-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
75 lines (55 loc) · 1.74 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
72
73
74
75
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: trobert <trobert@student.42.fr> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2022/01/21 15:43:19 by trobert #+# #+# #
# Updated: 2022/08/03 19:03:20 by trobert ### ########.fr #
# #
# **************************************************************************** #
SRC = algo_small_sort.c\
algo_middle_sort.c\
algo_big_sort.c\
check_and_display_functions.c\
check_args.c\
check_special_args.c\
find_arrays.c\
free_functions.c\
get_utils.c\
init_var.c\
lis.c\
lis_utils.c\
list_functions.c\
ops_functions.c\
ops_ab.c\
ops_a.c\
ops_b.c\
push_swap.c\
scoring.c\
SRCS = ${addprefix srcs/, ${SRC}}
OBJS = ${SRCS:.c=.o}
NAME = push_swap
LIBFT = libft/superlibft.a
INC = -I./includes
CC = cc
RM = rm -f
CFLAGS = -Wall -Wextra -Werror -g
MAKELIB = make -C libft/
CLEANLIB = make fclean -C libft/
all: ${NAME}
${NAME}: ${OBJS} libcompil includes/push_swap.h
${CC} ${CFLAGS} ${OBJS} ${LIBFT} -o ${NAME}
.c.o:
${CC} ${CFLAGS} ${INC} -c $< -o ${<:.c=.o}
libcompil :
${MAKELIB}
clean:
${RM} ${OBJS}
fclean: clean
${RM} ${NAME} ${BOBJS}
libclean:
${CLEANLIB}
re: fclean all
.PHONY: clean fclean bonus all re