-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
53 lines (40 loc) · 1.45 KB
/
Makefile
File metadata and controls
53 lines (40 loc) · 1.45 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
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: dporhomo <dporhomo@student.42prague.com +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2025/12/08 14:30:34 by dporhomo #+# #+# #
# Updated: 2025/12/09 16:05:37 by dporhomo ### ########.fr #
# #
# **************************************************************************** #
NAME = libftprintf.a
CC = cc
CFLAGS = -Wall -Wextra -Werror
RM = rm -f
AR = ar rcs
HEADER = ft_printf.h
SRCS = ft_printf_char.c \
ft_printf_flags_init.c\
ft_printf_hex.c\
ft_printf_int.c\
ft_printf_parse_format.c\
ft_printf_ptr.c\
ft_printf_str.c\
ft_printf_unsigned.c\
ft_printf_utils.c\
ft_printf.c
OBJS = $(SRCS:.c=.o)
all: $(NAME)
bonus: $(NAME)
$(NAME): $(OBJS)
$(AR) $(NAME) $(OBJS)
%.o: %.c $(HEADER)
$(CC) $(CFLAGS) -c $< -o $@
clean:
$(RM) $(OBJS)
fclean: clean
$(RM) $(NAME)
re: fclean all
.PHONY: all clean fclean re bonus