mina
mina copied to clipboard
check opam switch - compatible
See #11570 for the develop version of this PR.
This PR enables the check_opam_switch tool, that provides two binaries to check that the current opam switch contains the packages from the opam.export
file (at the same version):
-
check_opam_switch
simply does the check, -
dune_wrapper
does the check before invoking dune (so it is possible to keep using dune as usual (with an alias) but notice early when the switch needs to be updated).
Other changes:
-
The
opam.export
file was moved to the root of the dune project, as expected bydune_wrapper
by default (this way it is simpler to usedune_wrapper
it in multiple projects). -
The check was added to the
ocaml_checks
rule of the makefile (to notice early that the switch needs to be updated when compiling the project from the makefile).
See issue #10982 and PR #11450 for context.