summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile24
1 files changed, 18 insertions, 6 deletions
diff --git a/Makefile b/Makefile
index 9b3385e..2797e9c 100644
--- a/Makefile
+++ b/Makefile
@@ -1,12 +1,24 @@
-all: activity.html
+LUAVERSION?=5.4
+PREFIX?=/usr/local
+BINDIR=$(PREFIX)/bin
+LIBDIR=$(PREFIX)/lib
+DATADIR=$(PREFIX)/share
+LUADIR=$(DATADIR)/lua/$(LUAVERSION)
-%.html: generate.lua activity.lua
- lua generate.lua >$@
+all:
+ @echo Nothing to be built
-clean:
- rm -f *.html
+install:
+ install -m644 -Dt $(DESTDIR)$(LUADIR) activity.lua
+ install -m644 -Dt $(DESTDIR)$(LUADIR)/activity activity/*.lua
+ install -m644 -Dt $(DESTDIR)$(LUADIR)/activity/formats activity/formats/*.lua
+ install -m655 -Dt $(DESTDIR)$(BINDIR) generate.lua
+
+uninstall:
+ rm -rf $(DESTDIR)$(LUADIR)/activity
+ rm -f $(DESTIR)$(BINDIR)/generate.lua
test:
busted
-.PHONY: all clean test
+.PHONY: all install uninstall test