even more robust and conservative OCaml setup;
authorwenzelm
Fri Mar 22 10:36:50 2019 +0100 (4 weeks ago)
changeset 69948a591de179931
parent 69944 ab8aad4aa76e
child 69949 a7a0115061ec
even more robust and conservative OCaml setup;
lib/Tools/ocaml_setup
lib/scripts/ocamlfind
     1.1 --- a/lib/Tools/ocaml_setup	Thu Mar 21 19:46:26 2019 +0100
     1.2 +++ b/lib/Tools/ocaml_setup	Fri Mar 22 10:36:50 2019 +0100
     1.3 @@ -6,11 +6,14 @@
     1.4  
     1.5  set -e
     1.6  
     1.7 -if [ -e "$ISABELLE_OPAM_ROOT/config" ]
     1.8 +if [ -d "$ISABELLE_OPAM_ROOT/$ISABELLE_OCAML_VERSION/bin" ]
     1.9  then
    1.10 -  isabelle_opam switch reinstall -y "$ISABELLE_OCAML_VERSION"
    1.11 +  isabelle_opam switch -y "$ISABELLE_OCAML_VERSION"
    1.12 +elif [ -e "$ISABELLE_OPAM_ROOT/config" ]
    1.13 +then
    1.14 +  isabelle_opam switch create -y "$ISABELLE_OCAML_VERSION"
    1.15  else
    1.16    isabelle_opam init -y --disable-sandboxing --no-setup --compiler="$ISABELLE_OCAML_VERSION"
    1.17  fi
    1.18  
    1.19 -isabelle_opam install zarith -y
    1.20 +isabelle_opam install -y zarith
     2.1 --- a/lib/scripts/ocamlfind	Thu Mar 21 19:46:26 2019 +0100
     2.2 +++ b/lib/scripts/ocamlfind	Fri Mar 22 10:36:50 2019 +0100
     2.3 @@ -4,7 +4,7 @@
     2.4  #
     2.5  # Invoke ocamlfind via "opam".
     2.6  
     2.7 -if [ -e "$ISABELLE_OPAM_ROOT/config" ]
     2.8 +if [ -d "$ISABELLE_OPAM_ROOT/$ISABELLE_OCAML_VERSION/bin" ]
     2.9  then
    2.10    isabelle_opam config exec --switch "$ISABELLE_OCAML_VERSION" -- ocamlfind "$@"
    2.11  else