summaryrefslogtreecommitdiffstats
path: root/Lib/distutils/command/build_ext.py
diff options
context:
space:
mode:
authorTarek Ziadé <ziade.tarek@gmail.com>2009-02-05 22:52:52 (GMT)
committerTarek Ziadé <ziade.tarek@gmail.com>2009-02-05 22:52:52 (GMT)
commit0d4fd3493eb95a49ac0dee5c8607b1426432ab83 (patch)
tree1ae0fa194986df7a9ceda3092f93d8d39e465c88 /Lib/distutils/command/build_ext.py
parent38870cb432687b62a660bd18cc43ac66882ce869 (diff)
downloadcpython-0d4fd3493eb95a49ac0dee5c8607b1426432ab83.zip
cpython-0d4fd3493eb95a49ac0dee5c8607b1426432ab83.tar.gz
cpython-0d4fd3493eb95a49ac0dee5c8607b1426432ab83.tar.bz2
Fixed #5132: enable extensions to link on Solaris
Diffstat (limited to 'Lib/distutils/command/build_ext.py')
-rw-r--r--Lib/distutils/command/build_ext.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/Lib/distutils/command/build_ext.py b/Lib/distutils/command/build_ext.py
index fbf2a0b..2ed3ef6 100644
--- a/Lib/distutils/command/build_ext.py
+++ b/Lib/distutils/command/build_ext.py
@@ -231,10 +231,12 @@ class build_ext (Command):
# building python standard extensions
self.library_dirs.append('.')
- # for extensions under Linux with a shared Python library,
+ # for extensions under Linux or Solaris with a shared Python library,
# Python's library directory must be appended to library_dirs
- if (sys.platform.startswith('linux') or sys.platform.startswith('gnu')) \
- and sysconfig.get_config_var('Py_ENABLE_SHARED'):
+ sysconfig.get_config_var('Py_ENABLE_SHARED')
+ if ((sys.platform.startswith('linux') or sys.platform.startswith('gnu')
+ or sys.platform.startswith('sunos'))
+ and 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'))