ocamlPackages.findlib: automatically populate the CAML_LD_LIBRARY_PATH env. variable

With directories of the form:
  lib/ocaml/${ocaml.version}/site-lib/stubslibs
wip/yesman
Vincent Laporte 6 years ago committed by Vincent Laporte
parent 2455478754
commit 387d791663
  1. 3
      pkgs/development/tools/ocaml/findlib/default.nix

@ -39,6 +39,9 @@ stdenv.mkDerivation rec {
if test -d "''$1/lib/ocaml/${ocaml.version}/site-lib"; then
export OCAMLPATH="''${OCAMLPATH}''${OCAMLPATH:+:}''$1/lib/ocaml/${ocaml.version}/site-lib/"
fi
if test -d "''$1/lib/ocaml/${ocaml.version}/site-lib/stubslibs"; then
export CAML_LD_LIBRARY_PATH="''${CAML_LD_LIBRARY_PATH}''${CAML_LD_LIBRARY_PATH:+:}''$1/lib/ocaml/${ocaml.version}/site-lib/stubslibs"
fi
export OCAMLFIND_DESTDIR="''$out/lib/ocaml/${ocaml.version}/site-lib/"
if test -n "$createFindlibDestdir"; then
mkdir -p $OCAMLFIND_DESTDIR

Loading…
Cancel
Save