I m stuck with this error:
Code Sign error: Certificate identity \'iPhone Developer: My Name (xxx)\' appears more than once in the keychain. The codesign tool requir
Xcode 4.3 now searches all keychains for signing certificates but that is increasing the frequency of the build error:
Certificate identity (x) appears more than once in the keychain...
Apple's steps to resolve it are here: "How do I resolve the CodeSign error: Certificate identity appears more than once in the keychain?"
However, if you are affected by the keychain bug mentioned in the final note of that guide, following is a simpler and preferred solution to problem:
1) Keychain Access > Edit > Keychain List, uncheck "Shared" for the login keychain.
2) next, IF going back into the Keychain List you find the login keychain is still marked as Shared, create a backup of the following files and then remove them if they exist:
/Library/Preferences/com.apple.security-common.plist
~/Library/Preferences/com.apple.security.plist
3) Retry your build.