From 668a3af6913e3af5394d0c883043da28adae7602 Mon Sep 17 00:00:00 2001 From: Randy Eckenrode Date: Mon, 17 Nov 2025 20:25:22 -0500 Subject: [PATCH 1/2] mesa: fix timeout on Darwin (cherry picked from commit a8778fc470dd5ad5292cb4fcd4faf425abab3af4) --- pkgs/development/libraries/mesa/darwin.nix | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/pkgs/development/libraries/mesa/darwin.nix b/pkgs/development/libraries/mesa/darwin.nix index fb64f9e70d60..4487094b5ac0 100644 --- a/pkgs/development/libraries/mesa/darwin.nix +++ b/pkgs/development/libraries/mesa/darwin.nix @@ -59,6 +59,17 @@ stdenv.mkDerivation { ./opencl.patch ]; + postPatch = '' + # Darwin only installs `swrast_dri.so`. It is symlinked to `libdril_dri.dylib`, but the script never terminates + # checking for `swrast_dri.dylib`, which isn’t what will be created. + substituteInPlace bin/install_megadrivers.py \ + --replace-fail " while ext != '.' + args.libname_suffix" " while ext != '.so'" + + # Use `st_mtimespec` on Darwin instead of `st_mtim`. + substituteInPlace src/gallium/drivers/llvmpipe/lp_context.c \ + --replace-fail 'st_mtim.' 'st_mtimespec.' + ''; + outputs = [ "out" "dev" From 9190bf77cb790b86b333704c1a174089b301c8e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Thu, 28 May 2026 10:51:01 +0200 Subject: [PATCH 2/2] mesa: drop a patch applied in 26.1.1 We got that since merge dd1e8dbab21c7870d3b6fff31d8f8e3030443493 (cherry picked from commit 8ddb5bfe36bb9b00c51c9319cba661a21b33a161) --- pkgs/development/libraries/mesa/darwin.nix | 4 ---- 1 file changed, 4 deletions(-) diff --git a/pkgs/development/libraries/mesa/darwin.nix b/pkgs/development/libraries/mesa/darwin.nix index 4487094b5ac0..d683cc3bfe89 100644 --- a/pkgs/development/libraries/mesa/darwin.nix +++ b/pkgs/development/libraries/mesa/darwin.nix @@ -64,10 +64,6 @@ stdenv.mkDerivation { # checking for `swrast_dri.dylib`, which isn’t what will be created. substituteInPlace bin/install_megadrivers.py \ --replace-fail " while ext != '.' + args.libname_suffix" " while ext != '.so'" - - # Use `st_mtimespec` on Darwin instead of `st_mtim`. - substituteInPlace src/gallium/drivers/llvmpipe/lp_context.c \ - --replace-fail 'st_mtim.' 'st_mtimespec.' ''; outputs = [