-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile
50 lines (37 loc) · 954 Bytes
/
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
NAME = bip32_template_parse
ifeq (${NUM_WORKERS},)
NUM_WORKERS = 1
endif
all: check
run_check = java -jar ${TLATOOLSDIR}/tla2tools.jar \
-config ${NAME}.cfg \
-workers ${NUM_WORKERS} \
-metadir workdir/meta \
-terse \
-cleanup \
-userFile workdir/output.txt \
MC.tla
workdir/output.txt: workdir/meta
$(call run_check,)
workdir/output.txt.uniq: workdir/output.txt
@uniq workdir/output.txt | sort | uniq > $@
check: workdir/meta
$(call run_check,)
${NAME}.pdf: workdir/meta
java -cp ${TLATOOLSDIR}/tla2tools.jar tla2tex.TLA \
-metadir workdir/meta \
-latexOutputExt pdf \
-latexCommand pdflatex \
-ptSize 12 \
-shade \
${NAME}.tla
pdf: ${NAME}.pdf
test_data: MC.tla workdir/output.txt.uniq
@python3 generate_test_data.py MC.tla bip32_template_parse.cfg < workdir/output.txt.uniq
clean:
rm -rf workdir
workdir:
mkdir -p workdir
workdir/meta:
mkdir -p workdir/meta
.PHONY: all check pdf clean