From 07deefb3fa36c3ca1669ea4ff3dffc00f536a088 Mon Sep 17 00:00:00 2001 From: sternenseemann Date: Thu, 31 Jul 2025 16:30:57 +0200 Subject: [PATCH] nix-serve-ng: use overrideSrc This deals correctly deals with Hackage revisions for us if need be. --- .../haskell-modules/configuration-nix.nix | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/pkgs/development/haskell-modules/configuration-nix.nix b/pkgs/development/haskell-modules/configuration-nix.nix index 599fe365151e..423c66650f76 100644 --- a/pkgs/development/haskell-modules/configuration-nix.nix +++ b/pkgs/development/haskell-modules/configuration-nix.nix @@ -339,8 +339,9 @@ builtins.intersectAttrs super { # Add necessary reference to gtk3 package gi-dbusmenugtk3 = addPkgconfigDepend pkgs.gtk3 super.gi-dbusmenugtk3; - nix-serve-ng = - (overrideCabal (old: { + nix-serve-ng = lib.pipe (super.nix-serve-ng.override { nix = pkgs.nixVersions.nix_2_28; }) [ + # nix-serve-ng isn't regularly released to Hackage + (overrideSrc { src = pkgs.fetchFromGitHub { repo = "nix-serve-ng"; owner = "aristanetworks"; @@ -348,16 +349,16 @@ builtins.intersectAttrs super { hash = "sha256-N6c3NozYqAGwmjf+k5GHOZzlcquDntrJwsZQ7O2sqtQ="; }; version = "1.0.1-unstable-2025-05-28"; - #editedCabalFile = null; + }) + + (overrideCabal (old: { # Doesn't declare boost dependency pkg-configDepends = (old.pkg-configDepends or [ ]) ++ [ pkgs.boost.dev ]; # error: output '/nix/store/hv6lzj1nlshn8q5lirzgys8f4vgym4hg-nix-serve-ng-1.0.0-unstable-2024-12-02' is not allowed to refer to the following paths: # /nix/store/qza2y18fwkq1wzi02qywf691r42r5jfy-ghc-9.6.6 broken = pkgs.stdenv.hostPlatform.system == "aarch64-darwin"; - }) super.nix-serve-ng).override - { - nix = pkgs.nixVersions.nix_2_28; - }; + })) + ]; # These packages try to access the network. amqp = dontCheck super.amqp;