From 7ef2fa3b1b15836e345d7d69eb7a10eb74af47fd Mon Sep 17 00:00:00 2001 From: Rhys-T <108157737+Rhys-T@users.noreply.github.com> Date: Mon, 14 Apr 2025 14:17:56 -0400 Subject: [PATCH] allegro5: add `fixDarwinDylibNames` Allows Allegro-based programs on macOS/Darwin to locate the libraries at runtime, without needing a wrapper to set `DYLD_LIBRARY_PATH`. --- pkgs/development/libraries/allegro/5.nix | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/pkgs/development/libraries/allegro/5.nix b/pkgs/development/libraries/allegro/5.nix index 77930cf53163..55778e37df0d 100644 --- a/pkgs/development/libraries/allegro/5.nix +++ b/pkgs/development/libraries/allegro/5.nix @@ -4,6 +4,7 @@ cmake, enet, fetchFromGitHub, + fixDarwinDylibNames, flac, freetype, gtk3, @@ -49,10 +50,14 @@ stdenv.mkDerivation rec { sha256 = "sha256-agE3K+6VhhG/LO52fiesCsOq1fNYVRhdW7aKdPCbTOo="; }; - nativeBuildInputs = [ - cmake - pkg-config - ]; + nativeBuildInputs = + [ + cmake + pkg-config + ] + ++ lib.optionals stdenv.hostPlatform.isDarwin [ + fixDarwinDylibNames + ]; buildInputs = [