numexpr
numexpr copied to clipboard
Wrong separator for MKL libraries in setup.py?
This line https://github.com/pydata/numexpr/blob/b5271857db3ff3921ea1796da3d48ed56e5402f6/setup.py#L75 uses os.pathsep as a separator for MKL libraries. In my setup in the site.cfg I see
libraries=lapack,lapacke,blas,cblas
so the separator is a comma and the build fails. Once I patched setup.py to use commas instead of os.pathsep the build succeeded.
Without knowing what operating system you are using I can't provide useful feedback.
I am on Linux, so the path separator is a colon which is a wrong thing to use in the list of the libraries to give to the compiler. It interprets it as part of the libraries' names, so it thinks that the list is actually one long library name.
It seems that Numexpr has nothing to do with blas, cblas, and lapack. Actually we link to mkl because we want to utilize the VML library. In other words, we could leave that option to be mkl_rt, and that's enough. (not very sure)
And as we can see in the site.cfg.example, the comment reads: Please note that the valid os.pathsep is ; on Windows and : on Linux. If the user follow the instructions, then it won't be a big problem.
libraries should be comma-separated. But the linker is being invoked as if the comma-separated list is one file. This parsing diverges from numpy, which seems like a bug.