警告 ITMS-90080:“可执行文件 'Payload/myapp.app/Frameworks/some-framework.framework' 不是与位置无关的可执行文件

WARNING ITMS-90080: "The executable 'Payload/myapp.app/Frameworks/some-framework.framework' is not a Position Independent Executable

我以前能够毫无问题地提交我的申请。我的工作流程中唯一改变的部分是使用 Sourcetree。在对以下框架进行更新后,我在提交到 iOS App Store 时收到此警告。我还收到一封电子邮件,其中包含:

Non-PIE Binary - The executable 'Payload/myapp.app/Frameworks/Alamofire.framework' is not a Position Independent Executable. Please ensure that your build settings are configured to create PIE executables. For more information, refer to Technical Q&A QA1788 - Building a Position Independent Executable

Non-PIE Binary - The executable 'Alamofire.framework' is not a Position Independent Executable. Please ensure that your build settings are configured to create PIE executables. For more information, refer to Technical Q&A QA1788 - Building a Position Independent Executable

etc...

有问题的著名框架是:

我看过Apple Technical QA文章,手动设置了这些框架的所有部署目标和我自己的项目都没有用。有没有人以前见过这个问题并能够解决它?

更新:

我可以确认这些警告不会影响提交审批流程。我为 public 版本提交了我的应用程序,尽管有警告,它还是获得了批准。现在我很好奇 Apple 端发生了什么,以及这对框架开发人员意味着什么。

看来是苹果方面的bug,我今天也遇到了。看这里:

https://github.com/CocoaPods/CocoaPods/issues/5453

总结 link 中的信息,最近成功提交的构建没有设置 PIE 标志,并且通过了 OK。所以看起来要么苹果正在改变某些东西,要么它可能是一个错误。

得到同样的东西。不确定它是否相关,但所有构建都已从帐户中删除(发布后是否正常)。

还有一个问题,我收到一封电子邮件,说我的构建在审核期间已完成处理,但我已经一个多星期没有上传新构建了。

Apple 的服务器本周报告了问题。

感觉苹果这边有问题

您好,我遇到了同样的问题,在我尝试将存档上传到 iTune connect 之前没有问题,它给出了您收到的警告消息。我还收到了 Apple 发来的电子邮件,要求修复此警告消息。

"The executable '******/.framework' is not a Position Independent Executable. Please ensure that your build settings are configured to create PIE executables. For more information, refer to Technical Q&A QA1788 - Building a Position Independent Executable" .

我按照 https://developer.apple.com/library/ios/qa/qa1788/_index.html#/apple_ref/doc/uid/DTS40013354 中描述的步骤操作。并执行清理 - 构建。构建成功。但是当我选择 "Generic iOS Devices" 时,构建失败并显示错误消息“-no_pie 和 -bitcode_bundle(Xcode 设置 ENABLE_BITCODE=YES)不能一起使用错误”。为了解决这个问题,我在 Target 中将 "Enable Bitcode" 的选项更改为 NO。

这解决了构建问题。现在,当我尝试将存档上传到 iTune connect 时,它给了我错误 "ERROR ITMS-90635 'Invalid Mach-O Format. ............. Verify that all of the targets for a platform have consistent value for the ENABLE_BITCODE build setting.'" 上传失败。

现在要解决此问题,我在上传对话框中取消勾选选项 "include bitcode",上传按预期进行,没有任何警告或错误。