美文网首页iOS程序猿
error: Cannot find cdtool at 安装X

error: Cannot find cdtool at 安装X

作者: BestWilliam | 来源:发表于2017-09-26 10:13 被阅读117次

安装Xcode 9后,Xcode 8在编译项目时会出现错误:

error: Cannot find cdtool at '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Xcode/Agents/cdtool': Cannot find a simulator runtime for platform <DVTPlatform:0x7fa25a60fc20:'com.apple.platform.iphonesimulator'<DVTFilePath:0x7fa25a60fab0:'/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform'>>

移动iOS 10.3.simruntime可以解决这个问题,

sudo mkdir/Library/Developer/CoreSimulator/Profiles/Runtimes/Backup

sudo mv/Library/Developer/CoreSimulator/Profiles/Runtimes/{,Backup/}iOS\10.3.simruntime

sudo killall-9com.apple.CoreSimulator.CoreSimulatorService

然后重新启动Xcode,Simulator等;那些删除了CoreSimulator.framework,因此无法再运行Xcode.app,可以重新安装CoreSimulator.framework

installer-pkg/Applications/Xcode-beta.app/Contents/Resources/Packages/XcodeSystemResources.pkg-target/

相关文章

网友评论

    本文标题:error: Cannot find cdtool at 安装X

    本文链接:https://www.haomeiwen.com/subject/fvrvjxtx.html