From 336b25b02980a9494199a218afa435ce939d881f Mon Sep 17 00:00:00 2001 From: Ihar Hrachyshka Date: Sun, 1 Jun 2025 17:50:10 -0400 Subject: [PATCH] mesa: fix dylib rpath on darwin Without the patch, Xephyr fails to start with: Library not loaded: @rpath/libgallium-25.1.1.dylib Signed-off-by: Ihar Hrachyshka --- pkgs/development/libraries/mesa/darwin.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkgs/development/libraries/mesa/darwin.nix b/pkgs/development/libraries/mesa/darwin.nix index 5e7743f117b6..fb64f9e70d60 100644 --- a/pkgs/development/libraries/mesa/darwin.nix +++ b/pkgs/development/libraries/mesa/darwin.nix @@ -127,6 +127,10 @@ stdenv.mkDerivation { mesonBuildType = "release"; + postFixup = '' + install_name_tool -add_rpath "$out/lib" "$out/lib/libGL.dylib" + ''; + passthru = { # needed to pass evaluation of bad platforms driverLink = throw "driverLink not supported on darwin";