すんなり行かなかったのでメモしておく。
mecabはbrewでインストールすると楽だった。
(後述のmecab-pythonが上手くインストールできず、試行錯誤の過程でコンパイルして入れちゃったけど)
$ brew install mecab
$ brew install mecab-ipadic
こっからが本番。mecab-pythonのインストール。
普通にeasy_install https://mecab.googlecode.com/files/mecab-python-0.996.tar.gzとかやると、
clang: error: unknown argument: '-mno-fused-madd' [-Wunused-command-line-argument-hard-error-in-future]
clang: note: this will be a hard error (cannot be downgraded to a warning) in the future
error: command '/usr/bin/gcc' failed with exit status 1
ってエラーが出てくる。
上手くいかなくていろいろ調べた結果、環境変数をセットすると上手くいった。
$ wget https://mecab.googlecode.com/files/mecab-python-0.996.tar.gz
$ tar zxfv mecab-python-0.996.tar.gz
$ cd mecab-python-0.996
$
$ export CFLAGS=-Qunused-arguments
$ export CPPFLAGS=-Qunused-arguments
$ python setup.py build
$ python setup.py install
おわり。