# HG changeset patch # User wenzelm # Date 1553247410 -3600 # Node ID a591de17993141b8b506d0f719cd8fcd1dee4164 # Parent ab8aad4aa76e11e15da6b17a10de5e0cfa93eefc even more robust and conservative OCaml setup; diff -r ab8aad4aa76e -r a591de179931 lib/Tools/ocaml_setup --- a/lib/Tools/ocaml_setup Thu Mar 21 19:46:26 2019 +0100 +++ b/lib/Tools/ocaml_setup Fri Mar 22 10:36:50 2019 +0100 @@ -6,11 +6,14 @@ set -e -if [ -e "$ISABELLE_OPAM_ROOT/config" ] +if [ -d "$ISABELLE_OPAM_ROOT/$ISABELLE_OCAML_VERSION/bin" ] then - isabelle_opam switch reinstall -y "$ISABELLE_OCAML_VERSION" + isabelle_opam switch -y "$ISABELLE_OCAML_VERSION" +elif [ -e "$ISABELLE_OPAM_ROOT/config" ] +then + isabelle_opam switch create -y "$ISABELLE_OCAML_VERSION" else isabelle_opam init -y --disable-sandboxing --no-setup --compiler="$ISABELLE_OCAML_VERSION" fi -isabelle_opam install zarith -y +isabelle_opam install -y zarith diff -r ab8aad4aa76e -r a591de179931 lib/scripts/ocamlfind --- a/lib/scripts/ocamlfind Thu Mar 21 19:46:26 2019 +0100 +++ b/lib/scripts/ocamlfind Fri Mar 22 10:36:50 2019 +0100 @@ -4,7 +4,7 @@ # # Invoke ocamlfind via "opam". -if [ -e "$ISABELLE_OPAM_ROOT/config" ] +if [ -d "$ISABELLE_OPAM_ROOT/$ISABELLE_OCAML_VERSION/bin" ] then isabelle_opam config exec --switch "$ISABELLE_OCAML_VERSION" -- ocamlfind "$@" else