-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
40 lines (29 loc) · 1.23 KB
/
Makefile
File metadata and controls
40 lines (29 loc) · 1.23 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
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: adores <adores@student.42lisboa.com> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2025/04/24 11:10:10 by adores #+# #+# #
# Updated: 2025/05/03 11:56:45 by adores ### ########.fr #
# #
# **************************************************************************** #
NAME := libftprintf.a
CC := cc
CFLAGS := -Wall -Wextra -Werror
SRC := ft_printstr.c ft_hexaputnbr.c ft_printchar.c ft_printf.c \
ft_printnbr.c ft_unsputnbr.c ft_printp.c
OBJ := $(SRC:.c=.o)
RM := rm -f
AR := ar rcs
all: $(NAME)
$(NAME): $(OBJ)
$(AR) $@ $^
%.o: %.c
$(CC) $(CFLAGS) -o $@ -c $<
clean:
$(RM) $(OBJ)
fclean: clean
$(RM) $(NAME)
re: fclean all