summaryrefslogtreecommitdiffstats
path: root/makedat/configure.ac
blob: 440364378c9cefb3f76fcde123e19548c8762998 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
dnl Process this file with autoconf to produce a configure script.
dnl
dnl Copyright 1998 - 2001 Double Precision, Inc.  See COPYING for
dnl distribution information.

AC_INIT(makedat, 0.60, [courier-users@lists.sourceforge.net])

>confdefs.h  # Kill PACKAGE_ macros

AC_CONFIG_SRCDIR(makedatprog.c)
AC_CONFIG_AUX_DIR(../..)
AM_INIT_AUTOMAKE([foreign no-define])
LPATH="$PATH:/usr/local/bin"
AM_CONFIG_HEADER(config.h)

dnl Checks for programs.
AC_PROG_CC
AC_PROG_INSTALL
AC_PROG_LN_S
AC_PATH_PROGS(PERL, perl5 perl, perl, $LPATH)
AC_SUBST(PERL)
AC_PATH_PROGS(CAT, cat, cat)
AC_LIBTOOL_DLOPEN
AM_PROG_LIBTOOL
AC_SYS_LARGEFILE

if test x$GCC = xyes
then
	CFLAGS="-Wall $CFLAGS"
fi
if test x$GXX = xyes
then
	CXXFLAGS="-Wall $CXXFLAGS"
fi

CFLAGS="-I$srcdir/.. -I.. -I$srcdir/../.. -I../.. $CFLAGS"
CXXFLAGS="-I$srcdir/.. -I.. -I$srcdir/../.. -I../.. $CXXFLAGS"

dnl Check whether we should use gdbm, or db.

. ../../dbobj.config
if test "$dblibrary" != ""
then
	dblibrary="../../$dblibrary"
fi
AC_SUBST(dblibrary)

makedatprog_target=""
if test "$dblibrary" != ""
then
	makedatprog_target=makedatprog
fi
AC_SUBST(makedatprog_target)
AC_SUBST(dblibrary)

dnl Checks for header files.
AC_HEADER_STDC
AC_CHECK_HEADERS(unistd.h)

dnl Checks for typedefs, structures, and compiler characteristics.

dnl Checks for library functions.

AC_ARG_WITH(makedatprog,[ --with-makedatprog=filename      Installed location and name of makedatprog], makedatprog="$withval", makedatprog="$bindir/makedatprog")

makedatprogpath="$makedatprog"
AC_SUBST(makedatprogpath)

AC_OUTPUT(Makefile makedat)