简体   繁体   English

Xcode 构建目标差异——arm64 和 armv7、arm64

[英]Xcode build target difference - arm64 and armv7, arm64

I had created 2 new projects on Xcode this week for 2 different apps.本周我在 Xcode 上为 2 个不同的应用程序创建了 2 个新项目。 For some reason one of the project always fails compiling for the device target.由于某种原因,项目之一总是无法为设备目标编译。 I then realized that the device target is different for both the project.然后我意识到两个项目的设备目标是不同的。 For the working project "Any iOS Project (arm64)" The project which fails to build has "Any iOS Project (armv7, arm64)"对于工作项目“Any iOS Project (arm64)” 构建失败的项目有“Any iOS Project (armv7, arm64)”

What causes the device target to change this way and what is the difference?是什么导致设备目标以这种方式改变,有什么区别?

armv7 is 32bit architecture that was supported by earlier iOS versions up till 10.3.4 . armv710.3.4之前的早期 iOS 版本支持的 32 位架构。 arm64 is 64bit architecture which is supported by newer devices . arm64新设备支持的 64 位架构。

If your project has minimum iOS version which is below iOS 11.0, Xcode will automatically pick both armv7 and arm64 .如果您的项目具有低于 iOS 11.0 的最低 iOS 版本,Xcode 将自动选择armv7arm64

In case if Xcode does not pick the required architecture automatically, it can be added in build settings as shown below:如果 Xcode 没有自动选择所需的架构,可以将其添加到构建设置中,如下所示:

在 Xcode 构建设置中编辑 iOS 目标设备架构

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

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