diff --git a/pkgs/shells/fish/default.nix b/pkgs/shells/fish/default.nix index bc456813ddf4..69072c443190 100644 --- a/pkgs/shells/fish/default.nix +++ b/pkgs/shells/fish/default.nix @@ -110,6 +110,10 @@ let sha256 = "1f12c56v7n4s0f9mi9xinviwj6kpwlcjwaig1d4vsk5wlgp7ip07"; }; + # We don't have access to the codesign executable, so we patch this out. + # For more information, see: https://github.com/fish-shell/fish-shell/issues/6952 + patches = lib.optional stdenv.isDarwin ./dont-codesign-on-mac.diff; + nativeBuildInputs = [ cmake ]; diff --git a/pkgs/shells/fish/dont-codesign-on-mac.diff b/pkgs/shells/fish/dont-codesign-on-mac.diff new file mode 100644 index 000000000000..c61350b0549f --- /dev/null +++ b/pkgs/shells/fish/dont-codesign-on-mac.diff @@ -0,0 +1,12 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 7d220a032..786b60e6e 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -183,7 +183,6 @@ ENDFUNCTION(CODESIGN_ON_MAC target) + # Define a function to link dependencies. + FUNCTION(FISH_LINK_DEPS_AND_SIGN target) + TARGET_LINK_LIBRARIES(${target} fishlib) +- CODESIGN_ON_MAC(${target}) + ENDFUNCTION(FISH_LINK_DEPS_AND_SIGN) + + # Define libfish.a.