-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
54 lines (39 loc) · 1.54 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
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: asegovia <[email protected]> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2020/01/03 09:54:02 by asegovia #+# #+# #
# Updated: 2020/07/08 09:04:32 by asegovia ### ########.fr #
# #
# **************************************************************************** #
NAME = Cube3D
CFILES = main.c minimap.c movement.c raycast.c sprites.c bmp.c\
raycast2.c raycast3.c init_structs.c hooks.c
FLAGS = -Wall -Wextra -Werror -lmlx\
-framework OpenGL -framework Appkit
OBJS = $(CFILES:.c=.o)
MAKE_LIBS = $(MAP) $(LIBFT) $(MLX)
all: $(NAME)
$(NAME): $(OBJS) $(LIBS)
Make -C lib
Make -C map
Make -C mlx
gcc $(FLAGS) -o $(NAME) $(OBJS) map/map.a lib/libft.a
$(MLX):
Make -C mlx
$(MAP): map/map.a
Make -C map
$(LIBFT): lib/libft.a
Make -C lib
clean:
Make -C mlx clean
Make -C lib clean
Make -C map clean
rm -f $(OBJS)
fclean: clean
rm -f $(NAME) map/map.a lib/libft.a mlx/libmlx.a
re: fclean $(NAME)
.PHONY: all clean fclean re