py-pillow: ensure that RPATH includes graphics libraries#4522
py-pillow: ensure that RPATH includes graphics libraries#4522adamjstewart merged 1 commit intospack:developfrom
Conversation
|
I'm glad that this package has an explicit Python packages have 2 problems. Non-Python dependencies aren't being RPATHed properly (as you've noted). See numpy/numpy#8653 for an arguably more important version of this same problem. I am unable to install A second problem is that Python dependencies aren't in @citibeth and @wscullin might be interested in this conversation as well. Until a more general solution is devised, I'm going to merge this PR as is. |
|
Adam,
The RPATH solution here looks pretty general. Is this something we could
put into PythonPackage? I'm not up on what build_ext_args() is/does.
I am unable to install py-scipy with Spack with Intel MKL because mkl
isn't being RPATHed properly when py-numpy is built (even though site.cfg
is supposed to have an explicit rpath option).
You need to `module load` pi-scipy and all its dependencies. `spack module
loads -r` can generate this list.
A second problem is that Python dependencies aren't in sys.path unless
they are explicitly added to PYTHONPATH. This means that binaries like
sphinx-build and flake8 aren't usable unless all of their dependencies
are module loaded as well. There are ways to get around this problem (spack
activate, recursive module loading) but neither are ideal.
Yes, `spack module loads` is not ideal. But boy does it work. Talk of
Spack Environments will make this feel better / more integrated.
|
Unfortunately this won't work. I can't even install |
|
I've had no problems installing *py-scipy*. Maybe something has changed in
Spack that breaks it?
|
|
It depends on what compiler/BLAS/LAPACK you use. I can build with GCC and OpenBLAS but not Intel and Intel MKL. |
|
OK that makes sense, I've only tried with GCC.
…On Fri, Jun 16, 2017 at 12:52 PM, Adam J. Stewart ***@***.***> wrote:
It depends on what compiler/BLAS/LAPACK you use. I can build with GCC and
OpenBLAS but not Intel and Intel MKL.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#4522 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AB1cd2OC9prtgKURSmDhaUF9HfM2DrLGks5sErLQgaJpZM4N77DA>
.
|
|
Hi @adamjstewart , I'd be interested to know what would happen if you built python without replacing the spack wrappers in the configuration files. That is, comment out the |
|
That would be nice, but the Spack compiler wrappers can't be used outside of Spack. So I think it would mean that all pip installations would fail. I would have to test it though |
|
Thanks for starting work on #4545, @adamjstewart . For the record, my idea here was to build python using a fake compiler consisting of a wrapper around the spack wrappers. The outer wrapper would set environment variables equivalent to Let's see how #4545 unfolds. We can revisit this "double wrapper" idea if necessary. |
After installing py-pillow, the jpeg library was not detected when converting images. After setting RPATH explicitly during package installation, image conversions worked as expected.
This is the second RPATH problem I have had today with python packages. The problem could be resolved by using the spack compiler wrappers for package installation, but python is configured to use the real compilers (by the
filter_compilersmethod of thepythonpackage). This makes it easier for users to install packages without spack, but it causes problems when installing packages with spack. Perhaps it would be better to configure python to use a generic compiler (e.g. gcc) so that the actual compiler can be specified through environment variables (set by environment modules or spack).