Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 3e4b0e8

Browse files
committed
Get OPT from the environment to build the CCSHARED command.
Fixes the problem reported in bug #438786.
1 parent 772747b commit 3e4b0e8

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

setup.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,8 +138,8 @@ def build_extensions(self):
138138
# unfortunately, distutils doesn't let us provide separate C and C++
139139
# compilers
140140
if compiler is not None:
141-
(ccshared,) = sysconfig.get_config_vars('CCSHARED')
142-
args['compiler_so'] = compiler + ' ' + ccshared
141+
(ccshared,opt) = sysconfig.get_config_vars('CCSHARED','OPT')
142+
args['compiler_so'] = compiler + ' ' + opt + ' ' + ccshared
143143
if linker_so is not None:
144144
args['linker_so'] = linker_so + ' -shared'
145145
self.compiler.set_executables(**args)

0 commit comments

Comments
 (0)