File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -71,13 +71,20 @@ class BuildExt(build_ext):
71
71
'msvc' : ['/EHsc' ],
72
72
'unix' : [],
73
73
}
74
+ l_opts = {
75
+ 'msvc' : [],
76
+ 'unix' : [],
77
+ }
74
78
75
79
if sys .platform == 'darwin' :
76
- c_opts ['unix' ] += ['-stdlib=libc++' , '-mmacosx-version-min=10.7' ]
80
+ darwin_opts = ['-stdlib=libc++' , '-mmacosx-version-min=10.7' ]
81
+ c_opts ['unix' ] += darwin_opts
82
+ l_opts ['unix' ] += darwin_opts
77
83
78
84
def build_extensions (self ):
79
85
ct = self .compiler .compiler_type
80
86
opts = self .c_opts .get (ct , [])
87
+ link_opts = self .l_opts .get (ct , [])
81
88
if ct == 'unix' :
82
89
opts .append ('-DVERSION_INFO="%s"' % self .distribution .get_version ())
83
90
opts .append (cpp_flag (self .compiler ))
@@ -87,6 +94,7 @@ def build_extensions(self):
87
94
opts .append ('/DVERSION_INFO=\\ "%s\\ "' % self .distribution .get_version ())
88
95
for ext in self .extensions :
89
96
ext .extra_compile_args = opts
97
+ ext .extra_link_args = link_opts
90
98
build_ext .build_extensions (self )
91
99
92
100
setup (
You can’t perform that action at this time.
0 commit comments