From 7ea4c1e47fbb1be1fc6be9c7d2a8466b9f9f6e1d Mon Sep 17 00:00:00 2001 From: Luflosi Date: Tue, 28 Dec 2021 15:35:16 +0100 Subject: [PATCH] shell.nix: add dependency needed on Apple silicon shell.nix is missing a depencency on the UserNotifications framework on macOS with Apple silicon. Unfortunately we can't just unconditionally include this dependency because Nixpkgs uses a different macOS SDK version for macOS on an Intel processor compared to macOS on Apple silicon. The older SDK version 10.12 on Intel does not have the UserNotifications framework, which would lead to an "attribute missing" error when trying to execute `nix-shell`. The condition can be dropped when the macOS SDK version for Intel processors is finally updated. See https://github.com/NixOS/nixpkgs/issues/101229 for progress on that. See https://github.com/NixOS/nixpkgs/pull/137512 for more context. Closes https://github.com/kovidgoyal/kitty/issues/4352. --- shell.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/shell.nix b/shell.nix index 5bc449cda..4e5744fdd 100644 --- a/shell.nix +++ b/shell.nix @@ -24,6 +24,8 @@ mkShell rec { libpng python3 zlib + ] ++ lib.optionals (stdenv.isDarwin && (builtins.hasAttr "UserNotifications" darwin.apple_sdk.frameworks)) [ + darwin.apple_sdk.frameworks.UserNotifications ] ++ optionals stdenv.isLinux [ fontconfig libunistring libcanberra libX11 libXrandr libXinerama libXcursor libxkbcommon libXi libXext