]> code.citadel.org Git - citadel.git/blobdiff - webcit/configure.ac
The external libiconv test in webcit configure was
[citadel.git] / webcit / configure.ac
index 39626b38b8855ef77aed46341608c132d3e874e5..4a84bcadf114df7b7271eff455441aad643deed0 100644 (file)
@@ -1,6 +1,6 @@
 dnl Process this file with autoconf to produce a configure script.
 dnl $Id$
-AC_INIT([WebCit], [7.24], [http://www.citadel.org/])
+AC_INIT([WebCit], [7.30], [http://www.citadel.org/])
 
 AC_SUBST(PROG_SUBDIRS)
 AC_DEFINE(PROG_SUBDIRS, [], [Program dirs])
@@ -118,24 +118,6 @@ AC_CHECK_HEADER(libcitadel.h,
 )
 
 
-dnl Check to see if libcitadel is new enough
-AC_MSG_CHECKING(checking libcitadel version)
-AC_TRY_RUN(
-       [
-#include "webcit.h"
-main() {
-        if (LIBCITADEL_VERSION_NUMBER >= LIBCITADEL_MIN) {
-               return(0);
-       }
-       return(1);
-}
-       ], 
-       AC_MSG_RESULT(ok),
-       AC_MSG_ERROR(libcitadel is too old.  Please upgrade it first.)
-)
-
-
-
 webcit_with_calendar_service=no
 dnl Checks for the libical calendaring library.
 if test "x$with_libical" != xno ; then
@@ -337,25 +319,21 @@ if test "$ok_nls" != "no"; then
        )
 fi
 
-if test "$ok_iconv" = "no"; then
-       LD_FLAGS_BEFORE=$LDFLAGS
-       LDFLAGS="$LDFLAGS -liconv"
-               AC_TRY_RUN([
-                       #include <iconv.h>
-                       main() {
-                              iconv_t ic = (iconv_t)(-1) ;
-                              ic = iconv_open("UTF-8", "us-ascii");
-                              iconv_close(ic);
-                              exit(0);
-                       }
-                       ],
-                       ok_iconv=yes,
-                       ok_iconv=no
+dnl Check for iconv in external libiconv
+if test "$ok_nls" != "no"; then
+       if test "$ok_nls" == "no" ; then
+               AC_MSG_RESULT(Checking for an external libiconv...)
+               AC_CHECK_HEADER(iconv.h,
+                       [
+                               AC_CHECK_LIB(iconv, iconv_open,
+                                       [
+                                               LIBS="-liconv $LIBS"
+                                               ok_iconv=yes
+                                       ]
+                               )
+                       ]
                )
-               if test "$ok_iconv" != "no"; then
-                  LDFLAGS=$LD_FLAGS_BEFORE 
-                  LIBS="$LIBS -liconv"
-               fi
+       fi
 fi
 
 if test "$ok_iconv" != "no"; then
@@ -368,6 +346,7 @@ fi
 
 
 dnl Here is the check for libintl etc.
+AC_CHECK_FUNCS(strftime_l uselocale gettext)
 
 AC_ARG_ENABLE(nls,
        [  --disable-nls           do not use Native Language Support],