Invalid Binary shown in App Store

Mail From Apple:
An unexpected issue with the mentioned build.
To resolve this issue, please make sure to include the mandatory LC_MAIN command in your EXECUTE executable (Payload/KitchenStory.app/KitchenStory).

I am not understanding how to include LC_MAIN command in Executable


Answered by DTS Engineer in 671883022
LC_MAIN is a Mach-O load command that tells the system where to start your program; see <mach-o/loader.h> for the gory details. You can dump these load commands using otool. For example, here’s what I see when I dump a small iOS test app here in my office:

Code Block
% otool -l Test678672.app/Test678672 | grep -B 1 -A 3 LC_MAIN
Load command 11
cmd LC_MAIN
cmdsize 24
entryoff 17840
stacksize 0


This load command should be inserted automatically by your build tool. Are you building your app using Xcode? How are you submitting it to the App Store? Using the Organizer?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"
Accepted Answer
LC_MAIN is a Mach-O load command that tells the system where to start your program; see <mach-o/loader.h> for the gory details. You can dump these load commands using otool. For example, here’s what I see when I dump a small iOS test app here in my office:

Code Block
% otool -l Test678672.app/Test678672 | grep -B 1 -A 3 LC_MAIN
Load command 11
cmd LC_MAIN
cmdsize 24
entryoff 17840
stacksize 0


This load command should be inserted automatically by your build tool. Are you building your app using Xcode? How are you submitting it to the App Store? Using the Organizer?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"
Yes, we are building our app using Xcode. Using Organizer to submit app. But we are getting invalid binary.
I could not find .app file of my app.

I could not find .app file of my app.

Do this:
  1. Go to the Organizer.

  2. Find the archive you used to submit.

  3. Click Distribute App.

  4. Select App Store Connect > Export (as opposed to Upload).

  5. Continue through the export process, which will eventually result in a folder on disk containing your .ipa and other stuff.

  6. Using the Finder, change the extension on the .ipa to .zip.

  7. Double click it to unpack.

  8. Look inside the Payload directory for your .app.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"
Invalid Binary shown in App Store
 
 
Q