aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
blob: c24e590f5325edda4153878bfe5599deda944f67 (plain)
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
CC := gcc
CFLAGS := -g -Wall -Wextra -Wpedantic -Werror -Wno-language-extension-token -Wno-stringop-overread -Iinclude 

tests: container types log

container: tests/dynarray.c tests/dynarray_struct.c tests/obscure.c \
		tests/binary_search.c tests/linked_list.c tests/hashset.c \
		tests/hmap.c include/container.h \
	$(CC) $(CFLAGS) -o $@ $< -DTT_CHAR
	./$@
	$(CC) $(CFLAGS) -o $@ $< -DTT_SHORT
	./$@
	$(CC) $(CFLAGS) -o $@ $< -DTT_INT
	./$@
	$(CC) $(CFLAGS) -o $@ $< -DTT_LONG
	./$@
	$(CC) $(CFLAGS) -o $@ tests/dynarray_struct.c
	./$@
	$(CC) $(CFLAGS) -o $@ tests/obscure.c
	./$@
	$(CC) $(CFLAGS) -o $@ tests/binary_search.c
	./$@
	# $(CC) $(CFLAGS) -o $@ tests/linked_list.c
	# ./$@
	$(CC) $(CFLAGS) -o $@ tests/hmap.c
	./$@
	#$(CC) $(CFLAGS) -o $@ tests/hashset.c
	#./$@

	rm $@

types: tests/types.c
	$(CC) -o $@ tests/types.c $(CFLAGS)
	./$@
	
	rm $@

log: tests/log.c
	$(CC) -o $@ tests/log.c $(CFLAGS)
	- ./$@
	rm $@