diff --git a/src/client/opamAdminRepoUpgrade.ml b/src/client/opamAdminRepoUpgrade.ml index 5ce06fafb4d..6f8f774e35c 100644 --- a/src/client/opamAdminRepoUpgrade.ml +++ b/src/client/opamAdminRepoUpgrade.ml @@ -372,6 +372,9 @@ let do_upgrade repo_root = "CAML_LD_LIBRARY_PATH", PlusEq, "%{lib}%/stublibs", None; "OCAML_TOPLEVEL_PATH", Eq, "%{toplevel}%", None; ] |> + O.with_extensions + (OpamStd.String.Map.singleton OpamFile.OPAM.rewrite_xfield + (OpamTypesBase.nullify_pos (OpamParserTypes.FullPos.Bool true))) |> (* leave the Compiler flag to the implementations (since the user needs to select one) O.with_flags [Pkgflag_Compiler] |> *) diff --git a/tests/reftests/admin.test b/tests/reftests/admin.test index 6cef5b203d9..aeab50a4704 100644 --- a/tests/reftests/admin.test +++ b/tests/reftests/admin.test @@ -101,6 +101,7 @@ src: "file://${BASEDIR}/old-comp.1.2.tgz" checksum: "md5=HASH } ### opam-cat packages/ocaml/ocaml.1.2/opam +available: opam-version >= "2.2" build: ["ocaml" "-I" "+unix" "unix.cma" "gen_ocaml_config.ml"] build-env: CAML_LD_LIBRARY_PATH = "" depends: ["ocaml-base-compiler" {= "1.2"} | "ocaml-variants" {>= "1.2" & < "1.3~"} | "ocaml-system" {= "1.2"}] @@ -110,6 +111,7 @@ opam-version: "2.0" setenv: [[CAML_LD_LIBRARY_PATH = "%{_:stubsdir}%"] [CAML_LD_LIBRARY_PATH += "%{lib}%/stublibs"] [OCAML_TOPLEVEL_PATH = "%{toplevel}%"]] substs: "gen_ocaml_config.ml" synopsis: "The OCaml compiler (virtual package)" +x-allow-env-path-rewrite-on-windows: true ### cat packages/ocaml/ocaml.1.2/files/gen_ocaml_config.ml.in let () = let ocaml_version =