3

Mac (10.7.5、ruby-1.9.3-p392) に charlock_holmes をインストールしようとすると、次のエラーが発生します。

$gem install charlock_holmes -v '0.6.9.4'
Building native extensions.
This could take a while...
ERROR:  Error installing charlock_holmes:
ERROR: Failed to build gem native extension.

/Users/mthompson/.rvm/rubies/ruby-1.9.3-p392/bin/ruby extconf.rb
checking for main() in -licui18n... no
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.

macports 経由で icu をインストールしたので、icu ディレクトリは/opt/local/lib/icu/opt/local/share/icuです。指定されたディレクトリでインストールを試みました:

$ gem install charlock_holmes -v '0.6.9.4' -- --with-icu-dir=/opt/local/lib/icu --with-opt-include=/usr/local/include/ --with-opt-lib=/usr/local/lib/

..しかし、同じエラーが発生しました。どんなアイデアでも大歓迎です。

4

3 に答える 3

2

結局、MacPorts から Homebrew に切り替えて、ルビーとパッケージを再インストールしました。

于 2013-06-18T20:01:41.680 に答える