5

I have already downloaded the new Xcode 5.0, but I wanted to build an app for iOS 6...

How can I do that from Xcode 5.0? Or do I need to have a version of Xcode 4 installed so I can do that?

Xcode does let me change the deployment target as the screen below: deployment targer

But it doesn't let me use a older Base SDK

enter image description here

3
8

Just set the Deployment Target to iOS6, in the configuration of the project:

enter image description here

10
  • 2
    He might also need to download the older sdk's or has apple fixed that you don't need to do that anymore – Armand Sep 20 '13 at 13:17
  • 2
    You can deploy for an earlier target than your SDK as long as you don't use any APIs that were introduced in the newer version. – Fogmeister Sep 20 '13 at 13:20
  • Where is that screen you put? I think i still need to download the older SDK to be able to change de base SDK right? – Alexandre Lins Sep 20 '13 at 13:52
  • If you want to compile using the iOS6 SDK you'll need the previous XCode – Antonio MG Sep 20 '13 at 13:59
  • 3
    @AlexandreLins just use the iOS 7 SDK and set your deployment target to iOS 6. That's all you need to do. – Dave DeLong Sep 20 '13 at 14:55
7

First of all you need to download the older Xcode you want to build for. After that, you copy the .sdk in the folder of the older Xcode /Applications/Xcode/Contents/Developer/Platforms/iPhoneOS.platform/platform/SDK

and paste it in the same folder, but now, from the Xcode 5.0

Now, you should be able to choose between all the .sdk installed on that folder under the "Build settings" tab of your project, under Base SDK.

4
  • -1 this results in an unsupported configuration of Xcode and is not guaranteed to work. – Dave DeLong Sep 20 '13 at 14:54
  • +1 this worked very well for me. – Jamon Holmgren Nov 2 '13 at 21:17
  • Yes, This worked for me as well... Ton of thanks... – Prasad De Zoysa Dec 15 '13 at 22:38
  • 1
    This is the wrong answer, and will not work after February 1. – Aaron Brager Dec 25 '13 at 1:35

Not the answer you're looking for? Browse other questions tagged or ask your own question.