From 2d0d0ba99b507cab093962cb910ddc7dd4755c94 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Sl=C3=A1vek=20Banko?= <slavek.banko@axis.cz>
Date: Tue, 27 Aug 2013 04:57:39 +0200
Subject: Switch to dh_python2 (or dh_pysupport as fallback) on Debian and
 Ubuntu

---
 ubuntu/maverick/libraries/python-trinity/debian/rules | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

(limited to 'ubuntu/maverick/libraries/python-trinity/debian/rules')

diff --git a/ubuntu/maverick/libraries/python-trinity/debian/rules b/ubuntu/maverick/libraries/python-trinity/debian/rules
index 67af8c2d8..d4dac70f3 100755
--- a/ubuntu/maverick/libraries/python-trinity/debian/rules
+++ b/ubuntu/maverick/libraries/python-trinity/debian/rules
@@ -31,6 +31,9 @@ endif
 PYTHONS := $(shell pyversions -vr debian/control)
 DBG_PYTHONS := $(shell pyversions -vd)
 
+DEB_PYTHON_SYSTEM = $(if $(wildcard /usr/bin/dh_python2),,pysupport)
+DH_PYTHON2 = $(if $(wildcard /usr/bin/dh_python2),dh_python2,dh_pysupport)
+
 GCCVER := $(shell gcc --version | sed -n '/^gcc (GCC)/s/.*(GCC) \(...\).*/\1/p')
 ifneq (,$(filter $(GCCVER),4.2 4.3))
         SPLIT=20
@@ -149,7 +152,7 @@ ifeq (,$(findstring -i, $(DH_OPTIONS)))
 endif
 	dh_compress -X.py -X.ui -X.dtd
 	dh_fixperms
-	DH_PYCENTRAL=nomove dh_pycentral
+	${DH_PYTHON2}
 	dh_installdeb
 	dh_shlibdeps -l /opt/trinity/lib
 	dh_gencontrol
-- 
cgit v1.2.1