[Python-checkins] cpython: Issue #27434: Version of interpreter running a cross-build and source version

xavier.degaye python-checkins at python.org
Thu Jul 7 12:01:17 EDT 2016


https://hg.python.org/cpython/rev/62802d373e9f
changeset:   102282:62802d373e9f
user:        Xavier de Gaye <xdegaye at users.sourceforge.net>
date:        Thu Jul 07 18:00:22 2016 +0200
summary:
  Issue #27434: Version of interpreter running a cross-build and source version must be the same.

files:
  Misc/NEWS    |  3 +++
  configure    |  2 +-
  configure.ac |  2 +-
  3 files changed, 5 insertions(+), 2 deletions(-)


diff --git a/Misc/NEWS b/Misc/NEWS
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -132,6 +132,9 @@
 Build
 -----
 
+- Issue #27434: The interpreter that runs the cross-build, found in PATH, must
+  now be of the same feature version (e.g. 3.6) as the source being built.
+
 - Issue #26930: Update Windows builds to use OpenSSL 1.0.2h.
 
 - Issue #23968: Rename the platform directory from plat-$(MACHDEP) to
diff --git a/configure b/configure
--- a/configure
+++ b/configure
@@ -3002,7 +3002,7 @@
     if test -z "$PYTHON_FOR_BUILD"; then
         for interp in python$PACKAGE_VERSION python3 python; do
 	    which $interp >/dev/null 2>&1 || continue
-	    if $interp -c 'import sys;sys.exit(not sys.version_info[:2] >= (3,3))'; then
+	    if $interp -c "import sys;sys.exit(not '.'.join(str(n) for n in sys.version_info[:2]) == '$PACKAGE_VERSION')"; then
 	        break
 	    fi
             interp=
diff --git a/configure.ac b/configure.ac
--- a/configure.ac
+++ b/configure.ac
@@ -62,7 +62,7 @@
     if test -z "$PYTHON_FOR_BUILD"; then
         for interp in python$PACKAGE_VERSION python3 python; do
 	    which $interp >/dev/null 2>&1 || continue
-	    if $interp -c 'import sys;sys.exit(not sys.version_info@<:@:2@:>@ >= (3,3))'; then
+	    if $interp -c "import sys;sys.exit(not '.'.join(str(n) for n in sys.version_info@<:@:2@:>@) == '$PACKAGE_VERSION')"; then
 	        break
 	    fi
             interp=

-- 
Repository URL: https://hg.python.org/cpython


More information about the Python-checkins mailing list