How can I build for release/distribution on the Xcode 4?

后端 未结 9 1477
鱼传尺愫
鱼传尺愫 2020-12-07 13:53

Build for debug is just press on the PLAY symbol, but I don\'t know how to Build for distribution/release?

相关标签:
9条回答
  • 2020-12-07 14:55

    I have a large app that was having problems uploading to the AppStore using the archive method you will find in XCode 4. The activity indicator kept spinning for hours whether I was trying to validate or distribute, so I created a support ticket to Apple. During that process, I found out you could right click on the .app in your Products folder inside the Project Navigator of XCode, and compress the app to submit using the Application Loader 2.5.1. (aka the old method). Only the Debug - iphoneos folder is accessible this way (for now) and once Apple responded, this is what they had to say:

    I'm glad to hear that Application Loader has provided you a viable workaround. Discussing this situation internally, we're not sure that submitting the Debug build will pose too much of a problem (so long as it was signed with the App Store distribution profile, as you mentioned it was). The app will likely be slower as the debug switches are turned on and optimizations are turned off for the Debug configuration, though it will still run. App Review will ultimately determine whether or not that's ok, as I'm not sure that's something they check for. You could try reaching out directly to App Review to confirm this, if you wish. However, since App Loader is working for you, I do recommend rebuilding the app with your Release configuration and resubmitting to play it safe. To find your Release build in Xcode 4.x, control-click on the Application Archive on the Archives tab in the organizer, and choose "Show in Finder." Then, control-click on the .xcarchive file in Finder and choose "Show Package Contents." The release built .app file should be located within the /Products/Applications folder.

    This was very helpful information for developers who are having problems with the archive method, and my app is now uploading successfully without any concern that it won't run to the best of it's ability.

    0 讨论(0)
  • 2020-12-07 14:56

    They've bundled all the target/build configuration/debugging options stuff into "schemes". The transition guide has a good explanation.

    0 讨论(0)
  • 2020-12-07 14:57

    The short answer is:

    1. choose the iOS scheme from the drop-down near the run button from the menu bar
    2. choose product > archive in the window that pops-up
    3. click 'validate'
    4. upon successful validation, click 'submit'
    0 讨论(0)
提交回复
热议问题