git.iko.soy/typeable/nixpkgs
on master help sign in
cryptol: Make Z3 available for REPL users

The Cryptol REPL has a hard dependency on Z3, but the rest of the library uses SBV to support multiple solvers. Ensure that Z3 is available for `pkgs.cryptol`, which is likely to be installed via nix-env for REPL usage, but do not change pkgs.haskellPackages.cryptol, which is likely to be used as a dependency (in Nix expressions).

commit54ff1184779419c91cb57d7a3a234a069fcdc592 authorAneesh Agrawal <aneeshusa@gmail.com> dateSat 10 Sep 2016, 16:57 (10 years ago) parent0dbfb0f
1 file changed+9−1
pkgs/top-level/all-packages.nix+9−1
pkgs/top-level/all-packages.nix+9−1
@@ -4443,7 +4443,15 @@ in
44434443 coq = coq_8_5;
44444444 });
44454445
4446− cryptol = haskellPackages.cryptol;
4446+ # Users installing via `nix-env` will likely be using the REPL,
4447+ # which has a hard dependency on Z3, so make sure it is available.
4448+ cryptol = haskellPackages.cryptol.overrideDerivation (oldAttrs: {
4449+ buildInputs = (oldAttrs.buildInputs or []) ++ [ makeWrapper ];
4450+ installPhase = (oldAttrs.installPhase or "") + ''
4451+ wrapProgram $out/bin/cryptol \
4452+ --prefix 'PATH' ':' "${lib.getBin z3}/bin"
4453+ '';
4454+ });
44474455
44484456 devpi-client = callPackage ../development/tools/devpi-client {};
44494457