简体   繁体   中英

Which version of the iOS SDK should I use?

请告诉我应该使用哪个版本的iOS SDK,以便我的应用程序可以在iPhone 3.0或更高版本上使用。

There are two different concepts you should be aware of:

The Base SDK

This is what you use to build your application. The most recent release is 4.2 so you should use that to build your applications against.

The iOS Deployment Target

This is the target version of iOS you are building for. In your case, you set that (in Project or Target settings of Xcode) to "iOS 3.0".

The rest is up to you. You are, of course, building for many versions of the SDK, so if you use something that was introduced in any SDK after 3.0, you need to test for that functionality explicitly.

This is not a question of "which to use" but a question of "which one you have to use to get your apps accepted by apple", and the answer for that is: Use the newest one marked stable that is available to you. Apple accepts only Apps submitted for the AppStore build with one of the latest 2 (or so) Versions.

For setup see the answer of Typeoneerror and be aware, that you can build with a newer Base SDK (in fact you have to) but the compiler will not warn you if you use functions that are not available in your "Deployment Target", so you will have to test your app with a device that has the old iOS version installed to be sure it doesn't crash!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM