Skip to content

Commit

Permalink
librsvg: link libobjc on Darwin independent of CPU architecture (#347013
Browse files Browse the repository at this point in the history
)
  • Loading branch information
reckenrode authored Oct 8, 2024
2 parents 85faae5 + 38d39e6 commit 3c3568d
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions pkgs/development/libraries/librsvg/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -113,11 +113,8 @@ stdenv.mkDerivation (finalAttrs: {
${lib.optionalString (stdenv.hostPlatform.emulatorAvailable buildPackages) (stdenv.hostPlatform.emulator buildPackages)} ${lib.getDev gdk-pixbuf}/bin/gdk-pixbuf-query-loaders
'';

# librsvg only links Foundation, but it also requiers libobjc. The Framework.tbd in the 11.0 SDK
# reexports libobjc, but the one in the 10.12 SDK does not, so link it manually.
env = lib.optionalAttrs (stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isx86_64) {
NIX_LDFLAGS = "-lobjc";
};
# librsvg only links Foundation, but it also requiers libobjc.
env = lib.optionalAttrs stdenv.hostPlatform.isDarwin { NIX_LDFLAGS = "-lobjc"; };

preConfigure = ''
PKG_CONFIG_VAPIGEN_VAPIGEN="$(type -p vapigen)"
Expand Down

0 comments on commit 3c3568d

Please sign in to comment.