Makefile 427 Bytes
Newer Older
Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
1
all: truelisp
Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
2

Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
3
4
5
6
HY = hy
HYC = hyc3
HY2PY = hy2py3

7
8
FIBO = 15

Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
9
# Compile
Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
10
truelisp.py: truelisp.hy
Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
11
	$(info Compiling (hy2py) $<)
Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
12
	@$(HY2PY) $< > $@
Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
13
14

truelisp: truelisp.hy
Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
15
	@$(HYC) $<
Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
16

Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
17
18
# Tests
fibo: example-fibo.hy
19
20
	$(info Running $< $(FIBO))
	@$(HY) example-fibo.hy $(FIBO)
Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
21
22
23

test: test.hy
	$(info Running $<)
Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
24
	@$(HY) $<
Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
25
26

check: test fibo
Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
27

Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
28
29
# Clean
.PHONY: clean check test fibo truelisp
Pierre-Antoine Rouby's avatar
Pierre-Antoine Rouby committed
30
clean:
31
	@rm -vf *.py
32
	@rm -vrf __pycache__/