我的RubyMine版本4.0.1上的调试模式在将ruby版本升级到2.0.0后停止工作

时间:2013-06-19 09:10:11

标签: ubuntu rubygems rubymine

我有RubyMine版本4.0.1,我将Ruby升级到2.0.0。

尝试调试(开发或测试)时,我收到此消息:

The gem ruby-debug-base required by the debugger is not currently installed. Would you like to install it?

点击“是”后,我收到此错误:

Error running Development: air: Failed to Install Gems. Following gems were not installed: linecache (0.46): Error installing linecache: ERROR: Failed to build gem native extension. /home/yehuda/.rvm/rubies/ruby-2.0.0-p195/bin/ruby extconf.rb Can't handle 1.9.x yet *** 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=/home/yehuda/.rvm/rubies/ruby-2.0.0-p195/bin/ruby Gem files will remain installed in /home/yehuda/.rvm/gems/ruby-2.0.0-p195@global/gems/linecache-0.46 for inspection. Results logged to /home/yehuda/.rvm/gems/ruby-2.0.0-p195@global/gems/linecache-0.46/ext/gem_make.out /home/yehuda/Downloads/RubyMine-4.0.1/rb/gems/ruby-debug-base-0.10.5.jb2.gem: Error installing ruby-debug-base-0.10.5.jb2.gem: ERROR: Failed to build gem native extension. /home/yehuda/.rvm/rubies/ruby-2.0.0-p195/bin/ruby extconf.rb Can't handle 1.9.x yet *** 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=/home/yehuda/.rvm/rubies/ruby-2.0.0-p195/bin/ruby Gem files will remain installed in /home/yehuda/.rvm/gems/ruby-2.0.0-p195@global/gems/linecache-0.46 for inspection. Results logged to /home/yehuda/.rvm/gems/ruby-2.0.0-p195@global/gems/linecache-0.46/ext/gem_make.out

我读过这篇文章 - http://blog.jetbrains.com/ruby/2013/01/rubymine-enoki-eap-enjoy-ruby-2-0-apps-debugging/ 并尝试了5.4,但同样的问题发生了。

1 个答案:

答案 0 :(得分:4)

请更新到RubyMine 5.4.2,它将安装正确的调试gem版本。

5.x之前的RubyMine版本不支持Ruby 2.0调试。

5.x版本为Ruby 2.0安装以下gem:

ruby-debug-ide (0.4.17)

请注意,使用Ruby 2.0时,不需要linecacheruby-debug-base宝石,RubyMine 5也不会安装这些宝石。

如果由于某种原因无法从RubyMine安装ruby-debug-ide gem,请尝试从终端安装:

gem install ruby-debug-ide