Possible Duplicate:
Rails 3.1 and Ruby 1.9.3p125: ruby-debug19 still crashes with “Symbol not found: _ruby_threadptr_data_type”
我运行这个:
gem 安装 ruby-debug19
在我的 cucumber env.rb
文件中,我有这个:
需要'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 一起工作?
更新:ruby-debug19 不再维护。这个问题和我的回答已经无关紧要,使用“调试器”gem 更容易。
我也遇到过这个,并在 Ruby 1.9.3 and ruby-debug 中找到了解决方案.您需要安装尚未正式发布的 ruby-debug-base19 和 linecache19 版本。当前发布的版本确实导致了您遇到的异常。
使用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