From cd2c4cc64cb68ef5306e90696c1978d82ccc41cf Mon Sep 17 00:00:00 2001 From: sternenseemann Date: Sat, 13 Sep 2025 03:03:11 +0200 Subject: [PATCH] darcs: apply patches for base 4.20, Cabal 3.12 and hashable 1.5 --- .../haskell-modules/configuration-common.nix | 9 ++++++ .../patches/darcs-cabal-3.12.patch | 24 ++++++++++++++ .../patches/darcs-stackage-lts-23.patch | 32 +++++++++++++++++++ 3 files changed, 65 insertions(+) create mode 100644 pkgs/development/haskell-modules/patches/darcs-cabal-3.12.patch create mode 100644 pkgs/development/haskell-modules/patches/darcs-stackage-lts-23.patch diff --git a/pkgs/development/haskell-modules/configuration-common.nix b/pkgs/development/haskell-modules/configuration-common.nix index e94a0b664b18..a1523fbb321d 100644 --- a/pkgs/development/haskell-modules/configuration-common.nix +++ b/pkgs/development/haskell-modules/configuration-common.nix @@ -2414,6 +2414,15 @@ with haskellLib; } super.regex-compat-tdfa ); + darcs = appendPatches [ + # Cabal 3.12 support in Setup.hs + # https://hub.darcs.net/darcs/darcs-reviewed/patch/50d9b0b402a896c83aa7929a50a0e0449838600f + ./patches/darcs-cabal-3.12.patch + # GHC 9.10 patch plus lifted constraints for hashable + # https://hub.darcs.net/darcs/darcs-reviewed/patch/32646b190e019de21a103e950c4eccdd66f7eadc + ./patches/darcs-stackage-lts-23.patch + ] super.darcs; + # 2025-02-11: Too strict bounds on hedgehog < 1.5, hspec-hedgehog < 0.2 validation-selective = doJailbreak super.validation-selective; diff --git a/pkgs/development/haskell-modules/patches/darcs-cabal-3.12.patch b/pkgs/development/haskell-modules/patches/darcs-cabal-3.12.patch new file mode 100644 index 000000000000..2ad9dfba1d97 --- /dev/null +++ b/pkgs/development/haskell-modules/patches/darcs-cabal-3.12.patch @@ -0,0 +1,24 @@ +diff -rN -u old-darcs.net/darcs.cabal new-darcs.net/darcs.cabal +--- old-darcs.net/darcs.cabal 2025-09-13 02:45:32.790227974 +0200 ++++ new-darcs.net/darcs.cabal 2025-09-13 02:45:32.791227985 +0200 +@@ -124,7 +124,7 @@ + + custom-setup + setup-depends: base >= 4.10 && < 4.20, +- Cabal >= 2.4 && < 3.11, ++ Cabal >= 2.4 && < 3.13, + process >= 1.2.3.0 && < 1.7, + filepath >= 1.4.1 && < 1.5.0.0, + directory >= 1.2.7 && < 1.4 +diff -rN -u old-darcs.net/Setup.hs new-darcs.net/Setup.hs +--- old-darcs.net/Setup.hs 2025-09-13 02:45:32.789227964 +0200 ++++ new-darcs.net/Setup.hs 2025-09-13 02:45:32.790227974 +0200 +@@ -8,7 +8,7 @@ + import Distribution.Package ( packageVersion ) + import Distribution.Version( Version ) + import Distribution.Simple.LocalBuildInfo +- ( LocalBuildInfo(..), absoluteInstallDirs ) ++ ( LocalBuildInfo(..), absoluteInstallDirs, buildDir ) + import Distribution.Simple.InstallDirs (mandir, CopyDest (NoCopyDest)) + import Distribution.Simple.Setup + (buildVerbosity, copyDest, copyVerbosity, fromFlag, diff --git a/pkgs/development/haskell-modules/patches/darcs-stackage-lts-23.patch b/pkgs/development/haskell-modules/patches/darcs-stackage-lts-23.patch new file mode 100644 index 000000000000..613582cdeb3d --- /dev/null +++ b/pkgs/development/haskell-modules/patches/darcs-stackage-lts-23.patch @@ -0,0 +1,32 @@ +diff -rN -u old-darcs.net/darcs.cabal new-darcs.net/darcs.cabal +--- old-darcs.net/darcs.cabal 2025-09-13 02:46:05.662572580 +0200 ++++ new-darcs.net/darcs.cabal 2025-09-13 02:46:05.748573468 +0200 +@@ -123,7 +123,7 @@ + -- ---------------------------------------------------------------------- + + custom-setup +- setup-depends: base >= 4.10 && < 4.20, ++ setup-depends: base >= 4.10 && < 4.21, + Cabal >= 2.4 && < 3.13, + process >= 1.2.3.0 && < 1.7, + filepath >= 1.4.1 && < 1.5.0.0, +@@ -412,7 +412,7 @@ + else + build-depends: unix >= 2.7.1.0 && < 2.9 + +- build-depends: base >= 4.10 && < 4.20, ++ build-depends: base >= 4.10 && < 4.21, + safe >= 0.3.20 && < 0.4, + stm >= 2.1 && < 2.6, + binary >= 0.5 && < 0.11, +@@ -447,7 +447,7 @@ + temporary >= 1.2.1 && < 1.4, + process >= 1.2.3.0 && < 1.7, + array >= 0.5.1.0 && < 0.6, +- hashable >= 1.2.3.3 && < 1.5, ++ hashable >= 1.2.3.3 && < 1.6, + mmap >= 0.5.9 && < 0.6, + zlib >= 0.6.1.2 && < 0.8, + network-uri >= 2.6 && < 2.8, + +