-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
58 lines (39 loc) · 1.56 KB
/
Makefile
File metadata and controls
58 lines (39 loc) · 1.56 KB
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
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: tarchimb <tarchimb@student.42.fr> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2021/11/17 11:24:39 by tarchimb #+# #+# #
# Updated: 2022/03/31 14:36:29 by tarchimb ### ########.fr #
# #
# **************************************************************************** #
SRCS = pipex.c \
ft_parsing.c \
OBJS = ${SRCS:.c=.o}
INCLUDES = ./Includes/pipex.h \
./Includes/libft.h \
CC = gcc \
CFLAGS = -Wall -Wextra -Werror
NAME = pipexlib.a
LIBS = ./libft/libft.a \
./pipexlib.a \
EXEC = pipex
all: libft ${EXEC}
%.o: %.c ${INCLUDES}
${CC} ${CFLAGS} -I ./Includes -c $< -o $@
${EXEC}: pipex.c ${LIBS}
${CC} ${CFLAGS} ${LIBS} pipex.c -o ${EXEC}
libft: ${INCLUDES}
make -C libft
$(NAME): ${OBJS} ${INCLUDES}
ar rcs ${NAME} ${OBJS}
clean:
@${RM} ${OBJS} ${OBJSBONUS}
make clean -C ./libft
fclean: clean
make fclean -C ./libft
@${RM} ${EXEC} ${NAME}
re: fclean all
.PHONY: all clean fclean libft