-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
50 lines (36 loc) · 1.45 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
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: yrhiba <yrhiba@student.1337.ma> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2022/11/28 04:22:23 by yrhiba #+# #+# #
# Updated: 2022/12/06 03:46:20 by yrhiba ### ########.fr #
# #
# **************************************************************************** #
NAME = pipex
INC = pipex.h
SRCS = pipex.c pipex_utils.c return_utils.c \
getpipes.c getfds.c startforking.c \
getcmdargs.c
OBJS_DIR = objs/
OBJS = $(addprefix $(OBJS_DIR), $(SRCS:.c=.o))
FLAGS = -Wall -Wextra -Werror
$(NAME) : mlibft $(OBJS)
cc $(OBJS) -o $(NAME) -L libft -l ft
$(OBJS_DIR)%.o : %.c $(INC)
@mkdir -p $(OBJS_DIR)
cc $(FLAGS) -c $< -o $@ -Ilibft
all : $(NAME)
clean : clibft
rm -rf $(OBJS_DIR)
fclean : clean
rm -rf $(NAME)
re : fclean all
mlibft :
make -C libft
clibft :
make fclean -C libft
bonus : all
.PHONEY : all fclean clean re clibft mlibft