所以我一直在使用自制软件在我的 Mac 上安装各种包/库/程序。我一直遇到一个问题,自制软件告诉我我的酒窖中有未链接的小桶。
例如,在运行时,brew install phantomjs
我收到以下消息:
Warning: Could not link phantomjs. Unlinking...
Error: The `brew link` step did not complete successfully
The formula built, but is not symlinked into /usr/local
You can try again using `brew link phantomjs'
Possible conflicting files are:
/usr/local/bin/phantomjs -> /usr/local/lib/node_modules/phantomjs/bin/phantomjs
我尝试brew link phantomjs
按照建议运行,并遇到了类似的问题:
Error: Could not symlink file: /usr/local/Cellar/phantomjs/1.9.2/bin/phantomjs
Target /usr/local/bin/phantomjs already exists. You may need to delete it.
To force the link and overwrite all other conflicting files, do:
brew link --overwrite formula_name
该命令brew link --overwrite --dry-run phantomjs
给出以下消息:
Would remove:
/usr/local/bin/phantomjs -> /usr/local/lib/node_modules/phantomjs/bin/phantomjs
我可能会继续覆盖,但是每次我尝试使用自制软件安装某些东西时似乎都会发生这种情况。为什么?为什么自制软件没有按预期工作?
谢谢。