-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
71 lines (60 loc) · 1.75 KB
/
Makefile
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: fraqioui <[email protected]> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2022/11/23 07:54:41 by fraqioui #+# #+# #
# Updated: 2022/12/24 16:24:15 by fraqioui ### ########.fr #
# #
# **************************************************************************** #
NAME = push_swap
CC = cc
FLAGS = -Wall -Wextra -Werror
RM = rm -rf
HEADER = push_swap.h
FILES = algo_five \
algo_three \
calc_moves_needed \
checking \
helpers \
lis_algo \
list_creation \
lis \
main \
minmax \
moves_neg \
moves_posi \
operations1 \
operations2 \
operations3 \
push_swap_utils1 \
push_swap_utils2
BFILES = bonus \
push_swap_utils_bonus \
checking \
list_creation \
operations1 \
operations2 \
operations3 \
push_swap_utils1 \
push_swap_utils2 \
get_next_line \
get_next_line_utils
OBJ = ${FILES:=.o}
BOBJ = ${BFILES:=.o}
.PHONY: all bonus clean fclean re
all: ${NAME}
new = checker
${NAME}: ${OBJ} ${HEADER}
${CC} ${FLAGS} ${OBJ} -o ${NAME}
%.o: %.c
${CC} ${FLAGS} -c $< -o $@
bonus: ${BOBJ} ${HEADER}
${CC} ${FLAGS} ${BOBJ} -o ${new}
clean:
${RM} ${OBJ} ${BOBJ}
fclean: clean
${RM} ${NAME} ${new}
re: fclean all