X-Git-Url: https://vcs.maemo.org/git/?a=blobdiff_plain;f=Makefile;h=07af6fc1263d2deadc01c2f8fe4a9f1501dd222f;hb=401ac7f22d9a3ae4205ef7c3b6736d70d33180ab;hp=8098d0d093f7ea8fee660b5055dbffac78d52a75;hpb=509d8f891031a8637fa08bff1a61526ff6c4c6d4;p=dbuscron diff --git a/Makefile b/Makefile index 8098d0d..07af6fc 100644 --- a/Makefile +++ b/Makefile @@ -3,6 +3,7 @@ DESTDIR ?= PYMODULES ?= $(DESTDIR)/usr/lib/pymodules/python2.5 PREFIX ?= $(DESTDIR)/usr/bin PYSUFFIX = `test -e ./dbuscron/__init__.pyo && echo pyo || echo pyc` +PYVERSION ?= 2.5 all: @echo "No compilation needed." @@ -11,10 +12,11 @@ install: install -o root -g root -m 0755 ./dbuscron.py $(PREFIX)/dbuscron install -o root -g root -m 0755 ./dbuscrontab.py $(PREFIX)/dbuscrontab install -o root -g root -m 0755 -d $(PYMODULES)/dbuscron - python -c 'import dbuscron' + python$(PYVERSION) -O -c 'import dbuscron' install -o root -g root -m 0644 ./dbuscron/*.$(PYSUFFIX) $(PYMODULES)/dbuscron install -o root -g root -m 0644 ./event.d/dbuscron $(DESTDIR)/etc/event.d/dbuscron - touch $(DESTDIR)/etc/dbuscrontab + -test ! -f $(DESTDIR)/etc/dbuscrontab && \ + install -o root -g root -m 0644 ./doc/dbuscrontab $(DESTDIR)/etc/dbuscrontab @echo "Installation complete. Run \`dbuscrontab -e' to edit config file," @echo "then run \`initctl start dbuscron' to start dbuscron daemon." @@ -25,5 +27,7 @@ uninstall: rm -f $(DESTDIR)/etc/event.d/dbuscron clean: - find . -name "*.py[co]" | xargs rm -f + find ./dbuscron -name "*.py[co]" | xargs rm -f + +.PHONY: all install uninstall clean