我尝试通过 RVM 安装 ruby 2.1.1,但收到以下错误:
vmamaev@vmamaev:~$ rvm install ruby-2.1.1
ruby-2.1.1 - #removing src.
Searching for binary rubies, this might take some time.
No binary rubies available for: debian/7/i386/ruby-2.1.1.
Continuing with compilation. Please read 'rvm help mount' to get more information on binary rubies.
Checking requirements for debian.
Requirements installation successful.
Installing Ruby from source to: /home/vmamaev/.rvm/rubies/ruby-2.1.1, this may take a while depending on your cpu(s)...
ruby-2.1.1 - #downloading ruby-2.1.1, this may take a while depending on your connection...
ruby-2.1.1 - #extracting ruby-2.1.1 to /home/vmamaev/.rvm/src/ruby-2.1.1.
ruby-2.1.1 - #configuring.....................................................
ruby-2.1.1 - #post-configuration.
ruby-2.1.1 - #compiling..........
Error running '__rvm_make -j1',
showing last 15 lines of /home/vmamaev/.rvm/log/1394209466_ruby-2.1.1/make.log
compiling vm_trace.c
compiling thread.c
compiling cont.c
compiling ./enc/ascii.c
compiling ./enc/us_ascii.c
compiling ./enc/unicode.c
compiling ./enc/utf_8.c
compiling newline.c
compiling ./missing/strlcpy.c
compiling ./missing/strlcat.c
compiling ./missing/setproctitle.c
compiling addr2line.c
compiling dmyext.c
linking miniruby
make: *** [.rbconfig.time] Illegal instruction
There has been an error while running make. Halting the installation
vmamaev@vmamaev:~$ rvm requirements
Checking requirements for debian.
Requirements installation successful.
电脑设置:
AMD 速龙 2200MHz
32位
2GB 内存
Debian 7
gcc-4.7
请帮我通过 rvm 安装 ruby...
之前我安装了 Arch Linux,也遇到了同样的问题。
答案1
CFLAGS="-march=" 有问题本国的“尝试为编译器 gcc 指定标准标志。
答案2
检查这个解决方法,它对我有用: https://github.com/wayneeseguin/rvm/issues/2850
问候