windows ruby 调试 ide gem 安装失败
Posted
技术标签:
【中文标题】windows ruby 调试 ide gem 安装失败【英文标题】:windows ruby debug ide gem install fail 【发布时间】:2012-01-25 00:15:25 【问题描述】:我找不到任何与我有相同问题的东西(即任何解决方案)。我无法在我的系统上安装某个 gem。我跑:
gem install ruby-debug-ide --platform=ruby --pre
现在一切都安装好了。 Ruby 1.9.3 和 Ruby DevKit 也已安装。我也安装了 ruby-debug-base19x 版本 0.11.30.pre3 并且进展顺利。现在,这是唯一给我带来麻烦的事情。我已经尝试了一切 - 重新启动我的机器,甚至重新安装 Ruby 和 Ruby DevKit。
这是 gem_make.out 文件中的错误:
C:/Ruby193/bin/ruby.exe mkrf_conf.rb
Building native extensions. This could take a while...
Building native extensions. This could take a while...
ERROR: Failed to build gem native extension.
C:/Ruby193/bin/ruby.exe extconf.rb
checking for rb_method_entry_t.called_id in method.h... no
checking for rb_control_frame_t.method_id in method.h... no
checking for if rb_iseq_compile_with_option was added an argument filepath... no
C:/Ruby193/lib/ruby/gems/1.9.1/gems/ruby_core_source-0.1.5/lib/ruby_core_source.rb:39: Use RbConfig instead of obsolete and deprecated Config.
checking for rb_method_entry_t.called_id in method.h... yes
checking for rb_method_entry() in method.h... yes
checking for vm_core.h... yes
checking for iseq.h... yes
checking for insns.inc... yes
checking for insns_info.inc... yes
checking for eval_intern.h... yes
checking for if rb_iseq_compile_with_option was added an argument filepath... yes
creating Makefile
make
generating ruby_debug-i386-mingw32.def
compiling breakpoint.c
compiling ruby_debug.c
ruby_debug.c: In function 'filename_cmp':
ruby_debug.c:522:9: warning: implicit declaration of function 'filename_cmp_impl'
ruby_debug.c:530:7: warning: implicit declaration of function 'realpath'
ruby_debug.c:530:34: warning: comparison between pointer and integer
linking shared-object ruby_debug.so
ruby_debug.o: In function `filename_cmp':
C:\Ruby193\lib\ruby\gems\1.9.1\gems\ruby-debug-base19x-0.11.30.pre6\ext\ruby_debug/ruby_debug.c:530: undefined reference to `realpath'
collect2: ld returned 1 exit status
make: *** [ruby_debug.so] Error 1
Gem files will remain installed in C:/Ruby193/lib/ruby/gems/1.9.1/gems/ruby-debug-base19x-0.11.30.pre6 for inspection.
Results logged to C:/Ruby193/lib/ruby/gems/1.9.1/gems/ruby-debug-base19x-0.11.30.pre6/ext/ruby_debug/gem_make.out
C:/Ruby193/lib/ruby/1.9.1/rubygems/installer.rb:552:in `rescue in block in build_extensions'
C:/Ruby193/lib/ruby/1.9.1/rubygems/installer.rb:530:in `block in build_extensions'
C:/Ruby193/lib/ruby/1.9.1/rubygems/installer.rb:505:in `each'
C:/Ruby193/lib/ruby/1.9.1/rubygems/installer.rb:505:in `build_extensions'
C:/Ruby193/lib/ruby/1.9.1/rubygems/installer.rb:180:in `install'
C:/Ruby193/lib/ruby/1.9.1/rubygems/dependency_installer.rb:297:in `block in install'
C:/Ruby193/lib/ruby/1.9.1/rubygems/dependency_installer.rb:270:in `each'
C:/Ruby193/lib/ruby/1.9.1/rubygems/dependency_installer.rb:270:in `each_with_index'
C:/Ruby193/lib/ruby/1.9.1/rubygems/dependency_installer.rb:270:in `install'
mkrf_conf.rb:25:in `rescue in <main>'
mkrf_conf.rb:20:in `<main>'
对于错误的长度,我深表歉意 - 我只是厌倦了从头开始多次没有运气,并确保我所做的一切都是正确的,没有忽略任何事情。非常感谢。
【问题讨论】:
【参考方案1】:看起来recent commit 可能已经解决了这个问题。可以试试pre9吗?
【讨论】:
我实际上在批处理文件中重新执行了 DevKit 的变量,导致它工作(终于!) - 所以如果有人遇到这样的麻烦,那可能会有所帮助。 :-)以上是关于windows ruby 调试 ide gem 安装失败的主要内容,如果未能解决你的问题,请参考以下文章
JetBrains RubyMine 3.2.4 调试器不工作
Rails:找不到 gem 'sdoc (>=0) ruby'
Ruby 2.1.0 / 2.1.1 / 2.1.2 不支持调试器 gem