#!/usr/bin/make -f # Sample debian/rules that uses debhelper. # GNU copyright 1997 to 1999 by Joey Hess. # # adapted by Logilab for automatic generation by debianize # (part of the devtools project, http://www.logilab.org/projects/devtools) # # Copyright (c) 2003-2011 LOGILAB S.A. (Paris, FRANCE). # http://www.logilab.fr/ -- mailto:contact@logilab.fr # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 include /usr/share/python/python.mk # don't build the python3 package if python3 is < 3.3 py3k = $(subst python3.,,$(shell py3versions -d)) build_py3k = $(shell test "$(py3k)" -gt 2 && echo 1) ifeq (,$(build_py3k)) DH_OPTIONS += -Npython3-logilab-mtconverter export DH_OPTIONS endif install-python%: python$* setup.py install --root=$(CURDIR)/debian/tmp --prefix=/usr override_dh_auto_install: $(foreach python, $(shell py3versions -r), install-$(python)) dh_auto_install rm -f debian/tmp/usr/lib/python*/*/logilab/__init__.py override_dh_auto_clean: dh_auto_clean rm -rf *.egg-info build %: dh $@ --with python2,python3