执行命令行出现xcrun: error: active developer path 的解决方法

在探索swift源码编译时出现以下错误
xcrun: error: active developer path ("/Applications/Xcode.app/Contents/Developer") does not exist
Use sudo xcode-select --switch path/to/Xcode.app to specify the Xcode that you wish to use for command line developer tools, or use xcode-select --install to install the standalone command line developer tools.
See man xcode-select for more details.
ERROR: command terminated with a non-zero exit status 1, aborting

解决方法:在终端执行sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer命令,然后终端输入电脑密码就OK了👻👻👻

©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容