Cannot start Xcode 6.1.1 after duplicating the app folder

感情迁移 提交于 2020-01-04 10:12:28

问题


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!


回答1:


Open Terminal and just type this code

sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer

enjoy multiple version of xcode :)




回答2:


type following command in terminal:




回答3:


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.




回答4:


I fixed it with chown:

sudo chown -R root /Applications/Xcode6.1.1.app/



来源:https://stackoverflow.com/questions/27374245/cannot-start-xcode-6-1-1-after-duplicating-the-app-folder

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!