On our build system, we need to preserve multiple Xcode versions in order to also build older projects. We duplicate the Xcode app folder for every major Xcode release (from within Finder).
However, after duplicating the Xcode 6.1.1 folder, I couldn't start the app. After double-clicking on the duplicated folder (Xcode-6.1.1.app), it briefly showed the "Welcome" screen, then immediately closed it and showed an alert saying:
/Applications/Xcode-6.1.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/lib/dyld_sim is not owned by root.
The original Xcode.app can be opened normally. I could reproduce this problem on both Mavericks and Yosemite.
Has anyone seen this? Any ideas how to make the duplicated Xcode working? Thanks!
Open Terminal and just type this code
sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer
enjoy multiple version of xcode :)
The xcode-select commands did not work for me. So I deleted that copy I made with the Finder, and used the free Duplicate (which copies permissions and other metadata correctly when it makes the duplicate) to copy it from a backup. After that it launches flawlessly.
I fixed it with chown:
sudo chown -R root /Applications/Xcode6.1.1.app/
type following command in terminal: