Unable to publish .Net MAUI iOS app failing with Tool xcrun execution finished (exit code = 139) - Stack Overflow

I am trying to generate a build for my iOS application, I run:dotnet publish "SomeDirectoryMyAp

I am trying to generate a build for my iOS application, I run:

dotnet publish "/SomeDirectory/MyApp/MyApp.csproj" -f net8.0-ios -c Release -p:ArchiveOnBuild=true -p:RuntimeIdentifier=ios-arm64  -p:CodesignKey="Apple Distribution: SAMPLE MY APP (RT1234543)" -p:CodesignProvision="sample 25 03 25"

The response is

Tool xcrun execution finished (exit code = 139)

and

usr/local/share/dotnet/packs/Microsoft.iOS.Sdk8.0_18.0/18.0.8319/tools/msbuild/iOS/Xamarin.Shared.targets(2848,3): error : strip exited with code 139

However, the dotnet build command is able to generate the .app build, which I can sign using the codesign command. But it gets rejected by App Store Connect (correctly) saying that it is missing the provisioning profile. Please assist, I am using:

  1. dotnet 8.0.407
  2. dotnet workload SDK 8.0.400
  3. macOS Sonoma (14.7.1)
  4. Xcode 16.1

I am trying to generate a build for my iOS application, I run:

dotnet publish "/SomeDirectory/MyApp/MyApp.csproj" -f net8.0-ios -c Release -p:ArchiveOnBuild=true -p:RuntimeIdentifier=ios-arm64  -p:CodesignKey="Apple Distribution: SAMPLE MY APP (RT1234543)" -p:CodesignProvision="sample 25 03 25"

The response is

Tool xcrun execution finished (exit code = 139)

and

usr/local/share/dotnet/packs/Microsoft.iOS.Sdk8.0_18.0/18.0.8319/tools/msbuild/iOS/Xamarin.Shared.targets(2848,3): error : strip exited with code 139

However, the dotnet build command is able to generate the .app build, which I can sign using the codesign command. But it gets rejected by App Store Connect (correctly) saying that it is missing the provisioning profile. Please assist, I am using:

  1. dotnet 8.0.407
  2. dotnet workload SDK 8.0.400
  3. macOS Sonoma (14.7.1)
  4. Xcode 16.1
Share Improve this question edited Mar 25 at 10:00 dthorbur 1,1413 gold badges13 silver badges26 bronze badges asked Mar 25 at 7:54 Keletso BotsalanoKeletso Botsalano 11 silver badge2 bronze badges 5
  • Do you get the ipa file? – Liqun Shen-MSFT Commented Mar 26 at 1:22
  • @LiqunShen-MSFT, no. The publish fails completely, whereas the build passes but generates the app file. In any case, I have found something github/dotnet/macios/issues/21327. Will upgrade Xcode and provide feedback. – Keletso Botsalano Commented Mar 26 at 6:27
  • Awaiting your good news. By the way, here is the doc for Publish a .NET MAUI app for iOS. Feel free to check it as needed. – Liqun Shen-MSFT Commented Mar 27 at 9:07
  • I have upgraded Xcode to version 16.2 and now I can generate the .ipa file, and upload to App Store, we can consider this closed. – Keletso Botsalano Commented Mar 27 at 19:25
  • Thanks for your sharing @Keletso Botsalano. I just post an answer below and hope it helps those with similar question. Thanks. – Liqun Shen-MSFT Commented Mar 31 at 8:46
Add a comment  | 

1 Answer 1

Reset to default 0

Thanks for your sharing @Keletso Botsalano.

As an answer, if encountering the error info below

Error: strip exited with code 139

Consider upgrading to the XCode16.2 as it has been fixed in Xcode 16.2.

For more information, please refer to Regression: error : strip exited with code 139 #19157, Publish a .NET MAUI app for iOS.

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1744211924a4563374.html

相关推荐

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信