From 0d64bff5d86ce49e6b1d48efb897ed0dc14bed63 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Piotr=20O=C5=BCarowski?= <piotr@debian.org>
Date: Tue, 31 Aug 2010 19:17:45 +0200
Subject: [PATCH] Set the right minimum required python package version in
 packages with private modules

---
 debian/changelog     | 6 ++++--
 debpython/depends.py | 4 +++-
 2 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index f2bebec..fb7f2c0 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,9 +1,11 @@
-python-defaults (2.6.6-1) UNRELEASED; urgency=low
+python-defaults (2.6.6-1) unstable; urgency=low
 
   [ Piotr Ożarowski ]
   * dh_python2: typo in --help output fixed (thanks to Adam D. Barratt)
   * Bump python-minimal's Breaks of python2.5-minimal to << 2.5.5-7 (due to
     missing runpy module)
+  * Set the right minimum required python package version in packages with
+    private modules
 
   [ Scott Kitterman ]
   * debian/python-policy.sgml and debian/pyversions.py fix typos (thanks to
@@ -12,7 +14,7 @@ python-defaults (2.6.6-1) UNRELEASED; urgency=low
   [ Matthias Klose ]
   * Bump version to 2.6.6.
 
- -- Matthias Klose <doko@debian.org>  Tue, 24 Aug 2010 20:03:26 +0200
+ -- Piotr Ożarowski <piotr@debian.org>  Tue, 31 Aug 2010 19:09:30 +0200
 
 python-defaults (2.6.5-13) unstable; urgency=low
 
diff --git a/debpython/depends.py b/debpython/depends.py
index 0c9cb55..1db3ed3 100644
--- a/debpython/depends.py
+++ b/debpython/depends.py
@@ -23,6 +23,7 @@ import logging
 from debpython.pydist import parse_pydep, guess_dependency
 from debpython.version import SUPPORTED, DEFAULT, debsorted, vrepr, vrange_str
 
+MINPYCDEP = 'python (>= 2.6.5-11~)'  # minumum version required for pycompile
 log = logging.getLogger('dh_python')
 
 
@@ -119,7 +120,7 @@ class Dependencies(object):
 
         # make sure pycompile binary is available
         if stats['compile']:
-            self.depend("python (>= 2.6.5-11~)")
+            self.depend(MINPYCDEP)
 
         for interpreter, version in stats['shebangs']:
             self.depend(interpreter)
@@ -135,6 +136,7 @@ class Dependencies(object):
                 # TODO: if versions[0] not in requested_versions: FTBFS
             elif details.get('compile', False):
                 # no hardcoded versions, but there's something to compile
+                self.depend(MINPYCDEP)
                 args = ''
                 vr = options.vrange
                 if vr:
-- 
GitLab