about summary refs log tree commit diff
diff options
context:
space:
mode:
authorPeter Simons <simons@cryp.to>2017-03-27 09:00:06 +0200
committerPeter Simons <simons@cryp.to>2017-03-27 09:00:06 +0200
commit50cce50143c8395738702e735c682e4afd965f1c (patch)
tree8f00d60e09604dd7e065c8bc2f40f3205c4d66e7
parentdb5f0cdd50efd53584bc19b1eeb42be74e52e9c4 (diff)
downloadnixlib-50cce50143c8395738702e735c682e4afd965f1c.tar
nixlib-50cce50143c8395738702e735c682e4afd965f1c.tar.gz
nixlib-50cce50143c8395738702e735c682e4afd965f1c.tar.bz2
nixlib-50cce50143c8395738702e735c682e4afd965f1c.tar.lz
nixlib-50cce50143c8395738702e735c682e4afd965f1c.tar.xz
nixlib-50cce50143c8395738702e735c682e4afd965f1c.tar.zst
nixlib-50cce50143c8395738702e735c682e4afd965f1c.zip
callCabal2nix: Revert "Don't rebuild unchanged cabal file"
This reverts commit 24b47526ce38e3ccb073c776b32c0ea220f3c0f2 since it broke
callCabal2nix, apparently. See https://github.com/NixOS/nixpkgs/issues/24245
for details.
-rw-r--r--pkgs/development/haskell-modules/default.nix9
1 files changed, 1 insertions, 8 deletions
diff --git a/pkgs/development/haskell-modules/default.nix b/pkgs/development/haskell-modules/default.nix
index 7205f777bcf2..df17c769ea2d 100644
--- a/pkgs/development/haskell-modules/default.nix
+++ b/pkgs/development/haskell-modules/default.nix
@@ -84,14 +84,7 @@ let
         callHackage = name: version: self.callPackage (hackage2nix name version);
 
         # Creates a Haskell package from a source package by calling cabal2nix on the source.
-        callCabal2nix = name: src: args:
-          let
-            # Filter out files other than the cabal file. This ensures
-            # that we don't create new derivations even when the cabal
-            # file hasn't changed.
-            justCabal = builtins.filterSource (path: type: pkgs.lib.hasSuffix ".cabal" path) src;
-            drv = self.callPackage (haskellSrc2nix { inherit name; src = justCabal; }) args;
-          in overrideCabal drv (drv': { inherit src; }); # Restore the desired src.
+        callCabal2nix = name: src: self.callPackage (haskellSrc2nix { inherit src name; });
 
         ghcWithPackages = selectFrom: withPackages (selectFrom self);