Ruby已经消失了。 帮我重新安装ruby-1.9.3-p194

我是Ruby和Ruby on Rails的新手,我目前正在阅读Michael Hartl的Ruby on Rails教程。 或者至少我是在尝试加载安装之前的一些开源代码让我走上了一段黑暗的旅程。 我以某种方式设法从我的计算机中删除任何版本的Ruby,RVM不允许我使用rvm install 1.9.3(或使用珠宝盒)重新安装它。 我也尝试卸载Xcode并按照我发现无效的其他说明安装osx-gcc-installer。

添加了上下文:运行ruby -v会使系统挂起。

这是错误:

ruby-1.9.3-p194 - #configuring Error running 'env LDFLAGS=-L/opt/sm/pkg/active/lib CFLAGS=-I/opt/sm/pkg/active/include CPATH=/opt/sm/pkg/active/include -L/usr/local/rvm/usr/lib ./configure --enable-shared -- disable-install-doc --prefix=/usr/local/rvm/rubies/ruby-1.9.3-p194', please read /usr/local/rvm/log/ruby-1.9.3-p194/configure.log There has been an error while running configure. Halting the installation. 

这是日志的相关部分:

 checking build system type... x86_64-apple-darwin12.2.0 checking host system type... x86_64-apple-darwin12.2.0 checking target system type... x86_64-apple-darwin12.2.0 checking whether the C compiler works... no configure: error: in `/usr/local/rvm/src/ruby-1.9.3-p194': configure: error: C compiler cannot create executables See `config.log' for more details 

任何帮助将不胜感激!

重新安装一切!

这可能听起来像一个noob one-hit-wonder类型的解决方案。 但是当我说它会节省你的时间时相信我

编辑:要做的事情是……

  1. 如果您还没有自制软件,请安装它。
  2. 内爆RVM。 这将删除所有ruby并删除RVM
  3. 如果您使用的是OS X Mountain Lion,请运行CC=/Developer/usr/bin/gcc 。 这使用了很好的老gcc
  4. 重新安装RVM
  5. rvm install 1.9.3
  6. 请享用 (:

如果您使用的是Mac OS X,那么使用自制软件获取Ruby 1.9.3-p194可能会更容易。

安装自制软件的安装应该像下面这样简单:

 $ brew install ruby 

还有很多其他资源可供您根据版本进行特定链接; 狮子,雪豹,豹子等…… 下载ruby 。

我想你可以编辑如下,它将被解决

https://github.com/railsinstaller/railsinstaller-nix/issues/10