]> granicus.if.org Git - python/commitdiff
Issue #28918: Fix the cross compilation of xxlimited when Python
authorXavier de Gaye <xdegaye@users.sourceforge.net>
Sat, 10 Dec 2016 15:45:53 +0000 (16:45 +0100)
committerXavier de Gaye <xdegaye@users.sourceforge.net>
Sat, 10 Dec 2016 15:45:53 +0000 (16:45 +0100)
has been built with Py_DEBUG defined.

Misc/NEWS
setup.py

index ef0d96041fb23291ec1c5be708c34378ab95d291..587c4d24bd58e5594e34a5f271bd893e0928bcaf 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -10,6 +10,9 @@ What's New in Python 3.6.1 release candidate 1
 Core and Builtins
 -----------------
 
+- Issue #28918: Fix the cross compilation of xxlimited when Python has been
+  built with Py_DEBUG defined.
+
 - Issue #28731: Optimize _PyDict_NewPresized() to create correct size dict.
   Improve speed of dict literal with constant keys up to 30%.
 
index af9a414f7d7760e54e015d30e2e1f4153df66b83..116f06fb224bffb37f175fcfc504d2469c16a2ca 100644 (file)
--- a/setup.py
+++ b/setup.py
@@ -1630,7 +1630,7 @@ class PyBuildExt(build_ext):
 ##         ext = Extension('xx', ['xxmodule.c'])
 ##         self.extensions.append(ext)
 
-        if 'd' not in sys.abiflags:
+        if 'd' not in sysconfig.get_config_var('ABIFLAGS'):
             ext = Extension('xxlimited', ['xxlimited.c'],
                             define_macros=[('Py_LIMITED_API', '0x03050000')])
             self.extensions.append(ext)