在Windows上在Ruby 1.9.1上安装Hpricot

我正在使用命令安装hpricot:
>gem install hpricot -v 0.8.2
Building native extensions.  This Could take a while...
ERROR:  Error installing hpricot:
    ERROR: Failed to build gem native extension.

C:/Ruby19/bin/ruby.exe extconf.rb checking for stdio.h... * 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=C:/Ruby19/bin/ruby C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:362:in try_do': The complier Failed to generate an executable file. (RuntimeError) You have to install development tools first. from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:431:intry_cpp' from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:809:in block in have_header' from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:668:inblock in checking_for' from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:274:in block (2 levels) in postpone' from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:248:inopen' from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:274:in block in postpone' from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:248:inopen' from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:270:in postpone' from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:667:inchecking_for' from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:808:in have_header' from extconf.rb:2:in'

Gem files will remain installed in C:/Ruby19/lib/ruby/gems/1.9.1/gems/hpricot-0.8.2 for inspection. Results logged to C:/Ruby19/lib/ruby/gems/1.9.1/gems/hpricot-0.8.2/ext/fast_xs/gem_make.out

try_do': The complier Failed to generate an executable file. (RuntimeError) You have to install development tools first. from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:431:inblock in have_header' from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:668:inblock (2 levels) in postpone' from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:248:inblock in postpone' from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:248:inpostpone' from C:/Ruby19/lib/ruby/1.9.1/mkmf.rb:667:inhave_header' from extconf.rb:2:in

它提到我需要安装“开发工具”,但我不知道这是什么。有什么建议么?

尝试:
gem install hpricot --platform=mswin32

相关文章

Windows注册表操作基础代码 Windows下对注册表进行操作使用的...
黑客常用WinAPI函数整理之前的博客写了很多关于Windows编程的...
一个简单的Windows Socket可复用框架说起网络编程,无非是建...
Windows文件操作基础代码 Windows下对文件进行操作使用的一段...
Winpcap基础代码 使用Winpcap进行网络数据的截获和发送都需要...
使用vbs脚本进行批量编码转换 最近需要使用SourceInsight查看...