This is an archive of the discontinued LLVM Phabricator instance.

[OCaml] Install dynamic libraries in 'stubdirs' directory
ClosedPublic

Authored by mgorny on Jul 28 2017, 7:06 AM.

Details

Summary

Install the OCaml dynamic libraries in the 'stubdirs' directory rather
than the llvm subdirectory in order to fix running executables created
by ocamlc. Otherwise, the executables fail to run being unable to locate
the libraries (unless the LLVM directory is explicitly added to
LD_LIBRARY_PATH).

The staging directories are not altered since they work for our
development setup anyway, and installing into two directories would
unnecessarily make the code more complex.

Diff Detail

Repository
rL LLVM

Event Timeline

mgorny created this revision.Jul 28 2017, 7:06 AM
whitequark edited edge metadata.Jul 28 2017, 12:58 PM

Otherwise, the executables fail to run being unable to locate
the libraries (unless the LLVM directory is explicitly added to
LD_LIBRARY_PATH).

Do you mean CAML_LD_LIBRARY_PATH?

I suppose both should work but I only tested with plain LD_LIBRARY_PATH.

whitequark accepted this revision.Jul 28 2017, 2:57 PM
This revision is now accepted and ready to land.Jul 28 2017, 2:57 PM
This revision was automatically updated to reflect the committed changes.
jpdeplaix edited edge metadata.Jul 29 2017, 7:39 AM

Is it possible to backport this to the 5.0 branch ?