* configure.in: Use AC_HELP_STRING for kdc-replay-cache option info
[krb5.git] / src / configure.in
1 AC_INIT
2 AC_CONFIG_SRCDIR([aclocal.m4])
3 dnl
4 dnl autoconf 2.49 defaults to a /dev/null cache file, which is what we
5 dnl do not want for performance reasons. 
6 if test "x$cache_file" = "x/dev/null"; then
7   cache_file=./config.cache
8   AC_CACHE_LOAD
9 fi
10 dnl
11 CONFIG_RULES
12 dnl
13 dnl Determine version from patchlevel.h
14 eval `sed 's/#define \([A-Z0-9_]*\)[ \t]*\(.*\)/\1=\2/' < $srcdir/patchlevel.h`
15 KRB5_VERSION="$KRB5_MAJOR_RELEASE.$KRB5_MINOR_RELEASE.$KRB5_PATCHLEVEL"
16 AC_SUBST(KRB5_VERSION)
17 dnl
18 AC_REQUIRE_CPP
19 dnl
20 dnl The following lines are so that configure --help gives some global 
21 dnl configuration options.
22 dnl
23 AC_ARG_ENABLE([kdc-replay-cache],
24 AC_HELP_STRING([--enable-kdc-replay-cache],[check for replayed/retransmitted KDC requests (recommended for replay attack detection when hardware preauthentication is in use)])
25 AC_HELP_STRING([--disable-kdc-replay-cache],[omit replay detection]))dnl
26 KRB5_LIB_AUX
27 AC_KRB5_TCL
28 AC_ARG_ENABLE([athena],
29 [  --enable-athena         build with MIT Project Athena configuration],,)
30 dnl
31 if test -z "$KRB4_LIB"; then
32 kadminv4=""
33 krb524=""
34 libkrb4=""
35 KRB4=""
36 else
37 kadminv4=kadmin.v4
38 krb524=krb524
39 libkrb4=lib/krb4
40 KRB4=krb4
41 fi
42 AC_SUBST(KRB4)
43 AC_SUBST(krb524)
44 dnl
45 dnl Begin autoconf tests for the Makefiles generated out of the top-level
46 dnl configure.in...
47 dnl
48 AC_CHECK_FUNCS(memmove)
49 KRB5_BUILD_LIBOBJS
50 KRB5_BUILD_LIBRARY
51 KRB5_BUILD_PROGRAM
52 dnl
53 HOST_TYPE=$krb5_cv_host
54 AC_SUBST(HOST_TYPE)
55 dnl
56 dnl
57 if test "$COM_ERR_VERSION" = k5 ; then
58   AC_CONFIG_SUBDIRS(util/et)
59 fi
60 if test "$SS_VERSION" = k5 ; then
61   AC_CONFIG_SUBDIRS(util/ss)
62 fi
63 AC_CONFIG_SUBDIRS(util/profile util/pty)
64 if test "$DB_VERSION" = k5 ; then
65   AC_CONFIG_SUBDIRS(util/db2)
66 fi
67 AC_CONFIG_SUBDIRS(include lib/crypto lib/krb5 lib/des425)
68 if test -n "$KRB4_LIB"; then
69   AC_CONFIG_SUBDIRS(lib/krb4)
70 fi
71 AC_CONFIG_SUBDIRS(lib/kdb lib/gssapi lib/rpc lib/kadm5)
72 if test -n "$KRB4_LIB"; then
73   AC_CONFIG_SUBDIRS(krb524)
74 fi
75 case $krb5_cv_host in
76 *-*-solaris2.9*)
77         if test "$krb5_cv_prog_gcc" = yes; then
78                 DL_COMPILE='$(CC) -fpic -G -nostdlib'
79                 DL_COMPILE_TAIL='-lc -ldl'
80         else
81                 DL_COMPILE='$(CC) -Kpic -G'
82                 DL_COMPILE_TAIL='-ldl'
83         fi
84         EXITSLEEP_TARG=exitsleep
85         ;;
86 esac
87 AC_SUBST(DL_COMPILE)
88 AC_SUBST(DL_COMPILE_TAIL)
89 AC_SUBST(EXITSLEEP_TARG)
90
91 AC_CONFIG_SUBDIRS(kdc kadmin slave clients appl tests)
92 AC_CONFIG_FILES(krb5-config, [chmod +x krb5-config])
93 V5_AC_OUTPUT_MAKEFILE(. util util/send-pr lib config-files gen-manpages)