2

我正在尝试在 Windows 机器 (Windows XP) 上为我的 RoR 应用程序运行捆绑程序。但是,在下载 gem 时,它会停在gem Charlock_Holmes并给出以下错误。

'Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension

.

    C:/Ruby192/bin/ruby.exe extconf.rb
  checking for main() in -licui18n... no
   which: no brew in (.;C:\Devkit\bin;C:\Devkit\mingw\bin;C:\Ruby192\bin;C:\WINDOWS
 \system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\Git\cmd;C:\TCWIN4
  5\BIN)
 checking for main() in -licui18n... no


********************************************************************************
*******
*********** icu required (brew install icu4c or apt-get install libicu-dev) ****
*******
********************************************************************************
*******
*** 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:/Ruby192/bin/ruby
    --with-icu-dir
    --without-icu-dir
    --with-icu-include
    --without-icu-include=${icu-dir}/include
    --with-icu-lib
    --without-icu-lib=${icu-dir}/lib
    --with-icui18nlib
    --without-icui18nlib
    --with-icui18nlib
    --without-icui18nlib


Gem files will remain installed in C:/Ruby192/lib/ruby/gems/1.9.1/gems/charlock_
holmes-0.6.9 for inspection.
Results logged to C:/Ruby192/lib/ruby/gems/1.9.1/gems/charlock_holmes-0.6.9/ext/
charlock_holmes/gem_make.out
An error occurred while installing charlock_holmes (0.6.9), and Bundler cannot c
ontinue.
Make sure that `gem install charlock_holmes -v '0.6.9'` succeeds before bundling'

你能帮我找出问题所在吗?

4

1 回答 1

2
需要 icu(brew install icu4c 或 apt-get install libicu-dev) 

正如您的问题所述,您需要libicu-dev. 如果您使用的是 Cygwin,则可以安装该软件包

cygwin.com/packages/x86/libicu-devel

于 2013-04-30T09:04:23.857 回答