Autodetect mecab

Change configure.ac to autodetect mecab unless --with-mecab / --without-mecab
is specified.