-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
83 lines (62 loc) · 1.93 KB
/
Copy pathMakefile
File metadata and controls
83 lines (62 loc) · 1.93 KB
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
BUILDDIR=build
WREN:=deps/wren-cli.git/bin/wren_cli
VEERY:=$(WREN) $(BUILDDIR)/bin/veery
.PHONY: all
all: build
.PHONY: ckeck
check: check-lang-veery check-lang-wren
check-lang-veery: all
@echo "TODO: expand check-lang-veery"
check-lang-wren: all
@for TEST_FILE in $(shell find $(BUILDDIR) -type f); do \
echo $(VEERY) analyze --lang=wren "$${TEST_FILE}"; \
$(VEERY) analyze --lang=wren "$${TEST_FILE}"; \
done
@echo "TODO: expand check-lang-wren"
.PHONY: update-stage0
update-stage0: stage3 clean-stage0 stage0
.PHONY: stage0
stage0: stage3
make -f Makefile.stage BUILDDIR="stage0" VEERY="$(WREN) stage3/bin/veery" VEERY_ARGS="$(VEERY_ARGS)" bootstrap
.PHONY: stage1
stage1:
make -f Makefile.stage BUILDDIR="stage1" VEERY="$(WREN) stage0/bin/veery" VEERY_ARGS="$(VEERY_BOOTSTRAP_ARGS)" bootstrap
.PHONY: stage2
stage2: stage1
make -f Makefile.stage BUILDDIR="stage2" VEERY="$(WREN) stage1/bin/veery" VEERY_ARGS="$(VEERY_ARGS)" all
.PHONY: stage3
stage3: stage2
make -f Makefile.stage BUILDDIR="stage3" VEERY="$(WREN) stage2/bin/veery" VEERY_ARGS="$(VEERY_ARGS)" all
# Test for a sound build
diff -rq stage2 stage3
.PHONY: build
build: stage3
make -f Makefile.stage BUILDDIR="$(BUILDDIR)" VEERY="$(WREN) stage3/bin/veery" all
.PHONY: run-input-test
run-input-test: build
$(WREN) $(BUILDDIR)/bin/input-test
.PHONY: run-shell
run-shell: build
$(VEERY) shell
.PHONY: run-veery-shell
run-veery-shell: build
$(VEERY) shell --lang=veery
.PHONY: run-wren-shell
run-wren-shell: build
$(VEERY) shell --lang=wren
.PHONY: clean
clean:
make -f Makefile.stage BUILDDIR="stage1" clean
make -f Makefile.stage BUILDDIR="stage2" clean
make -f Makefile.stage BUILDDIR="stage3" clean
make -f Makefile.stage BUILDDIR="$(BUILDDIR)" clean
.PHONY: clean-stage0
clean-stage0:
rm -rf stage0
.PHONY: mrproper
mrproper:
# rm -rf stage0 # Preserve stage0
rm -rf stage1
rm -rf stage2
rm -rf stage3
# rm -rf $(BUILDDIR) # Preserve in case user use BUILDDIR=.