-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
63 lines (53 loc) · 1.46 KB
/
Makefile
File metadata and controls
63 lines (53 loc) · 1.46 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
59
60
61
62
63
NAME = libftprintf.a
CC = gcc
CFLAGS = -Wall -Werror -Wextra -I . -c
SOURCES = ft_printf.c \
ft_getstrbyspec.c \
ft_smartstrncat.c \
ft_expandsmartstr.c \
ft_flushsmartstr.c \
ft_strchr.c \
ft_strcpy.c \
ft_instr.c \
ft_ulfromstr.c \
ft_memset.c \
ft_bzero.c \
ft_strlen.c \
ft_strncpy.c \
ft_count_digits_unsigned.c \
ft_getspecificator.c \
ft_get_signed_arg.c \
ft_get_unsigned_arg.c \
ft_percent_format.c \
ft_unknown_format.c \
ft_char_format.c \
ft_string_format.c \
ft_unicode_format.c \
ft_integer_format.c \
ft_oct_format.c \
ft_hex_format.c \
ft_hex_upper_format.c \
ft_unsigned_format.c \
ft_pointer_format.c \
ft_afloat_format.c \
ft_afloat_upper_format.c \
ft_float_format.c \
ft_utf8_count_bytes.c \
ft_utf8_convert.c \
ft_format_hex.c \
ft_fill_floating_point.c \
ft_fill_long_floating_point.c \
ft_count_digits_signed.c \
OBJECTS = $(SOURCES:.c=.o)
HEADER = $(NAME:.a=.h)
all: $(NAME)
$(NAME): $(OBJECTS) $(HEADER)
ar -rc $(NAME) $(OBJECTS)
ranlib $(NAME)
%.o: %.c $(HEADER)
$(CC) $(CFLAGS) $<
clean:
rm -f $(OBJECTS)
fclean: clean
rm -f $(NAME)
re: fclean all