You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
XCode.cs: Statically link libraries when forcing AOT (#48156)
The fix in #48135 wasn't fully correct since it just fixed the problem for libSystem.Native but not the other libraries.
The real problem is that we're setting `preferDylib` to true via `!isDevice` but still generate the pinvoke mapping to `__Internal` for all files where an `.a` file is found.
The reason why this works in the simulator on non-AOT cases is because we only call the `register_dllmap` function when we're actually forcing AOT on the simulator: https://github.com/dotnet/runtime/blob/42009d1f33b52e40e5471d5c0d3ff4a8d5b2b83a/src/tasks/AppleAppBuilder/Templates/runtime.m#L239-L240
The better fix is to extend the check to always apply when forceAOT is true.
0 commit comments