CygwinにTinySVM入れてみた

http://d.hatena.ne.jp/svnseeds/20040222
http://kokeshi.dyndns.org/coding/cabocha_on_cygwin
を参考にCygwinにTinySVM

上記URLに書いてある通り、開発途中の最新版を明示的に使ってみる。

tar zxvf TinySVM-0.09.tar.gz
cd TinySVM-0.09
aclocal-1.11
automake-1.11 --add-missing
autoconf-2.68
libtoolize --force

ここで設定ファイルを編集

  • configure.inのAC_ISC_POSIXの直後にAC_CYGWINを追加
  • Makefile.inのLDFLAGSを次のように書き換え
LDFLAGS = -no-undefined @LDFLAGS@

さらに、ソースの書き換えも必要だった。src/getopt.h の148行目を次のように書き換え
変更前

extern int getopt();

変更後

extern int getopt (int argc, char *const *argv, const char *shortopts);

ここまで変更したら再びコマンド入力

automake-1.11
autoconf-2.68
./configure
make
make intall