diff --git a/pkgs/development/haskell-modules/configuration-common.nix b/pkgs/development/haskell-modules/configuration-common.nix index 0d2785b07e50..d4b8f0bd646b 100644 --- a/pkgs/development/haskell-modules/configuration-common.nix +++ b/pkgs/development/haskell-modules/configuration-common.nix @@ -153,11 +153,20 @@ self: super: { barbly = addBuildDepend super.barbly pkgs.darwin.apple_sdk.frameworks.AppKit; # Hakyll's tests are broken on Darwin (3 failures); and they require util-linux - hakyll = if pkgs.stdenv.isDarwin - then dontCheck (overrideCabal super.hakyll (drv: { + hakyll = let + # Hakyll needs a relaxed upper bound on `warp` so that the preview server will build + patched-hakyll = overrideCabal super.hakyll (drv: { + postPatch = (drv.postPatch or "") + '' + substituteInPlace hakyll.cabal --replace \ + "warp >= 3.2 && < 3.3" \ + "warp >= 3.2 && < 3.4" + ''; + }); + in if pkgs.stdenv.isDarwin + then dontCheck (overrideCabal patched-hakyll (drv: { testToolDepends = []; })) - else super.hakyll; + else patched-hakyll; double-conversion = if !pkgs.stdenv.isDarwin then super.double-conversion