This fixes actual cross-compile cases, like compiling for Apple Silicon on an Intel Mac. It also makes builds more consistent by using the SDK in the installed Xcode instead of the host root headers, which is how Apple recommends people build anyway. (If you only have the command line tools installed, though, it should fall back to those without a problem.)
This fixes actual cross-compile cases, like compiling for Apple Silicon on an Intel Mac. It also makes builds more consistent by using the SDK in the installed Xcode instead of the host root headers, which is how Apple recommends people build anyway. (If you only have the command line tools installed, though, it should fall back to those without a problem.)