-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
52 lines (38 loc) · 924 Bytes
/
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
52
NAME = ircserv
CC = clang++
CFLAGES = -Wall -Wextra -Werror -std=c++98 #-fsanitize=address -g3
IFLAGES = -I./inc -I./inc/cmd
SRCS := ./src/main.cpp \
./src/socket.cpp \
./src/utils.cpp \
./src/select.cpp \
./src/user.cpp \
./src/command/ping.cpp \
./src/command.cpp \
./src/command/nick.cpp \
./src/command/part.cpp \
./src/command/privmsg.cpp \
./src/command/join.cpp \
./src/command/kick.cpp \
./src/invoker.cpp \
./src/channel.cpp \
./src/command/quit.cpp \
./src/command/notice.cpp \
./src/command/invite.cpp \
./src/command/mode.cpp \
OBJS := $(SRCS:%.cpp=%.o)
$(NAME): $(OBJS)
@echo "compiler>>>>>>>>"
@$(CC) $(CFLAGES) $(OBJS) -o $@
@echo "IRC done!"
all: $(NAME)
clean:
@rm -rf $(OBJS)
@echo "Delete"
fclean:clean
@rm -rf $(NAME)
@echo "Delete all"
%.o: %.cpp
@$(CC) $(CFLAGES) $(IFLAGES) -c $< -o $@
re: fclean all
.PHONY: all clean fclean re