-
Notifications
You must be signed in to change notification settings - Fork 53
/
Makefile
71 lines (60 loc) · 1.28 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
default:
opam update
opam install . --deps-only
make build
.PHONY: build
build:
make pre-build
dune build
bazel build //src/llvm-backend:main
install:
eval $(opam config env)
opam update
opam install --yes . --deps-only
eval $(opam env)
lint:
make clean
make pre-build
dune build @lint
dune build @fmt
test:
make pre-build
dune runtest
scripts/run_frontend_integration_tests.sh
bazel test tests/llvm-backend/llvm_ir_codegen:test_llvm_ir_codegen
scripts/run_e2e_tests.sh
.SILENT: clean
clean:
dune clean
@git clean -dfX
rm -rf docs/
doc:
make clean
make pre-build
dune build @doc
mkdir docs/
cp -r ./_build/default/_doc/_html/* docs/
format:
make pre-build
dune build @fmt --auto-promote
find **/llvm-backend/** -name "*.h" -o -name "*.cc" | xargs clang-format -i --style=file
hook:
cp ./hooks/* .git/hooks
coverage:
make clean
make pre-build
BISECT_ENABLE=yes dune build
dune runtest
scripts/run_frontend_integration_tests.sh
bisect-ppx-report html
bisect-ppx-report summary
.SILENT: pre-build
pre-build:
# hack: create opam files so libraries can be exposed publicly
cp bolt.opam ast.opam
cp bolt.opam parsing.opam
cp bolt.opam typing.opam
cp bolt.opam desugaring.opam
cp bolt.opam data_race_checker.opam
cp bolt.opam ir_gen.opam
rm -rf bazel-bolt