3
0
Fork 0
forked from mirrors/nixpkgs

haskellPackages.developPackage: Use haskell.lib.compose correctly

This commit is contained in:
Ellie Hermaszewska 2021-11-08 18:33:48 +08:00
parent b0e58bafbe
commit 2413ab9e72
No known key found for this signature in database
GPG key ID: C8116E3A0C1CA76A

View file

@ -159,7 +159,7 @@ let
# (requiring it to be frequently rebuilt), which can be an # (requiring it to be frequently rebuilt), which can be an
# annoyance. # annoyance.
callPackageKeepDeriver = src: args: callPackageKeepDeriver = src: args:
overrideCabal (self.callPackage src args) (orig: { overrideCabal (orig: {
preConfigure = '' preConfigure = ''
# Generated from ${src} # Generated from ${src}
${orig.preConfigure or ""} ${orig.preConfigure or ""}
@ -171,7 +171,7 @@ let
# cabal2nixDeriver field. # cabal2nixDeriver field.
cabal2nixDeriver = src; cabal2nixDeriver = src;
}; };
}); }) (self.callPackage src args);
in package-set { inherit pkgs lib callPackage; } self // { in package-set { inherit pkgs lib callPackage; } self // {
@ -213,9 +213,9 @@ in package-set { inherit pkgs lib callPackage; } self // {
then pkgs.lib.cleanSourceWith { inherit src filter; } then pkgs.lib.cleanSourceWith { inherit src filter; }
else src; else src;
}; };
in overrideCabal (callPackageKeepDeriver expr args) (orig: { in overrideCabal (orig: {
inherit src; inherit src;
}); }) (callPackageKeepDeriver expr args);
callCabal2nix = name: src: args: self.callCabal2nixWithOptions name src "" args; callCabal2nix = name: src: args: self.callCabal2nixWithOptions name src "" args;