summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile26
1 files changed, 9 insertions, 17 deletions
diff --git a/Makefile b/Makefile
index dd3c9c0..3cb04eb 100644
--- a/Makefile
+++ b/Makefile
@@ -1,21 +1,13 @@
-XI_BINARY=bin/xi
SOURCE=src
-xi: src/xi.py
- mkdir -p bin
- cd src && zip -r xi.zip *
- echo '#!/usr/bin/env python' | cat - src/xi.zip > ${XI_BINARY}
- rm src/xi.zip
- chmod +x ${XI_BINARY}
+PREFIX=/usr
+CONFDIR=/etc
-install: clean xi xipkg.conf default.conf
- mkdir -p $(DESTDIR)/etc/xipkg.d/
- mkdir -p $(DESTDIR)/usr/bin
- cp default.conf $(DESTDIR)/etc/xipkg.d/
- cp xipkg.conf $(DESTDIR)/etc/xipkg.conf
- rm -f $(DESTDIR)/usr/bin/xi
- cp bin/xi $(DESTDIR)/usr/bin/xipkg
- ln -s /usr/bin/xipkg $(DESTDIR)/usr/bin/xi
+install: install-config
+ install -m755 ${SOURCE}/xisync.sh ${DESTDIR}${PREFIX}/bin/xisync
-clean:
- rm -rf bin
+
+install-config:
+ mkdir -p $(DESTDIR)${CONFDIR}/xipkg.d/
+ cp default.conf $(DESTDIR)${CONFDIR}/xipkg.d/
+ cp xipkg.conf $(DESTDIR)${CONFDIR}/xipkg.conf