本文介绍了如何使用rvm在OS_X 10.9上安装ruby 2.1.0? (没有适用于osx/10.9/x86_64/ruby的二进制红宝石)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试安装ruby 1.9.3-p545或ruby-2.1.0或ruby-2.1.1,但失败了...
I'm trying to install ruby 1.9.3-p545 or ruby-2.1.0 or ruby-2.1.1, but it fails...
我的环境:
- OS_X 10.9 x86_64
- rvm 1.25.20
终端错误:
bmalets$ rvm install 1.9.3-p545
Searching for binary rubies, this might take some time.
No binary rubies available for: osx/10.9/x86_64/ruby-1.9.3-p545.
Continuing with compilation. Please read 'rvm help mount' to get more information on binary rubies.
Checking requirements for osx_port.
Installing macports......................................................bmalets password required for 'make install':
......................
Installing requirements for osx_port.
Updating system............
Error running 'requirements_osx_port_update_system ruby-1.9.3-p545',
showing last 15 lines of /Users/bmalets/.rvm/log/1394647562_ruby-1.9.3-p545/update_system.log
checking Mac OS X version... 10.9.2
checking Xcode location... /Applications/Xcode.app/Contents/Developer
checking Xcode version... 5.0.2
checking for gcc... /usr/bin/llvm-gcc-4.2
checking whether the C compiler works... no
configure: error: in `/opt/local/var/macports/sources/rsync.macports.org/release/base':
configure: error: C compiler cannot create executables
See `config.log' for more details
shell command "cd /opt/local/var/macports/sources/rsync.macports.org/release/base && CC=/usr/bin/llvm-gcc-4.2 ./configure --prefix=/opt/local --with-tclpackage=/Library/Tcl --with-install-user=root --with-install-group=admin --with-directory-mode=0755 --enable-readline && make && make install" returned error 77
DEBUG: Error installing new MacPorts base: shell command failed (see log for details)
while executing
"macports::selfupdate [array get global_options] base_updated"
Error: /opt/local/bin/port: port selfupdate failed: Error installing new MacPorts base: shell command failed (see log for details)
++ return 1
++ return 1
Requirements installation failed with status: 1.
请帮助.
P.S.我试图更新命令行工具,但也失败了:
P.S.I tried to update my command line tools, it fails too:
我尝试更新端口:sudo port -v selfupdate
,它要求我提供命令行工具:)
I tried to update ports: sudo port -v selfupdate
, and it ask me for command line tools :)
bmalets$ sudo xcode-select --install
xcode-select: note: install requested for command line developer tools
推荐答案
嗯,我遇到了类似的问题.即使不确定细节,我也终于解决了……T_T
Well, I got the similar problem. And I finally solved it even though I was not sure about the details... T_T
安装自制软件
运行rvm requirements
,它将自动下载一些软件包
run rvm requirements
, and it will download some packages automatically
工作!
这篇关于如何使用rvm在OS_X 10.9上安装ruby 2.1.0? (没有适用于osx/10.9/x86_64/ruby的二进制红宝石)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!