summaryrefslogtreecommitdiffstats
path: root/Lib/distutils/command
diff options
context:
space:
mode:
authorAntoine Pitrou <solipsis@pitrou.net>2013-09-28 23:49:07 (GMT)
committerAntoine Pitrou <solipsis@pitrou.net>2013-09-28 23:49:07 (GMT)
commit61e10a5efe4c41602eddf0f7f3bf1b6c96569f6d (patch)
tree517e79b7131402da560ea703c4b603305aa7f37f /Lib/distutils/command
parentb3b07205979f8cd33707365027d8958c6c525171 (diff)
parent643238eb53805bc77148adbca83cd22e34d8aeba (diff)
downloadcpython-61e10a5efe4c41602eddf0f7f3bf1b6c96569f6d.zip
cpython-61e10a5efe4c41602eddf0f7f3bf1b6c96569f6d.tar.gz
cpython-61e10a5efe4c41602eddf0f7f3bf1b6c96569f6d.tar.bz2
Issue #4366: Fix building extensions on all platforms when --enable-shared is used.
Diffstat (limited to 'Lib/distutils/command')
-rw-r--r--Lib/distutils/command/build_ext.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/Lib/distutils/command/build_ext.py b/Lib/distutils/command/build_ext.py
index a6aad53..80689b6 100644
--- a/Lib/distutils/command/build_ext.py
+++ b/Lib/distutils/command/build_ext.py
@@ -242,11 +242,10 @@ class build_ext(Command):
# building python standard extensions
self.library_dirs.append('.')
- # for extensions under Linux or Solaris with a shared Python library,
+ # For building extensions with a shared Python library,
# Python's library directory must be appended to library_dirs
- sysconfig.get_config_var('Py_ENABLE_SHARED')
- if (sys.platform.startswith(('linux', 'gnu', 'sunos'))
- and sysconfig.get_config_var('Py_ENABLE_SHARED')):
+ # See Issues: #1600860, #4366
+ if (sysconfig.get_config_var('Py_ENABLE_SHARED')):
if sys.executable.startswith(os.path.join(sys.exec_prefix, "bin")):
# building third party extensions
self.library_dirs.append(sysconfig.get_config_var('LIBDIR'))