File tree 1 file changed +10
-2
lines changed
1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -18,13 +18,21 @@ def get_include(): # TODO
18
18
def __extra_compile_args ():
19
19
extra_compile_args = []
20
20
print ("Platform is " + platform .system ())
21
- if platform .system () == 'darwin' or 'macOS' :
21
+
22
+ if platform .system () == 'Darwin' :
22
23
extra_compile_args = ["-std=c++11" ]
23
24
else :
24
25
extra_compile_args = ["-fopenmp" , "-std=c++11" ]
25
26
return extra_compile_args
26
27
27
28
29
+ def __extra_link_args ():
30
+ extra_link_args = []
31
+ if platform .system () != 'Darwin' :
32
+ extra_link_args = ["-lgomp" , "-lm" , "-lrt" ]
33
+ return extra_link_args
34
+
35
+
28
36
sources_list = ['src/krbalancing.cpp' ]
29
37
30
38
kr_module = Extension ('krbalancing' ,
@@ -33,7 +41,7 @@ def __extra_compile_args():
33
41
# Path to eigen3 headers
34
42
get_include ()
35
43
],
36
- extra_link_args = [ "-lgomp" , "-lm" , "-lrt" ] ,
44
+ extra_link_args = __extra_link_args () ,
37
45
extra_compile_args = __extra_compile_args ()
38
46
)
39
47
You can’t perform that action at this time.
0 commit comments