-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmakefile
More file actions
54 lines (36 loc) · 1.09 KB
/
makefile
File metadata and controls
54 lines (36 loc) · 1.09 KB
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
CC := gcc
GDB := cgdb
FL_ERR := -Wall -Werror -Wextra -pedantic
# --std=c89
FL_DEBUG := -fsanitize=address -fsanitize=undefined -fsanitize=leak -ggdb3
FL_TEST := $(shell pkg-config --cflags --libs criterion)
CREL := ${CC} ${FL_ERR}
CDEV := ${CC} ${FL_ERR} ${FL_DEBUG}
CTEST := ${CC} ${FL_ERR} ${FL_DEBUG} ${FL_TEST}
DIR_TEST := dev_tests
FL_VALG := -s --track-origins=yes --leak-check=full --show-leak-kinds=all
MEMTEST := valgrind ${FL_VALG}
FL_TEST := --full-stats --verbose=0 --timeout=4 --color=always
.DELETE_ON_ERROR:
.PHONY: clean clean-obj clean-lib betty
######## TASKS
######## RELEASE
######## DEVELOPMENT
dev-criterion_testdrive:
@${CTEST} ${DIR_TEST}/template.test.c -o testdrive_unittest.x
@./testdrive_unittest.x ${FL_TEST}
######## UNIT TESTS
######## MEMORY CHECKS
######## RUN
######## UTILITY
betty:
@echo "running Betty CODING STYLE checks..."
@betty-style *.c *.h
@echo "running Betty DOCUMENTATION checks..."
@betty-doc *.c *.h
clean: clean-obj clean-lib
@$(RM) -v *~ *.exec *.out *.x
clean-obj:
@$(RM) -v *.o
clean-lib:
@$(RM) -v *.so