views:

1335

answers:

3

Just installed the latest iphone sdk 3.0. after i seleced the active sdk as simulator3.0 at the drop down overview, the "target" field no longer shows me the 2.2.1 SDK, and defaults to 3.0, resulting i cannot test on my 2.2.1 device.

What actions should I follow to fix this? even in target property my base sdk still appear device 2.2.1

Thanks in advance.

+1  A: 

You cannot run an iPhone application compiled for 3.0 on a device running anything other than 3.0 as it is not backwards-compatible with 2.2.1. You'll need to upgrade your device in order to run 3.0 apps on it.

More specific to the most recent release of the SDK, there is an entry in the release notes that states that this version does not let you compile against any SDK except the 3.0 SDK. I believe the last version that allowed you to do that was 3.0b2. You'll need to roll back to that one or earlier if you want to compile using the 2.2.1 SDK.

Marc W
ya i am using 3.0b2 and now jus want to compile and run my app using 2.2.1 simulator or device but it just disapear from my drop down overview,i am not trying to run a 3.0 appliccation to 2.2.1 device but just want to set the target to 2.2.1, posible to can make it?
Like I said, you cannot do this with versions of the SDK after 3.0 beta 2.
Marc W
You can actually. Beta 3,4 and 5 all have the options to build for 2.x
nduplessis
A: 

Right click on your project and select "Get Info". Then from the "Base SDK for All Configuration", select "iPhone Device 2.2.1" and the options will be available again.

  • Jetzdax


+1  A: 

The setting you may want is the "iPhone OS Deployment Target" at the bottom of the Deployment section of the Info window for your project.

You can leave the "Base SDK" setting set to 3.0, and set the "Deployment Target" to an earlier version like 2.2.1.

search for "Target an earlier iPhone OS release" in

http://devworld.apple.com/iphone/library/documentation/Xcode/Conceptual/iphone_development/120-Running_Applications/running_applications.html

Then it's up to you to make sure your application doesn't try to use OS 3.0 features on an OS 2.2 device. (use weak references to any OS 3.0-only frameworks, check OS version before doing things that only work on some versions, etc.)

David Maymudes