]> code.citadel.org Git - citadel.git/blobdiff - webcit/configure.in
* Threw away most of the gettextize-generated build system in the po/
[citadel.git] / webcit / configure.in
index b8c6dd3fa743fdcc4f179202a1900c16aa2e5d8a..33679ea87cb1a2770a579040792f909e22361419 100644 (file)
@@ -2,13 +2,22 @@ dnl Process this file with autoconf to produce a configure script.
 dnl $Id$
 AC_INIT(webserver.c)
 
+
+PACKAGE=webcit
+VERSION=6.21
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
+AC_SUBST(PACKAGE)
+AC_SUBST(VERSION)
+
 AC_CANONICAL_HOST
 AC_PROG_INSTALL
+AC_CHECK_PROG(SED, sed, sed, no)
 AC_PREFIX_DEFAULT(/usr/local/webcit)
 
-AC_ARG_WITH(with_libical, [  --with-libical          use libical calendaring library])
-AC_ARG_WITH(with_zlib, [  --with-zlib          use zlib compression if present])
-AC_ARG_WITH(with_newt, [  --with-newt          use newt window library])
+AC_ARG_WITH(with_libical, [  --with-libical      use libical calendaring library])
+AC_ARG_WITH(with_zlib,    [  --with-zlib         use zlib compression if present])
+AC_ARG_WITH(with_newt,    [  --with-newt         use newt window library])
 AC_ARG_WITH(ssl,
        [  --with-ssl=PATH     Specify path to OpenSSL installation ],
        [
@@ -70,6 +79,9 @@ AC_HEADER_STDC
 dnl AC_HEADER_SYS_WAIT
 AC_CHECK_HEADERS(fcntl.h limits.h sys/time.h unistd.h)
 
+
+
+
 dnl Checks for typedefs, structures, and compiler characteristics.
 AC_C_CONST
 AC_TYPE_OFF_T
@@ -96,19 +108,16 @@ if test "x$ok_libical" = xyes ; then
                [
 #include <ical.h>
 main() {
-       float v;
-       int i;
-       sscanf(ICAL_VERSION, "%f", &v);
-       printf("libical version: %0.2f\n", v);
-       v = v * 100.0;
-       i = (int) v;
-       if (i >= 24) {
-               printf("This version is ok.\n");
-               printf("WebCit will be built with calendar support.\n");
+        int major, minor, v;
+        sscanf(ICAL_VERSION, "%d.%d", &major, &minor);
+        v = 100*major + minor;
+        printf("libical version: %i\n", v);
+        if (v >= 24) {
+                printf("This version is ok.\n");
                return(0);
        }
-       printf("libical 0.24 or newer is required.\n");
-       printf("WebCit will be built without calendar support.\n");
+       printf("libical 0.24 or newer required.\n");
+       printf("Citadel will be built without calendar support.\n");
        return(1);
 }
                ], 
@@ -134,7 +143,6 @@ if test "x$ok_zlib" = xyes ; then
         AC_DEFINE(HAVE_ZLIB)
 fi
 
-
 dnl Checks for the newt window library.
 if test "x$with_newt" != xno ; then
        AC_CHECK_HEADERS(newt.h,
@@ -258,9 +266,9 @@ if test "$with_ssl" != "no"; then
        fi
 fi
 
-
+AM_GNU_GETTEXT
 
 AC_SUBST(SETUP_LIBS)
 
-AC_OUTPUT(Makefile)
+AC_OUTPUT(Makefile intl/Makefile po/Makefile.in po/Makefile )