-
Notifications
You must be signed in to change notification settings - Fork 40
/
Makefile
99 lines (71 loc) · 3.1 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
89
90
91
92
93
94
95
96
97
98
99
all: x86-linux x86-64-linux jvm
.PHONY: clean x86-linux x86-64-linux jvm wasm-wave
clean:
rm -f TAGS bin/*
cp scripts/* bin/
x86-linux: bin/spectest.x86-linux bin/wizeng.x86-linux bin/unittest.x86-linux bin/objdump.x86-linux
x86-64-linux: bin/spectest.x86-64-linux bin/wizeng.x86-64-linux bin/unittest.x86-64-linux bin/objdump.x86-64-linux
jvm: bin/spectest.jvm bin/wizeng.jvm bin/unittest.jvm bin/objdump.jvm
wasm-wave: bin/spectest.wasm bin/wizeng.wasm bin/unittest.wasm bin/objdump.wasm
v3i: bin/spectest.v3i bin/wizeng.v3i bin/unittest.v3i bin/objdump.v3i
ENGINE=src/engine/*.v3 src/engine/v3/*.v3 src/util/*.v3
MONITORS=src/monitors/*.v3
JIT=src/engine/compiler/*.v3
X86_64=src/engine/x86-64/*.v3
WAVE=src/modules/wave/*.v3
WASI=src/modules/wasi/*.v3
WASI_X86_64_LINUX=src/modules/wasi/x86-64-linux/*.v3
WALI=src/modules/wali/*.v3
WALI_X86_64_LINUX=src/modules/wali/x86-64-linux/*.v3
OBJDUMP=$(ENGINE) src/objdump.main.v3
SPECTEST=$(ENGINE) test/wasm-spec/*.v3 test/spectest.main.v3
UNITTEST=$(ENGINE) test/unittest/*.v3 test/wasm-spec/*.v3 test/unittest.main.v3
UNITTEST_X86_64_LINUX=test/unittest/x86-64-linux/*.v3 $(WASI) $(WASI_X86_64_LINUX)
WIZENG=$(ENGINE) $(WAVE) $(WASI) $(WALI) src/wizeng.main.v3 src/modules/*.v3 src/modules/wizeng/*.v3
TAGS: $(WIZENG) $(WAVE) $(WASI) $(WALI) $(SPECTEST) $(UNITTEST) $(WASI_X86_64_LINUX) $(JIT) $(X86_64)
vctags -e $(WIZENG) $(WAVE) $(WASI) $(WALI) $(SPECTEST) $(UNITTEST) $(WASI_X86_64_LINUX) $(WALI_X86_64_LINUX) $(JIT) $(X86_64)
# JVM targets
bin/unittest.jvm: $(UNITTEST) build.sh
./build.sh unittest jvm
bin/spectest.jvm: $(SPECTEST) build.sh
./build.sh spectest jvm
bin/wizeng.jvm: $(WIZENG) $(MONITORS) build.sh
./build.sh wizeng jvm
bin/objdump.jvm: $(OBJDUMP) build.sh
./build.sh objdump jvm
# WAVE targets
bin/unittest.wasm: $(UNITTEST) build.sh
./build.sh unittest wasm-wave
bin/spectest.wasm: $(SPECTEST) build.sh
./build.sh spectest wasm-wave
bin/wizeng.wasm: $(WIZENG) $(MONITORS) build.sh
./build.sh wizeng wasm-wave
bin/objdump.wasm: $(OBJDUMP) build.sh
./build.sh objdump wasm-wave
# x86-linux targets
bin/unittest.x86-linux: $(UNITTEST) build.sh
./build.sh unittest x86-linux
bin/spectest.x86-linux: $(SPECTEST) build.sh
./build.sh spectest x86-linux
bin/wizeng.x86-linux: $(WIZENG) $(MONITORS) build.sh
./build.sh wizeng x86-linux
bin/objdump.x86-linux: $(OBJDUMP) build.sh
./build.sh objdump x86-linux
# x86-64-linux targets
bin/unittest.x86-64-linux: $(UNITTEST) $(UNITTEST_X86_64_LINUX) $(X86_64) $(JIT) build.sh
./build.sh unittest x86-64-linux
bin/spectest.x86-64-linux: $(SPECTEST) $(X86_64) $(JIT) build.sh
./build.sh spectest x86-64-linux
bin/wizeng.x86-64-linux: $(WIZENG) $(MONITORS) $(WASI_X86_64_LINUX) $(WALI_X86_64_LINUX) $(X86_64) $(JIT) build.sh
./build.sh wizeng x86-64-linux
bin/objdump.x86-64-linux: $(OBJDUMP) $(X86_64) build.sh
./build.sh objdump x86-64-linux
# interpreter targets
bin/unittest.v3i: $(SPECTEST) build.sh
./build.sh unittest v3i
bin/spectest.v3i: $(SPECTEST) build.sh
./build.sh spectest v3i
bin/wizeng.v3i: $(WIZENG) $(MONITORS) build.sh
./build.sh wizeng v3i
bin/objdump.v3i: $(OBJDUMP) build.sh
./build.sh objdump v3i