Xcode 卡在“正在安装组件...”
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/50788573/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Xcode stuck on "Installing components..."
提问by Vic Segers
Xcode keeps getting stuck on "Installing components...", it stops at around 40%. I've let it sit for a whole night, reinstalling it from the App Store and searching for solutions on the internet, but all with no succes.
Xcode 一直卡在“正在安装组件...”上,停在 40% 左右。我已经让它坐了一夜,从 App Store 重新安装它并在互联网上搜索解决方案,但都没有成功。
When I Force Quit and restart Xcode, it does the same thing except that the progress bar immediately jumps to 100% but after that it won't budge. I can only get back to the 40% when i restart my computer.
当我强制退出并重新启动 Xcode 时,它会做同样的事情,只是进度条立即跳到 100% 但之后它不会让步。当我重新启动计算机时,我只能回到 40%。
I have Xcode version 9.4 and i'm running macOS High Sierra (10.13.5).
我有 Xcode 9.4 版,我正在运行 macOS High Sierra (10.13.5)。
Question asked when starting the app
Edit: I've fixed it by deleting some .kext files that were messing things up. Found the following on an Apple Community post:
编辑:我已经通过删除一些搞砸了的 .kext 文件来修复它。在 Apple 社区帖子中发现以下内容:
- Open Terminal in /Applications/Utilities
- Enter "system_profiler SPExtensionsDataType > ~/Desktop/kextList.txt" without the quotes and hit return(this will take a while to run).
- There should now be a kextList.txt file on your desktop, open it and press both the "Apple(Command)" and "F" keys to bring up the find.
- In the find field insert "Obtained from: Not Signed" Copy the destination to the .kext file to a list for use later.
- Browse your drive to /System/Library/Extensions and remove any of the unsigned kext files.
- Reboot and you should be all set.
- 在 /Applications/Utilities 中打开终端
- 输入不带引号的“system_profiler SPExtensionsDataType > ~/Desktop/kextList.txt”并点击返回(这将需要一段时间才能运行)。
- 现在你的桌面上应该有一个 kextList.txt 文件,打开它并同时按下“Apple(Command)”和“F”键来调出查找。
- 在查找字段中插入“Obtained from: Not Signed” 将目标复制到 .kext 文件到一个列表以备后用。
- 浏览您的驱动器到 /System/Library/Extensions 并删除任何未签名的 kext 文件。
- 重新启动,你应该一切都准备好了。
回答by JaimeRave
Starting MacOS in Safe Mode and the starting Xcode should fix the issue. I tried in MacOS High Sierra 10.13.6 and it worked perfectly.
在安全模式下启动 MacOS 和启动 Xcode 应该可以解决这个问题。我在 MacOS High Sierra 10.13.6 中尝试过,效果很好。