Unable to run ruby-debug on ruby1.9.3p0 under XP

292 Views Asked by At

How do I get ruby-debug to run under XP so that I can step through my Watir test scripts. I am unable to "require" ruby-debug on Windows XP. All of the solutions I have seen refer to a Unix-based system running Rails. Here is my system profile:

H:\>ruby -v
ruby 1.9.3p0 (2011-10-30) [i386-mingw32]

Here are the gems I have installed to support my testing in Watir

    H:\>gem list

    *** LOCAL GEMS ***

    archive-tar-minitar (0.5.2)
    awesome_print (1.0.2)
    bigdecimal (1.1.0)
    childprocess (0.2.4)
    columnize (0.3.6)
    ffi (1.0.11)
    io-console (0.3)
    json (1.5.4)
    linecache19 (0.5.13)
    minitest (2.5.1)
    mkrf (0.2.3)
    multi_json (1.0.4)
    net-ssh (2.2.1)
    rake (0.9.2.2)
    rdebug (0.1)
    rdiscount (1.6.8)
    rdoc (3.9.4)
    ruby-debug-base19x (0.11.30.pre4)
    ruby_core_source (0.1.5)
    rubygems-update (1.8.13)
    rubyzip (0.9.5)
    selenium-webdriver (2.15.0)
    watir-webdriver (0.4.1)
    wirble (0.1.3)

This is the error that presents itself when I try to "require" ruby-debug. Error:

    irb(main):001:0> require 'ruby-debug'
    LoadError: cannot load such file -- ruby-debug
    from C:/Ruby/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
    from C:/Ruby/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
    from (irb):1
    from C:/Ruby/bin/irb:12:in `<main>'
    irb(main):002:0>
2

There are 2 best solutions below

0
On BEST ANSWER

ruby-debug has been broken with recent ruby versions for a very long time. Try the debugger gem instead. I've no idea if it works on Windows though.

0
On

try this

gem install ruby-debug --pre