]> granicus.if.org Git - shadow/blob - configure
[svn-upgrade] Integrating new upstream version, shadow (20000826)
[shadow] / 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_help="$ac_help
15   --enable-shared[=PKGS]  build shared libraries [default=yes]"
16 ac_help="$ac_help
17   --enable-static[=PKGS]  build static libraries [default=yes]"
18 ac_help="$ac_help
19   --enable-fast-install[=PKGS]  optimize for fast installation [default=yes]"
20 ac_help="$ac_help
21   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]"
22 ac_help="$ac_help
23   --disable-libtool-lock  avoid locking (might break parallel builds)"
24 ac_help="$ac_help
25   --enable-desrpc         try to use secure RPC in login (default if found)"
26 ac_help="$ac_help
27   --enable-shadowgrp      enable shadow group support [default=yes]"
28 ac_help="$ac_help
29   --with-libcrack         try to use libcrack (default if found)"
30 ac_help="$ac_help
31   --with-libcrypt         try to use libcrypt (default if found)"
32 ac_help="$ac_help
33   --with-libopie          use libopie for OPIE support"
34 ac_help="$ac_help
35   --with-libpam           use libpam for PAM support"
36 ac_help="$ac_help
37   --with-libskey          use libskey for S/Key support"
38 ac_help="$ac_help
39   --with-libtcfs          use libtcfs for TCFS support"
40 ac_help="$ac_help
41   --disable-nls           do not use Native Language Support"
42 ac_help="$ac_help
43   --with-included-gettext use the GNU gettext library included here"
44 ac_help="$ac_help
45   --with-catgets          use catgets functions if available"
46
47 # Initialize some variables set by options.
48 # The variables have the same names as the options, with
49 # dashes changed to underlines.
50 build=NONE
51 cache_file=./config.cache
52 exec_prefix=NONE
53 host=NONE
54 no_create=
55 nonopt=NONE
56 no_recursion=
57 prefix=NONE
58 program_prefix=NONE
59 program_suffix=NONE
60 program_transform_name=s,x,x,
61 silent=
62 site=
63 srcdir=
64 target=NONE
65 verbose=
66 x_includes=NONE
67 x_libraries=NONE
68 bindir='${exec_prefix}/bin'
69 sbindir='${exec_prefix}/sbin'
70 libexecdir='${exec_prefix}/libexec'
71 datadir='${prefix}/share'
72 sysconfdir='${prefix}/etc'
73 sharedstatedir='${prefix}/com'
74 localstatedir='${prefix}/var'
75 libdir='${exec_prefix}/lib'
76 includedir='${prefix}/include'
77 oldincludedir='/usr/include'
78 infodir='${prefix}/info'
79 mandir='${prefix}/man'
80
81 # Initialize some other variables.
82 subdirs=
83 MFLAGS= MAKEFLAGS=
84 SHELL=${CONFIG_SHELL-/bin/sh}
85 # Maximum number of lines to put in a shell here document.
86 ac_max_here_lines=12
87
88 ac_prev=
89 for ac_option
90 do
91
92   # If the previous option needs an argument, assign it.
93   if test -n "$ac_prev"; then
94     eval "$ac_prev=\$ac_option"
95     ac_prev=
96     continue
97   fi
98
99   case "$ac_option" in
100   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
101   *) ac_optarg= ;;
102   esac
103
104   # Accept the important Cygnus configure options, so we can diagnose typos.
105
106   case "$ac_option" in
107
108   -bindir | --bindir | --bindi | --bind | --bin | --bi)
109     ac_prev=bindir ;;
110   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
111     bindir="$ac_optarg" ;;
112
113   -build | --build | --buil | --bui | --bu)
114     ac_prev=build ;;
115   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
116     build="$ac_optarg" ;;
117
118   -cache-file | --cache-file | --cache-fil | --cache-fi \
119   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
120     ac_prev=cache_file ;;
121   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
122   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
123     cache_file="$ac_optarg" ;;
124
125   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
126     ac_prev=datadir ;;
127   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
128   | --da=*)
129     datadir="$ac_optarg" ;;
130
131   -disable-* | --disable-*)
132     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
133     # Reject names that are not valid shell variable names.
134     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
135       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
136     fi
137     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
138     eval "enable_${ac_feature}=no" ;;
139
140   -enable-* | --enable-*)
141     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
142     # Reject names that are not valid shell variable names.
143     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
144       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
145     fi
146     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
147     case "$ac_option" in
148       *=*) ;;
149       *) ac_optarg=yes ;;
150     esac
151     eval "enable_${ac_feature}='$ac_optarg'" ;;
152
153   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
154   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
155   | --exec | --exe | --ex)
156     ac_prev=exec_prefix ;;
157   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
158   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
159   | --exec=* | --exe=* | --ex=*)
160     exec_prefix="$ac_optarg" ;;
161
162   -gas | --gas | --ga | --g)
163     # Obsolete; use --with-gas.
164     with_gas=yes ;;
165
166   -help | --help | --hel | --he)
167     # Omit some internal or obsolete options to make the list less imposing.
168     # This message is too long to be a string in the A/UX 3.1 sh.
169     cat << EOF
170 Usage: configure [options] [host]
171 Options: [defaults in brackets after descriptions]
172 Configuration:
173   --cache-file=FILE       cache test results in FILE
174   --help                  print this message
175   --no-create             do not create output files
176   --quiet, --silent       do not print \`checking...' messages
177   --version               print the version of autoconf that created configure
178 Directory and file names:
179   --prefix=PREFIX         install architecture-independent files in PREFIX
180                           [$ac_default_prefix]
181   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
182                           [same as prefix]
183   --bindir=DIR            user executables in DIR [EPREFIX/bin]
184   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
185   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
186   --datadir=DIR           read-only architecture-independent data in DIR
187                           [PREFIX/share]
188   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
189   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
190                           [PREFIX/com]
191   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
192   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
193   --includedir=DIR        C header files in DIR [PREFIX/include]
194   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
195   --infodir=DIR           info documentation in DIR [PREFIX/info]
196   --mandir=DIR            man documentation in DIR [PREFIX/man]
197   --srcdir=DIR            find the sources in DIR [configure dir or ..]
198   --program-prefix=PREFIX prepend PREFIX to installed program names
199   --program-suffix=SUFFIX append SUFFIX to installed program names
200   --program-transform-name=PROGRAM
201                           run sed PROGRAM on installed program names
202 EOF
203     cat << EOF
204 Host type:
205   --build=BUILD           configure for building on BUILD [BUILD=HOST]
206   --host=HOST             configure for HOST [guessed]
207   --target=TARGET         configure for TARGET [TARGET=HOST]
208 Features and packages:
209   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
210   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
211   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
212   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
213   --x-includes=DIR        X include files are in DIR
214   --x-libraries=DIR       X library files are in DIR
215 EOF
216     if test -n "$ac_help"; then
217       echo "--enable and --with options recognized:$ac_help"
218     fi
219     exit 0 ;;
220
221   -host | --host | --hos | --ho)
222     ac_prev=host ;;
223   -host=* | --host=* | --hos=* | --ho=*)
224     host="$ac_optarg" ;;
225
226   -includedir | --includedir | --includedi | --included | --include \
227   | --includ | --inclu | --incl | --inc)
228     ac_prev=includedir ;;
229   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
230   | --includ=* | --inclu=* | --incl=* | --inc=*)
231     includedir="$ac_optarg" ;;
232
233   -infodir | --infodir | --infodi | --infod | --info | --inf)
234     ac_prev=infodir ;;
235   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
236     infodir="$ac_optarg" ;;
237
238   -libdir | --libdir | --libdi | --libd)
239     ac_prev=libdir ;;
240   -libdir=* | --libdir=* | --libdi=* | --libd=*)
241     libdir="$ac_optarg" ;;
242
243   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
244   | --libexe | --libex | --libe)
245     ac_prev=libexecdir ;;
246   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
247   | --libexe=* | --libex=* | --libe=*)
248     libexecdir="$ac_optarg" ;;
249
250   -localstatedir | --localstatedir | --localstatedi | --localstated \
251   | --localstate | --localstat | --localsta | --localst \
252   | --locals | --local | --loca | --loc | --lo)
253     ac_prev=localstatedir ;;
254   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
255   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
256   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
257     localstatedir="$ac_optarg" ;;
258
259   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
260     ac_prev=mandir ;;
261   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
262     mandir="$ac_optarg" ;;
263
264   -nfp | --nfp | --nf)
265     # Obsolete; use --without-fp.
266     with_fp=no ;;
267
268   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
269   | --no-cr | --no-c)
270     no_create=yes ;;
271
272   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
273   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
274     no_recursion=yes ;;
275
276   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
277   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
278   | --oldin | --oldi | --old | --ol | --o)
279     ac_prev=oldincludedir ;;
280   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
281   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
282   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
283     oldincludedir="$ac_optarg" ;;
284
285   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
286     ac_prev=prefix ;;
287   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
288     prefix="$ac_optarg" ;;
289
290   -program-prefix | --program-prefix | --program-prefi | --program-pref \
291   | --program-pre | --program-pr | --program-p)
292     ac_prev=program_prefix ;;
293   -program-prefix=* | --program-prefix=* | --program-prefi=* \
294   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
295     program_prefix="$ac_optarg" ;;
296
297   -program-suffix | --program-suffix | --program-suffi | --program-suff \
298   | --program-suf | --program-su | --program-s)
299     ac_prev=program_suffix ;;
300   -program-suffix=* | --program-suffix=* | --program-suffi=* \
301   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
302     program_suffix="$ac_optarg" ;;
303
304   -program-transform-name | --program-transform-name \
305   | --program-transform-nam | --program-transform-na \
306   | --program-transform-n | --program-transform- \
307   | --program-transform | --program-transfor \
308   | --program-transfo | --program-transf \
309   | --program-trans | --program-tran \
310   | --progr-tra | --program-tr | --program-t)
311     ac_prev=program_transform_name ;;
312   -program-transform-name=* | --program-transform-name=* \
313   | --program-transform-nam=* | --program-transform-na=* \
314   | --program-transform-n=* | --program-transform-=* \
315   | --program-transform=* | --program-transfor=* \
316   | --program-transfo=* | --program-transf=* \
317   | --program-trans=* | --program-tran=* \
318   | --progr-tra=* | --program-tr=* | --program-t=*)
319     program_transform_name="$ac_optarg" ;;
320
321   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
322   | -silent | --silent | --silen | --sile | --sil)
323     silent=yes ;;
324
325   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
326     ac_prev=sbindir ;;
327   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
328   | --sbi=* | --sb=*)
329     sbindir="$ac_optarg" ;;
330
331   -sharedstatedir | --sharedstatedir | --sharedstatedi \
332   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
333   | --sharedst | --shareds | --shared | --share | --shar \
334   | --sha | --sh)
335     ac_prev=sharedstatedir ;;
336   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
337   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
338   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
339   | --sha=* | --sh=*)
340     sharedstatedir="$ac_optarg" ;;
341
342   -site | --site | --sit)
343     ac_prev=site ;;
344   -site=* | --site=* | --sit=*)
345     site="$ac_optarg" ;;
346
347   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
348     ac_prev=srcdir ;;
349   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
350     srcdir="$ac_optarg" ;;
351
352   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
353   | --syscon | --sysco | --sysc | --sys | --sy)
354     ac_prev=sysconfdir ;;
355   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
356   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
357     sysconfdir="$ac_optarg" ;;
358
359   -target | --target | --targe | --targ | --tar | --ta | --t)
360     ac_prev=target ;;
361   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
362     target="$ac_optarg" ;;
363
364   -v | -verbose | --verbose | --verbos | --verbo | --verb)
365     verbose=yes ;;
366
367   -version | --version | --versio | --versi | --vers)
368     echo "configure generated by autoconf version 2.13"
369     exit 0 ;;
370
371   -with-* | --with-*)
372     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
373     # Reject names that are not valid shell variable names.
374     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
375       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
376     fi
377     ac_package=`echo $ac_package| sed 's/-/_/g'`
378     case "$ac_option" in
379       *=*) ;;
380       *) ac_optarg=yes ;;
381     esac
382     eval "with_${ac_package}='$ac_optarg'" ;;
383
384   -without-* | --without-*)
385     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
386     # Reject names that are not valid shell variable names.
387     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
388       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
389     fi
390     ac_package=`echo $ac_package| sed 's/-/_/g'`
391     eval "with_${ac_package}=no" ;;
392
393   --x)
394     # Obsolete; use --with-x.
395     with_x=yes ;;
396
397   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
398   | --x-incl | --x-inc | --x-in | --x-i)
399     ac_prev=x_includes ;;
400   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
401   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
402     x_includes="$ac_optarg" ;;
403
404   -x-libraries | --x-libraries | --x-librarie | --x-librari \
405   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
406     ac_prev=x_libraries ;;
407   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
408   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
409     x_libraries="$ac_optarg" ;;
410
411   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
412     ;;
413
414   *)
415     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
416       echo "configure: warning: $ac_option: invalid host type" 1>&2
417     fi
418     if test "x$nonopt" != xNONE; then
419       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
420     fi
421     nonopt="$ac_option"
422     ;;
423
424   esac
425 done
426
427 if test -n "$ac_prev"; then
428   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
429 fi
430
431 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
432
433 # File descriptor usage:
434 # 0 standard input
435 # 1 file creation
436 # 2 errors and warnings
437 # 3 some systems may open it to /dev/tty
438 # 4 used on the Kubota Titan
439 # 6 checking for... messages and results
440 # 5 compiler messages saved in config.log
441 if test "$silent" = yes; then
442   exec 6>/dev/null
443 else
444   exec 6>&1
445 fi
446 exec 5>./config.log
447
448 echo "\
449 This file contains any messages produced by compilers while
450 running configure, to aid debugging if configure makes a mistake.
451 " 1>&5
452
453 # Strip out --no-create and --no-recursion so they do not pile up.
454 # Also quote any args containing shell metacharacters.
455 ac_configure_args=
456 for ac_arg
457 do
458   case "$ac_arg" in
459   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
460   | --no-cr | --no-c) ;;
461   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
462   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
463   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
464   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
465   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
466   esac
467 done
468
469 # NLS nuisances.
470 # Only set these to C if already set.  These must not be set unconditionally
471 # because not all systems understand e.g. LANG=C (notably SCO).
472 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
473 # Non-C LC_CTYPE values break the ctype check.
474 if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
475 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
476 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
477 if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
478
479 # confdefs.h avoids OS command line length limits that DEFS can exceed.
480 rm -rf conftest* confdefs.h
481 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
482 echo > confdefs.h
483
484 # A filename unique to this package, relative to the directory that
485 # configure is in, which we can look for to find out if srcdir is correct.
486 ac_unique_file=lib/dialchk.c
487
488 # Find the source files, if location was not specified.
489 if test -z "$srcdir"; then
490   ac_srcdir_defaulted=yes
491   # Try the directory containing this script, then its parent.
492   ac_prog=$0
493   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
494   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
495   srcdir=$ac_confdir
496   if test ! -r $srcdir/$ac_unique_file; then
497     srcdir=..
498   fi
499 else
500   ac_srcdir_defaulted=no
501 fi
502 if test ! -r $srcdir/$ac_unique_file; then
503   if test "$ac_srcdir_defaulted" = yes; then
504     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
505   else
506     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
507   fi
508 fi
509 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
510
511 # Prefer explicitly selected file to automatically selected ones.
512 if test -z "$CONFIG_SITE"; then
513   if test "x$prefix" != xNONE; then
514     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
515   else
516     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
517   fi
518 fi
519 for ac_site_file in $CONFIG_SITE; do
520   if test -r "$ac_site_file"; then
521     echo "loading site script $ac_site_file"
522     . "$ac_site_file"
523   fi
524 done
525
526 if test -r "$cache_file"; then
527   echo "loading cache $cache_file"
528   . $cache_file
529 else
530   echo "creating cache $cache_file"
531   > $cache_file
532 fi
533
534 ac_ext=c
535 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
536 ac_cpp='$CPP $CPPFLAGS'
537 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
538 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
539 cross_compiling=$ac_cv_prog_cc_cross
540
541 ac_exeext=
542 ac_objext=o
543 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
544   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
545   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
546     ac_n= ac_c='
547 ' ac_t='        '
548   else
549     ac_n=-n ac_c= ac_t=
550   fi
551 else
552   ac_n= ac_c='\c' ac_t=
553 fi
554
555
556 ac_aux_dir=
557 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
558   if test -f $ac_dir/install-sh; then
559     ac_aux_dir=$ac_dir
560     ac_install_sh="$ac_aux_dir/install-sh -c"
561     break
562   elif test -f $ac_dir/install.sh; then
563     ac_aux_dir=$ac_dir
564     ac_install_sh="$ac_aux_dir/install.sh -c"
565     break
566   fi
567 done
568 if test -z "$ac_aux_dir"; then
569   { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
570 fi
571 ac_config_guess=$ac_aux_dir/config.guess
572 ac_config_sub=$ac_aux_dir/config.sub
573 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
574
575 # Find a good install program.  We prefer a C program (faster),
576 # so one script is as good as another.  But avoid the broken or
577 # incompatible versions:
578 # SysV /etc/install, /usr/sbin/install
579 # SunOS /usr/etc/install
580 # IRIX /sbin/install
581 # AIX /bin/install
582 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
583 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
584 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
585 # ./install, which can be erroneously created by make from ./install.sh.
586 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
587 echo "configure:588: checking for a BSD compatible install" >&5
588 if test -z "$INSTALL"; then
589 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
590   echo $ac_n "(cached) $ac_c" 1>&6
591 else
592     IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
593   for ac_dir in $PATH; do
594     # Account for people who put trailing slashes in PATH elements.
595     case "$ac_dir/" in
596     /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
597     *)
598       # OSF1 and SCO ODT 3.0 have their own names for install.
599       # Don't use installbsd from OSF since it installs stuff as root
600       # by default.
601       for ac_prog in ginstall scoinst install; do
602         if test -f $ac_dir/$ac_prog; then
603           if test $ac_prog = install &&
604             grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
605             # AIX install.  It has an incompatible calling convention.
606             :
607           else
608             ac_cv_path_install="$ac_dir/$ac_prog -c"
609             break 2
610           fi
611         fi
612       done
613       ;;
614     esac
615   done
616   IFS="$ac_save_IFS"
617
618 fi
619   if test "${ac_cv_path_install+set}" = set; then
620     INSTALL="$ac_cv_path_install"
621   else
622     # As a last resort, use the slow shell script.  We don't cache a
623     # path for INSTALL within a source directory, because that will
624     # break other packages using the cache if that directory is
625     # removed, or if the path is relative.
626     INSTALL="$ac_install_sh"
627   fi
628 fi
629 echo "$ac_t""$INSTALL" 1>&6
630
631 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
632 # It thinks the first close brace ends the variable substitution.
633 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
634
635 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
636
637 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
638
639 echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
640 echo "configure:641: checking whether build environment is sane" >&5
641 # Just in case
642 sleep 1
643 echo timestamp > conftestfile
644 # Do `set' in a subshell so we don't clobber the current shell's
645 # arguments.  Must try -L first in case configure is actually a
646 # symlink; some systems play weird games with the mod time of symlinks
647 # (eg FreeBSD returns the mod time of the symlink's containing
648 # directory).
649 if (
650    set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
651    if test "$*" = "X"; then
652       # -L didn't work.
653       set X `ls -t $srcdir/configure conftestfile`
654    fi
655    if test "$*" != "X $srcdir/configure conftestfile" \
656       && test "$*" != "X conftestfile $srcdir/configure"; then
657
658       # If neither matched, then we have a broken ls.  This can happen
659       # if, for instance, CONFIG_SHELL is bash and it inherits a
660       # broken ls alias from the environment.  This has actually
661       # happened.  Such a system could not be considered "sane".
662       { echo "configure: error: ls -t appears to fail.  Make sure there is not a broken
663 alias in your environment" 1>&2; exit 1; }
664    fi
665
666    test "$2" = conftestfile
667    )
668 then
669    # Ok.
670    :
671 else
672    { echo "configure: error: newly created file is older than distributed files!
673 Check your system clock" 1>&2; exit 1; }
674 fi
675 rm -f conftest*
676 echo "$ac_t""yes" 1>&6
677 if test "$program_transform_name" = s,x,x,; then
678   program_transform_name=
679 else
680   # Double any \ or $.  echo might interpret backslashes.
681   cat <<\EOF_SED > conftestsed
682 s,\\,\\\\,g; s,\$,$$,g
683 EOF_SED
684   program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
685   rm -f conftestsed
686 fi
687 test "$program_prefix" != NONE &&
688   program_transform_name="s,^,${program_prefix},; $program_transform_name"
689 # Use a double $ so make ignores it.
690 test "$program_suffix" != NONE &&
691   program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
692
693 # sed with no file args requires a program.
694 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
695
696 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
697 echo "configure:698: checking whether ${MAKE-make} sets \${MAKE}" >&5
698 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
699 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
700   echo $ac_n "(cached) $ac_c" 1>&6
701 else
702   cat > conftestmake <<\EOF
703 all:
704         @echo 'ac_maketemp="${MAKE}"'
705 EOF
706 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
707 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
708 if test -n "$ac_maketemp"; then
709   eval ac_cv_prog_make_${ac_make}_set=yes
710 else
711   eval ac_cv_prog_make_${ac_make}_set=no
712 fi
713 rm -f conftestmake
714 fi
715 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
716   echo "$ac_t""yes" 1>&6
717   SET_MAKE=
718 else
719   echo "$ac_t""no" 1>&6
720   SET_MAKE="MAKE=${MAKE-make}"
721 fi
722
723
724 PACKAGE=shadow
725
726 VERSION=20000826
727
728 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
729   { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
730 fi
731 cat >> confdefs.h <<EOF
732 #define PACKAGE "$PACKAGE"
733 EOF
734
735 cat >> confdefs.h <<EOF
736 #define VERSION "$VERSION"
737 EOF
738
739
740
741 missing_dir=`cd $ac_aux_dir && pwd`
742 echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
743 echo "configure:744: checking for working aclocal" >&5
744 # Run test in a subshell; some versions of sh will print an error if
745 # an executable is not found, even if stderr is redirected.
746 # Redirect stdin to placate older versions of autoconf.  Sigh.
747 if (aclocal --version) < /dev/null > /dev/null 2>&1; then
748    ACLOCAL=aclocal
749    echo "$ac_t""found" 1>&6
750 else
751    ACLOCAL="$missing_dir/missing aclocal"
752    echo "$ac_t""missing" 1>&6
753 fi
754
755 echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
756 echo "configure:757: checking for working autoconf" >&5
757 # Run test in a subshell; some versions of sh will print an error if
758 # an executable is not found, even if stderr is redirected.
759 # Redirect stdin to placate older versions of autoconf.  Sigh.
760 if (autoconf --version) < /dev/null > /dev/null 2>&1; then
761    AUTOCONF=autoconf
762    echo "$ac_t""found" 1>&6
763 else
764    AUTOCONF="$missing_dir/missing autoconf"
765    echo "$ac_t""missing" 1>&6
766 fi
767
768 echo $ac_n "checking for working automake""... $ac_c" 1>&6
769 echo "configure:770: checking for working automake" >&5
770 # Run test in a subshell; some versions of sh will print an error if
771 # an executable is not found, even if stderr is redirected.
772 # Redirect stdin to placate older versions of autoconf.  Sigh.
773 if (automake --version) < /dev/null > /dev/null 2>&1; then
774    AUTOMAKE=automake
775    echo "$ac_t""found" 1>&6
776 else
777    AUTOMAKE="$missing_dir/missing automake"
778    echo "$ac_t""missing" 1>&6
779 fi
780
781 echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
782 echo "configure:783: checking for working autoheader" >&5
783 # Run test in a subshell; some versions of sh will print an error if
784 # an executable is not found, even if stderr is redirected.
785 # Redirect stdin to placate older versions of autoconf.  Sigh.
786 if (autoheader --version) < /dev/null > /dev/null 2>&1; then
787    AUTOHEADER=autoheader
788    echo "$ac_t""found" 1>&6
789 else
790    AUTOHEADER="$missing_dir/missing autoheader"
791    echo "$ac_t""missing" 1>&6
792 fi
793
794 echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
795 echo "configure:796: checking for working makeinfo" >&5
796 # Run test in a subshell; some versions of sh will print an error if
797 # an executable is not found, even if stderr is redirected.
798 # Redirect stdin to placate older versions of autoconf.  Sigh.
799 if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
800    MAKEINFO=makeinfo
801    echo "$ac_t""found" 1>&6
802 else
803    MAKEINFO="$missing_dir/missing makeinfo"
804    echo "$ac_t""missing" 1>&6
805 fi
806
807
808
809
810
811
812 test "$prefix" = "NONE" && prefix="/usr"
813 test "$prefix" = "/usr" && exec_prefix=""
814 test "$CFLAGS" = "" && CFLAGS="-O2 -Wall"
815 test "$LDFLAGS" = "" && LDFLAGS="-s"
816
817 ALL_LINGUAS="el fr pl sv"
818
819 # Extract the first word of "gcc", so it can be a program name with args.
820 set dummy gcc; ac_word=$2
821 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
822 echo "configure:823: checking for $ac_word" >&5
823 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
824   echo $ac_n "(cached) $ac_c" 1>&6
825 else
826   if test -n "$CC"; then
827   ac_cv_prog_CC="$CC" # Let the user override the test.
828 else
829   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
830   ac_dummy="$PATH"
831   for ac_dir in $ac_dummy; do
832     test -z "$ac_dir" && ac_dir=.
833     if test -f $ac_dir/$ac_word; then
834       ac_cv_prog_CC="gcc"
835       break
836     fi
837   done
838   IFS="$ac_save_ifs"
839 fi
840 fi
841 CC="$ac_cv_prog_CC"
842 if test -n "$CC"; then
843   echo "$ac_t""$CC" 1>&6
844 else
845   echo "$ac_t""no" 1>&6
846 fi
847
848 if test -z "$CC"; then
849   # Extract the first word of "cc", so it can be a program name with args.
850 set dummy cc; ac_word=$2
851 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
852 echo "configure:853: checking for $ac_word" >&5
853 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
854   echo $ac_n "(cached) $ac_c" 1>&6
855 else
856   if test -n "$CC"; then
857   ac_cv_prog_CC="$CC" # Let the user override the test.
858 else
859   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
860   ac_prog_rejected=no
861   ac_dummy="$PATH"
862   for ac_dir in $ac_dummy; do
863     test -z "$ac_dir" && ac_dir=.
864     if test -f $ac_dir/$ac_word; then
865       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
866         ac_prog_rejected=yes
867         continue
868       fi
869       ac_cv_prog_CC="cc"
870       break
871     fi
872   done
873   IFS="$ac_save_ifs"
874 if test $ac_prog_rejected = yes; then
875   # We found a bogon in the path, so make sure we never use it.
876   set dummy $ac_cv_prog_CC
877   shift
878   if test $# -gt 0; then
879     # We chose a different compiler from the bogus one.
880     # However, it has the same basename, so the bogon will be chosen
881     # first if we set CC to just the basename; use the full file name.
882     shift
883     set dummy "$ac_dir/$ac_word" "$@"
884     shift
885     ac_cv_prog_CC="$@"
886   fi
887 fi
888 fi
889 fi
890 CC="$ac_cv_prog_CC"
891 if test -n "$CC"; then
892   echo "$ac_t""$CC" 1>&6
893 else
894   echo "$ac_t""no" 1>&6
895 fi
896
897   if test -z "$CC"; then
898     case "`uname -s`" in
899     *win32* | *WIN32*)
900       # Extract the first word of "cl", so it can be a program name with args.
901 set dummy cl; ac_word=$2
902 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
903 echo "configure:904: checking for $ac_word" >&5
904 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
905   echo $ac_n "(cached) $ac_c" 1>&6
906 else
907   if test -n "$CC"; then
908   ac_cv_prog_CC="$CC" # Let the user override the test.
909 else
910   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
911   ac_dummy="$PATH"
912   for ac_dir in $ac_dummy; do
913     test -z "$ac_dir" && ac_dir=.
914     if test -f $ac_dir/$ac_word; then
915       ac_cv_prog_CC="cl"
916       break
917     fi
918   done
919   IFS="$ac_save_ifs"
920 fi
921 fi
922 CC="$ac_cv_prog_CC"
923 if test -n "$CC"; then
924   echo "$ac_t""$CC" 1>&6
925 else
926   echo "$ac_t""no" 1>&6
927 fi
928  ;;
929     esac
930   fi
931   test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
932 fi
933
934 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
935 echo "configure:936: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
936
937 ac_ext=c
938 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
939 ac_cpp='$CPP $CPPFLAGS'
940 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
941 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
942 cross_compiling=$ac_cv_prog_cc_cross
943
944 cat > conftest.$ac_ext << EOF
945
946 #line 947 "configure"
947 #include "confdefs.h"
948
949 main(){return(0);}
950 EOF
951 if { (eval echo configure:952: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
952   ac_cv_prog_cc_works=yes
953   # If we can't run a trivial program, we are probably using a cross compiler.
954   if (./conftest; exit) 2>/dev/null; then
955     ac_cv_prog_cc_cross=no
956   else
957     ac_cv_prog_cc_cross=yes
958   fi
959 else
960   echo "configure: failed program was:" >&5
961   cat conftest.$ac_ext >&5
962   ac_cv_prog_cc_works=no
963 fi
964 rm -fr conftest*
965 ac_ext=c
966 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
967 ac_cpp='$CPP $CPPFLAGS'
968 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
969 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
970 cross_compiling=$ac_cv_prog_cc_cross
971
972 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
973 if test $ac_cv_prog_cc_works = no; then
974   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
975 fi
976 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
977 echo "configure:978: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
978 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
979 cross_compiling=$ac_cv_prog_cc_cross
980
981 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
982 echo "configure:983: checking whether we are using GNU C" >&5
983 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
984   echo $ac_n "(cached) $ac_c" 1>&6
985 else
986   cat > conftest.c <<EOF
987 #ifdef __GNUC__
988   yes;
989 #endif
990 EOF
991 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:992: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
992   ac_cv_prog_gcc=yes
993 else
994   ac_cv_prog_gcc=no
995 fi
996 fi
997
998 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
999
1000 if test $ac_cv_prog_gcc = yes; then
1001   GCC=yes
1002 else
1003   GCC=
1004 fi
1005
1006 ac_test_CFLAGS="${CFLAGS+set}"
1007 ac_save_CFLAGS="$CFLAGS"
1008 CFLAGS=
1009 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1010 echo "configure:1011: checking whether ${CC-cc} accepts -g" >&5
1011 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1012   echo $ac_n "(cached) $ac_c" 1>&6
1013 else
1014   echo 'void f(){}' > conftest.c
1015 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1016   ac_cv_prog_cc_g=yes
1017 else
1018   ac_cv_prog_cc_g=no
1019 fi
1020 rm -f conftest*
1021
1022 fi
1023
1024 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1025 if test "$ac_test_CFLAGS" = set; then
1026   CFLAGS="$ac_save_CFLAGS"
1027 elif test $ac_cv_prog_cc_g = yes; then
1028   if test "$GCC" = yes; then
1029     CFLAGS="-g -O2"
1030   else
1031     CFLAGS="-g"
1032   fi
1033 else
1034   if test "$GCC" = yes; then
1035     CFLAGS="-O2"
1036   else
1037     CFLAGS=
1038   fi
1039 fi
1040
1041 echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
1042 echo "configure:1043: checking for POSIXized ISC" >&5
1043 if test -d /etc/conf/kconfig.d &&
1044   grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
1045 then
1046   echo "$ac_t""yes" 1>&6
1047   ISC=yes # If later tests want to check for ISC.
1048   cat >> confdefs.h <<\EOF
1049 #define _POSIX_SOURCE 1
1050 EOF
1051
1052   if test "$GCC" = yes; then
1053     CC="$CC -posix"
1054   else
1055     CC="$CC -Xp"
1056   fi
1057 else
1058   echo "$ac_t""no" 1>&6
1059   ISC=
1060 fi
1061
1062 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
1063 echo "configure:1064: checking whether ln -s works" >&5
1064 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
1065   echo $ac_n "(cached) $ac_c" 1>&6
1066 else
1067   rm -f conftestdata
1068 if ln -s X conftestdata 2>/dev/null
1069 then
1070   rm -f conftestdata
1071   ac_cv_prog_LN_S="ln -s"
1072 else
1073   ac_cv_prog_LN_S=ln
1074 fi
1075 fi
1076 LN_S="$ac_cv_prog_LN_S"
1077 if test "$ac_cv_prog_LN_S" = "ln -s"; then
1078   echo "$ac_t""yes" 1>&6
1079 else
1080   echo "$ac_t""no" 1>&6
1081 fi
1082
1083 for ac_prog in 'bison -y' byacc
1084 do
1085 # Extract the first word of "$ac_prog", so it can be a program name with args.
1086 set dummy $ac_prog; ac_word=$2
1087 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1088 echo "configure:1089: checking for $ac_word" >&5
1089 if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
1090   echo $ac_n "(cached) $ac_c" 1>&6
1091 else
1092   if test -n "$YACC"; then
1093   ac_cv_prog_YACC="$YACC" # Let the user override the test.
1094 else
1095   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1096   ac_dummy="$PATH"
1097   for ac_dir in $ac_dummy; do
1098     test -z "$ac_dir" && ac_dir=.
1099     if test -f $ac_dir/$ac_word; then
1100       ac_cv_prog_YACC="$ac_prog"
1101       break
1102     fi
1103   done
1104   IFS="$ac_save_ifs"
1105 fi
1106 fi
1107 YACC="$ac_cv_prog_YACC"
1108 if test -n "$YACC"; then
1109   echo "$ac_t""$YACC" 1>&6
1110 else
1111   echo "$ac_t""no" 1>&6
1112 fi
1113
1114 test -n "$YACC" && break
1115 done
1116 test -n "$YACC" || YACC="yacc"
1117
1118
1119
1120
1121 echo $ac_n "checking for ${CC-cc} option to accept ANSI C""... $ac_c" 1>&6
1122 echo "configure:1123: checking for ${CC-cc} option to accept ANSI C" >&5
1123 if eval "test \"`echo '$''{'am_cv_prog_cc_stdc'+set}'`\" = set"; then
1124   echo $ac_n "(cached) $ac_c" 1>&6
1125 else
1126   am_cv_prog_cc_stdc=no
1127 ac_save_CC="$CC"
1128 # Don't try gcc -ansi; that turns off useful extensions and
1129 # breaks some systems' header files.
1130 # AIX                   -qlanglvl=ansi
1131 # Ultrix and OSF/1      -std1
1132 # HP-UX                 -Aa -D_HPUX_SOURCE
1133 # SVR4                  -Xc -D__EXTENSIONS__
1134 for ac_arg in "" -qlanglvl=ansi -std1 "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1135 do
1136   CC="$ac_save_CC $ac_arg"
1137   cat > conftest.$ac_ext <<EOF
1138 #line 1139 "configure"
1139 #include "confdefs.h"
1140 #include <stdarg.h>
1141 #include <stdio.h>
1142 #include <sys/types.h>
1143 #include <sys/stat.h>
1144 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
1145 struct buf { int x; };
1146 FILE * (*rcsopen) (struct buf *, struct stat *, int);
1147 static char *e (p, i)
1148      char **p;
1149      int i;
1150 {
1151   return p[i];
1152 }
1153 static char *f (char * (*g) (char **, int), char **p, ...)
1154 {
1155   char *s;
1156   va_list v;
1157   va_start (v,p);
1158   s = g (p, va_arg (v,int));
1159   va_end (v);
1160   return s;
1161 }
1162 int test (int i, double x);
1163 struct s1 {int (*f) (int a);};
1164 struct s2 {int (*f) (double a);};
1165 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
1166 int argc;
1167 char **argv;
1168
1169 int main() {
1170
1171 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
1172
1173 ; return 0; }
1174 EOF
1175 if { (eval echo configure:1176: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1176   rm -rf conftest*
1177   am_cv_prog_cc_stdc="$ac_arg"; break
1178 else
1179   echo "configure: failed program was:" >&5
1180   cat conftest.$ac_ext >&5
1181 fi
1182 rm -f conftest*
1183 done
1184 CC="$ac_save_CC"
1185
1186 fi
1187
1188 if test -z "$am_cv_prog_cc_stdc"; then
1189   echo "$ac_t""none needed" 1>&6
1190 else
1191   echo "$ac_t""$am_cv_prog_cc_stdc" 1>&6
1192 fi
1193 case "x$am_cv_prog_cc_stdc" in
1194   x|xno) ;;
1195   *) CC="$CC $am_cv_prog_cc_stdc" ;;
1196 esac
1197
1198 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1199 echo "configure:1200: checking how to run the C preprocessor" >&5
1200 # On Suns, sometimes $CPP names a directory.
1201 if test -n "$CPP" && test -d "$CPP"; then
1202   CPP=
1203 fi
1204 if test -z "$CPP"; then
1205 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1206   echo $ac_n "(cached) $ac_c" 1>&6
1207 else
1208     # This must be in double quotes, not single quotes, because CPP may get
1209   # substituted into the Makefile and "${CC-cc}" will confuse make.
1210   CPP="${CC-cc} -E"
1211   # On the NeXT, cc -E runs the code through the compiler's parser,
1212   # not just through cpp.
1213   cat > conftest.$ac_ext <<EOF
1214 #line 1215 "configure"
1215 #include "confdefs.h"
1216 #include <assert.h>
1217 Syntax Error
1218 EOF
1219 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1220 { (eval echo configure:1221: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1221 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1222 if test -z "$ac_err"; then
1223   :
1224 else
1225   echo "$ac_err" >&5
1226   echo "configure: failed program was:" >&5
1227   cat conftest.$ac_ext >&5
1228   rm -rf conftest*
1229   CPP="${CC-cc} -E -traditional-cpp"
1230   cat > conftest.$ac_ext <<EOF
1231 #line 1232 "configure"
1232 #include "confdefs.h"
1233 #include <assert.h>
1234 Syntax Error
1235 EOF
1236 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1237 { (eval echo configure:1238: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1238 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1239 if test -z "$ac_err"; then
1240   :
1241 else
1242   echo "$ac_err" >&5
1243   echo "configure: failed program was:" >&5
1244   cat conftest.$ac_ext >&5
1245   rm -rf conftest*
1246   CPP="${CC-cc} -nologo -E"
1247   cat > conftest.$ac_ext <<EOF
1248 #line 1249 "configure"
1249 #include "confdefs.h"
1250 #include <assert.h>
1251 Syntax Error
1252 EOF
1253 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1254 { (eval echo configure:1255: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1255 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1256 if test -z "$ac_err"; then
1257   :
1258 else
1259   echo "$ac_err" >&5
1260   echo "configure: failed program was:" >&5
1261   cat conftest.$ac_ext >&5
1262   rm -rf conftest*
1263   CPP=/lib/cpp
1264 fi
1265 rm -f conftest*
1266 fi
1267 rm -f conftest*
1268 fi
1269 rm -f conftest*
1270   ac_cv_prog_CPP="$CPP"
1271 fi
1272   CPP="$ac_cv_prog_CPP"
1273 else
1274   ac_cv_prog_CPP="$CPP"
1275 fi
1276 echo "$ac_t""$CPP" 1>&6
1277
1278
1279
1280 echo $ac_n "checking for function prototypes""... $ac_c" 1>&6
1281 echo "configure:1282: checking for function prototypes" >&5
1282 if test "$am_cv_prog_cc_stdc" != no; then
1283   echo "$ac_t""yes" 1>&6
1284   cat >> confdefs.h <<\EOF
1285 #define PROTOTYPES 1
1286 EOF
1287
1288   U= ANSI2KNR=
1289 else
1290   echo "$ac_t""no" 1>&6
1291   U=_ ANSI2KNR=./ansi2knr
1292   # Ensure some checks needed by ansi2knr itself.
1293   echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1294 echo "configure:1295: checking for ANSI C header files" >&5
1295 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1296   echo $ac_n "(cached) $ac_c" 1>&6
1297 else
1298   cat > conftest.$ac_ext <<EOF
1299 #line 1300 "configure"
1300 #include "confdefs.h"
1301 #include <stdlib.h>
1302 #include <stdarg.h>
1303 #include <string.h>
1304 #include <float.h>
1305 EOF
1306 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1307 { (eval echo configure:1308: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1308 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1309 if test -z "$ac_err"; then
1310   rm -rf conftest*
1311   ac_cv_header_stdc=yes
1312 else
1313   echo "$ac_err" >&5
1314   echo "configure: failed program was:" >&5
1315   cat conftest.$ac_ext >&5
1316   rm -rf conftest*
1317   ac_cv_header_stdc=no
1318 fi
1319 rm -f conftest*
1320
1321 if test $ac_cv_header_stdc = yes; then
1322   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1323 cat > conftest.$ac_ext <<EOF
1324 #line 1325 "configure"
1325 #include "confdefs.h"
1326 #include <string.h>
1327 EOF
1328 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1329   egrep "memchr" >/dev/null 2>&1; then
1330   :
1331 else
1332   rm -rf conftest*
1333   ac_cv_header_stdc=no
1334 fi
1335 rm -f conftest*
1336
1337 fi
1338
1339 if test $ac_cv_header_stdc = yes; then
1340   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1341 cat > conftest.$ac_ext <<EOF
1342 #line 1343 "configure"
1343 #include "confdefs.h"
1344 #include <stdlib.h>
1345 EOF
1346 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1347   egrep "free" >/dev/null 2>&1; then
1348   :
1349 else
1350   rm -rf conftest*
1351   ac_cv_header_stdc=no
1352 fi
1353 rm -f conftest*
1354
1355 fi
1356
1357 if test $ac_cv_header_stdc = yes; then
1358   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1359 if test "$cross_compiling" = yes; then
1360   :
1361 else
1362   cat > conftest.$ac_ext <<EOF
1363 #line 1364 "configure"
1364 #include "confdefs.h"
1365 #include <ctype.h>
1366 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1367 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1368 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1369 int main () { int i; for (i = 0; i < 256; i++)
1370 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1371 exit (0); }
1372
1373 EOF
1374 if { (eval echo configure:1375: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1375 then
1376   :
1377 else
1378   echo "configure: failed program was:" >&5
1379   cat conftest.$ac_ext >&5
1380   rm -fr conftest*
1381   ac_cv_header_stdc=no
1382 fi
1383 rm -fr conftest*
1384 fi
1385
1386 fi
1387 fi
1388
1389 echo "$ac_t""$ac_cv_header_stdc" 1>&6
1390 if test $ac_cv_header_stdc = yes; then
1391   cat >> confdefs.h <<\EOF
1392 #define STDC_HEADERS 1
1393 EOF
1394
1395 fi
1396
1397   for ac_hdr in string.h
1398 do
1399 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1400 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1401 echo "configure:1402: checking for $ac_hdr" >&5
1402 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1403   echo $ac_n "(cached) $ac_c" 1>&6
1404 else
1405   cat > conftest.$ac_ext <<EOF
1406 #line 1407 "configure"
1407 #include "confdefs.h"
1408 #include <$ac_hdr>
1409 EOF
1410 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1411 { (eval echo configure:1412: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1412 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1413 if test -z "$ac_err"; then
1414   rm -rf conftest*
1415   eval "ac_cv_header_$ac_safe=yes"
1416 else
1417   echo "$ac_err" >&5
1418   echo "configure: failed program was:" >&5
1419   cat conftest.$ac_ext >&5
1420   rm -rf conftest*
1421   eval "ac_cv_header_$ac_safe=no"
1422 fi
1423 rm -f conftest*
1424 fi
1425 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1426   echo "$ac_t""yes" 1>&6
1427     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1428   cat >> confdefs.h <<EOF
1429 #define $ac_tr_hdr 1
1430 EOF
1431  
1432 else
1433   echo "$ac_t""no" 1>&6
1434 fi
1435 done
1436
1437 fi
1438
1439 # Check whether --enable-shared or --disable-shared was given.
1440 if test "${enable_shared+set}" = set; then
1441   enableval="$enable_shared"
1442   p=${PACKAGE-default}
1443 case "$enableval" in
1444 yes) enable_shared=yes ;;
1445 no) enable_shared=no ;;
1446 *)
1447   enable_shared=no
1448   # Look at the argument we got.  We use all the common list separators.
1449   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1450   for pkg in $enableval; do
1451     if test "X$pkg" = "X$p"; then
1452       enable_shared=yes
1453     fi
1454   done
1455   IFS="$ac_save_ifs"
1456   ;;
1457 esac
1458 else
1459   enable_shared=yes
1460 fi
1461
1462 # Check whether --enable-static or --disable-static was given.
1463 if test "${enable_static+set}" = set; then
1464   enableval="$enable_static"
1465   p=${PACKAGE-default}
1466 case "$enableval" in
1467 yes) enable_static=yes ;;
1468 no) enable_static=no ;;
1469 *)
1470   enable_static=no
1471   # Look at the argument we got.  We use all the common list separators.
1472   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1473   for pkg in $enableval; do
1474     if test "X$pkg" = "X$p"; then
1475       enable_static=yes
1476     fi
1477   done
1478   IFS="$ac_save_ifs"
1479   ;;
1480 esac
1481 else
1482   enable_static=yes
1483 fi
1484
1485 # Check whether --enable-fast-install or --disable-fast-install was given.
1486 if test "${enable_fast_install+set}" = set; then
1487   enableval="$enable_fast_install"
1488   p=${PACKAGE-default}
1489 case "$enableval" in
1490 yes) enable_fast_install=yes ;;
1491 no) enable_fast_install=no ;;
1492 *)
1493   enable_fast_install=no
1494   # Look at the argument we got.  We use all the common list separators.
1495   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
1496   for pkg in $enableval; do
1497     if test "X$pkg" = "X$p"; then
1498       enable_fast_install=yes
1499     fi
1500   done
1501   IFS="$ac_save_ifs"
1502   ;;
1503 esac
1504 else
1505   enable_fast_install=yes
1506 fi
1507
1508
1509 # Make sure we can run config.sub.
1510 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
1511 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
1512 fi
1513
1514 echo $ac_n "checking host system type""... $ac_c" 1>&6
1515 echo "configure:1516: checking host system type" >&5
1516
1517 host_alias=$host
1518 case "$host_alias" in
1519 NONE)
1520   case $nonopt in
1521   NONE)
1522     if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
1523     else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
1524     fi ;;
1525   *) host_alias=$nonopt ;;
1526   esac ;;
1527 esac
1528
1529 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
1530 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1531 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1532 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1533 echo "$ac_t""$host" 1>&6
1534
1535 echo $ac_n "checking build system type""... $ac_c" 1>&6
1536 echo "configure:1537: checking build system type" >&5
1537
1538 build_alias=$build
1539 case "$build_alias" in
1540 NONE)
1541   case $nonopt in
1542   NONE) build_alias=$host_alias ;;
1543   *) build_alias=$nonopt ;;
1544   esac ;;
1545 esac
1546
1547 build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
1548 build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1549 build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1550 build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1551 echo "$ac_t""$build" 1>&6
1552
1553 # Extract the first word of "ranlib", so it can be a program name with args.
1554 set dummy ranlib; ac_word=$2
1555 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1556 echo "configure:1557: checking for $ac_word" >&5
1557 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1558   echo $ac_n "(cached) $ac_c" 1>&6
1559 else
1560   if test -n "$RANLIB"; then
1561   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1562 else
1563   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1564   ac_dummy="$PATH"
1565   for ac_dir in $ac_dummy; do
1566     test -z "$ac_dir" && ac_dir=.
1567     if test -f $ac_dir/$ac_word; then
1568       ac_cv_prog_RANLIB="ranlib"
1569       break
1570     fi
1571   done
1572   IFS="$ac_save_ifs"
1573   test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1574 fi
1575 fi
1576 RANLIB="$ac_cv_prog_RANLIB"
1577 if test -n "$RANLIB"; then
1578   echo "$ac_t""$RANLIB" 1>&6
1579 else
1580   echo "$ac_t""no" 1>&6
1581 fi
1582
1583 # Check whether --with-gnu-ld or --without-gnu-ld was given.
1584 if test "${with_gnu_ld+set}" = set; then
1585   withval="$with_gnu_ld"
1586   test "$withval" = no || with_gnu_ld=yes
1587 else
1588   with_gnu_ld=no
1589 fi
1590
1591 ac_prog=ld
1592 if test "$ac_cv_prog_gcc" = yes; then
1593   # Check if gcc -print-prog-name=ld gives a path.
1594   echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
1595 echo "configure:1596: checking for ld used by GCC" >&5
1596   ac_prog=`($CC -print-prog-name=ld) 2>&5`
1597   case "$ac_prog" in
1598     # Accept absolute paths.
1599     [\\/]* | [A-Za-z]:[\\/]*)
1600       re_direlt='/[^/][^/]*/\.\./'
1601       # Canonicalize the path of ld
1602       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
1603       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
1604         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
1605       done
1606       test -z "$LD" && LD="$ac_prog"
1607       ;;
1608   "")
1609     # If it fails, then pretend we aren't using GCC.
1610     ac_prog=ld
1611     ;;
1612   *)
1613     # If it is relative, then search for the first ld in PATH.
1614     with_gnu_ld=unknown
1615     ;;
1616   esac
1617 elif test "$with_gnu_ld" = yes; then
1618   echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
1619 echo "configure:1620: checking for GNU ld" >&5
1620 else
1621   echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
1622 echo "configure:1623: checking for non-GNU ld" >&5
1623 fi
1624 if eval "test \"`echo '$''{'ac_cv_path_LD'+set}'`\" = set"; then
1625   echo $ac_n "(cached) $ac_c" 1>&6
1626 else
1627   if test -z "$LD"; then
1628   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
1629   for ac_dir in $PATH; do
1630     test -z "$ac_dir" && ac_dir=.
1631     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
1632       ac_cv_path_LD="$ac_dir/$ac_prog"
1633       # Check to see if the program is GNU ld.  I'd rather use --version,
1634       # but apparently some GNU ld's only accept -v.
1635       # Break only if it was the GNU/non-GNU ld that we prefer.
1636       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
1637         test "$with_gnu_ld" != no && break
1638       else
1639         test "$with_gnu_ld" != yes && break
1640       fi
1641     fi
1642   done
1643   IFS="$ac_save_ifs"
1644 else
1645   ac_cv_path_LD="$LD" # Let the user override the test with a path.
1646 fi
1647 fi
1648
1649 LD="$ac_cv_path_LD"
1650 if test -n "$LD"; then
1651   echo "$ac_t""$LD" 1>&6
1652 else
1653   echo "$ac_t""no" 1>&6
1654 fi
1655 test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
1656
1657 echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
1658 echo "configure:1659: checking if the linker ($LD) is GNU ld" >&5
1659 if eval "test \"`echo '$''{'ac_cv_prog_gnu_ld'+set}'`\" = set"; then
1660   echo $ac_n "(cached) $ac_c" 1>&6
1661 else
1662   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
1663 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
1664   ac_cv_prog_gnu_ld=yes
1665 else
1666   ac_cv_prog_gnu_ld=no
1667 fi
1668 fi
1669
1670 echo "$ac_t""$ac_cv_prog_gnu_ld" 1>&6
1671
1672
1673 echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
1674 echo "configure:1675: checking for BSD-compatible nm" >&5
1675 if eval "test \"`echo '$''{'ac_cv_path_NM'+set}'`\" = set"; then
1676   echo $ac_n "(cached) $ac_c" 1>&6
1677 else
1678   if test -n "$NM"; then
1679   # Let the user override the test.
1680   ac_cv_path_NM="$NM"
1681 else
1682   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
1683   for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
1684     test -z "$ac_dir" && ac_dir=.
1685     if test -f $ac_dir/nm || test -f $ac_dir/nm$ac_exeext ; then
1686       # Check to see if the nm accepts a BSD-compat flag.
1687       # Adding the `sed 1q' prevents false positives on HP-UX, which says:
1688       #   nm: unknown option "B" ignored
1689       if ($ac_dir/nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
1690         ac_cv_path_NM="$ac_dir/nm -B"
1691         break
1692       elif ($ac_dir/nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
1693         ac_cv_path_NM="$ac_dir/nm -p"
1694         break
1695       else
1696         ac_cv_path_NM=${ac_cv_path_NM="$ac_dir/nm"} # keep the first match, but
1697         continue # so that we can try to find one that supports BSD flags
1698       fi
1699     fi
1700   done
1701   IFS="$ac_save_ifs"
1702   test -z "$ac_cv_path_NM" && ac_cv_path_NM=nm
1703 fi
1704 fi
1705
1706 NM="$ac_cv_path_NM"
1707 echo "$ac_t""$NM" 1>&6
1708
1709
1710
1711 # Check for any special flags to pass to ltconfig.
1712 libtool_flags="--cache-file=$cache_file"
1713 test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
1714 test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static"
1715 test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install"
1716 test "$ac_cv_prog_gcc" = yes && libtool_flags="$libtool_flags --with-gcc"
1717 test "$ac_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
1718
1719
1720 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
1721 if test "${enable_libtool_lock+set}" = set; then
1722   enableval="$enable_libtool_lock"
1723   :
1724 fi
1725
1726 test "x$enable_libtool_lock" = xno && libtool_flags="$libtool_flags --disable-lock"
1727 test x"$silent" = xyes && libtool_flags="$libtool_flags --silent"
1728
1729 # Some flags need to be propagated to the compiler or linker for good
1730 # libtool support.
1731 case "$host" in
1732 *-*-irix6*)
1733   # Find out which ABI we are using.
1734   echo '#line 1735 "configure"' > conftest.$ac_ext
1735   if { (eval echo configure:1736: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1736     case "`/usr/bin/file conftest.o`" in
1737     *32-bit*)
1738       LD="${LD-ld} -32"
1739       ;;
1740     *N32*)
1741       LD="${LD-ld} -n32"
1742       ;;
1743     *64-bit*)
1744       LD="${LD-ld} -64"
1745       ;;
1746     esac
1747   fi
1748   rm -rf conftest*
1749   ;;
1750
1751 *-*-sco3.2v5*)
1752   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1753   SAVE_CFLAGS="$CFLAGS"
1754   CFLAGS="$CFLAGS -belf"
1755   echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
1756 echo "configure:1757: checking whether the C compiler needs -belf" >&5
1757 if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
1758   echo $ac_n "(cached) $ac_c" 1>&6
1759 else
1760   cat > conftest.$ac_ext <<EOF
1761 #line 1762 "configure"
1762 #include "confdefs.h"
1763
1764 int main() {
1765
1766 ; return 0; }
1767 EOF
1768 if { (eval echo configure:1769: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1769   rm -rf conftest*
1770   lt_cv_cc_needs_belf=yes
1771 else
1772   echo "configure: failed program was:" >&5
1773   cat conftest.$ac_ext >&5
1774   rm -rf conftest*
1775   lt_cv_cc_needs_belf=no
1776 fi
1777 rm -f conftest*
1778 fi
1779
1780 echo "$ac_t""$lt_cv_cc_needs_belf" 1>&6
1781   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1782     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1783     CFLAGS="$SAVE_CFLAGS"
1784   fi
1785   ;;
1786
1787
1788 esac
1789
1790
1791 # Save cache, so that ltconfig can load it
1792 cat > confcache <<\EOF
1793 # This file is a shell script that caches the results of configure
1794 # tests run on this system so they can be shared between configure
1795 # scripts and configure runs.  It is not useful on other systems.
1796 # If it contains results you don't want to keep, you may remove or edit it.
1797 #
1798 # By default, configure uses ./config.cache as the cache file,
1799 # creating it if it does not exist already.  You can give configure
1800 # the --cache-file=FILE option to use a different cache file; that is
1801 # what configure does when it calls configure scripts in
1802 # subdirectories, so they share the cache.
1803 # Giving --cache-file=/dev/null disables caching, for debugging configure.
1804 # config.status only pays attention to the cache file if you give it the
1805 # --recheck option to rerun configure.
1806 #
1807 EOF
1808 # The following way of writing the cache mishandles newlines in values,
1809 # but we know of no workaround that is simple, portable, and efficient.
1810 # So, don't put newlines in cache variables' values.
1811 # Ultrix sh set writes to stderr and can't be redirected directly,
1812 # and sets the high bit in the cache file unless we assign to the vars.
1813 (set) 2>&1 |
1814   case `(ac_space=' '; set | grep ac_space) 2>&1` in
1815   *ac_space=\ *)
1816     # `set' does not quote correctly, so add quotes (double-quote substitution
1817     # turns \\\\ into \\, and sed turns \\ into \).
1818     sed -n \
1819       -e "s/'/'\\\\''/g" \
1820       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
1821     ;;
1822   *)
1823     # `set' quotes correctly as required by POSIX, so do not add quotes.
1824     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
1825     ;;
1826   esac >> confcache
1827 if cmp -s $cache_file confcache; then
1828   :
1829 else
1830   if test -w $cache_file; then
1831     echo "updating cache $cache_file"
1832     cat confcache > $cache_file
1833   else
1834     echo "not updating unwritable cache $cache_file"
1835   fi
1836 fi
1837 rm -f confcache
1838
1839
1840 # Actually configure libtool.  ac_aux_dir is where install-sh is found.
1841 CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
1842 LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
1843 LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" \
1844 DLLTOOL="$DLLTOOL" AS="$AS" OBJDUMP="$OBJDUMP" \
1845 ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \
1846 $libtool_flags --no-verify $ac_aux_dir/ltmain.sh $host \
1847 || { echo "configure: error: libtool configure failed" 1>&2; exit 1; }
1848
1849 # Reload cache, that may have been modified by ltconfig
1850 if test -r "$cache_file"; then
1851   echo "loading cache $cache_file"
1852   . $cache_file
1853 else
1854   echo "creating cache $cache_file"
1855   > $cache_file
1856 fi
1857
1858
1859 # This can be used to rebuild libtool when needed
1860 LIBTOOL_DEPS="$ac_aux_dir/ltconfig $ac_aux_dir/ltmain.sh"
1861
1862 # Always use our own libtool.
1863 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
1864
1865 # Redirect the config.log output again, so that the ltconfig log is not
1866 # clobbered by the next message.
1867 exec 5>>./config.log
1868
1869
1870
1871 ac_header_dirent=no
1872 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
1873 do
1874 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1875 echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
1876 echo "configure:1877: checking for $ac_hdr that defines DIR" >&5
1877 if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
1878   echo $ac_n "(cached) $ac_c" 1>&6
1879 else
1880   cat > conftest.$ac_ext <<EOF
1881 #line 1882 "configure"
1882 #include "confdefs.h"
1883 #include <sys/types.h>
1884 #include <$ac_hdr>
1885 int main() {
1886 DIR *dirp = 0;
1887 ; return 0; }
1888 EOF
1889 if { (eval echo configure:1890: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1890   rm -rf conftest*
1891   eval "ac_cv_header_dirent_$ac_safe=yes"
1892 else
1893   echo "configure: failed program was:" >&5
1894   cat conftest.$ac_ext >&5
1895   rm -rf conftest*
1896   eval "ac_cv_header_dirent_$ac_safe=no"
1897 fi
1898 rm -f conftest*
1899 fi
1900 if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
1901   echo "$ac_t""yes" 1>&6
1902     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1903   cat >> confdefs.h <<EOF
1904 #define $ac_tr_hdr 1
1905 EOF
1906  ac_header_dirent=$ac_hdr; break
1907 else
1908   echo "$ac_t""no" 1>&6
1909 fi
1910 done
1911 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
1912 if test $ac_header_dirent = dirent.h; then
1913 echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
1914 echo "configure:1915: checking for opendir in -ldir" >&5
1915 ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
1916 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1917   echo $ac_n "(cached) $ac_c" 1>&6
1918 else
1919   ac_save_LIBS="$LIBS"
1920 LIBS="-ldir  $LIBS"
1921 cat > conftest.$ac_ext <<EOF
1922 #line 1923 "configure"
1923 #include "confdefs.h"
1924 /* Override any gcc2 internal prototype to avoid an error.  */
1925 /* We use char because int might match the return type of a gcc2
1926     builtin and then its argument prototype would still apply.  */
1927 char opendir();
1928
1929 int main() {
1930 opendir()
1931 ; return 0; }
1932 EOF
1933 if { (eval echo configure:1934: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1934   rm -rf conftest*
1935   eval "ac_cv_lib_$ac_lib_var=yes"
1936 else
1937   echo "configure: failed program was:" >&5
1938   cat conftest.$ac_ext >&5
1939   rm -rf conftest*
1940   eval "ac_cv_lib_$ac_lib_var=no"
1941 fi
1942 rm -f conftest*
1943 LIBS="$ac_save_LIBS"
1944
1945 fi
1946 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1947   echo "$ac_t""yes" 1>&6
1948   LIBS="$LIBS -ldir"
1949 else
1950   echo "$ac_t""no" 1>&6
1951 fi
1952
1953 else
1954 echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
1955 echo "configure:1956: checking for opendir in -lx" >&5
1956 ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
1957 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1958   echo $ac_n "(cached) $ac_c" 1>&6
1959 else
1960   ac_save_LIBS="$LIBS"
1961 LIBS="-lx  $LIBS"
1962 cat > conftest.$ac_ext <<EOF
1963 #line 1964 "configure"
1964 #include "confdefs.h"
1965 /* Override any gcc2 internal prototype to avoid an error.  */
1966 /* We use char because int might match the return type of a gcc2
1967     builtin and then its argument prototype would still apply.  */
1968 char opendir();
1969
1970 int main() {
1971 opendir()
1972 ; return 0; }
1973 EOF
1974 if { (eval echo configure:1975: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1975   rm -rf conftest*
1976   eval "ac_cv_lib_$ac_lib_var=yes"
1977 else
1978   echo "configure: failed program was:" >&5
1979   cat conftest.$ac_ext >&5
1980   rm -rf conftest*
1981   eval "ac_cv_lib_$ac_lib_var=no"
1982 fi
1983 rm -f conftest*
1984 LIBS="$ac_save_LIBS"
1985
1986 fi
1987 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1988   echo "$ac_t""yes" 1>&6
1989   LIBS="$LIBS -lx"
1990 else
1991   echo "$ac_t""no" 1>&6
1992 fi
1993
1994 fi
1995
1996 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1997 echo "configure:1998: checking for ANSI C header files" >&5
1998 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1999   echo $ac_n "(cached) $ac_c" 1>&6
2000 else
2001   cat > conftest.$ac_ext <<EOF
2002 #line 2003 "configure"
2003 #include "confdefs.h"
2004 #include <stdlib.h>
2005 #include <stdarg.h>
2006 #include <string.h>
2007 #include <float.h>
2008 EOF
2009 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2010 { (eval echo configure:2011: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2011 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2012 if test -z "$ac_err"; then
2013   rm -rf conftest*
2014   ac_cv_header_stdc=yes
2015 else
2016   echo "$ac_err" >&5
2017   echo "configure: failed program was:" >&5
2018   cat conftest.$ac_ext >&5
2019   rm -rf conftest*
2020   ac_cv_header_stdc=no
2021 fi
2022 rm -f conftest*
2023
2024 if test $ac_cv_header_stdc = yes; then
2025   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2026 cat > conftest.$ac_ext <<EOF
2027 #line 2028 "configure"
2028 #include "confdefs.h"
2029 #include <string.h>
2030 EOF
2031 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2032   egrep "memchr" >/dev/null 2>&1; then
2033   :
2034 else
2035   rm -rf conftest*
2036   ac_cv_header_stdc=no
2037 fi
2038 rm -f conftest*
2039
2040 fi
2041
2042 if test $ac_cv_header_stdc = yes; then
2043   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2044 cat > conftest.$ac_ext <<EOF
2045 #line 2046 "configure"
2046 #include "confdefs.h"
2047 #include <stdlib.h>
2048 EOF
2049 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2050   egrep "free" >/dev/null 2>&1; then
2051   :
2052 else
2053   rm -rf conftest*
2054   ac_cv_header_stdc=no
2055 fi
2056 rm -f conftest*
2057
2058 fi
2059
2060 if test $ac_cv_header_stdc = yes; then
2061   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2062 if test "$cross_compiling" = yes; then
2063   :
2064 else
2065   cat > conftest.$ac_ext <<EOF
2066 #line 2067 "configure"
2067 #include "confdefs.h"
2068 #include <ctype.h>
2069 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2070 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2071 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2072 int main () { int i; for (i = 0; i < 256; i++)
2073 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
2074 exit (0); }
2075
2076 EOF
2077 if { (eval echo configure:2078: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2078 then
2079   :
2080 else
2081   echo "configure: failed program was:" >&5
2082   cat conftest.$ac_ext >&5
2083   rm -fr conftest*
2084   ac_cv_header_stdc=no
2085 fi
2086 rm -fr conftest*
2087 fi
2088
2089 fi
2090 fi
2091
2092 echo "$ac_t""$ac_cv_header_stdc" 1>&6
2093 if test $ac_cv_header_stdc = yes; then
2094   cat >> confdefs.h <<\EOF
2095 #define STDC_HEADERS 1
2096 EOF
2097
2098 fi
2099
2100 echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
2101 echo "configure:2102: checking for sys/wait.h that is POSIX.1 compatible" >&5
2102 if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
2103   echo $ac_n "(cached) $ac_c" 1>&6
2104 else
2105   cat > conftest.$ac_ext <<EOF
2106 #line 2107 "configure"
2107 #include "confdefs.h"
2108 #include <sys/types.h>
2109 #include <sys/wait.h>
2110 #ifndef WEXITSTATUS
2111 #define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
2112 #endif
2113 #ifndef WIFEXITED
2114 #define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
2115 #endif
2116 int main() {
2117 int s;
2118 wait (&s);
2119 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
2120 ; return 0; }
2121 EOF
2122 if { (eval echo configure:2123: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2123   rm -rf conftest*
2124   ac_cv_header_sys_wait_h=yes
2125 else
2126   echo "configure: failed program was:" >&5
2127   cat conftest.$ac_ext >&5
2128   rm -rf conftest*
2129   ac_cv_header_sys_wait_h=no
2130 fi
2131 rm -f conftest*
2132 fi
2133
2134 echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6
2135 if test $ac_cv_header_sys_wait_h = yes; then
2136   cat >> confdefs.h <<\EOF
2137 #define HAVE_SYS_WAIT_H 1
2138 EOF
2139
2140 fi
2141
2142 for ac_hdr in fcntl.h limits.h unistd.h sys/time.h utmp.h utmpx.h
2143 do
2144 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2145 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2146 echo "configure:2147: checking for $ac_hdr" >&5
2147 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2148   echo $ac_n "(cached) $ac_c" 1>&6
2149 else
2150   cat > conftest.$ac_ext <<EOF
2151 #line 2152 "configure"
2152 #include "confdefs.h"
2153 #include <$ac_hdr>
2154 EOF
2155 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2156 { (eval echo configure:2157: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2157 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2158 if test -z "$ac_err"; then
2159   rm -rf conftest*
2160   eval "ac_cv_header_$ac_safe=yes"
2161 else
2162   echo "$ac_err" >&5
2163   echo "configure: failed program was:" >&5
2164   cat conftest.$ac_ext >&5
2165   rm -rf conftest*
2166   eval "ac_cv_header_$ac_safe=no"
2167 fi
2168 rm -f conftest*
2169 fi
2170 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2171   echo "$ac_t""yes" 1>&6
2172     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2173   cat >> confdefs.h <<EOF
2174 #define $ac_tr_hdr 1
2175 EOF
2176  
2177 else
2178   echo "$ac_t""no" 1>&6
2179 fi
2180 done
2181
2182 for ac_hdr in termios.h termio.h sgtty.h sys/ioctl.h syslog.h
2183 do
2184 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2185 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2186 echo "configure:2187: checking for $ac_hdr" >&5
2187 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2188   echo $ac_n "(cached) $ac_c" 1>&6
2189 else
2190   cat > conftest.$ac_ext <<EOF
2191 #line 2192 "configure"
2192 #include "confdefs.h"
2193 #include <$ac_hdr>
2194 EOF
2195 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2196 { (eval echo configure:2197: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2197 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2198 if test -z "$ac_err"; then
2199   rm -rf conftest*
2200   eval "ac_cv_header_$ac_safe=yes"
2201 else
2202   echo "$ac_err" >&5
2203   echo "configure: failed program was:" >&5
2204   cat conftest.$ac_ext >&5
2205   rm -rf conftest*
2206   eval "ac_cv_header_$ac_safe=no"
2207 fi
2208 rm -f conftest*
2209 fi
2210 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2211   echo "$ac_t""yes" 1>&6
2212     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2213   cat >> confdefs.h <<EOF
2214 #define $ac_tr_hdr 1
2215 EOF
2216  
2217 else
2218   echo "$ac_t""no" 1>&6
2219 fi
2220 done
2221
2222 for ac_hdr in paths.h usersec.h utime.h ulimit.h sys/resource.h
2223 do
2224 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2225 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2226 echo "configure:2227: checking for $ac_hdr" >&5
2227 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2228   echo $ac_n "(cached) $ac_c" 1>&6
2229 else
2230   cat > conftest.$ac_ext <<EOF
2231 #line 2232 "configure"
2232 #include "confdefs.h"
2233 #include <$ac_hdr>
2234 EOF
2235 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2236 { (eval echo configure:2237: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2237 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2238 if test -z "$ac_err"; then
2239   rm -rf conftest*
2240   eval "ac_cv_header_$ac_safe=yes"
2241 else
2242   echo "$ac_err" >&5
2243   echo "configure: failed program was:" >&5
2244   cat conftest.$ac_ext >&5
2245   rm -rf conftest*
2246   eval "ac_cv_header_$ac_safe=no"
2247 fi
2248 rm -f conftest*
2249 fi
2250 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2251   echo "$ac_t""yes" 1>&6
2252     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2253   cat >> confdefs.h <<EOF
2254 #define $ac_tr_hdr 1
2255 EOF
2256  
2257 else
2258   echo "$ac_t""no" 1>&6
2259 fi
2260 done
2261
2262 for ac_hdr in gshadow.h shadow.h lastlog.h rpc/key_prot.h
2263 do
2264 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2265 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2266 echo "configure:2267: checking for $ac_hdr" >&5
2267 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2268   echo $ac_n "(cached) $ac_c" 1>&6
2269 else
2270   cat > conftest.$ac_ext <<EOF
2271 #line 2272 "configure"
2272 #include "confdefs.h"
2273 #include <$ac_hdr>
2274 EOF
2275 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2276 { (eval echo configure:2277: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2277 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2278 if test -z "$ac_err"; then
2279   rm -rf conftest*
2280   eval "ac_cv_header_$ac_safe=yes"
2281 else
2282   echo "$ac_err" >&5
2283   echo "configure: failed program was:" >&5
2284   cat conftest.$ac_ext >&5
2285   rm -rf conftest*
2286   eval "ac_cv_header_$ac_safe=no"
2287 fi
2288 rm -f conftest*
2289 fi
2290 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2291   echo "$ac_t""yes" 1>&6
2292     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2293   cat >> confdefs.h <<EOF
2294 #define $ac_tr_hdr 1
2295 EOF
2296  
2297 else
2298   echo "$ac_t""no" 1>&6
2299 fi
2300 done
2301
2302
2303 echo $ac_n "checking for working const""... $ac_c" 1>&6
2304 echo "configure:2305: checking for working const" >&5
2305 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
2306   echo $ac_n "(cached) $ac_c" 1>&6
2307 else
2308   cat > conftest.$ac_ext <<EOF
2309 #line 2310 "configure"
2310 #include "confdefs.h"
2311
2312 int main() {
2313
2314 /* Ultrix mips cc rejects this.  */
2315 typedef int charset[2]; const charset x;
2316 /* SunOS 4.1.1 cc rejects this.  */
2317 char const *const *ccp;
2318 char **p;
2319 /* NEC SVR4.0.2 mips cc rejects this.  */
2320 struct point {int x, y;};
2321 static struct point const zero = {0,0};
2322 /* AIX XL C 1.02.0.0 rejects this.
2323    It does not let you subtract one const X* pointer from another in an arm
2324    of an if-expression whose if-part is not a constant expression */
2325 const char *g = "string";
2326 ccp = &g + (g ? g-g : 0);
2327 /* HPUX 7.0 cc rejects these. */
2328 ++ccp;
2329 p = (char**) ccp;
2330 ccp = (char const *const *) p;
2331 { /* SCO 3.2v4 cc rejects this.  */
2332   char *t;
2333   char const *s = 0 ? (char *) 0 : (char const *) 0;
2334
2335   *t++ = 0;
2336 }
2337 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
2338   int x[] = {25, 17};
2339   const int *foo = &x[0];
2340   ++foo;
2341 }
2342 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
2343   typedef const int *iptr;
2344   iptr p = 0;
2345   ++p;
2346 }
2347 { /* AIX XL C 1.02.0.0 rejects this saying
2348      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
2349   struct s { int j; const int *ap[3]; };
2350   struct s *b; b->j = 5;
2351 }
2352 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
2353   const int foo = 10;
2354 }
2355
2356 ; return 0; }
2357 EOF
2358 if { (eval echo configure:2359: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2359   rm -rf conftest*
2360   ac_cv_c_const=yes
2361 else
2362   echo "configure: failed program was:" >&5
2363   cat conftest.$ac_ext >&5
2364   rm -rf conftest*
2365   ac_cv_c_const=no
2366 fi
2367 rm -f conftest*
2368 fi
2369
2370 echo "$ac_t""$ac_cv_c_const" 1>&6
2371 if test $ac_cv_c_const = no; then
2372   cat >> confdefs.h <<\EOF
2373 #define const 
2374 EOF
2375
2376 fi
2377
2378 echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
2379 echo "configure:2380: checking for uid_t in sys/types.h" >&5
2380 if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
2381   echo $ac_n "(cached) $ac_c" 1>&6
2382 else
2383   cat > conftest.$ac_ext <<EOF
2384 #line 2385 "configure"
2385 #include "confdefs.h"
2386 #include <sys/types.h>
2387 EOF
2388 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2389   egrep "uid_t" >/dev/null 2>&1; then
2390   rm -rf conftest*
2391   ac_cv_type_uid_t=yes
2392 else
2393   rm -rf conftest*
2394   ac_cv_type_uid_t=no
2395 fi
2396 rm -f conftest*
2397
2398 fi
2399
2400 echo "$ac_t""$ac_cv_type_uid_t" 1>&6
2401 if test $ac_cv_type_uid_t = no; then
2402   cat >> confdefs.h <<\EOF
2403 #define uid_t int
2404 EOF
2405
2406   cat >> confdefs.h <<\EOF
2407 #define gid_t int
2408 EOF
2409
2410 fi
2411
2412 echo $ac_n "checking for off_t""... $ac_c" 1>&6
2413 echo "configure:2414: checking for off_t" >&5
2414 if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
2415   echo $ac_n "(cached) $ac_c" 1>&6
2416 else
2417   cat > conftest.$ac_ext <<EOF
2418 #line 2419 "configure"
2419 #include "confdefs.h"
2420 #include <sys/types.h>
2421 #if STDC_HEADERS
2422 #include <stdlib.h>
2423 #include <stddef.h>
2424 #endif
2425 EOF
2426 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2427   egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2428   rm -rf conftest*
2429   ac_cv_type_off_t=yes
2430 else
2431   rm -rf conftest*
2432   ac_cv_type_off_t=no
2433 fi
2434 rm -f conftest*
2435
2436 fi
2437 echo "$ac_t""$ac_cv_type_off_t" 1>&6
2438 if test $ac_cv_type_off_t = no; then
2439   cat >> confdefs.h <<\EOF
2440 #define off_t long
2441 EOF
2442
2443 fi
2444
2445 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
2446 echo "configure:2447: checking for pid_t" >&5
2447 if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
2448   echo $ac_n "(cached) $ac_c" 1>&6
2449 else
2450   cat > conftest.$ac_ext <<EOF
2451 #line 2452 "configure"
2452 #include "confdefs.h"
2453 #include <sys/types.h>
2454 #if STDC_HEADERS
2455 #include <stdlib.h>
2456 #include <stddef.h>
2457 #endif
2458 EOF
2459 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2460   egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2461   rm -rf conftest*
2462   ac_cv_type_pid_t=yes
2463 else
2464   rm -rf conftest*
2465   ac_cv_type_pid_t=no
2466 fi
2467 rm -f conftest*
2468
2469 fi
2470 echo "$ac_t""$ac_cv_type_pid_t" 1>&6
2471 if test $ac_cv_type_pid_t = no; then
2472   cat >> confdefs.h <<\EOF
2473 #define pid_t int
2474 EOF
2475
2476 fi
2477
2478 echo $ac_n "checking for mode_t""... $ac_c" 1>&6
2479 echo "configure:2480: checking for mode_t" >&5
2480 if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
2481   echo $ac_n "(cached) $ac_c" 1>&6
2482 else
2483   cat > conftest.$ac_ext <<EOF
2484 #line 2485 "configure"
2485 #include "confdefs.h"
2486 #include <sys/types.h>
2487 #if STDC_HEADERS
2488 #include <stdlib.h>
2489 #include <stddef.h>
2490 #endif
2491 EOF
2492 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2493   egrep "(^|[^a-zA-Z_0-9])mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2494   rm -rf conftest*
2495   ac_cv_type_mode_t=yes
2496 else
2497   rm -rf conftest*
2498   ac_cv_type_mode_t=no
2499 fi
2500 rm -f conftest*
2501
2502 fi
2503 echo "$ac_t""$ac_cv_type_mode_t" 1>&6
2504 if test $ac_cv_type_mode_t = no; then
2505   cat >> confdefs.h <<\EOF
2506 #define mode_t int
2507 EOF
2508
2509 fi
2510
2511 echo $ac_n "checking for st_rdev in struct stat""... $ac_c" 1>&6
2512 echo "configure:2513: checking for st_rdev in struct stat" >&5
2513 if eval "test \"`echo '$''{'ac_cv_struct_st_rdev'+set}'`\" = set"; then
2514   echo $ac_n "(cached) $ac_c" 1>&6
2515 else
2516   cat > conftest.$ac_ext <<EOF
2517 #line 2518 "configure"
2518 #include "confdefs.h"
2519 #include <sys/types.h>
2520 #include <sys/stat.h>
2521 int main() {
2522 struct stat s; s.st_rdev;
2523 ; return 0; }
2524 EOF
2525 if { (eval echo configure:2526: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2526   rm -rf conftest*
2527   ac_cv_struct_st_rdev=yes
2528 else
2529   echo "configure: failed program was:" >&5
2530   cat conftest.$ac_ext >&5
2531   rm -rf conftest*
2532   ac_cv_struct_st_rdev=no
2533 fi
2534 rm -f conftest*
2535 fi
2536
2537 echo "$ac_t""$ac_cv_struct_st_rdev" 1>&6
2538 if test $ac_cv_struct_st_rdev = yes; then
2539   cat >> confdefs.h <<\EOF
2540 #define HAVE_ST_RDEV 1
2541 EOF
2542
2543 fi
2544
2545 echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&6
2546 echo "configure:2547: checking whether stat file-mode macros are broken" >&5
2547 if eval "test \"`echo '$''{'ac_cv_header_stat_broken'+set}'`\" = set"; then
2548   echo $ac_n "(cached) $ac_c" 1>&6
2549 else
2550   cat > conftest.$ac_ext <<EOF
2551 #line 2552 "configure"
2552 #include "confdefs.h"
2553 #include <sys/types.h>
2554 #include <sys/stat.h>
2555
2556 #if defined(S_ISBLK) && defined(S_IFDIR)
2557 # if S_ISBLK (S_IFDIR)
2558 You lose.
2559 # endif
2560 #endif
2561
2562 #if defined(S_ISBLK) && defined(S_IFCHR)
2563 # if S_ISBLK (S_IFCHR)
2564 You lose.
2565 # endif
2566 #endif
2567
2568 #if defined(S_ISLNK) && defined(S_IFREG)
2569 # if S_ISLNK (S_IFREG)
2570 You lose.
2571 # endif
2572 #endif
2573
2574 #if defined(S_ISSOCK) && defined(S_IFREG)
2575 # if S_ISSOCK (S_IFREG)
2576 You lose.
2577 # endif
2578 #endif
2579
2580 EOF
2581 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2582   egrep "You lose" >/dev/null 2>&1; then
2583   rm -rf conftest*
2584   ac_cv_header_stat_broken=yes
2585 else
2586   rm -rf conftest*
2587   ac_cv_header_stat_broken=no
2588 fi
2589 rm -f conftest*
2590
2591 fi
2592
2593 echo "$ac_t""$ac_cv_header_stat_broken" 1>&6
2594 if test $ac_cv_header_stat_broken = yes; then
2595   cat >> confdefs.h <<\EOF
2596 #define STAT_MACROS_BROKEN 1
2597 EOF
2598
2599 fi
2600
2601 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
2602 echo "configure:2603: checking whether time.h and sys/time.h may both be included" >&5
2603 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
2604   echo $ac_n "(cached) $ac_c" 1>&6
2605 else
2606   cat > conftest.$ac_ext <<EOF
2607 #line 2608 "configure"
2608 #include "confdefs.h"
2609 #include <sys/types.h>
2610 #include <sys/time.h>
2611 #include <time.h>
2612 int main() {
2613 struct tm *tp;
2614 ; return 0; }
2615 EOF
2616 if { (eval echo configure:2617: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2617   rm -rf conftest*
2618   ac_cv_header_time=yes
2619 else
2620   echo "configure: failed program was:" >&5
2621   cat conftest.$ac_ext >&5
2622   rm -rf conftest*
2623   ac_cv_header_time=no
2624 fi
2625 rm -f conftest*
2626 fi
2627
2628 echo "$ac_t""$ac_cv_header_time" 1>&6
2629 if test $ac_cv_header_time = yes; then
2630   cat >> confdefs.h <<\EOF
2631 #define TIME_WITH_SYS_TIME 1
2632 EOF
2633
2634 fi
2635
2636 echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
2637 echo "configure:2638: checking whether struct tm is in sys/time.h or time.h" >&5
2638 if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
2639   echo $ac_n "(cached) $ac_c" 1>&6
2640 else
2641   cat > conftest.$ac_ext <<EOF
2642 #line 2643 "configure"
2643 #include "confdefs.h"
2644 #include <sys/types.h>
2645 #include <time.h>
2646 int main() {
2647 struct tm *tp; tp->tm_sec;
2648 ; return 0; }
2649 EOF
2650 if { (eval echo configure:2651: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2651   rm -rf conftest*
2652   ac_cv_struct_tm=time.h
2653 else
2654   echo "configure: failed program was:" >&5
2655   cat conftest.$ac_ext >&5
2656   rm -rf conftest*
2657   ac_cv_struct_tm=sys/time.h
2658 fi
2659 rm -f conftest*
2660 fi
2661
2662 echo "$ac_t""$ac_cv_struct_tm" 1>&6
2663 if test $ac_cv_struct_tm = sys/time.h; then
2664   cat >> confdefs.h <<\EOF
2665 #define TM_IN_SYS_TIME 1
2666 EOF
2667
2668 fi
2669
2670
2671 echo $ac_n "checking for pw_age in struct passwd""... $ac_c" 1>&6
2672 echo "configure:2673: checking for pw_age in struct passwd" >&5
2673 if eval "test \"`echo '$''{'ac_cv_struct_passwd_pw_age'+set}'`\" = set"; then
2674   echo $ac_n "(cached) $ac_c" 1>&6
2675 else
2676   cat > conftest.$ac_ext <<EOF
2677 #line 2678 "configure"
2678 #include "confdefs.h"
2679 #include <pwd.h>
2680 int main() {
2681  struct passwd pw;  pw.pw_age = ""; 
2682 ; return 0; }
2683 EOF
2684 if { (eval echo configure:2685: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2685   rm -rf conftest*
2686   ac_cv_struct_passwd_pw_age=yes
2687 else
2688   echo "configure: failed program was:" >&5
2689   cat conftest.$ac_ext >&5
2690   rm -rf conftest*
2691   ac_cv_struct_passwd_pw_age=no
2692 fi
2693 rm -f conftest*
2694 fi
2695
2696 echo "$ac_t""$ac_cv_struct_passwd_pw_age" 1>&6
2697
2698 if test "$ac_cv_struct_passwd_pw_age" = "yes"; then
2699         cat >> confdefs.h <<\EOF
2700 #define ATT_AGE 1
2701 EOF
2702
2703 fi
2704
2705 echo $ac_n "checking for pw_comment in struct passwd""... $ac_c" 1>&6
2706 echo "configure:2707: checking for pw_comment in struct passwd" >&5
2707 if eval "test \"`echo '$''{'ac_cv_struct_passwd_pw_comment'+set}'`\" = set"; then
2708   echo $ac_n "(cached) $ac_c" 1>&6
2709 else
2710   cat > conftest.$ac_ext <<EOF
2711 #line 2712 "configure"
2712 #include "confdefs.h"
2713 #include <pwd.h>
2714 int main() {
2715  struct passwd pw;  pw.pw_comment = ""; 
2716 ; return 0; }
2717 EOF
2718 if { (eval echo configure:2719: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2719   rm -rf conftest*
2720   ac_cv_struct_passwd_pw_comment=yes
2721 else
2722   echo "configure: failed program was:" >&5
2723   cat conftest.$ac_ext >&5
2724   rm -rf conftest*
2725   ac_cv_struct_passwd_pw_comment=no
2726 fi
2727 rm -f conftest*
2728 fi
2729
2730 echo "$ac_t""$ac_cv_struct_passwd_pw_comment" 1>&6
2731
2732 if test "$ac_cv_struct_passwd_pw_comment" = "yes"; then
2733         cat >> confdefs.h <<\EOF
2734 #define ATT_COMMENT 1
2735 EOF
2736
2737 fi
2738
2739 echo $ac_n "checking for pw_quota in struct passwd""... $ac_c" 1>&6
2740 echo "configure:2741: checking for pw_quota in struct passwd" >&5
2741 if eval "test \"`echo '$''{'ac_cv_struct_passwd_pw_quota'+set}'`\" = set"; then
2742   echo $ac_n "(cached) $ac_c" 1>&6
2743 else
2744   cat > conftest.$ac_ext <<EOF
2745 #line 2746 "configure"
2746 #include "confdefs.h"
2747 #include <pwd.h>
2748 int main() {
2749  struct passwd pw;  pw.pw_quota = ""; 
2750 ; return 0; }
2751 EOF
2752 if { (eval echo configure:2753: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2753   rm -rf conftest*
2754   ac_cv_struct_passwd_pw_quota=yes
2755 else
2756   echo "configure: failed program was:" >&5
2757   cat conftest.$ac_ext >&5
2758   rm -rf conftest*
2759   ac_cv_struct_passwd_pw_quota=no
2760 fi
2761 rm -f conftest*
2762 fi
2763
2764 echo "$ac_t""$ac_cv_struct_passwd_pw_quota" 1>&6
2765
2766 if test "$ac_cv_struct_passwd_pw_quota" = "yes"; then
2767         cat >> confdefs.h <<\EOF
2768 #define BSD_QUOTA 1
2769 EOF
2770
2771 fi
2772
2773 if test "$ac_cv_header_utmp_h" = "yes"; then
2774         echo $ac_n "checking for ut_host in struct utmp""... $ac_c" 1>&6
2775 echo "configure:2776: checking for ut_host in struct utmp" >&5
2776 if eval "test \"`echo '$''{'ac_cv_struct_utmp_ut_host'+set}'`\" = set"; then
2777   echo $ac_n "(cached) $ac_c" 1>&6
2778 else
2779   cat > conftest.$ac_ext <<EOF
2780 #line 2781 "configure"
2781 #include "confdefs.h"
2782 #include <utmp.h>
2783 int main() {
2784  struct utmp ut;  char *cp = ut.ut_host; 
2785 ; return 0; }
2786 EOF
2787 if { (eval echo configure:2788: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2788   rm -rf conftest*
2789   ac_cv_struct_utmp_ut_host=yes
2790 else
2791   echo "configure: failed program was:" >&5
2792   cat conftest.$ac_ext >&5
2793   rm -rf conftest*
2794   ac_cv_struct_utmp_ut_host=no
2795 fi
2796 rm -f conftest*
2797 fi
2798
2799 echo "$ac_t""$ac_cv_struct_utmp_ut_host" 1>&6
2800
2801         if test "$ac_cv_struct_utmp_ut_host" = "yes"; then
2802                 cat >> confdefs.h <<\EOF
2803 #define UT_HOST 1
2804 EOF
2805
2806         fi
2807
2808         echo $ac_n "checking for ut_user in struct utmp""... $ac_c" 1>&6
2809 echo "configure:2810: checking for ut_user in struct utmp" >&5
2810 if eval "test \"`echo '$''{'ac_cv_struct_utmp_ut_user'+set}'`\" = set"; then
2811   echo $ac_n "(cached) $ac_c" 1>&6
2812 else
2813   cat > conftest.$ac_ext <<EOF
2814 #line 2815 "configure"
2815 #include "confdefs.h"
2816 #include <utmp.h>
2817 int main() {
2818  struct utmp ut;  char *cp = ut.ut_user; 
2819 ; return 0; }
2820 EOF
2821 if { (eval echo configure:2822: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2822   rm -rf conftest*
2823   ac_cv_struct_utmp_ut_user=yes
2824 else
2825   echo "configure: failed program was:" >&5
2826   cat conftest.$ac_ext >&5
2827   rm -rf conftest*
2828   ac_cv_struct_utmp_ut_user=no
2829 fi
2830 rm -f conftest*
2831 fi
2832
2833 echo "$ac_t""$ac_cv_struct_utmp_ut_user" 1>&6
2834
2835         if test "$ac_cv_struct_utmp_ut_user" = "no"; then
2836                 cat >> confdefs.h <<\EOF
2837 #define ut_user ut_name
2838 EOF
2839
2840         fi
2841 fi
2842
2843 if test "$ac_cv_header_lastlog_h" = "yes"; then
2844         echo $ac_n "checking for ll_host in struct lastlog""... $ac_c" 1>&6
2845 echo "configure:2846: checking for ll_host in struct lastlog" >&5
2846 if eval "test \"`echo '$''{'ac_cv_struct_lastlog_ll_host'+set}'`\" = set"; then
2847   echo $ac_n "(cached) $ac_c" 1>&6
2848 else
2849   cat > conftest.$ac_ext <<EOF
2850 #line 2851 "configure"
2851 #include "confdefs.h"
2852 #include <lastlog.h>
2853 int main() {
2854  struct lastlog ll;  char *cp = ll.ll_host; 
2855 ; return 0; }
2856 EOF
2857 if { (eval echo configure:2858: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2858   rm -rf conftest*
2859   ac_cv_struct_lastlog_ll_host=yes
2860 else
2861   echo "configure: failed program was:" >&5
2862   cat conftest.$ac_ext >&5
2863   rm -rf conftest*
2864   ac_cv_struct_lastlog_ll_host=no
2865 fi
2866 rm -f conftest*
2867 fi
2868
2869 echo "$ac_t""$ac_cv_struct_lastlog_ll_host" 1>&6
2870
2871         if test "$ac_cv_struct_lastlog_ll_host" = "yes"; then
2872                 cat >> confdefs.h <<\EOF
2873 #define HAVE_LL_HOST 1
2874 EOF
2875
2876         fi
2877 fi
2878
2879 echo $ac_n "checking type of array argument to getgroups""... $ac_c" 1>&6
2880 echo "configure:2881: checking type of array argument to getgroups" >&5
2881 if eval "test \"`echo '$''{'ac_cv_type_getgroups'+set}'`\" = set"; then
2882   echo $ac_n "(cached) $ac_c" 1>&6
2883 else
2884   if test "$cross_compiling" = yes; then
2885   ac_cv_type_getgroups=cross
2886 else
2887   cat > conftest.$ac_ext <<EOF
2888 #line 2889 "configure"
2889 #include "confdefs.h"
2890
2891 /* Thanks to Mike Rendell for this test.  */
2892 #include <sys/types.h>
2893 #define NGID 256
2894 #undef MAX
2895 #define MAX(x, y) ((x) > (y) ? (x) : (y))
2896 main()
2897 {
2898   gid_t gidset[NGID];
2899   int i, n;
2900   union { gid_t gval; long lval; }  val;
2901
2902   val.lval = -1;
2903   for (i = 0; i < NGID; i++)
2904     gidset[i] = val.gval;
2905   n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
2906                  gidset);
2907   /* Exit non-zero if getgroups seems to require an array of ints.  This
2908      happens when gid_t is short but getgroups modifies an array of ints.  */
2909   exit ((n > 0 && gidset[n] != val.gval) ? 1 : 0);
2910 }
2911
2912 EOF
2913 if { (eval echo configure:2914: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2914 then
2915     ac_cv_type_getgroups=gid_t
2916 else
2917   echo "configure: failed program was:" >&5
2918   cat conftest.$ac_ext >&5
2919   rm -fr conftest*
2920   ac_cv_type_getgroups=int
2921 fi
2922 rm -fr conftest*
2923 fi
2924
2925 if test $ac_cv_type_getgroups = cross; then
2926         cat > conftest.$ac_ext <<EOF
2927 #line 2928 "configure"
2928 #include "confdefs.h"
2929 #include <unistd.h>
2930 EOF
2931 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2932   egrep "getgroups.*int.*gid_t" >/dev/null 2>&1; then
2933   rm -rf conftest*
2934   ac_cv_type_getgroups=gid_t
2935 else
2936   rm -rf conftest*
2937   ac_cv_type_getgroups=int
2938 fi
2939 rm -f conftest*
2940
2941 fi
2942 fi
2943
2944 echo "$ac_t""$ac_cv_type_getgroups" 1>&6
2945 cat >> confdefs.h <<EOF
2946 #define GETGROUPS_T $ac_cv_type_getgroups
2947 EOF
2948
2949
2950 if test $ac_cv_prog_gcc = yes; then
2951     echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6
2952 echo "configure:2953: checking whether ${CC-cc} needs -traditional" >&5
2953 if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then
2954   echo $ac_n "(cached) $ac_c" 1>&6
2955 else
2956     ac_pattern="Autoconf.*'x'"
2957   cat > conftest.$ac_ext <<EOF
2958 #line 2959 "configure"
2959 #include "confdefs.h"
2960 #include <sgtty.h>
2961 Autoconf TIOCGETP
2962 EOF
2963 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2964   egrep "$ac_pattern" >/dev/null 2>&1; then
2965   rm -rf conftest*
2966   ac_cv_prog_gcc_traditional=yes
2967 else
2968   rm -rf conftest*
2969   ac_cv_prog_gcc_traditional=no
2970 fi
2971 rm -f conftest*
2972
2973
2974   if test $ac_cv_prog_gcc_traditional = no; then
2975     cat > conftest.$ac_ext <<EOF
2976 #line 2977 "configure"
2977 #include "confdefs.h"
2978 #include <termio.h>
2979 Autoconf TCGETA
2980 EOF
2981 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2982   egrep "$ac_pattern" >/dev/null 2>&1; then
2983   rm -rf conftest*
2984   ac_cv_prog_gcc_traditional=yes
2985 fi
2986 rm -f conftest*
2987
2988   fi
2989 fi
2990
2991 echo "$ac_t""$ac_cv_prog_gcc_traditional" 1>&6
2992   if test $ac_cv_prog_gcc_traditional = yes; then
2993     CC="$CC -traditional"
2994   fi
2995 fi
2996
2997 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
2998 echo "configure:2999: checking return type of signal handlers" >&5
2999 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
3000   echo $ac_n "(cached) $ac_c" 1>&6
3001 else
3002   cat > conftest.$ac_ext <<EOF
3003 #line 3004 "configure"
3004 #include "confdefs.h"
3005 #include <sys/types.h>
3006 #include <signal.h>
3007 #ifdef signal
3008 #undef signal
3009 #endif
3010 #ifdef __cplusplus
3011 extern "C" void (*signal (int, void (*)(int)))(int);
3012 #else
3013 void (*signal ()) ();
3014 #endif
3015
3016 int main() {
3017 int i;
3018 ; return 0; }
3019 EOF
3020 if { (eval echo configure:3021: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3021   rm -rf conftest*
3022   ac_cv_type_signal=void
3023 else
3024   echo "configure: failed program was:" >&5
3025   cat conftest.$ac_ext >&5
3026   rm -rf conftest*
3027   ac_cv_type_signal=int
3028 fi
3029 rm -f conftest*
3030 fi
3031
3032 echo "$ac_t""$ac_cv_type_signal" 1>&6
3033 cat >> confdefs.h <<EOF
3034 #define RETSIGTYPE $ac_cv_type_signal
3035 EOF
3036
3037
3038 echo $ac_n "checking whether utime accepts a null argument""... $ac_c" 1>&6
3039 echo "configure:3040: checking whether utime accepts a null argument" >&5
3040 if eval "test \"`echo '$''{'ac_cv_func_utime_null'+set}'`\" = set"; then
3041   echo $ac_n "(cached) $ac_c" 1>&6
3042 else
3043   rm -f conftestdata; > conftestdata
3044 # Sequent interprets utime(file, 0) to mean use start of epoch.  Wrong.
3045 if test "$cross_compiling" = yes; then
3046   ac_cv_func_utime_null=no
3047 else
3048   cat > conftest.$ac_ext <<EOF
3049 #line 3050 "configure"
3050 #include "confdefs.h"
3051 #include <sys/types.h>
3052 #include <sys/stat.h>
3053 main() {
3054 struct stat s, t;
3055 exit(!(stat ("conftestdata", &s) == 0 && utime("conftestdata", (long *)0) == 0
3056 && stat("conftestdata", &t) == 0 && t.st_mtime >= s.st_mtime
3057 && t.st_mtime - s.st_mtime < 120));
3058 }
3059 EOF
3060 if { (eval echo configure:3061: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3061 then
3062   ac_cv_func_utime_null=yes
3063 else
3064   echo "configure: failed program was:" >&5
3065   cat conftest.$ac_ext >&5
3066   rm -fr conftest*
3067   ac_cv_func_utime_null=no
3068 fi
3069 rm -fr conftest*
3070 fi
3071
3072 rm -f core core.* *.core
3073 fi
3074
3075 echo "$ac_t""$ac_cv_func_utime_null" 1>&6
3076 if test $ac_cv_func_utime_null = yes; then
3077   cat >> confdefs.h <<\EOF
3078 #define HAVE_UTIME_NULL 1
3079 EOF
3080
3081 fi
3082
3083 echo $ac_n "checking for strftime""... $ac_c" 1>&6
3084 echo "configure:3085: checking for strftime" >&5
3085 if eval "test \"`echo '$''{'ac_cv_func_strftime'+set}'`\" = set"; then
3086   echo $ac_n "(cached) $ac_c" 1>&6
3087 else
3088   cat > conftest.$ac_ext <<EOF
3089 #line 3090 "configure"
3090 #include "confdefs.h"
3091 /* System header to define __stub macros and hopefully few prototypes,
3092     which can conflict with char strftime(); below.  */
3093 #include <assert.h>
3094 /* Override any gcc2 internal prototype to avoid an error.  */
3095 /* We use char because int might match the return type of a gcc2
3096     builtin and then its argument prototype would still apply.  */
3097 char strftime();
3098
3099 int main() {
3100
3101 /* The GNU C library defines this for functions which it implements
3102     to always fail with ENOSYS.  Some functions are actually named
3103     something starting with __ and the normal name is an alias.  */
3104 #if defined (__stub_strftime) || defined (__stub___strftime)
3105 choke me
3106 #else
3107 strftime();
3108 #endif
3109
3110 ; return 0; }
3111 EOF
3112 if { (eval echo configure:3113: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3113   rm -rf conftest*
3114   eval "ac_cv_func_strftime=yes"
3115 else
3116   echo "configure: failed program was:" >&5
3117   cat conftest.$ac_ext >&5
3118   rm -rf conftest*
3119   eval "ac_cv_func_strftime=no"
3120 fi
3121 rm -f conftest*
3122 fi
3123
3124 if eval "test \"`echo '$ac_cv_func_'strftime`\" = yes"; then
3125   echo "$ac_t""yes" 1>&6
3126   cat >> confdefs.h <<\EOF
3127 #define HAVE_STRFTIME 1
3128 EOF
3129
3130 else
3131   echo "$ac_t""no" 1>&6
3132 # strftime is in -lintl on SCO UNIX.
3133 echo $ac_n "checking for strftime in -lintl""... $ac_c" 1>&6
3134 echo "configure:3135: checking for strftime in -lintl" >&5
3135 ac_lib_var=`echo intl'_'strftime | sed 'y%./+-%__p_%'`
3136 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3137   echo $ac_n "(cached) $ac_c" 1>&6
3138 else
3139   ac_save_LIBS="$LIBS"
3140 LIBS="-lintl  $LIBS"
3141 cat > conftest.$ac_ext <<EOF
3142 #line 3143 "configure"
3143 #include "confdefs.h"
3144 /* Override any gcc2 internal prototype to avoid an error.  */
3145 /* We use char because int might match the return type of a gcc2
3146     builtin and then its argument prototype would still apply.  */
3147 char strftime();
3148
3149 int main() {
3150 strftime()
3151 ; return 0; }
3152 EOF
3153 if { (eval echo configure:3154: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3154   rm -rf conftest*
3155   eval "ac_cv_lib_$ac_lib_var=yes"
3156 else
3157   echo "configure: failed program was:" >&5
3158   cat conftest.$ac_ext >&5
3159   rm -rf conftest*
3160   eval "ac_cv_lib_$ac_lib_var=no"
3161 fi
3162 rm -f conftest*
3163 LIBS="$ac_save_LIBS"
3164
3165 fi
3166 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3167   echo "$ac_t""yes" 1>&6
3168   cat >> confdefs.h <<\EOF
3169 #define HAVE_STRFTIME 1
3170 EOF
3171
3172 LIBS="-lintl $LIBS"
3173 else
3174   echo "$ac_t""no" 1>&6
3175 fi
3176
3177 fi
3178
3179 for ac_func in a64l fchmod fchown fsync getgroups gethostname getspnam
3180 do
3181 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3182 echo "configure:3183: checking for $ac_func" >&5
3183 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3184   echo $ac_n "(cached) $ac_c" 1>&6
3185 else
3186   cat > conftest.$ac_ext <<EOF
3187 #line 3188 "configure"
3188 #include "confdefs.h"
3189 /* System header to define __stub macros and hopefully few prototypes,
3190     which can conflict with char $ac_func(); below.  */
3191 #include <assert.h>
3192 /* Override any gcc2 internal prototype to avoid an error.  */
3193 /* We use char because int might match the return type of a gcc2
3194     builtin and then its argument prototype would still apply.  */
3195 char $ac_func();
3196
3197 int main() {
3198
3199 /* The GNU C library defines this for functions which it implements
3200     to always fail with ENOSYS.  Some functions are actually named
3201     something starting with __ and the normal name is an alias.  */
3202 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3203 choke me
3204 #else
3205 $ac_func();
3206 #endif
3207
3208 ; return 0; }
3209 EOF
3210 if { (eval echo configure:3211: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3211   rm -rf conftest*
3212   eval "ac_cv_func_$ac_func=yes"
3213 else
3214   echo "configure: failed program was:" >&5
3215   cat conftest.$ac_ext >&5
3216   rm -rf conftest*
3217   eval "ac_cv_func_$ac_func=no"
3218 fi
3219 rm -f conftest*
3220 fi
3221
3222 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3223   echo "$ac_t""yes" 1>&6
3224     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3225   cat >> confdefs.h <<EOF
3226 #define $ac_tr_func 1
3227 EOF
3228  
3229 else
3230   echo "$ac_t""no" 1>&6
3231 fi
3232 done
3233
3234 for ac_func in gettimeofday getusershell getutent initgroups lchown lckpwdf
3235 do
3236 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3237 echo "configure:3238: checking for $ac_func" >&5
3238 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3239   echo $ac_n "(cached) $ac_c" 1>&6
3240 else
3241   cat > conftest.$ac_ext <<EOF
3242 #line 3243 "configure"
3243 #include "confdefs.h"
3244 /* System header to define __stub macros and hopefully few prototypes,
3245     which can conflict with char $ac_func(); below.  */
3246 #include <assert.h>
3247 /* Override any gcc2 internal prototype to avoid an error.  */
3248 /* We use char because int might match the return type of a gcc2
3249     builtin and then its argument prototype would still apply.  */
3250 char $ac_func();
3251
3252 int main() {
3253
3254 /* The GNU C library defines this for functions which it implements
3255     to always fail with ENOSYS.  Some functions are actually named
3256     something starting with __ and the normal name is an alias.  */
3257 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3258 choke me
3259 #else
3260 $ac_func();
3261 #endif
3262
3263 ; return 0; }
3264 EOF
3265 if { (eval echo configure:3266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3266   rm -rf conftest*
3267   eval "ac_cv_func_$ac_func=yes"
3268 else
3269   echo "configure: failed program was:" >&5
3270   cat conftest.$ac_ext >&5
3271   rm -rf conftest*
3272   eval "ac_cv_func_$ac_func=no"
3273 fi
3274 rm -f conftest*
3275 fi
3276
3277 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3278   echo "$ac_t""yes" 1>&6
3279     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3280   cat >> confdefs.h <<EOF
3281 #define $ac_tr_func 1
3282 EOF
3283  
3284 else
3285   echo "$ac_t""no" 1>&6
3286 fi
3287 done
3288
3289 for ac_func in lstat memcpy memset setgroups sigaction strchr updwtmp updwtmpx
3290 do
3291 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3292 echo "configure:3293: checking for $ac_func" >&5
3293 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3294   echo $ac_n "(cached) $ac_c" 1>&6
3295 else
3296   cat > conftest.$ac_ext <<EOF
3297 #line 3298 "configure"
3298 #include "confdefs.h"
3299 /* System header to define __stub macros and hopefully few prototypes,
3300     which can conflict with char $ac_func(); below.  */
3301 #include <assert.h>
3302 /* Override any gcc2 internal prototype to avoid an error.  */
3303 /* We use char because int might match the return type of a gcc2
3304     builtin and then its argument prototype would still apply.  */
3305 char $ac_func();
3306
3307 int main() {
3308
3309 /* The GNU C library defines this for functions which it implements
3310     to always fail with ENOSYS.  Some functions are actually named
3311     something starting with __ and the normal name is an alias.  */
3312 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3313 choke me
3314 #else
3315 $ac_func();
3316 #endif
3317
3318 ; return 0; }
3319 EOF
3320 if { (eval echo configure:3321: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3321   rm -rf conftest*
3322   eval "ac_cv_func_$ac_func=yes"
3323 else
3324   echo "configure: failed program was:" >&5
3325   cat conftest.$ac_ext >&5
3326   rm -rf conftest*
3327   eval "ac_cv_func_$ac_func=no"
3328 fi
3329 rm -f conftest*
3330 fi
3331
3332 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3333   echo "$ac_t""yes" 1>&6
3334     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3335   cat >> confdefs.h <<EOF
3336 #define $ac_tr_func 1
3337 EOF
3338  
3339 else
3340   echo "$ac_t""no" 1>&6
3341 fi
3342 done
3343
3344
3345 for ac_func in mkdir putgrent putpwent putspent rename rmdir
3346 do
3347 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3348 echo "configure:3349: checking for $ac_func" >&5
3349 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3350   echo $ac_n "(cached) $ac_c" 1>&6
3351 else
3352   cat > conftest.$ac_ext <<EOF
3353 #line 3354 "configure"
3354 #include "confdefs.h"
3355 /* System header to define __stub macros and hopefully few prototypes,
3356     which can conflict with char $ac_func(); below.  */
3357 #include <assert.h>
3358 /* Override any gcc2 internal prototype to avoid an error.  */
3359 /* We use char because int might match the return type of a gcc2
3360     builtin and then its argument prototype would still apply.  */
3361 char $ac_func();
3362
3363 int main() {
3364
3365 /* The GNU C library defines this for functions which it implements
3366     to always fail with ENOSYS.  Some functions are actually named
3367     something starting with __ and the normal name is an alias.  */
3368 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3369 choke me
3370 #else
3371 $ac_func();
3372 #endif
3373
3374 ; return 0; }
3375 EOF
3376 if { (eval echo configure:3377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3377   rm -rf conftest*
3378   eval "ac_cv_func_$ac_func=yes"
3379 else
3380   echo "configure: failed program was:" >&5
3381   cat conftest.$ac_ext >&5
3382   rm -rf conftest*
3383   eval "ac_cv_func_$ac_func=no"
3384 fi
3385 rm -f conftest*
3386 fi
3387
3388 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3389   echo "$ac_t""yes" 1>&6
3390     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3391   cat >> confdefs.h <<EOF
3392 #define $ac_tr_func 1
3393 EOF
3394  
3395 else
3396   echo "$ac_t""no" 1>&6
3397 LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
3398 fi
3399 done
3400
3401
3402 for ac_func in sgetgrent sgetpwent sgetspent
3403 do
3404 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3405 echo "configure:3406: checking for $ac_func" >&5
3406 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3407   echo $ac_n "(cached) $ac_c" 1>&6
3408 else
3409   cat > conftest.$ac_ext <<EOF
3410 #line 3411 "configure"
3411 #include "confdefs.h"
3412 /* System header to define __stub macros and hopefully few prototypes,
3413     which can conflict with char $ac_func(); below.  */
3414 #include <assert.h>
3415 /* Override any gcc2 internal prototype to avoid an error.  */
3416 /* We use char because int might match the return type of a gcc2
3417     builtin and then its argument prototype would still apply.  */
3418 char $ac_func();
3419
3420 int main() {
3421
3422 /* The GNU C library defines this for functions which it implements
3423     to always fail with ENOSYS.  Some functions are actually named
3424     something starting with __ and the normal name is an alias.  */
3425 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3426 choke me
3427 #else
3428 $ac_func();
3429 #endif
3430
3431 ; return 0; }
3432 EOF
3433 if { (eval echo configure:3434: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3434   rm -rf conftest*
3435   eval "ac_cv_func_$ac_func=yes"
3436 else
3437   echo "configure: failed program was:" >&5
3438   cat conftest.$ac_ext >&5
3439   rm -rf conftest*
3440   eval "ac_cv_func_$ac_func=no"
3441 fi
3442 rm -f conftest*
3443 fi
3444
3445 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3446   echo "$ac_t""yes" 1>&6
3447     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3448   cat >> confdefs.h <<EOF
3449 #define $ac_tr_func 1
3450 EOF
3451  
3452 else
3453   echo "$ac_t""no" 1>&6
3454 LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
3455 fi
3456 done
3457
3458
3459 for ac_func in snprintf strcasecmp strdup strerror strstr
3460 do
3461 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3462 echo "configure:3463: checking for $ac_func" >&5
3463 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3464   echo $ac_n "(cached) $ac_c" 1>&6
3465 else
3466   cat > conftest.$ac_ext <<EOF
3467 #line 3468 "configure"
3468 #include "confdefs.h"
3469 /* System header to define __stub macros and hopefully few prototypes,
3470     which can conflict with char $ac_func(); below.  */
3471 #include <assert.h>
3472 /* Override any gcc2 internal prototype to avoid an error.  */
3473 /* We use char because int might match the return type of a gcc2
3474     builtin and then its argument prototype would still apply.  */
3475 char $ac_func();
3476
3477 int main() {
3478
3479 /* The GNU C library defines this for functions which it implements
3480     to always fail with ENOSYS.  Some functions are actually named
3481     something starting with __ and the normal name is an alias.  */
3482 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3483 choke me
3484 #else
3485 $ac_func();
3486 #endif
3487
3488 ; return 0; }
3489 EOF
3490 if { (eval echo configure:3491: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3491   rm -rf conftest*
3492   eval "ac_cv_func_$ac_func=yes"
3493 else
3494   echo "configure: failed program was:" >&5
3495   cat conftest.$ac_ext >&5
3496   rm -rf conftest*
3497   eval "ac_cv_func_$ac_func=no"
3498 fi
3499 rm -f conftest*
3500 fi
3501
3502 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3503   echo "$ac_t""yes" 1>&6
3504     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3505   cat >> confdefs.h <<EOF
3506 #define $ac_tr_func 1
3507 EOF
3508  
3509 else
3510   echo "$ac_t""no" 1>&6
3511 LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
3512 fi
3513 done
3514
3515
3516
3517 echo $ac_n "checking for setpgrp""... $ac_c" 1>&6
3518 echo "configure:3519: checking for setpgrp" >&5
3519 if eval "test \"`echo '$''{'ac_cv_func_setpgrp'+set}'`\" = set"; then
3520   echo $ac_n "(cached) $ac_c" 1>&6
3521 else
3522   cat > conftest.$ac_ext <<EOF
3523 #line 3524 "configure"
3524 #include "confdefs.h"
3525 /* System header to define __stub macros and hopefully few prototypes,
3526     which can conflict with char setpgrp(); below.  */
3527 #include <assert.h>
3528 /* Override any gcc2 internal prototype to avoid an error.  */
3529 /* We use char because int might match the return type of a gcc2
3530     builtin and then its argument prototype would still apply.  */
3531 char setpgrp();
3532
3533 int main() {
3534
3535 /* The GNU C library defines this for functions which it implements
3536     to always fail with ENOSYS.  Some functions are actually named
3537     something starting with __ and the normal name is an alias.  */
3538 #if defined (__stub_setpgrp) || defined (__stub___setpgrp)
3539 choke me
3540 #else
3541 setpgrp();
3542 #endif
3543
3544 ; return 0; }
3545 EOF
3546 if { (eval echo configure:3547: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3547   rm -rf conftest*
3548   eval "ac_cv_func_setpgrp=yes"
3549 else
3550   echo "configure: failed program was:" >&5
3551   cat conftest.$ac_ext >&5
3552   rm -rf conftest*
3553   eval "ac_cv_func_setpgrp=no"
3554 fi
3555 rm -f conftest*
3556 fi
3557
3558 if eval "test \"`echo '$ac_cv_func_'setpgrp`\" = yes"; then
3559   echo "$ac_t""yes" 1>&6
3560   :
3561 else
3562   echo "$ac_t""no" 1>&6
3563 fi
3564
3565 echo $ac_n "checking whether setpgrp takes no argument""... $ac_c" 1>&6
3566 echo "configure:3567: checking whether setpgrp takes no argument" >&5
3567 if eval "test \"`echo '$''{'ac_cv_func_setpgrp_void'+set}'`\" = set"; then
3568   echo $ac_n "(cached) $ac_c" 1>&6
3569 else
3570   if test "$cross_compiling" = yes; then
3571   { echo "configure: error: cannot check setpgrp if cross compiling" 1>&2; exit 1; }
3572 else
3573   cat > conftest.$ac_ext <<EOF
3574 #line 3575 "configure"
3575 #include "confdefs.h"
3576
3577 #ifdef HAVE_UNISTD_H
3578 #include <unistd.h>
3579 #endif
3580
3581 /*
3582  * If this system has a BSD-style setpgrp, which takes arguments, exit
3583  * successfully.
3584  */
3585 main()
3586 {
3587     if (setpgrp(1,1) == -1)
3588         exit(0);
3589     else
3590         exit(1);
3591 }
3592
3593 EOF
3594 if { (eval echo configure:3595: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3595 then
3596   ac_cv_func_setpgrp_void=no
3597 else
3598   echo "configure: failed program was:" >&5
3599   cat conftest.$ac_ext >&5
3600   rm -fr conftest*
3601   ac_cv_func_setpgrp_void=yes
3602 fi
3603 rm -fr conftest*
3604 fi
3605
3606
3607 fi
3608
3609 echo "$ac_t""$ac_cv_func_setpgrp_void" 1>&6
3610 if test $ac_cv_func_setpgrp_void = yes; then
3611   cat >> confdefs.h <<\EOF
3612 #define SETPGRP_VOID 1
3613 EOF
3614
3615 fi
3616
3617
3618 if test "$ac_cv_header_shadow_h" = "yes"; then
3619 echo $ac_n "checking for working shadow group support""... $ac_c" 1>&6
3620 echo "configure:3621: checking for working shadow group support" >&5
3621 if eval "test \"`echo '$''{'ac_cv_libc_shadowgrp'+set}'`\" = set"; then
3622   echo $ac_n "(cached) $ac_c" 1>&6
3623 else
3624   if test "$cross_compiling" = yes; then
3625   ac_cv_libc_shadowgrp=no
3626 else
3627   cat > conftest.$ac_ext <<EOF
3628 #line 3629 "configure"
3629 #include "confdefs.h"
3630
3631 #include <shadow.h>
3632 main()
3633 {
3634         struct sgrp *sg = sgetsgent("test:x::");
3635         /* NYS libc on Red Hat 3.0.3 has broken shadow group support */
3636         return !sg || !sg->sg_adm || !sg->sg_mem;
3637 }
3638
3639 EOF
3640 if { (eval echo configure:3641: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3641 then
3642   ac_cv_libc_shadowgrp=yes
3643 else
3644   echo "configure: failed program was:" >&5
3645   cat conftest.$ac_ext >&5
3646   rm -fr conftest*
3647   ac_cv_libc_shadowgrp=no
3648 fi
3649 rm -fr conftest*
3650 fi
3651
3652 fi
3653
3654 echo "$ac_t""$ac_cv_libc_shadowgrp" 1>&6
3655
3656 if test "$ac_cv_libc_shadowgrp" = "yes"; then
3657         cat >> confdefs.h <<\EOF
3658 #define HAVE_SHADOWGRP 1
3659 EOF
3660
3661 fi
3662 fi
3663
3664 echo $ac_n "checking location of shared mail directory""... $ac_c" 1>&6
3665 echo "configure:3666: checking location of shared mail directory" >&5
3666 for maildir in /var/spool/mail /var/mail /usr/spool/mail /usr/mail NONE; do
3667         if test "$maildir" = "NONE"; then
3668                 echo "$ac_t""None" 1>&6
3669         elif test -d $maildir; then
3670                 cat >> confdefs.h <<EOF
3671 #define MAIL_SPOOL_DIR "$maildir"
3672 EOF
3673
3674                 echo "$ac_t""$maildir" 1>&6
3675                 break
3676         fi
3677 done
3678
3679 echo $ac_n "checking location of user mail file""... $ac_c" 1>&6
3680 echo "configure:3681: checking location of user mail file" >&5
3681 for mailfile in Mailbox mailbox Mail mail .mail NONE; do
3682         if test "$mailfile" = "NONE"; then
3683                 echo "$ac_t""None" 1>&6
3684         elif test -f $HOME/$mailfile; then
3685                 cat >> confdefs.h <<EOF
3686 #define MAIL_SPOOL_FILE "$mailfile"
3687 EOF
3688
3689                 echo "$ac_t""$mailfile" 1>&6
3690                 break
3691         fi
3692 done
3693
3694 echo $ac_n "checking location of utmp""... $ac_c" 1>&6
3695 echo "configure:3696: checking location of utmp" >&5
3696 for utmpdir in /var/run /var/adm /usr/adm /etc NONE; do
3697         if test "$utmpdir" = "NONE"; then
3698                 echo "configure: warning: utmp file not found" 1>&2
3699         elif test -f $utmpdir/utmp; then
3700                 cat >> confdefs.h <<EOF
3701 #define _UTMP_FILE "$utmpdir/utmp"
3702 EOF
3703
3704                 echo "$ac_t""$utmpdir" 1>&6
3705                 break
3706         fi
3707 done
3708
3709 echo $ac_n "checking location of faillog/lastlog/wtmp""... $ac_c" 1>&6
3710 echo "configure:3711: checking location of faillog/lastlog/wtmp" >&5
3711 for logdir in /var/log /var/adm /usr/adm /etc; do
3712         if test -d $logdir; then
3713                 cat >> confdefs.h <<EOF
3714 #define _WTMP_FILE "$logdir/wtmp"
3715 EOF
3716
3717                 cat >> confdefs.h <<EOF
3718 #define LASTLOG_FILE "$logdir/lastlog"
3719 EOF
3720
3721                 cat >> confdefs.h <<EOF
3722 #define FAILLOG_FILE "$logdir/faillog"
3723 EOF
3724
3725                 echo "$ac_t""$logdir" 1>&6
3726                 break
3727         fi
3728 done
3729
3730 echo $ac_n "checking location of the passwd program""... $ac_c" 1>&6
3731 echo "configure:3732: checking location of the passwd program" >&5
3732 if test -f /usr/bin/passwd; then
3733         passwd_dir=/usr/bin
3734 else
3735         passwd_dir=/bin
3736 fi
3737 cat >> confdefs.h <<EOF
3738 #define PASSWD_PROGRAM "$passwd_dir/passwd"
3739 EOF
3740
3741 echo "$ac_t""$passwd_dir" 1>&6
3742
3743 cat >> confdefs.h <<\EOF
3744 #define SHADOWPWD 1
3745 EOF
3746
3747 cat >> confdefs.h <<\EOF
3748 #define USG 1
3749 EOF
3750
3751 cat >> confdefs.h <<\EOF
3752 #define AGING 1
3753 EOF
3754
3755 cat >> confdefs.h <<\EOF
3756 #define USE_SYSLOG 1
3757 EOF
3758
3759 cat >> confdefs.h <<\EOF
3760 #define RLOGIN 1
3761 EOF
3762
3763 cat >> confdefs.h <<\EOF
3764 #define RUSEROK 0
3765 EOF
3766
3767 cat >> confdefs.h <<\EOF
3768 #define LOGIN_ACCESS 1
3769 EOF
3770
3771 cat >> confdefs.h <<\EOF
3772 #define SU_ACCESS 1
3773 EOF
3774
3775
3776 cat >> confdefs.h <<\EOF
3777 #define getpass libshadow_getpass
3778 EOF
3779
3780
3781 # Check whether --enable-desrpc or --disable-desrpc was given.
3782 if test "${enable_desrpc+set}" = set; then
3783   enableval="$enable_desrpc"
3784   :
3785 fi
3786
3787 # Check whether --enable-shadowgrp or --disable-shadowgrp was given.
3788 if test "${enable_shadowgrp+set}" = set; then
3789   enableval="$enable_shadowgrp"
3790   :
3791 fi
3792
3793
3794 # Check whether --with-libcrack or --without-libcrack was given.
3795 if test "${with_libcrack+set}" = set; then
3796   withval="$with_libcrack"
3797   :
3798 fi
3799
3800 # Check whether --with-libcrypt or --without-libcrypt was given.
3801 if test "${with_libcrypt+set}" = set; then
3802   withval="$with_libcrypt"
3803   :
3804 fi
3805
3806 # Check whether --with-libopie or --without-libopie was given.
3807 if test "${with_libopie+set}" = set; then
3808   withval="$with_libopie"
3809   :
3810 fi
3811
3812 # Check whether --with-libpam or --without-libpam was given.
3813 if test "${with_libpam+set}" = set; then
3814   withval="$with_libpam"
3815   :
3816 fi
3817
3818 # Check whether --with-libskey or --without-libskey was given.
3819 if test "${with_libskey+set}" = set; then
3820   withval="$with_libskey"
3821   :
3822 fi
3823
3824 # Check whether --with-libtcfs or --without-libtcfs was given.
3825 if test "${with_libtcfs+set}" = set; then
3826   withval="$with_libtcfs"
3827   :
3828 fi
3829
3830
3831
3832 echo $ac_n "checking for inet_ntoa""... $ac_c" 1>&6
3833 echo "configure:3834: checking for inet_ntoa" >&5
3834 if eval "test \"`echo '$''{'ac_cv_func_inet_ntoa'+set}'`\" = set"; then
3835   echo $ac_n "(cached) $ac_c" 1>&6
3836 else
3837   cat > conftest.$ac_ext <<EOF
3838 #line 3839 "configure"
3839 #include "confdefs.h"
3840 /* System header to define __stub macros and hopefully few prototypes,
3841     which can conflict with char inet_ntoa(); below.  */
3842 #include <assert.h>
3843 /* Override any gcc2 internal prototype to avoid an error.  */
3844 /* We use char because int might match the return type of a gcc2
3845     builtin and then its argument prototype would still apply.  */
3846 char inet_ntoa();
3847
3848 int main() {
3849
3850 /* The GNU C library defines this for functions which it implements
3851     to always fail with ENOSYS.  Some functions are actually named
3852     something starting with __ and the normal name is an alias.  */
3853 #if defined (__stub_inet_ntoa) || defined (__stub___inet_ntoa)
3854 choke me
3855 #else
3856 inet_ntoa();
3857 #endif
3858
3859 ; return 0; }
3860 EOF
3861 if { (eval echo configure:3862: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3862   rm -rf conftest*
3863   eval "ac_cv_func_inet_ntoa=yes"
3864 else
3865   echo "configure: failed program was:" >&5
3866   cat conftest.$ac_ext >&5
3867   rm -rf conftest*
3868   eval "ac_cv_func_inet_ntoa=no"
3869 fi
3870 rm -f conftest*
3871 fi
3872
3873 if eval "test \"`echo '$ac_cv_func_'inet_ntoa`\" = yes"; then
3874   echo "$ac_t""yes" 1>&6
3875   :
3876 else
3877   echo "$ac_t""no" 1>&6
3878 echo $ac_n "checking for inet_ntoa in -linet""... $ac_c" 1>&6
3879 echo "configure:3880: checking for inet_ntoa in -linet" >&5
3880 ac_lib_var=`echo inet'_'inet_ntoa | sed 'y%./+-%__p_%'`
3881 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3882   echo $ac_n "(cached) $ac_c" 1>&6
3883 else
3884   ac_save_LIBS="$LIBS"
3885 LIBS="-linet  $LIBS"
3886 cat > conftest.$ac_ext <<EOF
3887 #line 3888 "configure"
3888 #include "confdefs.h"
3889 /* Override any gcc2 internal prototype to avoid an error.  */
3890 /* We use char because int might match the return type of a gcc2
3891     builtin and then its argument prototype would still apply.  */
3892 char inet_ntoa();
3893
3894 int main() {
3895 inet_ntoa()
3896 ; return 0; }
3897 EOF
3898 if { (eval echo configure:3899: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3899   rm -rf conftest*
3900   eval "ac_cv_lib_$ac_lib_var=yes"
3901 else
3902   echo "configure: failed program was:" >&5
3903   cat conftest.$ac_ext >&5
3904   rm -rf conftest*
3905   eval "ac_cv_lib_$ac_lib_var=no"
3906 fi
3907 rm -f conftest*
3908 LIBS="$ac_save_LIBS"
3909
3910 fi
3911 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3912   echo "$ac_t""yes" 1>&6
3913     ac_tr_lib=HAVE_LIB`echo inet | sed -e 's/^a-zA-Z0-9_/_/g' \
3914     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
3915   cat >> confdefs.h <<EOF
3916 #define $ac_tr_lib 1
3917 EOF
3918
3919   LIBS="-linet $LIBS"
3920
3921 else
3922   echo "$ac_t""no" 1>&6
3923 fi
3924
3925 fi
3926
3927 echo $ac_n "checking for socket""... $ac_c" 1>&6
3928 echo "configure:3929: checking for socket" >&5
3929 if eval "test \"`echo '$''{'ac_cv_func_socket'+set}'`\" = set"; then
3930   echo $ac_n "(cached) $ac_c" 1>&6
3931 else
3932   cat > conftest.$ac_ext <<EOF
3933 #line 3934 "configure"
3934 #include "confdefs.h"
3935 /* System header to define __stub macros and hopefully few prototypes,
3936     which can conflict with char socket(); below.  */
3937 #include <assert.h>
3938 /* Override any gcc2 internal prototype to avoid an error.  */
3939 /* We use char because int might match the return type of a gcc2
3940     builtin and then its argument prototype would still apply.  */
3941 char socket();
3942
3943 int main() {
3944
3945 /* The GNU C library defines this for functions which it implements
3946     to always fail with ENOSYS.  Some functions are actually named
3947     something starting with __ and the normal name is an alias.  */
3948 #if defined (__stub_socket) || defined (__stub___socket)
3949 choke me
3950 #else
3951 socket();
3952 #endif
3953
3954 ; return 0; }
3955 EOF
3956 if { (eval echo configure:3957: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3957   rm -rf conftest*
3958   eval "ac_cv_func_socket=yes"
3959 else
3960   echo "configure: failed program was:" >&5
3961   cat conftest.$ac_ext >&5
3962   rm -rf conftest*
3963   eval "ac_cv_func_socket=no"
3964 fi
3965 rm -f conftest*
3966 fi
3967
3968 if eval "test \"`echo '$ac_cv_func_'socket`\" = yes"; then
3969   echo "$ac_t""yes" 1>&6
3970   :
3971 else
3972   echo "$ac_t""no" 1>&6
3973 echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
3974 echo "configure:3975: checking for socket in -lsocket" >&5
3975 ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'`
3976 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3977   echo $ac_n "(cached) $ac_c" 1>&6
3978 else
3979   ac_save_LIBS="$LIBS"
3980 LIBS="-lsocket  $LIBS"
3981 cat > conftest.$ac_ext <<EOF
3982 #line 3983 "configure"
3983 #include "confdefs.h"
3984 /* Override any gcc2 internal prototype to avoid an error.  */
3985 /* We use char because int might match the return type of a gcc2
3986     builtin and then its argument prototype would still apply.  */
3987 char socket();
3988
3989 int main() {
3990 socket()
3991 ; return 0; }
3992 EOF
3993 if { (eval echo configure:3994: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3994   rm -rf conftest*
3995   eval "ac_cv_lib_$ac_lib_var=yes"
3996 else
3997   echo "configure: failed program was:" >&5
3998   cat conftest.$ac_ext >&5
3999   rm -rf conftest*
4000   eval "ac_cv_lib_$ac_lib_var=no"
4001 fi
4002 rm -f conftest*
4003 LIBS="$ac_save_LIBS"
4004
4005 fi
4006 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4007   echo "$ac_t""yes" 1>&6
4008     ac_tr_lib=HAVE_LIB`echo socket | sed -e 's/^a-zA-Z0-9_/_/g' \
4009     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
4010   cat >> confdefs.h <<EOF
4011 #define $ac_tr_lib 1
4012 EOF
4013
4014   LIBS="-lsocket $LIBS"
4015
4016 else
4017   echo "$ac_t""no" 1>&6
4018 fi
4019
4020 fi
4021
4022 echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
4023 echo "configure:4024: checking for gethostbyname" >&5
4024 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
4025   echo $ac_n "(cached) $ac_c" 1>&6
4026 else
4027   cat > conftest.$ac_ext <<EOF
4028 #line 4029 "configure"
4029 #include "confdefs.h"
4030 /* System header to define __stub macros and hopefully few prototypes,
4031     which can conflict with char gethostbyname(); below.  */
4032 #include <assert.h>
4033 /* Override any gcc2 internal prototype to avoid an error.  */
4034 /* We use char because int might match the return type of a gcc2
4035     builtin and then its argument prototype would still apply.  */
4036 char gethostbyname();
4037
4038 int main() {
4039
4040 /* The GNU C library defines this for functions which it implements
4041     to always fail with ENOSYS.  Some functions are actually named
4042     something starting with __ and the normal name is an alias.  */
4043 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
4044 choke me
4045 #else
4046 gethostbyname();
4047 #endif
4048
4049 ; return 0; }
4050 EOF
4051 if { (eval echo configure:4052: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4052   rm -rf conftest*
4053   eval "ac_cv_func_gethostbyname=yes"
4054 else
4055   echo "configure: failed program was:" >&5
4056   cat conftest.$ac_ext >&5
4057   rm -rf conftest*
4058   eval "ac_cv_func_gethostbyname=no"
4059 fi
4060 rm -f conftest*
4061 fi
4062
4063 if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
4064   echo "$ac_t""yes" 1>&6
4065   :
4066 else
4067   echo "$ac_t""no" 1>&6
4068 echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
4069 echo "configure:4070: checking for gethostbyname in -lnsl" >&5
4070 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
4071 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4072   echo $ac_n "(cached) $ac_c" 1>&6
4073 else
4074   ac_save_LIBS="$LIBS"
4075 LIBS="-lnsl  $LIBS"
4076 cat > conftest.$ac_ext <<EOF
4077 #line 4078 "configure"
4078 #include "confdefs.h"
4079 /* Override any gcc2 internal prototype to avoid an error.  */
4080 /* We use char because int might match the return type of a gcc2
4081     builtin and then its argument prototype would still apply.  */
4082 char gethostbyname();
4083
4084 int main() {
4085 gethostbyname()
4086 ; return 0; }
4087 EOF
4088 if { (eval echo configure:4089: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4089   rm -rf conftest*
4090   eval "ac_cv_lib_$ac_lib_var=yes"
4091 else
4092   echo "configure: failed program was:" >&5
4093   cat conftest.$ac_ext >&5
4094   rm -rf conftest*
4095   eval "ac_cv_lib_$ac_lib_var=no"
4096 fi
4097 rm -f conftest*
4098 LIBS="$ac_save_LIBS"
4099
4100 fi
4101 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4102   echo "$ac_t""yes" 1>&6
4103     ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/^a-zA-Z0-9_/_/g' \
4104     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
4105   cat >> confdefs.h <<EOF
4106 #define $ac_tr_lib 1
4107 EOF
4108
4109   LIBS="-lnsl $LIBS"
4110
4111 else
4112   echo "$ac_t""no" 1>&6
4113 fi
4114
4115 fi
4116
4117
4118
4119 if test "$enable_desrpc" != "no" -a "$ac_cv_header_rpc_key_prot_h" = "yes" ; then
4120         echo $ac_n "checking for getsecretkey""... $ac_c" 1>&6
4121 echo "configure:4122: checking for getsecretkey" >&5
4122 if eval "test \"`echo '$''{'ac_cv_func_getsecretkey'+set}'`\" = set"; then
4123   echo $ac_n "(cached) $ac_c" 1>&6
4124 else
4125   cat > conftest.$ac_ext <<EOF
4126 #line 4127 "configure"
4127 #include "confdefs.h"
4128 /* System header to define __stub macros and hopefully few prototypes,
4129     which can conflict with char getsecretkey(); below.  */
4130 #include <assert.h>
4131 /* Override any gcc2 internal prototype to avoid an error.  */
4132 /* We use char because int might match the return type of a gcc2
4133     builtin and then its argument prototype would still apply.  */
4134 char getsecretkey();
4135
4136 int main() {
4137
4138 /* The GNU C library defines this for functions which it implements
4139     to always fail with ENOSYS.  Some functions are actually named
4140     something starting with __ and the normal name is an alias.  */
4141 #if defined (__stub_getsecretkey) || defined (__stub___getsecretkey)
4142 choke me
4143 #else
4144 getsecretkey();
4145 #endif
4146
4147 ; return 0; }
4148 EOF
4149 if { (eval echo configure:4150: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4150   rm -rf conftest*
4151   eval "ac_cv_func_getsecretkey=yes"
4152 else
4153   echo "configure: failed program was:" >&5
4154   cat conftest.$ac_ext >&5
4155   rm -rf conftest*
4156   eval "ac_cv_func_getsecretkey=no"
4157 fi
4158 rm -f conftest*
4159 fi
4160
4161 if eval "test \"`echo '$ac_cv_func_'getsecretkey`\" = yes"; then
4162   echo "$ac_t""yes" 1>&6
4163   cat >> confdefs.h <<\EOF
4164 #define DES_RPC 1
4165 EOF
4166
4167 else
4168   echo "$ac_t""no" 1>&6
4169 echo $ac_n "checking for getsecretkey in -lrpcsvc""... $ac_c" 1>&6
4170 echo "configure:4171: checking for getsecretkey in -lrpcsvc" >&5
4171 ac_lib_var=`echo rpcsvc'_'getsecretkey | sed 'y%./+-%__p_%'`
4172 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4173   echo $ac_n "(cached) $ac_c" 1>&6
4174 else
4175   ac_save_LIBS="$LIBS"
4176 LIBS="-lrpcsvc  $LIBS"
4177 cat > conftest.$ac_ext <<EOF
4178 #line 4179 "configure"
4179 #include "confdefs.h"
4180 /* Override any gcc2 internal prototype to avoid an error.  */
4181 /* We use char because int might match the return type of a gcc2
4182     builtin and then its argument prototype would still apply.  */
4183 char getsecretkey();
4184
4185 int main() {
4186 getsecretkey()
4187 ; return 0; }
4188 EOF
4189 if { (eval echo configure:4190: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4190   rm -rf conftest*
4191   eval "ac_cv_lib_$ac_lib_var=yes"
4192 else
4193   echo "configure: failed program was:" >&5
4194   cat conftest.$ac_ext >&5
4195   rm -rf conftest*
4196   eval "ac_cv_lib_$ac_lib_var=no"
4197 fi
4198 rm -f conftest*
4199 LIBS="$ac_save_LIBS"
4200
4201 fi
4202 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4203   echo "$ac_t""yes" 1>&6
4204   cat >> confdefs.h <<\EOF
4205 #define DES_RPC 1
4206 EOF
4207
4208 else
4209   echo "$ac_t""no" 1>&6
4210 fi
4211
4212 fi
4213
4214 fi
4215
4216 if test "$enable_shadowgrp" != "no"; then
4217         cat >> confdefs.h <<\EOF
4218 #define SHADOWGRP 1
4219 EOF
4220
4221 fi
4222
4223
4224 if test "$with_libcrypt" != "no"; then
4225         echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6
4226 echo "configure:4227: checking for crypt in -lcrypt" >&5
4227 ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'`
4228 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4229   echo $ac_n "(cached) $ac_c" 1>&6
4230 else
4231   ac_save_LIBS="$LIBS"
4232 LIBS="-lcrypt  $LIBS"
4233 cat > conftest.$ac_ext <<EOF
4234 #line 4235 "configure"
4235 #include "confdefs.h"
4236 /* Override any gcc2 internal prototype to avoid an error.  */
4237 /* We use char because int might match the return type of a gcc2
4238     builtin and then its argument prototype would still apply.  */
4239 char crypt();
4240
4241 int main() {
4242 crypt()
4243 ; return 0; }
4244 EOF
4245 if { (eval echo configure:4246: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4246   rm -rf conftest*
4247   eval "ac_cv_lib_$ac_lib_var=yes"
4248 else
4249   echo "configure: failed program was:" >&5
4250   cat conftest.$ac_ext >&5
4251   rm -rf conftest*
4252   eval "ac_cv_lib_$ac_lib_var=no"
4253 fi
4254 rm -f conftest*
4255 LIBS="$ac_save_LIBS"
4256
4257 fi
4258 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4259   echo "$ac_t""yes" 1>&6
4260   cat >> confdefs.h <<\EOF
4261 #define HAVE_LIBCRYPT 1
4262 EOF
4263  LIBCRYPT=-lcrypt
4264 else
4265   echo "$ac_t""no" 1>&6
4266 fi
4267
4268 fi
4269
4270 if test "$enable_md5crypt" = "yes"; then
4271         LIBOBJS="$LIBOBJS md5.o md5crypt.o"
4272         cat >> confdefs.h <<\EOF
4273 #define MD5_CRYPT 1
4274 EOF
4275
4276 fi
4277
4278
4279 if test "$with_libcrack" != "no"; then
4280         echo "checking cracklib flavour, don't be surprised by the results"
4281         echo $ac_n "checking for FascistCheck in -lcrack""... $ac_c" 1>&6
4282 echo "configure:4283: checking for FascistCheck in -lcrack" >&5
4283 ac_lib_var=`echo crack'_'FascistCheck | sed 'y%./+-%__p_%'`
4284 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4285   echo $ac_n "(cached) $ac_c" 1>&6
4286 else
4287   ac_save_LIBS="$LIBS"
4288 LIBS="-lcrack  $LIBS"
4289 cat > conftest.$ac_ext <<EOF
4290 #line 4291 "configure"
4291 #include "confdefs.h"
4292 /* Override any gcc2 internal prototype to avoid an error.  */
4293 /* We use char because int might match the return type of a gcc2
4294     builtin and then its argument prototype would still apply.  */
4295 char FascistCheck();
4296
4297 int main() {
4298 FascistCheck()
4299 ; return 0; }
4300 EOF
4301 if { (eval echo configure:4302: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4302   rm -rf conftest*
4303   eval "ac_cv_lib_$ac_lib_var=yes"
4304 else
4305   echo "configure: failed program was:" >&5
4306   cat conftest.$ac_ext >&5
4307   rm -rf conftest*
4308   eval "ac_cv_lib_$ac_lib_var=no"
4309 fi
4310 rm -f conftest*
4311 LIBS="$ac_save_LIBS"
4312
4313 fi
4314 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4315   echo "$ac_t""yes" 1>&6
4316   cat >> confdefs.h <<\EOF
4317 #define HAVE_LIBCRACK 1
4318 EOF
4319  LIBCRACK=-lcrack
4320 else
4321   echo "$ac_t""no" 1>&6
4322 fi
4323
4324         echo $ac_n "checking for FascistHistory in -lcrack""... $ac_c" 1>&6
4325 echo "configure:4326: checking for FascistHistory in -lcrack" >&5
4326 ac_lib_var=`echo crack'_'FascistHistory | sed 'y%./+-%__p_%'`
4327 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4328   echo $ac_n "(cached) $ac_c" 1>&6
4329 else
4330   ac_save_LIBS="$LIBS"
4331 LIBS="-lcrack  $LIBS"
4332 cat > conftest.$ac_ext <<EOF
4333 #line 4334 "configure"
4334 #include "confdefs.h"
4335 /* Override any gcc2 internal prototype to avoid an error.  */
4336 /* We use char because int might match the return type of a gcc2
4337     builtin and then its argument prototype would still apply.  */
4338 char FascistHistory();
4339
4340 int main() {
4341 FascistHistory()
4342 ; return 0; }
4343 EOF
4344 if { (eval echo configure:4345: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4345   rm -rf conftest*
4346   eval "ac_cv_lib_$ac_lib_var=yes"
4347 else
4348   echo "configure: failed program was:" >&5
4349   cat conftest.$ac_ext >&5
4350   rm -rf conftest*
4351   eval "ac_cv_lib_$ac_lib_var=no"
4352 fi
4353 rm -f conftest*
4354 LIBS="$ac_save_LIBS"
4355
4356 fi
4357 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4358   echo "$ac_t""yes" 1>&6
4359   cat >> confdefs.h <<\EOF
4360 #define HAVE_LIBCRACK_HIST 1
4361 EOF
4362
4363 else
4364   echo "$ac_t""no" 1>&6
4365 fi
4366
4367         echo $ac_n "checking for FascistHistoryPw in -lcrack""... $ac_c" 1>&6
4368 echo "configure:4369: checking for FascistHistoryPw in -lcrack" >&5
4369 ac_lib_var=`echo crack'_'FascistHistoryPw | sed 'y%./+-%__p_%'`
4370 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4371   echo $ac_n "(cached) $ac_c" 1>&6
4372 else
4373   ac_save_LIBS="$LIBS"
4374 LIBS="-lcrack  $LIBS"
4375 cat > conftest.$ac_ext <<EOF
4376 #line 4377 "configure"
4377 #include "confdefs.h"
4378 /* Override any gcc2 internal prototype to avoid an error.  */
4379 /* We use char because int might match the return type of a gcc2
4380     builtin and then its argument prototype would still apply.  */
4381 char FascistHistoryPw();
4382
4383 int main() {
4384 FascistHistoryPw()
4385 ; return 0; }
4386 EOF
4387 if { (eval echo configure:4388: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4388   rm -rf conftest*
4389   eval "ac_cv_lib_$ac_lib_var=yes"
4390 else
4391   echo "configure: failed program was:" >&5
4392   cat conftest.$ac_ext >&5
4393   rm -rf conftest*
4394   eval "ac_cv_lib_$ac_lib_var=no"
4395 fi
4396 rm -f conftest*
4397 LIBS="$ac_save_LIBS"
4398
4399 fi
4400 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4401   echo "$ac_t""yes" 1>&6
4402   cat >> confdefs.h <<\EOF
4403 #define HAVE_LIBCRACK_PW 1
4404 EOF
4405
4406 else
4407   echo "$ac_t""no" 1>&6
4408 fi
4409
4410 fi
4411
4412
4413
4414 if test "$with_libskey" = "yes"; then
4415         echo $ac_n "checking for MD5Init in -lmd""... $ac_c" 1>&6
4416 echo "configure:4417: checking for MD5Init in -lmd" >&5
4417 ac_lib_var=`echo md'_'MD5Init | sed 'y%./+-%__p_%'`
4418 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4419   echo $ac_n "(cached) $ac_c" 1>&6
4420 else
4421   ac_save_LIBS="$LIBS"
4422 LIBS="-lmd  $LIBS"
4423 cat > conftest.$ac_ext <<EOF
4424 #line 4425 "configure"
4425 #include "confdefs.h"
4426 /* Override any gcc2 internal prototype to avoid an error.  */
4427 /* We use char because int might match the return type of a gcc2
4428     builtin and then its argument prototype would still apply.  */
4429 char MD5Init();
4430
4431 int main() {
4432 MD5Init()
4433 ; return 0; }
4434 EOF
4435 if { (eval echo configure:4436: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4436   rm -rf conftest*
4437   eval "ac_cv_lib_$ac_lib_var=yes"
4438 else
4439   echo "configure: failed program was:" >&5
4440   cat conftest.$ac_ext >&5
4441   rm -rf conftest*
4442   eval "ac_cv_lib_$ac_lib_var=no"
4443 fi
4444 rm -f conftest*
4445 LIBS="$ac_save_LIBS"
4446
4447 fi
4448 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4449   echo "$ac_t""yes" 1>&6
4450   LIBMD=-lmd
4451 else
4452   echo "$ac_t""no" 1>&6
4453 fi
4454
4455         echo $ac_n "checking for skeychallenge in -lskey""... $ac_c" 1>&6
4456 echo "configure:4457: checking for skeychallenge in -lskey" >&5
4457 ac_lib_var=`echo skey'_'skeychallenge | sed 'y%./+-%__p_%'`
4458 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4459   echo $ac_n "(cached) $ac_c" 1>&6
4460 else
4461   ac_save_LIBS="$LIBS"
4462 LIBS="-lskey $LIBMD $LIBCRYPT $LIBS"
4463 cat > conftest.$ac_ext <<EOF
4464 #line 4465 "configure"
4465 #include "confdefs.h"
4466 /* Override any gcc2 internal prototype to avoid an error.  */
4467 /* We use char because int might match the return type of a gcc2
4468     builtin and then its argument prototype would still apply.  */
4469 char skeychallenge();
4470
4471 int main() {
4472 skeychallenge()
4473 ; return 0; }
4474 EOF
4475 if { (eval echo configure:4476: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4476   rm -rf conftest*
4477   eval "ac_cv_lib_$ac_lib_var=yes"
4478 else
4479   echo "configure: failed program was:" >&5
4480   cat conftest.$ac_ext >&5
4481   rm -rf conftest*
4482   eval "ac_cv_lib_$ac_lib_var=no"
4483 fi
4484 rm -f conftest*
4485 LIBS="$ac_save_LIBS"
4486
4487 fi
4488 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4489   echo "$ac_t""yes" 1>&6
4490   cat >> confdefs.h <<\EOF
4491 #define SKEY 1
4492 EOF
4493  LIBSKEY=-lskey
4494 else
4495   echo "$ac_t""no" 1>&6
4496 fi
4497
4498 elif test "$with_libopie" = "yes"; then
4499         echo $ac_n "checking for opiechallenge in -lopie""... $ac_c" 1>&6
4500 echo "configure:4501: checking for opiechallenge in -lopie" >&5
4501 ac_lib_var=`echo opie'_'opiechallenge | sed 'y%./+-%__p_%'`
4502 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4503   echo $ac_n "(cached) $ac_c" 1>&6
4504 else
4505   ac_save_LIBS="$LIBS"
4506 LIBS="-lopie $LIBCRYPT $LIBS"
4507 cat > conftest.$ac_ext <<EOF
4508 #line 4509 "configure"
4509 #include "confdefs.h"
4510 /* Override any gcc2 internal prototype to avoid an error.  */
4511 /* We use char because int might match the return type of a gcc2
4512     builtin and then its argument prototype would still apply.  */
4513 char opiechallenge();
4514
4515 int main() {
4516 opiechallenge()
4517 ; return 0; }
4518 EOF
4519 if { (eval echo configure:4520: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4520   rm -rf conftest*
4521   eval "ac_cv_lib_$ac_lib_var=yes"
4522 else
4523   echo "configure: failed program was:" >&5
4524   cat conftest.$ac_ext >&5
4525   rm -rf conftest*
4526   eval "ac_cv_lib_$ac_lib_var=no"
4527 fi
4528 rm -f conftest*
4529 LIBS="$ac_save_LIBS"
4530
4531 fi
4532 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4533   echo "$ac_t""yes" 1>&6
4534   cat >> confdefs.h <<\EOF
4535 #define OPIE 1
4536 EOF
4537  LIBSKEY=-lopie
4538 else
4539   echo "$ac_t""no" 1>&6
4540 fi
4541
4542 fi
4543
4544
4545 if test "$with_libtcfs" = "yes"; then
4546         echo $ac_n "checking for tcfs_encrypt_key in -ltcfs""... $ac_c" 1>&6
4547 echo "configure:4548: checking for tcfs_encrypt_key in -ltcfs" >&5
4548 ac_lib_var=`echo tcfs'_'tcfs_encrypt_key | sed 'y%./+-%__p_%'`
4549 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4550   echo $ac_n "(cached) $ac_c" 1>&6
4551 else
4552   ac_save_LIBS="$LIBS"
4553 LIBS="-ltcfs -lgdbm $LIBS"
4554 cat > conftest.$ac_ext <<EOF
4555 #line 4556 "configure"
4556 #include "confdefs.h"
4557 /* Override any gcc2 internal prototype to avoid an error.  */
4558 /* We use char because int might match the return type of a gcc2
4559     builtin and then its argument prototype would still apply.  */
4560 char tcfs_encrypt_key();
4561
4562 int main() {
4563 tcfs_encrypt_key()
4564 ; return 0; }
4565 EOF
4566 if { (eval echo configure:4567: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4567   rm -rf conftest*
4568   eval "ac_cv_lib_$ac_lib_var=yes"
4569 else
4570   echo "configure: failed program was:" >&5
4571   cat conftest.$ac_ext >&5
4572   rm -rf conftest*
4573   eval "ac_cv_lib_$ac_lib_var=no"
4574 fi
4575 rm -f conftest*
4576 LIBS="$ac_save_LIBS"
4577
4578 fi
4579 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4580   echo "$ac_t""yes" 1>&6
4581   cat >> confdefs.h <<\EOF
4582 #define HAVE_TCFS 1
4583 EOF
4584  cat >> confdefs.h <<\EOF
4585 #define TCFS_GDBM_SUPPORT 1
4586 EOF
4587  LIBTCFS="-ltcfs -lgdbm"
4588 else
4589   echo "$ac_t""no" 1>&6
4590 fi
4591
4592 fi
4593
4594
4595 if test "$with_libpam" = "yes"; then
4596                                 LIBPAM="-lpam -lpam_misc -ldl"
4597         cat >> confdefs.h <<\EOF
4598 #define USE_PAM 1
4599 EOF
4600
4601         echo $ac_n "checking whether pam_strerror needs two arguments""... $ac_c" 1>&6
4602 echo "configure:4603: checking whether pam_strerror needs two arguments" >&5
4603 if eval "test \"`echo '$''{'ac_cv_pam_strerror_needs_two_args'+set}'`\" = set"; then
4604   echo $ac_n "(cached) $ac_c" 1>&6
4605 else
4606   cat > conftest.$ac_ext <<EOF
4607 #line 4608 "configure"
4608 #include "confdefs.h"
4609 #include <security/pam_appl.h>
4610 int main() {
4611  pam_handle_t *pamh; pam_strerror(pamh, PAM_SUCCESS); 
4612 ; return 0; }
4613 EOF
4614 if { (eval echo configure:4615: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4615   rm -rf conftest*
4616   ac_cv_pam_strerror_needs_two_args=yes
4617 else
4618   echo "configure: failed program was:" >&5
4619   cat conftest.$ac_ext >&5
4620   rm -rf conftest*
4621   ac_cv_pam_strerror_needs_two_args=no
4622                 
4623 fi
4624 rm -f conftest*
4625         
4626 fi
4627
4628 echo "$ac_t""$ac_cv_pam_strerror_needs_two_args" 1>&6
4629         if test "$ac_cv_pam_strerror_needs_two_args" = "yes"; then
4630                 cat >> confdefs.h <<\EOF
4631 #define PAM_STRERROR_NEEDS_TWO_ARGS 1
4632 EOF
4633
4634         fi
4635 fi
4636
4637 LTLIBOBJS=`echo "$LIBOBJS" | sed 's/\.o/.lo/g'`
4638
4639
4640 echo $ac_n "checking for inline""... $ac_c" 1>&6
4641 echo "configure:4642: checking for inline" >&5
4642 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
4643   echo $ac_n "(cached) $ac_c" 1>&6
4644 else
4645   ac_cv_c_inline=no
4646 for ac_kw in inline __inline__ __inline; do
4647   cat > conftest.$ac_ext <<EOF
4648 #line 4649 "configure"
4649 #include "confdefs.h"
4650
4651 int main() {
4652 } $ac_kw foo() {
4653 ; return 0; }
4654 EOF
4655 if { (eval echo configure:4656: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4656   rm -rf conftest*
4657   ac_cv_c_inline=$ac_kw; break
4658 else
4659   echo "configure: failed program was:" >&5
4660   cat conftest.$ac_ext >&5
4661 fi
4662 rm -f conftest*
4663 done
4664
4665 fi
4666
4667 echo "$ac_t""$ac_cv_c_inline" 1>&6
4668 case "$ac_cv_c_inline" in
4669   inline | yes) ;;
4670   no) cat >> confdefs.h <<\EOF
4671 #define inline 
4672 EOF
4673  ;;
4674   *)  cat >> confdefs.h <<EOF
4675 #define inline $ac_cv_c_inline
4676 EOF
4677  ;;
4678 esac
4679
4680 echo $ac_n "checking for size_t""... $ac_c" 1>&6
4681 echo "configure:4682: checking for size_t" >&5
4682 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
4683   echo $ac_n "(cached) $ac_c" 1>&6
4684 else
4685   cat > conftest.$ac_ext <<EOF
4686 #line 4687 "configure"
4687 #include "confdefs.h"
4688 #include <sys/types.h>
4689 #if STDC_HEADERS
4690 #include <stdlib.h>
4691 #include <stddef.h>
4692 #endif
4693 EOF
4694 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4695   egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4696   rm -rf conftest*
4697   ac_cv_type_size_t=yes
4698 else
4699   rm -rf conftest*
4700   ac_cv_type_size_t=no
4701 fi
4702 rm -f conftest*
4703
4704 fi
4705 echo "$ac_t""$ac_cv_type_size_t" 1>&6
4706 if test $ac_cv_type_size_t = no; then
4707   cat >> confdefs.h <<\EOF
4708 #define size_t unsigned
4709 EOF
4710
4711 fi
4712
4713 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
4714 # for constant arguments.  Useless!
4715 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
4716 echo "configure:4717: checking for working alloca.h" >&5
4717 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
4718   echo $ac_n "(cached) $ac_c" 1>&6
4719 else
4720   cat > conftest.$ac_ext <<EOF
4721 #line 4722 "configure"
4722 #include "confdefs.h"
4723 #include <alloca.h>
4724 int main() {
4725 char *p = alloca(2 * sizeof(int));
4726 ; return 0; }
4727 EOF
4728 if { (eval echo configure:4729: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4729   rm -rf conftest*
4730   ac_cv_header_alloca_h=yes
4731 else
4732   echo "configure: failed program was:" >&5
4733   cat conftest.$ac_ext >&5
4734   rm -rf conftest*
4735   ac_cv_header_alloca_h=no
4736 fi
4737 rm -f conftest*
4738 fi
4739
4740 echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
4741 if test $ac_cv_header_alloca_h = yes; then
4742   cat >> confdefs.h <<\EOF
4743 #define HAVE_ALLOCA_H 1
4744 EOF
4745
4746 fi
4747
4748 echo $ac_n "checking for alloca""... $ac_c" 1>&6
4749 echo "configure:4750: checking for alloca" >&5
4750 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
4751   echo $ac_n "(cached) $ac_c" 1>&6
4752 else
4753   cat > conftest.$ac_ext <<EOF
4754 #line 4755 "configure"
4755 #include "confdefs.h"
4756
4757 #ifdef __GNUC__
4758 # define alloca __builtin_alloca
4759 #else
4760 # ifdef _MSC_VER
4761 #  include <malloc.h>
4762 #  define alloca _alloca
4763 # else
4764 #  if HAVE_ALLOCA_H
4765 #   include <alloca.h>
4766 #  else
4767 #   ifdef _AIX
4768  #pragma alloca
4769 #   else
4770 #    ifndef alloca /* predefined by HP cc +Olibcalls */
4771 char *alloca ();
4772 #    endif
4773 #   endif
4774 #  endif
4775 # endif
4776 #endif
4777
4778 int main() {
4779 char *p = (char *) alloca(1);
4780 ; return 0; }
4781 EOF
4782 if { (eval echo configure:4783: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4783   rm -rf conftest*
4784   ac_cv_func_alloca_works=yes
4785 else
4786   echo "configure: failed program was:" >&5
4787   cat conftest.$ac_ext >&5
4788   rm -rf conftest*
4789   ac_cv_func_alloca_works=no
4790 fi
4791 rm -f conftest*
4792 fi
4793
4794 echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
4795 if test $ac_cv_func_alloca_works = yes; then
4796   cat >> confdefs.h <<\EOF
4797 #define HAVE_ALLOCA 1
4798 EOF
4799
4800 fi
4801
4802 if test $ac_cv_func_alloca_works = no; then
4803   # The SVR3 libPW and SVR4 libucb both contain incompatible functions
4804   # that cause trouble.  Some versions do not even contain alloca or
4805   # contain a buggy version.  If you still want to use their alloca,
4806   # use ar to extract alloca.o from them instead of compiling alloca.c.
4807   ALLOCA=alloca.${ac_objext}
4808   cat >> confdefs.h <<\EOF
4809 #define C_ALLOCA 1
4810 EOF
4811
4812
4813 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
4814 echo "configure:4815: checking whether alloca needs Cray hooks" >&5
4815 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
4816   echo $ac_n "(cached) $ac_c" 1>&6
4817 else
4818   cat > conftest.$ac_ext <<EOF
4819 #line 4820 "configure"
4820 #include "confdefs.h"
4821 #if defined(CRAY) && ! defined(CRAY2)
4822 webecray
4823 #else
4824 wenotbecray
4825 #endif
4826
4827 EOF
4828 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4829   egrep "webecray" >/dev/null 2>&1; then
4830   rm -rf conftest*
4831   ac_cv_os_cray=yes
4832 else
4833   rm -rf conftest*
4834   ac_cv_os_cray=no
4835 fi
4836 rm -f conftest*
4837
4838 fi
4839
4840 echo "$ac_t""$ac_cv_os_cray" 1>&6
4841 if test $ac_cv_os_cray = yes; then
4842 for ac_func in _getb67 GETB67 getb67; do
4843   echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4844 echo "configure:4845: checking for $ac_func" >&5
4845 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4846   echo $ac_n "(cached) $ac_c" 1>&6
4847 else
4848   cat > conftest.$ac_ext <<EOF
4849 #line 4850 "configure"
4850 #include "confdefs.h"
4851 /* System header to define __stub macros and hopefully few prototypes,
4852     which can conflict with char $ac_func(); below.  */
4853 #include <assert.h>
4854 /* Override any gcc2 internal prototype to avoid an error.  */
4855 /* We use char because int might match the return type of a gcc2
4856     builtin and then its argument prototype would still apply.  */
4857 char $ac_func();
4858
4859 int main() {
4860
4861 /* The GNU C library defines this for functions which it implements
4862     to always fail with ENOSYS.  Some functions are actually named
4863     something starting with __ and the normal name is an alias.  */
4864 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4865 choke me
4866 #else
4867 $ac_func();
4868 #endif
4869
4870 ; return 0; }
4871 EOF
4872 if { (eval echo configure:4873: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4873   rm -rf conftest*
4874   eval "ac_cv_func_$ac_func=yes"
4875 else
4876   echo "configure: failed program was:" >&5
4877   cat conftest.$ac_ext >&5
4878   rm -rf conftest*
4879   eval "ac_cv_func_$ac_func=no"
4880 fi
4881 rm -f conftest*
4882 fi
4883
4884 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4885   echo "$ac_t""yes" 1>&6
4886   cat >> confdefs.h <<EOF
4887 #define CRAY_STACKSEG_END $ac_func
4888 EOF
4889
4890   break
4891 else
4892   echo "$ac_t""no" 1>&6
4893 fi
4894
4895 done
4896 fi
4897
4898 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
4899 echo "configure:4900: checking stack direction for C alloca" >&5
4900 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
4901   echo $ac_n "(cached) $ac_c" 1>&6
4902 else
4903   if test "$cross_compiling" = yes; then
4904   ac_cv_c_stack_direction=0
4905 else
4906   cat > conftest.$ac_ext <<EOF
4907 #line 4908 "configure"
4908 #include "confdefs.h"
4909 find_stack_direction ()
4910 {
4911   static char *addr = 0;
4912   auto char dummy;
4913   if (addr == 0)
4914     {
4915       addr = &dummy;
4916       return find_stack_direction ();
4917     }
4918   else
4919     return (&dummy > addr) ? 1 : -1;
4920 }
4921 main ()
4922 {
4923   exit (find_stack_direction() < 0);
4924 }
4925 EOF
4926 if { (eval echo configure:4927: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4927 then
4928   ac_cv_c_stack_direction=1
4929 else
4930   echo "configure: failed program was:" >&5
4931   cat conftest.$ac_ext >&5
4932   rm -fr conftest*
4933   ac_cv_c_stack_direction=-1
4934 fi
4935 rm -fr conftest*
4936 fi
4937
4938 fi
4939
4940 echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
4941 cat >> confdefs.h <<EOF
4942 #define STACK_DIRECTION $ac_cv_c_stack_direction
4943 EOF
4944
4945 fi
4946
4947 for ac_hdr in unistd.h
4948 do
4949 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4950 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4951 echo "configure:4952: checking for $ac_hdr" >&5
4952 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4953   echo $ac_n "(cached) $ac_c" 1>&6
4954 else
4955   cat > conftest.$ac_ext <<EOF
4956 #line 4957 "configure"
4957 #include "confdefs.h"
4958 #include <$ac_hdr>
4959 EOF
4960 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4961 { (eval echo configure:4962: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4962 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4963 if test -z "$ac_err"; then
4964   rm -rf conftest*
4965   eval "ac_cv_header_$ac_safe=yes"
4966 else
4967   echo "$ac_err" >&5
4968   echo "configure: failed program was:" >&5
4969   cat conftest.$ac_ext >&5
4970   rm -rf conftest*
4971   eval "ac_cv_header_$ac_safe=no"
4972 fi
4973 rm -f conftest*
4974 fi
4975 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4976   echo "$ac_t""yes" 1>&6
4977     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4978   cat >> confdefs.h <<EOF
4979 #define $ac_tr_hdr 1
4980 EOF
4981  
4982 else
4983   echo "$ac_t""no" 1>&6
4984 fi
4985 done
4986
4987 for ac_func in getpagesize
4988 do
4989 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4990 echo "configure:4991: checking for $ac_func" >&5
4991 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4992   echo $ac_n "(cached) $ac_c" 1>&6
4993 else
4994   cat > conftest.$ac_ext <<EOF
4995 #line 4996 "configure"
4996 #include "confdefs.h"
4997 /* System header to define __stub macros and hopefully few prototypes,
4998     which can conflict with char $ac_func(); below.  */
4999 #include <assert.h>
5000 /* Override any gcc2 internal prototype to avoid an error.  */
5001 /* We use char because int might match the return type of a gcc2
5002     builtin and then its argument prototype would still apply.  */
5003 char $ac_func();
5004
5005 int main() {
5006
5007 /* The GNU C library defines this for functions which it implements
5008     to always fail with ENOSYS.  Some functions are actually named
5009     something starting with __ and the normal name is an alias.  */
5010 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5011 choke me
5012 #else
5013 $ac_func();
5014 #endif
5015
5016 ; return 0; }
5017 EOF
5018 if { (eval echo configure:5019: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5019   rm -rf conftest*
5020   eval "ac_cv_func_$ac_func=yes"
5021 else
5022   echo "configure: failed program was:" >&5
5023   cat conftest.$ac_ext >&5
5024   rm -rf conftest*
5025   eval "ac_cv_func_$ac_func=no"
5026 fi
5027 rm -f conftest*
5028 fi
5029
5030 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5031   echo "$ac_t""yes" 1>&6
5032     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5033   cat >> confdefs.h <<EOF
5034 #define $ac_tr_func 1
5035 EOF
5036  
5037 else
5038   echo "$ac_t""no" 1>&6
5039 fi
5040 done
5041
5042 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
5043 echo "configure:5044: checking for working mmap" >&5
5044 if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
5045   echo $ac_n "(cached) $ac_c" 1>&6
5046 else
5047   if test "$cross_compiling" = yes; then
5048   ac_cv_func_mmap_fixed_mapped=no
5049 else
5050   cat > conftest.$ac_ext <<EOF
5051 #line 5052 "configure"
5052 #include "confdefs.h"
5053
5054 /* Thanks to Mike Haertel and Jim Avera for this test.
5055    Here is a matrix of mmap possibilities:
5056         mmap private not fixed
5057         mmap private fixed at somewhere currently unmapped
5058         mmap private fixed at somewhere already mapped
5059         mmap shared not fixed
5060         mmap shared fixed at somewhere currently unmapped
5061         mmap shared fixed at somewhere already mapped
5062    For private mappings, we should verify that changes cannot be read()
5063    back from the file, nor mmap's back from the file at a different
5064    address.  (There have been systems where private was not correctly
5065    implemented like the infamous i386 svr4.0, and systems where the
5066    VM page cache was not coherent with the filesystem buffer cache
5067    like early versions of FreeBSD and possibly contemporary NetBSD.)
5068    For shared mappings, we should conversely verify that changes get
5069    propogated back to all the places they're supposed to be.
5070
5071    Grep wants private fixed already mapped.
5072    The main things grep needs to know about mmap are:
5073    * does it exist and is it safe to write into the mmap'd area
5074    * how to use it (BSD variants)  */
5075 #include <sys/types.h>
5076 #include <fcntl.h>
5077 #include <sys/mman.h>
5078
5079 /* This mess was copied from the GNU getpagesize.h.  */
5080 #ifndef HAVE_GETPAGESIZE
5081 # ifdef HAVE_UNISTD_H
5082 #  include <unistd.h>
5083 # endif
5084
5085 /* Assume that all systems that can run configure have sys/param.h.  */
5086 # ifndef HAVE_SYS_PARAM_H
5087 #  define HAVE_SYS_PARAM_H 1
5088 # endif
5089
5090 # ifdef _SC_PAGESIZE
5091 #  define getpagesize() sysconf(_SC_PAGESIZE)
5092 # else /* no _SC_PAGESIZE */
5093 #  ifdef HAVE_SYS_PARAM_H
5094 #   include <sys/param.h>
5095 #   ifdef EXEC_PAGESIZE
5096 #    define getpagesize() EXEC_PAGESIZE
5097 #   else /* no EXEC_PAGESIZE */
5098 #    ifdef NBPG
5099 #     define getpagesize() NBPG * CLSIZE
5100 #     ifndef CLSIZE
5101 #      define CLSIZE 1
5102 #     endif /* no CLSIZE */
5103 #    else /* no NBPG */
5104 #     ifdef NBPC
5105 #      define getpagesize() NBPC
5106 #     else /* no NBPC */
5107 #      ifdef PAGESIZE
5108 #       define getpagesize() PAGESIZE
5109 #      endif /* PAGESIZE */
5110 #     endif /* no NBPC */
5111 #    endif /* no NBPG */
5112 #   endif /* no EXEC_PAGESIZE */
5113 #  else /* no HAVE_SYS_PARAM_H */
5114 #   define getpagesize() 8192   /* punt totally */
5115 #  endif /* no HAVE_SYS_PARAM_H */
5116 # endif /* no _SC_PAGESIZE */
5117
5118 #endif /* no HAVE_GETPAGESIZE */
5119
5120 #ifdef __cplusplus
5121 extern "C" { void *malloc(unsigned); }
5122 #else
5123 char *malloc();
5124 #endif
5125
5126 int
5127 main()
5128 {
5129         char *data, *data2, *data3;
5130         int i, pagesize;
5131         int fd;
5132
5133         pagesize = getpagesize();
5134
5135         /*
5136          * First, make a file with some known garbage in it.
5137          */
5138         data = malloc(pagesize);
5139         if (!data)
5140                 exit(1);
5141         for (i = 0; i < pagesize; ++i)
5142                 *(data + i) = rand();
5143         umask(0);
5144         fd = creat("conftestmmap", 0600);
5145         if (fd < 0)
5146                 exit(1);
5147         if (write(fd, data, pagesize) != pagesize)
5148                 exit(1);
5149         close(fd);
5150
5151         /*
5152          * Next, try to mmap the file at a fixed address which
5153          * already has something else allocated at it.  If we can,
5154          * also make sure that we see the same garbage.
5155          */
5156         fd = open("conftestmmap", O_RDWR);
5157         if (fd < 0)
5158                 exit(1);
5159         data2 = malloc(2 * pagesize);
5160         if (!data2)
5161                 exit(1);
5162         data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
5163         if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
5164             MAP_PRIVATE | MAP_FIXED, fd, 0L))
5165                 exit(1);
5166         for (i = 0; i < pagesize; ++i)
5167                 if (*(data + i) != *(data2 + i))
5168                         exit(1);
5169
5170         /*
5171          * Finally, make sure that changes to the mapped area
5172          * do not percolate back to the file as seen by read().
5173          * (This is a bug on some variants of i386 svr4.0.)
5174          */
5175         for (i = 0; i < pagesize; ++i)
5176                 *(data2 + i) = *(data2 + i) + 1;
5177         data3 = malloc(pagesize);
5178         if (!data3)
5179                 exit(1);
5180         if (read(fd, data3, pagesize) != pagesize)
5181                 exit(1);
5182         for (i = 0; i < pagesize; ++i)
5183                 if (*(data + i) != *(data3 + i))
5184                         exit(1);
5185         close(fd);
5186         unlink("conftestmmap");
5187         exit(0);
5188 }
5189
5190 EOF
5191 if { (eval echo configure:5192: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
5192 then
5193   ac_cv_func_mmap_fixed_mapped=yes
5194 else
5195   echo "configure: failed program was:" >&5
5196   cat conftest.$ac_ext >&5
5197   rm -fr conftest*
5198   ac_cv_func_mmap_fixed_mapped=no
5199 fi
5200 rm -fr conftest*
5201 fi
5202
5203 fi
5204
5205 echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
5206 if test $ac_cv_func_mmap_fixed_mapped = yes; then
5207   cat >> confdefs.h <<\EOF
5208 #define HAVE_MMAP 1
5209 EOF
5210
5211 fi
5212
5213                               
5214    for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \
5215 unistd.h sys/param.h
5216 do
5217 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5218 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5219 echo "configure:5220: checking for $ac_hdr" >&5
5220 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5221   echo $ac_n "(cached) $ac_c" 1>&6
5222 else
5223   cat > conftest.$ac_ext <<EOF
5224 #line 5225 "configure"
5225 #include "confdefs.h"
5226 #include <$ac_hdr>
5227 EOF
5228 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5229 { (eval echo configure:5230: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5230 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5231 if test -z "$ac_err"; then
5232   rm -rf conftest*
5233   eval "ac_cv_header_$ac_safe=yes"
5234 else
5235   echo "$ac_err" >&5
5236   echo "configure: failed program was:" >&5
5237   cat conftest.$ac_ext >&5
5238   rm -rf conftest*
5239   eval "ac_cv_header_$ac_safe=no"
5240 fi
5241 rm -f conftest*
5242 fi
5243 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5244   echo "$ac_t""yes" 1>&6
5245     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5246   cat >> confdefs.h <<EOF
5247 #define $ac_tr_hdr 1
5248 EOF
5249  
5250 else
5251   echo "$ac_t""no" 1>&6
5252 fi
5253 done
5254
5255    for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \
5256 strdup __argz_count __argz_stringify __argz_next
5257 do
5258 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5259 echo "configure:5260: checking for $ac_func" >&5
5260 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5261   echo $ac_n "(cached) $ac_c" 1>&6
5262 else
5263   cat > conftest.$ac_ext <<EOF
5264 #line 5265 "configure"
5265 #include "confdefs.h"
5266 /* System header to define __stub macros and hopefully few prototypes,
5267     which can conflict with char $ac_func(); below.  */
5268 #include <assert.h>
5269 /* Override any gcc2 internal prototype to avoid an error.  */
5270 /* We use char because int might match the return type of a gcc2
5271     builtin and then its argument prototype would still apply.  */
5272 char $ac_func();
5273
5274 int main() {
5275
5276 /* The GNU C library defines this for functions which it implements
5277     to always fail with ENOSYS.  Some functions are actually named
5278     something starting with __ and the normal name is an alias.  */
5279 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5280 choke me
5281 #else
5282 $ac_func();
5283 #endif
5284
5285 ; return 0; }
5286 EOF
5287 if { (eval echo configure:5288: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5288   rm -rf conftest*
5289   eval "ac_cv_func_$ac_func=yes"
5290 else
5291   echo "configure: failed program was:" >&5
5292   cat conftest.$ac_ext >&5
5293   rm -rf conftest*
5294   eval "ac_cv_func_$ac_func=no"
5295 fi
5296 rm -f conftest*
5297 fi
5298
5299 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5300   echo "$ac_t""yes" 1>&6
5301     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5302   cat >> confdefs.h <<EOF
5303 #define $ac_tr_func 1
5304 EOF
5305  
5306 else
5307   echo "$ac_t""no" 1>&6
5308 fi
5309 done
5310
5311
5312    if test "${ac_cv_func_stpcpy+set}" != "set"; then
5313      for ac_func in stpcpy
5314 do
5315 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5316 echo "configure:5317: checking for $ac_func" >&5
5317 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5318   echo $ac_n "(cached) $ac_c" 1>&6
5319 else
5320   cat > conftest.$ac_ext <<EOF
5321 #line 5322 "configure"
5322 #include "confdefs.h"
5323 /* System header to define __stub macros and hopefully few prototypes,
5324     which can conflict with char $ac_func(); below.  */
5325 #include <assert.h>
5326 /* Override any gcc2 internal prototype to avoid an error.  */
5327 /* We use char because int might match the return type of a gcc2
5328     builtin and then its argument prototype would still apply.  */
5329 char $ac_func();
5330
5331 int main() {
5332
5333 /* The GNU C library defines this for functions which it implements
5334     to always fail with ENOSYS.  Some functions are actually named
5335     something starting with __ and the normal name is an alias.  */
5336 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5337 choke me
5338 #else
5339 $ac_func();
5340 #endif
5341
5342 ; return 0; }
5343 EOF
5344 if { (eval echo configure:5345: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5345   rm -rf conftest*
5346   eval "ac_cv_func_$ac_func=yes"
5347 else
5348   echo "configure: failed program was:" >&5
5349   cat conftest.$ac_ext >&5
5350   rm -rf conftest*
5351   eval "ac_cv_func_$ac_func=no"
5352 fi
5353 rm -f conftest*
5354 fi
5355
5356 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5357   echo "$ac_t""yes" 1>&6
5358     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5359   cat >> confdefs.h <<EOF
5360 #define $ac_tr_func 1
5361 EOF
5362  
5363 else
5364   echo "$ac_t""no" 1>&6
5365 fi
5366 done
5367
5368    fi
5369    if test "${ac_cv_func_stpcpy}" = "yes"; then
5370      cat >> confdefs.h <<\EOF
5371 #define HAVE_STPCPY 1
5372 EOF
5373
5374    fi
5375
5376    if test $ac_cv_header_locale_h = yes; then
5377     echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
5378 echo "configure:5379: checking for LC_MESSAGES" >&5
5379 if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
5380   echo $ac_n "(cached) $ac_c" 1>&6
5381 else
5382   cat > conftest.$ac_ext <<EOF
5383 #line 5384 "configure"
5384 #include "confdefs.h"
5385 #include <locale.h>
5386 int main() {
5387 return LC_MESSAGES
5388 ; return 0; }
5389 EOF
5390 if { (eval echo configure:5391: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5391   rm -rf conftest*
5392   am_cv_val_LC_MESSAGES=yes
5393 else
5394   echo "configure: failed program was:" >&5
5395   cat conftest.$ac_ext >&5
5396   rm -rf conftest*
5397   am_cv_val_LC_MESSAGES=no
5398 fi
5399 rm -f conftest*
5400 fi
5401
5402 echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
5403     if test $am_cv_val_LC_MESSAGES = yes; then
5404       cat >> confdefs.h <<\EOF
5405 #define HAVE_LC_MESSAGES 1
5406 EOF
5407
5408     fi
5409   fi
5410    echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
5411 echo "configure:5412: checking whether NLS is requested" >&5
5412         # Check whether --enable-nls or --disable-nls was given.
5413 if test "${enable_nls+set}" = set; then
5414   enableval="$enable_nls"
5415   USE_NLS=$enableval
5416 else
5417   USE_NLS=yes
5418 fi
5419
5420     echo "$ac_t""$USE_NLS" 1>&6
5421     
5422
5423     USE_INCLUDED_LIBINTL=no
5424
5425         if test "$USE_NLS" = "yes"; then
5426       cat >> confdefs.h <<\EOF
5427 #define ENABLE_NLS 1
5428 EOF
5429
5430       echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
5431 echo "configure:5432: checking whether included gettext is requested" >&5
5432       # Check whether --with-included-gettext or --without-included-gettext was given.
5433 if test "${with_included_gettext+set}" = set; then
5434   withval="$with_included_gettext"
5435   nls_cv_force_use_gnu_gettext=$withval
5436 else
5437   nls_cv_force_use_gnu_gettext=no
5438 fi
5439
5440       echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
5441
5442       nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
5443       if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
5444                                         nls_cv_header_intl=
5445         nls_cv_header_libgt=
5446         CATOBJEXT=NONE
5447
5448         ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
5449 echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
5450 echo "configure:5451: checking for libintl.h" >&5
5451 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5452   echo $ac_n "(cached) $ac_c" 1>&6
5453 else
5454   cat > conftest.$ac_ext <<EOF
5455 #line 5456 "configure"
5456 #include "confdefs.h"
5457 #include <libintl.h>
5458 EOF
5459 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5460 { (eval echo configure:5461: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5461 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5462 if test -z "$ac_err"; then
5463   rm -rf conftest*
5464   eval "ac_cv_header_$ac_safe=yes"
5465 else
5466   echo "$ac_err" >&5
5467   echo "configure: failed program was:" >&5
5468   cat conftest.$ac_ext >&5
5469   rm -rf conftest*
5470   eval "ac_cv_header_$ac_safe=no"
5471 fi
5472 rm -f conftest*
5473 fi
5474 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5475   echo "$ac_t""yes" 1>&6
5476   echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
5477 echo "configure:5478: checking for gettext in libc" >&5
5478 if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
5479   echo $ac_n "(cached) $ac_c" 1>&6
5480 else
5481   cat > conftest.$ac_ext <<EOF
5482 #line 5483 "configure"
5483 #include "confdefs.h"
5484 #include <libintl.h>
5485 int main() {
5486 return (int) gettext ("")
5487 ; return 0; }
5488 EOF
5489 if { (eval echo configure:5490: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5490   rm -rf conftest*
5491   gt_cv_func_gettext_libc=yes
5492 else
5493   echo "configure: failed program was:" >&5
5494   cat conftest.$ac_ext >&5
5495   rm -rf conftest*
5496   gt_cv_func_gettext_libc=no
5497 fi
5498 rm -f conftest*
5499 fi
5500
5501 echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
5502
5503            if test "$gt_cv_func_gettext_libc" != "yes"; then
5504              echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
5505 echo "configure:5506: checking for bindtextdomain in -lintl" >&5
5506 ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
5507 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5508   echo $ac_n "(cached) $ac_c" 1>&6
5509 else
5510   ac_save_LIBS="$LIBS"
5511 LIBS="-lintl  $LIBS"
5512 cat > conftest.$ac_ext <<EOF
5513 #line 5514 "configure"
5514 #include "confdefs.h"
5515 /* Override any gcc2 internal prototype to avoid an error.  */
5516 /* We use char because int might match the return type of a gcc2
5517     builtin and then its argument prototype would still apply.  */
5518 char bindtextdomain();
5519
5520 int main() {
5521 bindtextdomain()
5522 ; return 0; }
5523 EOF
5524 if { (eval echo configure:5525: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5525   rm -rf conftest*
5526   eval "ac_cv_lib_$ac_lib_var=yes"
5527 else
5528   echo "configure: failed program was:" >&5
5529   cat conftest.$ac_ext >&5
5530   rm -rf conftest*
5531   eval "ac_cv_lib_$ac_lib_var=no"
5532 fi
5533 rm -f conftest*
5534 LIBS="$ac_save_LIBS"
5535
5536 fi
5537 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5538   echo "$ac_t""yes" 1>&6
5539   echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
5540 echo "configure:5541: checking for gettext in libintl" >&5
5541 if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
5542   echo $ac_n "(cached) $ac_c" 1>&6
5543 else
5544   echo $ac_n "checking for gettext in -lintl""... $ac_c" 1>&6
5545 echo "configure:5546: checking for gettext in -lintl" >&5
5546 ac_lib_var=`echo intl'_'gettext | sed 'y%./+-%__p_%'`
5547 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5548   echo $ac_n "(cached) $ac_c" 1>&6
5549 else
5550   ac_save_LIBS="$LIBS"
5551 LIBS="-lintl  $LIBS"
5552 cat > conftest.$ac_ext <<EOF
5553 #line 5554 "configure"
5554 #include "confdefs.h"
5555 /* Override any gcc2 internal prototype to avoid an error.  */
5556 /* We use char because int might match the return type of a gcc2
5557     builtin and then its argument prototype would still apply.  */
5558 char gettext();
5559
5560 int main() {
5561 gettext()
5562 ; return 0; }
5563 EOF
5564 if { (eval echo configure:5565: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5565   rm -rf conftest*
5566   eval "ac_cv_lib_$ac_lib_var=yes"
5567 else
5568   echo "configure: failed program was:" >&5
5569   cat conftest.$ac_ext >&5
5570   rm -rf conftest*
5571   eval "ac_cv_lib_$ac_lib_var=no"
5572 fi
5573 rm -f conftest*
5574 LIBS="$ac_save_LIBS"
5575
5576 fi
5577 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5578   echo "$ac_t""yes" 1>&6
5579   gt_cv_func_gettext_libintl=yes
5580 else
5581   echo "$ac_t""no" 1>&6
5582 gt_cv_func_gettext_libintl=no
5583 fi
5584
5585 fi
5586
5587 echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6
5588 else
5589   echo "$ac_t""no" 1>&6
5590 fi
5591
5592            fi
5593
5594            if test "$gt_cv_func_gettext_libc" = "yes" \
5595               || test "$gt_cv_func_gettext_libintl" = "yes"; then
5596               cat >> confdefs.h <<\EOF
5597 #define HAVE_GETTEXT 1
5598 EOF
5599
5600               # Extract the first word of "msgfmt", so it can be a program name with args.
5601 set dummy msgfmt; ac_word=$2
5602 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5603 echo "configure:5604: checking for $ac_word" >&5
5604 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
5605   echo $ac_n "(cached) $ac_c" 1>&6
5606 else
5607   case "$MSGFMT" in
5608   /*)
5609   ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
5610   ;;
5611   *)
5612   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
5613   for ac_dir in $PATH; do
5614     test -z "$ac_dir" && ac_dir=.
5615     if test -f $ac_dir/$ac_word; then
5616       if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
5617         ac_cv_path_MSGFMT="$ac_dir/$ac_word"
5618         break
5619       fi
5620     fi
5621   done
5622   IFS="$ac_save_ifs"
5623   test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no"
5624   ;;
5625 esac
5626 fi
5627 MSGFMT="$ac_cv_path_MSGFMT"
5628 if test -n "$MSGFMT"; then
5629   echo "$ac_t""$MSGFMT" 1>&6
5630 else
5631   echo "$ac_t""no" 1>&6
5632 fi
5633               if test "$MSGFMT" != "no"; then
5634                 for ac_func in dcgettext
5635 do
5636 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5637 echo "configure:5638: checking for $ac_func" >&5
5638 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5639   echo $ac_n "(cached) $ac_c" 1>&6
5640 else
5641   cat > conftest.$ac_ext <<EOF
5642 #line 5643 "configure"
5643 #include "confdefs.h"
5644 /* System header to define __stub macros and hopefully few prototypes,
5645     which can conflict with char $ac_func(); below.  */
5646 #include <assert.h>
5647 /* Override any gcc2 internal prototype to avoid an error.  */
5648 /* We use char because int might match the return type of a gcc2
5649     builtin and then its argument prototype would still apply.  */
5650 char $ac_func();
5651
5652 int main() {
5653
5654 /* The GNU C library defines this for functions which it implements
5655     to always fail with ENOSYS.  Some functions are actually named
5656     something starting with __ and the normal name is an alias.  */
5657 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5658 choke me
5659 #else
5660 $ac_func();
5661 #endif
5662
5663 ; return 0; }
5664 EOF
5665 if { (eval echo configure:5666: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5666   rm -rf conftest*
5667   eval "ac_cv_func_$ac_func=yes"
5668 else
5669   echo "configure: failed program was:" >&5
5670   cat conftest.$ac_ext >&5
5671   rm -rf conftest*
5672   eval "ac_cv_func_$ac_func=no"
5673 fi
5674 rm -f conftest*
5675 fi
5676
5677 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5678   echo "$ac_t""yes" 1>&6
5679     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5680   cat >> confdefs.h <<EOF
5681 #define $ac_tr_func 1
5682 EOF
5683  
5684 else
5685   echo "$ac_t""no" 1>&6
5686 fi
5687 done
5688
5689                 # Extract the first word of "gmsgfmt", so it can be a program name with args.
5690 set dummy gmsgfmt; ac_word=$2
5691 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5692 echo "configure:5693: checking for $ac_word" >&5
5693 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
5694   echo $ac_n "(cached) $ac_c" 1>&6
5695 else
5696   case "$GMSGFMT" in
5697   /*)
5698   ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
5699   ;;
5700   ?:/*)                  
5701   ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
5702   ;;
5703   *)
5704   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
5705   ac_dummy="$PATH"
5706   for ac_dir in $ac_dummy; do 
5707     test -z "$ac_dir" && ac_dir=.
5708     if test -f $ac_dir/$ac_word; then
5709       ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
5710       break
5711     fi
5712   done
5713   IFS="$ac_save_ifs"
5714   test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
5715   ;;
5716 esac
5717 fi
5718 GMSGFMT="$ac_cv_path_GMSGFMT"
5719 if test -n "$GMSGFMT"; then
5720   echo "$ac_t""$GMSGFMT" 1>&6
5721 else
5722   echo "$ac_t""no" 1>&6
5723 fi
5724
5725                 # Extract the first word of "xgettext", so it can be a program name with args.
5726 set dummy xgettext; ac_word=$2
5727 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5728 echo "configure:5729: checking for $ac_word" >&5
5729 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
5730   echo $ac_n "(cached) $ac_c" 1>&6
5731 else
5732   case "$XGETTEXT" in
5733   /*)
5734   ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
5735   ;;
5736   *)
5737   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
5738   for ac_dir in $PATH; do
5739     test -z "$ac_dir" && ac_dir=.
5740     if test -f $ac_dir/$ac_word; then
5741       if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
5742         ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
5743         break
5744       fi
5745     fi
5746   done
5747   IFS="$ac_save_ifs"
5748   test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
5749   ;;
5750 esac
5751 fi
5752 XGETTEXT="$ac_cv_path_XGETTEXT"
5753 if test -n "$XGETTEXT"; then
5754   echo "$ac_t""$XGETTEXT" 1>&6
5755 else
5756   echo "$ac_t""no" 1>&6
5757 fi
5758
5759                 cat > conftest.$ac_ext <<EOF
5760 #line 5761 "configure"
5761 #include "confdefs.h"
5762
5763 int main() {
5764 extern int _nl_msg_cat_cntr;
5765                                return _nl_msg_cat_cntr
5766 ; return 0; }
5767 EOF
5768 if { (eval echo configure:5769: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5769   rm -rf conftest*
5770   CATOBJEXT=.gmo
5771                    DATADIRNAME=share
5772 else
5773   echo "configure: failed program was:" >&5
5774   cat conftest.$ac_ext >&5
5775   rm -rf conftest*
5776   CATOBJEXT=.mo
5777                    DATADIRNAME=lib
5778 fi
5779 rm -f conftest*
5780                 INSTOBJEXT=.mo
5781               fi
5782             fi
5783         
5784 else
5785   echo "$ac_t""no" 1>&6
5786 fi
5787
5788
5789         if test "$CATOBJEXT" = "NONE"; then
5790           echo $ac_n "checking whether catgets can be used""... $ac_c" 1>&6
5791 echo "configure:5792: checking whether catgets can be used" >&5
5792           # Check whether --with-catgets or --without-catgets was given.
5793 if test "${with_catgets+set}" = set; then
5794   withval="$with_catgets"
5795   nls_cv_use_catgets=$withval
5796 else
5797   nls_cv_use_catgets=no
5798 fi
5799
5800           echo "$ac_t""$nls_cv_use_catgets" 1>&6
5801
5802           if test "$nls_cv_use_catgets" = "yes"; then
5803                     echo $ac_n "checking for main in -li""... $ac_c" 1>&6
5804 echo "configure:5805: checking for main in -li" >&5
5805 ac_lib_var=`echo i'_'main | sed 'y%./+-%__p_%'`
5806 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5807   echo $ac_n "(cached) $ac_c" 1>&6
5808 else
5809   ac_save_LIBS="$LIBS"
5810 LIBS="-li  $LIBS"
5811 cat > conftest.$ac_ext <<EOF
5812 #line 5813 "configure"
5813 #include "confdefs.h"
5814
5815 int main() {
5816 main()
5817 ; return 0; }
5818 EOF
5819 if { (eval echo configure:5820: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5820   rm -rf conftest*
5821   eval "ac_cv_lib_$ac_lib_var=yes"
5822 else
5823   echo "configure: failed program was:" >&5
5824   cat conftest.$ac_ext >&5
5825   rm -rf conftest*
5826   eval "ac_cv_lib_$ac_lib_var=no"
5827 fi
5828 rm -f conftest*
5829 LIBS="$ac_save_LIBS"
5830
5831 fi
5832 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5833   echo "$ac_t""yes" 1>&6
5834     ac_tr_lib=HAVE_LIB`echo i | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5835     -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5836   cat >> confdefs.h <<EOF
5837 #define $ac_tr_lib 1
5838 EOF
5839
5840   LIBS="-li $LIBS"
5841
5842 else
5843   echo "$ac_t""no" 1>&6
5844 fi
5845
5846             echo $ac_n "checking for catgets""... $ac_c" 1>&6
5847 echo "configure:5848: checking for catgets" >&5
5848 if eval "test \"`echo '$''{'ac_cv_func_catgets'+set}'`\" = set"; then
5849   echo $ac_n "(cached) $ac_c" 1>&6
5850 else
5851   cat > conftest.$ac_ext <<EOF
5852 #line 5853 "configure"
5853 #include "confdefs.h"
5854 /* System header to define __stub macros and hopefully few prototypes,
5855     which can conflict with char catgets(); below.  */
5856 #include <assert.h>
5857 /* Override any gcc2 internal prototype to avoid an error.  */
5858 /* We use char because int might match the return type of a gcc2
5859     builtin and then its argument prototype would still apply.  */
5860 char catgets();
5861
5862 int main() {
5863
5864 /* The GNU C library defines this for functions which it implements
5865     to always fail with ENOSYS.  Some functions are actually named
5866     something starting with __ and the normal name is an alias.  */
5867 #if defined (__stub_catgets) || defined (__stub___catgets)
5868 choke me
5869 #else
5870 catgets();
5871 #endif
5872
5873 ; return 0; }
5874 EOF
5875 if { (eval echo configure:5876: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5876   rm -rf conftest*
5877   eval "ac_cv_func_catgets=yes"
5878 else
5879   echo "configure: failed program was:" >&5
5880   cat conftest.$ac_ext >&5
5881   rm -rf conftest*
5882   eval "ac_cv_func_catgets=no"
5883 fi
5884 rm -f conftest*
5885 fi
5886
5887 if eval "test \"`echo '$ac_cv_func_'catgets`\" = yes"; then
5888   echo "$ac_t""yes" 1>&6
5889   cat >> confdefs.h <<\EOF
5890 #define HAVE_CATGETS 1
5891 EOF
5892
5893                INTLOBJS="\$(CATOBJS)"
5894                # Extract the first word of "gencat", so it can be a program name with args.
5895 set dummy gencat; ac_word=$2
5896 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5897 echo "configure:5898: checking for $ac_word" >&5
5898 if eval "test \"`echo '$''{'ac_cv_path_GENCAT'+set}'`\" = set"; then
5899   echo $ac_n "(cached) $ac_c" 1>&6
5900 else
5901   case "$GENCAT" in
5902   /*)
5903   ac_cv_path_GENCAT="$GENCAT" # Let the user override the test with a path.
5904   ;;
5905   ?:/*)                  
5906   ac_cv_path_GENCAT="$GENCAT" # Let the user override the test with a dos path.
5907   ;;
5908   *)
5909   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
5910   ac_dummy="$PATH"
5911   for ac_dir in $ac_dummy; do 
5912     test -z "$ac_dir" && ac_dir=.
5913     if test -f $ac_dir/$ac_word; then
5914       ac_cv_path_GENCAT="$ac_dir/$ac_word"
5915       break
5916     fi
5917   done
5918   IFS="$ac_save_ifs"
5919   test -z "$ac_cv_path_GENCAT" && ac_cv_path_GENCAT="no"
5920   ;;
5921 esac
5922 fi
5923 GENCAT="$ac_cv_path_GENCAT"
5924 if test -n "$GENCAT"; then
5925   echo "$ac_t""$GENCAT" 1>&6
5926 else
5927   echo "$ac_t""no" 1>&6
5928 fi
5929                if test "$GENCAT" != "no"; then
5930                  # Extract the first word of "gmsgfmt", so it can be a program name with args.
5931 set dummy gmsgfmt; ac_word=$2
5932 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5933 echo "configure:5934: checking for $ac_word" >&5
5934 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
5935   echo $ac_n "(cached) $ac_c" 1>&6
5936 else
5937   case "$GMSGFMT" in
5938   /*)
5939   ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
5940   ;;
5941   ?:/*)                  
5942   ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
5943   ;;
5944   *)
5945   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
5946   ac_dummy="$PATH"
5947   for ac_dir in $ac_dummy; do 
5948     test -z "$ac_dir" && ac_dir=.
5949     if test -f $ac_dir/$ac_word; then
5950       ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
5951       break
5952     fi
5953   done
5954   IFS="$ac_save_ifs"
5955   test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="no"
5956   ;;
5957 esac
5958 fi
5959 GMSGFMT="$ac_cv_path_GMSGFMT"
5960 if test -n "$GMSGFMT"; then
5961   echo "$ac_t""$GMSGFMT" 1>&6
5962 else
5963   echo "$ac_t""no" 1>&6
5964 fi
5965
5966                  if test "$GMSGFMT" = "no"; then
5967                    # Extract the first word of "msgfmt", so it can be a program name with args.
5968 set dummy msgfmt; ac_word=$2
5969 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5970 echo "configure:5971: checking for $ac_word" >&5
5971 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
5972   echo $ac_n "(cached) $ac_c" 1>&6
5973 else
5974   case "$GMSGFMT" in
5975   /*)
5976   ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
5977   ;;
5978   *)
5979   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
5980   for ac_dir in $PATH; do
5981     test -z "$ac_dir" && ac_dir=.
5982     if test -f $ac_dir/$ac_word; then
5983       if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
5984         ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
5985         break
5986       fi
5987     fi
5988   done
5989   IFS="$ac_save_ifs"
5990   test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="no"
5991   ;;
5992 esac
5993 fi
5994 GMSGFMT="$ac_cv_path_GMSGFMT"
5995 if test -n "$GMSGFMT"; then
5996   echo "$ac_t""$GMSGFMT" 1>&6
5997 else
5998   echo "$ac_t""no" 1>&6
5999 fi
6000
6001                  fi
6002                  # Extract the first word of "xgettext", so it can be a program name with args.
6003 set dummy xgettext; ac_word=$2
6004 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
6005 echo "configure:6006: checking for $ac_word" >&5
6006 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
6007   echo $ac_n "(cached) $ac_c" 1>&6
6008 else
6009   case "$XGETTEXT" in
6010   /*)
6011   ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
6012   ;;
6013   *)
6014   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
6015   for ac_dir in $PATH; do
6016     test -z "$ac_dir" && ac_dir=.
6017     if test -f $ac_dir/$ac_word; then
6018       if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
6019         ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
6020         break
6021       fi
6022     fi
6023   done
6024   IFS="$ac_save_ifs"
6025   test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
6026   ;;
6027 esac
6028 fi
6029 XGETTEXT="$ac_cv_path_XGETTEXT"
6030 if test -n "$XGETTEXT"; then
6031   echo "$ac_t""$XGETTEXT" 1>&6
6032 else
6033   echo "$ac_t""no" 1>&6
6034 fi
6035
6036                  USE_INCLUDED_LIBINTL=yes
6037                  CATOBJEXT=.cat
6038                  INSTOBJEXT=.cat
6039                  DATADIRNAME=lib
6040                  INTLDEPS='$(top_builddir)/intl/libintl.a'
6041                  INTLLIBS=$INTLDEPS
6042                  LIBS=`echo $LIBS | sed -e 's/-lintl//'`
6043                  nls_cv_header_intl=intl/libintl.h
6044                  nls_cv_header_libgt=intl/libgettext.h
6045                fi
6046 else
6047   echo "$ac_t""no" 1>&6
6048 fi
6049
6050           fi
6051         fi
6052
6053         if test "$CATOBJEXT" = "NONE"; then
6054                           nls_cv_use_gnu_gettext=yes
6055         fi
6056       fi
6057
6058       if test "$nls_cv_use_gnu_gettext" = "yes"; then
6059                 INTLOBJS="\$(GETTOBJS)"
6060         # Extract the first word of "msgfmt", so it can be a program name with args.
6061 set dummy msgfmt; ac_word=$2
6062 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
6063 echo "configure:6064: checking for $ac_word" >&5
6064 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
6065   echo $ac_n "(cached) $ac_c" 1>&6
6066 else
6067   case "$MSGFMT" in
6068   /*)
6069   ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
6070   ;;
6071   *)
6072   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
6073   for ac_dir in $PATH; do
6074     test -z "$ac_dir" && ac_dir=.
6075     if test -f $ac_dir/$ac_word; then
6076       if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
6077         ac_cv_path_MSGFMT="$ac_dir/$ac_word"
6078         break
6079       fi
6080     fi
6081   done
6082   IFS="$ac_save_ifs"
6083   test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt"
6084   ;;
6085 esac
6086 fi
6087 MSGFMT="$ac_cv_path_MSGFMT"
6088 if test -n "$MSGFMT"; then
6089   echo "$ac_t""$MSGFMT" 1>&6
6090 else
6091   echo "$ac_t""no" 1>&6
6092 fi
6093
6094         # Extract the first word of "gmsgfmt", so it can be a program name with args.
6095 set dummy gmsgfmt; ac_word=$2
6096 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
6097 echo "configure:6098: checking for $ac_word" >&5
6098 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
6099   echo $ac_n "(cached) $ac_c" 1>&6
6100 else
6101   case "$GMSGFMT" in
6102   /*)
6103   ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
6104   ;;
6105   ?:/*)                  
6106   ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
6107   ;;
6108   *)
6109   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
6110   ac_dummy="$PATH"
6111   for ac_dir in $ac_dummy; do 
6112     test -z "$ac_dir" && ac_dir=.
6113     if test -f $ac_dir/$ac_word; then
6114       ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
6115       break
6116     fi
6117   done
6118   IFS="$ac_save_ifs"
6119   test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
6120   ;;
6121 esac
6122 fi
6123 GMSGFMT="$ac_cv_path_GMSGFMT"
6124 if test -n "$GMSGFMT"; then
6125   echo "$ac_t""$GMSGFMT" 1>&6
6126 else
6127   echo "$ac_t""no" 1>&6
6128 fi
6129
6130         # Extract the first word of "xgettext", so it can be a program name with args.
6131 set dummy xgettext; ac_word=$2
6132 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
6133 echo "configure:6134: checking for $ac_word" >&5
6134 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
6135   echo $ac_n "(cached) $ac_c" 1>&6
6136 else
6137   case "$XGETTEXT" in
6138   /*)
6139   ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
6140   ;;
6141   *)
6142   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
6143   for ac_dir in $PATH; do
6144     test -z "$ac_dir" && ac_dir=.
6145     if test -f $ac_dir/$ac_word; then
6146       if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
6147         ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
6148         break
6149       fi
6150     fi
6151   done
6152   IFS="$ac_save_ifs"
6153   test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
6154   ;;
6155 esac
6156 fi
6157 XGETTEXT="$ac_cv_path_XGETTEXT"
6158 if test -n "$XGETTEXT"; then
6159   echo "$ac_t""$XGETTEXT" 1>&6
6160 else
6161   echo "$ac_t""no" 1>&6
6162 fi
6163
6164         
6165         USE_INCLUDED_LIBINTL=yes
6166         CATOBJEXT=.gmo
6167         INSTOBJEXT=.mo
6168         DATADIRNAME=share
6169         INTLDEPS='$(top_builddir)/intl/libintl.a'
6170         INTLLIBS=$INTLDEPS
6171         LIBS=`echo $LIBS | sed -e 's/-lintl//'`
6172         nls_cv_header_intl=intl/libintl.h
6173         nls_cv_header_libgt=intl/libgettext.h
6174       fi
6175
6176             if test "$XGETTEXT" != ":"; then
6177                         if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
6178           : ;
6179         else
6180           echo "$ac_t""found xgettext program is not GNU xgettext; ignore it" 1>&6
6181           XGETTEXT=":"
6182         fi
6183       fi
6184
6185       # We need to process the po/ directory.
6186       POSUB=po
6187     else
6188       DATADIRNAME=share
6189       nls_cv_header_intl=intl/libintl.h
6190       nls_cv_header_libgt=intl/libgettext.h
6191     fi
6192     
6193     
6194
6195
6196     # If this is used in GNU gettext we have to set USE_NLS to `yes'
6197     # because some of the sources are only built for this goal.
6198     if test "$PACKAGE" = gettext; then
6199       USE_NLS=yes
6200       USE_INCLUDED_LIBINTL=yes
6201     fi
6202
6203                 for lang in $ALL_LINGUAS; do
6204       GMOFILES="$GMOFILES $lang.gmo"
6205       POFILES="$POFILES $lang.po"
6206     done
6207
6208         
6209     
6210     
6211     
6212     
6213     
6214     
6215     
6216     
6217     
6218     
6219   
6220
6221    if test "x$CATOBJEXT" != "x"; then
6222      if test "x$ALL_LINGUAS" = "x"; then
6223        LINGUAS=
6224      else
6225        echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
6226 echo "configure:6227: checking for catalogs to be installed" >&5
6227        NEW_LINGUAS=
6228        for lang in ${LINGUAS=$ALL_LINGUAS}; do
6229          case "$ALL_LINGUAS" in
6230           *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;;
6231          esac
6232        done
6233        LINGUAS=$NEW_LINGUAS
6234        echo "$ac_t""$LINGUAS" 1>&6
6235      fi
6236
6237           if test -n "$LINGUAS"; then
6238        for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
6239      fi
6240    fi
6241
6242             if test $ac_cv_header_locale_h = yes; then
6243      INCLUDE_LOCALE_H="#include <locale.h>"
6244    else
6245      INCLUDE_LOCALE_H="\
6246 /* The system does not provide the header <locale.h>.  Take care yourself.  */"
6247    fi
6248    
6249
6250             test -d intl || mkdir intl
6251    if test "$CATOBJEXT" = ".cat"; then
6252      ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
6253 echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
6254 echo "configure:6255: checking for linux/version.h" >&5
6255 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
6256   echo $ac_n "(cached) $ac_c" 1>&6
6257 else
6258   cat > conftest.$ac_ext <<EOF
6259 #line 6260 "configure"
6260 #include "confdefs.h"
6261 #include <linux/version.h>
6262 EOF
6263 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6264 { (eval echo configure:6265: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6265 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
6266 if test -z "$ac_err"; then
6267   rm -rf conftest*
6268   eval "ac_cv_header_$ac_safe=yes"
6269 else
6270   echo "$ac_err" >&5
6271   echo "configure: failed program was:" >&5
6272   cat conftest.$ac_ext >&5
6273   rm -rf conftest*
6274   eval "ac_cv_header_$ac_safe=no"
6275 fi
6276 rm -f conftest*
6277 fi
6278 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
6279   echo "$ac_t""yes" 1>&6
6280   msgformat=linux
6281 else
6282   echo "$ac_t""no" 1>&6
6283 msgformat=xopen
6284 fi
6285
6286
6287                sed -e '/^#/d' $srcdir/intl/$msgformat-msg.sed > intl/po2msg.sed
6288    fi
6289       sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \
6290      $srcdir/intl/po2tbl.sed.in > intl/po2tbl.sed
6291
6292             if test "$PACKAGE" = "gettext"; then
6293      GT_NO="#NO#"
6294      GT_YES=
6295    else
6296      GT_NO=
6297      GT_YES="#YES#"
6298    fi
6299    
6300    
6301
6302             MKINSTALLDIRS=
6303    if test -n "$ac_aux_dir"; then
6304      MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
6305    fi
6306    if test -z "$MKINSTALLDIRS"; then
6307      MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
6308    fi
6309    
6310
6311       l=
6312    
6313
6314          test -d po || mkdir po
6315    if test "x$srcdir" != "x."; then
6316      if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
6317        posrcprefix="$srcdir/"
6318      else
6319        posrcprefix="../$srcdir/"
6320      fi
6321    else
6322      posrcprefix="../"
6323    fi
6324    rm -f po/POTFILES
6325    sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
6326         < $srcdir/po/POTFILES.in > po/POTFILES
6327   
6328
6329 trap '' 1 2 15
6330 cat > confcache <<\EOF
6331 # This file is a shell script that caches the results of configure
6332 # tests run on this system so they can be shared between configure
6333 # scripts and configure runs.  It is not useful on other systems.
6334 # If it contains results you don't want to keep, you may remove or edit it.
6335 #
6336 # By default, configure uses ./config.cache as the cache file,
6337 # creating it if it does not exist already.  You can give configure
6338 # the --cache-file=FILE option to use a different cache file; that is
6339 # what configure does when it calls configure scripts in
6340 # subdirectories, so they share the cache.
6341 # Giving --cache-file=/dev/null disables caching, for debugging configure.
6342 # config.status only pays attention to the cache file if you give it the
6343 # --recheck option to rerun configure.
6344 #
6345 EOF
6346 # The following way of writing the cache mishandles newlines in values,
6347 # but we know of no workaround that is simple, portable, and efficient.
6348 # So, don't put newlines in cache variables' values.
6349 # Ultrix sh set writes to stderr and can't be redirected directly,
6350 # and sets the high bit in the cache file unless we assign to the vars.
6351 (set) 2>&1 |
6352   case `(ac_space=' '; set | grep ac_space) 2>&1` in
6353   *ac_space=\ *)
6354     # `set' does not quote correctly, so add quotes (double-quote substitution
6355     # turns \\\\ into \\, and sed turns \\ into \).
6356     sed -n \
6357       -e "s/'/'\\\\''/g" \
6358       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
6359     ;;
6360   *)
6361     # `set' quotes correctly as required by POSIX, so do not add quotes.
6362     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
6363     ;;
6364   esac >> confcache
6365 if cmp -s $cache_file confcache; then
6366   :
6367 else
6368   if test -w $cache_file; then
6369     echo "updating cache $cache_file"
6370     cat confcache > $cache_file
6371   else
6372     echo "not updating unwritable cache $cache_file"
6373   fi
6374 fi
6375 rm -f confcache
6376
6377 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
6378
6379 test "x$prefix" = xNONE && prefix=$ac_default_prefix
6380 # Let make expand exec_prefix.
6381 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6382
6383 # Any assignment to VPATH causes Sun make to only execute
6384 # the first set of double-colon rules, so remove it if not needed.
6385 # If there is a colon in the path, we need to keep it.
6386 if test "x$srcdir" = x.; then
6387   ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
6388 fi
6389
6390 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
6391
6392 DEFS=-DHAVE_CONFIG_H
6393
6394 # Without the "./", some shells look in PATH for config.status.
6395 : ${CONFIG_STATUS=./config.status}
6396
6397 echo creating $CONFIG_STATUS
6398 rm -f $CONFIG_STATUS
6399 cat > $CONFIG_STATUS <<EOF
6400 #! /bin/sh
6401 # Generated automatically by configure.
6402 # Run this file to recreate the current configuration.
6403 # This directory was configured as follows,
6404 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
6405 #
6406 # $0 $ac_configure_args
6407 #
6408 # Compiler output produced by configure, useful for debugging
6409 # configure, is in ./config.log if it exists.
6410
6411 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
6412 for ac_option
6413 do
6414   case "\$ac_option" in
6415   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
6416     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
6417     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
6418   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
6419     echo "$CONFIG_STATUS generated by autoconf version 2.13"
6420     exit 0 ;;
6421   -help | --help | --hel | --he | --h)
6422     echo "\$ac_cs_usage"; exit 0 ;;
6423   *) echo "\$ac_cs_usage"; exit 1 ;;
6424   esac
6425 done
6426
6427 ac_given_srcdir=$srcdir
6428 ac_given_INSTALL="$INSTALL"
6429
6430 trap 'rm -fr `echo "libmisc/Makefile man/Makefile man/pl/Makefile
6431         lib/Makefile src/Makefile Makefile
6432         contrib/Makefile debian/Makefile doc/Makefile etc/Makefile
6433         intl/Makefile intl/po2tbl.sed po/Makefile.in
6434         etc/pam.d/Makefile old/Makefile
6435         redhat/Makefile redhat/shadow-utils.spec config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
6436 EOF
6437 cat >> $CONFIG_STATUS <<EOF
6438
6439 # Protect against being on the right side of a sed subst in config.status.
6440 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
6441  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
6442 $ac_vpsub
6443 $extrasub
6444 s%@SHELL@%$SHELL%g
6445 s%@CFLAGS@%$CFLAGS%g
6446 s%@CPPFLAGS@%$CPPFLAGS%g
6447 s%@CXXFLAGS@%$CXXFLAGS%g
6448 s%@FFLAGS@%$FFLAGS%g
6449 s%@DEFS@%$DEFS%g
6450 s%@LDFLAGS@%$LDFLAGS%g
6451 s%@LIBS@%$LIBS%g
6452 s%@exec_prefix@%$exec_prefix%g
6453 s%@prefix@%$prefix%g
6454 s%@program_transform_name@%$program_transform_name%g
6455 s%@bindir@%$bindir%g
6456 s%@sbindir@%$sbindir%g
6457 s%@libexecdir@%$libexecdir%g
6458 s%@datadir@%$datadir%g
6459 s%@sysconfdir@%$sysconfdir%g
6460 s%@sharedstatedir@%$sharedstatedir%g
6461 s%@localstatedir@%$localstatedir%g
6462 s%@libdir@%$libdir%g
6463 s%@includedir@%$includedir%g
6464 s%@oldincludedir@%$oldincludedir%g
6465 s%@infodir@%$infodir%g
6466 s%@mandir@%$mandir%g
6467 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
6468 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
6469 s%@INSTALL_DATA@%$INSTALL_DATA%g
6470 s%@PACKAGE@%$PACKAGE%g
6471 s%@VERSION@%$VERSION%g
6472 s%@ACLOCAL@%$ACLOCAL%g
6473 s%@AUTOCONF@%$AUTOCONF%g
6474 s%@AUTOMAKE@%$AUTOMAKE%g
6475 s%@AUTOHEADER@%$AUTOHEADER%g
6476 s%@MAKEINFO@%$MAKEINFO%g
6477 s%@SET_MAKE@%$SET_MAKE%g
6478 s%@CC@%$CC%g
6479 s%@LN_S@%$LN_S%g
6480 s%@YACC@%$YACC%g
6481 s%@CPP@%$CPP%g
6482 s%@U@%$U%g
6483 s%@ANSI2KNR@%$ANSI2KNR%g
6484 s%@host@%$host%g
6485 s%@host_alias@%$host_alias%g
6486 s%@host_cpu@%$host_cpu%g
6487 s%@host_vendor@%$host_vendor%g
6488 s%@host_os@%$host_os%g
6489 s%@build@%$build%g
6490 s%@build_alias@%$build_alias%g
6491 s%@build_cpu@%$build_cpu%g
6492 s%@build_vendor@%$build_vendor%g
6493 s%@build_os@%$build_os%g
6494 s%@RANLIB@%$RANLIB%g
6495 s%@LD@%$LD%g
6496 s%@NM@%$NM%g
6497 s%@LIBTOOL@%$LIBTOOL%g
6498 s%@LIBOBJS@%$LIBOBJS%g
6499 s%@LIBCRYPT@%$LIBCRYPT%g
6500 s%@LIBCRACK@%$LIBCRACK%g
6501 s%@LIBSKEY@%$LIBSKEY%g
6502 s%@LIBMD@%$LIBMD%g
6503 s%@LIBTCFS@%$LIBTCFS%g
6504 s%@LIBPAM@%$LIBPAM%g
6505 s%@LTLIBOBJS@%$LTLIBOBJS%g
6506 s%@ALLOCA@%$ALLOCA%g
6507 s%@USE_NLS@%$USE_NLS%g
6508 s%@MSGFMT@%$MSGFMT%g
6509 s%@GMSGFMT@%$GMSGFMT%g
6510 s%@XGETTEXT@%$XGETTEXT%g
6511 s%@GENCAT@%$GENCAT%g
6512 s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g
6513 s%@CATALOGS@%$CATALOGS%g
6514 s%@CATOBJEXT@%$CATOBJEXT%g
6515 s%@DATADIRNAME@%$DATADIRNAME%g
6516 s%@GMOFILES@%$GMOFILES%g
6517 s%@INSTOBJEXT@%$INSTOBJEXT%g
6518 s%@INTLDEPS@%$INTLDEPS%g
6519 s%@INTLLIBS@%$INTLLIBS%g
6520 s%@INTLOBJS@%$INTLOBJS%g
6521 s%@POFILES@%$POFILES%g
6522 s%@POSUB@%$POSUB%g
6523 s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g
6524 s%@GT_NO@%$GT_NO%g
6525 s%@GT_YES@%$GT_YES%g
6526 s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
6527 s%@l@%$l%g
6528
6529 CEOF
6530 EOF
6531
6532 cat >> $CONFIG_STATUS <<\EOF
6533
6534 # Split the substitutions into bite-sized pieces for seds with
6535 # small command number limits, like on Digital OSF/1 and HP-UX.
6536 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
6537 ac_file=1 # Number of current file.
6538 ac_beg=1 # First line for current file.
6539 ac_end=$ac_max_sed_cmds # Line after last line for current file.
6540 ac_more_lines=:
6541 ac_sed_cmds=""
6542 while $ac_more_lines; do
6543   if test $ac_beg -gt 1; then
6544     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
6545   else
6546     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
6547   fi
6548   if test ! -s conftest.s$ac_file; then
6549     ac_more_lines=false
6550     rm -f conftest.s$ac_file
6551   else
6552     if test -z "$ac_sed_cmds"; then
6553       ac_sed_cmds="sed -f conftest.s$ac_file"
6554     else
6555       ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
6556     fi
6557     ac_file=`expr $ac_file + 1`
6558     ac_beg=$ac_end
6559     ac_end=`expr $ac_end + $ac_max_sed_cmds`
6560   fi
6561 done
6562 if test -z "$ac_sed_cmds"; then
6563   ac_sed_cmds=cat
6564 fi
6565 EOF
6566
6567 cat >> $CONFIG_STATUS <<EOF
6568
6569 CONFIG_FILES=\${CONFIG_FILES-"libmisc/Makefile man/Makefile man/pl/Makefile
6570         lib/Makefile src/Makefile Makefile
6571         contrib/Makefile debian/Makefile doc/Makefile etc/Makefile
6572         intl/Makefile intl/po2tbl.sed po/Makefile.in
6573         etc/pam.d/Makefile old/Makefile
6574         redhat/Makefile redhat/shadow-utils.spec"}
6575 EOF
6576 cat >> $CONFIG_STATUS <<\EOF
6577 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
6578   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
6579   case "$ac_file" in
6580   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
6581        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
6582   *) ac_file_in="${ac_file}.in" ;;
6583   esac
6584
6585   # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
6586
6587   # Remove last slash and all that follows it.  Not all systems have dirname.
6588   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
6589   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
6590     # The file is in a subdirectory.
6591     test ! -d "$ac_dir" && mkdir "$ac_dir"
6592     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
6593     # A "../" for each directory in $ac_dir_suffix.
6594     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
6595   else
6596     ac_dir_suffix= ac_dots=
6597   fi
6598
6599   case "$ac_given_srcdir" in
6600   .)  srcdir=.
6601       if test -z "$ac_dots"; then top_srcdir=.
6602       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
6603   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
6604   *) # Relative path.
6605     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
6606     top_srcdir="$ac_dots$ac_given_srcdir" ;;
6607   esac
6608
6609   case "$ac_given_INSTALL" in
6610   [/$]*) INSTALL="$ac_given_INSTALL" ;;
6611   *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
6612   esac
6613
6614   echo creating "$ac_file"
6615   rm -f "$ac_file"
6616   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
6617   case "$ac_file" in
6618   *Makefile*) ac_comsub="1i\\
6619 # $configure_input" ;;
6620   *) ac_comsub= ;;
6621   esac
6622
6623   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
6624   sed -e "$ac_comsub
6625 s%@configure_input@%$configure_input%g
6626 s%@srcdir@%$srcdir%g
6627 s%@top_srcdir@%$top_srcdir%g
6628 s%@INSTALL@%$INSTALL%g
6629 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
6630 fi; done
6631 rm -f conftest.s*
6632
6633 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
6634 # NAME is the cpp macro being defined and VALUE is the value it is being given.
6635 #
6636 # ac_d sets the value in "#define NAME VALUE" lines.
6637 ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
6638 ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
6639 ac_dC='\3'
6640 ac_dD='%g'
6641 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
6642 ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
6643 ac_uB='\([      ]\)%\1#\2define\3'
6644 ac_uC=' '
6645 ac_uD='\4%g'
6646 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
6647 ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
6648 ac_eB='$%\1#\2define\3'
6649 ac_eC=' '
6650 ac_eD='%g'
6651
6652 if test "${CONFIG_HEADERS+set}" != set; then
6653 EOF
6654 cat >> $CONFIG_STATUS <<EOF
6655   CONFIG_HEADERS="config.h"
6656 EOF
6657 cat >> $CONFIG_STATUS <<\EOF
6658 fi
6659 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
6660   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
6661   case "$ac_file" in
6662   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
6663        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
6664   *) ac_file_in="${ac_file}.in" ;;
6665   esac
6666
6667   echo creating $ac_file
6668
6669   rm -f conftest.frag conftest.in conftest.out
6670   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
6671   cat $ac_file_inputs > conftest.in
6672
6673 EOF
6674
6675 # Transform confdefs.h into a sed script conftest.vals that substitutes
6676 # the proper values into config.h.in to produce config.h.  And first:
6677 # Protect against being on the right side of a sed subst in config.status.
6678 # Protect against being in an unquoted here document in config.status.
6679 rm -f conftest.vals
6680 cat > conftest.hdr <<\EOF
6681 s/[\\&%]/\\&/g
6682 s%[\\$`]%\\&%g
6683 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
6684 s%ac_d%ac_u%gp
6685 s%ac_u%ac_e%gp
6686 EOF
6687 sed -n -f conftest.hdr confdefs.h > conftest.vals
6688 rm -f conftest.hdr
6689
6690 # This sed command replaces #undef with comments.  This is necessary, for
6691 # example, in the case of _POSIX_SOURCE, which is predefined and required
6692 # on some systems where configure will not decide to define it.
6693 cat >> conftest.vals <<\EOF
6694 s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
6695 EOF
6696
6697 # Break up conftest.vals because some shells have a limit on
6698 # the size of here documents, and old seds have small limits too.
6699
6700 rm -f conftest.tail
6701 while :
6702 do
6703   ac_lines=`grep -c . conftest.vals`
6704   # grep -c gives empty output for an empty file on some AIX systems.
6705   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
6706   # Write a limited-size here document to conftest.frag.
6707   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
6708   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
6709   echo 'CEOF
6710   sed -f conftest.frag conftest.in > conftest.out
6711   rm -f conftest.in
6712   mv conftest.out conftest.in
6713 ' >> $CONFIG_STATUS
6714   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
6715   rm -f conftest.vals
6716   mv conftest.tail conftest.vals
6717 done
6718 rm -f conftest.vals
6719
6720 cat >> $CONFIG_STATUS <<\EOF
6721   rm -f conftest.frag conftest.h
6722   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
6723   cat conftest.in >> conftest.h
6724   rm -f conftest.in
6725   if cmp -s $ac_file conftest.h 2>/dev/null; then
6726     echo "$ac_file is unchanged"
6727     rm -f conftest.h
6728   else
6729     # Remove last slash and all that follows it.  Not all systems have dirname.
6730       ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
6731       if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
6732       # The file is in a subdirectory.
6733       test ! -d "$ac_dir" && mkdir "$ac_dir"
6734     fi
6735     rm -f $ac_file
6736     mv conftest.h $ac_file
6737   fi
6738 fi; done
6739
6740 EOF
6741
6742 cat >> $CONFIG_STATUS <<EOF
6743 ac_sources="$nls_cv_header_libgt"
6744 ac_dests="$nls_cv_header_intl"
6745 EOF
6746
6747 cat >> $CONFIG_STATUS <<\EOF
6748 srcdir=$ac_given_srcdir
6749 while test -n "$ac_sources"; do
6750   set $ac_dests; ac_dest=$1; shift; ac_dests=$*
6751   set $ac_sources; ac_source=$1; shift; ac_sources=$*
6752
6753   echo "linking $srcdir/$ac_source to $ac_dest"
6754
6755   if test ! -r $srcdir/$ac_source; then
6756     { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; }
6757   fi
6758   rm -f $ac_dest
6759
6760   # Make relative symlinks.
6761   # Remove last slash and all that follows it.  Not all systems have dirname.
6762   ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'`
6763   if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then
6764     # The dest file is in a subdirectory.
6765     test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir"
6766     ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`"
6767     # A "../" for each directory in $ac_dest_dir_suffix.
6768     ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'`
6769   else
6770     ac_dest_dir_suffix= ac_dots=
6771   fi
6772
6773   case "$srcdir" in
6774   [/$]*) ac_rel_source="$srcdir/$ac_source" ;;
6775   *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;;
6776   esac
6777
6778   # Make a symlink if possible; otherwise try a hard link.
6779   if ln -s $ac_rel_source $ac_dest 2>/dev/null ||
6780     ln $srcdir/$ac_source $ac_dest; then :
6781   else
6782     { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; }
6783   fi
6784 done
6785 EOF
6786 cat >> $CONFIG_STATUS <<EOF
6787
6788
6789
6790 EOF
6791 cat >> $CONFIG_STATUS <<\EOF
6792 test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
6793 case "$CONFIG_FILES" in *po/Makefile.in*)
6794         sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile
6795       esac
6796 echo timestamp > stamp-h
6797 exit 0
6798 EOF
6799 chmod +x $CONFIG_STATUS
6800 rm -fr confdefs* $ac_clean_files
6801 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
6802
6803