build-sys: add bug reporting address and home page to configure
[openafs.git] / configure.ac
1 AC_PREREQ([2.60])
2 AC_INIT([OpenAFS],
3         m4_esyscmd([build-tools/git-version .]),
4         [openafs-bugs@openafs.org],,
5         [http://www.openafs.org/])
6 AC_CONFIG_AUX_DIR([build-tools])
7 AC_CONFIG_MACRO_DIR([src/cf])
8 AC_CONFIG_SRCDIR([src/config/stds.h])
9 AM_INIT_AUTOMAKE
10
11 AC_CONFIG_HEADER(src/config/afsconfig.h)
12 MACOS_VERSION=1.5.76
13 #LINUX_PKGREL=0.pre3
14 LINUX_PKGREL=1.1
15
16 dnl Debian wants the release candidate version in the main upstream version,
17 dnl and wants ~ before it.
18 DEB_PKGVER=m4_esyscmd([build-tools/git-version .])
19 if echo "$LINUX_PKGREL" | grep pre >/dev/null 2>/dev/null ; then
20     DEB_PKGVER="$DEB_PKGVER"`echo "$LINUX_PKGREL" | sed 's/0.pre/~rc/'`
21 fi
22
23 AC_SUBST(MACOS_VERSION)
24 AC_SUBST(DEB_PKGVER)
25
26 dnl If the user hasn't specified CFLAGS don't let configure pick -g -O2
27 AS_IF([test -z "$CFLAGS"], [CFLAGS=" "], [])
28
29 AC_USE_SYSTEM_EXTENSIONS
30
31 LT_INIT
32
33 AC_PROG_CC
34 AC_PROG_LIBTOOL
35
36 AC_PATH_PROGS([PATH_CPP], [cpp], [${CC-cc} -E], [$PATH:/lib:/usr/ccs/lib])
37 AC_SUBST([PATH_CPP])
38 OPENAFS_CONFIGURE_COMMON
39
40 dnl Probe for Kerberos.  We have a few platform-specific overrides due to
41 dnl weird Kerberos implementations and installation locations.
42 AS_CASE([$AFS_SYSNAME],
43     [*_obsd*],
44     [KRB5_CPPFLAGS="-I/usr/include/kerberosV"],
45
46     [ppc_darwin_70],
47     [KRB5_CPPFLAGS="-I/usr/include"
48      KRB5_LDFLAGS="-L/usr/lib -Wl,-search_paths_first"])
49 RRA_LIB_KRB5_OPTIONAL
50 AS_CASE([$AFS_SYSNAME],
51     [hp_ux*|*_hpux*],
52     [KRB5_LIBS="-l:libkrb5.sl -l:libcom_err.sl"])
53
54 dnl Check for the characteristics of whatever Kerberos we found, if we found
55 dnl one.
56 BUILD_KRB5=no
57 MAKE_KRB5="#"
58 AS_IF([test x"$KRB5_LIBS" != x],
59     [BUILD_KRB5=yes
60      MAKE_KRB5=
61      RRA_LIB_KRB5_SWITCH
62      AC_CHECK_FUNCS([add_error_table \
63         add_to_error_table \
64         encode_krb5_enc_tkt_part \
65         encode_krb5_ticket \
66         krb5_524_conv_principal \
67         krb5_allow_weak_crypto \
68         krb5_c_encrypt \
69         krb5_decode_ticket \
70         krb5_enctype_enable \
71         krb5_get_init_creds_opt_alloc \
72         krb5_get_prompt_types \
73         krb5_princ_size \
74         krb5_principal_get_comp_string])
75      AC_CHECK_FUNCS([krb5_524_convert_creds], ,
76          [AC_CHECK_FUNCS([krb524_convert_creds_kdc], ,
77              [AC_CHECK_LIB([krb524], [krb524_convert_creds_kdc],
78                  [LIBS="-lkrb524 $LIBS"
79                   KRB5_LIBS="-lkrb524 $KRB5_LIBS"
80                   AC_CHECK_LIB([krb524], [krb5_524_conv_principal],
81                   [AC_DEFINE([HAVE_KRB5_524_CONV_PRINCIPAL], 1,
82                      [Define to 1 if you have the `krb5_524_conv_principal' function.])])
83                   AC_DEFINE([HAVE_KRB524_CONVERT_CREDS_KDC], 1,
84                      [Define to 1 if you have the `krb524_convert_creds_kdc' function.])])])])
85      AC_CHECK_HEADERS([kerberosIV/krb.h])
86      AC_CHECK_HEADERS([kerberosV/heim_err.h])
87      AC_CHECK_MEMBERS([krb5_creds.keyblock, krb5_creds.keyblock.enctype, krb5_creds.session,
88                        krb5_prompt.type], , , [#include <krb5.h>])
89 dnl If we have krb5_creds.session, we are using heimdal
90 dnl If we're using heimdal, aklog needs libasn1 for encode_EncTicketPart and a
91 dnl few other functions. But just aklog; not any of the other stuff that uses
92 dnl krb5.
93      AS_IF([test x"$ac_cv_member_krb5_creds_session" = xyes],
94            [AC_CHECK_LIB([asn1], [encode_EncTicketPart],
95                         [AKLOG_KRB5_LIBS="-lasn1"])])
96      RRA_LIB_KRB5_RESTORE])
97 AC_SUBST([BUILD_KRB5])
98 AC_SUBST([MAKE_KRB5])
99 AC_SUBST([AKLOG_KRB5_LIBS])
100
101 dnl Probe for GSSAPI
102 RRA_LIB_GSSAPI
103
104 if test -d 'doc/man-pages' ; then
105     MAN_MAKEFILE="doc/man-pages/Makefile doc/man-pages/install-man"
106 else
107     MAN_MAKEFILE=
108 fi
109 if test -f 'doc/xml/AdminGuide/Makefile.in' ; then
110    ADMINGUIDE_MAKEFILE="doc/xml/AdminGuide/Makefile"
111 else
112    ADMINGUIDE_MAKEFILE=
113 fi
114 if test -f 'doc/xml/QuickStartUnix/Makefile.in' ; then
115    QSUNIX_MAKEFILE="doc/xml/QuickStartUnix/Makefile"
116 else
117    QSUNIX_MAKEFILE=
118 fi
119 if test -f 'doc/xml/UserGuide/Makefile.in' ; then
120    USERGUIDE_MAKEFILE="doc/xml/UserGuide/Makefile"
121 else
122    USERGUIDE_MAKEFILE=
123 fi
124 if test -f 'doc/xml/AdminRef/Makefile.in' ; then
125    ADMINREF_MAKEFILE="doc/xml/AdminRef/Makefile"
126 else
127    ADMINREF_MAKEFILE=
128 fi
129 if test -f 'doc/xml/mobi-fixup.xsl.in' ; then
130    MOBI_FIXUP_XSL="doc/xml/mobi-fixup.xsl"
131 else
132    MOBI_FIXUP_XSL=
133 fi
134
135 AC_OUTPUT(             \
136 Makefile               \
137 ${MAN_MAKEFILE} \
138 ${ADMINGUIDE_MAKEFILE} \
139 ${QSUNIX_MAKEFILE} \
140 ${USERGUIDE_MAKEFILE} \
141 ${ADMINREF_MAKEFILE} \
142 ${MOBI_FIXUP_XSL} \
143 src/afs/Makefile \
144 src/afsd/Makefile \
145 src/afsmonitor/Makefile \
146 src/afsweb/Makefile \
147 src/aklog/Makefile \
148 src/audit/Makefile \
149 src/auth/Makefile \
150 src/auth/test/Makefile \
151 src/bozo/Makefile \
152 src/bozo/test/Makefile \
153 src/bu_utils/Makefile \
154 src/bubasics/Makefile \
155 src/bucoord/Makefile \
156 src/budb/Makefile \
157 src/tbudb/Makefile \
158 src/butc/Makefile \
159 src/butm/Makefile \
160 src/cmd/Makefile \
161 src/cmd/test/Makefile \
162 src/comerr/Makefile \
163 src/comerr/test/Makefile \
164 src/config/Makefile \
165 src/config/Makefile.config \
166 src/config/Makefile.libtool \
167 src/config/Makefile.lwp \
168 src/config/Makefile.lwptool \
169 src/config/Makefile.pthread \
170 src/config/Makefile.shared \
171 src/config/Makefile.version-CML \
172 src/config/Makefile.version-NOCML \
173 src/config/shlib-build \
174 src/config/shlib-install \
175 src/crypto/hcrypto/Makefile \
176 src/crypto/rfc3961/Makefile \
177 src/dir/Makefile \
178 src/dir/test/Makefile \
179 src/dviced/Makefile \
180 src/dvolser/Makefile \
181 src/export/Makefile \
182 src/finale/Makefile \
183 src/fsint/Makefile \
184 src/fsprobe/Makefile \
185 src/gtx/Makefile \
186 src/JAVA/libjafs/Makefile \
187 src/kauth/Makefile \
188 src/kauth/test/Makefile \
189 src/kopenafs/Makefile \
190 src/libacl/Makefile \
191 src/libacl/test/Makefile \
192 src/libadmin/Makefile \
193 src/libadmin/adminutil/Makefile \
194 src/libadmin/bos/Makefile \
195 src/libadmin/cfg/Makefile \
196 src/libadmin/cfg/test/Makefile \
197 src/libadmin/client/Makefile \
198 src/libadmin/kas/Makefile \
199 src/libadmin/pts/Makefile \
200 src/libadmin/samples/Makefile \
201 src/libadmin/test/Makefile \
202 src/libadmin/vos/Makefile \
203 src/libafs/Makefile.common \
204 src/libafs/MakefileProto.${MKAFS_OSTYPE} \
205 ${DARWIN_PLIST} \
206 src/libafsauthent/Makefile \
207 src/libafsrpc/Makefile \
208 src/libuafs/Makefile.common \
209 src/libuafs/MakefileProto.${MKAFS_OSTYPE} \
210 src/log/Makefile \
211 src/log/test/Makefile \
212 src/lwp/Makefile \
213 src/lwp/test/Makefile \
214 src/opr/Makefile \
215 src/packaging/Debian/changelog \
216 src/packaging/MacOS/OpenAFS-debug.Description.plist \
217 src/packaging/MacOS/OpenAFS-debug.Info.plist \
218 src/packaging/MacOS/OpenAFS.Description.plist \
219 src/packaging/MacOS/OpenAFS.Info.plist \
220 src/packaging/MacOS/OpenAFS.info \
221 src/packaging/MacOS/buildpkg.sh \
222 src/pam/Makefile \
223 src/platform/Makefile \
224 src/platform/${MKAFS_OSTYPE}/Makefile \
225 src/platform/DARWIN/growlagent/Makefile \
226 src/procmgmt/Makefile \
227 src/procmgmt/test/Makefile \
228 src/ptserver/Makefile \
229 src/tptserver/Makefile \
230 src/roken/Makefile \
231 src/rx/Makefile \
232 src/rx/bulk.example/Makefile \
233 src/rx/bulktest/Makefile \
234 src/rx/multi.example/Makefile \
235 src/rx/simple.example/Makefile \
236 src/rx/test/Makefile \
237 src/rxdebug/Makefile \
238 src/rxgen/Makefile \
239 src/rxkad/Makefile \
240 src/rxkad/test/Makefile \
241 src/rxosd/Makefile \
242 src/rxstat/Makefile \
243 src/scout/Makefile \
244 src/sgistuff/Makefile \
245 src/sys/Makefile \
246 src/tbutc/Makefile \
247 src/tests/Makefile \
248 src/tests/run-tests \
249 src/tools/Makefile \
250 src/tools/dumpscan/Makefile \
251 src/tools/rxperf/Makefile \
252 src/tsalvaged/Makefile \
253 src/tsm41/Makefile \
254 src/tvolser/Makefile \
255 src/ubik/Makefile \
256 src/tubik/Makefile \
257 src/update/Makefile \
258 src/usd/Makefile \
259 src/usd/test/Makefile \
260 src/uss/Makefile \
261 src/util/Makefile \
262 src/util/test/Makefile \
263 src/libafscp/Makefile \
264 src/venus/Makefile \
265 src/venus/test/Makefile \
266 src/vfsck/Makefile \
267 src/viced/Makefile \
268 src/vlserver/Makefile \
269 src/tvlserver/Makefile \
270 src/vol/Makefile \
271 src/vol/test/Makefile \
272 src/volser/Makefile \
273 src/xstat/Makefile \
274 src/helper-splint.sh \
275 tests/Makefile \
276 tests/auth/Makefile \
277 tests/cmd/Makefile \
278 tests/common/Makefile \
279 tests/opr/Makefile \
280 tests/rpctestlib/Makefile \
281 tests/rx/Makefile \
282 tests/tap/Makefile \
283 tests/util/Makefile \
284 tests/volser/Makefile,
285
286 [chmod a+x src/config/shlib-build
287  chmod a+x src/config/shlib-install])
288
289 # print a final summary
290 SUMMARY