错误而与RVM
我试图安装这种方式安装ruby2:错误而与RVM
brew install autoconf brew install automake brew install libyaml rvm install ruby-head
我尝试安装与RVM ruby2但我得到这个错误:
ruby-head - #compiling Error running 'make ', please read /Users/boti/.rvm/log/ruby-head/make.log There has been an error while running make. Halting the installation. Ruby 'ruby-head' was build using clang - but it's not (fully) supported, expect errors.
这是我的编译日志:
compiling ./missing/setproctitle.c compiling dmyext.c linking miniruby /Users/boti/.rvm/src/ruby-head/lib/fileutils.rb:111: [BUG] Stack consistency error (sp: 38, bp: 36) ruby 2.0.0dev (2013-02-25) [x86_64-darwin12.2.0]
-- Crash Report log information -------------------------------------------- See Crash Report log file under the one of following: * ~/Library/Logs/CrashReporter * /Library/Logs/CrashReporter * ~/Library/Logs/DiagnosticReports * /Library/Logs/DiagnosticReports the more detail of.
-- Control frame information ----------------------------------------------- c:0006 p:0038 s:0038 e:000037 CLASS /Users/boti/.rvm/src/ruby-head/lib/fileutils.rb:111 c:0005 p:0035 s:0034 e:000033 CLASS /Users/boti/.rvm/src/ruby-head/lib/fileutils.rb:107 c:0004 p:0009 s:0032 e:000031 TOP
/Users/boti/.rvm/src/ruby-head/lib/fileutils.rb:85 [FINISH] c:0003 p:---- s:0030 e:000029 CFUNC :require c:0002 p:0098 s:0026 E:000f88 EVAL ./tool/mkconfig.rb:11 [FINISH] c:0001 p:0000 s:0002 E:0017a8 TOP [FINISH]./tool/mkconfig.rb:11:in
<main>' ./tool/mkconfig.rb:11:in
require' /Users/boti/.rvm/src/ruby-head/lib/fileutils.rb:85:in<top (required)>' /Users/boti/.rvm/src/ruby-head/lib/fileutils.rb:107:in
' /Users/boti/.rvm/src/ruby-head/lib/fileutils.rb:111:in `'-- Other runtime information -----------------------------------------------
Loaded script: ./tool/mkconfig.rb
Loaded features:
0 enumerator.so
[NOTE] You may have encountered a bug in the Ruby interpreter or extension libraries. Bug reports are welcome. For details: http://www.ruby-lang.org/bugreport.html
make: * [.rbconfig.time] Abort trap: 6
这是我的编译日志的开头:
[2013-02-24 20:58:47] make CC = /usr/bin/gcc-4.2 LD = ld LDSHARED = /usr/bin/gcc-4.2 -dynamiclib CFLAGS = -O3 -fno-fast-math -ggdb3 -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initializers -Wunused-variable -Werror=pointer-arith -Werror=write-strings -Werror=declaration-after-statement -Werror=shorten-64-to-32 -Werror=implicit-function-declaration -fno-common -pipe XCFLAGS = -include ruby/config.h -include ruby/missing.h -D_FORTIFY_SOURCE=2 -fstack-protector -fno-strict-overflow -fvisibility=hidden -DRUBY_EXPORT CPPFLAGS = -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE -D_DARWIN_UNLIMITED_SELECT -D_REENTRANT -I. -I.ext/include/x86_64-darwin12.2.0 -I./include -I. DLDFLAGS = -Wl,-undefined,dynamic_lookup -Wl,-multiply_defined,suppress -install_name /Users/boti/.rvm/rubies/ruby-head/lib/libruby.2.0.0.dylib -current_version 2.0.0 -compatibility_version 2.0.0 -fstack-protector -Wl,-u,_objc_msgSend -fstack-protector -Wl,-u,_objc_msgSend SOLIBS =
我希望得到任何帮助......
我在Mac OS X 10.8.2用的XCode 4.6和BREW运行到周围miniruby生成错误也是如此。
如果只是想经营 “RVM安装2.0.0” 的结果是这样的:
https://gist.github.com/polarapfel/5080946
当试图设置CC到/ usr/bin中/铛,结果如下:
https://gist.github.com/polarapfel/5081054
无论哪种方式,其结果对我来说是一样的。
下面是关于它的有趣的事情:没有问题,我可以建立头。我认为2.0.0p0在Mac OS X上不是一个干净的版本,需要更多的工作来解决这些问题。
-
OK,这为我做:只需运行“RVM获得稳定的”摆脱了构建问题。
确保您使用铛3.0铛-v。
否则,如果你使用的是旧版本的铿锵使用编译2.0.0-P0用gcc 4.2:
rvm install ruby --with-gcc=gcc-4.2
我会先删除旧的红宝石尝试:
rvm remove 2.0.0-p0
还要确保你已经有了RVM头(不稳定):
rvm get head --autolibs=3
如果这应该解决miniruby/ENC编译问题,然后2.0.0-P0是一个干净的构建,但你使用过时的编译器。安装最新的Xcode不一定包含最新的叮当声版本。
是否已安装的Xcode的最新版本,命令行工具的最新版本? – michaelmichael 2013-02-24 19:10:06
Uff ...不,我现在正在做。谢谢... – Boti 2013-02-24 19:14:59
NP,只是我看到的第一件事情,如果我得到编译器错误。另外,请用结果更新问题。@mpapis(RVM发布经理)的答案表明RVM知道这个问题。 – michaelmichael 2013-02-24 19:29:46