ld64: ensure ld64 checks pass with the new SDK

The SDK library path is normally add by the ld wrapper, but ld64 is
being used unwrapped in this check phase. Ensure it can find the
requires SDK stubs by passing them via the clang wrapper.
This commit is contained in:
Randy Eckenrode
2024-10-10 16:23:07 -04:00
parent 39041627fe
commit 2bf9c22eb1
+1
View File
@@ -173,6 +173,7 @@ stdenv.mkDerivation (finalAttrs: {
cd "$NIX_BUILD_TOP/$sourceRoot"
export NIX_CFLAGS_COMPILE+=" --ld-path=$out/bin/${targetPrefix}ld"
export NIX_CFLAGS_LINK+=" -L$SDKROOT/usr/lib"
meson setup build-install-check -Db_lto=true --buildtype=$mesonBuildType${
lib.optionalString (targetPrefix != "") " -Dtarget_prefix=${targetPrefix}"
}