-
-
Notifications
You must be signed in to change notification settings - Fork 80
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
Look for libraries in the LD_LIBRARY_PATH #1
Comments
I created the branch In particular, an empty This originates from sequences of the form ":path", "path:", and "path::path" in the respective environment variables. Please test and tell me if it is fixed now for your setups. |
It works for me now! |
That's very good news! Now, should we keep this version or the one with the paths specified in the script? Or a mixture of both? The one you are testing now should work with the dependencies installed either in a system path, or in a path included in the respective variables. This requires that the user actually uses these variables. The one in the master branch should work always, but requires the user to edit the script. A mixture could use both pahts. But in which order? |
I can confirm that the Boost is installed in a non-standard path, with environment variables set, yaml-cpp is installed by the package manager. |
Thank you for testing this! I actually think we should keep this version only, since eitherways all the dependencies should be in some system-wide library paths also at runtime. What I mean: if a user e.g. installs yaml-cpp from source in a non-standard directory and specifies the paths in the script, but not in LD_LIBRARY_PATH, then the adapter will compile, but it will not run. Actually, the |
When building the adapter with preCICE as a static library, the paths for Boost and PETSc (and maybe also other dependencies in some cases) need to be set manually in the build script. However, some users already have these paths set in their
LD_LIBRARY_PATH
orLIBRARY_PATH
and they should not need to specify them again. Moreover, this could lead into linking to the wrong version of a library, if multiple are installed.We use the wmake build system, which is provided with OpenFOAM. However, this does not search directories like the
LIBRARY_PATH
,LD_LIBRARY_PATH
orCPLUS_INCLUDE_PATH
, as is described in this issue. One way to search them would be to add these directories in theLIB_LIBS
andEXE_INC
(for header files) of theMake/options
file.In the state of the adapter at commit e70e06c we had added these paths in the
LIB_LIBS
. However, for some users this triggered errors during linking:We need to investigate this issue further. Since it was always working for me, I need some help to reproduce the error or locate the problem.
The text was updated successfully, but these errors were encountered: