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
clang++ exited with code 1 #16778
Comments
I have the same issue, but my physical device still works. Tried a bunch of things:
|
@rolfbjarne - any suggestion where this issue should go? |
Looks like AppCenter doesn't ship support for the iossimulator-arm64 architecture, so this is an AppCenter issue. |
@rolfbjarne ah good to know. Any idea which of the various AppCenter repos this should go to? There are quite a few: https://github.com/orgs/microsoft/repositories?q=appcenter&type=all&language=&sort= |
Closing this as this is a bug in AppCenter. Please open a new issue there. |
@rolfbjarne @mattleibow nonesense , that is not an AppCenter issue as can be read here on SO! But how to exclude |
If you want to force x64 when building in Visual Studio, add this to your project: <PropertyGroup>
<ForceSimulatorX64ArchitectureInIDE>true</ForceSimulatorX64ArchitectureInIDE>
</PropertyGroup> If you're building from the command line, you need to specify the
|
There seems there's nothing on the MAUI side we can do so we are closing this issue for now. Thanks |
Can confirm that it works, but only when you place the Correct one is (if net7.0-ios is the TFM):
|
Interesting that the .NET MAUI team is not responsible for tooling issues with .NET MAUI. Who is responsible for such one? |
The underlying issue is that the AppCenter NuGet doesn't support the ARM64 architecture in the simulator. The answer in the SO link you posted (https://stackoverflow.com/a/73507083) says to tell Xcode to not build for ARM64 (in the simulator). The answer I posted yesterday (#16778 (comment)) is the equivalent for Visual Studio: it tells Visual Studio to not build for ARM64 (in the simulator). Both of these answers are just workarounds for the underlying problem: that the AppCenter NuGet doesn't support ARM64 in the simulator.
Maybe this one: https://github.com/microsoft/appcenter-sdk-dotnet? |
@rolfbjarne Thanks for taking the time for explaination |
Might be better to put in csproj.user so it doesnt mess with debugging on mac. |
You can also condition for Mac, at the top of the csproj there is a condition for windows to add the windows tfm. Just use that and swap to check for macos |
Hello lovely human, thank you for your comment on this issue. Because this issue has been closed for a period of time, please strongly consider opening a new issue linking to this issue instead to ensure better visibility of your comment. Thank you! |
Description
1>C:\Program Files\dotnet\packs\Microsoft.iOS.Sdk\16.4.7089\targets\Xamarin.Shared.Sdk.targets(1274,3): error : ld: in /Users/erichbrunner/Library/Caches/Xamarin/mtbs/builds/MauiApp1/c7d11821f579f7be20cca70bea58f9077387ac6e7fda6c0f0bf0598883d8d781/obj/Debug/net7.0-ios**/iossimulator-arm64**/linker-cache/AppCenterCrashes.a(MSACErrorReport.o), building for iOS Simulator, but linking in object file built for iOS, file '/Users/erichbrunner/Library/Caches/Xamarin/mtbs/builds/MauiApp1/c7d11821f579f7be20cca70bea58f9077387ac6e7fda6c0f0bf0598883d8d781/obj/Debug/net7.0-ios/iossimulator-arm64/linker-cache/AppCenterCrashes.a'
1>C:\Program Files\dotnet\packs\Microsoft.iOS.Sdk\16.4.7089\targets\Xamarin.Shared.Sdk.targets(1274,3): error : clang: error: linker command failed with exit code 1 (use -v to see invocation)
1>Done building project "MauiApp1.csproj" -- FAILED.
Steps to Reproduce
Visual Studio
Installed Workloads
Link to public reproduction project repository
https://github.com/ericbrunner/MauiClangError.git
Version with bug
maui-ios 8.0.0-preview.7.8842/8.0.100-preview.7 VS 17.7.34009.444
ios 16.4.8694-net8-p7/8.0.100-preview.7 VS 17.7.34009.444
Is this a regression from previous behavior?
No, this is something new
Last version that worked well
Unknown/Other
Affected platforms
iOS
Affected platform versions
iPhone 14 iOS 16.1
Did you find any workaround?
No. I tried to set
<PropertyGroup Condition="'$(Configuration)|$(TargetFramework)|$(Platform)'=='Debug|net7.0-ios|AnyCPU'"> <RuntimeIdentifier>iossimulator-arm64</RuntimeIdentifier> </PropertyGroup>
in MAUI .csproj without any working result. Taken from comments of #12124
Relevant log output
see gist of
build output pane
The text was updated successfully, but these errors were encountered: