haskellPackages.sbv: fix location of z3 executable

A lot of the functionality of the z3 library depends on it being able to
find the z3 executable on $PATH. Hard-coding it here means it will never
be unable to find it and z3 doesn't need to pollute $PATH.
This commit is contained in:
Nathan van Doorn 2018-09-20 11:45:16 +01:00
parent 0e1f3ef01a
commit c8598daad4

View File

@ -511,4 +511,10 @@ self: super: builtins.intersectAttrs super {
# Doctests hang only when compiling with nix.
# https://github.com/cdepillabout/termonad/issues/15
termonad = dontCheck super.termonad;
# Expects z3 to be on path so we replace it with a hard
sbv = overrideCabal super.sbv (drv: {
postPatch = ''
sed -i -e 's|"z3"|"${pkgs.z3}/bin/z3"|' Data/SBV/Provers/Z3.hs'';
});
}