summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile24
1 files changed, 24 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..2a462d7
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,24 @@
+FNLSOURCES = core.fnl
+LUASOURCES = $(FNLSOURCES:.fnl=.lua)
+
+all: cljlib.lua
+
+.PHONY: all clean help test
+
+cljlib.lua: test $(LUASOURCES)
+ mv core.lua cljlib.lua
+
+%.lua: %.fnl
+ fennel --compile $^ > $@
+
+clean:
+ rm -f *.lua
+
+test:
+ @fennel core_test.fnl
+ @fennel macros_test.fnl
+
+help:
+ @echo "make -- run tests and create lua library"
+ @echo "make test -- run tests"
+ @echo "make clean -- remove lua files"