-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
51 lines (38 loc) · 1.46 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: nhennigh <[email protected]> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2019/03/01 13:27:36 by nhennigh #+# #+# #
# Updated: 2019/03/01 13:28:14 by nhennigh ### ########.fr #
# #
# **************************************************************************** #
NAME = fillit
CFLAGS += -Wall -Wextra -Werror
CFLAGS += -I libft/
SRC = main.c \
reader.c \
solver.c \
OBJ = $(SRC:.c=.o)
LIBFT = libft/libft.a
.PHONY = all clean fclean clean re
all: $(NAME)
make -C libft
$(OBJ): %.o: %.c
@gcc -c $(CFLAGS) $< -o $@
$(LIBFT):
@make -C libft
$(NAME): $(LIBFT) $(OBJ)
@gcc $(OBJ) $(LIBFT) -o $(NAME)
@echo "\033[32mCompiled Executable\033[0m"
clean:
@rm -rf $(OBJ)
@make -C libft clean
@echo "\033[32mRemoved Object Files\033[0m"
fclean: clean
@rm -rf $(NAME)
@make -C libft fclean
@echo "\033[32mRemoved Executable\033[0m"
re: fclean all