【发布时间】:2016-08-21 02:16:54
【问题描述】:
由于某种原因,我无法通过 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.
【问题讨论】:
-
您安装了 OSX 构建工具吗?
-
您是否在尝试使用 rvm 时卸载 rbenv,反之亦然?如果不是,您应该这样做,因为这些工具相互不兼容。
-
@MarsAtomic 是的,在我决定使用 rvm 之前,我只有 rbenv。现在我两者都有,而且 rvm 工作正常。我想知道为什么 rbenv 根本不起作用。感谢您的评论。
-
@AnthonyE 是的,我愿意。它是在我安装 Homebrew 时安装的。
标签: ruby-on-rails ruby environment osx-yosemite