2013-07-28 60 views
1

我運行下面的命令來安裝寶石紅寶石調試base19:無法建立

bundle install --without production 

它開始安裝,直到它到達紅寶石調試base19。當它試圖安裝它應該以下錯誤

Installing ruby-debug-base19 (0.11.25) 
Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension. 

/usr/bin/ruby.exe extconf.rb 
checking for rb_method_entry_t.body in method.h... no 
checking for vm_core.h... no 
/usr/lib/ruby/gems/1.9.1/gems/ruby_core_source-0.1.5/lib/ruby_core_source.rb:39: Use RbConfig instead of obsolete and deprecated Config. 
checking for rb_method_entry_t.body in method.h... no 
checking for vm_core.h... yes 
checking for iseq.h... yes 
checking for insns.inc... yes 
checking for insns_info.inc... yes 
checking for eval_intern.h... yes 
creating Makefile 

make 
gcc -I. -I/usr/include/ruby-1.9.1/i386-cygwin -I/usr/include/ruby-1.9.1/ruby/backward -I/usr/include/ruby-1.9.1 -I. -DHAVE_VM_CORE_H -DHAVE_ISEQ_H -DHAVE_INSNS_INC -DHAVE_INSNS_INFO_INC -DHAVE_EVAL_INTERN_H -I/usr/include/ruby-1.9.1/ruby-1.9.3-p429 -ggdb -O2 -pipe -fno-strict-aliasing -o breakpoint.o -c breakpoint.c 
gcc -I. -I/usr/include/ruby-1.9.1/i386-cygwin -I/usr/include/ruby-1.9.1/ruby/backward -I/usr/include/ruby-1.9.1 -I. -DHAVE_VM_CORE_H -DHAVE_ISEQ_H -DHAVE_INSNS_INC -DHAVE_INSNS_INFO_INC -DHAVE_EVAL_INTERN_H -I/usr/include/ruby-1.9.1/ruby-1.9.3-p429 -ggdb -O2 -pipe -fno-strict-aliasing -o ruby_debug.o -c ruby_debug.c 
ruby_debug.c:29:19: error: conflicting types for ‘rb_iseq_compile_with_option’ 
In file included from ruby_debug.c:4:0: 
/usr/include/ruby-1.9.1/ruby-1.9.3-p429/vm_core.h:506:7: note: previous declaration of ‘rb_iseq_compile_with_option’ was here 
Makefile:206: recipe for target `ruby_debug.o' failed 
make: *** [ruby_debug.o] Error 1 


Gem files will remain installed in /usr/lib/ruby/gems/1.9.1/gems/ruby-debug-base19-0.11.25 for inspection. 
Results logged to /usr/lib/ruby/gems/1.9.1/gems/ruby-debug-base19-0.11.25/ext/ruby_debug/gem_make.out 

An error occurred while installing ruby-debug-base19 (0.11.25), and Bundler cannot continue. 
Make sure that `gem install ruby-debug-base19 -v '0.11.25'` succeeds before bundling. 

此錯誤的原因是什麼?它如何解決?

回答

1

ruby-debug19不再被維護。

但是,還有一種替代方案:

debugger

打開你的Gemfile

看看有沒有這樣的事情......

gem 'ruby-debug19', :require => 'ruby-debug' 

評論出來,並用'調試器'而不是

#gem 'ruby-debug19', :require => 'ruby-debug' 
gem 'debugger' 

它被包含在rails 3.2以來的Gemfile中,替換爲ruby-debug19。它具有完全相同的功能並得到積極維護。