]> granicus.if.org Git - linux-pam/blob - configure
Relevant BUGIDs: none
[linux-pam] / configure
1 #! /bin/sh
2
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.13 
5 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6 #
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
9
10 # Defaults:
11 ac_help=
12 ac_default_prefix=/usr/local
13 # Any additions from configure.in:
14 ac_default_prefix=
15 ac_help="$ac_help
16   --enable-debug           specify you are building with debugging on"
17 ac_help="$ac_help
18   --enable-memory-debug    specify you want every malloc etc. call tracked"
19 ac_help="$ac_help
20   --enable-libdebug        specify you are building debugging libraries"
21 ac_help="$ac_help
22   --enable-fakeroot=<path to packaging directory>"
23 ac_help="$ac_help
24   --enable-securedir=<path to location of PAMs> [default \$libdir/security]"
25 ac_help="$ac_help
26   --enable-sconfigdir=<path to module conf files> [default \$sysconfdir/security]"
27 ac_help="$ac_help
28   --enable-suplementedir=<path to module helper binaries> [default \$sbindir]"
29 ac_help="$ac_help
30   --enable-includedir=<path to include location> - where to put <security>"
31 ac_help="$ac_help
32   --enable-docdir=<path to store documentation in - /usr/share/doc/pam>"
33 ac_help="$ac_help
34   --enable-mandir=<path to store manuals in - /usr/share/man>"
35 ac_help="$ac_help
36   --enable-pamlocking      configure libpam to observe a global authentication lock"
37 ac_help="$ac_help
38   --enable-uglyhack        configure libpam to try to honor old pam_strerror syntax"
39 ac_help="$ac_help
40   --enable-read-both-confs  read both /etc/pam.d and /etc/pam.conf files"
41 ac_help="$ac_help
42   --enable-static-libpam   build a libpam.a library"
43 ac_help="$ac_help
44   --disable-dynamic-libpam do not build a shared libpam library"
45 ac_help="$ac_help
46   --enable-static-modules  do not make the modules dynamically loadable"
47 ac_help="$ac_help
48   --disable-lckpwdf do not use the lckpwdf function"
49 ac_help="$ac_help
50   --with-mailspool         path to mail spool directory
51                            [default _PATH_MAILDIR if defined in paths.h, otherwise /var/spool/mail]"
52
53 # Initialize some variables set by options.
54 # The variables have the same names as the options, with
55 # dashes changed to underlines.
56 build=NONE
57 cache_file=./config.cache
58 exec_prefix=NONE
59 host=NONE
60 no_create=
61 nonopt=NONE
62 no_recursion=
63 prefix=NONE
64 program_prefix=NONE
65 program_suffix=NONE
66 program_transform_name=s,x,x,
67 silent=
68 site=
69 srcdir=
70 target=NONE
71 verbose=
72 x_includes=NONE
73 x_libraries=NONE
74 bindir='${exec_prefix}/bin'
75 sbindir='${exec_prefix}/sbin'
76 libexecdir='${exec_prefix}/libexec'
77 datadir='${prefix}/share'
78 sysconfdir='${prefix}/etc'
79 sharedstatedir='${prefix}/com'
80 localstatedir='${prefix}/var'
81 libdir='${exec_prefix}/lib'
82 includedir='${prefix}/include'
83 oldincludedir='/usr/include'
84 infodir='${prefix}/info'
85 mandir='${prefix}/man'
86
87 # Initialize some other variables.
88 subdirs=
89 MFLAGS= MAKEFLAGS=
90 SHELL=${CONFIG_SHELL-/bin/sh}
91 # Maximum number of lines to put in a shell here document.
92 ac_max_here_lines=12
93
94 ac_prev=
95 for ac_option
96 do
97
98   # If the previous option needs an argument, assign it.
99   if test -n "$ac_prev"; then
100     eval "$ac_prev=\$ac_option"
101     ac_prev=
102     continue
103   fi
104
105   case "$ac_option" in
106   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
107   *) ac_optarg= ;;
108   esac
109
110   # Accept the important Cygnus configure options, so we can diagnose typos.
111
112   case "$ac_option" in
113
114   -bindir | --bindir | --bindi | --bind | --bin | --bi)
115     ac_prev=bindir ;;
116   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
117     bindir="$ac_optarg" ;;
118
119   -build | --build | --buil | --bui | --bu)
120     ac_prev=build ;;
121   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
122     build="$ac_optarg" ;;
123
124   -cache-file | --cache-file | --cache-fil | --cache-fi \
125   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
126     ac_prev=cache_file ;;
127   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
128   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
129     cache_file="$ac_optarg" ;;
130
131   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
132     ac_prev=datadir ;;
133   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
134   | --da=*)
135     datadir="$ac_optarg" ;;
136
137   -disable-* | --disable-*)
138     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
139     # Reject names that are not valid shell variable names.
140     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
141       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
142     fi
143     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
144     eval "enable_${ac_feature}=no" ;;
145
146   -enable-* | --enable-*)
147     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
148     # Reject names that are not valid shell variable names.
149     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
150       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
151     fi
152     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
153     case "$ac_option" in
154       *=*) ;;
155       *) ac_optarg=yes ;;
156     esac
157     eval "enable_${ac_feature}='$ac_optarg'" ;;
158
159   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
160   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
161   | --exec | --exe | --ex)
162     ac_prev=exec_prefix ;;
163   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
164   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
165   | --exec=* | --exe=* | --ex=*)
166     exec_prefix="$ac_optarg" ;;
167
168   -gas | --gas | --ga | --g)
169     # Obsolete; use --with-gas.
170     with_gas=yes ;;
171
172   -help | --help | --hel | --he)
173     # Omit some internal or obsolete options to make the list less imposing.
174     # This message is too long to be a string in the A/UX 3.1 sh.
175     cat << EOF
176 Usage: configure [options] [host]
177 Options: [defaults in brackets after descriptions]
178 Configuration:
179   --cache-file=FILE       cache test results in FILE
180   --help                  print this message
181   --no-create             do not create output files
182   --quiet, --silent       do not print \`checking...' messages
183   --version               print the version of autoconf that created configure
184 Directory and file names:
185   --prefix=PREFIX         install architecture-independent files in PREFIX
186                           [$ac_default_prefix]
187   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
188                           [same as prefix]
189   --bindir=DIR            user executables in DIR [EPREFIX/bin]
190   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
191   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
192   --datadir=DIR           read-only architecture-independent data in DIR
193                           [PREFIX/share]
194   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
195   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
196                           [PREFIX/com]
197   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
198   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
199   --includedir=DIR        C header files in DIR [PREFIX/include]
200   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
201   --infodir=DIR           info documentation in DIR [PREFIX/info]
202   --mandir=DIR            man documentation in DIR [PREFIX/man]
203   --srcdir=DIR            find the sources in DIR [configure dir or ..]
204   --program-prefix=PREFIX prepend PREFIX to installed program names
205   --program-suffix=SUFFIX append SUFFIX to installed program names
206   --program-transform-name=PROGRAM
207                           run sed PROGRAM on installed program names
208 EOF
209     cat << EOF
210 Host type:
211   --build=BUILD           configure for building on BUILD [BUILD=HOST]
212   --host=HOST             configure for HOST [guessed]
213   --target=TARGET         configure for TARGET [TARGET=HOST]
214 Features and packages:
215   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
216   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
217   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
218   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
219   --x-includes=DIR        X include files are in DIR
220   --x-libraries=DIR       X library files are in DIR
221 EOF
222     if test -n "$ac_help"; then
223       echo "--enable and --with options recognized:$ac_help"
224     fi
225     exit 0 ;;
226
227   -host | --host | --hos | --ho)
228     ac_prev=host ;;
229   -host=* | --host=* | --hos=* | --ho=*)
230     host="$ac_optarg" ;;
231
232   -includedir | --includedir | --includedi | --included | --include \
233   | --includ | --inclu | --incl | --inc)
234     ac_prev=includedir ;;
235   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
236   | --includ=* | --inclu=* | --incl=* | --inc=*)
237     includedir="$ac_optarg" ;;
238
239   -infodir | --infodir | --infodi | --infod | --info | --inf)
240     ac_prev=infodir ;;
241   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
242     infodir="$ac_optarg" ;;
243
244   -libdir | --libdir | --libdi | --libd)
245     ac_prev=libdir ;;
246   -libdir=* | --libdir=* | --libdi=* | --libd=*)
247     libdir="$ac_optarg" ;;
248
249   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
250   | --libexe | --libex | --libe)
251     ac_prev=libexecdir ;;
252   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
253   | --libexe=* | --libex=* | --libe=*)
254     libexecdir="$ac_optarg" ;;
255
256   -localstatedir | --localstatedir | --localstatedi | --localstated \
257   | --localstate | --localstat | --localsta | --localst \
258   | --locals | --local | --loca | --loc | --lo)
259     ac_prev=localstatedir ;;
260   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
261   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
262   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
263     localstatedir="$ac_optarg" ;;
264
265   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
266     ac_prev=mandir ;;
267   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
268     mandir="$ac_optarg" ;;
269
270   -nfp | --nfp | --nf)
271     # Obsolete; use --without-fp.
272     with_fp=no ;;
273
274   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
275   | --no-cr | --no-c)
276     no_create=yes ;;
277
278   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
279   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
280     no_recursion=yes ;;
281
282   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
283   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
284   | --oldin | --oldi | --old | --ol | --o)
285     ac_prev=oldincludedir ;;
286   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
287   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
288   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
289     oldincludedir="$ac_optarg" ;;
290
291   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
292     ac_prev=prefix ;;
293   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
294     prefix="$ac_optarg" ;;
295
296   -program-prefix | --program-prefix | --program-prefi | --program-pref \
297   | --program-pre | --program-pr | --program-p)
298     ac_prev=program_prefix ;;
299   -program-prefix=* | --program-prefix=* | --program-prefi=* \
300   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
301     program_prefix="$ac_optarg" ;;
302
303   -program-suffix | --program-suffix | --program-suffi | --program-suff \
304   | --program-suf | --program-su | --program-s)
305     ac_prev=program_suffix ;;
306   -program-suffix=* | --program-suffix=* | --program-suffi=* \
307   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
308     program_suffix="$ac_optarg" ;;
309
310   -program-transform-name | --program-transform-name \
311   | --program-transform-nam | --program-transform-na \
312   | --program-transform-n | --program-transform- \
313   | --program-transform | --program-transfor \
314   | --program-transfo | --program-transf \
315   | --program-trans | --program-tran \
316   | --progr-tra | --program-tr | --program-t)
317     ac_prev=program_transform_name ;;
318   -program-transform-name=* | --program-transform-name=* \
319   | --program-transform-nam=* | --program-transform-na=* \
320   | --program-transform-n=* | --program-transform-=* \
321   | --program-transform=* | --program-transfor=* \
322   | --program-transfo=* | --program-transf=* \
323   | --program-trans=* | --program-tran=* \
324   | --progr-tra=* | --program-tr=* | --program-t=*)
325     program_transform_name="$ac_optarg" ;;
326
327   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
328   | -silent | --silent | --silen | --sile | --sil)
329     silent=yes ;;
330
331   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
332     ac_prev=sbindir ;;
333   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
334   | --sbi=* | --sb=*)
335     sbindir="$ac_optarg" ;;
336
337   -sharedstatedir | --sharedstatedir | --sharedstatedi \
338   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
339   | --sharedst | --shareds | --shared | --share | --shar \
340   | --sha | --sh)
341     ac_prev=sharedstatedir ;;
342   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
343   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
344   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
345   | --sha=* | --sh=*)
346     sharedstatedir="$ac_optarg" ;;
347
348   -site | --site | --sit)
349     ac_prev=site ;;
350   -site=* | --site=* | --sit=*)
351     site="$ac_optarg" ;;
352
353   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
354     ac_prev=srcdir ;;
355   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
356     srcdir="$ac_optarg" ;;
357
358   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
359   | --syscon | --sysco | --sysc | --sys | --sy)
360     ac_prev=sysconfdir ;;
361   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
362   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
363     sysconfdir="$ac_optarg" ;;
364
365   -target | --target | --targe | --targ | --tar | --ta | --t)
366     ac_prev=target ;;
367   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
368     target="$ac_optarg" ;;
369
370   -v | -verbose | --verbose | --verbos | --verbo | --verb)
371     verbose=yes ;;
372
373   -version | --version | --versio | --versi | --vers)
374     echo "configure generated by autoconf version 2.13"
375     exit 0 ;;
376
377   -with-* | --with-*)
378     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
379     # Reject names that are not valid shell variable names.
380     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
381       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
382     fi
383     ac_package=`echo $ac_package| sed 's/-/_/g'`
384     case "$ac_option" in
385       *=*) ;;
386       *) ac_optarg=yes ;;
387     esac
388     eval "with_${ac_package}='$ac_optarg'" ;;
389
390   -without-* | --without-*)
391     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
392     # Reject names that are not valid shell variable names.
393     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
394       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
395     fi
396     ac_package=`echo $ac_package| sed 's/-/_/g'`
397     eval "with_${ac_package}=no" ;;
398
399   --x)
400     # Obsolete; use --with-x.
401     with_x=yes ;;
402
403   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
404   | --x-incl | --x-inc | --x-in | --x-i)
405     ac_prev=x_includes ;;
406   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
407   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
408     x_includes="$ac_optarg" ;;
409
410   -x-libraries | --x-libraries | --x-librarie | --x-librari \
411   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
412     ac_prev=x_libraries ;;
413   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
414   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
415     x_libraries="$ac_optarg" ;;
416
417   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
418     ;;
419
420   *)
421     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
422       echo "configure: warning: $ac_option: invalid host type" 1>&2
423     fi
424     if test "x$nonopt" != xNONE; then
425       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
426     fi
427     nonopt="$ac_option"
428     ;;
429
430   esac
431 done
432
433 if test -n "$ac_prev"; then
434   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
435 fi
436
437 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
438
439 # File descriptor usage:
440 # 0 standard input
441 # 1 file creation
442 # 2 errors and warnings
443 # 3 some systems may open it to /dev/tty
444 # 4 used on the Kubota Titan
445 # 6 checking for... messages and results
446 # 5 compiler messages saved in config.log
447 if test "$silent" = yes; then
448   exec 6>/dev/null
449 else
450   exec 6>&1
451 fi
452 exec 5>./config.log
453
454 echo "\
455 This file contains any messages produced by compilers while
456 running configure, to aid debugging if configure makes a mistake.
457 " 1>&5
458
459 # Strip out --no-create and --no-recursion so they do not pile up.
460 # Also quote any args containing shell metacharacters.
461 ac_configure_args=
462 for ac_arg
463 do
464   case "$ac_arg" in
465   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
466   | --no-cr | --no-c) ;;
467   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
468   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
469   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
470   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
471   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
472   esac
473 done
474
475 # NLS nuisances.
476 # Only set these to C if already set.  These must not be set unconditionally
477 # because not all systems understand e.g. LANG=C (notably SCO).
478 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
479 # Non-C LC_CTYPE values break the ctype check.
480 if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
481 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
482 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
483 if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
484
485 # confdefs.h avoids OS command line length limits that DEFS can exceed.
486 rm -rf conftest* confdefs.h
487 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
488 echo > confdefs.h
489
490 # A filename unique to this package, relative to the directory that
491 # configure is in, which we can look for to find out if srcdir is correct.
492 ac_unique_file=conf/pam_conv1/pam_conv.y
493
494 # Find the source files, if location was not specified.
495 if test -z "$srcdir"; then
496   ac_srcdir_defaulted=yes
497   # Try the directory containing this script, then its parent.
498   ac_prog=$0
499   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
500   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
501   srcdir=$ac_confdir
502   if test ! -r $srcdir/$ac_unique_file; then
503     srcdir=..
504   fi
505 else
506   ac_srcdir_defaulted=no
507 fi
508 if test ! -r $srcdir/$ac_unique_file; then
509   if test "$ac_srcdir_defaulted" = yes; then
510     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
511   else
512     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
513   fi
514 fi
515 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
516
517 # Prefer explicitly selected file to automatically selected ones.
518 if test -z "$CONFIG_SITE"; then
519   if test "x$prefix" != xNONE; then
520     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
521   else
522     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
523   fi
524 fi
525 for ac_site_file in $CONFIG_SITE; do
526   if test -r "$ac_site_file"; then
527     echo "loading site script $ac_site_file"
528     . "$ac_site_file"
529   fi
530 done
531
532 if test -r "$cache_file"; then
533   echo "loading cache $cache_file"
534   . $cache_file
535 else
536   echo "creating cache $cache_file"
537   > $cache_file
538 fi
539
540 ac_ext=c
541 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
542 ac_cpp='$CPP $CPPFLAGS'
543 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
544 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
545 cross_compiling=$ac_cv_prog_cc_cross
546
547 ac_exeext=
548 ac_objext=o
549 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
550   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
551   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
552     ac_n= ac_c='
553 ' ac_t='        '
554   else
555     ac_n=-n ac_c= ac_t=
556   fi
557 else
558   ac_n= ac_c='\c' ac_t=
559 fi
560
561
562
563
564
565
566 LIBPAM_VERSION_MAJOR=0
567 LIBPAM_VERSION_MINOR=77
568
569
570
571 cat >> confdefs.h <<\EOF
572 #define LIBPAM_VERSION_MAJOR 1
573 EOF
574
575 cat >> confdefs.h <<\EOF
576 #define LIBPAM_VERSION_MINOR 1
577 EOF
578
579
580
581
582
583 LOCALSRCDIR=`/bin/pwd`         ; 
584 LOCALOBJDIR=`/bin/pwd`         ; 
585 OS=`uname|sed -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
586
587
588
589 CONF_CFLAGS=                    ; 
590 MKDIR="mkdir -p"                ; 
591
592 SHLIBMODE=755                   ; 
593
594 USESONAME=yes                   ; 
595 SOSWITCH=-soname                ; 
596 NEEDSONAME=no                   ; 
597 LDCONFIG=/sbin/ldconfig         ; 
598
599 if test "$OS" = "aix"; then
600   INSTALL=/usr/ucb/install -c
601 else
602   INSTALL=/usr/bin/install
603 fi
604
605
606 # Extract the first word of "gcc", so it can be a program name with args.
607 set dummy gcc; ac_word=$2
608 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
609 echo "configure:610: checking for $ac_word" >&5
610 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
611   echo $ac_n "(cached) $ac_c" 1>&6
612 else
613   if test -n "$CC"; then
614   ac_cv_prog_CC="$CC" # Let the user override the test.
615 else
616   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
617   ac_dummy="$PATH"
618   for ac_dir in $ac_dummy; do
619     test -z "$ac_dir" && ac_dir=.
620     if test -f $ac_dir/$ac_word; then
621       ac_cv_prog_CC="gcc"
622       break
623     fi
624   done
625   IFS="$ac_save_ifs"
626 fi
627 fi
628 CC="$ac_cv_prog_CC"
629 if test -n "$CC"; then
630   echo "$ac_t""$CC" 1>&6
631 else
632   echo "$ac_t""no" 1>&6
633 fi
634
635 if test -z "$CC"; then
636   # Extract the first word of "cc", so it can be a program name with args.
637 set dummy cc; ac_word=$2
638 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
639 echo "configure:640: checking for $ac_word" >&5
640 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
641   echo $ac_n "(cached) $ac_c" 1>&6
642 else
643   if test -n "$CC"; then
644   ac_cv_prog_CC="$CC" # Let the user override the test.
645 else
646   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
647   ac_prog_rejected=no
648   ac_dummy="$PATH"
649   for ac_dir in $ac_dummy; do
650     test -z "$ac_dir" && ac_dir=.
651     if test -f $ac_dir/$ac_word; then
652       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
653         ac_prog_rejected=yes
654         continue
655       fi
656       ac_cv_prog_CC="cc"
657       break
658     fi
659   done
660   IFS="$ac_save_ifs"
661 if test $ac_prog_rejected = yes; then
662   # We found a bogon in the path, so make sure we never use it.
663   set dummy $ac_cv_prog_CC
664   shift
665   if test $# -gt 0; then
666     # We chose a different compiler from the bogus one.
667     # However, it has the same basename, so the bogon will be chosen
668     # first if we set CC to just the basename; use the full file name.
669     shift
670     set dummy "$ac_dir/$ac_word" "$@"
671     shift
672     ac_cv_prog_CC="$@"
673   fi
674 fi
675 fi
676 fi
677 CC="$ac_cv_prog_CC"
678 if test -n "$CC"; then
679   echo "$ac_t""$CC" 1>&6
680 else
681   echo "$ac_t""no" 1>&6
682 fi
683
684   if test -z "$CC"; then
685     case "`uname -s`" in
686     *win32* | *WIN32*)
687       # Extract the first word of "cl", so it can be a program name with args.
688 set dummy cl; ac_word=$2
689 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
690 echo "configure:691: checking for $ac_word" >&5
691 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
692   echo $ac_n "(cached) $ac_c" 1>&6
693 else
694   if test -n "$CC"; then
695   ac_cv_prog_CC="$CC" # Let the user override the test.
696 else
697   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
698   ac_dummy="$PATH"
699   for ac_dir in $ac_dummy; do
700     test -z "$ac_dir" && ac_dir=.
701     if test -f $ac_dir/$ac_word; then
702       ac_cv_prog_CC="cl"
703       break
704     fi
705   done
706   IFS="$ac_save_ifs"
707 fi
708 fi
709 CC="$ac_cv_prog_CC"
710 if test -n "$CC"; then
711   echo "$ac_t""$CC" 1>&6
712 else
713   echo "$ac_t""no" 1>&6
714 fi
715  ;;
716     esac
717   fi
718   test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
719 fi
720
721 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
722 echo "configure:723: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
723
724 ac_ext=c
725 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
726 ac_cpp='$CPP $CPPFLAGS'
727 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
728 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
729 cross_compiling=$ac_cv_prog_cc_cross
730
731 cat > conftest.$ac_ext << EOF
732
733 #line 734 "configure"
734 #include "confdefs.h"
735
736 main(){return(0);}
737 EOF
738 if { (eval echo configure:739: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
739   ac_cv_prog_cc_works=yes
740   # If we can't run a trivial program, we are probably using a cross compiler.
741   if (./conftest; exit) 2>/dev/null; then
742     ac_cv_prog_cc_cross=no
743   else
744     ac_cv_prog_cc_cross=yes
745   fi
746 else
747   echo "configure: failed program was:" >&5
748   cat conftest.$ac_ext >&5
749   ac_cv_prog_cc_works=no
750 fi
751 rm -fr conftest*
752 ac_ext=c
753 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
754 ac_cpp='$CPP $CPPFLAGS'
755 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
756 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
757 cross_compiling=$ac_cv_prog_cc_cross
758
759 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
760 if test $ac_cv_prog_cc_works = no; then
761   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
762 fi
763 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
764 echo "configure:765: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
765 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
766 cross_compiling=$ac_cv_prog_cc_cross
767
768 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
769 echo "configure:770: checking whether we are using GNU C" >&5
770 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
771   echo $ac_n "(cached) $ac_c" 1>&6
772 else
773   cat > conftest.c <<EOF
774 #ifdef __GNUC__
775   yes;
776 #endif
777 EOF
778 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:779: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
779   ac_cv_prog_gcc=yes
780 else
781   ac_cv_prog_gcc=no
782 fi
783 fi
784
785 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
786
787 if test $ac_cv_prog_gcc = yes; then
788   GCC=yes
789 else
790   GCC=
791 fi
792
793 ac_test_CFLAGS="${CFLAGS+set}"
794 ac_save_CFLAGS="$CFLAGS"
795 CFLAGS=
796 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
797 echo "configure:798: checking whether ${CC-cc} accepts -g" >&5
798 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
799   echo $ac_n "(cached) $ac_c" 1>&6
800 else
801   echo 'void f(){}' > conftest.c
802 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
803   ac_cv_prog_cc_g=yes
804 else
805   ac_cv_prog_cc_g=no
806 fi
807 rm -f conftest*
808
809 fi
810
811 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
812 if test "$ac_test_CFLAGS" = set; then
813   CFLAGS="$ac_save_CFLAGS"
814 elif test $ac_cv_prog_cc_g = yes; then
815   if test "$GCC" = yes; then
816     CFLAGS="-g -O2"
817   else
818     CFLAGS="-g"
819   fi
820 else
821   if test "$GCC" = yes; then
822     CFLAGS="-O2"
823   else
824     CFLAGS=
825   fi
826 fi
827
828 for ac_prog in 'bison -y' byacc
829 do
830 # Extract the first word of "$ac_prog", so it can be a program name with args.
831 set dummy $ac_prog; ac_word=$2
832 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
833 echo "configure:834: checking for $ac_word" >&5
834 if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
835   echo $ac_n "(cached) $ac_c" 1>&6
836 else
837   if test -n "$YACC"; then
838   ac_cv_prog_YACC="$YACC" # Let the user override the test.
839 else
840   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
841   ac_dummy="$PATH"
842   for ac_dir in $ac_dummy; do
843     test -z "$ac_dir" && ac_dir=.
844     if test -f $ac_dir/$ac_word; then
845       ac_cv_prog_YACC="$ac_prog"
846       break
847     fi
848   done
849   IFS="$ac_save_ifs"
850 fi
851 fi
852 YACC="$ac_cv_prog_YACC"
853 if test -n "$YACC"; then
854   echo "$ac_t""$YACC" 1>&6
855 else
856   echo "$ac_t""no" 1>&6
857 fi
858
859 test -n "$YACC" && break
860 done
861 test -n "$YACC" || YACC="yacc"
862
863 # Extract the first word of "flex", so it can be a program name with args.
864 set dummy flex; ac_word=$2
865 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
866 echo "configure:867: checking for $ac_word" >&5
867 if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
868   echo $ac_n "(cached) $ac_c" 1>&6
869 else
870   if test -n "$LEX"; then
871   ac_cv_prog_LEX="$LEX" # Let the user override the test.
872 else
873   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
874   ac_dummy="$PATH"
875   for ac_dir in $ac_dummy; do
876     test -z "$ac_dir" && ac_dir=.
877     if test -f $ac_dir/$ac_word; then
878       ac_cv_prog_LEX="flex"
879       break
880     fi
881   done
882   IFS="$ac_save_ifs"
883   test -z "$ac_cv_prog_LEX" && ac_cv_prog_LEX="lex"
884 fi
885 fi
886 LEX="$ac_cv_prog_LEX"
887 if test -n "$LEX"; then
888   echo "$ac_t""$LEX" 1>&6
889 else
890   echo "$ac_t""no" 1>&6
891 fi
892
893 if test -z "$LEXLIB"
894 then
895   case "$LEX" in
896   flex*) ac_lib=fl ;;
897   *) ac_lib=l ;;
898   esac
899   echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
900 echo "configure:901: checking for yywrap in -l$ac_lib" >&5
901 ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
902 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
903   echo $ac_n "(cached) $ac_c" 1>&6
904 else
905   ac_save_LIBS="$LIBS"
906 LIBS="-l$ac_lib  $LIBS"
907 cat > conftest.$ac_ext <<EOF
908 #line 909 "configure"
909 #include "confdefs.h"
910 /* Override any gcc2 internal prototype to avoid an error.  */
911 /* We use char because int might match the return type of a gcc2
912     builtin and then its argument prototype would still apply.  */
913 char yywrap();
914
915 int main() {
916 yywrap()
917 ; return 0; }
918 EOF
919 if { (eval echo configure:920: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
920   rm -rf conftest*
921   eval "ac_cv_lib_$ac_lib_var=yes"
922 else
923   echo "configure: failed program was:" >&5
924   cat conftest.$ac_ext >&5
925   rm -rf conftest*
926   eval "ac_cv_lib_$ac_lib_var=no"
927 fi
928 rm -f conftest*
929 LIBS="$ac_save_LIBS"
930
931 fi
932 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
933   echo "$ac_t""yes" 1>&6
934   LEXLIB="-l$ac_lib"
935 else
936   echo "$ac_t""no" 1>&6
937 fi
938
939 fi
940
941 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
942 echo "configure:943: checking whether ln -s works" >&5
943 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
944   echo $ac_n "(cached) $ac_c" 1>&6
945 else
946   rm -f conftestdata
947 if ln -s X conftestdata 2>/dev/null
948 then
949   rm -f conftestdata
950   ac_cv_prog_LN_S="ln -s"
951 else
952   ac_cv_prog_LN_S=ln
953 fi
954 fi
955 LN_S="$ac_cv_prog_LN_S"
956 if test "$ac_cv_prog_LN_S" = "ln -s"; then
957   echo "$ac_t""yes" 1>&6
958 else
959   echo "$ac_t""no" 1>&6
960 fi
961
962 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
963 echo "configure:964: checking whether ${MAKE-make} sets \${MAKE}" >&5
964 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
965 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
966   echo $ac_n "(cached) $ac_c" 1>&6
967 else
968   cat > conftestmake <<\EOF
969 all:
970         @echo 'ac_maketemp="${MAKE}"'
971 EOF
972 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
973 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
974 if test -n "$ac_maketemp"; then
975   eval ac_cv_prog_make_${ac_make}_set=yes
976 else
977   eval ac_cv_prog_make_${ac_make}_set=no
978 fi
979 rm -f conftestmake
980 fi
981 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
982   echo "$ac_t""yes" 1>&6
983   SET_MAKE=
984 else
985   echo "$ac_t""no" 1>&6
986   SET_MAKE="MAKE=${MAKE-make}"
987 fi
988
989
990
991 # Check whether --enable-debug or --disable-debug was given.
992 if test "${enable_debug+set}" = set; then
993   enableval="$enable_debug"
994   WITH_DEBUG=yes ; cat >> confdefs.h <<\EOF
995 #define DEBUG 1
996 EOF
997  
998 else
999   WITH_DEBUG=no
1000 fi
1001
1002
1003
1004 # Check whether --enable-memory-debug or --disable-memory-debug was given.
1005 if test "${enable_memory_debug+set}" = set; then
1006   enableval="$enable_memory_debug"
1007   WITH_MEMORY_DEBUG=yes ; cat >> confdefs.h <<\EOF
1008 #define MEMORY_DEBUG 1
1009 EOF
1010  
1011 else
1012   WITH_MEMORY_DEBUG=no
1013 fi
1014
1015
1016
1017 # Check whether --enable-libdebug or --disable-libdebug was given.
1018 if test "${enable_libdebug+set}" = set; then
1019   enableval="$enable_libdebug"
1020   WITH_LIBDEBUG=yes ; cat >> confdefs.h <<\EOF
1021 #define WITH_LIBDEBUG 1
1022 EOF
1023  
1024 else
1025   WITH_LIBDEBUG=no
1026 fi
1027
1028
1029
1030 # Check whether --enable-fakeroot or --disable-fakeroot was given.
1031 if test "${enable_fakeroot+set}" = set; then
1032   enableval="$enable_fakeroot"
1033   FAKEROOT=$enableval
1034 fi
1035
1036
1037
1038 # Check whether --enable-securedir or --disable-securedir was given.
1039 if test "${enable_securedir+set}" = set; then
1040   enableval="$enable_securedir"
1041   SECUREDIR=$enableval
1042 else
1043   SECUREDIR=$libdir/security
1044 fi
1045
1046
1047
1048 # Check whether --enable-sconfigdir or --disable-sconfigdir was given.
1049 if test "${enable_sconfigdir+set}" = set; then
1050   enableval="$enable_sconfigdir"
1051   SCONFIGDIR=$enableval
1052 else
1053   SCONFIGDIR=$sysconfdir/security
1054 fi
1055
1056
1057
1058 # Check whether --enable-suplementedir or --disable-suplementedir was given.
1059 if test "${enable_suplementedir+set}" = set; then
1060   enableval="$enable_suplementedir"
1061   SUPLEMENTED=$enableval
1062 else
1063   SUPLEMENTED=$sbindir
1064 fi
1065
1066
1067
1068 # Check whether --enable-includedir or --disable-includedir was given.
1069 if test "${enable_includedir+set}" = set; then
1070   enableval="$enable_includedir"
1071   INCLUDEDIR=$enableval
1072 else
1073   INCLUDEDIR=/usr/include
1074 fi
1075
1076
1077
1078 # Check whether --enable-docdir or --disable-docdir was given.
1079 if test "${enable_docdir+set}" = set; then
1080   enableval="$enable_docdir"
1081   DOCDIR=$enableval
1082 else
1083   DOCDIR=/usr/share/doc/pam
1084 fi
1085
1086
1087
1088 # Check whether --enable-mandir or --disable-mandir was given.
1089 if test "${enable_mandir+set}" = set; then
1090   enableval="$enable_mandir"
1091   MANDIR=$enableval
1092 else
1093   MANDIR=/usr/share/man
1094 fi
1095
1096
1097
1098 # Check whether --enable-pamlocking or --disable-pamlocking was given.
1099 if test "${enable_pamlocking+set}" = set; then
1100   enableval="$enable_pamlocking"
1101   WITH_PAMLOCKING=yes ; cat >> confdefs.h <<\EOF
1102 #define PAM_LOCKING 1
1103 EOF
1104  
1105 else
1106   WITH_PAMLOCKING=no
1107 fi
1108
1109
1110
1111 # Check whether --enable-uglyhack or --disable-uglyhack was given.
1112 if test "${enable_uglyhack+set}" = set; then
1113   enableval="$enable_uglyhack"
1114   cat >> confdefs.h <<\EOF
1115 #define UGLY_HACK_FOR_PRIOR_BEHAVIOR_SUPPORT 1
1116 EOF
1117
1118 fi
1119
1120
1121 # Check whether --enable-read-both-confs or --disable-read-both-confs was given.
1122 if test "${enable_read_both_confs+set}" = set; then
1123   enableval="$enable_read_both_confs"
1124   cat >> confdefs.h <<\EOF
1125 #define PAM_READ_BOTH_CONFS 1
1126 EOF
1127
1128 fi
1129
1130
1131
1132 # Check whether --enable-static-libpam or --disable-static-libpam was given.
1133 if test "${enable_static_libpam+set}" = set; then
1134   enableval="$enable_static_libpam"
1135   STATIC_LIBPAM=yes 
1136 else
1137   STATIC_LIBPAM=no
1138 fi
1139
1140
1141
1142 # Check whether --enable-dynamic-libpam or --disable-dynamic-libpam was given.
1143 if test "${enable_dynamic_libpam+set}" = set; then
1144   enableval="$enable_dynamic_libpam"
1145   DYNAMIC_LIBPAM=no
1146 else
1147   DYNAMIC_LIBPAM=yes
1148 fi
1149
1150
1151
1152 DYNAMIC=-DPAM_DYNAMIC
1153
1154
1155 # Check whether --enable-static-modules or --disable-static-modules was given.
1156 if test "${enable_static_modules+set}" = set; then
1157   enableval="$enable_static_modules"
1158   STATIC=-DPAM_STATIC
1159 fi
1160
1161
1162
1163 # Check whether --enable-lckpwdf or --disable-lckpwdf was given.
1164 if test "${enable_lckpwdf+set}" = set; then
1165   enableval="$enable_lckpwdf"
1166   WITH_LCKPWDF=no
1167 else
1168   WITH_LCKPWDF=yes
1169 fi
1170
1171
1172
1173 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1174 echo "configure:1175: checking how to run the C preprocessor" >&5
1175 # On Suns, sometimes $CPP names a directory.
1176 if test -n "$CPP" && test -d "$CPP"; then
1177   CPP=
1178 fi
1179 if test -z "$CPP"; then
1180 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1181   echo $ac_n "(cached) $ac_c" 1>&6
1182 else
1183     # This must be in double quotes, not single quotes, because CPP may get
1184   # substituted into the Makefile and "${CC-cc}" will confuse make.
1185   CPP="${CC-cc} -E"
1186   # On the NeXT, cc -E runs the code through the compiler's parser,
1187   # not just through cpp.
1188   cat > conftest.$ac_ext <<EOF
1189 #line 1190 "configure"
1190 #include "confdefs.h"
1191 #include <assert.h>
1192 Syntax Error
1193 EOF
1194 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1195 { (eval echo configure:1196: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1196 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1197 if test -z "$ac_err"; then
1198   :
1199 else
1200   echo "$ac_err" >&5
1201   echo "configure: failed program was:" >&5
1202   cat conftest.$ac_ext >&5
1203   rm -rf conftest*
1204   CPP="${CC-cc} -E -traditional-cpp"
1205   cat > conftest.$ac_ext <<EOF
1206 #line 1207 "configure"
1207 #include "confdefs.h"
1208 #include <assert.h>
1209 Syntax Error
1210 EOF
1211 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1212 { (eval echo configure:1213: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1213 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1214 if test -z "$ac_err"; then
1215   :
1216 else
1217   echo "$ac_err" >&5
1218   echo "configure: failed program was:" >&5
1219   cat conftest.$ac_ext >&5
1220   rm -rf conftest*
1221   CPP="${CC-cc} -nologo -E"
1222   cat > conftest.$ac_ext <<EOF
1223 #line 1224 "configure"
1224 #include "confdefs.h"
1225 #include <assert.h>
1226 Syntax Error
1227 EOF
1228 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1229 { (eval echo configure:1230: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1230 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1231 if test -z "$ac_err"; then
1232   :
1233 else
1234   echo "$ac_err" >&5
1235   echo "configure: failed program was:" >&5
1236   cat conftest.$ac_ext >&5
1237   rm -rf conftest*
1238   CPP=/lib/cpp
1239 fi
1240 rm -f conftest*
1241 fi
1242 rm -f conftest*
1243 fi
1244 rm -f conftest*
1245   ac_cv_prog_CPP="$CPP"
1246 fi
1247   CPP="$ac_cv_prog_CPP"
1248 else
1249   ac_cv_prog_CPP="$CPP"
1250 fi
1251 echo "$ac_t""$CPP" 1>&6
1252
1253 for ac_hdr in paths.h
1254 do
1255 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1256 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1257 echo "configure:1258: checking for $ac_hdr" >&5
1258 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1259   echo $ac_n "(cached) $ac_c" 1>&6
1260 else
1261   cat > conftest.$ac_ext <<EOF
1262 #line 1263 "configure"
1263 #include "confdefs.h"
1264 #include <$ac_hdr>
1265 EOF
1266 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1267 { (eval echo configure:1268: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1268 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1269 if test -z "$ac_err"; then
1270   rm -rf conftest*
1271   eval "ac_cv_header_$ac_safe=yes"
1272 else
1273   echo "$ac_err" >&5
1274   echo "configure: failed program was:" >&5
1275   cat conftest.$ac_ext >&5
1276   rm -rf conftest*
1277   eval "ac_cv_header_$ac_safe=no"
1278 fi
1279 rm -f conftest*
1280 fi
1281 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1282   echo "$ac_t""yes" 1>&6
1283     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1284   cat >> confdefs.h <<EOF
1285 #define $ac_tr_hdr 1
1286 EOF
1287  
1288 else
1289   echo "$ac_t""no" 1>&6
1290 fi
1291 done
1292
1293 # Check whether --with-mailspool or --without-mailspool was given.
1294 if test "${with_mailspool+set}" = set; then
1295   withval="$with_mailspool"
1296   with_mailspool=${withval}
1297 fi
1298
1299 if test x$with_mailspool != x ; then
1300         pam_mail_spool="\"$with_mailspool\""
1301 else
1302         if test "$cross_compiling" = yes; then
1303   pam_mail_spool="\"/var/spool/mail\""
1304 else
1305   cat > conftest.$ac_ext <<EOF
1306 #line 1307 "configure"
1307 #include "confdefs.h"
1308
1309 #include <paths.h>
1310 int main() {
1311 #ifdef _PATH_MAILDIR
1312 exit(0);
1313 #else
1314 exit(1);
1315 #endif
1316 }
1317 EOF
1318 if { (eval echo configure:1319: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1319 then
1320   pam_mail_spool="_PATH_MAILDIR"
1321 else
1322   echo "configure: failed program was:" >&5
1323   cat conftest.$ac_ext >&5
1324   rm -fr conftest*
1325   pam_mail_spool="\"/var/spool/mail\""
1326 fi
1327 rm -fr conftest*
1328 fi
1329
1330 fi
1331 cat >> confdefs.h <<EOF
1332 #define PAM_PATH_MAILDIR $pam_mail_spool
1333 EOF
1334
1335
1336 echo $ac_n "checking for __libc_sched_setscheduler in -lc""... $ac_c" 1>&6
1337 echo "configure:1338: checking for __libc_sched_setscheduler in -lc" >&5
1338 ac_lib_var=`echo c'_'__libc_sched_setscheduler | sed 'y%./+-%__p_%'`
1339 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1340   echo $ac_n "(cached) $ac_c" 1>&6
1341 else
1342   ac_save_LIBS="$LIBS"
1343 LIBS="-lc  $LIBS"
1344 cat > conftest.$ac_ext <<EOF
1345 #line 1346 "configure"
1346 #include "confdefs.h"
1347 /* Override any gcc2 internal prototype to avoid an error.  */
1348 /* We use char because int might match the return type of a gcc2
1349     builtin and then its argument prototype would still apply.  */
1350 char __libc_sched_setscheduler();
1351
1352 int main() {
1353 __libc_sched_setscheduler()
1354 ; return 0; }
1355 EOF
1356 if { (eval echo configure:1357: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1357   rm -rf conftest*
1358   eval "ac_cv_lib_$ac_lib_var=yes"
1359 else
1360   echo "configure: failed program was:" >&5
1361   cat conftest.$ac_ext >&5
1362   rm -rf conftest*
1363   eval "ac_cv_lib_$ac_lib_var=no"
1364 fi
1365 rm -f conftest*
1366 LIBS="$ac_save_LIBS"
1367
1368 fi
1369 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1370   echo "$ac_t""yes" 1>&6
1371   PAM_NEEDS_LIBC=
1372 else
1373   echo "$ac_t""no" 1>&6
1374 PAM_NEEDS_LIBC=-lc
1375 fi
1376
1377
1378
1379 echo $ac_n "checking for lckpwdf in -lc""... $ac_c" 1>&6
1380 echo "configure:1381: checking for lckpwdf in -lc" >&5
1381 ac_lib_var=`echo c'_'lckpwdf | sed 'y%./+-%__p_%'`
1382 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1383   echo $ac_n "(cached) $ac_c" 1>&6
1384 else
1385   ac_save_LIBS="$LIBS"
1386 LIBS="-lc  $LIBS"
1387 cat > conftest.$ac_ext <<EOF
1388 #line 1389 "configure"
1389 #include "confdefs.h"
1390 /* Override any gcc2 internal prototype to avoid an error.  */
1391 /* We use char because int might match the return type of a gcc2
1392     builtin and then its argument prototype would still apply.  */
1393 char lckpwdf();
1394
1395 int main() {
1396 lckpwdf()
1397 ; return 0; }
1398 EOF
1399 if { (eval echo configure:1400: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1400   rm -rf conftest*
1401   eval "ac_cv_lib_$ac_lib_var=yes"
1402 else
1403   echo "configure: failed program was:" >&5
1404   cat conftest.$ac_ext >&5
1405   rm -rf conftest*
1406   eval "ac_cv_lib_$ac_lib_var=no"
1407 fi
1408 rm -f conftest*
1409 LIBS="$ac_save_LIBS"
1410
1411 fi
1412 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1413   echo "$ac_t""yes" 1>&6
1414   HAVE_LCKPWDF=yes
1415 else
1416   echo "$ac_t""no" 1>&6
1417 HAVE_LCKPWDF=no
1418 fi
1419
1420
1421
1422 echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
1423 echo "configure:1424: checking for dlopen in -ldl" >&5
1424 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
1425 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1426   echo $ac_n "(cached) $ac_c" 1>&6
1427 else
1428   ac_save_LIBS="$LIBS"
1429 LIBS="-ldl  $LIBS"
1430 cat > conftest.$ac_ext <<EOF
1431 #line 1432 "configure"
1432 #include "confdefs.h"
1433 /* Override any gcc2 internal prototype to avoid an error.  */
1434 /* We use char because int might match the return type of a gcc2
1435     builtin and then its argument prototype would still apply.  */
1436 char dlopen();
1437
1438 int main() {
1439 dlopen()
1440 ; return 0; }
1441 EOF
1442 if { (eval echo configure:1443: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1443   rm -rf conftest*
1444   eval "ac_cv_lib_$ac_lib_var=yes"
1445 else
1446   echo "configure: failed program was:" >&5
1447   cat conftest.$ac_ext >&5
1448   rm -rf conftest*
1449   eval "ac_cv_lib_$ac_lib_var=no"
1450 fi
1451 rm -f conftest*
1452 LIBS="$ac_save_LIBS"
1453
1454 fi
1455 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1456   echo "$ac_t""yes" 1>&6
1457   LIBDL=-ldl
1458 else
1459   echo "$ac_t""no" 1>&6
1460 fi
1461  
1462
1463
1464 echo $ac_n "checking for FascistCheck in -lcrack""... $ac_c" 1>&6
1465 echo "configure:1466: checking for FascistCheck in -lcrack" >&5
1466 ac_lib_var=`echo crack'_'FascistCheck | sed 'y%./+-%__p_%'`
1467 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1468   echo $ac_n "(cached) $ac_c" 1>&6
1469 else
1470   ac_save_LIBS="$LIBS"
1471 LIBS="-lcrack  $LIBS"
1472 cat > conftest.$ac_ext <<EOF
1473 #line 1474 "configure"
1474 #include "confdefs.h"
1475 /* Override any gcc2 internal prototype to avoid an error.  */
1476 /* We use char because int might match the return type of a gcc2
1477     builtin and then its argument prototype would still apply.  */
1478 char FascistCheck();
1479
1480 int main() {
1481 FascistCheck()
1482 ; return 0; }
1483 EOF
1484 if { (eval echo configure:1485: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1485   rm -rf conftest*
1486   eval "ac_cv_lib_$ac_lib_var=yes"
1487 else
1488   echo "configure: failed program was:" >&5
1489   cat conftest.$ac_ext >&5
1490   rm -rf conftest*
1491   eval "ac_cv_lib_$ac_lib_var=no"
1492 fi
1493 rm -f conftest*
1494 LIBS="$ac_save_LIBS"
1495
1496 fi
1497 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1498   echo "$ac_t""yes" 1>&6
1499   HAVE_LIBCRACK=yes ; cat >> confdefs.h <<\EOF
1500 #define HAVE_LIBCRACK 1
1501 EOF
1502
1503 else
1504   echo "$ac_t""no" 1>&6
1505 HAVE_LIBCRACK=no
1506 fi
1507
1508
1509
1510 echo $ac_n "checking for fcrypt in -lcrypt""... $ac_c" 1>&6
1511 echo "configure:1512: checking for fcrypt in -lcrypt" >&5
1512 ac_lib_var=`echo crypt'_'fcrypt | sed 'y%./+-%__p_%'`
1513 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1514   echo $ac_n "(cached) $ac_c" 1>&6
1515 else
1516   ac_save_LIBS="$LIBS"
1517 LIBS="-lcrypt  $LIBS"
1518 cat > conftest.$ac_ext <<EOF
1519 #line 1520 "configure"
1520 #include "confdefs.h"
1521 /* Override any gcc2 internal prototype to avoid an error.  */
1522 /* We use char because int might match the return type of a gcc2
1523     builtin and then its argument prototype would still apply.  */
1524 char fcrypt();
1525
1526 int main() {
1527 fcrypt()
1528 ; return 0; }
1529 EOF
1530 if { (eval echo configure:1531: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1531   rm -rf conftest*
1532   eval "ac_cv_lib_$ac_lib_var=yes"
1533 else
1534   echo "configure: failed program was:" >&5
1535   cat conftest.$ac_ext >&5
1536   rm -rf conftest*
1537   eval "ac_cv_lib_$ac_lib_var=no"
1538 fi
1539 rm -f conftest*
1540 LIBS="$ac_save_LIBS"
1541
1542 fi
1543 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1544   echo "$ac_t""yes" 1>&6
1545   HAVE_LIBCRYPT=yes ; cat >> confdefs.h <<\EOF
1546 #define HAVE_LIBCRYPT 1
1547 EOF
1548
1549 else
1550   echo "$ac_t""no" 1>&6
1551 HAVE_LIBCRYPT=no
1552 fi
1553
1554
1555 echo $ac_n "checking for logwtmp in -lutil""... $ac_c" 1>&6
1556 echo "configure:1557: checking for logwtmp in -lutil" >&5
1557 ac_lib_var=`echo util'_'logwtmp | sed 'y%./+-%__p_%'`
1558 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1559   echo $ac_n "(cached) $ac_c" 1>&6
1560 else
1561   ac_save_LIBS="$LIBS"
1562 LIBS="-lutil  $LIBS"
1563 cat > conftest.$ac_ext <<EOF
1564 #line 1565 "configure"
1565 #include "confdefs.h"
1566 /* Override any gcc2 internal prototype to avoid an error.  */
1567 /* We use char because int might match the return type of a gcc2
1568     builtin and then its argument prototype would still apply.  */
1569 char logwtmp();
1570
1571 int main() {
1572 logwtmp()
1573 ; return 0; }
1574 EOF
1575 if { (eval echo configure:1576: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1576   rm -rf conftest*
1577   eval "ac_cv_lib_$ac_lib_var=yes"
1578 else
1579   echo "configure: failed program was:" >&5
1580   cat conftest.$ac_ext >&5
1581   rm -rf conftest*
1582   eval "ac_cv_lib_$ac_lib_var=no"
1583 fi
1584 rm -f conftest*
1585 LIBS="$ac_save_LIBS"
1586
1587 fi
1588 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1589   echo "$ac_t""yes" 1>&6
1590   HAVE_LIBUTIL=yes ; cat >> confdefs.h <<\EOF
1591 #define HAVE_LIBUTIL 1
1592 EOF
1593
1594 else
1595   echo "$ac_t""no" 1>&6
1596 HAVE_LIBUTIL=no
1597 fi
1598
1599
1600 echo $ac_n "checking for dbm_store in -lndbm""... $ac_c" 1>&6
1601 echo "configure:1602: checking for dbm_store in -lndbm" >&5
1602 ac_lib_var=`echo ndbm'_'dbm_store | sed 'y%./+-%__p_%'`
1603 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1604   echo $ac_n "(cached) $ac_c" 1>&6
1605 else
1606   ac_save_LIBS="$LIBS"
1607 LIBS="-lndbm  $LIBS"
1608 cat > conftest.$ac_ext <<EOF
1609 #line 1610 "configure"
1610 #include "confdefs.h"
1611 /* Override any gcc2 internal prototype to avoid an error.  */
1612 /* We use char because int might match the return type of a gcc2
1613     builtin and then its argument prototype would still apply.  */
1614 char dbm_store();
1615
1616 int main() {
1617 dbm_store()
1618 ; return 0; }
1619 EOF
1620 if { (eval echo configure:1621: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1621   rm -rf conftest*
1622   eval "ac_cv_lib_$ac_lib_var=yes"
1623 else
1624   echo "configure: failed program was:" >&5
1625   cat conftest.$ac_ext >&5
1626   rm -rf conftest*
1627   eval "ac_cv_lib_$ac_lib_var=no"
1628 fi
1629 rm -f conftest*
1630 LIBS="$ac_save_LIBS"
1631
1632 fi
1633 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1634   echo "$ac_t""yes" 1>&6
1635   HAVE_LIBNDBM=yes ; cat >> confdefs.h <<\EOF
1636 #define HAVE_LIBNDBM 1
1637 EOF
1638
1639 else
1640   echo "$ac_t""no" 1>&6
1641 HAVE_LIBNDBM=no
1642 fi
1643
1644
1645 echo $ac_n "checking for dbm_store in -ldb""... $ac_c" 1>&6
1646 echo "configure:1647: checking for dbm_store in -ldb" >&5
1647 ac_lib_var=`echo db'_'dbm_store | sed 'y%./+-%__p_%'`
1648 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1649   echo $ac_n "(cached) $ac_c" 1>&6
1650 else
1651   ac_save_LIBS="$LIBS"
1652 LIBS="-ldb  $LIBS"
1653 cat > conftest.$ac_ext <<EOF
1654 #line 1655 "configure"
1655 #include "confdefs.h"
1656 /* Override any gcc2 internal prototype to avoid an error.  */
1657 /* We use char because int might match the return type of a gcc2
1658     builtin and then its argument prototype would still apply.  */
1659 char dbm_store();
1660
1661 int main() {
1662 dbm_store()
1663 ; return 0; }
1664 EOF
1665 if { (eval echo configure:1666: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1666   rm -rf conftest*
1667   eval "ac_cv_lib_$ac_lib_var=yes"
1668 else
1669   echo "configure: failed program was:" >&5
1670   cat conftest.$ac_ext >&5
1671   rm -rf conftest*
1672   eval "ac_cv_lib_$ac_lib_var=no"
1673 fi
1674 rm -f conftest*
1675 LIBS="$ac_save_LIBS"
1676
1677 fi
1678 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1679   echo "$ac_t""yes" 1>&6
1680   HAVE_LIBDB=yes ; cat >> confdefs.h <<\EOF
1681 #define HAVE_LIBDB 1
1682 EOF
1683
1684 else
1685   echo "$ac_t""no" 1>&6
1686 HAVE_LIBDB=no
1687 fi
1688
1689 if test x$HAVE_LIBDB != xyes ; then
1690         echo $ac_n "checking for db_create in -ldb""... $ac_c" 1>&6
1691 echo "configure:1692: checking for db_create in -ldb" >&5
1692 ac_lib_var=`echo db'_'db_create | sed 'y%./+-%__p_%'`
1693 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1694   echo $ac_n "(cached) $ac_c" 1>&6
1695 else
1696   ac_save_LIBS="$LIBS"
1697 LIBS="-ldb  $LIBS"
1698 cat > conftest.$ac_ext <<EOF
1699 #line 1700 "configure"
1700 #include "confdefs.h"
1701 /* Override any gcc2 internal prototype to avoid an error.  */
1702 /* We use char because int might match the return type of a gcc2
1703     builtin and then its argument prototype would still apply.  */
1704 char db_create();
1705
1706 int main() {
1707 db_create()
1708 ; return 0; }
1709 EOF
1710 if { (eval echo configure:1711: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1711   rm -rf conftest*
1712   eval "ac_cv_lib_$ac_lib_var=yes"
1713 else
1714   echo "configure: failed program was:" >&5
1715   cat conftest.$ac_ext >&5
1716   rm -rf conftest*
1717   eval "ac_cv_lib_$ac_lib_var=no"
1718 fi
1719 rm -f conftest*
1720 LIBS="$ac_save_LIBS"
1721
1722 fi
1723 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1724   echo "$ac_t""yes" 1>&6
1725   HAVE_LIBDB=yes ; cat >> confdefs.h <<\EOF
1726 #define HAVE_LIBDB 1
1727 EOF
1728
1729 else
1730   echo "$ac_t""no" 1>&6
1731 HAVE_LIBDB=no
1732 fi
1733
1734 fi
1735
1736 echo $ac_n "checking for yylex in -lfl""... $ac_c" 1>&6
1737 echo "configure:1738: checking for yylex in -lfl" >&5
1738 ac_lib_var=`echo fl'_'yylex | sed 'y%./+-%__p_%'`
1739 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1740   echo $ac_n "(cached) $ac_c" 1>&6
1741 else
1742   ac_save_LIBS="$LIBS"
1743 LIBS="-lfl HAVE_LIBFL=no $LIBS"
1744 cat > conftest.$ac_ext <<EOF
1745 #line 1746 "configure"
1746 #include "confdefs.h"
1747 /* Override any gcc2 internal prototype to avoid an error.  */
1748 /* We use char because int might match the return type of a gcc2
1749     builtin and then its argument prototype would still apply.  */
1750 char yylex();
1751
1752 int main() {
1753 yylex()
1754 ; return 0; }
1755 EOF
1756 if { (eval echo configure:1757: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1757   rm -rf conftest*
1758   eval "ac_cv_lib_$ac_lib_var=yes"
1759 else
1760   echo "configure: failed program was:" >&5
1761   cat conftest.$ac_ext >&5
1762   rm -rf conftest*
1763   eval "ac_cv_lib_$ac_lib_var=no"
1764 fi
1765 rm -f conftest*
1766 LIBS="$ac_save_LIBS"
1767
1768 fi
1769 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1770   echo "$ac_t""yes" 1>&6
1771   yyterminate
1772 else
1773   echo "$ac_t""no" 1>&6
1774 HAVE_LIBFL=yes ; cat >> confdefs.h <<\EOF
1775 #define HAVE_LIBFL 1
1776 EOF
1777
1778 fi
1779
1780
1781 echo $ac_n "checking for yp_maplist in -lnsl""... $ac_c" 1>&6
1782 echo "configure:1783: checking for yp_maplist in -lnsl" >&5
1783 ac_lib_var=`echo nsl'_'yp_maplist | sed 'y%./+-%__p_%'`
1784 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1785   echo $ac_n "(cached) $ac_c" 1>&6
1786 else
1787   ac_save_LIBS="$LIBS"
1788 LIBS="-lnsl  $LIBS"
1789 cat > conftest.$ac_ext <<EOF
1790 #line 1791 "configure"
1791 #include "confdefs.h"
1792 /* Override any gcc2 internal prototype to avoid an error.  */
1793 /* We use char because int might match the return type of a gcc2
1794     builtin and then its argument prototype would still apply.  */
1795 char yp_maplist();
1796
1797 int main() {
1798 yp_maplist()
1799 ; return 0; }
1800 EOF
1801 if { (eval echo configure:1802: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1802   rm -rf conftest*
1803   eval "ac_cv_lib_$ac_lib_var=yes"
1804 else
1805   echo "configure: failed program was:" >&5
1806   cat conftest.$ac_ext >&5
1807   rm -rf conftest*
1808   eval "ac_cv_lib_$ac_lib_var=no"
1809 fi
1810 rm -f conftest*
1811 LIBS="$ac_save_LIBS"
1812
1813 fi
1814 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1815   echo "$ac_t""yes" 1>&6
1816   HAVE_LIBNSL=yes ; cat >> confdefs.h <<\EOF
1817 #define HAVE_LIBNSL 1
1818 EOF
1819
1820 else
1821   echo "$ac_t""no" 1>&6
1822 HAVE_LIBNSL=no
1823 fi
1824
1825
1826 echo $ac_n "checking for pwdb_db_name in -lpwdb""... $ac_c" 1>&6
1827 echo "configure:1828: checking for pwdb_db_name in -lpwdb" >&5
1828 ac_lib_var=`echo pwdb'_'pwdb_db_name | sed 'y%./+-%__p_%'`
1829 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1830   echo $ac_n "(cached) $ac_c" 1>&6
1831 else
1832   ac_save_LIBS="$LIBS"
1833 LIBS="-lpwdb  $LIBS"
1834 cat > conftest.$ac_ext <<EOF
1835 #line 1836 "configure"
1836 #include "confdefs.h"
1837 /* Override any gcc2 internal prototype to avoid an error.  */
1838 /* We use char because int might match the return type of a gcc2
1839     builtin and then its argument prototype would still apply.  */
1840 char pwdb_db_name();
1841
1842 int main() {
1843 pwdb_db_name()
1844 ; return 0; }
1845 EOF
1846 if { (eval echo configure:1847: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1847   rm -rf conftest*
1848   eval "ac_cv_lib_$ac_lib_var=yes"
1849 else
1850   echo "configure: failed program was:" >&5
1851   cat conftest.$ac_ext >&5
1852   rm -rf conftest*
1853   eval "ac_cv_lib_$ac_lib_var=no"
1854 fi
1855 rm -f conftest*
1856 LIBS="$ac_save_LIBS"
1857
1858 fi
1859 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1860   echo "$ac_t""yes" 1>&6
1861   HAVE_LIBPWDB=yes ; cat >> confdefs.h <<\EOF
1862 #define HAVE_LIBPWDB 1
1863 EOF
1864
1865 else
1866   echo "$ac_t""no" 1>&6
1867 HAVE_LIBPWDB=no
1868 fi
1869
1870
1871 echo $ac_n "checking for yywrap in -lfl""... $ac_c" 1>&6
1872 echo "configure:1873: checking for yywrap in -lfl" >&5
1873 ac_lib_var=`echo fl'_'yywrap | sed 'y%./+-%__p_%'`
1874 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1875   echo $ac_n "(cached) $ac_c" 1>&6
1876 else
1877   ac_save_LIBS="$LIBS"
1878 LIBS="-lfl  $LIBS"
1879 cat > conftest.$ac_ext <<EOF
1880 #line 1881 "configure"
1881 #include "confdefs.h"
1882 /* Override any gcc2 internal prototype to avoid an error.  */
1883 /* We use char because int might match the return type of a gcc2
1884     builtin and then its argument prototype would still apply.  */
1885 char yywrap();
1886
1887 int main() {
1888 yywrap()
1889 ; return 0; }
1890 EOF
1891 if { (eval echo configure:1892: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1892   rm -rf conftest*
1893   eval "ac_cv_lib_$ac_lib_var=yes"
1894 else
1895   echo "configure: failed program was:" >&5
1896   cat conftest.$ac_ext >&5
1897   rm -rf conftest*
1898   eval "ac_cv_lib_$ac_lib_var=no"
1899 fi
1900 rm -f conftest*
1901 LIBS="$ac_save_LIBS"
1902
1903 fi
1904 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1905   echo "$ac_t""yes" 1>&6
1906   HAVE_LIBFLEX=yes ; cat >> confdefs.h <<\EOF
1907 #define HAVE_LIBFLEX 1
1908 EOF
1909
1910 else
1911   echo "$ac_t""no" 1>&6
1912 HAVE_LIBFLEX=no
1913 fi
1914
1915
1916 echo $ac_n "checking for yywrap in -ll""... $ac_c" 1>&6
1917 echo "configure:1918: checking for yywrap in -ll" >&5
1918 ac_lib_var=`echo l'_'yywrap | sed 'y%./+-%__p_%'`
1919 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1920   echo $ac_n "(cached) $ac_c" 1>&6
1921 else
1922   ac_save_LIBS="$LIBS"
1923 LIBS="-ll  $LIBS"
1924 cat > conftest.$ac_ext <<EOF
1925 #line 1926 "configure"
1926 #include "confdefs.h"
1927 /* Override any gcc2 internal prototype to avoid an error.  */
1928 /* We use char because int might match the return type of a gcc2
1929     builtin and then its argument prototype would still apply.  */
1930 char yywrap();
1931
1932 int main() {
1933 yywrap()
1934 ; return 0; }
1935 EOF
1936 if { (eval echo configure:1937: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1937   rm -rf conftest*
1938   eval "ac_cv_lib_$ac_lib_var=yes"
1939 else
1940   echo "configure: failed program was:" >&5
1941   cat conftest.$ac_ext >&5
1942   rm -rf conftest*
1943   eval "ac_cv_lib_$ac_lib_var=no"
1944 fi
1945 rm -f conftest*
1946 LIBS="$ac_save_LIBS"
1947
1948 fi
1949 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1950   echo "$ac_t""yes" 1>&6
1951   HAVE_LIBLEX=yes ; cat >> confdefs.h <<\EOF
1952 #define HAVE_LIBLEX 1
1953 EOF
1954
1955 else
1956   echo "$ac_t""no" 1>&6
1957 HAVE_LIBLEX=no
1958 fi
1959
1960
1961
1962 ac_header_dirent=no
1963 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
1964 do
1965 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1966 echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
1967 echo "configure:1968: checking for $ac_hdr that defines DIR" >&5
1968 if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
1969   echo $ac_n "(cached) $ac_c" 1>&6
1970 else
1971   cat > conftest.$ac_ext <<EOF
1972 #line 1973 "configure"
1973 #include "confdefs.h"
1974 #include <sys/types.h>
1975 #include <$ac_hdr>
1976 int main() {
1977 DIR *dirp = 0;
1978 ; return 0; }
1979 EOF
1980 if { (eval echo configure:1981: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1981   rm -rf conftest*
1982   eval "ac_cv_header_dirent_$ac_safe=yes"
1983 else
1984   echo "configure: failed program was:" >&5
1985   cat conftest.$ac_ext >&5
1986   rm -rf conftest*
1987   eval "ac_cv_header_dirent_$ac_safe=no"
1988 fi
1989 rm -f conftest*
1990 fi
1991 if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
1992   echo "$ac_t""yes" 1>&6
1993     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1994   cat >> confdefs.h <<EOF
1995 #define $ac_tr_hdr 1
1996 EOF
1997  ac_header_dirent=$ac_hdr; break
1998 else
1999   echo "$ac_t""no" 1>&6
2000 fi
2001 done
2002 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
2003 if test $ac_header_dirent = dirent.h; then
2004 echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
2005 echo "configure:2006: checking for opendir in -ldir" >&5
2006 ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
2007 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2008   echo $ac_n "(cached) $ac_c" 1>&6
2009 else
2010   ac_save_LIBS="$LIBS"
2011 LIBS="-ldir  $LIBS"
2012 cat > conftest.$ac_ext <<EOF
2013 #line 2014 "configure"
2014 #include "confdefs.h"
2015 /* Override any gcc2 internal prototype to avoid an error.  */
2016 /* We use char because int might match the return type of a gcc2
2017     builtin and then its argument prototype would still apply.  */
2018 char opendir();
2019
2020 int main() {
2021 opendir()
2022 ; return 0; }
2023 EOF
2024 if { (eval echo configure:2025: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2025   rm -rf conftest*
2026   eval "ac_cv_lib_$ac_lib_var=yes"
2027 else
2028   echo "configure: failed program was:" >&5
2029   cat conftest.$ac_ext >&5
2030   rm -rf conftest*
2031   eval "ac_cv_lib_$ac_lib_var=no"
2032 fi
2033 rm -f conftest*
2034 LIBS="$ac_save_LIBS"
2035
2036 fi
2037 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2038   echo "$ac_t""yes" 1>&6
2039   LIBS="$LIBS -ldir"
2040 else
2041   echo "$ac_t""no" 1>&6
2042 fi
2043
2044 else
2045 echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
2046 echo "configure:2047: checking for opendir in -lx" >&5
2047 ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
2048 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2049   echo $ac_n "(cached) $ac_c" 1>&6
2050 else
2051   ac_save_LIBS="$LIBS"
2052 LIBS="-lx  $LIBS"
2053 cat > conftest.$ac_ext <<EOF
2054 #line 2055 "configure"
2055 #include "confdefs.h"
2056 /* Override any gcc2 internal prototype to avoid an error.  */
2057 /* We use char because int might match the return type of a gcc2
2058     builtin and then its argument prototype would still apply.  */
2059 char opendir();
2060
2061 int main() {
2062 opendir()
2063 ; return 0; }
2064 EOF
2065 if { (eval echo configure:2066: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2066   rm -rf conftest*
2067   eval "ac_cv_lib_$ac_lib_var=yes"
2068 else
2069   echo "configure: failed program was:" >&5
2070   cat conftest.$ac_ext >&5
2071   rm -rf conftest*
2072   eval "ac_cv_lib_$ac_lib_var=no"
2073 fi
2074 rm -f conftest*
2075 LIBS="$ac_save_LIBS"
2076
2077 fi
2078 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2079   echo "$ac_t""yes" 1>&6
2080   LIBS="$LIBS -lx"
2081 else
2082   echo "$ac_t""no" 1>&6
2083 fi
2084
2085 fi
2086
2087 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
2088 echo "configure:2089: checking for ANSI C header files" >&5
2089 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
2090   echo $ac_n "(cached) $ac_c" 1>&6
2091 else
2092   cat > conftest.$ac_ext <<EOF
2093 #line 2094 "configure"
2094 #include "confdefs.h"
2095 #include <stdlib.h>
2096 #include <stdarg.h>
2097 #include <string.h>
2098 #include <float.h>
2099 EOF
2100 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2101 { (eval echo configure:2102: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2102 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2103 if test -z "$ac_err"; then
2104   rm -rf conftest*
2105   ac_cv_header_stdc=yes
2106 else
2107   echo "$ac_err" >&5
2108   echo "configure: failed program was:" >&5
2109   cat conftest.$ac_ext >&5
2110   rm -rf conftest*
2111   ac_cv_header_stdc=no
2112 fi
2113 rm -f conftest*
2114
2115 if test $ac_cv_header_stdc = yes; then
2116   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2117 cat > conftest.$ac_ext <<EOF
2118 #line 2119 "configure"
2119 #include "confdefs.h"
2120 #include <string.h>
2121 EOF
2122 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2123   egrep "memchr" >/dev/null 2>&1; then
2124   :
2125 else
2126   rm -rf conftest*
2127   ac_cv_header_stdc=no
2128 fi
2129 rm -f conftest*
2130
2131 fi
2132
2133 if test $ac_cv_header_stdc = yes; then
2134   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2135 cat > conftest.$ac_ext <<EOF
2136 #line 2137 "configure"
2137 #include "confdefs.h"
2138 #include <stdlib.h>
2139 EOF
2140 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2141   egrep "free" >/dev/null 2>&1; then
2142   :
2143 else
2144   rm -rf conftest*
2145   ac_cv_header_stdc=no
2146 fi
2147 rm -f conftest*
2148
2149 fi
2150
2151 if test $ac_cv_header_stdc = yes; then
2152   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2153 if test "$cross_compiling" = yes; then
2154   :
2155 else
2156   cat > conftest.$ac_ext <<EOF
2157 #line 2158 "configure"
2158 #include "confdefs.h"
2159 #include <ctype.h>
2160 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2161 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2162 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2163 int main () { int i; for (i = 0; i < 256; i++)
2164 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
2165 exit (0); }
2166
2167 EOF
2168 if { (eval echo configure:2169: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2169 then
2170   :
2171 else
2172   echo "configure: failed program was:" >&5
2173   cat conftest.$ac_ext >&5
2174   rm -fr conftest*
2175   ac_cv_header_stdc=no
2176 fi
2177 rm -fr conftest*
2178 fi
2179
2180 fi
2181 fi
2182
2183 echo "$ac_t""$ac_cv_header_stdc" 1>&6
2184 if test $ac_cv_header_stdc = yes; then
2185   cat >> confdefs.h <<\EOF
2186 #define STDC_HEADERS 1
2187 EOF
2188
2189 fi
2190
2191 echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
2192 echo "configure:2193: checking for sys/wait.h that is POSIX.1 compatible" >&5
2193 if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
2194   echo $ac_n "(cached) $ac_c" 1>&6
2195 else
2196   cat > conftest.$ac_ext <<EOF
2197 #line 2198 "configure"
2198 #include "confdefs.h"
2199 #include <sys/types.h>
2200 #include <sys/wait.h>
2201 #ifndef WEXITSTATUS
2202 #define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
2203 #endif
2204 #ifndef WIFEXITED
2205 #define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
2206 #endif
2207 int main() {
2208 int s;
2209 wait (&s);
2210 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
2211 ; return 0; }
2212 EOF
2213 if { (eval echo configure:2214: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2214   rm -rf conftest*
2215   ac_cv_header_sys_wait_h=yes
2216 else
2217   echo "configure: failed program was:" >&5
2218   cat conftest.$ac_ext >&5
2219   rm -rf conftest*
2220   ac_cv_header_sys_wait_h=no
2221 fi
2222 rm -f conftest*
2223 fi
2224
2225 echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6
2226 if test $ac_cv_header_sys_wait_h = yes; then
2227   cat >> confdefs.h <<\EOF
2228 #define HAVE_SYS_WAIT_H 1
2229 EOF
2230
2231 fi
2232
2233 for ac_hdr in fcntl.h limits.h malloc.h sys/file.h sys/ioctl.h sys/time.h syslog.h termio.h unistd.h sys/fsuid.h
2234 do
2235 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2236 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2237 echo "configure:2238: checking for $ac_hdr" >&5
2238 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2239   echo $ac_n "(cached) $ac_c" 1>&6
2240 else
2241   cat > conftest.$ac_ext <<EOF
2242 #line 2243 "configure"
2243 #include "confdefs.h"
2244 #include <$ac_hdr>
2245 EOF
2246 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2247 { (eval echo configure:2248: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2248 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2249 if test -z "$ac_err"; then
2250   rm -rf conftest*
2251   eval "ac_cv_header_$ac_safe=yes"
2252 else
2253   echo "$ac_err" >&5
2254   echo "configure: failed program was:" >&5
2255   cat conftest.$ac_ext >&5
2256   rm -rf conftest*
2257   eval "ac_cv_header_$ac_safe=no"
2258 fi
2259 rm -f conftest*
2260 fi
2261 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2262   echo "$ac_t""yes" 1>&6
2263     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2264   cat >> confdefs.h <<EOF
2265 #define $ac_tr_hdr 1
2266 EOF
2267  
2268 else
2269   echo "$ac_t""no" 1>&6
2270 fi
2271 done
2272
2273
2274 for ac_hdr in features.h
2275 do
2276 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2277 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2278 echo "configure:2279: checking for $ac_hdr" >&5
2279 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2280   echo $ac_n "(cached) $ac_c" 1>&6
2281 else
2282   cat > conftest.$ac_ext <<EOF
2283 #line 2284 "configure"
2284 #include "confdefs.h"
2285 #include <$ac_hdr>
2286 EOF
2287 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2288 { (eval echo configure:2289: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2289 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2290 if test -z "$ac_err"; then
2291   rm -rf conftest*
2292   eval "ac_cv_header_$ac_safe=yes"
2293 else
2294   echo "$ac_err" >&5
2295   echo "configure: failed program was:" >&5
2296   cat conftest.$ac_ext >&5
2297   rm -rf conftest*
2298   eval "ac_cv_header_$ac_safe=no"
2299 fi
2300 rm -f conftest*
2301 fi
2302 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2303   echo "$ac_t""yes" 1>&6
2304     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2305   cat >> confdefs.h <<EOF
2306 #define $ac_tr_hdr 1
2307 EOF
2308  
2309 else
2310   echo "$ac_t""no" 1>&6
2311 fi
2312 done
2313
2314
2315 for ac_hdr in crypt.h
2316 do
2317 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2318 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2319 echo "configure:2320: checking for $ac_hdr" >&5
2320 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2321   echo $ac_n "(cached) $ac_c" 1>&6
2322 else
2323   cat > conftest.$ac_ext <<EOF
2324 #line 2325 "configure"
2325 #include "confdefs.h"
2326 #include <$ac_hdr>
2327 EOF
2328 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2329 { (eval echo configure:2330: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2330 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2331 if test -z "$ac_err"; then
2332   rm -rf conftest*
2333   eval "ac_cv_header_$ac_safe=yes"
2334 else
2335   echo "$ac_err" >&5
2336   echo "configure: failed program was:" >&5
2337   cat conftest.$ac_ext >&5
2338   rm -rf conftest*
2339   eval "ac_cv_header_$ac_safe=no"
2340 fi
2341 rm -f conftest*
2342 fi
2343 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2344   echo "$ac_t""yes" 1>&6
2345     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2346   cat >> confdefs.h <<EOF
2347 #define $ac_tr_hdr 1
2348 EOF
2349  
2350 else
2351   echo "$ac_t""no" 1>&6
2352 fi
2353 done
2354
2355
2356 for ac_hdr in ndbm.h db.h
2357 do
2358 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2359 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2360 echo "configure:2361: checking for $ac_hdr" >&5
2361 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2362   echo $ac_n "(cached) $ac_c" 1>&6
2363 else
2364   cat > conftest.$ac_ext <<EOF
2365 #line 2366 "configure"
2366 #include "confdefs.h"
2367 #include <$ac_hdr>
2368 EOF
2369 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2370 { (eval echo configure:2371: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2371 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2372 if test -z "$ac_err"; then
2373   rm -rf conftest*
2374   eval "ac_cv_header_$ac_safe=yes"
2375 else
2376   echo "$ac_err" >&5
2377   echo "configure: failed program was:" >&5
2378   cat conftest.$ac_ext >&5
2379   rm -rf conftest*
2380   eval "ac_cv_header_$ac_safe=no"
2381 fi
2382 rm -f conftest*
2383 fi
2384 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2385   echo "$ac_t""yes" 1>&6
2386     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2387   cat >> confdefs.h <<EOF
2388 #define $ac_tr_hdr 1
2389 EOF
2390  
2391 else
2392   echo "$ac_t""no" 1>&6
2393 fi
2394 done
2395
2396 HAVE_NDBM_H=$ac_cv_header_ndbm_h
2397
2398
2399 for ac_hdr in lastlog.h utmp.h utmpx.h
2400 do
2401 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2402 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2403 echo "configure:2404: checking for $ac_hdr" >&5
2404 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2405   echo $ac_n "(cached) $ac_c" 1>&6
2406 else
2407   cat > conftest.$ac_ext <<EOF
2408 #line 2409 "configure"
2409 #include "confdefs.h"
2410 #include <$ac_hdr>
2411 EOF
2412 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2413 { (eval echo configure:2414: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2414 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2415 if test -z "$ac_err"; then
2416   rm -rf conftest*
2417   eval "ac_cv_header_$ac_safe=yes"
2418 else
2419   echo "$ac_err" >&5
2420   echo "configure: failed program was:" >&5
2421   cat conftest.$ac_ext >&5
2422   rm -rf conftest*
2423   eval "ac_cv_header_$ac_safe=no"
2424 fi
2425 rm -f conftest*
2426 fi
2427 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2428   echo "$ac_t""yes" 1>&6
2429     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2430   cat >> confdefs.h <<EOF
2431 #define $ac_tr_hdr 1
2432 EOF
2433  
2434 else
2435   echo "$ac_t""no" 1>&6
2436 fi
2437 done
2438
2439
2440
2441 echo $ac_n "checking path to cracklib dictionary""... $ac_c" 1>&6
2442 echo "configure:2443: checking path to cracklib dictionary" >&5
2443 DICT_DIR_CANDIDATES="/usr/lib /usr/share/dict /usr/share/lib \
2444   /usr/local/lib /usr/local/share/lib"
2445 DICT_FILE_CANDIDATES="pw_dict cracklib_dict"
2446 CRACKLIB_DICTPATH=""
2447 for d in $DICT_DIR_CANDIDATES ; do
2448       for f in $DICT_FILE_CANDIDATES ; do
2449               if test -r $d/$f.hwm ; then
2450                       CRACKLIB_DICTPATH=$d/$f
2451                       break 2
2452               elif test -r $d/dict/$f.hwm ; then
2453                       CRACKLIB_DICTPATH=$d/dict/$f
2454                       break 2
2455               fi
2456       done
2457 done
2458 if test -z "$CRACKLIB_DICTPATH" ; then
2459       echo "$ac_t""none found" 1>&6
2460 else
2461       echo "$ac_t""$CRACKLIB_DICTPATH" 1>&6
2462 fi
2463
2464
2465
2466 GCC_WARNINGS="-Wall -Wwrite-strings \
2467         -Wpointer-arith -Wcast-qual -Wcast-align \
2468         -Wstrict-prototypes -Wmissing-prototypes \
2469         -Wnested-externs -Winline -Wshadow"
2470
2471 if test "$GCC" = yes; then
2472         CC=gcc                          ; 
2473 ### May need per-OS attention
2474 ### Example: -D_POSIX_SOURCE: needed on Linux but harms Solaris.
2475         case $OS in
2476         linux)
2477                 OS_CFLAGS="-ansi -D_POSIX_SOURCE -pedantic"
2478                 LD_D="gcc -shared -Xlinker -x"
2479                 WARNINGS="$GCC_WARNINGS"
2480                 PIC="-fPIC"
2481                 DYNTYPE=so
2482                 LD=ld                           
2483                 LD_L="$LD -x -shared"
2484                 RANLIB=ranlib
2485                 STRIP=strip
2486                 CC_STATIC="-Xlinker -export-dynamic"
2487                 ;;
2488         sunos)
2489                 OS_CFLAGS="-ansi -pedantic"
2490                 LD_D="gcc -shared -Xlinker -x"
2491                 WARNINGS="$GCC_WARNINGS"
2492                 PIC="-fPIC"
2493                 DYNTYPE=so
2494                 LD=ld                           
2495                 LD_L="$LD -x -shared"
2496                 RANLIB=ranlib
2497                 STRIP=strip
2498                 CC_STATIC="-Xlinker -export-dynamic"
2499                 ;;
2500         aix)
2501                 OS_CFLAGS=""
2502                 DYNTYPE=lo
2503                 LD=ld                           
2504                 LD_L=ld -bexpall -bM:SRE -bnoentry
2505                 LD_D="$LD_L"
2506                 RANLIB=ranlib
2507                 STRIP=strip
2508                 ;;
2509         *)
2510                 OS_CFLAGS=""
2511                 ;;
2512         esac
2513 else
2514 ###
2515 ### Non-gcc needs attention on per-OS basis
2516 ###
2517         case "$OS" in
2518         darwin)
2519 # add some stuff here (see sourceforge bug 534205)
2520 # DOCDIR=/System/Documentation/Administration/Libraries/PAM
2521 # MANDIR=/usr/share/man
2522                 ;;
2523         solaris)
2524             ### Support for Solaris-C
2525             OS_CFLAGS=""
2526             WARNINGS=""
2527             PIC="-K pic"
2528             LD=ld
2529             LD_D="cc -z text -G -R."
2530             LD_L="$LD_D"
2531             RANLIB=ranlib
2532             STRIP=strip
2533             CC_STATIC=
2534             ;;
2535         irix*)
2536             OSRELEASE=`uname -r`
2537             if test "$OSRELEASE" = 6.5; then
2538                 OS_CFLAGS=""
2539                 WARNINGS="-fullwarn"
2540                 PIC=                    #PIC code is default for IRIX
2541                 LD="cc -shared"         # modules friendly approach
2542                 LD_D="cc -shared"
2543                 LD_L="ld -G -z redlocsym"
2544                 RANLIB=echo
2545                 STRIP=strip
2546                 CC_STATIC=
2547             else
2548                 echo "IRIX prior to 6.5 not allowed for"
2549                 exit
2550             fi
2551             ;;
2552        *) echo "Native compiler on $OS is not yet supported"
2553                exit
2554             ;;
2555        esac
2556 fi
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569 echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
2570 echo "configure:2571: checking whether byte ordering is bigendian" >&5
2571 if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
2572   echo $ac_n "(cached) $ac_c" 1>&6
2573 else
2574   ac_cv_c_bigendian=unknown
2575 # See if sys/param.h defines the BYTE_ORDER macro.
2576 cat > conftest.$ac_ext <<EOF
2577 #line 2578 "configure"
2578 #include "confdefs.h"
2579 #include <sys/types.h>
2580 #include <sys/param.h>
2581 int main() {
2582
2583 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
2584  bogus endian macros
2585 #endif
2586 ; return 0; }
2587 EOF
2588 if { (eval echo configure:2589: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2589   rm -rf conftest*
2590   # It does; now see whether it defined to BIG_ENDIAN or not.
2591 cat > conftest.$ac_ext <<EOF
2592 #line 2593 "configure"
2593 #include "confdefs.h"
2594 #include <sys/types.h>
2595 #include <sys/param.h>
2596 int main() {
2597
2598 #if BYTE_ORDER != BIG_ENDIAN
2599  not big endian
2600 #endif
2601 ; return 0; }
2602 EOF
2603 if { (eval echo configure:2604: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2604   rm -rf conftest*
2605   ac_cv_c_bigendian=yes
2606 else
2607   echo "configure: failed program was:" >&5
2608   cat conftest.$ac_ext >&5
2609   rm -rf conftest*
2610   ac_cv_c_bigendian=no
2611 fi
2612 rm -f conftest*
2613 else
2614   echo "configure: failed program was:" >&5
2615   cat conftest.$ac_ext >&5
2616 fi
2617 rm -f conftest*
2618 if test $ac_cv_c_bigendian = unknown; then
2619 if test "$cross_compiling" = yes; then
2620     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
2621 else
2622   cat > conftest.$ac_ext <<EOF
2623 #line 2624 "configure"
2624 #include "confdefs.h"
2625 main () {
2626   /* Are we little or big endian?  From Harbison&Steele.  */
2627   union
2628   {
2629     long l;
2630     char c[sizeof (long)];
2631   } u;
2632   u.l = 1;
2633   exit (u.c[sizeof (long) - 1] == 1);
2634 }
2635 EOF
2636 if { (eval echo configure:2637: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2637 then
2638   ac_cv_c_bigendian=no
2639 else
2640   echo "configure: failed program was:" >&5
2641   cat conftest.$ac_ext >&5
2642   rm -fr conftest*
2643   ac_cv_c_bigendian=yes
2644 fi
2645 rm -fr conftest*
2646 fi
2647
2648 fi
2649 fi
2650
2651 echo "$ac_t""$ac_cv_c_bigendian" 1>&6
2652 if test $ac_cv_c_bigendian = yes; then
2653   cat >> confdefs.h <<\EOF
2654 #define WORDS_BIGENDIAN 1
2655 EOF
2656
2657 fi
2658
2659 echo $ac_n "checking for working const""... $ac_c" 1>&6
2660 echo "configure:2661: checking for working const" >&5
2661 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
2662   echo $ac_n "(cached) $ac_c" 1>&6
2663 else
2664   cat > conftest.$ac_ext <<EOF
2665 #line 2666 "configure"
2666 #include "confdefs.h"
2667
2668 int main() {
2669
2670 /* Ultrix mips cc rejects this.  */
2671 typedef int charset[2]; const charset x;
2672 /* SunOS 4.1.1 cc rejects this.  */
2673 char const *const *ccp;
2674 char **p;
2675 /* NEC SVR4.0.2 mips cc rejects this.  */
2676 struct point {int x, y;};
2677 static struct point const zero = {0,0};
2678 /* AIX XL C 1.02.0.0 rejects this.
2679    It does not let you subtract one const X* pointer from another in an arm
2680    of an if-expression whose if-part is not a constant expression */
2681 const char *g = "string";
2682 ccp = &g + (g ? g-g : 0);
2683 /* HPUX 7.0 cc rejects these. */
2684 ++ccp;
2685 p = (char**) ccp;
2686 ccp = (char const *const *) p;
2687 { /* SCO 3.2v4 cc rejects this.  */
2688   char *t;
2689   char const *s = 0 ? (char *) 0 : (char const *) 0;
2690
2691   *t++ = 0;
2692 }
2693 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
2694   int x[] = {25, 17};
2695   const int *foo = &x[0];
2696   ++foo;
2697 }
2698 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
2699   typedef const int *iptr;
2700   iptr p = 0;
2701   ++p;
2702 }
2703 { /* AIX XL C 1.02.0.0 rejects this saying
2704      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
2705   struct s { int j; const int *ap[3]; };
2706   struct s *b; b->j = 5;
2707 }
2708 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
2709   const int foo = 10;
2710 }
2711
2712 ; return 0; }
2713 EOF
2714 if { (eval echo configure:2715: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2715   rm -rf conftest*
2716   ac_cv_c_const=yes
2717 else
2718   echo "configure: failed program was:" >&5
2719   cat conftest.$ac_ext >&5
2720   rm -rf conftest*
2721   ac_cv_c_const=no
2722 fi
2723 rm -f conftest*
2724 fi
2725
2726 echo "$ac_t""$ac_cv_c_const" 1>&6
2727 if test $ac_cv_c_const = no; then
2728   cat >> confdefs.h <<\EOF
2729 #define const 
2730 EOF
2731
2732 fi
2733
2734 echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
2735 echo "configure:2736: checking for uid_t in sys/types.h" >&5
2736 if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
2737   echo $ac_n "(cached) $ac_c" 1>&6
2738 else
2739   cat > conftest.$ac_ext <<EOF
2740 #line 2741 "configure"
2741 #include "confdefs.h"
2742 #include <sys/types.h>
2743 EOF
2744 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2745   egrep "uid_t" >/dev/null 2>&1; then
2746   rm -rf conftest*
2747   ac_cv_type_uid_t=yes
2748 else
2749   rm -rf conftest*
2750   ac_cv_type_uid_t=no
2751 fi
2752 rm -f conftest*
2753
2754 fi
2755
2756 echo "$ac_t""$ac_cv_type_uid_t" 1>&6
2757 if test $ac_cv_type_uid_t = no; then
2758   cat >> confdefs.h <<\EOF
2759 #define uid_t int
2760 EOF
2761
2762   cat >> confdefs.h <<\EOF
2763 #define gid_t int
2764 EOF
2765
2766 fi
2767
2768 echo $ac_n "checking for off_t""... $ac_c" 1>&6
2769 echo "configure:2770: checking for off_t" >&5
2770 if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
2771   echo $ac_n "(cached) $ac_c" 1>&6
2772 else
2773   cat > conftest.$ac_ext <<EOF
2774 #line 2775 "configure"
2775 #include "confdefs.h"
2776 #include <sys/types.h>
2777 #if STDC_HEADERS
2778 #include <stdlib.h>
2779 #include <stddef.h>
2780 #endif
2781 EOF
2782 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2783   egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2784   rm -rf conftest*
2785   ac_cv_type_off_t=yes
2786 else
2787   rm -rf conftest*
2788   ac_cv_type_off_t=no
2789 fi
2790 rm -f conftest*
2791
2792 fi
2793 echo "$ac_t""$ac_cv_type_off_t" 1>&6
2794 if test $ac_cv_type_off_t = no; then
2795   cat >> confdefs.h <<\EOF
2796 #define off_t long
2797 EOF
2798
2799 fi
2800
2801 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
2802 echo "configure:2803: checking for pid_t" >&5
2803 if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
2804   echo $ac_n "(cached) $ac_c" 1>&6
2805 else
2806   cat > conftest.$ac_ext <<EOF
2807 #line 2808 "configure"
2808 #include "confdefs.h"
2809 #include <sys/types.h>
2810 #if STDC_HEADERS
2811 #include <stdlib.h>
2812 #include <stddef.h>
2813 #endif
2814 EOF
2815 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2816   egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2817   rm -rf conftest*
2818   ac_cv_type_pid_t=yes
2819 else
2820   rm -rf conftest*
2821   ac_cv_type_pid_t=no
2822 fi
2823 rm -f conftest*
2824
2825 fi
2826 echo "$ac_t""$ac_cv_type_pid_t" 1>&6
2827 if test $ac_cv_type_pid_t = no; then
2828   cat >> confdefs.h <<\EOF
2829 #define pid_t int
2830 EOF
2831
2832 fi
2833
2834 echo $ac_n "checking for size_t""... $ac_c" 1>&6
2835 echo "configure:2836: checking for size_t" >&5
2836 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
2837   echo $ac_n "(cached) $ac_c" 1>&6
2838 else
2839   cat > conftest.$ac_ext <<EOF
2840 #line 2841 "configure"
2841 #include "confdefs.h"
2842 #include <sys/types.h>
2843 #if STDC_HEADERS
2844 #include <stdlib.h>
2845 #include <stddef.h>
2846 #endif
2847 EOF
2848 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2849   egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2850   rm -rf conftest*
2851   ac_cv_type_size_t=yes
2852 else
2853   rm -rf conftest*
2854   ac_cv_type_size_t=no
2855 fi
2856 rm -f conftest*
2857
2858 fi
2859 echo "$ac_t""$ac_cv_type_size_t" 1>&6
2860 if test $ac_cv_type_size_t = no; then
2861   cat >> confdefs.h <<\EOF
2862 #define size_t unsigned
2863 EOF
2864
2865 fi
2866
2867 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
2868 echo "configure:2869: checking whether time.h and sys/time.h may both be included" >&5
2869 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
2870   echo $ac_n "(cached) $ac_c" 1>&6
2871 else
2872   cat > conftest.$ac_ext <<EOF
2873 #line 2874 "configure"
2874 #include "confdefs.h"
2875 #include <sys/types.h>
2876 #include <sys/time.h>
2877 #include <time.h>
2878 int main() {
2879 struct tm *tp;
2880 ; return 0; }
2881 EOF
2882 if { (eval echo configure:2883: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2883   rm -rf conftest*
2884   ac_cv_header_time=yes
2885 else
2886   echo "configure: failed program was:" >&5
2887   cat conftest.$ac_ext >&5
2888   rm -rf conftest*
2889   ac_cv_header_time=no
2890 fi
2891 rm -f conftest*
2892 fi
2893
2894 echo "$ac_t""$ac_cv_header_time" 1>&6
2895 if test $ac_cv_header_time = yes; then
2896   cat >> confdefs.h <<\EOF
2897 #define TIME_WITH_SYS_TIME 1
2898 EOF
2899
2900 fi
2901
2902 echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
2903 echo "configure:2904: checking whether struct tm is in sys/time.h or time.h" >&5
2904 if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
2905   echo $ac_n "(cached) $ac_c" 1>&6
2906 else
2907   cat > conftest.$ac_ext <<EOF
2908 #line 2909 "configure"
2909 #include "confdefs.h"
2910 #include <sys/types.h>
2911 #include <time.h>
2912 int main() {
2913 struct tm *tp; tp->tm_sec;
2914 ; return 0; }
2915 EOF
2916 if { (eval echo configure:2917: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2917   rm -rf conftest*
2918   ac_cv_struct_tm=time.h
2919 else
2920   echo "configure: failed program was:" >&5
2921   cat conftest.$ac_ext >&5
2922   rm -rf conftest*
2923   ac_cv_struct_tm=sys/time.h
2924 fi
2925 rm -f conftest*
2926 fi
2927
2928 echo "$ac_t""$ac_cv_struct_tm" 1>&6
2929 if test $ac_cv_struct_tm = sys/time.h; then
2930   cat >> confdefs.h <<\EOF
2931 #define TM_IN_SYS_TIME 1
2932 EOF
2933
2934 fi
2935
2936
2937 echo $ac_n "checking type of array argument to getgroups""... $ac_c" 1>&6
2938 echo "configure:2939: checking type of array argument to getgroups" >&5
2939 if eval "test \"`echo '$''{'ac_cv_type_getgroups'+set}'`\" = set"; then
2940   echo $ac_n "(cached) $ac_c" 1>&6
2941 else
2942   if test "$cross_compiling" = yes; then
2943   ac_cv_type_getgroups=cross
2944 else
2945   cat > conftest.$ac_ext <<EOF
2946 #line 2947 "configure"
2947 #include "confdefs.h"
2948
2949 /* Thanks to Mike Rendell for this test.  */
2950 #include <sys/types.h>
2951 #define NGID 256
2952 #undef MAX
2953 #define MAX(x, y) ((x) > (y) ? (x) : (y))
2954 main()
2955 {
2956   gid_t gidset[NGID];
2957   int i, n;
2958   union { gid_t gval; long lval; }  val;
2959
2960   val.lval = -1;
2961   for (i = 0; i < NGID; i++)
2962     gidset[i] = val.gval;
2963   n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
2964                  gidset);
2965   /* Exit non-zero if getgroups seems to require an array of ints.  This
2966      happens when gid_t is short but getgroups modifies an array of ints.  */
2967   exit ((n > 0 && gidset[n] != val.gval) ? 1 : 0);
2968 }
2969
2970 EOF
2971 if { (eval echo configure:2972: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2972 then
2973     ac_cv_type_getgroups=gid_t
2974 else
2975   echo "configure: failed program was:" >&5
2976   cat conftest.$ac_ext >&5
2977   rm -fr conftest*
2978   ac_cv_type_getgroups=int
2979 fi
2980 rm -fr conftest*
2981 fi
2982
2983 if test $ac_cv_type_getgroups = cross; then
2984         cat > conftest.$ac_ext <<EOF
2985 #line 2986 "configure"
2986 #include "confdefs.h"
2987 #include <unistd.h>
2988 EOF
2989 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2990   egrep "getgroups.*int.*gid_t" >/dev/null 2>&1; then
2991   rm -rf conftest*
2992   ac_cv_type_getgroups=gid_t
2993 else
2994   rm -rf conftest*
2995   ac_cv_type_getgroups=int
2996 fi
2997 rm -f conftest*
2998
2999 fi
3000 fi
3001
3002 echo "$ac_t""$ac_cv_type_getgroups" 1>&6
3003 cat >> confdefs.h <<EOF
3004 #define GETGROUPS_T $ac_cv_type_getgroups
3005 EOF
3006
3007
3008 if test $ac_cv_prog_gcc = yes; then
3009     echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6
3010 echo "configure:3011: checking whether ${CC-cc} needs -traditional" >&5
3011 if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then
3012   echo $ac_n "(cached) $ac_c" 1>&6
3013 else
3014     ac_pattern="Autoconf.*'x'"
3015   cat > conftest.$ac_ext <<EOF
3016 #line 3017 "configure"
3017 #include "confdefs.h"
3018 #include <sgtty.h>
3019 Autoconf TIOCGETP
3020 EOF
3021 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3022   egrep "$ac_pattern" >/dev/null 2>&1; then
3023   rm -rf conftest*
3024   ac_cv_prog_gcc_traditional=yes
3025 else
3026   rm -rf conftest*
3027   ac_cv_prog_gcc_traditional=no
3028 fi
3029 rm -f conftest*
3030
3031
3032   if test $ac_cv_prog_gcc_traditional = no; then
3033     cat > conftest.$ac_ext <<EOF
3034 #line 3035 "configure"
3035 #include "confdefs.h"
3036 #include <termio.h>
3037 Autoconf TCGETA
3038 EOF
3039 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3040   egrep "$ac_pattern" >/dev/null 2>&1; then
3041   rm -rf conftest*
3042   ac_cv_prog_gcc_traditional=yes
3043 fi
3044 rm -f conftest*
3045
3046   fi
3047 fi
3048
3049 echo "$ac_t""$ac_cv_prog_gcc_traditional" 1>&6
3050   if test $ac_cv_prog_gcc_traditional = yes; then
3051     CC="$CC -traditional"
3052   fi
3053 fi
3054
3055 echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6
3056 echo "configure:3057: checking for 8-bit clean memcmp" >&5
3057 if eval "test \"`echo '$''{'ac_cv_func_memcmp_clean'+set}'`\" = set"; then
3058   echo $ac_n "(cached) $ac_c" 1>&6
3059 else
3060   if test "$cross_compiling" = yes; then
3061   ac_cv_func_memcmp_clean=no
3062 else
3063   cat > conftest.$ac_ext <<EOF
3064 #line 3065 "configure"
3065 #include "confdefs.h"
3066
3067 main()
3068 {
3069   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
3070   exit(memcmp(&c0, &c2, 1) < 0 && memcmp(&c1, &c2, 1) < 0 ? 0 : 1);
3071 }
3072
3073 EOF
3074 if { (eval echo configure:3075: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3075 then
3076   ac_cv_func_memcmp_clean=yes
3077 else
3078   echo "configure: failed program was:" >&5
3079   cat conftest.$ac_ext >&5
3080   rm -fr conftest*
3081   ac_cv_func_memcmp_clean=no
3082 fi
3083 rm -fr conftest*
3084 fi
3085
3086 fi
3087
3088 echo "$ac_t""$ac_cv_func_memcmp_clean" 1>&6
3089 test $ac_cv_func_memcmp_clean = no && LIBOBJS="$LIBOBJS memcmp.${ac_objext}"
3090
3091 echo $ac_n "checking for vprintf""... $ac_c" 1>&6
3092 echo "configure:3093: checking for vprintf" >&5
3093 if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then
3094   echo $ac_n "(cached) $ac_c" 1>&6
3095 else
3096   cat > conftest.$ac_ext <<EOF
3097 #line 3098 "configure"
3098 #include "confdefs.h"
3099 /* System header to define __stub macros and hopefully few prototypes,
3100     which can conflict with char vprintf(); below.  */
3101 #include <assert.h>
3102 /* Override any gcc2 internal prototype to avoid an error.  */
3103 /* We use char because int might match the return type of a gcc2
3104     builtin and then its argument prototype would still apply.  */
3105 char vprintf();
3106
3107 int main() {
3108
3109 /* The GNU C library defines this for functions which it implements
3110     to always fail with ENOSYS.  Some functions are actually named
3111     something starting with __ and the normal name is an alias.  */
3112 #if defined (__stub_vprintf) || defined (__stub___vprintf)
3113 choke me
3114 #else
3115 vprintf();
3116 #endif
3117
3118 ; return 0; }
3119 EOF
3120 if { (eval echo configure:3121: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3121   rm -rf conftest*
3122   eval "ac_cv_func_vprintf=yes"
3123 else
3124   echo "configure: failed program was:" >&5
3125   cat conftest.$ac_ext >&5
3126   rm -rf conftest*
3127   eval "ac_cv_func_vprintf=no"
3128 fi
3129 rm -f conftest*
3130 fi
3131
3132 if eval "test \"`echo '$ac_cv_func_'vprintf`\" = yes"; then
3133   echo "$ac_t""yes" 1>&6
3134   cat >> confdefs.h <<\EOF
3135 #define HAVE_VPRINTF 1
3136 EOF
3137
3138 else
3139   echo "$ac_t""no" 1>&6
3140 fi
3141
3142 if test "$ac_cv_func_vprintf" != yes; then
3143 echo $ac_n "checking for _doprnt""... $ac_c" 1>&6
3144 echo "configure:3145: checking for _doprnt" >&5
3145 if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then
3146   echo $ac_n "(cached) $ac_c" 1>&6
3147 else
3148   cat > conftest.$ac_ext <<EOF
3149 #line 3150 "configure"
3150 #include "confdefs.h"
3151 /* System header to define __stub macros and hopefully few prototypes,
3152     which can conflict with char _doprnt(); below.  */
3153 #include <assert.h>
3154 /* Override any gcc2 internal prototype to avoid an error.  */
3155 /* We use char because int might match the return type of a gcc2
3156     builtin and then its argument prototype would still apply.  */
3157 char _doprnt();
3158
3159 int main() {
3160
3161 /* The GNU C library defines this for functions which it implements
3162     to always fail with ENOSYS.  Some functions are actually named
3163     something starting with __ and the normal name is an alias.  */
3164 #if defined (__stub__doprnt) || defined (__stub____doprnt)
3165 choke me
3166 #else
3167 _doprnt();
3168 #endif
3169
3170 ; return 0; }
3171 EOF
3172 if { (eval echo configure:3173: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3173   rm -rf conftest*
3174   eval "ac_cv_func__doprnt=yes"
3175 else
3176   echo "configure: failed program was:" >&5
3177   cat conftest.$ac_ext >&5
3178   rm -rf conftest*
3179   eval "ac_cv_func__doprnt=no"
3180 fi
3181 rm -f conftest*
3182 fi
3183
3184 if eval "test \"`echo '$ac_cv_func_'_doprnt`\" = yes"; then
3185   echo "$ac_t""yes" 1>&6
3186   cat >> confdefs.h <<\EOF
3187 #define HAVE_DOPRNT 1
3188 EOF
3189
3190 else
3191   echo "$ac_t""no" 1>&6
3192 fi
3193
3194 fi
3195
3196 for ac_func in gethostname gettimeofday mkdir select strcspn strdup strerror strspn strstr strtol uname
3197 do
3198 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3199 echo "configure:3200: checking for $ac_func" >&5
3200 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3201   echo $ac_n "(cached) $ac_c" 1>&6
3202 else
3203   cat > conftest.$ac_ext <<EOF
3204 #line 3205 "configure"
3205 #include "confdefs.h"
3206 /* System header to define __stub macros and hopefully few prototypes,
3207     which can conflict with char $ac_func(); below.  */
3208 #include <assert.h>
3209 /* Override any gcc2 internal prototype to avoid an error.  */
3210 /* We use char because int might match the return type of a gcc2
3211     builtin and then its argument prototype would still apply.  */
3212 char $ac_func();
3213
3214 int main() {
3215
3216 /* The GNU C library defines this for functions which it implements
3217     to always fail with ENOSYS.  Some functions are actually named
3218     something starting with __ and the normal name is an alias.  */
3219 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3220 choke me
3221 #else
3222 $ac_func();
3223 #endif
3224
3225 ; return 0; }
3226 EOF
3227 if { (eval echo configure:3228: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3228   rm -rf conftest*
3229   eval "ac_cv_func_$ac_func=yes"
3230 else
3231   echo "configure: failed program was:" >&5
3232   cat conftest.$ac_ext >&5
3233   rm -rf conftest*
3234   eval "ac_cv_func_$ac_func=no"
3235 fi
3236 rm -f conftest*
3237 fi
3238
3239 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3240   echo "$ac_t""yes" 1>&6
3241     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3242   cat >> confdefs.h <<EOF
3243 #define $ac_tr_func 1
3244 EOF
3245  
3246 else
3247   echo "$ac_t""no" 1>&6
3248 fi
3249 done
3250
3251
3252 for ac_func in getpwnam_r getgrnam_r
3253 do
3254 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3255 echo "configure:3256: checking for $ac_func" >&5
3256 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3257   echo $ac_n "(cached) $ac_c" 1>&6
3258 else
3259   cat > conftest.$ac_ext <<EOF
3260 #line 3261 "configure"
3261 #include "confdefs.h"
3262 /* System header to define __stub macros and hopefully few prototypes,
3263     which can conflict with char $ac_func(); below.  */
3264 #include <assert.h>
3265 /* Override any gcc2 internal prototype to avoid an error.  */
3266 /* We use char because int might match the return type of a gcc2
3267     builtin and then its argument prototype would still apply.  */
3268 char $ac_func();
3269
3270 int main() {
3271
3272 /* The GNU C library defines this for functions which it implements
3273     to always fail with ENOSYS.  Some functions are actually named
3274     something starting with __ and the normal name is an alias.  */
3275 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3276 choke me
3277 #else
3278 $ac_func();
3279 #endif
3280
3281 ; return 0; }
3282 EOF
3283 if { (eval echo configure:3284: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3284   rm -rf conftest*
3285   eval "ac_cv_func_$ac_func=yes"
3286 else
3287   echo "configure: failed program was:" >&5
3288   cat conftest.$ac_ext >&5
3289   rm -rf conftest*
3290   eval "ac_cv_func_$ac_func=no"
3291 fi
3292 rm -f conftest*
3293 fi
3294
3295 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3296   echo "$ac_t""yes" 1>&6
3297     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3298   cat >> confdefs.h <<EOF
3299 #define $ac_tr_func 1
3300 EOF
3301  
3302 else
3303   echo "$ac_t""no" 1>&6
3304 fi
3305 done
3306
3307
3308 # Extract the first word of "sgml2txt", so it can be a program name with args.
3309 set dummy sgml2txt; ac_word=$2
3310 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3311 echo "configure:3312: checking for $ac_word" >&5
3312 if eval "test \"`echo '$''{'ac_cv_prog_HAVE_SGML2TXT'+set}'`\" = set"; then
3313   echo $ac_n "(cached) $ac_c" 1>&6
3314 else
3315   if test -n "$HAVE_SGML2TXT"; then
3316   ac_cv_prog_HAVE_SGML2TXT="$HAVE_SGML2TXT" # Let the user override the test.
3317 else
3318   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
3319   ac_dummy="$PATH"
3320   for ac_dir in $ac_dummy; do
3321     test -z "$ac_dir" && ac_dir=.
3322     if test -f $ac_dir/$ac_word; then
3323       ac_cv_prog_HAVE_SGML2TXT="yes"
3324       break
3325     fi
3326   done
3327   IFS="$ac_save_ifs"
3328   test -z "$ac_cv_prog_HAVE_SGML2TXT" && ac_cv_prog_HAVE_SGML2TXT="no"
3329 fi
3330 fi
3331 HAVE_SGML2TXT="$ac_cv_prog_HAVE_SGML2TXT"
3332 if test -n "$HAVE_SGML2TXT"; then
3333   echo "$ac_t""$HAVE_SGML2TXT" 1>&6
3334 else
3335   echo "$ac_t""no" 1>&6
3336 fi
3337
3338 # Extract the first word of "sgml2html", so it can be a program name with args.
3339 set dummy sgml2html; ac_word=$2
3340 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3341 echo "configure:3342: checking for $ac_word" >&5
3342 if eval "test \"`echo '$''{'ac_cv_prog_HAVE_SGML2HTML'+set}'`\" = set"; then
3343   echo $ac_n "(cached) $ac_c" 1>&6
3344 else
3345   if test -n "$HAVE_SGML2HTML"; then
3346   ac_cv_prog_HAVE_SGML2HTML="$HAVE_SGML2HTML" # Let the user override the test.
3347 else
3348   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
3349   ac_dummy="$PATH"
3350   for ac_dir in $ac_dummy; do
3351     test -z "$ac_dir" && ac_dir=.
3352     if test -f $ac_dir/$ac_word; then
3353       ac_cv_prog_HAVE_SGML2HTML="yes"
3354       break
3355     fi
3356   done
3357   IFS="$ac_save_ifs"
3358   test -z "$ac_cv_prog_HAVE_SGML2HTML" && ac_cv_prog_HAVE_SGML2HTML="no"
3359 fi
3360 fi
3361 HAVE_SGML2HTML="$ac_cv_prog_HAVE_SGML2HTML"
3362 if test -n "$HAVE_SGML2HTML"; then
3363   echo "$ac_t""$HAVE_SGML2HTML" 1>&6
3364 else
3365   echo "$ac_t""no" 1>&6
3366 fi
3367
3368 # Extract the first word of "sgml2latex", so it can be a program name with args.
3369 set dummy sgml2latex; ac_word=$2
3370 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3371 echo "configure:3372: checking for $ac_word" >&5
3372 if eval "test \"`echo '$''{'ac_cv_prog_HAVE_SGML2LATEX'+set}'`\" = set"; then
3373   echo $ac_n "(cached) $ac_c" 1>&6
3374 else
3375   if test -n "$HAVE_SGML2LATEX"; then
3376   ac_cv_prog_HAVE_SGML2LATEX="$HAVE_SGML2LATEX" # Let the user override the test.
3377 else
3378   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
3379   ac_dummy="$PATH"
3380   for ac_dir in $ac_dummy; do
3381     test -z "$ac_dir" && ac_dir=.
3382     if test -f $ac_dir/$ac_word; then
3383       ac_cv_prog_HAVE_SGML2LATEX="yes"
3384       break
3385     fi
3386   done
3387   IFS="$ac_save_ifs"
3388   test -z "$ac_cv_prog_HAVE_SGML2LATEX" && ac_cv_prog_HAVE_SGML2LATEX="no"
3389 fi
3390 fi
3391 HAVE_SGML2LATEX="$ac_cv_prog_HAVE_SGML2LATEX"
3392 if test -n "$HAVE_SGML2LATEX"; then
3393   echo "$ac_t""$HAVE_SGML2LATEX" 1>&6
3394 else
3395   echo "$ac_t""no" 1>&6
3396 fi
3397
3398 if test $HAVE_SGML2LATEX = "yes" ; then
3399   if sgml2latex -h | grep -e --paper | grep  ' -p ' > /dev/null ; then
3400     PSER="sgml2latex -o ps"
3401   else
3402     PSER="sgml2latex -p"
3403   fi
3404   # Extract the first word of "ps2pdf", so it can be a program name with args.
3405 set dummy ps2pdf; ac_word=$2
3406 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3407 echo "configure:3408: checking for $ac_word" >&5
3408 if eval "test \"`echo '$''{'ac_cv_prog_HAVE_PS2PDF'+set}'`\" = set"; then
3409   echo $ac_n "(cached) $ac_c" 1>&6
3410 else
3411   if test -n "$HAVE_PS2PDF"; then
3412   ac_cv_prog_HAVE_PS2PDF="$HAVE_PS2PDF" # Let the user override the test.
3413 else
3414   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
3415   ac_dummy="$PATH"
3416   for ac_dir in $ac_dummy; do
3417     test -z "$ac_dir" && ac_dir=.
3418     if test -f $ac_dir/$ac_word; then
3419       ac_cv_prog_HAVE_PS2PDF="yes"
3420       break
3421     fi
3422   done
3423   IFS="$ac_save_ifs"
3424   test -z "$ac_cv_prog_HAVE_PS2PDF" && ac_cv_prog_HAVE_PS2PDF="no"
3425 fi
3426 fi
3427 HAVE_PS2PDF="$ac_cv_prog_HAVE_PS2PDF"
3428 if test -n "$HAVE_PS2PDF"; then
3429   echo "$ac_t""$HAVE_PS2PDF" 1>&6
3430 else
3431   echo "$ac_t""no" 1>&6
3432 fi
3433
3434 else
3435   # Extract the first word of "sgml2ps", so it can be a program name with args.
3436 set dummy sgml2ps; ac_word=$2
3437 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3438 echo "configure:3439: checking for $ac_word" >&5
3439 if eval "test \"`echo '$''{'ac_cv_prog_HAVE_SGML2PS'+set}'`\" = set"; then
3440   echo $ac_n "(cached) $ac_c" 1>&6
3441 else
3442   if test -n "$HAVE_SGML2PS"; then
3443   ac_cv_prog_HAVE_SGML2PS="$HAVE_SGML2PS" # Let the user override the test.
3444 else
3445   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
3446   ac_dummy="$PATH"
3447   for ac_dir in $ac_dummy; do
3448     test -z "$ac_dir" && ac_dir=.
3449     if test -f $ac_dir/$ac_word; then
3450       ac_cv_prog_HAVE_SGML2PS="yes"
3451       break
3452     fi
3453   done
3454   IFS="$ac_save_ifs"
3455   test -z "$ac_cv_prog_HAVE_SGML2PS" && ac_cv_prog_HAVE_SGML2PS="no"
3456 fi
3457 fi
3458 HAVE_SGML2PS="$ac_cv_prog_HAVE_SGML2PS"
3459 if test -n "$HAVE_SGML2PS"; then
3460   echo "$ac_t""$HAVE_SGML2PS" 1>&6
3461 else
3462   echo "$ac_t""no" 1>&6
3463 fi
3464
3465   if test $HAVE_SGML2PS = yes ; then
3466     PSER="sgml2ps"
3467   fi
3468 fi
3469
3470
3471
3472 trap '' 1 2 15
3473 cat > confcache <<\EOF
3474 # This file is a shell script that caches the results of configure
3475 # tests run on this system so they can be shared between configure
3476 # scripts and configure runs.  It is not useful on other systems.
3477 # If it contains results you don't want to keep, you may remove or edit it.
3478 #
3479 # By default, configure uses ./config.cache as the cache file,
3480 # creating it if it does not exist already.  You can give configure
3481 # the --cache-file=FILE option to use a different cache file; that is
3482 # what configure does when it calls configure scripts in
3483 # subdirectories, so they share the cache.
3484 # Giving --cache-file=/dev/null disables caching, for debugging configure.
3485 # config.status only pays attention to the cache file if you give it the
3486 # --recheck option to rerun configure.
3487 #
3488 EOF
3489 # The following way of writing the cache mishandles newlines in values,
3490 # but we know of no workaround that is simple, portable, and efficient.
3491 # So, don't put newlines in cache variables' values.
3492 # Ultrix sh set writes to stderr and can't be redirected directly,
3493 # and sets the high bit in the cache file unless we assign to the vars.
3494 (set) 2>&1 |
3495   case `(ac_space=' '; set | grep ac_space) 2>&1` in
3496   *ac_space=\ *)
3497     # `set' does not quote correctly, so add quotes (double-quote substitution
3498     # turns \\\\ into \\, and sed turns \\ into \).
3499     sed -n \
3500       -e "s/'/'\\\\''/g" \
3501       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
3502     ;;
3503   *)
3504     # `set' quotes correctly as required by POSIX, so do not add quotes.
3505     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
3506     ;;
3507   esac >> confcache
3508 if cmp -s $cache_file confcache; then
3509   :
3510 else
3511   if test -w $cache_file; then
3512     echo "updating cache $cache_file"
3513     cat confcache > $cache_file
3514   else
3515     echo "not updating unwritable cache $cache_file"
3516   fi
3517 fi
3518 rm -f confcache
3519
3520 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
3521
3522 test "x$prefix" = xNONE && prefix=$ac_default_prefix
3523 # Let make expand exec_prefix.
3524 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
3525
3526 # Any assignment to VPATH causes Sun make to only execute
3527 # the first set of double-colon rules, so remove it if not needed.
3528 # If there is a colon in the path, we need to keep it.
3529 if test "x$srcdir" = x.; then
3530   ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
3531 fi
3532
3533 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
3534
3535 DEFS=-DHAVE_CONFIG_H
3536
3537 # Without the "./", some shells look in PATH for config.status.
3538 : ${CONFIG_STATUS=./config.status}
3539
3540 echo creating $CONFIG_STATUS
3541 rm -f $CONFIG_STATUS
3542 cat > $CONFIG_STATUS <<EOF
3543 #! /bin/sh
3544 # Generated automatically by configure.
3545 # Run this file to recreate the current configuration.
3546 # This directory was configured as follows,
3547 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3548 #
3549 # $0 $ac_configure_args
3550 #
3551 # Compiler output produced by configure, useful for debugging
3552 # configure, is in ./config.log if it exists.
3553
3554 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
3555 for ac_option
3556 do
3557   case "\$ac_option" in
3558   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
3559     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
3560     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
3561   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
3562     echo "$CONFIG_STATUS generated by autoconf version 2.13"
3563     exit 0 ;;
3564   -help | --help | --hel | --he | --h)
3565     echo "\$ac_cs_usage"; exit 0 ;;
3566   *) echo "\$ac_cs_usage"; exit 1 ;;
3567   esac
3568 done
3569
3570 ac_given_srcdir=$srcdir
3571
3572 trap 'rm -fr `echo "Make.Rules _pam_aconf.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
3573 EOF
3574 cat >> $CONFIG_STATUS <<EOF
3575
3576 # Protect against being on the right side of a sed subst in config.status.
3577 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
3578  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
3579 $ac_vpsub
3580 $extrasub
3581 s%@SHELL@%$SHELL%g
3582 s%@CFLAGS@%$CFLAGS%g
3583 s%@CPPFLAGS@%$CPPFLAGS%g
3584 s%@CXXFLAGS@%$CXXFLAGS%g
3585 s%@FFLAGS@%$FFLAGS%g
3586 s%@DEFS@%$DEFS%g
3587 s%@LDFLAGS@%$LDFLAGS%g
3588 s%@LIBS@%$LIBS%g
3589 s%@exec_prefix@%$exec_prefix%g
3590 s%@prefix@%$prefix%g
3591 s%@program_transform_name@%$program_transform_name%g
3592 s%@bindir@%$bindir%g
3593 s%@sbindir@%$sbindir%g
3594 s%@libexecdir@%$libexecdir%g
3595 s%@datadir@%$datadir%g
3596 s%@sysconfdir@%$sysconfdir%g
3597 s%@sharedstatedir@%$sharedstatedir%g
3598 s%@localstatedir@%$localstatedir%g
3599 s%@libdir@%$libdir%g
3600 s%@includedir@%$includedir%g
3601 s%@oldincludedir@%$oldincludedir%g
3602 s%@infodir@%$infodir%g
3603 s%@mandir@%$mandir%g
3604 s%@LIBPAM_VERSION_MAJOR@%$LIBPAM_VERSION_MAJOR%g
3605 s%@LIBPAM_VERSION_MINOR@%$LIBPAM_VERSION_MINOR%g
3606 s%@LOCALSRCDIR@%$LOCALSRCDIR%g
3607 s%@LOCALOBJDIR@%$LOCALOBJDIR%g
3608 s%@OS@%$OS%g
3609 s%@CONF_CFLAGS@%$CONF_CFLAGS%g
3610 s%@MKDIR@%$MKDIR%g
3611 s%@SHLIBMODE@%$SHLIBMODE%g
3612 s%@USESONAME@%$USESONAME%g
3613 s%@SOSWITCH@%$SOSWITCH%g
3614 s%@NEEDSONAME@%$NEEDSONAME%g
3615 s%@LDCONFIG@%$LDCONFIG%g
3616 s%@INSTALL@%$INSTALL%g
3617 s%@CC@%$CC%g
3618 s%@YACC@%$YACC%g
3619 s%@LEX@%$LEX%g
3620 s%@LEXLIB@%$LEXLIB%g
3621 s%@LN_S@%$LN_S%g
3622 s%@SET_MAKE@%$SET_MAKE%g
3623 s%@WITH_DEBUG@%$WITH_DEBUG%g
3624 s%@WITH_MEMORY_DEBUG@%$WITH_MEMORY_DEBUG%g
3625 s%@WITH_LIBDEBUG@%$WITH_LIBDEBUG%g
3626 s%@FAKEROOT@%$FAKEROOT%g
3627 s%@SECUREDIR@%$SECUREDIR%g
3628 s%@SCONFIGDIR@%$SCONFIGDIR%g
3629 s%@SUPLEMENTED@%$SUPLEMENTED%g
3630 s%@INCLUDEDIR@%$INCLUDEDIR%g
3631 s%@DOCDIR@%$DOCDIR%g
3632 s%@MANDIR@%$MANDIR%g
3633 s%@WITH_PAMLOCKING@%$WITH_PAMLOCKING%g
3634 s%@PAM_READ_BOTH_CONFS@%$PAM_READ_BOTH_CONFS%g
3635 s%@STATIC_LIBPAM@%$STATIC_LIBPAM%g
3636 s%@DYNAMIC_LIBPAM@%$DYNAMIC_LIBPAM%g
3637 s%@DYNAMIC@%$DYNAMIC%g
3638 s%@STATIC@%$STATIC%g
3639 s%@WITH_LCKPWDF@%$WITH_LCKPWDF%g
3640 s%@CPP@%$CPP%g
3641 s%@PAM_NEEDS_LIBC@%$PAM_NEEDS_LIBC%g
3642 s%@HAVE_LCKPWDF@%$HAVE_LCKPWDF%g
3643 s%@LIBDL@%$LIBDL%g
3644 s%@HAVE_LIBCRACK@%$HAVE_LIBCRACK%g
3645 s%@HAVE_LIBCRYPT@%$HAVE_LIBCRYPT%g
3646 s%@HAVE_LIBUTIL@%$HAVE_LIBUTIL%g
3647 s%@HAVE_LIBNDBM@%$HAVE_LIBNDBM%g
3648 s%@HAVE_LIBDB@%$HAVE_LIBDB%g
3649 s%@HAVE_LIBFL@%$HAVE_LIBFL%g
3650 s%@HAVE_LIBNSL@%$HAVE_LIBNSL%g
3651 s%@HAVE_LIBPWDB@%$HAVE_LIBPWDB%g
3652 s%@HAVE_LIBFLEX@%$HAVE_LIBFLEX%g
3653 s%@HAVE_LIBLEX@%$HAVE_LIBLEX%g
3654 s%@HAVE_NDBM_H@%$HAVE_NDBM_H%g
3655 s%@CRACKLIB_DICTPATH@%$CRACKLIB_DICTPATH%g
3656 s%@DYNTYPE@%$DYNTYPE%g
3657 s%@OS_CFLAGS@%$OS_CFLAGS%g
3658 s%@WARNINGS@%$WARNINGS%g
3659 s%@PIC@%$PIC%g
3660 s%@LD@%$LD%g
3661 s%@LD_D@%$LD_D%g
3662 s%@LD_L@%$LD_L%g
3663 s%@RANLIB@%$RANLIB%g
3664 s%@STRIP@%$STRIP%g
3665 s%@CC_STATIC@%$CC_STATIC%g
3666 s%@LIBOBJS@%$LIBOBJS%g
3667 s%@HAVE_SGML2TXT@%$HAVE_SGML2TXT%g
3668 s%@HAVE_SGML2HTML@%$HAVE_SGML2HTML%g
3669 s%@HAVE_SGML2LATEX@%$HAVE_SGML2LATEX%g
3670 s%@HAVE_PS2PDF@%$HAVE_PS2PDF%g
3671 s%@HAVE_SGML2PS@%$HAVE_SGML2PS%g
3672 s%@PSER@%$PSER%g
3673 s%@PS2PDF@%$PS2PDF%g
3674
3675 CEOF
3676 EOF
3677
3678 cat >> $CONFIG_STATUS <<\EOF
3679
3680 # Split the substitutions into bite-sized pieces for seds with
3681 # small command number limits, like on Digital OSF/1 and HP-UX.
3682 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
3683 ac_file=1 # Number of current file.
3684 ac_beg=1 # First line for current file.
3685 ac_end=$ac_max_sed_cmds # Line after last line for current file.
3686 ac_more_lines=:
3687 ac_sed_cmds=""
3688 while $ac_more_lines; do
3689   if test $ac_beg -gt 1; then
3690     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
3691   else
3692     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
3693   fi
3694   if test ! -s conftest.s$ac_file; then
3695     ac_more_lines=false
3696     rm -f conftest.s$ac_file
3697   else
3698     if test -z "$ac_sed_cmds"; then
3699       ac_sed_cmds="sed -f conftest.s$ac_file"
3700     else
3701       ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
3702     fi
3703     ac_file=`expr $ac_file + 1`
3704     ac_beg=$ac_end
3705     ac_end=`expr $ac_end + $ac_max_sed_cmds`
3706   fi
3707 done
3708 if test -z "$ac_sed_cmds"; then
3709   ac_sed_cmds=cat
3710 fi
3711 EOF
3712
3713 cat >> $CONFIG_STATUS <<EOF
3714
3715 CONFIG_FILES=\${CONFIG_FILES-"Make.Rules"}
3716 EOF
3717 cat >> $CONFIG_STATUS <<\EOF
3718 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
3719   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3720   case "$ac_file" in
3721   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3722        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3723   *) ac_file_in="${ac_file}.in" ;;
3724   esac
3725
3726   # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
3727
3728   # Remove last slash and all that follows it.  Not all systems have dirname.
3729   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3730   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3731     # The file is in a subdirectory.
3732     test ! -d "$ac_dir" && mkdir "$ac_dir"
3733     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
3734     # A "../" for each directory in $ac_dir_suffix.
3735     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
3736   else
3737     ac_dir_suffix= ac_dots=
3738   fi
3739
3740   case "$ac_given_srcdir" in
3741   .)  srcdir=.
3742       if test -z "$ac_dots"; then top_srcdir=.
3743       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
3744   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
3745   *) # Relative path.
3746     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
3747     top_srcdir="$ac_dots$ac_given_srcdir" ;;
3748   esac
3749
3750
3751   echo creating "$ac_file"
3752   rm -f "$ac_file"
3753   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
3754   case "$ac_file" in
3755   *Makefile*) ac_comsub="1i\\
3756 # $configure_input" ;;
3757   *) ac_comsub= ;;
3758   esac
3759
3760   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3761   sed -e "$ac_comsub
3762 s%@configure_input@%$configure_input%g
3763 s%@srcdir@%$srcdir%g
3764 s%@top_srcdir@%$top_srcdir%g
3765 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
3766 fi; done
3767 rm -f conftest.s*
3768
3769 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
3770 # NAME is the cpp macro being defined and VALUE is the value it is being given.
3771 #
3772 # ac_d sets the value in "#define NAME VALUE" lines.
3773 ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
3774 ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
3775 ac_dC='\3'
3776 ac_dD='%g'
3777 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
3778 ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
3779 ac_uB='\([      ]\)%\1#\2define\3'
3780 ac_uC=' '
3781 ac_uD='\4%g'
3782 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
3783 ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
3784 ac_eB='$%\1#\2define\3'
3785 ac_eC=' '
3786 ac_eD='%g'
3787
3788 if test "${CONFIG_HEADERS+set}" != set; then
3789 EOF
3790 cat >> $CONFIG_STATUS <<EOF
3791   CONFIG_HEADERS="_pam_aconf.h"
3792 EOF
3793 cat >> $CONFIG_STATUS <<\EOF
3794 fi
3795 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
3796   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3797   case "$ac_file" in
3798   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3799        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3800   *) ac_file_in="${ac_file}.in" ;;
3801   esac
3802
3803   echo creating $ac_file
3804
3805   rm -f conftest.frag conftest.in conftest.out
3806   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
3807   cat $ac_file_inputs > conftest.in
3808
3809 EOF
3810
3811 # Transform confdefs.h into a sed script conftest.vals that substitutes
3812 # the proper values into config.h.in to produce config.h.  And first:
3813 # Protect against being on the right side of a sed subst in config.status.
3814 # Protect against being in an unquoted here document in config.status.
3815 rm -f conftest.vals
3816 cat > conftest.hdr <<\EOF
3817 s/[\\&%]/\\&/g
3818 s%[\\$`]%\\&%g
3819 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
3820 s%ac_d%ac_u%gp
3821 s%ac_u%ac_e%gp
3822 EOF
3823 sed -n -f conftest.hdr confdefs.h > conftest.vals
3824 rm -f conftest.hdr
3825
3826 # This sed command replaces #undef with comments.  This is necessary, for
3827 # example, in the case of _POSIX_SOURCE, which is predefined and required
3828 # on some systems where configure will not decide to define it.
3829 cat >> conftest.vals <<\EOF
3830 s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
3831 EOF
3832
3833 # Break up conftest.vals because some shells have a limit on
3834 # the size of here documents, and old seds have small limits too.
3835
3836 rm -f conftest.tail
3837 while :
3838 do
3839   ac_lines=`grep -c . conftest.vals`
3840   # grep -c gives empty output for an empty file on some AIX systems.
3841   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
3842   # Write a limited-size here document to conftest.frag.
3843   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
3844   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
3845   echo 'CEOF
3846   sed -f conftest.frag conftest.in > conftest.out
3847   rm -f conftest.in
3848   mv conftest.out conftest.in
3849 ' >> $CONFIG_STATUS
3850   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
3851   rm -f conftest.vals
3852   mv conftest.tail conftest.vals
3853 done
3854 rm -f conftest.vals
3855
3856 cat >> $CONFIG_STATUS <<\EOF
3857   rm -f conftest.frag conftest.h
3858   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
3859   cat conftest.in >> conftest.h
3860   rm -f conftest.in
3861   if cmp -s $ac_file conftest.h 2>/dev/null; then
3862     echo "$ac_file is unchanged"
3863     rm -f conftest.h
3864   else
3865     # Remove last slash and all that follows it.  Not all systems have dirname.
3866       ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3867       if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3868       # The file is in a subdirectory.
3869       test ! -d "$ac_dir" && mkdir "$ac_dir"
3870     fi
3871     rm -f $ac_file
3872     mv conftest.h $ac_file
3873   fi
3874 fi; done
3875
3876 EOF
3877 cat >> $CONFIG_STATUS <<EOF
3878
3879 EOF
3880 cat >> $CONFIG_STATUS <<\EOF
3881
3882 exit 0
3883 EOF
3884 chmod +x $CONFIG_STATUS
3885 rm -fr confdefs* $ac_clean_files
3886 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
3887