(XCode 4.0.2) 存档构建(为在应用商店上分发而构建)armv6 警告

发布于 2024-11-06 04:45:05 字数 803 浏览 0 评论 0原文

我发誓我即将最终使用 XCode 4.0.2 提交应用程序。 但我担心我现在遇到了一个相当陡峭的障碍。

无论我做什么,我总是会收到 1-2 个与 armv6 架构相关的警告。 我已经设置了项目和要使用的目标构建设置:

  • 架构:标准 (armv6 armv7)
  • 基础 SDK:最新 iOS 4.3
  • 仅构建活动架构:选中或未选中似乎并不存在有所作为)
  • 支持分发平台:iphoneos
  • 有效架构:armv6 armv7

存档后(分发到应用程序商店)我总是收到这些警告:

  • iphone 应用程序应包括armv6 架构(当前 ARCHS =“armv7”)。
  • iPhone/iPod Touch:应用程序可执行文件缺少所需的体系结构。必须至少存在以下架构之一:armv6 (-19033)

请提供帮助。

* 更新 *

只需在某处读到 Base SDK 需要设置为 iOS 4.0 而不是“最新 iOS (iOS 4.3)”。它在没有警告的情况下构建/存档。

* 再次更新 *

忽略我之前的更新评论。导致干净存档构建的原因是取消选中“仅构建活动架构”选项。不知道为什么它决定现在构建良好,因为这个复选框最初没有被选中,但只有在我开始更改内容以尝试首先修复警告之后。

I swear I am close to finally submitting an app with XCode 4.0.2.
But i am afraid i've come across a pretty steep obstacle to hurdle now.

No matter what I do i always get 1-2 warnings related to the armv6 architecture.
I have set both Project & Target build settings to use:

  • Architectures: Standard (armv6 armv7)
  • Base SDK: Latest iOS 4.3
  • Build active architectures only: checked or unchecked doesnt seem to make a difference)
  • Support platforms for Distribute: iphoneos
  • Valid architectures: armv6 armv7

Upon archiving (to distribute to app-store) I always get these warnings:

  • iphone apps should include an armv6 architecture (current ARCHS = "armv7").
  • iPhone/iPod Touch: application executable is missing a required architecture. At least one of the following architecture(s) must be present: armv6 (-19033)

Please help.

* UPDATE *

Just read somewhere that the Base SDK needs to be set to iOS 4.0 instead of "Latest iOS (iOS 4.3)". It built/archived without warnings.

* UPDATED AGAIN *

Disregard my previous update comment. The thing that caused a clean archive build was the unchecking of the "Build active architectures only" option. Not sure why it decided to build fine now cuz this checkbox wasn't checked initially, but only after i started changing things in trying to fix the warning in the first place.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

违心° 2024-11-13 04:45:05

确保 Xcode 中的构建设置。

  • “架构”应为“标准(armv6 armv7)”
  • “仅构建活动架构”应为“否”。
  • “有效架构”应该是“armv6 armv7”。

它能够使用 file 命令检查存档的应用程序二进制文件。

$ file Payload/Foo.app/Foo
Payload/Foo.app/Foo: Mach-O universal binary with 2 architectures
Payload/Foo.app/Foo (for architecture armv6):   Mach-O executable arm
Payload/Foo.app/Foo (for architecture armv7):   Mach-O executable arm

Make sure build settings in Xcode.

  • "Architectures" should be "Standard (armv6 armv7)"
  • "Build Active Architecture Only" should be "NO".
  • "Valid Architectures" should be "armv6 armv7".

It is able to check the archived application binary using file command.

$ file Payload/Foo.app/Foo
Payload/Foo.app/Foo: Mach-O universal binary with 2 architectures
Payload/Foo.app/Foo (for architecture armv6):   Mach-O executable arm
Payload/Foo.app/Foo (for architecture armv7):   Mach-O executable arm
天涯沦落人 2024-11-13 04:45:05

我在使用 XCode 3 构建的旧应用程序上遇到了相同的错误,但一年后必须为 XCode 4 重建。

所有这些设置都是相同的:

"Architectures" should be "Standard (armv6 armv7)"
"Build Active Architecture Only" should be "NO".
"Valid Architectures" should be "armv6 armv7".

我使用 file 命令检查了存档的应用程序二进制文件。

$ file MyApp

没有返回两个条目

Payload/Foo.app/Foo: Mach-O universal binary with 2 architectures
Payload/Foo.app/Foo (for architecture armv6):   Mach-O executable arm
Payload/Foo.app/Foo (for architecture armv7):   Mach-O executable arm

,但有一个

$ file MyApp
MyApp: Mach-O executable arm

我在上面的 stackoverflow 中看到了“通用二进制”,因此意识到该应用程序从未为 iPad 构建。

我不得不将 iPhone 更改为通用。

Project > My App Target > Summary Tab > Devices drop down
Change from iPhone to Universal.

它将MainWindow复制到MainWindow-iPad。

我还没有打算制作 iPad 版本,所以拒绝了。

我再次存档并验证应用程序工作。

I got the same error on an old app built with XCode 3 but had to rebuild a year later for XCode 4.

ALL THESE SETTINGS WERE THE SAME:

"Architectures" should be "Standard (armv6 armv7)"
"Build Active Architecture Only" should be "NO".
"Valid Architectures" should be "armv6 armv7".

I checked the archived application binary using file command.

$ file MyApp

DIDNT RETURN TWO ENTRIES

Payload/Foo.app/Foo: Mach-O universal binary with 2 architectures
Payload/Foo.app/Foo (for architecture armv6):   Mach-O executable arm
Payload/Foo.app/Foo (for architecture armv7):   Mach-O executable arm

BUT ONE

$ file MyApp
MyApp: Mach-O executable arm

I saw 'universal binary' in above stackoverflow so realised the app had never been built for iPad.

I had to change iPhone to Universal.

Project > My App Target > Summary Tab > Devices drop down
Change from iPhone to Universal.

It will as to copy MainWindow to MainWindow-iPad.

I didnt plan to make iPad version yet so said no.

I did Archive again and Validate App worked.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文