Flutter App unable to build IOS archive

i am trying to build a IOS IPA for generic device, followed all the instructions, added signing certificates, team etc. but i am unable to build the product. any one please help me to resolve this issue.

Checked to automatically managed signing. added device in developer site.

when archiving product, at the end of process it gives error 'exit with non zero code'

" /users/saif/library/developer/xcode/deriveddata/runner-bemaxobcrmqabgcgltuauohrwrje/build/intermediates.noindex/archiveintermediates/runner/installationbuildproductslocation/applications/myapp.app/frameworks/app.framework/app: errsecinternalcomponent command phasescriptexecution failed with a nonzero exit code">****" /users/saif/library/developer/xcode/deriveddata/runner-bemaxobcrmqabgcgltuauohrwrje/build/intermediates.noindex/archiveintermediates/runner/installationbuildproductslocation/applications/myapp.app/frameworks/app.framework/app: errsecinternalcomponent command phasescriptexecution failed with a nonzero exit code"/>
Code Block sent 435785657 bytes received 92 bytes 58104766.53 bytes/sec total size is 435732165 speedup is 1.00 Warning: unable to build chain to self-signed root for signer "Apple Development: ******" /Users/Saif/Library/Developer/Xcode/DerivedData/Runner-bemaxobcrmqabgcgltuauohrwrje/Build/Intermediates.noindex/ArchiveIntermediates/Runner/InstallationBuildProductsLocation/Applications/myapp.app/Frameworks/App.framework/App: errSecInternalComponent Command PhaseScriptExecution failed with a nonzero exit code


i am just stuck on this error for about 3 days. tried each and every solution available on stackoverflow and apple developer forums.
Flutter : 2.0.1 Xcode : 11.2.1

Replies

Hi,

I know the feeling, it's frustrating. I had a similar problem building my Flutter app yesterday and it was to do with the framework. As soon as I removed it then it verified and built and now it's live in the app store.

Try removing the script, you might find that script is not supported in some way either by Flutter, SDK or Apple

errsecinternalcomponent command phasescriptexecution failed with a nonzero exit code"/>
Add a Comment
could you please specify me from where is should remove that script. ?

Getting the same error phasescript failed with error 0. have been stuck with it over a week! Tried building with reinstalling pods, steps mentioned on SO and developer portal.

I can’t help you with third-party build tools but that error, errSecInternalComponent, is likely coming from codesign, as discussed in Resolving errSecInternalComponent errors during code signing.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"