今のKAKASIをメンテナンスしている野首です。
At Mon, 12 Nov 2007 08:32:57 +0900,
<[メールアドレス保護]>
wrote:
>
> libkakasi.aというのがライブラリらしいのですが
> KAKASIをmakeするときに以下のようなlibtoolの警告が出るのが原因でしょうか?
>
> --------------------------------------------------------------------------------
> libtool: link: warning: undefined symbols not allowed in i686-pc-cygwin
> shared libraries
確認してみました。ソースにあるlibtoolを直接見てもらうとわかるのですが、
--
*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*)
# It is impossible to link a dll without this setting, and
# we shouldn't force the makefile maintainer to figure out
# which system we are compiling for in order to pass an extra
# flag for every libtool invocation.
# allow_undefined=no
# FIXME: Unfortunately, there are problems with the above when trying
# to make a dll which has undefined symbols, in which case not
# even a static library is built. For now, we need to specify
# -no-undefined on the libtool link line when we can be certain
# that all symbols are satisfied, otherwise we get a static library.
allow_undefined=yes
;;
--
ということで、こういう状況の場合libtoolに-no-undefinedを指定する必要
があるようです。
Ref:
http://practical-scheme.net/wiliki/wiliki.cgi?Gauche%3aautomake%2blibtoolize#H-g712ip
lib/Makefile.amのlibkakasi_la_LDFLAGSに-no-undefinedを追加して
automakeを実行し、Makefile.inを再生成させた上でconfigure, makeしたとこ
ろきちんとdllができるようになりました。
--
libkakasi_la_LDFLAGS = \
-version-info 3:0:1 -export-dynamic -no-undefined
--
対応としては、lib/Makefile.amをlib/Makefile.am.inに変更してconfiugre
時にcygwin環境でのみ-no-undefinedを追加するようにする、という方法が考
えられますが、なんとなくもっとよい方法がありそうな気がします。
--
野首 貴嗣
E-mail:
[メールアドレス保護]
[メールアドレス保護] /
[メールアドレス保護]
_______________________________________________
Kakasi-dev mailing list
[email protected]
http://www.namazu.org/cgi-bin/mailman/listinfo/kakasi-dev