2013-07-29 95 views
5

我的最终目标是安装当前版本的Ruby on Rails。我在OS X Mountain Lion上运行。这里是我的进程迄今:无法通过RVM安装Ruby 2.0.0-p247(OSX Mountain Lion)

安装RVM

$ \curl -L https://get.rvm.io | bash -s stable 

检查已知的(我假设批准)安装

$ rvm list known 

我看到,当前稳定版本可

[ruby-]2.0.0[-p247] 

键入命令安装

$ rvm install 2.0.0-p247 

注:我也尝试过这些安装我越来越无处快命令

$ rvm install ruby-2.0.0-p247 
$ rvm install ruby=2.0.0-p247 

。结果:

$ rvm install 2.0.0-p247 
Searching for binary rubies, this might take some time. 
No binary rubies available for: osx/10.8/x86_64/ruby-2.0.0-p247. 
Continuing with compilation. Please read 'rvm help mount' to get more information on binary rubies. 
Installing requirements for osx, might require sudo password. 
Certificates in '/usr/local/etc/openssl/cert.pem' already are up to date. 
Requirements installation successful. 
Installing Ruby from source to: /Users/xxxxx/.rvm/rubies/ruby-2.0.0-p247, this may take a while depending on your cpu(s)... 
ruby-2.0.0-p247 - #downloading ruby-2.0.0-p247, this may take a while depending on your connection... 
ruby-2.0.0-p247 - #extracted to /Users/xxxxx/.rvm/src/ruby-2.0.0-p247 (already extracted) 
ruby-2.0.0-p247 - #configuring........ 
Error running './configure --prefix=/Users/xxxxx/.rvm/rubies/ruby-2.0.0-p247 --with-opt-dir=/usr/local/opt/libyaml:/usr/local/opt/readline:/usr/local/opt/libksba:/usr/local/opt/openssl --disable-install-doc --without-tcl --without-tk --enable-shared', 
please read /Users/xxxxx/.rvm/log/ruby-2.0.0-p247/1375141206_configure.log 
There has been an error while running configure. Halting the installation. 

我也在调试模式下运行这个命令。为了避免混乱,你可以访问它here

而且,这里是日志:

./configure 
current path: /Users/xxxxx/.rvm/src/ruby-2.0.0-p247 
command(7): ./configure --prefix=/Users/xxxxx/.rvm/rubies/ruby-2.0.0-p247 --with-opt-dir=/usr/local/opt/libyaml:/usr/local/opt/readline:/usr/local/opt/libksba:/usr/local/opt/openssl --disable-install-doc --without-tcl --without-tk --enable-shared 
configure: WARNING: unrecognized options: --without-tcl, --without-tk 
checking build system type... x86_64-apple-darwin12.2.1 
checking host system type... x86_64-apple-darwin12.2.1 
checking target system type... x86_64-apple-darwin12.2.1 
checking whether the C compiler works... no 
configure: error: in `/Users/xxxxx/.rvm/src/ruby-2.0.0-p247': 
configure: error: C compiler cannot create executables 
See `config.log' for more details 

这是我通过RVM第一安装。 $ rvm列表不返回任何宝石。

请询问是否有其他信息可能有帮助。

编辑 - HERE是可以帮助任何人的登录情况。

+0

后,试图重新开始我的整个过程从头开始。现在重新安装Xcode和命令行工具 - 然后我会再试一次。我会在可用时发布我的结果。 – MrCarder

+1

请加上'/ Users/xxxxx/.rvm/src/ruby​​-2.0.0 -p247/config.log' – mpapis

+0

我想出了这个问题(种类)。如果我发布日志,它会对他人有帮助吗? – MrCarder

回答

4

我的Xcode或我的命令行工具安装一定是错误的。重新安装都使得一切都运行良好。

+0

你是如何卸载命令行工具的? – Clone

+3

由于您的答案缺乏技术深度并建议这样一个低效率的流程,因此得不到支持。 – JGallardo

1

请确保您在XCode中安装命令行工具,因为它不会自动执行(是的,我同意命令行工具应该默认安装),但事实并非如此。

安装的XCode - >首选项 - >下载 - >“命令行工具”

编辑*错过了整个“造万物运行精美一部分”,并输入这一切OUT-

干杯,很高兴一切工作出来了!

3

对于那些来到这里,从谷歌,当你应用了相同的错误查询:

我有同样的问题,但不希望要经过冗长得可笑的重新安装的Xcode喜欢接受的答案的过程建议。我所做的只是运行
rvm get stable然后运行
rvm install ruby-2.0.0-p247再次

我原来的问题

problem

然后我跑
rvm get stable

Solution

相关问题