diff --git a/debian/changelog b/debian/changelog index 66c4b6181120a65126c03e7496fdb2ad6e0e105b..16f3fb59f6159f00637d0fa941cb6cfd3130dbc4 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +python-defaults (2.6.6-5) experimental; urgency=low + + * pycompile: if installed Python is requested via -V option, use it even if + it's not in a list of supported Python versions (closes: 600529) + + -- Piotr Ożarowski <piotr@debian.org> Sun, 17 Oct 2010 23:22:22 +0200 + python-defaults (2.6.6-4) experimental; urgency=low * Add python2.7 as a supported Python version. diff --git a/pycompile b/pycompile index b1ff118bd00efe41501c7bea8994a14b44c1a89e..bcef097f1bb84a66b96ed3339e8f9041ec638651 100755 --- a/pycompile +++ b/pycompile @@ -235,7 +235,12 @@ multiple times to build up a list of things to exclude.') 'only, please use /usr/share/python/bcep to specify ' 'public modules to skip') - versions = get_requested_versions(options.vrange, available=True) + if options.vrange and options.vrange[0] == options.vrange[1] and\ + exists("/usr/bin/python%d.%d" % options.vrange[0]): + # specific version requested, use it even if it's not in SUPPORTED + versions = set(options.vrange[:1]) + else: + versions = get_requested_versions(options.vrange, available=True) if not versions: log.error('Requested versions are not installed') exit(3)