ruby-debug-base19-0.11.26.gem on WIN x64

帅比萌擦擦* 提交于 2019-12-11 08:14:23

问题


Info about my system:

ruby -v -> ruby 1.9.3p125 (2012-02-16) [i386-mingw32]

gem -v -> 1.8.24


when i'm running

bundle install

output:

Fetching source index for http://rubygems.org/
Could not find ruby-debug-base19-0.11.26 in any of the sources

the firewall is OFF

I downloaded this file: ruby-debug-base19-0.11.26.gem

but when i run:

gem install ruby-debug-base19-0.11.26.gem

outputs:

Temporarily enhancing PATH to include DevKit...
Building native extensions.  This could take a while...
ERROR:  Error installing ruby-debug-base19-0.11.26.gem:
        ERROR: Failed to build gem native extension.

        C:/RailsInstaller/Ruby1.9.3/bin/ruby.exe extconf.rb
checking for rb_method_entry_t.called_id in method.h... no
checking for rb_control_frame_t.method_id in method.h... no
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of
necessary libraries and/or headers.  Check the mkmf.log file for more
details.  You may need configuration options.

Provided configuration options:
        --with-opt-dir
        --without-opt-dir
        --with-opt-include
        --without-opt-include=${opt-dir}/include
        --with-opt-lib
        --without-opt-lib=${opt-dir}/lib
        --with-make-prog
        --without-make-prog
        --srcdir=.
        --curdir
        --ruby=C:/RailsInstaller/Ruby1.9.3/bin/ruby
        --with-ruby-dir
        --without-ruby-dir
        --with-ruby-include
        --without-ruby-include=${ruby-dir}/include
        --with-ruby-lib
        --without-ruby-lib=${ruby-dir}/lib
extconf.rb:16:in `block in <main>': break from proc-closure (LocalJumpError)
        from C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/ruby_core_sour
ce-0.1.5/lib/ruby_core_source.rb:18:in `call'
        from C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/ruby_core_sour
ce-0.1.5/lib/ruby_core_source.rb:18:in `create_makefile_with_core'
        from extconf.rb:32:in `<main>'


Gem files will remain installed in C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9
.1/gems/ruby-debug-base19-0.11.26 for inspection.
Results logged to C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/ruby-debu
g-base19-0.11.26/ext/ruby_debug/gem_make.out

what's the problem??


回答1:


You need to provide the --with-ruby-include options with ruby-debug-base19. In your case try:

gem install ruby-debug-base19-0.11.26.gem -- --with-ruby-include=C:/RailsInstaller/Ruby1.9.3/include/ruby-1.9.1/ruby-1.9.3-p125

Alternatively look at the debugger gem. It seems to cut a lot of fat off the other debugging gems, plus it actually works and installs easily!




回答2:


Open your Gemfile

See if there's something like this...

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

Comment it out, and use 'debugger' instead

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


来源:https://stackoverflow.com/questions/10475837/ruby-debug-base19-0-11-26-gem-on-win-x64

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!