From 8d87514b90723e3a997f49afe21bd6c10afbdf12 Mon Sep 17 00:00:00 2001 From: akir Date: Thu, 2 Sep 2004 16:51:54 +0000 Subject: adds -liconv when iconv_close is in libiconv --- configure.in | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/configure.in b/configure.in index cfacf35..545bb98 100644 --- a/configure.in +++ b/configure.in @@ -84,6 +84,17 @@ dnl now check for const char *msg argument in iconv(..) [ AC_MSG_RESULT([yes (non const msg)])], [ AC_DEFINE(HAVE_CONST_ICONV, 1, "iconv") AC_MSG_RESULT([yes (const msg)])]) + +dnl Check if iconv is part of libiconv + AC_CHECK_LIB(iconv, iconv_close, + AC_MSG_CHECKING([for iconv_close in libiconv]) + AC_TRY_LINK( + #include , + [int main() { return iconv_close((iconv_t)(-1)); }], + AC_MSG_RESULT([yes]), + LIBS="$LIBS -liconv" + ) + ) else AC_MSG_RESULT([no]) fi -- cgit v0.11.2