-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
76 lines (63 loc) · 2.5 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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: vcombey <[email protected]> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2016/12/30 19:59:01 by vcombey #+# #+# #
# Updated: 2017/05/01 18:11:47 by vcombey ### ########.fr #
# #
# **************************************************************************** #
NAME = wolf3d
SRC = main.c \
parsing.c \
ft_pixelput.c \
ft_pixelget.c \
ft_retmsg.c \
env.c \
map.c \
camera.c \
wolf.c \
trace.c \
key_event.c \
portal_gun.c \
teleportation.c \
cross.c \
ft_rot_pos.c \
hit_portal.c \
hit.c \
draw_portal_gun.c \
struct.c \
key_pressed.c \
init_texture.c \
trace_portal.c \
tourelle.c \
trace_line.c \
floor_casting.c \
INCLUDE = -I ./libft -I ./include -I ./minilibx_macos/
OBJS = $(addprefix objs/, $(SRC:.c=.o))
CFLAGS += -Wall -g -o2 -flto -Wextra -Werror
all: $(NAME)
$(NAME): dis $(OBJS)
make -C ./libft/
@gcc -g $(OBJS) -L libft -lft -lmlx -framework OpenGL -framework AppKit -o2 -flto -L minilibx_macos -lmlx -o $(NAME)
clean:
make clean -C ./libft/
/bin/rm -rf objs
fclean: clean
/bin/rm -f ./libft/libft.a
/bin/rm -f $(NAME)
re: fclean all
objs/%.o : src/%.c
@/bin/mkdir -p objs
gcc $(INCLUDE) $(CFLAGS) -c -o $@ $<
dis:
@echo " __ __ ___ ______ ___ _______ _______ ________ "
@echo "|\" |/ \| \"| / \" \ |\" | /\" \"| /\" __ )|\" \"\ "
@echo "|' / \: | // ____ \ || | (: ______)(__/ _) ./(. ___ :) "
@echo "|: /' | / / ) :)|: | \/ | / // |: \ ) || "
@echo " \// /\' |(: (____/ // \ |___ // ___) __ \_ \\\\\\\ (| (___\ || "
@echo " / / \\\ | \ / ( \_|: \(: ( (: \__) :\|: :) "
@echo "|___/ \___| \\\"_____/ \_______)\__/ \_______)(________/ "
.PHONY: all clean fclean re