CodeSign error: Certificate identity \'iPhone Developer: XXXX (12345678)\' appears more than once in the keychain. The codesign tool requires there only be one.
So I
I just deleted one of the private keys in my keychain for the certificate that I don't need any more.
Even though the certificate re-appers but the private key doesn't reappear. Now check for the valid certificates and only one certificate will appear and the other certificates whose private key is deleted is no longer displayed under valid certificates.
I think this is the simplest way to resolve this issue.