问题
I've installed ruby-install like this:
brew install ruby-install
But, when I try to install ruby it fails:
$ ruby-install ruby
>>> Installing ruby 2.1.1 into /Users/mishamoroshko/.rubies/ruby-2.1.1 ...
>>> Installing dependencies for ruby 2.1.1 ...
Reading Package Lists... Done
Building Dependency Tree... Done
E: Couldn't find package build-essential
!!! Installing dependencies failed!
I'm on Mac OSX 10.9.2.
Any ideas?
回答1:
Apparently, apt-get
was the first in ruby-install
's package manager detection order. It was broken on my system, and this is why the error.
After I removed apt-get
from my system, ruby-install
picked up Homebrew and the error disappeared.
来源:https://stackoverflow.com/questions/22403376/why-ruby-install-ruby-fails-with-e-couldnt-find-package-build-essential