不能在1.9.3-p0中使用ruby-debug19? [英] Cannot use ruby-debug19 with 1.9.3-p0?

查看:95
本文介绍了不能在1.9.3-p0中使用ruby-debug19?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


可能存在重复:

/ b>

我执行此操作:



gem install ruby​​-debug19



在我的黄瓜 env.rb 文件,我有这个:

require'ruby-debug'



当我尝试运行时,出现以下异常:

/ home / skendall / .rvm / gems / ruby​​-1.9.3-p0 / gems / ruby​​-debug-base19-0.11.25 / lib / ruby​​_debug.so:undefined symbol:ruby_current_thread - /home/skendall/.rvm/gems/ruby-1.9。 3-p0 / gems / ruby​​-debug-base19-0.11.25 / lib / ruby​​_debug.so(LoadError)



我需要什么要做的是让ruby-debug使用1.9.3-p0?

解决方案

UPDATE:ruby-debug19不再被维护。这个问题和我的答案已经变得无关紧要,使用'debugger'gem变得容易得多。



请参阅



我也遇到过这个问题,并在<一个href =http://blog.wyeworks.com/2011/11/1/1/ruby-1-9-3-and-ruby-debug =nofollow noreferrer> Ruby 1.9.3和ruby-debug 。您需要安装尚未正式发布的ruby-debug-base19和linecache19版本。 使用 >这个要点

 #要在Ubuntu ruby​​-1.9.3上安装ruby-debug,您需要从http://rubyforge.org/frs/?group_id=8883 

linecache19-0.5.13.gem
ruby​​_core_source-0.1.5.gem
ruby​​-debug19-0.11。 6.gem
ruby​​-debug-base19-0.11.26.gem

#然后在你的控制台中

export RVM_SRC = / your / path / to / ruby -1.9.3
#注意,你的源代码路径应该是/home/user/.rvm/src/ruby-1.9.3-p0

gem install archive-tar-minitar
gem install ruby​​_core_source-0.1.5.gem - --with-ruby-include = / $ RVM_SRC
gem install linecache19-0.5.13.gem - --with-ruby-include = / $ RVM_SRC
gem install ruby​​-debug-base19-0.11.26.gem - --with-ruby-include = / $ RVM_SRC
gem install ruby​​-debug19-0.11.6.gem - - -with-ruby-include = / $ RVM_SRC


Possible Duplicate:
Rails 3.1 and Ruby 1.9.3p125: ruby-debug19 still crashes with “Symbol not found: _ruby_threadptr_data_type”

I run this:

gem install ruby-debug19

And in my cucumber env.rb file, I have this:

require 'ruby-debug'

When I try to run, though, I get this exception:

/home/skendall/.rvm/gems/ruby-1.9.3-p0/gems/ruby-debug-base19-0.11.25/lib/ruby_debug.so: undefined symbol: ruby_current_thread - /home/skendall/.rvm/gems/ruby-1.9.3-p0/gems/ruby-debug-base19-0.11.25/lib/ruby_debug.so (LoadError)

What do I need to do to get ruby-debug to work with 1.9.3-p0?

解决方案

UPDATE: ruby-debug19 is not maintained anymore. This question and my answer have become irrelevant, it's far easier to use the 'debugger' gem instead.

See Debugging in ruby 1.9

I also ran into this, and found the solution in Ruby 1.9.3 and ruby-debug. You need to install not-yet-officially-released versions of ruby-debug-base19 and linecache19. The currently released versions indeed cause the exception you had.

Use this gist.

#To install ruby-debug on Ubuntu ruby-1.9.3 you need to download from http://rubyforge.org/frs/?group_id=8883

linecache19-0.5.13.gem 
ruby_core_source-0.1.5.gem 
ruby-debug19-0.11.6.gem 
ruby-debug-base19-0.11.26.gem

#Then in your console

export RVM_SRC=/your/path/to/ruby-1.9.3
# Note, your source path should be something like /home/user/.rvm/src/ruby-1.9.3-p0

gem install archive-tar-minitar
gem install ruby_core_source-0.1.5.gem -- --with-ruby-include=/$RVM_SRC
gem install linecache19-0.5.13.gem -- --with-ruby-include=/$RVM_SRC
gem install ruby-debug-base19-0.11.26.gem -- --with-ruby-include=/$RVM_SRC
gem install ruby-debug19-0.11.6.gem -- --with-ruby-include=/$RVM_SRC

这篇关于不能在1.9.3-p0中使用ruby-debug19?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆