3

I installed Xcode 4, thinking it would be similar to Xcode 3, and now I cannot get my binary to the App Store using organizer which I believe is the proper way to do this.

Has anyone got this working properly? Not sure what setting I need to update - All I get is an "invalid binary" message. Of course, it is a critical update I need to submit.

Moshe
  • 57,511
  • 78
  • 272
  • 425
Slee
  • 27,498
  • 52
  • 145
  • 243
  • By the way, there is an [App Store proposal on Area 51](http://area51.stackexchange.com/proposals/30702/app-store/) for mobile developers. – Moshe Mar 28 '11 at 20:21

2 Answers2

9

I've had something similar. You should check your code signing settings. Xcode 4 introduces "schemes", which are a little complicated. Think of them as sets of configurations. In Xcode 3, you could only have one such set of settings.

I believe that you need to check your code signing settings for your active scheme. Check the "Archive" option.

Edit your code signing settings:

Set up code signing

Then, ensure that your "Archive" option is using the correct signing settings. Click on the "Edit Scheme" entry in the menu on the top left of your window.

enter image description here

And then verify that the proper signing setting is being used:

enter image description here

Depending on how you've set up your code signing and Build Settings, you may need to adjust your schemes appropriately.

Moshe
  • 57,511
  • 78
  • 272
  • 425
  • Note that you'll need to sign the release build using a distribution profile in order for iTunes to accept the app. If you don't, XCode will submit the binary just fine, but you'll see an "Invalid Binary" error in iTunes Connect. – avaynshtok May 19 '11 at 07:28
  • @avaynshtok - You mean when you submit the binary, you have to select the distribution profile. However in the Code Signing section of the build settings, you still want the developer profile selected for the release build configuration, correct? – Aaron Douglas May 23 '11 at 15:28
  • Yes. See my answer below. To future googlers: he's talking about the the certificate you select when you are in Organizer in XCoder 4 and submitting the archive to the app store. *That's* the point where you select the distribution profile. – Jack BeNimble Oct 15 '11 at 12:22
2

After trying a wide variety of options over a period of two intensive and enormously frustrating days, only to be faced with the cryptic and utterly unhelpful "invalid binary" message, I reviewed this post again.

When I reviewed avaynshtok's question - "You mean when you submit the binary, you have to select the distribution profile. However in the Code Signing section of the build settings, you still want the developer profile selected for the release build configuration, correct?"

Although it wasn't answered, it got me to think about the profile you select when you are in Organizer and select the "Submit" button. I took another look and realized that you need to set the distribution profile there, for which I had been just accepting the default until now.

So, I set my "AppStore" archiving profile back to use the development certificates, as suggested above. I then resubmitted using the distribution profile at the Organizer "submit" time, and voila - it passed.

Question to Apple: you guys have $70,000,000,000 in cash. Can you afford to update the apps store submission procedure docs and "invalid binary" message to be a tad more clear? I'd be fired if I produced such low quality work.

Flexo
  • 87,323
  • 22
  • 191
  • 272
Jack BeNimble
  • 35,733
  • 41
  • 130
  • 213