From 7115040e19fa4cd20028f8b4a37ba44a993029af Mon Sep 17 00:00:00 2001 From: Ryan Burns Date: Wed, 30 Dec 2020 19:00:32 -0800 Subject: [PATCH] mesa: fix build on darwin Latest mesa requires macOS SDK 10.13 - this applies an upstream patch for compatibility with 10.13 Applied on darwin only to avoid linux rebuilds in staging-next - left a note that this can be done unconditionally as it has no effect on non-darwin platforms, if this would be considered more robust. --- pkgs/development/libraries/mesa/default.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pkgs/development/libraries/mesa/default.nix b/pkgs/development/libraries/mesa/default.nix index 0e18164e6f2..c96d1edfadf 100644 --- a/pkgs/development/libraries/mesa/default.nix +++ b/pkgs/development/libraries/mesa/default.nix @@ -65,6 +65,13 @@ stdenv.mkDerivation { url = "https://gitlab.freedesktop.org/mesa/mesa/commit/aebbf819df6d1e.patch"; sha256 = "17248hyzg43d73c86p077m4lv1pkncaycr3l27hwv9k4ija9zl8q"; }) + ] ++ stdenv.lib.optionals stdenv.isDarwin [ + # Fix for pre macOS SDK 10.13 + # TODO(r-burns) can be applied unconditionally, at the cost of a mass linux rebuild + (fetchpatch { + url = "https://gitlab.freedesktop.org/mesa/mesa/-/commit/f4403f70fe5bf2ec41af5546122f0d78caffa984.patch"; + sha256 = "03j2aj255m7ms848nkb41vj3s3yb72zb5rz3w3fzp5l9wzzargw5"; + }) ]; postPatch = ''