#!/usr/bin/make -f # Sample debian/rules that uses debhelper. # GNU copyright 1997 to 1999 by Joey Hess. # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 # python version for which a pkg will be build PYVERS:=$(shell pyversions -r) ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS))) CFLAGS += -g endif ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS))) INSTALL_PROGRAM += -s endif build: build-stamp build-stamp: dh_testdir set -e; \ for py in $(PYVERS); do \ $$py setup.py build; done #/usr/bin/docbook-to-man debian/python-jabber.sgml > python-jabber.1 touch build-stamp jabber/__init__.py clean: dh_testdir dh_testroot -for py in $(PYVERS); do \ $$py setup.py clean --all; done find $(CURDIR) -name \*.pyc -exec rm -f {} \; find $(CURDIR) -name \*.pyo -exec rm -f {} \; rm -f build-stamp jabber/__init__.py rm -rf docs dh_clean install: build dh_testdir dh_testroot dh_clean -k dh_installdirs -v set -e; \ for py in $(PYVERS); do \ $$py setup.py install --root=debian/python-jabber; \ done # Build architecture-independent files here. binary-indep: build install # We have nothing to do by default. dh_testdir -i dh_testroot -i # Decode some imgs for html docs install -d $(CURDIR)/docs/img/ install -d $(CURDIR)/docs/docs/ uudecode -o $(CURDIR)/docs/img/logo-56-80.png \ $(CURDIR)/debian/img/logo-56-80.png.b64 uudecode -o $(CURDIR)/docs/img/jabber-powered-20.png \ $(CURDIR)/debian/img/jabber-powered-20.png.b64 install -m 0644 $(CURDIR)/debian/jabber.html \ $(CURDIR)/debian/xmlstream.html \ $(CURDIR)/docs/docs/ dh_installdocs -i dh_installexamples -i dh_installchangelogs -i dh_link -i dh_compress -i -X.py -X.xpm dh_fixperms -i dh_python2 -i dh_installdeb -i dh_shlibdeps -i dh_gencontrol -i dh_md5sums -i dh_builddeb -i # Build architecture-dependent files here. binary-arch: build install binary: binary-indep binary-arch .PHONY: build clean binary-indep binary-arch binary install