Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does warning "Mapping architecture arm64 to x86_64" mean?

After migrating my framework to Xcode 10 beta (10L176w) I started to get warnings like:

Mapping architecture arm64 to x86_64. Ensure that this target's Architectures and Valid Architectures build settings are configured correctly for the iOS Simulator platform.

... and:

Mapping architecture armv7 to i386. Ensure that this target's Architectures and Valid Architectures build settings are configured correctly for the iOS Simulator platform.

Despite these warnings the build and the unit tests all pass Ok. I'm using Swift 4.2.

Still, what are these warnings about?

like image 204
0x416e746f6e Avatar asked Jun 08 '18 21:06

0x416e746f6e


People also ask

What is the difference between ARM64 and x86_64?

ARM and x86 are for 32-bit processors, while arm64 and x86_64 are for 64-bit processors. We'll explain in more detail below.

Is ARM64 an architecture?

An ARM64 processor is an evolution of ARM architecture that includes servers, desktop PCs, and the internet of things (IoT). ARM64 processors help address the increased processing demands from new technologies such as high-resolution displays, realistic 3D gaming, and voice recognition.


8 Answers

Go to Build Settings and do as shown below

enter image description here

like image 63
Hassan Taleb Avatar answered Oct 05 '22 18:10

Hassan Taleb


I was able to silence these warnings by changing my Valid Architectures setting to $(ARCHS_STANDARD) which matches my Architectures setting as well.

Oddly, this displayed as armv7 arm64 (in comparison to the default setting of armv7 armv7s arm64), but setting it to that value manually still caused the warnings. Not sure what the significance of that is, but I haven't noticed any problems in my testing yet.

like image 24
John Montgomery Avatar answered Oct 05 '22 19:10

John Montgomery


You likely have the VALID_ARCHS ("Valid Architectures") build setting overridden, either for the target or for its project. This is a build setting that should get its value automatically based on which run destination you're building for. When you figure out where this override is coming from (the build setting will display in bold when overridden), select it and hit the delete key to restore it to the default value.

like image 36
Rick Ballard Avatar answered Oct 05 '22 20:10

Rick Ballard


For the TARGET which report warnings, Change the "Valid Architecture" setting to:

$(VALID_ARCHS)
x86_64

enter image description here

like image 43
Quanhua Guan Avatar answered Oct 05 '22 18:10

Quanhua Guan


Similar to other answers, I was able to remove the warning by changing $(VALID_ARCHS) (Valid Architectures) to $(ARCHS_STANDARD). From there, I cleared all Derived Data and restarted Xcode 10.0. This made the warning go away completely. Deleting everything from Valid Architectures just made a different warning appear ("No valid architectures found").

like image 24
jldailey Avatar answered Oct 05 '22 18:10

jldailey


I am also facing the same problem. For resolution, I have just changed the build system from Standard to Legacy and that resolved the issue.

like image 28
Harsh Wardhan Gupta Avatar answered Oct 05 '22 19:10

Harsh Wardhan Gupta


The solution is simpler: in Valid Architectures just replace arm64 with x86_64.

Had similar issue and the following three warnings in my project: Had similar issue and the following warning in my project

My Valid Archtectures originally were My **Valid Archtectures** originally were

Replacing:

  • armv7 with i386,
  • armv7s with i386,
  • and, arm64 with x86_64

(as mentioned in the Warnings) was my solution. The result in the Valid Architecture setting was:

Replacing armv7 with i386, armv7s with i386, and, arm64 with x86_64 as mentioned in the Warnings was my solution

After the replacements my three warnings above disappeared.

More profound info about the Architectures can be found here: https://docs.elementscompiler.com/Platforms/Cocoa/CpuArchitectures/

I think the formulation of this warning in Xcode is a bit confusion.

like image 34
CGN Avatar answered Oct 05 '22 20:10

CGN


If you are facing problem in Flutter:

  1. Delete the Podfile, Podfile.lock, Pods folder, Runner.xcworkspace, Flutter.framework.

  2. Run flutter clean.

  3. Run flutter build ios.
like image 25
Deepak Ror Avatar answered Oct 05 '22 20:10

Deepak Ror