diff options
| author | Samuel Rivas <samuelrivas@gmail.com> | 2021-08-14 09:59:29 +0200 |
|---|---|---|
| committer | sterni <sternenseemann@systemli.org> | 2021-08-16 12:12:46 +0200 |
| commit | b3743e632534da9416c44a7a12ae4b1a36b82a77 (patch) | |
| tree | 39c973659bb53de22baea48019c3f86d092eb739 | |
| parent | Merge pull request #133640 from NixOS/backport-133627-to-release-21.05 (diff) | |
| download | nixpkgs-b3743e632534da9416c44a7a12ae4b1a36b82a77.tar.gz | |
haskellPackages.readline: fix Setup.hs to work with Cabal 3
See https://github.com/NixOS/nixpkgs/pull/111985/ for previous discussion
(cherry picked from commit b950ecaf3a49662ba92e6c978aa472155eddd47f)
4 files changed, 12 insertions, 3 deletions
diff --git a/pkgs/development/haskell-modules/configuration-common.nix b/pkgs/development/haskell-modules/configuration-common.nix index d62741d590ee..2f142d29a388 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 ad6dd7115ae7..5c7568416b79 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 198ce1cc4a5a..ba4e363423e3 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 000000000000..95853b32a14b --- /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 |
