1

I am getting the following Error While installing ruby debugger

In gemfile i added

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

and run

 bundle install

Installing linecache19 (0.5.12) with native extensions
   Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
   /usr/local/bin/ruby extconf.rb
   checking for vm_core.h... no
   checking for vm_core.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=/usr/local/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

What is the reason for the error

how to install thre debugger..???

3 Answers 3

2

You have to first set the path of DevKit in your environmental variable

Then run

gem install linecache19
gem install ruby-debug-base19
gem install ruby-debug-ide

through command prompt

May this work

0
1

From the RVM website:

If you have trouble installing ruby-debug19 try installing with the following command:

$ rvm reinstall 1.9.3 --patch debug --force-autoconf
$ gem install ruby-debug19 -- --with-ruby-include="${MY_RUBY_HOME/rubies/src}"
1
  • So no RVM on windows I guess?
    – Abram
    Commented Sep 4, 2012 at 6:48
1

"On Ubuntu, the native compilation step downloads the ruby 1.9.2 source and tries to unpack it into a directory that your current user probably does not have write access to." - Darren (Reference: http://isitruby19.com/linecache19)

In this case, try sudo bundle install.


If the problem is that it cannot resolve the vm_core.h file dependency, you can run the installs with specific versions and the path to the ruby source:

sudo -E gem install linecache19 -v=0.5.11 -- --with-ruby-include=path_to/ruby-1.9.1-p378/
sudo -E gem install ruby-debug-base19 -v=0.11.23 -- --with-ruby-include=path_to/ruby-1.9.1-p378/
sudo -E gem install ruby-debug-ide -v=0.4.9 -- --with-ruby-include=path_to/ruby-1.9.1-p378/

Reference: http://isitruby19.com/linecache19

Note, replace path_to/ruby-1.9.1-p378/, with the path to where you installed ruby.

To find out where you installed ruby, try running:

which ruby
1
  • Are you installing with superuser rights? eg. when you bundle, try sudo bundle
    – ronalchn
    Commented Sep 4, 2012 at 6:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.