I have just upgraded my XCode to 4.5 and installed the SDK 6.0. I have found that SDK 5.0 disappeared but I can still download back the Iphone 5.0 simulator.
I just wonder weather I can use SDK 6.0 to develop application for iOS 5.1. I have made the configuration shown in the following pictures.
Yes any iOS SDK allows you to develop for previous versions of the OS as well. For example you can develop for iOS5 even with the iOS6 SDK.
You simply have to set the "Deployment Target" setting to 5.1.
You can then:
For more information and detailed instruction for the configuration and example cases, I strongly suggest to read the SDK Compatibility Guide in Apple documentation.
For example, if you want to provide a button to share something on social networks, you could want to use the Social.framework, but this one is only available on iOS6. Thus you can propose this feature for iOS6 users and alert iOS5 users that they need to update their iPhone to iOS6 to use this specific feature:
// Always test the availability of a class/method/... to use
// instead of comparing the system version or whatever other method, see doc
if ([SLComposeViewController class])
{
// Only true if the class exists, so the framework is available we can use the class
SLComposeViewController* composer = [composeViewControllerForServiceType:SLServiceTypeFacebook];
// ... then present the composer, etc and handle everything to manage this
} else {
UIAlertView* alert = [[UIAlertView alloc] initWithTitle:@"Sharing unavailable"
message:@"You need to upgrade to iOS6 to be able to use this feature!"
delegate:nil
cancelButtonTitle:nil
otherButtonTitles:@"OK, will do!"];
[alert show];
[alert release];
}
Then simply weak-link the Social.framework (change "Required" to "Optional" when you add the framework to the linker build phases) as explained in details in the documentation.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With