Xcode iOS organizer submit to app store yields “The archive is invalid” error

前端 未结 21 1387
萌比男神i
萌比男神i 2021-01-01 18:35

I just switched from Xcode 3 to 4. When I attempt to upload an app that I have archived to the organizer, I receive this error:

The archive is invalid

21条回答
  •  悲&欢浪女
    2021-01-01 18:45

    A good way to test is to run the build from the command line. Change to your project folder and run 'xcodebuild' and look carefully at the outputs, especially around the 'codesign' command.

    I did this and discovered the following:

    architecture armv7 object: /Users/chris/Documents/x/x/build/Release-iphoneos/x.app/x malformed object
    object file format invalid or unsuitable
    

    So it isn't a solution, but it at least lets you zero in on what the problem is. Anyway, for me, looks like an architecture config error.

    Update - to fix this problem, i replaced the copy of codesign_allocate in my /usr/bin folder with the one in /Developer/somewhere and that fixed it.

提交回复
热议问题