I am trying to create an archive of an iOS app with Xcode to submit it to the App Store. However, the following error message pops up when I select 'iOS Device' as target and click on Product - Archive:
Unable to create a provisioning profile because your team has no devices registered in the Member Center. Please connect a device, enable it for development, and add it to the Member Center using the Organizer.
The same error message also appears when I click the "Fix Issue" button on the app settings page where it tells me that there are no provisioning profiles installed.
There seem to be the following two causes for the issue:
- The App ID is not registered in the Apple Member Center. I have already fixed this. Unfortunately, it didn't help.
- Some older threads mention that you need to add your Mac in the Member Center. However, the instructions given seem to be for older versions of Xcode and don't appear to be working for Xcode 6.1:
- If I go to Window - Organizer, there is no 'Devices' tab
- There is Window - Devices though. I do see 'My Mac' here, however I cannot right click and select 'Add to portal' as there is no such option.
- Under 'Certificates, Identifiers & Profiles' in the Member Center, I cannot add my Mac either. It only seems to accept iOS devices.
I should also mention that I don't own an iOS device (and unfortunately there is no way for me to buy one either) but according to what I've read, it should be possible to submit an app to the App Store without an iOS device.
Thanks in advance for your assistance!
For those who have the same problem: The issue in my case was that I had multiple certificates configured in the Apple Member Center. Xcode's automatic provisioning only seems to work with one certificate.
To solve that problem, you can just manually create a provisioning profile in the Member Center and import that into Xcode. For me, just double clicking the file worked. It didn't show any messages but I was able to use the profile afterwards (it might have also automatically pulled it from the Member Center...).
To actually use that profile, go into the Build Settings of your app. Under the section 'Code Signing', select the right certificate (the one you used to create the profile) and finally the Provisioning Profile itself. It should look something like that:
Now, you should be able to archive your app.
Huge thanks to brendan09 and Legolas-the-elf from reddit who helped me solve the issue: https://www.reddit.com/r/iOSProgramming/comments/2lsjpe/error_when_trying_to_create_archive_of_ios_app/