-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
55 lines (42 loc) · 770 Bytes
/
Makefile
File metadata and controls
55 lines (42 loc) · 770 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
CC = cc
CFLAGS = -Werror -Wall -Wextra
UTILS_DIR = utils/
ALGO_DIR = algos/
SRCS = main.c \
ft_atoi.c \
ft_sqrt.c \
ft_bzero.c \
ft_calloc.c \
ft_strcmp.c \
init_data.c \
ft_printf.c \
push.c \
reverse.c \
rotate.c \
swap.c \
disorder.c \
benchmark.c \
$(UTILS_DIR)nbr_utils.c \
$(UTILS_DIR)lst_utils.c \
$(UTILS_DIR)lst_utils_bis.c \
$(UTILS_DIR)error_utils.c \
$(UTILS_DIR)algos_utils.c \
$(ALGO_DIR)simple.c \
$(ALGO_DIR)medium.c \
$(ALGO_DIR)complex.c \
$(ALGO_DIR)adaptive.c \
HEADERS = push_swap.h \
ft_printf.h
OBJS = $(SRCS:.c=.o)
NAME = push_swap
all : $(NAME)
$(NAME): $(OBJS)
$(CC) $(CFLAGS) -o $@ $^
%.o: %.c $(HEADERS)
$(CC) $(CFLAGS) -c $< -o $@
clean:
rm -rf $(OBJS)
fclean: clean
rm -rf $(NAME)
re: fclean all
.PHONY: all clean fclean re