Mercurial > dovecot > core-2.2
annotate configure.in @ 11370:f0141862bdca HEAD
configure: --without-shared-libs should use static liblda for lda/lmtp.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Tue, 25 May 2010 19:52:07 +0100 |
parents | 348eb4754085 |
children | 044589aca7c6 |
rev | line source |
---|---|
3784
beeae4f17615
Cleanups and some more kqueue stuff
Timo Sirainen <tss@iki.fi>
parents:
3783
diff
changeset
|
1 AC_PREREQ([2.59]) |
11274 | 2 AC_INIT([Dovecot],[2.0.beta5],[dovecot@dovecot.org]) |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
3 AC_CONFIG_SRCDIR([src]) |
0 | 4 |
8523
426b356a0708
Use "foreign" automake option so it doesn't complain about missing ChangeLog.
Timo Sirainen <tss@iki.fi>
parents:
8517
diff
changeset
|
5 AM_INIT_AUTOMAKE([foreign]) |
0 | 6 |
7 AM_MAINTAINER_MODE | |
8 | |
10754
c5cbc99f4627
configure: Set ACLOCAL_AMFLAGS so make finds dovecot.m4.
Timo Sirainen <tss@iki.fi>
parents:
10753
diff
changeset
|
9 ACLOCAL_AMFLAGS='-I $(top_srcdir)' |
c5cbc99f4627
configure: Set ACLOCAL_AMFLAGS so make finds dovecot.m4.
Timo Sirainen <tss@iki.fi>
parents:
10753
diff
changeset
|
10 AC_SUBST(ACLOCAL_AMFLAGS) |
c5cbc99f4627
configure: Set ACLOCAL_AMFLAGS so make finds dovecot.m4.
Timo Sirainen <tss@iki.fi>
parents:
10753
diff
changeset
|
11 |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
12 dnl TEST_WITH(name, value, [plugin]) |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
13 AC_DEFUN([TEST_WITH], [ |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
14 want=want_`echo $1|sed s/-/_/g` |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
15 if test $2 = yes || test $2 = no || test $2 = auto; then |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
16 eval $want=$2 |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
17 elif test $2 = plugin; then |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
18 if test "$3" = plugin; then |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
19 eval $want=plugin |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
20 else |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
21 AC_ERROR([--with-$1=plugin not supported]) |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
22 fi |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
23 elif `echo $2|grep '^/' >/dev/null`; then |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
24 AC_ERROR([--with-$1=path not supported. You may want to use instead: |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
25 CPPFLAGS=-I$2/include LDFLAGS=-L$2/lib ./configure --with-$1]) |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
26 else |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
27 AC_ERROR([--with-$1: Unknown value: $2]) |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
28 fi |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
29 ]) |
0 | 30 |
7929
55d1a2bf4573
Renamed --enable-debug to --enable-devel-checks, which describes it better.
Timo Sirainen <tss@iki.fi>
parents:
7924
diff
changeset
|
31 AC_ARG_ENABLE(devel-checks, |
55d1a2bf4573
Renamed --enable-debug to --enable-devel-checks, which describes it better.
Timo Sirainen <tss@iki.fi>
parents:
7924
diff
changeset
|
32 [ --enable-devel-checks Enable some extra expensive checks for developers], |
544
42e65c2ba49d
Added --enable-debug. Currently it just forces file locks so that index
Timo Sirainen <tss@iki.fi>
parents:
530
diff
changeset
|
33 if test x$enableval = xyes; then |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
34 AC_DEFINE(DEBUG,, Build with extra debugging checks) |
544
42e65c2ba49d
Added --enable-debug. Currently it just forces file locks so that index
Timo Sirainen <tss@iki.fi>
parents:
530
diff
changeset
|
35 fi) |
42e65c2ba49d
Added --enable-debug. Currently it just forces file locks so that index
Timo Sirainen <tss@iki.fi>
parents:
530
diff
changeset
|
36 |
546
e1254b838e0b
Added --enable-asserts (default) and fixed some warnings when building
Timo Sirainen <tss@iki.fi>
parents:
544
diff
changeset
|
37 AC_ARG_ENABLE(asserts, |
e1254b838e0b
Added --enable-asserts (default) and fixed some warnings when building
Timo Sirainen <tss@iki.fi>
parents:
544
diff
changeset
|
38 [ --enable-asserts Enable asserts (default)], |
4057
f4807accc1d5
Unbreak last accidental change..
Timo Sirainen <tss@iki.fi>
parents:
4055
diff
changeset
|
39 if test x$enableval = xno; then |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
40 AC_DEFINE(DISABLE_ASSERTS,, Disable asserts) |
546
e1254b838e0b
Added --enable-asserts (default) and fixed some warnings when building
Timo Sirainen <tss@iki.fi>
parents:
544
diff
changeset
|
41 fi) |
e1254b838e0b
Added --enable-asserts (default) and fixed some warnings when building
Timo Sirainen <tss@iki.fi>
parents:
544
diff
changeset
|
42 |
9104
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
43 AC_ARG_WITH(shared-libs, |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
44 [ --with-shared-libs Link binaries using shared Dovecot libraries (default)], |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
45 want_shared_libs=$withval, |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
46 want_shared_libs=yes) |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
47 AM_CONDITIONAL(BUILD_SHARED_LIBS, test "$want_shared_libs" = "yes") |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
48 |
439
b66ccecbc8a6
Added --with-mem-align=BYTES option
Timo Sirainen <tss@iki.fi>
parents:
426
diff
changeset
|
49 AC_ARG_WITH(mem-align, |
1394
059f13d577bb
Use separate index alignment from memory alignment. We don't use pointers in
Timo Sirainen <tss@iki.fi>
parents:
1389
diff
changeset
|
50 [ --with-mem-align=BYTES Set the memory alignment (default: 8)], |
439
b66ccecbc8a6
Added --with-mem-align=BYTES option
Timo Sirainen <tss@iki.fi>
parents:
426
diff
changeset
|
51 mem_align=$withval, |
b66ccecbc8a6
Added --with-mem-align=BYTES option
Timo Sirainen <tss@iki.fi>
parents:
426
diff
changeset
|
52 mem_align=8) |
b66ccecbc8a6
Added --with-mem-align=BYTES option
Timo Sirainen <tss@iki.fi>
parents:
426
diff
changeset
|
53 |
2569
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
54 AC_ARG_WITH(ioloop, |
3784
beeae4f17615
Cleanups and some more kqueue stuff
Timo Sirainen <tss@iki.fi>
parents:
3783
diff
changeset
|
55 [ --with-ioloop=IOLOOP Specify the I/O loop method to use |
4482
f60b07bd5fa7
--with-ioloop=auto changed to --with-ioloop=best
Timo Sirainen <tss@iki.fi>
parents:
4478
diff
changeset
|
56 (epoll, kqueue, poll; best for the fastest available; |
7268
80cd999d5623
Changed the default ioloop to "best".
Timo Sirainen <tss@iki.fi>
parents:
7264
diff
changeset
|
57 default is best)], |
2569
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
58 ioloop=$withval, |
7268
80cd999d5623
Changed the default ioloop to "best".
Timo Sirainen <tss@iki.fi>
parents:
7264
diff
changeset
|
59 ioloop=best) |
2569
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
60 |
3482
465c465c66be
Added inotify patch by Johannes Berg and did some restructuring to
Timo Sirainen <tss@iki.fi>
parents:
3452
diff
changeset
|
61 AC_ARG_WITH(notify, |
4551
2643a46322a6
Updated --with-notify description.
Timo Sirainen <tss@iki.fi>
parents:
4530
diff
changeset
|
62 [ --with-notify=NOTIFY Specify the file system notification method to use |
2643a46322a6
Updated --with-notify description.
Timo Sirainen <tss@iki.fi>
parents:
4530
diff
changeset
|
63 (inotify, kqueue, dnotify, none; |
2643a46322a6
Updated --with-notify description.
Timo Sirainen <tss@iki.fi>
parents:
4530
diff
changeset
|
64 default is detected in the above order)], |
3482
465c465c66be
Added inotify patch by Johannes Berg and did some restructuring to
Timo Sirainen <tss@iki.fi>
parents:
3452
diff
changeset
|
65 notify=$withval, |
465c465c66be
Added inotify patch by Johannes Berg and did some restructuring to
Timo Sirainen <tss@iki.fi>
parents:
3452
diff
changeset
|
66 notify=) |
465c465c66be
Added inotify patch by Johannes Berg and did some restructuring to
Timo Sirainen <tss@iki.fi>
parents:
3452
diff
changeset
|
67 |
6111
c83546491bad
--with-passwd was used also for --with-nss
Timo Sirainen <tss@iki.fi>
parents:
6106
diff
changeset
|
68 AC_ARG_WITH(nss, |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
69 [ --with-nss Build with NSS module support (auto)], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
70 TEST_WITH(nss, $withval), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
71 want_nss=auto) |
5870
c9b49ed99d28
Added userdb nss which currently supports glibc-compatible NSS modules.
Timo Sirainen <tss@iki.fi>
parents:
5859
diff
changeset
|
72 |
328
a0abed892d11
s/--enable/--with/ to all auth modules. added --with-file-offset-size=BITS
Timo Sirainen <tss@iki.fi>
parents:
313
diff
changeset
|
73 AC_ARG_WITH(shadow, |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
74 [ --with-shadow Build with shadow password support (auto)], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
75 TEST_WITH(shadow, $withval), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
76 want_shadow=auto) |
0 | 77 |
328
a0abed892d11
s/--enable/--with/ to all auth modules. added --with-file-offset-size=BITS
Timo Sirainen <tss@iki.fi>
parents:
313
diff
changeset
|
78 AC_ARG_WITH(pam, |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
79 [ --with-pam Build with PAM support (auto)], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
80 TEST_WITH(pam, $withval), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
81 want_pam=auto) |
0 | 82 |
1851
d66d53f57e43
Added bsdauth support, patch by Dan Cross
Timo Sirainen <tss@iki.fi>
parents:
1849
diff
changeset
|
83 AC_ARG_WITH(bsdauth, |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
84 [ --with-bsdauth Build with BSD authentication support (auto)], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
85 TEST_WITH(bsdauth, $withval), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
86 want_bsdauth=auto) |
1851
d66d53f57e43
Added bsdauth support, patch by Dan Cross
Timo Sirainen <tss@iki.fi>
parents:
1849
diff
changeset
|
87 |
3683
28cca6317829
Added GSSAPI support. Patch by Jelmer Vernooij and some fixes by
Timo Sirainen <tss@iki.fi>
parents:
3671
diff
changeset
|
88 AC_ARG_WITH(gssapi, |
6259
f2b00d3996df
Updated --with-gssapi help string to include yes|plugin.
Timo Sirainen <tss@iki.fi>
parents:
6232
diff
changeset
|
89 [ --with-gssapi=yes|plugin Build with GSSAPI authentication support], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
90 TEST_WITH(gssapi, $withval, plugin), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
91 want_gssapi=no) |
3683
28cca6317829
Added GSSAPI support. Patch by Jelmer Vernooij and some fixes by
Timo Sirainen <tss@iki.fi>
parents:
3671
diff
changeset
|
92 |
4638
689a02ca02d3
Tru64 SIA authentication support. Patch by Simon L Jackson
Timo Sirainen <tss@iki.fi>
parents:
4621
diff
changeset
|
93 AC_ARG_WITH(sia, |
689a02ca02d3
Tru64 SIA authentication support. Patch by Simon L Jackson
Timo Sirainen <tss@iki.fi>
parents:
4621
diff
changeset
|
94 [ --with-sia Build with Tru64 SIA support], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
95 TEST_WITH(sia, $withval), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
96 want_sia=no) |
4638
689a02ca02d3
Tru64 SIA authentication support. Patch by Simon L Jackson
Timo Sirainen <tss@iki.fi>
parents:
4621
diff
changeset
|
97 |
1057
c5ab972db48c
libldap checks, --without-pop3 disables pop3 server
Timo Sirainen <tss@iki.fi>
parents:
1049
diff
changeset
|
98 AC_ARG_WITH(ldap, |
6198
4f6c4aeafafb
--with-ldap=plugin builds LDAP passdb and userdb support as a plugin.
Timo Sirainen <tss@iki.fi>
parents:
6196
diff
changeset
|
99 [ --with-ldap=yes|plugin Build with LDAP support], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
100 TEST_WITH(ldap, $withval, plugin), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
101 want_ldap=no) |
1057
c5ab972db48c
libldap checks, --without-pop3 disables pop3 server
Timo Sirainen <tss@iki.fi>
parents:
1049
diff
changeset
|
102 |
280
fa2d1a1d025e
vpopmail authentication. compiles, not tested if it really works.
Timo Sirainen <tss@iki.fi>
parents:
247
diff
changeset
|
103 AC_ARG_WITH(vpopmail, |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
104 [ --with-vpopmail Build with vpopmail support (auto)], |
280
fa2d1a1d025e
vpopmail authentication. compiles, not tested if it really works.
Timo Sirainen <tss@iki.fi>
parents:
247
diff
changeset
|
105 if test x$withval = xno; then |
fa2d1a1d025e
vpopmail authentication. compiles, not tested if it really works.
Timo Sirainen <tss@iki.fi>
parents:
247
diff
changeset
|
106 want_vpopmail=no |
fa2d1a1d025e
vpopmail authentication. compiles, not tested if it really works.
Timo Sirainen <tss@iki.fi>
parents:
247
diff
changeset
|
107 else |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
108 if test x$withval = xyes || test x$withval = xauto; then |
5035
80f0ee36e905
Allow --with-vpopmail=path specify the vpopmail_home path.
Timo Sirainen <tss@iki.fi>
parents:
5034
diff
changeset
|
109 vpopmail_home="`echo ~vpopmail`" |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
110 want_vpopmail=$withval |
5035
80f0ee36e905
Allow --with-vpopmail=path specify the vpopmail_home path.
Timo Sirainen <tss@iki.fi>
parents:
5034
diff
changeset
|
111 else |
80f0ee36e905
Allow --with-vpopmail=path specify the vpopmail_home path.
Timo Sirainen <tss@iki.fi>
parents:
5034
diff
changeset
|
112 vpopmail_home="$withval" |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
113 want_vpopmail=yes |
5035
80f0ee36e905
Allow --with-vpopmail=path specify the vpopmail_home path.
Timo Sirainen <tss@iki.fi>
parents:
5034
diff
changeset
|
114 fi |
80f0ee36e905
Allow --with-vpopmail=path specify the vpopmail_home path.
Timo Sirainen <tss@iki.fi>
parents:
5034
diff
changeset
|
115 fi, [ |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
116 want_vpopmail=auto |
5035
80f0ee36e905
Allow --with-vpopmail=path specify the vpopmail_home path.
Timo Sirainen <tss@iki.fi>
parents:
5034
diff
changeset
|
117 vpopmail_home="`echo ~vpopmail`" |
80f0ee36e905
Allow --with-vpopmail=path specify the vpopmail_home path.
Timo Sirainen <tss@iki.fi>
parents:
5034
diff
changeset
|
118 ]) |
280
fa2d1a1d025e
vpopmail authentication. compiles, not tested if it really works.
Timo Sirainen <tss@iki.fi>
parents:
247
diff
changeset
|
119 |
10581
6ecb1b7528c9
Disabled Berkeley DB support until someone fixes it.
Timo Sirainen <tss@iki.fi>
parents:
10567
diff
changeset
|
120 # Berkeley DB support is more or less broken. Disabled for now. |
6ecb1b7528c9
Disabled Berkeley DB support until someone fixes it.
Timo Sirainen <tss@iki.fi>
parents:
10567
diff
changeset
|
121 #AC_ARG_WITH(db, |
6ecb1b7528c9
Disabled Berkeley DB support until someone fixes it.
Timo Sirainen <tss@iki.fi>
parents:
10567
diff
changeset
|
122 #[ --with-db Build with Berkeley DB support], |
6ecb1b7528c9
Disabled Berkeley DB support until someone fixes it.
Timo Sirainen <tss@iki.fi>
parents:
10567
diff
changeset
|
123 # TEST_WITH(db, $withval), |
6ecb1b7528c9
Disabled Berkeley DB support until someone fixes it.
Timo Sirainen <tss@iki.fi>
parents:
10567
diff
changeset
|
124 # want_db=no) |
10600
20963e8ec560
configure: Another try at fixing Berkeley DB check to not give an error.
Timo Sirainen <tss@iki.fi>
parents:
10598
diff
changeset
|
125 want_db=no |
4517
e661182eab75
Berkeley DB dict support is now enabled only when using --with-db configure option.
Timo Sirainen <timo.sirainen@movial.fi>
parents:
4482
diff
changeset
|
126 |
4013
bf0357107349
Added --with-sql option to build with SQL userdb/passdb but without any
Timo Sirainen <tss@iki.fi>
parents:
4012
diff
changeset
|
127 dnl The --with-sql is useful only if Dovecot is being built with all the SQL |
bf0357107349
Added --with-sql option to build with SQL userdb/passdb but without any
Timo Sirainen <tss@iki.fi>
parents:
4012
diff
changeset
|
128 dnl drivers as modules. If any SQL driver is built-in, this option is ignored. |
bf0357107349
Added --with-sql option to build with SQL userdb/passdb but without any
Timo Sirainen <tss@iki.fi>
parents:
4012
diff
changeset
|
129 AC_ARG_WITH(sql, |
6196
17fdcb09159b
Updated --with-sql help string.
Timo Sirainen <tss@iki.fi>
parents:
6195
diff
changeset
|
130 [ --with-sql=yes|plugin Build with generic SQL support], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
131 TEST_WITH(sql, $withval, plugin), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
132 want_sql=no) |
4013
bf0357107349
Added --with-sql option to build with SQL userdb/passdb but without any
Timo Sirainen <tss@iki.fi>
parents:
4012
diff
changeset
|
133 |
1283
2d8af547a8b4
Added PostgreSQL support, patch by Alex Howansky
Timo Sirainen <tss@iki.fi>
parents:
1256
diff
changeset
|
134 AC_ARG_WITH(pgsql, |
4013
bf0357107349
Added --with-sql option to build with SQL userdb/passdb but without any
Timo Sirainen <tss@iki.fi>
parents:
4012
diff
changeset
|
135 [ --with-pgsql Build with PostgreSQL driver support], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
136 TEST_WITH(pgsql, $withval), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
137 want_pgsql=no) |
1283
2d8af547a8b4
Added PostgreSQL support, patch by Alex Howansky
Timo Sirainen <tss@iki.fi>
parents:
1256
diff
changeset
|
138 |
1995
cc64f8bb4716
MySQL authentication patch by Matther Reimer
Timo Sirainen <tss@iki.fi>
parents:
1990
diff
changeset
|
139 AC_ARG_WITH(mysql, |
4013
bf0357107349
Added --with-sql option to build with SQL userdb/passdb but without any
Timo Sirainen <tss@iki.fi>
parents:
4012
diff
changeset
|
140 [ --with-mysql Build with MySQL driver support], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
141 TEST_WITH(mysql, $withval), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
142 want_mysql=no) |
1995
cc64f8bb4716
MySQL authentication patch by Matther Reimer
Timo Sirainen <tss@iki.fi>
parents:
1990
diff
changeset
|
143 |
3919
b967ffb7e3a6
SQLite support. Patch by Jakob Hirsch.
Timo Sirainen <tss@iki.fi>
parents:
3904
diff
changeset
|
144 AC_ARG_WITH(sqlite, |
4348
2dc5f48ff4ee
Whitespace cleanup for --help. Don't enable GSSAPI support by default.
Timo Sirainen <tss@iki.fi>
parents:
4343
diff
changeset
|
145 [ --with-sqlite Build with SQLite3 driver support], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
146 TEST_WITH(sqlite, $withval), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
147 want_sqlite=no) |
3919
b967ffb7e3a6
SQLite support. Patch by Jakob Hirsch.
Timo Sirainen <tss@iki.fi>
parents:
3904
diff
changeset
|
148 |
4621
446646de0c4a
--with-lucene now enables lucene full text search indexing. Note that using
Timo Sirainen <tss@iki.fi>
parents:
4609
diff
changeset
|
149 AC_ARG_WITH(lucene, |
446646de0c4a
--with-lucene now enables lucene full text search indexing. Note that using
Timo Sirainen <tss@iki.fi>
parents:
4609
diff
changeset
|
150 [ --with-lucene Build with CLucene full text search support], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
151 TEST_WITH(lucene, $withval), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
152 want_lucene=no) |
10882
3ebd6a4ad55a
configure: --with-lucene fails now with suggestion to use Solr instead.
Timo Sirainen <tss@iki.fi>
parents:
10798
diff
changeset
|
153 if test "$want_lucene" = "yes"; then |
3ebd6a4ad55a
configure: --with-lucene fails now with suggestion to use Solr instead.
Timo Sirainen <tss@iki.fi>
parents:
10798
diff
changeset
|
154 AC_ERROR([CLucene support isn't working very well. Use Solr instead.]) |
3ebd6a4ad55a
configure: --with-lucene fails now with suggestion to use Solr instead.
Timo Sirainen <tss@iki.fi>
parents:
10798
diff
changeset
|
155 fi |
4621
446646de0c4a
--with-lucene now enables lucene full text search indexing. Note that using
Timo Sirainen <tss@iki.fi>
parents:
4609
diff
changeset
|
156 AM_CONDITIONAL(BUILD_LUCENE, test "$want_lucene" = "yes") |
446646de0c4a
--with-lucene now enables lucene full text search indexing. Note that using
Timo Sirainen <tss@iki.fi>
parents:
4609
diff
changeset
|
157 |
7990
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
158 AC_ARG_WITH(solr, |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
159 [ --with-solr Build with Solr full text search support], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
160 TEST_WITH(solr, $withval), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
161 want_solr=no) |
7990
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
162 |
8090
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
163 AC_ARG_WITH(zlib, |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
164 [ --with-zlib Build with zlib compression support], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
165 TEST_WITH(zlib, $withval), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
166 want_zlib=auto) |
8090
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
167 |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
168 AC_ARG_WITH(bzlib, |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
169 [ --with-bzlib Build with bzlib compression support], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
170 TEST_WITH(bzlib, $withval), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
171 want_bzlib=auto) |
8090
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
172 |
9538
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
173 AC_ARG_WITH(libcap, |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
174 [ --with-libcap Build with libcap support (Dropping capabilities).], |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
175 TEST_WITH(libcap, $withval), |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
176 want_libcap=auto) |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
177 |
10647
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
178 AC_ARG_WITH(libwrap, |
11006
864b17ec5fac
configure: Minor description fix to previous change.
Timo Sirainen <tss@iki.fi>
parents:
11005
diff
changeset
|
179 [ --with-libwrap Build with libwrap, ie. TCP-wrappers], |
10647
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
180 TEST_WITH(libwrap, $withval), |
11005
51150f2b3be8
configure: Disabled tcp-wrappers by default.
Timo Sirainen <tss@iki.fi>
parents:
10994
diff
changeset
|
181 want_libwrap=no) |
10647
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
182 |
622 | 183 AC_ARG_WITH(ssl, |
6196
17fdcb09159b
Updated --with-sql help string.
Timo Sirainen <tss@iki.fi>
parents:
6195
diff
changeset
|
184 [ --with-ssl=gnutls|openssl Build with GNUTLS or OpenSSL (default)], |
245 | 185 if test x$withval = xno; then |
244 | 186 want_gnutls=no |
622 | 187 want_openssl=no |
188 elif test x$withval = xgnutls; then | |
189 want_gnutls=yes | |
190 want_openssl=no | |
191 elif test x$withval = xopenssl; then | |
192 want_gnutls=no | |
193 want_openssl=yes | |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
194 elif test x$withval = xyes; then |
3004
60a172e62d11
Don't use GNUTLS unless explicitly specified. It's not working currently
Timo Sirainen <tss@iki.fi>
parents:
3002
diff
changeset
|
195 want_gnutls=no |
622 | 196 want_openssl=yes |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
197 else |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
198 AC_ERROR([--with-ssl: Invalid value: $withval]) |
622 | 199 fi, [ |
3004
60a172e62d11
Don't use GNUTLS unless explicitly specified. It's not working currently
Timo Sirainen <tss@iki.fi>
parents:
3002
diff
changeset
|
200 want_gnutls=no |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
201 want_openssl=auto |
622 | 202 ]) |
244 | 203 |
657
85a888d2766e
Added script to easily generate self-signed certificate.
Timo Sirainen <tss@iki.fi>
parents:
654
diff
changeset
|
204 AC_ARG_WITH(ssldir, |
85a888d2766e
Added script to easily generate self-signed certificate.
Timo Sirainen <tss@iki.fi>
parents:
654
diff
changeset
|
205 [ --with-ssldir=DIR SSL base directory for certificates (/etc/ssl)], |
85a888d2766e
Added script to easily generate self-signed certificate.
Timo Sirainen <tss@iki.fi>
parents:
654
diff
changeset
|
206 ssldir="$withval", |
85a888d2766e
Added script to easily generate self-signed certificate.
Timo Sirainen <tss@iki.fi>
parents:
654
diff
changeset
|
207 ssldir=/etc/ssl |
85a888d2766e
Added script to easily generate self-signed certificate.
Timo Sirainen <tss@iki.fi>
parents:
654
diff
changeset
|
208 ) |
712
385f862a4005
--with-ssldir actually didn't do anything, and the default directory for
Timo Sirainen <tss@iki.fi>
parents:
711
diff
changeset
|
209 AC_SUBST(ssldir) |
657
85a888d2766e
Added script to easily generate self-signed certificate.
Timo Sirainen <tss@iki.fi>
parents:
654
diff
changeset
|
210 |
3327
ce0733b39311
Added --with-rundir configure option.
Timo Sirainen <tss@iki.fi>
parents:
3284
diff
changeset
|
211 AC_ARG_WITH(rundir, |
ce0733b39311
Added --with-rundir configure option.
Timo Sirainen <tss@iki.fi>
parents:
3284
diff
changeset
|
212 [ --with-rundir=DIR Runtime data directory (LOCALSTATEDIR/run/dovecot)], |
ce0733b39311
Added --with-rundir configure option.
Timo Sirainen <tss@iki.fi>
parents:
3284
diff
changeset
|
213 rundir="$withval", |
7914
5061533382be
Uppercased PACKAGE_NAME macro and started using it in some places.
Timo Sirainen <tss@iki.fi>
parents:
7902
diff
changeset
|
214 rundir=$localstatedir/run/$PACKAGE |
3327
ce0733b39311
Added --with-rundir configure option.
Timo Sirainen <tss@iki.fi>
parents:
3284
diff
changeset
|
215 ) |
ce0733b39311
Added --with-rundir configure option.
Timo Sirainen <tss@iki.fi>
parents:
3284
diff
changeset
|
216 AC_SUBST(rundir) |
ce0733b39311
Added --with-rundir configure option.
Timo Sirainen <tss@iki.fi>
parents:
3284
diff
changeset
|
217 |
4407
2e4857a2b858
Added --with-statedir configure option which defaults to
Timo Sirainen <tss@iki.fi>
parents:
4387
diff
changeset
|
218 AC_ARG_WITH(statedir, |
2e4857a2b858
Added --with-statedir configure option which defaults to
Timo Sirainen <tss@iki.fi>
parents:
4387
diff
changeset
|
219 [ --with-statedir=DIR Permanent data directory (LOCALSTATEDIR/lib/dovecot)], |
2e4857a2b858
Added --with-statedir configure option which defaults to
Timo Sirainen <tss@iki.fi>
parents:
4387
diff
changeset
|
220 statedir="$withval", |
7914
5061533382be
Uppercased PACKAGE_NAME macro and started using it in some places.
Timo Sirainen <tss@iki.fi>
parents:
7902
diff
changeset
|
221 statedir=$localstatedir/lib/$PACKAGE |
4407
2e4857a2b858
Added --with-statedir configure option which defaults to
Timo Sirainen <tss@iki.fi>
parents:
4387
diff
changeset
|
222 ) |
2e4857a2b858
Added --with-statedir configure option which defaults to
Timo Sirainen <tss@iki.fi>
parents:
4387
diff
changeset
|
223 AC_SUBST(statedir) |
2e4857a2b858
Added --with-statedir configure option which defaults to
Timo Sirainen <tss@iki.fi>
parents:
4387
diff
changeset
|
224 |
1786
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
225 AC_ARG_WITH(gc, |
4599
ab77182ddf94
Boehm GC seems to be working now. Removed the broken-warning.
Timo Sirainen <tss@iki.fi>
parents:
4572
diff
changeset
|
226 [ --with-gc Use Boehm garbage collector], |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
227 TEST_WITH(gc, $withval), |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
228 want_gc=no) |
1786
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
229 |
1404
54015ae11177
--with-storage=maildir,mbox can now be used to compile in only the wanted
Timo Sirainen <tss@iki.fi>
parents:
1403
diff
changeset
|
230 AC_ARG_WITH(storages, |
6894
84bcf1c8b07a
Updated list of available mail storage formats. Changed deliver's internal
Timo Sirainen <tss@iki.fi>
parents:
6860
diff
changeset
|
231 [ --with-storages Build with specified mail storage formats |
9977
0bb321c347ae
Split dbox (single-dbox) and mdbox (multi-dbox) into separate storage backends.
Timo Sirainen <tss@iki.fi>
parents:
9973
diff
changeset
|
232 (maildir mbox dbox mdbox cydir)], [ |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
233 if test "$withval" = "yes" || test "$withval" = "no"; then |
4005
450ee12c2e26
Give error if --with-storages or --without-storages is used without
Timo Sirainen <tss@iki.fi>
parents:
3997
diff
changeset
|
234 AC_MSG_ERROR([--with-storages needs storage list as parameter]) |
450ee12c2e26
Give error if --with-storages or --without-storages is used without
Timo Sirainen <tss@iki.fi>
parents:
3997
diff
changeset
|
235 fi |
8398
d331b8fc8ba8
configure: Previous change broke shared storage completely.
Timo Sirainen <tss@iki.fi>
parents:
8392
diff
changeset
|
236 mail_storages="shared `echo "$withval"|sed 's/,/ /g'`" ], |
9977
0bb321c347ae
Split dbox (single-dbox) and mdbox (multi-dbox) into separate storage backends.
Timo Sirainen <tss@iki.fi>
parents:
9973
diff
changeset
|
237 mail_storages="shared maildir mbox dbox mdbox cydir") |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
238 AC_SUBST(mail_storages) |
1404
54015ae11177
--with-storage=maildir,mbox can now be used to compile in only the wanted
Timo Sirainen <tss@iki.fi>
parents:
1403
diff
changeset
|
239 |
2070
0c8f884d1648
Added --with-moduledir configure option
Timo Sirainen <tss@iki.fi>
parents:
2036
diff
changeset
|
240 AC_ARG_WITH(moduledir, |
0c8f884d1648
Added --with-moduledir configure option
Timo Sirainen <tss@iki.fi>
parents:
2036
diff
changeset
|
241 [ --with-moduledir=DIR Base directory for dynamically loadable modules], |
0c8f884d1648
Added --with-moduledir configure option
Timo Sirainen <tss@iki.fi>
parents:
2036
diff
changeset
|
242 moduledir="$withval", |
0c8f884d1648
Added --with-moduledir configure option
Timo Sirainen <tss@iki.fi>
parents:
2036
diff
changeset
|
243 moduledir=$libdir/dovecot |
0c8f884d1648
Added --with-moduledir configure option
Timo Sirainen <tss@iki.fi>
parents:
2036
diff
changeset
|
244 ) |
0c8f884d1648
Added --with-moduledir configure option
Timo Sirainen <tss@iki.fi>
parents:
2036
diff
changeset
|
245 AC_SUBST(moduledir) |
0c8f884d1648
Added --with-moduledir configure option
Timo Sirainen <tss@iki.fi>
parents:
2036
diff
changeset
|
246 |
3779
e87a8db60d25
Added --with-docs parameter to specify if documentation should be installed.
Timo Sirainen <tss@iki.fi>
parents:
3762
diff
changeset
|
247 AC_ARG_WITH(docs, |
4348
2dc5f48ff4ee
Whitespace cleanup for --help. Don't enable GSSAPI support by default.
Timo Sirainen <tss@iki.fi>
parents:
4343
diff
changeset
|
248 [ --with-docs Install documentation (default)], |
3779
e87a8db60d25
Added --with-docs parameter to specify if documentation should be installed.
Timo Sirainen <tss@iki.fi>
parents:
3762
diff
changeset
|
249 if test x$withval = xno; then |
e87a8db60d25
Added --with-docs parameter to specify if documentation should be installed.
Timo Sirainen <tss@iki.fi>
parents:
3762
diff
changeset
|
250 want_docs=no |
e87a8db60d25
Added --with-docs parameter to specify if documentation should be installed.
Timo Sirainen <tss@iki.fi>
parents:
3762
diff
changeset
|
251 else |
e87a8db60d25
Added --with-docs parameter to specify if documentation should be installed.
Timo Sirainen <tss@iki.fi>
parents:
3762
diff
changeset
|
252 want_docs=yes |
e87a8db60d25
Added --with-docs parameter to specify if documentation should be installed.
Timo Sirainen <tss@iki.fi>
parents:
3762
diff
changeset
|
253 fi, |
e87a8db60d25
Added --with-docs parameter to specify if documentation should be installed.
Timo Sirainen <tss@iki.fi>
parents:
3762
diff
changeset
|
254 want_docs=yes) |
e87a8db60d25
Added --with-docs parameter to specify if documentation should be installed.
Timo Sirainen <tss@iki.fi>
parents:
3762
diff
changeset
|
255 AM_CONDITIONAL(BUILD_DOCS, test "$want_docs" = "yes") |
e87a8db60d25
Added --with-docs parameter to specify if documentation should be installed.
Timo Sirainen <tss@iki.fi>
parents:
3762
diff
changeset
|
256 |
9158
69aa6e878a59
configure: Removed --with-* parameters for passdbs/userdbs that don't require external libraries.
Timo Sirainen <tss@iki.fi>
parents:
9157
diff
changeset
|
257 dnl always enable all of the passbs and userdbs that don't require extra libs |
69aa6e878a59
configure: Removed --with-* parameters for passdbs/userdbs that don't require external libraries.
Timo Sirainen <tss@iki.fi>
parents:
9157
diff
changeset
|
258 want_passwd=yes |
69aa6e878a59
configure: Removed --with-* parameters for passdbs/userdbs that don't require external libraries.
Timo Sirainen <tss@iki.fi>
parents:
9157
diff
changeset
|
259 want_passwd_file=yes |
69aa6e878a59
configure: Removed --with-* parameters for passdbs/userdbs that don't require external libraries.
Timo Sirainen <tss@iki.fi>
parents:
9157
diff
changeset
|
260 want_checkpassword=yes |
69aa6e878a59
configure: Removed --with-* parameters for passdbs/userdbs that don't require external libraries.
Timo Sirainen <tss@iki.fi>
parents:
9157
diff
changeset
|
261 want_static_userdb=yes |
69aa6e878a59
configure: Removed --with-* parameters for passdbs/userdbs that don't require external libraries.
Timo Sirainen <tss@iki.fi>
parents:
9157
diff
changeset
|
262 want_prefetch_userdb=yes |
69aa6e878a59
configure: Removed --with-* parameters for passdbs/userdbs that don't require external libraries.
Timo Sirainen <tss@iki.fi>
parents:
9157
diff
changeset
|
263 |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
264 AC_ISC_POSIX |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
265 AC_PROG_CC |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
266 AC_PROG_CPP |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
267 AC_PROG_CXX # lucene plugin needs this |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
268 AC_HEADER_STDC |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
269 AC_C_INLINE |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
270 AC_PROG_LIBTOOL |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
271 AM_ICONV |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
272 |
10645
928312d6017c
config.h: Added DOVECOT_* macros for PACKAGE_* macros.
Timo Sirainen <tss@iki.fi>
parents:
10619
diff
changeset
|
273 AC_DEFINE_UNQUOTED(DOVECOT_NAME, "$PACKAGE_NAME", Dovecot name) |
928312d6017c
config.h: Added DOVECOT_* macros for PACKAGE_* macros.
Timo Sirainen <tss@iki.fi>
parents:
10619
diff
changeset
|
274 AC_DEFINE_UNQUOTED(DOVECOT_STRING, "$PACKAGE_STRING", Dovecot string) |
928312d6017c
config.h: Added DOVECOT_* macros for PACKAGE_* macros.
Timo Sirainen <tss@iki.fi>
parents:
10619
diff
changeset
|
275 AC_DEFINE_UNQUOTED(DOVECOT_VERSION, "$PACKAGE_VERSION", Dovecot version) |
928312d6017c
config.h: Added DOVECOT_* macros for PACKAGE_* macros.
Timo Sirainen <tss@iki.fi>
parents:
10619
diff
changeset
|
276 |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
277 AC_CHECK_HEADERS(strings.h stdint.h unistd.h dirent.h malloc.h inttypes.h \ |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
278 sys/uio.h sys/sysmacros.h sys/resource.h sys/select.h libgen.h \ |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
279 sys/quota.h sys/fs/ufs_quota.h ufs/ufs/quota.h jfs/quota.h sys/fs/quota_common.h \ |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
280 mntent.h sys/mnttab.h sys/event.h sys/time.h sys/mkdev.h linux/dqblk_xfs.h \ |
9656
dc6d35b51b68
configure: Check sasl.h existence only when using --with-ldap.
Timo Sirainen <tss@iki.fi>
parents:
9655
diff
changeset
|
281 xfs/xqm.h execinfo.h ucontext.h malloc_np.h sys/utsname.h sys/vmount.h \ |
9669
6cc6913fee1c
dovecot.conf: Added support for !include globs.
Timo Sirainen <tss@iki.fi>
parents:
9656
diff
changeset
|
282 sys/utsname.h glob.h) |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
283 |
691
567f5e66c7b8
We compile now if dev_t is a structure (eg. glibc+tcc).
Timo Sirainen <tss@iki.fi>
parents:
679
diff
changeset
|
284 dnl * gcc specific options |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
285 if test "x$ac_cv_c_compiler_gnu" = "xyes"; then |
4826
53ff1a59cdd5
Enable -Wstrict-aliasing=2 with gcc 4.
Timo Sirainen <tss@iki.fi>
parents:
4808
diff
changeset
|
286 # -Wcast-qual -Wcast-align -Wconversion -Wunreachable-code # too many warnings |
850 | 287 # -Wstrict-prototypes -Wredundant-decls # may give warnings in some systems |
1043
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
288 # -Wmissing-format-attribute -Wmissing-noreturn -Wwrite-strings # a couple of warnings |
4022
2f26567685ff
Removed -Wstrict-aliasing=2 since it gives errors with older gccs
Timo Sirainen <tss@iki.fi>
parents:
4018
diff
changeset
|
289 CFLAGS="$CFLAGS -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2 -Wbad-function-cast" |
3091 | 290 |
4826
53ff1a59cdd5
Enable -Wstrict-aliasing=2 with gcc 4.
Timo Sirainen <tss@iki.fi>
parents:
4808
diff
changeset
|
291 AC_TRY_COMPILE([ |
53ff1a59cdd5
Enable -Wstrict-aliasing=2 with gcc 4.
Timo Sirainen <tss@iki.fi>
parents:
4808
diff
changeset
|
292 #if __GNUC__ < 4 |
53ff1a59cdd5
Enable -Wstrict-aliasing=2 with gcc 4.
Timo Sirainen <tss@iki.fi>
parents:
4808
diff
changeset
|
293 # error old gcc |
53ff1a59cdd5
Enable -Wstrict-aliasing=2 with gcc 4.
Timo Sirainen <tss@iki.fi>
parents:
4808
diff
changeset
|
294 #endif |
53ff1a59cdd5
Enable -Wstrict-aliasing=2 with gcc 4.
Timo Sirainen <tss@iki.fi>
parents:
4808
diff
changeset
|
295 ],,[ |
53ff1a59cdd5
Enable -Wstrict-aliasing=2 with gcc 4.
Timo Sirainen <tss@iki.fi>
parents:
4808
diff
changeset
|
296 # gcc4 |
53ff1a59cdd5
Enable -Wstrict-aliasing=2 with gcc 4.
Timo Sirainen <tss@iki.fi>
parents:
4808
diff
changeset
|
297 CFLAGS="$CFLAGS -Wstrict-aliasing=2" |
53ff1a59cdd5
Enable -Wstrict-aliasing=2 with gcc 4.
Timo Sirainen <tss@iki.fi>
parents:
4808
diff
changeset
|
298 ]) |
53ff1a59cdd5
Enable -Wstrict-aliasing=2 with gcc 4.
Timo Sirainen <tss@iki.fi>
parents:
4808
diff
changeset
|
299 |
3097
3ba362513202
Don't use -std=gnu99 if gcc doesn't support it.
Timo Sirainen <tss@iki.fi>
parents:
3091
diff
changeset
|
300 # Use std=gnu99 if we have new enough gcc |
3ba362513202
Don't use -std=gnu99 if gcc doesn't support it.
Timo Sirainen <tss@iki.fi>
parents:
3091
diff
changeset
|
301 old_cflags=$CFLAGS |
3ba362513202
Don't use -std=gnu99 if gcc doesn't support it.
Timo Sirainen <tss@iki.fi>
parents:
3091
diff
changeset
|
302 CFLAGS="-std=gnu99" |
3ba362513202
Don't use -std=gnu99 if gcc doesn't support it.
Timo Sirainen <tss@iki.fi>
parents:
3091
diff
changeset
|
303 AC_TRY_COMPILE([ |
3ba362513202
Don't use -std=gnu99 if gcc doesn't support it.
Timo Sirainen <tss@iki.fi>
parents:
3091
diff
changeset
|
304 ],, [ |
3ba362513202
Don't use -std=gnu99 if gcc doesn't support it.
Timo Sirainen <tss@iki.fi>
parents:
3091
diff
changeset
|
305 CFLAGS="$CFLAGS $old_cflags" |
3ba362513202
Don't use -std=gnu99 if gcc doesn't support it.
Timo Sirainen <tss@iki.fi>
parents:
3091
diff
changeset
|
306 ], [ |
3ba362513202
Don't use -std=gnu99 if gcc doesn't support it.
Timo Sirainen <tss@iki.fi>
parents:
3091
diff
changeset
|
307 CFLAGS="$old_cflags" |
3ba362513202
Don't use -std=gnu99 if gcc doesn't support it.
Timo Sirainen <tss@iki.fi>
parents:
3091
diff
changeset
|
308 ]) |
691
567f5e66c7b8
We compile now if dev_t is a structure (eg. glibc+tcc).
Timo Sirainen <tss@iki.fi>
parents:
679
diff
changeset
|
309 fi |
567f5e66c7b8
We compile now if dev_t is a structure (eg. glibc+tcc).
Timo Sirainen <tss@iki.fi>
parents:
679
diff
changeset
|
310 |
0 | 311 dnl ** |
312 dnl ** just some generic stuff... | |
313 dnl ** | |
314 | |
5690
c1f51c3510ca
Simplify some checks with AC_SEARCH_LIBS()
Timo Sirainen <tss@iki.fi>
parents:
5681
diff
changeset
|
315 AC_SEARCH_LIBS(socket, socket) |
c1f51c3510ca
Simplify some checks with AC_SEARCH_LIBS()
Timo Sirainen <tss@iki.fi>
parents:
5681
diff
changeset
|
316 AC_SEARCH_LIBS(inet_addr, nsl) |
c1f51c3510ca
Simplify some checks with AC_SEARCH_LIBS()
Timo Sirainen <tss@iki.fi>
parents:
5681
diff
changeset
|
317 AC_SEARCH_LIBS(fdatasync, rt, [ |
c1f51c3510ca
Simplify some checks with AC_SEARCH_LIBS()
Timo Sirainen <tss@iki.fi>
parents:
5681
diff
changeset
|
318 AC_DEFINE(HAVE_FDATASYNC,, Define if you have fdatasync()) |
0 | 319 ]) |
320 | |
9538
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
321 if test $want_libcap != no; then |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
322 AC_CHECK_LIB(cap, cap_init, [ |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
323 AC_DEFINE(HAVE_LIBCAP,, libcap is installed for cap_init()) |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
324 LIBCAP="-lcap" |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
325 AC_SUBST(LIBCAP) |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
326 ], [ |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
327 if test "$want_libcap" = "yes"; then |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
328 AC_ERROR([Can't build with libcap support: libcap not found]) |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
329 fi |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
330 ]) |
b20513ab8f5a
Added --without-libcap configure option.
Daniel Mierswa <impulze@impulze.org>
parents:
9410
diff
changeset
|
331 fi |
5201
8920e744dac4
Drop privileges if libcap is found. Patch by David (lists edeca.net).
Timo Sirainen <tss@iki.fi>
parents:
5197
diff
changeset
|
332 |
10647
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
333 have_libwrap=no |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
334 if test $want_libwrap != no; then |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
335 AC_CHECK_HEADER(tcpd.h, [ |
10700
b14e694fc8b4
configure: libwrap detection cleared $LIBS
Timo Sirainen <tss@iki.fi>
parents:
10699
diff
changeset
|
336 old_LIBS=$LIBS |
10980
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
337 |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
338 AC_CACHE_CHECK([whether we have libwrap],i_cv_have_libwrap,[ |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
339 AC_TRY_COMPILE([ |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
340 #include <tcpd.h> |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
341 int allow_severity = 0; |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
342 int deny_severity = 0; |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
343 ], [ |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
344 request_init((void *)0); |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
345 ], [ |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
346 i_cv_have_libwrap=yes |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
347 ], [ |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
348 i_cv_have_libwrap=no |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
349 ]) |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
350 ]) |
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
351 if test $i_cv_have_libwrap = yes; then |
10647
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
352 AC_DEFINE(HAVE_LIBWRAP,, Define if you have libwrap) |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
353 LIBWRAP_LIBS=-lwrap |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
354 AC_SUBST(LIBWRAP_LIBS) |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
355 have_libwrap=yes |
10980
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
356 else |
10647
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
357 if test "$want_libwrap" = "yes"; then |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
358 AC_ERROR([Can't build with libwrap support: libwrap not found]) |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
359 fi |
10980
5b0a88cb9a12
configure: Fixed libwrap checking in some systems.
Timo Sirainen <tss@iki.fi>
parents:
10968
diff
changeset
|
360 fi |
10647
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
361 LIBS=$old_LIBS |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
362 ], [ |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
363 if test "$want_libwrap" = "yes"; then |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
364 AC_ERROR([Can't build with libwrap support: tcpd.h not found]) |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
365 fi |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
366 ]) |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
367 fi |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
368 AM_CONDITIONAL(TCPWRAPPERS, test "$have_libwrap" = "yes") |
51a978045f47
Added support for tcpwrappers and potentially other login access checks.
Timo Sirainen <tss@iki.fi>
parents:
10645
diff
changeset
|
369 |
7917
ca2ff54ee9b4
Added support for IMAP ID extension.
Timo Sirainen <tss@iki.fi>
parents:
7914
diff
changeset
|
370 AC_DEFINE(PACKAGE_WEBPAGE, "http://www.dovecot.org/", Support URL) |
ca2ff54ee9b4
Added support for IMAP ID extension.
Timo Sirainen <tss@iki.fi>
parents:
7914
diff
changeset
|
371 |
0 | 372 dnl * after -lsocket and -lnsl tests, inet_aton() may be in them |
2103
879b0b9ed5d4
Separate mbox_locks/mbox_read_dotlock to mbox_read_locks and
Timo Sirainen <tss@iki.fi>
parents:
2080
diff
changeset
|
373 AC_CHECK_FUNCS(fcntl flock lockf inet_aton sigaction getpagesize madvise \ |
8600
7c12e20f1eee
env_remove(): Implement a fallback method if unsetenv() doesn't exist.
Timo Sirainen <tss@iki.fi>
parents:
8578
diff
changeset
|
374 strcasecmp stricmp vsyslog writev pread uname unsetenv \ |
3237
2f57438d9542
Added setegid() emulation for HP-UX.
Timo Sirainen <tss@iki.fi>
parents:
3236
diff
changeset
|
375 setrlimit setproctitle seteuid setreuid setegid setresgid \ |
7889
ef8af0eb161a
Check strtoimax() and strtoumax() with inttypes.h included. They won't be
Timo Sirainen <tss@iki.fi>
parents:
7869
diff
changeset
|
376 strtoull strtoll strtouq strtoq \ |
7847
35877d1131db
Added more fallbacks if strtoll() or strtoull() isn't implemented
Timo Sirainen <tss@iki.fi>
parents:
7844
diff
changeset
|
377 setpriority quotactl getmntent kqueue kevent backtrace_symbols \ |
9669
6cc6913fee1c
dovecot.conf: Added support for !include globs.
Timo Sirainen <tss@iki.fi>
parents:
9656
diff
changeset
|
378 walkcontext dirfd clearenv malloc_usable_size glob) |
9655
cef143e8719d
configure: Use -lrt for clock_gettime() if necessary.
Timo Sirainen <tss@iki.fi>
parents:
9654
diff
changeset
|
379 |
cef143e8719d
configure: Use -lrt for clock_gettime() if necessary.
Timo Sirainen <tss@iki.fi>
parents:
9654
diff
changeset
|
380 AC_CHECK_LIB(rt, clock_gettime, [ |
cef143e8719d
configure: Use -lrt for clock_gettime() if necessary.
Timo Sirainen <tss@iki.fi>
parents:
9654
diff
changeset
|
381 AC_DEFINE(HAVE_CLOCK_GETTIME,, Define if you have the clock_gettime function) |
9677
00399010c88a
configure: clock_gettime()'s -lrt adding dropped everything else from $LIBS.
Timo Sirainen <tss@iki.fi>
parents:
9669
diff
changeset
|
382 LIBS="$LIBS -lrt" |
9655
cef143e8719d
configure: Use -lrt for clock_gettime() if necessary.
Timo Sirainen <tss@iki.fi>
parents:
9654
diff
changeset
|
383 ], [ |
cef143e8719d
configure: Use -lrt for clock_gettime() if necessary.
Timo Sirainen <tss@iki.fi>
parents:
9654
diff
changeset
|
384 # OpenBSD |
cef143e8719d
configure: Use -lrt for clock_gettime() if necessary.
Timo Sirainen <tss@iki.fi>
parents:
9654
diff
changeset
|
385 AC_CHECK_FUNCS(clock_gettime) |
cef143e8719d
configure: Use -lrt for clock_gettime() if necessary.
Timo Sirainen <tss@iki.fi>
parents:
9654
diff
changeset
|
386 ]) |
0 | 387 |
7889
ef8af0eb161a
Check strtoimax() and strtoumax() with inttypes.h included. They won't be
Timo Sirainen <tss@iki.fi>
parents:
7869
diff
changeset
|
388 dnl strtoimax and strtoumax are macros in HP-UX, so inttypes.h must be included |
8601
da02a1d15783
configure: Test strtoumax() and strtoimax() by linking instead of just compiling (Tru64 fix).
Timo Sirainen <tss@iki.fi>
parents:
8600
diff
changeset
|
389 dnl Link instead of just compiling since there's something wrong with Tru64 |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
390 AC_CACHE_CHECK([for strtoimax],i_cv_have_strtoimax,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
391 AC_TRY_LINK([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
392 #include <inttypes.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
393 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
394 strtoimax(0, 0, 0); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
395 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
396 i_cv_have_strtoimax=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
397 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
398 i_cv_have_strtoimax=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
399 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
400 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
401 if test $i_cv_have_strtoimax = yes; then |
7889
ef8af0eb161a
Check strtoimax() and strtoumax() with inttypes.h included. They won't be
Timo Sirainen <tss@iki.fi>
parents:
7869
diff
changeset
|
402 AC_DEFINE(HAVE_STRTOIMAX,, Define if you have strtoimax function) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
403 fi |
7889
ef8af0eb161a
Check strtoimax() and strtoumax() with inttypes.h included. They won't be
Timo Sirainen <tss@iki.fi>
parents:
7869
diff
changeset
|
404 |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
405 AC_CACHE_CHECK([for strtoumax],i_cv_have_strtoumax,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
406 AC_TRY_LINK([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
407 #include <inttypes.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
408 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
409 strtoumax(0, 0, 0); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
410 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
411 i_cv_have_strtoumax=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
412 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
413 i_cv_have_strtoumax=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
414 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
415 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
416 if test $i_cv_have_strtoumax = yes; then |
7889
ef8af0eb161a
Check strtoimax() and strtoumax() with inttypes.h included. They won't be
Timo Sirainen <tss@iki.fi>
parents:
7869
diff
changeset
|
417 AC_DEFINE(HAVE_STRTOUMAX,, Define if you have strtoumax function) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
418 fi |
7889
ef8af0eb161a
Check strtoimax() and strtoumax() with inttypes.h included. They won't be
Timo Sirainen <tss@iki.fi>
parents:
7869
diff
changeset
|
419 |
2569
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
420 dnl * I/O loop function |
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
421 have_ioloop=no |
0 | 422 |
4482
f60b07bd5fa7
--with-ioloop=auto changed to --with-ioloop=best
Timo Sirainen <tss@iki.fi>
parents:
4478
diff
changeset
|
423 if test "$ioloop" = "best" || test "$ioloop" = "epoll"; then |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
424 AC_CACHE_CHECK([whether we can use epoll],i_cv_epoll_works,[ |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
425 AC_TRY_RUN([ |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
426 #include <sys/epoll.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
427 |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
428 int main() |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
429 { |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
430 return epoll_create(5) < 1; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
431 } |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
432 ], [ |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
433 i_cv_epoll_works=yes |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
434 ], [ |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
435 i_cv_epoll_works=no |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
436 ]) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
437 ]) |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
438 if test $i_cv_epoll_works = yes; then |
2569
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
439 AC_DEFINE(IOLOOP_EPOLL,, Implement I/O loop with Linux 2.6 epoll()) |
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
440 have_ioloop=yes |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
441 ioloop=epoll |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
442 else |
4478
4b01707d6cbe
Don't use epoll/kqueue by default unless --with-ioloop=auto is given.
Timo Sirainen <tss@iki.fi>
parents:
4443
diff
changeset
|
443 if test "$ioloop" = "epoll" ; then |
4b01707d6cbe
Don't use epoll/kqueue by default unless --with-ioloop=auto is given.
Timo Sirainen <tss@iki.fi>
parents:
4443
diff
changeset
|
444 AC_MSG_ERROR([epoll ioloop requested but epoll_create() is not available]) |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
445 fi |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
446 fi |
2569
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
447 fi |
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
448 |
4482
f60b07bd5fa7
--with-ioloop=auto changed to --with-ioloop=best
Timo Sirainen <tss@iki.fi>
parents:
4478
diff
changeset
|
449 if test "$ioloop" = "best" || test "$ioloop" = "kqueue"; then |
4433 | 450 if test "$ac_cv_func_kqueue" = yes && test "$ac_cv_func_kevent" = yes; then |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
451 AC_DEFINE(IOLOOP_KQUEUE,, [Implement I/O loop with BSD kqueue()]) |
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
452 ioloop=kqueue |
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
453 have_ioloop=yes |
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
454 elif test "$ioloop" = "kqueue"; then |
4478
4b01707d6cbe
Don't use epoll/kqueue by default unless --with-ioloop=auto is given.
Timo Sirainen <tss@iki.fi>
parents:
4443
diff
changeset
|
455 AC_MSG_ERROR([kqueue ioloop requested but kqueue() is not available]) |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
456 fi |
3749
194295062e5e
Added kqueue support. Patch by Vaclav Haisman.
Timo Sirainen <tss@iki.fi>
parents:
3745
diff
changeset
|
457 fi |
194295062e5e
Added kqueue support. Patch by Vaclav Haisman.
Timo Sirainen <tss@iki.fi>
parents:
3745
diff
changeset
|
458 |
4482
f60b07bd5fa7
--with-ioloop=auto changed to --with-ioloop=best
Timo Sirainen <tss@iki.fi>
parents:
4478
diff
changeset
|
459 if test "$ioloop" = "best" || test "$ioloop" = "poll"; then |
2569
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
460 AC_CHECK_FUNC(poll, [ |
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
461 AC_DEFINE(IOLOOP_POLL,, Implement I/O loop with poll()) |
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
462 ioloop=poll |
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
463 have_ioloop=yes |
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
464 ]) |
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
465 fi |
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
466 |
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
467 if test "$have_ioloop" = "no"; then |
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
468 AC_DEFINE(IOLOOP_SELECT,, Implement I/O loop with select()) |
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
469 ioloop="select" |
554f1324a435
Added epoll support if --with-ioloop=epoll is given. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
2538
diff
changeset
|
470 fi |
0 | 471 |
3745
840cc63e439b
Don't allow giving invalid notify methods in --with-notify
Timo Sirainen <tss@iki.fi>
parents:
3744
diff
changeset
|
472 have_notify=none |
3482
465c465c66be
Added inotify patch by Johannes Berg and did some restructuring to
Timo Sirainen <tss@iki.fi>
parents:
3452
diff
changeset
|
473 |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
474 if test "$notify" = "" || test "$notify" = "inotify" ; then |
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
475 dnl * inotify? |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
476 AC_CACHE_CHECK([whether we can use inotify],i_cv_inotify_works,[ |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
477 AC_TRY_RUN([ |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
478 #define _GNU_SOURCE |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
479 #include <sys/ioctl.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
480 #include <fcntl.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
481 #include <sys/inotify.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
482 #include <stdio.h> |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
483 |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
484 int main() |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
485 { |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
486 int wd, fd; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
487 char * fn = "/tmp"; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
488 |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
489 fd = inotify_init (); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
490 if (fd < 0) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
491 { |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
492 perror ("inotify_init"); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
493 return 1; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
494 } |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
495 |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
496 wd = inotify_add_watch (fd, fn, IN_ALL_EVENTS); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
497 |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
498 if (wd < 0) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
499 { |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
500 perror ("inotify_add_watch"); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
501 return 2; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
502 } |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
503 |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
504 inotify_rm_watch (fd, wd); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
505 |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
506 close (fd); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
507 return 0; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
508 } |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
509 ], [ |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
510 i_cv_inotify_works=yes |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
511 ], [ |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
512 i_cv_inotify_works=no |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
513 ]) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
514 ]) |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
515 if test $i_cv_inotify_works = yes; then |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
516 have_notify=inotify |
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
517 notify=inotify |
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
518 AC_DEFINE(IOLOOP_NOTIFY_INOTIFY,, Use Linux inotify) |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
519 else |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
520 if test "$notify" = "inotify"; then |
4478
4b01707d6cbe
Don't use epoll/kqueue by default unless --with-ioloop=auto is given.
Timo Sirainen <tss@iki.fi>
parents:
4443
diff
changeset
|
521 AC_MSG_ERROR([inotify requested but not available]) |
4423
26d18749f718
Fixes to io notify detection. Patch by Marcus Rueckert
Timo Sirainen <tss@iki.fi>
parents:
4422
diff
changeset
|
522 notify="" |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
523 fi |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
524 fi |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
525 fi |
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
526 |
4572
046b985ed767
Use notify=kqueue automatically only if ioloop=kqueue.
Timo Sirainen <tss@iki.fi>
parents:
4571
diff
changeset
|
527 if (test "$notify" = "" && test "$ioloop" = kqueue) || test "$notify" = "kqueue"; then |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
528 dnl * BSD kqueue() notify |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
529 AC_MSG_CHECKING([whether we can use BSD kqueue() notify]) |
4442 | 530 if test "$ac_cv_func_kqueue" = yes && test "$ac_cv_func_kevent" = yes ; then |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
531 have_notify=kqueue |
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
532 notify=kqueue |
4423
26d18749f718
Fixes to io notify detection. Patch by Marcus Rueckert
Timo Sirainen <tss@iki.fi>
parents:
4422
diff
changeset
|
533 AC_MSG_RESULT("yes") |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
534 AC_DEFINE(IOLOOP_NOTIFY_KQUEUE,, |
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
535 Use BSD kqueue directory changes notificaton) |
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
536 else |
4423
26d18749f718
Fixes to io notify detection. Patch by Marcus Rueckert
Timo Sirainen <tss@iki.fi>
parents:
4422
diff
changeset
|
537 AC_MSG_RESULT("no") |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
538 if test "$notify" = "kqueue" ; then |
4478
4b01707d6cbe
Don't use epoll/kqueue by default unless --with-ioloop=auto is given.
Timo Sirainen <tss@iki.fi>
parents:
4443
diff
changeset
|
539 AC_MSG_ERROR([kqueue notify requested but kqueue() is not available]) |
4423
26d18749f718
Fixes to io notify detection. Patch by Marcus Rueckert
Timo Sirainen <tss@iki.fi>
parents:
4422
diff
changeset
|
540 notify="" |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
541 fi |
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
542 fi |
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
543 fi |
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
544 |
3482
465c465c66be
Added inotify patch by Johannes Berg and did some restructuring to
Timo Sirainen <tss@iki.fi>
parents:
3452
diff
changeset
|
545 if test "$notify" = "" || test "$notify" = "dnotify"; then |
465c465c66be
Added inotify patch by Johannes Berg and did some restructuring to
Timo Sirainen <tss@iki.fi>
parents:
3452
diff
changeset
|
546 dnl * dnotify? |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
547 AC_CACHE_CHECK([whether we can use dnotify],i_cv_have_dnotify,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
548 AC_TRY_COMPILE([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
549 #define _GNU_SOURCE |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
550 #include <fcntl.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
551 #include <signal.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
552 #include <unistd.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
553 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
554 fcntl(0, F_SETSIG, SIGRTMIN); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
555 fcntl(0, F_NOTIFY, DN_CREATE | DN_DELETE | DN_RENAME | DN_MULTISHOT); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
556 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
557 i_cv_have_dnotify=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
558 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
559 i_cv_have_dnotify=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
560 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
561 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
562 if test $i_cv_have_dnotify = yes; then |
3482
465c465c66be
Added inotify patch by Johannes Berg and did some restructuring to
Timo Sirainen <tss@iki.fi>
parents:
3452
diff
changeset
|
563 AC_DEFINE(IOLOOP_NOTIFY_DNOTIFY,, Use Linux dnotify) |
3745
840cc63e439b
Don't allow giving invalid notify methods in --with-notify
Timo Sirainen <tss@iki.fi>
parents:
3744
diff
changeset
|
564 have_notify=dnotify |
4386
e23469650c85
Better detection for ioloop and notify methods. Patch by Roy Marples
Timo Sirainen <tss@iki.fi>
parents:
4349
diff
changeset
|
565 notify=dnotify |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
566 else |
3482
465c465c66be
Added inotify patch by Johannes Berg and did some restructuring to
Timo Sirainen <tss@iki.fi>
parents:
3452
diff
changeset
|
567 if test "$notify" = "dnotify"; then |
4478
4b01707d6cbe
Don't use epoll/kqueue by default unless --with-ioloop=auto is given.
Timo Sirainen <tss@iki.fi>
parents:
4443
diff
changeset
|
568 AC_MSG_ERROR([dnotify requested but not available]) |
3482
465c465c66be
Added inotify patch by Johannes Berg and did some restructuring to
Timo Sirainen <tss@iki.fi>
parents:
3452
diff
changeset
|
569 fi |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
570 fi |
3745
840cc63e439b
Don't allow giving invalid notify methods in --with-notify
Timo Sirainen <tss@iki.fi>
parents:
3744
diff
changeset
|
571 fi |
840cc63e439b
Don't allow giving invalid notify methods in --with-notify
Timo Sirainen <tss@iki.fi>
parents:
3744
diff
changeset
|
572 |
840cc63e439b
Don't allow giving invalid notify methods in --with-notify
Timo Sirainen <tss@iki.fi>
parents:
3744
diff
changeset
|
573 if test "$have_notify" = "none"; then |
840cc63e439b
Don't allow giving invalid notify methods in --with-notify
Timo Sirainen <tss@iki.fi>
parents:
3744
diff
changeset
|
574 AC_DEFINE(IOLOOP_NOTIFY_NONE,, No special notify support) |
3482
465c465c66be
Added inotify patch by Johannes Berg and did some restructuring to
Timo Sirainen <tss@iki.fi>
parents:
3452
diff
changeset
|
575 fi |
1729
5bf22d6bb65e
Added IO_DIR_NOTIFY and IO_FILE_NOTIFY conditions to io_add(). IO_DIR_NOTIFY
Timo Sirainen <tss@iki.fi>
parents:
1720
diff
changeset
|
576 |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
577 AC_CACHE_CHECK([whether we have glibc],i_cv_have_glibc,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
578 AC_TRY_COMPILE([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
579 #include <stdlib.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
580 #ifdef __GLIBC__ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
581 we have glibc |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
582 #endif |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
583 ],, [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
584 i_cv_have_glibc=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
585 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
586 i_cv_have_glibc=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
587 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
588 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
589 if test "$i_cv_have_glibc" = "yes"; then |
1989
a2b009c65e02
Define PREAD_WRAPPERS if we're using GLIBC, not if we're using Linux.
Timo Sirainen <tss@iki.fi>
parents:
1978
diff
changeset
|
590 AC_DEFINE(PREAD_WRAPPERS,, Define if pread/pwrite needs _XOPEN_SOURCE 500) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
591 fi |
1989
a2b009c65e02
Define PREAD_WRAPPERS if we're using GLIBC, not if we're using Linux.
Timo Sirainen <tss@iki.fi>
parents:
1978
diff
changeset
|
592 |
7164
d349cdeddc7d
Don't use posix_fallocate() with GLIBC versions older than 2.7. It probably
Timo Sirainen <tss@iki.fi>
parents:
7094
diff
changeset
|
593 dnl * Old glibcs have broken posix_fallocate(). Make sure not to use it. |
8227
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
594 dnl * It may also be broken in AIX. |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
595 AC_CACHE_CHECK([whether posix_fallocate() works],i_cv_posix_fallocate_works,[ |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
596 AC_TRY_RUN([ |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
597 #define _XOPEN_SOURCE 600 |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
598 #include <stdio.h> |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
599 #include <stdlib.h> |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
600 #include <fcntl.h> |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
601 #include <unistd.h> |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
602 #if defined(__GLIBC__) && (__GLIBC__ < 2 || __GLIBC_MINOR__ < 7) |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
603 possibly broken posix_fallocate |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
604 #endif |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
605 int main() { |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
606 int fd = creat("conftest.temp", 0600); |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
607 int ret; |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
608 if (fd == -1) { |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
609 perror("creat()"); |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
610 return 2; |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
611 } |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
612 ret = posix_fallocate(fd, 1024, 1024) < 0 ? 1 : 0; |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
613 unlink("conftest.temp"); |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
614 return ret; |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
615 } |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
616 ], [ |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
617 i_cv_posix_fallocate_works=yes |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
618 ], [ |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
619 i_cv_posix_fallocate_works=no |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
620 ]) |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
621 ]) |
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
622 if test $i_cv_posix_fallocate_works = yes; then |
7164
d349cdeddc7d
Don't use posix_fallocate() with GLIBC versions older than 2.7. It probably
Timo Sirainen <tss@iki.fi>
parents:
7094
diff
changeset
|
623 AC_DEFINE(HAVE_POSIX_FALLOCATE,, Define if you have a working posix_fallocate()) |
8227
9886bf0a4c40
Test if posix_fallocate() works already in configure.
Timo Sirainen <tss@iki.fi>
parents:
8226
diff
changeset
|
624 fi |
7164
d349cdeddc7d
Don't use posix_fallocate() with GLIBC versions older than 2.7. It probably
Timo Sirainen <tss@iki.fi>
parents:
7094
diff
changeset
|
625 |
0 | 626 dnl * OS specific options |
10753
80a11f8650a4
Added dovecot.m4 file that external plugins can use.
Timo Sirainen <tss@iki.fi>
parents:
10702
diff
changeset
|
627 DC_PLUGIN_DEPS |
0 | 628 case "$host_os" in |
629 hpux*) | |
7823 | 630 CFLAGS="$CFLAGS -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED" |
631 # for getting fd_send/fd_recv working: | |
632 LDFLAGS="$LDFLAGS -Wl,+b,:" | |
633 LIBS="-lxnet $LIBS" | |
7822
5abe05d7d093
HP-UX: pread() and pwrite() are broken, use our own implementation.
Timo Sirainen <tss@iki.fi>
parents:
7804
diff
changeset
|
634 AC_DEFINE(PREAD_BROKEN,, Defint if pread/pwrite implementation is broken) |
0 | 635 ;; |
11356
348eb4754085
Added process title hack support for OS X.
Timo Sirainen <tss@iki.fi>
parents:
11321
diff
changeset
|
636 linux*|darwin*) |
10188
affb52c62add
Fixed Linux proctitle hack and enabled it by default now.
Timo Sirainen <tss@iki.fi>
parents:
10163
diff
changeset
|
637 AC_DEFINE(PROCTITLE_HACK,, Define if process title can be changed by modifying argv) |
affb52c62add
Fixed Linux proctitle hack and enabled it by default now.
Timo Sirainen <tss@iki.fi>
parents:
10163
diff
changeset
|
638 ;; |
0 | 639 *) |
640 ;; | |
641 esac | |
642 | |
55
db8ea2c11ab7
whops, 64bit support was disabled.
Timo Sirainen <tss@iki.fi>
parents:
50
diff
changeset
|
643 AC_CHECK_SIZEOF(int) |
db8ea2c11ab7
whops, 64bit support was disabled.
Timo Sirainen <tss@iki.fi>
parents:
50
diff
changeset
|
644 AC_CHECK_SIZEOF(long) |
464
c634b705f24b
Removed several useless handers of printf_string_upper_bound(), and added a
Timo Sirainen <tss@iki.fi>
parents:
439
diff
changeset
|
645 AC_CHECK_SIZEOF(void *) |
55
db8ea2c11ab7
whops, 64bit support was disabled.
Timo Sirainen <tss@iki.fi>
parents:
50
diff
changeset
|
646 AC_CHECK_SIZEOF(long long) |
185 | 647 |
2036
b3a56463c812
AC_DEFUN warning fixes for aclocal 1.8..
Timo Sirainen <tss@iki.fi>
parents:
2035
diff
changeset
|
648 AC_DEFUN([AC_TYPEOF], [ |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
649 dnl * first check if we can get the size with redefining typedefs |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
650 |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
651 order="$2" |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
652 if test "$2" = ""; then |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
653 order="int long long-long" |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
654 fi |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
655 |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
656 result="" |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
657 visible="unknown" |
733
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
658 AC_MSG_CHECKING([type of $1]) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
659 AC_CACHE_VAL(i_cv_typeof_$1,[ |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
660 if test "x$ac_cv_c_compiler_gnu" = "xyes"; then |
733
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
661 dnl * try with printf() + -Werror |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
662 old_CFLAGS="$CFLAGS" |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
663 CFLAGS="$CFLAGS -Werror" |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
664 |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
665 for type in $order; do |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
666 case "$type" in |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
667 int) |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
668 fmt="%d" |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
669 ;; |
1630 | 670 unsigned-int) |
671 fmt="%u" | |
672 ;; | |
733
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
673 long) |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
674 fmt="%ld" |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
675 ;; |
1630 | 676 unsigned-long) |
677 fmt="%lu" | |
678 ;; | |
733
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
679 long-long) |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
680 fmt="%lld" |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
681 ;; |
1630 | 682 unsigned-long-long) |
683 fmt="%llu" | |
684 ;; | |
733
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
685 *) |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
686 fmt="" |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
687 ;; |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
688 esac |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
689 |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
690 if test "$fmt" != ""; then |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
691 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
733
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
692 #include <sys/types.h> |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
693 #include <stdio.h> |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
694 ]], [[ |
733
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
695 printf("$fmt", ($1)0); |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
696 ]])],[ |
733
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
697 if test "$result" != ""; then |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
698 dnl * warning check isn't working |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
699 result="" |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
700 visible="unknown" |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
701 break |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
702 fi |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
703 result="`echo $type|sed 's/-/ /g'`" |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
704 visible="$result" |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
705 ],[]) |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
706 fi |
733
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
707 done |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
708 CFLAGS="$old_CFLAGS" |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
709 fi |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
710 |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
711 if test "$result" = ""; then |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
712 for type in $order; do |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
713 type="`echo $type|sed 's/-/ /g'`" |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
714 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
733
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
715 #include <sys/types.h> |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
716 typedef $type $1; |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
717 ]], [[]])],[ |
733
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
718 if test "$result" != ""; then |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
719 dnl * compiler allows redefining to anything |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
720 result="" |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
721 visible="unknown" |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
722 break |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
723 fi |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
724 result="$type" |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
725 visible="$type" |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
726 ],[]) |
733
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
727 done |
280c0952fa90
AC_TYPEOF macro: with gcc we can check the type with printf() + -Werror
Timo Sirainen <tss@iki.fi>
parents:
732
diff
changeset
|
728 fi |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
729 |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
730 if test "$result" = ""; then |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
731 dnl * check with sizes |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
732 |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
733 dnl * older autoconfs don't include sys/types.h, so do it manually |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
734 AC_RUN_IFELSE([AC_LANG_SOURCE([[ |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
735 #include <stdio.h> |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
736 #include <sys/types.h> |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
737 int main() { |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
738 FILE *f=fopen("conftestval", "w"); |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
739 if (!f) exit(1); |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
740 fprintf(f, "%d\n", sizeof($1)); |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
741 exit(0); |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
742 } |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
743 ]])],[ |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
744 size=`cat conftestval` |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
745 rm -f conftestval |
55
db8ea2c11ab7
whops, 64bit support was disabled.
Timo Sirainen <tss@iki.fi>
parents:
50
diff
changeset
|
746 |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
747 for type in $order; do |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
748 actype="ac_cv_sizeof_`echo $type|sed 's/-/_/g'`" |
4567
32f5df3de2d1
eval doesn't need to have its parameters quoted. The previous \" quoting was
Timo Sirainen <tss@iki.fi>
parents:
4565
diff
changeset
|
749 if test "$size" = "`eval echo \\$$actype`"; then |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
750 result="`echo $type|sed 's/-/ /g'`" |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
751 visible="`expr $size \* 8`bit (using $result)" |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
752 break |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
753 fi |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
754 done |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
755 if test "$result" = ""; then |
4055
f7ff79c3189b
If size_t and ssize_t exist but we can't figure out their type, don't
Timo Sirainen <tss@iki.fi>
parents:
4050
diff
changeset
|
756 result=unknown |
f7ff79c3189b
If size_t and ssize_t exist but we can't figure out their type, don't
Timo Sirainen <tss@iki.fi>
parents:
4050
diff
changeset
|
757 visible="`expr $size \* 8`bit (unknown type)" |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
758 fi |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
759 ],[],[]) |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
760 fi |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
761 i_cv_typeof_$1=$result/$visible |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
762 ]) |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
763 |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
764 typeof_$1=`echo $i_cv_typeof_$1 | sed s,/.*$,,` |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
765 visible=`echo $i_cv_typeof_$1 | sed s,^.*/,,` |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
766 AC_MSG_RESULT($visible) |
185 | 767 ]) |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
768 |
6616
be366eda336e
Use AC_SYS_LARGEFILE instead of our own checks. Also removes
Timo Sirainen <tss@iki.fi>
parents:
6610
diff
changeset
|
769 AC_SYS_LARGEFILE |
3929
49a1a979959e
If uoff_t type already exists, use it (UnixWare has it).
Timo Sirainen <tss@iki.fi>
parents:
3919
diff
changeset
|
770 AC_CHECK_TYPES(_Bool) |
49a1a979959e
If uoff_t type already exists, use it (UnixWare has it).
Timo Sirainen <tss@iki.fi>
parents:
3919
diff
changeset
|
771 |
49a1a979959e
If uoff_t type already exists, use it (UnixWare has it).
Timo Sirainen <tss@iki.fi>
parents:
3919
diff
changeset
|
772 AC_CHECK_TYPE(uoff_t, [ |
3931 | 773 have_uoff_t=yes |
3929
49a1a979959e
If uoff_t type already exists, use it (UnixWare has it).
Timo Sirainen <tss@iki.fi>
parents:
3919
diff
changeset
|
774 AC_DEFINE(HAVE_UOFF_T,, Define if you have a native uoff_t type) |
49a1a979959e
If uoff_t type already exists, use it (UnixWare has it).
Timo Sirainen <tss@iki.fi>
parents:
3919
diff
changeset
|
775 ], [ |
3931 | 776 have_uoff_t=no |
777 ]) | |
778 | |
779 AC_TYPEOF(off_t, long int long-long) | |
780 case "$typeof_off_t" in | |
781 int) | |
782 offt_max=INT_MAX | |
783 uofft_fmt="u" | |
784 if test "$have_uoff_t" != "yes"; then | |
3929
49a1a979959e
If uoff_t type already exists, use it (UnixWare has it).
Timo Sirainen <tss@iki.fi>
parents:
3919
diff
changeset
|
785 AC_DEFINE(UOFF_T_INT,, Define if off_t is int) |
3931 | 786 fi |
787 offt_bits=`expr 8 \* $ac_cv_sizeof_int` | |
788 ;; | |
789 long) | |
790 offt_max=LONG_MAX | |
791 uofft_fmt="lu" | |
792 if test "$have_uoff_t" != "yes"; then | |
3929
49a1a979959e
If uoff_t type already exists, use it (UnixWare has it).
Timo Sirainen <tss@iki.fi>
parents:
3919
diff
changeset
|
793 AC_DEFINE(UOFF_T_LONG,, Define if off_t is long) |
3931 | 794 fi |
795 offt_bits=`expr 8 \* $ac_cv_sizeof_long` | |
796 ;; | |
797 "long long") | |
798 offt_max=LLONG_MAX | |
799 uofft_fmt="llu" | |
800 if test "$have_uoff_t" != "yes"; then | |
3929
49a1a979959e
If uoff_t type already exists, use it (UnixWare has it).
Timo Sirainen <tss@iki.fi>
parents:
3919
diff
changeset
|
801 AC_DEFINE(UOFF_T_LONG_LONG,, Define if off_t is long long) |
3931 | 802 fi |
803 offt_bits=`expr 8 \* $ac_cv_sizeof_long_long` | |
804 ;; | |
805 *) | |
806 AC_MSG_ERROR([Unsupported off_t type]) | |
807 ;; | |
808 esac | |
50
d493b9cc265e
Introduced uoff_t which is the unsigned-equilevant of off_t. This was needed
Timo Sirainen <tss@iki.fi>
parents:
5
diff
changeset
|
809 |
2078
b3daf55df932
Added maildir_stat_dirs option.
Timo Sirainen <tss@iki.fi>
parents:
2070
diff
changeset
|
810 dnl * Do we have struct dirent->d_type |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
811 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
2078
b3daf55df932
Added maildir_stat_dirs option.
Timo Sirainen <tss@iki.fi>
parents:
2070
diff
changeset
|
812 #include <dirent.h> |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
813 ]], [[ |
2078
b3daf55df932
Added maildir_stat_dirs option.
Timo Sirainen <tss@iki.fi>
parents:
2070
diff
changeset
|
814 struct dirent d; |
b3daf55df932
Added maildir_stat_dirs option.
Timo Sirainen <tss@iki.fi>
parents:
2070
diff
changeset
|
815 d.d_type = DT_DIR; |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
816 ]])],[ |
2078
b3daf55df932
Added maildir_stat_dirs option.
Timo Sirainen <tss@iki.fi>
parents:
2070
diff
changeset
|
817 AC_DEFINE(HAVE_DIRENT_D_TYPE,, Define if you have struct dirent->d_type) |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
818 ],[]) |
2078
b3daf55df932
Added maildir_stat_dirs option.
Timo Sirainen <tss@iki.fi>
parents:
2070
diff
changeset
|
819 |
1382
c4d519a6395d
Don't define OFF_T_MAX if it's already defined
Timo Sirainen <tss@iki.fi>
parents:
1341
diff
changeset
|
820 dnl * Do we have OFF_T_MAX? |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
821 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
1382
c4d519a6395d
Don't define OFF_T_MAX if it's already defined
Timo Sirainen <tss@iki.fi>
parents:
1341
diff
changeset
|
822 #include <limits.h> |
c4d519a6395d
Don't define OFF_T_MAX if it's already defined
Timo Sirainen <tss@iki.fi>
parents:
1341
diff
changeset
|
823 #include <sys/types.h> |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
824 ]], [[ |
1382
c4d519a6395d
Don't define OFF_T_MAX if it's already defined
Timo Sirainen <tss@iki.fi>
parents:
1341
diff
changeset
|
825 off_t i = OFF_T_MAX; |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
826 ]])],[ |
1403 | 827 : |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
828 ],[ |
1382
c4d519a6395d
Don't define OFF_T_MAX if it's already defined
Timo Sirainen <tss@iki.fi>
parents:
1341
diff
changeset
|
829 AC_DEFINE_UNQUOTED(OFF_T_MAX, $offt_max, Maximum value of off_t) |
c4d519a6395d
Don't define OFF_T_MAX if it's already defined
Timo Sirainen <tss@iki.fi>
parents:
1341
diff
changeset
|
830 ]) |
c4d519a6395d
Don't define OFF_T_MAX if it's already defined
Timo Sirainen <tss@iki.fi>
parents:
1341
diff
changeset
|
831 |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
832 AC_DEFINE_UNQUOTED(PRIuUOFF_T, "$uofft_fmt", printf() format for uoff_t) |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
833 |
750
b97c8964d7c1
Give a hard warning if size_t is signed.
Timo Sirainen <tss@iki.fi>
parents:
745
diff
changeset
|
834 dnl * make sure size_t isn't signed. we'd probably work fine with it, but |
b97c8964d7c1
Give a hard warning if size_t is signed.
Timo Sirainen <tss@iki.fi>
parents:
745
diff
changeset
|
835 dnl * it's more likely vulnerable to buffer overflows. Anyway, C99 specifies |
b97c8964d7c1
Give a hard warning if size_t is signed.
Timo Sirainen <tss@iki.fi>
parents:
745
diff
changeset
|
836 dnl * that it's unsigned and only some old systems define it as signed. |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
837 AC_CACHE_CHECK([whether size_t is signed],i_cv_signed_size_t,[ |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
838 AC_RUN_IFELSE([AC_LANG_SOURCE([[ |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
839 #include <sys/types.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
840 int main() { |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
841 /* return 0 if we're signed */ |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
842 exit((size_t)(int)-1 <= 0 ? 0 : 1); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
843 } |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
844 ]])],[ |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
845 i_cv_signed_size_t=yes |
750
b97c8964d7c1
Give a hard warning if size_t is signed.
Timo Sirainen <tss@iki.fi>
parents:
745
diff
changeset
|
846 |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
847 echo |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
848 echo "Your system's size_t is a signed integer, Dovecot isn't designed to" |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
849 echo "support it. It probably works just fine, but it's less resistant to" |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
850 echo "buffer overflows. If you're not worried about this and still want to" |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
851 echo "compile Dovecot, set ignore_signed_size=1 environment." |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
852 |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
853 if test "$ignore_signed_size" = ""; then |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
854 AC_MSG_ERROR([aborting]) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
855 fi |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
856 echo "..ignoring as requested.." |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
857 ],[ |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
858 i_cv_signed_size_t=no |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
859 ],[]) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
860 ]) |
1626
08b73ec005f8
Get the size_t type properly in OSX
Timo Sirainen <tss@iki.fi>
parents:
1625
diff
changeset
|
861 dnl Note: we check size_t rather than ssize_t here, because on OSX 10.2 |
08b73ec005f8
Get the size_t type properly in OSX
Timo Sirainen <tss@iki.fi>
parents:
1625
diff
changeset
|
862 dnl ssize_t = int and size_t = unsigned long. We're mostly concerned about |
08b73ec005f8
Get the size_t type properly in OSX
Timo Sirainen <tss@iki.fi>
parents:
1625
diff
changeset
|
863 dnl printf format here, so check the size_t one. |
08b73ec005f8
Get the size_t type properly in OSX
Timo Sirainen <tss@iki.fi>
parents:
1625
diff
changeset
|
864 AC_TYPEOF(size_t, unsigned-int unsigned-long unsigned-long-long) |
08b73ec005f8
Get the size_t type properly in OSX
Timo Sirainen <tss@iki.fi>
parents:
1625
diff
changeset
|
865 case "$typeof_size_t" in |
08b73ec005f8
Get the size_t type properly in OSX
Timo Sirainen <tss@iki.fi>
parents:
1625
diff
changeset
|
866 "unsigned long") |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
867 ssizet_max=LONG_MAX |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
868 sizet_fmt="lu" |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
869 ;; |
1626
08b73ec005f8
Get the size_t type properly in OSX
Timo Sirainen <tss@iki.fi>
parents:
1625
diff
changeset
|
870 "unsigned long long") |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
871 ssizet_max=LLONG_MAX |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
872 sizet_fmt="llu" |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
873 ;; |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
874 *) |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
875 dnl older systems didn't have ssize_t, default to int |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
876 ssizet_max=INT_MAX |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
877 sizet_fmt="u" |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
878 |
1626
08b73ec005f8
Get the size_t type properly in OSX
Timo Sirainen <tss@iki.fi>
parents:
1625
diff
changeset
|
879 if test "$typeof_size_t" = ""; then |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
880 AC_DEFINE(size_t, unsigned int, Define to 'unsigned int' if you don't have it) |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
881 AC_DEFINE(ssize_t, int, Define to 'int' if you don't have it) |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
882 fi |
677
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
883 ;; |
3089685bbb7e
Created AC_TYPEOF() which tells what base type (int/long/long long) the
Timo Sirainen <tss@iki.fi>
parents:
676
diff
changeset
|
884 esac |
183
4a7ab9e94f25
size_t fixes for lib/. Changed OFF_T_FORMAT to PRIuOFF_T which is more
Timo Sirainen <tss@iki.fi>
parents:
179
diff
changeset
|
885 |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
886 AC_DEFINE_UNQUOTED(SSIZE_T_MAX, $ssizet_max, Maximum value of ssize_t) |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
887 AC_DEFINE_UNQUOTED(PRIuSIZE_T, "$sizet_fmt", printf() format for size_t) |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
888 |
2036
b3a56463c812
AC_DEFUN warning fixes for aclocal 1.8..
Timo Sirainen <tss@iki.fi>
parents:
2035
diff
changeset
|
889 AC_DEFUN([AC_CHECKTYPE2], [ |
678
1e5c655bad25
Renamed largest_t to uintmax_t which already exists in C99.
Timo Sirainen <tss@iki.fi>
parents:
677
diff
changeset
|
890 AC_MSG_CHECKING([for $1]) |
1e5c655bad25
Renamed largest_t to uintmax_t which already exists in C99.
Timo Sirainen <tss@iki.fi>
parents:
677
diff
changeset
|
891 AC_CACHE_VAL(i_cv_type_$1, |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
892 [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
678
1e5c655bad25
Renamed largest_t to uintmax_t which already exists in C99.
Timo Sirainen <tss@iki.fi>
parents:
677
diff
changeset
|
893 #include <sys/types.h> |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
894 $2]], [[$1 t;]])],[i_cv_type_$1=yes],[i_cv_type_$1=no])]) |
678
1e5c655bad25
Renamed largest_t to uintmax_t which already exists in C99.
Timo Sirainen <tss@iki.fi>
parents:
677
diff
changeset
|
895 AC_MSG_RESULT($i_cv_type_$1) |
1e5c655bad25
Renamed largest_t to uintmax_t which already exists in C99.
Timo Sirainen <tss@iki.fi>
parents:
677
diff
changeset
|
896 ]) |
1e5c655bad25
Renamed largest_t to uintmax_t which already exists in C99.
Timo Sirainen <tss@iki.fi>
parents:
677
diff
changeset
|
897 |
1660
4076387f7ccb
We should be checking C99 types using stdint.h, not inttypes.h
Timo Sirainen <tss@iki.fi>
parents:
1658
diff
changeset
|
898 dnl some systems don't have stdint.h, but still have some of the types |
4076387f7ccb
We should be checking C99 types using stdint.h, not inttypes.h
Timo Sirainen <tss@iki.fi>
parents:
1658
diff
changeset
|
899 dnl defined elsewhere |
4076387f7ccb
We should be checking C99 types using stdint.h, not inttypes.h
Timo Sirainen <tss@iki.fi>
parents:
1658
diff
changeset
|
900 AC_CHECK_HEADER(stdint.h, [ |
4076387f7ccb
We should be checking C99 types using stdint.h, not inttypes.h
Timo Sirainen <tss@iki.fi>
parents:
1658
diff
changeset
|
901 stdint_include="#include <stdint.h>" |
4076387f7ccb
We should be checking C99 types using stdint.h, not inttypes.h
Timo Sirainen <tss@iki.fi>
parents:
1658
diff
changeset
|
902 ]) |
4076387f7ccb
We should be checking C99 types using stdint.h, not inttypes.h
Timo Sirainen <tss@iki.fi>
parents:
1658
diff
changeset
|
903 |
4076387f7ccb
We should be checking C99 types using stdint.h, not inttypes.h
Timo Sirainen <tss@iki.fi>
parents:
1658
diff
changeset
|
904 AC_CHECKTYPE2(uintmax_t, [$stdint_include]) |
678
1e5c655bad25
Renamed largest_t to uintmax_t which already exists in C99.
Timo Sirainen <tss@iki.fi>
parents:
677
diff
changeset
|
905 if test $i_cv_type_uintmax_t = yes; then |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
906 AC_DEFINE(HAVE_UINTMAX_T,, Define if you have uintmax_t (C99 type)) |
179
0ffecd4e7e1a
added dec2str() function and largest_t type, removed itoa() and ltoa()
Timo Sirainen <tss@iki.fi>
parents:
175
diff
changeset
|
907 fi |
0ffecd4e7e1a
added dec2str() function and largest_t type, removed itoa() and ltoa()
Timo Sirainen <tss@iki.fi>
parents:
175
diff
changeset
|
908 |
908
bc55266563cd
Use separate check for uint_fast32_t.
Timo Sirainen <tss@iki.fi>
parents:
907
diff
changeset
|
909 dnl use separate check, eg. Solaris 8 has uintmax_t but not uint_fast32_t |
1660
4076387f7ccb
We should be checking C99 types using stdint.h, not inttypes.h
Timo Sirainen <tss@iki.fi>
parents:
1658
diff
changeset
|
910 AC_CHECKTYPE2(uint_fast32_t, [$stdint_include]) |
908
bc55266563cd
Use separate check for uint_fast32_t.
Timo Sirainen <tss@iki.fi>
parents:
907
diff
changeset
|
911 if test $i_cv_type_uint_fast32_t = yes; then |
bc55266563cd
Use separate check for uint_fast32_t.
Timo Sirainen <tss@iki.fi>
parents:
907
diff
changeset
|
912 AC_DEFINE(HAVE_UINT_FAST32_T,, Define if you have uint_fast32_t (C99 type)) |
bc55266563cd
Use separate check for uint_fast32_t.
Timo Sirainen <tss@iki.fi>
parents:
907
diff
changeset
|
913 fi |
bc55266563cd
Use separate check for uint_fast32_t.
Timo Sirainen <tss@iki.fi>
parents:
907
diff
changeset
|
914 |
678
1e5c655bad25
Renamed largest_t to uintmax_t which already exists in C99.
Timo Sirainen <tss@iki.fi>
parents:
677
diff
changeset
|
915 AC_CHECKTYPE2(socklen_t, [#include <sys/socket.h>]) |
1e5c655bad25
Renamed largest_t to uintmax_t which already exists in C99.
Timo Sirainen <tss@iki.fi>
parents:
677
diff
changeset
|
916 if test $i_cv_type_socklen_t = yes; then |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
917 AC_DEFINE(HAVE_SOCKLEN_T,, Define to 'int' if you don't have socklen_t) |
0 | 918 fi |
919 | |
1394
059f13d577bb
Use separate index alignment from memory alignment. We don't use pointers in
Timo Sirainen <tss@iki.fi>
parents:
1389
diff
changeset
|
920 AC_DEFINE_UNQUOTED(MEM_ALIGN_SIZE, $mem_align, Required memory alignment) |
059f13d577bb
Use separate index alignment from memory alignment. We don't use pointers in
Timo Sirainen <tss@iki.fi>
parents:
1389
diff
changeset
|
921 |
1335
5ad84c54eb7e
Support using OpenSSL's pseudo-random generator instead of /dev/urandom. If
Timo Sirainen <tss@iki.fi>
parents:
1300
diff
changeset
|
922 dnl * find random source |
9204
1849c4269ad8
If /dev/arandom exists (OpenBSD), use it instead of /dev/urandom.
Timo Sirainen <tss@iki.fi>
parents:
9159
diff
changeset
|
923 AC_MSG_CHECKING([for OpenBSD /dev/arandom]) |
1849c4269ad8
If /dev/arandom exists (OpenBSD), use it instead of /dev/urandom.
Timo Sirainen <tss@iki.fi>
parents:
9159
diff
changeset
|
924 if test -c /dev/arandom; then |
1335
5ad84c54eb7e
Support using OpenSSL's pseudo-random generator instead of /dev/urandom. If
Timo Sirainen <tss@iki.fi>
parents:
1300
diff
changeset
|
925 AC_MSG_RESULT(yes) |
9204
1849c4269ad8
If /dev/arandom exists (OpenBSD), use it instead of /dev/urandom.
Timo Sirainen <tss@iki.fi>
parents:
9159
diff
changeset
|
926 AC_DEFINE(DEV_URANDOM_PATH, "/dev/arandom", Path to /dev/urandom) |
1335
5ad84c54eb7e
Support using OpenSSL's pseudo-random generator instead of /dev/urandom. If
Timo Sirainen <tss@iki.fi>
parents:
1300
diff
changeset
|
927 have_random_source=yes |
5ad84c54eb7e
Support using OpenSSL's pseudo-random generator instead of /dev/urandom. If
Timo Sirainen <tss@iki.fi>
parents:
1300
diff
changeset
|
928 else |
5ad84c54eb7e
Support using OpenSSL's pseudo-random generator instead of /dev/urandom. If
Timo Sirainen <tss@iki.fi>
parents:
1300
diff
changeset
|
929 AC_MSG_RESULT(no) |
9204
1849c4269ad8
If /dev/arandom exists (OpenBSD), use it instead of /dev/urandom.
Timo Sirainen <tss@iki.fi>
parents:
9159
diff
changeset
|
930 AC_MSG_CHECKING([for /dev/urandom]) |
1849c4269ad8
If /dev/arandom exists (OpenBSD), use it instead of /dev/urandom.
Timo Sirainen <tss@iki.fi>
parents:
9159
diff
changeset
|
931 if test -c /dev/urandom || test -s /dev/urandom; then |
1849c4269ad8
If /dev/arandom exists (OpenBSD), use it instead of /dev/urandom.
Timo Sirainen <tss@iki.fi>
parents:
9159
diff
changeset
|
932 AC_MSG_RESULT(yes) |
1849c4269ad8
If /dev/arandom exists (OpenBSD), use it instead of /dev/urandom.
Timo Sirainen <tss@iki.fi>
parents:
9159
diff
changeset
|
933 AC_DEFINE(DEV_URANDOM_PATH, "/dev/urandom", Path to /dev/urandom) |
1849c4269ad8
If /dev/arandom exists (OpenBSD), use it instead of /dev/urandom.
Timo Sirainen <tss@iki.fi>
parents:
9159
diff
changeset
|
934 have_random_source=yes |
1849c4269ad8
If /dev/arandom exists (OpenBSD), use it instead of /dev/urandom.
Timo Sirainen <tss@iki.fi>
parents:
9159
diff
changeset
|
935 else |
1849c4269ad8
If /dev/arandom exists (OpenBSD), use it instead of /dev/urandom.
Timo Sirainen <tss@iki.fi>
parents:
9159
diff
changeset
|
936 AC_MSG_RESULT(no) |
1849c4269ad8
If /dev/arandom exists (OpenBSD), use it instead of /dev/urandom.
Timo Sirainen <tss@iki.fi>
parents:
9159
diff
changeset
|
937 fi |
1849c4269ad8
If /dev/arandom exists (OpenBSD), use it instead of /dev/urandom.
Timo Sirainen <tss@iki.fi>
parents:
9159
diff
changeset
|
938 fi |
1335
5ad84c54eb7e
Support using OpenSSL's pseudo-random generator instead of /dev/urandom. If
Timo Sirainen <tss@iki.fi>
parents:
1300
diff
changeset
|
939 |
9204
1849c4269ad8
If /dev/arandom exists (OpenBSD), use it instead of /dev/urandom.
Timo Sirainen <tss@iki.fi>
parents:
9159
diff
changeset
|
940 if test "$have_random_source" != "yes"; then |
1335
5ad84c54eb7e
Support using OpenSSL's pseudo-random generator instead of /dev/urandom. If
Timo Sirainen <tss@iki.fi>
parents:
1300
diff
changeset
|
941 AC_CHECK_HEADER(openssl/rand.h, [ |
5ad84c54eb7e
Support using OpenSSL's pseudo-random generator instead of /dev/urandom. If
Timo Sirainen <tss@iki.fi>
parents:
1300
diff
changeset
|
942 AC_DEFINE(HAVE_OPENSSL_RAND_H,, Define if you have openssl/rand.h) |
7844
7b39370dae6b
If we need -lcrypto for randomness, put it to $LIBS instead of $RAND_LIBS
Timo Sirainen <tss@iki.fi>
parents:
7826
diff
changeset
|
943 LIBS="$LIBS -lcrypto" |
1335
5ad84c54eb7e
Support using OpenSSL's pseudo-random generator instead of /dev/urandom. If
Timo Sirainen <tss@iki.fi>
parents:
1300
diff
changeset
|
944 ]) |
5ad84c54eb7e
Support using OpenSSL's pseudo-random generator instead of /dev/urandom. If
Timo Sirainen <tss@iki.fi>
parents:
1300
diff
changeset
|
945 fi |
5ad84c54eb7e
Support using OpenSSL's pseudo-random generator instead of /dev/urandom. If
Timo Sirainen <tss@iki.fi>
parents:
1300
diff
changeset
|
946 |
0 | 947 dnl * do we have tm_gmtoff |
948 AC_MSG_CHECKING([for tm_gmtoff]) | |
949 AC_CACHE_VAL(i_cv_field_tm_gmtoff, | |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
950 [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
951 #include <time.h>]], |
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
952 [[struct tm *tm; return tm->tm_gmtoff;]])], |
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
953 [i_cv_field_tm_gmtoff=yes], |
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
954 [i_cv_field_tm_gmtoff=no])]) |
0 | 955 if test $i_cv_field_tm_gmtoff = yes; then |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
956 AC_DEFINE(HAVE_TM_GMTOFF,, Define if you have struct tm->tm_gmtoff) |
0 | 957 fi |
958 AC_MSG_RESULT($i_cv_field_tm_gmtoff) | |
959 | |
1658
20519e4bca48
utc_mktime() crashed with 64bit time_t if gmtime() didn't like >32bit values
Timo Sirainen <tss@iki.fi>
parents:
1656
diff
changeset
|
960 dnl * how large time_t values does gmtime() accept? |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
961 AC_CACHE_CHECK([how large time_t values gmtime() accepts],i_cv_gmtime_max_time_t,[ |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
962 AC_RUN_IFELSE([AC_LANG_SOURCE([[ |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
963 #include <stdio.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
964 #include <time.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
965 int main() { |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
966 FILE *f; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
967 int bits; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
968 |
6522
6c46542a5ce5
With 32bit time_t we were checking it up to 64 bits, which overflowed the
Timo Sirainen <tss@iki.fi>
parents:
6501
diff
changeset
|
969 for (bits = 1; bits < sizeof(time_t)*8; bits++) { |
6483
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
970 time_t t = ((time_t)1 << bits) - 1; |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
971 if (gmtime(&t) == NULL) { |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
972 bits--; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
973 break; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
974 } |
1658
20519e4bca48
utc_mktime() crashed with 64bit time_t if gmtime() didn't like >32bit values
Timo Sirainen <tss@iki.fi>
parents:
1656
diff
changeset
|
975 } |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
976 if (bits > 40) { |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
977 /* Solaris 9 breaks after 55 bits. Perhaps other systems break earlier. |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
978 Let's just do the same as Cyrus folks and limit it to 40 bits. */ |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
979 bits = 40; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
980 } |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
981 |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
982 f = fopen("conftest.temp", "w"); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
983 if (f == NULL) { |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
984 perror("fopen()"); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
985 return 1; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
986 } |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
987 fprintf(f, "%d", bits); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
988 fclose(f); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
989 return 0; |
3206 | 990 } |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
991 ]])],[ |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
992 i_cv_gmtime_max_time_t=`cat conftest.temp` |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
993 rm -f conftest.temp |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
994 ], [ |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
995 printf "check failed, assuming " |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
996 i_cv_gmtime_max_time_t=31 |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
997 ],[]) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
998 ]) |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
999 AC_DEFINE_UNQUOTED(TIME_T_MAX_BITS, $i_cv_gmtime_max_time_t, max. time_t bits gmtime() can handle) |
1658
20519e4bca48
utc_mktime() crashed with 64bit time_t if gmtime() didn't like >32bit values
Timo Sirainen <tss@iki.fi>
parents:
1656
diff
changeset
|
1000 |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1001 AC_CACHE_CHECK([whether time_t is signed],i_cv_signed_time_t,[ |
6483
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
1002 AC_RUN_IFELSE([AC_LANG_SOURCE([[ |
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
1003 #include <sys/types.h> |
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
1004 int main() { |
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
1005 /* return 0 if we're signed */ |
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
1006 exit((time_t)(int)-1 <= 0 ? 0 : 1); |
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
1007 } |
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
1008 ]])],[ |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1009 i_cv_signed_time_t=yes |
6483
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
1010 ], [ |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1011 i_cv_signed_time_t=no |
6483
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
1012 ]) |
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
1013 ]) |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1014 if test $i_cv_signed_time_t = yes; then |
6483
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
1015 AC_DEFINE(TIME_T_SIGNED,, Define if your time_t is signed) |
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
1016 fi |
6d15946eccb5
Rewrote utc_mktime() so it's now MIT licensed. This also fixes handling
Timo Sirainen <tss@iki.fi>
parents:
6403
diff
changeset
|
1017 |
7997
0d66b44689ee
Fixed compiling on some older pre-C99 compilers.
Timo Sirainen <tss@iki.fi>
parents:
7990
diff
changeset
|
1018 dnl Our implementation of AC_C_FLEXIBLE_ARRAY_MEMBER. |
0d66b44689ee
Fixed compiling on some older pre-C99 compilers.
Timo Sirainen <tss@iki.fi>
parents:
7990
diff
changeset
|
1019 dnl Use it until autoconf 2.61+ becomes more widely used |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1020 AC_CACHE_CHECK([if we can use C99-like flexible array members],i_cv_c99_flex_arrays,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1021 AC_TRY_COMPILE([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1022 struct foo { |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1023 int x; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1024 char y[]; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1025 }; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1026 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1027 struct foo foo; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1028 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1029 i_cv_c99_flex_arrays=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1030 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1031 i_cv_c99_flex_arrays=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1032 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1033 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1034 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1035 if test $i_cv_c99_flex_arrays = yes; then |
10094
634588d51ae6
configure: FLEXIBLE_ARRAY_MEMBER value was reversed.
Timo Sirainen <tss@iki.fi>
parents:
10091
diff
changeset
|
1036 flexible_value= |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1037 else |
10094
634588d51ae6
configure: FLEXIBLE_ARRAY_MEMBER value was reversed.
Timo Sirainen <tss@iki.fi>
parents:
10091
diff
changeset
|
1038 flexible_value=1 |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1039 fi |
7997
0d66b44689ee
Fixed compiling on some older pre-C99 compilers.
Timo Sirainen <tss@iki.fi>
parents:
7990
diff
changeset
|
1040 AC_DEFINE_UNQUOTED(FLEXIBLE_ARRAY_MEMBER, $flexible_value, How to define flexible array members in structs) |
0d66b44689ee
Fixed compiling on some older pre-C99 compilers.
Timo Sirainen <tss@iki.fi>
parents:
7990
diff
changeset
|
1041 |
411 | 1042 dnl * do we have struct iovec |
1043 AC_MSG_CHECKING([for struct iovec]) | |
1044 AC_CACHE_VAL(i_cv_struct_iovec, | |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1045 [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
411 | 1046 #include <sys/types.h> |
1047 #include <sys/uio.h> | |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1048 #include <unistd.h>]], |
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1049 [[struct iovec *iovec;]])], |
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1050 [i_cv_struct_iovec=yes], |
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1051 [i_cv_struct_iovec=no])]) |
411 | 1052 |
1053 if test $i_cv_struct_iovec = yes; then | |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
1054 AC_DEFINE(HAVE_STRUCT_IOVEC,, Define if you have struct iovec) |
411 | 1055 fi |
1056 AC_MSG_RESULT($i_cv_struct_iovec) | |
1057 | |
691
567f5e66c7b8
We compile now if dev_t is a structure (eg. glibc+tcc).
Timo Sirainen <tss@iki.fi>
parents:
679
diff
changeset
|
1058 dnl * is dev_t an integer or something else? |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1059 AC_CACHE_CHECK([whether dev_t is struct],i_cv_dev_t_struct,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1060 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1061 #include <sys/types.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1062 struct test { dev_t a; }; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1063 static struct test t = { 0 }; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1064 ]], |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1065 [[ ]])], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1066 i_cv_dev_t_struct=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1067 ],[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1068 i_cv_dev_t_struct=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1069 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1070 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1071 if test $i_cv_dev_t_struct = yes; then |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
1072 AC_DEFINE(DEV_T_STRUCT,, Define if your dev_t is a structure instead of integer type) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1073 fi |
691
567f5e66c7b8
We compile now if dev_t is a structure (eg. glibc+tcc).
Timo Sirainen <tss@iki.fi>
parents:
679
diff
changeset
|
1074 |
739
f50714973d0b
RLIMIT_AS isn't supported everywhere - use it if it exists, but also use
Timo Sirainen <tss@iki.fi>
parents:
733
diff
changeset
|
1075 dnl * Do we have RLIMIT_AS? |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1076 AC_CACHE_CHECK([whether RLIMIT_AS exists],i_cv_have_rlimit_as,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1077 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1078 #include <sys/types.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1079 #include <sys/time.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1080 #include <sys/resource.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1081 ]], [[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1082 struct rlimit r; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1083 getrlimit(RLIMIT_AS, &r); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1084 ]])],[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1085 i_cv_have_rlimit_as=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1086 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1087 i_cv_have_rlimit_as=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1088 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1089 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1090 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1091 if test $i_cv_have_rlimit_as = yes; then |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
1092 AC_DEFINE(HAVE_RLIMIT_AS,, Define if you have RLIMIT_AS for setrlimit()) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1093 fi |
739
f50714973d0b
RLIMIT_AS isn't supported everywhere - use it if it exists, but also use
Timo Sirainen <tss@iki.fi>
parents:
733
diff
changeset
|
1094 |
1065 | 1095 dnl * Do we have RLIMIT_NPROC? |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1096 AC_CACHE_CHECK([whether RLIMIT_NPROC exists],i_cv_have_rlimit_nproc,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1097 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1098 #include <sys/types.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1099 #include <sys/time.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1100 #include <sys/resource.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1101 ]], [[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1102 struct rlimit r; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1103 getrlimit(RLIMIT_NPROC, &r); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1104 ]])],[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1105 i_cv_have_rlimit_nproc=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1106 ],[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1107 i_cv_have_rlimit_nproc=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1108 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1109 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1110 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1111 if test $i_cv_have_rlimit_nproc = yes; then |
1065 | 1112 AC_DEFINE(HAVE_RLIMIT_NPROC,, Define if you have RLIMIT_NPROC for setrlimit()) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1113 fi |
1065 | 1114 |
7946
aad49536db41
If core dump limit is 0, add "core dumps disabled" to startup log line.
Timo Sirainen <tss@iki.fi>
parents:
7929
diff
changeset
|
1115 dnl * Do we have RLIMIT_CORE? |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1116 AC_CACHE_CHECK([whether RLIMIT_CORE exists],i_cv_have_rlimit_core,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1117 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1118 #include <sys/types.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1119 #include <sys/time.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1120 #include <sys/resource.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1121 ]], [[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1122 struct rlimit r; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1123 getrlimit(RLIMIT_CORE, &r); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1124 ]])],[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1125 i_cv_have_rlimit_core=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1126 ],[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1127 i_cv_have_rlimit_core=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1128 ]) |
8798
c9381a0fdc5e
Improved logging for core dumping. With Linux use PR_SET_DUMPABLE for imap/pop3.
Timo Sirainen <tss@iki.fi>
parents:
8743
diff
changeset
|
1129 ]) |
c9381a0fdc5e
Improved logging for core dumping. With Linux use PR_SET_DUMPABLE for imap/pop3.
Timo Sirainen <tss@iki.fi>
parents:
8743
diff
changeset
|
1130 |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1131 if test $i_cv_have_rlimit_core = yes; then |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1132 AC_DEFINE(HAVE_RLIMIT_CORE,, Define if you have RLIMIT_CORE for getrlimit()) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1133 fi |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1134 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1135 AC_CACHE_CHECK([whether PR_SET_DUMPABLE exists],i_cv_have_pr_set_dumpable,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1136 AC_TRY_LINK([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1137 #include <sys/prctl.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1138 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1139 prctl(PR_SET_DUMPABLE, 1, 0, 0, 0); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1140 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1141 i_cv_have_pr_set_dumpable=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1142 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1143 i_cv_have_pr_set_dumpable=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1144 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1145 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1146 if test $i_cv_have_pr_set_dumpable = yes; then |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1147 AC_DEFINE(HAVE_PR_SET_DUMPABLE,, Define if you have prctl(PR_SET_DUMPABLE)) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1148 fi |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1149 |
528
a95b1ccff82e
Support FreeBSD-compatible sendfile(). Completely untested.
Timo Sirainen <tss@iki.fi>
parents:
494
diff
changeset
|
1150 dnl * Linux compatible mremap() |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1151 AC_CACHE_CHECK([Linux compatible mremap()],i_cv_have_linux_mremap,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1152 AC_TRY_LINK([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1153 #include <unistd.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1154 #define __USE_GNU |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1155 #include <sys/mman.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1156 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1157 mremap(0, 0, 0, MREMAP_MAYMOVE); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1158 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1159 i_cv_have_linux_mremap=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1160 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1161 i_cv_have_linux_mremap=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1162 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1163 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1164 if test $i_cv_have_linux_mremap = yes; then |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
1165 AC_DEFINE(HAVE_LINUX_MREMAP,, Define if you have Linux-compatible mremap()) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1166 fi |
224 | 1167 |
1622
d22e03714d36
index_mmap_invalidate = yes now invalidate memory maps before accessing
Timo Sirainen <tss@iki.fi>
parents:
1611
diff
changeset
|
1168 dnl * If mmap() plays nicely with write() |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1169 AC_CACHE_CHECK([whether shared mmaps get updated by write()s],i_cv_mmap_plays_with_write,[ |
2349
b65456de1b49
Check BUGGY_CMSG_MACROS in configure.
Timo Sirainen <tss@iki.fi>
parents:
2325
diff
changeset
|
1170 AC_TRY_RUN([ |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1171 #include <stdio.h> |
2349
b65456de1b49
Check BUGGY_CMSG_MACROS in configure.
Timo Sirainen <tss@iki.fi>
parents:
2325
diff
changeset
|
1172 #include <sys/types.h> |
b65456de1b49
Check BUGGY_CMSG_MACROS in configure.
Timo Sirainen <tss@iki.fi>
parents:
2325
diff
changeset
|
1173 #include <sys/stat.h> |
b65456de1b49
Check BUGGY_CMSG_MACROS in configure.
Timo Sirainen <tss@iki.fi>
parents:
2325
diff
changeset
|
1174 #include <unistd.h> |
b65456de1b49
Check BUGGY_CMSG_MACROS in configure.
Timo Sirainen <tss@iki.fi>
parents:
2325
diff
changeset
|
1175 #include <fcntl.h> |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1176 #include <sys/mman.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1177 int main() { |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1178 /* return 0 if we're signed */ |
8226
3e493fd3a9fa
configure: create test files with mode 0600.
Timo Sirainen <tss@iki.fi>
parents:
8173
diff
changeset
|
1179 int f = open("conftest.mmap", O_RDWR|O_CREAT|O_TRUNC, 0600); |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1180 void *mem; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1181 if (f == -1) { |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1182 perror("open()"); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1183 return 1; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1184 } |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1185 unlink("conftest.mmap"); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1186 |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1187 write(f, "1", 2); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1188 mem = mmap(NULL, 2, PROT_READ|PROT_WRITE, MAP_SHARED, f, 0); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1189 if (mem == MAP_FAILED) { |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1190 perror("mmap()"); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1191 return 1; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1192 } |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1193 strcpy(mem, "2"); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1194 msync(mem, 2, MS_SYNC); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1195 lseek(f, 0, SEEK_SET); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1196 write(f, "3", 2); |
2349
b65456de1b49
Check BUGGY_CMSG_MACROS in configure.
Timo Sirainen <tss@iki.fi>
parents:
2325
diff
changeset
|
1197 |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1198 return strcmp(mem, "3") == 0 ? 0 : 1; |
2349
b65456de1b49
Check BUGGY_CMSG_MACROS in configure.
Timo Sirainen <tss@iki.fi>
parents:
2325
diff
changeset
|
1199 } |
b65456de1b49
Check BUGGY_CMSG_MACROS in configure.
Timo Sirainen <tss@iki.fi>
parents:
2325
diff
changeset
|
1200 ], [ |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1201 i_cv_mmap_plays_with_write=yes |
2349
b65456de1b49
Check BUGGY_CMSG_MACROS in configure.
Timo Sirainen <tss@iki.fi>
parents:
2325
diff
changeset
|
1202 ], [ |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1203 i_cv_mmap_plays_with_write=no |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1204 ]) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1205 ]) |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1206 if test $i_cv_mmap_plays_with_write = no; then |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1207 AC_DEFINE(MMAP_CONFLICTS_WRITE,, [Define if shared mmaps don't get updated by write()s]) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1208 fi |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1209 |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1210 dnl * see if fd passing works |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1211 AC_CACHE_CHECK([whether fd passing works],i_cv_fd_passing,[ |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1212 for i in 1 2; do |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1213 old_cflags="$CFLAGS" |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1214 CFLAGS="$CFLAGS -I$srcdir/src/lib $srcdir/src/lib/fdpass.c" |
2349
b65456de1b49
Check BUGGY_CMSG_MACROS in configure.
Timo Sirainen <tss@iki.fi>
parents:
2325
diff
changeset
|
1215 if test $i = 2; then |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1216 CFLAGS="$CFLAGS -DBUGGY_CMSG_MACROS" |
2349
b65456de1b49
Check BUGGY_CMSG_MACROS in configure.
Timo Sirainen <tss@iki.fi>
parents:
2325
diff
changeset
|
1217 fi |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1218 |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1219 AC_TRY_RUN([ |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1220 #include <sys/types.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1221 #include <sys/socket.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1222 #include <sys/wait.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1223 #include <sys/stat.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1224 #include <unistd.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1225 #include <fcntl.h> |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1226 #include "fdpass.h" |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1227 |
8578
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1228 int nopen(void) |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1229 { |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1230 int i, n; |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1231 struct stat sb; |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1232 for (i = n = 0; i < 256; i++) |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1233 if (fstat(i, &sb) == 0) n++; |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1234 return n; |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1235 } |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1236 int main(void) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1237 { |
8578
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1238 int fd[2], send_fd, recv_fd, status, n1, n2; |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1239 struct stat st, st2; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1240 char data; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1241 |
8226
3e493fd3a9fa
configure: create test files with mode 0600.
Timo Sirainen <tss@iki.fi>
parents:
8173
diff
changeset
|
1242 send_fd = creat("conftest.fdpass", 0600); |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1243 if (send_fd == -1) return 2; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1244 unlink("conftest.fdpass"); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1245 if (fstat(send_fd, &st) < 0) return 2; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1246 if (socketpair(AF_UNIX, SOCK_STREAM, 0, fd) < 0) return 2; |
8578
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1247 n1 = nopen(); |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1248 |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1249 switch (fork()) { |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1250 case -1: |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1251 return 2; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1252 case 0: |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1253 alarm(1); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1254 if (fd_send(fd[0], send_fd, &data, 1) != 1) return 2; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1255 return 0; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1256 default: |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1257 alarm(2); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1258 if (wait(&status) == -1) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1259 return 2; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1260 if (status != 0) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1261 return status; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1262 if (fd_read(fd[1], &data, 1, &recv_fd) != 1) return 1; |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1263 if (fstat(recv_fd, &st2) < 0) return 2; |
8578
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1264 /* nopen check is for making sure that only a single fd |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1265 was received */ |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1266 n2 = nopen(); |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1267 return st.st_ino == st2.st_ino && n2 == n1 + 1 ? 0 : 1; |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1268 } |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1269 } |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1270 ], [ |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1271 CFLAGS=$old_cflags |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1272 if test $i = 2; then |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1273 i_cv_fd_passing=buggy_cmsg_macros |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1274 else |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1275 i_cv_fd_passing=yes |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1276 fi |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1277 break |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1278 ], [ |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1279 dnl no, try with BUGGY_CMSG_MACROS |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1280 CFLAGS=$old_cflags |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1281 i_cv_fd_passing=no |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1282 ]) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1283 done |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1284 ]); |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1285 |
8578
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1286 case "$host_os" in |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1287 darwin[[1-9]].*) |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1288 if test "$i_cv_fd_passing" = "yes"; then |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1289 i_cv_fd_passing=buggy_cmsg_macros |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1290 fi |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1291 ;; |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1292 esac |
729576bb91d8
Some versions of Mac OS X have buggy CMSG_* macros, avoid using them.
Timo Sirainen <tss@iki.fi>
parents:
8572
diff
changeset
|
1293 |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1294 if test $i_cv_fd_passing = buggy_cmsg_macros; then |
5165
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1295 AC_DEFINE(BUGGY_CMSG_MACROS,, Define if you have buggy CMSG macros) |
04bdc7c83854
Added AC_CACHE_CHECK()s to all AC_TRY_RUN and AC_RUN_IFELSE checks so that
Timo Sirainen <tss@iki.fi>
parents:
5103
diff
changeset
|
1296 fi |
1622
d22e03714d36
index_mmap_invalidate = yes now invalidate memory maps before accessing
Timo Sirainen <tss@iki.fi>
parents:
1611
diff
changeset
|
1297 |
2035
0e65efd14eda
Solaris: Move from sendfilev() to sendfile() (was it always there?). Make
Timo Sirainen <tss@iki.fi>
parents:
2028
diff
changeset
|
1298 dnl * Solaris compatible sendfile() |
0e65efd14eda
Solaris: Move from sendfilev() to sendfile() (was it always there?). Make
Timo Sirainen <tss@iki.fi>
parents:
2028
diff
changeset
|
1299 AC_CHECK_LIB(sendfile, sendfile, [ |
976
b3e0f857981c
Support for Solaris sendfilev(). Entirely untested, hope it works.
Timo Sirainen <tss@iki.fi>
parents:
975
diff
changeset
|
1300 LIBS="$LIBS -lsendfile" |
2035
0e65efd14eda
Solaris: Move from sendfilev() to sendfile() (was it always there?). Make
Timo Sirainen <tss@iki.fi>
parents:
2028
diff
changeset
|
1301 AC_DEFINE(HAVE_SOLARIS_SENDFILE,, Define if you have Solaris-compatible sendfile()) |
976
b3e0f857981c
Support for Solaris sendfilev(). Entirely untested, hope it works.
Timo Sirainen <tss@iki.fi>
parents:
975
diff
changeset
|
1302 ], [ |
981
7e9b90bfe78c
If Solaris sendfilev() is found, don't try checking for Linux one. Linux
Timo Sirainen <tss@iki.fi>
parents:
976
diff
changeset
|
1303 dnl * Linux compatible sendfile() - don't check if Solaris one was found. |
7e9b90bfe78c
If Solaris sendfilev() is found, don't try checking for Linux one. Linux
Timo Sirainen <tss@iki.fi>
parents:
976
diff
changeset
|
1304 dnl * This seems to pass with Solaris for some reason.. |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1305 AC_CACHE_CHECK([Linux compatible sendfile()],i_cv_have_linux_sendfile,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1306 AC_TRY_LINK([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1307 #undef _FILE_OFFSET_BITS |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1308 #include <sys/types.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1309 #include <sys/socket.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1310 #include <sys/sendfile.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1311 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1312 sendfile(0, 0, (void *) 0, 0); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1313 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1314 i_cv_have_linux_sendfile=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1315 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1316 i_cv_have_linux_sendfile=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1317 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1318 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1319 if test $i_cv_have_linux_sendfile = yes; then |
981
7e9b90bfe78c
If Solaris sendfilev() is found, don't try checking for Linux one. Linux
Timo Sirainen <tss@iki.fi>
parents:
976
diff
changeset
|
1320 AC_DEFINE(HAVE_LINUX_SENDFILE,, Define if you have Linux-compatible sendfile()) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1321 fi |
981
7e9b90bfe78c
If Solaris sendfilev() is found, don't try checking for Linux one. Linux
Timo Sirainen <tss@iki.fi>
parents:
976
diff
changeset
|
1322 |
7e9b90bfe78c
If Solaris sendfilev() is found, don't try checking for Linux one. Linux
Timo Sirainen <tss@iki.fi>
parents:
976
diff
changeset
|
1323 dnl * FreeBSD compatible sendfile() |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1324 AC_CACHE_CHECK([FreeBSD compatible sendfile()],i_cv_have_freebsd_sendfile,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1325 AC_TRY_LINK([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1326 #include <sys/types.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1327 #include <sys/socket.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1328 #include <sys/uio.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1329 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1330 struct sf_hdtr hdtr; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1331 sendfile(0, 0, 0, 0, &hdtr, (void *) 0, 0); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1332 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1333 i_cv_have_freebsd_sendfile=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1334 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1335 i_cv_have_freebsd_sendfile=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1336 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1337 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1338 if test $i_cv_have_freebsd_sendfile = yes; then |
981
7e9b90bfe78c
If Solaris sendfilev() is found, don't try checking for Linux one. Linux
Timo Sirainen <tss@iki.fi>
parents:
976
diff
changeset
|
1339 AC_DEFINE(HAVE_FREEBSD_SENDFILE,, Define if you have FreeBSD-compatible sendfile()) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1340 fi |
976
b3e0f857981c
Support for Solaris sendfilev(). Entirely untested, hope it works.
Timo Sirainen <tss@iki.fi>
parents:
975
diff
changeset
|
1341 ]) |
b3e0f857981c
Support for Solaris sendfilev(). Entirely untested, hope it works.
Timo Sirainen <tss@iki.fi>
parents:
975
diff
changeset
|
1342 |
10491
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1343 AC_CACHE_CHECK([if unsetenv returns int],i_cv_unsetenv_ret_int,[ |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1344 AC_TRY_COMPILE([ |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1345 #include <stdlib.h> |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1346 ], [ |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1347 if (unsetenv("env") < 0) ; |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1348 ], [ |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1349 i_cv_unsetenv_ret_int=yes |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1350 ], [ |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1351 i_cv_unsetenv_ret_int=no |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1352 ]) |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1353 ]) |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1354 if test $i_cv_unsetenv_ret_int = yes; then |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1355 AC_DEFINE(UNSETENV_RET_INT,, Define if unsetenv() returns int) |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1356 fi |
617fa0739538
Compile fix for systems where unsetenv() returns void.
Timo Sirainen <tss@iki.fi>
parents:
10489
diff
changeset
|
1357 |
3590
340e1b87c27b
Added check for _XPG6 macro for crypt().
Timo Sirainen <tss@iki.fi>
parents:
3575
diff
changeset
|
1358 dnl * Check for crypt() if unistd.h compiles with _XOPEN_SOURCE + _XPG6 |
340e1b87c27b
Added check for _XPG6 macro for crypt().
Timo Sirainen <tss@iki.fi>
parents:
3575
diff
changeset
|
1359 dnl * Add other macros there too "just in case". |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1360 AC_CACHE_CHECK([if we should use _XPG6 macro for crypt()],i_cv_use_xpg6_crypt,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1361 AC_TRY_COMPILE([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1362 #define _XOPEN_SOURCE 4 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1363 #define _XOPEN_SOURCE_EXTENDED 1 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1364 #define _XOPEN_VERSION 4 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1365 #define _XPG4_2 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1366 #define _XPG6 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1367 #include <unistd.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1368 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1369 crypt("a", "b"); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1370 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1371 i_cv_use_xpg6_crypt=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1372 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1373 i_cv_use_xpg6_crypt=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1374 ]) |
3590
340e1b87c27b
Added check for _XPG6 macro for crypt().
Timo Sirainen <tss@iki.fi>
parents:
3575
diff
changeset
|
1375 ]) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1376 if test $i_cv_use_xpg6_crypt = yes; then |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1377 AC_DEFINE(CRYPT_USE_XPG6,, Define if _XPG6 macro is needed for crypt()) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1378 fi |
7526
a957567706ec
Replaced HAVE_ST_NSEC macro checks with more generic ST_?TIME_NSEC() macros
Timo Sirainen <tss@iki.fi>
parents:
7502
diff
changeset
|
1379 |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1380 AC_CACHE_CHECK([if struct stat has st_?tim timespec fields],i_cv_have_st_tim_timespec,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1381 AC_TRY_COMPILE([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1382 #include <sys/types.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1383 #include <sys/stat.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1384 #include <unistd.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1385 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1386 struct stat st; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1387 unsigned long x = st.st_mtim.tv_nsec; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1388 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1389 return 0; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1390 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1391 i_cv_have_st_tim_timespec=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1392 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1393 i_cv_have_st_tim_timespec=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1394 ]) |
5375
94f043494a12
Check if struct stat has tv_nsec fields
Timo Sirainen <tss@iki.fi>
parents:
5359
diff
changeset
|
1395 ]) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1396 if test $i_cv_have_st_tim_timespec = yes; then |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1397 AC_DEFINE(HAVE_STAT_XTIM,, Define if you have st_?tim timespec fields in struct stat) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1398 fi |
5375
94f043494a12
Check if struct stat has tv_nsec fields
Timo Sirainen <tss@iki.fi>
parents:
5359
diff
changeset
|
1399 |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1400 AC_CACHE_CHECK([if struct stat has st_?timespec fields],i_cv_have_st_timespec,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1401 AC_TRY_COMPILE([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1402 #include <sys/types.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1403 #include <sys/stat.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1404 #include <unistd.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1405 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1406 struct stat st; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1407 unsigned long x = st.st_mtimespec.tv_nsec; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1408 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1409 return 0; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1410 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1411 i_cv_have_st_timespec=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1412 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1413 i_cv_have_st_timespec=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1414 ]) |
4736
6789961fe02e
Added support for statvfs(), which is what the newer BSDs use.
Timo Sirainen <tss@iki.fi>
parents:
4645
diff
changeset
|
1415 ]) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1416 if test $i_cv_have_st_timespec = yes; then |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1417 AC_DEFINE(HAVE_STAT_XTIMESPEC,, Define if you have st_?timespec fields in struct stat) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1418 fi |
4736
6789961fe02e
Added support for statvfs(), which is what the newer BSDs use.
Timo Sirainen <tss@iki.fi>
parents:
4645
diff
changeset
|
1419 |
6789961fe02e
Added support for statvfs(), which is what the newer BSDs use.
Timo Sirainen <tss@iki.fi>
parents:
4645
diff
changeset
|
1420 dnl * Check if statvfs() can be used to find out block device for files |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1421 AC_CACHE_CHECK([if statvfs.f_mntfromname exists],i_cv_have_statvfs_f_mntfromname,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1422 AC_TRY_COMPILE([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1423 #include <sys/types.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1424 #include <sys/statvfs.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1425 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1426 struct statvfs buf; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1427 char *p = buf.f_mntfromname; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1428 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1429 statvfs(".", &buf); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1430 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1431 i_cv_have_statvfs_f_mntfromname=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1432 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1433 i_cv_have_statvfs_f_mntfromname=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1434 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1435 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1436 if test $i_cv_have_statvfs_f_mntfromname = yes; then |
4736
6789961fe02e
Added support for statvfs(), which is what the newer BSDs use.
Timo Sirainen <tss@iki.fi>
parents:
4645
diff
changeset
|
1437 AC_DEFINE(HAVE_STATVFS_MNTFROMNAME,, Define if you have statvfs.f_mntfromname) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1438 fi |
4736
6789961fe02e
Added support for statvfs(), which is what the newer BSDs use.
Timo Sirainen <tss@iki.fi>
parents:
4645
diff
changeset
|
1439 |
3745
840cc63e439b
Don't allow giving invalid notify methods in --with-notify
Timo Sirainen <tss@iki.fi>
parents:
3744
diff
changeset
|
1440 dnl * Check if statfs() can be used to find out block device for files |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1441 AC_CACHE_CHECK([if statfs.f_mntfromname exists],i_cv_have_statfs_f_mntfromname,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1442 AC_TRY_COMPILE([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1443 #include <sys/param.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1444 #include <sys/mount.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1445 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1446 struct statfs buf; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1447 char *p = buf.f_mntfromname; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1448 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1449 statfs(".", &buf); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1450 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1451 i_cv_have_statfs_f_mntfromname=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1452 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1453 i_cv_have_statfs_f_mntfromname=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1454 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1455 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1456 if test $i_cv_have_statfs_f_mntfromname = yes; then |
3745
840cc63e439b
Don't allow giving invalid notify methods in --with-notify
Timo Sirainen <tss@iki.fi>
parents:
3744
diff
changeset
|
1457 AC_DEFINE(HAVE_STATFS_MNTFROMNAME,, Define if you have statfs.f_mntfromname) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1458 fi |
3745
840cc63e439b
Don't allow giving invalid notify methods in --with-notify
Timo Sirainen <tss@iki.fi>
parents:
3744
diff
changeset
|
1459 |
4552
ef71b2fdd433
Put back specific checks for struct dqblk.dqb_curblocks vs curspace. The
Timo Sirainen <tss@iki.fi>
parents:
4551
diff
changeset
|
1460 dnl * Check if we have struct dqblk.dqb_curblocks |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1461 AC_CACHE_CHECK([if struct dqblk.dqb_curblocks exists],i_cv_have_dqblk_dqb_curblocks,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1462 AC_TRY_COMPILE([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1463 #include <sys/types.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1464 #include "$srcdir/src/plugins/quota/quota-fs.h" |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1465 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1466 struct dqblk dqblk; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1467 unsigned int x = dqblk.dqb_curblocks; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1468 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1469 i_cv_have_dqblk_dqb_curblocks=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1470 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1471 i_cv_have_dqblk_dqb_curblocks=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1472 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1473 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1474 if test $i_cv_have_dqblk_dqb_curblocks = yes; then |
4552
ef71b2fdd433
Put back specific checks for struct dqblk.dqb_curblocks vs curspace. The
Timo Sirainen <tss@iki.fi>
parents:
4551
diff
changeset
|
1475 AC_DEFINE(HAVE_STRUCT_DQBLK_CURBLOCKS,, Define if struct sqblk.dqb_curblocks exists) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1476 fi |
4552
ef71b2fdd433
Put back specific checks for struct dqblk.dqb_curblocks vs curspace. The
Timo Sirainen <tss@iki.fi>
parents:
4551
diff
changeset
|
1477 |
ef71b2fdd433
Put back specific checks for struct dqblk.dqb_curblocks vs curspace. The
Timo Sirainen <tss@iki.fi>
parents:
4551
diff
changeset
|
1478 dnl * Check if we have struct dqblk.dqb_curspace |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1479 AC_CACHE_CHECK([if struct dqblk.dqb_curspace exists],i_cv_have_dqblk_dqb_curspace,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1480 AC_TRY_COMPILE([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1481 #include <sys/types.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1482 #include "$srcdir/src/plugins/quota/quota-fs.h" |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1483 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1484 struct dqblk dqblk; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1485 unsigned int x = dqblk.dqb_curspace; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1486 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1487 i_cv_have_dqblk_dqb_curspace=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1488 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1489 i_cv_have_dqblk_dqb_curspace=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1490 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1491 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1492 if test $i_cv_have_dqblk_dqb_curspace = yes; then |
4552
ef71b2fdd433
Put back specific checks for struct dqblk.dqb_curblocks vs curspace. The
Timo Sirainen <tss@iki.fi>
parents:
4551
diff
changeset
|
1493 AC_DEFINE(HAVE_STRUCT_DQBLK_CURSPACE,, Define if struct sqblk.dqb_curspace exists) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1494 fi |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1495 |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1496 dnl * Check if we have Q_QUOTACTL ioctl (Solaris) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1497 AC_CACHE_CHECK([if Q_QUOTACTL ioctl exists],i_cv_have_ioctl_q_quotactl,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1498 AC_TRY_COMPILE([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1499 #include <sys/types.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1500 #include <sys/fs/ufs_quota.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1501 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1502 struct quotctl ctl; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1503 ioctl(0, Q_QUOTACTL, &ctl); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1504 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1505 i_cv_have_ioctl_q_quotactl=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1506 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1507 i_cv_have_ioctl_q_quotactl=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1508 ]) |
4552
ef71b2fdd433
Put back specific checks for struct dqblk.dqb_curblocks vs curspace. The
Timo Sirainen <tss@iki.fi>
parents:
4551
diff
changeset
|
1509 ]) |
ef71b2fdd433
Put back specific checks for struct dqblk.dqb_curblocks vs curspace. The
Timo Sirainen <tss@iki.fi>
parents:
4551
diff
changeset
|
1510 |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1511 if test $i_cv_have_ioctl_q_quotactl = yes; then |
4063
f60237ad2edd
Support Solaris's ioctl(Q_QUOTACTL).
Timo Sirainen <tss@iki.fi>
parents:
4057
diff
changeset
|
1512 AC_DEFINE(HAVE_Q_QUOTACTL,, Define if Q_QUOTACTL exists) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
1513 fi |
4063
f60237ad2edd
Support Solaris's ioctl(Q_QUOTACTL).
Timo Sirainen <tss@iki.fi>
parents:
4057
diff
changeset
|
1514 |
859
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1515 dnl *** |
5681
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1516 dnl *** C99 vsnprintf()? |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1517 dnl *** |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1518 |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1519 AC_CACHE_CHECK([for C99 vsnprintf()],i_cv_c99_vsnprintf,[ |
5681
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1520 AC_RUN_IFELSE([AC_LANG_SOURCE([[ |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1521 #include <stdio.h> |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1522 #include <stdarg.h> |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1523 static int f(const char *fmt, ...) { |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1524 va_list args; |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1525 char buf[13]; |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1526 int ret; |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1527 |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1528 va_start(args, fmt); |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1529 ret = vsnprintf(buf, 11, fmt, args) != 12 || buf[11-1] != '\0'; |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1530 va_end(args); |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1531 return ret; |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1532 } |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1533 int main() { |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1534 return f("hello %s%d", "world", 1); |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1535 }]])], |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1536 [i_cv_c99_vsnprintf=yes], |
7850
7f9f7fc02359
Support systems with non-C99 vsnprintf().
Timo Sirainen <tss@iki.fi>
parents:
7847
diff
changeset
|
1537 [i_cv_c99_vsnprintf=no]) |
5681
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1538 ]) |
7555
47c5e52c1181
Prefix AC_CACHE_CHECK variables with i_cv_.
Timo Sirainen <tss@iki.fi>
parents:
7554
diff
changeset
|
1539 if test $i_cv_c99_vsnprintf = no; then |
7850
7f9f7fc02359
Support systems with non-C99 vsnprintf().
Timo Sirainen <tss@iki.fi>
parents:
7847
diff
changeset
|
1540 AC_DEFINE(HAVE_OLD_VSNPRINTF,, Define if you don't have C99 compatible vsnprintf() call) |
5681
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1541 fi |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1542 |
09415e6a0892
Require C99 compatible vsnprintf(). Removed printf_string_upper_bound() and
Timo Sirainen <tss@iki.fi>
parents:
5633
diff
changeset
|
1543 dnl *** |
859
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1544 dnl *** va_copy checks (from GLIB) |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1545 dnl *** |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1546 |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1547 AC_CACHE_CHECK([for an implementation of va_copy()],lib_cv_va_copy,[ |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1548 AC_RUN_IFELSE([AC_LANG_SOURCE([[ |
859
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1549 #include <stdarg.h> |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1550 void f (int i, ...) { |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1551 va_list args1, args2; |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1552 va_start (args1, i); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1553 va_copy (args2, args1); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1554 if (va_arg (args2, int) != 42 || va_arg (args1, int) != 42) |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1555 exit (1); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1556 va_end (args1); va_end (args2); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1557 } |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1558 int main() { |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1559 f (0, 42); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1560 return 0; |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1561 }]])], |
859
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1562 [lib_cv_va_copy=yes], |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1563 [lib_cv_va_copy=no],[]) |
859
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1564 ]) |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1565 AC_CACHE_CHECK([for an implementation of __va_copy()],lib_cv___va_copy,[ |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1566 AC_RUN_IFELSE([AC_LANG_SOURCE([[ |
859
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1567 #include <stdarg.h> |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1568 void f (int i, ...) { |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1569 va_list args1, args2; |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1570 va_start (args1, i); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1571 __va_copy (args2, args1); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1572 if (va_arg (args2, int) != 42 || va_arg (args1, int) != 42) |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1573 exit (1); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1574 va_end (args1); va_end (args2); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1575 } |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1576 int main() { |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1577 f (0, 42); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1578 return 0; |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1579 }]])], |
859
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1580 [lib_cv___va_copy=yes], |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1581 [lib_cv___va_copy=no],[]) |
859
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1582 ]) |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1583 |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1584 if test "x$lib_cv_va_copy" = "xyes"; then |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1585 va_copy_func=va_copy |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1586 else if test "x$lib_cv___va_copy" = "xyes"; then |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1587 va_copy_func=__va_copy |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1588 fi |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1589 fi |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1590 |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1591 if test -n "$va_copy_func"; then |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1592 AC_DEFINE_UNQUOTED(VA_COPY,$va_copy_func,[A 'va_copy' style function]) |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1593 fi |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1594 |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1595 AC_CACHE_CHECK([whether va_lists can be copied by value],lib_cv_va_val_copy,[ |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1596 AC_RUN_IFELSE([AC_LANG_SOURCE([[ |
859
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1597 #include <stdarg.h> |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1598 void f (int i, ...) { |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1599 va_list args1, args2; |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1600 va_start (args1, i); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1601 args2 = args1; |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1602 if (va_arg (args2, int) != 42 || va_arg (args1, int) != 42) |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1603 exit (1); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1604 va_end (args1); va_end (args2); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1605 } |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1606 int main() { |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1607 f (0, 42); |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1608 return 0; |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1609 }]])], |
859
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1610 [lib_cv_va_val_copy=yes], |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
1611 [lib_cv_va_val_copy=no],[]) |
859
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1612 ]) |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1613 |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1614 if test "x$lib_cv_va_val_copy" = "xno"; then |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1615 AC_DEFINE(VA_COPY_AS_ARRAY,1, ['va_lists' cannot be copies as values]) |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1616 fi |
c4754c5770f3
We weren't using va_list properly, especially gcc/PowerPC didn't like it.
Timo Sirainen <tss@iki.fi>
parents:
850
diff
changeset
|
1617 |
7958
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1618 dnl * dynamic modules? |
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1619 have_modules=no |
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1620 AC_CHECK_FUNC(dlopen, [ |
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1621 have_modules=yes |
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1622 MODULE_LIBS="-export-dynamic" |
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1623 ], [ |
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1624 AC_CHECK_LIB(dl, dlopen, [ |
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1625 have_modules=yes |
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1626 MODULE_LIBS="-export-dynamic -ldl" |
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1627 DLLIB=-ldl |
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1628 ]) |
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1629 ]) |
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1630 |
0 | 1631 dnl ** |
8022
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1632 dnl ** AIX mntctl |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1633 dnl ** |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1634 |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1635 if test $ac_cv_header_sys_vmount_h = yes; then |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1636 AC_MSG_CHECKING([for reasonable mntctl buffer size]) |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1637 AC_RUN_IFELSE([AC_LANG_SOURCE([[ |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1638 #include <stdio.h> |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1639 #include <stdlib.h> |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1640 #include <sys/vmount.h> |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1641 int main() { |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1642 int size,count; char *m; |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1643 FILE *f=fopen("conftestval", "w"); |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1644 if (!f) exit(1); |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1645 if ((count=mntctl(MCTL_QUERY,sizeof(size),&size))!=0 || !(m=malloc(size)) || |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1646 (count=mntctl(MCTL_QUERY,size,m))<=0) exit(1); |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1647 fprintf(f, "%d\n",(size * (count + 5))/count & ~1); /* 5 mounts more */ |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1648 exit(0); |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1649 } |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1650 ]])],[ |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1651 size=`cat conftestval` |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1652 rm -f conftestval |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1653 AC_DEFINE_UNQUOTED(STATIC_MTAB_SIZE,$size, reasonable mntctl buffer size) |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1654 AC_MSG_RESULT($size) |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1655 ],[ |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1656 AC_MSG_RESULT(default) |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1657 ]) |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1658 fi |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1659 |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1660 |
d1da922a437d
mountpoint_get(): Added support for AIX support with mntctl().
Timo Sirainen <tss@iki.fi>
parents:
8008
diff
changeset
|
1661 dnl ** |
622 | 1662 dnl ** SSL |
0 | 1663 dnl ** |
1664 | |
623 | 1665 have_ssl=no |
1666 | |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1667 if test $want_openssl != no && test $have_ssl = no; then |
4049
2fa6dc0e0e27
Don't print error if pkg-config isn't found.
Timo Sirainen <tss@iki.fi>
parents:
4022
diff
changeset
|
1668 if pkg-config --exists openssl 2>/dev/null; then |
1565
97572a77243a
Check OpenSSL using pkg-config which at least redhat uses nowadays.
Timo Sirainen <tss@iki.fi>
parents:
1539
diff
changeset
|
1669 PKG_CHECK_MODULES(SSL, openssl) |
97572a77243a
Check OpenSSL using pkg-config which at least redhat uses nowadays.
Timo Sirainen <tss@iki.fi>
parents:
1539
diff
changeset
|
1670 CFLAGS="$CFLAGS $SSL_CFLAGS" |
97572a77243a
Check OpenSSL using pkg-config which at least redhat uses nowadays.
Timo Sirainen <tss@iki.fi>
parents:
1539
diff
changeset
|
1671 have_openssl=yes |
97572a77243a
Check OpenSSL using pkg-config which at least redhat uses nowadays.
Timo Sirainen <tss@iki.fi>
parents:
1539
diff
changeset
|
1672 else |
7958
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1673 # openssl 0.9.8 wants -ldl and it's required if there's only .a lib |
1565
97572a77243a
Check OpenSSL using pkg-config which at least redhat uses nowadays.
Timo Sirainen <tss@iki.fi>
parents:
1539
diff
changeset
|
1674 AC_CHECK_LIB(ssl, SSL_read, [ |
97572a77243a
Check OpenSSL using pkg-config which at least redhat uses nowadays.
Timo Sirainen <tss@iki.fi>
parents:
1539
diff
changeset
|
1675 AC_CHECK_HEADERS(openssl/ssl.h openssl/err.h, [ |
7958
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1676 SSL_LIBS="-lssl -lcrypto $DLLIB" |
1565
97572a77243a
Check OpenSSL using pkg-config which at least redhat uses nowadays.
Timo Sirainen <tss@iki.fi>
parents:
1539
diff
changeset
|
1677 AC_SUBST(SSL_LIBS) |
97572a77243a
Check OpenSSL using pkg-config which at least redhat uses nowadays.
Timo Sirainen <tss@iki.fi>
parents:
1539
diff
changeset
|
1678 have_openssl=yes |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1679 ], [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1680 if test $want_openssl = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1681 AC_ERROR([Can't build with OpenSSL: openssl/ssl.h or openssl/err.h not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1682 fi |
1565
97572a77243a
Check OpenSSL using pkg-config which at least redhat uses nowadays.
Timo Sirainen <tss@iki.fi>
parents:
1539
diff
changeset
|
1683 ]) |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1684 ], [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1685 if test $want_openssl = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1686 AC_ERROR([Can't build with OpenSSL: libssl not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1687 fi |
7958
adb7d13d7d97
When checking for -lssl, include -ldl if it exists. OpenSSL 0.9.8 uses it.
Timo Sirainen <tss@iki.fi>
parents:
7946
diff
changeset
|
1688 ], -lcrypto $DLLIB) |
1565
97572a77243a
Check OpenSSL using pkg-config which at least redhat uses nowadays.
Timo Sirainen <tss@iki.fi>
parents:
1539
diff
changeset
|
1689 fi |
1566 | 1690 if test "$have_openssl" = "yes"; then |
1691 AC_DEFINE(HAVE_OPENSSL,, Build with OpenSSL support) | |
1692 have_ssl="yes (OpenSSL)" | |
9973
ba12a404d3b3
Compiling fix for OpenSSL 0.9.7 and older.
Timo Sirainen <tss@iki.fi>
parents:
9942
diff
changeset
|
1693 |
ba12a404d3b3
Compiling fix for OpenSSL 0.9.7 and older.
Timo Sirainen <tss@iki.fi>
parents:
9942
diff
changeset
|
1694 AC_CHECK_LIB(ssl, SSL_get_current_compression, [ |
ba12a404d3b3
Compiling fix for OpenSSL 0.9.7 and older.
Timo Sirainen <tss@iki.fi>
parents:
9942
diff
changeset
|
1695 AC_DEFINE(HAVE_SSL_COMPRESSION,, Build with OpenSSL compression) |
ba12a404d3b3
Compiling fix for OpenSSL 0.9.7 and older.
Timo Sirainen <tss@iki.fi>
parents:
9942
diff
changeset
|
1696 ],, $SSL_LIBS) |
1566 | 1697 fi |
622 | 1698 fi |
1699 | |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1700 if test $want_gnutls != no && test $have_ssl = no; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1701 AC_CHECK_LIB(gnutls, gnutls_global_init, [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1702 AC_CHECK_HEADER(gnutls/gnutls.h, [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1703 AC_DEFINE(HAVE_GNUTLS,, Build with GNUTLS support) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1704 SSL_LIBS="-lgnutls -lgcrypt" |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1705 AC_SUBST(SSL_LIBS) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1706 have_ssl="yes (GNUTLS)" |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1707 have_gnutls=yes |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1708 ], [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1709 if test $want_gnutls = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1710 AC_ERROR([Can't build with GNUTLS: gnutls/gnutls.h not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1711 fi |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1712 ]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1713 ], [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1714 if test $want_gnutls = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1715 AC_ERROR([Can't build with GNUTLS: libgnutls not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1716 fi |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1717 ], -lgcrypt) |
1948 | 1718 fi |
1719 | |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
1720 if test "$have_ssl" != "no"; then |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
1721 AC_DEFINE(HAVE_SSL,, Build with SSL/TLS support) |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
1722 fi |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
1723 |
0 | 1724 dnl ** |
1786
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
1725 dnl ** Garbage Collector |
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
1726 dnl ** |
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
1727 |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1728 if test $want_gc != no; then |
1786
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
1729 AC_CHECK_LIB(gc, GC_malloc, [ |
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
1730 AC_CHECK_HEADERS(gc/gc.h gc.h) |
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
1731 AC_DEFINE(USE_GC,, Define if you want to use Boehm GC) |
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
1732 LIBS="$LIBS -lgc" |
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
1733 ], [ |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1734 if test $want_gc = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1735 AC_ERROR([Can't build with GC: libgc not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1736 fi |
1786
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
1737 ]) |
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
1738 fi |
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
1739 |
49b6103dd2e0
Added support for Boehm GC. However it seems to be crashing for some reason
Timo Sirainen <tss@iki.fi>
parents:
1729
diff
changeset
|
1740 dnl ** |
1043
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1741 dnl ** userdb and passdb checks |
0 | 1742 dnl ** |
1743 | |
1043
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1744 userdb="" |
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1745 passdb="" |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1746 not_userdb="" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1747 not_passdb="" |
1043
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1748 |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1749 if test $want_static_userdb != no; then |
1043
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1750 AC_DEFINE(USERDB_STATIC,, Build with static userdb support) |
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1751 userdb="$userdb static" |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1752 else |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1753 not_userdb="$not_userdb static" |
1043
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1754 fi |
0 | 1755 |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1756 if test $want_prefetch_userdb != no; then |
3667
b7569a6a4ada
Renamed userdb passdb to prefetch.
Timo Sirainen <tss@iki.fi>
parents:
3600
diff
changeset
|
1757 AC_DEFINE(USERDB_PREFETCH,, Build with prefetch userdb support) |
b7569a6a4ada
Renamed userdb passdb to prefetch.
Timo Sirainen <tss@iki.fi>
parents:
3600
diff
changeset
|
1758 userdb="$userdb prefetch" |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1759 else |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1760 not_userdb="$not_userdb prefetch" |
3062
5e2e4cdbfe2e
Added "passdb" userdb. It works only if passdb gives all the information
Timo Sirainen <tss@iki.fi>
parents:
3004
diff
changeset
|
1761 fi |
5e2e4cdbfe2e
Added "passdb" userdb. It works only if passdb gives all the information
Timo Sirainen <tss@iki.fi>
parents:
3004
diff
changeset
|
1762 |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1763 if test $want_passwd != no; then |
1043
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1764 AC_DEFINE(USERDB_PASSWD,, Build with passwd support) |
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1765 AC_DEFINE(PASSDB_PASSWD,, Build with passwd support) |
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1766 userdb="$userdb passwd" |
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1767 passdb="$passdb passwd" |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1768 else |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1769 not_passdb="$not_passdb passwd" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1770 not_userdb="$not_userdb passwd" |
0 | 1771 fi |
1772 | |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1773 if test $want_passwd_file != no; then |
1043
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1774 AC_DEFINE(USERDB_PASSWD_FILE,, Build with passwd-file support) |
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1775 AC_DEFINE(PASSDB_PASSWD_FILE,, Build with passwd-file support) |
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1776 userdb="$userdb passwd-file" |
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
1777 passdb="$passdb passwd-file" |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1778 else |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1779 not_passdb="$not_passdb passwd-file" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1780 not_userdb="$not_userdb passwd-file" |
0 | 1781 fi |
1782 | |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1783 have_shadow=no |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1784 if test $want_shadow != no; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1785 AC_CHECK_FUNC(getspnam, [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1786 AC_CHECK_HEADER(shadow.h, [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1787 AC_DEFINE(PASSDB_SHADOW,, Build with shadow support) |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1788 have_shadow=yes |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1789 ], [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1790 if test $want_shadow = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1791 AC_ERROR([Can't build with shadow support: shadow.h not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1792 fi |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1793 ]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1794 ], [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1795 if test $want_shadow = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1796 AC_ERROR([Can't build with shadow support: getspnam() not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1797 fi |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1798 ]) |
0 | 1799 fi |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1800 if test $have_shadow = no; then |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1801 not_passdb="$not_passdb shadow" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1802 else |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1803 passdb="$passdb shadow" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1804 fi |
0 | 1805 |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1806 if test $want_pam != no; then |
0 | 1807 AC_CHECK_LIB(pam, pam_start, [ |
706
df5bf4ee669f
OSX puts PAM includes into pam/ directory instead of security. Detect that.
Timo Sirainen <tss@iki.fi>
parents:
702
diff
changeset
|
1808 have_pam=no |
0 | 1809 AC_CHECK_HEADER(security/pam_appl.h, [ |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
1810 AC_DEFINE(HAVE_SECURITY_PAM_APPL_H,, |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
1811 Define if you have security/pam_appl.h) |
706
df5bf4ee669f
OSX puts PAM includes into pam/ directory instead of security. Detect that.
Timo Sirainen <tss@iki.fi>
parents:
702
diff
changeset
|
1812 have_pam=yes |
df5bf4ee669f
OSX puts PAM includes into pam/ directory instead of security. Detect that.
Timo Sirainen <tss@iki.fi>
parents:
702
diff
changeset
|
1813 ]) |
df5bf4ee669f
OSX puts PAM includes into pam/ directory instead of security. Detect that.
Timo Sirainen <tss@iki.fi>
parents:
702
diff
changeset
|
1814 |
df5bf4ee669f
OSX puts PAM includes into pam/ directory instead of security. Detect that.
Timo Sirainen <tss@iki.fi>
parents:
702
diff
changeset
|
1815 AC_CHECK_HEADER(pam/pam_appl.h, [ |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
1816 AC_DEFINE(HAVE_PAM_PAM_APPL_H,, |
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
1817 Define if you have pam/pam_appl.h) |
706
df5bf4ee669f
OSX puts PAM includes into pam/ directory instead of security. Detect that.
Timo Sirainen <tss@iki.fi>
parents:
702
diff
changeset
|
1818 have_pam=yes |
df5bf4ee669f
OSX puts PAM includes into pam/ directory instead of security. Detect that.
Timo Sirainen <tss@iki.fi>
parents:
702
diff
changeset
|
1819 ]) |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1820 ], [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1821 if test $want_pam = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1822 AC_ERROR([Can't build with PAM support: libpam not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1823 fi |
0 | 1824 ]) |
1825 fi | |
1826 | |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1827 if test "$have_pam" = "yes"; then |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1828 AUTH_LIBS="$AUTH_LIBS -lpam" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1829 AC_DEFINE(PASSDB_PAM,, Build with PAM support) |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1830 passdb="$passdb pam" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1831 |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1832 AC_CHECK_LIB(pam, pam_setcred, [ |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1833 AC_DEFINE(HAVE_PAM_SETCRED,, Define if you have pam_setcred()) |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1834 ]) |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1835 elif test $want_pam = yes; then |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1836 AC_ERROR([Can't build with PAM support: pam_appl.h not found]) |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1837 else |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1838 not_passdb="$not_passdb pam" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1839 fi |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1840 |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1841 if test $want_checkpassword != no; then |
2162
95b2a6abc01e
Added checkpassword passdb. userdb has only beginnings.
Timo Sirainen <tss@iki.fi>
parents:
2103
diff
changeset
|
1842 AC_DEFINE(PASSDB_CHECKPASSWORD,, Build with checkpassword passdb support) |
8307
33eae1ca0be0
Added support for userdb checkpassword. Patch by Sascha Wilde.
Timo Sirainen <tss@iki.fi>
parents:
8297
diff
changeset
|
1843 AC_DEFINE(USERDB_CHECKPASSWORD,, Build with checkpassword userdb support) |
2162
95b2a6abc01e
Added checkpassword passdb. userdb has only beginnings.
Timo Sirainen <tss@iki.fi>
parents:
2103
diff
changeset
|
1844 passdb="$passdb checkpassword" |
8307
33eae1ca0be0
Added support for userdb checkpassword. Patch by Sascha Wilde.
Timo Sirainen <tss@iki.fi>
parents:
8297
diff
changeset
|
1845 userdb="$userdb checkpassword" |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1846 else |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1847 not_passdb="$not_passdb checkpassword" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1848 not_userdb="$not_userdb checkpassword" |
2162
95b2a6abc01e
Added checkpassword passdb. userdb has only beginnings.
Timo Sirainen <tss@iki.fi>
parents:
2103
diff
changeset
|
1849 fi |
95b2a6abc01e
Added checkpassword passdb. userdb has only beginnings.
Timo Sirainen <tss@iki.fi>
parents:
2103
diff
changeset
|
1850 |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1851 have_bsdauth=no |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1852 if test $want_bsdauth != no; then |
1851
d66d53f57e43
Added bsdauth support, patch by Dan Cross
Timo Sirainen <tss@iki.fi>
parents:
1849
diff
changeset
|
1853 AC_CHECK_FUNC(auth_userokay, [ |
d66d53f57e43
Added bsdauth support, patch by Dan Cross
Timo Sirainen <tss@iki.fi>
parents:
1849
diff
changeset
|
1854 AC_DEFINE(PASSDB_BSDAUTH,, Build with BSD authentication support) |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1855 have_bsdauth=yes |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1856 ], [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1857 if test $want_bsdauth = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1858 AC_ERROR([Can't build with BSD authentication support: auth_userokay() not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1859 fi |
1851
d66d53f57e43
Added bsdauth support, patch by Dan Cross
Timo Sirainen <tss@iki.fi>
parents:
1849
diff
changeset
|
1860 ]) |
d66d53f57e43
Added bsdauth support, patch by Dan Cross
Timo Sirainen <tss@iki.fi>
parents:
1849
diff
changeset
|
1861 fi |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1862 if test $have_bsdauth = no; then |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1863 not_passdb="$not_passdb bsdauth" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1864 else |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1865 passdb="$passdb bsdauth" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1866 fi |
1851
d66d53f57e43
Added bsdauth support, patch by Dan Cross
Timo Sirainen <tss@iki.fi>
parents:
1849
diff
changeset
|
1867 |
3683
28cca6317829
Added GSSAPI support. Patch by Jelmer Vernooij and some fixes by
Timo Sirainen <tss@iki.fi>
parents:
3671
diff
changeset
|
1868 have_gssapi=no |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1869 if test $want_gssapi != no; then |
3683
28cca6317829
Added GSSAPI support. Patch by Jelmer Vernooij and some fixes by
Timo Sirainen <tss@iki.fi>
parents:
3671
diff
changeset
|
1870 AC_CHECK_PROG(KRB5CONFIG, krb5-config, YES, NO) |
28cca6317829
Added GSSAPI support. Patch by Jelmer Vernooij and some fixes by
Timo Sirainen <tss@iki.fi>
parents:
3671
diff
changeset
|
1871 if test $KRB5CONFIG = YES; then |
7548
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1872 if ! krb5-config --version gssapi 2>/dev/null > /dev/null; then |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1873 # krb5-config doesn't support gssapi. |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1874 KRB5_LIBS="`krb5-config --libs`" |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1875 KRB5_CFLAGS=`krb5-config --cflags` |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1876 AC_CHECK_LIB(gss, gss_acquire_cred, [ |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1877 # Solaris |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1878 KRB5_LIBS="$KRB5_LIBS -lgss" |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1879 ], [ |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1880 # failed |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1881 KRB5_LIBS= |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1882 ], $KRB5_LIBS) |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1883 else |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1884 KRB5_LIBS=`krb5-config --libs gssapi` |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1885 KRB5_CFLAGS=`krb5-config --cflags gssapi` |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1886 fi |
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1887 if test "$KRB5_LIBS" != ""; then |
6199 | 1888 AC_SUBST(KRB5_LIBS) |
1889 AC_SUBST(KRB5_CFLAGS) | |
3780
0128534525d8
Check that gssapi/gssapi.h exists before using it.
Timo Sirainen <tss@iki.fi>
parents:
3779
diff
changeset
|
1890 |
0128534525d8
Check that gssapi/gssapi.h exists before using it.
Timo Sirainen <tss@iki.fi>
parents:
3779
diff
changeset
|
1891 # Although krb5-config exists, all systems still don't |
0128534525d8
Check that gssapi/gssapi.h exists before using it.
Timo Sirainen <tss@iki.fi>
parents:
3779
diff
changeset
|
1892 # have gssapi.h |
0128534525d8
Check that gssapi/gssapi.h exists before using it.
Timo Sirainen <tss@iki.fi>
parents:
3779
diff
changeset
|
1893 old_CFLAGS=$CFLAGS |
7548
e6187b556b65
Fixed GSSAPI checks. Perhaps it works now with Solaris krb5-config also.
Timo Sirainen <tss@iki.fi>
parents:
7526
diff
changeset
|
1894 CFLAGS="$CFLAGS $KRB5_CFLAGS" |
3780
0128534525d8
Check that gssapi/gssapi.h exists before using it.
Timo Sirainen <tss@iki.fi>
parents:
3779
diff
changeset
|
1895 AC_CHECK_HEADER([gssapi/gssapi.h], [ |
4862
bddfbc560857
Some systems have gssapi elsewhere than gssapi/gssapi.h. So check also plain
Timo Sirainen <tss@iki.fi>
parents:
4855
diff
changeset
|
1896 AC_DEFINE(HAVE_GSSAPI_GSSAPI_H,, GSSAPI headers in gssapi/gssapi.h) |
3780
0128534525d8
Check that gssapi/gssapi.h exists before using it.
Timo Sirainen <tss@iki.fi>
parents:
3779
diff
changeset
|
1897 have_gssapi=yes |
0128534525d8
Check that gssapi/gssapi.h exists before using it.
Timo Sirainen <tss@iki.fi>
parents:
3779
diff
changeset
|
1898 ]) |
4862
bddfbc560857
Some systems have gssapi elsewhere than gssapi/gssapi.h. So check also plain
Timo Sirainen <tss@iki.fi>
parents:
4855
diff
changeset
|
1899 AC_CHECK_HEADER([gssapi.h], [ |
bddfbc560857
Some systems have gssapi elsewhere than gssapi/gssapi.h. So check also plain
Timo Sirainen <tss@iki.fi>
parents:
4855
diff
changeset
|
1900 AC_DEFINE(HAVE_GSSAPI_H,, GSSAPI headers in gssapi.h) |
bddfbc560857
Some systems have gssapi elsewhere than gssapi/gssapi.h. So check also plain
Timo Sirainen <tss@iki.fi>
parents:
4855
diff
changeset
|
1901 have_gssapi=yes |
bddfbc560857
Some systems have gssapi elsewhere than gssapi/gssapi.h. So check also plain
Timo Sirainen <tss@iki.fi>
parents:
4855
diff
changeset
|
1902 ]) |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
1903 if test $have_gssapi != no; then |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
1904 if test $want_gssapi = plugin; then |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
1905 have_gssapi=plugin |
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
1906 fi |
4862
bddfbc560857
Some systems have gssapi elsewhere than gssapi/gssapi.h. So check also plain
Timo Sirainen <tss@iki.fi>
parents:
4855
diff
changeset
|
1907 AC_DEFINE(HAVE_GSSAPI,, Build with GSSAPI support) |
7610
280e570a5ced
gssapi: Check for gssapi_krb5.h existence before trying to use it.
Timo Sirainen <tss@iki.fi>
parents:
7603
diff
changeset
|
1908 AC_CHECK_HEADERS(gssapi/gssapi_ext.h gssapi_krb5.h gssapi/gssapi_krb5.h) |
5859
dfdedb187b26
If __gss_userok() exists, use it to verify username. Patch by Peter Eriksson.
Timo Sirainen <tss@iki.fi>
parents:
5692
diff
changeset
|
1909 AC_CHECK_LIB(gss, __gss_userok, [ |
dfdedb187b26
If __gss_userok() exists, use it to verify username. Patch by Peter Eriksson.
Timo Sirainen <tss@iki.fi>
parents:
5692
diff
changeset
|
1910 AC_DEFINE(HAVE___GSS_USEROK,, |
dfdedb187b26
If __gss_userok() exists, use it to verify username. Patch by Peter Eriksson.
Timo Sirainen <tss@iki.fi>
parents:
5692
diff
changeset
|
1911 Define if you have __gss_userok()) |
7261
e665ef583668
If __gss_userok() is found from -lgss, make sure we link with -lgss.
Timo Sirainen <tss@iki.fi>
parents:
7259
diff
changeset
|
1912 KRB5_LIBS="$KRB5_LIBS -lgss" |
6199 | 1913 ],, $KRB5_LIBS) |
6501
dee85392c5c1
Make sure we don't define BUILTIN_GSSAPI unless HAVE_GSSAPI is also defined.
Timo Sirainen <tss@iki.fi>
parents:
6489
diff
changeset
|
1914 |
8068
9569038e0816
gssapi: Make auth_krb5_keytab work by calling _register_acceptor_identity()
Timo Sirainen <tss@iki.fi>
parents:
8055
diff
changeset
|
1915 # MIT has a #define for Heimdal acceptor_identity, but it's way too |
9569038e0816
gssapi: Make auth_krb5_keytab work by calling _register_acceptor_identity()
Timo Sirainen <tss@iki.fi>
parents:
8055
diff
changeset
|
1916 # difficult to test for it.. |
9569038e0816
gssapi: Make auth_krb5_keytab work by calling _register_acceptor_identity()
Timo Sirainen <tss@iki.fi>
parents:
8055
diff
changeset
|
1917 old_LIBS=$LIBS |
9569038e0816
gssapi: Make auth_krb5_keytab work by calling _register_acceptor_identity()
Timo Sirainen <tss@iki.fi>
parents:
8055
diff
changeset
|
1918 LIBS="$LIBS $KRB5_LIBS" |
9569038e0816
gssapi: Make auth_krb5_keytab work by calling _register_acceptor_identity()
Timo Sirainen <tss@iki.fi>
parents:
8055
diff
changeset
|
1919 AC_CHECK_FUNCS(gsskrb5_register_acceptor_identity krb5_gss_register_acceptor_identity) |
8094
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1920 |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1921 # does the kerberos library support SPNEGO? |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1922 AC_CACHE_CHECK([whether GSSAPI supports SPNEGO],i_cv_gssapi_spnego,[ |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1923 AC_TRY_RUN([ |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1924 #ifdef HAVE_GSSAPI_H |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1925 # include <gssapi.h> |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1926 #else |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1927 # include <gssapi/gssapi.h> |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1928 #endif |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1929 #include <krb5.h> |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1930 #include <string.h> |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1931 int main(void) { |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1932 OM_uint32 minor_status; |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1933 gss_OID_set mech_set; |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1934 unsigned char spnego_oid[] = { 0x2b, 0x06, 0x01, 0x05, 0x05, 0x02 }; |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1935 unsigned int i; |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1936 |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1937 gss_indicate_mechs(&minor_status, &mech_set); |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1938 for (i = 0; i < mech_set->count; i++) { |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1939 if (mech_set->elements[i].length == 6 && |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1940 memcmp(mech_set->elements[i].elements, |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1941 spnego_oid, 6) == 0) |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1942 return 0; |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1943 } |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1944 return 1; |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1945 } |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1946 ], [ |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1947 i_cv_gssapi_spnego=yes |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1948 ], [ |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1949 i_cv_gssapi_spnego=no |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1950 ]) |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1951 ]) |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1952 if test "$i_cv_gssapi_spnego" = "yes"; then |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1953 AC_DEFINE(HAVE_GSSAPI_SPNEGO,, GSSAPI supports SPNEGO) |
641d761219a6
Support GSS-SPNEGO mechanism if GSSAPI library supports it.
Timo Sirainen <tss@iki.fi>
parents:
8090
diff
changeset
|
1954 fi |
8068
9569038e0816
gssapi: Make auth_krb5_keytab work by calling _register_acceptor_identity()
Timo Sirainen <tss@iki.fi>
parents:
8055
diff
changeset
|
1955 LIBS=$old_LIBS |
9569038e0816
gssapi: Make auth_krb5_keytab work by calling _register_acceptor_identity()
Timo Sirainen <tss@iki.fi>
parents:
8055
diff
changeset
|
1956 |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
1957 if test $want_gssapi != plugin; then |
6501
dee85392c5c1
Make sure we don't define BUILTIN_GSSAPI unless HAVE_GSSAPI is also defined.
Timo Sirainen <tss@iki.fi>
parents:
6489
diff
changeset
|
1958 AUTH_LIBS="$AUTH_LIBS $KRB5_LIBS" |
7554
419b7cfc954c
Once $KRB5_CFLAGS is set, use it instead of calling krb5-config again.
Timo Sirainen <tss@iki.fi>
parents:
7548
diff
changeset
|
1959 AUTH_CFLAGS="$AUTH_CFLAGS $KRB5_CFLAGS" |
6501
dee85392c5c1
Make sure we don't define BUILTIN_GSSAPI unless HAVE_GSSAPI is also defined.
Timo Sirainen <tss@iki.fi>
parents:
6489
diff
changeset
|
1960 AC_DEFINE(BUILTIN_GSSAPI,, GSSAPI support is built in) |
dee85392c5c1
Make sure we don't define BUILTIN_GSSAPI unless HAVE_GSSAPI is also defined.
Timo Sirainen <tss@iki.fi>
parents:
6489
diff
changeset
|
1961 else |
dee85392c5c1
Make sure we don't define BUILTIN_GSSAPI unless HAVE_GSSAPI is also defined.
Timo Sirainen <tss@iki.fi>
parents:
6489
diff
changeset
|
1962 have_gssapi_plugin=yes |
dee85392c5c1
Make sure we don't define BUILTIN_GSSAPI unless HAVE_GSSAPI is also defined.
Timo Sirainen <tss@iki.fi>
parents:
6489
diff
changeset
|
1963 fi |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1964 else |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
1965 if test $want_gssapi != auto; then |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1966 AC_ERROR([Can't build with GSSAPI support: gssapi.h not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1967 fi |
4862
bddfbc560857
Some systems have gssapi elsewhere than gssapi/gssapi.h. So check also plain
Timo Sirainen <tss@iki.fi>
parents:
4855
diff
changeset
|
1968 fi |
3780
0128534525d8
Check that gssapi/gssapi.h exists before using it.
Timo Sirainen <tss@iki.fi>
parents:
3779
diff
changeset
|
1969 CFLAGS=$old_CFLAGS |
3705
561e81dfa20b
MIT kerberos v1.2 (and older) doesn't work with us.
Timo Sirainen <tss@iki.fi>
parents:
3686
diff
changeset
|
1970 fi |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1971 else |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
1972 if test $want_gssapi != auto; then |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1973 AC_ERROR([Can't build with GSSAPI support: krb5-config not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1974 fi |
3683
28cca6317829
Added GSSAPI support. Patch by Jelmer Vernooij and some fixes by
Timo Sirainen <tss@iki.fi>
parents:
3671
diff
changeset
|
1975 fi |
28cca6317829
Added GSSAPI support. Patch by Jelmer Vernooij and some fixes by
Timo Sirainen <tss@iki.fi>
parents:
3671
diff
changeset
|
1976 fi |
6199 | 1977 AM_CONDITIONAL(GSSAPI_PLUGIN, test "$have_gssapi_plugin" = "yes") |
3683
28cca6317829
Added GSSAPI support. Patch by Jelmer Vernooij and some fixes by
Timo Sirainen <tss@iki.fi>
parents:
3671
diff
changeset
|
1978 |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1979 have_sia=no |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1980 if test $want_sia != no; then |
4638
689a02ca02d3
Tru64 SIA authentication support. Patch by Simon L Jackson
Timo Sirainen <tss@iki.fi>
parents:
4621
diff
changeset
|
1981 AC_CHECK_FUNC(sia_validate_user, [ |
689a02ca02d3
Tru64 SIA authentication support. Patch by Simon L Jackson
Timo Sirainen <tss@iki.fi>
parents:
4621
diff
changeset
|
1982 AC_DEFINE(PASSDB_SIA,, Build with Tru64 SIA support) |
689a02ca02d3
Tru64 SIA authentication support. Patch by Simon L Jackson
Timo Sirainen <tss@iki.fi>
parents:
4621
diff
changeset
|
1983 AUTH_LIBS="$AUTH_LIBS -depth_ring_search" |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1984 have_sia=yes |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1985 ], [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1986 if test $want_sia = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1987 AC_ERROR([Can't build with SIA support: sia_validate_user() not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1988 fi |
4638
689a02ca02d3
Tru64 SIA authentication support. Patch by Simon L Jackson
Timo Sirainen <tss@iki.fi>
parents:
4621
diff
changeset
|
1989 ]) |
689a02ca02d3
Tru64 SIA authentication support. Patch by Simon L Jackson
Timo Sirainen <tss@iki.fi>
parents:
4621
diff
changeset
|
1990 fi |
689a02ca02d3
Tru64 SIA authentication support. Patch by Simon L Jackson
Timo Sirainen <tss@iki.fi>
parents:
4621
diff
changeset
|
1991 |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1992 if test $have_sia = no; then |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1993 not_passdb="$not_passdb sia" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1994 else |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1995 passdb="$passdb sia" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1996 fi |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1997 |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
1998 have_ldap=no |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
1999 if test $want_ldap != no; then |
1057
c5ab972db48c
libldap checks, --without-pop3 disables pop3 server
Timo Sirainen <tss@iki.fi>
parents:
1049
diff
changeset
|
2000 AC_CHECK_LIB(ldap, ldap_init, [ |
c5ab972db48c
libldap checks, --without-pop3 disables pop3 server
Timo Sirainen <tss@iki.fi>
parents:
1049
diff
changeset
|
2001 AC_CHECK_HEADER(ldap.h, [ |
2325
7613e0f68513
Fixed to compile with Solaris LDAP library
Timo Sirainen <tss@iki.fi>
parents:
2222
diff
changeset
|
2002 AC_CHECK_LIB(ldap, ldap_initialize, [ |
7613e0f68513
Fixed to compile with Solaris LDAP library
Timo Sirainen <tss@iki.fi>
parents:
2222
diff
changeset
|
2003 AC_DEFINE(LDAP_HAVE_INITIALIZE,, Define if you have ldap_initialize) |
7613e0f68513
Fixed to compile with Solaris LDAP library
Timo Sirainen <tss@iki.fi>
parents:
2222
diff
changeset
|
2004 ]) |
4415
b91816cd1d16
Added TLS support for LDAP if the library supports it.
Timo Sirainen <tss@iki.fi>
parents:
4411
diff
changeset
|
2005 AC_CHECK_LIB(ldap, ldap_start_tls_s, [ |
b91816cd1d16
Added TLS support for LDAP if the library supports it.
Timo Sirainen <tss@iki.fi>
parents:
4411
diff
changeset
|
2006 AC_DEFINE(LDAP_HAVE_START_TLS_S,, Define if you have ldap_start_tls_s) |
b91816cd1d16
Added TLS support for LDAP if the library supports it.
Timo Sirainen <tss@iki.fi>
parents:
4411
diff
changeset
|
2007 ]) |
10551
2882650531e0
configure: Use -llber for ldap only if necessary.
Timo Sirainen <tss@iki.fi>
parents:
10491
diff
changeset
|
2008 LDAP_LIBS="-lldap" |
11117
eee1e2a1c25b
configure: Removed --enable-header-install. It's now always enabled.
Timo Sirainen <tss@iki.fi>
parents:
11008
diff
changeset
|
2009 AC_CHECK_LIB(ldap, ber_free, [ |
eee1e2a1c25b
configure: Removed --enable-header-install. It's now always enabled.
Timo Sirainen <tss@iki.fi>
parents:
11008
diff
changeset
|
2010 # do nothing, default is to add -lldap to LIBS |
11120
829cc91ed831
configure: Fix to older autoconfs
Timo Sirainen <tss@iki.fi>
parents:
11117
diff
changeset
|
2011 : |
11117
eee1e2a1c25b
configure: Removed --enable-header-install. It's now always enabled.
Timo Sirainen <tss@iki.fi>
parents:
11008
diff
changeset
|
2012 ], [ |
10551
2882650531e0
configure: Use -llber for ldap only if necessary.
Timo Sirainen <tss@iki.fi>
parents:
10491
diff
changeset
|
2013 AC_CHECK_LIB(lber, ber_free, [ |
2882650531e0
configure: Use -llber for ldap only if necessary.
Timo Sirainen <tss@iki.fi>
parents:
10491
diff
changeset
|
2014 LDAP_LIBS="$LDAP_LIBS -llber" |
2882650531e0
configure: Use -llber for ldap only if necessary.
Timo Sirainen <tss@iki.fi>
parents:
10491
diff
changeset
|
2015 ]) |
2882650531e0
configure: Use -llber for ldap only if necessary.
Timo Sirainen <tss@iki.fi>
parents:
10491
diff
changeset
|
2016 ]) |
6198
4f6c4aeafafb
--with-ldap=plugin builds LDAP passdb and userdb support as a plugin.
Timo Sirainen <tss@iki.fi>
parents:
6196
diff
changeset
|
2017 AC_SUBST(LDAP_LIBS) |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
2018 if test $want_ldap != plugin; then |
6198
4f6c4aeafafb
--with-ldap=plugin builds LDAP passdb and userdb support as a plugin.
Timo Sirainen <tss@iki.fi>
parents:
6196
diff
changeset
|
2019 AUTH_LIBS="$AUTH_LIBS $LDAP_LIBS" |
4f6c4aeafafb
--with-ldap=plugin builds LDAP passdb and userdb support as a plugin.
Timo Sirainen <tss@iki.fi>
parents:
6196
diff
changeset
|
2020 AC_DEFINE(BUILTIN_LDAP,, LDAP support is built in) |
4f6c4aeafafb
--with-ldap=plugin builds LDAP passdb and userdb support as a plugin.
Timo Sirainen <tss@iki.fi>
parents:
6196
diff
changeset
|
2021 fi |
1057
c5ab972db48c
libldap checks, --without-pop3 disables pop3 server
Timo Sirainen <tss@iki.fi>
parents:
1049
diff
changeset
|
2022 |
c5ab972db48c
libldap checks, --without-pop3 disables pop3 server
Timo Sirainen <tss@iki.fi>
parents:
1049
diff
changeset
|
2023 AC_DEFINE(USERDB_LDAP,, Build with LDAP support) |
c5ab972db48c
libldap checks, --without-pop3 disables pop3 server
Timo Sirainen <tss@iki.fi>
parents:
1049
diff
changeset
|
2024 AC_DEFINE(PASSDB_LDAP,, Build with LDAP support) |
9656
dc6d35b51b68
configure: Check sasl.h existence only when using --with-ldap.
Timo Sirainen <tss@iki.fi>
parents:
9655
diff
changeset
|
2025 AC_CHECK_HEADERS(sasl.h sasl/sasl.h) |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2026 have_ldap=yes |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2027 ], [ |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
2028 if test $want_ldap != auto; then |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2029 AC_ERROR([Can't build with LDAP support: ldap.h not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2030 fi |
1057
c5ab972db48c
libldap checks, --without-pop3 disables pop3 server
Timo Sirainen <tss@iki.fi>
parents:
1049
diff
changeset
|
2031 ]) |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2032 ], [ |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
2033 if test $want_ldap != auto; then |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2034 AC_ERROR([Can't build with LDAP support: libldap not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2035 fi |
1057
c5ab972db48c
libldap checks, --without-pop3 disables pop3 server
Timo Sirainen <tss@iki.fi>
parents:
1049
diff
changeset
|
2036 ]) |
c5ab972db48c
libldap checks, --without-pop3 disables pop3 server
Timo Sirainen <tss@iki.fi>
parents:
1049
diff
changeset
|
2037 fi |
c5ab972db48c
libldap checks, --without-pop3 disables pop3 server
Timo Sirainen <tss@iki.fi>
parents:
1049
diff
changeset
|
2038 |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2039 if test $have_ldap = no; then |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2040 not_passdb="$not_passdb ldap" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2041 not_userdb="$not_userdb ldap" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2042 else |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2043 userdb="$userdb ldap" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2044 passdb="$passdb ldap" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2045 if test $want_ldap = plugin; then |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2046 have_ldap_plugin=yes |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2047 userdb="$userdb (plugin)" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2048 passdb="$passdb (plugin)" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2049 fi |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2050 fi |
9551
49a1e47cb037
Fixed building LDAP support as plugin.
Timo Sirainen <tss@iki.fi>
parents:
9542
diff
changeset
|
2051 AM_CONDITIONAL(LDAP_PLUGIN, test "$have_ldap_plugin" = "yes") |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2052 |
4517
e661182eab75
Berkeley DB dict support is now enabled only when using --with-db configure option.
Timo Sirainen <timo.sirainen@movial.fi>
parents:
4482
diff
changeset
|
2053 dict_drivers=client |
e661182eab75
Berkeley DB dict support is now enabled only when using --with-db configure option.
Timo Sirainen <timo.sirainen@movial.fi>
parents:
4482
diff
changeset
|
2054 |
10600
20963e8ec560
configure: Another try at fixing Berkeley DB check to not give an error.
Timo Sirainen <tss@iki.fi>
parents:
10598
diff
changeset
|
2055 if test $want_db != no; then |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2056 AC_CACHE_CHECK([db_env_create in -ldb],i_cv_have_db_env_create,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2057 old_LIBS=$LIBS |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2058 LIBS="$LIBS -ldb" |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2059 AC_TRY_LINK([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2060 #include <db.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2061 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2062 db_env_create(0, 0); |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2063 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2064 i_cv_have_db_env_create=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2065 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2066 i_cv_have_db_env_create=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2067 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2068 LIBS=$old_LIBS |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2069 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2070 if test $i_cv_have_db_env_create = yes; then |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2071 AC_CHECK_HEADER(db.h, [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2072 DICT_LIBS="$DICT_LIBS -ldb" |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2073 dict_drivers="$dict_drivers db" |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2074 AC_DEFINE(BUILD_DB,, Build with Berkeley DB support) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2075 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2076 if test $want_db = yes; then |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2077 AC_ERROR([Can't build with db support: db.h not found]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2078 fi |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2079 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2080 else |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2081 if test $want_db = yes; then |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2082 AC_ERROR([Can't build with db support: libdb not found]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2083 fi |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2084 fi |
4517
e661182eab75
Berkeley DB dict support is now enabled only when using --with-db configure option.
Timo Sirainen <timo.sirainen@movial.fi>
parents:
4482
diff
changeset
|
2085 fi |
e661182eab75
Berkeley DB dict support is now enabled only when using --with-db configure option.
Timo Sirainen <timo.sirainen@movial.fi>
parents:
4482
diff
changeset
|
2086 |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2087 if test $want_pgsql != no; then |
9640
ac52d79b7b94
configure: Use pg_config for figuring out PostgreSQL include/libs paths.
Timo Sirainen <tss@iki.fi>
parents:
9559
diff
changeset
|
2088 AC_CHECK_PROG(PG_CONFIG, pg_config, YES, NO) |
ac52d79b7b94
configure: Use pg_config for figuring out PostgreSQL include/libs paths.
Timo Sirainen <tss@iki.fi>
parents:
9559
diff
changeset
|
2089 if test $PG_CONFIG = NO; then |
9654
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2090 # based on code from PHP |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2091 for i in /usr /usr/local /usr/local/pgsql; do |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2092 for j in include include/pgsql include/postgres include/postgresql ""; do |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2093 if test -r "$i/$j/libpq-fe.h"; then |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2094 PGSQL_INCLUDE=$i/$j |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2095 fi |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2096 done |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2097 for lib in lib lib64; do |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2098 for j in $lib $lib/pgsql $lib/postgres $lib/postgresql ""; do |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2099 if test -f "$i/$j/libpq.so" || test -f "$i/$j/libpq.a"; then |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2100 PGSQL_LIBDIR=$i/$j |
9640
ac52d79b7b94
configure: Use pg_config for figuring out PostgreSQL include/libs paths.
Timo Sirainen <tss@iki.fi>
parents:
9559
diff
changeset
|
2101 fi |
9654
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2102 done |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2103 done |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2104 done |
9640
ac52d79b7b94
configure: Use pg_config for figuring out PostgreSQL include/libs paths.
Timo Sirainen <tss@iki.fi>
parents:
9559
diff
changeset
|
2105 else |
9654
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2106 PGSQL_INCLUDE="`pg_config --includedir`" |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2107 PGSQL_LIBDIR="`pg_config --libdir`" |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2108 fi |
1283
2d8af547a8b4
Added PostgreSQL support, patch by Alex Howansky
Timo Sirainen <tss@iki.fi>
parents:
1256
diff
changeset
|
2109 |
9654
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2110 old_LIBS=$LIBS |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2111 if test "$PGSQL_LIBDIR" != ""; then |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2112 LIBS="$LIBS -L$PGSQL_LIBDIR" |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2113 fi |
1283
2d8af547a8b4
Added PostgreSQL support, patch by Alex Howansky
Timo Sirainen <tss@iki.fi>
parents:
1256
diff
changeset
|
2114 |
9654
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2115 AC_CHECK_LIB(pq, PQconnectdb, [ |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2116 AC_CHECK_LIB(pq, PQescapeStringConn, [ |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2117 AC_DEFINE(HAVE_PQESCAPE_STRING_CONN,, Define if libpq has PQescapeStringConn function) |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2118 ]) |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2119 old_CPPFLAGS=$CPPFLAGS |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2120 if test "$PGSQL_INCLUDE" != ""; then |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2121 CPPFLAGS="$CPPFLAGS -I $PGSQL_INCLUDE" |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2122 fi |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2123 AC_CHECK_HEADER(libpq-fe.h, [ |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2124 if test "$PGSQL_INCLUDE" != ""; then |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2125 PGSQL_CFLAGS="$PGSQL_CFLAGS -I$PGSQL_INCLUDE" |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2126 fi |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2127 if test "$PGSQL_LIBDIR" != ""; then |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2128 PGSQL_LIBS="$PGSQL_LIBS -L$PGSQL_LIBDIR" |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2129 fi |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2130 PGSQL_LIBS="$PGSQL_LIBS -lpq" |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2131 AC_DEFINE(HAVE_PGSQL,, Build with PostgreSQL support) |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2132 found_sql_drivers="$found_sql_drivers pgsql" |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2133 ], [ |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2134 if test $want_pgsql = yes; then |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2135 AC_ERROR([Can't build with PostgreSQL support: libpq-fe.h not found]) |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2136 fi |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2137 ]) |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2138 CPPFLAGS=$old_CPPFLAGS |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2139 ], [ |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2140 if test $want_pgsql = yes; then |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2141 AC_ERROR([Can't build with PostgreSQL support: libpq not found]) |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2142 fi |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2143 ]) |
5714aba539f0
configure: Support finding PostgreSQL without pg_config after all.
Timo Sirainen <tss@iki.fi>
parents:
9640
diff
changeset
|
2144 LIBS=$old_LIBS |
1283
2d8af547a8b4
Added PostgreSQL support, patch by Alex Howansky
Timo Sirainen <tss@iki.fi>
parents:
1256
diff
changeset
|
2145 fi |
2d8af547a8b4
Added PostgreSQL support, patch by Alex Howansky
Timo Sirainen <tss@iki.fi>
parents:
1256
diff
changeset
|
2146 |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2147 if test $want_mysql != no; then |
9942
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2148 AC_CHECK_PROG(MYSQL_CONFIG, mysql_config, YES, NO) |
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2149 if test $MYSQL_CONFIG = NO; then |
2384
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2150 # based on code from PHP |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2151 for i in /usr /usr/local /usr/local/mysql; do |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2152 for j in include include/mysql ""; do |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2153 if test -r "$i/$j/mysql.h"; then |
9942
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2154 MYSQL_INCLUDE="-I $i/$j" |
2384
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2155 fi |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2156 done |
4142
08aef9a8e22c
Added lib64 directory to mysql/pgsql checks. Removed all special lib/include
Timo Sirainen <tss@iki.fi>
parents:
4141
diff
changeset
|
2157 for j in lib lib/mysql lib64 lib64/mysql ""; do |
2384
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2158 if test -f "$i/$j/libmysqlclient.so" || test -f "$i/$j/libmysqlclient.a"; then |
9942
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2159 MYSQL_LIBS="-L $i/$j -lmysqlclient -lz -lm" |
2384
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2160 fi |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2161 done |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2162 done |
9942
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2163 else |
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2164 MYSQL_INCLUDE="`mysql_config --include`" |
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2165 MYSQL_LIBS="`mysql_config --libs`" |
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2166 fi |
2384
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2167 |
9942
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2168 old_LIBS=$LIBS |
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2169 if test "$MYSQL_LIBS" != ""; then |
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2170 LIBS="$LIBS $MYSQL_LIBS" |
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2171 fi |
1995
cc64f8bb4716
MySQL authentication patch by Matther Reimer
Timo Sirainen <tss@iki.fi>
parents:
1990
diff
changeset
|
2172 |
9942
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2173 mysql_lib="" |
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2174 LIBS="$LIBS -lz -lm" |
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2175 AC_CHECK_LIB(mysqlclient, mysql_init, [ |
2384
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2176 old_CPPFLAGS=$CPPFLAGS |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2177 if test "$MYSQL_INCLUDE" != ""; then |
9942
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2178 CPPFLAGS="$CPPFLAGS $MYSQL_INCLUDE" |
2384
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2179 fi |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2180 AC_CHECK_HEADER(mysql.h, [ |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2181 if test "$MYSQL_INCLUDE" != ""; then |
9942
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2182 MYSQL_CFLAGS="$MYSQL_CFLAGS $MYSQL_INCLUDE" |
2384
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2183 fi |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2184 |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2185 AC_CHECK_LIB(mysqlclient, mysql_ssl_set, [ |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2186 AC_DEFINE(HAVE_MYSQL_SSL,, Define if your MySQL library has SSL functions) |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2187 if test "x$have_openssl" = "yes"; then |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2188 ssl_define="#define HAVE_OPENSSL" |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2189 else |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2190 ssl_define="" |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2191 fi |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2192 AC_TRY_COMPILE([ |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2193 $ssl_define |
2403 | 2194 #include <mysql.h> |
2384
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2195 ], [ |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2196 mysql_set_ssl(0, 0, 0, 0, 0, 0); |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2197 ], [ |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2198 AC_DEFINE(HAVE_MYSQL_SSL_CIPHER,, Define if your MySQL library supports setting cipher) |
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2199 ]) |
2369 | 2200 ]) |
2384
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2201 |
2754
3c3ac12be307
Created generic asynchronous SQL API and implemented MySQL and PostgreSQL
Timo Sirainen <tss@iki.fi>
parents:
2717
diff
changeset
|
2202 AC_DEFINE(HAVE_MYSQL,, Build with MySQL support) |
3943
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2203 found_sql_drivers="$found_sql_drivers mysql" |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2204 ], [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2205 if test $want_mysql = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2206 AC_ERROR([Can't build with MySQL support: mysql.h not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2207 fi |
2369 | 2208 ]) |
2384
0cc72087752f
Better MySQL checking. Patch by John Dennis
Timo Sirainen <tss@iki.fi>
parents:
2377
diff
changeset
|
2209 CPPFLAGS=$old_CPPFLAGS |
9942
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2210 ], [ |
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2211 if test $want_mysql = yes; then |
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2212 AC_ERROR([Can't build with MySQL support: libmysqlclient not found]) |
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2213 fi |
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2214 ]) |
1995
cc64f8bb4716
MySQL authentication patch by Matther Reimer
Timo Sirainen <tss@iki.fi>
parents:
1990
diff
changeset
|
2215 |
9942
a22c9e8a01ae
configure: Use mysql_config to find where mysql exists.
Timo Sirainen <tss@iki.fi>
parents:
9842
diff
changeset
|
2216 LIBS=$old_LIBS |
1995
cc64f8bb4716
MySQL authentication patch by Matther Reimer
Timo Sirainen <tss@iki.fi>
parents:
1990
diff
changeset
|
2217 fi |
cc64f8bb4716
MySQL authentication patch by Matther Reimer
Timo Sirainen <tss@iki.fi>
parents:
1990
diff
changeset
|
2218 |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2219 if test $want_sqlite != no; then |
3919
b967ffb7e3a6
SQLite support. Patch by Jakob Hirsch.
Timo Sirainen <tss@iki.fi>
parents:
3904
diff
changeset
|
2220 AC_CHECK_LIB(sqlite3, sqlite3_open, [ |
b967ffb7e3a6
SQLite support. Patch by Jakob Hirsch.
Timo Sirainen <tss@iki.fi>
parents:
3904
diff
changeset
|
2221 AC_CHECK_HEADER(sqlite3.h, [ |
6194
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2222 SQLITE_LIBS="$SQLITE_LIBS -lsqlite3 -lz" |
3919
b967ffb7e3a6
SQLite support. Patch by Jakob Hirsch.
Timo Sirainen <tss@iki.fi>
parents:
3904
diff
changeset
|
2223 |
b967ffb7e3a6
SQLite support. Patch by Jakob Hirsch.
Timo Sirainen <tss@iki.fi>
parents:
3904
diff
changeset
|
2224 AC_DEFINE(HAVE_SQLITE,, Build with SQLite3 support) |
3943
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2225 found_sql_drivers="$found_sql_drivers sqlite" |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2226 ], [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2227 if test $want_sqlite = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2228 AC_ERROR([Can't build with SQLite support: sqlite3.h not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2229 fi |
3919
b967ffb7e3a6
SQLite support. Patch by Jakob Hirsch.
Timo Sirainen <tss@iki.fi>
parents:
3904
diff
changeset
|
2230 ]) |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2231 ], [ |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2232 if test $want_sqlite = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2233 AC_ERROR([Can't build with SQLite support: libsqlite3 not found]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2234 fi |
4144 | 2235 ]) |
3919
b967ffb7e3a6
SQLite support. Patch by Jakob Hirsch.
Timo Sirainen <tss@iki.fi>
parents:
3904
diff
changeset
|
2236 fi |
6194
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2237 |
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2238 SQL_CFLAGS="$MYSQL_CFLAGS $PGSQL_CFLAGS $SQLITE_CFLAGS" |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
2239 if test "$want_sql" != "plugin"; then |
6194
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2240 SQL_LIBS="$MYSQL_LIBS $PGSQL_LIBS $SQLITE_LIBS" |
9329
ed142749ce67
dovecot --build-options: If SQL or LDAP was built as plugins, say it.
Timo Sirainen <tss@iki.fi>
parents:
9258
diff
changeset
|
2241 else |
ed142749ce67
dovecot --build-options: If SQL or LDAP was built as plugins, say it.
Timo Sirainen <tss@iki.fi>
parents:
9258
diff
changeset
|
2242 AC_DEFINE(SQL_DRIVER_PLUGINS,, Build SQL drivers as plugins) |
6194
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2243 fi |
3919
b967ffb7e3a6
SQLite support. Patch by Jakob Hirsch.
Timo Sirainen <tss@iki.fi>
parents:
3904
diff
changeset
|
2244 |
10155
3a32306aa473
configure: Removed --with-sql-drivers parameter. I'm not sure what it tried to do.
Timo Sirainen <tss@iki.fi>
parents:
10095
diff
changeset
|
2245 sql_drivers= |
3a32306aa473
configure: Removed --with-sql-drivers parameter. I'm not sure what it tried to do.
Timo Sirainen <tss@iki.fi>
parents:
10095
diff
changeset
|
2246 not_sql_drivers= |
3a32306aa473
configure: Removed --with-sql-drivers parameter. I'm not sure what it tried to do.
Timo Sirainen <tss@iki.fi>
parents:
10095
diff
changeset
|
2247 |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
2248 if test "$found_sql_drivers" != "" || test "$want_sql" != "no"; then |
10155
3a32306aa473
configure: Removed --with-sql-drivers parameter. I'm not sure what it tried to do.
Timo Sirainen <tss@iki.fi>
parents:
10095
diff
changeset
|
2249 sql_drivers="$found_sql_drivers" |
3943
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2250 |
2754
3c3ac12be307
Created generic asynchronous SQL API and implemented MySQL and PostgreSQL
Timo Sirainen <tss@iki.fi>
parents:
2717
diff
changeset
|
2251 AC_DEFINE(PASSDB_SQL,, Build with SQL support) |
3c3ac12be307
Created generic asynchronous SQL API and implemented MySQL and PostgreSQL
Timo Sirainen <tss@iki.fi>
parents:
2717
diff
changeset
|
2252 AC_DEFINE(USERDB_SQL,, Build with SQL support) |
3c3ac12be307
Created generic asynchronous SQL API and implemented MySQL and PostgreSQL
Timo Sirainen <tss@iki.fi>
parents:
2717
diff
changeset
|
2253 AUTH_LIBS="$AUTH_LIBS $SQL_LIBS" |
4012
d8c1e641b435
Building with SQL support replaced passdb list with userdbs.
Timo Sirainen <timo.sirainen@movial.fi>
parents:
4005
diff
changeset
|
2254 passdb="$passdb sql" |
3943
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2255 userdb="$userdb sql" |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2256 else |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2257 not_passdb="$not_passdb sql" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2258 not_userdb="$not_userdb sql" |
2754
3c3ac12be307
Created generic asynchronous SQL API and implemented MySQL and PostgreSQL
Timo Sirainen <tss@iki.fi>
parents:
2717
diff
changeset
|
2259 fi |
3c3ac12be307
Created generic asynchronous SQL API and implemented MySQL and PostgreSQL
Timo Sirainen <tss@iki.fi>
parents:
2717
diff
changeset
|
2260 |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2261 have_vpopmail=no |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2262 if test $want_vpopmail != no; then |
8828
71f385df3de4
--with-vpopmail=path now also checks path/lib_deps instead of only path/etc/lib_deps.
Timo Sirainen <tss@iki.fi>
parents:
8798
diff
changeset
|
2263 vpop_etc="$vpopmail_home/etc" |
71f385df3de4
--with-vpopmail=path now also checks path/lib_deps instead of only path/etc/lib_deps.
Timo Sirainen <tss@iki.fi>
parents:
8798
diff
changeset
|
2264 AC_MSG_CHECKING([for vpopmail configuration at $vpop_etc/lib_deps]) |
71f385df3de4
--with-vpopmail=path now also checks path/lib_deps instead of only path/etc/lib_deps.
Timo Sirainen <tss@iki.fi>
parents:
8798
diff
changeset
|
2265 if ! test -f $vpop_etc/lib_deps; then |
8829
f67a966f2792
--with-vpopmail: Minor fix for previous change.
Timo Sirainen <tss@iki.fi>
parents:
8828
diff
changeset
|
2266 AC_MSG_RESULT(not found) |
8828
71f385df3de4
--with-vpopmail=path now also checks path/lib_deps instead of only path/etc/lib_deps.
Timo Sirainen <tss@iki.fi>
parents:
8798
diff
changeset
|
2267 vpop_etc="$vpopmail_home" |
71f385df3de4
--with-vpopmail=path now also checks path/lib_deps instead of only path/etc/lib_deps.
Timo Sirainen <tss@iki.fi>
parents:
8798
diff
changeset
|
2268 AC_MSG_CHECKING([for vpopmail configuration at $vpop_etc/lib_deps]) |
71f385df3de4
--with-vpopmail=path now also checks path/lib_deps instead of only path/etc/lib_deps.
Timo Sirainen <tss@iki.fi>
parents:
8798
diff
changeset
|
2269 fi |
71f385df3de4
--with-vpopmail=path now also checks path/lib_deps instead of only path/etc/lib_deps.
Timo Sirainen <tss@iki.fi>
parents:
8798
diff
changeset
|
2270 if test -f $vpop_etc/lib_deps; then |
71f385df3de4
--with-vpopmail=path now also checks path/lib_deps instead of only path/etc/lib_deps.
Timo Sirainen <tss@iki.fi>
parents:
8798
diff
changeset
|
2271 AUTH_CFLAGS="$AUTH_CFLAGS `cat $vpop_etc/inc_deps` $CFLAGS" |
71f385df3de4
--with-vpopmail=path now also checks path/lib_deps instead of only path/etc/lib_deps.
Timo Sirainen <tss@iki.fi>
parents:
8798
diff
changeset
|
2272 AUTH_LIBS="$AUTH_LIBS `cat $vpop_etc/lib_deps`" |
1043
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
2273 AC_DEFINE(USERDB_VPOPMAIL,, Build with vpopmail support) |
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
2274 AC_DEFINE(PASSDB_VPOPMAIL,, Build with vpopmail support) |
281 | 2275 AC_MSG_RESULT(found) |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2276 have_vpopmail=yes |
280
fa2d1a1d025e
vpopmail authentication. compiles, not tested if it really works.
Timo Sirainen <tss@iki.fi>
parents:
247
diff
changeset
|
2277 else |
281 | 2278 AC_MSG_RESULT(not found) |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2279 if test $want_vpopmail = yes; then |
8828
71f385df3de4
--with-vpopmail=path now also checks path/lib_deps instead of only path/etc/lib_deps.
Timo Sirainen <tss@iki.fi>
parents:
8798
diff
changeset
|
2280 AC_ERROR([Can't build with vpopmail support: $vpop_etc/lib_deps not found]) |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2281 fi |
280
fa2d1a1d025e
vpopmail authentication. compiles, not tested if it really works.
Timo Sirainen <tss@iki.fi>
parents:
247
diff
changeset
|
2282 fi |
fa2d1a1d025e
vpopmail authentication. compiles, not tested if it really works.
Timo Sirainen <tss@iki.fi>
parents:
247
diff
changeset
|
2283 fi |
fa2d1a1d025e
vpopmail authentication. compiles, not tested if it really works.
Timo Sirainen <tss@iki.fi>
parents:
247
diff
changeset
|
2284 |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2285 if test $have_vpopmail = no; then |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2286 not_passdb="$not_passdb vpopmail" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2287 not_userdb="$not_userdb vpopmail" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2288 else |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2289 userdb="$userdb vpopmail" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2290 passdb="$passdb vpopmail" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2291 fi |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2292 |
5692
1034fcaffcce
If crypt() is in libc, don't link -lcrypt even if it's found.
Timo Sirainen <tss@iki.fi>
parents:
5691
diff
changeset
|
2293 AC_CHECK_FUNC(crypt,, [ |
1034fcaffcce
If crypt() is in libc, don't link -lcrypt even if it's found.
Timo Sirainen <tss@iki.fi>
parents:
5691
diff
changeset
|
2294 AC_CHECK_LIB(crypt, crypt, [ |
1034fcaffcce
If crypt() is in libc, don't link -lcrypt even if it's found.
Timo Sirainen <tss@iki.fi>
parents:
5691
diff
changeset
|
2295 AUTH_LIBS="-lcrypt $AUTH_LIBS" |
1034fcaffcce
If crypt() is in libc, don't link -lcrypt even if it's found.
Timo Sirainen <tss@iki.fi>
parents:
5691
diff
changeset
|
2296 ], [ |
1034fcaffcce
If crypt() is in libc, don't link -lcrypt even if it's found.
Timo Sirainen <tss@iki.fi>
parents:
5691
diff
changeset
|
2297 AC_MSG_ERROR([crypt() wasn't found]) |
1034fcaffcce
If crypt() is in libc, don't link -lcrypt even if it's found.
Timo Sirainen <tss@iki.fi>
parents:
5691
diff
changeset
|
2298 ]) |
5346
e39ce58a463b
Link dovecot-auth always with -lcrypto if it's needed for crypt(). It could
Timo Sirainen <tss@iki.fi>
parents:
5217
diff
changeset
|
2299 ]) |
0 | 2300 |
1511
a4ad03c210af
Check if dlopen is in libc too.
Timo Sirainen <tss@iki.fi>
parents:
1467
diff
changeset
|
2301 if test $have_modules = yes; then |
1465
03dd87873a81
Added support for dynamically loadable imap/pop3 modules.
Timo Sirainen <tss@iki.fi>
parents:
1462
diff
changeset
|
2302 AC_DEFINE(HAVE_MODULES,, Define if you have dynamic module support) |
03dd87873a81
Added support for dynamically loadable imap/pop3 modules.
Timo Sirainen <tss@iki.fi>
parents:
1462
diff
changeset
|
2303 AC_SUBST(MODULE_LIBS) |
7826
b63aa0ffe564
Use dynamic module suffix provided by libtool rather than hardcoded ".so".
Timo Sirainen <tss@iki.fi>
parents:
7823
diff
changeset
|
2304 |
b63aa0ffe564
Use dynamic module suffix provided by libtool rather than hardcoded ".so".
Timo Sirainen <tss@iki.fi>
parents:
7823
diff
changeset
|
2305 # shrext_cmds comes from libtool.m4 |
7867
3f8282688777
Fixed looking up plugin suffix.
Timo Sirainen <tss@iki.fi>
parents:
7865
diff
changeset
|
2306 module=yes eval MODULE_SUFFIX=$shrext_cmds |
7869
fe465f0f86fb
If $shrext_cmds isn't set for some reason, fallback to ".so" suffix.
Timo Sirainen <tss@iki.fi>
parents:
7867
diff
changeset
|
2307 if test "$MODULE_SUFFIX" = ""; then |
fe465f0f86fb
If $shrext_cmds isn't set for some reason, fallback to ".so" suffix.
Timo Sirainen <tss@iki.fi>
parents:
7867
diff
changeset
|
2308 # too old libtool? |
fe465f0f86fb
If $shrext_cmds isn't set for some reason, fallback to ".so" suffix.
Timo Sirainen <tss@iki.fi>
parents:
7867
diff
changeset
|
2309 MODULE_SUFFIX=.so |
fe465f0f86fb
If $shrext_cmds isn't set for some reason, fallback to ".so" suffix.
Timo Sirainen <tss@iki.fi>
parents:
7867
diff
changeset
|
2310 fi |
7826
b63aa0ffe564
Use dynamic module suffix provided by libtool rather than hardcoded ".so".
Timo Sirainen <tss@iki.fi>
parents:
7823
diff
changeset
|
2311 AC_DEFINE_UNQUOTED(MODULE_SUFFIX,"$MODULE_SUFFIX",Dynamic module suffix) |
b63aa0ffe564
Use dynamic module suffix provided by libtool rather than hardcoded ".so".
Timo Sirainen <tss@iki.fi>
parents:
7823
diff
changeset
|
2312 AC_SUBST(MODULE_SUFFIX) |
1511
a4ad03c210af
Check if dlopen is in libc too.
Timo Sirainen <tss@iki.fi>
parents:
1467
diff
changeset
|
2313 fi |
1150
18a2074a4d3d
Support for dynamic authentication modules.
Timo Sirainen <tss@iki.fi>
parents:
1096
diff
changeset
|
2314 |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2315 have_nss=no |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2316 if test $want_nss != no; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2317 if test $have_modules != yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2318 if test $want_nss = yes; then |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2319 AC_ERROR([Can't build with NSS support: Dynamic modules not supported]) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2320 fi |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2321 else |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2322 AC_CACHE_CHECK([for NSS support],i_cv_have_nss,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2323 AC_TRY_COMPILE([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2324 #include <nss.h> |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2325 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2326 enum nss_status status = NSS_STATUS_TRYAGAIN; |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2327 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2328 i_cv_have_nss=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2329 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2330 i_cv_have_nss=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2331 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2332 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2333 if test $i_cv_have_nss = yes; then |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2334 AC_DEFINE(USERDB_NSS,, Build with NSS module support) |
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2335 have_nss=yes |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2336 else |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2337 if test $want_nss = yes; then |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2338 AC_ERROR([Can't build with NSS support: nss.h not found or not usable]) |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2339 fi |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2340 fi |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2341 fi |
5870
c9b49ed99d28
Added userdb nss which currently supports glibc-compatible NSS modules.
Timo Sirainen <tss@iki.fi>
parents:
5859
diff
changeset
|
2342 fi |
c9b49ed99d28
Added userdb nss which currently supports glibc-compatible NSS modules.
Timo Sirainen <tss@iki.fi>
parents:
5859
diff
changeset
|
2343 |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2344 if test $have_nss = no; then |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2345 not_userdb="$not_userdb nss" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2346 else |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2347 userdb="$userdb nss" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2348 fi |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2349 |
1283
2d8af547a8b4
Added PostgreSQL support, patch by Alex Howansky
Timo Sirainen <tss@iki.fi>
parents:
1256
diff
changeset
|
2350 AC_SUBST(AUTH_CFLAGS) |
1284 | 2351 AC_SUBST(AUTH_LIBS) |
2754
3c3ac12be307
Created generic asynchronous SQL API and implemented MySQL and PostgreSQL
Timo Sirainen <tss@iki.fi>
parents:
2717
diff
changeset
|
2352 AC_SUBST(SQL_CFLAGS) |
3c3ac12be307
Created generic asynchronous SQL API and implemented MySQL and PostgreSQL
Timo Sirainen <tss@iki.fi>
parents:
2717
diff
changeset
|
2353 AC_SUBST(SQL_LIBS) |
6194
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2354 AC_SUBST(MYSQL_CFLAGS) |
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2355 AC_SUBST(MYSQL_LIBS) |
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2356 AC_SUBST(PGSQL_CFLAGS) |
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2357 AC_SUBST(PGSQL_LIBS) |
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2358 AC_SUBST(SQLITE_CFLAGS) |
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2359 AC_SUBST(SQLITE_LIBS) |
0 | 2360 |
4517
e661182eab75
Berkeley DB dict support is now enabled only when using --with-db configure option.
Timo Sirainen <timo.sirainen@movial.fi>
parents:
4482
diff
changeset
|
2361 AC_SUBST(DICT_LIBS) |
e661182eab75
Berkeley DB dict support is now enabled only when using --with-db configure option.
Timo Sirainen <timo.sirainen@movial.fi>
parents:
4482
diff
changeset
|
2362 AC_SUBST(dict_drivers) |
e661182eab75
Berkeley DB dict support is now enabled only when using --with-db configure option.
Timo Sirainen <timo.sirainen@movial.fi>
parents:
4482
diff
changeset
|
2363 |
0 | 2364 dnl ** |
8572
9ec2882243a6
Try to use (Apple) gcc's __BIG_ENDIAN__ and __LITTLE_ENDIAN__ macros if possible.
Timo Sirainen <tss@iki.fi>
parents:
8556
diff
changeset
|
2365 dnl ** Endianess |
0 | 2366 dnl ** |
2367 | |
8572
9ec2882243a6
Try to use (Apple) gcc's __BIG_ENDIAN__ and __LITTLE_ENDIAN__ macros if possible.
Timo Sirainen <tss@iki.fi>
parents:
8556
diff
changeset
|
2368 dnl At least Apple's gcc supports __BIG_ENDIAN__ and __LITTLE_ENDIAN__ |
9ec2882243a6
Try to use (Apple) gcc's __BIG_ENDIAN__ and __LITTLE_ENDIAN__ macros if possible.
Timo Sirainen <tss@iki.fi>
parents:
8556
diff
changeset
|
2369 dnl defines. Use them if possible to allow cross-compiling. |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2370 AC_CACHE_CHECK([if __BIG_ENDIAN__ or __LITTLE_ENDIAN__ is defined],i_cv_have___big_endian__,[ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2371 AC_TRY_COMPILE([ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2372 #if !(__BIG_ENDIAN__ || __LITTLE_ENDIAN__) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2373 #error nope |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2374 #endif |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2375 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2376 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2377 i_cv_have___big_endian__=yes |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2378 ], [ |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2379 i_cv_have___big_endian__=no |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2380 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2381 ]) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2382 if test $i_cv_have___big_endian__ = yes; then |
8572
9ec2882243a6
Try to use (Apple) gcc's __BIG_ENDIAN__ and __LITTLE_ENDIAN__ macros if possible.
Timo Sirainen <tss@iki.fi>
parents:
8556
diff
changeset
|
2383 AC_DEFINE(WORDS_BIGENDIAN, __BIG_ENDIAN__, Define if your CPU is big endian) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2384 else |
8572
9ec2882243a6
Try to use (Apple) gcc's __BIG_ENDIAN__ and __LITTLE_ENDIAN__ macros if possible.
Timo Sirainen <tss@iki.fi>
parents:
8556
diff
changeset
|
2385 AC_C_BIGENDIAN |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2386 fi |
0 | 2387 |
2388 dnl ** | |
2389 dnl ** IPv6 support | |
2390 dnl ** | |
2391 | |
6974
ec6cc297dd82
--with-package=yes now fails if package can't be used. --with-package=auto
Timo Sirainen <tss@iki.fi>
parents:
6919
diff
changeset
|
2392 have_ipv6=no |
9157
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2393 AC_MSG_CHECKING([for IPv6]) |
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2394 AC_CACHE_VAL(i_cv_type_in6_addr, |
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2395 [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ |
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2396 #include <sys/types.h> |
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2397 #include <sys/socket.h> |
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2398 #include <netinet/in.h> |
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2399 #include <netdb.h> |
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2400 #include <arpa/inet.h>]], |
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2401 [[struct in6_addr i;]])], |
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2402 [i_cv_type_in6_addr=yes], |
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2403 [i_cv_type_in6_addr=no])]) |
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2404 if test $i_cv_type_in6_addr = yes; then |
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2405 AC_DEFINE(HAVE_IPV6,, Build with IPv6 support) |
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2406 have_ipv6=yes |
0 | 2407 fi |
9157
ee378a4ba6cd
configure: Removed --disable-ipv6 parameter. There's really no point having it.
Timo Sirainen <tss@iki.fi>
parents:
9135
diff
changeset
|
2408 AC_MSG_RESULT($i_cv_type_in6_addr) |
0 | 2409 |
2410 dnl ** | |
1404
54015ae11177
--with-storage=maildir,mbox can now be used to compile in only the wanted
Timo Sirainen <tss@iki.fi>
parents:
1403
diff
changeset
|
2411 dnl ** storage classes |
54015ae11177
--with-storage=maildir,mbox can now be used to compile in only the wanted
Timo Sirainen <tss@iki.fi>
parents:
1403
diff
changeset
|
2412 dnl ** |
54015ae11177
--with-storage=maildir,mbox can now be used to compile in only the wanted
Timo Sirainen <tss@iki.fi>
parents:
1403
diff
changeset
|
2413 |
9017
1b586a2fee8b
Build libdovecot.so and libdovecot-storage.so.
Timo Sirainen <tss@iki.fi>
parents:
9016
diff
changeset
|
2414 maildir_libs='$(top_builddir)/src/lib-storage/index/maildir/libstorage_maildir.la' |
1b586a2fee8b
Build libdovecot.so and libdovecot-storage.so.
Timo Sirainen <tss@iki.fi>
parents:
9016
diff
changeset
|
2415 mbox_libs='$(top_builddir)/src/lib-storage/index/mbox/libstorage_mbox.la' |
9977
0bb321c347ae
Split dbox (single-dbox) and mdbox (multi-dbox) into separate storage backends.
Timo Sirainen <tss@iki.fi>
parents:
9973
diff
changeset
|
2416 dbox_common_libs='$(top_builddir)/src/lib-storage/index/dbox-common/libstorage_dbox_common.la' |
0bb321c347ae
Split dbox (single-dbox) and mdbox (multi-dbox) into separate storage backends.
Timo Sirainen <tss@iki.fi>
parents:
9973
diff
changeset
|
2417 dbox_libs='$(top_builddir)/src/lib-storage/index/dbox-single/libstorage_dbox_single.la' |
0bb321c347ae
Split dbox (single-dbox) and mdbox (multi-dbox) into separate storage backends.
Timo Sirainen <tss@iki.fi>
parents:
9973
diff
changeset
|
2418 mdbox_libs='$(top_builddir)/src/lib-storage/index/dbox-multi/libstorage_dbox_multi.la' |
9017
1b586a2fee8b
Build libdovecot.so and libdovecot-storage.so.
Timo Sirainen <tss@iki.fi>
parents:
9016
diff
changeset
|
2419 cydir_libs='$(top_builddir)/src/lib-storage/index/cydir/libstorage_cydir.la' |
1b586a2fee8b
Build libdovecot.so and libdovecot-storage.so.
Timo Sirainen <tss@iki.fi>
parents:
9016
diff
changeset
|
2420 raw_libs='$(top_builddir)/src/lib-storage/index/raw/libstorage_raw.la' |
1b586a2fee8b
Build libdovecot.so and libdovecot-storage.so.
Timo Sirainen <tss@iki.fi>
parents:
9016
diff
changeset
|
2421 shared_libs='$(top_builddir)/src/lib-storage/index/shared/libstorage_shared.la' |
8376
2d24b8b46308
$STORAGE_LIBS now contains all the libraries that libstorage needs.
Timo Sirainen <tss@iki.fi>
parents:
8354
diff
changeset
|
2422 |
9017
1b586a2fee8b
Build libdovecot.so and libdovecot-storage.so.
Timo Sirainen <tss@iki.fi>
parents:
9016
diff
changeset
|
2423 CORE_LIBS='$(top_builddir)/src/lib-dovecot/libdovecot.la' |
1b586a2fee8b
Build libdovecot.so and libdovecot-storage.so.
Timo Sirainen <tss@iki.fi>
parents:
9016
diff
changeset
|
2424 STORAGE_LIB='$(top_builddir)/src/lib-storage/libdovecot-storage.la' |
1404
54015ae11177
--with-storage=maildir,mbox can now be used to compile in only the wanted
Timo Sirainen <tss@iki.fi>
parents:
1403
diff
changeset
|
2425 |
9017
1b586a2fee8b
Build libdovecot.so and libdovecot-storage.so.
Timo Sirainen <tss@iki.fi>
parents:
9016
diff
changeset
|
2426 LINKED_STORAGE_LIBS= |
9091
e7dc0fb735ff
Removed configure --with-deliver and --with-pop3d parameters.
Timo Sirainen <tss@iki.fi>
parents:
9059
diff
changeset
|
2427 mail_storages="$mail_storages raw" |
9542
6350d105c34e
configure --with-storages: Drop duplicate storages.
Timo Sirainen <tss@iki.fi>
parents:
9538
diff
changeset
|
2428 # drop duplicates |
6350d105c34e
configure --with-storages: Drop duplicate storages.
Timo Sirainen <tss@iki.fi>
parents:
9538
diff
changeset
|
2429 mail_storages=`(for i in $mail_storages; do echo $i; done)|sort|uniq|xargs echo` |
1404
54015ae11177
--with-storage=maildir,mbox can now be used to compile in only the wanted
Timo Sirainen <tss@iki.fi>
parents:
1403
diff
changeset
|
2430 for storage in $mail_storages; do |
9017
1b586a2fee8b
Build libdovecot.so and libdovecot-storage.so.
Timo Sirainen <tss@iki.fi>
parents:
9016
diff
changeset
|
2431 LINKED_STORAGE_LIBS="$LINKED_STORAGE_LIBS `eval echo \\$${storage}_libs`" |
9977
0bb321c347ae
Split dbox (single-dbox) and mdbox (multi-dbox) into separate storage backends.
Timo Sirainen <tss@iki.fi>
parents:
9973
diff
changeset
|
2432 if test $storage = dbox || test $storage = mdbox; then |
0bb321c347ae
Split dbox (single-dbox) and mdbox (multi-dbox) into separate storage backends.
Timo Sirainen <tss@iki.fi>
parents:
9973
diff
changeset
|
2433 LINKED_STORAGE_LIBS="$LINKED_STORAGE_LIBS $dbox_common_libs" |
0bb321c347ae
Split dbox (single-dbox) and mdbox (multi-dbox) into separate storage backends.
Timo Sirainen <tss@iki.fi>
parents:
9973
diff
changeset
|
2434 dbox_common_libs="" |
0bb321c347ae
Split dbox (single-dbox) and mdbox (multi-dbox) into separate storage backends.
Timo Sirainen <tss@iki.fi>
parents:
9973
diff
changeset
|
2435 fi |
1404
54015ae11177
--with-storage=maildir,mbox can now be used to compile in only the wanted
Timo Sirainen <tss@iki.fi>
parents:
1403
diff
changeset
|
2436 done |
9017
1b586a2fee8b
Build libdovecot.so and libdovecot-storage.so.
Timo Sirainen <tss@iki.fi>
parents:
9016
diff
changeset
|
2437 AC_SUBST(LINKED_STORAGE_LIBS) |
6635
e4f9e2b94a90
Show mail storages in dovecot --build-options.
Timo Sirainen <tss@iki.fi>
parents:
6616
diff
changeset
|
2438 AC_DEFINE_UNQUOTED(MAIL_STORAGES, "$mail_storages", List of compiled in mail storages) |
1404
54015ae11177
--with-storage=maildir,mbox can now be used to compile in only the wanted
Timo Sirainen <tss@iki.fi>
parents:
1403
diff
changeset
|
2439 |
54015ae11177
--with-storage=maildir,mbox can now be used to compile in only the wanted
Timo Sirainen <tss@iki.fi>
parents:
1403
diff
changeset
|
2440 dnl ** |
9104
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2441 dnl ** Shared libraries usage |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2442 dnl ** |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2443 |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2444 if test "$want_shared_libs" = "yes"; then |
10091
6a1c96577476
Makefiles: Separated LIBDOVECOT and LIBDOVECOT_DEPS.
Timo Sirainen <tss@iki.fi>
parents:
10052
diff
changeset
|
2445 LIBDOVECOT_DEPS='$(top_builddir)/src/lib-dovecot/libdovecot.la' |
6a1c96577476
Makefiles: Separated LIBDOVECOT and LIBDOVECOT_DEPS.
Timo Sirainen <tss@iki.fi>
parents:
10052
diff
changeset
|
2446 LIBDOVECOT="$LIBDOVECOT_DEPS" |
9104
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2447 LIBDOVECOT_STORAGE='$(top_builddir)/src/lib-storage/libdovecot-storage.la' |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2448 LIBDOVECOT_LOGIN='$(top_builddir)/src/login-common/libdovecot-login.la' |
11370
f0141862bdca
configure: --without-shared-libs should use static liblda for lda/lmtp.
Timo Sirainen <tss@iki.fi>
parents:
11356
diff
changeset
|
2449 LIBDOVECOT_LDA='$(top_builddir)/src/lib-lda/libdovecot-lda.la' |
9104
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2450 else |
10615
8f9fc7fa7c73
Added dns-client service and library for doing async dns lookups.
Timo Sirainen <tss@iki.fi>
parents:
10600
diff
changeset
|
2451 LIBDOVECOT_DEPS='$(top_builddir)/src/lib-master/libmaster.la $(top_builddir)/src/lib-settings/libsettings.la $(top_builddir)/src/lib-dict/libdict.la $(top_builddir)/src/lib-dns/libdns.la $(top_builddir)/src/lib-imap/libimap.la $(top_builddir)/src/lib-mail/libmail.la $(top_builddir)/src/lib-auth/libauth.la $(top_builddir)/src/lib-charset/libcharset.la $(top_builddir)/src/lib/liblib.la' |
10091
6a1c96577476
Makefiles: Separated LIBDOVECOT and LIBDOVECOT_DEPS.
Timo Sirainen <tss@iki.fi>
parents:
10052
diff
changeset
|
2452 LIBDOVECOT="$LIBDOVECOT_DEPS \$(LIBICONV)" |
9135
43ce0506a90b
configure --without-shared-libs: Don't link other libraries to libstorage.a.
Timo Sirainen <tss@iki.fi>
parents:
9121
diff
changeset
|
2453 LIBDOVECOT_STORAGE_LAST='$(top_builddir)/src/lib-storage/list/libstorage_list.la $(top_builddir)/src/lib-storage/index/libstorage_index.la $(top_builddir)/src/lib-storage/libstorage.la $(top_builddir)/src/lib-index/libindex.la' |
43ce0506a90b
configure --without-shared-libs: Don't link other libraries to libstorage.a.
Timo Sirainen <tss@iki.fi>
parents:
9121
diff
changeset
|
2454 LIBDOVECOT_STORAGE_FIRST='$(top_builddir)/src/lib-storage/libstorage_service.la $(top_builddir)/src/lib-storage/register/libstorage_register.la' |
43ce0506a90b
configure --without-shared-libs: Don't link other libraries to libstorage.a.
Timo Sirainen <tss@iki.fi>
parents:
9121
diff
changeset
|
2455 LIBDOVECOT_STORAGE="$LIBDOVECOT_STORAGE_FIRST $LINKED_STORAGE_LIBS $LIBDOVECOT_STORAGE_LAST" |
9104
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2456 LIBDOVECOT_LOGIN='$(top_builddir)/src/login-common/liblogin.la' |
11370
f0141862bdca
configure: --without-shared-libs should use static liblda for lda/lmtp.
Timo Sirainen <tss@iki.fi>
parents:
11356
diff
changeset
|
2457 LIBDOVECOT_LDA='$(top_builddir)/src/lib-lda/liblda.la' |
9104
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2458 fi |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2459 LIBDOVECOT_SQL='$(top_builddir)/src/lib-sql/libsql.la' |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2460 AC_SUBST(LIBDOVECOT) |
10091
6a1c96577476
Makefiles: Separated LIBDOVECOT and LIBDOVECOT_DEPS.
Timo Sirainen <tss@iki.fi>
parents:
10052
diff
changeset
|
2461 AC_SUBST(LIBDOVECOT_DEPS) |
9104
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2462 AC_SUBST(LIBDOVECOT_STORAGE) |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2463 AC_SUBST(LIBDOVECOT_LOGIN) |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2464 AC_SUBST(LIBDOVECOT_SQL) |
11186
1319fa7a7266
lib-lda is now an installed shared library.
Timo Sirainen <tss@iki.fi>
parents:
11120
diff
changeset
|
2465 AC_SUBST(LIBDOVECOT_LDA) |
9104
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2466 |
c6d306772f4e
Added configure --without-shared-libs to link built binaries against static libraries.
Timo Sirainen <tss@iki.fi>
parents:
9092
diff
changeset
|
2467 dnl ** |
3943
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2468 dnl ** SQL drivers |
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2469 dnl ** |
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2470 |
6194
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2471 build_pgsql=no |
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2472 build_mysql=no |
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2473 build_sqlite=no |
3943
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2474 for driver in $sql_drivers; do |
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2475 if test "$driver" = "pgsql"; then |
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2476 AC_DEFINE(BUILD_PGSQL,, Built-in PostgreSQL support) |
6194
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2477 build_pgsql=yes |
3943
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2478 elif test "$driver" = "mysql"; then |
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2479 AC_DEFINE(BUILD_MYSQL,, Built-in MySQL support) |
6194
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2480 build_mysql=yes |
3943
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2481 elif test "$driver" = "sqlite"; then |
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2482 AC_DEFINE(BUILD_SQLITE,, Built-in SQLite support) |
6194
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2483 build_sqlite=yes |
3943
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2484 fi |
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2485 done |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2486 if test $build_pgsql = no; then |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2487 not_sql_drivers="$not_sql_drivers pgsql" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2488 fi |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2489 if test $build_mysql = no; then |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2490 not_sql_drivers="$not_sql_drivers mysql" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2491 fi |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2492 if test $build_sqlite = no; then |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2493 not_sql_drivers="$not_sql_drivers sqlite" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2494 fi |
3943
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2495 |
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2496 AC_SUBST(sql_drivers) |
6194
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2497 AM_CONDITIONAL(BUILD_PGSQL, test "$build_pgsql" = "yes") |
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2498 AM_CONDITIONAL(BUILD_MYSQL, test "$build_mysql" = "yes") |
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2499 AM_CONDITIONAL(BUILD_SQLITE, test "$build_sqlite" = "yes") |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
2500 AM_CONDITIONAL(SQL_PLUGINS, test "$want_sql" = "plugin") |
3943
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2501 |
cbe5c6772e0d
Added support for dynamically building SQL drivers.
Timo Sirainen <tss@iki.fi>
parents:
3934
diff
changeset
|
2502 dnl ** |
3969
884da753caba
If zlib.h isn't found, don't try to build the zlib plugin.
Timo Sirainen <tss@iki.fi>
parents:
3948
diff
changeset
|
2503 dnl ** Plugins |
884da753caba
If zlib.h isn't found, don't try to build the zlib plugin.
Timo Sirainen <tss@iki.fi>
parents:
3948
diff
changeset
|
2504 dnl ** |
884da753caba
If zlib.h isn't found, don't try to build the zlib plugin.
Timo Sirainen <tss@iki.fi>
parents:
3948
diff
changeset
|
2505 |
8090
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2506 if test "$want_zlib" != "no"; then |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2507 AC_CHECK_HEADER(zlib.h, [ |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2508 have_zlib=yes |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2509 have_zlib_plugin=yes |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2510 AC_DEFINE(HAVE_ZLIB,, Define if you have zlib library) |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2511 ], [ |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2512 if test "$want_zlib" = "yes"; then |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2513 AC_ERROR([Can't build with zlib support: zlib.h not found]) |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2514 fi |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2515 ]) |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2516 fi |
3969
884da753caba
If zlib.h isn't found, don't try to build the zlib plugin.
Timo Sirainen <tss@iki.fi>
parents:
3948
diff
changeset
|
2517 AM_CONDITIONAL(BUILD_ZLIB, test "$have_zlib" = "yes") |
884da753caba
If zlib.h isn't found, don't try to build the zlib plugin.
Timo Sirainen <tss@iki.fi>
parents:
3948
diff
changeset
|
2518 |
8090
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2519 if test "$want_bzlib" != "no"; then |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2520 AC_CHECK_HEADER(bzlib.h, [ |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2521 AC_CHECK_LIB(bz2, BZ2_bzdopen, [ |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2522 have_bzlib=yes |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2523 have_zlib_plugin=yes |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2524 AC_DEFINE(HAVE_BZLIB,, Define if you have bzlib library) |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2525 ], [ |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2526 if test "$want_bzlib" = "yes"; then |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2527 AC_ERROR([Can't build with bzlib support: libbz2 not found]) |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2528 fi |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2529 ]) |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2530 ], [ |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2531 if test "$want_bzlib" = "yes"; then |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2532 AC_ERROR([Can't build with bzlib support: bzlib.h not found]) |
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2533 fi |
8046
8afc9ddd723e
Check that libbz2 has correct functions. Old versions had different names.
Timo Sirainen <tss@iki.fi>
parents:
8022
diff
changeset
|
2534 ]) |
8090
75b1f16cba72
Added --with-zlib and --with-bzlib configure options.
Timo Sirainen <tss@iki.fi>
parents:
8076
diff
changeset
|
2535 fi |
7981
bb9d3aabcb61
zlib plugin supports now bzip2 also.
Timo Sirainen <tss@iki.fi>
parents:
7958
diff
changeset
|
2536 AM_CONDITIONAL(BUILD_BZLIB, test "$have_bzlib" = "yes") |
bb9d3aabcb61
zlib plugin supports now bzip2 also.
Timo Sirainen <tss@iki.fi>
parents:
7958
diff
changeset
|
2537 AM_CONDITIONAL(BUILD_ZLIB_PLUGIN, test "$have_zlib_plugin" = "yes") |
bb9d3aabcb61
zlib plugin supports now bzip2 also.
Timo Sirainen <tss@iki.fi>
parents:
7958
diff
changeset
|
2538 |
6177
abec53314897
Build rquota_xdr.c with rpcgen from rquota.x.
Timo Sirainen <tss@iki.fi>
parents:
6159
diff
changeset
|
2539 RPCGEN=${RPCGEN-rpcgen} |
abec53314897
Build rquota_xdr.c with rpcgen from rquota.x.
Timo Sirainen <tss@iki.fi>
parents:
6159
diff
changeset
|
2540 if ! $RPCGEN -c /dev/null > /dev/null; then |
abec53314897
Build rquota_xdr.c with rpcgen from rquota.x.
Timo Sirainen <tss@iki.fi>
parents:
6159
diff
changeset
|
2541 RPCGEN= |
abec53314897
Build rquota_xdr.c with rpcgen from rquota.x.
Timo Sirainen <tss@iki.fi>
parents:
6159
diff
changeset
|
2542 fi |
abec53314897
Build rquota_xdr.c with rpcgen from rquota.x.
Timo Sirainen <tss@iki.fi>
parents:
6159
diff
changeset
|
2543 AC_SUBST(RPCGEN) |
abec53314897
Build rquota_xdr.c with rpcgen from rquota.x.
Timo Sirainen <tss@iki.fi>
parents:
6159
diff
changeset
|
2544 |
6159
078d9dde99c8
Support for rquota with NFS mounts. Patch by HTK NetCommunication Oy.
Timo Sirainen <tss@iki.fi>
parents:
6111
diff
changeset
|
2545 have_rquota=no |
6177
abec53314897
Build rquota_xdr.c with rpcgen from rquota.x.
Timo Sirainen <tss@iki.fi>
parents:
6159
diff
changeset
|
2546 if test -f /usr/include/rpcsvc/rquota.x && test -n "$RPCGEN"; then |
6159
078d9dde99c8
Support for rquota with NFS mounts. Patch by HTK NetCommunication Oy.
Timo Sirainen <tss@iki.fi>
parents:
6111
diff
changeset
|
2547 AC_DEFINE(HAVE_RQUOTA,, Define if you wish to retrieve quota of NFS mounted mailboxes) |
078d9dde99c8
Support for rquota with NFS mounts. Patch by HTK NetCommunication Oy.
Timo Sirainen <tss@iki.fi>
parents:
6111
diff
changeset
|
2548 have_rquota=yes |
6177
abec53314897
Build rquota_xdr.c with rpcgen from rquota.x.
Timo Sirainen <tss@iki.fi>
parents:
6159
diff
changeset
|
2549 fi |
6159
078d9dde99c8
Support for rquota with NFS mounts. Patch by HTK NetCommunication Oy.
Timo Sirainen <tss@iki.fi>
parents:
6111
diff
changeset
|
2550 AM_CONDITIONAL(HAVE_RQUOTA, test "$have_rquota" = "yes") |
078d9dde99c8
Support for rquota with NFS mounts. Patch by HTK NetCommunication Oy.
Timo Sirainen <tss@iki.fi>
parents:
6111
diff
changeset
|
2551 |
7990
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2552 if test "$want_solr" != "no"; then |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2553 AC_CHECK_PROG(CURLCONFIG, curl-config, YES, NO) |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2554 if test $CURLCONFIG = YES; then |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2555 CURL_CFLAGS=`curl-config --cflags` |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2556 CURL_LIBS=`curl-config --libs` |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2557 |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2558 dnl libcurl found, also need libexpat |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2559 AC_CHECK_LIB(expat, XML_Parse, [ |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2560 AC_CHECK_HEADER(expat.h, [ |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2561 AC_SUBST(CURL_CFLAGS) |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2562 AC_SUBST(CURL_LIBS) |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2563 have_solr=yes |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2564 ], [ |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2565 if test $want_solr = yes; then |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2566 AC_ERROR([Can't build with Solr support: expat.h not found]) |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2567 fi |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2568 ]) |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2569 ], [ |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2570 if test $want_solr = yes; then |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2571 AC_ERROR([Can't build with Solr support: libexpat not found]) |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2572 fi |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2573 ]) |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2574 else |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2575 if test $want_solr = yes; then |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2576 AC_ERROR([Can't build with Solr support: curl-config not found]) |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2577 fi |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2578 fi |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2579 fi |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2580 AM_CONDITIONAL(BUILD_SOLR, test "$have_solr" = "yes") |
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2581 |
3969
884da753caba
If zlib.h isn't found, don't try to build the zlib plugin.
Timo Sirainen <tss@iki.fi>
parents:
3948
diff
changeset
|
2582 dnl ** |
9002
9d0037a997f4
Initial commit for config rewrite.
Timo Sirainen <tss@iki.fi>
parents:
8601
diff
changeset
|
2583 dnl ** Settings |
9d0037a997f4
Initial commit for config rewrite.
Timo Sirainen <tss@iki.fi>
parents:
8601
diff
changeset
|
2584 dnl ** |
9d0037a997f4
Initial commit for config rewrite.
Timo Sirainen <tss@iki.fi>
parents:
8601
diff
changeset
|
2585 |
9d0037a997f4
Initial commit for config rewrite.
Timo Sirainen <tss@iki.fi>
parents:
8601
diff
changeset
|
2586 dnl get a list of setting .[ch] files, but list .h files first |
10336
e18645b47984
config: Allow settings plugins to specify also new default services.
Timo Sirainen <tss@iki.fi>
parents:
10295
diff
changeset
|
2587 FILES1=`find $srcdir/src -name '*settings.[[ch]]'|grep "$srcdir/src/lib-" | sed 's/^\(.*\)\(.\)$/\2 \1\2/' | sort -r | sed s/^..//` |
e18645b47984
config: Allow settings plugins to specify also new default services.
Timo Sirainen <tss@iki.fi>
parents:
10295
diff
changeset
|
2588 FILES2=`find $srcdir/src -name '*settings.[[ch]]'|grep -v "$srcdir/src/lib-" | sed 's/^\(.*\)\(.\)$/\2 \1\2/' | grep -v all-settings | sort -r | sed s/^..//` |
10702
dc6cf5f10602
configure: If libwrap isn't used, don't add its service to doveconf.
Timo Sirainen <tss@iki.fi>
parents:
10700
diff
changeset
|
2589 SETTING_FILES=`echo $FILES1 $FILES2 | sed -e s,$srcdir/src,./src,g -e 's,./src,$(top_srcdir)/src,g'` |
9002
9d0037a997f4
Initial commit for config rewrite.
Timo Sirainen <tss@iki.fi>
parents:
8601
diff
changeset
|
2590 AC_SUBST(SETTING_FILES) |
9d0037a997f4
Initial commit for config rewrite.
Timo Sirainen <tss@iki.fi>
parents:
8601
diff
changeset
|
2591 |
9d0037a997f4
Initial commit for config rewrite.
Timo Sirainen <tss@iki.fi>
parents:
8601
diff
changeset
|
2592 dnl ** |
0 | 2593 dnl ** capabilities |
2594 dnl ** | |
2595 | |
7924
30871a9961f7
Include ENABLE in banner capabilities, since it can be pipelined after login.
Timo Sirainen <tss@iki.fi>
parents:
7922
diff
changeset
|
2596 capability_banner="IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE" |
10567
7fe775a404b1
Added LIST-STATUS to CAPABILITY list.
Timo Sirainen <tss@iki.fi>
parents:
10551
diff
changeset
|
2597 capability="$capability_banner SORT SORT=DISPLAY THREAD=REFERENCES THREAD=REFS MULTIAPPEND UNSELECT IDLE CHILDREN NAMESPACE UIDPLUS LIST-EXTENDED I18NLEVEL=1 CONDSTORE QRESYNC ESEARCH ESORT SEARCHRES WITHIN CONTEXT=SEARCH LIST-STATUS" |
742
b3dd87844fff
acconfig.h is deprecated with autoconf 2.5, changed configure to contain
Timo Sirainen <tss@iki.fi>
parents:
739
diff
changeset
|
2598 AC_DEFINE_UNQUOTED(CAPABILITY_STRING, "$capability", IMAP capabilities) |
7922
4b4d2a4423ec
Removed login_greeting_capability setting. Instead now a minimal pre-login
Timo Sirainen <tss@iki.fi>
parents:
7917
diff
changeset
|
2599 AC_DEFINE_UNQUOTED(CAPABILITY_BANNER_STRING, "$capability_banner", IMAP capabilities advertised in banner) |
0 | 2600 |
843
e9a5ce16f0f3
EXTRA_CFLAGS environment is now added to CFLAGS after all tests. Useful for adding -Werror there.
Timo Sirainen <tss@iki.fi>
parents:
835
diff
changeset
|
2601 CFLAGS="$CFLAGS $EXTRA_CFLAGS" |
e9a5ce16f0f3
EXTRA_CFLAGS environment is now added to CFLAGS after all tests. Useful for adding -Werror there.
Timo Sirainen <tss@iki.fi>
parents:
835
diff
changeset
|
2602 |
7297
2cda05620383
Added support for autoconf versions older than 2.59c.
Timo Sirainen <tss@iki.fi>
parents:
7285
diff
changeset
|
2603 if test "$docdir" = ""; then |
2cda05620383
Added support for autoconf versions older than 2.59c.
Timo Sirainen <tss@iki.fi>
parents:
7285
diff
changeset
|
2604 dnl docdir supported only by autoconf v2.59c and later |
7298
86af79a203d7
Base docdir to datadir instead of datarootdir which doesn't exist in old
Timo Sirainen <tss@iki.fi>
parents:
7297
diff
changeset
|
2605 docdir='${datadir}/doc/${PACKAGE_TARNAME}' |
7297
2cda05620383
Added support for autoconf versions older than 2.59c.
Timo Sirainen <tss@iki.fi>
parents:
7285
diff
changeset
|
2606 fi |
2cda05620383
Added support for autoconf versions older than 2.59c.
Timo Sirainen <tss@iki.fi>
parents:
7285
diff
changeset
|
2607 AC_SUBST(docdir) |
2cda05620383
Added support for autoconf versions older than 2.59c.
Timo Sirainen <tss@iki.fi>
parents:
7285
diff
changeset
|
2608 |
10994
c78fe7920deb
If valgrind exists, run unit tests using it.
Timo Sirainen <tss@iki.fi>
parents:
10980
diff
changeset
|
2609 AC_CHECK_PROG(VALGRIND, valgrind, YES, NO) |
c78fe7920deb
If valgrind exists, run unit tests using it.
Timo Sirainen <tss@iki.fi>
parents:
10980
diff
changeset
|
2610 if test $VALGRIND = YES; then |
c78fe7920deb
If valgrind exists, run unit tests using it.
Timo Sirainen <tss@iki.fi>
parents:
10980
diff
changeset
|
2611 RUN_TEST='$(SHELL) $(top_srcdir)/run-test.sh' |
c78fe7920deb
If valgrind exists, run unit tests using it.
Timo Sirainen <tss@iki.fi>
parents:
10980
diff
changeset
|
2612 else |
c78fe7920deb
If valgrind exists, run unit tests using it.
Timo Sirainen <tss@iki.fi>
parents:
10980
diff
changeset
|
2613 RUN_TEST='' |
c78fe7920deb
If valgrind exists, run unit tests using it.
Timo Sirainen <tss@iki.fi>
parents:
10980
diff
changeset
|
2614 fi |
c78fe7920deb
If valgrind exists, run unit tests using it.
Timo Sirainen <tss@iki.fi>
parents:
10980
diff
changeset
|
2615 AC_SUBST(RUN_TEST) |
10014
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2616 AC_SUBST(abs_top_builddir) |
e7f8f15f1c4c
configure: Use cache for more checks.
Timo Sirainen <tss@iki.fi>
parents:
10001
diff
changeset
|
2617 |
3782
c67f77647a6e
Added kqueue notification support. Patch by Vaclav Haisman
Timo Sirainen <tss@iki.fi>
parents:
3780
diff
changeset
|
2618 AC_CONFIG_HEADERS([config.h]) |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
2619 AC_CONFIG_FILES([ |
0 | 2620 Makefile |
2621 doc/Makefile | |
5441
9d36800df1ae
Added documentation to doc/wiki/. autogen.sh downloads them from dovecot.org
Timo Sirainen <tss@iki.fi>
parents:
5375
diff
changeset
|
2622 doc/wiki/Makefile |
9842
e95135898a3c
Split dovecot-example.conf to multiple files. Also it's now installed under docdir.
Timo Sirainen <tss@iki.fi>
parents:
9812
diff
changeset
|
2623 doc/example-config/Makefile |
e95135898a3c
Split dovecot-example.conf to multiple files. Also it's now installed under docdir.
Timo Sirainen <tss@iki.fi>
parents:
9812
diff
changeset
|
2624 doc/example-config/conf.d/Makefile |
0 | 2625 src/Makefile |
2626 src/lib/Makefile | |
2754
3c3ac12be307
Created generic asynchronous SQL API and implemented MySQL and PostgreSQL
Timo Sirainen <tss@iki.fi>
parents:
2717
diff
changeset
|
2627 src/lib-sql/Makefile |
1702
43815588dd6b
Moved client side code for auth process handling to lib-auth. Some other login process cleanups.
Timo Sirainen <tss@iki.fi>
parents:
1694
diff
changeset
|
2628 src/lib-auth/Makefile |
568
f2aa58c2afd0
SEARCH CHARSET support. Currently we do it through iconv() and only ASCII
Timo Sirainen <tss@iki.fi>
parents:
550
diff
changeset
|
2629 src/lib-charset/Makefile |
3737
d67092398377
Added dictionary API and implementation for SQL. It's meant for looking and
Timo Sirainen <tss@iki.fi>
parents:
3720
diff
changeset
|
2630 src/lib-dict/Makefile |
10615
8f9fc7fa7c73
Added dns-client service and library for doing async dns lookups.
Timo Sirainen <tss@iki.fi>
parents:
10600
diff
changeset
|
2631 src/lib-dns/Makefile |
0 | 2632 src/lib-imap/Makefile |
2633 src/lib-index/Makefile | |
9092
e4832f128738
Renamed deliver to dovecot-lda and moved most of its code to lib-lda.
Timo Sirainen <tss@iki.fi>
parents:
9091
diff
changeset
|
2634 src/lib-lda/Makefile |
0 | 2635 src/lib-mail/Makefile |
9059
94ecf8a8ed68
Added lib-master and mail-storage-service code that makes it easier to build new Dovecot binaries.
Timo Sirainen <tss@iki.fi>
parents:
9017
diff
changeset
|
2636 src/lib-master/Makefile |
2377
8f5be0be3199
NTLM authentication. Patch by Andrey Panin
Timo Sirainen <tss@iki.fi>
parents:
2369
diff
changeset
|
2637 src/lib-ntlm/Makefile |
4798
c04189d77a59
Added OTP and S/KEY authentication mechanisms. Patch by Andrey Panin.
Timo Sirainen <tss@iki.fi>
parents:
4736
diff
changeset
|
2638 src/lib-otp/Makefile |
9017
1b586a2fee8b
Build libdovecot.so and libdovecot-storage.so.
Timo Sirainen <tss@iki.fi>
parents:
9016
diff
changeset
|
2639 src/lib-dovecot/Makefile |
1058
3b8fb7bf7ecc
Moved settings parsing to lib-settings.
Timo Sirainen <tss@iki.fi>
parents:
1057
diff
changeset
|
2640 src/lib-settings/Makefile |
9258
665ea7a8d26e
Tests are now run on "make check". Added initial tests for lib-index.
Timo Sirainen <tss@iki.fi>
parents:
9246
diff
changeset
|
2641 src/lib-test/Makefile |
0 | 2642 src/lib-storage/Makefile |
4808
93bc9770f938
Initial code for separation of mailbox accessing and directory layout
Timo Sirainen <tss@iki.fi>
parents:
4798
diff
changeset
|
2643 src/lib-storage/list/Makefile |
0 | 2644 src/lib-storage/index/Makefile |
2645 src/lib-storage/index/maildir/Makefile | |
2646 src/lib-storage/index/mbox/Makefile | |
9977
0bb321c347ae
Split dbox (single-dbox) and mdbox (multi-dbox) into separate storage backends.
Timo Sirainen <tss@iki.fi>
parents:
9973
diff
changeset
|
2647 src/lib-storage/index/dbox-common/Makefile |
0bb321c347ae
Split dbox (single-dbox) and mdbox (multi-dbox) into separate storage backends.
Timo Sirainen <tss@iki.fi>
parents:
9973
diff
changeset
|
2648 src/lib-storage/index/dbox-multi/Makefile |
0bb321c347ae
Split dbox (single-dbox) and mdbox (multi-dbox) into separate storage backends.
Timo Sirainen <tss@iki.fi>
parents:
9973
diff
changeset
|
2649 src/lib-storage/index/dbox-single/Makefile |
5458
daca7ed634c0
Added a simple cydir mail storage backend. It trusts index files completely:
Timo Sirainen <tss@iki.fi>
parents:
5456
diff
changeset
|
2650 src/lib-storage/index/cydir/Makefile |
6748
d712370dfd14
Added raw storage for opening single-mail files/streams as mailboxes.
Timo Sirainen <tss@iki.fi>
parents:
6734
diff
changeset
|
2651 src/lib-storage/index/raw/Makefile |
8173
6dd0c6755afe
Added initial support for shared mailboxes. Listing isn't supported yet.
Timo Sirainen <tss@iki.fi>
parents:
8161
diff
changeset
|
2652 src/lib-storage/index/shared/Makefile |
761
d3bd41a56309
First implementation of SORT extension. String comparing still not up to
Timo Sirainen <tss@iki.fi>
parents:
755
diff
changeset
|
2653 src/lib-storage/register/Makefile |
9235
2e2b957f1cca
Implemented anvil service, which is used to implement mail_max_userip_connections.
Timo Sirainen <tss@iki.fi>
parents:
9204
diff
changeset
|
2654 src/anvil/Makefile |
0 | 2655 src/auth/Makefile |
9002
9d0037a997f4
Initial commit for config rewrite.
Timo Sirainen <tss@iki.fi>
parents:
8601
diff
changeset
|
2656 src/config/Makefile |
10001
a02c1d9df1bf
Moved doveadm to a separate directory and made it a bit more easily extensible.
Timo Sirainen <tss@iki.fi>
parents:
9985
diff
changeset
|
2657 src/doveadm/Makefile |
9559 | 2658 src/dsync/Makefile |
9092
e4832f128738
Renamed deliver to dovecot-lda and moved most of its code to lib-lda.
Timo Sirainen <tss@iki.fi>
parents:
9091
diff
changeset
|
2659 src/lda/Makefile |
9159
6324a79d3ee1
Initial commit for v2.0 master rewrite. Several features are still missing.
Timo Sirainen <tss@iki.fi>
parents:
9158
diff
changeset
|
2660 src/log/Makefile |
9121
a957a6be4af5
Initial implementation of LMTP server. Master process doesn't yet execute it though.
Timo Sirainen <tss@iki.fi>
parents:
9104
diff
changeset
|
2661 src/lmtp/Makefile |
3779
e87a8db60d25
Added --with-docs parameter to specify if documentation should be installed.
Timo Sirainen <tss@iki.fi>
parents:
3762
diff
changeset
|
2662 src/dict/Makefile |
11321
5f350b5ff6d9
Added initial implementation of a director process (for NFS users).
Timo Sirainen <tss@iki.fi>
parents:
11274
diff
changeset
|
2663 src/director/Makefile |
10615
8f9fc7fa7c73
Added dns-client service and library for doing async dns lookups.
Timo Sirainen <tss@iki.fi>
parents:
10600
diff
changeset
|
2664 src/dns/Makefile |
0 | 2665 src/imap/Makefile |
1049
c41787e8c3f4
Moved common login process code to login-common, created pop3-login.
Timo Sirainen <tss@iki.fi>
parents:
1043
diff
changeset
|
2666 src/imap-login/Makefile |
c41787e8c3f4
Moved common login process code to login-common, created pop3-login.
Timo Sirainen <tss@iki.fi>
parents:
1043
diff
changeset
|
2667 src/login-common/Makefile |
0 | 2668 src/master/Makefile |
1043
cacabd33c68a
Initial code for POP3 server. RETR isn't working right yet, there's some
Timo Sirainen <tss@iki.fi>
parents:
1022
diff
changeset
|
2669 src/pop3/Makefile |
1049
c41787e8c3f4
Moved common login process code to login-common, created pop3-login.
Timo Sirainen <tss@iki.fi>
parents:
1043
diff
changeset
|
2670 src/pop3-login/Makefile |
9985
ea36bad4d9da
Added ssl-params binary that login process uses to read SSL parameters.
Timo Sirainen <tss@iki.fi>
parents:
9977
diff
changeset
|
2671 src/ssl-params/Makefile |
1694
0fae24674a9a
Separated rawlog into it's own binary.
Timo Sirainen <tss@iki.fi>
parents:
1669
diff
changeset
|
2672 src/util/Makefile |
3738
732b62dc1976
Added beginnings of plugin infrastructure. TODO: These could be optionally
Timo Sirainen <tss@iki.fi>
parents:
3737
diff
changeset
|
2673 src/plugins/Makefile |
4082 | 2674 src/plugins/acl/Makefile |
8418
29b1ec15880a
Added IMAP ACL commands with ability to modify ACLs.
Timo Sirainen <tss@iki.fi>
parents:
8398
diff
changeset
|
2675 src/plugins/imap-acl/Makefile |
8295 | 2676 src/plugins/autocreate/Makefile |
4523
99699cf9df43
Initial import of expire plugin code. Seems to work with at least one user. :)
Timo Sirainen <timo.sirainen@movial.fi>
parents:
4517
diff
changeset
|
2677 src/plugins/expire/Makefile |
4609
48a16f1254b5
Added full text search plugin framework. Still missing support for handling
Timo Sirainen <tss@iki.fi>
parents:
4599
diff
changeset
|
2678 src/plugins/fts/Makefile |
4621
446646de0c4a
--with-lucene now enables lucene full text search indexing. Note that using
Timo Sirainen <tss@iki.fi>
parents:
4609
diff
changeset
|
2679 src/plugins/fts-lucene/Makefile |
7990
662172573fe1
Initial code to support Apache Solr (Lucene indexing server).
Timo Sirainen <tss@iki.fi>
parents:
7983
diff
changeset
|
2680 src/plugins/fts-solr/Makefile |
4855
5bc593f1a8f6
Added "squat" full text search indexer backend. Its name and basic ideas
Timo Sirainen <tss@iki.fi>
parents:
4840
diff
changeset
|
2681 src/plugins/fts-squat/Makefile |
4913
dea1c8fa53f4
Added lazy expunge plugin.
Timo Sirainen <timo.sirainen@movial.fi>
parents:
4862
diff
changeset
|
2682 src/plugins/lazy-expunge/Makefile |
8297 | 2683 src/plugins/listescape/Makefile |
5034
1b28e0434d85
Added mail_log plugin to log various mail operations. Currently it logs mail
Timo Sirainen <tss@iki.fi>
parents:
5009
diff
changeset
|
2684 src/plugins/mail-log/Makefile |
5633
fbb4bdbbf374
Added mbox snarf plugin to move mails from /var/spool/mail to ~/mbox if it
Timo Sirainen <tss@iki.fi>
parents:
5578
diff
changeset
|
2685 src/plugins/mbox-snarf/Makefile |
9812
f751c23561f9
Added a notify plugin that can be used as a generic event catching framework by other plugins.
Timo Sirainen <tss@iki.fi>
parents:
9749
diff
changeset
|
2686 src/plugins/notify/Makefile |
3738
732b62dc1976
Added beginnings of plugin infrastructure. TODO: These could be optionally
Timo Sirainen <tss@iki.fi>
parents:
3737
diff
changeset
|
2687 src/plugins/quota/Makefile |
732b62dc1976
Added beginnings of plugin infrastructure. TODO: These could be optionally
Timo Sirainen <tss@iki.fi>
parents:
3737
diff
changeset
|
2688 src/plugins/imap-quota/Makefile |
732b62dc1976
Added beginnings of plugin infrastructure. TODO: These could be optionally
Timo Sirainen <tss@iki.fi>
parents:
3737
diff
changeset
|
2689 src/plugins/trash/Makefile |
7663
8fc919084252
Added initial support for virtual mailboxes.
Timo Sirainen <tss@iki.fi>
parents:
7391
diff
changeset
|
2690 src/plugins/virtual/Makefile |
3800 | 2691 src/plugins/zlib/Makefile |
10699
29f5567e0a9a
Added imap-zlib plugin for enabling COMPRESS=DEFLATE extension.
Timo Sirainen <tss@iki.fi>
parents:
10647
diff
changeset
|
2692 src/plugins/imap-zlib/Makefile |
1418
c36d18766a35
0.99.9.1 released. Added redhat spec file.
Timo Sirainen <tss@iki.fi>
parents:
1410
diff
changeset
|
2693 stamp.h |
4343
407e6c620d70
dovecot-config now contains module_dir
Timo Sirainen <tss@iki.fi>
parents:
4300
diff
changeset
|
2694 dovecot-config.in]) |
1096
2ea48622afbc
Building in separate directory didn't work
Timo Sirainen <tss@iki.fi>
parents:
1089
diff
changeset
|
2695 |
2796
fb7f862194b5
Upgrades to autoconf 2.5 and automake >1.4.
Timo Sirainen <tss@iki.fi>
parents:
2784
diff
changeset
|
2696 AC_OUTPUT |
1096
2ea48622afbc
Building in separate directory didn't work
Timo Sirainen <tss@iki.fi>
parents:
1089
diff
changeset
|
2697 |
8517
451e3cf38290
configure: Handle --with-*=* consistently and give better error messages.
Timo Sirainen <tss@iki.fi>
parents:
8489
diff
changeset
|
2698 if test "$want_sql" = "plugin"; then |
6194
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2699 sql_drivers="$sql_drivers (plugins)" |
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2700 fi |
0d86bb9cf286
Added --enable-sql-plugins to build SQL drivers as plugins. Based on patch
Timo Sirainen <tss@iki.fi>
parents:
6177
diff
changeset
|
2701 |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2702 not_passdb=`echo "$not_passdb"|sed 's/ / -/g'` |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2703 not_userdb=`echo "$not_userdb"|sed 's/ / -/g'` |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2704 not_sql_drivers=`echo "$not_sql_drivers"|sed 's/ / -/g'` |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2705 |
0 | 2706 echo |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2707 echo "Install prefix . : $prefix" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2708 echo "File offsets ... : ${offt_bits}bit" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2709 echo "I/O polling .... : $ioloop" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2710 echo "I/O notifys .... : $have_notify" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2711 echo "SSL ............ : $have_ssl" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2712 echo "GSSAPI ......... : $have_gssapi" |
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2713 echo "passdbs ........ :$passdb" |
9410
ab69375b8422
configure: If all passdb/userdb/sql drivers are compiled, don't print an empty line for them.
Timo Sirainen <tss@iki.fi>
parents:
9329
diff
changeset
|
2714 if test "$not_passdb" != ""; then |
ab69375b8422
configure: If all passdb/userdb/sql drivers are compiled, don't print an empty line for them.
Timo Sirainen <tss@iki.fi>
parents:
9329
diff
changeset
|
2715 echo " :$not_passdb" |
ab69375b8422
configure: If all passdb/userdb/sql drivers are compiled, don't print an empty line for them.
Timo Sirainen <tss@iki.fi>
parents:
9329
diff
changeset
|
2716 fi |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2717 echo "userdbs ........ :$userdb" |
9410
ab69375b8422
configure: If all passdb/userdb/sql drivers are compiled, don't print an empty line for them.
Timo Sirainen <tss@iki.fi>
parents:
9329
diff
changeset
|
2718 if test "$not_userdb" != ""; then |
ab69375b8422
configure: If all passdb/userdb/sql drivers are compiled, don't print an empty line for them.
Timo Sirainen <tss@iki.fi>
parents:
9329
diff
changeset
|
2719 echo " :$not_userdb" |
ab69375b8422
configure: If all passdb/userdb/sql drivers are compiled, don't print an empty line for them.
Timo Sirainen <tss@iki.fi>
parents:
9329
diff
changeset
|
2720 fi |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2721 echo "SQL drivers .... :$sql_drivers" |
9410
ab69375b8422
configure: If all passdb/userdb/sql drivers are compiled, don't print an empty line for them.
Timo Sirainen <tss@iki.fi>
parents:
9329
diff
changeset
|
2722 if test "$not_sql_drivers" != ""; then |
ab69375b8422
configure: If all passdb/userdb/sql drivers are compiled, don't print an empty line for them.
Timo Sirainen <tss@iki.fi>
parents:
9329
diff
changeset
|
2723 echo " :$not_sql_drivers" |
ab69375b8422
configure: If all passdb/userdb/sql drivers are compiled, don't print an empty line for them.
Timo Sirainen <tss@iki.fi>
parents:
9329
diff
changeset
|
2724 fi |
9016 | 2725 |
9246
df8b1ae676fe
configure: Show also list of disabled passdbs/userdbs/sql drivers.
Timo Sirainen <tss@iki.fi>
parents:
9245
diff
changeset
|
2726 echo |
9245
e661cd70e425
configure: Version number is nowadays 2.0, not 1.3.
Timo Sirainen <tss@iki.fi>
parents:
9235
diff
changeset
|
2727 echo "NOTE: This is the UNSTABLE development branch of Dovecot v2.0." |