-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
58 lines (42 loc) · 877 Bytes
/
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
##
## EPITECH PROJECT, 2020
## 110borwein
## File description:
## Makefile
##
NAME = 110borwein
SRC = src/main.c \
src/start.c \
src/error_handling.c \
src/util_functions.c \
src/compute.c
TEST = src/start.c \
src/error_handling.c \
src/util_functions.c \
src/compute.c
CC ?= gcc
CFLAGS = -W -Wextra -Wall
CPPFLAGS = -I./include/
LDFLAGS = -lm
CFFLAGS = tests/unit_tests.c -I./include --coverage -lcriterion
OBJ = $(SRC:.c=.o)
name : all
all : $(OBJ)
$(CC) -o $(NAME) $(OBJ) $(LDFLAGS)
tests_run :
$(CC) -o unit_tests $(TEST) $(CFFLAGS) $(LDFLAGS)
clean :
rm -f $(OBJ)
fclean : clean
rm -f $(NAME) \
rm -f *# \
rm -f src/*# \
rm -f include/*# \
rm -f *~ \
rm -f src/*~ \
rm -f include/*~ \
rm -f *.gcda \
rm -f *.gcno \
rm -f unit_tests
re : fclean all
.PHONY : name all debug tests_run clean fclean re