-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
40 lines (28 loc) · 1.25 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
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: ofadhel <[email protected]> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2024/07/29 16:43:20 by ofadhel #+# #+# #
# Updated: 2024/10/28 10:22:34 by ofadhel ### ########.fr #
# #
# **************************************************************************** #
NAME = ircserv
SRCS = $(shell find srcs -name '*.cpp')
OBJS = $(SRCS:%.cpp=objs/%.o)
FLAGS = -Wall -Wextra -Werror -std=c++98 -g
CC = g++
objs/%.o: %.cpp
@mkdir -p $(dir $@)
$(CC) $(FLAGS) -c $< -o $@
all: $(NAME)
$(NAME): $(OBJS)
$(CC) $(FLAGS) $(OBJS) -o $(NAME)
clean:
rm -rf $(NAME) $(OBJS)
fclean: clean
rm -rf objs .vscode
re: fclean all
.PHONY: all clean fclean re