Make getHaskellBuildInputs / shellFor work with overrideCabal

This commit is contained in:
Will Fancher
2018-05-17 20:35:53 -04:00
parent 50bbc56b0b
commit 5523ec8f3c
2 changed files with 7 additions and 4 deletions
+5 -2
View File
@@ -297,8 +297,11 @@ rec {
# This is useful to build environments for developing on that
# package.
getHaskellBuildInputs = p:
(p.override { mkDerivation = extractBuildInputs p.compiler;
}).haskellBuildInputs;
(overrideCabal p (args: {
passthru = (args.passthru or {}) // {
_getHaskellBuildInputs = extractBuildInputs p.compiler args;
};
}))._getHaskellBuildInputs;
# Under normal evaluation, simply return the original package. Under
# nix-shell evaluation, return a nix-shell optimized environment.