简体   繁体   English

在xcode 6中存档产生的是pkg,而不是ipa

[英]Archive in xcode 6 is producing a pkg, not ipa

Recently updated to Xcode 6 and now whenever I archive a project, I get a .pkg instead of an .ipa. 最近更新到Xcode 6,现在每当我存档一个项目时,我得到一个.pkg而不是.ipa。 I've set the other target in my project (cocoapods) to skip install but that didn't do the trick. 我已经在我的项目中设置了另一个目标(cocoapods)以跳过安装,但这并没有成功。 The deployment target is iOS, not mac (it's an iphone/ipad app that previously archived .ipas fine). 部署目标是iOS,而不是mac(它是以前存档的iphone / ipad应用程序.ipas很好)。

Am I missing a new setting somewhere (ie default archive iOS apps to .ipa) or is there a gotcha with ad hoc distribution on Xcode 6 I'm not aware of? 我错过了某个地方的新设置(即默认存档iOS应用程序为.ipa),还是在Xcode 6上有特别分发的问题我不知道?

Add LSRequiresIPhoneOS YES to your Info.plist LSRequiresIPhoneOS YES添加到您的Info.plist
The key can be found as Application requires iPhone environment 密钥可以在Application requires iPhone environment

I couldn't find a direct way to do this in the Xcode 6 GM (or betas), but found a couple solutions that have worked: 我无法在Xcode 6 GM(或beta版)中找到直接的方法,但发现了一些有效的解决方案:

  1. Archive in Xcode 6 and export in Xcode 5. This worked for me while I was using the betas, but after installing the GM, the Xcode.app binary overwrote my Xcode 5 version (This could be easily reinstalled). 存档在Xcode 6中并在Xcode 5中导出。这在我使用测试版时对我有用,但在安装GM之后,Xcode.app二进制文件覆盖了我的Xcode 5版本(这可以很容易地重新安装)。 @Anan answered that here . @Anan 在这里回答。

  2. Grab the .app file from your .xarchive and package your own .ipa by creating a Payload directory, copying the .app into it, zipping it, and renaming the extension to .ipa. 从你的.xarchive中获取.app文件并打包自己的.ipa,方法是创建一个Payload目录,将.app复制到其中,压缩它,然后将扩展名重命名为.ipa。

  3. I tried using the TestFlight desktop app and dragged the archive into it after creating an account. 我尝试使用TestFlight桌面应用程序,并在创建帐户后将存档拖入其中。 This seemed to go through the motions of packaging the .ipa and uploading it to the TestFlight servers. 这似乎经历了打包.ipa并将其上传到TestFlight服务器的动作。 I wasn't able to find a trace of the .ipa on my local machine. 我无法在本地机器上找到.ipa的痕迹。 This probably works, just not sure where to grab the .ipa. 这可能有效,只是不知道在哪里抓住.ipa。 You would have to generate the .plist on your own or use an old one. 您必须自己生成.plist或使用旧的.plist。

Regardless, this seems like a bug and these workarounds are annoying to have to do for something that used to take 5 seconds to complete. 无论如何,这似乎是一个错误,这些变通办法对于过去需要5秒才能完成的事情而言非常烦人。

Steve 史蒂夫

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM