-
Notifications
You must be signed in to change notification settings - Fork 0
/
makefile
43 lines (32 loc) · 1.36 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
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: jmykkane <[email protected]> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2022/10/24 14:22:41 by jmykkane #+# #+# #
# Updated: 2022/10/24 14:22:53 by jmykkane ### ########.fr #
# #
# **************************************************************************** #
NAME = libftprintf.a
SRC = ft_printf.c convert_c.c convert_d_i.c convert_p.c convert_precentage.c\
convert_s.c convert_x.c convert_u.c
SRC_O = $(SRC:.c=.o)
LIBFT = libft/libft.a
INCLUDES = ft_printf.h
FLAGS = -Wall -Werror -Wextra -I $(INCLUDES)
all: $(NAME)
$(NAME):
cd libft && $(MAKE)
mv libft/libft.a $(NAME)
cc -c $(FLAGS) $(SRC)
ar rc $(NAME) $(SRC_O)
clean:
rm -f $(SRC_O)
cd libft && $(MAKE) clean
fclean:
rm -f $(SRC_O)
rm -f $(NAME)
cd libft && $(MAKE) fclean
re: fclean all