Did you run sudo xcode-select -switch /Applications/Xcode.app
? This message: error: can't exec '/Developer/usr/bin/xcodebuild'
is telling you that your system is looking for xcodebuild in `/Developer/usr/bin/' but as of Xcode 4.3 (the one that's installed from the App Store) it's located in the Xcode.app bundle which is in /Applications.
Edit
In a comment to your question you say you've run sudo xcode-select -switch /Applications/Xcode.app
. Now run xcode-select -print-path
and make sure it says "/Applications/Xcode.app".
Also, you may need to download the command line tools separately. (I don't know from first-hand experience because I'm stuck on Snow Leopard for the moment so I haven't installed Xcode 4.3.)
I'm having the same issue. At first I thought it was me doing something wrong, then it hit me again last night.
I am using a corporate macbook pro I7 (which seems to run slower than my personal 2009 macbook core-2 duo, but i regress...) I was vpn'd into work with Cisco Any connect.
I got to a stopping point, went to commit the files, added my comment and before I hit the commit button, I lost the vpn. No problem I thought as the commit is only to the local repository, but when I hit commit, I got an error saying this is not a git repository. I flipped back to my project and half the files were gone. Luckily the 4 files I had been working in were still there, but I had another project open at the same time, and I lost everything there but the project file. Luckily I had pushed to our git server twice that day, but did lose a little work.
The computer is running McAffee AV.
I'm wondering if it's something to do with the mobile account on the mac.
None of the source code files are in the trash, they just vanish.
I'm storing my projects in ~/Projects/Mobile/Project1... but I have also lost source code in ~/Documents/Projects before.
Zip files in the ~/Projects/Mobile folder are unaffected.
All source code files in MOST all project folders disappear, even projects that were not open in XCode.
Best Answer
Why not just install the latest version of Xcode?
Xcode 3.2 was originally released all the way back in 2009 and since it's a very technical product by nature, it's not really a surprise that it crashes on a OS that was released 5 years later.
If you really, really need v. 3.2, I'd suggest looking into virtualization (Parallels Desktop or VMware Fusion are popular choices). You could then install Leopard (10.5) and Xcode 3.2 and compile via the virtual machine.