forked from peigen-sboxes/PEIGEN
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
88 lines (58 loc) · 1.99 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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
CC=g++ -fopenmp
CFLAGS= -mavx2 -std=c++14 -O3 -Wall -Wextra -pedantic
LDFLAGS=
EXEC=evaluate evaluate_single search_GC_n3 search_GC_n4 search_depth_n3 search_depth_n4 filter_n3 filter_n4 gen_n3 gen_n4
all: $(EXEC)
evaluate: evaluate.o
$(CC) -o $@ $^ $(LDFLAGS) -DEVA
evaluate.o: main.cpp
$(CC) -o $@ -c $< $(CFLAGS) -DEVA
evaluate_single: evaluate_single.o
$(CC) -o $@ $^ $(LDFLAGS) -DEVA_Single
evaluate_single.o: main.cpp
$(CC) -o $@ -c $< $(CFLAGS) -DEVA_Single
search_GC_n3: search_GC_n3.o
$(CC) -o $@ $^ $(LDFLAGS) -DGC -DSIZEINBIT=3
search_GC_n3.o: main.cpp
$(CC) -o $@ -c $< $(CFLAGS) -DGC -DSIZEINBIT=3
search_GC_n4: search_GC_n4.o
$(CC) -o $@ $^ $(LDFLAGS) -DGC -DSIZEINBIT=4
search_GC_n4.o: main.cpp
$(CC) -o $@ -c $< $(CFLAGS) -DGC -DSIZEINBIT=4
search_depth_n3: search_depth_n3.o
$(CC) -o $@ $^ $(LDFLAGS) -DDEPTH -DSIZEINBIT=3
search_depth_n3.o: main.cpp
$(CC) -o $@ -c $< $(CFLAGS) -DDEPTH -DSIZEINBIT=3
search_depth_n4: search_depth_n4.o
$(CC) -o $@ $^ $(LDFLAGS) -DDEPTH -DSIZEINBIT=4
search_depth_n4.o: main.cpp
$(CC) -o $@ -c $< $(CFLAGS) -DDEPTH -DSIZEINBIT=4
filter_n3: filter_n3.o
$(CC) -o $@ $^ $(LDFLAGS) -DFILTER -DSIZEINBIT=3
filter_n3.o: main.cpp
$(CC) -o $@ -c $< $(CFLAGS) -DFILTER -DSIZEINBIT=3
filter_n4: filter_n4.o
$(CC) -o $@ $^ $(LDFLAGS) -DFILTER -DSIZEINBIT=4
filter_n4.o: main.cpp
$(CC) -o $@ -c $< $(CFLAGS) -DFILTER -DSIZEINBIT=4
gen_n3: gen_n3.o
$(CC) -o $@ $^ $(LDFLAGS) -DGEN -DSIZEINBIT=3
gen_n3.o: main.cpp
$(CC) -o $@ -c $< $(CFLAGS) -DGEN -DSIZEINBIT=3
gen_n4: gen_n4.o
$(CC) -o $@ $^ $(LDFLAGS) -DGEN -DSIZEINBIT=4
gen_n4.o: main.cpp
$(CC) -o $@ -c $< $(CFLAGS) -DGEN -DSIZEINBIT=4
clean:
rm -rf *.o
mrproper: clean
rm -rf $(EXEC)
rm test_faster
rm test_lighter
gencheck:
find ./R -maxdepth 1 -name "*.c" -print > results.c
$(CC) $(CFLAGS) genTest.cpp -o genTest && ./genTest
checkfaster:
$(CC) $(CFLAGS) faster_test.cpp -o test_faster && ./test_faster
checklighter:
$(CC) $(CFLAGS) faster_test.cpp -o test_lighter && ./test_lighter