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
rpath + finding 3rd party C-libraries #3202
Comments
Comment author: administrator
I second Jacques' suggestion: either the C library is useful by
It makes me nervous to modify LD_LIBRARY_PATH from within the bytecode Cheers,
|
Comment author: administrator On Wed, 13 Feb 2002, Jacques Garrigue wrote:
Unfortunately, this only works if the user has root privileges.
That's the way I currently solve this problem. I noticed that users have
This would require some awful hacks. I don't want to interfere too On Wed, 13 Feb 2002, Xavier Leroy wrote:
I had feared that you don't like this "runtime patching" of I'll therefore stay with the current solution (hardwire the path in Cheers, -- |
Comment author: administrator From: markus@oefai.at
The problem is that these libraries are loaded by ld.so, not by ocaml, Since these are C libraries, the reasonnable thing to do seems to put A third solution is to link the whole library with the stubs. This may Jacques Garrigue Kyoto University garrigue at kurims.kyoto-u.ac.jp |
Comment author: administrator Basically, a C DLL install issue. Not much we can do about it. |
Original bug ID: 887
Reporter: administrator
Status: closed
Resolution: not a bug
Priority: normal
Severity: minor
Category: ~DO NOT USE (was: OCaml general)
Bug description
Hello,
sometimes it is necessary to install 3rd party C-libraries for some
OCaml-project. If I want to use shared libraries for this purpose,
the question arises how the loader can find those C-libraries if they
are not installed in a standard place (e.g. /usr/lib) but reside in
some OCaml-directory.
Would it be possible and useful to automatically add the directory of
dynamic OCaml-libraries "dll*.so" to the search path "LD_LIBRARY_PATH"
before "dlopen" so that required, locally installed C-libraries can
be found?
E.g.:
ocaml/
...
contrib/
...
dllpcre.so
libpcre.so.0
...
If I don't use the rpath-directive during linking, "libpcre.so.0", which
is required by "dllpcre.so", cannot be found, even though "-I +contrib"
finds "dllpcre.so". This is especially bad when the installation
directory or library is moved (maybe resides on a different filesystem)
and if we don't want the user to mess around with "LD_LIBRARY_PATH"
or even recompile the library.
Maybe you know an even better solution to the problem?
Regards,
Markus Mottl
--
Markus Mottl markus@oefai.at
Austrian Research Institute
for Artificial Intelligence http://www.oefai.at/~markus
The text was updated successfully, but these errors were encountered: