无法从 XCode 6.1 导出 IPA 文件
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/27061729/
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
Can not export IPA file from XCode 6.1
提问by Akshit Zaveri
I've wasted a day trying to export IPA file using development profiles. I'm a developer since 18 months now. And its not something that i don't know about exporting IPA. And i really hate Apple developers for changing the way we used to export a simple IPA. I've already exported hundreds of times but this time i'm having no luck.
我浪费了一天试图使用开发配置文件导出 IPA 文件。我从 18 个月开始就是一名开发人员。这不是我不知道出口 IPA 的事情。我真的很讨厌 Apple 开发人员改变我们过去导出简单 IPA 的方式。我已经出口了数百次,但这次我没有运气。
I think what is needed to export a successful IPA requires these things to be available in the system
我认为导出成功的 IPA 需要这些东西在系统中可用
- Private key with Certificate in Keychain -> Login -> My Certificates
- Login in with developer account in XCode -> Preferences -> Accounts
- Archive the project and select Export -> Save for Ad Hoc Deployment -> Select developer account from the list.
- Wait until XCode does some magic. (This is the part where XCode fails everytime. See attached screenshot please)
- 在钥匙串中带有证书的私钥 -> 登录 -> 我的证书
- 在 XCode 中使用开发者帐户登录 -> Preferences -> Accounts
- 存档项目并选择导出 -> 保存以用于临时部署 -> 从列表中选择开发者帐户。
- 等到 XCode 施展魔法。(这是 XCode 每次都失败的部分。请参阅附件截图)
Here's what i've tried:
这是我尝试过的:
- Removing all keychain certificates and provisioning profiles. - DIDN'T WORKED
- Restart XCode and System (Almost 3 times) - DIDN'T WORKED
- Removing certificates and provisioning profiles from Apple developer portal and regenerate all of them. - DIDN'T WORKED
- Tried AirSign / Testflight. - DIDN'T WORKED
- 删除所有钥匙串证书和配置文件。-没用
- 重新启动 XCode 和系统(几乎 3 次)-不起作用
- 从 Apple 开发人员门户中删除证书和配置文件并重新生成所有这些。-没用
- 尝试 AirSign / Testflight。-没用
HINT: I am using XCode 6.1.1 GM SEED and previously had installed along with XCode 6.2 beta. But i removed XCode 6.2 Beta later
提示:我使用的是 XCode 6.1.1 GM SEED,之前已与 XCode 6.2 beta 一起安装。但我后来删除了 XCode 6.2 Beta
Someone please tell me where i'm going wrong.. Thanks...
有人请告诉我哪里出错了..谢谢...
采纳答案by Libran Coder
Starting from XCode 6, you have to generate an AdHoctype cerificate from the Apple Developer Center to be able to save the .ipafor AdHoc deployment. I was also facing the same issue and generated a new certificate particularly for AdHoc Distribution. Archiving using that resolved the issue.
从 XCode 6 开始,您必须从 Apple Developer Center生成AdHoc类型证书才能保存.ipa以进行 AdHoc 部署。我也面临同样的问题,并特别为AdHoc Distribution生成了一个新证书。使用它进行归档解决了这个问题。
回答by dulgan
I'd recommend you using the fastlane tools to handle every aspects of code signing and ipa generation.
我建议您使用 fastlane 工具来处理代码签名和 ipa 生成的各个方面。
The cert command allows you to create a new certificate as needed : no option for distribution certificate, --developement for a development one.
cert 命令允许您根据需要创建新证书:分发证书没有选项,--developement 用于开发证书。
The sigh command allows you to create a new provisionning profile : no options = app store, --adhoc = ad hoc, --development = development
sigh 命令允许您创建新的配置文件:no options = app store, --adhoc = ad hoc, --development = development
The gym command allows you build ipa, same options as above !
健身房命令允许您构建 ipa,与上面相同的选项!
Meanwhile there's a trick for dev ipa generation : - set your code signing assets as needed for development in Xcode target
同时,开发 ipa 生成有一个技巧: - 根据 Xcode 目标中的开发需要设置您的代码签名资产
- build the app for a device
- Go to te "Product" group folder in Xcode files navigator
- Ctrl-click on yourApp.app and click "Show in finder"
- Copy the .app in a new folder called "Payload"
- Create a zip from this folder using Ctrl+click, archive
- Rename this archive as yourApp.ipa
- 为设备构建应用程序
- 转到 Xcode 文件导航器中的“产品”组文件夹
- 按住 Ctrl 键单击 yourApp.app,然后单击“在查找器中显示”
- 将 .app 复制到名为“Payload”的新文件夹中
- 使用 Ctrl+单击从此文件夹创建 zip,存档
- 将此存档重命名为 yourApp.ipa
You're now able to install this dev signed ipa over the air or through iTunes on the devices recorded in the provisionning profile used to build the app.
您现在可以通过无线方式或通过 iTunes 在用于构建应用程序的配置文件中记录的设备上安装此开发者签名的 ipa。
回答by Sukeshj
You will not get this issues if you create certificated through xcode.
如果您通过 xcode 创建证书,则不会遇到此问题。
xcode->Preferences->Select Apple id->select account->view details->click on plus button
xcode->首选项->选择Apple id->选择帐户->查看详细信息->点击加号按钮
Useing this certificate revoke your provisioning profile then again
使用此证书会再次撤销您的配置文件
xcode->Preferences->Select Apple id->select account->view details-> click on refresh button
xcode->首选项->选择Apple id->选择账户->查看详情->点击刷新按钮
Now you will not get this error
现在你不会得到这个错误
回答by Vinod
Try installing your distribution certificate and profile before creating IPA with developer profile. I faced this issue and that fixed it.
在使用开发人员配置文件创建 IPA 之前尝试安装您的分发证书和配置文件。我遇到了这个问题并解决了它。