新手问题 在 mac os x 10.8 xcode 4.5 的环境下安装 ruby 时报 gcc 的错误应该解决呀?

echowang_2011 · 2012年10月28日 · 最后由 leomayleomay 回复于 2012年10月28日 · 4393 次阅读

Ruby (and needed base gems) for your selection will be installed shortly. Before it happens, please read and execute the instructions below. Please use a separate terminal to execute any additional commands.

Notes for Mac OS X 10.8, Xcode 4.5.1.

For JRuby: Install the JDK. See http://developer.apple.com/java/download/ # Current Java version "1.6.0_26" For IronRuby: Install Mono >= 2.6 For Ruby 1.9.3: Install libksba # If using Homebrew, 'brew install libksba'

To use an RVM installed Ruby as default, instead of the system ruby:

rvm install 1.8.7 # installs patch 357: closest supported version rvm system ; rvm gemset export system.gems ; rvm 1.8.7 ; rvm gemset import system.gems # migrate your gems rvm alias create default 1.8.7

And reopen your terminal windows.

Xcode and gcc:

Right now Ruby requires gcc to compile, but Xcode 4.2 and later no longer ship w:

以上是提示信息。

Open XCode go to preferences under downloads install command line tools.

Hope this will help you.

我已经安装了 command line tools

需要 登录 后方可回复, 如果你还没有账号请 注册新账号