[questions]
[solution]
Open project with Xcode
Command + K restart the computer
Reference: Xcode packing error command codesign failed with a nonzero exit code
[wrong guess]
After reading other people’s summary, I feel that it may be the problem caused by updating the Mac operating system
From:
Xcode packaging failed: xcrun codesign failed with exit code 1
[summary]
Here is the requirement after upgrading MacOS High Sierra
1. Set the login password and the password of Apple Developer account (= = icloud), otherwise
2. Later, I jumped out of the login dialog box many times and asked to enter icloud’s password – “because I couldn’t remember the password clearly at that time
3. After that, I entered the correct password immediately, but due to network problems, I failed to log in normally
4. And later, although the network was successful and the password was correct, it did not disappear because of the previous pop-up box
This seems to lead to:
The apple related (project) Certificate in login is estimated to be unable to be accessed normally
-, which leads to an error in codesign when Xcode goes to archive to package the project
The solution is:
Make sure that icloud’s login password has been updated and logged in after upgrading MacOS High Sierra
Here is:
Restart the Mac, making the previous box disappear
When you want to enter the password, enter the correct password and log in to icloud
If not, go to Keychain to reset the login password
Keychain access edit change password for Keychain login
In this way, Xcode can have the right to access the certificate in the keychain with the correct password, and can code design and package normally