ran autoconf
[kai/samba.git] / source3 / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by Autoconf 2.52.
4 #
5 # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
6 # Free Software Foundation, Inc.
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
9
10 # Avoid depending upon Character Ranges.
11 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
12 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
13 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
14 as_cr_digits='0123456789'
15 as_cr_alnum=$as_cr_Letters$as_cr_digits
16
17 # Sed expression to map a string onto a valid variable name.
18 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
19
20 # Sed expression to map a string onto a valid CPP name.
21 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
22
23 # Be Bourne compatible
24 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
25   emulate sh
26   NULLCMD=:
27 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
28   set -o posix
29 fi
30
31 # Name of the executable.
32 as_me=`echo "$0" |sed 's,.*[\\/],,'`
33
34 if expr a : '\(a\)' >/dev/null 2>&1; then
35   as_expr=expr
36 else
37   as_expr=false
38 fi
39
40 rm -f conf$$ conf$$.exe conf$$.file
41 echo >conf$$.file
42 if ln -s conf$$.file conf$$ 2>/dev/null; then
43   # We could just check for DJGPP; but this test a) works b) is more generic
44   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
45   if test -f conf$$.exe; then
46     # Don't use ln at all; we don't have any links
47     as_ln_s='cp -p'
48   else
49     as_ln_s='ln -s'
50   fi
51 elif ln conf$$.file conf$$ 2>/dev/null; then
52   as_ln_s=ln
53 else
54   as_ln_s='cp -p'
55 fi
56 rm -f conf$$ conf$$.exe conf$$.file
57
58 as_executable_p="test -f"
59
60 # Support unset when possible.
61 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
62   as_unset=unset
63 else
64   as_unset=false
65 fi
66
67 # NLS nuisances.
68 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
69 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
70 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
71 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
72 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
73 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
74 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
75 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
76
77 # IFS
78 # We need space, tab and new line, in precisely that order.
79 as_nl='
80 '
81 IFS="   $as_nl"
82
83 # CDPATH.
84 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
85
86 # Name of the host.
87 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
88 # so uname gets run too.
89 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
90
91 exec 6>&1
92
93 #
94 # Initializations.
95 #
96 ac_default_prefix=/usr/local
97 cross_compiling=no
98 subdirs=
99 MFLAGS= MAKEFLAGS=
100 SHELL=${CONFIG_SHELL-/bin/sh}
101
102 # Maximum number of lines to put in a shell here document.
103 # This variable seems obsolete.  It should probably be removed, and
104 # only ac_max_sed_lines should be used.
105 : ${ac_max_here_lines=38}
106
107 ac_unique_file="include/includes.h"
108 ac_default_prefix=/usr/local/samba
109 # Factoring default headers for most tests.
110 ac_includes_default="\
111 #include <stdio.h>
112 #if HAVE_SYS_TYPES_H
113 # include <sys/types.h>
114 #endif
115 #if HAVE_SYS_STAT_H
116 # include <sys/stat.h>
117 #endif
118 #if STDC_HEADERS
119 # include <stdlib.h>
120 # include <stddef.h>
121 #else
122 # if HAVE_STDLIB_H
123 #  include <stdlib.h>
124 # endif
125 #endif
126 #if HAVE_STRING_H
127 # if !STDC_HEADERS && HAVE_MEMORY_H
128 #  include <memory.h>
129 # endif
130 # include <string.h>
131 #endif
132 #if HAVE_STRINGS_H
133 # include <strings.h>
134 #endif
135 #if HAVE_INTTYPES_H
136 # include <inttypes.h>
137 #else
138 # if HAVE_STDINT_H
139 #  include <stdint.h>
140 # endif
141 #endif
142 #if HAVE_UNISTD_H
143 # include <unistd.h>
144 #endif"
145
146 # Initialize some variables set by options.
147 ac_init_help=
148 ac_init_version=false
149 # The variables have the same names as the options, with
150 # dashes changed to underlines.
151 cache_file=/dev/null
152 exec_prefix=NONE
153 no_create=
154 no_recursion=
155 prefix=NONE
156 program_prefix=NONE
157 program_suffix=NONE
158 program_transform_name=s,x,x,
159 silent=
160 site=
161 srcdir=
162 verbose=
163 x_includes=NONE
164 x_libraries=NONE
165
166 # Installation directory options.
167 # These are left unexpanded so users can "make install exec_prefix=/foo"
168 # and all the variables that are supposed to be based on exec_prefix
169 # by default will actually change.
170 # Use braces instead of parens because sh, perl, etc. also accept them.
171 bindir='${exec_prefix}/bin'
172 sbindir='${exec_prefix}/sbin'
173 libexecdir='${exec_prefix}/libexec'
174 datadir='${prefix}/share'
175 sysconfdir='${prefix}/etc'
176 sharedstatedir='${prefix}/com'
177 localstatedir='${prefix}/var'
178 libdir='${exec_prefix}/lib'
179 includedir='${prefix}/include'
180 oldincludedir='/usr/include'
181 infodir='${prefix}/info'
182 mandir='${prefix}/man'
183
184 # Identity of this package.
185 PACKAGE_NAME=
186 PACKAGE_TARNAME=
187 PACKAGE_VERSION=
188 PACKAGE_STRING=
189 PACKAGE_BUGREPORT=
190
191 ac_prev=
192 for ac_option
193 do
194   # If the previous option needs an argument, assign it.
195   if test -n "$ac_prev"; then
196     eval "$ac_prev=\$ac_option"
197     ac_prev=
198     continue
199   fi
200
201   ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
202
203   # Accept the important Cygnus configure options, so we can diagnose typos.
204
205   case $ac_option in
206
207   -bindir | --bindir | --bindi | --bind | --bin | --bi)
208     ac_prev=bindir ;;
209   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
210     bindir=$ac_optarg ;;
211
212   -build | --build | --buil | --bui | --bu)
213     ac_prev=build_alias ;;
214   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
215     build_alias=$ac_optarg ;;
216
217   -cache-file | --cache-file | --cache-fil | --cache-fi \
218   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
219     ac_prev=cache_file ;;
220   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
221   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
222     cache_file=$ac_optarg ;;
223
224   --config-cache | -C)
225     cache_file=config.cache ;;
226
227   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
228     ac_prev=datadir ;;
229   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
230   | --da=*)
231     datadir=$ac_optarg ;;
232
233   -disable-* | --disable-*)
234     ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
235     # Reject names that are not valid shell variable names.
236     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
237       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
238    { (exit 1); exit 1; }; }
239     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
240     eval "enable_$ac_feature=no" ;;
241
242   -enable-* | --enable-*)
243     ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
244     # Reject names that are not valid shell variable names.
245     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
246       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
247    { (exit 1); exit 1; }; }
248     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
249     case $ac_option in
250       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
251       *) ac_optarg=yes ;;
252     esac
253     eval "enable_$ac_feature='$ac_optarg'" ;;
254
255   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
256   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
257   | --exec | --exe | --ex)
258     ac_prev=exec_prefix ;;
259   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
260   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
261   | --exec=* | --exe=* | --ex=*)
262     exec_prefix=$ac_optarg ;;
263
264   -gas | --gas | --ga | --g)
265     # Obsolete; use --with-gas.
266     with_gas=yes ;;
267
268   -help | --help | --hel | --he | -h)
269     ac_init_help=long ;;
270   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
271     ac_init_help=recursive ;;
272   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
273     ac_init_help=short ;;
274
275   -host | --host | --hos | --ho)
276     ac_prev=host_alias ;;
277   -host=* | --host=* | --hos=* | --ho=*)
278     host_alias=$ac_optarg ;;
279
280   -includedir | --includedir | --includedi | --included | --include \
281   | --includ | --inclu | --incl | --inc)
282     ac_prev=includedir ;;
283   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
284   | --includ=* | --inclu=* | --incl=* | --inc=*)
285     includedir=$ac_optarg ;;
286
287   -infodir | --infodir | --infodi | --infod | --info | --inf)
288     ac_prev=infodir ;;
289   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
290     infodir=$ac_optarg ;;
291
292   -libdir | --libdir | --libdi | --libd)
293     ac_prev=libdir ;;
294   -libdir=* | --libdir=* | --libdi=* | --libd=*)
295     libdir=$ac_optarg ;;
296
297   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
298   | --libexe | --libex | --libe)
299     ac_prev=libexecdir ;;
300   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
301   | --libexe=* | --libex=* | --libe=*)
302     libexecdir=$ac_optarg ;;
303
304   -localstatedir | --localstatedir | --localstatedi | --localstated \
305   | --localstate | --localstat | --localsta | --localst \
306   | --locals | --local | --loca | --loc | --lo)
307     ac_prev=localstatedir ;;
308   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
309   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
310   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
311     localstatedir=$ac_optarg ;;
312
313   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
314     ac_prev=mandir ;;
315   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
316     mandir=$ac_optarg ;;
317
318   -nfp | --nfp | --nf)
319     # Obsolete; use --without-fp.
320     with_fp=no ;;
321
322   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
323   | --no-cr | --no-c)
324     no_create=yes ;;
325
326   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
327   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
328     no_recursion=yes ;;
329
330   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
331   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
332   | --oldin | --oldi | --old | --ol | --o)
333     ac_prev=oldincludedir ;;
334   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
335   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
336   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
337     oldincludedir=$ac_optarg ;;
338
339   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
340     ac_prev=prefix ;;
341   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
342     prefix=$ac_optarg ;;
343
344   -program-prefix | --program-prefix | --program-prefi | --program-pref \
345   | --program-pre | --program-pr | --program-p)
346     ac_prev=program_prefix ;;
347   -program-prefix=* | --program-prefix=* | --program-prefi=* \
348   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
349     program_prefix=$ac_optarg ;;
350
351   -program-suffix | --program-suffix | --program-suffi | --program-suff \
352   | --program-suf | --program-su | --program-s)
353     ac_prev=program_suffix ;;
354   -program-suffix=* | --program-suffix=* | --program-suffi=* \
355   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
356     program_suffix=$ac_optarg ;;
357
358   -program-transform-name | --program-transform-name \
359   | --program-transform-nam | --program-transform-na \
360   | --program-transform-n | --program-transform- \
361   | --program-transform | --program-transfor \
362   | --program-transfo | --program-transf \
363   | --program-trans | --program-tran \
364   | --progr-tra | --program-tr | --program-t)
365     ac_prev=program_transform_name ;;
366   -program-transform-name=* | --program-transform-name=* \
367   | --program-transform-nam=* | --program-transform-na=* \
368   | --program-transform-n=* | --program-transform-=* \
369   | --program-transform=* | --program-transfor=* \
370   | --program-transfo=* | --program-transf=* \
371   | --program-trans=* | --program-tran=* \
372   | --progr-tra=* | --program-tr=* | --program-t=*)
373     program_transform_name=$ac_optarg ;;
374
375   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
376   | -silent | --silent | --silen | --sile | --sil)
377     silent=yes ;;
378
379   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
380     ac_prev=sbindir ;;
381   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
382   | --sbi=* | --sb=*)
383     sbindir=$ac_optarg ;;
384
385   -sharedstatedir | --sharedstatedir | --sharedstatedi \
386   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
387   | --sharedst | --shareds | --shared | --share | --shar \
388   | --sha | --sh)
389     ac_prev=sharedstatedir ;;
390   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
391   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
392   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
393   | --sha=* | --sh=*)
394     sharedstatedir=$ac_optarg ;;
395
396   -site | --site | --sit)
397     ac_prev=site ;;
398   -site=* | --site=* | --sit=*)
399     site=$ac_optarg ;;
400
401   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
402     ac_prev=srcdir ;;
403   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
404     srcdir=$ac_optarg ;;
405
406   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
407   | --syscon | --sysco | --sysc | --sys | --sy)
408     ac_prev=sysconfdir ;;
409   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
410   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
411     sysconfdir=$ac_optarg ;;
412
413   -target | --target | --targe | --targ | --tar | --ta | --t)
414     ac_prev=target_alias ;;
415   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
416     target_alias=$ac_optarg ;;
417
418   -v | -verbose | --verbose | --verbos | --verbo | --verb)
419     verbose=yes ;;
420
421   -version | --version | --versio | --versi | --vers | -V)
422     ac_init_version=: ;;
423
424   -with-* | --with-*)
425     ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
426     # Reject names that are not valid shell variable names.
427     expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
428       { echo "$as_me: error: invalid package name: $ac_package" >&2
429    { (exit 1); exit 1; }; }
430     ac_package=`echo $ac_package| sed 's/-/_/g'`
431     case $ac_option in
432       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
433       *) ac_optarg=yes ;;
434     esac
435     eval "with_$ac_package='$ac_optarg'" ;;
436
437   -without-* | --without-*)
438     ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
439     # Reject names that are not valid shell variable names.
440     expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
441       { echo "$as_me: error: invalid package name: $ac_package" >&2
442    { (exit 1); exit 1; }; }
443     ac_package=`echo $ac_package | sed 's/-/_/g'`
444     eval "with_$ac_package=no" ;;
445
446   --x)
447     # Obsolete; use --with-x.
448     with_x=yes ;;
449
450   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
451   | --x-incl | --x-inc | --x-in | --x-i)
452     ac_prev=x_includes ;;
453   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
454   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
455     x_includes=$ac_optarg ;;
456
457   -x-libraries | --x-libraries | --x-librarie | --x-librari \
458   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
459     ac_prev=x_libraries ;;
460   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
461   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
462     x_libraries=$ac_optarg ;;
463
464   -*) { echo "$as_me: error: unrecognized option: $ac_option
465 Try \`$0 --help' for more information." >&2
466    { (exit 1); exit 1; }; }
467     ;;
468
469   *=*)
470     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
471     # Reject names that are not valid shell variable names.
472     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
473       { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
474    { (exit 1); exit 1; }; }
475     ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
476     eval "$ac_envvar='$ac_optarg'"
477     export $ac_envvar ;;
478
479   *)
480     # FIXME: should be removed in autoconf 3.0.
481     echo "$as_me: WARNING: you should use --build, --host, --target" >&2
482     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
483       echo "$as_me: WARNING: invalid host type: $ac_option" >&2
484     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
485     ;;
486
487   esac
488 done
489
490 if test -n "$ac_prev"; then
491   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
492   { echo "$as_me: error: missing argument to $ac_option" >&2
493    { (exit 1); exit 1; }; }
494 fi
495
496 # Be sure to have absolute paths.
497 for ac_var in exec_prefix prefix
498 do
499   eval ac_val=$`echo $ac_var`
500   case $ac_val in
501     [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
502     *)  { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
503    { (exit 1); exit 1; }; };;
504   esac
505 done
506
507 # Be sure to have absolute paths.
508 for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
509               localstatedir libdir includedir oldincludedir infodir mandir
510 do
511   eval ac_val=$`echo $ac_var`
512   case $ac_val in
513     [\\/$]* | ?:[\\/]* ) ;;
514     *)  { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
515    { (exit 1); exit 1; }; };;
516   esac
517 done
518
519 # There might be people who depend on the old broken behavior: `$host'
520 # used to hold the argument of --host etc.
521 build=$build_alias
522 host=$host_alias
523 target=$target_alias
524
525 # FIXME: should be removed in autoconf 3.0.
526 if test "x$host_alias" != x; then
527   if test "x$build_alias" = x; then
528     cross_compiling=maybe
529     echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
530     If a cross compiler is detected then cross compile mode will be used." >&2
531   elif test "x$build_alias" != "x$host_alias"; then
532     cross_compiling=yes
533   fi
534 fi
535
536 ac_tool_prefix=
537 test -n "$host_alias" && ac_tool_prefix=$host_alias-
538
539 test "$silent" = yes && exec 6>/dev/null
540
541 # Find the source files, if location was not specified.
542 if test -z "$srcdir"; then
543   ac_srcdir_defaulted=yes
544   # Try the directory containing this script, then its parent.
545   ac_prog=$0
546   ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
547   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
548   srcdir=$ac_confdir
549   if test ! -r $srcdir/$ac_unique_file; then
550     srcdir=..
551   fi
552 else
553   ac_srcdir_defaulted=no
554 fi
555 if test ! -r $srcdir/$ac_unique_file; then
556   if test "$ac_srcdir_defaulted" = yes; then
557     { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
558    { (exit 1); exit 1; }; }
559   else
560     { echo "$as_me: error: cannot find sources in $srcdir" >&2
561    { (exit 1); exit 1; }; }
562   fi
563 fi
564 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
565 ac_env_build_alias_set=${build_alias+set}
566 ac_env_build_alias_value=$build_alias
567 ac_cv_env_build_alias_set=${build_alias+set}
568 ac_cv_env_build_alias_value=$build_alias
569 ac_env_host_alias_set=${host_alias+set}
570 ac_env_host_alias_value=$host_alias
571 ac_cv_env_host_alias_set=${host_alias+set}
572 ac_cv_env_host_alias_value=$host_alias
573 ac_env_target_alias_set=${target_alias+set}
574 ac_env_target_alias_value=$target_alias
575 ac_cv_env_target_alias_set=${target_alias+set}
576 ac_cv_env_target_alias_value=$target_alias
577 ac_env_CC_set=${CC+set}
578 ac_env_CC_value=$CC
579 ac_cv_env_CC_set=${CC+set}
580 ac_cv_env_CC_value=$CC
581 ac_env_CFLAGS_set=${CFLAGS+set}
582 ac_env_CFLAGS_value=$CFLAGS
583 ac_cv_env_CFLAGS_set=${CFLAGS+set}
584 ac_cv_env_CFLAGS_value=$CFLAGS
585 ac_env_LDFLAGS_set=${LDFLAGS+set}
586 ac_env_LDFLAGS_value=$LDFLAGS
587 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
588 ac_cv_env_LDFLAGS_value=$LDFLAGS
589 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
590 ac_env_CPPFLAGS_value=$CPPFLAGS
591 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
592 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
593 ac_env_CPP_set=${CPP+set}
594 ac_env_CPP_value=$CPP
595 ac_cv_env_CPP_set=${CPP+set}
596 ac_cv_env_CPP_value=$CPP
597
598 #
599 # Report the --help message.
600 #
601 if test "$ac_init_help" = "long"; then
602   # Omit some internal or obsolete options to make the list less imposing.
603   # This message is too long to be a string in the A/UX 3.1 sh.
604   cat <<EOF
605 \`configure' configures this package to adapt to many kinds of systems.
606
607 Usage: $0 [OPTION]... [VAR=VALUE]...
608
609 To assign environment variables (e.g., CC, CFLAGS...), specify them as
610 VAR=VALUE.  See below for descriptions of some of the useful variables.
611
612 Defaults for the options are specified in brackets.
613
614 Configuration:
615   -h, --help              display this help and exit
616       --help=short        display options specific to this package
617       --help=recursive    display the short help of all the included packages
618   -V, --version           display version information and exit
619   -q, --quiet, --silent   do not print \`checking...' messages
620       --cache-file=FILE   cache test results in FILE [disabled]
621   -C, --config-cache      alias for \`--cache-file=config.cache'
622   -n, --no-create         do not create output files
623       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
624
625 EOF
626
627   cat <<EOF
628 Installation directories:
629   --prefix=PREFIX         install architecture-independent files in PREFIX
630                           [$ac_default_prefix]
631   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
632                           [PREFIX]
633
634 By default, \`make install' will install all the files in
635 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
636 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
637 for instance \`--prefix=\$HOME'.
638
639 For better control, use the options below.
640
641 Fine tuning of the installation directories:
642   --bindir=DIR           user executables [EPREFIX/bin]
643   --sbindir=DIR          system admin executables [EPREFIX/sbin]
644   --libexecdir=DIR       program executables [EPREFIX/libexec]
645   --datadir=DIR          read-only architecture-independent data [PREFIX/share]
646   --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
647   --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
648   --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
649   --libdir=DIR           object code libraries [EPREFIX/lib]
650   --includedir=DIR       C header files [PREFIX/include]
651   --oldincludedir=DIR    C header files for non-gcc [/usr/include]
652   --infodir=DIR          info documentation [PREFIX/info]
653   --mandir=DIR           man documentation [PREFIX/man]
654 EOF
655
656   cat <<\EOF
657
658 System types:
659   --build=BUILD     configure for building on BUILD [guessed]
660   --host=HOST       build programs to run on HOST [BUILD]
661   --target=TARGET   configure for building compilers for TARGET [HOST]
662 EOF
663 fi
664
665 if test -n "$ac_init_help"; then
666
667   cat <<\EOF
668
669 Optional Features:
670   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
671   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
672   --enable-debug          turn on debugging default=no
673   --enable-developer      turn on developer warnings and debugging default=no
674
675 Optional Packages:
676   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
677   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
678   --with-readline=DIR   Look for readline include/libs in DIR (default=auto)
679   --with-libiconv=BASEDIR Use libiconv in BASEDIR/lib and BASEDIR/include (default=auto)
680   --with-smbwrapper       Include SMB wrapper support (default=no)
681   --with-afs              Include AFS clear-text auth support (default=no)
682   --with-dce-dfs          Include DCE/DFS clear-text auth support (default=no)
683   --with-krb5=base-dir    Locate Kerberos 5 support (default=/usr)
684   --with-automount        Include AUTOMOUNT support (default=no)
685   --with-smbmount         Include SMBMOUNT (Linux only) support (default=no)
686   --with-pam              Include PAM support (default=no)
687   --with-pam_smbpass      Build a PAM module to allow other applications to use our smbpasswd file (default=no)
688   --with-tdbsam           Include experimental TDB SAM support (default=no)
689   --with-ldapsam          Include experimental LDAP SAM support (default=no)
690   --with-nisplussam       Include NISPLUS SAM support (default=no)
691   --with-nisplus-home     Include NISPLUS_HOME support (default=no)
692   --with-ssl              Include SSL support (default=no)
693   --with-sslinc=DIR          Where the SSL includes are (defaults to /usr/local/ssl/include)
694   --with-ssllib=DIR          Where the SSL libraries are (defaults to /usr/local/ssl/lib)
695   --with-syslog           Include experimental SYSLOG support (default=no)
696   --with-profiling-data   Include gathering source code profile information (default=no)
697   --with-quotas           Include experimental disk-quota support (default=no)
698   --with-utmp             Include experimental utmp accounting (default=no)
699   --with-privatedir=DIR   Where to put smbpasswd ($ac_default_prefix/private)
700   --with-lockdir=DIR      Where to put lock files ($ac_default_prefix/var/locks)
701   --with-swatdir=DIR      Where to put SWAT files ($ac_default_prefix/swat)
702   --with-manpages-langs={en,ja,pl}  Choose man pages' language(s). (en)
703   --with-spinlocks        Use spin locks instead of fcntl locks (default=no)
704   --with-acl-support      Include ACL support (default=no)
705   --with-winbind          Build winbind (default, if supported by OS)
706   --with-included-popt    use bundled popt library, not from system
707
708 Some influential environment variables:
709   CC          C compiler command
710   CFLAGS      C compiler flags
711   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
712               nonstandard directory <lib dir>
713   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
714               headers in a nonstandard directory <include dir>
715   CPP         C preprocessor
716
717 Use these variables to override the choices made by `configure' or to help
718 it to find libraries and programs with nonstandard names/locations.
719
720 EOF
721 fi
722
723 if test "$ac_init_help" = "recursive"; then
724   # If there are subdirs, report their specific --help.
725   ac_popdir=`pwd`
726   for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
727     cd $ac_subdir
728     # A "../" for each directory in /$ac_subdir.
729     ac_dots=`echo $ac_subdir |
730              sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
731
732     case $srcdir in
733     .) # No --srcdir option.  We are building in place.
734       ac_sub_srcdir=$srcdir ;;
735     [\\/]* | ?:[\\/]* ) # Absolute path.
736       ac_sub_srcdir=$srcdir/$ac_subdir ;;
737     *) # Relative path.
738       ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
739     esac
740
741     # Check for guested configure; otherwise get Cygnus style configure.
742     if test -f $ac_sub_srcdir/configure.gnu; then
743       echo
744       $SHELL $ac_sub_srcdir/configure.gnu  --help=recursive
745     elif test -f $ac_sub_srcdir/configure; then
746       echo
747       $SHELL $ac_sub_srcdir/configure  --help=recursive
748     elif test -f $ac_sub_srcdir/configure.ac ||
749            test -f $ac_sub_srcdir/configure.in; then
750       echo
751       $ac_configure --help
752     else
753       echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
754     fi
755     cd $ac_popdir
756   done
757 fi
758
759 test -n "$ac_init_help" && exit 0
760 if $ac_init_version; then
761   cat <<\EOF
762
763 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
764 Free Software Foundation, Inc.
765 This configure script is free software; the Free Software Foundation
766 gives unlimited permission to copy, distribute and modify it.
767 EOF
768   exit 0
769 fi
770 exec 5>config.log
771 cat >&5 <<EOF
772 This file contains any messages produced by compilers while
773 running configure, to aid debugging if configure makes a mistake.
774
775 It was created by $as_me, which was
776 generated by GNU Autoconf 2.52.  Invocation command line was
777
778   $ $0 $@
779
780 EOF
781 {
782 cat <<_ASUNAME
783 ## ---------- ##
784 ## Platform.  ##
785 ## ---------- ##
786
787 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
788 uname -m = `(uname -m) 2>/dev/null || echo unknown`
789 uname -r = `(uname -r) 2>/dev/null || echo unknown`
790 uname -s = `(uname -s) 2>/dev/null || echo unknown`
791 uname -v = `(uname -v) 2>/dev/null || echo unknown`
792
793 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
794 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
795
796 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
797 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
798 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
799 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
800 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
801 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
802 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
803
804 PATH = $PATH
805
806 _ASUNAME
807 } >&5
808
809 cat >&5 <<EOF
810 ## ------------ ##
811 ## Core tests.  ##
812 ## ------------ ##
813
814 EOF
815
816 # Keep a trace of the command line.
817 # Strip out --no-create and --no-recursion so they do not pile up.
818 # Also quote any args containing shell meta-characters.
819 ac_configure_args=
820 ac_sep=
821 for ac_arg
822 do
823   case $ac_arg in
824   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
825   | --no-cr | --no-c) ;;
826   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
827   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
828   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
829     ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
830     ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
831     ac_sep=" " ;;
832   *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
833      ac_sep=" " ;;
834   esac
835   # Get rid of the leading space.
836 done
837
838 # When interrupted or exit'd, cleanup temporary files, and complete
839 # config.log.  We remove comments because anyway the quotes in there
840 # would cause problems or look ugly.
841 trap 'exit_status=$?
842   # Save into config.log some information that might help in debugging.
843   echo >&5
844   echo "## ----------------- ##" >&5
845   echo "## Cache variables.  ##" >&5
846   echo "## ----------------- ##" >&5
847   echo >&5
848   # The following way of writing the cache mishandles newlines in values,
849 {
850   (set) 2>&1 |
851     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
852     *ac_space=\ *)
853       sed -n \
854         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
855           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
856       ;;
857     *)
858       sed -n \
859         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
860       ;;
861     esac;
862 } >&5
863   sed "/^$/d" confdefs.h >conftest.log
864   if test -s conftest.log; then
865     echo >&5
866     echo "## ------------ ##" >&5
867     echo "## confdefs.h.  ##" >&5
868     echo "## ------------ ##" >&5
869     echo >&5
870     cat conftest.log >&5
871   fi
872   (echo; echo) >&5
873   test "$ac_signal" != 0 &&
874     echo "$as_me: caught signal $ac_signal" >&5
875   echo "$as_me: exit $exit_status" >&5
876   rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
877     exit $exit_status
878      ' 0
879 for ac_signal in 1 2 13 15; do
880   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
881 done
882 ac_signal=0
883
884 # confdefs.h avoids OS command line length limits that DEFS can exceed.
885 rm -rf conftest* confdefs.h
886 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
887 echo >confdefs.h
888
889 # Let the site file select an alternate cache file if it wants to.
890 # Prefer explicitly selected file to automatically selected ones.
891 if test -z "$CONFIG_SITE"; then
892   if test "x$prefix" != xNONE; then
893     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
894   else
895     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
896   fi
897 fi
898 for ac_site_file in $CONFIG_SITE; do
899   if test -r "$ac_site_file"; then
900     { echo "$as_me:900: loading site script $ac_site_file" >&5
901 echo "$as_me: loading site script $ac_site_file" >&6;}
902     cat "$ac_site_file" >&5
903     . "$ac_site_file"
904   fi
905 done
906
907 if test -r "$cache_file"; then
908   # Some versions of bash will fail to source /dev/null (special
909   # files actually), so we avoid doing that.
910   if test -f "$cache_file"; then
911     { echo "$as_me:911: loading cache $cache_file" >&5
912 echo "$as_me: loading cache $cache_file" >&6;}
913     case $cache_file in
914       [\\/]* | ?:[\\/]* ) . $cache_file;;
915       *)                      . ./$cache_file;;
916     esac
917   fi
918 else
919   { echo "$as_me:919: creating cache $cache_file" >&5
920 echo "$as_me: creating cache $cache_file" >&6;}
921   >$cache_file
922 fi
923
924 # Check that the precious variables saved in the cache have kept the same
925 # value.
926 ac_cache_corrupted=false
927 for ac_var in `(set) 2>&1 |
928                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
929   eval ac_old_set=\$ac_cv_env_${ac_var}_set
930   eval ac_new_set=\$ac_env_${ac_var}_set
931   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
932   eval ac_new_val="\$ac_env_${ac_var}_value"
933   case $ac_old_set,$ac_new_set in
934     set,)
935       { echo "$as_me:935: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
936 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
937       ac_cache_corrupted=: ;;
938     ,set)
939       { echo "$as_me:939: error: \`$ac_var' was not set in the previous run" >&5
940 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
941       ac_cache_corrupted=: ;;
942     ,);;
943     *)
944       if test "x$ac_old_val" != "x$ac_new_val"; then
945         { echo "$as_me:945: error: \`$ac_var' has changed since the previous run:" >&5
946 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
947         { echo "$as_me:947:   former value:  $ac_old_val" >&5
948 echo "$as_me:   former value:  $ac_old_val" >&2;}
949         { echo "$as_me:949:   current value: $ac_new_val" >&5
950 echo "$as_me:   current value: $ac_new_val" >&2;}
951         ac_cache_corrupted=:
952       fi;;
953   esac
954   # Pass precious variables to config.status.  It doesn't matter if
955   # we pass some twice (in addition to the command line arguments).
956   if test "$ac_new_set" = set; then
957     case $ac_new_val in
958     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
959       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
960       ac_configure_args="$ac_configure_args '$ac_arg'"
961       ;;
962     *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
963        ;;
964     esac
965   fi
966 done
967 if $ac_cache_corrupted; then
968   { echo "$as_me:968: error: changes in the environment can compromise the build" >&5
969 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
970   { { echo "$as_me:970: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
971 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
972    { (exit 1); exit 1; }; }
973 fi
974
975 ac_ext=c
976 ac_cpp='$CPP $CPPFLAGS'
977 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
978 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
979 ac_compiler_gnu=$ac_cv_c_compiler_gnu
980
981 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
982   *c*,-n*) ECHO_N= ECHO_C='
983 ' ECHO_T='      ' ;;
984   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
985   *)      ECHO_N= ECHO_C='\c' ECHO_T= ;;
986 esac
987 echo "#! $SHELL" >conftest.sh
988 echo  "exit 0"   >>conftest.sh
989 chmod +x conftest.sh
990 if { (echo "$as_me:990: PATH=\".;.\"; conftest.sh") >&5
991   (PATH=".;."; conftest.sh) 2>&5
992   ac_status=$?
993   echo "$as_me:993: \$? = $ac_status" >&5
994   (exit $ac_status); }; then
995   ac_path_separator=';'
996 else
997   ac_path_separator=:
998 fi
999 PATH_SEPARATOR="$ac_path_separator"
1000 rm -f conftest.sh
1001
1002 ac_config_headers="$ac_config_headers include/config.h"
1003
1004 # we want to be compatibe with older versions of Samba
1005
1006 # compile with optimisation and without debugging by default
1007 CFLAGS="-O ${CFLAGS}"
1008
1009 # Check whether --enable-debug or --disable-debug was given.
1010 if test "${enable_debug+set}" = set; then
1011   enableval="$enable_debug"
1012   if eval "test x$enable_debug = xyes"; then
1013         CFLAGS="${CFLAGS} -g"
1014     fi
1015 fi;
1016
1017 # Check whether --enable-developer or --disable-developer was given.
1018 if test "${enable_developer+set}" = set; then
1019   enableval="$enable_developer"
1020   if eval "test x$enable_developer = xyes"; then
1021         CFLAGS="${CFLAGS} -g -Wall -Wshadow -Wstrict-prototypes -Wpointer-arith -Wcast-qual -Wcast-align -DDEBUG_PASSWORD -DDEVELOPER"
1022     fi
1023 fi;
1024
1025 ac_ext=c
1026 ac_cpp='$CPP $CPPFLAGS'
1027 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1028 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1029 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1030 if test -n "$ac_tool_prefix"; then
1031   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1032 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1033 echo "$as_me:1033: checking for $ac_word" >&5
1034 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1035 if test "${ac_cv_prog_CC+set}" = set; then
1036   echo $ECHO_N "(cached) $ECHO_C" >&6
1037 else
1038   if test -n "$CC"; then
1039   ac_cv_prog_CC="$CC" # Let the user override the test.
1040 else
1041   ac_save_IFS=$IFS; IFS=$ac_path_separator
1042 ac_dummy="$PATH"
1043 for ac_dir in $ac_dummy; do
1044   IFS=$ac_save_IFS
1045   test -z "$ac_dir" && ac_dir=.
1046   $as_executable_p "$ac_dir/$ac_word" || continue
1047 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1048 echo "$as_me:1048: found $ac_dir/$ac_word" >&5
1049 break
1050 done
1051
1052 fi
1053 fi
1054 CC=$ac_cv_prog_CC
1055 if test -n "$CC"; then
1056   echo "$as_me:1056: result: $CC" >&5
1057 echo "${ECHO_T}$CC" >&6
1058 else
1059   echo "$as_me:1059: result: no" >&5
1060 echo "${ECHO_T}no" >&6
1061 fi
1062
1063 fi
1064 if test -z "$ac_cv_prog_CC"; then
1065   ac_ct_CC=$CC
1066   # Extract the first word of "gcc", so it can be a program name with args.
1067 set dummy gcc; ac_word=$2
1068 echo "$as_me:1068: checking for $ac_word" >&5
1069 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1070 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1071   echo $ECHO_N "(cached) $ECHO_C" >&6
1072 else
1073   if test -n "$ac_ct_CC"; then
1074   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1075 else
1076   ac_save_IFS=$IFS; IFS=$ac_path_separator
1077 ac_dummy="$PATH"
1078 for ac_dir in $ac_dummy; do
1079   IFS=$ac_save_IFS
1080   test -z "$ac_dir" && ac_dir=.
1081   $as_executable_p "$ac_dir/$ac_word" || continue
1082 ac_cv_prog_ac_ct_CC="gcc"
1083 echo "$as_me:1083: found $ac_dir/$ac_word" >&5
1084 break
1085 done
1086
1087 fi
1088 fi
1089 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1090 if test -n "$ac_ct_CC"; then
1091   echo "$as_me:1091: result: $ac_ct_CC" >&5
1092 echo "${ECHO_T}$ac_ct_CC" >&6
1093 else
1094   echo "$as_me:1094: result: no" >&5
1095 echo "${ECHO_T}no" >&6
1096 fi
1097
1098   CC=$ac_ct_CC
1099 else
1100   CC="$ac_cv_prog_CC"
1101 fi
1102
1103 if test -z "$CC"; then
1104   if test -n "$ac_tool_prefix"; then
1105   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1106 set dummy ${ac_tool_prefix}cc; ac_word=$2
1107 echo "$as_me:1107: checking for $ac_word" >&5
1108 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1109 if test "${ac_cv_prog_CC+set}" = set; then
1110   echo $ECHO_N "(cached) $ECHO_C" >&6
1111 else
1112   if test -n "$CC"; then
1113   ac_cv_prog_CC="$CC" # Let the user override the test.
1114 else
1115   ac_save_IFS=$IFS; IFS=$ac_path_separator
1116 ac_dummy="$PATH"
1117 for ac_dir in $ac_dummy; do
1118   IFS=$ac_save_IFS
1119   test -z "$ac_dir" && ac_dir=.
1120   $as_executable_p "$ac_dir/$ac_word" || continue
1121 ac_cv_prog_CC="${ac_tool_prefix}cc"
1122 echo "$as_me:1122: found $ac_dir/$ac_word" >&5
1123 break
1124 done
1125
1126 fi
1127 fi
1128 CC=$ac_cv_prog_CC
1129 if test -n "$CC"; then
1130   echo "$as_me:1130: result: $CC" >&5
1131 echo "${ECHO_T}$CC" >&6
1132 else
1133   echo "$as_me:1133: result: no" >&5
1134 echo "${ECHO_T}no" >&6
1135 fi
1136
1137 fi
1138 if test -z "$ac_cv_prog_CC"; then
1139   ac_ct_CC=$CC
1140   # Extract the first word of "cc", so it can be a program name with args.
1141 set dummy cc; ac_word=$2
1142 echo "$as_me:1142: checking for $ac_word" >&5
1143 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1144 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1145   echo $ECHO_N "(cached) $ECHO_C" >&6
1146 else
1147   if test -n "$ac_ct_CC"; then
1148   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1149 else
1150   ac_save_IFS=$IFS; IFS=$ac_path_separator
1151 ac_dummy="$PATH"
1152 for ac_dir in $ac_dummy; do
1153   IFS=$ac_save_IFS
1154   test -z "$ac_dir" && ac_dir=.
1155   $as_executable_p "$ac_dir/$ac_word" || continue
1156 ac_cv_prog_ac_ct_CC="cc"
1157 echo "$as_me:1157: found $ac_dir/$ac_word" >&5
1158 break
1159 done
1160
1161 fi
1162 fi
1163 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1164 if test -n "$ac_ct_CC"; then
1165   echo "$as_me:1165: result: $ac_ct_CC" >&5
1166 echo "${ECHO_T}$ac_ct_CC" >&6
1167 else
1168   echo "$as_me:1168: result: no" >&5
1169 echo "${ECHO_T}no" >&6
1170 fi
1171
1172   CC=$ac_ct_CC
1173 else
1174   CC="$ac_cv_prog_CC"
1175 fi
1176
1177 fi
1178 if test -z "$CC"; then
1179   # Extract the first word of "cc", so it can be a program name with args.
1180 set dummy cc; ac_word=$2
1181 echo "$as_me:1181: checking for $ac_word" >&5
1182 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1183 if test "${ac_cv_prog_CC+set}" = set; then
1184   echo $ECHO_N "(cached) $ECHO_C" >&6
1185 else
1186   if test -n "$CC"; then
1187   ac_cv_prog_CC="$CC" # Let the user override the test.
1188 else
1189   ac_prog_rejected=no
1190   ac_save_IFS=$IFS; IFS=$ac_path_separator
1191 ac_dummy="$PATH"
1192 for ac_dir in $ac_dummy; do
1193   IFS=$ac_save_IFS
1194   test -z "$ac_dir" && ac_dir=.
1195   $as_executable_p "$ac_dir/$ac_word" || continue
1196 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1197   ac_prog_rejected=yes
1198   continue
1199 fi
1200 ac_cv_prog_CC="cc"
1201 echo "$as_me:1201: found $ac_dir/$ac_word" >&5
1202 break
1203 done
1204
1205 if test $ac_prog_rejected = yes; then
1206   # We found a bogon in the path, so make sure we never use it.
1207   set dummy $ac_cv_prog_CC
1208   shift
1209   if test $# != 0; then
1210     # We chose a different compiler from the bogus one.
1211     # However, it has the same basename, so the bogon will be chosen
1212     # first if we set CC to just the basename; use the full file name.
1213     shift
1214     set dummy "$ac_dir/$ac_word" ${1+"$@"}
1215     shift
1216     ac_cv_prog_CC="$@"
1217   fi
1218 fi
1219 fi
1220 fi
1221 CC=$ac_cv_prog_CC
1222 if test -n "$CC"; then
1223   echo "$as_me:1223: result: $CC" >&5
1224 echo "${ECHO_T}$CC" >&6
1225 else
1226   echo "$as_me:1226: result: no" >&5
1227 echo "${ECHO_T}no" >&6
1228 fi
1229
1230 fi
1231 if test -z "$CC"; then
1232   if test -n "$ac_tool_prefix"; then
1233   for ac_prog in cl
1234   do
1235     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1236 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1237 echo "$as_me:1237: checking for $ac_word" >&5
1238 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1239 if test "${ac_cv_prog_CC+set}" = set; then
1240   echo $ECHO_N "(cached) $ECHO_C" >&6
1241 else
1242   if test -n "$CC"; then
1243   ac_cv_prog_CC="$CC" # Let the user override the test.
1244 else
1245   ac_save_IFS=$IFS; IFS=$ac_path_separator
1246 ac_dummy="$PATH"
1247 for ac_dir in $ac_dummy; do
1248   IFS=$ac_save_IFS
1249   test -z "$ac_dir" && ac_dir=.
1250   $as_executable_p "$ac_dir/$ac_word" || continue
1251 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1252 echo "$as_me:1252: found $ac_dir/$ac_word" >&5
1253 break
1254 done
1255
1256 fi
1257 fi
1258 CC=$ac_cv_prog_CC
1259 if test -n "$CC"; then
1260   echo "$as_me:1260: result: $CC" >&5
1261 echo "${ECHO_T}$CC" >&6
1262 else
1263   echo "$as_me:1263: result: no" >&5
1264 echo "${ECHO_T}no" >&6
1265 fi
1266
1267     test -n "$CC" && break
1268   done
1269 fi
1270 if test -z "$CC"; then
1271   ac_ct_CC=$CC
1272   for ac_prog in cl
1273 do
1274   # Extract the first word of "$ac_prog", so it can be a program name with args.
1275 set dummy $ac_prog; ac_word=$2
1276 echo "$as_me:1276: checking for $ac_word" >&5
1277 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1278 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1279   echo $ECHO_N "(cached) $ECHO_C" >&6
1280 else
1281   if test -n "$ac_ct_CC"; then
1282   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1283 else
1284   ac_save_IFS=$IFS; IFS=$ac_path_separator
1285 ac_dummy="$PATH"
1286 for ac_dir in $ac_dummy; do
1287   IFS=$ac_save_IFS
1288   test -z "$ac_dir" && ac_dir=.
1289   $as_executable_p "$ac_dir/$ac_word" || continue
1290 ac_cv_prog_ac_ct_CC="$ac_prog"
1291 echo "$as_me:1291: found $ac_dir/$ac_word" >&5
1292 break
1293 done
1294
1295 fi
1296 fi
1297 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1298 if test -n "$ac_ct_CC"; then
1299   echo "$as_me:1299: result: $ac_ct_CC" >&5
1300 echo "${ECHO_T}$ac_ct_CC" >&6
1301 else
1302   echo "$as_me:1302: result: no" >&5
1303 echo "${ECHO_T}no" >&6
1304 fi
1305
1306   test -n "$ac_ct_CC" && break
1307 done
1308
1309   CC=$ac_ct_CC
1310 fi
1311
1312 fi
1313
1314 test -z "$CC" && { { echo "$as_me:1314: error: no acceptable cc found in \$PATH" >&5
1315 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1316    { (exit 1); exit 1; }; }
1317
1318 # Provide some information about the compiler.
1319 echo "$as_me:1319:" \
1320      "checking for C compiler version" >&5
1321 ac_compiler=`set X $ac_compile; echo $2`
1322 { (eval echo "$as_me:1322: \"$ac_compiler --version </dev/null >&5\"") >&5
1323   (eval $ac_compiler --version </dev/null >&5) 2>&5
1324   ac_status=$?
1325   echo "$as_me:1325: \$? = $ac_status" >&5
1326   (exit $ac_status); }
1327 { (eval echo "$as_me:1327: \"$ac_compiler -v </dev/null >&5\"") >&5
1328   (eval $ac_compiler -v </dev/null >&5) 2>&5
1329   ac_status=$?
1330   echo "$as_me:1330: \$? = $ac_status" >&5
1331   (exit $ac_status); }
1332 { (eval echo "$as_me:1332: \"$ac_compiler -V </dev/null >&5\"") >&5
1333   (eval $ac_compiler -V </dev/null >&5) 2>&5
1334   ac_status=$?
1335   echo "$as_me:1335: \$? = $ac_status" >&5
1336   (exit $ac_status); }
1337
1338 cat >conftest.$ac_ext <<_ACEOF
1339 #line 1339 "configure"
1340 #include "confdefs.h"
1341
1342 int
1343 main ()
1344 {
1345
1346   ;
1347   return 0;
1348 }
1349 _ACEOF
1350 ac_clean_files_save=$ac_clean_files
1351 ac_clean_files="$ac_clean_files a.out a.exe"
1352 # Try to create an executable without -o first, disregard a.out.
1353 # It will help us diagnose broken compilers, and finding out an intuition
1354 # of exeext.
1355 echo "$as_me:1355: checking for C compiler default output" >&5
1356 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1357 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1358 if { (eval echo "$as_me:1358: \"$ac_link_default\"") >&5
1359   (eval $ac_link_default) 2>&5
1360   ac_status=$?
1361   echo "$as_me:1361: \$? = $ac_status" >&5
1362   (exit $ac_status); }; then
1363   # Find the output, starting from the most likely.  This scheme is
1364 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1365 # resort.
1366 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1367                 ls a.out conftest 2>/dev/null;
1368                 ls a.* conftest.* 2>/dev/null`; do
1369   case $ac_file in
1370     *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
1371     a.out ) # We found the default executable, but exeext='' is most
1372             # certainly right.
1373             break;;
1374     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1375           # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1376           export ac_cv_exeext
1377           break;;
1378     * ) break;;
1379   esac
1380 done
1381 else
1382   echo "$as_me: failed program was:" >&5
1383 cat conftest.$ac_ext >&5
1384 { { echo "$as_me:1384: error: C compiler cannot create executables" >&5
1385 echo "$as_me: error: C compiler cannot create executables" >&2;}
1386    { (exit 77); exit 77; }; }
1387 fi
1388
1389 ac_exeext=$ac_cv_exeext
1390 echo "$as_me:1390: result: $ac_file" >&5
1391 echo "${ECHO_T}$ac_file" >&6
1392
1393 # Check the compiler produces executables we can run.  If not, either
1394 # the compiler is broken, or we cross compile.
1395 echo "$as_me:1395: checking whether the C compiler works" >&5
1396 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1397 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1398 # If not cross compiling, check that we can run a simple program.
1399 if test "$cross_compiling" != yes; then
1400   if { ac_try='./$ac_file'
1401   { (eval echo "$as_me:1401: \"$ac_try\"") >&5
1402   (eval $ac_try) 2>&5
1403   ac_status=$?
1404   echo "$as_me:1404: \$? = $ac_status" >&5
1405   (exit $ac_status); }; }; then
1406     cross_compiling=no
1407   else
1408     if test "$cross_compiling" = maybe; then
1409         cross_compiling=yes
1410     else
1411         { { echo "$as_me:1411: error: cannot run C compiled programs.
1412 If you meant to cross compile, use \`--host'." >&5
1413 echo "$as_me: error: cannot run C compiled programs.
1414 If you meant to cross compile, use \`--host'." >&2;}
1415    { (exit 1); exit 1; }; }
1416     fi
1417   fi
1418 fi
1419 echo "$as_me:1419: result: yes" >&5
1420 echo "${ECHO_T}yes" >&6
1421
1422 rm -f a.out a.exe conftest$ac_cv_exeext
1423 ac_clean_files=$ac_clean_files_save
1424 # Check the compiler produces executables we can run.  If not, either
1425 # the compiler is broken, or we cross compile.
1426 echo "$as_me:1426: checking whether we are cross compiling" >&5
1427 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1428 echo "$as_me:1428: result: $cross_compiling" >&5
1429 echo "${ECHO_T}$cross_compiling" >&6
1430
1431 echo "$as_me:1431: checking for executable suffix" >&5
1432 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1433 if { (eval echo "$as_me:1433: \"$ac_link\"") >&5
1434   (eval $ac_link) 2>&5
1435   ac_status=$?
1436   echo "$as_me:1436: \$? = $ac_status" >&5
1437   (exit $ac_status); }; then
1438   # If both `conftest.exe' and `conftest' are `present' (well, observable)
1439 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
1440 # work properly (i.e., refer to `conftest.exe'), while it won't with
1441 # `rm'.
1442 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1443   case $ac_file in
1444     *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
1445     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1446           export ac_cv_exeext
1447           break;;
1448     * ) break;;
1449   esac
1450 done
1451 else
1452   { { echo "$as_me:1452: error: cannot compute EXEEXT: cannot compile and link" >&5
1453 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1454    { (exit 1); exit 1; }; }
1455 fi
1456
1457 rm -f conftest$ac_cv_exeext
1458 echo "$as_me:1458: result: $ac_cv_exeext" >&5
1459 echo "${ECHO_T}$ac_cv_exeext" >&6
1460
1461 rm -f conftest.$ac_ext
1462 EXEEXT=$ac_cv_exeext
1463 ac_exeext=$EXEEXT
1464 echo "$as_me:1464: checking for object suffix" >&5
1465 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1466 if test "${ac_cv_objext+set}" = set; then
1467   echo $ECHO_N "(cached) $ECHO_C" >&6
1468 else
1469   cat >conftest.$ac_ext <<_ACEOF
1470 #line 1470 "configure"
1471 #include "confdefs.h"
1472
1473 int
1474 main ()
1475 {
1476
1477   ;
1478   return 0;
1479 }
1480 _ACEOF
1481 rm -f conftest.o conftest.obj
1482 if { (eval echo "$as_me:1482: \"$ac_compile\"") >&5
1483   (eval $ac_compile) 2>&5
1484   ac_status=$?
1485   echo "$as_me:1485: \$? = $ac_status" >&5
1486   (exit $ac_status); }; then
1487   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1488   case $ac_file in
1489     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb ) ;;
1490     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1491        break;;
1492   esac
1493 done
1494 else
1495   echo "$as_me: failed program was:" >&5
1496 cat conftest.$ac_ext >&5
1497 { { echo "$as_me:1497: error: cannot compute OBJEXT: cannot compile" >&5
1498 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1499    { (exit 1); exit 1; }; }
1500 fi
1501
1502 rm -f conftest.$ac_cv_objext conftest.$ac_ext
1503 fi
1504 echo "$as_me:1504: result: $ac_cv_objext" >&5
1505 echo "${ECHO_T}$ac_cv_objext" >&6
1506 OBJEXT=$ac_cv_objext
1507 ac_objext=$OBJEXT
1508 echo "$as_me:1508: checking whether we are using the GNU C compiler" >&5
1509 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1510 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1511   echo $ECHO_N "(cached) $ECHO_C" >&6
1512 else
1513   cat >conftest.$ac_ext <<_ACEOF
1514 #line 1514 "configure"
1515 #include "confdefs.h"
1516
1517 int
1518 main ()
1519 {
1520 #ifndef __GNUC__
1521        choke me
1522 #endif
1523
1524   ;
1525   return 0;
1526 }
1527 _ACEOF
1528 rm -f conftest.$ac_objext
1529 if { (eval echo "$as_me:1529: \"$ac_compile\"") >&5
1530   (eval $ac_compile) 2>&5
1531   ac_status=$?
1532   echo "$as_me:1532: \$? = $ac_status" >&5
1533   (exit $ac_status); } &&
1534          { ac_try='test -s conftest.$ac_objext'
1535   { (eval echo "$as_me:1535: \"$ac_try\"") >&5
1536   (eval $ac_try) 2>&5
1537   ac_status=$?
1538   echo "$as_me:1538: \$? = $ac_status" >&5
1539   (exit $ac_status); }; }; then
1540   ac_compiler_gnu=yes
1541 else
1542   echo "$as_me: failed program was:" >&5
1543 cat conftest.$ac_ext >&5
1544 ac_compiler_gnu=no
1545 fi
1546 rm -f conftest.$ac_objext conftest.$ac_ext
1547 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1548
1549 fi
1550 echo "$as_me:1550: result: $ac_cv_c_compiler_gnu" >&5
1551 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1552 GCC=`test $ac_compiler_gnu = yes && echo yes`
1553 ac_test_CFLAGS=${CFLAGS+set}
1554 ac_save_CFLAGS=$CFLAGS
1555 CFLAGS="-g"
1556 echo "$as_me:1556: checking whether $CC accepts -g" >&5
1557 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1558 if test "${ac_cv_prog_cc_g+set}" = set; then
1559   echo $ECHO_N "(cached) $ECHO_C" >&6
1560 else
1561   cat >conftest.$ac_ext <<_ACEOF
1562 #line 1562 "configure"
1563 #include "confdefs.h"
1564
1565 int
1566 main ()
1567 {
1568
1569   ;
1570   return 0;
1571 }
1572 _ACEOF
1573 rm -f conftest.$ac_objext
1574 if { (eval echo "$as_me:1574: \"$ac_compile\"") >&5
1575   (eval $ac_compile) 2>&5
1576   ac_status=$?
1577   echo "$as_me:1577: \$? = $ac_status" >&5
1578   (exit $ac_status); } &&
1579          { ac_try='test -s conftest.$ac_objext'
1580   { (eval echo "$as_me:1580: \"$ac_try\"") >&5
1581   (eval $ac_try) 2>&5
1582   ac_status=$?
1583   echo "$as_me:1583: \$? = $ac_status" >&5
1584   (exit $ac_status); }; }; then
1585   ac_cv_prog_cc_g=yes
1586 else
1587   echo "$as_me: failed program was:" >&5
1588 cat conftest.$ac_ext >&5
1589 ac_cv_prog_cc_g=no
1590 fi
1591 rm -f conftest.$ac_objext conftest.$ac_ext
1592 fi
1593 echo "$as_me:1593: result: $ac_cv_prog_cc_g" >&5
1594 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1595 if test "$ac_test_CFLAGS" = set; then
1596   CFLAGS=$ac_save_CFLAGS
1597 elif test $ac_cv_prog_cc_g = yes; then
1598   if test "$GCC" = yes; then
1599     CFLAGS="-g -O2"
1600   else
1601     CFLAGS="-g"
1602   fi
1603 else
1604   if test "$GCC" = yes; then
1605     CFLAGS="-O2"
1606   else
1607     CFLAGS=
1608   fi
1609 fi
1610 # Some people use a C++ compiler to compile C.  Since we use `exit',
1611 # in C++ we need to declare it.  In case someone uses the same compiler
1612 # for both compiling C and C++ we need to have the C++ compiler decide
1613 # the declaration of exit, since it's the most demanding environment.
1614 cat >conftest.$ac_ext <<_ACEOF
1615 #ifndef __cplusplus
1616   choke me
1617 #endif
1618 _ACEOF
1619 rm -f conftest.$ac_objext
1620 if { (eval echo "$as_me:1620: \"$ac_compile\"") >&5
1621   (eval $ac_compile) 2>&5
1622   ac_status=$?
1623   echo "$as_me:1623: \$? = $ac_status" >&5
1624   (exit $ac_status); } &&
1625          { ac_try='test -s conftest.$ac_objext'
1626   { (eval echo "$as_me:1626: \"$ac_try\"") >&5
1627   (eval $ac_try) 2>&5
1628   ac_status=$?
1629   echo "$as_me:1629: \$? = $ac_status" >&5
1630   (exit $ac_status); }; }; then
1631   for ac_declaration in \
1632    ''\
1633    '#include <stdlib.h>' \
1634    'extern "C" void std::exit (int) throw (); using std::exit;' \
1635    'extern "C" void std::exit (int); using std::exit;' \
1636    'extern "C" void exit (int) throw ();' \
1637    'extern "C" void exit (int);' \
1638    'void exit (int);'
1639 do
1640   cat >conftest.$ac_ext <<_ACEOF
1641 #line 1641 "configure"
1642 #include "confdefs.h"
1643 #include <stdlib.h>
1644 $ac_declaration
1645 int
1646 main ()
1647 {
1648 exit (42);
1649   ;
1650   return 0;
1651 }
1652 _ACEOF
1653 rm -f conftest.$ac_objext
1654 if { (eval echo "$as_me:1654: \"$ac_compile\"") >&5
1655   (eval $ac_compile) 2>&5
1656   ac_status=$?
1657   echo "$as_me:1657: \$? = $ac_status" >&5
1658   (exit $ac_status); } &&
1659          { ac_try='test -s conftest.$ac_objext'
1660   { (eval echo "$as_me:1660: \"$ac_try\"") >&5
1661   (eval $ac_try) 2>&5
1662   ac_status=$?
1663   echo "$as_me:1663: \$? = $ac_status" >&5
1664   (exit $ac_status); }; }; then
1665   :
1666 else
1667   echo "$as_me: failed program was:" >&5
1668 cat conftest.$ac_ext >&5
1669 continue
1670 fi
1671 rm -f conftest.$ac_objext conftest.$ac_ext
1672   cat >conftest.$ac_ext <<_ACEOF
1673 #line 1673 "configure"
1674 #include "confdefs.h"
1675 $ac_declaration
1676 int
1677 main ()
1678 {
1679 exit (42);
1680   ;
1681   return 0;
1682 }
1683 _ACEOF
1684 rm -f conftest.$ac_objext
1685 if { (eval echo "$as_me:1685: \"$ac_compile\"") >&5
1686   (eval $ac_compile) 2>&5
1687   ac_status=$?
1688   echo "$as_me:1688: \$? = $ac_status" >&5
1689   (exit $ac_status); } &&
1690          { ac_try='test -s conftest.$ac_objext'
1691   { (eval echo "$as_me:1691: \"$ac_try\"") >&5
1692   (eval $ac_try) 2>&5
1693   ac_status=$?
1694   echo "$as_me:1694: \$? = $ac_status" >&5
1695   (exit $ac_status); }; }; then
1696   break
1697 else
1698   echo "$as_me: failed program was:" >&5
1699 cat conftest.$ac_ext >&5
1700 fi
1701 rm -f conftest.$ac_objext conftest.$ac_ext
1702 done
1703 rm -f conftest*
1704 if test -n "$ac_declaration"; then
1705   echo '#ifdef __cplusplus' >>confdefs.h
1706   echo $ac_declaration      >>confdefs.h
1707   echo '#endif'             >>confdefs.h
1708 fi
1709
1710 else
1711   echo "$as_me: failed program was:" >&5
1712 cat conftest.$ac_ext >&5
1713 fi
1714 rm -f conftest.$ac_objext conftest.$ac_ext
1715 ac_ext=c
1716 ac_cpp='$CPP $CPPFLAGS'
1717 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1718 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1719 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1720
1721 ac_aux_dir=
1722 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1723   if test -f $ac_dir/install-sh; then
1724     ac_aux_dir=$ac_dir
1725     ac_install_sh="$ac_aux_dir/install-sh -c"
1726     break
1727   elif test -f $ac_dir/install.sh; then
1728     ac_aux_dir=$ac_dir
1729     ac_install_sh="$ac_aux_dir/install.sh -c"
1730     break
1731   elif test -f $ac_dir/shtool; then
1732     ac_aux_dir=$ac_dir
1733     ac_install_sh="$ac_aux_dir/shtool install -c"
1734     break
1735   fi
1736 done
1737 if test -z "$ac_aux_dir"; then
1738   { { echo "$as_me:1738: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1739 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1740    { (exit 1); exit 1; }; }
1741 fi
1742 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1743 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1744 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1745
1746 # Find a good install program.  We prefer a C program (faster),
1747 # so one script is as good as another.  But avoid the broken or
1748 # incompatible versions:
1749 # SysV /etc/install, /usr/sbin/install
1750 # SunOS /usr/etc/install
1751 # IRIX /sbin/install
1752 # AIX /bin/install
1753 # AmigaOS /C/install, which installs bootblocks on floppy discs
1754 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1755 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
1756 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1757 # ./install, which can be erroneously created by make from ./install.sh.
1758 echo "$as_me:1758: checking for a BSD compatible install" >&5
1759 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
1760 if test -z "$INSTALL"; then
1761 if test "${ac_cv_path_install+set}" = set; then
1762   echo $ECHO_N "(cached) $ECHO_C" >&6
1763 else
1764     ac_save_IFS=$IFS; IFS=$ac_path_separator
1765   for ac_dir in $PATH; do
1766     IFS=$ac_save_IFS
1767     # Account for people who put trailing slashes in PATH elements.
1768     case $ac_dir/ in
1769     / | ./ | .// | /cC/* \
1770     | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
1771     | /usr/ucb/* ) ;;
1772     *)
1773       # OSF1 and SCO ODT 3.0 have their own names for install.
1774       # Don't use installbsd from OSF since it installs stuff as root
1775       # by default.
1776       for ac_prog in ginstall scoinst install; do
1777         if $as_executable_p "$ac_dir/$ac_prog"; then
1778           if test $ac_prog = install &&
1779             grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
1780             # AIX install.  It has an incompatible calling convention.
1781             :
1782           elif test $ac_prog = install &&
1783             grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
1784             # program-specific install script used by HP pwplus--don't use.
1785             :
1786           else
1787             ac_cv_path_install="$ac_dir/$ac_prog -c"
1788             break 2
1789           fi
1790         fi
1791       done
1792       ;;
1793     esac
1794   done
1795
1796 fi
1797   if test "${ac_cv_path_install+set}" = set; then
1798     INSTALL=$ac_cv_path_install
1799   else
1800     # As a last resort, use the slow shell script.  We don't cache a
1801     # path for INSTALL within a source directory, because that will
1802     # break other packages using the cache if that directory is
1803     # removed, or if the path is relative.
1804     INSTALL=$ac_install_sh
1805   fi
1806 fi
1807 echo "$as_me:1807: result: $INSTALL" >&5
1808 echo "${ECHO_T}$INSTALL" >&6
1809
1810 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1811 # It thinks the first close brace ends the variable substitution.
1812 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1813
1814 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
1815
1816 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1817
1818 for ac_prog in mawk gawk nawk awk
1819 do
1820   # Extract the first word of "$ac_prog", so it can be a program name with args.
1821 set dummy $ac_prog; ac_word=$2
1822 echo "$as_me:1822: checking for $ac_word" >&5
1823 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1824 if test "${ac_cv_prog_AWK+set}" = set; then
1825   echo $ECHO_N "(cached) $ECHO_C" >&6
1826 else
1827   if test -n "$AWK"; then
1828   ac_cv_prog_AWK="$AWK" # Let the user override the test.
1829 else
1830   ac_save_IFS=$IFS; IFS=$ac_path_separator
1831 ac_dummy="$PATH"
1832 for ac_dir in $ac_dummy; do
1833   IFS=$ac_save_IFS
1834   test -z "$ac_dir" && ac_dir=.
1835   $as_executable_p "$ac_dir/$ac_word" || continue
1836 ac_cv_prog_AWK="$ac_prog"
1837 echo "$as_me:1837: found $ac_dir/$ac_word" >&5
1838 break
1839 done
1840
1841 fi
1842 fi
1843 AWK=$ac_cv_prog_AWK
1844 if test -n "$AWK"; then
1845   echo "$as_me:1845: result: $AWK" >&5
1846 echo "${ECHO_T}$AWK" >&6
1847 else
1848   echo "$as_me:1848: result: no" >&5
1849 echo "${ECHO_T}no" >&6
1850 fi
1851
1852   test -n "$AWK" && break
1853 done
1854
1855 echo "$as_me:1855: checking for POSIXized ISC" >&5
1856 echo $ECHO_N "checking for POSIXized ISC... $ECHO_C" >&6
1857 if test -d /etc/conf/kconfig.d &&
1858    grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
1859 then
1860   echo "$as_me:1860: result: yes" >&5
1861 echo "${ECHO_T}yes" >&6
1862   ISC=yes # If later tests want to check for ISC.
1863
1864 cat >>confdefs.h <<\EOF
1865 #define _POSIX_SOURCE 1
1866 EOF
1867
1868   if test "$GCC" = yes; then
1869     CC="$CC -posix"
1870   else
1871     CC="$CC -Xp"
1872   fi
1873 else
1874   echo "$as_me:1874: result: no" >&5
1875 echo "${ECHO_T}no" >&6
1876   ISC=
1877 fi
1878
1879 if test "x$CC" != xcc; then
1880   echo "$as_me:1880: checking whether $CC and cc understand -c and -o together" >&5
1881 echo $ECHO_N "checking whether $CC and cc understand -c and -o together... $ECHO_C" >&6
1882 else
1883   echo "$as_me:1883: checking whether cc understands -c and -o together" >&5
1884 echo $ECHO_N "checking whether cc understands -c and -o together... $ECHO_C" >&6
1885 fi
1886 set dummy $CC; ac_cc=`echo $2 |
1887                       sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
1888 if eval "test \"\${ac_cv_prog_cc_${ac_cc}_c_o+set}\" = set"; then
1889   echo $ECHO_N "(cached) $ECHO_C" >&6
1890 else
1891   cat >conftest.$ac_ext <<_ACEOF
1892 #line 1892 "configure"
1893 #include "confdefs.h"
1894
1895 int
1896 main ()
1897 {
1898
1899   ;
1900   return 0;
1901 }
1902 _ACEOF
1903 # Make sure it works both with $CC and with simple cc.
1904 # We do the test twice because some compilers refuse to overwrite an
1905 # existing .o file with -o, though they will create one.
1906 ac_try='$CC -c conftest.$ac_ext -o conftest.$ac_objext >&5'
1907 if { (eval echo "$as_me:1907: \"$ac_try\"") >&5
1908   (eval $ac_try) 2>&5
1909   ac_status=$?
1910   echo "$as_me:1910: \$? = $ac_status" >&5
1911   (exit $ac_status); } &&
1912    test -f conftest.$ac_objext && { (eval echo "$as_me:1912: \"$ac_try\"") >&5
1913   (eval $ac_try) 2>&5
1914   ac_status=$?
1915   echo "$as_me:1915: \$? = $ac_status" >&5
1916   (exit $ac_status); };
1917 then
1918   eval ac_cv_prog_cc_${ac_cc}_c_o=yes
1919   if test "x$CC" != xcc; then
1920     # Test first that cc exists at all.
1921     if { ac_try='cc -c conftest.$ac_ext >&5'
1922   { (eval echo "$as_me:1922: \"$ac_try\"") >&5
1923   (eval $ac_try) 2>&5
1924   ac_status=$?
1925   echo "$as_me:1925: \$? = $ac_status" >&5
1926   (exit $ac_status); }; }; then
1927       ac_try='cc -c conftest.$ac_ext -o conftest.$ac_objext >&5'
1928       if { (eval echo "$as_me:1928: \"$ac_try\"") >&5
1929   (eval $ac_try) 2>&5
1930   ac_status=$?
1931   echo "$as_me:1931: \$? = $ac_status" >&5
1932   (exit $ac_status); } &&
1933          test -f conftest.$ac_objext && { (eval echo "$as_me:1933: \"$ac_try\"") >&5
1934   (eval $ac_try) 2>&5
1935   ac_status=$?
1936   echo "$as_me:1936: \$? = $ac_status" >&5
1937   (exit $ac_status); };
1938       then
1939         # cc works too.
1940         :
1941       else
1942         # cc exists but doesn't like -o.
1943         eval ac_cv_prog_cc_${ac_cc}_c_o=no
1944       fi
1945     fi
1946   fi
1947 else
1948   eval ac_cv_prog_cc_${ac_cc}_c_o=no
1949 fi
1950 rm -f conftest*
1951
1952 fi
1953 if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = yes"; then
1954   echo "$as_me:1954: result: yes" >&5
1955 echo "${ECHO_T}yes" >&6
1956 else
1957   echo "$as_me:1957: result: no" >&5
1958 echo "${ECHO_T}no" >&6
1959
1960 cat >>confdefs.h <<\EOF
1961 #define NO_MINUS_C_MINUS_O 1
1962 EOF
1963
1964 fi
1965
1966 if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = no"; then
1967       BROKEN_CC=
1968 else
1969       BROKEN_CC=#
1970 fi
1971
1972 echo "$as_me:1972: checking that the C compiler understands volatile" >&5
1973 echo $ECHO_N "checking that the C compiler understands volatile... $ECHO_C" >&6
1974 if test "${samba_cv_volatile+set}" = set; then
1975   echo $ECHO_N "(cached) $ECHO_C" >&6
1976 else
1977
1978 cat >conftest.$ac_ext <<_ACEOF
1979 #line 1979 "configure"
1980 #include "confdefs.h"
1981 #include <sys/types.h>
1982 int
1983 main ()
1984 {
1985 volatile int i = 0
1986   ;
1987   return 0;
1988 }
1989 _ACEOF
1990 rm -f conftest.$ac_objext
1991 if { (eval echo "$as_me:1991: \"$ac_compile\"") >&5
1992   (eval $ac_compile) 2>&5
1993   ac_status=$?
1994   echo "$as_me:1994: \$? = $ac_status" >&5
1995   (exit $ac_status); } &&
1996          { ac_try='test -s conftest.$ac_objext'
1997   { (eval echo "$as_me:1997: \"$ac_try\"") >&5
1998   (eval $ac_try) 2>&5
1999   ac_status=$?
2000   echo "$as_me:2000: \$? = $ac_status" >&5
2001   (exit $ac_status); }; }; then
2002   samba_cv_volatile=yes
2003 else
2004   echo "$as_me: failed program was:" >&5
2005 cat conftest.$ac_ext >&5
2006 samba_cv_volatile=no
2007 fi
2008 rm -f conftest.$ac_objext conftest.$ac_ext
2009 fi
2010 echo "$as_me:2010: result: $samba_cv_volatile" >&5
2011 echo "${ECHO_T}$samba_cv_volatile" >&6
2012 if test x"$samba_cv_volatile" = x"yes"; then
2013    cat >>confdefs.h <<\EOF
2014 #define HAVE_VOLATILE 1
2015 EOF
2016
2017 fi
2018
2019 # Make sure we can run config.sub.
2020 $ac_config_sub sun4 >/dev/null 2>&1 ||
2021   { { echo "$as_me:2021: error: cannot run $ac_config_sub" >&5
2022 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
2023    { (exit 1); exit 1; }; }
2024
2025 echo "$as_me:2025: checking build system type" >&5
2026 echo $ECHO_N "checking build system type... $ECHO_C" >&6
2027 if test "${ac_cv_build+set}" = set; then
2028   echo $ECHO_N "(cached) $ECHO_C" >&6
2029 else
2030   ac_cv_build_alias=$build_alias
2031 test -z "$ac_cv_build_alias" &&
2032   ac_cv_build_alias=`$ac_config_guess`
2033 test -z "$ac_cv_build_alias" &&
2034   { { echo "$as_me:2034: error: cannot guess build type; you must specify one" >&5
2035 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
2036    { (exit 1); exit 1; }; }
2037 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
2038   { { echo "$as_me:2038: error: $ac_config_sub $ac_cv_build_alias failed." >&5
2039 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
2040    { (exit 1); exit 1; }; }
2041
2042 fi
2043 echo "$as_me:2043: result: $ac_cv_build" >&5
2044 echo "${ECHO_T}$ac_cv_build" >&6
2045 build=$ac_cv_build
2046 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
2047 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
2048 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
2049
2050 echo "$as_me:2050: checking host system type" >&5
2051 echo $ECHO_N "checking host system type... $ECHO_C" >&6
2052 if test "${ac_cv_host+set}" = set; then
2053   echo $ECHO_N "(cached) $ECHO_C" >&6
2054 else
2055   ac_cv_host_alias=$host_alias
2056 test -z "$ac_cv_host_alias" &&
2057   ac_cv_host_alias=$ac_cv_build_alias
2058 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
2059   { { echo "$as_me:2059: error: $ac_config_sub $ac_cv_host_alias failed" >&5
2060 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
2061    { (exit 1); exit 1; }; }
2062
2063 fi
2064 echo "$as_me:2064: result: $ac_cv_host" >&5
2065 echo "${ECHO_T}$ac_cv_host" >&6
2066 host=$ac_cv_host
2067 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
2068 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
2069 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
2070
2071 echo "$as_me:2071: checking target system type" >&5
2072 echo $ECHO_N "checking target system type... $ECHO_C" >&6
2073 if test "${ac_cv_target+set}" = set; then
2074   echo $ECHO_N "(cached) $ECHO_C" >&6
2075 else
2076   ac_cv_target_alias=$target_alias
2077 test "x$ac_cv_target_alias" = "x" &&
2078   ac_cv_target_alias=$ac_cv_host_alias
2079 ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
2080   { { echo "$as_me:2080: error: $ac_config_sub $ac_cv_target_alias failed" >&5
2081 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
2082    { (exit 1); exit 1; }; }
2083
2084 fi
2085 echo "$as_me:2085: result: $ac_cv_target" >&5
2086 echo "${ECHO_T}$ac_cv_target" >&6
2087 target=$ac_cv_target
2088 target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
2089 target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
2090 target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
2091
2092 # The aliases save the names the user supplied, while $host etc.
2093 # will get canonicalized.
2094 test -n "$target_alias" &&
2095   test "$program_prefix$program_suffix$program_transform_name" = \
2096     NONENONEs,x,x, &&
2097   program_prefix=${target_alias}-
2098
2099   case "$host_os" in
2100         *irix6*) cat >> confdefs.h <<\EOF
2101 #include <standards.h>
2102 EOF
2103
2104         ;;
2105 esac
2106
2107     echo "$as_me:2107: checking config.cache system type" >&5
2108 echo $ECHO_N "checking config.cache system type... $ECHO_C" >&6
2109     if { test x"${ac_cv_host_system_type+set}" = x"set" &&
2110          test x"$ac_cv_host_system_type" != x"$host"; } ||
2111        { test x"${ac_cv_build_system_type+set}" = x"set" &&
2112          test x"$ac_cv_build_system_type" != x"$build"; } ||
2113        { test x"${ac_cv_target_system_type+set}" = x"set" &&
2114          test x"$ac_cv_target_system_type" != x"$target"; }; then
2115         echo "$as_me:2115: result: different" >&5
2116 echo "${ECHO_T}different" >&6
2117         { { echo "$as_me:2117: error: \"you must remove config.cache and restart configure\"" >&5
2118 echo "$as_me: error: \"you must remove config.cache and restart configure\"" >&2;}
2119    { (exit 1); exit 1; }; }
2120     else
2121         echo "$as_me:2121: result: same" >&5
2122 echo "${ECHO_T}same" >&6
2123     fi
2124     ac_cv_host_system_type="$host"
2125     ac_cv_build_system_type="$build"
2126     ac_cv_target_system_type="$target"
2127
2128 #
2129 # Config CPPFLAG settings for strange OS's that must be set
2130 # before other tests.
2131 #
2132 case "$host_os" in
2133 # Try to work out if this is the native HPUX compiler that uses the -Ae flag.
2134     *hpux*)
2135       echo "$as_me:2135: checking whether ${CC-cc} accepts -Ae" >&5
2136 echo $ECHO_N "checking whether ${CC-cc} accepts -Ae... $ECHO_C" >&6
2137 if test "${ac_cv_prog_cc_Ae+set}" = set; then
2138   echo $ECHO_N "(cached) $ECHO_C" >&6
2139 else
2140   echo 'void f(){}' > conftest.c
2141 if test -z "`${CC-cc} -Ae -c conftest.c 2>&1`"; then
2142   ac_cv_prog_cc_Ae=yes
2143 else
2144   ac_cv_prog_cc_Ae=no
2145 fi
2146 rm -f conftest*
2147
2148 fi
2149 echo "$as_me:2149: result: $ac_cv_prog_cc_Ae" >&5
2150 echo "${ECHO_T}$ac_cv_prog_cc_Ae" >&6
2151       # mmap on HPUX is completely broken...
2152       cat >>confdefs.h <<\EOF
2153 #define MMAP_BLACKLIST 1
2154 EOF
2155
2156       if test $ac_cv_prog_cc_Ae = yes; then
2157         CPPFLAGS="$CPPFLAGS -Ae"
2158       fi
2159 #
2160 # Defines needed for HPUX support.
2161 # HPUX has bigcrypt but (sometimes?) doesn't use it for
2162 # password hashing - hence the USE_BOTH_CRYPT_CALLS define.
2163 #
2164       case `uname -r` in
2165                         *9*|*10*)
2166                                 CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_POSIX_SOURCE"
2167                                 cat >>confdefs.h <<\EOF
2168 #define USE_BOTH_CRYPT_CALLS 1
2169 EOF
2170
2171                                 ;;
2172                         *11*)
2173                                 CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_POSIX_SOURCE -D_LARGEFILE64_SOURCE"
2174                                 cat >>confdefs.h <<\EOF
2175 #define USE_BOTH_CRYPT_CALLS 1
2176 EOF
2177
2178                                 ;;
2179       esac
2180       ;;
2181 #
2182 # AIX4.x doesn't even admit to having large
2183 # files *at all* unless the -D_LARGE_FILE or -D_LARGE_FILE_API flags are set.
2184 #
2185     *aix4*)
2186           echo "$as_me:2186: result: enabling large file support" >&5
2187 echo "${ECHO_T}enabling large file support" >&6
2188       CPPFLAGS="$CPPFLAGS -D_LARGE_FILES"
2189       ;;
2190 #
2191 # Defines needed for Solaris 2.6/2.7 aka 7.0 to make it admit
2192 # to the existance of large files..
2193 # Note that -D_LARGEFILE64_SOURCE is different from the Sun
2194 # recommendations on large file support, however it makes the
2195 # compile work using gcc 2.7 and 2.8, whereas using the Sun
2196 # recommendation makes the compile fail on gcc2.7. JRA.
2197 #
2198         *solaris*)
2199                 case `uname -r` in
2200                         5.0*|5.1*|5.2*|5.3*|5.5*)
2201                                 echo "$as_me:2201: result: no large file support" >&5
2202 echo "${ECHO_T}no large file support" >&6
2203                                 ;;
2204                         5.*)
2205                         echo "$as_me:2205: result: enabling large file support" >&5
2206 echo "${ECHO_T}enabling large file support" >&6
2207                         if test "$ac_cv_c_compiler_gnu" = yes; then
2208                                 ${CC-cc} -v >conftest.c 2>&1
2209                                 ac_cv_gcc_compiler_version_number=`grep 'gcc version' conftest.c`
2210                                 rm -fr conftest.c
2211                                 case "$ac_cv_gcc_compiler_version_number" in
2212                                         *"gcc version 2.6"*|*"gcc version 2.7"*)
2213                                                 CPPFLAGS="$CPPFLAGS -D_LARGEFILE64_SOURCE"
2214                                                 ;;
2215                                         *)
2216                                                 CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
2217                                                 ;;
2218                                 esac
2219                         else
2220                                 CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
2221                         fi
2222                         ;;
2223                 esac
2224                 ;;
2225 #
2226 # Tests needed for SINIX large file support.
2227 #
2228     *sysv4*)
2229       if test $host = mips-sni-sysv4 ; then
2230         echo "$as_me:2230: checking for LFS support" >&5
2231 echo $ECHO_N "checking for LFS support... $ECHO_C" >&6
2232         old_CPPFLAGS="$CPPFLAGS"
2233         CPPFLAGS="-D_LARGEFILE64_SOURCE $CPPFLAGS"
2234         if test "$cross_compiling" = yes; then
2235   SINIX_LFS_SUPPORT=cross
2236 else
2237   cat >conftest.$ac_ext <<_ACEOF
2238 #line 2238 "configure"
2239 #include "confdefs.h"
2240
2241 #include <unistd.h>
2242 main () {
2243 #if _LFS64_LARGEFILE == 1
2244 exit(0);
2245 #else
2246 exit(1);
2247 #endif
2248 }
2249 _ACEOF
2250 rm -f conftest$ac_exeext
2251 if { (eval echo "$as_me:2251: \"$ac_link\"") >&5
2252   (eval $ac_link) 2>&5
2253   ac_status=$?
2254   echo "$as_me:2254: \$? = $ac_status" >&5
2255   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
2256   { (eval echo "$as_me:2256: \"$ac_try\"") >&5
2257   (eval $ac_try) 2>&5
2258   ac_status=$?
2259   echo "$as_me:2259: \$? = $ac_status" >&5
2260   (exit $ac_status); }; }; then
2261   SINIX_LFS_SUPPORT=yes
2262 else
2263   echo "$as_me: program exited with status $ac_status" >&5
2264 echo "$as_me: failed program was:" >&5
2265 cat conftest.$ac_ext >&5
2266 SINIX_LFS_SUPPORT=no
2267 fi
2268 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
2269 fi
2270         CPPFLAGS="$old_CPPFLAGS"
2271         if test x$SINIX_LFS_SUPPORT = xyes ; then
2272           CPPFLAGS="-D_LARGEFILE64_SOURCE $CPPFLAGS"
2273           CFLAGS="`getconf LFS64_CFLAGS` $CFLAGS"
2274           LDFLAGS="`getconf LFS64_LDFLAGS` $LDFLAGS"
2275           LIBS="`getconf LFS64_LIBS` $LIBS"
2276         fi
2277       echo "$as_me:2277: result: $SINIX_LFS_SUPPORT" >&5
2278 echo "${ECHO_T}$SINIX_LFS_SUPPORT" >&6
2279       fi
2280     ;;
2281
2282 # Tests for linux LFS support. Need kernel 2.4 and glibc2.2 or greater support.
2283 #
2284     *linux*)
2285         echo "$as_me:2285: checking for LFS support" >&5
2286 echo $ECHO_N "checking for LFS support... $ECHO_C" >&6
2287         old_CPPFLAGS="$CPPFLAGS"
2288         CPPFLAGS="-D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE $CPPFLAGS"
2289        if test "$cross_compiling" = yes; then
2290   LINUX_LFS_SUPPORT=cross
2291 else
2292   cat >conftest.$ac_ext <<_ACEOF
2293 #line 2293 "configure"
2294 #include "confdefs.h"
2295
2296 #include <unistd.h>
2297 #include <sys/utsname.h>
2298 main() {
2299 #if _LFS64_LARGEFILE == 1
2300        struct utsname uts;
2301        char *release;
2302        int major, minor;
2303
2304        /* Ensure this is glibc 2.2 or higher */
2305 #if defined(__GLIBC__) && defined(__GLIBC_MINOR__)
2306        int libc_major = __GLIBC__;
2307        int libc_minor = __GLIBC_MINOR__;
2308
2309        if (libc_major < 2)
2310               exit(1);
2311        if (libc_minor < 2)
2312               exit(1);
2313 #endif
2314
2315        /* Ensure this is kernel 2.4 or higher */
2316
2317        uname(&uts);
2318        release = uts.release;
2319        major = atoi(strsep(&release, "."));
2320        minor = atoi(strsep(&release, "."));
2321
2322        if (major > 2 || (major == 2 && minor > 3))
2323                exit(0);
2324        exit(1);
2325 #else
2326        exit(1);
2327 #endif
2328 }
2329
2330 _ACEOF
2331 rm -f conftest$ac_exeext
2332 if { (eval echo "$as_me:2332: \"$ac_link\"") >&5
2333   (eval $ac_link) 2>&5
2334   ac_status=$?
2335   echo "$as_me:2335: \$? = $ac_status" >&5
2336   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
2337   { (eval echo "$as_me:2337: \"$ac_try\"") >&5
2338   (eval $ac_try) 2>&5
2339   ac_status=$?
2340   echo "$as_me:2340: \$? = $ac_status" >&5
2341   (exit $ac_status); }; }; then
2342   LINUX_LFS_SUPPORT=yes
2343 else
2344   echo "$as_me: program exited with status $ac_status" >&5
2345 echo "$as_me: failed program was:" >&5
2346 cat conftest.$ac_ext >&5
2347 LINUX_LFS_SUPPORT=no
2348 fi
2349 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
2350 fi
2351         CPPFLAGS="$old_CPPFLAGS"
2352         if test x$LINUX_LFS_SUPPORT = xyes ; then
2353           CPPFLAGS="-D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE $CPPFLAGS"
2354         fi
2355        echo "$as_me:2355: result: $LINUX_LFS_SUPPORT" >&5
2356 echo "${ECHO_T}$LINUX_LFS_SUPPORT" >&6
2357                 ;;
2358
2359     *hurd*)
2360         echo "$as_me:2360: checking for LFS support" >&5
2361 echo $ECHO_N "checking for LFS support... $ECHO_C" >&6
2362         old_CPPFLAGS="$CPPFLAGS"
2363         CPPFLAGS="-D_LARGEFILE64_SOURCE -D_GNU_SOURCE $CPPFLAGS"
2364         if test "$cross_compiling" = yes; then
2365   GLIBC_LFS_SUPPORT=cross
2366 else
2367   cat >conftest.$ac_ext <<_ACEOF
2368 #line 2368 "configure"
2369 #include "confdefs.h"
2370
2371 #include <unistd.h>
2372 main () {
2373 #if _LFS64_LARGEFILE == 1
2374 exit(0);
2375 #else
2376 exit(1);
2377 #endif
2378 }
2379 _ACEOF
2380 rm -f conftest$ac_exeext
2381 if { (eval echo "$as_me:2381: \"$ac_link\"") >&5
2382   (eval $ac_link) 2>&5
2383   ac_status=$?
2384   echo "$as_me:2384: \$? = $ac_status" >&5
2385   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
2386   { (eval echo "$as_me:2386: \"$ac_try\"") >&5
2387   (eval $ac_try) 2>&5
2388   ac_status=$?
2389   echo "$as_me:2389: \$? = $ac_status" >&5
2390   (exit $ac_status); }; }; then
2391   GLIBC_LFS_SUPPORT=yes
2392 else
2393   echo "$as_me: program exited with status $ac_status" >&5
2394 echo "$as_me: failed program was:" >&5
2395 cat conftest.$ac_ext >&5
2396 GLIBC_LFS_SUPPORT=no
2397 fi
2398 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
2399 fi
2400         CPPFLAGS="$old_CPPFLAGS"
2401         if test x$GLIBC_LFS_SUPPORT = xyes ; then
2402           CPPFLAGS="-D_LARGEFILE64_SOURCE -D_GNU_SOURCE $CPPFLAGS"
2403         fi
2404       echo "$as_me:2404: result: $GLIBC_LFS_SUPPORT" >&5
2405 echo "${ECHO_T}$GLIBC_LFS_SUPPORT" >&6
2406     ;;
2407
2408 esac
2409
2410 echo "$as_me:2410: checking for $CC option to accept ANSI C" >&5
2411 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2412 if test "${ac_cv_prog_cc_stdc+set}" = set; then
2413   echo $ECHO_N "(cached) $ECHO_C" >&6
2414 else
2415   ac_cv_prog_cc_stdc=no
2416 ac_save_CC=$CC
2417 cat >conftest.$ac_ext <<_ACEOF
2418 #line 2418 "configure"
2419 #include "confdefs.h"
2420 #include <stdarg.h>
2421 #include <stdio.h>
2422 #include <sys/types.h>
2423 #include <sys/stat.h>
2424 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
2425 struct buf { int x; };
2426 FILE * (*rcsopen) (struct buf *, struct stat *, int);
2427 static char *e (p, i)
2428      char **p;
2429      int i;
2430 {
2431   return p[i];
2432 }
2433 static char *f (char * (*g) (char **, int), char **p, ...)
2434 {
2435   char *s;
2436   va_list v;
2437   va_start (v,p);
2438   s = g (p, va_arg (v,int));
2439   va_end (v);
2440   return s;
2441 }
2442 int test (int i, double x);
2443 struct s1 {int (*f) (int a);};
2444 struct s2 {int (*f) (double a);};
2445 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2446 int argc;
2447 char **argv;
2448 int
2449 main ()
2450 {
2451 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
2452   ;
2453   return 0;
2454 }
2455 _ACEOF
2456 # Don't try gcc -ansi; that turns off useful extensions and
2457 # breaks some systems' header files.
2458 # AIX                   -qlanglvl=ansi
2459 # Ultrix and OSF/1      -std1
2460 # HP-UX 10.20 and later -Ae
2461 # HP-UX older versions  -Aa -D_HPUX_SOURCE
2462 # SVR4                  -Xc -D__EXTENSIONS__
2463 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2464 do
2465   CC="$ac_save_CC $ac_arg"
2466   rm -f conftest.$ac_objext
2467 if { (eval echo "$as_me:2467: \"$ac_compile\"") >&5
2468   (eval $ac_compile) 2>&5
2469   ac_status=$?
2470   echo "$as_me:2470: \$? = $ac_status" >&5
2471   (exit $ac_status); } &&
2472          { ac_try='test -s conftest.$ac_objext'
2473   { (eval echo "$as_me:2473: \"$ac_try\"") >&5
2474   (eval $ac_try) 2>&5
2475   ac_status=$?
2476   echo "$as_me:2476: \$? = $ac_status" >&5
2477   (exit $ac_status); }; }; then
2478   ac_cv_prog_cc_stdc=$ac_arg
2479 break
2480 else
2481   echo "$as_me: failed program was:" >&5
2482 cat conftest.$ac_ext >&5
2483 fi
2484 rm -f conftest.$ac_objext
2485 done
2486 rm -f conftest.$ac_ext conftest.$ac_objext
2487 CC=$ac_save_CC
2488
2489 fi
2490
2491 case "x$ac_cv_prog_cc_stdc" in
2492   x|xno)
2493     echo "$as_me:2493: result: none needed" >&5
2494 echo "${ECHO_T}none needed" >&6 ;;
2495   *)
2496     echo "$as_me:2496: result: $ac_cv_prog_cc_stdc" >&5
2497 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2498     CC="$CC $ac_cv_prog_cc_stdc" ;;
2499 esac
2500
2501 echo "$as_me:2501: checking for inline" >&5
2502 echo $ECHO_N "checking for inline... $ECHO_C" >&6
2503 if test "${ac_cv_c_inline+set}" = set; then
2504   echo $ECHO_N "(cached) $ECHO_C" >&6
2505 else
2506   ac_cv_c_inline=no
2507 for ac_kw in inline __inline__ __inline; do
2508   cat >conftest.$ac_ext <<_ACEOF
2509 #line 2509 "configure"
2510 #include "confdefs.h"
2511 #ifndef __cplusplus
2512 static $ac_kw int static_foo () {return 0; }
2513 $ac_kw int foo () {return 0; }
2514 #endif
2515
2516 _ACEOF
2517 rm -f conftest.$ac_objext
2518 if { (eval echo "$as_me:2518: \"$ac_compile\"") >&5
2519   (eval $ac_compile) 2>&5
2520   ac_status=$?
2521   echo "$as_me:2521: \$? = $ac_status" >&5
2522   (exit $ac_status); } &&
2523          { ac_try='test -s conftest.$ac_objext'
2524   { (eval echo "$as_me:2524: \"$ac_try\"") >&5
2525   (eval $ac_try) 2>&5
2526   ac_status=$?
2527   echo "$as_me:2527: \$? = $ac_status" >&5
2528   (exit $ac_status); }; }; then
2529   ac_cv_c_inline=$ac_kw; break
2530 else
2531   echo "$as_me: failed program was:" >&5
2532 cat conftest.$ac_ext >&5
2533 fi
2534 rm -f conftest.$ac_objext conftest.$ac_ext
2535 done
2536
2537 fi
2538 echo "$as_me:2538: result: $ac_cv_c_inline" >&5
2539 echo "${ECHO_T}$ac_cv_c_inline" >&6
2540 case $ac_cv_c_inline in
2541   inline | yes) ;;
2542   no)
2543 cat >>confdefs.h <<\EOF
2544 #define inline
2545 EOF
2546  ;;
2547   *)  cat >>confdefs.h <<EOF
2548 #define inline $ac_cv_c_inline
2549 EOF
2550  ;;
2551 esac
2552
2553 ac_ext=c
2554 ac_cpp='$CPP $CPPFLAGS'
2555 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2556 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2557 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2558 echo "$as_me:2558: checking how to run the C preprocessor" >&5
2559 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2560 # On Suns, sometimes $CPP names a directory.
2561 if test -n "$CPP" && test -d "$CPP"; then
2562   CPP=
2563 fi
2564 if test -z "$CPP"; then
2565   if test "${ac_cv_prog_CPP+set}" = set; then
2566   echo $ECHO_N "(cached) $ECHO_C" >&6
2567 else
2568       # Double quotes because CPP needs to be expanded
2569     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2570     do
2571       ac_preproc_ok=false
2572 for ac_c_preproc_warn_flag in '' yes
2573 do
2574   # Use a header file that comes with gcc, so configuring glibc
2575   # with a fresh cross-compiler works.
2576   # On the NeXT, cc -E runs the code through the compiler's parser,
2577   # not just through cpp. "Syntax error" is here to catch this case.
2578   cat >conftest.$ac_ext <<_ACEOF
2579 #line 2579 "configure"
2580 #include "confdefs.h"
2581 #include <assert.h>
2582                      Syntax error
2583 _ACEOF
2584 if { (eval echo "$as_me:2584: \"$ac_cpp conftest.$ac_ext\"") >&5
2585   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2586   ac_status=$?
2587   egrep -v '^ *\+' conftest.er1 >conftest.err
2588   rm -f conftest.er1
2589   cat conftest.err >&5
2590   echo "$as_me:2590: \$? = $ac_status" >&5
2591   (exit $ac_status); } >/dev/null; then
2592   if test -s conftest.err; then
2593     ac_cpp_err=$ac_c_preproc_warn_flag
2594   else
2595     ac_cpp_err=
2596   fi
2597 else
2598   ac_cpp_err=yes
2599 fi
2600 if test -z "$ac_cpp_err"; then
2601   :
2602 else
2603   echo "$as_me: failed program was:" >&5
2604   cat conftest.$ac_ext >&5
2605   # Broken: fails on valid input.
2606 continue
2607 fi
2608 rm -f conftest.err conftest.$ac_ext
2609
2610   # OK, works on sane cases.  Now check whether non-existent headers
2611   # can be detected and how.
2612   cat >conftest.$ac_ext <<_ACEOF
2613 #line 2613 "configure"
2614 #include "confdefs.h"
2615 #include <ac_nonexistent.h>
2616 _ACEOF
2617 if { (eval echo "$as_me:2617: \"$ac_cpp conftest.$ac_ext\"") >&5
2618   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2619   ac_status=$?
2620   egrep -v '^ *\+' conftest.er1 >conftest.err
2621   rm -f conftest.er1
2622   cat conftest.err >&5
2623   echo "$as_me:2623: \$? = $ac_status" >&5
2624   (exit $ac_status); } >/dev/null; then
2625   if test -s conftest.err; then
2626     ac_cpp_err=$ac_c_preproc_warn_flag
2627   else
2628     ac_cpp_err=
2629   fi
2630 else
2631   ac_cpp_err=yes
2632 fi
2633 if test -z "$ac_cpp_err"; then
2634   # Broken: success on invalid input.
2635 continue
2636 else
2637   echo "$as_me: failed program was:" >&5
2638   cat conftest.$ac_ext >&5
2639   # Passes both tests.
2640 ac_preproc_ok=:
2641 break
2642 fi
2643 rm -f conftest.err conftest.$ac_ext
2644
2645 done
2646 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2647 rm -f conftest.err conftest.$ac_ext
2648 if $ac_preproc_ok; then
2649   break
2650 fi
2651
2652     done
2653     ac_cv_prog_CPP=$CPP
2654
2655 fi
2656   CPP=$ac_cv_prog_CPP
2657 else
2658   ac_cv_prog_CPP=$CPP
2659 fi
2660 echo "$as_me:2660: result: $CPP" >&5
2661 echo "${ECHO_T}$CPP" >&6
2662 ac_preproc_ok=false
2663 for ac_c_preproc_warn_flag in '' yes
2664 do
2665   # Use a header file that comes with gcc, so configuring glibc
2666   # with a fresh cross-compiler works.
2667   # On the NeXT, cc -E runs the code through the compiler's parser,
2668   # not just through cpp. "Syntax error" is here to catch this case.
2669   cat >conftest.$ac_ext <<_ACEOF
2670 #line 2670 "configure"
2671 #include "confdefs.h"
2672 #include <assert.h>
2673                      Syntax error
2674 _ACEOF
2675 if { (eval echo "$as_me:2675: \"$ac_cpp conftest.$ac_ext\"") >&5
2676   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2677   ac_status=$?
2678   egrep -v '^ *\+' conftest.er1 >conftest.err
2679   rm -f conftest.er1
2680   cat conftest.err >&5
2681   echo "$as_me:2681: \$? = $ac_status" >&5
2682   (exit $ac_status); } >/dev/null; then
2683   if test -s conftest.err; then
2684     ac_cpp_err=$ac_c_preproc_warn_flag
2685   else
2686     ac_cpp_err=
2687   fi
2688 else
2689   ac_cpp_err=yes
2690 fi
2691 if test -z "$ac_cpp_err"; then
2692   :
2693 else
2694   echo "$as_me: failed program was:" >&5
2695   cat conftest.$ac_ext >&5
2696   # Broken: fails on valid input.
2697 continue
2698 fi
2699 rm -f conftest.err conftest.$ac_ext
2700
2701   # OK, works on sane cases.  Now check whether non-existent headers
2702   # can be detected and how.
2703   cat >conftest.$ac_ext <<_ACEOF
2704 #line 2704 "configure"
2705 #include "confdefs.h"
2706 #include <ac_nonexistent.h>
2707 _ACEOF
2708 if { (eval echo "$as_me:2708: \"$ac_cpp conftest.$ac_ext\"") >&5
2709   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2710   ac_status=$?
2711   egrep -v '^ *\+' conftest.er1 >conftest.err
2712   rm -f conftest.er1
2713   cat conftest.err >&5
2714   echo "$as_me:2714: \$? = $ac_status" >&5
2715   (exit $ac_status); } >/dev/null; then
2716   if test -s conftest.err; then
2717     ac_cpp_err=$ac_c_preproc_warn_flag
2718   else
2719     ac_cpp_err=
2720   fi
2721 else
2722   ac_cpp_err=yes
2723 fi
2724 if test -z "$ac_cpp_err"; then
2725   # Broken: success on invalid input.
2726 continue
2727 else
2728   echo "$as_me: failed program was:" >&5
2729   cat conftest.$ac_ext >&5
2730   # Passes both tests.
2731 ac_preproc_ok=:
2732 break
2733 fi
2734 rm -f conftest.err conftest.$ac_ext
2735
2736 done
2737 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2738 rm -f conftest.err conftest.$ac_ext
2739 if $ac_preproc_ok; then
2740   :
2741 else
2742   { { echo "$as_me:2742: error: C preprocessor \"$CPP\" fails sanity check" >&5
2743 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2744    { (exit 1); exit 1; }; }
2745 fi
2746
2747 ac_ext=c
2748 ac_cpp='$CPP $CPPFLAGS'
2749 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2750 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2751 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2752
2753 echo "$as_me:2753: checking for ANSI C header files" >&5
2754 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
2755 if test "${ac_cv_header_stdc+set}" = set; then
2756   echo $ECHO_N "(cached) $ECHO_C" >&6
2757 else
2758   cat >conftest.$ac_ext <<_ACEOF
2759 #line 2759 "configure"
2760 #include "confdefs.h"
2761 #include <stdlib.h>
2762 #include <stdarg.h>
2763 #include <string.h>
2764 #include <float.h>
2765
2766 _ACEOF
2767 if { (eval echo "$as_me:2767: \"$ac_cpp conftest.$ac_ext\"") >&5
2768   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2769   ac_status=$?
2770   egrep -v '^ *\+' conftest.er1 >conftest.err
2771   rm -f conftest.er1
2772   cat conftest.err >&5
2773   echo "$as_me:2773: \$? = $ac_status" >&5
2774   (exit $ac_status); } >/dev/null; then
2775   if test -s conftest.err; then
2776     ac_cpp_err=$ac_c_preproc_warn_flag
2777   else
2778     ac_cpp_err=
2779   fi
2780 else
2781   ac_cpp_err=yes
2782 fi
2783 if test -z "$ac_cpp_err"; then
2784   ac_cv_header_stdc=yes
2785 else
2786   echo "$as_me: failed program was:" >&5
2787   cat conftest.$ac_ext >&5
2788   ac_cv_header_stdc=no
2789 fi
2790 rm -f conftest.err conftest.$ac_ext
2791
2792 if test $ac_cv_header_stdc = yes; then
2793   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2794   cat >conftest.$ac_ext <<_ACEOF
2795 #line 2795 "configure"
2796 #include "confdefs.h"
2797 #include <string.h>
2798
2799 _ACEOF
2800 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2801   egrep "memchr" >/dev/null 2>&1; then
2802   :
2803 else
2804   ac_cv_header_stdc=no
2805 fi
2806 rm -f conftest*
2807
2808 fi
2809
2810 if test $ac_cv_header_stdc = yes; then
2811   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2812   cat >conftest.$ac_ext <<_ACEOF
2813 #line 2813 "configure"
2814 #include "confdefs.h"
2815 #include <stdlib.h>
2816
2817 _ACEOF
2818 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2819   egrep "free" >/dev/null 2>&1; then
2820   :
2821 else
2822   ac_cv_header_stdc=no
2823 fi
2824 rm -f conftest*
2825
2826 fi
2827
2828 if test $ac_cv_header_stdc = yes; then
2829   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2830   if test "$cross_compiling" = yes; then
2831   :
2832 else
2833   cat >conftest.$ac_ext <<_ACEOF
2834 #line 2834 "configure"
2835 #include "confdefs.h"
2836 #include <ctype.h>
2837 #if ((' ' & 0x0FF) == 0x020)
2838 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2839 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2840 #else
2841 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
2842                      || ('j' <= (c) && (c) <= 'r') \
2843                      || ('s' <= (c) && (c) <= 'z'))
2844 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
2845 #endif
2846
2847 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2848 int
2849 main ()
2850 {
2851   int i;
2852   for (i = 0; i < 256; i++)
2853     if (XOR (islower (i), ISLOWER (i))
2854         || toupper (i) != TOUPPER (i))
2855       exit(2);
2856   exit (0);
2857 }
2858 _ACEOF
2859 rm -f conftest$ac_exeext
2860 if { (eval echo "$as_me:2860: \"$ac_link\"") >&5
2861   (eval $ac_link) 2>&5
2862   ac_status=$?
2863   echo "$as_me:2863: \$? = $ac_status" >&5
2864   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
2865   { (eval echo "$as_me:2865: \"$ac_try\"") >&5
2866   (eval $ac_try) 2>&5
2867   ac_status=$?
2868   echo "$as_me:2868: \$? = $ac_status" >&5
2869   (exit $ac_status); }; }; then
2870   :
2871 else
2872   echo "$as_me: program exited with status $ac_status" >&5
2873 echo "$as_me: failed program was:" >&5
2874 cat conftest.$ac_ext >&5
2875 ac_cv_header_stdc=no
2876 fi
2877 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
2878 fi
2879 fi
2880 fi
2881 echo "$as_me:2881: result: $ac_cv_header_stdc" >&5
2882 echo "${ECHO_T}$ac_cv_header_stdc" >&6
2883 if test $ac_cv_header_stdc = yes; then
2884
2885 cat >>confdefs.h <<\EOF
2886 #define STDC_HEADERS 1
2887 EOF
2888
2889 fi
2890
2891 ac_header_dirent=no
2892 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
2893   as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
2894 echo "$as_me:2894: checking for $ac_hdr that defines DIR" >&5
2895 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
2896 if eval "test \"\${$as_ac_Header+set}\" = set"; then
2897   echo $ECHO_N "(cached) $ECHO_C" >&6
2898 else
2899   cat >conftest.$ac_ext <<_ACEOF
2900 #line 2900 "configure"
2901 #include "confdefs.h"
2902 #include <sys/types.h>
2903 #include <$ac_hdr>
2904
2905 int
2906 main ()
2907 {
2908 if ((DIR *) 0)
2909 return 0;
2910   ;
2911   return 0;
2912 }
2913 _ACEOF
2914 rm -f conftest.$ac_objext
2915 if { (eval echo "$as_me:2915: \"$ac_compile\"") >&5
2916   (eval $ac_compile) 2>&5
2917   ac_status=$?
2918   echo "$as_me:2918: \$? = $ac_status" >&5
2919   (exit $ac_status); } &&
2920          { ac_try='test -s conftest.$ac_objext'
2921   { (eval echo "$as_me:2921: \"$ac_try\"") >&5
2922   (eval $ac_try) 2>&5
2923   ac_status=$?
2924   echo "$as_me:2924: \$? = $ac_status" >&5
2925   (exit $ac_status); }; }; then
2926   eval "$as_ac_Header=yes"
2927 else
2928   echo "$as_me: failed program was:" >&5
2929 cat conftest.$ac_ext >&5
2930 eval "$as_ac_Header=no"
2931 fi
2932 rm -f conftest.$ac_objext conftest.$ac_ext
2933 fi
2934 echo "$as_me:2934: result: `eval echo '${'$as_ac_Header'}'`" >&5
2935 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
2936 if test `eval echo '${'$as_ac_Header'}'` = yes; then
2937   cat >>confdefs.h <<EOF
2938 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
2939 EOF
2940
2941 ac_header_dirent=$ac_hdr; break
2942 fi
2943
2944 done
2945 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
2946 if test $ac_header_dirent = dirent.h; then
2947   echo "$as_me:2947: checking for opendir in -ldir" >&5
2948 echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6
2949 if test "${ac_cv_lib_dir_opendir+set}" = set; then
2950   echo $ECHO_N "(cached) $ECHO_C" >&6
2951 else
2952   ac_check_lib_save_LIBS=$LIBS
2953 LIBS="-ldir  $LIBS"
2954 cat >conftest.$ac_ext <<_ACEOF
2955 #line 2955 "configure"
2956 #include "confdefs.h"
2957
2958 /* Override any gcc2 internal prototype to avoid an error.  */
2959 #ifdef __cplusplus
2960 extern "C"
2961 #endif
2962 /* We use char because int might match the return type of a gcc2
2963    builtin and then its argument prototype would still apply.  */
2964 char opendir ();
2965 int
2966 main ()
2967 {
2968 opendir ();
2969   ;
2970   return 0;
2971 }
2972 _ACEOF
2973 rm -f conftest.$ac_objext conftest$ac_exeext
2974 if { (eval echo "$as_me:2974: \"$ac_link\"") >&5
2975   (eval $ac_link) 2>&5
2976   ac_status=$?
2977   echo "$as_me:2977: \$? = $ac_status" >&5
2978   (exit $ac_status); } &&
2979          { ac_try='test -s conftest$ac_exeext'
2980   { (eval echo "$as_me:2980: \"$ac_try\"") >&5
2981   (eval $ac_try) 2>&5
2982   ac_status=$?
2983   echo "$as_me:2983: \$? = $ac_status" >&5
2984   (exit $ac_status); }; }; then
2985   ac_cv_lib_dir_opendir=yes
2986 else
2987   echo "$as_me: failed program was:" >&5
2988 cat conftest.$ac_ext >&5
2989 ac_cv_lib_dir_opendir=no
2990 fi
2991 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
2992 LIBS=$ac_check_lib_save_LIBS
2993 fi
2994 echo "$as_me:2994: result: $ac_cv_lib_dir_opendir" >&5
2995 echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6
2996 if test $ac_cv_lib_dir_opendir = yes; then
2997   LIBS="$LIBS -ldir"
2998 fi
2999
3000 else
3001   echo "$as_me:3001: checking for opendir in -lx" >&5
3002 echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6
3003 if test "${ac_cv_lib_x_opendir+set}" = set; then
3004   echo $ECHO_N "(cached) $ECHO_C" >&6
3005 else
3006   ac_check_lib_save_LIBS=$LIBS
3007 LIBS="-lx  $LIBS"
3008 cat >conftest.$ac_ext <<_ACEOF
3009 #line 3009 "configure"
3010 #include "confdefs.h"
3011
3012 /* Override any gcc2 internal prototype to avoid an error.  */
3013 #ifdef __cplusplus
3014 extern "C"
3015 #endif
3016 /* We use char because int might match the return type of a gcc2
3017    builtin and then its argument prototype would still apply.  */
3018 char opendir ();
3019 int
3020 main ()
3021 {
3022 opendir ();
3023   ;
3024   return 0;
3025 }
3026 _ACEOF
3027 rm -f conftest.$ac_objext conftest$ac_exeext
3028 if { (eval echo "$as_me:3028: \"$ac_link\"") >&5
3029   (eval $ac_link) 2>&5
3030   ac_status=$?
3031   echo "$as_me:3031: \$? = $ac_status" >&5
3032   (exit $ac_status); } &&
3033          { ac_try='test -s conftest$ac_exeext'
3034   { (eval echo "$as_me:3034: \"$ac_try\"") >&5
3035   (eval $ac_try) 2>&5
3036   ac_status=$?
3037   echo "$as_me:3037: \$? = $ac_status" >&5
3038   (exit $ac_status); }; }; then
3039   ac_cv_lib_x_opendir=yes
3040 else
3041   echo "$as_me: failed program was:" >&5
3042 cat conftest.$ac_ext >&5
3043 ac_cv_lib_x_opendir=no
3044 fi
3045 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3046 LIBS=$ac_check_lib_save_LIBS
3047 fi
3048 echo "$as_me:3048: result: $ac_cv_lib_x_opendir" >&5
3049 echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6
3050 if test $ac_cv_lib_x_opendir = yes; then
3051   LIBS="$LIBS -lx"
3052 fi
3053
3054 fi
3055
3056 echo "$as_me:3056: checking whether time.h and sys/time.h may both be included" >&5
3057 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
3058 if test "${ac_cv_header_time+set}" = set; then
3059   echo $ECHO_N "(cached) $ECHO_C" >&6
3060 else
3061   cat >conftest.$ac_ext <<_ACEOF
3062 #line 3062 "configure"
3063 #include "confdefs.h"
3064 #include <sys/types.h>
3065 #include <sys/time.h>
3066 #include <time.h>
3067
3068 int
3069 main ()
3070 {
3071 if ((struct tm *) 0)
3072 return 0;
3073   ;
3074   return 0;
3075 }
3076 _ACEOF
3077 rm -f conftest.$ac_objext
3078 if { (eval echo "$as_me:3078: \"$ac_compile\"") >&5
3079   (eval $ac_compile) 2>&5
3080   ac_status=$?
3081   echo "$as_me:3081: \$? = $ac_status" >&5
3082   (exit $ac_status); } &&
3083          { ac_try='test -s conftest.$ac_objext'
3084   { (eval echo "$as_me:3084: \"$ac_try\"") >&5
3085   (eval $ac_try) 2>&5
3086   ac_status=$?
3087   echo "$as_me:3087: \$? = $ac_status" >&5
3088   (exit $ac_status); }; }; then
3089   ac_cv_header_time=yes
3090 else
3091   echo "$as_me: failed program was:" >&5
3092 cat conftest.$ac_ext >&5
3093 ac_cv_header_time=no
3094 fi
3095 rm -f conftest.$ac_objext conftest.$ac_ext
3096 fi
3097 echo "$as_me:3097: result: $ac_cv_header_time" >&5
3098 echo "${ECHO_T}$ac_cv_header_time" >&6
3099 if test $ac_cv_header_time = yes; then
3100
3101 cat >>confdefs.h <<\EOF
3102 #define TIME_WITH_SYS_TIME 1
3103 EOF
3104
3105 fi
3106
3107 echo "$as_me:3107: checking for sys/wait.h that is POSIX.1 compatible" >&5
3108 echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
3109 if test "${ac_cv_header_sys_wait_h+set}" = set; then
3110   echo $ECHO_N "(cached) $ECHO_C" >&6
3111 else
3112   cat >conftest.$ac_ext <<_ACEOF
3113 #line 3113 "configure"
3114 #include "confdefs.h"
3115 #include <sys/types.h>
3116 #include <sys/wait.h>
3117 #ifndef WEXITSTATUS
3118 # define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
3119 #endif
3120 #ifndef WIFEXITED
3121 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
3122 #endif
3123
3124 int
3125 main ()
3126 {
3127   int s;
3128   wait (&s);
3129   s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
3130   ;
3131   return 0;
3132 }
3133 _ACEOF
3134 rm -f conftest.$ac_objext
3135 if { (eval echo "$as_me:3135: \"$ac_compile\"") >&5
3136   (eval $ac_compile) 2>&5
3137   ac_status=$?
3138   echo "$as_me:3138: \$? = $ac_status" >&5
3139   (exit $ac_status); } &&
3140          { ac_try='test -s conftest.$ac_objext'
3141   { (eval echo "$as_me:3141: \"$ac_try\"") >&5
3142   (eval $ac_try) 2>&5
3143   ac_status=$?
3144   echo "$as_me:3144: \$? = $ac_status" >&5
3145   (exit $ac_status); }; }; then
3146   ac_cv_header_sys_wait_h=yes
3147 else
3148   echo "$as_me: failed program was:" >&5
3149 cat conftest.$ac_ext >&5
3150 ac_cv_header_sys_wait_h=no
3151 fi
3152 rm -f conftest.$ac_objext conftest.$ac_ext
3153 fi
3154 echo "$as_me:3154: result: $ac_cv_header_sys_wait_h" >&5
3155 echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
3156 if test $ac_cv_header_sys_wait_h = yes; then
3157
3158 cat >>confdefs.h <<\EOF
3159 #define HAVE_SYS_WAIT_H 1
3160 EOF
3161
3162 fi
3163
3164 for ac_header in arpa/inet.h sys/fcntl.h sys/select.h fcntl.h sys/time.h sys/unistd.h
3165 do
3166 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3167 echo "$as_me:3167: checking for $ac_header" >&5
3168 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3169 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3170   echo $ECHO_N "(cached) $ECHO_C" >&6
3171 else
3172   cat >conftest.$ac_ext <<_ACEOF
3173 #line 3173 "configure"
3174 #include "confdefs.h"
3175 #include <$ac_header>
3176 _ACEOF
3177 if { (eval echo "$as_me:3177: \"$ac_cpp conftest.$ac_ext\"") >&5
3178   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3179   ac_status=$?
3180   egrep -v '^ *\+' conftest.er1 >conftest.err
3181   rm -f conftest.er1
3182   cat conftest.err >&5
3183   echo "$as_me:3183: \$? = $ac_status" >&5
3184   (exit $ac_status); } >/dev/null; then
3185   if test -s conftest.err; then
3186     ac_cpp_err=$ac_c_preproc_warn_flag
3187   else
3188     ac_cpp_err=
3189   fi
3190 else
3191   ac_cpp_err=yes
3192 fi
3193 if test -z "$ac_cpp_err"; then
3194   eval "$as_ac_Header=yes"
3195 else
3196   echo "$as_me: failed program was:" >&5
3197   cat conftest.$ac_ext >&5
3198   eval "$as_ac_Header=no"
3199 fi
3200 rm -f conftest.err conftest.$ac_ext
3201 fi
3202 echo "$as_me:3202: result: `eval echo '${'$as_ac_Header'}'`" >&5
3203 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3204 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3205   cat >>confdefs.h <<EOF
3206 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3207 EOF
3208
3209 fi
3210 done
3211
3212 for ac_header in unistd.h utime.h grp.h sys/id.h limits.h memory.h net/if.h
3213 do
3214 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3215 echo "$as_me:3215: checking for $ac_header" >&5
3216 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3217 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3218   echo $ECHO_N "(cached) $ECHO_C" >&6
3219 else
3220   cat >conftest.$ac_ext <<_ACEOF
3221 #line 3221 "configure"
3222 #include "confdefs.h"
3223 #include <$ac_header>
3224 _ACEOF
3225 if { (eval echo "$as_me:3225: \"$ac_cpp conftest.$ac_ext\"") >&5
3226   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3227   ac_status=$?
3228   egrep -v '^ *\+' conftest.er1 >conftest.err
3229   rm -f conftest.er1
3230   cat conftest.err >&5
3231   echo "$as_me:3231: \$? = $ac_status" >&5
3232   (exit $ac_status); } >/dev/null; then
3233   if test -s conftest.err; then
3234     ac_cpp_err=$ac_c_preproc_warn_flag
3235   else
3236     ac_cpp_err=
3237   fi
3238 else
3239   ac_cpp_err=yes
3240 fi
3241 if test -z "$ac_cpp_err"; then
3242   eval "$as_ac_Header=yes"
3243 else
3244   echo "$as_me: failed program was:" >&5
3245   cat conftest.$ac_ext >&5
3246   eval "$as_ac_Header=no"
3247 fi
3248 rm -f conftest.err conftest.$ac_ext
3249 fi
3250 echo "$as_me:3250: result: `eval echo '${'$as_ac_Header'}'`" >&5
3251 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3252 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3253   cat >>confdefs.h <<EOF
3254 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3255 EOF
3256
3257 fi
3258 done
3259
3260 for ac_header in compat.h rpc/rpc.h rpcsvc/nis.h rpcsvc/yp_prot.h rpcsvc/ypclnt.h
3261 do
3262 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3263 echo "$as_me:3263: checking for $ac_header" >&5
3264 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3265 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3266   echo $ECHO_N "(cached) $ECHO_C" >&6
3267 else
3268   cat >conftest.$ac_ext <<_ACEOF
3269 #line 3269 "configure"
3270 #include "confdefs.h"
3271 #include <$ac_header>
3272 _ACEOF
3273 if { (eval echo "$as_me:3273: \"$ac_cpp conftest.$ac_ext\"") >&5
3274   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3275   ac_status=$?
3276   egrep -v '^ *\+' conftest.er1 >conftest.err
3277   rm -f conftest.er1
3278   cat conftest.err >&5
3279   echo "$as_me:3279: \$? = $ac_status" >&5
3280   (exit $ac_status); } >/dev/null; then
3281   if test -s conftest.err; then
3282     ac_cpp_err=$ac_c_preproc_warn_flag
3283   else
3284     ac_cpp_err=
3285   fi
3286 else
3287   ac_cpp_err=yes
3288 fi
3289 if test -z "$ac_cpp_err"; then
3290   eval "$as_ac_Header=yes"
3291 else
3292   echo "$as_me: failed program was:" >&5
3293   cat conftest.$ac_ext >&5
3294   eval "$as_ac_Header=no"
3295 fi
3296 rm -f conftest.err conftest.$ac_ext
3297 fi
3298 echo "$as_me:3298: result: `eval echo '${'$as_ac_Header'}'`" >&5
3299 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3300 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3301   cat >>confdefs.h <<EOF
3302 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3303 EOF
3304
3305 fi
3306 done
3307
3308 for ac_header in sys/param.h ctype.h sys/wait.h sys/resource.h sys/ioctl.h sys/ipc.h sys/mode.h
3309 do
3310 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3311 echo "$as_me:3311: checking for $ac_header" >&5
3312 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3313 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3314   echo $ECHO_N "(cached) $ECHO_C" >&6
3315 else
3316   cat >conftest.$ac_ext <<_ACEOF
3317 #line 3317 "configure"
3318 #include "confdefs.h"
3319 #include <$ac_header>
3320 _ACEOF
3321 if { (eval echo "$as_me:3321: \"$ac_cpp conftest.$ac_ext\"") >&5
3322   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3323   ac_status=$?
3324   egrep -v '^ *\+' conftest.er1 >conftest.err
3325   rm -f conftest.er1
3326   cat conftest.err >&5
3327   echo "$as_me:3327: \$? = $ac_status" >&5
3328   (exit $ac_status); } >/dev/null; then
3329   if test -s conftest.err; then
3330     ac_cpp_err=$ac_c_preproc_warn_flag
3331   else
3332     ac_cpp_err=
3333   fi
3334 else
3335   ac_cpp_err=yes
3336 fi
3337 if test -z "$ac_cpp_err"; then
3338   eval "$as_ac_Header=yes"
3339 else
3340   echo "$as_me: failed program was:" >&5
3341   cat conftest.$ac_ext >&5
3342   eval "$as_ac_Header=no"
3343 fi
3344 rm -f conftest.err conftest.$ac_ext
3345 fi
3346 echo "$as_me:3346: result: `eval echo '${'$as_ac_Header'}'`" >&5
3347 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3348 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3349   cat >>confdefs.h <<EOF
3350 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3351 EOF
3352
3353 fi
3354 done
3355
3356 for ac_header in sys/mman.h sys/filio.h sys/priv.h sys/shm.h string.h strings.h stdlib.h sys/socket.h
3357 do
3358 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3359 echo "$as_me:3359: checking for $ac_header" >&5
3360 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3361 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3362   echo $ECHO_N "(cached) $ECHO_C" >&6
3363 else
3364   cat >conftest.$ac_ext <<_ACEOF
3365 #line 3365 "configure"
3366 #include "confdefs.h"
3367 #include <$ac_header>
3368 _ACEOF
3369 if { (eval echo "$as_me:3369: \"$ac_cpp conftest.$ac_ext\"") >&5
3370   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3371   ac_status=$?
3372   egrep -v '^ *\+' conftest.er1 >conftest.err
3373   rm -f conftest.er1
3374   cat conftest.err >&5
3375   echo "$as_me:3375: \$? = $ac_status" >&5
3376   (exit $ac_status); } >/dev/null; then
3377   if test -s conftest.err; then
3378     ac_cpp_err=$ac_c_preproc_warn_flag
3379   else
3380     ac_cpp_err=
3381   fi
3382 else
3383   ac_cpp_err=yes
3384 fi
3385 if test -z "$ac_cpp_err"; then
3386   eval "$as_ac_Header=yes"
3387 else
3388   echo "$as_me: failed program was:" >&5
3389   cat conftest.$ac_ext >&5
3390   eval "$as_ac_Header=no"
3391 fi
3392 rm -f conftest.err conftest.$ac_ext
3393 fi
3394 echo "$as_me:3394: result: `eval echo '${'$as_ac_Header'}'`" >&5
3395 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3396 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3397   cat >>confdefs.h <<EOF
3398 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3399 EOF
3400
3401 fi
3402 done
3403
3404 for ac_header in sys/mount.h sys/vfs.h sys/fs/s5param.h sys/filsys.h termios.h termio.h
3405 do
3406 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3407 echo "$as_me:3407: checking for $ac_header" >&5
3408 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3409 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3410   echo $ECHO_N "(cached) $ECHO_C" >&6
3411 else
3412   cat >conftest.$ac_ext <<_ACEOF
3413 #line 3413 "configure"
3414 #include "confdefs.h"
3415 #include <$ac_header>
3416 _ACEOF
3417 if { (eval echo "$as_me:3417: \"$ac_cpp conftest.$ac_ext\"") >&5
3418   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3419   ac_status=$?
3420   egrep -v '^ *\+' conftest.er1 >conftest.err
3421   rm -f conftest.er1
3422   cat conftest.err >&5
3423   echo "$as_me:3423: \$? = $ac_status" >&5
3424   (exit $ac_status); } >/dev/null; then
3425   if test -s conftest.err; then
3426     ac_cpp_err=$ac_c_preproc_warn_flag
3427   else
3428     ac_cpp_err=
3429   fi
3430 else
3431   ac_cpp_err=yes
3432 fi
3433 if test -z "$ac_cpp_err"; then
3434   eval "$as_ac_Header=yes"
3435 else
3436   echo "$as_me: failed program was:" >&5
3437   cat conftest.$ac_ext >&5
3438   eval "$as_ac_Header=no"
3439 fi
3440 rm -f conftest.err conftest.$ac_ext
3441 fi
3442 echo "$as_me:3442: result: `eval echo '${'$as_ac_Header'}'`" >&5
3443 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3444 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3445   cat >>confdefs.h <<EOF
3446 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3447 EOF
3448
3449 fi
3450 done
3451
3452 for ac_header in sys/termio.h sys/statfs.h sys/dustat.h sys/statvfs.h stdarg.h sys/sockio.h
3453 do
3454 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3455 echo "$as_me:3455: checking for $ac_header" >&5
3456 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3457 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3458   echo $ECHO_N "(cached) $ECHO_C" >&6
3459 else
3460   cat >conftest.$ac_ext <<_ACEOF
3461 #line 3461 "configure"
3462 #include "confdefs.h"
3463 #include <$ac_header>
3464 _ACEOF
3465 if { (eval echo "$as_me:3465: \"$ac_cpp conftest.$ac_ext\"") >&5
3466   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3467   ac_status=$?
3468   egrep -v '^ *\+' conftest.er1 >conftest.err
3469   rm -f conftest.er1
3470   cat conftest.err >&5
3471   echo "$as_me:3471: \$? = $ac_status" >&5
3472   (exit $ac_status); } >/dev/null; then
3473   if test -s conftest.err; then
3474     ac_cpp_err=$ac_c_preproc_warn_flag
3475   else
3476     ac_cpp_err=
3477   fi
3478 else
3479   ac_cpp_err=yes
3480 fi
3481 if test -z "$ac_cpp_err"; then
3482   eval "$as_ac_Header=yes"
3483 else
3484   echo "$as_me: failed program was:" >&5
3485   cat conftest.$ac_ext >&5
3486   eval "$as_ac_Header=no"
3487 fi
3488 rm -f conftest.err conftest.$ac_ext
3489 fi
3490 echo "$as_me:3490: result: `eval echo '${'$as_ac_Header'}'`" >&5
3491 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3492 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3493   cat >>confdefs.h <<EOF
3494 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3495 EOF
3496
3497 fi
3498 done
3499
3500 for ac_header in security/pam_modules.h security/_pam_macros.h ldap.h
3501 do
3502 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3503 echo "$as_me:3503: checking for $ac_header" >&5
3504 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3505 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3506   echo $ECHO_N "(cached) $ECHO_C" >&6
3507 else
3508   cat >conftest.$ac_ext <<_ACEOF
3509 #line 3509 "configure"
3510 #include "confdefs.h"
3511 #include <$ac_header>
3512 _ACEOF
3513 if { (eval echo "$as_me:3513: \"$ac_cpp conftest.$ac_ext\"") >&5
3514   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3515   ac_status=$?
3516   egrep -v '^ *\+' conftest.er1 >conftest.err
3517   rm -f conftest.er1
3518   cat conftest.err >&5
3519   echo "$as_me:3519: \$? = $ac_status" >&5
3520   (exit $ac_status); } >/dev/null; then
3521   if test -s conftest.err; then
3522     ac_cpp_err=$ac_c_preproc_warn_flag
3523   else
3524     ac_cpp_err=
3525   fi
3526 else
3527   ac_cpp_err=yes
3528 fi
3529 if test -z "$ac_cpp_err"; then
3530   eval "$as_ac_Header=yes"
3531 else
3532   echo "$as_me: failed program was:" >&5
3533   cat conftest.$ac_ext >&5
3534   eval "$as_ac_Header=no"
3535 fi
3536 rm -f conftest.err conftest.$ac_ext
3537 fi
3538 echo "$as_me:3538: result: `eval echo '${'$as_ac_Header'}'`" >&5
3539 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3540 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3541   cat >>confdefs.h <<EOF
3542 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3543 EOF
3544
3545 fi
3546 done
3547
3548 #
3549 # HPUX has a bug in that including shadow.h causes a re-definition of MAXINT.
3550 # This causes configure to fail to detect it. Check for shadow separately on HPUX.
3551 #
3552 case "$host_os" in
3553     *hpux*)
3554                 cat >conftest.$ac_ext <<_ACEOF
3555 #line 3555 "configure"
3556 #include "confdefs.h"
3557 #include <shadow.h>
3558 int
3559 main ()
3560 {
3561 struct spwd testme
3562   ;
3563   return 0;
3564 }
3565 _ACEOF
3566 rm -f conftest.$ac_objext
3567 if { (eval echo "$as_me:3567: \"$ac_compile\"") >&5
3568   (eval $ac_compile) 2>&5
3569   ac_status=$?
3570   echo "$as_me:3570: \$? = $ac_status" >&5
3571   (exit $ac_status); } &&
3572          { ac_try='test -s conftest.$ac_objext'
3573   { (eval echo "$as_me:3573: \"$ac_try\"") >&5
3574   (eval $ac_try) 2>&5
3575   ac_status=$?
3576   echo "$as_me:3576: \$? = $ac_status" >&5
3577   (exit $ac_status); }; }; then
3578   ac_cv_header_shadow_h=yes
3579 else
3580   echo "$as_me: failed program was:" >&5
3581 cat conftest.$ac_ext >&5
3582 ac_cv_header_shadow_h=no
3583 fi
3584 rm -f conftest.$ac_objext conftest.$ac_ext
3585                 if test x"$ac_cv_header_shadow_h" = x"yes"; then
3586                    cat >>confdefs.h <<\EOF
3587 #define HAVE_SHADOW_H 1
3588 EOF
3589
3590                 fi
3591         ;;
3592 esac
3593
3594 for ac_header in shadow.h netinet/ip.h netinet/tcp.h netinet/in_systm.h netinet/in_ip.h
3595 do
3596 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3597 echo "$as_me:3597: checking for $ac_header" >&5
3598 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3599 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3600   echo $ECHO_N "(cached) $ECHO_C" >&6
3601 else
3602   cat >conftest.$ac_ext <<_ACEOF
3603 #line 3603 "configure"
3604 #include "confdefs.h"
3605 #include <$ac_header>
3606 _ACEOF
3607 if { (eval echo "$as_me:3607: \"$ac_cpp conftest.$ac_ext\"") >&5
3608   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3609   ac_status=$?
3610   egrep -v '^ *\+' conftest.er1 >conftest.err
3611   rm -f conftest.er1
3612   cat conftest.err >&5
3613   echo "$as_me:3613: \$? = $ac_status" >&5
3614   (exit $ac_status); } >/dev/null; then
3615   if test -s conftest.err; then
3616     ac_cpp_err=$ac_c_preproc_warn_flag
3617   else
3618     ac_cpp_err=
3619   fi
3620 else
3621   ac_cpp_err=yes
3622 fi
3623 if test -z "$ac_cpp_err"; then
3624   eval "$as_ac_Header=yes"
3625 else
3626   echo "$as_me: failed program was:" >&5
3627   cat conftest.$ac_ext >&5
3628   eval "$as_ac_Header=no"
3629 fi
3630 rm -f conftest.err conftest.$ac_ext
3631 fi
3632 echo "$as_me:3632: result: `eval echo '${'$as_ac_Header'}'`" >&5
3633 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3634 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3635   cat >>confdefs.h <<EOF
3636 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3637 EOF
3638
3639 fi
3640 done
3641
3642 for ac_header in nss.h nss_common.h ns_api.h sys/security.h security/pam_appl.h security/pam_modules.h
3643 do
3644 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3645 echo "$as_me:3645: checking for $ac_header" >&5
3646 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3647 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3648   echo $ECHO_N "(cached) $ECHO_C" >&6
3649 else
3650   cat >conftest.$ac_ext <<_ACEOF
3651 #line 3651 "configure"
3652 #include "confdefs.h"
3653 #include <$ac_header>
3654 _ACEOF
3655 if { (eval echo "$as_me:3655: \"$ac_cpp conftest.$ac_ext\"") >&5
3656   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3657   ac_status=$?
3658   egrep -v '^ *\+' conftest.er1 >conftest.err
3659   rm -f conftest.er1
3660   cat conftest.err >&5
3661   echo "$as_me:3661: \$? = $ac_status" >&5
3662   (exit $ac_status); } >/dev/null; then
3663   if test -s conftest.err; then
3664     ac_cpp_err=$ac_c_preproc_warn_flag
3665   else
3666     ac_cpp_err=
3667   fi
3668 else
3669   ac_cpp_err=yes
3670 fi
3671 if test -z "$ac_cpp_err"; then
3672   eval "$as_ac_Header=yes"
3673 else
3674   echo "$as_me: failed program was:" >&5
3675   cat conftest.$ac_ext >&5
3676   eval "$as_ac_Header=no"
3677 fi
3678 rm -f conftest.err conftest.$ac_ext
3679 fi
3680 echo "$as_me:3680: result: `eval echo '${'$as_ac_Header'}'`" >&5
3681 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3682 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3683   cat >>confdefs.h <<EOF
3684 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3685 EOF
3686
3687 fi
3688 done
3689
3690 for ac_header in stropts.h poll.h
3691 do
3692 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3693 echo "$as_me:3693: checking for $ac_header" >&5
3694 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3695 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3696   echo $ECHO_N "(cached) $ECHO_C" >&6
3697 else
3698   cat >conftest.$ac_ext <<_ACEOF
3699 #line 3699 "configure"
3700 #include "confdefs.h"
3701 #include <$ac_header>
3702 _ACEOF
3703 if { (eval echo "$as_me:3703: \"$ac_cpp conftest.$ac_ext\"") >&5
3704   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3705   ac_status=$?
3706   egrep -v '^ *\+' conftest.er1 >conftest.err
3707   rm -f conftest.er1
3708   cat conftest.err >&5
3709   echo "$as_me:3709: \$? = $ac_status" >&5
3710   (exit $ac_status); } >/dev/null; then
3711   if test -s conftest.err; then
3712     ac_cpp_err=$ac_c_preproc_warn_flag
3713   else
3714     ac_cpp_err=
3715   fi
3716 else
3717   ac_cpp_err=yes
3718 fi
3719 if test -z "$ac_cpp_err"; then
3720   eval "$as_ac_Header=yes"
3721 else
3722   echo "$as_me: failed program was:" >&5
3723   cat conftest.$ac_ext >&5
3724   eval "$as_ac_Header=no"
3725 fi
3726 rm -f conftest.err conftest.$ac_ext
3727 fi
3728 echo "$as_me:3728: result: `eval echo '${'$as_ac_Header'}'`" >&5
3729 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3730 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3731   cat >>confdefs.h <<EOF
3732 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3733 EOF
3734
3735 fi
3736 done
3737
3738 for ac_header in sys/capability.h syscall.h sys/syscall.h
3739 do
3740 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3741 echo "$as_me:3741: checking for $ac_header" >&5
3742 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3743 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3744   echo $ECHO_N "(cached) $ECHO_C" >&6
3745 else
3746   cat >conftest.$ac_ext <<_ACEOF
3747 #line 3747 "configure"
3748 #include "confdefs.h"
3749 #include <$ac_header>
3750 _ACEOF
3751 if { (eval echo "$as_me:3751: \"$ac_cpp conftest.$ac_ext\"") >&5
3752   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3753   ac_status=$?
3754   egrep -v '^ *\+' conftest.er1 >conftest.err
3755   rm -f conftest.er1
3756   cat conftest.err >&5
3757   echo "$as_me:3757: \$? = $ac_status" >&5
3758   (exit $ac_status); } >/dev/null; then
3759   if test -s conftest.err; then
3760     ac_cpp_err=$ac_c_preproc_warn_flag
3761   else
3762     ac_cpp_err=
3763   fi
3764 else
3765   ac_cpp_err=yes
3766 fi
3767 if test -z "$ac_cpp_err"; then
3768   eval "$as_ac_Header=yes"
3769 else
3770   echo "$as_me: failed program was:" >&5
3771   cat conftest.$ac_ext >&5
3772   eval "$as_ac_Header=no"
3773 fi
3774 rm -f conftest.err conftest.$ac_ext
3775 fi
3776 echo "$as_me:3776: result: `eval echo '${'$as_ac_Header'}'`" >&5
3777 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3778 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3779   cat >>confdefs.h <<EOF
3780 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3781 EOF
3782
3783 fi
3784 done
3785
3786 for ac_header in sys/acl.h sys/cdefs.h glob.h
3787 do
3788 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3789 echo "$as_me:3789: checking for $ac_header" >&5
3790 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3791 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3792   echo $ECHO_N "(cached) $ECHO_C" >&6
3793 else
3794   cat >conftest.$ac_ext <<_ACEOF
3795 #line 3795 "configure"
3796 #include "confdefs.h"
3797 #include <$ac_header>
3798 _ACEOF
3799 if { (eval echo "$as_me:3799: \"$ac_cpp conftest.$ac_ext\"") >&5
3800   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3801   ac_status=$?
3802   egrep -v '^ *\+' conftest.er1 >conftest.err
3803   rm -f conftest.er1
3804   cat conftest.err >&5
3805   echo "$as_me:3805: \$? = $ac_status" >&5
3806   (exit $ac_status); } >/dev/null; then
3807   if test -s conftest.err; then
3808     ac_cpp_err=$ac_c_preproc_warn_flag
3809   else
3810     ac_cpp_err=
3811   fi
3812 else
3813   ac_cpp_err=yes
3814 fi
3815 if test -z "$ac_cpp_err"; then
3816   eval "$as_ac_Header=yes"
3817 else
3818   echo "$as_me: failed program was:" >&5
3819   cat conftest.$ac_ext >&5
3820   eval "$as_ac_Header=no"
3821 fi
3822 rm -f conftest.err conftest.$ac_ext
3823 fi
3824 echo "$as_me:3824: result: `eval echo '${'$as_ac_Header'}'`" >&5
3825 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3826 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3827   cat >>confdefs.h <<EOF
3828 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3829 EOF
3830
3831 fi
3832 done
3833
3834 # For experimental utmp support (lastlog on some BSD-like systems)
3835
3836 for ac_header in utmp.h utmpx.h lastlog.h
3837 do
3838 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3839 echo "$as_me:3839: checking for $ac_header" >&5
3840 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3841 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3842   echo $ECHO_N "(cached) $ECHO_C" >&6
3843 else
3844   cat >conftest.$ac_ext <<_ACEOF
3845 #line 3845 "configure"
3846 #include "confdefs.h"
3847 #include <$ac_header>
3848 _ACEOF
3849 if { (eval echo "$as_me:3849: \"$ac_cpp conftest.$ac_ext\"") >&5
3850   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3851   ac_status=$?
3852   egrep -v '^ *\+' conftest.er1 >conftest.err
3853   rm -f conftest.er1
3854   cat conftest.err >&5
3855   echo "$as_me:3855: \$? = $ac_status" >&5
3856   (exit $ac_status); } >/dev/null; then
3857   if test -s conftest.err; then
3858     ac_cpp_err=$ac_c_preproc_warn_flag
3859   else
3860     ac_cpp_err=
3861   fi
3862 else
3863   ac_cpp_err=yes
3864 fi
3865 if test -z "$ac_cpp_err"; then
3866   eval "$as_ac_Header=yes"
3867 else
3868   echo "$as_me: failed program was:" >&5
3869   cat conftest.$ac_ext >&5
3870   eval "$as_ac_Header=no"
3871 fi
3872 rm -f conftest.err conftest.$ac_ext
3873 fi
3874 echo "$as_me:3874: result: `eval echo '${'$as_ac_Header'}'`" >&5
3875 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3876 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3877   cat >>confdefs.h <<EOF
3878 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3879 EOF
3880
3881 fi
3882 done
3883
3884 # For quotas on Veritas VxFS filesystems
3885
3886 for ac_header in sys/fs/vx_quota.h
3887 do
3888 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3889 echo "$as_me:3889: checking for $ac_header" >&5
3890 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3891 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3892   echo $ECHO_N "(cached) $ECHO_C" >&6
3893 else
3894   cat >conftest.$ac_ext <<_ACEOF
3895 #line 3895 "configure"
3896 #include "confdefs.h"
3897 #include <$ac_header>
3898 _ACEOF
3899 if { (eval echo "$as_me:3899: \"$ac_cpp conftest.$ac_ext\"") >&5
3900   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3901   ac_status=$?
3902   egrep -v '^ *\+' conftest.er1 >conftest.err
3903   rm -f conftest.er1
3904   cat conftest.err >&5
3905   echo "$as_me:3905: \$? = $ac_status" >&5
3906   (exit $ac_status); } >/dev/null; then
3907   if test -s conftest.err; then
3908     ac_cpp_err=$ac_c_preproc_warn_flag
3909   else
3910     ac_cpp_err=
3911   fi
3912 else
3913   ac_cpp_err=yes
3914 fi
3915 if test -z "$ac_cpp_err"; then
3916   eval "$as_ac_Header=yes"
3917 else
3918   echo "$as_me: failed program was:" >&5
3919   cat conftest.$ac_ext >&5
3920   eval "$as_ac_Header=no"
3921 fi
3922 rm -f conftest.err conftest.$ac_ext
3923 fi
3924 echo "$as_me:3924: result: `eval echo '${'$as_ac_Header'}'`" >&5
3925 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3926 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3927   cat >>confdefs.h <<EOF
3928 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3929 EOF
3930
3931 fi
3932 done
3933
3934 # For quotas on Linux XFS filesystems
3935
3936 for ac_header in linux/xqm.h
3937 do
3938 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3939 echo "$as_me:3939: checking for $ac_header" >&5
3940 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3941 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3942   echo $ECHO_N "(cached) $ECHO_C" >&6
3943 else
3944   cat >conftest.$ac_ext <<_ACEOF
3945 #line 3945 "configure"
3946 #include "confdefs.h"
3947 #include <$ac_header>
3948 _ACEOF
3949 if { (eval echo "$as_me:3949: \"$ac_cpp conftest.$ac_ext\"") >&5
3950   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3951   ac_status=$?
3952   egrep -v '^ *\+' conftest.er1 >conftest.err
3953   rm -f conftest.er1
3954   cat conftest.err >&5
3955   echo "$as_me:3955: \$? = $ac_status" >&5
3956   (exit $ac_status); } >/dev/null; then
3957   if test -s conftest.err; then
3958     ac_cpp_err=$ac_c_preproc_warn_flag
3959   else
3960     ac_cpp_err=
3961   fi
3962 else
3963   ac_cpp_err=yes
3964 fi
3965 if test -z "$ac_cpp_err"; then
3966   eval "$as_ac_Header=yes"
3967 else
3968   echo "$as_me: failed program was:" >&5
3969   cat conftest.$ac_ext >&5
3970   eval "$as_ac_Header=no"
3971 fi
3972 rm -f conftest.err conftest.$ac_ext
3973 fi
3974 echo "$as_me:3974: result: `eval echo '${'$as_ac_Header'}'`" >&5
3975 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3976 if test `eval echo '${'$as_ac_Header'}'` = yes; then
3977   cat >>confdefs.h <<EOF
3978 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3979 EOF
3980
3981 fi
3982 done
3983
3984 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
3985
3986 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
3987                   inttypes.h stdint.h unistd.h
3988 do
3989 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3990 echo "$as_me:3990: checking for $ac_header" >&5
3991 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3992 if eval "test \"\${$as_ac_Header+set}\" = set"; then
3993   echo $ECHO_N "(cached) $ECHO_C" >&6
3994 else
3995   cat >conftest.$ac_ext <<_ACEOF
3996 #line 3996 "configure"
3997 #include "confdefs.h"
3998 $ac_includes_default
3999 #include <$ac_header>
4000 _ACEOF
4001 rm -f conftest.$ac_objext
4002 if { (eval echo "$as_me:4002: \"$ac_compile\"") >&5
4003   (eval $ac_compile) 2>&5
4004   ac_status=$?
4005   echo "$as_me:4005: \$? = $ac_status" >&5
4006   (exit $ac_status); } &&
4007          { ac_try='test -s conftest.$ac_objext'
4008   { (eval echo "$as_me:4008: \"$ac_try\"") >&5
4009   (eval $ac_try) 2>&5
4010   ac_status=$?
4011   echo "$as_me:4011: \$? = $ac_status" >&5
4012   (exit $ac_status); }; }; then
4013   eval "$as_ac_Header=yes"
4014 else
4015   echo "$as_me: failed program was:" >&5
4016 cat conftest.$ac_ext >&5
4017 eval "$as_ac_Header=no"
4018 fi
4019 rm -f conftest.$ac_objext conftest.$ac_ext
4020 fi
4021 echo "$as_me:4021: result: `eval echo '${'$as_ac_Header'}'`" >&5
4022 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4023 if test `eval echo '${'$as_ac_Header'}'` = yes; then
4024   cat >>confdefs.h <<EOF
4025 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4026 EOF
4027
4028 fi
4029 done
4030
4031 echo "$as_me:4031: checking for int" >&5
4032 echo $ECHO_N "checking for int... $ECHO_C" >&6
4033 if test "${ac_cv_type_int+set}" = set; then
4034   echo $ECHO_N "(cached) $ECHO_C" >&6
4035 else
4036   cat >conftest.$ac_ext <<_ACEOF
4037 #line 4037 "configure"
4038 #include "confdefs.h"
4039 $ac_includes_default
4040 int
4041 main ()
4042 {
4043 if ((int *) 0)
4044   return 0;
4045 if (sizeof (int))
4046   return 0;
4047   ;
4048   return 0;
4049 }
4050 _ACEOF
4051 rm -f conftest.$ac_objext
4052 if { (eval echo "$as_me:4052: \"$ac_compile\"") >&5
4053   (eval $ac_compile) 2>&5
4054   ac_status=$?
4055   echo "$as_me:4055: \$? = $ac_status" >&5
4056   (exit $ac_status); } &&
4057          { ac_try='test -s conftest.$ac_objext'
4058   { (eval echo "$as_me:4058: \"$ac_try\"") >&5
4059   (eval $ac_try) 2>&5
4060   ac_status=$?
4061   echo "$as_me:4061: \$? = $ac_status" >&5
4062   (exit $ac_status); }; }; then
4063   ac_cv_type_int=yes
4064 else
4065   echo "$as_me: failed program was:" >&5
4066 cat conftest.$ac_ext >&5
4067 ac_cv_type_int=no
4068 fi
4069 rm -f conftest.$ac_objext conftest.$ac_ext
4070 fi
4071 echo "$as_me:4071: result: $ac_cv_type_int" >&5
4072 echo "${ECHO_T}$ac_cv_type_int" >&6
4073
4074 echo "$as_me:4074: checking size of int" >&5
4075 echo $ECHO_N "checking size of int... $ECHO_C" >&6
4076 if test "${ac_cv_sizeof_int+set}" = set; then
4077   echo $ECHO_N "(cached) $ECHO_C" >&6
4078 else
4079   if test "$ac_cv_type_int" = yes; then
4080   if test "$cross_compiling" = yes; then
4081   # Depending upon the size, compute the lo and hi bounds.
4082 cat >conftest.$ac_ext <<_ACEOF
4083 #line 4083 "configure"
4084 #include "confdefs.h"
4085 $ac_includes_default
4086 int
4087 main ()
4088 {
4089 int _array_ [1 - 2 * !((sizeof (int)) >= 0)]
4090   ;
4091   return 0;
4092 }
4093 _ACEOF
4094 rm -f conftest.$ac_objext
4095 if { (eval echo "$as_me:4095: \"$ac_compile\"") >&5
4096   (eval $ac_compile) 2>&5
4097   ac_status=$?
4098   echo "$as_me:4098: \$? = $ac_status" >&5
4099   (exit $ac_status); } &&
4100          { ac_try='test -s conftest.$ac_objext'
4101   { (eval echo "$as_me:4101: \"$ac_try\"") >&5
4102   (eval $ac_try) 2>&5
4103   ac_status=$?
4104   echo "$as_me:4104: \$? = $ac_status" >&5
4105   (exit $ac_status); }; }; then
4106   ac_lo=0 ac_mid=0
4107   while :; do
4108     cat >conftest.$ac_ext <<_ACEOF
4109 #line 4109 "configure"
4110 #include "confdefs.h"
4111 $ac_includes_default
4112 int
4113 main ()
4114 {
4115 int _array_ [1 - 2 * !((sizeof (int)) <= $ac_mid)]
4116   ;
4117   return 0;
4118 }
4119 _ACEOF
4120 rm -f conftest.$ac_objext
4121 if { (eval echo "$as_me:4121: \"$ac_compile\"") >&5
4122   (eval $ac_compile) 2>&5
4123   ac_status=$?
4124   echo "$as_me:4124: \$? = $ac_status" >&5
4125   (exit $ac_status); } &&
4126          { ac_try='test -s conftest.$ac_objext'
4127   { (eval echo "$as_me:4127: \"$ac_try\"") >&5
4128   (eval $ac_try) 2>&5
4129   ac_status=$?
4130   echo "$as_me:4130: \$? = $ac_status" >&5
4131   (exit $ac_status); }; }; then
4132   ac_hi=$ac_mid; break
4133 else
4134   echo "$as_me: failed program was:" >&5
4135 cat conftest.$ac_ext >&5
4136 ac_lo=`expr $ac_mid + 1`; ac_mid=`expr 2 '*' $ac_mid + 1`
4137 fi
4138 rm -f conftest.$ac_objext conftest.$ac_ext
4139   done
4140 else
4141   echo "$as_me: failed program was:" >&5
4142 cat conftest.$ac_ext >&5
4143 ac_hi=-1 ac_mid=-1
4144   while :; do
4145     cat >conftest.$ac_ext <<_ACEOF
4146 #line 4146 "configure"
4147 #include "confdefs.h"
4148 $ac_includes_default
4149 int
4150 main ()
4151 {
4152 int _array_ [1 - 2 * !((sizeof (int)) >= $ac_mid)]
4153   ;
4154   return 0;
4155 }
4156 _ACEOF
4157 rm -f conftest.$ac_objext
4158 if { (eval echo "$as_me:4158: \"$ac_compile\"") >&5
4159   (eval $ac_compile) 2>&5
4160   ac_status=$?
4161   echo "$as_me:4161: \$? = $ac_status" >&5
4162   (exit $ac_status); } &&
4163          { ac_try='test -s conftest.$ac_objext'
4164   { (eval echo "$as_me:4164: \"$ac_try\"") >&5
4165   (eval $ac_try) 2>&5
4166   ac_status=$?
4167   echo "$as_me:4167: \$? = $ac_status" >&5
4168   (exit $ac_status); }; }; then
4169   ac_lo=$ac_mid; break
4170 else
4171   echo "$as_me: failed program was:" >&5
4172 cat conftest.$ac_ext >&5
4173 ac_hi=`expr $ac_mid - 1`; ac_mid=`expr 2 '*' $ac_mid`
4174 fi
4175 rm -f conftest.$ac_objext conftest.$ac_ext
4176   done
4177 fi
4178 rm -f conftest.$ac_objext conftest.$ac_ext
4179 # Binary search between lo and hi bounds.
4180 while test "x$ac_lo" != "x$ac_hi"; do
4181   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
4182   cat >conftest.$ac_ext <<_ACEOF
4183 #line 4183 "configure"
4184 #include "confdefs.h"
4185 $ac_includes_default
4186 int
4187 main ()
4188 {
4189 int _array_ [1 - 2 * !((sizeof (int)) <= $ac_mid)]
4190   ;
4191   return 0;
4192 }
4193 _ACEOF
4194 rm -f conftest.$ac_objext
4195 if { (eval echo "$as_me:4195: \"$ac_compile\"") >&5
4196   (eval $ac_compile) 2>&5
4197   ac_status=$?
4198   echo "$as_me:4198: \$? = $ac_status" >&5
4199   (exit $ac_status); } &&
4200          { ac_try='test -s conftest.$ac_objext'
4201   { (eval echo "$as_me:4201: \"$ac_try\"") >&5
4202   (eval $ac_try) 2>&5
4203   ac_status=$?
4204   echo "$as_me:4204: \$? = $ac_status" >&5
4205   (exit $ac_status); }; }; then
4206   ac_hi=$ac_mid
4207 else
4208   echo "$as_me: failed program was:" >&5
4209 cat conftest.$ac_ext >&5
4210 ac_lo=`expr $ac_mid + 1`
4211 fi
4212 rm -f conftest.$ac_objext conftest.$ac_ext
4213 done
4214 ac_cv_sizeof_int=$ac_lo
4215 else
4216   if test "$cross_compiling" = yes; then
4217   { { echo "$as_me:4217: error: cannot run test program while cross compiling" >&5
4218 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
4219    { (exit 1); exit 1; }; }
4220 else
4221   cat >conftest.$ac_ext <<_ACEOF
4222 #line 4222 "configure"
4223 #include "confdefs.h"
4224 $ac_includes_default
4225 int
4226 main ()
4227 {
4228 FILE *f = fopen ("conftest.val", "w");
4229 if (!f)
4230   exit (1);
4231 fprintf (f, "%d", (sizeof (int)));
4232 fclose (f);
4233   ;
4234   return 0;
4235 }
4236 _ACEOF
4237 rm -f conftest$ac_exeext
4238 if { (eval echo "$as_me:4238: \"$ac_link\"") >&5
4239   (eval $ac_link) 2>&5
4240   ac_status=$?
4241   echo "$as_me:4241: \$? = $ac_status" >&5
4242   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4243   { (eval echo "$as_me:4243: \"$ac_try\"") >&5
4244   (eval $ac_try) 2>&5
4245   ac_status=$?
4246   echo "$as_me:4246: \$? = $ac_status" >&5
4247   (exit $ac_status); }; }; then
4248   ac_cv_sizeof_int=`cat conftest.val`
4249 else
4250   echo "$as_me: program exited with status $ac_status" >&5
4251 echo "$as_me: failed program was:" >&5
4252 cat conftest.$ac_ext >&5
4253 fi
4254 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4255 fi
4256 fi
4257 rm -f conftest.val
4258 else
4259   ac_cv_sizeof_int=0
4260 fi
4261 fi
4262 echo "$as_me:4262: result: $ac_cv_sizeof_int" >&5
4263 echo "${ECHO_T}$ac_cv_sizeof_int" >&6
4264 cat >>confdefs.h <<EOF
4265 #define SIZEOF_INT $ac_cv_sizeof_int
4266 EOF
4267
4268 echo "$as_me:4268: checking for long" >&5
4269 echo $ECHO_N "checking for long... $ECHO_C" >&6
4270 if test "${ac_cv_type_long+set}" = set; then
4271   echo $ECHO_N "(cached) $ECHO_C" >&6
4272 else
4273   cat >conftest.$ac_ext <<_ACEOF
4274 #line 4274 "configure"
4275 #include "confdefs.h"
4276 $ac_includes_default
4277 int
4278 main ()
4279 {
4280 if ((long *) 0)
4281   return 0;
4282 if (sizeof (long))
4283   return 0;
4284   ;
4285   return 0;
4286 }
4287 _ACEOF
4288 rm -f conftest.$ac_objext
4289 if { (eval echo "$as_me:4289: \"$ac_compile\"") >&5
4290   (eval $ac_compile) 2>&5
4291   ac_status=$?
4292   echo "$as_me:4292: \$? = $ac_status" >&5
4293   (exit $ac_status); } &&
4294          { ac_try='test -s conftest.$ac_objext'
4295   { (eval echo "$as_me:4295: \"$ac_try\"") >&5
4296   (eval $ac_try) 2>&5
4297   ac_status=$?
4298   echo "$as_me:4298: \$? = $ac_status" >&5
4299   (exit $ac_status); }; }; then
4300   ac_cv_type_long=yes
4301 else
4302   echo "$as_me: failed program was:" >&5
4303 cat conftest.$ac_ext >&5
4304 ac_cv_type_long=no
4305 fi
4306 rm -f conftest.$ac_objext conftest.$ac_ext
4307 fi
4308 echo "$as_me:4308: result: $ac_cv_type_long" >&5
4309 echo "${ECHO_T}$ac_cv_type_long" >&6
4310
4311 echo "$as_me:4311: checking size of long" >&5
4312 echo $ECHO_N "checking size of long... $ECHO_C" >&6
4313 if test "${ac_cv_sizeof_long+set}" = set; then
4314   echo $ECHO_N "(cached) $ECHO_C" >&6
4315 else
4316   if test "$ac_cv_type_long" = yes; then
4317   if test "$cross_compiling" = yes; then
4318   # Depending upon the size, compute the lo and hi bounds.
4319 cat >conftest.$ac_ext <<_ACEOF
4320 #line 4320 "configure"
4321 #include "confdefs.h"
4322 $ac_includes_default
4323 int
4324 main ()
4325 {
4326 int _array_ [1 - 2 * !((sizeof (long)) >= 0)]
4327   ;
4328   return 0;
4329 }
4330 _ACEOF
4331 rm -f conftest.$ac_objext
4332 if { (eval echo "$as_me:4332: \"$ac_compile\"") >&5
4333   (eval $ac_compile) 2>&5
4334   ac_status=$?
4335   echo "$as_me:4335: \$? = $ac_status" >&5
4336   (exit $ac_status); } &&
4337          { ac_try='test -s conftest.$ac_objext'
4338   { (eval echo "$as_me:4338: \"$ac_try\"") >&5
4339   (eval $ac_try) 2>&5
4340   ac_status=$?
4341   echo "$as_me:4341: \$? = $ac_status" >&5
4342   (exit $ac_status); }; }; then
4343   ac_lo=0 ac_mid=0
4344   while :; do
4345     cat >conftest.$ac_ext <<_ACEOF
4346 #line 4346 "configure"
4347 #include "confdefs.h"
4348 $ac_includes_default
4349 int
4350 main ()
4351 {
4352 int _array_ [1 - 2 * !((sizeof (long)) <= $ac_mid)]
4353   ;
4354   return 0;
4355 }
4356 _ACEOF
4357 rm -f conftest.$ac_objext
4358 if { (eval echo "$as_me:4358: \"$ac_compile\"") >&5
4359   (eval $ac_compile) 2>&5
4360   ac_status=$?
4361   echo "$as_me:4361: \$? = $ac_status" >&5
4362   (exit $ac_status); } &&
4363          { ac_try='test -s conftest.$ac_objext'
4364   { (eval echo "$as_me:4364: \"$ac_try\"") >&5
4365   (eval $ac_try) 2>&5
4366   ac_status=$?
4367   echo "$as_me:4367: \$? = $ac_status" >&5
4368   (exit $ac_status); }; }; then
4369   ac_hi=$ac_mid; break
4370 else
4371   echo "$as_me: failed program was:" >&5
4372 cat conftest.$ac_ext >&5
4373 ac_lo=`expr $ac_mid + 1`; ac_mid=`expr 2 '*' $ac_mid + 1`
4374 fi
4375 rm -f conftest.$ac_objext conftest.$ac_ext
4376   done
4377 else
4378   echo "$as_me: failed program was:" >&5
4379 cat conftest.$ac_ext >&5
4380 ac_hi=-1 ac_mid=-1
4381   while :; do
4382     cat >conftest.$ac_ext <<_ACEOF
4383 #line 4383 "configure"
4384 #include "confdefs.h"
4385 $ac_includes_default
4386 int
4387 main ()
4388 {
4389 int _array_ [1 - 2 * !((sizeof (long)) >= $ac_mid)]
4390   ;
4391   return 0;
4392 }
4393 _ACEOF
4394 rm -f conftest.$ac_objext
4395 if { (eval echo "$as_me:4395: \"$ac_compile\"") >&5
4396   (eval $ac_compile) 2>&5
4397   ac_status=$?
4398   echo "$as_me:4398: \$? = $ac_status" >&5
4399   (exit $ac_status); } &&
4400          { ac_try='test -s conftest.$ac_objext'
4401   { (eval echo "$as_me:4401: \"$ac_try\"") >&5
4402   (eval $ac_try) 2>&5
4403   ac_status=$?
4404   echo "$as_me:4404: \$? = $ac_status" >&5
4405   (exit $ac_status); }; }; then
4406   ac_lo=$ac_mid; break
4407 else
4408   echo "$as_me: failed program was:" >&5
4409 cat conftest.$ac_ext >&5
4410 ac_hi=`expr $ac_mid - 1`; ac_mid=`expr 2 '*' $ac_mid`
4411 fi
4412 rm -f conftest.$ac_objext conftest.$ac_ext
4413   done
4414 fi
4415 rm -f conftest.$ac_objext conftest.$ac_ext
4416 # Binary search between lo and hi bounds.
4417 while test "x$ac_lo" != "x$ac_hi"; do
4418   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
4419   cat >conftest.$ac_ext <<_ACEOF
4420 #line 4420 "configure"
4421 #include "confdefs.h"
4422 $ac_includes_default
4423 int
4424 main ()
4425 {
4426 int _array_ [1 - 2 * !((sizeof (long)) <= $ac_mid)]
4427   ;
4428   return 0;
4429 }
4430 _ACEOF
4431 rm -f conftest.$ac_objext
4432 if { (eval echo "$as_me:4432: \"$ac_compile\"") >&5
4433   (eval $ac_compile) 2>&5
4434   ac_status=$?
4435   echo "$as_me:4435: \$? = $ac_status" >&5
4436   (exit $ac_status); } &&
4437          { ac_try='test -s conftest.$ac_objext'
4438   { (eval echo "$as_me:4438: \"$ac_try\"") >&5
4439   (eval $ac_try) 2>&5
4440   ac_status=$?
4441   echo "$as_me:4441: \$? = $ac_status" >&5
4442   (exit $ac_status); }; }; then
4443   ac_hi=$ac_mid
4444 else
4445   echo "$as_me: failed program was:" >&5
4446 cat conftest.$ac_ext >&5
4447 ac_lo=`expr $ac_mid + 1`
4448 fi
4449 rm -f conftest.$ac_objext conftest.$ac_ext
4450 done
4451 ac_cv_sizeof_long=$ac_lo
4452 else
4453   if test "$cross_compiling" = yes; then
4454   { { echo "$as_me:4454: error: cannot run test program while cross compiling" >&5
4455 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
4456    { (exit 1); exit 1; }; }
4457 else
4458   cat >conftest.$ac_ext <<_ACEOF
4459 #line 4459 "configure"
4460 #include "confdefs.h"
4461 $ac_includes_default
4462 int
4463 main ()
4464 {
4465 FILE *f = fopen ("conftest.val", "w");
4466 if (!f)
4467   exit (1);
4468 fprintf (f, "%d", (sizeof (long)));
4469 fclose (f);
4470   ;
4471   return 0;
4472 }
4473 _ACEOF
4474 rm -f conftest$ac_exeext
4475 if { (eval echo "$as_me:4475: \"$ac_link\"") >&5
4476   (eval $ac_link) 2>&5
4477   ac_status=$?
4478   echo "$as_me:4478: \$? = $ac_status" >&5
4479   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4480   { (eval echo "$as_me:4480: \"$ac_try\"") >&5
4481   (eval $ac_try) 2>&5
4482   ac_status=$?
4483   echo "$as_me:4483: \$? = $ac_status" >&5
4484   (exit $ac_status); }; }; then
4485   ac_cv_sizeof_long=`cat conftest.val`
4486 else
4487   echo "$as_me: program exited with status $ac_status" >&5
4488 echo "$as_me: failed program was:" >&5
4489 cat conftest.$ac_ext >&5
4490 fi
4491 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4492 fi
4493 fi
4494 rm -f conftest.val
4495 else
4496   ac_cv_sizeof_long=0
4497 fi
4498 fi
4499 echo "$as_me:4499: result: $ac_cv_sizeof_long" >&5
4500 echo "${ECHO_T}$ac_cv_sizeof_long" >&6
4501 cat >>confdefs.h <<EOF
4502 #define SIZEOF_LONG $ac_cv_sizeof_long
4503 EOF
4504
4505 echo "$as_me:4505: checking for short" >&5
4506 echo $ECHO_N "checking for short... $ECHO_C" >&6
4507 if test "${ac_cv_type_short+set}" = set; then
4508   echo $ECHO_N "(cached) $ECHO_C" >&6
4509 else
4510   cat >conftest.$ac_ext <<_ACEOF
4511 #line 4511 "configure"
4512 #include "confdefs.h"
4513 $ac_includes_default
4514 int
4515 main ()
4516 {
4517 if ((short *) 0)
4518   return 0;
4519 if (sizeof (short))
4520   return 0;
4521   ;
4522   return 0;
4523 }
4524 _ACEOF
4525 rm -f conftest.$ac_objext
4526 if { (eval echo "$as_me:4526: \"$ac_compile\"") >&5
4527   (eval $ac_compile) 2>&5
4528   ac_status=$?
4529   echo "$as_me:4529: \$? = $ac_status" >&5
4530   (exit $ac_status); } &&
4531          { ac_try='test -s conftest.$ac_objext'
4532   { (eval echo "$as_me:4532: \"$ac_try\"") >&5
4533   (eval $ac_try) 2>&5
4534   ac_status=$?
4535   echo "$as_me:4535: \$? = $ac_status" >&5
4536   (exit $ac_status); }; }; then
4537   ac_cv_type_short=yes
4538 else
4539   echo "$as_me: failed program was:" >&5
4540 cat conftest.$ac_ext >&5
4541 ac_cv_type_short=no
4542 fi
4543 rm -f conftest.$ac_objext conftest.$ac_ext
4544 fi
4545 echo "$as_me:4545: result: $ac_cv_type_short" >&5
4546 echo "${ECHO_T}$ac_cv_type_short" >&6
4547
4548 echo "$as_me:4548: checking size of short" >&5
4549 echo $ECHO_N "checking size of short... $ECHO_C" >&6
4550 if test "${ac_cv_sizeof_short+set}" = set; then
4551   echo $ECHO_N "(cached) $ECHO_C" >&6
4552 else
4553   if test "$ac_cv_type_short" = yes; then
4554   if test "$cross_compiling" = yes; then
4555   # Depending upon the size, compute the lo and hi bounds.
4556 cat >conftest.$ac_ext <<_ACEOF
4557 #line 4557 "configure"
4558 #include "confdefs.h"
4559 $ac_includes_default
4560 int
4561 main ()
4562 {
4563 int _array_ [1 - 2 * !((sizeof (short)) >= 0)]
4564   ;
4565   return 0;
4566 }
4567 _ACEOF
4568 rm -f conftest.$ac_objext
4569 if { (eval echo "$as_me:4569: \"$ac_compile\"") >&5
4570   (eval $ac_compile) 2>&5
4571   ac_status=$?
4572   echo "$as_me:4572: \$? = $ac_status" >&5
4573   (exit $ac_status); } &&
4574          { ac_try='test -s conftest.$ac_objext'
4575   { (eval echo "$as_me:4575: \"$ac_try\"") >&5
4576   (eval $ac_try) 2>&5
4577   ac_status=$?
4578   echo "$as_me:4578: \$? = $ac_status" >&5
4579   (exit $ac_status); }; }; then
4580   ac_lo=0 ac_mid=0
4581   while :; do
4582     cat >conftest.$ac_ext <<_ACEOF
4583 #line 4583 "configure"
4584 #include "confdefs.h"
4585 $ac_includes_default
4586 int
4587 main ()
4588 {
4589 int _array_ [1 - 2 * !((sizeof (short)) <= $ac_mid)]
4590   ;
4591   return 0;
4592 }
4593 _ACEOF
4594 rm -f conftest.$ac_objext
4595 if { (eval echo "$as_me:4595: \"$ac_compile\"") >&5
4596   (eval $ac_compile) 2>&5
4597   ac_status=$?
4598   echo "$as_me:4598: \$? = $ac_status" >&5
4599   (exit $ac_status); } &&
4600          { ac_try='test -s conftest.$ac_objext'
4601   { (eval echo "$as_me:4601: \"$ac_try\"") >&5
4602   (eval $ac_try) 2>&5
4603   ac_status=$?
4604   echo "$as_me:4604: \$? = $ac_status" >&5
4605   (exit $ac_status); }; }; then
4606   ac_hi=$ac_mid; break
4607 else
4608   echo "$as_me: failed program was:" >&5
4609 cat conftest.$ac_ext >&5
4610 ac_lo=`expr $ac_mid + 1`; ac_mid=`expr 2 '*' $ac_mid + 1`
4611 fi
4612 rm -f conftest.$ac_objext conftest.$ac_ext
4613   done
4614 else
4615   echo "$as_me: failed program was:" >&5
4616 cat conftest.$ac_ext >&5
4617 ac_hi=-1 ac_mid=-1
4618   while :; do
4619     cat >conftest.$ac_ext <<_ACEOF
4620 #line 4620 "configure"
4621 #include "confdefs.h"
4622 $ac_includes_default
4623 int
4624 main ()
4625 {
4626 int _array_ [1 - 2 * !((sizeof (short)) >= $ac_mid)]
4627   ;
4628   return 0;
4629 }
4630 _ACEOF
4631 rm -f conftest.$ac_objext
4632 if { (eval echo "$as_me:4632: \"$ac_compile\"") >&5
4633   (eval $ac_compile) 2>&5
4634   ac_status=$?
4635   echo "$as_me:4635: \$? = $ac_status" >&5
4636   (exit $ac_status); } &&
4637          { ac_try='test -s conftest.$ac_objext'
4638   { (eval echo "$as_me:4638: \"$ac_try\"") >&5
4639   (eval $ac_try) 2>&5
4640   ac_status=$?
4641   echo "$as_me:4641: \$? = $ac_status" >&5
4642   (exit $ac_status); }; }; then
4643   ac_lo=$ac_mid; break
4644 else
4645   echo "$as_me: failed program was:" >&5
4646 cat conftest.$ac_ext >&5
4647 ac_hi=`expr $ac_mid - 1`; ac_mid=`expr 2 '*' $ac_mid`
4648 fi
4649 rm -f conftest.$ac_objext conftest.$ac_ext
4650   done
4651 fi
4652 rm -f conftest.$ac_objext conftest.$ac_ext
4653 # Binary search between lo and hi bounds.
4654 while test "x$ac_lo" != "x$ac_hi"; do
4655   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
4656   cat >conftest.$ac_ext <<_ACEOF
4657 #line 4657 "configure"
4658 #include "confdefs.h"
4659 $ac_includes_default
4660 int
4661 main ()
4662 {
4663 int _array_ [1 - 2 * !((sizeof (short)) <= $ac_mid)]
4664   ;
4665   return 0;
4666 }
4667 _ACEOF
4668 rm -f conftest.$ac_objext
4669 if { (eval echo "$as_me:4669: \"$ac_compile\"") >&5
4670   (eval $ac_compile) 2>&5
4671   ac_status=$?
4672   echo "$as_me:4672: \$? = $ac_status" >&5
4673   (exit $ac_status); } &&
4674          { ac_try='test -s conftest.$ac_objext'
4675   { (eval echo "$as_me:4675: \"$ac_try\"") >&5
4676   (eval $ac_try) 2>&5
4677   ac_status=$?
4678   echo "$as_me:4678: \$? = $ac_status" >&5
4679   (exit $ac_status); }; }; then
4680   ac_hi=$ac_mid
4681 else
4682   echo "$as_me: failed program was:" >&5
4683 cat conftest.$ac_ext >&5
4684 ac_lo=`expr $ac_mid + 1`
4685 fi
4686 rm -f conftest.$ac_objext conftest.$ac_ext
4687 done
4688 ac_cv_sizeof_short=$ac_lo
4689 else
4690   if test "$cross_compiling" = yes; then
4691   { { echo "$as_me:4691: error: cannot run test program while cross compiling" >&5
4692 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
4693    { (exit 1); exit 1; }; }
4694 else
4695   cat >conftest.$ac_ext <<_ACEOF
4696 #line 4696 "configure"
4697 #include "confdefs.h"
4698 $ac_includes_default
4699 int
4700 main ()
4701 {
4702 FILE *f = fopen ("conftest.val", "w");
4703 if (!f)
4704   exit (1);
4705 fprintf (f, "%d", (sizeof (short)));
4706 fclose (f);
4707   ;
4708   return 0;
4709 }
4710 _ACEOF
4711 rm -f conftest$ac_exeext
4712 if { (eval echo "$as_me:4712: \"$ac_link\"") >&5
4713   (eval $ac_link) 2>&5
4714   ac_status=$?
4715   echo "$as_me:4715: \$? = $ac_status" >&5
4716   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4717   { (eval echo "$as_me:4717: \"$ac_try\"") >&5
4718   (eval $ac_try) 2>&5
4719   ac_status=$?
4720   echo "$as_me:4720: \$? = $ac_status" >&5
4721   (exit $ac_status); }; }; then
4722   ac_cv_sizeof_short=`cat conftest.val`
4723 else
4724   echo "$as_me: program exited with status $ac_status" >&5
4725 echo "$as_me: failed program was:" >&5
4726 cat conftest.$ac_ext >&5
4727 fi
4728 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4729 fi
4730 fi
4731 rm -f conftest.val
4732 else
4733   ac_cv_sizeof_short=0
4734 fi
4735 fi
4736 echo "$as_me:4736: result: $ac_cv_sizeof_short" >&5
4737 echo "${ECHO_T}$ac_cv_sizeof_short" >&6
4738 cat >>confdefs.h <<EOF
4739 #define SIZEOF_SHORT $ac_cv_sizeof_short
4740 EOF
4741
4742 echo "$as_me:4742: checking for an ANSI C-conforming const" >&5
4743 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
4744 if test "${ac_cv_c_const+set}" = set; then
4745   echo $ECHO_N "(cached) $ECHO_C" >&6
4746 else
4747   cat >conftest.$ac_ext <<_ACEOF
4748 #line 4748 "configure"
4749 #include "confdefs.h"
4750
4751 int
4752 main ()
4753 {
4754 /* FIXME: Include the comments suggested by Paul. */
4755 #ifndef __cplusplus
4756   /* Ultrix mips cc rejects this.  */
4757   typedef int charset[2];
4758   const charset x;
4759   /* SunOS 4.1.1 cc rejects this.  */
4760   char const *const *ccp;
4761   char **p;
4762   /* NEC SVR4.0.2 mips cc rejects this.  */
4763   struct point {int x, y;};
4764   static struct point const zero = {0,0};
4765   /* AIX XL C 1.02.0.0 rejects this.
4766      It does not let you subtract one const X* pointer from another in
4767      an arm of an if-expression whose if-part is not a constant
4768      expression */
4769   const char *g = "string";
4770   ccp = &g + (g ? g-g : 0);
4771   /* HPUX 7.0 cc rejects these. */
4772   ++ccp;
4773   p = (char**) ccp;
4774   ccp = (char const *const *) p;
4775   { /* SCO 3.2v4 cc rejects this.  */
4776     char *t;
4777     char const *s = 0 ? (char *) 0 : (char const *) 0;
4778
4779     *t++ = 0;
4780   }
4781   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
4782     int x[] = {25, 17};
4783     const int *foo = &x[0];
4784     ++foo;
4785   }
4786   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
4787     typedef const int *iptr;
4788     iptr p = 0;
4789     ++p;
4790   }
4791   { /* AIX XL C 1.02.0.0 rejects this saying
4792        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
4793     struct s { int j; const int *ap[3]; };
4794     struct s *b; b->j = 5;
4795   }
4796   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
4797     const int foo = 10;
4798   }
4799 #endif
4800
4801   ;
4802   return 0;
4803 }
4804 _ACEOF
4805 rm -f conftest.$ac_objext
4806 if { (eval echo "$as_me:4806: \"$ac_compile\"") >&5
4807   (eval $ac_compile) 2>&5
4808   ac_status=$?
4809   echo "$as_me:4809: \$? = $ac_status" >&5
4810   (exit $ac_status); } &&
4811          { ac_try='test -s conftest.$ac_objext'
4812   { (eval echo "$as_me:4812: \"$ac_try\"") >&5
4813   (eval $ac_try) 2>&5
4814   ac_status=$?
4815   echo "$as_me:4815: \$? = $ac_status" >&5
4816   (exit $ac_status); }; }; then
4817   ac_cv_c_const=yes
4818 else
4819   echo "$as_me: failed program was:" >&5
4820 cat conftest.$ac_ext >&5
4821 ac_cv_c_const=no
4822 fi
4823 rm -f conftest.$ac_objext conftest.$ac_ext
4824 fi
4825 echo "$as_me:4825: result: $ac_cv_c_const" >&5
4826 echo "${ECHO_T}$ac_cv_c_const" >&6
4827 if test $ac_cv_c_const = no; then
4828
4829 cat >>confdefs.h <<\EOF
4830 #define const
4831 EOF
4832
4833 fi
4834
4835 echo "$as_me:4835: checking for inline" >&5
4836 echo $ECHO_N "checking for inline... $ECHO_C" >&6
4837 if test "${ac_cv_c_inline+set}" = set; then
4838   echo $ECHO_N "(cached) $ECHO_C" >&6
4839 else
4840   ac_cv_c_inline=no
4841 for ac_kw in inline __inline__ __inline; do
4842   cat >conftest.$ac_ext <<_ACEOF
4843 #line 4843 "configure"
4844 #include "confdefs.h"
4845 #ifndef __cplusplus
4846 static $ac_kw int static_foo () {return 0; }
4847 $ac_kw int foo () {return 0; }
4848 #endif
4849
4850 _ACEOF
4851 rm -f conftest.$ac_objext
4852 if { (eval echo "$as_me:4852: \"$ac_compile\"") >&5
4853   (eval $ac_compile) 2>&5
4854   ac_status=$?
4855   echo "$as_me:4855: \$? = $ac_status" >&5
4856   (exit $ac_status); } &&
4857          { ac_try='test -s conftest.$ac_objext'
4858   { (eval echo "$as_me:4858: \"$ac_try\"") >&5
4859   (eval $ac_try) 2>&5
4860   ac_status=$?
4861   echo "$as_me:4861: \$? = $ac_status" >&5
4862   (exit $ac_status); }; }; then
4863   ac_cv_c_inline=$ac_kw; break
4864 else
4865   echo "$as_me: failed program was:" >&5
4866 cat conftest.$ac_ext >&5
4867 fi
4868 rm -f conftest.$ac_objext conftest.$ac_ext
4869 done
4870
4871 fi
4872 echo "$as_me:4872: result: $ac_cv_c_inline" >&5
4873 echo "${ECHO_T}$ac_cv_c_inline" >&6
4874 case $ac_cv_c_inline in
4875   inline | yes) ;;
4876   no)
4877 cat >>confdefs.h <<\EOF
4878 #define inline
4879 EOF
4880  ;;
4881   *)  cat >>confdefs.h <<EOF
4882 #define inline $ac_cv_c_inline
4883 EOF
4884  ;;
4885 esac
4886
4887 echo "$as_me:4887: checking whether byte ordering is bigendian" >&5
4888 echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
4889 if test "${ac_cv_c_bigendian+set}" = set; then
4890   echo $ECHO_N "(cached) $ECHO_C" >&6
4891 else
4892   ac_cv_c_bigendian=unknown
4893 # See if sys/param.h defines the BYTE_ORDER macro.
4894 cat >conftest.$ac_ext <<_ACEOF
4895 #line 4895 "configure"
4896 #include "confdefs.h"
4897 #include <sys/types.h>
4898 #include <sys/param.h>
4899
4900 int
4901 main ()
4902 {
4903 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
4904  bogus endian macros
4905 #endif
4906
4907   ;
4908   return 0;
4909 }
4910 _ACEOF
4911 rm -f conftest.$ac_objext
4912 if { (eval echo "$as_me:4912: \"$ac_compile\"") >&5
4913   (eval $ac_compile) 2>&5
4914   ac_status=$?
4915   echo "$as_me:4915: \$? = $ac_status" >&5
4916   (exit $ac_status); } &&
4917          { ac_try='test -s conftest.$ac_objext'
4918   { (eval echo "$as_me:4918: \"$ac_try\"") >&5
4919   (eval $ac_try) 2>&5
4920   ac_status=$?
4921   echo "$as_me:4921: \$? = $ac_status" >&5
4922   (exit $ac_status); }; }; then
4923   # It does; now see whether it defined to BIG_ENDIAN or not.
4924 cat >conftest.$ac_ext <<_ACEOF
4925 #line 4925 "configure"
4926 #include "confdefs.h"
4927 #include <sys/types.h>
4928 #include <sys/param.h>
4929
4930 int
4931 main ()
4932 {
4933 #if BYTE_ORDER != BIG_ENDIAN
4934  not big endian
4935 #endif
4936
4937   ;
4938   return 0;
4939 }
4940 _ACEOF
4941 rm -f conftest.$ac_objext
4942 if { (eval echo "$as_me:4942: \"$ac_compile\"") >&5
4943   (eval $ac_compile) 2>&5
4944   ac_status=$?
4945   echo "$as_me:4945: \$? = $ac_status" >&5
4946   (exit $ac_status); } &&
4947          { ac_try='test -s conftest.$ac_objext'
4948   { (eval echo "$as_me:4948: \"$ac_try\"") >&5
4949   (eval $ac_try) 2>&5
4950   ac_status=$?
4951   echo "$as_me:4951: \$? = $ac_status" >&5
4952   (exit $ac_status); }; }; then
4953   ac_cv_c_bigendian=yes
4954 else
4955   echo "$as_me: failed program was:" >&5
4956 cat conftest.$ac_ext >&5
4957 ac_cv_c_bigendian=no
4958 fi
4959 rm -f conftest.$ac_objext conftest.$ac_ext
4960 else
4961   echo "$as_me: failed program was:" >&5
4962 cat conftest.$ac_ext >&5
4963 fi
4964 rm -f conftest.$ac_objext conftest.$ac_ext
4965 if test $ac_cv_c_bigendian = unknown; then
4966 if test "$cross_compiling" = yes; then
4967   { { echo "$as_me:4967: error: cannot run test program while cross compiling" >&5
4968 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
4969    { (exit 1); exit 1; }; }
4970 else
4971   cat >conftest.$ac_ext <<_ACEOF
4972 #line 4972 "configure"
4973 #include "confdefs.h"
4974 int
4975 main ()
4976 {
4977   /* Are we little or big endian?  From Harbison&Steele.  */
4978   union
4979   {
4980     long l;
4981     char c[sizeof (long)];
4982   } u;
4983   u.l = 1;
4984   exit (u.c[sizeof (long) - 1] == 1);
4985 }
4986 _ACEOF
4987 rm -f conftest$ac_exeext
4988 if { (eval echo "$as_me:4988: \"$ac_link\"") >&5
4989   (eval $ac_link) 2>&5
4990   ac_status=$?
4991   echo "$as_me:4991: \$? = $ac_status" >&5
4992   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4993   { (eval echo "$as_me:4993: \"$ac_try\"") >&5
4994   (eval $ac_try) 2>&5
4995   ac_status=$?
4996   echo "$as_me:4996: \$? = $ac_status" >&5
4997   (exit $ac_status); }; }; then
4998   ac_cv_c_bigendian=no
4999 else
5000   echo "$as_me: program exited with status $ac_status" >&5
5001 echo "$as_me: failed program was:" >&5
5002 cat conftest.$ac_ext >&5
5003 ac_cv_c_bigendian=yes
5004 fi
5005 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5006 fi
5007 fi
5008 fi
5009 echo "$as_me:5009: result: $ac_cv_c_bigendian" >&5
5010 echo "${ECHO_T}$ac_cv_c_bigendian" >&6
5011 if test $ac_cv_c_bigendian = yes; then
5012
5013 cat >>confdefs.h <<\EOF
5014 #define WORDS_BIGENDIAN 1
5015 EOF
5016
5017 fi
5018
5019 echo "$as_me:5019: checking whether char is unsigned" >&5
5020 echo $ECHO_N "checking whether char is unsigned... $ECHO_C" >&6
5021 if test "${ac_cv_c_char_unsigned+set}" = set; then
5022   echo $ECHO_N "(cached) $ECHO_C" >&6
5023 else
5024   cat >conftest.$ac_ext <<_ACEOF
5025 #line 5025 "configure"
5026 #include "confdefs.h"
5027 $ac_includes_default
5028 int
5029 main ()
5030 {
5031 int _array_ [1 - 2 * !(((char) -1) < 0)]
5032   ;
5033   return 0;
5034 }
5035 _ACEOF
5036 rm -f conftest.$ac_objext
5037 if { (eval echo "$as_me:5037: \"$ac_compile\"") >&5
5038   (eval $ac_compile) 2>&5
5039   ac_status=$?
5040   echo "$as_me:5040: \$? = $ac_status" >&5
5041   (exit $ac_status); } &&
5042          { ac_try='test -s conftest.$ac_objext'
5043   { (eval echo "$as_me:5043: \"$ac_try\"") >&5
5044   (eval $ac_try) 2>&5
5045   ac_status=$?
5046   echo "$as_me:5046: \$? = $ac_status" >&5
5047   (exit $ac_status); }; }; then
5048   ac_cv_c_char_unsigned=no
5049 else
5050   echo "$as_me: failed program was:" >&5
5051 cat conftest.$ac_ext >&5
5052 ac_cv_c_char_unsigned=yes
5053 fi
5054 rm -f conftest.$ac_objext conftest.$ac_ext
5055 fi
5056 echo "$as_me:5056: result: $ac_cv_c_char_unsigned" >&5
5057 echo "${ECHO_T}$ac_cv_c_char_unsigned" >&6
5058 if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
5059   cat >>confdefs.h <<\EOF
5060 #define __CHAR_UNSIGNED__ 1
5061 EOF
5062
5063 fi
5064
5065 echo "$as_me:5065: checking return type of signal handlers" >&5
5066 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
5067 if test "${ac_cv_type_signal+set}" = set; then
5068   echo $ECHO_N "(cached) $ECHO_C" >&6
5069 else
5070   cat >conftest.$ac_ext <<_ACEOF
5071 #line 5071 "configure"
5072 #include "confdefs.h"
5073 #include <sys/types.h>
5074 #include <signal.h>
5075 #ifdef signal
5076 # undef signal
5077 #endif
5078 #ifdef __cplusplus
5079 extern "C" void (*signal (int, void (*)(int)))(int);
5080 #else
5081 void (*signal ()) ();
5082 #endif
5083
5084 int
5085 main ()
5086 {
5087 int i;
5088   ;
5089   return 0;
5090 }
5091 _ACEOF
5092 rm -f conftest.$ac_objext
5093 if { (eval echo "$as_me:5093: \"$ac_compile\"") >&5
5094   (eval $ac_compile) 2>&5
5095   ac_status=$?
5096   echo "$as_me:5096: \$? = $ac_status" >&5
5097   (exit $ac_status); } &&
5098          { ac_try='test -s conftest.$ac_objext'
5099   { (eval echo "$as_me:5099: \"$ac_try\"") >&5
5100   (eval $ac_try) 2>&5
5101   ac_status=$?
5102   echo "$as_me:5102: \$? = $ac_status" >&5
5103   (exit $ac_status); }; }; then
5104   ac_cv_type_signal=void
5105 else
5106   echo "$as_me: failed program was:" >&5
5107 cat conftest.$ac_ext >&5
5108 ac_cv_type_signal=int
5109 fi
5110 rm -f conftest.$ac_objext conftest.$ac_ext
5111 fi
5112 echo "$as_me:5112: result: $ac_cv_type_signal" >&5
5113 echo "${ECHO_T}$ac_cv_type_signal" >&6
5114
5115 cat >>confdefs.h <<EOF
5116 #define RETSIGTYPE $ac_cv_type_signal
5117 EOF
5118
5119 echo "$as_me:5119: checking for uid_t in sys/types.h" >&5
5120 echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6
5121 if test "${ac_cv_type_uid_t+set}" = set; then
5122   echo $ECHO_N "(cached) $ECHO_C" >&6
5123 else
5124   cat >conftest.$ac_ext <<_ACEOF
5125 #line 5125 "configure"
5126 #include "confdefs.h"
5127 #include <sys/types.h>
5128
5129 _ACEOF
5130 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5131   egrep "uid_t" >/dev/null 2>&1; then
5132   ac_cv_type_uid_t=yes
5133 else
5134   ac_cv_type_uid_t=no
5135 fi
5136 rm -f conftest*
5137
5138 fi
5139 echo "$as_me:5139: result: $ac_cv_type_uid_t" >&5
5140 echo "${ECHO_T}$ac_cv_type_uid_t" >&6
5141 if test $ac_cv_type_uid_t = no; then
5142
5143 cat >>confdefs.h <<\EOF
5144 #define uid_t int
5145 EOF
5146
5147 cat >>confdefs.h <<\EOF
5148 #define gid_t int
5149 EOF
5150
5151 fi
5152
5153 echo "$as_me:5153: checking for mode_t" >&5
5154 echo $ECHO_N "checking for mode_t... $ECHO_C" >&6
5155 if test "${ac_cv_type_mode_t+set}" = set; then
5156   echo $ECHO_N "(cached) $ECHO_C" >&6
5157 else
5158   cat >conftest.$ac_ext <<_ACEOF
5159 #line 5159 "configure"
5160 #include "confdefs.h"
5161 $ac_includes_default
5162 int
5163 main ()
5164 {
5165 if ((mode_t *) 0)
5166   return 0;
5167 if (sizeof (mode_t))
5168   return 0;
5169   ;
5170   return 0;
5171 }
5172 _ACEOF
5173 rm -f conftest.$ac_objext
5174 if { (eval echo "$as_me:5174: \"$ac_compile\"") >&5
5175   (eval $ac_compile) 2>&5
5176   ac_status=$?
5177   echo "$as_me:5177: \$? = $ac_status" >&5
5178   (exit $ac_status); } &&
5179          { ac_try='test -s conftest.$ac_objext'
5180   { (eval echo "$as_me:5180: \"$ac_try\"") >&5
5181   (eval $ac_try) 2>&5
5182   ac_status=$?
5183   echo "$as_me:5183: \$? = $ac_status" >&5
5184   (exit $ac_status); }; }; then
5185   ac_cv_type_mode_t=yes
5186 else
5187   echo "$as_me: failed program was:" >&5
5188 cat conftest.$ac_ext >&5
5189 ac_cv_type_mode_t=no
5190 fi
5191 rm -f conftest.$ac_objext conftest.$ac_ext
5192 fi
5193 echo "$as_me:5193: result: $ac_cv_type_mode_t" >&5
5194 echo "${ECHO_T}$ac_cv_type_mode_t" >&6
5195 if test $ac_cv_type_mode_t = yes; then
5196   :
5197 else
5198
5199 cat >>confdefs.h <<EOF
5200 #define mode_t int
5201 EOF
5202
5203 fi
5204
5205 echo "$as_me:5205: checking for off_t" >&5
5206 echo $ECHO_N "checking for off_t... $ECHO_C" >&6
5207 if test "${ac_cv_type_off_t+set}" = set; then
5208   echo $ECHO_N "(cached) $ECHO_C" >&6
5209 else
5210   cat >conftest.$ac_ext <<_ACEOF
5211 #line 5211 "configure"
5212 #include "confdefs.h"
5213 $ac_includes_default
5214 int
5215 main ()
5216 {
5217 if ((off_t *) 0)
5218   return 0;
5219 if (sizeof (off_t))
5220   return 0;
5221   ;
5222   return 0;
5223 }
5224 _ACEOF
5225 rm -f conftest.$ac_objext
5226 if { (eval echo "$as_me:5226: \"$ac_compile\"") >&5
5227   (eval $ac_compile) 2>&5
5228   ac_status=$?
5229   echo "$as_me:5229: \$? = $ac_status" >&5
5230   (exit $ac_status); } &&
5231          { ac_try='test -s conftest.$ac_objext'
5232   { (eval echo "$as_me:5232: \"$ac_try\"") >&5
5233   (eval $ac_try) 2>&5
5234   ac_status=$?
5235   echo "$as_me:5235: \$? = $ac_status" >&5
5236   (exit $ac_status); }; }; then
5237   ac_cv_type_off_t=yes
5238 else
5239   echo "$as_me: failed program was:" >&5
5240 cat conftest.$ac_ext >&5
5241 ac_cv_type_off_t=no
5242 fi
5243 rm -f conftest.$ac_objext conftest.$ac_ext
5244 fi
5245 echo "$as_me:5245: result: $ac_cv_type_off_t" >&5
5246 echo "${ECHO_T}$ac_cv_type_off_t" >&6
5247 if test $ac_cv_type_off_t = yes; then
5248   :
5249 else
5250
5251 cat >>confdefs.h <<EOF
5252 #define off_t long
5253 EOF
5254
5255 fi
5256
5257 echo "$as_me:5257: checking for size_t" >&5
5258 echo $ECHO_N "checking for size_t... $ECHO_C" >&6
5259 if test "${ac_cv_type_size_t+set}" = set; then
5260   echo $ECHO_N "(cached) $ECHO_C" >&6
5261 else
5262   cat >conftest.$ac_ext <<_ACEOF
5263 #line 5263 "configure"
5264 #include "confdefs.h"
5265 $ac_includes_default
5266 int
5267 main ()
5268 {
5269 if ((size_t *) 0)
5270   return 0;
5271 if (sizeof (size_t))
5272   return 0;
5273   ;
5274   return 0;
5275 }
5276 _ACEOF
5277 rm -f conftest.$ac_objext
5278 if { (eval echo "$as_me:5278: \"$ac_compile\"") >&5
5279   (eval $ac_compile) 2>&5
5280   ac_status=$?
5281   echo "$as_me:5281: \$? = $ac_status" >&5
5282   (exit $ac_status); } &&
5283          { ac_try='test -s conftest.$ac_objext'
5284   { (eval echo "$as_me:5284: \"$ac_try\"") >&5
5285   (eval $ac_try) 2>&5
5286   ac_status=$?
5287   echo "$as_me:5287: \$? = $ac_status" >&5
5288   (exit $ac_status); }; }; then
5289   ac_cv_type_size_t=yes
5290 else
5291   echo "$as_me: failed program was:" >&5
5292 cat conftest.$ac_ext >&5
5293 ac_cv_type_size_t=no
5294 fi
5295 rm -f conftest.$ac_objext conftest.$ac_ext
5296 fi
5297 echo "$as_me:5297: result: $ac_cv_type_size_t" >&5
5298 echo "${ECHO_T}$ac_cv_type_size_t" >&6
5299 if test $ac_cv_type_size_t = yes; then
5300   :
5301 else
5302
5303 cat >>confdefs.h <<EOF
5304 #define size_t unsigned
5305 EOF
5306
5307 fi
5308
5309 echo "$as_me:5309: checking for pid_t" >&5
5310 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
5311 if test "${ac_cv_type_pid_t+set}" = set; then
5312   echo $ECHO_N "(cached) $ECHO_C" >&6
5313 else
5314   cat >conftest.$ac_ext <<_ACEOF
5315 #line 5315 "configure"
5316 #include "confdefs.h"
5317 $ac_includes_default
5318 int
5319 main ()
5320 {
5321 if ((pid_t *) 0)
5322   return 0;
5323 if (sizeof (pid_t))
5324   return 0;
5325   ;
5326   return 0;
5327 }
5328 _ACEOF
5329 rm -f conftest.$ac_objext
5330 if { (eval echo "$as_me:5330: \"$ac_compile\"") >&5
5331   (eval $ac_compile) 2>&5
5332   ac_status=$?
5333   echo "$as_me:5333: \$? = $ac_status" >&5
5334   (exit $ac_status); } &&
5335          { ac_try='test -s conftest.$ac_objext'
5336   { (eval echo "$as_me:5336: \"$ac_try\"") >&5
5337   (eval $ac_try) 2>&5
5338   ac_status=$?
5339   echo "$as_me:5339: \$? = $ac_status" >&5
5340   (exit $ac_status); }; }; then
5341   ac_cv_type_pid_t=yes
5342 else
5343   echo "$as_me: failed program was:" >&5
5344 cat conftest.$ac_ext >&5
5345 ac_cv_type_pid_t=no
5346 fi
5347 rm -f conftest.$ac_objext conftest.$ac_ext
5348 fi
5349 echo "$as_me:5349: result: $ac_cv_type_pid_t" >&5
5350 echo "${ECHO_T}$ac_cv_type_pid_t" >&6
5351 if test $ac_cv_type_pid_t = yes; then
5352   :
5353 else
5354
5355 cat >>confdefs.h <<EOF
5356 #define pid_t int
5357 EOF
5358
5359 fi
5360
5361 echo "$as_me:5361: checking for struct stat.st_rdev" >&5
5362 echo $ECHO_N "checking for struct stat.st_rdev... $ECHO_C" >&6
5363 if test "${ac_cv_member_struct_stat_st_rdev+set}" = set; then
5364   echo $ECHO_N "(cached) $ECHO_C" >&6
5365 else
5366   cat >conftest.$ac_ext <<_ACEOF
5367 #line 5367 "configure"
5368 #include "confdefs.h"
5369 $ac_includes_default
5370 int
5371 main ()
5372 {
5373 static struct stat ac_aggr;
5374 if (ac_aggr.st_rdev)
5375 return 0;
5376   ;
5377   return 0;
5378 }
5379 _ACEOF
5380 rm -f conftest.$ac_objext
5381 if { (eval echo "$as_me:5381: \"$ac_compile\"") >&5
5382   (eval $ac_compile) 2>&5
5383   ac_status=$?
5384   echo "$as_me:5384: \$? = $ac_status" >&5
5385   (exit $ac_status); } &&
5386          { ac_try='test -s conftest.$ac_objext'
5387   { (eval echo "$as_me:5387: \"$ac_try\"") >&5
5388   (eval $ac_try) 2>&5
5389   ac_status=$?
5390   echo "$as_me:5390: \$? = $ac_status" >&5
5391   (exit $ac_status); }; }; then
5392   ac_cv_member_struct_stat_st_rdev=yes
5393 else
5394   echo "$as_me: failed program was:" >&5
5395 cat conftest.$ac_ext >&5
5396 ac_cv_member_struct_stat_st_rdev=no
5397 fi
5398 rm -f conftest.$ac_objext conftest.$ac_ext
5399 fi
5400 echo "$as_me:5400: result: $ac_cv_member_struct_stat_st_rdev" >&5
5401 echo "${ECHO_T}$ac_cv_member_struct_stat_st_rdev" >&6
5402 if test $ac_cv_member_struct_stat_st_rdev = yes; then
5403
5404 cat >>confdefs.h <<EOF
5405 #define HAVE_STRUCT_STAT_ST_RDEV 1
5406 EOF
5407
5408 cat >>confdefs.h <<\EOF
5409 #define HAVE_ST_RDEV 1
5410 EOF
5411
5412 fi
5413
5414 echo "$as_me:5414: checking for d_off in dirent" >&5
5415 echo $ECHO_N "checking for d_off in dirent... $ECHO_C" >&6
5416 if test "${ac_cv_dirent_d_off+set}" = set; then
5417   echo $ECHO_N "(cached) $ECHO_C" >&6
5418 else
5419   cat >conftest.$ac_ext <<_ACEOF
5420 #line 5420 "configure"
5421 #include "confdefs.h"
5422
5423 #include <unistd.h>
5424 #include <sys/types.h>
5425 #include <dirent.h>
5426 int
5427 main ()
5428 {
5429 struct dirent d; d.d_off;
5430   ;
5431   return 0;
5432 }
5433 _ACEOF
5434 rm -f conftest.$ac_objext
5435 if { (eval echo "$as_me:5435: \"$ac_compile\"") >&5
5436   (eval $ac_compile) 2>&5
5437   ac_status=$?
5438   echo "$as_me:5438: \$? = $ac_status" >&5
5439   (exit $ac_status); } &&
5440          { ac_try='test -s conftest.$ac_objext'
5441   { (eval echo "$as_me:5441: \"$ac_try\"") >&5
5442   (eval $ac_try) 2>&5
5443   ac_status=$?
5444   echo "$as_me:5444: \$? = $ac_status" >&5
5445   (exit $ac_status); }; }; then
5446   ac_cv_dirent_d_off=yes
5447 else
5448   echo "$as_me: failed program was:" >&5
5449 cat conftest.$ac_ext >&5
5450 ac_cv_dirent_d_off=no
5451 fi
5452 rm -f conftest.$ac_objext conftest.$ac_ext
5453 fi
5454 echo "$as_me:5454: result: $ac_cv_dirent_d_off" >&5
5455 echo "${ECHO_T}$ac_cv_dirent_d_off" >&6
5456 if test $ac_cv_dirent_d_off = yes; then
5457   cat >>confdefs.h <<\EOF
5458 #define HAVE_DIRENT_D_OFF 1
5459 EOF
5460
5461 fi
5462
5463 echo "$as_me:5463: checking for ino_t" >&5
5464 echo $ECHO_N "checking for ino_t... $ECHO_C" >&6
5465 if test "${ac_cv_type_ino_t+set}" = set; then
5466   echo $ECHO_N "(cached) $ECHO_C" >&6
5467 else
5468   cat >conftest.$ac_ext <<_ACEOF
5469 #line 5469 "configure"
5470 #include "confdefs.h"
5471 $ac_includes_default
5472 int
5473 main ()
5474 {
5475 if ((ino_t *) 0)
5476   return 0;
5477 if (sizeof (ino_t))
5478   return 0;
5479   ;
5480   return 0;
5481 }
5482 _ACEOF
5483 rm -f conftest.$ac_objext
5484 if { (eval echo "$as_me:5484: \"$ac_compile\"") >&5
5485   (eval $ac_compile) 2>&5
5486   ac_status=$?
5487   echo "$as_me:5487: \$? = $ac_status" >&5
5488   (exit $ac_status); } &&
5489          { ac_try='test -s conftest.$ac_objext'
5490   { (eval echo "$as_me:5490: \"$ac_try\"") >&5
5491   (eval $ac_try) 2>&5
5492   ac_status=$?
5493   echo "$as_me:5493: \$? = $ac_status" >&5
5494   (exit $ac_status); }; }; then
5495   ac_cv_type_ino_t=yes
5496 else
5497   echo "$as_me: failed program was:" >&5
5498 cat conftest.$ac_ext >&5
5499 ac_cv_type_ino_t=no
5500 fi
5501 rm -f conftest.$ac_objext conftest.$ac_ext
5502 fi
5503 echo "$as_me:5503: result: $ac_cv_type_ino_t" >&5
5504 echo "${ECHO_T}$ac_cv_type_ino_t" >&6
5505 if test $ac_cv_type_ino_t = yes; then
5506   :
5507 else
5508
5509 cat >>confdefs.h <<EOF
5510 #define ino_t unsigned
5511 EOF
5512
5513 fi
5514
5515 echo "$as_me:5515: checking for loff_t" >&5
5516 echo $ECHO_N "checking for loff_t... $ECHO_C" >&6
5517 if test "${ac_cv_type_loff_t+set}" = set; then
5518   echo $ECHO_N "(cached) $ECHO_C" >&6
5519 else
5520   cat >conftest.$ac_ext <<_ACEOF
5521 #line 5521 "configure"
5522 #include "confdefs.h"
5523 $ac_includes_default
5524 int
5525 main ()
5526 {
5527 if ((loff_t *) 0)
5528   return 0;
5529 if (sizeof (loff_t))
5530   return 0;
5531   ;
5532   return 0;
5533 }
5534 _ACEOF
5535 rm -f conftest.$ac_objext
5536 if { (eval echo "$as_me:5536: \"$ac_compile\"") >&5
5537   (eval $ac_compile) 2>&5
5538   ac_status=$?
5539   echo "$as_me:5539: \$? = $ac_status" >&5
5540   (exit $ac_status); } &&
5541          { ac_try='test -s conftest.$ac_objext'
5542   { (eval echo "$as_me:5542: \"$ac_try\"") >&5
5543   (eval $ac_try) 2>&5
5544   ac_status=$?
5545   echo "$as_me:5545: \$? = $ac_status" >&5
5546   (exit $ac_status); }; }; then
5547   ac_cv_type_loff_t=yes
5548 else
5549   echo "$as_me: failed program was:" >&5
5550 cat conftest.$ac_ext >&5
5551 ac_cv_type_loff_t=no
5552 fi
5553 rm -f conftest.$ac_objext conftest.$ac_ext
5554 fi
5555 echo "$as_me:5555: result: $ac_cv_type_loff_t" >&5
5556 echo "${ECHO_T}$ac_cv_type_loff_t" >&6
5557 if test $ac_cv_type_loff_t = yes; then
5558   :
5559 else
5560
5561 cat >>confdefs.h <<EOF
5562 #define loff_t off_t
5563 EOF
5564
5565 fi
5566
5567 echo "$as_me:5567: checking for offset_t" >&5
5568 echo $ECHO_N "checking for offset_t... $ECHO_C" >&6
5569 if test "${ac_cv_type_offset_t+set}" = set; then
5570   echo $ECHO_N "(cached) $ECHO_C" >&6
5571 else
5572   cat >conftest.$ac_ext <<_ACEOF
5573 #line 5573 "configure"
5574 #include "confdefs.h"
5575 $ac_includes_default
5576 int
5577 main ()
5578 {
5579 if ((offset_t *) 0)
5580   return 0;
5581 if (sizeof (offset_t))
5582   return 0;
5583   ;
5584   return 0;
5585 }
5586 _ACEOF
5587 rm -f conftest.$ac_objext
5588 if { (eval echo "$as_me:5588: \"$ac_compile\"") >&5
5589   (eval $ac_compile) 2>&5
5590   ac_status=$?
5591   echo "$as_me:5591: \$? = $ac_status" >&5
5592   (exit $ac_status); } &&
5593          { ac_try='test -s conftest.$ac_objext'
5594   { (eval echo "$as_me:5594: \"$ac_try\"") >&5
5595   (eval $ac_try) 2>&5
5596   ac_status=$?
5597   echo "$as_me:5597: \$? = $ac_status" >&5
5598   (exit $ac_status); }; }; then
5599   ac_cv_type_offset_t=yes
5600 else
5601   echo "$as_me: failed program was:" >&5
5602 cat conftest.$ac_ext >&5
5603 ac_cv_type_offset_t=no
5604 fi
5605 rm -f conftest.$ac_objext conftest.$ac_ext
5606 fi
5607 echo "$as_me:5607: result: $ac_cv_type_offset_t" >&5
5608 echo "${ECHO_T}$ac_cv_type_offset_t" >&6
5609 if test $ac_cv_type_offset_t = yes; then
5610   :
5611 else
5612
5613 cat >>confdefs.h <<EOF
5614 #define offset_t loff_t
5615 EOF
5616
5617 fi
5618
5619 echo "$as_me:5619: checking for ssize_t" >&5
5620 echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6
5621 if test "${ac_cv_type_ssize_t+set}" = set; then
5622   echo $ECHO_N "(cached) $ECHO_C" >&6
5623 else
5624   cat >conftest.$ac_ext <<_ACEOF
5625 #line 5625 "configure"
5626 #include "confdefs.h"
5627 $ac_includes_default
5628 int
5629 main ()
5630 {
5631 if ((ssize_t *) 0)
5632   return 0;
5633 if (sizeof (ssize_t))
5634   return 0;
5635   ;
5636   return 0;
5637 }
5638 _ACEOF
5639 rm -f conftest.$ac_objext
5640 if { (eval echo "$as_me:5640: \"$ac_compile\"") >&5
5641   (eval $ac_compile) 2>&5
5642   ac_status=$?
5643   echo "$as_me:5643: \$? = $ac_status" >&5
5644   (exit $ac_status); } &&
5645          { ac_try='test -s conftest.$ac_objext'
5646   { (eval echo "$as_me:5646: \"$ac_try\"") >&5
5647   (eval $ac_try) 2>&5
5648   ac_status=$?
5649   echo "$as_me:5649: \$? = $ac_status" >&5
5650   (exit $ac_status); }; }; then
5651   ac_cv_type_ssize_t=yes
5652 else
5653   echo "$as_me: failed program was:" >&5
5654 cat conftest.$ac_ext >&5
5655 ac_cv_type_ssize_t=no
5656 fi
5657 rm -f conftest.$ac_objext conftest.$ac_ext
5658 fi
5659 echo "$as_me:5659: result: $ac_cv_type_ssize_t" >&5
5660 echo "${ECHO_T}$ac_cv_type_ssize_t" >&6
5661 if test $ac_cv_type_ssize_t = yes; then
5662   :
5663 else
5664
5665 cat >>confdefs.h <<EOF
5666 #define ssize_t int
5667 EOF
5668
5669 fi
5670
5671 echo "$as_me:5671: checking for wchar_t" >&5
5672 echo $ECHO_N "checking for wchar_t... $ECHO_C" >&6
5673 if test "${ac_cv_type_wchar_t+set}" = set; then
5674   echo $ECHO_N "(cached) $ECHO_C" >&6
5675 else
5676   cat >conftest.$ac_ext <<_ACEOF
5677 #line 5677 "configure"
5678 #include "confdefs.h"
5679 $ac_includes_default
5680 int
5681 main ()
5682 {
5683 if ((wchar_t *) 0)
5684   return 0;
5685 if (sizeof (wchar_t))
5686   return 0;
5687   ;
5688   return 0;
5689 }
5690 _ACEOF
5691 rm -f conftest.$ac_objext
5692 if { (eval echo "$as_me:5692: \"$ac_compile\"") >&5
5693   (eval $ac_compile) 2>&5
5694   ac_status=$?
5695   echo "$as_me:5695: \$? = $ac_status" >&5
5696   (exit $ac_status); } &&
5697          { ac_try='test -s conftest.$ac_objext'
5698   { (eval echo "$as_me:5698: \"$ac_try\"") >&5
5699   (eval $ac_try) 2>&5
5700   ac_status=$?
5701   echo "$as_me:5701: \$? = $ac_status" >&5
5702   (exit $ac_status); }; }; then
5703   ac_cv_type_wchar_t=yes
5704 else
5705   echo "$as_me: failed program was:" >&5
5706 cat conftest.$ac_ext >&5
5707 ac_cv_type_wchar_t=no
5708 fi
5709 rm -f conftest.$ac_objext conftest.$ac_ext
5710 fi
5711 echo "$as_me:5711: result: $ac_cv_type_wchar_t" >&5
5712 echo "${ECHO_T}$ac_cv_type_wchar_t" >&6
5713 if test $ac_cv_type_wchar_t = yes; then
5714   :
5715 else
5716
5717 cat >>confdefs.h <<EOF
5718 #define wchar_t unsigned short
5719 EOF
5720
5721 fi
5722
5723 ############################################
5724 # for cups support we need libcups, and a handful of header files
5725
5726 echo "$as_me:5726: checking for httpConnect in -lcups" >&5
5727 echo $ECHO_N "checking for httpConnect in -lcups... $ECHO_C" >&6
5728 if test "${ac_cv_lib_cups_httpConnect+set}" = set; then
5729   echo $ECHO_N "(cached) $ECHO_C" >&6
5730 else
5731   ac_check_lib_save_LIBS=$LIBS
5732 LIBS="-lcups  $LIBS"
5733 cat >conftest.$ac_ext <<_ACEOF
5734 #line 5734 "configure"
5735 #include "confdefs.h"
5736
5737 /* Override any gcc2 internal prototype to avoid an error.  */
5738 #ifdef __cplusplus
5739 extern "C"
5740 #endif
5741 /* We use char because int might match the return type of a gcc2
5742    builtin and then its argument prototype would still apply.  */
5743 char httpConnect ();
5744 int
5745 main ()
5746 {
5747 httpConnect ();
5748   ;
5749   return 0;
5750 }
5751 _ACEOF
5752 rm -f conftest.$ac_objext conftest$ac_exeext
5753 if { (eval echo "$as_me:5753: \"$ac_link\"") >&5
5754   (eval $ac_link) 2>&5
5755   ac_status=$?
5756   echo "$as_me:5756: \$? = $ac_status" >&5
5757   (exit $ac_status); } &&
5758          { ac_try='test -s conftest$ac_exeext'
5759   { (eval echo "$as_me:5759: \"$ac_try\"") >&5
5760   (eval $ac_try) 2>&5
5761   ac_status=$?
5762   echo "$as_me:5762: \$? = $ac_status" >&5
5763   (exit $ac_status); }; }; then
5764   ac_cv_lib_cups_httpConnect=yes
5765 else
5766   echo "$as_me: failed program was:" >&5
5767 cat conftest.$ac_ext >&5
5768 ac_cv_lib_cups_httpConnect=no
5769 fi
5770 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5771 LIBS=$ac_check_lib_save_LIBS
5772 fi
5773 echo "$as_me:5773: result: $ac_cv_lib_cups_httpConnect" >&5
5774 echo "${ECHO_T}$ac_cv_lib_cups_httpConnect" >&6
5775 if test $ac_cv_lib_cups_httpConnect = yes; then
5776   cat >>confdefs.h <<EOF
5777 #define HAVE_LIBCUPS 1
5778 EOF
5779
5780   LIBS="-lcups $LIBS"
5781
5782 fi
5783
5784 # I wonder if there is a nicer way of doing this?
5785
5786 if test x"$ac_cv_lib_cups_httpConnect" = x"yes"; then
5787
5788 for ac_header in cups/cups.h cups/language.h
5789 do
5790 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5791 echo "$as_me:5791: checking for $ac_header" >&5
5792 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5793 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5794   echo $ECHO_N "(cached) $ECHO_C" >&6
5795 else
5796   cat >conftest.$ac_ext <<_ACEOF
5797 #line 5797 "configure"
5798 #include "confdefs.h"
5799 #include <$ac_header>
5800 _ACEOF
5801 if { (eval echo "$as_me:5801: \"$ac_cpp conftest.$ac_ext\"") >&5
5802   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5803   ac_status=$?
5804   egrep -v '^ *\+' conftest.er1 >conftest.err
5805   rm -f conftest.er1
5806   cat conftest.err >&5
5807   echo "$as_me:5807: \$? = $ac_status" >&5
5808   (exit $ac_status); } >/dev/null; then
5809   if test -s conftest.err; then
5810     ac_cpp_err=$ac_c_preproc_warn_flag
5811   else
5812     ac_cpp_err=
5813   fi
5814 else
5815   ac_cpp_err=yes
5816 fi
5817 if test -z "$ac_cpp_err"; then
5818   eval "$as_ac_Header=yes"
5819 else
5820   echo "$as_me: failed program was:" >&5
5821   cat conftest.$ac_ext >&5
5822   eval "$as_ac_Header=no"
5823 fi
5824 rm -f conftest.err conftest.$ac_ext
5825 fi
5826 echo "$as_me:5826: result: `eval echo '${'$as_ac_Header'}'`" >&5
5827 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5828 if test `eval echo '${'$as_ac_Header'}'` = yes; then
5829   cat >>confdefs.h <<EOF
5830 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5831 EOF
5832
5833 fi
5834 done
5835
5836         if test x"$ac_cv_header_cups_cups_h" = x"yes"; then
5837                 if test x"$ac_cv_header_cups_language_h" = x"yes"; then
5838                         cat >>confdefs.h <<\EOF
5839 #define HAVE_CUPS 1
5840 EOF
5841
5842                 fi
5843         fi
5844 fi
5845
5846 ############################################
5847 # we need libdl for PAM and the new VFS code
5848 echo "$as_me:5848: checking for dlopen in -ldl" >&5
5849 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
5850 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
5851   echo $ECHO_N "(cached) $ECHO_C" >&6
5852 else
5853   ac_check_lib_save_LIBS=$LIBS
5854 LIBS="-ldl  $LIBS"
5855 cat >conftest.$ac_ext <<_ACEOF
5856 #line 5856 "configure"
5857 #include "confdefs.h"
5858
5859 /* Override any gcc2 internal prototype to avoid an error.  */
5860 #ifdef __cplusplus
5861 extern "C"
5862 #endif
5863 /* We use char because int might match the return type of a gcc2
5864    builtin and then its argument prototype would still apply.  */
5865 char dlopen ();
5866 int
5867 main ()
5868 {
5869 dlopen ();
5870   ;
5871   return 0;
5872 }
5873 _ACEOF
5874 rm -f conftest.$ac_objext conftest$ac_exeext
5875 if { (eval echo "$as_me:5875: \"$ac_link\"") >&5
5876   (eval $ac_link) 2>&5
5877   ac_status=$?
5878   echo "$as_me:5878: \$? = $ac_status" >&5
5879   (exit $ac_status); } &&
5880          { ac_try='test -s conftest$ac_exeext'
5881   { (eval echo "$as_me:5881: \"$ac_try\"") >&5
5882   (eval $ac_try) 2>&5
5883   ac_status=$?
5884   echo "$as_me:5884: \$? = $ac_status" >&5
5885   (exit $ac_status); }; }; then
5886   ac_cv_lib_dl_dlopen=yes
5887 else
5888   echo "$as_me: failed program was:" >&5
5889 cat conftest.$ac_ext >&5
5890 ac_cv_lib_dl_dlopen=no
5891 fi
5892 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5893 LIBS=$ac_check_lib_save_LIBS
5894 fi
5895 echo "$as_me:5895: result: $ac_cv_lib_dl_dlopen" >&5
5896 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
5897 if test $ac_cv_lib_dl_dlopen = yes; then
5898   LIBS="$LIBS -ldl";
5899         cat >>confdefs.h <<\EOF
5900 #define HAVE_LIBDL 1
5901 EOF
5902
5903 fi
5904
5905 ############################################
5906 # check if the compiler can do immediate structures
5907 echo "$as_me:5907: checking for immediate structures" >&5
5908 echo $ECHO_N "checking for immediate structures... $ECHO_C" >&6
5909 if test "${samba_cv_immediate_structures+set}" = set; then
5910   echo $ECHO_N "(cached) $ECHO_C" >&6
5911 else
5912
5913     cat >conftest.$ac_ext <<_ACEOF
5914 #line 5914 "configure"
5915 #include "confdefs.h"
5916
5917 #include <stdio.h>
5918 int
5919 main ()
5920 {
5921
5922    #define X_FOOBAR(x) ((FOOBAR) { x })
5923    typedef struct {unsigned x;} FOOBAR;
5924    FOOBAR f = X_FOOBAR(1);
5925
5926   ;
5927   return 0;
5928 }
5929 _ACEOF
5930 rm -f conftest.$ac_objext
5931 if { (eval echo "$as_me:5931: \"$ac_compile\"") >&5
5932   (eval $ac_compile) 2>&5
5933   ac_status=$?
5934   echo "$as_me:5934: \$? = $ac_status" >&5
5935   (exit $ac_status); } &&
5936          { ac_try='test -s conftest.$ac_objext'
5937   { (eval echo "$as_me:5937: \"$ac_try\"") >&5
5938   (eval $ac_try) 2>&5
5939   ac_status=$?
5940   echo "$as_me:5940: \$? = $ac_status" >&5
5941   (exit $ac_status); }; }; then
5942   samba_cv_immediate_structures=yes
5943 else
5944   echo "$as_me: failed program was:" >&5
5945 cat conftest.$ac_ext >&5
5946 samba_cv_immediate_structures=no
5947 fi
5948 rm -f conftest.$ac_objext conftest.$ac_ext
5949 fi
5950 echo "$as_me:5950: result: $samba_cv_immediate_structures" >&5
5951 echo "${ECHO_T}$samba_cv_immediate_structures" >&6
5952 if test x"$samba_cv_immediate_structures" = x"yes"; then
5953    cat >>confdefs.h <<\EOF
5954 #define HAVE_IMMEDIATE_STRUCTURES 1
5955 EOF
5956
5957 fi
5958
5959 ############################################
5960 # check for unix domain sockets
5961 echo "$as_me:5961: checking for unix domain sockets" >&5
5962 echo $ECHO_N "checking for unix domain sockets... $ECHO_C" >&6
5963 if test "${samba_cv_unixsocket+set}" = set; then
5964   echo $ECHO_N "(cached) $ECHO_C" >&6
5965 else
5966
5967     cat >conftest.$ac_ext <<_ACEOF
5968 #line 5968 "configure"
5969 #include "confdefs.h"
5970
5971 #include <sys/types.h>
5972 #include <stdlib.h>
5973 #include <stddef.h>
5974 #include <sys/socket.h>
5975 #include <sys/un.h>
5976 int
5977 main ()
5978 {
5979
5980   struct sockaddr_un sunaddr;
5981   sunaddr.sun_family = AF_UNIX;
5982
5983   ;
5984   return 0;
5985 }
5986 _ACEOF
5987 rm -f conftest.$ac_objext
5988 if { (eval echo "$as_me:5988: \"$ac_compile\"") >&5
5989   (eval $ac_compile) 2>&5
5990   ac_status=$?
5991   echo "$as_me:5991: \$? = $ac_status" >&5
5992   (exit $ac_status); } &&
5993          { ac_try='test -s conftest.$ac_objext'
5994   { (eval echo "$as_me:5994: \"$ac_try\"") >&5
5995   (eval $ac_try) 2>&5
5996   ac_status=$?
5997   echo "$as_me:5997: \$? = $ac_status" >&5
5998   (exit $ac_status); }; }; then
5999   samba_cv_unixsocket=yes
6000 else
6001   echo "$as_me: failed program was:" >&5
6002 cat conftest.$ac_ext >&5
6003 samba_cv_unixsocket=no
6004 fi
6005 rm -f conftest.$ac_objext conftest.$ac_ext
6006 fi
6007 echo "$as_me:6007: result: $samba_cv_unixsocket" >&5
6008 echo "${ECHO_T}$samba_cv_unixsocket" >&6
6009 if test x"$samba_cv_unixsocket" = x"yes"; then
6010    cat >>confdefs.h <<\EOF
6011 #define HAVE_UNIXSOCKET 1
6012 EOF
6013
6014 fi
6015
6016 echo "$as_me:6016: checking for socklen_t type" >&5
6017 echo $ECHO_N "checking for socklen_t type... $ECHO_C" >&6
6018 if test "${samba_cv_socklen_t+set}" = set; then
6019   echo $ECHO_N "(cached) $ECHO_C" >&6
6020 else
6021
6022     cat >conftest.$ac_ext <<_ACEOF
6023 #line 6023 "configure"
6024 #include "confdefs.h"
6025
6026 #include <sys/types.h>
6027 #if STDC_HEADERS
6028 #include <stdlib.h>
6029 #include <stddef.h>
6030 #endif
6031 #include <sys/socket.h>
6032 int
6033 main ()
6034 {
6035 socklen_t i = 0
6036   ;
6037   return 0;
6038 }
6039 _ACEOF
6040 rm -f conftest.$ac_objext
6041 if { (eval echo "$as_me:6041: \"$ac_compile\"") >&5
6042   (eval $ac_compile) 2>&5
6043   ac_status=$?
6044   echo "$as_me:6044: \$? = $ac_status" >&5
6045   (exit $ac_status); } &&
6046          { ac_try='test -s conftest.$ac_objext'
6047   { (eval echo "$as_me:6047: \"$ac_try\"") >&5
6048   (eval $ac_try) 2>&5
6049   ac_status=$?
6050   echo "$as_me:6050: \$? = $ac_status" >&5
6051   (exit $ac_status); }; }; then
6052   samba_cv_socklen_t=yes
6053 else
6054   echo "$as_me: failed program was:" >&5
6055 cat conftest.$ac_ext >&5
6056 samba_cv_socklen_t=no
6057 fi
6058 rm -f conftest.$ac_objext conftest.$ac_ext
6059 fi
6060 echo "$as_me:6060: result: $samba_cv_socklen_t" >&5
6061 echo "${ECHO_T}$samba_cv_socklen_t" >&6
6062 if test x"$samba_cv_socklen_t" = x"yes"; then
6063    cat >>confdefs.h <<\EOF
6064 #define HAVE_SOCKLEN_T_TYPE 1
6065 EOF
6066
6067 fi
6068
6069 echo "$as_me:6069: checking for sig_atomic_t type" >&5
6070 echo $ECHO_N "checking for sig_atomic_t type... $ECHO_C" >&6
6071 if test "${samba_cv_sig_atomic_t+set}" = set; then
6072   echo $ECHO_N "(cached) $ECHO_C" >&6
6073 else
6074
6075     cat >conftest.$ac_ext <<_ACEOF
6076 #line 6076 "configure"
6077 #include "confdefs.h"
6078
6079 #include <sys/types.h>
6080 #if STDC_HEADERS
6081 #include <stdlib.h>
6082 #include <stddef.h>
6083 #endif
6084 #include <signal.h>
6085 int
6086 main ()
6087 {
6088 sig_atomic_t i = 0
6089   ;
6090   return 0;
6091 }
6092 _ACEOF
6093 rm -f conftest.$ac_objext
6094 if { (eval echo "$as_me:6094: \"$ac_compile\"") >&5
6095   (eval $ac_compile) 2>&5
6096   ac_status=$?
6097   echo "$as_me:6097: \$? = $ac_status" >&5
6098   (exit $ac_status); } &&
6099          { ac_try='test -s conftest.$ac_objext'
6100   { (eval echo "$as_me:6100: \"$ac_try\"") >&5
6101   (eval $ac_try) 2>&5
6102   ac_status=$?
6103   echo "$as_me:6103: \$? = $ac_status" >&5
6104   (exit $ac_status); }; }; then
6105   samba_cv_sig_atomic_t=yes
6106 else
6107   echo "$as_me: failed program was:" >&5
6108 cat conftest.$ac_ext >&5
6109 samba_cv_sig_atomic_t=no
6110 fi
6111 rm -f conftest.$ac_objext conftest.$ac_ext
6112 fi
6113 echo "$as_me:6113: result: $samba_cv_sig_atomic_t" >&5
6114 echo "${ECHO_T}$samba_cv_sig_atomic_t" >&6
6115 if test x"$samba_cv_sig_atomic_t" = x"yes"; then
6116    cat >>confdefs.h <<\EOF
6117 #define HAVE_SIG_ATOMIC_T_TYPE 1
6118 EOF
6119
6120 fi
6121
6122 # stupid headers have the functions but no declaration. grrrr.
6123
6124  echo "$as_me:6124: checking for errno declaration" >&5
6125 echo $ECHO_N "checking for errno declaration... $ECHO_C" >&6
6126 if test "${ac_cv_have_errno_decl+set}" = set; then
6127   echo $ECHO_N "(cached) $ECHO_C" >&6
6128 else
6129
6130     cat >conftest.$ac_ext <<_ACEOF
6131 #line 6131 "configure"
6132 #include "confdefs.h"
6133 #include <errno.h>
6134 int
6135 main ()
6136 {
6137 int i = (int)errno
6138   ;
6139   return 0;
6140 }
6141 _ACEOF
6142 rm -f conftest.$ac_objext
6143 if { (eval echo "$as_me:6143: \"$ac_compile\"") >&5
6144   (eval $ac_compile) 2>&5
6145   ac_status=$?
6146   echo "$as_me:6146: \$? = $ac_status" >&5
6147   (exit $ac_status); } &&
6148          { ac_try='test -s conftest.$ac_objext'
6149   { (eval echo "$as_me:6149: \"$ac_try\"") >&5
6150   (eval $ac_try) 2>&5
6151   ac_status=$?
6152   echo "$as_me:6152: \$? = $ac_status" >&5
6153   (exit $ac_status); }; }; then
6154   ac_cv_have_errno_decl=yes
6155 else
6156   echo "$as_me: failed program was:" >&5
6157 cat conftest.$ac_ext >&5
6158 ac_cv_have_errno_decl=no
6159 fi
6160 rm -f conftest.$ac_objext conftest.$ac_ext
6161 fi
6162 echo "$as_me:6162: result: $ac_cv_have_errno_decl" >&5
6163 echo "${ECHO_T}$ac_cv_have_errno_decl" >&6
6164  if test x"$ac_cv_have_errno_decl" = x"yes"; then
6165     cat >>confdefs.h <<\EOF
6166 #define HAVE_ERRNO_DECL 1
6167 EOF
6168
6169  fi
6170
6171  echo "$as_me:6171: checking for setresuid declaration" >&5
6172 echo $ECHO_N "checking for setresuid declaration... $ECHO_C" >&6
6173 if test "${ac_cv_have_setresuid_decl+set}" = set; then
6174   echo $ECHO_N "(cached) $ECHO_C" >&6
6175 else
6176
6177     cat >conftest.$ac_ext <<_ACEOF
6178 #line 6178 "configure"
6179 #include "confdefs.h"
6180 #include <unistd.h>
6181 int
6182 main ()
6183 {
6184 int i = (int)setresuid
6185   ;
6186   return 0;
6187 }
6188 _ACEOF
6189 rm -f conftest.$ac_objext
6190 if { (eval echo "$as_me:6190: \"$ac_compile\"") >&5
6191   (eval $ac_compile) 2>&5
6192   ac_status=$?
6193   echo "$as_me:6193: \$? = $ac_status" >&5
6194   (exit $ac_status); } &&
6195          { ac_try='test -s conftest.$ac_objext'
6196   { (eval echo "$as_me:6196: \"$ac_try\"") >&5
6197   (eval $ac_try) 2>&5
6198   ac_status=$?
6199   echo "$as_me:6199: \$? = $ac_status" >&5
6200   (exit $ac_status); }; }; then
6201   ac_cv_have_setresuid_decl=yes
6202 else
6203   echo "$as_me: failed program was:" >&5
6204 cat conftest.$ac_ext >&5
6205 ac_cv_have_setresuid_decl=no
6206 fi
6207 rm -f conftest.$ac_objext conftest.$ac_ext
6208 fi
6209 echo "$as_me:6209: result: $ac_cv_have_setresuid_decl" >&5
6210 echo "${ECHO_T}$ac_cv_have_setresuid_decl" >&6
6211  if test x"$ac_cv_have_setresuid_decl" = x"yes"; then
6212     cat >>confdefs.h <<\EOF
6213 #define HAVE_SETRESUID_DECL 1
6214 EOF
6215
6216  fi
6217
6218  echo "$as_me:6218: checking for setresgid declaration" >&5
6219 echo $ECHO_N "checking for setresgid declaration... $ECHO_C" >&6
6220 if test "${ac_cv_have_setresgid_decl+set}" = set; then
6221   echo $ECHO_N "(cached) $ECHO_C" >&6
6222 else
6223
6224     cat >conftest.$ac_ext <<_ACEOF
6225 #line 6225 "configure"
6226 #include "confdefs.h"
6227 #include <unistd.h>
6228 int
6229 main ()
6230 {
6231 int i = (int)setresgid
6232   ;
6233   return 0;
6234 }
6235 _ACEOF
6236 rm -f conftest.$ac_objext
6237 if { (eval echo "$as_me:6237: \"$ac_compile\"") >&5
6238   (eval $ac_compile) 2>&5
6239   ac_status=$?
6240   echo "$as_me:6240: \$? = $ac_status" >&5
6241   (exit $ac_status); } &&
6242          { ac_try='test -s conftest.$ac_objext'
6243   { (eval echo "$as_me:6243: \"$ac_try\"") >&5
6244   (eval $ac_try) 2>&5
6245   ac_status=$?
6246   echo "$as_me:6246: \$? = $ac_status" >&5
6247   (exit $ac_status); }; }; then
6248   ac_cv_have_setresgid_decl=yes
6249 else
6250   echo "$as_me: failed program was:" >&5
6251 cat conftest.$ac_ext >&5
6252 ac_cv_have_setresgid_decl=no
6253 fi
6254 rm -f conftest.$ac_objext conftest.$ac_ext
6255 fi
6256 echo "$as_me:6256: result: $ac_cv_have_setresgid_decl" >&5
6257 echo "${ECHO_T}$ac_cv_have_setresgid_decl" >&6
6258  if test x"$ac_cv_have_setresgid_decl" = x"yes"; then
6259     cat >>confdefs.h <<\EOF
6260 #define HAVE_SETRESGID_DECL 1
6261 EOF
6262
6263  fi
6264
6265  echo "$as_me:6265: checking for asprintf declaration" >&5
6266 echo $ECHO_N "checking for asprintf declaration... $ECHO_C" >&6
6267 if test "${ac_cv_have_asprintf_decl+set}" = set; then
6268   echo $ECHO_N "(cached) $ECHO_C" >&6
6269 else
6270
6271     cat >conftest.$ac_ext <<_ACEOF
6272 #line 6272 "configure"
6273 #include "confdefs.h"
6274 #include <stdio.h>
6275 int
6276 main ()
6277 {
6278 int i = (int)asprintf
6279   ;
6280   return 0;
6281 }
6282 _ACEOF
6283 rm -f conftest.$ac_objext
6284 if { (eval echo "$as_me:6284: \"$ac_compile\"") >&5
6285   (eval $ac_compile) 2>&5
6286   ac_status=$?
6287   echo "$as_me:6287: \$? = $ac_status" >&5
6288   (exit $ac_status); } &&
6289          { ac_try='test -s conftest.$ac_objext'
6290   { (eval echo "$as_me:6290: \"$ac_try\"") >&5
6291   (eval $ac_try) 2>&5
6292   ac_status=$?
6293   echo "$as_me:6293: \$? = $ac_status" >&5
6294   (exit $ac_status); }; }; then
6295   ac_cv_have_asprintf_decl=yes
6296 else
6297   echo "$as_me: failed program was:" >&5
6298 cat conftest.$ac_ext >&5
6299 ac_cv_have_asprintf_decl=no
6300 fi
6301 rm -f conftest.$ac_objext conftest.$ac_ext
6302 fi
6303 echo "$as_me:6303: result: $ac_cv_have_asprintf_decl" >&5
6304 echo "${ECHO_T}$ac_cv_have_asprintf_decl" >&6
6305  if test x"$ac_cv_have_asprintf_decl" = x"yes"; then
6306     cat >>confdefs.h <<\EOF
6307 #define HAVE_ASPRINTF_DECL 1
6308 EOF
6309
6310  fi
6311
6312  echo "$as_me:6312: checking for vasprintf declaration" >&5
6313 echo $ECHO_N "checking for vasprintf declaration... $ECHO_C" >&6
6314 if test "${ac_cv_have_vasprintf_decl+set}" = set; then
6315   echo $ECHO_N "(cached) $ECHO_C" >&6
6316 else
6317
6318     cat >conftest.$ac_ext <<_ACEOF
6319 #line 6319 "configure"
6320 #include "confdefs.h"
6321 #include <stdio.h>
6322 int
6323 main ()
6324 {
6325 int i = (int)vasprintf
6326   ;
6327   return 0;
6328 }
6329 _ACEOF
6330 rm -f conftest.$ac_objext
6331 if { (eval echo "$as_me:6331: \"$ac_compile\"") >&5
6332   (eval $ac_compile) 2>&5
6333   ac_status=$?
6334   echo "$as_me:6334: \$? = $ac_status" >&5
6335   (exit $ac_status); } &&
6336          { ac_try='test -s conftest.$ac_objext'
6337   { (eval echo "$as_me:6337: \"$ac_try\"") >&5
6338   (eval $ac_try) 2>&5
6339   ac_status=$?
6340   echo "$as_me:6340: \$? = $ac_status" >&5
6341   (exit $ac_status); }; }; then
6342   ac_cv_have_vasprintf_decl=yes
6343 else
6344   echo "$as_me: failed program was:" >&5
6345 cat conftest.$ac_ext >&5
6346 ac_cv_have_vasprintf_decl=no
6347 fi
6348 rm -f conftest.$ac_objext conftest.$ac_ext
6349 fi
6350 echo "$as_me:6350: result: $ac_cv_have_vasprintf_decl" >&5
6351 echo "${ECHO_T}$ac_cv_have_vasprintf_decl" >&6
6352  if test x"$ac_cv_have_vasprintf_decl" = x"yes"; then
6353     cat >>confdefs.h <<\EOF
6354 #define HAVE_VASPRINTF_DECL 1
6355 EOF
6356
6357  fi
6358
6359  echo "$as_me:6359: checking for vsnprintf declaration" >&5
6360 echo $ECHO_N "checking for vsnprintf declaration... $ECHO_C" >&6
6361 if test "${ac_cv_have_vsnprintf_decl+set}" = set; then
6362   echo $ECHO_N "(cached) $ECHO_C" >&6
6363 else
6364
6365     cat >conftest.$ac_ext <<_ACEOF
6366 #line 6366 "configure"
6367 #include "confdefs.h"
6368 #include <stdio.h>
6369 int
6370 main ()
6371 {
6372 int i = (int)vsnprintf
6373   ;
6374   return 0;
6375 }
6376 _ACEOF
6377 rm -f conftest.$ac_objext
6378 if { (eval echo "$as_me:6378: \"$ac_compile\"") >&5
6379   (eval $ac_compile) 2>&5
6380   ac_status=$?
6381   echo "$as_me:6381: \$? = $ac_status" >&5
6382   (exit $ac_status); } &&
6383          { ac_try='test -s conftest.$ac_objext'
6384   { (eval echo "$as_me:6384: \"$ac_try\"") >&5
6385   (eval $ac_try) 2>&5
6386   ac_status=$?
6387   echo "$as_me:6387: \$? = $ac_status" >&5
6388   (exit $ac_status); }; }; then
6389   ac_cv_have_vsnprintf_decl=yes
6390 else
6391   echo "$as_me: failed program was:" >&5
6392 cat conftest.$ac_ext >&5
6393 ac_cv_have_vsnprintf_decl=no
6394 fi
6395 rm -f conftest.$ac_objext conftest.$ac_ext
6396 fi
6397 echo "$as_me:6397: result: $ac_cv_have_vsnprintf_decl" >&5
6398 echo "${ECHO_T}$ac_cv_have_vsnprintf_decl" >&6
6399  if test x"$ac_cv_have_vsnprintf_decl" = x"yes"; then
6400     cat >>confdefs.h <<\EOF
6401 #define HAVE_VSNPRINTF_DECL 1
6402 EOF
6403
6404  fi
6405
6406  echo "$as_me:6406: checking for snprintf declaration" >&5
6407 echo $ECHO_N "checking for snprintf declaration... $ECHO_C" >&6
6408 if test "${ac_cv_have_snprintf_decl+set}" = set; then
6409   echo $ECHO_N "(cached) $ECHO_C" >&6
6410 else
6411
6412     cat >conftest.$ac_ext <<_ACEOF
6413 #line 6413 "configure"
6414 #include "confdefs.h"
6415 #include <stdio.h>
6416 int
6417 main ()
6418 {
6419 int i = (int)snprintf
6420   ;
6421   return 0;
6422 }
6423 _ACEOF
6424 rm -f conftest.$ac_objext
6425 if { (eval echo "$as_me:6425: \"$ac_compile\"") >&5
6426   (eval $ac_compile) 2>&5
6427   ac_status=$?
6428   echo "$as_me:6428: \$? = $ac_status" >&5
6429   (exit $ac_status); } &&
6430          { ac_try='test -s conftest.$ac_objext'
6431   { (eval echo "$as_me:6431: \"$ac_try\"") >&5
6432   (eval $ac_try) 2>&5
6433   ac_status=$?
6434   echo "$as_me:6434: \$? = $ac_status" >&5
6435   (exit $ac_status); }; }; then
6436   ac_cv_have_snprintf_decl=yes
6437 else
6438   echo "$as_me: failed program was:" >&5
6439 cat conftest.$ac_ext >&5
6440 ac_cv_have_snprintf_decl=no
6441 fi
6442 rm -f conftest.$ac_objext conftest.$ac_ext
6443 fi
6444 echo "$as_me:6444: result: $ac_cv_have_snprintf_decl" >&5
6445 echo "${ECHO_T}$ac_cv_have_snprintf_decl" >&6
6446  if test x"$ac_cv_have_snprintf_decl" = x"yes"; then
6447     cat >>confdefs.h <<\EOF
6448 #define HAVE_SNPRINTF_DECL 1
6449 EOF
6450
6451  fi
6452
6453 # and glibc has setresuid under linux but the function does
6454 # nothing until kernel 2.1.44! very dumb.
6455 echo "$as_me:6455: checking for real setresuid" >&5
6456 echo $ECHO_N "checking for real setresuid... $ECHO_C" >&6
6457 if test "${samba_cv_have_setresuid+set}" = set; then
6458   echo $ECHO_N "(cached) $ECHO_C" >&6
6459 else
6460
6461     if test "$cross_compiling" = yes; then
6462   samba_cv_have_setresuid=cross
6463 else
6464   cat >conftest.$ac_ext <<_ACEOF
6465 #line 6465 "configure"
6466 #include "confdefs.h"
6467 #include <errno.h>
6468 main() { setresuid(1,1,1); setresuid(2,2,2); exit(errno==EPERM?0:1);}
6469 _ACEOF
6470 rm -f conftest$ac_exeext
6471 if { (eval echo "$as_me:6471: \"$ac_link\"") >&5
6472   (eval $ac_link) 2>&5
6473   ac_status=$?
6474   echo "$as_me:6474: \$? = $ac_status" >&5
6475   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6476   { (eval echo "$as_me:6476: \"$ac_try\"") >&5
6477   (eval $ac_try) 2>&5
6478   ac_status=$?
6479   echo "$as_me:6479: \$? = $ac_status" >&5
6480   (exit $ac_status); }; }; then
6481   samba_cv_have_setresuid=yes
6482 else
6483   echo "$as_me: program exited with status $ac_status" >&5
6484 echo "$as_me: failed program was:" >&5
6485 cat conftest.$ac_ext >&5
6486 samba_cv_have_setresuid=no
6487 fi
6488 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6489 fi
6490 fi
6491 echo "$as_me:6491: result: $samba_cv_have_setresuid" >&5
6492 echo "${ECHO_T}$samba_cv_have_setresuid" >&6
6493 if test x"$samba_cv_have_setresuid" = x"yes"; then
6494     cat >>confdefs.h <<\EOF
6495 #define HAVE_SETRESUID 1
6496 EOF
6497
6498 fi
6499
6500 # Do the same check for setresguid...
6501 #
6502 echo "$as_me:6502: checking for real setresgid" >&5
6503 echo $ECHO_N "checking for real setresgid... $ECHO_C" >&6
6504 if test "${samba_cv_have_setresgid+set}" = set; then
6505   echo $ECHO_N "(cached) $ECHO_C" >&6
6506 else
6507
6508     if test "$cross_compiling" = yes; then
6509   samba_cv_have_setresgid=cross
6510 else
6511   cat >conftest.$ac_ext <<_ACEOF
6512 #line 6512 "configure"
6513 #include "confdefs.h"
6514 #include <unistd.h>
6515 #include <errno.h>
6516 main() { errno = 0; setresgid(1,1,1); exit(errno != 0 ? (errno==EPERM ? 0 : 1) : 0);}
6517 _ACEOF
6518 rm -f conftest$ac_exeext
6519 if { (eval echo "$as_me:6519: \"$ac_link\"") >&5
6520   (eval $ac_link) 2>&5
6521   ac_status=$?
6522   echo "$as_me:6522: \$? = $ac_status" >&5
6523   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6524   { (eval echo "$as_me:6524: \"$ac_try\"") >&5
6525   (eval $ac_try) 2>&5
6526   ac_status=$?
6527   echo "$as_me:6527: \$? = $ac_status" >&5
6528   (exit $ac_status); }; }; then
6529   samba_cv_have_setresgid=yes
6530 else
6531   echo "$as_me: program exited with status $ac_status" >&5
6532 echo "$as_me: failed program was:" >&5
6533 cat conftest.$ac_ext >&5
6534 samba_cv_have_setresgid=no
6535 fi
6536 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6537 fi
6538 fi
6539 echo "$as_me:6539: result: $samba_cv_have_setresgid" >&5
6540 echo "${ECHO_T}$samba_cv_have_setresgid" >&6
6541 if test x"$samba_cv_have_setresgid" = x"yes"; then
6542     cat >>confdefs.h <<\EOF
6543 #define HAVE_SETRESGID 1
6544 EOF
6545
6546 fi
6547
6548 echo "$as_me:6548: checking for working memcmp" >&5
6549 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
6550 if test "${ac_cv_func_memcmp_working+set}" = set; then
6551   echo $ECHO_N "(cached) $ECHO_C" >&6
6552 else
6553   if test "$cross_compiling" = yes; then
6554   ac_cv_func_memcmp_working=no
6555 else
6556   cat >conftest.$ac_ext <<_ACEOF
6557 #line 6557 "configure"
6558 #include "confdefs.h"
6559
6560 int
6561 main ()
6562 {
6563
6564   /* Some versions of memcmp are not 8-bit clean.  */
6565   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
6566   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
6567     exit (1);
6568
6569   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
6570      or more and with at least one buffer not starting on a 4-byte boundary.
6571      William Lewis provided this test program.   */
6572   {
6573     char foo[21];
6574     char bar[21];
6575     int i;
6576     for (i = 0; i < 4; i++)
6577       {
6578         char *a = foo + i;
6579         char *b = bar + i;
6580         strcpy (a, "--------01111111");
6581         strcpy (b, "--------10000000");
6582         if (memcmp (a, b, 16) >= 0)
6583           exit (1);
6584       }
6585     exit (0);
6586   }
6587
6588   ;
6589   return 0;
6590 }
6591 _ACEOF
6592 rm -f conftest$ac_exeext
6593 if { (eval echo "$as_me:6593: \"$ac_link\"") >&5
6594   (eval $ac_link) 2>&5
6595   ac_status=$?
6596   echo "$as_me:6596: \$? = $ac_status" >&5
6597   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6598   { (eval echo "$as_me:6598: \"$ac_try\"") >&5
6599   (eval $ac_try) 2>&5
6600   ac_status=$?
6601   echo "$as_me:6601: \$? = $ac_status" >&5
6602   (exit $ac_status); }; }; then
6603   ac_cv_func_memcmp_working=yes
6604 else
6605   echo "$as_me: program exited with status $ac_status" >&5
6606 echo "$as_me: failed program was:" >&5
6607 cat conftest.$ac_ext >&5
6608 ac_cv_func_memcmp_working=no
6609 fi
6610 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6611 fi
6612 fi
6613 echo "$as_me:6613: result: $ac_cv_func_memcmp_working" >&5
6614 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
6615 test $ac_cv_func_memcmp_working = no && LIBOBJS="$LIBOBJS memcmp.$ac_objext"
6616
6617 ###############################################
6618 # test for where we get crypt() from
6619
6620 for ac_func in crypt
6621 do
6622 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
6623 echo "$as_me:6623: checking for $ac_func" >&5
6624 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
6625 if eval "test \"\${$as_ac_var+set}\" = set"; then
6626   echo $ECHO_N "(cached) $ECHO_C" >&6
6627 else
6628   cat >conftest.$ac_ext <<_ACEOF
6629 #line 6629 "configure"
6630 #include "confdefs.h"
6631 /* System header to define __stub macros and hopefully few prototypes,
6632     which can conflict with char $ac_func (); below.  */
6633 #include <assert.h>
6634 /* Override any gcc2 internal prototype to avoid an error.  */
6635 #ifdef __cplusplus
6636 extern "C"
6637 #endif
6638 /* We use char because int might match the return type of a gcc2
6639    builtin and then its argument prototype would still apply.  */
6640 char $ac_func ();
6641 char (*f) ();
6642
6643 int
6644 main ()
6645 {
6646 /* The GNU C library defines this for functions which it implements
6647     to always fail with ENOSYS.  Some functions are actually named
6648     something starting with __ and the normal name is an alias.  */
6649 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6650 choke me
6651 #else
6652 f = $ac_func;
6653 #endif
6654
6655   ;
6656   return 0;
6657 }
6658 _ACEOF
6659 rm -f conftest.$ac_objext conftest$ac_exeext
6660 if { (eval echo "$as_me:6660: \"$ac_link\"") >&5
6661   (eval $ac_link) 2>&5
6662   ac_status=$?
6663   echo "$as_me:6663: \$? = $ac_status" >&5
6664   (exit $ac_status); } &&
6665          { ac_try='test -s conftest$ac_exeext'
6666   { (eval echo "$as_me:6666: \"$ac_try\"") >&5
6667   (eval $ac_try) 2>&5
6668   ac_status=$?
6669   echo "$as_me:6669: \$? = $ac_status" >&5
6670   (exit $ac_status); }; }; then
6671   eval "$as_ac_var=yes"
6672 else
6673   echo "$as_me: failed program was:" >&5
6674 cat conftest.$ac_ext >&5
6675 eval "$as_ac_var=no"
6676 fi
6677 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6678 fi
6679 echo "$as_me:6679: result: `eval echo '${'$as_ac_var'}'`" >&5
6680 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
6681 if test `eval echo '${'$as_ac_var'}'` = yes; then
6682   cat >>confdefs.h <<EOF
6683 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
6684 EOF
6685
6686 fi
6687 done
6688
6689 if test x"$ac_cv_func_crypt" = x"no"; then
6690     echo "$as_me:6690: checking for crypt in -lcrypt" >&5
6691 echo $ECHO_N "checking for crypt in -lcrypt... $ECHO_C" >&6
6692 if test "${ac_cv_lib_crypt_crypt+set}" = set; then
6693   echo $ECHO_N "(cached) $ECHO_C" >&6
6694 else
6695   ac_check_lib_save_LIBS=$LIBS
6696 LIBS="-lcrypt  $LIBS"
6697 cat >conftest.$ac_ext <<_ACEOF
6698 #line 6698 "configure"
6699 #include "confdefs.h"
6700
6701 /* Override any gcc2 internal prototype to avoid an error.  */
6702 #ifdef __cplusplus
6703 extern "C"
6704 #endif
6705 /* We use char because int might match the return type of a gcc2
6706    builtin and then its argument prototype would still apply.  */
6707 char crypt ();
6708 int
6709 main ()
6710 {
6711 crypt ();
6712   ;
6713   return 0;
6714 }
6715 _ACEOF
6716 rm -f conftest.$ac_objext conftest$ac_exeext
6717 if { (eval echo "$as_me:6717: \"$ac_link\"") >&5
6718   (eval $ac_link) 2>&5
6719   ac_status=$?
6720   echo "$as_me:6720: \$? = $ac_status" >&5
6721   (exit $ac_status); } &&
6722          { ac_try='test -s conftest$ac_exeext'
6723   { (eval echo "$as_me:6723: \"$ac_try\"") >&5
6724   (eval $ac_try) 2>&5
6725   ac_status=$?
6726   echo "$as_me:6726: \$? = $ac_status" >&5
6727   (exit $ac_status); }; }; then
6728   ac_cv_lib_crypt_crypt=yes
6729 else
6730   echo "$as_me: failed program was:" >&5
6731 cat conftest.$ac_ext >&5
6732 ac_cv_lib_crypt_crypt=no
6733 fi
6734 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6735 LIBS=$ac_check_lib_save_LIBS
6736 fi
6737 echo "$as_me:6737: result: $ac_cv_lib_crypt_crypt" >&5
6738 echo "${ECHO_T}$ac_cv_lib_crypt_crypt" >&6
6739 if test $ac_cv_lib_crypt_crypt = yes; then
6740   LIBS="$LIBS -lcrypt";
6741         cat >>confdefs.h <<\EOF
6742 #define HAVE_CRYPT 1
6743 EOF
6744
6745 fi
6746
6747 fi
6748
6749 ###############################################
6750 # Readline included by default unless explicitly asked not to
6751 test "${with_readline+set}" != "set" && with_readline=yes
6752
6753 # test for where we get readline() from
6754 echo "$as_me:6754: checking whether to use readline" >&5
6755 echo $ECHO_N "checking whether to use readline... $ECHO_C" >&6
6756
6757 # Check whether --with-readline or --without-readline was given.
6758 if test "${with_readline+set}" = set; then
6759   withval="$with_readline"
6760     case "$with_readline" in
6761   yes)
6762     echo "$as_me:6762: result: yes" >&5
6763 echo "${ECHO_T}yes" >&6
6764
6765 for ac_header in readline.h history.h readline/readline.h
6766 do
6767 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6768 echo "$as_me:6768: checking for $ac_header" >&5
6769 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6770 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6771   echo $ECHO_N "(cached) $ECHO_C" >&6
6772 else
6773   cat >conftest.$ac_ext <<_ACEOF
6774 #line 6774 "configure"
6775 #include "confdefs.h"
6776 #include <$ac_header>
6777 _ACEOF
6778 if { (eval echo "$as_me:6778: \"$ac_cpp conftest.$ac_ext\"") >&5
6779   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6780   ac_status=$?
6781   egrep -v '^ *\+' conftest.er1 >conftest.err
6782   rm -f conftest.er1
6783   cat conftest.err >&5
6784   echo "$as_me:6784: \$? = $ac_status" >&5
6785   (exit $ac_status); } >/dev/null; then
6786   if test -s conftest.err; then
6787     ac_cpp_err=$ac_c_preproc_warn_flag
6788   else
6789     ac_cpp_err=
6790   fi
6791 else
6792   ac_cpp_err=yes
6793 fi
6794 if test -z "$ac_cpp_err"; then
6795   eval "$as_ac_Header=yes"
6796 else
6797   echo "$as_me: failed program was:" >&5
6798   cat conftest.$ac_ext >&5
6799   eval "$as_ac_Header=no"
6800 fi
6801 rm -f conftest.err conftest.$ac_ext
6802 fi
6803 echo "$as_me:6803: result: `eval echo '${'$as_ac_Header'}'`" >&5
6804 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6805 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6806   cat >>confdefs.h <<EOF
6807 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6808 EOF
6809
6810 fi
6811 done
6812
6813 for ac_header in readline/history.h
6814 do
6815 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6816 echo "$as_me:6816: checking for $ac_header" >&5
6817 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6818 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6819   echo $ECHO_N "(cached) $ECHO_C" >&6
6820 else
6821   cat >conftest.$ac_ext <<_ACEOF
6822 #line 6822 "configure"
6823 #include "confdefs.h"
6824 #include <$ac_header>
6825 _ACEOF
6826 if { (eval echo "$as_me:6826: \"$ac_cpp conftest.$ac_ext\"") >&5
6827   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6828   ac_status=$?
6829   egrep -v '^ *\+' conftest.er1 >conftest.err
6830   rm -f conftest.er1
6831   cat conftest.err >&5
6832   echo "$as_me:6832: \$? = $ac_status" >&5
6833   (exit $ac_status); } >/dev/null; then
6834   if test -s conftest.err; then
6835     ac_cpp_err=$ac_c_preproc_warn_flag
6836   else
6837     ac_cpp_err=
6838   fi
6839 else
6840   ac_cpp_err=yes
6841 fi
6842 if test -z "$ac_cpp_err"; then
6843   eval "$as_ac_Header=yes"
6844 else
6845   echo "$as_me: failed program was:" >&5
6846   cat conftest.$ac_ext >&5
6847   eval "$as_ac_Header=no"
6848 fi
6849 rm -f conftest.err conftest.$ac_ext
6850 fi
6851 echo "$as_me:6851: result: `eval echo '${'$as_ac_Header'}'`" >&5
6852 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6853 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6854   cat >>confdefs.h <<EOF
6855 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6856 EOF
6857
6858 fi
6859 done
6860
6861 for ac_header in readline.h readline/readline.h
6862 do
6863 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6864 echo "$as_me:6864: checking for $ac_header" >&5
6865 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6866 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6867   echo $ECHO_N "(cached) $ECHO_C" >&6
6868 else
6869   cat >conftest.$ac_ext <<_ACEOF
6870 #line 6870 "configure"
6871 #include "confdefs.h"
6872 #include <$ac_header>
6873 _ACEOF
6874 if { (eval echo "$as_me:6874: \"$ac_cpp conftest.$ac_ext\"") >&5
6875   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6876   ac_status=$?
6877   egrep -v '^ *\+' conftest.er1 >conftest.err
6878   rm -f conftest.er1
6879   cat conftest.err >&5
6880   echo "$as_me:6880: \$? = $ac_status" >&5
6881   (exit $ac_status); } >/dev/null; then
6882   if test -s conftest.err; then
6883     ac_cpp_err=$ac_c_preproc_warn_flag
6884   else
6885     ac_cpp_err=
6886   fi
6887 else
6888   ac_cpp_err=yes
6889 fi
6890 if test -z "$ac_cpp_err"; then
6891   eval "$as_ac_Header=yes"
6892 else
6893   echo "$as_me: failed program was:" >&5
6894   cat conftest.$ac_ext >&5
6895   eval "$as_ac_Header=no"
6896 fi
6897 rm -f conftest.err conftest.$ac_ext
6898 fi
6899 echo "$as_me:6899: result: `eval echo '${'$as_ac_Header'}'`" >&5
6900 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6901 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6902   cat >>confdefs.h <<EOF
6903 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6904 EOF
6905
6906       for termlib in ncurses curses termcap terminfo termlib; do
6907        as_ac_Lib=`echo "ac_cv_lib_${termlib}''_tgetent" | $as_tr_sh`
6908 echo "$as_me:6908: checking for tgetent in -l${termlib}" >&5
6909 echo $ECHO_N "checking for tgetent in -l${termlib}... $ECHO_C" >&6
6910 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
6911   echo $ECHO_N "(cached) $ECHO_C" >&6
6912 else
6913   ac_check_lib_save_LIBS=$LIBS
6914 LIBS="-l${termlib}  $LIBS"
6915 cat >conftest.$ac_ext <<_ACEOF
6916 #line 6916 "configure"
6917 #include "confdefs.h"
6918
6919 /* Override any gcc2 internal prototype to avoid an error.  */
6920 #ifdef __cplusplus
6921 extern "C"
6922 #endif
6923 /* We use char because int might match the return type of a gcc2
6924    builtin and then its argument prototype would still apply.  */
6925 char tgetent ();
6926 int
6927 main ()
6928 {
6929 tgetent ();
6930   ;
6931   return 0;
6932 }
6933 _ACEOF
6934 rm -f conftest.$ac_objext conftest$ac_exeext
6935 if { (eval echo "$as_me:6935: \"$ac_link\"") >&5
6936   (eval $ac_link) 2>&5
6937   ac_status=$?
6938   echo "$as_me:6938: \$? = $ac_status" >&5
6939   (exit $ac_status); } &&
6940          { ac_try='test -s conftest$ac_exeext'
6941   { (eval echo "$as_me:6941: \"$ac_try\"") >&5
6942   (eval $ac_try) 2>&5
6943   ac_status=$?
6944   echo "$as_me:6944: \$? = $ac_status" >&5
6945   (exit $ac_status); }; }; then
6946   eval "$as_ac_Lib=yes"
6947 else
6948   echo "$as_me: failed program was:" >&5
6949 cat conftest.$ac_ext >&5
6950 eval "$as_ac_Lib=no"
6951 fi
6952 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6953 LIBS=$ac_check_lib_save_LIBS
6954 fi
6955 echo "$as_me:6955: result: `eval echo '${'$as_ac_Lib'}'`" >&5
6956 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
6957 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
6958   TERMLIBS="-l${termlib}"; break
6959 fi
6960
6961       done
6962       echo "$as_me:6962: checking for rl_callback_handler_install in -lreadline" >&5
6963 echo $ECHO_N "checking for rl_callback_handler_install in -lreadline... $ECHO_C" >&6
6964 if test "${ac_cv_lib_readline_rl_callback_handler_install+set}" = set; then
6965   echo $ECHO_N "(cached) $ECHO_C" >&6
6966 else
6967   ac_check_lib_save_LIBS=$LIBS
6968 LIBS="-lreadline $TERMLIBS $LIBS"
6969 cat >conftest.$ac_ext <<_ACEOF
6970 #line 6970 "configure"
6971 #include "confdefs.h"
6972
6973 /* Override any gcc2 internal prototype to avoid an error.  */
6974 #ifdef __cplusplus
6975 extern "C"
6976 #endif
6977 /* We use char because int might match the return type of a gcc2
6978    builtin and then its argument prototype would still apply.  */
6979 char rl_callback_handler_install ();
6980 int
6981 main ()
6982 {
6983 rl_callback_handler_install ();
6984   ;
6985   return 0;
6986 }
6987 _ACEOF
6988 rm -f conftest.$ac_objext conftest$ac_exeext
6989 if { (eval echo "$as_me:6989: \"$ac_link\"") >&5
6990   (eval $ac_link) 2>&5
6991   ac_status=$?
6992   echo "$as_me:6992: \$? = $ac_status" >&5
6993   (exit $ac_status); } &&
6994          { ac_try='test -s conftest$ac_exeext'
6995   { (eval echo "$as_me:6995: \"$ac_try\"") >&5
6996   (eval $ac_try) 2>&5
6997   ac_status=$?
6998   echo "$as_me:6998: \$? = $ac_status" >&5
6999   (exit $ac_status); }; }; then
7000   ac_cv_lib_readline_rl_callback_handler_install=yes
7001 else
7002   echo "$as_me: failed program was:" >&5
7003 cat conftest.$ac_ext >&5
7004 ac_cv_lib_readline_rl_callback_handler_install=no
7005 fi
7006 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7007 LIBS=$ac_check_lib_save_LIBS
7008 fi
7009 echo "$as_me:7009: result: $ac_cv_lib_readline_rl_callback_handler_install" >&5
7010 echo "${ECHO_T}$ac_cv_lib_readline_rl_callback_handler_install" >&6
7011 if test $ac_cv_lib_readline_rl_callback_handler_install = yes; then
7012   TERMLIBS="-lreadline $TERMLIBS"
7013        cat >>confdefs.h <<\EOF
7014 #define HAVE_LIBREADLINE 1
7015 EOF
7016
7017        break
7018 else
7019   TERMLIBS=
7020 fi
7021
7022 fi
7023 done
7024
7025     ;;
7026   no)
7027     echo "$as_me:7027: result: no" >&5
7028 echo "${ECHO_T}no" >&6
7029     ;;
7030   *)
7031     echo "$as_me:7031: result: yes" >&5
7032 echo "${ECHO_T}yes" >&6
7033
7034     # Needed for AC_CHECK_HEADERS and AC_CHECK_LIB to look at
7035     # alternate readline path
7036     _ldflags=${LDFLAGS}
7037     _cppflags=${CPPFLAGS}
7038
7039     # Add additional search path
7040     LDFLAGS="-L$with_readline/lib $LDFLAGS"
7041     CPPFLAGS="-I$with_readline/include $CPPFLAGS"
7042
7043 for ac_header in readline.h history.h readline/readline.h
7044 do
7045 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7046 echo "$as_me:7046: checking for $ac_header" >&5
7047 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7048 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7049   echo $ECHO_N "(cached) $ECHO_C" >&6
7050 else
7051   cat >conftest.$ac_ext <<_ACEOF
7052 #line 7052 "configure"
7053 #include "confdefs.h"
7054 #include <$ac_header>
7055 _ACEOF
7056 if { (eval echo "$as_me:7056: \"$ac_cpp conftest.$ac_ext\"") >&5
7057   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7058   ac_status=$?
7059   egrep -v '^ *\+' conftest.er1 >conftest.err
7060   rm -f conftest.er1
7061   cat conftest.err >&5
7062   echo "$as_me:7062: \$? = $ac_status" >&5
7063   (exit $ac_status); } >/dev/null; then
7064   if test -s conftest.err; then
7065     ac_cpp_err=$ac_c_preproc_warn_flag
7066   else
7067     ac_cpp_err=
7068   fi
7069 else
7070   ac_cpp_err=yes
7071 fi
7072 if test -z "$ac_cpp_err"; then
7073   eval "$as_ac_Header=yes"
7074 else
7075   echo "$as_me: failed program was:" >&5
7076   cat conftest.$ac_ext >&5
7077   eval "$as_ac_Header=no"
7078 fi
7079 rm -f conftest.err conftest.$ac_ext
7080 fi
7081 echo "$as_me:7081: result: `eval echo '${'$as_ac_Header'}'`" >&5
7082 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7083 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7084   cat >>confdefs.h <<EOF
7085 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7086 EOF
7087
7088 fi
7089 done
7090
7091 for ac_header in readline/history.h
7092 do
7093 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7094 echo "$as_me:7094: checking for $ac_header" >&5
7095 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7096 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7097   echo $ECHO_N "(cached) $ECHO_C" >&6
7098 else
7099   cat >conftest.$ac_ext <<_ACEOF
7100 #line 7100 "configure"
7101 #include "confdefs.h"
7102 #include <$ac_header>
7103 _ACEOF
7104 if { (eval echo "$as_me:7104: \"$ac_cpp conftest.$ac_ext\"") >&5
7105   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7106   ac_status=$?
7107   egrep -v '^ *\+' conftest.er1 >conftest.err
7108   rm -f conftest.er1
7109   cat conftest.err >&5
7110   echo "$as_me:7110: \$? = $ac_status" >&5
7111   (exit $ac_status); } >/dev/null; then
7112   if test -s conftest.err; then
7113     ac_cpp_err=$ac_c_preproc_warn_flag
7114   else
7115     ac_cpp_err=
7116   fi
7117 else
7118   ac_cpp_err=yes
7119 fi
7120 if test -z "$ac_cpp_err"; then
7121   eval "$as_ac_Header=yes"
7122 else
7123   echo "$as_me: failed program was:" >&5
7124   cat conftest.$ac_ext >&5
7125   eval "$as_ac_Header=no"
7126 fi
7127 rm -f conftest.err conftest.$ac_ext
7128 fi
7129 echo "$as_me:7129: result: `eval echo '${'$as_ac_Header'}'`" >&5
7130 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7131 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7132   cat >>confdefs.h <<EOF
7133 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7134 EOF
7135
7136 fi
7137 done
7138
7139 for ac_header in readline.h readline/readline.h
7140 do
7141 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7142 echo "$as_me:7142: checking for $ac_header" >&5
7143 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7144 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7145   echo $ECHO_N "(cached) $ECHO_C" >&6
7146 else
7147   cat >conftest.$ac_ext <<_ACEOF
7148 #line 7148 "configure"
7149 #include "confdefs.h"
7150 #include <$ac_header>
7151 _ACEOF
7152 if { (eval echo "$as_me:7152: \"$ac_cpp conftest.$ac_ext\"") >&5
7153   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7154   ac_status=$?
7155   egrep -v '^ *\+' conftest.er1 >conftest.err
7156   rm -f conftest.er1
7157   cat conftest.err >&5
7158   echo "$as_me:7158: \$? = $ac_status" >&5
7159   (exit $ac_status); } >/dev/null; then
7160   if test -s conftest.err; then
7161     ac_cpp_err=$ac_c_preproc_warn_flag
7162   else
7163     ac_cpp_err=
7164   fi
7165 else
7166   ac_cpp_err=yes
7167 fi
7168 if test -z "$ac_cpp_err"; then
7169   eval "$as_ac_Header=yes"
7170 else
7171   echo "$as_me: failed program was:" >&5
7172   cat conftest.$ac_ext >&5
7173   eval "$as_ac_Header=no"
7174 fi
7175 rm -f conftest.err conftest.$ac_ext
7176 fi
7177 echo "$as_me:7177: result: `eval echo '${'$as_ac_Header'}'`" >&5
7178 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7179 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7180   cat >>confdefs.h <<EOF
7181 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7182 EOF
7183
7184       for termlib in ncurses curses termcap terminfo termlib; do
7185        as_ac_Lib=`echo "ac_cv_lib_${termlib}''_tgetent" | $as_tr_sh`
7186 echo "$as_me:7186: checking for tgetent in -l${termlib}" >&5
7187 echo $ECHO_N "checking for tgetent in -l${termlib}... $ECHO_C" >&6
7188 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
7189   echo $ECHO_N "(cached) $ECHO_C" >&6
7190 else
7191   ac_check_lib_save_LIBS=$LIBS
7192 LIBS="-l${termlib}  $LIBS"
7193 cat >conftest.$ac_ext <<_ACEOF
7194 #line 7194 "configure"
7195 #include "confdefs.h"
7196
7197 /* Override any gcc2 internal prototype to avoid an error.  */
7198 #ifdef __cplusplus
7199 extern "C"
7200 #endif
7201 /* We use char because int might match the return type of a gcc2
7202    builtin and then its argument prototype would still apply.  */
7203 char tgetent ();
7204 int
7205 main ()
7206 {
7207 tgetent ();
7208   ;
7209   return 0;
7210 }
7211 _ACEOF
7212 rm -f conftest.$ac_objext conftest$ac_exeext
7213 if { (eval echo "$as_me:7213: \"$ac_link\"") >&5
7214   (eval $ac_link) 2>&5
7215   ac_status=$?
7216   echo "$as_me:7216: \$? = $ac_status" >&5
7217   (exit $ac_status); } &&
7218          { ac_try='test -s conftest$ac_exeext'
7219   { (eval echo "$as_me:7219: \"$ac_try\"") >&5
7220   (eval $ac_try) 2>&5
7221   ac_status=$?
7222   echo "$as_me:7222: \$? = $ac_status" >&5
7223   (exit $ac_status); }; }; then
7224   eval "$as_ac_Lib=yes"
7225 else
7226   echo "$as_me: failed program was:" >&5
7227 cat conftest.$ac_ext >&5
7228 eval "$as_ac_Lib=no"
7229 fi
7230 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7231 LIBS=$ac_check_lib_save_LIBS
7232 fi
7233 echo "$as_me:7233: result: `eval echo '${'$as_ac_Lib'}'`" >&5
7234 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
7235 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
7236   TERMLIBS="-l${termlib}"; break
7237 fi
7238
7239       done
7240       echo "$as_me:7240: checking for rl_callback_handler_install in -lreadline" >&5
7241 echo $ECHO_N "checking for rl_callback_handler_install in -lreadline... $ECHO_C" >&6
7242 if test "${ac_cv_lib_readline_rl_callback_handler_install+set}" = set; then
7243   echo $ECHO_N "(cached) $ECHO_C" >&6
7244 else
7245   ac_check_lib_save_LIBS=$LIBS
7246 LIBS="-lreadline $TERMLIBS $LIBS"
7247 cat >conftest.$ac_ext <<_ACEOF
7248 #line 7248 "configure"
7249 #include "confdefs.h"
7250
7251 /* Override any gcc2 internal prototype to avoid an error.  */
7252 #ifdef __cplusplus
7253 extern "C"
7254 #endif
7255 /* We use char because int might match the return type of a gcc2
7256    builtin and then its argument prototype would still apply.  */
7257 char rl_callback_handler_install ();
7258 int
7259 main ()
7260 {
7261 rl_callback_handler_install ();
7262   ;
7263   return 0;
7264 }
7265 _ACEOF
7266 rm -f conftest.$ac_objext conftest$ac_exeext
7267 if { (eval echo "$as_me:7267: \"$ac_link\"") >&5
7268   (eval $ac_link) 2>&5
7269   ac_status=$?
7270   echo "$as_me:7270: \$? = $ac_status" >&5
7271   (exit $ac_status); } &&
7272          { ac_try='test -s conftest$ac_exeext'
7273   { (eval echo "$as_me:7273: \"$ac_try\"") >&5
7274   (eval $ac_try) 2>&5
7275   ac_status=$?
7276   echo "$as_me:7276: \$? = $ac_status" >&5
7277   (exit $ac_status); }; }; then
7278   ac_cv_lib_readline_rl_callback_handler_install=yes
7279 else
7280   echo "$as_me: failed program was:" >&5
7281 cat conftest.$ac_ext >&5
7282 ac_cv_lib_readline_rl_callback_handler_install=no
7283 fi
7284 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7285 LIBS=$ac_check_lib_save_LIBS
7286 fi
7287 echo "$as_me:7287: result: $ac_cv_lib_readline_rl_callback_handler_install" >&5
7288 echo "${ECHO_T}$ac_cv_lib_readline_rl_callback_handler_install" >&6
7289 if test $ac_cv_lib_readline_rl_callback_handler_install = yes; then
7290   TERMLDFLAGS="-L$with_readline/lib"
7291        TERMCPPFLAGS="-I$with_readline/include"
7292        CPPFLAGS="-I$with_readline/include $CPPFLAGS"
7293        TERMLIBS="-lreadline $TERMLIBS"
7294        cat >>confdefs.h <<\EOF
7295 #define HAVE_LIBREADLINE 1
7296 EOF
7297
7298        break
7299 else
7300   TERMLIBS= CPPFLAGS=$_cppflags
7301 fi
7302
7303 fi
7304 done
7305
7306     LDFLAGS=$_ldflags
7307     ;;
7308   esac
7309 else
7310   echo "$as_me:7310: result: no" >&5
7311 echo "${ECHO_T}no" >&6
7312
7313 fi;
7314
7315 # The readline API changed slightly from readline3 to readline4, so
7316 # code will generate warnings on one of them unless we have a few
7317 # special cases.
7318 echo "$as_me:7318: checking for rl_completion_matches in -lreadline" >&5
7319 echo $ECHO_N "checking for rl_completion_matches in -lreadline... $ECHO_C" >&6
7320 if test "${ac_cv_lib_readline_rl_completion_matches+set}" = set; then
7321   echo $ECHO_N "(cached) $ECHO_C" >&6
7322 else
7323   ac_check_lib_save_LIBS=$LIBS
7324 LIBS="-lreadline $TERMLIBS $LIBS"
7325 cat >conftest.$ac_ext <<_ACEOF
7326 #line 7326 "configure"
7327 #include "confdefs.h"
7328
7329 /* Override any gcc2 internal prototype to avoid an error.  */
7330 #ifdef __cplusplus
7331 extern "C"
7332 #endif
7333 /* We use char because int might match the return type of a gcc2
7334    builtin and then its argument prototype would still apply.  */
7335 char rl_completion_matches ();
7336 int
7337 main ()
7338 {
7339 rl_completion_matches ();
7340   ;
7341   return 0;
7342 }
7343 _ACEOF
7344 rm -f conftest.$ac_objext conftest$ac_exeext
7345 if { (eval echo "$as_me:7345: \"$ac_link\"") >&5
7346   (eval $ac_link) 2>&5
7347   ac_status=$?
7348   echo "$as_me:7348: \$? = $ac_status" >&5
7349   (exit $ac_status); } &&
7350          { ac_try='test -s conftest$ac_exeext'
7351   { (eval echo "$as_me:7351: \"$ac_try\"") >&5
7352   (eval $ac_try) 2>&5
7353   ac_status=$?
7354   echo "$as_me:7354: \$? = $ac_status" >&5
7355   (exit $ac_status); }; }; then
7356   ac_cv_lib_readline_rl_completion_matches=yes
7357 else
7358   echo "$as_me: failed program was:" >&5
7359 cat conftest.$ac_ext >&5
7360 ac_cv_lib_readline_rl_completion_matches=no
7361 fi
7362 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7363 LIBS=$ac_check_lib_save_LIBS
7364 fi
7365 echo "$as_me:7365: result: $ac_cv_lib_readline_rl_completion_matches" >&5
7366 echo "${ECHO_T}$ac_cv_lib_readline_rl_completion_matches" >&6
7367 if test $ac_cv_lib_readline_rl_completion_matches = yes; then
7368
7369 cat >>confdefs.h <<\EOF
7370 #define HAVE_NEW_LIBREADLINE 1
7371 EOF
7372
7373 fi
7374
7375 # The following test taken from the cvs sources
7376 # If we can't find connect, try looking in -lsocket, -lnsl, and -linet.
7377 # The Irix 5 libc.so has connect and gethostbyname, but Irix 5 also has
7378 # libsocket.so which has a bad implementation of gethostbyname (it
7379 # only looks in /etc/hosts), so we only look for -lsocket if we need
7380 # it.
7381
7382 for ac_func in connect
7383 do
7384 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
7385 echo "$as_me:7385: checking for $ac_func" >&5
7386 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
7387 if eval "test \"\${$as_ac_var+set}\" = set"; then
7388   echo $ECHO_N "(cached) $ECHO_C" >&6
7389 else
7390   cat >conftest.$ac_ext <<_ACEOF
7391 #line 7391 "configure"
7392 #include "confdefs.h"
7393 /* System header to define __stub macros and hopefully few prototypes,
7394     which can conflict with char $ac_func (); below.  */
7395 #include <assert.h>
7396 /* Override any gcc2 internal prototype to avoid an error.  */
7397 #ifdef __cplusplus
7398 extern "C"
7399 #endif
7400 /* We use char because int might match the return type of a gcc2
7401    builtin and then its argument prototype would still apply.  */
7402 char $ac_func ();
7403 char (*f) ();
7404
7405 int
7406 main ()
7407 {
7408 /* The GNU C library defines this for functions which it implements
7409     to always fail with ENOSYS.  Some functions are actually named
7410     something starting with __ and the normal name is an alias.  */
7411 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7412 choke me
7413 #else
7414 f = $ac_func;
7415 #endif
7416
7417   ;
7418   return 0;
7419 }
7420 _ACEOF
7421 rm -f conftest.$ac_objext conftest$ac_exeext
7422 if { (eval echo "$as_me:7422: \"$ac_link\"") >&5
7423   (eval $ac_link) 2>&5
7424   ac_status=$?
7425   echo "$as_me:7425: \$? = $ac_status" >&5
7426   (exit $ac_status); } &&
7427          { ac_try='test -s conftest$ac_exeext'
7428   { (eval echo "$as_me:7428: \"$ac_try\"") >&5
7429   (eval $ac_try) 2>&5
7430   ac_status=$?
7431   echo "$as_me:7431: \$? = $ac_status" >&5
7432   (exit $ac_status); }; }; then
7433   eval "$as_ac_var=yes"
7434 else
7435   echo "$as_me: failed program was:" >&5
7436 cat conftest.$ac_ext >&5
7437 eval "$as_ac_var=no"
7438 fi
7439 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7440 fi
7441 echo "$as_me:7441: result: `eval echo '${'$as_ac_var'}'`" >&5
7442 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
7443 if test `eval echo '${'$as_ac_var'}'` = yes; then
7444   cat >>confdefs.h <<EOF
7445 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
7446 EOF
7447
7448 fi
7449 done
7450
7451 if test x"$ac_cv_func_connect" = x"no"; then
7452     case "$LIBS" in
7453     *-lnsl*) ;;
7454     *)
7455 echo "$as_me:7455: checking for printf in -lnsl_s" >&5
7456 echo $ECHO_N "checking for printf in -lnsl_s... $ECHO_C" >&6
7457 if test "${ac_cv_lib_nsl_s_printf+set}" = set; then
7458   echo $ECHO_N "(cached) $ECHO_C" >&6
7459 else
7460   ac_check_lib_save_LIBS=$LIBS
7461 LIBS="-lnsl_s  $LIBS"
7462 cat >conftest.$ac_ext <<_ACEOF
7463 #line 7463 "configure"
7464 #include "confdefs.h"
7465
7466 /* Override any gcc2 internal prototype to avoid an error.  */
7467 #ifdef __cplusplus
7468 extern "C"
7469 #endif
7470 /* We use char because int might match the return type of a gcc2
7471    builtin and then its argument prototype would still apply.  */
7472 char printf ();
7473 int
7474 main ()
7475 {
7476 printf ();
7477   ;
7478   return 0;
7479 }
7480 _ACEOF
7481 rm -f conftest.$ac_objext conftest$ac_exeext
7482 if { (eval echo "$as_me:7482: \"$ac_link\"") >&5
7483   (eval $ac_link) 2>&5
7484   ac_status=$?
7485   echo "$as_me:7485: \$? = $ac_status" >&5
7486   (exit $ac_status); } &&
7487          { ac_try='test -s conftest$ac_exeext'
7488   { (eval echo "$as_me:7488: \"$ac_try\"") >&5
7489   (eval $ac_try) 2>&5
7490   ac_status=$?
7491   echo "$as_me:7491: \$? = $ac_status" >&5
7492   (exit $ac_status); }; }; then
7493   ac_cv_lib_nsl_s_printf=yes
7494 else
7495   echo "$as_me: failed program was:" >&5
7496 cat conftest.$ac_ext >&5
7497 ac_cv_lib_nsl_s_printf=no
7498 fi
7499 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7500 LIBS=$ac_check_lib_save_LIBS
7501 fi
7502 echo "$as_me:7502: result: $ac_cv_lib_nsl_s_printf" >&5
7503 echo "${ECHO_T}$ac_cv_lib_nsl_s_printf" >&6
7504 if test $ac_cv_lib_nsl_s_printf = yes; then
7505   cat >>confdefs.h <<EOF
7506 #define HAVE_LIBNSL_S 1
7507 EOF
7508
7509   LIBS="-lnsl_s $LIBS"
7510
7511 fi
7512  ;;
7513     esac
7514     case "$LIBS" in
7515     *-lnsl*) ;;
7516     *)
7517 echo "$as_me:7517: checking for printf in -lnsl" >&5
7518 echo $ECHO_N "checking for printf in -lnsl... $ECHO_C" >&6
7519 if test "${ac_cv_lib_nsl_printf+set}" = set; then
7520   echo $ECHO_N "(cached) $ECHO_C" >&6
7521 else
7522   ac_check_lib_save_LIBS=$LIBS
7523 LIBS="-lnsl  $LIBS"
7524 cat >conftest.$ac_ext <<_ACEOF
7525 #line 7525 "configure"
7526 #include "confdefs.h"
7527
7528 /* Override any gcc2 internal prototype to avoid an error.  */
7529 #ifdef __cplusplus
7530 extern "C"
7531 #endif
7532 /* We use char because int might match the return type of a gcc2
7533    builtin and then its argument prototype would still apply.  */
7534 char printf ();
7535 int
7536 main ()
7537 {
7538 printf ();
7539   ;
7540   return 0;
7541 }
7542 _ACEOF
7543 rm -f conftest.$ac_objext conftest$ac_exeext
7544 if { (eval echo "$as_me:7544: \"$ac_link\"") >&5
7545   (eval $ac_link) 2>&5
7546   ac_status=$?
7547   echo "$as_me:7547: \$? = $ac_status" >&5
7548   (exit $ac_status); } &&
7549          { ac_try='test -s conftest$ac_exeext'
7550   { (eval echo "$as_me:7550: \"$ac_try\"") >&5
7551   (eval $ac_try) 2>&5
7552   ac_status=$?
7553   echo "$as_me:7553: \$? = $ac_status" >&5
7554   (exit $ac_status); }; }; then
7555   ac_cv_lib_nsl_printf=yes
7556 else
7557   echo "$as_me: failed program was:" >&5
7558 cat conftest.$ac_ext >&5
7559 ac_cv_lib_nsl_printf=no
7560 fi
7561 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7562 LIBS=$ac_check_lib_save_LIBS
7563 fi
7564 echo "$as_me:7564: result: $ac_cv_lib_nsl_printf" >&5
7565 echo "${ECHO_T}$ac_cv_lib_nsl_printf" >&6
7566 if test $ac_cv_lib_nsl_printf = yes; then
7567   cat >>confdefs.h <<EOF
7568 #define HAVE_LIBNSL 1
7569 EOF
7570
7571   LIBS="-lnsl $LIBS"
7572
7573 fi
7574  ;;
7575     esac
7576     case "$LIBS" in
7577     *-lsocket*) ;;
7578     *)
7579 echo "$as_me:7579: checking for connect in -lsocket" >&5
7580 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
7581 if test "${ac_cv_lib_socket_connect+set}" = set; then
7582   echo $ECHO_N "(cached) $ECHO_C" >&6
7583 else
7584   ac_check_lib_save_LIBS=$LIBS
7585 LIBS="-lsocket  $LIBS"
7586 cat >conftest.$ac_ext <<_ACEOF
7587 #line 7587 "configure"
7588 #include "confdefs.h"
7589
7590 /* Override any gcc2 internal prototype to avoid an error.  */
7591 #ifdef __cplusplus
7592 extern "C"
7593 #endif
7594 /* We use char because int might match the return type of a gcc2
7595    builtin and then its argument prototype would still apply.  */
7596 char connect ();
7597 int
7598 main ()
7599 {
7600 connect ();
7601   ;
7602   return 0;
7603 }
7604 _ACEOF
7605 rm -f conftest.$ac_objext conftest$ac_exeext
7606 if { (eval echo "$as_me:7606: \"$ac_link\"") >&5
7607   (eval $ac_link) 2>&5
7608   ac_status=$?
7609   echo "$as_me:7609: \$? = $ac_status" >&5
7610   (exit $ac_status); } &&
7611          { ac_try='test -s conftest$ac_exeext'
7612   { (eval echo "$as_me:7612: \"$ac_try\"") >&5
7613   (eval $ac_try) 2>&5
7614   ac_status=$?
7615   echo "$as_me:7615: \$? = $ac_status" >&5
7616   (exit $ac_status); }; }; then
7617   ac_cv_lib_socket_connect=yes
7618 else
7619   echo "$as_me: failed program was:" >&5
7620 cat conftest.$ac_ext >&5
7621 ac_cv_lib_socket_connect=no
7622 fi
7623 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7624 LIBS=$ac_check_lib_save_LIBS
7625 fi
7626 echo "$as_me:7626: result: $ac_cv_lib_socket_connect" >&5
7627 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
7628 if test $ac_cv_lib_socket_connect = yes; then
7629   cat >>confdefs.h <<EOF
7630 #define HAVE_LIBSOCKET 1
7631 EOF
7632
7633   LIBS="-lsocket $LIBS"
7634
7635 fi
7636  ;;
7637     esac
7638     case "$LIBS" in
7639     *-linet*) ;;
7640     *)
7641 echo "$as_me:7641: checking for connect in -linet" >&5
7642 echo $ECHO_N "checking for connect in -linet... $ECHO_C" >&6
7643 if test "${ac_cv_lib_inet_connect+set}" = set; then
7644   echo $ECHO_N "(cached) $ECHO_C" >&6
7645 else
7646   ac_check_lib_save_LIBS=$LIBS
7647 LIBS="-linet  $LIBS"
7648 cat >conftest.$ac_ext <<_ACEOF
7649 #line 7649 "configure"
7650 #include "confdefs.h"
7651
7652 /* Override any gcc2 internal prototype to avoid an error.  */
7653 #ifdef __cplusplus
7654 extern "C"
7655 #endif
7656 /* We use char because int might match the return type of a gcc2
7657    builtin and then its argument prototype would still apply.  */
7658 char connect ();
7659 int
7660 main ()
7661 {
7662 connect ();
7663   ;
7664   return 0;
7665 }
7666 _ACEOF
7667 rm -f conftest.$ac_objext conftest$ac_exeext
7668 if { (eval echo "$as_me:7668: \"$ac_link\"") >&5
7669   (eval $ac_link) 2>&5
7670   ac_status=$?
7671   echo "$as_me:7671: \$? = $ac_status" >&5
7672   (exit $ac_status); } &&
7673          { ac_try='test -s conftest$ac_exeext'
7674   { (eval echo "$as_me:7674: \"$ac_try\"") >&5
7675   (eval $ac_try) 2>&5
7676   ac_status=$?
7677   echo "$as_me:7677: \$? = $ac_status" >&5
7678   (exit $ac_status); }; }; then
7679   ac_cv_lib_inet_connect=yes
7680 else
7681   echo "$as_me: failed program was:" >&5
7682 cat conftest.$ac_ext >&5
7683 ac_cv_lib_inet_connect=no
7684 fi
7685 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7686 LIBS=$ac_check_lib_save_LIBS
7687 fi
7688 echo "$as_me:7688: result: $ac_cv_lib_inet_connect" >&5
7689 echo "${ECHO_T}$ac_cv_lib_inet_connect" >&6
7690 if test $ac_cv_lib_inet_connect = yes; then
7691   cat >>confdefs.h <<EOF
7692 #define HAVE_LIBINET 1
7693 EOF
7694
7695   LIBS="-linet $LIBS"
7696
7697 fi
7698  ;;
7699     esac
7700             if test x"$ac_cv_lib_socket_connect" = x"yes" ||
7701        test x"$ac_cv_lib_inet_connect" = x"yes"; then
7702         # ac_cv_func_connect=yes
7703         # don't!  it would cause AC_CHECK_FUNC to succeed next time configure is run
7704         cat >>confdefs.h <<\EOF
7705 #define HAVE_CONNECT 1
7706 EOF
7707
7708     fi
7709 fi
7710
7711 ###############################################
7712 # test for where we get get_yp_default_domain() from
7713
7714 for ac_func in yp_get_default_domain
7715 do
7716 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
7717 echo "$as_me:7717: checking for $ac_func" >&5
7718 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
7719 if eval "test \"\${$as_ac_var+set}\" = set"; then
7720   echo $ECHO_N "(cached) $ECHO_C" >&6
7721 else
7722   cat >conftest.$ac_ext <<_ACEOF
7723 #line 7723 "configure"
7724 #include "confdefs.h"
7725 /* System header to define __stub macros and hopefully few prototypes,
7726     which can conflict with char $ac_func (); below.  */
7727 #include <assert.h>
7728 /* Override any gcc2 internal prototype to avoid an error.  */
7729 #ifdef __cplusplus
7730 extern "C"
7731 #endif
7732 /* We use char because int might match the return type of a gcc2
7733    builtin and then its argument prototype would still apply.  */
7734 char $ac_func ();
7735 char (*f) ();
7736
7737 int
7738 main ()
7739 {
7740 /* The GNU C library defines this for functions which it implements
7741     to always fail with ENOSYS.  Some functions are actually named
7742     something starting with __ and the normal name is an alias.  */
7743 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7744 choke me
7745 #else
7746 f = $ac_func;
7747 #endif
7748
7749   ;
7750   return 0;
7751 }
7752 _ACEOF
7753 rm -f conftest.$ac_objext conftest$ac_exeext
7754 if { (eval echo "$as_me:7754: \"$ac_link\"") >&5
7755   (eval $ac_link) 2>&5
7756   ac_status=$?
7757   echo "$as_me:7757: \$? = $ac_status" >&5
7758   (exit $ac_status); } &&
7759          { ac_try='test -s conftest$ac_exeext'
7760   { (eval echo "$as_me:7760: \"$ac_try\"") >&5
7761   (eval $ac_try) 2>&5
7762   ac_status=$?
7763   echo "$as_me:7763: \$? = $ac_status" >&5
7764   (exit $ac_status); }; }; then
7765   eval "$as_ac_var=yes"
7766 else
7767   echo "$as_me: failed program was:" >&5
7768 cat conftest.$ac_ext >&5
7769 eval "$as_ac_var=no"
7770 fi
7771 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7772 fi
7773 echo "$as_me:7773: result: `eval echo '${'$as_ac_var'}'`" >&5
7774 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
7775 if test `eval echo '${'$as_ac_var'}'` = yes; then
7776   cat >>confdefs.h <<EOF
7777 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
7778 EOF
7779
7780 fi
7781 done
7782
7783 if test x"$ac_cv_func_yp_get_default_domain" = x"no"; then
7784         echo "$as_me:7784: checking for yp_get_default_domain in -lnsl" >&5
7785 echo $ECHO_N "checking for yp_get_default_domain in -lnsl... $ECHO_C" >&6
7786 if test "${ac_cv_lib_nsl_yp_get_default_domain+set}" = set; then
7787   echo $ECHO_N "(cached) $ECHO_C" >&6
7788 else
7789   ac_check_lib_save_LIBS=$LIBS
7790 LIBS="-lnsl  $LIBS"
7791 cat >conftest.$ac_ext <<_ACEOF
7792 #line 7792 "configure"
7793 #include "confdefs.h"
7794
7795 /* Override any gcc2 internal prototype to avoid an error.  */
7796 #ifdef __cplusplus
7797 extern "C"
7798 #endif
7799 /* We use char because int might match the return type of a gcc2
7800    builtin and then its argument prototype would still apply.  */
7801 char yp_get_default_domain ();
7802 int
7803 main ()
7804 {
7805 yp_get_default_domain ();
7806   ;
7807   return 0;
7808 }
7809 _ACEOF
7810 rm -f conftest.$ac_objext conftest$ac_exeext
7811 if { (eval echo "$as_me:7811: \"$ac_link\"") >&5
7812   (eval $ac_link) 2>&5
7813   ac_status=$?
7814   echo "$as_me:7814: \$? = $ac_status" >&5
7815   (exit $ac_status); } &&
7816          { ac_try='test -s conftest$ac_exeext'
7817   { (eval echo "$as_me:7817: \"$ac_try\"") >&5
7818   (eval $ac_try) 2>&5
7819   ac_status=$?
7820   echo "$as_me:7820: \$? = $ac_status" >&5
7821   (exit $ac_status); }; }; then
7822   ac_cv_lib_nsl_yp_get_default_domain=yes
7823 else
7824   echo "$as_me: failed program was:" >&5
7825 cat conftest.$ac_ext >&5
7826 ac_cv_lib_nsl_yp_get_default_domain=no
7827 fi
7828 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7829 LIBS=$ac_check_lib_save_LIBS
7830 fi
7831 echo "$as_me:7831: result: $ac_cv_lib_nsl_yp_get_default_domain" >&5
7832 echo "${ECHO_T}$ac_cv_lib_nsl_yp_get_default_domain" >&6
7833 if test $ac_cv_lib_nsl_yp_get_default_domain = yes; then
7834   LIBS="$LIBS -lnsl";
7835         cat >>confdefs.h <<\EOF
7836 #define HAVE_YP_GET_DEFAULT_DOMAIN 1
7837 EOF
7838
7839 fi
7840
7841 fi
7842
7843 # Check if we have execl, if not we need to compile smbrun.
7844
7845 for ac_func in execl
7846 do
7847 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
7848 echo "$as_me:7848: checking for $ac_func" >&5
7849 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
7850 if eval "test \"\${$as_ac_var+set}\" = set"; then
7851   echo $ECHO_N "(cached) $ECHO_C" >&6
7852 else
7853   cat >conftest.$ac_ext <<_ACEOF
7854 #line 7854 "configure"
7855 #include "confdefs.h"
7856 /* System header to define __stub macros and hopefully few prototypes,
7857     which can conflict with char $ac_func (); below.  */
7858 #include <assert.h>
7859 /* Override any gcc2 internal prototype to avoid an error.  */
7860 #ifdef __cplusplus
7861 extern "C"
7862 #endif
7863 /* We use char because int might match the return type of a gcc2
7864    builtin and then its argument prototype would still apply.  */
7865 char $ac_func ();
7866 char (*f) ();
7867
7868 int
7869 main ()
7870 {
7871 /* The GNU C library defines this for functions which it implements
7872     to always fail with ENOSYS.  Some functions are actually named
7873     something starting with __ and the normal name is an alias.  */
7874 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7875 choke me
7876 #else
7877 f = $ac_func;
7878 #endif
7879
7880   ;
7881   return 0;
7882 }
7883 _ACEOF
7884 rm -f conftest.$ac_objext conftest$ac_exeext
7885 if { (eval echo "$as_me:7885: \"$ac_link\"") >&5
7886   (eval $ac_link) 2>&5
7887   ac_status=$?
7888   echo "$as_me:7888: \$? = $ac_status" >&5
7889   (exit $ac_status); } &&
7890          { ac_try='test -s conftest$ac_exeext'
7891   { (eval echo "$as_me:7891: \"$ac_try\"") >&5
7892   (eval $ac_try) 2>&5
7893   ac_status=$?
7894   echo "$as_me:7894: \$? = $ac_status" >&5
7895   (exit $ac_status); }; }; then
7896   eval "$as_ac_var=yes"
7897 else
7898   echo "$as_me: failed program was:" >&5
7899 cat conftest.$ac_ext >&5
7900 eval "$as_ac_var=no"
7901 fi
7902 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7903 fi
7904 echo "$as_me:7904: result: `eval echo '${'$as_ac_var'}'`" >&5
7905 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
7906 if test `eval echo '${'$as_ac_var'}'` = yes; then
7907   cat >>confdefs.h <<EOF
7908 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
7909 EOF
7910
7911 fi
7912 done
7913
7914 if test x"$ac_cv_func_execl" = x"no"; then
7915     RUNPROG="bin/smbrun"
7916 else
7917     RUNPROG=""
7918 fi
7919
7920 for ac_func in waitpid getcwd strdup strtoul strerror chown fchown chmod fchmod chroot
7921 do
7922 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
7923 echo "$as_me:7923: checking for $ac_func" >&5
7924 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
7925 if eval "test \"\${$as_ac_var+set}\" = set"; then
7926   echo $ECHO_N "(cached) $ECHO_C" >&6
7927 else
7928   cat >conftest.$ac_ext <<_ACEOF
7929 #line 7929 "configure"
7930 #include "confdefs.h"
7931 /* System header to define __stub macros and hopefully few prototypes,
7932     which can conflict with char $ac_func (); below.  */
7933 #include <assert.h>
7934 /* Override any gcc2 internal prototype to avoid an error.  */
7935 #ifdef __cplusplus
7936 extern "C"
7937 #endif
7938 /* We use char because int might match the return type of a gcc2
7939    builtin and then its argument prototype would still apply.  */
7940 char $ac_func ();
7941 char (*f) ();
7942
7943 int
7944 main ()
7945 {
7946 /* The GNU C library defines this for functions which it implements
7947     to always fail with ENOSYS.  Some functions are actually named
7948     something starting with __ and the normal name is an alias.  */
7949 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7950 choke me
7951 #else
7952 f = $ac_func;
7953 #endif
7954
7955   ;
7956   return 0;
7957 }
7958 _ACEOF
7959 rm -f conftest.$ac_objext conftest$ac_exeext
7960 if { (eval echo "$as_me:7960: \"$ac_link\"") >&5
7961   (eval $ac_link) 2>&5
7962   ac_status=$?
7963   echo "$as_me:7963: \$? = $ac_status" >&5
7964   (exit $ac_status); } &&
7965          { ac_try='test -s conftest$ac_exeext'
7966   { (eval echo "$as_me:7966: \"$ac_try\"") >&5
7967   (eval $ac_try) 2>&5
7968   ac_status=$?
7969   echo "$as_me:7969: \$? = $ac_status" >&5
7970   (exit $ac_status); }; }; then
7971   eval "$as_ac_var=yes"
7972 else
7973   echo "$as_me: failed program was:" >&5
7974 cat conftest.$ac_ext >&5
7975 eval "$as_ac_var=no"
7976 fi
7977 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7978 fi
7979 echo "$as_me:7979: result: `eval echo '${'$as_ac_var'}'`" >&5
7980 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
7981 if test `eval echo '${'$as_ac_var'}'` = yes; then
7982   cat >>confdefs.h <<EOF
7983 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
7984 EOF
7985
7986 fi
7987 done
7988
7989 for ac_func in fstat strchr utime utimes getrlimit fsync bzero memset strlcpy strlcat
7990 do
7991 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
7992 echo "$as_me:7992: checking for $ac_func" >&5
7993 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
7994 if eval "test \"\${$as_ac_var+set}\" = set"; then
7995   echo $ECHO_N "(cached) $ECHO_C" >&6
7996 else
7997   cat >conftest.$ac_ext <<_ACEOF
7998 #line 7998 "configure"
7999 #include "confdefs.h"
8000 /* System header to define __stub macros and hopefully few prototypes,
8001     which can conflict with char $ac_func (); below.  */
8002 #include <assert.h>
8003 /* Override any gcc2 internal prototype to avoid an error.  */
8004 #ifdef __cplusplus
8005 extern "C"
8006 #endif
8007 /* We use char because int might match the return type of a gcc2
8008    builtin and then its argument prototype would still apply.  */
8009 char $ac_func ();
8010 char (*f) ();
8011
8012 int
8013 main ()
8014 {
8015 /* The GNU C library defines this for functions which it implements
8016     to always fail with ENOSYS.  Some functions are actually named
8017     something starting with __ and the normal name is an alias.  */
8018 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8019 choke me
8020 #else
8021 f = $ac_func;
8022 #endif
8023
8024   ;
8025   return 0;
8026 }
8027 _ACEOF
8028 rm -f conftest.$ac_objext conftest$ac_exeext
8029 if { (eval echo "$as_me:8029: \"$ac_link\"") >&5
8030   (eval $ac_link) 2>&5
8031   ac_status=$?
8032   echo "$as_me:8032: \$? = $ac_status" >&5
8033   (exit $ac_status); } &&
8034          { ac_try='test -s conftest$ac_exeext'
8035   { (eval echo "$as_me:8035: \"$ac_try\"") >&5
8036   (eval $ac_try) 2>&5
8037   ac_status=$?
8038   echo "$as_me:8038: \$? = $ac_status" >&5
8039   (exit $ac_status); }; }; then
8040   eval "$as_ac_var=yes"
8041 else
8042   echo "$as_me: failed program was:" >&5
8043 cat conftest.$ac_ext >&5
8044 eval "$as_ac_var=no"
8045 fi
8046 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8047 fi
8048 echo "$as_me:8048: result: `eval echo '${'$as_ac_var'}'`" >&5
8049 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8050 if test `eval echo '${'$as_ac_var'}'` = yes; then
8051   cat >>confdefs.h <<EOF
8052 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8053 EOF
8054
8055 fi
8056 done
8057
8058 for ac_func in memmove vsnprintf snprintf asprintf vasprintf setsid glob strpbrk pipe crypt16 getauthuid
8059 do
8060 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8061 echo "$as_me:8061: checking for $ac_func" >&5
8062 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8063 if eval "test \"\${$as_ac_var+set}\" = set"; then
8064   echo $ECHO_N "(cached) $ECHO_C" >&6
8065 else
8066   cat >conftest.$ac_ext <<_ACEOF
8067 #line 8067 "configure"
8068 #include "confdefs.h"
8069 /* System header to define __stub macros and hopefully few prototypes,
8070     which can conflict with char $ac_func (); below.  */
8071 #include <assert.h>
8072 /* Override any gcc2 internal prototype to avoid an error.  */
8073 #ifdef __cplusplus
8074 extern "C"
8075 #endif
8076 /* We use char because int might match the return type of a gcc2
8077    builtin and then its argument prototype would still apply.  */
8078 char $ac_func ();
8079 char (*f) ();
8080
8081 int
8082 main ()
8083 {
8084 /* The GNU C library defines this for functions which it implements
8085     to always fail with ENOSYS.  Some functions are actually named
8086     something starting with __ and the normal name is an alias.  */
8087 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8088 choke me
8089 #else
8090 f = $ac_func;
8091 #endif
8092
8093   ;
8094   return 0;
8095 }
8096 _ACEOF
8097 rm -f conftest.$ac_objext conftest$ac_exeext
8098 if { (eval echo "$as_me:8098: \"$ac_link\"") >&5
8099   (eval $ac_link) 2>&5
8100   ac_status=$?
8101   echo "$as_me:8101: \$? = $ac_status" >&5
8102   (exit $ac_status); } &&
8103          { ac_try='test -s conftest$ac_exeext'
8104   { (eval echo "$as_me:8104: \"$ac_try\"") >&5
8105   (eval $ac_try) 2>&5
8106   ac_status=$?
8107   echo "$as_me:8107: \$? = $ac_status" >&5
8108   (exit $ac_status); }; }; then
8109   eval "$as_ac_var=yes"
8110 else
8111   echo "$as_me: failed program was:" >&5
8112 cat conftest.$ac_ext >&5
8113 eval "$as_ac_var=no"
8114 fi
8115 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8116 fi
8117 echo "$as_me:8117: result: `eval echo '${'$as_ac_var'}'`" >&5
8118 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8119 if test `eval echo '${'$as_ac_var'}'` = yes; then
8120   cat >>confdefs.h <<EOF
8121 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8122 EOF
8123
8124 fi
8125 done
8126
8127 for ac_func in strftime sigprocmask sigblock sigaction sigset innetgr setnetgrent getnetgrent endnetgrent
8128 do
8129 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8130 echo "$as_me:8130: checking for $ac_func" >&5
8131 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8132 if eval "test \"\${$as_ac_var+set}\" = set"; then
8133   echo $ECHO_N "(cached) $ECHO_C" >&6
8134 else
8135   cat >conftest.$ac_ext <<_ACEOF
8136 #line 8136 "configure"
8137 #include "confdefs.h"
8138 /* System header to define __stub macros and hopefully few prototypes,
8139     which can conflict with char $ac_func (); below.  */
8140 #include <assert.h>
8141 /* Override any gcc2 internal prototype to avoid an error.  */
8142 #ifdef __cplusplus
8143 extern "C"
8144 #endif
8145 /* We use char because int might match the return type of a gcc2
8146    builtin and then its argument prototype would still apply.  */
8147 char $ac_func ();
8148 char (*f) ();
8149
8150 int
8151 main ()
8152 {
8153 /* The GNU C library defines this for functions which it implements
8154     to always fail with ENOSYS.  Some functions are actually named
8155     something starting with __ and the normal name is an alias.  */
8156 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8157 choke me
8158 #else
8159 f = $ac_func;
8160 #endif
8161
8162   ;
8163   return 0;
8164 }
8165 _ACEOF
8166 rm -f conftest.$ac_objext conftest$ac_exeext
8167 if { (eval echo "$as_me:8167: \"$ac_link\"") >&5
8168   (eval $ac_link) 2>&5
8169   ac_status=$?
8170   echo "$as_me:8170: \$? = $ac_status" >&5
8171   (exit $ac_status); } &&
8172          { ac_try='test -s conftest$ac_exeext'
8173   { (eval echo "$as_me:8173: \"$ac_try\"") >&5
8174   (eval $ac_try) 2>&5
8175   ac_status=$?
8176   echo "$as_me:8176: \$? = $ac_status" >&5
8177   (exit $ac_status); }; }; then
8178   eval "$as_ac_var=yes"
8179 else
8180   echo "$as_me: failed program was:" >&5
8181 cat conftest.$ac_ext >&5
8182 eval "$as_ac_var=no"
8183 fi
8184 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8185 fi
8186 echo "$as_me:8186: result: `eval echo '${'$as_ac_var'}'`" >&5
8187 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8188 if test `eval echo '${'$as_ac_var'}'` = yes; then
8189   cat >>confdefs.h <<EOF
8190 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8191 EOF
8192
8193 fi
8194 done
8195
8196 for ac_func in initgroups select poll rdchk getgrnam getgrent pathconf
8197 do
8198 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8199 echo "$as_me:8199: checking for $ac_func" >&5
8200 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8201 if eval "test \"\${$as_ac_var+set}\" = set"; then
8202   echo $ECHO_N "(cached) $ECHO_C" >&6
8203 else
8204   cat >conftest.$ac_ext <<_ACEOF
8205 #line 8205 "configure"
8206 #include "confdefs.h"
8207 /* System header to define __stub macros and hopefully few prototypes,
8208     which can conflict with char $ac_func (); below.  */
8209 #include <assert.h>
8210 /* Override any gcc2 internal prototype to avoid an error.  */
8211 #ifdef __cplusplus
8212 extern "C"
8213 #endif
8214 /* We use char because int might match the return type of a gcc2
8215    builtin and then its argument prototype would still apply.  */
8216 char $ac_func ();
8217 char (*f) ();
8218
8219 int
8220 main ()
8221 {
8222 /* The GNU C library defines this for functions which it implements
8223     to always fail with ENOSYS.  Some functions are actually named
8224     something starting with __ and the normal name is an alias.  */
8225 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8226 choke me
8227 #else
8228 f = $ac_func;
8229 #endif
8230
8231   ;
8232   return 0;
8233 }
8234 _ACEOF
8235 rm -f conftest.$ac_objext conftest$ac_exeext
8236 if { (eval echo "$as_me:8236: \"$ac_link\"") >&5
8237   (eval $ac_link) 2>&5
8238   ac_status=$?
8239   echo "$as_me:8239: \$? = $ac_status" >&5
8240   (exit $ac_status); } &&
8241          { ac_try='test -s conftest$ac_exeext'
8242   { (eval echo "$as_me:8242: \"$ac_try\"") >&5
8243   (eval $ac_try) 2>&5
8244   ac_status=$?
8245   echo "$as_me:8245: \$? = $ac_status" >&5
8246   (exit $ac_status); }; }; then
8247   eval "$as_ac_var=yes"
8248 else
8249   echo "$as_me: failed program was:" >&5
8250 cat conftest.$ac_ext >&5
8251 eval "$as_ac_var=no"
8252 fi
8253 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8254 fi
8255 echo "$as_me:8255: result: `eval echo '${'$as_ac_var'}'`" >&5
8256 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8257 if test `eval echo '${'$as_ac_var'}'` = yes; then
8258   cat >>confdefs.h <<EOF
8259 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8260 EOF
8261
8262 fi
8263 done
8264
8265 for ac_func in setpriv setgidx setuidx setgroups sysconf mktime rename ftruncate stat64 fstat64
8266 do
8267 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8268 echo "$as_me:8268: checking for $ac_func" >&5
8269 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8270 if eval "test \"\${$as_ac_var+set}\" = set"; then
8271   echo $ECHO_N "(cached) $ECHO_C" >&6
8272 else
8273   cat >conftest.$ac_ext <<_ACEOF
8274 #line 8274 "configure"
8275 #include "confdefs.h"
8276 /* System header to define __stub macros and hopefully few prototypes,
8277     which can conflict with char $ac_func (); below.  */
8278 #include <assert.h>
8279 /* Override any gcc2 internal prototype to avoid an error.  */
8280 #ifdef __cplusplus
8281 extern "C"
8282 #endif
8283 /* We use char because int might match the return type of a gcc2
8284    builtin and then its argument prototype would still apply.  */
8285 char $ac_func ();
8286 char (*f) ();
8287
8288 int
8289 main ()
8290 {
8291 /* The GNU C library defines this for functions which it implements
8292     to always fail with ENOSYS.  Some functions are actually named
8293     something starting with __ and the normal name is an alias.  */
8294 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8295 choke me
8296 #else
8297 f = $ac_func;
8298 #endif
8299
8300   ;
8301   return 0;
8302 }
8303 _ACEOF
8304 rm -f conftest.$ac_objext conftest$ac_exeext
8305 if { (eval echo "$as_me:8305: \"$ac_link\"") >&5
8306   (eval $ac_link) 2>&5
8307   ac_status=$?
8308   echo "$as_me:8308: \$? = $ac_status" >&5
8309   (exit $ac_status); } &&
8310          { ac_try='test -s conftest$ac_exeext'
8311   { (eval echo "$as_me:8311: \"$ac_try\"") >&5
8312   (eval $ac_try) 2>&5
8313   ac_status=$?
8314   echo "$as_me:8314: \$? = $ac_status" >&5
8315   (exit $ac_status); }; }; then
8316   eval "$as_ac_var=yes"
8317 else
8318   echo "$as_me: failed program was:" >&5
8319 cat conftest.$ac_ext >&5
8320 eval "$as_ac_var=no"
8321 fi
8322 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8323 fi
8324 echo "$as_me:8324: result: `eval echo '${'$as_ac_var'}'`" >&5
8325 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8326 if test `eval echo '${'$as_ac_var'}'` = yes; then
8327   cat >>confdefs.h <<EOF
8328 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8329 EOF
8330
8331 fi
8332 done
8333
8334 for ac_func in lstat64 fopen64 atexit grantpt dup2 lseek64 ftruncate64 readdir64
8335 do
8336 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8337 echo "$as_me:8337: checking for $ac_func" >&5
8338 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8339 if eval "test \"\${$as_ac_var+set}\" = set"; then
8340   echo $ECHO_N "(cached) $ECHO_C" >&6
8341 else
8342   cat >conftest.$ac_ext <<_ACEOF
8343 #line 8343 "configure"
8344 #include "confdefs.h"
8345 /* System header to define __stub macros and hopefully few prototypes,
8346     which can conflict with char $ac_func (); below.  */
8347 #include <assert.h>
8348 /* Override any gcc2 internal prototype to avoid an error.  */
8349 #ifdef __cplusplus
8350 extern "C"
8351 #endif
8352 /* We use char because int might match the return type of a gcc2
8353    builtin and then its argument prototype would still apply.  */
8354 char $ac_func ();
8355 char (*f) ();
8356
8357 int
8358 main ()
8359 {
8360 /* The GNU C library defines this for functions which it implements
8361     to always fail with ENOSYS.  Some functions are actually named
8362     something starting with __ and the normal name is an alias.  */
8363 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8364 choke me
8365 #else
8366 f = $ac_func;
8367 #endif
8368
8369   ;
8370   return 0;
8371 }
8372 _ACEOF
8373 rm -f conftest.$ac_objext conftest$ac_exeext
8374 if { (eval echo "$as_me:8374: \"$ac_link\"") >&5
8375   (eval $ac_link) 2>&5
8376   ac_status=$?
8377   echo "$as_me:8377: \$? = $ac_status" >&5
8378   (exit $ac_status); } &&
8379          { ac_try='test -s conftest$ac_exeext'
8380   { (eval echo "$as_me:8380: \"$ac_try\"") >&5
8381   (eval $ac_try) 2>&5
8382   ac_status=$?
8383   echo "$as_me:8383: \$? = $ac_status" >&5
8384   (exit $ac_status); }; }; then
8385   eval "$as_ac_var=yes"
8386 else
8387   echo "$as_me: failed program was:" >&5
8388 cat conftest.$ac_ext >&5
8389 eval "$as_ac_var=no"
8390 fi
8391 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8392 fi
8393 echo "$as_me:8393: result: `eval echo '${'$as_ac_var'}'`" >&5
8394 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8395 if test `eval echo '${'$as_ac_var'}'` = yes; then
8396   cat >>confdefs.h <<EOF
8397 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8398 EOF
8399
8400 fi
8401 done
8402
8403 for ac_func in fseek64 fseeko64 ftell64 ftello64 setluid getpwanam setlinebuf
8404 do
8405 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8406 echo "$as_me:8406: checking for $ac_func" >&5
8407 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8408 if eval "test \"\${$as_ac_var+set}\" = set"; then
8409   echo $ECHO_N "(cached) $ECHO_C" >&6
8410 else
8411   cat >conftest.$ac_ext <<_ACEOF
8412 #line 8412 "configure"
8413 #include "confdefs.h"
8414 /* System header to define __stub macros and hopefully few prototypes,
8415     which can conflict with char $ac_func (); below.  */
8416 #include <assert.h>
8417 /* Override any gcc2 internal prototype to avoid an error.  */
8418 #ifdef __cplusplus
8419 extern "C"
8420 #endif
8421 /* We use char because int might match the return type of a gcc2
8422    builtin and then its argument prototype would still apply.  */
8423 char $ac_func ();
8424 char (*f) ();
8425
8426 int
8427 main ()
8428 {
8429 /* The GNU C library defines this for functions which it implements
8430     to always fail with ENOSYS.  Some functions are actually named
8431     something starting with __ and the normal name is an alias.  */
8432 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8433 choke me
8434 #else
8435 f = $ac_func;
8436 #endif
8437
8438   ;
8439   return 0;
8440 }
8441 _ACEOF
8442 rm -f conftest.$ac_objext conftest$ac_exeext
8443 if { (eval echo "$as_me:8443: \"$ac_link\"") >&5
8444   (eval $ac_link) 2>&5
8445   ac_status=$?
8446   echo "$as_me:8446: \$? = $ac_status" >&5
8447   (exit $ac_status); } &&
8448          { ac_try='test -s conftest$ac_exeext'
8449   { (eval echo "$as_me:8449: \"$ac_try\"") >&5
8450   (eval $ac_try) 2>&5
8451   ac_status=$?
8452   echo "$as_me:8452: \$? = $ac_status" >&5
8453   (exit $ac_status); }; }; then
8454   eval "$as_ac_var=yes"
8455 else
8456   echo "$as_me: failed program was:" >&5
8457 cat conftest.$ac_ext >&5
8458 eval "$as_ac_var=no"
8459 fi
8460 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8461 fi
8462 echo "$as_me:8462: result: `eval echo '${'$as_ac_var'}'`" >&5
8463 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8464 if test `eval echo '${'$as_ac_var'}'` = yes; then
8465   cat >>confdefs.h <<EOF
8466 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8467 EOF
8468
8469 fi
8470 done
8471
8472 for ac_func in srandom random srand rand setenv usleep strcasecmp fcvt fcvtl symlink readlink
8473 do
8474 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8475 echo "$as_me:8475: checking for $ac_func" >&5
8476 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8477 if eval "test \"\${$as_ac_var+set}\" = set"; then
8478   echo $ECHO_N "(cached) $ECHO_C" >&6
8479 else
8480   cat >conftest.$ac_ext <<_ACEOF
8481 #line 8481 "configure"
8482 #include "confdefs.h"
8483 /* System header to define __stub macros and hopefully few prototypes,
8484     which can conflict with char $ac_func (); below.  */
8485 #include <assert.h>
8486 /* Override any gcc2 internal prototype to avoid an error.  */
8487 #ifdef __cplusplus
8488 extern "C"
8489 #endif
8490 /* We use char because int might match the return type of a gcc2
8491    builtin and then its argument prototype would still apply.  */
8492 char $ac_func ();
8493 char (*f) ();
8494
8495 int
8496 main ()
8497 {
8498 /* The GNU C library defines this for functions which it implements
8499     to always fail with ENOSYS.  Some functions are actually named
8500     something starting with __ and the normal name is an alias.  */
8501 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8502 choke me
8503 #else
8504 f = $ac_func;
8505 #endif
8506
8507   ;
8508   return 0;
8509 }
8510 _ACEOF
8511 rm -f conftest.$ac_objext conftest$ac_exeext
8512 if { (eval echo "$as_me:8512: \"$ac_link\"") >&5
8513   (eval $ac_link) 2>&5
8514   ac_status=$?
8515   echo "$as_me:8515: \$? = $ac_status" >&5
8516   (exit $ac_status); } &&
8517          { ac_try='test -s conftest$ac_exeext'
8518   { (eval echo "$as_me:8518: \"$ac_try\"") >&5
8519   (eval $ac_try) 2>&5
8520   ac_status=$?
8521   echo "$as_me:8521: \$? = $ac_status" >&5
8522   (exit $ac_status); }; }; then
8523   eval "$as_ac_var=yes"
8524 else
8525   echo "$as_me: failed program was:" >&5
8526 cat conftest.$ac_ext >&5
8527 eval "$as_ac_var=no"
8528 fi
8529 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8530 fi
8531 echo "$as_me:8531: result: `eval echo '${'$as_ac_var'}'`" >&5
8532 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8533 if test `eval echo '${'$as_ac_var'}'` = yes; then
8534   cat >>confdefs.h <<EOF
8535 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8536 EOF
8537
8538 fi
8539 done
8540
8541 # setbuffer is needed for smbtorture
8542
8543 for ac_func in setbuffer
8544 do
8545 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8546 echo "$as_me:8546: checking for $ac_func" >&5
8547 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8548 if eval "test \"\${$as_ac_var+set}\" = set"; then
8549   echo $ECHO_N "(cached) $ECHO_C" >&6
8550 else
8551   cat >conftest.$ac_ext <<_ACEOF
8552 #line 8552 "configure"
8553 #include "confdefs.h"
8554 /* System header to define __stub macros and hopefully few prototypes,
8555     which can conflict with char $ac_func (); below.  */
8556 #include <assert.h>
8557 /* Override any gcc2 internal prototype to avoid an error.  */
8558 #ifdef __cplusplus
8559 extern "C"
8560 #endif
8561 /* We use char because int might match the return type of a gcc2
8562    builtin and then its argument prototype would still apply.  */
8563 char $ac_func ();
8564 char (*f) ();
8565
8566 int
8567 main ()
8568 {
8569 /* The GNU C library defines this for functions which it implements
8570     to always fail with ENOSYS.  Some functions are actually named
8571     something starting with __ and the normal name is an alias.  */
8572 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8573 choke me
8574 #else
8575 f = $ac_func;
8576 #endif
8577
8578   ;
8579   return 0;
8580 }
8581 _ACEOF
8582 rm -f conftest.$ac_objext conftest$ac_exeext
8583 if { (eval echo "$as_me:8583: \"$ac_link\"") >&5
8584   (eval $ac_link) 2>&5
8585   ac_status=$?
8586   echo "$as_me:8586: \$? = $ac_status" >&5
8587   (exit $ac_status); } &&
8588          { ac_try='test -s conftest$ac_exeext'
8589   { (eval echo "$as_me:8589: \"$ac_try\"") >&5
8590   (eval $ac_try) 2>&5
8591   ac_status=$?
8592   echo "$as_me:8592: \$? = $ac_status" >&5
8593   (exit $ac_status); }; }; then
8594   eval "$as_ac_var=yes"
8595 else
8596   echo "$as_me: failed program was:" >&5
8597 cat conftest.$ac_ext >&5
8598 eval "$as_ac_var=no"
8599 fi
8600 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8601 fi
8602 echo "$as_me:8602: result: `eval echo '${'$as_ac_var'}'`" >&5
8603 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8604 if test `eval echo '${'$as_ac_var'}'` = yes; then
8605   cat >>confdefs.h <<EOF
8606 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8607 EOF
8608
8609 fi
8610 done
8611
8612 # syscall() is needed for smbwrapper.
8613
8614 for ac_func in syscall
8615 do
8616 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8617 echo "$as_me:8617: checking for $ac_func" >&5
8618 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8619 if eval "test \"\${$as_ac_var+set}\" = set"; then
8620   echo $ECHO_N "(cached) $ECHO_C" >&6
8621 else
8622   cat >conftest.$ac_ext <<_ACEOF
8623 #line 8623 "configure"
8624 #include "confdefs.h"
8625 /* System header to define __stub macros and hopefully few prototypes,
8626     which can conflict with char $ac_func (); below.  */
8627 #include <assert.h>
8628 /* Override any gcc2 internal prototype to avoid an error.  */
8629 #ifdef __cplusplus
8630 extern "C"
8631 #endif
8632 /* We use char because int might match the return type of a gcc2
8633    builtin and then its argument prototype would still apply.  */
8634 char $ac_func ();
8635 char (*f) ();
8636
8637 int
8638 main ()
8639 {
8640 /* The GNU C library defines this for functions which it implements
8641     to always fail with ENOSYS.  Some functions are actually named
8642     something starting with __ and the normal name is an alias.  */
8643 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8644 choke me
8645 #else
8646 f = $ac_func;
8647 #endif
8648
8649   ;
8650   return 0;
8651 }
8652 _ACEOF
8653 rm -f conftest.$ac_objext conftest$ac_exeext
8654 if { (eval echo "$as_me:8654: \"$ac_link\"") >&5
8655   (eval $ac_link) 2>&5
8656   ac_status=$?
8657   echo "$as_me:8657: \$? = $ac_status" >&5
8658   (exit $ac_status); } &&
8659          { ac_try='test -s conftest$ac_exeext'
8660   { (eval echo "$as_me:8660: \"$ac_try\"") >&5
8661   (eval $ac_try) 2>&5
8662   ac_status=$?
8663   echo "$as_me:8663: \$? = $ac_status" >&5
8664   (exit $ac_status); }; }; then
8665   eval "$as_ac_var=yes"
8666 else
8667   echo "$as_me: failed program was:" >&5
8668 cat conftest.$ac_ext >&5
8669 eval "$as_ac_var=no"
8670 fi
8671 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8672 fi
8673 echo "$as_me:8673: result: `eval echo '${'$as_ac_var'}'`" >&5
8674 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8675 if test `eval echo '${'$as_ac_var'}'` = yes; then
8676   cat >>confdefs.h <<EOF
8677 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8678 EOF
8679
8680 fi
8681 done
8682
8683 for ac_func in _dup _dup2 _opendir _readdir _seekdir _telldir _closedir
8684 do
8685 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8686 echo "$as_me:8686: checking for $ac_func" >&5
8687 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8688 if eval "test \"\${$as_ac_var+set}\" = set"; then
8689   echo $ECHO_N "(cached) $ECHO_C" >&6
8690 else
8691   cat >conftest.$ac_ext <<_ACEOF
8692 #line 8692 "configure"
8693 #include "confdefs.h"
8694 /* System header to define __stub macros and hopefully few prototypes,
8695     which can conflict with char $ac_func (); below.  */
8696 #include <assert.h>
8697 /* Override any gcc2 internal prototype to avoid an error.  */
8698 #ifdef __cplusplus
8699 extern "C"
8700 #endif
8701 /* We use char because int might match the return type of a gcc2
8702    builtin and then its argument prototype would still apply.  */
8703 char $ac_func ();
8704 char (*f) ();
8705
8706 int
8707 main ()
8708 {
8709 /* The GNU C library defines this for functions which it implements
8710     to always fail with ENOSYS.  Some functions are actually named
8711     something starting with __ and the normal name is an alias.  */
8712 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8713 choke me
8714 #else
8715 f = $ac_func;
8716 #endif
8717
8718   ;
8719   return 0;
8720 }
8721 _ACEOF
8722 rm -f conftest.$ac_objext conftest$ac_exeext
8723 if { (eval echo "$as_me:8723: \"$ac_link\"") >&5
8724   (eval $ac_link) 2>&5
8725   ac_status=$?
8726   echo "$as_me:8726: \$? = $ac_status" >&5
8727   (exit $ac_status); } &&
8728          { ac_try='test -s conftest$ac_exeext'
8729   { (eval echo "$as_me:8729: \"$ac_try\"") >&5
8730   (eval $ac_try) 2>&5
8731   ac_status=$?
8732   echo "$as_me:8732: \$? = $ac_status" >&5
8733   (exit $ac_status); }; }; then
8734   eval "$as_ac_var=yes"
8735 else
8736   echo "$as_me: failed program was:" >&5
8737 cat conftest.$ac_ext >&5
8738 eval "$as_ac_var=no"
8739 fi
8740 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8741 fi
8742 echo "$as_me:8742: result: `eval echo '${'$as_ac_var'}'`" >&5
8743 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8744 if test `eval echo '${'$as_ac_var'}'` = yes; then
8745   cat >>confdefs.h <<EOF
8746 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8747 EOF
8748
8749 fi
8750 done
8751
8752 for ac_func in __dup __dup2 __opendir __readdir __seekdir __telldir __closedir
8753 do
8754 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8755 echo "$as_me:8755: checking for $ac_func" >&5
8756 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8757 if eval "test \"\${$as_ac_var+set}\" = set"; then
8758   echo $ECHO_N "(cached) $ECHO_C" >&6
8759 else
8760   cat >conftest.$ac_ext <<_ACEOF
8761 #line 8761 "configure"
8762 #include "confdefs.h"
8763 /* System header to define __stub macros and hopefully few prototypes,
8764     which can conflict with char $ac_func (); below.  */
8765 #include <assert.h>
8766 /* Override any gcc2 internal prototype to avoid an error.  */
8767 #ifdef __cplusplus
8768 extern "C"
8769 #endif
8770 /* We use char because int might match the return type of a gcc2
8771    builtin and then its argument prototype would still apply.  */
8772 char $ac_func ();
8773 char (*f) ();
8774
8775 int
8776 main ()
8777 {
8778 /* The GNU C library defines this for functions which it implements
8779     to always fail with ENOSYS.  Some functions are actually named
8780     something starting with __ and the normal name is an alias.  */
8781 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8782 choke me
8783 #else
8784 f = $ac_func;
8785 #endif
8786
8787   ;
8788   return 0;
8789 }
8790 _ACEOF
8791 rm -f conftest.$ac_objext conftest$ac_exeext
8792 if { (eval echo "$as_me:8792: \"$ac_link\"") >&5
8793   (eval $ac_link) 2>&5
8794   ac_status=$?
8795   echo "$as_me:8795: \$? = $ac_status" >&5
8796   (exit $ac_status); } &&
8797          { ac_try='test -s conftest$ac_exeext'
8798   { (eval echo "$as_me:8798: \"$ac_try\"") >&5
8799   (eval $ac_try) 2>&5
8800   ac_status=$?
8801   echo "$as_me:8801: \$? = $ac_status" >&5
8802   (exit $ac_status); }; }; then
8803   eval "$as_ac_var=yes"
8804 else
8805   echo "$as_me: failed program was:" >&5
8806 cat conftest.$ac_ext >&5
8807 eval "$as_ac_var=no"
8808 fi
8809 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8810 fi
8811 echo "$as_me:8811: result: `eval echo '${'$as_ac_var'}'`" >&5
8812 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8813 if test `eval echo '${'$as_ac_var'}'` = yes; then
8814   cat >>confdefs.h <<EOF
8815 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8816 EOF
8817
8818 fi
8819 done
8820
8821 for ac_func in __getcwd _getcwd
8822 do
8823 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8824 echo "$as_me:8824: checking for $ac_func" >&5
8825 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8826 if eval "test \"\${$as_ac_var+set}\" = set"; then
8827   echo $ECHO_N "(cached) $ECHO_C" >&6
8828 else
8829   cat >conftest.$ac_ext <<_ACEOF
8830 #line 8830 "configure"
8831 #include "confdefs.h"
8832 /* System header to define __stub macros and hopefully few prototypes,
8833     which can conflict with char $ac_func (); below.  */
8834 #include <assert.h>
8835 /* Override any gcc2 internal prototype to avoid an error.  */
8836 #ifdef __cplusplus
8837 extern "C"
8838 #endif
8839 /* We use char because int might match the return type of a gcc2
8840    builtin and then its argument prototype would still apply.  */
8841 char $ac_func ();
8842 char (*f) ();
8843
8844 int
8845 main ()
8846 {
8847 /* The GNU C library defines this for functions which it implements
8848     to always fail with ENOSYS.  Some functions are actually named
8849     something starting with __ and the normal name is an alias.  */
8850 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8851 choke me
8852 #else
8853 f = $ac_func;
8854 #endif
8855
8856   ;
8857   return 0;
8858 }
8859 _ACEOF
8860 rm -f conftest.$ac_objext conftest$ac_exeext
8861 if { (eval echo "$as_me:8861: \"$ac_link\"") >&5
8862   (eval $ac_link) 2>&5
8863   ac_status=$?
8864   echo "$as_me:8864: \$? = $ac_status" >&5
8865   (exit $ac_status); } &&
8866          { ac_try='test -s conftest$ac_exeext'
8867   { (eval echo "$as_me:8867: \"$ac_try\"") >&5
8868   (eval $ac_try) 2>&5
8869   ac_status=$?
8870   echo "$as_me:8870: \$? = $ac_status" >&5
8871   (exit $ac_status); }; }; then
8872   eval "$as_ac_var=yes"
8873 else
8874   echo "$as_me: failed program was:" >&5
8875 cat conftest.$ac_ext >&5
8876 eval "$as_ac_var=no"
8877 fi
8878 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8879 fi
8880 echo "$as_me:8880: result: `eval echo '${'$as_ac_var'}'`" >&5
8881 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8882 if test `eval echo '${'$as_ac_var'}'` = yes; then
8883   cat >>confdefs.h <<EOF
8884 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8885 EOF
8886
8887 fi
8888 done
8889
8890 for ac_func in __xstat __fxstat __lxstat
8891 do
8892 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8893 echo "$as_me:8893: checking for $ac_func" >&5
8894 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8895 if eval "test \"\${$as_ac_var+set}\" = set"; then
8896   echo $ECHO_N "(cached) $ECHO_C" >&6
8897 else
8898   cat >conftest.$ac_ext <<_ACEOF
8899 #line 8899 "configure"
8900 #include "confdefs.h"
8901 /* System header to define __stub macros and hopefully few prototypes,
8902     which can conflict with char $ac_func (); below.  */
8903 #include <assert.h>
8904 /* Override any gcc2 internal prototype to avoid an error.  */
8905 #ifdef __cplusplus
8906 extern "C"
8907 #endif
8908 /* We use char because int might match the return type of a gcc2
8909    builtin and then its argument prototype would still apply.  */
8910 char $ac_func ();
8911 char (*f) ();
8912
8913 int
8914 main ()
8915 {
8916 /* The GNU C library defines this for functions which it implements
8917     to always fail with ENOSYS.  Some functions are actually named
8918     something starting with __ and the normal name is an alias.  */
8919 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8920 choke me
8921 #else
8922 f = $ac_func;
8923 #endif
8924
8925   ;
8926   return 0;
8927 }
8928 _ACEOF
8929 rm -f conftest.$ac_objext conftest$ac_exeext
8930 if { (eval echo "$as_me:8930: \"$ac_link\"") >&5
8931   (eval $ac_link) 2>&5
8932   ac_status=$?
8933   echo "$as_me:8933: \$? = $ac_status" >&5
8934   (exit $ac_status); } &&
8935          { ac_try='test -s conftest$ac_exeext'
8936   { (eval echo "$as_me:8936: \"$ac_try\"") >&5
8937   (eval $ac_try) 2>&5
8938   ac_status=$?
8939   echo "$as_me:8939: \$? = $ac_status" >&5
8940   (exit $ac_status); }; }; then
8941   eval "$as_ac_var=yes"
8942 else
8943   echo "$as_me: failed program was:" >&5
8944 cat conftest.$ac_ext >&5
8945 eval "$as_ac_var=no"
8946 fi
8947 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8948 fi
8949 echo "$as_me:8949: result: `eval echo '${'$as_ac_var'}'`" >&5
8950 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8951 if test `eval echo '${'$as_ac_var'}'` = yes; then
8952   cat >>confdefs.h <<EOF
8953 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8954 EOF
8955
8956 fi
8957 done
8958
8959 for ac_func in _stat _lstat _fstat __stat __lstat __fstat
8960 do
8961 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8962 echo "$as_me:8962: checking for $ac_func" >&5
8963 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8964 if eval "test \"\${$as_ac_var+set}\" = set"; then
8965   echo $ECHO_N "(cached) $ECHO_C" >&6
8966 else
8967   cat >conftest.$ac_ext <<_ACEOF
8968 #line 8968 "configure"
8969 #include "confdefs.h"
8970 /* System header to define __stub macros and hopefully few prototypes,
8971     which can conflict with char $ac_func (); below.  */
8972 #include <assert.h>
8973 /* Override any gcc2 internal prototype to avoid an error.  */
8974 #ifdef __cplusplus
8975 extern "C"
8976 #endif
8977 /* We use char because int might match the return type of a gcc2
8978    builtin and then its argument prototype would still apply.  */
8979 char $ac_func ();
8980 char (*f) ();
8981
8982 int
8983 main ()
8984 {
8985 /* The GNU C library defines this for functions which it implements
8986     to always fail with ENOSYS.  Some functions are actually named
8987     something starting with __ and the normal name is an alias.  */
8988 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8989 choke me
8990 #else
8991 f = $ac_func;
8992 #endif
8993
8994   ;
8995   return 0;
8996 }
8997 _ACEOF
8998 rm -f conftest.$ac_objext conftest$ac_exeext
8999 if { (eval echo "$as_me:8999: \"$ac_link\"") >&5
9000   (eval $ac_link) 2>&5
9001   ac_status=$?
9002   echo "$as_me:9002: \$? = $ac_status" >&5
9003   (exit $ac_status); } &&
9004          { ac_try='test -s conftest$ac_exeext'
9005   { (eval echo "$as_me:9005: \"$ac_try\"") >&5
9006   (eval $ac_try) 2>&5
9007   ac_status=$?
9008   echo "$as_me:9008: \$? = $ac_status" >&5
9009   (exit $ac_status); }; }; then
9010   eval "$as_ac_var=yes"
9011 else
9012   echo "$as_me: failed program was:" >&5
9013 cat conftest.$ac_ext >&5
9014 eval "$as_ac_var=no"
9015 fi
9016 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9017 fi
9018 echo "$as_me:9018: result: `eval echo '${'$as_ac_var'}'`" >&5
9019 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9020 if test `eval echo '${'$as_ac_var'}'` = yes; then
9021   cat >>confdefs.h <<EOF
9022 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9023 EOF
9024
9025 fi
9026 done
9027
9028 for ac_func in _acl __acl _facl __facl _open __open _chdir __chdir
9029 do
9030 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9031 echo "$as_me:9031: checking for $ac_func" >&5
9032 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9033 if eval "test \"\${$as_ac_var+set}\" = set"; then
9034   echo $ECHO_N "(cached) $ECHO_C" >&6
9035 else
9036   cat >conftest.$ac_ext <<_ACEOF
9037 #line 9037 "configure"
9038 #include "confdefs.h"
9039 /* System header to define __stub macros and hopefully few prototypes,
9040     which can conflict with char $ac_func (); below.  */
9041 #include <assert.h>
9042 /* Override any gcc2 internal prototype to avoid an error.  */
9043 #ifdef __cplusplus
9044 extern "C"
9045 #endif
9046 /* We use char because int might match the return type of a gcc2
9047    builtin and then its argument prototype would still apply.  */
9048 char $ac_func ();
9049 char (*f) ();
9050
9051 int
9052 main ()
9053 {
9054 /* The GNU C library defines this for functions which it implements
9055     to always fail with ENOSYS.  Some functions are actually named
9056     something starting with __ and the normal name is an alias.  */
9057 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9058 choke me
9059 #else
9060 f = $ac_func;
9061 #endif
9062
9063   ;
9064   return 0;
9065 }
9066 _ACEOF
9067 rm -f conftest.$ac_objext conftest$ac_exeext
9068 if { (eval echo "$as_me:9068: \"$ac_link\"") >&5
9069   (eval $ac_link) 2>&5
9070   ac_status=$?
9071   echo "$as_me:9071: \$? = $ac_status" >&5
9072   (exit $ac_status); } &&
9073          { ac_try='test -s conftest$ac_exeext'
9074   { (eval echo "$as_me:9074: \"$ac_try\"") >&5
9075   (eval $ac_try) 2>&5
9076   ac_status=$?
9077   echo "$as_me:9077: \$? = $ac_status" >&5
9078   (exit $ac_status); }; }; then
9079   eval "$as_ac_var=yes"
9080 else
9081   echo "$as_me: failed program was:" >&5
9082 cat conftest.$ac_ext >&5
9083 eval "$as_ac_var=no"
9084 fi
9085 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9086 fi
9087 echo "$as_me:9087: result: `eval echo '${'$as_ac_var'}'`" >&5
9088 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9089 if test `eval echo '${'$as_ac_var'}'` = yes; then
9090   cat >>confdefs.h <<EOF
9091 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9092 EOF
9093
9094 fi
9095 done
9096
9097 for ac_func in _close __close _fchdir __fchdir _fcntl __fcntl
9098 do
9099 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9100 echo "$as_me:9100: checking for $ac_func" >&5
9101 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9102 if eval "test \"\${$as_ac_var+set}\" = set"; then
9103   echo $ECHO_N "(cached) $ECHO_C" >&6
9104 else
9105   cat >conftest.$ac_ext <<_ACEOF
9106 #line 9106 "configure"
9107 #include "confdefs.h"
9108 /* System header to define __stub macros and hopefully few prototypes,
9109     which can conflict with char $ac_func (); below.  */
9110 #include <assert.h>
9111 /* Override any gcc2 internal prototype to avoid an error.  */
9112 #ifdef __cplusplus
9113 extern "C"
9114 #endif
9115 /* We use char because int might match the return type of a gcc2
9116    builtin and then its argument prototype would still apply.  */
9117 char $ac_func ();
9118 char (*f) ();
9119
9120 int
9121 main ()
9122 {
9123 /* The GNU C library defines this for functions which it implements
9124     to always fail with ENOSYS.  Some functions are actually named
9125     something starting with __ and the normal name is an alias.  */
9126 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9127 choke me
9128 #else
9129 f = $ac_func;
9130 #endif
9131
9132   ;
9133   return 0;
9134 }
9135 _ACEOF
9136 rm -f conftest.$ac_objext conftest$ac_exeext
9137 if { (eval echo "$as_me:9137: \"$ac_link\"") >&5
9138   (eval $ac_link) 2>&5
9139   ac_status=$?
9140   echo "$as_me:9140: \$? = $ac_status" >&5
9141   (exit $ac_status); } &&
9142          { ac_try='test -s conftest$ac_exeext'
9143   { (eval echo "$as_me:9143: \"$ac_try\"") >&5
9144   (eval $ac_try) 2>&5
9145   ac_status=$?
9146   echo "$as_me:9146: \$? = $ac_status" >&5
9147   (exit $ac_status); }; }; then
9148   eval "$as_ac_var=yes"
9149 else
9150   echo "$as_me: failed program was:" >&5
9151 cat conftest.$ac_ext >&5
9152 eval "$as_ac_var=no"
9153 fi
9154 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9155 fi
9156 echo "$as_me:9156: result: `eval echo '${'$as_ac_var'}'`" >&5
9157 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9158 if test `eval echo '${'$as_ac_var'}'` = yes; then
9159   cat >>confdefs.h <<EOF
9160 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9161 EOF
9162
9163 fi
9164 done
9165
9166 for ac_func in getdents _getdents __getdents _lseek __lseek _read __read
9167 do
9168 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9169 echo "$as_me:9169: checking for $ac_func" >&5
9170 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9171 if eval "test \"\${$as_ac_var+set}\" = set"; then
9172   echo $ECHO_N "(cached) $ECHO_C" >&6
9173 else
9174   cat >conftest.$ac_ext <<_ACEOF
9175 #line 9175 "configure"
9176 #include "confdefs.h"
9177 /* System header to define __stub macros and hopefully few prototypes,
9178     which can conflict with char $ac_func (); below.  */
9179 #include <assert.h>
9180 /* Override any gcc2 internal prototype to avoid an error.  */
9181 #ifdef __cplusplus
9182 extern "C"
9183 #endif
9184 /* We use char because int might match the return type of a gcc2
9185    builtin and then its argument prototype would still apply.  */
9186 char $ac_func ();
9187 char (*f) ();
9188
9189 int
9190 main ()
9191 {
9192 /* The GNU C library defines this for functions which it implements
9193     to always fail with ENOSYS.  Some functions are actually named
9194     something starting with __ and the normal name is an alias.  */
9195 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9196 choke me
9197 #else
9198 f = $ac_func;
9199 #endif
9200
9201   ;
9202   return 0;
9203 }
9204 _ACEOF
9205 rm -f conftest.$ac_objext conftest$ac_exeext
9206 if { (eval echo "$as_me:9206: \"$ac_link\"") >&5
9207   (eval $ac_link) 2>&5
9208   ac_status=$?
9209   echo "$as_me:9209: \$? = $ac_status" >&5
9210   (exit $ac_status); } &&
9211          { ac_try='test -s conftest$ac_exeext'
9212   { (eval echo "$as_me:9212: \"$ac_try\"") >&5
9213   (eval $ac_try) 2>&5
9214   ac_status=$?
9215   echo "$as_me:9215: \$? = $ac_status" >&5
9216   (exit $ac_status); }; }; then
9217   eval "$as_ac_var=yes"
9218 else
9219   echo "$as_me: failed program was:" >&5
9220 cat conftest.$ac_ext >&5
9221 eval "$as_ac_var=no"
9222 fi
9223 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9224 fi
9225 echo "$as_me:9225: result: `eval echo '${'$as_ac_var'}'`" >&5
9226 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9227 if test `eval echo '${'$as_ac_var'}'` = yes; then
9228   cat >>confdefs.h <<EOF
9229 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9230 EOF
9231
9232 fi
9233 done
9234
9235 for ac_func in _write __write _fork __fork
9236 do
9237 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9238 echo "$as_me:9238: checking for $ac_func" >&5
9239 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9240 if eval "test \"\${$as_ac_var+set}\" = set"; then
9241   echo $ECHO_N "(cached) $ECHO_C" >&6
9242 else
9243   cat >conftest.$ac_ext <<_ACEOF
9244 #line 9244 "configure"
9245 #include "confdefs.h"
9246 /* System header to define __stub macros and hopefully few prototypes,
9247     which can conflict with char $ac_func (); below.  */
9248 #include <assert.h>
9249 /* Override any gcc2 internal prototype to avoid an error.  */
9250 #ifdef __cplusplus
9251 extern "C"
9252 #endif
9253 /* We use char because int might match the return type of a gcc2
9254    builtin and then its argument prototype would still apply.  */
9255 char $ac_func ();
9256 char (*f) ();
9257
9258 int
9259 main ()
9260 {
9261 /* The GNU C library defines this for functions which it implements
9262     to always fail with ENOSYS.  Some functions are actually named
9263     something starting with __ and the normal name is an alias.  */
9264 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9265 choke me
9266 #else
9267 f = $ac_func;
9268 #endif
9269
9270   ;
9271   return 0;
9272 }
9273 _ACEOF
9274 rm -f conftest.$ac_objext conftest$ac_exeext
9275 if { (eval echo "$as_me:9275: \"$ac_link\"") >&5
9276   (eval $ac_link) 2>&5
9277   ac_status=$?
9278   echo "$as_me:9278: \$? = $ac_status" >&5
9279   (exit $ac_status); } &&
9280          { ac_try='test -s conftest$ac_exeext'
9281   { (eval echo "$as_me:9281: \"$ac_try\"") >&5
9282   (eval $ac_try) 2>&5
9283   ac_status=$?
9284   echo "$as_me:9284: \$? = $ac_status" >&5
9285   (exit $ac_status); }; }; then
9286   eval "$as_ac_var=yes"
9287 else
9288   echo "$as_me: failed program was:" >&5
9289 cat conftest.$ac_ext >&5
9290 eval "$as_ac_var=no"
9291 fi
9292 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9293 fi
9294 echo "$as_me:9294: result: `eval echo '${'$as_ac_var'}'`" >&5
9295 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9296 if test `eval echo '${'$as_ac_var'}'` = yes; then
9297   cat >>confdefs.h <<EOF
9298 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9299 EOF
9300
9301 fi
9302 done
9303
9304 for ac_func in _stat64 __stat64 _fstat64 __fstat64 _lstat64 __lstat64
9305 do
9306 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9307 echo "$as_me:9307: checking for $ac_func" >&5
9308 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9309 if eval "test \"\${$as_ac_var+set}\" = set"; then
9310   echo $ECHO_N "(cached) $ECHO_C" >&6
9311 else
9312   cat >conftest.$ac_ext <<_ACEOF
9313 #line 9313 "configure"
9314 #include "confdefs.h"
9315 /* System header to define __stub macros and hopefully few prototypes,
9316     which can conflict with char $ac_func (); below.  */
9317 #include <assert.h>
9318 /* Override any gcc2 internal prototype to avoid an error.  */
9319 #ifdef __cplusplus
9320 extern "C"
9321 #endif
9322 /* We use char because int might match the return type of a gcc2
9323    builtin and then its argument prototype would still apply.  */
9324 char $ac_func ();
9325 char (*f) ();
9326
9327 int
9328 main ()
9329 {
9330 /* The GNU C library defines this for functions which it implements
9331     to always fail with ENOSYS.  Some functions are actually named
9332     something starting with __ and the normal name is an alias.  */
9333 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9334 choke me
9335 #else
9336 f = $ac_func;
9337 #endif
9338
9339   ;
9340   return 0;
9341 }
9342 _ACEOF
9343 rm -f conftest.$ac_objext conftest$ac_exeext
9344 if { (eval echo "$as_me:9344: \"$ac_link\"") >&5
9345   (eval $ac_link) 2>&5
9346   ac_status=$?
9347   echo "$as_me:9347: \$? = $ac_status" >&5
9348   (exit $ac_status); } &&
9349          { ac_try='test -s conftest$ac_exeext'
9350   { (eval echo "$as_me:9350: \"$ac_try\"") >&5
9351   (eval $ac_try) 2>&5
9352   ac_status=$?
9353   echo "$as_me:9353: \$? = $ac_status" >&5
9354   (exit $ac_status); }; }; then
9355   eval "$as_ac_var=yes"
9356 else
9357   echo "$as_me: failed program was:" >&5
9358 cat conftest.$ac_ext >&5
9359 eval "$as_ac_var=no"
9360 fi
9361 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9362 fi
9363 echo "$as_me:9363: result: `eval echo '${'$as_ac_var'}'`" >&5
9364 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9365 if test `eval echo '${'$as_ac_var'}'` = yes; then
9366   cat >>confdefs.h <<EOF
9367 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9368 EOF
9369
9370 fi
9371 done
9372
9373 for ac_func in __sys_llseek llseek _llseek __llseek readdir64 _readdir64 __readdir64
9374 do
9375 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9376 echo "$as_me:9376: checking for $ac_func" >&5
9377 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9378 if eval "test \"\${$as_ac_var+set}\" = set"; then
9379   echo $ECHO_N "(cached) $ECHO_C" >&6
9380 else
9381   cat >conftest.$ac_ext <<_ACEOF
9382 #line 9382 "configure"
9383 #include "confdefs.h"
9384 /* System header to define __stub macros and hopefully few prototypes,
9385     which can conflict with char $ac_func (); below.  */
9386 #include <assert.h>
9387 /* Override any gcc2 internal prototype to avoid an error.  */
9388 #ifdef __cplusplus
9389 extern "C"
9390 #endif
9391 /* We use char because int might match the return type of a gcc2
9392    builtin and then its argument prototype would still apply.  */
9393 char $ac_func ();
9394 char (*f) ();
9395
9396 int
9397 main ()
9398 {
9399 /* The GNU C library defines this for functions which it implements
9400     to always fail with ENOSYS.  Some functions are actually named
9401     something starting with __ and the normal name is an alias.  */
9402 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9403 choke me
9404 #else
9405 f = $ac_func;
9406 #endif
9407
9408   ;
9409   return 0;
9410 }
9411 _ACEOF
9412 rm -f conftest.$ac_objext conftest$ac_exeext
9413 if { (eval echo "$as_me:9413: \"$ac_link\"") >&5
9414   (eval $ac_link) 2>&5
9415   ac_status=$?
9416   echo "$as_me:9416: \$? = $ac_status" >&5
9417   (exit $ac_status); } &&
9418          { ac_try='test -s conftest$ac_exeext'
9419   { (eval echo "$as_me:9419: \"$ac_try\"") >&5
9420   (eval $ac_try) 2>&5
9421   ac_status=$?
9422   echo "$as_me:9422: \$? = $ac_status" >&5
9423   (exit $ac_status); }; }; then
9424   eval "$as_ac_var=yes"
9425 else
9426   echo "$as_me: failed program was:" >&5
9427 cat conftest.$ac_ext >&5
9428 eval "$as_ac_var=no"
9429 fi
9430 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9431 fi
9432 echo "$as_me:9432: result: `eval echo '${'$as_ac_var'}'`" >&5
9433 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9434 if test `eval echo '${'$as_ac_var'}'` = yes; then
9435   cat >>confdefs.h <<EOF
9436 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9437 EOF
9438
9439 fi
9440 done
9441
9442 for ac_func in pread _pread __pread pread64 _pread64 __pread64
9443 do
9444 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9445 echo "$as_me:9445: checking for $ac_func" >&5
9446 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9447 if eval "test \"\${$as_ac_var+set}\" = set"; then
9448   echo $ECHO_N "(cached) $ECHO_C" >&6
9449 else
9450   cat >conftest.$ac_ext <<_ACEOF
9451 #line 9451 "configure"
9452 #include "confdefs.h"
9453 /* System header to define __stub macros and hopefully few prototypes,
9454     which can conflict with char $ac_func (); below.  */
9455 #include <assert.h>
9456 /* Override any gcc2 internal prototype to avoid an error.  */
9457 #ifdef __cplusplus
9458 extern "C"
9459 #endif
9460 /* We use char because int might match the return type of a gcc2
9461    builtin and then its argument prototype would still apply.  */
9462 char $ac_func ();
9463 char (*f) ();
9464
9465 int
9466 main ()
9467 {
9468 /* The GNU C library defines this for functions which it implements
9469     to always fail with ENOSYS.  Some functions are actually named
9470     something starting with __ and the normal name is an alias.  */
9471 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9472 choke me
9473 #else
9474 f = $ac_func;
9475 #endif
9476
9477   ;
9478   return 0;
9479 }
9480 _ACEOF
9481 rm -f conftest.$ac_objext conftest$ac_exeext
9482 if { (eval echo "$as_me:9482: \"$ac_link\"") >&5
9483   (eval $ac_link) 2>&5
9484   ac_status=$?
9485   echo "$as_me:9485: \$? = $ac_status" >&5
9486   (exit $ac_status); } &&
9487          { ac_try='test -s conftest$ac_exeext'
9488   { (eval echo "$as_me:9488: \"$ac_try\"") >&5
9489   (eval $ac_try) 2>&5
9490   ac_status=$?
9491   echo "$as_me:9491: \$? = $ac_status" >&5
9492   (exit $ac_status); }; }; then
9493   eval "$as_ac_var=yes"
9494 else
9495   echo "$as_me: failed program was:" >&5
9496 cat conftest.$ac_ext >&5
9497 eval "$as_ac_var=no"
9498 fi
9499 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9500 fi
9501 echo "$as_me:9501: result: `eval echo '${'$as_ac_var'}'`" >&5
9502 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9503 if test `eval echo '${'$as_ac_var'}'` = yes; then
9504   cat >>confdefs.h <<EOF
9505 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9506 EOF
9507
9508 fi
9509 done
9510
9511 for ac_func in pwrite _pwrite __pwrite pwrite64 _pwrite64 __pwrite64
9512 do
9513 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9514 echo "$as_me:9514: checking for $ac_func" >&5
9515 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9516 if eval "test \"\${$as_ac_var+set}\" = set"; then
9517   echo $ECHO_N "(cached) $ECHO_C" >&6
9518 else
9519   cat >conftest.$ac_ext <<_ACEOF
9520 #line 9520 "configure"
9521 #include "confdefs.h"
9522 /* System header to define __stub macros and hopefully few prototypes,
9523     which can conflict with char $ac_func (); below.  */
9524 #include <assert.h>
9525 /* Override any gcc2 internal prototype to avoid an error.  */
9526 #ifdef __cplusplus
9527 extern "C"
9528 #endif
9529 /* We use char because int might match the return type of a gcc2
9530    builtin and then its argument prototype would still apply.  */
9531 char $ac_func ();
9532 char (*f) ();
9533
9534 int
9535 main ()
9536 {
9537 /* The GNU C library defines this for functions which it implements
9538     to always fail with ENOSYS.  Some functions are actually named
9539     something starting with __ and the normal name is an alias.  */
9540 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9541 choke me
9542 #else
9543 f = $ac_func;
9544 #endif
9545
9546   ;
9547   return 0;
9548 }
9549 _ACEOF
9550 rm -f conftest.$ac_objext conftest$ac_exeext
9551 if { (eval echo "$as_me:9551: \"$ac_link\"") >&5
9552   (eval $ac_link) 2>&5
9553   ac_status=$?
9554   echo "$as_me:9554: \$? = $ac_status" >&5
9555   (exit $ac_status); } &&
9556          { ac_try='test -s conftest$ac_exeext'
9557   { (eval echo "$as_me:9557: \"$ac_try\"") >&5
9558   (eval $ac_try) 2>&5
9559   ac_status=$?
9560   echo "$as_me:9560: \$? = $ac_status" >&5
9561   (exit $ac_status); }; }; then
9562   eval "$as_ac_var=yes"
9563 else
9564   echo "$as_me: failed program was:" >&5
9565 cat conftest.$ac_ext >&5
9566 eval "$as_ac_var=no"
9567 fi
9568 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9569 fi
9570 echo "$as_me:9570: result: `eval echo '${'$as_ac_var'}'`" >&5
9571 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9572 if test `eval echo '${'$as_ac_var'}'` = yes; then
9573   cat >>confdefs.h <<EOF
9574 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9575 EOF
9576
9577 fi
9578 done
9579
9580 for ac_func in open64 _open64 __open64 creat64
9581 do
9582 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9583 echo "$as_me:9583: checking for $ac_func" >&5
9584 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9585 if eval "test \"\${$as_ac_var+set}\" = set"; then
9586   echo $ECHO_N "(cached) $ECHO_C" >&6
9587 else
9588   cat >conftest.$ac_ext <<_ACEOF
9589 #line 9589 "configure"
9590 #include "confdefs.h"
9591 /* System header to define __stub macros and hopefully few prototypes,
9592     which can conflict with char $ac_func (); below.  */
9593 #include <assert.h>
9594 /* Override any gcc2 internal prototype to avoid an error.  */
9595 #ifdef __cplusplus
9596 extern "C"
9597 #endif
9598 /* We use char because int might match the return type of a gcc2
9599    builtin and then its argument prototype would still apply.  */
9600 char $ac_func ();
9601 char (*f) ();
9602
9603 int
9604 main ()
9605 {
9606 /* The GNU C library defines this for functions which it implements
9607     to always fail with ENOSYS.  Some functions are actually named
9608     something starting with __ and the normal name is an alias.  */
9609 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9610 choke me
9611 #else
9612 f = $ac_func;
9613 #endif
9614
9615   ;
9616   return 0;
9617 }
9618 _ACEOF
9619 rm -f conftest.$ac_objext conftest$ac_exeext
9620 if { (eval echo "$as_me:9620: \"$ac_link\"") >&5
9621   (eval $ac_link) 2>&5
9622   ac_status=$?
9623   echo "$as_me:9623: \$? = $ac_status" >&5
9624   (exit $ac_status); } &&
9625          { ac_try='test -s conftest$ac_exeext'
9626   { (eval echo "$as_me:9626: \"$ac_try\"") >&5
9627   (eval $ac_try) 2>&5
9628   ac_status=$?
9629   echo "$as_me:9629: \$? = $ac_status" >&5
9630   (exit $ac_status); }; }; then
9631   eval "$as_ac_var=yes"
9632 else
9633   echo "$as_me: failed program was:" >&5
9634 cat conftest.$ac_ext >&5
9635 eval "$as_ac_var=no"
9636 fi
9637 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9638 fi
9639 echo "$as_me:9639: result: `eval echo '${'$as_ac_var'}'`" >&5
9640 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9641 if test `eval echo '${'$as_ac_var'}'` = yes; then
9642   cat >>confdefs.h <<EOF
9643 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9644 EOF
9645
9646 fi
9647 done
9648
9649 #
9650 # stat64 family may need <sys/stat.h> on some systems, notably ReliantUNIX
9651 #
9652
9653 if test x$ac_cv_func_stat64 = xno ; then
9654   echo "$as_me:9654: checking for stat64 in <sys/stat.h>" >&5
9655 echo $ECHO_N "checking for stat64 in <sys/stat.h>... $ECHO_C" >&6
9656   cat >conftest.$ac_ext <<_ACEOF
9657 #line 9657 "configure"
9658 #include "confdefs.h"
9659
9660 #if defined(HAVE_UNISTD_H)
9661 #include <unistd.h>
9662 #endif
9663 #include <sys/stat.h>
9664
9665 int
9666 main ()
9667 {
9668 struct stat64 st64; exit(stat64(".",&st64));
9669   ;
9670   return 0;
9671 }
9672 _ACEOF
9673 rm -f conftest.$ac_objext conftest$ac_exeext
9674 if { (eval echo "$as_me:9674: \"$ac_link\"") >&5
9675   (eval $ac_link) 2>&5
9676   ac_status=$?
9677   echo "$as_me:9677: \$? = $ac_status" >&5
9678   (exit $ac_status); } &&
9679          { ac_try='test -s conftest$ac_exeext'
9680   { (eval echo "$as_me:9680: \"$ac_try\"") >&5
9681   (eval $ac_try) 2>&5
9682   ac_status=$?
9683   echo "$as_me:9683: \$? = $ac_status" >&5
9684   (exit $ac_status); }; }; then
9685   ac_cv_func_stat64=yes
9686 else
9687   echo "$as_me: failed program was:" >&5
9688 cat conftest.$ac_ext >&5
9689 fi
9690 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9691   echo "$as_me:9691: result: $ac_cv_func_stat64" >&5
9692 echo "${ECHO_T}$ac_cv_func_stat64" >&6
9693   if test x$ac_cv_func_stat64 = xyes ; then
9694     cat >>confdefs.h <<\EOF
9695 #define HAVE_STAT64 1
9696 EOF
9697
9698   fi
9699 fi
9700
9701 if test x$ac_cv_func_lstat64 = xno ; then
9702   echo "$as_me:9702: checking for lstat64 in <sys/stat.h>" >&5
9703 echo $ECHO_N "checking for lstat64 in <sys/stat.h>... $ECHO_C" >&6
9704   cat >conftest.$ac_ext <<_ACEOF
9705 #line 9705 "configure"
9706 #include "confdefs.h"
9707
9708 #if defined(HAVE_UNISTD_H)
9709 #include <unistd.h>
9710 #endif
9711 #include <sys/stat.h>
9712
9713 int
9714 main ()
9715 {
9716 struct stat64 st64; exit(lstat64(".",&st64));
9717   ;
9718   return 0;
9719 }
9720 _ACEOF
9721 rm -f conftest.$ac_objext conftest$ac_exeext
9722 if { (eval echo "$as_me:9722: \"$ac_link\"") >&5
9723   (eval $ac_link) 2>&5
9724   ac_status=$?
9725   echo "$as_me:9725: \$? = $ac_status" >&5
9726   (exit $ac_status); } &&
9727          { ac_try='test -s conftest$ac_exeext'
9728   { (eval echo "$as_me:9728: \"$ac_try\"") >&5
9729   (eval $ac_try) 2>&5
9730   ac_status=$?
9731   echo "$as_me:9731: \$? = $ac_status" >&5
9732   (exit $ac_status); }; }; then
9733   ac_cv_func_lstat64=yes
9734 else
9735   echo "$as_me: failed program was:" >&5
9736 cat conftest.$ac_ext >&5
9737 fi
9738 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9739   echo "$as_me:9739: result: $ac_cv_func_lstat64" >&5
9740 echo "${ECHO_T}$ac_cv_func_lstat64" >&6
9741   if test x$ac_cv_func_lstat64 = xyes ; then
9742     cat >>confdefs.h <<\EOF
9743 #define HAVE_LSTAT64 1
9744 EOF
9745
9746   fi
9747 fi
9748
9749 if test x$ac_cv_func_fstat64 = xno ; then
9750   echo "$as_me:9750: checking for fstat64 in <sys/stat.h>" >&5
9751 echo $ECHO_N "checking for fstat64 in <sys/stat.h>... $ECHO_C" >&6
9752   cat >conftest.$ac_ext <<_ACEOF
9753 #line 9753 "configure"
9754 #include "confdefs.h"
9755
9756 #if defined(HAVE_UNISTD_H)
9757 #include <unistd.h>
9758 #endif
9759 #include <sys/stat.h>
9760
9761 int
9762 main ()
9763 {
9764 struct stat64 st64; exit(fstat64(0,&st64));
9765   ;
9766   return 0;
9767 }
9768 _ACEOF
9769 rm -f conftest.$ac_objext conftest$ac_exeext
9770 if { (eval echo "$as_me:9770: \"$ac_link\"") >&5
9771   (eval $ac_link) 2>&5
9772   ac_status=$?
9773   echo "$as_me:9773: \$? = $ac_status" >&5
9774   (exit $ac_status); } &&
9775          { ac_try='test -s conftest$ac_exeext'
9776   { (eval echo "$as_me:9776: \"$ac_try\"") >&5
9777   (eval $ac_try) 2>&5
9778   ac_status=$?
9779   echo "$as_me:9779: \$? = $ac_status" >&5
9780   (exit $ac_status); }; }; then
9781   ac_cv_func_fstat64=yes
9782 else
9783   echo "$as_me: failed program was:" >&5
9784 cat conftest.$ac_ext >&5
9785 fi
9786 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9787   echo "$as_me:9787: result: $ac_cv_func_fstat64" >&5
9788 echo "${ECHO_T}$ac_cv_func_fstat64" >&6
9789   if test x$ac_cv_func_fstat64 = xyes ; then
9790     cat >>confdefs.h <<\EOF
9791 #define HAVE_FSTAT64 1
9792 EOF
9793
9794   fi
9795 fi
9796
9797 #####################################
9798 # we might need the resolv library on some systems
9799
9800 echo "$as_me:9800: checking for dn_expand in -lresolv" >&5
9801 echo $ECHO_N "checking for dn_expand in -lresolv... $ECHO_C" >&6
9802 if test "${ac_cv_lib_resolv_dn_expand+set}" = set; then
9803   echo $ECHO_N "(cached) $ECHO_C" >&6
9804 else
9805   ac_check_lib_save_LIBS=$LIBS
9806 LIBS="-lresolv  $LIBS"
9807 cat >conftest.$ac_ext <<_ACEOF
9808 #line 9808 "configure"
9809 #include "confdefs.h"
9810
9811 /* Override any gcc2 internal prototype to avoid an error.  */
9812 #ifdef __cplusplus
9813 extern "C"
9814 #endif
9815 /* We use char because int might match the return type of a gcc2
9816    builtin and then its argument prototype would still apply.  */
9817 char dn_expand ();
9818 int
9819 main ()
9820 {
9821 dn_expand ();
9822   ;
9823   return 0;
9824 }
9825 _ACEOF
9826 rm -f conftest.$ac_objext conftest$ac_exeext
9827 if { (eval echo "$as_me:9827: \"$ac_link\"") >&5
9828   (eval $ac_link) 2>&5
9829   ac_status=$?
9830   echo "$as_me:9830: \$? = $ac_status" >&5
9831   (exit $ac_status); } &&
9832          { ac_try='test -s conftest$ac_exeext'
9833   { (eval echo "$as_me:9833: \"$ac_try\"") >&5
9834   (eval $ac_try) 2>&5
9835   ac_status=$?
9836   echo "$as_me:9836: \$? = $ac_status" >&5
9837   (exit $ac_status); }; }; then
9838   ac_cv_lib_resolv_dn_expand=yes
9839 else
9840   echo "$as_me: failed program was:" >&5
9841 cat conftest.$ac_ext >&5
9842 ac_cv_lib_resolv_dn_expand=no
9843 fi
9844 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9845 LIBS=$ac_check_lib_save_LIBS
9846 fi
9847 echo "$as_me:9847: result: $ac_cv_lib_resolv_dn_expand" >&5
9848 echo "${ECHO_T}$ac_cv_lib_resolv_dn_expand" >&6
9849 if test $ac_cv_lib_resolv_dn_expand = yes; then
9850   cat >>confdefs.h <<EOF
9851 #define HAVE_LIBRESOLV 1
9852 EOF
9853
9854   LIBS="-lresolv $LIBS"
9855
9856 fi
9857
9858 #
9859 # Check for the functions putprpwnam, set_auth_parameters,
9860 # getspnam, bigcrypt and getprpwnam in -lsec and -lsecurity
9861 # Needed for OSF1 and HPUX.
9862 #
9863
9864 case "$LIBS" in
9865   *-lsecurity*)
9866 for ac_func in putprpwnam
9867 do
9868 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9869 echo "$as_me:9869: checking for $ac_func" >&5
9870 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9871 if eval "test \"\${$as_ac_var+set}\" = set"; then
9872   echo $ECHO_N "(cached) $ECHO_C" >&6
9873 else
9874   cat >conftest.$ac_ext <<_ACEOF
9875 #line 9875 "configure"
9876 #include "confdefs.h"
9877 /* System header to define __stub macros and hopefully few prototypes,
9878     which can conflict with char $ac_func (); below.  */
9879 #include <assert.h>
9880 /* Override any gcc2 internal prototype to avoid an error.  */
9881 #ifdef __cplusplus
9882 extern "C"
9883 #endif
9884 /* We use char because int might match the return type of a gcc2
9885    builtin and then its argument prototype would still apply.  */
9886 char $ac_func ();
9887 char (*f) ();
9888
9889 int
9890 main ()
9891 {
9892 /* The GNU C library defines this for functions which it implements
9893     to always fail with ENOSYS.  Some functions are actually named
9894     something starting with __ and the normal name is an alias.  */
9895 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9896 choke me
9897 #else
9898 f = $ac_func;
9899 #endif
9900
9901   ;
9902   return 0;
9903 }
9904 _ACEOF
9905 rm -f conftest.$ac_objext conftest$ac_exeext
9906 if { (eval echo "$as_me:9906: \"$ac_link\"") >&5
9907   (eval $ac_link) 2>&5
9908   ac_status=$?
9909   echo "$as_me:9909: \$? = $ac_status" >&5
9910   (exit $ac_status); } &&
9911          { ac_try='test -s conftest$ac_exeext'
9912   { (eval echo "$as_me:9912: \"$ac_try\"") >&5
9913   (eval $ac_try) 2>&5
9914   ac_status=$?
9915   echo "$as_me:9915: \$? = $ac_status" >&5
9916   (exit $ac_status); }; }; then
9917   eval "$as_ac_var=yes"
9918 else
9919   echo "$as_me: failed program was:" >&5
9920 cat conftest.$ac_ext >&5
9921 eval "$as_ac_var=no"
9922 fi
9923 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9924 fi
9925 echo "$as_me:9925: result: `eval echo '${'$as_ac_var'}'`" >&5
9926 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9927 if test `eval echo '${'$as_ac_var'}'` = yes; then
9928   cat >>confdefs.h <<EOF
9929 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9930 EOF
9931
9932 fi
9933 done
9934  ;;
9935   *)
9936 echo "$as_me:9936: checking for putprpwnam in -lsecurity" >&5
9937 echo $ECHO_N "checking for putprpwnam in -lsecurity... $ECHO_C" >&6
9938 if test "${ac_cv_lib_security_putprpwnam+set}" = set; then
9939   echo $ECHO_N "(cached) $ECHO_C" >&6
9940 else
9941   ac_check_lib_save_LIBS=$LIBS
9942 LIBS="-lsecurity  $LIBS"
9943 cat >conftest.$ac_ext <<_ACEOF
9944 #line 9944 "configure"
9945 #include "confdefs.h"
9946
9947 /* Override any gcc2 internal prototype to avoid an error.  */
9948 #ifdef __cplusplus
9949 extern "C"
9950 #endif
9951 /* We use char because int might match the return type of a gcc2
9952    builtin and then its argument prototype would still apply.  */
9953 char putprpwnam ();
9954 int
9955 main ()
9956 {
9957 putprpwnam ();
9958   ;
9959   return 0;
9960 }
9961 _ACEOF
9962 rm -f conftest.$ac_objext conftest$ac_exeext
9963 if { (eval echo "$as_me:9963: \"$ac_link\"") >&5
9964   (eval $ac_link) 2>&5
9965   ac_status=$?
9966   echo "$as_me:9966: \$? = $ac_status" >&5
9967   (exit $ac_status); } &&
9968          { ac_try='test -s conftest$ac_exeext'
9969   { (eval echo "$as_me:9969: \"$ac_try\"") >&5
9970   (eval $ac_try) 2>&5
9971   ac_status=$?
9972   echo "$as_me:9972: \$? = $ac_status" >&5
9973   (exit $ac_status); }; }; then
9974   ac_cv_lib_security_putprpwnam=yes
9975 else
9976   echo "$as_me: failed program was:" >&5
9977 cat conftest.$ac_ext >&5
9978 ac_cv_lib_security_putprpwnam=no
9979 fi
9980 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9981 LIBS=$ac_check_lib_save_LIBS
9982 fi
9983 echo "$as_me:9983: result: $ac_cv_lib_security_putprpwnam" >&5
9984 echo "${ECHO_T}$ac_cv_lib_security_putprpwnam" >&6
9985 if test $ac_cv_lib_security_putprpwnam = yes; then
9986   cat >>confdefs.h <<EOF
9987 #define HAVE_LIBSECURITY 1
9988 EOF
9989
9990   LIBS="-lsecurity $LIBS"
9991
9992 fi
9993
9994 for ac_func in putprpwnam
9995 do
9996 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9997 echo "$as_me:9997: checking for $ac_func" >&5
9998 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9999 if eval "test \"\${$as_ac_var+set}\" = set"; then
10000   echo $ECHO_N "(cached) $ECHO_C" >&6
10001 else
10002   cat >conftest.$ac_ext <<_ACEOF
10003 #line 10003 "configure"
10004 #include "confdefs.h"
10005 /* System header to define __stub macros and hopefully few prototypes,
10006     which can conflict with char $ac_func (); below.  */
10007 #include <assert.h>
10008 /* Override any gcc2 internal prototype to avoid an error.  */
10009 #ifdef __cplusplus
10010 extern "C"
10011 #endif
10012 /* We use char because int might match the return type of a gcc2
10013    builtin and then its argument prototype would still apply.  */
10014 char $ac_func ();
10015 char (*f) ();
10016
10017 int
10018 main ()
10019 {
10020 /* The GNU C library defines this for functions which it implements
10021     to always fail with ENOSYS.  Some functions are actually named
10022     something starting with __ and the normal name is an alias.  */
10023 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10024 choke me
10025 #else
10026 f = $ac_func;
10027 #endif
10028
10029   ;
10030   return 0;
10031 }
10032 _ACEOF
10033 rm -f conftest.$ac_objext conftest$ac_exeext
10034 if { (eval echo "$as_me:10034: \"$ac_link\"") >&5
10035   (eval $ac_link) 2>&5
10036   ac_status=$?
10037   echo "$as_me:10037: \$? = $ac_status" >&5
10038   (exit $ac_status); } &&
10039          { ac_try='test -s conftest$ac_exeext'
10040   { (eval echo "$as_me:10040: \"$ac_try\"") >&5
10041   (eval $ac_try) 2>&5
10042   ac_status=$?
10043   echo "$as_me:10043: \$? = $ac_status" >&5
10044   (exit $ac_status); }; }; then
10045   eval "$as_ac_var=yes"
10046 else
10047   echo "$as_me: failed program was:" >&5
10048 cat conftest.$ac_ext >&5
10049 eval "$as_ac_var=no"
10050 fi
10051 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10052 fi
10053 echo "$as_me:10053: result: `eval echo '${'$as_ac_var'}'`" >&5
10054 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10055 if test `eval echo '${'$as_ac_var'}'` = yes; then
10056   cat >>confdefs.h <<EOF
10057 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10058 EOF
10059
10060 fi
10061 done
10062
10063   ;;
10064   esac
10065
10066 case "$LIBS" in
10067   *-lsec*)
10068 for ac_func in putprpwnam
10069 do
10070 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10071 echo "$as_me:10071: checking for $ac_func" >&5
10072 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10073 if eval "test \"\${$as_ac_var+set}\" = set"; then
10074   echo $ECHO_N "(cached) $ECHO_C" >&6
10075 else
10076   cat >conftest.$ac_ext <<_ACEOF
10077 #line 10077 "configure"
10078 #include "confdefs.h"
10079 /* System header to define __stub macros and hopefully few prototypes,
10080     which can conflict with char $ac_func (); below.  */
10081 #include <assert.h>
10082 /* Override any gcc2 internal prototype to avoid an error.  */
10083 #ifdef __cplusplus
10084 extern "C"
10085 #endif
10086 /* We use char because int might match the return type of a gcc2
10087    builtin and then its argument prototype would still apply.  */
10088 char $ac_func ();
10089 char (*f) ();
10090
10091 int
10092 main ()
10093 {
10094 /* The GNU C library defines this for functions which it implements
10095     to always fail with ENOSYS.  Some functions are actually named
10096     something starting with __ and the normal name is an alias.  */
10097 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10098 choke me
10099 #else
10100 f = $ac_func;
10101 #endif
10102
10103   ;
10104   return 0;
10105 }
10106 _ACEOF
10107 rm -f conftest.$ac_objext conftest$ac_exeext
10108 if { (eval echo "$as_me:10108: \"$ac_link\"") >&5
10109   (eval $ac_link) 2>&5
10110   ac_status=$?
10111   echo "$as_me:10111: \$? = $ac_status" >&5
10112   (exit $ac_status); } &&
10113          { ac_try='test -s conftest$ac_exeext'
10114   { (eval echo "$as_me:10114: \"$ac_try\"") >&5
10115   (eval $ac_try) 2>&5
10116   ac_status=$?
10117   echo "$as_me:10117: \$? = $ac_status" >&5
10118   (exit $ac_status); }; }; then
10119   eval "$as_ac_var=yes"
10120 else
10121   echo "$as_me: failed program was:" >&5
10122 cat conftest.$ac_ext >&5
10123 eval "$as_ac_var=no"
10124 fi
10125 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10126 fi
10127 echo "$as_me:10127: result: `eval echo '${'$as_ac_var'}'`" >&5
10128 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10129 if test `eval echo '${'$as_ac_var'}'` = yes; then
10130   cat >>confdefs.h <<EOF
10131 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10132 EOF
10133
10134 fi
10135 done
10136  ;;
10137   *)
10138 echo "$as_me:10138: checking for putprpwnam in -lsec" >&5
10139 echo $ECHO_N "checking for putprpwnam in -lsec... $ECHO_C" >&6
10140 if test "${ac_cv_lib_sec_putprpwnam+set}" = set; then
10141   echo $ECHO_N "(cached) $ECHO_C" >&6
10142 else
10143   ac_check_lib_save_LIBS=$LIBS
10144 LIBS="-lsec  $LIBS"
10145 cat >conftest.$ac_ext <<_ACEOF
10146 #line 10146 "configure"
10147 #include "confdefs.h"
10148
10149 /* Override any gcc2 internal prototype to avoid an error.  */
10150 #ifdef __cplusplus
10151 extern "C"
10152 #endif
10153 /* We use char because int might match the return type of a gcc2
10154    builtin and then its argument prototype would still apply.  */
10155 char putprpwnam ();
10156 int
10157 main ()
10158 {
10159 putprpwnam ();
10160   ;
10161   return 0;
10162 }
10163 _ACEOF
10164 rm -f conftest.$ac_objext conftest$ac_exeext
10165 if { (eval echo "$as_me:10165: \"$ac_link\"") >&5
10166   (eval $ac_link) 2>&5
10167   ac_status=$?
10168   echo "$as_me:10168: \$? = $ac_status" >&5
10169   (exit $ac_status); } &&
10170          { ac_try='test -s conftest$ac_exeext'
10171   { (eval echo "$as_me:10171: \"$ac_try\"") >&5
10172   (eval $ac_try) 2>&5
10173   ac_status=$?
10174   echo "$as_me:10174: \$? = $ac_status" >&5
10175   (exit $ac_status); }; }; then
10176   ac_cv_lib_sec_putprpwnam=yes
10177 else
10178   echo "$as_me: failed program was:" >&5
10179 cat conftest.$ac_ext >&5
10180 ac_cv_lib_sec_putprpwnam=no
10181 fi
10182 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10183 LIBS=$ac_check_lib_save_LIBS
10184 fi
10185 echo "$as_me:10185: result: $ac_cv_lib_sec_putprpwnam" >&5
10186 echo "${ECHO_T}$ac_cv_lib_sec_putprpwnam" >&6
10187 if test $ac_cv_lib_sec_putprpwnam = yes; then
10188   cat >>confdefs.h <<EOF
10189 #define HAVE_LIBSEC 1
10190 EOF
10191
10192   LIBS="-lsec $LIBS"
10193
10194 fi
10195
10196 for ac_func in putprpwnam
10197 do
10198 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10199 echo "$as_me:10199: checking for $ac_func" >&5
10200 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10201 if eval "test \"\${$as_ac_var+set}\" = set"; then
10202   echo $ECHO_N "(cached) $ECHO_C" >&6
10203 else
10204   cat >conftest.$ac_ext <<_ACEOF
10205 #line 10205 "configure"
10206 #include "confdefs.h"
10207 /* System header to define __stub macros and hopefully few prototypes,
10208     which can conflict with char $ac_func (); below.  */
10209 #include <assert.h>
10210 /* Override any gcc2 internal prototype to avoid an error.  */
10211 #ifdef __cplusplus
10212 extern "C"
10213 #endif
10214 /* We use char because int might match the return type of a gcc2
10215    builtin and then its argument prototype would still apply.  */
10216 char $ac_func ();
10217 char (*f) ();
10218
10219 int
10220 main ()
10221 {
10222 /* The GNU C library defines this for functions which it implements
10223     to always fail with ENOSYS.  Some functions are actually named
10224     something starting with __ and the normal name is an alias.  */
10225 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10226 choke me
10227 #else
10228 f = $ac_func;
10229 #endif
10230
10231   ;
10232   return 0;
10233 }
10234 _ACEOF
10235 rm -f conftest.$ac_objext conftest$ac_exeext
10236 if { (eval echo "$as_me:10236: \"$ac_link\"") >&5
10237   (eval $ac_link) 2>&5
10238   ac_status=$?
10239   echo "$as_me:10239: \$? = $ac_status" >&5
10240   (exit $ac_status); } &&
10241          { ac_try='test -s conftest$ac_exeext'
10242   { (eval echo "$as_me:10242: \"$ac_try\"") >&5
10243   (eval $ac_try) 2>&5
10244   ac_status=$?
10245   echo "$as_me:10245: \$? = $ac_status" >&5
10246   (exit $ac_status); }; }; then
10247   eval "$as_ac_var=yes"
10248 else
10249   echo "$as_me: failed program was:" >&5
10250 cat conftest.$ac_ext >&5
10251 eval "$as_ac_var=no"
10252 fi
10253 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10254 fi
10255 echo "$as_me:10255: result: `eval echo '${'$as_ac_var'}'`" >&5
10256 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10257 if test `eval echo '${'$as_ac_var'}'` = yes; then
10258   cat >>confdefs.h <<EOF
10259 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10260 EOF
10261
10262 fi
10263 done
10264
10265   ;;
10266   esac
10267
10268 case "$LIBS" in
10269   *-lsecurity*)
10270 for ac_func in set_auth_parameters
10271 do
10272 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10273 echo "$as_me:10273: checking for $ac_func" >&5
10274 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10275 if eval "test \"\${$as_ac_var+set}\" = set"; then
10276   echo $ECHO_N "(cached) $ECHO_C" >&6
10277 else
10278   cat >conftest.$ac_ext <<_ACEOF
10279 #line 10279 "configure"
10280 #include "confdefs.h"
10281 /* System header to define __stub macros and hopefully few prototypes,
10282     which can conflict with char $ac_func (); below.  */
10283 #include <assert.h>
10284 /* Override any gcc2 internal prototype to avoid an error.  */
10285 #ifdef __cplusplus
10286 extern "C"
10287 #endif
10288 /* We use char because int might match the return type of a gcc2
10289    builtin and then its argument prototype would still apply.  */
10290 char $ac_func ();
10291 char (*f) ();
10292
10293 int
10294 main ()
10295 {
10296 /* The GNU C library defines this for functions which it implements
10297     to always fail with ENOSYS.  Some functions are actually named
10298     something starting with __ and the normal name is an alias.  */
10299 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10300 choke me
10301 #else
10302 f = $ac_func;
10303 #endif
10304
10305   ;
10306   return 0;
10307 }
10308 _ACEOF
10309 rm -f conftest.$ac_objext conftest$ac_exeext
10310 if { (eval echo "$as_me:10310: \"$ac_link\"") >&5
10311   (eval $ac_link) 2>&5
10312   ac_status=$?
10313   echo "$as_me:10313: \$? = $ac_status" >&5
10314   (exit $ac_status); } &&
10315          { ac_try='test -s conftest$ac_exeext'
10316   { (eval echo "$as_me:10316: \"$ac_try\"") >&5
10317   (eval $ac_try) 2>&5
10318   ac_status=$?
10319   echo "$as_me:10319: \$? = $ac_status" >&5
10320   (exit $ac_status); }; }; then
10321   eval "$as_ac_var=yes"
10322 else
10323   echo "$as_me: failed program was:" >&5
10324 cat conftest.$ac_ext >&5
10325 eval "$as_ac_var=no"
10326 fi
10327 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10328 fi
10329 echo "$as_me:10329: result: `eval echo '${'$as_ac_var'}'`" >&5
10330 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10331 if test `eval echo '${'$as_ac_var'}'` = yes; then
10332   cat >>confdefs.h <<EOF
10333 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10334 EOF
10335
10336 fi
10337 done
10338  ;;
10339   *)
10340 echo "$as_me:10340: checking for set_auth_parameters in -lsecurity" >&5
10341 echo $ECHO_N "checking for set_auth_parameters in -lsecurity... $ECHO_C" >&6
10342 if test "${ac_cv_lib_security_set_auth_parameters+set}" = set; then
10343   echo $ECHO_N "(cached) $ECHO_C" >&6
10344 else
10345   ac_check_lib_save_LIBS=$LIBS
10346 LIBS="-lsecurity  $LIBS"
10347 cat >conftest.$ac_ext <<_ACEOF
10348 #line 10348 "configure"
10349 #include "confdefs.h"
10350
10351 /* Override any gcc2 internal prototype to avoid an error.  */
10352 #ifdef __cplusplus
10353 extern "C"
10354 #endif
10355 /* We use char because int might match the return type of a gcc2
10356    builtin and then its argument prototype would still apply.  */
10357 char set_auth_parameters ();
10358 int
10359 main ()
10360 {
10361 set_auth_parameters ();
10362   ;
10363   return 0;
10364 }
10365 _ACEOF
10366 rm -f conftest.$ac_objext conftest$ac_exeext
10367 if { (eval echo "$as_me:10367: \"$ac_link\"") >&5
10368   (eval $ac_link) 2>&5
10369   ac_status=$?
10370   echo "$as_me:10370: \$? = $ac_status" >&5
10371   (exit $ac_status); } &&
10372          { ac_try='test -s conftest$ac_exeext'
10373   { (eval echo "$as_me:10373: \"$ac_try\"") >&5
10374   (eval $ac_try) 2>&5
10375   ac_status=$?
10376   echo "$as_me:10376: \$? = $ac_status" >&5
10377   (exit $ac_status); }; }; then
10378   ac_cv_lib_security_set_auth_parameters=yes
10379 else
10380   echo "$as_me: failed program was:" >&5
10381 cat conftest.$ac_ext >&5
10382 ac_cv_lib_security_set_auth_parameters=no
10383 fi
10384 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10385 LIBS=$ac_check_lib_save_LIBS
10386 fi
10387 echo "$as_me:10387: result: $ac_cv_lib_security_set_auth_parameters" >&5
10388 echo "${ECHO_T}$ac_cv_lib_security_set_auth_parameters" >&6
10389 if test $ac_cv_lib_security_set_auth_parameters = yes; then
10390   cat >>confdefs.h <<EOF
10391 #define HAVE_LIBSECURITY 1
10392 EOF
10393
10394   LIBS="-lsecurity $LIBS"
10395
10396 fi
10397
10398 for ac_func in set_auth_parameters
10399 do
10400 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10401 echo "$as_me:10401: checking for $ac_func" >&5
10402 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10403 if eval "test \"\${$as_ac_var+set}\" = set"; then
10404   echo $ECHO_N "(cached) $ECHO_C" >&6
10405 else
10406   cat >conftest.$ac_ext <<_ACEOF
10407 #line 10407 "configure"
10408 #include "confdefs.h"
10409 /* System header to define __stub macros and hopefully few prototypes,
10410     which can conflict with char $ac_func (); below.  */
10411 #include <assert.h>
10412 /* Override any gcc2 internal prototype to avoid an error.  */
10413 #ifdef __cplusplus
10414 extern "C"
10415 #endif
10416 /* We use char because int might match the return type of a gcc2
10417    builtin and then its argument prototype would still apply.  */
10418 char $ac_func ();
10419 char (*f) ();
10420
10421 int
10422 main ()
10423 {
10424 /* The GNU C library defines this for functions which it implements
10425     to always fail with ENOSYS.  Some functions are actually named
10426     something starting with __ and the normal name is an alias.  */
10427 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10428 choke me
10429 #else
10430 f = $ac_func;
10431 #endif
10432
10433   ;
10434   return 0;
10435 }
10436 _ACEOF
10437 rm -f conftest.$ac_objext conftest$ac_exeext
10438 if { (eval echo "$as_me:10438: \"$ac_link\"") >&5
10439   (eval $ac_link) 2>&5
10440   ac_status=$?
10441   echo "$as_me:10441: \$? = $ac_status" >&5
10442   (exit $ac_status); } &&
10443          { ac_try='test -s conftest$ac_exeext'
10444   { (eval echo "$as_me:10444: \"$ac_try\"") >&5
10445   (eval $ac_try) 2>&5
10446   ac_status=$?
10447   echo "$as_me:10447: \$? = $ac_status" >&5
10448   (exit $ac_status); }; }; then
10449   eval "$as_ac_var=yes"
10450 else
10451   echo "$as_me: failed program was:" >&5
10452 cat conftest.$ac_ext >&5
10453 eval "$as_ac_var=no"
10454 fi
10455 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10456 fi
10457 echo "$as_me:10457: result: `eval echo '${'$as_ac_var'}'`" >&5
10458 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10459 if test `eval echo '${'$as_ac_var'}'` = yes; then
10460   cat >>confdefs.h <<EOF
10461 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10462 EOF
10463
10464 fi
10465 done
10466
10467   ;;
10468   esac
10469
10470 case "$LIBS" in
10471   *-lsec*)
10472 for ac_func in set_auth_parameters
10473 do
10474 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10475 echo "$as_me:10475: checking for $ac_func" >&5
10476 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10477 if eval "test \"\${$as_ac_var+set}\" = set"; then
10478   echo $ECHO_N "(cached) $ECHO_C" >&6
10479 else
10480   cat >conftest.$ac_ext <<_ACEOF
10481 #line 10481 "configure"
10482 #include "confdefs.h"
10483 /* System header to define __stub macros and hopefully few prototypes,
10484     which can conflict with char $ac_func (); below.  */
10485 #include <assert.h>
10486 /* Override any gcc2 internal prototype to avoid an error.  */
10487 #ifdef __cplusplus
10488 extern "C"
10489 #endif
10490 /* We use char because int might match the return type of a gcc2
10491    builtin and then its argument prototype would still apply.  */
10492 char $ac_func ();
10493 char (*f) ();
10494
10495 int
10496 main ()
10497 {
10498 /* The GNU C library defines this for functions which it implements
10499     to always fail with ENOSYS.  Some functions are actually named
10500     something starting with __ and the normal name is an alias.  */
10501 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10502 choke me
10503 #else
10504 f = $ac_func;
10505 #endif
10506
10507   ;
10508   return 0;
10509 }
10510 _ACEOF
10511 rm -f conftest.$ac_objext conftest$ac_exeext
10512 if { (eval echo "$as_me:10512: \"$ac_link\"") >&5
10513   (eval $ac_link) 2>&5
10514   ac_status=$?
10515   echo "$as_me:10515: \$? = $ac_status" >&5
10516   (exit $ac_status); } &&
10517          { ac_try='test -s conftest$ac_exeext'
10518   { (eval echo "$as_me:10518: \"$ac_try\"") >&5
10519   (eval $ac_try) 2>&5
10520   ac_status=$?
10521   echo "$as_me:10521: \$? = $ac_status" >&5
10522   (exit $ac_status); }; }; then
10523   eval "$as_ac_var=yes"
10524 else
10525   echo "$as_me: failed program was:" >&5
10526 cat conftest.$ac_ext >&5
10527 eval "$as_ac_var=no"
10528 fi
10529 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10530 fi
10531 echo "$as_me:10531: result: `eval echo '${'$as_ac_var'}'`" >&5
10532 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10533 if test `eval echo '${'$as_ac_var'}'` = yes; then
10534   cat >>confdefs.h <<EOF
10535 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10536 EOF
10537
10538 fi
10539 done
10540  ;;
10541   *)
10542 echo "$as_me:10542: checking for set_auth_parameters in -lsec" >&5
10543 echo $ECHO_N "checking for set_auth_parameters in -lsec... $ECHO_C" >&6
10544 if test "${ac_cv_lib_sec_set_auth_parameters+set}" = set; then
10545   echo $ECHO_N "(cached) $ECHO_C" >&6
10546 else
10547   ac_check_lib_save_LIBS=$LIBS
10548 LIBS="-lsec  $LIBS"
10549 cat >conftest.$ac_ext <<_ACEOF
10550 #line 10550 "configure"
10551 #include "confdefs.h"
10552
10553 /* Override any gcc2 internal prototype to avoid an error.  */
10554 #ifdef __cplusplus
10555 extern "C"
10556 #endif
10557 /* We use char because int might match the return type of a gcc2
10558    builtin and then its argument prototype would still apply.  */
10559 char set_auth_parameters ();
10560 int
10561 main ()
10562 {
10563 set_auth_parameters ();
10564   ;
10565   return 0;
10566 }
10567 _ACEOF
10568 rm -f conftest.$ac_objext conftest$ac_exeext
10569 if { (eval echo "$as_me:10569: \"$ac_link\"") >&5
10570   (eval $ac_link) 2>&5
10571   ac_status=$?
10572   echo "$as_me:10572: \$? = $ac_status" >&5
10573   (exit $ac_status); } &&
10574          { ac_try='test -s conftest$ac_exeext'
10575   { (eval echo "$as_me:10575: \"$ac_try\"") >&5
10576   (eval $ac_try) 2>&5
10577   ac_status=$?
10578   echo "$as_me:10578: \$? = $ac_status" >&5
10579   (exit $ac_status); }; }; then
10580   ac_cv_lib_sec_set_auth_parameters=yes
10581 else
10582   echo "$as_me: failed program was:" >&5
10583 cat conftest.$ac_ext >&5
10584 ac_cv_lib_sec_set_auth_parameters=no
10585 fi
10586 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10587 LIBS=$ac_check_lib_save_LIBS
10588 fi
10589 echo "$as_me:10589: result: $ac_cv_lib_sec_set_auth_parameters" >&5
10590 echo "${ECHO_T}$ac_cv_lib_sec_set_auth_parameters" >&6
10591 if test $ac_cv_lib_sec_set_auth_parameters = yes; then
10592   cat >>confdefs.h <<EOF
10593 #define HAVE_LIBSEC 1
10594 EOF
10595
10596   LIBS="-lsec $LIBS"
10597
10598 fi
10599
10600 for ac_func in set_auth_parameters
10601 do
10602 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10603 echo "$as_me:10603: checking for $ac_func" >&5
10604 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10605 if eval "test \"\${$as_ac_var+set}\" = set"; then
10606   echo $ECHO_N "(cached) $ECHO_C" >&6
10607 else
10608   cat >conftest.$ac_ext <<_ACEOF
10609 #line 10609 "configure"
10610 #include "confdefs.h"
10611 /* System header to define __stub macros and hopefully few prototypes,
10612     which can conflict with char $ac_func (); below.  */
10613 #include <assert.h>
10614 /* Override any gcc2 internal prototype to avoid an error.  */
10615 #ifdef __cplusplus
10616 extern "C"
10617 #endif
10618 /* We use char because int might match the return type of a gcc2
10619    builtin and then its argument prototype would still apply.  */
10620 char $ac_func ();
10621 char (*f) ();
10622
10623 int
10624 main ()
10625 {
10626 /* The GNU C library defines this for functions which it implements
10627     to always fail with ENOSYS.  Some functions are actually named
10628     something starting with __ and the normal name is an alias.  */
10629 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10630 choke me
10631 #else
10632 f = $ac_func;
10633 #endif
10634
10635   ;
10636   return 0;
10637 }
10638 _ACEOF
10639 rm -f conftest.$ac_objext conftest$ac_exeext
10640 if { (eval echo "$as_me:10640: \"$ac_link\"") >&5
10641   (eval $ac_link) 2>&5
10642   ac_status=$?
10643   echo "$as_me:10643: \$? = $ac_status" >&5
10644   (exit $ac_status); } &&
10645          { ac_try='test -s conftest$ac_exeext'
10646   { (eval echo "$as_me:10646: \"$ac_try\"") >&5
10647   (eval $ac_try) 2>&5
10648   ac_status=$?
10649   echo "$as_me:10649: \$? = $ac_status" >&5
10650   (exit $ac_status); }; }; then
10651   eval "$as_ac_var=yes"
10652 else
10653   echo "$as_me: failed program was:" >&5
10654 cat conftest.$ac_ext >&5
10655 eval "$as_ac_var=no"
10656 fi
10657 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10658 fi
10659 echo "$as_me:10659: result: `eval echo '${'$as_ac_var'}'`" >&5
10660 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10661 if test `eval echo '${'$as_ac_var'}'` = yes; then
10662   cat >>confdefs.h <<EOF
10663 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10664 EOF
10665
10666 fi
10667 done
10668
10669   ;;
10670   esac
10671
10672 # UnixWare 7.x has its getspnam in -lgen
10673 case "$LIBS" in
10674   *-lgen*)
10675 for ac_func in getspnam
10676 do
10677 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10678 echo "$as_me:10678: checking for $ac_func" >&5
10679 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10680 if eval "test \"\${$as_ac_var+set}\" = set"; then
10681   echo $ECHO_N "(cached) $ECHO_C" >&6
10682 else
10683   cat >conftest.$ac_ext <<_ACEOF
10684 #line 10684 "configure"
10685 #include "confdefs.h"
10686 /* System header to define __stub macros and hopefully few prototypes,
10687     which can conflict with char $ac_func (); below.  */
10688 #include <assert.h>
10689 /* Override any gcc2 internal prototype to avoid an error.  */
10690 #ifdef __cplusplus
10691 extern "C"
10692 #endif
10693 /* We use char because int might match the return type of a gcc2
10694    builtin and then its argument prototype would still apply.  */
10695 char $ac_func ();
10696 char (*f) ();
10697
10698 int
10699 main ()
10700 {
10701 /* The GNU C library defines this for functions which it implements
10702     to always fail with ENOSYS.  Some functions are actually named
10703     something starting with __ and the normal name is an alias.  */
10704 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10705 choke me
10706 #else
10707 f = $ac_func;
10708 #endif
10709
10710   ;
10711   return 0;
10712 }
10713 _ACEOF
10714 rm -f conftest.$ac_objext conftest$ac_exeext
10715 if { (eval echo "$as_me:10715: \"$ac_link\"") >&5
10716   (eval $ac_link) 2>&5
10717   ac_status=$?
10718   echo "$as_me:10718: \$? = $ac_status" >&5
10719   (exit $ac_status); } &&
10720          { ac_try='test -s conftest$ac_exeext'
10721   { (eval echo "$as_me:10721: \"$ac_try\"") >&5
10722   (eval $ac_try) 2>&5
10723   ac_status=$?
10724   echo "$as_me:10724: \$? = $ac_status" >&5
10725   (exit $ac_status); }; }; then
10726   eval "$as_ac_var=yes"
10727 else
10728   echo "$as_me: failed program was:" >&5
10729 cat conftest.$ac_ext >&5
10730 eval "$as_ac_var=no"
10731 fi
10732 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10733 fi
10734 echo "$as_me:10734: result: `eval echo '${'$as_ac_var'}'`" >&5
10735 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10736 if test `eval echo '${'$as_ac_var'}'` = yes; then
10737   cat >>confdefs.h <<EOF
10738 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10739 EOF
10740
10741 fi
10742 done
10743  ;;
10744   *)
10745 echo "$as_me:10745: checking for getspnam in -lgen" >&5
10746 echo $ECHO_N "checking for getspnam in -lgen... $ECHO_C" >&6
10747 if test "${ac_cv_lib_gen_getspnam+set}" = set; then
10748   echo $ECHO_N "(cached) $ECHO_C" >&6
10749 else
10750   ac_check_lib_save_LIBS=$LIBS
10751 LIBS="-lgen  $LIBS"
10752 cat >conftest.$ac_ext <<_ACEOF
10753 #line 10753 "configure"
10754 #include "confdefs.h"
10755
10756 /* Override any gcc2 internal prototype to avoid an error.  */
10757 #ifdef __cplusplus
10758 extern "C"
10759 #endif
10760 /* We use char because int might match the return type of a gcc2
10761    builtin and then its argument prototype would still apply.  */
10762 char getspnam ();
10763 int
10764 main ()
10765 {
10766 getspnam ();
10767   ;
10768   return 0;
10769 }
10770 _ACEOF
10771 rm -f conftest.$ac_objext conftest$ac_exeext
10772 if { (eval echo "$as_me:10772: \"$ac_link\"") >&5
10773   (eval $ac_link) 2>&5
10774   ac_status=$?
10775   echo "$as_me:10775: \$? = $ac_status" >&5
10776   (exit $ac_status); } &&
10777          { ac_try='test -s conftest$ac_exeext'
10778   { (eval echo "$as_me:10778: \"$ac_try\"") >&5
10779   (eval $ac_try) 2>&5
10780   ac_status=$?
10781   echo "$as_me:10781: \$? = $ac_status" >&5
10782   (exit $ac_status); }; }; then
10783   ac_cv_lib_gen_getspnam=yes
10784 else
10785   echo "$as_me: failed program was:" >&5
10786 cat conftest.$ac_ext >&5
10787 ac_cv_lib_gen_getspnam=no
10788 fi
10789 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10790 LIBS=$ac_check_lib_save_LIBS
10791 fi
10792 echo "$as_me:10792: result: $ac_cv_lib_gen_getspnam" >&5
10793 echo "${ECHO_T}$ac_cv_lib_gen_getspnam" >&6
10794 if test $ac_cv_lib_gen_getspnam = yes; then
10795   cat >>confdefs.h <<EOF
10796 #define HAVE_LIBGEN 1
10797 EOF
10798
10799   LIBS="-lgen $LIBS"
10800
10801 fi
10802
10803 for ac_func in getspnam
10804 do
10805 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10806 echo "$as_me:10806: checking for $ac_func" >&5
10807 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10808 if eval "test \"\${$as_ac_var+set}\" = set"; then
10809   echo $ECHO_N "(cached) $ECHO_C" >&6
10810 else
10811   cat >conftest.$ac_ext <<_ACEOF
10812 #line 10812 "configure"
10813 #include "confdefs.h"
10814 /* System header to define __stub macros and hopefully few prototypes,
10815     which can conflict with char $ac_func (); below.  */
10816 #include <assert.h>
10817 /* Override any gcc2 internal prototype to avoid an error.  */
10818 #ifdef __cplusplus
10819 extern "C"
10820 #endif
10821 /* We use char because int might match the return type of a gcc2
10822    builtin and then its argument prototype would still apply.  */
10823 char $ac_func ();
10824 char (*f) ();
10825
10826 int
10827 main ()
10828 {
10829 /* The GNU C library defines this for functions which it implements
10830     to always fail with ENOSYS.  Some functions are actually named
10831     something starting with __ and the normal name is an alias.  */
10832 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10833 choke me
10834 #else
10835 f = $ac_func;
10836 #endif
10837
10838   ;
10839   return 0;
10840 }
10841 _ACEOF
10842 rm -f conftest.$ac_objext conftest$ac_exeext
10843 if { (eval echo "$as_me:10843: \"$ac_link\"") >&5
10844   (eval $ac_link) 2>&5
10845   ac_status=$?
10846   echo "$as_me:10846: \$? = $ac_status" >&5
10847   (exit $ac_status); } &&
10848          { ac_try='test -s conftest$ac_exeext'
10849   { (eval echo "$as_me:10849: \"$ac_try\"") >&5
10850   (eval $ac_try) 2>&5
10851   ac_status=$?
10852   echo "$as_me:10852: \$? = $ac_status" >&5
10853   (exit $ac_status); }; }; then
10854   eval "$as_ac_var=yes"
10855 else
10856   echo "$as_me: failed program was:" >&5
10857 cat conftest.$ac_ext >&5
10858 eval "$as_ac_var=no"
10859 fi
10860 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10861 fi
10862 echo "$as_me:10862: result: `eval echo '${'$as_ac_var'}'`" >&5
10863 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10864 if test `eval echo '${'$as_ac_var'}'` = yes; then
10865   cat >>confdefs.h <<EOF
10866 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10867 EOF
10868
10869 fi
10870 done
10871
10872   ;;
10873   esac
10874
10875 case "$LIBS" in
10876   *-lsecurity*)
10877 for ac_func in getspnam
10878 do
10879 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10880 echo "$as_me:10880: checking for $ac_func" >&5
10881 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10882 if eval "test \"\${$as_ac_var+set}\" = set"; then
10883   echo $ECHO_N "(cached) $ECHO_C" >&6
10884 else
10885   cat >conftest.$ac_ext <<_ACEOF
10886 #line 10886 "configure"
10887 #include "confdefs.h"
10888 /* System header to define __stub macros and hopefully few prototypes,
10889     which can conflict with char $ac_func (); below.  */
10890 #include <assert.h>
10891 /* Override any gcc2 internal prototype to avoid an error.  */
10892 #ifdef __cplusplus
10893 extern "C"
10894 #endif
10895 /* We use char because int might match the return type of a gcc2
10896    builtin and then its argument prototype would still apply.  */
10897 char $ac_func ();
10898 char (*f) ();
10899
10900 int
10901 main ()
10902 {
10903 /* The GNU C library defines this for functions which it implements
10904     to always fail with ENOSYS.  Some functions are actually named
10905     something starting with __ and the normal name is an alias.  */
10906 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10907 choke me
10908 #else
10909 f = $ac_func;
10910 #endif
10911
10912   ;
10913   return 0;
10914 }
10915 _ACEOF
10916 rm -f conftest.$ac_objext conftest$ac_exeext
10917 if { (eval echo "$as_me:10917: \"$ac_link\"") >&5
10918   (eval $ac_link) 2>&5
10919   ac_status=$?
10920   echo "$as_me:10920: \$? = $ac_status" >&5
10921   (exit $ac_status); } &&
10922          { ac_try='test -s conftest$ac_exeext'
10923   { (eval echo "$as_me:10923: \"$ac_try\"") >&5
10924   (eval $ac_try) 2>&5
10925   ac_status=$?
10926   echo "$as_me:10926: \$? = $ac_status" >&5
10927   (exit $ac_status); }; }; then
10928   eval "$as_ac_var=yes"
10929 else
10930   echo "$as_me: failed program was:" >&5
10931 cat conftest.$ac_ext >&5
10932 eval "$as_ac_var=no"
10933 fi
10934 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10935 fi
10936 echo "$as_me:10936: result: `eval echo '${'$as_ac_var'}'`" >&5
10937 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10938 if test `eval echo '${'$as_ac_var'}'` = yes; then
10939   cat >>confdefs.h <<EOF
10940 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10941 EOF
10942
10943 fi
10944 done
10945  ;;
10946   *)
10947 echo "$as_me:10947: checking for getspnam in -lsecurity" >&5
10948 echo $ECHO_N "checking for getspnam in -lsecurity... $ECHO_C" >&6
10949 if test "${ac_cv_lib_security_getspnam+set}" = set; then
10950   echo $ECHO_N "(cached) $ECHO_C" >&6
10951 else
10952   ac_check_lib_save_LIBS=$LIBS
10953 LIBS="-lsecurity  $LIBS"
10954 cat >conftest.$ac_ext <<_ACEOF
10955 #line 10955 "configure"
10956 #include "confdefs.h"
10957
10958 /* Override any gcc2 internal prototype to avoid an error.  */
10959 #ifdef __cplusplus
10960 extern "C"
10961 #endif
10962 /* We use char because int might match the return type of a gcc2
10963    builtin and then its argument prototype would still apply.  */
10964 char getspnam ();
10965 int
10966 main ()
10967 {
10968 getspnam ();
10969   ;
10970   return 0;
10971 }
10972 _ACEOF
10973 rm -f conftest.$ac_objext conftest$ac_exeext
10974 if { (eval echo "$as_me:10974: \"$ac_link\"") >&5
10975   (eval $ac_link) 2>&5
10976   ac_status=$?
10977   echo "$as_me:10977: \$? = $ac_status" >&5
10978   (exit $ac_status); } &&
10979          { ac_try='test -s conftest$ac_exeext'
10980   { (eval echo "$as_me:10980: \"$ac_try\"") >&5
10981   (eval $ac_try) 2>&5
10982   ac_status=$?
10983   echo "$as_me:10983: \$? = $ac_status" >&5
10984   (exit $ac_status); }; }; then
10985   ac_cv_lib_security_getspnam=yes
10986 else
10987   echo "$as_me: failed program was:" >&5
10988 cat conftest.$ac_ext >&5
10989 ac_cv_lib_security_getspnam=no
10990 fi
10991 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10992 LIBS=$ac_check_lib_save_LIBS
10993 fi
10994 echo "$as_me:10994: result: $ac_cv_lib_security_getspnam" >&5
10995 echo "${ECHO_T}$ac_cv_lib_security_getspnam" >&6
10996 if test $ac_cv_lib_security_getspnam = yes; then
10997   cat >>confdefs.h <<EOF
10998 #define HAVE_LIBSECURITY 1
10999 EOF
11000
11001   LIBS="-lsecurity $LIBS"
11002
11003 fi
11004
11005 for ac_func in getspnam
11006 do
11007 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11008 echo "$as_me:11008: checking for $ac_func" >&5
11009 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11010 if eval "test \"\${$as_ac_var+set}\" = set"; then
11011   echo $ECHO_N "(cached) $ECHO_C" >&6
11012 else
11013   cat >conftest.$ac_ext <<_ACEOF
11014 #line 11014 "configure"
11015 #include "confdefs.h"
11016 /* System header to define __stub macros and hopefully few prototypes,
11017     which can conflict with char $ac_func (); below.  */
11018 #include <assert.h>
11019 /* Override any gcc2 internal prototype to avoid an error.  */
11020 #ifdef __cplusplus
11021 extern "C"
11022 #endif
11023 /* We use char because int might match the return type of a gcc2
11024    builtin and then its argument prototype would still apply.  */
11025 char $ac_func ();
11026 char (*f) ();
11027
11028 int
11029 main ()
11030 {
11031 /* The GNU C library defines this for functions which it implements
11032     to always fail with ENOSYS.  Some functions are actually named
11033     something starting with __ and the normal name is an alias.  */
11034 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11035 choke me
11036 #else
11037 f = $ac_func;
11038 #endif
11039
11040   ;
11041   return 0;
11042 }
11043 _ACEOF
11044 rm -f conftest.$ac_objext conftest$ac_exeext
11045 if { (eval echo "$as_me:11045: \"$ac_link\"") >&5
11046   (eval $ac_link) 2>&5
11047   ac_status=$?
11048   echo "$as_me:11048: \$? = $ac_status" >&5
11049   (exit $ac_status); } &&
11050          { ac_try='test -s conftest$ac_exeext'
11051   { (eval echo "$as_me:11051: \"$ac_try\"") >&5
11052   (eval $ac_try) 2>&5
11053   ac_status=$?
11054   echo "$as_me:11054: \$? = $ac_status" >&5
11055   (exit $ac_status); }; }; then
11056   eval "$as_ac_var=yes"
11057 else
11058   echo "$as_me: failed program was:" >&5
11059 cat conftest.$ac_ext >&5
11060 eval "$as_ac_var=no"
11061 fi
11062 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11063 fi
11064 echo "$as_me:11064: result: `eval echo '${'$as_ac_var'}'`" >&5
11065 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11066 if test `eval echo '${'$as_ac_var'}'` = yes; then
11067   cat >>confdefs.h <<EOF
11068 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11069 EOF
11070
11071 fi
11072 done
11073
11074   ;;
11075   esac
11076
11077 case "$LIBS" in
11078   *-lsec*)
11079 for ac_func in getspnam
11080 do
11081 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11082 echo "$as_me:11082: checking for $ac_func" >&5
11083 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11084 if eval "test \"\${$as_ac_var+set}\" = set"; then
11085   echo $ECHO_N "(cached) $ECHO_C" >&6
11086 else
11087   cat >conftest.$ac_ext <<_ACEOF
11088 #line 11088 "configure"
11089 #include "confdefs.h"
11090 /* System header to define __stub macros and hopefully few prototypes,
11091     which can conflict with char $ac_func (); below.  */
11092 #include <assert.h>
11093 /* Override any gcc2 internal prototype to avoid an error.  */
11094 #ifdef __cplusplus
11095 extern "C"
11096 #endif
11097 /* We use char because int might match the return type of a gcc2
11098    builtin and then its argument prototype would still apply.  */
11099 char $ac_func ();
11100 char (*f) ();
11101
11102 int
11103 main ()
11104 {
11105 /* The GNU C library defines this for functions which it implements
11106     to always fail with ENOSYS.  Some functions are actually named
11107     something starting with __ and the normal name is an alias.  */
11108 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11109 choke me
11110 #else
11111 f = $ac_func;
11112 #endif
11113
11114   ;
11115   return 0;
11116 }
11117 _ACEOF
11118 rm -f conftest.$ac_objext conftest$ac_exeext
11119 if { (eval echo "$as_me:11119: \"$ac_link\"") >&5
11120   (eval $ac_link) 2>&5
11121   ac_status=$?
11122   echo "$as_me:11122: \$? = $ac_status" >&5
11123   (exit $ac_status); } &&
11124          { ac_try='test -s conftest$ac_exeext'
11125   { (eval echo "$as_me:11125: \"$ac_try\"") >&5
11126   (eval $ac_try) 2>&5
11127   ac_status=$?
11128   echo "$as_me:11128: \$? = $ac_status" >&5
11129   (exit $ac_status); }; }; then
11130   eval "$as_ac_var=yes"
11131 else
11132   echo "$as_me: failed program was:" >&5
11133 cat conftest.$ac_ext >&5
11134 eval "$as_ac_var=no"
11135 fi
11136 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11137 fi
11138 echo "$as_me:11138: result: `eval echo '${'$as_ac_var'}'`" >&5
11139 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11140 if test `eval echo '${'$as_ac_var'}'` = yes; then
11141   cat >>confdefs.h <<EOF
11142 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11143 EOF
11144
11145 fi
11146 done
11147  ;;
11148   *)
11149 echo "$as_me:11149: checking for getspnam in -lsec" >&5
11150 echo $ECHO_N "checking for getspnam in -lsec... $ECHO_C" >&6
11151 if test "${ac_cv_lib_sec_getspnam+set}" = set; then
11152   echo $ECHO_N "(cached) $ECHO_C" >&6
11153 else
11154   ac_check_lib_save_LIBS=$LIBS
11155 LIBS="-lsec  $LIBS"
11156 cat >conftest.$ac_ext <<_ACEOF
11157 #line 11157 "configure"
11158 #include "confdefs.h"
11159
11160 /* Override any gcc2 internal prototype to avoid an error.  */
11161 #ifdef __cplusplus
11162 extern "C"
11163 #endif
11164 /* We use char because int might match the return type of a gcc2
11165    builtin and then its argument prototype would still apply.  */
11166 char getspnam ();
11167 int
11168 main ()
11169 {
11170 getspnam ();
11171   ;
11172   return 0;
11173 }
11174 _ACEOF
11175 rm -f conftest.$ac_objext conftest$ac_exeext
11176 if { (eval echo "$as_me:11176: \"$ac_link\"") >&5
11177   (eval $ac_link) 2>&5
11178   ac_status=$?
11179   echo "$as_me:11179: \$? = $ac_status" >&5
11180   (exit $ac_status); } &&
11181          { ac_try='test -s conftest$ac_exeext'
11182   { (eval echo "$as_me:11182: \"$ac_try\"") >&5
11183   (eval $ac_try) 2>&5
11184   ac_status=$?
11185   echo "$as_me:11185: \$? = $ac_status" >&5
11186   (exit $ac_status); }; }; then
11187   ac_cv_lib_sec_getspnam=yes
11188 else
11189   echo "$as_me: failed program was:" >&5
11190 cat conftest.$ac_ext >&5
11191 ac_cv_lib_sec_getspnam=no
11192 fi
11193 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11194 LIBS=$ac_check_lib_save_LIBS
11195 fi
11196 echo "$as_me:11196: result: $ac_cv_lib_sec_getspnam" >&5
11197 echo "${ECHO_T}$ac_cv_lib_sec_getspnam" >&6
11198 if test $ac_cv_lib_sec_getspnam = yes; then
11199   cat >>confdefs.h <<EOF
11200 #define HAVE_LIBSEC 1
11201 EOF
11202
11203   LIBS="-lsec $LIBS"
11204
11205 fi
11206
11207 for ac_func in getspnam
11208 do
11209 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11210 echo "$as_me:11210: checking for $ac_func" >&5
11211 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11212 if eval "test \"\${$as_ac_var+set}\" = set"; then
11213   echo $ECHO_N "(cached) $ECHO_C" >&6
11214 else
11215   cat >conftest.$ac_ext <<_ACEOF
11216 #line 11216 "configure"
11217 #include "confdefs.h"
11218 /* System header to define __stub macros and hopefully few prototypes,
11219     which can conflict with char $ac_func (); below.  */
11220 #include <assert.h>
11221 /* Override any gcc2 internal prototype to avoid an error.  */
11222 #ifdef __cplusplus
11223 extern "C"
11224 #endif
11225 /* We use char because int might match the return type of a gcc2
11226    builtin and then its argument prototype would still apply.  */
11227 char $ac_func ();
11228 char (*f) ();
11229
11230 int
11231 main ()
11232 {
11233 /* The GNU C library defines this for functions which it implements
11234     to always fail with ENOSYS.  Some functions are actually named
11235     something starting with __ and the normal name is an alias.  */
11236 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11237 choke me
11238 #else
11239 f = $ac_func;
11240 #endif
11241
11242   ;
11243   return 0;
11244 }
11245 _ACEOF
11246 rm -f conftest.$ac_objext conftest$ac_exeext
11247 if { (eval echo "$as_me:11247: \"$ac_link\"") >&5
11248   (eval $ac_link) 2>&5
11249   ac_status=$?
11250   echo "$as_me:11250: \$? = $ac_status" >&5
11251   (exit $ac_status); } &&
11252          { ac_try='test -s conftest$ac_exeext'
11253   { (eval echo "$as_me:11253: \"$ac_try\"") >&5
11254   (eval $ac_try) 2>&5
11255   ac_status=$?
11256   echo "$as_me:11256: \$? = $ac_status" >&5
11257   (exit $ac_status); }; }; then
11258   eval "$as_ac_var=yes"
11259 else
11260   echo "$as_me: failed program was:" >&5
11261 cat conftest.$ac_ext >&5
11262 eval "$as_ac_var=no"
11263 fi
11264 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11265 fi
11266 echo "$as_me:11266: result: `eval echo '${'$as_ac_var'}'`" >&5
11267 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11268 if test `eval echo '${'$as_ac_var'}'` = yes; then
11269   cat >>confdefs.h <<EOF
11270 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11271 EOF
11272
11273 fi
11274 done
11275
11276   ;;
11277   esac
11278
11279 case "$LIBS" in
11280   *-lsecurity*)
11281 for ac_func in bigcrypt
11282 do
11283 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11284 echo "$as_me:11284: checking for $ac_func" >&5
11285 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11286 if eval "test \"\${$as_ac_var+set}\" = set"; then
11287   echo $ECHO_N "(cached) $ECHO_C" >&6
11288 else
11289   cat >conftest.$ac_ext <<_ACEOF
11290 #line 11290 "configure"
11291 #include "confdefs.h"
11292 /* System header to define __stub macros and hopefully few prototypes,
11293     which can conflict with char $ac_func (); below.  */
11294 #include <assert.h>
11295 /* Override any gcc2 internal prototype to avoid an error.  */
11296 #ifdef __cplusplus
11297 extern "C"
11298 #endif
11299 /* We use char because int might match the return type of a gcc2
11300    builtin and then its argument prototype would still apply.  */
11301 char $ac_func ();
11302 char (*f) ();
11303
11304 int
11305 main ()
11306 {
11307 /* The GNU C library defines this for functions which it implements
11308     to always fail with ENOSYS.  Some functions are actually named
11309     something starting with __ and the normal name is an alias.  */
11310 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11311 choke me
11312 #else
11313 f = $ac_func;
11314 #endif
11315
11316   ;
11317   return 0;
11318 }
11319 _ACEOF
11320 rm -f conftest.$ac_objext conftest$ac_exeext
11321 if { (eval echo "$as_me:11321: \"$ac_link\"") >&5
11322   (eval $ac_link) 2>&5
11323   ac_status=$?
11324   echo "$as_me:11324: \$? = $ac_status" >&5
11325   (exit $ac_status); } &&
11326          { ac_try='test -s conftest$ac_exeext'
11327   { (eval echo "$as_me:11327: \"$ac_try\"") >&5
11328   (eval $ac_try) 2>&5
11329   ac_status=$?
11330   echo "$as_me:11330: \$? = $ac_status" >&5
11331   (exit $ac_status); }; }; then
11332   eval "$as_ac_var=yes"
11333 else
11334   echo "$as_me: failed program was:" >&5
11335 cat conftest.$ac_ext >&5
11336 eval "$as_ac_var=no"
11337 fi
11338 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11339 fi
11340 echo "$as_me:11340: result: `eval echo '${'$as_ac_var'}'`" >&5
11341 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11342 if test `eval echo '${'$as_ac_var'}'` = yes; then
11343   cat >>confdefs.h <<EOF
11344 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11345 EOF
11346
11347 fi
11348 done
11349  ;;
11350   *)
11351 echo "$as_me:11351: checking for bigcrypt in -lsecurity" >&5
11352 echo $ECHO_N "checking for bigcrypt in -lsecurity... $ECHO_C" >&6
11353 if test "${ac_cv_lib_security_bigcrypt+set}" = set; then
11354   echo $ECHO_N "(cached) $ECHO_C" >&6
11355 else
11356   ac_check_lib_save_LIBS=$LIBS
11357 LIBS="-lsecurity  $LIBS"
11358 cat >conftest.$ac_ext <<_ACEOF
11359 #line 11359 "configure"
11360 #include "confdefs.h"
11361
11362 /* Override any gcc2 internal prototype to avoid an error.  */
11363 #ifdef __cplusplus
11364 extern "C"
11365 #endif
11366 /* We use char because int might match the return type of a gcc2
11367    builtin and then its argument prototype would still apply.  */
11368 char bigcrypt ();
11369 int
11370 main ()
11371 {
11372 bigcrypt ();
11373   ;
11374   return 0;
11375 }
11376 _ACEOF
11377 rm -f conftest.$ac_objext conftest$ac_exeext
11378 if { (eval echo "$as_me:11378: \"$ac_link\"") >&5
11379   (eval $ac_link) 2>&5
11380   ac_status=$?
11381   echo "$as_me:11381: \$? = $ac_status" >&5
11382   (exit $ac_status); } &&
11383          { ac_try='test -s conftest$ac_exeext'
11384   { (eval echo "$as_me:11384: \"$ac_try\"") >&5
11385   (eval $ac_try) 2>&5
11386   ac_status=$?
11387   echo "$as_me:11387: \$? = $ac_status" >&5
11388   (exit $ac_status); }; }; then
11389   ac_cv_lib_security_bigcrypt=yes
11390 else
11391   echo "$as_me: failed program was:" >&5
11392 cat conftest.$ac_ext >&5
11393 ac_cv_lib_security_bigcrypt=no
11394 fi
11395 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11396 LIBS=$ac_check_lib_save_LIBS
11397 fi
11398 echo "$as_me:11398: result: $ac_cv_lib_security_bigcrypt" >&5
11399 echo "${ECHO_T}$ac_cv_lib_security_bigcrypt" >&6
11400 if test $ac_cv_lib_security_bigcrypt = yes; then
11401   cat >>confdefs.h <<EOF
11402 #define HAVE_LIBSECURITY 1
11403 EOF
11404
11405   LIBS="-lsecurity $LIBS"
11406
11407 fi
11408
11409 for ac_func in bigcrypt
11410 do
11411 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11412 echo "$as_me:11412: checking for $ac_func" >&5
11413 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11414 if eval "test \"\${$as_ac_var+set}\" = set"; then
11415   echo $ECHO_N "(cached) $ECHO_C" >&6
11416 else
11417   cat >conftest.$ac_ext <<_ACEOF
11418 #line 11418 "configure"
11419 #include "confdefs.h"
11420 /* System header to define __stub macros and hopefully few prototypes,
11421     which can conflict with char $ac_func (); below.  */
11422 #include <assert.h>
11423 /* Override any gcc2 internal prototype to avoid an error.  */
11424 #ifdef __cplusplus
11425 extern "C"
11426 #endif
11427 /* We use char because int might match the return type of a gcc2
11428    builtin and then its argument prototype would still apply.  */
11429 char $ac_func ();
11430 char (*f) ();
11431
11432 int
11433 main ()
11434 {
11435 /* The GNU C library defines this for functions which it implements
11436     to always fail with ENOSYS.  Some functions are actually named
11437     something starting with __ and the normal name is an alias.  */
11438 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11439 choke me
11440 #else
11441 f = $ac_func;
11442 #endif
11443
11444   ;
11445   return 0;
11446 }
11447 _ACEOF
11448 rm -f conftest.$ac_objext conftest$ac_exeext
11449 if { (eval echo "$as_me:11449: \"$ac_link\"") >&5
11450   (eval $ac_link) 2>&5
11451   ac_status=$?
11452   echo "$as_me:11452: \$? = $ac_status" >&5
11453   (exit $ac_status); } &&
11454          { ac_try='test -s conftest$ac_exeext'
11455   { (eval echo "$as_me:11455: \"$ac_try\"") >&5
11456   (eval $ac_try) 2>&5
11457   ac_status=$?
11458   echo "$as_me:11458: \$? = $ac_status" >&5
11459   (exit $ac_status); }; }; then
11460   eval "$as_ac_var=yes"
11461 else
11462   echo "$as_me: failed program was:" >&5
11463 cat conftest.$ac_ext >&5
11464 eval "$as_ac_var=no"
11465 fi
11466 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11467 fi
11468 echo "$as_me:11468: result: `eval echo '${'$as_ac_var'}'`" >&5
11469 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11470 if test `eval echo '${'$as_ac_var'}'` = yes; then
11471   cat >>confdefs.h <<EOF
11472 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11473 EOF
11474
11475 fi
11476 done
11477
11478   ;;
11479   esac
11480
11481 case "$LIBS" in
11482   *-lsec*)
11483 for ac_func in bigcrypt
11484 do
11485 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11486 echo "$as_me:11486: checking for $ac_func" >&5
11487 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11488 if eval "test \"\${$as_ac_var+set}\" = set"; then
11489   echo $ECHO_N "(cached) $ECHO_C" >&6
11490 else
11491   cat >conftest.$ac_ext <<_ACEOF
11492 #line 11492 "configure"
11493 #include "confdefs.h"
11494 /* System header to define __stub macros and hopefully few prototypes,
11495     which can conflict with char $ac_func (); below.  */
11496 #include <assert.h>
11497 /* Override any gcc2 internal prototype to avoid an error.  */
11498 #ifdef __cplusplus
11499 extern "C"
11500 #endif
11501 /* We use char because int might match the return type of a gcc2
11502    builtin and then its argument prototype would still apply.  */
11503 char $ac_func ();
11504 char (*f) ();
11505
11506 int
11507 main ()
11508 {
11509 /* The GNU C library defines this for functions which it implements
11510     to always fail with ENOSYS.  Some functions are actually named
11511     something starting with __ and the normal name is an alias.  */
11512 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11513 choke me
11514 #else
11515 f = $ac_func;
11516 #endif
11517
11518   ;
11519   return 0;
11520 }
11521 _ACEOF
11522 rm -f conftest.$ac_objext conftest$ac_exeext
11523 if { (eval echo "$as_me:11523: \"$ac_link\"") >&5
11524   (eval $ac_link) 2>&5
11525   ac_status=$?
11526   echo "$as_me:11526: \$? = $ac_status" >&5
11527   (exit $ac_status); } &&
11528          { ac_try='test -s conftest$ac_exeext'
11529   { (eval echo "$as_me:11529: \"$ac_try\"") >&5
11530   (eval $ac_try) 2>&5
11531   ac_status=$?
11532   echo "$as_me:11532: \$? = $ac_status" >&5
11533   (exit $ac_status); }; }; then
11534   eval "$as_ac_var=yes"
11535 else
11536   echo "$as_me: failed program was:" >&5
11537 cat conftest.$ac_ext >&5
11538 eval "$as_ac_var=no"
11539 fi
11540 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11541 fi
11542 echo "$as_me:11542: result: `eval echo '${'$as_ac_var'}'`" >&5
11543 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11544 if test `eval echo '${'$as_ac_var'}'` = yes; then
11545   cat >>confdefs.h <<EOF
11546 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11547 EOF
11548
11549 fi
11550 done
11551  ;;
11552   *)
11553 echo "$as_me:11553: checking for bigcrypt in -lsec" >&5
11554 echo $ECHO_N "checking for bigcrypt in -lsec... $ECHO_C" >&6
11555 if test "${ac_cv_lib_sec_bigcrypt+set}" = set; then
11556   echo $ECHO_N "(cached) $ECHO_C" >&6
11557 else
11558   ac_check_lib_save_LIBS=$LIBS
11559 LIBS="-lsec  $LIBS"
11560 cat >conftest.$ac_ext <<_ACEOF
11561 #line 11561 "configure"
11562 #include "confdefs.h"
11563
11564 /* Override any gcc2 internal prototype to avoid an error.  */
11565 #ifdef __cplusplus
11566 extern "C"
11567 #endif
11568 /* We use char because int might match the return type of a gcc2
11569    builtin and then its argument prototype would still apply.  */
11570 char bigcrypt ();
11571 int
11572 main ()
11573 {
11574 bigcrypt ();
11575   ;
11576   return 0;
11577 }
11578 _ACEOF
11579 rm -f conftest.$ac_objext conftest$ac_exeext
11580 if { (eval echo "$as_me:11580: \"$ac_link\"") >&5
11581   (eval $ac_link) 2>&5
11582   ac_status=$?
11583   echo "$as_me:11583: \$? = $ac_status" >&5
11584   (exit $ac_status); } &&
11585          { ac_try='test -s conftest$ac_exeext'
11586   { (eval echo "$as_me:11586: \"$ac_try\"") >&5
11587   (eval $ac_try) 2>&5
11588   ac_status=$?
11589   echo "$as_me:11589: \$? = $ac_status" >&5
11590   (exit $ac_status); }; }; then
11591   ac_cv_lib_sec_bigcrypt=yes
11592 else
11593   echo "$as_me: failed program was:" >&5
11594 cat conftest.$ac_ext >&5
11595 ac_cv_lib_sec_bigcrypt=no
11596 fi
11597 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11598 LIBS=$ac_check_lib_save_LIBS
11599 fi
11600 echo "$as_me:11600: result: $ac_cv_lib_sec_bigcrypt" >&5
11601 echo "${ECHO_T}$ac_cv_lib_sec_bigcrypt" >&6
11602 if test $ac_cv_lib_sec_bigcrypt = yes; then
11603   cat >>confdefs.h <<EOF
11604 #define HAVE_LIBSEC 1
11605 EOF
11606
11607   LIBS="-lsec $LIBS"
11608
11609 fi
11610
11611 for ac_func in bigcrypt
11612 do
11613 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11614 echo "$as_me:11614: checking for $ac_func" >&5
11615 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11616 if eval "test \"\${$as_ac_var+set}\" = set"; then
11617   echo $ECHO_N "(cached) $ECHO_C" >&6
11618 else
11619   cat >conftest.$ac_ext <<_ACEOF
11620 #line 11620 "configure"
11621 #include "confdefs.h"
11622 /* System header to define __stub macros and hopefully few prototypes,
11623     which can conflict with char $ac_func (); below.  */
11624 #include <assert.h>
11625 /* Override any gcc2 internal prototype to avoid an error.  */
11626 #ifdef __cplusplus
11627 extern "C"
11628 #endif
11629 /* We use char because int might match the return type of a gcc2
11630    builtin and then its argument prototype would still apply.  */
11631 char $ac_func ();
11632 char (*f) ();
11633
11634 int
11635 main ()
11636 {
11637 /* The GNU C library defines this for functions which it implements
11638     to always fail with ENOSYS.  Some functions are actually named
11639     something starting with __ and the normal name is an alias.  */
11640 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11641 choke me
11642 #else
11643 f = $ac_func;
11644 #endif
11645
11646   ;
11647   return 0;
11648 }
11649 _ACEOF
11650 rm -f conftest.$ac_objext conftest$ac_exeext
11651 if { (eval echo "$as_me:11651: \"$ac_link\"") >&5
11652   (eval $ac_link) 2>&5
11653   ac_status=$?
11654   echo "$as_me:11654: \$? = $ac_status" >&5
11655   (exit $ac_status); } &&
11656          { ac_try='test -s conftest$ac_exeext'
11657   { (eval echo "$as_me:11657: \"$ac_try\"") >&5
11658   (eval $ac_try) 2>&5
11659   ac_status=$?
11660   echo "$as_me:11660: \$? = $ac_status" >&5
11661   (exit $ac_status); }; }; then
11662   eval "$as_ac_var=yes"
11663 else
11664   echo "$as_me: failed program was:" >&5
11665 cat conftest.$ac_ext >&5
11666 eval "$as_ac_var=no"
11667 fi
11668 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11669 fi
11670 echo "$as_me:11670: result: `eval echo '${'$as_ac_var'}'`" >&5
11671 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11672 if test `eval echo '${'$as_ac_var'}'` = yes; then
11673   cat >>confdefs.h <<EOF
11674 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11675 EOF
11676
11677 fi
11678 done
11679
11680   ;;
11681   esac
11682
11683 case "$LIBS" in
11684   *-lsecurity*)
11685 for ac_func in getprpwnam
11686 do
11687 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11688 echo "$as_me:11688: checking for $ac_func" >&5
11689 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11690 if eval "test \"\${$as_ac_var+set}\" = set"; then
11691   echo $ECHO_N "(cached) $ECHO_C" >&6
11692 else
11693   cat >conftest.$ac_ext <<_ACEOF
11694 #line 11694 "configure"
11695 #include "confdefs.h"
11696 /* System header to define __stub macros and hopefully few prototypes,
11697     which can conflict with char $ac_func (); below.  */
11698 #include <assert.h>
11699 /* Override any gcc2 internal prototype to avoid an error.  */
11700 #ifdef __cplusplus
11701 extern "C"
11702 #endif
11703 /* We use char because int might match the return type of a gcc2
11704    builtin and then its argument prototype would still apply.  */
11705 char $ac_func ();
11706 char (*f) ();
11707
11708 int
11709 main ()
11710 {
11711 /* The GNU C library defines this for functions which it implements
11712     to always fail with ENOSYS.  Some functions are actually named
11713     something starting with __ and the normal name is an alias.  */
11714 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11715 choke me
11716 #else
11717 f = $ac_func;
11718 #endif
11719
11720   ;
11721   return 0;
11722 }
11723 _ACEOF
11724 rm -f conftest.$ac_objext conftest$ac_exeext
11725 if { (eval echo "$as_me:11725: \"$ac_link\"") >&5
11726   (eval $ac_link) 2>&5
11727   ac_status=$?
11728   echo "$as_me:11728: \$? = $ac_status" >&5
11729   (exit $ac_status); } &&
11730          { ac_try='test -s conftest$ac_exeext'
11731   { (eval echo "$as_me:11731: \"$ac_try\"") >&5
11732   (eval $ac_try) 2>&5
11733   ac_status=$?
11734   echo "$as_me:11734: \$? = $ac_status" >&5
11735   (exit $ac_status); }; }; then
11736   eval "$as_ac_var=yes"
11737 else
11738   echo "$as_me: failed program was:" >&5
11739 cat conftest.$ac_ext >&5
11740 eval "$as_ac_var=no"
11741 fi
11742 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11743 fi
11744 echo "$as_me:11744: result: `eval echo '${'$as_ac_var'}'`" >&5
11745 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11746 if test `eval echo '${'$as_ac_var'}'` = yes; then
11747   cat >>confdefs.h <<EOF
11748 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11749 EOF
11750
11751 fi
11752 done
11753  ;;
11754   *)
11755 echo "$as_me:11755: checking for getprpwnam in -lsecurity" >&5
11756 echo $ECHO_N "checking for getprpwnam in -lsecurity... $ECHO_C" >&6
11757 if test "${ac_cv_lib_security_getprpwnam+set}" = set; then
11758   echo $ECHO_N "(cached) $ECHO_C" >&6
11759 else
11760   ac_check_lib_save_LIBS=$LIBS
11761 LIBS="-lsecurity  $LIBS"
11762 cat >conftest.$ac_ext <<_ACEOF
11763 #line 11763 "configure"
11764 #include "confdefs.h"
11765
11766 /* Override any gcc2 internal prototype to avoid an error.  */
11767 #ifdef __cplusplus
11768 extern "C"
11769 #endif
11770 /* We use char because int might match the return type of a gcc2
11771    builtin and then its argument prototype would still apply.  */
11772 char getprpwnam ();
11773 int
11774 main ()
11775 {
11776 getprpwnam ();
11777   ;
11778   return 0;
11779 }
11780 _ACEOF
11781 rm -f conftest.$ac_objext conftest$ac_exeext
11782 if { (eval echo "$as_me:11782: \"$ac_link\"") >&5
11783   (eval $ac_link) 2>&5
11784   ac_status=$?
11785   echo "$as_me:11785: \$? = $ac_status" >&5
11786   (exit $ac_status); } &&
11787          { ac_try='test -s conftest$ac_exeext'
11788   { (eval echo "$as_me:11788: \"$ac_try\"") >&5
11789   (eval $ac_try) 2>&5
11790   ac_status=$?
11791   echo "$as_me:11791: \$? = $ac_status" >&5
11792   (exit $ac_status); }; }; then
11793   ac_cv_lib_security_getprpwnam=yes
11794 else
11795   echo "$as_me: failed program was:" >&5
11796 cat conftest.$ac_ext >&5
11797 ac_cv_lib_security_getprpwnam=no
11798 fi
11799 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11800 LIBS=$ac_check_lib_save_LIBS
11801 fi
11802 echo "$as_me:11802: result: $ac_cv_lib_security_getprpwnam" >&5
11803 echo "${ECHO_T}$ac_cv_lib_security_getprpwnam" >&6
11804 if test $ac_cv_lib_security_getprpwnam = yes; then
11805   cat >>confdefs.h <<EOF
11806 #define HAVE_LIBSECURITY 1
11807 EOF
11808
11809   LIBS="-lsecurity $LIBS"
11810
11811 fi
11812
11813 for ac_func in getprpwnam
11814 do
11815 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11816 echo "$as_me:11816: checking for $ac_func" >&5
11817 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11818 if eval "test \"\${$as_ac_var+set}\" = set"; then
11819   echo $ECHO_N "(cached) $ECHO_C" >&6
11820 else
11821   cat >conftest.$ac_ext <<_ACEOF
11822 #line 11822 "configure"
11823 #include "confdefs.h"
11824 /* System header to define __stub macros and hopefully few prototypes,
11825     which can conflict with char $ac_func (); below.  */
11826 #include <assert.h>
11827 /* Override any gcc2 internal prototype to avoid an error.  */
11828 #ifdef __cplusplus
11829 extern "C"
11830 #endif
11831 /* We use char because int might match the return type of a gcc2
11832    builtin and then its argument prototype would still apply.  */
11833 char $ac_func ();
11834 char (*f) ();
11835
11836 int
11837 main ()
11838 {
11839 /* The GNU C library defines this for functions which it implements
11840     to always fail with ENOSYS.  Some functions are actually named
11841     something starting with __ and the normal name is an alias.  */
11842 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11843 choke me
11844 #else
11845 f = $ac_func;
11846 #endif
11847
11848   ;
11849   return 0;
11850 }
11851 _ACEOF
11852 rm -f conftest.$ac_objext conftest$ac_exeext
11853 if { (eval echo "$as_me:11853: \"$ac_link\"") >&5
11854   (eval $ac_link) 2>&5
11855   ac_status=$?
11856   echo "$as_me:11856: \$? = $ac_status" >&5
11857   (exit $ac_status); } &&
11858          { ac_try='test -s conftest$ac_exeext'
11859   { (eval echo "$as_me:11859: \"$ac_try\"") >&5
11860   (eval $ac_try) 2>&5
11861   ac_status=$?
11862   echo "$as_me:11862: \$? = $ac_status" >&5
11863   (exit $ac_status); }; }; then
11864   eval "$as_ac_var=yes"
11865 else
11866   echo "$as_me: failed program was:" >&5
11867 cat conftest.$ac_ext >&5
11868 eval "$as_ac_var=no"
11869 fi
11870 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11871 fi
11872 echo "$as_me:11872: result: `eval echo '${'$as_ac_var'}'`" >&5
11873 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11874 if test `eval echo '${'$as_ac_var'}'` = yes; then
11875   cat >>confdefs.h <<EOF
11876 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11877 EOF
11878
11879 fi
11880 done
11881
11882   ;;
11883   esac
11884
11885 case "$LIBS" in
11886   *-lsec*)
11887 for ac_func in getprpwnam
11888 do
11889 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11890 echo "$as_me:11890: checking for $ac_func" >&5
11891 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11892 if eval "test \"\${$as_ac_var+set}\" = set"; then
11893   echo $ECHO_N "(cached) $ECHO_C" >&6
11894 else
11895   cat >conftest.$ac_ext <<_ACEOF
11896 #line 11896 "configure"
11897 #include "confdefs.h"
11898 /* System header to define __stub macros and hopefully few prototypes,
11899     which can conflict with char $ac_func (); below.  */
11900 #include <assert.h>
11901 /* Override any gcc2 internal prototype to avoid an error.  */
11902 #ifdef __cplusplus
11903 extern "C"
11904 #endif
11905 /* We use char because int might match the return type of a gcc2
11906    builtin and then its argument prototype would still apply.  */
11907 char $ac_func ();
11908 char (*f) ();
11909
11910 int
11911 main ()
11912 {
11913 /* The GNU C library defines this for functions which it implements
11914     to always fail with ENOSYS.  Some functions are actually named
11915     something starting with __ and the normal name is an alias.  */
11916 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11917 choke me
11918 #else
11919 f = $ac_func;
11920 #endif
11921
11922   ;
11923   return 0;
11924 }
11925 _ACEOF
11926 rm -f conftest.$ac_objext conftest$ac_exeext
11927 if { (eval echo "$as_me:11927: \"$ac_link\"") >&5
11928   (eval $ac_link) 2>&5
11929   ac_status=$?
11930   echo "$as_me:11930: \$? = $ac_status" >&5
11931   (exit $ac_status); } &&
11932          { ac_try='test -s conftest$ac_exeext'
11933   { (eval echo "$as_me:11933: \"$ac_try\"") >&5
11934   (eval $ac_try) 2>&5
11935   ac_status=$?
11936   echo "$as_me:11936: \$? = $ac_status" >&5
11937   (exit $ac_status); }; }; then
11938   eval "$as_ac_var=yes"
11939 else
11940   echo "$as_me: failed program was:" >&5
11941 cat conftest.$ac_ext >&5
11942 eval "$as_ac_var=no"
11943 fi
11944 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11945 fi
11946 echo "$as_me:11946: result: `eval echo '${'$as_ac_var'}'`" >&5
11947 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11948 if test `eval echo '${'$as_ac_var'}'` = yes; then
11949   cat >>confdefs.h <<EOF
11950 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11951 EOF
11952
11953 fi
11954 done
11955  ;;
11956   *)
11957 echo "$as_me:11957: checking for getprpwnam in -lsec" >&5
11958 echo $ECHO_N "checking for getprpwnam in -lsec... $ECHO_C" >&6
11959 if test "${ac_cv_lib_sec_getprpwnam+set}" = set; then
11960   echo $ECHO_N "(cached) $ECHO_C" >&6
11961 else
11962   ac_check_lib_save_LIBS=$LIBS
11963 LIBS="-lsec  $LIBS"
11964 cat >conftest.$ac_ext <<_ACEOF
11965 #line 11965 "configure"
11966 #include "confdefs.h"
11967
11968 /* Override any gcc2 internal prototype to avoid an error.  */
11969 #ifdef __cplusplus
11970 extern "C"
11971 #endif
11972 /* We use char because int might match the return type of a gcc2
11973    builtin and then its argument prototype would still apply.  */
11974 char getprpwnam ();
11975 int
11976 main ()
11977 {
11978 getprpwnam ();
11979   ;
11980   return 0;
11981 }
11982 _ACEOF
11983 rm -f conftest.$ac_objext conftest$ac_exeext
11984 if { (eval echo "$as_me:11984: \"$ac_link\"") >&5
11985   (eval $ac_link) 2>&5
11986   ac_status=$?
11987   echo "$as_me:11987: \$? = $ac_status" >&5
11988   (exit $ac_status); } &&
11989          { ac_try='test -s conftest$ac_exeext'
11990   { (eval echo "$as_me:11990: \"$ac_try\"") >&5
11991   (eval $ac_try) 2>&5
11992   ac_status=$?
11993   echo "$as_me:11993: \$? = $ac_status" >&5
11994   (exit $ac_status); }; }; then
11995   ac_cv_lib_sec_getprpwnam=yes
11996 else
11997   echo "$as_me: failed program was:" >&5
11998 cat conftest.$ac_ext >&5
11999 ac_cv_lib_sec_getprpwnam=no
12000 fi
12001 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12002 LIBS=$ac_check_lib_save_LIBS
12003 fi
12004 echo "$as_me:12004: result: $ac_cv_lib_sec_getprpwnam" >&5
12005 echo "${ECHO_T}$ac_cv_lib_sec_getprpwnam" >&6
12006 if test $ac_cv_lib_sec_getprpwnam = yes; then
12007   cat >>confdefs.h <<EOF
12008 #define HAVE_LIBSEC 1
12009 EOF
12010
12011   LIBS="-lsec $LIBS"
12012
12013 fi
12014
12015 for ac_func in getprpwnam
12016 do
12017 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12018 echo "$as_me:12018: checking for $ac_func" >&5
12019 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12020 if eval "test \"\${$as_ac_var+set}\" = set"; then
12021   echo $ECHO_N "(cached) $ECHO_C" >&6
12022 else
12023   cat >conftest.$ac_ext <<_ACEOF
12024 #line 12024 "configure"
12025 #include "confdefs.h"
12026 /* System header to define __stub macros and hopefully few prototypes,
12027     which can conflict with char $ac_func (); below.  */
12028 #include <assert.h>
12029 /* Override any gcc2 internal prototype to avoid an error.  */
12030 #ifdef __cplusplus
12031 extern "C"
12032 #endif
12033 /* We use char because int might match the return type of a gcc2
12034    builtin and then its argument prototype would still apply.  */
12035 char $ac_func ();
12036 char (*f) ();
12037
12038 int
12039 main ()
12040 {
12041 /* The GNU C library defines this for functions which it implements
12042     to always fail with ENOSYS.  Some functions are actually named
12043     something starting with __ and the normal name is an alias.  */
12044 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12045 choke me
12046 #else
12047 f = $ac_func;
12048 #endif
12049
12050   ;
12051   return 0;
12052 }
12053 _ACEOF
12054 rm -f conftest.$ac_objext conftest$ac_exeext
12055 if { (eval echo "$as_me:12055: \"$ac_link\"") >&5
12056   (eval $ac_link) 2>&5
12057   ac_status=$?
12058   echo "$as_me:12058: \$? = $ac_status" >&5
12059   (exit $ac_status); } &&
12060          { ac_try='test -s conftest$ac_exeext'
12061   { (eval echo "$as_me:12061: \"$ac_try\"") >&5
12062   (eval $ac_try) 2>&5
12063   ac_status=$?
12064   echo "$as_me:12064: \$? = $ac_status" >&5
12065   (exit $ac_status); }; }; then
12066   eval "$as_ac_var=yes"
12067 else
12068   echo "$as_me: failed program was:" >&5
12069 cat conftest.$ac_ext >&5
12070 eval "$as_ac_var=no"
12071 fi
12072 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12073 fi
12074 echo "$as_me:12074: result: `eval echo '${'$as_ac_var'}'`" >&5
12075 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12076 if test `eval echo '${'$as_ac_var'}'` = yes; then
12077   cat >>confdefs.h <<EOF
12078 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12079 EOF
12080
12081 fi
12082 done
12083
12084   ;;
12085   esac
12086
12087 # this bit needs to be modified for each OS that is suported by
12088 # smbwrapper. You need to specify how to created a shared library and
12089 # how to compile C code to produce PIC object files
12090
12091 # these are the defaults, good for lots of systems
12092 HOST_OS="$host_os"
12093 LDSHFLAGS="-shared"
12094 SHLD="\${CC}"
12095 PICFLAG=""
12096 PICSUFFIX="po"
12097 POBAD_CC="#"
12098 SHLIBEXT="so"
12099 # Assume non-shared by default and override below
12100 BLDSHARED="false"
12101 echo "$as_me:12101: checking ability to build shared libraries" >&5
12102 echo $ECHO_N "checking ability to build shared libraries... $ECHO_C" >&6
12103
12104 # and these are for particular systems
12105 case "$host_os" in
12106                 *linux*)   cat >>confdefs.h <<\EOF
12107 #define LINUX 1
12108 EOF
12109
12110                         BLDSHARED="true"
12111                         LDSHFLAGS="-shared"
12112                         PICFLAG="-fPIC"
12113                 ;;
12114                 *solaris*) cat >>confdefs.h <<\EOF
12115 #define SUNOS5 1
12116 EOF
12117
12118                         BLDSHARED="true"
12119                         LDSHFLAGS="-Wl,-h,\$@.so -G"
12120                         if test "${ac_cv_prog_CC}" = "gcc"; then
12121                                 PICFLAG="-fPIC"
12122                         else
12123                                 PICFLAG="-KPIC"
12124                                 POBAD_CC=""
12125                                 PICSUFFIX="po.o"
12126                         fi
12127                 ;;
12128                 *sunos*) cat >>confdefs.h <<\EOF
12129 #define SUNOS4 1
12130 EOF
12131
12132                         BLDSHARED="true"
12133                         LDSHFLAGS="-Wl,-h,\$@ -G"
12134                         PICFLAG="-KPIC"   # Is this correct for SunOS
12135                 ;;
12136                 *bsd*)  BLDSHARED="true"
12137                         LDSHFLAGS="-Wl,-soname,\$@ -shared"
12138                         PICFLAG="-fPIC"
12139                 ;;
12140                 *irix*) cat >>confdefs.h <<\EOF
12141 #define IRIX 1
12142 EOF
12143
12144                         case "$host_os" in
12145                         *irix6*) cat >>confdefs.h <<\EOF
12146 #define IRIX6 1
12147 EOF
12148
12149                         ;;
12150                         esac
12151                         ATTEMPT_WRAP32_BUILD=yes
12152                         BLDSHARED="true"
12153                         LDSHFLAGS="-Wl,-soname,\$@ -shared"
12154                         if test "${ac_cv_prog_CC}" = "gcc"; then
12155                                 PICFLAG="-fPIC"
12156                         else
12157                                 PICFLAG="-KPIC"
12158                         fi
12159                 ;;
12160                 *aix*) cat >>confdefs.h <<\EOF
12161 #define AIX 1
12162 EOF
12163
12164                         BLDSHARED="true"
12165                         LDSHFLAGS="-Wl,-bexpall,-bM:SRE,-bnoentry"
12166                         PICFLAG="-O2 -qmaxmem=6000"
12167                 ;;
12168                 *hpux*) cat >>confdefs.h <<\EOF
12169 #define HPUX 1
12170 EOF
12171
12172                         SHLIBEXT="sl"
12173                         # Use special PIC flags for the native HP-UX compiler.
12174                         if test $ac_cv_prog_cc_Ae = yes; then
12175                                 #BLDSHARED="true"
12176                                 LDSHFLAGS="-b -z +h \$@"
12177                                 PICFLAG="+z"
12178                         fi
12179                 ;;
12180                 *qnx*) cat >>confdefs.h <<\EOF
12181 #define QNX 1
12182 EOF
12183 ;;
12184                 *osf*) cat >>confdefs.h <<\EOF
12185 #define OSF1 1
12186 EOF
12187
12188                         BLDSHARED="true"
12189                         LDSHFLAGS="-Wl,-soname,\$@ -shared"
12190                         PICFLAG="-fPIC"
12191                 ;;
12192                 *sco*) cat >>confdefs.h <<\EOF
12193 #define SCO 1
12194 EOF
12195 ;;
12196                 *unixware*) cat >>confdefs.h <<\EOF
12197 #define UNIXWARE 1
12198 EOF
12199
12200                         BLDSHARED="true"
12201                         LDSHFLAGS="-Wl,-soname,\$@ -shared"
12202                         PICFLAG="-KPIC"
12203                 ;;
12204                 *next2*) cat >>confdefs.h <<\EOF
12205 #define NEXT2 1
12206 EOF
12207 ;;
12208                 *dgux*) # Extract the first word of "groff", so it can be a program name with args.
12209 set dummy groff; ac_word=$2
12210 echo "$as_me:12210: checking for $ac_word" >&5
12211 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12212 if test "${ac_cv_prog_ROFF+set}" = set; then
12213   echo $ECHO_N "(cached) $ECHO_C" >&6
12214 else
12215   if test -n "$ROFF"; then
12216   ac_cv_prog_ROFF="$ROFF" # Let the user override the test.
12217 else
12218   ac_save_IFS=$IFS; IFS=$ac_path_separator
12219 ac_dummy="$PATH"
12220 for ac_dir in $ac_dummy; do
12221   IFS=$ac_save_IFS
12222   test -z "$ac_dir" && ac_dir=.
12223   $as_executable_p "$ac_dir/$ac_word" || continue
12224 ac_cv_prog_ROFF="groff -etpsR -Tascii -man"
12225 echo "$as_me:12225: found $ac_dir/$ac_word" >&5
12226 break
12227 done
12228
12229 fi
12230 fi
12231 ROFF=$ac_cv_prog_ROFF
12232 if test -n "$ROFF"; then
12233   echo "$as_me:12233: result: $ROFF" >&5
12234 echo "${ECHO_T}$ROFF" >&6
12235 else
12236   echo "$as_me:12236: result: no" >&5
12237 echo "${ECHO_T}no" >&6
12238 fi
12239 ;;
12240                 *sysv4*)
12241                         case "$host" in
12242                                 *-univel-*)     if  test "$GCC" != yes ; then
12243                                                                         cat >>confdefs.h <<\EOF
12244 #define HAVE_MEMSET 1
12245 EOF
12246
12247                                                                 fi
12248                                                                 LDSHFLAGS="-G"
12249                                 ;;
12250                                 *mips-sni-sysv4*) cat >>confdefs.h <<\EOF
12251 #define RELIANTUNIX 1
12252 EOF
12253 ;;
12254                         esac
12255                         ;;
12256                 *sysv5*)
12257                         if  test "$GCC" != yes ; then
12258                                 cat >>confdefs.h <<\EOF
12259 #define HAVE_MEMSET 1
12260 EOF
12261
12262                         fi
12263                         LDSHFLAGS="-G"
12264                         ;;
12265 esac
12266 echo "$as_me:12266: result: $BLDSHARED" >&5
12267 echo "${ECHO_T}$BLDSHARED" >&6
12268 echo "$as_me:12268: checking linker flags for shared libraries" >&5
12269 echo $ECHO_N "checking linker flags for shared libraries... $ECHO_C" >&6
12270 echo "$as_me:12270: result: $LDSHFLAGS" >&5
12271 echo "${ECHO_T}$LDSHFLAGS" >&6
12272 echo "$as_me:12272: checking compiler flags for position-independent code" >&5
12273 echo $ECHO_N "checking compiler flags for position-independent code... $ECHO_C" >&6
12274 echo "$as_me:12274: result: $PICFLAGS" >&5
12275 echo "${ECHO_T}$PICFLAGS" >&6
12276
12277 # this updates our target list if we can build shared libs
12278 if test $BLDSHARED = true; then
12279    LIBSMBCLIENT_SHARED=bin/libsmbclient.$SHLIBEXT
12280 else
12281    LIBSMBCLIENT_SHARED=
12282 fi
12283
12284 ################
12285
12286 echo "$as_me:12286: checking for long long" >&5
12287 echo $ECHO_N "checking for long long... $ECHO_C" >&6
12288 if test "${samba_cv_have_longlong+set}" = set; then
12289   echo $ECHO_N "(cached) $ECHO_C" >&6
12290 else
12291
12292 if test "$cross_compiling" = yes; then
12293   samba_cv_have_longlong=cross
12294 else
12295   cat >conftest.$ac_ext <<_ACEOF
12296 #line 12296 "configure"
12297 #include "confdefs.h"
12298 #include <stdio.h>
12299 main() { long long x = 1000000; x *= x; exit(((x/1000000) == 1000000)? 0: 1); }
12300 _ACEOF
12301 rm -f conftest$ac_exeext
12302 if { (eval echo "$as_me:12302: \"$ac_link\"") >&5
12303   (eval $ac_link) 2>&5
12304   ac_status=$?
12305   echo "$as_me:12305: \$? = $ac_status" >&5
12306   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12307   { (eval echo "$as_me:12307: \"$ac_try\"") >&5
12308   (eval $ac_try) 2>&5
12309   ac_status=$?
12310   echo "$as_me:12310: \$? = $ac_status" >&5
12311   (exit $ac_status); }; }; then
12312   samba_cv_have_longlong=yes
12313 else
12314   echo "$as_me: program exited with status $ac_status" >&5
12315 echo "$as_me: failed program was:" >&5
12316 cat conftest.$ac_ext >&5
12317 samba_cv_have_longlong=no
12318 fi
12319 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12320 fi
12321 fi
12322 echo "$as_me:12322: result: $samba_cv_have_longlong" >&5
12323 echo "${ECHO_T}$samba_cv_have_longlong" >&6
12324 if test x"$samba_cv_have_longlong" = x"yes"; then
12325     cat >>confdefs.h <<\EOF
12326 #define HAVE_LONGLONG 1
12327 EOF
12328
12329 fi
12330
12331 #
12332 # Check if the compiler supports the LL prefix on long long integers.
12333 # AIX needs this.
12334
12335 echo "$as_me:12335: checking for LL suffix on long long integers" >&5
12336 echo $ECHO_N "checking for LL suffix on long long integers... $ECHO_C" >&6
12337 if test "${samba_cv_compiler_supports_ll+set}" = set; then
12338   echo $ECHO_N "(cached) $ECHO_C" >&6
12339 else
12340
12341     cat >conftest.$ac_ext <<_ACEOF
12342 #line 12342 "configure"
12343 #include "confdefs.h"
12344 #include <stdio.h>
12345 int
12346 main ()
12347 {
12348 long long i = 0x8000000000LL
12349   ;
12350   return 0;
12351 }
12352 _ACEOF
12353 rm -f conftest.$ac_objext
12354 if { (eval echo "$as_me:12354: \"$ac_compile\"") >&5
12355   (eval $ac_compile) 2>&5
12356   ac_status=$?
12357   echo "$as_me:12357: \$? = $ac_status" >&5
12358   (exit $ac_status); } &&
12359          { ac_try='test -s conftest.$ac_objext'
12360   { (eval echo "$as_me:12360: \"$ac_try\"") >&5
12361   (eval $ac_try) 2>&5
12362   ac_status=$?
12363   echo "$as_me:12363: \$? = $ac_status" >&5
12364   (exit $ac_status); }; }; then
12365   samba_cv_compiler_supports_ll=yes
12366 else
12367   echo "$as_me: failed program was:" >&5
12368 cat conftest.$ac_ext >&5
12369 samba_cv_compiler_supports_ll=no
12370 fi
12371 rm -f conftest.$ac_objext conftest.$ac_ext
12372 fi
12373 echo "$as_me:12373: result: $samba_cv_compiler_supports_ll" >&5
12374 echo "${ECHO_T}$samba_cv_compiler_supports_ll" >&6
12375 if test x"$samba_cv_compiler_supports_ll" = x"yes"; then
12376    cat >>confdefs.h <<\EOF
12377 #define COMPILER_SUPPORTS_LL 1
12378 EOF
12379
12380 fi
12381
12382 echo "$as_me:12382: checking for 64 bit off_t" >&5
12383 echo $ECHO_N "checking for 64 bit off_t... $ECHO_C" >&6
12384 if test "${samba_cv_SIZEOF_OFF_T+set}" = set; then
12385   echo $ECHO_N "(cached) $ECHO_C" >&6
12386 else
12387
12388 if test "$cross_compiling" = yes; then
12389   samba_cv_SIZEOF_OFF_T=cross
12390 else
12391   cat >conftest.$ac_ext <<_ACEOF
12392 #line 12392 "configure"
12393 #include "confdefs.h"
12394 #include <stdio.h>
12395 #include <sys/stat.h>
12396 main() { exit((sizeof(off_t) == 8) ? 0 : 1); }
12397 _ACEOF
12398 rm -f conftest$ac_exeext
12399 if { (eval echo "$as_me:12399: \"$ac_link\"") >&5
12400   (eval $ac_link) 2>&5
12401   ac_status=$?
12402   echo "$as_me:12402: \$? = $ac_status" >&5
12403   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12404   { (eval echo "$as_me:12404: \"$ac_try\"") >&5
12405   (eval $ac_try) 2>&5
12406   ac_status=$?
12407   echo "$as_me:12407: \$? = $ac_status" >&5
12408   (exit $ac_status); }; }; then
12409   samba_cv_SIZEOF_OFF_T=yes
12410 else
12411   echo "$as_me: program exited with status $ac_status" >&5
12412 echo "$as_me: failed program was:" >&5
12413 cat conftest.$ac_ext >&5
12414 samba_cv_SIZEOF_OFF_T=no
12415 fi
12416 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12417 fi
12418 fi
12419 echo "$as_me:12419: result: $samba_cv_SIZEOF_OFF_T" >&5
12420 echo "${ECHO_T}$samba_cv_SIZEOF_OFF_T" >&6
12421 if test x"$samba_cv_SIZEOF_OFF_T" = x"yes"; then
12422     cat >>confdefs.h <<\EOF
12423 #define SIZEOF_OFF_T 8
12424 EOF
12425
12426 fi
12427
12428 echo "$as_me:12428: checking for off64_t" >&5
12429 echo $ECHO_N "checking for off64_t... $ECHO_C" >&6
12430 if test "${samba_cv_HAVE_OFF64_T+set}" = set; then
12431   echo $ECHO_N "(cached) $ECHO_C" >&6
12432 else
12433
12434 if test "$cross_compiling" = yes; then
12435   samba_cv_HAVE_OFF64_T=cross
12436 else
12437   cat >conftest.$ac_ext <<_ACEOF
12438 #line 12438 "configure"
12439 #include "confdefs.h"
12440
12441 #if defined(HAVE_UNISTD_H)
12442 #include <unistd.h>
12443 #endif
12444 #include <stdio.h>
12445 #include <sys/stat.h>
12446 main() { struct stat64 st; off64_t s; if (sizeof(off_t) == sizeof(off64_t)) exit(1); exit((lstat64("/dev/null", &st)==0)?0:1); }
12447 _ACEOF
12448 rm -f conftest$ac_exeext
12449 if { (eval echo "$as_me:12449: \"$ac_link\"") >&5
12450   (eval $ac_link) 2>&5
12451   ac_status=$?
12452   echo "$as_me:12452: \$? = $ac_status" >&5
12453   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12454   { (eval echo "$as_me:12454: \"$ac_try\"") >&5
12455   (eval $ac_try) 2>&5
12456   ac_status=$?
12457   echo "$as_me:12457: \$? = $ac_status" >&5
12458   (exit $ac_status); }; }; then
12459   samba_cv_HAVE_OFF64_T=yes
12460 else
12461   echo "$as_me: program exited with status $ac_status" >&5
12462 echo "$as_me: failed program was:" >&5
12463 cat conftest.$ac_ext >&5
12464 samba_cv_HAVE_OFF64_T=no
12465 fi
12466 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12467 fi
12468 fi
12469 echo "$as_me:12469: result: $samba_cv_HAVE_OFF64_T" >&5
12470 echo "${ECHO_T}$samba_cv_HAVE_OFF64_T" >&6
12471 if test x"$samba_cv_HAVE_OFF64_T" = x"yes"; then
12472     cat >>confdefs.h <<\EOF
12473 #define HAVE_OFF64_T 1
12474 EOF
12475
12476 fi
12477
12478 echo "$as_me:12478: checking for 64 bit ino_t" >&5
12479 echo $ECHO_N "checking for 64 bit ino_t... $ECHO_C" >&6
12480 if test "${samba_cv_SIZEOF_INO_T+set}" = set; then
12481   echo $ECHO_N "(cached) $ECHO_C" >&6
12482 else
12483
12484 if test "$cross_compiling" = yes; then
12485   samba_cv_SIZEOF_INO_T=cross
12486 else
12487   cat >conftest.$ac_ext <<_ACEOF
12488 #line 12488 "configure"
12489 #include "confdefs.h"
12490 #include <stdio.h>
12491 #include <sys/stat.h>
12492 main() { exit((sizeof(ino_t) == 8) ? 0 : 1); }
12493 _ACEOF
12494 rm -f conftest$ac_exeext
12495 if { (eval echo "$as_me:12495: \"$ac_link\"") >&5
12496   (eval $ac_link) 2>&5
12497   ac_status=$?
12498   echo "$as_me:12498: \$? = $ac_status" >&5
12499   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12500   { (eval echo "$as_me:12500: \"$ac_try\"") >&5
12501   (eval $ac_try) 2>&5
12502   ac_status=$?
12503   echo "$as_me:12503: \$? = $ac_status" >&5
12504   (exit $ac_status); }; }; then
12505   samba_cv_SIZEOF_INO_T=yes
12506 else
12507   echo "$as_me: program exited with status $ac_status" >&5
12508 echo "$as_me: failed program was:" >&5
12509 cat conftest.$ac_ext >&5
12510 samba_cv_SIZEOF_INO_T=no
12511 fi
12512 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12513 fi
12514 fi
12515 echo "$as_me:12515: result: $samba_cv_SIZEOF_INO_T" >&5
12516 echo "${ECHO_T}$samba_cv_SIZEOF_INO_T" >&6
12517 if test x"$samba_cv_SIZEOF_INO_T" = x"yes"; then
12518     cat >>confdefs.h <<\EOF
12519 #define SIZEOF_INO_T 8
12520 EOF
12521
12522 fi
12523
12524 echo "$as_me:12524: checking for ino64_t" >&5
12525 echo $ECHO_N "checking for ino64_t... $ECHO_C" >&6
12526 if test "${samba_cv_HAVE_INO64_T+set}" = set; then
12527   echo $ECHO_N "(cached) $ECHO_C" >&6
12528 else
12529
12530 if test "$cross_compiling" = yes; then
12531   samba_cv_HAVE_INO64_T=cross
12532 else
12533   cat >conftest.$ac_ext <<_ACEOF
12534 #line 12534 "configure"
12535 #include "confdefs.h"
12536
12537 #if defined(HAVE_UNISTD_H)
12538 #include <unistd.h>
12539 #endif
12540 #include <stdio.h>
12541 #include <sys/stat.h>
12542 main() { struct stat64 st; ino64_t s; if (sizeof(ino_t) == sizeof(ino64_t)) exit(1); exit((lstat64("/dev/null", &st)==0)?0:1); }
12543 _ACEOF
12544 rm -f conftest$ac_exeext
12545 if { (eval echo "$as_me:12545: \"$ac_link\"") >&5
12546   (eval $ac_link) 2>&5
12547   ac_status=$?
12548   echo "$as_me:12548: \$? = $ac_status" >&5
12549   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12550   { (eval echo "$as_me:12550: \"$ac_try\"") >&5
12551   (eval $ac_try) 2>&5
12552   ac_status=$?
12553   echo "$as_me:12553: \$? = $ac_status" >&5
12554   (exit $ac_status); }; }; then
12555   samba_cv_HAVE_INO64_T=yes
12556 else
12557   echo "$as_me: program exited with status $ac_status" >&5
12558 echo "$as_me: failed program was:" >&5
12559 cat conftest.$ac_ext >&5
12560 samba_cv_HAVE_INO64_T=no
12561 fi
12562 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12563 fi
12564 fi
12565 echo "$as_me:12565: result: $samba_cv_HAVE_INO64_T" >&5
12566 echo "${ECHO_T}$samba_cv_HAVE_INO64_T" >&6
12567 if test x"$samba_cv_HAVE_INO64_T" = x"yes"; then
12568     cat >>confdefs.h <<\EOF
12569 #define HAVE_INO64_T 1
12570 EOF
12571
12572 fi
12573
12574 echo "$as_me:12574: checking for struct dirent64" >&5
12575 echo $ECHO_N "checking for struct dirent64... $ECHO_C" >&6
12576 if test "${samba_cv_HAVE_STRUCT_DIRENT64+set}" = set; then
12577   echo $ECHO_N "(cached) $ECHO_C" >&6
12578 else
12579
12580 cat >conftest.$ac_ext <<_ACEOF
12581 #line 12581 "configure"
12582 #include "confdefs.h"
12583
12584 #if defined(HAVE_UNISTD_H)
12585 #include <unistd.h>
12586 #endif
12587 #include <sys/types.h>
12588 #include <dirent.h>
12589 int
12590 main ()
12591 {
12592 struct dirent64 de;
12593   ;
12594   return 0;
12595 }
12596 _ACEOF
12597 rm -f conftest.$ac_objext
12598 if { (eval echo "$as_me:12598: \"$ac_compile\"") >&5
12599   (eval $ac_compile) 2>&5
12600   ac_status=$?
12601   echo "$as_me:12601: \$? = $ac_status" >&5
12602   (exit $ac_status); } &&
12603          { ac_try='test -s conftest.$ac_objext'
12604   { (eval echo "$as_me:12604: \"$ac_try\"") >&5
12605   (eval $ac_try) 2>&5
12606   ac_status=$?
12607   echo "$as_me:12607: \$? = $ac_status" >&5
12608   (exit $ac_status); }; }; then
12609   samba_cv_HAVE_STRUCT_DIRENT64=yes
12610 else
12611   echo "$as_me: failed program was:" >&5
12612 cat conftest.$ac_ext >&5
12613 samba_cv_HAVE_STRUCT_DIRENT64=no
12614 fi
12615 rm -f conftest.$ac_objext conftest.$ac_ext
12616 fi
12617 echo "$as_me:12617: result: $samba_cv_HAVE_STRUCT_DIRENT64" >&5
12618 echo "${ECHO_T}$samba_cv_HAVE_STRUCT_DIRENT64" >&6
12619 if test x"$samba_cv_HAVE_STRUCT_DIRENT64" = x"yes"; then
12620     cat >>confdefs.h <<\EOF
12621 #define HAVE_STRUCT_DIRENT64 1
12622 EOF
12623
12624 fi
12625
12626 echo "$as_me:12626: checking for unsigned char" >&5
12627 echo $ECHO_N "checking for unsigned char... $ECHO_C" >&6
12628 if test "${samba_cv_HAVE_UNSIGNED_CHAR+set}" = set; then
12629   echo $ECHO_N "(cached) $ECHO_C" >&6
12630 else
12631
12632 if test "$cross_compiling" = yes; then
12633   samba_cv_HAVE_UNSIGNED_CHAR=cross
12634 else
12635   cat >conftest.$ac_ext <<_ACEOF
12636 #line 12636 "configure"
12637 #include "confdefs.h"
12638 #include <stdio.h>
12639 main() { char c; c=250; exit((c > 0)?0:1); }
12640 _ACEOF
12641 rm -f conftest$ac_exeext
12642 if { (eval echo "$as_me:12642: \"$ac_link\"") >&5
12643   (eval $ac_link) 2>&5
12644   ac_status=$?
12645   echo "$as_me:12645: \$? = $ac_status" >&5
12646   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12647   { (eval echo "$as_me:12647: \"$ac_try\"") >&5
12648   (eval $ac_try) 2>&5
12649   ac_status=$?
12650   echo "$as_me:12650: \$? = $ac_status" >&5
12651   (exit $ac_status); }; }; then
12652   samba_cv_HAVE_UNSIGNED_CHAR=yes
12653 else
12654   echo "$as_me: program exited with status $ac_status" >&5
12655 echo "$as_me: failed program was:" >&5
12656 cat conftest.$ac_ext >&5
12657 samba_cv_HAVE_UNSIGNED_CHAR=no
12658 fi
12659 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12660 fi
12661 fi
12662 echo "$as_me:12662: result: $samba_cv_HAVE_UNSIGNED_CHAR" >&5
12663 echo "${ECHO_T}$samba_cv_HAVE_UNSIGNED_CHAR" >&6
12664 if test x"$samba_cv_HAVE_UNSIGNED_CHAR" = x"yes"; then
12665     cat >>confdefs.h <<\EOF
12666 #define HAVE_UNSIGNED_CHAR 1
12667 EOF
12668
12669 fi
12670
12671 echo "$as_me:12671: checking for sin_len in sock" >&5
12672 echo $ECHO_N "checking for sin_len in sock... $ECHO_C" >&6
12673 if test "${samba_cv_HAVE_SOCK_SIN_LEN+set}" = set; then
12674   echo $ECHO_N "(cached) $ECHO_C" >&6
12675 else
12676
12677 cat >conftest.$ac_ext <<_ACEOF
12678 #line 12678 "configure"
12679 #include "confdefs.h"
12680 #include <sys/types.h>
12681 #include <sys/socket.h>
12682 #include <netinet/in.h>
12683 int
12684 main ()
12685 {
12686 struct sockaddr_in sock; sock.sin_len = sizeof(sock);
12687   ;
12688   return 0;
12689 }
12690 _ACEOF
12691 rm -f conftest.$ac_objext
12692 if { (eval echo "$as_me:12692: \"$ac_compile\"") >&5
12693   (eval $ac_compile) 2>&5
12694   ac_status=$?
12695   echo "$as_me:12695: \$? = $ac_status" >&5
12696   (exit $ac_status); } &&
12697          { ac_try='test -s conftest.$ac_objext'
12698   { (eval echo "$as_me:12698: \"$ac_try\"") >&5
12699   (eval $ac_try) 2>&5
12700   ac_status=$?
12701   echo "$as_me:12701: \$? = $ac_status" >&5
12702   (exit $ac_status); }; }; then
12703   samba_cv_HAVE_SOCK_SIN_LEN=yes
12704 else
12705   echo "$as_me: failed program was:" >&5
12706 cat conftest.$ac_ext >&5
12707 samba_cv_HAVE_SOCK_SIN_LEN=no
12708 fi
12709 rm -f conftest.$ac_objext conftest.$ac_ext
12710 fi
12711 echo "$as_me:12711: result: $samba_cv_HAVE_SOCK_SIN_LEN" >&5
12712 echo "${ECHO_T}$samba_cv_HAVE_SOCK_SIN_LEN" >&6
12713 if test x"$samba_cv_HAVE_SOCK_SIN_LEN" = x"yes"; then
12714     cat >>confdefs.h <<\EOF
12715 #define HAVE_SOCK_SIN_LEN 1
12716 EOF
12717
12718 fi
12719
12720 echo "$as_me:12720: checking whether seekdir returns void" >&5
12721 echo $ECHO_N "checking whether seekdir returns void... $ECHO_C" >&6
12722 if test "${samba_cv_SEEKDIR_RETURNS_VOID+set}" = set; then
12723   echo $ECHO_N "(cached) $ECHO_C" >&6
12724 else
12725
12726 cat >conftest.$ac_ext <<_ACEOF
12727 #line 12727 "configure"
12728 #include "confdefs.h"
12729 #include <sys/types.h>
12730 #include <dirent.h>
12731 void seekdir(DIR *d, long loc) { return; }
12732 int
12733 main ()
12734 {
12735 return 0;
12736   ;
12737   return 0;
12738 }
12739 _ACEOF
12740 rm -f conftest.$ac_objext
12741 if { (eval echo "$as_me:12741: \"$ac_compile\"") >&5
12742   (eval $ac_compile) 2>&5
12743   ac_status=$?
12744   echo "$as_me:12744: \$? = $ac_status" >&5
12745   (exit $ac_status); } &&
12746          { ac_try='test -s conftest.$ac_objext'
12747   { (eval echo "$as_me:12747: \"$ac_try\"") >&5
12748   (eval $ac_try) 2>&5
12749   ac_status=$?
12750   echo "$as_me:12750: \$? = $ac_status" >&5
12751   (exit $ac_status); }; }; then
12752   samba_cv_SEEKDIR_RETURNS_VOID=yes
12753 else
12754   echo "$as_me: failed program was:" >&5
12755 cat conftest.$ac_ext >&5
12756 samba_cv_SEEKDIR_RETURNS_VOID=no
12757 fi
12758 rm -f conftest.$ac_objext conftest.$ac_ext
12759 fi
12760 echo "$as_me:12760: result: $samba_cv_SEEKDIR_RETURNS_VOID" >&5
12761 echo "${ECHO_T}$samba_cv_SEEKDIR_RETURNS_VOID" >&6
12762 if test x"$samba_cv_SEEKDIR_RETURNS_VOID" = x"yes"; then
12763     cat >>confdefs.h <<\EOF
12764 #define SEEKDIR_RETURNS_VOID 1
12765 EOF
12766
12767 fi
12768
12769 echo "$as_me:12769: checking for __FILE__ macro" >&5
12770 echo $ECHO_N "checking for __FILE__ macro... $ECHO_C" >&6
12771 if test "${samba_cv_HAVE_FILE_MACRO+set}" = set; then
12772   echo $ECHO_N "(cached) $ECHO_C" >&6
12773 else
12774
12775 cat >conftest.$ac_ext <<_ACEOF
12776 #line 12776 "configure"
12777 #include "confdefs.h"
12778 #include <stdio.h>
12779 int
12780 main ()
12781 {
12782 printf("%s\n", __FILE__);
12783   ;
12784   return 0;
12785 }
12786 _ACEOF
12787 rm -f conftest.$ac_objext
12788 if { (eval echo "$as_me:12788: \"$ac_compile\"") >&5
12789   (eval $ac_compile) 2>&5
12790   ac_status=$?
12791   echo "$as_me:12791: \$? = $ac_status" >&5
12792   (exit $ac_status); } &&
12793          { ac_try='test -s conftest.$ac_objext'
12794   { (eval echo "$as_me:12794: \"$ac_try\"") >&5
12795   (eval $ac_try) 2>&5
12796   ac_status=$?
12797   echo "$as_me:12797: \$? = $ac_status" >&5
12798   (exit $ac_status); }; }; then
12799   samba_cv_HAVE_FILE_MACRO=yes
12800 else
12801   echo "$as_me: failed program was:" >&5
12802 cat conftest.$ac_ext >&5
12803 samba_cv_HAVE_FILE_MACRO=no
12804 fi
12805 rm -f conftest.$ac_objext conftest.$ac_ext
12806 fi
12807 echo "$as_me:12807: result: $samba_cv_HAVE_FILE_MACRO" >&5
12808 echo "${ECHO_T}$samba_cv_HAVE_FILE_MACRO" >&6
12809 if test x"$samba_cv_HAVE_FILE_MACRO" = x"yes"; then
12810     cat >>confdefs.h <<\EOF
12811 #define HAVE_FILE_MACRO 1
12812 EOF
12813
12814 fi
12815
12816 echo "$as_me:12816: checking for __FUNCTION__ macro" >&5
12817 echo $ECHO_N "checking for __FUNCTION__ macro... $ECHO_C" >&6
12818 if test "${samba_cv_HAVE_FUNCTION_MACRO+set}" = set; then
12819   echo $ECHO_N "(cached) $ECHO_C" >&6
12820 else
12821
12822 cat >conftest.$ac_ext <<_ACEOF
12823 #line 12823 "configure"
12824 #include "confdefs.h"
12825 #include <stdio.h>
12826 int
12827 main ()
12828 {
12829 printf("%s\n", __FUNCTION__);
12830   ;
12831   return 0;
12832 }
12833 _ACEOF
12834 rm -f conftest.$ac_objext
12835 if { (eval echo "$as_me:12835: \"$ac_compile\"") >&5
12836   (eval $ac_compile) 2>&5
12837   ac_status=$?
12838   echo "$as_me:12838: \$? = $ac_status" >&5
12839   (exit $ac_status); } &&
12840          { ac_try='test -s conftest.$ac_objext'
12841   { (eval echo "$as_me:12841: \"$ac_try\"") >&5
12842   (eval $ac_try) 2>&5
12843   ac_status=$?
12844   echo "$as_me:12844: \$? = $ac_status" >&5
12845   (exit $ac_status); }; }; then
12846   samba_cv_HAVE_FUNCTION_MACRO=yes
12847 else
12848   echo "$as_me: failed program was:" >&5
12849 cat conftest.$ac_ext >&5
12850 samba_cv_HAVE_FUNCTION_MACRO=no
12851 fi
12852 rm -f conftest.$ac_objext conftest.$ac_ext
12853 fi
12854 echo "$as_me:12854: result: $samba_cv_HAVE_FUNCTION_MACRO" >&5
12855 echo "${ECHO_T}$samba_cv_HAVE_FUNCTION_MACRO" >&6
12856 if test x"$samba_cv_HAVE_FUNCTION_MACRO" = x"yes"; then
12857     cat >>confdefs.h <<\EOF
12858 #define HAVE_FUNCTION_MACRO 1
12859 EOF
12860
12861 fi
12862
12863 echo "$as_me:12863: checking if gettimeofday takes tz argument" >&5
12864 echo $ECHO_N "checking if gettimeofday takes tz argument... $ECHO_C" >&6
12865 if test "${samba_cv_HAVE_GETTIMEOFDAY_TZ+set}" = set; then
12866   echo $ECHO_N "(cached) $ECHO_C" >&6
12867 else
12868
12869 if test "$cross_compiling" = yes; then
12870   samba_cv_HAVE_GETTIMEOFDAY_TZ=cross
12871 else
12872   cat >conftest.$ac_ext <<_ACEOF
12873 #line 12873 "configure"
12874 #include "confdefs.h"
12875
12876 #include <sys/time.h>
12877 #include <unistd.h>
12878 main() { struct timeval tv; exit(gettimeofday(&tv, NULL));}
12879 _ACEOF
12880 rm -f conftest$ac_exeext
12881 if { (eval echo "$as_me:12881: \"$ac_link\"") >&5
12882   (eval $ac_link) 2>&5
12883   ac_status=$?
12884   echo "$as_me:12884: \$? = $ac_status" >&5
12885   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12886   { (eval echo "$as_me:12886: \"$ac_try\"") >&5
12887   (eval $ac_try) 2>&5
12888   ac_status=$?
12889   echo "$as_me:12889: \$? = $ac_status" >&5
12890   (exit $ac_status); }; }; then
12891   samba_cv_HAVE_GETTIMEOFDAY_TZ=yes
12892 else
12893   echo "$as_me: program exited with status $ac_status" >&5
12894 echo "$as_me: failed program was:" >&5
12895 cat conftest.$ac_ext >&5
12896 samba_cv_HAVE_GETTIMEOFDAY_TZ=no
12897 fi
12898 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12899 fi
12900 fi
12901 echo "$as_me:12901: result: $samba_cv_HAVE_GETTIMEOFDAY_TZ" >&5
12902 echo "${ECHO_T}$samba_cv_HAVE_GETTIMEOFDAY_TZ" >&6
12903 if test x"$samba_cv_HAVE_GETTIMEOFDAY_TZ" = x"yes"; then
12904     cat >>confdefs.h <<\EOF
12905 #define HAVE_GETTIMEOFDAY_TZ 1
12906 EOF
12907
12908 fi
12909
12910 echo "$as_me:12910: checking for C99 vsnprintf" >&5
12911 echo $ECHO_N "checking for C99 vsnprintf... $ECHO_C" >&6
12912 if test "${samba_cv_HAVE_C99_VSNPRINTF+set}" = set; then
12913   echo $ECHO_N "(cached) $ECHO_C" >&6
12914 else
12915
12916 if test "$cross_compiling" = yes; then
12917   samba_cv_HAVE_C99_VSNPRINTF=cross
12918 else
12919   cat >conftest.$ac_ext <<_ACEOF
12920 #line 12920 "configure"
12921 #include "confdefs.h"
12922
12923 #include <sys/types.h>
12924 #include <stdarg.h>
12925 void foo(const char *format, ...) {
12926        va_list ap;
12927        int len;
12928        char buf[5];
12929
12930        va_start(ap, format);
12931        len = vsnprintf(0, 0, format, ap);
12932        va_end(ap);
12933        if (len != 5) exit(1);
12934
12935        if (snprintf(buf, 3, "hello") != 5 || strcmp(buf, "he") != 0) exit(1);
12936
12937        exit(0);
12938 }
12939 main() { foo("hello"); }
12940
12941 _ACEOF
12942 rm -f conftest$ac_exeext
12943 if { (eval echo "$as_me:12943: \"$ac_link\"") >&5
12944   (eval $ac_link) 2>&5
12945   ac_status=$?
12946   echo "$as_me:12946: \$? = $ac_status" >&5
12947   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12948   { (eval echo "$as_me:12948: \"$ac_try\"") >&5
12949   (eval $ac_try) 2>&5
12950   ac_status=$?
12951   echo "$as_me:12951: \$? = $ac_status" >&5
12952   (exit $ac_status); }; }; then
12953   samba_cv_HAVE_C99_VSNPRINTF=yes
12954 else
12955   echo "$as_me: program exited with status $ac_status" >&5
12956 echo "$as_me: failed program was:" >&5
12957 cat conftest.$ac_ext >&5
12958 samba_cv_HAVE_C99_VSNPRINTF=no
12959 fi
12960 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12961 fi
12962 fi
12963 echo "$as_me:12963: result: $samba_cv_HAVE_C99_VSNPRINTF" >&5
12964 echo "${ECHO_T}$samba_cv_HAVE_C99_VSNPRINTF" >&6
12965 if test x"$samba_cv_HAVE_C99_VSNPRINTF" = x"yes"; then
12966     cat >>confdefs.h <<\EOF
12967 #define HAVE_C99_VSNPRINTF 1
12968 EOF
12969
12970 fi
12971
12972 echo "$as_me:12972: checking for broken readdir" >&5
12973 echo $ECHO_N "checking for broken readdir... $ECHO_C" >&6
12974 if test "${samba_cv_HAVE_BROKEN_READDIR+set}" = set; then
12975   echo $ECHO_N "(cached) $ECHO_C" >&6
12976 else
12977
12978 if test "$cross_compiling" = yes; then
12979   samba_cv_HAVE_BROKEN_READDIR=cross
12980 else
12981   cat >conftest.$ac_ext <<_ACEOF
12982 #line 12982 "configure"
12983 #include "confdefs.h"
12984 #include <sys/types.h>
12985 #include <dirent.h>
12986 main() { struct dirent *di; DIR *d = opendir("."); di = readdir(d);
12987 if (di && di->d_name[-2] == '.' && di->d_name[-1] == 0 &&
12988 di->d_name[0] == 0) exit(0); exit(1);}
12989 _ACEOF
12990 rm -f conftest$ac_exeext
12991 if { (eval echo "$as_me:12991: \"$ac_link\"") >&5
12992   (eval $ac_link) 2>&5
12993   ac_status=$?
12994   echo "$as_me:12994: \$? = $ac_status" >&5
12995   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12996   { (eval echo "$as_me:12996: \"$ac_try\"") >&5
12997   (eval $ac_try) 2>&5
12998   ac_status=$?
12999   echo "$as_me:12999: \$? = $ac_status" >&5
13000   (exit $ac_status); }; }; then
13001   samba_cv_HAVE_BROKEN_READDIR=yes
13002 else
13003   echo "$as_me: program exited with status $ac_status" >&5
13004 echo "$as_me: failed program was:" >&5
13005 cat conftest.$ac_ext >&5
13006 samba_cv_HAVE_BROKEN_READDIR=no
13007 fi
13008 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13009 fi
13010 fi
13011 echo "$as_me:13011: result: $samba_cv_HAVE_BROKEN_READDIR" >&5
13012 echo "${ECHO_T}$samba_cv_HAVE_BROKEN_READDIR" >&6
13013 if test x"$samba_cv_HAVE_BROKEN_READDIR" = x"yes"; then
13014     cat >>confdefs.h <<\EOF
13015 #define HAVE_BROKEN_READDIR 1
13016 EOF
13017
13018 fi
13019
13020 echo "$as_me:13020: checking for utimbuf" >&5
13021 echo $ECHO_N "checking for utimbuf... $ECHO_C" >&6
13022 if test "${samba_cv_HAVE_UTIMBUF+set}" = set; then
13023   echo $ECHO_N "(cached) $ECHO_C" >&6
13024 else
13025
13026 cat >conftest.$ac_ext <<_ACEOF
13027 #line 13027 "configure"
13028 #include "confdefs.h"
13029 #include <sys/types.h>
13030 #include <utime.h>
13031 int
13032 main ()
13033 {
13034 struct utimbuf tbuf;  tbuf.actime = 0; tbuf.modtime = 1; exit(utime("foo.c",&tbuf));
13035   ;
13036   return 0;
13037 }
13038 _ACEOF
13039 rm -f conftest.$ac_objext
13040 if { (eval echo "$as_me:13040: \"$ac_compile\"") >&5
13041   (eval $ac_compile) 2>&5
13042   ac_status=$?
13043   echo "$as_me:13043: \$? = $ac_status" >&5
13044   (exit $ac_status); } &&
13045          { ac_try='test -s conftest.$ac_objext'
13046   { (eval echo "$as_me:13046: \"$ac_try\"") >&5
13047   (eval $ac_try) 2>&5
13048   ac_status=$?
13049   echo "$as_me:13049: \$? = $ac_status" >&5
13050   (exit $ac_status); }; }; then
13051   samba_cv_HAVE_UTIMBUF=yes
13052 else
13053   echo "$as_me: failed program was:" >&5
13054 cat conftest.$ac_ext >&5
13055 samba_cv_HAVE_UTIMBUF=no
13056 fi
13057 rm -f conftest.$ac_objext conftest.$ac_ext
13058 fi
13059 echo "$as_me:13059: result: $samba_cv_HAVE_UTIMBUF" >&5
13060 echo "${ECHO_T}$samba_cv_HAVE_UTIMBUF" >&6
13061 if test x"$samba_cv_HAVE_UTIMBUF" = x"yes"; then
13062     cat >>confdefs.h <<\EOF
13063 #define HAVE_UTIMBUF 1
13064 EOF
13065
13066 fi
13067
13068 for ac_func in pututline pututxline updwtmp updwtmpx getutmpx
13069 do
13070 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13071 echo "$as_me:13071: checking for $ac_func" >&5
13072 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13073 if eval "test \"\${$as_ac_var+set}\" = set"; then
13074   echo $ECHO_N "(cached) $ECHO_C" >&6
13075 else
13076   cat >conftest.$ac_ext <<_ACEOF
13077 #line 13077 "configure"
13078 #include "confdefs.h"
13079 /* System header to define __stub macros and hopefully few prototypes,
13080     which can conflict with char $ac_func (); below.  */
13081 #include <assert.h>
13082 /* Override any gcc2 internal prototype to avoid an error.  */
13083 #ifdef __cplusplus
13084 extern "C"
13085 #endif
13086 /* We use char because int might match the return type of a gcc2
13087    builtin and then its argument prototype would still apply.  */
13088 char $ac_func ();
13089 char (*f) ();
13090
13091 int
13092 main ()
13093 {
13094 /* The GNU C library defines this for functions which it implements
13095     to always fail with ENOSYS.  Some functions are actually named
13096     something starting with __ and the normal name is an alias.  */
13097 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13098 choke me
13099 #else
13100 f = $ac_func;
13101 #endif
13102
13103   ;
13104   return 0;
13105 }
13106 _ACEOF
13107 rm -f conftest.$ac_objext conftest$ac_exeext
13108 if { (eval echo "$as_me:13108: \"$ac_link\"") >&5
13109   (eval $ac_link) 2>&5
13110   ac_status=$?
13111   echo "$as_me:13111: \$? = $ac_status" >&5
13112   (exit $ac_status); } &&
13113          { ac_try='test -s conftest$ac_exeext'
13114   { (eval echo "$as_me:13114: \"$ac_try\"") >&5
13115   (eval $ac_try) 2>&5
13116   ac_status=$?
13117   echo "$as_me:13117: \$? = $ac_status" >&5
13118   (exit $ac_status); }; }; then
13119   eval "$as_ac_var=yes"
13120 else
13121   echo "$as_me: failed program was:" >&5
13122 cat conftest.$ac_ext >&5
13123 eval "$as_ac_var=no"
13124 fi
13125 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13126 fi
13127 echo "$as_me:13127: result: `eval echo '${'$as_ac_var'}'`" >&5
13128 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13129 if test `eval echo '${'$as_ac_var'}'` = yes; then
13130   cat >>confdefs.h <<EOF
13131 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13132 EOF
13133
13134 fi
13135 done
13136
13137 echo "$as_me:13137: checking for ut_name in utmp" >&5
13138 echo $ECHO_N "checking for ut_name in utmp... $ECHO_C" >&6
13139 if test "${samba_cv_HAVE_UT_UT_NAME+set}" = set; then
13140   echo $ECHO_N "(cached) $ECHO_C" >&6
13141 else
13142
13143 cat >conftest.$ac_ext <<_ACEOF
13144 #line 13144 "configure"
13145 #include "confdefs.h"
13146 #include <sys/types.h>
13147 #include <utmp.h>
13148 int
13149 main ()
13150 {
13151 struct utmp ut;  ut.ut_name[0] = 'a';
13152   ;
13153   return 0;
13154 }
13155 _ACEOF
13156 rm -f conftest.$ac_objext
13157 if { (eval echo "$as_me:13157: \"$ac_compile\"") >&5
13158   (eval $ac_compile) 2>&5
13159   ac_status=$?
13160   echo "$as_me:13160: \$? = $ac_status" >&5
13161   (exit $ac_status); } &&
13162          { ac_try='test -s conftest.$ac_objext'
13163   { (eval echo "$as_me:13163: \"$ac_try\"") >&5
13164   (eval $ac_try) 2>&5
13165   ac_status=$?
13166   echo "$as_me:13166: \$? = $ac_status" >&5
13167   (exit $ac_status); }; }; then
13168   samba_cv_HAVE_UT_UT_NAME=yes
13169 else
13170   echo "$as_me: failed program was:" >&5
13171 cat conftest.$ac_ext >&5
13172 samba_cv_HAVE_UT_UT_NAME=no
13173 fi
13174 rm -f conftest.$ac_objext conftest.$ac_ext
13175 fi
13176 echo "$as_me:13176: result: $samba_cv_HAVE_UT_UT_NAME" >&5
13177 echo "${ECHO_T}$samba_cv_HAVE_UT_UT_NAME" >&6
13178 if test x"$samba_cv_HAVE_UT_UT_NAME" = x"yes"; then
13179     cat >>confdefs.h <<\EOF
13180 #define HAVE_UT_UT_NAME 1
13181 EOF
13182
13183 fi
13184
13185 echo "$as_me:13185: checking for ut_user in utmp" >&5
13186 echo $ECHO_N "checking for ut_user in utmp... $ECHO_C" >&6
13187 if test "${samba_cv_HAVE_UT_UT_USER+set}" = set; then
13188   echo $ECHO_N "(cached) $ECHO_C" >&6
13189 else
13190
13191 cat >conftest.$ac_ext <<_ACEOF
13192 #line 13192 "configure"
13193 #include "confdefs.h"
13194 #include <sys/types.h>
13195 #include <utmp.h>
13196 int
13197 main ()
13198 {
13199 struct utmp ut;  ut.ut_user[0] = 'a';
13200   ;
13201   return 0;
13202 }
13203 _ACEOF
13204 rm -f conftest.$ac_objext
13205 if { (eval echo "$as_me:13205: \"$ac_compile\"") >&5
13206   (eval $ac_compile) 2>&5
13207   ac_status=$?
13208   echo "$as_me:13208: \$? = $ac_status" >&5
13209   (exit $ac_status); } &&
13210          { ac_try='test -s conftest.$ac_objext'
13211   { (eval echo "$as_me:13211: \"$ac_try\"") >&5
13212   (eval $ac_try) 2>&5
13213   ac_status=$?
13214   echo "$as_me:13214: \$? = $ac_status" >&5
13215   (exit $ac_status); }; }; then
13216   samba_cv_HAVE_UT_UT_USER=yes
13217 else
13218   echo "$as_me: failed program was:" >&5
13219 cat conftest.$ac_ext >&5
13220 samba_cv_HAVE_UT_UT_USER=no
13221 fi
13222 rm -f conftest.$ac_objext conftest.$ac_ext
13223 fi
13224 echo "$as_me:13224: result: $samba_cv_HAVE_UT_UT_USER" >&5
13225 echo "${ECHO_T}$samba_cv_HAVE_UT_UT_USER" >&6
13226 if test x"$samba_cv_HAVE_UT_UT_USER" = x"yes"; then
13227     cat >>confdefs.h <<\EOF
13228 #define HAVE_UT_UT_USER 1
13229 EOF
13230
13231 fi
13232
13233 echo "$as_me:13233: checking for ut_id in utmp" >&5
13234 echo $ECHO_N "checking for ut_id in utmp... $ECHO_C" >&6
13235 if test "${samba_cv_HAVE_UT_UT_ID+set}" = set; then
13236   echo $ECHO_N "(cached) $ECHO_C" >&6
13237 else
13238
13239 cat >conftest.$ac_ext <<_ACEOF
13240 #line 13240 "configure"
13241 #include "confdefs.h"
13242 #include <sys/types.h>
13243 #include <utmp.h>
13244 int
13245 main ()
13246 {
13247 struct utmp ut;  ut.ut_id[0] = 'a';
13248   ;
13249   return 0;
13250 }
13251 _ACEOF
13252 rm -f conftest.$ac_objext
13253 if { (eval echo "$as_me:13253: \"$ac_compile\"") >&5
13254   (eval $ac_compile) 2>&5
13255   ac_status=$?
13256   echo "$as_me:13256: \$? = $ac_status" >&5
13257   (exit $ac_status); } &&
13258          { ac_try='test -s conftest.$ac_objext'
13259   { (eval echo "$as_me:13259: \"$ac_try\"") >&5
13260   (eval $ac_try) 2>&5
13261   ac_status=$?
13262   echo "$as_me:13262: \$? = $ac_status" >&5
13263   (exit $ac_status); }; }; then
13264   samba_cv_HAVE_UT_UT_ID=yes
13265 else
13266   echo "$as_me: failed program was:" >&5
13267 cat conftest.$ac_ext >&5
13268 samba_cv_HAVE_UT_UT_ID=no
13269 fi
13270 rm -f conftest.$ac_objext conftest.$ac_ext
13271 fi
13272 echo "$as_me:13272: result: $samba_cv_HAVE_UT_UT_ID" >&5
13273 echo "${ECHO_T}$samba_cv_HAVE_UT_UT_ID" >&6
13274 if test x"$samba_cv_HAVE_UT_UT_ID" = x"yes"; then
13275     cat >>confdefs.h <<\EOF
13276 #define HAVE_UT_UT_ID 1
13277 EOF
13278
13279 fi
13280
13281 echo "$as_me:13281: checking for ut_host in utmp" >&5
13282 echo $ECHO_N "checking for ut_host in utmp... $ECHO_C" >&6
13283 if test "${samba_cv_HAVE_UT_UT_HOST+set}" = set; then
13284   echo $ECHO_N "(cached) $ECHO_C" >&6
13285 else
13286
13287 cat >conftest.$ac_ext <<_ACEOF
13288 #line 13288 "configure"
13289 #include "confdefs.h"
13290 #include <sys/types.h>
13291 #include <utmp.h>
13292 int
13293 main ()
13294 {
13295 struct utmp ut;  ut.ut_host[0] = 'a';
13296   ;
13297   return 0;
13298 }
13299 _ACEOF
13300 rm -f conftest.$ac_objext
13301 if { (eval echo "$as_me:13301: \"$ac_compile\"") >&5
13302   (eval $ac_compile) 2>&5
13303   ac_status=$?
13304   echo "$as_me:13304: \$? = $ac_status" >&5
13305   (exit $ac_status); } &&
13306          { ac_try='test -s conftest.$ac_objext'
13307   { (eval echo "$as_me:13307: \"$ac_try\"") >&5
13308   (eval $ac_try) 2>&5
13309   ac_status=$?
13310   echo "$as_me:13310: \$? = $ac_status" >&5
13311   (exit $ac_status); }; }; then
13312   samba_cv_HAVE_UT_UT_HOST=yes
13313 else
13314   echo "$as_me: failed program was:" >&5
13315 cat conftest.$ac_ext >&5
13316 samba_cv_HAVE_UT_UT_HOST=no
13317 fi
13318 rm -f conftest.$ac_objext conftest.$ac_ext
13319 fi
13320 echo "$as_me:13320: result: $samba_cv_HAVE_UT_UT_HOST" >&5
13321 echo "${ECHO_T}$samba_cv_HAVE_UT_UT_HOST" >&6
13322 if test x"$samba_cv_HAVE_UT_UT_HOST" = x"yes"; then
13323     cat >>confdefs.h <<\EOF
13324 #define HAVE_UT_UT_HOST 1
13325 EOF
13326
13327 fi
13328
13329 echo "$as_me:13329: checking for ut_time in utmp" >&5
13330 echo $ECHO_N "checking for ut_time in utmp... $ECHO_C" >&6
13331 if test "${samba_cv_HAVE_UT_UT_TIME+set}" = set; then
13332   echo $ECHO_N "(cached) $ECHO_C" >&6
13333 else
13334
13335 cat >conftest.$ac_ext <<_ACEOF
13336 #line 13336 "configure"
13337 #include "confdefs.h"
13338 #include <sys/types.h>
13339 #include <utmp.h>
13340 int
13341 main ()
13342 {
13343 struct utmp ut;  time_t t; ut.ut_time = t;
13344   ;
13345   return 0;
13346 }
13347 _ACEOF
13348 rm -f conftest.$ac_objext
13349 if { (eval echo "$as_me:13349: \"$ac_compile\"") >&5
13350   (eval $ac_compile) 2>&5
13351   ac_status=$?
13352   echo "$as_me:13352: \$? = $ac_status" >&5
13353   (exit $ac_status); } &&
13354          { ac_try='test -s conftest.$ac_objext'
13355   { (eval echo "$as_me:13355: \"$ac_try\"") >&5
13356   (eval $ac_try) 2>&5
13357   ac_status=$?
13358   echo "$as_me:13358: \$? = $ac_status" >&5
13359   (exit $ac_status); }; }; then
13360   samba_cv_HAVE_UT_UT_TIME=yes
13361 else
13362   echo "$as_me: failed program was:" >&5
13363 cat conftest.$ac_ext >&5
13364 samba_cv_HAVE_UT_UT_TIME=no
13365 fi
13366 rm -f conftest.$ac_objext conftest.$ac_ext
13367 fi
13368 echo "$as_me:13368: result: $samba_cv_HAVE_UT_UT_TIME" >&5
13369 echo "${ECHO_T}$samba_cv_HAVE_UT_UT_TIME" >&6
13370 if test x"$samba_cv_HAVE_UT_UT_TIME" = x"yes"; then
13371     cat >>confdefs.h <<\EOF
13372 #define HAVE_UT_UT_TIME 1
13373 EOF
13374
13375 fi
13376
13377 echo "$as_me:13377: checking for ut_tv in utmp" >&5
13378 echo $ECHO_N "checking for ut_tv in utmp... $ECHO_C" >&6
13379 if test "${samba_cv_HAVE_UT_UT_TV+set}" = set; then
13380   echo $ECHO_N "(cached) $ECHO_C" >&6
13381 else
13382
13383 cat >conftest.$ac_ext <<_ACEOF
13384 #line 13384 "configure"
13385 #include "confdefs.h"
13386 #include <sys/types.h>
13387 #include <utmp.h>
13388 int
13389 main ()
13390 {
13391 struct utmp ut;  struct timeval tv; ut.ut_tv = tv;
13392   ;
13393   return 0;
13394 }
13395 _ACEOF
13396 rm -f conftest.$ac_objext
13397 if { (eval echo "$as_me:13397: \"$ac_compile\"") >&5
13398   (eval $ac_compile) 2>&5
13399   ac_status=$?
13400   echo "$as_me:13400: \$? = $ac_status" >&5
13401   (exit $ac_status); } &&
13402          { ac_try='test -s conftest.$ac_objext'
13403   { (eval echo "$as_me:13403: \"$ac_try\"") >&5
13404   (eval $ac_try) 2>&5
13405   ac_status=$?
13406   echo "$as_me:13406: \$? = $ac_status" >&5
13407   (exit $ac_status); }; }; then
13408   samba_cv_HAVE_UT_UT_TV=yes
13409 else
13410   echo "$as_me: failed program was:" >&5
13411 cat conftest.$ac_ext >&5
13412 samba_cv_HAVE_UT_UT_TV=no
13413 fi
13414 rm -f conftest.$ac_objext conftest.$ac_ext
13415 fi
13416 echo "$as_me:13416: result: $samba_cv_HAVE_UT_UT_TV" >&5
13417 echo "${ECHO_T}$samba_cv_HAVE_UT_UT_TV" >&6
13418 if test x"$samba_cv_HAVE_UT_UT_TV" = x"yes"; then
13419     cat >>confdefs.h <<\EOF
13420 #define HAVE_UT_UT_TV 1
13421 EOF
13422
13423 fi
13424
13425 echo "$as_me:13425: checking for ut_type in utmp" >&5
13426 echo $ECHO_N "checking for ut_type in utmp... $ECHO_C" >&6
13427 if test "${samba_cv_HAVE_UT_UT_TYPE+set}" = set; then
13428   echo $ECHO_N "(cached) $ECHO_C" >&6
13429 else
13430
13431 cat >conftest.$ac_ext <<_ACEOF
13432 #line 13432 "configure"
13433 #include "confdefs.h"
13434 #include <sys/types.h>
13435 #include <utmp.h>
13436 int
13437 main ()
13438 {
13439 struct utmp ut;  ut.ut_type = 0;
13440   ;
13441   return 0;
13442 }
13443 _ACEOF
13444 rm -f conftest.$ac_objext
13445 if { (eval echo "$as_me:13445: \"$ac_compile\"") >&5
13446   (eval $ac_compile) 2>&5
13447   ac_status=$?
13448   echo "$as_me:13448: \$? = $ac_status" >&5
13449   (exit $ac_status); } &&
13450          { ac_try='test -s conftest.$ac_objext'
13451   { (eval echo "$as_me:13451: \"$ac_try\"") >&5
13452   (eval $ac_try) 2>&5
13453   ac_status=$?
13454   echo "$as_me:13454: \$? = $ac_status" >&5
13455   (exit $ac_status); }; }; then
13456   samba_cv_HAVE_UT_UT_TYPE=yes
13457 else
13458   echo "$as_me: failed program was:" >&5
13459 cat conftest.$ac_ext >&5
13460 samba_cv_HAVE_UT_UT_TYPE=no
13461 fi
13462 rm -f conftest.$ac_objext conftest.$ac_ext
13463 fi
13464 echo "$as_me:13464: result: $samba_cv_HAVE_UT_UT_TYPE" >&5
13465 echo "${ECHO_T}$samba_cv_HAVE_UT_UT_TYPE" >&6
13466 if test x"$samba_cv_HAVE_UT_UT_TYPE" = x"yes"; then
13467     cat >>confdefs.h <<\EOF
13468 #define HAVE_UT_UT_TYPE 1
13469 EOF
13470
13471 fi
13472
13473 echo "$as_me:13473: checking for ut_pid in utmp" >&5
13474 echo $ECHO_N "checking for ut_pid in utmp... $ECHO_C" >&6
13475 if test "${samba_cv_HAVE_UT_UT_PID+set}" = set; then
13476   echo $ECHO_N "(cached) $ECHO_C" >&6
13477 else
13478
13479 cat >conftest.$ac_ext <<_ACEOF
13480 #line 13480 "configure"
13481 #include "confdefs.h"
13482 #include <sys/types.h>
13483 #include <utmp.h>
13484 int
13485 main ()
13486 {
13487 struct utmp ut;  ut.ut_pid = 0;
13488   ;
13489   return 0;
13490 }
13491 _ACEOF
13492 rm -f conftest.$ac_objext
13493 if { (eval echo "$as_me:13493: \"$ac_compile\"") >&5
13494   (eval $ac_compile) 2>&5
13495   ac_status=$?
13496   echo "$as_me:13496: \$? = $ac_status" >&5
13497   (exit $ac_status); } &&
13498          { ac_try='test -s conftest.$ac_objext'
13499   { (eval echo "$as_me:13499: \"$ac_try\"") >&5
13500   (eval $ac_try) 2>&5
13501   ac_status=$?
13502   echo "$as_me:13502: \$? = $ac_status" >&5
13503   (exit $ac_status); }; }; then
13504   samba_cv_HAVE_UT_UT_PID=yes
13505 else
13506   echo "$as_me: failed program was:" >&5
13507 cat conftest.$ac_ext >&5
13508 samba_cv_HAVE_UT_UT_PID=no
13509 fi
13510 rm -f conftest.$ac_objext conftest.$ac_ext
13511 fi
13512 echo "$as_me:13512: result: $samba_cv_HAVE_UT_UT_PID" >&5
13513 echo "${ECHO_T}$samba_cv_HAVE_UT_UT_PID" >&6
13514 if test x"$samba_cv_HAVE_UT_UT_PID" = x"yes"; then
13515     cat >>confdefs.h <<\EOF
13516 #define HAVE_UT_UT_PID 1
13517 EOF
13518
13519 fi
13520
13521 echo "$as_me:13521: checking for ut_exit in utmp" >&5
13522 echo $ECHO_N "checking for ut_exit in utmp... $ECHO_C" >&6
13523 if test "${samba_cv_HAVE_UT_UT_EXIT+set}" = set; then
13524   echo $ECHO_N "(cached) $ECHO_C" >&6
13525 else
13526
13527 cat >conftest.$ac_ext <<_ACEOF
13528 #line 13528 "configure"
13529 #include "confdefs.h"
13530 #include <sys/types.h>
13531 #include <utmp.h>
13532 int
13533 main ()
13534 {
13535 struct utmp ut;  ut.ut_exit.e_exit = 0;
13536   ;
13537   return 0;
13538 }
13539 _ACEOF
13540 rm -f conftest.$ac_objext
13541 if { (eval echo "$as_me:13541: \"$ac_compile\"") >&5
13542   (eval $ac_compile) 2>&5
13543   ac_status=$?
13544   echo "$as_me:13544: \$? = $ac_status" >&5
13545   (exit $ac_status); } &&
13546          { ac_try='test -s conftest.$ac_objext'
13547   { (eval echo "$as_me:13547: \"$ac_try\"") >&5
13548   (eval $ac_try) 2>&5
13549   ac_status=$?
13550   echo "$as_me:13550: \$? = $ac_status" >&5
13551   (exit $ac_status); }; }; then
13552   samba_cv_HAVE_UT_UT_EXIT=yes
13553 else
13554   echo "$as_me: failed program was:" >&5
13555 cat conftest.$ac_ext >&5
13556 samba_cv_HAVE_UT_UT_EXIT=no
13557 fi
13558 rm -f conftest.$ac_objext conftest.$ac_ext
13559 fi
13560 echo "$as_me:13560: result: $samba_cv_HAVE_UT_UT_EXIT" >&5
13561 echo "${ECHO_T}$samba_cv_HAVE_UT_UT_EXIT" >&6
13562 if test x"$samba_cv_HAVE_UT_UT_EXIT" = x"yes"; then
13563     cat >>confdefs.h <<\EOF
13564 #define HAVE_UT_UT_EXIT 1
13565 EOF
13566
13567 fi
13568
13569 echo "$as_me:13569: checking for ut_addr in utmp" >&5
13570 echo $ECHO_N "checking for ut_addr in utmp... $ECHO_C" >&6
13571 if test "${samba_cv_HAVE_UT_UT_ADDR+set}" = set; then
13572   echo $ECHO_N "(cached) $ECHO_C" >&6
13573 else
13574
13575 cat >conftest.$ac_ext <<_ACEOF
13576 #line 13576 "configure"
13577 #include "confdefs.h"
13578 #include <sys/types.h>
13579 #include <utmp.h>
13580 int
13581 main ()
13582 {
13583 struct utmp ut;  ut.ut_addr = 0;
13584   ;
13585   return 0;
13586 }
13587 _ACEOF
13588 rm -f conftest.$ac_objext
13589 if { (eval echo "$as_me:13589: \"$ac_compile\"") >&5
13590   (eval $ac_compile) 2>&5
13591   ac_status=$?
13592   echo "$as_me:13592: \$? = $ac_status" >&5
13593   (exit $ac_status); } &&
13594          { ac_try='test -s conftest.$ac_objext'
13595   { (eval echo "$as_me:13595: \"$ac_try\"") >&5
13596   (eval $ac_try) 2>&5
13597   ac_status=$?
13598   echo "$as_me:13598: \$? = $ac_status" >&5
13599   (exit $ac_status); }; }; then
13600   samba_cv_HAVE_UT_UT_ADDR=yes
13601 else
13602   echo "$as_me: failed program was:" >&5
13603 cat conftest.$ac_ext >&5
13604 samba_cv_HAVE_UT_UT_ADDR=no
13605 fi
13606 rm -f conftest.$ac_objext conftest.$ac_ext
13607 fi
13608 echo "$as_me:13608: result: $samba_cv_HAVE_UT_UT_ADDR" >&5
13609 echo "${ECHO_T}$samba_cv_HAVE_UT_UT_ADDR" >&6
13610 if test x"$samba_cv_HAVE_UT_UT_ADDR" = x"yes"; then
13611     cat >>confdefs.h <<\EOF
13612 #define HAVE_UT_UT_ADDR 1
13613 EOF
13614
13615 fi
13616
13617 if test x$ac_cv_func_pututline = xyes ; then
13618   echo "$as_me:13618: checking whether pututline returns pointer" >&5
13619 echo $ECHO_N "checking whether pututline returns pointer... $ECHO_C" >&6
13620 if test "${samba_cv_PUTUTLINE_RETURNS_UTMP+set}" = set; then
13621   echo $ECHO_N "(cached) $ECHO_C" >&6
13622 else
13623
13624   cat >conftest.$ac_ext <<_ACEOF
13625 #line 13625 "configure"
13626 #include "confdefs.h"
13627 #include <sys/types.h>
13628 #include <utmp.h>
13629 int
13630 main ()
13631 {
13632 struct utmp utarg; struct utmp *utreturn; utreturn = pututline(&utarg);
13633   ;
13634   return 0;
13635 }
13636 _ACEOF
13637 rm -f conftest.$ac_objext
13638 if { (eval echo "$as_me:13638: \"$ac_compile\"") >&5
13639   (eval $ac_compile) 2>&5
13640   ac_status=$?
13641   echo "$as_me:13641: \$? = $ac_status" >&5
13642   (exit $ac_status); } &&
13643          { ac_try='test -s conftest.$ac_objext'
13644   { (eval echo "$as_me:13644: \"$ac_try\"") >&5
13645   (eval $ac_try) 2>&5
13646   ac_status=$?
13647   echo "$as_me:13647: \$? = $ac_status" >&5
13648   (exit $ac_status); }; }; then
13649   samba_cv_PUTUTLINE_RETURNS_UTMP=yes
13650 else
13651   echo "$as_me: failed program was:" >&5
13652 cat conftest.$ac_ext >&5
13653 samba_cv_PUTUTLINE_RETURNS_UTMP=no
13654 fi
13655 rm -f conftest.$ac_objext conftest.$ac_ext
13656 fi
13657 echo "$as_me:13657: result: $samba_cv_PUTUTLINE_RETURNS_UTMP" >&5
13658 echo "${ECHO_T}$samba_cv_PUTUTLINE_RETURNS_UTMP" >&6
13659   if test x"$samba_cv_PUTUTLINE_RETURNS_UTMP" = x"yes"; then
13660       cat >>confdefs.h <<\EOF
13661 #define PUTUTLINE_RETURNS_UTMP 1
13662 EOF
13663
13664   fi
13665 fi
13666
13667 echo "$as_me:13667: checking for ut_syslen in utmpx" >&5
13668 echo $ECHO_N "checking for ut_syslen in utmpx... $ECHO_C" >&6
13669 if test "${samba_cv_HAVE_UX_UT_SYSLEN+set}" = set; then
13670   echo $ECHO_N "(cached) $ECHO_C" >&6
13671 else
13672
13673 cat >conftest.$ac_ext <<_ACEOF
13674 #line 13674 "configure"
13675 #include "confdefs.h"
13676 #include <sys/types.h>
13677 #include <utmpx.h>
13678 int
13679 main ()
13680 {
13681 struct utmpx ux;  ux.ut_syslen = 0;
13682   ;
13683   return 0;
13684 }
13685 _ACEOF
13686 rm -f conftest.$ac_objext
13687 if { (eval echo "$as_me:13687: \"$ac_compile\"") >&5
13688   (eval $ac_compile) 2>&5
13689   ac_status=$?
13690   echo "$as_me:13690: \$? = $ac_status" >&5
13691   (exit $ac_status); } &&
13692          { ac_try='test -s conftest.$ac_objext'
13693   { (eval echo "$as_me:13693: \"$ac_try\"") >&5
13694   (eval $ac_try) 2>&5
13695   ac_status=$?
13696   echo "$as_me:13696: \$? = $ac_status" >&5
13697   (exit $ac_status); }; }; then
13698   samba_cv_HAVE_UX_UT_SYSLEN=yes
13699 else
13700   echo "$as_me: failed program was:" >&5
13701 cat conftest.$ac_ext >&5
13702 samba_cv_HAVE_UX_UT_SYSLEN=no
13703 fi
13704 rm -f conftest.$ac_objext conftest.$ac_ext
13705 fi
13706 echo "$as_me:13706: result: $samba_cv_HAVE_UX_UT_SYSLEN" >&5
13707 echo "${ECHO_T}$samba_cv_HAVE_UX_UT_SYSLEN" >&6
13708 if test x"$samba_cv_HAVE_UX_UT_SYSLEN" = x"yes"; then
13709     cat >>confdefs.h <<\EOF
13710 #define HAVE_UX_UT_SYSLEN 1
13711 EOF
13712
13713 fi
13714
13715 #################################################
13716 # check for libiconv support
13717 echo "$as_me:13717: checking whether to use libiconv" >&5
13718 echo $ECHO_N "checking whether to use libiconv... $ECHO_C" >&6
13719
13720 # Check whether --with-libiconv or --without-libiconv was given.
13721 if test "${with_libiconv+set}" = set; then
13722   withval="$with_libiconv"
13723    case "$withval" in
13724   no)
13725     echo "$as_me:13725: result: no" >&5
13726 echo "${ECHO_T}no" >&6
13727     ;;
13728   *)
13729     echo "$as_me:13729: result: yes" >&5
13730 echo "${ECHO_T}yes" >&6
13731     CFLAGS="$CFLAGS -I$withval/include"
13732     LDFLAGS="$LDFLAGS -L$withval/lib"
13733
13734 echo "$as_me:13734: checking for iconv_open in -liconv" >&5
13735 echo $ECHO_N "checking for iconv_open in -liconv... $ECHO_C" >&6
13736 if test "${ac_cv_lib_iconv_iconv_open+set}" = set; then
13737   echo $ECHO_N "(cached) $ECHO_C" >&6
13738 else
13739   ac_check_lib_save_LIBS=$LIBS
13740 LIBS="-liconv  $LIBS"
13741 cat >conftest.$ac_ext <<_ACEOF
13742 #line 13742 "configure"
13743 #include "confdefs.h"
13744
13745 /* Override any gcc2 internal prototype to avoid an error.  */
13746 #ifdef __cplusplus
13747 extern "C"
13748 #endif
13749 /* We use char because int might match the return type of a gcc2
13750    builtin and then its argument prototype would still apply.  */
13751 char iconv_open ();
13752 int
13753 main ()
13754 {
13755 iconv_open ();
13756   ;
13757   return 0;
13758 }
13759 _ACEOF
13760 rm -f conftest.$ac_objext conftest$ac_exeext
13761 if { (eval echo "$as_me:13761: \"$ac_link\"") >&5
13762   (eval $ac_link) 2>&5
13763   ac_status=$?
13764   echo "$as_me:13764: \$? = $ac_status" >&5
13765   (exit $ac_status); } &&
13766          { ac_try='test -s conftest$ac_exeext'
13767   { (eval echo "$as_me:13767: \"$ac_try\"") >&5
13768   (eval $ac_try) 2>&5
13769   ac_status=$?
13770   echo "$as_me:13770: \$? = $ac_status" >&5
13771   (exit $ac_status); }; }; then
13772   ac_cv_lib_iconv_iconv_open=yes
13773 else
13774   echo "$as_me: failed program was:" >&5
13775 cat conftest.$ac_ext >&5
13776 ac_cv_lib_iconv_iconv_open=no
13777 fi
13778 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13779 LIBS=$ac_check_lib_save_LIBS
13780 fi
13781 echo "$as_me:13781: result: $ac_cv_lib_iconv_iconv_open" >&5
13782 echo "${ECHO_T}$ac_cv_lib_iconv_iconv_open" >&6
13783 if test $ac_cv_lib_iconv_iconv_open = yes; then
13784   cat >>confdefs.h <<EOF
13785 #define HAVE_LIBICONV 1
13786 EOF
13787
13788   LIBS="-liconv $LIBS"
13789
13790 fi
13791
13792     cat >>confdefs.h <<EOF
13793 #define WITH_LIBICONV "${withval}"
13794 EOF
13795
13796     ;;
13797   esac
13798 else
13799   echo "$as_me:13799: result: no" >&5
13800 echo "${ECHO_T}no" >&6
13801
13802 fi;
13803
13804 ############
13805 # check for iconv in libc
13806 echo "$as_me:13806: checking for working iconv" >&5
13807 echo $ECHO_N "checking for working iconv... $ECHO_C" >&6
13808 if test "${samba_cv_HAVE_NATIVE_ICONV+set}" = set; then
13809   echo $ECHO_N "(cached) $ECHO_C" >&6
13810 else
13811
13812 if test "$cross_compiling" = yes; then
13813   samba_cv_HAVE_NATIVE_ICONV=cross
13814 else
13815   cat >conftest.$ac_ext <<_ACEOF
13816 #line 13816 "configure"
13817 #include "confdefs.h"
13818
13819 #include <iconv.h>
13820 main() {
13821        iconv_t cd = iconv_open("ASCII", "UCS-2LE");
13822        if (cd == 0 || cd == (iconv_t)-1) return -1;
13823        return 0;
13824 }
13825
13826 _ACEOF
13827 rm -f conftest$ac_exeext
13828 if { (eval echo "$as_me:13828: \"$ac_link\"") >&5
13829   (eval $ac_link) 2>&5
13830   ac_status=$?
13831   echo "$as_me:13831: \$? = $ac_status" >&5
13832   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13833   { (eval echo "$as_me:13833: \"$ac_try\"") >&5
13834   (eval $ac_try) 2>&5
13835   ac_status=$?
13836   echo "$as_me:13836: \$? = $ac_status" >&5
13837   (exit $ac_status); }; }; then
13838   samba_cv_HAVE_NATIVE_ICONV=yes
13839 else
13840   echo "$as_me: program exited with status $ac_status" >&5
13841 echo "$as_me: failed program was:" >&5
13842 cat conftest.$ac_ext >&5
13843 samba_cv_HAVE_NATIVE_ICONV=no
13844 fi
13845 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13846 fi
13847 fi
13848 echo "$as_me:13848: result: $samba_cv_HAVE_NATIVE_ICONV" >&5
13849 echo "${ECHO_T}$samba_cv_HAVE_NATIVE_ICONV" >&6
13850 if test x"$samba_cv_HAVE_NATIVE_ICONV" = x"yes"; then
13851     cat >>confdefs.h <<\EOF
13852 #define HAVE_NATIVE_ICONV 1
13853 EOF
13854
13855 fi
13856
13857 echo "$as_me:13857: checking for Linux kernel oplocks" >&5
13858 echo $ECHO_N "checking for Linux kernel oplocks... $ECHO_C" >&6
13859 if test "${samba_cv_HAVE_KERNEL_OPLOCKS_LINUX+set}" = set; then
13860   echo $ECHO_N "(cached) $ECHO_C" >&6
13861 else
13862
13863 if test "$cross_compiling" = yes; then
13864   samba_cv_HAVE_KERNEL_OPLOCKS_LINUX=cross
13865 else
13866   cat >conftest.$ac_ext <<_ACEOF
13867 #line 13867 "configure"
13868 #include "confdefs.h"
13869
13870 #include <sys/types.h>
13871 #include <fcntl.h>
13872 #ifndef F_GETLEASE
13873 #define F_GETLEASE      1025
13874 #endif
13875 main() {
13876        int fd = open("/dev/null", O_RDONLY);
13877        return fcntl(fd, F_GETLEASE, 0) == -1;
13878 }
13879
13880 _ACEOF
13881 rm -f conftest$ac_exeext
13882 if { (eval echo "$as_me:13882: \"$ac_link\"") >&5
13883   (eval $ac_link) 2>&5
13884   ac_status=$?
13885   echo "$as_me:13885: \$? = $ac_status" >&5
13886   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13887   { (eval echo "$as_me:13887: \"$ac_try\"") >&5
13888   (eval $ac_try) 2>&5
13889   ac_status=$?
13890   echo "$as_me:13890: \$? = $ac_status" >&5
13891   (exit $ac_status); }; }; then
13892   samba_cv_HAVE_KERNEL_OPLOCKS_LINUX=yes
13893 else
13894   echo "$as_me: program exited with status $ac_status" >&5
13895 echo "$as_me: failed program was:" >&5
13896 cat conftest.$ac_ext >&5
13897 samba_cv_HAVE_KERNEL_OPLOCKS_LINUX=no
13898 fi
13899 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13900 fi
13901 fi
13902 echo "$as_me:13902: result: $samba_cv_HAVE_KERNEL_OPLOCKS_LINUX" >&5
13903 echo "${ECHO_T}$samba_cv_HAVE_KERNEL_OPLOCKS_LINUX" >&6
13904 if test x"$samba_cv_HAVE_KERNEL_OPLOCKS_LINUX" = x"yes"; then
13905     cat >>confdefs.h <<\EOF
13906 #define HAVE_KERNEL_OPLOCKS_LINUX 1
13907 EOF
13908
13909 fi
13910
13911 echo "$as_me:13911: checking for kernel change notify support" >&5
13912 echo $ECHO_N "checking for kernel change notify support... $ECHO_C" >&6
13913 if test "${samba_cv_HAVE_KERNEL_CHANGE_NOTIFY+set}" = set; then
13914   echo $ECHO_N "(cached) $ECHO_C" >&6
13915 else
13916
13917 if test "$cross_compiling" = yes; then
13918   samba_cv_HAVE_KERNEL_CHANGE_NOTIFY=cross
13919 else
13920   cat >conftest.$ac_ext <<_ACEOF
13921 #line 13921 "configure"
13922 #include "confdefs.h"
13923
13924 #include <sys/types.h>
13925 #include <fcntl.h>
13926 #include <signal.h>
13927 #ifndef F_NOTIFY
13928 #define F_NOTIFY 1026
13929 #endif
13930 main() {
13931         exit(fcntl(open("/tmp", O_RDONLY), F_NOTIFY, 0) == -1 ?  1 : 0);
13932 }
13933
13934 _ACEOF
13935 rm -f conftest$ac_exeext
13936 if { (eval echo "$as_me:13936: \"$ac_link\"") >&5
13937   (eval $ac_link) 2>&5
13938   ac_status=$?
13939   echo "$as_me:13939: \$? = $ac_status" >&5
13940   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13941   { (eval echo "$as_me:13941: \"$ac_try\"") >&5
13942   (eval $ac_try) 2>&5
13943   ac_status=$?
13944   echo "$as_me:13944: \$? = $ac_status" >&5
13945   (exit $ac_status); }; }; then
13946   samba_cv_HAVE_KERNEL_CHANGE_NOTIFY=yes
13947 else
13948   echo "$as_me: program exited with status $ac_status" >&5
13949 echo "$as_me: failed program was:" >&5
13950 cat conftest.$ac_ext >&5
13951 samba_cv_HAVE_KERNEL_CHANGE_NOTIFY=no
13952 fi
13953 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13954 fi
13955 fi
13956 echo "$as_me:13956: result: $samba_cv_HAVE_KERNEL_CHANGE_NOTIFY" >&5
13957 echo "${ECHO_T}$samba_cv_HAVE_KERNEL_CHANGE_NOTIFY" >&6
13958 if test x"$samba_cv_HAVE_KERNEL_CHANGE_NOTIFY" = x"yes"; then
13959     cat >>confdefs.h <<\EOF
13960 #define HAVE_KERNEL_CHANGE_NOTIFY 1
13961 EOF
13962
13963 fi
13964
13965 echo "$as_me:13965: checking for kernel share modes" >&5
13966 echo $ECHO_N "checking for kernel share modes... $ECHO_C" >&6
13967 if test "${samba_cv_HAVE_KERNEL_SHARE_MODES+set}" = set; then
13968   echo $ECHO_N "(cached) $ECHO_C" >&6
13969 else
13970
13971 if test "$cross_compiling" = yes; then
13972   samba_cv_HAVE_KERNEL_SHARE_MODES=cross
13973 else
13974   cat >conftest.$ac_ext <<_ACEOF
13975 #line 13975 "configure"
13976 #include "confdefs.h"
13977
13978 #include <sys/types.h>
13979 #include <fcntl.h>
13980 #include <signal.h>
13981 #include <sys/file.h>
13982 #ifndef LOCK_MAND
13983 #define LOCK_MAND       32
13984 #define LOCK_READ       64
13985 #endif
13986 main() {
13987         exit(flock(open("/dev/null", O_RDWR), LOCK_MAND|LOCK_READ) != 0);
13988 }
13989
13990 _ACEOF
13991 rm -f conftest$ac_exeext
13992 if { (eval echo "$as_me:13992: \"$ac_link\"") >&5
13993   (eval $ac_link) 2>&5
13994   ac_status=$?
13995   echo "$as_me:13995: \$? = $ac_status" >&5
13996   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13997   { (eval echo "$as_me:13997: \"$ac_try\"") >&5
13998   (eval $ac_try) 2>&5
13999   ac_status=$?
14000   echo "$as_me:14000: \$? = $ac_status" >&5
14001   (exit $ac_status); }; }; then
14002   samba_cv_HAVE_KERNEL_SHARE_MODES=yes
14003 else
14004   echo "$as_me: program exited with status $ac_status" >&5
14005 echo "$as_me: failed program was:" >&5
14006 cat conftest.$ac_ext >&5
14007 samba_cv_HAVE_KERNEL_SHARE_MODES=no
14008 fi
14009 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14010 fi
14011 fi
14012 echo "$as_me:14012: result: $samba_cv_HAVE_KERNEL_SHARE_MODES" >&5
14013 echo "${ECHO_T}$samba_cv_HAVE_KERNEL_SHARE_MODES" >&6
14014 if test x"$samba_cv_HAVE_KERNEL_SHARE_MODES" = x"yes"; then
14015     cat >>confdefs.h <<\EOF
14016 #define HAVE_KERNEL_SHARE_MODES 1
14017 EOF
14018
14019 fi
14020
14021 echo "$as_me:14021: checking for IRIX kernel oplock type definitions" >&5
14022 echo $ECHO_N "checking for IRIX kernel oplock type definitions... $ECHO_C" >&6
14023 if test "${samba_cv_HAVE_KERNEL_OPLOCKS_IRIX+set}" = set; then
14024   echo $ECHO_N "(cached) $ECHO_C" >&6
14025 else
14026
14027 cat >conftest.$ac_ext <<_ACEOF
14028 #line 14028 "configure"
14029 #include "confdefs.h"
14030 #include <sys/types.h>
14031 #include <fcntl.h>
14032 int
14033 main ()
14034 {
14035 oplock_stat_t t; t.os_state = OP_REVOKE; t.os_dev = 1; t.os_ino = 1;
14036   ;
14037   return 0;
14038 }
14039 _ACEOF
14040 rm -f conftest.$ac_objext
14041 if { (eval echo "$as_me:14041: \"$ac_compile\"") >&5
14042   (eval $ac_compile) 2>&5
14043   ac_status=$?
14044   echo "$as_me:14044: \$? = $ac_status" >&5
14045   (exit $ac_status); } &&
14046          { ac_try='test -s conftest.$ac_objext'
14047   { (eval echo "$as_me:14047: \"$ac_try\"") >&5
14048   (eval $ac_try) 2>&5
14049   ac_status=$?
14050   echo "$as_me:14050: \$? = $ac_status" >&5
14051   (exit $ac_status); }; }; then
14052   samba_cv_HAVE_KERNEL_OPLOCKS_IRIX=yes
14053 else
14054   echo "$as_me: failed program was:" >&5
14055 cat conftest.$ac_ext >&5
14056 samba_cv_HAVE_KERNEL_OPLOCKS_IRIX=no
14057 fi
14058 rm -f conftest.$ac_objext conftest.$ac_ext
14059 fi
14060 echo "$as_me:14060: result: $samba_cv_HAVE_KERNEL_OPLOCKS_IRIX" >&5
14061 echo "${ECHO_T}$samba_cv_HAVE_KERNEL_OPLOCKS_IRIX" >&6
14062 if test x"$samba_cv_HAVE_KERNEL_OPLOCKS_IRIX" = x"yes"; then
14063     cat >>confdefs.h <<\EOF
14064 #define HAVE_KERNEL_OPLOCKS_IRIX 1
14065 EOF
14066
14067 fi
14068
14069 echo "$as_me:14069: checking for irix specific capabilities" >&5
14070 echo $ECHO_N "checking for irix specific capabilities... $ECHO_C" >&6
14071 if test "${samba_cv_HAVE_IRIX_SPECIFIC_CAPABILITIES+set}" = set; then
14072   echo $ECHO_N "(cached) $ECHO_C" >&6
14073 else
14074
14075 if test "$cross_compiling" = yes; then
14076   samba_cv_HAVE_IRIX_SPECIFIC_CAPABILITIES=cross
14077 else
14078   cat >conftest.$ac_ext <<_ACEOF
14079 #line 14079 "configure"
14080 #include "confdefs.h"
14081 #include <sys/types.h>
14082 #include <sys/capability.h>
14083 main() {
14084  cap_t cap;
14085  if ((cap = cap_get_proc()) == NULL)
14086    exit(1);
14087  cap->cap_effective |= CAP_NETWORK_MGT;
14088  cap->cap_inheritable |= CAP_NETWORK_MGT;
14089  cap_set_proc(cap);
14090  exit(0);
14091 }
14092
14093 _ACEOF
14094 rm -f conftest$ac_exeext
14095 if { (eval echo "$as_me:14095: \"$ac_link\"") >&5
14096   (eval $ac_link) 2>&5
14097   ac_status=$?
14098   echo "$as_me:14098: \$? = $ac_status" >&5
14099   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14100   { (eval echo "$as_me:14100: \"$ac_try\"") >&5
14101   (eval $ac_try) 2>&5
14102   ac_status=$?
14103   echo "$as_me:14103: \$? = $ac_status" >&5
14104   (exit $ac_status); }; }; then
14105   samba_cv_HAVE_IRIX_SPECIFIC_CAPABILITIES=yes
14106 else
14107   echo "$as_me: program exited with status $ac_status" >&5
14108 echo "$as_me: failed program was:" >&5
14109 cat conftest.$ac_ext >&5
14110 samba_cv_HAVE_IRIX_SPECIFIC_CAPABILITIES=no
14111 fi
14112 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14113 fi
14114 fi
14115 echo "$as_me:14115: result: $samba_cv_HAVE_IRIX_SPECIFIC_CAPABILITIES" >&5
14116 echo "${ECHO_T}$samba_cv_HAVE_IRIX_SPECIFIC_CAPABILITIES" >&6
14117 if test x"$samba_cv_HAVE_IRIX_SPECIFIC_CAPABILITIES" = x"yes"; then
14118     cat >>confdefs.h <<\EOF
14119 #define HAVE_IRIX_SPECIFIC_CAPABILITIES 1
14120 EOF
14121
14122 fi
14123
14124 #
14125 # Check for int16, uint16, int32 and uint32 in rpc/types.h included from rpc/rpc.h
14126 # This is *really* broken but some systems (DEC OSF1) do this.... JRA.
14127 #
14128
14129 echo "$as_me:14129: checking for int16 typedef included by rpc/rpc.h" >&5
14130 echo $ECHO_N "checking for int16 typedef included by rpc/rpc.h... $ECHO_C" >&6
14131 if test "${samba_cv_HAVE_INT16_FROM_RPC_RPC_H+set}" = set; then
14132   echo $ECHO_N "(cached) $ECHO_C" >&6
14133 else
14134
14135 cat >conftest.$ac_ext <<_ACEOF
14136 #line 14136 "configure"
14137 #include "confdefs.h"
14138 #include <sys/types.h>
14139 #if defined(HAVE_RPC_RPC_H)
14140 #include <rpc/rpc.h>
14141 #endif
14142 int
14143 main ()
14144 {
14145 int16 testvar;
14146   ;
14147   return 0;
14148 }
14149 _ACEOF
14150 rm -f conftest.$ac_objext
14151 if { (eval echo "$as_me:14151: \"$ac_compile\"") >&5
14152   (eval $ac_compile) 2>&5
14153   ac_status=$?
14154   echo "$as_me:14154: \$? = $ac_status" >&5
14155   (exit $ac_status); } &&
14156          { ac_try='test -s conftest.$ac_objext'
14157   { (eval echo "$as_me:14157: \"$ac_try\"") >&5
14158   (eval $ac_try) 2>&5
14159   ac_status=$?
14160   echo "$as_me:14160: \$? = $ac_status" >&5
14161   (exit $ac_status); }; }; then
14162   samba_cv_HAVE_INT16_FROM_RPC_RPC_H=yes
14163 else
14164   echo "$as_me: failed program was:" >&5
14165 cat conftest.$ac_ext >&5
14166 samba_cv_HAVE_INT16_FROM_RPC_RPC_H=no
14167 fi
14168 rm -f conftest.$ac_objext conftest.$ac_ext
14169 fi
14170 echo "$as_me:14170: result: $samba_cv_HAVE_INT16_FROM_RPC_RPC_H" >&5
14171 echo "${ECHO_T}$samba_cv_HAVE_INT16_FROM_RPC_RPC_H" >&6
14172 if test x"$samba_cv_HAVE_INT16_FROM_RPC_RPC_H" = x"yes"; then
14173     cat >>confdefs.h <<\EOF
14174 #define HAVE_INT16_FROM_RPC_RPC_H 1
14175 EOF
14176
14177 fi
14178
14179 echo "$as_me:14179: checking for uint16 typedef included by rpc/rpc.h" >&5
14180 echo $ECHO_N "checking for uint16 typedef included by rpc/rpc.h... $ECHO_C" >&6
14181 if test "${samba_cv_HAVE_UINT16_FROM_RPC_RPC_H+set}" = set; then
14182   echo $ECHO_N "(cached) $ECHO_C" >&6
14183 else
14184
14185 cat >conftest.$ac_ext <<_ACEOF
14186 #line 14186 "configure"
14187 #include "confdefs.h"
14188 #include <sys/types.h>
14189 #if defined(HAVE_RPC_RPC_H)
14190 #include <rpc/rpc.h>
14191 #endif
14192 int
14193 main ()
14194 {
14195 uint16 testvar;
14196   ;
14197   return 0;
14198 }
14199 _ACEOF
14200 rm -f conftest.$ac_objext
14201 if { (eval echo "$as_me:14201: \"$ac_compile\"") >&5
14202   (eval $ac_compile) 2>&5
14203   ac_status=$?
14204   echo "$as_me:14204: \$? = $ac_status" >&5
14205   (exit $ac_status); } &&
14206          { ac_try='test -s conftest.$ac_objext'
14207   { (eval echo "$as_me:14207: \"$ac_try\"") >&5
14208   (eval $ac_try) 2>&5
14209   ac_status=$?
14210   echo "$as_me:14210: \$? = $ac_status" >&5
14211   (exit $ac_status); }; }; then
14212   samba_cv_HAVE_UINT16_FROM_RPC_RPC_H=yes
14213 else
14214   echo "$as_me: failed program was:" >&5
14215 cat conftest.$ac_ext >&5
14216 samba_cv_HAVE_UINT16_FROM_RPC_RPC_H=no
14217 fi
14218 rm -f conftest.$ac_objext conftest.$ac_ext
14219 fi
14220 echo "$as_me:14220: result: $samba_cv_HAVE_UINT16_FROM_RPC_RPC_H" >&5
14221 echo "${ECHO_T}$samba_cv_HAVE_UINT16_FROM_RPC_RPC_H" >&6
14222 if test x"$samba_cv_HAVE_UINT16_FROM_RPC_RPC_H" = x"yes"; then
14223     cat >>confdefs.h <<\EOF
14224 #define HAVE_UINT16_FROM_RPC_RPC_H 1
14225 EOF
14226
14227 fi
14228
14229 echo "$as_me:14229: checking for int32 typedef included by rpc/rpc.h" >&5
14230 echo $ECHO_N "checking for int32 typedef included by rpc/rpc.h... $ECHO_C" >&6
14231 if test "${samba_cv_HAVE_INT32_FROM_RPC_RPC_H+set}" = set; then
14232   echo $ECHO_N "(cached) $ECHO_C" >&6
14233 else
14234
14235 cat >conftest.$ac_ext <<_ACEOF
14236 #line 14236 "configure"
14237 #include "confdefs.h"
14238 #include <sys/types.h>
14239 #if defined(HAVE_RPC_RPC_H)
14240 #include <rpc/rpc.h>
14241 #endif
14242 int
14243 main ()
14244 {
14245 int32 testvar;
14246   ;
14247   return 0;
14248 }
14249 _ACEOF
14250 rm -f conftest.$ac_objext
14251 if { (eval echo "$as_me:14251: \"$ac_compile\"") >&5
14252   (eval $ac_compile) 2>&5
14253   ac_status=$?
14254   echo "$as_me:14254: \$? = $ac_status" >&5
14255   (exit $ac_status); } &&
14256          { ac_try='test -s conftest.$ac_objext'
14257   { (eval echo "$as_me:14257: \"$ac_try\"") >&5
14258   (eval $ac_try) 2>&5
14259   ac_status=$?
14260   echo "$as_me:14260: \$? = $ac_status" >&5
14261   (exit $ac_status); }; }; then
14262   samba_cv_HAVE_INT32_FROM_RPC_RPC_H=yes
14263 else
14264   echo "$as_me: failed program was:" >&5
14265 cat conftest.$ac_ext >&5
14266 samba_cv_HAVE_INT32_FROM_RPC_RPC_H=no
14267 fi
14268 rm -f conftest.$ac_objext conftest.$ac_ext
14269 fi
14270 echo "$as_me:14270: result: $samba_cv_HAVE_INT32_FROM_RPC_RPC_H" >&5
14271 echo "${ECHO_T}$samba_cv_HAVE_INT32_FROM_RPC_RPC_H" >&6
14272 if test x"$samba_cv_HAVE_INT32_FROM_RPC_RPC_H" = x"yes"; then
14273     cat >>confdefs.h <<\EOF
14274 #define HAVE_INT32_FROM_RPC_RPC_H 1
14275 EOF
14276
14277 fi
14278
14279 echo "$as_me:14279: checking for uint32 typedef included by rpc/rpc.h" >&5
14280 echo $ECHO_N "checking for uint32 typedef included by rpc/rpc.h... $ECHO_C" >&6
14281 if test "${samba_cv_HAVE_UINT32_FROM_RPC_RPC_H+set}" = set; then
14282   echo $ECHO_N "(cached) $ECHO_C" >&6
14283 else
14284
14285 cat >conftest.$ac_ext <<_ACEOF
14286 #line 14286 "configure"
14287 #include "confdefs.h"
14288 #include <sys/types.h>
14289 #if defined(HAVE_RPC_RPC_H)
14290 #include <rpc/rpc.h>
14291 #endif
14292 int
14293 main ()
14294 {
14295 uint32 testvar;
14296   ;
14297   return 0;
14298 }
14299 _ACEOF
14300 rm -f conftest.$ac_objext
14301 if { (eval echo "$as_me:14301: \"$ac_compile\"") >&5
14302   (eval $ac_compile) 2>&5
14303   ac_status=$?
14304   echo "$as_me:14304: \$? = $ac_status" >&5
14305   (exit $ac_status); } &&
14306          { ac_try='test -s conftest.$ac_objext'
14307   { (eval echo "$as_me:14307: \"$ac_try\"") >&5
14308   (eval $ac_try) 2>&5
14309   ac_status=$?
14310   echo "$as_me:14310: \$? = $ac_status" >&5
14311   (exit $ac_status); }; }; then
14312   samba_cv_HAVE_UINT32_FROM_RPC_RPC_H=yes
14313 else
14314   echo "$as_me: failed program was:" >&5
14315 cat conftest.$ac_ext >&5
14316 samba_cv_HAVE_UINT32_FROM_RPC_RPC_H=no
14317 fi
14318 rm -f conftest.$ac_objext conftest.$ac_ext
14319 fi
14320 echo "$as_me:14320: result: $samba_cv_HAVE_UINT32_FROM_RPC_RPC_H" >&5
14321 echo "${ECHO_T}$samba_cv_HAVE_UINT32_FROM_RPC_RPC_H" >&6
14322 if test x"$samba_cv_HAVE_UINT32_FROM_RPC_RPC_H" = x"yes"; then
14323     cat >>confdefs.h <<\EOF
14324 #define HAVE_UINT32_FROM_RPC_RPC_H 1
14325 EOF
14326
14327 fi
14328
14329 echo "$as_me:14329: checking for conflicting AUTH_ERROR define in rpc/rpc.h" >&5
14330 echo $ECHO_N "checking for conflicting AUTH_ERROR define in rpc/rpc.h... $ECHO_C" >&6
14331 if test "${samba_cv_HAVE_RPC_AUTH_ERROR_CONFLICT+set}" = set; then
14332   echo $ECHO_N "(cached) $ECHO_C" >&6
14333 else
14334
14335 cat >conftest.$ac_ext <<_ACEOF
14336 #line 14336 "configure"
14337 #include "confdefs.h"
14338 #include <sys/types.h>
14339 #ifdef HAVE_SYS_SECURITY_H
14340 #include <sys/security.h>
14341 #include <prot.h>
14342 #endif  /* HAVE_SYS_SECURITY_H */
14343 #if defined(HAVE_RPC_RPC_H)
14344 #include <rpc/rpc.h>
14345 #endif
14346 int
14347 main ()
14348 {
14349 int testvar;
14350   ;
14351   return 0;
14352 }
14353 _ACEOF
14354 rm -f conftest.$ac_objext
14355 if { (eval echo "$as_me:14355: \"$ac_compile\"") >&5
14356   (eval $ac_compile) 2>&5
14357   ac_status=$?
14358   echo "$as_me:14358: \$? = $ac_status" >&5
14359   (exit $ac_status); } &&
14360          { ac_try='test -s conftest.$ac_objext'
14361   { (eval echo "$as_me:14361: \"$ac_try\"") >&5
14362   (eval $ac_try) 2>&5
14363   ac_status=$?
14364   echo "$as_me:14364: \$? = $ac_status" >&5
14365   (exit $ac_status); }; }; then
14366   samba_cv_HAVE_RPC_AUTH_ERROR_CONFLICT=no
14367 else
14368   echo "$as_me: failed program was:" >&5
14369 cat conftest.$ac_ext >&5
14370 samba_cv_HAVE_RPC_AUTH_ERROR_CONFLICT=yes
14371 fi
14372 rm -f conftest.$ac_objext conftest.$ac_ext
14373 fi
14374 echo "$as_me:14374: result: $samba_cv_HAVE_RPC_AUTH_ERROR_CONFLICT" >&5
14375 echo "${ECHO_T}$samba_cv_HAVE_RPC_AUTH_ERROR_CONFLICT" >&6
14376 if test x"$samba_cv_HAVE_RPC_AUTH_ERROR_CONFLICT" = x"yes"; then
14377     cat >>confdefs.h <<\EOF
14378 #define HAVE_RPC_AUTH_ERROR_CONFLICT 1
14379 EOF
14380
14381 fi
14382
14383 echo "$as_me:14383: checking for test routines" >&5
14384 echo $ECHO_N "checking for test routines... $ECHO_C" >&6
14385 if test "$cross_compiling" = yes; then
14386   { echo "$as_me:14386: WARNING: cannot run when cross-compiling" >&5
14387 echo "$as_me: WARNING: cannot run when cross-compiling" >&2;}
14388 else
14389   cat >conftest.$ac_ext <<_ACEOF
14390 #line 14390 "configure"
14391 #include "confdefs.h"
14392 #include "${srcdir-.}/tests/trivial.c"
14393 _ACEOF
14394 rm -f conftest$ac_exeext
14395 if { (eval echo "$as_me:14395: \"$ac_link\"") >&5
14396   (eval $ac_link) 2>&5
14397   ac_status=$?
14398   echo "$as_me:14398: \$? = $ac_status" >&5
14399   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14400   { (eval echo "$as_me:14400: \"$ac_try\"") >&5
14401   (eval $ac_try) 2>&5
14402   ac_status=$?
14403   echo "$as_me:14403: \$? = $ac_status" >&5
14404   (exit $ac_status); }; }; then
14405   echo "$as_me:14405: result: yes" >&5
14406 echo "${ECHO_T}yes" >&6
14407 else
14408   echo "$as_me: program exited with status $ac_status" >&5
14409 echo "$as_me: failed program was:" >&5
14410 cat conftest.$ac_ext >&5
14411 { { echo "$as_me:14411: error: cant find test code. Aborting config" >&5
14412 echo "$as_me: error: cant find test code. Aborting config" >&2;}
14413    { (exit 1); exit 1; }; }
14414 fi
14415 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14416 fi
14417
14418 echo "$as_me:14418: checking for ftruncate extend" >&5
14419 echo $ECHO_N "checking for ftruncate extend... $ECHO_C" >&6
14420 if test "${samba_cv_HAVE_FTRUNCATE_EXTEND+set}" = set; then
14421   echo $ECHO_N "(cached) $ECHO_C" >&6
14422 else
14423
14424 if test "$cross_compiling" = yes; then
14425   samba_cv_HAVE_FTRUNCATE_EXTEND=cross
14426 else
14427   cat >conftest.$ac_ext <<_ACEOF
14428 #line 14428 "configure"
14429 #include "confdefs.h"
14430 #include "${srcdir-.}/tests/ftruncate.c"
14431 _ACEOF
14432 rm -f conftest$ac_exeext
14433 if { (eval echo "$as_me:14433: \"$ac_link\"") >&5
14434   (eval $ac_link) 2>&5
14435   ac_status=$?
14436   echo "$as_me:14436: \$? = $ac_status" >&5
14437   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14438   { (eval echo "$as_me:14438: \"$ac_try\"") >&5
14439   (eval $ac_try) 2>&5
14440   ac_status=$?
14441   echo "$as_me:14441: \$? = $ac_status" >&5
14442   (exit $ac_status); }; }; then
14443   samba_cv_HAVE_FTRUNCATE_EXTEND=yes
14444 else
14445   echo "$as_me: program exited with status $ac_status" >&5
14446 echo "$as_me: failed program was:" >&5
14447 cat conftest.$ac_ext >&5
14448 samba_cv_HAVE_FTRUNCATE_EXTEND=no
14449 fi
14450 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14451 fi
14452 fi
14453 echo "$as_me:14453: result: $samba_cv_HAVE_FTRUNCATE_EXTEND" >&5
14454 echo "${ECHO_T}$samba_cv_HAVE_FTRUNCATE_EXTEND" >&6
14455 if test x"$samba_cv_HAVE_FTRUNCATE_EXTEND" = x"yes"; then
14456     cat >>confdefs.h <<\EOF
14457 #define HAVE_FTRUNCATE_EXTEND 1
14458 EOF
14459
14460 fi
14461
14462 echo "$as_me:14462: checking for AF_LOCAL socket support" >&5
14463 echo $ECHO_N "checking for AF_LOCAL socket support... $ECHO_C" >&6
14464 if test "${samba_cv_HAVE_WORKING_AF_LOCAL+set}" = set; then
14465   echo $ECHO_N "(cached) $ECHO_C" >&6
14466 else
14467
14468 if test "$cross_compiling" = yes; then
14469   samba_cv_HAVE_WORKING_AF_LOCAL=cross
14470 else
14471   cat >conftest.$ac_ext <<_ACEOF
14472 #line 14472 "configure"
14473 #include "confdefs.h"
14474 #include "${srcdir-.}/tests/unixsock.c"
14475 _ACEOF
14476 rm -f conftest$ac_exeext
14477 if { (eval echo "$as_me:14477: \"$ac_link\"") >&5
14478   (eval $ac_link) 2>&5
14479   ac_status=$?
14480   echo "$as_me:14480: \$? = $ac_status" >&5
14481   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14482   { (eval echo "$as_me:14482: \"$ac_try\"") >&5
14483   (eval $ac_try) 2>&5
14484   ac_status=$?
14485   echo "$as_me:14485: \$? = $ac_status" >&5
14486   (exit $ac_status); }; }; then
14487   samba_cv_HAVE_WORKING_AF_LOCAL=yes
14488 else
14489   echo "$as_me: program exited with status $ac_status" >&5
14490 echo "$as_me: failed program was:" >&5
14491 cat conftest.$ac_ext >&5
14492 samba_cv_HAVE_WORKING_AF_LOCAL=no
14493 fi
14494 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14495 fi
14496 fi
14497 echo "$as_me:14497: result: $samba_cv_HAVE_WORKING_AF_LOCAL" >&5
14498 echo "${ECHO_T}$samba_cv_HAVE_WORKING_AF_LOCAL" >&6
14499 if test x"$samba_cv_HAVE_WORKING_AF_LOCAL" != xno
14500 then
14501
14502 cat >>confdefs.h <<\EOF
14503 #define HAVE_WORKING_AF_LOCAL 1
14504 EOF
14505
14506 fi
14507
14508 echo "$as_me:14508: checking for broken getgroups" >&5
14509 echo $ECHO_N "checking for broken getgroups... $ECHO_C" >&6
14510 if test "${samba_cv_HAVE_BROKEN_GETGROUPS+set}" = set; then
14511   echo $ECHO_N "(cached) $ECHO_C" >&6
14512 else
14513
14514 if test "$cross_compiling" = yes; then
14515   samba_cv_HAVE_BROKEN_GETGROUPS=cross
14516 else
14517   cat >conftest.$ac_ext <<_ACEOF
14518 #line 14518 "configure"
14519 #include "confdefs.h"
14520 #include "${srcdir-.}/tests/getgroups.c"
14521 _ACEOF
14522 rm -f conftest$ac_exeext
14523 if { (eval echo "$as_me:14523: \"$ac_link\"") >&5
14524   (eval $ac_link) 2>&5
14525   ac_status=$?
14526   echo "$as_me:14526: \$? = $ac_status" >&5
14527   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14528   { (eval echo "$as_me:14528: \"$ac_try\"") >&5
14529   (eval $ac_try) 2>&5
14530   ac_status=$?
14531   echo "$as_me:14531: \$? = $ac_status" >&5
14532   (exit $ac_status); }; }; then
14533   samba_cv_HAVE_BROKEN_GETGROUPS=yes
14534 else
14535   echo "$as_me: program exited with status $ac_status" >&5
14536 echo "$as_me: failed program was:" >&5
14537 cat conftest.$ac_ext >&5
14538 samba_cv_HAVE_BROKEN_GETGROUPS=no
14539 fi
14540 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14541 fi
14542 fi
14543 echo "$as_me:14543: result: $samba_cv_HAVE_BROKEN_GETGROUPS" >&5
14544 echo "${ECHO_T}$samba_cv_HAVE_BROKEN_GETGROUPS" >&6
14545 if test x"$samba_cv_HAVE_BROKEN_GETGROUPS" = x"yes"; then
14546     cat >>confdefs.h <<\EOF
14547 #define HAVE_BROKEN_GETGROUPS 1
14548 EOF
14549
14550 fi
14551
14552 echo "$as_me:14552: checking whether getpass should be replaced" >&5
14553 echo $ECHO_N "checking whether getpass should be replaced... $ECHO_C" >&6
14554 if test "${samba_cv_REPLACE_GETPASS+set}" = set; then
14555   echo $ECHO_N "(cached) $ECHO_C" >&6
14556 else
14557
14558 SAVE_CPPFLAGS="$CPPFLAGS"
14559 CPPFLAGS="$CPPFLAGS -I${srcdir-.}/ -I${srcdir-.}/include -I${srcdir-.}/ubiqx -I${srcdir-.}/smbwrapper"
14560 cat >conftest.$ac_ext <<_ACEOF
14561 #line 14561 "configure"
14562 #include "confdefs.h"
14563
14564 #define REPLACE_GETPASS 1
14565 #define NO_CONFIG_H 1
14566 #define main dont_declare_main
14567 #include "${srcdir-.}/lib/getsmbpass.c"
14568 #undef main
14569
14570 int
14571 main ()
14572 {
14573
14574   ;
14575   return 0;
14576 }
14577 _ACEOF
14578 rm -f conftest.$ac_objext
14579 if { (eval echo "$as_me:14579: \"$ac_compile\"") >&5
14580   (eval $ac_compile) 2>&5
14581   ac_status=$?
14582   echo "$as_me:14582: \$? = $ac_status" >&5
14583   (exit $ac_status); } &&
14584          { ac_try='test -s conftest.$ac_objext'
14585   { (eval echo "$as_me:14585: \"$ac_try\"") >&5
14586   (eval $ac_try) 2>&5
14587   ac_status=$?
14588   echo "$as_me:14588: \$? = $ac_status" >&5
14589   (exit $ac_status); }; }; then
14590   samba_cv_REPLACE_GETPASS=yes
14591 else
14592   echo "$as_me: failed program was:" >&5
14593 cat conftest.$ac_ext >&5
14594 samba_cv_REPLACE_GETPASS=no
14595 fi
14596 rm -f conftest.$ac_objext conftest.$ac_ext
14597 CPPFLAGS="$SAVE_CPPFLAGS"
14598
14599 fi
14600 echo "$as_me:14600: result: $samba_cv_REPLACE_GETPASS" >&5
14601 echo "${ECHO_T}$samba_cv_REPLACE_GETPASS" >&6
14602 if test x"$samba_cv_REPLACE_GETPASS" = x"yes"; then
14603         cat >>confdefs.h <<\EOF
14604 #define REPLACE_GETPASS 1
14605 EOF
14606
14607 fi
14608
14609 echo "$as_me:14609: checking for broken inet_ntoa" >&5
14610 echo $ECHO_N "checking for broken inet_ntoa... $ECHO_C" >&6
14611 if test "${samba_cv_REPLACE_INET_NTOA+set}" = set; then
14612   echo $ECHO_N "(cached) $ECHO_C" >&6
14613 else
14614
14615 if test "$cross_compiling" = yes; then
14616   samba_cv_REPLACE_INET_NTOA=cross
14617 else
14618   cat >conftest.$ac_ext <<_ACEOF
14619 #line 14619 "configure"
14620 #include "confdefs.h"
14621
14622 #include <stdio.h>
14623 #include <sys/types.h>
14624 #include <netinet/in.h>
14625 #ifdef HAVE_ARPA_INET_H
14626 #include <arpa/inet.h>
14627 #endif
14628 main() { struct in_addr ip; ip.s_addr = 0x12345678;
14629 if (strcmp(inet_ntoa(ip),"18.52.86.120") &&
14630     strcmp(inet_ntoa(ip),"120.86.52.18")) { exit(0); }
14631 exit(1);}
14632 _ACEOF
14633 rm -f conftest$ac_exeext
14634 if { (eval echo "$as_me:14634: \"$ac_link\"") >&5
14635   (eval $ac_link) 2>&5
14636   ac_status=$?
14637   echo "$as_me:14637: \$? = $ac_status" >&5
14638   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14639   { (eval echo "$as_me:14639: \"$ac_try\"") >&5
14640   (eval $ac_try) 2>&5
14641   ac_status=$?
14642   echo "$as_me:14642: \$? = $ac_status" >&5
14643   (exit $ac_status); }; }; then
14644   samba_cv_REPLACE_INET_NTOA=yes
14645 else
14646   echo "$as_me: program exited with status $ac_status" >&5
14647 echo "$as_me: failed program was:" >&5
14648 cat conftest.$ac_ext >&5
14649 samba_cv_REPLACE_INET_NTOA=no
14650 fi
14651 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14652 fi
14653 fi
14654 echo "$as_me:14654: result: $samba_cv_REPLACE_INET_NTOA" >&5
14655 echo "${ECHO_T}$samba_cv_REPLACE_INET_NTOA" >&6
14656 if test x"$samba_cv_REPLACE_INET_NTOA" = x"yes"; then
14657     cat >>confdefs.h <<\EOF
14658 #define REPLACE_INET_NTOA 1
14659 EOF
14660
14661 fi
14662
14663 echo "$as_me:14663: checking for secure mkstemp" >&5
14664 echo $ECHO_N "checking for secure mkstemp... $ECHO_C" >&6
14665 if test "${samba_cv_HAVE_SECURE_MKSTEMP+set}" = set; then
14666   echo $ECHO_N "(cached) $ECHO_C" >&6
14667 else
14668
14669 if test "$cross_compiling" = yes; then
14670   samba_cv_HAVE_SECURE_MKSTEMP=cross
14671 else
14672   cat >conftest.$ac_ext <<_ACEOF
14673 #line 14673 "configure"
14674 #include "confdefs.h"
14675 #include <stdlib.h>
14676 #include <sys/types.h>
14677 #include <sys/stat.h>
14678 #include <unistd.h>
14679 main() {
14680   struct stat st;
14681   char tpl[20]="/tmp/test.XXXXXX";
14682   int fd = mkstemp(tpl);
14683   if (fd == -1) exit(1);
14684   unlink(tpl);
14685   if (fstat(fd, &st) != 0) exit(1);
14686   if ((st.st_mode & 0777) != 0600) exit(1);
14687   exit(0);
14688 }
14689 _ACEOF
14690 rm -f conftest$ac_exeext
14691 if { (eval echo "$as_me:14691: \"$ac_link\"") >&5
14692   (eval $ac_link) 2>&5
14693   ac_status=$?
14694   echo "$as_me:14694: \$? = $ac_status" >&5
14695   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14696   { (eval echo "$as_me:14696: \"$ac_try\"") >&5
14697   (eval $ac_try) 2>&5
14698   ac_status=$?
14699   echo "$as_me:14699: \$? = $ac_status" >&5
14700   (exit $ac_status); }; }; then
14701   samba_cv_HAVE_SECURE_MKSTEMP=yes
14702 else
14703   echo "$as_me: program exited with status $ac_status" >&5
14704 echo "$as_me: failed program was:" >&5
14705 cat conftest.$ac_ext >&5
14706 samba_cv_HAVE_SECURE_MKSTEMP=no
14707 fi
14708 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14709 fi
14710 fi
14711 echo "$as_me:14711: result: $samba_cv_HAVE_SECURE_MKSTEMP" >&5
14712 echo "${ECHO_T}$samba_cv_HAVE_SECURE_MKSTEMP" >&6
14713 if test x"$samba_cv_HAVE_SECURE_MKSTEMP" = x"yes"; then
14714     cat >>confdefs.h <<\EOF
14715 #define HAVE_SECURE_MKSTEMP 1
14716 EOF
14717
14718 fi
14719
14720 echo "$as_me:14720: checking for sysconf(_SC_NGROUPS_MAX)" >&5
14721 echo $ECHO_N "checking for sysconf(_SC_NGROUPS_MAX)... $ECHO_C" >&6
14722 if test "${samba_cv_SYSCONF_SC_NGROUPS_MAX+set}" = set; then
14723   echo $ECHO_N "(cached) $ECHO_C" >&6
14724 else
14725
14726 if test "$cross_compiling" = yes; then
14727   samba_cv_SYSCONF_SC_NGROUPS_MAX=cross
14728 else
14729   cat >conftest.$ac_ext <<_ACEOF
14730 #line 14730 "configure"
14731 #include "confdefs.h"
14732 #include <unistd.h>
14733 main() { exit(sysconf(_SC_NGROUPS_MAX) == -1 ? 1 : 0); }
14734 _ACEOF
14735 rm -f conftest$ac_exeext
14736 if { (eval echo "$as_me:14736: \"$ac_link\"") >&5
14737   (eval $ac_link) 2>&5
14738   ac_status=$?
14739   echo "$as_me:14739: \$? = $ac_status" >&5
14740   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14741   { (eval echo "$as_me:14741: \"$ac_try\"") >&5
14742   (eval $ac_try) 2>&5
14743   ac_status=$?
14744   echo "$as_me:14744: \$? = $ac_status" >&5
14745   (exit $ac_status); }; }; then
14746   samba_cv_SYSCONF_SC_NGROUPS_MAX=yes
14747 else
14748   echo "$as_me: program exited with status $ac_status" >&5
14749 echo "$as_me: failed program was:" >&5
14750 cat conftest.$ac_ext >&5
14751 samba_cv_SYSCONF_SC_NGROUPS_MAX=no
14752 fi
14753 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14754 fi
14755 fi
14756 echo "$as_me:14756: result: $samba_cv_SYSCONF_SC_NGROUPS_MAX" >&5
14757 echo "${ECHO_T}$samba_cv_SYSCONF_SC_NGROUPS_MAX" >&6
14758 if test x"$samba_cv_SYSCONF_SC_NGROUPS_MAX" = x"yes"; then
14759     cat >>confdefs.h <<\EOF
14760 #define SYSCONF_SC_NGROUPS_MAX 1
14761 EOF
14762
14763 fi
14764
14765 echo "$as_me:14765: checking for root" >&5
14766 echo $ECHO_N "checking for root... $ECHO_C" >&6
14767 if test "${samba_cv_HAVE_ROOT+set}" = set; then
14768   echo $ECHO_N "(cached) $ECHO_C" >&6
14769 else
14770
14771 if test "$cross_compiling" = yes; then
14772   samba_cv_HAVE_ROOT=cross
14773 else
14774   cat >conftest.$ac_ext <<_ACEOF
14775 #line 14775 "configure"
14776 #include "confdefs.h"
14777 main() { exit(getuid() != 0); }
14778 _ACEOF
14779 rm -f conftest$ac_exeext
14780 if { (eval echo "$as_me:14780: \"$ac_link\"") >&5
14781   (eval $ac_link) 2>&5
14782   ac_status=$?
14783   echo "$as_me:14783: \$? = $ac_status" >&5
14784   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14785   { (eval echo "$as_me:14785: \"$ac_try\"") >&5
14786   (eval $ac_try) 2>&5
14787   ac_status=$?
14788   echo "$as_me:14788: \$? = $ac_status" >&5
14789   (exit $ac_status); }; }; then
14790   samba_cv_HAVE_ROOT=yes
14791 else
14792   echo "$as_me: program exited with status $ac_status" >&5
14793 echo "$as_me: failed program was:" >&5
14794 cat conftest.$ac_ext >&5
14795 samba_cv_HAVE_ROOT=no
14796 fi
14797 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14798 fi
14799 fi
14800 echo "$as_me:14800: result: $samba_cv_HAVE_ROOT" >&5
14801 echo "${ECHO_T}$samba_cv_HAVE_ROOT" >&6
14802 if test x"$samba_cv_HAVE_ROOT" = x"yes"; then
14803     cat >>confdefs.h <<\EOF
14804 #define HAVE_ROOT 1
14805 EOF
14806
14807 else
14808     { echo "$as_me:14808: WARNING: running as non-root will disable some tests" >&5
14809 echo "$as_me: WARNING: running as non-root will disable some tests" >&2;}
14810 fi
14811
14812 ##################
14813 # look for a method of finding the list of network interfaces
14814 iface=no;
14815 echo "$as_me:14815: checking for iface AIX" >&5
14816 echo $ECHO_N "checking for iface AIX... $ECHO_C" >&6
14817 if test "${samba_cv_HAVE_IFACE_AIX+set}" = set; then
14818   echo $ECHO_N "(cached) $ECHO_C" >&6
14819 else
14820
14821 if test "$cross_compiling" = yes; then
14822   samba_cv_HAVE_IFACE_AIX=cross
14823 else
14824   cat >conftest.$ac_ext <<_ACEOF
14825 #line 14825 "configure"
14826 #include "confdefs.h"
14827
14828 #define HAVE_IFACE_AIX 1
14829 #define AUTOCONF_TEST 1
14830 #include "confdefs.h"
14831 #include "${srcdir-.}/lib/interfaces.c"
14832 _ACEOF
14833 rm -f conftest$ac_exeext
14834 if { (eval echo "$as_me:14834: \"$ac_link\"") >&5
14835   (eval $ac_link) 2>&5
14836   ac_status=$?
14837   echo "$as_me:14837: \$? = $ac_status" >&5
14838   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14839   { (eval echo "$as_me:14839: \"$ac_try\"") >&5
14840   (eval $ac_try) 2>&5
14841   ac_status=$?
14842   echo "$as_me:14842: \$? = $ac_status" >&5
14843   (exit $ac_status); }; }; then
14844   samba_cv_HAVE_IFACE_AIX=yes
14845 else
14846   echo "$as_me: program exited with status $ac_status" >&5
14847 echo "$as_me: failed program was:" >&5
14848 cat conftest.$ac_ext >&5
14849 samba_cv_HAVE_IFACE_AIX=no
14850 fi
14851 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14852 fi
14853 fi
14854 echo "$as_me:14854: result: $samba_cv_HAVE_IFACE_AIX" >&5
14855 echo "${ECHO_T}$samba_cv_HAVE_IFACE_AIX" >&6
14856 if test x"$samba_cv_HAVE_IFACE_AIX" = x"yes"; then
14857     iface=yes;cat >>confdefs.h <<\EOF
14858 #define HAVE_IFACE_AIX 1
14859 EOF
14860
14861 fi
14862
14863 if test $iface = no; then
14864 echo "$as_me:14864: checking for iface ifconf" >&5
14865 echo $ECHO_N "checking for iface ifconf... $ECHO_C" >&6
14866 if test "${samba_cv_HAVE_IFACE_IFCONF+set}" = set; then
14867   echo $ECHO_N "(cached) $ECHO_C" >&6
14868 else
14869
14870 if test "$cross_compiling" = yes; then
14871   samba_cv_HAVE_IFACE_IFCONF=cross
14872 else
14873   cat >conftest.$ac_ext <<_ACEOF
14874 #line 14874 "configure"
14875 #include "confdefs.h"
14876
14877 #define HAVE_IFACE_IFCONF 1
14878 #define AUTOCONF_TEST 1
14879 #include "confdefs.h"
14880 #include "${srcdir-.}/lib/interfaces.c"
14881 _ACEOF
14882 rm -f conftest$ac_exeext
14883 if { (eval echo "$as_me:14883: \"$ac_link\"") >&5
14884   (eval $ac_link) 2>&5
14885   ac_status=$?
14886   echo "$as_me:14886: \$? = $ac_status" >&5
14887   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14888   { (eval echo "$as_me:14888: \"$ac_try\"") >&5
14889   (eval $ac_try) 2>&5
14890   ac_status=$?
14891   echo "$as_me:14891: \$? = $ac_status" >&5
14892   (exit $ac_status); }; }; then
14893   samba_cv_HAVE_IFACE_IFCONF=yes
14894 else
14895   echo "$as_me: program exited with status $ac_status" >&5
14896 echo "$as_me: failed program was:" >&5
14897 cat conftest.$ac_ext >&5
14898 samba_cv_HAVE_IFACE_IFCONF=no
14899 fi
14900 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14901 fi
14902 fi
14903 echo "$as_me:14903: result: $samba_cv_HAVE_IFACE_IFCONF" >&5
14904 echo "${ECHO_T}$samba_cv_HAVE_IFACE_IFCONF" >&6
14905 if test x"$samba_cv_HAVE_IFACE_IFCONF" = x"yes"; then
14906     iface=yes;cat >>confdefs.h <<\EOF
14907 #define HAVE_IFACE_IFCONF 1
14908 EOF
14909
14910 fi
14911 fi
14912
14913 if test $iface = no; then
14914 echo "$as_me:14914: checking for iface ifreq" >&5
14915 echo $ECHO_N "checking for iface ifreq... $ECHO_C" >&6
14916 if test "${samba_cv_HAVE_IFACE_IFREQ+set}" = set; then
14917   echo $ECHO_N "(cached) $ECHO_C" >&6
14918 else
14919
14920 if test "$cross_compiling" = yes; then
14921   samba_cv_HAVE_IFACE_IFREQ=cross
14922 else
14923   cat >conftest.$ac_ext <<_ACEOF
14924 #line 14924 "configure"
14925 #include "confdefs.h"
14926
14927 #define HAVE_IFACE_IFREQ 1
14928 #define AUTOCONF_TEST 1
14929 #include "confdefs.h"
14930 #include "${srcdir-.}/lib/interfaces.c"
14931 _ACEOF
14932 rm -f conftest$ac_exeext
14933 if { (eval echo "$as_me:14933: \"$ac_link\"") >&5
14934   (eval $ac_link) 2>&5
14935   ac_status=$?
14936   echo "$as_me:14936: \$? = $ac_status" >&5
14937   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14938   { (eval echo "$as_me:14938: \"$ac_try\"") >&5
14939   (eval $ac_try) 2>&5
14940   ac_status=$?
14941   echo "$as_me:14941: \$? = $ac_status" >&5
14942   (exit $ac_status); }; }; then
14943   samba_cv_HAVE_IFACE_IFREQ=yes
14944 else
14945   echo "$as_me: program exited with status $ac_status" >&5
14946 echo "$as_me: failed program was:" >&5
14947 cat conftest.$ac_ext >&5
14948 samba_cv_HAVE_IFACE_IFREQ=no
14949 fi
14950 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14951 fi
14952 fi
14953 echo "$as_me:14953: result: $samba_cv_HAVE_IFACE_IFREQ" >&5
14954 echo "${ECHO_T}$samba_cv_HAVE_IFACE_IFREQ" >&6
14955 if test x"$samba_cv_HAVE_IFACE_IFREQ" = x"yes"; then
14956     iface=yes;cat >>confdefs.h <<\EOF
14957 #define HAVE_IFACE_IFREQ 1
14958 EOF
14959
14960 fi
14961 fi
14962
14963 ################################################
14964 # look for a method of setting the effective uid
14965 seteuid=no;
14966 if test $seteuid = no; then
14967 echo "$as_me:14967: checking for setresuid" >&5
14968 echo $ECHO_N "checking for setresuid... $ECHO_C" >&6
14969 if test "${samba_cv_USE_SETRESUID+set}" = set; then
14970   echo $ECHO_N "(cached) $ECHO_C" >&6
14971 else
14972
14973 if test "$cross_compiling" = yes; then
14974   samba_cv_USE_SETRESUID=cross
14975 else
14976   cat >conftest.$ac_ext <<_ACEOF
14977 #line 14977 "configure"
14978 #include "confdefs.h"
14979
14980 #define AUTOCONF_TEST 1
14981 #define USE_SETRESUID 1
14982 #include "confdefs.h"
14983 #include "${srcdir-.}/lib/util_sec.c"
14984 _ACEOF
14985 rm -f conftest$ac_exeext
14986 if { (eval echo "$as_me:14986: \"$ac_link\"") >&5
14987   (eval $ac_link) 2>&5
14988   ac_status=$?
14989   echo "$as_me:14989: \$? = $ac_status" >&5
14990   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14991   { (eval echo "$as_me:14991: \"$ac_try\"") >&5
14992   (eval $ac_try) 2>&5
14993   ac_status=$?
14994   echo "$as_me:14994: \$? = $ac_status" >&5
14995   (exit $ac_status); }; }; then
14996   samba_cv_USE_SETRESUID=yes
14997 else
14998   echo "$as_me: program exited with status $ac_status" >&5
14999 echo "$as_me: failed program was:" >&5
15000 cat conftest.$ac_ext >&5
15001 samba_cv_USE_SETRESUID=no
15002 fi
15003 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15004 fi
15005 fi
15006 echo "$as_me:15006: result: $samba_cv_USE_SETRESUID" >&5
15007 echo "${ECHO_T}$samba_cv_USE_SETRESUID" >&6
15008 if test x"$samba_cv_USE_SETRESUID" = x"yes"; then
15009     seteuid=yes;cat >>confdefs.h <<\EOF
15010 #define USE_SETRESUID 1
15011 EOF
15012
15013 fi
15014 fi
15015
15016 if test $seteuid = no; then
15017 echo "$as_me:15017: checking for setreuid" >&5
15018 echo $ECHO_N "checking for setreuid... $ECHO_C" >&6
15019 if test "${samba_cv_USE_SETREUID+set}" = set; then
15020   echo $ECHO_N "(cached) $ECHO_C" >&6
15021 else
15022
15023 if test "$cross_compiling" = yes; then
15024   samba_cv_USE_SETREUID=cross
15025 else
15026   cat >conftest.$ac_ext <<_ACEOF
15027 #line 15027 "configure"
15028 #include "confdefs.h"
15029
15030 #define AUTOCONF_TEST 1
15031 #define USE_SETREUID 1
15032 #include "confdefs.h"
15033 #include "${srcdir-.}/lib/util_sec.c"
15034 _ACEOF
15035 rm -f conftest$ac_exeext
15036 if { (eval echo "$as_me:15036: \"$ac_link\"") >&5
15037   (eval $ac_link) 2>&5
15038   ac_status=$?
15039   echo "$as_me:15039: \$? = $ac_status" >&5
15040   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15041   { (eval echo "$as_me:15041: \"$ac_try\"") >&5
15042   (eval $ac_try) 2>&5
15043   ac_status=$?
15044   echo "$as_me:15044: \$? = $ac_status" >&5
15045   (exit $ac_status); }; }; then
15046   samba_cv_USE_SETREUID=yes
15047 else
15048   echo "$as_me: program exited with status $ac_status" >&5
15049 echo "$as_me: failed program was:" >&5
15050 cat conftest.$ac_ext >&5
15051 samba_cv_USE_SETREUID=no
15052 fi
15053 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15054 fi
15055 fi
15056 echo "$as_me:15056: result: $samba_cv_USE_SETREUID" >&5
15057 echo "${ECHO_T}$samba_cv_USE_SETREUID" >&6
15058 if test x"$samba_cv_USE_SETREUID" = x"yes"; then
15059     seteuid=yes;cat >>confdefs.h <<\EOF
15060 #define USE_SETREUID 1
15061 EOF
15062
15063 fi
15064 fi
15065
15066 if test $seteuid = no; then
15067 echo "$as_me:15067: checking for seteuid" >&5
15068 echo $ECHO_N "checking for seteuid... $ECHO_C" >&6
15069 if test "${samba_cv_USE_SETEUID+set}" = set; then
15070   echo $ECHO_N "(cached) $ECHO_C" >&6
15071 else
15072
15073 if test "$cross_compiling" = yes; then
15074   samba_cv_USE_SETEUID=cross
15075 else
15076   cat >conftest.$ac_ext <<_ACEOF
15077 #line 15077 "configure"
15078 #include "confdefs.h"
15079
15080 #define AUTOCONF_TEST 1
15081 #define USE_SETEUID 1
15082 #include "confdefs.h"
15083 #include "${srcdir-.}/lib/util_sec.c"
15084 _ACEOF
15085 rm -f conftest$ac_exeext
15086 if { (eval echo "$as_me:15086: \"$ac_link\"") >&5
15087   (eval $ac_link) 2>&5
15088   ac_status=$?
15089   echo "$as_me:15089: \$? = $ac_status" >&5
15090   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15091   { (eval echo "$as_me:15091: \"$ac_try\"") >&5
15092   (eval $ac_try) 2>&5
15093   ac_status=$?
15094   echo "$as_me:15094: \$? = $ac_status" >&5
15095   (exit $ac_status); }; }; then
15096   samba_cv_USE_SETEUID=yes
15097 else
15098   echo "$as_me: program exited with status $ac_status" >&5
15099 echo "$as_me: failed program was:" >&5
15100 cat conftest.$ac_ext >&5
15101 samba_cv_USE_SETEUID=no
15102 fi
15103 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15104 fi
15105 fi
15106 echo "$as_me:15106: result: $samba_cv_USE_SETEUID" >&5
15107 echo "${ECHO_T}$samba_cv_USE_SETEUID" >&6
15108 if test x"$samba_cv_USE_SETEUID" = x"yes"; then
15109     seteuid=yes;cat >>confdefs.h <<\EOF
15110 #define USE_SETEUID 1
15111 EOF
15112
15113 fi
15114 fi
15115
15116 if test $seteuid = no; then
15117 echo "$as_me:15117: checking for setuidx" >&5
15118 echo $ECHO_N "checking for setuidx... $ECHO_C" >&6
15119 if test "${samba_cv_USE_SETUIDX+set}" = set; then
15120   echo $ECHO_N "(cached) $ECHO_C" >&6
15121 else
15122
15123 if test "$cross_compiling" = yes; then
15124   samba_cv_USE_SETUIDX=cross
15125 else
15126   cat >conftest.$ac_ext <<_ACEOF
15127 #line 15127 "configure"
15128 #include "confdefs.h"
15129
15130 #define AUTOCONF_TEST 1
15131 #define USE_SETUIDX 1
15132 #include "confdefs.h"
15133 #include "${srcdir-.}/lib/util_sec.c"
15134 _ACEOF
15135 rm -f conftest$ac_exeext
15136 if { (eval echo "$as_me:15136: \"$ac_link\"") >&5
15137   (eval $ac_link) 2>&5
15138   ac_status=$?
15139   echo "$as_me:15139: \$? = $ac_status" >&5
15140   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15141   { (eval echo "$as_me:15141: \"$ac_try\"") >&5
15142   (eval $ac_try) 2>&5
15143   ac_status=$?
15144   echo "$as_me:15144: \$? = $ac_status" >&5
15145   (exit $ac_status); }; }; then
15146   samba_cv_USE_SETUIDX=yes
15147 else
15148   echo "$as_me: program exited with status $ac_status" >&5
15149 echo "$as_me: failed program was:" >&5
15150 cat conftest.$ac_ext >&5
15151 samba_cv_USE_SETUIDX=no
15152 fi
15153 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15154 fi
15155 fi
15156 echo "$as_me:15156: result: $samba_cv_USE_SETUIDX" >&5
15157 echo "${ECHO_T}$samba_cv_USE_SETUIDX" >&6
15158 if test x"$samba_cv_USE_SETUIDX" = x"yes"; then
15159     seteuid=yes;cat >>confdefs.h <<\EOF
15160 #define USE_SETUIDX 1
15161 EOF
15162
15163 fi
15164 fi
15165
15166 echo "$as_me:15166: checking for working mmap" >&5
15167 echo $ECHO_N "checking for working mmap... $ECHO_C" >&6
15168 if test "${samba_cv_HAVE_MMAP+set}" = set; then
15169   echo $ECHO_N "(cached) $ECHO_C" >&6
15170 else
15171
15172 if test "$cross_compiling" = yes; then
15173   samba_cv_HAVE_MMAP=cross
15174 else
15175   cat >conftest.$ac_ext <<_ACEOF
15176 #line 15176 "configure"
15177 #include "confdefs.h"
15178 #include "${srcdir-.}/tests/shared_mmap.c"
15179 _ACEOF
15180 rm -f conftest$ac_exeext
15181 if { (eval echo "$as_me:15181: \"$ac_link\"") >&5
15182   (eval $ac_link) 2>&5
15183   ac_status=$?
15184   echo "$as_me:15184: \$? = $ac_status" >&5
15185   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15186   { (eval echo "$as_me:15186: \"$ac_try\"") >&5
15187   (eval $ac_try) 2>&5
15188   ac_status=$?
15189   echo "$as_me:15189: \$? = $ac_status" >&5
15190   (exit $ac_status); }; }; then
15191   samba_cv_HAVE_MMAP=yes
15192 else
15193   echo "$as_me: program exited with status $ac_status" >&5
15194 echo "$as_me: failed program was:" >&5
15195 cat conftest.$ac_ext >&5
15196 samba_cv_HAVE_MMAP=no
15197 fi
15198 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15199 fi
15200 fi
15201 echo "$as_me:15201: result: $samba_cv_HAVE_MMAP" >&5
15202 echo "${ECHO_T}$samba_cv_HAVE_MMAP" >&6
15203 if test x"$samba_cv_HAVE_MMAP" = x"yes"; then
15204     cat >>confdefs.h <<\EOF
15205 #define HAVE_MMAP 1
15206 EOF
15207
15208 fi
15209
15210 echo "$as_me:15210: checking for ftruncate needs root" >&5
15211 echo $ECHO_N "checking for ftruncate needs root... $ECHO_C" >&6
15212 if test "${samba_cv_FTRUNCATE_NEEDS_ROOT+set}" = set; then
15213   echo $ECHO_N "(cached) $ECHO_C" >&6
15214 else
15215
15216 if test "$cross_compiling" = yes; then
15217   samba_cv_FTRUNCATE_NEEDS_ROOT=cross
15218 else
15219   cat >conftest.$ac_ext <<_ACEOF
15220 #line 15220 "configure"
15221 #include "confdefs.h"
15222 #include "${srcdir-.}/tests/ftruncroot.c"
15223 _ACEOF
15224 rm -f conftest$ac_exeext
15225 if { (eval echo "$as_me:15225: \"$ac_link\"") >&5
15226   (eval $ac_link) 2>&5
15227   ac_status=$?
15228   echo "$as_me:15228: \$? = $ac_status" >&5
15229   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15230   { (eval echo "$as_me:15230: \"$ac_try\"") >&5
15231   (eval $ac_try) 2>&5
15232   ac_status=$?
15233   echo "$as_me:15233: \$? = $ac_status" >&5
15234   (exit $ac_status); }; }; then
15235   samba_cv_FTRUNCATE_NEEDS_ROOT=yes
15236 else
15237   echo "$as_me: program exited with status $ac_status" >&5
15238 echo "$as_me: failed program was:" >&5
15239 cat conftest.$ac_ext >&5
15240 samba_cv_FTRUNCATE_NEEDS_ROOT=no
15241 fi
15242 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15243 fi
15244 fi
15245 echo "$as_me:15245: result: $samba_cv_FTRUNCATE_NEEDS_ROOT" >&5
15246 echo "${ECHO_T}$samba_cv_FTRUNCATE_NEEDS_ROOT" >&6
15247 if test x"$samba_cv_FTRUNCATE_NEEDS_ROOT" = x"yes"; then
15248     cat >>confdefs.h <<\EOF
15249 #define FTRUNCATE_NEEDS_ROOT 1
15250 EOF
15251
15252 fi
15253
15254 echo "$as_me:15254: checking for fcntl locking" >&5
15255 echo $ECHO_N "checking for fcntl locking... $ECHO_C" >&6
15256 if test "${samba_cv_HAVE_FCNTL_LOCK+set}" = set; then
15257   echo $ECHO_N "(cached) $ECHO_C" >&6
15258 else
15259
15260 if test "$cross_compiling" = yes; then
15261   samba_cv_HAVE_FCNTL_LOCK=cross
15262 else
15263   cat >conftest.$ac_ext <<_ACEOF
15264 #line 15264 "configure"
15265 #include "confdefs.h"
15266 #include "${srcdir-.}/tests/fcntl_lock.c"
15267 _ACEOF
15268 rm -f conftest$ac_exeext
15269 if { (eval echo "$as_me:15269: \"$ac_link\"") >&5
15270   (eval $ac_link) 2>&5
15271   ac_status=$?
15272   echo "$as_me:15272: \$? = $ac_status" >&5
15273   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15274   { (eval echo "$as_me:15274: \"$ac_try\"") >&5
15275   (eval $ac_try) 2>&5
15276   ac_status=$?
15277   echo "$as_me:15277: \$? = $ac_status" >&5
15278   (exit $ac_status); }; }; then
15279   samba_cv_HAVE_FCNTL_LOCK=yes
15280 else
15281   echo "$as_me: program exited with status $ac_status" >&5
15282 echo "$as_me: failed program was:" >&5
15283 cat conftest.$ac_ext >&5
15284 samba_cv_HAVE_FCNTL_LOCK=no
15285 fi
15286 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15287 fi
15288 fi
15289 echo "$as_me:15289: result: $samba_cv_HAVE_FCNTL_LOCK" >&5
15290 echo "${ECHO_T}$samba_cv_HAVE_FCNTL_LOCK" >&6
15291 if test x"$samba_cv_HAVE_FCNTL_LOCK" = x"yes"; then
15292     cat >>confdefs.h <<\EOF
15293 #define HAVE_FCNTL_LOCK 1
15294 EOF
15295
15296 fi
15297
15298 echo "$as_me:15298: checking for broken (glibc2.1/x86) 64 bit fcntl locking" >&5
15299 echo $ECHO_N "checking for broken (glibc2.1/x86) 64 bit fcntl locking... $ECHO_C" >&6
15300 if test "${samba_cv_HAVE_BROKEN_FCNTL64_LOCKS+set}" = set; then
15301   echo $ECHO_N "(cached) $ECHO_C" >&6
15302 else
15303
15304 if test "$cross_compiling" = yes; then
15305   samba_cv_HAVE_BROKEN_FCNTL64_LOCKS=cross
15306 else
15307   cat >conftest.$ac_ext <<_ACEOF
15308 #line 15308 "configure"
15309 #include "confdefs.h"
15310 #include "${srcdir-.}/tests/fcntl_lock64.c"
15311 _ACEOF
15312 rm -f conftest$ac_exeext
15313 if { (eval echo "$as_me:15313: \"$ac_link\"") >&5
15314   (eval $ac_link) 2>&5
15315   ac_status=$?
15316   echo "$as_me:15316: \$? = $ac_status" >&5
15317   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15318   { (eval echo "$as_me:15318: \"$ac_try\"") >&5
15319   (eval $ac_try) 2>&5
15320   ac_status=$?
15321   echo "$as_me:15321: \$? = $ac_status" >&5
15322   (exit $ac_status); }; }; then
15323   samba_cv_HAVE_BROKEN_FCNTL64_LOCKS=yes
15324 else
15325   echo "$as_me: program exited with status $ac_status" >&5
15326 echo "$as_me: failed program was:" >&5
15327 cat conftest.$ac_ext >&5
15328 samba_cv_HAVE_BROKEN_FCNTL64_LOCKS=no
15329 fi
15330 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15331 fi
15332 fi
15333 echo "$as_me:15333: result: $samba_cv_HAVE_BROKEN_FCNTL64_LOCKS" >&5
15334 echo "${ECHO_T}$samba_cv_HAVE_BROKEN_FCNTL64_LOCKS" >&6
15335 if test x"$samba_cv_HAVE_BROKEN_FCNTL64_LOCKS" = x"yes"; then
15336     cat >>confdefs.h <<\EOF
15337 #define HAVE_BROKEN_FCNTL64_LOCKS 1
15338 EOF
15339
15340 else
15341
15342   echo "$as_me:15342: checking for 64 bit fcntl locking" >&5
15343 echo $ECHO_N "checking for 64 bit fcntl locking... $ECHO_C" >&6
15344 if test "${samba_cv_HAVE_STRUCT_FLOCK64+set}" = set; then
15345   echo $ECHO_N "(cached) $ECHO_C" >&6
15346 else
15347
15348   if test "$cross_compiling" = yes; then
15349   samba_cv_HAVE_STRUCT_FLOCK64=cross
15350 else
15351   cat >conftest.$ac_ext <<_ACEOF
15352 #line 15352 "configure"
15353 #include "confdefs.h"
15354
15355 #if defined(HAVE_UNISTD_H)
15356 #include <unistd.h>
15357 #endif
15358 #include <stdio.h>
15359 #include <stdlib.h>
15360
15361 #ifdef HAVE_FCNTL_H
15362 #include <fcntl.h>
15363 #endif
15364
15365 #ifdef HAVE_SYS_FCNTL_H
15366 #include <sys/fcntl.h>
15367 #endif
15368 main() { struct flock64 fl64;
15369 #if defined(F_SETLKW64) && defined(F_SETLK64) && defined(F_GETLK64)
15370 exit(0);
15371 #else
15372 exit(1);
15373 #endif
15374 }
15375 _ACEOF
15376 rm -f conftest$ac_exeext
15377 if { (eval echo "$as_me:15377: \"$ac_link\"") >&5
15378   (eval $ac_link) 2>&5
15379   ac_status=$?
15380   echo "$as_me:15380: \$? = $ac_status" >&5
15381   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15382   { (eval echo "$as_me:15382: \"$ac_try\"") >&5
15383   (eval $ac_try) 2>&5
15384   ac_status=$?
15385   echo "$as_me:15385: \$? = $ac_status" >&5
15386   (exit $ac_status); }; }; then
15387   samba_cv_HAVE_STRUCT_FLOCK64=yes
15388 else
15389   echo "$as_me: program exited with status $ac_status" >&5
15390 echo "$as_me: failed program was:" >&5
15391 cat conftest.$ac_ext >&5
15392 samba_cv_HAVE_STRUCT_FLOCK64=no
15393 fi
15394 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15395 fi
15396 fi
15397 echo "$as_me:15397: result: $samba_cv_HAVE_STRUCT_FLOCK64" >&5
15398 echo "${ECHO_T}$samba_cv_HAVE_STRUCT_FLOCK64" >&6
15399
15400   if test x"$samba_cv_HAVE_STRUCT_FLOCK64" = x"yes"; then
15401       cat >>confdefs.h <<\EOF
15402 #define HAVE_STRUCT_FLOCK64 1
15403 EOF
15404
15405   fi
15406 fi
15407
15408 case "$host_os" in
15409 *linux*)
15410 echo "$as_me:15410: checking for broken RedHat 7.2 system header files" >&5
15411 echo $ECHO_N "checking for broken RedHat 7.2 system header files... $ECHO_C" >&6
15412 if test "${samba_cv_BROKEN_REDHAT_7_SYSTEM_HEADERS+set}" = set; then
15413   echo $ECHO_N "(cached) $ECHO_C" >&6
15414 else
15415
15416 cat >conftest.$ac_ext <<_ACEOF
15417 #line 15417 "configure"
15418 #include "confdefs.h"
15419
15420 #ifdef HAVE_SYS_VFS_H
15421 #include <sys/vfs.h>
15422 #endif
15423 #ifdef HAVE_SYS_CAPABILITY_H
15424 #include <sys/capability.h>
15425 #endif
15426
15427 int
15428 main ()
15429 {
15430 int i;
15431   ;
15432   return 0;
15433 }
15434 _ACEOF
15435 rm -f conftest.$ac_objext
15436 if { (eval echo "$as_me:15436: \"$ac_compile\"") >&5
15437   (eval $ac_compile) 2>&5
15438   ac_status=$?
15439   echo "$as_me:15439: \$? = $ac_status" >&5
15440   (exit $ac_status); } &&
15441          { ac_try='test -s conftest.$ac_objext'
15442   { (eval echo "$as_me:15442: \"$ac_try\"") >&5
15443   (eval $ac_try) 2>&5
15444   ac_status=$?
15445   echo "$as_me:15445: \$? = $ac_status" >&5
15446   (exit $ac_status); }; }; then
15447   samba_cv_BROKEN_REDHAT_7_SYSTEM_HEADERS=no
15448 else
15449   echo "$as_me: failed program was:" >&5
15450 cat conftest.$ac_ext >&5
15451 samba_cv_BROKEN_REDHAT_7_SYSTEM_HEADERS=yes
15452 fi
15453 rm -f conftest.$ac_objext conftest.$ac_ext
15454 fi
15455 echo "$as_me:15455: result: $samba_cv_BROKEN_REDHAT_7_SYSTEM_HEADERS" >&5
15456 echo "${ECHO_T}$samba_cv_BROKEN_REDHAT_7_SYSTEM_HEADERS" >&6
15457 if test x"$samba_cv_BROKEN_REDHAT_7_SYSTEM_HEADERS" = x"yes"; then
15458    cat >>confdefs.h <<\EOF
15459 #define BROKEN_REDHAT_7_SYSTEM_HEADERS 1
15460 EOF
15461
15462 fi
15463 ;;
15464 esac
15465
15466 echo "$as_me:15466: checking for broken nisplus include files" >&5
15467 echo $ECHO_N "checking for broken nisplus include files... $ECHO_C" >&6
15468 if test "${samba_cv_BROKEN_NISPLUS_INCLUDE_FILES+set}" = set; then
15469   echo $ECHO_N "(cached) $ECHO_C" >&6
15470 else
15471
15472 cat >conftest.$ac_ext <<_ACEOF
15473 #line 15473 "configure"
15474 #include "confdefs.h"
15475 #include <sys/acl.h>
15476 #if defined(HAVE_RPCSVC_NIS_H)
15477 #include <rpcsvc/nis.h>
15478 #endif
15479 int
15480 main ()
15481 {
15482 int i;
15483   ;
15484   return 0;
15485 }
15486 _ACEOF
15487 rm -f conftest.$ac_objext
15488 if { (eval echo "$as_me:15488: \"$ac_compile\"") >&5
15489   (eval $ac_compile) 2>&5
15490   ac_status=$?
15491   echo "$as_me:15491: \$? = $ac_status" >&5
15492   (exit $ac_status); } &&
15493          { ac_try='test -s conftest.$ac_objext'
15494   { (eval echo "$as_me:15494: \"$ac_try\"") >&5
15495   (eval $ac_try) 2>&5
15496   ac_status=$?
15497   echo "$as_me:15497: \$? = $ac_status" >&5
15498   (exit $ac_status); }; }; then
15499   samba_cv_BROKEN_NISPLUS_INCLUDE_FILES=no
15500 else
15501   echo "$as_me: failed program was:" >&5
15502 cat conftest.$ac_ext >&5
15503 samba_cv_BROKEN_NISPLUS_INCLUDE_FILES=yes
15504 fi
15505 rm -f conftest.$ac_objext conftest.$ac_ext
15506 fi
15507 echo "$as_me:15507: result: $samba_cv_BROKEN_NISPLUS_INCLUDE_FILES" >&5
15508 echo "${ECHO_T}$samba_cv_BROKEN_NISPLUS_INCLUDE_FILES" >&6
15509 if test x"$samba_cv_BROKEN_NISPLUS_INCLUDE_FILES" = x"yes"; then
15510     cat >>confdefs.h <<\EOF
15511 #define BROKEN_NISPLUS_INCLUDE_FILES 1
15512 EOF
15513
15514 fi
15515
15516 #################################################
15517 # check for smbwrapper support
15518 echo "$as_me:15518: checking whether to use smbwrapper" >&5
15519 echo $ECHO_N "checking whether to use smbwrapper... $ECHO_C" >&6
15520
15521 # Check whether --with-smbwrapper or --without-smbwrapper was given.
15522 if test "${with_smbwrapper+set}" = set; then
15523   withval="$with_smbwrapper"
15524    case "$withval" in
15525   yes)
15526     echo "$as_me:15526: result: yes" >&5
15527 echo "${ECHO_T}yes" >&6
15528     cat >>confdefs.h <<\EOF
15529 #define WITH_SMBWRAPPER 1
15530 EOF
15531
15532         WRAP="bin/smbsh bin/smbwrapper.$SHLIBEXT"
15533
15534         if test x$ATTEMPT_WRAP32_BUILD = x; then
15535                 WRAP32=""
15536         else
15537                         WRAP32=bin/smbwrapper.32.$SHLIBEXT
15538         fi
15539
15540 # Conditions under which smbwrapper should not be built.
15541
15542         if test x$PICFLAG = x; then
15543            echo No support for PIC code - disabling smbwrapper and smbsh
15544            WRAP=""
15545            WRAP32=""
15546         elif test x$ac_cv_func_syscall = xno; then
15547            echo "$as_me:15547: result: No syscall() -- disabling smbwrapper and smbsh" >&5
15548 echo "${ECHO_T}No syscall() -- disabling smbwrapper and smbsh" >&6
15549            WRAP=""
15550            WRAP32=""
15551         fi
15552     ;;
15553   *)
15554     echo "$as_me:15554: result: no" >&5
15555 echo "${ECHO_T}no" >&6
15556     ;;
15557   esac
15558 else
15559   echo "$as_me:15559: result: no" >&5
15560 echo "${ECHO_T}no" >&6
15561
15562 fi;
15563
15564 #################################################
15565 # check for AFS clear-text auth support
15566 echo "$as_me:15566: checking whether to use AFS clear-text auth" >&5
15567 echo $ECHO_N "checking whether to use AFS clear-text auth... $ECHO_C" >&6
15568
15569 # Check whether --with-afs or --without-afs was given.
15570 if test "${with_afs+set}" = set; then
15571   withval="$with_afs"
15572    case "$withval" in
15573   yes)
15574     echo "$as_me:15574: result: yes" >&5
15575 echo "${ECHO_T}yes" >&6
15576     cat >>confdefs.h <<\EOF
15577 #define WITH_AFS 1
15578 EOF
15579
15580     ;;
15581   *)
15582     echo "$as_me:15582: result: no" >&5
15583 echo "${ECHO_T}no" >&6
15584     ;;
15585   esac
15586 else
15587   echo "$as_me:15587: result: no" >&5
15588 echo "${ECHO_T}no" >&6
15589
15590 fi;
15591
15592 #################################################
15593 # check for the DFS clear-text auth system
15594 echo "$as_me:15594: checking whether to use DFS clear-text auth" >&5
15595 echo $ECHO_N "checking whether to use DFS clear-text auth... $ECHO_C" >&6
15596
15597 # Check whether --with-dfs or --without-dfs was given.
15598 if test "${with_dfs+set}" = set; then
15599   withval="$with_dfs"
15600    case "$withval" in
15601   yes)
15602     echo "$as_me:15602: result: yes" >&5
15603 echo "${ECHO_T}yes" >&6
15604     cat >>confdefs.h <<\EOF
15605 #define WITH_DFS 1
15606 EOF
15607
15608     ;;
15609   *)
15610     echo "$as_me:15610: result: no" >&5
15611 echo "${ECHO_T}no" >&6
15612     ;;
15613   esac
15614 else
15615   echo "$as_me:15615: result: no" >&5
15616 echo "${ECHO_T}no" >&6
15617
15618 fi;
15619
15620 #################################################
15621 # see if this box has the RedHat location for kerberos
15622 echo "$as_me:15622: checking for /usr/kerberos" >&5
15623 echo $ECHO_N "checking for /usr/kerberos... $ECHO_C" >&6
15624 if test -d /usr/kerberos; then
15625     LDFLAGS="$LDFLAGS -L/usr/kerberos/lib"
15626     CFLAGS="$CFLAGS -I/usr/kerberos/include"
15627     CPPFLAGS="$CPPFLAGS -I/usr/kerberos/include"
15628     echo "$as_me:15628: result: yes" >&5
15629 echo "${ECHO_T}yes" >&6
15630 else
15631     echo "$as_me:15631: result: no" >&5
15632 echo "${ECHO_T}no" >&6
15633 fi
15634
15635 #################################################
15636 # check for location of Kerberos 5 install
15637 echo "$as_me:15637: checking for kerberos 5 install path" >&5
15638 echo $ECHO_N "checking for kerberos 5 install path... $ECHO_C" >&6
15639
15640 # Check whether --with-krb5 or --without-krb5 was given.
15641 if test "${with_krb5+set}" = set; then
15642   withval="$with_krb5"
15643    case "$withval" in
15644   no)
15645     echo "$as_me:15645: result: no" >&5
15646 echo "${ECHO_T}no" >&6
15647     ;;
15648   *)
15649     echo "$as_me:15649: result: yes" >&5
15650 echo "${ECHO_T}yes" >&6
15651     LIBS="$LIBS -lkrb5"
15652     CFLAGS="$CFLAGS -I$withval/include"
15653     CPPFLAGS="$CPPFLAGS -I$withval/include"
15654     LDFLAGS="$LDFLAGS -L$withval/lib"
15655     ;;
15656   esac
15657 else
15658   echo "$as_me:15658: result: no" >&5
15659 echo "${ECHO_T}no" >&6
15660
15661 fi;
15662
15663 # now check for krb5.h. Some systems have the libraries without the headers!
15664 # note that this check is done here to allow for different kerberos
15665 # include paths
15666
15667 for ac_header in krb5.h
15668 do
15669 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15670 echo "$as_me:15670: checking for $ac_header" >&5
15671 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15672 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15673   echo $ECHO_N "(cached) $ECHO_C" >&6
15674 else
15675   cat >conftest.$ac_ext <<_ACEOF
15676 #line 15676 "configure"
15677 #include "confdefs.h"
15678 #include <$ac_header>
15679 _ACEOF
15680 if { (eval echo "$as_me:15680: \"$ac_cpp conftest.$ac_ext\"") >&5
15681   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15682   ac_status=$?
15683   egrep -v '^ *\+' conftest.er1 >conftest.err
15684   rm -f conftest.er1
15685   cat conftest.err >&5
15686   echo "$as_me:15686: \$? = $ac_status" >&5
15687   (exit $ac_status); } >/dev/null; then
15688   if test -s conftest.err; then
15689     ac_cpp_err=$ac_c_preproc_warn_flag
15690   else
15691     ac_cpp_err=
15692   fi
15693 else
15694   ac_cpp_err=yes
15695 fi
15696 if test -z "$ac_cpp_err"; then
15697   eval "$as_ac_Header=yes"
15698 else
15699   echo "$as_me: failed program was:" >&5
15700   cat conftest.$ac_ext >&5
15701   eval "$as_ac_Header=no"
15702 fi
15703 rm -f conftest.err conftest.$ac_ext
15704 fi
15705 echo "$as_me:15705: result: `eval echo '${'$as_ac_Header'}'`" >&5
15706 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15707 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15708   cat >>confdefs.h <<EOF
15709 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15710 EOF
15711
15712 fi
15713 done
15714
15715 # now check for gssapi headers.  This is also done here to allow for
15716 # different kerberos include paths
15717
15718 for ac_header in gssapi/gssapi_generic.h gssapi/gssapi.h
15719 do
15720 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15721 echo "$as_me:15721: checking for $ac_header" >&5
15722 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15723 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15724   echo $ECHO_N "(cached) $ECHO_C" >&6
15725 else
15726   cat >conftest.$ac_ext <<_ACEOF
15727 #line 15727 "configure"
15728 #include "confdefs.h"
15729 #include <$ac_header>
15730 _ACEOF
15731 if { (eval echo "$as_me:15731: \"$ac_cpp conftest.$ac_ext\"") >&5
15732   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15733   ac_status=$?
15734   egrep -v '^ *\+' conftest.er1 >conftest.err
15735   rm -f conftest.er1
15736   cat conftest.err >&5
15737   echo "$as_me:15737: \$? = $ac_status" >&5
15738   (exit $ac_status); } >/dev/null; then
15739   if test -s conftest.err; then
15740     ac_cpp_err=$ac_c_preproc_warn_flag
15741   else
15742     ac_cpp_err=
15743   fi
15744 else
15745   ac_cpp_err=yes
15746 fi
15747 if test -z "$ac_cpp_err"; then
15748   eval "$as_ac_Header=yes"
15749 else
15750   echo "$as_me: failed program was:" >&5
15751   cat conftest.$ac_ext >&5
15752   eval "$as_ac_Header=no"
15753 fi
15754 rm -f conftest.err conftest.$ac_ext
15755 fi
15756 echo "$as_me:15756: result: `eval echo '${'$as_ac_Header'}'`" >&5
15757 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15758 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15759   cat >>confdefs.h <<EOF
15760 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15761 EOF
15762
15763 fi
15764 done
15765
15766 ##################################################################
15767 # we might need the k5crypto and com_err libraries on some systems
15768 echo "$as_me:15768: checking for _et_list in -lcom_err" >&5
15769 echo $ECHO_N "checking for _et_list in -lcom_err... $ECHO_C" >&6
15770 if test "${ac_cv_lib_com_err__et_list+set}" = set; then
15771   echo $ECHO_N "(cached) $ECHO_C" >&6
15772 else
15773   ac_check_lib_save_LIBS=$LIBS
15774 LIBS="-lcom_err  $LIBS"
15775 cat >conftest.$ac_ext <<_ACEOF
15776 #line 15776 "configure"
15777 #include "confdefs.h"
15778
15779 /* Override any gcc2 internal prototype to avoid an error.  */
15780 #ifdef __cplusplus
15781 extern "C"
15782 #endif
15783 /* We use char because int might match the return type of a gcc2
15784    builtin and then its argument prototype would still apply.  */
15785 char _et_list ();
15786 int
15787 main ()
15788 {
15789 _et_list ();
15790   ;
15791   return 0;
15792 }
15793 _ACEOF
15794 rm -f conftest.$ac_objext conftest$ac_exeext
15795 if { (eval echo "$as_me:15795: \"$ac_link\"") >&5
15796   (eval $ac_link) 2>&5
15797   ac_status=$?
15798   echo "$as_me:15798: \$? = $ac_status" >&5
15799   (exit $ac_status); } &&
15800          { ac_try='test -s conftest$ac_exeext'
15801   { (eval echo "$as_me:15801: \"$ac_try\"") >&5
15802   (eval $ac_try) 2>&5
15803   ac_status=$?
15804   echo "$as_me:15804: \$? = $ac_status" >&5
15805   (exit $ac_status); }; }; then
15806   ac_cv_lib_com_err__et_list=yes
15807 else
15808   echo "$as_me: failed program was:" >&5
15809 cat conftest.$ac_ext >&5
15810 ac_cv_lib_com_err__et_list=no
15811 fi
15812 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15813 LIBS=$ac_check_lib_save_LIBS
15814 fi
15815 echo "$as_me:15815: result: $ac_cv_lib_com_err__et_list" >&5
15816 echo "${ECHO_T}$ac_cv_lib_com_err__et_list" >&6
15817 if test $ac_cv_lib_com_err__et_list = yes; then
15818   LIBS="$LIBS -lcom_err"
15819 fi
15820
15821 echo "$as_me:15821: checking for krb5_encrypt_data in -lk5crypto" >&5
15822 echo $ECHO_N "checking for krb5_encrypt_data in -lk5crypto... $ECHO_C" >&6
15823 if test "${ac_cv_lib_k5crypto_krb5_encrypt_data+set}" = set; then
15824   echo $ECHO_N "(cached) $ECHO_C" >&6
15825 else
15826   ac_check_lib_save_LIBS=$LIBS
15827 LIBS="-lk5crypto  $LIBS"
15828 cat >conftest.$ac_ext <<_ACEOF
15829 #line 15829 "configure"
15830 #include "confdefs.h"
15831
15832 /* Override any gcc2 internal prototype to avoid an error.  */
15833 #ifdef __cplusplus
15834 extern "C"
15835 #endif
15836 /* We use char because int might match the return type of a gcc2
15837    builtin and then its argument prototype would still apply.  */
15838 char krb5_encrypt_data ();
15839 int
15840 main ()
15841 {
15842 krb5_encrypt_data ();
15843   ;
15844   return 0;
15845 }
15846 _ACEOF
15847 rm -f conftest.$ac_objext conftest$ac_exeext
15848 if { (eval echo "$as_me:15848: \"$ac_link\"") >&5
15849   (eval $ac_link) 2>&5
15850   ac_status=$?
15851   echo "$as_me:15851: \$? = $ac_status" >&5
15852   (exit $ac_status); } &&
15853          { ac_try='test -s conftest$ac_exeext'
15854   { (eval echo "$as_me:15854: \"$ac_try\"") >&5
15855   (eval $ac_try) 2>&5
15856   ac_status=$?
15857   echo "$as_me:15857: \$? = $ac_status" >&5
15858   (exit $ac_status); }; }; then
15859   ac_cv_lib_k5crypto_krb5_encrypt_data=yes
15860 else
15861   echo "$as_me: failed program was:" >&5
15862 cat conftest.$ac_ext >&5
15863 ac_cv_lib_k5crypto_krb5_encrypt_data=no
15864 fi
15865 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15866 LIBS=$ac_check_lib_save_LIBS
15867 fi
15868 echo "$as_me:15868: result: $ac_cv_lib_k5crypto_krb5_encrypt_data" >&5
15869 echo "${ECHO_T}$ac_cv_lib_k5crypto_krb5_encrypt_data" >&6
15870 if test $ac_cv_lib_k5crypto_krb5_encrypt_data = yes; then
15871   LIBS="$LIBS -lk5crypto"
15872 fi
15873
15874 echo "$as_me:15874: checking for gss_import_name in -lgssapi_krb5" >&5
15875 echo $ECHO_N "checking for gss_import_name in -lgssapi_krb5... $ECHO_C" >&6
15876 if test "${ac_cv_lib_gssapi_krb5_gss_import_name+set}" = set; then
15877   echo $ECHO_N "(cached) $ECHO_C" >&6
15878 else
15879   ac_check_lib_save_LIBS=$LIBS
15880 LIBS="-lgssapi_krb5  $LIBS"
15881 cat >conftest.$ac_ext <<_ACEOF
15882 #line 15882 "configure"
15883 #include "confdefs.h"
15884
15885 /* Override any gcc2 internal prototype to avoid an error.  */
15886 #ifdef __cplusplus
15887 extern "C"
15888 #endif
15889 /* We use char because int might match the return type of a gcc2
15890    builtin and then its argument prototype would still apply.  */
15891 char gss_import_name ();
15892 int
15893 main ()
15894 {
15895 gss_import_name ();
15896   ;
15897   return 0;
15898 }
15899 _ACEOF
15900 rm -f conftest.$ac_objext conftest$ac_exeext
15901 if { (eval echo "$as_me:15901: \"$ac_link\"") >&5
15902   (eval $ac_link) 2>&5
15903   ac_status=$?
15904   echo "$as_me:15904: \$? = $ac_status" >&5
15905   (exit $ac_status); } &&
15906          { ac_try='test -s conftest$ac_exeext'
15907   { (eval echo "$as_me:15907: \"$ac_try\"") >&5
15908   (eval $ac_try) 2>&5
15909   ac_status=$?
15910   echo "$as_me:15910: \$? = $ac_status" >&5
15911   (exit $ac_status); }; }; then
15912   ac_cv_lib_gssapi_krb5_gss_import_name=yes
15913 else
15914   echo "$as_me: failed program was:" >&5
15915 cat conftest.$ac_ext >&5
15916 ac_cv_lib_gssapi_krb5_gss_import_name=no
15917 fi
15918 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15919 LIBS=$ac_check_lib_save_LIBS
15920 fi
15921 echo "$as_me:15921: result: $ac_cv_lib_gssapi_krb5_gss_import_name" >&5
15922 echo "${ECHO_T}$ac_cv_lib_gssapi_krb5_gss_import_name" >&6
15923 if test $ac_cv_lib_gssapi_krb5_gss_import_name = yes; then
15924   LIBS="$LIBS -lgssapi_krb5"
15925 fi
15926
15927 ########################################################
15928 # now see if we can find the krb5 libs in standard paths
15929 # or as specified above
15930 echo "$as_me:15930: checking for krb5_mk_req_extended in -lkrb5" >&5
15931 echo $ECHO_N "checking for krb5_mk_req_extended in -lkrb5... $ECHO_C" >&6
15932 if test "${ac_cv_lib_krb5_krb5_mk_req_extended+set}" = set; then
15933   echo $ECHO_N "(cached) $ECHO_C" >&6
15934 else
15935   ac_check_lib_save_LIBS=$LIBS
15936 LIBS="-lkrb5  $LIBS"
15937 cat >conftest.$ac_ext <<_ACEOF
15938 #line 15938 "configure"
15939 #include "confdefs.h"
15940
15941 /* Override any gcc2 internal prototype to avoid an error.  */
15942 #ifdef __cplusplus
15943 extern "C"
15944 #endif
15945 /* We use char because int might match the return type of a gcc2
15946    builtin and then its argument prototype would still apply.  */
15947 char krb5_mk_req_extended ();
15948 int
15949 main ()
15950 {
15951 krb5_mk_req_extended ();
15952   ;
15953   return 0;
15954 }
15955 _ACEOF
15956 rm -f conftest.$ac_objext conftest$ac_exeext
15957 if { (eval echo "$as_me:15957: \"$ac_link\"") >&5
15958   (eval $ac_link) 2>&5
15959   ac_status=$?
15960   echo "$as_me:15960: \$? = $ac_status" >&5
15961   (exit $ac_status); } &&
15962          { ac_try='test -s conftest$ac_exeext'
15963   { (eval echo "$as_me:15963: \"$ac_try\"") >&5
15964   (eval $ac_try) 2>&5
15965   ac_status=$?
15966   echo "$as_me:15966: \$? = $ac_status" >&5
15967   (exit $ac_status); }; }; then
15968   ac_cv_lib_krb5_krb5_mk_req_extended=yes
15969 else
15970   echo "$as_me: failed program was:" >&5
15971 cat conftest.$ac_ext >&5
15972 ac_cv_lib_krb5_krb5_mk_req_extended=no
15973 fi
15974 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15975 LIBS=$ac_check_lib_save_LIBS
15976 fi
15977 echo "$as_me:15977: result: $ac_cv_lib_krb5_krb5_mk_req_extended" >&5
15978 echo "${ECHO_T}$ac_cv_lib_krb5_krb5_mk_req_extended" >&6
15979 if test $ac_cv_lib_krb5_krb5_mk_req_extended = yes; then
15980   LIBS="$LIBS -lkrb5";
15981         cat >>confdefs.h <<\EOF
15982 #define HAVE_KRB5 1
15983 EOF
15984
15985 fi
15986
15987 ##################################################################
15988 # we might need the lber lib on some systems. To avoid link errors
15989 # this test must be before the libldap test
15990 echo "$as_me:15990: checking for ber_scanf in -llber" >&5
15991 echo $ECHO_N "checking for ber_scanf in -llber... $ECHO_C" >&6
15992 if test "${ac_cv_lib_lber_ber_scanf+set}" = set; then
15993   echo $ECHO_N "(cached) $ECHO_C" >&6
15994 else
15995   ac_check_lib_save_LIBS=$LIBS
15996 LIBS="-llber  $LIBS"
15997 cat >conftest.$ac_ext <<_ACEOF
15998 #line 15998 "configure"
15999 #include "confdefs.h"
16000
16001 /* Override any gcc2 internal prototype to avoid an error.  */
16002 #ifdef __cplusplus
16003 extern "C"
16004 #endif
16005 /* We use char because int might match the return type of a gcc2
16006    builtin and then its argument prototype would still apply.  */
16007 char ber_scanf ();
16008 int
16009 main ()
16010 {
16011 ber_scanf ();
16012   ;
16013   return 0;
16014 }
16015 _ACEOF
16016 rm -f conftest.$ac_objext conftest$ac_exeext
16017 if { (eval echo "$as_me:16017: \"$ac_link\"") >&5
16018   (eval $ac_link) 2>&5
16019   ac_status=$?
16020   echo "$as_me:16020: \$? = $ac_status" >&5
16021   (exit $ac_status); } &&
16022          { ac_try='test -s conftest$ac_exeext'
16023   { (eval echo "$as_me:16023: \"$ac_try\"") >&5
16024   (eval $ac_try) 2>&5
16025   ac_status=$?
16026   echo "$as_me:16026: \$? = $ac_status" >&5
16027   (exit $ac_status); }; }; then
16028   ac_cv_lib_lber_ber_scanf=yes
16029 else
16030   echo "$as_me: failed program was:" >&5
16031 cat conftest.$ac_ext >&5
16032 ac_cv_lib_lber_ber_scanf=no
16033 fi
16034 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16035 LIBS=$ac_check_lib_save_LIBS
16036 fi
16037 echo "$as_me:16037: result: $ac_cv_lib_lber_ber_scanf" >&5
16038 echo "${ECHO_T}$ac_cv_lib_lber_ber_scanf" >&6
16039 if test $ac_cv_lib_lber_ber_scanf = yes; then
16040   LIBS="$LIBS -llber"
16041 fi
16042
16043 ########################################################
16044 # now see if we can find the ldap libs in standard paths
16045 if test x$have_ldap != xyes; then
16046 echo "$as_me:16046: checking for ldap_open in -lldap" >&5
16047 echo $ECHO_N "checking for ldap_open in -lldap... $ECHO_C" >&6
16048 if test "${ac_cv_lib_ldap_ldap_open+set}" = set; then
16049   echo $ECHO_N "(cached) $ECHO_C" >&6
16050 else
16051   ac_check_lib_save_LIBS=$LIBS
16052 LIBS="-lldap  $LIBS"
16053 cat >conftest.$ac_ext <<_ACEOF
16054 #line 16054 "configure"
16055 #include "confdefs.h"
16056
16057 /* Override any gcc2 internal prototype to avoid an error.  */
16058 #ifdef __cplusplus
16059 extern "C"
16060 #endif
16061 /* We use char because int might match the return type of a gcc2
16062    builtin and then its argument prototype would still apply.  */
16063 char ldap_open ();
16064 int
16065 main ()
16066 {
16067 ldap_open ();
16068   ;
16069   return 0;
16070 }
16071 _ACEOF
16072 rm -f conftest.$ac_objext conftest$ac_exeext
16073 if { (eval echo "$as_me:16073: \"$ac_link\"") >&5
16074   (eval $ac_link) 2>&5
16075   ac_status=$?
16076   echo "$as_me:16076: \$? = $ac_status" >&5
16077   (exit $ac_status); } &&
16078          { ac_try='test -s conftest$ac_exeext'
16079   { (eval echo "$as_me:16079: \"$ac_try\"") >&5
16080   (eval $ac_try) 2>&5
16081   ac_status=$?
16082   echo "$as_me:16082: \$? = $ac_status" >&5
16083   (exit $ac_status); }; }; then
16084   ac_cv_lib_ldap_ldap_open=yes
16085 else
16086   echo "$as_me: failed program was:" >&5
16087 cat conftest.$ac_ext >&5
16088 ac_cv_lib_ldap_ldap_open=no
16089 fi
16090 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16091 LIBS=$ac_check_lib_save_LIBS
16092 fi
16093 echo "$as_me:16093: result: $ac_cv_lib_ldap_ldap_open" >&5
16094 echo "${ECHO_T}$ac_cv_lib_ldap_ldap_open" >&6
16095 if test $ac_cv_lib_ldap_ldap_open = yes; then
16096   LIBS="$LIBS -lldap";
16097         cat >>confdefs.h <<\EOF
16098 #define HAVE_LDAP 1
16099 EOF
16100
16101 fi
16102
16103 fi
16104
16105 #################################################
16106 # check for automount support
16107 echo "$as_me:16107: checking whether to use AUTOMOUNT" >&5
16108 echo $ECHO_N "checking whether to use AUTOMOUNT... $ECHO_C" >&6
16109
16110 # Check whether --with-automount or --without-automount was given.
16111 if test "${with_automount+set}" = set; then
16112   withval="$with_automount"
16113    case "$withval" in
16114   yes)
16115     echo "$as_me:16115: result: yes" >&5
16116 echo "${ECHO_T}yes" >&6
16117     cat >>confdefs.h <<\EOF
16118 #define WITH_AUTOMOUNT 1
16119 EOF
16120
16121     ;;
16122   *)
16123     echo "$as_me:16123: result: no" >&5
16124 echo "${ECHO_T}no" >&6
16125     ;;
16126   esac
16127 else
16128   echo "$as_me:16128: result: no" >&5
16129 echo "${ECHO_T}no" >&6
16130
16131 fi;
16132
16133 #################################################
16134 # check for smbmount support
16135 echo "$as_me:16135: checking whether to use SMBMOUNT" >&5
16136 echo $ECHO_N "checking whether to use SMBMOUNT... $ECHO_C" >&6
16137
16138 # Check whether --with-smbmount or --without-smbmount was given.
16139 if test "${with_smbmount+set}" = set; then
16140   withval="$with_smbmount"
16141    case "$withval" in
16142   yes)
16143         case "$host_os" in
16144         *linux*)
16145                 echo "$as_me:16145: result: yes" >&5
16146 echo "${ECHO_T}yes" >&6
16147                 cat >>confdefs.h <<\EOF
16148 #define WITH_SMBMOUNT 1
16149 EOF
16150
16151                 MPROGS="bin/smbmount bin/smbmnt bin/smbumount"
16152                 ;;
16153         *)
16154                 { { echo "$as_me:16154: error: not on a linux system!" >&5
16155 echo "$as_me: error: not on a linux system!" >&2;}
16156    { (exit 1); exit 1; }; }
16157                 ;;
16158         esac
16159     ;;
16160   *)
16161     echo "$as_me:16161: result: no" >&5
16162 echo "${ECHO_T}no" >&6
16163     MPROGS=
16164     ;;
16165   esac
16166 else
16167   echo "$as_me:16167: result: no" >&5
16168 echo "${ECHO_T}no" >&6
16169   MPROGS=
16170
16171 fi;
16172
16173 #################################################
16174 # check for a PAM clear-text auth, accounts, password and session support
16175 with_pam_for_crypt=no
16176 echo "$as_me:16176: checking whether to use PAM" >&5
16177 echo $ECHO_N "checking whether to use PAM... $ECHO_C" >&6
16178
16179 # Check whether --with-pam or --without-pam was given.
16180 if test "${with_pam+set}" = set; then
16181   withval="$with_pam"
16182    case "$withval" in
16183   yes)
16184     echo "$as_me:16184: result: yes" >&5
16185 echo "${ECHO_T}yes" >&6
16186     cat >>confdefs.h <<\EOF
16187 #define WITH_PAM 1
16188 EOF
16189
16190     LIBS="$LIBS -lpam"
16191     with_pam_for_crypt=yes
16192     ;;
16193   *)
16194     echo "$as_me:16194: result: no" >&5
16195 echo "${ECHO_T}no" >&6
16196     ;;
16197   esac
16198 else
16199   echo "$as_me:16199: result: no" >&5
16200 echo "${ECHO_T}no" >&6
16201
16202 fi;
16203
16204 # we can't build a pam module if we don't have pam.
16205 echo "$as_me:16205: checking for pam_get_data in -lpam" >&5
16206 echo $ECHO_N "checking for pam_get_data in -lpam... $ECHO_C" >&6
16207 if test "${ac_cv_lib_pam_pam_get_data+set}" = set; then
16208   echo $ECHO_N "(cached) $ECHO_C" >&6
16209 else
16210   ac_check_lib_save_LIBS=$LIBS
16211 LIBS="-lpam  $LIBS"
16212 cat >conftest.$ac_ext <<_ACEOF
16213 #line 16213 "configure"
16214 #include "confdefs.h"
16215
16216 /* Override any gcc2 internal prototype to avoid an error.  */
16217 #ifdef __cplusplus
16218 extern "C"
16219 #endif
16220 /* We use char because int might match the return type of a gcc2
16221    builtin and then its argument prototype would still apply.  */
16222 char pam_get_data ();
16223 int
16224 main ()
16225 {
16226 pam_get_data ();
16227   ;
16228   return 0;
16229 }
16230 _ACEOF
16231 rm -f conftest.$ac_objext conftest$ac_exeext
16232 if { (eval echo "$as_me:16232: \"$ac_link\"") >&5
16233   (eval $ac_link) 2>&5
16234   ac_status=$?
16235   echo "$as_me:16235: \$? = $ac_status" >&5
16236   (exit $ac_status); } &&
16237          { ac_try='test -s conftest$ac_exeext'
16238   { (eval echo "$as_me:16238: \"$ac_try\"") >&5
16239   (eval $ac_try) 2>&5
16240   ac_status=$?
16241   echo "$as_me:16241: \$? = $ac_status" >&5
16242   (exit $ac_status); }; }; then
16243   ac_cv_lib_pam_pam_get_data=yes
16244 else
16245   echo "$as_me: failed program was:" >&5
16246 cat conftest.$ac_ext >&5
16247 ac_cv_lib_pam_pam_get_data=no
16248 fi
16249 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16250 LIBS=$ac_check_lib_save_LIBS
16251 fi
16252 echo "$as_me:16252: result: $ac_cv_lib_pam_pam_get_data" >&5
16253 echo "${ECHO_T}$ac_cv_lib_pam_pam_get_data" >&6
16254 if test $ac_cv_lib_pam_pam_get_data = yes; then
16255   cat >>confdefs.h <<\EOF
16256 #define HAVE_LIBPAM 1
16257 EOF
16258
16259 fi
16260
16261 #################################################
16262 # check for pam_smbpass support
16263 echo "$as_me:16263: checking whether to use pam_smbpass" >&5
16264 echo $ECHO_N "checking whether to use pam_smbpass... $ECHO_C" >&6
16265
16266 # Check whether --with-pam_smbpass or --without-pam_smbpass was given.
16267 if test "${with_pam_smbpass+set}" = set; then
16268   withval="$with_pam_smbpass"
16269    case "$withval" in
16270   yes)
16271     echo "$as_me:16271: result: yes" >&5
16272 echo "${ECHO_T}yes" >&6
16273
16274 # Conditions under which pam_smbpass should not be built.
16275
16276        if test x$PICFLAG = x; then
16277           echo "$as_me:16277: result: No support for PIC code - disabling pam_smbpass" >&5
16278 echo "${ECHO_T}No support for PIC code - disabling pam_smbpass" >&6
16279           PAM_MOD=""
16280        elif test x$ac_cv_lib_pam_pam_get_data = xno; then
16281           echo "$as_me:16281: result: No libpam found -- disabling pam_smbpass" >&5
16282 echo "${ECHO_T}No libpam found -- disabling pam_smbpass" >&6
16283           PAM_MOD=""
16284        else
16285           PAM_MOD="bin/pam_smbpass.so"
16286        fi
16287     ;;
16288   *)
16289     echo "$as_me:16289: result: no" >&5
16290 echo "${ECHO_T}no" >&6
16291     ;;
16292   esac
16293 else
16294   echo "$as_me:16294: result: no" >&5
16295 echo "${ECHO_T}no" >&6
16296
16297 fi;
16298
16299 ###############################################
16300 # test for where we get crypt() from, but only
16301 # if not using PAM
16302 if test $with_pam_for_crypt = no; then
16303
16304 for ac_func in crypt
16305 do
16306 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16307 echo "$as_me:16307: checking for $ac_func" >&5
16308 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16309 if eval "test \"\${$as_ac_var+set}\" = set"; then
16310   echo $ECHO_N "(cached) $ECHO_C" >&6
16311 else
16312   cat >conftest.$ac_ext <<_ACEOF
16313 #line 16313 "configure"
16314 #include "confdefs.h"
16315 /* System header to define __stub macros and hopefully few prototypes,
16316     which can conflict with char $ac_func (); below.  */
16317 #include <assert.h>
16318 /* Override any gcc2 internal prototype to avoid an error.  */
16319 #ifdef __cplusplus
16320 extern "C"
16321 #endif
16322 /* We use char because int might match the return type of a gcc2
16323    builtin and then its argument prototype would still apply.  */
16324 char $ac_func ();
16325 char (*f) ();
16326
16327 int
16328 main ()
16329 {
16330 /* The GNU C library defines this for functions which it implements
16331     to always fail with ENOSYS.  Some functions are actually named
16332     something starting with __ and the normal name is an alias.  */
16333 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16334 choke me
16335 #else
16336 f = $ac_func;
16337 #endif
16338
16339   ;
16340   return 0;
16341 }
16342 _ACEOF
16343 rm -f conftest.$ac_objext conftest$ac_exeext
16344 if { (eval echo "$as_me:16344: \"$ac_link\"") >&5
16345   (eval $ac_link) 2>&5
16346   ac_status=$?
16347   echo "$as_me:16347: \$? = $ac_status" >&5
16348   (exit $ac_status); } &&
16349          { ac_try='test -s conftest$ac_exeext'
16350   { (eval echo "$as_me:16350: \"$ac_try\"") >&5
16351   (eval $ac_try) 2>&5
16352   ac_status=$?
16353   echo "$as_me:16353: \$? = $ac_status" >&5
16354   (exit $ac_status); }; }; then
16355   eval "$as_ac_var=yes"
16356 else
16357   echo "$as_me: failed program was:" >&5
16358 cat conftest.$ac_ext >&5
16359 eval "$as_ac_var=no"
16360 fi
16361 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16362 fi
16363 echo "$as_me:16363: result: `eval echo '${'$as_ac_var'}'`" >&5
16364 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16365 if test `eval echo '${'$as_ac_var'}'` = yes; then
16366   cat >>confdefs.h <<EOF
16367 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16368 EOF
16369
16370 fi
16371 done
16372
16373 if test x"$ac_cv_func_crypt" = x"no"; then
16374     echo "$as_me:16374: checking for crypt in -lcrypt" >&5
16375 echo $ECHO_N "checking for crypt in -lcrypt... $ECHO_C" >&6
16376 if test "${ac_cv_lib_crypt_crypt+set}" = set; then
16377   echo $ECHO_N "(cached) $ECHO_C" >&6
16378 else
16379   ac_check_lib_save_LIBS=$LIBS
16380 LIBS="-lcrypt  $LIBS"
16381 cat >conftest.$ac_ext <<_ACEOF
16382 #line 16382 "configure"
16383 #include "confdefs.h"
16384
16385 /* Override any gcc2 internal prototype to avoid an error.  */
16386 #ifdef __cplusplus
16387 extern "C"
16388 #endif
16389 /* We use char because int might match the return type of a gcc2
16390    builtin and then its argument prototype would still apply.  */
16391 char crypt ();
16392 int
16393 main ()
16394 {
16395 crypt ();
16396   ;
16397   return 0;
16398 }
16399 _ACEOF
16400 rm -f conftest.$ac_objext conftest$ac_exeext
16401 if { (eval echo "$as_me:16401: \"$ac_link\"") >&5
16402   (eval $ac_link) 2>&5
16403   ac_status=$?
16404   echo "$as_me:16404: \$? = $ac_status" >&5
16405   (exit $ac_status); } &&
16406          { ac_try='test -s conftest$ac_exeext'
16407   { (eval echo "$as_me:16407: \"$ac_try\"") >&5
16408   (eval $ac_try) 2>&5
16409   ac_status=$?
16410   echo "$as_me:16410: \$? = $ac_status" >&5
16411   (exit $ac_status); }; }; then
16412   ac_cv_lib_crypt_crypt=yes
16413 else
16414   echo "$as_me: failed program was:" >&5
16415 cat conftest.$ac_ext >&5
16416 ac_cv_lib_crypt_crypt=no
16417 fi
16418 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16419 LIBS=$ac_check_lib_save_LIBS
16420 fi
16421 echo "$as_me:16421: result: $ac_cv_lib_crypt_crypt" >&5
16422 echo "${ECHO_T}$ac_cv_lib_crypt_crypt" >&6
16423 if test $ac_cv_lib_crypt_crypt = yes; then
16424   LIBS="$LIBS -lcrypt";
16425         cat >>confdefs.h <<\EOF
16426 #define HAVE_CRYPT 1
16427 EOF
16428
16429 fi
16430
16431 fi
16432 fi
16433
16434 ##
16435 ## moved after the check for -lcrypt in order to
16436 ## ensure that the necessary libraries are included
16437 ## check checking for truncated salt.  Wrapped by the
16438 ## $with_pam_for_crypt variable as above   --jerry
16439 ##
16440 if test $with_pam_for_crypt = no; then
16441 echo "$as_me:16441: checking for a crypt that needs truncated salt" >&5
16442 echo $ECHO_N "checking for a crypt that needs truncated salt... $ECHO_C" >&6
16443 if test "${samba_cv_HAVE_TRUNCATED_SALT+set}" = set; then
16444   echo $ECHO_N "(cached) $ECHO_C" >&6
16445 else
16446
16447 if test "$cross_compiling" = yes; then
16448   samba_cv_HAVE_TRUNCATED_SALT=cross
16449 else
16450   cat >conftest.$ac_ext <<_ACEOF
16451 #line 16451 "configure"
16452 #include "confdefs.h"
16453 #include "${srcdir-.}/tests/crypttest.c"
16454 _ACEOF
16455 rm -f conftest$ac_exeext
16456 if { (eval echo "$as_me:16456: \"$ac_link\"") >&5
16457   (eval $ac_link) 2>&5
16458   ac_status=$?
16459   echo "$as_me:16459: \$? = $ac_status" >&5
16460   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16461   { (eval echo "$as_me:16461: \"$ac_try\"") >&5
16462   (eval $ac_try) 2>&5
16463   ac_status=$?
16464   echo "$as_me:16464: \$? = $ac_status" >&5
16465   (exit $ac_status); }; }; then
16466   samba_cv_HAVE_TRUNCATED_SALT=no
16467 else
16468   echo "$as_me: program exited with status $ac_status" >&5
16469 echo "$as_me: failed program was:" >&5
16470 cat conftest.$ac_ext >&5
16471 samba_cv_HAVE_TRUNCATED_SALT=yes
16472 fi
16473 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16474 fi
16475 fi
16476 echo "$as_me:16476: result: $samba_cv_HAVE_TRUNCATED_SALT" >&5
16477 echo "${ECHO_T}$samba_cv_HAVE_TRUNCATED_SALT" >&6
16478 if test x"$samba_cv_HAVE_TRUNCATED_SALT" = x"yes"; then
16479         cat >>confdefs.h <<\EOF
16480 #define HAVE_TRUNCATED_SALT 1
16481 EOF
16482
16483 fi
16484 fi
16485
16486 ########################################################################################
16487 ##
16488 ## TESTS FOR SAM BACKENDS.  KEEP THESE GROUPED TOGETHER
16489 ##
16490 ########################################################################################
16491
16492 ## set the with_smbpasswd_sam as the default
16493 with_smbpasswd_sam=yes
16494
16495 #################################################
16496 # check for a TDB password database
16497 echo "$as_me:16497: checking whether to use TDB SAM database" >&5
16498 echo $ECHO_N "checking whether to use TDB SAM database... $ECHO_C" >&6
16499
16500 # Check whether --with-tdbsam or --without-tdbsam was given.
16501 if test "${with_tdbsam+set}" = set; then
16502   withval="$with_tdbsam"
16503    case "$withval" in
16504   yes)
16505     echo "$as_me:16505: result: yes" >&5
16506 echo "${ECHO_T}yes" >&6
16507     cat >>confdefs.h <<\EOF
16508 #define WITH_TDB_SAM 1
16509 EOF
16510
16511     with_smbpasswd_sam=no
16512     ;;
16513   *)
16514     echo "$as_me:16514: result: no" >&5
16515 echo "${ECHO_T}no" >&6
16516     ;;
16517   esac
16518 else
16519   echo "$as_me:16519: result: no" >&5
16520 echo "${ECHO_T}no" >&6
16521
16522 fi;
16523
16524 #################################################
16525 # check for a LDAP password database
16526 echo "$as_me:16526: checking whether to use LDAP SAM database" >&5
16527 echo $ECHO_N "checking whether to use LDAP SAM database... $ECHO_C" >&6
16528
16529 # Check whether --with-ldapsam or --without-ldapsam was given.
16530 if test "${with_ldapsam+set}" = set; then
16531   withval="$with_ldapsam"
16532    case "$withval" in
16533   yes)
16534     echo "$as_me:16534: result: yes" >&5
16535 echo "${ECHO_T}yes" >&6
16536     cat >>confdefs.h <<\EOF
16537 #define WITH_LDAP_SAM 1
16538 EOF
16539
16540     LIBS="-lldap -llber $LIBS"
16541     with_smbpasswd_sam=no
16542     ;;
16543   *)
16544     echo "$as_me:16544: result: no" >&5
16545 echo "${ECHO_T}no" >&6
16546     ;;
16547   esac
16548 else
16549   echo "$as_me:16549: result: no" >&5
16550 echo "${ECHO_T}no" >&6
16551
16552 fi;
16553
16554 #################################################
16555 # check for a NISPLUS password database
16556 echo "$as_me:16556: checking whether to use NISPLUS SAM database" >&5
16557 echo $ECHO_N "checking whether to use NISPLUS SAM database... $ECHO_C" >&6
16558
16559 # Check whether --with-nisplussam or --without-nisplussam was given.
16560 if test "${with_nisplussam+set}" = set; then
16561   withval="$with_nisplussam"
16562    case "$withval" in
16563   yes)
16564     echo "$as_me:16564: result: yes" >&5
16565 echo "${ECHO_T}yes" >&6
16566     cat >>confdefs.h <<\EOF
16567 #define WITH_NISPLUS_SAM 1
16568 EOF
16569
16570     with_smbpasswd_sam=no
16571     ;;
16572   *)
16573     echo "$as_me:16573: result: no" >&5
16574 echo "${ECHO_T}no" >&6
16575     ;;
16576   esac
16577 else
16578   echo "$as_me:16578: result: no" >&5
16579 echo "${ECHO_T}no" >&6
16580
16581 fi;
16582
16583 ################################################
16584 # This test should come last because the
16585 # smbpasswd SAM is only used if another format
16586 # has not been defined
16587 echo "$as_me:16587: checking whether to use traditional smbpasswd file" >&5
16588 echo $ECHO_N "checking whether to use traditional smbpasswd file... $ECHO_C" >&6
16589 if test $with_smbpasswd_sam = yes; then
16590         echo "$as_me:16590: result: yes" >&5
16591 echo "${ECHO_T}yes" >&6
16592         cat >>confdefs.h <<\EOF
16593 #define WITH_SMBPASSWD_SAM 1
16594 EOF
16595
16596 else
16597         echo "$as_me:16597: result: no" >&5
16598 echo "${ECHO_T}no" >&6
16599 fi
16600
16601 ########################################################################################
16602 ##
16603 ## END OF TESTS FOR SAM BACKENDS.
16604 ##
16605 ########################################################################################
16606
16607 #################################################
16608 # check for a NISPLUS_HOME support
16609 echo "$as_me:16609: checking whether to use NISPLUS_HOME" >&5
16610 echo $ECHO_N "checking whether to use NISPLUS_HOME... $ECHO_C" >&6
16611
16612 # Check whether --with-nisplus-home or --without-nisplus-home was given.
16613 if test "${with_nisplus_home+set}" = set; then
16614   withval="$with_nisplus_home"
16615    case "$withval" in
16616   yes)
16617     echo "$as_me:16617: result: yes" >&5
16618 echo "${ECHO_T}yes" >&6
16619     cat >>confdefs.h <<\EOF
16620 #define WITH_NISPLUS_HOME 1
16621 EOF
16622
16623     ;;
16624   *)
16625     echo "$as_me:16625: result: no" >&5
16626 echo "${ECHO_T}no" >&6
16627     ;;
16628   esac
16629 else
16630   echo "$as_me:16630: result: no" >&5
16631 echo "${ECHO_T}no" >&6
16632
16633 fi;
16634
16635 #################################################
16636 # check for the secure socket layer
16637 echo "$as_me:16637: checking whether to use SSL" >&5
16638 echo $ECHO_N "checking whether to use SSL... $ECHO_C" >&6
16639
16640 # Check whether --with-ssl or --without-ssl was given.
16641 if test "${with_ssl+set}" = set; then
16642   withval="$with_ssl"
16643    case "$withval" in
16644   yes)
16645     echo "$as_me:16645: result: yes" >&5
16646 echo "${ECHO_T}yes" >&6
16647     cat >>confdefs.h <<\EOF
16648 #define WITH_SSL 1
16649 EOF
16650
16651     withval="/usr/local/ssl"     # default
16652
16653     if test "${with_sslinc+set}" = set; then
16654
16655         withval="$with_sslinc"
16656         case "$withval" in
16657         yes|no)
16658           echo "configure: warning: --with-sslinc called without argument - will use default" 1>&w
16659           CFLAGS="-I/usr/local/ssl/include $CFLAGS"
16660         ;;
16661         * )
16662           CFLAGS="-I${withval} $CFLAGS"
16663         ;;
16664         esac
16665
16666     else
16667
16668         CFLAGS="-I/usr/local/ssl/include $CFLAGS"
16669
16670     fi
16671
16672     if test "${with_ssllib+set}" = set; then
16673
16674         withval="$with_ssllib"
16675         case "$withval" in
16676         yes|no)
16677           echo "configure: warning: --with-ssllib called without argument - will use default" 1>&w
16678           LDFLAGS="-L/usr/local/ssl/lib $LDFLAGS"
16679         ;;
16680         * )
16681           LDFLAGS="-L${withval}/lib $LDFLAGS"
16682         ;;
16683         esac
16684
16685     else
16686
16687         LDFLAGS="-L/usr/local/ssl/lib $LDFLAGS"
16688
16689     fi
16690
16691     LIBS="-lssl -lcrypto $LIBS"
16692
16693 #    if test ! -d ${withval}; then
16694 #      echo "configure: error: called with --with-ssl, but ssl base directory ${withval} does not exist or is not a directory. Aborting config" 1>&2
16695 #      exit 1
16696 #    fi
16697
16698     CFLAGS="-DHAVE_CRYPT_DECL $CFLAGS"  # Damn, SSLeay defines its own
16699
16700     ;;
16701   *)
16702     echo "$as_me:16702: result: no" >&5
16703 echo "${ECHO_T}no" >&6
16704     ;;
16705   esac
16706 else
16707   echo "$as_me:16707: result: no" >&5
16708 echo "${ECHO_T}no" >&6
16709
16710 fi;
16711
16712 #################################################
16713 # check for syslog logging
16714 echo "$as_me:16714: checking whether to use syslog logging" >&5
16715 echo $ECHO_N "checking whether to use syslog logging... $ECHO_C" >&6
16716
16717 # Check whether --with-syslog or --without-syslog was given.
16718 if test "${with_syslog+set}" = set; then
16719   withval="$with_syslog"
16720    case "$withval" in
16721   yes)
16722     echo "$as_me:16722: result: yes" >&5
16723 echo "${ECHO_T}yes" >&6
16724     cat >>confdefs.h <<\EOF
16725 #define WITH_SYSLOG 1
16726 EOF
16727
16728     ;;
16729   *)
16730     echo "$as_me:16730: result: no" >&5
16731 echo "${ECHO_T}no" >&6
16732     ;;
16733   esac
16734 else
16735   echo "$as_me:16735: result: no" >&5
16736 echo "${ECHO_T}no" >&6
16737
16738 fi;
16739
16740 #################################################
16741 # check for a shared memory profiling support
16742 echo "$as_me:16742: checking whether to use profiling" >&5
16743 echo $ECHO_N "checking whether to use profiling... $ECHO_C" >&6
16744
16745 # Check whether --with-profiling-data or --without-profiling-data was given.
16746 if test "${with_profiling_data+set}" = set; then
16747   withval="$with_profiling_data"
16748    case "$withval" in
16749   yes)
16750     echo "$as_me:16750: result: yes" >&5
16751 echo "${ECHO_T}yes" >&6
16752     cat >>confdefs.h <<\EOF
16753 #define WITH_PROFILE 1
16754 EOF
16755
16756     ;;
16757   *)
16758     echo "$as_me:16758: result: no" >&5
16759 echo "${ECHO_T}no" >&6
16760     ;;
16761   esac
16762 else
16763   echo "$as_me:16763: result: no" >&5
16764 echo "${ECHO_T}no" >&6
16765
16766 fi;
16767
16768 #################################################
16769 # check for experimental disk-quotas support
16770 QUOTAOBJS=smbd/noquotas.o
16771
16772 echo "$as_me:16772: checking whether to support disk-quotas" >&5
16773 echo $ECHO_N "checking whether to support disk-quotas... $ECHO_C" >&6
16774
16775 # Check whether --with-quotas or --without-quotas was given.
16776 if test "${with_quotas+set}" = set; then
16777   withval="$with_quotas"
16778    case "$withval" in
16779   yes)
16780     echo "$as_me:16780: result: yes" >&5
16781 echo "${ECHO_T}yes" >&6
16782     case "$host_os" in
16783       *linux*)
16784         # Check for kernel 2.4.x quota braindamage...
16785         echo "$as_me:16785: checking for linux 2.4.x quota braindamage.." >&5
16786 echo $ECHO_N "checking for linux 2.4.x quota braindamage..... $ECHO_C" >&6
16787 if test "${samba_cv_linux_2_4_quota_braindamage+set}" = set; then
16788   echo $ECHO_N "(cached) $ECHO_C" >&6
16789 else
16790
16791         cat >conftest.$ac_ext <<_ACEOF
16792 #line 16792 "configure"
16793 #include "confdefs.h"
16794 #include <stdio.h>
16795 #include <sys/types.h>
16796 #include <asm/types.h>
16797 #include <linux/quota.h>
16798 #include <mntent.h>
16799 #include <linux/unistd.h>
16800 int
16801 main ()
16802 {
16803 struct mem_dqblk D;
16804   ;
16805   return 0;
16806 }
16807 _ACEOF
16808 rm -f conftest.$ac_objext
16809 if { (eval echo "$as_me:16809: \"$ac_compile\"") >&5
16810   (eval $ac_compile) 2>&5
16811   ac_status=$?
16812   echo "$as_me:16812: \$? = $ac_status" >&5
16813   (exit $ac_status); } &&
16814          { ac_try='test -s conftest.$ac_objext'
16815   { (eval echo "$as_me:16815: \"$ac_try\"") >&5
16816   (eval $ac_try) 2>&5
16817   ac_status=$?
16818   echo "$as_me:16818: \$? = $ac_status" >&5
16819   (exit $ac_status); }; }; then
16820   samba_cv_linux_2_4_quota_braindamage=yes
16821 else
16822   echo "$as_me: failed program was:" >&5
16823 cat conftest.$ac_ext >&5
16824 samba_cv_linux_2_4_quota_braindamage=no
16825 fi
16826 rm -f conftest.$ac_objext conftest.$ac_ext
16827 fi
16828 echo "$as_me:16828: result: $samba_cv_linux_2_4_quota_braindamage" >&5
16829 echo "${ECHO_T}$samba_cv_linux_2_4_quota_braindamage" >&6
16830 if test x"$samba_cv_linux_2_4_quota_braindamage" = x"yes"; then
16831         cat >>confdefs.h <<\EOF
16832 #define LINUX_QUOTAS_2 1
16833 EOF
16834
16835 else
16836         cat >>confdefs.h <<\EOF
16837 #define LINUX_QUOTAS_1 1
16838 EOF
16839
16840 fi
16841         ;;
16842       *)
16843         ;;
16844     esac
16845     QUOTAOBJS=smbd/quotas.o
16846     cat >>confdefs.h <<\EOF
16847 #define WITH_QUOTAS 1
16848 EOF
16849
16850     ;;
16851   *)
16852     echo "$as_me:16852: result: no" >&5
16853 echo "${ECHO_T}no" >&6
16854     ;;
16855   esac
16856 else
16857   echo "$as_me:16857: result: no" >&5
16858 echo "${ECHO_T}no" >&6
16859
16860 fi;
16861
16862 #################################################
16863 # check for experimental utmp accounting
16864
16865 echo "$as_me:16865: checking whether to support utmp accounting" >&5
16866 echo $ECHO_N "checking whether to support utmp accounting... $ECHO_C" >&6
16867
16868 # Check whether --with-utmp or --without-utmp was given.
16869 if test "${with_utmp+set}" = set; then
16870   withval="$with_utmp"
16871    case "$withval" in
16872   yes)
16873     echo "$as_me:16873: result: yes" >&5
16874 echo "${ECHO_T}yes" >&6
16875     cat >>confdefs.h <<\EOF
16876 #define WITH_UTMP 1
16877 EOF
16878
16879     ;;
16880   *)
16881     echo "$as_me:16881: result: no" >&5
16882 echo "${ECHO_T}no" >&6
16883     ;;
16884   esac
16885 else
16886   echo "$as_me:16886: result: no" >&5
16887 echo "${ECHO_T}no" >&6
16888
16889 fi;
16890
16891 #################################################
16892 # set private directory location
16893
16894 # Check whether --with-privatedir or --without-privatedir was given.
16895 if test "${with_privatedir+set}" = set; then
16896   withval="$with_privatedir"
16897    case "$withval" in
16898   yes|no)
16899   #
16900   # Just in case anybody calls it without argument
16901   #
16902     { echo "$as_me:16902: WARNING: --with-privatedir called without argument - will use default" >&5
16903 echo "$as_me: WARNING: --with-privatedir called without argument - will use default" >&2;}
16904     privatedir='${prefix}/private'
16905   ;;
16906   * )
16907     privatedir="$withval"
16908     ;;
16909   esac
16910
16911 else
16912   privatedir='${prefix}/private'
16913
16914 fi;
16915
16916 #################################################
16917 # set lock directory location
16918
16919 # Check whether --with-lockdir or --without-lockdir was given.
16920 if test "${with_lockdir+set}" = set; then
16921   withval="$with_lockdir"
16922    case "$withval" in
16923   yes|no)
16924   #
16925   # Just in case anybody calls it without argument
16926   #
16927     { echo "$as_me:16927: WARNING: --with-lockdir called without argument - will use default" >&5
16928 echo "$as_me: WARNING: --with-lockdir called without argument - will use default" >&2;}
16929     lockdir='$(VARDIR)/locks'
16930   ;;
16931   * )
16932     lockdir="$withval"
16933     ;;
16934   esac
16935
16936 else
16937   lockdir='$(VARDIR)/locks'
16938
16939 fi;
16940
16941 #################################################
16942 # set SWAT directory location
16943
16944 # Check whether --with-swatdir or --without-swatdir was given.
16945 if test "${with_swatdir+set}" = set; then
16946   withval="$with_swatdir"
16947    case "$withval" in
16948   yes|no)
16949   #
16950   # Just in case anybody does it
16951   #
16952     { echo "$as_me:16952: WARNING: --with-swatdir called without argument - will use default" >&5
16953 echo "$as_me: WARNING: --with-swatdir called without argument - will use default" >&2;}
16954     swatdir='${prefix}/swat'
16955   ;;
16956   * )
16957     swatdir="$withval"
16958     ;;
16959   esac
16960
16961 else
16962   swatdir='${prefix}/swat'
16963
16964 fi;
16965
16966 #################################################
16967 # choose native language(s) of man pages
16968 echo "$as_me:16968: checking chosen man pages' language(s)" >&5
16969 echo $ECHO_N "checking chosen man pages' language(s)... $ECHO_C" >&6
16970
16971 # Check whether --with-manpages-langs or --without-manpages-langs was given.
16972 if test "${with_manpages_langs+set}" = set; then
16973   withval="$with_manpages_langs"
16974    case "$withval" in
16975   yes|no)
16976     { echo "$as_me:16976: WARNING: --with-manpages-langs called without argument - will use default" >&5
16977 echo "$as_me: WARNING: --with-manpages-langs called without argument - will use default" >&2;}
16978     manlangs="en"
16979   ;;
16980   *)
16981     manlangs="$withval"
16982   ;;
16983   esac
16984
16985   echo "$as_me:16985: result: $manlangs" >&5
16986 echo "${ECHO_T}$manlangs" >&6
16987   manlangs=`echo $manlangs | sed "s/,/ /"`   # replacing commas with spaces to produce a list
16988
16989 else
16990   manlangs="en"
16991   echo "$as_me:16991: result: $manlangs" >&5
16992 echo "${ECHO_T}$manlangs" >&6
16993
16994 fi;
16995
16996 #################################################
16997 # these tests are taken from the GNU fileutils package
16998 { echo "$as_me:16998: checking how to get filesystem space usage..." >&5
16999 echo "$as_me: checking how to get filesystem space usage..." >&6;}
17000 space=no
17001
17002 # Test for statvfs64.
17003 if test $space = no; then
17004   # SVR4
17005   echo "$as_me:17005: checking statvfs64 function (SVR4)" >&5
17006 echo $ECHO_N "checking statvfs64 function (SVR4)... $ECHO_C" >&6
17007 if test "${fu_cv_sys_stat_statvfs64+set}" = set; then
17008   echo $ECHO_N "(cached) $ECHO_C" >&6
17009 else
17010   if test "$cross_compiling" = yes; then
17011   fu_cv_sys_stat_statvfs64=cross
17012 else
17013   cat >conftest.$ac_ext <<_ACEOF
17014 #line 17014 "configure"
17015 #include "confdefs.h"
17016
17017 #if defined(HAVE_UNISTD_H)
17018 #include <unistd.h>
17019 #endif
17020 #include <sys/types.h>
17021 #include <sys/statvfs.h>
17022   main ()
17023   {
17024     struct statvfs64 fsd;
17025     exit (statvfs64 (".", &fsd));
17026   }
17027 _ACEOF
17028 rm -f conftest$ac_exeext
17029 if { (eval echo "$as_me:17029: \"$ac_link\"") >&5
17030   (eval $ac_link) 2>&5
17031   ac_status=$?
17032   echo "$as_me:17032: \$? = $ac_status" >&5
17033   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17034   { (eval echo "$as_me:17034: \"$ac_try\"") >&5
17035   (eval $ac_try) 2>&5
17036   ac_status=$?
17037   echo "$as_me:17037: \$? = $ac_status" >&5
17038   (exit $ac_status); }; }; then
17039   fu_cv_sys_stat_statvfs64=yes
17040 else
17041   echo "$as_me: program exited with status $ac_status" >&5
17042 echo "$as_me: failed program was:" >&5
17043 cat conftest.$ac_ext >&5
17044 fu_cv_sys_stat_statvfs64=no
17045 fi
17046 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17047 fi
17048 fi
17049 echo "$as_me:17049: result: $fu_cv_sys_stat_statvfs64" >&5
17050 echo "${ECHO_T}$fu_cv_sys_stat_statvfs64" >&6
17051   if test $fu_cv_sys_stat_statvfs64 = yes; then
17052     space=yes
17053     cat >>confdefs.h <<\EOF
17054 #define STAT_STATVFS64 1
17055 EOF
17056
17057   fi
17058 fi
17059
17060 # Perform only the link test since it seems there are no variants of the
17061 # statvfs function.  This check is more than just AC_CHECK_FUNCS(statvfs)
17062 # because that got a false positive on SCO OSR5.  Adding the declaration
17063 # of a `struct statvfs' causes this test to fail (as it should) on such
17064 # systems.  That system is reported to work fine with STAT_STATFS4 which
17065 # is what it gets when this test fails.
17066 if test $space = no; then
17067   # SVR4
17068   echo "$as_me:17068: checking statvfs function (SVR4)" >&5
17069 echo $ECHO_N "checking statvfs function (SVR4)... $ECHO_C" >&6
17070 if test "${fu_cv_sys_stat_statvfs+set}" = set; then
17071   echo $ECHO_N "(cached) $ECHO_C" >&6
17072 else
17073   cat >conftest.$ac_ext <<_ACEOF
17074 #line 17074 "configure"
17075 #include "confdefs.h"
17076 #include <sys/types.h>
17077 #include <sys/statvfs.h>
17078 int
17079 main ()
17080 {
17081 struct statvfs fsd; statvfs (0, &fsd);
17082   ;
17083   return 0;
17084 }
17085 _ACEOF
17086 rm -f conftest.$ac_objext conftest$ac_exeext
17087 if { (eval echo "$as_me:17087: \"$ac_link\"") >&5
17088   (eval $ac_link) 2>&5
17089   ac_status=$?
17090   echo "$as_me:17090: \$? = $ac_status" >&5
17091   (exit $ac_status); } &&
17092          { ac_try='test -s conftest$ac_exeext'
17093   { (eval echo "$as_me:17093: \"$ac_try\"") >&5
17094   (eval $ac_try) 2>&5
17095   ac_status=$?
17096   echo "$as_me:17096: \$? = $ac_status" >&5
17097   (exit $ac_status); }; }; then
17098   fu_cv_sys_stat_statvfs=yes
17099 else
17100   echo "$as_me: failed program was:" >&5
17101 cat conftest.$ac_ext >&5
17102 fu_cv_sys_stat_statvfs=no
17103 fi
17104 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17105 fi
17106 echo "$as_me:17106: result: $fu_cv_sys_stat_statvfs" >&5
17107 echo "${ECHO_T}$fu_cv_sys_stat_statvfs" >&6
17108   if test $fu_cv_sys_stat_statvfs = yes; then
17109     space=yes
17110     cat >>confdefs.h <<\EOF
17111 #define STAT_STATVFS 1
17112 EOF
17113
17114   fi
17115 fi
17116
17117 if test $space = no; then
17118   # DEC Alpha running OSF/1
17119   echo "$as_me:17119: checking for 3-argument statfs function (DEC OSF/1)" >&5
17120 echo $ECHO_N "checking for 3-argument statfs function (DEC OSF/1)... $ECHO_C" >&6
17121   if test "${fu_cv_sys_stat_statfs3_osf1+set}" = set; then
17122   echo $ECHO_N "(cached) $ECHO_C" >&6
17123 else
17124   if test "$cross_compiling" = yes; then
17125   fu_cv_sys_stat_statfs3_osf1=no
17126 else
17127   cat >conftest.$ac_ext <<_ACEOF
17128 #line 17128 "configure"
17129 #include "confdefs.h"
17130
17131 #include <sys/param.h>
17132 #include <sys/types.h>
17133 #include <sys/mount.h>
17134   main ()
17135   {
17136     struct statfs fsd;
17137     fsd.f_fsize = 0;
17138     exit (statfs (".", &fsd, sizeof (struct statfs)));
17139   }
17140 _ACEOF
17141 rm -f conftest$ac_exeext
17142 if { (eval echo "$as_me:17142: \"$ac_link\"") >&5
17143   (eval $ac_link) 2>&5
17144   ac_status=$?
17145   echo "$as_me:17145: \$? = $ac_status" >&5
17146   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17147   { (eval echo "$as_me:17147: \"$ac_try\"") >&5
17148   (eval $ac_try) 2>&5
17149   ac_status=$?
17150   echo "$as_me:17150: \$? = $ac_status" >&5
17151   (exit $ac_status); }; }; then
17152   fu_cv_sys_stat_statfs3_osf1=yes
17153 else
17154   echo "$as_me: program exited with status $ac_status" >&5
17155 echo "$as_me: failed program was:" >&5
17156 cat conftest.$ac_ext >&5
17157 fu_cv_sys_stat_statfs3_osf1=no
17158 fi
17159 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17160 fi
17161 fi
17162
17163   echo "$as_me:17163: result: $fu_cv_sys_stat_statfs3_osf1" >&5
17164 echo "${ECHO_T}$fu_cv_sys_stat_statfs3_osf1" >&6
17165   if test $fu_cv_sys_stat_statfs3_osf1 = yes; then
17166     space=yes
17167     cat >>confdefs.h <<\EOF
17168 #define STAT_STATFS3_OSF1 1
17169 EOF
17170
17171   fi
17172 fi
17173
17174 if test $space = no; then
17175 # AIX
17176   echo "$as_me:17176: checking for two-argument statfs with statfs.bsize member (AIX, 4.3BSD)" >&5
17177 echo $ECHO_N "checking for two-argument statfs with statfs.bsize member (AIX, 4.3BSD)... $ECHO_C" >&6
17178   if test "${fu_cv_sys_stat_statfs2_bsize+set}" = set; then
17179   echo $ECHO_N "(cached) $ECHO_C" >&6
17180 else
17181   if test "$cross_compiling" = yes; then
17182   fu_cv_sys_stat_statfs2_bsize=no
17183 else
17184   cat >conftest.$ac_ext <<_ACEOF
17185 #line 17185 "configure"
17186 #include "confdefs.h"
17187
17188 #ifdef HAVE_SYS_PARAM_H
17189 #include <sys/param.h>
17190 #endif
17191 #ifdef HAVE_SYS_MOUNT_H
17192 #include <sys/mount.h>
17193 #endif
17194 #ifdef HAVE_SYS_VFS_H
17195 #include <sys/vfs.h>
17196 #endif
17197   main ()
17198   {
17199   struct statfs fsd;
17200   fsd.f_bsize = 0;
17201   exit (statfs (".", &fsd));
17202   }
17203 _ACEOF
17204 rm -f conftest$ac_exeext
17205 if { (eval echo "$as_me:17205: \"$ac_link\"") >&5
17206   (eval $ac_link) 2>&5
17207   ac_status=$?
17208   echo "$as_me:17208: \$? = $ac_status" >&5
17209   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17210   { (eval echo "$as_me:17210: \"$ac_try\"") >&5
17211   (eval $ac_try) 2>&5
17212   ac_status=$?
17213   echo "$as_me:17213: \$? = $ac_status" >&5
17214   (exit $ac_status); }; }; then
17215   fu_cv_sys_stat_statfs2_bsize=yes
17216 else
17217   echo "$as_me: program exited with status $ac_status" >&5
17218 echo "$as_me: failed program was:" >&5
17219 cat conftest.$ac_ext >&5
17220 fu_cv_sys_stat_statfs2_bsize=no
17221 fi
17222 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17223 fi
17224 fi
17225
17226   echo "$as_me:17226: result: $fu_cv_sys_stat_statfs2_bsize" >&5
17227 echo "${ECHO_T}$fu_cv_sys_stat_statfs2_bsize" >&6
17228   if test $fu_cv_sys_stat_statfs2_bsize = yes; then
17229     space=yes
17230     cat >>confdefs.h <<\EOF
17231 #define STAT_STATFS2_BSIZE 1
17232 EOF
17233
17234   fi
17235 fi
17236
17237 if test $space = no; then
17238 # SVR3
17239   echo "$as_me:17239: checking for four-argument statfs (AIX-3.2.5, SVR3)" >&5
17240 echo $ECHO_N "checking for four-argument statfs (AIX-3.2.5, SVR3)... $ECHO_C" >&6
17241   if test "${fu_cv_sys_stat_statfs4+set}" = set; then
17242   echo $ECHO_N "(cached) $ECHO_C" >&6
17243 else
17244   if test "$cross_compiling" = yes; then
17245   fu_cv_sys_stat_statfs4=no
17246 else
17247   cat >conftest.$ac_ext <<_ACEOF
17248 #line 17248 "configure"
17249 #include "confdefs.h"
17250 #include <sys/types.h>
17251 #include <sys/statfs.h>
17252   main ()
17253   {
17254   struct statfs fsd;
17255   exit (statfs (".", &fsd, sizeof fsd, 0));
17256   }
17257 _ACEOF
17258 rm -f conftest$ac_exeext
17259 if { (eval echo "$as_me:17259: \"$ac_link\"") >&5
17260   (eval $ac_link) 2>&5
17261   ac_status=$?
17262   echo "$as_me:17262: \$? = $ac_status" >&5
17263   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17264   { (eval echo "$as_me:17264: \"$ac_try\"") >&5
17265   (eval $ac_try) 2>&5
17266   ac_status=$?
17267   echo "$as_me:17267: \$? = $ac_status" >&5
17268   (exit $ac_status); }; }; then
17269   fu_cv_sys_stat_statfs4=yes
17270 else
17271   echo "$as_me: program exited with status $ac_status" >&5
17272 echo "$as_me: failed program was:" >&5
17273 cat conftest.$ac_ext >&5
17274 fu_cv_sys_stat_statfs4=no
17275 fi
17276 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17277 fi
17278 fi
17279
17280   echo "$as_me:17280: result: $fu_cv_sys_stat_statfs4" >&5
17281 echo "${ECHO_T}$fu_cv_sys_stat_statfs4" >&6
17282   if test $fu_cv_sys_stat_statfs4 = yes; then
17283     space=yes
17284     cat >>confdefs.h <<\EOF
17285 #define STAT_STATFS4 1
17286 EOF
17287
17288   fi
17289 fi
17290
17291 if test $space = no; then
17292 # 4.4BSD and NetBSD
17293   echo "$as_me:17293: checking for two-argument statfs with statfs.fsize member (4.4BSD and NetBSD)" >&5
17294 echo $ECHO_N "checking for two-argument statfs with statfs.fsize member (4.4BSD and NetBSD)... $ECHO_C" >&6
17295   if test "${fu_cv_sys_stat_statfs2_fsize+set}" = set; then
17296   echo $ECHO_N "(cached) $ECHO_C" >&6
17297 else
17298   if test "$cross_compiling" = yes; then
17299   fu_cv_sys_stat_statfs2_fsize=no
17300 else
17301   cat >conftest.$ac_ext <<_ACEOF
17302 #line 17302 "configure"
17303 #include "confdefs.h"
17304 #include <sys/types.h>
17305 #ifdef HAVE_SYS_PARAM_H
17306 #include <sys/param.h>
17307 #endif
17308 #ifdef HAVE_SYS_MOUNT_H
17309 #include <sys/mount.h>
17310 #endif
17311   main ()
17312   {
17313   struct statfs fsd;
17314   fsd.f_fsize = 0;
17315   exit (statfs (".", &fsd));
17316   }
17317 _ACEOF
17318 rm -f conftest$ac_exeext
17319 if { (eval echo "$as_me:17319: \"$ac_link\"") >&5
17320   (eval $ac_link) 2>&5
17321   ac_status=$?
17322   echo "$as_me:17322: \$? = $ac_status" >&5
17323   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17324   { (eval echo "$as_me:17324: \"$ac_try\"") >&5
17325   (eval $ac_try) 2>&5
17326   ac_status=$?
17327   echo "$as_me:17327: \$? = $ac_status" >&5
17328   (exit $ac_status); }; }; then
17329   fu_cv_sys_stat_statfs2_fsize=yes
17330 else
17331   echo "$as_me: program exited with status $ac_status" >&5
17332 echo "$as_me: failed program was:" >&5
17333 cat conftest.$ac_ext >&5
17334 fu_cv_sys_stat_statfs2_fsize=no
17335 fi
17336 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17337 fi
17338 fi
17339
17340   echo "$as_me:17340: result: $fu_cv_sys_stat_statfs2_fsize" >&5
17341 echo "${ECHO_T}$fu_cv_sys_stat_statfs2_fsize" >&6
17342   if test $fu_cv_sys_stat_statfs2_fsize = yes; then
17343     space=yes
17344     cat >>confdefs.h <<\EOF
17345 #define STAT_STATFS2_FSIZE 1
17346 EOF
17347
17348   fi
17349 fi
17350
17351 if test $space = no; then
17352   # Ultrix
17353   echo "$as_me:17353: checking for two-argument statfs with struct fs_data (Ultrix)" >&5
17354 echo $ECHO_N "checking for two-argument statfs with struct fs_data (Ultrix)... $ECHO_C" >&6
17355   if test "${fu_cv_sys_stat_fs_data+set}" = set; then
17356   echo $ECHO_N "(cached) $ECHO_C" >&6
17357 else
17358   if test "$cross_compiling" = yes; then
17359   fu_cv_sys_stat_fs_data=no
17360 else
17361   cat >conftest.$ac_ext <<_ACEOF
17362 #line 17362 "configure"
17363 #include "confdefs.h"
17364 #include <sys/types.h>
17365 #ifdef HAVE_SYS_PARAM_H
17366 #include <sys/param.h>
17367 #endif
17368 #ifdef HAVE_SYS_MOUNT_H
17369 #include <sys/mount.h>
17370 #endif
17371 #ifdef HAVE_SYS_FS_TYPES_H
17372 #include <sys/fs_types.h>
17373 #endif
17374   main ()
17375   {
17376   struct fs_data fsd;
17377   /* Ultrix's statfs returns 1 for success,
17378      0 for not mounted, -1 for failure.  */
17379   exit (statfs (".", &fsd) != 1);
17380   }
17381 _ACEOF
17382 rm -f conftest$ac_exeext
17383 if { (eval echo "$as_me:17383: \"$ac_link\"") >&5
17384   (eval $ac_link) 2>&5
17385   ac_status=$?
17386   echo "$as_me:17386: \$? = $ac_status" >&5
17387   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17388   { (eval echo "$as_me:17388: \"$ac_try\"") >&5
17389   (eval $ac_try) 2>&5
17390   ac_status=$?
17391   echo "$as_me:17391: \$? = $ac_status" >&5
17392   (exit $ac_status); }; }; then
17393   fu_cv_sys_stat_fs_data=yes
17394 else
17395   echo "$as_me: program exited with status $ac_status" >&5
17396 echo "$as_me: failed program was:" >&5
17397 cat conftest.$ac_ext >&5
17398 fu_cv_sys_stat_fs_data=no
17399 fi
17400 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17401 fi
17402 fi
17403
17404   echo "$as_me:17404: result: $fu_cv_sys_stat_fs_data" >&5
17405 echo "${ECHO_T}$fu_cv_sys_stat_fs_data" >&6
17406   if test $fu_cv_sys_stat_fs_data = yes; then
17407     space=yes
17408     cat >>confdefs.h <<\EOF
17409 #define STAT_STATFS2_FS_DATA 1
17410 EOF
17411
17412   fi
17413 fi
17414
17415 #
17416 # As a gating factor for large file support, in order to
17417 # use <4GB files we must have the following minimal support
17418 # available.
17419 # long long, and a 64 bit off_t or off64_t.
17420 # If we don't have all of these then disable large
17421 # file support.
17422 #
17423 echo "$as_me:17423: checking if large file support can be enabled" >&5
17424 echo $ECHO_N "checking if large file support can be enabled... $ECHO_C" >&6
17425 cat >conftest.$ac_ext <<_ACEOF
17426 #line 17426 "configure"
17427 #include "confdefs.h"
17428
17429 #if defined(HAVE_LONGLONG) && (defined(HAVE_OFF64_T) || (defined(SIZEOF_OFF_T) && (SIZEOF_OFF_T == 8)))
17430 #include <sys/types.h>
17431 #else
17432 __COMPILE_ERROR_
17433 #endif
17434
17435 int
17436 main ()
17437 {
17438 int i
17439   ;
17440   return 0;
17441 }
17442 _ACEOF
17443 rm -f conftest.$ac_objext
17444 if { (eval echo "$as_me:17444: \"$ac_compile\"") >&5
17445   (eval $ac_compile) 2>&5
17446   ac_status=$?
17447   echo "$as_me:17447: \$? = $ac_status" >&5
17448   (exit $ac_status); } &&
17449          { ac_try='test -s conftest.$ac_objext'
17450   { (eval echo "$as_me:17450: \"$ac_try\"") >&5
17451   (eval $ac_try) 2>&5
17452   ac_status=$?
17453   echo "$as_me:17453: \$? = $ac_status" >&5
17454   (exit $ac_status); }; }; then
17455   samba_cv_HAVE_EXPLICIT_LARGEFILE_SUPPORT=yes
17456 else
17457   echo "$as_me: failed program was:" >&5
17458 cat conftest.$ac_ext >&5
17459 samba_cv_HAVE_EXPLICIT_LARGEFILE_SUPPORT=no
17460 fi
17461 rm -f conftest.$ac_objext conftest.$ac_ext
17462 if test x"$samba_cv_HAVE_EXPLICIT_LARGEFILE_SUPPORT" = x"yes"; then
17463     cat >>confdefs.h <<\EOF
17464 #define HAVE_EXPLICIT_LARGEFILE_SUPPORT 1
17465 EOF
17466
17467 fi
17468 echo "$as_me:17468: result: $samba_cv_HAVE_EXPLICIT_LARGEFILE_SUPPORT" >&5
17469 echo "${ECHO_T}$samba_cv_HAVE_EXPLICIT_LARGEFILE_SUPPORT" >&6
17470
17471 # Check whether --with-spinlocks or --without-spinlocks was given.
17472 if test "${with_spinlocks+set}" = set; then
17473   withval="$with_spinlocks"
17474
17475 fi;
17476 if test "x$with_spinlocks" = "xyes"; then
17477     cat >>confdefs.h <<\EOF
17478 #define USE_SPINLOCKS 1
17479 EOF
17480
17481     case "$host_cpu" in
17482         sparc)
17483             cat >>confdefs.h <<\EOF
17484 #define SPARC_SPINLOCKS 1
17485 EOF
17486
17487             ;;
17488
17489         i386|i486|i586|i686)
17490             cat >>confdefs.h <<\EOF
17491 #define INTEL_SPINLOCKS 1
17492 EOF
17493
17494             ;;
17495
17496         mips)
17497             cat >>confdefs.h <<\EOF
17498 #define MIPS_SPINLOCKS 1
17499 EOF
17500
17501             ;;
17502
17503         powerpc)
17504             cat >>confdefs.h <<\EOF
17505 #define POWERPC_SPINLOCKS 1
17506 EOF
17507
17508             ;;
17509     esac
17510 fi
17511
17512 #################################################
17513 # check for ACL support
17514
17515 echo "$as_me:17515: checking whether to support ACLs" >&5
17516 echo $ECHO_N "checking whether to support ACLs... $ECHO_C" >&6
17517
17518 # Check whether --with-acl-support or --without-acl-support was given.
17519 if test "${with_acl_support+set}" = set; then
17520   withval="$with_acl_support"
17521    case "$withval" in
17522   yes)
17523
17524         case "$host_os" in
17525         *sysv5*)
17526             echo "$as_me:17526: result: Using UnixWare ACLs" >&5
17527 echo "${ECHO_T}Using UnixWare ACLs" >&6
17528             cat >>confdefs.h <<\EOF
17529 #define HAVE_UNIXWARE_ACLS 1
17530 EOF
17531
17532             ;;
17533         *solaris*)
17534             echo "$as_me:17534: result: Using solaris ACLs" >&5
17535 echo "${ECHO_T}Using solaris ACLs" >&6
17536             cat >>confdefs.h <<\EOF
17537 #define HAVE_SOLARIS_ACLS 1
17538 EOF
17539
17540             ;;
17541                 *irix*)
17542                         echo "$as_me:17542: result: Using IRIX ACLs" >&5
17543 echo "${ECHO_T}Using IRIX ACLs" >&6
17544                         cat >>confdefs.h <<\EOF
17545 #define HAVE_IRIX_ACLS 1
17546 EOF
17547
17548                         ;;
17549                 *aix*)
17550                         echo "$as_me:17550: result: Using AIX ACLs" >&5
17551 echo "${ECHO_T}Using AIX ACLs" >&6
17552                         cat >>confdefs.h <<\EOF
17553 #define HAVE_AIX_ACLS 1
17554 EOF
17555
17556                         ;;
17557                 *osf*)
17558                         echo "$as_me:17558: result: Using Tru64 ACLs" >&5
17559 echo "${ECHO_T}Using Tru64 ACLs" >&6
17560                         cat >>confdefs.h <<\EOF
17561 #define HAVE_TRU64_ACLS 1
17562 EOF
17563
17564                         LIBS="$LIBS -lpacl"
17565                         ;;
17566         *)
17567
17568 echo "$as_me:17568: checking for acl_get_file in -lacl" >&5
17569 echo $ECHO_N "checking for acl_get_file in -lacl... $ECHO_C" >&6
17570 if test "${ac_cv_lib_acl_acl_get_file+set}" = set; then
17571   echo $ECHO_N "(cached) $ECHO_C" >&6
17572 else
17573   ac_check_lib_save_LIBS=$LIBS
17574 LIBS="-lacl  $LIBS"
17575 cat >conftest.$ac_ext <<_ACEOF
17576 #line 17576 "configure"
17577 #include "confdefs.h"
17578
17579 /* Override any gcc2 internal prototype to avoid an error.  */
17580 #ifdef __cplusplus
17581 extern "C"
17582 #endif
17583 /* We use char because int might match the return type of a gcc2
17584    builtin and then its argument prototype would still apply.  */
17585 char acl_get_file ();
17586 int
17587 main ()
17588 {
17589 acl_get_file ();
17590   ;
17591   return 0;
17592 }
17593 _ACEOF
17594 rm -f conftest.$ac_objext conftest$ac_exeext
17595 if { (eval echo "$as_me:17595: \"$ac_link\"") >&5
17596   (eval $ac_link) 2>&5
17597   ac_status=$?
17598   echo "$as_me:17598: \$? = $ac_status" >&5
17599   (exit $ac_status); } &&
17600          { ac_try='test -s conftest$ac_exeext'
17601   { (eval echo "$as_me:17601: \"$ac_try\"") >&5
17602   (eval $ac_try) 2>&5
17603   ac_status=$?
17604   echo "$as_me:17604: \$? = $ac_status" >&5
17605   (exit $ac_status); }; }; then
17606   ac_cv_lib_acl_acl_get_file=yes
17607 else
17608   echo "$as_me: failed program was:" >&5
17609 cat conftest.$ac_ext >&5
17610 ac_cv_lib_acl_acl_get_file=no
17611 fi
17612 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17613 LIBS=$ac_check_lib_save_LIBS
17614 fi
17615 echo "$as_me:17615: result: $ac_cv_lib_acl_acl_get_file" >&5
17616 echo "${ECHO_T}$ac_cv_lib_acl_acl_get_file" >&6
17617 if test $ac_cv_lib_acl_acl_get_file = yes; then
17618   cat >>confdefs.h <<EOF
17619 #define HAVE_LIBACL 1
17620 EOF
17621
17622   LIBS="-lacl $LIBS"
17623
17624 fi
17625
17626                         echo "$as_me:17626: checking for ACL support" >&5
17627 echo $ECHO_N "checking for ACL support... $ECHO_C" >&6
17628 if test "${samba_cv_HAVE_POSIX_ACLS+set}" = set; then
17629   echo $ECHO_N "(cached) $ECHO_C" >&6
17630 else
17631
17632                         cat >conftest.$ac_ext <<_ACEOF
17633 #line 17633 "configure"
17634 #include "confdefs.h"
17635 #include <sys/types.h>
17636 #include <sys/acl.h>
17637 int
17638 main ()
17639 {
17640  acl_t acl; int entry_id; acl_entry_t *entry_p; return acl_get_entry( acl, entry_id, entry_p);
17641   ;
17642   return 0;
17643 }
17644 _ACEOF
17645 rm -f conftest.$ac_objext conftest$ac_exeext
17646 if { (eval echo "$as_me:17646: \"$ac_link\"") >&5
17647   (eval $ac_link) 2>&5
17648   ac_status=$?
17649   echo "$as_me:17649: \$? = $ac_status" >&5
17650   (exit $ac_status); } &&
17651          { ac_try='test -s conftest$ac_exeext'
17652   { (eval echo "$as_me:17652: \"$ac_try\"") >&5
17653   (eval $ac_try) 2>&5
17654   ac_status=$?
17655   echo "$as_me:17655: \$? = $ac_status" >&5
17656   (exit $ac_status); }; }; then
17657   samba_cv_HAVE_POSIX_ACLS=yes
17658 else
17659   echo "$as_me: failed program was:" >&5
17660 cat conftest.$ac_ext >&5
17661 samba_cv_HAVE_POSIX_ACLS=no
17662 fi
17663 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17664 fi
17665 echo "$as_me:17665: result: $samba_cv_HAVE_POSIX_ACLS" >&5
17666 echo "${ECHO_T}$samba_cv_HAVE_POSIX_ACLS" >&6
17667                         if test x"$samba_cv_HAVE_POSIX_ACLS" = x"yes"; then
17668                                 echo "$as_me:17668: result: Using posix ACLs" >&5
17669 echo "${ECHO_T}Using posix ACLs" >&6
17670                                 cat >>confdefs.h <<\EOF
17671 #define HAVE_POSIX_ACLS 1
17672 EOF
17673
17674                                 echo "$as_me:17674: checking for acl_get_perm_np" >&5
17675 echo $ECHO_N "checking for acl_get_perm_np... $ECHO_C" >&6
17676 if test "${samba_cv_HAVE_ACL_GET_PERM_NP+set}" = set; then
17677   echo $ECHO_N "(cached) $ECHO_C" >&6
17678 else
17679
17680                                 cat >conftest.$ac_ext <<_ACEOF
17681 #line 17681 "configure"
17682 #include "confdefs.h"
17683 #include <sys/types.h>
17684 #include <sys/acl.h>
17685 int
17686 main ()
17687 {
17688  acl_permset_t permset_d; acl_perm_t perm; return acl_get_perm_np( permset_d, perm);
17689   ;
17690   return 0;
17691 }
17692 _ACEOF
17693 rm -f conftest.$ac_objext conftest$ac_exeext
17694 if { (eval echo "$as_me:17694: \"$ac_link\"") >&5
17695   (eval $ac_link) 2>&5
17696   ac_status=$?
17697   echo "$as_me:17697: \$? = $ac_status" >&5
17698   (exit $ac_status); } &&
17699          { ac_try='test -s conftest$ac_exeext'
17700   { (eval echo "$as_me:17700: \"$ac_try\"") >&5
17701   (eval $ac_try) 2>&5
17702   ac_status=$?
17703   echo "$as_me:17703: \$? = $ac_status" >&5
17704   (exit $ac_status); }; }; then
17705   samba_cv_HAVE_ACL_GET_PERM_NP=yes
17706 else
17707   echo "$as_me: failed program was:" >&5
17708 cat conftest.$ac_ext >&5
17709 samba_cv_HAVE_ACL_GET_PERM_NP=no
17710 fi
17711 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17712 fi
17713 echo "$as_me:17713: result: $samba_cv_HAVE_ACL_GET_PERM_NP" >&5
17714 echo "${ECHO_T}$samba_cv_HAVE_ACL_GET_PERM_NP" >&6
17715                                 if test x"$samba_cv_HAVE_ACL_GET_PERM_NP" = x"yes"; then
17716                                         cat >>confdefs.h <<\EOF
17717 #define HAVE_ACL_GET_PERM_NP 1
17718 EOF
17719
17720                                 fi
17721                         fi
17722             ;;
17723         esac
17724         ;;
17725   *)
17726     echo "$as_me:17726: result: no" >&5
17727 echo "${ECHO_T}no" >&6
17728     cat >>confdefs.h <<\EOF
17729 #define HAVE_NO_ACLS 1
17730 EOF
17731
17732     ;;
17733   esac
17734 else
17735   cat >>confdefs.h <<\EOF
17736 #define HAVE_NO_ACLS 1
17737 EOF
17738
17739   echo "$as_me:17739: result: no" >&5
17740 echo "${ECHO_T}no" >&6
17741
17742 fi;
17743
17744 #################################################
17745 # Check whether winbind is supported on this platform.  If so we need to
17746 # build and install client programs (WINBIND_TARGETS), sbin programs
17747 # (WINBIND_STARGETS) and shared libraries (WINBIND_LTARGETS).
17748
17749 echo "$as_me:17749: checking whether to build winbind" >&5
17750 echo $ECHO_N "checking whether to build winbind... $ECHO_C" >&6
17751
17752 # Initially, the value of $host_os decides whether winbind is supported
17753
17754 case "$host_os" in
17755         *linux*|*solaris*)
17756                 HAVE_WINBIND=yes
17757                 ;;
17758         *)
17759                 HAVE_WINBIND=no
17760                 winbind_no_reason=", unsupported on $host_os"
17761                 ;;
17762 esac
17763
17764 # Check the setting of --with-winbindd
17765
17766 # Check whether --with-winbind or --without-winbind was given.
17767 if test "${with_winbind+set}" = set; then
17768   withval="$with_winbind"
17769
17770   case "$withval" in
17771         yes)
17772                 HAVE_WINBIND=yes
17773                 ;;
17774         no)
17775                 HAVE_WINBIND=no
17776                 winbind_reason=""
17777                 ;;
17778   esac
17779 fi;
17780
17781 # We need unix domain sockets for winbind
17782
17783 if test x"$HAVE_WINBIND" = x"yes"; then
17784         if test x"$samba_cv_unixsocket" = x"no"; then
17785                 winbind_no_reason=", no unix domain socket support on $host_os"
17786                 HAVE_WINBIND=no
17787         fi
17788 fi
17789
17790 # Display test results
17791
17792 if test x"$HAVE_WINBIND" = x"yes"; then
17793
17794         echo "$as_me:17794: result: yes" >&5
17795 echo "${ECHO_T}yes" >&6
17796
17797         WINBIND_TARGETS="bin/wbinfo"
17798         WINBIND_STARGETS="bin/winbindd"
17799         WINBIND_LTARGETS="nsswitch/libnss_winbind.so"
17800         case "$with_pam" in
17801                 yes)
17802                         WINBIND_PAM_TARGETS="nsswitch/pam_winbind.so"
17803                 ;;
17804         esac
17805 else
17806         echo "$as_me:17806: result: no$winbind_no_reason" >&5
17807 echo "${ECHO_T}no$winbind_no_reason" >&6
17808
17809         WINBIND_TARGETS=""
17810         WINBIND_STARGETS=""
17811         WINBIND_LTARGETS=""
17812         WINBIND_PAM_PROGS=""
17813 fi
17814
17815 # Substitution time!
17816
17817 #################################################
17818 # Check to see if we should use the included popt
17819
17820 # Check whether --with-included-popt or --without-included-popt was given.
17821 if test "${with_included_popt+set}" = set; then
17822   withval="$with_included_popt"
17823
17824   case "$withval" in
17825         yes)
17826                 INCLUDED_POPT=yes
17827                 ;;
17828         no)
17829                 INCLUDED_POPT=no
17830                 ;;
17831   esac
17832 fi;
17833 if test x"$INCLUDED_POPT" != x"yes"; then
17834     echo "$as_me:17834: checking for poptGetContext in -lpopt" >&5
17835 echo $ECHO_N "checking for poptGetContext in -lpopt... $ECHO_C" >&6
17836 if test "${ac_cv_lib_popt_poptGetContext+set}" = set; then
17837   echo $ECHO_N "(cached) $ECHO_C" >&6
17838 else
17839   ac_check_lib_save_LIBS=$LIBS
17840 LIBS="-lpopt  $LIBS"
17841 cat >conftest.$ac_ext <<_ACEOF
17842 #line 17842 "configure"
17843 #include "confdefs.h"
17844
17845 /* Override any gcc2 internal prototype to avoid an error.  */
17846 #ifdef __cplusplus
17847 extern "C"
17848 #endif
17849 /* We use char because int might match the return type of a gcc2
17850    builtin and then its argument prototype would still apply.  */
17851 char poptGetContext ();
17852 int
17853 main ()
17854 {
17855 poptGetContext ();
17856   ;
17857   return 0;
17858 }
17859 _ACEOF
17860 rm -f conftest.$ac_objext conftest$ac_exeext
17861 if { (eval echo "$as_me:17861: \"$ac_link\"") >&5
17862   (eval $ac_link) 2>&5
17863   ac_status=$?
17864   echo "$as_me:17864: \$? = $ac_status" >&5
17865   (exit $ac_status); } &&
17866          { ac_try='test -s conftest$ac_exeext'
17867   { (eval echo "$as_me:17867: \"$ac_try\"") >&5
17868   (eval $ac_try) 2>&5
17869   ac_status=$?
17870   echo "$as_me:17870: \$? = $ac_status" >&5
17871   (exit $ac_status); }; }; then
17872   ac_cv_lib_popt_poptGetContext=yes
17873 else
17874   echo "$as_me: failed program was:" >&5
17875 cat conftest.$ac_ext >&5
17876 ac_cv_lib_popt_poptGetContext=no
17877 fi
17878 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17879 LIBS=$ac_check_lib_save_LIBS
17880 fi
17881 echo "$as_me:17881: result: $ac_cv_lib_popt_poptGetContext" >&5
17882 echo "${ECHO_T}$ac_cv_lib_popt_poptGetContext" >&6
17883 if test $ac_cv_lib_popt_poptGetContext = yes; then
17884   INCLUDED_POPT=no
17885 else
17886   INCLUDED_POPT=yes
17887 fi
17888
17889 fi
17890
17891 echo "$as_me:17891: checking whether to use included popt" >&5
17892 echo $ECHO_N "checking whether to use included popt... $ECHO_C" >&6
17893 if test x"$INCLUDED_POPT" = x"yes"; then
17894     echo "$as_me:17894: result: $srcdir/popt" >&5
17895 echo "${ECHO_T}$srcdir/popt" >&6
17896     BUILD_POPT='$(POPT_OBJS)'
17897     FLAGS1="-I$srcdir/popt"
17898 else
17899     echo "$as_me:17899: result: no" >&5
17900 echo "${ECHO_T}no" >&6
17901     LIBS="$LIBS -lpopt"
17902 fi
17903
17904 #################################################
17905 # final configure stuff
17906
17907 echo "checking configure summary"
17908 if test "$cross_compiling" = yes; then
17909   :
17910 else
17911   cat >conftest.$ac_ext <<_ACEOF
17912 #line 17912 "configure"
17913 #include "confdefs.h"
17914 #include "${srcdir-.}/tests/summary.c"
17915 _ACEOF
17916 rm -f conftest$ac_exeext
17917 if { (eval echo "$as_me:17917: \"$ac_link\"") >&5
17918   (eval $ac_link) 2>&5
17919   ac_status=$?
17920   echo "$as_me:17920: \$? = $ac_status" >&5
17921   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17922   { (eval echo "$as_me:17922: \"$ac_try\"") >&5
17923   (eval $ac_try) 2>&5
17924   ac_status=$?
17925   echo "$as_me:17925: \$? = $ac_status" >&5
17926   (exit $ac_status); }; }; then
17927   echo "configure OK";
17928 else
17929   echo "$as_me: program exited with status $ac_status" >&5
17930 echo "$as_me: failed program was:" >&5
17931 cat conftest.$ac_ext >&5
17932 { { echo "$as_me:17932: error: summary failure. Aborting config" >&5
17933 echo "$as_me: error: summary failure. Aborting config" >&2;}
17934    { (exit 1); exit 1; }; }
17935 fi
17936 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17937 fi
17938
17939 builddir=`pwd`
17940
17941 ac_config_files="$ac_config_files include/stamp-h Makefile"
17942 cat >confcache <<\_ACEOF
17943 # This file is a shell script that caches the results of configure
17944 # tests run on this system so they can be shared between configure
17945 # scripts and configure runs, see configure's option --config-cache.
17946 # It is not useful on other systems.  If it contains results you don't
17947 # want to keep, you may remove or edit it.
17948 #
17949 # config.status only pays attention to the cache file if you give it
17950 # the --recheck option to rerun configure.
17951 #
17952 # `ac_cv_env_foo' variables (set or unset) will be overriden when
17953 # loading this file, other *unset* `ac_cv_foo' will be assigned the
17954 # following values.
17955
17956 _ACEOF
17957
17958 # The following way of writing the cache mishandles newlines in values,
17959 # but we know of no workaround that is simple, portable, and efficient.
17960 # So, don't put newlines in cache variables' values.
17961 # Ultrix sh set writes to stderr and can't be redirected directly,
17962 # and sets the high bit in the cache file unless we assign to the vars.
17963 {
17964   (set) 2>&1 |
17965     case `(ac_space=' '; set | grep ac_space) 2>&1` in
17966     *ac_space=\ *)
17967       # `set' does not quote correctly, so add quotes (double-quote
17968       # substitution turns \\\\ into \\, and sed turns \\ into \).
17969       sed -n \
17970         "s/'/'\\\\''/g;
17971           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
17972       ;;
17973     *)
17974       # `set' quotes correctly as required by POSIX, so do not add quotes.
17975       sed -n \
17976         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
17977       ;;
17978     esac;
17979 } |
17980   sed '
17981      t clear
17982      : clear
17983      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
17984      t end
17985      /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
17986      : end' >>confcache
17987 if cmp -s $cache_file confcache; then :; else
17988   if test -w $cache_file; then
17989     test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
17990     cat confcache >$cache_file
17991   else
17992     echo "not updating unwritable cache $cache_file"
17993   fi
17994 fi
17995 rm -f confcache
17996
17997 test "x$prefix" = xNONE && prefix=$ac_default_prefix
17998 # Let make expand exec_prefix.
17999 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
18000
18001 # VPATH may cause trouble with some makes, so we remove $(srcdir),
18002 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
18003 # trailing colons and then remove the whole line if VPATH becomes empty
18004 # (actually we leave an empty line to preserve line numbers).
18005 if test "x$srcdir" = x.; then
18006   ac_vpsub='/^[         ]*VPATH[        ]*=/{
18007 s/:*\$(srcdir):*/:/;
18008 s/:*\${srcdir}:*/:/;
18009 s/:*@srcdir@:*/:/;
18010 s/^\([^=]*=[    ]*\):*/\1/;
18011 s/:*$//;
18012 s/^[^=]*=[      ]*$//;
18013 }'
18014 fi
18015
18016 DEFS=-DHAVE_CONFIG_H
18017
18018 : ${CONFIG_STATUS=./config.status}
18019 ac_clean_files_save=$ac_clean_files
18020 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
18021 { echo "$as_me:18021: creating $CONFIG_STATUS" >&5
18022 echo "$as_me: creating $CONFIG_STATUS" >&6;}
18023 cat >$CONFIG_STATUS <<_ACEOF
18024 #! $SHELL
18025 # Generated automatically by configure.
18026 # Run this file to recreate the current configuration.
18027 # Compiler output produced by configure, useful for debugging
18028 # configure, is in config.log if it exists.
18029
18030 debug=false
18031 SHELL=\${CONFIG_SHELL-$SHELL}
18032 ac_cs_invocation="\$0 \$@"
18033
18034 _ACEOF
18035
18036 cat >>$CONFIG_STATUS <<\_ACEOF
18037 # Be Bourne compatible
18038 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
18039   emulate sh
18040   NULLCMD=:
18041 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
18042   set -o posix
18043 fi
18044
18045 # Name of the executable.
18046 as_me=`echo "$0" |sed 's,.*[\\/],,'`
18047
18048 if expr a : '\(a\)' >/dev/null 2>&1; then
18049   as_expr=expr
18050 else
18051   as_expr=false
18052 fi
18053
18054 rm -f conf$$ conf$$.exe conf$$.file
18055 echo >conf$$.file
18056 if ln -s conf$$.file conf$$ 2>/dev/null; then
18057   # We could just check for DJGPP; but this test a) works b) is more generic
18058   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
18059   if test -f conf$$.exe; then
18060     # Don't use ln at all; we don't have any links
18061     as_ln_s='cp -p'
18062   else
18063     as_ln_s='ln -s'
18064   fi
18065 elif ln conf$$.file conf$$ 2>/dev/null; then
18066   as_ln_s=ln
18067 else
18068   as_ln_s='cp -p'
18069 fi
18070 rm -f conf$$ conf$$.exe conf$$.file
18071
18072 as_executable_p="test -f"
18073
18074 # Support unset when possible.
18075 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
18076   as_unset=unset
18077 else
18078   as_unset=false
18079 fi
18080
18081 # NLS nuisances.
18082 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
18083 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
18084 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
18085 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
18086 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
18087 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
18088 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
18089 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
18090
18091 # IFS
18092 # We need space, tab and new line, in precisely that order.
18093 as_nl='
18094 '
18095 IFS="   $as_nl"
18096
18097 # CDPATH.
18098 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
18099
18100 exec 6>&1
18101
18102 _ACEOF
18103
18104 # Files that config.status was made for.
18105 if test -n "$ac_config_files"; then
18106   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
18107 fi
18108
18109 if test -n "$ac_config_headers"; then
18110   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
18111 fi
18112
18113 if test -n "$ac_config_links"; then
18114   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
18115 fi
18116
18117 if test -n "$ac_config_commands"; then
18118   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
18119 fi
18120
18121 cat >>$CONFIG_STATUS <<\EOF
18122
18123 ac_cs_usage="\
18124 \`$as_me' instantiates files from templates according to the
18125 current configuration.
18126
18127 Usage: $0 [OPTIONS] [FILE]...
18128
18129   -h, --help       print this help, then exit
18130   -V, --version    print version number, then exit
18131   -d, --debug      don't remove temporary files
18132       --recheck    update $as_me by reconfiguring in the same conditions
18133   --file=FILE[:TEMPLATE]
18134                    instantiate the configuration file FILE
18135   --header=FILE[:TEMPLATE]
18136                    instantiate the configuration header FILE
18137
18138 Configuration files:
18139 $config_files
18140
18141 Configuration headers:
18142 $config_headers
18143
18144 Report bugs to <bug-autoconf@gnu.org>."
18145 EOF
18146
18147 cat >>$CONFIG_STATUS <<EOF
18148 ac_cs_version="\\
18149 config.status
18150 configured by $0, generated by GNU Autoconf 2.52,
18151   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
18152
18153 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
18154 Free Software Foundation, Inc.
18155 This config.status script is free software; the Free Software Foundation
18156 gives unlimited permission to copy, distribute and modify it."
18157 srcdir=$srcdir
18158 INSTALL="$INSTALL"
18159 EOF
18160
18161 cat >>$CONFIG_STATUS <<\EOF
18162 # If no file are specified by the user, then we need to provide default
18163 # value.  By we need to know if files were specified by the user.
18164 ac_need_defaults=:
18165 while test $# != 0
18166 do
18167   case $1 in
18168   --*=*)
18169     ac_option=`expr "x$1" : 'x\([^=]*\)='`
18170     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
18171     shift
18172     set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
18173     shift
18174     ;;
18175   -*);;
18176   *) # This is not an option, so the user has probably given explicit
18177      # arguments.
18178      ac_need_defaults=false;;
18179   esac
18180
18181   case $1 in
18182   # Handling of the options.
18183 EOF
18184 cat >>$CONFIG_STATUS <<EOF
18185   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
18186     echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
18187     exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
18188 EOF
18189 cat >>$CONFIG_STATUS <<\EOF
18190   --version | --vers* | -V )
18191     echo "$ac_cs_version"; exit 0 ;;
18192   --he | --h)
18193     # Conflict between --help and --header
18194     { { echo "$as_me:18194: error: ambiguous option: $1
18195 Try \`$0 --help' for more information." >&5
18196 echo "$as_me: error: ambiguous option: $1
18197 Try \`$0 --help' for more information." >&2;}
18198    { (exit 1); exit 1; }; };;
18199   --help | --hel | -h )
18200     echo "$ac_cs_usage"; exit 0 ;;
18201   --debug | --d* | -d )
18202     debug=: ;;
18203   --file | --fil | --fi | --f )
18204     shift
18205     CONFIG_FILES="$CONFIG_FILES $1"
18206     ac_need_defaults=false;;
18207   --header | --heade | --head | --hea )
18208     shift
18209     CONFIG_HEADERS="$CONFIG_HEADERS $1"
18210     ac_need_defaults=false;;
18211
18212   # This is an error.
18213   -*) { { echo "$as_me:18213: error: unrecognized option: $1
18214 Try \`$0 --help' for more information." >&5
18215 echo "$as_me: error: unrecognized option: $1
18216 Try \`$0 --help' for more information." >&2;}
18217    { (exit 1); exit 1; }; } ;;
18218
18219   *) ac_config_targets="$ac_config_targets $1" ;;
18220
18221   esac
18222   shift
18223 done
18224
18225 exec 5>>config.log
18226 cat >&5 << _ACEOF
18227
18228 ## ----------------------- ##
18229 ## Running config.status.  ##
18230 ## ----------------------- ##
18231
18232 This file was extended by $as_me 2.52, executed with
18233   CONFIG_FILES    = $CONFIG_FILES
18234   CONFIG_HEADERS  = $CONFIG_HEADERS
18235   CONFIG_LINKS    = $CONFIG_LINKS
18236   CONFIG_COMMANDS = $CONFIG_COMMANDS
18237   > $ac_cs_invocation
18238 on `(hostname || uname -n) 2>/dev/null | sed 1q`
18239
18240 _ACEOF
18241 EOF
18242
18243 cat >>$CONFIG_STATUS <<\EOF
18244 for ac_config_target in $ac_config_targets
18245 do
18246   case "$ac_config_target" in
18247   # Handling of arguments.
18248   "include/stamp-h" ) CONFIG_FILES="$CONFIG_FILES include/stamp-h" ;;
18249   "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
18250   "include/config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/config.h" ;;
18251   *) { { echo "$as_me:18251: error: invalid argument: $ac_config_target" >&5
18252 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
18253    { (exit 1); exit 1; }; };;
18254   esac
18255 done
18256
18257 # If the user did not use the arguments to specify the items to instantiate,
18258 # then the envvar interface is used.  Set only those that are not.
18259 # We use the long form for the default assignment because of an extremely
18260 # bizarre bug on SunOS 4.1.3.
18261 if $ac_need_defaults; then
18262   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
18263   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
18264 fi
18265
18266 # Create a temporary directory, and hook for its removal unless debugging.
18267 $debug ||
18268 {
18269   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
18270   trap '{ (exit 1); exit 1; }' 1 2 13 15
18271 }
18272
18273 # Create a (secure) tmp directory for tmp files.
18274 : ${TMPDIR=/tmp}
18275 {
18276   tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
18277   test -n "$tmp" && test -d "$tmp"
18278 }  ||
18279 {
18280   tmp=$TMPDIR/cs$$-$RANDOM
18281   (umask 077 && mkdir $tmp)
18282 } ||
18283 {
18284    echo "$me: cannot create a temporary directory in $TMPDIR" >&2
18285    { (exit 1); exit 1; }
18286 }
18287
18288 EOF
18289
18290 cat >>$CONFIG_STATUS <<EOF
18291
18292 #
18293 # CONFIG_FILES section.
18294 #
18295
18296 # No need to generate the scripts if there are no CONFIG_FILES.
18297 # This happens for instance when ./config.status config.h
18298 if test -n "\$CONFIG_FILES"; then
18299   # Protect against being on the right side of a sed subst in config.status.
18300   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
18301    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
18302 s,@SHELL@,$SHELL,;t t
18303 s,@exec_prefix@,$exec_prefix,;t t
18304 s,@prefix@,$prefix,;t t
18305 s,@program_transform_name@,$program_transform_name,;t t
18306 s,@bindir@,$bindir,;t t
18307 s,@sbindir@,$sbindir,;t t
18308 s,@libexecdir@,$libexecdir,;t t
18309 s,@datadir@,$datadir,;t t
18310 s,@sysconfdir@,$sysconfdir,;t t
18311 s,@sharedstatedir@,$sharedstatedir,;t t
18312 s,@localstatedir@,$localstatedir,;t t
18313 s,@libdir@,$libdir,;t t
18314 s,@includedir@,$includedir,;t t
18315 s,@oldincludedir@,$oldincludedir,;t t
18316 s,@infodir@,$infodir,;t t
18317 s,@mandir@,$mandir,;t t
18318 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
18319 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
18320 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
18321 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
18322 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
18323 s,@build_alias@,$build_alias,;t t
18324 s,@host_alias@,$host_alias,;t t
18325 s,@target_alias@,$target_alias,;t t
18326 s,@ECHO_C@,$ECHO_C,;t t
18327 s,@ECHO_N@,$ECHO_N,;t t
18328 s,@ECHO_T@,$ECHO_T,;t t
18329 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
18330 s,@DEFS@,$DEFS,;t t
18331 s,@LIBS@,$LIBS,;t t
18332 s,@RUNPROG@,$RUNPROG,;t t
18333 s,@MPROGS@,$MPROGS,;t t
18334 s,@LDSHFLAGS@,$LDSHFLAGS,;t t
18335 s,@SHLD@,$SHLD,;t t
18336 s,@HOST_OS@,$HOST_OS,;t t
18337 s,@PAM_MOD@,$PAM_MOD,;t t
18338 s,@WRAP@,$WRAP,;t t
18339 s,@WRAP32@,$WRAP32,;t t
18340 s,@PICFLAG@,$PICFLAG,;t t
18341 s,@PICSUFFIX@,$PICSUFFIX,;t t
18342 s,@POBAD_CC@,$POBAD_CC,;t t
18343 s,@SHLIBEXT@,$SHLIBEXT,;t t
18344 s,@LIBSMBCLIENT_SHARED@,$LIBSMBCLIENT_SHARED,;t t
18345 s,@CC@,$CC,;t t
18346 s,@CFLAGS@,$CFLAGS,;t t
18347 s,@LDFLAGS@,$LDFLAGS,;t t
18348 s,@CPPFLAGS@,$CPPFLAGS,;t t
18349 s,@ac_ct_CC@,$ac_ct_CC,;t t
18350 s,@EXEEXT@,$EXEEXT,;t t
18351 s,@OBJEXT@,$OBJEXT,;t t
18352 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
18353 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
18354 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
18355 s,@AWK@,$AWK,;t t
18356 s,@BROKEN_CC@,$BROKEN_CC,;t t
18357 s,@build@,$build,;t t
18358 s,@build_cpu@,$build_cpu,;t t
18359 s,@build_vendor@,$build_vendor,;t t
18360 s,@build_os@,$build_os,;t t
18361 s,@host@,$host,;t t
18362 s,@host_cpu@,$host_cpu,;t t
18363 s,@host_vendor@,$host_vendor,;t t
18364 s,@host_os@,$host_os,;t t
18365 s,@target@,$target,;t t
18366 s,@target_cpu@,$target_cpu,;t t
18367 s,@target_vendor@,$target_vendor,;t t
18368 s,@target_os@,$target_os,;t t
18369 s,@CPP@,$CPP,;t t
18370 s,@LIBOBJS@,$LIBOBJS,;t t
18371 s,@TERMLIBS@,$TERMLIBS,;t t
18372 s,@TERMLDFLAGS@,$TERMLDFLAGS,;t t
18373 s,@ROFF@,$ROFF,;t t
18374 s,@QUOTAOBJS@,$QUOTAOBJS,;t t
18375 s,@privatedir@,$privatedir,;t t
18376 s,@lockdir@,$lockdir,;t t
18377 s,@swatdir@,$swatdir,;t t
18378 s,@manlangs@,$manlangs,;t t
18379 s,@WINBIND_TARGETS@,$WINBIND_TARGETS,;t t
18380 s,@WINBIND_STARGETS@,$WINBIND_STARGETS,;t t
18381 s,@WINBIND_LTARGETS@,$WINBIND_LTARGETS,;t t
18382 s,@WINBIND_PAM_TARGETS@,$WINBIND_PAM_TARGETS,;t t
18383 s,@BUILD_POPT@,$BUILD_POPT,;t t
18384 s,@FLAGS1@,$FLAGS1,;t t
18385 s,@builddir@,$builddir,;t t
18386 CEOF
18387
18388 EOF
18389
18390   cat >>$CONFIG_STATUS <<\EOF
18391   # Split the substitutions into bite-sized pieces for seds with
18392   # small command number limits, like on Digital OSF/1 and HP-UX.
18393   ac_max_sed_lines=48
18394   ac_sed_frag=1 # Number of current file.
18395   ac_beg=1 # First line for current file.
18396   ac_end=$ac_max_sed_lines # Line after last line for current file.
18397   ac_more_lines=:
18398   ac_sed_cmds=
18399   while $ac_more_lines; do
18400     if test $ac_beg -gt 1; then
18401       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
18402     else
18403       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
18404     fi
18405     if test ! -s $tmp/subs.frag; then
18406       ac_more_lines=false
18407     else
18408       # The purpose of the label and of the branching condition is to
18409       # speed up the sed processing (if there are no `@' at all, there
18410       # is no need to browse any of the substitutions).
18411       # These are the two extra sed commands mentioned above.
18412       (echo ':t
18413   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
18414       if test -z "$ac_sed_cmds"; then
18415         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
18416       else
18417         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
18418       fi
18419       ac_sed_frag=`expr $ac_sed_frag + 1`
18420       ac_beg=$ac_end
18421       ac_end=`expr $ac_end + $ac_max_sed_lines`
18422     fi
18423   done
18424   if test -z "$ac_sed_cmds"; then
18425     ac_sed_cmds=cat
18426   fi
18427 fi # test -n "$CONFIG_FILES"
18428
18429 EOF
18430 cat >>$CONFIG_STATUS <<\EOF
18431 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
18432   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
18433   case $ac_file in
18434   - | *:- | *:-:* ) # input from stdin
18435         cat >$tmp/stdin
18436         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18437         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18438   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18439         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18440   * )   ac_file_in=$ac_file.in ;;
18441   esac
18442
18443   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
18444   ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18445          X"$ac_file" : 'X\(//\)[^/]' \| \
18446          X"$ac_file" : 'X\(//\)$' \| \
18447          X"$ac_file" : 'X\(/\)' \| \
18448          .     : '\(.\)' 2>/dev/null ||
18449 echo X"$ac_file" |
18450     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
18451           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
18452           /^X\(\/\/\)$/{ s//\1/; q; }
18453           /^X\(\/\).*/{ s//\1/; q; }
18454           s/.*/./; q'`
18455   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
18456     { case "$ac_dir" in
18457   [\\/]* | ?:[\\/]* ) as_incr_dir=;;
18458   *)                      as_incr_dir=.;;
18459 esac
18460 as_dummy="$ac_dir"
18461 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
18462   case $as_mkdir_dir in
18463     # Skip DOS drivespec
18464     ?:) as_incr_dir=$as_mkdir_dir ;;
18465     *)
18466       as_incr_dir=$as_incr_dir/$as_mkdir_dir
18467       test -d "$as_incr_dir" || mkdir "$as_incr_dir"
18468     ;;
18469   esac
18470 done; }
18471
18472     ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
18473     # A "../" for each directory in $ac_dir_suffix.
18474     ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
18475   else
18476     ac_dir_suffix= ac_dots=
18477   fi
18478
18479   case $srcdir in
18480   .)  ac_srcdir=.
18481       if test -z "$ac_dots"; then
18482          ac_top_srcdir=.
18483       else
18484          ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
18485       fi ;;
18486   [\\/]* | ?:[\\/]* )
18487       ac_srcdir=$srcdir$ac_dir_suffix;
18488       ac_top_srcdir=$srcdir ;;
18489   *) # Relative path.
18490     ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
18491     ac_top_srcdir=$ac_dots$srcdir ;;
18492   esac
18493
18494   case $INSTALL in
18495   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
18496   *) ac_INSTALL=$ac_dots$INSTALL ;;
18497   esac
18498
18499   if test x"$ac_file" != x-; then
18500     { echo "$as_me:18500: creating $ac_file" >&5
18501 echo "$as_me: creating $ac_file" >&6;}
18502     rm -f "$ac_file"
18503   fi
18504   # Let's still pretend it is `configure' which instantiates (i.e., don't
18505   # use $as_me), people would be surprised to read:
18506   #    /* config.h.  Generated automatically by config.status.  */
18507   configure_input="Generated automatically from `echo $ac_file_in |
18508                                                  sed 's,.*/,,'` by configure."
18509
18510   # First look for the input files in the build tree, otherwise in the
18511   # src tree.
18512   ac_file_inputs=`IFS=:
18513     for f in $ac_file_in; do
18514       case $f in
18515       -) echo $tmp/stdin ;;
18516       [\\/$]*)
18517          # Absolute (can't be DOS-style, as IFS=:)
18518          test -f "$f" || { { echo "$as_me:18518: error: cannot find input file: $f" >&5
18519 echo "$as_me: error: cannot find input file: $f" >&2;}
18520    { (exit 1); exit 1; }; }
18521          echo $f;;
18522       *) # Relative
18523          if test -f "$f"; then
18524            # Build tree
18525            echo $f
18526          elif test -f "$srcdir/$f"; then
18527            # Source tree
18528            echo $srcdir/$f
18529          else
18530            # /dev/null tree
18531            { { echo "$as_me:18531: error: cannot find input file: $f" >&5
18532 echo "$as_me: error: cannot find input file: $f" >&2;}
18533    { (exit 1); exit 1; }; }
18534          fi;;
18535       esac
18536     done` || { (exit 1); exit 1; }
18537 EOF
18538 cat >>$CONFIG_STATUS <<EOF
18539   sed "$ac_vpsub
18540 $extrasub
18541 EOF
18542 cat >>$CONFIG_STATUS <<\EOF
18543 :t
18544 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
18545 s,@configure_input@,$configure_input,;t t
18546 s,@srcdir@,$ac_srcdir,;t t
18547 s,@top_srcdir@,$ac_top_srcdir,;t t
18548 s,@INSTALL@,$ac_INSTALL,;t t
18549 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
18550   rm -f $tmp/stdin
18551   if test x"$ac_file" != x-; then
18552     mv $tmp/out $ac_file
18553   else
18554     cat $tmp/out
18555     rm -f $tmp/out
18556   fi
18557
18558 done
18559 EOF
18560 cat >>$CONFIG_STATUS <<\EOF
18561
18562 #
18563 # CONFIG_HEADER section.
18564 #
18565
18566 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
18567 # NAME is the cpp macro being defined and VALUE is the value it is being given.
18568 #
18569 # ac_d sets the value in "#define NAME VALUE" lines.
18570 ac_dA='s,^\([   ]*\)#\([        ]*define[       ][      ]*\)'
18571 ac_dB='[        ].*$,\1#\2'
18572 ac_dC=' '
18573 ac_dD=',;t'
18574 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
18575 ac_uA='s,^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
18576 ac_uB='$,\1#\2define\3'
18577 ac_uC=' '
18578 ac_uD=',;t'
18579
18580 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
18581   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
18582   case $ac_file in
18583   - | *:- | *:-:* ) # input from stdin
18584         cat >$tmp/stdin
18585         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18586         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18587   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18588         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18589   * )   ac_file_in=$ac_file.in ;;
18590   esac
18591
18592   test x"$ac_file" != x- && { echo "$as_me:18592: creating $ac_file" >&5
18593 echo "$as_me: creating $ac_file" >&6;}
18594
18595   # First look for the input files in the build tree, otherwise in the
18596   # src tree.
18597   ac_file_inputs=`IFS=:
18598     for f in $ac_file_in; do
18599       case $f in
18600       -) echo $tmp/stdin ;;
18601       [\\/$]*)
18602          # Absolute (can't be DOS-style, as IFS=:)
18603          test -f "$f" || { { echo "$as_me:18603: error: cannot find input file: $f" >&5
18604 echo "$as_me: error: cannot find input file: $f" >&2;}
18605    { (exit 1); exit 1; }; }
18606          echo $f;;
18607       *) # Relative
18608          if test -f "$f"; then
18609            # Build tree
18610            echo $f
18611          elif test -f "$srcdir/$f"; then
18612            # Source tree
18613            echo $srcdir/$f
18614          else
18615            # /dev/null tree
18616            { { echo "$as_me:18616: error: cannot find input file: $f" >&5
18617 echo "$as_me: error: cannot find input file: $f" >&2;}
18618    { (exit 1); exit 1; }; }
18619          fi;;
18620       esac
18621     done` || { (exit 1); exit 1; }
18622   # Remove the trailing spaces.
18623   sed 's/[      ]*$//' $ac_file_inputs >$tmp/in
18624
18625 EOF
18626
18627 # Transform confdefs.h into two sed scripts, `conftest.defines' and
18628 # `conftest.undefs', that substitutes the proper values into
18629 # config.h.in to produce config.h.  The first handles `#define'
18630 # templates, and the second `#undef' templates.
18631 # And first: Protect against being on the right side of a sed subst in
18632 # config.status.  Protect against being in an unquoted here document
18633 # in config.status.
18634 rm -f conftest.defines conftest.undefs
18635 # Using a here document instead of a string reduces the quoting nightmare.
18636 # Putting comments in sed scripts is not portable.
18637 #
18638 # `end' is used to avoid that the second main sed command (meant for
18639 # 0-ary CPP macros) applies to n-ary macro definitions.
18640 # See the Autoconf documentation for `clear'.
18641 cat >confdef2sed.sed <<\EOF
18642 s/[\\&,]/\\&/g
18643 s,[\\$`],\\&,g
18644 t clear
18645 : clear
18646 s,^[    ]*#[    ]*define[       ][      ]*\(\([^        (][^    (]*\)([^)]*)\)[         ]*\(.*\)$,${ac_dA}\2${ac_dB}\1${ac_dC}\3${ac_dD},gp
18647 t end
18648 s,^[    ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
18649 : end
18650 EOF
18651 # If some macros were called several times there might be several times
18652 # the same #defines, which is useless.  Nevertheless, we may not want to
18653 # sort them, since we want the *last* AC-DEFINE to be honored.
18654 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
18655 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
18656 rm -f confdef2sed.sed
18657
18658 # This sed command replaces #undef with comments.  This is necessary, for
18659 # example, in the case of _POSIX_SOURCE, which is predefined and required
18660 # on some systems where configure will not decide to define it.
18661 cat >>conftest.undefs <<\EOF
18662 s,^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
18663 EOF
18664
18665 # Break up conftest.defines because some shells have a limit on the size
18666 # of here documents, and old seds have small limits too (100 cmds).
18667 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
18668 echo '  if egrep "^[    ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
18669 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
18670 echo '  :' >>$CONFIG_STATUS
18671 rm -f conftest.tail
18672 while grep . conftest.defines >/dev/null
18673 do
18674   # Write a limited-size here document to $tmp/defines.sed.
18675   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
18676   # Speed up: don't consider the non `#define' lines.
18677   echo '/^[     ]*#[    ]*define/!b' >>$CONFIG_STATUS
18678   # Work around the forget-to-reset-the-flag bug.
18679   echo 't clr' >>$CONFIG_STATUS
18680   echo ': clr' >>$CONFIG_STATUS
18681   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
18682   echo 'CEOF
18683   sed -f $tmp/defines.sed $tmp/in >$tmp/out
18684   rm -f $tmp/in
18685   mv $tmp/out $tmp/in
18686 ' >>$CONFIG_STATUS
18687   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
18688   rm -f conftest.defines
18689   mv conftest.tail conftest.defines
18690 done
18691 rm -f conftest.defines
18692 echo '  fi # egrep' >>$CONFIG_STATUS
18693 echo >>$CONFIG_STATUS
18694
18695 # Break up conftest.undefs because some shells have a limit on the size
18696 # of here documents, and old seds have small limits too (100 cmds).
18697 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
18698 rm -f conftest.tail
18699 while grep . conftest.undefs >/dev/null
18700 do
18701   # Write a limited-size here document to $tmp/undefs.sed.
18702   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
18703   # Speed up: don't consider the non `#undef'
18704   echo '/^[     ]*#[    ]*undef/!b' >>$CONFIG_STATUS
18705   # Work around the forget-to-reset-the-flag bug.
18706   echo 't clr' >>$CONFIG_STATUS
18707   echo ': clr' >>$CONFIG_STATUS
18708   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
18709   echo 'CEOF
18710   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
18711   rm -f $tmp/in
18712   mv $tmp/out $tmp/in
18713 ' >>$CONFIG_STATUS
18714   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
18715   rm -f conftest.undefs
18716   mv conftest.tail conftest.undefs
18717 done
18718 rm -f conftest.undefs
18719
18720 cat >>$CONFIG_STATUS <<\EOF
18721   # Let's still pretend it is `configure' which instantiates (i.e., don't
18722   # use $as_me), people would be surprised to read:
18723   #    /* config.h.  Generated automatically by config.status.  */
18724   if test x"$ac_file" = x-; then
18725     echo "/* Generated automatically by configure.  */" >$tmp/config.h
18726   else
18727     echo "/* $ac_file.  Generated automatically by configure.  */" >$tmp/config.h
18728   fi
18729   cat $tmp/in >>$tmp/config.h
18730   rm -f $tmp/in
18731   if test x"$ac_file" != x-; then
18732     if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
18733       { echo "$as_me:18733: $ac_file is unchanged" >&5
18734 echo "$as_me: $ac_file is unchanged" >&6;}
18735     else
18736       ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18737          X"$ac_file" : 'X\(//\)[^/]' \| \
18738          X"$ac_file" : 'X\(//\)$' \| \
18739          X"$ac_file" : 'X\(/\)' \| \
18740          .     : '\(.\)' 2>/dev/null ||
18741 echo X"$ac_file" |
18742     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
18743           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
18744           /^X\(\/\/\)$/{ s//\1/; q; }
18745           /^X\(\/\).*/{ s//\1/; q; }
18746           s/.*/./; q'`
18747       if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
18748         { case "$ac_dir" in
18749   [\\/]* | ?:[\\/]* ) as_incr_dir=;;
18750   *)                      as_incr_dir=.;;
18751 esac
18752 as_dummy="$ac_dir"
18753 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
18754   case $as_mkdir_dir in
18755     # Skip DOS drivespec
18756     ?:) as_incr_dir=$as_mkdir_dir ;;
18757     *)
18758       as_incr_dir=$as_incr_dir/$as_mkdir_dir
18759       test -d "$as_incr_dir" || mkdir "$as_incr_dir"
18760     ;;
18761   esac
18762 done; }
18763
18764       fi
18765       rm -f $ac_file
18766       mv $tmp/config.h $ac_file
18767     fi
18768   else
18769     cat $tmp/config.h
18770     rm -f $tmp/config.h
18771   fi
18772 done
18773 EOF
18774
18775 cat >>$CONFIG_STATUS <<\EOF
18776
18777 { (exit 0); exit 0; }
18778 EOF
18779 chmod +x $CONFIG_STATUS
18780 ac_clean_files=$ac_clean_files_save
18781
18782 # configure is writing to config.log, and then calls config.status.
18783 # config.status does its own redirection, appending to config.log.
18784 # Unfortunately, on DOS this fails, as config.log is still kept open
18785 # by configure, so config.status won't be able to write to it; its
18786 # output is simply discarded.  So we exec the FD to /dev/null,
18787 # effectively closing config.log, so it can be properly (re)opened and
18788 # appended to by config.status.  When coming back to configure, we
18789 # need to make the FD available again.
18790 if test "$no_create" != yes; then
18791   ac_cs_success=:
18792   exec 5>/dev/null
18793   $SHELL $CONFIG_STATUS || ac_cs_success=false
18794   exec 5>>config.log
18795   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
18796   # would make configure fail if this is the last instruction.
18797   $ac_cs_success || { (exit 1); exit 1; }
18798 fi
18799