From 5d3bef551c671f75ed1eb1978d7fd1ee51cfa59d Mon Sep 17 00:00:00 2001 From: Jiajie Chen Date: Wed, 22 Jun 2022 17:32:43 +0800 Subject: [PATCH] cairo: add patch to fix crashes on darwin Apply patches regardless of os. --- pkgs/development/libraries/cairo/default.nix | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/pkgs/development/libraries/cairo/default.nix b/pkgs/development/libraries/cairo/default.nix index 8f65bd6c5cd7..9a18d173f1d3 100644 --- a/pkgs/development/libraries/cairo/default.nix +++ b/pkgs/development/libraries/cairo/default.nix @@ -52,9 +52,16 @@ in stdenv.mkDerivation rec { url = "https://github.com/freedesktop/cairo/commit/78266cc8c0f7a595cfe8f3b694bfb9bcc3700b38.patch"; sha256 = "048nzfz7rkgqb9xs0dfs56qdw7ckkxr87nbj3p0qziqdq4nb6wki"; }) - ] ++ optionals stdenv.hostPlatform.isDarwin [ + # Workaround https://gitlab.freedesktop.org/cairo/cairo/-/issues/121 ./skip-configure-stderr-check.patch + + # Fixes cairo crash on macOS Big Sur + # Upstream PR: https://gitlab.freedesktop.org/cairo/cairo/-/issues/420 + (fetchpatch { + url = "https://gitlab.freedesktop.org/cairo/cairo/-/commit/e22d7212acb454daccc088619ee147af03883974.diff"; + sha256 = "sha256-8G98nsPz3MLEWPDX9F0jKgXC4hC4NNdFQLSpmW3ay2s="; + }) ]; outputs = [ "out" "dev" "devdoc" ];