V2EX
   Tag:
 Xcode
Posted in iPhone on October 22nd, 2008 by Xin

I just encountered this problem and finally got it working. Here are some tips if you’ve experienced the same problem:

  1. Try create a new iPhone project in Xcode, and your distribution provisioning profile will show up in the new project. Then back to the problematic project, you may get lucky.
  2. Enter iPhone Distribution in Code Signing Identity, select Code Signing Provisioning Profile and press delete. Switch to distribution configuration and build, if you got lucky, you’ll be prompted about permission or something Keychain, click Always Allow. After build, you may find distribution provisioning profile showing up.
  3. You’ll need to generate and request different certificates for Developer profile and Distribution profile.
  4. Actually you don’t need to enter the name part in Code Signing Identity, just iPhone Developer and iPhone Distribution is enough for Xcode to locate these profiles.

Since Xcode behaves strange and different from what Apple describes in program portal guide, this could be a bug and I hope it gets fixed in next version of Xcode. I believe that many people were mad about this.