All of your programming will be for naught if you don’t sign up for the iOS Developer Program with Apple. This is a multistep process that can take quite some time, so make sure to get it all in hand well before you want to upload your program to the App Store.
To get started, you must register as a developer at http://developer.apple.com/devcenter/ios/. When you register, you’re asked for some basic information about what you’ll be developing, and you need to sign Apple’s Terms & Conditions for working with the iOS. You’ve probably already done this step, because it’s required in order to get access to the SDK and the online documentation.
Sometime afterward—maybe in a few hours, maybe in a few weeks—you’ll get a call from Apple confirming your signup information and giving you the OK for the program. Apple will then send you an email that allows you to finish your registration. At this point, expect to pay a fee, currently $99/year (standard) or $299/year (enterprise), to become a full-fledged developer. The standard program allows for distribution via the App Store, and the enterprise program allows distribution of in-house applications to over 500 employees.
The first advantage of being a registered iOS developer is that you can compile programs directly to your device. This is fairly critical for certain types of testing. As you’ve seen in this book, features like altitude detection, volume control, and the accelerometer don’t work correctly when tested in the Simulator.
To compile to a device, you must create a provisioning profile, which is a multistep process. You need to use some new tools that appear under a Program Portal link at the top of http://developer.apple.com after you finish your signup and pay your fee. Apple has a complete “iTunes Connect Developer Guide” that explains how to use everything here, but we’ll outline the main steps:
Your certificate will be permanently installed in your keychain; if you rebuild your machine or move to a new machine, you’ll lose it. To avoid this, be sure you export the private key associated with your developer certificate. You can then import it on a different machine, and redownload the two certificates from Apple. If you fail to do this, a Team Admin may need to revoke your certificate so that you can create a new one.
Although the setup can be a bit extensive for an Admin, after the initial work is done, a member can create a CSR, download a certificate, and download a provisioning profile. From that point, the member can choose to compile onto a device rather than to the iOS Simulator by changing the pop-up window at upper left in Xcode.
Preparing your program for distribution via the App Store follows much the same process as preparing your programs for testing on iPhones on iPads, except that the steps can only be undertaken by the Team Agent:
These procedures may change over time; but for now, this is what you need to do to get your program from your desktop to the App Store.
There are also two alternative ways to distribute your software: enterprise distribution lets you distribute an in-house application to employees within your company, and ad hoc distributions let you distribute to up to 100 other users by email or a web-site. Both are explained further in Apple’s documentation.