| 1 | dnl Process this file with autoconf to produce a configure script. |
| 2 | dnl |
| 3 | dnl Copyright 2004 Double Precision, Inc. See COPYING for |
| 4 | dnl distribution information. |
| 5 | |
| 6 | AC_INIT(courierlogger, 0.10, [courier-users@lists.sourceforge.net]) |
| 7 | |
| 8 | >confdefs.h # Kill PACKAGE_ macros. |
| 9 | LPATH="$PATH:/usr/local/bin" |
| 10 | AC_CONFIG_SRCDIR(logger.c) |
| 11 | AC_CONFIG_AUX_DIR(..) |
| 12 | AM_INIT_AUTOMAKE([foreign no-define]) |
| 13 | AM_CONFIG_HEADER(config.h) |
| 14 | |
| 15 | dnl Checks for programs. |
| 16 | AC_PROG_CC |
| 17 | AC_PROG_INSTALL |
| 18 | AC_PROG_LN_S |
| 19 | AC_PROG_LIBTOOL |
| 20 | |
| 21 | if test x$GCC = xyes |
| 22 | then |
| 23 | CFLAGS="-Wall $CFLAGS" |
| 24 | fi |
| 25 | if test x$GXX = xyes |
| 26 | then |
| 27 | CXXFLAGS="-Wall $CXXFLAGS" |
| 28 | fi |
| 29 | |
| 30 | CFLAGS="-I../libs -I$srcdir/../libs $CFLAGS" |
| 31 | CXXFLAGS="-I../libs -I$srcdir/../libs $CXXFLAGS" |
| 32 | |
| 33 | AC_C_CONST |
| 34 | AC_HEADER_STDC |
| 35 | AC_CHECK_HEADERS(fcntl.h string.h syslog.h) |
| 36 | AC_TYPE_UID_T |
| 37 | AC_SYS_LARGEFILE |
| 38 | AC_CHECK_FUNCS(strchr) |
| 39 | |
| 40 | AC_ARG_WITH(syslog, |
| 41 | AC_HELP_STRING([--with-syslog=XXX],[syslog facility [[MAIL]]]), |
| 42 | logdest="LOG_$withval", logdest="LOG_MAIL") |
| 43 | |
| 44 | AC_DEFINE_UNQUOTED(LOG_DEST, [$logdest], |
| 45 | [ syslog facility ]) |
| 46 | AM_CONDITIONAL(HAVE_SGML, test -d ${srcdir}/../libs/docbook) |
| 47 | AC_OUTPUT(Makefile) |