XCode:无法使用通用设备创建配置文件

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/48394285/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-15 10:31:35  来源:igfitidea点击:

XCode: Failed to create provisioning profile w/ Generic Device

iosxcodeionic-framework

提问by MatTaNg

I am trying to release my ionic app for iOS but I am getting this error below when I try to archive my app in Xcode:

我正在尝试为 iOS 发布我的 ionic 应用程序,但是当我尝试在 Xcode 中存档我的应​​用程序时出现以下错误:

enter image description here

在此处输入图片说明

I have created a profile and added iOS Distribution and iOS developer certificates:

我创建了一个配置文件并添加了 iOS 分发和 iOS 开发人员证书:

enter image description here

在此处输入图片说明

I have tried various solutions found online such as unchecking and checking Automatically Manage Signing, changing Deployment Target from 8.0 -> 7.0 and even closing and reopening Xcode. Yes, I paid the $100 for a developer account.

我尝试了各种在线找到的解决方案,例如取消选中和选中自动管理签名,将部署目标从 8.0 -> 7.0 更改为甚至关闭并重新打开 Xcode。是的,我为开发者帐户支付了 100 美元。

I also do not have an iOS device which may be the problem. I should be able to do this without an iOS device though right?

我也没有 iOS 设备,这可能是问题所在。我应该能够在没有 iOS 设备的情况下做到这一点,对吗?

Also, I was following this tutorial https://code.tutsplus.com/tutorials/distributing-ios-apps-with-itunes-connect--cms-21672but I got stuck at the end - It doesn't tell me what to put in here on iTune Connect:

另外,我正在关注本教程https://code.tutsplus.com/tutorials/distributing-ios-apps-with-itunes-connect--cms-21672但我最后卡住了 - 它没有告诉我什么在 iTune Connect 上输入:

enter image description here

在此处输入图片说明

Any help is appreciated - Thanks.

任何帮助表示赞赏 - 谢谢。

EDIT: All the 'stuff' I did:

编辑:我所做的所有“东西”:

Here is the app information I filled out as suggested by a comment (I have not submitted it yet - I believe I need to Archive it first?):

这是我根据评论的建议填写的应用程序信息(我还没有提交 - 我认为我需要先存档?):

enter image description here

在此处输入图片说明

Here is my Provisioning Profile. I downloaded it and opened it in Xcode. I tried to archive it but I got the described error:

这是我的配置文件。我下载了它并在 Xcode 中打开它。我试图存档它,但我收到了描述的错误:

enter image description here

在此处输入图片说明

Heres my distribution thing (Should be in my provisional profile):

这是我的分发内容(应该在我的临时配置文件中):

enter image description here

在此处输入图片说明

And also my key (Should be in my provisional profile):

还有我的钥匙(应该在我的临时档案中):

enter image description here

在此处输入图片说明

I also have this certificate in my Keychain:

我的钥匙串中也有这个证书:

enter image description here

在此处输入图片说明

Edit Edit:

编辑编辑:

Dragging the provision profile onto Xcode didn't do anything. I went into Xcode and manually opened it with Xcode and got this thing:

将配置文件拖到 Xcode 上没有任何作用。我进入Xcode并用Xcode手动打开它并得到这个东西:

enter image description here

在此处输入图片说明

Is the file type correct? Its called Moment_Provisioning_Profile-2.mobileprovision. This is the file I got when I hit download on the above screenshot.

文件类型是否正确?它叫做Moment_Provisioning_Profile-2.mobileprovision. 这是我在上面的屏幕截图上点击下载时得到的文件。

回答by MAhipal Singh

first: if you have not register your bundle id in the apple developer center for your app, then goto "Certificates, identifiers and profile"section: https://developer.apple.com/membercenter/index.actionand register it after that..

第一:如果你还没有在苹果开发者中心为你的应用注册你的 bundle id,那么转到“证书、标识符和配置文件”部分:https: //developer.apple.com/membercenter/index.action然后注册它..

uncheck Automatically Manage Signing,

取消勾选 Automatically Manage Signing,

and select your downloaded profile : and then clean and build again. enter image description here

并选择您下载的配置文件:然后清理并再次构建。 在此处输入图片说明

for more about xcode help

有关xcode 帮助的更多信息

EDITED

已编辑

Step 1: Clear the derived data

第 1 步:清除派生数据

Step 2: then download the provision profile & certificate from developer account

第 2 步:然后从开发者帐户下载配置文件和证书

Step 3: install the certificate by double clicking on it

第三步:双击安装证书

Step 4: drag provision profile on xcode icon in Dock. enter image description here

第 4 步:在 Dock 中的 xcode 图标上拖动配置文件。 在此处输入图片说明

Step 5: uncheck "automatic code sigining" option and selected the provision profile from list as shown above

第 5 步:取消选中“自动代码签名”选项并从列表中选择配置文件,如上所示

回答by Ajay

  1. You need to add your device UDID in Apple developer certificates and identifier section.
  2. Recreate and install provisioning profile.
  3. Make sure you are using correct app ID/ bundle identifier in your bundle settings.
  4. Xcode should pick up provisioning profile automatically, if not uncheck automatic box and select your developer provisioning profile. Hope this will help.
  1. 您需要在 Apple 开发者证书和标识符部分添加您的设备 UDID。
  2. 重新创建并安装配置文件。
  3. 确保您在捆绑设置中使用正确的应用 ID/捆绑标识符。
  4. Xcode 应该自动选择配置文件,如果没有取消选中自动框并选择您的开发人员配置文件。希望这会有所帮助。