debut ecritures fonctions clean et error

This commit is contained in:
hugogogo
2021-06-10 14:20:38 +02:00
parent 8d3fb563dd
commit 64363aeb18
9 changed files with 87 additions and 22 deletions

View File

@@ -3,30 +3,31 @@
# variables names # value | .h in includes/
# - - - - - - - - - - - - - - # ! name is case sensitive | ! use VPATH only for .c
NAME = pushswap
NAME = pushswap
CC = gcc
CC = gcc
VPATH = srcs
VPATH = srcs
IDIR = ./includes
IDIR = ./includes
_DEPS =
DEPS = $(_DEPS:%.h=$(IDIR)/%.h)
_DEPS =
DEPS = $(_DEPS:%.h=$(IDIR)/%.h)
# used to check if a .h has been modify when execute $NAME rule
LDIR = ./libft
_LIBS = libft.a
LIBS = $(_LIBS:lib%.a=%)
LDIR = ./libft
_LIBS = libft.a
LIBS = $(_LIBS:lib%.a=%)
SRCS = pushswap.c
SRCS = pushswap.c \
error.c
ODIR = ./builds
OBJS = $(SRCS:%.c=$(ODIR)/%.o)
ODIR = ./builds
OBJS = $(SRCS:%.c=$(ODIR)/%.o)
CFLAGS = -I$(IDIR) -g3 -Wall -Wextra -Werror
CFLAGS = -I$(IDIR) -g3 -Wall -Wextra -Werror
LFLAGS = -L$(LDIR) -l$(LIBS)
LFLAGS = -L$(LDIR) -l$(LIBS)