Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ocamlPackages.mirage: init at 3.9.0 #103040

Merged
merged 3 commits into from Nov 14, 2020
Merged

ocamlPackages.mirage: init at 3.9.0 #103040

merged 3 commits into from Nov 14, 2020

Conversation

vbgl
Copy link
Contributor

@vbgl vbgl commented Nov 6, 2020

Motivation for this change

#23955

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

@vbgl
Copy link
Contributor Author

vbgl commented Nov 7, 2020

@GrahamcOfBorg build ocamlPackages.mirage

@sternenseemann
Copy link
Member

Might be a good idea to wrap bin/mirage to add some runtime dependencies to PATH like dune.

@vbgl
Copy link
Contributor Author

vbgl commented Nov 13, 2020

Might make sense for dune. But won’t you also need ocaml, ocamlfind, ocamlbuild, and a handful of OCaml libraries. It seems futile to try to have them all within the wrapped mirage: so, is it better to have some but not all rather than none?

@sternenseemann
Copy link
Member

Yeah, I'm somewhat torn as well — mirage largely relies on stuff that is assumed to be installed anyways. Thus the UX for missing runtime dependencies is horrible (it shows it as command failure without any further information and you have to infer the cause from the exit code 127).

I think wrapping here could be harmful because it would limit the users choice of versions which make a difference:

  • dune 1 vs. dune 2 (at least for the moment)
  • different OCaml versions
  • different ways of installing other dependencies (stateful opam, via a nix-shell, from nixpkgs, …) which also would in turn affect ocamlfind

I don't think that it's reasonable requiring users to use overriding to make these choices, so the simplest most user-friendly way seems to be relying on the environment.

@vbgl
Copy link
Contributor Author

vbgl commented Nov 14, 2020

Thanks. Let’s merge as is then.

@vbgl vbgl merged commit 9ca92f0 into NixOS:master Nov 14, 2020
@vbgl vbgl deleted the ocaml-mirage-3.9.0 branch November 14, 2020 08:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants