New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LD_LIBRARY_PATH not passed to package build? #697

Closed
bilke opened this Issue Jun 4, 2015 · 3 comments

Comments

Projects
None yet
2 participants
@bilke

bilke commented Jun 4, 2015

I am on CentOS and use the The Environment Modules package. I load all dependencies of MXE via module load ... Now when I try to build MXE the first package which gets build is pkgconf and that fails because the compiler did not run because a shared library could not be loaded:

Failed to build package pkgconf!
------------------------------------------------------------
checking whether the C compiler works... no
configure: error: in `/gpfs0/home/jenkins/mxe/tmp-pkgconf-x86_64-w64-mingw32.static/pkgconf-pkgconf-da179fd':
configure: error: C compiler cannot create executables
See `config.log' for more details

In tmp-pkgconf-x86_64-w64-mingw32.static/pkgconf-pkgconf-da179fd/config.log:

configure:2281: gcc    conftest.c  >&5
/gpfs0/global/local/gcc/4.8.1-3_CentOS6/bin/../libexec/gcc/x86_64-unknown-linux-gnu/4.8.1/cc1: 
error while loading shared libraries: libcloog-isl.so.4: cannot open shared object file: No such
file or directory
configure:2285: $? = 1
configure:2323: result: no

Maybe the environment is not passed to subsequent calls in MXEs build system. When I manually invoke ./configure and make in ``tmp-pkgconf-x86_64-w64-mingw32.static/pkgconf-pkgconf-da179fd` everything builds fine.

Do you have any suggestions?

@TimothyGu

This comment has been minimized.

Member

TimothyGu commented Jun 4, 2015

Maybe the environment is not passed to subsequent calls in MXEs build system.

I believe this is correct. We intentionally whitelist environment variables that are allowed in the build system: https://github.com/mxe/mxe/blob/master/Makefile#L128

You can try to patch it out like this:

-ENV_WHITELIST := PATH LANG MAKE% MXE% %PROXY %proxy
+ENV_WHITELIST := PATH LD_LIBRARY_PATH LANG MAKE% MXE% %PROXY %proxy
@bilke

This comment has been minimized.

bilke commented Jun 5, 2015

Thank you! Adding LD_LIBRARY_PATH to the ENV_WHITELIST-variable works for me. What is the reason for not passing this variable?

@bilke

This comment has been minimized.

bilke commented Jun 5, 2015

One more thing: To build hdf5 I had to add ACLOCAL_PATH to the whitelist variable as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment