Wednesday, March 9, 2011

Xcode 4 & Xcode 3 Work Fine Together

Edit: Very timely! didn't know Xcode 4 would be released today!

DO NOT INSTALL XCODE 4 in the default location!!!
If you do/did you will/have replaced your Xcode 3 installation.

Edit: sorry for shouting...

Wait, what? you already installed it and now you lost Xcode 3... ARG the humanity!!!! Okay all is not lost, take a quick look at this older post about selecting a different folder for Xcode to install into and run the Xcode installers a second time. I would remove the old folders first.

I am using the following folders:
Xcode 3 (including the new iOS 4.3 GM SDK) installed into -> /Xcode3 (was /Developer) (1)
Xcode 4 (includes the GM 2) installed into -> /Developer (was /Xcode4) (1)

(1) Update: I just switched today with the final releases of both Xcode 3.2.6 and Xcode 4. I want Xcode 4 to be the default so I'm installing it into /Developer. You can install whichever way you want, heck even in /Xcode4 and /Xcode3, that may be the easiest way to keep them separate. Just know that "/Developer" will always be set as the default folder, regardless of the Xcode version.

Install the Xcode's in whatever order you want. To set the "default" version (the one that opens when you double-click a project file), choose get info on a project file from Finder and then browse to and select the Xcode app you want to use and select the Always use this application" checkbox.

The /Xcode4 folder was leftover from the beta installs but there is no reason it won't run just fine in that folder. This allows you to, very quickly create say a nice shiny new cocos2d 0.99.5 or heck even a beta 1.0.0 app with Xcode 3 using the cocos2d templates (that still work in Xcode 3) and then open the project in Xcode 4.

Sweeeeet.... :-]


  1. Great blog article!

    cocos2d 1.0.0beta include Xcode 4 template.

    I've posted a url on twitter.
    This is the url.
    ( Sorry, this is japanese,but the url will be informative. )

  2. Awesome, thanks. Here is the actual url: to github.

  3. Yes, this article.

    cocos2d for Xcode 4 template was updated.
    Now support chipmunk and box2d. Great work!!

  4. Could you please answer a stupid question?
    I'm new to macs so this is probably me missing something really simple.

    I've installed Xcode 4, then realising I have some tutorial files to work through based in Xcode 3 I downloaded the dmg and installed it in a different directory /Xcode3.

    So far so good.

    But the xcode 3 isn't listed in applications anywhere. The xcode4 is and seems unchanged, but I can't seem to figure out how to get 3 running.

    Any ideas?


  5. Never stupid questions... :-) Open a Finder window and browse to your hard drive. Now look for Xcode3 OR use the "Go" menu and select "Go to folder" and enter Xcode3.

    Now look in the "Applications" folder and there is the Xcode app. Right-click it and choose "Make Alias", Rename it Xcode3 and drag it to your desktop.

    PS Sorry for the delay