Manbolo Blog

Manbolo Team Blog, creators of MeonArchives

How to Indicate What Devices Are Supported by Your iOS App

In Hypercritical n°64 “You Will Die Instantly!”, John Siracusa discusses about an iOS issue regarding app devices compatibility vs iTunes metadatas. The issue (raised in the previous show) was about a customer complaining that the game he had downloaded didn’t run on its iPhone 3G, whereas iTunes indicated that every devices (including the 3G) were supported. As the customer complained about it, the developer argued that the description of the app clearly stated that the iPhone 3G was not supported by this game, whereas the iTunes metadatas told the contrary. So, there seemed to be a difference between what iTunes said and what the app description said, and presumably the system should have avoided it.

One of John’s listener feedback was that this discrepancy (between iTunes metadatas and the app description) is not due to the developer, but is instead a lack of possibility, on the development side, to list devices on which an app is running.

Actually, it’s not exactly true, and I would like to explain the possibility you have, as a developer, to precisely target which devices your application is supporting.

1. Hardware capabilities

One of the most important resources of your app in Xcode is the Info.plist file. This file contains important key for you app, like the app bundle id, CFBundleIdentifier, which is the unique identifier of your application, the bundle display name, which is the name of your app on SpringBoard, the background mode you use etc…

Among these keys, the UIRequiredDeviceCapabilities key, while not mandatory, is crucial. This key allows you to list ’hardware-like’ capabilities that your app needs. Examples of what this key can contain are: microphone, gyroscope, video-camera, front-facing-camera etc.. I said ’hardware-like’ because some of these values are more software oriented (like gamekit aka Game Center, or even opengles-1) but the majority is hardware oriented.

UIRequiredDeviceCapabilities exampleExample of capablity requiring armv7 support

Playing with these capabilities, you can target which device your app is running on. In the iTunesConnect Developer Guide, there is even a matrix showing how you can combine the different values and the resulted supported devices.

Updated on 2012/10/30: Updated matrix with the iPad mini and the iPad 4

iTunes devices matrix

By the way, do you know that there is an iPhone 3GS ’China flavor’ without wifi ?

A side note: when you will submit your app to the App Store, Apple will add an iTunesMetadata.plist file, containing various info about your app, and including the UIRequiredDeviceCapabilities, another proof of the importance of it. For instance, you could have:

<key>UIRequiredDeviceCapabilities</key>
<dict>
    <key>armv7</key>
    <true/>
    <key>opengles-2</key>
    <true/>
</dict>

2. Software capabilities

You can also adjust the minimum iOS required by your app. Once again, as the app developer, this is your responsibility, and if your set a minimum version to iOS 3.0, you must insure that your app is effectively running on this OS ( and test if APIs are here etc…, weak link frameworks etc.. more information [here][] )

To set the minimum iOS version, simply select your target, go to ’Build Settings’, and set the iOS Deployment Target to what you want.

iOS Deployment target setting

That’s all. When you will submit your app to the App Store, Apple will add to your Info.plist file the following key:

<key>MinimumOSVersion</key>
<string>4.1</string>

to indicate what is the minimum iOS version for your app.

3. Summary and wrap up with Hypercritical

So, to make the link with the Hypercritical issue, the developer of the incriminated game should have added in the Info.plist file an armv7 capability requiring armv7 support. Simply doing this, his game would have been only available on iPhone 3GS and superior, and the iTunes metadata would have reflected it. In fact, the armv7 capability is even in the default plist file when you’re creating a new projet under Xcode 4.2 and superior (Yes, Apple is pushing you to armv7 devices!).

Theses capabilities are not exactly a list of devices but by playing with it, developers can indicate precisely on which devices their apps are running on. I like the Apple approach, and I find that Apple has done a pretty good job regarding how to specify device compability. UIRequiredDeviceCapabilities can be used to target hardware capabilities, and these capabilities will infer which devices you’re supporting. So you don’t have to know all iOS devices and their capabilities, but you need to understand what features (hardware or software) you’re requiring. Doing it intelligently, and the iTunes metadatas will match exactly the devices you’re supporting.

For instance, if you look at the Infinity Blade II iTunes page, you will see this:

Infinity Blade

Looking inside the Infinity Blade app bundle, you can check that the UIRequiredDeviceCapabilities are

<key>UIRequiredDeviceCapabilities</key>
<dict>
    <key>armv7</key>
    <true/>
    <key>opengles-2</key>
    <true/>
</dict>

and the iOS version

<key>MinimumOSVersion</key>
<string>4.0</string>

that matches exactly the iTunes description!

By the way, if you don’t know Hypercritical and the other 5by5 podcasts, stop reading me and subscribe to these gems!

From jc.

All Posts