X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=Makefile;h=df1d311b718630897780f5f621bd652a5fefb8f0;hb=394178168c700cc719ca5d584138d0db02f7d4dd;hp=855f3462afb6e60a32df438edb0cf8046ead27fe;hpb=637a4cecf5383c8b43260865dd946dcf822186e5;p=sfa.git diff --git a/Makefile b/Makefile index 855f3462..df1d311b 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,7 @@ # # overwritten by the specfile DESTDIR="/" - +PREFIX=/usr ########## all: python wsdl @@ -29,16 +29,16 @@ sfa/util/version.py: sfa/util/version.py.in sed -e "s,@VERSIONTAG@,$(VERSIONTAG),g" -e "s,@SCMURL@,$(SCMURL),g" sfa/util/version.py.in > $@ xmlbuilder-install: - cd xmlbuilder-0.9 && python setup.py install --root=$(DESTDIR) && cd - + cd xmlbuilder-0.9 && python setup.py install --prefix=$(PREFIX) --root=$(DESTDIR) && cd - rm -rf $(DESTDIR)/usr/lib*/python*/site-packages/*egg-info # postinstall steps - various cleanups and tweaks for a nicer rpm python-install: - python setup.py install --root=$(DESTDIR) + python setup.py install --prefix=$(PREFIX) --root=$(DESTDIR) chmod 444 $(DESTDIR)/etc/sfa/default_config.xml rm -rf $(DESTDIR)/usr/lib*/python*/site-packages/*egg-info rm -rf $(DESTDIR)/usr/lib*/python*/site-packages/sfa/storage/migrations - (cd $(DESTDIR)/usr/bin ; ln -s sfi.py sfi; ln -s sfascan.py sfascan) + (cd $(DESTDIR)/usr/bin ; ln -s sfi.py sfi; ln -s sfascan.py sfascan; ln -s sfaadmin.py sfaadmin) python-clean: version-clean python setup.py clean @@ -61,6 +61,12 @@ wsdl-clean: .PHONY: wsdl wsdl-install wsdl-clean +########## +debian: version + $(MAKE) -f Makefile.debian debian +debian.clean: + $(MAKE) -f Makefile.debian clean + ########## tests-install: mkdir -p $(DESTDIR)/usr/share/sfa/tests @@ -144,15 +150,17 @@ RSYNC_EXCLUDES := --exclude .svn --exclude .git --exclude '*~' --exclude TAGS $ RSYNC_COND_DRY_RUN := $(if $(findstring n,$(MAKEFLAGS)),--dry-run,) RSYNC := rsync -a -v $(RSYNC_COND_DRY_RUN) --no-owner $(RSYNC_EXCLUDES) -CLIENTS = $(shell ls sfa/clientbin/*.py) +CLIENTS = $(shell ls clientbin/*.py) BINS = ./config/sfa-config-tty ./config/gen-sfa-cm-config.py \ ./sfa/server/sfa-start.py \ - ./sfa/clientbin/sfaadmin.py \ + ./clientbin/sfaadmin.py \ $(CLIENTS) synclib: synccheck +$(RSYNC) --relative ./sfa/ --exclude migrations $(SSHURL)/usr/lib\*/python2.\*/site-packages/ +synclibdeb: synccheck + +$(RSYNC) --relative ./sfa/ --exclude migrations $(SSHURL)/usr/share/pyshared/ syncbin: synccheck +$(RSYNC) $(BINS) $(SSHURL)/usr/bin/ syncinit: synccheck @@ -170,6 +178,7 @@ syncmig: # full-fledged sync: synclib syncbin syncinit syncconfig syncrestart +syncdeb: synclibdeb syncbin syncinit syncconfig syncrestart # 99% of the time this is enough syncfast: synclib syncrestart