Xcode 6 GM creating archive

2019-01-13 21:52发布

I am attempting to create an archive .ipa for distribution via testflight. The archive creates, and I choose export, then choose ad hoc, then select my team. However, at this point I get the below screen.

enter image description here

I know that my certificate is valid, as I created an .ipa in xcode 5 with a different provisioning profile about 2 hours before I downloaded xcode 6 GM. I also know that my provisioning profile is valid and connected to said certificate.

Thing is, in xcode 5 it didn't ask for a team; it only asked for a provisioning profile. Now, export asks for a team, which I provide. Also, of course I have a valid iOS Distribution certificate. I'm using it in the build settings to sign my application. Seems like a strange error to get

Any help would be greatly appreciated.

7条回答
冷血范
2楼-- · 2019-01-13 22:13

This is what worked for me. Hope it helps

  1. Delete both the Dev and AdHoc profiles for the particular application from your Mac. (I use Configuration Utility for that)
  2. Quit and then Launch Xcode
  3. Download the provisioning profiles from Apple Dev Portal
  4. Select the new Provisioning from Code Sign Settings
查看更多
SAY GOODBYE
3楼-- · 2019-01-13 22:16

For me the following worked instantly:

  1. Go to keychain access

  2. Delete the trash keys that Xcode or last Mac OS update recovered.

  3. Leave only the "public key" with the "private keys" which contain a litte triangle beside them (which when clicked shows the certificate).

After deleting these thrash keys Xcode 6.0.1. managed to archive a add hoc app for OTA distribution.

This helped me, hope it helps you guys. Gl :)

查看更多
贼婆χ
4楼-- · 2019-01-13 22:19

You have to change your "Code Signing Identity" to "iOS Distribution"

First of all understand that the error message is a BS repurposed message and not accurate to what is happening here. It's not your fault you have wasted so much time on this. This is an example of 1 small flaw in Apple's workflow costing hundreds of thousands of dollars in wasted developer time. But what can we do?

  1. Make sure you have a VALID Provisioning Profile for Ad Hoc distribution in Developer Member Center and download it to your Mac. (This is an important detail as you probably didn't have one of these prior to Xcode 6 because it wasn't required.)
  2. Open the *.mobileprovision file by dragging it to the Xcode icon in your dock.
  3. In Xcode go to Build Settings and find "Code Signing Identity" under "Code Signing".
  4. It's probably going to be set to "iPhone Developer". Change it to "iOS Distribution", even though that sounds like you're making an App Store build.
  5. Find "Provisioning Profile" in Xcode under "Code Signing". Make sure that your Ad Hoc provisioning profile is present in the dropdown list, but select Automatic.
  6. Now you can do: Product > Build; Product > Archive; Export...; And all should be well.

Xcode 6

This is technically the same idea as @steventnorris. I wanted to be more clear because I failed recognize and implement his answer. I had to discover this on my own through much trial and error.

查看更多
倾城 Initia
5楼-- · 2019-01-13 22:24

For me worked following.

  1. Delete distribution profiles from developer portal.
  2. Create new one
  3. Clear and re-archive
查看更多
叛逆
6楼-- · 2019-01-13 22:30

The only way I could generate the AdHoc build (without getting rid of my certificates) was using the command line tool xcbuild as described here:

https://stackoverflow.com/a/25979784/2008167

查看更多
做个烂人
7楼-- · 2019-01-13 22:32

Here's the short version of what worked for me (naturally I had spent hours trying everything else first):

NOTE: Instructions are for Xcode 6.3.2.

  1. Create and install new distribution certificate.
  2. Uninstall old certificate.
  3. Switch provisioning profile to new cert.
  4. Perform Archive. If you're okay with changing your cert, feel free to stop here.
  5. Switch provisioning profile back to original cert.
  6. Perform Archive. Should now work.

Here's the long, detailed version:

  1. Delete the existing Distribution certificate in your Keychain.
  2. Create a new Distribution certificate in the Apple Member Center.
  3. Download and install the new certificate.
  4. Change the project AdHoc provisioning profile to use this new certificate.
  5. In Xcode, click Preferences in the Xcode menu.
  6. Click View Details...
  7. Right Click a provisioning profile at the bottom and choose Show in Finder.
  8. Delete all files in that folder.
  9. Click the refresh button at the bottom of the window in Xcode.
  10. Attempt the Archive again, it should work. Stop here if you're okay with changing certificates regularly.
  11. Delete the new certificate from your Keychain and reinstall the old one.
  12. Change the provisioning profile back to the original certificate.
  13. Repeat the deleting and refreshing of the provisioning profiles.
  14. Attempt the Archive again, it should work. Upload this version.
查看更多
登录 后发表回答