I feel your pain, I went through this very thing during submission last night.
So much "tribal knowledge" shrouds this process, it surely needs some cleanup on Apple's side of things...
Sadly, I can't pin down for sure what specific bit of magic made the beast happy; but fwiw, here's my Rain Dance outlined:
1) When installing the provisioning profiles via dropping them onto XCode, it appears to install them via their internal UUIDs (presumably to avoid naming conflicts) to their home of ~/Library/MobileDevice/Provisioning Profiles. That seemed a bit fishy upon perusal of the build logs, as the file name is at times referenced, and the external name" is at times references, so ...
2) I blew away the profiles found here and copied afresh my 3 profiles (developer, ad-hoc and app store distribution) into the ~/Library/MobileDevice/Provisioning Profiles directory manually without dragging them onto XCode.
3) I re-downloaded the WWDR intermediate certificate (to sate paranoia) and the Agent's (sounds like you are in an individual program, so does not apply) private key via a p12 export.
4) I fired up XCode and set the active SDK to device and went into the target's Build configuration. From here I verified that the Code Signing Identity was "iPhone Distribution: <our company name>" and I could see then see the 2 provisioning profiles for Ad-hoc and App Store listed (by name, UUID nonsense was vanquished), and manually selected the App Store profile.
5) I did a ritualistic clean. Killed XCode. Fired it back up and built, and much rejoicing as the app passed codesign on the happy joy joy submit.
Now, if I could only get all this to happen repeatedly on our build server....
|