From 1a818e315050ced2f0ddf022ecff2c8c1bed652a Mon Sep 17 00:00:00 2001 From: sternenseemann Date: Fri, 7 Jun 2024 15:12:54 +0200 Subject: [PATCH] nvfetcher: prevent incorrect references on aarch64-darwin --- pkgs/development/haskell-modules/configuration-nix.nix | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/pkgs/development/haskell-modules/configuration-nix.nix b/pkgs/development/haskell-modules/configuration-nix.nix index 87fcdd9f4f4d..706bd2dfecf2 100644 --- a/pkgs/development/haskell-modules/configuration-nix.nix +++ b/pkgs/development/haskell-modules/configuration-nix.nix @@ -1073,6 +1073,14 @@ self: super: builtins.intersectAttrs super { pkgs.nix-prefetch-docker ] }" + '' + # Prevent erroneous references to other libraries that use Paths_ modules + # on aarch64-darwin. Note that references to the data outputs are not removed. + + lib.optionalString (with pkgs.stdenv; hostPlatform.isDarwin && hostPlatform.isAarch64) '' + remove-references-to -t "${self.shake.out}" "$out/bin/.nvfetcher-wrapped" + remove-references-to -t "${self.js-jquery.out}" "$out/bin/.nvfetcher-wrapped" + remove-references-to -t "${self.js-flot.out}" "$out/bin/.nvfetcher-wrapped" + remove-references-to -t "${self.js-dgtable.out}" "$out/bin/.nvfetcher-wrapped" ''; }) super.nvfetcher);