-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
63 lines (46 loc) · 1.64 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
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: eserebry <eserebry@student.42.fr> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2017/10/02 00:51:37 by eserebry #+# #+# #
# Updated: 2017/10/18 16:08:42 by eserebry ### ########.fr #
# #
# **************************************************************************** #
NAME = wolf3d
FLAGS = -Wall -Wextra -Werror -Ofast -g
CC = gcc
CMP = -L minilibx -lmlx -framework OpenGL -framework AppKit
SRC = main.c\
usage.c\
movement.c\
raycasting.c\
init.c\
move.c\
menu.c
OBJ = $(SRCS:.c=.o)
SRCDIR = srcs
OBJDIR = objs
SRCS = $(addprefix $(SRCDIR)/, $(SRC))
OBJS = $(addprefix $(OBJDIR)/, $(OBJ))
HEADER = wolf3d.h
RM = rm -rf
GREEN = \033[32m
RED = \033[31m
all: $(NAME)
$(NAME): $(OBJ)
@make -C libft/
@$(CC) -o $(NAME) $(SRCS) $(CMP) $(FLAG) libft/libft.a
@echo "$(GREEN)wolf3d: creating object files"
clean:
@/bin/$(RM) $(OBJ)
@make -C libft/ clean
fclean: clean
@make -C libft/ fclean
@/bin/$(RM) $(NAME)
@echo "$(RED)wolf3d: deleting object files"
re: fclean all
.PHONY: all clean fclean re
.SUFFIXES: .c .o