-
Notifications
You must be signed in to change notification settings - Fork 4.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
xcode-select : error : tool 'xcodebuild' requires Xcode - new error with nativeaot in .NET 9 preview 2 #100189
Comments
Tagging subscribers to this area: @agocke, @MichalStrehovsky, @jkotas |
@LLT21 Please check https://stackoverflow.com/questions/55939354/tool-xcodebuild-requires-xcode-but-active-developer-directory-library-devel for how to work around this issue for now. This is regression from #97856 / #98726 . cc @VSadov @filipnavara Can we check e.g. |
I'm not sure if the same regex works for the build version of other tools. For reference, on my machine:
The clang version only loosely correlates to the Xcode version, so it's not perfect. We'd lose the ability to enable the new ld64 on minor Xcode release, at very least. Xamarin also has a similar check, so we should double check what they are doing. |
https://github.com/xamarin/xamarin-macios/blob/a150c6068c1b5659af4f0b7217bdf572c1e213b4/dotnet/targets/Xamarin.Shared.Sdk.targets#L1599-L1601 |
For reference, on the same machine with just command line tools installed:
|
The regex picks up the first number that it sees in the output. As far as I can tell, it works for the clang output just fine.
We just need something simple that works out-of-the-box for the common cases. The logic does not need to be perfect. In case we need to do something extra for minor xcode releases in future, we can deal with once it shows up. |
For your information: on my MacBook Air M1 I do not have Xcode installed, only the command line tools. This because it only has 256GB and Xcode is pretty big. Up to now this worked fine up to .NET 9 preview 1 for NativeAOT compilation of asp.net applications. |
Fixes #100189 Co-authored-by: Jan Kotas <[email protected]>
With the following project file settings:
when publishing in release mode, I receive the following errors on my Mac M1 with .NET 9 preview 2, which I do not have with previous versions:
The text was updated successfully, but these errors were encountered: