diff --git a/pkgs/development/haskell-modules/configuration-common.nix b/pkgs/development/haskell-modules/configuration-common.nix index d62741d590e..2f142d29a38 100644 --- a/pkgs/development/haskell-modules/configuration-common.nix +++ b/pkgs/development/haskell-modules/configuration-common.nix @@ -1583,6 +1583,10 @@ self: super: { addBuildDepend (unmarkBroken super.hercules-ci-cli) super.hercules-ci-optparse-applicative ); + # Readline uses Distribution.Simple from Cabal 2, in a way that is not + # compatible with Cabal 3. No upstream repository found so far + readline = appendPatch super.readline ./patches/readline-fix-for-cabal-3.patch; + # 2020-12-05: http-client is fixed on too old version essence-of-live-coding-warp = doJailbreak (super.essence-of-live-coding-warp.override { http-client = self.http-client_0_7_8; diff --git a/pkgs/development/haskell-modules/configuration-hackage2nix/broken.yaml b/pkgs/development/haskell-modules/configuration-hackage2nix/broken.yaml index ad6dd7115ae..5c7568416b7 100644 --- a/pkgs/development/haskell-modules/configuration-hackage2nix/broken.yaml +++ b/pkgs/development/haskell-modules/configuration-hackage2nix/broken.yaml @@ -3772,7 +3772,6 @@ broken-packages: - read-bounded - read-ctags - read-io - - readline - readme-lhs - readshp - really-simple-xml-parser diff --git a/pkgs/development/haskell-modules/hackage-packages.nix b/pkgs/development/haskell-modules/hackage-packages.nix index 198ce1cc4a5..ba4e363423e 100644 --- a/pkgs/development/haskell-modules/hackage-packages.nix +++ b/pkgs/development/haskell-modules/hackage-packages.nix @@ -216709,8 +216709,6 @@ self: { librarySystemDepends = [ ncurses readline ]; description = "An interface to the GNU readline library"; license = "GPL"; - hydraPlatforms = lib.platforms.none; - broken = true; }) {inherit (pkgs) ncurses; inherit (pkgs) readline;}; "readline-statevar" = callPackage diff --git a/pkgs/development/haskell-modules/patches/readline-fix-for-cabal-3.patch b/pkgs/development/haskell-modules/patches/readline-fix-for-cabal-3.patch new file mode 100644 index 00000000000..95853b32a14 --- /dev/null +++ b/pkgs/development/haskell-modules/patches/readline-fix-for-cabal-3.patch @@ -0,0 +1,8 @@ +--- a/Setup.hs 2021-02-04 14:01:09.557970245 +0100 ++++ b/Setup.hs 2021-02-04 14:07:45.047443753 +0100 +@@ -3,4 +3,4 @@ + import Distribution.Simple + + main :: IO () +-main = defaultMainWithHooks defaultUserHooks ++main = defaultMainWithHooks autoconfUserHooks