From 1aa02b5c3802100dfba899dc63d143521c761b0d Mon Sep 17 00:00:00 2001 From: sternenseemann Date: Fri, 25 Feb 2022 21:15:57 +0100 Subject: [PATCH] haskell.packages.ghc8{107,84}.OneTuple: provide hashable We need to manually simulate the following conditional in the cabal file: if impl(ghc >=9.0) build-depends: ghc-prim else build-depends: hashable >=1.3.5.0 && <1.5 --- .../development/haskell-modules/configuration-ghc-8.10.x.nix | 5 +++++ pkgs/development/haskell-modules/configuration-ghc-8.8.x.nix | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/pkgs/development/haskell-modules/configuration-ghc-8.10.x.nix b/pkgs/development/haskell-modules/configuration-ghc-8.10.x.nix index 466e25270193..7c6565072c13 100644 --- a/pkgs/development/haskell-modules/configuration-ghc-8.10.x.nix +++ b/pkgs/development/haskell-modules/configuration-ghc-8.10.x.nix @@ -105,4 +105,9 @@ self: super: { # weeder 2.3.0 no longer supports GHC 8.10 weeder = doDistribute (doJailbreak self.weeder_2_2_0); + + # OneTuple needs hashable instead of ghc-prim for GHC < 9 + OneTuple = super.OneTuple.override { + ghc-prim = self.hashable; + }; } diff --git a/pkgs/development/haskell-modules/configuration-ghc-8.8.x.nix b/pkgs/development/haskell-modules/configuration-ghc-8.8.x.nix index 9257ebb1a308..2db51bbbfc4e 100644 --- a/pkgs/development/haskell-modules/configuration-ghc-8.8.x.nix +++ b/pkgs/development/haskell-modules/configuration-ghc-8.8.x.nix @@ -142,4 +142,9 @@ self: super: { # https://github.com/haskell/haskell-language-server/issues/2728 hls-hlint-plugin = null; }); + + # OneTuple needs hashable instead of ghc-prim for GHC < 9 + OneTuple = super.OneTuple.override { + ghc-prim = self.hashable; + }; }