-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
51 lines (39 loc) · 1.51 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
51
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: luisfern <luisfern@student.42lisboa.com +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2022/10/18 14:36:04 by luisfern #+# #+# #
# Updated: 2022/10/20 15:27:13 by luisfern ### ########.fr #
# #
# **************************************************************************** #
CLIENT = client
SERVER = server
FILE_S = server.c
FILE_C = client.c
EXE_S = server
EXE_C = client
PRINTF = ft_printf/libftprintf.a
CC = gcc
CFLAGS = -Wall -Wextra -Werror
RM = rm -rf
all: $(CLIENT) $(SERVER)
$(CLIENT): $(PRINTF)
@ $(CC) $(CFLAGS) $(FILE_C) $(PRINTF) -o $(CLIENT)
@ echo client ready.
$(SERVER): $(PRINTF)
@ $(CC) $(CFLAGS) $(FILE_S) $(PRINTF) -o $(SERVER)
@ echo server ready.
$(PRINTF):
@ make -C ft_printf/
@ cp ft_printf/libftprintf.a .
clean:
@ $(RM) $(CLIENT) $(SERVER)
@ echo client n server deleted.
fclean: clean
@ $(RM) libftprintf.a
@ echo all deleted.
re: fclean all
@ echo recompiling