xnd-project / numba-xnd

Integrating xnd into numba
https://xnd.io/
5 stars 1 forks source link

Remove `CONDA_PREFIX` env variable dependency #15

Closed andersy005 closed 6 years ago

andersy005 commented 6 years ago

Fixes https://github.com/Quansight/numba-xnd/issues/14

saulshanabrook commented 6 years ago

I wonder why circle ci didn't run on this...

saulshanabrook commented 6 years ago

I'll try this locally. @pearu do you have any comments on this?

saulshanabrook commented 6 years ago

Thanks for this.

pearu commented 6 years ago

Using get_python_lib approach seems to be more robust than using CONDA_PREFIX indeed. It should work also in non-conda environment.

However, this issue illustrates another xnd packing/installation issue: libxnd.{a,so], libndtypes.{a,so}, libgumath.{a,so} are installed in two places, in <prefix>/lib and in <prefix>/python<vers>/site-packages/{xnd,ndtypes,gumath}. While perhaps practical during development, imho, the libraries should be installed only to <prefix>/lib, where setup.py can be configured to pick these up. Reasoning: right now these libraries are used by C and Python projects. Soon we will have Ruby support. It's not efficient to install three identical libraries for each target language. There will be more copies when installing different versions of the same language. IMHO, this is a potential source of confusion. Perhaps the above should be a separete issue...