通过 rbenv 在 Yosemite 上安装 Ruby 2.3.0 时出错
Error installing Ruby 2.3.0 on Yosemite via rbenv
出于某种原因,我无法通过 RBENV 安装 ruby 2.3.0。不过,我让它可以与 RVM 一起使用。如果我需要提供更多信息,请告诉我。
这是我得到的错误:
Downloading ruby-2.3.0.tar.bz2...
-> https://cache.ruby-lang.org/pub/ruby/2.3/ruby-2.3.0.tar.bz2
Installing ruby-2.3.0...
BUILD FAILED (OS X 10.10.5 using ruby-build 20160426)
Inspect or clean up the working tree at /tmp/ruby-build.20160426211028.6622
Results logged to /tmp/ruby-build.20160426211028.6622.log
Last 10 log lines:
config.guess already exists
config.sub already exists
checking build system type... x86_64-apple-darwin14.5.0
checking host system type... x86_64-apple-darwin14.5.0
checking target system type... x86_64-apple-darwin14.5.0
checking whether the C compiler works... no
configure: error: in `/tmp/ruby-build.20160426211028.6622/ruby-2.3.0':
configure: error: C compiler cannot create executables
See `config.log' for more details
make: *** No targets specified and no makefile found. Stop.
您的系统的安全策略过于严格,因此为 rbenv 添加 sudo
以提供添加执行的能力。所以你会喜欢这样的东西:
sudo rbenv install 2.3.0
出于某种原因,我无法通过 RBENV 安装 ruby 2.3.0。不过,我让它可以与 RVM 一起使用。如果我需要提供更多信息,请告诉我。
这是我得到的错误:
Downloading ruby-2.3.0.tar.bz2...
-> https://cache.ruby-lang.org/pub/ruby/2.3/ruby-2.3.0.tar.bz2
Installing ruby-2.3.0...
BUILD FAILED (OS X 10.10.5 using ruby-build 20160426)
Inspect or clean up the working tree at /tmp/ruby-build.20160426211028.6622
Results logged to /tmp/ruby-build.20160426211028.6622.log
Last 10 log lines:
config.guess already exists
config.sub already exists
checking build system type... x86_64-apple-darwin14.5.0
checking host system type... x86_64-apple-darwin14.5.0
checking target system type... x86_64-apple-darwin14.5.0
checking whether the C compiler works... no
configure: error: in `/tmp/ruby-build.20160426211028.6622/ruby-2.3.0':
configure: error: C compiler cannot create executables
See `config.log' for more details
make: *** No targets specified and no makefile found. Stop.
您的系统的安全策略过于严格,因此为 rbenv 添加 sudo
以提供添加执行的能力。所以你会喜欢这样的东西:
sudo rbenv install 2.3.0