-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
62 lines (50 loc) · 1.81 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
52
53
54
55
56
57
58
59
60
61
62
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: rpoetess <[email protected]> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2019/09/05 20:27:05 by ksticks #+# #+# #
# Updated: 2019/11/21 22:00:31 by rpoetess ### ########.fr #
# #
# **************************************************************************** #
CC = gcc
NAME = fractol
FLAGS = -Wall -Wextra -Werror
SRC = \
src/app.c \
src/controller.c \
src/camera.c \
src/framebuffer.c \
src/palette.c \
src/fractol.c \
src/fractol_pix.c \
src/it_estimator.c \
src/fractol_v2.c \
src/mouse_movement.c \
src/main.c
OPTION = -I. -Ilibft -Iminilibx_macos
OBJ = $(SRC:.c=.o)
all : $(NAME)
$(NAME) : libft/libft.a minilibx_macos/libmlx.a $(OBJ)
$(CC) -o $(NAME) $(OBJ) $(OPTION) -L minilibx_macos/ -lmlx -L libft/ -lft -framework OpenGL -framework AppKit
# @$(CC) -o $(NAME) $(OBJ) $(OPTION) -L minilibx_macos/ -L libft/ -lft
%.o: %.c
@echo compile $(<) "->" $(<:.c=.o)
$(CC) $(FLAGS) -c $(<) -o $(<:.c=.o) $(OPTION)
libft/libft.a :
make -C libft/
minilibx_macos/libmlx.a :
# @echo skip mac
make -C minilibx_macos
run : $(NAME)
@./$(NAME) julia
clean :
rm -f $(OBJ)
make -C libft/ clean
fclean : clean
rm -f $(NAME)
make -C libft/ fclean
make -C minilibx_macos/ clean
re : fclean all