After updating to Xcode 5.1, I can no longer build my project for the 64-bit simulator, receiving this error:
No architectures to compile for (ONLY_ACTIVE_ARCH=YES, active arch=x86_64, VALID_ARCHS=i386).
These are my target build settings:
I tried changing "Build Active Architecture" to No, as well as adding "i386" to the "Valid Architectures", unfortunately neither worked. Thanks for any suggestions!
I arrived at this question due to a problem with command line build for simulator in Xcode 7.2. In case anyone else gets here with the same issue, I will share the solution I found:
Apparently there is a bug in Xcode 7.2 that causes
xcodebuild
to fail when trying to build for simulator. The solution is to specify the option "-destination", e.g:Update
The above example command will build a binary including the graphics for iPhone 6 only. If the binary is run on other simulators, the iPhone 6 graphics is scaled to the platform. A better workaround which contains all graphics for all platforms is to specify the parameter
PLATFORM_NAME=iphonesimulator
, for example:Try removing all previous architectures (i.e. remove the ARCHS_STANDARD setting) at the same time as you add i386 to the Architectures. This should change the active architecture to i386. I encountered a similar issue when I tried to build for armv7 by default, but it kept trying to build for arm64. I changed ARCHS_STANDARD to ARCHS_STANDARD_32_BIT, and this changed the active architecture chosen.
In acrhiecture - sometimes to support 6.0 and 7.0 , we exlude arm64
In architectures - > acrchitecture - select standard architecture arm64 armv7 armv7s. Just below in Valid acrchitecture make user arm64 armv7 armv7s is included. This worked for me.
My problem was that the Pods project was targeting OS X, despite my Podfile having
platform :ios
. I'm using cocoapods 0.35.0.rc2.To fix it, select the Pods project in the project navigator, and check that the Pods PROJECT node (mind you, not the Pods target) is targeting iOS. That is, the architectures build settings should be:
$(ARCHS_STANDARD)
iOS 8.1
iOS
$(ARCHS_STANDARD)
I also wanted to build all architectures, so I added the following to the Podfile:
I had to add the following
i386
andx86_64
toValid Architectures
. I'm running Xcode 7.2 and targeting iOS 8+. I already hadarmv7
,armv7s
andarm64
in there and that was working in Xcode 6.4.I faced the same problem when running my app on iPad using xcode 5.1. It got resolved by removing armv7s from 'valid architectures' and setting the 'build active architectures only' value to No. Both these fields can be found in your app->targets->build settings->architectures.