-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
50 lines (43 loc) · 1.7 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
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: twitting <[email protected]> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2018/11/20 14:23:06 by twitting #+# #+# #
# Updated: 2018/12/28 17:52:24 by twitting ### ########.fr #
# #
# **************************************************************************** #
NAME = fdf
SRC = ./fdf_src/fdf.c \
./fdf_src/ft_pointmaker.c \
./fdf_src/ft_printlines.c \
./fdf_src/ft_putline.c \
./fdf_src/ft_freepnt.c \
./fdf_src/ft_keyboard.c
SRC2 = ./libft/libft.a
OBJECTS = fdf.o \
ft_pointmaker.o \
ft_printlines.o \
ft_putline.o \
ft_freepnt.o \
ft_keyboard.o
FLAGS = -Wall -Wextra -Werror
FLAGS2 = -I /usr/local/include -L /usr/local/lib -lmlx -framework OpenGL -framework AppKit
FLAGS3 = /usr/local/lib/libmlx.a /usr/local/include/mlx.h -lXext -lX11 -lm
all: $(NAME)
linux:
make re -C libft/
sudo gcc $(FLAGS) $(SRC) $(SRC2) $(FLAGS3) -o $(NAME)
$(NAME):
make re -C libft/
gcc $(FLAGS) $(SRC) -c
gcc $(FLAGS) $(FLAGS2) $(OBJECTS) $(SRC2) -o $(NAME)
clean:
make clean -C libft/
/bin/rm -f $(OBJECTS)
fclean: clean
make fclean -C libft/
/bin/rm -f $(NAME)
re: fclean all