Skip to content

Commit

Permalink
drl: add flags to work around NixOS/nixpkgs#358328
Browse files Browse the repository at this point in the history
  • Loading branch information
Rhys-T committed Nov 29, 2024
1 parent 8639742 commit 915a0a1
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions pkgs/drl/unwrapped.nix
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,11 @@ in stdenv.mkDerivation rec {
substituteInPlace "$FPCVALKYRIE_ROOT"/libs/vsdl2ttflibrary.pas \
--replace-fail '${if stdenv.hostPlatform.isDarwin then "SDL2_ttf.framework/SDL2_ttf" else "libSDL2_ttf-2.0.so.0"}' '${lib.getLib SDL2_ttf}/lib/libSDL2_ttf.${libExt}'
'' + lib.optionalString stdenv.hostPlatform.isDarwin ''
NIX_LDFLAGS+=" -F$DEVELOPER_DIR/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks"
NIX_LDFLAGS+=" -L$DEVELOPER_DIR/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/lib"
if [ -d "$DEVELOPER_DIR/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/lib/swift" ]; then
NIX_LDFLAGS+=" -L$DEVELOPER_DIR/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/lib/swift"
fi
sed -E -i '
/glExtLoader/ {
/GetSymbolExt\s*:=/ s/glExtLoader/GetSymbol/
Expand Down

1 comment on commit 915a0a1

@Rhys-T
Copy link
Owner Author

@Rhys-T Rhys-T commented on 915a0a1 Nov 29, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixes #16.

Please sign in to comment.