In XCode, when I open project settings, I only see the following two choices for the setting "Architectures": 'Standard (armv6 armv7)' and 'Optimized (armv7)'.
How can I get the choice of 'Optimized (armv6 armv7)' to appear?
I'm using XCode 3.2.3.
It's misleading. Choose armv6&7 if you're developing for iPhone 3G or earlier. 3GS and later, including iPad, use arm7, so if those are the devices you're targeting, you can get code more optimized for those newer devices by choosing armv7, no backward compatibility. (For targeting all devices, old and new, choose armv6&7.)
With the iOS SDK for 4.0.x, Apple renamed the old "Optimized (armv6 armv7)" to "Standard (armv6 armv7)", so you've already got it to appear, just under a different name.
Related
After doing some minor modifications to my app and loading it up into the latest xcode version, I've noticed the following settings.
Should I remove armv6?
The option in the drop down says armv7, armv7s.
What should I set ?
If you don't really want to support iPhone 3G and lower (not 3GS) then you can remove armv6. If you do, then you'll need to support only iOS 4.* and lower, and i don't think you really need it.
So, you can feel free to remove armv6 from the list.
As shown is image, If you select both architectures, the product built will execute on all iOS devices including iPhone 3G. If you have to run your code on iPhone 3GS or above. You can set armv7 in setting.
Set ARMv6 if you want to support iPhone(original) and iPhone 3G.
Set ARMv7 if you want to support iPhone 3GS, iPhone 4 and iPhone 4S
Set ARMv7s if you want to support iPhone 5
Here is a little explanation about the basics on iPhone processors technology.
Just for the record, iPhone(original), 3G and 3GS were discontinued.
I am using Xcode 4.2 to develop my apps. My current ongoing project is set to run on ios4.2, but i only have a iPhone 3G (not 'S') to test my app. The problem is that when i try to run my app in my device, xcode says it was compiled and running on device but the app doenst even install in my iPhone.
I have read on other posts that i have to change the armvX configuration, so how do I do that in order for my app to run in a iPhone 3G?
Thanks.
This is a hardware issue rather than an iOS version issue.
In the Architectures section of your build configuration it probably just says armv7.
You need it so have two entries, armv6 and armv7. Select Other from the architectures menu then delete the default then add two new entries, one that just says armv6, on that just says armv7.
This creates a fat binary (essentially two binaries) which will contain the v6 code the 3G needs.
Go to the project view. (Short cut key: Command-1)
Select the project to see its summary.
Under iOS Application Target, there should be a Deployment Target.
Select the version 3.1.3 or whatever the desired minimum version.
I dont have my Mac in front of me but i believe in the Target settings for the project
(click on the project in Xcode and under targets select your project name)
In the settings there you will see it more then liekly saying armv7 change to a lower number armv and i believe it will work.
though i cant be sure
I want to limit my universal-build app to iPhone4 / iPad, and I've set UIRequiredDeviceCapabilities to include "armv7", accordingly. In the build settings I've set:
"Architectures" = "Optimized (armv7)"
"Valid Architectures" = "armv7"
But the Release and Distribution builds of my universal app are generating this warning:
warning: iPhone apps should include an armv6 architecture (current ARCHS = "armv7")
Is this even a real problem? Can I safely ignore the warning? Why doesn't my debug build exhibit the same warning - the build config has the same settings?
I'm building with XCode 3.2.5, 4.2 SDK.
Similar to this question, but not quite:
"Warning: iPhone apps should include an armv6 architecture" even with build config set
I was having the same issue. I set the project settings accordingly but was still getting the error when building the Release version. I had to edit the Target settings and found that 'Build Active Architecture Only' was checked for the Release configuration. Unchecking it resolved the warning. I hope this helps someone.
Build Active Architecture only is really best used just for debug and simulator builds.
The iOS deployment target version is what determines the required architectures. iOS 4.2 and earlier included support for armv6 processors; therefore Xcode wants you to build for that architecture for builds that might be distributed.
If you really don't want armv6 code, and understand that the app store will reject your app if it targets iOS 4.2 or earlier and does not have armv6, then I'd suggest just changing the "Architectures" setting in the target to armv7 only.
You can stay with arm7 only if you want, but if you want to limit to iPhone 4 / iPad it's because you have a good reason ? To limit to devices you need to use UIRequiredDeviceCapabilities in your Info.plist, otherwise people with previous iPhone will find your app and it will not work.
PS: It's not easy to find a device capability for both iPad and iPhone, you can for example said that you want devices with a front facing camera but this will limit to iPhone 4 and iPad 2 (and not iPad 1)
How to make universal binary of one app, which can correctly run on 3G and support multitasking on iPhone 4?
Thanks!
The term "universal binary" here is a misnomer, since that is only for iPad/iPhone combined apps. If all you want to do is compile a build that works on both iPhone 4 and iPhone 3G, you need to download and install SDK 4, set 4.0 as the "Base SDK", and then set your "Deployment Target" to whatever minimum version of iOS you want to allow to run your app. Some people use a setting of 3.1.3, some people keep that setting at 4.0.
This is documented in the iPad Programming Guide under Starting Your Project.
What is this selection for? I have the Architectures set to Optimized (armv6 armv7) so a fat binary should be getting build with both, right?
So why does this need to set this in the menu? What does it do?
Well mostly you do not need it, but even if you are building fat binaries you may not always be building both versions.
If you check the Build settings for the target there is an option in the Architectures section named "Build Active Architecture Only". I think by default this is selected when you are building for debug. The idea being that if you have armv6 device plugged in Xcode is smart enough to detect that and only build that version saving you some time.
Of course when you are building for distribution the option will not be checked to ensure you build for both architectures (not just the active one).
So I guess the short answer is that you do need to mess with it as Xcode will set it for you based on which device you have plugged in.
armv6 is compatible with all iPhone/iPod touch/iPad devices.
armv7 is for newer devices which support OpenGL ES 2.0, including iPhone 3GS, recent iPod touch and iPad devices.
Xcode detects which devices you have connected and will set the active architecture accordingly. So if you plug a 2nd generation iPod Touch into your computer Xcode should set the active architecture to armv6.
When you create a Distribution configuration for publishing to the App Store you should make sure this option is not set so that you build the fat universal binary