summary refs log tree commit diff
path: root/pkgs/development/haskell-modules
diff options
context:
space:
mode:
authorWill Fancher <elvishjerricco@gmail.com>2017-11-06 14:57:28 -0500
committerWill Fancher <elvishjerricco@gmail.com>2017-11-06 16:47:29 -0500
commit8caf9f13a66b7d7a9aa9a13d59a6e83fdc99f107 (patch)
treefe7c607d87daba724ac21b7273251810fd772d7b /pkgs/development/haskell-modules
parent4a62ff9f476919912807cbe42df61a549d55614d (diff)
downloadnixlib-8caf9f13a66b7d7a9aa9a13d59a6e83fdc99f107.tar
nixlib-8caf9f13a66b7d7a9aa9a13d59a6e83fdc99f107.tar.gz
nixlib-8caf9f13a66b7d7a9aa9a13d59a6e83fdc99f107.tar.bz2
nixlib-8caf9f13a66b7d7a9aa9a13d59a6e83fdc99f107.tar.lz
nixlib-8caf9f13a66b7d7a9aa9a13d59a6e83fdc99f107.tar.xz
nixlib-8caf9f13a66b7d7a9aa9a13d59a6e83fdc99f107.tar.zst
nixlib-8caf9f13a66b7d7a9aa9a13d59a6e83fdc99f107.zip
Revert "Merge branch 'all-cabal-hashes-components'"
This reverts commit ad6b8f438db055a73e64218b5f2ed3cbca963ae5, reversing
changes made to 2d44e7280166256d8322546b11dcbe9b95f5bc5d.
Diffstat (limited to 'pkgs/development/haskell-modules')
-rw-r--r--pkgs/development/haskell-modules/make-package-set.nix19
1 files changed, 3 insertions, 16 deletions
diff --git a/pkgs/development/haskell-modules/make-package-set.nix b/pkgs/development/haskell-modules/make-package-set.nix
index ebfe44dd25ae..37b32177f6ba 100644
--- a/pkgs/development/haskell-modules/make-package-set.nix
+++ b/pkgs/development/haskell-modules/make-package-set.nix
@@ -118,23 +118,10 @@ let
       '';
   };
 
-  all-cabal-hashes-component = name: import (pkgs.runCommand "all-cabal-hashes-component-${name}.nix" {}
-    ''
-      set +o pipefail
-      for component in ${all-cabal-hashes}/*; do
-        if ls $component | grep -q "^${name}$"; then
-          echo "builtins.storePath $component" > $out
-          exit 0
-        fi
-      done
-      echo "${name} not found in any all-cabal-hashes component, are you sure it's in hackage?" >&2
-      exit 1
-    '');
-
-  hackage2nix = name: version: let component = all-cabal-hashes-component name; in self.haskellSrc2nix {
+  hackage2nix = name: version: self.haskellSrc2nix {
     name   = "${name}-${version}";
-    sha256 = ''$(sed -e 's/.*"SHA256":"//' -e 's/".*$//' "${component}/${name}/${version}/${name}.json")'';
-    src    = "${component}/${name}/${version}/${name}.cabal";
+    sha256 = ''$(sed -e 's/.*"SHA256":"//' -e 's/".*$//' "${all-cabal-hashes}/${name}/${version}/${name}.json")'';
+    src    = "${all-cabal-hashes}/${name}/${version}/${name}.cabal";
   };
 
 in package-set { inherit pkgs stdenv callPackage; } self // {