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 2424with open (os .path .join (ROOT , 'README.md' ), encoding = "utf-8" ) as f :
2525 README = f .read ()
2626
27+ # add platform dependant optional compilation argument
28+ opt_arg = ["-O3" ]
29+ import platform
30+ if platform .system ()== 'Darwin' :
31+ if platform .release ()== '18.0.0' :
32+ opt_arg .append ("-stdlib=libc++" ) # correspond to a compilation problem with Mojave and XCode 10
2733
2834setup (name = 'POT' ,
2935 version = __version__ ,
3945 sources = ["ot/lp/emd_wrap.pyx" , "ot/lp/EMD_wrapper.cpp" ], # the Cython source and
4046 # additional C++ source files
4147 language = "c++" , # generate and compile C++ code,
42- include_dirs = [numpy .get_include (),os .path .join (ROOT ,'ot/lp' )])),
48+ include_dirs = [numpy .get_include (),os .path .join (ROOT ,'ot/lp' )],
49+ extra_compile_args = opt_arg
50+ )),
4351 platforms = ['linux' ,'macosx' ,'windows' ],
4452 download_url = 'https://github.com/rflamary/POT/archive/{}.tar.gz' .format (__version__ ),
4553 license = 'MIT' ,
You can’t perform that action at this time.
0 commit comments