]> git.sur5r.net Git - openldap/blob - configure
refine previous commit
[openldap] / configure
1 #! /bin/sh
2 # From configure.in OpenLDAP: pkg/ldap/configure.in,v 1.634 2006/07/06 05:51:14 kurt Exp .
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated by GNU Autoconf 2.59.
5 #
6 # Copyright 1998-2006 The OpenLDAP Foundation. All rights reserved.
7 # Restrictions apply, see COPYRIGHT and LICENSE files.
8 #
9 # Copyright (C) 2003 Free Software Foundation, Inc.
10 # This configure script is free software; the Free Software Foundation
11 # gives unlimited permission to copy, distribute and modify it.
12 ## --------------------- ##
13 ## M4sh Initialization.  ##
14 ## --------------------- ##
15
16 # Be Bourne compatible
17 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
18   emulate sh
19   NULLCMD=:
20   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
21   # is contrary to our usage.  Disable this feature.
22   alias -g '${1+"$@"}'='"$@"'
23 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
24   set -o posix
25 fi
26 DUALCASE=1; export DUALCASE # for MKS sh
27
28 # Support unset when possible.
29 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
30   as_unset=unset
31 else
32   as_unset=false
33 fi
34
35
36 # Work around bugs in pre-3.0 UWIN ksh.
37 $as_unset ENV MAIL MAILPATH
38 PS1='$ '
39 PS2='> '
40 PS4='+ '
41
42 # NLS nuisances.
43 for as_var in \
44   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
45   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
46   LC_TELEPHONE LC_TIME
47 do
48   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
49     eval $as_var=C; export $as_var
50   else
51     $as_unset $as_var
52   fi
53 done
54
55 # Required to use basename.
56 if expr a : '\(a\)' >/dev/null 2>&1; then
57   as_expr=expr
58 else
59   as_expr=false
60 fi
61
62 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
63   as_basename=basename
64 else
65   as_basename=false
66 fi
67
68
69 # Name of the executable.
70 as_me=`$as_basename "$0" ||
71 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
72          X"$0" : 'X\(//\)$' \| \
73          X"$0" : 'X\(/\)$' \| \
74          .     : '\(.\)' 2>/dev/null ||
75 echo X/"$0" |
76     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
77           /^X\/\(\/\/\)$/{ s//\1/; q; }
78           /^X\/\(\/\).*/{ s//\1/; q; }
79           s/.*/./; q'`
80
81
82 # PATH needs CR, and LINENO needs CR and PATH.
83 # Avoid depending upon Character Ranges.
84 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
85 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
86 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
87 as_cr_digits='0123456789'
88 as_cr_alnum=$as_cr_Letters$as_cr_digits
89
90 # The user is always right.
91 if test "${PATH_SEPARATOR+set}" != set; then
92   echo "#! /bin/sh" >conf$$.sh
93   echo  "exit 0"   >>conf$$.sh
94   chmod +x conf$$.sh
95   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
96     PATH_SEPARATOR=';'
97   else
98     PATH_SEPARATOR=:
99   fi
100   rm -f conf$$.sh
101 fi
102
103
104   as_lineno_1=$LINENO
105   as_lineno_2=$LINENO
106   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
107   test "x$as_lineno_1" != "x$as_lineno_2" &&
108   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
109   # Find who we are.  Look in the path if we contain no path at all
110   # relative or not.
111   case $0 in
112     *[\\/]* ) as_myself=$0 ;;
113     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
114 for as_dir in $PATH
115 do
116   IFS=$as_save_IFS
117   test -z "$as_dir" && as_dir=.
118   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
119 done
120
121        ;;
122   esac
123   # We did not find ourselves, most probably we were run as `sh COMMAND'
124   # in which case we are not to be found in the path.
125   if test "x$as_myself" = x; then
126     as_myself=$0
127   fi
128   if test ! -f "$as_myself"; then
129     { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
130    { (exit 1); exit 1; }; }
131   fi
132   case $CONFIG_SHELL in
133   '')
134     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
135 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
136 do
137   IFS=$as_save_IFS
138   test -z "$as_dir" && as_dir=.
139   for as_base in sh bash ksh sh5; do
140          case $as_dir in
141          /*)
142            if ("$as_dir/$as_base" -c '
143   as_lineno_1=$LINENO
144   as_lineno_2=$LINENO
145   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
146   test "x$as_lineno_1" != "x$as_lineno_2" &&
147   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
148              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
149              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
150              CONFIG_SHELL=$as_dir/$as_base
151              export CONFIG_SHELL
152              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
153            fi;;
154          esac
155        done
156 done
157 ;;
158   esac
159
160   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
161   # uniformly replaced by the line number.  The first 'sed' inserts a
162   # line-number line before each line; the second 'sed' does the real
163   # work.  The second script uses 'N' to pair each line-number line
164   # with the numbered line, and appends trailing '-' during
165   # substitution so that $LINENO is not a special case at line end.
166   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
167   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
168   sed '=' <$as_myself |
169     sed '
170       N
171       s,$,-,
172       : loop
173       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
174       t loop
175       s,-$,,
176       s,^['$as_cr_digits']*\n,,
177     ' >$as_me.lineno &&
178   chmod +x $as_me.lineno ||
179     { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
180    { (exit 1); exit 1; }; }
181
182   # Don't try to exec as it changes $[0], causing all sort of problems
183   # (the dirname of $[0] is not the place where we might find the
184   # original and so on.  Autoconf is especially sensible to this).
185   . ./$as_me.lineno
186   # Exit status is that of the last command.
187   exit
188 }
189
190
191 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
192   *c*,-n*) ECHO_N= ECHO_C='
193 ' ECHO_T='      ' ;;
194   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
195   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
196 esac
197
198 if expr a : '\(a\)' >/dev/null 2>&1; then
199   as_expr=expr
200 else
201   as_expr=false
202 fi
203
204 rm -f conf$$ conf$$.exe conf$$.file
205 echo >conf$$.file
206 if ln -s conf$$.file conf$$ 2>/dev/null; then
207   # We could just check for DJGPP; but this test a) works b) is more generic
208   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
209   if test -f conf$$.exe; then
210     # Don't use ln at all; we don't have any links
211     as_ln_s='cp -p'
212   else
213     as_ln_s='ln -s'
214   fi
215 elif ln conf$$.file conf$$ 2>/dev/null; then
216   as_ln_s=ln
217 else
218   as_ln_s='cp -p'
219 fi
220 rm -f conf$$ conf$$.exe conf$$.file
221
222 if mkdir -p . 2>/dev/null; then
223   as_mkdir_p=:
224 else
225   test -d ./-p && rmdir ./-p
226   as_mkdir_p=false
227 fi
228
229 as_executable_p="test -f"
230
231 # Sed expression to map a string onto a valid CPP name.
232 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
233
234 # Sed expression to map a string onto a valid variable name.
235 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
236
237
238 # IFS
239 # We need space, tab and new line, in precisely that order.
240 as_nl='
241 '
242 IFS="   $as_nl"
243
244 # CDPATH.
245 $as_unset CDPATH
246
247
248
249 # Check that we are running under the correct shell.
250 SHELL=${CONFIG_SHELL-/bin/sh}
251
252 case X$ECHO in
253 X*--fallback-echo)
254   # Remove one level of quotation (which was required for Make).
255   ECHO=`echo "$ECHO" | sed 's,\\\\\$\\$0,'$0','`
256   ;;
257 esac
258
259 echo=${ECHO-echo}
260 if test "X$1" = X--no-reexec; then
261   # Discard the --no-reexec flag, and continue.
262   shift
263 elif test "X$1" = X--fallback-echo; then
264   # Avoid inline document here, it may be left over
265   :
266 elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then
267   # Yippee, $echo works!
268   :
269 else
270   # Restart under the correct shell.
271   exec $SHELL "$0" --no-reexec ${1+"$@"}
272 fi
273
274 if test "X$1" = X--fallback-echo; then
275   # used as fallback echo
276   shift
277   cat <<EOF
278 $*
279 EOF
280   exit 0
281 fi
282
283 # The HP-UX ksh and POSIX shell print the target directory to stdout
284 # if CDPATH is set.
285 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
286
287 if test -z "$ECHO"; then
288 if test "X${echo_test_string+set}" != Xset; then
289 # find a string as large as possible, as long as the shell can cope with it
290   for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do
291     # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
292     if (echo_test_string=`eval $cmd`) 2>/dev/null &&
293        echo_test_string=`eval $cmd` &&
294        (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
295     then
296       break
297     fi
298   done
299 fi
300
301 if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
302    echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
303    test "X$echo_testing_string" = "X$echo_test_string"; then
304   :
305 else
306   # The Solaris, AIX, and Digital Unix default echo programs unquote
307   # backslashes.  This makes it impossible to quote backslashes using
308   #   echo "$something" | sed 's/\\/\\\\/g'
309   #
310   # So, first we look for a working echo in the user's PATH.
311
312   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
313   for dir in $PATH /usr/ucb; do
314     IFS="$lt_save_ifs"
315     if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
316        test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
317        echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
318        test "X$echo_testing_string" = "X$echo_test_string"; then
319       echo="$dir/echo"
320       break
321     fi
322   done
323   IFS="$lt_save_ifs"
324
325   if test "X$echo" = Xecho; then
326     # We didn't find a better echo, so look for alternatives.
327     if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
328        echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
329        test "X$echo_testing_string" = "X$echo_test_string"; then
330       # This shell has a builtin print -r that does the trick.
331       echo='print -r'
332     elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
333          test "X$CONFIG_SHELL" != X/bin/ksh; then
334       # If we have ksh, try running configure again with it.
335       ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
336       export ORIGINAL_CONFIG_SHELL
337       CONFIG_SHELL=/bin/ksh
338       export CONFIG_SHELL
339       exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"}
340     else
341       # Try using printf.
342       echo='printf %s\n'
343       if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
344          echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
345          test "X$echo_testing_string" = "X$echo_test_string"; then
346         # Cool, printf works
347         :
348       elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
349            test "X$echo_testing_string" = 'X\t' &&
350            echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
351            test "X$echo_testing_string" = "X$echo_test_string"; then
352         CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
353         export CONFIG_SHELL
354         SHELL="$CONFIG_SHELL"
355         export SHELL
356         echo="$CONFIG_SHELL $0 --fallback-echo"
357       elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
358            test "X$echo_testing_string" = 'X\t' &&
359            echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
360            test "X$echo_testing_string" = "X$echo_test_string"; then
361         echo="$CONFIG_SHELL $0 --fallback-echo"
362       else
363         # maybe with a smaller string...
364         prev=:
365
366         for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do
367           if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
368           then
369             break
370           fi
371           prev="$cmd"
372         done
373
374         if test "$prev" != 'sed 50q "$0"'; then
375           echo_test_string=`eval $prev`
376           export echo_test_string
377           exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"}
378         else
379           # Oops.  We lost completely, so just stick with echo.
380           echo=echo
381         fi
382       fi
383     fi
384   fi
385 fi
386 fi
387
388 # Copy echo and quote the copy suitably for passing to libtool from
389 # the Makefile, instead of quoting the original, which is used later.
390 ECHO=$echo
391 if test "X$ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then
392    ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo"
393 fi
394
395
396
397
398 # Name of the host.
399 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
400 # so uname gets run too.
401 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
402
403 exec 6>&1
404
405 #
406 # Initializations.
407 #
408 ac_default_prefix=/usr/local
409 ac_config_libobj_dir=.
410 cross_compiling=no
411 subdirs=
412 MFLAGS=
413 MAKEFLAGS=
414 SHELL=${CONFIG_SHELL-/bin/sh}
415
416 # Maximum number of lines to put in a shell here document.
417 # This variable seems obsolete.  It should probably be removed, and
418 # only ac_max_sed_lines should be used.
419 : ${ac_max_here_lines=38}
420
421 # Identity of this package.
422 PACKAGE_NAME=
423 PACKAGE_TARNAME=
424 PACKAGE_VERSION=
425 PACKAGE_STRING=
426 PACKAGE_BUGREPORT=
427
428 ac_unique_file="OpenLDAP"
429 ac_unique_file="build/version.sh"
430 ac_default_prefix=/usr/local
431 # Factoring default headers for most tests.
432 ac_includes_default="\
433 #include <stdio.h>
434 #if HAVE_SYS_TYPES_H
435 # include <sys/types.h>
436 #endif
437 #if HAVE_SYS_STAT_H
438 # include <sys/stat.h>
439 #endif
440 #if STDC_HEADERS
441 # include <stdlib.h>
442 # include <stddef.h>
443 #else
444 # if HAVE_STDLIB_H
445 #  include <stdlib.h>
446 # endif
447 #endif
448 #if HAVE_STRING_H
449 # if !STDC_HEADERS && HAVE_MEMORY_H
450 #  include <memory.h>
451 # endif
452 # include <string.h>
453 #endif
454 #if HAVE_STRINGS_H
455 # include <strings.h>
456 #endif
457 #if HAVE_INTTYPES_H
458 # include <inttypes.h>
459 #else
460 # if HAVE_STDINT_H
461 #  include <stdint.h>
462 # endif
463 #endif
464 #if HAVE_UNISTD_H
465 # include <unistd.h>
466 #endif"
467
468 ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM mkdir_p AWK SET_MAKE am__leading_dot AMTAR am__tar am__untar OPENLDAP_LIBRELEASE OPENLDAP_LIBVERSION OPENLDAP_RELEASE_DATE top_builddir ldap_subdir CC AR CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE EGREP LN_S ECHO ac_ct_AR RANLIB ac_ct_RANLIB DLLTOOL ac_ct_DLLTOOL AS ac_ct_AS OBJDUMP ac_ct_OBJDUMP CPP LIBTOOL PERLBIN OL_MKDEP OL_MKDEP_FLAGS LTSTATIC LIBOBJS LIBSRCS PLAT WITH_SASL WITH_TLS WITH_MODULES_ENABLED WITH_ACI_ENABLED BUILD_THREAD BUILD_LIBS_DYNAMIC BUILD_SLAPD BUILD_SLAPI SLAPD_SLAPI_DEPEND BUILD_BDB BUILD_DNSSRV BUILD_HDB BUILD_LDAP BUILD_META BUILD_MONITOR BUILD_NULL BUILD_PASSWD BUILD_RELAY BUILD_PERL BUILD_SHELL BUILD_SQL BUILD_ACCESSLOG BUILD_AUDITLOG BUILD_CONSTRAINT BUILD_DDS BUILD_DENYOP BUILD_DYNGROUP BUILD_DYNLIST BUILD_LASTMOD BUILD_PPOLICY BUILD_PROXYCACHE BUILD_REFINT BUILD_RETCODE BUILD_RWM BUILD_SEQMOD BUILD_SYNCPROV BUILD_TRANSLUCENT BUILD_UNIQUE BUILD_VALSORT BUILD_SLURPD LDAP_LIBS SLAPD_LIBS SLURPD_LIBS BDB_LIBS LTHREAD_LIBS LUTIL_LIBS WRAP_LIBS SLAPD_MODULES_CPPFLAGS SLAPD_MODULES_LDFLAGS SLAPD_NO_STATIC SLAPD_STATIC_BACKENDS SLAPD_DYNAMIC_BACKENDS SLAPD_STATIC_OVERLAYS SLAPD_DYNAMIC_OVERLAYS PERL_CPPFLAGS SLAPD_PERL_LDFLAGS MOD_PERL_LDFLAGS KRB4_LIBS KRB5_LIBS SASL_LIBS TLS_LIBS MODULES_LIBS SLAPI_LIBS LIBSLAPI LIBSLAPITOOLS AUTH_LIBS ICU_LIBS SLAPD_SLP_LIBS SLAPD_GMP_LIBS SLAPD_SQL_LDFLAGS SLAPD_SQL_LIBS SLAPD_SQL_INCLUDES LTLIBOBJS'
469 ac_subst_files=''
470
471 # Initialize some variables set by options.
472 ac_init_help=
473 ac_init_version=false
474 # The variables have the same names as the options, with
475 # dashes changed to underlines.
476 cache_file=/dev/null
477 exec_prefix=NONE
478 no_create=
479 no_recursion=
480 prefix=NONE
481 program_prefix=NONE
482 program_suffix=NONE
483 program_transform_name=s,x,x,
484 silent=
485 site=
486 srcdir=
487 verbose=
488 x_includes=NONE
489 x_libraries=NONE
490
491 # Installation directory options.
492 # These are left unexpanded so users can "make install exec_prefix=/foo"
493 # and all the variables that are supposed to be based on exec_prefix
494 # by default will actually change.
495 # Use braces instead of parens because sh, perl, etc. also accept them.
496 bindir='${exec_prefix}/bin'
497 sbindir='${exec_prefix}/sbin'
498 libexecdir='${exec_prefix}/libexec'
499 datadir='${prefix}/share'
500 sysconfdir='${prefix}/etc'
501 sharedstatedir='${prefix}/com'
502 localstatedir='${prefix}/var'
503 libdir='${exec_prefix}/lib'
504 includedir='${prefix}/include'
505 oldincludedir='/usr/include'
506 infodir='${prefix}/info'
507 mandir='${prefix}/man'
508
509 ac_prev=
510 for ac_option
511 do
512   # If the previous option needs an argument, assign it.
513   if test -n "$ac_prev"; then
514     eval "$ac_prev=\$ac_option"
515     ac_prev=
516     continue
517   fi
518
519   ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
520
521   # Accept the important Cygnus configure options, so we can diagnose typos.
522
523   case $ac_option in
524
525   -bindir | --bindir | --bindi | --bind | --bin | --bi)
526     ac_prev=bindir ;;
527   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
528     bindir=$ac_optarg ;;
529
530   -build | --build | --buil | --bui | --bu)
531     ac_prev=build_alias ;;
532   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
533     build_alias=$ac_optarg ;;
534
535   -cache-file | --cache-file | --cache-fil | --cache-fi \
536   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
537     ac_prev=cache_file ;;
538   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
539   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
540     cache_file=$ac_optarg ;;
541
542   --config-cache | -C)
543     cache_file=config.cache ;;
544
545   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
546     ac_prev=datadir ;;
547   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
548   | --da=*)
549     datadir=$ac_optarg ;;
550
551   -disable-* | --disable-*)
552     ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
553     # Reject names that are not valid shell variable names.
554     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
555       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
556    { (exit 1); exit 1; }; }
557     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
558     eval "enable_$ac_feature=no" ;;
559
560   -enable-* | --enable-*)
561     ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
562     # Reject names that are not valid shell variable names.
563     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
564       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
565    { (exit 1); exit 1; }; }
566     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
567     case $ac_option in
568       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
569       *) ac_optarg=yes ;;
570     esac
571     eval "enable_$ac_feature='$ac_optarg'" ;;
572
573   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
574   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
575   | --exec | --exe | --ex)
576     ac_prev=exec_prefix ;;
577   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
578   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
579   | --exec=* | --exe=* | --ex=*)
580     exec_prefix=$ac_optarg ;;
581
582   -gas | --gas | --ga | --g)
583     # Obsolete; use --with-gas.
584     with_gas=yes ;;
585
586   -help | --help | --hel | --he | -h)
587     ac_init_help=long ;;
588   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
589     ac_init_help=recursive ;;
590   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
591     ac_init_help=short ;;
592
593   -host | --host | --hos | --ho)
594     ac_prev=host_alias ;;
595   -host=* | --host=* | --hos=* | --ho=*)
596     host_alias=$ac_optarg ;;
597
598   -includedir | --includedir | --includedi | --included | --include \
599   | --includ | --inclu | --incl | --inc)
600     ac_prev=includedir ;;
601   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
602   | --includ=* | --inclu=* | --incl=* | --inc=*)
603     includedir=$ac_optarg ;;
604
605   -infodir | --infodir | --infodi | --infod | --info | --inf)
606     ac_prev=infodir ;;
607   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
608     infodir=$ac_optarg ;;
609
610   -libdir | --libdir | --libdi | --libd)
611     ac_prev=libdir ;;
612   -libdir=* | --libdir=* | --libdi=* | --libd=*)
613     libdir=$ac_optarg ;;
614
615   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
616   | --libexe | --libex | --libe)
617     ac_prev=libexecdir ;;
618   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
619   | --libexe=* | --libex=* | --libe=*)
620     libexecdir=$ac_optarg ;;
621
622   -localstatedir | --localstatedir | --localstatedi | --localstated \
623   | --localstate | --localstat | --localsta | --localst \
624   | --locals | --local | --loca | --loc | --lo)
625     ac_prev=localstatedir ;;
626   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
627   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
628   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
629     localstatedir=$ac_optarg ;;
630
631   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
632     ac_prev=mandir ;;
633   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
634     mandir=$ac_optarg ;;
635
636   -nfp | --nfp | --nf)
637     # Obsolete; use --without-fp.
638     with_fp=no ;;
639
640   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
641   | --no-cr | --no-c | -n)
642     no_create=yes ;;
643
644   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
645   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
646     no_recursion=yes ;;
647
648   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
649   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
650   | --oldin | --oldi | --old | --ol | --o)
651     ac_prev=oldincludedir ;;
652   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
653   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
654   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
655     oldincludedir=$ac_optarg ;;
656
657   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
658     ac_prev=prefix ;;
659   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
660     prefix=$ac_optarg ;;
661
662   -program-prefix | --program-prefix | --program-prefi | --program-pref \
663   | --program-pre | --program-pr | --program-p)
664     ac_prev=program_prefix ;;
665   -program-prefix=* | --program-prefix=* | --program-prefi=* \
666   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
667     program_prefix=$ac_optarg ;;
668
669   -program-suffix | --program-suffix | --program-suffi | --program-suff \
670   | --program-suf | --program-su | --program-s)
671     ac_prev=program_suffix ;;
672   -program-suffix=* | --program-suffix=* | --program-suffi=* \
673   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
674     program_suffix=$ac_optarg ;;
675
676   -program-transform-name | --program-transform-name \
677   | --program-transform-nam | --program-transform-na \
678   | --program-transform-n | --program-transform- \
679   | --program-transform | --program-transfor \
680   | --program-transfo | --program-transf \
681   | --program-trans | --program-tran \
682   | --progr-tra | --program-tr | --program-t)
683     ac_prev=program_transform_name ;;
684   -program-transform-name=* | --program-transform-name=* \
685   | --program-transform-nam=* | --program-transform-na=* \
686   | --program-transform-n=* | --program-transform-=* \
687   | --program-transform=* | --program-transfor=* \
688   | --program-transfo=* | --program-transf=* \
689   | --program-trans=* | --program-tran=* \
690   | --progr-tra=* | --program-tr=* | --program-t=*)
691     program_transform_name=$ac_optarg ;;
692
693   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
694   | -silent | --silent | --silen | --sile | --sil)
695     silent=yes ;;
696
697   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
698     ac_prev=sbindir ;;
699   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
700   | --sbi=* | --sb=*)
701     sbindir=$ac_optarg ;;
702
703   -sharedstatedir | --sharedstatedir | --sharedstatedi \
704   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
705   | --sharedst | --shareds | --shared | --share | --shar \
706   | --sha | --sh)
707     ac_prev=sharedstatedir ;;
708   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
709   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
710   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
711   | --sha=* | --sh=*)
712     sharedstatedir=$ac_optarg ;;
713
714   -site | --site | --sit)
715     ac_prev=site ;;
716   -site=* | --site=* | --sit=*)
717     site=$ac_optarg ;;
718
719   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
720     ac_prev=srcdir ;;
721   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
722     srcdir=$ac_optarg ;;
723
724   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
725   | --syscon | --sysco | --sysc | --sys | --sy)
726     ac_prev=sysconfdir ;;
727   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
728   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
729     sysconfdir=$ac_optarg ;;
730
731   -target | --target | --targe | --targ | --tar | --ta | --t)
732     ac_prev=target_alias ;;
733   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
734     target_alias=$ac_optarg ;;
735
736   -v | -verbose | --verbose | --verbos | --verbo | --verb)
737     verbose=yes ;;
738
739   -version | --version | --versio | --versi | --vers | -V)
740     ac_init_version=: ;;
741
742   -with-* | --with-*)
743     ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
744     # Reject names that are not valid shell variable names.
745     expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
746       { echo "$as_me: error: invalid package name: $ac_package" >&2
747    { (exit 1); exit 1; }; }
748     ac_package=`echo $ac_package| sed 's/-/_/g'`
749     case $ac_option in
750       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
751       *) ac_optarg=yes ;;
752     esac
753     eval "with_$ac_package='$ac_optarg'" ;;
754
755   -without-* | --without-*)
756     ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
757     # Reject names that are not valid shell variable names.
758     expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
759       { echo "$as_me: error: invalid package name: $ac_package" >&2
760    { (exit 1); exit 1; }; }
761     ac_package=`echo $ac_package | sed 's/-/_/g'`
762     eval "with_$ac_package=no" ;;
763
764   --x)
765     # Obsolete; use --with-x.
766     with_x=yes ;;
767
768   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
769   | --x-incl | --x-inc | --x-in | --x-i)
770     ac_prev=x_includes ;;
771   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
772   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
773     x_includes=$ac_optarg ;;
774
775   -x-libraries | --x-libraries | --x-librarie | --x-librari \
776   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
777     ac_prev=x_libraries ;;
778   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
779   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
780     x_libraries=$ac_optarg ;;
781
782   -*) { echo "$as_me: error: unrecognized option: $ac_option
783 Try \`$0 --help' for more information." >&2
784    { (exit 1); exit 1; }; }
785     ;;
786
787   *=*)
788     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
789     # Reject names that are not valid shell variable names.
790     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
791       { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
792    { (exit 1); exit 1; }; }
793     ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
794     eval "$ac_envvar='$ac_optarg'"
795     export $ac_envvar ;;
796
797   *)
798     # FIXME: should be removed in autoconf 3.0.
799     echo "$as_me: WARNING: you should use --build, --host, --target" >&2
800     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
801       echo "$as_me: WARNING: invalid host type: $ac_option" >&2
802     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
803     ;;
804
805   esac
806 done
807
808 if test -n "$ac_prev"; then
809   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
810   { echo "$as_me: error: missing argument to $ac_option" >&2
811    { (exit 1); exit 1; }; }
812 fi
813
814 # Be sure to have absolute paths.
815 for ac_var in exec_prefix prefix
816 do
817   eval ac_val=$`echo $ac_var`
818   case $ac_val in
819     [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
820     *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
821    { (exit 1); exit 1; }; };;
822   esac
823 done
824
825 # Be sure to have absolute paths.
826 for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
827               localstatedir libdir includedir oldincludedir infodir mandir
828 do
829   eval ac_val=$`echo $ac_var`
830   case $ac_val in
831     [\\/$]* | ?:[\\/]* ) ;;
832     *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
833    { (exit 1); exit 1; }; };;
834   esac
835 done
836
837 # There might be people who depend on the old broken behavior: `$host'
838 # used to hold the argument of --host etc.
839 # FIXME: To remove some day.
840 build=$build_alias
841 host=$host_alias
842 target=$target_alias
843
844 # FIXME: To remove some day.
845 if test "x$host_alias" != x; then
846   if test "x$build_alias" = x; then
847     cross_compiling=maybe
848     echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
849     If a cross compiler is detected then cross compile mode will be used." >&2
850   elif test "x$build_alias" != "x$host_alias"; then
851     cross_compiling=yes
852   fi
853 fi
854
855 ac_tool_prefix=
856 test -n "$host_alias" && ac_tool_prefix=$host_alias-
857
858 test "$silent" = yes && exec 6>/dev/null
859
860
861 # Find the source files, if location was not specified.
862 if test -z "$srcdir"; then
863   ac_srcdir_defaulted=yes
864   # Try the directory containing this script, then its parent.
865   ac_confdir=`(dirname "$0") 2>/dev/null ||
866 $as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
867          X"$0" : 'X\(//\)[^/]' \| \
868          X"$0" : 'X\(//\)$' \| \
869          X"$0" : 'X\(/\)' \| \
870          .     : '\(.\)' 2>/dev/null ||
871 echo X"$0" |
872     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
873           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
874           /^X\(\/\/\)$/{ s//\1/; q; }
875           /^X\(\/\).*/{ s//\1/; q; }
876           s/.*/./; q'`
877   srcdir=$ac_confdir
878   if test ! -r $srcdir/$ac_unique_file; then
879     srcdir=..
880   fi
881 else
882   ac_srcdir_defaulted=no
883 fi
884 if test ! -r $srcdir/$ac_unique_file; then
885   if test "$ac_srcdir_defaulted" = yes; then
886     { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
887    { (exit 1); exit 1; }; }
888   else
889     { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
890    { (exit 1); exit 1; }; }
891   fi
892 fi
893 (cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
894   { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
895    { (exit 1); exit 1; }; }
896 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
897 ac_env_build_alias_set=${build_alias+set}
898 ac_env_build_alias_value=$build_alias
899 ac_cv_env_build_alias_set=${build_alias+set}
900 ac_cv_env_build_alias_value=$build_alias
901 ac_env_host_alias_set=${host_alias+set}
902 ac_env_host_alias_value=$host_alias
903 ac_cv_env_host_alias_set=${host_alias+set}
904 ac_cv_env_host_alias_value=$host_alias
905 ac_env_target_alias_set=${target_alias+set}
906 ac_env_target_alias_value=$target_alias
907 ac_cv_env_target_alias_set=${target_alias+set}
908 ac_cv_env_target_alias_value=$target_alias
909 ac_env_CC_set=${CC+set}
910 ac_env_CC_value=$CC
911 ac_cv_env_CC_set=${CC+set}
912 ac_cv_env_CC_value=$CC
913 ac_env_CFLAGS_set=${CFLAGS+set}
914 ac_env_CFLAGS_value=$CFLAGS
915 ac_cv_env_CFLAGS_set=${CFLAGS+set}
916 ac_cv_env_CFLAGS_value=$CFLAGS
917 ac_env_LDFLAGS_set=${LDFLAGS+set}
918 ac_env_LDFLAGS_value=$LDFLAGS
919 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
920 ac_cv_env_LDFLAGS_value=$LDFLAGS
921 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
922 ac_env_CPPFLAGS_value=$CPPFLAGS
923 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
924 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
925 ac_env_CPP_set=${CPP+set}
926 ac_env_CPP_value=$CPP
927 ac_cv_env_CPP_set=${CPP+set}
928 ac_cv_env_CPP_value=$CPP
929
930 #
931 # Report the --help message.
932 #
933 if test "$ac_init_help" = "long"; then
934   # Omit some internal or obsolete options to make the list less imposing.
935   # This message is too long to be a string in the A/UX 3.1 sh.
936   cat <<_ACEOF
937 \`configure' configures this package to adapt to many kinds of systems.
938
939 Usage: $0 [OPTION]... [VAR=VALUE]...
940
941 To assign environment variables (e.g., CC, CFLAGS...), specify them as
942 VAR=VALUE.  See below for descriptions of some of the useful variables.
943
944 Defaults for the options are specified in brackets.
945
946 Configuration:
947   -h, --help              display this help and exit
948       --help=short        display options specific to this package
949       --help=recursive    display the short help of all the included packages
950   -V, --version           display version information and exit
951   -q, --quiet, --silent   do not print \`checking...' messages
952       --cache-file=FILE   cache test results in FILE [disabled]
953   -C, --config-cache      alias for \`--cache-file=config.cache'
954   -n, --no-create         do not create output files
955       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
956
957 _ACEOF
958
959   cat <<_ACEOF
960 Installation directories:
961   --prefix=PREFIX         install architecture-independent files in PREFIX
962                           [$ac_default_prefix]
963   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
964                           [PREFIX]
965
966 By default, \`make install' will install all the files in
967 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
968 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
969 for instance \`--prefix=\$HOME'.
970
971 For better control, use the options below.
972
973 Fine tuning of the installation directories:
974   --bindir=DIR           user executables [EPREFIX/bin]
975   --sbindir=DIR          system admin executables [EPREFIX/sbin]
976   --libexecdir=DIR       program executables [EPREFIX/libexec]
977   --datadir=DIR          read-only architecture-independent data [PREFIX/share]
978   --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
979   --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
980   --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
981   --libdir=DIR           object code libraries [EPREFIX/lib]
982   --includedir=DIR       C header files [PREFIX/include]
983   --oldincludedir=DIR    C header files for non-gcc [/usr/include]
984   --infodir=DIR          info documentation [PREFIX/info]
985   --mandir=DIR           man documentation [PREFIX/man]
986 _ACEOF
987
988   cat <<\_ACEOF
989
990 Program names:
991   --program-prefix=PREFIX            prepend PREFIX to installed program names
992   --program-suffix=SUFFIX            append SUFFIX to installed program names
993   --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
994
995 System types:
996   --build=BUILD     configure for building on BUILD [guessed]
997   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
998   --target=TARGET   configure for building compilers for TARGET [HOST]
999 _ACEOF
1000 fi
1001
1002 if test -n "$ac_init_help"; then
1003
1004   cat <<\_ACEOF
1005
1006 Optional Features:
1007   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1008   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1009   --enable-debug          enable debugging no|yes|traditional [yes]
1010   --enable-dynamic        enable linking built binaries with dynamic libs [no]
1011   --enable-syslog         enable syslog support [auto]
1012   --enable-proctitle      enable proctitle support [yes]
1013   --enable-ipv6           enable IPv6 support [auto]
1014   --enable-local          enable AF_LOCAL (AF_UNIX) socket support [auto]
1015
1016 SLAPD (Standalone LDAP Daemon) Options:
1017   --enable-slapd          enable building slapd [yes]
1018     --enable-dynacl       enable run-time loadable ACL support (experimental) [no]
1019     --enable-aci          enable per-object ACIs (experimental) no|yes|mod [no]
1020     --enable-cleartext    enable cleartext passwords [yes]
1021     --enable-crypt        enable crypt(3) passwords [no]
1022     --enable-lmpasswd     enable LAN Manager passwords [no]
1023     --enable-spasswd      enable (Cyrus) SASL password verification [no]
1024     --enable-modules      enable dynamic module support [no]
1025     --enable-rewrite      enable DN rewriting in back-ldap and rwm overlay [auto]
1026     --enable-rlookups     enable reverse lookups of client hostnames [no]
1027     --enable-slapi        enable SLAPI support (experimental) [no]
1028     --enable-slp          enable SLPv2 support [no]
1029     --enable-wrappers     enable tcp wrapper support [no]
1030
1031 SLAPD Backend Options:
1032     --enable-backends     enable all available backends no|yes|mod
1033     --enable-bdb          enable Berkeley DB backend no|yes|mod [yes]
1034     --enable-dnssrv       enable dnssrv backend no|yes|mod [no]
1035     --enable-hdb          enable Hierarchical DB backend no|yes|mod [yes]
1036     --enable-ldap         enable ldap backend no|yes|mod [no]
1037     --enable-meta         enable metadirectory backend no|yes|mod [no]
1038     --enable-monitor      enable monitor backend no|yes|mod [yes]
1039     --enable-null         enable null backend no|yes|mod [no]
1040     --enable-passwd       enable passwd backend no|yes|mod [no]
1041     --enable-perl         enable perl backend no|yes|mod [no]
1042     --enable-relay        enable relay backend no|yes|mod [yes]
1043     --enable-shell        enable shell backend no|yes|mod [no]
1044     --enable-sql          enable sql backend no|yes|mod [no]
1045
1046 SLAPD Overlay Options:
1047     --enable-overlays     enable all available overlays no|yes|mod
1048     --enable-accesslog    In-Directory Access Logging overlay no|yes|mod [no]
1049     --enable-auditlog     Audit Logging overlay no|yes|mod [no]
1050     --enable-constraint   Attribute Constraint overlay no|yes|mod [no]
1051     --enable-dds          Dynamic Directory Services overlay no|yes|mod [no]
1052     --enable-denyop       Deny Operation overlay no|yes|mod [no]
1053     --enable-dyngroup     Dynamic Group overlay no|yes|mod [no]
1054     --enable-dynlist      Dynamic List overlay no|yes|mod [no]
1055     --enable-lastmod      Last Modification overlay no|yes|mod [no]
1056     --enable-ppolicy      Password Policy overlay no|yes|mod [no]
1057     --enable-proxycache   Proxy Cache overlay no|yes|mod [no]
1058     --enable-refint       Referential Integrity overlay no|yes|mod [no]
1059     --enable-retcode      Return Code testing overlay no|yes|mod [no]
1060     --enable-rwm          Rewrite/Remap overlay no|yes|mod [no]
1061     --enable-seqmod       Sequential Modify overlay no|yes|mod [yes]
1062     --enable-syncprov     Syncrepl Provider overlay no|yes|mod [yes]
1063     --enable-translucent  Translucent Proxy overlay no|yes|mod [no]
1064     --enable-unique       Attribute Uniqueness overlay no|yes|mod [no]
1065     --enable-valsort      Value Sorting overlay no|yes|mod [no]
1066
1067 SLURPD (Replication Daemon) Options:
1068   --enable-slurpd         enable building slurpd [auto]
1069
1070 Library Generation & Linking Options
1071   --enable-static[=PKGS]
1072                           build static libraries [default=yes]
1073   --enable-shared[=PKGS]
1074                           build shared libraries [default=yes]
1075   --enable-fast-install[=PKGS]
1076                           optimize for fast installation [default=yes]
1077   --disable-dependency-tracking  speeds up one-time build
1078   --enable-dependency-tracking   do not reject slow dependency extractors
1079   --disable-libtool-lock  avoid locking (might break parallel builds)
1080
1081 Optional Packages:
1082   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1083   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1084   --with-subdir=DIR       change default subdirectory used for installs
1085   --with-cyrus-sasl       with Cyrus SASL support [auto]
1086   --with-fetch            with fetch(3) URL support [auto]
1087   --with-threads          with threads [auto]
1088   --with-tls              with TLS/SSL support [auto]
1089   --with-yielding-select  with implicitly yielding select [auto]
1090   --with-mp               with multiple precision statistics auto|longlong|long|bignum|gmp [auto]
1091   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1092   --with-pic              try to use only PIC/non-PIC objects [default=use
1093                           both]
1094   --with-tags[=TAGS]
1095                           include additional configurations [automatic]
1096
1097 See INSTALL file for further details.
1098
1099 Some influential environment variables:
1100   CC          C compiler command
1101   CFLAGS      C compiler flags
1102   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1103               nonstandard directory <lib dir>
1104   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
1105               headers in a nonstandard directory <include dir>
1106   CPP         C preprocessor
1107
1108 Use these variables to override the choices made by `configure' or to help
1109 it to find libraries and programs with nonstandard names/locations.
1110
1111 _ACEOF
1112 fi
1113
1114 if test "$ac_init_help" = "recursive"; then
1115   # If there are subdirs, report their specific --help.
1116   ac_popdir=`pwd`
1117   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1118     test -d $ac_dir || continue
1119     ac_builddir=.
1120
1121 if test "$ac_dir" != .; then
1122   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
1123   # A "../" for each directory in $ac_dir_suffix.
1124   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
1125 else
1126   ac_dir_suffix= ac_top_builddir=
1127 fi
1128
1129 case $srcdir in
1130   .)  # No --srcdir option.  We are building in place.
1131     ac_srcdir=.
1132     if test -z "$ac_top_builddir"; then
1133        ac_top_srcdir=.
1134     else
1135        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
1136     fi ;;
1137   [\\/]* | ?:[\\/]* )  # Absolute path.
1138     ac_srcdir=$srcdir$ac_dir_suffix;
1139     ac_top_srcdir=$srcdir ;;
1140   *) # Relative path.
1141     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
1142     ac_top_srcdir=$ac_top_builddir$srcdir ;;
1143 esac
1144
1145 # Do not use `cd foo && pwd` to compute absolute paths, because
1146 # the directories may not exist.
1147 case `pwd` in
1148 .) ac_abs_builddir="$ac_dir";;
1149 *)
1150   case "$ac_dir" in
1151   .) ac_abs_builddir=`pwd`;;
1152   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
1153   *) ac_abs_builddir=`pwd`/"$ac_dir";;
1154   esac;;
1155 esac
1156 case $ac_abs_builddir in
1157 .) ac_abs_top_builddir=${ac_top_builddir}.;;
1158 *)
1159   case ${ac_top_builddir}. in
1160   .) ac_abs_top_builddir=$ac_abs_builddir;;
1161   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
1162   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
1163   esac;;
1164 esac
1165 case $ac_abs_builddir in
1166 .) ac_abs_srcdir=$ac_srcdir;;
1167 *)
1168   case $ac_srcdir in
1169   .) ac_abs_srcdir=$ac_abs_builddir;;
1170   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
1171   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
1172   esac;;
1173 esac
1174 case $ac_abs_builddir in
1175 .) ac_abs_top_srcdir=$ac_top_srcdir;;
1176 *)
1177   case $ac_top_srcdir in
1178   .) ac_abs_top_srcdir=$ac_abs_builddir;;
1179   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
1180   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
1181   esac;;
1182 esac
1183
1184     cd $ac_dir
1185     # Check for guested configure; otherwise get Cygnus style configure.
1186     if test -f $ac_srcdir/configure.gnu; then
1187       echo
1188       $SHELL $ac_srcdir/configure.gnu  --help=recursive
1189     elif test -f $ac_srcdir/configure; then
1190       echo
1191       $SHELL $ac_srcdir/configure  --help=recursive
1192     elif test -f $ac_srcdir/configure.ac ||
1193            test -f $ac_srcdir/configure.in; then
1194       echo
1195       $ac_configure --help
1196     else
1197       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1198     fi
1199     cd $ac_popdir
1200   done
1201 fi
1202
1203 test -n "$ac_init_help" && exit 0
1204 if $ac_init_version; then
1205   cat <<\_ACEOF
1206
1207 Copyright (C) 2003 Free Software Foundation, Inc.
1208 This configure script is free software; the Free Software Foundation
1209 gives unlimited permission to copy, distribute and modify it.
1210
1211 Copyright 1998-2006 The OpenLDAP Foundation. All rights reserved.
1212 Restrictions apply, see COPYRIGHT and LICENSE files.
1213 _ACEOF
1214   exit 0
1215 fi
1216 exec 5>config.log
1217 cat >&5 <<_ACEOF
1218 This file contains any messages produced by compilers while
1219 running configure, to aid debugging if configure makes a mistake.
1220
1221 It was created by $as_me, which was
1222 generated by GNU Autoconf 2.59.  Invocation command line was
1223
1224   $ $0 $@
1225
1226 _ACEOF
1227 {
1228 cat <<_ASUNAME
1229 ## --------- ##
1230 ## Platform. ##
1231 ## --------- ##
1232
1233 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1234 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1235 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1236 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1237 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1238
1239 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1240 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1241
1242 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1243 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1244 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1245 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
1246 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1247 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1248 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1249
1250 _ASUNAME
1251
1252 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1253 for as_dir in $PATH
1254 do
1255   IFS=$as_save_IFS
1256   test -z "$as_dir" && as_dir=.
1257   echo "PATH: $as_dir"
1258 done
1259
1260 } >&5
1261
1262 cat >&5 <<_ACEOF
1263
1264
1265 ## ----------- ##
1266 ## Core tests. ##
1267 ## ----------- ##
1268
1269 _ACEOF
1270
1271
1272 # Keep a trace of the command line.
1273 # Strip out --no-create and --no-recursion so they do not pile up.
1274 # Strip out --silent because we don't want to record it for future runs.
1275 # Also quote any args containing shell meta-characters.
1276 # Make two passes to allow for proper duplicate-argument suppression.
1277 ac_configure_args=
1278 ac_configure_args0=
1279 ac_configure_args1=
1280 ac_sep=
1281 ac_must_keep_next=false
1282 for ac_pass in 1 2
1283 do
1284   for ac_arg
1285   do
1286     case $ac_arg in
1287     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1288     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1289     | -silent | --silent | --silen | --sile | --sil)
1290       continue ;;
1291     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1292       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1293     esac
1294     case $ac_pass in
1295     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1296     2)
1297       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1298       if test $ac_must_keep_next = true; then
1299         ac_must_keep_next=false # Got value, back to normal.
1300       else
1301         case $ac_arg in
1302           *=* | --config-cache | -C | -disable-* | --disable-* \
1303           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1304           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1305           | -with-* | --with-* | -without-* | --without-* | --x)
1306             case "$ac_configure_args0 " in
1307               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1308             esac
1309             ;;
1310           -* ) ac_must_keep_next=true ;;
1311         esac
1312       fi
1313       ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1314       # Get rid of the leading space.
1315       ac_sep=" "
1316       ;;
1317     esac
1318   done
1319 done
1320 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1321 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1322
1323 # When interrupted or exit'd, cleanup temporary files, and complete
1324 # config.log.  We remove comments because anyway the quotes in there
1325 # would cause problems or look ugly.
1326 # WARNING: Be sure not to use single quotes in there, as some shells,
1327 # such as our DU 5.0 friend, will then `close' the trap.
1328 trap 'exit_status=$?
1329   # Save into config.log some information that might help in debugging.
1330   {
1331     echo
1332
1333     cat <<\_ASBOX
1334 ## ---------------- ##
1335 ## Cache variables. ##
1336 ## ---------------- ##
1337 _ASBOX
1338     echo
1339     # The following way of writing the cache mishandles newlines in values,
1340 {
1341   (set) 2>&1 |
1342     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1343     *ac_space=\ *)
1344       sed -n \
1345         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1346           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1347       ;;
1348     *)
1349       sed -n \
1350         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1351       ;;
1352     esac;
1353 }
1354     echo
1355
1356     cat <<\_ASBOX
1357 ## ----------------- ##
1358 ## Output variables. ##
1359 ## ----------------- ##
1360 _ASBOX
1361     echo
1362     for ac_var in $ac_subst_vars
1363     do
1364       eval ac_val=$`echo $ac_var`
1365       echo "$ac_var='"'"'$ac_val'"'"'"
1366     done | sort
1367     echo
1368
1369     if test -n "$ac_subst_files"; then
1370       cat <<\_ASBOX
1371 ## ------------- ##
1372 ## Output files. ##
1373 ## ------------- ##
1374 _ASBOX
1375       echo
1376       for ac_var in $ac_subst_files
1377       do
1378         eval ac_val=$`echo $ac_var`
1379         echo "$ac_var='"'"'$ac_val'"'"'"
1380       done | sort
1381       echo
1382     fi
1383
1384     if test -s confdefs.h; then
1385       cat <<\_ASBOX
1386 ## ----------- ##
1387 ## confdefs.h. ##
1388 ## ----------- ##
1389 _ASBOX
1390       echo
1391       sed "/^$/d" confdefs.h | sort
1392       echo
1393     fi
1394     test "$ac_signal" != 0 &&
1395       echo "$as_me: caught signal $ac_signal"
1396     echo "$as_me: exit $exit_status"
1397   } >&5
1398   rm -f core *.core &&
1399   rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1400     exit $exit_status
1401      ' 0
1402 for ac_signal in 1 2 13 15; do
1403   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1404 done
1405 ac_signal=0
1406
1407 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1408 rm -rf conftest* confdefs.h
1409 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1410 echo >confdefs.h
1411
1412 # Predefined preprocessor variables.
1413
1414 cat >>confdefs.h <<_ACEOF
1415 #define PACKAGE_NAME "$PACKAGE_NAME"
1416 _ACEOF
1417
1418
1419 cat >>confdefs.h <<_ACEOF
1420 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1421 _ACEOF
1422
1423
1424 cat >>confdefs.h <<_ACEOF
1425 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1426 _ACEOF
1427
1428
1429 cat >>confdefs.h <<_ACEOF
1430 #define PACKAGE_STRING "$PACKAGE_STRING"
1431 _ACEOF
1432
1433
1434 cat >>confdefs.h <<_ACEOF
1435 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1436 _ACEOF
1437
1438
1439 # Let the site file select an alternate cache file if it wants to.
1440 # Prefer explicitly selected file to automatically selected ones.
1441 if test -z "$CONFIG_SITE"; then
1442   if test "x$prefix" != xNONE; then
1443     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1444   else
1445     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1446   fi
1447 fi
1448 for ac_site_file in $CONFIG_SITE; do
1449   if test -r "$ac_site_file"; then
1450     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1451 echo "$as_me: loading site script $ac_site_file" >&6;}
1452     sed 's/^/| /' "$ac_site_file" >&5
1453     . "$ac_site_file"
1454   fi
1455 done
1456
1457
1458 # Check that the precious variables saved in the cache have kept the same
1459 # value.
1460 ac_cache_corrupted=false
1461 for ac_var in `(set) 2>&1 |
1462                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1463   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1464   eval ac_new_set=\$ac_env_${ac_var}_set
1465   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1466   eval ac_new_val="\$ac_env_${ac_var}_value"
1467   case $ac_old_set,$ac_new_set in
1468     set,)
1469       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1470 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1471       ac_cache_corrupted=: ;;
1472     ,set)
1473       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1474 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1475       ac_cache_corrupted=: ;;
1476     ,);;
1477     *)
1478       if test "x$ac_old_val" != "x$ac_new_val"; then
1479         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1480 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1481         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1482 echo "$as_me:   former value:  $ac_old_val" >&2;}
1483         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1484 echo "$as_me:   current value: $ac_new_val" >&2;}
1485         ac_cache_corrupted=:
1486       fi;;
1487   esac
1488   # Pass precious variables to config.status.
1489   if test "$ac_new_set" = set; then
1490     case $ac_new_val in
1491     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1492       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1493     *) ac_arg=$ac_var=$ac_new_val ;;
1494     esac
1495     case " $ac_configure_args " in
1496       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1497       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1498     esac
1499   fi
1500 done
1501 if $ac_cache_corrupted; then
1502   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1503 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1504   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1505 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1506    { (exit 1); exit 1; }; }
1507 fi
1508
1509 ac_ext=c
1510 ac_cpp='$CPP $CPPFLAGS'
1511 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1512 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1513 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557 ac_aux_dir=
1558 for ac_dir in build $srcdir/build; do
1559   if test -f $ac_dir/install-sh; then
1560     ac_aux_dir=$ac_dir
1561     ac_install_sh="$ac_aux_dir/install-sh -c"
1562     break
1563   elif test -f $ac_dir/install.sh; then
1564     ac_aux_dir=$ac_dir
1565     ac_install_sh="$ac_aux_dir/install.sh -c"
1566     break
1567   elif test -f $ac_dir/shtool; then
1568     ac_aux_dir=$ac_dir
1569     ac_install_sh="$ac_aux_dir/shtool install -c"
1570     break
1571   fi
1572 done
1573 if test -z "$ac_aux_dir"; then
1574   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in build $srcdir/build" >&5
1575 echo "$as_me: error: cannot find install-sh or install.sh in build $srcdir/build" >&2;}
1576    { (exit 1); exit 1; }; }
1577 fi
1578 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1579 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1580 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1581
1582 eval `$ac_aux_dir/version.sh`
1583 if test -z "$OL_STRING"; then
1584         { { echo "$as_me:$LINENO: error: could not determine version" >&5
1585 echo "$as_me: error: could not determine version" >&2;}
1586    { (exit 1); exit 1; }; }
1587 fi
1588
1589 if test -f "$ac_aux_dir/shtool" && test ! -d $ac_aux_dir/shtool; then
1590         ac_cv_shtool="$ac_aux_dir/shtool"
1591 else
1592         { { echo "$as_me:$LINENO: error: no shtool found in $ac_aux_dir" >&5
1593 echo "$as_me: error: no shtool found in $ac_aux_dir" >&2;}
1594    { (exit 1); exit 1; }; }
1595 fi
1596
1597 SHTOOL="$ac_cv_shtool"
1598
1599 TB="`$SHTOOL echo -e '%B' 2>/dev/null`"
1600 TN="`$SHTOOL echo -e '%b' 2>/dev/null`"
1601
1602 OPENLDAP_CVS=""
1603 if test -d $ac_aux_dir/CVS; then
1604         OPENLDAP_CVS="(from CVS sources) "
1605 fi
1606
1607 echo "Configuring ${TB}${OL_STRING}${TN} ${OPENLDAP_CVS}..."
1608
1609 # Make sure we can run config.sub.
1610 $ac_config_sub sun4 >/dev/null 2>&1 ||
1611   { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
1612 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1613    { (exit 1); exit 1; }; }
1614
1615 echo "$as_me:$LINENO: checking build system type" >&5
1616 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1617 if test "${ac_cv_build+set}" = set; then
1618   echo $ECHO_N "(cached) $ECHO_C" >&6
1619 else
1620   ac_cv_build_alias=$build_alias
1621 test -z "$ac_cv_build_alias" &&
1622   ac_cv_build_alias=`$ac_config_guess`
1623 test -z "$ac_cv_build_alias" &&
1624   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1625 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1626    { (exit 1); exit 1; }; }
1627 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1628   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1629 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
1630    { (exit 1); exit 1; }; }
1631
1632 fi
1633 echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1634 echo "${ECHO_T}$ac_cv_build" >&6
1635 build=$ac_cv_build
1636 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1637 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1638 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1639
1640
1641 echo "$as_me:$LINENO: checking host system type" >&5
1642 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1643 if test "${ac_cv_host+set}" = set; then
1644   echo $ECHO_N "(cached) $ECHO_C" >&6
1645 else
1646   ac_cv_host_alias=$host_alias
1647 test -z "$ac_cv_host_alias" &&
1648   ac_cv_host_alias=$ac_cv_build_alias
1649 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1650   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1651 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1652    { (exit 1); exit 1; }; }
1653
1654 fi
1655 echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1656 echo "${ECHO_T}$ac_cv_host" >&6
1657 host=$ac_cv_host
1658 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1659 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1660 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1661
1662
1663 echo "$as_me:$LINENO: checking target system type" >&5
1664 echo $ECHO_N "checking target system type... $ECHO_C" >&6
1665 if test "${ac_cv_target+set}" = set; then
1666   echo $ECHO_N "(cached) $ECHO_C" >&6
1667 else
1668   ac_cv_target_alias=$target_alias
1669 test "x$ac_cv_target_alias" = "x" &&
1670   ac_cv_target_alias=$ac_cv_host_alias
1671 ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
1672   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1673 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
1674    { (exit 1); exit 1; }; }
1675
1676 fi
1677 echo "$as_me:$LINENO: result: $ac_cv_target" >&5
1678 echo "${ECHO_T}$ac_cv_target" >&6
1679 target=$ac_cv_target
1680 target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1681 target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1682 target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1683
1684
1685 # The aliases save the names the user supplied, while $host etc.
1686 # will get canonicalized.
1687 test -n "$target_alias" &&
1688   test "$program_prefix$program_suffix$program_transform_name" = \
1689     NONENONEs,x,x, &&
1690   program_prefix=${target_alias}-
1691
1692 am__api_version="1.9"
1693 # Find a good install program.  We prefer a C program (faster),
1694 # so one script is as good as another.  But avoid the broken or
1695 # incompatible versions:
1696 # SysV /etc/install, /usr/sbin/install
1697 # SunOS /usr/etc/install
1698 # IRIX /sbin/install
1699 # AIX /bin/install
1700 # AmigaOS /C/install, which installs bootblocks on floppy discs
1701 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1702 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
1703 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1704 # OS/2's system install, which has a completely different semantic
1705 # ./install, which can be erroneously created by make from ./install.sh.
1706 echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
1707 echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
1708 if test -z "$INSTALL"; then
1709 if test "${ac_cv_path_install+set}" = set; then
1710   echo $ECHO_N "(cached) $ECHO_C" >&6
1711 else
1712   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1713 for as_dir in $PATH
1714 do
1715   IFS=$as_save_IFS
1716   test -z "$as_dir" && as_dir=.
1717   # Account for people who put trailing slashes in PATH elements.
1718 case $as_dir/ in
1719   ./ | .// | /cC/* | \
1720   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
1721   ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
1722   /usr/ucb/* ) ;;
1723   *)
1724     # OSF1 and SCO ODT 3.0 have their own names for install.
1725     # Don't use installbsd from OSF since it installs stuff as root
1726     # by default.
1727     for ac_prog in ginstall scoinst install; do
1728       for ac_exec_ext in '' $ac_executable_extensions; do
1729         if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
1730           if test $ac_prog = install &&
1731             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
1732             # AIX install.  It has an incompatible calling convention.
1733             :
1734           elif test $ac_prog = install &&
1735             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
1736             # program-specific install script used by HP pwplus--don't use.
1737             :
1738           else
1739             ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
1740             break 3
1741           fi
1742         fi
1743       done
1744     done
1745     ;;
1746 esac
1747 done
1748
1749
1750 fi
1751   if test "${ac_cv_path_install+set}" = set; then
1752     INSTALL=$ac_cv_path_install
1753   else
1754     # As a last resort, use the slow shell script.  We don't cache a
1755     # path for INSTALL within a source directory, because that will
1756     # break other packages using the cache if that directory is
1757     # removed, or if the path is relative.
1758     INSTALL=$ac_install_sh
1759   fi
1760 fi
1761 echo "$as_me:$LINENO: result: $INSTALL" >&5
1762 echo "${ECHO_T}$INSTALL" >&6
1763
1764 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1765 # It thinks the first close brace ends the variable substitution.
1766 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1767
1768 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
1769
1770 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1771
1772 echo "$as_me:$LINENO: checking whether build environment is sane" >&5
1773 echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6
1774 # Just in case
1775 sleep 1
1776 echo timestamp > conftest.file
1777 # Do `set' in a subshell so we don't clobber the current shell's
1778 # arguments.  Must try -L first in case configure is actually a
1779 # symlink; some systems play weird games with the mod time of symlinks
1780 # (eg FreeBSD returns the mod time of the symlink's containing
1781 # directory).
1782 if (
1783    set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
1784    if test "$*" = "X"; then
1785       # -L didn't work.
1786       set X `ls -t $srcdir/configure conftest.file`
1787    fi
1788    rm -f conftest.file
1789    if test "$*" != "X $srcdir/configure conftest.file" \
1790       && test "$*" != "X conftest.file $srcdir/configure"; then
1791
1792       # If neither matched, then we have a broken ls.  This can happen
1793       # if, for instance, CONFIG_SHELL is bash and it inherits a
1794       # broken ls alias from the environment.  This has actually
1795       # happened.  Such a system could not be considered "sane".
1796       { { echo "$as_me:$LINENO: error: ls -t appears to fail.  Make sure there is not a broken
1797 alias in your environment" >&5
1798 echo "$as_me: error: ls -t appears to fail.  Make sure there is not a broken
1799 alias in your environment" >&2;}
1800    { (exit 1); exit 1; }; }
1801    fi
1802
1803    test "$2" = conftest.file
1804    )
1805 then
1806    # Ok.
1807    :
1808 else
1809    { { echo "$as_me:$LINENO: error: newly created file is older than distributed files!
1810 Check your system clock" >&5
1811 echo "$as_me: error: newly created file is older than distributed files!
1812 Check your system clock" >&2;}
1813    { (exit 1); exit 1; }; }
1814 fi
1815 echo "$as_me:$LINENO: result: yes" >&5
1816 echo "${ECHO_T}yes" >&6
1817 test "$program_prefix" != NONE &&
1818   program_transform_name="s,^,$program_prefix,;$program_transform_name"
1819 # Use a double $ so make ignores it.
1820 test "$program_suffix" != NONE &&
1821   program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1822 # Double any \ or $.  echo might interpret backslashes.
1823 # By default was `s,x,x', remove it if useless.
1824 cat <<\_ACEOF >conftest.sed
1825 s/[\\$]/&&/g;s/;s,x,x,$//
1826 _ACEOF
1827 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1828 rm conftest.sed
1829
1830 # expand $ac_aux_dir to an absolute path
1831 am_aux_dir=`cd $ac_aux_dir && pwd`
1832
1833 test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
1834 # Use eval to expand $SHELL
1835 if eval "$MISSING --run true"; then
1836   am_missing_run="$MISSING --run "
1837 else
1838   am_missing_run=
1839   { echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5
1840 echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
1841 fi
1842
1843 if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then
1844   # We used to keeping the `.' as first argument, in order to
1845   # allow $(mkdir_p) to be used without argument.  As in
1846   #   $(mkdir_p) $(somedir)
1847   # where $(somedir) is conditionally defined.  However this is wrong
1848   # for two reasons:
1849   #  1. if the package is installed by a user who cannot write `.'
1850   #     make install will fail,
1851   #  2. the above comment should most certainly read
1852   #     $(mkdir_p) $(DESTDIR)$(somedir)
1853   #     so it does not work when $(somedir) is undefined and
1854   #     $(DESTDIR) is not.
1855   #  To support the latter case, we have to write
1856   #     test -z "$(somedir)" || $(mkdir_p) $(DESTDIR)$(somedir),
1857   #  so the `.' trick is pointless.
1858   mkdir_p='mkdir -p --'
1859 else
1860   # On NextStep and OpenStep, the `mkdir' command does not
1861   # recognize any option.  It will interpret all options as
1862   # directories to create, and then abort because `.' already
1863   # exists.
1864   for d in ./-p ./--version;
1865   do
1866     test -d $d && rmdir $d
1867   done
1868   # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists.
1869   if test -f "$ac_aux_dir/mkinstalldirs"; then
1870     mkdir_p='$(mkinstalldirs)'
1871   else
1872     mkdir_p='$(install_sh) -d'
1873   fi
1874 fi
1875
1876 for ac_prog in gawk mawk nawk awk
1877 do
1878   # Extract the first word of "$ac_prog", so it can be a program name with args.
1879 set dummy $ac_prog; ac_word=$2
1880 echo "$as_me:$LINENO: checking for $ac_word" >&5
1881 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1882 if test "${ac_cv_prog_AWK+set}" = set; then
1883   echo $ECHO_N "(cached) $ECHO_C" >&6
1884 else
1885   if test -n "$AWK"; then
1886   ac_cv_prog_AWK="$AWK" # Let the user override the test.
1887 else
1888 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1889 for as_dir in $PATH
1890 do
1891   IFS=$as_save_IFS
1892   test -z "$as_dir" && as_dir=.
1893   for ac_exec_ext in '' $ac_executable_extensions; do
1894   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1895     ac_cv_prog_AWK="$ac_prog"
1896     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1897     break 2
1898   fi
1899 done
1900 done
1901
1902 fi
1903 fi
1904 AWK=$ac_cv_prog_AWK
1905 if test -n "$AWK"; then
1906   echo "$as_me:$LINENO: result: $AWK" >&5
1907 echo "${ECHO_T}$AWK" >&6
1908 else
1909   echo "$as_me:$LINENO: result: no" >&5
1910 echo "${ECHO_T}no" >&6
1911 fi
1912
1913   test -n "$AWK" && break
1914 done
1915
1916 echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
1917 echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
1918 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'`
1919 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1920   echo $ECHO_N "(cached) $ECHO_C" >&6
1921 else
1922   cat >conftest.make <<\_ACEOF
1923 all:
1924         @echo 'ac_maketemp="$(MAKE)"'
1925 _ACEOF
1926 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1927 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1928 if test -n "$ac_maketemp"; then
1929   eval ac_cv_prog_make_${ac_make}_set=yes
1930 else
1931   eval ac_cv_prog_make_${ac_make}_set=no
1932 fi
1933 rm -f conftest.make
1934 fi
1935 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1936   echo "$as_me:$LINENO: result: yes" >&5
1937 echo "${ECHO_T}yes" >&6
1938   SET_MAKE=
1939 else
1940   echo "$as_me:$LINENO: result: no" >&5
1941 echo "${ECHO_T}no" >&6
1942   SET_MAKE="MAKE=${MAKE-make}"
1943 fi
1944
1945 rm -rf .tst 2>/dev/null
1946 mkdir .tst 2>/dev/null
1947 if test -d .tst; then
1948   am__leading_dot=.
1949 else
1950   am__leading_dot=_
1951 fi
1952 rmdir .tst 2>/dev/null
1953
1954 # test to see if srcdir already configured
1955 if test "`cd $srcdir && pwd`" != "`pwd`" &&
1956    test -f $srcdir/config.status; then
1957   { { echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5
1958 echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;}
1959    { (exit 1); exit 1; }; }
1960 fi
1961
1962 # test whether we have cygpath
1963 if test -z "$CYGPATH_W"; then
1964   if (cygpath --version) >/dev/null 2>/dev/null; then
1965     CYGPATH_W='cygpath -w'
1966   else
1967     CYGPATH_W=echo
1968   fi
1969 fi
1970
1971
1972 # Define the identity of the package.
1973  PACKAGE=$OL_PACKAGE
1974  VERSION=$OL_VERSION
1975
1976
1977 # Some tools Automake needs.
1978
1979 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
1980
1981
1982 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
1983
1984
1985 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
1986
1987
1988 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
1989
1990
1991 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
1992
1993 install_sh=${install_sh-"$am_aux_dir/install-sh"}
1994
1995 # Installed binaries are usually stripped using `strip' when the user
1996 # run `make install-strip'.  However `strip' might not be the right
1997 # tool to use in cross-compilation environments, therefore Automake
1998 # will honor the `STRIP' environment variable to overrule this program.
1999 if test "$cross_compiling" != no; then
2000   if test -n "$ac_tool_prefix"; then
2001   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
2002 set dummy ${ac_tool_prefix}strip; ac_word=$2
2003 echo "$as_me:$LINENO: checking for $ac_word" >&5
2004 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2005 if test "${ac_cv_prog_STRIP+set}" = set; then
2006   echo $ECHO_N "(cached) $ECHO_C" >&6
2007 else
2008   if test -n "$STRIP"; then
2009   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
2010 else
2011 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2012 for as_dir in $PATH
2013 do
2014   IFS=$as_save_IFS
2015   test -z "$as_dir" && as_dir=.
2016   for ac_exec_ext in '' $ac_executable_extensions; do
2017   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2018     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
2019     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2020     break 2
2021   fi
2022 done
2023 done
2024
2025 fi
2026 fi
2027 STRIP=$ac_cv_prog_STRIP
2028 if test -n "$STRIP"; then
2029   echo "$as_me:$LINENO: result: $STRIP" >&5
2030 echo "${ECHO_T}$STRIP" >&6
2031 else
2032   echo "$as_me:$LINENO: result: no" >&5
2033 echo "${ECHO_T}no" >&6
2034 fi
2035
2036 fi
2037 if test -z "$ac_cv_prog_STRIP"; then
2038   ac_ct_STRIP=$STRIP
2039   # Extract the first word of "strip", so it can be a program name with args.
2040 set dummy strip; ac_word=$2
2041 echo "$as_me:$LINENO: checking for $ac_word" >&5
2042 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2043 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
2044   echo $ECHO_N "(cached) $ECHO_C" >&6
2045 else
2046   if test -n "$ac_ct_STRIP"; then
2047   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
2048 else
2049 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2050 for as_dir in $PATH
2051 do
2052   IFS=$as_save_IFS
2053   test -z "$as_dir" && as_dir=.
2054   for ac_exec_ext in '' $ac_executable_extensions; do
2055   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2056     ac_cv_prog_ac_ct_STRIP="strip"
2057     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2058     break 2
2059   fi
2060 done
2061 done
2062
2063   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
2064 fi
2065 fi
2066 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
2067 if test -n "$ac_ct_STRIP"; then
2068   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
2069 echo "${ECHO_T}$ac_ct_STRIP" >&6
2070 else
2071   echo "$as_me:$LINENO: result: no" >&5
2072 echo "${ECHO_T}no" >&6
2073 fi
2074
2075   STRIP=$ac_ct_STRIP
2076 else
2077   STRIP="$ac_cv_prog_STRIP"
2078 fi
2079
2080 fi
2081 INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
2082
2083 # We need awk for the "check" target.  The system "awk" is bad on
2084 # some platforms.
2085 # Always define AMTAR for backward compatibility.
2086
2087 AMTAR=${AMTAR-"${am_missing_run}tar"}
2088
2089 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
2090
2091
2092
2093
2094
2095 cat >>confdefs.h <<_ACEOF
2096 #define OPENLDAP_PACKAGE "$PACKAGE"
2097 _ACEOF
2098
2099
2100 cat >>confdefs.h <<_ACEOF
2101 #define OPENLDAP_VERSION "$VERSION"
2102 _ACEOF
2103
2104
2105
2106 cat >>confdefs.h <<_ACEOF
2107 #define LDAP_VENDOR_VERSION $OL_API_INC
2108 _ACEOF
2109
2110
2111 cat >>confdefs.h <<_ACEOF
2112 #define LDAP_VENDOR_VERSION_MAJOR $OL_MAJOR
2113 _ACEOF
2114
2115
2116 cat >>confdefs.h <<_ACEOF
2117 #define LDAP_VENDOR_VERSION_MINOR $OL_MINOR
2118 _ACEOF
2119
2120
2121 cat >>confdefs.h <<_ACEOF
2122 #define LDAP_VENDOR_VERSION_PATCH $OL_PATCH
2123 _ACEOF
2124
2125
2126 OPENLDAP_LIBRELEASE=$OL_API_LIB_RELEASE
2127
2128 OPENLDAP_LIBVERSION=$OL_API_LIB_VERSION
2129
2130 OPENLDAP_RELEASE_DATE="$OL_RELEASE_DATE"
2131
2132
2133
2134
2135
2136
2137
2138           ac_config_headers="$ac_config_headers include/portable.h:include/portable.hin"
2139
2140           ac_config_headers="$ac_config_headers include/ldap_features.h:include/ldap_features.hin"
2141
2142           ac_config_headers="$ac_config_headers include/lber_types.h:include/lber_types.hin"
2143
2144
2145 echo "$as_me:$LINENO: checking configure arguments" >&5
2146 echo $ECHO_N "checking configure arguments... $ECHO_C" >&6
2147
2148
2149 top_builddir=`pwd`
2150
2151 ldap_subdir="/openldap"
2152
2153
2154 # Check whether --with-subdir or --without-subdir was given.
2155 if test "${with_subdir+set}" = set; then
2156   withval="$with_subdir"
2157   case "$withval" in
2158         no) ldap_subdir=""
2159                 ;;
2160         yes)
2161                 ;;
2162         /*|\\*)
2163                 ldap_subdir="$withval"
2164                 ;;
2165         *)
2166                 ldap_subdir="/$withval"
2167                 ;;
2168 esac
2169
2170 fi;
2171
2172 # OpenLDAP --enable-debug
2173
2174         # Check whether --enable-debug or --disable-debug was given.
2175 if test "${enable_debug+set}" = set; then
2176   enableval="$enable_debug"
2177
2178         ol_arg=invalid
2179         for ol_val in no yes traditional ; do
2180                 if test "$enableval" = "$ol_val" ; then
2181                         ol_arg="$ol_val"
2182                 fi
2183         done
2184         if test "$ol_arg" = "invalid" ; then
2185                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-debug" >&5
2186 echo "$as_me: error: bad value $enableval for --enable-debug" >&2;}
2187    { (exit 1); exit 1; }; }
2188         fi
2189         ol_enable_debug="$ol_arg"
2190
2191 else
2192         ol_enable_debug=yes
2193 fi;
2194 # end --enable-debug
2195 # OpenLDAP --enable-dynamic
2196
2197         # Check whether --enable-dynamic or --disable-dynamic was given.
2198 if test "${enable_dynamic+set}" = set; then
2199   enableval="$enable_dynamic"
2200
2201         ol_arg=invalid
2202         for ol_val in auto yes no ; do
2203                 if test "$enableval" = "$ol_val" ; then
2204                         ol_arg="$ol_val"
2205                 fi
2206         done
2207         if test "$ol_arg" = "invalid" ; then
2208                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dynamic" >&5
2209 echo "$as_me: error: bad value $enableval for --enable-dynamic" >&2;}
2210    { (exit 1); exit 1; }; }
2211         fi
2212         ol_enable_dynamic="$ol_arg"
2213
2214 else
2215         ol_enable_dynamic=no
2216 fi;
2217 # end --enable-dynamic
2218 # OpenLDAP --enable-syslog
2219
2220         # Check whether --enable-syslog or --disable-syslog was given.
2221 if test "${enable_syslog+set}" = set; then
2222   enableval="$enable_syslog"
2223
2224         ol_arg=invalid
2225         for ol_val in auto yes no ; do
2226                 if test "$enableval" = "$ol_val" ; then
2227                         ol_arg="$ol_val"
2228                 fi
2229         done
2230         if test "$ol_arg" = "invalid" ; then
2231                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-syslog" >&5
2232 echo "$as_me: error: bad value $enableval for --enable-syslog" >&2;}
2233    { (exit 1); exit 1; }; }
2234         fi
2235         ol_enable_syslog="$ol_arg"
2236
2237 else
2238         ol_enable_syslog=auto
2239 fi;
2240 # end --enable-syslog
2241 # OpenLDAP --enable-proctitle
2242
2243         # Check whether --enable-proctitle or --disable-proctitle was given.
2244 if test "${enable_proctitle+set}" = set; then
2245   enableval="$enable_proctitle"
2246
2247         ol_arg=invalid
2248         for ol_val in auto yes no ; do
2249                 if test "$enableval" = "$ol_val" ; then
2250                         ol_arg="$ol_val"
2251                 fi
2252         done
2253         if test "$ol_arg" = "invalid" ; then
2254                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-proctitle" >&5
2255 echo "$as_me: error: bad value $enableval for --enable-proctitle" >&2;}
2256    { (exit 1); exit 1; }; }
2257         fi
2258         ol_enable_proctitle="$ol_arg"
2259
2260 else
2261         ol_enable_proctitle=yes
2262 fi;
2263 # end --enable-proctitle
2264 ol_enable_referrals=${ol_enable_referrals-no}
2265 ol_enable_kbind=${ol_enable_kbind-no}
2266 # OpenLDAP --enable-ipv6
2267
2268         # Check whether --enable-ipv6 or --disable-ipv6 was given.
2269 if test "${enable_ipv6+set}" = set; then
2270   enableval="$enable_ipv6"
2271
2272         ol_arg=invalid
2273         for ol_val in auto yes no ; do
2274                 if test "$enableval" = "$ol_val" ; then
2275                         ol_arg="$ol_val"
2276                 fi
2277         done
2278         if test "$ol_arg" = "invalid" ; then
2279                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ipv6" >&5
2280 echo "$as_me: error: bad value $enableval for --enable-ipv6" >&2;}
2281    { (exit 1); exit 1; }; }
2282         fi
2283         ol_enable_ipv6="$ol_arg"
2284
2285 else
2286         ol_enable_ipv6=auto
2287 fi;
2288 # end --enable-ipv6
2289 # OpenLDAP --enable-local
2290
2291         # Check whether --enable-local or --disable-local was given.
2292 if test "${enable_local+set}" = set; then
2293   enableval="$enable_local"
2294
2295         ol_arg=invalid
2296         for ol_val in auto yes no ; do
2297                 if test "$enableval" = "$ol_val" ; then
2298                         ol_arg="$ol_val"
2299                 fi
2300         done
2301         if test "$ol_arg" = "invalid" ; then
2302                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-local" >&5
2303 echo "$as_me: error: bad value $enableval for --enable-local" >&2;}
2304    { (exit 1); exit 1; }; }
2305         fi
2306         ol_enable_local="$ol_arg"
2307
2308 else
2309         ol_enable_local=auto
2310 fi;
2311 # end --enable-local
2312
2313 # OpenLDAP --with-cyrus_sasl
2314
2315 # Check whether --with-cyrus_sasl or --without-cyrus_sasl was given.
2316 if test "${with_cyrus_sasl+set}" = set; then
2317   withval="$with_cyrus_sasl"
2318
2319         ol_arg=invalid
2320         for ol_val in auto yes no  ; do
2321                 if test "$withval" = "$ol_val" ; then
2322                         ol_arg="$ol_val"
2323                 fi
2324         done
2325         if test "$ol_arg" = "invalid" ; then
2326                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-cyrus_sasl" >&5
2327 echo "$as_me: error: bad value $withval for --with-cyrus_sasl" >&2;}
2328    { (exit 1); exit 1; }; }
2329         fi
2330         ol_with_cyrus_sasl="$ol_arg"
2331
2332 else
2333         ol_with_cyrus_sasl="auto"
2334 fi; # end --with-cyrus_sasl
2335
2336 # OpenLDAP --with-fetch
2337
2338 # Check whether --with-fetch or --without-fetch was given.
2339 if test "${with_fetch+set}" = set; then
2340   withval="$with_fetch"
2341
2342         ol_arg=invalid
2343         for ol_val in auto yes no  ; do
2344                 if test "$withval" = "$ol_val" ; then
2345                         ol_arg="$ol_val"
2346                 fi
2347         done
2348         if test "$ol_arg" = "invalid" ; then
2349                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-fetch" >&5
2350 echo "$as_me: error: bad value $withval for --with-fetch" >&2;}
2351    { (exit 1); exit 1; }; }
2352         fi
2353         ol_with_fetch="$ol_arg"
2354
2355 else
2356         ol_with_fetch="auto"
2357 fi; # end --with-fetch
2358
2359 ol_with_kerberos=${ol_with_kerberos-auto}
2360 # OpenLDAP --with-threads
2361
2362 # Check whether --with-threads or --without-threads was given.
2363 if test "${with_threads+set}" = set; then
2364   withval="$with_threads"
2365
2366         ol_arg=invalid
2367         for ol_val in auto nt posix mach pth lwp yes no manual  ; do
2368                 if test "$withval" = "$ol_val" ; then
2369                         ol_arg="$ol_val"
2370                 fi
2371         done
2372         if test "$ol_arg" = "invalid" ; then
2373                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-threads" >&5
2374 echo "$as_me: error: bad value $withval for --with-threads" >&2;}
2375    { (exit 1); exit 1; }; }
2376         fi
2377         ol_with_threads="$ol_arg"
2378
2379 else
2380         ol_with_threads="auto"
2381 fi; # end --with-threads
2382
2383 # OpenLDAP --with-tls
2384
2385 # Check whether --with-tls or --without-tls was given.
2386 if test "${with_tls+set}" = set; then
2387   withval="$with_tls"
2388
2389         ol_arg=invalid
2390         for ol_val in auto openssl yes no  ; do
2391                 if test "$withval" = "$ol_val" ; then
2392                         ol_arg="$ol_val"
2393                 fi
2394         done
2395         if test "$ol_arg" = "invalid" ; then
2396                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-tls" >&5
2397 echo "$as_me: error: bad value $withval for --with-tls" >&2;}
2398    { (exit 1); exit 1; }; }
2399         fi
2400         ol_with_tls="$ol_arg"
2401
2402 else
2403         ol_with_tls="auto"
2404 fi; # end --with-tls
2405
2406 # OpenLDAP --with-yielding_select
2407
2408 # Check whether --with-yielding_select or --without-yielding_select was given.
2409 if test "${with_yielding_select+set}" = set; then
2410   withval="$with_yielding_select"
2411
2412         ol_arg=invalid
2413         for ol_val in auto yes no manual  ; do
2414                 if test "$withval" = "$ol_val" ; then
2415                         ol_arg="$ol_val"
2416                 fi
2417         done
2418         if test "$ol_arg" = "invalid" ; then
2419                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-yielding_select" >&5
2420 echo "$as_me: error: bad value $withval for --with-yielding_select" >&2;}
2421    { (exit 1); exit 1; }; }
2422         fi
2423         ol_with_yielding_select="$ol_arg"
2424
2425 else
2426         ol_with_yielding_select="auto"
2427 fi; # end --with-yielding_select
2428
2429 # OpenLDAP --with-mp
2430
2431 # Check whether --with-mp or --without-mp was given.
2432 if test "${with_mp+set}" = set; then
2433   withval="$with_mp"
2434
2435         ol_arg=invalid
2436         for ol_val in auto longlong long bignum gmp yes no ; do
2437                 if test "$withval" = "$ol_val" ; then
2438                         ol_arg="$ol_val"
2439                 fi
2440         done
2441         if test "$ol_arg" = "invalid" ; then
2442                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-mp" >&5
2443 echo "$as_me: error: bad value $withval for --with-mp" >&2;}
2444    { (exit 1); exit 1; }; }
2445         fi
2446         ol_with_mp="$ol_arg"
2447
2448 else
2449         ol_with_mp="auto"
2450 fi; # end --with-mp
2451
2452
2453
2454 # Check whether --enable-xxslapdoptions or --disable-xxslapdoptions was given.
2455 if test "${enable_xxslapdoptions+set}" = set; then
2456   enableval="$enable_xxslapdoptions"
2457
2458 fi;
2459 # OpenLDAP --enable-slapd
2460
2461         # Check whether --enable-slapd or --disable-slapd was given.
2462 if test "${enable_slapd+set}" = set; then
2463   enableval="$enable_slapd"
2464
2465         ol_arg=invalid
2466         for ol_val in auto yes no ; do
2467                 if test "$enableval" = "$ol_val" ; then
2468                         ol_arg="$ol_val"
2469                 fi
2470         done
2471         if test "$ol_arg" = "invalid" ; then
2472                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slapd" >&5
2473 echo "$as_me: error: bad value $enableval for --enable-slapd" >&2;}
2474    { (exit 1); exit 1; }; }
2475         fi
2476         ol_enable_slapd="$ol_arg"
2477
2478 else
2479         ol_enable_slapd=yes
2480 fi;
2481 # end --enable-slapd
2482 # OpenLDAP --enable-dynacl
2483
2484         # Check whether --enable-dynacl or --disable-dynacl was given.
2485 if test "${enable_dynacl+set}" = set; then
2486   enableval="$enable_dynacl"
2487
2488         ol_arg=invalid
2489         for ol_val in auto yes no ; do
2490                 if test "$enableval" = "$ol_val" ; then
2491                         ol_arg="$ol_val"
2492                 fi
2493         done
2494         if test "$ol_arg" = "invalid" ; then
2495                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dynacl" >&5
2496 echo "$as_me: error: bad value $enableval for --enable-dynacl" >&2;}
2497    { (exit 1); exit 1; }; }
2498         fi
2499         ol_enable_dynacl="$ol_arg"
2500
2501 else
2502         ol_enable_dynacl=no
2503 fi;
2504 # end --enable-dynacl
2505 # OpenLDAP --enable-aci
2506
2507         # Check whether --enable-aci or --disable-aci was given.
2508 if test "${enable_aci+set}" = set; then
2509   enableval="$enable_aci"
2510
2511         ol_arg=invalid
2512         for ol_val in no yes mod ; do
2513                 if test "$enableval" = "$ol_val" ; then
2514                         ol_arg="$ol_val"
2515                 fi
2516         done
2517         if test "$ol_arg" = "invalid" ; then
2518                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-aci" >&5
2519 echo "$as_me: error: bad value $enableval for --enable-aci" >&2;}
2520    { (exit 1); exit 1; }; }
2521         fi
2522         ol_enable_aci="$ol_arg"
2523
2524 else
2525         ol_enable_aci=no
2526 fi;
2527 # end --enable-aci
2528 # OpenLDAP --enable-cleartext
2529
2530         # Check whether --enable-cleartext or --disable-cleartext was given.
2531 if test "${enable_cleartext+set}" = set; then
2532   enableval="$enable_cleartext"
2533
2534         ol_arg=invalid
2535         for ol_val in auto yes no ; do
2536                 if test "$enableval" = "$ol_val" ; then
2537                         ol_arg="$ol_val"
2538                 fi
2539         done
2540         if test "$ol_arg" = "invalid" ; then
2541                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-cleartext" >&5
2542 echo "$as_me: error: bad value $enableval for --enable-cleartext" >&2;}
2543    { (exit 1); exit 1; }; }
2544         fi
2545         ol_enable_cleartext="$ol_arg"
2546
2547 else
2548         ol_enable_cleartext=yes
2549 fi;
2550 # end --enable-cleartext
2551 # OpenLDAP --enable-crypt
2552
2553         # Check whether --enable-crypt or --disable-crypt was given.
2554 if test "${enable_crypt+set}" = set; then
2555   enableval="$enable_crypt"
2556
2557         ol_arg=invalid
2558         for ol_val in auto yes no ; do
2559                 if test "$enableval" = "$ol_val" ; then
2560                         ol_arg="$ol_val"
2561                 fi
2562         done
2563         if test "$ol_arg" = "invalid" ; then
2564                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-crypt" >&5
2565 echo "$as_me: error: bad value $enableval for --enable-crypt" >&2;}
2566    { (exit 1); exit 1; }; }
2567         fi
2568         ol_enable_crypt="$ol_arg"
2569
2570 else
2571         ol_enable_crypt=no
2572 fi;
2573 # end --enable-crypt
2574 # OpenLDAP --enable-lmpasswd
2575
2576         # Check whether --enable-lmpasswd or --disable-lmpasswd was given.
2577 if test "${enable_lmpasswd+set}" = set; then
2578   enableval="$enable_lmpasswd"
2579
2580         ol_arg=invalid
2581         for ol_val in auto yes no ; do
2582                 if test "$enableval" = "$ol_val" ; then
2583                         ol_arg="$ol_val"
2584                 fi
2585         done
2586         if test "$ol_arg" = "invalid" ; then
2587                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-lmpasswd" >&5
2588 echo "$as_me: error: bad value $enableval for --enable-lmpasswd" >&2;}
2589    { (exit 1); exit 1; }; }
2590         fi
2591         ol_enable_lmpasswd="$ol_arg"
2592
2593 else
2594         ol_enable_lmpasswd=no
2595 fi;
2596 # end --enable-lmpasswd
2597 # OpenLDAP --enable-spasswd
2598
2599         # Check whether --enable-spasswd or --disable-spasswd was given.
2600 if test "${enable_spasswd+set}" = set; then
2601   enableval="$enable_spasswd"
2602
2603         ol_arg=invalid
2604         for ol_val in auto yes no ; do
2605                 if test "$enableval" = "$ol_val" ; then
2606                         ol_arg="$ol_val"
2607                 fi
2608         done
2609         if test "$ol_arg" = "invalid" ; then
2610                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-spasswd" >&5
2611 echo "$as_me: error: bad value $enableval for --enable-spasswd" >&2;}
2612    { (exit 1); exit 1; }; }
2613         fi
2614         ol_enable_spasswd="$ol_arg"
2615
2616 else
2617         ol_enable_spasswd=no
2618 fi;
2619 # end --enable-spasswd
2620 # OpenLDAP --enable-modules
2621
2622         # Check whether --enable-modules or --disable-modules was given.
2623 if test "${enable_modules+set}" = set; then
2624   enableval="$enable_modules"
2625
2626         ol_arg=invalid
2627         for ol_val in auto yes no ; do
2628                 if test "$enableval" = "$ol_val" ; then
2629                         ol_arg="$ol_val"
2630                 fi
2631         done
2632         if test "$ol_arg" = "invalid" ; then
2633                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-modules" >&5
2634 echo "$as_me: error: bad value $enableval for --enable-modules" >&2;}
2635    { (exit 1); exit 1; }; }
2636         fi
2637         ol_enable_modules="$ol_arg"
2638
2639 else
2640         ol_enable_modules=no
2641 fi;
2642 # end --enable-modules
2643 # OpenLDAP --enable-rewrite
2644
2645         # Check whether --enable-rewrite or --disable-rewrite was given.
2646 if test "${enable_rewrite+set}" = set; then
2647   enableval="$enable_rewrite"
2648
2649         ol_arg=invalid
2650         for ol_val in auto yes no ; do
2651                 if test "$enableval" = "$ol_val" ; then
2652                         ol_arg="$ol_val"
2653                 fi
2654         done
2655         if test "$ol_arg" = "invalid" ; then
2656                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rewrite" >&5
2657 echo "$as_me: error: bad value $enableval for --enable-rewrite" >&2;}
2658    { (exit 1); exit 1; }; }
2659         fi
2660         ol_enable_rewrite="$ol_arg"
2661
2662 else
2663         ol_enable_rewrite=auto
2664 fi;
2665 # end --enable-rewrite
2666 # OpenLDAP --enable-rlookups
2667
2668         # Check whether --enable-rlookups or --disable-rlookups was given.
2669 if test "${enable_rlookups+set}" = set; then
2670   enableval="$enable_rlookups"
2671
2672         ol_arg=invalid
2673         for ol_val in auto yes no ; do
2674                 if test "$enableval" = "$ol_val" ; then
2675                         ol_arg="$ol_val"
2676                 fi
2677         done
2678         if test "$ol_arg" = "invalid" ; then
2679                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rlookups" >&5
2680 echo "$as_me: error: bad value $enableval for --enable-rlookups" >&2;}
2681    { (exit 1); exit 1; }; }
2682         fi
2683         ol_enable_rlookups="$ol_arg"
2684
2685 else
2686         ol_enable_rlookups=no
2687 fi;
2688 # end --enable-rlookups
2689 # OpenLDAP --enable-slapi
2690
2691         # Check whether --enable-slapi or --disable-slapi was given.
2692 if test "${enable_slapi+set}" = set; then
2693   enableval="$enable_slapi"
2694
2695         ol_arg=invalid
2696         for ol_val in auto yes no ; do
2697                 if test "$enableval" = "$ol_val" ; then
2698                         ol_arg="$ol_val"
2699                 fi
2700         done
2701         if test "$ol_arg" = "invalid" ; then
2702                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slapi" >&5
2703 echo "$as_me: error: bad value $enableval for --enable-slapi" >&2;}
2704    { (exit 1); exit 1; }; }
2705         fi
2706         ol_enable_slapi="$ol_arg"
2707
2708 else
2709         ol_enable_slapi=no
2710 fi;
2711 # end --enable-slapi
2712 # OpenLDAP --enable-slp
2713
2714         # Check whether --enable-slp or --disable-slp was given.
2715 if test "${enable_slp+set}" = set; then
2716   enableval="$enable_slp"
2717
2718         ol_arg=invalid
2719         for ol_val in auto yes no ; do
2720                 if test "$enableval" = "$ol_val" ; then
2721                         ol_arg="$ol_val"
2722                 fi
2723         done
2724         if test "$ol_arg" = "invalid" ; then
2725                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slp" >&5
2726 echo "$as_me: error: bad value $enableval for --enable-slp" >&2;}
2727    { (exit 1); exit 1; }; }
2728         fi
2729         ol_enable_slp="$ol_arg"
2730
2731 else
2732         ol_enable_slp=no
2733 fi;
2734 # end --enable-slp
2735 # OpenLDAP --enable-wrappers
2736
2737         # Check whether --enable-wrappers or --disable-wrappers was given.
2738 if test "${enable_wrappers+set}" = set; then
2739   enableval="$enable_wrappers"
2740
2741         ol_arg=invalid
2742         for ol_val in auto yes no ; do
2743                 if test "$enableval" = "$ol_val" ; then
2744                         ol_arg="$ol_val"
2745                 fi
2746         done
2747         if test "$ol_arg" = "invalid" ; then
2748                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-wrappers" >&5
2749 echo "$as_me: error: bad value $enableval for --enable-wrappers" >&2;}
2750    { (exit 1); exit 1; }; }
2751         fi
2752         ol_enable_wrappers="$ol_arg"
2753
2754 else
2755         ol_enable_wrappers=no
2756 fi;
2757 # end --enable-wrappers
2758
2759 Backends="bdb \
2760         dnssrv \
2761         hdb \
2762         ldap \
2763         meta \
2764         monitor \
2765         null \
2766         passwd \
2767         perl \
2768         relay \
2769         shell \
2770         sql"
2771
2772 # Check whether --enable-xxslapbackends or --disable-xxslapbackends was given.
2773 if test "${enable_xxslapbackends+set}" = set; then
2774   enableval="$enable_xxslapbackends"
2775
2776 fi;
2777
2778 # OpenLDAP --enable-backends
2779
2780         # Check whether --enable-backends or --disable-backends was given.
2781 if test "${enable_backends+set}" = set; then
2782   enableval="$enable_backends"
2783
2784         ol_arg=invalid
2785         for ol_val in no yes mod ; do
2786                 if test "$enableval" = "$ol_val" ; then
2787                         ol_arg="$ol_val"
2788                 fi
2789         done
2790         if test "$ol_arg" = "invalid" ; then
2791                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-backends" >&5
2792 echo "$as_me: error: bad value $enableval for --enable-backends" >&2;}
2793    { (exit 1); exit 1; }; }
2794         fi
2795         ol_enable_backends="$ol_arg"
2796
2797 fi;
2798 # end --enable-backends
2799 # OpenLDAP --enable-bdb
2800
2801         # Check whether --enable-bdb or --disable-bdb was given.
2802 if test "${enable_bdb+set}" = set; then
2803   enableval="$enable_bdb"
2804
2805         ol_arg=invalid
2806         for ol_val in no yes mod ; do
2807                 if test "$enableval" = "$ol_val" ; then
2808                         ol_arg="$ol_val"
2809                 fi
2810         done
2811         if test "$ol_arg" = "invalid" ; then
2812                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-bdb" >&5
2813 echo "$as_me: error: bad value $enableval for --enable-bdb" >&2;}
2814    { (exit 1); exit 1; }; }
2815         fi
2816         ol_enable_bdb="$ol_arg"
2817
2818 else
2819         ol_enable_bdb=${ol_enable_backends:-yes}
2820 fi;
2821 # end --enable-bdb
2822 # OpenLDAP --enable-dnssrv
2823
2824         # Check whether --enable-dnssrv or --disable-dnssrv was given.
2825 if test "${enable_dnssrv+set}" = set; then
2826   enableval="$enable_dnssrv"
2827
2828         ol_arg=invalid
2829         for ol_val in no yes mod ; do
2830                 if test "$enableval" = "$ol_val" ; then
2831                         ol_arg="$ol_val"
2832                 fi
2833         done
2834         if test "$ol_arg" = "invalid" ; then
2835                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dnssrv" >&5
2836 echo "$as_me: error: bad value $enableval for --enable-dnssrv" >&2;}
2837    { (exit 1); exit 1; }; }
2838         fi
2839         ol_enable_dnssrv="$ol_arg"
2840
2841 else
2842         ol_enable_dnssrv=${ol_enable_backends:-no}
2843 fi;
2844 # end --enable-dnssrv
2845 # OpenLDAP --enable-hdb
2846
2847         # Check whether --enable-hdb or --disable-hdb was given.
2848 if test "${enable_hdb+set}" = set; then
2849   enableval="$enable_hdb"
2850
2851         ol_arg=invalid
2852         for ol_val in no yes mod ; do
2853                 if test "$enableval" = "$ol_val" ; then
2854                         ol_arg="$ol_val"
2855                 fi
2856         done
2857         if test "$ol_arg" = "invalid" ; then
2858                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-hdb" >&5
2859 echo "$as_me: error: bad value $enableval for --enable-hdb" >&2;}
2860    { (exit 1); exit 1; }; }
2861         fi
2862         ol_enable_hdb="$ol_arg"
2863
2864 else
2865         ol_enable_hdb=${ol_enable_backends:-yes}
2866 fi;
2867 # end --enable-hdb
2868 # OpenLDAP --enable-ldap
2869
2870         # Check whether --enable-ldap or --disable-ldap was given.
2871 if test "${enable_ldap+set}" = set; then
2872   enableval="$enable_ldap"
2873
2874         ol_arg=invalid
2875         for ol_val in no yes mod ; do
2876                 if test "$enableval" = "$ol_val" ; then
2877                         ol_arg="$ol_val"
2878                 fi
2879         done
2880         if test "$ol_arg" = "invalid" ; then
2881                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ldap" >&5
2882 echo "$as_me: error: bad value $enableval for --enable-ldap" >&2;}
2883    { (exit 1); exit 1; }; }
2884         fi
2885         ol_enable_ldap="$ol_arg"
2886
2887 else
2888         ol_enable_ldap=${ol_enable_backends:-no}
2889 fi;
2890 # end --enable-ldap
2891 # OpenLDAP --enable-meta
2892
2893         # Check whether --enable-meta or --disable-meta was given.
2894 if test "${enable_meta+set}" = set; then
2895   enableval="$enable_meta"
2896
2897         ol_arg=invalid
2898         for ol_val in no yes mod ; do
2899                 if test "$enableval" = "$ol_val" ; then
2900                         ol_arg="$ol_val"
2901                 fi
2902         done
2903         if test "$ol_arg" = "invalid" ; then
2904                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-meta" >&5
2905 echo "$as_me: error: bad value $enableval for --enable-meta" >&2;}
2906    { (exit 1); exit 1; }; }
2907         fi
2908         ol_enable_meta="$ol_arg"
2909
2910 else
2911         ol_enable_meta=${ol_enable_backends:-no}
2912 fi;
2913 # end --enable-meta
2914 # OpenLDAP --enable-monitor
2915
2916         # Check whether --enable-monitor or --disable-monitor was given.
2917 if test "${enable_monitor+set}" = set; then
2918   enableval="$enable_monitor"
2919
2920         ol_arg=invalid
2921         for ol_val in no yes mod ; do
2922                 if test "$enableval" = "$ol_val" ; then
2923                         ol_arg="$ol_val"
2924                 fi
2925         done
2926         if test "$ol_arg" = "invalid" ; then
2927                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-monitor" >&5
2928 echo "$as_me: error: bad value $enableval for --enable-monitor" >&2;}
2929    { (exit 1); exit 1; }; }
2930         fi
2931         ol_enable_monitor="$ol_arg"
2932
2933 else
2934         ol_enable_monitor=${ol_enable_backends:-yes}
2935 fi;
2936 # end --enable-monitor
2937 # OpenLDAP --enable-null
2938
2939         # Check whether --enable-null or --disable-null was given.
2940 if test "${enable_null+set}" = set; then
2941   enableval="$enable_null"
2942
2943         ol_arg=invalid
2944         for ol_val in no yes mod ; do
2945                 if test "$enableval" = "$ol_val" ; then
2946                         ol_arg="$ol_val"
2947                 fi
2948         done
2949         if test "$ol_arg" = "invalid" ; then
2950                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-null" >&5
2951 echo "$as_me: error: bad value $enableval for --enable-null" >&2;}
2952    { (exit 1); exit 1; }; }
2953         fi
2954         ol_enable_null="$ol_arg"
2955
2956 else
2957         ol_enable_null=${ol_enable_backends:-no}
2958 fi;
2959 # end --enable-null
2960 # OpenLDAP --enable-passwd
2961
2962         # Check whether --enable-passwd or --disable-passwd was given.
2963 if test "${enable_passwd+set}" = set; then
2964   enableval="$enable_passwd"
2965
2966         ol_arg=invalid
2967         for ol_val in no yes mod ; do
2968                 if test "$enableval" = "$ol_val" ; then
2969                         ol_arg="$ol_val"
2970                 fi
2971         done
2972         if test "$ol_arg" = "invalid" ; then
2973                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-passwd" >&5
2974 echo "$as_me: error: bad value $enableval for --enable-passwd" >&2;}
2975    { (exit 1); exit 1; }; }
2976         fi
2977         ol_enable_passwd="$ol_arg"
2978
2979 else
2980         ol_enable_passwd=${ol_enable_backends:-no}
2981 fi;
2982 # end --enable-passwd
2983 # OpenLDAP --enable-perl
2984
2985         # Check whether --enable-perl or --disable-perl was given.
2986 if test "${enable_perl+set}" = set; then
2987   enableval="$enable_perl"
2988
2989         ol_arg=invalid
2990         for ol_val in no yes mod ; do
2991                 if test "$enableval" = "$ol_val" ; then
2992                         ol_arg="$ol_val"
2993                 fi
2994         done
2995         if test "$ol_arg" = "invalid" ; then
2996                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-perl" >&5
2997 echo "$as_me: error: bad value $enableval for --enable-perl" >&2;}
2998    { (exit 1); exit 1; }; }
2999         fi
3000         ol_enable_perl="$ol_arg"
3001
3002 else
3003         ol_enable_perl=${ol_enable_backends:-no}
3004 fi;
3005 # end --enable-perl
3006 # OpenLDAP --enable-relay
3007
3008         # Check whether --enable-relay or --disable-relay was given.
3009 if test "${enable_relay+set}" = set; then
3010   enableval="$enable_relay"
3011
3012         ol_arg=invalid
3013         for ol_val in no yes mod ; do
3014                 if test "$enableval" = "$ol_val" ; then
3015                         ol_arg="$ol_val"
3016                 fi
3017         done
3018         if test "$ol_arg" = "invalid" ; then
3019                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-relay" >&5
3020 echo "$as_me: error: bad value $enableval for --enable-relay" >&2;}
3021    { (exit 1); exit 1; }; }
3022         fi
3023         ol_enable_relay="$ol_arg"
3024
3025 else
3026         ol_enable_relay=${ol_enable_backends:-yes}
3027 fi;
3028 # end --enable-relay
3029 # OpenLDAP --enable-shell
3030
3031         # Check whether --enable-shell or --disable-shell was given.
3032 if test "${enable_shell+set}" = set; then
3033   enableval="$enable_shell"
3034
3035         ol_arg=invalid
3036         for ol_val in no yes mod ; do
3037                 if test "$enableval" = "$ol_val" ; then
3038                         ol_arg="$ol_val"
3039                 fi
3040         done
3041         if test "$ol_arg" = "invalid" ; then
3042                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-shell" >&5
3043 echo "$as_me: error: bad value $enableval for --enable-shell" >&2;}
3044    { (exit 1); exit 1; }; }
3045         fi
3046         ol_enable_shell="$ol_arg"
3047
3048 else
3049         ol_enable_shell=${ol_enable_backends:-no}
3050 fi;
3051 # end --enable-shell
3052 # OpenLDAP --enable-sql
3053
3054         # Check whether --enable-sql or --disable-sql was given.
3055 if test "${enable_sql+set}" = set; then
3056   enableval="$enable_sql"
3057
3058         ol_arg=invalid
3059         for ol_val in no yes mod ; do
3060                 if test "$enableval" = "$ol_val" ; then
3061                         ol_arg="$ol_val"
3062                 fi
3063         done
3064         if test "$ol_arg" = "invalid" ; then
3065                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-sql" >&5
3066 echo "$as_me: error: bad value $enableval for --enable-sql" >&2;}
3067    { (exit 1); exit 1; }; }
3068         fi
3069         ol_enable_sql="$ol_arg"
3070
3071 else
3072         ol_enable_sql=${ol_enable_backends:-no}
3073 fi;
3074 # end --enable-sql
3075
3076 Overlays="accesslog \
3077         auditlog \
3078         constraint \
3079         dds \
3080         denyop \
3081         dyngroup \
3082         dynlist \
3083         lastmod \
3084         ppolicy \
3085         proxycache \
3086         refint \
3087         retcode \
3088         rwm \
3089         seqmod \
3090         syncprov \
3091         translucent \
3092         unique \
3093         valsort"
3094
3095 # Check whether --enable-xxslapoverlays or --disable-xxslapoverlays was given.
3096 if test "${enable_xxslapoverlays+set}" = set; then
3097   enableval="$enable_xxslapoverlays"
3098
3099 fi;
3100
3101 # OpenLDAP --enable-overlays
3102
3103         # Check whether --enable-overlays or --disable-overlays was given.
3104 if test "${enable_overlays+set}" = set; then
3105   enableval="$enable_overlays"
3106
3107         ol_arg=invalid
3108         for ol_val in no yes mod ; do
3109                 if test "$enableval" = "$ol_val" ; then
3110                         ol_arg="$ol_val"
3111                 fi
3112         done
3113         if test "$ol_arg" = "invalid" ; then
3114                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-overlays" >&5
3115 echo "$as_me: error: bad value $enableval for --enable-overlays" >&2;}
3116    { (exit 1); exit 1; }; }
3117         fi
3118         ol_enable_overlays="$ol_arg"
3119
3120 fi;
3121 # end --enable-overlays
3122 # OpenLDAP --enable-accesslog
3123
3124         # Check whether --enable-accesslog or --disable-accesslog was given.
3125 if test "${enable_accesslog+set}" = set; then
3126   enableval="$enable_accesslog"
3127
3128         ol_arg=invalid
3129         for ol_val in no yes mod ; do
3130                 if test "$enableval" = "$ol_val" ; then
3131                         ol_arg="$ol_val"
3132                 fi
3133         done
3134         if test "$ol_arg" = "invalid" ; then
3135                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-accesslog" >&5
3136 echo "$as_me: error: bad value $enableval for --enable-accesslog" >&2;}
3137    { (exit 1); exit 1; }; }
3138         fi
3139         ol_enable_accesslog="$ol_arg"
3140
3141 else
3142         ol_enable_accesslog=${ol_enable_overlays:-no}
3143 fi;
3144 # end --enable-accesslog
3145
3146 # OpenLDAP --enable-auditlog
3147
3148         # Check whether --enable-auditlog or --disable-auditlog was given.
3149 if test "${enable_auditlog+set}" = set; then
3150   enableval="$enable_auditlog"
3151
3152         ol_arg=invalid
3153         for ol_val in no yes mod ; do
3154                 if test "$enableval" = "$ol_val" ; then
3155                         ol_arg="$ol_val"
3156                 fi
3157         done
3158         if test "$ol_arg" = "invalid" ; then
3159                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-auditlog" >&5
3160 echo "$as_me: error: bad value $enableval for --enable-auditlog" >&2;}
3161    { (exit 1); exit 1; }; }
3162         fi
3163         ol_enable_auditlog="$ol_arg"
3164
3165 else
3166         ol_enable_auditlog=${ol_enable_overlays:-no}
3167 fi;
3168 # end --enable-auditlog
3169
3170 # OpenLDAP --enable-constraint
3171
3172         # Check whether --enable-constraint or --disable-constraint was given.
3173 if test "${enable_constraint+set}" = set; then
3174   enableval="$enable_constraint"
3175
3176         ol_arg=invalid
3177         for ol_val in no yes mod ; do
3178                 if test "$enableval" = "$ol_val" ; then
3179                         ol_arg="$ol_val"
3180                 fi
3181         done
3182         if test "$ol_arg" = "invalid" ; then
3183                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-constraint" >&5
3184 echo "$as_me: error: bad value $enableval for --enable-constraint" >&2;}
3185    { (exit 1); exit 1; }; }
3186         fi
3187         ol_enable_constraint="$ol_arg"
3188
3189 else
3190         ol_enable_constraint=${ol_enable_overlays:-no}
3191 fi;
3192 # end --enable-constraint
3193
3194 # OpenLDAP --enable-dds
3195
3196         # Check whether --enable-dds or --disable-dds was given.
3197 if test "${enable_dds+set}" = set; then
3198   enableval="$enable_dds"
3199
3200         ol_arg=invalid
3201         for ol_val in no yes mod ; do
3202                 if test "$enableval" = "$ol_val" ; then
3203                         ol_arg="$ol_val"
3204                 fi
3205         done
3206         if test "$ol_arg" = "invalid" ; then
3207                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dds" >&5
3208 echo "$as_me: error: bad value $enableval for --enable-dds" >&2;}
3209    { (exit 1); exit 1; }; }
3210         fi
3211         ol_enable_dds="$ol_arg"
3212
3213 else
3214         ol_enable_dds=${ol_enable_overlays:-no}
3215 fi;
3216 # end --enable-dds
3217
3218 # OpenLDAP --enable-denyop
3219
3220         # Check whether --enable-denyop or --disable-denyop was given.
3221 if test "${enable_denyop+set}" = set; then
3222   enableval="$enable_denyop"
3223
3224         ol_arg=invalid
3225         for ol_val in no yes mod ; do
3226                 if test "$enableval" = "$ol_val" ; then
3227                         ol_arg="$ol_val"
3228                 fi
3229         done
3230         if test "$ol_arg" = "invalid" ; then
3231                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-denyop" >&5
3232 echo "$as_me: error: bad value $enableval for --enable-denyop" >&2;}
3233    { (exit 1); exit 1; }; }
3234         fi
3235         ol_enable_denyop="$ol_arg"
3236
3237 else
3238         ol_enable_denyop=${ol_enable_overlays:-no}
3239 fi;
3240 # end --enable-denyop
3241
3242 # OpenLDAP --enable-dyngroup
3243
3244         # Check whether --enable-dyngroup or --disable-dyngroup was given.
3245 if test "${enable_dyngroup+set}" = set; then
3246   enableval="$enable_dyngroup"
3247
3248         ol_arg=invalid
3249         for ol_val in no yes mod ; do
3250                 if test "$enableval" = "$ol_val" ; then
3251                         ol_arg="$ol_val"
3252                 fi
3253         done
3254         if test "$ol_arg" = "invalid" ; then
3255                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dyngroup" >&5
3256 echo "$as_me: error: bad value $enableval for --enable-dyngroup" >&2;}
3257    { (exit 1); exit 1; }; }
3258         fi
3259         ol_enable_dyngroup="$ol_arg"
3260
3261 else
3262         ol_enable_dyngroup=${ol_enable_overlays:-no}
3263 fi;
3264 # end --enable-dyngroup
3265
3266 # OpenLDAP --enable-dynlist
3267
3268         # Check whether --enable-dynlist or --disable-dynlist was given.
3269 if test "${enable_dynlist+set}" = set; then
3270   enableval="$enable_dynlist"
3271
3272         ol_arg=invalid
3273         for ol_val in no yes mod ; do
3274                 if test "$enableval" = "$ol_val" ; then
3275                         ol_arg="$ol_val"
3276                 fi
3277         done
3278         if test "$ol_arg" = "invalid" ; then
3279                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dynlist" >&5
3280 echo "$as_me: error: bad value $enableval for --enable-dynlist" >&2;}
3281    { (exit 1); exit 1; }; }
3282         fi
3283         ol_enable_dynlist="$ol_arg"
3284
3285 else
3286         ol_enable_dynlist=${ol_enable_overlays:-no}
3287 fi;
3288 # end --enable-dynlist
3289
3290 # OpenLDAP --enable-lastmod
3291
3292         # Check whether --enable-lastmod or --disable-lastmod was given.
3293 if test "${enable_lastmod+set}" = set; then
3294   enableval="$enable_lastmod"
3295
3296         ol_arg=invalid
3297         for ol_val in no yes mod ; do
3298                 if test "$enableval" = "$ol_val" ; then
3299                         ol_arg="$ol_val"
3300                 fi
3301         done
3302         if test "$ol_arg" = "invalid" ; then
3303                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-lastmod" >&5
3304 echo "$as_me: error: bad value $enableval for --enable-lastmod" >&2;}
3305    { (exit 1); exit 1; }; }
3306         fi
3307         ol_enable_lastmod="$ol_arg"
3308
3309 else
3310         ol_enable_lastmod=${ol_enable_overlays:-no}
3311 fi;
3312 # end --enable-lastmod
3313
3314 # OpenLDAP --enable-ppolicy
3315
3316         # Check whether --enable-ppolicy or --disable-ppolicy was given.
3317 if test "${enable_ppolicy+set}" = set; then
3318   enableval="$enable_ppolicy"
3319
3320         ol_arg=invalid
3321         for ol_val in no yes mod ; do
3322                 if test "$enableval" = "$ol_val" ; then
3323                         ol_arg="$ol_val"
3324                 fi
3325         done
3326         if test "$ol_arg" = "invalid" ; then
3327                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ppolicy" >&5
3328 echo "$as_me: error: bad value $enableval for --enable-ppolicy" >&2;}
3329    { (exit 1); exit 1; }; }
3330         fi
3331         ol_enable_ppolicy="$ol_arg"
3332
3333 else
3334         ol_enable_ppolicy=${ol_enable_overlays:-no}
3335 fi;
3336 # end --enable-ppolicy
3337
3338 # OpenLDAP --enable-proxycache
3339
3340         # Check whether --enable-proxycache or --disable-proxycache was given.
3341 if test "${enable_proxycache+set}" = set; then
3342   enableval="$enable_proxycache"
3343
3344         ol_arg=invalid
3345         for ol_val in no yes mod ; do
3346                 if test "$enableval" = "$ol_val" ; then
3347                         ol_arg="$ol_val"
3348                 fi
3349         done
3350         if test "$ol_arg" = "invalid" ; then
3351                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-proxycache" >&5
3352 echo "$as_me: error: bad value $enableval for --enable-proxycache" >&2;}
3353    { (exit 1); exit 1; }; }
3354         fi
3355         ol_enable_proxycache="$ol_arg"
3356
3357 else
3358         ol_enable_proxycache=${ol_enable_overlays:-no}
3359 fi;
3360 # end --enable-proxycache
3361
3362 # OpenLDAP --enable-refint
3363
3364         # Check whether --enable-refint or --disable-refint was given.
3365 if test "${enable_refint+set}" = set; then
3366   enableval="$enable_refint"
3367
3368         ol_arg=invalid
3369         for ol_val in no yes mod ; do
3370                 if test "$enableval" = "$ol_val" ; then
3371                         ol_arg="$ol_val"
3372                 fi
3373         done
3374         if test "$ol_arg" = "invalid" ; then
3375                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-refint" >&5
3376 echo "$as_me: error: bad value $enableval for --enable-refint" >&2;}
3377    { (exit 1); exit 1; }; }
3378         fi
3379         ol_enable_refint="$ol_arg"
3380
3381 else
3382         ol_enable_refint=${ol_enable_overlays:-no}
3383 fi;
3384 # end --enable-refint
3385
3386 # OpenLDAP --enable-retcode
3387
3388         # Check whether --enable-retcode or --disable-retcode was given.
3389 if test "${enable_retcode+set}" = set; then
3390   enableval="$enable_retcode"
3391
3392         ol_arg=invalid
3393         for ol_val in no yes mod ; do
3394                 if test "$enableval" = "$ol_val" ; then
3395                         ol_arg="$ol_val"
3396                 fi
3397         done
3398         if test "$ol_arg" = "invalid" ; then
3399                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-retcode" >&5
3400 echo "$as_me: error: bad value $enableval for --enable-retcode" >&2;}
3401    { (exit 1); exit 1; }; }
3402         fi
3403         ol_enable_retcode="$ol_arg"
3404
3405 else
3406         ol_enable_retcode=${ol_enable_overlays:-no}
3407 fi;
3408 # end --enable-retcode
3409
3410 # OpenLDAP --enable-rwm
3411
3412         # Check whether --enable-rwm or --disable-rwm was given.
3413 if test "${enable_rwm+set}" = set; then
3414   enableval="$enable_rwm"
3415
3416         ol_arg=invalid
3417         for ol_val in no yes mod ; do
3418                 if test "$enableval" = "$ol_val" ; then
3419                         ol_arg="$ol_val"
3420                 fi
3421         done
3422         if test "$ol_arg" = "invalid" ; then
3423                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rwm" >&5
3424 echo "$as_me: error: bad value $enableval for --enable-rwm" >&2;}
3425    { (exit 1); exit 1; }; }
3426         fi
3427         ol_enable_rwm="$ol_arg"
3428
3429 else
3430         ol_enable_rwm=${ol_enable_overlays:-no}
3431 fi;
3432 # end --enable-rwm
3433
3434 # OpenLDAP --enable-seqmod
3435
3436         # Check whether --enable-seqmod or --disable-seqmod was given.
3437 if test "${enable_seqmod+set}" = set; then
3438   enableval="$enable_seqmod"
3439
3440         ol_arg=invalid
3441         for ol_val in no yes mod ; do
3442                 if test "$enableval" = "$ol_val" ; then
3443                         ol_arg="$ol_val"
3444                 fi
3445         done
3446         if test "$ol_arg" = "invalid" ; then
3447                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-seqmod" >&5
3448 echo "$as_me: error: bad value $enableval for --enable-seqmod" >&2;}
3449    { (exit 1); exit 1; }; }
3450         fi
3451         ol_enable_seqmod="$ol_arg"
3452
3453 else
3454         ol_enable_seqmod=${ol_enable_overlays:-yes}
3455 fi;
3456 # end --enable-seqmod
3457
3458 # OpenLDAP --enable-syncprov
3459
3460         # Check whether --enable-syncprov or --disable-syncprov was given.
3461 if test "${enable_syncprov+set}" = set; then
3462   enableval="$enable_syncprov"
3463
3464         ol_arg=invalid
3465         for ol_val in no yes mod ; do
3466                 if test "$enableval" = "$ol_val" ; then
3467                         ol_arg="$ol_val"
3468                 fi
3469         done
3470         if test "$ol_arg" = "invalid" ; then
3471                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-syncprov" >&5
3472 echo "$as_me: error: bad value $enableval for --enable-syncprov" >&2;}
3473    { (exit 1); exit 1; }; }
3474         fi
3475         ol_enable_syncprov="$ol_arg"
3476
3477 else
3478         ol_enable_syncprov=${ol_enable_overlays:-yes}
3479 fi;
3480 # end --enable-syncprov
3481
3482 # OpenLDAP --enable-translucent
3483
3484         # Check whether --enable-translucent or --disable-translucent was given.
3485 if test "${enable_translucent+set}" = set; then
3486   enableval="$enable_translucent"
3487
3488         ol_arg=invalid
3489         for ol_val in no yes mod ; do
3490                 if test "$enableval" = "$ol_val" ; then
3491                         ol_arg="$ol_val"
3492                 fi
3493         done
3494         if test "$ol_arg" = "invalid" ; then
3495                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-translucent" >&5
3496 echo "$as_me: error: bad value $enableval for --enable-translucent" >&2;}
3497    { (exit 1); exit 1; }; }
3498         fi
3499         ol_enable_translucent="$ol_arg"
3500
3501 else
3502         ol_enable_translucent=${ol_enable_overlays:-no}
3503 fi;
3504 # end --enable-translucent
3505
3506 # OpenLDAP --enable-unique
3507
3508         # Check whether --enable-unique or --disable-unique was given.
3509 if test "${enable_unique+set}" = set; then
3510   enableval="$enable_unique"
3511
3512         ol_arg=invalid
3513         for ol_val in no yes mod ; do
3514                 if test "$enableval" = "$ol_val" ; then
3515                         ol_arg="$ol_val"
3516                 fi
3517         done
3518         if test "$ol_arg" = "invalid" ; then
3519                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-unique" >&5
3520 echo "$as_me: error: bad value $enableval for --enable-unique" >&2;}
3521    { (exit 1); exit 1; }; }
3522         fi
3523         ol_enable_unique="$ol_arg"
3524
3525 else
3526         ol_enable_unique=${ol_enable_overlays:-no}
3527 fi;
3528 # end --enable-unique
3529
3530 # OpenLDAP --enable-valsort
3531
3532         # Check whether --enable-valsort or --disable-valsort was given.
3533 if test "${enable_valsort+set}" = set; then
3534   enableval="$enable_valsort"
3535
3536         ol_arg=invalid
3537         for ol_val in no yes mod ; do
3538                 if test "$enableval" = "$ol_val" ; then
3539                         ol_arg="$ol_val"
3540                 fi
3541         done
3542         if test "$ol_arg" = "invalid" ; then
3543                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-valsort" >&5
3544 echo "$as_me: error: bad value $enableval for --enable-valsort" >&2;}
3545    { (exit 1); exit 1; }; }
3546         fi
3547         ol_enable_valsort="$ol_arg"
3548
3549 else
3550         ol_enable_valsort=${ol_enable_overlays:-no}
3551 fi;
3552 # end --enable-valsort
3553
3554
3555 # Check whether --enable-xxslurpdoptions or --disable-xxslurpdoptions was given.
3556 if test "${enable_xxslurpdoptions+set}" = set; then
3557   enableval="$enable_xxslurpdoptions"
3558
3559 fi;
3560 # OpenLDAP --enable-slurpd
3561
3562         # Check whether --enable-slurpd or --disable-slurpd was given.
3563 if test "${enable_slurpd+set}" = set; then
3564   enableval="$enable_slurpd"
3565
3566         ol_arg=invalid
3567         for ol_val in auto yes no ; do
3568                 if test "$enableval" = "$ol_val" ; then
3569                         ol_arg="$ol_val"
3570                 fi
3571         done
3572         if test "$ol_arg" = "invalid" ; then
3573                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slurpd" >&5
3574 echo "$as_me: error: bad value $enableval for --enable-slurpd" >&2;}
3575    { (exit 1); exit 1; }; }
3576         fi
3577         ol_enable_slurpd="$ol_arg"
3578
3579 else
3580         ol_enable_slurpd=auto
3581 fi;
3582 # end --enable-slurpd
3583
3584 # Check whether --enable-xxliboptions or --disable-xxliboptions was given.
3585 if test "${enable_xxliboptions+set}" = set; then
3586   enableval="$enable_xxliboptions"
3587
3588 fi;
3589 # Check whether --enable-static or --disable-static was given.
3590 if test "${enable_static+set}" = set; then
3591   enableval="$enable_static"
3592   p=${PACKAGE-default}
3593     case $enableval in
3594     yes) enable_static=yes ;;
3595     no) enable_static=no ;;
3596     *)
3597      enable_static=no
3598       # Look at the argument we got.  We use all the common list separators.
3599       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
3600       for pkg in $enableval; do
3601         IFS="$lt_save_ifs"
3602         if test "X$pkg" = "X$p"; then
3603           enable_static=yes
3604         fi
3605       done
3606       IFS="$lt_save_ifs"
3607       ;;
3608     esac
3609 else
3610   enable_static=yes
3611 fi;
3612
3613 # Check whether --enable-shared or --disable-shared was given.
3614 if test "${enable_shared+set}" = set; then
3615   enableval="$enable_shared"
3616   p=${PACKAGE-default}
3617     case $enableval in
3618     yes) enable_shared=yes ;;
3619     no) enable_shared=no ;;
3620     *)
3621       enable_shared=no
3622       # Look at the argument we got.  We use all the common list separators.
3623       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
3624       for pkg in $enableval; do
3625         IFS="$lt_save_ifs"
3626         if test "X$pkg" = "X$p"; then
3627           enable_shared=yes
3628         fi
3629       done
3630       IFS="$lt_save_ifs"
3631       ;;
3632     esac
3633 else
3634   enable_shared=yes
3635 fi;
3636
3637
3638
3639 # validate options
3640 if test $ol_enable_slapd = no ; then
3641                 if test $ol_enable_slapi = yes ; then
3642                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-slapi argument" >&5
3643 echo "$as_me: WARNING: slapd disabled, ignoring --enable-slapi argument" >&2;}
3644         fi
3645         case "$ol_enable_backends" in yes | mod)
3646                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-backends argument" >&5
3647 echo "$as_me: WARNING: slapd disabled, ignoring --enable-backends argument" >&2;}
3648         esac
3649         for i in $Backends; do
3650                 eval "ol_tmp=\$ol_enable_$i"
3651                 if test $ol_tmp != no ; then
3652                         { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-$i argument" >&5
3653 echo "$as_me: WARNING: slapd disabled, ignoring --enable-$i argument" >&2;}
3654                         eval "ol_enable_$i=no"
3655                 fi
3656         done
3657         if test $ol_enable_modules = yes ; then
3658                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-modules argument" >&5
3659 echo "$as_me: WARNING: slapd disabled, ignoring --enable-modules argument" >&2;}
3660         fi
3661         if test $ol_enable_wrappers = yes ; then
3662                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-wrappers argument" >&5
3663 echo "$as_me: WARNING: slapd disabled, ignoring --enable-wrappers argument" >&2;}
3664         fi
3665         if test $ol_enable_rlookups = yes ; then
3666                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-rlookups argument" >&5
3667 echo "$as_me: WARNING: slapd disabled, ignoring --enable-rlookups argument" >&2;}
3668         fi
3669         if test $ol_enable_dynacl = yes ; then
3670                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-dynacl argument" >&5
3671 echo "$as_me: WARNING: slapd disabled, ignoring --enable-dynacl argument" >&2;}
3672         fi
3673         if test $ol_enable_aci != no ; then
3674                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-aci argument" >&5
3675 echo "$as_me: WARNING: slapd disabled, ignoring --enable-aci argument" >&2;}
3676         fi
3677         if test $ol_enable_slurpd = yes ; then
3678                 { { echo "$as_me:$LINENO: error: slurpd requires slapd" >&5
3679 echo "$as_me: error: slurpd requires slapd" >&2;}
3680    { (exit 1); exit 1; }; }
3681         fi
3682         if test $ol_enable_rewrite = yes ; then
3683                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-rewrite argument" >&5
3684 echo "$as_me: WARNING: slapd disabled, ignoring --enable-rewrite argument" >&2;}
3685         fi
3686                 case "$ol_enable_overlays" in yes | mod)
3687                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-overlays argument" >&5
3688 echo "$as_me: WARNING: slapd disabled, ignoring --enable-overlays argument" >&2;}
3689         esac
3690         for i in $Overlays; do
3691                 eval "ol_tmp=\$ol_enable_$i"
3692                 if test $ol_tmp != no ; then
3693                         { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-$i argument" >&5
3694 echo "$as_me: WARNING: slapd disabled, ignoring --enable-$i argument" >&2;}
3695                         eval "ol_enable_$i=no"
3696                 fi
3697         done
3698
3699         # force settings to no
3700         ol_enable_slapi=no
3701
3702         ol_enable_backends=
3703         ol_enable_overlays=
3704         ol_enable_modules=no
3705         ol_enable_rlookups=no
3706         ol_enable_dynacl=no
3707         ol_enable_aci=no
3708         ol_enable_wrappers=no
3709
3710         ol_enable_slurpd=no
3711
3712         ol_enable_rewrite=no
3713
3714 elif test $ol_enable_modules != yes &&
3715         test $ol_enable_bdb = no &&
3716         test $ol_enable_dnssrv = no &&
3717         test $ol_enable_hdb = no &&
3718         test $ol_enable_ldap = no &&
3719         test $ol_enable_meta = no &&
3720         test $ol_enable_monitor = no &&
3721         test $ol_enable_null = no &&
3722         test $ol_enable_passwd = no &&
3723         test $ol_enable_perl = no &&
3724         test $ol_enable_relay = no &&
3725         test $ol_enable_shell = no &&
3726         test $ol_enable_sql = no ; then
3727
3728         if test $ol_enable_slapd = yes ; then
3729                 { { echo "$as_me:$LINENO: error: slapd requires a backend" >&5
3730 echo "$as_me: error: slapd requires a backend" >&2;}
3731    { (exit 1); exit 1; }; }
3732         else
3733                 { echo "$as_me:$LINENO: WARNING: skipping slapd, no backend specified" >&5
3734 echo "$as_me: WARNING: skipping slapd, no backend specified" >&2;}
3735                 ol_enable_slapd=no
3736         fi
3737 fi
3738
3739 if test $ol_enable_meta/$ol_enable_ldap = yes/no ; then
3740         { { echo "$as_me:$LINENO: error: --enable-meta requires --enable-ldap" >&5
3741 echo "$as_me: error: --enable-meta requires --enable-ldap" >&2;}
3742    { (exit 1); exit 1; }; }
3743 fi
3744
3745 if test $ol_enable_slurpd = yes ; then
3746                 if test $ol_with_threads = no ; then
3747                 { { echo "$as_me:$LINENO: error: slurpd requires threads" >&5
3748 echo "$as_me: error: slurpd requires threads" >&2;}
3749    { (exit 1); exit 1; }; }
3750         fi
3751 fi
3752
3753 if test $ol_enable_lmpasswd = yes ; then
3754         if test $ol_with_tls = no ; then
3755                 { { echo "$as_me:$LINENO: error: LAN Manager passwords require OpenSSL" >&5
3756 echo "$as_me: error: LAN Manager passwords require OpenSSL" >&2;}
3757    { (exit 1); exit 1; }; }
3758         fi
3759 fi
3760
3761 if test $ol_enable_kbind = yes ; then
3762         if test $ol_with_kerberos = no ; then
3763                 { { echo "$as_me:$LINENO: error: options require --with-kerberos" >&5
3764 echo "$as_me: error: options require --with-kerberos" >&2;}
3765    { (exit 1); exit 1; }; }
3766         elif test $ol_with_kerberos = auto ; then
3767                 ol_with_kerberos=yes
3768         fi
3769
3770 elif test $ol_enable_kbind = no ; then
3771         if test $ol_with_kerberos = auto ; then
3772                 ol_with_kerberos=no
3773         elif test $ol_with_kerberos != no ; then
3774                 { echo "$as_me:$LINENO: WARNING: Kerberos detection enabled unnecessarily" >&5
3775 echo "$as_me: WARNING: Kerberos detection enabled unnecessarily" >&2;};
3776                 ol_with_kerberos=no
3777         fi
3778 fi
3779
3780 if test $ol_enable_spasswd = yes ; then
3781         if test $ol_with_cyrus_sasl = no ; then
3782                 { { echo "$as_me:$LINENO: error: options require --with-cyrus-sasl" >&5
3783 echo "$as_me: error: options require --with-cyrus-sasl" >&2;}
3784    { (exit 1); exit 1; }; }
3785         fi
3786         ol_with_cyrus_sasl=yes
3787 fi
3788
3789 echo "$as_me:$LINENO: result: done" >&5
3790 echo "${ECHO_T}done" >&6
3791
3792 LDAP_LIBS=
3793 BDB_LIBS=
3794 LTHREAD_LIBS=
3795 LUTIL_LIBS=
3796
3797 SLAPD_LIBS=
3798 SLURPD_LIBS=
3799
3800 BUILD_SLAPD=no
3801 BUILD_SLURPD=no
3802
3803 BUILD_THREAD=no
3804
3805 BUILD_SLAPI=no
3806 SLAPD_SLAPI_DEPEND=
3807
3808 BUILD_BDB=no
3809 BUILD_DNSSRV=no
3810 BUILD_HDB=no
3811 BUILD_LDAP=no
3812 BUILD_META=no
3813 BUILD_MONITOR=no
3814 BUILD_NULL=no
3815 BUILD_PASSWD=no
3816 BUILD_PERL=no
3817 BUILD_RELAY=no
3818 BUILD_SHELL=no
3819 BUILD_SQL=no
3820
3821 BUILD_ACCESSLOG=no
3822 BUILD_AUDITLOG=no
3823 BUILD_CONSTRAINT=no
3824 BUILD_DDS=no
3825 BUILD_DENYOP=no
3826 BUILD_DYNGROUP=no
3827 BUILD_DYNLIST=no
3828 BUILD_LASTMOD=no
3829 BUILD_PPOLICY=no
3830 BUILD_PROXYCACHE=no
3831 BUILD_REFINT=no
3832 BUILD_RETCODE=no
3833 BUILD_RWM=no
3834 BUILD_SEQMOD=no
3835 BUILD_SYNCPROV=no
3836 BUILD_TRANSLUCENT=no
3837 BUILD_UNIQUE=no
3838 BUILD_VALSORT=no
3839
3840 SLAPD_STATIC_OVERLAYS=
3841 SLAPD_DYNAMIC_OVERLAYS=
3842
3843 SLAPD_MODULES_LDFLAGS=
3844 SLAPD_MODULES_CPPFLAGS=
3845
3846 SLAPD_STATIC_BACKENDS=back-ldif
3847 SLAPD_DYNAMIC_BACKENDS=
3848
3849 SLAPD_PERL_LDFLAGS=
3850 MOD_PERL_LDFLAGS=
3851 PERL_CPPFLAGS=
3852
3853 SLAPD_SQL_LDFLAGS=
3854 SLAPD_SQL_LIBS=
3855 SLAPD_SQL_INCLUDES=
3856
3857 KRB4_LIBS=
3858 KRB5_LIBS=
3859 SASL_LIBS=
3860 TLS_LIBS=
3861 MODULES_LIBS=
3862 SLAPI_LIBS=
3863 LIBSLAPI=
3864 LIBSLAPITOOLS=
3865 AUTH_LIBS=
3866 ICU_LIBS=
3867
3868 SLAPD_SLP_LIBS=
3869 SLAPD_GMP_LIBS=
3870
3871
3872
3873 cat >>confdefs.h <<\_ACEOF
3874 #define HAVE_MKVERSION 1
3875 _ACEOF
3876
3877
3878
3879
3880 ol_aix_threads=no
3881 case "$target" in
3882 *-*-aix*)       if test -z "$CC" ; then
3883                 case "$ol_with_threads" in
3884                 auto | yes |  posix) ol_aix_threads=yes ;;
3885                 esac
3886         fi
3887 ;;
3888 esac
3889
3890 if test $ol_aix_threads = yes ; then
3891         if test -z "${CC}" ; then
3892                 for ac_prog in cc_r xlc_r cc
3893 do
3894   # Extract the first word of "$ac_prog", so it can be a program name with args.
3895 set dummy $ac_prog; ac_word=$2
3896 echo "$as_me:$LINENO: checking for $ac_word" >&5
3897 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3898 if test "${ac_cv_prog_CC+set}" = set; then
3899   echo $ECHO_N "(cached) $ECHO_C" >&6
3900 else
3901   if test -n "$CC"; then
3902   ac_cv_prog_CC="$CC" # Let the user override the test.
3903 else
3904 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3905 for as_dir in $PATH
3906 do
3907   IFS=$as_save_IFS
3908   test -z "$as_dir" && as_dir=.
3909   for ac_exec_ext in '' $ac_executable_extensions; do
3910   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3911     ac_cv_prog_CC="$ac_prog"
3912     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3913     break 2
3914   fi
3915 done
3916 done
3917
3918 fi
3919 fi
3920 CC=$ac_cv_prog_CC
3921 if test -n "$CC"; then
3922   echo "$as_me:$LINENO: result: $CC" >&5
3923 echo "${ECHO_T}$CC" >&6
3924 else
3925   echo "$as_me:$LINENO: result: no" >&5
3926 echo "${ECHO_T}no" >&6
3927 fi
3928
3929   test -n "$CC" && break
3930 done
3931
3932
3933                 if test "$CC" = cc ; then
3934                                                 if test $ol_with_threads != auto ; then
3935                                 { { echo "$as_me:$LINENO: error: --with-threads requires cc_r (or other suitable compiler) on AIX" >&5
3936 echo "$as_me: error: --with-threads requires cc_r (or other suitable compiler) on AIX" >&2;}
3937    { (exit 1); exit 1; }; }
3938                         else
3939                                 { echo "$as_me:$LINENO: WARNING: disabling threads, no cc_r on AIX" >&5
3940 echo "$as_me: WARNING: disabling threads, no cc_r on AIX" >&2;}
3941                         fi
3942                         ol_with_threads=no
3943                 fi
3944         fi
3945
3946         case ${CC} in cc_r | xlc_r)
3947                 ol_with_threads=posix
3948                 ol_cv_pthread_create=yes
3949                 ;;
3950         esac
3951 fi
3952
3953 if test -z "${CC}"; then
3954         for ac_prog in cc gcc
3955 do
3956   # Extract the first word of "$ac_prog", so it can be a program name with args.
3957 set dummy $ac_prog; ac_word=$2
3958 echo "$as_me:$LINENO: checking for $ac_word" >&5
3959 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3960 if test "${ac_cv_prog_CC+set}" = set; then
3961   echo $ECHO_N "(cached) $ECHO_C" >&6
3962 else
3963   if test -n "$CC"; then
3964   ac_cv_prog_CC="$CC" # Let the user override the test.
3965 else
3966 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3967 for as_dir in $PATH
3968 do
3969   IFS=$as_save_IFS
3970   test -z "$as_dir" && as_dir=.
3971   for ac_exec_ext in '' $ac_executable_extensions; do
3972   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3973     ac_cv_prog_CC="$ac_prog"
3974     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3975     break 2
3976   fi
3977 done
3978 done
3979
3980 fi
3981 fi
3982 CC=$ac_cv_prog_CC
3983 if test -n "$CC"; then
3984   echo "$as_me:$LINENO: result: $CC" >&5
3985 echo "${ECHO_T}$CC" >&6
3986 else
3987   echo "$as_me:$LINENO: result: no" >&5
3988 echo "${ECHO_T}no" >&6
3989 fi
3990
3991   test -n "$CC" && break
3992 done
3993 test -n "$CC" || CC="missing"
3994
3995
3996         if test "${CC}" = "missing" ; then
3997                 { { echo "$as_me:$LINENO: error: Unable to locate cc(1) or suitable replacement.  Check PATH or set CC." >&5
3998 echo "$as_me: error: Unable to locate cc(1) or suitable replacement.  Check PATH or set CC." >&2;}
3999    { (exit 1); exit 1; }; }
4000         fi
4001 fi
4002
4003 if test -z "${AR}"; then
4004         for ac_prog in ar gar
4005 do
4006   # Extract the first word of "$ac_prog", so it can be a program name with args.
4007 set dummy $ac_prog; ac_word=$2
4008 echo "$as_me:$LINENO: checking for $ac_word" >&5
4009 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4010 if test "${ac_cv_prog_AR+set}" = set; then
4011   echo $ECHO_N "(cached) $ECHO_C" >&6
4012 else
4013   if test -n "$AR"; then
4014   ac_cv_prog_AR="$AR" # Let the user override the test.
4015 else
4016 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4017 for as_dir in $PATH
4018 do
4019   IFS=$as_save_IFS
4020   test -z "$as_dir" && as_dir=.
4021   for ac_exec_ext in '' $ac_executable_extensions; do
4022   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4023     ac_cv_prog_AR="$ac_prog"
4024     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4025     break 2
4026   fi
4027 done
4028 done
4029
4030 fi
4031 fi
4032 AR=$ac_cv_prog_AR
4033 if test -n "$AR"; then
4034   echo "$as_me:$LINENO: result: $AR" >&5
4035 echo "${ECHO_T}$AR" >&6
4036 else
4037   echo "$as_me:$LINENO: result: no" >&5
4038 echo "${ECHO_T}no" >&6
4039 fi
4040
4041   test -n "$AR" && break
4042 done
4043 test -n "$AR" || AR="missing"
4044
4045
4046         if test "${AR}" = "missing" ; then
4047                 { { echo "$as_me:$LINENO: error: Unable to locate ar(1) or suitable replacement.  Check PATH or set AR." >&5
4048 echo "$as_me: error: Unable to locate ar(1) or suitable replacement.  Check PATH or set AR." >&2;}
4049    { (exit 1); exit 1; }; }
4050         fi
4051 fi
4052
4053
4054
4055
4056
4057 # Check whether --enable-fast-install or --disable-fast-install was given.
4058 if test "${enable_fast_install+set}" = set; then
4059   enableval="$enable_fast_install"
4060   p=${PACKAGE-default}
4061     case $enableval in
4062     yes) enable_fast_install=yes ;;
4063     no) enable_fast_install=no ;;
4064     *)
4065       enable_fast_install=no
4066       # Look at the argument we got.  We use all the common list separators.
4067       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
4068       for pkg in $enableval; do
4069         IFS="$lt_save_ifs"
4070         if test "X$pkg" = "X$p"; then
4071           enable_fast_install=yes
4072         fi
4073       done
4074       IFS="$lt_save_ifs"
4075       ;;
4076     esac
4077 else
4078   enable_fast_install=yes
4079 fi;
4080
4081 DEPDIR="${am__leading_dot}deps"
4082
4083           ac_config_commands="$ac_config_commands depfiles"
4084
4085
4086 am_make=${MAKE-make}
4087 cat > confinc << 'END'
4088 am__doit:
4089         @echo done
4090 .PHONY: am__doit
4091 END
4092 # If we don't find an include directive, just comment out the code.
4093 echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5
4094 echo $ECHO_N "checking for style of include used by $am_make... $ECHO_C" >&6
4095 am__include="#"
4096 am__quote=
4097 _am_result=none
4098 # First try GNU make style include.
4099 echo "include confinc" > confmf
4100 # We grep out `Entering directory' and `Leaving directory'
4101 # messages which can occur if `w' ends up in MAKEFLAGS.
4102 # In particular we don't look at `^make:' because GNU make might
4103 # be invoked under some other name (usually "gmake"), in which
4104 # case it prints its new name instead of `make'.
4105 if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
4106    am__include=include
4107    am__quote=
4108    _am_result=GNU
4109 fi
4110 # Now try BSD make style include.
4111 if test "$am__include" = "#"; then
4112    echo '.include "confinc"' > confmf
4113    if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
4114       am__include=.include
4115       am__quote="\""
4116       _am_result=BSD
4117    fi
4118 fi
4119
4120
4121 echo "$as_me:$LINENO: result: $_am_result" >&5
4122 echo "${ECHO_T}$_am_result" >&6
4123 rm -f confinc confmf
4124
4125 # Check whether --enable-dependency-tracking or --disable-dependency-tracking was given.
4126 if test "${enable_dependency_tracking+set}" = set; then
4127   enableval="$enable_dependency_tracking"
4128
4129 fi;
4130 if test "x$enable_dependency_tracking" != xno; then
4131   am_depcomp="$ac_aux_dir/depcomp"
4132   AMDEPBACKSLASH='\'
4133 fi
4134
4135
4136 if test "x$enable_dependency_tracking" != xno; then
4137   AMDEP_TRUE=
4138   AMDEP_FALSE='#'
4139 else
4140   AMDEP_TRUE='#'
4141   AMDEP_FALSE=
4142 fi
4143
4144
4145
4146 ac_ext=c
4147 ac_cpp='$CPP $CPPFLAGS'
4148 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4149 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4150 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4151 if test -n "$ac_tool_prefix"; then
4152   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4153 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4154 echo "$as_me:$LINENO: checking for $ac_word" >&5
4155 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4156 if test "${ac_cv_prog_CC+set}" = set; then
4157   echo $ECHO_N "(cached) $ECHO_C" >&6
4158 else
4159   if test -n "$CC"; then
4160   ac_cv_prog_CC="$CC" # Let the user override the test.
4161 else
4162 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4163 for as_dir in $PATH
4164 do
4165   IFS=$as_save_IFS
4166   test -z "$as_dir" && as_dir=.
4167   for ac_exec_ext in '' $ac_executable_extensions; do
4168   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4169     ac_cv_prog_CC="${ac_tool_prefix}gcc"
4170     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4171     break 2
4172   fi
4173 done
4174 done
4175
4176 fi
4177 fi
4178 CC=$ac_cv_prog_CC
4179 if test -n "$CC"; then
4180   echo "$as_me:$LINENO: result: $CC" >&5
4181 echo "${ECHO_T}$CC" >&6
4182 else
4183   echo "$as_me:$LINENO: result: no" >&5
4184 echo "${ECHO_T}no" >&6
4185 fi
4186
4187 fi
4188 if test -z "$ac_cv_prog_CC"; then
4189   ac_ct_CC=$CC
4190   # Extract the first word of "gcc", so it can be a program name with args.
4191 set dummy gcc; ac_word=$2
4192 echo "$as_me:$LINENO: checking for $ac_word" >&5
4193 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4194 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
4195   echo $ECHO_N "(cached) $ECHO_C" >&6
4196 else
4197   if test -n "$ac_ct_CC"; then
4198   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4199 else
4200 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4201 for as_dir in $PATH
4202 do
4203   IFS=$as_save_IFS
4204   test -z "$as_dir" && as_dir=.
4205   for ac_exec_ext in '' $ac_executable_extensions; do
4206   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4207     ac_cv_prog_ac_ct_CC="gcc"
4208     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4209     break 2
4210   fi
4211 done
4212 done
4213
4214 fi
4215 fi
4216 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4217 if test -n "$ac_ct_CC"; then
4218   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4219 echo "${ECHO_T}$ac_ct_CC" >&6
4220 else
4221   echo "$as_me:$LINENO: result: no" >&5
4222 echo "${ECHO_T}no" >&6
4223 fi
4224
4225   CC=$ac_ct_CC
4226 else
4227   CC="$ac_cv_prog_CC"
4228 fi
4229
4230 if test -z "$CC"; then
4231   if test -n "$ac_tool_prefix"; then
4232   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4233 set dummy ${ac_tool_prefix}cc; ac_word=$2
4234 echo "$as_me:$LINENO: checking for $ac_word" >&5
4235 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4236 if test "${ac_cv_prog_CC+set}" = set; then
4237   echo $ECHO_N "(cached) $ECHO_C" >&6
4238 else
4239   if test -n "$CC"; then
4240   ac_cv_prog_CC="$CC" # Let the user override the test.
4241 else
4242 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4243 for as_dir in $PATH
4244 do
4245   IFS=$as_save_IFS
4246   test -z "$as_dir" && as_dir=.
4247   for ac_exec_ext in '' $ac_executable_extensions; do
4248   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4249     ac_cv_prog_CC="${ac_tool_prefix}cc"
4250     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4251     break 2
4252   fi
4253 done
4254 done
4255
4256 fi
4257 fi
4258 CC=$ac_cv_prog_CC
4259 if test -n "$CC"; then
4260   echo "$as_me:$LINENO: result: $CC" >&5
4261 echo "${ECHO_T}$CC" >&6
4262 else
4263   echo "$as_me:$LINENO: result: no" >&5
4264 echo "${ECHO_T}no" >&6
4265 fi
4266
4267 fi
4268 if test -z "$ac_cv_prog_CC"; then
4269   ac_ct_CC=$CC
4270   # Extract the first word of "cc", so it can be a program name with args.
4271 set dummy cc; ac_word=$2
4272 echo "$as_me:$LINENO: checking for $ac_word" >&5
4273 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4274 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
4275   echo $ECHO_N "(cached) $ECHO_C" >&6
4276 else
4277   if test -n "$ac_ct_CC"; then
4278   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4279 else
4280 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4281 for as_dir in $PATH
4282 do
4283   IFS=$as_save_IFS
4284   test -z "$as_dir" && as_dir=.
4285   for ac_exec_ext in '' $ac_executable_extensions; do
4286   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4287     ac_cv_prog_ac_ct_CC="cc"
4288     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4289     break 2
4290   fi
4291 done
4292 done
4293
4294 fi
4295 fi
4296 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4297 if test -n "$ac_ct_CC"; then
4298   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4299 echo "${ECHO_T}$ac_ct_CC" >&6
4300 else
4301   echo "$as_me:$LINENO: result: no" >&5
4302 echo "${ECHO_T}no" >&6
4303 fi
4304
4305   CC=$ac_ct_CC
4306 else
4307   CC="$ac_cv_prog_CC"
4308 fi
4309
4310 fi
4311 if test -z "$CC"; then
4312   # Extract the first word of "cc", so it can be a program name with args.
4313 set dummy cc; ac_word=$2
4314 echo "$as_me:$LINENO: checking for $ac_word" >&5
4315 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4316 if test "${ac_cv_prog_CC+set}" = set; then
4317   echo $ECHO_N "(cached) $ECHO_C" >&6
4318 else
4319   if test -n "$CC"; then
4320   ac_cv_prog_CC="$CC" # Let the user override the test.
4321 else
4322   ac_prog_rejected=no
4323 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4324 for as_dir in $PATH
4325 do
4326   IFS=$as_save_IFS
4327   test -z "$as_dir" && as_dir=.
4328   for ac_exec_ext in '' $ac_executable_extensions; do
4329   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4330     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4331        ac_prog_rejected=yes
4332        continue
4333      fi
4334     ac_cv_prog_CC="cc"
4335     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4336     break 2
4337   fi
4338 done
4339 done
4340
4341 if test $ac_prog_rejected = yes; then
4342   # We found a bogon in the path, so make sure we never use it.
4343   set dummy $ac_cv_prog_CC
4344   shift
4345   if test $# != 0; then
4346     # We chose a different compiler from the bogus one.
4347     # However, it has the same basename, so the bogon will be chosen
4348     # first if we set CC to just the basename; use the full file name.
4349     shift
4350     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4351   fi
4352 fi
4353 fi
4354 fi
4355 CC=$ac_cv_prog_CC
4356 if test -n "$CC"; then
4357   echo "$as_me:$LINENO: result: $CC" >&5
4358 echo "${ECHO_T}$CC" >&6
4359 else
4360   echo "$as_me:$LINENO: result: no" >&5
4361 echo "${ECHO_T}no" >&6
4362 fi
4363
4364 fi
4365 if test -z "$CC"; then
4366   if test -n "$ac_tool_prefix"; then
4367   for ac_prog in cl
4368   do
4369     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4370 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4371 echo "$as_me:$LINENO: checking for $ac_word" >&5
4372 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4373 if test "${ac_cv_prog_CC+set}" = set; then
4374   echo $ECHO_N "(cached) $ECHO_C" >&6
4375 else
4376   if test -n "$CC"; then
4377   ac_cv_prog_CC="$CC" # Let the user override the test.
4378 else
4379 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4380 for as_dir in $PATH
4381 do
4382   IFS=$as_save_IFS
4383   test -z "$as_dir" && as_dir=.
4384   for ac_exec_ext in '' $ac_executable_extensions; do
4385   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4386     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4387     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4388     break 2
4389   fi
4390 done
4391 done
4392
4393 fi
4394 fi
4395 CC=$ac_cv_prog_CC
4396 if test -n "$CC"; then
4397   echo "$as_me:$LINENO: result: $CC" >&5
4398 echo "${ECHO_T}$CC" >&6
4399 else
4400   echo "$as_me:$LINENO: result: no" >&5
4401 echo "${ECHO_T}no" >&6
4402 fi
4403
4404     test -n "$CC" && break
4405   done
4406 fi
4407 if test -z "$CC"; then
4408   ac_ct_CC=$CC
4409   for ac_prog in cl
4410 do
4411   # Extract the first word of "$ac_prog", so it can be a program name with args.
4412 set dummy $ac_prog; ac_word=$2
4413 echo "$as_me:$LINENO: checking for $ac_word" >&5
4414 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4415 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
4416   echo $ECHO_N "(cached) $ECHO_C" >&6
4417 else
4418   if test -n "$ac_ct_CC"; then
4419   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4420 else
4421 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4422 for as_dir in $PATH
4423 do
4424   IFS=$as_save_IFS
4425   test -z "$as_dir" && as_dir=.
4426   for ac_exec_ext in '' $ac_executable_extensions; do
4427   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4428     ac_cv_prog_ac_ct_CC="$ac_prog"
4429     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4430     break 2
4431   fi
4432 done
4433 done
4434
4435 fi
4436 fi
4437 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4438 if test -n "$ac_ct_CC"; then
4439   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4440 echo "${ECHO_T}$ac_ct_CC" >&6
4441 else
4442   echo "$as_me:$LINENO: result: no" >&5
4443 echo "${ECHO_T}no" >&6
4444 fi
4445
4446   test -n "$ac_ct_CC" && break
4447 done
4448
4449   CC=$ac_ct_CC
4450 fi
4451
4452 fi
4453
4454
4455 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
4456 See \`config.log' for more details." >&5
4457 echo "$as_me: error: no acceptable C compiler found in \$PATH
4458 See \`config.log' for more details." >&2;}
4459    { (exit 1); exit 1; }; }
4460
4461 # Provide some information about the compiler.
4462 echo "$as_me:$LINENO:" \
4463      "checking for C compiler version" >&5
4464 ac_compiler=`set X $ac_compile; echo $2`
4465 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
4466   (eval $ac_compiler --version </dev/null >&5) 2>&5
4467   ac_status=$?
4468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4469   (exit $ac_status); }
4470 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
4471   (eval $ac_compiler -v </dev/null >&5) 2>&5
4472   ac_status=$?
4473   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4474   (exit $ac_status); }
4475 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
4476   (eval $ac_compiler -V </dev/null >&5) 2>&5
4477   ac_status=$?
4478   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4479   (exit $ac_status); }
4480
4481 cat >conftest.$ac_ext <<_ACEOF
4482 /* confdefs.h.  */
4483 _ACEOF
4484 cat confdefs.h >>conftest.$ac_ext
4485 cat >>conftest.$ac_ext <<_ACEOF
4486 /* end confdefs.h.  */
4487
4488 int
4489 main ()
4490 {
4491
4492   ;
4493   return 0;
4494 }
4495 _ACEOF
4496 ac_clean_files_save=$ac_clean_files
4497 ac_clean_files="$ac_clean_files a.out a.exe b.out"
4498 # Try to create an executable without -o first, disregard a.out.
4499 # It will help us diagnose broken compilers, and finding out an intuition
4500 # of exeext.
4501 echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
4502 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
4503 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4504 if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
4505   (eval $ac_link_default) 2>&5
4506   ac_status=$?
4507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4508   (exit $ac_status); }; then
4509   # Find the output, starting from the most likely.  This scheme is
4510 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
4511 # resort.
4512
4513 # Be careful to initialize this variable, since it used to be cached.
4514 # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
4515 ac_cv_exeext=
4516 # b.out is created by i960 compilers.
4517 for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
4518 do
4519   test -f "$ac_file" || continue
4520   case $ac_file in
4521     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
4522         ;;
4523     conftest.$ac_ext )
4524         # This is the source file.
4525         ;;
4526     [ab].out )
4527         # We found the default executable, but exeext='' is most
4528         # certainly right.
4529         break;;
4530     *.* )
4531         ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4532         # FIXME: I believe we export ac_cv_exeext for Libtool,
4533         # but it would be cool to find out if it's true.  Does anybody
4534         # maintain Libtool? --akim.
4535         export ac_cv_exeext
4536         break;;
4537     * )
4538         break;;
4539   esac
4540 done
4541 else
4542   echo "$as_me: failed program was:" >&5
4543 sed 's/^/| /' conftest.$ac_ext >&5
4544
4545 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
4546 See \`config.log' for more details." >&5
4547 echo "$as_me: error: C compiler cannot create executables
4548 See \`config.log' for more details." >&2;}
4549    { (exit 77); exit 77; }; }
4550 fi
4551
4552 ac_exeext=$ac_cv_exeext
4553 echo "$as_me:$LINENO: result: $ac_file" >&5
4554 echo "${ECHO_T}$ac_file" >&6
4555
4556 # Check the compiler produces executables we can run.  If not, either
4557 # the compiler is broken, or we cross compile.
4558 echo "$as_me:$LINENO: checking whether the C compiler works" >&5
4559 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
4560 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
4561 # If not cross compiling, check that we can run a simple program.
4562 if test "$cross_compiling" != yes; then
4563   if { ac_try='./$ac_file'
4564   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4565   (eval $ac_try) 2>&5
4566   ac_status=$?
4567   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4568   (exit $ac_status); }; }; then
4569     cross_compiling=no
4570   else
4571     if test "$cross_compiling" = maybe; then
4572         cross_compiling=yes
4573     else
4574         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
4575 If you meant to cross compile, use \`--host'.
4576 See \`config.log' for more details." >&5
4577 echo "$as_me: error: cannot run C compiled programs.
4578 If you meant to cross compile, use \`--host'.
4579 See \`config.log' for more details." >&2;}
4580    { (exit 1); exit 1; }; }
4581     fi
4582   fi
4583 fi
4584 echo "$as_me:$LINENO: result: yes" >&5
4585 echo "${ECHO_T}yes" >&6
4586
4587 rm -f a.out a.exe conftest$ac_cv_exeext b.out
4588 ac_clean_files=$ac_clean_files_save
4589 # Check the compiler produces executables we can run.  If not, either
4590 # the compiler is broken, or we cross compile.
4591 echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
4592 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
4593 echo "$as_me:$LINENO: result: $cross_compiling" >&5
4594 echo "${ECHO_T}$cross_compiling" >&6
4595
4596 echo "$as_me:$LINENO: checking for suffix of executables" >&5
4597 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
4598 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4599   (eval $ac_link) 2>&5
4600   ac_status=$?
4601   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4602   (exit $ac_status); }; then
4603   # If both `conftest.exe' and `conftest' are `present' (well, observable)
4604 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
4605 # work properly (i.e., refer to `conftest.exe'), while it won't with
4606 # `rm'.
4607 for ac_file in conftest.exe conftest conftest.*; do
4608   test -f "$ac_file" || continue
4609   case $ac_file in
4610     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
4611     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4612           export ac_cv_exeext
4613           break;;
4614     * ) break;;
4615   esac
4616 done
4617 else
4618   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
4619 See \`config.log' for more details." >&5
4620 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
4621 See \`config.log' for more details." >&2;}
4622    { (exit 1); exit 1; }; }
4623 fi
4624
4625 rm -f conftest$ac_cv_exeext
4626 echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
4627 echo "${ECHO_T}$ac_cv_exeext" >&6
4628
4629 rm -f conftest.$ac_ext
4630 EXEEXT=$ac_cv_exeext
4631 ac_exeext=$EXEEXT
4632 echo "$as_me:$LINENO: checking for suffix of object files" >&5
4633 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
4634 if test "${ac_cv_objext+set}" = set; then
4635   echo $ECHO_N "(cached) $ECHO_C" >&6
4636 else
4637   cat >conftest.$ac_ext <<_ACEOF
4638 /* confdefs.h.  */
4639 _ACEOF
4640 cat confdefs.h >>conftest.$ac_ext
4641 cat >>conftest.$ac_ext <<_ACEOF
4642 /* end confdefs.h.  */
4643
4644 int
4645 main ()
4646 {
4647
4648   ;
4649   return 0;
4650 }
4651 _ACEOF
4652 rm -f conftest.o conftest.obj
4653 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4654   (eval $ac_compile) 2>&5
4655   ac_status=$?
4656   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4657   (exit $ac_status); }; then
4658   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
4659   case $ac_file in
4660     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
4661     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4662        break;;
4663   esac
4664 done
4665 else
4666   echo "$as_me: failed program was:" >&5
4667 sed 's/^/| /' conftest.$ac_ext >&5
4668
4669 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
4670 See \`config.log' for more details." >&5
4671 echo "$as_me: error: cannot compute suffix of object files: cannot compile
4672 See \`config.log' for more details." >&2;}
4673    { (exit 1); exit 1; }; }
4674 fi
4675
4676 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4677 fi
4678 echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
4679 echo "${ECHO_T}$ac_cv_objext" >&6
4680 OBJEXT=$ac_cv_objext
4681 ac_objext=$OBJEXT
4682 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
4683 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
4684 if test "${ac_cv_c_compiler_gnu+set}" = set; then
4685   echo $ECHO_N "(cached) $ECHO_C" >&6
4686 else
4687   cat >conftest.$ac_ext <<_ACEOF
4688 /* confdefs.h.  */
4689 _ACEOF
4690 cat confdefs.h >>conftest.$ac_ext
4691 cat >>conftest.$ac_ext <<_ACEOF
4692 /* end confdefs.h.  */
4693
4694 int
4695 main ()
4696 {
4697 #ifndef __GNUC__
4698        choke me
4699 #endif
4700
4701   ;
4702   return 0;
4703 }
4704 _ACEOF
4705 rm -f conftest.$ac_objext
4706 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4707   (eval $ac_compile) 2>conftest.er1
4708   ac_status=$?
4709   grep -v '^ *+' conftest.er1 >conftest.err
4710   rm -f conftest.er1
4711   cat conftest.err >&5
4712   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4713   (exit $ac_status); } &&
4714          { ac_try='test -z "$ac_c_werror_flag"
4715                          || test ! -s conftest.err'
4716   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4717   (eval $ac_try) 2>&5
4718   ac_status=$?
4719   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4720   (exit $ac_status); }; } &&
4721          { ac_try='test -s conftest.$ac_objext'
4722   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4723   (eval $ac_try) 2>&5
4724   ac_status=$?
4725   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4726   (exit $ac_status); }; }; then
4727   ac_compiler_gnu=yes
4728 else
4729   echo "$as_me: failed program was:" >&5
4730 sed 's/^/| /' conftest.$ac_ext >&5
4731
4732 ac_compiler_gnu=no
4733 fi
4734 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4735 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4736
4737 fi
4738 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
4739 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
4740 GCC=`test $ac_compiler_gnu = yes && echo yes`
4741 ac_test_CFLAGS=${CFLAGS+set}
4742 ac_save_CFLAGS=$CFLAGS
4743 CFLAGS="-g"
4744 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
4745 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
4746 if test "${ac_cv_prog_cc_g+set}" = set; then
4747   echo $ECHO_N "(cached) $ECHO_C" >&6
4748 else
4749   cat >conftest.$ac_ext <<_ACEOF
4750 /* confdefs.h.  */
4751 _ACEOF
4752 cat confdefs.h >>conftest.$ac_ext
4753 cat >>conftest.$ac_ext <<_ACEOF
4754 /* end confdefs.h.  */
4755
4756 int
4757 main ()
4758 {
4759
4760   ;
4761   return 0;
4762 }
4763 _ACEOF
4764 rm -f conftest.$ac_objext
4765 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4766   (eval $ac_compile) 2>conftest.er1
4767   ac_status=$?
4768   grep -v '^ *+' conftest.er1 >conftest.err
4769   rm -f conftest.er1
4770   cat conftest.err >&5
4771   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4772   (exit $ac_status); } &&
4773          { ac_try='test -z "$ac_c_werror_flag"
4774                          || test ! -s conftest.err'
4775   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4776   (eval $ac_try) 2>&5
4777   ac_status=$?
4778   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4779   (exit $ac_status); }; } &&
4780          { ac_try='test -s conftest.$ac_objext'
4781   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4782   (eval $ac_try) 2>&5
4783   ac_status=$?
4784   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4785   (exit $ac_status); }; }; then
4786   ac_cv_prog_cc_g=yes
4787 else
4788   echo "$as_me: failed program was:" >&5
4789 sed 's/^/| /' conftest.$ac_ext >&5
4790
4791 ac_cv_prog_cc_g=no
4792 fi
4793 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4794 fi
4795 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
4796 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
4797 if test "$ac_test_CFLAGS" = set; then
4798   CFLAGS=$ac_save_CFLAGS
4799 elif test $ac_cv_prog_cc_g = yes; then
4800   if test "$GCC" = yes; then
4801     CFLAGS="-g -O2"
4802   else
4803     CFLAGS="-g"
4804   fi
4805 else
4806   if test "$GCC" = yes; then
4807     CFLAGS="-O2"
4808   else
4809     CFLAGS=
4810   fi
4811 fi
4812 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
4813 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
4814 if test "${ac_cv_prog_cc_stdc+set}" = set; then
4815   echo $ECHO_N "(cached) $ECHO_C" >&6
4816 else
4817   ac_cv_prog_cc_stdc=no
4818 ac_save_CC=$CC
4819 cat >conftest.$ac_ext <<_ACEOF
4820 /* confdefs.h.  */
4821 _ACEOF
4822 cat confdefs.h >>conftest.$ac_ext
4823 cat >>conftest.$ac_ext <<_ACEOF
4824 /* end confdefs.h.  */
4825 #include <stdarg.h>
4826 #include <stdio.h>
4827 #include <sys/types.h>
4828 #include <sys/stat.h>
4829 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4830 struct buf { int x; };
4831 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4832 static char *e (p, i)
4833      char **p;
4834      int i;
4835 {
4836   return p[i];
4837 }
4838 static char *f (char * (*g) (char **, int), char **p, ...)
4839 {
4840   char *s;
4841   va_list v;
4842   va_start (v,p);
4843   s = g (p, va_arg (v,int));
4844   va_end (v);
4845   return s;
4846 }
4847
4848 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
4849    function prototypes and stuff, but not '\xHH' hex character constants.
4850    These don't provoke an error unfortunately, instead are silently treated
4851    as 'x'.  The following induces an error, until -std1 is added to get
4852    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
4853    array size at least.  It's necessary to write '\x00'==0 to get something
4854    that's true only with -std1.  */
4855 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4856
4857 int test (int i, double x);
4858 struct s1 {int (*f) (int a);};
4859 struct s2 {int (*f) (double a);};
4860 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4861 int argc;
4862 char **argv;
4863 int
4864 main ()
4865 {
4866 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4867   ;
4868   return 0;
4869 }
4870 _ACEOF
4871 # Don't try gcc -ansi; that turns off useful extensions and
4872 # breaks some systems' header files.
4873 # AIX                   -qlanglvl=ansi
4874 # Ultrix and OSF/1      -std1
4875 # HP-UX 10.20 and later -Ae
4876 # HP-UX older versions  -Aa -D_HPUX_SOURCE
4877 # SVR4                  -Xc -D__EXTENSIONS__
4878 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4879 do
4880   CC="$ac_save_CC $ac_arg"
4881   rm -f conftest.$ac_objext
4882 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4883   (eval $ac_compile) 2>conftest.er1
4884   ac_status=$?
4885   grep -v '^ *+' conftest.er1 >conftest.err
4886   rm -f conftest.er1
4887   cat conftest.err >&5
4888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4889   (exit $ac_status); } &&
4890          { ac_try='test -z "$ac_c_werror_flag"
4891                          || test ! -s conftest.err'
4892   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4893   (eval $ac_try) 2>&5
4894   ac_status=$?
4895   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4896   (exit $ac_status); }; } &&
4897          { ac_try='test -s conftest.$ac_objext'
4898   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4899   (eval $ac_try) 2>&5
4900   ac_status=$?
4901   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4902   (exit $ac_status); }; }; then
4903   ac_cv_prog_cc_stdc=$ac_arg
4904 break
4905 else
4906   echo "$as_me: failed program was:" >&5
4907 sed 's/^/| /' conftest.$ac_ext >&5
4908
4909 fi
4910 rm -f conftest.err conftest.$ac_objext
4911 done
4912 rm -f conftest.$ac_ext conftest.$ac_objext
4913 CC=$ac_save_CC
4914
4915 fi
4916
4917 case "x$ac_cv_prog_cc_stdc" in
4918   x|xno)
4919     echo "$as_me:$LINENO: result: none needed" >&5
4920 echo "${ECHO_T}none needed" >&6 ;;
4921   *)
4922     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
4923 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
4924     CC="$CC $ac_cv_prog_cc_stdc" ;;
4925 esac
4926
4927 # Some people use a C++ compiler to compile C.  Since we use `exit',
4928 # in C++ we need to declare it.  In case someone uses the same compiler
4929 # for both compiling C and C++ we need to have the C++ compiler decide
4930 # the declaration of exit, since it's the most demanding environment.
4931 cat >conftest.$ac_ext <<_ACEOF
4932 #ifndef __cplusplus
4933   choke me
4934 #endif
4935 _ACEOF
4936 rm -f conftest.$ac_objext
4937 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4938   (eval $ac_compile) 2>conftest.er1
4939   ac_status=$?
4940   grep -v '^ *+' conftest.er1 >conftest.err
4941   rm -f conftest.er1
4942   cat conftest.err >&5
4943   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4944   (exit $ac_status); } &&
4945          { ac_try='test -z "$ac_c_werror_flag"
4946                          || test ! -s conftest.err'
4947   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4948   (eval $ac_try) 2>&5
4949   ac_status=$?
4950   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4951   (exit $ac_status); }; } &&
4952          { ac_try='test -s conftest.$ac_objext'
4953   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4954   (eval $ac_try) 2>&5
4955   ac_status=$?
4956   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4957   (exit $ac_status); }; }; then
4958   for ac_declaration in \
4959    '' \
4960    'extern "C" void std::exit (int) throw (); using std::exit;' \
4961    'extern "C" void std::exit (int); using std::exit;' \
4962    'extern "C" void exit (int) throw ();' \
4963    'extern "C" void exit (int);' \
4964    'void exit (int);'
4965 do
4966   cat >conftest.$ac_ext <<_ACEOF
4967 /* confdefs.h.  */
4968 _ACEOF
4969 cat confdefs.h >>conftest.$ac_ext
4970 cat >>conftest.$ac_ext <<_ACEOF
4971 /* end confdefs.h.  */
4972 $ac_declaration
4973 #include <stdlib.h>
4974 int
4975 main ()
4976 {
4977 exit (42);
4978   ;
4979   return 0;
4980 }
4981 _ACEOF
4982 rm -f conftest.$ac_objext
4983 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4984   (eval $ac_compile) 2>conftest.er1
4985   ac_status=$?
4986   grep -v '^ *+' conftest.er1 >conftest.err
4987   rm -f conftest.er1
4988   cat conftest.err >&5
4989   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4990   (exit $ac_status); } &&
4991          { ac_try='test -z "$ac_c_werror_flag"
4992                          || test ! -s conftest.err'
4993   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4994   (eval $ac_try) 2>&5
4995   ac_status=$?
4996   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4997   (exit $ac_status); }; } &&
4998          { ac_try='test -s conftest.$ac_objext'
4999   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5000   (eval $ac_try) 2>&5
5001   ac_status=$?
5002   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5003   (exit $ac_status); }; }; then
5004   :
5005 else
5006   echo "$as_me: failed program was:" >&5
5007 sed 's/^/| /' conftest.$ac_ext >&5
5008
5009 continue
5010 fi
5011 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5012   cat >conftest.$ac_ext <<_ACEOF
5013 /* confdefs.h.  */
5014 _ACEOF
5015 cat confdefs.h >>conftest.$ac_ext
5016 cat >>conftest.$ac_ext <<_ACEOF
5017 /* end confdefs.h.  */
5018 $ac_declaration
5019 int
5020 main ()
5021 {
5022 exit (42);
5023   ;
5024   return 0;
5025 }
5026 _ACEOF
5027 rm -f conftest.$ac_objext
5028 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5029   (eval $ac_compile) 2>conftest.er1
5030   ac_status=$?
5031   grep -v '^ *+' conftest.er1 >conftest.err
5032   rm -f conftest.er1
5033   cat conftest.err >&5
5034   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5035   (exit $ac_status); } &&
5036          { ac_try='test -z "$ac_c_werror_flag"
5037                          || test ! -s conftest.err'
5038   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5039   (eval $ac_try) 2>&5
5040   ac_status=$?
5041   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5042   (exit $ac_status); }; } &&
5043          { ac_try='test -s conftest.$ac_objext'
5044   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5045   (eval $ac_try) 2>&5
5046   ac_status=$?
5047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5048   (exit $ac_status); }; }; then
5049   break
5050 else
5051   echo "$as_me: failed program was:" >&5
5052 sed 's/^/| /' conftest.$ac_ext >&5
5053
5054 fi
5055 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5056 done
5057 rm -f conftest*
5058 if test -n "$ac_declaration"; then
5059   echo '#ifdef __cplusplus' >>confdefs.h
5060   echo $ac_declaration      >>confdefs.h
5061   echo '#endif'             >>confdefs.h
5062 fi
5063
5064 else
5065   echo "$as_me: failed program was:" >&5
5066 sed 's/^/| /' conftest.$ac_ext >&5
5067
5068 fi
5069 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5070 ac_ext=c
5071 ac_cpp='$CPP $CPPFLAGS'
5072 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5073 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5074 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5075
5076 depcc="$CC"   am_compiler_list=
5077
5078 echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
5079 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6
5080 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
5081   echo $ECHO_N "(cached) $ECHO_C" >&6
5082 else
5083   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5084   # We make a subdir and do the tests there.  Otherwise we can end up
5085   # making bogus files that we don't know about and never remove.  For
5086   # instance it was reported that on HP-UX the gcc test will end up
5087   # making a dummy file named `D' -- because `-MD' means `put the output
5088   # in D'.
5089   mkdir conftest.dir
5090   # Copy depcomp to subdir because otherwise we won't find it if we're
5091   # using a relative directory.
5092   cp "$am_depcomp" conftest.dir
5093   cd conftest.dir
5094   # We will build objects and dependencies in a subdirectory because
5095   # it helps to detect inapplicable dependency modes.  For instance
5096   # both Tru64's cc and ICC support -MD to output dependencies as a
5097   # side effect of compilation, but ICC will put the dependencies in
5098   # the current directory while Tru64 will put them in the object
5099   # directory.
5100   mkdir sub
5101
5102   am_cv_CC_dependencies_compiler_type=none
5103   if test "$am_compiler_list" = ""; then
5104      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5105   fi
5106   for depmode in $am_compiler_list; do
5107     # Setup a source with many dependencies, because some compilers
5108     # like to wrap large dependency lists on column 80 (with \), and
5109     # we should not choose a depcomp mode which is confused by this.
5110     #
5111     # We need to recreate these files for each test, as the compiler may
5112     # overwrite some of them when testing with obscure command lines.
5113     # This happens at least with the AIX C compiler.
5114     : > sub/conftest.c
5115     for i in 1 2 3 4 5 6; do
5116       echo '#include "conftst'$i'.h"' >> sub/conftest.c
5117       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5118       # Solaris 8's {/usr,}/bin/sh.
5119       touch sub/conftst$i.h
5120     done
5121     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5122
5123     case $depmode in
5124     nosideeffect)
5125       # after this tag, mechanisms are not by side-effect, so they'll
5126       # only be used when explicitly requested
5127       if test "x$enable_dependency_tracking" = xyes; then
5128         continue
5129       else
5130         break
5131       fi
5132       ;;
5133     none) break ;;
5134     esac
5135     # We check with `-c' and `-o' for the sake of the "dashmstdout"
5136     # mode.  It turns out that the SunPro C++ compiler does not properly
5137     # handle `-M -o', and we need to detect this.
5138     if depmode=$depmode \
5139        source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
5140        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5141        $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
5142          >/dev/null 2>conftest.err &&
5143        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5144        grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
5145        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5146       # icc doesn't choke on unknown options, it will just issue warnings
5147       # or remarks (even with -Werror).  So we grep stderr for any message
5148       # that says an option was ignored or not supported.
5149       # When given -MP, icc 7.0 and 7.1 complain thusly:
5150       #   icc: Command line warning: ignoring option '-M'; no argument required
5151       # The diagnosis changed in icc 8.0:
5152       #   icc: Command line remark: option '-MP' not supported
5153       if (grep 'ignoring option' conftest.err ||
5154           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5155         am_cv_CC_dependencies_compiler_type=$depmode
5156         break
5157       fi
5158     fi
5159   done
5160
5161   cd ..
5162   rm -rf conftest.dir
5163 else
5164   am_cv_CC_dependencies_compiler_type=none
5165 fi
5166
5167 fi
5168 echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
5169 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6
5170 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5171
5172
5173
5174 if
5175   test "x$enable_dependency_tracking" != xno \
5176   && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5177   am__fastdepCC_TRUE=
5178   am__fastdepCC_FALSE='#'
5179 else
5180   am__fastdepCC_TRUE='#'
5181   am__fastdepCC_FALSE=
5182 fi
5183
5184
5185 echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5
5186 echo $ECHO_N "checking for a sed that does not truncate output... $ECHO_C" >&6
5187 if test "${lt_cv_path_SED+set}" = set; then
5188   echo $ECHO_N "(cached) $ECHO_C" >&6
5189 else
5190   # Loop through the user's path and test for sed and gsed.
5191 # Then use that list of sed's as ones to test for truncation.
5192 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5193 for as_dir in $PATH
5194 do
5195   IFS=$as_save_IFS
5196   test -z "$as_dir" && as_dir=.
5197   for lt_ac_prog in sed gsed; do
5198     for ac_exec_ext in '' $ac_executable_extensions; do
5199       if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
5200         lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
5201       fi
5202     done
5203   done
5204 done
5205 lt_ac_max=0
5206 lt_ac_count=0
5207 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
5208 # along with /bin/sed that truncates output.
5209 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
5210   test ! -f $lt_ac_sed && continue
5211   cat /dev/null > conftest.in
5212   lt_ac_count=0
5213   echo $ECHO_N "0123456789$ECHO_C" >conftest.in
5214   # Check for GNU sed and select it if it is found.
5215   if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
5216     lt_cv_path_SED=$lt_ac_sed
5217     break
5218   fi
5219   while true; do
5220     cat conftest.in conftest.in >conftest.tmp
5221     mv conftest.tmp conftest.in
5222     cp conftest.in conftest.nl
5223     echo >>conftest.nl
5224     $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
5225     cmp -s conftest.out conftest.nl || break
5226     # 10000 chars as input seems more than enough
5227     test $lt_ac_count -gt 10 && break
5228     lt_ac_count=`expr $lt_ac_count + 1`
5229     if test $lt_ac_count -gt $lt_ac_max; then
5230       lt_ac_max=$lt_ac_count
5231       lt_cv_path_SED=$lt_ac_sed
5232     fi
5233   done
5234 done
5235
5236 fi
5237
5238 SED=$lt_cv_path_SED
5239 echo "$as_me:$LINENO: result: $SED" >&5
5240 echo "${ECHO_T}$SED" >&6
5241
5242 echo "$as_me:$LINENO: checking for egrep" >&5
5243 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
5244 if test "${ac_cv_prog_egrep+set}" = set; then
5245   echo $ECHO_N "(cached) $ECHO_C" >&6
5246 else
5247   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
5248     then ac_cv_prog_egrep='grep -E'
5249     else ac_cv_prog_egrep='egrep'
5250     fi
5251 fi
5252 echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
5253 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
5254  EGREP=$ac_cv_prog_egrep
5255
5256
5257
5258 # Check whether --with-gnu-ld or --without-gnu-ld was given.
5259 if test "${with_gnu_ld+set}" = set; then
5260   withval="$with_gnu_ld"
5261   test "$withval" = no || with_gnu_ld=yes
5262 else
5263   with_gnu_ld=no
5264 fi;
5265 ac_prog=ld
5266 if test "$GCC" = yes; then
5267   # Check if gcc -print-prog-name=ld gives a path.
5268   echo "$as_me:$LINENO: checking for ld used by $CC" >&5
5269 echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6
5270   case $host in
5271   *-*-mingw*)
5272     # gcc leaves a trailing carriage return which upsets mingw
5273     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
5274   *)
5275     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
5276   esac
5277   case $ac_prog in
5278     # Accept absolute paths.
5279     [\\/]* | ?:[\\/]*)
5280       re_direlt='/[^/][^/]*/\.\./'
5281       # Canonicalize the pathname of ld
5282       ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
5283       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
5284         ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
5285       done
5286       test -z "$LD" && LD="$ac_prog"
5287       ;;
5288   "")
5289     # If it fails, then pretend we aren't using GCC.
5290     ac_prog=ld
5291     ;;
5292   *)
5293     # If it is relative, then search for the first ld in PATH.
5294     with_gnu_ld=unknown
5295     ;;
5296   esac
5297 elif test "$with_gnu_ld" = yes; then
5298   echo "$as_me:$LINENO: checking for GNU ld" >&5
5299 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
5300 else
5301   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
5302 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
5303 fi
5304 if test "${lt_cv_path_LD+set}" = set; then
5305   echo $ECHO_N "(cached) $ECHO_C" >&6
5306 else
5307   if test -z "$LD"; then
5308   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
5309   for ac_dir in $PATH; do
5310     IFS="$lt_save_ifs"
5311     test -z "$ac_dir" && ac_dir=.
5312     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
5313       lt_cv_path_LD="$ac_dir/$ac_prog"
5314       # Check to see if the program is GNU ld.  I'd rather use --version,
5315       # but apparently some variants of GNU ld only accept -v.
5316       # Break only if it was the GNU/non-GNU ld that we prefer.
5317       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
5318       *GNU* | *'with BFD'*)
5319         test "$with_gnu_ld" != no && break
5320         ;;
5321       *)
5322         test "$with_gnu_ld" != yes && break
5323         ;;
5324       esac
5325     fi
5326   done
5327   IFS="$lt_save_ifs"
5328 else
5329   lt_cv_path_LD="$LD" # Let the user override the test with a path.
5330 fi
5331 fi
5332
5333 LD="$lt_cv_path_LD"
5334 if test -n "$LD"; then
5335   echo "$as_me:$LINENO: result: $LD" >&5
5336 echo "${ECHO_T}$LD" >&6
5337 else
5338   echo "$as_me:$LINENO: result: no" >&5
5339 echo "${ECHO_T}no" >&6
5340 fi
5341 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
5342 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
5343    { (exit 1); exit 1; }; }
5344 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
5345 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
5346 if test "${lt_cv_prog_gnu_ld+set}" = set; then
5347   echo $ECHO_N "(cached) $ECHO_C" >&6
5348 else
5349   # I'd rather use --version here, but apparently some GNU lds only accept -v.
5350 case `$LD -v 2>&1 </dev/null` in
5351 *GNU* | *'with BFD'*)
5352   lt_cv_prog_gnu_ld=yes
5353   ;;
5354 *)
5355   lt_cv_prog_gnu_ld=no
5356   ;;
5357 esac
5358 fi
5359 echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
5360 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6
5361 with_gnu_ld=$lt_cv_prog_gnu_ld
5362
5363
5364 echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5
5365 echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6
5366 if test "${lt_cv_ld_reload_flag+set}" = set; then
5367   echo $ECHO_N "(cached) $ECHO_C" >&6
5368 else
5369   lt_cv_ld_reload_flag='-r'
5370 fi
5371 echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5
5372 echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6
5373 reload_flag=$lt_cv_ld_reload_flag
5374 case $reload_flag in
5375 "" | " "*) ;;
5376 *) reload_flag=" $reload_flag" ;;
5377 esac
5378 reload_cmds='$LD$reload_flag -o $output$reload_objs'
5379 case $host_os in
5380   darwin*)
5381     if test "$GCC" = yes; then
5382       reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs'
5383     else
5384       reload_cmds='$LD$reload_flag -o $output$reload_objs'
5385     fi
5386     ;;
5387 esac
5388
5389 echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
5390 echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6
5391 if test "${lt_cv_path_NM+set}" = set; then
5392   echo $ECHO_N "(cached) $ECHO_C" >&6
5393 else
5394   if test -n "$NM"; then
5395   # Let the user override the test.
5396   lt_cv_path_NM="$NM"
5397 else
5398   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
5399   for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
5400     IFS="$lt_save_ifs"
5401     test -z "$ac_dir" && ac_dir=.
5402     tmp_nm="$ac_dir/${ac_tool_prefix}nm"
5403     if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
5404       # Check to see if the nm accepts a BSD-compat flag.
5405       # Adding the `sed 1q' prevents false positives on HP-UX, which says:
5406       #   nm: unknown option "B" ignored
5407       # Tru64's nm complains that /dev/null is an invalid object file
5408       case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
5409       */dev/null* | *'Invalid file or object type'*)
5410         lt_cv_path_NM="$tmp_nm -B"
5411         break
5412         ;;
5413       *)
5414         case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
5415         */dev/null*)
5416           lt_cv_path_NM="$tmp_nm -p"
5417           break
5418           ;;
5419         *)
5420           lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
5421           continue # so that we can try to find one that supports BSD flags
5422           ;;
5423         esac
5424       esac
5425     fi
5426   done
5427   IFS="$lt_save_ifs"
5428   test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
5429 fi
5430 fi
5431 echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5
5432 echo "${ECHO_T}$lt_cv_path_NM" >&6
5433 NM="$lt_cv_path_NM"
5434
5435 echo "$as_me:$LINENO: checking whether ln -s works" >&5
5436 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
5437 LN_S=$as_ln_s
5438 if test "$LN_S" = "ln -s"; then
5439   echo "$as_me:$LINENO: result: yes" >&5
5440 echo "${ECHO_T}yes" >&6
5441 else
5442   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
5443 echo "${ECHO_T}no, using $LN_S" >&6
5444 fi
5445
5446 echo "$as_me:$LINENO: checking how to recognise dependent libraries" >&5
5447 echo $ECHO_N "checking how to recognise dependent libraries... $ECHO_C" >&6
5448 if test "${lt_cv_deplibs_check_method+set}" = set; then
5449   echo $ECHO_N "(cached) $ECHO_C" >&6
5450 else
5451   lt_cv_file_magic_cmd='$MAGIC_CMD'
5452 lt_cv_file_magic_test_file=
5453 lt_cv_deplibs_check_method='unknown'
5454 # Need to set the preceding variable on all platforms that support
5455 # interlibrary dependencies.
5456 # 'none' -- dependencies not supported.
5457 # `unknown' -- same as none, but documents that we really don't know.
5458 # 'pass_all' -- all dependencies passed with no checks.
5459 # 'test_compile' -- check by making test program.
5460 # 'file_magic [[regex]]' -- check by looking for files in library path
5461 # which responds to the $file_magic_cmd with a given extended regex.
5462 # If you have `file' or equivalent on your system and you're not sure
5463 # whether `pass_all' will *always* work, you probably want this one.
5464
5465 case $host_os in
5466 aix4* | aix5*)
5467   lt_cv_deplibs_check_method=pass_all
5468   ;;
5469
5470 beos*)
5471   lt_cv_deplibs_check_method=pass_all
5472   ;;
5473
5474 bsdi[45]*)
5475   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
5476   lt_cv_file_magic_cmd='/usr/bin/file -L'
5477   lt_cv_file_magic_test_file=/shlib/libc.so
5478   ;;
5479
5480 cygwin*)
5481   # func_win32_libid is a shell function defined in ltmain.sh
5482   lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
5483   lt_cv_file_magic_cmd='func_win32_libid'
5484   ;;
5485
5486 mingw* | pw32*)
5487   # Base MSYS/MinGW do not provide the 'file' command needed by
5488   # func_win32_libid shell function, so use a weaker test based on 'objdump'.
5489   lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
5490   lt_cv_file_magic_cmd='$OBJDUMP -f'
5491   ;;
5492
5493 darwin* | rhapsody*)
5494   lt_cv_deplibs_check_method=pass_all
5495   ;;
5496
5497 freebsd* | kfreebsd*-gnu | dragonfly*)
5498   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
5499     case $host_cpu in
5500     i*86 )
5501       # Not sure whether the presence of OpenBSD here was a mistake.
5502       # Let's accept both of them until this is cleared up.
5503       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
5504       lt_cv_file_magic_cmd=/usr/bin/file
5505       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
5506       ;;
5507     esac
5508   else
5509     lt_cv_deplibs_check_method=pass_all
5510   fi
5511   ;;
5512
5513 gnu*)
5514   lt_cv_deplibs_check_method=pass_all
5515   ;;
5516
5517 hpux10.20* | hpux11*)
5518   lt_cv_file_magic_cmd=/usr/bin/file
5519   case $host_cpu in
5520   ia64*)
5521     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
5522     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
5523     ;;
5524   hppa*64*)
5525     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'
5526     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
5527     ;;
5528   *)
5529     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
5530     lt_cv_file_magic_test_file=/usr/lib/libc.sl
5531     ;;
5532   esac
5533   ;;
5534
5535 irix5* | irix6* | nonstopux*)
5536   case $LD in
5537   *-32|*"-32 ") libmagic=32-bit;;
5538   *-n32|*"-n32 ") libmagic=N32;;
5539   *-64|*"-64 ") libmagic=64-bit;;
5540   *) libmagic=never-match;;
5541   esac
5542   lt_cv_deplibs_check_method=pass_all
5543   ;;
5544
5545 # This must be Linux ELF.
5546 linux*)
5547   lt_cv_deplibs_check_method=pass_all
5548   ;;
5549
5550 netbsd*)
5551   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
5552     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5553   else
5554     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
5555   fi
5556   ;;
5557
5558 newos6*)
5559   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
5560   lt_cv_file_magic_cmd=/usr/bin/file
5561   lt_cv_file_magic_test_file=/usr/lib/libnls.so
5562   ;;
5563
5564 nto-qnx*)
5565   lt_cv_deplibs_check_method=unknown
5566   ;;
5567
5568 openbsd*)
5569   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5570     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
5571   else
5572     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5573   fi
5574   ;;
5575
5576 osf3* | osf4* | osf5*)
5577   lt_cv_deplibs_check_method=pass_all
5578   ;;
5579
5580 sco3.2v5*)
5581   lt_cv_deplibs_check_method=pass_all
5582   ;;
5583
5584 solaris*)
5585   lt_cv_deplibs_check_method=pass_all
5586   ;;
5587
5588 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5589   case $host_vendor in
5590   motorola)
5591     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
5592     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
5593     ;;
5594   ncr)
5595     lt_cv_deplibs_check_method=pass_all
5596     ;;
5597   sequent)
5598     lt_cv_file_magic_cmd='/bin/file'
5599     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
5600     ;;
5601   sni)
5602     lt_cv_file_magic_cmd='/bin/file'
5603     lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
5604     lt_cv_file_magic_test_file=/lib/libc.so
5605     ;;
5606   siemens)
5607     lt_cv_deplibs_check_method=pass_all
5608     ;;
5609   esac
5610   ;;
5611
5612 sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7* | sysv4*uw2*)
5613   lt_cv_deplibs_check_method=pass_all
5614   ;;
5615 esac
5616
5617 fi
5618 echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5
5619 echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6
5620 file_magic_cmd=$lt_cv_file_magic_cmd
5621 deplibs_check_method=$lt_cv_deplibs_check_method
5622 test -z "$deplibs_check_method" && deplibs_check_method=unknown
5623
5624
5625
5626
5627 # If no C compiler was specified, use CC.
5628 LTCC=${LTCC-"$CC"}
5629
5630 # Allow CC to be a program name with arguments.
5631 compiler=$CC
5632
5633
5634 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
5635 if test "${enable_libtool_lock+set}" = set; then
5636   enableval="$enable_libtool_lock"
5637
5638 fi;
5639 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
5640
5641 # Some flags need to be propagated to the compiler or linker for good
5642 # libtool support.
5643 case $host in
5644 ia64-*-hpux*)
5645   # Find out which ABI we are using.
5646   echo 'int i;' > conftest.$ac_ext
5647   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5648   (eval $ac_compile) 2>&5
5649   ac_status=$?
5650   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5651   (exit $ac_status); }; then
5652     case `/usr/bin/file conftest.$ac_objext` in
5653     *ELF-32*)
5654       HPUX_IA64_MODE="32"
5655       ;;
5656     *ELF-64*)
5657       HPUX_IA64_MODE="64"
5658       ;;
5659     esac
5660   fi
5661   rm -rf conftest*
5662   ;;
5663 *-*-irix6*)
5664   # Find out which ABI we are using.
5665   echo '#line 5665 "configure"' > conftest.$ac_ext
5666   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5667   (eval $ac_compile) 2>&5
5668   ac_status=$?
5669   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5670   (exit $ac_status); }; then
5671    if test "$lt_cv_prog_gnu_ld" = yes; then
5672     case `/usr/bin/file conftest.$ac_objext` in
5673     *32-bit*)
5674       LD="${LD-ld} -melf32bsmip"
5675       ;;
5676     *N32*)
5677       LD="${LD-ld} -melf32bmipn32"
5678       ;;
5679     *64-bit*)
5680       LD="${LD-ld} -melf64bmip"
5681       ;;
5682     esac
5683    else
5684     case `/usr/bin/file conftest.$ac_objext` in
5685     *32-bit*)
5686       LD="${LD-ld} -32"
5687       ;;
5688     *N32*)
5689       LD="${LD-ld} -n32"
5690       ;;
5691     *64-bit*)
5692       LD="${LD-ld} -64"
5693       ;;
5694     esac
5695    fi
5696   fi
5697   rm -rf conftest*
5698   ;;
5699
5700 x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
5701   # Find out which ABI we are using.
5702   echo 'int i;' > conftest.$ac_ext
5703   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5704   (eval $ac_compile) 2>&5
5705   ac_status=$?
5706   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5707   (exit $ac_status); }; then
5708     case `/usr/bin/file conftest.o` in
5709     *32-bit*)
5710       case $host in
5711         x86_64-*linux*)
5712           LD="${LD-ld} -m elf_i386"
5713           ;;
5714         ppc64-*linux*|powerpc64-*linux*)
5715           LD="${LD-ld} -m elf32ppclinux"
5716           ;;
5717         s390x-*linux*)
5718           LD="${LD-ld} -m elf_s390"
5719           ;;
5720         sparc64-*linux*)
5721           LD="${LD-ld} -m elf32_sparc"
5722           ;;
5723       esac
5724       ;;
5725     *64-bit*)
5726       case $host in
5727         x86_64-*linux*)
5728           LD="${LD-ld} -m elf_x86_64"
5729           ;;
5730         ppc*-*linux*|powerpc*-*linux*)
5731           LD="${LD-ld} -m elf64ppc"
5732           ;;
5733         s390*-*linux*)
5734           LD="${LD-ld} -m elf64_s390"
5735           ;;
5736         sparc*-*linux*)
5737           LD="${LD-ld} -m elf64_sparc"
5738           ;;
5739       esac
5740       ;;
5741     esac
5742   fi
5743   rm -rf conftest*
5744   ;;
5745
5746 *-*-sco3.2v5*)
5747   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
5748   SAVE_CFLAGS="$CFLAGS"
5749   CFLAGS="$CFLAGS -belf"
5750   echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5
5751 echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6
5752 if test "${lt_cv_cc_needs_belf+set}" = set; then
5753   echo $ECHO_N "(cached) $ECHO_C" >&6
5754 else
5755   ac_ext=c
5756 ac_cpp='$CPP $CPPFLAGS'
5757 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5758 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5759 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5760
5761      cat >conftest.$ac_ext <<_ACEOF
5762 /* confdefs.h.  */
5763 _ACEOF
5764 cat confdefs.h >>conftest.$ac_ext
5765 cat >>conftest.$ac_ext <<_ACEOF
5766 /* end confdefs.h.  */
5767
5768 int
5769 main ()
5770 {
5771
5772   ;
5773   return 0;
5774 }
5775 _ACEOF
5776 rm -f conftest.$ac_objext conftest$ac_exeext
5777 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5778   (eval $ac_link) 2>conftest.er1
5779   ac_status=$?
5780   grep -v '^ *+' conftest.er1 >conftest.err
5781   rm -f conftest.er1
5782   cat conftest.err >&5
5783   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5784   (exit $ac_status); } &&
5785          { ac_try='test -z "$ac_c_werror_flag"
5786                          || test ! -s conftest.err'
5787   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5788   (eval $ac_try) 2>&5
5789   ac_status=$?
5790   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5791   (exit $ac_status); }; } &&
5792          { ac_try='test -s conftest$ac_exeext'
5793   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5794   (eval $ac_try) 2>&5
5795   ac_status=$?
5796   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5797   (exit $ac_status); }; }; then
5798   lt_cv_cc_needs_belf=yes
5799 else
5800   echo "$as_me: failed program was:" >&5
5801 sed 's/^/| /' conftest.$ac_ext >&5
5802
5803 lt_cv_cc_needs_belf=no
5804 fi
5805 rm -f conftest.err conftest.$ac_objext \
5806       conftest$ac_exeext conftest.$ac_ext
5807      ac_ext=c
5808 ac_cpp='$CPP $CPPFLAGS'
5809 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5810 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5811 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5812
5813 fi
5814 echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5
5815 echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6
5816   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
5817     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
5818     CFLAGS="$SAVE_CFLAGS"
5819   fi
5820   ;;
5821 *-*-cygwin* | *-*-mingw* | *-*-pw32*)
5822   if test -n "$ac_tool_prefix"; then
5823   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
5824 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
5825 echo "$as_me:$LINENO: checking for $ac_word" >&5
5826 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5827 if test "${ac_cv_prog_DLLTOOL+set}" = set; then
5828   echo $ECHO_N "(cached) $ECHO_C" >&6
5829 else
5830   if test -n "$DLLTOOL"; then
5831   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
5832 else
5833 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5834 for as_dir in $PATH
5835 do
5836   IFS=$as_save_IFS
5837   test -z "$as_dir" && as_dir=.
5838   for ac_exec_ext in '' $ac_executable_extensions; do
5839   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5840     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
5841     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5842     break 2
5843   fi
5844 done
5845 done
5846
5847 fi
5848 fi
5849 DLLTOOL=$ac_cv_prog_DLLTOOL
5850 if test -n "$DLLTOOL"; then
5851   echo "$as_me:$LINENO: result: $DLLTOOL" >&5
5852 echo "${ECHO_T}$DLLTOOL" >&6
5853 else
5854   echo "$as_me:$LINENO: result: no" >&5
5855 echo "${ECHO_T}no" >&6
5856 fi
5857
5858 fi
5859 if test -z "$ac_cv_prog_DLLTOOL"; then
5860   ac_ct_DLLTOOL=$DLLTOOL
5861   # Extract the first word of "dlltool", so it can be a program name with args.
5862 set dummy dlltool; ac_word=$2
5863 echo "$as_me:$LINENO: checking for $ac_word" >&5
5864 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5865 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
5866   echo $ECHO_N "(cached) $ECHO_C" >&6
5867 else
5868   if test -n "$ac_ct_DLLTOOL"; then
5869   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
5870 else
5871 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5872 for as_dir in $PATH
5873 do
5874   IFS=$as_save_IFS
5875   test -z "$as_dir" && as_dir=.
5876   for ac_exec_ext in '' $ac_executable_extensions; do
5877   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5878     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
5879     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5880     break 2
5881   fi
5882 done
5883 done
5884
5885   test -z "$ac_cv_prog_ac_ct_DLLTOOL" && ac_cv_prog_ac_ct_DLLTOOL="false"
5886 fi
5887 fi
5888 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
5889 if test -n "$ac_ct_DLLTOOL"; then
5890   echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
5891 echo "${ECHO_T}$ac_ct_DLLTOOL" >&6
5892 else
5893   echo "$as_me:$LINENO: result: no" >&5
5894 echo "${ECHO_T}no" >&6
5895 fi
5896
5897   DLLTOOL=$ac_ct_DLLTOOL
5898 else
5899   DLLTOOL="$ac_cv_prog_DLLTOOL"
5900 fi
5901
5902   if test -n "$ac_tool_prefix"; then
5903   # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
5904 set dummy ${ac_tool_prefix}as; ac_word=$2
5905 echo "$as_me:$LINENO: checking for $ac_word" >&5
5906 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5907 if test "${ac_cv_prog_AS+set}" = set; then
5908   echo $ECHO_N "(cached) $ECHO_C" >&6
5909 else
5910   if test -n "$AS"; then
5911   ac_cv_prog_AS="$AS" # Let the user override the test.
5912 else
5913 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5914 for as_dir in $PATH
5915 do
5916   IFS=$as_save_IFS
5917   test -z "$as_dir" && as_dir=.
5918   for ac_exec_ext in '' $ac_executable_extensions; do
5919   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5920     ac_cv_prog_AS="${ac_tool_prefix}as"
5921     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5922     break 2
5923   fi
5924 done
5925 done
5926
5927 fi
5928 fi
5929 AS=$ac_cv_prog_AS
5930 if test -n "$AS"; then
5931   echo "$as_me:$LINENO: result: $AS" >&5
5932 echo "${ECHO_T}$AS" >&6
5933 else
5934   echo "$as_me:$LINENO: result: no" >&5
5935 echo "${ECHO_T}no" >&6
5936 fi
5937
5938 fi
5939 if test -z "$ac_cv_prog_AS"; then
5940   ac_ct_AS=$AS
5941   # Extract the first word of "as", so it can be a program name with args.
5942 set dummy as; ac_word=$2
5943 echo "$as_me:$LINENO: checking for $ac_word" >&5
5944 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5945 if test "${ac_cv_prog_ac_ct_AS+set}" = set; then
5946   echo $ECHO_N "(cached) $ECHO_C" >&6
5947 else
5948   if test -n "$ac_ct_AS"; then
5949   ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test.
5950 else
5951 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5952 for as_dir in $PATH
5953 do
5954   IFS=$as_save_IFS
5955   test -z "$as_dir" && as_dir=.
5956   for ac_exec_ext in '' $ac_executable_extensions; do
5957   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5958     ac_cv_prog_ac_ct_AS="as"
5959     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5960     break 2
5961   fi
5962 done
5963 done
5964
5965   test -z "$ac_cv_prog_ac_ct_AS" && ac_cv_prog_ac_ct_AS="false"
5966 fi
5967 fi
5968 ac_ct_AS=$ac_cv_prog_ac_ct_AS
5969 if test -n "$ac_ct_AS"; then
5970   echo "$as_me:$LINENO: result: $ac_ct_AS" >&5
5971 echo "${ECHO_T}$ac_ct_AS" >&6
5972 else
5973   echo "$as_me:$LINENO: result: no" >&5
5974 echo "${ECHO_T}no" >&6
5975 fi
5976
5977   AS=$ac_ct_AS
5978 else
5979   AS="$ac_cv_prog_AS"
5980 fi
5981
5982   if test -n "$ac_tool_prefix"; then
5983   # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
5984 set dummy ${ac_tool_prefix}objdump; ac_word=$2
5985 echo "$as_me:$LINENO: checking for $ac_word" >&5
5986 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5987 if test "${ac_cv_prog_OBJDUMP+set}" = set; then
5988   echo $ECHO_N "(cached) $ECHO_C" >&6
5989 else
5990   if test -n "$OBJDUMP"; then
5991   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
5992 else
5993 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5994 for as_dir in $PATH
5995 do
5996   IFS=$as_save_IFS
5997   test -z "$as_dir" && as_dir=.
5998   for ac_exec_ext in '' $ac_executable_extensions; do
5999   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6000     ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
6001     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6002     break 2
6003   fi
6004 done
6005 done
6006
6007 fi
6008 fi
6009 OBJDUMP=$ac_cv_prog_OBJDUMP
6010 if test -n "$OBJDUMP"; then
6011   echo "$as_me:$LINENO: result: $OBJDUMP" >&5
6012 echo "${ECHO_T}$OBJDUMP" >&6
6013 else
6014   echo "$as_me:$LINENO: result: no" >&5
6015 echo "${ECHO_T}no" >&6
6016 fi
6017
6018 fi
6019 if test -z "$ac_cv_prog_OBJDUMP"; then
6020   ac_ct_OBJDUMP=$OBJDUMP
6021   # Extract the first word of "objdump", so it can be a program name with args.
6022 set dummy objdump; ac_word=$2
6023 echo "$as_me:$LINENO: checking for $ac_word" >&5
6024 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6025 if test "${ac_cv_prog_ac_ct_OBJDUMP+set}" = set; then
6026   echo $ECHO_N "(cached) $ECHO_C" >&6
6027 else
6028   if test -n "$ac_ct_OBJDUMP"; then
6029   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
6030 else
6031 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6032 for as_dir in $PATH
6033 do
6034   IFS=$as_save_IFS
6035   test -z "$as_dir" && as_dir=.
6036   for ac_exec_ext in '' $ac_executable_extensions; do
6037   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6038     ac_cv_prog_ac_ct_OBJDUMP="objdump"
6039     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6040     break 2
6041   fi
6042 done
6043 done
6044
6045   test -z "$ac_cv_prog_ac_ct_OBJDUMP" && ac_cv_prog_ac_ct_OBJDUMP="false"
6046 fi
6047 fi
6048 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
6049 if test -n "$ac_ct_OBJDUMP"; then
6050   echo "$as_me:$LINENO: result: $ac_ct_OBJDUMP" >&5
6051 echo "${ECHO_T}$ac_ct_OBJDUMP" >&6
6052 else
6053   echo "$as_me:$LINENO: result: no" >&5
6054 echo "${ECHO_T}no" >&6
6055 fi
6056
6057   OBJDUMP=$ac_ct_OBJDUMP
6058 else
6059   OBJDUMP="$ac_cv_prog_OBJDUMP"
6060 fi
6061
6062   ;;
6063
6064 esac
6065
6066 need_locks="$enable_libtool_lock"
6067
6068
6069 ac_ext=c
6070 ac_cpp='$CPP $CPPFLAGS'
6071 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6072 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6073 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6074 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
6075 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
6076 # On Suns, sometimes $CPP names a directory.
6077 if test -n "$CPP" && test -d "$CPP"; then
6078   CPP=
6079 fi
6080 if test -z "$CPP"; then
6081   if test "${ac_cv_prog_CPP+set}" = set; then
6082   echo $ECHO_N "(cached) $ECHO_C" >&6
6083 else
6084       # Double quotes because CPP needs to be expanded
6085     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6086     do
6087       ac_preproc_ok=false
6088 for ac_c_preproc_warn_flag in '' yes
6089 do
6090   # Use a header file that comes with gcc, so configuring glibc
6091   # with a fresh cross-compiler works.
6092   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6093   # <limits.h> exists even on freestanding compilers.
6094   # On the NeXT, cc -E runs the code through the compiler's parser,
6095   # not just through cpp. "Syntax error" is here to catch this case.
6096   cat >conftest.$ac_ext <<_ACEOF
6097 /* confdefs.h.  */
6098 _ACEOF
6099 cat confdefs.h >>conftest.$ac_ext
6100 cat >>conftest.$ac_ext <<_ACEOF
6101 /* end confdefs.h.  */
6102 #ifdef __STDC__
6103 # include <limits.h>
6104 #else
6105 # include <assert.h>
6106 #endif
6107                      Syntax error
6108 _ACEOF
6109 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6110   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6111   ac_status=$?
6112   grep -v '^ *+' conftest.er1 >conftest.err
6113   rm -f conftest.er1
6114   cat conftest.err >&5
6115   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6116   (exit $ac_status); } >/dev/null; then
6117   if test -s conftest.err; then
6118     ac_cpp_err=$ac_c_preproc_warn_flag
6119     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6120   else
6121     ac_cpp_err=
6122   fi
6123 else
6124   ac_cpp_err=yes
6125 fi
6126 if test -z "$ac_cpp_err"; then
6127   :
6128 else
6129   echo "$as_me: failed program was:" >&5
6130 sed 's/^/| /' conftest.$ac_ext >&5
6131
6132   # Broken: fails on valid input.
6133 continue
6134 fi
6135 rm -f conftest.err conftest.$ac_ext
6136
6137   # OK, works on sane cases.  Now check whether non-existent headers
6138   # can be detected and how.
6139   cat >conftest.$ac_ext <<_ACEOF
6140 /* confdefs.h.  */
6141 _ACEOF
6142 cat confdefs.h >>conftest.$ac_ext
6143 cat >>conftest.$ac_ext <<_ACEOF
6144 /* end confdefs.h.  */
6145 #include <ac_nonexistent.h>
6146 _ACEOF
6147 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6148   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6149   ac_status=$?
6150   grep -v '^ *+' conftest.er1 >conftest.err
6151   rm -f conftest.er1
6152   cat conftest.err >&5
6153   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6154   (exit $ac_status); } >/dev/null; then
6155   if test -s conftest.err; then
6156     ac_cpp_err=$ac_c_preproc_warn_flag
6157     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6158   else
6159     ac_cpp_err=
6160   fi
6161 else
6162   ac_cpp_err=yes
6163 fi
6164 if test -z "$ac_cpp_err"; then
6165   # Broken: success on invalid input.
6166 continue
6167 else
6168   echo "$as_me: failed program was:" >&5
6169 sed 's/^/| /' conftest.$ac_ext >&5
6170
6171   # Passes both tests.
6172 ac_preproc_ok=:
6173 break
6174 fi
6175 rm -f conftest.err conftest.$ac_ext
6176
6177 done
6178 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6179 rm -f conftest.err conftest.$ac_ext
6180 if $ac_preproc_ok; then
6181   break
6182 fi
6183
6184     done
6185     ac_cv_prog_CPP=$CPP
6186
6187 fi
6188   CPP=$ac_cv_prog_CPP
6189 else
6190   ac_cv_prog_CPP=$CPP
6191 fi
6192 echo "$as_me:$LINENO: result: $CPP" >&5
6193 echo "${ECHO_T}$CPP" >&6
6194 ac_preproc_ok=false
6195 for ac_c_preproc_warn_flag in '' yes
6196 do
6197   # Use a header file that comes with gcc, so configuring glibc
6198   # with a fresh cross-compiler works.
6199   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6200   # <limits.h> exists even on freestanding compilers.
6201   # On the NeXT, cc -E runs the code through the compiler's parser,
6202   # not just through cpp. "Syntax error" is here to catch this case.
6203   cat >conftest.$ac_ext <<_ACEOF
6204 /* confdefs.h.  */
6205 _ACEOF
6206 cat confdefs.h >>conftest.$ac_ext
6207 cat >>conftest.$ac_ext <<_ACEOF
6208 /* end confdefs.h.  */
6209 #ifdef __STDC__
6210 # include <limits.h>
6211 #else
6212 # include <assert.h>
6213 #endif
6214                      Syntax error
6215 _ACEOF
6216 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6217   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6218   ac_status=$?
6219   grep -v '^ *+' conftest.er1 >conftest.err
6220   rm -f conftest.er1
6221   cat conftest.err >&5
6222   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6223   (exit $ac_status); } >/dev/null; then
6224   if test -s conftest.err; then
6225     ac_cpp_err=$ac_c_preproc_warn_flag
6226     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6227   else
6228     ac_cpp_err=
6229   fi
6230 else
6231   ac_cpp_err=yes
6232 fi
6233 if test -z "$ac_cpp_err"; then
6234   :
6235 else
6236   echo "$as_me: failed program was:" >&5
6237 sed 's/^/| /' conftest.$ac_ext >&5
6238
6239   # Broken: fails on valid input.
6240 continue
6241 fi
6242 rm -f conftest.err conftest.$ac_ext
6243
6244   # OK, works on sane cases.  Now check whether non-existent headers
6245   # can be detected and how.
6246   cat >conftest.$ac_ext <<_ACEOF
6247 /* confdefs.h.  */
6248 _ACEOF
6249 cat confdefs.h >>conftest.$ac_ext
6250 cat >>conftest.$ac_ext <<_ACEOF
6251 /* end confdefs.h.  */
6252 #include <ac_nonexistent.h>
6253 _ACEOF
6254 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6255   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6256   ac_status=$?
6257   grep -v '^ *+' conftest.er1 >conftest.err
6258   rm -f conftest.er1
6259   cat conftest.err >&5
6260   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6261   (exit $ac_status); } >/dev/null; then
6262   if test -s conftest.err; then
6263     ac_cpp_err=$ac_c_preproc_warn_flag
6264     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6265   else
6266     ac_cpp_err=
6267   fi
6268 else
6269   ac_cpp_err=yes
6270 fi
6271 if test -z "$ac_cpp_err"; then
6272   # Broken: success on invalid input.
6273 continue
6274 else
6275   echo "$as_me: failed program was:" >&5
6276 sed 's/^/| /' conftest.$ac_ext >&5
6277
6278   # Passes both tests.
6279 ac_preproc_ok=:
6280 break
6281 fi
6282 rm -f conftest.err conftest.$ac_ext
6283
6284 done
6285 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6286 rm -f conftest.err conftest.$ac_ext
6287 if $ac_preproc_ok; then
6288   :
6289 else
6290   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
6291 See \`config.log' for more details." >&5
6292 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
6293 See \`config.log' for more details." >&2;}
6294    { (exit 1); exit 1; }; }
6295 fi
6296
6297 ac_ext=c
6298 ac_cpp='$CPP $CPPFLAGS'
6299 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6300 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6301 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6302
6303
6304 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
6305 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
6306 if test "${ac_cv_header_stdc+set}" = set; then
6307   echo $ECHO_N "(cached) $ECHO_C" >&6
6308 else
6309   cat >conftest.$ac_ext <<_ACEOF
6310 /* confdefs.h.  */
6311 _ACEOF
6312 cat confdefs.h >>conftest.$ac_ext
6313 cat >>conftest.$ac_ext <<_ACEOF
6314 /* end confdefs.h.  */
6315 #include <stdlib.h>
6316 #include <stdarg.h>
6317 #include <string.h>
6318 #include <float.h>
6319
6320 int
6321 main ()
6322 {
6323
6324   ;
6325   return 0;
6326 }
6327 _ACEOF
6328 rm -f conftest.$ac_objext
6329 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6330   (eval $ac_compile) 2>conftest.er1
6331   ac_status=$?
6332   grep -v '^ *+' conftest.er1 >conftest.err
6333   rm -f conftest.er1
6334   cat conftest.err >&5
6335   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6336   (exit $ac_status); } &&
6337          { ac_try='test -z "$ac_c_werror_flag"
6338                          || test ! -s conftest.err'
6339   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6340   (eval $ac_try) 2>&5
6341   ac_status=$?
6342   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6343   (exit $ac_status); }; } &&
6344          { ac_try='test -s conftest.$ac_objext'
6345   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6346   (eval $ac_try) 2>&5
6347   ac_status=$?
6348   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6349   (exit $ac_status); }; }; then
6350   ac_cv_header_stdc=yes
6351 else
6352   echo "$as_me: failed program was:" >&5
6353 sed 's/^/| /' conftest.$ac_ext >&5
6354
6355 ac_cv_header_stdc=no
6356 fi
6357 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6358
6359 if test $ac_cv_header_stdc = yes; then
6360   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6361   cat >conftest.$ac_ext <<_ACEOF
6362 /* confdefs.h.  */
6363 _ACEOF
6364 cat confdefs.h >>conftest.$ac_ext
6365 cat >>conftest.$ac_ext <<_ACEOF
6366 /* end confdefs.h.  */
6367 #include <string.h>
6368
6369 _ACEOF
6370 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6371   $EGREP "memchr" >/dev/null 2>&1; then
6372   :
6373 else
6374   ac_cv_header_stdc=no
6375 fi
6376 rm -f conftest*
6377
6378 fi
6379
6380 if test $ac_cv_header_stdc = yes; then
6381   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6382   cat >conftest.$ac_ext <<_ACEOF
6383 /* confdefs.h.  */
6384 _ACEOF
6385 cat confdefs.h >>conftest.$ac_ext
6386 cat >>conftest.$ac_ext <<_ACEOF
6387 /* end confdefs.h.  */
6388 #include <stdlib.h>
6389
6390 _ACEOF
6391 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6392   $EGREP "free" >/dev/null 2>&1; then
6393   :
6394 else
6395   ac_cv_header_stdc=no
6396 fi
6397 rm -f conftest*
6398
6399 fi
6400
6401 if test $ac_cv_header_stdc = yes; then
6402   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6403   if test "$cross_compiling" = yes; then
6404   :
6405 else
6406   cat >conftest.$ac_ext <<_ACEOF
6407 /* confdefs.h.  */
6408 _ACEOF
6409 cat confdefs.h >>conftest.$ac_ext
6410 cat >>conftest.$ac_ext <<_ACEOF
6411 /* end confdefs.h.  */
6412 #include <ctype.h>
6413 #if ((' ' & 0x0FF) == 0x020)
6414 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6415 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6416 #else
6417 # define ISLOWER(c) \
6418                    (('a' <= (c) && (c) <= 'i') \
6419                      || ('j' <= (c) && (c) <= 'r') \
6420                      || ('s' <= (c) && (c) <= 'z'))
6421 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6422 #endif
6423
6424 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6425 int
6426 main ()
6427 {
6428   int i;
6429   for (i = 0; i < 256; i++)
6430     if (XOR (islower (i), ISLOWER (i))
6431         || toupper (i) != TOUPPER (i))
6432       exit(2);
6433   exit (0);
6434 }
6435 _ACEOF
6436 rm -f conftest$ac_exeext
6437 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6438   (eval $ac_link) 2>&5
6439   ac_status=$?
6440   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6441   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6442   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6443   (eval $ac_try) 2>&5
6444   ac_status=$?
6445   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6446   (exit $ac_status); }; }; then
6447   :
6448 else
6449   echo "$as_me: program exited with status $ac_status" >&5
6450 echo "$as_me: failed program was:" >&5
6451 sed 's/^/| /' conftest.$ac_ext >&5
6452
6453 ( exit $ac_status )
6454 ac_cv_header_stdc=no
6455 fi
6456 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6457 fi
6458 fi
6459 fi
6460 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
6461 echo "${ECHO_T}$ac_cv_header_stdc" >&6
6462 if test $ac_cv_header_stdc = yes; then
6463
6464 cat >>confdefs.h <<\_ACEOF
6465 #define STDC_HEADERS 1
6466 _ACEOF
6467
6468 fi
6469
6470 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6471
6472
6473
6474
6475
6476
6477
6478
6479
6480 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6481                   inttypes.h stdint.h unistd.h
6482 do
6483 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6484 echo "$as_me:$LINENO: checking for $ac_header" >&5
6485 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6486 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6487   echo $ECHO_N "(cached) $ECHO_C" >&6
6488 else
6489   cat >conftest.$ac_ext <<_ACEOF
6490 /* confdefs.h.  */
6491 _ACEOF
6492 cat confdefs.h >>conftest.$ac_ext
6493 cat >>conftest.$ac_ext <<_ACEOF
6494 /* end confdefs.h.  */
6495 $ac_includes_default
6496
6497 #include <$ac_header>
6498 _ACEOF
6499 rm -f conftest.$ac_objext
6500 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6501   (eval $ac_compile) 2>conftest.er1
6502   ac_status=$?
6503   grep -v '^ *+' conftest.er1 >conftest.err
6504   rm -f conftest.er1
6505   cat conftest.err >&5
6506   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6507   (exit $ac_status); } &&
6508          { ac_try='test -z "$ac_c_werror_flag"
6509                          || test ! -s conftest.err'
6510   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6511   (eval $ac_try) 2>&5
6512   ac_status=$?
6513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6514   (exit $ac_status); }; } &&
6515          { ac_try='test -s conftest.$ac_objext'
6516   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6517   (eval $ac_try) 2>&5
6518   ac_status=$?
6519   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6520   (exit $ac_status); }; }; then
6521   eval "$as_ac_Header=yes"
6522 else
6523   echo "$as_me: failed program was:" >&5
6524 sed 's/^/| /' conftest.$ac_ext >&5
6525
6526 eval "$as_ac_Header=no"
6527 fi
6528 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6529 fi
6530 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6531 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6532 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6533   cat >>confdefs.h <<_ACEOF
6534 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6535 _ACEOF
6536
6537 fi
6538
6539 done
6540
6541
6542
6543 for ac_header in dlfcn.h
6544 do
6545 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6546 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6547   echo "$as_me:$LINENO: checking for $ac_header" >&5
6548 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6549 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6550   echo $ECHO_N "(cached) $ECHO_C" >&6
6551 fi
6552 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6553 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6554 else
6555   # Is the header compilable?
6556 echo "$as_me:$LINENO: checking $ac_header usability" >&5
6557 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
6558 cat >conftest.$ac_ext <<_ACEOF
6559 /* confdefs.h.  */
6560 _ACEOF
6561 cat confdefs.h >>conftest.$ac_ext
6562 cat >>conftest.$ac_ext <<_ACEOF
6563 /* end confdefs.h.  */
6564 $ac_includes_default
6565 #include <$ac_header>
6566 _ACEOF
6567 rm -f conftest.$ac_objext
6568 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6569   (eval $ac_compile) 2>conftest.er1
6570   ac_status=$?
6571   grep -v '^ *+' conftest.er1 >conftest.err
6572   rm -f conftest.er1
6573   cat conftest.err >&5
6574   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6575   (exit $ac_status); } &&
6576          { ac_try='test -z "$ac_c_werror_flag"
6577                          || test ! -s conftest.err'
6578   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6579   (eval $ac_try) 2>&5
6580   ac_status=$?
6581   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6582   (exit $ac_status); }; } &&
6583          { ac_try='test -s conftest.$ac_objext'
6584   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6585   (eval $ac_try) 2>&5
6586   ac_status=$?
6587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6588   (exit $ac_status); }; }; then
6589   ac_header_compiler=yes
6590 else
6591   echo "$as_me: failed program was:" >&5
6592 sed 's/^/| /' conftest.$ac_ext >&5
6593
6594 ac_header_compiler=no
6595 fi
6596 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6597 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6598 echo "${ECHO_T}$ac_header_compiler" >&6
6599
6600 # Is the header present?
6601 echo "$as_me:$LINENO: checking $ac_header presence" >&5
6602 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
6603 cat >conftest.$ac_ext <<_ACEOF
6604 /* confdefs.h.  */
6605 _ACEOF
6606 cat confdefs.h >>conftest.$ac_ext
6607 cat >>conftest.$ac_ext <<_ACEOF
6608 /* end confdefs.h.  */
6609 #include <$ac_header>
6610 _ACEOF
6611 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6612   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6613   ac_status=$?
6614   grep -v '^ *+' conftest.er1 >conftest.err
6615   rm -f conftest.er1
6616   cat conftest.err >&5
6617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6618   (exit $ac_status); } >/dev/null; then
6619   if test -s conftest.err; then
6620     ac_cpp_err=$ac_c_preproc_warn_flag
6621     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6622   else
6623     ac_cpp_err=
6624   fi
6625 else
6626   ac_cpp_err=yes
6627 fi
6628 if test -z "$ac_cpp_err"; then
6629   ac_header_preproc=yes
6630 else
6631   echo "$as_me: failed program was:" >&5
6632 sed 's/^/| /' conftest.$ac_ext >&5
6633
6634   ac_header_preproc=no
6635 fi
6636 rm -f conftest.err conftest.$ac_ext
6637 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6638 echo "${ECHO_T}$ac_header_preproc" >&6
6639
6640 # So?  What about this header?
6641 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6642   yes:no: )
6643     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6644 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
6645     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
6646 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
6647     ac_header_preproc=yes
6648     ;;
6649   no:yes:* )
6650     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6651 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
6652     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
6653 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
6654     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
6655 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
6656     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
6657 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
6658     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6659 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
6660     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
6661 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
6662     (
6663       cat <<\_ASBOX
6664 ## --------------------------------------------- ##
6665 ## Report this to <http://www.openldap.org/its/> ##
6666 ## --------------------------------------------- ##
6667 _ASBOX
6668     ) |
6669       sed "s/^/$as_me: WARNING:     /" >&2
6670     ;;
6671 esac
6672 echo "$as_me:$LINENO: checking for $ac_header" >&5
6673 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6674 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6675   echo $ECHO_N "(cached) $ECHO_C" >&6
6676 else
6677   eval "$as_ac_Header=\$ac_header_preproc"
6678 fi
6679 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6680 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6681
6682 fi
6683 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6684   cat >>confdefs.h <<_ACEOF
6685 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6686 _ACEOF
6687
6688 fi
6689
6690 done
6691
6692
6693 # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
6694
6695 # find the maximum length of command line arguments
6696 echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5
6697 echo $ECHO_N "checking the maximum length of command line arguments... $ECHO_C" >&6
6698 if test "${lt_cv_sys_max_cmd_len+set}" = set; then
6699   echo $ECHO_N "(cached) $ECHO_C" >&6
6700 else
6701     i=0
6702   teststring="ABCD"
6703
6704   case $build_os in
6705   msdosdjgpp*)
6706     # On DJGPP, this test can blow up pretty badly due to problems in libc
6707     # (any single argument exceeding 2000 bytes causes a buffer overrun
6708     # during glob expansion).  Even if it were fixed, the result of this
6709     # check would be larger than it should be.
6710     lt_cv_sys_max_cmd_len=12288;    # 12K is about right
6711     ;;
6712
6713   gnu*)
6714     # Under GNU Hurd, this test is not required because there is
6715     # no limit to the length of command line arguments.
6716     # Libtool will interpret -1 as no limit whatsoever
6717     lt_cv_sys_max_cmd_len=-1;
6718     ;;
6719
6720   cygwin* | mingw*)
6721     # On Win9x/ME, this test blows up -- it succeeds, but takes
6722     # about 5 minutes as the teststring grows exponentially.
6723     # Worse, since 9x/ME are not pre-emptively multitasking,
6724     # you end up with a "frozen" computer, even though with patience
6725     # the test eventually succeeds (with a max line length of 256k).
6726     # Instead, let's just punt: use the minimum linelength reported by
6727     # all of the supported platforms: 8192 (on NT/2K/XP).
6728     lt_cv_sys_max_cmd_len=8192;
6729     ;;
6730
6731   amigaos*)
6732     # On AmigaOS with pdksh, this test takes hours, literally.
6733     # So we just punt and use a minimum line length of 8192.
6734     lt_cv_sys_max_cmd_len=8192;
6735     ;;
6736
6737   netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
6738     # This has been around since 386BSD, at least.  Likely further.
6739     if test -x /sbin/sysctl; then
6740       lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
6741     elif test -x /usr/sbin/sysctl; then
6742       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
6743     else
6744       lt_cv_sys_max_cmd_len=65536       # usable default for all BSDs
6745     fi
6746     # And add a safety zone
6747     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
6748     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
6749     ;;
6750   osf*)
6751     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
6752     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
6753     # nice to cause kernel panics so lets avoid the loop below.
6754     # First set a reasonable default.
6755     lt_cv_sys_max_cmd_len=16384
6756     #
6757     if test -x /sbin/sysconfig; then
6758       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
6759         *1*) lt_cv_sys_max_cmd_len=-1 ;;
6760       esac
6761     fi
6762     ;;
6763   *)
6764     # If test is not a shell built-in, we'll probably end up computing a
6765     # maximum length that is only half of the actual maximum length, but
6766     # we can't tell.
6767     SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
6768     while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \
6769                = "XX$teststring") >/dev/null 2>&1 &&
6770             new_result=`expr "X$teststring" : ".*" 2>&1` &&
6771             lt_cv_sys_max_cmd_len=$new_result &&
6772             test $i != 17 # 1/2 MB should be enough
6773     do
6774       i=`expr $i + 1`
6775       teststring=$teststring$teststring
6776     done
6777     teststring=
6778     # Add a significant safety factor because C++ compilers can tack on massive
6779     # amounts of additional arguments before passing them to the linker.
6780     # It appears as though 1/2 is a usable value.
6781     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
6782     ;;
6783   esac
6784
6785 fi
6786
6787 if test -n $lt_cv_sys_max_cmd_len ; then
6788   echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5
6789 echo "${ECHO_T}$lt_cv_sys_max_cmd_len" >&6
6790 else
6791   echo "$as_me:$LINENO: result: none" >&5
6792 echo "${ECHO_T}none" >&6
6793 fi
6794
6795
6796
6797
6798 # Check for command to grab the raw symbol name followed by C symbol from nm.
6799 echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5
6800 echo $ECHO_N "checking command to parse $NM output from $compiler object... $ECHO_C" >&6
6801 if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then
6802   echo $ECHO_N "(cached) $ECHO_C" >&6
6803 else
6804
6805 # These are sane defaults that work on at least a few old systems.
6806 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
6807
6808 # Character class describing NM global symbol codes.
6809 symcode='[BCDEGRST]'
6810
6811 # Regexp to match symbols that can be accessed directly from C.
6812 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
6813
6814 # Transform an extracted symbol line into a proper C declaration
6815 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
6816
6817 # Transform an extracted symbol line into symbol name and symbol address
6818 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([^ ]*\) \([^ ]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
6819
6820 # Define system-specific variables.
6821 case $host_os in
6822 aix*)
6823   symcode='[BCDT]'
6824   ;;
6825 cygwin* | mingw* | pw32*)
6826   symcode='[ABCDGISTW]'
6827   ;;
6828 hpux*) # Its linker distinguishes data from code symbols
6829   if test "$host_cpu" = ia64; then
6830     symcode='[ABCDEGRST]'
6831   fi
6832   lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
6833   lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
6834   ;;
6835 linux*)
6836   if test "$host_cpu" = ia64; then
6837     symcode='[ABCDGIRSTW]'
6838     lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
6839     lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
6840   fi
6841   ;;
6842 irix* | nonstopux*)
6843   symcode='[BCDEGRST]'
6844   ;;
6845 osf*)
6846   symcode='[BCDEGQRST]'
6847   ;;
6848 solaris* | sysv5*)
6849   symcode='[BDRT]'
6850   ;;
6851 sysv4)
6852   symcode='[DFNSTU]'
6853   ;;
6854 esac
6855
6856 # Handle CRLF in mingw tool chain
6857 opt_cr=
6858 case $build_os in
6859 mingw*)
6860   opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
6861   ;;
6862 esac
6863
6864 # If we're using GNU nm, then use its standard symbol codes.
6865 case `$NM -V 2>&1` in
6866 *GNU* | *'with BFD'*)
6867   symcode='[ABCDGIRSTW]' ;;
6868 esac
6869
6870 # Try without a prefix undercore, then with it.
6871 for ac_symprfx in "" "_"; do
6872
6873   # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
6874   symxfrm="\\1 $ac_symprfx\\2 \\2"
6875
6876   # Write the raw and C identifiers.
6877   lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[       ]\($symcode$symcode*\)[         ][      ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
6878
6879   # Check to see that the pipe works correctly.
6880   pipe_works=no
6881
6882   rm -f conftest*
6883   cat > conftest.$ac_ext <<EOF
6884 #ifdef __cplusplus
6885 extern "C" {
6886 #endif
6887 char nm_test_var;
6888 void nm_test_func(){}
6889 #ifdef __cplusplus
6890 }
6891 #endif
6892 int main(){nm_test_var='a';nm_test_func();return(0);}
6893 EOF
6894
6895   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6896   (eval $ac_compile) 2>&5
6897   ac_status=$?
6898   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6899   (exit $ac_status); }; then
6900     # Now try to grab the symbols.
6901     nlist=conftest.nm
6902     if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5
6903   (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5
6904   ac_status=$?
6905   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6906   (exit $ac_status); } && test -s "$nlist"; then
6907       # Try sorting and uniquifying the output.
6908       if sort "$nlist" | uniq > "$nlist"T; then
6909         mv -f "$nlist"T "$nlist"
6910       else
6911         rm -f "$nlist"T
6912       fi
6913
6914       # Make sure that we snagged all the symbols we need.
6915       if grep ' nm_test_var$' "$nlist" >/dev/null; then
6916         if grep ' nm_test_func$' "$nlist" >/dev/null; then
6917           cat <<EOF > conftest.$ac_ext
6918 #ifdef __cplusplus
6919 extern "C" {
6920 #endif
6921
6922 EOF
6923           # Now generate the symbol file.
6924           eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
6925
6926           cat <<EOF >> conftest.$ac_ext
6927 #if defined (__STDC__) && __STDC__
6928 # define lt_ptr_t void *
6929 #else
6930 # define lt_ptr_t char *
6931 # define const
6932 #endif
6933
6934 /* The mapping between symbol names and symbols. */
6935 const struct {
6936   const char *name;
6937   lt_ptr_t address;
6938 }
6939 lt_preloaded_symbols[] =
6940 {
6941 EOF
6942           $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
6943           cat <<\EOF >> conftest.$ac_ext
6944   {0, (lt_ptr_t) 0}
6945 };
6946
6947 #ifdef __cplusplus
6948 }
6949 #endif
6950 EOF
6951           # Now try linking the two files.
6952           mv conftest.$ac_objext conftstm.$ac_objext
6953           lt_save_LIBS="$LIBS"
6954           lt_save_CFLAGS="$CFLAGS"
6955           LIBS="conftstm.$ac_objext"
6956           CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
6957           if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6958   (eval $ac_link) 2>&5
6959   ac_status=$?
6960   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6961   (exit $ac_status); } && test -s conftest${ac_exeext}; then
6962             pipe_works=yes
6963           fi
6964           LIBS="$lt_save_LIBS"
6965           CFLAGS="$lt_save_CFLAGS"
6966         else
6967           echo "cannot find nm_test_func in $nlist" >&5
6968         fi
6969       else
6970         echo "cannot find nm_test_var in $nlist" >&5
6971       fi
6972     else
6973       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
6974     fi
6975   else
6976     echo "$progname: failed program was:" >&5
6977     cat conftest.$ac_ext >&5
6978   fi
6979   rm -f conftest* conftst*
6980
6981   # Do not use the global_symbol_pipe unless it works.
6982   if test "$pipe_works" = yes; then
6983     break
6984   else
6985     lt_cv_sys_global_symbol_pipe=
6986   fi
6987 done
6988
6989 fi
6990
6991 if test -z "$lt_cv_sys_global_symbol_pipe"; then
6992   lt_cv_sys_global_symbol_to_cdecl=
6993 fi
6994 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
6995   echo "$as_me:$LINENO: result: failed" >&5
6996 echo "${ECHO_T}failed" >&6
6997 else
6998   echo "$as_me:$LINENO: result: ok" >&5
6999 echo "${ECHO_T}ok" >&6
7000 fi
7001
7002 echo "$as_me:$LINENO: checking for objdir" >&5
7003 echo $ECHO_N "checking for objdir... $ECHO_C" >&6
7004 if test "${lt_cv_objdir+set}" = set; then
7005   echo $ECHO_N "(cached) $ECHO_C" >&6
7006 else
7007   rm -f .libs 2>/dev/null
7008 mkdir .libs 2>/dev/null
7009 if test -d .libs; then
7010   lt_cv_objdir=.libs
7011 else
7012   # MS-DOS does not allow filenames that begin with a dot.
7013   lt_cv_objdir=_libs
7014 fi
7015 rmdir .libs 2>/dev/null
7016 fi
7017 echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5
7018 echo "${ECHO_T}$lt_cv_objdir" >&6
7019 objdir=$lt_cv_objdir
7020
7021
7022
7023
7024
7025 case $host_os in
7026 aix3*)
7027   # AIX sometimes has problems with the GCC collect2 program.  For some
7028   # reason, if we set the COLLECT_NAMES environment variable, the problems
7029   # vanish in a puff of smoke.
7030   if test "X${COLLECT_NAMES+set}" != Xset; then
7031     COLLECT_NAMES=
7032     export COLLECT_NAMES
7033   fi
7034   ;;
7035 esac
7036
7037 # Sed substitution that helps us do robust quoting.  It backslashifies
7038 # metacharacters that are still active within double-quoted strings.
7039 Xsed='sed -e 1s/^X//'
7040 sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'
7041
7042 # Same as above, but do not quote variable references.
7043 double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'
7044
7045 # Sed substitution to delay expansion of an escaped shell variable in a
7046 # double_quote_subst'ed string.
7047 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
7048
7049 # Sed substitution to avoid accidental globbing in evaled expressions
7050 no_glob_subst='s/\*/\\\*/g'
7051
7052 # Constants:
7053 rm="rm -f"
7054
7055 # Global variables:
7056 default_ofile=libtool
7057 can_build_shared=yes
7058
7059 # All known linkers require a `.a' archive for static linking (except MSVC,
7060 # which needs '.lib').
7061 libext=a
7062 ltmain="$ac_aux_dir/ltmain.sh"
7063 ofile="$default_ofile"
7064 with_gnu_ld="$lt_cv_prog_gnu_ld"
7065
7066 if test -n "$ac_tool_prefix"; then
7067   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
7068 set dummy ${ac_tool_prefix}ar; ac_word=$2
7069 echo "$as_me:$LINENO: checking for $ac_word" >&5
7070 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7071 if test "${ac_cv_prog_AR+set}" = set; then
7072   echo $ECHO_N "(cached) $ECHO_C" >&6
7073 else
7074   if test -n "$AR"; then
7075   ac_cv_prog_AR="$AR" # Let the user override the test.
7076 else
7077 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7078 for as_dir in $PATH
7079 do
7080   IFS=$as_save_IFS
7081   test -z "$as_dir" && as_dir=.
7082   for ac_exec_ext in '' $ac_executable_extensions; do
7083   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7084     ac_cv_prog_AR="${ac_tool_prefix}ar"
7085     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7086     break 2
7087   fi
7088 done
7089 done
7090
7091 fi
7092 fi
7093 AR=$ac_cv_prog_AR
7094 if test -n "$AR"; then
7095   echo "$as_me:$LINENO: result: $AR" >&5
7096 echo "${ECHO_T}$AR" >&6
7097 else
7098   echo "$as_me:$LINENO: result: no" >&5
7099 echo "${ECHO_T}no" >&6
7100 fi
7101
7102 fi
7103 if test -z "$ac_cv_prog_AR"; then
7104   ac_ct_AR=$AR
7105   # Extract the first word of "ar", so it can be a program name with args.
7106 set dummy ar; ac_word=$2
7107 echo "$as_me:$LINENO: checking for $ac_word" >&5
7108 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7109 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
7110   echo $ECHO_N "(cached) $ECHO_C" >&6
7111 else
7112   if test -n "$ac_ct_AR"; then
7113   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
7114 else
7115 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7116 for as_dir in $PATH
7117 do
7118   IFS=$as_save_IFS
7119   test -z "$as_dir" && as_dir=.
7120   for ac_exec_ext in '' $ac_executable_extensions; do
7121   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7122     ac_cv_prog_ac_ct_AR="ar"
7123     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7124     break 2
7125   fi
7126 done
7127 done
7128
7129   test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="false"
7130 fi
7131 fi
7132 ac_ct_AR=$ac_cv_prog_ac_ct_AR
7133 if test -n "$ac_ct_AR"; then
7134   echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
7135 echo "${ECHO_T}$ac_ct_AR" >&6
7136 else
7137   echo "$as_me:$LINENO: result: no" >&5
7138 echo "${ECHO_T}no" >&6
7139 fi
7140
7141   AR=$ac_ct_AR
7142 else
7143   AR="$ac_cv_prog_AR"
7144 fi
7145
7146 if test -n "$ac_tool_prefix"; then
7147   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
7148 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
7149 echo "$as_me:$LINENO: checking for $ac_word" >&5
7150 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7151 if test "${ac_cv_prog_RANLIB+set}" = set; then
7152   echo $ECHO_N "(cached) $ECHO_C" >&6
7153 else
7154   if test -n "$RANLIB"; then
7155   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
7156 else
7157 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7158 for as_dir in $PATH
7159 do
7160   IFS=$as_save_IFS
7161   test -z "$as_dir" && as_dir=.
7162   for ac_exec_ext in '' $ac_executable_extensions; do
7163   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7164     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
7165     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7166     break 2
7167   fi
7168 done
7169 done
7170
7171 fi
7172 fi
7173 RANLIB=$ac_cv_prog_RANLIB
7174 if test -n "$RANLIB"; then
7175   echo "$as_me:$LINENO: result: $RANLIB" >&5
7176 echo "${ECHO_T}$RANLIB" >&6
7177 else
7178   echo "$as_me:$LINENO: result: no" >&5
7179 echo "${ECHO_T}no" >&6
7180 fi
7181
7182 fi
7183 if test -z "$ac_cv_prog_RANLIB"; then
7184   ac_ct_RANLIB=$RANLIB
7185   # Extract the first word of "ranlib", so it can be a program name with args.
7186 set dummy ranlib; ac_word=$2
7187 echo "$as_me:$LINENO: checking for $ac_word" >&5
7188 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7189 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
7190   echo $ECHO_N "(cached) $ECHO_C" >&6
7191 else
7192   if test -n "$ac_ct_RANLIB"; then
7193   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
7194 else
7195 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7196 for as_dir in $PATH
7197 do
7198   IFS=$as_save_IFS
7199   test -z "$as_dir" && as_dir=.
7200   for ac_exec_ext in '' $ac_executable_extensions; do
7201   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7202     ac_cv_prog_ac_ct_RANLIB="ranlib"
7203     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7204     break 2
7205   fi
7206 done
7207 done
7208
7209   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
7210 fi
7211 fi
7212 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
7213 if test -n "$ac_ct_RANLIB"; then
7214   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
7215 echo "${ECHO_T}$ac_ct_RANLIB" >&6
7216 else
7217   echo "$as_me:$LINENO: result: no" >&5
7218 echo "${ECHO_T}no" >&6
7219 fi
7220
7221   RANLIB=$ac_ct_RANLIB
7222 else
7223   RANLIB="$ac_cv_prog_RANLIB"
7224 fi
7225
7226 if test -n "$ac_tool_prefix"; then
7227   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
7228 set dummy ${ac_tool_prefix}strip; ac_word=$2
7229 echo "$as_me:$LINENO: checking for $ac_word" >&5
7230 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7231 if test "${ac_cv_prog_STRIP+set}" = set; then
7232   echo $ECHO_N "(cached) $ECHO_C" >&6
7233 else
7234   if test -n "$STRIP"; then
7235   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
7236 else
7237 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7238 for as_dir in $PATH
7239 do
7240   IFS=$as_save_IFS
7241   test -z "$as_dir" && as_dir=.
7242   for ac_exec_ext in '' $ac_executable_extensions; do
7243   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7244     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
7245     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7246     break 2
7247   fi
7248 done
7249 done
7250
7251 fi
7252 fi
7253 STRIP=$ac_cv_prog_STRIP
7254 if test -n "$STRIP"; then
7255   echo "$as_me:$LINENO: result: $STRIP" >&5
7256 echo "${ECHO_T}$STRIP" >&6
7257 else
7258   echo "$as_me:$LINENO: result: no" >&5
7259 echo "${ECHO_T}no" >&6
7260 fi
7261
7262 fi
7263 if test -z "$ac_cv_prog_STRIP"; then
7264   ac_ct_STRIP=$STRIP
7265   # Extract the first word of "strip", so it can be a program name with args.
7266 set dummy strip; ac_word=$2
7267 echo "$as_me:$LINENO: checking for $ac_word" >&5
7268 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7269 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
7270   echo $ECHO_N "(cached) $ECHO_C" >&6
7271 else
7272   if test -n "$ac_ct_STRIP"; then
7273   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
7274 else
7275 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7276 for as_dir in $PATH
7277 do
7278   IFS=$as_save_IFS
7279   test -z "$as_dir" && as_dir=.
7280   for ac_exec_ext in '' $ac_executable_extensions; do
7281   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7282     ac_cv_prog_ac_ct_STRIP="strip"
7283     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7284     break 2
7285   fi
7286 done
7287 done
7288
7289   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
7290 fi
7291 fi
7292 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
7293 if test -n "$ac_ct_STRIP"; then
7294   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
7295 echo "${ECHO_T}$ac_ct_STRIP" >&6
7296 else
7297   echo "$as_me:$LINENO: result: no" >&5
7298 echo "${ECHO_T}no" >&6
7299 fi
7300
7301   STRIP=$ac_ct_STRIP
7302 else
7303   STRIP="$ac_cv_prog_STRIP"
7304 fi
7305
7306
7307 old_CC="$CC"
7308 old_CFLAGS="$CFLAGS"
7309
7310 # Set sane defaults for various variables
7311 test -z "$AR" && AR=ar
7312 test -z "$AR_FLAGS" && AR_FLAGS=cru
7313 test -z "$AS" && AS=as
7314 test -z "$CC" && CC=cc
7315 test -z "$LTCC" && LTCC=$CC
7316 test -z "$DLLTOOL" && DLLTOOL=dlltool
7317 test -z "$LD" && LD=ld
7318 test -z "$LN_S" && LN_S="ln -s"
7319 test -z "$MAGIC_CMD" && MAGIC_CMD=file
7320 test -z "$NM" && NM=nm
7321 test -z "$SED" && SED=sed
7322 test -z "$OBJDUMP" && OBJDUMP=objdump
7323 test -z "$RANLIB" && RANLIB=:
7324 test -z "$STRIP" && STRIP=:
7325 test -z "$ac_objext" && ac_objext=o
7326
7327 # Determine commands to create old-style static archives.
7328 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
7329 old_postinstall_cmds='chmod 644 $oldlib'
7330 old_postuninstall_cmds=
7331
7332 if test -n "$RANLIB"; then
7333   case $host_os in
7334   openbsd*)
7335     old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
7336     ;;
7337   *)
7338     old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
7339     ;;
7340   esac
7341   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
7342 fi
7343
7344 for cc_temp in $compiler""; do
7345   case $cc_temp in
7346     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
7347     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
7348     \-*) ;;
7349     *) break;;
7350   esac
7351 done
7352 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
7353
7354
7355 # Only perform the check for file, if the check method requires it
7356 case $deplibs_check_method in
7357 file_magic*)
7358   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
7359     echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5
7360 echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6
7361 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7362   echo $ECHO_N "(cached) $ECHO_C" >&6
7363 else
7364   case $MAGIC_CMD in
7365 [\\/*] |  ?:[\\/]*)
7366   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7367   ;;
7368 *)
7369   lt_save_MAGIC_CMD="$MAGIC_CMD"
7370   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
7371   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
7372   for ac_dir in $ac_dummy; do
7373     IFS="$lt_save_ifs"
7374     test -z "$ac_dir" && ac_dir=.
7375     if test -f $ac_dir/${ac_tool_prefix}file; then
7376       lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
7377       if test -n "$file_magic_test_file"; then
7378         case $deplibs_check_method in
7379         "file_magic "*)
7380           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
7381           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7382           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7383             $EGREP "$file_magic_regex" > /dev/null; then
7384             :
7385           else
7386             cat <<EOF 1>&2
7387
7388 *** Warning: the command libtool uses to detect shared libraries,
7389 *** $file_magic_cmd, produces output that libtool cannot recognize.
7390 *** The result is that libtool may fail to recognize shared libraries
7391 *** as such.  This will affect the creation of libtool libraries that
7392 *** depend on shared libraries, but programs linked with such libtool
7393 *** libraries will work regardless of this problem.  Nevertheless, you
7394 *** may want to report the problem to your system manager and/or to
7395 *** bug-libtool@gnu.org
7396
7397 EOF
7398           fi ;;
7399         esac
7400       fi
7401       break
7402     fi
7403   done
7404   IFS="$lt_save_ifs"
7405   MAGIC_CMD="$lt_save_MAGIC_CMD"
7406   ;;
7407 esac
7408 fi
7409
7410 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7411 if test -n "$MAGIC_CMD"; then
7412   echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7413 echo "${ECHO_T}$MAGIC_CMD" >&6
7414 else
7415   echo "$as_me:$LINENO: result: no" >&5
7416 echo "${ECHO_T}no" >&6
7417 fi
7418
7419 if test -z "$lt_cv_path_MAGIC_CMD"; then
7420   if test -n "$ac_tool_prefix"; then
7421     echo "$as_me:$LINENO: checking for file" >&5
7422 echo $ECHO_N "checking for file... $ECHO_C" >&6
7423 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7424   echo $ECHO_N "(cached) $ECHO_C" >&6
7425 else
7426   case $MAGIC_CMD in
7427 [\\/*] |  ?:[\\/]*)
7428   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7429   ;;
7430 *)
7431   lt_save_MAGIC_CMD="$MAGIC_CMD"
7432   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
7433   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
7434   for ac_dir in $ac_dummy; do
7435     IFS="$lt_save_ifs"
7436     test -z "$ac_dir" && ac_dir=.
7437     if test -f $ac_dir/file; then
7438       lt_cv_path_MAGIC_CMD="$ac_dir/file"
7439       if test -n "$file_magic_test_file"; then
7440         case $deplibs_check_method in
7441         "file_magic "*)
7442           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
7443           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7444           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7445             $EGREP "$file_magic_regex" > /dev/null; then
7446             :
7447           else
7448             cat <<EOF 1>&2
7449
7450 *** Warning: the command libtool uses to detect shared libraries,
7451 *** $file_magic_cmd, produces output that libtool cannot recognize.
7452 *** The result is that libtool may fail to recognize shared libraries
7453 *** as such.  This will affect the creation of libtool libraries that
7454 *** depend on shared libraries, but programs linked with such libtool
7455 *** libraries will work regardless of this problem.  Nevertheless, you
7456 *** may want to report the problem to your system manager and/or to
7457 *** bug-libtool@gnu.org
7458
7459 EOF
7460           fi ;;
7461         esac
7462       fi
7463       break
7464     fi
7465   done
7466   IFS="$lt_save_ifs"
7467   MAGIC_CMD="$lt_save_MAGIC_CMD"
7468   ;;
7469 esac
7470 fi
7471
7472 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7473 if test -n "$MAGIC_CMD"; then
7474   echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7475 echo "${ECHO_T}$MAGIC_CMD" >&6
7476 else
7477   echo "$as_me:$LINENO: result: no" >&5
7478 echo "${ECHO_T}no" >&6
7479 fi
7480
7481   else
7482     MAGIC_CMD=:
7483   fi
7484 fi
7485
7486   fi
7487   ;;
7488 esac
7489
7490 enable_dlopen=yes
7491 enable_win32_dll=yes
7492
7493 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
7494 if test "${enable_libtool_lock+set}" = set; then
7495   enableval="$enable_libtool_lock"
7496
7497 fi;
7498 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
7499
7500
7501 # Check whether --with-pic or --without-pic was given.
7502 if test "${with_pic+set}" = set; then
7503   withval="$with_pic"
7504   pic_mode="$withval"
7505 else
7506   pic_mode=default
7507 fi;
7508 test -z "$pic_mode" && pic_mode=default
7509
7510 # Use C for the default configuration in the libtool script
7511 tagname=
7512 lt_save_CC="$CC"
7513 ac_ext=c
7514 ac_cpp='$CPP $CPPFLAGS'
7515 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7516 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7517 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7518
7519
7520 # Source file extension for C test sources.
7521 ac_ext=c
7522
7523 # Object file extension for compiled C test sources.
7524 objext=o
7525 objext=$objext
7526
7527 # Code to be used in simple compile tests
7528 lt_simple_compile_test_code="int some_variable = 0;\n"
7529
7530 # Code to be used in simple link tests
7531 lt_simple_link_test_code='int main(){return(0);}\n'
7532
7533
7534 # If no C compiler was specified, use CC.
7535 LTCC=${LTCC-"$CC"}
7536
7537 # Allow CC to be a program name with arguments.
7538 compiler=$CC
7539
7540
7541 # save warnings/boilerplate of simple test code
7542 ac_outfile=conftest.$ac_objext
7543 printf "$lt_simple_compile_test_code" >conftest.$ac_ext
7544 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
7545 _lt_compiler_boilerplate=`cat conftest.err`
7546 $rm conftest*
7547
7548 ac_outfile=conftest.$ac_objext
7549 printf "$lt_simple_link_test_code" >conftest.$ac_ext
7550 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
7551 _lt_linker_boilerplate=`cat conftest.err`
7552 $rm conftest*
7553
7554
7555 #
7556 # Check for any special shared library compilation flags.
7557 #
7558 lt_prog_cc_shlib=
7559 if test "$GCC" = no; then
7560   case $host_os in
7561   sco3.2v5*)
7562     lt_prog_cc_shlib='-belf'
7563     ;;
7564   esac
7565 fi
7566 if test -n "$lt_prog_cc_shlib"; then
7567   { echo "$as_me:$LINENO: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&5
7568 echo "$as_me: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&2;}
7569   if echo "$old_CC $old_CFLAGS " | grep "[      ]$lt_prog_cc_shlib[     ]" >/dev/null; then :
7570   else
7571     { echo "$as_me:$LINENO: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&5
7572 echo "$as_me: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&2;}
7573     lt_cv_prog_cc_can_build_shared=no
7574   fi
7575 fi
7576
7577
7578 #
7579 # Check to make sure the static flag actually works.
7580 #
7581 echo "$as_me:$LINENO: checking if $compiler static flag $lt_prog_compiler_static works" >&5
7582 echo $ECHO_N "checking if $compiler static flag $lt_prog_compiler_static works... $ECHO_C" >&6
7583 if test "${lt_prog_compiler_static_works+set}" = set; then
7584   echo $ECHO_N "(cached) $ECHO_C" >&6
7585 else
7586   lt_prog_compiler_static_works=no
7587    save_LDFLAGS="$LDFLAGS"
7588    LDFLAGS="$LDFLAGS $lt_prog_compiler_static"
7589    printf "$lt_simple_link_test_code" > conftest.$ac_ext
7590    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
7591      # The linker can only warn and ignore the option if not recognized
7592      # So say no if there are warnings
7593      if test -s conftest.err; then
7594        # Append any errors to the config.log.
7595        cat conftest.err 1>&5
7596        $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp
7597        $SED '/^$/d' conftest.err >conftest.er2
7598        if diff conftest.exp conftest.er2 >/dev/null; then
7599          lt_prog_compiler_static_works=yes
7600        fi
7601      else
7602        lt_prog_compiler_static_works=yes
7603      fi
7604    fi
7605    $rm conftest*
7606    LDFLAGS="$save_LDFLAGS"
7607
7608 fi
7609 echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works" >&5
7610 echo "${ECHO_T}$lt_prog_compiler_static_works" >&6
7611
7612 if test x"$lt_prog_compiler_static_works" = xyes; then
7613     :
7614 else
7615     lt_prog_compiler_static=
7616 fi
7617
7618
7619
7620
7621 lt_prog_compiler_no_builtin_flag=
7622
7623 if test "$GCC" = yes; then
7624   lt_prog_compiler_no_builtin_flag=' -fno-builtin'
7625
7626
7627 echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
7628 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6
7629 if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then
7630   echo $ECHO_N "(cached) $ECHO_C" >&6
7631 else
7632   lt_cv_prog_compiler_rtti_exceptions=no
7633   ac_outfile=conftest.$ac_objext
7634    printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7635    lt_compiler_flag="-fno-rtti -fno-exceptions"
7636    # Insert the option either (1) after the last *FLAGS variable, or
7637    # (2) before a word containing "conftest.", or (3) at the end.
7638    # Note that $ac_compile itself does not contain backslashes and begins
7639    # with a dollar sign (not a hyphen), so the echo should work correctly.
7640    # The option is referenced via a variable to avoid confusing sed.
7641    lt_compile=`echo "$ac_compile" | $SED \
7642    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7643    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7644    -e 's:$: $lt_compiler_flag:'`
7645    (eval echo "\"\$as_me:7645: $lt_compile\"" >&5)
7646    (eval "$lt_compile" 2>conftest.err)
7647    ac_status=$?
7648    cat conftest.err >&5
7649    echo "$as_me:7649: \$? = $ac_status" >&5
7650    if (exit $ac_status) && test -s "$ac_outfile"; then
7651      # The compiler can only warn and ignore the option if not recognized
7652      # So say no if there are warnings other than the usual output.
7653      $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
7654      $SED '/^$/d' conftest.err >conftest.er2
7655      if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
7656        lt_cv_prog_compiler_rtti_exceptions=yes
7657      fi
7658    fi
7659    $rm conftest*
7660
7661 fi
7662 echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
7663 echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6
7664
7665 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
7666     lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
7667 else
7668     :
7669 fi
7670
7671 fi
7672
7673 lt_prog_compiler_wl=
7674 lt_prog_compiler_pic=
7675 lt_prog_compiler_static=
7676
7677 echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
7678 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6
7679
7680   if test "$GCC" = yes; then
7681     lt_prog_compiler_wl='-Wl,'
7682     lt_prog_compiler_static='-static'
7683
7684     case $host_os in
7685       aix*)
7686       # All AIX code is PIC.
7687       if test "$host_cpu" = ia64; then
7688         # AIX 5 now supports IA64 processor
7689         lt_prog_compiler_static='-Bstatic'
7690       fi
7691       ;;
7692
7693     amigaos*)
7694       # FIXME: we need at least 68020 code to build shared libraries, but
7695       # adding the `-m68020' flag to GCC prevents building anything better,
7696       # like `-m68040'.
7697       lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
7698       ;;
7699
7700     beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
7701       # PIC is the default for these OSes.
7702       ;;
7703
7704     mingw* | pw32* | os2*)
7705       # This hack is so that the source file can tell whether it is being
7706       # built for inclusion in a dll (and should export symbols for example).
7707       lt_prog_compiler_pic='-DDLL_EXPORT'
7708       ;;
7709
7710     darwin* | rhapsody*)
7711       # PIC is the default on this platform
7712       # Common symbols not allowed in MH_DYLIB files
7713       lt_prog_compiler_pic='-fno-common'
7714       ;;
7715
7716     msdosdjgpp*)
7717       # Just because we use GCC doesn't mean we suddenly get shared libraries
7718       # on systems that don't support them.
7719       lt_prog_compiler_can_build_shared=no
7720       enable_shared=no
7721       ;;
7722
7723     sysv4*MP*)
7724       if test -d /usr/nec; then
7725         lt_prog_compiler_pic=-Kconform_pic
7726       fi
7727       ;;
7728
7729     hpux*)
7730       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
7731       # not for PA HP-UX.
7732       case $host_cpu in
7733       hppa*64*|ia64*)
7734         # +Z the default
7735         ;;
7736       *)
7737         lt_prog_compiler_pic='-fPIC'
7738         ;;
7739       esac
7740       ;;
7741
7742     *)
7743       lt_prog_compiler_pic='-fPIC'
7744       ;;
7745     esac
7746   else
7747     # PORTME Check for flag to pass linker flags through the system compiler.
7748     case $host_os in
7749     aix*)
7750       lt_prog_compiler_wl='-Wl,'
7751       if test "$host_cpu" = ia64; then
7752         # AIX 5 now supports IA64 processor
7753         lt_prog_compiler_static='-Bstatic'
7754       else
7755         lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
7756       fi
7757       ;;
7758       darwin*)
7759         # PIC is the default on this platform
7760         # Common symbols not allowed in MH_DYLIB files
7761        case $cc_basename in
7762          xlc*)
7763          lt_prog_compiler_pic='-qnocommon'
7764          lt_prog_compiler_wl='-Wl,'
7765          ;;
7766        esac
7767        ;;
7768
7769     mingw* | pw32* | os2*)
7770       # This hack is so that the source file can tell whether it is being
7771       # built for inclusion in a dll (and should export symbols for example).
7772       lt_prog_compiler_pic='-DDLL_EXPORT'
7773       ;;
7774
7775     hpux9* | hpux10* | hpux11*)
7776       lt_prog_compiler_wl='-Wl,'
7777       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
7778       # not for PA HP-UX.
7779       case $host_cpu in
7780       hppa*64*|ia64*)
7781         # +Z the default
7782         ;;
7783       *)
7784         lt_prog_compiler_pic='+Z'
7785         ;;
7786       esac
7787       # Is there a better lt_prog_compiler_static that works with the bundled CC?
7788       lt_prog_compiler_static='${wl}-a ${wl}archive'
7789       ;;
7790
7791     irix5* | irix6* | nonstopux*)
7792       lt_prog_compiler_wl='-Wl,'
7793       # PIC (with -KPIC) is the default.
7794       lt_prog_compiler_static='-non_shared'
7795       ;;
7796
7797     newsos6)
7798       lt_prog_compiler_pic='-KPIC'
7799       lt_prog_compiler_static='-Bstatic'
7800       ;;
7801
7802     linux*)
7803       case $cc_basename in
7804       icc* | ecc*)
7805         lt_prog_compiler_wl='-Wl,'
7806         lt_prog_compiler_pic='-KPIC'
7807         lt_prog_compiler_static='-static'
7808         ;;
7809       pgcc* | pgf77* | pgf90* | pgf95*)
7810         # Portland Group compilers (*not* the Pentium gcc compiler,
7811         # which looks to be a dead project)
7812         lt_prog_compiler_wl='-Wl,'
7813         lt_prog_compiler_pic='-fpic'
7814         lt_prog_compiler_static='-Bstatic'
7815         ;;
7816       ccc*)
7817         lt_prog_compiler_wl='-Wl,'
7818         # All Alpha code is PIC.
7819         lt_prog_compiler_static='-non_shared'
7820         ;;
7821       esac
7822       ;;
7823
7824     osf3* | osf4* | osf5*)
7825       lt_prog_compiler_wl='-Wl,'
7826       # All OSF/1 code is PIC.
7827       lt_prog_compiler_static='-non_shared'
7828       ;;
7829
7830     sco3.2v5*)
7831       lt_prog_compiler_pic='-Kpic'
7832       lt_prog_compiler_static='-dn'
7833       ;;
7834
7835     solaris*)
7836       lt_prog_compiler_pic='-KPIC'
7837       lt_prog_compiler_static='-Bstatic'
7838       case $cc_basename in
7839       f77* | f90* | f95*)
7840         lt_prog_compiler_wl='-Qoption ld ';;
7841       *)
7842         lt_prog_compiler_wl='-Wl,';;
7843       esac
7844       ;;
7845
7846     sunos4*)
7847       lt_prog_compiler_wl='-Qoption ld '
7848       lt_prog_compiler_pic='-PIC'
7849       lt_prog_compiler_static='-Bstatic'
7850       ;;
7851
7852     sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
7853       lt_prog_compiler_wl='-Wl,'
7854       lt_prog_compiler_pic='-KPIC'
7855       lt_prog_compiler_static='-Bstatic'
7856       ;;
7857
7858     sysv4*MP*)
7859       if test -d /usr/nec ;then
7860         lt_prog_compiler_pic='-Kconform_pic'
7861         lt_prog_compiler_static='-Bstatic'
7862       fi
7863       ;;
7864
7865     unicos*)
7866       lt_prog_compiler_wl='-Wl,'
7867       lt_prog_compiler_can_build_shared=no
7868       ;;
7869
7870     uts4*)
7871       lt_prog_compiler_pic='-pic'
7872       lt_prog_compiler_static='-Bstatic'
7873       ;;
7874
7875     *)
7876       lt_prog_compiler_can_build_shared=no
7877       ;;
7878     esac
7879   fi
7880
7881 echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5
7882 echo "${ECHO_T}$lt_prog_compiler_pic" >&6
7883
7884 #
7885 # Check to make sure the PIC flag actually works.
7886 #
7887 if test -n "$lt_prog_compiler_pic"; then
7888
7889 echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
7890 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic works... $ECHO_C" >&6
7891 if test "${lt_prog_compiler_pic_works+set}" = set; then
7892   echo $ECHO_N "(cached) $ECHO_C" >&6
7893 else
7894   lt_prog_compiler_pic_works=no
7895   ac_outfile=conftest.$ac_objext
7896    printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7897    lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
7898    # Insert the option either (1) after the last *FLAGS variable, or
7899    # (2) before a word containing "conftest.", or (3) at the end.
7900    # Note that $ac_compile itself does not contain backslashes and begins
7901    # with a dollar sign (not a hyphen), so the echo should work correctly.
7902    # The option is referenced via a variable to avoid confusing sed.
7903    lt_compile=`echo "$ac_compile" | $SED \
7904    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7905    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7906    -e 's:$: $lt_compiler_flag:'`
7907    (eval echo "\"\$as_me:7907: $lt_compile\"" >&5)
7908    (eval "$lt_compile" 2>conftest.err)
7909    ac_status=$?
7910    cat conftest.err >&5
7911    echo "$as_me:7911: \$? = $ac_status" >&5
7912    if (exit $ac_status) && test -s "$ac_outfile"; then
7913      # The compiler can only warn and ignore the option if not recognized
7914      # So say no if there are warnings other than the usual output.
7915      $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
7916      $SED '/^$/d' conftest.err >conftest.er2
7917      if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
7918        lt_prog_compiler_pic_works=yes
7919      fi
7920    fi
7921    $rm conftest*
7922
7923 fi
7924 echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works" >&5
7925 echo "${ECHO_T}$lt_prog_compiler_pic_works" >&6
7926
7927 if test x"$lt_prog_compiler_pic_works" = xyes; then
7928     case $lt_prog_compiler_pic in
7929      "" | " "*) ;;
7930      *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
7931      esac
7932 else
7933     lt_prog_compiler_pic=
7934      lt_prog_compiler_can_build_shared=no
7935 fi
7936
7937 fi
7938 case $host_os in
7939   # For platforms which do not support PIC, -DPIC is meaningless:
7940   *djgpp*)
7941     lt_prog_compiler_pic=
7942     ;;
7943   *)
7944     lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
7945     ;;
7946 esac
7947
7948 echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
7949 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6
7950 if test "${lt_cv_prog_compiler_c_o+set}" = set; then
7951   echo $ECHO_N "(cached) $ECHO_C" >&6
7952 else
7953   lt_cv_prog_compiler_c_o=no
7954    $rm -r conftest 2>/dev/null
7955    mkdir conftest
7956    cd conftest
7957    mkdir out
7958    printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7959
7960    lt_compiler_flag="-o out/conftest2.$ac_objext"
7961    # Insert the option either (1) after the last *FLAGS variable, or
7962    # (2) before a word containing "conftest.", or (3) at the end.
7963    # Note that $ac_compile itself does not contain backslashes and begins
7964    # with a dollar sign (not a hyphen), so the echo should work correctly.
7965    lt_compile=`echo "$ac_compile" | $SED \
7966    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7967    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7968    -e 's:$: $lt_compiler_flag:'`
7969    (eval echo "\"\$as_me:7969: $lt_compile\"" >&5)
7970    (eval "$lt_compile" 2>out/conftest.err)
7971    ac_status=$?
7972    cat out/conftest.err >&5
7973    echo "$as_me:7973: \$? = $ac_status" >&5
7974    if (exit $ac_status) && test -s out/conftest2.$ac_objext
7975    then
7976      # The compiler can only warn and ignore the option if not recognized
7977      # So say no if there are warnings
7978      $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp
7979      $SED '/^$/d' out/conftest.err >out/conftest.er2
7980      if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then
7981        lt_cv_prog_compiler_c_o=yes
7982      fi
7983    fi
7984    chmod u+w . 2>&5
7985    $rm conftest*
7986    # SGI C++ compiler will create directory out/ii_files/ for
7987    # template instantiation
7988    test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
7989    $rm out/* && rmdir out
7990    cd ..
7991    rmdir conftest
7992    $rm conftest*
7993
7994 fi
7995 echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5
7996 echo "${ECHO_T}$lt_cv_prog_compiler_c_o" >&6
7997
7998
7999 hard_links="nottested"
8000 if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
8001   # do not overwrite the value of need_locks provided by the user
8002   echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
8003 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6
8004   hard_links=yes
8005   $rm conftest*
8006   ln conftest.a conftest.b 2>/dev/null && hard_links=no
8007   touch conftest.a
8008   ln conftest.a conftest.b 2>&5 || hard_links=no
8009   ln conftest.a conftest.b 2>/dev/null && hard_links=no
8010   echo "$as_me:$LINENO: result: $hard_links" >&5
8011 echo "${ECHO_T}$hard_links" >&6
8012   if test "$hard_links" = no; then
8013     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
8014 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
8015     need_locks=warn
8016   fi
8017 else
8018   need_locks=no
8019 fi
8020
8021 echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
8022 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6
8023
8024   runpath_var=
8025   allow_undefined_flag=
8026   enable_shared_with_static_runtimes=no
8027   archive_cmds=
8028   archive_expsym_cmds=
8029   old_archive_From_new_cmds=
8030   old_archive_from_expsyms_cmds=
8031   export_dynamic_flag_spec=
8032   whole_archive_flag_spec=
8033   thread_safe_flag_spec=
8034   hardcode_libdir_flag_spec=
8035   hardcode_libdir_flag_spec_ld=
8036   hardcode_libdir_separator=
8037   hardcode_direct=no
8038   hardcode_minus_L=no
8039   hardcode_shlibpath_var=unsupported
8040   link_all_deplibs=unknown
8041   hardcode_automatic=no
8042   module_cmds=
8043   module_expsym_cmds=
8044   always_export_symbols=no
8045   export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
8046   # include_expsyms should be a list of space-separated symbols to be *always*
8047   # included in the symbol list
8048   include_expsyms=
8049   # exclude_expsyms can be an extended regexp of symbols to exclude
8050   # it will be wrapped by ` (' and `)$', so one must not match beginning or
8051   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
8052   # as well as any symbol that contains `d'.
8053   exclude_expsyms="_GLOBAL_OFFSET_TABLE_"
8054   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
8055   # platforms (ab)use it in PIC code, but their linkers get confused if
8056   # the symbol is explicitly referenced.  Since portable code cannot
8057   # rely on this symbol name, it's probably fine to never include it in
8058   # preloaded symbol tables.
8059   extract_expsyms_cmds=
8060   # Just being paranoid about ensuring that cc_basename is set.
8061   for cc_temp in $compiler""; do
8062   case $cc_temp in
8063     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
8064     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
8065     \-*) ;;
8066     *) break;;
8067   esac
8068 done
8069 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
8070
8071   case $host_os in
8072   cygwin* | mingw* | pw32*)
8073     # FIXME: the MSVC++ port hasn't been tested in a loooong time
8074     # When not using gcc, we currently assume that we are using
8075     # Microsoft Visual C++.
8076     if test "$GCC" != yes; then
8077       with_gnu_ld=no
8078     fi
8079     ;;
8080   openbsd*)
8081     with_gnu_ld=no
8082     ;;
8083   esac
8084
8085   ld_shlibs=yes
8086   if test "$with_gnu_ld" = yes; then
8087     # If archive_cmds runs LD, not CC, wlarc should be empty
8088     wlarc='${wl}'
8089
8090     # Set some defaults for GNU ld with shared library support. These
8091     # are reset later if shared libraries are not supported. Putting them
8092     # here allows them to be overridden if necessary.
8093     runpath_var=LD_RUN_PATH
8094     hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir'
8095     export_dynamic_flag_spec='${wl}--export-dynamic'
8096     # ancient GNU ld didn't support --whole-archive et. al.
8097     if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
8098         whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
8099       else
8100         whole_archive_flag_spec=
8101     fi
8102     supports_anon_versioning=no
8103     case `$LD -v 2>/dev/null` in
8104       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
8105       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
8106       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
8107       *\ 2.11.*) ;; # other 2.11 versions
8108       *) supports_anon_versioning=yes ;;
8109     esac
8110
8111     # See if GNU ld supports shared libraries.
8112     case $host_os in
8113     aix3* | aix4* | aix5*)
8114       # On AIX/PPC, the GNU linker is very broken
8115       if test "$host_cpu" != ia64; then
8116         ld_shlibs=no
8117         cat <<EOF 1>&2
8118
8119 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
8120 *** to be unable to reliably create shared libraries on AIX.
8121 *** Therefore, libtool is disabling shared libraries support.  If you
8122 *** really care for shared libraries, you may want to modify your PATH
8123 *** so that a non-GNU linker is found, and then restart.
8124
8125 EOF
8126       fi
8127       ;;
8128
8129     amigaos*)
8130       archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
8131       hardcode_libdir_flag_spec='-L$libdir'
8132       hardcode_minus_L=yes
8133
8134       # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
8135       # that the semantics of dynamic libraries on AmigaOS, at least up
8136       # to version 4, is to share data among multiple programs linked
8137       # with the same dynamic library.  Since this doesn't match the
8138       # behavior of shared libraries on other platforms, we can't use
8139       # them.
8140       ld_shlibs=no
8141       ;;
8142
8143     beos*)
8144       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8145         allow_undefined_flag=unsupported
8146         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
8147         # support --undefined.  This deserves some investigation.  FIXME
8148         archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8149       else
8150         ld_shlibs=no
8151       fi
8152       ;;
8153
8154     cygwin* | mingw* | pw32*)
8155       # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
8156       # as there is no search path for DLLs.
8157       hardcode_libdir_flag_spec='-L$libdir'
8158       allow_undefined_flag=unsupported
8159       always_export_symbols=no
8160       enable_shared_with_static_runtimes=yes
8161       export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols'
8162
8163       if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
8164         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
8165         # If the export-symbols file already is a .def file (1st line
8166         # is EXPORTS), use it as is; otherwise, prepend...
8167         archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
8168           cp $export_symbols $output_objdir/$soname.def;
8169         else
8170           echo EXPORTS > $output_objdir/$soname.def;
8171           cat $export_symbols >> $output_objdir/$soname.def;
8172         fi~
8173         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000  ${wl}--out-implib,$lib'
8174       else
8175         ld_shlibs=no
8176       fi
8177       ;;
8178
8179     linux*)
8180       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8181         tmp_addflag=
8182         case $cc_basename,$host_cpu in
8183         pgcc*)                          # Portland Group C compiler
8184           whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
8185           tmp_addflag=' $pic_flag'
8186           ;;
8187         pgf77* | pgf90* | pgf95*)       # Portland Group f77 and f90 compilers
8188           whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
8189           tmp_addflag=' $pic_flag -Mnomain' ;;
8190         ecc*,ia64* | icc*,ia64*)                # Intel C compiler on ia64
8191           tmp_addflag=' -i_dynamic' ;;
8192         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
8193           tmp_addflag=' -i_dynamic -nofor_main' ;;
8194         ifc* | ifort*)                  # Intel Fortran compiler
8195           tmp_addflag=' -nofor_main' ;;
8196         esac
8197         archive_cmds='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8198
8199         if test $supports_anon_versioning = yes; then
8200           archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~
8201   cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
8202   $echo "local: *; };" >> $output_objdir/$libname.ver~
8203           $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
8204         fi
8205       else
8206         ld_shlibs=no
8207       fi
8208       ;;
8209
8210     netbsd*)
8211       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
8212         archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
8213         wlarc=
8214       else
8215         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8216         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8217       fi
8218       ;;
8219
8220     solaris* | sysv5*)
8221       if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
8222         ld_shlibs=no
8223         cat <<EOF 1>&2
8224
8225 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
8226 *** create shared libraries on Solaris systems.  Therefore, libtool
8227 *** is disabling shared libraries support.  We urge you to upgrade GNU
8228 *** binutils to release 2.9.1 or newer.  Another option is to modify
8229 *** your PATH or compiler configuration so that the native linker is
8230 *** used, and then restart.
8231
8232 EOF
8233       elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8234         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8235         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8236       else
8237         ld_shlibs=no
8238       fi
8239       ;;
8240
8241     sunos4*)
8242       archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8243       wlarc=
8244       hardcode_direct=yes
8245       hardcode_shlibpath_var=no
8246       ;;
8247
8248     *)
8249       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8250         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8251         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8252       else
8253         ld_shlibs=no
8254       fi
8255       ;;
8256     esac
8257
8258     if test "$ld_shlibs" = no; then
8259       runpath_var=
8260       hardcode_libdir_flag_spec=
8261       export_dynamic_flag_spec=
8262       whole_archive_flag_spec=
8263     fi
8264   else
8265     # PORTME fill in a description of your system's linker (not GNU ld)
8266     case $host_os in
8267     aix3*)
8268       allow_undefined_flag=unsupported
8269       always_export_symbols=yes
8270       archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
8271       # Note: this linker hardcodes the directories in LIBPATH if there
8272       # are no directories specified by -L.
8273       hardcode_minus_L=yes
8274       if test "$GCC" = yes && test -z "$link_static_flag"; then
8275         # Neither direct hardcoding nor static linking is supported with a
8276         # broken collect2.
8277         hardcode_direct=unsupported
8278       fi
8279       ;;
8280
8281     aix4* | aix5*)
8282       if test "$host_cpu" = ia64; then
8283         # On IA64, the linker does run time linking by default, so we don't
8284         # have to do anything special.
8285         aix_use_runtimelinking=no
8286         exp_sym_flag='-Bexport'
8287         no_entry_flag=""
8288       else
8289         # If we're using GNU nm, then we don't want the "-C" option.
8290         # -C means demangle to AIX nm, but means don't demangle with GNU nm
8291         if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
8292           export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
8293         else
8294           export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
8295         fi
8296         aix_use_runtimelinking=no
8297
8298         # Test if we are trying to use run time linking or normal
8299         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
8300         # need to do runtime linking.
8301         case $host_os in aix4.[23]|aix4.[23].*|aix5*)
8302           for ld_flag in $LDFLAGS; do
8303           if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
8304             aix_use_runtimelinking=yes
8305             break
8306           fi
8307           done
8308         esac
8309
8310         exp_sym_flag='-bexport'
8311         no_entry_flag='-bnoentry'
8312       fi
8313
8314       # When large executables or shared objects are built, AIX ld can
8315       # have problems creating the table of contents.  If linking a library
8316       # or program results in "error TOC overflow" add -mminimal-toc to
8317       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
8318       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
8319
8320       archive_cmds=''
8321       hardcode_direct=yes
8322       hardcode_libdir_separator=':'
8323       link_all_deplibs=yes
8324
8325       if test "$GCC" = yes; then
8326         case $host_os in aix4.[012]|aix4.[012].*)
8327         # We only want to do this on AIX 4.2 and lower, the check
8328         # below for broken collect2 doesn't work under 4.3+
8329           collect2name=`${CC} -print-prog-name=collect2`
8330           if test -f "$collect2name" && \
8331            strings "$collect2name" | grep resolve_lib_name >/dev/null
8332           then
8333           # We have reworked collect2
8334           hardcode_direct=yes
8335           else
8336           # We have old collect2
8337           hardcode_direct=unsupported
8338           # It fails to find uninstalled libraries when the uninstalled
8339           # path is not listed in the libpath.  Setting hardcode_minus_L
8340           # to unsupported forces relinking
8341           hardcode_minus_L=yes
8342           hardcode_libdir_flag_spec='-L$libdir'
8343           hardcode_libdir_separator=
8344           fi
8345         esac
8346         shared_flag='-shared'
8347         if test "$aix_use_runtimelinking" = yes; then
8348           shared_flag="$shared_flag "'${wl}-G'
8349         fi
8350       else
8351         # not using gcc
8352         if test "$host_cpu" = ia64; then
8353         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
8354         # chokes on -Wl,-G. The following line is correct:
8355           shared_flag='-G'
8356         else
8357         if test "$aix_use_runtimelinking" = yes; then
8358             shared_flag='${wl}-G'
8359           else
8360             shared_flag='${wl}-bM:SRE'
8361         fi
8362         fi
8363       fi
8364
8365       # It seems that -bexpall does not export symbols beginning with
8366       # underscore (_), so it is better to generate a list of symbols to export.
8367       always_export_symbols=yes
8368       if test "$aix_use_runtimelinking" = yes; then
8369         # Warning - without using the other runtime loading flags (-brtl),
8370         # -berok will link without error, but may produce a broken library.
8371         allow_undefined_flag='-berok'
8372        # Determine the default libpath from the value encoded in an empty executable.
8373        cat >conftest.$ac_ext <<_ACEOF
8374 /* confdefs.h.  */
8375 _ACEOF
8376 cat confdefs.h >>conftest.$ac_ext
8377 cat >>conftest.$ac_ext <<_ACEOF
8378 /* end confdefs.h.  */
8379
8380 int
8381 main ()
8382 {
8383
8384   ;
8385   return 0;
8386 }
8387 _ACEOF
8388 rm -f conftest.$ac_objext conftest$ac_exeext
8389 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8390   (eval $ac_link) 2>conftest.er1
8391   ac_status=$?
8392   grep -v '^ *+' conftest.er1 >conftest.err
8393   rm -f conftest.er1
8394   cat conftest.err >&5
8395   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8396   (exit $ac_status); } &&
8397          { ac_try='test -z "$ac_c_werror_flag"
8398                          || test ! -s conftest.err'
8399   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8400   (eval $ac_try) 2>&5
8401   ac_status=$?
8402   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8403   (exit $ac_status); }; } &&
8404          { ac_try='test -s conftest$ac_exeext'
8405   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8406   (eval $ac_try) 2>&5
8407   ac_status=$?
8408   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8409   (exit $ac_status); }; }; then
8410
8411 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
8412 }'`
8413 # Check for a 64-bit object if we didn't find anything.
8414 if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
8415 }'`; fi
8416 else
8417   echo "$as_me: failed program was:" >&5
8418 sed 's/^/| /' conftest.$ac_ext >&5
8419
8420 fi
8421 rm -f conftest.err conftest.$ac_objext \
8422       conftest$ac_exeext conftest.$ac_ext
8423 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
8424
8425        hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
8426         archive_expsym_cmds="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
8427        else
8428         if test "$host_cpu" = ia64; then
8429           hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
8430           allow_undefined_flag="-z nodefs"
8431           archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
8432         else
8433          # Determine the default libpath from the value encoded in an empty executable.
8434          cat >conftest.$ac_ext <<_ACEOF
8435 /* confdefs.h.  */
8436 _ACEOF
8437 cat confdefs.h >>conftest.$ac_ext
8438 cat >>conftest.$ac_ext <<_ACEOF
8439 /* end confdefs.h.  */
8440
8441 int
8442 main ()
8443 {
8444
8445   ;
8446   return 0;
8447 }
8448 _ACEOF
8449 rm -f conftest.$ac_objext conftest$ac_exeext
8450 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8451   (eval $ac_link) 2>conftest.er1
8452   ac_status=$?
8453   grep -v '^ *+' conftest.er1 >conftest.err
8454   rm -f conftest.er1
8455   cat conftest.err >&5
8456   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8457   (exit $ac_status); } &&
8458          { ac_try='test -z "$ac_c_werror_flag"
8459                          || test ! -s conftest.err'
8460   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8461   (eval $ac_try) 2>&5
8462   ac_status=$?
8463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8464   (exit $ac_status); }; } &&
8465          { ac_try='test -s conftest$ac_exeext'
8466   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8467   (eval $ac_try) 2>&5
8468   ac_status=$?
8469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8470   (exit $ac_status); }; }; then
8471
8472 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
8473 }'`
8474 # Check for a 64-bit object if we didn't find anything.
8475 if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
8476 }'`; fi
8477 else
8478   echo "$as_me: failed program was:" >&5
8479 sed 's/^/| /' conftest.$ac_ext >&5
8480
8481 fi
8482 rm -f conftest.err conftest.$ac_objext \
8483       conftest$ac_exeext conftest.$ac_ext
8484 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
8485
8486          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
8487           # Warning - without using the other run time loading flags,
8488           # -berok will link without error, but may produce a broken library.
8489           no_undefined_flag=' ${wl}-bernotok'
8490           allow_undefined_flag=' ${wl}-berok'
8491           # -bexpall does not export symbols beginning with underscore (_)
8492           always_export_symbols=yes
8493           # Exported symbols can be pulled into shared objects from archives
8494           whole_archive_flag_spec=' '
8495           archive_cmds_need_lc=yes
8496           # This is similar to how AIX traditionally builds its shared libraries.
8497           archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
8498         fi
8499       fi
8500       ;;
8501
8502     amigaos*)
8503       archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
8504       hardcode_libdir_flag_spec='-L$libdir'
8505       hardcode_minus_L=yes
8506       # see comment about different semantics on the GNU ld section
8507       ld_shlibs=no
8508       ;;
8509
8510     bsdi[45]*)
8511       export_dynamic_flag_spec=-rdynamic
8512       ;;
8513
8514     cygwin* | mingw* | pw32*)
8515       # When not using gcc, we currently assume that we are using
8516       # Microsoft Visual C++.
8517       # hardcode_libdir_flag_spec is actually meaningless, as there is
8518       # no search path for DLLs.
8519       hardcode_libdir_flag_spec=' '
8520       allow_undefined_flag=unsupported
8521       # Tell ltmain to make .lib files, not .a files.
8522       libext=lib
8523       # Tell ltmain to make .dll files, not .so files.
8524       shrext_cmds=".dll"
8525       # FIXME: Setting linknames here is a bad hack.
8526       archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
8527       # The linker will automatically build a .lib file if we build a DLL.
8528       old_archive_From_new_cmds='true'
8529       # FIXME: Should let the user specify the lib program.
8530       old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs'
8531       fix_srcfile_path='`cygpath -w "$srcfile"`'
8532       enable_shared_with_static_runtimes=yes
8533       ;;
8534
8535     darwin* | rhapsody*)
8536       case $host_os in
8537         rhapsody* | darwin1.[012])
8538          allow_undefined_flag='${wl}-undefined ${wl}suppress'
8539          ;;
8540        *) # Darwin 1.3 on
8541          if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
8542            allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
8543          else
8544            case ${MACOSX_DEPLOYMENT_TARGET} in
8545              10.[012])
8546                allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
8547                ;;
8548              10.*)
8549                allow_undefined_flag='${wl}-undefined ${wl}dynamic_lookup'
8550                ;;
8551            esac
8552          fi
8553          ;;
8554       esac
8555       archive_cmds_need_lc=no
8556       hardcode_direct=no
8557       hardcode_automatic=yes
8558       hardcode_shlibpath_var=unsupported
8559       whole_archive_flag_spec=''
8560       link_all_deplibs=yes
8561     if test "$GCC" = yes ; then
8562         output_verbose_link_cmd='echo'
8563         archive_cmds='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
8564       module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
8565       # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
8566       archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
8567       module_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
8568     else
8569       case $cc_basename in
8570         xlc*)
8571          output_verbose_link_cmd='echo'
8572          archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
8573          module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
8574           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
8575          archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
8576           module_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
8577           ;;
8578        *)
8579          ld_shlibs=no
8580           ;;
8581       esac
8582     fi
8583       ;;
8584
8585     dgux*)
8586       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8587       hardcode_libdir_flag_spec='-L$libdir'
8588       hardcode_shlibpath_var=no
8589       ;;
8590
8591     freebsd1*)
8592       ld_shlibs=no
8593       ;;
8594
8595     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
8596     # support.  Future versions do this automatically, but an explicit c++rt0.o
8597     # does not break anything, and helps significantly (at the cost of a little
8598     # extra space).
8599     freebsd2.2*)
8600       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
8601       hardcode_libdir_flag_spec='-R$libdir'
8602       hardcode_direct=yes
8603       hardcode_shlibpath_var=no
8604       ;;
8605
8606     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
8607     freebsd2*)
8608       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8609       hardcode_direct=yes
8610       hardcode_minus_L=yes
8611       hardcode_shlibpath_var=no
8612       ;;
8613
8614     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
8615     freebsd* | kfreebsd*-gnu | dragonfly*)
8616       archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
8617       hardcode_libdir_flag_spec='-R$libdir'
8618       hardcode_direct=yes
8619       hardcode_shlibpath_var=no
8620       ;;
8621
8622     hpux9*)
8623       if test "$GCC" = yes; then
8624         archive_cmds='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
8625       else
8626         archive_cmds='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
8627       fi
8628       hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8629       hardcode_libdir_separator=:
8630       hardcode_direct=yes
8631
8632       # hardcode_minus_L: Not really in the search PATH,
8633       # but as the default location of the library.
8634       hardcode_minus_L=yes
8635       export_dynamic_flag_spec='${wl}-E'
8636       ;;
8637
8638     hpux10* | hpux11*)
8639       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
8640         case $host_cpu in
8641         hppa*64*|ia64*)
8642           archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8643           ;;
8644         *)
8645           archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
8646           ;;
8647         esac
8648       else
8649         case $host_cpu in
8650         hppa*64*|ia64*)
8651           archive_cmds='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags'
8652           ;;
8653         *)
8654           archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
8655           ;;
8656         esac
8657       fi
8658       if test "$with_gnu_ld" = no; then
8659         case $host_cpu in
8660         hppa*64*)
8661           hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8662           hardcode_libdir_flag_spec_ld='+b $libdir'
8663           hardcode_libdir_separator=:
8664           hardcode_direct=no
8665           hardcode_shlibpath_var=no
8666           ;;
8667         ia64*)
8668           hardcode_libdir_flag_spec='-L$libdir'
8669           hardcode_direct=no
8670           hardcode_shlibpath_var=no
8671
8672           # hardcode_minus_L: Not really in the search PATH,
8673           # but as the default location of the library.
8674           hardcode_minus_L=yes
8675           ;;
8676         *)
8677           hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8678           hardcode_libdir_separator=:
8679           hardcode_direct=yes
8680           export_dynamic_flag_spec='${wl}-E'
8681
8682           # hardcode_minus_L: Not really in the search PATH,
8683           # but as the default location of the library.
8684           hardcode_minus_L=yes
8685           ;;
8686         esac
8687       fi
8688       ;;
8689
8690     irix5* | irix6* | nonstopux*)
8691       if test "$GCC" = yes; then
8692         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
8693       else
8694         archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
8695         hardcode_libdir_flag_spec_ld='-rpath $libdir'
8696       fi
8697       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8698       hardcode_libdir_separator=:
8699       link_all_deplibs=yes
8700       ;;
8701
8702     netbsd*)
8703       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
8704         archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
8705       else
8706         archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
8707       fi
8708       hardcode_libdir_flag_spec='-R$libdir'
8709       hardcode_direct=yes
8710       hardcode_shlibpath_var=no
8711       ;;
8712
8713     newsos6)
8714       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8715       hardcode_direct=yes
8716       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8717       hardcode_libdir_separator=:
8718       hardcode_shlibpath_var=no
8719       ;;
8720
8721     openbsd*)
8722       hardcode_direct=yes
8723       hardcode_shlibpath_var=no
8724       if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
8725         archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8726         archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
8727         hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8728         export_dynamic_flag_spec='${wl}-E'
8729       else
8730        case $host_os in
8731          openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
8732            archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8733            hardcode_libdir_flag_spec='-R$libdir'
8734            ;;
8735          *)
8736            archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8737            hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8738            ;;
8739        esac
8740       fi
8741       ;;
8742
8743     os2*)
8744       hardcode_libdir_flag_spec='-L$libdir'
8745       hardcode_minus_L=yes
8746       allow_undefined_flag=unsupported
8747       archive_cmds='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
8748       old_archive_From_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
8749       ;;
8750
8751     osf3*)
8752       if test "$GCC" = yes; then
8753         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
8754         archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
8755       else
8756         allow_undefined_flag=' -expect_unresolved \*'
8757         archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
8758       fi
8759       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8760       hardcode_libdir_separator=:
8761       ;;
8762
8763     osf4* | osf5*)      # as osf3* with the addition of -msym flag
8764       if test "$GCC" = yes; then
8765         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
8766         archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
8767         hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8768       else
8769         allow_undefined_flag=' -expect_unresolved \*'
8770         archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
8771         archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
8772         $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp'
8773
8774         # Both c and cxx compiler support -rpath directly
8775         hardcode_libdir_flag_spec='-rpath $libdir'
8776       fi
8777       hardcode_libdir_separator=:
8778       ;;
8779
8780     sco3.2v5*)
8781       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8782       hardcode_shlibpath_var=no
8783       export_dynamic_flag_spec='${wl}-Bexport'
8784       runpath_var=LD_RUN_PATH
8785       hardcode_runpath_var=yes
8786       ;;
8787
8788     solaris*)
8789       no_undefined_flag=' -z text'
8790       if test "$GCC" = yes; then
8791         wlarc='${wl}'
8792         archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8793         archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8794           $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
8795       else
8796         wlarc=''
8797         archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
8798         archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8799         $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
8800       fi
8801       hardcode_libdir_flag_spec='-R$libdir'
8802       hardcode_shlibpath_var=no
8803       case $host_os in
8804       solaris2.[0-5] | solaris2.[0-5].*) ;;
8805       *)
8806         # The compiler driver will combine linker options so we
8807         # cannot just pass the convience library names through
8808         # without $wl, iff we do not link with $LD.
8809         # Luckily, gcc supports the same syntax we need for Sun Studio.
8810         # Supported since Solaris 2.6 (maybe 2.5.1?)
8811         case $wlarc in
8812         '')
8813           whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;;
8814         *)
8815           whole_archive_flag_spec='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;;
8816         esac ;;
8817       esac
8818       link_all_deplibs=yes
8819       ;;
8820
8821     sunos4*)
8822       if test "x$host_vendor" = xsequent; then
8823         # Use $CC to link under sequent, because it throws in some extra .o
8824         # files that make .init and .fini sections work.
8825         archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
8826       else
8827         archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
8828       fi
8829       hardcode_libdir_flag_spec='-L$libdir'
8830       hardcode_direct=yes
8831       hardcode_minus_L=yes
8832       hardcode_shlibpath_var=no
8833       ;;
8834
8835     sysv4)
8836       case $host_vendor in
8837         sni)
8838           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8839           hardcode_direct=yes # is this really true???
8840         ;;
8841         siemens)
8842           ## LD is ld it makes a PLAMLIB
8843           ## CC just makes a GrossModule.
8844           archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
8845           reload_cmds='$CC -r -o $output$reload_objs'
8846           hardcode_direct=no
8847         ;;
8848         motorola)
8849           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8850           hardcode_direct=no #Motorola manual says yes, but my tests say they lie
8851         ;;
8852       esac
8853       runpath_var='LD_RUN_PATH'
8854       hardcode_shlibpath_var=no
8855       ;;
8856
8857     sysv4.3*)
8858       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8859       hardcode_shlibpath_var=no
8860       export_dynamic_flag_spec='-Bexport'
8861       ;;
8862
8863     sysv4*MP*)
8864       if test -d /usr/nec; then
8865         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8866         hardcode_shlibpath_var=no
8867         runpath_var=LD_RUN_PATH
8868         hardcode_runpath_var=yes
8869         ld_shlibs=yes
8870       fi
8871       ;;
8872
8873     sysv4.2uw2*)
8874       archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
8875       hardcode_direct=yes
8876       hardcode_minus_L=no
8877       hardcode_shlibpath_var=no
8878       hardcode_runpath_var=yes
8879       runpath_var=LD_RUN_PATH
8880       ;;
8881
8882    sysv5OpenUNIX8* | sysv5UnixWare7* |  sysv5uw[78]* | unixware7*)
8883       no_undefined_flag='${wl}-z ${wl}text'
8884       if test "$GCC" = yes; then
8885         archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8886       else
8887         archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8888       fi
8889       runpath_var='LD_RUN_PATH'
8890       hardcode_shlibpath_var=no
8891       ;;
8892
8893     sysv5*)
8894       no_undefined_flag=' -z text'
8895       # $CC -shared without GNU ld will not create a library from C++
8896       # object files and a static libstdc++, better avoid it by now
8897       archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
8898       archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8899                 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
8900       hardcode_libdir_flag_spec=
8901       hardcode_shlibpath_var=no
8902       runpath_var='LD_RUN_PATH'
8903       ;;
8904
8905     uts4*)
8906       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8907       hardcode_libdir_flag_spec='-L$libdir'
8908       hardcode_shlibpath_var=no
8909       ;;
8910
8911     *)
8912       ld_shlibs=no
8913       ;;
8914     esac
8915   fi
8916
8917 echo "$as_me:$LINENO: result: $ld_shlibs" >&5
8918 echo "${ECHO_T}$ld_shlibs" >&6
8919 test "$ld_shlibs" = no && can_build_shared=no
8920
8921 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
8922 if test "$GCC" = yes; then
8923   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
8924 fi
8925
8926 #
8927 # Do we need to explicitly link libc?
8928 #
8929 case "x$archive_cmds_need_lc" in
8930 x|xyes)
8931   # Assume -lc should be added
8932   archive_cmds_need_lc=yes
8933
8934   if test "$enable_shared" = yes && test "$GCC" = yes; then
8935     case $archive_cmds in
8936     *'~'*)
8937       # FIXME: we may have to deal with multi-command sequences.
8938       ;;
8939     '$CC '*)
8940       # Test whether the compiler implicitly links with -lc since on some
8941       # systems, -lgcc has to come before -lc. If gcc already passes -lc
8942       # to ld, don't add -lc before -lgcc.
8943       echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
8944 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6
8945       $rm conftest*
8946       printf "$lt_simple_compile_test_code" > conftest.$ac_ext
8947
8948       if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8949   (eval $ac_compile) 2>&5
8950   ac_status=$?
8951   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8952   (exit $ac_status); } 2>conftest.err; then
8953         soname=conftest
8954         lib=conftest
8955         libobjs=conftest.$ac_objext
8956         deplibs=
8957         wl=$lt_prog_compiler_wl
8958         compiler_flags=-v
8959         linker_flags=-v
8960         verstring=
8961         output_objdir=.
8962         libname=conftest
8963         lt_save_allow_undefined_flag=$allow_undefined_flag
8964         allow_undefined_flag=
8965         if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5
8966   (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5
8967   ac_status=$?
8968   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8969   (exit $ac_status); }
8970         then
8971           archive_cmds_need_lc=no
8972         else
8973           archive_cmds_need_lc=yes
8974         fi
8975         allow_undefined_flag=$lt_save_allow_undefined_flag
8976       else
8977         cat conftest.err 1>&5
8978       fi
8979       $rm conftest*
8980       echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5
8981 echo "${ECHO_T}$archive_cmds_need_lc" >&6
8982       ;;
8983     esac
8984   fi
8985   ;;
8986 esac
8987
8988 echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
8989 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6
8990 library_names_spec=
8991 libname_spec='lib$name'
8992 soname_spec=
8993 shrext_cmds=".so"
8994 postinstall_cmds=
8995 postuninstall_cmds=
8996 finish_cmds=
8997 finish_eval=
8998 shlibpath_var=
8999 shlibpath_overrides_runpath=unknown
9000 version_type=none
9001 dynamic_linker="$host_os ld.so"
9002 sys_lib_dlsearch_path_spec="/lib /usr/lib"
9003 if test "$GCC" = yes; then
9004   sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
9005   if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
9006     # if the path contains ";" then we assume it to be the separator
9007     # otherwise default to the standard path separator (i.e. ":") - it is
9008     # assumed that no part of a normal pathname contains ";" but that should
9009     # okay in the real world where ";" in dirpaths is itself problematic.
9010     sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
9011   else
9012     sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
9013   fi
9014 else
9015   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
9016 fi
9017 need_lib_prefix=unknown
9018 hardcode_into_libs=no
9019
9020 # when you set need_version to no, make sure it does not cause -set_version
9021 # flags to be left without arguments
9022 need_version=unknown
9023
9024 case $host_os in
9025 aix3*)
9026   version_type=linux
9027   library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
9028   shlibpath_var=LIBPATH
9029
9030   # AIX 3 has no versioning support, so we append a major version to the name.
9031   soname_spec='${libname}${release}${shared_ext}$major'
9032   ;;
9033
9034 aix4* | aix5*)
9035   version_type=linux
9036   need_lib_prefix=no
9037   need_version=no
9038   hardcode_into_libs=yes
9039   if test "$host_cpu" = ia64; then
9040     # AIX 5 supports IA64
9041     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
9042     shlibpath_var=LD_LIBRARY_PATH
9043   else
9044     # With GCC up to 2.95.x, collect2 would create an import file
9045     # for dependence libraries.  The import file would start with
9046     # the line `#! .'.  This would cause the generated library to
9047     # depend on `.', always an invalid library.  This was fixed in
9048     # development snapshots of GCC prior to 3.0.
9049     case $host_os in
9050       aix4 | aix4.[01] | aix4.[01].*)
9051       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
9052            echo ' yes '
9053            echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
9054         :
9055       else
9056         can_build_shared=no
9057       fi
9058       ;;
9059     esac
9060     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
9061     # soname into executable. Probably we can add versioning support to
9062     # collect2, so additional links can be useful in future.
9063     if test "$aix_use_runtimelinking" = yes; then
9064       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
9065       # instead of lib<name>.a to let people know that these are not
9066       # typical AIX shared libraries.
9067       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9068     else
9069       # We preserve .a as extension for shared libraries through AIX4.2
9070       # and later when we are not doing run time linking.
9071       library_names_spec='${libname}${release}.a $libname.a'
9072       soname_spec='${libname}${release}${shared_ext}$major'
9073     fi
9074     shlibpath_var=LIBPATH
9075   fi
9076   ;;
9077
9078 amigaos*)
9079   library_names_spec='$libname.ixlibrary $libname.a'
9080   # Create ${libname}_ixlibrary.a entries in /sys/libs.
9081   finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
9082   ;;
9083
9084 beos*)
9085   library_names_spec='${libname}${shared_ext}'
9086   dynamic_linker="$host_os ld.so"
9087   shlibpath_var=LIBRARY_PATH
9088   ;;
9089
9090 bsdi[45]*)
9091   version_type=linux
9092   need_version=no
9093   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9094   soname_spec='${libname}${release}${shared_ext}$major'
9095   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
9096   shlibpath_var=LD_LIBRARY_PATH
9097   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
9098   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
9099   # the default ld.so.conf also contains /usr/contrib/lib and
9100   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
9101   # libtool to hard-code these into programs
9102   ;;
9103
9104 cygwin* | mingw* | pw32*)
9105   version_type=windows
9106   shrext_cmds=".dll"
9107   need_version=no
9108   need_lib_prefix=no
9109
9110   case $GCC,$host_os in
9111   yes,cygwin* | yes,mingw* | yes,pw32*)
9112     library_names_spec='$libname.dll.a'
9113     # DLL is installed to $(libdir)/../bin by postinstall_cmds
9114     postinstall_cmds='base_file=`basename \${file}`~
9115       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
9116       dldir=$destdir/`dirname \$dlpath`~
9117       test -d \$dldir || mkdir -p \$dldir~
9118       $install_prog $dir/$dlname \$dldir/$dlname~
9119       chmod a+x \$dldir/$dlname'
9120     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
9121       dlpath=$dir/\$dldll~
9122        $rm \$dlpath'
9123     shlibpath_overrides_runpath=yes
9124
9125     case $host_os in
9126     cygwin*)
9127       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
9128       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9129       sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
9130       ;;
9131     mingw*)
9132       # MinGW DLLs use traditional 'lib' prefix
9133       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9134       sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
9135       if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then
9136         # It is most probably a Windows format PATH printed by
9137         # mingw gcc, but we are running on Cygwin. Gcc prints its search
9138         # path with ; separators, and with drive letters. We can handle the
9139         # drive letters (cygwin fileutils understands them), so leave them,
9140         # especially as we might pass files found there to a mingw objdump,
9141         # which wouldn't understand a cygwinified path. Ahh.
9142         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
9143       else
9144         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
9145       fi
9146       ;;
9147     pw32*)
9148       # pw32 DLLs use 'pw' prefix rather than 'lib'
9149       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9150       ;;
9151     esac
9152     ;;
9153
9154   *)
9155     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
9156     ;;
9157   esac
9158   dynamic_linker='Win32 ld.exe'
9159   # FIXME: first we should search . and the directory the executable is in
9160   shlibpath_var=PATH
9161   ;;
9162
9163 darwin* | rhapsody*)
9164   dynamic_linker="$host_os dyld"
9165   version_type=darwin
9166   need_lib_prefix=no
9167   need_version=no
9168   library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
9169   soname_spec='${libname}${release}${major}$shared_ext'
9170   shlibpath_overrides_runpath=yes
9171   shlibpath_var=DYLD_LIBRARY_PATH
9172   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
9173   # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
9174   if test "$GCC" = yes; then
9175     sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"`
9176   else
9177     sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
9178   fi
9179   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
9180   ;;
9181
9182 dgux*)
9183   version_type=linux
9184   need_lib_prefix=no
9185   need_version=no
9186   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
9187   soname_spec='${libname}${release}${shared_ext}$major'
9188   shlibpath_var=LD_LIBRARY_PATH
9189   ;;
9190
9191 freebsd1*)
9192   dynamic_linker=no
9193   ;;
9194
9195 kfreebsd*-gnu)
9196   version_type=linux
9197   need_lib_prefix=no
9198   need_version=no
9199   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9200   soname_spec='${libname}${release}${shared_ext}$major'
9201   shlibpath_var=LD_LIBRARY_PATH
9202   shlibpath_overrides_runpath=no
9203   hardcode_into_libs=yes
9204   dynamic_linker='GNU ld.so'
9205   ;;
9206
9207 freebsd* | dragonfly*)
9208   # DragonFly does not have aout.  When/if they implement a new
9209   # versioning mechanism, adjust this.
9210   if test -x /usr/bin/objformat; then
9211     objformat=`/usr/bin/objformat`
9212   else
9213     case $host_os in
9214     freebsd[123]*) objformat=aout ;;
9215     *) objformat=elf ;;
9216     esac
9217   fi
9218   version_type=freebsd-$objformat
9219   case $version_type in
9220     freebsd-elf*)
9221       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
9222       need_version=no
9223       need_lib_prefix=no
9224       ;;
9225     freebsd-*)
9226       library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
9227       need_version=yes
9228       ;;
9229   esac
9230   shlibpath_var=LD_LIBRARY_PATH
9231   case $host_os in
9232   freebsd2*)
9233     shlibpath_overrides_runpath=yes
9234     ;;
9235   freebsd3.[01]* | freebsdelf3.[01]*)
9236     shlibpath_overrides_runpath=yes
9237     hardcode_into_libs=yes
9238     ;;
9239   *) # from 3.2 on
9240     shlibpath_overrides_runpath=no
9241     hardcode_into_libs=yes
9242     ;;
9243   esac
9244   ;;
9245
9246 gnu*)
9247   version_type=linux
9248   need_lib_prefix=no
9249   need_version=no
9250   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
9251   soname_spec='${libname}${release}${shared_ext}$major'
9252   shlibpath_var=LD_LIBRARY_PATH
9253   hardcode_into_libs=yes
9254   ;;
9255
9256 hpux9* | hpux10* | hpux11*)
9257   # Give a soname corresponding to the major version so that dld.sl refuses to
9258   # link against other versions.
9259   version_type=sunos
9260   need_lib_prefix=no
9261   need_version=no
9262   case $host_cpu in
9263   ia64*)
9264     shrext_cmds='.so'
9265     hardcode_into_libs=yes
9266     dynamic_linker="$host_os dld.so"
9267     shlibpath_var=LD_LIBRARY_PATH
9268     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
9269     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9270     soname_spec='${libname}${release}${shared_ext}$major'
9271     if test "X$HPUX_IA64_MODE" = X32; then
9272       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
9273     else
9274       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
9275     fi
9276     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
9277     ;;
9278    hppa*64*)
9279      shrext_cmds='.sl'
9280      hardcode_into_libs=yes
9281      dynamic_linker="$host_os dld.sl"
9282      shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
9283      shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
9284      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9285      soname_spec='${libname}${release}${shared_ext}$major'
9286      sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
9287      sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
9288      ;;
9289    *)
9290     shrext_cmds='.sl'
9291     dynamic_linker="$host_os dld.sl"
9292     shlibpath_var=SHLIB_PATH
9293     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
9294     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9295     soname_spec='${libname}${release}${shared_ext}$major'
9296     ;;
9297   esac
9298   # HP-UX runs *really* slowly unless shared libraries are mode 555.
9299   postinstall_cmds='chmod 555 $lib'
9300   ;;
9301
9302 irix5* | irix6* | nonstopux*)
9303   case $host_os in
9304     nonstopux*) version_type=nonstopux ;;
9305     *)
9306         if test "$lt_cv_prog_gnu_ld" = yes; then
9307                 version_type=linux
9308         else
9309                 version_type=irix
9310         fi ;;
9311   esac
9312   need_lib_prefix=no
9313   need_version=no
9314   soname_spec='${libname}${release}${shared_ext}$major'
9315   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
9316   case $host_os in
9317   irix5* | nonstopux*)
9318     libsuff= shlibsuff=
9319     ;;
9320   *)
9321     case $LD in # libtool.m4 will add one of these switches to LD
9322     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
9323       libsuff= shlibsuff= libmagic=32-bit;;
9324     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
9325       libsuff=32 shlibsuff=N32 libmagic=N32;;
9326     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
9327       libsuff=64 shlibsuff=64 libmagic=64-bit;;
9328     *) libsuff= shlibsuff= libmagic=never-match;;
9329     esac
9330     ;;
9331   esac
9332   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
9333   shlibpath_overrides_runpath=no
9334   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
9335   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
9336   hardcode_into_libs=yes
9337   ;;
9338
9339 # No shared lib support for Linux oldld, aout, or coff.
9340 linux*oldld* | linux*aout* | linux*coff*)
9341   dynamic_linker=no
9342   ;;
9343
9344 # This must be Linux ELF.
9345 linux*)
9346   version_type=linux
9347   need_lib_prefix=no
9348   need_version=no
9349   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9350   soname_spec='${libname}${release}${shared_ext}$major'
9351   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
9352   shlibpath_var=LD_LIBRARY_PATH
9353   shlibpath_overrides_runpath=no
9354   # This implies no fast_install, which is unacceptable.
9355   # Some rework will be needed to allow for fast_install
9356   # before this can be enabled.
9357   hardcode_into_libs=yes
9358
9359   # Append ld.so.conf contents to the search path
9360   if test -f /etc/ld.so.conf; then
9361     lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:,        ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
9362     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
9363   fi
9364
9365   # We used to test for /lib/ld.so.1 and disable shared libraries on
9366   # powerpc, because MkLinux only supported shared libraries with the
9367   # GNU dynamic linker.  Since this was broken with cross compilers,
9368   # most powerpc-linux boxes support dynamic linking these days and
9369   # people can always --disable-shared, the test was removed, and we
9370   # assume the GNU/Linux dynamic linker is in use.
9371   dynamic_linker='GNU/Linux ld.so'
9372   ;;
9373
9374 knetbsd*-gnu)
9375   version_type=linux
9376   need_lib_prefix=no
9377   need_version=no
9378   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9379   soname_spec='${libname}${release}${shared_ext}$major'
9380   shlibpath_var=LD_LIBRARY_PATH
9381   shlibpath_overrides_runpath=no
9382   hardcode_into_libs=yes
9383   dynamic_linker='GNU ld.so'
9384   ;;
9385
9386 netbsd*)
9387   version_type=sunos
9388   need_lib_prefix=no
9389   need_version=no
9390   if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
9391     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9392     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
9393     dynamic_linker='NetBSD (a.out) ld.so'
9394   else
9395     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9396     soname_spec='${libname}${release}${shared_ext}$major'
9397     dynamic_linker='NetBSD ld.elf_so'
9398   fi
9399   shlibpath_var=LD_LIBRARY_PATH
9400   shlibpath_overrides_runpath=yes
9401   hardcode_into_libs=yes
9402   ;;
9403
9404 newsos6)
9405   version_type=linux
9406   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9407   shlibpath_var=LD_LIBRARY_PATH
9408   shlibpath_overrides_runpath=yes
9409   ;;
9410
9411 nto-qnx*)
9412   version_type=linux
9413   need_lib_prefix=no
9414   need_version=no
9415   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9416   soname_spec='${libname}${release}${shared_ext}$major'
9417   shlibpath_var=LD_LIBRARY_PATH
9418   shlibpath_overrides_runpath=yes
9419   ;;
9420
9421 openbsd*)
9422   version_type=sunos
9423   need_lib_prefix=no
9424   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
9425   case $host_os in
9426     openbsd3.3 | openbsd3.3.*) need_version=yes ;;
9427     *)                         need_version=no  ;;
9428   esac
9429   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9430   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
9431   shlibpath_var=LD_LIBRARY_PATH
9432   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
9433     case $host_os in
9434       openbsd2.[89] | openbsd2.[89].*)
9435         shlibpath_overrides_runpath=no
9436         ;;
9437       *)
9438         shlibpath_overrides_runpath=yes
9439         ;;
9440       esac
9441   else
9442     shlibpath_overrides_runpath=yes
9443   fi
9444   ;;
9445
9446 os2*)
9447   libname_spec='$name'
9448   shrext_cmds=".dll"
9449   need_lib_prefix=no
9450   library_names_spec='$libname${shared_ext} $libname.a'
9451   dynamic_linker='OS/2 ld.exe'
9452   shlibpath_var=LIBPATH
9453   ;;
9454
9455 osf3* | osf4* | osf5*)
9456   version_type=osf
9457   need_lib_prefix=no
9458   need_version=no
9459   soname_spec='${libname}${release}${shared_ext}$major'
9460   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9461   shlibpath_var=LD_LIBRARY_PATH
9462   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
9463   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
9464   ;;
9465
9466 sco3.2v5*)
9467   version_type=osf
9468   soname_spec='${libname}${release}${shared_ext}$major'
9469   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9470   shlibpath_var=LD_LIBRARY_PATH
9471   ;;
9472
9473 solaris*)
9474   version_type=linux
9475   need_lib_prefix=no
9476   need_version=no
9477   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9478   soname_spec='${libname}${release}${shared_ext}$major'
9479   shlibpath_var=LD_LIBRARY_PATH
9480   shlibpath_overrides_runpath=yes
9481   hardcode_into_libs=yes
9482   # ldd complains unless libraries are executable
9483   postinstall_cmds='chmod +x $lib'
9484   ;;
9485
9486 sunos4*)
9487   version_type=sunos
9488   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9489   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
9490   shlibpath_var=LD_LIBRARY_PATH
9491   shlibpath_overrides_runpath=yes
9492   if test "$with_gnu_ld" = yes; then
9493     need_lib_prefix=no
9494   fi
9495   need_version=yes
9496   ;;
9497
9498 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
9499   version_type=linux
9500   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9501   soname_spec='${libname}${release}${shared_ext}$major'
9502   shlibpath_var=LD_LIBRARY_PATH
9503   case $host_vendor in
9504     sni)
9505       shlibpath_overrides_runpath=no
9506       need_lib_prefix=no
9507       export_dynamic_flag_spec='${wl}-Blargedynsym'
9508       runpath_var=LD_RUN_PATH
9509       ;;
9510     siemens)
9511       need_lib_prefix=no
9512       ;;
9513     motorola)
9514       need_lib_prefix=no
9515       need_version=no
9516       shlibpath_overrides_runpath=no
9517       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
9518       ;;
9519   esac
9520   ;;
9521
9522 sysv4*MP*)
9523   if test -d /usr/nec ;then
9524     version_type=linux
9525     library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
9526     soname_spec='$libname${shared_ext}.$major'
9527     shlibpath_var=LD_LIBRARY_PATH
9528   fi
9529   ;;
9530
9531 uts4*)
9532   version_type=linux
9533   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9534   soname_spec='${libname}${release}${shared_ext}$major'
9535   shlibpath_var=LD_LIBRARY_PATH
9536   ;;
9537
9538 *)
9539   dynamic_linker=no
9540   ;;
9541 esac
9542 echo "$as_me:$LINENO: result: $dynamic_linker" >&5
9543 echo "${ECHO_T}$dynamic_linker" >&6
9544 test "$dynamic_linker" = no && can_build_shared=no
9545
9546 echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
9547 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6
9548 hardcode_action=
9549 if test -n "$hardcode_libdir_flag_spec" || \
9550    test -n "$runpath_var" || \
9551    test "X$hardcode_automatic" = "Xyes" ; then
9552
9553   # We can hardcode non-existant directories.
9554   if test "$hardcode_direct" != no &&
9555      # If the only mechanism to avoid hardcoding is shlibpath_var, we
9556      # have to relink, otherwise we might link with an installed library
9557      # when we should be linking with a yet-to-be-installed one
9558      ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, )" != no &&
9559      test "$hardcode_minus_L" != no; then
9560     # Linking always hardcodes the temporary library directory.
9561     hardcode_action=relink
9562   else
9563     # We can link without hardcoding, and we can hardcode nonexisting dirs.
9564     hardcode_action=immediate
9565   fi
9566 else
9567   # We cannot hardcode anything, or else we can only hardcode existing
9568   # directories.
9569   hardcode_action=unsupported
9570 fi
9571 echo "$as_me:$LINENO: result: $hardcode_action" >&5
9572 echo "${ECHO_T}$hardcode_action" >&6
9573
9574 if test "$hardcode_action" = relink; then
9575   # Fast installation is not supported
9576   enable_fast_install=no
9577 elif test "$shlibpath_overrides_runpath" = yes ||
9578      test "$enable_shared" = no; then
9579   # Fast installation is not necessary
9580   enable_fast_install=needless
9581 fi
9582
9583 striplib=
9584 old_striplib=
9585 echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5
9586 echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&6
9587 if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
9588   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
9589   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
9590   echo "$as_me:$LINENO: result: yes" >&5
9591 echo "${ECHO_T}yes" >&6
9592 else
9593 # FIXME - insert some real tests, host_os isn't really good enough
9594   case $host_os in
9595    darwin*)
9596        if test -n "$STRIP" ; then
9597          striplib="$STRIP -x"
9598          echo "$as_me:$LINENO: result: yes" >&5
9599 echo "${ECHO_T}yes" >&6
9600        else
9601   echo "$as_me:$LINENO: result: no" >&5
9602 echo "${ECHO_T}no" >&6
9603 fi
9604        ;;
9605    *)
9606   echo "$as_me:$LINENO: result: no" >&5
9607 echo "${ECHO_T}no" >&6
9608     ;;
9609   esac
9610 fi
9611
9612 if test "x$enable_dlopen" != xyes; then
9613   enable_dlopen=unknown
9614   enable_dlopen_self=unknown
9615   enable_dlopen_self_static=unknown
9616 else
9617   lt_cv_dlopen=no
9618   lt_cv_dlopen_libs=
9619
9620   case $host_os in
9621   beos*)
9622     lt_cv_dlopen="load_add_on"
9623     lt_cv_dlopen_libs=
9624     lt_cv_dlopen_self=yes
9625     ;;
9626
9627   mingw* | pw32*)
9628     lt_cv_dlopen="LoadLibrary"
9629     lt_cv_dlopen_libs=
9630    ;;
9631
9632   cygwin*)
9633     lt_cv_dlopen="dlopen"
9634     lt_cv_dlopen_libs=
9635    ;;
9636
9637   darwin*)
9638   # if libdl is installed we need to link against it
9639     echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
9640 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
9641 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
9642   echo $ECHO_N "(cached) $ECHO_C" >&6
9643 else
9644   ac_check_lib_save_LIBS=$LIBS
9645 LIBS="-ldl  $LIBS"
9646 cat >conftest.$ac_ext <<_ACEOF
9647 /* confdefs.h.  */
9648 _ACEOF
9649 cat confdefs.h >>conftest.$ac_ext
9650 cat >>conftest.$ac_ext <<_ACEOF
9651 /* end confdefs.h.  */
9652
9653 /* Override any gcc2 internal prototype to avoid an error.  */
9654 #ifdef __cplusplus
9655 extern "C"
9656 #endif
9657 /* We use char because int might match the return type of a gcc2
9658    builtin and then its argument prototype would still apply.  */
9659 char dlopen ();
9660 int
9661 main ()
9662 {
9663 dlopen ();
9664   ;
9665   return 0;
9666 }
9667 _ACEOF
9668 rm -f conftest.$ac_objext conftest$ac_exeext
9669 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9670   (eval $ac_link) 2>conftest.er1
9671   ac_status=$?
9672   grep -v '^ *+' conftest.er1 >conftest.err
9673   rm -f conftest.er1
9674   cat conftest.err >&5
9675   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9676   (exit $ac_status); } &&
9677          { ac_try='test -z "$ac_c_werror_flag"
9678                          || test ! -s conftest.err'
9679   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9680   (eval $ac_try) 2>&5
9681   ac_status=$?
9682   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9683   (exit $ac_status); }; } &&
9684          { ac_try='test -s conftest$ac_exeext'
9685   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9686   (eval $ac_try) 2>&5
9687   ac_status=$?
9688   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9689   (exit $ac_status); }; }; then
9690   ac_cv_lib_dl_dlopen=yes
9691 else
9692   echo "$as_me: failed program was:" >&5
9693 sed 's/^/| /' conftest.$ac_ext >&5
9694
9695 ac_cv_lib_dl_dlopen=no
9696 fi
9697 rm -f conftest.err conftest.$ac_objext \
9698       conftest$ac_exeext conftest.$ac_ext
9699 LIBS=$ac_check_lib_save_LIBS
9700 fi
9701 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
9702 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
9703 if test $ac_cv_lib_dl_dlopen = yes; then
9704   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
9705 else
9706
9707     lt_cv_dlopen="dyld"
9708     lt_cv_dlopen_libs=
9709     lt_cv_dlopen_self=yes
9710
9711 fi
9712
9713    ;;
9714
9715   *)
9716     echo "$as_me:$LINENO: checking for shl_load" >&5
9717 echo $ECHO_N "checking for shl_load... $ECHO_C" >&6
9718 if test "${ac_cv_func_shl_load+set}" = set; then
9719   echo $ECHO_N "(cached) $ECHO_C" >&6
9720 else
9721   cat >conftest.$ac_ext <<_ACEOF
9722 /* confdefs.h.  */
9723 _ACEOF
9724 cat confdefs.h >>conftest.$ac_ext
9725 cat >>conftest.$ac_ext <<_ACEOF
9726 /* end confdefs.h.  */
9727 /* Define shl_load to an innocuous variant, in case <limits.h> declares shl_load.
9728    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9729 #define shl_load innocuous_shl_load
9730
9731 /* System header to define __stub macros and hopefully few prototypes,
9732     which can conflict with char shl_load (); below.
9733     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9734     <limits.h> exists even on freestanding compilers.  */
9735
9736 #ifdef __STDC__
9737 # include <limits.h>
9738 #else
9739 # include <assert.h>
9740 #endif
9741
9742 #undef shl_load
9743
9744 /* Override any gcc2 internal prototype to avoid an error.  */
9745 #ifdef __cplusplus
9746 extern "C"
9747 {
9748 #endif
9749 /* We use char because int might match the return type of a gcc2
9750    builtin and then its argument prototype would still apply.  */
9751 char shl_load ();
9752 /* The GNU C library defines this for functions which it implements
9753     to always fail with ENOSYS.  Some functions are actually named
9754     something starting with __ and the normal name is an alias.  */
9755 #if defined (__stub_shl_load) || defined (__stub___shl_load)
9756 choke me
9757 #else
9758 char (*f) () = shl_load;
9759 #endif
9760 #ifdef __cplusplus
9761 }
9762 #endif
9763
9764 int
9765 main ()
9766 {
9767 return f != shl_load;
9768   ;
9769   return 0;
9770 }
9771 _ACEOF
9772 rm -f conftest.$ac_objext conftest$ac_exeext
9773 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9774   (eval $ac_link) 2>conftest.er1
9775   ac_status=$?
9776   grep -v '^ *+' conftest.er1 >conftest.err
9777   rm -f conftest.er1
9778   cat conftest.err >&5
9779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9780   (exit $ac_status); } &&
9781          { ac_try='test -z "$ac_c_werror_flag"
9782                          || test ! -s conftest.err'
9783   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9784   (eval $ac_try) 2>&5
9785   ac_status=$?
9786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9787   (exit $ac_status); }; } &&
9788          { ac_try='test -s conftest$ac_exeext'
9789   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9790   (eval $ac_try) 2>&5
9791   ac_status=$?
9792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9793   (exit $ac_status); }; }; then
9794   ac_cv_func_shl_load=yes
9795 else
9796   echo "$as_me: failed program was:" >&5
9797 sed 's/^/| /' conftest.$ac_ext >&5
9798
9799 ac_cv_func_shl_load=no
9800 fi
9801 rm -f conftest.err conftest.$ac_objext \
9802       conftest$ac_exeext conftest.$ac_ext
9803 fi
9804 echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5
9805 echo "${ECHO_T}$ac_cv_func_shl_load" >&6
9806 if test $ac_cv_func_shl_load = yes; then
9807   lt_cv_dlopen="shl_load"
9808 else
9809   echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
9810 echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6
9811 if test "${ac_cv_lib_dld_shl_load+set}" = set; then
9812   echo $ECHO_N "(cached) $ECHO_C" >&6
9813 else
9814   ac_check_lib_save_LIBS=$LIBS
9815 LIBS="-ldld  $LIBS"
9816 cat >conftest.$ac_ext <<_ACEOF
9817 /* confdefs.h.  */
9818 _ACEOF
9819 cat confdefs.h >>conftest.$ac_ext
9820 cat >>conftest.$ac_ext <<_ACEOF
9821 /* end confdefs.h.  */
9822
9823 /* Override any gcc2 internal prototype to avoid an error.  */
9824 #ifdef __cplusplus
9825 extern "C"
9826 #endif
9827 /* We use char because int might match the return type of a gcc2
9828    builtin and then its argument prototype would still apply.  */
9829 char shl_load ();
9830 int
9831 main ()
9832 {
9833 shl_load ();
9834   ;
9835   return 0;
9836 }
9837 _ACEOF
9838 rm -f conftest.$ac_objext conftest$ac_exeext
9839 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9840   (eval $ac_link) 2>conftest.er1
9841   ac_status=$?
9842   grep -v '^ *+' conftest.er1 >conftest.err
9843   rm -f conftest.er1
9844   cat conftest.err >&5
9845   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9846   (exit $ac_status); } &&
9847          { ac_try='test -z "$ac_c_werror_flag"
9848                          || test ! -s conftest.err'
9849   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9850   (eval $ac_try) 2>&5
9851   ac_status=$?
9852   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9853   (exit $ac_status); }; } &&
9854          { ac_try='test -s conftest$ac_exeext'
9855   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9856   (eval $ac_try) 2>&5
9857   ac_status=$?
9858   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9859   (exit $ac_status); }; }; then
9860   ac_cv_lib_dld_shl_load=yes
9861 else
9862   echo "$as_me: failed program was:" >&5
9863 sed 's/^/| /' conftest.$ac_ext >&5
9864
9865 ac_cv_lib_dld_shl_load=no
9866 fi
9867 rm -f conftest.err conftest.$ac_objext \
9868       conftest$ac_exeext conftest.$ac_ext
9869 LIBS=$ac_check_lib_save_LIBS
9870 fi
9871 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
9872 echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6
9873 if test $ac_cv_lib_dld_shl_load = yes; then
9874   lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"
9875 else
9876   echo "$as_me:$LINENO: checking for dlopen" >&5
9877 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6
9878 if test "${ac_cv_func_dlopen+set}" = set; then
9879   echo $ECHO_N "(cached) $ECHO_C" >&6
9880 else
9881   cat >conftest.$ac_ext <<_ACEOF
9882 /* confdefs.h.  */
9883 _ACEOF
9884 cat confdefs.h >>conftest.$ac_ext
9885 cat >>conftest.$ac_ext <<_ACEOF
9886 /* end confdefs.h.  */
9887 /* Define dlopen to an innocuous variant, in case <limits.h> declares dlopen.
9888    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9889 #define dlopen innocuous_dlopen
9890
9891 /* System header to define __stub macros and hopefully few prototypes,
9892     which can conflict with char dlopen (); below.
9893     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9894     <limits.h> exists even on freestanding compilers.  */
9895
9896 #ifdef __STDC__
9897 # include <limits.h>
9898 #else
9899 # include <assert.h>
9900 #endif
9901
9902 #undef dlopen
9903
9904 /* Override any gcc2 internal prototype to avoid an error.  */
9905 #ifdef __cplusplus
9906 extern "C"
9907 {
9908 #endif
9909 /* We use char because int might match the return type of a gcc2
9910    builtin and then its argument prototype would still apply.  */
9911 char dlopen ();
9912 /* The GNU C library defines this for functions which it implements
9913     to always fail with ENOSYS.  Some functions are actually named
9914     something starting with __ and the normal name is an alias.  */
9915 #if defined (__stub_dlopen) || defined (__stub___dlopen)
9916 choke me
9917 #else
9918 char (*f) () = dlopen;
9919 #endif
9920 #ifdef __cplusplus
9921 }
9922 #endif
9923
9924 int
9925 main ()
9926 {
9927 return f != dlopen;
9928   ;
9929   return 0;
9930 }
9931 _ACEOF
9932 rm -f conftest.$ac_objext conftest$ac_exeext
9933 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9934   (eval $ac_link) 2>conftest.er1
9935   ac_status=$?
9936   grep -v '^ *+' conftest.er1 >conftest.err
9937   rm -f conftest.er1
9938   cat conftest.err >&5
9939   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9940   (exit $ac_status); } &&
9941          { ac_try='test -z "$ac_c_werror_flag"
9942                          || test ! -s conftest.err'
9943   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9944   (eval $ac_try) 2>&5
9945   ac_status=$?
9946   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9947   (exit $ac_status); }; } &&
9948          { ac_try='test -s conftest$ac_exeext'
9949   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9950   (eval $ac_try) 2>&5
9951   ac_status=$?
9952   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9953   (exit $ac_status); }; }; then
9954   ac_cv_func_dlopen=yes
9955 else
9956   echo "$as_me: failed program was:" >&5
9957 sed 's/^/| /' conftest.$ac_ext >&5
9958
9959 ac_cv_func_dlopen=no
9960 fi
9961 rm -f conftest.err conftest.$ac_objext \
9962       conftest$ac_exeext conftest.$ac_ext
9963 fi
9964 echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
9965 echo "${ECHO_T}$ac_cv_func_dlopen" >&6
9966 if test $ac_cv_func_dlopen = yes; then
9967   lt_cv_dlopen="dlopen"
9968 else
9969   echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
9970 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
9971 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
9972   echo $ECHO_N "(cached) $ECHO_C" >&6
9973 else
9974   ac_check_lib_save_LIBS=$LIBS
9975 LIBS="-ldl  $LIBS"
9976 cat >conftest.$ac_ext <<_ACEOF
9977 /* confdefs.h.  */
9978 _ACEOF
9979 cat confdefs.h >>conftest.$ac_ext
9980 cat >>conftest.$ac_ext <<_ACEOF
9981 /* end confdefs.h.  */
9982
9983 /* Override any gcc2 internal prototype to avoid an error.  */
9984 #ifdef __cplusplus
9985 extern "C"
9986 #endif
9987 /* We use char because int might match the return type of a gcc2
9988    builtin and then its argument prototype would still apply.  */
9989 char dlopen ();
9990 int
9991 main ()
9992 {
9993 dlopen ();
9994   ;
9995   return 0;
9996 }
9997 _ACEOF
9998 rm -f conftest.$ac_objext conftest$ac_exeext
9999 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10000   (eval $ac_link) 2>conftest.er1
10001   ac_status=$?
10002   grep -v '^ *+' conftest.er1 >conftest.err
10003   rm -f conftest.er1
10004   cat conftest.err >&5
10005   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10006   (exit $ac_status); } &&
10007          { ac_try='test -z "$ac_c_werror_flag"
10008                          || test ! -s conftest.err'
10009   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10010   (eval $ac_try) 2>&5
10011   ac_status=$?
10012   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10013   (exit $ac_status); }; } &&
10014          { ac_try='test -s conftest$ac_exeext'
10015   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10016   (eval $ac_try) 2>&5
10017   ac_status=$?
10018   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10019   (exit $ac_status); }; }; then
10020   ac_cv_lib_dl_dlopen=yes
10021 else
10022   echo "$as_me: failed program was:" >&5
10023 sed 's/^/| /' conftest.$ac_ext >&5
10024
10025 ac_cv_lib_dl_dlopen=no
10026 fi
10027 rm -f conftest.err conftest.$ac_objext \
10028       conftest$ac_exeext conftest.$ac_ext
10029 LIBS=$ac_check_lib_save_LIBS
10030 fi
10031 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
10032 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
10033 if test $ac_cv_lib_dl_dlopen = yes; then
10034   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
10035 else
10036   echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5
10037 echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6
10038 if test "${ac_cv_lib_svld_dlopen+set}" = set; then
10039   echo $ECHO_N "(cached) $ECHO_C" >&6
10040 else
10041   ac_check_lib_save_LIBS=$LIBS
10042 LIBS="-lsvld  $LIBS"
10043 cat >conftest.$ac_ext <<_ACEOF
10044 /* confdefs.h.  */
10045 _ACEOF
10046 cat confdefs.h >>conftest.$ac_ext
10047 cat >>conftest.$ac_ext <<_ACEOF
10048 /* end confdefs.h.  */
10049
10050 /* Override any gcc2 internal prototype to avoid an error.  */
10051 #ifdef __cplusplus
10052 extern "C"
10053 #endif
10054 /* We use char because int might match the return type of a gcc2
10055    builtin and then its argument prototype would still apply.  */
10056 char dlopen ();
10057 int
10058 main ()
10059 {
10060 dlopen ();
10061   ;
10062   return 0;
10063 }
10064 _ACEOF
10065 rm -f conftest.$ac_objext conftest$ac_exeext
10066 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10067   (eval $ac_link) 2>conftest.er1
10068   ac_status=$?
10069   grep -v '^ *+' conftest.er1 >conftest.err
10070   rm -f conftest.er1
10071   cat conftest.err >&5
10072   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10073   (exit $ac_status); } &&
10074          { ac_try='test -z "$ac_c_werror_flag"
10075                          || test ! -s conftest.err'
10076   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10077   (eval $ac_try) 2>&5
10078   ac_status=$?
10079   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10080   (exit $ac_status); }; } &&
10081          { ac_try='test -s conftest$ac_exeext'
10082   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10083   (eval $ac_try) 2>&5
10084   ac_status=$?
10085   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10086   (exit $ac_status); }; }; then
10087   ac_cv_lib_svld_dlopen=yes
10088 else
10089   echo "$as_me: failed program was:" >&5
10090 sed 's/^/| /' conftest.$ac_ext >&5
10091
10092 ac_cv_lib_svld_dlopen=no
10093 fi
10094 rm -f conftest.err conftest.$ac_objext \
10095       conftest$ac_exeext conftest.$ac_ext
10096 LIBS=$ac_check_lib_save_LIBS
10097 fi
10098 echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5
10099 echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6
10100 if test $ac_cv_lib_svld_dlopen = yes; then
10101   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
10102 else
10103   echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5
10104 echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6
10105 if test "${ac_cv_lib_dld_dld_link+set}" = set; then
10106   echo $ECHO_N "(cached) $ECHO_C" >&6
10107 else
10108   ac_check_lib_save_LIBS=$LIBS
10109 LIBS="-ldld  $LIBS"
10110 cat >conftest.$ac_ext <<_ACEOF
10111 /* confdefs.h.  */
10112 _ACEOF
10113 cat confdefs.h >>conftest.$ac_ext
10114 cat >>conftest.$ac_ext <<_ACEOF
10115 /* end confdefs.h.  */
10116
10117 /* Override any gcc2 internal prototype to avoid an error.  */
10118 #ifdef __cplusplus
10119 extern "C"
10120 #endif
10121 /* We use char because int might match the return type of a gcc2
10122    builtin and then its argument prototype would still apply.  */
10123 char dld_link ();
10124 int
10125 main ()
10126 {
10127 dld_link ();
10128   ;
10129   return 0;
10130 }
10131 _ACEOF
10132 rm -f conftest.$ac_objext conftest$ac_exeext
10133 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10134   (eval $ac_link) 2>conftest.er1
10135   ac_status=$?
10136   grep -v '^ *+' conftest.er1 >conftest.err
10137   rm -f conftest.er1
10138   cat conftest.err >&5
10139   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10140   (exit $ac_status); } &&
10141          { ac_try='test -z "$ac_c_werror_flag"
10142                          || test ! -s conftest.err'
10143   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10144   (eval $ac_try) 2>&5
10145   ac_status=$?
10146   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10147   (exit $ac_status); }; } &&
10148          { ac_try='test -s conftest$ac_exeext'
10149   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10150   (eval $ac_try) 2>&5
10151   ac_status=$?
10152   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10153   (exit $ac_status); }; }; then
10154   ac_cv_lib_dld_dld_link=yes
10155 else
10156   echo "$as_me: failed program was:" >&5
10157 sed 's/^/| /' conftest.$ac_ext >&5
10158
10159 ac_cv_lib_dld_dld_link=no
10160 fi
10161 rm -f conftest.err conftest.$ac_objext \
10162       conftest$ac_exeext conftest.$ac_ext
10163 LIBS=$ac_check_lib_save_LIBS
10164 fi
10165 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5
10166 echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6
10167 if test $ac_cv_lib_dld_dld_link = yes; then
10168   lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"
10169 fi
10170
10171
10172 fi
10173
10174
10175 fi
10176
10177
10178 fi
10179
10180
10181 fi
10182
10183
10184 fi
10185
10186     ;;
10187   esac
10188
10189   if test "x$lt_cv_dlopen" != xno; then
10190     enable_dlopen=yes
10191   else
10192     enable_dlopen=no
10193   fi
10194
10195   case $lt_cv_dlopen in
10196   dlopen)
10197     save_CPPFLAGS="$CPPFLAGS"
10198     test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
10199
10200     save_LDFLAGS="$LDFLAGS"
10201     eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
10202
10203     save_LIBS="$LIBS"
10204     LIBS="$lt_cv_dlopen_libs $LIBS"
10205
10206     echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5
10207 echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6
10208 if test "${lt_cv_dlopen_self+set}" = set; then
10209   echo $ECHO_N "(cached) $ECHO_C" >&6
10210 else
10211           if test "$cross_compiling" = yes; then :
10212   lt_cv_dlopen_self=cross
10213 else
10214   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10215   lt_status=$lt_dlunknown
10216   cat > conftest.$ac_ext <<EOF
10217 #line 10217 "configure"
10218 #include "confdefs.h"
10219
10220 #if HAVE_DLFCN_H
10221 #include <dlfcn.h>
10222 #endif
10223
10224 #include <stdio.h>
10225
10226 #ifdef RTLD_GLOBAL
10227 #  define LT_DLGLOBAL           RTLD_GLOBAL
10228 #else
10229 #  ifdef DL_GLOBAL
10230 #    define LT_DLGLOBAL         DL_GLOBAL
10231 #  else
10232 #    define LT_DLGLOBAL         0
10233 #  endif
10234 #endif
10235
10236 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
10237    find out it does not work in some platform. */
10238 #ifndef LT_DLLAZY_OR_NOW
10239 #  ifdef RTLD_LAZY
10240 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
10241 #  else
10242 #    ifdef DL_LAZY
10243 #      define LT_DLLAZY_OR_NOW          DL_LAZY
10244 #    else
10245 #      ifdef RTLD_NOW
10246 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
10247 #      else
10248 #        ifdef DL_NOW
10249 #          define LT_DLLAZY_OR_NOW      DL_NOW
10250 #        else
10251 #          define LT_DLLAZY_OR_NOW      0
10252 #        endif
10253 #      endif
10254 #    endif
10255 #  endif
10256 #endif
10257
10258 #ifdef __cplusplus
10259 extern "C" void exit (int);
10260 #endif
10261
10262 void fnord() { int i=42;}
10263 int main ()
10264 {
10265   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10266   int status = $lt_dlunknown;
10267
10268   if (self)
10269     {
10270       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
10271       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
10272       /* dlclose (self); */
10273     }
10274
10275     exit (status);
10276 }
10277 EOF
10278   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10279   (eval $ac_link) 2>&5
10280   ac_status=$?
10281   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10282   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
10283     (./conftest; exit; ) >&5 2>/dev/null
10284     lt_status=$?
10285     case x$lt_status in
10286       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
10287       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
10288       x$lt_unknown|x*) lt_cv_dlopen_self=no ;;
10289     esac
10290   else :
10291     # compilation failed
10292     lt_cv_dlopen_self=no
10293   fi
10294 fi
10295 rm -fr conftest*
10296
10297
10298 fi
10299 echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5
10300 echo "${ECHO_T}$lt_cv_dlopen_self" >&6
10301
10302     if test "x$lt_cv_dlopen_self" = xyes; then
10303       LDFLAGS="$LDFLAGS $link_static_flag"
10304       echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5
10305 echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6
10306 if test "${lt_cv_dlopen_self_static+set}" = set; then
10307   echo $ECHO_N "(cached) $ECHO_C" >&6
10308 else
10309           if test "$cross_compiling" = yes; then :
10310   lt_cv_dlopen_self_static=cross
10311 else
10312   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10313   lt_status=$lt_dlunknown
10314   cat > conftest.$ac_ext <<EOF
10315 #line 10315 "configure"
10316 #include "confdefs.h"
10317
10318 #if HAVE_DLFCN_H
10319 #include <dlfcn.h>
10320 #endif
10321
10322 #include <stdio.h>
10323
10324 #ifdef RTLD_GLOBAL
10325 #  define LT_DLGLOBAL           RTLD_GLOBAL
10326 #else
10327 #  ifdef DL_GLOBAL
10328 #    define LT_DLGLOBAL         DL_GLOBAL
10329 #  else
10330 #    define LT_DLGLOBAL         0
10331 #  endif
10332 #endif
10333
10334 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
10335    find out it does not work in some platform. */
10336 #ifndef LT_DLLAZY_OR_NOW
10337 #  ifdef RTLD_LAZY
10338 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
10339 #  else
10340 #    ifdef DL_LAZY
10341 #      define LT_DLLAZY_OR_NOW          DL_LAZY
10342 #    else
10343 #      ifdef RTLD_NOW
10344 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
10345 #      else
10346 #        ifdef DL_NOW
10347 #          define LT_DLLAZY_OR_NOW      DL_NOW
10348 #        else
10349 #          define LT_DLLAZY_OR_NOW      0
10350 #        endif
10351 #      endif
10352 #    endif
10353 #  endif
10354 #endif
10355
10356 #ifdef __cplusplus
10357 extern "C" void exit (int);
10358 #endif
10359
10360 void fnord() { int i=42;}
10361 int main ()
10362 {
10363   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10364   int status = $lt_dlunknown;
10365
10366   if (self)
10367     {
10368       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
10369       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
10370       /* dlclose (self); */
10371     }
10372
10373     exit (status);
10374 }
10375 EOF
10376   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10377   (eval $ac_link) 2>&5
10378   ac_status=$?
10379   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10380   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
10381     (./conftest; exit; ) >&5 2>/dev/null
10382     lt_status=$?
10383     case x$lt_status in
10384       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
10385       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
10386       x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;;
10387     esac
10388   else :
10389     # compilation failed
10390     lt_cv_dlopen_self_static=no
10391   fi
10392 fi
10393 rm -fr conftest*
10394
10395
10396 fi
10397 echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5
10398 echo "${ECHO_T}$lt_cv_dlopen_self_static" >&6
10399     fi
10400
10401     CPPFLAGS="$save_CPPFLAGS"
10402     LDFLAGS="$save_LDFLAGS"
10403     LIBS="$save_LIBS"
10404     ;;
10405   esac
10406
10407   case $lt_cv_dlopen_self in
10408   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
10409   *) enable_dlopen_self=unknown ;;
10410   esac
10411
10412   case $lt_cv_dlopen_self_static in
10413   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
10414   *) enable_dlopen_self_static=unknown ;;
10415   esac
10416 fi
10417
10418
10419 # Report which librarie types wil actually be built
10420 echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
10421 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6
10422 echo "$as_me:$LINENO: result: $can_build_shared" >&5
10423 echo "${ECHO_T}$can_build_shared" >&6
10424
10425 echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
10426 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6
10427 test "$can_build_shared" = "no" && enable_shared=no
10428
10429 # On AIX, shared libraries and static libraries use the same namespace, and
10430 # are all built from PIC.
10431 case $host_os in
10432 aix3*)
10433   test "$enable_shared" = yes && enable_static=no
10434   if test -n "$RANLIB"; then
10435     archive_cmds="$archive_cmds~\$RANLIB \$lib"
10436     postinstall_cmds='$RANLIB $lib'
10437   fi
10438   ;;
10439
10440 aix4* | aix5*)
10441   if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
10442     test "$enable_shared" = yes && enable_static=no
10443   fi
10444     ;;
10445 esac
10446 echo "$as_me:$LINENO: result: $enable_shared" >&5
10447 echo "${ECHO_T}$enable_shared" >&6
10448
10449 echo "$as_me:$LINENO: checking whether to build static libraries" >&5
10450 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6
10451 # Make sure either enable_shared or enable_static is yes.
10452 test "$enable_shared" = yes || enable_static=yes
10453 echo "$as_me:$LINENO: result: $enable_static" >&5
10454 echo "${ECHO_T}$enable_static" >&6
10455
10456 # The else clause should only fire when bootstrapping the
10457 # libtool distribution, otherwise you forgot to ship ltmain.sh
10458 # with your package, and you will get complaints that there are
10459 # no rules to generate ltmain.sh.
10460 if test -f "$ltmain"; then
10461   # See if we are running on zsh, and set the options which allow our commands through
10462   # without removal of \ escapes.
10463   if test -n "${ZSH_VERSION+set}" ; then
10464     setopt NO_GLOB_SUBST
10465   fi
10466   # Now quote all the things that may contain metacharacters while being
10467   # careful not to overquote the AC_SUBSTed values.  We take copies of the
10468   # variables and quote the copies for generation of the libtool script.
10469   for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
10470     SED SHELL STRIP \
10471     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
10472     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
10473     deplibs_check_method reload_flag reload_cmds need_locks \
10474     lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
10475     lt_cv_sys_global_symbol_to_c_name_address \
10476     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
10477     old_postinstall_cmds old_postuninstall_cmds \
10478     compiler \
10479     CC \
10480     LD \
10481     lt_prog_compiler_wl \
10482     lt_prog_compiler_pic \
10483     lt_prog_compiler_static \
10484     lt_prog_compiler_no_builtin_flag \
10485     export_dynamic_flag_spec \
10486     thread_safe_flag_spec \
10487     whole_archive_flag_spec \
10488     enable_shared_with_static_runtimes \
10489     old_archive_cmds \
10490     old_archive_from_new_cmds \
10491     predep_objects \
10492     postdep_objects \
10493     predeps \
10494     postdeps \
10495     compiler_lib_search_path \
10496     archive_cmds \
10497     archive_expsym_cmds \
10498     postinstall_cmds \
10499     postuninstall_cmds \
10500     old_archive_from_expsyms_cmds \
10501     allow_undefined_flag \
10502     no_undefined_flag \
10503     export_symbols_cmds \
10504     hardcode_libdir_flag_spec \
10505     hardcode_libdir_flag_spec_ld \
10506     hardcode_libdir_separator \
10507     hardcode_automatic \
10508     module_cmds \
10509     module_expsym_cmds \
10510     lt_cv_prog_compiler_c_o \
10511     exclude_expsyms \
10512     include_expsyms; do
10513
10514     case $var in
10515     old_archive_cmds | \
10516     old_archive_from_new_cmds | \
10517     archive_cmds | \
10518     archive_expsym_cmds | \
10519     module_cmds | \
10520     module_expsym_cmds | \
10521     old_archive_from_expsyms_cmds | \
10522     export_symbols_cmds | \
10523     extract_expsyms_cmds | reload_cmds | finish_cmds | \
10524     postinstall_cmds | postuninstall_cmds | \
10525     old_postinstall_cmds | old_postuninstall_cmds | \
10526     sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
10527       # Double-quote double-evaled strings.
10528       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
10529       ;;
10530     *)
10531       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
10532       ;;
10533     esac
10534   done
10535
10536   case $lt_echo in
10537   *'\$0 --fallback-echo"')
10538     lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
10539     ;;
10540   esac
10541
10542 cfgfile="${ofile}T"
10543   trap "$rm \"$cfgfile\"; exit 1" 1 2 15
10544   $rm -f "$cfgfile"
10545   { echo "$as_me:$LINENO: creating $ofile" >&5
10546 echo "$as_me: creating $ofile" >&6;}
10547
10548   cat <<__EOF__ >> "$cfgfile"
10549 #! $SHELL
10550
10551 # `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
10552 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
10553 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
10554 #
10555 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
10556 # Free Software Foundation, Inc.
10557 #
10558 # This file is part of GNU Libtool:
10559 # Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
10560 #
10561 # This program is free software; you can redistribute it and/or modify
10562 # it under the terms of the GNU General Public License as published by
10563 # the Free Software Foundation; either version 2 of the License, or
10564 # (at your option) any later version.
10565 #
10566 # This program is distributed in the hope that it will be useful, but
10567 # WITHOUT ANY WARRANTY; without even the implied warranty of
10568 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
10569 # General Public License for more details.
10570 #
10571 # You should have received a copy of the GNU General Public License
10572 # along with this program; if not, write to the Free Software
10573 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
10574 #
10575 # As a special exception to the GNU General Public License, if you
10576 # distribute this file as part of a program that contains a
10577 # configuration script generated by Autoconf, you may include it under
10578 # the same distribution terms that you use for the rest of that program.
10579
10580 # A sed program that does not truncate output.
10581 SED=$lt_SED
10582
10583 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
10584 Xsed="$SED -e 1s/^X//"
10585
10586 # The HP-UX ksh and POSIX shell print the target directory to stdout
10587 # if CDPATH is set.
10588 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
10589
10590 # The names of the tagged configurations supported by this script.
10591 available_tags=
10592
10593 # ### BEGIN LIBTOOL CONFIG
10594
10595 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
10596
10597 # Shell to use when invoking shell scripts.
10598 SHELL=$lt_SHELL
10599
10600 # Whether or not to build shared libraries.
10601 build_libtool_libs=$enable_shared
10602
10603 # Whether or not to build static libraries.
10604 build_old_libs=$enable_static
10605
10606 # Whether or not to add -lc for building shared libraries.
10607 build_libtool_need_lc=$archive_cmds_need_lc
10608
10609 # Whether or not to disallow shared libs when runtime libs are static
10610 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
10611
10612 # Whether or not to optimize for fast installation.
10613 fast_install=$enable_fast_install
10614
10615 # The host system.
10616 host_alias=$host_alias
10617 host=$host
10618 host_os=$host_os
10619
10620 # The build system.
10621 build_alias=$build_alias
10622 build=$build
10623 build_os=$build_os
10624
10625 # An echo program that does not interpret backslashes.
10626 echo=$lt_echo
10627
10628 # The archiver.
10629 AR=$lt_AR
10630 AR_FLAGS=$lt_AR_FLAGS
10631
10632 # A C compiler.
10633 LTCC=$lt_LTCC
10634
10635 # A language-specific compiler.
10636 CC=$lt_compiler
10637
10638 # Is the compiler the GNU C compiler?
10639 with_gcc=$GCC
10640
10641 # An ERE matcher.
10642 EGREP=$lt_EGREP
10643
10644 # The linker used to build libraries.
10645 LD=$lt_LD
10646
10647 # Whether we need hard or soft links.
10648 LN_S=$lt_LN_S
10649
10650 # A BSD-compatible nm program.
10651 NM=$lt_NM
10652
10653 # A symbol stripping program
10654 STRIP=$lt_STRIP
10655
10656 # Used to examine libraries when file_magic_cmd begins "file"
10657 MAGIC_CMD=$MAGIC_CMD
10658
10659 # Used on cygwin: DLL creation program.
10660 DLLTOOL="$DLLTOOL"
10661
10662 # Used on cygwin: object dumper.
10663 OBJDUMP="$OBJDUMP"
10664
10665 # Used on cygwin: assembler.
10666 AS="$AS"
10667
10668 # The name of the directory that contains temporary libtool files.
10669 objdir=$objdir
10670
10671 # How to create reloadable object files.
10672 reload_flag=$lt_reload_flag
10673 reload_cmds=$lt_reload_cmds
10674
10675 # How to pass a linker flag through the compiler.
10676 wl=$lt_lt_prog_compiler_wl
10677
10678 # Object file suffix (normally "o").
10679 objext="$ac_objext"
10680
10681 # Old archive suffix (normally "a").
10682 libext="$libext"
10683
10684 # Shared library suffix (normally ".so").
10685 shrext_cmds='$shrext_cmds'
10686
10687 # Executable file suffix (normally "").
10688 exeext="$exeext"
10689
10690 # Additional compiler flags for building library objects.
10691 pic_flag=$lt_lt_prog_compiler_pic
10692 pic_mode=$pic_mode
10693
10694 # What is the maximum length of a command?
10695 max_cmd_len=$lt_cv_sys_max_cmd_len
10696
10697 # Does compiler simultaneously support -c and -o options?
10698 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
10699
10700 # Must we lock files when doing compilation?
10701 need_locks=$lt_need_locks
10702
10703 # Do we need the lib prefix for modules?
10704 need_lib_prefix=$need_lib_prefix
10705
10706 # Do we need a version for libraries?
10707 need_version=$need_version
10708
10709 # Whether dlopen is supported.
10710 dlopen_support=$enable_dlopen
10711
10712 # Whether dlopen of programs is supported.
10713 dlopen_self=$enable_dlopen_self
10714
10715 # Whether dlopen of statically linked programs is supported.
10716 dlopen_self_static=$enable_dlopen_self_static
10717
10718 # Compiler flag to prevent dynamic linking.
10719 link_static_flag=$lt_lt_prog_compiler_static
10720
10721 # Compiler flag to turn off builtin functions.
10722 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
10723
10724 # Compiler flag to allow reflexive dlopens.
10725 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
10726
10727 # Compiler flag to generate shared objects directly from archives.
10728 whole_archive_flag_spec=$lt_whole_archive_flag_spec
10729
10730 # Compiler flag to generate thread-safe objects.
10731 thread_safe_flag_spec=$lt_thread_safe_flag_spec
10732
10733 # Library versioning type.
10734 version_type=$version_type
10735
10736 # Format of library name prefix.
10737 libname_spec=$lt_libname_spec
10738
10739 # List of archive names.  First name is the real one, the rest are links.
10740 # The last name is the one that the linker finds with -lNAME.
10741 library_names_spec=$lt_library_names_spec
10742
10743 # The coded name of the library, if different from the real name.
10744 soname_spec=$lt_soname_spec
10745
10746 # Commands used to build and install an old-style archive.
10747 RANLIB=$lt_RANLIB
10748 old_archive_cmds=$lt_old_archive_cmds
10749 old_postinstall_cmds=$lt_old_postinstall_cmds
10750 old_postuninstall_cmds=$lt_old_postuninstall_cmds
10751
10752 # Create an old-style archive from a shared archive.
10753 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
10754
10755 # Create a temporary old-style archive to link instead of a shared archive.
10756 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
10757
10758 # Commands used to build and install a shared archive.
10759 archive_cmds=$lt_archive_cmds
10760 archive_expsym_cmds=$lt_archive_expsym_cmds
10761 postinstall_cmds=$lt_postinstall_cmds
10762 postuninstall_cmds=$lt_postuninstall_cmds
10763
10764 # Commands used to build a loadable module (assumed same as above if empty)
10765 module_cmds=$lt_module_cmds
10766 module_expsym_cmds=$lt_module_expsym_cmds
10767
10768 # Commands to strip libraries.
10769 old_striplib=$lt_old_striplib
10770 striplib=$lt_striplib
10771
10772 # Dependencies to place before the objects being linked to create a
10773 # shared library.
10774 predep_objects=$lt_predep_objects
10775
10776 # Dependencies to place after the objects being linked to create a
10777 # shared library.
10778 postdep_objects=$lt_postdep_objects
10779
10780 # Dependencies to place before the objects being linked to create a
10781 # shared library.
10782 predeps=$lt_predeps
10783
10784 # Dependencies to place after the objects being linked to create a
10785 # shared library.
10786 postdeps=$lt_postdeps
10787
10788 # The library search path used internally by the compiler when linking
10789 # a shared library.
10790 compiler_lib_search_path=$lt_compiler_lib_search_path
10791
10792 # Method to check whether dependent libraries are shared objects.
10793 deplibs_check_method=$lt_deplibs_check_method
10794
10795 # Command to use when deplibs_check_method == file_magic.
10796 file_magic_cmd=$lt_file_magic_cmd
10797
10798 # Flag that allows shared libraries with undefined symbols to be built.
10799 allow_undefined_flag=$lt_allow_undefined_flag
10800
10801 # Flag that forces no undefined symbols.
10802 no_undefined_flag=$lt_no_undefined_flag
10803
10804 # Commands used to finish a libtool library installation in a directory.
10805 finish_cmds=$lt_finish_cmds
10806
10807 # Same as above, but a single script fragment to be evaled but not shown.
10808 finish_eval=$lt_finish_eval
10809
10810 # Take the output of nm and produce a listing of raw symbols and C names.
10811 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
10812
10813 # Transform the output of nm in a proper C declaration
10814 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
10815
10816 # Transform the output of nm in a C name address pair
10817 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
10818
10819 # This is the shared library runtime path variable.
10820 runpath_var=$runpath_var
10821
10822 # This is the shared library path variable.
10823 shlibpath_var=$shlibpath_var
10824
10825 # Is shlibpath searched before the hard-coded library search path?
10826 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
10827
10828 # How to hardcode a shared library path into an executable.
10829 hardcode_action=$hardcode_action
10830
10831 # Whether we should hardcode library paths into libraries.
10832 hardcode_into_libs=$hardcode_into_libs
10833
10834 # Flag to hardcode \$libdir into a binary during linking.
10835 # This must work even if \$libdir does not exist.
10836 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
10837
10838 # If ld is used when linking, flag to hardcode \$libdir into
10839 # a binary during linking. This must work even if \$libdir does
10840 # not exist.
10841 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
10842
10843 # Whether we need a single -rpath flag with a separated argument.
10844 hardcode_libdir_separator=$lt_hardcode_libdir_separator
10845
10846 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
10847 # resulting binary.
10848 hardcode_direct=$hardcode_direct
10849
10850 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
10851 # resulting binary.
10852 hardcode_minus_L=$hardcode_minus_L
10853
10854 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
10855 # the resulting binary.
10856 hardcode_shlibpath_var=$hardcode_shlibpath_var
10857
10858 # Set to yes if building a shared library automatically hardcodes DIR into the library
10859 # and all subsequent libraries and executables linked against it.
10860 hardcode_automatic=$hardcode_automatic
10861
10862 # Variables whose values should be saved in libtool wrapper scripts and
10863 # restored at relink time.
10864 variables_saved_for_relink="$variables_saved_for_relink"
10865
10866 # Whether libtool must link a program against all its dependency libraries.
10867 link_all_deplibs=$link_all_deplibs
10868
10869 # Compile-time system search path for libraries
10870 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
10871
10872 # Run-time system search path for libraries
10873 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
10874
10875 # Fix the shell variable \$srcfile for the compiler.
10876 fix_srcfile_path="$fix_srcfile_path"
10877
10878 # Set to yes if exported symbols are required.
10879 always_export_symbols=$always_export_symbols
10880
10881 # The commands to list exported symbols.
10882 export_symbols_cmds=$lt_export_symbols_cmds
10883
10884 # The commands to extract the exported symbol list from a shared archive.
10885 extract_expsyms_cmds=$lt_extract_expsyms_cmds
10886
10887 # Symbols that should not be listed in the preloaded symbols.
10888 exclude_expsyms=$lt_exclude_expsyms
10889
10890 # Symbols that must always be exported.
10891 include_expsyms=$lt_include_expsyms
10892
10893 # ### END LIBTOOL CONFIG
10894
10895 __EOF__
10896
10897
10898   case $host_os in
10899   aix3*)
10900     cat <<\EOF >> "$cfgfile"
10901
10902 # AIX sometimes has problems with the GCC collect2 program.  For some
10903 # reason, if we set the COLLECT_NAMES environment variable, the problems
10904 # vanish in a puff of smoke.
10905 if test "X${COLLECT_NAMES+set}" != Xset; then
10906   COLLECT_NAMES=
10907   export COLLECT_NAMES
10908 fi
10909 EOF
10910     ;;
10911   esac
10912
10913   # We use sed instead of cat because bash on DJGPP gets confused if
10914   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
10915   # text mode, it properly converts lines to CR/LF.  This bash problem
10916   # is reportedly fixed, but why not run on old versions too?
10917   sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
10918
10919   mv -f "$cfgfile" "$ofile" || \
10920     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
10921   chmod +x "$ofile"
10922
10923 else
10924   # If there is no Makefile yet, we rely on a make rule to execute
10925   # `config.status --recheck' to rerun these tests and create the
10926   # libtool script then.
10927   ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
10928   if test -f "$ltmain_in"; then
10929     test -f Makefile && make "$ltmain"
10930   fi
10931 fi
10932
10933
10934 ac_ext=c
10935 ac_cpp='$CPP $CPPFLAGS'
10936 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10937 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10938 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10939
10940 CC="$lt_save_CC"
10941
10942
10943 # Check whether --with-tags or --without-tags was given.
10944 if test "${with_tags+set}" = set; then
10945   withval="$with_tags"
10946   tagnames="$withval"
10947 fi;
10948
10949 if test -f "$ltmain" && test -n "$tagnames"; then
10950   if test ! -f "${ofile}"; then
10951     { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not exist" >&5
10952 echo "$as_me: WARNING: output file \`$ofile' does not exist" >&2;}
10953   fi
10954
10955   if test -z "$LTCC"; then
10956     eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
10957     if test -z "$LTCC"; then
10958       { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not look like a libtool script" >&5
10959 echo "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;}
10960     else
10961       { echo "$as_me:$LINENO: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5
10962 echo "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;}
10963     fi
10964   fi
10965
10966   # Extract list of available tagged configurations in $ofile.
10967   # Note that this assumes the entire list is on one line.
10968   available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
10969
10970   lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
10971   for tagname in $tagnames; do
10972     IFS="$lt_save_ifs"
10973     # Check whether tagname contains only valid characters
10974     case `$echo "X$tagname" | $Xsed -e 's:[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]::g'` in
10975     "") ;;
10976     *)  { { echo "$as_me:$LINENO: error: invalid tag name: $tagname" >&5
10977 echo "$as_me: error: invalid tag name: $tagname" >&2;}
10978    { (exit 1); exit 1; }; }
10979         ;;
10980     esac
10981
10982     if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
10983     then
10984       { { echo "$as_me:$LINENO: error: tag name \"$tagname\" already exists" >&5
10985 echo "$as_me: error: tag name \"$tagname\" already exists" >&2;}
10986    { (exit 1); exit 1; }; }
10987     fi
10988
10989     # Update the list of available tags.
10990     if test -n "$tagname"; then
10991       echo appending configuration tag \"$tagname\" to $ofile
10992
10993       case $tagname in
10994       CXX)
10995         if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
10996             ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
10997             (test "X$CXX" != "Xg++"))) ; then
10998           :
10999         else
11000           tagname=""
11001         fi
11002         ;;
11003
11004       F77)
11005         if test -n "$F77" && test "X$F77" != "Xno"; then
11006           :
11007         else
11008           tagname=""
11009         fi
11010         ;;
11011
11012       GCJ)
11013         if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
11014           :
11015         else
11016           tagname=""
11017         fi
11018         ;;
11019
11020       RC)
11021
11022
11023
11024 # Source file extension for RC test sources.
11025 ac_ext=rc
11026
11027 # Object file extension for compiled RC test sources.
11028 objext=o
11029 objext_RC=$objext
11030
11031 # Code to be used in simple compile tests
11032 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
11033
11034 # Code to be used in simple link tests
11035 lt_simple_link_test_code="$lt_simple_compile_test_code"
11036
11037 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
11038
11039 # If no C compiler was specified, use CC.
11040 LTCC=${LTCC-"$CC"}
11041
11042 # Allow CC to be a program name with arguments.
11043 compiler=$CC
11044
11045
11046 # save warnings/boilerplate of simple test code
11047 ac_outfile=conftest.$ac_objext
11048 printf "$lt_simple_compile_test_code" >conftest.$ac_ext
11049 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
11050 _lt_compiler_boilerplate=`cat conftest.err`
11051 $rm conftest*
11052
11053 ac_outfile=conftest.$ac_objext
11054 printf "$lt_simple_link_test_code" >conftest.$ac_ext
11055 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
11056 _lt_linker_boilerplate=`cat conftest.err`
11057 $rm conftest*
11058
11059
11060 # Allow CC to be a program name with arguments.
11061 lt_save_CC="$CC"
11062 CC=${RC-"windres"}
11063 compiler=$CC
11064 compiler_RC=$CC
11065 for cc_temp in $compiler""; do
11066   case $cc_temp in
11067     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
11068     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
11069     \-*) ;;
11070     *) break;;
11071   esac
11072 done
11073 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
11074
11075 lt_cv_prog_compiler_c_o_RC=yes
11076
11077 # The else clause should only fire when bootstrapping the
11078 # libtool distribution, otherwise you forgot to ship ltmain.sh
11079 # with your package, and you will get complaints that there are
11080 # no rules to generate ltmain.sh.
11081 if test -f "$ltmain"; then
11082   # See if we are running on zsh, and set the options which allow our commands through
11083   # without removal of \ escapes.
11084   if test -n "${ZSH_VERSION+set}" ; then
11085     setopt NO_GLOB_SUBST
11086   fi
11087   # Now quote all the things that may contain metacharacters while being
11088   # careful not to overquote the AC_SUBSTed values.  We take copies of the
11089   # variables and quote the copies for generation of the libtool script.
11090   for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
11091     SED SHELL STRIP \
11092     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
11093     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
11094     deplibs_check_method reload_flag reload_cmds need_locks \
11095     lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
11096     lt_cv_sys_global_symbol_to_c_name_address \
11097     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
11098     old_postinstall_cmds old_postuninstall_cmds \
11099     compiler_RC \
11100     CC_RC \
11101     LD_RC \
11102     lt_prog_compiler_wl_RC \
11103     lt_prog_compiler_pic_RC \
11104     lt_prog_compiler_static_RC \
11105     lt_prog_compiler_no_builtin_flag_RC \
11106     export_dynamic_flag_spec_RC \
11107     thread_safe_flag_spec_RC \
11108     whole_archive_flag_spec_RC \
11109     enable_shared_with_static_runtimes_RC \
11110     old_archive_cmds_RC \
11111     old_archive_from_new_cmds_RC \
11112     predep_objects_RC \
11113     postdep_objects_RC \
11114     predeps_RC \
11115     postdeps_RC \
11116     compiler_lib_search_path_RC \
11117     archive_cmds_RC \
11118     archive_expsym_cmds_RC \
11119     postinstall_cmds_RC \
11120     postuninstall_cmds_RC \
11121     old_archive_from_expsyms_cmds_RC \
11122     allow_undefined_flag_RC \
11123     no_undefined_flag_RC \
11124     export_symbols_cmds_RC \
11125     hardcode_libdir_flag_spec_RC \
11126     hardcode_libdir_flag_spec_ld_RC \
11127     hardcode_libdir_separator_RC \
11128     hardcode_automatic_RC \
11129     module_cmds_RC \
11130     module_expsym_cmds_RC \
11131     lt_cv_prog_compiler_c_o_RC \
11132     exclude_expsyms_RC \
11133     include_expsyms_RC; do
11134
11135     case $var in
11136     old_archive_cmds_RC | \
11137     old_archive_from_new_cmds_RC | \
11138     archive_cmds_RC | \
11139     archive_expsym_cmds_RC | \
11140     module_cmds_RC | \
11141     module_expsym_cmds_RC | \
11142     old_archive_from_expsyms_cmds_RC | \
11143     export_symbols_cmds_RC | \
11144     extract_expsyms_cmds | reload_cmds | finish_cmds | \
11145     postinstall_cmds | postuninstall_cmds | \
11146     old_postinstall_cmds | old_postuninstall_cmds | \
11147     sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
11148       # Double-quote double-evaled strings.
11149       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
11150       ;;
11151     *)
11152       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
11153       ;;
11154     esac
11155   done
11156
11157   case $lt_echo in
11158   *'\$0 --fallback-echo"')
11159     lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
11160     ;;
11161   esac
11162
11163 cfgfile="$ofile"
11164
11165   cat <<__EOF__ >> "$cfgfile"
11166 # ### BEGIN LIBTOOL TAG CONFIG: $tagname
11167
11168 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
11169
11170 # Shell to use when invoking shell scripts.
11171 SHELL=$lt_SHELL
11172
11173 # Whether or not to build shared libraries.
11174 build_libtool_libs=$enable_shared
11175
11176 # Whether or not to build static libraries.
11177 build_old_libs=$enable_static
11178
11179 # Whether or not to add -lc for building shared libraries.
11180 build_libtool_need_lc=$archive_cmds_need_lc_RC
11181
11182 # Whether or not to disallow shared libs when runtime libs are static
11183 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_RC
11184
11185 # Whether or not to optimize for fast installation.
11186 fast_install=$enable_fast_install
11187
11188 # The host system.
11189 host_alias=$host_alias
11190 host=$host
11191 host_os=$host_os
11192
11193 # The build system.
11194 build_alias=$build_alias
11195 build=$build
11196 build_os=$build_os
11197
11198 # An echo program that does not interpret backslashes.
11199 echo=$lt_echo
11200
11201 # The archiver.
11202 AR=$lt_AR
11203 AR_FLAGS=$lt_AR_FLAGS
11204
11205 # A C compiler.
11206 LTCC=$lt_LTCC
11207
11208 # A language-specific compiler.
11209 CC=$lt_compiler_RC
11210
11211 # Is the compiler the GNU C compiler?
11212 with_gcc=$GCC_RC
11213
11214 # An ERE matcher.
11215 EGREP=$lt_EGREP
11216
11217 # The linker used to build libraries.
11218 LD=$lt_LD_RC
11219
11220 # Whether we need hard or soft links.
11221 LN_S=$lt_LN_S
11222
11223 # A BSD-compatible nm program.
11224 NM=$lt_NM
11225
11226 # A symbol stripping program
11227 STRIP=$lt_STRIP
11228
11229 # Used to examine libraries when file_magic_cmd begins "file"
11230 MAGIC_CMD=$MAGIC_CMD
11231
11232 # Used on cygwin: DLL creation program.
11233 DLLTOOL="$DLLTOOL"
11234
11235 # Used on cygwin: object dumper.
11236 OBJDUMP="$OBJDUMP"
11237
11238 # Used on cygwin: assembler.
11239 AS="$AS"
11240
11241 # The name of the directory that contains temporary libtool files.
11242 objdir=$objdir
11243
11244 # How to create reloadable object files.
11245 reload_flag=$lt_reload_flag
11246 reload_cmds=$lt_reload_cmds
11247
11248 # How to pass a linker flag through the compiler.
11249 wl=$lt_lt_prog_compiler_wl_RC
11250
11251 # Object file suffix (normally "o").
11252 objext="$ac_objext"
11253
11254 # Old archive suffix (normally "a").
11255 libext="$libext"
11256
11257 # Shared library suffix (normally ".so").
11258 shrext_cmds='$shrext_cmds'
11259
11260 # Executable file suffix (normally "").
11261 exeext="$exeext"
11262
11263 # Additional compiler flags for building library objects.
11264 pic_flag=$lt_lt_prog_compiler_pic_RC
11265 pic_mode=$pic_mode
11266
11267 # What is the maximum length of a command?
11268 max_cmd_len=$lt_cv_sys_max_cmd_len
11269
11270 # Does compiler simultaneously support -c and -o options?
11271 compiler_c_o=$lt_lt_cv_prog_compiler_c_o_RC
11272
11273 # Must we lock files when doing compilation?
11274 need_locks=$lt_need_locks
11275
11276 # Do we need the lib prefix for modules?
11277 need_lib_prefix=$need_lib_prefix
11278
11279 # Do we need a version for libraries?
11280 need_version=$need_version
11281
11282 # Whether dlopen is supported.
11283 dlopen_support=$enable_dlopen
11284
11285 # Whether dlopen of programs is supported.
11286 dlopen_self=$enable_dlopen_self
11287
11288 # Whether dlopen of statically linked programs is supported.
11289 dlopen_self_static=$enable_dlopen_self_static
11290
11291 # Compiler flag to prevent dynamic linking.
11292 link_static_flag=$lt_lt_prog_compiler_static_RC
11293
11294 # Compiler flag to turn off builtin functions.
11295 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_RC
11296
11297 # Compiler flag to allow reflexive dlopens.
11298 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_RC
11299
11300 # Compiler flag to generate shared objects directly from archives.
11301 whole_archive_flag_spec=$lt_whole_archive_flag_spec_RC
11302
11303 # Compiler flag to generate thread-safe objects.
11304 thread_safe_flag_spec=$lt_thread_safe_flag_spec_RC
11305
11306 # Library versioning type.
11307 version_type=$version_type
11308
11309 # Format of library name prefix.
11310 libname_spec=$lt_libname_spec
11311
11312 # List of archive names.  First name is the real one, the rest are links.
11313 # The last name is the one that the linker finds with -lNAME.
11314 library_names_spec=$lt_library_names_spec
11315
11316 # The coded name of the library, if different from the real name.
11317 soname_spec=$lt_soname_spec
11318
11319 # Commands used to build and install an old-style archive.
11320 RANLIB=$lt_RANLIB
11321 old_archive_cmds=$lt_old_archive_cmds_RC
11322 old_postinstall_cmds=$lt_old_postinstall_cmds
11323 old_postuninstall_cmds=$lt_old_postuninstall_cmds
11324
11325 # Create an old-style archive from a shared archive.
11326 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_RC
11327
11328 # Create a temporary old-style archive to link instead of a shared archive.
11329 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_RC
11330
11331 # Commands used to build and install a shared archive.
11332 archive_cmds=$lt_archive_cmds_RC
11333 archive_expsym_cmds=$lt_archive_expsym_cmds_RC
11334 postinstall_cmds=$lt_postinstall_cmds
11335 postuninstall_cmds=$lt_postuninstall_cmds
11336
11337 # Commands used to build a loadable module (assumed same as above if empty)
11338 module_cmds=$lt_module_cmds_RC
11339 module_expsym_cmds=$lt_module_expsym_cmds_RC
11340
11341 # Commands to strip libraries.
11342 old_striplib=$lt_old_striplib
11343 striplib=$lt_striplib
11344
11345 # Dependencies to place before the objects being linked to create a
11346 # shared library.
11347 predep_objects=$lt_predep_objects_RC
11348
11349 # Dependencies to place after the objects being linked to create a
11350 # shared library.
11351 postdep_objects=$lt_postdep_objects_RC
11352
11353 # Dependencies to place before the objects being linked to create a
11354 # shared library.
11355 predeps=$lt_predeps_RC
11356
11357 # Dependencies to place after the objects being linked to create a
11358 # shared library.
11359 postdeps=$lt_postdeps_RC
11360
11361 # The library search path used internally by the compiler when linking
11362 # a shared library.
11363 compiler_lib_search_path=$lt_compiler_lib_search_path_RC
11364
11365 # Method to check whether dependent libraries are shared objects.
11366 deplibs_check_method=$lt_deplibs_check_method
11367
11368 # Command to use when deplibs_check_method == file_magic.
11369 file_magic_cmd=$lt_file_magic_cmd
11370
11371 # Flag that allows shared libraries with undefined symbols to be built.
11372 allow_undefined_flag=$lt_allow_undefined_flag_RC
11373
11374 # Flag that forces no undefined symbols.
11375 no_undefined_flag=$lt_no_undefined_flag_RC
11376
11377 # Commands used to finish a libtool library installation in a directory.
11378 finish_cmds=$lt_finish_cmds
11379
11380 # Same as above, but a single script fragment to be evaled but not shown.
11381 finish_eval=$lt_finish_eval
11382
11383 # Take the output of nm and produce a listing of raw symbols and C names.
11384 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
11385
11386 # Transform the output of nm in a proper C declaration
11387 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
11388
11389 # Transform the output of nm in a C name address pair
11390 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
11391
11392 # This is the shared library runtime path variable.
11393 runpath_var=$runpath_var
11394
11395 # This is the shared library path variable.
11396 shlibpath_var=$shlibpath_var
11397
11398 # Is shlibpath searched before the hard-coded library search path?
11399 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
11400
11401 # How to hardcode a shared library path into an executable.
11402 hardcode_action=$hardcode_action_RC
11403
11404 # Whether we should hardcode library paths into libraries.
11405 hardcode_into_libs=$hardcode_into_libs
11406
11407 # Flag to hardcode \$libdir into a binary during linking.
11408 # This must work even if \$libdir does not exist.
11409 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_RC
11410
11411 # If ld is used when linking, flag to hardcode \$libdir into
11412 # a binary during linking. This must work even if \$libdir does
11413 # not exist.
11414 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_RC
11415
11416 # Whether we need a single -rpath flag with a separated argument.
11417 hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC
11418
11419 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
11420 # resulting binary.
11421 hardcode_direct=$hardcode_direct_RC
11422
11423 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
11424 # resulting binary.
11425 hardcode_minus_L=$hardcode_minus_L_RC
11426
11427 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
11428 # the resulting binary.
11429 hardcode_shlibpath_var=$hardcode_shlibpath_var_RC
11430
11431 # Set to yes if building a shared library automatically hardcodes DIR into the library
11432 # and all subsequent libraries and executables linked against it.
11433 hardcode_automatic=$hardcode_automatic_RC
11434
11435 # Variables whose values should be saved in libtool wrapper scripts and
11436 # restored at relink time.
11437 variables_saved_for_relink="$variables_saved_for_relink"
11438
11439 # Whether libtool must link a program against all its dependency libraries.
11440 link_all_deplibs=$link_all_deplibs_RC
11441
11442 # Compile-time system search path for libraries
11443 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
11444
11445 # Run-time system search path for libraries
11446 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
11447
11448 # Fix the shell variable \$srcfile for the compiler.
11449 fix_srcfile_path="$fix_srcfile_path_RC"
11450
11451 # Set to yes if exported symbols are required.
11452 always_export_symbols=$always_export_symbols_RC
11453
11454 # The commands to list exported symbols.
11455 export_symbols_cmds=$lt_export_symbols_cmds_RC
11456
11457 # The commands to extract the exported symbol list from a shared archive.
11458 extract_expsyms_cmds=$lt_extract_expsyms_cmds
11459
11460 # Symbols that should not be listed in the preloaded symbols.
11461 exclude_expsyms=$lt_exclude_expsyms_RC
11462
11463 # Symbols that must always be exported.
11464 include_expsyms=$lt_include_expsyms_RC
11465
11466 # ### END LIBTOOL TAG CONFIG: $tagname
11467
11468 __EOF__
11469
11470
11471 else
11472   # If there is no Makefile yet, we rely on a make rule to execute
11473   # `config.status --recheck' to rerun these tests and create the
11474   # libtool script then.
11475   ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
11476   if test -f "$ltmain_in"; then
11477     test -f Makefile && make "$ltmain"
11478   fi
11479 fi
11480
11481
11482 ac_ext=c
11483 ac_cpp='$CPP $CPPFLAGS'
11484 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11485 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11486 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11487
11488 CC="$lt_save_CC"
11489
11490         ;;
11491
11492       *)
11493         { { echo "$as_me:$LINENO: error: Unsupported tag name: $tagname" >&5
11494 echo "$as_me: error: Unsupported tag name: $tagname" >&2;}
11495    { (exit 1); exit 1; }; }
11496         ;;
11497       esac
11498
11499       # Append the new tag name to the list of available tags.
11500       if test -n "$tagname" ; then
11501       available_tags="$available_tags $tagname"
11502     fi
11503     fi
11504   done
11505   IFS="$lt_save_ifs"
11506
11507   # Now substitute the updated list of available tags.
11508   if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
11509     mv "${ofile}T" "$ofile"
11510     chmod +x "$ofile"
11511   else
11512     rm -f "${ofile}T"
11513     { { echo "$as_me:$LINENO: error: unable to update list of available tagged configurations." >&5
11514 echo "$as_me: error: unable to update list of available tagged configurations." >&2;}
11515    { (exit 1); exit 1; }; }
11516   fi
11517 fi
11518
11519
11520
11521 # This can be used to rebuild libtool when needed
11522 LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
11523
11524 # Always use our own libtool.
11525 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
11526
11527 # Prevent multiple expansion
11528
11529
11530
11531
11532
11533
11534
11535
11536
11537
11538 ol_link_perl=no
11539 if test $ol_enable_perl != no ; then
11540         # Extract the first word of "perl", so it can be a program name with args.
11541 set dummy perl; ac_word=$2
11542 echo "$as_me:$LINENO: checking for $ac_word" >&5
11543 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11544 if test "${ac_cv_path_PERLBIN+set}" = set; then
11545   echo $ECHO_N "(cached) $ECHO_C" >&6
11546 else
11547   case $PERLBIN in
11548   [\\/]* | ?:[\\/]*)
11549   ac_cv_path_PERLBIN="$PERLBIN" # Let the user override the test with a path.
11550   ;;
11551   *)
11552   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11553 for as_dir in $PATH
11554 do
11555   IFS=$as_save_IFS
11556   test -z "$as_dir" && as_dir=.
11557   for ac_exec_ext in '' $ac_executable_extensions; do
11558   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11559     ac_cv_path_PERLBIN="$as_dir/$ac_word$ac_exec_ext"
11560     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11561     break 2
11562   fi
11563 done
11564 done
11565
11566   test -z "$ac_cv_path_PERLBIN" && ac_cv_path_PERLBIN="/usr/bin/perl"
11567   ;;
11568 esac
11569 fi
11570 PERLBIN=$ac_cv_path_PERLBIN
11571
11572 if test -n "$PERLBIN"; then
11573   echo "$as_me:$LINENO: result: $PERLBIN" >&5
11574 echo "${ECHO_T}$PERLBIN" >&6
11575 else
11576   echo "$as_me:$LINENO: result: no" >&5
11577 echo "${ECHO_T}no" >&6
11578 fi
11579
11580
11581         if test "no$PERLBIN" = "no" ; then
11582                 if test $ol_enable_perl = yes ; then
11583                         { { echo "$as_me:$LINENO: error: could not locate perl" >&5
11584 echo "$as_me: error: could not locate perl" >&2;}
11585    { (exit 1); exit 1; }; }
11586                 fi
11587
11588         else
11589                 PERL_CPPFLAGS="`$PERLBIN -MExtUtils::Embed -e ccopts`"
11590                 PERL_LDFLAGS="`$PERLBIN -MExtUtils::Embed -e ldopts|sed -e 's/ -lc / /' -e 's/ -lc$//'`"
11591
11592                 if test x"$ol_enable_perl" = "xyes" ; then
11593                         SLAPD_PERL_LDFLAGS="$PERL_LDFLAGS"
11594                 else
11595                         MOD_PERL_LDFLAGS="$PERL_LDFLAGS"
11596                 fi
11597                                 ol_link_perl=yes
11598         fi
11599 fi
11600
11601 ac_ext=c
11602 ac_cpp='$CPP $CPPFLAGS'
11603 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11604 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11605 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11606 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
11607 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
11608 # On Suns, sometimes $CPP names a directory.
11609 if test -n "$CPP" && test -d "$CPP"; then
11610   CPP=
11611 fi
11612 if test -z "$CPP"; then
11613   if test "${ac_cv_prog_CPP+set}" = set; then
11614   echo $ECHO_N "(cached) $ECHO_C" >&6
11615 else
11616       # Double quotes because CPP needs to be expanded
11617     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
11618     do
11619       ac_preproc_ok=false
11620 for ac_c_preproc_warn_flag in '' yes
11621 do
11622   # Use a header file that comes with gcc, so configuring glibc
11623   # with a fresh cross-compiler works.
11624   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11625   # <limits.h> exists even on freestanding compilers.
11626   # On the NeXT, cc -E runs the code through the compiler's parser,
11627   # not just through cpp. "Syntax error" is here to catch this case.
11628   cat >conftest.$ac_ext <<_ACEOF
11629 /* confdefs.h.  */
11630 _ACEOF
11631 cat confdefs.h >>conftest.$ac_ext
11632 cat >>conftest.$ac_ext <<_ACEOF
11633 /* end confdefs.h.  */
11634 #ifdef __STDC__
11635 # include <limits.h>
11636 #else
11637 # include <assert.h>
11638 #endif
11639                      Syntax error
11640 _ACEOF
11641 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11642   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11643   ac_status=$?
11644   grep -v '^ *+' conftest.er1 >conftest.err
11645   rm -f conftest.er1
11646   cat conftest.err >&5
11647   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11648   (exit $ac_status); } >/dev/null; then
11649   if test -s conftest.err; then
11650     ac_cpp_err=$ac_c_preproc_warn_flag
11651     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11652   else
11653     ac_cpp_err=
11654   fi
11655 else
11656   ac_cpp_err=yes
11657 fi
11658 if test -z "$ac_cpp_err"; then
11659   :
11660 else
11661   echo "$as_me: failed program was:" >&5
11662 sed 's/^/| /' conftest.$ac_ext >&5
11663
11664   # Broken: fails on valid input.
11665 continue
11666 fi
11667 rm -f conftest.err conftest.$ac_ext
11668
11669   # OK, works on sane cases.  Now check whether non-existent headers
11670   # can be detected and how.
11671   cat >conftest.$ac_ext <<_ACEOF
11672 /* confdefs.h.  */
11673 _ACEOF
11674 cat confdefs.h >>conftest.$ac_ext
11675 cat >>conftest.$ac_ext <<_ACEOF
11676 /* end confdefs.h.  */
11677 #include <ac_nonexistent.h>
11678 _ACEOF
11679 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11680   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11681   ac_status=$?
11682   grep -v '^ *+' conftest.er1 >conftest.err
11683   rm -f conftest.er1
11684   cat conftest.err >&5
11685   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11686   (exit $ac_status); } >/dev/null; then
11687   if test -s conftest.err; then
11688     ac_cpp_err=$ac_c_preproc_warn_flag
11689     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11690   else
11691     ac_cpp_err=
11692   fi
11693 else
11694   ac_cpp_err=yes
11695 fi
11696 if test -z "$ac_cpp_err"; then
11697   # Broken: success on invalid input.
11698 continue
11699 else
11700   echo "$as_me: failed program was:" >&5
11701 sed 's/^/| /' conftest.$ac_ext >&5
11702
11703   # Passes both tests.
11704 ac_preproc_ok=:
11705 break
11706 fi
11707 rm -f conftest.err conftest.$ac_ext
11708
11709 done
11710 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
11711 rm -f conftest.err conftest.$ac_ext
11712 if $ac_preproc_ok; then
11713   break
11714 fi
11715
11716     done
11717     ac_cv_prog_CPP=$CPP
11718
11719 fi
11720   CPP=$ac_cv_prog_CPP
11721 else
11722   ac_cv_prog_CPP=$CPP
11723 fi
11724 echo "$as_me:$LINENO: result: $CPP" >&5
11725 echo "${ECHO_T}$CPP" >&6
11726 ac_preproc_ok=false
11727 for ac_c_preproc_warn_flag in '' yes
11728 do
11729   # Use a header file that comes with gcc, so configuring glibc
11730   # with a fresh cross-compiler works.
11731   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11732   # <limits.h> exists even on freestanding compilers.
11733   # On the NeXT, cc -E runs the code through the compiler's parser,
11734   # not just through cpp. "Syntax error" is here to catch this case.
11735   cat >conftest.$ac_ext <<_ACEOF
11736 /* confdefs.h.  */
11737 _ACEOF
11738 cat confdefs.h >>conftest.$ac_ext
11739 cat >>conftest.$ac_ext <<_ACEOF
11740 /* end confdefs.h.  */
11741 #ifdef __STDC__
11742 # include <limits.h>
11743 #else
11744 # include <assert.h>
11745 #endif
11746                      Syntax error
11747 _ACEOF
11748 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11749   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11750   ac_status=$?
11751   grep -v '^ *+' conftest.er1 >conftest.err
11752   rm -f conftest.er1
11753   cat conftest.err >&5
11754   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11755   (exit $ac_status); } >/dev/null; then
11756   if test -s conftest.err; then
11757     ac_cpp_err=$ac_c_preproc_warn_flag
11758     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11759   else
11760     ac_cpp_err=
11761   fi
11762 else
11763   ac_cpp_err=yes
11764 fi
11765 if test -z "$ac_cpp_err"; then
11766   :
11767 else
11768   echo "$as_me: failed program was:" >&5
11769 sed 's/^/| /' conftest.$ac_ext >&5
11770
11771   # Broken: fails on valid input.
11772 continue
11773 fi
11774 rm -f conftest.err conftest.$ac_ext
11775
11776   # OK, works on sane cases.  Now check whether non-existent headers
11777   # can be detected and how.
11778   cat >conftest.$ac_ext <<_ACEOF
11779 /* confdefs.h.  */
11780 _ACEOF
11781 cat confdefs.h >>conftest.$ac_ext
11782 cat >>conftest.$ac_ext <<_ACEOF
11783 /* end confdefs.h.  */
11784 #include <ac_nonexistent.h>
11785 _ACEOF
11786 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11787   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11788   ac_status=$?
11789   grep -v '^ *+' conftest.er1 >conftest.err
11790   rm -f conftest.er1
11791   cat conftest.err >&5
11792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11793   (exit $ac_status); } >/dev/null; then
11794   if test -s conftest.err; then
11795     ac_cpp_err=$ac_c_preproc_warn_flag
11796     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11797   else
11798     ac_cpp_err=
11799   fi
11800 else
11801   ac_cpp_err=yes
11802 fi
11803 if test -z "$ac_cpp_err"; then
11804   # Broken: success on invalid input.
11805 continue
11806 else
11807   echo "$as_me: failed program was:" >&5
11808 sed 's/^/| /' conftest.$ac_ext >&5
11809
11810   # Passes both tests.
11811 ac_preproc_ok=:
11812 break
11813 fi
11814 rm -f conftest.err conftest.$ac_ext
11815
11816 done
11817 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
11818 rm -f conftest.err conftest.$ac_ext
11819 if $ac_preproc_ok; then
11820   :
11821 else
11822   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
11823 See \`config.log' for more details." >&5
11824 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
11825 See \`config.log' for more details." >&2;}
11826    { (exit 1); exit 1; }; }
11827 fi
11828
11829 ac_ext=c
11830 ac_cpp='$CPP $CPPFLAGS'
11831 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11832 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11833 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11834
11835
11836 case $host_os in
11837   *mingw32* ) ac_cv_mingw32=yes ;;
11838   *cygwin* ) ac_cv_cygwin=yes ;;
11839 esac
11840
11841
11842
11843
11844 cat >>confdefs.h <<_ACEOF
11845 #define EXEEXT "${EXEEXT}"
11846 _ACEOF
11847
11848
11849 echo "$as_me:$LINENO: checking for be_app in -lbe" >&5
11850 echo $ECHO_N "checking for be_app in -lbe... $ECHO_C" >&6
11851 if test "${ac_cv_lib_be_be_app+set}" = set; then
11852   echo $ECHO_N "(cached) $ECHO_C" >&6
11853 else
11854   ac_check_lib_save_LIBS=$LIBS
11855 LIBS="-lbe -lroot -lnet $LIBS"
11856 cat >conftest.$ac_ext <<_ACEOF
11857 /* confdefs.h.  */
11858 _ACEOF
11859 cat confdefs.h >>conftest.$ac_ext
11860 cat >>conftest.$ac_ext <<_ACEOF
11861 /* end confdefs.h.  */
11862
11863 /* Override any gcc2 internal prototype to avoid an error.  */
11864 #ifdef __cplusplus
11865 extern "C"
11866 #endif
11867 /* We use char because int might match the return type of a gcc2
11868    builtin and then its argument prototype would still apply.  */
11869 char be_app ();
11870 int
11871 main ()
11872 {
11873 be_app ();
11874   ;
11875   return 0;
11876 }
11877 _ACEOF
11878 rm -f conftest.$ac_objext conftest$ac_exeext
11879 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11880   (eval $ac_link) 2>conftest.er1
11881   ac_status=$?
11882   grep -v '^ *+' conftest.er1 >conftest.err
11883   rm -f conftest.er1
11884   cat conftest.err >&5
11885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11886   (exit $ac_status); } &&
11887          { ac_try='test -z "$ac_c_werror_flag"
11888                          || test ! -s conftest.err'
11889   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11890   (eval $ac_try) 2>&5
11891   ac_status=$?
11892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11893   (exit $ac_status); }; } &&
11894          { ac_try='test -s conftest$ac_exeext'
11895   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11896   (eval $ac_try) 2>&5
11897   ac_status=$?
11898   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11899   (exit $ac_status); }; }; then
11900   ac_cv_lib_be_be_app=yes
11901 else
11902   echo "$as_me: failed program was:" >&5
11903 sed 's/^/| /' conftest.$ac_ext >&5
11904
11905 ac_cv_lib_be_be_app=no
11906 fi
11907 rm -f conftest.err conftest.$ac_objext \
11908       conftest$ac_exeext conftest.$ac_ext
11909 LIBS=$ac_check_lib_save_LIBS
11910 fi
11911 echo "$as_me:$LINENO: result: $ac_cv_lib_be_be_app" >&5
11912 echo "${ECHO_T}$ac_cv_lib_be_be_app" >&6
11913 if test $ac_cv_lib_be_be_app = yes; then
11914   LIBS="$LIBS -lbe -lroot -lnet"
11915 else
11916   :
11917 fi
11918
11919
11920 ac_ext=c
11921 ac_cpp='$CPP $CPPFLAGS'
11922 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11923 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11924 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11925 if test -n "$ac_tool_prefix"; then
11926   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
11927 set dummy ${ac_tool_prefix}gcc; ac_word=$2
11928 echo "$as_me:$LINENO: checking for $ac_word" >&5
11929 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11930 if test "${ac_cv_prog_CC+set}" = set; then
11931   echo $ECHO_N "(cached) $ECHO_C" >&6
11932 else
11933   if test -n "$CC"; then
11934   ac_cv_prog_CC="$CC" # Let the user override the test.
11935 else
11936 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11937 for as_dir in $PATH
11938 do
11939   IFS=$as_save_IFS
11940   test -z "$as_dir" && as_dir=.
11941   for ac_exec_ext in '' $ac_executable_extensions; do
11942   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11943     ac_cv_prog_CC="${ac_tool_prefix}gcc"
11944     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11945     break 2
11946   fi
11947 done
11948 done
11949
11950 fi
11951 fi
11952 CC=$ac_cv_prog_CC
11953 if test -n "$CC"; then
11954   echo "$as_me:$LINENO: result: $CC" >&5
11955 echo "${ECHO_T}$CC" >&6
11956 else
11957   echo "$as_me:$LINENO: result: no" >&5
11958 echo "${ECHO_T}no" >&6
11959 fi
11960
11961 fi
11962 if test -z "$ac_cv_prog_CC"; then
11963   ac_ct_CC=$CC
11964   # Extract the first word of "gcc", so it can be a program name with args.
11965 set dummy gcc; ac_word=$2
11966 echo "$as_me:$LINENO: checking for $ac_word" >&5
11967 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11968 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
11969   echo $ECHO_N "(cached) $ECHO_C" >&6
11970 else
11971   if test -n "$ac_ct_CC"; then
11972   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
11973 else
11974 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11975 for as_dir in $PATH
11976 do
11977   IFS=$as_save_IFS
11978   test -z "$as_dir" && as_dir=.
11979   for ac_exec_ext in '' $ac_executable_extensions; do
11980   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11981     ac_cv_prog_ac_ct_CC="gcc"
11982     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11983     break 2
11984   fi
11985 done
11986 done
11987
11988 fi
11989 fi
11990 ac_ct_CC=$ac_cv_prog_ac_ct_CC
11991 if test -n "$ac_ct_CC"; then
11992   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
11993 echo "${ECHO_T}$ac_ct_CC" >&6
11994 else
11995   echo "$as_me:$LINENO: result: no" >&5
11996 echo "${ECHO_T}no" >&6
11997 fi
11998
11999   CC=$ac_ct_CC
12000 else
12001   CC="$ac_cv_prog_CC"
12002 fi
12003
12004 if test -z "$CC"; then
12005   if test -n "$ac_tool_prefix"; then
12006   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
12007 set dummy ${ac_tool_prefix}cc; ac_word=$2
12008 echo "$as_me:$LINENO: checking for $ac_word" >&5
12009 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12010 if test "${ac_cv_prog_CC+set}" = set; then
12011   echo $ECHO_N "(cached) $ECHO_C" >&6
12012 else
12013   if test -n "$CC"; then
12014   ac_cv_prog_CC="$CC" # Let the user override the test.
12015 else
12016 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12017 for as_dir in $PATH
12018 do
12019   IFS=$as_save_IFS
12020   test -z "$as_dir" && as_dir=.
12021   for ac_exec_ext in '' $ac_executable_extensions; do
12022   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12023     ac_cv_prog_CC="${ac_tool_prefix}cc"
12024     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12025     break 2
12026   fi
12027 done
12028 done
12029
12030 fi
12031 fi
12032 CC=$ac_cv_prog_CC
12033 if test -n "$CC"; then
12034   echo "$as_me:$LINENO: result: $CC" >&5
12035 echo "${ECHO_T}$CC" >&6
12036 else
12037   echo "$as_me:$LINENO: result: no" >&5
12038 echo "${ECHO_T}no" >&6
12039 fi
12040
12041 fi
12042 if test -z "$ac_cv_prog_CC"; then
12043   ac_ct_CC=$CC
12044   # Extract the first word of "cc", so it can be a program name with args.
12045 set dummy cc; ac_word=$2
12046 echo "$as_me:$LINENO: checking for $ac_word" >&5
12047 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12048 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
12049   echo $ECHO_N "(cached) $ECHO_C" >&6
12050 else
12051   if test -n "$ac_ct_CC"; then
12052   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
12053 else
12054 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12055 for as_dir in $PATH
12056 do
12057   IFS=$as_save_IFS
12058   test -z "$as_dir" && as_dir=.
12059   for ac_exec_ext in '' $ac_executable_extensions; do
12060   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12061     ac_cv_prog_ac_ct_CC="cc"
12062     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12063     break 2
12064   fi
12065 done
12066 done
12067
12068 fi
12069 fi
12070 ac_ct_CC=$ac_cv_prog_ac_ct_CC
12071 if test -n "$ac_ct_CC"; then
12072   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
12073 echo "${ECHO_T}$ac_ct_CC" >&6
12074 else
12075   echo "$as_me:$LINENO: result: no" >&5
12076 echo "${ECHO_T}no" >&6
12077 fi
12078
12079   CC=$ac_ct_CC
12080 else
12081   CC="$ac_cv_prog_CC"
12082 fi
12083
12084 fi
12085 if test -z "$CC"; then
12086   # Extract the first word of "cc", so it can be a program name with args.
12087 set dummy cc; ac_word=$2
12088 echo "$as_me:$LINENO: checking for $ac_word" >&5
12089 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12090 if test "${ac_cv_prog_CC+set}" = set; then
12091   echo $ECHO_N "(cached) $ECHO_C" >&6
12092 else
12093   if test -n "$CC"; then
12094   ac_cv_prog_CC="$CC" # Let the user override the test.
12095 else
12096   ac_prog_rejected=no
12097 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12098 for as_dir in $PATH
12099 do
12100   IFS=$as_save_IFS
12101   test -z "$as_dir" && as_dir=.
12102   for ac_exec_ext in '' $ac_executable_extensions; do
12103   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12104     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
12105        ac_prog_rejected=yes
12106        continue
12107      fi
12108     ac_cv_prog_CC="cc"
12109     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12110     break 2
12111   fi
12112 done
12113 done
12114
12115 if test $ac_prog_rejected = yes; then
12116   # We found a bogon in the path, so make sure we never use it.
12117   set dummy $ac_cv_prog_CC
12118   shift
12119   if test $# != 0; then
12120     # We chose a different compiler from the bogus one.
12121     # However, it has the same basename, so the bogon will be chosen
12122     # first if we set CC to just the basename; use the full file name.
12123     shift
12124     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
12125   fi
12126 fi
12127 fi
12128 fi
12129 CC=$ac_cv_prog_CC
12130 if test -n "$CC"; then
12131   echo "$as_me:$LINENO: result: $CC" >&5
12132 echo "${ECHO_T}$CC" >&6
12133 else
12134   echo "$as_me:$LINENO: result: no" >&5
12135 echo "${ECHO_T}no" >&6
12136 fi
12137
12138 fi
12139 if test -z "$CC"; then
12140   if test -n "$ac_tool_prefix"; then
12141   for ac_prog in cl
12142   do
12143     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
12144 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
12145 echo "$as_me:$LINENO: checking for $ac_word" >&5
12146 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12147 if test "${ac_cv_prog_CC+set}" = set; then
12148   echo $ECHO_N "(cached) $ECHO_C" >&6
12149 else
12150   if test -n "$CC"; then
12151   ac_cv_prog_CC="$CC" # Let the user override the test.
12152 else
12153 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12154 for as_dir in $PATH
12155 do
12156   IFS=$as_save_IFS
12157   test -z "$as_dir" && as_dir=.
12158   for ac_exec_ext in '' $ac_executable_extensions; do
12159   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12160     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
12161     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12162     break 2
12163   fi
12164 done
12165 done
12166
12167 fi
12168 fi
12169 CC=$ac_cv_prog_CC
12170 if test -n "$CC"; then
12171   echo "$as_me:$LINENO: result: $CC" >&5
12172 echo "${ECHO_T}$CC" >&6
12173 else
12174   echo "$as_me:$LINENO: result: no" >&5
12175 echo "${ECHO_T}no" >&6
12176 fi
12177
12178     test -n "$CC" && break
12179   done
12180 fi
12181 if test -z "$CC"; then
12182   ac_ct_CC=$CC
12183   for ac_prog in cl
12184 do
12185   # Extract the first word of "$ac_prog", so it can be a program name with args.
12186 set dummy $ac_prog; ac_word=$2
12187 echo "$as_me:$LINENO: checking for $ac_word" >&5
12188 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12189 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
12190   echo $ECHO_N "(cached) $ECHO_C" >&6
12191 else
12192   if test -n "$ac_ct_CC"; then
12193   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
12194 else
12195 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12196 for as_dir in $PATH
12197 do
12198   IFS=$as_save_IFS
12199   test -z "$as_dir" && as_dir=.
12200   for ac_exec_ext in '' $ac_executable_extensions; do
12201   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12202     ac_cv_prog_ac_ct_CC="$ac_prog"
12203     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12204     break 2
12205   fi
12206 done
12207 done
12208
12209 fi
12210 fi
12211 ac_ct_CC=$ac_cv_prog_ac_ct_CC
12212 if test -n "$ac_ct_CC"; then
12213   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
12214 echo "${ECHO_T}$ac_ct_CC" >&6
12215 else
12216   echo "$as_me:$LINENO: result: no" >&5
12217 echo "${ECHO_T}no" >&6
12218 fi
12219
12220   test -n "$ac_ct_CC" && break
12221 done
12222
12223   CC=$ac_ct_CC
12224 fi
12225
12226 fi
12227
12228
12229 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
12230 See \`config.log' for more details." >&5
12231 echo "$as_me: error: no acceptable C compiler found in \$PATH
12232 See \`config.log' for more details." >&2;}
12233    { (exit 1); exit 1; }; }
12234
12235 # Provide some information about the compiler.
12236 echo "$as_me:$LINENO:" \
12237      "checking for C compiler version" >&5
12238 ac_compiler=`set X $ac_compile; echo $2`
12239 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
12240   (eval $ac_compiler --version </dev/null >&5) 2>&5
12241   ac_status=$?
12242   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12243   (exit $ac_status); }
12244 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
12245   (eval $ac_compiler -v </dev/null >&5) 2>&5
12246   ac_status=$?
12247   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12248   (exit $ac_status); }
12249 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
12250   (eval $ac_compiler -V </dev/null >&5) 2>&5
12251   ac_status=$?
12252   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12253   (exit $ac_status); }
12254
12255 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
12256 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
12257 if test "${ac_cv_c_compiler_gnu+set}" = set; then
12258   echo $ECHO_N "(cached) $ECHO_C" >&6
12259 else
12260   cat >conftest.$ac_ext <<_ACEOF
12261 /* confdefs.h.  */
12262 _ACEOF
12263 cat confdefs.h >>conftest.$ac_ext
12264 cat >>conftest.$ac_ext <<_ACEOF
12265 /* end confdefs.h.  */
12266
12267 int
12268 main ()
12269 {
12270 #ifndef __GNUC__
12271        choke me
12272 #endif
12273
12274   ;
12275   return 0;
12276 }
12277 _ACEOF
12278 rm -f conftest.$ac_objext
12279 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12280   (eval $ac_compile) 2>conftest.er1
12281   ac_status=$?
12282   grep -v '^ *+' conftest.er1 >conftest.err
12283   rm -f conftest.er1
12284   cat conftest.err >&5
12285   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12286   (exit $ac_status); } &&
12287          { ac_try='test -z "$ac_c_werror_flag"
12288                          || test ! -s conftest.err'
12289   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12290   (eval $ac_try) 2>&5
12291   ac_status=$?
12292   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12293   (exit $ac_status); }; } &&
12294          { ac_try='test -s conftest.$ac_objext'
12295   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12296   (eval $ac_try) 2>&5
12297   ac_status=$?
12298   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12299   (exit $ac_status); }; }; then
12300   ac_compiler_gnu=yes
12301 else
12302   echo "$as_me: failed program was:" >&5
12303 sed 's/^/| /' conftest.$ac_ext >&5
12304
12305 ac_compiler_gnu=no
12306 fi
12307 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12308 ac_cv_c_compiler_gnu=$ac_compiler_gnu
12309
12310 fi
12311 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
12312 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
12313 GCC=`test $ac_compiler_gnu = yes && echo yes`
12314 ac_test_CFLAGS=${CFLAGS+set}
12315 ac_save_CFLAGS=$CFLAGS
12316 CFLAGS="-g"
12317 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
12318 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
12319 if test "${ac_cv_prog_cc_g+set}" = set; then
12320   echo $ECHO_N "(cached) $ECHO_C" >&6
12321 else
12322   cat >conftest.$ac_ext <<_ACEOF
12323 /* confdefs.h.  */
12324 _ACEOF
12325 cat confdefs.h >>conftest.$ac_ext
12326 cat >>conftest.$ac_ext <<_ACEOF
12327 /* end confdefs.h.  */
12328
12329 int
12330 main ()
12331 {
12332
12333   ;
12334   return 0;
12335 }
12336 _ACEOF
12337 rm -f conftest.$ac_objext
12338 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12339   (eval $ac_compile) 2>conftest.er1
12340   ac_status=$?
12341   grep -v '^ *+' conftest.er1 >conftest.err
12342   rm -f conftest.er1
12343   cat conftest.err >&5
12344   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12345   (exit $ac_status); } &&
12346          { ac_try='test -z "$ac_c_werror_flag"
12347                          || test ! -s conftest.err'
12348   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12349   (eval $ac_try) 2>&5
12350   ac_status=$?
12351   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12352   (exit $ac_status); }; } &&
12353          { ac_try='test -s conftest.$ac_objext'
12354   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12355   (eval $ac_try) 2>&5
12356   ac_status=$?
12357   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12358   (exit $ac_status); }; }; then
12359   ac_cv_prog_cc_g=yes
12360 else
12361   echo "$as_me: failed program was:" >&5
12362 sed 's/^/| /' conftest.$ac_ext >&5
12363
12364 ac_cv_prog_cc_g=no
12365 fi
12366 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12367 fi
12368 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
12369 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
12370 if test "$ac_test_CFLAGS" = set; then
12371   CFLAGS=$ac_save_CFLAGS
12372 elif test $ac_cv_prog_cc_g = yes; then
12373   if test "$GCC" = yes; then
12374     CFLAGS="-g -O2"
12375   else
12376     CFLAGS="-g"
12377   fi
12378 else
12379   if test "$GCC" = yes; then
12380     CFLAGS="-O2"
12381   else
12382     CFLAGS=
12383   fi
12384 fi
12385 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
12386 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
12387 if test "${ac_cv_prog_cc_stdc+set}" = set; then
12388   echo $ECHO_N "(cached) $ECHO_C" >&6
12389 else
12390   ac_cv_prog_cc_stdc=no
12391 ac_save_CC=$CC
12392 cat >conftest.$ac_ext <<_ACEOF
12393 /* confdefs.h.  */
12394 _ACEOF
12395 cat confdefs.h >>conftest.$ac_ext
12396 cat >>conftest.$ac_ext <<_ACEOF
12397 /* end confdefs.h.  */
12398 #include <stdarg.h>
12399 #include <stdio.h>
12400 #include <sys/types.h>
12401 #include <sys/stat.h>
12402 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
12403 struct buf { int x; };
12404 FILE * (*rcsopen) (struct buf *, struct stat *, int);
12405 static char *e (p, i)
12406      char **p;
12407      int i;
12408 {
12409   return p[i];
12410 }
12411 static char *f (char * (*g) (char **, int), char **p, ...)
12412 {
12413   char *s;
12414   va_list v;
12415   va_start (v,p);
12416   s = g (p, va_arg (v,int));
12417   va_end (v);
12418   return s;
12419 }
12420
12421 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
12422    function prototypes and stuff, but not '\xHH' hex character constants.
12423    These don't provoke an error unfortunately, instead are silently treated
12424    as 'x'.  The following induces an error, until -std1 is added to get
12425    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
12426    array size at least.  It's necessary to write '\x00'==0 to get something
12427    that's true only with -std1.  */
12428 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
12429
12430 int test (int i, double x);
12431 struct s1 {int (*f) (int a);};
12432 struct s2 {int (*f) (double a);};
12433 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
12434 int argc;
12435 char **argv;
12436 int
12437 main ()
12438 {
12439 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
12440   ;
12441   return 0;
12442 }
12443 _ACEOF
12444 # Don't try gcc -ansi; that turns off useful extensions and
12445 # breaks some systems' header files.
12446 # AIX                   -qlanglvl=ansi
12447 # Ultrix and OSF/1      -std1
12448 # HP-UX 10.20 and later -Ae
12449 # HP-UX older versions  -Aa -D_HPUX_SOURCE
12450 # SVR4                  -Xc -D__EXTENSIONS__
12451 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
12452 do
12453   CC="$ac_save_CC $ac_arg"
12454   rm -f conftest.$ac_objext
12455 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12456   (eval $ac_compile) 2>conftest.er1
12457   ac_status=$?
12458   grep -v '^ *+' conftest.er1 >conftest.err
12459   rm -f conftest.er1
12460   cat conftest.err >&5
12461   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12462   (exit $ac_status); } &&
12463          { ac_try='test -z "$ac_c_werror_flag"
12464                          || test ! -s conftest.err'
12465   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12466   (eval $ac_try) 2>&5
12467   ac_status=$?
12468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12469   (exit $ac_status); }; } &&
12470          { ac_try='test -s conftest.$ac_objext'
12471   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12472   (eval $ac_try) 2>&5
12473   ac_status=$?
12474   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12475   (exit $ac_status); }; }; then
12476   ac_cv_prog_cc_stdc=$ac_arg
12477 break
12478 else
12479   echo "$as_me: failed program was:" >&5
12480 sed 's/^/| /' conftest.$ac_ext >&5
12481
12482 fi
12483 rm -f conftest.err conftest.$ac_objext
12484 done
12485 rm -f conftest.$ac_ext conftest.$ac_objext
12486 CC=$ac_save_CC
12487
12488 fi
12489
12490 case "x$ac_cv_prog_cc_stdc" in
12491   x|xno)
12492     echo "$as_me:$LINENO: result: none needed" >&5
12493 echo "${ECHO_T}none needed" >&6 ;;
12494   *)
12495     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
12496 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
12497     CC="$CC $ac_cv_prog_cc_stdc" ;;
12498 esac
12499
12500 # Some people use a C++ compiler to compile C.  Since we use `exit',
12501 # in C++ we need to declare it.  In case someone uses the same compiler
12502 # for both compiling C and C++ we need to have the C++ compiler decide
12503 # the declaration of exit, since it's the most demanding environment.
12504 cat >conftest.$ac_ext <<_ACEOF
12505 #ifndef __cplusplus
12506   choke me
12507 #endif
12508 _ACEOF
12509 rm -f conftest.$ac_objext
12510 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12511   (eval $ac_compile) 2>conftest.er1
12512   ac_status=$?
12513   grep -v '^ *+' conftest.er1 >conftest.err
12514   rm -f conftest.er1
12515   cat conftest.err >&5
12516   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12517   (exit $ac_status); } &&
12518          { ac_try='test -z "$ac_c_werror_flag"
12519                          || test ! -s conftest.err'
12520   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12521   (eval $ac_try) 2>&5
12522   ac_status=$?
12523   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12524   (exit $ac_status); }; } &&
12525          { ac_try='test -s conftest.$ac_objext'
12526   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12527   (eval $ac_try) 2>&5
12528   ac_status=$?
12529   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12530   (exit $ac_status); }; }; then
12531   for ac_declaration in \
12532    '' \
12533    'extern "C" void std::exit (int) throw (); using std::exit;' \
12534    'extern "C" void std::exit (int); using std::exit;' \
12535    'extern "C" void exit (int) throw ();' \
12536    'extern "C" void exit (int);' \
12537    'void exit (int);'
12538 do
12539   cat >conftest.$ac_ext <<_ACEOF
12540 /* confdefs.h.  */
12541 _ACEOF
12542 cat confdefs.h >>conftest.$ac_ext
12543 cat >>conftest.$ac_ext <<_ACEOF
12544 /* end confdefs.h.  */
12545 $ac_declaration
12546 #include <stdlib.h>
12547 int
12548 main ()
12549 {
12550 exit (42);
12551   ;
12552   return 0;
12553 }
12554 _ACEOF
12555 rm -f conftest.$ac_objext
12556 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12557   (eval $ac_compile) 2>conftest.er1
12558   ac_status=$?
12559   grep -v '^ *+' conftest.er1 >conftest.err
12560   rm -f conftest.er1
12561   cat conftest.err >&5
12562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12563   (exit $ac_status); } &&
12564          { ac_try='test -z "$ac_c_werror_flag"
12565                          || test ! -s conftest.err'
12566   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12567   (eval $ac_try) 2>&5
12568   ac_status=$?
12569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12570   (exit $ac_status); }; } &&
12571          { ac_try='test -s conftest.$ac_objext'
12572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12573   (eval $ac_try) 2>&5
12574   ac_status=$?
12575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12576   (exit $ac_status); }; }; then
12577   :
12578 else
12579   echo "$as_me: failed program was:" >&5
12580 sed 's/^/| /' conftest.$ac_ext >&5
12581
12582 continue
12583 fi
12584 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12585   cat >conftest.$ac_ext <<_ACEOF
12586 /* confdefs.h.  */
12587 _ACEOF
12588 cat confdefs.h >>conftest.$ac_ext
12589 cat >>conftest.$ac_ext <<_ACEOF
12590 /* end confdefs.h.  */
12591 $ac_declaration
12592 int
12593 main ()
12594 {
12595 exit (42);
12596   ;
12597   return 0;
12598 }
12599 _ACEOF
12600 rm -f conftest.$ac_objext
12601 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12602   (eval $ac_compile) 2>conftest.er1
12603   ac_status=$?
12604   grep -v '^ *+' conftest.er1 >conftest.err
12605   rm -f conftest.er1
12606   cat conftest.err >&5
12607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12608   (exit $ac_status); } &&
12609          { ac_try='test -z "$ac_c_werror_flag"
12610                          || test ! -s conftest.err'
12611   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12612   (eval $ac_try) 2>&5
12613   ac_status=$?
12614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12615   (exit $ac_status); }; } &&
12616          { ac_try='test -s conftest.$ac_objext'
12617   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12618   (eval $ac_try) 2>&5
12619   ac_status=$?
12620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12621   (exit $ac_status); }; }; then
12622   break
12623 else
12624   echo "$as_me: failed program was:" >&5
12625 sed 's/^/| /' conftest.$ac_ext >&5
12626
12627 fi
12628 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12629 done
12630 rm -f conftest*
12631 if test -n "$ac_declaration"; then
12632   echo '#ifdef __cplusplus' >>confdefs.h
12633   echo $ac_declaration      >>confdefs.h
12634   echo '#endif'             >>confdefs.h
12635 fi
12636
12637 else
12638   echo "$as_me: failed program was:" >&5
12639 sed 's/^/| /' conftest.$ac_ext >&5
12640
12641 fi
12642 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12643 ac_ext=c
12644 ac_cpp='$CPP $CPPFLAGS'
12645 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
12646 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
12647 ac_compiler_gnu=$ac_cv_c_compiler_gnu
12648
12649 depcc="$CC"   am_compiler_list=
12650
12651 echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
12652 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6
12653 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
12654   echo $ECHO_N "(cached) $ECHO_C" >&6
12655 else
12656   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
12657   # We make a subdir and do the tests there.  Otherwise we can end up
12658   # making bogus files that we don't know about and never remove.  For
12659   # instance it was reported that on HP-UX the gcc test will end up
12660   # making a dummy file named `D' -- because `-MD' means `put the output
12661   # in D'.
12662   mkdir conftest.dir
12663   # Copy depcomp to subdir because otherwise we won't find it if we're
12664   # using a relative directory.
12665   cp "$am_depcomp" conftest.dir
12666   cd conftest.dir
12667   # We will build objects and dependencies in a subdirectory because
12668   # it helps to detect inapplicable dependency modes.  For instance
12669   # both Tru64's cc and ICC support -MD to output dependencies as a
12670   # side effect of compilation, but ICC will put the dependencies in
12671   # the current directory while Tru64 will put them in the object
12672   # directory.
12673   mkdir sub
12674
12675   am_cv_CC_dependencies_compiler_type=none
12676   if test "$am_compiler_list" = ""; then
12677      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
12678   fi
12679   for depmode in $am_compiler_list; do
12680     # Setup a source with many dependencies, because some compilers
12681     # like to wrap large dependency lists on column 80 (with \), and
12682     # we should not choose a depcomp mode which is confused by this.
12683     #
12684     # We need to recreate these files for each test, as the compiler may
12685     # overwrite some of them when testing with obscure command lines.
12686     # This happens at least with the AIX C compiler.
12687     : > sub/conftest.c
12688     for i in 1 2 3 4 5 6; do
12689       echo '#include "conftst'$i'.h"' >> sub/conftest.c
12690       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
12691       # Solaris 8's {/usr,}/bin/sh.
12692       touch sub/conftst$i.h
12693     done
12694     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
12695
12696     case $depmode in
12697     nosideeffect)
12698       # after this tag, mechanisms are not by side-effect, so they'll
12699       # only be used when explicitly requested
12700       if test "x$enable_dependency_tracking" = xyes; then
12701         continue
12702       else
12703         break
12704       fi
12705       ;;
12706     none) break ;;
12707     esac
12708     # We check with `-c' and `-o' for the sake of the "dashmstdout"
12709     # mode.  It turns out that the SunPro C++ compiler does not properly
12710     # handle `-M -o', and we need to detect this.
12711     if depmode=$depmode \
12712        source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
12713        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
12714        $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
12715          >/dev/null 2>conftest.err &&
12716        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
12717        grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
12718        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
12719       # icc doesn't choke on unknown options, it will just issue warnings
12720       # or remarks (even with -Werror).  So we grep stderr for any message
12721       # that says an option was ignored or not supported.
12722       # When given -MP, icc 7.0 and 7.1 complain thusly:
12723       #   icc: Command line warning: ignoring option '-M'; no argument required
12724       # The diagnosis changed in icc 8.0:
12725       #   icc: Command line remark: option '-MP' not supported
12726       if (grep 'ignoring option' conftest.err ||
12727           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
12728         am_cv_CC_dependencies_compiler_type=$depmode
12729         break
12730       fi
12731     fi
12732   done
12733
12734   cd ..
12735   rm -rf conftest.dir
12736 else
12737   am_cv_CC_dependencies_compiler_type=none
12738 fi
12739
12740 fi
12741 echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
12742 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6
12743 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
12744
12745
12746
12747 if
12748   test "x$enable_dependency_tracking" != xno \
12749   && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
12750   am__fastdepCC_TRUE=
12751   am__fastdepCC_FALSE='#'
12752 else
12753   am__fastdepCC_TRUE='#'
12754   am__fastdepCC_FALSE=
12755 fi
12756
12757
12758 if test "X${ac_cv_prog_cc_stdc}" = "Xno" ; then
12759         { { echo "$as_me:$LINENO: error: OpenLDAP requires compiler to support STDC constructs." >&5
12760 echo "$as_me: error: OpenLDAP requires compiler to support STDC constructs." >&2;}
12761    { (exit 1); exit 1; }; }
12762 fi
12763
12764 # test for make depend flag
12765 OL_MKDEP=
12766 OL_MKDEP_FLAGS=
12767 if test -z "${MKDEP}"; then
12768         OL_MKDEP="${CC-cc}"
12769         if test -z "${MKDEP_FLAGS}"; then
12770                 echo "$as_me:$LINENO: checking for ${OL_MKDEP} depend flag" >&5
12771 echo $ECHO_N "checking for ${OL_MKDEP} depend flag... $ECHO_C" >&6
12772 if test "${ol_cv_mkdep+set}" = set; then
12773   echo $ECHO_N "(cached) $ECHO_C" >&6
12774 else
12775
12776                         ol_cv_mkdep=no
12777                         for flag in "-M" "-xM"; do
12778                                 cat > conftest.c <<EOF
12779  noCode;
12780 EOF
12781                                 if { ac_try='$OL_MKDEP $flag conftest.c'
12782   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12783   (eval $ac_try) 2>&5
12784   ac_status=$?
12785   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12786   (exit $ac_status); }; } \
12787                                         | grep '^conftest\.'"${ac_objext}" >/dev/null 2>&1
12788                                 then
12789                                         if test ! -f conftest."${ac_object}" ; then
12790                                                 ol_cv_mkdep=$flag
12791                                                 OL_MKDEP_FLAGS="$flag"
12792                                                 break
12793                                         fi
12794                                 fi
12795                         done
12796                         rm -f conftest*
12797
12798 fi
12799 echo "$as_me:$LINENO: result: $ol_cv_mkdep" >&5
12800 echo "${ECHO_T}$ol_cv_mkdep" >&6
12801         else
12802                 cc_cv_mkdep=yes
12803                 OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
12804         fi
12805 else
12806         cc_cv_mkdep=yes
12807         OL_MKDEP="${MKDEP}"
12808         OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
12809 fi
12810
12811
12812
12813 if test "${ol_cv_mkdep}" = no ; then
12814         # this will soon become an error
12815         { echo "$as_me:$LINENO: WARNING: do not know how to generate dependencies" >&5
12816 echo "$as_me: WARNING: do not know how to generate dependencies" >&2;}
12817 fi
12818
12819 echo "$as_me:$LINENO: checking for afopen in -ls" >&5
12820 echo $ECHO_N "checking for afopen in -ls... $ECHO_C" >&6
12821 if test "${ac_cv_lib_s_afopen+set}" = set; then
12822   echo $ECHO_N "(cached) $ECHO_C" >&6
12823 else
12824   ac_check_lib_save_LIBS=$LIBS
12825 LIBS="-ls  $LIBS"
12826 cat >conftest.$ac_ext <<_ACEOF
12827 /* confdefs.h.  */
12828 _ACEOF
12829 cat confdefs.h >>conftest.$ac_ext
12830 cat >>conftest.$ac_ext <<_ACEOF
12831 /* end confdefs.h.  */
12832
12833 /* Override any gcc2 internal prototype to avoid an error.  */
12834 #ifdef __cplusplus
12835 extern "C"
12836 #endif
12837 /* We use char because int might match the return type of a gcc2
12838    builtin and then its argument prototype would still apply.  */
12839 char afopen ();
12840 int
12841 main ()
12842 {
12843 afopen ();
12844   ;
12845   return 0;
12846 }
12847 _ACEOF
12848 rm -f conftest.$ac_objext conftest$ac_exeext
12849 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12850   (eval $ac_link) 2>conftest.er1
12851   ac_status=$?
12852   grep -v '^ *+' conftest.er1 >conftest.err
12853   rm -f conftest.er1
12854   cat conftest.err >&5
12855   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12856   (exit $ac_status); } &&
12857          { ac_try='test -z "$ac_c_werror_flag"
12858                          || test ! -s conftest.err'
12859   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12860   (eval $ac_try) 2>&5
12861   ac_status=$?
12862   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12863   (exit $ac_status); }; } &&
12864          { ac_try='test -s conftest$ac_exeext'
12865   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12866   (eval $ac_try) 2>&5
12867   ac_status=$?
12868   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12869   (exit $ac_status); }; }; then
12870   ac_cv_lib_s_afopen=yes
12871 else
12872   echo "$as_me: failed program was:" >&5
12873 sed 's/^/| /' conftest.$ac_ext >&5
12874
12875 ac_cv_lib_s_afopen=no
12876 fi
12877 rm -f conftest.err conftest.$ac_objext \
12878       conftest$ac_exeext conftest.$ac_ext
12879 LIBS=$ac_check_lib_save_LIBS
12880 fi
12881 echo "$as_me:$LINENO: result: $ac_cv_lib_s_afopen" >&5
12882 echo "${ECHO_T}$ac_cv_lib_s_afopen" >&6
12883 if test $ac_cv_lib_s_afopen = yes; then
12884
12885         AUTH_LIBS=-ls
12886
12887 cat >>confdefs.h <<\_ACEOF
12888 #define HAVE_AIX_SECURITY 1
12889 _ACEOF
12890
12891
12892 fi
12893
12894
12895 case "$target" in
12896 *-ibm-openedition)
12897         ac_cv_func_getopt=no
12898
12899 cat >>confdefs.h <<\_ACEOF
12900 #define BOTH_STRINGS_H 1
12901 _ACEOF
12902
12903         ;;
12904 esac
12905
12906 ol_link_modules=no
12907 WITH_MODULES_ENABLED=no
12908 if test $ol_enable_modules != no ; then
12909
12910 for ac_header in ltdl.h
12911 do
12912 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12913 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12914   echo "$as_me:$LINENO: checking for $ac_header" >&5
12915 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12916 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12917   echo $ECHO_N "(cached) $ECHO_C" >&6
12918 fi
12919 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12920 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12921 else
12922   # Is the header compilable?
12923 echo "$as_me:$LINENO: checking $ac_header usability" >&5
12924 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
12925 cat >conftest.$ac_ext <<_ACEOF
12926 /* confdefs.h.  */
12927 _ACEOF
12928 cat confdefs.h >>conftest.$ac_ext
12929 cat >>conftest.$ac_ext <<_ACEOF
12930 /* end confdefs.h.  */
12931 $ac_includes_default
12932 #include <$ac_header>
12933 _ACEOF
12934 rm -f conftest.$ac_objext
12935 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12936   (eval $ac_compile) 2>conftest.er1
12937   ac_status=$?
12938   grep -v '^ *+' conftest.er1 >conftest.err
12939   rm -f conftest.er1
12940   cat conftest.err >&5
12941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12942   (exit $ac_status); } &&
12943          { ac_try='test -z "$ac_c_werror_flag"
12944                          || test ! -s conftest.err'
12945   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12946   (eval $ac_try) 2>&5
12947   ac_status=$?
12948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12949   (exit $ac_status); }; } &&
12950          { ac_try='test -s conftest.$ac_objext'
12951   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12952   (eval $ac_try) 2>&5
12953   ac_status=$?
12954   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12955   (exit $ac_status); }; }; then
12956   ac_header_compiler=yes
12957 else
12958   echo "$as_me: failed program was:" >&5
12959 sed 's/^/| /' conftest.$ac_ext >&5
12960
12961 ac_header_compiler=no
12962 fi
12963 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12964 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12965 echo "${ECHO_T}$ac_header_compiler" >&6
12966
12967 # Is the header present?
12968 echo "$as_me:$LINENO: checking $ac_header presence" >&5
12969 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
12970 cat >conftest.$ac_ext <<_ACEOF
12971 /* confdefs.h.  */
12972 _ACEOF
12973 cat confdefs.h >>conftest.$ac_ext
12974 cat >>conftest.$ac_ext <<_ACEOF
12975 /* end confdefs.h.  */
12976 #include <$ac_header>
12977 _ACEOF
12978 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
12979   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12980   ac_status=$?
12981   grep -v '^ *+' conftest.er1 >conftest.err
12982   rm -f conftest.er1
12983   cat conftest.err >&5
12984   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12985   (exit $ac_status); } >/dev/null; then
12986   if test -s conftest.err; then
12987     ac_cpp_err=$ac_c_preproc_warn_flag
12988     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
12989   else
12990     ac_cpp_err=
12991   fi
12992 else
12993   ac_cpp_err=yes
12994 fi
12995 if test -z "$ac_cpp_err"; then
12996   ac_header_preproc=yes
12997 else
12998   echo "$as_me: failed program was:" >&5
12999 sed 's/^/| /' conftest.$ac_ext >&5
13000
13001   ac_header_preproc=no
13002 fi
13003 rm -f conftest.err conftest.$ac_ext
13004 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13005 echo "${ECHO_T}$ac_header_preproc" >&6
13006
13007 # So?  What about this header?
13008 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13009   yes:no: )
13010     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13011 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13012     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13013 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13014     ac_header_preproc=yes
13015     ;;
13016   no:yes:* )
13017     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13018 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13019     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13020 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13021     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13022 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13023     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13024 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13025     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13026 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13027     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13028 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13029     (
13030       cat <<\_ASBOX
13031 ## --------------------------------------------- ##
13032 ## Report this to <http://www.openldap.org/its/> ##
13033 ## --------------------------------------------- ##
13034 _ASBOX
13035     ) |
13036       sed "s/^/$as_me: WARNING:     /" >&2
13037     ;;
13038 esac
13039 echo "$as_me:$LINENO: checking for $ac_header" >&5
13040 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13041 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13042   echo $ECHO_N "(cached) $ECHO_C" >&6
13043 else
13044   eval "$as_ac_Header=\$ac_header_preproc"
13045 fi
13046 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13047 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13048
13049 fi
13050 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13051   cat >>confdefs.h <<_ACEOF
13052 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13053 _ACEOF
13054
13055 fi
13056
13057 done
13058
13059
13060         if test $ac_cv_header_ltdl_h = no ; then
13061                 { { echo "$as_me:$LINENO: error: could not locate libtool ltdl.h" >&5
13062 echo "$as_me: error: could not locate libtool ltdl.h" >&2;}
13063    { (exit 1); exit 1; }; }
13064         fi
13065
13066         echo "$as_me:$LINENO: checking for lt_dlinit in -lltdl" >&5
13067 echo $ECHO_N "checking for lt_dlinit in -lltdl... $ECHO_C" >&6
13068 if test "${ac_cv_lib_ltdl_lt_dlinit+set}" = set; then
13069   echo $ECHO_N "(cached) $ECHO_C" >&6
13070 else
13071   ac_check_lib_save_LIBS=$LIBS
13072 LIBS="-lltdl  $LIBS"
13073 cat >conftest.$ac_ext <<_ACEOF
13074 /* confdefs.h.  */
13075 _ACEOF
13076 cat confdefs.h >>conftest.$ac_ext
13077 cat >>conftest.$ac_ext <<_ACEOF
13078 /* end confdefs.h.  */
13079
13080 /* Override any gcc2 internal prototype to avoid an error.  */
13081 #ifdef __cplusplus
13082 extern "C"
13083 #endif
13084 /* We use char because int might match the return type of a gcc2
13085    builtin and then its argument prototype would still apply.  */
13086 char lt_dlinit ();
13087 int
13088 main ()
13089 {
13090 lt_dlinit ();
13091   ;
13092   return 0;
13093 }
13094 _ACEOF
13095 rm -f conftest.$ac_objext conftest$ac_exeext
13096 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13097   (eval $ac_link) 2>conftest.er1
13098   ac_status=$?
13099   grep -v '^ *+' conftest.er1 >conftest.err
13100   rm -f conftest.er1
13101   cat conftest.err >&5
13102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13103   (exit $ac_status); } &&
13104          { ac_try='test -z "$ac_c_werror_flag"
13105                          || test ! -s conftest.err'
13106   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13107   (eval $ac_try) 2>&5
13108   ac_status=$?
13109   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13110   (exit $ac_status); }; } &&
13111          { ac_try='test -s conftest$ac_exeext'
13112   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13113   (eval $ac_try) 2>&5
13114   ac_status=$?
13115   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13116   (exit $ac_status); }; }; then
13117   ac_cv_lib_ltdl_lt_dlinit=yes
13118 else
13119   echo "$as_me: failed program was:" >&5
13120 sed 's/^/| /' conftest.$ac_ext >&5
13121
13122 ac_cv_lib_ltdl_lt_dlinit=no
13123 fi
13124 rm -f conftest.err conftest.$ac_objext \
13125       conftest$ac_exeext conftest.$ac_ext
13126 LIBS=$ac_check_lib_save_LIBS
13127 fi
13128 echo "$as_me:$LINENO: result: $ac_cv_lib_ltdl_lt_dlinit" >&5
13129 echo "${ECHO_T}$ac_cv_lib_ltdl_lt_dlinit" >&6
13130 if test $ac_cv_lib_ltdl_lt_dlinit = yes; then
13131
13132                 MODULES_LIBS=-lltdl
13133
13134 cat >>confdefs.h <<\_ACEOF
13135 #define HAVE_LIBLTDL 1
13136 _ACEOF
13137
13138
13139 fi
13140
13141
13142         if test "$ac_cv_lib_ltdl_lt_dlinit" = no ; then
13143                 { { echo "$as_me:$LINENO: error: could not locate libtool -lltdl" >&5
13144 echo "$as_me: error: could not locate libtool -lltdl" >&2;}
13145    { (exit 1); exit 1; }; }
13146         fi
13147         ol_link_modules=yes
13148         WITH_MODULES_ENABLED=yes
13149
13150 else
13151         for i in $Backends; do
13152                 eval "ol_tmp=\$ol_enable_$i"
13153                 if test $ol_tmp = mod ; then
13154                         { echo "$as_me:$LINENO: WARNING: building static $i backend" >&5
13155 echo "$as_me: WARNING: building static $i backend" >&2;}
13156                         eval "ol_enable_$i=yes"
13157                 fi
13158         done
13159         for i in $Overlays; do
13160                 eval "ol_tmp=\$ol_enable_$i"
13161                 if test $ol_tmp = mod ; then
13162                         { echo "$as_me:$LINENO: WARNING: building static $i overlay" >&5
13163 echo "$as_me: WARNING: building static $i overlay" >&2;}
13164                         eval "ol_enable_$i=yes"
13165                 fi
13166         done
13167 fi
13168
13169 # test for EBCDIC
13170 echo "$as_me:$LINENO: checking for EBCDIC" >&5
13171 echo $ECHO_N "checking for EBCDIC... $ECHO_C" >&6
13172 if test "${ol_cv_cpp_ebcdic+set}" = set; then
13173   echo $ECHO_N "(cached) $ECHO_C" >&6
13174 else
13175
13176         cat >conftest.$ac_ext <<_ACEOF
13177 /* confdefs.h.  */
13178 _ACEOF
13179 cat confdefs.h >>conftest.$ac_ext
13180 cat >>conftest.$ac_ext <<_ACEOF
13181 /* end confdefs.h.  */
13182
13183 #if !('M' == 0xd4)
13184 #include <__ASCII__/generate_error.h>
13185 #endif
13186
13187 _ACEOF
13188 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13189   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13190   ac_status=$?
13191   grep -v '^ *+' conftest.er1 >conftest.err
13192   rm -f conftest.er1
13193   cat conftest.err >&5
13194   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13195   (exit $ac_status); } >/dev/null; then
13196   if test -s conftest.err; then
13197     ac_cpp_err=$ac_c_preproc_warn_flag
13198     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
13199   else
13200     ac_cpp_err=
13201   fi
13202 else
13203   ac_cpp_err=yes
13204 fi
13205 if test -z "$ac_cpp_err"; then
13206   ol_cv_cpp_ebcdic=yes
13207 else
13208   echo "$as_me: failed program was:" >&5
13209 sed 's/^/| /' conftest.$ac_ext >&5
13210
13211   ol_cv_cpp_ebcdic=no
13212 fi
13213 rm -f conftest.err conftest.$ac_ext
13214 fi
13215 echo "$as_me:$LINENO: result: $ol_cv_cpp_ebcdic" >&5
13216 echo "${ECHO_T}$ol_cv_cpp_ebcdic" >&6
13217 if test $ol_cv_cpp_ebcdic = yes ; then
13218
13219 cat >>confdefs.h <<\_ACEOF
13220 #define HAVE_EBCDIC 1
13221 _ACEOF
13222
13223 fi
13224
13225 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
13226 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
13227 if test "${ol_cv_header_stdc+set}" = set; then
13228   echo $ECHO_N "(cached) $ECHO_C" >&6
13229 else
13230   cat >conftest.$ac_ext <<_ACEOF
13231 /* confdefs.h.  */
13232 _ACEOF
13233 cat confdefs.h >>conftest.$ac_ext
13234 cat >>conftest.$ac_ext <<_ACEOF
13235 /* end confdefs.h.  */
13236 #include <stdlib.h>
13237 #include <stdarg.h>
13238 #include <string.h>
13239 #include <float.h>
13240 _ACEOF
13241 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13242   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13243   ac_status=$?
13244   grep -v '^ *+' conftest.er1 >conftest.err
13245   rm -f conftest.er1
13246   cat conftest.err >&5
13247   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13248   (exit $ac_status); } >/dev/null; then
13249   if test -s conftest.err; then
13250     ac_cpp_err=$ac_c_preproc_warn_flag
13251     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
13252   else
13253     ac_cpp_err=
13254   fi
13255 else
13256   ac_cpp_err=yes
13257 fi
13258 if test -z "$ac_cpp_err"; then
13259   ol_cv_header_stdc=yes
13260 else
13261   echo "$as_me: failed program was:" >&5
13262 sed 's/^/| /' conftest.$ac_ext >&5
13263
13264   ol_cv_header_stdc=no
13265 fi
13266 rm -f conftest.err conftest.$ac_ext
13267
13268 if test $ol_cv_header_stdc = yes; then
13269   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13270 cat >conftest.$ac_ext <<_ACEOF
13271 /* confdefs.h.  */
13272 _ACEOF
13273 cat confdefs.h >>conftest.$ac_ext
13274 cat >>conftest.$ac_ext <<_ACEOF
13275 /* end confdefs.h.  */
13276 #include <string.h>
13277
13278 _ACEOF
13279 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13280   $EGREP "memchr" >/dev/null 2>&1; then
13281   :
13282 else
13283   ol_cv_header_stdc=no
13284 fi
13285 rm -f conftest*
13286
13287 fi
13288
13289 if test $ol_cv_header_stdc = yes; then
13290   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13291 cat >conftest.$ac_ext <<_ACEOF
13292 /* confdefs.h.  */
13293 _ACEOF
13294 cat confdefs.h >>conftest.$ac_ext
13295 cat >>conftest.$ac_ext <<_ACEOF
13296 /* end confdefs.h.  */
13297 #include <stdlib.h>
13298
13299 _ACEOF
13300 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13301   $EGREP "free" >/dev/null 2>&1; then
13302   :
13303 else
13304   ol_cv_header_stdc=no
13305 fi
13306 rm -f conftest*
13307
13308 fi
13309
13310 if test $ol_cv_header_stdc = yes; then
13311   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13312 if test "$cross_compiling" = yes; then
13313   :
13314 else
13315   cat >conftest.$ac_ext <<_ACEOF
13316 /* confdefs.h.  */
13317 _ACEOF
13318 cat confdefs.h >>conftest.$ac_ext
13319 cat >>conftest.$ac_ext <<_ACEOF
13320 /* end confdefs.h.  */
13321 #include <ctype.h>
13322 #ifndef HAVE_EBCDIC
13323 #       define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13324 #       define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13325 #else
13326 #       define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13327                 || ('j' <= (c) && (c) <= 'r') \
13328                 || ('s' <= (c) && (c) <= 'z'))
13329 #       define TOUPPER(c)       (ISLOWER(c) ? ((c) | 0x40) : (c))
13330 #endif
13331 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13332 int main () { int i; for (i = 0; i < 256; i++)
13333 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
13334 exit (0); }
13335
13336 _ACEOF
13337 rm -f conftest$ac_exeext
13338 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13339   (eval $ac_link) 2>&5
13340   ac_status=$?
13341   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13342   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13343   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13344   (eval $ac_try) 2>&5
13345   ac_status=$?
13346   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13347   (exit $ac_status); }; }; then
13348   :
13349 else
13350   echo "$as_me: program exited with status $ac_status" >&5
13351 echo "$as_me: failed program was:" >&5
13352 sed 's/^/| /' conftest.$ac_ext >&5
13353
13354 ( exit $ac_status )
13355 ol_cv_header_stdc=no
13356 fi
13357 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13358 fi
13359 fi
13360 fi
13361 echo "$as_me:$LINENO: result: $ol_cv_header_stdc" >&5
13362 echo "${ECHO_T}$ol_cv_header_stdc" >&6
13363 if test $ol_cv_header_stdc = yes; then
13364   cat >>confdefs.h <<\_ACEOF
13365 #define STDC_HEADERS 1
13366 _ACEOF
13367
13368 fi
13369 ac_cv_header_stdc=disable
13370
13371
13372 if test $ol_cv_header_stdc != yes; then
13373         { echo "$as_me:$LINENO: WARNING: could not locate Standard C compliant headers" >&5
13374 echo "$as_me: WARNING: could not locate Standard C compliant headers" >&2;}
13375 fi
13376
13377
13378
13379
13380
13381
13382 ac_header_dirent=no
13383 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
13384   as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
13385 echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
13386 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
13387 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13388   echo $ECHO_N "(cached) $ECHO_C" >&6
13389 else
13390   cat >conftest.$ac_ext <<_ACEOF
13391 /* confdefs.h.  */
13392 _ACEOF
13393 cat confdefs.h >>conftest.$ac_ext
13394 cat >>conftest.$ac_ext <<_ACEOF
13395 /* end confdefs.h.  */
13396 #include <sys/types.h>
13397 #include <$ac_hdr>
13398
13399 int
13400 main ()
13401 {
13402 if ((DIR *) 0)
13403 return 0;
13404   ;
13405   return 0;
13406 }
13407 _ACEOF
13408 rm -f conftest.$ac_objext
13409 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13410   (eval $ac_compile) 2>conftest.er1
13411   ac_status=$?
13412   grep -v '^ *+' conftest.er1 >conftest.err
13413   rm -f conftest.er1
13414   cat conftest.err >&5
13415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13416   (exit $ac_status); } &&
13417          { ac_try='test -z "$ac_c_werror_flag"
13418                          || test ! -s conftest.err'
13419   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13420   (eval $ac_try) 2>&5
13421   ac_status=$?
13422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13423   (exit $ac_status); }; } &&
13424          { ac_try='test -s conftest.$ac_objext'
13425   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13426   (eval $ac_try) 2>&5
13427   ac_status=$?
13428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13429   (exit $ac_status); }; }; then
13430   eval "$as_ac_Header=yes"
13431 else
13432   echo "$as_me: failed program was:" >&5
13433 sed 's/^/| /' conftest.$ac_ext >&5
13434
13435 eval "$as_ac_Header=no"
13436 fi
13437 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13438 fi
13439 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13440 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13441 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13442   cat >>confdefs.h <<_ACEOF
13443 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
13444 _ACEOF
13445
13446 ac_header_dirent=$ac_hdr; break
13447 fi
13448
13449 done
13450 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
13451 if test $ac_header_dirent = dirent.h; then
13452   echo "$as_me:$LINENO: checking for library containing opendir" >&5
13453 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
13454 if test "${ac_cv_search_opendir+set}" = set; then
13455   echo $ECHO_N "(cached) $ECHO_C" >&6
13456 else
13457   ac_func_search_save_LIBS=$LIBS
13458 ac_cv_search_opendir=no
13459 cat >conftest.$ac_ext <<_ACEOF
13460 /* confdefs.h.  */
13461 _ACEOF
13462 cat confdefs.h >>conftest.$ac_ext
13463 cat >>conftest.$ac_ext <<_ACEOF
13464 /* end confdefs.h.  */
13465
13466 /* Override any gcc2 internal prototype to avoid an error.  */
13467 #ifdef __cplusplus
13468 extern "C"
13469 #endif
13470 /* We use char because int might match the return type of a gcc2
13471    builtin and then its argument prototype would still apply.  */
13472 char opendir ();
13473 int
13474 main ()
13475 {
13476 opendir ();
13477   ;
13478   return 0;
13479 }
13480 _ACEOF
13481 rm -f conftest.$ac_objext conftest$ac_exeext
13482 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13483   (eval $ac_link) 2>conftest.er1
13484   ac_status=$?
13485   grep -v '^ *+' conftest.er1 >conftest.err
13486   rm -f conftest.er1
13487   cat conftest.err >&5
13488   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13489   (exit $ac_status); } &&
13490          { ac_try='test -z "$ac_c_werror_flag"
13491                          || test ! -s conftest.err'
13492   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13493   (eval $ac_try) 2>&5
13494   ac_status=$?
13495   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13496   (exit $ac_status); }; } &&
13497          { ac_try='test -s conftest$ac_exeext'
13498   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13499   (eval $ac_try) 2>&5
13500   ac_status=$?
13501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13502   (exit $ac_status); }; }; then
13503   ac_cv_search_opendir="none required"
13504 else
13505   echo "$as_me: failed program was:" >&5
13506 sed 's/^/| /' conftest.$ac_ext >&5
13507
13508 fi
13509 rm -f conftest.err conftest.$ac_objext \
13510       conftest$ac_exeext conftest.$ac_ext
13511 if test "$ac_cv_search_opendir" = no; then
13512   for ac_lib in dir; do
13513     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
13514     cat >conftest.$ac_ext <<_ACEOF
13515 /* confdefs.h.  */
13516 _ACEOF
13517 cat confdefs.h >>conftest.$ac_ext
13518 cat >>conftest.$ac_ext <<_ACEOF
13519 /* end confdefs.h.  */
13520
13521 /* Override any gcc2 internal prototype to avoid an error.  */
13522 #ifdef __cplusplus
13523 extern "C"
13524 #endif
13525 /* We use char because int might match the return type of a gcc2
13526    builtin and then its argument prototype would still apply.  */
13527 char opendir ();
13528 int
13529 main ()
13530 {
13531 opendir ();
13532   ;
13533   return 0;
13534 }
13535 _ACEOF
13536 rm -f conftest.$ac_objext conftest$ac_exeext
13537 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13538   (eval $ac_link) 2>conftest.er1
13539   ac_status=$?
13540   grep -v '^ *+' conftest.er1 >conftest.err
13541   rm -f conftest.er1
13542   cat conftest.err >&5
13543   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13544   (exit $ac_status); } &&
13545          { ac_try='test -z "$ac_c_werror_flag"
13546                          || test ! -s conftest.err'
13547   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13548   (eval $ac_try) 2>&5
13549   ac_status=$?
13550   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13551   (exit $ac_status); }; } &&
13552          { ac_try='test -s conftest$ac_exeext'
13553   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13554   (eval $ac_try) 2>&5
13555   ac_status=$?
13556   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13557   (exit $ac_status); }; }; then
13558   ac_cv_search_opendir="-l$ac_lib"
13559 break
13560 else
13561   echo "$as_me: failed program was:" >&5
13562 sed 's/^/| /' conftest.$ac_ext >&5
13563
13564 fi
13565 rm -f conftest.err conftest.$ac_objext \
13566       conftest$ac_exeext conftest.$ac_ext
13567   done
13568 fi
13569 LIBS=$ac_func_search_save_LIBS
13570 fi
13571 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
13572 echo "${ECHO_T}$ac_cv_search_opendir" >&6
13573 if test "$ac_cv_search_opendir" != no; then
13574   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
13575
13576 fi
13577
13578 else
13579   echo "$as_me:$LINENO: checking for library containing opendir" >&5
13580 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
13581 if test "${ac_cv_search_opendir+set}" = set; then
13582   echo $ECHO_N "(cached) $ECHO_C" >&6
13583 else
13584   ac_func_search_save_LIBS=$LIBS
13585 ac_cv_search_opendir=no
13586 cat >conftest.$ac_ext <<_ACEOF
13587 /* confdefs.h.  */
13588 _ACEOF
13589 cat confdefs.h >>conftest.$ac_ext
13590 cat >>conftest.$ac_ext <<_ACEOF
13591 /* end confdefs.h.  */
13592
13593 /* Override any gcc2 internal prototype to avoid an error.  */
13594 #ifdef __cplusplus
13595 extern "C"
13596 #endif
13597 /* We use char because int might match the return type of a gcc2
13598    builtin and then its argument prototype would still apply.  */
13599 char opendir ();
13600 int
13601 main ()
13602 {
13603 opendir ();
13604   ;
13605   return 0;
13606 }
13607 _ACEOF
13608 rm -f conftest.$ac_objext conftest$ac_exeext
13609 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13610   (eval $ac_link) 2>conftest.er1
13611   ac_status=$?
13612   grep -v '^ *+' conftest.er1 >conftest.err
13613   rm -f conftest.er1
13614   cat conftest.err >&5
13615   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13616   (exit $ac_status); } &&
13617          { ac_try='test -z "$ac_c_werror_flag"
13618                          || test ! -s conftest.err'
13619   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13620   (eval $ac_try) 2>&5
13621   ac_status=$?
13622   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13623   (exit $ac_status); }; } &&
13624          { ac_try='test -s conftest$ac_exeext'
13625   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13626   (eval $ac_try) 2>&5
13627   ac_status=$?
13628   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13629   (exit $ac_status); }; }; then
13630   ac_cv_search_opendir="none required"
13631 else
13632   echo "$as_me: failed program was:" >&5
13633 sed 's/^/| /' conftest.$ac_ext >&5
13634
13635 fi
13636 rm -f conftest.err conftest.$ac_objext \
13637       conftest$ac_exeext conftest.$ac_ext
13638 if test "$ac_cv_search_opendir" = no; then
13639   for ac_lib in x; do
13640     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
13641     cat >conftest.$ac_ext <<_ACEOF
13642 /* confdefs.h.  */
13643 _ACEOF
13644 cat confdefs.h >>conftest.$ac_ext
13645 cat >>conftest.$ac_ext <<_ACEOF
13646 /* end confdefs.h.  */
13647
13648 /* Override any gcc2 internal prototype to avoid an error.  */
13649 #ifdef __cplusplus
13650 extern "C"
13651 #endif
13652 /* We use char because int might match the return type of a gcc2
13653    builtin and then its argument prototype would still apply.  */
13654 char opendir ();
13655 int
13656 main ()
13657 {
13658 opendir ();
13659   ;
13660   return 0;
13661 }
13662 _ACEOF
13663 rm -f conftest.$ac_objext conftest$ac_exeext
13664 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13665   (eval $ac_link) 2>conftest.er1
13666   ac_status=$?
13667   grep -v '^ *+' conftest.er1 >conftest.err
13668   rm -f conftest.er1
13669   cat conftest.err >&5
13670   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13671   (exit $ac_status); } &&
13672          { ac_try='test -z "$ac_c_werror_flag"
13673                          || test ! -s conftest.err'
13674   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13675   (eval $ac_try) 2>&5
13676   ac_status=$?
13677   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13678   (exit $ac_status); }; } &&
13679          { ac_try='test -s conftest$ac_exeext'
13680   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13681   (eval $ac_try) 2>&5
13682   ac_status=$?
13683   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13684   (exit $ac_status); }; }; then
13685   ac_cv_search_opendir="-l$ac_lib"
13686 break
13687 else
13688   echo "$as_me: failed program was:" >&5
13689 sed 's/^/| /' conftest.$ac_ext >&5
13690
13691 fi
13692 rm -f conftest.err conftest.$ac_objext \
13693       conftest$ac_exeext conftest.$ac_ext
13694   done
13695 fi
13696 LIBS=$ac_func_search_save_LIBS
13697 fi
13698 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
13699 echo "${ECHO_T}$ac_cv_search_opendir" >&6
13700 if test "$ac_cv_search_opendir" != no; then
13701   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
13702
13703 fi
13704
13705 fi
13706
13707 echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
13708 echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
13709 if test "${ac_cv_header_sys_wait_h+set}" = set; then
13710   echo $ECHO_N "(cached) $ECHO_C" >&6
13711 else
13712   cat >conftest.$ac_ext <<_ACEOF
13713 /* confdefs.h.  */
13714 _ACEOF
13715 cat confdefs.h >>conftest.$ac_ext
13716 cat >>conftest.$ac_ext <<_ACEOF
13717 /* end confdefs.h.  */
13718 #include <sys/types.h>
13719 #include <sys/wait.h>
13720 #ifndef WEXITSTATUS
13721 # define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
13722 #endif
13723 #ifndef WIFEXITED
13724 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
13725 #endif
13726
13727 int
13728 main ()
13729 {
13730   int s;
13731   wait (&s);
13732   s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
13733   ;
13734   return 0;
13735 }
13736 _ACEOF
13737 rm -f conftest.$ac_objext
13738 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13739   (eval $ac_compile) 2>conftest.er1
13740   ac_status=$?
13741   grep -v '^ *+' conftest.er1 >conftest.err
13742   rm -f conftest.er1
13743   cat conftest.err >&5
13744   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13745   (exit $ac_status); } &&
13746          { ac_try='test -z "$ac_c_werror_flag"
13747                          || test ! -s conftest.err'
13748   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13749   (eval $ac_try) 2>&5
13750   ac_status=$?
13751   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13752   (exit $ac_status); }; } &&
13753          { ac_try='test -s conftest.$ac_objext'
13754   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13755   (eval $ac_try) 2>&5
13756   ac_status=$?
13757   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13758   (exit $ac_status); }; }; then
13759   ac_cv_header_sys_wait_h=yes
13760 else
13761   echo "$as_me: failed program was:" >&5
13762 sed 's/^/| /' conftest.$ac_ext >&5
13763
13764 ac_cv_header_sys_wait_h=no
13765 fi
13766 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13767 fi
13768 echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
13769 echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
13770 if test $ac_cv_header_sys_wait_h = yes; then
13771
13772 cat >>confdefs.h <<\_ACEOF
13773 #define HAVE_SYS_WAIT_H 1
13774 _ACEOF
13775
13776 fi
13777
13778 echo "$as_me:$LINENO: checking whether termios.h defines TIOCGWINSZ" >&5
13779 echo $ECHO_N "checking whether termios.h defines TIOCGWINSZ... $ECHO_C" >&6
13780 if test "${ac_cv_sys_tiocgwinsz_in_termios_h+set}" = set; then
13781   echo $ECHO_N "(cached) $ECHO_C" >&6
13782 else
13783   cat >conftest.$ac_ext <<_ACEOF
13784 /* confdefs.h.  */
13785 _ACEOF
13786 cat confdefs.h >>conftest.$ac_ext
13787 cat >>conftest.$ac_ext <<_ACEOF
13788 /* end confdefs.h.  */
13789 #include <sys/types.h>
13790 #include <termios.h>
13791 #ifdef TIOCGWINSZ
13792   yes
13793 #endif
13794
13795 _ACEOF
13796 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13797   $EGREP "yes" >/dev/null 2>&1; then
13798   ac_cv_sys_tiocgwinsz_in_termios_h=yes
13799 else
13800   ac_cv_sys_tiocgwinsz_in_termios_h=no
13801 fi
13802 rm -f conftest*
13803
13804 fi
13805 echo "$as_me:$LINENO: result: $ac_cv_sys_tiocgwinsz_in_termios_h" >&5
13806 echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_termios_h" >&6
13807
13808 if test $ac_cv_sys_tiocgwinsz_in_termios_h != yes; then
13809   echo "$as_me:$LINENO: checking whether sys/ioctl.h defines TIOCGWINSZ" >&5
13810 echo $ECHO_N "checking whether sys/ioctl.h defines TIOCGWINSZ... $ECHO_C" >&6
13811 if test "${ac_cv_sys_tiocgwinsz_in_sys_ioctl_h+set}" = set; then
13812   echo $ECHO_N "(cached) $ECHO_C" >&6
13813 else
13814   cat >conftest.$ac_ext <<_ACEOF
13815 /* confdefs.h.  */
13816 _ACEOF
13817 cat confdefs.h >>conftest.$ac_ext
13818 cat >>conftest.$ac_ext <<_ACEOF
13819 /* end confdefs.h.  */
13820 #include <sys/types.h>
13821 #include <sys/ioctl.h>
13822 #ifdef TIOCGWINSZ
13823   yes
13824 #endif
13825
13826 _ACEOF
13827 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13828   $EGREP "yes" >/dev/null 2>&1; then
13829   ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=yes
13830 else
13831   ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=no
13832 fi
13833 rm -f conftest*
13834
13835 fi
13836 echo "$as_me:$LINENO: result: $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&5
13837 echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&6
13838
13839   if test $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h = yes; then
13840
13841 cat >>confdefs.h <<\_ACEOF
13842 #define GWINSZ_IN_SYS_IOCTL 1
13843 _ACEOF
13844
13845   fi
13846 fi
13847
13848
13849
13850
13851
13852
13853
13854
13855
13856
13857
13858
13859
13860
13861
13862
13863
13864
13865
13866
13867
13868
13869
13870
13871
13872
13873
13874
13875
13876
13877
13878
13879
13880
13881
13882
13883
13884
13885
13886
13887
13888
13889
13890
13891
13892
13893
13894
13895 for ac_header in \
13896         arpa/inet.h             \
13897         arpa/nameser.h  \
13898         assert.h                \
13899         bits/types.h    \
13900         conio.h                 \
13901         crypt.h                 \
13902         direct.h                \
13903         errno.h                 \
13904         fcntl.h                 \
13905         filio.h                 \
13906         getopt.h                \
13907         grp.h                   \
13908         io.h                    \
13909         libutil.h               \
13910         limits.h                \
13911         locale.h                \
13912         malloc.h                \
13913         memory.h                \
13914         psap.h                  \
13915         pwd.h                   \
13916         process.h               \
13917         sgtty.h                 \
13918         shadow.h                \
13919         stddef.h                \
13920         string.h                \
13921         strings.h               \
13922         sysexits.h              \
13923         sys/file.h              \
13924         sys/filio.h             \
13925         sys/errno.h             \
13926         sys/ioctl.h             \
13927         sys/param.h             \
13928         sys/resource.h  \
13929         sys/select.h    \
13930         sys/socket.h    \
13931         sys/stat.h              \
13932         sys/syslog.h    \
13933         sys/time.h              \
13934         sys/types.h             \
13935         sys/uio.h               \
13936         syslog.h                \
13937         termios.h               \
13938         unistd.h                \
13939         utime.h                 \
13940         winsock.h               \
13941         winsock2.h              \
13942
13943 do
13944 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13945 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13946   echo "$as_me:$LINENO: checking for $ac_header" >&5
13947 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13948 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13949   echo $ECHO_N "(cached) $ECHO_C" >&6
13950 fi
13951 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13952 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13953 else
13954   # Is the header compilable?
13955 echo "$as_me:$LINENO: checking $ac_header usability" >&5
13956 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13957 cat >conftest.$ac_ext <<_ACEOF
13958 /* confdefs.h.  */
13959 _ACEOF
13960 cat confdefs.h >>conftest.$ac_ext
13961 cat >>conftest.$ac_ext <<_ACEOF
13962 /* end confdefs.h.  */
13963 $ac_includes_default
13964 #include <$ac_header>
13965 _ACEOF
13966 rm -f conftest.$ac_objext
13967 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13968   (eval $ac_compile) 2>conftest.er1
13969   ac_status=$?
13970   grep -v '^ *+' conftest.er1 >conftest.err
13971   rm -f conftest.er1
13972   cat conftest.err >&5
13973   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13974   (exit $ac_status); } &&
13975          { ac_try='test -z "$ac_c_werror_flag"
13976                          || test ! -s conftest.err'
13977   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13978   (eval $ac_try) 2>&5
13979   ac_status=$?
13980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13981   (exit $ac_status); }; } &&
13982          { ac_try='test -s conftest.$ac_objext'
13983   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13984   (eval $ac_try) 2>&5
13985   ac_status=$?
13986   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13987   (exit $ac_status); }; }; then
13988   ac_header_compiler=yes
13989 else
13990   echo "$as_me: failed program was:" >&5
13991 sed 's/^/| /' conftest.$ac_ext >&5
13992
13993 ac_header_compiler=no
13994 fi
13995 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13996 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13997 echo "${ECHO_T}$ac_header_compiler" >&6
13998
13999 # Is the header present?
14000 echo "$as_me:$LINENO: checking $ac_header presence" >&5
14001 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
14002 cat >conftest.$ac_ext <<_ACEOF
14003 /* confdefs.h.  */
14004 _ACEOF
14005 cat confdefs.h >>conftest.$ac_ext
14006 cat >>conftest.$ac_ext <<_ACEOF
14007 /* end confdefs.h.  */
14008 #include <$ac_header>
14009 _ACEOF
14010 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
14011   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14012   ac_status=$?
14013   grep -v '^ *+' conftest.er1 >conftest.err
14014   rm -f conftest.er1
14015   cat conftest.err >&5
14016   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14017   (exit $ac_status); } >/dev/null; then
14018   if test -s conftest.err; then
14019     ac_cpp_err=$ac_c_preproc_warn_flag
14020     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
14021   else
14022     ac_cpp_err=
14023   fi
14024 else
14025   ac_cpp_err=yes
14026 fi
14027 if test -z "$ac_cpp_err"; then
14028   ac_header_preproc=yes
14029 else
14030   echo "$as_me: failed program was:" >&5
14031 sed 's/^/| /' conftest.$ac_ext >&5
14032
14033   ac_header_preproc=no
14034 fi
14035 rm -f conftest.err conftest.$ac_ext
14036 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14037 echo "${ECHO_T}$ac_header_preproc" >&6
14038
14039 # So?  What about this header?
14040 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14041   yes:no: )
14042     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14043 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14044     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14045 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14046     ac_header_preproc=yes
14047     ;;
14048   no:yes:* )
14049     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14050 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14051     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14052 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14053     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14054 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14055     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14056 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14057     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14058 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14059     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14060 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14061     (
14062       cat <<\_ASBOX
14063 ## --------------------------------------------- ##
14064 ## Report this to <http://www.openldap.org/its/> ##
14065 ## --------------------------------------------- ##
14066 _ASBOX
14067     ) |
14068       sed "s/^/$as_me: WARNING:     /" >&2
14069     ;;
14070 esac
14071 echo "$as_me:$LINENO: checking for $ac_header" >&5
14072 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14073 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14074   echo $ECHO_N "(cached) $ECHO_C" >&6
14075 else
14076   eval "$as_ac_Header=\$ac_header_preproc"
14077 fi
14078 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14079 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14080
14081 fi
14082 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14083   cat >>confdefs.h <<_ACEOF
14084 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14085 _ACEOF
14086
14087 fi
14088
14089 done
14090
14091
14092
14093 for ac_header in resolv.h
14094 do
14095 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14096 echo "$as_me:$LINENO: checking for $ac_header" >&5
14097 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14098 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14099   echo $ECHO_N "(cached) $ECHO_C" >&6
14100 else
14101   cat >conftest.$ac_ext <<_ACEOF
14102 /* confdefs.h.  */
14103 _ACEOF
14104 cat confdefs.h >>conftest.$ac_ext
14105 cat >>conftest.$ac_ext <<_ACEOF
14106 /* end confdefs.h.  */
14107 $ac_includes_default
14108 #include <netinet/in.h>
14109
14110
14111 #include <$ac_header>
14112 _ACEOF
14113 rm -f conftest.$ac_objext
14114 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14115   (eval $ac_compile) 2>conftest.er1
14116   ac_status=$?
14117   grep -v '^ *+' conftest.er1 >conftest.err
14118   rm -f conftest.er1
14119   cat conftest.err >&5
14120   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14121   (exit $ac_status); } &&
14122          { ac_try='test -z "$ac_c_werror_flag"
14123                          || test ! -s conftest.err'
14124   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14125   (eval $ac_try) 2>&5
14126   ac_status=$?
14127   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14128   (exit $ac_status); }; } &&
14129          { ac_try='test -s conftest.$ac_objext'
14130   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14131   (eval $ac_try) 2>&5
14132   ac_status=$?
14133   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14134   (exit $ac_status); }; }; then
14135   eval "$as_ac_Header=yes"
14136 else
14137   echo "$as_me: failed program was:" >&5
14138 sed 's/^/| /' conftest.$ac_ext >&5
14139
14140 eval "$as_ac_Header=no"
14141 fi
14142 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14143 fi
14144 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14145 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14146 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14147   cat >>confdefs.h <<_ACEOF
14148 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14149 _ACEOF
14150
14151 fi
14152
14153 done
14154
14155
14156
14157 for ac_header in netinet/tcp.h
14158 do
14159 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14160 echo "$as_me:$LINENO: checking for $ac_header" >&5
14161 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14162 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14163   echo $ECHO_N "(cached) $ECHO_C" >&6
14164 else
14165   cat >conftest.$ac_ext <<_ACEOF
14166 /* confdefs.h.  */
14167 _ACEOF
14168 cat confdefs.h >>conftest.$ac_ext
14169 cat >>conftest.$ac_ext <<_ACEOF
14170 /* end confdefs.h.  */
14171 $ac_includes_default
14172 #include <netinet/in.h>
14173
14174
14175 #include <$ac_header>
14176 _ACEOF
14177 rm -f conftest.$ac_objext
14178 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14179   (eval $ac_compile) 2>conftest.er1
14180   ac_status=$?
14181   grep -v '^ *+' conftest.er1 >conftest.err
14182   rm -f conftest.er1
14183   cat conftest.err >&5
14184   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14185   (exit $ac_status); } &&
14186          { ac_try='test -z "$ac_c_werror_flag"
14187                          || test ! -s conftest.err'
14188   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14189   (eval $ac_try) 2>&5
14190   ac_status=$?
14191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14192   (exit $ac_status); }; } &&
14193          { ac_try='test -s conftest.$ac_objext'
14194   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14195   (eval $ac_try) 2>&5
14196   ac_status=$?
14197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14198   (exit $ac_status); }; }; then
14199   eval "$as_ac_Header=yes"
14200 else
14201   echo "$as_me: failed program was:" >&5
14202 sed 's/^/| /' conftest.$ac_ext >&5
14203
14204 eval "$as_ac_Header=no"
14205 fi
14206 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14207 fi
14208 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14209 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14210 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14211   cat >>confdefs.h <<_ACEOF
14212 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14213 _ACEOF
14214
14215 fi
14216
14217 done
14218
14219
14220
14221 for ac_header in sys/ucred.h
14222 do
14223 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14224 echo "$as_me:$LINENO: checking for $ac_header" >&5
14225 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14226 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14227   echo $ECHO_N "(cached) $ECHO_C" >&6
14228 else
14229   cat >conftest.$ac_ext <<_ACEOF
14230 /* confdefs.h.  */
14231 _ACEOF
14232 cat confdefs.h >>conftest.$ac_ext
14233 cat >>conftest.$ac_ext <<_ACEOF
14234 /* end confdefs.h.  */
14235 $ac_includes_default
14236 #ifdef HAVE_SYS_PARAM_H
14237 #include <sys/param.h>
14238 #endif
14239
14240
14241 #include <$ac_header>
14242 _ACEOF
14243 rm -f conftest.$ac_objext
14244 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14245   (eval $ac_compile) 2>conftest.er1
14246   ac_status=$?
14247   grep -v '^ *+' conftest.er1 >conftest.err
14248   rm -f conftest.er1
14249   cat conftest.err >&5
14250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14251   (exit $ac_status); } &&
14252          { ac_try='test -z "$ac_c_werror_flag"
14253                          || test ! -s conftest.err'
14254   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14255   (eval $ac_try) 2>&5
14256   ac_status=$?
14257   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14258   (exit $ac_status); }; } &&
14259          { ac_try='test -s conftest.$ac_objext'
14260   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14261   (eval $ac_try) 2>&5
14262   ac_status=$?
14263   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14264   (exit $ac_status); }; }; then
14265   eval "$as_ac_Header=yes"
14266 else
14267   echo "$as_me: failed program was:" >&5
14268 sed 's/^/| /' conftest.$ac_ext >&5
14269
14270 eval "$as_ac_Header=no"
14271 fi
14272 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14273 fi
14274 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14275 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14276 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14277   cat >>confdefs.h <<_ACEOF
14278 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14279 _ACEOF
14280
14281 fi
14282
14283 done
14284
14285
14286
14287
14288
14289 for ac_func in sigaction sigset
14290 do
14291 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14292 echo "$as_me:$LINENO: checking for $ac_func" >&5
14293 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14294 if eval "test \"\${$as_ac_var+set}\" = set"; then
14295   echo $ECHO_N "(cached) $ECHO_C" >&6
14296 else
14297   cat >conftest.$ac_ext <<_ACEOF
14298 /* confdefs.h.  */
14299 _ACEOF
14300 cat confdefs.h >>conftest.$ac_ext
14301 cat >>conftest.$ac_ext <<_ACEOF
14302 /* end confdefs.h.  */
14303 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14304    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14305 #define $ac_func innocuous_$ac_func
14306
14307 /* System header to define __stub macros and hopefully few prototypes,
14308     which can conflict with char $ac_func (); below.
14309     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14310     <limits.h> exists even on freestanding compilers.  */
14311
14312 #ifdef __STDC__
14313 # include <limits.h>
14314 #else
14315 # include <assert.h>
14316 #endif
14317
14318 #undef $ac_func
14319
14320 /* Override any gcc2 internal prototype to avoid an error.  */
14321 #ifdef __cplusplus
14322 extern "C"
14323 {
14324 #endif
14325 /* We use char because int might match the return type of a gcc2
14326    builtin and then its argument prototype would still apply.  */
14327 char $ac_func ();
14328 /* The GNU C library defines this for functions which it implements
14329     to always fail with ENOSYS.  Some functions are actually named
14330     something starting with __ and the normal name is an alias.  */
14331 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14332 choke me
14333 #else
14334 char (*f) () = $ac_func;
14335 #endif
14336 #ifdef __cplusplus
14337 }
14338 #endif
14339
14340 int
14341 main ()
14342 {
14343 return f != $ac_func;
14344   ;
14345   return 0;
14346 }
14347 _ACEOF
14348 rm -f conftest.$ac_objext conftest$ac_exeext
14349 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14350   (eval $ac_link) 2>conftest.er1
14351   ac_status=$?
14352   grep -v '^ *+' conftest.er1 >conftest.err
14353   rm -f conftest.er1
14354   cat conftest.err >&5
14355   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14356   (exit $ac_status); } &&
14357          { ac_try='test -z "$ac_c_werror_flag"
14358                          || test ! -s conftest.err'
14359   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14360   (eval $ac_try) 2>&5
14361   ac_status=$?
14362   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14363   (exit $ac_status); }; } &&
14364          { ac_try='test -s conftest$ac_exeext'
14365   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14366   (eval $ac_try) 2>&5
14367   ac_status=$?
14368   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14369   (exit $ac_status); }; }; then
14370   eval "$as_ac_var=yes"
14371 else
14372   echo "$as_me: failed program was:" >&5
14373 sed 's/^/| /' conftest.$ac_ext >&5
14374
14375 eval "$as_ac_var=no"
14376 fi
14377 rm -f conftest.err conftest.$ac_objext \
14378       conftest$ac_exeext conftest.$ac_ext
14379 fi
14380 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14381 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14382 if test `eval echo '${'$as_ac_var'}'` = yes; then
14383   cat >>confdefs.h <<_ACEOF
14384 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14385 _ACEOF
14386
14387 fi
14388 done
14389
14390
14391 if test $ac_cv_func_sigaction = no && test $ac_cv_func_sigaction = no ; then
14392
14393 echo "$as_me:$LINENO: checking for sigset in -lV3" >&5
14394 echo $ECHO_N "checking for sigset in -lV3... $ECHO_C" >&6
14395 if test "${ac_cv_lib_V3_sigset+set}" = set; then
14396   echo $ECHO_N "(cached) $ECHO_C" >&6
14397 else
14398   ac_check_lib_save_LIBS=$LIBS
14399 LIBS="-lV3  $LIBS"
14400 cat >conftest.$ac_ext <<_ACEOF
14401 /* confdefs.h.  */
14402 _ACEOF
14403 cat confdefs.h >>conftest.$ac_ext
14404 cat >>conftest.$ac_ext <<_ACEOF
14405 /* end confdefs.h.  */
14406
14407 /* Override any gcc2 internal prototype to avoid an error.  */
14408 #ifdef __cplusplus
14409 extern "C"
14410 #endif
14411 /* We use char because int might match the return type of a gcc2
14412    builtin and then its argument prototype would still apply.  */
14413 char sigset ();
14414 int
14415 main ()
14416 {
14417 sigset ();
14418   ;
14419   return 0;
14420 }
14421 _ACEOF
14422 rm -f conftest.$ac_objext conftest$ac_exeext
14423 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14424   (eval $ac_link) 2>conftest.er1
14425   ac_status=$?
14426   grep -v '^ *+' conftest.er1 >conftest.err
14427   rm -f conftest.er1
14428   cat conftest.err >&5
14429   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14430   (exit $ac_status); } &&
14431          { ac_try='test -z "$ac_c_werror_flag"
14432                          || test ! -s conftest.err'
14433   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14434   (eval $ac_try) 2>&5
14435   ac_status=$?
14436   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14437   (exit $ac_status); }; } &&
14438          { ac_try='test -s conftest$ac_exeext'
14439   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14440   (eval $ac_try) 2>&5
14441   ac_status=$?
14442   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14443   (exit $ac_status); }; }; then
14444   ac_cv_lib_V3_sigset=yes
14445 else
14446   echo "$as_me: failed program was:" >&5
14447 sed 's/^/| /' conftest.$ac_ext >&5
14448
14449 ac_cv_lib_V3_sigset=no
14450 fi
14451 rm -f conftest.err conftest.$ac_objext \
14452       conftest$ac_exeext conftest.$ac_ext
14453 LIBS=$ac_check_lib_save_LIBS
14454 fi
14455 echo "$as_me:$LINENO: result: $ac_cv_lib_V3_sigset" >&5
14456 echo "${ECHO_T}$ac_cv_lib_V3_sigset" >&6
14457 if test $ac_cv_lib_V3_sigset = yes; then
14458   cat >>confdefs.h <<_ACEOF
14459 #define HAVE_LIBV3 1
14460 _ACEOF
14461
14462   LIBS="-lV3 $LIBS"
14463
14464 fi
14465
14466 fi
14467
14468 if test "$ac_cv_cygwin" != yes && test "$ac_cv_header_winsock_h" = yes; then
14469 echo "$as_me:$LINENO: checking for winsock" >&5
14470 echo $ECHO_N "checking for winsock... $ECHO_C" >&6
14471 if test "${ol_cv_winsock+set}" = set; then
14472   echo $ECHO_N "(cached) $ECHO_C" >&6
14473 else
14474   save_LIBS="$LIBS"
14475 for curlib in ws2_32 wsock32; do
14476         LIBS="$LIBS -l$curlib"
14477         cat >conftest.$ac_ext <<_ACEOF
14478 /* confdefs.h.  */
14479 _ACEOF
14480 cat confdefs.h >>conftest.$ac_ext
14481 cat >>conftest.$ac_ext <<_ACEOF
14482 /* end confdefs.h.  */
14483 #include <winsock.h>
14484
14485 int
14486 main ()
14487 {
14488
14489                         socket(0,0,0);
14490                         select(0,NULL,NULL,NULL,NULL);
14491                         closesocket(0);
14492                         gethostname(NULL,0);
14493
14494   ;
14495   return 0;
14496 }
14497 _ACEOF
14498 rm -f conftest.$ac_objext conftest$ac_exeext
14499 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14500   (eval $ac_link) 2>conftest.er1
14501   ac_status=$?
14502   grep -v '^ *+' conftest.er1 >conftest.err
14503   rm -f conftest.er1
14504   cat conftest.err >&5
14505   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14506   (exit $ac_status); } &&
14507          { ac_try='test -z "$ac_c_werror_flag"
14508                          || test ! -s conftest.err'
14509   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14510   (eval $ac_try) 2>&5
14511   ac_status=$?
14512   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14513   (exit $ac_status); }; } &&
14514          { ac_try='test -s conftest$ac_exeext'
14515   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14516   (eval $ac_try) 2>&5
14517   ac_status=$?
14518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14519   (exit $ac_status); }; }; then
14520   ol_cv_winsock=yes
14521 else
14522   echo "$as_me: failed program was:" >&5
14523 sed 's/^/| /' conftest.$ac_ext >&5
14524
14525 ol_cv_winsock=no
14526 fi
14527 rm -f conftest.err conftest.$ac_objext \
14528       conftest$ac_exeext conftest.$ac_ext
14529
14530         if test $ol_cv_winsock = yes; then
14531
14532 cat >>confdefs.h <<\_ACEOF
14533 #define HAVE_WINSOCK 1
14534 _ACEOF
14535
14536                 ac_cv_func_socket=yes
14537                 ac_cv_func_select=yes
14538                 ac_cv_func_closesocket=yes
14539                 ac_cv_func_gethostname=yes
14540                 if test $curlib = ws2_32; then
14541                         ol_cv_winsock=winsock2
14542
14543 cat >>confdefs.h <<\_ACEOF
14544 #define HAVE_WINSOCK2 1
14545 _ACEOF
14546
14547                 fi
14548                 break
14549         fi
14550         LIBS="$save_LIBS"
14551 done
14552 fi
14553 echo "$as_me:$LINENO: result: $ol_cv_winsock" >&5
14554 echo "${ECHO_T}$ol_cv_winsock" >&6
14555 fi
14556
14557
14558 echo "$as_me:$LINENO: checking for socket" >&5
14559 echo $ECHO_N "checking for socket... $ECHO_C" >&6
14560 if test "${ac_cv_func_socket+set}" = set; then
14561   echo $ECHO_N "(cached) $ECHO_C" >&6
14562 else
14563   cat >conftest.$ac_ext <<_ACEOF
14564 /* confdefs.h.  */
14565 _ACEOF
14566 cat confdefs.h >>conftest.$ac_ext
14567 cat >>conftest.$ac_ext <<_ACEOF
14568 /* end confdefs.h.  */
14569 /* Define socket to an innocuous variant, in case <limits.h> declares socket.
14570    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14571 #define socket innocuous_socket
14572
14573 /* System header to define __stub macros and hopefully few prototypes,
14574     which can conflict with char socket (); below.
14575     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14576     <limits.h> exists even on freestanding compilers.  */
14577
14578 #ifdef __STDC__
14579 # include <limits.h>
14580 #else
14581 # include <assert.h>
14582 #endif
14583
14584 #undef socket
14585
14586 /* Override any gcc2 internal prototype to avoid an error.  */
14587 #ifdef __cplusplus
14588 extern "C"
14589 {
14590 #endif
14591 /* We use char because int might match the return type of a gcc2
14592    builtin and then its argument prototype would still apply.  */
14593 char socket ();
14594 /* The GNU C library defines this for functions which it implements
14595     to always fail with ENOSYS.  Some functions are actually named
14596     something starting with __ and the normal name is an alias.  */
14597 #if defined (__stub_socket) || defined (__stub___socket)
14598 choke me
14599 #else
14600 char (*f) () = socket;
14601 #endif
14602 #ifdef __cplusplus
14603 }
14604 #endif
14605
14606 int
14607 main ()
14608 {
14609 return f != socket;
14610   ;
14611   return 0;
14612 }
14613 _ACEOF
14614 rm -f conftest.$ac_objext conftest$ac_exeext
14615 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14616   (eval $ac_link) 2>conftest.er1
14617   ac_status=$?
14618   grep -v '^ *+' conftest.er1 >conftest.err
14619   rm -f conftest.er1
14620   cat conftest.err >&5
14621   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14622   (exit $ac_status); } &&
14623          { ac_try='test -z "$ac_c_werror_flag"
14624                          || test ! -s conftest.err'
14625   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14626   (eval $ac_try) 2>&5
14627   ac_status=$?
14628   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14629   (exit $ac_status); }; } &&
14630          { ac_try='test -s conftest$ac_exeext'
14631   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14632   (eval $ac_try) 2>&5
14633   ac_status=$?
14634   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14635   (exit $ac_status); }; }; then
14636   ac_cv_func_socket=yes
14637 else
14638   echo "$as_me: failed program was:" >&5
14639 sed 's/^/| /' conftest.$ac_ext >&5
14640
14641 ac_cv_func_socket=no
14642 fi
14643 rm -f conftest.err conftest.$ac_objext \
14644       conftest$ac_exeext conftest.$ac_ext
14645 fi
14646 echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
14647 echo "${ECHO_T}$ac_cv_func_socket" >&6
14648 if test $ac_cv_func_socket = yes; then
14649   :
14650 else
14651
14652
14653 echo "$as_me:$LINENO: checking for main in -lsocket" >&5
14654 echo $ECHO_N "checking for main in -lsocket... $ECHO_C" >&6
14655 if test "${ac_cv_lib_socket_main+set}" = set; then
14656   echo $ECHO_N "(cached) $ECHO_C" >&6
14657 else
14658   ac_check_lib_save_LIBS=$LIBS
14659 LIBS="-lsocket  $LIBS"
14660 cat >conftest.$ac_ext <<_ACEOF
14661 /* confdefs.h.  */
14662 _ACEOF
14663 cat confdefs.h >>conftest.$ac_ext
14664 cat >>conftest.$ac_ext <<_ACEOF
14665 /* end confdefs.h.  */
14666
14667
14668 int
14669 main ()
14670 {
14671 main ();
14672   ;
14673   return 0;
14674 }
14675 _ACEOF
14676 rm -f conftest.$ac_objext conftest$ac_exeext
14677 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14678   (eval $ac_link) 2>conftest.er1
14679   ac_status=$?
14680   grep -v '^ *+' conftest.er1 >conftest.err
14681   rm -f conftest.er1
14682   cat conftest.err >&5
14683   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14684   (exit $ac_status); } &&
14685          { ac_try='test -z "$ac_c_werror_flag"
14686                          || test ! -s conftest.err'
14687   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14688   (eval $ac_try) 2>&5
14689   ac_status=$?
14690   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14691   (exit $ac_status); }; } &&
14692          { ac_try='test -s conftest$ac_exeext'
14693   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14694   (eval $ac_try) 2>&5
14695   ac_status=$?
14696   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14697   (exit $ac_status); }; }; then
14698   ac_cv_lib_socket_main=yes
14699 else
14700   echo "$as_me: failed program was:" >&5
14701 sed 's/^/| /' conftest.$ac_ext >&5
14702
14703 ac_cv_lib_socket_main=no
14704 fi
14705 rm -f conftest.err conftest.$ac_objext \
14706       conftest$ac_exeext conftest.$ac_ext
14707 LIBS=$ac_check_lib_save_LIBS
14708 fi
14709 echo "$as_me:$LINENO: result: $ac_cv_lib_socket_main" >&5
14710 echo "${ECHO_T}$ac_cv_lib_socket_main" >&6
14711 if test $ac_cv_lib_socket_main = yes; then
14712   cat >>confdefs.h <<_ACEOF
14713 #define HAVE_LIBSOCKET 1
14714 _ACEOF
14715
14716   LIBS="-lsocket $LIBS"
14717
14718 fi
14719
14720
14721 echo "$as_me:$LINENO: checking for main in -lnet" >&5
14722 echo $ECHO_N "checking for main in -lnet... $ECHO_C" >&6
14723 if test "${ac_cv_lib_net_main+set}" = set; then
14724   echo $ECHO_N "(cached) $ECHO_C" >&6
14725 else
14726   ac_check_lib_save_LIBS=$LIBS
14727 LIBS="-lnet  $LIBS"
14728 cat >conftest.$ac_ext <<_ACEOF
14729 /* confdefs.h.  */
14730 _ACEOF
14731 cat confdefs.h >>conftest.$ac_ext
14732 cat >>conftest.$ac_ext <<_ACEOF
14733 /* end confdefs.h.  */
14734
14735
14736 int
14737 main ()
14738 {
14739 main ();
14740   ;
14741   return 0;
14742 }
14743 _ACEOF
14744 rm -f conftest.$ac_objext conftest$ac_exeext
14745 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14746   (eval $ac_link) 2>conftest.er1
14747   ac_status=$?
14748   grep -v '^ *+' conftest.er1 >conftest.err
14749   rm -f conftest.er1
14750   cat conftest.err >&5
14751   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14752   (exit $ac_status); } &&
14753          { ac_try='test -z "$ac_c_werror_flag"
14754                          || test ! -s conftest.err'
14755   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14756   (eval $ac_try) 2>&5
14757   ac_status=$?
14758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14759   (exit $ac_status); }; } &&
14760          { ac_try='test -s conftest$ac_exeext'
14761   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14762   (eval $ac_try) 2>&5
14763   ac_status=$?
14764   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14765   (exit $ac_status); }; }; then
14766   ac_cv_lib_net_main=yes
14767 else
14768   echo "$as_me: failed program was:" >&5
14769 sed 's/^/| /' conftest.$ac_ext >&5
14770
14771 ac_cv_lib_net_main=no
14772 fi
14773 rm -f conftest.err conftest.$ac_objext \
14774       conftest$ac_exeext conftest.$ac_ext
14775 LIBS=$ac_check_lib_save_LIBS
14776 fi
14777 echo "$as_me:$LINENO: result: $ac_cv_lib_net_main" >&5
14778 echo "${ECHO_T}$ac_cv_lib_net_main" >&6
14779 if test $ac_cv_lib_net_main = yes; then
14780   cat >>confdefs.h <<_ACEOF
14781 #define HAVE_LIBNET 1
14782 _ACEOF
14783
14784   LIBS="-lnet $LIBS"
14785
14786 fi
14787
14788
14789 echo "$as_me:$LINENO: checking for main in -lnsl_s" >&5
14790 echo $ECHO_N "checking for main in -lnsl_s... $ECHO_C" >&6
14791 if test "${ac_cv_lib_nsl_s_main+set}" = set; then
14792   echo $ECHO_N "(cached) $ECHO_C" >&6
14793 else
14794   ac_check_lib_save_LIBS=$LIBS
14795 LIBS="-lnsl_s  $LIBS"
14796 cat >conftest.$ac_ext <<_ACEOF
14797 /* confdefs.h.  */
14798 _ACEOF
14799 cat confdefs.h >>conftest.$ac_ext
14800 cat >>conftest.$ac_ext <<_ACEOF
14801 /* end confdefs.h.  */
14802
14803
14804 int
14805 main ()
14806 {
14807 main ();
14808   ;
14809   return 0;
14810 }
14811 _ACEOF
14812 rm -f conftest.$ac_objext conftest$ac_exeext
14813 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14814   (eval $ac_link) 2>conftest.er1
14815   ac_status=$?
14816   grep -v '^ *+' conftest.er1 >conftest.err
14817   rm -f conftest.er1
14818   cat conftest.err >&5
14819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14820   (exit $ac_status); } &&
14821          { ac_try='test -z "$ac_c_werror_flag"
14822                          || test ! -s conftest.err'
14823   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14824   (eval $ac_try) 2>&5
14825   ac_status=$?
14826   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14827   (exit $ac_status); }; } &&
14828          { ac_try='test -s conftest$ac_exeext'
14829   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14830   (eval $ac_try) 2>&5
14831   ac_status=$?
14832   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14833   (exit $ac_status); }; }; then
14834   ac_cv_lib_nsl_s_main=yes
14835 else
14836   echo "$as_me: failed program was:" >&5
14837 sed 's/^/| /' conftest.$ac_ext >&5
14838
14839 ac_cv_lib_nsl_s_main=no
14840 fi
14841 rm -f conftest.err conftest.$ac_objext \
14842       conftest$ac_exeext conftest.$ac_ext
14843 LIBS=$ac_check_lib_save_LIBS
14844 fi
14845 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_s_main" >&5
14846 echo "${ECHO_T}$ac_cv_lib_nsl_s_main" >&6
14847 if test $ac_cv_lib_nsl_s_main = yes; then
14848   cat >>confdefs.h <<_ACEOF
14849 #define HAVE_LIBNSL_S 1
14850 _ACEOF
14851
14852   LIBS="-lnsl_s $LIBS"
14853
14854 fi
14855
14856
14857 echo "$as_me:$LINENO: checking for main in -lnsl" >&5
14858 echo $ECHO_N "checking for main in -lnsl... $ECHO_C" >&6
14859 if test "${ac_cv_lib_nsl_main+set}" = set; then
14860   echo $ECHO_N "(cached) $ECHO_C" >&6
14861 else
14862   ac_check_lib_save_LIBS=$LIBS
14863 LIBS="-lnsl  $LIBS"
14864 cat >conftest.$ac_ext <<_ACEOF
14865 /* confdefs.h.  */
14866 _ACEOF
14867 cat confdefs.h >>conftest.$ac_ext
14868 cat >>conftest.$ac_ext <<_ACEOF
14869 /* end confdefs.h.  */
14870
14871
14872 int
14873 main ()
14874 {
14875 main ();
14876   ;
14877   return 0;
14878 }
14879 _ACEOF
14880 rm -f conftest.$ac_objext conftest$ac_exeext
14881 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14882   (eval $ac_link) 2>conftest.er1
14883   ac_status=$?
14884   grep -v '^ *+' conftest.er1 >conftest.err
14885   rm -f conftest.er1
14886   cat conftest.err >&5
14887   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14888   (exit $ac_status); } &&
14889          { ac_try='test -z "$ac_c_werror_flag"
14890                          || test ! -s conftest.err'
14891   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14892   (eval $ac_try) 2>&5
14893   ac_status=$?
14894   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14895   (exit $ac_status); }; } &&
14896          { ac_try='test -s conftest$ac_exeext'
14897   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14898   (eval $ac_try) 2>&5
14899   ac_status=$?
14900   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14901   (exit $ac_status); }; }; then
14902   ac_cv_lib_nsl_main=yes
14903 else
14904   echo "$as_me: failed program was:" >&5
14905 sed 's/^/| /' conftest.$ac_ext >&5
14906
14907 ac_cv_lib_nsl_main=no
14908 fi
14909 rm -f conftest.err conftest.$ac_objext \
14910       conftest$ac_exeext conftest.$ac_ext
14911 LIBS=$ac_check_lib_save_LIBS
14912 fi
14913 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_main" >&5
14914 echo "${ECHO_T}$ac_cv_lib_nsl_main" >&6
14915 if test $ac_cv_lib_nsl_main = yes; then
14916   cat >>confdefs.h <<_ACEOF
14917 #define HAVE_LIBNSL 1
14918 _ACEOF
14919
14920   LIBS="-lnsl $LIBS"
14921
14922 fi
14923
14924
14925 echo "$as_me:$LINENO: checking for socket in -linet" >&5
14926 echo $ECHO_N "checking for socket in -linet... $ECHO_C" >&6
14927 if test "${ac_cv_lib_inet_socket+set}" = set; then
14928   echo $ECHO_N "(cached) $ECHO_C" >&6
14929 else
14930   ac_check_lib_save_LIBS=$LIBS
14931 LIBS="-linet  $LIBS"
14932 cat >conftest.$ac_ext <<_ACEOF
14933 /* confdefs.h.  */
14934 _ACEOF
14935 cat confdefs.h >>conftest.$ac_ext
14936 cat >>conftest.$ac_ext <<_ACEOF
14937 /* end confdefs.h.  */
14938
14939 /* Override any gcc2 internal prototype to avoid an error.  */
14940 #ifdef __cplusplus
14941 extern "C"
14942 #endif
14943 /* We use char because int might match the return type of a gcc2
14944    builtin and then its argument prototype would still apply.  */
14945 char socket ();
14946 int
14947 main ()
14948 {
14949 socket ();
14950   ;
14951   return 0;
14952 }
14953 _ACEOF
14954 rm -f conftest.$ac_objext conftest$ac_exeext
14955 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14956   (eval $ac_link) 2>conftest.er1
14957   ac_status=$?
14958   grep -v '^ *+' conftest.er1 >conftest.err
14959   rm -f conftest.er1
14960   cat conftest.err >&5
14961   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14962   (exit $ac_status); } &&
14963          { ac_try='test -z "$ac_c_werror_flag"
14964                          || test ! -s conftest.err'
14965   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14966   (eval $ac_try) 2>&5
14967   ac_status=$?
14968   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14969   (exit $ac_status); }; } &&
14970          { ac_try='test -s conftest$ac_exeext'
14971   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14972   (eval $ac_try) 2>&5
14973   ac_status=$?
14974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14975   (exit $ac_status); }; }; then
14976   ac_cv_lib_inet_socket=yes
14977 else
14978   echo "$as_me: failed program was:" >&5
14979 sed 's/^/| /' conftest.$ac_ext >&5
14980
14981 ac_cv_lib_inet_socket=no
14982 fi
14983 rm -f conftest.err conftest.$ac_objext \
14984       conftest$ac_exeext conftest.$ac_ext
14985 LIBS=$ac_check_lib_save_LIBS
14986 fi
14987 echo "$as_me:$LINENO: result: $ac_cv_lib_inet_socket" >&5
14988 echo "${ECHO_T}$ac_cv_lib_inet_socket" >&6
14989 if test $ac_cv_lib_inet_socket = yes; then
14990   cat >>confdefs.h <<_ACEOF
14991 #define HAVE_LIBINET 1
14992 _ACEOF
14993
14994   LIBS="-linet $LIBS"
14995
14996 fi
14997
14998
14999 echo "$as_me:$LINENO: checking for main in -lgen" >&5
15000 echo $ECHO_N "checking for main in -lgen... $ECHO_C" >&6
15001 if test "${ac_cv_lib_gen_main+set}" = set; then
15002   echo $ECHO_N "(cached) $ECHO_C" >&6
15003 else
15004   ac_check_lib_save_LIBS=$LIBS
15005 LIBS="-lgen  $LIBS"
15006 cat >conftest.$ac_ext <<_ACEOF
15007 /* confdefs.h.  */
15008 _ACEOF
15009 cat confdefs.h >>conftest.$ac_ext
15010 cat >>conftest.$ac_ext <<_ACEOF
15011 /* end confdefs.h.  */
15012
15013
15014 int
15015 main ()
15016 {
15017 main ();
15018   ;
15019   return 0;
15020 }
15021 _ACEOF
15022 rm -f conftest.$ac_objext conftest$ac_exeext
15023 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15024   (eval $ac_link) 2>conftest.er1
15025   ac_status=$?
15026   grep -v '^ *+' conftest.er1 >conftest.err
15027   rm -f conftest.er1
15028   cat conftest.err >&5
15029   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15030   (exit $ac_status); } &&
15031          { ac_try='test -z "$ac_c_werror_flag"
15032                          || test ! -s conftest.err'
15033   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15034   (eval $ac_try) 2>&5
15035   ac_status=$?
15036   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15037   (exit $ac_status); }; } &&
15038          { ac_try='test -s conftest$ac_exeext'
15039   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15040   (eval $ac_try) 2>&5
15041   ac_status=$?
15042   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15043   (exit $ac_status); }; }; then
15044   ac_cv_lib_gen_main=yes
15045 else
15046   echo "$as_me: failed program was:" >&5
15047 sed 's/^/| /' conftest.$ac_ext >&5
15048
15049 ac_cv_lib_gen_main=no
15050 fi
15051 rm -f conftest.err conftest.$ac_objext \
15052       conftest$ac_exeext conftest.$ac_ext
15053 LIBS=$ac_check_lib_save_LIBS
15054 fi
15055 echo "$as_me:$LINENO: result: $ac_cv_lib_gen_main" >&5
15056 echo "${ECHO_T}$ac_cv_lib_gen_main" >&6
15057 if test $ac_cv_lib_gen_main = yes; then
15058   cat >>confdefs.h <<_ACEOF
15059 #define HAVE_LIBGEN 1
15060 _ACEOF
15061
15062   LIBS="-lgen $LIBS"
15063
15064 fi
15065
15066
15067 fi
15068
15069
15070 echo "$as_me:$LINENO: checking for select" >&5
15071 echo $ECHO_N "checking for select... $ECHO_C" >&6
15072 if test "${ac_cv_func_select+set}" = set; then
15073   echo $ECHO_N "(cached) $ECHO_C" >&6
15074 else
15075   cat >conftest.$ac_ext <<_ACEOF
15076 /* confdefs.h.  */
15077 _ACEOF
15078 cat confdefs.h >>conftest.$ac_ext
15079 cat >>conftest.$ac_ext <<_ACEOF
15080 /* end confdefs.h.  */
15081 /* Define select to an innocuous variant, in case <limits.h> declares select.
15082    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15083 #define select innocuous_select
15084
15085 /* System header to define __stub macros and hopefully few prototypes,
15086     which can conflict with char select (); below.
15087     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15088     <limits.h> exists even on freestanding compilers.  */
15089
15090 #ifdef __STDC__
15091 # include <limits.h>
15092 #else
15093 # include <assert.h>
15094 #endif
15095
15096 #undef select
15097
15098 /* Override any gcc2 internal prototype to avoid an error.  */
15099 #ifdef __cplusplus
15100 extern "C"
15101 {
15102 #endif
15103 /* We use char because int might match the return type of a gcc2
15104    builtin and then its argument prototype would still apply.  */
15105 char select ();
15106 /* The GNU C library defines this for functions which it implements
15107     to always fail with ENOSYS.  Some functions are actually named
15108     something starting with __ and the normal name is an alias.  */
15109 #if defined (__stub_select) || defined (__stub___select)
15110 choke me
15111 #else
15112 char (*f) () = select;
15113 #endif
15114 #ifdef __cplusplus
15115 }
15116 #endif
15117
15118 int
15119 main ()
15120 {
15121 return f != select;
15122   ;
15123   return 0;
15124 }
15125 _ACEOF
15126 rm -f conftest.$ac_objext conftest$ac_exeext
15127 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15128   (eval $ac_link) 2>conftest.er1
15129   ac_status=$?
15130   grep -v '^ *+' conftest.er1 >conftest.err
15131   rm -f conftest.er1
15132   cat conftest.err >&5
15133   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15134   (exit $ac_status); } &&
15135          { ac_try='test -z "$ac_c_werror_flag"
15136                          || test ! -s conftest.err'
15137   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15138   (eval $ac_try) 2>&5
15139   ac_status=$?
15140   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15141   (exit $ac_status); }; } &&
15142          { ac_try='test -s conftest$ac_exeext'
15143   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15144   (eval $ac_try) 2>&5
15145   ac_status=$?
15146   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15147   (exit $ac_status); }; }; then
15148   ac_cv_func_select=yes
15149 else
15150   echo "$as_me: failed program was:" >&5
15151 sed 's/^/| /' conftest.$ac_ext >&5
15152
15153 ac_cv_func_select=no
15154 fi
15155 rm -f conftest.err conftest.$ac_objext \
15156       conftest$ac_exeext conftest.$ac_ext
15157 fi
15158 echo "$as_me:$LINENO: result: $ac_cv_func_select" >&5
15159 echo "${ECHO_T}$ac_cv_func_select" >&6
15160 if test $ac_cv_func_select = yes; then
15161   :
15162 else
15163   { { echo "$as_me:$LINENO: error: select() required." >&5
15164 echo "$as_me: error: select() required." >&2;}
15165    { (exit 1); exit 1; }; }
15166 fi
15167
15168
15169 if test "${ac_cv_header_winsock_h}" != yes; then
15170
15171
15172 for ac_header in sys/select.h sys/socket.h
15173 do
15174 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15175 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15176   echo "$as_me:$LINENO: checking for $ac_header" >&5
15177 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15178 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15179   echo $ECHO_N "(cached) $ECHO_C" >&6
15180 fi
15181 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15182 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15183 else
15184   # Is the header compilable?
15185 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15186 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15187 cat >conftest.$ac_ext <<_ACEOF
15188 /* confdefs.h.  */
15189 _ACEOF
15190 cat confdefs.h >>conftest.$ac_ext
15191 cat >>conftest.$ac_ext <<_ACEOF
15192 /* end confdefs.h.  */
15193 $ac_includes_default
15194 #include <$ac_header>
15195 _ACEOF
15196 rm -f conftest.$ac_objext
15197 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15198   (eval $ac_compile) 2>conftest.er1
15199   ac_status=$?
15200   grep -v '^ *+' conftest.er1 >conftest.err
15201   rm -f conftest.er1
15202   cat conftest.err >&5
15203   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15204   (exit $ac_status); } &&
15205          { ac_try='test -z "$ac_c_werror_flag"
15206                          || test ! -s conftest.err'
15207   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15208   (eval $ac_try) 2>&5
15209   ac_status=$?
15210   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15211   (exit $ac_status); }; } &&
15212          { ac_try='test -s conftest.$ac_objext'
15213   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15214   (eval $ac_try) 2>&5
15215   ac_status=$?
15216   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15217   (exit $ac_status); }; }; then
15218   ac_header_compiler=yes
15219 else
15220   echo "$as_me: failed program was:" >&5
15221 sed 's/^/| /' conftest.$ac_ext >&5
15222
15223 ac_header_compiler=no
15224 fi
15225 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15226 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15227 echo "${ECHO_T}$ac_header_compiler" >&6
15228
15229 # Is the header present?
15230 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15231 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15232 cat >conftest.$ac_ext <<_ACEOF
15233 /* confdefs.h.  */
15234 _ACEOF
15235 cat confdefs.h >>conftest.$ac_ext
15236 cat >>conftest.$ac_ext <<_ACEOF
15237 /* end confdefs.h.  */
15238 #include <$ac_header>
15239 _ACEOF
15240 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15241   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15242   ac_status=$?
15243   grep -v '^ *+' conftest.er1 >conftest.err
15244   rm -f conftest.er1
15245   cat conftest.err >&5
15246   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15247   (exit $ac_status); } >/dev/null; then
15248   if test -s conftest.err; then
15249     ac_cpp_err=$ac_c_preproc_warn_flag
15250     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15251   else
15252     ac_cpp_err=
15253   fi
15254 else
15255   ac_cpp_err=yes
15256 fi
15257 if test -z "$ac_cpp_err"; then
15258   ac_header_preproc=yes
15259 else
15260   echo "$as_me: failed program was:" >&5
15261 sed 's/^/| /' conftest.$ac_ext >&5
15262
15263   ac_header_preproc=no
15264 fi
15265 rm -f conftest.err conftest.$ac_ext
15266 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15267 echo "${ECHO_T}$ac_header_preproc" >&6
15268
15269 # So?  What about this header?
15270 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15271   yes:no: )
15272     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15273 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15274     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15275 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15276     ac_header_preproc=yes
15277     ;;
15278   no:yes:* )
15279     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15280 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15281     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15282 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15283     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15284 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15285     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15286 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15287     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15288 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15289     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15290 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15291     (
15292       cat <<\_ASBOX
15293 ## --------------------------------------------- ##
15294 ## Report this to <http://www.openldap.org/its/> ##
15295 ## --------------------------------------------- ##
15296 _ASBOX
15297     ) |
15298       sed "s/^/$as_me: WARNING:     /" >&2
15299     ;;
15300 esac
15301 echo "$as_me:$LINENO: checking for $ac_header" >&5
15302 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15303 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15304   echo $ECHO_N "(cached) $ECHO_C" >&6
15305 else
15306   eval "$as_ac_Header=\$ac_header_preproc"
15307 fi
15308 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15309 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15310
15311 fi
15312 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15313   cat >>confdefs.h <<_ACEOF
15314 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15315 _ACEOF
15316
15317 fi
15318
15319 done
15320
15321 echo "$as_me:$LINENO: checking types of arguments for select" >&5
15322 echo $ECHO_N "checking types of arguments for select... $ECHO_C" >&6
15323 if test "${ac_cv_func_select_args+set}" = set; then
15324   echo $ECHO_N "(cached) $ECHO_C" >&6
15325 else
15326   for ac_arg234 in 'fd_set *' 'int *' 'void *'; do
15327  for ac_arg1 in 'int' 'size_t' 'unsigned long' 'unsigned'; do
15328   for ac_arg5 in 'struct timeval *' 'const struct timeval *'; do
15329    cat >conftest.$ac_ext <<_ACEOF
15330 /* confdefs.h.  */
15331 _ACEOF
15332 cat confdefs.h >>conftest.$ac_ext
15333 cat >>conftest.$ac_ext <<_ACEOF
15334 /* end confdefs.h.  */
15335 $ac_includes_default
15336 #if HAVE_SYS_SELECT_H
15337 # include <sys/select.h>
15338 #endif
15339 #if HAVE_SYS_SOCKET_H
15340 # include <sys/socket.h>
15341 #endif
15342
15343 int
15344 main ()
15345 {
15346 extern int select ($ac_arg1,
15347                                             $ac_arg234, $ac_arg234, $ac_arg234,
15348                                             $ac_arg5);
15349   ;
15350   return 0;
15351 }
15352 _ACEOF
15353 rm -f conftest.$ac_objext
15354 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15355   (eval $ac_compile) 2>conftest.er1
15356   ac_status=$?
15357   grep -v '^ *+' conftest.er1 >conftest.err
15358   rm -f conftest.er1
15359   cat conftest.err >&5
15360   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15361   (exit $ac_status); } &&
15362          { ac_try='test -z "$ac_c_werror_flag"
15363                          || test ! -s conftest.err'
15364   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15365   (eval $ac_try) 2>&5
15366   ac_status=$?
15367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15368   (exit $ac_status); }; } &&
15369          { ac_try='test -s conftest.$ac_objext'
15370   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15371   (eval $ac_try) 2>&5
15372   ac_status=$?
15373   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15374   (exit $ac_status); }; }; then
15375   ac_cv_func_select_args="$ac_arg1,$ac_arg234,$ac_arg5"; break 3
15376 else
15377   echo "$as_me: failed program was:" >&5
15378 sed 's/^/| /' conftest.$ac_ext >&5
15379
15380 fi
15381 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15382   done
15383  done
15384 done
15385 # Provide a safe default value.
15386 : ${ac_cv_func_select_args='int,int *,struct timeval *'}
15387
15388 fi
15389 echo "$as_me:$LINENO: result: $ac_cv_func_select_args" >&5
15390 echo "${ECHO_T}$ac_cv_func_select_args" >&6
15391 ac_save_IFS=$IFS; IFS=','
15392 set dummy `echo "$ac_cv_func_select_args" | sed 's/\*/\*/g'`
15393 IFS=$ac_save_IFS
15394 shift
15395
15396 cat >>confdefs.h <<_ACEOF
15397 #define SELECT_TYPE_ARG1 $1
15398 _ACEOF
15399
15400
15401 cat >>confdefs.h <<_ACEOF
15402 #define SELECT_TYPE_ARG234 ($2)
15403 _ACEOF
15404
15405
15406 cat >>confdefs.h <<_ACEOF
15407 #define SELECT_TYPE_ARG5 ($3)
15408 _ACEOF
15409
15410 rm -f conftest*
15411
15412 fi
15413
15414
15415
15416 for ac_func in poll
15417 do
15418 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15419 echo "$as_me:$LINENO: checking for $ac_func" >&5
15420 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15421 if eval "test \"\${$as_ac_var+set}\" = set"; then
15422   echo $ECHO_N "(cached) $ECHO_C" >&6
15423 else
15424   cat >conftest.$ac_ext <<_ACEOF
15425 /* confdefs.h.  */
15426 _ACEOF
15427 cat confdefs.h >>conftest.$ac_ext
15428 cat >>conftest.$ac_ext <<_ACEOF
15429 /* end confdefs.h.  */
15430 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15431    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15432 #define $ac_func innocuous_$ac_func
15433
15434 /* System header to define __stub macros and hopefully few prototypes,
15435     which can conflict with char $ac_func (); below.
15436     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15437     <limits.h> exists even on freestanding compilers.  */
15438
15439 #ifdef __STDC__
15440 # include <limits.h>
15441 #else
15442 # include <assert.h>
15443 #endif
15444
15445 #undef $ac_func
15446
15447 /* Override any gcc2 internal prototype to avoid an error.  */
15448 #ifdef __cplusplus
15449 extern "C"
15450 {
15451 #endif
15452 /* We use char because int might match the return type of a gcc2
15453    builtin and then its argument prototype would still apply.  */
15454 char $ac_func ();
15455 /* The GNU C library defines this for functions which it implements
15456     to always fail with ENOSYS.  Some functions are actually named
15457     something starting with __ and the normal name is an alias.  */
15458 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15459 choke me
15460 #else
15461 char (*f) () = $ac_func;
15462 #endif
15463 #ifdef __cplusplus
15464 }
15465 #endif
15466
15467 int
15468 main ()
15469 {
15470 return f != $ac_func;
15471   ;
15472   return 0;
15473 }
15474 _ACEOF
15475 rm -f conftest.$ac_objext conftest$ac_exeext
15476 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15477   (eval $ac_link) 2>conftest.er1
15478   ac_status=$?
15479   grep -v '^ *+' conftest.er1 >conftest.err
15480   rm -f conftest.er1
15481   cat conftest.err >&5
15482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15483   (exit $ac_status); } &&
15484          { ac_try='test -z "$ac_c_werror_flag"
15485                          || test ! -s conftest.err'
15486   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15487   (eval $ac_try) 2>&5
15488   ac_status=$?
15489   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15490   (exit $ac_status); }; } &&
15491          { ac_try='test -s conftest$ac_exeext'
15492   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15493   (eval $ac_try) 2>&5
15494   ac_status=$?
15495   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15496   (exit $ac_status); }; }; then
15497   eval "$as_ac_var=yes"
15498 else
15499   echo "$as_me: failed program was:" >&5
15500 sed 's/^/| /' conftest.$ac_ext >&5
15501
15502 eval "$as_ac_var=no"
15503 fi
15504 rm -f conftest.err conftest.$ac_objext \
15505       conftest$ac_exeext conftest.$ac_ext
15506 fi
15507 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15508 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15509 if test `eval echo '${'$as_ac_var'}'` = yes; then
15510   cat >>confdefs.h <<_ACEOF
15511 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15512 _ACEOF
15513
15514 fi
15515 done
15516
15517
15518 for ac_header in poll.h
15519 do
15520 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15521 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15522   echo "$as_me:$LINENO: checking for $ac_header" >&5
15523 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15524 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15525   echo $ECHO_N "(cached) $ECHO_C" >&6
15526 fi
15527 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15528 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15529 else
15530   # Is the header compilable?
15531 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15532 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15533 cat >conftest.$ac_ext <<_ACEOF
15534 /* confdefs.h.  */
15535 _ACEOF
15536 cat confdefs.h >>conftest.$ac_ext
15537 cat >>conftest.$ac_ext <<_ACEOF
15538 /* end confdefs.h.  */
15539 $ac_includes_default
15540 #include <$ac_header>
15541 _ACEOF
15542 rm -f conftest.$ac_objext
15543 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15544   (eval $ac_compile) 2>conftest.er1
15545   ac_status=$?
15546   grep -v '^ *+' conftest.er1 >conftest.err
15547   rm -f conftest.er1
15548   cat conftest.err >&5
15549   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15550   (exit $ac_status); } &&
15551          { ac_try='test -z "$ac_c_werror_flag"
15552                          || test ! -s conftest.err'
15553   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15554   (eval $ac_try) 2>&5
15555   ac_status=$?
15556   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15557   (exit $ac_status); }; } &&
15558          { ac_try='test -s conftest.$ac_objext'
15559   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15560   (eval $ac_try) 2>&5
15561   ac_status=$?
15562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15563   (exit $ac_status); }; }; then
15564   ac_header_compiler=yes
15565 else
15566   echo "$as_me: failed program was:" >&5
15567 sed 's/^/| /' conftest.$ac_ext >&5
15568
15569 ac_header_compiler=no
15570 fi
15571 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15572 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15573 echo "${ECHO_T}$ac_header_compiler" >&6
15574
15575 # Is the header present?
15576 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15577 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15578 cat >conftest.$ac_ext <<_ACEOF
15579 /* confdefs.h.  */
15580 _ACEOF
15581 cat confdefs.h >>conftest.$ac_ext
15582 cat >>conftest.$ac_ext <<_ACEOF
15583 /* end confdefs.h.  */
15584 #include <$ac_header>
15585 _ACEOF
15586 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15587   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15588   ac_status=$?
15589   grep -v '^ *+' conftest.er1 >conftest.err
15590   rm -f conftest.er1
15591   cat conftest.err >&5
15592   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15593   (exit $ac_status); } >/dev/null; then
15594   if test -s conftest.err; then
15595     ac_cpp_err=$ac_c_preproc_warn_flag
15596     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15597   else
15598     ac_cpp_err=
15599   fi
15600 else
15601   ac_cpp_err=yes
15602 fi
15603 if test -z "$ac_cpp_err"; then
15604   ac_header_preproc=yes
15605 else
15606   echo "$as_me: failed program was:" >&5
15607 sed 's/^/| /' conftest.$ac_ext >&5
15608
15609   ac_header_preproc=no
15610 fi
15611 rm -f conftest.err conftest.$ac_ext
15612 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15613 echo "${ECHO_T}$ac_header_preproc" >&6
15614
15615 # So?  What about this header?
15616 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15617   yes:no: )
15618     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15619 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15620     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15621 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15622     ac_header_preproc=yes
15623     ;;
15624   no:yes:* )
15625     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15626 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15627     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15628 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15629     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15630 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15631     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15632 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15633     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15634 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15635     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15636 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15637     (
15638       cat <<\_ASBOX
15639 ## --------------------------------------------- ##
15640 ## Report this to <http://www.openldap.org/its/> ##
15641 ## --------------------------------------------- ##
15642 _ASBOX
15643     ) |
15644       sed "s/^/$as_me: WARNING:     /" >&2
15645     ;;
15646 esac
15647 echo "$as_me:$LINENO: checking for $ac_header" >&5
15648 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15649 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15650   echo $ECHO_N "(cached) $ECHO_C" >&6
15651 else
15652   eval "$as_ac_Header=\$ac_header_preproc"
15653 fi
15654 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15655 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15656
15657 fi
15658 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15659   cat >>confdefs.h <<_ACEOF
15660 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15661 _ACEOF
15662
15663 fi
15664
15665 done
15666
15667
15668
15669 for ac_header in sys/epoll.h
15670 do
15671 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15672 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15673   echo "$as_me:$LINENO: checking for $ac_header" >&5
15674 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15675 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15676   echo $ECHO_N "(cached) $ECHO_C" >&6
15677 fi
15678 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15679 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15680 else
15681   # Is the header compilable?
15682 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15683 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15684 cat >conftest.$ac_ext <<_ACEOF
15685 /* confdefs.h.  */
15686 _ACEOF
15687 cat confdefs.h >>conftest.$ac_ext
15688 cat >>conftest.$ac_ext <<_ACEOF
15689 /* end confdefs.h.  */
15690 $ac_includes_default
15691 #include <$ac_header>
15692 _ACEOF
15693 rm -f conftest.$ac_objext
15694 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15695   (eval $ac_compile) 2>conftest.er1
15696   ac_status=$?
15697   grep -v '^ *+' conftest.er1 >conftest.err
15698   rm -f conftest.er1
15699   cat conftest.err >&5
15700   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15701   (exit $ac_status); } &&
15702          { ac_try='test -z "$ac_c_werror_flag"
15703                          || test ! -s conftest.err'
15704   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15705   (eval $ac_try) 2>&5
15706   ac_status=$?
15707   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15708   (exit $ac_status); }; } &&
15709          { ac_try='test -s conftest.$ac_objext'
15710   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15711   (eval $ac_try) 2>&5
15712   ac_status=$?
15713   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15714   (exit $ac_status); }; }; then
15715   ac_header_compiler=yes
15716 else
15717   echo "$as_me: failed program was:" >&5
15718 sed 's/^/| /' conftest.$ac_ext >&5
15719
15720 ac_header_compiler=no
15721 fi
15722 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15723 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15724 echo "${ECHO_T}$ac_header_compiler" >&6
15725
15726 # Is the header present?
15727 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15728 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15729 cat >conftest.$ac_ext <<_ACEOF
15730 /* confdefs.h.  */
15731 _ACEOF
15732 cat confdefs.h >>conftest.$ac_ext
15733 cat >>conftest.$ac_ext <<_ACEOF
15734 /* end confdefs.h.  */
15735 #include <$ac_header>
15736 _ACEOF
15737 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15738   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15739   ac_status=$?
15740   grep -v '^ *+' conftest.er1 >conftest.err
15741   rm -f conftest.er1
15742   cat conftest.err >&5
15743   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15744   (exit $ac_status); } >/dev/null; then
15745   if test -s conftest.err; then
15746     ac_cpp_err=$ac_c_preproc_warn_flag
15747     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15748   else
15749     ac_cpp_err=
15750   fi
15751 else
15752   ac_cpp_err=yes
15753 fi
15754 if test -z "$ac_cpp_err"; then
15755   ac_header_preproc=yes
15756 else
15757   echo "$as_me: failed program was:" >&5
15758 sed 's/^/| /' conftest.$ac_ext >&5
15759
15760   ac_header_preproc=no
15761 fi
15762 rm -f conftest.err conftest.$ac_ext
15763 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15764 echo "${ECHO_T}$ac_header_preproc" >&6
15765
15766 # So?  What about this header?
15767 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15768   yes:no: )
15769     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15770 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15771     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15772 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15773     ac_header_preproc=yes
15774     ;;
15775   no:yes:* )
15776     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15777 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15778     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15779 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15780     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15781 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15782     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15783 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15784     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15785 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15786     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15787 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15788     (
15789       cat <<\_ASBOX
15790 ## --------------------------------------------- ##
15791 ## Report this to <http://www.openldap.org/its/> ##
15792 ## --------------------------------------------- ##
15793 _ASBOX
15794     ) |
15795       sed "s/^/$as_me: WARNING:     /" >&2
15796     ;;
15797 esac
15798 echo "$as_me:$LINENO: checking for $ac_header" >&5
15799 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15800 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15801   echo $ECHO_N "(cached) $ECHO_C" >&6
15802 else
15803   eval "$as_ac_Header=\$ac_header_preproc"
15804 fi
15805 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15806 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15807
15808 fi
15809 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15810   cat >>confdefs.h <<_ACEOF
15811 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15812 _ACEOF
15813
15814 fi
15815
15816 done
15817
15818 if test "${ac_cv_header_sys_epoll_h}" = yes; then
15819 echo "$as_me:$LINENO: checking for epoll system call" >&5
15820 echo $ECHO_N "checking for epoll system call... $ECHO_C" >&6
15821 if test "$cross_compiling" = yes; then
15822   echo "$as_me:$LINENO: result: no" >&5
15823 echo "${ECHO_T}no" >&6
15824 else
15825   cat >conftest.$ac_ext <<_ACEOF
15826 /* confdefs.h.  */
15827 _ACEOF
15828 cat confdefs.h >>conftest.$ac_ext
15829 cat >>conftest.$ac_ext <<_ACEOF
15830 /* end confdefs.h.  */
15831 int main(int argc, char *argv)
15832 {
15833         int epfd = epoll_create(256);
15834         exit (epfd == -1 ? 1 : 0);
15835 }
15836 _ACEOF
15837 rm -f conftest$ac_exeext
15838 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15839   (eval $ac_link) 2>&5
15840   ac_status=$?
15841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15842   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15843   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15844   (eval $ac_try) 2>&5
15845   ac_status=$?
15846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15847   (exit $ac_status); }; }; then
15848   echo "$as_me:$LINENO: result: yes" >&5
15849 echo "${ECHO_T}yes" >&6
15850
15851 cat >>confdefs.h <<\_ACEOF
15852 #define HAVE_EPOLL 1
15853 _ACEOF
15854
15855 else
15856   echo "$as_me: program exited with status $ac_status" >&5
15857 echo "$as_me: failed program was:" >&5
15858 sed 's/^/| /' conftest.$ac_ext >&5
15859
15860 ( exit $ac_status )
15861 echo "$as_me:$LINENO: result: no" >&5
15862 echo "${ECHO_T}no" >&6
15863 fi
15864 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15865 fi
15866 fi
15867
15868 # strerror checks
15869 echo "$as_me:$LINENO: checking declaration of sys_errlist" >&5
15870 echo $ECHO_N "checking declaration of sys_errlist... $ECHO_C" >&6
15871 if test "${ol_cv_dcl_sys_errlist+set}" = set; then
15872   echo $ECHO_N "(cached) $ECHO_C" >&6
15873 else
15874
15875         cat >conftest.$ac_ext <<_ACEOF
15876 /* confdefs.h.  */
15877 _ACEOF
15878 cat confdefs.h >>conftest.$ac_ext
15879 cat >>conftest.$ac_ext <<_ACEOF
15880 /* end confdefs.h.  */
15881
15882 #include <stdio.h>
15883 #include <sys/types.h>
15884 #include <errno.h>
15885 #ifdef WINNT
15886 #include <stdlib.h>
15887 #endif
15888 int
15889 main ()
15890 {
15891 char *c = (char *) *sys_errlist
15892   ;
15893   return 0;
15894 }
15895 _ACEOF
15896 rm -f conftest.$ac_objext
15897 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15898   (eval $ac_compile) 2>conftest.er1
15899   ac_status=$?
15900   grep -v '^ *+' conftest.er1 >conftest.err
15901   rm -f conftest.er1
15902   cat conftest.err >&5
15903   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15904   (exit $ac_status); } &&
15905          { ac_try='test -z "$ac_c_werror_flag"
15906                          || test ! -s conftest.err'
15907   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15908   (eval $ac_try) 2>&5
15909   ac_status=$?
15910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15911   (exit $ac_status); }; } &&
15912          { ac_try='test -s conftest.$ac_objext'
15913   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15914   (eval $ac_try) 2>&5
15915   ac_status=$?
15916   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15917   (exit $ac_status); }; }; then
15918   ol_cv_dcl_sys_errlist=yes
15919         ol_cv_have_sys_errlist=yes
15920 else
15921   echo "$as_me: failed program was:" >&5
15922 sed 's/^/| /' conftest.$ac_ext >&5
15923
15924 ol_cv_dcl_sys_errlist=no
15925 fi
15926 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15927 fi
15928 echo "$as_me:$LINENO: result: $ol_cv_dcl_sys_errlist" >&5
15929 echo "${ECHO_T}$ol_cv_dcl_sys_errlist" >&6
15930 #
15931 # It's possible (for near-UNIX clones) that sys_errlist doesn't exist
15932 if test $ol_cv_dcl_sys_errlist = no ; then
15933
15934 cat >>confdefs.h <<\_ACEOF
15935 #define DECL_SYS_ERRLIST 1
15936 _ACEOF
15937
15938
15939         echo "$as_me:$LINENO: checking existence of sys_errlist" >&5
15940 echo $ECHO_N "checking existence of sys_errlist... $ECHO_C" >&6
15941 if test "${ol_cv_have_sys_errlist+set}" = set; then
15942   echo $ECHO_N "(cached) $ECHO_C" >&6
15943 else
15944
15945                 cat >conftest.$ac_ext <<_ACEOF
15946 /* confdefs.h.  */
15947 _ACEOF
15948 cat confdefs.h >>conftest.$ac_ext
15949 cat >>conftest.$ac_ext <<_ACEOF
15950 /* end confdefs.h.  */
15951 #include <errno.h>
15952 int
15953 main ()
15954 {
15955 char *c = (char *) *sys_errlist
15956   ;
15957   return 0;
15958 }
15959 _ACEOF
15960 rm -f conftest.$ac_objext conftest$ac_exeext
15961 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15962   (eval $ac_link) 2>conftest.er1
15963   ac_status=$?
15964   grep -v '^ *+' conftest.er1 >conftest.err
15965   rm -f conftest.er1
15966   cat conftest.err >&5
15967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15968   (exit $ac_status); } &&
15969          { ac_try='test -z "$ac_c_werror_flag"
15970                          || test ! -s conftest.err'
15971   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15972   (eval $ac_try) 2>&5
15973   ac_status=$?
15974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15975   (exit $ac_status); }; } &&
15976          { ac_try='test -s conftest$ac_exeext'
15977   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15978   (eval $ac_try) 2>&5
15979   ac_status=$?
15980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15981   (exit $ac_status); }; }; then
15982   ol_cv_have_sys_errlist=yes
15983 else
15984   echo "$as_me: failed program was:" >&5
15985 sed 's/^/| /' conftest.$ac_ext >&5
15986
15987 ol_cv_have_sys_errlist=no
15988 fi
15989 rm -f conftest.err conftest.$ac_objext \
15990       conftest$ac_exeext conftest.$ac_ext
15991 fi
15992 echo "$as_me:$LINENO: result: $ol_cv_have_sys_errlist" >&5
15993 echo "${ECHO_T}$ol_cv_have_sys_errlist" >&6
15994 fi
15995 if test $ol_cv_have_sys_errlist = yes ; then
15996
15997 cat >>confdefs.h <<\_ACEOF
15998 #define HAVE_SYS_ERRLIST 1
15999 _ACEOF
16000
16001 fi
16002
16003
16004 for ac_func in strerror strerror_r
16005 do
16006 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16007 echo "$as_me:$LINENO: checking for $ac_func" >&5
16008 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16009 if eval "test \"\${$as_ac_var+set}\" = set"; then
16010   echo $ECHO_N "(cached) $ECHO_C" >&6
16011 else
16012   cat >conftest.$ac_ext <<_ACEOF
16013 /* confdefs.h.  */
16014 _ACEOF
16015 cat confdefs.h >>conftest.$ac_ext
16016 cat >>conftest.$ac_ext <<_ACEOF
16017 /* end confdefs.h.  */
16018 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16019    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16020 #define $ac_func innocuous_$ac_func
16021
16022 /* System header to define __stub macros and hopefully few prototypes,
16023     which can conflict with char $ac_func (); below.
16024     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16025     <limits.h> exists even on freestanding compilers.  */
16026
16027 #ifdef __STDC__
16028 # include <limits.h>
16029 #else
16030 # include <assert.h>
16031 #endif
16032
16033 #undef $ac_func
16034
16035 /* Override any gcc2 internal prototype to avoid an error.  */
16036 #ifdef __cplusplus
16037 extern "C"
16038 {
16039 #endif
16040 /* We use char because int might match the return type of a gcc2
16041    builtin and then its argument prototype would still apply.  */
16042 char $ac_func ();
16043 /* The GNU C library defines this for functions which it implements
16044     to always fail with ENOSYS.  Some functions are actually named
16045     something starting with __ and the normal name is an alias.  */
16046 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16047 choke me
16048 #else
16049 char (*f) () = $ac_func;
16050 #endif
16051 #ifdef __cplusplus
16052 }
16053 #endif
16054
16055 int
16056 main ()
16057 {
16058 return f != $ac_func;
16059   ;
16060   return 0;
16061 }
16062 _ACEOF
16063 rm -f conftest.$ac_objext conftest$ac_exeext
16064 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16065   (eval $ac_link) 2>conftest.er1
16066   ac_status=$?
16067   grep -v '^ *+' conftest.er1 >conftest.err
16068   rm -f conftest.er1
16069   cat conftest.err >&5
16070   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16071   (exit $ac_status); } &&
16072          { ac_try='test -z "$ac_c_werror_flag"
16073                          || test ! -s conftest.err'
16074   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16075   (eval $ac_try) 2>&5
16076   ac_status=$?
16077   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16078   (exit $ac_status); }; } &&
16079          { ac_try='test -s conftest$ac_exeext'
16080   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16081   (eval $ac_try) 2>&5
16082   ac_status=$?
16083   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16084   (exit $ac_status); }; }; then
16085   eval "$as_ac_var=yes"
16086 else
16087   echo "$as_me: failed program was:" >&5
16088 sed 's/^/| /' conftest.$ac_ext >&5
16089
16090 eval "$as_ac_var=no"
16091 fi
16092 rm -f conftest.err conftest.$ac_objext \
16093       conftest$ac_exeext conftest.$ac_ext
16094 fi
16095 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16096 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16097 if test `eval echo '${'$as_ac_var'}'` = yes; then
16098   cat >>confdefs.h <<_ACEOF
16099 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16100 _ACEOF
16101
16102 fi
16103 done
16104
16105 ol_cv_func_strerror_r=no
16106 if test "${ac_cv_func_strerror_r}" = yes ; then
16107         echo "$as_me:$LINENO: checking non-posix strerror_r" >&5
16108 echo $ECHO_N "checking non-posix strerror_r... $ECHO_C" >&6
16109 if test "${ol_cv_nonposix_strerror_r+set}" = set; then
16110   echo $ECHO_N "(cached) $ECHO_C" >&6
16111 else
16112
16113         cat >conftest.$ac_ext <<_ACEOF
16114 /* confdefs.h.  */
16115 _ACEOF
16116 cat confdefs.h >>conftest.$ac_ext
16117 cat >>conftest.$ac_ext <<_ACEOF
16118 /* end confdefs.h.  */
16119 #include <string.h>
16120 _ACEOF
16121 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16122   $EGREP "strerror_r" >/dev/null 2>&1; then
16123   ol_decl_strerror_r=yes
16124 else
16125   ol_decl_strerror_r=no
16126 fi
16127 rm -f conftest*
16128
16129         if test $ol_decl_strerror_r = yes ; then
16130                 cat >conftest.$ac_ext <<_ACEOF
16131 /* confdefs.h.  */
16132 _ACEOF
16133 cat confdefs.h >>conftest.$ac_ext
16134 cat >>conftest.$ac_ext <<_ACEOF
16135 /* end confdefs.h.  */
16136 #include <string.h>
16137 int
16138 main ()
16139 {
16140    /* from autoconf 2.59 */
16141                                 char buf[100];
16142                                 char x = *strerror_r (0, buf, sizeof buf);
16143                                 char *p = strerror_r (0, buf, sizeof buf);
16144
16145   ;
16146   return 0;
16147 }
16148 _ACEOF
16149 rm -f conftest.$ac_objext
16150 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16151   (eval $ac_compile) 2>conftest.er1
16152   ac_status=$?
16153   grep -v '^ *+' conftest.er1 >conftest.err
16154   rm -f conftest.er1
16155   cat conftest.err >&5
16156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16157   (exit $ac_status); } &&
16158          { ac_try='test -z "$ac_c_werror_flag"
16159                          || test ! -s conftest.err'
16160   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16161   (eval $ac_try) 2>&5
16162   ac_status=$?
16163   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16164   (exit $ac_status); }; } &&
16165          { ac_try='test -s conftest.$ac_objext'
16166   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16167   (eval $ac_try) 2>&5
16168   ac_status=$?
16169   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16170   (exit $ac_status); }; }; then
16171   ol_cv_nonposix_strerror_r=yes
16172 else
16173   echo "$as_me: failed program was:" >&5
16174 sed 's/^/| /' conftest.$ac_ext >&5
16175
16176 ol_cv_nonposix_strerror_r=no
16177 fi
16178 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16179         else
16180                 if test "$cross_compiling" = yes; then
16181   ol_cv_nonposix_strerror=no
16182 else
16183   cat >conftest.$ac_ext <<_ACEOF
16184 /* confdefs.h.  */
16185 _ACEOF
16186 cat confdefs.h >>conftest.$ac_ext
16187 cat >>conftest.$ac_ext <<_ACEOF
16188 /* end confdefs.h.  */
16189
16190                         main() {
16191                                 char buf[100];
16192                                 buf[0] = 0;
16193                                 strerror_r( 1, buf, sizeof buf );
16194                                 exit( buf[0] == 0 );
16195                         }
16196
16197 _ACEOF
16198 rm -f conftest$ac_exeext
16199 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16200   (eval $ac_link) 2>&5
16201   ac_status=$?
16202   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16203   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16204   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16205   (eval $ac_try) 2>&5
16206   ac_status=$?
16207   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16208   (exit $ac_status); }; }; then
16209   ol_cv_nonposix_strerror_r=yes
16210 else
16211   echo "$as_me: program exited with status $ac_status" >&5
16212 echo "$as_me: failed program was:" >&5
16213 sed 's/^/| /' conftest.$ac_ext >&5
16214
16215 ( exit $ac_status )
16216 ol_cv_nonposix_strerror=no
16217 fi
16218 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16219 fi
16220         fi
16221
16222 fi
16223 echo "$as_me:$LINENO: result: $ol_cv_nonposix_strerror_r" >&5
16224 echo "${ECHO_T}$ol_cv_nonposix_strerror_r" >&6
16225 if test $ol_cv_nonposix_strerror_r = yes ; then
16226
16227 cat >>confdefs.h <<\_ACEOF
16228 #define HAVE_NONPOSIX_STRERROR_R 1
16229 _ACEOF
16230
16231 fi
16232
16233 elif test "${ac_cv_func_strerror}" = no ; then
16234         echo "$as_me:$LINENO: checking declaration of sys_errlist" >&5
16235 echo $ECHO_N "checking declaration of sys_errlist... $ECHO_C" >&6
16236 if test "${ol_cv_dcl_sys_errlist+set}" = set; then
16237   echo $ECHO_N "(cached) $ECHO_C" >&6
16238 else
16239
16240         cat >conftest.$ac_ext <<_ACEOF
16241 /* confdefs.h.  */
16242 _ACEOF
16243 cat confdefs.h >>conftest.$ac_ext
16244 cat >>conftest.$ac_ext <<_ACEOF
16245 /* end confdefs.h.  */
16246
16247 #include <stdio.h>
16248 #include <sys/types.h>
16249 #include <errno.h>
16250 #ifdef WINNT
16251 #include <stdlib.h>
16252 #endif
16253 int
16254 main ()
16255 {
16256 char *c = (char *) *sys_errlist
16257   ;
16258   return 0;
16259 }
16260 _ACEOF
16261 rm -f conftest.$ac_objext
16262 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16263   (eval $ac_compile) 2>conftest.er1
16264   ac_status=$?
16265   grep -v '^ *+' conftest.er1 >conftest.err
16266   rm -f conftest.er1
16267   cat conftest.err >&5
16268   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16269   (exit $ac_status); } &&
16270          { ac_try='test -z "$ac_c_werror_flag"
16271                          || test ! -s conftest.err'
16272   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16273   (eval $ac_try) 2>&5
16274   ac_status=$?
16275   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16276   (exit $ac_status); }; } &&
16277          { ac_try='test -s conftest.$ac_objext'
16278   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16279   (eval $ac_try) 2>&5
16280   ac_status=$?
16281   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16282   (exit $ac_status); }; }; then
16283   ol_cv_dcl_sys_errlist=yes
16284         ol_cv_have_sys_errlist=yes
16285 else
16286   echo "$as_me: failed program was:" >&5
16287 sed 's/^/| /' conftest.$ac_ext >&5
16288
16289 ol_cv_dcl_sys_errlist=no
16290 fi
16291 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16292 fi
16293 echo "$as_me:$LINENO: result: $ol_cv_dcl_sys_errlist" >&5
16294 echo "${ECHO_T}$ol_cv_dcl_sys_errlist" >&6
16295 #
16296 # It's possible (for near-UNIX clones) that sys_errlist doesn't exist
16297 if test $ol_cv_dcl_sys_errlist = no ; then
16298
16299 cat >>confdefs.h <<\_ACEOF
16300 #define DECL_SYS_ERRLIST 1
16301 _ACEOF
16302
16303
16304         echo "$as_me:$LINENO: checking existence of sys_errlist" >&5
16305 echo $ECHO_N "checking existence of sys_errlist... $ECHO_C" >&6
16306 if test "${ol_cv_have_sys_errlist+set}" = set; then
16307   echo $ECHO_N "(cached) $ECHO_C" >&6
16308 else
16309
16310                 cat >conftest.$ac_ext <<_ACEOF
16311 /* confdefs.h.  */
16312 _ACEOF
16313 cat confdefs.h >>conftest.$ac_ext
16314 cat >>conftest.$ac_ext <<_ACEOF
16315 /* end confdefs.h.  */
16316 #include <errno.h>
16317 int
16318 main ()
16319 {
16320 char *c = (char *) *sys_errlist
16321   ;
16322   return 0;
16323 }
16324 _ACEOF
16325 rm -f conftest.$ac_objext conftest$ac_exeext
16326 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16327   (eval $ac_link) 2>conftest.er1
16328   ac_status=$?
16329   grep -v '^ *+' conftest.er1 >conftest.err
16330   rm -f conftest.er1
16331   cat conftest.err >&5
16332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16333   (exit $ac_status); } &&
16334          { ac_try='test -z "$ac_c_werror_flag"
16335                          || test ! -s conftest.err'
16336   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16337   (eval $ac_try) 2>&5
16338   ac_status=$?
16339   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16340   (exit $ac_status); }; } &&
16341          { ac_try='test -s conftest$ac_exeext'
16342   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16343   (eval $ac_try) 2>&5
16344   ac_status=$?
16345   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16346   (exit $ac_status); }; }; then
16347   ol_cv_have_sys_errlist=yes
16348 else
16349   echo "$as_me: failed program was:" >&5
16350 sed 's/^/| /' conftest.$ac_ext >&5
16351
16352 ol_cv_have_sys_errlist=no
16353 fi
16354 rm -f conftest.err conftest.$ac_objext \
16355       conftest$ac_exeext conftest.$ac_ext
16356 fi
16357 echo "$as_me:$LINENO: result: $ol_cv_have_sys_errlist" >&5
16358 echo "${ECHO_T}$ol_cv_have_sys_errlist" >&6
16359 fi
16360 if test $ol_cv_have_sys_errlist = yes ; then
16361
16362 cat >>confdefs.h <<\_ACEOF
16363 #define HAVE_SYS_ERRLIST 1
16364 _ACEOF
16365
16366 fi
16367
16368 fi
16369
16370
16371
16372 for ac_header in regex.h
16373 do
16374 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16375 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16376   echo "$as_me:$LINENO: checking for $ac_header" >&5
16377 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16378 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16379   echo $ECHO_N "(cached) $ECHO_C" >&6
16380 fi
16381 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16382 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16383 else
16384   # Is the header compilable?
16385 echo "$as_me:$LINENO: checking $ac_header usability" >&5
16386 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16387 cat >conftest.$ac_ext <<_ACEOF
16388 /* confdefs.h.  */
16389 _ACEOF
16390 cat confdefs.h >>conftest.$ac_ext
16391 cat >>conftest.$ac_ext <<_ACEOF
16392 /* end confdefs.h.  */
16393 $ac_includes_default
16394 #include <$ac_header>
16395 _ACEOF
16396 rm -f conftest.$ac_objext
16397 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16398   (eval $ac_compile) 2>conftest.er1
16399   ac_status=$?
16400   grep -v '^ *+' conftest.er1 >conftest.err
16401   rm -f conftest.er1
16402   cat conftest.err >&5
16403   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16404   (exit $ac_status); } &&
16405          { ac_try='test -z "$ac_c_werror_flag"
16406                          || test ! -s conftest.err'
16407   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16408   (eval $ac_try) 2>&5
16409   ac_status=$?
16410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16411   (exit $ac_status); }; } &&
16412          { ac_try='test -s conftest.$ac_objext'
16413   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16414   (eval $ac_try) 2>&5
16415   ac_status=$?
16416   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16417   (exit $ac_status); }; }; then
16418   ac_header_compiler=yes
16419 else
16420   echo "$as_me: failed program was:" >&5
16421 sed 's/^/| /' conftest.$ac_ext >&5
16422
16423 ac_header_compiler=no
16424 fi
16425 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16426 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16427 echo "${ECHO_T}$ac_header_compiler" >&6
16428
16429 # Is the header present?
16430 echo "$as_me:$LINENO: checking $ac_header presence" >&5
16431 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
16432 cat >conftest.$ac_ext <<_ACEOF
16433 /* confdefs.h.  */
16434 _ACEOF
16435 cat confdefs.h >>conftest.$ac_ext
16436 cat >>conftest.$ac_ext <<_ACEOF
16437 /* end confdefs.h.  */
16438 #include <$ac_header>
16439 _ACEOF
16440 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
16441   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16442   ac_status=$?
16443   grep -v '^ *+' conftest.er1 >conftest.err
16444   rm -f conftest.er1
16445   cat conftest.err >&5
16446   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16447   (exit $ac_status); } >/dev/null; then
16448   if test -s conftest.err; then
16449     ac_cpp_err=$ac_c_preproc_warn_flag
16450     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
16451   else
16452     ac_cpp_err=
16453   fi
16454 else
16455   ac_cpp_err=yes
16456 fi
16457 if test -z "$ac_cpp_err"; then
16458   ac_header_preproc=yes
16459 else
16460   echo "$as_me: failed program was:" >&5
16461 sed 's/^/| /' conftest.$ac_ext >&5
16462
16463   ac_header_preproc=no
16464 fi
16465 rm -f conftest.err conftest.$ac_ext
16466 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16467 echo "${ECHO_T}$ac_header_preproc" >&6
16468
16469 # So?  What about this header?
16470 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16471   yes:no: )
16472     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
16473 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
16474     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
16475 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
16476     ac_header_preproc=yes
16477     ;;
16478   no:yes:* )
16479     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
16480 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
16481     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
16482 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
16483     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
16484 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
16485     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
16486 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
16487     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
16488 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16489     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
16490 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
16491     (
16492       cat <<\_ASBOX
16493 ## --------------------------------------------- ##
16494 ## Report this to <http://www.openldap.org/its/> ##
16495 ## --------------------------------------------- ##
16496 _ASBOX
16497     ) |
16498       sed "s/^/$as_me: WARNING:     /" >&2
16499     ;;
16500 esac
16501 echo "$as_me:$LINENO: checking for $ac_header" >&5
16502 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16503 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16504   echo $ECHO_N "(cached) $ECHO_C" >&6
16505 else
16506   eval "$as_ac_Header=\$ac_header_preproc"
16507 fi
16508 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16509 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16510
16511 fi
16512 if test `eval echo '${'$as_ac_Header'}'` = yes; then
16513   cat >>confdefs.h <<_ACEOF
16514 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16515 _ACEOF
16516
16517 fi
16518
16519 done
16520
16521 if test "$ac_cv_header_regex_h" != yes ; then
16522         { { echo "$as_me:$LINENO: error: POSIX regex.h required." >&5
16523 echo "$as_me: error: POSIX regex.h required." >&2;}
16524    { (exit 1); exit 1; }; }
16525 fi
16526 echo "$as_me:$LINENO: checking for library containing regfree" >&5
16527 echo $ECHO_N "checking for library containing regfree... $ECHO_C" >&6
16528 if test "${ac_cv_search_regfree+set}" = set; then
16529   echo $ECHO_N "(cached) $ECHO_C" >&6
16530 else
16531   ac_func_search_save_LIBS=$LIBS
16532 ac_cv_search_regfree=no
16533 cat >conftest.$ac_ext <<_ACEOF
16534 /* confdefs.h.  */
16535 _ACEOF
16536 cat confdefs.h >>conftest.$ac_ext
16537 cat >>conftest.$ac_ext <<_ACEOF
16538 /* end confdefs.h.  */
16539
16540 /* Override any gcc2 internal prototype to avoid an error.  */
16541 #ifdef __cplusplus
16542 extern "C"
16543 #endif
16544 /* We use char because int might match the return type of a gcc2
16545    builtin and then its argument prototype would still apply.  */
16546 char regfree ();
16547 int
16548 main ()
16549 {
16550 regfree ();
16551   ;
16552   return 0;
16553 }
16554 _ACEOF
16555 rm -f conftest.$ac_objext conftest$ac_exeext
16556 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16557   (eval $ac_link) 2>conftest.er1
16558   ac_status=$?
16559   grep -v '^ *+' conftest.er1 >conftest.err
16560   rm -f conftest.er1
16561   cat conftest.err >&5
16562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16563   (exit $ac_status); } &&
16564          { ac_try='test -z "$ac_c_werror_flag"
16565                          || test ! -s conftest.err'
16566   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16567   (eval $ac_try) 2>&5
16568   ac_status=$?
16569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16570   (exit $ac_status); }; } &&
16571          { ac_try='test -s conftest$ac_exeext'
16572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16573   (eval $ac_try) 2>&5
16574   ac_status=$?
16575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16576   (exit $ac_status); }; }; then
16577   ac_cv_search_regfree="none required"
16578 else
16579   echo "$as_me: failed program was:" >&5
16580 sed 's/^/| /' conftest.$ac_ext >&5
16581
16582 fi
16583 rm -f conftest.err conftest.$ac_objext \
16584       conftest$ac_exeext conftest.$ac_ext
16585 if test "$ac_cv_search_regfree" = no; then
16586   for ac_lib in regex gnuregex; do
16587     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
16588     cat >conftest.$ac_ext <<_ACEOF
16589 /* confdefs.h.  */
16590 _ACEOF
16591 cat confdefs.h >>conftest.$ac_ext
16592 cat >>conftest.$ac_ext <<_ACEOF
16593 /* end confdefs.h.  */
16594
16595 /* Override any gcc2 internal prototype to avoid an error.  */
16596 #ifdef __cplusplus
16597 extern "C"
16598 #endif
16599 /* We use char because int might match the return type of a gcc2
16600    builtin and then its argument prototype would still apply.  */
16601 char regfree ();
16602 int
16603 main ()
16604 {
16605 regfree ();
16606   ;
16607   return 0;
16608 }
16609 _ACEOF
16610 rm -f conftest.$ac_objext conftest$ac_exeext
16611 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16612   (eval $ac_link) 2>conftest.er1
16613   ac_status=$?
16614   grep -v '^ *+' conftest.er1 >conftest.err
16615   rm -f conftest.er1
16616   cat conftest.err >&5
16617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16618   (exit $ac_status); } &&
16619          { ac_try='test -z "$ac_c_werror_flag"
16620                          || test ! -s conftest.err'
16621   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16622   (eval $ac_try) 2>&5
16623   ac_status=$?
16624   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16625   (exit $ac_status); }; } &&
16626          { ac_try='test -s conftest$ac_exeext'
16627   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16628   (eval $ac_try) 2>&5
16629   ac_status=$?
16630   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16631   (exit $ac_status); }; }; then
16632   ac_cv_search_regfree="-l$ac_lib"
16633 break
16634 else
16635   echo "$as_me: failed program was:" >&5
16636 sed 's/^/| /' conftest.$ac_ext >&5
16637
16638 fi
16639 rm -f conftest.err conftest.$ac_objext \
16640       conftest$ac_exeext conftest.$ac_ext
16641   done
16642 fi
16643 LIBS=$ac_func_search_save_LIBS
16644 fi
16645 echo "$as_me:$LINENO: result: $ac_cv_search_regfree" >&5
16646 echo "${ECHO_T}$ac_cv_search_regfree" >&6
16647 if test "$ac_cv_search_regfree" != no; then
16648   test "$ac_cv_search_regfree" = "none required" || LIBS="$ac_cv_search_regfree $LIBS"
16649   :
16650 else
16651   { { echo "$as_me:$LINENO: error: POSIX regex required." >&5
16652 echo "$as_me: error: POSIX regex required." >&2;}
16653    { (exit 1); exit 1; }; }
16654 fi
16655
16656
16657
16658 echo "$as_me:$LINENO: checking for compatible POSIX regex" >&5
16659 echo $ECHO_N "checking for compatible POSIX regex... $ECHO_C" >&6
16660 if test "${ol_cv_c_posix_regex+set}" = set; then
16661   echo $ECHO_N "(cached) $ECHO_C" >&6
16662 else
16663
16664         if test "$cross_compiling" = yes; then
16665   ol_cv_c_posix_regex=cross
16666 else
16667   cat >conftest.$ac_ext <<_ACEOF
16668 /* confdefs.h.  */
16669 _ACEOF
16670 cat confdefs.h >>conftest.$ac_ext
16671 cat >>conftest.$ac_ext <<_ACEOF
16672 /* end confdefs.h.  */
16673
16674 #include <sys/types.h>
16675 #include <regex.h>
16676 static char *pattern, *string;
16677 main()
16678 {
16679         int rc;
16680         regex_t re;
16681
16682         pattern = "^A";
16683
16684         if(regcomp(&re, pattern, 0)) {
16685                 return -1;
16686         }
16687
16688         string = "ALL MATCH";
16689
16690         rc = regexec(&re, string, 0, (void*)0, 0);
16691
16692         regfree(&re);
16693
16694         return rc;
16695 }
16696 _ACEOF
16697 rm -f conftest$ac_exeext
16698 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16699   (eval $ac_link) 2>&5
16700   ac_status=$?
16701   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16702   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16703   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16704   (eval $ac_try) 2>&5
16705   ac_status=$?
16706   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16707   (exit $ac_status); }; }; then
16708   ol_cv_c_posix_regex=yes
16709 else
16710   echo "$as_me: program exited with status $ac_status" >&5
16711 echo "$as_me: failed program was:" >&5
16712 sed 's/^/| /' conftest.$ac_ext >&5
16713
16714 ( exit $ac_status )
16715 ol_cv_c_posix_regex=no
16716 fi
16717 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16718 fi
16719 fi
16720 echo "$as_me:$LINENO: result: $ol_cv_c_posix_regex" >&5
16721 echo "${ECHO_T}$ol_cv_c_posix_regex" >&6
16722
16723 if test "$ol_cv_c_posix_regex" = no ; then
16724         { { echo "$as_me:$LINENO: error: broken POSIX regex!" >&5
16725 echo "$as_me: error: broken POSIX regex!" >&2;}
16726    { (exit 1); exit 1; }; }
16727 fi
16728
16729
16730 have_uuid=no
16731
16732 for ac_header in sys/uuid.h
16733 do
16734 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16735 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16736   echo "$as_me:$LINENO: checking for $ac_header" >&5
16737 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16738 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16739   echo $ECHO_N "(cached) $ECHO_C" >&6
16740 fi
16741 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16742 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16743 else
16744   # Is the header compilable?
16745 echo "$as_me:$LINENO: checking $ac_header usability" >&5
16746 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16747 cat >conftest.$ac_ext <<_ACEOF
16748 /* confdefs.h.  */
16749 _ACEOF
16750 cat confdefs.h >>conftest.$ac_ext
16751 cat >>conftest.$ac_ext <<_ACEOF
16752 /* end confdefs.h.  */
16753 $ac_includes_default
16754 #include <$ac_header>
16755 _ACEOF
16756 rm -f conftest.$ac_objext
16757 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16758   (eval $ac_compile) 2>conftest.er1
16759   ac_status=$?
16760   grep -v '^ *+' conftest.er1 >conftest.err
16761   rm -f conftest.er1
16762   cat conftest.err >&5
16763   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16764   (exit $ac_status); } &&
16765          { ac_try='test -z "$ac_c_werror_flag"
16766                          || test ! -s conftest.err'
16767   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16768   (eval $ac_try) 2>&5
16769   ac_status=$?
16770   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16771   (exit $ac_status); }; } &&
16772          { ac_try='test -s conftest.$ac_objext'
16773   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16774   (eval $ac_try) 2>&5
16775   ac_status=$?
16776   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16777   (exit $ac_status); }; }; then
16778   ac_header_compiler=yes
16779 else
16780   echo "$as_me: failed program was:" >&5
16781 sed 's/^/| /' conftest.$ac_ext >&5
16782
16783 ac_header_compiler=no
16784 fi
16785 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16786 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16787 echo "${ECHO_T}$ac_header_compiler" >&6
16788
16789 # Is the header present?
16790 echo "$as_me:$LINENO: checking $ac_header presence" >&5
16791 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
16792 cat >conftest.$ac_ext <<_ACEOF
16793 /* confdefs.h.  */
16794 _ACEOF
16795 cat confdefs.h >>conftest.$ac_ext
16796 cat >>conftest.$ac_ext <<_ACEOF
16797 /* end confdefs.h.  */
16798 #include <$ac_header>
16799 _ACEOF
16800 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
16801   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16802   ac_status=$?
16803   grep -v '^ *+' conftest.er1 >conftest.err
16804   rm -f conftest.er1
16805   cat conftest.err >&5
16806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16807   (exit $ac_status); } >/dev/null; then
16808   if test -s conftest.err; then
16809     ac_cpp_err=$ac_c_preproc_warn_flag
16810     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
16811   else
16812     ac_cpp_err=
16813   fi
16814 else
16815   ac_cpp_err=yes
16816 fi
16817 if test -z "$ac_cpp_err"; then
16818   ac_header_preproc=yes
16819 else
16820   echo "$as_me: failed program was:" >&5
16821 sed 's/^/| /' conftest.$ac_ext >&5
16822
16823   ac_header_preproc=no
16824 fi
16825 rm -f conftest.err conftest.$ac_ext
16826 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16827 echo "${ECHO_T}$ac_header_preproc" >&6
16828
16829 # So?  What about this header?
16830 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16831   yes:no: )
16832     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
16833 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
16834     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
16835 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
16836     ac_header_preproc=yes
16837     ;;
16838   no:yes:* )
16839     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
16840 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
16841     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
16842 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
16843     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
16844 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
16845     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
16846 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
16847     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
16848 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16849     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
16850 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
16851     (
16852       cat <<\_ASBOX
16853 ## --------------------------------------------- ##
16854 ## Report this to <http://www.openldap.org/its/> ##
16855 ## --------------------------------------------- ##
16856 _ASBOX
16857     ) |
16858       sed "s/^/$as_me: WARNING:     /" >&2
16859     ;;
16860 esac
16861 echo "$as_me:$LINENO: checking for $ac_header" >&5
16862 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16863 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16864   echo $ECHO_N "(cached) $ECHO_C" >&6
16865 else
16866   eval "$as_ac_Header=\$ac_header_preproc"
16867 fi
16868 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16869 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16870
16871 fi
16872 if test `eval echo '${'$as_ac_Header'}'` = yes; then
16873   cat >>confdefs.h <<_ACEOF
16874 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16875 _ACEOF
16876
16877 fi
16878
16879 done
16880
16881 if test $ac_cv_header_sys_uuid_h = yes ; then
16882         save_LIBS="$LIBS"
16883         echo "$as_me:$LINENO: checking for library containing uuid_to_str" >&5
16884 echo $ECHO_N "checking for library containing uuid_to_str... $ECHO_C" >&6
16885 if test "${ac_cv_search_uuid_to_str+set}" = set; then
16886   echo $ECHO_N "(cached) $ECHO_C" >&6
16887 else
16888   ac_func_search_save_LIBS=$LIBS
16889 ac_cv_search_uuid_to_str=no
16890 cat >conftest.$ac_ext <<_ACEOF
16891 /* confdefs.h.  */
16892 _ACEOF
16893 cat confdefs.h >>conftest.$ac_ext
16894 cat >>conftest.$ac_ext <<_ACEOF
16895 /* end confdefs.h.  */
16896
16897 /* Override any gcc2 internal prototype to avoid an error.  */
16898 #ifdef __cplusplus
16899 extern "C"
16900 #endif
16901 /* We use char because int might match the return type of a gcc2
16902    builtin and then its argument prototype would still apply.  */
16903 char uuid_to_str ();
16904 int
16905 main ()
16906 {
16907 uuid_to_str ();
16908   ;
16909   return 0;
16910 }
16911 _ACEOF
16912 rm -f conftest.$ac_objext conftest$ac_exeext
16913 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16914   (eval $ac_link) 2>conftest.er1
16915   ac_status=$?
16916   grep -v '^ *+' conftest.er1 >conftest.err
16917   rm -f conftest.er1
16918   cat conftest.err >&5
16919   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16920   (exit $ac_status); } &&
16921          { ac_try='test -z "$ac_c_werror_flag"
16922                          || test ! -s conftest.err'
16923   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16924   (eval $ac_try) 2>&5
16925   ac_status=$?
16926   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16927   (exit $ac_status); }; } &&
16928          { ac_try='test -s conftest$ac_exeext'
16929   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16930   (eval $ac_try) 2>&5
16931   ac_status=$?
16932   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16933   (exit $ac_status); }; }; then
16934   ac_cv_search_uuid_to_str="none required"
16935 else
16936   echo "$as_me: failed program was:" >&5
16937 sed 's/^/| /' conftest.$ac_ext >&5
16938
16939 fi
16940 rm -f conftest.err conftest.$ac_objext \
16941       conftest$ac_exeext conftest.$ac_ext
16942 if test "$ac_cv_search_uuid_to_str" = no; then
16943   for ac_lib in uuid; do
16944     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
16945     cat >conftest.$ac_ext <<_ACEOF
16946 /* confdefs.h.  */
16947 _ACEOF
16948 cat confdefs.h >>conftest.$ac_ext
16949 cat >>conftest.$ac_ext <<_ACEOF
16950 /* end confdefs.h.  */
16951
16952 /* Override any gcc2 internal prototype to avoid an error.  */
16953 #ifdef __cplusplus
16954 extern "C"
16955 #endif
16956 /* We use char because int might match the return type of a gcc2
16957    builtin and then its argument prototype would still apply.  */
16958 char uuid_to_str ();
16959 int
16960 main ()
16961 {
16962 uuid_to_str ();
16963   ;
16964   return 0;
16965 }
16966 _ACEOF
16967 rm -f conftest.$ac_objext conftest$ac_exeext
16968 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16969   (eval $ac_link) 2>conftest.er1
16970   ac_status=$?
16971   grep -v '^ *+' conftest.er1 >conftest.err
16972   rm -f conftest.er1
16973   cat conftest.err >&5
16974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16975   (exit $ac_status); } &&
16976          { ac_try='test -z "$ac_c_werror_flag"
16977                          || test ! -s conftest.err'
16978   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16979   (eval $ac_try) 2>&5
16980   ac_status=$?
16981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16982   (exit $ac_status); }; } &&
16983          { ac_try='test -s conftest$ac_exeext'
16984   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16985   (eval $ac_try) 2>&5
16986   ac_status=$?
16987   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16988   (exit $ac_status); }; }; then
16989   ac_cv_search_uuid_to_str="-l$ac_lib"
16990 break
16991 else
16992   echo "$as_me: failed program was:" >&5
16993 sed 's/^/| /' conftest.$ac_ext >&5
16994
16995 fi
16996 rm -f conftest.err conftest.$ac_objext \
16997       conftest$ac_exeext conftest.$ac_ext
16998   done
16999 fi
17000 LIBS=$ac_func_search_save_LIBS
17001 fi
17002 echo "$as_me:$LINENO: result: $ac_cv_search_uuid_to_str" >&5
17003 echo "${ECHO_T}$ac_cv_search_uuid_to_str" >&6
17004 if test "$ac_cv_search_uuid_to_str" != no; then
17005   test "$ac_cv_search_uuid_to_str" = "none required" || LIBS="$ac_cv_search_uuid_to_str $LIBS"
17006   have_uuid=yes
17007 else
17008   :
17009 fi
17010
17011         LIBS="$save_LIBS"
17012
17013         if test have_uuid = yes ; then
17014
17015 cat >>confdefs.h <<\_ACEOF
17016 #define HAVE_UUID_TO_STR 1
17017 _ACEOF
17018
17019
17020                 test "$ac_cv_search_uuid_to_str" = "none required" || \
17021                         SLAPD_LIBS="$SLAPD_LIBS $ac_cv_search_uuid_to_str"
17022         fi
17023 fi
17024
17025 if test $have_uuid = no ; then
17026         echo "$as_me:$LINENO: checking to see if -lrpcrt4 is needed for win32 UUID support" >&5
17027 echo $ECHO_N "checking to see if -lrpcrt4 is needed for win32 UUID support... $ECHO_C" >&6
17028         save_LIBS="$LIBS"
17029         LIBS="$LIBS -lrpcrt4"
17030         cat >conftest.$ac_ext <<_ACEOF
17031 /* confdefs.h.  */
17032 _ACEOF
17033 cat confdefs.h >>conftest.$ac_ext
17034 cat >>conftest.$ac_ext <<_ACEOF
17035 /* end confdefs.h.  */
17036
17037                 int __stdcall UuidCreate(void *);
17038                 int __stdcall UuidToStringA(void *,void **);
17039
17040 int
17041 main ()
17042 {
17043
17044                 UuidCreate(0);
17045                 UuidToStringA(0,0);
17046
17047   ;
17048   return 0;
17049 }
17050 _ACEOF
17051 rm -f conftest.$ac_objext conftest$ac_exeext
17052 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17053   (eval $ac_link) 2>conftest.er1
17054   ac_status=$?
17055   grep -v '^ *+' conftest.er1 >conftest.err
17056   rm -f conftest.er1
17057   cat conftest.err >&5
17058   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17059   (exit $ac_status); } &&
17060          { ac_try='test -z "$ac_c_werror_flag"
17061                          || test ! -s conftest.err'
17062   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17063   (eval $ac_try) 2>&5
17064   ac_status=$?
17065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17066   (exit $ac_status); }; } &&
17067          { ac_try='test -s conftest$ac_exeext'
17068   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17069   (eval $ac_try) 2>&5
17070   ac_status=$?
17071   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17072   (exit $ac_status); }; }; then
17073   need_rpcrt=yes
17074 else
17075   echo "$as_me: failed program was:" >&5
17076 sed 's/^/| /' conftest.$ac_ext >&5
17077
17078 need_rpcrt=no
17079 fi
17080 rm -f conftest.err conftest.$ac_objext \
17081       conftest$ac_exeext conftest.$ac_ext
17082         if test $need_rpcrt = yes; then
17083                 SLAPD_LIBS="$SLAPD_LIBS -lrpcrt4"
17084         fi
17085         LIBS="$save_LIBS"
17086         echo "$as_me:$LINENO: result: $need_rpcrt" >&5
17087 echo "${ECHO_T}$need_rpcrt" >&6
17088 fi
17089
17090 ol_cv_lib_resolver=no
17091 if test $ol_cv_lib_resolver = no ; then
17092         echo "$as_me:$LINENO: checking for resolver link (default)" >&5
17093 echo $ECHO_N "checking for resolver link (default)... $ECHO_C" >&6
17094 if test "${ol_cv_resolver_none+set}" = set; then
17095   echo $ECHO_N "(cached) $ECHO_C" >&6
17096 else
17097
17098         ol_RESOLVER_LIB=
17099         ol_LIBS=$LIBS
17100         LIBS="$ol_RESOLVER_LIB $LIBS"
17101
17102         cat >conftest.$ac_ext <<_ACEOF
17103 /* confdefs.h.  */
17104 _ACEOF
17105 cat confdefs.h >>conftest.$ac_ext
17106 cat >>conftest.$ac_ext <<_ACEOF
17107 /* end confdefs.h.  */
17108
17109 #ifdef HAVE_SYS_TYPES_H
17110 #       include <sys/types.h>
17111 #endif
17112 #include <netinet/in.h>
17113 #ifdef HAVE_ARPA_NAMESER_H
17114 #       include <arpa/nameser.h>
17115 #endif
17116 #ifdef HAVE_RESOLV_H
17117 #       include <resolv.h>
17118 #endif
17119
17120 int
17121 main ()
17122 {
17123 {
17124         int len, status;
17125         char *request = NULL;
17126         unsigned char reply[64*1024];
17127         unsigned char host[64*1024];
17128         unsigned char *p;
17129
17130 #ifdef NS_HFIXEDSZ
17131         /* Bind 8/9 interface */
17132         len = res_query(request, ns_c_in, ns_t_srv, reply, sizeof(reply));
17133 #else
17134         /* Bind 4 interface */
17135 # ifndef T_SRV
17136 #  define T_SRV 33
17137 # endif
17138         len = res_query(request, C_IN, T_SRV, reply, sizeof(reply));
17139 #endif
17140         p = reply;
17141 #ifdef NS_HFIXEDSZ
17142         /* Bind 8/9 interface */
17143         p += NS_HFIXEDSZ;
17144 #elif defined(HFIXEDSZ)
17145         /* Bind 4 interface w/ HFIXEDSZ */
17146         p += HFIXEDSZ;
17147 #else
17148         /* Bind 4 interface w/o HFIXEDSZ */
17149         p += sizeof(HEADER);
17150 #endif
17151         status = dn_expand( reply, reply+len, p, host, sizeof(host));
17152 }
17153   ;
17154   return 0;
17155 }
17156 _ACEOF
17157 rm -f conftest.$ac_objext conftest$ac_exeext
17158 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17159   (eval $ac_link) 2>conftest.er1
17160   ac_status=$?
17161   grep -v '^ *+' conftest.er1 >conftest.err
17162   rm -f conftest.er1
17163   cat conftest.err >&5
17164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17165   (exit $ac_status); } &&
17166          { ac_try='test -z "$ac_c_werror_flag"
17167                          || test ! -s conftest.err'
17168   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17169   (eval $ac_try) 2>&5
17170   ac_status=$?
17171   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17172   (exit $ac_status); }; } &&
17173          { ac_try='test -s conftest$ac_exeext'
17174   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17175   (eval $ac_try) 2>&5
17176   ac_status=$?
17177   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17178   (exit $ac_status); }; }; then
17179   ol_cv_resolver_none=yes
17180 else
17181   echo "$as_me: failed program was:" >&5
17182 sed 's/^/| /' conftest.$ac_ext >&5
17183
17184 ol_cv_resolver_none=no
17185 fi
17186 rm -f conftest.err conftest.$ac_objext \
17187       conftest$ac_exeext conftest.$ac_ext
17188
17189         LIBS="$ol_LIBS"
17190
17191 fi
17192 echo "$as_me:$LINENO: result: $ol_cv_resolver_none" >&5
17193 echo "${ECHO_T}$ol_cv_resolver_none" >&6
17194
17195         if test $ol_cv_resolver_none = yes ; then
17196                 ol_cv_lib_resolver=yes
17197         fi
17198 fi
17199
17200 if test $ol_cv_lib_resolver = no ; then
17201         echo "$as_me:$LINENO: checking for resolver link (-lresolv)" >&5
17202 echo $ECHO_N "checking for resolver link (-lresolv)... $ECHO_C" >&6
17203 if test "${ol_cv_resolver_resolv+set}" = set; then
17204   echo $ECHO_N "(cached) $ECHO_C" >&6
17205 else
17206
17207         ol_RESOLVER_LIB=-lresolv
17208         ol_LIBS=$LIBS
17209         LIBS="$ol_RESOLVER_LIB $LIBS"
17210
17211         cat >conftest.$ac_ext <<_ACEOF
17212 /* confdefs.h.  */
17213 _ACEOF
17214 cat confdefs.h >>conftest.$ac_ext
17215 cat >>conftest.$ac_ext <<_ACEOF
17216 /* end confdefs.h.  */
17217
17218 #ifdef HAVE_SYS_TYPES_H
17219 #       include <sys/types.h>
17220 #endif
17221 #include <netinet/in.h>
17222 #ifdef HAVE_ARPA_NAMESER_H
17223 #       include <arpa/nameser.h>
17224 #endif
17225 #ifdef HAVE_RESOLV_H
17226 #       include <resolv.h>
17227 #endif
17228
17229 int
17230 main ()
17231 {
17232 {
17233         int len, status;
17234         char *request = NULL;
17235         unsigned char reply[64*1024];
17236         unsigned char host[64*1024];
17237         unsigned char *p;
17238
17239 #ifdef NS_HFIXEDSZ
17240         /* Bind 8/9 interface */
17241         len = res_query(request, ns_c_in, ns_t_srv, reply, sizeof(reply));
17242 #else
17243         /* Bind 4 interface */
17244 # ifndef T_SRV
17245 #  define T_SRV 33
17246 # endif
17247         len = res_query(request, C_IN, T_SRV, reply, sizeof(reply));
17248 #endif
17249         p = reply;
17250 #ifdef NS_HFIXEDSZ
17251         /* Bind 8/9 interface */
17252         p += NS_HFIXEDSZ;
17253 #elif defined(HFIXEDSZ)
17254         /* Bind 4 interface w/ HFIXEDSZ */
17255         p += HFIXEDSZ;
17256 #else
17257         /* Bind 4 interface w/o HFIXEDSZ */
17258         p += sizeof(HEADER);
17259 #endif
17260         status = dn_expand( reply, reply+len, p, host, sizeof(host));
17261 }
17262   ;
17263   return 0;
17264 }
17265 _ACEOF
17266 rm -f conftest.$ac_objext conftest$ac_exeext
17267 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17268   (eval $ac_link) 2>conftest.er1
17269   ac_status=$?
17270   grep -v '^ *+' conftest.er1 >conftest.err
17271   rm -f conftest.er1
17272   cat conftest.err >&5
17273   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17274   (exit $ac_status); } &&
17275          { ac_try='test -z "$ac_c_werror_flag"
17276                          || test ! -s conftest.err'
17277   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17278   (eval $ac_try) 2>&5
17279   ac_status=$?
17280   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17281   (exit $ac_status); }; } &&
17282          { ac_try='test -s conftest$ac_exeext'
17283   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17284   (eval $ac_try) 2>&5
17285   ac_status=$?
17286   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17287   (exit $ac_status); }; }; then
17288   ol_cv_resolver_resolv=yes
17289 else
17290   echo "$as_me: failed program was:" >&5
17291 sed 's/^/| /' conftest.$ac_ext >&5
17292
17293 ol_cv_resolver_resolv=no
17294 fi
17295 rm -f conftest.err conftest.$ac_objext \
17296       conftest$ac_exeext conftest.$ac_ext
17297
17298         LIBS="$ol_LIBS"
17299
17300 fi
17301 echo "$as_me:$LINENO: result: $ol_cv_resolver_resolv" >&5
17302 echo "${ECHO_T}$ol_cv_resolver_resolv" >&6
17303
17304         if test $ol_cv_resolver_resolv = yes ; then
17305                 ol_cv_lib_resolver=-lresolv
17306         fi
17307 fi
17308
17309 if test $ol_cv_lib_resolver = no ; then
17310         echo "$as_me:$LINENO: checking for resolver link (-lbind)" >&5
17311 echo $ECHO_N "checking for resolver link (-lbind)... $ECHO_C" >&6
17312 if test "${ol_cv_resolver_bind+set}" = set; then
17313   echo $ECHO_N "(cached) $ECHO_C" >&6
17314 else
17315
17316         ol_RESOLVER_LIB=-lbind
17317         ol_LIBS=$LIBS
17318         LIBS="$ol_RESOLVER_LIB $LIBS"
17319
17320         cat >conftest.$ac_ext <<_ACEOF
17321 /* confdefs.h.  */
17322 _ACEOF
17323 cat confdefs.h >>conftest.$ac_ext
17324 cat >>conftest.$ac_ext <<_ACEOF
17325 /* end confdefs.h.  */
17326
17327 #ifdef HAVE_SYS_TYPES_H
17328 #       include <sys/types.h>
17329 #endif
17330 #include <netinet/in.h>
17331 #ifdef HAVE_ARPA_NAMESER_H
17332 #       include <arpa/nameser.h>
17333 #endif
17334 #ifdef HAVE_RESOLV_H
17335 #       include <resolv.h>
17336 #endif
17337
17338 int
17339 main ()
17340 {
17341 {
17342         int len, status;
17343         char *request = NULL;
17344         unsigned char reply[64*1024];
17345         unsigned char host[64*1024];
17346         unsigned char *p;
17347
17348 #ifdef NS_HFIXEDSZ
17349         /* Bind 8/9 interface */
17350         len = res_query(request, ns_c_in, ns_t_srv, reply, sizeof(reply));
17351 #else
17352         /* Bind 4 interface */
17353 # ifndef T_SRV
17354 #  define T_SRV 33
17355 # endif
17356         len = res_query(request, C_IN, T_SRV, reply, sizeof(reply));
17357 #endif
17358         p = reply;
17359 #ifdef NS_HFIXEDSZ
17360         /* Bind 8/9 interface */
17361         p += NS_HFIXEDSZ;
17362 #elif defined(HFIXEDSZ)
17363         /* Bind 4 interface w/ HFIXEDSZ */
17364         p += HFIXEDSZ;
17365 #else
17366         /* Bind 4 interface w/o HFIXEDSZ */
17367         p += sizeof(HEADER);
17368 #endif
17369         status = dn_expand( reply, reply+len, p, host, sizeof(host));
17370 }
17371   ;
17372   return 0;
17373 }
17374 _ACEOF
17375 rm -f conftest.$ac_objext conftest$ac_exeext
17376 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17377   (eval $ac_link) 2>conftest.er1
17378   ac_status=$?
17379   grep -v '^ *+' conftest.er1 >conftest.err
17380   rm -f conftest.er1
17381   cat conftest.err >&5
17382   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17383   (exit $ac_status); } &&
17384          { ac_try='test -z "$ac_c_werror_flag"
17385                          || test ! -s conftest.err'
17386   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17387   (eval $ac_try) 2>&5
17388   ac_status=$?
17389   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17390   (exit $ac_status); }; } &&
17391          { ac_try='test -s conftest$ac_exeext'
17392   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17393   (eval $ac_try) 2>&5
17394   ac_status=$?
17395   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17396   (exit $ac_status); }; }; then
17397   ol_cv_resolver_bind=yes
17398 else
17399   echo "$as_me: failed program was:" >&5
17400 sed 's/^/| /' conftest.$ac_ext >&5
17401
17402 ol_cv_resolver_bind=no
17403 fi
17404 rm -f conftest.err conftest.$ac_objext \
17405       conftest$ac_exeext conftest.$ac_ext
17406
17407         LIBS="$ol_LIBS"
17408
17409 fi
17410 echo "$as_me:$LINENO: result: $ol_cv_resolver_bind" >&5
17411 echo "${ECHO_T}$ol_cv_resolver_bind" >&6
17412
17413         if test $ol_cv_resolver_bind = yes ; then
17414                 ol_cv_lib_resolver=-lbind
17415         fi
17416 fi
17417
17418
17419
17420 ol_link_dnssrv=no
17421 if test "$ol_cv_lib_resolver" != no ; then
17422
17423 cat >>confdefs.h <<\_ACEOF
17424 #define HAVE_RES_QUERY 1
17425 _ACEOF
17426
17427
17428         if test "$ol_enable_dnssrv" != no ; then
17429                 ol_link_dnssrv=yes
17430         fi
17431
17432         if test "$ol_cv_lib_resolver" != yes ; then
17433                 LIBS="$ol_cv_lib_resolver $LIBS"
17434         fi
17435 fi
17436
17437 if test "$ol_enable_dnssrv" = yes || test "$ol_enable_dnssrv" = mod ; then
17438         if test "$ol_link_dnssrv" = no ; then
17439                 { { echo "$as_me:$LINENO: error: DNSSRV requires res_query()" >&5
17440 echo "$as_me: error: DNSSRV requires res_query()" >&2;}
17441    { (exit 1); exit 1; }; }
17442         fi
17443 else
17444         ol_enable_dnssrv=no
17445 fi
17446
17447
17448 for ac_func in hstrerror
17449 do
17450 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17451 echo "$as_me:$LINENO: checking for $ac_func" >&5
17452 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17453 if eval "test \"\${$as_ac_var+set}\" = set"; then
17454   echo $ECHO_N "(cached) $ECHO_C" >&6
17455 else
17456   cat >conftest.$ac_ext <<_ACEOF
17457 /* confdefs.h.  */
17458 _ACEOF
17459 cat confdefs.h >>conftest.$ac_ext
17460 cat >>conftest.$ac_ext <<_ACEOF
17461 /* end confdefs.h.  */
17462 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17463    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17464 #define $ac_func innocuous_$ac_func
17465
17466 /* System header to define __stub macros and hopefully few prototypes,
17467     which can conflict with char $ac_func (); below.
17468     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17469     <limits.h> exists even on freestanding compilers.  */
17470
17471 #ifdef __STDC__
17472 # include <limits.h>
17473 #else
17474 # include <assert.h>
17475 #endif
17476
17477 #undef $ac_func
17478
17479 /* Override any gcc2 internal prototype to avoid an error.  */
17480 #ifdef __cplusplus
17481 extern "C"
17482 {
17483 #endif
17484 /* We use char because int might match the return type of a gcc2
17485    builtin and then its argument prototype would still apply.  */
17486 char $ac_func ();
17487 /* The GNU C library defines this for functions which it implements
17488     to always fail with ENOSYS.  Some functions are actually named
17489     something starting with __ and the normal name is an alias.  */
17490 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17491 choke me
17492 #else
17493 char (*f) () = $ac_func;
17494 #endif
17495 #ifdef __cplusplus
17496 }
17497 #endif
17498
17499 int
17500 main ()
17501 {
17502 return f != $ac_func;
17503   ;
17504   return 0;
17505 }
17506 _ACEOF
17507 rm -f conftest.$ac_objext conftest$ac_exeext
17508 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17509   (eval $ac_link) 2>conftest.er1
17510   ac_status=$?
17511   grep -v '^ *+' conftest.er1 >conftest.err
17512   rm -f conftest.er1
17513   cat conftest.err >&5
17514   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17515   (exit $ac_status); } &&
17516          { ac_try='test -z "$ac_c_werror_flag"
17517                          || test ! -s conftest.err'
17518   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17519   (eval $ac_try) 2>&5
17520   ac_status=$?
17521   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17522   (exit $ac_status); }; } &&
17523          { ac_try='test -s conftest$ac_exeext'
17524   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17525   (eval $ac_try) 2>&5
17526   ac_status=$?
17527   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17528   (exit $ac_status); }; }; then
17529   eval "$as_ac_var=yes"
17530 else
17531   echo "$as_me: failed program was:" >&5
17532 sed 's/^/| /' conftest.$ac_ext >&5
17533
17534 eval "$as_ac_var=no"
17535 fi
17536 rm -f conftest.err conftest.$ac_objext \
17537       conftest$ac_exeext conftest.$ac_ext
17538 fi
17539 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
17540 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17541 if test `eval echo '${'$as_ac_var'}'` = yes; then
17542   cat >>confdefs.h <<_ACEOF
17543 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17544 _ACEOF
17545
17546 fi
17547 done
17548
17549
17550
17551
17552
17553
17554 for ac_func in getaddrinfo getnameinfo gai_strerror inet_ntop
17555 do
17556 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17557 echo "$as_me:$LINENO: checking for $ac_func" >&5
17558 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17559 if eval "test \"\${$as_ac_var+set}\" = set"; then
17560   echo $ECHO_N "(cached) $ECHO_C" >&6
17561 else
17562   cat >conftest.$ac_ext <<_ACEOF
17563 /* confdefs.h.  */
17564 _ACEOF
17565 cat confdefs.h >>conftest.$ac_ext
17566 cat >>conftest.$ac_ext <<_ACEOF
17567 /* end confdefs.h.  */
17568 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17569    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17570 #define $ac_func innocuous_$ac_func
17571
17572 /* System header to define __stub macros and hopefully few prototypes,
17573     which can conflict with char $ac_func (); below.
17574     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17575     <limits.h> exists even on freestanding compilers.  */
17576
17577 #ifdef __STDC__
17578 # include <limits.h>
17579 #else
17580 # include <assert.h>
17581 #endif
17582
17583 #undef $ac_func
17584
17585 /* Override any gcc2 internal prototype to avoid an error.  */
17586 #ifdef __cplusplus
17587 extern "C"
17588 {
17589 #endif
17590 /* We use char because int might match the return type of a gcc2
17591    builtin and then its argument prototype would still apply.  */
17592 char $ac_func ();
17593 /* The GNU C library defines this for functions which it implements
17594     to always fail with ENOSYS.  Some functions are actually named
17595     something starting with __ and the normal name is an alias.  */
17596 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17597 choke me
17598 #else
17599 char (*f) () = $ac_func;
17600 #endif
17601 #ifdef __cplusplus
17602 }
17603 #endif
17604
17605 int
17606 main ()
17607 {
17608 return f != $ac_func;
17609   ;
17610   return 0;
17611 }
17612 _ACEOF
17613 rm -f conftest.$ac_objext conftest$ac_exeext
17614 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17615   (eval $ac_link) 2>conftest.er1
17616   ac_status=$?
17617   grep -v '^ *+' conftest.er1 >conftest.err
17618   rm -f conftest.er1
17619   cat conftest.err >&5
17620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17621   (exit $ac_status); } &&
17622          { ac_try='test -z "$ac_c_werror_flag"
17623                          || test ! -s conftest.err'
17624   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17625   (eval $ac_try) 2>&5
17626   ac_status=$?
17627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17628   (exit $ac_status); }; } &&
17629          { ac_try='test -s conftest$ac_exeext'
17630   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17631   (eval $ac_try) 2>&5
17632   ac_status=$?
17633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17634   (exit $ac_status); }; }; then
17635   eval "$as_ac_var=yes"
17636 else
17637   echo "$as_me: failed program was:" >&5
17638 sed 's/^/| /' conftest.$ac_ext >&5
17639
17640 eval "$as_ac_var=no"
17641 fi
17642 rm -f conftest.err conftest.$ac_objext \
17643       conftest$ac_exeext conftest.$ac_ext
17644 fi
17645 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
17646 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17647 if test `eval echo '${'$as_ac_var'}'` = yes; then
17648   cat >>confdefs.h <<_ACEOF
17649 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17650 _ACEOF
17651
17652 fi
17653 done
17654
17655
17656 ol_link_ipv6=no
17657 if test $ac_cv_func_getaddrinfo = no || test $ac_cv_func_inet_ntop = no ; then
17658         if test $ol_enable_ipv6 = yes ; then
17659                 { { echo "$as_me:$LINENO: error: IPv6 support requires getaddrinfo() and inet_ntop()" >&5
17660 echo "$as_me: error: IPv6 support requires getaddrinfo() and inet_ntop()" >&2;}
17661    { (exit 1); exit 1; }; }
17662         fi
17663 elif test $ol_enable_ipv6 != no ; then
17664         echo "$as_me:$LINENO: checking INET6_ADDRSTRLEN" >&5
17665 echo $ECHO_N "checking INET6_ADDRSTRLEN... $ECHO_C" >&6
17666 if test "${ol_cv_inet6_addrstrlen+set}" = set; then
17667   echo $ECHO_N "(cached) $ECHO_C" >&6
17668 else
17669
17670                 cat >conftest.$ac_ext <<_ACEOF
17671 /* confdefs.h.  */
17672 _ACEOF
17673 cat confdefs.h >>conftest.$ac_ext
17674 cat >>conftest.$ac_ext <<_ACEOF
17675 /* end confdefs.h.  */
17676
17677 #                       include <netinet/in.h>
17678 #                       ifdef INET6_ADDRSTRLEN
17679                                 __has_inet6_addrstrlen__;
17680 #                       endif
17681
17682 _ACEOF
17683 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17684   $EGREP "__has_inet6_addrstrlen__" >/dev/null 2>&1; then
17685   ol_cv_inet6_addrstrlen=yes
17686 else
17687   ol_cv_inet6_addrstrlen=no
17688 fi
17689 rm -f conftest*
17690
17691 fi
17692 echo "$as_me:$LINENO: result: $ol_cv_inet6_addrstrlen" >&5
17693 echo "${ECHO_T}$ol_cv_inet6_addrstrlen" >&6
17694
17695
17696         echo "$as_me:$LINENO: checking struct sockaddr_storage" >&5
17697 echo $ECHO_N "checking struct sockaddr_storage... $ECHO_C" >&6
17698 if test "${ol_cv_struct_sockaddr_storage+set}" = set; then
17699   echo $ECHO_N "(cached) $ECHO_C" >&6
17700 else
17701
17702                 cat >conftest.$ac_ext <<_ACEOF
17703 /* confdefs.h.  */
17704 _ACEOF
17705 cat confdefs.h >>conftest.$ac_ext
17706 cat >>conftest.$ac_ext <<_ACEOF
17707 /* end confdefs.h.  */
17708
17709 #include <sys/types.h>
17710 #include <sys/socket.h>
17711
17712 int
17713 main ()
17714 {
17715
17716                         struct sockaddr_storage ss;
17717
17718   ;
17719   return 0;
17720 }
17721 _ACEOF
17722 rm -f conftest.$ac_objext
17723 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17724   (eval $ac_compile) 2>conftest.er1
17725   ac_status=$?
17726   grep -v '^ *+' conftest.er1 >conftest.err
17727   rm -f conftest.er1
17728   cat conftest.err >&5
17729   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17730   (exit $ac_status); } &&
17731          { ac_try='test -z "$ac_c_werror_flag"
17732                          || test ! -s conftest.err'
17733   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17734   (eval $ac_try) 2>&5
17735   ac_status=$?
17736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17737   (exit $ac_status); }; } &&
17738          { ac_try='test -s conftest.$ac_objext'
17739   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17740   (eval $ac_try) 2>&5
17741   ac_status=$?
17742   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17743   (exit $ac_status); }; }; then
17744   ol_cv_struct_sockaddr_storage=yes
17745 else
17746   echo "$as_me: failed program was:" >&5
17747 sed 's/^/| /' conftest.$ac_ext >&5
17748
17749 ol_cv_struct_sockaddr_storage=no
17750 fi
17751 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17752 fi
17753 echo "$as_me:$LINENO: result: $ol_cv_struct_sockaddr_storage" >&5
17754 echo "${ECHO_T}$ol_cv_struct_sockaddr_storage" >&6
17755
17756         if test $ol_cv_inet6_addrstrlen = yes &&
17757            test $ol_cv_struct_sockaddr_storage = yes ; then
17758                 ol_link_ipv6=yes
17759         elif test $ol_enable_ipv6 = yes &&
17760              test $ol_cv_inet6_addrstrlen = no ; then
17761                 { { echo "$as_me:$LINENO: error: IPv6 support requires INET6_ADDRSTRLEN" >&5
17762 echo "$as_me: error: IPv6 support requires INET6_ADDRSTRLEN" >&2;}
17763    { (exit 1); exit 1; }; }
17764         elif test $ol_enable_ipv6 = yes &&
17765              test $ol_cv_struct_sockaddr_storage = no ; then
17766                 { { echo "$as_me:$LINENO: error: IPv6 support requires struct sockaddr_storage" >&5
17767 echo "$as_me: error: IPv6 support requires struct sockaddr_storage" >&2;}
17768    { (exit 1); exit 1; }; }
17769         fi
17770 fi
17771
17772 if test $ol_enable_local != no ; then
17773
17774 for ac_header in sys/un.h
17775 do
17776 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17777 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17778   echo "$as_me:$LINENO: checking for $ac_header" >&5
17779 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17780 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17781   echo $ECHO_N "(cached) $ECHO_C" >&6
17782 fi
17783 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17784 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17785 else
17786   # Is the header compilable?
17787 echo "$as_me:$LINENO: checking $ac_header usability" >&5
17788 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17789 cat >conftest.$ac_ext <<_ACEOF
17790 /* confdefs.h.  */
17791 _ACEOF
17792 cat confdefs.h >>conftest.$ac_ext
17793 cat >>conftest.$ac_ext <<_ACEOF
17794 /* end confdefs.h.  */
17795 $ac_includes_default
17796 #include <$ac_header>
17797 _ACEOF
17798 rm -f conftest.$ac_objext
17799 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17800   (eval $ac_compile) 2>conftest.er1
17801   ac_status=$?
17802   grep -v '^ *+' conftest.er1 >conftest.err
17803   rm -f conftest.er1
17804   cat conftest.err >&5
17805   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17806   (exit $ac_status); } &&
17807          { ac_try='test -z "$ac_c_werror_flag"
17808                          || test ! -s conftest.err'
17809   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17810   (eval $ac_try) 2>&5
17811   ac_status=$?
17812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17813   (exit $ac_status); }; } &&
17814          { ac_try='test -s conftest.$ac_objext'
17815   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17816   (eval $ac_try) 2>&5
17817   ac_status=$?
17818   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17819   (exit $ac_status); }; }; then
17820   ac_header_compiler=yes
17821 else
17822   echo "$as_me: failed program was:" >&5
17823 sed 's/^/| /' conftest.$ac_ext >&5
17824
17825 ac_header_compiler=no
17826 fi
17827 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17828 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17829 echo "${ECHO_T}$ac_header_compiler" >&6
17830
17831 # Is the header present?
17832 echo "$as_me:$LINENO: checking $ac_header presence" >&5
17833 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17834 cat >conftest.$ac_ext <<_ACEOF
17835 /* confdefs.h.  */
17836 _ACEOF
17837 cat confdefs.h >>conftest.$ac_ext
17838 cat >>conftest.$ac_ext <<_ACEOF
17839 /* end confdefs.h.  */
17840 #include <$ac_header>
17841 _ACEOF
17842 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
17843   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17844   ac_status=$?
17845   grep -v '^ *+' conftest.er1 >conftest.err
17846   rm -f conftest.er1
17847   cat conftest.err >&5
17848   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17849   (exit $ac_status); } >/dev/null; then
17850   if test -s conftest.err; then
17851     ac_cpp_err=$ac_c_preproc_warn_flag
17852     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
17853   else
17854     ac_cpp_err=
17855   fi
17856 else
17857   ac_cpp_err=yes
17858 fi
17859 if test -z "$ac_cpp_err"; then
17860   ac_header_preproc=yes
17861 else
17862   echo "$as_me: failed program was:" >&5
17863 sed 's/^/| /' conftest.$ac_ext >&5
17864
17865   ac_header_preproc=no
17866 fi
17867 rm -f conftest.err conftest.$ac_ext
17868 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17869 echo "${ECHO_T}$ac_header_preproc" >&6
17870
17871 # So?  What about this header?
17872 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17873   yes:no: )
17874     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17875 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17876     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
17877 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
17878     ac_header_preproc=yes
17879     ;;
17880   no:yes:* )
17881     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17882 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17883     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
17884 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
17885     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
17886 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
17887     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
17888 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
17889     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17890 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17891     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
17892 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
17893     (
17894       cat <<\_ASBOX
17895 ## --------------------------------------------- ##
17896 ## Report this to <http://www.openldap.org/its/> ##
17897 ## --------------------------------------------- ##
17898 _ASBOX
17899     ) |
17900       sed "s/^/$as_me: WARNING:     /" >&2
17901     ;;
17902 esac
17903 echo "$as_me:$LINENO: checking for $ac_header" >&5
17904 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17905 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17906   echo $ECHO_N "(cached) $ECHO_C" >&6
17907 else
17908   eval "$as_ac_Header=\$ac_header_preproc"
17909 fi
17910 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17911 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17912
17913 fi
17914 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17915   cat >>confdefs.h <<_ACEOF
17916 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17917 _ACEOF
17918
17919 fi
17920
17921 done
17922
17923
17924         if test $ol_enable_local = auto ; then
17925                 ol_enable_local=$ac_cv_header_sys_un_h
17926         elif test $ac_cv_header_sys_un_h = no ; then
17927                 { { echo "$as_me:$LINENO: error: AF_LOCAL domain support requires sys/un.h" >&5
17928 echo "$as_me: error: AF_LOCAL domain support requires sys/un.h" >&2;}
17929    { (exit 1); exit 1; }; }
17930         fi
17931 fi
17932
17933 ol_link_kbind=no
17934 ol_link_krb5=no
17935 ol_link_krb4=no
17936
17937 case $ol_with_kerberos in yes | auto | k5 | k5only | k425)
17938
17939
17940 for ac_header in krb5.h
17941 do
17942 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17943 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17944   echo "$as_me:$LINENO: checking for $ac_header" >&5
17945 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17946 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17947   echo $ECHO_N "(cached) $ECHO_C" >&6
17948 fi
17949 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17950 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17951 else
17952   # Is the header compilable?
17953 echo "$as_me:$LINENO: checking $ac_header usability" >&5
17954 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17955 cat >conftest.$ac_ext <<_ACEOF
17956 /* confdefs.h.  */
17957 _ACEOF
17958 cat confdefs.h >>conftest.$ac_ext
17959 cat >>conftest.$ac_ext <<_ACEOF
17960 /* end confdefs.h.  */
17961 $ac_includes_default
17962 #include <$ac_header>
17963 _ACEOF
17964 rm -f conftest.$ac_objext
17965 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17966   (eval $ac_compile) 2>conftest.er1
17967   ac_status=$?
17968   grep -v '^ *+' conftest.er1 >conftest.err
17969   rm -f conftest.er1
17970   cat conftest.err >&5
17971   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17972   (exit $ac_status); } &&
17973          { ac_try='test -z "$ac_c_werror_flag"
17974                          || test ! -s conftest.err'
17975   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17976   (eval $ac_try) 2>&5
17977   ac_status=$?
17978   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17979   (exit $ac_status); }; } &&
17980          { ac_try='test -s conftest.$ac_objext'
17981   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17982   (eval $ac_try) 2>&5
17983   ac_status=$?
17984   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17985   (exit $ac_status); }; }; then
17986   ac_header_compiler=yes
17987 else
17988   echo "$as_me: failed program was:" >&5
17989 sed 's/^/| /' conftest.$ac_ext >&5
17990
17991 ac_header_compiler=no
17992 fi
17993 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17994 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17995 echo "${ECHO_T}$ac_header_compiler" >&6
17996
17997 # Is the header present?
17998 echo "$as_me:$LINENO: checking $ac_header presence" >&5
17999 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18000 cat >conftest.$ac_ext <<_ACEOF
18001 /* confdefs.h.  */
18002 _ACEOF
18003 cat confdefs.h >>conftest.$ac_ext
18004 cat >>conftest.$ac_ext <<_ACEOF
18005 /* end confdefs.h.  */
18006 #include <$ac_header>
18007 _ACEOF
18008 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18009   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18010   ac_status=$?
18011   grep -v '^ *+' conftest.er1 >conftest.err
18012   rm -f conftest.er1
18013   cat conftest.err >&5
18014   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18015   (exit $ac_status); } >/dev/null; then
18016   if test -s conftest.err; then
18017     ac_cpp_err=$ac_c_preproc_warn_flag
18018     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
18019   else
18020     ac_cpp_err=
18021   fi
18022 else
18023   ac_cpp_err=yes
18024 fi
18025 if test -z "$ac_cpp_err"; then
18026   ac_header_preproc=yes
18027 else
18028   echo "$as_me: failed program was:" >&5
18029 sed 's/^/| /' conftest.$ac_ext >&5
18030
18031   ac_header_preproc=no
18032 fi
18033 rm -f conftest.err conftest.$ac_ext
18034 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18035 echo "${ECHO_T}$ac_header_preproc" >&6
18036
18037 # So?  What about this header?
18038 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18039   yes:no: )
18040     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18041 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18042     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18043 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18044     ac_header_preproc=yes
18045     ;;
18046   no:yes:* )
18047     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18048 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
18049     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
18050 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
18051     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18052 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18053     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
18054 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
18055     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18056 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18057     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18058 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
18059     (
18060       cat <<\_ASBOX
18061 ## --------------------------------------------- ##
18062 ## Report this to <http://www.openldap.org/its/> ##
18063 ## --------------------------------------------- ##
18064 _ASBOX
18065     ) |
18066       sed "s/^/$as_me: WARNING:     /" >&2
18067     ;;
18068 esac
18069 echo "$as_me:$LINENO: checking for $ac_header" >&5
18070 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18071 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18072   echo $ECHO_N "(cached) $ECHO_C" >&6
18073 else
18074   eval "$as_ac_Header=\$ac_header_preproc"
18075 fi
18076 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18077 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18078
18079 fi
18080 if test `eval echo '${'$as_ac_Header'}'` = yes; then
18081   cat >>confdefs.h <<_ACEOF
18082 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18083 _ACEOF
18084
18085 fi
18086
18087 done
18088
18089
18090         if test $ac_cv_header_krb5_h = yes ; then
18091
18092 for ac_header in heim_err.h
18093 do
18094 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18095 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18096   echo "$as_me:$LINENO: checking for $ac_header" >&5
18097 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18098 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18099   echo $ECHO_N "(cached) $ECHO_C" >&6
18100 fi
18101 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18102 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18103 else
18104   # Is the header compilable?
18105 echo "$as_me:$LINENO: checking $ac_header usability" >&5
18106 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18107 cat >conftest.$ac_ext <<_ACEOF
18108 /* confdefs.h.  */
18109 _ACEOF
18110 cat confdefs.h >>conftest.$ac_ext
18111 cat >>conftest.$ac_ext <<_ACEOF
18112 /* end confdefs.h.  */
18113 $ac_includes_default
18114 #include <$ac_header>
18115 _ACEOF
18116 rm -f conftest.$ac_objext
18117 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18118   (eval $ac_compile) 2>conftest.er1
18119   ac_status=$?
18120   grep -v '^ *+' conftest.er1 >conftest.err
18121   rm -f conftest.er1
18122   cat conftest.err >&5
18123   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18124   (exit $ac_status); } &&
18125          { ac_try='test -z "$ac_c_werror_flag"
18126                          || test ! -s conftest.err'
18127   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18128   (eval $ac_try) 2>&5
18129   ac_status=$?
18130   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18131   (exit $ac_status); }; } &&
18132          { ac_try='test -s conftest.$ac_objext'
18133   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18134   (eval $ac_try) 2>&5
18135   ac_status=$?
18136   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18137   (exit $ac_status); }; }; then
18138   ac_header_compiler=yes
18139 else
18140   echo "$as_me: failed program was:" >&5
18141 sed 's/^/| /' conftest.$ac_ext >&5
18142
18143 ac_header_compiler=no
18144 fi
18145 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18146 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18147 echo "${ECHO_T}$ac_header_compiler" >&6
18148
18149 # Is the header present?
18150 echo "$as_me:$LINENO: checking $ac_header presence" >&5
18151 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18152 cat >conftest.$ac_ext <<_ACEOF
18153 /* confdefs.h.  */
18154 _ACEOF
18155 cat confdefs.h >>conftest.$ac_ext
18156 cat >>conftest.$ac_ext <<_ACEOF
18157 /* end confdefs.h.  */
18158 #include <$ac_header>
18159 _ACEOF
18160 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18161   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18162   ac_status=$?
18163   grep -v '^ *+' conftest.er1 >conftest.err
18164   rm -f conftest.er1
18165   cat conftest.err >&5
18166   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18167   (exit $ac_status); } >/dev/null; then
18168   if test -s conftest.err; then
18169     ac_cpp_err=$ac_c_preproc_warn_flag
18170     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
18171   else
18172     ac_cpp_err=
18173   fi
18174 else
18175   ac_cpp_err=yes
18176 fi
18177 if test -z "$ac_cpp_err"; then
18178   ac_header_preproc=yes
18179 else
18180   echo "$as_me: failed program was:" >&5
18181 sed 's/^/| /' conftest.$ac_ext >&5
18182
18183   ac_header_preproc=no
18184 fi
18185 rm -f conftest.err conftest.$ac_ext
18186 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18187 echo "${ECHO_T}$ac_header_preproc" >&6
18188
18189 # So?  What about this header?
18190 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18191   yes:no: )
18192     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18193 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18194     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18195 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18196     ac_header_preproc=yes
18197     ;;
18198   no:yes:* )
18199     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18200 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
18201     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
18202 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
18203     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18204 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18205     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
18206 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
18207     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18208 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18209     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18210 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
18211     (
18212       cat <<\_ASBOX
18213 ## --------------------------------------------- ##
18214 ## Report this to <http://www.openldap.org/its/> ##
18215 ## --------------------------------------------- ##
18216 _ASBOX
18217     ) |
18218       sed "s/^/$as_me: WARNING:     /" >&2
18219     ;;
18220 esac
18221 echo "$as_me:$LINENO: checking for $ac_header" >&5
18222 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18223 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18224   echo $ECHO_N "(cached) $ECHO_C" >&6
18225 else
18226   eval "$as_ac_Header=\$ac_header_preproc"
18227 fi
18228 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18229 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18230
18231 fi
18232 if test `eval echo '${'$as_ac_Header'}'` = yes; then
18233   cat >>confdefs.h <<_ACEOF
18234 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18235 _ACEOF
18236
18237 fi
18238
18239 done
18240
18241                 if test $ac_cv_header_heim_err_h = yes ; then
18242                         krb5_impl=heimdal
18243                 else
18244                         krb5_impl=mit
18245                 fi
18246
18247                 if test $krb5_impl = mit; then
18248                         echo "$as_me:$LINENO: checking for main in -lk5crypto" >&5
18249 echo $ECHO_N "checking for main in -lk5crypto... $ECHO_C" >&6
18250 if test "${ac_cv_lib_k5crypto_main+set}" = set; then
18251   echo $ECHO_N "(cached) $ECHO_C" >&6
18252 else
18253   ac_check_lib_save_LIBS=$LIBS
18254 LIBS="-lk5crypto  $LIBS"
18255 cat >conftest.$ac_ext <<_ACEOF
18256 /* confdefs.h.  */
18257 _ACEOF
18258 cat confdefs.h >>conftest.$ac_ext
18259 cat >>conftest.$ac_ext <<_ACEOF
18260 /* end confdefs.h.  */
18261
18262
18263 int
18264 main ()
18265 {
18266 main ();
18267   ;
18268   return 0;
18269 }
18270 _ACEOF
18271 rm -f conftest.$ac_objext conftest$ac_exeext
18272 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18273   (eval $ac_link) 2>conftest.er1
18274   ac_status=$?
18275   grep -v '^ *+' conftest.er1 >conftest.err
18276   rm -f conftest.er1
18277   cat conftest.err >&5
18278   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18279   (exit $ac_status); } &&
18280          { ac_try='test -z "$ac_c_werror_flag"
18281                          || test ! -s conftest.err'
18282   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18283   (eval $ac_try) 2>&5
18284   ac_status=$?
18285   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18286   (exit $ac_status); }; } &&
18287          { ac_try='test -s conftest$ac_exeext'
18288   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18289   (eval $ac_try) 2>&5
18290   ac_status=$?
18291   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18292   (exit $ac_status); }; }; then
18293   ac_cv_lib_k5crypto_main=yes
18294 else
18295   echo "$as_me: failed program was:" >&5
18296 sed 's/^/| /' conftest.$ac_ext >&5
18297
18298 ac_cv_lib_k5crypto_main=no
18299 fi
18300 rm -f conftest.err conftest.$ac_objext \
18301       conftest$ac_exeext conftest.$ac_ext
18302 LIBS=$ac_check_lib_save_LIBS
18303 fi
18304 echo "$as_me:$LINENO: result: $ac_cv_lib_k5crypto_main" >&5
18305 echo "${ECHO_T}$ac_cv_lib_k5crypto_main" >&6
18306 if test $ac_cv_lib_k5crypto_main = yes; then
18307   krb5crypto=k5crypto
18308 else
18309   krb5crypto=crypto
18310 fi
18311
18312
18313                         echo "$as_me:$LINENO: checking for main in -lkrb5" >&5
18314 echo $ECHO_N "checking for main in -lkrb5... $ECHO_C" >&6
18315 if test "${ac_cv_lib_krb5_main+set}" = set; then
18316   echo $ECHO_N "(cached) $ECHO_C" >&6
18317 else
18318   ac_check_lib_save_LIBS=$LIBS
18319 LIBS="-lkrb5 -l$krb5crypto -lcom_err $LIBS"
18320 cat >conftest.$ac_ext <<_ACEOF
18321 /* confdefs.h.  */
18322 _ACEOF
18323 cat confdefs.h >>conftest.$ac_ext
18324 cat >>conftest.$ac_ext <<_ACEOF
18325 /* end confdefs.h.  */
18326
18327
18328 int
18329 main ()
18330 {
18331 main ();
18332   ;
18333   return 0;
18334 }
18335 _ACEOF
18336 rm -f conftest.$ac_objext conftest$ac_exeext
18337 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18338   (eval $ac_link) 2>conftest.er1
18339   ac_status=$?
18340   grep -v '^ *+' conftest.er1 >conftest.err
18341   rm -f conftest.er1
18342   cat conftest.err >&5
18343   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18344   (exit $ac_status); } &&
18345          { ac_try='test -z "$ac_c_werror_flag"
18346                          || test ! -s conftest.err'
18347   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18348   (eval $ac_try) 2>&5
18349   ac_status=$?
18350   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18351   (exit $ac_status); }; } &&
18352          { ac_try='test -s conftest$ac_exeext'
18353   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18354   (eval $ac_try) 2>&5
18355   ac_status=$?
18356   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18357   (exit $ac_status); }; }; then
18358   ac_cv_lib_krb5_main=yes
18359 else
18360   echo "$as_me: failed program was:" >&5
18361 sed 's/^/| /' conftest.$ac_ext >&5
18362
18363 ac_cv_lib_krb5_main=no
18364 fi
18365 rm -f conftest.err conftest.$ac_objext \
18366       conftest$ac_exeext conftest.$ac_ext
18367 LIBS=$ac_check_lib_save_LIBS
18368 fi
18369 echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_main" >&5
18370 echo "${ECHO_T}$ac_cv_lib_krb5_main" >&6
18371 if test $ac_cv_lib_krb5_main = yes; then
18372   have_krb5=yes
18373                                 KRB5_LIBS="-lkrb5 -l$krb5crypto -lcom_err"
18374 else
18375   have_krb5=no
18376 fi
18377
18378
18379                 elif test $krb5_impl = heimdal; then
18380                         echo "$as_me:$LINENO: checking for main in -ldes" >&5
18381 echo $ECHO_N "checking for main in -ldes... $ECHO_C" >&6
18382 if test "${ac_cv_lib_des_main+set}" = set; then
18383   echo $ECHO_N "(cached) $ECHO_C" >&6
18384 else
18385   ac_check_lib_save_LIBS=$LIBS
18386 LIBS="-ldes  $LIBS"
18387 cat >conftest.$ac_ext <<_ACEOF
18388 /* confdefs.h.  */
18389 _ACEOF
18390 cat confdefs.h >>conftest.$ac_ext
18391 cat >>conftest.$ac_ext <<_ACEOF
18392 /* end confdefs.h.  */
18393
18394
18395 int
18396 main ()
18397 {
18398 main ();
18399   ;
18400   return 0;
18401 }
18402 _ACEOF
18403 rm -f conftest.$ac_objext conftest$ac_exeext
18404 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18405   (eval $ac_link) 2>conftest.er1
18406   ac_status=$?
18407   grep -v '^ *+' conftest.er1 >conftest.err
18408   rm -f conftest.er1
18409   cat conftest.err >&5
18410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18411   (exit $ac_status); } &&
18412          { ac_try='test -z "$ac_c_werror_flag"
18413                          || test ! -s conftest.err'
18414   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18415   (eval $ac_try) 2>&5
18416   ac_status=$?
18417   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18418   (exit $ac_status); }; } &&
18419          { ac_try='test -s conftest$ac_exeext'
18420   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18421   (eval $ac_try) 2>&5
18422   ac_status=$?
18423   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18424   (exit $ac_status); }; }; then
18425   ac_cv_lib_des_main=yes
18426 else
18427   echo "$as_me: failed program was:" >&5
18428 sed 's/^/| /' conftest.$ac_ext >&5
18429
18430 ac_cv_lib_des_main=no
18431 fi
18432 rm -f conftest.err conftest.$ac_objext \
18433       conftest$ac_exeext conftest.$ac_ext
18434 LIBS=$ac_check_lib_save_LIBS
18435 fi
18436 echo "$as_me:$LINENO: result: $ac_cv_lib_des_main" >&5
18437 echo "${ECHO_T}$ac_cv_lib_des_main" >&6
18438 if test $ac_cv_lib_des_main = yes; then
18439   krb5crypto=des
18440 else
18441   krb5crypto=crypto
18442 fi
18443
18444
18445                         echo "$as_me:$LINENO: checking for main in -lkrb5" >&5
18446 echo $ECHO_N "checking for main in -lkrb5... $ECHO_C" >&6
18447 if test "${ac_cv_lib_krb5_main+set}" = set; then
18448   echo $ECHO_N "(cached) $ECHO_C" >&6
18449 else
18450   ac_check_lib_save_LIBS=$LIBS
18451 LIBS="-lkrb5 -l$krb5crypto -lasn1 -lroken -lcom_err $LIBS"
18452 cat >conftest.$ac_ext <<_ACEOF
18453 /* confdefs.h.  */
18454 _ACEOF
18455 cat confdefs.h >>conftest.$ac_ext
18456 cat >>conftest.$ac_ext <<_ACEOF
18457 /* end confdefs.h.  */
18458
18459
18460 int
18461 main ()
18462 {
18463 main ();
18464   ;
18465   return 0;
18466 }
18467 _ACEOF
18468 rm -f conftest.$ac_objext conftest$ac_exeext
18469 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18470   (eval $ac_link) 2>conftest.er1
18471   ac_status=$?
18472   grep -v '^ *+' conftest.er1 >conftest.err
18473   rm -f conftest.er1
18474   cat conftest.err >&5
18475   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18476   (exit $ac_status); } &&
18477          { ac_try='test -z "$ac_c_werror_flag"
18478                          || test ! -s conftest.err'
18479   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18480   (eval $ac_try) 2>&5
18481   ac_status=$?
18482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18483   (exit $ac_status); }; } &&
18484          { ac_try='test -s conftest$ac_exeext'
18485   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18486   (eval $ac_try) 2>&5
18487   ac_status=$?
18488   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18489   (exit $ac_status); }; }; then
18490   ac_cv_lib_krb5_main=yes
18491 else
18492   echo "$as_me: failed program was:" >&5
18493 sed 's/^/| /' conftest.$ac_ext >&5
18494
18495 ac_cv_lib_krb5_main=no
18496 fi
18497 rm -f conftest.err conftest.$ac_objext \
18498       conftest$ac_exeext conftest.$ac_ext
18499 LIBS=$ac_check_lib_save_LIBS
18500 fi
18501 echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_main" >&5
18502 echo "${ECHO_T}$ac_cv_lib_krb5_main" >&6
18503 if test $ac_cv_lib_krb5_main = yes; then
18504   have_krb5=yes
18505                                 KRB5_LIBS="-lkrb5 -l$krb5crypto -lasn1 -lroken -lcom_err"
18506 else
18507   have_krb5=no
18508 fi
18509
18510
18511
18512 cat >>confdefs.h <<\_ACEOF
18513 #define HAVE_HEIMDAL_KERBEROS 1
18514 _ACEOF
18515
18516
18517                 else
18518                         have_krb5=no
18519                         { echo "$as_me:$LINENO: WARNING: Unrecognized Kerberos5 Implementation" >&5
18520 echo "$as_me: WARNING: Unrecognized Kerberos5 Implementation" >&2;}
18521                 fi
18522
18523                 if test $have_krb5 = yes ; then
18524                         ol_link_krb5=yes
18525
18526
18527 cat >>confdefs.h <<\_ACEOF
18528 #define HAVE_KRB5 1
18529 _ACEOF
18530
18531
18532                         if test $ol_with_kerberos = k5only ; then
18533                                 ol_with_kerberos=found
18534                         fi
18535
18536                 elif test $ol_with_kerberos != auto ; then
18537                         { { echo "$as_me:$LINENO: error: Required Kerberos 5 support not available" >&5
18538 echo "$as_me: error: Required Kerberos 5 support not available" >&2;}
18539    { (exit 1); exit 1; }; }
18540                 fi
18541
18542         fi
18543         ;;
18544 esac
18545
18546 if test $ol_link_krb5 = yes &&
18547    { test $ol_with_kerberos = yes ||
18548      test $ol_with_kerberos = auto ||
18549      test $ol_with_kerberos = k425; }; then
18550
18551
18552
18553 for ac_header in kerberosIV/krb.h kerberosIV/des.h
18554 do
18555 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18556 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18557   echo "$as_me:$LINENO: checking for $ac_header" >&5
18558 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18559 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18560   echo $ECHO_N "(cached) $ECHO_C" >&6
18561 fi
18562 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18563 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18564 else
18565   # Is the header compilable?
18566 echo "$as_me:$LINENO: checking $ac_header usability" >&5
18567 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18568 cat >conftest.$ac_ext <<_ACEOF
18569 /* confdefs.h.  */
18570 _ACEOF
18571 cat confdefs.h >>conftest.$ac_ext
18572 cat >>conftest.$ac_ext <<_ACEOF
18573 /* end confdefs.h.  */
18574 $ac_includes_default
18575 #include <$ac_header>
18576 _ACEOF
18577 rm -f conftest.$ac_objext
18578 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18579   (eval $ac_compile) 2>conftest.er1
18580   ac_status=$?
18581   grep -v '^ *+' conftest.er1 >conftest.err
18582   rm -f conftest.er1
18583   cat conftest.err >&5
18584   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18585   (exit $ac_status); } &&
18586          { ac_try='test -z "$ac_c_werror_flag"
18587                          || test ! -s conftest.err'
18588   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18589   (eval $ac_try) 2>&5
18590   ac_status=$?
18591   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18592   (exit $ac_status); }; } &&
18593          { ac_try='test -s conftest.$ac_objext'
18594   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18595   (eval $ac_try) 2>&5
18596   ac_status=$?
18597   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18598   (exit $ac_status); }; }; then
18599   ac_header_compiler=yes
18600 else
18601   echo "$as_me: failed program was:" >&5
18602 sed 's/^/| /' conftest.$ac_ext >&5
18603
18604 ac_header_compiler=no
18605 fi
18606 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18607 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18608 echo "${ECHO_T}$ac_header_compiler" >&6
18609
18610 # Is the header present?
18611 echo "$as_me:$LINENO: checking $ac_header presence" >&5
18612 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18613 cat >conftest.$ac_ext <<_ACEOF
18614 /* confdefs.h.  */
18615 _ACEOF
18616 cat confdefs.h >>conftest.$ac_ext
18617 cat >>conftest.$ac_ext <<_ACEOF
18618 /* end confdefs.h.  */
18619 #include <$ac_header>
18620 _ACEOF
18621 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18622   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18623   ac_status=$?
18624   grep -v '^ *+' conftest.er1 >conftest.err
18625   rm -f conftest.er1
18626   cat conftest.err >&5
18627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18628   (exit $ac_status); } >/dev/null; then
18629   if test -s conftest.err; then
18630     ac_cpp_err=$ac_c_preproc_warn_flag
18631     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
18632   else
18633     ac_cpp_err=
18634   fi
18635 else
18636   ac_cpp_err=yes
18637 fi
18638 if test -z "$ac_cpp_err"; then
18639   ac_header_preproc=yes
18640 else
18641   echo "$as_me: failed program was:" >&5
18642 sed 's/^/| /' conftest.$ac_ext >&5
18643
18644   ac_header_preproc=no
18645 fi
18646 rm -f conftest.err conftest.$ac_ext
18647 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18648 echo "${ECHO_T}$ac_header_preproc" >&6
18649
18650 # So?  What about this header?
18651 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18652   yes:no: )
18653     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18654 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18655     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18656 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18657     ac_header_preproc=yes
18658     ;;
18659   no:yes:* )
18660     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18661 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
18662     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
18663 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
18664     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18665 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18666     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
18667 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
18668     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18669 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18670     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18671 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
18672     (
18673       cat <<\_ASBOX
18674 ## --------------------------------------------- ##
18675 ## Report this to <http://www.openldap.org/its/> ##
18676 ## --------------------------------------------- ##
18677 _ASBOX
18678     ) |
18679       sed "s/^/$as_me: WARNING:     /" >&2
18680     ;;
18681 esac
18682 echo "$as_me:$LINENO: checking for $ac_header" >&5
18683 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18684 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18685   echo $ECHO_N "(cached) $ECHO_C" >&6
18686 else
18687   eval "$as_ac_Header=\$ac_header_preproc"
18688 fi
18689 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18690 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18691
18692 fi
18693 if test `eval echo '${'$as_ac_Header'}'` = yes; then
18694   cat >>confdefs.h <<_ACEOF
18695 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18696 _ACEOF
18697
18698 fi
18699
18700 done
18701
18702
18703         if test $ac_cv_header_kerberosIV_krb_h = yes ; then
18704                 if test $krb5_impl = mit; then
18705                         echo "$as_me:$LINENO: checking for main in -lkrb4" >&5
18706 echo $ECHO_N "checking for main in -lkrb4... $ECHO_C" >&6
18707 if test "${ac_cv_lib_krb4_main+set}" = set; then
18708   echo $ECHO_N "(cached) $ECHO_C" >&6
18709 else
18710   ac_check_lib_save_LIBS=$LIBS
18711 LIBS="-lkrb4 -ldes425 -lkrb5 -l$krb5crypto -lcom_err $LIBS"
18712 cat >conftest.$ac_ext <<_ACEOF
18713 /* confdefs.h.  */
18714 _ACEOF
18715 cat confdefs.h >>conftest.$ac_ext
18716 cat >>conftest.$ac_ext <<_ACEOF
18717 /* end confdefs.h.  */
18718
18719
18720 int
18721 main ()
18722 {
18723 main ();
18724   ;
18725   return 0;
18726 }
18727 _ACEOF
18728 rm -f conftest.$ac_objext conftest$ac_exeext
18729 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18730   (eval $ac_link) 2>conftest.er1
18731   ac_status=$?
18732   grep -v '^ *+' conftest.er1 >conftest.err
18733   rm -f conftest.er1
18734   cat conftest.err >&5
18735   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18736   (exit $ac_status); } &&
18737          { ac_try='test -z "$ac_c_werror_flag"
18738                          || test ! -s conftest.err'
18739   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18740   (eval $ac_try) 2>&5
18741   ac_status=$?
18742   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18743   (exit $ac_status); }; } &&
18744          { ac_try='test -s conftest$ac_exeext'
18745   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18746   (eval $ac_try) 2>&5
18747   ac_status=$?
18748   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18749   (exit $ac_status); }; }; then
18750   ac_cv_lib_krb4_main=yes
18751 else
18752   echo "$as_me: failed program was:" >&5
18753 sed 's/^/| /' conftest.$ac_ext >&5
18754
18755 ac_cv_lib_krb4_main=no
18756 fi
18757 rm -f conftest.err conftest.$ac_objext \
18758       conftest$ac_exeext conftest.$ac_ext
18759 LIBS=$ac_check_lib_save_LIBS
18760 fi
18761 echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_main" >&5
18762 echo "${ECHO_T}$ac_cv_lib_krb4_main" >&6
18763 if test $ac_cv_lib_krb4_main = yes; then
18764   have_k425=yes
18765                                 KRB4_LIBS="-lkrb4 -ldes425"
18766 else
18767   have_k425=no
18768 fi
18769
18770
18771                 elif test $krb5_impl = heimdal; then
18772                         echo "$as_me:$LINENO: checking for main in -lkrb4" >&5
18773 echo $ECHO_N "checking for main in -lkrb4... $ECHO_C" >&6
18774 if test "${ac_cv_lib_krb4_main+set}" = set; then
18775   echo $ECHO_N "(cached) $ECHO_C" >&6
18776 else
18777   ac_check_lib_save_LIBS=$LIBS
18778 LIBS="-lkrb4 -lkrb5 -l$krb5crypto -lasn1 -lroken -lcom_err $LIBS"
18779 cat >conftest.$ac_ext <<_ACEOF
18780 /* confdefs.h.  */
18781 _ACEOF
18782 cat confdefs.h >>conftest.$ac_ext
18783 cat >>conftest.$ac_ext <<_ACEOF
18784 /* end confdefs.h.  */
18785
18786
18787 int
18788 main ()
18789 {
18790 main ();
18791   ;
18792   return 0;
18793 }
18794 _ACEOF
18795 rm -f conftest.$ac_objext conftest$ac_exeext
18796 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18797   (eval $ac_link) 2>conftest.er1
18798   ac_status=$?
18799   grep -v '^ *+' conftest.er1 >conftest.err
18800   rm -f conftest.er1
18801   cat conftest.err >&5
18802   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18803   (exit $ac_status); } &&
18804          { ac_try='test -z "$ac_c_werror_flag"
18805                          || test ! -s conftest.err'
18806   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18807   (eval $ac_try) 2>&5
18808   ac_status=$?
18809   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18810   (exit $ac_status); }; } &&
18811          { ac_try='test -s conftest$ac_exeext'
18812   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18813   (eval $ac_try) 2>&5
18814   ac_status=$?
18815   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18816   (exit $ac_status); }; }; then
18817   ac_cv_lib_krb4_main=yes
18818 else
18819   echo "$as_me: failed program was:" >&5
18820 sed 's/^/| /' conftest.$ac_ext >&5
18821
18822 ac_cv_lib_krb4_main=no
18823 fi
18824 rm -f conftest.err conftest.$ac_objext \
18825       conftest$ac_exeext conftest.$ac_ext
18826 LIBS=$ac_check_lib_save_LIBS
18827 fi
18828 echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_main" >&5
18829 echo "${ECHO_T}$ac_cv_lib_krb4_main" >&6
18830 if test $ac_cv_lib_krb4_main = yes; then
18831   have_k425=yes
18832                                 KRB4_LIBS="-lkrb4"
18833 else
18834   have_k425=no
18835 fi
18836
18837
18838                 else
18839                         have_425=no
18840                         { echo "$as_me:$LINENO: WARNING: Unrecongized Kerberos V Implementation" >&5
18841 echo "$as_me: WARNING: Unrecongized Kerberos V Implementation" >&2;}
18842                 fi
18843
18844                 if test $have_k425 = yes ; then
18845                         ol_with_kerberos=found
18846                         ol_link_krb4=yes
18847
18848
18849 cat >>confdefs.h <<\_ACEOF
18850 #define HAVE_KRB425 1
18851 _ACEOF
18852
18853
18854 cat >>confdefs.h <<\_ACEOF
18855 #define HAVE_KRB4 1
18856 _ACEOF
18857
18858
18859                         echo "$as_me:$LINENO: checking for des_debug in Kerberos libraries" >&5
18860 echo $ECHO_N "checking for des_debug in Kerberos libraries... $ECHO_C" >&6
18861 if test "${ol_cv_var_des_debug+set}" = set; then
18862   echo $ECHO_N "(cached) $ECHO_C" >&6
18863 else
18864
18865                                                                 save_LIBS="$LIBS"
18866                                 LIBS="$KRB4_LIBS $KRB5_LIBS $LIBS"
18867                                 cat >conftest.$ac_ext <<_ACEOF
18868 /* confdefs.h.  */
18869 _ACEOF
18870 cat confdefs.h >>conftest.$ac_ext
18871 cat >>conftest.$ac_ext <<_ACEOF
18872 /* end confdefs.h.  */
18873
18874 #include <kerberosIV/krb.h>
18875 #include <kerberosIV/des.h>
18876 extern int des_debug;
18877
18878 int
18879 main ()
18880 {
18881
18882 des_debug = 1;
18883
18884   ;
18885   return 0;
18886 }
18887 _ACEOF
18888 rm -f conftest.$ac_objext conftest$ac_exeext
18889 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18890   (eval $ac_link) 2>conftest.er1
18891   ac_status=$?
18892   grep -v '^ *+' conftest.er1 >conftest.err
18893   rm -f conftest.er1
18894   cat conftest.err >&5
18895   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18896   (exit $ac_status); } &&
18897          { ac_try='test -z "$ac_c_werror_flag"
18898                          || test ! -s conftest.err'
18899   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18900   (eval $ac_try) 2>&5
18901   ac_status=$?
18902   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18903   (exit $ac_status); }; } &&
18904          { ac_try='test -s conftest$ac_exeext'
18905   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18906   (eval $ac_try) 2>&5
18907   ac_status=$?
18908   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18909   (exit $ac_status); }; }; then
18910   ol_cv_var_des_debug=yes
18911 else
18912   echo "$as_me: failed program was:" >&5
18913 sed 's/^/| /' conftest.$ac_ext >&5
18914
18915 ol_cv_var_des_debug=no
18916 fi
18917 rm -f conftest.err conftest.$ac_objext \
18918       conftest$ac_exeext conftest.$ac_ext
18919                                                                 LIBS="$save_LIBS"
18920
18921 fi
18922 echo "$as_me:$LINENO: result: $ol_cv_var_des_debug" >&5
18923 echo "${ECHO_T}$ol_cv_var_des_debug" >&6
18924
18925                         if test $ol_cv_var_des_debug = yes ; then
18926
18927 cat >>confdefs.h <<\_ACEOF
18928 #define HAVE_DES_DEBUG 1
18929 _ACEOF
18930
18931                         fi
18932
18933                         LIBS="$save_LIBS"
18934                 fi
18935         fi
18936 fi
18937
18938 if test $ol_link_krb5 = yes ; then
18939         ol_with_kerberos=found
18940 fi
18941
18942 case $ol_with_kerberos in yes | auto | k4 | kth)
18943
18944
18945
18946
18947 for ac_header in krb.h des.h krb-archaeology.h
18948 do
18949 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18950 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18951   echo "$as_me:$LINENO: checking for $ac_header" >&5
18952 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18953 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18954   echo $ECHO_N "(cached) $ECHO_C" >&6
18955 fi
18956 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18957 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18958 else
18959   # Is the header compilable?
18960 echo "$as_me:$LINENO: checking $ac_header usability" >&5
18961 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18962 cat >conftest.$ac_ext <<_ACEOF
18963 /* confdefs.h.  */
18964 _ACEOF
18965 cat confdefs.h >>conftest.$ac_ext
18966 cat >>conftest.$ac_ext <<_ACEOF
18967 /* end confdefs.h.  */
18968 $ac_includes_default
18969 #include <$ac_header>
18970 _ACEOF
18971 rm -f conftest.$ac_objext
18972 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18973   (eval $ac_compile) 2>conftest.er1
18974   ac_status=$?
18975   grep -v '^ *+' conftest.er1 >conftest.err
18976   rm -f conftest.er1
18977   cat conftest.err >&5
18978   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18979   (exit $ac_status); } &&
18980          { ac_try='test -z "$ac_c_werror_flag"
18981                          || test ! -s conftest.err'
18982   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18983   (eval $ac_try) 2>&5
18984   ac_status=$?
18985   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18986   (exit $ac_status); }; } &&
18987          { ac_try='test -s conftest.$ac_objext'
18988   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18989   (eval $ac_try) 2>&5
18990   ac_status=$?
18991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18992   (exit $ac_status); }; }; then
18993   ac_header_compiler=yes
18994 else
18995   echo "$as_me: failed program was:" >&5
18996 sed 's/^/| /' conftest.$ac_ext >&5
18997
18998 ac_header_compiler=no
18999 fi
19000 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19001 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19002 echo "${ECHO_T}$ac_header_compiler" >&6
19003
19004 # Is the header present?
19005 echo "$as_me:$LINENO: checking $ac_header presence" >&5
19006 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19007 cat >conftest.$ac_ext <<_ACEOF
19008 /* confdefs.h.  */
19009 _ACEOF
19010 cat confdefs.h >>conftest.$ac_ext
19011 cat >>conftest.$ac_ext <<_ACEOF
19012 /* end confdefs.h.  */
19013 #include <$ac_header>
19014 _ACEOF
19015 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
19016   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19017   ac_status=$?
19018   grep -v '^ *+' conftest.er1 >conftest.err
19019   rm -f conftest.er1
19020   cat conftest.err >&5
19021   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19022   (exit $ac_status); } >/dev/null; then
19023   if test -s conftest.err; then
19024     ac_cpp_err=$ac_c_preproc_warn_flag
19025     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
19026   else
19027     ac_cpp_err=
19028   fi
19029 else
19030   ac_cpp_err=yes
19031 fi
19032 if test -z "$ac_cpp_err"; then
19033   ac_header_preproc=yes
19034 else
19035   echo "$as_me: failed program was:" >&5
19036 sed 's/^/| /' conftest.$ac_ext >&5
19037
19038   ac_header_preproc=no
19039 fi
19040 rm -f conftest.err conftest.$ac_ext
19041 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19042 echo "${ECHO_T}$ac_header_preproc" >&6
19043
19044 # So?  What about this header?
19045 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19046   yes:no: )
19047     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19048 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
19049     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19050 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19051     ac_header_preproc=yes
19052     ;;
19053   no:yes:* )
19054     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19055 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
19056     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
19057 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
19058     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19059 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19060     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
19061 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
19062     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19063 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19064     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19065 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19066     (
19067       cat <<\_ASBOX
19068 ## --------------------------------------------- ##
19069 ## Report this to <http://www.openldap.org/its/> ##
19070 ## --------------------------------------------- ##
19071 _ASBOX
19072     ) |
19073       sed "s/^/$as_me: WARNING:     /" >&2
19074     ;;
19075 esac
19076 echo "$as_me:$LINENO: checking for $ac_header" >&5
19077 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19078 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19079   echo $ECHO_N "(cached) $ECHO_C" >&6
19080 else
19081   eval "$as_ac_Header=\$ac_header_preproc"
19082 fi
19083 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19084 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19085
19086 fi
19087 if test `eval echo '${'$as_ac_Header'}'` = yes; then
19088   cat >>confdefs.h <<_ACEOF
19089 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
19090 _ACEOF
19091
19092 fi
19093
19094 done
19095
19096
19097         if test $ac_cv_header_krb_h = yes ; then
19098                 echo "$as_me:$LINENO: checking for main in -lkrb" >&5
19099 echo $ECHO_N "checking for main in -lkrb... $ECHO_C" >&6
19100 if test "${ac_cv_lib_krb_main+set}" = set; then
19101   echo $ECHO_N "(cached) $ECHO_C" >&6
19102 else
19103   ac_check_lib_save_LIBS=$LIBS
19104 LIBS="-lkrb -ldes $LIBS"
19105 cat >conftest.$ac_ext <<_ACEOF
19106 /* confdefs.h.  */
19107 _ACEOF
19108 cat confdefs.h >>conftest.$ac_ext
19109 cat >>conftest.$ac_ext <<_ACEOF
19110 /* end confdefs.h.  */
19111
19112
19113 int
19114 main ()
19115 {
19116 main ();
19117   ;
19118   return 0;
19119 }
19120 _ACEOF
19121 rm -f conftest.$ac_objext conftest$ac_exeext
19122 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19123   (eval $ac_link) 2>conftest.er1
19124   ac_status=$?
19125   grep -v '^ *+' conftest.er1 >conftest.err
19126   rm -f conftest.er1
19127   cat conftest.err >&5
19128   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19129   (exit $ac_status); } &&
19130          { ac_try='test -z "$ac_c_werror_flag"
19131                          || test ! -s conftest.err'
19132   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19133   (eval $ac_try) 2>&5
19134   ac_status=$?
19135   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19136   (exit $ac_status); }; } &&
19137          { ac_try='test -s conftest$ac_exeext'
19138   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19139   (eval $ac_try) 2>&5
19140   ac_status=$?
19141   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19142   (exit $ac_status); }; }; then
19143   ac_cv_lib_krb_main=yes
19144 else
19145   echo "$as_me: failed program was:" >&5
19146 sed 's/^/| /' conftest.$ac_ext >&5
19147
19148 ac_cv_lib_krb_main=no
19149 fi
19150 rm -f conftest.err conftest.$ac_objext \
19151       conftest$ac_exeext conftest.$ac_ext
19152 LIBS=$ac_check_lib_save_LIBS
19153 fi
19154 echo "$as_me:$LINENO: result: $ac_cv_lib_krb_main" >&5
19155 echo "${ECHO_T}$ac_cv_lib_krb_main" >&6
19156 if test $ac_cv_lib_krb_main = yes; then
19157   have_k4=yes
19158 else
19159   have_k4=no
19160 fi
19161
19162
19163                 if test $have_k4 = yes ; then
19164                         ol_with_kerberos=found
19165                         ol_link_krb4=yes
19166
19167
19168 cat >>confdefs.h <<\_ACEOF
19169 #define HAVE_KRB4 1
19170 _ACEOF
19171
19172
19173                         KRB4_LIBS="-lkrb -ldes"
19174
19175                         if test $ac_cv_header_krb_archaeology_h = yes ; then
19176
19177 cat >>confdefs.h <<\_ACEOF
19178 #define HAVE_KTH_KERBEROS 1
19179 _ACEOF
19180
19181                         fi
19182                 fi
19183         fi
19184         ;;
19185 esac
19186
19187 if test $ol_link_krb4 = yes && test $ol_enable_kbind != no ; then
19188         ol_link_kbind=yes
19189
19190 elif test $ol_enable_kbind = yes ; then
19191         { { echo "$as_me:$LINENO: error: Kerberos IV detection failed" >&5
19192 echo "$as_me: error: Kerberos IV detection failed" >&2;}
19193    { (exit 1); exit 1; }; }
19194 fi
19195
19196 if test $ol_link_krb4 = yes || test $ol_link_krb5 = yes ; then
19197
19198 cat >>confdefs.h <<\_ACEOF
19199 #define HAVE_KERBEROS 1
19200 _ACEOF
19201
19202
19203 elif test $ol_with_kerberos != auto && test $ol_with_kerberos != no ; then
19204         { { echo "$as_me:$LINENO: error: Kerberos detection failed" >&5
19205 echo "$as_me: error: Kerberos detection failed" >&2;}
19206    { (exit 1); exit 1; }; }
19207 fi
19208
19209
19210 if test $ol_with_tls = yes ; then
19211         ol_with_tls=auto
19212 fi
19213
19214 ol_link_tls=no
19215 if test $ol_with_tls = openssl || test $ol_with_tls = auto ; then
19216
19217 for ac_header in openssl/ssl.h
19218 do
19219 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
19220 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19221   echo "$as_me:$LINENO: checking for $ac_header" >&5
19222 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19223 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19224   echo $ECHO_N "(cached) $ECHO_C" >&6
19225 fi
19226 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19227 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19228 else
19229   # Is the header compilable?
19230 echo "$as_me:$LINENO: checking $ac_header usability" >&5
19231 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19232 cat >conftest.$ac_ext <<_ACEOF
19233 /* confdefs.h.  */
19234 _ACEOF
19235 cat confdefs.h >>conftest.$ac_ext
19236 cat >>conftest.$ac_ext <<_ACEOF
19237 /* end confdefs.h.  */
19238 $ac_includes_default
19239 #include <$ac_header>
19240 _ACEOF
19241 rm -f conftest.$ac_objext
19242 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19243   (eval $ac_compile) 2>conftest.er1
19244   ac_status=$?
19245   grep -v '^ *+' conftest.er1 >conftest.err
19246   rm -f conftest.er1
19247   cat conftest.err >&5
19248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19249   (exit $ac_status); } &&
19250          { ac_try='test -z "$ac_c_werror_flag"
19251                          || test ! -s conftest.err'
19252   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19253   (eval $ac_try) 2>&5
19254   ac_status=$?
19255   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19256   (exit $ac_status); }; } &&
19257          { ac_try='test -s conftest.$ac_objext'
19258   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19259   (eval $ac_try) 2>&5
19260   ac_status=$?
19261   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19262   (exit $ac_status); }; }; then
19263   ac_header_compiler=yes
19264 else
19265   echo "$as_me: failed program was:" >&5
19266 sed 's/^/| /' conftest.$ac_ext >&5
19267
19268 ac_header_compiler=no
19269 fi
19270 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19271 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19272 echo "${ECHO_T}$ac_header_compiler" >&6
19273
19274 # Is the header present?
19275 echo "$as_me:$LINENO: checking $ac_header presence" >&5
19276 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19277 cat >conftest.$ac_ext <<_ACEOF
19278 /* confdefs.h.  */
19279 _ACEOF
19280 cat confdefs.h >>conftest.$ac_ext
19281 cat >>conftest.$ac_ext <<_ACEOF
19282 /* end confdefs.h.  */
19283 #include <$ac_header>
19284 _ACEOF
19285 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
19286   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19287   ac_status=$?
19288   grep -v '^ *+' conftest.er1 >conftest.err
19289   rm -f conftest.er1
19290   cat conftest.err >&5
19291   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19292   (exit $ac_status); } >/dev/null; then
19293   if test -s conftest.err; then
19294     ac_cpp_err=$ac_c_preproc_warn_flag
19295     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
19296   else
19297     ac_cpp_err=
19298   fi
19299 else
19300   ac_cpp_err=yes
19301 fi
19302 if test -z "$ac_cpp_err"; then
19303   ac_header_preproc=yes
19304 else
19305   echo "$as_me: failed program was:" >&5
19306 sed 's/^/| /' conftest.$ac_ext >&5
19307
19308   ac_header_preproc=no
19309 fi
19310 rm -f conftest.err conftest.$ac_ext
19311 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19312 echo "${ECHO_T}$ac_header_preproc" >&6
19313
19314 # So?  What about this header?
19315 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19316   yes:no: )
19317     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19318 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
19319     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19320 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19321     ac_header_preproc=yes
19322     ;;
19323   no:yes:* )
19324     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19325 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
19326     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
19327 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
19328     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19329 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19330     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
19331 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
19332     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19333 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19334     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19335 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19336     (
19337       cat <<\_ASBOX
19338 ## --------------------------------------------- ##
19339 ## Report this to <http://www.openldap.org/its/> ##
19340 ## --------------------------------------------- ##
19341 _ASBOX
19342     ) |
19343       sed "s/^/$as_me: WARNING:     /" >&2
19344     ;;
19345 esac
19346 echo "$as_me:$LINENO: checking for $ac_header" >&5
19347 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19348 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19349   echo $ECHO_N "(cached) $ECHO_C" >&6
19350 else
19351   eval "$as_ac_Header=\$ac_header_preproc"
19352 fi
19353 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19354 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19355
19356 fi
19357 if test `eval echo '${'$as_ac_Header'}'` = yes; then
19358   cat >>confdefs.h <<_ACEOF
19359 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
19360 _ACEOF
19361
19362 fi
19363
19364 done
19365
19366
19367         if test $ac_cv_header_openssl_ssl_h = yes ; then
19368                 echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
19369 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6
19370 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
19371   echo $ECHO_N "(cached) $ECHO_C" >&6
19372 else
19373   ac_check_lib_save_LIBS=$LIBS
19374 LIBS="-lssl -lcrypto $LIBS"
19375 cat >conftest.$ac_ext <<_ACEOF
19376 /* confdefs.h.  */
19377 _ACEOF
19378 cat confdefs.h >>conftest.$ac_ext
19379 cat >>conftest.$ac_ext <<_ACEOF
19380 /* end confdefs.h.  */
19381
19382 /* Override any gcc2 internal prototype to avoid an error.  */
19383 #ifdef __cplusplus
19384 extern "C"
19385 #endif
19386 /* We use char because int might match the return type of a gcc2
19387    builtin and then its argument prototype would still apply.  */
19388 char SSL_library_init ();
19389 int
19390 main ()
19391 {
19392 SSL_library_init ();
19393   ;
19394   return 0;
19395 }
19396 _ACEOF
19397 rm -f conftest.$ac_objext conftest$ac_exeext
19398 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19399   (eval $ac_link) 2>conftest.er1
19400   ac_status=$?
19401   grep -v '^ *+' conftest.er1 >conftest.err
19402   rm -f conftest.er1
19403   cat conftest.err >&5
19404   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19405   (exit $ac_status); } &&
19406          { ac_try='test -z "$ac_c_werror_flag"
19407                          || test ! -s conftest.err'
19408   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19409   (eval $ac_try) 2>&5
19410   ac_status=$?
19411   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19412   (exit $ac_status); }; } &&
19413          { ac_try='test -s conftest$ac_exeext'
19414   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19415   (eval $ac_try) 2>&5
19416   ac_status=$?
19417   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19418   (exit $ac_status); }; }; then
19419   ac_cv_lib_ssl_SSL_library_init=yes
19420 else
19421   echo "$as_me: failed program was:" >&5
19422 sed 's/^/| /' conftest.$ac_ext >&5
19423
19424 ac_cv_lib_ssl_SSL_library_init=no
19425 fi
19426 rm -f conftest.err conftest.$ac_objext \
19427       conftest$ac_exeext conftest.$ac_ext
19428 LIBS=$ac_check_lib_save_LIBS
19429 fi
19430 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
19431 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6
19432 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
19433   have_openssl=yes
19434                         need_rsaref=no
19435 else
19436   have_openssl=no
19437 fi
19438
19439
19440                 if test $have_openssl = no ; then
19441                         echo "$as_me:$LINENO: checking for ssl3_accept in -lssl" >&5
19442 echo $ECHO_N "checking for ssl3_accept in -lssl... $ECHO_C" >&6
19443 if test "${ac_cv_lib_ssl_ssl3_accept+set}" = set; then
19444   echo $ECHO_N "(cached) $ECHO_C" >&6
19445 else
19446   ac_check_lib_save_LIBS=$LIBS
19447 LIBS="-lssl -lcrypto -lRSAglue -lrsaref $LIBS"
19448 cat >conftest.$ac_ext <<_ACEOF
19449 /* confdefs.h.  */
19450 _ACEOF
19451 cat confdefs.h >>conftest.$ac_ext
19452 cat >>conftest.$ac_ext <<_ACEOF
19453 /* end confdefs.h.  */
19454
19455 /* Override any gcc2 internal prototype to avoid an error.  */
19456 #ifdef __cplusplus
19457 extern "C"
19458 #endif
19459 /* We use char because int might match the return type of a gcc2
19460    builtin and then its argument prototype would still apply.  */
19461 char ssl3_accept ();
19462 int
19463 main ()
19464 {
19465 ssl3_accept ();
19466   ;
19467   return 0;
19468 }
19469 _ACEOF
19470 rm -f conftest.$ac_objext conftest$ac_exeext
19471 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19472   (eval $ac_link) 2>conftest.er1
19473   ac_status=$?
19474   grep -v '^ *+' conftest.er1 >conftest.err
19475   rm -f conftest.er1
19476   cat conftest.err >&5
19477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19478   (exit $ac_status); } &&
19479          { ac_try='test -z "$ac_c_werror_flag"
19480                          || test ! -s conftest.err'
19481   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19482   (eval $ac_try) 2>&5
19483   ac_status=$?
19484   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19485   (exit $ac_status); }; } &&
19486          { ac_try='test -s conftest$ac_exeext'
19487   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19488   (eval $ac_try) 2>&5
19489   ac_status=$?
19490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19491   (exit $ac_status); }; }; then
19492   ac_cv_lib_ssl_ssl3_accept=yes
19493 else
19494   echo "$as_me: failed program was:" >&5
19495 sed 's/^/| /' conftest.$ac_ext >&5
19496
19497 ac_cv_lib_ssl_ssl3_accept=no
19498 fi
19499 rm -f conftest.err conftest.$ac_objext \
19500       conftest$ac_exeext conftest.$ac_ext
19501 LIBS=$ac_check_lib_save_LIBS
19502 fi
19503 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_ssl3_accept" >&5
19504 echo "${ECHO_T}$ac_cv_lib_ssl_ssl3_accept" >&6
19505 if test $ac_cv_lib_ssl_ssl3_accept = yes; then
19506   have_openssl=yes
19507                                 need_rsaref=yes
19508 else
19509   have_openssl=no
19510 fi
19511
19512                 fi
19513
19514                 if test $have_openssl = yes ; then
19515                         ol_with_tls=openssl
19516                         ol_link_tls=yes
19517
19518
19519 cat >>confdefs.h <<\_ACEOF
19520 #define HAVE_OPENSSL 1
19521 _ACEOF
19522
19523
19524                         if test $need_rsaref = yes; then
19525
19526 cat >>confdefs.h <<\_ACEOF
19527 #define HAVE_RSAREF 1
19528 _ACEOF
19529
19530
19531                                 TLS_LIBS="-lssl -lcrypto -lRSAglue -lrsaref"
19532                         else
19533                                 TLS_LIBS="-lssl -lcrypto"
19534                         fi
19535
19536                         echo "$as_me:$LINENO: checking OpenSSL library version (CRL checking capability)" >&5
19537 echo $ECHO_N "checking OpenSSL library version (CRL checking capability)... $ECHO_C" >&6
19538 if test "${ol_cv_ssl_crl_compat+set}" = set; then
19539   echo $ECHO_N "(cached) $ECHO_C" >&6
19540 else
19541
19542                 cat >conftest.$ac_ext <<_ACEOF
19543 /* confdefs.h.  */
19544 _ACEOF
19545 cat confdefs.h >>conftest.$ac_ext
19546 cat >>conftest.$ac_ext <<_ACEOF
19547 /* end confdefs.h.  */
19548
19549 #ifdef HAVE_OPENSSL_SSL_H
19550 #include <openssl/ssl.h>
19551 #endif
19552
19553 /* Require 0.9.7d+ */
19554 #if OPENSSL_VERSION_NUMBER >= 0x0090704fL
19555         char *__ssl_compat = "0.9.7d";
19556 #endif
19557
19558 _ACEOF
19559 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19560   $EGREP "__ssl_compat" >/dev/null 2>&1; then
19561   ol_cv_ssl_crl_compat=yes
19562 else
19563   ol_cv_ssl_crl_compat=no
19564 fi
19565 rm -f conftest*
19566
19567 fi
19568 echo "$as_me:$LINENO: result: $ol_cv_ssl_crl_compat" >&5
19569 echo "${ECHO_T}$ol_cv_ssl_crl_compat" >&6
19570
19571                         if test $ol_cv_ssl_crl_compat = yes ; then
19572
19573 cat >>confdefs.h <<\_ACEOF
19574 #define HAVE_OPENSSL_CRL 1
19575 _ACEOF
19576
19577                         fi
19578                 fi
19579         fi
19580 fi
19581
19582 WITH_TLS=no
19583 if test $ol_link_tls = yes ; then
19584
19585 cat >>confdefs.h <<\_ACEOF
19586 #define HAVE_TLS 1
19587 _ACEOF
19588
19589         WITH_TLS=yes
19590 elif test $ol_with_tls = auto ; then
19591         { echo "$as_me:$LINENO: WARNING: Could not locate TLS/SSL package" >&5
19592 echo "$as_me: WARNING: Could not locate TLS/SSL package" >&2;}
19593         { echo "$as_me:$LINENO: WARNING: TLS data protection not supported!" >&5
19594 echo "$as_me: WARNING: TLS data protection not supported!" >&2;}
19595 elif test $ol_with_tls != no ; then
19596         { { echo "$as_me:$LINENO: error: Could not locate TLS/SSL package" >&5
19597 echo "$as_me: error: Could not locate TLS/SSL package" >&2;}
19598    { (exit 1); exit 1; }; }
19599 else
19600         { echo "$as_me:$LINENO: WARNING: TLS data protection not supported!" >&5
19601 echo "$as_me: WARNING: TLS data protection not supported!" >&2;}
19602 fi
19603
19604 if test $ol_enable_lmpasswd != no; then
19605         if test $ol_link_tls != yes ; then
19606                 { { echo "$as_me:$LINENO: error: LAN Manager passwords require OpenSSL" >&5
19607 echo "$as_me: error: LAN Manager passwords require OpenSSL" >&2;}
19608    { (exit 1); exit 1; }; }
19609         fi
19610
19611
19612 cat >>confdefs.h <<\_ACEOF
19613 #define SLAPD_LMHASH 1
19614 _ACEOF
19615
19616 fi
19617
19618 ol_link_threads=no
19619
19620 case $ol_with_threads in auto | yes | nt)
19621
19622
19623         echo "$as_me:$LINENO: checking for _beginthread" >&5
19624 echo $ECHO_N "checking for _beginthread... $ECHO_C" >&6
19625 if test "${ac_cv_func__beginthread+set}" = set; then
19626   echo $ECHO_N "(cached) $ECHO_C" >&6
19627 else
19628   cat >conftest.$ac_ext <<_ACEOF
19629 /* confdefs.h.  */
19630 _ACEOF
19631 cat confdefs.h >>conftest.$ac_ext
19632 cat >>conftest.$ac_ext <<_ACEOF
19633 /* end confdefs.h.  */
19634 /* Define _beginthread to an innocuous variant, in case <limits.h> declares _beginthread.
19635    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19636 #define _beginthread innocuous__beginthread
19637
19638 /* System header to define __stub macros and hopefully few prototypes,
19639     which can conflict with char _beginthread (); below.
19640     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19641     <limits.h> exists even on freestanding compilers.  */
19642
19643 #ifdef __STDC__
19644 # include <limits.h>
19645 #else
19646 # include <assert.h>
19647 #endif
19648
19649 #undef _beginthread
19650
19651 /* Override any gcc2 internal prototype to avoid an error.  */
19652 #ifdef __cplusplus
19653 extern "C"
19654 {
19655 #endif
19656 /* We use char because int might match the return type of a gcc2
19657    builtin and then its argument prototype would still apply.  */
19658 char _beginthread ();
19659 /* The GNU C library defines this for functions which it implements
19660     to always fail with ENOSYS.  Some functions are actually named
19661     something starting with __ and the normal name is an alias.  */
19662 #if defined (__stub__beginthread) || defined (__stub____beginthread)
19663 choke me
19664 #else
19665 char (*f) () = _beginthread;
19666 #endif
19667 #ifdef __cplusplus
19668 }
19669 #endif
19670
19671 int
19672 main ()
19673 {
19674 return f != _beginthread;
19675   ;
19676   return 0;
19677 }
19678 _ACEOF
19679 rm -f conftest.$ac_objext conftest$ac_exeext
19680 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19681   (eval $ac_link) 2>conftest.er1
19682   ac_status=$?
19683   grep -v '^ *+' conftest.er1 >conftest.err
19684   rm -f conftest.er1
19685   cat conftest.err >&5
19686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19687   (exit $ac_status); } &&
19688          { ac_try='test -z "$ac_c_werror_flag"
19689                          || test ! -s conftest.err'
19690   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19691   (eval $ac_try) 2>&5
19692   ac_status=$?
19693   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19694   (exit $ac_status); }; } &&
19695          { ac_try='test -s conftest$ac_exeext'
19696   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19697   (eval $ac_try) 2>&5
19698   ac_status=$?
19699   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19700   (exit $ac_status); }; }; then
19701   ac_cv_func__beginthread=yes
19702 else
19703   echo "$as_me: failed program was:" >&5
19704 sed 's/^/| /' conftest.$ac_ext >&5
19705
19706 ac_cv_func__beginthread=no
19707 fi
19708 rm -f conftest.err conftest.$ac_objext \
19709       conftest$ac_exeext conftest.$ac_ext
19710 fi
19711 echo "$as_me:$LINENO: result: $ac_cv_func__beginthread" >&5
19712 echo "${ECHO_T}$ac_cv_func__beginthread" >&6
19713
19714
19715         if test $ac_cv_func__beginthread = yes ; then
19716
19717 cat >>confdefs.h <<\_ACEOF
19718 #define HAVE_NT_THREADS 1
19719 _ACEOF
19720
19721                 ol_cv_nt_threads=yes
19722         fi
19723
19724
19725         if test "$ol_cv_nt_threads" = yes ; then
19726                 ol_link_threads=nt
19727                 ol_with_threads=found
19728                 ol_with_yielding_select=yes
19729
19730
19731 cat >>confdefs.h <<\_ACEOF
19732 #define HAVE_NT_SERVICE_MANAGER 1
19733 _ACEOF
19734
19735
19736 cat >>confdefs.h <<\_ACEOF
19737 #define HAVE_NT_EVENT_LOG 1
19738 _ACEOF
19739
19740         fi
19741
19742         if test $ol_with_threads = nt ; then
19743                 { { echo "$as_me:$LINENO: error: could not locate NT Threads" >&5
19744 echo "$as_me: error: could not locate NT Threads" >&2;}
19745    { (exit 1); exit 1; }; }
19746         fi
19747         ;;
19748 esac
19749
19750 case $ol_with_threads in auto | yes | posix)
19751
19752
19753 for ac_header in pthread.h
19754 do
19755 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
19756 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19757   echo "$as_me:$LINENO: checking for $ac_header" >&5
19758 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19759 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19760   echo $ECHO_N "(cached) $ECHO_C" >&6
19761 fi
19762 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19763 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19764 else
19765   # Is the header compilable?
19766 echo "$as_me:$LINENO: checking $ac_header usability" >&5
19767 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19768 cat >conftest.$ac_ext <<_ACEOF
19769 /* confdefs.h.  */
19770 _ACEOF
19771 cat confdefs.h >>conftest.$ac_ext
19772 cat >>conftest.$ac_ext <<_ACEOF
19773 /* end confdefs.h.  */
19774 $ac_includes_default
19775 #include <$ac_header>
19776 _ACEOF
19777 rm -f conftest.$ac_objext
19778 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19779   (eval $ac_compile) 2>conftest.er1
19780   ac_status=$?
19781   grep -v '^ *+' conftest.er1 >conftest.err
19782   rm -f conftest.er1
19783   cat conftest.err >&5
19784   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19785   (exit $ac_status); } &&
19786          { ac_try='test -z "$ac_c_werror_flag"
19787                          || test ! -s conftest.err'
19788   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19789   (eval $ac_try) 2>&5
19790   ac_status=$?
19791   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19792   (exit $ac_status); }; } &&
19793          { ac_try='test -s conftest.$ac_objext'
19794   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19795   (eval $ac_try) 2>&5
19796   ac_status=$?
19797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19798   (exit $ac_status); }; }; then
19799   ac_header_compiler=yes
19800 else
19801   echo "$as_me: failed program was:" >&5
19802 sed 's/^/| /' conftest.$ac_ext >&5
19803
19804 ac_header_compiler=no
19805 fi
19806 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19807 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19808 echo "${ECHO_T}$ac_header_compiler" >&6
19809
19810 # Is the header present?
19811 echo "$as_me:$LINENO: checking $ac_header presence" >&5
19812 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19813 cat >conftest.$ac_ext <<_ACEOF
19814 /* confdefs.h.  */
19815 _ACEOF
19816 cat confdefs.h >>conftest.$ac_ext
19817 cat >>conftest.$ac_ext <<_ACEOF
19818 /* end confdefs.h.  */
19819 #include <$ac_header>
19820 _ACEOF
19821 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
19822   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19823   ac_status=$?
19824   grep -v '^ *+' conftest.er1 >conftest.err
19825   rm -f conftest.er1
19826   cat conftest.err >&5
19827   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19828   (exit $ac_status); } >/dev/null; then
19829   if test -s conftest.err; then
19830     ac_cpp_err=$ac_c_preproc_warn_flag
19831     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
19832   else
19833     ac_cpp_err=
19834   fi
19835 else
19836   ac_cpp_err=yes
19837 fi
19838 if test -z "$ac_cpp_err"; then
19839   ac_header_preproc=yes
19840 else
19841   echo "$as_me: failed program was:" >&5
19842 sed 's/^/| /' conftest.$ac_ext >&5
19843
19844   ac_header_preproc=no
19845 fi
19846 rm -f conftest.err conftest.$ac_ext
19847 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19848 echo "${ECHO_T}$ac_header_preproc" >&6
19849
19850 # So?  What about this header?
19851 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19852   yes:no: )
19853     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19854 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
19855     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19856 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19857     ac_header_preproc=yes
19858     ;;
19859   no:yes:* )
19860     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19861 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
19862     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
19863 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
19864     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19865 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19866     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
19867 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
19868     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19869 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19870     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19871 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19872     (
19873       cat <<\_ASBOX
19874 ## --------------------------------------------- ##
19875 ## Report this to <http://www.openldap.org/its/> ##
19876 ## --------------------------------------------- ##
19877 _ASBOX
19878     ) |
19879       sed "s/^/$as_me: WARNING:     /" >&2
19880     ;;
19881 esac
19882 echo "$as_me:$LINENO: checking for $ac_header" >&5
19883 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19884 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19885   echo $ECHO_N "(cached) $ECHO_C" >&6
19886 else
19887   eval "$as_ac_Header=\$ac_header_preproc"
19888 fi
19889 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19890 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19891
19892 fi
19893 if test `eval echo '${'$as_ac_Header'}'` = yes; then
19894   cat >>confdefs.h <<_ACEOF
19895 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
19896 _ACEOF
19897
19898 fi
19899
19900 done
19901
19902
19903         if test $ac_cv_header_pthread_h = yes ; then
19904                 echo "$as_me:$LINENO: checking POSIX thread version" >&5
19905 echo $ECHO_N "checking POSIX thread version... $ECHO_C" >&6
19906 if test "${ol_cv_pthread_version+set}" = set; then
19907   echo $ECHO_N "(cached) $ECHO_C" >&6
19908 else
19909
19910         cat >conftest.$ac_ext <<_ACEOF
19911 /* confdefs.h.  */
19912 _ACEOF
19913 cat confdefs.h >>conftest.$ac_ext
19914 cat >>conftest.$ac_ext <<_ACEOF
19915 /* end confdefs.h.  */
19916
19917 #               include <pthread.h>
19918
19919 int
19920 main ()
19921 {
19922
19923                 int i = PTHREAD_CREATE_JOINABLE;
19924
19925   ;
19926   return 0;
19927 }
19928 _ACEOF
19929 rm -f conftest.$ac_objext
19930 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19931   (eval $ac_compile) 2>conftest.er1
19932   ac_status=$?
19933   grep -v '^ *+' conftest.er1 >conftest.err
19934   rm -f conftest.er1
19935   cat conftest.err >&5
19936   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19937   (exit $ac_status); } &&
19938          { ac_try='test -z "$ac_c_werror_flag"
19939                          || test ! -s conftest.err'
19940   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19941   (eval $ac_try) 2>&5
19942   ac_status=$?
19943   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19944   (exit $ac_status); }; } &&
19945          { ac_try='test -s conftest.$ac_objext'
19946   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19947   (eval $ac_try) 2>&5
19948   ac_status=$?
19949   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19950   (exit $ac_status); }; }; then
19951
19952         cat >conftest.$ac_ext <<_ACEOF
19953 /* confdefs.h.  */
19954 _ACEOF
19955 cat confdefs.h >>conftest.$ac_ext
19956 cat >>conftest.$ac_ext <<_ACEOF
19957 /* end confdefs.h.  */
19958 #include <pthread.h>
19959
19960 _ACEOF
19961 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19962   $EGREP "pthread_detach" >/dev/null 2>&1; then
19963   ol_cv_pthread_version=10
19964 else
19965   ol_cv_pthread_version=8
19966 fi
19967 rm -f conftest*
19968
19969 else
19970   echo "$as_me: failed program was:" >&5
19971 sed 's/^/| /' conftest.$ac_ext >&5
19972
19973
19974         cat >conftest.$ac_ext <<_ACEOF
19975 /* confdefs.h.  */
19976 _ACEOF
19977 cat confdefs.h >>conftest.$ac_ext
19978 cat >>conftest.$ac_ext <<_ACEOF
19979 /* end confdefs.h.  */
19980
19981 #               include <pthread.h>
19982 #               ifdef PTHREAD_CREATE_UNDETACHED
19983                 draft7
19984 #               endif
19985
19986 _ACEOF
19987 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19988   $EGREP "draft7" >/dev/null 2>&1; then
19989   ol_cv_pthread_version=7
19990 else
19991
19992         cat >conftest.$ac_ext <<_ACEOF
19993 /* confdefs.h.  */
19994 _ACEOF
19995 cat confdefs.h >>conftest.$ac_ext
19996 cat >>conftest.$ac_ext <<_ACEOF
19997 /* end confdefs.h.  */
19998 #include <pthread.h>
19999
20000 _ACEOF
20001 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20002   $EGREP "pthread_attr_init" >/dev/null 2>&1; then
20003   ol_cv_pthread_version=6
20004 else
20005
20006         cat >conftest.$ac_ext <<_ACEOF
20007 /* confdefs.h.  */
20008 _ACEOF
20009 cat confdefs.h >>conftest.$ac_ext
20010 cat >>conftest.$ac_ext <<_ACEOF
20011 /* end confdefs.h.  */
20012
20013 #               include <pthread.h>
20014 #ifdef          PTHREAD_MUTEX_INITIALIZER
20015                 draft5
20016 #endif
20017
20018 _ACEOF
20019 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20020   $EGREP "draft5" >/dev/null 2>&1; then
20021   ol_cv_pthread_version=5
20022 else
20023   ol_cv_pthread_version=4
20024 fi
20025 rm -f conftest*
20026
20027 fi
20028 rm -f conftest*
20029
20030 fi
20031 rm -f conftest*
20032
20033 fi
20034 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20035
20036 fi
20037 echo "$as_me:$LINENO: result: $ol_cv_pthread_version" >&5
20038 echo "${ECHO_T}$ol_cv_pthread_version" >&6
20039
20040
20041                 if test $ol_cv_pthread_version != 0 ; then
20042
20043 cat >>confdefs.h <<_ACEOF
20044 #define HAVE_PTHREADS $ol_cv_pthread_version
20045 _ACEOF
20046
20047                 else
20048                         { { echo "$as_me:$LINENO: error: unknown pthread version" >&5
20049 echo "$as_me: error: unknown pthread version" >&2;}
20050    { (exit 1); exit 1; }; }
20051                 fi
20052
20053                 # consider threads found
20054                 ol_with_threads=found
20055
20056
20057         echo "$as_me:$LINENO: checking for LinuxThreads pthread.h" >&5
20058 echo $ECHO_N "checking for LinuxThreads pthread.h... $ECHO_C" >&6
20059 if test "${ol_cv_header_linux_threads+set}" = set; then
20060   echo $ECHO_N "(cached) $ECHO_C" >&6
20061 else
20062   cat >conftest.$ac_ext <<_ACEOF
20063 /* confdefs.h.  */
20064 _ACEOF
20065 cat confdefs.h >>conftest.$ac_ext
20066 cat >>conftest.$ac_ext <<_ACEOF
20067 /* end confdefs.h.  */
20068 #include <pthread.h>
20069 _ACEOF
20070 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20071   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then
20072   ol_cv_header_linux_threads=yes
20073 else
20074   ol_cv_header_linux_threads=no
20075 fi
20076 rm -f conftest*
20077
20078
20079 fi
20080 echo "$as_me:$LINENO: result: $ol_cv_header_linux_threads" >&5
20081 echo "${ECHO_T}$ol_cv_header_linux_threads" >&6
20082         if test $ol_cv_header_linux_threads = yes; then
20083
20084 cat >>confdefs.h <<\_ACEOF
20085 #define HAVE_LINUX_THREADS 1
20086 _ACEOF
20087
20088         fi
20089
20090
20091         echo "$as_me:$LINENO: checking for GNU Pth pthread.h" >&5
20092 echo $ECHO_N "checking for GNU Pth pthread.h... $ECHO_C" >&6
20093 if test "${ol_cv_header_gnu_pth_pthread_h+set}" = set; then
20094   echo $ECHO_N "(cached) $ECHO_C" >&6
20095 else
20096   cat >conftest.$ac_ext <<_ACEOF
20097 /* confdefs.h.  */
20098 _ACEOF
20099 cat confdefs.h >>conftest.$ac_ext
20100 cat >>conftest.$ac_ext <<_ACEOF
20101 /* end confdefs.h.  */
20102 #include <pthread.h>
20103 #ifdef _POSIX_THREAD_IS_GNU_PTH
20104         __gnu_pth__;
20105 #endif
20106
20107 _ACEOF
20108 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20109   $EGREP "__gnu_pth__" >/dev/null 2>&1; then
20110   ol_cv_header_gnu_pth_pthread_h=yes
20111 else
20112   ol_cv_header_gnu_pth_pthread_h=no
20113 fi
20114 rm -f conftest*
20115
20116
20117 fi
20118 echo "$as_me:$LINENO: result: $ol_cv_header_gnu_pth_pthread_h" >&5
20119 echo "${ECHO_T}$ol_cv_header_gnu_pth_pthread_h" >&6
20120
20121
20122                 if test $ol_cv_header_gnu_pth_pthread_h = no ; then
20123
20124 for ac_header in sched.h
20125 do
20126 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
20127 if eval "test \"\${$as_ac_Header+set}\" = set"; then
20128   echo "$as_me:$LINENO: checking for $ac_header" >&5
20129 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20130 if eval "test \"\${$as_ac_Header+set}\" = set"; then
20131   echo $ECHO_N "(cached) $ECHO_C" >&6
20132 fi
20133 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20134 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
20135 else
20136   # Is the header compilable?
20137 echo "$as_me:$LINENO: checking $ac_header usability" >&5
20138 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
20139 cat >conftest.$ac_ext <<_ACEOF
20140 /* confdefs.h.  */
20141 _ACEOF
20142 cat confdefs.h >>conftest.$ac_ext
20143 cat >>conftest.$ac_ext <<_ACEOF
20144 /* end confdefs.h.  */
20145 $ac_includes_default
20146 #include <$ac_header>
20147 _ACEOF
20148 rm -f conftest.$ac_objext
20149 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20150   (eval $ac_compile) 2>conftest.er1
20151   ac_status=$?
20152   grep -v '^ *+' conftest.er1 >conftest.err
20153   rm -f conftest.er1
20154   cat conftest.err >&5
20155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20156   (exit $ac_status); } &&
20157          { ac_try='test -z "$ac_c_werror_flag"
20158                          || test ! -s conftest.err'
20159   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20160   (eval $ac_try) 2>&5
20161   ac_status=$?
20162   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20163   (exit $ac_status); }; } &&
20164          { ac_try='test -s conftest.$ac_objext'
20165   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20166   (eval $ac_try) 2>&5
20167   ac_status=$?
20168   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20169   (exit $ac_status); }; }; then
20170   ac_header_compiler=yes
20171 else
20172   echo "$as_me: failed program was:" >&5
20173 sed 's/^/| /' conftest.$ac_ext >&5
20174
20175 ac_header_compiler=no
20176 fi
20177 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20178 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20179 echo "${ECHO_T}$ac_header_compiler" >&6
20180
20181 # Is the header present?
20182 echo "$as_me:$LINENO: checking $ac_header presence" >&5
20183 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
20184 cat >conftest.$ac_ext <<_ACEOF
20185 /* confdefs.h.  */
20186 _ACEOF
20187 cat confdefs.h >>conftest.$ac_ext
20188 cat >>conftest.$ac_ext <<_ACEOF
20189 /* end confdefs.h.  */
20190 #include <$ac_header>
20191 _ACEOF
20192 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
20193   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20194   ac_status=$?
20195   grep -v '^ *+' conftest.er1 >conftest.err
20196   rm -f conftest.er1
20197   cat conftest.err >&5
20198   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20199   (exit $ac_status); } >/dev/null; then
20200   if test -s conftest.err; then
20201     ac_cpp_err=$ac_c_preproc_warn_flag
20202     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
20203   else
20204     ac_cpp_err=
20205   fi
20206 else
20207   ac_cpp_err=yes
20208 fi
20209 if test -z "$ac_cpp_err"; then
20210   ac_header_preproc=yes
20211 else
20212   echo "$as_me: failed program was:" >&5
20213 sed 's/^/| /' conftest.$ac_ext >&5
20214
20215   ac_header_preproc=no
20216 fi
20217 rm -f conftest.err conftest.$ac_ext
20218 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20219 echo "${ECHO_T}$ac_header_preproc" >&6
20220
20221 # So?  What about this header?
20222 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20223   yes:no: )
20224     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20225 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
20226     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20227 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20228     ac_header_preproc=yes
20229     ;;
20230   no:yes:* )
20231     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20232 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
20233     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
20234 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
20235     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20236 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20237     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
20238 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
20239     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20240 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
20241     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20242 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
20243     (
20244       cat <<\_ASBOX
20245 ## --------------------------------------------- ##
20246 ## Report this to <http://www.openldap.org/its/> ##
20247 ## --------------------------------------------- ##
20248 _ASBOX
20249     ) |
20250       sed "s/^/$as_me: WARNING:     /" >&2
20251     ;;
20252 esac
20253 echo "$as_me:$LINENO: checking for $ac_header" >&5
20254 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20255 if eval "test \"\${$as_ac_Header+set}\" = set"; then
20256   echo $ECHO_N "(cached) $ECHO_C" >&6
20257 else
20258   eval "$as_ac_Header=\$ac_header_preproc"
20259 fi
20260 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20261 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
20262
20263 fi
20264 if test `eval echo '${'$as_ac_Header'}'` = yes; then
20265   cat >>confdefs.h <<_ACEOF
20266 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
20267 _ACEOF
20268
20269 fi
20270
20271 done
20272
20273                 fi
20274
20275
20276                                 echo "$as_me:$LINENO: checking for pthread_create in default libraries" >&5
20277 echo $ECHO_N "checking for pthread_create in default libraries... $ECHO_C" >&6
20278 if test "${ol_cv_pthread_create+set}" = set; then
20279   echo $ECHO_N "(cached) $ECHO_C" >&6
20280 else
20281
20282                         if test "$cross_compiling" = yes; then
20283   cat >conftest.$ac_ext <<_ACEOF
20284 /* confdefs.h.  */
20285 _ACEOF
20286 cat confdefs.h >>conftest.$ac_ext
20287 cat >>conftest.$ac_ext <<_ACEOF
20288 /* end confdefs.h.  */
20289
20290 /* pthread test headers */
20291 #include <pthread.h>
20292 #if HAVE_PTHREADS < 7
20293 #include <errno.h>
20294 #endif
20295 #ifndef NULL
20296 #define NULL (void*)0
20297 #endif
20298
20299 static void *task(p)
20300         void *p;
20301 {
20302         return (void *) (p == NULL);
20303 }
20304
20305 int
20306 main ()
20307 {
20308
20309         /* pthread test function */
20310 #ifndef PTHREAD_CREATE_DETACHED
20311 #define PTHREAD_CREATE_DETACHED 1
20312 #endif
20313         pthread_t t;
20314         int status;
20315         int detach = PTHREAD_CREATE_DETACHED;
20316
20317 #if HAVE_PTHREADS > 4
20318         /* Final pthreads */
20319         pthread_attr_t attr;
20320
20321         status = pthread_attr_init(&attr);
20322         if( status ) return status;
20323
20324 #if HAVE_PTHREADS < 7
20325         status = pthread_attr_setdetachstate(&attr, &detach);
20326         if( status < 0 ) status = errno;
20327 #else
20328         status = pthread_attr_setdetachstate(&attr, detach);
20329 #endif
20330         if( status ) return status;
20331         status = pthread_create( &t, &attr, task, NULL );
20332 #if HAVE_PTHREADS < 7
20333         if( status < 0 ) status = errno;
20334 #endif
20335         if( status ) return status;
20336 #else
20337         /* Draft 4 pthreads */
20338         status = pthread_create( &t, pthread_attr_default, task, NULL );
20339         if( status ) return errno;
20340
20341         /* give thread a chance to complete */
20342         /* it should remain joinable and hence detachable */
20343         sleep( 1 );
20344
20345         status = pthread_detach( &t );
20346         if( status ) return errno;
20347 #endif
20348
20349 #ifdef HAVE_LINUX_THREADS
20350         pthread_kill_other_threads_np();
20351 #endif
20352
20353         return 0;
20354
20355   ;
20356   return 0;
20357 }
20358 _ACEOF
20359 rm -f conftest.$ac_objext conftest$ac_exeext
20360 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20361   (eval $ac_link) 2>conftest.er1
20362   ac_status=$?
20363   grep -v '^ *+' conftest.er1 >conftest.err
20364   rm -f conftest.er1
20365   cat conftest.err >&5
20366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20367   (exit $ac_status); } &&
20368          { ac_try='test -z "$ac_c_werror_flag"
20369                          || test ! -s conftest.err'
20370   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20371   (eval $ac_try) 2>&5
20372   ac_status=$?
20373   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20374   (exit $ac_status); }; } &&
20375          { ac_try='test -s conftest$ac_exeext'
20376   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20377   (eval $ac_try) 2>&5
20378   ac_status=$?
20379   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20380   (exit $ac_status); }; }; then
20381   ol_cv_pthread_create=yes
20382 else
20383   echo "$as_me: failed program was:" >&5
20384 sed 's/^/| /' conftest.$ac_ext >&5
20385
20386 ol_cv_pthread_create=no
20387 fi
20388 rm -f conftest.err conftest.$ac_objext \
20389       conftest$ac_exeext conftest.$ac_ext
20390 else
20391   cat >conftest.$ac_ext <<_ACEOF
20392 /* confdefs.h.  */
20393 _ACEOF
20394 cat confdefs.h >>conftest.$ac_ext
20395 cat >>conftest.$ac_ext <<_ACEOF
20396 /* end confdefs.h.  */
20397
20398 /* pthread test headers */
20399 #include <pthread.h>
20400 #if HAVE_PTHREADS < 7
20401 #include <errno.h>
20402 #endif
20403 #ifndef NULL
20404 #define NULL (void*)0
20405 #endif
20406
20407 static void *task(p)
20408         void *p;
20409 {
20410         return (void *) (p == NULL);
20411 }
20412
20413
20414 int main(argc, argv)
20415         int argc;
20416         char **argv;
20417 {
20418
20419         /* pthread test function */
20420 #ifndef PTHREAD_CREATE_DETACHED
20421 #define PTHREAD_CREATE_DETACHED 1
20422 #endif
20423         pthread_t t;
20424         int status;
20425         int detach = PTHREAD_CREATE_DETACHED;
20426
20427 #if HAVE_PTHREADS > 4
20428         /* Final pthreads */
20429         pthread_attr_t attr;
20430
20431         status = pthread_attr_init(&attr);
20432         if( status ) return status;
20433
20434 #if HAVE_PTHREADS < 7
20435         status = pthread_attr_setdetachstate(&attr, &detach);
20436         if( status < 0 ) status = errno;
20437 #else
20438         status = pthread_attr_setdetachstate(&attr, detach);
20439 #endif
20440         if( status ) return status;
20441         status = pthread_create( &t, &attr, task, NULL );
20442 #if HAVE_PTHREADS < 7
20443         if( status < 0 ) status = errno;
20444 #endif
20445         if( status ) return status;
20446 #else
20447         /* Draft 4 pthreads */
20448         status = pthread_create( &t, pthread_attr_default, task, NULL );
20449         if( status ) return errno;
20450
20451         /* give thread a chance to complete */
20452         /* it should remain joinable and hence detachable */
20453         sleep( 1 );
20454
20455         status = pthread_detach( &t );
20456         if( status ) return errno;
20457 #endif
20458
20459 #ifdef HAVE_LINUX_THREADS
20460         pthread_kill_other_threads_np();
20461 #endif
20462
20463         return 0;
20464
20465 }
20466
20467 _ACEOF
20468 rm -f conftest$ac_exeext
20469 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20470   (eval $ac_link) 2>&5
20471   ac_status=$?
20472   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20473   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20474   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20475   (eval $ac_try) 2>&5
20476   ac_status=$?
20477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20478   (exit $ac_status); }; }; then
20479   ol_cv_pthread_create=yes
20480 else
20481   echo "$as_me: program exited with status $ac_status" >&5
20482 echo "$as_me: failed program was:" >&5
20483 sed 's/^/| /' conftest.$ac_ext >&5
20484
20485 ( exit $ac_status )
20486 ol_cv_pthread_create=no
20487 fi
20488 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20489 fi
20490 fi
20491 echo "$as_me:$LINENO: result: $ol_cv_pthread_create" >&5
20492 echo "${ECHO_T}$ol_cv_pthread_create" >&6
20493
20494                 if test $ol_cv_pthread_create != no ; then
20495                         ol_link_threads=posix
20496                         ol_link_pthreads=""
20497                 fi
20498
20499                 # Pthread try link: -kthread (ol_cv_pthread_kthread)
20500 if test "$ol_link_threads" = no ; then
20501         # try -kthread
20502         echo "$as_me:$LINENO: checking for pthread link with -kthread" >&5
20503 echo $ECHO_N "checking for pthread link with -kthread... $ECHO_C" >&6
20504 if test "${ol_cv_pthread_kthread+set}" = set; then
20505   echo $ECHO_N "(cached) $ECHO_C" >&6
20506 else
20507
20508                 # save the flags
20509                 ol_LIBS="$LIBS"
20510                 LIBS="-kthread $LIBS"
20511
20512                 if test "$cross_compiling" = yes; then
20513   cat >conftest.$ac_ext <<_ACEOF
20514 /* confdefs.h.  */
20515 _ACEOF
20516 cat confdefs.h >>conftest.$ac_ext
20517 cat >>conftest.$ac_ext <<_ACEOF
20518 /* end confdefs.h.  */
20519
20520 /* pthread test headers */
20521 #include <pthread.h>
20522 #if HAVE_PTHREADS < 7
20523 #include <errno.h>
20524 #endif
20525 #ifndef NULL
20526 #define NULL (void*)0
20527 #endif
20528
20529 static void *task(p)
20530         void *p;
20531 {
20532         return (void *) (p == NULL);
20533 }
20534
20535 int
20536 main ()
20537 {
20538
20539         /* pthread test function */
20540 #ifndef PTHREAD_CREATE_DETACHED
20541 #define PTHREAD_CREATE_DETACHED 1
20542 #endif
20543         pthread_t t;
20544         int status;
20545         int detach = PTHREAD_CREATE_DETACHED;
20546
20547 #if HAVE_PTHREADS > 4
20548         /* Final pthreads */
20549         pthread_attr_t attr;
20550
20551         status = pthread_attr_init(&attr);
20552         if( status ) return status;
20553
20554 #if HAVE_PTHREADS < 7
20555         status = pthread_attr_setdetachstate(&attr, &detach);
20556         if( status < 0 ) status = errno;
20557 #else
20558         status = pthread_attr_setdetachstate(&attr, detach);
20559 #endif
20560         if( status ) return status;
20561         status = pthread_create( &t, &attr, task, NULL );
20562 #if HAVE_PTHREADS < 7
20563         if( status < 0 ) status = errno;
20564 #endif
20565         if( status ) return status;
20566 #else
20567         /* Draft 4 pthreads */
20568         status = pthread_create( &t, pthread_attr_default, task, NULL );
20569         if( status ) return errno;
20570
20571         /* give thread a chance to complete */
20572         /* it should remain joinable and hence detachable */
20573         sleep( 1 );
20574
20575         status = pthread_detach( &t );
20576         if( status ) return errno;
20577 #endif
20578
20579 #ifdef HAVE_LINUX_THREADS
20580         pthread_kill_other_threads_np();
20581 #endif
20582
20583         return 0;
20584
20585   ;
20586   return 0;
20587 }
20588 _ACEOF
20589 rm -f conftest.$ac_objext conftest$ac_exeext
20590 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20591   (eval $ac_link) 2>conftest.er1
20592   ac_status=$?
20593   grep -v '^ *+' conftest.er1 >conftest.err
20594   rm -f conftest.er1
20595   cat conftest.err >&5
20596   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20597   (exit $ac_status); } &&
20598          { ac_try='test -z "$ac_c_werror_flag"
20599                          || test ! -s conftest.err'
20600   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20601   (eval $ac_try) 2>&5
20602   ac_status=$?
20603   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20604   (exit $ac_status); }; } &&
20605          { ac_try='test -s conftest$ac_exeext'
20606   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20607   (eval $ac_try) 2>&5
20608   ac_status=$?
20609   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20610   (exit $ac_status); }; }; then
20611   ol_cv_pthread_kthread=yes
20612 else
20613   echo "$as_me: failed program was:" >&5
20614 sed 's/^/| /' conftest.$ac_ext >&5
20615
20616 ol_cv_pthread_kthread=no
20617 fi
20618 rm -f conftest.err conftest.$ac_objext \
20619       conftest$ac_exeext conftest.$ac_ext
20620 else
20621   cat >conftest.$ac_ext <<_ACEOF
20622 /* confdefs.h.  */
20623 _ACEOF
20624 cat confdefs.h >>conftest.$ac_ext
20625 cat >>conftest.$ac_ext <<_ACEOF
20626 /* end confdefs.h.  */
20627
20628 /* pthread test headers */
20629 #include <pthread.h>
20630 #if HAVE_PTHREADS < 7
20631 #include <errno.h>
20632 #endif
20633 #ifndef NULL
20634 #define NULL (void*)0
20635 #endif
20636
20637 static void *task(p)
20638         void *p;
20639 {
20640         return (void *) (p == NULL);
20641 }
20642
20643
20644 int main(argc, argv)
20645         int argc;
20646         char **argv;
20647 {
20648
20649         /* pthread test function */
20650 #ifndef PTHREAD_CREATE_DETACHED
20651 #define PTHREAD_CREATE_DETACHED 1
20652 #endif
20653         pthread_t t;
20654         int status;
20655         int detach = PTHREAD_CREATE_DETACHED;
20656
20657 #if HAVE_PTHREADS > 4
20658         /* Final pthreads */
20659         pthread_attr_t attr;
20660
20661         status = pthread_attr_init(&attr);
20662         if( status ) return status;
20663
20664 #if HAVE_PTHREADS < 7
20665         status = pthread_attr_setdetachstate(&attr, &detach);
20666         if( status < 0 ) status = errno;
20667 #else
20668         status = pthread_attr_setdetachstate(&attr, detach);
20669 #endif
20670         if( status ) return status;
20671         status = pthread_create( &t, &attr, task, NULL );
20672 #if HAVE_PTHREADS < 7
20673         if( status < 0 ) status = errno;
20674 #endif
20675         if( status ) return status;
20676 #else
20677         /* Draft 4 pthreads */
20678         status = pthread_create( &t, pthread_attr_default, task, NULL );
20679         if( status ) return errno;
20680
20681         /* give thread a chance to complete */
20682         /* it should remain joinable and hence detachable */
20683         sleep( 1 );
20684
20685         status = pthread_detach( &t );
20686         if( status ) return errno;
20687 #endif
20688
20689 #ifdef HAVE_LINUX_THREADS
20690         pthread_kill_other_threads_np();
20691 #endif
20692
20693         return 0;
20694
20695 }
20696
20697 _ACEOF
20698 rm -f conftest$ac_exeext
20699 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20700   (eval $ac_link) 2>&5
20701   ac_status=$?
20702   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20703   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20704   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20705   (eval $ac_try) 2>&5
20706   ac_status=$?
20707   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20708   (exit $ac_status); }; }; then
20709   ol_cv_pthread_kthread=yes
20710 else
20711   echo "$as_me: program exited with status $ac_status" >&5
20712 echo "$as_me: failed program was:" >&5
20713 sed 's/^/| /' conftest.$ac_ext >&5
20714
20715 ( exit $ac_status )
20716 ol_cv_pthread_kthread=no
20717 fi
20718 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20719 fi
20720
20721                 # restore the LIBS
20722                 LIBS="$ol_LIBS"
20723
20724 fi
20725 echo "$as_me:$LINENO: result: $ol_cv_pthread_kthread" >&5
20726 echo "${ECHO_T}$ol_cv_pthread_kthread" >&6
20727
20728         if test $ol_cv_pthread_kthread = yes ; then
20729                 ol_link_pthreads="-kthread"
20730                 ol_link_threads=posix
20731         fi
20732 fi
20733
20734                 # Pthread try link: -pthread (ol_cv_pthread_pthread)
20735 if test "$ol_link_threads" = no ; then
20736         # try -pthread
20737         echo "$as_me:$LINENO: checking for pthread link with -pthread" >&5
20738 echo $ECHO_N "checking for pthread link with -pthread... $ECHO_C" >&6
20739 if test "${ol_cv_pthread_pthread+set}" = set; then
20740   echo $ECHO_N "(cached) $ECHO_C" >&6
20741 else
20742
20743                 # save the flags
20744                 ol_LIBS="$LIBS"
20745                 LIBS="-pthread $LIBS"
20746
20747                 if test "$cross_compiling" = yes; then
20748   cat >conftest.$ac_ext <<_ACEOF
20749 /* confdefs.h.  */
20750 _ACEOF
20751 cat confdefs.h >>conftest.$ac_ext
20752 cat >>conftest.$ac_ext <<_ACEOF
20753 /* end confdefs.h.  */
20754
20755 /* pthread test headers */
20756 #include <pthread.h>
20757 #if HAVE_PTHREADS < 7
20758 #include <errno.h>
20759 #endif
20760 #ifndef NULL
20761 #define NULL (void*)0
20762 #endif
20763
20764 static void *task(p)
20765         void *p;
20766 {
20767         return (void *) (p == NULL);
20768 }
20769
20770 int
20771 main ()
20772 {
20773
20774         /* pthread test function */
20775 #ifndef PTHREAD_CREATE_DETACHED
20776 #define PTHREAD_CREATE_DETACHED 1
20777 #endif
20778         pthread_t t;
20779         int status;
20780         int detach = PTHREAD_CREATE_DETACHED;
20781
20782 #if HAVE_PTHREADS > 4
20783         /* Final pthreads */
20784         pthread_attr_t attr;
20785
20786         status = pthread_attr_init(&attr);
20787         if( status ) return status;
20788
20789 #if HAVE_PTHREADS < 7
20790         status = pthread_attr_setdetachstate(&attr, &detach);
20791         if( status < 0 ) status = errno;
20792 #else
20793         status = pthread_attr_setdetachstate(&attr, detach);
20794 #endif
20795         if( status ) return status;
20796         status = pthread_create( &t, &attr, task, NULL );
20797 #if HAVE_PTHREADS < 7
20798         if( status < 0 ) status = errno;
20799 #endif
20800         if( status ) return status;
20801 #else
20802         /* Draft 4 pthreads */
20803         status = pthread_create( &t, pthread_attr_default, task, NULL );
20804         if( status ) return errno;
20805
20806         /* give thread a chance to complete */
20807         /* it should remain joinable and hence detachable */
20808         sleep( 1 );
20809
20810         status = pthread_detach( &t );
20811         if( status ) return errno;
20812 #endif
20813
20814 #ifdef HAVE_LINUX_THREADS
20815         pthread_kill_other_threads_np();
20816 #endif
20817
20818         return 0;
20819
20820   ;
20821   return 0;
20822 }
20823 _ACEOF
20824 rm -f conftest.$ac_objext conftest$ac_exeext
20825 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20826   (eval $ac_link) 2>conftest.er1
20827   ac_status=$?
20828   grep -v '^ *+' conftest.er1 >conftest.err
20829   rm -f conftest.er1
20830   cat conftest.err >&5
20831   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20832   (exit $ac_status); } &&
20833          { ac_try='test -z "$ac_c_werror_flag"
20834                          || test ! -s conftest.err'
20835   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20836   (eval $ac_try) 2>&5
20837   ac_status=$?
20838   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20839   (exit $ac_status); }; } &&
20840          { ac_try='test -s conftest$ac_exeext'
20841   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20842   (eval $ac_try) 2>&5
20843   ac_status=$?
20844   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20845   (exit $ac_status); }; }; then
20846   ol_cv_pthread_pthread=yes
20847 else
20848   echo "$as_me: failed program was:" >&5
20849 sed 's/^/| /' conftest.$ac_ext >&5
20850
20851 ol_cv_pthread_pthread=no
20852 fi
20853 rm -f conftest.err conftest.$ac_objext \
20854       conftest$ac_exeext conftest.$ac_ext
20855 else
20856   cat >conftest.$ac_ext <<_ACEOF
20857 /* confdefs.h.  */
20858 _ACEOF
20859 cat confdefs.h >>conftest.$ac_ext
20860 cat >>conftest.$ac_ext <<_ACEOF
20861 /* end confdefs.h.  */
20862
20863 /* pthread test headers */
20864 #include <pthread.h>
20865 #if HAVE_PTHREADS < 7
20866 #include <errno.h>
20867 #endif
20868 #ifndef NULL
20869 #define NULL (void*)0
20870 #endif
20871
20872 static void *task(p)
20873         void *p;
20874 {
20875         return (void *) (p == NULL);
20876 }
20877
20878
20879 int main(argc, argv)
20880         int argc;
20881         char **argv;
20882 {
20883
20884         /* pthread test function */
20885 #ifndef PTHREAD_CREATE_DETACHED
20886 #define PTHREAD_CREATE_DETACHED 1
20887 #endif
20888         pthread_t t;
20889         int status;
20890         int detach = PTHREAD_CREATE_DETACHED;
20891
20892 #if HAVE_PTHREADS > 4
20893         /* Final pthreads */
20894         pthread_attr_t attr;
20895
20896         status = pthread_attr_init(&attr);
20897         if( status ) return status;
20898
20899 #if HAVE_PTHREADS < 7
20900         status = pthread_attr_setdetachstate(&attr, &detach);
20901         if( status < 0 ) status = errno;
20902 #else
20903         status = pthread_attr_setdetachstate(&attr, detach);
20904 #endif
20905         if( status ) return status;
20906         status = pthread_create( &t, &attr, task, NULL );
20907 #if HAVE_PTHREADS < 7
20908         if( status < 0 ) status = errno;
20909 #endif
20910         if( status ) return status;
20911 #else
20912         /* Draft 4 pthreads */
20913         status = pthread_create( &t, pthread_attr_default, task, NULL );
20914         if( status ) return errno;
20915
20916         /* give thread a chance to complete */
20917         /* it should remain joinable and hence detachable */
20918         sleep( 1 );
20919
20920         status = pthread_detach( &t );
20921         if( status ) return errno;
20922 #endif
20923
20924 #ifdef HAVE_LINUX_THREADS
20925         pthread_kill_other_threads_np();
20926 #endif
20927
20928         return 0;
20929
20930 }
20931
20932 _ACEOF
20933 rm -f conftest$ac_exeext
20934 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20935   (eval $ac_link) 2>&5
20936   ac_status=$?
20937   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20938   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20939   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20940   (eval $ac_try) 2>&5
20941   ac_status=$?
20942   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20943   (exit $ac_status); }; }; then
20944   ol_cv_pthread_pthread=yes
20945 else
20946   echo "$as_me: program exited with status $ac_status" >&5
20947 echo "$as_me: failed program was:" >&5
20948 sed 's/^/| /' conftest.$ac_ext >&5
20949
20950 ( exit $ac_status )
20951 ol_cv_pthread_pthread=no
20952 fi
20953 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20954 fi
20955
20956                 # restore the LIBS
20957                 LIBS="$ol_LIBS"
20958
20959 fi
20960 echo "$as_me:$LINENO: result: $ol_cv_pthread_pthread" >&5
20961 echo "${ECHO_T}$ol_cv_pthread_pthread" >&6
20962
20963         if test $ol_cv_pthread_pthread = yes ; then
20964                 ol_link_pthreads="-pthread"
20965                 ol_link_threads=posix
20966         fi
20967 fi
20968
20969                 # Pthread try link: -pthreads (ol_cv_pthread_pthreads)
20970 if test "$ol_link_threads" = no ; then
20971         # try -pthreads
20972         echo "$as_me:$LINENO: checking for pthread link with -pthreads" >&5
20973 echo $ECHO_N "checking for pthread link with -pthreads... $ECHO_C" >&6
20974 if test "${ol_cv_pthread_pthreads+set}" = set; then
20975   echo $ECHO_N "(cached) $ECHO_C" >&6
20976 else
20977
20978                 # save the flags
20979                 ol_LIBS="$LIBS"
20980                 LIBS="-pthreads $LIBS"
20981
20982                 if test "$cross_compiling" = yes; then
20983   cat >conftest.$ac_ext <<_ACEOF
20984 /* confdefs.h.  */
20985 _ACEOF
20986 cat confdefs.h >>conftest.$ac_ext
20987 cat >>conftest.$ac_ext <<_ACEOF
20988 /* end confdefs.h.  */
20989
20990 /* pthread test headers */
20991 #include <pthread.h>
20992 #if HAVE_PTHREADS < 7
20993 #include <errno.h>
20994 #endif
20995 #ifndef NULL
20996 #define NULL (void*)0
20997 #endif
20998
20999 static void *task(p)
21000         void *p;
21001 {
21002         return (void *) (p == NULL);
21003 }
21004
21005 int
21006 main ()
21007 {
21008
21009         /* pthread test function */
21010 #ifndef PTHREAD_CREATE_DETACHED
21011 #define PTHREAD_CREATE_DETACHED 1
21012 #endif
21013         pthread_t t;
21014         int status;
21015         int detach = PTHREAD_CREATE_DETACHED;
21016
21017 #if HAVE_PTHREADS > 4
21018         /* Final pthreads */
21019         pthread_attr_t attr;
21020
21021         status = pthread_attr_init(&attr);
21022         if( status ) return status;
21023
21024 #if HAVE_PTHREADS < 7
21025         status = pthread_attr_setdetachstate(&attr, &detach);
21026         if( status < 0 ) status = errno;
21027 #else
21028         status = pthread_attr_setdetachstate(&attr, detach);
21029 #endif
21030         if( status ) return status;
21031         status = pthread_create( &t, &attr, task, NULL );
21032 #if HAVE_PTHREADS < 7
21033         if( status < 0 ) status = errno;
21034 #endif
21035         if( status ) return status;
21036 #else
21037         /* Draft 4 pthreads */
21038         status = pthread_create( &t, pthread_attr_default, task, NULL );
21039         if( status ) return errno;
21040
21041         /* give thread a chance to complete */
21042         /* it should remain joinable and hence detachable */
21043         sleep( 1 );
21044
21045         status = pthread_detach( &t );
21046         if( status ) return errno;
21047 #endif
21048
21049 #ifdef HAVE_LINUX_THREADS
21050         pthread_kill_other_threads_np();
21051 #endif
21052
21053         return 0;
21054
21055   ;
21056   return 0;
21057 }
21058 _ACEOF
21059 rm -f conftest.$ac_objext conftest$ac_exeext
21060 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21061   (eval $ac_link) 2>conftest.er1
21062   ac_status=$?
21063   grep -v '^ *+' conftest.er1 >conftest.err
21064   rm -f conftest.er1
21065   cat conftest.err >&5
21066   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21067   (exit $ac_status); } &&
21068          { ac_try='test -z "$ac_c_werror_flag"
21069                          || test ! -s conftest.err'
21070   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21071   (eval $ac_try) 2>&5
21072   ac_status=$?
21073   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21074   (exit $ac_status); }; } &&
21075          { ac_try='test -s conftest$ac_exeext'
21076   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21077   (eval $ac_try) 2>&5
21078   ac_status=$?
21079   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21080   (exit $ac_status); }; }; then
21081   ol_cv_pthread_pthreads=yes
21082 else
21083   echo "$as_me: failed program was:" >&5
21084 sed 's/^/| /' conftest.$ac_ext >&5
21085
21086 ol_cv_pthread_pthreads=no
21087 fi
21088 rm -f conftest.err conftest.$ac_objext \
21089       conftest$ac_exeext conftest.$ac_ext
21090 else
21091   cat >conftest.$ac_ext <<_ACEOF
21092 /* confdefs.h.  */
21093 _ACEOF
21094 cat confdefs.h >>conftest.$ac_ext
21095 cat >>conftest.$ac_ext <<_ACEOF
21096 /* end confdefs.h.  */
21097
21098 /* pthread test headers */
21099 #include <pthread.h>
21100 #if HAVE_PTHREADS < 7
21101 #include <errno.h>
21102 #endif
21103 #ifndef NULL
21104 #define NULL (void*)0
21105 #endif
21106
21107 static void *task(p)
21108         void *p;
21109 {
21110         return (void *) (p == NULL);
21111 }
21112
21113
21114 int main(argc, argv)
21115         int argc;
21116         char **argv;
21117 {
21118
21119         /* pthread test function */
21120 #ifndef PTHREAD_CREATE_DETACHED
21121 #define PTHREAD_CREATE_DETACHED 1
21122 #endif
21123         pthread_t t;
21124         int status;
21125         int detach = PTHREAD_CREATE_DETACHED;
21126
21127 #if HAVE_PTHREADS > 4
21128         /* Final pthreads */
21129         pthread_attr_t attr;
21130
21131         status = pthread_attr_init(&attr);
21132         if( status ) return status;
21133
21134 #if HAVE_PTHREADS < 7
21135         status = pthread_attr_setdetachstate(&attr, &detach);
21136         if( status < 0 ) status = errno;
21137 #else
21138         status = pthread_attr_setdetachstate(&attr, detach);
21139 #endif
21140         if( status ) return status;
21141         status = pthread_create( &t, &attr, task, NULL );
21142 #if HAVE_PTHREADS < 7
21143         if( status < 0 ) status = errno;
21144 #endif
21145         if( status ) return status;
21146 #else
21147         /* Draft 4 pthreads */
21148         status = pthread_create( &t, pthread_attr_default, task, NULL );
21149         if( status ) return errno;
21150
21151         /* give thread a chance to complete */
21152         /* it should remain joinable and hence detachable */
21153         sleep( 1 );
21154
21155         status = pthread_detach( &t );
21156         if( status ) return errno;
21157 #endif
21158
21159 #ifdef HAVE_LINUX_THREADS
21160         pthread_kill_other_threads_np();
21161 #endif
21162
21163         return 0;
21164
21165 }
21166
21167 _ACEOF
21168 rm -f conftest$ac_exeext
21169 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21170   (eval $ac_link) 2>&5
21171   ac_status=$?
21172   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21173   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21174   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21175   (eval $ac_try) 2>&5
21176   ac_status=$?
21177   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21178   (exit $ac_status); }; }; then
21179   ol_cv_pthread_pthreads=yes
21180 else
21181   echo "$as_me: program exited with status $ac_status" >&5
21182 echo "$as_me: failed program was:" >&5
21183 sed 's/^/| /' conftest.$ac_ext >&5
21184
21185 ( exit $ac_status )
21186 ol_cv_pthread_pthreads=no
21187 fi
21188 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21189 fi
21190
21191                 # restore the LIBS
21192                 LIBS="$ol_LIBS"
21193
21194 fi
21195 echo "$as_me:$LINENO: result: $ol_cv_pthread_pthreads" >&5
21196 echo "${ECHO_T}$ol_cv_pthread_pthreads" >&6
21197
21198         if test $ol_cv_pthread_pthreads = yes ; then
21199                 ol_link_pthreads="-pthreads"
21200                 ol_link_threads=posix
21201         fi
21202 fi
21203
21204                 # Pthread try link: -mthreads (ol_cv_pthread_mthreads)
21205 if test "$ol_link_threads" = no ; then
21206         # try -mthreads
21207         echo "$as_me:$LINENO: checking for pthread link with -mthreads" >&5
21208 echo $ECHO_N "checking for pthread link with -mthreads... $ECHO_C" >&6
21209 if test "${ol_cv_pthread_mthreads+set}" = set; then
21210   echo $ECHO_N "(cached) $ECHO_C" >&6
21211 else
21212
21213                 # save the flags
21214                 ol_LIBS="$LIBS"
21215                 LIBS="-mthreads $LIBS"
21216
21217                 if test "$cross_compiling" = yes; then
21218   cat >conftest.$ac_ext <<_ACEOF
21219 /* confdefs.h.  */
21220 _ACEOF
21221 cat confdefs.h >>conftest.$ac_ext
21222 cat >>conftest.$ac_ext <<_ACEOF
21223 /* end confdefs.h.  */
21224
21225 /* pthread test headers */
21226 #include <pthread.h>
21227 #if HAVE_PTHREADS < 7
21228 #include <errno.h>
21229 #endif
21230 #ifndef NULL
21231 #define NULL (void*)0
21232 #endif
21233
21234 static void *task(p)
21235         void *p;
21236 {
21237         return (void *) (p == NULL);
21238 }
21239
21240 int
21241 main ()
21242 {
21243
21244         /* pthread test function */
21245 #ifndef PTHREAD_CREATE_DETACHED
21246 #define PTHREAD_CREATE_DETACHED 1
21247 #endif
21248         pthread_t t;
21249         int status;
21250         int detach = PTHREAD_CREATE_DETACHED;
21251
21252 #if HAVE_PTHREADS > 4
21253         /* Final pthreads */
21254         pthread_attr_t attr;
21255
21256         status = pthread_attr_init(&attr);
21257         if( status ) return status;
21258
21259 #if HAVE_PTHREADS < 7
21260         status = pthread_attr_setdetachstate(&attr, &detach);
21261         if( status < 0 ) status = errno;
21262 #else
21263         status = pthread_attr_setdetachstate(&attr, detach);
21264 #endif
21265         if( status ) return status;
21266         status = pthread_create( &t, &attr, task, NULL );
21267 #if HAVE_PTHREADS < 7
21268         if( status < 0 ) status = errno;
21269 #endif
21270         if( status ) return status;
21271 #else
21272         /* Draft 4 pthreads */
21273         status = pthread_create( &t, pthread_attr_default, task, NULL );
21274         if( status ) return errno;
21275
21276         /* give thread a chance to complete */
21277         /* it should remain joinable and hence detachable */
21278         sleep( 1 );
21279
21280         status = pthread_detach( &t );
21281         if( status ) return errno;
21282 #endif
21283
21284 #ifdef HAVE_LINUX_THREADS
21285         pthread_kill_other_threads_np();
21286 #endif
21287
21288         return 0;
21289
21290   ;
21291   return 0;
21292 }
21293 _ACEOF
21294 rm -f conftest.$ac_objext conftest$ac_exeext
21295 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21296   (eval $ac_link) 2>conftest.er1
21297   ac_status=$?
21298   grep -v '^ *+' conftest.er1 >conftest.err
21299   rm -f conftest.er1
21300   cat conftest.err >&5
21301   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21302   (exit $ac_status); } &&
21303          { ac_try='test -z "$ac_c_werror_flag"
21304                          || test ! -s conftest.err'
21305   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21306   (eval $ac_try) 2>&5
21307   ac_status=$?
21308   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21309   (exit $ac_status); }; } &&
21310          { ac_try='test -s conftest$ac_exeext'
21311   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21312   (eval $ac_try) 2>&5
21313   ac_status=$?
21314   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21315   (exit $ac_status); }; }; then
21316   ol_cv_pthread_mthreads=yes
21317 else
21318   echo "$as_me: failed program was:" >&5
21319 sed 's/^/| /' conftest.$ac_ext >&5
21320
21321 ol_cv_pthread_mthreads=no
21322 fi
21323 rm -f conftest.err conftest.$ac_objext \
21324       conftest$ac_exeext conftest.$ac_ext
21325 else
21326   cat >conftest.$ac_ext <<_ACEOF
21327 /* confdefs.h.  */
21328 _ACEOF
21329 cat confdefs.h >>conftest.$ac_ext
21330 cat >>conftest.$ac_ext <<_ACEOF
21331 /* end confdefs.h.  */
21332
21333 /* pthread test headers */
21334 #include <pthread.h>
21335 #if HAVE_PTHREADS < 7
21336 #include <errno.h>
21337 #endif
21338 #ifndef NULL
21339 #define NULL (void*)0
21340 #endif
21341
21342 static void *task(p)
21343         void *p;
21344 {
21345         return (void *) (p == NULL);
21346 }
21347
21348
21349 int main(argc, argv)
21350         int argc;
21351         char **argv;
21352 {
21353
21354         /* pthread test function */
21355 #ifndef PTHREAD_CREATE_DETACHED
21356 #define PTHREAD_CREATE_DETACHED 1
21357 #endif
21358         pthread_t t;
21359         int status;
21360         int detach = PTHREAD_CREATE_DETACHED;
21361
21362 #if HAVE_PTHREADS > 4
21363         /* Final pthreads */
21364         pthread_attr_t attr;
21365
21366         status = pthread_attr_init(&attr);
21367         if( status ) return status;
21368
21369 #if HAVE_PTHREADS < 7
21370         status = pthread_attr_setdetachstate(&attr, &detach);
21371         if( status < 0 ) status = errno;
21372 #else
21373         status = pthread_attr_setdetachstate(&attr, detach);
21374 #endif
21375         if( status ) return status;
21376         status = pthread_create( &t, &attr, task, NULL );
21377 #if HAVE_PTHREADS < 7
21378         if( status < 0 ) status = errno;
21379 #endif
21380         if( status ) return status;
21381 #else
21382         /* Draft 4 pthreads */
21383         status = pthread_create( &t, pthread_attr_default, task, NULL );
21384         if( status ) return errno;
21385
21386         /* give thread a chance to complete */
21387         /* it should remain joinable and hence detachable */
21388         sleep( 1 );
21389
21390         status = pthread_detach( &t );
21391         if( status ) return errno;
21392 #endif
21393
21394 #ifdef HAVE_LINUX_THREADS
21395         pthread_kill_other_threads_np();
21396 #endif
21397
21398         return 0;
21399
21400 }
21401
21402 _ACEOF
21403 rm -f conftest$ac_exeext
21404 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21405   (eval $ac_link) 2>&5
21406   ac_status=$?
21407   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21408   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21409   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21410   (eval $ac_try) 2>&5
21411   ac_status=$?
21412   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21413   (exit $ac_status); }; }; then
21414   ol_cv_pthread_mthreads=yes
21415 else
21416   echo "$as_me: program exited with status $ac_status" >&5
21417 echo "$as_me: failed program was:" >&5
21418 sed 's/^/| /' conftest.$ac_ext >&5
21419
21420 ( exit $ac_status )
21421 ol_cv_pthread_mthreads=no
21422 fi
21423 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21424 fi
21425
21426                 # restore the LIBS
21427                 LIBS="$ol_LIBS"
21428
21429 fi
21430 echo "$as_me:$LINENO: result: $ol_cv_pthread_mthreads" >&5
21431 echo "${ECHO_T}$ol_cv_pthread_mthreads" >&6
21432
21433         if test $ol_cv_pthread_mthreads = yes ; then
21434                 ol_link_pthreads="-mthreads"
21435                 ol_link_threads=posix
21436         fi
21437 fi
21438
21439                 # Pthread try link: -thread (ol_cv_pthread_thread)
21440 if test "$ol_link_threads" = no ; then
21441         # try -thread
21442         echo "$as_me:$LINENO: checking for pthread link with -thread" >&5
21443 echo $ECHO_N "checking for pthread link with -thread... $ECHO_C" >&6
21444 if test "${ol_cv_pthread_thread+set}" = set; then
21445   echo $ECHO_N "(cached) $ECHO_C" >&6
21446 else
21447
21448                 # save the flags
21449                 ol_LIBS="$LIBS"
21450                 LIBS="-thread $LIBS"
21451
21452                 if test "$cross_compiling" = yes; then
21453   cat >conftest.$ac_ext <<_ACEOF
21454 /* confdefs.h.  */
21455 _ACEOF
21456 cat confdefs.h >>conftest.$ac_ext
21457 cat >>conftest.$ac_ext <<_ACEOF
21458 /* end confdefs.h.  */
21459
21460 /* pthread test headers */
21461 #include <pthread.h>
21462 #if HAVE_PTHREADS < 7
21463 #include <errno.h>
21464 #endif
21465 #ifndef NULL
21466 #define NULL (void*)0
21467 #endif
21468
21469 static void *task(p)
21470         void *p;
21471 {
21472         return (void *) (p == NULL);
21473 }
21474
21475 int
21476 main ()
21477 {
21478
21479         /* pthread test function */
21480 #ifndef PTHREAD_CREATE_DETACHED
21481 #define PTHREAD_CREATE_DETACHED 1
21482 #endif
21483         pthread_t t;
21484         int status;
21485         int detach = PTHREAD_CREATE_DETACHED;
21486
21487 #if HAVE_PTHREADS > 4
21488         /* Final pthreads */
21489         pthread_attr_t attr;
21490
21491         status = pthread_attr_init(&attr);
21492         if( status ) return status;
21493
21494 #if HAVE_PTHREADS < 7
21495         status = pthread_attr_setdetachstate(&attr, &detach);
21496         if( status < 0 ) status = errno;
21497 #else
21498         status = pthread_attr_setdetachstate(&attr, detach);
21499 #endif
21500         if( status ) return status;
21501         status = pthread_create( &t, &attr, task, NULL );
21502 #if HAVE_PTHREADS < 7
21503         if( status < 0 ) status = errno;
21504 #endif
21505         if( status ) return status;
21506 #else
21507         /* Draft 4 pthreads */
21508         status = pthread_create( &t, pthread_attr_default, task, NULL );
21509         if( status ) return errno;
21510
21511         /* give thread a chance to complete */
21512         /* it should remain joinable and hence detachable */
21513         sleep( 1 );
21514
21515         status = pthread_detach( &t );
21516         if( status ) return errno;
21517 #endif
21518
21519 #ifdef HAVE_LINUX_THREADS
21520         pthread_kill_other_threads_np();
21521 #endif
21522
21523         return 0;
21524
21525   ;
21526   return 0;
21527 }
21528 _ACEOF
21529 rm -f conftest.$ac_objext conftest$ac_exeext
21530 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21531   (eval $ac_link) 2>conftest.er1
21532   ac_status=$?
21533   grep -v '^ *+' conftest.er1 >conftest.err
21534   rm -f conftest.er1
21535   cat conftest.err >&5
21536   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21537   (exit $ac_status); } &&
21538          { ac_try='test -z "$ac_c_werror_flag"
21539                          || test ! -s conftest.err'
21540   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21541   (eval $ac_try) 2>&5
21542   ac_status=$?
21543   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21544   (exit $ac_status); }; } &&
21545          { ac_try='test -s conftest$ac_exeext'
21546   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21547   (eval $ac_try) 2>&5
21548   ac_status=$?
21549   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21550   (exit $ac_status); }; }; then
21551   ol_cv_pthread_thread=yes
21552 else
21553   echo "$as_me: failed program was:" >&5
21554 sed 's/^/| /' conftest.$ac_ext >&5
21555
21556 ol_cv_pthread_thread=no
21557 fi
21558 rm -f conftest.err conftest.$ac_objext \
21559       conftest$ac_exeext conftest.$ac_ext
21560 else
21561   cat >conftest.$ac_ext <<_ACEOF
21562 /* confdefs.h.  */
21563 _ACEOF
21564 cat confdefs.h >>conftest.$ac_ext
21565 cat >>conftest.$ac_ext <<_ACEOF
21566 /* end confdefs.h.  */
21567
21568 /* pthread test headers */
21569 #include <pthread.h>
21570 #if HAVE_PTHREADS < 7
21571 #include <errno.h>
21572 #endif
21573 #ifndef NULL
21574 #define NULL (void*)0
21575 #endif
21576
21577 static void *task(p)
21578         void *p;
21579 {
21580         return (void *) (p == NULL);
21581 }
21582
21583
21584 int main(argc, argv)
21585         int argc;
21586         char **argv;
21587 {
21588
21589         /* pthread test function */
21590 #ifndef PTHREAD_CREATE_DETACHED
21591 #define PTHREAD_CREATE_DETACHED 1
21592 #endif
21593         pthread_t t;
21594         int status;
21595         int detach = PTHREAD_CREATE_DETACHED;
21596
21597 #if HAVE_PTHREADS > 4
21598         /* Final pthreads */
21599         pthread_attr_t attr;
21600
21601         status = pthread_attr_init(&attr);
21602         if( status ) return status;
21603
21604 #if HAVE_PTHREADS < 7
21605         status = pthread_attr_setdetachstate(&attr, &detach);
21606         if( status < 0 ) status = errno;
21607 #else
21608         status = pthread_attr_setdetachstate(&attr, detach);
21609 #endif
21610         if( status ) return status;
21611         status = pthread_create( &t, &attr, task, NULL );
21612 #if HAVE_PTHREADS < 7
21613         if( status < 0 ) status = errno;
21614 #endif
21615         if( status ) return status;
21616 #else
21617         /* Draft 4 pthreads */
21618         status = pthread_create( &t, pthread_attr_default, task, NULL );
21619         if( status ) return errno;
21620
21621         /* give thread a chance to complete */
21622         /* it should remain joinable and hence detachable */
21623         sleep( 1 );
21624
21625         status = pthread_detach( &t );
21626         if( status ) return errno;
21627 #endif
21628
21629 #ifdef HAVE_LINUX_THREADS
21630         pthread_kill_other_threads_np();
21631 #endif
21632
21633         return 0;
21634
21635 }
21636
21637 _ACEOF
21638 rm -f conftest$ac_exeext
21639 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21640   (eval $ac_link) 2>&5
21641   ac_status=$?
21642   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21643   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21644   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21645   (eval $ac_try) 2>&5
21646   ac_status=$?
21647   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21648   (exit $ac_status); }; }; then
21649   ol_cv_pthread_thread=yes
21650 else
21651   echo "$as_me: program exited with status $ac_status" >&5
21652 echo "$as_me: failed program was:" >&5
21653 sed 's/^/| /' conftest.$ac_ext >&5
21654
21655 ( exit $ac_status )
21656 ol_cv_pthread_thread=no
21657 fi
21658 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21659 fi
21660
21661                 # restore the LIBS
21662                 LIBS="$ol_LIBS"
21663
21664 fi
21665 echo "$as_me:$LINENO: result: $ol_cv_pthread_thread" >&5
21666 echo "${ECHO_T}$ol_cv_pthread_thread" >&6
21667
21668         if test $ol_cv_pthread_thread = yes ; then
21669                 ol_link_pthreads="-thread"
21670                 ol_link_threads=posix
21671         fi
21672 fi
21673
21674
21675                 # Pthread try link: -lpthread -lmach -lexc -lc_r (ol_cv_pthread_lpthread_lmach_lexc_lc_r)
21676 if test "$ol_link_threads" = no ; then
21677         # try -lpthread -lmach -lexc -lc_r
21678         echo "$as_me:$LINENO: checking for pthread link with -lpthread -lmach -lexc -lc_r" >&5
21679 echo $ECHO_N "checking for pthread link with -lpthread -lmach -lexc -lc_r... $ECHO_C" >&6
21680 if test "${ol_cv_pthread_lpthread_lmach_lexc_lc_r+set}" = set; then
21681   echo $ECHO_N "(cached) $ECHO_C" >&6
21682 else
21683
21684                 # save the flags
21685                 ol_LIBS="$LIBS"
21686                 LIBS="-lpthread -lmach -lexc -lc_r $LIBS"
21687
21688                 if test "$cross_compiling" = yes; then
21689   cat >conftest.$ac_ext <<_ACEOF
21690 /* confdefs.h.  */
21691 _ACEOF
21692 cat confdefs.h >>conftest.$ac_ext
21693 cat >>conftest.$ac_ext <<_ACEOF
21694 /* end confdefs.h.  */
21695
21696 /* pthread test headers */
21697 #include <pthread.h>
21698 #if HAVE_PTHREADS < 7
21699 #include <errno.h>
21700 #endif
21701 #ifndef NULL
21702 #define NULL (void*)0
21703 #endif
21704
21705 static void *task(p)
21706         void *p;
21707 {
21708         return (void *) (p == NULL);
21709 }
21710
21711 int
21712 main ()
21713 {
21714
21715         /* pthread test function */
21716 #ifndef PTHREAD_CREATE_DETACHED
21717 #define PTHREAD_CREATE_DETACHED 1
21718 #endif
21719         pthread_t t;
21720         int status;
21721         int detach = PTHREAD_CREATE_DETACHED;
21722
21723 #if HAVE_PTHREADS > 4
21724         /* Final pthreads */
21725         pthread_attr_t attr;
21726
21727         status = pthread_attr_init(&attr);
21728         if( status ) return status;
21729
21730 #if HAVE_PTHREADS < 7
21731         status = pthread_attr_setdetachstate(&attr, &detach);
21732         if( status < 0 ) status = errno;
21733 #else
21734         status = pthread_attr_setdetachstate(&attr, detach);
21735 #endif
21736         if( status ) return status;
21737         status = pthread_create( &t, &attr, task, NULL );
21738 #if HAVE_PTHREADS < 7
21739         if( status < 0 ) status = errno;
21740 #endif
21741         if( status ) return status;
21742 #else
21743         /* Draft 4 pthreads */
21744         status = pthread_create( &t, pthread_attr_default, task, NULL );
21745         if( status ) return errno;
21746
21747         /* give thread a chance to complete */
21748         /* it should remain joinable and hence detachable */
21749         sleep( 1 );
21750
21751         status = pthread_detach( &t );
21752         if( status ) return errno;
21753 #endif
21754
21755 #ifdef HAVE_LINUX_THREADS
21756         pthread_kill_other_threads_np();
21757 #endif
21758
21759         return 0;
21760
21761   ;
21762   return 0;
21763 }
21764 _ACEOF
21765 rm -f conftest.$ac_objext conftest$ac_exeext
21766 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21767   (eval $ac_link) 2>conftest.er1
21768   ac_status=$?
21769   grep -v '^ *+' conftest.er1 >conftest.err
21770   rm -f conftest.er1
21771   cat conftest.err >&5
21772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21773   (exit $ac_status); } &&
21774          { ac_try='test -z "$ac_c_werror_flag"
21775                          || test ! -s conftest.err'
21776   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21777   (eval $ac_try) 2>&5
21778   ac_status=$?
21779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21780   (exit $ac_status); }; } &&
21781          { ac_try='test -s conftest$ac_exeext'
21782   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21783   (eval $ac_try) 2>&5
21784   ac_status=$?
21785   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21786   (exit $ac_status); }; }; then
21787   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
21788 else
21789   echo "$as_me: failed program was:" >&5
21790 sed 's/^/| /' conftest.$ac_ext >&5
21791
21792 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
21793 fi
21794 rm -f conftest.err conftest.$ac_objext \
21795       conftest$ac_exeext conftest.$ac_ext
21796 else
21797   cat >conftest.$ac_ext <<_ACEOF
21798 /* confdefs.h.  */
21799 _ACEOF
21800 cat confdefs.h >>conftest.$ac_ext
21801 cat >>conftest.$ac_ext <<_ACEOF
21802 /* end confdefs.h.  */
21803
21804 /* pthread test headers */
21805 #include <pthread.h>
21806 #if HAVE_PTHREADS < 7
21807 #include <errno.h>
21808 #endif
21809 #ifndef NULL
21810 #define NULL (void*)0
21811 #endif
21812
21813 static void *task(p)
21814         void *p;
21815 {
21816         return (void *) (p == NULL);
21817 }
21818
21819
21820 int main(argc, argv)
21821         int argc;
21822         char **argv;
21823 {
21824
21825         /* pthread test function */
21826 #ifndef PTHREAD_CREATE_DETACHED
21827 #define PTHREAD_CREATE_DETACHED 1
21828 #endif
21829         pthread_t t;
21830         int status;
21831         int detach = PTHREAD_CREATE_DETACHED;
21832
21833 #if HAVE_PTHREADS > 4
21834         /* Final pthreads */
21835         pthread_attr_t attr;
21836
21837         status = pthread_attr_init(&attr);
21838         if( status ) return status;
21839
21840 #if HAVE_PTHREADS < 7
21841         status = pthread_attr_setdetachstate(&attr, &detach);
21842         if( status < 0 ) status = errno;
21843 #else
21844         status = pthread_attr_setdetachstate(&attr, detach);
21845 #endif
21846         if( status ) return status;
21847         status = pthread_create( &t, &attr, task, NULL );
21848 #if HAVE_PTHREADS < 7
21849         if( status < 0 ) status = errno;
21850 #endif
21851         if( status ) return status;
21852 #else
21853         /* Draft 4 pthreads */
21854         status = pthread_create( &t, pthread_attr_default, task, NULL );
21855         if( status ) return errno;
21856
21857         /* give thread a chance to complete */
21858         /* it should remain joinable and hence detachable */
21859         sleep( 1 );
21860
21861         status = pthread_detach( &t );
21862         if( status ) return errno;
21863 #endif
21864
21865 #ifdef HAVE_LINUX_THREADS
21866         pthread_kill_other_threads_np();
21867 #endif
21868
21869         return 0;
21870
21871 }
21872
21873 _ACEOF
21874 rm -f conftest$ac_exeext
21875 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21876   (eval $ac_link) 2>&5
21877   ac_status=$?
21878   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21879   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21880   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21881   (eval $ac_try) 2>&5
21882   ac_status=$?
21883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21884   (exit $ac_status); }; }; then
21885   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
21886 else
21887   echo "$as_me: program exited with status $ac_status" >&5
21888 echo "$as_me: failed program was:" >&5
21889 sed 's/^/| /' conftest.$ac_ext >&5
21890
21891 ( exit $ac_status )
21892 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
21893 fi
21894 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21895 fi
21896
21897                 # restore the LIBS
21898                 LIBS="$ol_LIBS"
21899
21900 fi
21901 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&5
21902 echo "${ECHO_T}$ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&6
21903
21904         if test $ol_cv_pthread_lpthread_lmach_lexc_lc_r = yes ; then
21905                 ol_link_pthreads="-lpthread -lmach -lexc -lc_r"
21906                 ol_link_threads=posix
21907         fi
21908 fi
21909
21910                 # Pthread try link: -lpthread -lmach -lexc (ol_cv_pthread_lpthread_lmach_lexc)
21911 if test "$ol_link_threads" = no ; then
21912         # try -lpthread -lmach -lexc
21913         echo "$as_me:$LINENO: checking for pthread link with -lpthread -lmach -lexc" >&5
21914 echo $ECHO_N "checking for pthread link with -lpthread -lmach -lexc... $ECHO_C" >&6
21915 if test "${ol_cv_pthread_lpthread_lmach_lexc+set}" = set; then
21916   echo $ECHO_N "(cached) $ECHO_C" >&6
21917 else
21918
21919                 # save the flags
21920                 ol_LIBS="$LIBS"
21921                 LIBS="-lpthread -lmach -lexc $LIBS"
21922
21923                 if test "$cross_compiling" = yes; then
21924   cat >conftest.$ac_ext <<_ACEOF
21925 /* confdefs.h.  */
21926 _ACEOF
21927 cat confdefs.h >>conftest.$ac_ext
21928 cat >>conftest.$ac_ext <<_ACEOF
21929 /* end confdefs.h.  */
21930
21931 /* pthread test headers */
21932 #include <pthread.h>
21933 #if HAVE_PTHREADS < 7
21934 #include <errno.h>
21935 #endif
21936 #ifndef NULL
21937 #define NULL (void*)0
21938 #endif
21939
21940 static void *task(p)
21941         void *p;
21942 {
21943         return (void *) (p == NULL);
21944 }
21945
21946 int
21947 main ()
21948 {
21949
21950         /* pthread test function */
21951 #ifndef PTHREAD_CREATE_DETACHED
21952 #define PTHREAD_CREATE_DETACHED 1
21953 #endif
21954         pthread_t t;
21955         int status;
21956         int detach = PTHREAD_CREATE_DETACHED;
21957
21958 #if HAVE_PTHREADS > 4
21959         /* Final pthreads */
21960         pthread_attr_t attr;
21961
21962         status = pthread_attr_init(&attr);
21963         if( status ) return status;
21964
21965 #if HAVE_PTHREADS < 7
21966         status = pthread_attr_setdetachstate(&attr, &detach);
21967         if( status < 0 ) status = errno;
21968 #else
21969         status = pthread_attr_setdetachstate(&attr, detach);
21970 #endif
21971         if( status ) return status;
21972         status = pthread_create( &t, &attr, task, NULL );
21973 #if HAVE_PTHREADS < 7
21974         if( status < 0 ) status = errno;
21975 #endif
21976         if( status ) return status;
21977 #else
21978         /* Draft 4 pthreads */
21979         status = pthread_create( &t, pthread_attr_default, task, NULL );
21980         if( status ) return errno;
21981
21982         /* give thread a chance to complete */
21983         /* it should remain joinable and hence detachable */
21984         sleep( 1 );
21985
21986         status = pthread_detach( &t );
21987         if( status ) return errno;
21988 #endif
21989
21990 #ifdef HAVE_LINUX_THREADS
21991         pthread_kill_other_threads_np();
21992 #endif
21993
21994         return 0;
21995
21996   ;
21997   return 0;
21998 }
21999 _ACEOF
22000 rm -f conftest.$ac_objext conftest$ac_exeext
22001 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22002   (eval $ac_link) 2>conftest.er1
22003   ac_status=$?
22004   grep -v '^ *+' conftest.er1 >conftest.err
22005   rm -f conftest.er1
22006   cat conftest.err >&5
22007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22008   (exit $ac_status); } &&
22009          { ac_try='test -z "$ac_c_werror_flag"
22010                          || test ! -s conftest.err'
22011   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22012   (eval $ac_try) 2>&5
22013   ac_status=$?
22014   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22015   (exit $ac_status); }; } &&
22016          { ac_try='test -s conftest$ac_exeext'
22017   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22018   (eval $ac_try) 2>&5
22019   ac_status=$?
22020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22021   (exit $ac_status); }; }; then
22022   ol_cv_pthread_lpthread_lmach_lexc=yes
22023 else
22024   echo "$as_me: failed program was:" >&5
22025 sed 's/^/| /' conftest.$ac_ext >&5
22026
22027 ol_cv_pthread_lpthread_lmach_lexc=no
22028 fi
22029 rm -f conftest.err conftest.$ac_objext \
22030       conftest$ac_exeext conftest.$ac_ext
22031 else
22032   cat >conftest.$ac_ext <<_ACEOF
22033 /* confdefs.h.  */
22034 _ACEOF
22035 cat confdefs.h >>conftest.$ac_ext
22036 cat >>conftest.$ac_ext <<_ACEOF
22037 /* end confdefs.h.  */
22038
22039 /* pthread test headers */
22040 #include <pthread.h>
22041 #if HAVE_PTHREADS < 7
22042 #include <errno.h>
22043 #endif
22044 #ifndef NULL
22045 #define NULL (void*)0
22046 #endif
22047
22048 static void *task(p)
22049         void *p;
22050 {
22051         return (void *) (p == NULL);
22052 }
22053
22054
22055 int main(argc, argv)
22056         int argc;
22057         char **argv;
22058 {
22059
22060         /* pthread test function */
22061 #ifndef PTHREAD_CREATE_DETACHED
22062 #define PTHREAD_CREATE_DETACHED 1
22063 #endif
22064         pthread_t t;
22065         int status;
22066         int detach = PTHREAD_CREATE_DETACHED;
22067
22068 #if HAVE_PTHREADS > 4
22069         /* Final pthreads */
22070         pthread_attr_t attr;
22071
22072         status = pthread_attr_init(&attr);
22073         if( status ) return status;
22074
22075 #if HAVE_PTHREADS < 7
22076         status = pthread_attr_setdetachstate(&attr, &detach);
22077         if( status < 0 ) status = errno;
22078 #else
22079         status = pthread_attr_setdetachstate(&attr, detach);
22080 #endif
22081         if( status ) return status;
22082         status = pthread_create( &t, &attr, task, NULL );
22083 #if HAVE_PTHREADS < 7
22084         if( status < 0 ) status = errno;
22085 #endif
22086         if( status ) return status;
22087 #else
22088         /* Draft 4 pthreads */
22089         status = pthread_create( &t, pthread_attr_default, task, NULL );
22090         if( status ) return errno;
22091
22092         /* give thread a chance to complete */
22093         /* it should remain joinable and hence detachable */
22094         sleep( 1 );
22095
22096         status = pthread_detach( &t );
22097         if( status ) return errno;
22098 #endif
22099
22100 #ifdef HAVE_LINUX_THREADS
22101         pthread_kill_other_threads_np();
22102 #endif
22103
22104         return 0;
22105
22106 }
22107
22108 _ACEOF
22109 rm -f conftest$ac_exeext
22110 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22111   (eval $ac_link) 2>&5
22112   ac_status=$?
22113   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22114   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22115   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22116   (eval $ac_try) 2>&5
22117   ac_status=$?
22118   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22119   (exit $ac_status); }; }; then
22120   ol_cv_pthread_lpthread_lmach_lexc=yes
22121 else
22122   echo "$as_me: program exited with status $ac_status" >&5
22123 echo "$as_me: failed program was:" >&5
22124 sed 's/^/| /' conftest.$ac_ext >&5
22125
22126 ( exit $ac_status )
22127 ol_cv_pthread_lpthread_lmach_lexc=no
22128 fi
22129 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22130 fi
22131
22132                 # restore the LIBS
22133                 LIBS="$ol_LIBS"
22134
22135 fi
22136 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread_lmach_lexc" >&5
22137 echo "${ECHO_T}$ol_cv_pthread_lpthread_lmach_lexc" >&6
22138
22139         if test $ol_cv_pthread_lpthread_lmach_lexc = yes ; then
22140                 ol_link_pthreads="-lpthread -lmach -lexc"
22141                 ol_link_threads=posix
22142         fi
22143 fi
22144
22145
22146                 # Pthread try link: -lpthread -Wl,-woff,85 (ol_cv_pthread_lib_lpthread_woff)
22147 if test "$ol_link_threads" = no ; then
22148         # try -lpthread -Wl,-woff,85
22149         echo "$as_me:$LINENO: checking for pthread link with -lpthread -Wl,-woff,85" >&5
22150 echo $ECHO_N "checking for pthread link with -lpthread -Wl,-woff,85... $ECHO_C" >&6
22151 if test "${ol_cv_pthread_lib_lpthread_woff+set}" = set; then
22152   echo $ECHO_N "(cached) $ECHO_C" >&6
22153 else
22154
22155                 # save the flags
22156                 ol_LIBS="$LIBS"
22157                 LIBS="-lpthread -Wl,-woff,85 $LIBS"
22158
22159                 if test "$cross_compiling" = yes; then
22160   cat >conftest.$ac_ext <<_ACEOF
22161 /* confdefs.h.  */
22162 _ACEOF
22163 cat confdefs.h >>conftest.$ac_ext
22164 cat >>conftest.$ac_ext <<_ACEOF
22165 /* end confdefs.h.  */
22166
22167 /* pthread test headers */
22168 #include <pthread.h>
22169 #if HAVE_PTHREADS < 7
22170 #include <errno.h>
22171 #endif
22172 #ifndef NULL
22173 #define NULL (void*)0
22174 #endif
22175
22176 static void *task(p)
22177         void *p;
22178 {
22179         return (void *) (p == NULL);
22180 }
22181
22182 int
22183 main ()
22184 {
22185
22186         /* pthread test function */
22187 #ifndef PTHREAD_CREATE_DETACHED
22188 #define PTHREAD_CREATE_DETACHED 1
22189 #endif
22190         pthread_t t;
22191         int status;
22192         int detach = PTHREAD_CREATE_DETACHED;
22193
22194 #if HAVE_PTHREADS > 4
22195         /* Final pthreads */
22196         pthread_attr_t attr;
22197
22198         status = pthread_attr_init(&attr);
22199         if( status ) return status;
22200
22201 #if HAVE_PTHREADS < 7
22202         status = pthread_attr_setdetachstate(&attr, &detach);
22203         if( status < 0 ) status = errno;
22204 #else
22205         status = pthread_attr_setdetachstate(&attr, detach);
22206 #endif
22207         if( status ) return status;
22208         status = pthread_create( &t, &attr, task, NULL );
22209 #if HAVE_PTHREADS < 7
22210         if( status < 0 ) status = errno;
22211 #endif
22212         if( status ) return status;
22213 #else
22214         /* Draft 4 pthreads */
22215         status = pthread_create( &t, pthread_attr_default, task, NULL );
22216         if( status ) return errno;
22217
22218         /* give thread a chance to complete */
22219         /* it should remain joinable and hence detachable */
22220         sleep( 1 );
22221
22222         status = pthread_detach( &t );
22223         if( status ) return errno;
22224 #endif
22225
22226 #ifdef HAVE_LINUX_THREADS
22227         pthread_kill_other_threads_np();
22228 #endif
22229
22230         return 0;
22231
22232   ;
22233   return 0;
22234 }
22235 _ACEOF
22236 rm -f conftest.$ac_objext conftest$ac_exeext
22237 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22238   (eval $ac_link) 2>conftest.er1
22239   ac_status=$?
22240   grep -v '^ *+' conftest.er1 >conftest.err
22241   rm -f conftest.er1
22242   cat conftest.err >&5
22243   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22244   (exit $ac_status); } &&
22245          { ac_try='test -z "$ac_c_werror_flag"
22246                          || test ! -s conftest.err'
22247   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22248   (eval $ac_try) 2>&5
22249   ac_status=$?
22250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22251   (exit $ac_status); }; } &&
22252          { ac_try='test -s conftest$ac_exeext'
22253   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22254   (eval $ac_try) 2>&5
22255   ac_status=$?
22256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22257   (exit $ac_status); }; }; then
22258   ol_cv_pthread_lib_lpthread_woff=yes
22259 else
22260   echo "$as_me: failed program was:" >&5
22261 sed 's/^/| /' conftest.$ac_ext >&5
22262
22263 ol_cv_pthread_lib_lpthread_woff=no
22264 fi
22265 rm -f conftest.err conftest.$ac_objext \
22266       conftest$ac_exeext conftest.$ac_ext
22267 else
22268   cat >conftest.$ac_ext <<_ACEOF
22269 /* confdefs.h.  */
22270 _ACEOF
22271 cat confdefs.h >>conftest.$ac_ext
22272 cat >>conftest.$ac_ext <<_ACEOF
22273 /* end confdefs.h.  */
22274
22275 /* pthread test headers */
22276 #include <pthread.h>
22277 #if HAVE_PTHREADS < 7
22278 #include <errno.h>
22279 #endif
22280 #ifndef NULL
22281 #define NULL (void*)0
22282 #endif
22283
22284 static void *task(p)
22285         void *p;
22286 {
22287         return (void *) (p == NULL);
22288 }
22289
22290
22291 int main(argc, argv)
22292         int argc;
22293         char **argv;
22294 {
22295
22296         /* pthread test function */
22297 #ifndef PTHREAD_CREATE_DETACHED
22298 #define PTHREAD_CREATE_DETACHED 1
22299 #endif
22300         pthread_t t;
22301         int status;
22302         int detach = PTHREAD_CREATE_DETACHED;
22303
22304 #if HAVE_PTHREADS > 4
22305         /* Final pthreads */
22306         pthread_attr_t attr;
22307
22308         status = pthread_attr_init(&attr);
22309         if( status ) return status;
22310
22311 #if HAVE_PTHREADS < 7
22312         status = pthread_attr_setdetachstate(&attr, &detach);
22313         if( status < 0 ) status = errno;
22314 #else
22315         status = pthread_attr_setdetachstate(&attr, detach);
22316 #endif
22317         if( status ) return status;
22318         status = pthread_create( &t, &attr, task, NULL );
22319 #if HAVE_PTHREADS < 7
22320         if( status < 0 ) status = errno;
22321 #endif
22322         if( status ) return status;
22323 #else
22324         /* Draft 4 pthreads */
22325         status = pthread_create( &t, pthread_attr_default, task, NULL );
22326         if( status ) return errno;
22327
22328         /* give thread a chance to complete */
22329         /* it should remain joinable and hence detachable */
22330         sleep( 1 );
22331
22332         status = pthread_detach( &t );
22333         if( status ) return errno;
22334 #endif
22335
22336 #ifdef HAVE_LINUX_THREADS
22337         pthread_kill_other_threads_np();
22338 #endif
22339
22340         return 0;
22341
22342 }
22343
22344 _ACEOF
22345 rm -f conftest$ac_exeext
22346 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22347   (eval $ac_link) 2>&5
22348   ac_status=$?
22349   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22350   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22351   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22352   (eval $ac_try) 2>&5
22353   ac_status=$?
22354   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22355   (exit $ac_status); }; }; then
22356   ol_cv_pthread_lib_lpthread_woff=yes
22357 else
22358   echo "$as_me: program exited with status $ac_status" >&5
22359 echo "$as_me: failed program was:" >&5
22360 sed 's/^/| /' conftest.$ac_ext >&5
22361
22362 ( exit $ac_status )
22363 ol_cv_pthread_lib_lpthread_woff=no
22364 fi
22365 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22366 fi
22367
22368                 # restore the LIBS
22369                 LIBS="$ol_LIBS"
22370
22371 fi
22372 echo "$as_me:$LINENO: result: $ol_cv_pthread_lib_lpthread_woff" >&5
22373 echo "${ECHO_T}$ol_cv_pthread_lib_lpthread_woff" >&6
22374
22375         if test $ol_cv_pthread_lib_lpthread_woff = yes ; then
22376                 ol_link_pthreads="-lpthread -Wl,-woff,85"
22377                 ol_link_threads=posix
22378         fi
22379 fi
22380
22381
22382                 # Pthread try link: -lpthread (ol_cv_pthread_lpthread)
22383 if test "$ol_link_threads" = no ; then
22384         # try -lpthread
22385         echo "$as_me:$LINENO: checking for pthread link with -lpthread" >&5
22386 echo $ECHO_N "checking for pthread link with -lpthread... $ECHO_C" >&6
22387 if test "${ol_cv_pthread_lpthread+set}" = set; then
22388   echo $ECHO_N "(cached) $ECHO_C" >&6
22389 else
22390
22391                 # save the flags
22392                 ol_LIBS="$LIBS"
22393                 LIBS="-lpthread $LIBS"
22394
22395                 if test "$cross_compiling" = yes; then
22396   cat >conftest.$ac_ext <<_ACEOF
22397 /* confdefs.h.  */
22398 _ACEOF
22399 cat confdefs.h >>conftest.$ac_ext
22400 cat >>conftest.$ac_ext <<_ACEOF
22401 /* end confdefs.h.  */
22402
22403 /* pthread test headers */
22404 #include <pthread.h>
22405 #if HAVE_PTHREADS < 7
22406 #include <errno.h>
22407 #endif
22408 #ifndef NULL
22409 #define NULL (void*)0
22410 #endif
22411
22412 static void *task(p)
22413         void *p;
22414 {
22415         return (void *) (p == NULL);
22416 }
22417
22418 int
22419 main ()
22420 {
22421
22422         /* pthread test function */
22423 #ifndef PTHREAD_CREATE_DETACHED
22424 #define PTHREAD_CREATE_DETACHED 1
22425 #endif
22426         pthread_t t;
22427         int status;
22428         int detach = PTHREAD_CREATE_DETACHED;
22429
22430 #if HAVE_PTHREADS > 4
22431         /* Final pthreads */
22432         pthread_attr_t attr;
22433
22434         status = pthread_attr_init(&attr);
22435         if( status ) return status;
22436
22437 #if HAVE_PTHREADS < 7
22438         status = pthread_attr_setdetachstate(&attr, &detach);
22439         if( status < 0 ) status = errno;
22440 #else
22441         status = pthread_attr_setdetachstate(&attr, detach);
22442 #endif
22443         if( status ) return status;
22444         status = pthread_create( &t, &attr, task, NULL );
22445 #if HAVE_PTHREADS < 7
22446         if( status < 0 ) status = errno;
22447 #endif
22448         if( status ) return status;
22449 #else
22450         /* Draft 4 pthreads */
22451         status = pthread_create( &t, pthread_attr_default, task, NULL );
22452         if( status ) return errno;
22453
22454         /* give thread a chance to complete */
22455         /* it should remain joinable and hence detachable */
22456         sleep( 1 );
22457
22458         status = pthread_detach( &t );
22459         if( status ) return errno;
22460 #endif
22461
22462 #ifdef HAVE_LINUX_THREADS
22463         pthread_kill_other_threads_np();
22464 #endif
22465
22466         return 0;
22467
22468   ;
22469   return 0;
22470 }
22471 _ACEOF
22472 rm -f conftest.$ac_objext conftest$ac_exeext
22473 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22474   (eval $ac_link) 2>conftest.er1
22475   ac_status=$?
22476   grep -v '^ *+' conftest.er1 >conftest.err
22477   rm -f conftest.er1
22478   cat conftest.err >&5
22479   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22480   (exit $ac_status); } &&
22481          { ac_try='test -z "$ac_c_werror_flag"
22482                          || test ! -s conftest.err'
22483   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22484   (eval $ac_try) 2>&5
22485   ac_status=$?
22486   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22487   (exit $ac_status); }; } &&
22488          { ac_try='test -s conftest$ac_exeext'
22489   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22490   (eval $ac_try) 2>&5
22491   ac_status=$?
22492   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22493   (exit $ac_status); }; }; then
22494   ol_cv_pthread_lpthread=yes
22495 else
22496   echo "$as_me: failed program was:" >&5
22497 sed 's/^/| /' conftest.$ac_ext >&5
22498
22499 ol_cv_pthread_lpthread=no
22500 fi
22501 rm -f conftest.err conftest.$ac_objext \
22502       conftest$ac_exeext conftest.$ac_ext
22503 else
22504   cat >conftest.$ac_ext <<_ACEOF
22505 /* confdefs.h.  */
22506 _ACEOF
22507 cat confdefs.h >>conftest.$ac_ext
22508 cat >>conftest.$ac_ext <<_ACEOF
22509 /* end confdefs.h.  */
22510
22511 /* pthread test headers */
22512 #include <pthread.h>
22513 #if HAVE_PTHREADS < 7
22514 #include <errno.h>
22515 #endif
22516 #ifndef NULL
22517 #define NULL (void*)0
22518 #endif
22519
22520 static void *task(p)
22521         void *p;
22522 {
22523         return (void *) (p == NULL);
22524 }
22525
22526
22527 int main(argc, argv)
22528         int argc;
22529         char **argv;
22530 {
22531
22532         /* pthread test function */
22533 #ifndef PTHREAD_CREATE_DETACHED
22534 #define PTHREAD_CREATE_DETACHED 1
22535 #endif
22536         pthread_t t;
22537         int status;
22538         int detach = PTHREAD_CREATE_DETACHED;
22539
22540 #if HAVE_PTHREADS > 4
22541         /* Final pthreads */
22542         pthread_attr_t attr;
22543
22544         status = pthread_attr_init(&attr);
22545         if( status ) return status;
22546
22547 #if HAVE_PTHREADS < 7
22548         status = pthread_attr_setdetachstate(&attr, &detach);
22549         if( status < 0 ) status = errno;
22550 #else
22551         status = pthread_attr_setdetachstate(&attr, detach);
22552 #endif
22553         if( status ) return status;
22554         status = pthread_create( &t, &attr, task, NULL );
22555 #if HAVE_PTHREADS < 7
22556         if( status < 0 ) status = errno;
22557 #endif
22558         if( status ) return status;
22559 #else
22560         /* Draft 4 pthreads */
22561         status = pthread_create( &t, pthread_attr_default, task, NULL );
22562         if( status ) return errno;
22563
22564         /* give thread a chance to complete */
22565         /* it should remain joinable and hence detachable */
22566         sleep( 1 );
22567
22568         status = pthread_detach( &t );
22569         if( status ) return errno;
22570 #endif
22571
22572 #ifdef HAVE_LINUX_THREADS
22573         pthread_kill_other_threads_np();
22574 #endif
22575
22576         return 0;
22577
22578 }
22579
22580 _ACEOF
22581 rm -f conftest$ac_exeext
22582 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22583   (eval $ac_link) 2>&5
22584   ac_status=$?
22585   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22586   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22587   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22588   (eval $ac_try) 2>&5
22589   ac_status=$?
22590   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22591   (exit $ac_status); }; }; then
22592   ol_cv_pthread_lpthread=yes
22593 else
22594   echo "$as_me: program exited with status $ac_status" >&5
22595 echo "$as_me: failed program was:" >&5
22596 sed 's/^/| /' conftest.$ac_ext >&5
22597
22598 ( exit $ac_status )
22599 ol_cv_pthread_lpthread=no
22600 fi
22601 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22602 fi
22603
22604                 # restore the LIBS
22605                 LIBS="$ol_LIBS"
22606
22607 fi
22608 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread" >&5
22609 echo "${ECHO_T}$ol_cv_pthread_lpthread" >&6
22610
22611         if test $ol_cv_pthread_lpthread = yes ; then
22612                 ol_link_pthreads="-lpthread"
22613                 ol_link_threads=posix
22614         fi
22615 fi
22616
22617                 # Pthread try link: -lc_r (ol_cv_pthread_lc_r)
22618 if test "$ol_link_threads" = no ; then
22619         # try -lc_r
22620         echo "$as_me:$LINENO: checking for pthread link with -lc_r" >&5
22621 echo $ECHO_N "checking for pthread link with -lc_r... $ECHO_C" >&6
22622 if test "${ol_cv_pthread_lc_r+set}" = set; then
22623   echo $ECHO_N "(cached) $ECHO_C" >&6
22624 else
22625
22626                 # save the flags
22627                 ol_LIBS="$LIBS"
22628                 LIBS="-lc_r $LIBS"
22629
22630                 if test "$cross_compiling" = yes; then
22631   cat >conftest.$ac_ext <<_ACEOF
22632 /* confdefs.h.  */
22633 _ACEOF
22634 cat confdefs.h >>conftest.$ac_ext
22635 cat >>conftest.$ac_ext <<_ACEOF
22636 /* end confdefs.h.  */
22637
22638 /* pthread test headers */
22639 #include <pthread.h>
22640 #if HAVE_PTHREADS < 7
22641 #include <errno.h>
22642 #endif
22643 #ifndef NULL
22644 #define NULL (void*)0
22645 #endif
22646
22647 static void *task(p)
22648         void *p;
22649 {
22650         return (void *) (p == NULL);
22651 }
22652
22653 int
22654 main ()
22655 {
22656
22657         /* pthread test function */
22658 #ifndef PTHREAD_CREATE_DETACHED
22659 #define PTHREAD_CREATE_DETACHED 1
22660 #endif
22661         pthread_t t;
22662         int status;
22663         int detach = PTHREAD_CREATE_DETACHED;
22664
22665 #if HAVE_PTHREADS > 4
22666         /* Final pthreads */
22667         pthread_attr_t attr;
22668
22669         status = pthread_attr_init(&attr);
22670         if( status ) return status;
22671
22672 #if HAVE_PTHREADS < 7
22673         status = pthread_attr_setdetachstate(&attr, &detach);
22674         if( status < 0 ) status = errno;
22675 #else
22676         status = pthread_attr_setdetachstate(&attr, detach);
22677 #endif
22678         if( status ) return status;
22679         status = pthread_create( &t, &attr, task, NULL );
22680 #if HAVE_PTHREADS < 7
22681         if( status < 0 ) status = errno;
22682 #endif
22683         if( status ) return status;
22684 #else
22685         /* Draft 4 pthreads */
22686         status = pthread_create( &t, pthread_attr_default, task, NULL );
22687         if( status ) return errno;
22688
22689         /* give thread a chance to complete */
22690         /* it should remain joinable and hence detachable */
22691         sleep( 1 );
22692
22693         status = pthread_detach( &t );
22694         if( status ) return errno;
22695 #endif
22696
22697 #ifdef HAVE_LINUX_THREADS
22698         pthread_kill_other_threads_np();
22699 #endif
22700
22701         return 0;
22702
22703   ;
22704   return 0;
22705 }
22706 _ACEOF
22707 rm -f conftest.$ac_objext conftest$ac_exeext
22708 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22709   (eval $ac_link) 2>conftest.er1
22710   ac_status=$?
22711   grep -v '^ *+' conftest.er1 >conftest.err
22712   rm -f conftest.er1
22713   cat conftest.err >&5
22714   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22715   (exit $ac_status); } &&
22716          { ac_try='test -z "$ac_c_werror_flag"
22717                          || test ! -s conftest.err'
22718   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22719   (eval $ac_try) 2>&5
22720   ac_status=$?
22721   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22722   (exit $ac_status); }; } &&
22723          { ac_try='test -s conftest$ac_exeext'
22724   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22725   (eval $ac_try) 2>&5
22726   ac_status=$?
22727   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22728   (exit $ac_status); }; }; then
22729   ol_cv_pthread_lc_r=yes
22730 else
22731   echo "$as_me: failed program was:" >&5
22732 sed 's/^/| /' conftest.$ac_ext >&5
22733
22734 ol_cv_pthread_lc_r=no
22735 fi
22736 rm -f conftest.err conftest.$ac_objext \
22737       conftest$ac_exeext conftest.$ac_ext
22738 else
22739   cat >conftest.$ac_ext <<_ACEOF
22740 /* confdefs.h.  */
22741 _ACEOF
22742 cat confdefs.h >>conftest.$ac_ext
22743 cat >>conftest.$ac_ext <<_ACEOF
22744 /* end confdefs.h.  */
22745
22746 /* pthread test headers */
22747 #include <pthread.h>
22748 #if HAVE_PTHREADS < 7
22749 #include <errno.h>
22750 #endif
22751 #ifndef NULL
22752 #define NULL (void*)0
22753 #endif
22754
22755 static void *task(p)
22756         void *p;
22757 {
22758         return (void *) (p == NULL);
22759 }
22760
22761
22762 int main(argc, argv)
22763         int argc;
22764         char **argv;
22765 {
22766
22767         /* pthread test function */
22768 #ifndef PTHREAD_CREATE_DETACHED
22769 #define PTHREAD_CREATE_DETACHED 1
22770 #endif
22771         pthread_t t;
22772         int status;
22773         int detach = PTHREAD_CREATE_DETACHED;
22774
22775 #if HAVE_PTHREADS > 4
22776         /* Final pthreads */
22777         pthread_attr_t attr;
22778
22779         status = pthread_attr_init(&attr);
22780         if( status ) return status;
22781
22782 #if HAVE_PTHREADS < 7
22783         status = pthread_attr_setdetachstate(&attr, &detach);
22784         if( status < 0 ) status = errno;
22785 #else
22786         status = pthread_attr_setdetachstate(&attr, detach);
22787 #endif
22788         if( status ) return status;
22789         status = pthread_create( &t, &attr, task, NULL );
22790 #if HAVE_PTHREADS < 7
22791         if( status < 0 ) status = errno;
22792 #endif
22793         if( status ) return status;
22794 #else
22795         /* Draft 4 pthreads */
22796         status = pthread_create( &t, pthread_attr_default, task, NULL );
22797         if( status ) return errno;
22798
22799         /* give thread a chance to complete */
22800         /* it should remain joinable and hence detachable */
22801         sleep( 1 );
22802
22803         status = pthread_detach( &t );
22804         if( status ) return errno;
22805 #endif
22806
22807 #ifdef HAVE_LINUX_THREADS
22808         pthread_kill_other_threads_np();
22809 #endif
22810
22811         return 0;
22812
22813 }
22814
22815 _ACEOF
22816 rm -f conftest$ac_exeext
22817 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22818   (eval $ac_link) 2>&5
22819   ac_status=$?
22820   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22821   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22822   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22823   (eval $ac_try) 2>&5
22824   ac_status=$?
22825   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22826   (exit $ac_status); }; }; then
22827   ol_cv_pthread_lc_r=yes
22828 else
22829   echo "$as_me: program exited with status $ac_status" >&5
22830 echo "$as_me: failed program was:" >&5
22831 sed 's/^/| /' conftest.$ac_ext >&5
22832
22833 ( exit $ac_status )
22834 ol_cv_pthread_lc_r=no
22835 fi
22836 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22837 fi
22838
22839                 # restore the LIBS
22840                 LIBS="$ol_LIBS"
22841
22842 fi
22843 echo "$as_me:$LINENO: result: $ol_cv_pthread_lc_r" >&5
22844 echo "${ECHO_T}$ol_cv_pthread_lc_r" >&6
22845
22846         if test $ol_cv_pthread_lc_r = yes ; then
22847                 ol_link_pthreads="-lc_r"
22848                 ol_link_threads=posix
22849         fi
22850 fi
22851
22852
22853                 # Pthread try link: -threads (ol_cv_pthread_threads)
22854 if test "$ol_link_threads" = no ; then
22855         # try -threads
22856         echo "$as_me:$LINENO: checking for pthread link with -threads" >&5
22857 echo $ECHO_N "checking for pthread link with -threads... $ECHO_C" >&6
22858 if test "${ol_cv_pthread_threads+set}" = set; then
22859   echo $ECHO_N "(cached) $ECHO_C" >&6
22860 else
22861
22862                 # save the flags
22863                 ol_LIBS="$LIBS"
22864                 LIBS="-threads $LIBS"
22865
22866                 if test "$cross_compiling" = yes; then
22867   cat >conftest.$ac_ext <<_ACEOF
22868 /* confdefs.h.  */
22869 _ACEOF
22870 cat confdefs.h >>conftest.$ac_ext
22871 cat >>conftest.$ac_ext <<_ACEOF
22872 /* end confdefs.h.  */
22873
22874 /* pthread test headers */
22875 #include <pthread.h>
22876 #if HAVE_PTHREADS < 7
22877 #include <errno.h>
22878 #endif
22879 #ifndef NULL
22880 #define NULL (void*)0
22881 #endif
22882
22883 static void *task(p)
22884         void *p;
22885 {
22886         return (void *) (p == NULL);
22887 }
22888
22889 int
22890 main ()
22891 {
22892
22893         /* pthread test function */
22894 #ifndef PTHREAD_CREATE_DETACHED
22895 #define PTHREAD_CREATE_DETACHED 1
22896 #endif
22897         pthread_t t;
22898         int status;
22899         int detach = PTHREAD_CREATE_DETACHED;
22900
22901 #if HAVE_PTHREADS > 4
22902         /* Final pthreads */
22903         pthread_attr_t attr;
22904
22905         status = pthread_attr_init(&attr);
22906         if( status ) return status;
22907
22908 #if HAVE_PTHREADS < 7
22909         status = pthread_attr_setdetachstate(&attr, &detach);
22910         if( status < 0 ) status = errno;
22911 #else
22912         status = pthread_attr_setdetachstate(&attr, detach);
22913 #endif
22914         if( status ) return status;
22915         status = pthread_create( &t, &attr, task, NULL );
22916 #if HAVE_PTHREADS < 7
22917         if( status < 0 ) status = errno;
22918 #endif
22919         if( status ) return status;
22920 #else
22921         /* Draft 4 pthreads */
22922         status = pthread_create( &t, pthread_attr_default, task, NULL );
22923         if( status ) return errno;
22924
22925         /* give thread a chance to complete */
22926         /* it should remain joinable and hence detachable */
22927         sleep( 1 );
22928
22929         status = pthread_detach( &t );
22930         if( status ) return errno;
22931 #endif
22932
22933 #ifdef HAVE_LINUX_THREADS
22934         pthread_kill_other_threads_np();
22935 #endif
22936
22937         return 0;
22938
22939   ;
22940   return 0;
22941 }
22942 _ACEOF
22943 rm -f conftest.$ac_objext conftest$ac_exeext
22944 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22945   (eval $ac_link) 2>conftest.er1
22946   ac_status=$?
22947   grep -v '^ *+' conftest.er1 >conftest.err
22948   rm -f conftest.er1
22949   cat conftest.err >&5
22950   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22951   (exit $ac_status); } &&
22952          { ac_try='test -z "$ac_c_werror_flag"
22953                          || test ! -s conftest.err'
22954   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22955   (eval $ac_try) 2>&5
22956   ac_status=$?
22957   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22958   (exit $ac_status); }; } &&
22959          { ac_try='test -s conftest$ac_exeext'
22960   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22961   (eval $ac_try) 2>&5
22962   ac_status=$?
22963   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22964   (exit $ac_status); }; }; then
22965   ol_cv_pthread_threads=yes
22966 else
22967   echo "$as_me: failed program was:" >&5
22968 sed 's/^/| /' conftest.$ac_ext >&5
22969
22970 ol_cv_pthread_threads=no
22971 fi
22972 rm -f conftest.err conftest.$ac_objext \
22973       conftest$ac_exeext conftest.$ac_ext
22974 else
22975   cat >conftest.$ac_ext <<_ACEOF
22976 /* confdefs.h.  */
22977 _ACEOF
22978 cat confdefs.h >>conftest.$ac_ext
22979 cat >>conftest.$ac_ext <<_ACEOF
22980 /* end confdefs.h.  */
22981
22982 /* pthread test headers */
22983 #include <pthread.h>
22984 #if HAVE_PTHREADS < 7
22985 #include <errno.h>
22986 #endif
22987 #ifndef NULL
22988 #define NULL (void*)0
22989 #endif
22990
22991 static void *task(p)
22992         void *p;
22993 {
22994         return (void *) (p == NULL);
22995 }
22996
22997
22998 int main(argc, argv)
22999         int argc;
23000         char **argv;
23001 {
23002
23003         /* pthread test function */
23004 #ifndef PTHREAD_CREATE_DETACHED
23005 #define PTHREAD_CREATE_DETACHED 1
23006 #endif
23007         pthread_t t;
23008         int status;
23009         int detach = PTHREAD_CREATE_DETACHED;
23010
23011 #if HAVE_PTHREADS > 4
23012         /* Final pthreads */
23013         pthread_attr_t attr;
23014
23015         status = pthread_attr_init(&attr);
23016         if( status ) return status;
23017
23018 #if HAVE_PTHREADS < 7
23019         status = pthread_attr_setdetachstate(&attr, &detach);
23020         if( status < 0 ) status = errno;
23021 #else
23022         status = pthread_attr_setdetachstate(&attr, detach);
23023 #endif
23024         if( status ) return status;
23025         status = pthread_create( &t, &attr, task, NULL );
23026 #if HAVE_PTHREADS < 7
23027         if( status < 0 ) status = errno;
23028 #endif
23029         if( status ) return status;
23030 #else
23031         /* Draft 4 pthreads */
23032         status = pthread_create( &t, pthread_attr_default, task, NULL );
23033         if( status ) return errno;
23034
23035         /* give thread a chance to complete */
23036         /* it should remain joinable and hence detachable */
23037         sleep( 1 );
23038
23039         status = pthread_detach( &t );
23040         if( status ) return errno;
23041 #endif
23042
23043 #ifdef HAVE_LINUX_THREADS
23044         pthread_kill_other_threads_np();
23045 #endif
23046
23047         return 0;
23048
23049 }
23050
23051 _ACEOF
23052 rm -f conftest$ac_exeext
23053 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23054   (eval $ac_link) 2>&5
23055   ac_status=$?
23056   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23057   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23058   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23059   (eval $ac_try) 2>&5
23060   ac_status=$?
23061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23062   (exit $ac_status); }; }; then
23063   ol_cv_pthread_threads=yes
23064 else
23065   echo "$as_me: program exited with status $ac_status" >&5
23066 echo "$as_me: failed program was:" >&5
23067 sed 's/^/| /' conftest.$ac_ext >&5
23068
23069 ( exit $ac_status )
23070 ol_cv_pthread_threads=no
23071 fi
23072 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23073 fi
23074
23075                 # restore the LIBS
23076                 LIBS="$ol_LIBS"
23077
23078 fi
23079 echo "$as_me:$LINENO: result: $ol_cv_pthread_threads" >&5
23080 echo "${ECHO_T}$ol_cv_pthread_threads" >&6
23081
23082         if test $ol_cv_pthread_threads = yes ; then
23083                 ol_link_pthreads="-threads"
23084                 ol_link_threads=posix
23085         fi
23086 fi
23087
23088
23089                 # Pthread try link: -lpthreads -lmach -lexc -lc_r (ol_cv_pthread_lpthreads_lmach_lexc_lc_r)
23090 if test "$ol_link_threads" = no ; then
23091         # try -lpthreads -lmach -lexc -lc_r
23092         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lmach -lexc -lc_r" >&5
23093 echo $ECHO_N "checking for pthread link with -lpthreads -lmach -lexc -lc_r... $ECHO_C" >&6
23094 if test "${ol_cv_pthread_lpthreads_lmach_lexc_lc_r+set}" = set; then
23095   echo $ECHO_N "(cached) $ECHO_C" >&6
23096 else
23097
23098                 # save the flags
23099                 ol_LIBS="$LIBS"
23100                 LIBS="-lpthreads -lmach -lexc -lc_r $LIBS"
23101
23102                 if test "$cross_compiling" = yes; then
23103   cat >conftest.$ac_ext <<_ACEOF
23104 /* confdefs.h.  */
23105 _ACEOF
23106 cat confdefs.h >>conftest.$ac_ext
23107 cat >>conftest.$ac_ext <<_ACEOF
23108 /* end confdefs.h.  */
23109
23110 /* pthread test headers */
23111 #include <pthread.h>
23112 #if HAVE_PTHREADS < 7
23113 #include <errno.h>
23114 #endif
23115 #ifndef NULL
23116 #define NULL (void*)0
23117 #endif
23118
23119 static void *task(p)
23120         void *p;
23121 {
23122         return (void *) (p == NULL);
23123 }
23124
23125 int
23126 main ()
23127 {
23128
23129         /* pthread test function */
23130 #ifndef PTHREAD_CREATE_DETACHED
23131 #define PTHREAD_CREATE_DETACHED 1
23132 #endif
23133         pthread_t t;
23134         int status;
23135         int detach = PTHREAD_CREATE_DETACHED;
23136
23137 #if HAVE_PTHREADS > 4
23138         /* Final pthreads */
23139         pthread_attr_t attr;
23140
23141         status = pthread_attr_init(&attr);
23142         if( status ) return status;
23143
23144 #if HAVE_PTHREADS < 7
23145         status = pthread_attr_setdetachstate(&attr, &detach);
23146         if( status < 0 ) status = errno;
23147 #else
23148         status = pthread_attr_setdetachstate(&attr, detach);
23149 #endif
23150         if( status ) return status;
23151         status = pthread_create( &t, &attr, task, NULL );
23152 #if HAVE_PTHREADS < 7
23153         if( status < 0 ) status = errno;
23154 #endif
23155         if( status ) return status;
23156 #else
23157         /* Draft 4 pthreads */
23158         status = pthread_create( &t, pthread_attr_default, task, NULL );
23159         if( status ) return errno;
23160
23161         /* give thread a chance to complete */
23162         /* it should remain joinable and hence detachable */
23163         sleep( 1 );
23164
23165         status = pthread_detach( &t );
23166         if( status ) return errno;
23167 #endif
23168
23169 #ifdef HAVE_LINUX_THREADS
23170         pthread_kill_other_threads_np();
23171 #endif
23172
23173         return 0;
23174
23175   ;
23176   return 0;
23177 }
23178 _ACEOF
23179 rm -f conftest.$ac_objext conftest$ac_exeext
23180 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23181   (eval $ac_link) 2>conftest.er1
23182   ac_status=$?
23183   grep -v '^ *+' conftest.er1 >conftest.err
23184   rm -f conftest.er1
23185   cat conftest.err >&5
23186   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23187   (exit $ac_status); } &&
23188          { ac_try='test -z "$ac_c_werror_flag"
23189                          || test ! -s conftest.err'
23190   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23191   (eval $ac_try) 2>&5
23192   ac_status=$?
23193   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23194   (exit $ac_status); }; } &&
23195          { ac_try='test -s conftest$ac_exeext'
23196   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23197   (eval $ac_try) 2>&5
23198   ac_status=$?
23199   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23200   (exit $ac_status); }; }; then
23201   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
23202 else
23203   echo "$as_me: failed program was:" >&5
23204 sed 's/^/| /' conftest.$ac_ext >&5
23205
23206 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
23207 fi
23208 rm -f conftest.err conftest.$ac_objext \
23209       conftest$ac_exeext conftest.$ac_ext
23210 else
23211   cat >conftest.$ac_ext <<_ACEOF
23212 /* confdefs.h.  */
23213 _ACEOF
23214 cat confdefs.h >>conftest.$ac_ext
23215 cat >>conftest.$ac_ext <<_ACEOF
23216 /* end confdefs.h.  */
23217
23218 /* pthread test headers */
23219 #include <pthread.h>
23220 #if HAVE_PTHREADS < 7
23221 #include <errno.h>
23222 #endif
23223 #ifndef NULL
23224 #define NULL (void*)0
23225 #endif
23226
23227 static void *task(p)
23228         void *p;
23229 {
23230         return (void *) (p == NULL);
23231 }
23232
23233
23234 int main(argc, argv)
23235         int argc;
23236         char **argv;
23237 {
23238
23239         /* pthread test function */
23240 #ifndef PTHREAD_CREATE_DETACHED
23241 #define PTHREAD_CREATE_DETACHED 1
23242 #endif
23243         pthread_t t;
23244         int status;
23245         int detach = PTHREAD_CREATE_DETACHED;
23246
23247 #if HAVE_PTHREADS > 4
23248         /* Final pthreads */
23249         pthread_attr_t attr;
23250
23251         status = pthread_attr_init(&attr);
23252         if( status ) return status;
23253
23254 #if HAVE_PTHREADS < 7
23255         status = pthread_attr_setdetachstate(&attr, &detach);
23256         if( status < 0 ) status = errno;
23257 #else
23258         status = pthread_attr_setdetachstate(&attr, detach);
23259 #endif
23260         if( status ) return status;
23261         status = pthread_create( &t, &attr, task, NULL );
23262 #if HAVE_PTHREADS < 7
23263         if( status < 0 ) status = errno;
23264 #endif
23265         if( status ) return status;
23266 #else
23267         /* Draft 4 pthreads */
23268         status = pthread_create( &t, pthread_attr_default, task, NULL );
23269         if( status ) return errno;
23270
23271         /* give thread a chance to complete */
23272         /* it should remain joinable and hence detachable */
23273         sleep( 1 );
23274
23275         status = pthread_detach( &t );
23276         if( status ) return errno;
23277 #endif
23278
23279 #ifdef HAVE_LINUX_THREADS
23280         pthread_kill_other_threads_np();
23281 #endif
23282
23283         return 0;
23284
23285 }
23286
23287 _ACEOF
23288 rm -f conftest$ac_exeext
23289 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23290   (eval $ac_link) 2>&5
23291   ac_status=$?
23292   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23293   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23294   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23295   (eval $ac_try) 2>&5
23296   ac_status=$?
23297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23298   (exit $ac_status); }; }; then
23299   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
23300 else
23301   echo "$as_me: program exited with status $ac_status" >&5
23302 echo "$as_me: failed program was:" >&5
23303 sed 's/^/| /' conftest.$ac_ext >&5
23304
23305 ( exit $ac_status )
23306 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
23307 fi
23308 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23309 fi
23310
23311                 # restore the LIBS
23312                 LIBS="$ol_LIBS"
23313
23314 fi
23315 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&5
23316 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&6
23317
23318         if test $ol_cv_pthread_lpthreads_lmach_lexc_lc_r = yes ; then
23319                 ol_link_pthreads="-lpthreads -lmach -lexc -lc_r"
23320                 ol_link_threads=posix
23321         fi
23322 fi
23323
23324                 # Pthread try link: -lpthreads -lmach -lexc (ol_cv_pthread_lpthreads_lmach_lexc)
23325 if test "$ol_link_threads" = no ; then
23326         # try -lpthreads -lmach -lexc
23327         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lmach -lexc" >&5
23328 echo $ECHO_N "checking for pthread link with -lpthreads -lmach -lexc... $ECHO_C" >&6
23329 if test "${ol_cv_pthread_lpthreads_lmach_lexc+set}" = set; then
23330   echo $ECHO_N "(cached) $ECHO_C" >&6
23331 else
23332
23333                 # save the flags
23334                 ol_LIBS="$LIBS"
23335                 LIBS="-lpthreads -lmach -lexc $LIBS"
23336
23337                 if test "$cross_compiling" = yes; then
23338   cat >conftest.$ac_ext <<_ACEOF
23339 /* confdefs.h.  */
23340 _ACEOF
23341 cat confdefs.h >>conftest.$ac_ext
23342 cat >>conftest.$ac_ext <<_ACEOF
23343 /* end confdefs.h.  */
23344
23345 /* pthread test headers */
23346 #include <pthread.h>
23347 #if HAVE_PTHREADS < 7
23348 #include <errno.h>
23349 #endif
23350 #ifndef NULL
23351 #define NULL (void*)0
23352 #endif
23353
23354 static void *task(p)
23355         void *p;
23356 {
23357         return (void *) (p == NULL);
23358 }
23359
23360 int
23361 main ()
23362 {
23363
23364         /* pthread test function */
23365 #ifndef PTHREAD_CREATE_DETACHED
23366 #define PTHREAD_CREATE_DETACHED 1
23367 #endif
23368         pthread_t t;
23369         int status;
23370         int detach = PTHREAD_CREATE_DETACHED;
23371
23372 #if HAVE_PTHREADS > 4
23373         /* Final pthreads */
23374         pthread_attr_t attr;
23375
23376         status = pthread_attr_init(&attr);
23377         if( status ) return status;
23378
23379 #if HAVE_PTHREADS < 7
23380         status = pthread_attr_setdetachstate(&attr, &detach);
23381         if( status < 0 ) status = errno;
23382 #else
23383         status = pthread_attr_setdetachstate(&attr, detach);
23384 #endif
23385         if( status ) return status;
23386         status = pthread_create( &t, &attr, task, NULL );
23387 #if HAVE_PTHREADS < 7
23388         if( status < 0 ) status = errno;
23389 #endif
23390         if( status ) return status;
23391 #else
23392         /* Draft 4 pthreads */
23393         status = pthread_create( &t, pthread_attr_default, task, NULL );
23394         if( status ) return errno;
23395
23396         /* give thread a chance to complete */
23397         /* it should remain joinable and hence detachable */
23398         sleep( 1 );
23399
23400         status = pthread_detach( &t );
23401         if( status ) return errno;
23402 #endif
23403
23404 #ifdef HAVE_LINUX_THREADS
23405         pthread_kill_other_threads_np();
23406 #endif
23407
23408         return 0;
23409
23410   ;
23411   return 0;
23412 }
23413 _ACEOF
23414 rm -f conftest.$ac_objext conftest$ac_exeext
23415 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23416   (eval $ac_link) 2>conftest.er1
23417   ac_status=$?
23418   grep -v '^ *+' conftest.er1 >conftest.err
23419   rm -f conftest.er1
23420   cat conftest.err >&5
23421   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23422   (exit $ac_status); } &&
23423          { ac_try='test -z "$ac_c_werror_flag"
23424                          || test ! -s conftest.err'
23425   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23426   (eval $ac_try) 2>&5
23427   ac_status=$?
23428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23429   (exit $ac_status); }; } &&
23430          { ac_try='test -s conftest$ac_exeext'
23431   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23432   (eval $ac_try) 2>&5
23433   ac_status=$?
23434   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23435   (exit $ac_status); }; }; then
23436   ol_cv_pthread_lpthreads_lmach_lexc=yes
23437 else
23438   echo "$as_me: failed program was:" >&5
23439 sed 's/^/| /' conftest.$ac_ext >&5
23440
23441 ol_cv_pthread_lpthreads_lmach_lexc=no
23442 fi
23443 rm -f conftest.err conftest.$ac_objext \
23444       conftest$ac_exeext conftest.$ac_ext
23445 else
23446   cat >conftest.$ac_ext <<_ACEOF
23447 /* confdefs.h.  */
23448 _ACEOF
23449 cat confdefs.h >>conftest.$ac_ext
23450 cat >>conftest.$ac_ext <<_ACEOF
23451 /* end confdefs.h.  */
23452
23453 /* pthread test headers */
23454 #include <pthread.h>
23455 #if HAVE_PTHREADS < 7
23456 #include <errno.h>
23457 #endif
23458 #ifndef NULL
23459 #define NULL (void*)0
23460 #endif
23461
23462 static void *task(p)
23463         void *p;
23464 {
23465         return (void *) (p == NULL);
23466 }
23467
23468
23469 int main(argc, argv)
23470         int argc;
23471         char **argv;
23472 {
23473
23474         /* pthread test function */
23475 #ifndef PTHREAD_CREATE_DETACHED
23476 #define PTHREAD_CREATE_DETACHED 1
23477 #endif
23478         pthread_t t;
23479         int status;
23480         int detach = PTHREAD_CREATE_DETACHED;
23481
23482 #if HAVE_PTHREADS > 4
23483         /* Final pthreads */
23484         pthread_attr_t attr;
23485
23486         status = pthread_attr_init(&attr);
23487         if( status ) return status;
23488
23489 #if HAVE_PTHREADS < 7
23490         status = pthread_attr_setdetachstate(&attr, &detach);
23491         if( status < 0 ) status = errno;
23492 #else
23493         status = pthread_attr_setdetachstate(&attr, detach);
23494 #endif
23495         if( status ) return status;
23496         status = pthread_create( &t, &attr, task, NULL );
23497 #if HAVE_PTHREADS < 7
23498         if( status < 0 ) status = errno;
23499 #endif
23500         if( status ) return status;
23501 #else
23502         /* Draft 4 pthreads */
23503         status = pthread_create( &t, pthread_attr_default, task, NULL );
23504         if( status ) return errno;
23505
23506         /* give thread a chance to complete */
23507         /* it should remain joinable and hence detachable */
23508         sleep( 1 );
23509
23510         status = pthread_detach( &t );
23511         if( status ) return errno;
23512 #endif
23513
23514 #ifdef HAVE_LINUX_THREADS
23515         pthread_kill_other_threads_np();
23516 #endif
23517
23518         return 0;
23519
23520 }
23521
23522 _ACEOF
23523 rm -f conftest$ac_exeext
23524 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23525   (eval $ac_link) 2>&5
23526   ac_status=$?
23527   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23528   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23529   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23530   (eval $ac_try) 2>&5
23531   ac_status=$?
23532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23533   (exit $ac_status); }; }; then
23534   ol_cv_pthread_lpthreads_lmach_lexc=yes
23535 else
23536   echo "$as_me: program exited with status $ac_status" >&5
23537 echo "$as_me: failed program was:" >&5
23538 sed 's/^/| /' conftest.$ac_ext >&5
23539
23540 ( exit $ac_status )
23541 ol_cv_pthread_lpthreads_lmach_lexc=no
23542 fi
23543 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23544 fi
23545
23546                 # restore the LIBS
23547                 LIBS="$ol_LIBS"
23548
23549 fi
23550 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lmach_lexc" >&5
23551 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lmach_lexc" >&6
23552
23553         if test $ol_cv_pthread_lpthreads_lmach_lexc = yes ; then
23554                 ol_link_pthreads="-lpthreads -lmach -lexc"
23555                 ol_link_threads=posix
23556         fi
23557 fi
23558
23559                 # Pthread try link: -lpthreads -lexc (ol_cv_pthread_lpthreads_lexc)
23560 if test "$ol_link_threads" = no ; then
23561         # try -lpthreads -lexc
23562         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lexc" >&5
23563 echo $ECHO_N "checking for pthread link with -lpthreads -lexc... $ECHO_C" >&6
23564 if test "${ol_cv_pthread_lpthreads_lexc+set}" = set; then
23565   echo $ECHO_N "(cached) $ECHO_C" >&6
23566 else
23567
23568                 # save the flags
23569                 ol_LIBS="$LIBS"
23570                 LIBS="-lpthreads -lexc $LIBS"
23571
23572                 if test "$cross_compiling" = yes; then
23573   cat >conftest.$ac_ext <<_ACEOF
23574 /* confdefs.h.  */
23575 _ACEOF
23576 cat confdefs.h >>conftest.$ac_ext
23577 cat >>conftest.$ac_ext <<_ACEOF
23578 /* end confdefs.h.  */
23579
23580 /* pthread test headers */
23581 #include <pthread.h>
23582 #if HAVE_PTHREADS < 7
23583 #include <errno.h>
23584 #endif
23585 #ifndef NULL
23586 #define NULL (void*)0
23587 #endif
23588
23589 static void *task(p)
23590         void *p;
23591 {
23592         return (void *) (p == NULL);
23593 }
23594
23595 int
23596 main ()
23597 {
23598
23599         /* pthread test function */
23600 #ifndef PTHREAD_CREATE_DETACHED
23601 #define PTHREAD_CREATE_DETACHED 1
23602 #endif
23603         pthread_t t;
23604         int status;
23605         int detach = PTHREAD_CREATE_DETACHED;
23606
23607 #if HAVE_PTHREADS > 4
23608         /* Final pthreads */
23609         pthread_attr_t attr;
23610
23611         status = pthread_attr_init(&attr);
23612         if( status ) return status;
23613
23614 #if HAVE_PTHREADS < 7
23615         status = pthread_attr_setdetachstate(&attr, &detach);
23616         if( status < 0 ) status = errno;
23617 #else
23618         status = pthread_attr_setdetachstate(&attr, detach);
23619 #endif
23620         if( status ) return status;
23621         status = pthread_create( &t, &attr, task, NULL );
23622 #if HAVE_PTHREADS < 7
23623         if( status < 0 ) status = errno;
23624 #endif
23625         if( status ) return status;
23626 #else
23627         /* Draft 4 pthreads */
23628         status = pthread_create( &t, pthread_attr_default, task, NULL );
23629         if( status ) return errno;
23630
23631         /* give thread a chance to complete */
23632         /* it should remain joinable and hence detachable */
23633         sleep( 1 );
23634
23635         status = pthread_detach( &t );
23636         if( status ) return errno;
23637 #endif
23638
23639 #ifdef HAVE_LINUX_THREADS
23640         pthread_kill_other_threads_np();
23641 #endif
23642
23643         return 0;
23644
23645   ;
23646   return 0;
23647 }
23648 _ACEOF
23649 rm -f conftest.$ac_objext conftest$ac_exeext
23650 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23651   (eval $ac_link) 2>conftest.er1
23652   ac_status=$?
23653   grep -v '^ *+' conftest.er1 >conftest.err
23654   rm -f conftest.er1
23655   cat conftest.err >&5
23656   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23657   (exit $ac_status); } &&
23658          { ac_try='test -z "$ac_c_werror_flag"
23659                          || test ! -s conftest.err'
23660   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23661   (eval $ac_try) 2>&5
23662   ac_status=$?
23663   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23664   (exit $ac_status); }; } &&
23665          { ac_try='test -s conftest$ac_exeext'
23666   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23667   (eval $ac_try) 2>&5
23668   ac_status=$?
23669   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23670   (exit $ac_status); }; }; then
23671   ol_cv_pthread_lpthreads_lexc=yes
23672 else
23673   echo "$as_me: failed program was:" >&5
23674 sed 's/^/| /' conftest.$ac_ext >&5
23675
23676 ol_cv_pthread_lpthreads_lexc=no
23677 fi
23678 rm -f conftest.err conftest.$ac_objext \
23679       conftest$ac_exeext conftest.$ac_ext
23680 else
23681   cat >conftest.$ac_ext <<_ACEOF
23682 /* confdefs.h.  */
23683 _ACEOF
23684 cat confdefs.h >>conftest.$ac_ext
23685 cat >>conftest.$ac_ext <<_ACEOF
23686 /* end confdefs.h.  */
23687
23688 /* pthread test headers */
23689 #include <pthread.h>
23690 #if HAVE_PTHREADS < 7
23691 #include <errno.h>
23692 #endif
23693 #ifndef NULL
23694 #define NULL (void*)0
23695 #endif
23696
23697 static void *task(p)
23698         void *p;
23699 {
23700         return (void *) (p == NULL);
23701 }
23702
23703
23704 int main(argc, argv)
23705         int argc;
23706         char **argv;
23707 {
23708
23709         /* pthread test function */
23710 #ifndef PTHREAD_CREATE_DETACHED
23711 #define PTHREAD_CREATE_DETACHED 1
23712 #endif
23713         pthread_t t;
23714         int status;
23715         int detach = PTHREAD_CREATE_DETACHED;
23716
23717 #if HAVE_PTHREADS > 4
23718         /* Final pthreads */
23719         pthread_attr_t attr;
23720
23721         status = pthread_attr_init(&attr);
23722         if( status ) return status;
23723
23724 #if HAVE_PTHREADS < 7
23725         status = pthread_attr_setdetachstate(&attr, &detach);
23726         if( status < 0 ) status = errno;
23727 #else
23728         status = pthread_attr_setdetachstate(&attr, detach);
23729 #endif
23730         if( status ) return status;
23731         status = pthread_create( &t, &attr, task, NULL );
23732 #if HAVE_PTHREADS < 7
23733         if( status < 0 ) status = errno;
23734 #endif
23735         if( status ) return status;
23736 #else
23737         /* Draft 4 pthreads */
23738         status = pthread_create( &t, pthread_attr_default, task, NULL );
23739         if( status ) return errno;
23740
23741         /* give thread a chance to complete */
23742         /* it should remain joinable and hence detachable */
23743         sleep( 1 );
23744
23745         status = pthread_detach( &t );
23746         if( status ) return errno;
23747 #endif
23748
23749 #ifdef HAVE_LINUX_THREADS
23750         pthread_kill_other_threads_np();
23751 #endif
23752
23753         return 0;
23754
23755 }
23756
23757 _ACEOF
23758 rm -f conftest$ac_exeext
23759 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23760   (eval $ac_link) 2>&5
23761   ac_status=$?
23762   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23763   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23764   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23765   (eval $ac_try) 2>&5
23766   ac_status=$?
23767   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23768   (exit $ac_status); }; }; then
23769   ol_cv_pthread_lpthreads_lexc=yes
23770 else
23771   echo "$as_me: program exited with status $ac_status" >&5
23772 echo "$as_me: failed program was:" >&5
23773 sed 's/^/| /' conftest.$ac_ext >&5
23774
23775 ( exit $ac_status )
23776 ol_cv_pthread_lpthreads_lexc=no
23777 fi
23778 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23779 fi
23780
23781                 # restore the LIBS
23782                 LIBS="$ol_LIBS"
23783
23784 fi
23785 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lexc" >&5
23786 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lexc" >&6
23787
23788         if test $ol_cv_pthread_lpthreads_lexc = yes ; then
23789                 ol_link_pthreads="-lpthreads -lexc"
23790                 ol_link_threads=posix
23791         fi
23792 fi
23793
23794
23795                 # Pthread try link: -lpthreads (ol_cv_pthread_lib_lpthreads)
23796 if test "$ol_link_threads" = no ; then
23797         # try -lpthreads
23798         echo "$as_me:$LINENO: checking for pthread link with -lpthreads" >&5
23799 echo $ECHO_N "checking for pthread link with -lpthreads... $ECHO_C" >&6
23800 if test "${ol_cv_pthread_lib_lpthreads+set}" = set; then
23801   echo $ECHO_N "(cached) $ECHO_C" >&6
23802 else
23803
23804                 # save the flags
23805                 ol_LIBS="$LIBS"
23806                 LIBS="-lpthreads $LIBS"
23807
23808                 if test "$cross_compiling" = yes; then
23809   cat >conftest.$ac_ext <<_ACEOF
23810 /* confdefs.h.  */
23811 _ACEOF
23812 cat confdefs.h >>conftest.$ac_ext
23813 cat >>conftest.$ac_ext <<_ACEOF
23814 /* end confdefs.h.  */
23815
23816 /* pthread test headers */
23817 #include <pthread.h>
23818 #if HAVE_PTHREADS < 7
23819 #include <errno.h>
23820 #endif
23821 #ifndef NULL
23822 #define NULL (void*)0
23823 #endif
23824
23825 static void *task(p)
23826         void *p;
23827 {
23828         return (void *) (p == NULL);
23829 }
23830
23831 int
23832 main ()
23833 {
23834
23835         /* pthread test function */
23836 #ifndef PTHREAD_CREATE_DETACHED
23837 #define PTHREAD_CREATE_DETACHED 1
23838 #endif
23839         pthread_t t;
23840         int status;
23841         int detach = PTHREAD_CREATE_DETACHED;
23842
23843 #if HAVE_PTHREADS > 4
23844         /* Final pthreads */
23845         pthread_attr_t attr;
23846
23847         status = pthread_attr_init(&attr);
23848         if( status ) return status;
23849
23850 #if HAVE_PTHREADS < 7
23851         status = pthread_attr_setdetachstate(&attr, &detach);
23852         if( status < 0 ) status = errno;
23853 #else
23854         status = pthread_attr_setdetachstate(&attr, detach);
23855 #endif
23856         if( status ) return status;
23857         status = pthread_create( &t, &attr, task, NULL );
23858 #if HAVE_PTHREADS < 7
23859         if( status < 0 ) status = errno;
23860 #endif
23861         if( status ) return status;
23862 #else
23863         /* Draft 4 pthreads */
23864         status = pthread_create( &t, pthread_attr_default, task, NULL );
23865         if( status ) return errno;
23866
23867         /* give thread a chance to complete */
23868         /* it should remain joinable and hence detachable */
23869         sleep( 1 );
23870
23871         status = pthread_detach( &t );
23872         if( status ) return errno;
23873 #endif
23874
23875 #ifdef HAVE_LINUX_THREADS
23876         pthread_kill_other_threads_np();
23877 #endif
23878
23879         return 0;
23880
23881   ;
23882   return 0;
23883 }
23884 _ACEOF
23885 rm -f conftest.$ac_objext conftest$ac_exeext
23886 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23887   (eval $ac_link) 2>conftest.er1
23888   ac_status=$?
23889   grep -v '^ *+' conftest.er1 >conftest.err
23890   rm -f conftest.er1
23891   cat conftest.err >&5
23892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23893   (exit $ac_status); } &&
23894          { ac_try='test -z "$ac_c_werror_flag"
23895                          || test ! -s conftest.err'
23896   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23897   (eval $ac_try) 2>&5
23898   ac_status=$?
23899   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23900   (exit $ac_status); }; } &&
23901          { ac_try='test -s conftest$ac_exeext'
23902   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23903   (eval $ac_try) 2>&5
23904   ac_status=$?
23905   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23906   (exit $ac_status); }; }; then
23907   ol_cv_pthread_lib_lpthreads=yes
23908 else
23909   echo "$as_me: failed program was:" >&5
23910 sed 's/^/| /' conftest.$ac_ext >&5
23911
23912 ol_cv_pthread_lib_lpthreads=no
23913 fi
23914 rm -f conftest.err conftest.$ac_objext \
23915       conftest$ac_exeext conftest.$ac_ext
23916 else
23917   cat >conftest.$ac_ext <<_ACEOF
23918 /* confdefs.h.  */
23919 _ACEOF
23920 cat confdefs.h >>conftest.$ac_ext
23921 cat >>conftest.$ac_ext <<_ACEOF
23922 /* end confdefs.h.  */
23923
23924 /* pthread test headers */
23925 #include <pthread.h>
23926 #if HAVE_PTHREADS < 7
23927 #include <errno.h>
23928 #endif
23929 #ifndef NULL
23930 #define NULL (void*)0
23931 #endif
23932
23933 static void *task(p)
23934         void *p;
23935 {
23936         return (void *) (p == NULL);
23937 }
23938
23939
23940 int main(argc, argv)
23941         int argc;
23942         char **argv;
23943 {
23944
23945         /* pthread test function */
23946 #ifndef PTHREAD_CREATE_DETACHED
23947 #define PTHREAD_CREATE_DETACHED 1
23948 #endif
23949         pthread_t t;
23950         int status;
23951         int detach = PTHREAD_CREATE_DETACHED;
23952
23953 #if HAVE_PTHREADS > 4
23954         /* Final pthreads */
23955         pthread_attr_t attr;
23956
23957         status = pthread_attr_init(&attr);
23958         if( status ) return status;
23959
23960 #if HAVE_PTHREADS < 7
23961         status = pthread_attr_setdetachstate(&attr, &detach);
23962         if( status < 0 ) status = errno;
23963 #else
23964         status = pthread_attr_setdetachstate(&attr, detach);
23965 #endif
23966         if( status ) return status;
23967         status = pthread_create( &t, &attr, task, NULL );
23968 #if HAVE_PTHREADS < 7
23969         if( status < 0 ) status = errno;
23970 #endif
23971         if( status ) return status;
23972 #else
23973         /* Draft 4 pthreads */
23974         status = pthread_create( &t, pthread_attr_default, task, NULL );
23975         if( status ) return errno;
23976
23977         /* give thread a chance to complete */
23978         /* it should remain joinable and hence detachable */
23979         sleep( 1 );
23980
23981         status = pthread_detach( &t );
23982         if( status ) return errno;
23983 #endif
23984
23985 #ifdef HAVE_LINUX_THREADS
23986         pthread_kill_other_threads_np();
23987 #endif
23988
23989         return 0;
23990
23991 }
23992
23993 _ACEOF
23994 rm -f conftest$ac_exeext
23995 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23996   (eval $ac_link) 2>&5
23997   ac_status=$?
23998   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23999   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24000   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24001   (eval $ac_try) 2>&5
24002   ac_status=$?
24003   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24004   (exit $ac_status); }; }; then
24005   ol_cv_pthread_lib_lpthreads=yes
24006 else
24007   echo "$as_me: program exited with status $ac_status" >&5
24008 echo "$as_me: failed program was:" >&5
24009 sed 's/^/| /' conftest.$ac_ext >&5
24010
24011 ( exit $ac_status )
24012 ol_cv_pthread_lib_lpthreads=no
24013 fi
24014 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24015 fi
24016
24017                 # restore the LIBS
24018                 LIBS="$ol_LIBS"
24019
24020 fi
24021 echo "$as_me:$LINENO: result: $ol_cv_pthread_lib_lpthreads" >&5
24022 echo "${ECHO_T}$ol_cv_pthread_lib_lpthreads" >&6
24023
24024         if test $ol_cv_pthread_lib_lpthreads = yes ; then
24025                 ol_link_pthreads="-lpthreads"
24026                 ol_link_threads=posix
24027         fi
24028 fi
24029
24030
24031                 if test $ol_link_threads != no ; then
24032                         LTHREAD_LIBS="$LTHREAD_LIBS $ol_link_pthreads"
24033
24034                                                 save_CPPFLAGS="$CPPFLAGS"
24035                         save_LIBS="$LIBS"
24036                         LIBS="$LTHREAD_LIBS $LIBS"
24037
24038
24039
24040
24041 for ac_func in sched_yield pthread_yield thr_yield
24042 do
24043 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
24044 echo "$as_me:$LINENO: checking for $ac_func" >&5
24045 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
24046 if eval "test \"\${$as_ac_var+set}\" = set"; then
24047   echo $ECHO_N "(cached) $ECHO_C" >&6
24048 else
24049   cat >conftest.$ac_ext <<_ACEOF
24050 /* confdefs.h.  */
24051 _ACEOF
24052 cat confdefs.h >>conftest.$ac_ext
24053 cat >>conftest.$ac_ext <<_ACEOF
24054 /* end confdefs.h.  */
24055 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
24056    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24057 #define $ac_func innocuous_$ac_func
24058
24059 /* System header to define __stub macros and hopefully few prototypes,
24060     which can conflict with char $ac_func (); below.
24061     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24062     <limits.h> exists even on freestanding compilers.  */
24063
24064 #ifdef __STDC__
24065 # include <limits.h>
24066 #else
24067 # include <assert.h>
24068 #endif
24069
24070 #undef $ac_func
24071
24072 /* Override any gcc2 internal prototype to avoid an error.  */
24073 #ifdef __cplusplus
24074 extern "C"
24075 {
24076 #endif
24077 /* We use char because int might match the return type of a gcc2
24078    builtin and then its argument prototype would still apply.  */
24079 char $ac_func ();
24080 /* The GNU C library defines this for functions which it implements
24081     to always fail with ENOSYS.  Some functions are actually named
24082     something starting with __ and the normal name is an alias.  */
24083 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
24084 choke me
24085 #else
24086 char (*f) () = $ac_func;
24087 #endif
24088 #ifdef __cplusplus
24089 }
24090 #endif
24091
24092 int
24093 main ()
24094 {
24095 return f != $ac_func;
24096   ;
24097   return 0;
24098 }
24099 _ACEOF
24100 rm -f conftest.$ac_objext conftest$ac_exeext
24101 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24102   (eval $ac_link) 2>conftest.er1
24103   ac_status=$?
24104   grep -v '^ *+' conftest.er1 >conftest.err
24105   rm -f conftest.er1
24106   cat conftest.err >&5
24107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24108   (exit $ac_status); } &&
24109          { ac_try='test -z "$ac_c_werror_flag"
24110                          || test ! -s conftest.err'
24111   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24112   (eval $ac_try) 2>&5
24113   ac_status=$?
24114   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24115   (exit $ac_status); }; } &&
24116          { ac_try='test -s conftest$ac_exeext'
24117   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24118   (eval $ac_try) 2>&5
24119   ac_status=$?
24120   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24121   (exit $ac_status); }; }; then
24122   eval "$as_ac_var=yes"
24123 else
24124   echo "$as_me: failed program was:" >&5
24125 sed 's/^/| /' conftest.$ac_ext >&5
24126
24127 eval "$as_ac_var=no"
24128 fi
24129 rm -f conftest.err conftest.$ac_objext \
24130       conftest$ac_exeext conftest.$ac_ext
24131 fi
24132 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
24133 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
24134 if test `eval echo '${'$as_ac_var'}'` = yes; then
24135   cat >>confdefs.h <<_ACEOF
24136 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
24137 _ACEOF
24138
24139 fi
24140 done
24141
24142
24143                         if test $ac_cv_func_sched_yield = no &&
24144                            test $ac_cv_func_pthread_yield = no &&
24145                            test $ac_cv_func_thr_yield = no ; then
24146                                                                 echo "$as_me:$LINENO: checking for sched_yield in -lrt" >&5
24147 echo $ECHO_N "checking for sched_yield in -lrt... $ECHO_C" >&6
24148 if test "${ac_cv_lib_rt_sched_yield+set}" = set; then
24149   echo $ECHO_N "(cached) $ECHO_C" >&6
24150 else
24151   ac_check_lib_save_LIBS=$LIBS
24152 LIBS="-lrt  $LIBS"
24153 cat >conftest.$ac_ext <<_ACEOF
24154 /* confdefs.h.  */
24155 _ACEOF
24156 cat confdefs.h >>conftest.$ac_ext
24157 cat >>conftest.$ac_ext <<_ACEOF
24158 /* end confdefs.h.  */
24159
24160 /* Override any gcc2 internal prototype to avoid an error.  */
24161 #ifdef __cplusplus
24162 extern "C"
24163 #endif
24164 /* We use char because int might match the return type of a gcc2
24165    builtin and then its argument prototype would still apply.  */
24166 char sched_yield ();
24167 int
24168 main ()
24169 {
24170 sched_yield ();
24171   ;
24172   return 0;
24173 }
24174 _ACEOF
24175 rm -f conftest.$ac_objext conftest$ac_exeext
24176 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24177   (eval $ac_link) 2>conftest.er1
24178   ac_status=$?
24179   grep -v '^ *+' conftest.er1 >conftest.err
24180   rm -f conftest.er1
24181   cat conftest.err >&5
24182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24183   (exit $ac_status); } &&
24184          { ac_try='test -z "$ac_c_werror_flag"
24185                          || test ! -s conftest.err'
24186   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24187   (eval $ac_try) 2>&5
24188   ac_status=$?
24189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24190   (exit $ac_status); }; } &&
24191          { ac_try='test -s conftest$ac_exeext'
24192   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24193   (eval $ac_try) 2>&5
24194   ac_status=$?
24195   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24196   (exit $ac_status); }; }; then
24197   ac_cv_lib_rt_sched_yield=yes
24198 else
24199   echo "$as_me: failed program was:" >&5
24200 sed 's/^/| /' conftest.$ac_ext >&5
24201
24202 ac_cv_lib_rt_sched_yield=no
24203 fi
24204 rm -f conftest.err conftest.$ac_objext \
24205       conftest$ac_exeext conftest.$ac_ext
24206 LIBS=$ac_check_lib_save_LIBS
24207 fi
24208 echo "$as_me:$LINENO: result: $ac_cv_lib_rt_sched_yield" >&5
24209 echo "${ECHO_T}$ac_cv_lib_rt_sched_yield" >&6
24210 if test $ac_cv_lib_rt_sched_yield = yes; then
24211   LTHREAD_LIBS="$LTHREAD_LIBS -lrt"
24212
24213 cat >>confdefs.h <<\_ACEOF
24214 #define HAVE_SCHED_YIELD 1
24215 _ACEOF
24216
24217                                         ac_cv_func_sched_yield=yes
24218 else
24219   ac_cv_func_sched_yield=no
24220 fi
24221
24222                         fi
24223                         if test $ac_cv_func_sched_yield = no &&
24224                            test $ac_cv_func_pthread_yield = no &&
24225                            test "$ac_cv_func_thr_yield" = no ; then
24226                                 { echo "$as_me:$LINENO: WARNING: could not locate sched_yield() or pthread_yield()" >&5
24227 echo "$as_me: WARNING: could not locate sched_yield() or pthread_yield()" >&2;}
24228                         fi
24229
24230
24231
24232 for ac_func in pthread_kill pthread_rwlock_destroy
24233 do
24234 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
24235 echo "$as_me:$LINENO: checking for $ac_func" >&5
24236 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
24237 if eval "test \"\${$as_ac_var+set}\" = set"; then
24238   echo $ECHO_N "(cached) $ECHO_C" >&6
24239 else
24240   cat >conftest.$ac_ext <<_ACEOF
24241 /* confdefs.h.  */
24242 _ACEOF
24243 cat confdefs.h >>conftest.$ac_ext
24244 cat >>conftest.$ac_ext <<_ACEOF
24245 /* end confdefs.h.  */
24246 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
24247    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24248 #define $ac_func innocuous_$ac_func
24249
24250 /* System header to define __stub macros and hopefully few prototypes,
24251     which can conflict with char $ac_func (); below.
24252     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24253     <limits.h> exists even on freestanding compilers.  */
24254
24255 #ifdef __STDC__
24256 # include <limits.h>
24257 #else
24258 # include <assert.h>
24259 #endif
24260
24261 #undef $ac_func
24262
24263 /* Override any gcc2 internal prototype to avoid an error.  */
24264 #ifdef __cplusplus
24265 extern "C"
24266 {
24267 #endif
24268 /* We use char because int might match the return type of a gcc2
24269    builtin and then its argument prototype would still apply.  */
24270 char $ac_func ();
24271 /* The GNU C library defines this for functions which it implements
24272     to always fail with ENOSYS.  Some functions are actually named
24273     something starting with __ and the normal name is an alias.  */
24274 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
24275 choke me
24276 #else
24277 char (*f) () = $ac_func;
24278 #endif
24279 #ifdef __cplusplus
24280 }
24281 #endif
24282
24283 int
24284 main ()
24285 {
24286 return f != $ac_func;
24287   ;
24288   return 0;
24289 }
24290 _ACEOF
24291 rm -f conftest.$ac_objext conftest$ac_exeext
24292 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24293   (eval $ac_link) 2>conftest.er1
24294   ac_status=$?
24295   grep -v '^ *+' conftest.er1 >conftest.err
24296   rm -f conftest.er1
24297   cat conftest.err >&5
24298   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24299   (exit $ac_status); } &&
24300          { ac_try='test -z "$ac_c_werror_flag"
24301                          || test ! -s conftest.err'
24302   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24303   (eval $ac_try) 2>&5
24304   ac_status=$?
24305   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24306   (exit $ac_status); }; } &&
24307          { ac_try='test -s conftest$ac_exeext'
24308   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24309   (eval $ac_try) 2>&5
24310   ac_status=$?
24311   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24312   (exit $ac_status); }; }; then
24313   eval "$as_ac_var=yes"
24314 else
24315   echo "$as_me: failed program was:" >&5
24316 sed 's/^/| /' conftest.$ac_ext >&5
24317
24318 eval "$as_ac_var=no"
24319 fi
24320 rm -f conftest.err conftest.$ac_objext \
24321       conftest$ac_exeext conftest.$ac_ext
24322 fi
24323 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
24324 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
24325 if test `eval echo '${'$as_ac_var'}'` = yes; then
24326   cat >>confdefs.h <<_ACEOF
24327 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
24328 _ACEOF
24329
24330 fi
24331 done
24332
24333
24334                                                                         echo "$as_me:$LINENO: checking for pthread_detach with <pthread.h>" >&5
24335 echo $ECHO_N "checking for pthread_detach with <pthread.h>... $ECHO_C" >&6
24336 if test "${ol_cv_func_pthread_detach+set}" = set; then
24337   echo $ECHO_N "(cached) $ECHO_C" >&6
24338 else
24339
24340                                                                 cat >conftest.$ac_ext <<_ACEOF
24341 /* confdefs.h.  */
24342 _ACEOF
24343 cat confdefs.h >>conftest.$ac_ext
24344 cat >>conftest.$ac_ext <<_ACEOF
24345 /* end confdefs.h.  */
24346
24347 #include <pthread.h>
24348 #ifndef NULL
24349 #define NULL (void*)0
24350 #endif
24351
24352 int
24353 main ()
24354 {
24355 pthread_detach(NULL);
24356   ;
24357   return 0;
24358 }
24359 _ACEOF
24360 rm -f conftest.$ac_objext conftest$ac_exeext
24361 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24362   (eval $ac_link) 2>conftest.er1
24363   ac_status=$?
24364   grep -v '^ *+' conftest.er1 >conftest.err
24365   rm -f conftest.er1
24366   cat conftest.err >&5
24367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24368   (exit $ac_status); } &&
24369          { ac_try='test -z "$ac_c_werror_flag"
24370                          || test ! -s conftest.err'
24371   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24372   (eval $ac_try) 2>&5
24373   ac_status=$?
24374   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24375   (exit $ac_status); }; } &&
24376          { ac_try='test -s conftest$ac_exeext'
24377   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24378   (eval $ac_try) 2>&5
24379   ac_status=$?
24380   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24381   (exit $ac_status); }; }; then
24382   ol_cv_func_pthread_detach=yes
24383 else
24384   echo "$as_me: failed program was:" >&5
24385 sed 's/^/| /' conftest.$ac_ext >&5
24386
24387 ol_cv_func_pthread_detach=no
24388 fi
24389 rm -f conftest.err conftest.$ac_objext \
24390       conftest$ac_exeext conftest.$ac_ext
24391
24392 fi
24393 echo "$as_me:$LINENO: result: $ol_cv_func_pthread_detach" >&5
24394 echo "${ECHO_T}$ol_cv_func_pthread_detach" >&6
24395
24396                         if test $ol_cv_func_pthread_detach = no ; then
24397                                 { { echo "$as_me:$LINENO: error: could not locate pthread_detach()" >&5
24398 echo "$as_me: error: could not locate pthread_detach()" >&2;}
24399    { (exit 1); exit 1; }; }
24400                         fi
24401
24402
24403 cat >>confdefs.h <<\_ACEOF
24404 #define HAVE_PTHREAD_DETACH 1
24405 _ACEOF
24406
24407
24408
24409
24410
24411
24412 for ac_func in \
24413                                 pthread_setconcurrency \
24414                                 pthread_getconcurrency \
24415                                 thr_setconcurrency \
24416                                 thr_getconcurrency \
24417
24418 do
24419 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
24420 echo "$as_me:$LINENO: checking for $ac_func" >&5
24421 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
24422 if eval "test \"\${$as_ac_var+set}\" = set"; then
24423   echo $ECHO_N "(cached) $ECHO_C" >&6
24424 else
24425   cat >conftest.$ac_ext <<_ACEOF
24426 /* confdefs.h.  */
24427 _ACEOF
24428 cat confdefs.h >>conftest.$ac_ext
24429 cat >>conftest.$ac_ext <<_ACEOF
24430 /* end confdefs.h.  */
24431 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
24432    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24433 #define $ac_func innocuous_$ac_func
24434
24435 /* System header to define __stub macros and hopefully few prototypes,
24436     which can conflict with char $ac_func (); below.
24437     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24438     <limits.h> exists even on freestanding compilers.  */
24439
24440 #ifdef __STDC__
24441 # include <limits.h>
24442 #else
24443 # include <assert.h>
24444 #endif
24445
24446 #undef $ac_func
24447
24448 /* Override any gcc2 internal prototype to avoid an error.  */
24449 #ifdef __cplusplus
24450 extern "C"
24451 {
24452 #endif
24453 /* We use char because int might match the return type of a gcc2
24454    builtin and then its argument prototype would still apply.  */
24455 char $ac_func ();
24456 /* The GNU C library defines this for functions which it implements
24457     to always fail with ENOSYS.  Some functions are actually named
24458     something starting with __ and the normal name is an alias.  */
24459 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
24460 choke me
24461 #else
24462 char (*f) () = $ac_func;
24463 #endif
24464 #ifdef __cplusplus
24465 }
24466 #endif
24467
24468 int
24469 main ()
24470 {
24471 return f != $ac_func;
24472   ;
24473   return 0;
24474 }
24475 _ACEOF
24476 rm -f conftest.$ac_objext conftest$ac_exeext
24477 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24478   (eval $ac_link) 2>conftest.er1
24479   ac_status=$?
24480   grep -v '^ *+' conftest.er1 >conftest.err
24481   rm -f conftest.er1
24482   cat conftest.err >&5
24483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24484   (exit $ac_status); } &&
24485          { ac_try='test -z "$ac_c_werror_flag"
24486                          || test ! -s conftest.err'
24487   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24488   (eval $ac_try) 2>&5
24489   ac_status=$?
24490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24491   (exit $ac_status); }; } &&
24492          { ac_try='test -s conftest$ac_exeext'
24493   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24494   (eval $ac_try) 2>&5
24495   ac_status=$?
24496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24497   (exit $ac_status); }; }; then
24498   eval "$as_ac_var=yes"
24499 else
24500   echo "$as_me: failed program was:" >&5
24501 sed 's/^/| /' conftest.$ac_ext >&5
24502
24503 eval "$as_ac_var=no"
24504 fi
24505 rm -f conftest.err conftest.$ac_objext \
24506       conftest$ac_exeext conftest.$ac_ext
24507 fi
24508 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
24509 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
24510 if test `eval echo '${'$as_ac_var'}'` = yes; then
24511   cat >>confdefs.h <<_ACEOF
24512 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
24513 _ACEOF
24514
24515 fi
24516 done
24517
24518
24519
24520
24521 for ac_func in pthread_kill_other_threads_np
24522 do
24523 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
24524 echo "$as_me:$LINENO: checking for $ac_func" >&5
24525 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
24526 if eval "test \"\${$as_ac_var+set}\" = set"; then
24527   echo $ECHO_N "(cached) $ECHO_C" >&6
24528 else
24529   cat >conftest.$ac_ext <<_ACEOF
24530 /* confdefs.h.  */
24531 _ACEOF
24532 cat confdefs.h >>conftest.$ac_ext
24533 cat >>conftest.$ac_ext <<_ACEOF
24534 /* end confdefs.h.  */
24535 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
24536    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24537 #define $ac_func innocuous_$ac_func
24538
24539 /* System header to define __stub macros and hopefully few prototypes,
24540     which can conflict with char $ac_func (); below.
24541     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24542     <limits.h> exists even on freestanding compilers.  */
24543
24544 #ifdef __STDC__
24545 # include <limits.h>
24546 #else
24547 # include <assert.h>
24548 #endif
24549
24550 #undef $ac_func
24551
24552 /* Override any gcc2 internal prototype to avoid an error.  */
24553 #ifdef __cplusplus
24554 extern "C"
24555 {
24556 #endif
24557 /* We use char because int might match the return type of a gcc2
24558    builtin and then its argument prototype would still apply.  */
24559 char $ac_func ();
24560 /* The GNU C library defines this for functions which it implements
24561     to always fail with ENOSYS.  Some functions are actually named
24562     something starting with __ and the normal name is an alias.  */
24563 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
24564 choke me
24565 #else
24566 char (*f) () = $ac_func;
24567 #endif
24568 #ifdef __cplusplus
24569 }
24570 #endif
24571
24572 int
24573 main ()
24574 {
24575 return f != $ac_func;
24576   ;
24577   return 0;
24578 }
24579 _ACEOF
24580 rm -f conftest.$ac_objext conftest$ac_exeext
24581 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24582   (eval $ac_link) 2>conftest.er1
24583   ac_status=$?
24584   grep -v '^ *+' conftest.er1 >conftest.err
24585   rm -f conftest.er1
24586   cat conftest.err >&5
24587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24588   (exit $ac_status); } &&
24589          { ac_try='test -z "$ac_c_werror_flag"
24590                          || test ! -s conftest.err'
24591   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24592   (eval $ac_try) 2>&5
24593   ac_status=$?
24594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24595   (exit $ac_status); }; } &&
24596          { ac_try='test -s conftest$ac_exeext'
24597   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24598   (eval $ac_try) 2>&5
24599   ac_status=$?
24600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24601   (exit $ac_status); }; }; then
24602   eval "$as_ac_var=yes"
24603 else
24604   echo "$as_me: failed program was:" >&5
24605 sed 's/^/| /' conftest.$ac_ext >&5
24606
24607 eval "$as_ac_var=no"
24608 fi
24609 rm -f conftest.err conftest.$ac_objext \
24610       conftest$ac_exeext conftest.$ac_ext
24611 fi
24612 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
24613 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
24614 if test `eval echo '${'$as_ac_var'}'` = yes; then
24615   cat >>confdefs.h <<_ACEOF
24616 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
24617 _ACEOF
24618
24619 fi
24620 done
24621
24622         echo "$as_me:$LINENO: checking for LinuxThreads implementation" >&5
24623 echo $ECHO_N "checking for LinuxThreads implementation... $ECHO_C" >&6
24624 if test "${ol_cv_sys_linux_threads+set}" = set; then
24625   echo $ECHO_N "(cached) $ECHO_C" >&6
24626 else
24627   ol_cv_sys_linux_threads=$ac_cv_func_pthread_kill_other_threads_np
24628 fi
24629 echo "$as_me:$LINENO: result: $ol_cv_sys_linux_threads" >&5
24630 echo "${ECHO_T}$ol_cv_sys_linux_threads" >&6
24631
24632
24633
24634
24635         echo "$as_me:$LINENO: checking for LinuxThreads consistency" >&5
24636 echo $ECHO_N "checking for LinuxThreads consistency... $ECHO_C" >&6
24637 if test "${ol_cv_linux_threads+set}" = set; then
24638   echo $ECHO_N "(cached) $ECHO_C" >&6
24639 else
24640
24641                 if test $ol_cv_header_linux_threads = yes &&
24642                    test $ol_cv_sys_linux_threads = yes; then
24643                         ol_cv_linux_threads=yes
24644                 elif test $ol_cv_header_linux_threads = no &&
24645                      test $ol_cv_sys_linux_threads = no; then
24646                         ol_cv_linux_threads=no
24647                 else
24648                         ol_cv_linux_threads=error
24649                 fi
24650
24651 fi
24652 echo "$as_me:$LINENO: result: $ol_cv_linux_threads" >&5
24653 echo "${ECHO_T}$ol_cv_linux_threads" >&6
24654
24655
24656                         if test $ol_cv_linux_threads = error; then
24657                                 { { echo "$as_me:$LINENO: error: LinuxThreads header/library mismatch" >&5
24658 echo "$as_me: error: LinuxThreads header/library mismatch" >&2;}
24659    { (exit 1); exit 1; }; };
24660                         fi
24661
24662                         echo "$as_me:$LINENO: checking if pthread_create() works" >&5
24663 echo $ECHO_N "checking if pthread_create() works... $ECHO_C" >&6
24664 if test "${ol_cv_pthread_create_works+set}" = set; then
24665   echo $ECHO_N "(cached) $ECHO_C" >&6
24666 else
24667
24668                         if test "$cross_compiling" = yes; then
24669                                 ol_cv_pthread_create_works=yes
24670 else
24671   cat >conftest.$ac_ext <<_ACEOF
24672 /* confdefs.h.  */
24673 _ACEOF
24674 cat confdefs.h >>conftest.$ac_ext
24675 cat >>conftest.$ac_ext <<_ACEOF
24676 /* end confdefs.h.  */
24677
24678 /* pthread test headers */
24679 #include <pthread.h>
24680 #if HAVE_PTHREADS < 7
24681 #include <errno.h>
24682 #endif
24683 #ifndef NULL
24684 #define NULL (void*)0
24685 #endif
24686
24687 static void *task(p)
24688         void *p;
24689 {
24690         return (void *) (p == NULL);
24691 }
24692
24693
24694 int main(argc, argv)
24695         int argc;
24696         char **argv;
24697 {
24698
24699         /* pthread test function */
24700 #ifndef PTHREAD_CREATE_DETACHED
24701 #define PTHREAD_CREATE_DETACHED 1
24702 #endif
24703         pthread_t t;
24704         int status;
24705         int detach = PTHREAD_CREATE_DETACHED;
24706
24707 #if HAVE_PTHREADS > 4
24708         /* Final pthreads */
24709         pthread_attr_t attr;
24710
24711         status = pthread_attr_init(&attr);
24712         if( status ) return status;
24713
24714 #if HAVE_PTHREADS < 7
24715         status = pthread_attr_setdetachstate(&attr, &detach);
24716         if( status < 0 ) status = errno;
24717 #else
24718         status = pthread_attr_setdetachstate(&attr, detach);
24719 #endif
24720         if( status ) return status;
24721         status = pthread_create( &t, &attr, task, NULL );
24722 #if HAVE_PTHREADS < 7
24723         if( status < 0 ) status = errno;
24724 #endif
24725         if( status ) return status;
24726 #else
24727         /* Draft 4 pthreads */
24728         status = pthread_create( &t, pthread_attr_default, task, NULL );
24729         if( status ) return errno;
24730
24731         /* give thread a chance to complete */
24732         /* it should remain joinable and hence detachable */
24733         sleep( 1 );
24734
24735         status = pthread_detach( &t );
24736         if( status ) return errno;
24737 #endif
24738
24739 #ifdef HAVE_LINUX_THREADS
24740         pthread_kill_other_threads_np();
24741 #endif
24742
24743         return 0;
24744
24745 }
24746
24747 _ACEOF
24748 rm -f conftest$ac_exeext
24749 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24750   (eval $ac_link) 2>&5
24751   ac_status=$?
24752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24753   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24754   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24755   (eval $ac_try) 2>&5
24756   ac_status=$?
24757   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24758   (exit $ac_status); }; }; then
24759   ol_cv_pthread_create_works=yes
24760 else
24761   echo "$as_me: program exited with status $ac_status" >&5
24762 echo "$as_me: failed program was:" >&5
24763 sed 's/^/| /' conftest.$ac_ext >&5
24764
24765 ( exit $ac_status )
24766 ol_cv_pthread_create_works=no
24767 fi
24768 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24769 fi
24770 fi
24771 echo "$as_me:$LINENO: result: $ol_cv_pthread_create_works" >&5
24772 echo "${ECHO_T}$ol_cv_pthread_create_works" >&6
24773
24774                         if test $ol_cv_pthread_create_works = no ; then
24775                                 { { echo "$as_me:$LINENO: error: pthread_create is not usable, check environment settings" >&5
24776 echo "$as_me: error: pthread_create is not usable, check environment settings" >&2;}
24777    { (exit 1); exit 1; }; }
24778                         fi
24779
24780                         ol_replace_broken_yield=no
24781
24782                         if test $ol_replace_broken_yield = yes ; then
24783
24784 cat >>confdefs.h <<\_ACEOF
24785 #define REPLACE_BROKEN_YIELD 1
24786 _ACEOF
24787
24788                         fi
24789
24790                                                 if test $ol_with_yielding_select = auto ; then
24791                                 echo "$as_me:$LINENO: checking if select yields when using pthreads" >&5
24792 echo $ECHO_N "checking if select yields when using pthreads... $ECHO_C" >&6
24793 if test "${ol_cv_pthread_select_yields+set}" = set; then
24794   echo $ECHO_N "(cached) $ECHO_C" >&6
24795 else
24796
24797                                 if test "$cross_compiling" = yes; then
24798   ol_cv_pthread_select_yields=cross
24799 else
24800   cat >conftest.$ac_ext <<_ACEOF
24801 /* confdefs.h.  */
24802 _ACEOF
24803 cat confdefs.h >>conftest.$ac_ext
24804 cat >>conftest.$ac_ext <<_ACEOF
24805 /* end confdefs.h.  */
24806
24807 #include <sys/types.h>
24808 #include <sys/time.h>
24809 #include <unistd.h>
24810 #include <pthread.h>
24811 #ifndef NULL
24812 #define NULL (void*) 0
24813 #endif
24814
24815 static int fildes[2];
24816
24817 static void *task(p)
24818         void *p;
24819 {
24820         int i;
24821         struct timeval tv;
24822
24823         fd_set rfds;
24824
24825         tv.tv_sec=10;
24826         tv.tv_usec=0;
24827
24828         FD_ZERO(&rfds);
24829         FD_SET(fildes[0], &rfds);
24830
24831         /* we're not interested in any fds */
24832         i = select(FD_SETSIZE, &rfds, NULL, NULL, &tv);
24833
24834         if(i < 0) {
24835                 perror("select");
24836                 exit(10);
24837         }
24838
24839         exit(0); /* if we exit here, the select blocked the whole process */
24840 }
24841
24842 int main(argc, argv)
24843         int argc;
24844         char **argv;
24845 {
24846         pthread_t t;
24847
24848         /* create a pipe to select */
24849         if(pipe(&fildes[0])) {
24850                 perror("select");
24851                 exit(1);
24852         }
24853
24854 #ifdef HAVE_PTHREAD_SETCONCURRENCY
24855         (void) pthread_setconcurrency(2);
24856 #else
24857 #ifdef HAVE_THR_SETCONCURRENCY
24858         /* Set Solaris LWP concurrency to 2 */
24859         thr_setconcurrency(2);
24860 #endif
24861 #endif
24862
24863 #if HAVE_PTHREADS < 6
24864         pthread_create(&t, pthread_attr_default, task, NULL);
24865 #else
24866         pthread_create(&t, NULL, task, NULL);
24867 #endif
24868
24869         /* make sure task runs first */
24870 #if HAVE_THR_YIELD
24871         thr_yield();
24872 #elif defined( HAVE_SCHED_YIELD )
24873         sched_yield();
24874 #elif defined( HAVE_PTHREAD_YIELD )
24875         pthread_yield();
24876 #endif
24877
24878         exit(2);
24879 }
24880 _ACEOF
24881 rm -f conftest$ac_exeext
24882 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24883   (eval $ac_link) 2>&5
24884   ac_status=$?
24885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24886   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24887   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24888   (eval $ac_try) 2>&5
24889   ac_status=$?
24890   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24891   (exit $ac_status); }; }; then
24892   ol_cv_pthread_select_yields=no
24893 else
24894   echo "$as_me: program exited with status $ac_status" >&5
24895 echo "$as_me: failed program was:" >&5
24896 sed 's/^/| /' conftest.$ac_ext >&5
24897
24898 ( exit $ac_status )
24899 ol_cv_pthread_select_yields=yes
24900 fi
24901 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24902 fi
24903 fi
24904 echo "$as_me:$LINENO: result: $ol_cv_pthread_select_yields" >&5
24905 echo "${ECHO_T}$ol_cv_pthread_select_yields" >&6
24906
24907                                 if test $ol_cv_pthread_select_yields = cross ; then
24908                                         { { echo "$as_me:$LINENO: error: crossing compiling: use --with-yielding_select=yes|no|manual" >&5
24909 echo "$as_me: error: crossing compiling: use --with-yielding_select=yes|no|manual" >&2;}
24910    { (exit 1); exit 1; }; }
24911                                 fi
24912
24913                                 if test $ol_cv_pthread_select_yields = yes ; then
24914                                         ol_with_yielding_select=yes
24915                                 fi
24916                         fi
24917
24918                                                 CPPFLAGS="$save_CPPFLAGS"
24919                         LIBS="$save_LIBS"
24920                 else
24921                         { { echo "$as_me:$LINENO: error: could not locate usable POSIX Threads" >&5
24922 echo "$as_me: error: could not locate usable POSIX Threads" >&2;}
24923    { (exit 1); exit 1; }; }
24924                 fi
24925         fi
24926
24927         if test $ol_with_threads = posix ; then
24928                 { { echo "$as_me:$LINENO: error: could not locate POSIX Threads" >&5
24929 echo "$as_me: error: could not locate POSIX Threads" >&2;}
24930    { (exit 1); exit 1; }; }
24931         fi
24932         ;;
24933 esac
24934
24935 case $ol_with_threads in auto | yes | mach)
24936
24937
24938
24939 for ac_header in mach/cthreads.h cthreads.h
24940 do
24941 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
24942 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24943   echo "$as_me:$LINENO: checking for $ac_header" >&5
24944 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24945 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24946   echo $ECHO_N "(cached) $ECHO_C" >&6
24947 fi
24948 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24949 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24950 else
24951   # Is the header compilable?
24952 echo "$as_me:$LINENO: checking $ac_header usability" >&5
24953 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
24954 cat >conftest.$ac_ext <<_ACEOF
24955 /* confdefs.h.  */
24956 _ACEOF
24957 cat confdefs.h >>conftest.$ac_ext
24958 cat >>conftest.$ac_ext <<_ACEOF
24959 /* end confdefs.h.  */
24960 $ac_includes_default
24961 #include <$ac_header>
24962 _ACEOF
24963 rm -f conftest.$ac_objext
24964 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
24965   (eval $ac_compile) 2>conftest.er1
24966   ac_status=$?
24967   grep -v '^ *+' conftest.er1 >conftest.err
24968   rm -f conftest.er1
24969   cat conftest.err >&5
24970   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24971   (exit $ac_status); } &&
24972          { ac_try='test -z "$ac_c_werror_flag"
24973                          || test ! -s conftest.err'
24974   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24975   (eval $ac_try) 2>&5
24976   ac_status=$?
24977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24978   (exit $ac_status); }; } &&
24979          { ac_try='test -s conftest.$ac_objext'
24980   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24981   (eval $ac_try) 2>&5
24982   ac_status=$?
24983   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24984   (exit $ac_status); }; }; then
24985   ac_header_compiler=yes
24986 else
24987   echo "$as_me: failed program was:" >&5
24988 sed 's/^/| /' conftest.$ac_ext >&5
24989
24990 ac_header_compiler=no
24991 fi
24992 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
24993 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
24994 echo "${ECHO_T}$ac_header_compiler" >&6
24995
24996 # Is the header present?
24997 echo "$as_me:$LINENO: checking $ac_header presence" >&5
24998 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
24999 cat >conftest.$ac_ext <<_ACEOF
25000 /* confdefs.h.  */
25001 _ACEOF
25002 cat confdefs.h >>conftest.$ac_ext
25003 cat >>conftest.$ac_ext <<_ACEOF
25004 /* end confdefs.h.  */
25005 #include <$ac_header>
25006 _ACEOF
25007 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25008   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25009   ac_status=$?
25010   grep -v '^ *+' conftest.er1 >conftest.err
25011   rm -f conftest.er1
25012   cat conftest.err >&5
25013   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25014   (exit $ac_status); } >/dev/null; then
25015   if test -s conftest.err; then
25016     ac_cpp_err=$ac_c_preproc_warn_flag
25017     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25018   else
25019     ac_cpp_err=
25020   fi
25021 else
25022   ac_cpp_err=yes
25023 fi
25024 if test -z "$ac_cpp_err"; then
25025   ac_header_preproc=yes
25026 else
25027   echo "$as_me: failed program was:" >&5
25028 sed 's/^/| /' conftest.$ac_ext >&5
25029
25030   ac_header_preproc=no
25031 fi
25032 rm -f conftest.err conftest.$ac_ext
25033 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25034 echo "${ECHO_T}$ac_header_preproc" >&6
25035
25036 # So?  What about this header?
25037 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25038   yes:no: )
25039     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25040 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25041     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25042 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25043     ac_header_preproc=yes
25044     ;;
25045   no:yes:* )
25046     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25047 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25048     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25049 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25050     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25051 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25052     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25053 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25054     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25055 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25056     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25057 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25058     (
25059       cat <<\_ASBOX
25060 ## --------------------------------------------- ##
25061 ## Report this to <http://www.openldap.org/its/> ##
25062 ## --------------------------------------------- ##
25063 _ASBOX
25064     ) |
25065       sed "s/^/$as_me: WARNING:     /" >&2
25066     ;;
25067 esac
25068 echo "$as_me:$LINENO: checking for $ac_header" >&5
25069 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25070 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25071   echo $ECHO_N "(cached) $ECHO_C" >&6
25072 else
25073   eval "$as_ac_Header=\$ac_header_preproc"
25074 fi
25075 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25076 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25077
25078 fi
25079 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25080   cat >>confdefs.h <<_ACEOF
25081 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25082 _ACEOF
25083
25084 fi
25085
25086 done
25087
25088         if test $ac_cv_header_mach_cthreads_h = yes ; then
25089                 ol_with_threads=found
25090
25091                                 echo "$as_me:$LINENO: checking for cthread_fork" >&5
25092 echo $ECHO_N "checking for cthread_fork... $ECHO_C" >&6
25093 if test "${ac_cv_func_cthread_fork+set}" = set; then
25094   echo $ECHO_N "(cached) $ECHO_C" >&6
25095 else
25096   cat >conftest.$ac_ext <<_ACEOF
25097 /* confdefs.h.  */
25098 _ACEOF
25099 cat confdefs.h >>conftest.$ac_ext
25100 cat >>conftest.$ac_ext <<_ACEOF
25101 /* end confdefs.h.  */
25102 /* Define cthread_fork to an innocuous variant, in case <limits.h> declares cthread_fork.
25103    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
25104 #define cthread_fork innocuous_cthread_fork
25105
25106 /* System header to define __stub macros and hopefully few prototypes,
25107     which can conflict with char cthread_fork (); below.
25108     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
25109     <limits.h> exists even on freestanding compilers.  */
25110
25111 #ifdef __STDC__
25112 # include <limits.h>
25113 #else
25114 # include <assert.h>
25115 #endif
25116
25117 #undef cthread_fork
25118
25119 /* Override any gcc2 internal prototype to avoid an error.  */
25120 #ifdef __cplusplus
25121 extern "C"
25122 {
25123 #endif
25124 /* We use char because int might match the return type of a gcc2
25125    builtin and then its argument prototype would still apply.  */
25126 char cthread_fork ();
25127 /* The GNU C library defines this for functions which it implements
25128     to always fail with ENOSYS.  Some functions are actually named
25129     something starting with __ and the normal name is an alias.  */
25130 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
25131 choke me
25132 #else
25133 char (*f) () = cthread_fork;
25134 #endif
25135 #ifdef __cplusplus
25136 }
25137 #endif
25138
25139 int
25140 main ()
25141 {
25142 return f != cthread_fork;
25143   ;
25144   return 0;
25145 }
25146 _ACEOF
25147 rm -f conftest.$ac_objext conftest$ac_exeext
25148 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25149   (eval $ac_link) 2>conftest.er1
25150   ac_status=$?
25151   grep -v '^ *+' conftest.er1 >conftest.err
25152   rm -f conftest.er1
25153   cat conftest.err >&5
25154   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25155   (exit $ac_status); } &&
25156          { ac_try='test -z "$ac_c_werror_flag"
25157                          || test ! -s conftest.err'
25158   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25159   (eval $ac_try) 2>&5
25160   ac_status=$?
25161   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25162   (exit $ac_status); }; } &&
25163          { ac_try='test -s conftest$ac_exeext'
25164   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25165   (eval $ac_try) 2>&5
25166   ac_status=$?
25167   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25168   (exit $ac_status); }; }; then
25169   ac_cv_func_cthread_fork=yes
25170 else
25171   echo "$as_me: failed program was:" >&5
25172 sed 's/^/| /' conftest.$ac_ext >&5
25173
25174 ac_cv_func_cthread_fork=no
25175 fi
25176 rm -f conftest.err conftest.$ac_objext \
25177       conftest$ac_exeext conftest.$ac_ext
25178 fi
25179 echo "$as_me:$LINENO: result: $ac_cv_func_cthread_fork" >&5
25180 echo "${ECHO_T}$ac_cv_func_cthread_fork" >&6
25181 if test $ac_cv_func_cthread_fork = yes; then
25182   ol_link_threads=yes
25183 fi
25184
25185
25186                 if test $ol_link_threads = no ; then
25187                                                                         echo "$as_me:$LINENO: checking for cthread_fork with -all_load" >&5
25188 echo $ECHO_N "checking for cthread_fork with -all_load... $ECHO_C" >&6
25189 if test "${ol_cv_cthread_all_load+set}" = set; then
25190   echo $ECHO_N "(cached) $ECHO_C" >&6
25191 else
25192
25193                                                                 save_LIBS="$LIBS"
25194                                 LIBS="-all_load $LIBS"
25195                                 cat >conftest.$ac_ext <<_ACEOF
25196 /* confdefs.h.  */
25197 _ACEOF
25198 cat confdefs.h >>conftest.$ac_ext
25199 cat >>conftest.$ac_ext <<_ACEOF
25200 /* end confdefs.h.  */
25201 #include <mach/cthreads.h>
25202 int
25203 main ()
25204 {
25205
25206                                         cthread_fork((void *)0, (void *)0);
25207
25208   ;
25209   return 0;
25210 }
25211 _ACEOF
25212 rm -f conftest.$ac_objext conftest$ac_exeext
25213 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25214   (eval $ac_link) 2>conftest.er1
25215   ac_status=$?
25216   grep -v '^ *+' conftest.er1 >conftest.err
25217   rm -f conftest.er1
25218   cat conftest.err >&5
25219   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25220   (exit $ac_status); } &&
25221          { ac_try='test -z "$ac_c_werror_flag"
25222                          || test ! -s conftest.err'
25223   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25224   (eval $ac_try) 2>&5
25225   ac_status=$?
25226   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25227   (exit $ac_status); }; } &&
25228          { ac_try='test -s conftest$ac_exeext'
25229   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25230   (eval $ac_try) 2>&5
25231   ac_status=$?
25232   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25233   (exit $ac_status); }; }; then
25234   ol_cv_cthread_all_load=yes
25235 else
25236   echo "$as_me: failed program was:" >&5
25237 sed 's/^/| /' conftest.$ac_ext >&5
25238
25239 ol_cv_cthread_all_load=no
25240 fi
25241 rm -f conftest.err conftest.$ac_objext \
25242       conftest$ac_exeext conftest.$ac_ext
25243                                                                 LIBS="$save_LIBS"
25244
25245 fi
25246 echo "$as_me:$LINENO: result: $ol_cv_cthread_all_load" >&5
25247 echo "${ECHO_T}$ol_cv_cthread_all_load" >&6
25248
25249                         if test $ol_cv_cthread_all_load = yes ; then
25250                                 LTHREAD_LIBS="$LTHREAD_LIBS -all_load"
25251                                 ol_link_threads=mach
25252                                 ol_with_threads=found
25253                         fi
25254                 fi
25255
25256         elif test $ac_cv_header_cthreads_h = yes ; then
25257
25258                 ol_with_threads=found
25259
25260                                 save_LIBS="$LIBS"
25261                 LIBS="$LIBS -lthreads"
25262                 echo "$as_me:$LINENO: checking for cthread_fork" >&5
25263 echo $ECHO_N "checking for cthread_fork... $ECHO_C" >&6
25264 if test "${ac_cv_func_cthread_fork+set}" = set; then
25265   echo $ECHO_N "(cached) $ECHO_C" >&6
25266 else
25267   cat >conftest.$ac_ext <<_ACEOF
25268 /* confdefs.h.  */
25269 _ACEOF
25270 cat confdefs.h >>conftest.$ac_ext
25271 cat >>conftest.$ac_ext <<_ACEOF
25272 /* end confdefs.h.  */
25273 /* Define cthread_fork to an innocuous variant, in case <limits.h> declares cthread_fork.
25274    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
25275 #define cthread_fork innocuous_cthread_fork
25276
25277 /* System header to define __stub macros and hopefully few prototypes,
25278     which can conflict with char cthread_fork (); below.
25279     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
25280     <limits.h> exists even on freestanding compilers.  */
25281
25282 #ifdef __STDC__
25283 # include <limits.h>
25284 #else
25285 # include <assert.h>
25286 #endif
25287
25288 #undef cthread_fork
25289
25290 /* Override any gcc2 internal prototype to avoid an error.  */
25291 #ifdef __cplusplus
25292 extern "C"
25293 {
25294 #endif
25295 /* We use char because int might match the return type of a gcc2
25296    builtin and then its argument prototype would still apply.  */
25297 char cthread_fork ();
25298 /* The GNU C library defines this for functions which it implements
25299     to always fail with ENOSYS.  Some functions are actually named
25300     something starting with __ and the normal name is an alias.  */
25301 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
25302 choke me
25303 #else
25304 char (*f) () = cthread_fork;
25305 #endif
25306 #ifdef __cplusplus
25307 }
25308 #endif
25309
25310 int
25311 main ()
25312 {
25313 return f != cthread_fork;
25314   ;
25315   return 0;
25316 }
25317 _ACEOF
25318 rm -f conftest.$ac_objext conftest$ac_exeext
25319 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25320   (eval $ac_link) 2>conftest.er1
25321   ac_status=$?
25322   grep -v '^ *+' conftest.er1 >conftest.err
25323   rm -f conftest.er1
25324   cat conftest.err >&5
25325   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25326   (exit $ac_status); } &&
25327          { ac_try='test -z "$ac_c_werror_flag"
25328                          || test ! -s conftest.err'
25329   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25330   (eval $ac_try) 2>&5
25331   ac_status=$?
25332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25333   (exit $ac_status); }; } &&
25334          { ac_try='test -s conftest$ac_exeext'
25335   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25336   (eval $ac_try) 2>&5
25337   ac_status=$?
25338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25339   (exit $ac_status); }; }; then
25340   ac_cv_func_cthread_fork=yes
25341 else
25342   echo "$as_me: failed program was:" >&5
25343 sed 's/^/| /' conftest.$ac_ext >&5
25344
25345 ac_cv_func_cthread_fork=no
25346 fi
25347 rm -f conftest.err conftest.$ac_objext \
25348       conftest$ac_exeext conftest.$ac_ext
25349 fi
25350 echo "$as_me:$LINENO: result: $ac_cv_func_cthread_fork" >&5
25351 echo "${ECHO_T}$ac_cv_func_cthread_fork" >&6
25352 if test $ac_cv_func_cthread_fork = yes; then
25353   ol_link_threads=yes
25354 fi
25355
25356                 LIBS="$save_LIBS"
25357
25358                 if test $ol_link_threads = yes ; then
25359                         LTHREAD_LIBS="-lthreads"
25360                         ol_link_threads=mach
25361                         ol_with_threads=found
25362                 else
25363                         { { echo "$as_me:$LINENO: error: could not link with Mach CThreads" >&5
25364 echo "$as_me: error: could not link with Mach CThreads" >&2;}
25365    { (exit 1); exit 1; }; }
25366                 fi
25367
25368         elif test $ol_with_threads = mach ; then
25369                 { { echo "$as_me:$LINENO: error: could not locate Mach CThreads" >&5
25370 echo "$as_me: error: could not locate Mach CThreads" >&2;}
25371    { (exit 1); exit 1; }; }
25372         fi
25373
25374         if test $ol_link_threads = mach ; then
25375
25376 cat >>confdefs.h <<\_ACEOF
25377 #define HAVE_MACH_CTHREADS 1
25378 _ACEOF
25379
25380         elif test $ol_with_threads = found ; then
25381                 { { echo "$as_me:$LINENO: error: could not link with Mach CThreads" >&5
25382 echo "$as_me: error: could not link with Mach CThreads" >&2;}
25383    { (exit 1); exit 1; }; }
25384         fi
25385         ;;
25386 esac
25387
25388 case $ol_with_threads in auto | yes | pth)
25389
25390
25391 for ac_header in pth.h
25392 do
25393 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25394 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25395   echo "$as_me:$LINENO: checking for $ac_header" >&5
25396 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25397 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25398   echo $ECHO_N "(cached) $ECHO_C" >&6
25399 fi
25400 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25401 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25402 else
25403   # Is the header compilable?
25404 echo "$as_me:$LINENO: checking $ac_header usability" >&5
25405 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
25406 cat >conftest.$ac_ext <<_ACEOF
25407 /* confdefs.h.  */
25408 _ACEOF
25409 cat confdefs.h >>conftest.$ac_ext
25410 cat >>conftest.$ac_ext <<_ACEOF
25411 /* end confdefs.h.  */
25412 $ac_includes_default
25413 #include <$ac_header>
25414 _ACEOF
25415 rm -f conftest.$ac_objext
25416 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
25417   (eval $ac_compile) 2>conftest.er1
25418   ac_status=$?
25419   grep -v '^ *+' conftest.er1 >conftest.err
25420   rm -f conftest.er1
25421   cat conftest.err >&5
25422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25423   (exit $ac_status); } &&
25424          { ac_try='test -z "$ac_c_werror_flag"
25425                          || test ! -s conftest.err'
25426   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25427   (eval $ac_try) 2>&5
25428   ac_status=$?
25429   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25430   (exit $ac_status); }; } &&
25431          { ac_try='test -s conftest.$ac_objext'
25432   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25433   (eval $ac_try) 2>&5
25434   ac_status=$?
25435   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25436   (exit $ac_status); }; }; then
25437   ac_header_compiler=yes
25438 else
25439   echo "$as_me: failed program was:" >&5
25440 sed 's/^/| /' conftest.$ac_ext >&5
25441
25442 ac_header_compiler=no
25443 fi
25444 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
25445 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25446 echo "${ECHO_T}$ac_header_compiler" >&6
25447
25448 # Is the header present?
25449 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25450 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25451 cat >conftest.$ac_ext <<_ACEOF
25452 /* confdefs.h.  */
25453 _ACEOF
25454 cat confdefs.h >>conftest.$ac_ext
25455 cat >>conftest.$ac_ext <<_ACEOF
25456 /* end confdefs.h.  */
25457 #include <$ac_header>
25458 _ACEOF
25459 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25460   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25461   ac_status=$?
25462   grep -v '^ *+' conftest.er1 >conftest.err
25463   rm -f conftest.er1
25464   cat conftest.err >&5
25465   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25466   (exit $ac_status); } >/dev/null; then
25467   if test -s conftest.err; then
25468     ac_cpp_err=$ac_c_preproc_warn_flag
25469     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25470   else
25471     ac_cpp_err=
25472   fi
25473 else
25474   ac_cpp_err=yes
25475 fi
25476 if test -z "$ac_cpp_err"; then
25477   ac_header_preproc=yes
25478 else
25479   echo "$as_me: failed program was:" >&5
25480 sed 's/^/| /' conftest.$ac_ext >&5
25481
25482   ac_header_preproc=no
25483 fi
25484 rm -f conftest.err conftest.$ac_ext
25485 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25486 echo "${ECHO_T}$ac_header_preproc" >&6
25487
25488 # So?  What about this header?
25489 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25490   yes:no: )
25491     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25492 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25493     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25494 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25495     ac_header_preproc=yes
25496     ;;
25497   no:yes:* )
25498     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25499 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25500     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25501 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25502     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25503 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25504     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25505 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25506     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25507 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25508     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25509 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25510     (
25511       cat <<\_ASBOX
25512 ## --------------------------------------------- ##
25513 ## Report this to <http://www.openldap.org/its/> ##
25514 ## --------------------------------------------- ##
25515 _ASBOX
25516     ) |
25517       sed "s/^/$as_me: WARNING:     /" >&2
25518     ;;
25519 esac
25520 echo "$as_me:$LINENO: checking for $ac_header" >&5
25521 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25522 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25523   echo $ECHO_N "(cached) $ECHO_C" >&6
25524 else
25525   eval "$as_ac_Header=\$ac_header_preproc"
25526 fi
25527 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25528 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25529
25530 fi
25531 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25532   cat >>confdefs.h <<_ACEOF
25533 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25534 _ACEOF
25535
25536 fi
25537
25538 done
25539
25540
25541         if test $ac_cv_header_pth_h = yes ; then
25542                 echo "$as_me:$LINENO: checking for pth_version in -lpth" >&5
25543 echo $ECHO_N "checking for pth_version in -lpth... $ECHO_C" >&6
25544 if test "${ac_cv_lib_pth_pth_version+set}" = set; then
25545   echo $ECHO_N "(cached) $ECHO_C" >&6
25546 else
25547   ac_check_lib_save_LIBS=$LIBS
25548 LIBS="-lpth  $LIBS"
25549 cat >conftest.$ac_ext <<_ACEOF
25550 /* confdefs.h.  */
25551 _ACEOF
25552 cat confdefs.h >>conftest.$ac_ext
25553 cat >>conftest.$ac_ext <<_ACEOF
25554 /* end confdefs.h.  */
25555
25556 /* Override any gcc2 internal prototype to avoid an error.  */
25557 #ifdef __cplusplus
25558 extern "C"
25559 #endif
25560 /* We use char because int might match the return type of a gcc2
25561    builtin and then its argument prototype would still apply.  */
25562 char pth_version ();
25563 int
25564 main ()
25565 {
25566 pth_version ();
25567   ;
25568   return 0;
25569 }
25570 _ACEOF
25571 rm -f conftest.$ac_objext conftest$ac_exeext
25572 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25573   (eval $ac_link) 2>conftest.er1
25574   ac_status=$?
25575   grep -v '^ *+' conftest.er1 >conftest.err
25576   rm -f conftest.er1
25577   cat conftest.err >&5
25578   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25579   (exit $ac_status); } &&
25580          { ac_try='test -z "$ac_c_werror_flag"
25581                          || test ! -s conftest.err'
25582   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25583   (eval $ac_try) 2>&5
25584   ac_status=$?
25585   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25586   (exit $ac_status); }; } &&
25587          { ac_try='test -s conftest$ac_exeext'
25588   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25589   (eval $ac_try) 2>&5
25590   ac_status=$?
25591   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25592   (exit $ac_status); }; }; then
25593   ac_cv_lib_pth_pth_version=yes
25594 else
25595   echo "$as_me: failed program was:" >&5
25596 sed 's/^/| /' conftest.$ac_ext >&5
25597
25598 ac_cv_lib_pth_pth_version=no
25599 fi
25600 rm -f conftest.err conftest.$ac_objext \
25601       conftest$ac_exeext conftest.$ac_ext
25602 LIBS=$ac_check_lib_save_LIBS
25603 fi
25604 echo "$as_me:$LINENO: result: $ac_cv_lib_pth_pth_version" >&5
25605 echo "${ECHO_T}$ac_cv_lib_pth_pth_version" >&6
25606 if test $ac_cv_lib_pth_pth_version = yes; then
25607   have_pth=yes
25608 else
25609   have_pth=no
25610 fi
25611
25612
25613                 if test $have_pth = yes ; then
25614
25615 cat >>confdefs.h <<\_ACEOF
25616 #define HAVE_GNU_PTH 1
25617 _ACEOF
25618
25619                         LTHREAD_LIBS="$LTHREAD_LIBS -lpth"
25620                         ol_link_threads=pth
25621                         ol_with_threads=found
25622
25623                         if test $ol_with_yielding_select = auto ; then
25624                                 ol_with_yielding_select=yes
25625                         fi
25626                 fi
25627         fi
25628         ;;
25629 esac
25630
25631 case $ol_with_threads in auto | yes | lwp)
25632
25633
25634
25635 for ac_header in thread.h synch.h
25636 do
25637 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25638 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25639   echo "$as_me:$LINENO: checking for $ac_header" >&5
25640 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25641 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25642   echo $ECHO_N "(cached) $ECHO_C" >&6
25643 fi
25644 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25645 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25646 else
25647   # Is the header compilable?
25648 echo "$as_me:$LINENO: checking $ac_header usability" >&5
25649 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
25650 cat >conftest.$ac_ext <<_ACEOF
25651 /* confdefs.h.  */
25652 _ACEOF
25653 cat confdefs.h >>conftest.$ac_ext
25654 cat >>conftest.$ac_ext <<_ACEOF
25655 /* end confdefs.h.  */
25656 $ac_includes_default
25657 #include <$ac_header>
25658 _ACEOF
25659 rm -f conftest.$ac_objext
25660 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
25661   (eval $ac_compile) 2>conftest.er1
25662   ac_status=$?
25663   grep -v '^ *+' conftest.er1 >conftest.err
25664   rm -f conftest.er1
25665   cat conftest.err >&5
25666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25667   (exit $ac_status); } &&
25668          { ac_try='test -z "$ac_c_werror_flag"
25669                          || test ! -s conftest.err'
25670   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25671   (eval $ac_try) 2>&5
25672   ac_status=$?
25673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25674   (exit $ac_status); }; } &&
25675          { ac_try='test -s conftest.$ac_objext'
25676   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25677   (eval $ac_try) 2>&5
25678   ac_status=$?
25679   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25680   (exit $ac_status); }; }; then
25681   ac_header_compiler=yes
25682 else
25683   echo "$as_me: failed program was:" >&5
25684 sed 's/^/| /' conftest.$ac_ext >&5
25685
25686 ac_header_compiler=no
25687 fi
25688 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
25689 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25690 echo "${ECHO_T}$ac_header_compiler" >&6
25691
25692 # Is the header present?
25693 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25694 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25695 cat >conftest.$ac_ext <<_ACEOF
25696 /* confdefs.h.  */
25697 _ACEOF
25698 cat confdefs.h >>conftest.$ac_ext
25699 cat >>conftest.$ac_ext <<_ACEOF
25700 /* end confdefs.h.  */
25701 #include <$ac_header>
25702 _ACEOF
25703 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25704   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25705   ac_status=$?
25706   grep -v '^ *+' conftest.er1 >conftest.err
25707   rm -f conftest.er1
25708   cat conftest.err >&5
25709   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25710   (exit $ac_status); } >/dev/null; then
25711   if test -s conftest.err; then
25712     ac_cpp_err=$ac_c_preproc_warn_flag
25713     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25714   else
25715     ac_cpp_err=
25716   fi
25717 else
25718   ac_cpp_err=yes
25719 fi
25720 if test -z "$ac_cpp_err"; then
25721   ac_header_preproc=yes
25722 else
25723   echo "$as_me: failed program was:" >&5
25724 sed 's/^/| /' conftest.$ac_ext >&5
25725
25726   ac_header_preproc=no
25727 fi
25728 rm -f conftest.err conftest.$ac_ext
25729 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25730 echo "${ECHO_T}$ac_header_preproc" >&6
25731
25732 # So?  What about this header?
25733 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25734   yes:no: )
25735     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25736 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25737     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25738 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25739     ac_header_preproc=yes
25740     ;;
25741   no:yes:* )
25742     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25743 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25744     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25745 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25746     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25747 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25748     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25749 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25750     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25751 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25752     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25753 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25754     (
25755       cat <<\_ASBOX
25756 ## --------------------------------------------- ##
25757 ## Report this to <http://www.openldap.org/its/> ##
25758 ## --------------------------------------------- ##
25759 _ASBOX
25760     ) |
25761       sed "s/^/$as_me: WARNING:     /" >&2
25762     ;;
25763 esac
25764 echo "$as_me:$LINENO: checking for $ac_header" >&5
25765 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25766 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25767   echo $ECHO_N "(cached) $ECHO_C" >&6
25768 else
25769   eval "$as_ac_Header=\$ac_header_preproc"
25770 fi
25771 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25772 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25773
25774 fi
25775 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25776   cat >>confdefs.h <<_ACEOF
25777 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25778 _ACEOF
25779
25780 fi
25781
25782 done
25783
25784         if test $ac_cv_header_thread_h = yes &&
25785            test $ac_cv_header_synch_h = yes ; then
25786                 echo "$as_me:$LINENO: checking for thr_create in -lthread" >&5
25787 echo $ECHO_N "checking for thr_create in -lthread... $ECHO_C" >&6
25788 if test "${ac_cv_lib_thread_thr_create+set}" = set; then
25789   echo $ECHO_N "(cached) $ECHO_C" >&6
25790 else
25791   ac_check_lib_save_LIBS=$LIBS
25792 LIBS="-lthread  $LIBS"
25793 cat >conftest.$ac_ext <<_ACEOF
25794 /* confdefs.h.  */
25795 _ACEOF
25796 cat confdefs.h >>conftest.$ac_ext
25797 cat >>conftest.$ac_ext <<_ACEOF
25798 /* end confdefs.h.  */
25799
25800 /* Override any gcc2 internal prototype to avoid an error.  */
25801 #ifdef __cplusplus
25802 extern "C"
25803 #endif
25804 /* We use char because int might match the return type of a gcc2
25805    builtin and then its argument prototype would still apply.  */
25806 char thr_create ();
25807 int
25808 main ()
25809 {
25810 thr_create ();
25811   ;
25812   return 0;
25813 }
25814 _ACEOF
25815 rm -f conftest.$ac_objext conftest$ac_exeext
25816 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25817   (eval $ac_link) 2>conftest.er1
25818   ac_status=$?
25819   grep -v '^ *+' conftest.er1 >conftest.err
25820   rm -f conftest.er1
25821   cat conftest.err >&5
25822   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25823   (exit $ac_status); } &&
25824          { ac_try='test -z "$ac_c_werror_flag"
25825                          || test ! -s conftest.err'
25826   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25827   (eval $ac_try) 2>&5
25828   ac_status=$?
25829   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25830   (exit $ac_status); }; } &&
25831          { ac_try='test -s conftest$ac_exeext'
25832   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25833   (eval $ac_try) 2>&5
25834   ac_status=$?
25835   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25836   (exit $ac_status); }; }; then
25837   ac_cv_lib_thread_thr_create=yes
25838 else
25839   echo "$as_me: failed program was:" >&5
25840 sed 's/^/| /' conftest.$ac_ext >&5
25841
25842 ac_cv_lib_thread_thr_create=no
25843 fi
25844 rm -f conftest.err conftest.$ac_objext \
25845       conftest$ac_exeext conftest.$ac_ext
25846 LIBS=$ac_check_lib_save_LIBS
25847 fi
25848 echo "$as_me:$LINENO: result: $ac_cv_lib_thread_thr_create" >&5
25849 echo "${ECHO_T}$ac_cv_lib_thread_thr_create" >&6
25850 if test $ac_cv_lib_thread_thr_create = yes; then
25851   have_thr=yes
25852 else
25853   have_thr=no
25854 fi
25855
25856
25857                 if test $have_thr = yes ; then
25858
25859 cat >>confdefs.h <<\_ACEOF
25860 #define HAVE_THR 1
25861 _ACEOF
25862
25863                         LTHREAD_LIBS="$LTHREAD_LIBS -lthread"
25864                         ol_link_threads=thr
25865
25866                         if test $ol_with_yielding_select = auto ; then
25867                                 ol_with_yielding_select=yes
25868                         fi
25869
25870
25871
25872 for ac_func in \
25873                                 thr_setconcurrency \
25874                                 thr_getconcurrency \
25875
25876 do
25877 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
25878 echo "$as_me:$LINENO: checking for $ac_func" >&5
25879 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
25880 if eval "test \"\${$as_ac_var+set}\" = set"; then
25881   echo $ECHO_N "(cached) $ECHO_C" >&6
25882 else
25883   cat >conftest.$ac_ext <<_ACEOF
25884 /* confdefs.h.  */
25885 _ACEOF
25886 cat confdefs.h >>conftest.$ac_ext
25887 cat >>conftest.$ac_ext <<_ACEOF
25888 /* end confdefs.h.  */
25889 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
25890    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
25891 #define $ac_func innocuous_$ac_func
25892
25893 /* System header to define __stub macros and hopefully few prototypes,
25894     which can conflict with char $ac_func (); below.
25895     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
25896     <limits.h> exists even on freestanding compilers.  */
25897
25898 #ifdef __STDC__
25899 # include <limits.h>
25900 #else
25901 # include <assert.h>
25902 #endif
25903
25904 #undef $ac_func
25905
25906 /* Override any gcc2 internal prototype to avoid an error.  */
25907 #ifdef __cplusplus
25908 extern "C"
25909 {
25910 #endif
25911 /* We use char because int might match the return type of a gcc2
25912    builtin and then its argument prototype would still apply.  */
25913 char $ac_func ();
25914 /* The GNU C library defines this for functions which it implements
25915     to always fail with ENOSYS.  Some functions are actually named
25916     something starting with __ and the normal name is an alias.  */
25917 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
25918 choke me
25919 #else
25920 char (*f) () = $ac_func;
25921 #endif
25922 #ifdef __cplusplus
25923 }
25924 #endif
25925
25926 int
25927 main ()
25928 {
25929 return f != $ac_func;
25930   ;
25931   return 0;
25932 }
25933 _ACEOF
25934 rm -f conftest.$ac_objext conftest$ac_exeext
25935 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25936   (eval $ac_link) 2>conftest.er1
25937   ac_status=$?
25938   grep -v '^ *+' conftest.er1 >conftest.err
25939   rm -f conftest.er1
25940   cat conftest.err >&5
25941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25942   (exit $ac_status); } &&
25943          { ac_try='test -z "$ac_c_werror_flag"
25944                          || test ! -s conftest.err'
25945   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25946   (eval $ac_try) 2>&5
25947   ac_status=$?
25948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25949   (exit $ac_status); }; } &&
25950          { ac_try='test -s conftest$ac_exeext'
25951   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25952   (eval $ac_try) 2>&5
25953   ac_status=$?
25954   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25955   (exit $ac_status); }; }; then
25956   eval "$as_ac_var=yes"
25957 else
25958   echo "$as_me: failed program was:" >&5
25959 sed 's/^/| /' conftest.$ac_ext >&5
25960
25961 eval "$as_ac_var=no"
25962 fi
25963 rm -f conftest.err conftest.$ac_objext \
25964       conftest$ac_exeext conftest.$ac_ext
25965 fi
25966 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
25967 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
25968 if test `eval echo '${'$as_ac_var'}'` = yes; then
25969   cat >>confdefs.h <<_ACEOF
25970 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
25971 _ACEOF
25972
25973 fi
25974 done
25975
25976                 fi
25977         fi
25978
25979
25980 for ac_header in lwp/lwp.h
25981 do
25982 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25983 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25984   echo "$as_me:$LINENO: checking for $ac_header" >&5
25985 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25986 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25987   echo $ECHO_N "(cached) $ECHO_C" >&6
25988 fi
25989 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25990 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25991 else
25992   # Is the header compilable?
25993 echo "$as_me:$LINENO: checking $ac_header usability" >&5
25994 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
25995 cat >conftest.$ac_ext <<_ACEOF
25996 /* confdefs.h.  */
25997 _ACEOF
25998 cat confdefs.h >>conftest.$ac_ext
25999 cat >>conftest.$ac_ext <<_ACEOF
26000 /* end confdefs.h.  */
26001 $ac_includes_default
26002 #include <$ac_header>
26003 _ACEOF
26004 rm -f conftest.$ac_objext
26005 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26006   (eval $ac_compile) 2>conftest.er1
26007   ac_status=$?
26008   grep -v '^ *+' conftest.er1 >conftest.err
26009   rm -f conftest.er1
26010   cat conftest.err >&5
26011   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26012   (exit $ac_status); } &&
26013          { ac_try='test -z "$ac_c_werror_flag"
26014                          || test ! -s conftest.err'
26015   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26016   (eval $ac_try) 2>&5
26017   ac_status=$?
26018   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26019   (exit $ac_status); }; } &&
26020          { ac_try='test -s conftest.$ac_objext'
26021   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26022   (eval $ac_try) 2>&5
26023   ac_status=$?
26024   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26025   (exit $ac_status); }; }; then
26026   ac_header_compiler=yes
26027 else
26028   echo "$as_me: failed program was:" >&5
26029 sed 's/^/| /' conftest.$ac_ext >&5
26030
26031 ac_header_compiler=no
26032 fi
26033 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26034 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26035 echo "${ECHO_T}$ac_header_compiler" >&6
26036
26037 # Is the header present?
26038 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26039 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26040 cat >conftest.$ac_ext <<_ACEOF
26041 /* confdefs.h.  */
26042 _ACEOF
26043 cat confdefs.h >>conftest.$ac_ext
26044 cat >>conftest.$ac_ext <<_ACEOF
26045 /* end confdefs.h.  */
26046 #include <$ac_header>
26047 _ACEOF
26048 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26049   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26050   ac_status=$?
26051   grep -v '^ *+' conftest.er1 >conftest.err
26052   rm -f conftest.er1
26053   cat conftest.err >&5
26054   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26055   (exit $ac_status); } >/dev/null; then
26056   if test -s conftest.err; then
26057     ac_cpp_err=$ac_c_preproc_warn_flag
26058     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26059   else
26060     ac_cpp_err=
26061   fi
26062 else
26063   ac_cpp_err=yes
26064 fi
26065 if test -z "$ac_cpp_err"; then
26066   ac_header_preproc=yes
26067 else
26068   echo "$as_me: failed program was:" >&5
26069 sed 's/^/| /' conftest.$ac_ext >&5
26070
26071   ac_header_preproc=no
26072 fi
26073 rm -f conftest.err conftest.$ac_ext
26074 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26075 echo "${ECHO_T}$ac_header_preproc" >&6
26076
26077 # So?  What about this header?
26078 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26079   yes:no: )
26080     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26081 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26082     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26083 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26084     ac_header_preproc=yes
26085     ;;
26086   no:yes:* )
26087     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26088 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26089     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26090 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26091     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26092 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26093     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26094 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26095     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26096 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26097     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26098 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26099     (
26100       cat <<\_ASBOX
26101 ## --------------------------------------------- ##
26102 ## Report this to <http://www.openldap.org/its/> ##
26103 ## --------------------------------------------- ##
26104 _ASBOX
26105     ) |
26106       sed "s/^/$as_me: WARNING:     /" >&2
26107     ;;
26108 esac
26109 echo "$as_me:$LINENO: checking for $ac_header" >&5
26110 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26111 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26112   echo $ECHO_N "(cached) $ECHO_C" >&6
26113 else
26114   eval "$as_ac_Header=\$ac_header_preproc"
26115 fi
26116 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26117 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26118
26119 fi
26120 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26121   cat >>confdefs.h <<_ACEOF
26122 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26123 _ACEOF
26124
26125 fi
26126
26127 done
26128
26129         if test $ac_cv_header_lwp_lwp_h = yes ; then
26130                 echo "$as_me:$LINENO: checking for lwp_create in -llwp" >&5
26131 echo $ECHO_N "checking for lwp_create in -llwp... $ECHO_C" >&6
26132 if test "${ac_cv_lib_lwp_lwp_create+set}" = set; then
26133   echo $ECHO_N "(cached) $ECHO_C" >&6
26134 else
26135   ac_check_lib_save_LIBS=$LIBS
26136 LIBS="-llwp  $LIBS"
26137 cat >conftest.$ac_ext <<_ACEOF
26138 /* confdefs.h.  */
26139 _ACEOF
26140 cat confdefs.h >>conftest.$ac_ext
26141 cat >>conftest.$ac_ext <<_ACEOF
26142 /* end confdefs.h.  */
26143
26144 /* Override any gcc2 internal prototype to avoid an error.  */
26145 #ifdef __cplusplus
26146 extern "C"
26147 #endif
26148 /* We use char because int might match the return type of a gcc2
26149    builtin and then its argument prototype would still apply.  */
26150 char lwp_create ();
26151 int
26152 main ()
26153 {
26154 lwp_create ();
26155   ;
26156   return 0;
26157 }
26158 _ACEOF
26159 rm -f conftest.$ac_objext conftest$ac_exeext
26160 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26161   (eval $ac_link) 2>conftest.er1
26162   ac_status=$?
26163   grep -v '^ *+' conftest.er1 >conftest.err
26164   rm -f conftest.er1
26165   cat conftest.err >&5
26166   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26167   (exit $ac_status); } &&
26168          { ac_try='test -z "$ac_c_werror_flag"
26169                          || test ! -s conftest.err'
26170   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26171   (eval $ac_try) 2>&5
26172   ac_status=$?
26173   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26174   (exit $ac_status); }; } &&
26175          { ac_try='test -s conftest$ac_exeext'
26176   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26177   (eval $ac_try) 2>&5
26178   ac_status=$?
26179   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26180   (exit $ac_status); }; }; then
26181   ac_cv_lib_lwp_lwp_create=yes
26182 else
26183   echo "$as_me: failed program was:" >&5
26184 sed 's/^/| /' conftest.$ac_ext >&5
26185
26186 ac_cv_lib_lwp_lwp_create=no
26187 fi
26188 rm -f conftest.err conftest.$ac_objext \
26189       conftest$ac_exeext conftest.$ac_ext
26190 LIBS=$ac_check_lib_save_LIBS
26191 fi
26192 echo "$as_me:$LINENO: result: $ac_cv_lib_lwp_lwp_create" >&5
26193 echo "${ECHO_T}$ac_cv_lib_lwp_lwp_create" >&6
26194 if test $ac_cv_lib_lwp_lwp_create = yes; then
26195   have_lwp=yes
26196 else
26197   have_lwp=no
26198 fi
26199
26200
26201                 if test $have_lwp = yes ; then
26202
26203 cat >>confdefs.h <<\_ACEOF
26204 #define HAVE_LWP 1
26205 _ACEOF
26206
26207                         LTHREAD_LIBS="$LTHREAD_LIBS -llwp"
26208                         ol_link_threads=lwp
26209
26210                         if test $ol_with_yielding_select = auto ; then
26211                                 ol_with_yielding_select=no
26212                         fi
26213                 fi
26214         fi
26215         ;;
26216 esac
26217
26218 if test $ol_with_yielding_select = yes ; then
26219
26220 cat >>confdefs.h <<\_ACEOF
26221 #define HAVE_YIELDING_SELECT 1
26222 _ACEOF
26223
26224 fi
26225
26226 if test $ol_with_threads = manual ; then
26227                 ol_link_threads=yes
26228
26229         { echo "$as_me:$LINENO: WARNING: thread defines and link options must be set manually" >&5
26230 echo "$as_me: WARNING: thread defines and link options must be set manually" >&2;}
26231
26232
26233
26234 for ac_header in pthread.h sched.h
26235 do
26236 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26237 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26238   echo "$as_me:$LINENO: checking for $ac_header" >&5
26239 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26240 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26241   echo $ECHO_N "(cached) $ECHO_C" >&6
26242 fi
26243 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26244 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26245 else
26246   # Is the header compilable?
26247 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26248 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26249 cat >conftest.$ac_ext <<_ACEOF
26250 /* confdefs.h.  */
26251 _ACEOF
26252 cat confdefs.h >>conftest.$ac_ext
26253 cat >>conftest.$ac_ext <<_ACEOF
26254 /* end confdefs.h.  */
26255 $ac_includes_default
26256 #include <$ac_header>
26257 _ACEOF
26258 rm -f conftest.$ac_objext
26259 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26260   (eval $ac_compile) 2>conftest.er1
26261   ac_status=$?
26262   grep -v '^ *+' conftest.er1 >conftest.err
26263   rm -f conftest.er1
26264   cat conftest.err >&5
26265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26266   (exit $ac_status); } &&
26267          { ac_try='test -z "$ac_c_werror_flag"
26268                          || test ! -s conftest.err'
26269   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26270   (eval $ac_try) 2>&5
26271   ac_status=$?
26272   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26273   (exit $ac_status); }; } &&
26274          { ac_try='test -s conftest.$ac_objext'
26275   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26276   (eval $ac_try) 2>&5
26277   ac_status=$?
26278   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26279   (exit $ac_status); }; }; then
26280   ac_header_compiler=yes
26281 else
26282   echo "$as_me: failed program was:" >&5
26283 sed 's/^/| /' conftest.$ac_ext >&5
26284
26285 ac_header_compiler=no
26286 fi
26287 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26288 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26289 echo "${ECHO_T}$ac_header_compiler" >&6
26290
26291 # Is the header present?
26292 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26293 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26294 cat >conftest.$ac_ext <<_ACEOF
26295 /* confdefs.h.  */
26296 _ACEOF
26297 cat confdefs.h >>conftest.$ac_ext
26298 cat >>conftest.$ac_ext <<_ACEOF
26299 /* end confdefs.h.  */
26300 #include <$ac_header>
26301 _ACEOF
26302 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26303   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26304   ac_status=$?
26305   grep -v '^ *+' conftest.er1 >conftest.err
26306   rm -f conftest.er1
26307   cat conftest.err >&5
26308   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26309   (exit $ac_status); } >/dev/null; then
26310   if test -s conftest.err; then
26311     ac_cpp_err=$ac_c_preproc_warn_flag
26312     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26313   else
26314     ac_cpp_err=
26315   fi
26316 else
26317   ac_cpp_err=yes
26318 fi
26319 if test -z "$ac_cpp_err"; then
26320   ac_header_preproc=yes
26321 else
26322   echo "$as_me: failed program was:" >&5
26323 sed 's/^/| /' conftest.$ac_ext >&5
26324
26325   ac_header_preproc=no
26326 fi
26327 rm -f conftest.err conftest.$ac_ext
26328 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26329 echo "${ECHO_T}$ac_header_preproc" >&6
26330
26331 # So?  What about this header?
26332 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26333   yes:no: )
26334     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26335 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26336     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26337 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26338     ac_header_preproc=yes
26339     ;;
26340   no:yes:* )
26341     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26342 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26343     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26344 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26345     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26346 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26347     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26348 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26349     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26350 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26351     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26352 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26353     (
26354       cat <<\_ASBOX
26355 ## --------------------------------------------- ##
26356 ## Report this to <http://www.openldap.org/its/> ##
26357 ## --------------------------------------------- ##
26358 _ASBOX
26359     ) |
26360       sed "s/^/$as_me: WARNING:     /" >&2
26361     ;;
26362 esac
26363 echo "$as_me:$LINENO: checking for $ac_header" >&5
26364 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26365 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26366   echo $ECHO_N "(cached) $ECHO_C" >&6
26367 else
26368   eval "$as_ac_Header=\$ac_header_preproc"
26369 fi
26370 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26371 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26372
26373 fi
26374 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26375   cat >>confdefs.h <<_ACEOF
26376 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26377 _ACEOF
26378
26379 fi
26380
26381 done
26382
26383
26384
26385 for ac_func in sched_yield pthread_yield
26386 do
26387 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
26388 echo "$as_me:$LINENO: checking for $ac_func" >&5
26389 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
26390 if eval "test \"\${$as_ac_var+set}\" = set"; then
26391   echo $ECHO_N "(cached) $ECHO_C" >&6
26392 else
26393   cat >conftest.$ac_ext <<_ACEOF
26394 /* confdefs.h.  */
26395 _ACEOF
26396 cat confdefs.h >>conftest.$ac_ext
26397 cat >>conftest.$ac_ext <<_ACEOF
26398 /* end confdefs.h.  */
26399 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
26400    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
26401 #define $ac_func innocuous_$ac_func
26402
26403 /* System header to define __stub macros and hopefully few prototypes,
26404     which can conflict with char $ac_func (); below.
26405     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
26406     <limits.h> exists even on freestanding compilers.  */
26407
26408 #ifdef __STDC__
26409 # include <limits.h>
26410 #else
26411 # include <assert.h>
26412 #endif
26413
26414 #undef $ac_func
26415
26416 /* Override any gcc2 internal prototype to avoid an error.  */
26417 #ifdef __cplusplus
26418 extern "C"
26419 {
26420 #endif
26421 /* We use char because int might match the return type of a gcc2
26422    builtin and then its argument prototype would still apply.  */
26423 char $ac_func ();
26424 /* The GNU C library defines this for functions which it implements
26425     to always fail with ENOSYS.  Some functions are actually named
26426     something starting with __ and the normal name is an alias.  */
26427 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
26428 choke me
26429 #else
26430 char (*f) () = $ac_func;
26431 #endif
26432 #ifdef __cplusplus
26433 }
26434 #endif
26435
26436 int
26437 main ()
26438 {
26439 return f != $ac_func;
26440   ;
26441   return 0;
26442 }
26443 _ACEOF
26444 rm -f conftest.$ac_objext conftest$ac_exeext
26445 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26446   (eval $ac_link) 2>conftest.er1
26447   ac_status=$?
26448   grep -v '^ *+' conftest.er1 >conftest.err
26449   rm -f conftest.er1
26450   cat conftest.err >&5
26451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26452   (exit $ac_status); } &&
26453          { ac_try='test -z "$ac_c_werror_flag"
26454                          || test ! -s conftest.err'
26455   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26456   (eval $ac_try) 2>&5
26457   ac_status=$?
26458   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26459   (exit $ac_status); }; } &&
26460          { ac_try='test -s conftest$ac_exeext'
26461   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26462   (eval $ac_try) 2>&5
26463   ac_status=$?
26464   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26465   (exit $ac_status); }; }; then
26466   eval "$as_ac_var=yes"
26467 else
26468   echo "$as_me: failed program was:" >&5
26469 sed 's/^/| /' conftest.$ac_ext >&5
26470
26471 eval "$as_ac_var=no"
26472 fi
26473 rm -f conftest.err conftest.$ac_objext \
26474       conftest$ac_exeext conftest.$ac_ext
26475 fi
26476 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
26477 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
26478 if test `eval echo '${'$as_ac_var'}'` = yes; then
26479   cat >>confdefs.h <<_ACEOF
26480 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
26481 _ACEOF
26482
26483 fi
26484 done
26485
26486
26487         echo "$as_me:$LINENO: checking for LinuxThreads pthread.h" >&5
26488 echo $ECHO_N "checking for LinuxThreads pthread.h... $ECHO_C" >&6
26489 if test "${ol_cv_header_linux_threads+set}" = set; then
26490   echo $ECHO_N "(cached) $ECHO_C" >&6
26491 else
26492   cat >conftest.$ac_ext <<_ACEOF
26493 /* confdefs.h.  */
26494 _ACEOF
26495 cat confdefs.h >>conftest.$ac_ext
26496 cat >>conftest.$ac_ext <<_ACEOF
26497 /* end confdefs.h.  */
26498 #include <pthread.h>
26499 _ACEOF
26500 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
26501   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then
26502   ol_cv_header_linux_threads=yes
26503 else
26504   ol_cv_header_linux_threads=no
26505 fi
26506 rm -f conftest*
26507
26508
26509 fi
26510 echo "$as_me:$LINENO: result: $ol_cv_header_linux_threads" >&5
26511 echo "${ECHO_T}$ol_cv_header_linux_threads" >&6
26512         if test $ol_cv_header_linux_threads = yes; then
26513
26514 cat >>confdefs.h <<\_ACEOF
26515 #define HAVE_LINUX_THREADS 1
26516 _ACEOF
26517
26518         fi
26519
26520
26521
26522 for ac_header in mach/cthreads.h
26523 do
26524 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26525 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26526   echo "$as_me:$LINENO: checking for $ac_header" >&5
26527 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26528 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26529   echo $ECHO_N "(cached) $ECHO_C" >&6
26530 fi
26531 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26532 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26533 else
26534   # Is the header compilable?
26535 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26536 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26537 cat >conftest.$ac_ext <<_ACEOF
26538 /* confdefs.h.  */
26539 _ACEOF
26540 cat confdefs.h >>conftest.$ac_ext
26541 cat >>conftest.$ac_ext <<_ACEOF
26542 /* end confdefs.h.  */
26543 $ac_includes_default
26544 #include <$ac_header>
26545 _ACEOF
26546 rm -f conftest.$ac_objext
26547 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26548   (eval $ac_compile) 2>conftest.er1
26549   ac_status=$?
26550   grep -v '^ *+' conftest.er1 >conftest.err
26551   rm -f conftest.er1
26552   cat conftest.err >&5
26553   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26554   (exit $ac_status); } &&
26555          { ac_try='test -z "$ac_c_werror_flag"
26556                          || test ! -s conftest.err'
26557   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26558   (eval $ac_try) 2>&5
26559   ac_status=$?
26560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26561   (exit $ac_status); }; } &&
26562          { ac_try='test -s conftest.$ac_objext'
26563   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26564   (eval $ac_try) 2>&5
26565   ac_status=$?
26566   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26567   (exit $ac_status); }; }; then
26568   ac_header_compiler=yes
26569 else
26570   echo "$as_me: failed program was:" >&5
26571 sed 's/^/| /' conftest.$ac_ext >&5
26572
26573 ac_header_compiler=no
26574 fi
26575 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26576 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26577 echo "${ECHO_T}$ac_header_compiler" >&6
26578
26579 # Is the header present?
26580 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26581 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26582 cat >conftest.$ac_ext <<_ACEOF
26583 /* confdefs.h.  */
26584 _ACEOF
26585 cat confdefs.h >>conftest.$ac_ext
26586 cat >>conftest.$ac_ext <<_ACEOF
26587 /* end confdefs.h.  */
26588 #include <$ac_header>
26589 _ACEOF
26590 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26591   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26592   ac_status=$?
26593   grep -v '^ *+' conftest.er1 >conftest.err
26594   rm -f conftest.er1
26595   cat conftest.err >&5
26596   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26597   (exit $ac_status); } >/dev/null; then
26598   if test -s conftest.err; then
26599     ac_cpp_err=$ac_c_preproc_warn_flag
26600     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26601   else
26602     ac_cpp_err=
26603   fi
26604 else
26605   ac_cpp_err=yes
26606 fi
26607 if test -z "$ac_cpp_err"; then
26608   ac_header_preproc=yes
26609 else
26610   echo "$as_me: failed program was:" >&5
26611 sed 's/^/| /' conftest.$ac_ext >&5
26612
26613   ac_header_preproc=no
26614 fi
26615 rm -f conftest.err conftest.$ac_ext
26616 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26617 echo "${ECHO_T}$ac_header_preproc" >&6
26618
26619 # So?  What about this header?
26620 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26621   yes:no: )
26622     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26623 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26624     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26625 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26626     ac_header_preproc=yes
26627     ;;
26628   no:yes:* )
26629     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26630 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26631     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26632 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26633     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26634 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26635     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26636 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26637     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26638 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26639     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26640 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26641     (
26642       cat <<\_ASBOX
26643 ## --------------------------------------------- ##
26644 ## Report this to <http://www.openldap.org/its/> ##
26645 ## --------------------------------------------- ##
26646 _ASBOX
26647     ) |
26648       sed "s/^/$as_me: WARNING:     /" >&2
26649     ;;
26650 esac
26651 echo "$as_me:$LINENO: checking for $ac_header" >&5
26652 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26653 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26654   echo $ECHO_N "(cached) $ECHO_C" >&6
26655 else
26656   eval "$as_ac_Header=\$ac_header_preproc"
26657 fi
26658 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26659 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26660
26661 fi
26662 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26663   cat >>confdefs.h <<_ACEOF
26664 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26665 _ACEOF
26666
26667 fi
26668
26669 done
26670
26671
26672 for ac_header in lwp/lwp.h
26673 do
26674 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26675 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26676   echo "$as_me:$LINENO: checking for $ac_header" >&5
26677 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26678 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26679   echo $ECHO_N "(cached) $ECHO_C" >&6
26680 fi
26681 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26682 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26683 else
26684   # Is the header compilable?
26685 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26686 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26687 cat >conftest.$ac_ext <<_ACEOF
26688 /* confdefs.h.  */
26689 _ACEOF
26690 cat confdefs.h >>conftest.$ac_ext
26691 cat >>conftest.$ac_ext <<_ACEOF
26692 /* end confdefs.h.  */
26693 $ac_includes_default
26694 #include <$ac_header>
26695 _ACEOF
26696 rm -f conftest.$ac_objext
26697 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26698   (eval $ac_compile) 2>conftest.er1
26699   ac_status=$?
26700   grep -v '^ *+' conftest.er1 >conftest.err
26701   rm -f conftest.er1
26702   cat conftest.err >&5
26703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26704   (exit $ac_status); } &&
26705          { ac_try='test -z "$ac_c_werror_flag"
26706                          || test ! -s conftest.err'
26707   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26708   (eval $ac_try) 2>&5
26709   ac_status=$?
26710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26711   (exit $ac_status); }; } &&
26712          { ac_try='test -s conftest.$ac_objext'
26713   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26714   (eval $ac_try) 2>&5
26715   ac_status=$?
26716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26717   (exit $ac_status); }; }; then
26718   ac_header_compiler=yes
26719 else
26720   echo "$as_me: failed program was:" >&5
26721 sed 's/^/| /' conftest.$ac_ext >&5
26722
26723 ac_header_compiler=no
26724 fi
26725 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26726 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26727 echo "${ECHO_T}$ac_header_compiler" >&6
26728
26729 # Is the header present?
26730 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26731 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26732 cat >conftest.$ac_ext <<_ACEOF
26733 /* confdefs.h.  */
26734 _ACEOF
26735 cat confdefs.h >>conftest.$ac_ext
26736 cat >>conftest.$ac_ext <<_ACEOF
26737 /* end confdefs.h.  */
26738 #include <$ac_header>
26739 _ACEOF
26740 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26741   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26742   ac_status=$?
26743   grep -v '^ *+' conftest.er1 >conftest.err
26744   rm -f conftest.er1
26745   cat conftest.err >&5
26746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26747   (exit $ac_status); } >/dev/null; then
26748   if test -s conftest.err; then
26749     ac_cpp_err=$ac_c_preproc_warn_flag
26750     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26751   else
26752     ac_cpp_err=
26753   fi
26754 else
26755   ac_cpp_err=yes
26756 fi
26757 if test -z "$ac_cpp_err"; then
26758   ac_header_preproc=yes
26759 else
26760   echo "$as_me: failed program was:" >&5
26761 sed 's/^/| /' conftest.$ac_ext >&5
26762
26763   ac_header_preproc=no
26764 fi
26765 rm -f conftest.err conftest.$ac_ext
26766 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26767 echo "${ECHO_T}$ac_header_preproc" >&6
26768
26769 # So?  What about this header?
26770 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26771   yes:no: )
26772     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26773 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26774     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26775 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26776     ac_header_preproc=yes
26777     ;;
26778   no:yes:* )
26779     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26780 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26781     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26782 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26783     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26784 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26785     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26786 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26787     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26788 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26789     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26790 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26791     (
26792       cat <<\_ASBOX
26793 ## --------------------------------------------- ##
26794 ## Report this to <http://www.openldap.org/its/> ##
26795 ## --------------------------------------------- ##
26796 _ASBOX
26797     ) |
26798       sed "s/^/$as_me: WARNING:     /" >&2
26799     ;;
26800 esac
26801 echo "$as_me:$LINENO: checking for $ac_header" >&5
26802 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26803 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26804   echo $ECHO_N "(cached) $ECHO_C" >&6
26805 else
26806   eval "$as_ac_Header=\$ac_header_preproc"
26807 fi
26808 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26809 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26810
26811 fi
26812 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26813   cat >>confdefs.h <<_ACEOF
26814 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26815 _ACEOF
26816
26817 fi
26818
26819 done
26820
26821
26822
26823 for ac_header in thread.h synch.h
26824 do
26825 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26826 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26827   echo "$as_me:$LINENO: checking for $ac_header" >&5
26828 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26829 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26830   echo $ECHO_N "(cached) $ECHO_C" >&6
26831 fi
26832 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26833 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26834 else
26835   # Is the header compilable?
26836 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26837 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26838 cat >conftest.$ac_ext <<_ACEOF
26839 /* confdefs.h.  */
26840 _ACEOF
26841 cat confdefs.h >>conftest.$ac_ext
26842 cat >>conftest.$ac_ext <<_ACEOF
26843 /* end confdefs.h.  */
26844 $ac_includes_default
26845 #include <$ac_header>
26846 _ACEOF
26847 rm -f conftest.$ac_objext
26848 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26849   (eval $ac_compile) 2>conftest.er1
26850   ac_status=$?
26851   grep -v '^ *+' conftest.er1 >conftest.err
26852   rm -f conftest.er1
26853   cat conftest.err >&5
26854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26855   (exit $ac_status); } &&
26856          { ac_try='test -z "$ac_c_werror_flag"
26857                          || test ! -s conftest.err'
26858   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26859   (eval $ac_try) 2>&5
26860   ac_status=$?
26861   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26862   (exit $ac_status); }; } &&
26863          { ac_try='test -s conftest.$ac_objext'
26864   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26865   (eval $ac_try) 2>&5
26866   ac_status=$?
26867   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26868   (exit $ac_status); }; }; then
26869   ac_header_compiler=yes
26870 else
26871   echo "$as_me: failed program was:" >&5
26872 sed 's/^/| /' conftest.$ac_ext >&5
26873
26874 ac_header_compiler=no
26875 fi
26876 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26877 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26878 echo "${ECHO_T}$ac_header_compiler" >&6
26879
26880 # Is the header present?
26881 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26882 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26883 cat >conftest.$ac_ext <<_ACEOF
26884 /* confdefs.h.  */
26885 _ACEOF
26886 cat confdefs.h >>conftest.$ac_ext
26887 cat >>conftest.$ac_ext <<_ACEOF
26888 /* end confdefs.h.  */
26889 #include <$ac_header>
26890 _ACEOF
26891 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26892   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26893   ac_status=$?
26894   grep -v '^ *+' conftest.er1 >conftest.err
26895   rm -f conftest.er1
26896   cat conftest.err >&5
26897   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26898   (exit $ac_status); } >/dev/null; then
26899   if test -s conftest.err; then
26900     ac_cpp_err=$ac_c_preproc_warn_flag
26901     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26902   else
26903     ac_cpp_err=
26904   fi
26905 else
26906   ac_cpp_err=yes
26907 fi
26908 if test -z "$ac_cpp_err"; then
26909   ac_header_preproc=yes
26910 else
26911   echo "$as_me: failed program was:" >&5
26912 sed 's/^/| /' conftest.$ac_ext >&5
26913
26914   ac_header_preproc=no
26915 fi
26916 rm -f conftest.err conftest.$ac_ext
26917 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26918 echo "${ECHO_T}$ac_header_preproc" >&6
26919
26920 # So?  What about this header?
26921 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26922   yes:no: )
26923     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26924 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26925     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26926 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26927     ac_header_preproc=yes
26928     ;;
26929   no:yes:* )
26930     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26931 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26932     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26933 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26934     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26935 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26936     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26937 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26938     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26939 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26940     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26941 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26942     (
26943       cat <<\_ASBOX
26944 ## --------------------------------------------- ##
26945 ## Report this to <http://www.openldap.org/its/> ##
26946 ## --------------------------------------------- ##
26947 _ASBOX
26948     ) |
26949       sed "s/^/$as_me: WARNING:     /" >&2
26950     ;;
26951 esac
26952 echo "$as_me:$LINENO: checking for $ac_header" >&5
26953 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26954 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26955   echo $ECHO_N "(cached) $ECHO_C" >&6
26956 else
26957   eval "$as_ac_Header=\$ac_header_preproc"
26958 fi
26959 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26960 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26961
26962 fi
26963 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26964   cat >>confdefs.h <<_ACEOF
26965 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26966 _ACEOF
26967
26968 fi
26969
26970 done
26971
26972 fi
26973
26974 if test $ol_link_threads != no && test $ol_link_threads != nt ; then
26975                         cat >>confdefs.h <<\_ACEOF
26976 #define REENTRANT 1
26977 _ACEOF
26978
26979         cat >>confdefs.h <<\_ACEOF
26980 #define _REENTRANT 1
26981 _ACEOF
26982
26983         cat >>confdefs.h <<\_ACEOF
26984 #define THREAD_SAFE 1
26985 _ACEOF
26986
26987         cat >>confdefs.h <<\_ACEOF
26988 #define _THREAD_SAFE 1
26989 _ACEOF
26990
26991         cat >>confdefs.h <<\_ACEOF
26992 #define THREADSAFE 1
26993 _ACEOF
26994
26995         cat >>confdefs.h <<\_ACEOF
26996 #define _THREADSAFE 1
26997 _ACEOF
26998
26999         cat >>confdefs.h <<\_ACEOF
27000 #define _SGI_MP_SOURCE 1
27001 _ACEOF
27002
27003
27004                         echo "$as_me:$LINENO: checking for thread specific errno" >&5
27005 echo $ECHO_N "checking for thread specific errno... $ECHO_C" >&6
27006 if test "${ol_cv_errno_thread_specific+set}" = set; then
27007   echo $ECHO_N "(cached) $ECHO_C" >&6
27008 else
27009
27010                 cat >conftest.$ac_ext <<_ACEOF
27011 /* confdefs.h.  */
27012 _ACEOF
27013 cat confdefs.h >>conftest.$ac_ext
27014 cat >>conftest.$ac_ext <<_ACEOF
27015 /* end confdefs.h.  */
27016 #include <errno.h>
27017 int
27018 main ()
27019 {
27020 errno = 0;
27021   ;
27022   return 0;
27023 }
27024 _ACEOF
27025 rm -f conftest.$ac_objext conftest$ac_exeext
27026 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27027   (eval $ac_link) 2>conftest.er1
27028   ac_status=$?
27029   grep -v '^ *+' conftest.er1 >conftest.err
27030   rm -f conftest.er1
27031   cat conftest.err >&5
27032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27033   (exit $ac_status); } &&
27034          { ac_try='test -z "$ac_c_werror_flag"
27035                          || test ! -s conftest.err'
27036   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27037   (eval $ac_try) 2>&5
27038   ac_status=$?
27039   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27040   (exit $ac_status); }; } &&
27041          { ac_try='test -s conftest$ac_exeext'
27042   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27043   (eval $ac_try) 2>&5
27044   ac_status=$?
27045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27046   (exit $ac_status); }; }; then
27047   ol_cv_errno_thread_specific=yes
27048 else
27049   echo "$as_me: failed program was:" >&5
27050 sed 's/^/| /' conftest.$ac_ext >&5
27051
27052 ol_cv_errno_thread_specific=no
27053 fi
27054 rm -f conftest.err conftest.$ac_objext \
27055       conftest$ac_exeext conftest.$ac_ext
27056
27057 fi
27058 echo "$as_me:$LINENO: result: $ol_cv_errno_thread_specific" >&5
27059 echo "${ECHO_T}$ol_cv_errno_thread_specific" >&6
27060
27061                         echo "$as_me:$LINENO: checking for thread specific h_errno" >&5
27062 echo $ECHO_N "checking for thread specific h_errno... $ECHO_C" >&6
27063 if test "${ol_cv_h_errno_thread_specific+set}" = set; then
27064   echo $ECHO_N "(cached) $ECHO_C" >&6
27065 else
27066
27067                 cat >conftest.$ac_ext <<_ACEOF
27068 /* confdefs.h.  */
27069 _ACEOF
27070 cat confdefs.h >>conftest.$ac_ext
27071 cat >>conftest.$ac_ext <<_ACEOF
27072 /* end confdefs.h.  */
27073 #include <netdb.h>
27074 int
27075 main ()
27076 {
27077 h_errno = 0;
27078   ;
27079   return 0;
27080 }
27081 _ACEOF
27082 rm -f conftest.$ac_objext conftest$ac_exeext
27083 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27084   (eval $ac_link) 2>conftest.er1
27085   ac_status=$?
27086   grep -v '^ *+' conftest.er1 >conftest.err
27087   rm -f conftest.er1
27088   cat conftest.err >&5
27089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27090   (exit $ac_status); } &&
27091          { ac_try='test -z "$ac_c_werror_flag"
27092                          || test ! -s conftest.err'
27093   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27094   (eval $ac_try) 2>&5
27095   ac_status=$?
27096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27097   (exit $ac_status); }; } &&
27098          { ac_try='test -s conftest$ac_exeext'
27099   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27100   (eval $ac_try) 2>&5
27101   ac_status=$?
27102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27103   (exit $ac_status); }; }; then
27104   ol_cv_h_errno_thread_specific=yes
27105 else
27106   echo "$as_me: failed program was:" >&5
27107 sed 's/^/| /' conftest.$ac_ext >&5
27108
27109 ol_cv_h_errno_thread_specific=no
27110 fi
27111 rm -f conftest.err conftest.$ac_objext \
27112       conftest$ac_exeext conftest.$ac_ext
27113
27114 fi
27115 echo "$as_me:$LINENO: result: $ol_cv_h_errno_thread_specific" >&5
27116 echo "${ECHO_T}$ol_cv_h_errno_thread_specific" >&6
27117
27118         if test $ol_cv_errno_thread_specific != yes ||
27119            test $ol_cv_h_errno_thread_specific != yes ; then
27120                 LIBS="$LTHREAD_LIBS $LIBS"
27121                 LTHREAD_LIBS=""
27122         fi
27123
27124 fi
27125
27126 if test $ol_link_threads = no ; then
27127         if test $ol_with_threads = yes ; then
27128                 { { echo "$as_me:$LINENO: error: no suitable thread support" >&5
27129 echo "$as_me: error: no suitable thread support" >&2;}
27130    { (exit 1); exit 1; }; }
27131         fi
27132
27133         if test $ol_with_threads = auto ; then
27134                 { echo "$as_me:$LINENO: WARNING: no suitable thread support, disabling threads" >&5
27135 echo "$as_me: WARNING: no suitable thread support, disabling threads" >&2;}
27136                 ol_with_threads=no
27137         fi
27138
27139
27140 cat >>confdefs.h <<\_ACEOF
27141 #define NO_THREADS 1
27142 _ACEOF
27143
27144         LTHREAD_LIBS=""
27145         BUILD_THREAD=no
27146 else
27147         BUILD_THREAD=yes
27148 fi
27149
27150 if test $ol_link_threads != no ; then
27151
27152 cat >>confdefs.h <<\_ACEOF
27153 #define LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE 1
27154 _ACEOF
27155
27156 fi
27157
27158
27159
27160
27161 for ac_func in \
27162         ctime_r                 \
27163         gethostbyname_r gethostbyaddr_r \
27164
27165 do
27166 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
27167 echo "$as_me:$LINENO: checking for $ac_func" >&5
27168 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
27169 if eval "test \"\${$as_ac_var+set}\" = set"; then
27170   echo $ECHO_N "(cached) $ECHO_C" >&6
27171 else
27172   cat >conftest.$ac_ext <<_ACEOF
27173 /* confdefs.h.  */
27174 _ACEOF
27175 cat confdefs.h >>conftest.$ac_ext
27176 cat >>conftest.$ac_ext <<_ACEOF
27177 /* end confdefs.h.  */
27178 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
27179    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
27180 #define $ac_func innocuous_$ac_func
27181
27182 /* System header to define __stub macros and hopefully few prototypes,
27183     which can conflict with char $ac_func (); below.
27184     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
27185     <limits.h> exists even on freestanding compilers.  */
27186
27187 #ifdef __STDC__
27188 # include <limits.h>
27189 #else
27190 # include <assert.h>
27191 #endif
27192
27193 #undef $ac_func
27194
27195 /* Override any gcc2 internal prototype to avoid an error.  */
27196 #ifdef __cplusplus
27197 extern "C"
27198 {
27199 #endif
27200 /* We use char because int might match the return type of a gcc2
27201    builtin and then its argument prototype would still apply.  */
27202 char $ac_func ();
27203 /* The GNU C library defines this for functions which it implements
27204     to always fail with ENOSYS.  Some functions are actually named
27205     something starting with __ and the normal name is an alias.  */
27206 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
27207 choke me
27208 #else
27209 char (*f) () = $ac_func;
27210 #endif
27211 #ifdef __cplusplus
27212 }
27213 #endif
27214
27215 int
27216 main ()
27217 {
27218 return f != $ac_func;
27219   ;
27220   return 0;
27221 }
27222 _ACEOF
27223 rm -f conftest.$ac_objext conftest$ac_exeext
27224 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27225   (eval $ac_link) 2>conftest.er1
27226   ac_status=$?
27227   grep -v '^ *+' conftest.er1 >conftest.err
27228   rm -f conftest.er1
27229   cat conftest.err >&5
27230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27231   (exit $ac_status); } &&
27232          { ac_try='test -z "$ac_c_werror_flag"
27233                          || test ! -s conftest.err'
27234   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27235   (eval $ac_try) 2>&5
27236   ac_status=$?
27237   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27238   (exit $ac_status); }; } &&
27239          { ac_try='test -s conftest$ac_exeext'
27240   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27241   (eval $ac_try) 2>&5
27242   ac_status=$?
27243   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27244   (exit $ac_status); }; }; then
27245   eval "$as_ac_var=yes"
27246 else
27247   echo "$as_me: failed program was:" >&5
27248 sed 's/^/| /' conftest.$ac_ext >&5
27249
27250 eval "$as_ac_var=no"
27251 fi
27252 rm -f conftest.err conftest.$ac_objext \
27253       conftest$ac_exeext conftest.$ac_ext
27254 fi
27255 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
27256 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
27257 if test `eval echo '${'$as_ac_var'}'` = yes; then
27258   cat >>confdefs.h <<_ACEOF
27259 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
27260 _ACEOF
27261
27262 fi
27263 done
27264
27265
27266 if test "$ac_cv_func_ctime_r" = no ; then
27267         ol_cv_func_ctime_r_nargs=0
27268 else
27269         echo "$as_me:$LINENO: checking number of arguments of ctime_r" >&5
27270 echo $ECHO_N "checking number of arguments of ctime_r... $ECHO_C" >&6
27271 if test "${ol_cv_func_ctime_r_nargs+set}" = set; then
27272   echo $ECHO_N "(cached) $ECHO_C" >&6
27273 else
27274   cat >conftest.$ac_ext <<_ACEOF
27275 /* confdefs.h.  */
27276 _ACEOF
27277 cat confdefs.h >>conftest.$ac_ext
27278 cat >>conftest.$ac_ext <<_ACEOF
27279 /* end confdefs.h.  */
27280 #include <time.h>
27281 int
27282 main ()
27283 {
27284 time_t ti; char *buffer; ctime_r(&ti,buffer,32);
27285   ;
27286   return 0;
27287 }
27288 _ACEOF
27289 rm -f conftest.$ac_objext
27290 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27291   (eval $ac_compile) 2>conftest.er1
27292   ac_status=$?
27293   grep -v '^ *+' conftest.er1 >conftest.err
27294   rm -f conftest.er1
27295   cat conftest.err >&5
27296   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27297   (exit $ac_status); } &&
27298          { ac_try='test -z "$ac_c_werror_flag"
27299                          || test ! -s conftest.err'
27300   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27301   (eval $ac_try) 2>&5
27302   ac_status=$?
27303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27304   (exit $ac_status); }; } &&
27305          { ac_try='test -s conftest.$ac_objext'
27306   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27307   (eval $ac_try) 2>&5
27308   ac_status=$?
27309   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27310   (exit $ac_status); }; }; then
27311   ol_cv_func_ctime_r_nargs3=yes
27312 else
27313   echo "$as_me: failed program was:" >&5
27314 sed 's/^/| /' conftest.$ac_ext >&5
27315
27316 ol_cv_func_ctime_r_nargs3=no
27317 fi
27318 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27319
27320         cat >conftest.$ac_ext <<_ACEOF
27321 /* confdefs.h.  */
27322 _ACEOF
27323 cat confdefs.h >>conftest.$ac_ext
27324 cat >>conftest.$ac_ext <<_ACEOF
27325 /* end confdefs.h.  */
27326 #include <time.h>
27327 int
27328 main ()
27329 {
27330 time_t ti; char *buffer; ctime_r(&ti,buffer);
27331   ;
27332   return 0;
27333 }
27334 _ACEOF
27335 rm -f conftest.$ac_objext
27336 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27337   (eval $ac_compile) 2>conftest.er1
27338   ac_status=$?
27339   grep -v '^ *+' conftest.er1 >conftest.err
27340   rm -f conftest.er1
27341   cat conftest.err >&5
27342   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27343   (exit $ac_status); } &&
27344          { ac_try='test -z "$ac_c_werror_flag"
27345                          || test ! -s conftest.err'
27346   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27347   (eval $ac_try) 2>&5
27348   ac_status=$?
27349   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27350   (exit $ac_status); }; } &&
27351          { ac_try='test -s conftest.$ac_objext'
27352   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27353   (eval $ac_try) 2>&5
27354   ac_status=$?
27355   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27356   (exit $ac_status); }; }; then
27357   ol_cv_func_ctime_r_nargs2=yes
27358 else
27359   echo "$as_me: failed program was:" >&5
27360 sed 's/^/| /' conftest.$ac_ext >&5
27361
27362 ol_cv_func_ctime_r_nargs2=no
27363 fi
27364 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27365
27366         if test $ol_cv_func_ctime_r_nargs3 = yes &&
27367            test $ol_cv_func_ctime_r_nargs2 = no ; then
27368
27369                 ol_cv_func_ctime_r_nargs=3
27370
27371         elif test $ol_cv_func_ctime_r_nargs3 = no &&
27372              test $ol_cv_func_ctime_r_nargs2 = yes ; then
27373
27374                 ol_cv_func_ctime_r_nargs=2
27375
27376         else
27377                 ol_cv_func_ctime_r_nargs=0
27378         fi
27379
27380 fi
27381 echo "$as_me:$LINENO: result: $ol_cv_func_ctime_r_nargs" >&5
27382 echo "${ECHO_T}$ol_cv_func_ctime_r_nargs" >&6
27383
27384   if test $ol_cv_func_ctime_r_nargs -gt 1 ; then
27385
27386 cat >>confdefs.h <<_ACEOF
27387 #define CTIME_R_NARGS $ol_cv_func_ctime_r_nargs
27388 _ACEOF
27389
27390   fi
27391
27392 fi
27393
27394 if test "$ac_cv_func_gethostbyname_r" = yes ; then
27395         echo "$as_me:$LINENO: checking number of arguments of gethostbyname_r" >&5
27396 echo $ECHO_N "checking number of arguments of gethostbyname_r... $ECHO_C" >&6
27397 if test "${ol_cv_func_gethostbyname_r_nargs+set}" = set; then
27398   echo $ECHO_N "(cached) $ECHO_C" >&6
27399 else
27400   cat >conftest.$ac_ext <<_ACEOF
27401 /* confdefs.h.  */
27402 _ACEOF
27403 cat confdefs.h >>conftest.$ac_ext
27404 cat >>conftest.$ac_ext <<_ACEOF
27405 /* end confdefs.h.  */
27406 #include <sys/types.h>
27407 #include <sys/socket.h>
27408 #include <netinet/in.h>
27409 #include <netdb.h>
27410 #define BUFSIZE (sizeof(struct hostent)+10)
27411 int
27412 main ()
27413 {
27414 struct hostent hent; char buffer[BUFSIZE];
27415                 int bufsize=BUFSIZE;int h_errno;
27416                 (void)gethostbyname_r("segovia.cs.purdue.edu", &hent,
27417                         buffer, bufsize, &h_errno);
27418   ;
27419   return 0;
27420 }
27421 _ACEOF
27422 rm -f conftest.$ac_objext
27423 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27424   (eval $ac_compile) 2>conftest.er1
27425   ac_status=$?
27426   grep -v '^ *+' conftest.er1 >conftest.err
27427   rm -f conftest.er1
27428   cat conftest.err >&5
27429   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27430   (exit $ac_status); } &&
27431          { ac_try='test -z "$ac_c_werror_flag"
27432                          || test ! -s conftest.err'
27433   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27434   (eval $ac_try) 2>&5
27435   ac_status=$?
27436   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27437   (exit $ac_status); }; } &&
27438          { ac_try='test -s conftest.$ac_objext'
27439   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27440   (eval $ac_try) 2>&5
27441   ac_status=$?
27442   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27443   (exit $ac_status); }; }; then
27444   ol_cv_func_gethostbyname_r_nargs5=yes
27445 else
27446   echo "$as_me: failed program was:" >&5
27447 sed 's/^/| /' conftest.$ac_ext >&5
27448
27449 ol_cv_func_gethostbyname_r_nargs5=no
27450 fi
27451 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27452
27453         cat >conftest.$ac_ext <<_ACEOF
27454 /* confdefs.h.  */
27455 _ACEOF
27456 cat confdefs.h >>conftest.$ac_ext
27457 cat >>conftest.$ac_ext <<_ACEOF
27458 /* end confdefs.h.  */
27459 #include <sys/types.h>
27460 #include <sys/socket.h>
27461 #include <netinet/in.h>
27462 #include <netdb.h>
27463 #define BUFSIZE (sizeof(struct hostent)+10)
27464 int
27465 main ()
27466 {
27467 struct hostent hent;struct hostent *rhent;
27468                 char buffer[BUFSIZE];
27469                 int bufsize=BUFSIZE;int h_errno;
27470                 (void)gethostbyname_r("localhost", &hent, buffer, bufsize,
27471                         &rhent, &h_errno);
27472   ;
27473   return 0;
27474 }
27475 _ACEOF
27476 rm -f conftest.$ac_objext
27477 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27478   (eval $ac_compile) 2>conftest.er1
27479   ac_status=$?
27480   grep -v '^ *+' conftest.er1 >conftest.err
27481   rm -f conftest.er1
27482   cat conftest.err >&5
27483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27484   (exit $ac_status); } &&
27485          { ac_try='test -z "$ac_c_werror_flag"
27486                          || test ! -s conftest.err'
27487   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27488   (eval $ac_try) 2>&5
27489   ac_status=$?
27490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27491   (exit $ac_status); }; } &&
27492          { ac_try='test -s conftest.$ac_objext'
27493   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27494   (eval $ac_try) 2>&5
27495   ac_status=$?
27496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27497   (exit $ac_status); }; }; then
27498   ol_cv_func_gethostbyname_r_nargs6=yes
27499 else
27500   echo "$as_me: failed program was:" >&5
27501 sed 's/^/| /' conftest.$ac_ext >&5
27502
27503 ol_cv_func_gethostbyname_r_nargs6=no
27504 fi
27505 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27506
27507         if test $ol_cv_func_gethostbyname_r_nargs5 = yes &&
27508            test $ol_cv_func_gethostbyname_r_nargs6 = no ; then
27509
27510                 ol_cv_func_gethostbyname_r_nargs=5
27511
27512         elif test $ol_cv_func_gethostbyname_r_nargs5 = no &&
27513              test $ol_cv_func_gethostbyname_r_nargs6 = yes ; then
27514
27515                 ol_cv_func_gethostbyname_r_nargs=6
27516
27517         else
27518                 ol_cv_func_gethostbyname_r_nargs=0
27519         fi
27520
27521 fi
27522 echo "$as_me:$LINENO: result: $ol_cv_func_gethostbyname_r_nargs" >&5
27523 echo "${ECHO_T}$ol_cv_func_gethostbyname_r_nargs" >&6
27524   if test $ol_cv_func_gethostbyname_r_nargs -gt 1 ; then
27525
27526 cat >>confdefs.h <<_ACEOF
27527 #define GETHOSTBYNAME_R_NARGS $ol_cv_func_gethostbyname_r_nargs
27528 _ACEOF
27529
27530   fi
27531
27532 else
27533         ol_cv_func_gethostbyname_r_nargs=0
27534 fi
27535
27536 if test "$ac_cv_func_gethostbyaddr_r" = yes ; then
27537         echo "$as_me:$LINENO: checking number of arguments of gethostbyaddr_r" >&5
27538 echo $ECHO_N "checking number of arguments of gethostbyaddr_r... $ECHO_C" >&6
27539 if test "${ol_cv_func_gethostbyaddr_r_nargs+set}" = set; then
27540   echo $ECHO_N "(cached) $ECHO_C" >&6
27541 else
27542   cat >conftest.$ac_ext <<_ACEOF
27543 /* confdefs.h.  */
27544 _ACEOF
27545 cat confdefs.h >>conftest.$ac_ext
27546 cat >>conftest.$ac_ext <<_ACEOF
27547 /* end confdefs.h.  */
27548 #include <sys/types.h>
27549 #include <sys/socket.h>
27550 #include <netinet/in.h>
27551 #include <netdb.h>
27552 #define BUFSIZE (sizeof(struct hostent)+10)
27553 int
27554 main ()
27555 {
27556 struct hostent hent; char buffer[BUFSIZE];
27557             struct in_addr add;
27558             size_t alen=sizeof(struct in_addr);
27559             int bufsize=BUFSIZE;int h_errno;
27560                 (void)gethostbyaddr_r( (void *)&(add.s_addr),
27561                         alen, AF_INET, &hent, buffer, bufsize, &h_errno);
27562   ;
27563   return 0;
27564 }
27565 _ACEOF
27566 rm -f conftest.$ac_objext
27567 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27568   (eval $ac_compile) 2>conftest.er1
27569   ac_status=$?
27570   grep -v '^ *+' conftest.er1 >conftest.err
27571   rm -f conftest.er1
27572   cat conftest.err >&5
27573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27574   (exit $ac_status); } &&
27575          { ac_try='test -z "$ac_c_werror_flag"
27576                          || test ! -s conftest.err'
27577   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27578   (eval $ac_try) 2>&5
27579   ac_status=$?
27580   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27581   (exit $ac_status); }; } &&
27582          { ac_try='test -s conftest.$ac_objext'
27583   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27584   (eval $ac_try) 2>&5
27585   ac_status=$?
27586   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27587   (exit $ac_status); }; }; then
27588   ol_cv_func_gethostbyaddr_r_nargs7=yes
27589 else
27590   echo "$as_me: failed program was:" >&5
27591 sed 's/^/| /' conftest.$ac_ext >&5
27592
27593 ol_cv_func_gethostbyaddr_r_nargs7=no
27594 fi
27595 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27596
27597         cat >conftest.$ac_ext <<_ACEOF
27598 /* confdefs.h.  */
27599 _ACEOF
27600 cat confdefs.h >>conftest.$ac_ext
27601 cat >>conftest.$ac_ext <<_ACEOF
27602 /* end confdefs.h.  */
27603 #include <sys/types.h>
27604 #include <sys/socket.h>
27605 #include <netinet/in.h>
27606 #include <netdb.h>
27607 #define BUFSIZE (sizeof(struct hostent)+10)
27608 int
27609 main ()
27610 {
27611 struct hostent hent;
27612                 struct hostent *rhent; char buffer[BUFSIZE];
27613                 struct in_addr add;
27614                 size_t alen=sizeof(struct in_addr);
27615                 int bufsize=BUFSIZE;int h_errno;
27616                 (void)gethostbyaddr_r( (void *)&(add.s_addr),
27617                         alen, AF_INET, &hent, buffer, bufsize,
27618                         &rhent, &h_errno);
27619   ;
27620   return 0;
27621 }
27622 _ACEOF
27623 rm -f conftest.$ac_objext
27624 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27625   (eval $ac_compile) 2>conftest.er1
27626   ac_status=$?
27627   grep -v '^ *+' conftest.er1 >conftest.err
27628   rm -f conftest.er1
27629   cat conftest.err >&5
27630   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27631   (exit $ac_status); } &&
27632          { ac_try='test -z "$ac_c_werror_flag"
27633                          || test ! -s conftest.err'
27634   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27635   (eval $ac_try) 2>&5
27636   ac_status=$?
27637   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27638   (exit $ac_status); }; } &&
27639          { ac_try='test -s conftest.$ac_objext'
27640   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27641   (eval $ac_try) 2>&5
27642   ac_status=$?
27643   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27644   (exit $ac_status); }; }; then
27645   ol_cv_func_gethostbyaddr_r_nargs8=yes
27646 else
27647   echo "$as_me: failed program was:" >&5
27648 sed 's/^/| /' conftest.$ac_ext >&5
27649
27650 ol_cv_func_gethostbyaddr_r_nargs8=no
27651 fi
27652 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27653
27654         if test $ol_cv_func_gethostbyaddr_r_nargs7 = yes &&
27655            test $ol_cv_func_gethostbyaddr_r_nargs8 = no ; then
27656
27657                 ol_cv_func_gethostbyaddr_r_nargs=7
27658
27659         elif test $ol_cv_func_gethostbyaddr_r_nargs7 = no &&
27660              test $ol_cv_func_gethostbyaddr_r_nargs8 = yes ; then
27661
27662                 ol_cv_func_gethostbyaddr_r_nargs=8
27663
27664         else
27665                 ol_cv_func_gethostbyaddr_r_nargs=0
27666         fi
27667
27668 fi
27669 echo "$as_me:$LINENO: result: $ol_cv_func_gethostbyaddr_r_nargs" >&5
27670 echo "${ECHO_T}$ol_cv_func_gethostbyaddr_r_nargs" >&6
27671   if test $ol_cv_func_gethostbyaddr_r_nargs -gt 1 ; then
27672
27673 cat >>confdefs.h <<_ACEOF
27674 #define GETHOSTBYADDR_R_NARGS $ol_cv_func_gethostbyaddr_r_nargs
27675 _ACEOF
27676
27677   fi
27678
27679 else
27680         ol_cv_func_gethostbyaddr_r_nargs=0
27681 fi
27682
27683 ol_link_bdb=no
27684
27685 if test $ol_enable_bdb/$ol_enable_hdb != no/no; then
27686         ol_cv_berkeley_db=no
27687
27688 for ac_header in db.h
27689 do
27690 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
27691 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27692   echo "$as_me:$LINENO: checking for $ac_header" >&5
27693 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27694 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27695   echo $ECHO_N "(cached) $ECHO_C" >&6
27696 fi
27697 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27698 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27699 else
27700   # Is the header compilable?
27701 echo "$as_me:$LINENO: checking $ac_header usability" >&5
27702 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
27703 cat >conftest.$ac_ext <<_ACEOF
27704 /* confdefs.h.  */
27705 _ACEOF
27706 cat confdefs.h >>conftest.$ac_ext
27707 cat >>conftest.$ac_ext <<_ACEOF
27708 /* end confdefs.h.  */
27709 $ac_includes_default
27710 #include <$ac_header>
27711 _ACEOF
27712 rm -f conftest.$ac_objext
27713 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27714   (eval $ac_compile) 2>conftest.er1
27715   ac_status=$?
27716   grep -v '^ *+' conftest.er1 >conftest.err
27717   rm -f conftest.er1
27718   cat conftest.err >&5
27719   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27720   (exit $ac_status); } &&
27721          { ac_try='test -z "$ac_c_werror_flag"
27722                          || test ! -s conftest.err'
27723   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27724   (eval $ac_try) 2>&5
27725   ac_status=$?
27726   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27727   (exit $ac_status); }; } &&
27728          { ac_try='test -s conftest.$ac_objext'
27729   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27730   (eval $ac_try) 2>&5
27731   ac_status=$?
27732   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27733   (exit $ac_status); }; }; then
27734   ac_header_compiler=yes
27735 else
27736   echo "$as_me: failed program was:" >&5
27737 sed 's/^/| /' conftest.$ac_ext >&5
27738
27739 ac_header_compiler=no
27740 fi
27741 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27742 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
27743 echo "${ECHO_T}$ac_header_compiler" >&6
27744
27745 # Is the header present?
27746 echo "$as_me:$LINENO: checking $ac_header presence" >&5
27747 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
27748 cat >conftest.$ac_ext <<_ACEOF
27749 /* confdefs.h.  */
27750 _ACEOF
27751 cat confdefs.h >>conftest.$ac_ext
27752 cat >>conftest.$ac_ext <<_ACEOF
27753 /* end confdefs.h.  */
27754 #include <$ac_header>
27755 _ACEOF
27756 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
27757   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
27758   ac_status=$?
27759   grep -v '^ *+' conftest.er1 >conftest.err
27760   rm -f conftest.er1
27761   cat conftest.err >&5
27762   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27763   (exit $ac_status); } >/dev/null; then
27764   if test -s conftest.err; then
27765     ac_cpp_err=$ac_c_preproc_warn_flag
27766     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
27767   else
27768     ac_cpp_err=
27769   fi
27770 else
27771   ac_cpp_err=yes
27772 fi
27773 if test -z "$ac_cpp_err"; then
27774   ac_header_preproc=yes
27775 else
27776   echo "$as_me: failed program was:" >&5
27777 sed 's/^/| /' conftest.$ac_ext >&5
27778
27779   ac_header_preproc=no
27780 fi
27781 rm -f conftest.err conftest.$ac_ext
27782 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
27783 echo "${ECHO_T}$ac_header_preproc" >&6
27784
27785 # So?  What about this header?
27786 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
27787   yes:no: )
27788     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
27789 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
27790     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
27791 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
27792     ac_header_preproc=yes
27793     ;;
27794   no:yes:* )
27795     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
27796 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
27797     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
27798 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
27799     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
27800 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
27801     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
27802 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
27803     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27804 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27805     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
27806 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
27807     (
27808       cat <<\_ASBOX
27809 ## --------------------------------------------- ##
27810 ## Report this to <http://www.openldap.org/its/> ##
27811 ## --------------------------------------------- ##
27812 _ASBOX
27813     ) |
27814       sed "s/^/$as_me: WARNING:     /" >&2
27815     ;;
27816 esac
27817 echo "$as_me:$LINENO: checking for $ac_header" >&5
27818 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27819 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27820   echo $ECHO_N "(cached) $ECHO_C" >&6
27821 else
27822   eval "$as_ac_Header=\$ac_header_preproc"
27823 fi
27824 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27825 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27826
27827 fi
27828 if test `eval echo '${'$as_ac_Header'}'` = yes; then
27829   cat >>confdefs.h <<_ACEOF
27830 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
27831 _ACEOF
27832
27833 fi
27834
27835 done
27836
27837 if test $ac_cv_header_db_h = yes; then
27838         ol_cv_lib_db=no
27839
27840 echo "$as_me:$LINENO: checking for Berkeley DB major version" >&5
27841 echo $ECHO_N "checking for Berkeley DB major version... $ECHO_C" >&6
27842 if test "${ol_cv_bdb_major+set}" = set; then
27843   echo $ECHO_N "(cached) $ECHO_C" >&6
27844 else
27845
27846         ol_cv_bdb_major=0
27847         if test $ol_cv_bdb_major = 0 ; then
27848                 cat >conftest.$ac_ext <<_ACEOF
27849 /* confdefs.h.  */
27850 _ACEOF
27851 cat confdefs.h >>conftest.$ac_ext
27852 cat >>conftest.$ac_ext <<_ACEOF
27853 /* end confdefs.h.  */
27854
27855 #include <db.h>
27856 #ifndef DB_VERSION_MAJOR
27857 #       define DB_VERSION_MAJOR 1
27858 #endif
27859 #if DB_VERSION_MAJOR == 4
27860 __db_version
27861 #endif
27862
27863 _ACEOF
27864 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27865   $EGREP "__db_version" >/dev/null 2>&1; then
27866   ol_cv_bdb_major=4
27867 else
27868   :
27869 fi
27870 rm -f conftest*
27871
27872         fi
27873         if test $ol_cv_bdb_major = 0 ; then
27874                 cat >conftest.$ac_ext <<_ACEOF
27875 /* confdefs.h.  */
27876 _ACEOF
27877 cat confdefs.h >>conftest.$ac_ext
27878 cat >>conftest.$ac_ext <<_ACEOF
27879 /* end confdefs.h.  */
27880
27881 #include <db.h>
27882 #ifndef DB_VERSION_MAJOR
27883 #       define DB_VERSION_MAJOR 1
27884 #endif
27885 #if DB_VERSION_MAJOR == 3
27886 __db_version
27887 #endif
27888
27889 _ACEOF
27890 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27891   $EGREP "__db_version" >/dev/null 2>&1; then
27892   ol_cv_bdb_major=3
27893 else
27894   :
27895 fi
27896 rm -f conftest*
27897
27898         fi
27899         if test $ol_cv_bdb_major = 0 ; then
27900                 cat >conftest.$ac_ext <<_ACEOF
27901 /* confdefs.h.  */
27902 _ACEOF
27903 cat confdefs.h >>conftest.$ac_ext
27904 cat >>conftest.$ac_ext <<_ACEOF
27905 /* end confdefs.h.  */
27906
27907 #include <db.h>
27908 #ifndef DB_VERSION_MAJOR
27909 #       define DB_VERSION_MAJOR 1
27910 #endif
27911 #if DB_VERSION_MAJOR == 2
27912 __db_version
27913 #endif
27914
27915 _ACEOF
27916 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27917   $EGREP "__db_version" >/dev/null 2>&1; then
27918   ol_cv_bdb_major=2
27919 else
27920   :
27921 fi
27922 rm -f conftest*
27923
27924         fi
27925         if test $ol_cv_bdb_major = 0 ; then
27926                 cat >conftest.$ac_ext <<_ACEOF
27927 /* confdefs.h.  */
27928 _ACEOF
27929 cat confdefs.h >>conftest.$ac_ext
27930 cat >>conftest.$ac_ext <<_ACEOF
27931 /* end confdefs.h.  */
27932
27933 #include <db.h>
27934 #ifndef DB_VERSION_MAJOR
27935 #       define DB_VERSION_MAJOR 1
27936 #endif
27937 #if DB_VERSION_MAJOR == 1
27938 __db_version
27939 #endif
27940
27941 _ACEOF
27942 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27943   $EGREP "__db_version" >/dev/null 2>&1; then
27944   ol_cv_bdb_major=1
27945 else
27946   :
27947 fi
27948 rm -f conftest*
27949
27950         fi
27951
27952         if test $ol_cv_bdb_major = 0 ; then
27953                 { { echo "$as_me:$LINENO: error: Unknown Berkeley DB major version" >&5
27954 echo "$as_me: error: Unknown Berkeley DB major version" >&2;}
27955    { (exit 1); exit 1; }; }
27956         fi
27957
27958 fi
27959 echo "$as_me:$LINENO: result: $ol_cv_bdb_major" >&5
27960 echo "${ECHO_T}$ol_cv_bdb_major" >&6
27961
27962 echo "$as_me:$LINENO: checking for Berkeley DB minor version" >&5
27963 echo $ECHO_N "checking for Berkeley DB minor version... $ECHO_C" >&6
27964 if test "${ol_cv_bdb_minor+set}" = set; then
27965   echo $ECHO_N "(cached) $ECHO_C" >&6
27966 else
27967
27968         ol_cv_bdb_minor=0
27969         if test $ol_cv_bdb_minor = 0 ; then
27970                 cat >conftest.$ac_ext <<_ACEOF
27971 /* confdefs.h.  */
27972 _ACEOF
27973 cat confdefs.h >>conftest.$ac_ext
27974 cat >>conftest.$ac_ext <<_ACEOF
27975 /* end confdefs.h.  */
27976
27977 #include <db.h>
27978 #ifndef DB_VERSION_MINOR
27979 #       define DB_VERSION_MINOR 0
27980 #endif
27981 #if DB_VERSION_MINOR == 9
27982 __db_version
27983 #endif
27984
27985 _ACEOF
27986 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27987   $EGREP "__db_version" >/dev/null 2>&1; then
27988   ol_cv_bdb_minor=9
27989 else
27990   :
27991 fi
27992 rm -f conftest*
27993
27994         fi
27995         if test $ol_cv_bdb_minor = 0 ; then
27996                 cat >conftest.$ac_ext <<_ACEOF
27997 /* confdefs.h.  */
27998 _ACEOF
27999 cat confdefs.h >>conftest.$ac_ext
28000 cat >>conftest.$ac_ext <<_ACEOF
28001 /* end confdefs.h.  */
28002
28003 #include <db.h>
28004 #ifndef DB_VERSION_MINOR
28005 #       define DB_VERSION_MINOR 0
28006 #endif
28007 #if DB_VERSION_MINOR == 8
28008 __db_version
28009 #endif
28010
28011 _ACEOF
28012 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28013   $EGREP "__db_version" >/dev/null 2>&1; then
28014   ol_cv_bdb_minor=8
28015 else
28016   :
28017 fi
28018 rm -f conftest*
28019
28020         fi
28021         if test $ol_cv_bdb_minor = 0 ; then
28022                 cat >conftest.$ac_ext <<_ACEOF
28023 /* confdefs.h.  */
28024 _ACEOF
28025 cat confdefs.h >>conftest.$ac_ext
28026 cat >>conftest.$ac_ext <<_ACEOF
28027 /* end confdefs.h.  */
28028
28029 #include <db.h>
28030 #ifndef DB_VERSION_MINOR
28031 #       define DB_VERSION_MINOR 0
28032 #endif
28033 #if DB_VERSION_MINOR == 7
28034 __db_version
28035 #endif
28036
28037 _ACEOF
28038 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28039   $EGREP "__db_version" >/dev/null 2>&1; then
28040   ol_cv_bdb_minor=7
28041 else
28042   :
28043 fi
28044 rm -f conftest*
28045
28046         fi
28047         if test $ol_cv_bdb_minor = 0 ; then
28048                 cat >conftest.$ac_ext <<_ACEOF
28049 /* confdefs.h.  */
28050 _ACEOF
28051 cat confdefs.h >>conftest.$ac_ext
28052 cat >>conftest.$ac_ext <<_ACEOF
28053 /* end confdefs.h.  */
28054
28055 #include <db.h>
28056 #ifndef DB_VERSION_MINOR
28057 #       define DB_VERSION_MINOR 0
28058 #endif
28059 #if DB_VERSION_MINOR == 6
28060 __db_version
28061 #endif
28062
28063 _ACEOF
28064 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28065   $EGREP "__db_version" >/dev/null 2>&1; then
28066   ol_cv_bdb_minor=6
28067 else
28068   :
28069 fi
28070 rm -f conftest*
28071
28072         fi
28073         if test $ol_cv_bdb_minor = 0 ; then
28074                 cat >conftest.$ac_ext <<_ACEOF
28075 /* confdefs.h.  */
28076 _ACEOF
28077 cat confdefs.h >>conftest.$ac_ext
28078 cat >>conftest.$ac_ext <<_ACEOF
28079 /* end confdefs.h.  */
28080
28081 #include <db.h>
28082 #ifndef DB_VERSION_MINOR
28083 #       define DB_VERSION_MINOR 0
28084 #endif
28085 #if DB_VERSION_MINOR == 5
28086 __db_version
28087 #endif
28088
28089 _ACEOF
28090 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28091   $EGREP "__db_version" >/dev/null 2>&1; then
28092   ol_cv_bdb_minor=5
28093 else
28094   :
28095 fi
28096 rm -f conftest*
28097
28098         fi
28099         if test $ol_cv_bdb_minor = 0 ; then
28100                 cat >conftest.$ac_ext <<_ACEOF
28101 /* confdefs.h.  */
28102 _ACEOF
28103 cat confdefs.h >>conftest.$ac_ext
28104 cat >>conftest.$ac_ext <<_ACEOF
28105 /* end confdefs.h.  */
28106
28107 #include <db.h>
28108 #ifndef DB_VERSION_MINOR
28109 #       define DB_VERSION_MINOR 0
28110 #endif
28111 #if DB_VERSION_MINOR == 4
28112 __db_version
28113 #endif
28114
28115 _ACEOF
28116 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28117   $EGREP "__db_version" >/dev/null 2>&1; then
28118   ol_cv_bdb_minor=4
28119 else
28120   :
28121 fi
28122 rm -f conftest*
28123
28124         fi
28125         if test $ol_cv_bdb_minor = 0 ; then
28126                 cat >conftest.$ac_ext <<_ACEOF
28127 /* confdefs.h.  */
28128 _ACEOF
28129 cat confdefs.h >>conftest.$ac_ext
28130 cat >>conftest.$ac_ext <<_ACEOF
28131 /* end confdefs.h.  */
28132
28133 #include <db.h>
28134 #ifndef DB_VERSION_MINOR
28135 #       define DB_VERSION_MINOR 0
28136 #endif
28137 #if DB_VERSION_MINOR == 3
28138 __db_version
28139 #endif
28140
28141 _ACEOF
28142 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28143   $EGREP "__db_version" >/dev/null 2>&1; then
28144   ol_cv_bdb_minor=3
28145 else
28146   :
28147 fi
28148 rm -f conftest*
28149
28150         fi
28151         if test $ol_cv_bdb_minor = 0 ; then
28152                 cat >conftest.$ac_ext <<_ACEOF
28153 /* confdefs.h.  */
28154 _ACEOF
28155 cat confdefs.h >>conftest.$ac_ext
28156 cat >>conftest.$ac_ext <<_ACEOF
28157 /* end confdefs.h.  */
28158
28159 #include <db.h>
28160 #ifndef DB_VERSION_MINOR
28161 #       define DB_VERSION_MINOR 0
28162 #endif
28163 #if DB_VERSION_MINOR == 2
28164 __db_version
28165 #endif
28166
28167 _ACEOF
28168 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28169   $EGREP "__db_version" >/dev/null 2>&1; then
28170   ol_cv_bdb_minor=2
28171 else
28172   :
28173 fi
28174 rm -f conftest*
28175
28176         fi
28177         if test $ol_cv_bdb_minor = 0 ; then
28178                 cat >conftest.$ac_ext <<_ACEOF
28179 /* confdefs.h.  */
28180 _ACEOF
28181 cat confdefs.h >>conftest.$ac_ext
28182 cat >>conftest.$ac_ext <<_ACEOF
28183 /* end confdefs.h.  */
28184
28185 #include <db.h>
28186 #ifndef DB_VERSION_MINOR
28187 #       define DB_VERSION_MINOR 0
28188 #endif
28189 #if DB_VERSION_MINOR == 1
28190 __db_version
28191 #endif
28192
28193 _ACEOF
28194 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28195   $EGREP "__db_version" >/dev/null 2>&1; then
28196   ol_cv_bdb_minor=1
28197 else
28198   :
28199 fi
28200 rm -f conftest*
28201
28202         fi
28203
28204 fi
28205 echo "$as_me:$LINENO: result: $ol_cv_bdb_minor" >&5
28206 echo "${ECHO_T}$ol_cv_bdb_minor" >&6
28207
28208 if test $ol_cv_bdb_major = 4 ; then
28209         if test $ol_cv_bdb_minor = 4 ; then
28210                 if test $ol_cv_lib_db = no ; then
28211         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb44)" >&5
28212 echo $ECHO_N "checking for Berkeley DB link (-ldb44)... $ECHO_C" >&6
28213 if test "${ol_cv_db_db44+set}" = set; then
28214   echo $ECHO_N "(cached) $ECHO_C" >&6
28215 else
28216
28217         ol_DB_LIB=-ldb44
28218         ol_LIBS=$LIBS
28219         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28220
28221         cat >conftest.$ac_ext <<_ACEOF
28222 /* confdefs.h.  */
28223 _ACEOF
28224 cat confdefs.h >>conftest.$ac_ext
28225 cat >>conftest.$ac_ext <<_ACEOF
28226 /* end confdefs.h.  */
28227
28228 #ifdef HAVE_DB_185_H
28229 # include <db_185.h>
28230 #else
28231 # include <db.h>
28232 #endif
28233
28234 #ifndef DB_VERSION_MAJOR
28235 # define DB_VERSION_MAJOR 1
28236 #endif
28237
28238 #ifndef NULL
28239 #define NULL ((void*)0)
28240 #endif
28241
28242 int
28243 main ()
28244 {
28245
28246 #if DB_VERSION_MAJOR > 1
28247         {
28248                 char *version;
28249                 int major, minor, patch;
28250
28251                 version = db_version( &major, &minor, &patch );
28252
28253                 if( major != DB_VERSION_MAJOR ||
28254                         minor < DB_VERSION_MINOR )
28255                 {
28256                         printf("Berkeley DB version mismatch\n"
28257                                 "\theader: %s\n\tlibrary: %s\n",
28258                                 DB_VERSION_STRING, version);
28259                         return 1;
28260                 }
28261         }
28262 #endif
28263
28264 #if DB_VERSION_MAJOR > 2
28265         db_env_create( NULL, 0 );
28266 #elif DB_VERSION_MAJOR > 1
28267         db_appexit( NULL );
28268 #else
28269         (void) dbopen( NULL, 0, 0, 0, NULL);
28270 #endif
28271
28272   ;
28273   return 0;
28274 }
28275 _ACEOF
28276 rm -f conftest.$ac_objext conftest$ac_exeext
28277 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28278   (eval $ac_link) 2>conftest.er1
28279   ac_status=$?
28280   grep -v '^ *+' conftest.er1 >conftest.err
28281   rm -f conftest.er1
28282   cat conftest.err >&5
28283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28284   (exit $ac_status); } &&
28285          { ac_try='test -z "$ac_c_werror_flag"
28286                          || test ! -s conftest.err'
28287   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28288   (eval $ac_try) 2>&5
28289   ac_status=$?
28290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28291   (exit $ac_status); }; } &&
28292          { ac_try='test -s conftest$ac_exeext'
28293   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28294   (eval $ac_try) 2>&5
28295   ac_status=$?
28296   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28297   (exit $ac_status); }; }; then
28298   ol_cv_db_db44=yes
28299 else
28300   echo "$as_me: failed program was:" >&5
28301 sed 's/^/| /' conftest.$ac_ext >&5
28302
28303 ol_cv_db_db44=no
28304 fi
28305 rm -f conftest.err conftest.$ac_objext \
28306       conftest$ac_exeext conftest.$ac_ext
28307
28308         LIBS="$ol_LIBS"
28309
28310 fi
28311 echo "$as_me:$LINENO: result: $ol_cv_db_db44" >&5
28312 echo "${ECHO_T}$ol_cv_db_db44" >&6
28313
28314         if test $ol_cv_db_db44 = yes ; then
28315                 ol_cv_lib_db=-ldb44
28316         fi
28317 fi
28318
28319                 if test $ol_cv_lib_db = no ; then
28320         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-44)" >&5
28321 echo $ECHO_N "checking for Berkeley DB link (-ldb-44)... $ECHO_C" >&6
28322 if test "${ol_cv_db_db_44+set}" = set; then
28323   echo $ECHO_N "(cached) $ECHO_C" >&6
28324 else
28325
28326         ol_DB_LIB=-ldb-44
28327         ol_LIBS=$LIBS
28328         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28329
28330         cat >conftest.$ac_ext <<_ACEOF
28331 /* confdefs.h.  */
28332 _ACEOF
28333 cat confdefs.h >>conftest.$ac_ext
28334 cat >>conftest.$ac_ext <<_ACEOF
28335 /* end confdefs.h.  */
28336
28337 #ifdef HAVE_DB_185_H
28338 # include <db_185.h>
28339 #else
28340 # include <db.h>
28341 #endif
28342
28343 #ifndef DB_VERSION_MAJOR
28344 # define DB_VERSION_MAJOR 1
28345 #endif
28346
28347 #ifndef NULL
28348 #define NULL ((void*)0)
28349 #endif
28350
28351 int
28352 main ()
28353 {
28354
28355 #if DB_VERSION_MAJOR > 1
28356         {
28357                 char *version;
28358                 int major, minor, patch;
28359
28360                 version = db_version( &major, &minor, &patch );
28361
28362                 if( major != DB_VERSION_MAJOR ||
28363                         minor < DB_VERSION_MINOR )
28364                 {
28365                         printf("Berkeley DB version mismatch\n"
28366                                 "\theader: %s\n\tlibrary: %s\n",
28367                                 DB_VERSION_STRING, version);
28368                         return 1;
28369                 }
28370         }
28371 #endif
28372
28373 #if DB_VERSION_MAJOR > 2
28374         db_env_create( NULL, 0 );
28375 #elif DB_VERSION_MAJOR > 1
28376         db_appexit( NULL );
28377 #else
28378         (void) dbopen( NULL, 0, 0, 0, NULL);
28379 #endif
28380
28381   ;
28382   return 0;
28383 }
28384 _ACEOF
28385 rm -f conftest.$ac_objext conftest$ac_exeext
28386 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28387   (eval $ac_link) 2>conftest.er1
28388   ac_status=$?
28389   grep -v '^ *+' conftest.er1 >conftest.err
28390   rm -f conftest.er1
28391   cat conftest.err >&5
28392   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28393   (exit $ac_status); } &&
28394          { ac_try='test -z "$ac_c_werror_flag"
28395                          || test ! -s conftest.err'
28396   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28397   (eval $ac_try) 2>&5
28398   ac_status=$?
28399   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28400   (exit $ac_status); }; } &&
28401          { ac_try='test -s conftest$ac_exeext'
28402   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28403   (eval $ac_try) 2>&5
28404   ac_status=$?
28405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28406   (exit $ac_status); }; }; then
28407   ol_cv_db_db_44=yes
28408 else
28409   echo "$as_me: failed program was:" >&5
28410 sed 's/^/| /' conftest.$ac_ext >&5
28411
28412 ol_cv_db_db_44=no
28413 fi
28414 rm -f conftest.err conftest.$ac_objext \
28415       conftest$ac_exeext conftest.$ac_ext
28416
28417         LIBS="$ol_LIBS"
28418
28419 fi
28420 echo "$as_me:$LINENO: result: $ol_cv_db_db_44" >&5
28421 echo "${ECHO_T}$ol_cv_db_db_44" >&6
28422
28423         if test $ol_cv_db_db_44 = yes ; then
28424                 ol_cv_lib_db=-ldb-44
28425         fi
28426 fi
28427
28428                 if test $ol_cv_lib_db = no ; then
28429         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.4)" >&5
28430 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.4)... $ECHO_C" >&6
28431 if test "${ol_cv_db_db_4_dot_4+set}" = set; then
28432   echo $ECHO_N "(cached) $ECHO_C" >&6
28433 else
28434
28435         ol_DB_LIB=-ldb-4.4
28436         ol_LIBS=$LIBS
28437         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28438
28439         cat >conftest.$ac_ext <<_ACEOF
28440 /* confdefs.h.  */
28441 _ACEOF
28442 cat confdefs.h >>conftest.$ac_ext
28443 cat >>conftest.$ac_ext <<_ACEOF
28444 /* end confdefs.h.  */
28445
28446 #ifdef HAVE_DB_185_H
28447 # include <db_185.h>
28448 #else
28449 # include <db.h>
28450 #endif
28451
28452 #ifndef DB_VERSION_MAJOR
28453 # define DB_VERSION_MAJOR 1
28454 #endif
28455
28456 #ifndef NULL
28457 #define NULL ((void*)0)
28458 #endif
28459
28460 int
28461 main ()
28462 {
28463
28464 #if DB_VERSION_MAJOR > 1
28465         {
28466                 char *version;
28467                 int major, minor, patch;
28468
28469                 version = db_version( &major, &minor, &patch );
28470
28471                 if( major != DB_VERSION_MAJOR ||
28472                         minor < DB_VERSION_MINOR )
28473                 {
28474                         printf("Berkeley DB version mismatch\n"
28475                                 "\theader: %s\n\tlibrary: %s\n",
28476                                 DB_VERSION_STRING, version);
28477                         return 1;
28478                 }
28479         }
28480 #endif
28481
28482 #if DB_VERSION_MAJOR > 2
28483         db_env_create( NULL, 0 );
28484 #elif DB_VERSION_MAJOR > 1
28485         db_appexit( NULL );
28486 #else
28487         (void) dbopen( NULL, 0, 0, 0, NULL);
28488 #endif
28489
28490   ;
28491   return 0;
28492 }
28493 _ACEOF
28494 rm -f conftest.$ac_objext conftest$ac_exeext
28495 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28496   (eval $ac_link) 2>conftest.er1
28497   ac_status=$?
28498   grep -v '^ *+' conftest.er1 >conftest.err
28499   rm -f conftest.er1
28500   cat conftest.err >&5
28501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28502   (exit $ac_status); } &&
28503          { ac_try='test -z "$ac_c_werror_flag"
28504                          || test ! -s conftest.err'
28505   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28506   (eval $ac_try) 2>&5
28507   ac_status=$?
28508   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28509   (exit $ac_status); }; } &&
28510          { ac_try='test -s conftest$ac_exeext'
28511   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28512   (eval $ac_try) 2>&5
28513   ac_status=$?
28514   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28515   (exit $ac_status); }; }; then
28516   ol_cv_db_db_4_dot_4=yes
28517 else
28518   echo "$as_me: failed program was:" >&5
28519 sed 's/^/| /' conftest.$ac_ext >&5
28520
28521 ol_cv_db_db_4_dot_4=no
28522 fi
28523 rm -f conftest.err conftest.$ac_objext \
28524       conftest$ac_exeext conftest.$ac_ext
28525
28526         LIBS="$ol_LIBS"
28527
28528 fi
28529 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_4" >&5
28530 echo "${ECHO_T}$ol_cv_db_db_4_dot_4" >&6
28531
28532         if test $ol_cv_db_db_4_dot_4 = yes ; then
28533                 ol_cv_lib_db=-ldb-4.4
28534         fi
28535 fi
28536
28537                 if test $ol_cv_lib_db = no ; then
28538         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-4)" >&5
28539 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-4)... $ECHO_C" >&6
28540 if test "${ol_cv_db_db_4_4+set}" = set; then
28541   echo $ECHO_N "(cached) $ECHO_C" >&6
28542 else
28543
28544         ol_DB_LIB=-ldb-4-4
28545         ol_LIBS=$LIBS
28546         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28547
28548         cat >conftest.$ac_ext <<_ACEOF
28549 /* confdefs.h.  */
28550 _ACEOF
28551 cat confdefs.h >>conftest.$ac_ext
28552 cat >>conftest.$ac_ext <<_ACEOF
28553 /* end confdefs.h.  */
28554
28555 #ifdef HAVE_DB_185_H
28556 # include <db_185.h>
28557 #else
28558 # include <db.h>
28559 #endif
28560
28561 #ifndef DB_VERSION_MAJOR
28562 # define DB_VERSION_MAJOR 1
28563 #endif
28564
28565 #ifndef NULL
28566 #define NULL ((void*)0)
28567 #endif
28568
28569 int
28570 main ()
28571 {
28572
28573 #if DB_VERSION_MAJOR > 1
28574         {
28575                 char *version;
28576                 int major, minor, patch;
28577
28578                 version = db_version( &major, &minor, &patch );
28579
28580                 if( major != DB_VERSION_MAJOR ||
28581                         minor < DB_VERSION_MINOR )
28582                 {
28583                         printf("Berkeley DB version mismatch\n"
28584                                 "\theader: %s\n\tlibrary: %s\n",
28585                                 DB_VERSION_STRING, version);
28586                         return 1;
28587                 }
28588         }
28589 #endif
28590
28591 #if DB_VERSION_MAJOR > 2
28592         db_env_create( NULL, 0 );
28593 #elif DB_VERSION_MAJOR > 1
28594         db_appexit( NULL );
28595 #else
28596         (void) dbopen( NULL, 0, 0, 0, NULL);
28597 #endif
28598
28599   ;
28600   return 0;
28601 }
28602 _ACEOF
28603 rm -f conftest.$ac_objext conftest$ac_exeext
28604 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28605   (eval $ac_link) 2>conftest.er1
28606   ac_status=$?
28607   grep -v '^ *+' conftest.er1 >conftest.err
28608   rm -f conftest.er1
28609   cat conftest.err >&5
28610   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28611   (exit $ac_status); } &&
28612          { ac_try='test -z "$ac_c_werror_flag"
28613                          || test ! -s conftest.err'
28614   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28615   (eval $ac_try) 2>&5
28616   ac_status=$?
28617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28618   (exit $ac_status); }; } &&
28619          { ac_try='test -s conftest$ac_exeext'
28620   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28621   (eval $ac_try) 2>&5
28622   ac_status=$?
28623   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28624   (exit $ac_status); }; }; then
28625   ol_cv_db_db_4_4=yes
28626 else
28627   echo "$as_me: failed program was:" >&5
28628 sed 's/^/| /' conftest.$ac_ext >&5
28629
28630 ol_cv_db_db_4_4=no
28631 fi
28632 rm -f conftest.err conftest.$ac_objext \
28633       conftest$ac_exeext conftest.$ac_ext
28634
28635         LIBS="$ol_LIBS"
28636
28637 fi
28638 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_4" >&5
28639 echo "${ECHO_T}$ol_cv_db_db_4_4" >&6
28640
28641         if test $ol_cv_db_db_4_4 = yes ; then
28642                 ol_cv_lib_db=-ldb-4-4
28643         fi
28644 fi
28645
28646         elif test $ol_cv_bdb_minor = 3 ; then
28647                 if test $ol_cv_lib_db = no ; then
28648         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb43)" >&5
28649 echo $ECHO_N "checking for Berkeley DB link (-ldb43)... $ECHO_C" >&6
28650 if test "${ol_cv_db_db43+set}" = set; then
28651   echo $ECHO_N "(cached) $ECHO_C" >&6
28652 else
28653
28654         ol_DB_LIB=-ldb43
28655         ol_LIBS=$LIBS
28656         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28657
28658         cat >conftest.$ac_ext <<_ACEOF
28659 /* confdefs.h.  */
28660 _ACEOF
28661 cat confdefs.h >>conftest.$ac_ext
28662 cat >>conftest.$ac_ext <<_ACEOF
28663 /* end confdefs.h.  */
28664
28665 #ifdef HAVE_DB_185_H
28666 # include <db_185.h>
28667 #else
28668 # include <db.h>
28669 #endif
28670
28671 #ifndef DB_VERSION_MAJOR
28672 # define DB_VERSION_MAJOR 1
28673 #endif
28674
28675 #ifndef NULL
28676 #define NULL ((void*)0)
28677 #endif
28678
28679 int
28680 main ()
28681 {
28682
28683 #if DB_VERSION_MAJOR > 1
28684         {
28685                 char *version;
28686                 int major, minor, patch;
28687
28688                 version = db_version( &major, &minor, &patch );
28689
28690                 if( major != DB_VERSION_MAJOR ||
28691                         minor < DB_VERSION_MINOR )
28692                 {
28693                         printf("Berkeley DB version mismatch\n"
28694                                 "\theader: %s\n\tlibrary: %s\n",
28695                                 DB_VERSION_STRING, version);
28696                         return 1;
28697                 }
28698         }
28699 #endif
28700
28701 #if DB_VERSION_MAJOR > 2
28702         db_env_create( NULL, 0 );
28703 #elif DB_VERSION_MAJOR > 1
28704         db_appexit( NULL );
28705 #else
28706         (void) dbopen( NULL, 0, 0, 0, NULL);
28707 #endif
28708
28709   ;
28710   return 0;
28711 }
28712 _ACEOF
28713 rm -f conftest.$ac_objext conftest$ac_exeext
28714 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28715   (eval $ac_link) 2>conftest.er1
28716   ac_status=$?
28717   grep -v '^ *+' conftest.er1 >conftest.err
28718   rm -f conftest.er1
28719   cat conftest.err >&5
28720   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28721   (exit $ac_status); } &&
28722          { ac_try='test -z "$ac_c_werror_flag"
28723                          || test ! -s conftest.err'
28724   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28725   (eval $ac_try) 2>&5
28726   ac_status=$?
28727   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28728   (exit $ac_status); }; } &&
28729          { ac_try='test -s conftest$ac_exeext'
28730   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28731   (eval $ac_try) 2>&5
28732   ac_status=$?
28733   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28734   (exit $ac_status); }; }; then
28735   ol_cv_db_db43=yes
28736 else
28737   echo "$as_me: failed program was:" >&5
28738 sed 's/^/| /' conftest.$ac_ext >&5
28739
28740 ol_cv_db_db43=no
28741 fi
28742 rm -f conftest.err conftest.$ac_objext \
28743       conftest$ac_exeext conftest.$ac_ext
28744
28745         LIBS="$ol_LIBS"
28746
28747 fi
28748 echo "$as_me:$LINENO: result: $ol_cv_db_db43" >&5
28749 echo "${ECHO_T}$ol_cv_db_db43" >&6
28750
28751         if test $ol_cv_db_db43 = yes ; then
28752                 ol_cv_lib_db=-ldb43
28753         fi
28754 fi
28755
28756                 if test $ol_cv_lib_db = no ; then
28757         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-43)" >&5
28758 echo $ECHO_N "checking for Berkeley DB link (-ldb-43)... $ECHO_C" >&6
28759 if test "${ol_cv_db_db_43+set}" = set; then
28760   echo $ECHO_N "(cached) $ECHO_C" >&6
28761 else
28762
28763         ol_DB_LIB=-ldb-43
28764         ol_LIBS=$LIBS
28765         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28766
28767         cat >conftest.$ac_ext <<_ACEOF
28768 /* confdefs.h.  */
28769 _ACEOF
28770 cat confdefs.h >>conftest.$ac_ext
28771 cat >>conftest.$ac_ext <<_ACEOF
28772 /* end confdefs.h.  */
28773
28774 #ifdef HAVE_DB_185_H
28775 # include <db_185.h>
28776 #else
28777 # include <db.h>
28778 #endif
28779
28780 #ifndef DB_VERSION_MAJOR
28781 # define DB_VERSION_MAJOR 1
28782 #endif
28783
28784 #ifndef NULL
28785 #define NULL ((void*)0)
28786 #endif
28787
28788 int
28789 main ()
28790 {
28791
28792 #if DB_VERSION_MAJOR > 1
28793         {
28794                 char *version;
28795                 int major, minor, patch;
28796
28797                 version = db_version( &major, &minor, &patch );
28798
28799                 if( major != DB_VERSION_MAJOR ||
28800                         minor < DB_VERSION_MINOR )
28801                 {
28802                         printf("Berkeley DB version mismatch\n"
28803                                 "\theader: %s\n\tlibrary: %s\n",
28804                                 DB_VERSION_STRING, version);
28805                         return 1;
28806                 }
28807         }
28808 #endif
28809
28810 #if DB_VERSION_MAJOR > 2
28811         db_env_create( NULL, 0 );
28812 #elif DB_VERSION_MAJOR > 1
28813         db_appexit( NULL );
28814 #else
28815         (void) dbopen( NULL, 0, 0, 0, NULL);
28816 #endif
28817
28818   ;
28819   return 0;
28820 }
28821 _ACEOF
28822 rm -f conftest.$ac_objext conftest$ac_exeext
28823 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28824   (eval $ac_link) 2>conftest.er1
28825   ac_status=$?
28826   grep -v '^ *+' conftest.er1 >conftest.err
28827   rm -f conftest.er1
28828   cat conftest.err >&5
28829   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28830   (exit $ac_status); } &&
28831          { ac_try='test -z "$ac_c_werror_flag"
28832                          || test ! -s conftest.err'
28833   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28834   (eval $ac_try) 2>&5
28835   ac_status=$?
28836   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28837   (exit $ac_status); }; } &&
28838          { ac_try='test -s conftest$ac_exeext'
28839   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28840   (eval $ac_try) 2>&5
28841   ac_status=$?
28842   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28843   (exit $ac_status); }; }; then
28844   ol_cv_db_db_43=yes
28845 else
28846   echo "$as_me: failed program was:" >&5
28847 sed 's/^/| /' conftest.$ac_ext >&5
28848
28849 ol_cv_db_db_43=no
28850 fi
28851 rm -f conftest.err conftest.$ac_objext \
28852       conftest$ac_exeext conftest.$ac_ext
28853
28854         LIBS="$ol_LIBS"
28855
28856 fi
28857 echo "$as_me:$LINENO: result: $ol_cv_db_db_43" >&5
28858 echo "${ECHO_T}$ol_cv_db_db_43" >&6
28859
28860         if test $ol_cv_db_db_43 = yes ; then
28861                 ol_cv_lib_db=-ldb-43
28862         fi
28863 fi
28864
28865                 if test $ol_cv_lib_db = no ; then
28866         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.3)" >&5
28867 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.3)... $ECHO_C" >&6
28868 if test "${ol_cv_db_db_4_dot_3+set}" = set; then
28869   echo $ECHO_N "(cached) $ECHO_C" >&6
28870 else
28871
28872         ol_DB_LIB=-ldb-4.3
28873         ol_LIBS=$LIBS
28874         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28875
28876         cat >conftest.$ac_ext <<_ACEOF
28877 /* confdefs.h.  */
28878 _ACEOF
28879 cat confdefs.h >>conftest.$ac_ext
28880 cat >>conftest.$ac_ext <<_ACEOF
28881 /* end confdefs.h.  */
28882
28883 #ifdef HAVE_DB_185_H
28884 # include <db_185.h>
28885 #else
28886 # include <db.h>
28887 #endif
28888
28889 #ifndef DB_VERSION_MAJOR
28890 # define DB_VERSION_MAJOR 1
28891 #endif
28892
28893 #ifndef NULL
28894 #define NULL ((void*)0)
28895 #endif
28896
28897 int
28898 main ()
28899 {
28900
28901 #if DB_VERSION_MAJOR > 1
28902         {
28903                 char *version;
28904                 int major, minor, patch;
28905
28906                 version = db_version( &major, &minor, &patch );
28907
28908                 if( major != DB_VERSION_MAJOR ||
28909                         minor < DB_VERSION_MINOR )
28910                 {
28911                         printf("Berkeley DB version mismatch\n"
28912                                 "\theader: %s\n\tlibrary: %s\n",
28913                                 DB_VERSION_STRING, version);
28914                         return 1;
28915                 }
28916         }
28917 #endif
28918
28919 #if DB_VERSION_MAJOR > 2
28920         db_env_create( NULL, 0 );
28921 #elif DB_VERSION_MAJOR > 1
28922         db_appexit( NULL );
28923 #else
28924         (void) dbopen( NULL, 0, 0, 0, NULL);
28925 #endif
28926
28927   ;
28928   return 0;
28929 }
28930 _ACEOF
28931 rm -f conftest.$ac_objext conftest$ac_exeext
28932 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28933   (eval $ac_link) 2>conftest.er1
28934   ac_status=$?
28935   grep -v '^ *+' conftest.er1 >conftest.err
28936   rm -f conftest.er1
28937   cat conftest.err >&5
28938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28939   (exit $ac_status); } &&
28940          { ac_try='test -z "$ac_c_werror_flag"
28941                          || test ! -s conftest.err'
28942   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28943   (eval $ac_try) 2>&5
28944   ac_status=$?
28945   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28946   (exit $ac_status); }; } &&
28947          { ac_try='test -s conftest$ac_exeext'
28948   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28949   (eval $ac_try) 2>&5
28950   ac_status=$?
28951   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28952   (exit $ac_status); }; }; then
28953   ol_cv_db_db_4_dot_3=yes
28954 else
28955   echo "$as_me: failed program was:" >&5
28956 sed 's/^/| /' conftest.$ac_ext >&5
28957
28958 ol_cv_db_db_4_dot_3=no
28959 fi
28960 rm -f conftest.err conftest.$ac_objext \
28961       conftest$ac_exeext conftest.$ac_ext
28962
28963         LIBS="$ol_LIBS"
28964
28965 fi
28966 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_3" >&5
28967 echo "${ECHO_T}$ol_cv_db_db_4_dot_3" >&6
28968
28969         if test $ol_cv_db_db_4_dot_3 = yes ; then
28970                 ol_cv_lib_db=-ldb-4.3
28971         fi
28972 fi
28973
28974                 if test $ol_cv_lib_db = no ; then
28975         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-3)" >&5
28976 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-3)... $ECHO_C" >&6
28977 if test "${ol_cv_db_db_4_3+set}" = set; then
28978   echo $ECHO_N "(cached) $ECHO_C" >&6
28979 else
28980
28981         ol_DB_LIB=-ldb-4-3
28982         ol_LIBS=$LIBS
28983         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28984
28985         cat >conftest.$ac_ext <<_ACEOF
28986 /* confdefs.h.  */
28987 _ACEOF
28988 cat confdefs.h >>conftest.$ac_ext
28989 cat >>conftest.$ac_ext <<_ACEOF
28990 /* end confdefs.h.  */
28991
28992 #ifdef HAVE_DB_185_H
28993 # include <db_185.h>
28994 #else
28995 # include <db.h>
28996 #endif
28997
28998 #ifndef DB_VERSION_MAJOR
28999 # define DB_VERSION_MAJOR 1
29000 #endif
29001
29002 #ifndef NULL
29003 #define NULL ((void*)0)
29004 #endif
29005
29006 int
29007 main ()
29008 {
29009
29010 #if DB_VERSION_MAJOR > 1
29011         {
29012                 char *version;
29013                 int major, minor, patch;
29014
29015                 version = db_version( &major, &minor, &patch );
29016
29017                 if( major != DB_VERSION_MAJOR ||
29018                         minor < DB_VERSION_MINOR )
29019                 {
29020                         printf("Berkeley DB version mismatch\n"
29021                                 "\theader: %s\n\tlibrary: %s\n",
29022                                 DB_VERSION_STRING, version);
29023                         return 1;
29024                 }
29025         }
29026 #endif
29027
29028 #if DB_VERSION_MAJOR > 2
29029         db_env_create( NULL, 0 );
29030 #elif DB_VERSION_MAJOR > 1
29031         db_appexit( NULL );
29032 #else
29033         (void) dbopen( NULL, 0, 0, 0, NULL);
29034 #endif
29035
29036   ;
29037   return 0;
29038 }
29039 _ACEOF
29040 rm -f conftest.$ac_objext conftest$ac_exeext
29041 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29042   (eval $ac_link) 2>conftest.er1
29043   ac_status=$?
29044   grep -v '^ *+' conftest.er1 >conftest.err
29045   rm -f conftest.er1
29046   cat conftest.err >&5
29047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29048   (exit $ac_status); } &&
29049          { ac_try='test -z "$ac_c_werror_flag"
29050                          || test ! -s conftest.err'
29051   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29052   (eval $ac_try) 2>&5
29053   ac_status=$?
29054   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29055   (exit $ac_status); }; } &&
29056          { ac_try='test -s conftest$ac_exeext'
29057   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29058   (eval $ac_try) 2>&5
29059   ac_status=$?
29060   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29061   (exit $ac_status); }; }; then
29062   ol_cv_db_db_4_3=yes
29063 else
29064   echo "$as_me: failed program was:" >&5
29065 sed 's/^/| /' conftest.$ac_ext >&5
29066
29067 ol_cv_db_db_4_3=no
29068 fi
29069 rm -f conftest.err conftest.$ac_objext \
29070       conftest$ac_exeext conftest.$ac_ext
29071
29072         LIBS="$ol_LIBS"
29073
29074 fi
29075 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_3" >&5
29076 echo "${ECHO_T}$ol_cv_db_db_4_3" >&6
29077
29078         if test $ol_cv_db_db_4_3 = yes ; then
29079                 ol_cv_lib_db=-ldb-4-3
29080         fi
29081 fi
29082
29083         elif test $ol_cv_bdb_minor = 2 ; then
29084                 if test $ol_cv_lib_db = no ; then
29085         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb42)" >&5
29086 echo $ECHO_N "checking for Berkeley DB link (-ldb42)... $ECHO_C" >&6
29087 if test "${ol_cv_db_db42+set}" = set; then
29088   echo $ECHO_N "(cached) $ECHO_C" >&6
29089 else
29090
29091         ol_DB_LIB=-ldb42
29092         ol_LIBS=$LIBS
29093         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29094
29095         cat >conftest.$ac_ext <<_ACEOF
29096 /* confdefs.h.  */
29097 _ACEOF
29098 cat confdefs.h >>conftest.$ac_ext
29099 cat >>conftest.$ac_ext <<_ACEOF
29100 /* end confdefs.h.  */
29101
29102 #ifdef HAVE_DB_185_H
29103 # include <db_185.h>
29104 #else
29105 # include <db.h>
29106 #endif
29107
29108 #ifndef DB_VERSION_MAJOR
29109 # define DB_VERSION_MAJOR 1
29110 #endif
29111
29112 #ifndef NULL
29113 #define NULL ((void*)0)
29114 #endif
29115
29116 int
29117 main ()
29118 {
29119
29120 #if DB_VERSION_MAJOR > 1
29121         {
29122                 char *version;
29123                 int major, minor, patch;
29124
29125                 version = db_version( &major, &minor, &patch );
29126
29127                 if( major != DB_VERSION_MAJOR ||
29128                         minor < DB_VERSION_MINOR )
29129                 {
29130                         printf("Berkeley DB version mismatch\n"
29131                                 "\theader: %s\n\tlibrary: %s\n",
29132                                 DB_VERSION_STRING, version);
29133                         return 1;
29134                 }
29135         }
29136 #endif
29137
29138 #if DB_VERSION_MAJOR > 2
29139         db_env_create( NULL, 0 );
29140 #elif DB_VERSION_MAJOR > 1
29141         db_appexit( NULL );
29142 #else
29143         (void) dbopen( NULL, 0, 0, 0, NULL);
29144 #endif
29145
29146   ;
29147   return 0;
29148 }
29149 _ACEOF
29150 rm -f conftest.$ac_objext conftest$ac_exeext
29151 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29152   (eval $ac_link) 2>conftest.er1
29153   ac_status=$?
29154   grep -v '^ *+' conftest.er1 >conftest.err
29155   rm -f conftest.er1
29156   cat conftest.err >&5
29157   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29158   (exit $ac_status); } &&
29159          { ac_try='test -z "$ac_c_werror_flag"
29160                          || test ! -s conftest.err'
29161   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29162   (eval $ac_try) 2>&5
29163   ac_status=$?
29164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29165   (exit $ac_status); }; } &&
29166          { ac_try='test -s conftest$ac_exeext'
29167   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29168   (eval $ac_try) 2>&5
29169   ac_status=$?
29170   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29171   (exit $ac_status); }; }; then
29172   ol_cv_db_db42=yes
29173 else
29174   echo "$as_me: failed program was:" >&5
29175 sed 's/^/| /' conftest.$ac_ext >&5
29176
29177 ol_cv_db_db42=no
29178 fi
29179 rm -f conftest.err conftest.$ac_objext \
29180       conftest$ac_exeext conftest.$ac_ext
29181
29182         LIBS="$ol_LIBS"
29183
29184 fi
29185 echo "$as_me:$LINENO: result: $ol_cv_db_db42" >&5
29186 echo "${ECHO_T}$ol_cv_db_db42" >&6
29187
29188         if test $ol_cv_db_db42 = yes ; then
29189                 ol_cv_lib_db=-ldb42
29190         fi
29191 fi
29192
29193                 if test $ol_cv_lib_db = no ; then
29194         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-42)" >&5
29195 echo $ECHO_N "checking for Berkeley DB link (-ldb-42)... $ECHO_C" >&6
29196 if test "${ol_cv_db_db_42+set}" = set; then
29197   echo $ECHO_N "(cached) $ECHO_C" >&6
29198 else
29199
29200         ol_DB_LIB=-ldb-42
29201         ol_LIBS=$LIBS
29202         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29203
29204         cat >conftest.$ac_ext <<_ACEOF
29205 /* confdefs.h.  */
29206 _ACEOF
29207 cat confdefs.h >>conftest.$ac_ext
29208 cat >>conftest.$ac_ext <<_ACEOF
29209 /* end confdefs.h.  */
29210
29211 #ifdef HAVE_DB_185_H
29212 # include <db_185.h>
29213 #else
29214 # include <db.h>
29215 #endif
29216
29217 #ifndef DB_VERSION_MAJOR
29218 # define DB_VERSION_MAJOR 1
29219 #endif
29220
29221 #ifndef NULL
29222 #define NULL ((void*)0)
29223 #endif
29224
29225 int
29226 main ()
29227 {
29228
29229 #if DB_VERSION_MAJOR > 1
29230         {
29231                 char *version;
29232                 int major, minor, patch;
29233
29234                 version = db_version( &major, &minor, &patch );
29235
29236                 if( major != DB_VERSION_MAJOR ||
29237                         minor < DB_VERSION_MINOR )
29238                 {
29239                         printf("Berkeley DB version mismatch\n"
29240                                 "\theader: %s\n\tlibrary: %s\n",
29241                                 DB_VERSION_STRING, version);
29242                         return 1;
29243                 }
29244         }
29245 #endif
29246
29247 #if DB_VERSION_MAJOR > 2
29248         db_env_create( NULL, 0 );
29249 #elif DB_VERSION_MAJOR > 1
29250         db_appexit( NULL );
29251 #else
29252         (void) dbopen( NULL, 0, 0, 0, NULL);
29253 #endif
29254
29255   ;
29256   return 0;
29257 }
29258 _ACEOF
29259 rm -f conftest.$ac_objext conftest$ac_exeext
29260 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29261   (eval $ac_link) 2>conftest.er1
29262   ac_status=$?
29263   grep -v '^ *+' conftest.er1 >conftest.err
29264   rm -f conftest.er1
29265   cat conftest.err >&5
29266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29267   (exit $ac_status); } &&
29268          { ac_try='test -z "$ac_c_werror_flag"
29269                          || test ! -s conftest.err'
29270   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29271   (eval $ac_try) 2>&5
29272   ac_status=$?
29273   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29274   (exit $ac_status); }; } &&
29275          { ac_try='test -s conftest$ac_exeext'
29276   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29277   (eval $ac_try) 2>&5
29278   ac_status=$?
29279   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29280   (exit $ac_status); }; }; then
29281   ol_cv_db_db_42=yes
29282 else
29283   echo "$as_me: failed program was:" >&5
29284 sed 's/^/| /' conftest.$ac_ext >&5
29285
29286 ol_cv_db_db_42=no
29287 fi
29288 rm -f conftest.err conftest.$ac_objext \
29289       conftest$ac_exeext conftest.$ac_ext
29290
29291         LIBS="$ol_LIBS"
29292
29293 fi
29294 echo "$as_me:$LINENO: result: $ol_cv_db_db_42" >&5
29295 echo "${ECHO_T}$ol_cv_db_db_42" >&6
29296
29297         if test $ol_cv_db_db_42 = yes ; then
29298                 ol_cv_lib_db=-ldb-42
29299         fi
29300 fi
29301
29302                 if test $ol_cv_lib_db = no ; then
29303         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.2)" >&5
29304 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.2)... $ECHO_C" >&6
29305 if test "${ol_cv_db_db_4_dot_2+set}" = set; then
29306   echo $ECHO_N "(cached) $ECHO_C" >&6
29307 else
29308
29309         ol_DB_LIB=-ldb-4.2
29310         ol_LIBS=$LIBS
29311         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29312
29313         cat >conftest.$ac_ext <<_ACEOF
29314 /* confdefs.h.  */
29315 _ACEOF
29316 cat confdefs.h >>conftest.$ac_ext
29317 cat >>conftest.$ac_ext <<_ACEOF
29318 /* end confdefs.h.  */
29319
29320 #ifdef HAVE_DB_185_H
29321 # include <db_185.h>
29322 #else
29323 # include <db.h>
29324 #endif
29325
29326 #ifndef DB_VERSION_MAJOR
29327 # define DB_VERSION_MAJOR 1
29328 #endif
29329
29330 #ifndef NULL
29331 #define NULL ((void*)0)
29332 #endif
29333
29334 int
29335 main ()
29336 {
29337
29338 #if DB_VERSION_MAJOR > 1
29339         {
29340                 char *version;
29341                 int major, minor, patch;
29342
29343                 version = db_version( &major, &minor, &patch );
29344
29345                 if( major != DB_VERSION_MAJOR ||
29346                         minor < DB_VERSION_MINOR )
29347                 {
29348                         printf("Berkeley DB version mismatch\n"
29349                                 "\theader: %s\n\tlibrary: %s\n",
29350                                 DB_VERSION_STRING, version);
29351                         return 1;
29352                 }
29353         }
29354 #endif
29355
29356 #if DB_VERSION_MAJOR > 2
29357         db_env_create( NULL, 0 );
29358 #elif DB_VERSION_MAJOR > 1
29359         db_appexit( NULL );
29360 #else
29361         (void) dbopen( NULL, 0, 0, 0, NULL);
29362 #endif
29363
29364   ;
29365   return 0;
29366 }
29367 _ACEOF
29368 rm -f conftest.$ac_objext conftest$ac_exeext
29369 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29370   (eval $ac_link) 2>conftest.er1
29371   ac_status=$?
29372   grep -v '^ *+' conftest.er1 >conftest.err
29373   rm -f conftest.er1
29374   cat conftest.err >&5
29375   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29376   (exit $ac_status); } &&
29377          { ac_try='test -z "$ac_c_werror_flag"
29378                          || test ! -s conftest.err'
29379   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29380   (eval $ac_try) 2>&5
29381   ac_status=$?
29382   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29383   (exit $ac_status); }; } &&
29384          { ac_try='test -s conftest$ac_exeext'
29385   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29386   (eval $ac_try) 2>&5
29387   ac_status=$?
29388   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29389   (exit $ac_status); }; }; then
29390   ol_cv_db_db_4_dot_2=yes
29391 else
29392   echo "$as_me: failed program was:" >&5
29393 sed 's/^/| /' conftest.$ac_ext >&5
29394
29395 ol_cv_db_db_4_dot_2=no
29396 fi
29397 rm -f conftest.err conftest.$ac_objext \
29398       conftest$ac_exeext conftest.$ac_ext
29399
29400         LIBS="$ol_LIBS"
29401
29402 fi
29403 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_2" >&5
29404 echo "${ECHO_T}$ol_cv_db_db_4_dot_2" >&6
29405
29406         if test $ol_cv_db_db_4_dot_2 = yes ; then
29407                 ol_cv_lib_db=-ldb-4.2
29408         fi
29409 fi
29410
29411                 if test $ol_cv_lib_db = no ; then
29412         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-2)" >&5
29413 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-2)... $ECHO_C" >&6
29414 if test "${ol_cv_db_db_4_2+set}" = set; then
29415   echo $ECHO_N "(cached) $ECHO_C" >&6
29416 else
29417
29418         ol_DB_LIB=-ldb-4-2
29419         ol_LIBS=$LIBS
29420         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29421
29422         cat >conftest.$ac_ext <<_ACEOF
29423 /* confdefs.h.  */
29424 _ACEOF
29425 cat confdefs.h >>conftest.$ac_ext
29426 cat >>conftest.$ac_ext <<_ACEOF
29427 /* end confdefs.h.  */
29428
29429 #ifdef HAVE_DB_185_H
29430 # include <db_185.h>
29431 #else
29432 # include <db.h>
29433 #endif
29434
29435 #ifndef DB_VERSION_MAJOR
29436 # define DB_VERSION_MAJOR 1
29437 #endif
29438
29439 #ifndef NULL
29440 #define NULL ((void*)0)
29441 #endif
29442
29443 int
29444 main ()
29445 {
29446
29447 #if DB_VERSION_MAJOR > 1
29448         {
29449                 char *version;
29450                 int major, minor, patch;
29451
29452                 version = db_version( &major, &minor, &patch );
29453
29454                 if( major != DB_VERSION_MAJOR ||
29455                         minor < DB_VERSION_MINOR )
29456                 {
29457                         printf("Berkeley DB version mismatch\n"
29458                                 "\theader: %s\n\tlibrary: %s\n",
29459                                 DB_VERSION_STRING, version);
29460                         return 1;
29461                 }
29462         }
29463 #endif
29464
29465 #if DB_VERSION_MAJOR > 2
29466         db_env_create( NULL, 0 );
29467 #elif DB_VERSION_MAJOR > 1
29468         db_appexit( NULL );
29469 #else
29470         (void) dbopen( NULL, 0, 0, 0, NULL);
29471 #endif
29472
29473   ;
29474   return 0;
29475 }
29476 _ACEOF
29477 rm -f conftest.$ac_objext conftest$ac_exeext
29478 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29479   (eval $ac_link) 2>conftest.er1
29480   ac_status=$?
29481   grep -v '^ *+' conftest.er1 >conftest.err
29482   rm -f conftest.er1
29483   cat conftest.err >&5
29484   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29485   (exit $ac_status); } &&
29486          { ac_try='test -z "$ac_c_werror_flag"
29487                          || test ! -s conftest.err'
29488   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29489   (eval $ac_try) 2>&5
29490   ac_status=$?
29491   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29492   (exit $ac_status); }; } &&
29493          { ac_try='test -s conftest$ac_exeext'
29494   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29495   (eval $ac_try) 2>&5
29496   ac_status=$?
29497   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29498   (exit $ac_status); }; }; then
29499   ol_cv_db_db_4_2=yes
29500 else
29501   echo "$as_me: failed program was:" >&5
29502 sed 's/^/| /' conftest.$ac_ext >&5
29503
29504 ol_cv_db_db_4_2=no
29505 fi
29506 rm -f conftest.err conftest.$ac_objext \
29507       conftest$ac_exeext conftest.$ac_ext
29508
29509         LIBS="$ol_LIBS"
29510
29511 fi
29512 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_2" >&5
29513 echo "${ECHO_T}$ol_cv_db_db_4_2" >&6
29514
29515         if test $ol_cv_db_db_4_2 = yes ; then
29516                 ol_cv_lib_db=-ldb-4-2
29517         fi
29518 fi
29519
29520         elif test $ol_cv_bdb_minor = 1 ; then
29521                 if test $ol_cv_lib_db = no ; then
29522         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb41)" >&5
29523 echo $ECHO_N "checking for Berkeley DB link (-ldb41)... $ECHO_C" >&6
29524 if test "${ol_cv_db_db41+set}" = set; then
29525   echo $ECHO_N "(cached) $ECHO_C" >&6
29526 else
29527
29528         ol_DB_LIB=-ldb41
29529         ol_LIBS=$LIBS
29530         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29531
29532         cat >conftest.$ac_ext <<_ACEOF
29533 /* confdefs.h.  */
29534 _ACEOF
29535 cat confdefs.h >>conftest.$ac_ext
29536 cat >>conftest.$ac_ext <<_ACEOF
29537 /* end confdefs.h.  */
29538
29539 #ifdef HAVE_DB_185_H
29540 # include <db_185.h>
29541 #else
29542 # include <db.h>
29543 #endif
29544
29545 #ifndef DB_VERSION_MAJOR
29546 # define DB_VERSION_MAJOR 1
29547 #endif
29548
29549 #ifndef NULL
29550 #define NULL ((void*)0)
29551 #endif
29552
29553 int
29554 main ()
29555 {
29556
29557 #if DB_VERSION_MAJOR > 1
29558         {
29559                 char *version;
29560                 int major, minor, patch;
29561
29562                 version = db_version( &major, &minor, &patch );
29563
29564                 if( major != DB_VERSION_MAJOR ||
29565                         minor < DB_VERSION_MINOR )
29566                 {
29567                         printf("Berkeley DB version mismatch\n"
29568                                 "\theader: %s\n\tlibrary: %s\n",
29569                                 DB_VERSION_STRING, version);
29570                         return 1;
29571                 }
29572         }
29573 #endif
29574
29575 #if DB_VERSION_MAJOR > 2
29576         db_env_create( NULL, 0 );
29577 #elif DB_VERSION_MAJOR > 1
29578         db_appexit( NULL );
29579 #else
29580         (void) dbopen( NULL, 0, 0, 0, NULL);
29581 #endif
29582
29583   ;
29584   return 0;
29585 }
29586 _ACEOF
29587 rm -f conftest.$ac_objext conftest$ac_exeext
29588 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29589   (eval $ac_link) 2>conftest.er1
29590   ac_status=$?
29591   grep -v '^ *+' conftest.er1 >conftest.err
29592   rm -f conftest.er1
29593   cat conftest.err >&5
29594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29595   (exit $ac_status); } &&
29596          { ac_try='test -z "$ac_c_werror_flag"
29597                          || test ! -s conftest.err'
29598   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29599   (eval $ac_try) 2>&5
29600   ac_status=$?
29601   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29602   (exit $ac_status); }; } &&
29603          { ac_try='test -s conftest$ac_exeext'
29604   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29605   (eval $ac_try) 2>&5
29606   ac_status=$?
29607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29608   (exit $ac_status); }; }; then
29609   ol_cv_db_db41=yes
29610 else
29611   echo "$as_me: failed program was:" >&5
29612 sed 's/^/| /' conftest.$ac_ext >&5
29613
29614 ol_cv_db_db41=no
29615 fi
29616 rm -f conftest.err conftest.$ac_objext \
29617       conftest$ac_exeext conftest.$ac_ext
29618
29619         LIBS="$ol_LIBS"
29620
29621 fi
29622 echo "$as_me:$LINENO: result: $ol_cv_db_db41" >&5
29623 echo "${ECHO_T}$ol_cv_db_db41" >&6
29624
29625         if test $ol_cv_db_db41 = yes ; then
29626                 ol_cv_lib_db=-ldb41
29627         fi
29628 fi
29629
29630                 if test $ol_cv_lib_db = no ; then
29631         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-41)" >&5
29632 echo $ECHO_N "checking for Berkeley DB link (-ldb-41)... $ECHO_C" >&6
29633 if test "${ol_cv_db_db_41+set}" = set; then
29634   echo $ECHO_N "(cached) $ECHO_C" >&6
29635 else
29636
29637         ol_DB_LIB=-ldb-41
29638         ol_LIBS=$LIBS
29639         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29640
29641         cat >conftest.$ac_ext <<_ACEOF
29642 /* confdefs.h.  */
29643 _ACEOF
29644 cat confdefs.h >>conftest.$ac_ext
29645 cat >>conftest.$ac_ext <<_ACEOF
29646 /* end confdefs.h.  */
29647
29648 #ifdef HAVE_DB_185_H
29649 # include <db_185.h>
29650 #else
29651 # include <db.h>
29652 #endif
29653
29654 #ifndef DB_VERSION_MAJOR
29655 # define DB_VERSION_MAJOR 1
29656 #endif
29657
29658 #ifndef NULL
29659 #define NULL ((void*)0)
29660 #endif
29661
29662 int
29663 main ()
29664 {
29665
29666 #if DB_VERSION_MAJOR > 1
29667         {
29668                 char *version;
29669                 int major, minor, patch;
29670
29671                 version = db_version( &major, &minor, &patch );
29672
29673                 if( major != DB_VERSION_MAJOR ||
29674                         minor < DB_VERSION_MINOR )
29675                 {
29676                         printf("Berkeley DB version mismatch\n"
29677                                 "\theader: %s\n\tlibrary: %s\n",
29678                                 DB_VERSION_STRING, version);
29679                         return 1;
29680                 }
29681         }
29682 #endif
29683
29684 #if DB_VERSION_MAJOR > 2
29685         db_env_create( NULL, 0 );
29686 #elif DB_VERSION_MAJOR > 1
29687         db_appexit( NULL );
29688 #else
29689         (void) dbopen( NULL, 0, 0, 0, NULL);
29690 #endif
29691
29692   ;
29693   return 0;
29694 }
29695 _ACEOF
29696 rm -f conftest.$ac_objext conftest$ac_exeext
29697 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29698   (eval $ac_link) 2>conftest.er1
29699   ac_status=$?
29700   grep -v '^ *+' conftest.er1 >conftest.err
29701   rm -f conftest.er1
29702   cat conftest.err >&5
29703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29704   (exit $ac_status); } &&
29705          { ac_try='test -z "$ac_c_werror_flag"
29706                          || test ! -s conftest.err'
29707   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29708   (eval $ac_try) 2>&5
29709   ac_status=$?
29710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29711   (exit $ac_status); }; } &&
29712          { ac_try='test -s conftest$ac_exeext'
29713   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29714   (eval $ac_try) 2>&5
29715   ac_status=$?
29716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29717   (exit $ac_status); }; }; then
29718   ol_cv_db_db_41=yes
29719 else
29720   echo "$as_me: failed program was:" >&5
29721 sed 's/^/| /' conftest.$ac_ext >&5
29722
29723 ol_cv_db_db_41=no
29724 fi
29725 rm -f conftest.err conftest.$ac_objext \
29726       conftest$ac_exeext conftest.$ac_ext
29727
29728         LIBS="$ol_LIBS"
29729
29730 fi
29731 echo "$as_me:$LINENO: result: $ol_cv_db_db_41" >&5
29732 echo "${ECHO_T}$ol_cv_db_db_41" >&6
29733
29734         if test $ol_cv_db_db_41 = yes ; then
29735                 ol_cv_lib_db=-ldb-41
29736         fi
29737 fi
29738
29739                 if test $ol_cv_lib_db = no ; then
29740         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.1)" >&5
29741 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.1)... $ECHO_C" >&6
29742 if test "${ol_cv_db_db_4_dot_1+set}" = set; then
29743   echo $ECHO_N "(cached) $ECHO_C" >&6
29744 else
29745
29746         ol_DB_LIB=-ldb-4.1
29747         ol_LIBS=$LIBS
29748         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29749
29750         cat >conftest.$ac_ext <<_ACEOF
29751 /* confdefs.h.  */
29752 _ACEOF
29753 cat confdefs.h >>conftest.$ac_ext
29754 cat >>conftest.$ac_ext <<_ACEOF
29755 /* end confdefs.h.  */
29756
29757 #ifdef HAVE_DB_185_H
29758 # include <db_185.h>
29759 #else
29760 # include <db.h>
29761 #endif
29762
29763 #ifndef DB_VERSION_MAJOR
29764 # define DB_VERSION_MAJOR 1
29765 #endif
29766
29767 #ifndef NULL
29768 #define NULL ((void*)0)
29769 #endif
29770
29771 int
29772 main ()
29773 {
29774
29775 #if DB_VERSION_MAJOR > 1
29776         {
29777                 char *version;
29778                 int major, minor, patch;
29779
29780                 version = db_version( &major, &minor, &patch );
29781
29782                 if( major != DB_VERSION_MAJOR ||
29783                         minor < DB_VERSION_MINOR )
29784                 {
29785                         printf("Berkeley DB version mismatch\n"
29786                                 "\theader: %s\n\tlibrary: %s\n",
29787                                 DB_VERSION_STRING, version);
29788                         return 1;
29789                 }
29790         }
29791 #endif
29792
29793 #if DB_VERSION_MAJOR > 2
29794         db_env_create( NULL, 0 );
29795 #elif DB_VERSION_MAJOR > 1
29796         db_appexit( NULL );
29797 #else
29798         (void) dbopen( NULL, 0, 0, 0, NULL);
29799 #endif
29800
29801   ;
29802   return 0;
29803 }
29804 _ACEOF
29805 rm -f conftest.$ac_objext conftest$ac_exeext
29806 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29807   (eval $ac_link) 2>conftest.er1
29808   ac_status=$?
29809   grep -v '^ *+' conftest.er1 >conftest.err
29810   rm -f conftest.er1
29811   cat conftest.err >&5
29812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29813   (exit $ac_status); } &&
29814          { ac_try='test -z "$ac_c_werror_flag"
29815                          || test ! -s conftest.err'
29816   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29817   (eval $ac_try) 2>&5
29818   ac_status=$?
29819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29820   (exit $ac_status); }; } &&
29821          { ac_try='test -s conftest$ac_exeext'
29822   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29823   (eval $ac_try) 2>&5
29824   ac_status=$?
29825   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29826   (exit $ac_status); }; }; then
29827   ol_cv_db_db_4_dot_1=yes
29828 else
29829   echo "$as_me: failed program was:" >&5
29830 sed 's/^/| /' conftest.$ac_ext >&5
29831
29832 ol_cv_db_db_4_dot_1=no
29833 fi
29834 rm -f conftest.err conftest.$ac_objext \
29835       conftest$ac_exeext conftest.$ac_ext
29836
29837         LIBS="$ol_LIBS"
29838
29839 fi
29840 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_1" >&5
29841 echo "${ECHO_T}$ol_cv_db_db_4_dot_1" >&6
29842
29843         if test $ol_cv_db_db_4_dot_1 = yes ; then
29844                 ol_cv_lib_db=-ldb-4.1
29845         fi
29846 fi
29847
29848                 if test $ol_cv_lib_db = no ; then
29849         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-1)" >&5
29850 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-1)... $ECHO_C" >&6
29851 if test "${ol_cv_db_db_4_1+set}" = set; then
29852   echo $ECHO_N "(cached) $ECHO_C" >&6
29853 else
29854
29855         ol_DB_LIB=-ldb-4-1
29856         ol_LIBS=$LIBS
29857         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29858
29859         cat >conftest.$ac_ext <<_ACEOF
29860 /* confdefs.h.  */
29861 _ACEOF
29862 cat confdefs.h >>conftest.$ac_ext
29863 cat >>conftest.$ac_ext <<_ACEOF
29864 /* end confdefs.h.  */
29865
29866 #ifdef HAVE_DB_185_H
29867 # include <db_185.h>
29868 #else
29869 # include <db.h>
29870 #endif
29871
29872 #ifndef DB_VERSION_MAJOR
29873 # define DB_VERSION_MAJOR 1
29874 #endif
29875
29876 #ifndef NULL
29877 #define NULL ((void*)0)
29878 #endif
29879
29880 int
29881 main ()
29882 {
29883
29884 #if DB_VERSION_MAJOR > 1
29885         {
29886                 char *version;
29887                 int major, minor, patch;
29888
29889                 version = db_version( &major, &minor, &patch );
29890
29891                 if( major != DB_VERSION_MAJOR ||
29892                         minor < DB_VERSION_MINOR )
29893                 {
29894                         printf("Berkeley DB version mismatch\n"
29895                                 "\theader: %s\n\tlibrary: %s\n",
29896                                 DB_VERSION_STRING, version);
29897                         return 1;
29898                 }
29899         }
29900 #endif
29901
29902 #if DB_VERSION_MAJOR > 2
29903         db_env_create( NULL, 0 );
29904 #elif DB_VERSION_MAJOR > 1
29905         db_appexit( NULL );
29906 #else
29907         (void) dbopen( NULL, 0, 0, 0, NULL);
29908 #endif
29909
29910   ;
29911   return 0;
29912 }
29913 _ACEOF
29914 rm -f conftest.$ac_objext conftest$ac_exeext
29915 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29916   (eval $ac_link) 2>conftest.er1
29917   ac_status=$?
29918   grep -v '^ *+' conftest.er1 >conftest.err
29919   rm -f conftest.er1
29920   cat conftest.err >&5
29921   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29922   (exit $ac_status); } &&
29923          { ac_try='test -z "$ac_c_werror_flag"
29924                          || test ! -s conftest.err'
29925   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29926   (eval $ac_try) 2>&5
29927   ac_status=$?
29928   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29929   (exit $ac_status); }; } &&
29930          { ac_try='test -s conftest$ac_exeext'
29931   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29932   (eval $ac_try) 2>&5
29933   ac_status=$?
29934   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29935   (exit $ac_status); }; }; then
29936   ol_cv_db_db_4_1=yes
29937 else
29938   echo "$as_me: failed program was:" >&5
29939 sed 's/^/| /' conftest.$ac_ext >&5
29940
29941 ol_cv_db_db_4_1=no
29942 fi
29943 rm -f conftest.err conftest.$ac_objext \
29944       conftest$ac_exeext conftest.$ac_ext
29945
29946         LIBS="$ol_LIBS"
29947
29948 fi
29949 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_1" >&5
29950 echo "${ECHO_T}$ol_cv_db_db_4_1" >&6
29951
29952         if test $ol_cv_db_db_4_1 = yes ; then
29953                 ol_cv_lib_db=-ldb-4-1
29954         fi
29955 fi
29956
29957         fi
29958         if test $ol_cv_lib_db = no ; then
29959         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4)" >&5
29960 echo $ECHO_N "checking for Berkeley DB link (-ldb-4)... $ECHO_C" >&6
29961 if test "${ol_cv_db_db_4+set}" = set; then
29962   echo $ECHO_N "(cached) $ECHO_C" >&6
29963 else
29964
29965         ol_DB_LIB=-ldb-4
29966         ol_LIBS=$LIBS
29967         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29968
29969         cat >conftest.$ac_ext <<_ACEOF
29970 /* confdefs.h.  */
29971 _ACEOF
29972 cat confdefs.h >>conftest.$ac_ext
29973 cat >>conftest.$ac_ext <<_ACEOF
29974 /* end confdefs.h.  */
29975
29976 #ifdef HAVE_DB_185_H
29977 # include <db_185.h>
29978 #else
29979 # include <db.h>
29980 #endif
29981
29982 #ifndef DB_VERSION_MAJOR
29983 # define DB_VERSION_MAJOR 1
29984 #endif
29985
29986 #ifndef NULL
29987 #define NULL ((void*)0)
29988 #endif
29989
29990 int
29991 main ()
29992 {
29993
29994 #if DB_VERSION_MAJOR > 1
29995         {
29996                 char *version;
29997                 int major, minor, patch;
29998
29999                 version = db_version( &major, &minor, &patch );
30000
30001                 if( major != DB_VERSION_MAJOR ||
30002                         minor < DB_VERSION_MINOR )
30003                 {
30004                         printf("Berkeley DB version mismatch\n"
30005                                 "\theader: %s\n\tlibrary: %s\n",
30006                                 DB_VERSION_STRING, version);
30007                         return 1;
30008                 }
30009         }
30010 #endif
30011
30012 #if DB_VERSION_MAJOR > 2
30013         db_env_create( NULL, 0 );
30014 #elif DB_VERSION_MAJOR > 1
30015         db_appexit( NULL );
30016 #else
30017         (void) dbopen( NULL, 0, 0, 0, NULL);
30018 #endif
30019
30020   ;
30021   return 0;
30022 }
30023 _ACEOF
30024 rm -f conftest.$ac_objext conftest$ac_exeext
30025 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30026   (eval $ac_link) 2>conftest.er1
30027   ac_status=$?
30028   grep -v '^ *+' conftest.er1 >conftest.err
30029   rm -f conftest.er1
30030   cat conftest.err >&5
30031   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30032   (exit $ac_status); } &&
30033          { ac_try='test -z "$ac_c_werror_flag"
30034                          || test ! -s conftest.err'
30035   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30036   (eval $ac_try) 2>&5
30037   ac_status=$?
30038   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30039   (exit $ac_status); }; } &&
30040          { ac_try='test -s conftest$ac_exeext'
30041   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30042   (eval $ac_try) 2>&5
30043   ac_status=$?
30044   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30045   (exit $ac_status); }; }; then
30046   ol_cv_db_db_4=yes
30047 else
30048   echo "$as_me: failed program was:" >&5
30049 sed 's/^/| /' conftest.$ac_ext >&5
30050
30051 ol_cv_db_db_4=no
30052 fi
30053 rm -f conftest.err conftest.$ac_objext \
30054       conftest$ac_exeext conftest.$ac_ext
30055
30056         LIBS="$ol_LIBS"
30057
30058 fi
30059 echo "$as_me:$LINENO: result: $ol_cv_db_db_4" >&5
30060 echo "${ECHO_T}$ol_cv_db_db_4" >&6
30061
30062         if test $ol_cv_db_db_4 = yes ; then
30063                 ol_cv_lib_db=-ldb-4
30064         fi
30065 fi
30066
30067         if test $ol_cv_lib_db = no ; then
30068         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb4)" >&5
30069 echo $ECHO_N "checking for Berkeley DB link (-ldb4)... $ECHO_C" >&6
30070 if test "${ol_cv_db_db4+set}" = set; then
30071   echo $ECHO_N "(cached) $ECHO_C" >&6
30072 else
30073
30074         ol_DB_LIB=-ldb4
30075         ol_LIBS=$LIBS
30076         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30077
30078         cat >conftest.$ac_ext <<_ACEOF
30079 /* confdefs.h.  */
30080 _ACEOF
30081 cat confdefs.h >>conftest.$ac_ext
30082 cat >>conftest.$ac_ext <<_ACEOF
30083 /* end confdefs.h.  */
30084
30085 #ifdef HAVE_DB_185_H
30086 # include <db_185.h>
30087 #else
30088 # include <db.h>
30089 #endif
30090
30091 #ifndef DB_VERSION_MAJOR
30092 # define DB_VERSION_MAJOR 1
30093 #endif
30094
30095 #ifndef NULL
30096 #define NULL ((void*)0)
30097 #endif
30098
30099 int
30100 main ()
30101 {
30102
30103 #if DB_VERSION_MAJOR > 1
30104         {
30105                 char *version;
30106                 int major, minor, patch;
30107
30108                 version = db_version( &major, &minor, &patch );
30109
30110                 if( major != DB_VERSION_MAJOR ||
30111                         minor < DB_VERSION_MINOR )
30112                 {
30113                         printf("Berkeley DB version mismatch\n"
30114                                 "\theader: %s\n\tlibrary: %s\n",
30115                                 DB_VERSION_STRING, version);
30116                         return 1;
30117                 }
30118         }
30119 #endif
30120
30121 #if DB_VERSION_MAJOR > 2
30122         db_env_create( NULL, 0 );
30123 #elif DB_VERSION_MAJOR > 1
30124         db_appexit( NULL );
30125 #else
30126         (void) dbopen( NULL, 0, 0, 0, NULL);
30127 #endif
30128
30129   ;
30130   return 0;
30131 }
30132 _ACEOF
30133 rm -f conftest.$ac_objext conftest$ac_exeext
30134 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30135   (eval $ac_link) 2>conftest.er1
30136   ac_status=$?
30137   grep -v '^ *+' conftest.er1 >conftest.err
30138   rm -f conftest.er1
30139   cat conftest.err >&5
30140   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30141   (exit $ac_status); } &&
30142          { ac_try='test -z "$ac_c_werror_flag"
30143                          || test ! -s conftest.err'
30144   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30145   (eval $ac_try) 2>&5
30146   ac_status=$?
30147   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30148   (exit $ac_status); }; } &&
30149          { ac_try='test -s conftest$ac_exeext'
30150   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30151   (eval $ac_try) 2>&5
30152   ac_status=$?
30153   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30154   (exit $ac_status); }; }; then
30155   ol_cv_db_db4=yes
30156 else
30157   echo "$as_me: failed program was:" >&5
30158 sed 's/^/| /' conftest.$ac_ext >&5
30159
30160 ol_cv_db_db4=no
30161 fi
30162 rm -f conftest.err conftest.$ac_objext \
30163       conftest$ac_exeext conftest.$ac_ext
30164
30165         LIBS="$ol_LIBS"
30166
30167 fi
30168 echo "$as_me:$LINENO: result: $ol_cv_db_db4" >&5
30169 echo "${ECHO_T}$ol_cv_db_db4" >&6
30170
30171         if test $ol_cv_db_db4 = yes ; then
30172                 ol_cv_lib_db=-ldb4
30173         fi
30174 fi
30175
30176         if test $ol_cv_lib_db = no ; then
30177         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb)" >&5
30178 echo $ECHO_N "checking for Berkeley DB link (-ldb)... $ECHO_C" >&6
30179 if test "${ol_cv_db_db+set}" = set; then
30180   echo $ECHO_N "(cached) $ECHO_C" >&6
30181 else
30182
30183         ol_DB_LIB=-ldb
30184         ol_LIBS=$LIBS
30185         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30186
30187         cat >conftest.$ac_ext <<_ACEOF
30188 /* confdefs.h.  */
30189 _ACEOF
30190 cat confdefs.h >>conftest.$ac_ext
30191 cat >>conftest.$ac_ext <<_ACEOF
30192 /* end confdefs.h.  */
30193
30194 #ifdef HAVE_DB_185_H
30195 # include <db_185.h>
30196 #else
30197 # include <db.h>
30198 #endif
30199
30200 #ifndef DB_VERSION_MAJOR
30201 # define DB_VERSION_MAJOR 1
30202 #endif
30203
30204 #ifndef NULL
30205 #define NULL ((void*)0)
30206 #endif
30207
30208 int
30209 main ()
30210 {
30211
30212 #if DB_VERSION_MAJOR > 1
30213         {
30214                 char *version;
30215                 int major, minor, patch;
30216
30217                 version = db_version( &major, &minor, &patch );
30218
30219                 if( major != DB_VERSION_MAJOR ||
30220                         minor < DB_VERSION_MINOR )
30221                 {
30222                         printf("Berkeley DB version mismatch\n"
30223                                 "\theader: %s\n\tlibrary: %s\n",
30224                                 DB_VERSION_STRING, version);
30225                         return 1;
30226                 }
30227         }
30228 #endif
30229
30230 #if DB_VERSION_MAJOR > 2
30231         db_env_create( NULL, 0 );
30232 #elif DB_VERSION_MAJOR > 1
30233         db_appexit( NULL );
30234 #else
30235         (void) dbopen( NULL, 0, 0, 0, NULL);
30236 #endif
30237
30238   ;
30239   return 0;
30240 }
30241 _ACEOF
30242 rm -f conftest.$ac_objext conftest$ac_exeext
30243 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30244   (eval $ac_link) 2>conftest.er1
30245   ac_status=$?
30246   grep -v '^ *+' conftest.er1 >conftest.err
30247   rm -f conftest.er1
30248   cat conftest.err >&5
30249   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30250   (exit $ac_status); } &&
30251          { ac_try='test -z "$ac_c_werror_flag"
30252                          || test ! -s conftest.err'
30253   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30254   (eval $ac_try) 2>&5
30255   ac_status=$?
30256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30257   (exit $ac_status); }; } &&
30258          { ac_try='test -s conftest$ac_exeext'
30259   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30260   (eval $ac_try) 2>&5
30261   ac_status=$?
30262   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30263   (exit $ac_status); }; }; then
30264   ol_cv_db_db=yes
30265 else
30266   echo "$as_me: failed program was:" >&5
30267 sed 's/^/| /' conftest.$ac_ext >&5
30268
30269 ol_cv_db_db=no
30270 fi
30271 rm -f conftest.err conftest.$ac_objext \
30272       conftest$ac_exeext conftest.$ac_ext
30273
30274         LIBS="$ol_LIBS"
30275
30276 fi
30277 echo "$as_me:$LINENO: result: $ol_cv_db_db" >&5
30278 echo "${ECHO_T}$ol_cv_db_db" >&6
30279
30280         if test $ol_cv_db_db = yes ; then
30281                 ol_cv_lib_db=-ldb
30282         fi
30283 fi
30284
30285
30286 elif test $ol_cv_bdb_major = 3 ; then
30287         if test $ol_cv_lib_db = no ; then
30288         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb3)" >&5
30289 echo $ECHO_N "checking for Berkeley DB link (-ldb3)... $ECHO_C" >&6
30290 if test "${ol_cv_db_db3+set}" = set; then
30291   echo $ECHO_N "(cached) $ECHO_C" >&6
30292 else
30293
30294         ol_DB_LIB=-ldb3
30295         ol_LIBS=$LIBS
30296         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30297
30298         cat >conftest.$ac_ext <<_ACEOF
30299 /* confdefs.h.  */
30300 _ACEOF
30301 cat confdefs.h >>conftest.$ac_ext
30302 cat >>conftest.$ac_ext <<_ACEOF
30303 /* end confdefs.h.  */
30304
30305 #ifdef HAVE_DB_185_H
30306 # include <db_185.h>
30307 #else
30308 # include <db.h>
30309 #endif
30310
30311 #ifndef DB_VERSION_MAJOR
30312 # define DB_VERSION_MAJOR 1
30313 #endif
30314
30315 #ifndef NULL
30316 #define NULL ((void*)0)
30317 #endif
30318
30319 int
30320 main ()
30321 {
30322
30323 #if DB_VERSION_MAJOR > 1
30324         {
30325                 char *version;
30326                 int major, minor, patch;
30327
30328                 version = db_version( &major, &minor, &patch );
30329
30330                 if( major != DB_VERSION_MAJOR ||
30331                         minor < DB_VERSION_MINOR )
30332                 {
30333                         printf("Berkeley DB version mismatch\n"
30334                                 "\theader: %s\n\tlibrary: %s\n",
30335                                 DB_VERSION_STRING, version);
30336                         return 1;
30337                 }
30338         }
30339 #endif
30340
30341 #if DB_VERSION_MAJOR > 2
30342         db_env_create( NULL, 0 );
30343 #elif DB_VERSION_MAJOR > 1
30344         db_appexit( NULL );
30345 #else
30346         (void) dbopen( NULL, 0, 0, 0, NULL);
30347 #endif
30348
30349   ;
30350   return 0;
30351 }
30352 _ACEOF
30353 rm -f conftest.$ac_objext conftest$ac_exeext
30354 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30355   (eval $ac_link) 2>conftest.er1
30356   ac_status=$?
30357   grep -v '^ *+' conftest.er1 >conftest.err
30358   rm -f conftest.er1
30359   cat conftest.err >&5
30360   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30361   (exit $ac_status); } &&
30362          { ac_try='test -z "$ac_c_werror_flag"
30363                          || test ! -s conftest.err'
30364   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30365   (eval $ac_try) 2>&5
30366   ac_status=$?
30367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30368   (exit $ac_status); }; } &&
30369          { ac_try='test -s conftest$ac_exeext'
30370   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30371   (eval $ac_try) 2>&5
30372   ac_status=$?
30373   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30374   (exit $ac_status); }; }; then
30375   ol_cv_db_db3=yes
30376 else
30377   echo "$as_me: failed program was:" >&5
30378 sed 's/^/| /' conftest.$ac_ext >&5
30379
30380 ol_cv_db_db3=no
30381 fi
30382 rm -f conftest.err conftest.$ac_objext \
30383       conftest$ac_exeext conftest.$ac_ext
30384
30385         LIBS="$ol_LIBS"
30386
30387 fi
30388 echo "$as_me:$LINENO: result: $ol_cv_db_db3" >&5
30389 echo "${ECHO_T}$ol_cv_db_db3" >&6
30390
30391         if test $ol_cv_db_db3 = yes ; then
30392                 ol_cv_lib_db=-ldb3
30393         fi
30394 fi
30395
30396         if test $ol_cv_lib_db = no ; then
30397         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-3)" >&5
30398 echo $ECHO_N "checking for Berkeley DB link (-ldb-3)... $ECHO_C" >&6
30399 if test "${ol_cv_db_db_3+set}" = set; then
30400   echo $ECHO_N "(cached) $ECHO_C" >&6
30401 else
30402
30403         ol_DB_LIB=-ldb-3
30404         ol_LIBS=$LIBS
30405         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30406
30407         cat >conftest.$ac_ext <<_ACEOF
30408 /* confdefs.h.  */
30409 _ACEOF
30410 cat confdefs.h >>conftest.$ac_ext
30411 cat >>conftest.$ac_ext <<_ACEOF
30412 /* end confdefs.h.  */
30413
30414 #ifdef HAVE_DB_185_H
30415 # include <db_185.h>
30416 #else
30417 # include <db.h>
30418 #endif
30419
30420 #ifndef DB_VERSION_MAJOR
30421 # define DB_VERSION_MAJOR 1
30422 #endif
30423
30424 #ifndef NULL
30425 #define NULL ((void*)0)
30426 #endif
30427
30428 int
30429 main ()
30430 {
30431
30432 #if DB_VERSION_MAJOR > 1
30433         {
30434                 char *version;
30435                 int major, minor, patch;
30436
30437                 version = db_version( &major, &minor, &patch );
30438
30439                 if( major != DB_VERSION_MAJOR ||
30440                         minor < DB_VERSION_MINOR )
30441                 {
30442                         printf("Berkeley DB version mismatch\n"
30443                                 "\theader: %s\n\tlibrary: %s\n",
30444                                 DB_VERSION_STRING, version);
30445                         return 1;
30446                 }
30447         }
30448 #endif
30449
30450 #if DB_VERSION_MAJOR > 2
30451         db_env_create( NULL, 0 );
30452 #elif DB_VERSION_MAJOR > 1
30453         db_appexit( NULL );
30454 #else
30455         (void) dbopen( NULL, 0, 0, 0, NULL);
30456 #endif
30457
30458   ;
30459   return 0;
30460 }
30461 _ACEOF
30462 rm -f conftest.$ac_objext conftest$ac_exeext
30463 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30464   (eval $ac_link) 2>conftest.er1
30465   ac_status=$?
30466   grep -v '^ *+' conftest.er1 >conftest.err
30467   rm -f conftest.er1
30468   cat conftest.err >&5
30469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30470   (exit $ac_status); } &&
30471          { ac_try='test -z "$ac_c_werror_flag"
30472                          || test ! -s conftest.err'
30473   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30474   (eval $ac_try) 2>&5
30475   ac_status=$?
30476   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30477   (exit $ac_status); }; } &&
30478          { ac_try='test -s conftest$ac_exeext'
30479   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30480   (eval $ac_try) 2>&5
30481   ac_status=$?
30482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30483   (exit $ac_status); }; }; then
30484   ol_cv_db_db_3=yes
30485 else
30486   echo "$as_me: failed program was:" >&5
30487 sed 's/^/| /' conftest.$ac_ext >&5
30488
30489 ol_cv_db_db_3=no
30490 fi
30491 rm -f conftest.err conftest.$ac_objext \
30492       conftest$ac_exeext conftest.$ac_ext
30493
30494         LIBS="$ol_LIBS"
30495
30496 fi
30497 echo "$as_me:$LINENO: result: $ol_cv_db_db_3" >&5
30498 echo "${ECHO_T}$ol_cv_db_db_3" >&6
30499
30500         if test $ol_cv_db_db_3 = yes ; then
30501                 ol_cv_lib_db=-ldb-3
30502         fi
30503 fi
30504
30505
30506 elif test $ol_cv_bdb_major = 2 ; then
30507         if test $ol_cv_lib_db = no ; then
30508         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb2)" >&5
30509 echo $ECHO_N "checking for Berkeley DB link (-ldb2)... $ECHO_C" >&6
30510 if test "${ol_cv_db_db2+set}" = set; then
30511   echo $ECHO_N "(cached) $ECHO_C" >&6
30512 else
30513
30514         ol_DB_LIB=-ldb2
30515         ol_LIBS=$LIBS
30516         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30517
30518         cat >conftest.$ac_ext <<_ACEOF
30519 /* confdefs.h.  */
30520 _ACEOF
30521 cat confdefs.h >>conftest.$ac_ext
30522 cat >>conftest.$ac_ext <<_ACEOF
30523 /* end confdefs.h.  */
30524
30525 #ifdef HAVE_DB_185_H
30526 # include <db_185.h>
30527 #else
30528 # include <db.h>
30529 #endif
30530
30531 #ifndef DB_VERSION_MAJOR
30532 # define DB_VERSION_MAJOR 1
30533 #endif
30534
30535 #ifndef NULL
30536 #define NULL ((void*)0)
30537 #endif
30538
30539 int
30540 main ()
30541 {
30542
30543 #if DB_VERSION_MAJOR > 1
30544         {
30545                 char *version;
30546                 int major, minor, patch;
30547
30548                 version = db_version( &major, &minor, &patch );
30549
30550                 if( major != DB_VERSION_MAJOR ||
30551                         minor < DB_VERSION_MINOR )
30552                 {
30553                         printf("Berkeley DB version mismatch\n"
30554                                 "\theader: %s\n\tlibrary: %s\n",
30555                                 DB_VERSION_STRING, version);
30556                         return 1;
30557                 }
30558         }
30559 #endif
30560
30561 #if DB_VERSION_MAJOR > 2
30562         db_env_create( NULL, 0 );
30563 #elif DB_VERSION_MAJOR > 1
30564         db_appexit( NULL );
30565 #else
30566         (void) dbopen( NULL, 0, 0, 0, NULL);
30567 #endif
30568
30569   ;
30570   return 0;
30571 }
30572 _ACEOF
30573 rm -f conftest.$ac_objext conftest$ac_exeext
30574 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30575   (eval $ac_link) 2>conftest.er1
30576   ac_status=$?
30577   grep -v '^ *+' conftest.er1 >conftest.err
30578   rm -f conftest.er1
30579   cat conftest.err >&5
30580   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30581   (exit $ac_status); } &&
30582          { ac_try='test -z "$ac_c_werror_flag"
30583                          || test ! -s conftest.err'
30584   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30585   (eval $ac_try) 2>&5
30586   ac_status=$?
30587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30588   (exit $ac_status); }; } &&
30589          { ac_try='test -s conftest$ac_exeext'
30590   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30591   (eval $ac_try) 2>&5
30592   ac_status=$?
30593   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30594   (exit $ac_status); }; }; then
30595   ol_cv_db_db2=yes
30596 else
30597   echo "$as_me: failed program was:" >&5
30598 sed 's/^/| /' conftest.$ac_ext >&5
30599
30600 ol_cv_db_db2=no
30601 fi
30602 rm -f conftest.err conftest.$ac_objext \
30603       conftest$ac_exeext conftest.$ac_ext
30604
30605         LIBS="$ol_LIBS"
30606
30607 fi
30608 echo "$as_me:$LINENO: result: $ol_cv_db_db2" >&5
30609 echo "${ECHO_T}$ol_cv_db_db2" >&6
30610
30611         if test $ol_cv_db_db2 = yes ; then
30612                 ol_cv_lib_db=-ldb2
30613         fi
30614 fi
30615
30616         if test $ol_cv_lib_db = no ; then
30617         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-2)" >&5
30618 echo $ECHO_N "checking for Berkeley DB link (-ldb-2)... $ECHO_C" >&6
30619 if test "${ol_cv_db_db_2+set}" = set; then
30620   echo $ECHO_N "(cached) $ECHO_C" >&6
30621 else
30622
30623         ol_DB_LIB=-ldb-2
30624         ol_LIBS=$LIBS
30625         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30626
30627         cat >conftest.$ac_ext <<_ACEOF
30628 /* confdefs.h.  */
30629 _ACEOF
30630 cat confdefs.h >>conftest.$ac_ext
30631 cat >>conftest.$ac_ext <<_ACEOF
30632 /* end confdefs.h.  */
30633
30634 #ifdef HAVE_DB_185_H
30635 # include <db_185.h>
30636 #else
30637 # include <db.h>
30638 #endif
30639
30640 #ifndef DB_VERSION_MAJOR
30641 # define DB_VERSION_MAJOR 1
30642 #endif
30643
30644 #ifndef NULL
30645 #define NULL ((void*)0)
30646 #endif
30647
30648 int
30649 main ()
30650 {
30651
30652 #if DB_VERSION_MAJOR > 1
30653         {
30654                 char *version;
30655                 int major, minor, patch;
30656
30657                 version = db_version( &major, &minor, &patch );
30658
30659                 if( major != DB_VERSION_MAJOR ||
30660                         minor < DB_VERSION_MINOR )
30661                 {
30662                         printf("Berkeley DB version mismatch\n"
30663                                 "\theader: %s\n\tlibrary: %s\n",
30664                                 DB_VERSION_STRING, version);
30665                         return 1;
30666                 }
30667         }
30668 #endif
30669
30670 #if DB_VERSION_MAJOR > 2
30671         db_env_create( NULL, 0 );
30672 #elif DB_VERSION_MAJOR > 1
30673         db_appexit( NULL );
30674 #else
30675         (void) dbopen( NULL, 0, 0, 0, NULL);
30676 #endif
30677
30678   ;
30679   return 0;
30680 }
30681 _ACEOF
30682 rm -f conftest.$ac_objext conftest$ac_exeext
30683 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30684   (eval $ac_link) 2>conftest.er1
30685   ac_status=$?
30686   grep -v '^ *+' conftest.er1 >conftest.err
30687   rm -f conftest.er1
30688   cat conftest.err >&5
30689   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30690   (exit $ac_status); } &&
30691          { ac_try='test -z "$ac_c_werror_flag"
30692                          || test ! -s conftest.err'
30693   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30694   (eval $ac_try) 2>&5
30695   ac_status=$?
30696   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30697   (exit $ac_status); }; } &&
30698          { ac_try='test -s conftest$ac_exeext'
30699   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30700   (eval $ac_try) 2>&5
30701   ac_status=$?
30702   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30703   (exit $ac_status); }; }; then
30704   ol_cv_db_db_2=yes
30705 else
30706   echo "$as_me: failed program was:" >&5
30707 sed 's/^/| /' conftest.$ac_ext >&5
30708
30709 ol_cv_db_db_2=no
30710 fi
30711 rm -f conftest.err conftest.$ac_objext \
30712       conftest$ac_exeext conftest.$ac_ext
30713
30714         LIBS="$ol_LIBS"
30715
30716 fi
30717 echo "$as_me:$LINENO: result: $ol_cv_db_db_2" >&5
30718 echo "${ECHO_T}$ol_cv_db_db_2" >&6
30719
30720         if test $ol_cv_db_db_2 = yes ; then
30721                 ol_cv_lib_db=-ldb-2
30722         fi
30723 fi
30724
30725
30726 elif test $ol_cv_bdb_major = 1 ; then
30727         if test $ol_cv_lib_db = no ; then
30728         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb1)" >&5
30729 echo $ECHO_N "checking for Berkeley DB link (-ldb1)... $ECHO_C" >&6
30730 if test "${ol_cv_db_db1+set}" = set; then
30731   echo $ECHO_N "(cached) $ECHO_C" >&6
30732 else
30733
30734         ol_DB_LIB=-ldb1
30735         ol_LIBS=$LIBS
30736         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30737
30738         cat >conftest.$ac_ext <<_ACEOF
30739 /* confdefs.h.  */
30740 _ACEOF
30741 cat confdefs.h >>conftest.$ac_ext
30742 cat >>conftest.$ac_ext <<_ACEOF
30743 /* end confdefs.h.  */
30744
30745 #ifdef HAVE_DB_185_H
30746 # include <db_185.h>
30747 #else
30748 # include <db.h>
30749 #endif
30750
30751 #ifndef DB_VERSION_MAJOR
30752 # define DB_VERSION_MAJOR 1
30753 #endif
30754
30755 #ifndef NULL
30756 #define NULL ((void*)0)
30757 #endif
30758
30759 int
30760 main ()
30761 {
30762
30763 #if DB_VERSION_MAJOR > 1
30764         {
30765                 char *version;
30766                 int major, minor, patch;
30767
30768                 version = db_version( &major, &minor, &patch );
30769
30770                 if( major != DB_VERSION_MAJOR ||
30771                         minor < DB_VERSION_MINOR )
30772                 {
30773                         printf("Berkeley DB version mismatch\n"
30774                                 "\theader: %s\n\tlibrary: %s\n",
30775                                 DB_VERSION_STRING, version);
30776                         return 1;
30777                 }
30778         }
30779 #endif
30780
30781 #if DB_VERSION_MAJOR > 2
30782         db_env_create( NULL, 0 );
30783 #elif DB_VERSION_MAJOR > 1
30784         db_appexit( NULL );
30785 #else
30786         (void) dbopen( NULL, 0, 0, 0, NULL);
30787 #endif
30788
30789   ;
30790   return 0;
30791 }
30792 _ACEOF
30793 rm -f conftest.$ac_objext conftest$ac_exeext
30794 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30795   (eval $ac_link) 2>conftest.er1
30796   ac_status=$?
30797   grep -v '^ *+' conftest.er1 >conftest.err
30798   rm -f conftest.er1
30799   cat conftest.err >&5
30800   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30801   (exit $ac_status); } &&
30802          { ac_try='test -z "$ac_c_werror_flag"
30803                          || test ! -s conftest.err'
30804   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30805   (eval $ac_try) 2>&5
30806   ac_status=$?
30807   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30808   (exit $ac_status); }; } &&
30809          { ac_try='test -s conftest$ac_exeext'
30810   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30811   (eval $ac_try) 2>&5
30812   ac_status=$?
30813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30814   (exit $ac_status); }; }; then
30815   ol_cv_db_db1=yes
30816 else
30817   echo "$as_me: failed program was:" >&5
30818 sed 's/^/| /' conftest.$ac_ext >&5
30819
30820 ol_cv_db_db1=no
30821 fi
30822 rm -f conftest.err conftest.$ac_objext \
30823       conftest$ac_exeext conftest.$ac_ext
30824
30825         LIBS="$ol_LIBS"
30826
30827 fi
30828 echo "$as_me:$LINENO: result: $ol_cv_db_db1" >&5
30829 echo "${ECHO_T}$ol_cv_db_db1" >&6
30830
30831         if test $ol_cv_db_db1 = yes ; then
30832                 ol_cv_lib_db=-ldb1
30833         fi
30834 fi
30835
30836         if test $ol_cv_lib_db = no ; then
30837         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-1)" >&5
30838 echo $ECHO_N "checking for Berkeley DB link (-ldb-1)... $ECHO_C" >&6
30839 if test "${ol_cv_db_db_1+set}" = set; then
30840   echo $ECHO_N "(cached) $ECHO_C" >&6
30841 else
30842
30843         ol_DB_LIB=-ldb-1
30844         ol_LIBS=$LIBS
30845         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30846
30847         cat >conftest.$ac_ext <<_ACEOF
30848 /* confdefs.h.  */
30849 _ACEOF
30850 cat confdefs.h >>conftest.$ac_ext
30851 cat >>conftest.$ac_ext <<_ACEOF
30852 /* end confdefs.h.  */
30853
30854 #ifdef HAVE_DB_185_H
30855 # include <db_185.h>
30856 #else
30857 # include <db.h>
30858 #endif
30859
30860 #ifndef DB_VERSION_MAJOR
30861 # define DB_VERSION_MAJOR 1
30862 #endif
30863
30864 #ifndef NULL
30865 #define NULL ((void*)0)
30866 #endif
30867
30868 int
30869 main ()
30870 {
30871
30872 #if DB_VERSION_MAJOR > 1
30873         {
30874                 char *version;
30875                 int major, minor, patch;
30876
30877                 version = db_version( &major, &minor, &patch );
30878
30879                 if( major != DB_VERSION_MAJOR ||
30880                         minor < DB_VERSION_MINOR )
30881                 {
30882                         printf("Berkeley DB version mismatch\n"
30883                                 "\theader: %s\n\tlibrary: %s\n",
30884                                 DB_VERSION_STRING, version);
30885                         return 1;
30886                 }
30887         }
30888 #endif
30889
30890 #if DB_VERSION_MAJOR > 2
30891         db_env_create( NULL, 0 );
30892 #elif DB_VERSION_MAJOR > 1
30893         db_appexit( NULL );
30894 #else
30895         (void) dbopen( NULL, 0, 0, 0, NULL);
30896 #endif
30897
30898   ;
30899   return 0;
30900 }
30901 _ACEOF
30902 rm -f conftest.$ac_objext conftest$ac_exeext
30903 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30904   (eval $ac_link) 2>conftest.er1
30905   ac_status=$?
30906   grep -v '^ *+' conftest.er1 >conftest.err
30907   rm -f conftest.er1
30908   cat conftest.err >&5
30909   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30910   (exit $ac_status); } &&
30911          { ac_try='test -z "$ac_c_werror_flag"
30912                          || test ! -s conftest.err'
30913   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30914   (eval $ac_try) 2>&5
30915   ac_status=$?
30916   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30917   (exit $ac_status); }; } &&
30918          { ac_try='test -s conftest$ac_exeext'
30919   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30920   (eval $ac_try) 2>&5
30921   ac_status=$?
30922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30923   (exit $ac_status); }; }; then
30924   ol_cv_db_db_1=yes
30925 else
30926   echo "$as_me: failed program was:" >&5
30927 sed 's/^/| /' conftest.$ac_ext >&5
30928
30929 ol_cv_db_db_1=no
30930 fi
30931 rm -f conftest.err conftest.$ac_objext \
30932       conftest$ac_exeext conftest.$ac_ext
30933
30934         LIBS="$ol_LIBS"
30935
30936 fi
30937 echo "$as_me:$LINENO: result: $ol_cv_db_db_1" >&5
30938 echo "${ECHO_T}$ol_cv_db_db_1" >&6
30939
30940         if test $ol_cv_db_db_1 = yes ; then
30941                 ol_cv_lib_db=-ldb-1
30942         fi
30943 fi
30944
30945 fi
30946 if test $ol_cv_lib_db = no ; then
30947         echo "$as_me:$LINENO: checking for Berkeley DB link (default)" >&5
30948 echo $ECHO_N "checking for Berkeley DB link (default)... $ECHO_C" >&6
30949 if test "${ol_cv_db_none+set}" = set; then
30950   echo $ECHO_N "(cached) $ECHO_C" >&6
30951 else
30952
30953         ol_DB_LIB=
30954         ol_LIBS=$LIBS
30955         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30956
30957         cat >conftest.$ac_ext <<_ACEOF
30958 /* confdefs.h.  */
30959 _ACEOF
30960 cat confdefs.h >>conftest.$ac_ext
30961 cat >>conftest.$ac_ext <<_ACEOF
30962 /* end confdefs.h.  */
30963
30964 #ifdef HAVE_DB_185_H
30965 # include <db_185.h>
30966 #else
30967 # include <db.h>
30968 #endif
30969
30970 #ifndef DB_VERSION_MAJOR
30971 # define DB_VERSION_MAJOR 1
30972 #endif
30973
30974 #ifndef NULL
30975 #define NULL ((void*)0)
30976 #endif
30977
30978 int
30979 main ()
30980 {
30981
30982 #if DB_VERSION_MAJOR > 1
30983         {
30984                 char *version;
30985                 int major, minor, patch;
30986
30987                 version = db_version( &major, &minor, &patch );
30988
30989                 if( major != DB_VERSION_MAJOR ||
30990                         minor < DB_VERSION_MINOR )
30991                 {
30992                         printf("Berkeley DB version mismatch\n"
30993                                 "\theader: %s\n\tlibrary: %s\n",
30994                                 DB_VERSION_STRING, version);
30995                         return 1;
30996                 }
30997         }
30998 #endif
30999
31000 #if DB_VERSION_MAJOR > 2
31001         db_env_create( NULL, 0 );
31002 #elif DB_VERSION_MAJOR > 1
31003         db_appexit( NULL );
31004 #else
31005         (void) dbopen( NULL, 0, 0, 0, NULL);
31006 #endif
31007
31008   ;
31009   return 0;
31010 }
31011 _ACEOF
31012 rm -f conftest.$ac_objext conftest$ac_exeext
31013 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31014   (eval $ac_link) 2>conftest.er1
31015   ac_status=$?
31016   grep -v '^ *+' conftest.er1 >conftest.err
31017   rm -f conftest.er1
31018   cat conftest.err >&5
31019   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31020   (exit $ac_status); } &&
31021          { ac_try='test -z "$ac_c_werror_flag"
31022                          || test ! -s conftest.err'
31023   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31024   (eval $ac_try) 2>&5
31025   ac_status=$?
31026   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31027   (exit $ac_status); }; } &&
31028          { ac_try='test -s conftest$ac_exeext'
31029   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31030   (eval $ac_try) 2>&5
31031   ac_status=$?
31032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31033   (exit $ac_status); }; }; then
31034   ol_cv_db_none=yes
31035 else
31036   echo "$as_me: failed program was:" >&5
31037 sed 's/^/| /' conftest.$ac_ext >&5
31038
31039 ol_cv_db_none=no
31040 fi
31041 rm -f conftest.err conftest.$ac_objext \
31042       conftest$ac_exeext conftest.$ac_ext
31043
31044         LIBS="$ol_LIBS"
31045
31046 fi
31047 echo "$as_me:$LINENO: result: $ol_cv_db_none" >&5
31048 echo "${ECHO_T}$ol_cv_db_none" >&6
31049
31050         if test $ol_cv_db_none = yes ; then
31051                 ol_cv_lib_db=yes
31052         fi
31053 fi
31054
31055
31056         if test "$ol_cv_lib_db" != no ; then
31057                 ol_cv_berkeley_db=yes
31058                 echo "$as_me:$LINENO: checking for Berkeley DB version match" >&5
31059 echo $ECHO_N "checking for Berkeley DB version match... $ECHO_C" >&6
31060 if test "${ol_cv_berkeley_db_version+set}" = set; then
31061   echo $ECHO_N "(cached) $ECHO_C" >&6
31062 else
31063
31064         ol_LIBS="$LIBS"
31065         LIBS="$LTHREAD_LIBS $LIBS"
31066         if test $ol_cv_lib_db != yes ; then
31067                 LIBS="$ol_cv_lib_db $LIBS"
31068         fi
31069
31070         if test "$cross_compiling" = yes; then
31071   ol_cv_berkeley_db_version=cross
31072 else
31073   cat >conftest.$ac_ext <<_ACEOF
31074 /* confdefs.h.  */
31075 _ACEOF
31076 cat confdefs.h >>conftest.$ac_ext
31077 cat >>conftest.$ac_ext <<_ACEOF
31078 /* end confdefs.h.  */
31079
31080 #ifdef HAVE_DB_185_H
31081         choke me;
31082 #else
31083 #include <db.h>
31084 #endif
31085 #ifndef DB_VERSION_MAJOR
31086 # define DB_VERSION_MAJOR 1
31087 #endif
31088 #ifndef NULL
31089 #define NULL ((void *)0)
31090 #endif
31091 main()
31092 {
31093 #if DB_VERSION_MAJOR > 1
31094         char *version;
31095         int major, minor, patch;
31096
31097         version = db_version( &major, &minor, &patch );
31098
31099         if( major != DB_VERSION_MAJOR ||
31100                 minor != DB_VERSION_MINOR ||
31101                 patch != DB_VERSION_PATCH )
31102         {
31103                 printf("Berkeley DB version mismatch\n"
31104                         "\theader: %s\n\tlibrary: %s\n",
31105                         DB_VERSION_STRING, version);
31106                 return 1;
31107         }
31108 #endif
31109
31110         return 0;
31111 }
31112 _ACEOF
31113 rm -f conftest$ac_exeext
31114 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31115   (eval $ac_link) 2>&5
31116   ac_status=$?
31117   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31118   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
31119   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31120   (eval $ac_try) 2>&5
31121   ac_status=$?
31122   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31123   (exit $ac_status); }; }; then
31124   ol_cv_berkeley_db_version=yes
31125 else
31126   echo "$as_me: program exited with status $ac_status" >&5
31127 echo "$as_me: failed program was:" >&5
31128 sed 's/^/| /' conftest.$ac_ext >&5
31129
31130 ( exit $ac_status )
31131 ol_cv_berkeley_db_version=no
31132 fi
31133 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
31134 fi
31135
31136         LIBS="$ol_LIBS"
31137
31138 fi
31139 echo "$as_me:$LINENO: result: $ol_cv_berkeley_db_version" >&5
31140 echo "${ECHO_T}$ol_cv_berkeley_db_version" >&6
31141
31142         if test $ol_cv_berkeley_db_version = no ; then
31143                 { { echo "$as_me:$LINENO: error: Berkeley DB version mismatch" >&5
31144 echo "$as_me: error: Berkeley DB version mismatch" >&2;}
31145    { (exit 1); exit 1; }; }
31146         fi
31147
31148                 echo "$as_me:$LINENO: checking for Berkeley DB thread support" >&5
31149 echo $ECHO_N "checking for Berkeley DB thread support... $ECHO_C" >&6
31150 if test "${ol_cv_berkeley_db_thread+set}" = set; then
31151   echo $ECHO_N "(cached) $ECHO_C" >&6
31152 else
31153
31154         ol_LIBS="$LIBS"
31155         LIBS="$LTHREAD_LIBS $LIBS"
31156         if test $ol_cv_lib_db != yes ; then
31157                 LIBS="$ol_cv_lib_db $LIBS"
31158         fi
31159
31160         if test "$cross_compiling" = yes; then
31161   ol_cv_berkeley_db_thread=cross
31162 else
31163   cat >conftest.$ac_ext <<_ACEOF
31164 /* confdefs.h.  */
31165 _ACEOF
31166 cat confdefs.h >>conftest.$ac_ext
31167 cat >>conftest.$ac_ext <<_ACEOF
31168 /* end confdefs.h.  */
31169
31170 #ifdef HAVE_DB_185_H
31171         choke me;
31172 #else
31173 #include <db.h>
31174 #endif
31175 #ifndef NULL
31176 #define NULL ((void *)0)
31177 #endif
31178 main()
31179 {
31180         int rc;
31181         u_int32_t flags = DB_CREATE |
31182 #ifdef DB_PRIVATE
31183                 DB_PRIVATE |
31184 #endif
31185                 DB_THREAD;
31186
31187 #if DB_VERSION_MAJOR > 2
31188         DB_ENV *env = NULL;
31189
31190         rc = db_env_create( &env, 0 );
31191
31192         flags |= DB_INIT_MPOOL;
31193 #ifdef DB_MPOOL_PRIVATE
31194         flags |= DB_MPOOL_PRIVATE;
31195 #endif
31196
31197         if( rc ) {
31198                 printf("BerkeleyDB: %s\n", db_strerror(rc) );
31199                 return rc;
31200         }
31201
31202 #if (DB_VERSION_MAJOR > 3) || (DB_VERSION_MINOR >= 1)
31203         rc = env->open( env, NULL, flags, 0 );
31204 #else
31205         rc = env->open( env, NULL, NULL, flags, 0 );
31206 #endif
31207
31208         if ( rc == 0 ) {
31209                 rc = env->close( env, 0 );
31210         }
31211
31212         if( rc ) {
31213                 printf("BerkeleyDB: %s\n", db_strerror(rc) );
31214                 return rc;
31215         }
31216
31217 #else
31218         DB_ENV env;
31219         memset( &env, '\0', sizeof(env) );
31220
31221         rc = db_appinit( NULL, NULL, &env, flags );
31222
31223         if( rc == 0 ) {
31224                 db_appexit( &env );
31225         }
31226
31227         unlink("__db_mpool.share");
31228         unlink("__db_lock.share");
31229 #endif
31230
31231         return rc;
31232 }
31233 _ACEOF
31234 rm -f conftest$ac_exeext
31235 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31236   (eval $ac_link) 2>&5
31237   ac_status=$?
31238   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31239   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
31240   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31241   (eval $ac_try) 2>&5
31242   ac_status=$?
31243   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31244   (exit $ac_status); }; }; then
31245   ol_cv_berkeley_db_thread=yes
31246 else
31247   echo "$as_me: program exited with status $ac_status" >&5
31248 echo "$as_me: failed program was:" >&5
31249 sed 's/^/| /' conftest.$ac_ext >&5
31250
31251 ( exit $ac_status )
31252 ol_cv_berkeley_db_thread=no
31253 fi
31254 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
31255 fi
31256
31257         LIBS="$ol_LIBS"
31258
31259 fi
31260 echo "$as_me:$LINENO: result: $ol_cv_berkeley_db_thread" >&5
31261 echo "${ECHO_T}$ol_cv_berkeley_db_thread" >&6
31262
31263         if test $ol_cv_berkeley_db_thread != no ; then
31264
31265 cat >>confdefs.h <<\_ACEOF
31266 #define HAVE_BERKELEY_DB_THREAD 1
31267 _ACEOF
31268
31269         fi
31270
31271         fi
31272 fi
31273
31274
31275         if test $ol_cv_berkeley_db = no ; then
31276                 { { echo "$as_me:$LINENO: error: BDB/HDB: BerkeleyDB not available" >&5
31277 echo "$as_me: error: BDB/HDB: BerkeleyDB not available" >&2;}
31278    { (exit 1); exit 1; }; }
31279         fi
31280
31281
31282 cat >>confdefs.h <<\_ACEOF
31283 #define HAVE_BERKELEY_DB 1
31284 _ACEOF
31285
31286
31287                         if test $ol_cv_lib_db != yes ; then
31288                 BDB_LIBS="$BDB_LIBS $ol_cv_lib_db"
31289         fi
31290
31291         echo "$as_me:$LINENO: checking Berkeley DB version for BDB/HDB backends" >&5
31292 echo $ECHO_N "checking Berkeley DB version for BDB/HDB backends... $ECHO_C" >&6
31293 if test "${ol_cv_bdb_compat+set}" = set; then
31294   echo $ECHO_N "(cached) $ECHO_C" >&6
31295 else
31296
31297         cat >conftest.$ac_ext <<_ACEOF
31298 /* confdefs.h.  */
31299 _ACEOF
31300 cat confdefs.h >>conftest.$ac_ext
31301 cat >>conftest.$ac_ext <<_ACEOF
31302 /* end confdefs.h.  */
31303
31304 #include <db.h>
31305
31306  /* this check could be improved */
31307 #ifndef DB_VERSION_MAJOR
31308 #       define DB_VERSION_MAJOR 1
31309 #endif
31310 #ifndef DB_VERSION_MINOR
31311 #       define DB_VERSION_MINOR 0
31312 #endif
31313
31314 /* require 4.2 or later */
31315 #if (DB_VERSION_MAJOR >= 4) && (DB_VERSION_MINOR >= 2)
31316         __db_version_compat
31317 #endif
31318
31319 _ACEOF
31320 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
31321   $EGREP "__db_version_compat" >/dev/null 2>&1; then
31322   ol_cv_bdb_compat=yes
31323 else
31324   ol_cv_bdb_compat=no
31325 fi
31326 rm -f conftest*
31327
31328 fi
31329 echo "$as_me:$LINENO: result: $ol_cv_bdb_compat" >&5
31330 echo "${ECHO_T}$ol_cv_bdb_compat" >&6
31331
31332
31333         if test $ol_cv_bdb_compat != yes ; then
31334                 { { echo "$as_me:$LINENO: error: BDB/HDB: BerkeleyDB version incompatible" >&5
31335 echo "$as_me: error: BDB/HDB: BerkeleyDB version incompatible" >&2;}
31336    { (exit 1); exit 1; }; }
31337         fi
31338
31339         SLAPD_LIBS="$SLAPD_LIBS \$(BDB_LIBS)"
31340
31341         ol_link_bdb=yes
31342 fi
31343
31344
31345 if test $ol_enable_dynamic = yes && test $enable_shared = yes ; then
31346         BUILD_LIBS_DYNAMIC=shared
31347
31348 cat >>confdefs.h <<\_ACEOF
31349 #define LDAP_LIBS_DYNAMIC 1
31350 _ACEOF
31351
31352         LTSTATIC=""
31353 else
31354         BUILD_LIBS_DYNAMIC=static
31355         LTSTATIC="-static"
31356 fi
31357
31358 if test $ol_enable_wrappers != no ; then
31359
31360 for ac_header in tcpd.h
31361 do
31362 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
31363 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31364   echo "$as_me:$LINENO: checking for $ac_header" >&5
31365 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31366 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31367   echo $ECHO_N "(cached) $ECHO_C" >&6
31368 fi
31369 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31370 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31371 else
31372   # Is the header compilable?
31373 echo "$as_me:$LINENO: checking $ac_header usability" >&5
31374 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
31375 cat >conftest.$ac_ext <<_ACEOF
31376 /* confdefs.h.  */
31377 _ACEOF
31378 cat confdefs.h >>conftest.$ac_ext
31379 cat >>conftest.$ac_ext <<_ACEOF
31380 /* end confdefs.h.  */
31381 $ac_includes_default
31382 #include <$ac_header>
31383 _ACEOF
31384 rm -f conftest.$ac_objext
31385 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31386   (eval $ac_compile) 2>conftest.er1
31387   ac_status=$?
31388   grep -v '^ *+' conftest.er1 >conftest.err
31389   rm -f conftest.er1
31390   cat conftest.err >&5
31391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31392   (exit $ac_status); } &&
31393          { ac_try='test -z "$ac_c_werror_flag"
31394                          || test ! -s conftest.err'
31395   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31396   (eval $ac_try) 2>&5
31397   ac_status=$?
31398   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31399   (exit $ac_status); }; } &&
31400          { ac_try='test -s conftest.$ac_objext'
31401   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31402   (eval $ac_try) 2>&5
31403   ac_status=$?
31404   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31405   (exit $ac_status); }; }; then
31406   ac_header_compiler=yes
31407 else
31408   echo "$as_me: failed program was:" >&5
31409 sed 's/^/| /' conftest.$ac_ext >&5
31410
31411 ac_header_compiler=no
31412 fi
31413 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
31414 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
31415 echo "${ECHO_T}$ac_header_compiler" >&6
31416
31417 # Is the header present?
31418 echo "$as_me:$LINENO: checking $ac_header presence" >&5
31419 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
31420 cat >conftest.$ac_ext <<_ACEOF
31421 /* confdefs.h.  */
31422 _ACEOF
31423 cat confdefs.h >>conftest.$ac_ext
31424 cat >>conftest.$ac_ext <<_ACEOF
31425 /* end confdefs.h.  */
31426 #include <$ac_header>
31427 _ACEOF
31428 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
31429   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
31430   ac_status=$?
31431   grep -v '^ *+' conftest.er1 >conftest.err
31432   rm -f conftest.er1
31433   cat conftest.err >&5
31434   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31435   (exit $ac_status); } >/dev/null; then
31436   if test -s conftest.err; then
31437     ac_cpp_err=$ac_c_preproc_warn_flag
31438     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
31439   else
31440     ac_cpp_err=
31441   fi
31442 else
31443   ac_cpp_err=yes
31444 fi
31445 if test -z "$ac_cpp_err"; then
31446   ac_header_preproc=yes
31447 else
31448   echo "$as_me: failed program was:" >&5
31449 sed 's/^/| /' conftest.$ac_ext >&5
31450
31451   ac_header_preproc=no
31452 fi
31453 rm -f conftest.err conftest.$ac_ext
31454 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
31455 echo "${ECHO_T}$ac_header_preproc" >&6
31456
31457 # So?  What about this header?
31458 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
31459   yes:no: )
31460     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
31461 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
31462     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
31463 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
31464     ac_header_preproc=yes
31465     ;;
31466   no:yes:* )
31467     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
31468 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
31469     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
31470 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
31471     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
31472 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
31473     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
31474 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
31475     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
31476 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
31477     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
31478 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
31479     (
31480       cat <<\_ASBOX
31481 ## --------------------------------------------- ##
31482 ## Report this to <http://www.openldap.org/its/> ##
31483 ## --------------------------------------------- ##
31484 _ASBOX
31485     ) |
31486       sed "s/^/$as_me: WARNING:     /" >&2
31487     ;;
31488 esac
31489 echo "$as_me:$LINENO: checking for $ac_header" >&5
31490 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31491 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31492   echo $ECHO_N "(cached) $ECHO_C" >&6
31493 else
31494   eval "$as_ac_Header=\$ac_header_preproc"
31495 fi
31496 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31497 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31498
31499 fi
31500 if test `eval echo '${'$as_ac_Header'}'` = yes; then
31501   cat >>confdefs.h <<_ACEOF
31502 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
31503 _ACEOF
31504
31505                 echo "$as_me:$LINENO: checking for TCP wrappers library" >&5
31506 echo $ECHO_N "checking for TCP wrappers library... $ECHO_C" >&6
31507                 save_LIBS="$LIBS"
31508                 LIBS="$LIBS -lwrap"
31509                 cat >conftest.$ac_ext <<_ACEOF
31510 /* confdefs.h.  */
31511 _ACEOF
31512 cat confdefs.h >>conftest.$ac_ext
31513 cat >>conftest.$ac_ext <<_ACEOF
31514 /* end confdefs.h.  */
31515
31516 #include <tcpd.h>
31517 int allow_severity = 0;
31518 int deny_severity  = 0;
31519
31520 struct request_info *req;
31521
31522 int
31523 main ()
31524 {
31525
31526 hosts_access(req)
31527
31528   ;
31529   return 0;
31530 }
31531 _ACEOF
31532 rm -f conftest.$ac_objext conftest$ac_exeext
31533 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31534   (eval $ac_link) 2>conftest.er1
31535   ac_status=$?
31536   grep -v '^ *+' conftest.er1 >conftest.err
31537   rm -f conftest.er1
31538   cat conftest.err >&5
31539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31540   (exit $ac_status); } &&
31541          { ac_try='test -z "$ac_c_werror_flag"
31542                          || test ! -s conftest.err'
31543   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31544   (eval $ac_try) 2>&5
31545   ac_status=$?
31546   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31547   (exit $ac_status); }; } &&
31548          { ac_try='test -s conftest$ac_exeext'
31549   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31550   (eval $ac_try) 2>&5
31551   ac_status=$?
31552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31553   (exit $ac_status); }; }; then
31554   echo "$as_me:$LINENO: result: -lwrap" >&5
31555 echo "${ECHO_T}-lwrap" >&6
31556                 have_wrappers=yes
31557                 LIBS="$save_LIBS"
31558 else
31559   echo "$as_me: failed program was:" >&5
31560 sed 's/^/| /' conftest.$ac_ext >&5
31561
31562
31563                                 LIBS="$LIBS -lnsl"
31564                 cat >conftest.$ac_ext <<_ACEOF
31565 /* confdefs.h.  */
31566 _ACEOF
31567 cat confdefs.h >>conftest.$ac_ext
31568 cat >>conftest.$ac_ext <<_ACEOF
31569 /* end confdefs.h.  */
31570
31571 #include <tcpd.h>
31572 int allow_severity = 0;
31573 int deny_severity  = 0;
31574
31575 struct request_info *req;
31576
31577 int
31578 main ()
31579 {
31580
31581 hosts_access(req)
31582
31583   ;
31584   return 0;
31585 }
31586 _ACEOF
31587 rm -f conftest.$ac_objext conftest$ac_exeext
31588 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31589   (eval $ac_link) 2>conftest.er1
31590   ac_status=$?
31591   grep -v '^ *+' conftest.er1 >conftest.err
31592   rm -f conftest.er1
31593   cat conftest.err >&5
31594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31595   (exit $ac_status); } &&
31596          { ac_try='test -z "$ac_c_werror_flag"
31597                          || test ! -s conftest.err'
31598   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31599   (eval $ac_try) 2>&5
31600   ac_status=$?
31601   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31602   (exit $ac_status); }; } &&
31603          { ac_try='test -s conftest$ac_exeext'
31604   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31605   (eval $ac_try) 2>&5
31606   ac_status=$?
31607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31608   (exit $ac_status); }; }; then
31609   echo "$as_me:$LINENO: result: -lwrap -lnsl" >&5
31610 echo "${ECHO_T}-lwrap -lnsl" >&6
31611                 have_wrappers=yes
31612                 LIBS="$save_LIBS -lnsl"
31613 else
31614   echo "$as_me: failed program was:" >&5
31615 sed 's/^/| /' conftest.$ac_ext >&5
31616
31617
31618                 echo "$as_me:$LINENO: result: no" >&5
31619 echo "${ECHO_T}no" >&6
31620                 have_wrappers=no
31621                 LIBS=$save_LIBS
31622 fi
31623 rm -f conftest.err conftest.$ac_objext \
31624       conftest$ac_exeext conftest.$ac_ext
31625 fi
31626 rm -f conftest.err conftest.$ac_objext \
31627       conftest$ac_exeext conftest.$ac_ext
31628 else
31629   have_wrappers=no
31630 fi
31631
31632 done
31633
31634
31635         if test $have_wrappers = yes ; then
31636
31637 cat >>confdefs.h <<\_ACEOF
31638 #define HAVE_TCPD 1
31639 _ACEOF
31640
31641                 WRAP_LIBS="-lwrap"
31642         elif test $ol_enable_wrappers = yes ; then
31643                 { { echo "$as_me:$LINENO: error: could not find TCP wrappers, select apppropriate options or disable" >&5
31644 echo "$as_me: error: could not find TCP wrappers, select apppropriate options or disable" >&2;}
31645    { (exit 1); exit 1; }; }
31646         else
31647                 { echo "$as_me:$LINENO: WARNING: could not find TCP wrappers, support disabled" >&5
31648 echo "$as_me: WARNING: could not find TCP wrappers, support disabled" >&2;}
31649                 WRAP_LIBS=""
31650         fi
31651 fi
31652
31653 if test $ol_enable_syslog != no ; then
31654         echo "$as_me:$LINENO: checking for openlog" >&5
31655 echo $ECHO_N "checking for openlog... $ECHO_C" >&6
31656 if test "${ac_cv_func_openlog+set}" = set; then
31657   echo $ECHO_N "(cached) $ECHO_C" >&6
31658 else
31659   cat >conftest.$ac_ext <<_ACEOF
31660 /* confdefs.h.  */
31661 _ACEOF
31662 cat confdefs.h >>conftest.$ac_ext
31663 cat >>conftest.$ac_ext <<_ACEOF
31664 /* end confdefs.h.  */
31665 /* Define openlog to an innocuous variant, in case <limits.h> declares openlog.
31666    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
31667 #define openlog innocuous_openlog
31668
31669 /* System header to define __stub macros and hopefully few prototypes,
31670     which can conflict with char openlog (); below.
31671     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31672     <limits.h> exists even on freestanding compilers.  */
31673
31674 #ifdef __STDC__
31675 # include <limits.h>
31676 #else
31677 # include <assert.h>
31678 #endif
31679
31680 #undef openlog
31681
31682 /* Override any gcc2 internal prototype to avoid an error.  */
31683 #ifdef __cplusplus
31684 extern "C"
31685 {
31686 #endif
31687 /* We use char because int might match the return type of a gcc2
31688    builtin and then its argument prototype would still apply.  */
31689 char openlog ();
31690 /* The GNU C library defines this for functions which it implements
31691     to always fail with ENOSYS.  Some functions are actually named
31692     something starting with __ and the normal name is an alias.  */
31693 #if defined (__stub_openlog) || defined (__stub___openlog)
31694 choke me
31695 #else
31696 char (*f) () = openlog;
31697 #endif
31698 #ifdef __cplusplus
31699 }
31700 #endif
31701
31702 int
31703 main ()
31704 {
31705 return f != openlog;
31706   ;
31707   return 0;
31708 }
31709 _ACEOF
31710 rm -f conftest.$ac_objext conftest$ac_exeext
31711 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31712   (eval $ac_link) 2>conftest.er1
31713   ac_status=$?
31714   grep -v '^ *+' conftest.er1 >conftest.err
31715   rm -f conftest.er1
31716   cat conftest.err >&5
31717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31718   (exit $ac_status); } &&
31719          { ac_try='test -z "$ac_c_werror_flag"
31720                          || test ! -s conftest.err'
31721   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31722   (eval $ac_try) 2>&5
31723   ac_status=$?
31724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31725   (exit $ac_status); }; } &&
31726          { ac_try='test -s conftest$ac_exeext'
31727   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31728   (eval $ac_try) 2>&5
31729   ac_status=$?
31730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31731   (exit $ac_status); }; }; then
31732   ac_cv_func_openlog=yes
31733 else
31734   echo "$as_me: failed program was:" >&5
31735 sed 's/^/| /' conftest.$ac_ext >&5
31736
31737 ac_cv_func_openlog=no
31738 fi
31739 rm -f conftest.err conftest.$ac_objext \
31740       conftest$ac_exeext conftest.$ac_ext
31741 fi
31742 echo "$as_me:$LINENO: result: $ac_cv_func_openlog" >&5
31743 echo "${ECHO_T}$ac_cv_func_openlog" >&6
31744
31745         if test $ac_cv_func_openlog = no && test $ol_enable_syslog = yes; then
31746                 { { echo "$as_me:$LINENO: error: could not find syslog" >&5
31747 echo "$as_me: error: could not find syslog" >&2;}
31748    { (exit select appropriate options or disable); exit select appropriate options or disable; }; }
31749         fi
31750         ol_enable_syslog=$ac_cv_func_openlog
31751 fi
31752
31753 ol_link_sql=no
31754 if test $ol_enable_sql != no ; then
31755
31756
31757 for ac_header in sql.h sqlext.h
31758 do
31759 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
31760 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31761   echo "$as_me:$LINENO: checking for $ac_header" >&5
31762 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31763 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31764   echo $ECHO_N "(cached) $ECHO_C" >&6
31765 fi
31766 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31767 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31768 else
31769   # Is the header compilable?
31770 echo "$as_me:$LINENO: checking $ac_header usability" >&5
31771 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
31772 cat >conftest.$ac_ext <<_ACEOF
31773 /* confdefs.h.  */
31774 _ACEOF
31775 cat confdefs.h >>conftest.$ac_ext
31776 cat >>conftest.$ac_ext <<_ACEOF
31777 /* end confdefs.h.  */
31778 $ac_includes_default
31779 #include <$ac_header>
31780 _ACEOF
31781 rm -f conftest.$ac_objext
31782 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31783   (eval $ac_compile) 2>conftest.er1
31784   ac_status=$?
31785   grep -v '^ *+' conftest.er1 >conftest.err
31786   rm -f conftest.er1
31787   cat conftest.err >&5
31788   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31789   (exit $ac_status); } &&
31790          { ac_try='test -z "$ac_c_werror_flag"
31791                          || test ! -s conftest.err'
31792   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31793   (eval $ac_try) 2>&5
31794   ac_status=$?
31795   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31796   (exit $ac_status); }; } &&
31797          { ac_try='test -s conftest.$ac_objext'
31798   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31799   (eval $ac_try) 2>&5
31800   ac_status=$?
31801   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31802   (exit $ac_status); }; }; then
31803   ac_header_compiler=yes
31804 else
31805   echo "$as_me: failed program was:" >&5
31806 sed 's/^/| /' conftest.$ac_ext >&5
31807
31808 ac_header_compiler=no
31809 fi
31810 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
31811 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
31812 echo "${ECHO_T}$ac_header_compiler" >&6
31813
31814 # Is the header present?
31815 echo "$as_me:$LINENO: checking $ac_header presence" >&5
31816 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
31817 cat >conftest.$ac_ext <<_ACEOF
31818 /* confdefs.h.  */
31819 _ACEOF
31820 cat confdefs.h >>conftest.$ac_ext
31821 cat >>conftest.$ac_ext <<_ACEOF
31822 /* end confdefs.h.  */
31823 #include <$ac_header>
31824 _ACEOF
31825 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
31826   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
31827   ac_status=$?
31828   grep -v '^ *+' conftest.er1 >conftest.err
31829   rm -f conftest.er1
31830   cat conftest.err >&5
31831   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31832   (exit $ac_status); } >/dev/null; then
31833   if test -s conftest.err; then
31834     ac_cpp_err=$ac_c_preproc_warn_flag
31835     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
31836   else
31837     ac_cpp_err=
31838   fi
31839 else
31840   ac_cpp_err=yes
31841 fi
31842 if test -z "$ac_cpp_err"; then
31843   ac_header_preproc=yes
31844 else
31845   echo "$as_me: failed program was:" >&5
31846 sed 's/^/| /' conftest.$ac_ext >&5
31847
31848   ac_header_preproc=no
31849 fi
31850 rm -f conftest.err conftest.$ac_ext
31851 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
31852 echo "${ECHO_T}$ac_header_preproc" >&6
31853
31854 # So?  What about this header?
31855 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
31856   yes:no: )
31857     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
31858 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
31859     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
31860 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
31861     ac_header_preproc=yes
31862     ;;
31863   no:yes:* )
31864     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
31865 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
31866     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
31867 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
31868     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
31869 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
31870     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
31871 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
31872     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
31873 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
31874     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
31875 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
31876     (
31877       cat <<\_ASBOX
31878 ## --------------------------------------------- ##
31879 ## Report this to <http://www.openldap.org/its/> ##
31880 ## --------------------------------------------- ##
31881 _ASBOX
31882     ) |
31883       sed "s/^/$as_me: WARNING:     /" >&2
31884     ;;
31885 esac
31886 echo "$as_me:$LINENO: checking for $ac_header" >&5
31887 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31888 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31889   echo $ECHO_N "(cached) $ECHO_C" >&6
31890 else
31891   eval "$as_ac_Header=\$ac_header_preproc"
31892 fi
31893 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31894 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31895
31896 fi
31897 if test `eval echo '${'$as_ac_Header'}'` = yes; then
31898   cat >>confdefs.h <<_ACEOF
31899 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
31900 _ACEOF
31901
31902 else
31903
31904                 { { echo "$as_me:$LINENO: error: could not locate SQL headers" >&5
31905 echo "$as_me: error: could not locate SQL headers" >&2;}
31906    { (exit 1); exit 1; }; }
31907
31908 fi
31909
31910 done
31911
31912
31913         sql_LIBS="$LIBS"
31914         LIBS="$LTHREAD_LIBS"
31915
31916         echo "$as_me:$LINENO: checking for SQLDriverConnect in -liodbc" >&5
31917 echo $ECHO_N "checking for SQLDriverConnect in -liodbc... $ECHO_C" >&6
31918 if test "${ac_cv_lib_iodbc_SQLDriverConnect+set}" = set; then
31919   echo $ECHO_N "(cached) $ECHO_C" >&6
31920 else
31921   ac_check_lib_save_LIBS=$LIBS
31922 LIBS="-liodbc  $LIBS"
31923 cat >conftest.$ac_ext <<_ACEOF
31924 /* confdefs.h.  */
31925 _ACEOF
31926 cat confdefs.h >>conftest.$ac_ext
31927 cat >>conftest.$ac_ext <<_ACEOF
31928 /* end confdefs.h.  */
31929
31930 /* Override any gcc2 internal prototype to avoid an error.  */
31931 #ifdef __cplusplus
31932 extern "C"
31933 #endif
31934 /* We use char because int might match the return type of a gcc2
31935    builtin and then its argument prototype would still apply.  */
31936 char SQLDriverConnect ();
31937 int
31938 main ()
31939 {
31940 SQLDriverConnect ();
31941   ;
31942   return 0;
31943 }
31944 _ACEOF
31945 rm -f conftest.$ac_objext conftest$ac_exeext
31946 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31947   (eval $ac_link) 2>conftest.er1
31948   ac_status=$?
31949   grep -v '^ *+' conftest.er1 >conftest.err
31950   rm -f conftest.er1
31951   cat conftest.err >&5
31952   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31953   (exit $ac_status); } &&
31954          { ac_try='test -z "$ac_c_werror_flag"
31955                          || test ! -s conftest.err'
31956   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31957   (eval $ac_try) 2>&5
31958   ac_status=$?
31959   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31960   (exit $ac_status); }; } &&
31961          { ac_try='test -s conftest$ac_exeext'
31962   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31963   (eval $ac_try) 2>&5
31964   ac_status=$?
31965   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31966   (exit $ac_status); }; }; then
31967   ac_cv_lib_iodbc_SQLDriverConnect=yes
31968 else
31969   echo "$as_me: failed program was:" >&5
31970 sed 's/^/| /' conftest.$ac_ext >&5
31971
31972 ac_cv_lib_iodbc_SQLDriverConnect=no
31973 fi
31974 rm -f conftest.err conftest.$ac_objext \
31975       conftest$ac_exeext conftest.$ac_ext
31976 LIBS=$ac_check_lib_save_LIBS
31977 fi
31978 echo "$as_me:$LINENO: result: $ac_cv_lib_iodbc_SQLDriverConnect" >&5
31979 echo "${ECHO_T}$ac_cv_lib_iodbc_SQLDriverConnect" >&6
31980 if test $ac_cv_lib_iodbc_SQLDriverConnect = yes; then
31981   have_iodbc=yes
31982 else
31983   have_iodbc=no
31984 fi
31985
31986         if test $have_iodbc = yes ; then
31987                 ol_link_sql="-liodbc"
31988         else
31989                 echo "$as_me:$LINENO: checking for SQLDriverConnect in -lodbc" >&5
31990 echo $ECHO_N "checking for SQLDriverConnect in -lodbc... $ECHO_C" >&6
31991 if test "${ac_cv_lib_odbc_SQLDriverConnect+set}" = set; then
31992   echo $ECHO_N "(cached) $ECHO_C" >&6
31993 else
31994   ac_check_lib_save_LIBS=$LIBS
31995 LIBS="-lodbc  $LIBS"
31996 cat >conftest.$ac_ext <<_ACEOF
31997 /* confdefs.h.  */
31998 _ACEOF
31999 cat confdefs.h >>conftest.$ac_ext
32000 cat >>conftest.$ac_ext <<_ACEOF
32001 /* end confdefs.h.  */
32002
32003 /* Override any gcc2 internal prototype to avoid an error.  */
32004 #ifdef __cplusplus
32005 extern "C"
32006 #endif
32007 /* We use char because int might match the return type of a gcc2
32008    builtin and then its argument prototype would still apply.  */
32009 char SQLDriverConnect ();
32010 int
32011 main ()
32012 {
32013 SQLDriverConnect ();
32014   ;
32015   return 0;
32016 }
32017 _ACEOF
32018 rm -f conftest.$ac_objext conftest$ac_exeext
32019 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32020   (eval $ac_link) 2>conftest.er1
32021   ac_status=$?
32022   grep -v '^ *+' conftest.er1 >conftest.err
32023   rm -f conftest.er1
32024   cat conftest.err >&5
32025   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32026   (exit $ac_status); } &&
32027          { ac_try='test -z "$ac_c_werror_flag"
32028                          || test ! -s conftest.err'
32029   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32030   (eval $ac_try) 2>&5
32031   ac_status=$?
32032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32033   (exit $ac_status); }; } &&
32034          { ac_try='test -s conftest$ac_exeext'
32035   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32036   (eval $ac_try) 2>&5
32037   ac_status=$?
32038   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32039   (exit $ac_status); }; }; then
32040   ac_cv_lib_odbc_SQLDriverConnect=yes
32041 else
32042   echo "$as_me: failed program was:" >&5
32043 sed 's/^/| /' conftest.$ac_ext >&5
32044
32045 ac_cv_lib_odbc_SQLDriverConnect=no
32046 fi
32047 rm -f conftest.err conftest.$ac_objext \
32048       conftest$ac_exeext conftest.$ac_ext
32049 LIBS=$ac_check_lib_save_LIBS
32050 fi
32051 echo "$as_me:$LINENO: result: $ac_cv_lib_odbc_SQLDriverConnect" >&5
32052 echo "${ECHO_T}$ac_cv_lib_odbc_SQLDriverConnect" >&6
32053 if test $ac_cv_lib_odbc_SQLDriverConnect = yes; then
32054   have_odbc=yes
32055 else
32056   have_odbc=no
32057 fi
32058
32059                 if test $have_odbc = yes ; then
32060                         ol_link_sql="-lodbc"
32061                 fi
32062         fi
32063
32064         LIBS="$sql_LIBS"
32065
32066         if test $ol_link_sql != no ; then
32067                 SLAPD_SQL_LIBS="$ol_link_sql"
32068
32069         elif test $ol_enable_sql != auto ; then
32070                 { { echo "$as_me:$LINENO: error: could not locate suitable ODBC library" >&5
32071 echo "$as_me: error: could not locate suitable ODBC library" >&2;}
32072    { (exit 1); exit 1; }; }
32073         fi
32074 fi
32075
32076 ol_icu=no
32077
32078 for ac_header in unicode/utypes.h
32079 do
32080 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
32081 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32082   echo "$as_me:$LINENO: checking for $ac_header" >&5
32083 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32084 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32085   echo $ECHO_N "(cached) $ECHO_C" >&6
32086 fi
32087 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32088 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32089 else
32090   # Is the header compilable?
32091 echo "$as_me:$LINENO: checking $ac_header usability" >&5
32092 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
32093 cat >conftest.$ac_ext <<_ACEOF
32094 /* confdefs.h.  */
32095 _ACEOF
32096 cat confdefs.h >>conftest.$ac_ext
32097 cat >>conftest.$ac_ext <<_ACEOF
32098 /* end confdefs.h.  */
32099 $ac_includes_default
32100 #include <$ac_header>
32101 _ACEOF
32102 rm -f conftest.$ac_objext
32103 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32104   (eval $ac_compile) 2>conftest.er1
32105   ac_status=$?
32106   grep -v '^ *+' conftest.er1 >conftest.err
32107   rm -f conftest.er1
32108   cat conftest.err >&5
32109   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32110   (exit $ac_status); } &&
32111          { ac_try='test -z "$ac_c_werror_flag"
32112                          || test ! -s conftest.err'
32113   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32114   (eval $ac_try) 2>&5
32115   ac_status=$?
32116   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32117   (exit $ac_status); }; } &&
32118          { ac_try='test -s conftest.$ac_objext'
32119   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32120   (eval $ac_try) 2>&5
32121   ac_status=$?
32122   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32123   (exit $ac_status); }; }; then
32124   ac_header_compiler=yes
32125 else
32126   echo "$as_me: failed program was:" >&5
32127 sed 's/^/| /' conftest.$ac_ext >&5
32128
32129 ac_header_compiler=no
32130 fi
32131 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32132 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
32133 echo "${ECHO_T}$ac_header_compiler" >&6
32134
32135 # Is the header present?
32136 echo "$as_me:$LINENO: checking $ac_header presence" >&5
32137 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
32138 cat >conftest.$ac_ext <<_ACEOF
32139 /* confdefs.h.  */
32140 _ACEOF
32141 cat confdefs.h >>conftest.$ac_ext
32142 cat >>conftest.$ac_ext <<_ACEOF
32143 /* end confdefs.h.  */
32144 #include <$ac_header>
32145 _ACEOF
32146 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
32147   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
32148   ac_status=$?
32149   grep -v '^ *+' conftest.er1 >conftest.err
32150   rm -f conftest.er1
32151   cat conftest.err >&5
32152   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32153   (exit $ac_status); } >/dev/null; then
32154   if test -s conftest.err; then
32155     ac_cpp_err=$ac_c_preproc_warn_flag
32156     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
32157   else
32158     ac_cpp_err=
32159   fi
32160 else
32161   ac_cpp_err=yes
32162 fi
32163 if test -z "$ac_cpp_err"; then
32164   ac_header_preproc=yes
32165 else
32166   echo "$as_me: failed program was:" >&5
32167 sed 's/^/| /' conftest.$ac_ext >&5
32168
32169   ac_header_preproc=no
32170 fi
32171 rm -f conftest.err conftest.$ac_ext
32172 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
32173 echo "${ECHO_T}$ac_header_preproc" >&6
32174
32175 # So?  What about this header?
32176 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
32177   yes:no: )
32178     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
32179 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
32180     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
32181 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
32182     ac_header_preproc=yes
32183     ;;
32184   no:yes:* )
32185     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
32186 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
32187     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
32188 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
32189     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
32190 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
32191     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
32192 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
32193     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
32194 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
32195     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
32196 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
32197     (
32198       cat <<\_ASBOX
32199 ## --------------------------------------------- ##
32200 ## Report this to <http://www.openldap.org/its/> ##
32201 ## --------------------------------------------- ##
32202 _ASBOX
32203     ) |
32204       sed "s/^/$as_me: WARNING:     /" >&2
32205     ;;
32206 esac
32207 echo "$as_me:$LINENO: checking for $ac_header" >&5
32208 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32209 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32210   echo $ECHO_N "(cached) $ECHO_C" >&6
32211 else
32212   eval "$as_ac_Header=\$ac_header_preproc"
32213 fi
32214 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32215 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32216
32217 fi
32218 if test `eval echo '${'$as_ac_Header'}'` = yes; then
32219   cat >>confdefs.h <<_ACEOF
32220 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
32221 _ACEOF
32222
32223 fi
32224
32225 done
32226
32227 if test $ac_cv_header_unicode_utypes_h = yes ; then
32228                 OL_ICULIBS="-licuuc -licudata"
32229
32230         echo "$as_me:$LINENO: checking for ICU libraries" >&5
32231 echo $ECHO_N "checking for ICU libraries... $ECHO_C" >&6
32232 if test "${ol_cv_lib_icu+set}" = set; then
32233   echo $ECHO_N "(cached) $ECHO_C" >&6
32234 else
32235
32236                 ol_LIBS="$LIBS"
32237                 LIBS="$OL_ICULIBS $LIBS"
32238                 cat >conftest.$ac_ext <<_ACEOF
32239 /* confdefs.h.  */
32240 _ACEOF
32241 cat confdefs.h >>conftest.$ac_ext
32242 cat >>conftest.$ac_ext <<_ACEOF
32243 /* end confdefs.h.  */
32244
32245 #include <unicode/utypes.h>
32246
32247 int
32248 main ()
32249 {
32250
32251 (void) u_errorName(0);
32252
32253   ;
32254   return 0;
32255 }
32256 _ACEOF
32257 rm -f conftest.$ac_objext conftest$ac_exeext
32258 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32259   (eval $ac_link) 2>conftest.er1
32260   ac_status=$?
32261   grep -v '^ *+' conftest.er1 >conftest.err
32262   rm -f conftest.er1
32263   cat conftest.err >&5
32264   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32265   (exit $ac_status); } &&
32266          { ac_try='test -z "$ac_c_werror_flag"
32267                          || test ! -s conftest.err'
32268   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32269   (eval $ac_try) 2>&5
32270   ac_status=$?
32271   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32272   (exit $ac_status); }; } &&
32273          { ac_try='test -s conftest$ac_exeext'
32274   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32275   (eval $ac_try) 2>&5
32276   ac_status=$?
32277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32278   (exit $ac_status); }; }; then
32279   ol_cv_lib_icu=yes
32280 else
32281   echo "$as_me: failed program was:" >&5
32282 sed 's/^/| /' conftest.$ac_ext >&5
32283
32284 ol_cv_lib_icu=no
32285 fi
32286 rm -f conftest.err conftest.$ac_objext \
32287       conftest$ac_exeext conftest.$ac_ext
32288                 LIBS="$ol_LIBS"
32289
32290 fi
32291 echo "$as_me:$LINENO: result: $ol_cv_lib_icu" >&5
32292 echo "${ECHO_T}$ol_cv_lib_icu" >&6
32293
32294         if test $ol_cv_lib_icu != no ; then
32295                 ol_icu="$OL_ICULIBS"
32296
32297 cat >>confdefs.h <<\_ACEOF
32298 #define HAVE_ICU 1
32299 _ACEOF
32300
32301         fi
32302 fi
32303
32304 if test "$ol_icu" = no ; then
32305         { echo "$as_me:$LINENO: WARNING: ICU not available" >&5
32306 echo "$as_me: WARNING: ICU not available" >&2;}
32307 else
32308         ICU_LIBS="$ol_icu"
32309 fi
32310 WITH_SASL=no
32311 ol_link_sasl=no
32312 ol_link_spasswd=no
32313 if test $ol_with_cyrus_sasl != no ; then
32314
32315
32316 for ac_header in sasl/sasl.h sasl.h
32317 do
32318 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
32319 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32320   echo "$as_me:$LINENO: checking for $ac_header" >&5
32321 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32322 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32323   echo $ECHO_N "(cached) $ECHO_C" >&6
32324 fi
32325 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32326 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32327 else
32328   # Is the header compilable?
32329 echo "$as_me:$LINENO: checking $ac_header usability" >&5
32330 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
32331 cat >conftest.$ac_ext <<_ACEOF
32332 /* confdefs.h.  */
32333 _ACEOF
32334 cat confdefs.h >>conftest.$ac_ext
32335 cat >>conftest.$ac_ext <<_ACEOF
32336 /* end confdefs.h.  */
32337 $ac_includes_default
32338 #include <$ac_header>
32339 _ACEOF
32340 rm -f conftest.$ac_objext
32341 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32342   (eval $ac_compile) 2>conftest.er1
32343   ac_status=$?
32344   grep -v '^ *+' conftest.er1 >conftest.err
32345   rm -f conftest.er1
32346   cat conftest.err >&5
32347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32348   (exit $ac_status); } &&
32349          { ac_try='test -z "$ac_c_werror_flag"
32350                          || test ! -s conftest.err'
32351   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32352   (eval $ac_try) 2>&5
32353   ac_status=$?
32354   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32355   (exit $ac_status); }; } &&
32356          { ac_try='test -s conftest.$ac_objext'
32357   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32358   (eval $ac_try) 2>&5
32359   ac_status=$?
32360   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32361   (exit $ac_status); }; }; then
32362   ac_header_compiler=yes
32363 else
32364   echo "$as_me: failed program was:" >&5
32365 sed 's/^/| /' conftest.$ac_ext >&5
32366
32367 ac_header_compiler=no
32368 fi
32369 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32370 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
32371 echo "${ECHO_T}$ac_header_compiler" >&6
32372
32373 # Is the header present?
32374 echo "$as_me:$LINENO: checking $ac_header presence" >&5
32375 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
32376 cat >conftest.$ac_ext <<_ACEOF
32377 /* confdefs.h.  */
32378 _ACEOF
32379 cat confdefs.h >>conftest.$ac_ext
32380 cat >>conftest.$ac_ext <<_ACEOF
32381 /* end confdefs.h.  */
32382 #include <$ac_header>
32383 _ACEOF
32384 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
32385   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
32386   ac_status=$?
32387   grep -v '^ *+' conftest.er1 >conftest.err
32388   rm -f conftest.er1
32389   cat conftest.err >&5
32390   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32391   (exit $ac_status); } >/dev/null; then
32392   if test -s conftest.err; then
32393     ac_cpp_err=$ac_c_preproc_warn_flag
32394     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
32395   else
32396     ac_cpp_err=
32397   fi
32398 else
32399   ac_cpp_err=yes
32400 fi
32401 if test -z "$ac_cpp_err"; then
32402   ac_header_preproc=yes
32403 else
32404   echo "$as_me: failed program was:" >&5
32405 sed 's/^/| /' conftest.$ac_ext >&5
32406
32407   ac_header_preproc=no
32408 fi
32409 rm -f conftest.err conftest.$ac_ext
32410 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
32411 echo "${ECHO_T}$ac_header_preproc" >&6
32412
32413 # So?  What about this header?
32414 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
32415   yes:no: )
32416     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
32417 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
32418     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
32419 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
32420     ac_header_preproc=yes
32421     ;;
32422   no:yes:* )
32423     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
32424 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
32425     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
32426 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
32427     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
32428 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
32429     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
32430 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
32431     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
32432 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
32433     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
32434 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
32435     (
32436       cat <<\_ASBOX
32437 ## --------------------------------------------- ##
32438 ## Report this to <http://www.openldap.org/its/> ##
32439 ## --------------------------------------------- ##
32440 _ASBOX
32441     ) |
32442       sed "s/^/$as_me: WARNING:     /" >&2
32443     ;;
32444 esac
32445 echo "$as_me:$LINENO: checking for $ac_header" >&5
32446 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32447 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32448   echo $ECHO_N "(cached) $ECHO_C" >&6
32449 else
32450   eval "$as_ac_Header=\$ac_header_preproc"
32451 fi
32452 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32453 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32454
32455 fi
32456 if test `eval echo '${'$as_ac_Header'}'` = yes; then
32457   cat >>confdefs.h <<_ACEOF
32458 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
32459 _ACEOF
32460
32461 fi
32462
32463 done
32464
32465
32466         if test $ac_cv_header_sasl_sasl_h = yes ||
32467            test $ac_cv_header_sasl_h = yes; then
32468                 echo "$as_me:$LINENO: checking for sasl_client_init in -lsasl2" >&5
32469 echo $ECHO_N "checking for sasl_client_init in -lsasl2... $ECHO_C" >&6
32470 if test "${ac_cv_lib_sasl2_sasl_client_init+set}" = set; then
32471   echo $ECHO_N "(cached) $ECHO_C" >&6
32472 else
32473   ac_check_lib_save_LIBS=$LIBS
32474 LIBS="-lsasl2  $LIBS"
32475 cat >conftest.$ac_ext <<_ACEOF
32476 /* confdefs.h.  */
32477 _ACEOF
32478 cat confdefs.h >>conftest.$ac_ext
32479 cat >>conftest.$ac_ext <<_ACEOF
32480 /* end confdefs.h.  */
32481
32482 /* Override any gcc2 internal prototype to avoid an error.  */
32483 #ifdef __cplusplus
32484 extern "C"
32485 #endif
32486 /* We use char because int might match the return type of a gcc2
32487    builtin and then its argument prototype would still apply.  */
32488 char sasl_client_init ();
32489 int
32490 main ()
32491 {
32492 sasl_client_init ();
32493   ;
32494   return 0;
32495 }
32496 _ACEOF
32497 rm -f conftest.$ac_objext conftest$ac_exeext
32498 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32499   (eval $ac_link) 2>conftest.er1
32500   ac_status=$?
32501   grep -v '^ *+' conftest.er1 >conftest.err
32502   rm -f conftest.er1
32503   cat conftest.err >&5
32504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32505   (exit $ac_status); } &&
32506          { ac_try='test -z "$ac_c_werror_flag"
32507                          || test ! -s conftest.err'
32508   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32509   (eval $ac_try) 2>&5
32510   ac_status=$?
32511   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32512   (exit $ac_status); }; } &&
32513          { ac_try='test -s conftest$ac_exeext'
32514   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32515   (eval $ac_try) 2>&5
32516   ac_status=$?
32517   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32518   (exit $ac_status); }; }; then
32519   ac_cv_lib_sasl2_sasl_client_init=yes
32520 else
32521   echo "$as_me: failed program was:" >&5
32522 sed 's/^/| /' conftest.$ac_ext >&5
32523
32524 ac_cv_lib_sasl2_sasl_client_init=no
32525 fi
32526 rm -f conftest.err conftest.$ac_objext \
32527       conftest$ac_exeext conftest.$ac_ext
32528 LIBS=$ac_check_lib_save_LIBS
32529 fi
32530 echo "$as_me:$LINENO: result: $ac_cv_lib_sasl2_sasl_client_init" >&5
32531 echo "${ECHO_T}$ac_cv_lib_sasl2_sasl_client_init" >&6
32532 if test $ac_cv_lib_sasl2_sasl_client_init = yes; then
32533   ol_link_sasl="-lsasl2"
32534 else
32535   echo "$as_me:$LINENO: checking for sasl_client_init in -lsasl" >&5
32536 echo $ECHO_N "checking for sasl_client_init in -lsasl... $ECHO_C" >&6
32537 if test "${ac_cv_lib_sasl_sasl_client_init+set}" = set; then
32538   echo $ECHO_N "(cached) $ECHO_C" >&6
32539 else
32540   ac_check_lib_save_LIBS=$LIBS
32541 LIBS="-lsasl  $LIBS"
32542 cat >conftest.$ac_ext <<_ACEOF
32543 /* confdefs.h.  */
32544 _ACEOF
32545 cat confdefs.h >>conftest.$ac_ext
32546 cat >>conftest.$ac_ext <<_ACEOF
32547 /* end confdefs.h.  */
32548
32549 /* Override any gcc2 internal prototype to avoid an error.  */
32550 #ifdef __cplusplus
32551 extern "C"
32552 #endif
32553 /* We use char because int might match the return type of a gcc2
32554    builtin and then its argument prototype would still apply.  */
32555 char sasl_client_init ();
32556 int
32557 main ()
32558 {
32559 sasl_client_init ();
32560   ;
32561   return 0;
32562 }
32563 _ACEOF
32564 rm -f conftest.$ac_objext conftest$ac_exeext
32565 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32566   (eval $ac_link) 2>conftest.er1
32567   ac_status=$?
32568   grep -v '^ *+' conftest.er1 >conftest.err
32569   rm -f conftest.er1
32570   cat conftest.err >&5
32571   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32572   (exit $ac_status); } &&
32573          { ac_try='test -z "$ac_c_werror_flag"
32574                          || test ! -s conftest.err'
32575   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32576   (eval $ac_try) 2>&5
32577   ac_status=$?
32578   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32579   (exit $ac_status); }; } &&
32580          { ac_try='test -s conftest$ac_exeext'
32581   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32582   (eval $ac_try) 2>&5
32583   ac_status=$?
32584   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32585   (exit $ac_status); }; }; then
32586   ac_cv_lib_sasl_sasl_client_init=yes
32587 else
32588   echo "$as_me: failed program was:" >&5
32589 sed 's/^/| /' conftest.$ac_ext >&5
32590
32591 ac_cv_lib_sasl_sasl_client_init=no
32592 fi
32593 rm -f conftest.err conftest.$ac_objext \
32594       conftest$ac_exeext conftest.$ac_ext
32595 LIBS=$ac_check_lib_save_LIBS
32596 fi
32597 echo "$as_me:$LINENO: result: $ac_cv_lib_sasl_sasl_client_init" >&5
32598 echo "${ECHO_T}$ac_cv_lib_sasl_sasl_client_init" >&6
32599 if test $ac_cv_lib_sasl_sasl_client_init = yes; then
32600   ol_link_sasl="-lsasl"
32601 fi
32602
32603 fi
32604
32605         fi
32606
32607         if test $ol_link_sasl = no ; then
32608                 if test $ol_with_cyrus_sasl != auto ; then
32609                         { { echo "$as_me:$LINENO: error: Could not locate Cyrus SASL" >&5
32610 echo "$as_me: error: Could not locate Cyrus SASL" >&2;}
32611    { (exit 1); exit 1; }; }
32612                 else
32613                         { echo "$as_me:$LINENO: WARNING: Could not locate Cyrus SASL" >&5
32614 echo "$as_me: WARNING: Could not locate Cyrus SASL" >&2;}
32615                         { echo "$as_me:$LINENO: WARNING: SASL authentication not supported!" >&5
32616 echo "$as_me: WARNING: SASL authentication not supported!" >&2;}
32617                         if test $ol_link_tls = no ; then
32618                                 { echo "$as_me:$LINENO: WARNING: Strong authentication not supported!" >&5
32619 echo "$as_me: WARNING: Strong authentication not supported!" >&2;}
32620                         fi
32621                 fi
32622         else
32623                 echo "$as_me:$LINENO: checking Cyrus SASL library version" >&5
32624 echo $ECHO_N "checking Cyrus SASL library version... $ECHO_C" >&6
32625 if test "${ol_cv_sasl_compat+set}" = set; then
32626   echo $ECHO_N "(cached) $ECHO_C" >&6
32627 else
32628
32629         cat >conftest.$ac_ext <<_ACEOF
32630 /* confdefs.h.  */
32631 _ACEOF
32632 cat confdefs.h >>conftest.$ac_ext
32633 cat >>conftest.$ac_ext <<_ACEOF
32634 /* end confdefs.h.  */
32635
32636 #ifdef HAVE_SASL_SASL_H
32637 #include <sasl/sasl.h>
32638 #else
32639 #include <sasl.h>
32640 #endif
32641
32642 /* Require 2.1.15+ */
32643 #if SASL_VERSION_MAJOR == 2  && SASL_VERSION_MINOR > 1
32644         char *__sasl_compat = "2.2+ or better okay (we guess)";
32645 #elif SASL_VERSION_MAJOR == 2  && SASL_VERSION_MINOR == 1 \
32646         && SASL_VERSION_STEP >=15
32647         char *__sasl_compat = "2.1.15+ or better okay";
32648 #endif
32649
32650 _ACEOF
32651 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32652   $EGREP "__sasl_compat" >/dev/null 2>&1; then
32653   ol_cv_sasl_compat=yes
32654 else
32655   ol_cv_sasl_compat=no
32656 fi
32657 rm -f conftest*
32658
32659 fi
32660 echo "$as_me:$LINENO: result: $ol_cv_sasl_compat" >&5
32661 echo "${ECHO_T}$ol_cv_sasl_compat" >&6
32662
32663                 if test $ol_cv_sasl_compat = no ; then
32664                         ol_link_sasl=no
32665                         { { echo "$as_me:$LINENO: error: Cyrus SASL library located but is incompatible" >&5
32666 echo "$as_me: error: Cyrus SASL library located but is incompatible" >&2;}
32667    { (exit 1); exit 1; }; }
32668                 fi
32669
32670
32671 cat >>confdefs.h <<\_ACEOF
32672 #define HAVE_CYRUS_SASL 1
32673 _ACEOF
32674
32675                 SASL_LIBS="$ol_link_sasl"
32676                 if test $ol_enable_spasswd != no ; then
32677                         ol_link_spasswd=yes
32678                 fi
32679
32680                 ac_save_LIBS="$LIBS"
32681                 LIBS="$LIBS $ol_link_sasl"
32682                 echo "$as_me:$LINENO: checking for sasl_version" >&5
32683 echo $ECHO_N "checking for sasl_version... $ECHO_C" >&6
32684 if test "${ac_cv_func_sasl_version+set}" = set; then
32685   echo $ECHO_N "(cached) $ECHO_C" >&6
32686 else
32687   cat >conftest.$ac_ext <<_ACEOF
32688 /* confdefs.h.  */
32689 _ACEOF
32690 cat confdefs.h >>conftest.$ac_ext
32691 cat >>conftest.$ac_ext <<_ACEOF
32692 /* end confdefs.h.  */
32693 /* Define sasl_version to an innocuous variant, in case <limits.h> declares sasl_version.
32694    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
32695 #define sasl_version innocuous_sasl_version
32696
32697 /* System header to define __stub macros and hopefully few prototypes,
32698     which can conflict with char sasl_version (); below.
32699     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
32700     <limits.h> exists even on freestanding compilers.  */
32701
32702 #ifdef __STDC__
32703 # include <limits.h>
32704 #else
32705 # include <assert.h>
32706 #endif
32707
32708 #undef sasl_version
32709
32710 /* Override any gcc2 internal prototype to avoid an error.  */
32711 #ifdef __cplusplus
32712 extern "C"
32713 {
32714 #endif
32715 /* We use char because int might match the return type of a gcc2
32716    builtin and then its argument prototype would still apply.  */
32717 char sasl_version ();
32718 /* The GNU C library defines this for functions which it implements
32719     to always fail with ENOSYS.  Some functions are actually named
32720     something starting with __ and the normal name is an alias.  */
32721 #if defined (__stub_sasl_version) || defined (__stub___sasl_version)
32722 choke me
32723 #else
32724 char (*f) () = sasl_version;
32725 #endif
32726 #ifdef __cplusplus
32727 }
32728 #endif
32729
32730 int
32731 main ()
32732 {
32733 return f != sasl_version;
32734   ;
32735   return 0;
32736 }
32737 _ACEOF
32738 rm -f conftest.$ac_objext conftest$ac_exeext
32739 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32740   (eval $ac_link) 2>conftest.er1
32741   ac_status=$?
32742   grep -v '^ *+' conftest.er1 >conftest.err
32743   rm -f conftest.er1
32744   cat conftest.err >&5
32745   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32746   (exit $ac_status); } &&
32747          { ac_try='test -z "$ac_c_werror_flag"
32748                          || test ! -s conftest.err'
32749   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32750   (eval $ac_try) 2>&5
32751   ac_status=$?
32752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32753   (exit $ac_status); }; } &&
32754          { ac_try='test -s conftest$ac_exeext'
32755   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32756   (eval $ac_try) 2>&5
32757   ac_status=$?
32758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32759   (exit $ac_status); }; }; then
32760   ac_cv_func_sasl_version=yes
32761 else
32762   echo "$as_me: failed program was:" >&5
32763 sed 's/^/| /' conftest.$ac_ext >&5
32764
32765 ac_cv_func_sasl_version=no
32766 fi
32767 rm -f conftest.err conftest.$ac_objext \
32768       conftest$ac_exeext conftest.$ac_ext
32769 fi
32770 echo "$as_me:$LINENO: result: $ac_cv_func_sasl_version" >&5
32771 echo "${ECHO_T}$ac_cv_func_sasl_version" >&6
32772 if test $ac_cv_func_sasl_version = yes; then
32773
32774 cat >>confdefs.h <<\_ACEOF
32775 #define HAVE_SASL_VERSION 1
32776 _ACEOF
32777
32778 fi
32779
32780                 LIBS="$ac_save_LIBS"
32781
32782                 WITH_SASL=yes
32783         fi
32784
32785 else
32786         { echo "$as_me:$LINENO: WARNING: SASL authentication not supported!" >&5
32787 echo "$as_me: WARNING: SASL authentication not supported!" >&2;}
32788         if test $ol_link_tls = no ; then
32789                 { echo "$as_me:$LINENO: WARNING: Strong authentication not supported!" >&5
32790 echo "$as_me: WARNING: Strong authentication not supported!" >&2;}
32791         fi
32792 fi
32793
32794 if test $cross_compiling != yes && test "$ac_cv_mingw32" != yes ; then
32795         dev=no
32796         if test -r /dev/urandom ; then
32797                 dev="/dev/urandom";
32798         elif test -r /idev/urandom ; then
32799                 dev="/idev/urandom";
32800         elif test -r /dev/srandom ; then
32801                 dev="/dev/srandom";
32802         elif test -r /dev/random ; then
32803                 dev="/dev/random";
32804         elif test -r /idev/random ; then
32805                 dev="/idev/random";
32806         fi
32807
32808         if test $dev != no ; then
32809
32810 cat >>confdefs.h <<_ACEOF
32811 #define URANDOM_DEVICE "$dev"
32812 _ACEOF
32813
32814         fi
32815 fi
32816
32817 ol_link_fetch=no
32818 if test $ol_with_fetch != no ; then
32819         ol_LIBS=$LIBS
32820 LIBS="-lfetch -lcom_err $LIBS"
32821 echo "$as_me:$LINENO: checking fetch(3) library" >&5
32822 echo $ECHO_N "checking fetch(3) library... $ECHO_C" >&6
32823 if test "${ol_cv_lib_fetch+set}" = set; then
32824   echo $ECHO_N "(cached) $ECHO_C" >&6
32825 else
32826
32827         cat >conftest.$ac_ext <<_ACEOF
32828 /* confdefs.h.  */
32829 _ACEOF
32830 cat confdefs.h >>conftest.$ac_ext
32831 cat >>conftest.$ac_ext <<_ACEOF
32832 /* end confdefs.h.  */
32833
32834 #include <sys/param.h>
32835 #include <stdio.h>
32836 #include <fetch.h>
32837 int
32838 main ()
32839 {
32840 struct url *u = fetchParseURL("file:///");
32841   ;
32842   return 0;
32843 }
32844 _ACEOF
32845 rm -f conftest.$ac_objext conftest$ac_exeext
32846 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32847   (eval $ac_link) 2>conftest.er1
32848   ac_status=$?
32849   grep -v '^ *+' conftest.er1 >conftest.err
32850   rm -f conftest.er1
32851   cat conftest.err >&5
32852   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32853   (exit $ac_status); } &&
32854          { ac_try='test -z "$ac_c_werror_flag"
32855                          || test ! -s conftest.err'
32856   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32857   (eval $ac_try) 2>&5
32858   ac_status=$?
32859   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32860   (exit $ac_status); }; } &&
32861          { ac_try='test -s conftest$ac_exeext'
32862   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32863   (eval $ac_try) 2>&5
32864   ac_status=$?
32865   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32866   (exit $ac_status); }; }; then
32867   ol_cv_lib_fetch=yes
32868 else
32869   echo "$as_me: failed program was:" >&5
32870 sed 's/^/| /' conftest.$ac_ext >&5
32871
32872 ol_cv_lib_fetch=no
32873 fi
32874 rm -f conftest.err conftest.$ac_objext \
32875       conftest$ac_exeext conftest.$ac_ext
32876 fi
32877 echo "$as_me:$LINENO: result: $ol_cv_lib_fetch" >&5
32878 echo "${ECHO_T}$ol_cv_lib_fetch" >&6
32879 LIBS=$ol_LIBS
32880 if test $ol_cv_lib_fetch != no ; then
32881         ol_link_fetch="-lfetch -lcom_err"
32882
32883 cat >>confdefs.h <<\_ACEOF
32884 #define HAVE_FETCH 1
32885 _ACEOF
32886
32887 fi
32888
32889
32890         if test $ol_cv_lib_fetch != no ; then
32891                 LUTIL_LIBS="$LUTIL_LIBS $ol_link_fetch"
32892                 ol_link_fetch=freebsd
32893
32894         elif test $ol_with_fetch != auto ; then
32895                 { { echo "$as_me:$LINENO: error: no suitable API for --with-fetch=$ol_with_fetch" >&5
32896 echo "$as_me: error: no suitable API for --with-fetch=$ol_with_fetch" >&2;}
32897    { (exit 1); exit 1; }; }
32898         fi
32899 fi
32900
32901 if test $ol_enable_crypt != no ; then
32902         save_LIBS="$LIBS"
32903         LIBS="$TLS_LIBS $LIBS"
32904
32905         echo "$as_me:$LINENO: checking for crypt" >&5
32906 echo $ECHO_N "checking for crypt... $ECHO_C" >&6
32907 if test "${ac_cv_func_crypt+set}" = set; then
32908   echo $ECHO_N "(cached) $ECHO_C" >&6
32909 else
32910   cat >conftest.$ac_ext <<_ACEOF
32911 /* confdefs.h.  */
32912 _ACEOF
32913 cat confdefs.h >>conftest.$ac_ext
32914 cat >>conftest.$ac_ext <<_ACEOF
32915 /* end confdefs.h.  */
32916 /* Define crypt to an innocuous variant, in case <limits.h> declares crypt.
32917    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
32918 #define crypt innocuous_crypt
32919
32920 /* System header to define __stub macros and hopefully few prototypes,
32921     which can conflict with char crypt (); below.
32922     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
32923     <limits.h> exists even on freestanding compilers.  */
32924
32925 #ifdef __STDC__
32926 # include <limits.h>
32927 #else
32928 # include <assert.h>
32929 #endif
32930
32931 #undef crypt
32932
32933 /* Override any gcc2 internal prototype to avoid an error.  */
32934 #ifdef __cplusplus
32935 extern "C"
32936 {
32937 #endif
32938 /* We use char because int might match the return type of a gcc2
32939    builtin and then its argument prototype would still apply.  */
32940 char crypt ();
32941 /* The GNU C library defines this for functions which it implements
32942     to always fail with ENOSYS.  Some functions are actually named
32943     something starting with __ and the normal name is an alias.  */
32944 #if defined (__stub_crypt) || defined (__stub___crypt)
32945 choke me
32946 #else
32947 char (*f) () = crypt;
32948 #endif
32949 #ifdef __cplusplus
32950 }
32951 #endif
32952
32953 int
32954 main ()
32955 {
32956 return f != crypt;
32957   ;
32958   return 0;
32959 }
32960 _ACEOF
32961 rm -f conftest.$ac_objext conftest$ac_exeext
32962 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32963   (eval $ac_link) 2>conftest.er1
32964   ac_status=$?
32965   grep -v '^ *+' conftest.er1 >conftest.err
32966   rm -f conftest.er1
32967   cat conftest.err >&5
32968   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32969   (exit $ac_status); } &&
32970          { ac_try='test -z "$ac_c_werror_flag"
32971                          || test ! -s conftest.err'
32972   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32973   (eval $ac_try) 2>&5
32974   ac_status=$?
32975   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32976   (exit $ac_status); }; } &&
32977          { ac_try='test -s conftest$ac_exeext'
32978   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32979   (eval $ac_try) 2>&5
32980   ac_status=$?
32981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32982   (exit $ac_status); }; }; then
32983   ac_cv_func_crypt=yes
32984 else
32985   echo "$as_me: failed program was:" >&5
32986 sed 's/^/| /' conftest.$ac_ext >&5
32987
32988 ac_cv_func_crypt=no
32989 fi
32990 rm -f conftest.err conftest.$ac_objext \
32991       conftest$ac_exeext conftest.$ac_ext
32992 fi
32993 echo "$as_me:$LINENO: result: $ac_cv_func_crypt" >&5
32994 echo "${ECHO_T}$ac_cv_func_crypt" >&6
32995 if test $ac_cv_func_crypt = yes; then
32996   have_crypt=yes
32997 else
32998
32999                 LIBS="$save_LIBS"
33000                 echo "$as_me:$LINENO: checking for crypt in -lcrypt" >&5
33001 echo $ECHO_N "checking for crypt in -lcrypt... $ECHO_C" >&6
33002 if test "${ac_cv_lib_crypt_crypt+set}" = set; then
33003   echo $ECHO_N "(cached) $ECHO_C" >&6
33004 else
33005   ac_check_lib_save_LIBS=$LIBS
33006 LIBS="-lcrypt  $LIBS"
33007 cat >conftest.$ac_ext <<_ACEOF
33008 /* confdefs.h.  */
33009 _ACEOF
33010 cat confdefs.h >>conftest.$ac_ext
33011 cat >>conftest.$ac_ext <<_ACEOF
33012 /* end confdefs.h.  */
33013
33014 /* Override any gcc2 internal prototype to avoid an error.  */
33015 #ifdef __cplusplus
33016 extern "C"
33017 #endif
33018 /* We use char because int might match the return type of a gcc2
33019    builtin and then its argument prototype would still apply.  */
33020 char crypt ();
33021 int
33022 main ()
33023 {
33024 crypt ();
33025   ;
33026   return 0;
33027 }
33028 _ACEOF
33029 rm -f conftest.$ac_objext conftest$ac_exeext
33030 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33031   (eval $ac_link) 2>conftest.er1
33032   ac_status=$?
33033   grep -v '^ *+' conftest.er1 >conftest.err
33034   rm -f conftest.er1
33035   cat conftest.err >&5
33036   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33037   (exit $ac_status); } &&
33038          { ac_try='test -z "$ac_c_werror_flag"
33039                          || test ! -s conftest.err'
33040   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33041   (eval $ac_try) 2>&5
33042   ac_status=$?
33043   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33044   (exit $ac_status); }; } &&
33045          { ac_try='test -s conftest$ac_exeext'
33046   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33047   (eval $ac_try) 2>&5
33048   ac_status=$?
33049   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33050   (exit $ac_status); }; }; then
33051   ac_cv_lib_crypt_crypt=yes
33052 else
33053   echo "$as_me: failed program was:" >&5
33054 sed 's/^/| /' conftest.$ac_ext >&5
33055
33056 ac_cv_lib_crypt_crypt=no
33057 fi
33058 rm -f conftest.err conftest.$ac_objext \
33059       conftest$ac_exeext conftest.$ac_ext
33060 LIBS=$ac_check_lib_save_LIBS
33061 fi
33062 echo "$as_me:$LINENO: result: $ac_cv_lib_crypt_crypt" >&5
33063 echo "${ECHO_T}$ac_cv_lib_crypt_crypt" >&6
33064 if test $ac_cv_lib_crypt_crypt = yes; then
33065   LUTIL_LIBS="$LUTIL_LIBS -lcrypt"
33066                         have_crypt=yes
33067 else
33068   have_crypt=no
33069 fi
33070
33071 fi
33072
33073
33074         LIBS="$save_LIBS"
33075
33076         if test $have_crypt = yes ; then
33077
33078 cat >>confdefs.h <<\_ACEOF
33079 #define HAVE_CRYPT 1
33080 _ACEOF
33081
33082         else
33083                 { echo "$as_me:$LINENO: WARNING: could not find crypt" >&5
33084 echo "$as_me: WARNING: could not find crypt" >&2;}
33085                 if test $ol_enable_crypt = yes ; then
33086                         { { echo "$as_me:$LINENO: error: could not find crypt, select appropriate options or disable" >&5
33087 echo "$as_me: error: could not find crypt, select appropriate options or disable" >&2;}
33088    { (exit 1); exit 1; }; }
33089                 fi
33090
33091                 { echo "$as_me:$LINENO: WARNING: disabling crypt support" >&5
33092 echo "$as_me: WARNING: disabling crypt support" >&2;}
33093                 ol_enable_crypt=no
33094         fi
33095 fi
33096
33097 if test $ol_enable_proctitle != no ; then
33098         echo "$as_me:$LINENO: checking for setproctitle" >&5
33099 echo $ECHO_N "checking for setproctitle... $ECHO_C" >&6
33100 if test "${ac_cv_func_setproctitle+set}" = set; then
33101   echo $ECHO_N "(cached) $ECHO_C" >&6
33102 else
33103   cat >conftest.$ac_ext <<_ACEOF
33104 /* confdefs.h.  */
33105 _ACEOF
33106 cat confdefs.h >>conftest.$ac_ext
33107 cat >>conftest.$ac_ext <<_ACEOF
33108 /* end confdefs.h.  */
33109 /* Define setproctitle to an innocuous variant, in case <limits.h> declares setproctitle.
33110    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
33111 #define setproctitle innocuous_setproctitle
33112
33113 /* System header to define __stub macros and hopefully few prototypes,
33114     which can conflict with char setproctitle (); below.
33115     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
33116     <limits.h> exists even on freestanding compilers.  */
33117
33118 #ifdef __STDC__
33119 # include <limits.h>
33120 #else
33121 # include <assert.h>
33122 #endif
33123
33124 #undef setproctitle
33125
33126 /* Override any gcc2 internal prototype to avoid an error.  */
33127 #ifdef __cplusplus
33128 extern "C"
33129 {
33130 #endif
33131 /* We use char because int might match the return type of a gcc2
33132    builtin and then its argument prototype would still apply.  */
33133 char setproctitle ();
33134 /* The GNU C library defines this for functions which it implements
33135     to always fail with ENOSYS.  Some functions are actually named
33136     something starting with __ and the normal name is an alias.  */
33137 #if defined (__stub_setproctitle) || defined (__stub___setproctitle)
33138 choke me
33139 #else
33140 char (*f) () = setproctitle;
33141 #endif
33142 #ifdef __cplusplus
33143 }
33144 #endif
33145
33146 int
33147 main ()
33148 {
33149 return f != setproctitle;
33150   ;
33151   return 0;
33152 }
33153 _ACEOF
33154 rm -f conftest.$ac_objext conftest$ac_exeext
33155 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33156   (eval $ac_link) 2>conftest.er1
33157   ac_status=$?
33158   grep -v '^ *+' conftest.er1 >conftest.err
33159   rm -f conftest.er1
33160   cat conftest.err >&5
33161   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33162   (exit $ac_status); } &&
33163          { ac_try='test -z "$ac_c_werror_flag"
33164                          || test ! -s conftest.err'
33165   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33166   (eval $ac_try) 2>&5
33167   ac_status=$?
33168   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33169   (exit $ac_status); }; } &&
33170          { ac_try='test -s conftest$ac_exeext'
33171   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33172   (eval $ac_try) 2>&5
33173   ac_status=$?
33174   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33175   (exit $ac_status); }; }; then
33176   ac_cv_func_setproctitle=yes
33177 else
33178   echo "$as_me: failed program was:" >&5
33179 sed 's/^/| /' conftest.$ac_ext >&5
33180
33181 ac_cv_func_setproctitle=no
33182 fi
33183 rm -f conftest.err conftest.$ac_objext \
33184       conftest$ac_exeext conftest.$ac_ext
33185 fi
33186 echo "$as_me:$LINENO: result: $ac_cv_func_setproctitle" >&5
33187 echo "${ECHO_T}$ac_cv_func_setproctitle" >&6
33188 if test $ac_cv_func_setproctitle = yes; then
33189   have_setproctitle=yes
33190 else
33191
33192                 echo "$as_me:$LINENO: checking for setproctitle in -lutil" >&5
33193 echo $ECHO_N "checking for setproctitle in -lutil... $ECHO_C" >&6
33194 if test "${ac_cv_lib_util_setproctitle+set}" = set; then
33195   echo $ECHO_N "(cached) $ECHO_C" >&6
33196 else
33197   ac_check_lib_save_LIBS=$LIBS
33198 LIBS="-lutil  $LIBS"
33199 cat >conftest.$ac_ext <<_ACEOF
33200 /* confdefs.h.  */
33201 _ACEOF
33202 cat confdefs.h >>conftest.$ac_ext
33203 cat >>conftest.$ac_ext <<_ACEOF
33204 /* end confdefs.h.  */
33205
33206 /* Override any gcc2 internal prototype to avoid an error.  */
33207 #ifdef __cplusplus
33208 extern "C"
33209 #endif
33210 /* We use char because int might match the return type of a gcc2
33211    builtin and then its argument prototype would still apply.  */
33212 char setproctitle ();
33213 int
33214 main ()
33215 {
33216 setproctitle ();
33217   ;
33218   return 0;
33219 }
33220 _ACEOF
33221 rm -f conftest.$ac_objext conftest$ac_exeext
33222 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33223   (eval $ac_link) 2>conftest.er1
33224   ac_status=$?
33225   grep -v '^ *+' conftest.er1 >conftest.err
33226   rm -f conftest.er1
33227   cat conftest.err >&5
33228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33229   (exit $ac_status); } &&
33230          { ac_try='test -z "$ac_c_werror_flag"
33231                          || test ! -s conftest.err'
33232   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33233   (eval $ac_try) 2>&5
33234   ac_status=$?
33235   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33236   (exit $ac_status); }; } &&
33237          { ac_try='test -s conftest$ac_exeext'
33238   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33239   (eval $ac_try) 2>&5
33240   ac_status=$?
33241   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33242   (exit $ac_status); }; }; then
33243   ac_cv_lib_util_setproctitle=yes
33244 else
33245   echo "$as_me: failed program was:" >&5
33246 sed 's/^/| /' conftest.$ac_ext >&5
33247
33248 ac_cv_lib_util_setproctitle=no
33249 fi
33250 rm -f conftest.err conftest.$ac_objext \
33251       conftest$ac_exeext conftest.$ac_ext
33252 LIBS=$ac_check_lib_save_LIBS
33253 fi
33254 echo "$as_me:$LINENO: result: $ac_cv_lib_util_setproctitle" >&5
33255 echo "${ECHO_T}$ac_cv_lib_util_setproctitle" >&6
33256 if test $ac_cv_lib_util_setproctitle = yes; then
33257   have_setproctitle=yes
33258                         LUTIL_LIBS="$LUTIL_LIBS -lutil"
33259 else
33260   have_setproctitle=no
33261                         case $LIBOBJS in
33262     "setproctitle.$ac_objext"   | \
33263   *" setproctitle.$ac_objext"   | \
33264     "setproctitle.$ac_objext "* | \
33265   *" setproctitle.$ac_objext "* ) ;;
33266   *) LIBOBJS="$LIBOBJS setproctitle.$ac_objext" ;;
33267 esac
33268
33269                         LIBSRCS="$LIBSRCS setproctitle.c"
33270 fi
33271
33272 fi
33273
33274
33275         if test $have_setproctitle = yes ; then
33276
33277 cat >>confdefs.h <<\_ACEOF
33278 #define HAVE_SETPROCTITLE 1
33279 _ACEOF
33280
33281         fi
33282 fi
33283
33284 if test $ol_enable_slp != no ; then
33285
33286 for ac_header in slp.h
33287 do
33288 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
33289 if eval "test \"\${$as_ac_Header+set}\" = set"; then
33290   echo "$as_me:$LINENO: checking for $ac_header" >&5
33291 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
33292 if eval "test \"\${$as_ac_Header+set}\" = set"; then
33293   echo $ECHO_N "(cached) $ECHO_C" >&6
33294 fi
33295 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
33296 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
33297 else
33298   # Is the header compilable?
33299 echo "$as_me:$LINENO: checking $ac_header usability" >&5
33300 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
33301 cat >conftest.$ac_ext <<_ACEOF
33302 /* confdefs.h.  */
33303 _ACEOF
33304 cat confdefs.h >>conftest.$ac_ext
33305 cat >>conftest.$ac_ext <<_ACEOF
33306 /* end confdefs.h.  */
33307 $ac_includes_default
33308 #include <$ac_header>
33309 _ACEOF
33310 rm -f conftest.$ac_objext
33311 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33312   (eval $ac_compile) 2>conftest.er1
33313   ac_status=$?
33314   grep -v '^ *+' conftest.er1 >conftest.err
33315   rm -f conftest.er1
33316   cat conftest.err >&5
33317   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33318   (exit $ac_status); } &&
33319          { ac_try='test -z "$ac_c_werror_flag"
33320                          || test ! -s conftest.err'
33321   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33322   (eval $ac_try) 2>&5
33323   ac_status=$?
33324   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33325   (exit $ac_status); }; } &&
33326          { ac_try='test -s conftest.$ac_objext'
33327   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33328   (eval $ac_try) 2>&5
33329   ac_status=$?
33330   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33331   (exit $ac_status); }; }; then
33332   ac_header_compiler=yes
33333 else
33334   echo "$as_me: failed program was:" >&5
33335 sed 's/^/| /' conftest.$ac_ext >&5
33336
33337 ac_header_compiler=no
33338 fi
33339 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33340 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
33341 echo "${ECHO_T}$ac_header_compiler" >&6
33342
33343 # Is the header present?
33344 echo "$as_me:$LINENO: checking $ac_header presence" >&5
33345 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
33346 cat >conftest.$ac_ext <<_ACEOF
33347 /* confdefs.h.  */
33348 _ACEOF
33349 cat confdefs.h >>conftest.$ac_ext
33350 cat >>conftest.$ac_ext <<_ACEOF
33351 /* end confdefs.h.  */
33352 #include <$ac_header>
33353 _ACEOF
33354 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
33355   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
33356   ac_status=$?
33357   grep -v '^ *+' conftest.er1 >conftest.err
33358   rm -f conftest.er1
33359   cat conftest.err >&5
33360   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33361   (exit $ac_status); } >/dev/null; then
33362   if test -s conftest.err; then
33363     ac_cpp_err=$ac_c_preproc_warn_flag
33364     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
33365   else
33366     ac_cpp_err=
33367   fi
33368 else
33369   ac_cpp_err=yes
33370 fi
33371 if test -z "$ac_cpp_err"; then
33372   ac_header_preproc=yes
33373 else
33374   echo "$as_me: failed program was:" >&5
33375 sed 's/^/| /' conftest.$ac_ext >&5
33376
33377   ac_header_preproc=no
33378 fi
33379 rm -f conftest.err conftest.$ac_ext
33380 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
33381 echo "${ECHO_T}$ac_header_preproc" >&6
33382
33383 # So?  What about this header?
33384 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
33385   yes:no: )
33386     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
33387 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
33388     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
33389 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
33390     ac_header_preproc=yes
33391     ;;
33392   no:yes:* )
33393     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
33394 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
33395     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
33396 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
33397     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
33398 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
33399     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
33400 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
33401     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
33402 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
33403     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
33404 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
33405     (
33406       cat <<\_ASBOX
33407 ## --------------------------------------------- ##
33408 ## Report this to <http://www.openldap.org/its/> ##
33409 ## --------------------------------------------- ##
33410 _ASBOX
33411     ) |
33412       sed "s/^/$as_me: WARNING:     /" >&2
33413     ;;
33414 esac
33415 echo "$as_me:$LINENO: checking for $ac_header" >&5
33416 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
33417 if eval "test \"\${$as_ac_Header+set}\" = set"; then
33418   echo $ECHO_N "(cached) $ECHO_C" >&6
33419 else
33420   eval "$as_ac_Header=\$ac_header_preproc"
33421 fi
33422 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
33423 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
33424
33425 fi
33426 if test `eval echo '${'$as_ac_Header'}'` = yes; then
33427   cat >>confdefs.h <<_ACEOF
33428 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
33429 _ACEOF
33430
33431 fi
33432
33433 done
33434
33435
33436         if test $ac_cv_header_slp_h = yes ; then
33437                 echo "$as_me:$LINENO: checking for SLPOpen in -lslp" >&5
33438 echo $ECHO_N "checking for SLPOpen in -lslp... $ECHO_C" >&6
33439 if test "${ac_cv_lib_slp_SLPOpen+set}" = set; then
33440   echo $ECHO_N "(cached) $ECHO_C" >&6
33441 else
33442   ac_check_lib_save_LIBS=$LIBS
33443 LIBS="-lslp  $LIBS"
33444 cat >conftest.$ac_ext <<_ACEOF
33445 /* confdefs.h.  */
33446 _ACEOF
33447 cat confdefs.h >>conftest.$ac_ext
33448 cat >>conftest.$ac_ext <<_ACEOF
33449 /* end confdefs.h.  */
33450
33451 /* Override any gcc2 internal prototype to avoid an error.  */
33452 #ifdef __cplusplus
33453 extern "C"
33454 #endif
33455 /* We use char because int might match the return type of a gcc2
33456    builtin and then its argument prototype would still apply.  */
33457 char SLPOpen ();
33458 int
33459 main ()
33460 {
33461 SLPOpen ();
33462   ;
33463   return 0;
33464 }
33465 _ACEOF
33466 rm -f conftest.$ac_objext conftest$ac_exeext
33467 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33468   (eval $ac_link) 2>conftest.er1
33469   ac_status=$?
33470   grep -v '^ *+' conftest.er1 >conftest.err
33471   rm -f conftest.er1
33472   cat conftest.err >&5
33473   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33474   (exit $ac_status); } &&
33475          { ac_try='test -z "$ac_c_werror_flag"
33476                          || test ! -s conftest.err'
33477   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33478   (eval $ac_try) 2>&5
33479   ac_status=$?
33480   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33481   (exit $ac_status); }; } &&
33482          { ac_try='test -s conftest$ac_exeext'
33483   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33484   (eval $ac_try) 2>&5
33485   ac_status=$?
33486   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33487   (exit $ac_status); }; }; then
33488   ac_cv_lib_slp_SLPOpen=yes
33489 else
33490   echo "$as_me: failed program was:" >&5
33491 sed 's/^/| /' conftest.$ac_ext >&5
33492
33493 ac_cv_lib_slp_SLPOpen=no
33494 fi
33495 rm -f conftest.err conftest.$ac_objext \
33496       conftest$ac_exeext conftest.$ac_ext
33497 LIBS=$ac_check_lib_save_LIBS
33498 fi
33499 echo "$as_me:$LINENO: result: $ac_cv_lib_slp_SLPOpen" >&5
33500 echo "${ECHO_T}$ac_cv_lib_slp_SLPOpen" >&6
33501 if test $ac_cv_lib_slp_SLPOpen = yes; then
33502   have_slp=yes
33503 else
33504   have_slp=no
33505 fi
33506
33507                 if test $have_slp = yes ; then
33508
33509 cat >>confdefs.h <<\_ACEOF
33510 #define HAVE_SLP 1
33511 _ACEOF
33512
33513                         SLAPD_SLP_LIBS=-lslp
33514                 fi
33515
33516         elif test $ol_enable_slp = yes ; then
33517                 { { echo "$as_me:$LINENO: error: SLP not found" >&5
33518 echo "$as_me: error: SLP not found" >&2;}
33519    { (exit 1); exit 1; }; }
33520         fi
33521 fi
33522
33523
33524 echo "$as_me:$LINENO: checking for mode_t" >&5
33525 echo $ECHO_N "checking for mode_t... $ECHO_C" >&6
33526 if test "${ac_cv_type_mode_t+set}" = set; then
33527   echo $ECHO_N "(cached) $ECHO_C" >&6
33528 else
33529   cat >conftest.$ac_ext <<_ACEOF
33530 /* confdefs.h.  */
33531 _ACEOF
33532 cat confdefs.h >>conftest.$ac_ext
33533 cat >>conftest.$ac_ext <<_ACEOF
33534 /* end confdefs.h.  */
33535 $ac_includes_default
33536 int
33537 main ()
33538 {
33539 if ((mode_t *) 0)
33540   return 0;
33541 if (sizeof (mode_t))
33542   return 0;
33543   ;
33544   return 0;
33545 }
33546 _ACEOF
33547 rm -f conftest.$ac_objext
33548 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33549   (eval $ac_compile) 2>conftest.er1
33550   ac_status=$?
33551   grep -v '^ *+' conftest.er1 >conftest.err
33552   rm -f conftest.er1
33553   cat conftest.err >&5
33554   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33555   (exit $ac_status); } &&
33556          { ac_try='test -z "$ac_c_werror_flag"
33557                          || test ! -s conftest.err'
33558   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33559   (eval $ac_try) 2>&5
33560   ac_status=$?
33561   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33562   (exit $ac_status); }; } &&
33563          { ac_try='test -s conftest.$ac_objext'
33564   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33565   (eval $ac_try) 2>&5
33566   ac_status=$?
33567   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33568   (exit $ac_status); }; }; then
33569   ac_cv_type_mode_t=yes
33570 else
33571   echo "$as_me: failed program was:" >&5
33572 sed 's/^/| /' conftest.$ac_ext >&5
33573
33574 ac_cv_type_mode_t=no
33575 fi
33576 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33577 fi
33578 echo "$as_me:$LINENO: result: $ac_cv_type_mode_t" >&5
33579 echo "${ECHO_T}$ac_cv_type_mode_t" >&6
33580 if test $ac_cv_type_mode_t = yes; then
33581   :
33582 else
33583
33584 cat >>confdefs.h <<_ACEOF
33585 #define mode_t int
33586 _ACEOF
33587
33588 fi
33589
33590 echo "$as_me:$LINENO: checking for off_t" >&5
33591 echo $ECHO_N "checking for off_t... $ECHO_C" >&6
33592 if test "${ac_cv_type_off_t+set}" = set; then
33593   echo $ECHO_N "(cached) $ECHO_C" >&6
33594 else
33595   cat >conftest.$ac_ext <<_ACEOF
33596 /* confdefs.h.  */
33597 _ACEOF
33598 cat confdefs.h >>conftest.$ac_ext
33599 cat >>conftest.$ac_ext <<_ACEOF
33600 /* end confdefs.h.  */
33601 $ac_includes_default
33602 int
33603 main ()
33604 {
33605 if ((off_t *) 0)
33606   return 0;
33607 if (sizeof (off_t))
33608   return 0;
33609   ;
33610   return 0;
33611 }
33612 _ACEOF
33613 rm -f conftest.$ac_objext
33614 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33615   (eval $ac_compile) 2>conftest.er1
33616   ac_status=$?
33617   grep -v '^ *+' conftest.er1 >conftest.err
33618   rm -f conftest.er1
33619   cat conftest.err >&5
33620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33621   (exit $ac_status); } &&
33622          { ac_try='test -z "$ac_c_werror_flag"
33623                          || test ! -s conftest.err'
33624   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33625   (eval $ac_try) 2>&5
33626   ac_status=$?
33627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33628   (exit $ac_status); }; } &&
33629          { ac_try='test -s conftest.$ac_objext'
33630   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33631   (eval $ac_try) 2>&5
33632   ac_status=$?
33633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33634   (exit $ac_status); }; }; then
33635   ac_cv_type_off_t=yes
33636 else
33637   echo "$as_me: failed program was:" >&5
33638 sed 's/^/| /' conftest.$ac_ext >&5
33639
33640 ac_cv_type_off_t=no
33641 fi
33642 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33643 fi
33644 echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
33645 echo "${ECHO_T}$ac_cv_type_off_t" >&6
33646 if test $ac_cv_type_off_t = yes; then
33647   :
33648 else
33649
33650 cat >>confdefs.h <<_ACEOF
33651 #define off_t long
33652 _ACEOF
33653
33654 fi
33655
33656 echo "$as_me:$LINENO: checking for pid_t" >&5
33657 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
33658 if test "${ac_cv_type_pid_t+set}" = set; then
33659   echo $ECHO_N "(cached) $ECHO_C" >&6
33660 else
33661   cat >conftest.$ac_ext <<_ACEOF
33662 /* confdefs.h.  */
33663 _ACEOF
33664 cat confdefs.h >>conftest.$ac_ext
33665 cat >>conftest.$ac_ext <<_ACEOF
33666 /* end confdefs.h.  */
33667 $ac_includes_default
33668 int
33669 main ()
33670 {
33671 if ((pid_t *) 0)
33672   return 0;
33673 if (sizeof (pid_t))
33674   return 0;
33675   ;
33676   return 0;
33677 }
33678 _ACEOF
33679 rm -f conftest.$ac_objext
33680 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33681   (eval $ac_compile) 2>conftest.er1
33682   ac_status=$?
33683   grep -v '^ *+' conftest.er1 >conftest.err
33684   rm -f conftest.er1
33685   cat conftest.err >&5
33686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33687   (exit $ac_status); } &&
33688          { ac_try='test -z "$ac_c_werror_flag"
33689                          || test ! -s conftest.err'
33690   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33691   (eval $ac_try) 2>&5
33692   ac_status=$?
33693   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33694   (exit $ac_status); }; } &&
33695          { ac_try='test -s conftest.$ac_objext'
33696   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33697   (eval $ac_try) 2>&5
33698   ac_status=$?
33699   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33700   (exit $ac_status); }; }; then
33701   ac_cv_type_pid_t=yes
33702 else
33703   echo "$as_me: failed program was:" >&5
33704 sed 's/^/| /' conftest.$ac_ext >&5
33705
33706 ac_cv_type_pid_t=no
33707 fi
33708 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33709 fi
33710 echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
33711 echo "${ECHO_T}$ac_cv_type_pid_t" >&6
33712 if test $ac_cv_type_pid_t = yes; then
33713   :
33714 else
33715
33716 cat >>confdefs.h <<_ACEOF
33717 #define pid_t int
33718 _ACEOF
33719
33720 fi
33721
33722 echo "$as_me:$LINENO: checking for ssize_t" >&5
33723 echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6
33724 if test "${ac_cv_type_ssize_t+set}" = set; then
33725   echo $ECHO_N "(cached) $ECHO_C" >&6
33726 else
33727   cat >conftest.$ac_ext <<_ACEOF
33728 /* confdefs.h.  */
33729 _ACEOF
33730 cat confdefs.h >>conftest.$ac_ext
33731 cat >>conftest.$ac_ext <<_ACEOF
33732 /* end confdefs.h.  */
33733 $ac_includes_default
33734 int
33735 main ()
33736 {
33737 if ((ssize_t *) 0)
33738   return 0;
33739 if (sizeof (ssize_t))
33740   return 0;
33741   ;
33742   return 0;
33743 }
33744 _ACEOF
33745 rm -f conftest.$ac_objext
33746 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33747   (eval $ac_compile) 2>conftest.er1
33748   ac_status=$?
33749   grep -v '^ *+' conftest.er1 >conftest.err
33750   rm -f conftest.er1
33751   cat conftest.err >&5
33752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33753   (exit $ac_status); } &&
33754          { ac_try='test -z "$ac_c_werror_flag"
33755                          || test ! -s conftest.err'
33756   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33757   (eval $ac_try) 2>&5
33758   ac_status=$?
33759   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33760   (exit $ac_status); }; } &&
33761          { ac_try='test -s conftest.$ac_objext'
33762   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33763   (eval $ac_try) 2>&5
33764   ac_status=$?
33765   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33766   (exit $ac_status); }; }; then
33767   ac_cv_type_ssize_t=yes
33768 else
33769   echo "$as_me: failed program was:" >&5
33770 sed 's/^/| /' conftest.$ac_ext >&5
33771
33772 ac_cv_type_ssize_t=no
33773 fi
33774 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33775 fi
33776 echo "$as_me:$LINENO: result: $ac_cv_type_ssize_t" >&5
33777 echo "${ECHO_T}$ac_cv_type_ssize_t" >&6
33778 if test $ac_cv_type_ssize_t = yes; then
33779   :
33780 else
33781
33782 cat >>confdefs.h <<_ACEOF
33783 #define ssize_t signed int
33784 _ACEOF
33785
33786 fi
33787
33788 echo "$as_me:$LINENO: checking for caddr_t" >&5
33789 echo $ECHO_N "checking for caddr_t... $ECHO_C" >&6
33790 if test "${ac_cv_type_caddr_t+set}" = set; then
33791   echo $ECHO_N "(cached) $ECHO_C" >&6
33792 else
33793   cat >conftest.$ac_ext <<_ACEOF
33794 /* confdefs.h.  */
33795 _ACEOF
33796 cat confdefs.h >>conftest.$ac_ext
33797 cat >>conftest.$ac_ext <<_ACEOF
33798 /* end confdefs.h.  */
33799 $ac_includes_default
33800 int
33801 main ()
33802 {
33803 if ((caddr_t *) 0)
33804   return 0;
33805 if (sizeof (caddr_t))
33806   return 0;
33807   ;
33808   return 0;
33809 }
33810 _ACEOF
33811 rm -f conftest.$ac_objext
33812 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33813   (eval $ac_compile) 2>conftest.er1
33814   ac_status=$?
33815   grep -v '^ *+' conftest.er1 >conftest.err
33816   rm -f conftest.er1
33817   cat conftest.err >&5
33818   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33819   (exit $ac_status); } &&
33820          { ac_try='test -z "$ac_c_werror_flag"
33821                          || test ! -s conftest.err'
33822   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33823   (eval $ac_try) 2>&5
33824   ac_status=$?
33825   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33826   (exit $ac_status); }; } &&
33827          { ac_try='test -s conftest.$ac_objext'
33828   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33829   (eval $ac_try) 2>&5
33830   ac_status=$?
33831   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33832   (exit $ac_status); }; }; then
33833   ac_cv_type_caddr_t=yes
33834 else
33835   echo "$as_me: failed program was:" >&5
33836 sed 's/^/| /' conftest.$ac_ext >&5
33837
33838 ac_cv_type_caddr_t=no
33839 fi
33840 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33841 fi
33842 echo "$as_me:$LINENO: result: $ac_cv_type_caddr_t" >&5
33843 echo "${ECHO_T}$ac_cv_type_caddr_t" >&6
33844 if test $ac_cv_type_caddr_t = yes; then
33845   :
33846 else
33847
33848 cat >>confdefs.h <<_ACEOF
33849 #define caddr_t char *
33850 _ACEOF
33851
33852 fi
33853
33854 echo "$as_me:$LINENO: checking for size_t" >&5
33855 echo $ECHO_N "checking for size_t... $ECHO_C" >&6
33856 if test "${ac_cv_type_size_t+set}" = set; then
33857   echo $ECHO_N "(cached) $ECHO_C" >&6
33858 else
33859   cat >conftest.$ac_ext <<_ACEOF
33860 /* confdefs.h.  */
33861 _ACEOF
33862 cat confdefs.h >>conftest.$ac_ext
33863 cat >>conftest.$ac_ext <<_ACEOF
33864 /* end confdefs.h.  */
33865 $ac_includes_default
33866 int
33867 main ()
33868 {
33869 if ((size_t *) 0)
33870   return 0;
33871 if (sizeof (size_t))
33872   return 0;
33873   ;
33874   return 0;
33875 }
33876 _ACEOF
33877 rm -f conftest.$ac_objext
33878 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33879   (eval $ac_compile) 2>conftest.er1
33880   ac_status=$?
33881   grep -v '^ *+' conftest.er1 >conftest.err
33882   rm -f conftest.er1
33883   cat conftest.err >&5
33884   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33885   (exit $ac_status); } &&
33886          { ac_try='test -z "$ac_c_werror_flag"
33887                          || test ! -s conftest.err'
33888   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33889   (eval $ac_try) 2>&5
33890   ac_status=$?
33891   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33892   (exit $ac_status); }; } &&
33893          { ac_try='test -s conftest.$ac_objext'
33894   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33895   (eval $ac_try) 2>&5
33896   ac_status=$?
33897   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33898   (exit $ac_status); }; }; then
33899   ac_cv_type_size_t=yes
33900 else
33901   echo "$as_me: failed program was:" >&5
33902 sed 's/^/| /' conftest.$ac_ext >&5
33903
33904 ac_cv_type_size_t=no
33905 fi
33906 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33907 fi
33908 echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
33909 echo "${ECHO_T}$ac_cv_type_size_t" >&6
33910 if test $ac_cv_type_size_t = yes; then
33911   :
33912 else
33913
33914 cat >>confdefs.h <<_ACEOF
33915 #define size_t unsigned
33916 _ACEOF
33917
33918 fi
33919
33920
33921 echo "$as_me:$LINENO: checking for long long" >&5
33922 echo $ECHO_N "checking for long long... $ECHO_C" >&6
33923 if test "${ac_cv_type_long_long+set}" = set; then
33924   echo $ECHO_N "(cached) $ECHO_C" >&6
33925 else
33926   cat >conftest.$ac_ext <<_ACEOF
33927 /* confdefs.h.  */
33928 _ACEOF
33929 cat confdefs.h >>conftest.$ac_ext
33930 cat >>conftest.$ac_ext <<_ACEOF
33931 /* end confdefs.h.  */
33932 $ac_includes_default
33933 int
33934 main ()
33935 {
33936 if ((long long *) 0)
33937   return 0;
33938 if (sizeof (long long))
33939   return 0;
33940   ;
33941   return 0;
33942 }
33943 _ACEOF
33944 rm -f conftest.$ac_objext
33945 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33946   (eval $ac_compile) 2>conftest.er1
33947   ac_status=$?
33948   grep -v '^ *+' conftest.er1 >conftest.err
33949   rm -f conftest.er1
33950   cat conftest.err >&5
33951   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33952   (exit $ac_status); } &&
33953          { ac_try='test -z "$ac_c_werror_flag"
33954                          || test ! -s conftest.err'
33955   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33956   (eval $ac_try) 2>&5
33957   ac_status=$?
33958   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33959   (exit $ac_status); }; } &&
33960          { ac_try='test -s conftest.$ac_objext'
33961   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33962   (eval $ac_try) 2>&5
33963   ac_status=$?
33964   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33965   (exit $ac_status); }; }; then
33966   ac_cv_type_long_long=yes
33967 else
33968   echo "$as_me: failed program was:" >&5
33969 sed 's/^/| /' conftest.$ac_ext >&5
33970
33971 ac_cv_type_long_long=no
33972 fi
33973 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33974 fi
33975 echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
33976 echo "${ECHO_T}$ac_cv_type_long_long" >&6
33977 if test $ac_cv_type_long_long = yes; then
33978
33979 cat >>confdefs.h <<_ACEOF
33980 #define HAVE_LONG_LONG 1
33981 _ACEOF
33982
33983
33984 fi
33985
33986 echo "$as_me:$LINENO: checking for ptrdiff_t" >&5
33987 echo $ECHO_N "checking for ptrdiff_t... $ECHO_C" >&6
33988 if test "${ac_cv_type_ptrdiff_t+set}" = set; then
33989   echo $ECHO_N "(cached) $ECHO_C" >&6
33990 else
33991   cat >conftest.$ac_ext <<_ACEOF
33992 /* confdefs.h.  */
33993 _ACEOF
33994 cat confdefs.h >>conftest.$ac_ext
33995 cat >>conftest.$ac_ext <<_ACEOF
33996 /* end confdefs.h.  */
33997 $ac_includes_default
33998 int
33999 main ()
34000 {
34001 if ((ptrdiff_t *) 0)
34002   return 0;
34003 if (sizeof (ptrdiff_t))
34004   return 0;
34005   ;
34006   return 0;
34007 }
34008 _ACEOF
34009 rm -f conftest.$ac_objext
34010 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34011   (eval $ac_compile) 2>conftest.er1
34012   ac_status=$?
34013   grep -v '^ *+' conftest.er1 >conftest.err
34014   rm -f conftest.er1
34015   cat conftest.err >&5
34016   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34017   (exit $ac_status); } &&
34018          { ac_try='test -z "$ac_c_werror_flag"
34019                          || test ! -s conftest.err'
34020   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34021   (eval $ac_try) 2>&5
34022   ac_status=$?
34023   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34024   (exit $ac_status); }; } &&
34025          { ac_try='test -s conftest.$ac_objext'
34026   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34027   (eval $ac_try) 2>&5
34028   ac_status=$?
34029   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34030   (exit $ac_status); }; }; then
34031   ac_cv_type_ptrdiff_t=yes
34032 else
34033   echo "$as_me: failed program was:" >&5
34034 sed 's/^/| /' conftest.$ac_ext >&5
34035
34036 ac_cv_type_ptrdiff_t=no
34037 fi
34038 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34039 fi
34040 echo "$as_me:$LINENO: result: $ac_cv_type_ptrdiff_t" >&5
34041 echo "${ECHO_T}$ac_cv_type_ptrdiff_t" >&6
34042 if test $ac_cv_type_ptrdiff_t = yes; then
34043
34044 cat >>confdefs.h <<_ACEOF
34045 #define HAVE_PTRDIFF_T 1
34046 _ACEOF
34047
34048
34049 fi
34050
34051
34052 echo "$as_me:$LINENO: checking for socklen_t" >&5
34053 echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6
34054 if test "${ac_cv_type_socklen_t+set}" = set; then
34055   echo $ECHO_N "(cached) $ECHO_C" >&6
34056 else
34057   cat >conftest.$ac_ext <<_ACEOF
34058 /* confdefs.h.  */
34059 _ACEOF
34060 cat confdefs.h >>conftest.$ac_ext
34061 cat >>conftest.$ac_ext <<_ACEOF
34062 /* end confdefs.h.  */
34063 $ac_includes_default
34064 #ifdef HAVE_SYS_SOCKET_H
34065 #include <sys/socket.h>
34066 #endif
34067
34068
34069 int
34070 main ()
34071 {
34072 if ((socklen_t *) 0)
34073   return 0;
34074 if (sizeof (socklen_t))
34075   return 0;
34076   ;
34077   return 0;
34078 }
34079 _ACEOF
34080 rm -f conftest.$ac_objext
34081 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34082   (eval $ac_compile) 2>conftest.er1
34083   ac_status=$?
34084   grep -v '^ *+' conftest.er1 >conftest.err
34085   rm -f conftest.er1
34086   cat conftest.err >&5
34087   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34088   (exit $ac_status); } &&
34089          { ac_try='test -z "$ac_c_werror_flag"
34090                          || test ! -s conftest.err'
34091   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34092   (eval $ac_try) 2>&5
34093   ac_status=$?
34094   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34095   (exit $ac_status); }; } &&
34096          { ac_try='test -s conftest.$ac_objext'
34097   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34098   (eval $ac_try) 2>&5
34099   ac_status=$?
34100   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34101   (exit $ac_status); }; }; then
34102   ac_cv_type_socklen_t=yes
34103 else
34104   echo "$as_me: failed program was:" >&5
34105 sed 's/^/| /' conftest.$ac_ext >&5
34106
34107 ac_cv_type_socklen_t=no
34108 fi
34109 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34110 fi
34111 echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5
34112 echo "${ECHO_T}$ac_cv_type_socklen_t" >&6
34113 if test $ac_cv_type_socklen_t = yes; then
34114   :
34115 else
34116
34117 cat >>confdefs.h <<_ACEOF
34118 #define socklen_t int
34119 _ACEOF
34120
34121 fi
34122
34123
34124 echo "$as_me:$LINENO: checking return type of signal handlers" >&5
34125 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
34126 if test "${ac_cv_type_signal+set}" = set; then
34127   echo $ECHO_N "(cached) $ECHO_C" >&6
34128 else
34129   cat >conftest.$ac_ext <<_ACEOF
34130 /* confdefs.h.  */
34131 _ACEOF
34132 cat confdefs.h >>conftest.$ac_ext
34133 cat >>conftest.$ac_ext <<_ACEOF
34134 /* end confdefs.h.  */
34135 #include <sys/types.h>
34136 #include <signal.h>
34137 #ifdef signal
34138 # undef signal
34139 #endif
34140 #ifdef __cplusplus
34141 extern "C" void (*signal (int, void (*)(int)))(int);
34142 #else
34143 void (*signal ()) ();
34144 #endif
34145
34146 int
34147 main ()
34148 {
34149 int i;
34150   ;
34151   return 0;
34152 }
34153 _ACEOF
34154 rm -f conftest.$ac_objext
34155 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34156   (eval $ac_compile) 2>conftest.er1
34157   ac_status=$?
34158   grep -v '^ *+' conftest.er1 >conftest.err
34159   rm -f conftest.er1
34160   cat conftest.err >&5
34161   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34162   (exit $ac_status); } &&
34163          { ac_try='test -z "$ac_c_werror_flag"
34164                          || test ! -s conftest.err'
34165   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34166   (eval $ac_try) 2>&5
34167   ac_status=$?
34168   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34169   (exit $ac_status); }; } &&
34170          { ac_try='test -s conftest.$ac_objext'
34171   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34172   (eval $ac_try) 2>&5
34173   ac_status=$?
34174   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34175   (exit $ac_status); }; }; then
34176   ac_cv_type_signal=void
34177 else
34178   echo "$as_me: failed program was:" >&5
34179 sed 's/^/| /' conftest.$ac_ext >&5
34180
34181 ac_cv_type_signal=int
34182 fi
34183 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34184 fi
34185 echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
34186 echo "${ECHO_T}$ac_cv_type_signal" >&6
34187
34188 cat >>confdefs.h <<_ACEOF
34189 #define RETSIGTYPE $ac_cv_type_signal
34190 _ACEOF
34191
34192
34193
34194 echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
34195 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6
34196 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
34197   echo $ECHO_N "(cached) $ECHO_C" >&6
34198 else
34199   cat >conftest.$ac_ext <<_ACEOF
34200 /* confdefs.h.  */
34201 _ACEOF
34202 cat confdefs.h >>conftest.$ac_ext
34203 cat >>conftest.$ac_ext <<_ACEOF
34204 /* end confdefs.h.  */
34205 $ac_includes_default
34206 #include <signal.h>
34207
34208
34209 int
34210 main ()
34211 {
34212 if ((sig_atomic_t *) 0)
34213   return 0;
34214 if (sizeof (sig_atomic_t))
34215   return 0;
34216   ;
34217   return 0;
34218 }
34219 _ACEOF
34220 rm -f conftest.$ac_objext
34221 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34222   (eval $ac_compile) 2>conftest.er1
34223   ac_status=$?
34224   grep -v '^ *+' conftest.er1 >conftest.err
34225   rm -f conftest.er1
34226   cat conftest.err >&5
34227   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34228   (exit $ac_status); } &&
34229          { ac_try='test -z "$ac_c_werror_flag"
34230                          || test ! -s conftest.err'
34231   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34232   (eval $ac_try) 2>&5
34233   ac_status=$?
34234   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34235   (exit $ac_status); }; } &&
34236          { ac_try='test -s conftest.$ac_objext'
34237   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34238   (eval $ac_try) 2>&5
34239   ac_status=$?
34240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34241   (exit $ac_status); }; }; then
34242   ac_cv_type_sig_atomic_t=yes
34243 else
34244   echo "$as_me: failed program was:" >&5
34245 sed 's/^/| /' conftest.$ac_ext >&5
34246
34247 ac_cv_type_sig_atomic_t=no
34248 fi
34249 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34250 fi
34251 echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
34252 echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6
34253 if test $ac_cv_type_sig_atomic_t = yes; then
34254   :
34255 else
34256
34257 cat >>confdefs.h <<_ACEOF
34258 #define sig_atomic_t int
34259 _ACEOF
34260
34261 fi
34262
34263
34264 echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5
34265 echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6
34266 if test "${ac_cv_type_uid_t+set}" = set; then
34267   echo $ECHO_N "(cached) $ECHO_C" >&6
34268 else
34269   cat >conftest.$ac_ext <<_ACEOF
34270 /* confdefs.h.  */
34271 _ACEOF
34272 cat confdefs.h >>conftest.$ac_ext
34273 cat >>conftest.$ac_ext <<_ACEOF
34274 /* end confdefs.h.  */
34275 #include <sys/types.h>
34276
34277 _ACEOF
34278 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34279   $EGREP "uid_t" >/dev/null 2>&1; then
34280   ac_cv_type_uid_t=yes
34281 else
34282   ac_cv_type_uid_t=no
34283 fi
34284 rm -f conftest*
34285
34286 fi
34287 echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5
34288 echo "${ECHO_T}$ac_cv_type_uid_t" >&6
34289 if test $ac_cv_type_uid_t = no; then
34290
34291 cat >>confdefs.h <<\_ACEOF
34292 #define uid_t int
34293 _ACEOF
34294
34295
34296 cat >>confdefs.h <<\_ACEOF
34297 #define gid_t int
34298 _ACEOF
34299
34300 fi
34301
34302
34303 echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
34304 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
34305 if test "${ac_cv_header_time+set}" = set; then
34306   echo $ECHO_N "(cached) $ECHO_C" >&6
34307 else
34308   cat >conftest.$ac_ext <<_ACEOF
34309 /* confdefs.h.  */
34310 _ACEOF
34311 cat confdefs.h >>conftest.$ac_ext
34312 cat >>conftest.$ac_ext <<_ACEOF
34313 /* end confdefs.h.  */
34314 #include <sys/types.h>
34315 #include <sys/time.h>
34316 #include <time.h>
34317
34318 int
34319 main ()
34320 {
34321 if ((struct tm *) 0)
34322 return 0;
34323   ;
34324   return 0;
34325 }
34326 _ACEOF
34327 rm -f conftest.$ac_objext
34328 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34329   (eval $ac_compile) 2>conftest.er1
34330   ac_status=$?
34331   grep -v '^ *+' conftest.er1 >conftest.err
34332   rm -f conftest.er1
34333   cat conftest.err >&5
34334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34335   (exit $ac_status); } &&
34336          { ac_try='test -z "$ac_c_werror_flag"
34337                          || test ! -s conftest.err'
34338   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34339   (eval $ac_try) 2>&5
34340   ac_status=$?
34341   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34342   (exit $ac_status); }; } &&
34343          { ac_try='test -s conftest.$ac_objext'
34344   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34345   (eval $ac_try) 2>&5
34346   ac_status=$?
34347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34348   (exit $ac_status); }; }; then
34349   ac_cv_header_time=yes
34350 else
34351   echo "$as_me: failed program was:" >&5
34352 sed 's/^/| /' conftest.$ac_ext >&5
34353
34354 ac_cv_header_time=no
34355 fi
34356 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34357 fi
34358 echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
34359 echo "${ECHO_T}$ac_cv_header_time" >&6
34360 if test $ac_cv_header_time = yes; then
34361
34362 cat >>confdefs.h <<\_ACEOF
34363 #define TIME_WITH_SYS_TIME 1
34364 _ACEOF
34365
34366 fi
34367
34368 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
34369 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
34370 if test "${ac_cv_struct_tm+set}" = set; then
34371   echo $ECHO_N "(cached) $ECHO_C" >&6
34372 else
34373   cat >conftest.$ac_ext <<_ACEOF
34374 /* confdefs.h.  */
34375 _ACEOF
34376 cat confdefs.h >>conftest.$ac_ext
34377 cat >>conftest.$ac_ext <<_ACEOF
34378 /* end confdefs.h.  */
34379 #include <sys/types.h>
34380 #include <time.h>
34381
34382 int
34383 main ()
34384 {
34385 struct tm *tp; tp->tm_sec;
34386   ;
34387   return 0;
34388 }
34389 _ACEOF
34390 rm -f conftest.$ac_objext
34391 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34392   (eval $ac_compile) 2>conftest.er1
34393   ac_status=$?
34394   grep -v '^ *+' conftest.er1 >conftest.err
34395   rm -f conftest.er1
34396   cat conftest.err >&5
34397   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34398   (exit $ac_status); } &&
34399          { ac_try='test -z "$ac_c_werror_flag"
34400                          || test ! -s conftest.err'
34401   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34402   (eval $ac_try) 2>&5
34403   ac_status=$?
34404   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34405   (exit $ac_status); }; } &&
34406          { ac_try='test -s conftest.$ac_objext'
34407   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34408   (eval $ac_try) 2>&5
34409   ac_status=$?
34410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34411   (exit $ac_status); }; }; then
34412   ac_cv_struct_tm=time.h
34413 else
34414   echo "$as_me: failed program was:" >&5
34415 sed 's/^/| /' conftest.$ac_ext >&5
34416
34417 ac_cv_struct_tm=sys/time.h
34418 fi
34419 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34420 fi
34421 echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
34422 echo "${ECHO_T}$ac_cv_struct_tm" >&6
34423 if test $ac_cv_struct_tm = sys/time.h; then
34424
34425 cat >>confdefs.h <<\_ACEOF
34426 #define TM_IN_SYS_TIME 1
34427 _ACEOF
34428
34429 fi
34430
34431 echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
34432 echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6
34433 if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
34434   echo $ECHO_N "(cached) $ECHO_C" >&6
34435 else
34436   cat >conftest.$ac_ext <<_ACEOF
34437 /* confdefs.h.  */
34438 _ACEOF
34439 cat confdefs.h >>conftest.$ac_ext
34440 cat >>conftest.$ac_ext <<_ACEOF
34441 /* end confdefs.h.  */
34442 $ac_includes_default
34443 int
34444 main ()
34445 {
34446 static struct stat ac_aggr;
34447 if (ac_aggr.st_blksize)
34448 return 0;
34449   ;
34450   return 0;
34451 }
34452 _ACEOF
34453 rm -f conftest.$ac_objext
34454 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34455   (eval $ac_compile) 2>conftest.er1
34456   ac_status=$?
34457   grep -v '^ *+' conftest.er1 >conftest.err
34458   rm -f conftest.er1
34459   cat conftest.err >&5
34460   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34461   (exit $ac_status); } &&
34462          { ac_try='test -z "$ac_c_werror_flag"
34463                          || test ! -s conftest.err'
34464   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34465   (eval $ac_try) 2>&5
34466   ac_status=$?
34467   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34468   (exit $ac_status); }; } &&
34469          { ac_try='test -s conftest.$ac_objext'
34470   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34471   (eval $ac_try) 2>&5
34472   ac_status=$?
34473   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34474   (exit $ac_status); }; }; then
34475   ac_cv_member_struct_stat_st_blksize=yes
34476 else
34477   echo "$as_me: failed program was:" >&5
34478 sed 's/^/| /' conftest.$ac_ext >&5
34479
34480 cat >conftest.$ac_ext <<_ACEOF
34481 /* confdefs.h.  */
34482 _ACEOF
34483 cat confdefs.h >>conftest.$ac_ext
34484 cat >>conftest.$ac_ext <<_ACEOF
34485 /* end confdefs.h.  */
34486 $ac_includes_default
34487 int
34488 main ()
34489 {
34490 static struct stat ac_aggr;
34491 if (sizeof ac_aggr.st_blksize)
34492 return 0;
34493   ;
34494   return 0;
34495 }
34496 _ACEOF
34497 rm -f conftest.$ac_objext
34498 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34499   (eval $ac_compile) 2>conftest.er1
34500   ac_status=$?
34501   grep -v '^ *+' conftest.er1 >conftest.err
34502   rm -f conftest.er1
34503   cat conftest.err >&5
34504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34505   (exit $ac_status); } &&
34506          { ac_try='test -z "$ac_c_werror_flag"
34507                          || test ! -s conftest.err'
34508   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34509   (eval $ac_try) 2>&5
34510   ac_status=$?
34511   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34512   (exit $ac_status); }; } &&
34513          { ac_try='test -s conftest.$ac_objext'
34514   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34515   (eval $ac_try) 2>&5
34516   ac_status=$?
34517   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34518   (exit $ac_status); }; }; then
34519   ac_cv_member_struct_stat_st_blksize=yes
34520 else
34521   echo "$as_me: failed program was:" >&5
34522 sed 's/^/| /' conftest.$ac_ext >&5
34523
34524 ac_cv_member_struct_stat_st_blksize=no
34525 fi
34526 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34527 fi
34528 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34529 fi
34530 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
34531 echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6
34532 if test $ac_cv_member_struct_stat_st_blksize = yes; then
34533
34534 cat >>confdefs.h <<_ACEOF
34535 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
34536 _ACEOF
34537
34538
34539 fi
34540
34541 echo "$as_me:$LINENO: checking for struct passwd.pw_gecos" >&5
34542 echo $ECHO_N "checking for struct passwd.pw_gecos... $ECHO_C" >&6
34543 if test "${ac_cv_member_struct_passwd_pw_gecos+set}" = set; then
34544   echo $ECHO_N "(cached) $ECHO_C" >&6
34545 else
34546   cat >conftest.$ac_ext <<_ACEOF
34547 /* confdefs.h.  */
34548 _ACEOF
34549 cat confdefs.h >>conftest.$ac_ext
34550 cat >>conftest.$ac_ext <<_ACEOF
34551 /* end confdefs.h.  */
34552 $ac_includes_default
34553 #include <pwd.h>
34554
34555 int
34556 main ()
34557 {
34558 static struct passwd ac_aggr;
34559 if (ac_aggr.pw_gecos)
34560 return 0;
34561   ;
34562   return 0;
34563 }
34564 _ACEOF
34565 rm -f conftest.$ac_objext
34566 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34567   (eval $ac_compile) 2>conftest.er1
34568   ac_status=$?
34569   grep -v '^ *+' conftest.er1 >conftest.err
34570   rm -f conftest.er1
34571   cat conftest.err >&5
34572   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34573   (exit $ac_status); } &&
34574          { ac_try='test -z "$ac_c_werror_flag"
34575                          || test ! -s conftest.err'
34576   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34577   (eval $ac_try) 2>&5
34578   ac_status=$?
34579   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34580   (exit $ac_status); }; } &&
34581          { ac_try='test -s conftest.$ac_objext'
34582   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34583   (eval $ac_try) 2>&5
34584   ac_status=$?
34585   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34586   (exit $ac_status); }; }; then
34587   ac_cv_member_struct_passwd_pw_gecos=yes
34588 else
34589   echo "$as_me: failed program was:" >&5
34590 sed 's/^/| /' conftest.$ac_ext >&5
34591
34592 cat >conftest.$ac_ext <<_ACEOF
34593 /* confdefs.h.  */
34594 _ACEOF
34595 cat confdefs.h >>conftest.$ac_ext
34596 cat >>conftest.$ac_ext <<_ACEOF
34597 /* end confdefs.h.  */
34598 $ac_includes_default
34599 #include <pwd.h>
34600
34601 int
34602 main ()
34603 {
34604 static struct passwd ac_aggr;
34605 if (sizeof ac_aggr.pw_gecos)
34606 return 0;
34607   ;
34608   return 0;
34609 }
34610 _ACEOF
34611 rm -f conftest.$ac_objext
34612 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34613   (eval $ac_compile) 2>conftest.er1
34614   ac_status=$?
34615   grep -v '^ *+' conftest.er1 >conftest.err
34616   rm -f conftest.er1
34617   cat conftest.err >&5
34618   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34619   (exit $ac_status); } &&
34620          { ac_try='test -z "$ac_c_werror_flag"
34621                          || test ! -s conftest.err'
34622   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34623   (eval $ac_try) 2>&5
34624   ac_status=$?
34625   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34626   (exit $ac_status); }; } &&
34627          { ac_try='test -s conftest.$ac_objext'
34628   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34629   (eval $ac_try) 2>&5
34630   ac_status=$?
34631   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34632   (exit $ac_status); }; }; then
34633   ac_cv_member_struct_passwd_pw_gecos=yes
34634 else
34635   echo "$as_me: failed program was:" >&5
34636 sed 's/^/| /' conftest.$ac_ext >&5
34637
34638 ac_cv_member_struct_passwd_pw_gecos=no
34639 fi
34640 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34641 fi
34642 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34643 fi
34644 echo "$as_me:$LINENO: result: $ac_cv_member_struct_passwd_pw_gecos" >&5
34645 echo "${ECHO_T}$ac_cv_member_struct_passwd_pw_gecos" >&6
34646 if test $ac_cv_member_struct_passwd_pw_gecos = yes; then
34647
34648 cat >>confdefs.h <<_ACEOF
34649 #define HAVE_STRUCT_PASSWD_PW_GECOS 1
34650 _ACEOF
34651
34652
34653 fi
34654
34655 echo "$as_me:$LINENO: checking for struct passwd.pw_passwd" >&5
34656 echo $ECHO_N "checking for struct passwd.pw_passwd... $ECHO_C" >&6
34657 if test "${ac_cv_member_struct_passwd_pw_passwd+set}" = set; then
34658   echo $ECHO_N "(cached) $ECHO_C" >&6
34659 else
34660   cat >conftest.$ac_ext <<_ACEOF
34661 /* confdefs.h.  */
34662 _ACEOF
34663 cat confdefs.h >>conftest.$ac_ext
34664 cat >>conftest.$ac_ext <<_ACEOF
34665 /* end confdefs.h.  */
34666 $ac_includes_default
34667 #include <pwd.h>
34668
34669 int
34670 main ()
34671 {
34672 static struct passwd ac_aggr;
34673 if (ac_aggr.pw_passwd)
34674 return 0;
34675   ;
34676   return 0;
34677 }
34678 _ACEOF
34679 rm -f conftest.$ac_objext
34680 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34681   (eval $ac_compile) 2>conftest.er1
34682   ac_status=$?
34683   grep -v '^ *+' conftest.er1 >conftest.err
34684   rm -f conftest.er1
34685   cat conftest.err >&5
34686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34687   (exit $ac_status); } &&
34688          { ac_try='test -z "$ac_c_werror_flag"
34689                          || test ! -s conftest.err'
34690   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34691   (eval $ac_try) 2>&5
34692   ac_status=$?
34693   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34694   (exit $ac_status); }; } &&
34695          { ac_try='test -s conftest.$ac_objext'
34696   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34697   (eval $ac_try) 2>&5
34698   ac_status=$?
34699   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34700   (exit $ac_status); }; }; then
34701   ac_cv_member_struct_passwd_pw_passwd=yes
34702 else
34703   echo "$as_me: failed program was:" >&5
34704 sed 's/^/| /' conftest.$ac_ext >&5
34705
34706 cat >conftest.$ac_ext <<_ACEOF
34707 /* confdefs.h.  */
34708 _ACEOF
34709 cat confdefs.h >>conftest.$ac_ext
34710 cat >>conftest.$ac_ext <<_ACEOF
34711 /* end confdefs.h.  */
34712 $ac_includes_default
34713 #include <pwd.h>
34714
34715 int
34716 main ()
34717 {
34718 static struct passwd ac_aggr;
34719 if (sizeof ac_aggr.pw_passwd)
34720 return 0;
34721   ;
34722   return 0;
34723 }
34724 _ACEOF
34725 rm -f conftest.$ac_objext
34726 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34727   (eval $ac_compile) 2>conftest.er1
34728   ac_status=$?
34729   grep -v '^ *+' conftest.er1 >conftest.err
34730   rm -f conftest.er1
34731   cat conftest.err >&5
34732   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34733   (exit $ac_status); } &&
34734          { ac_try='test -z "$ac_c_werror_flag"
34735                          || test ! -s conftest.err'
34736   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34737   (eval $ac_try) 2>&5
34738   ac_status=$?
34739   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34740   (exit $ac_status); }; } &&
34741          { ac_try='test -s conftest.$ac_objext'
34742   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34743   (eval $ac_try) 2>&5
34744   ac_status=$?
34745   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34746   (exit $ac_status); }; }; then
34747   ac_cv_member_struct_passwd_pw_passwd=yes
34748 else
34749   echo "$as_me: failed program was:" >&5
34750 sed 's/^/| /' conftest.$ac_ext >&5
34751
34752 ac_cv_member_struct_passwd_pw_passwd=no
34753 fi
34754 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34755 fi
34756 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34757 fi
34758 echo "$as_me:$LINENO: result: $ac_cv_member_struct_passwd_pw_passwd" >&5
34759 echo "${ECHO_T}$ac_cv_member_struct_passwd_pw_passwd" >&6
34760 if test $ac_cv_member_struct_passwd_pw_passwd = yes; then
34761
34762 cat >>confdefs.h <<_ACEOF
34763 #define HAVE_STRUCT_PASSWD_PW_PASSWD 1
34764 _ACEOF
34765
34766
34767 fi
34768
34769
34770 echo "$as_me:$LINENO: checking if toupper() requires islower()" >&5
34771 echo $ECHO_N "checking if toupper() requires islower()... $ECHO_C" >&6
34772 if test "${ol_cv_c_upper_lower+set}" = set; then
34773   echo $ECHO_N "(cached) $ECHO_C" >&6
34774 else
34775
34776         if test "$cross_compiling" = yes; then
34777   ol_cv_c_upper_lower=safe
34778 else
34779   cat >conftest.$ac_ext <<_ACEOF
34780 /* confdefs.h.  */
34781 _ACEOF
34782 cat confdefs.h >>conftest.$ac_ext
34783 cat >>conftest.$ac_ext <<_ACEOF
34784 /* end confdefs.h.  */
34785
34786 #include <ctype.h>
34787 main()
34788 {
34789         if ('C' == toupper('C'))
34790                 exit(0);
34791         else
34792                 exit(1);
34793 }
34794 _ACEOF
34795 rm -f conftest$ac_exeext
34796 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
34797   (eval $ac_link) 2>&5
34798   ac_status=$?
34799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34800   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
34801   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34802   (eval $ac_try) 2>&5
34803   ac_status=$?
34804   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34805   (exit $ac_status); }; }; then
34806   ol_cv_c_upper_lower=no
34807 else
34808   echo "$as_me: program exited with status $ac_status" >&5
34809 echo "$as_me: failed program was:" >&5
34810 sed 's/^/| /' conftest.$ac_ext >&5
34811
34812 ( exit $ac_status )
34813 ol_cv_c_upper_lower=yes
34814 fi
34815 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
34816 fi
34817 fi
34818 echo "$as_me:$LINENO: result: $ol_cv_c_upper_lower" >&5
34819 echo "${ECHO_T}$ol_cv_c_upper_lower" >&6
34820 if test $ol_cv_c_upper_lower != no ; then
34821
34822 cat >>confdefs.h <<\_ACEOF
34823 #define C_UPPER_LOWER 1
34824 _ACEOF
34825
34826 fi
34827
34828 echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
34829 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
34830 if test "${ac_cv_c_const+set}" = set; then
34831   echo $ECHO_N "(cached) $ECHO_C" >&6
34832 else
34833   cat >conftest.$ac_ext <<_ACEOF
34834 /* confdefs.h.  */
34835 _ACEOF
34836 cat confdefs.h >>conftest.$ac_ext
34837 cat >>conftest.$ac_ext <<_ACEOF
34838 /* end confdefs.h.  */
34839
34840 int
34841 main ()
34842 {
34843 /* FIXME: Include the comments suggested by Paul. */
34844 #ifndef __cplusplus
34845   /* Ultrix mips cc rejects this.  */
34846   typedef int charset[2];
34847   const charset x;
34848   /* SunOS 4.1.1 cc rejects this.  */
34849   char const *const *ccp;
34850   char **p;
34851   /* NEC SVR4.0.2 mips cc rejects this.  */
34852   struct point {int x, y;};
34853   static struct point const zero = {0,0};
34854   /* AIX XL C 1.02.0.0 rejects this.
34855      It does not let you subtract one const X* pointer from another in
34856      an arm of an if-expression whose if-part is not a constant
34857      expression */
34858   const char *g = "string";
34859   ccp = &g + (g ? g-g : 0);
34860   /* HPUX 7.0 cc rejects these. */
34861   ++ccp;
34862   p = (char**) ccp;
34863   ccp = (char const *const *) p;
34864   { /* SCO 3.2v4 cc rejects this.  */
34865     char *t;
34866     char const *s = 0 ? (char *) 0 : (char const *) 0;
34867
34868     *t++ = 0;
34869   }
34870   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
34871     int x[] = {25, 17};
34872     const int *foo = &x[0];
34873     ++foo;
34874   }
34875   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
34876     typedef const int *iptr;
34877     iptr p = 0;
34878     ++p;
34879   }
34880   { /* AIX XL C 1.02.0.0 rejects this saying
34881        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
34882     struct s { int j; const int *ap[3]; };
34883     struct s *b; b->j = 5;
34884   }
34885   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
34886     const int foo = 10;
34887   }
34888 #endif
34889
34890   ;
34891   return 0;
34892 }
34893 _ACEOF
34894 rm -f conftest.$ac_objext
34895 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34896   (eval $ac_compile) 2>conftest.er1
34897   ac_status=$?
34898   grep -v '^ *+' conftest.er1 >conftest.err
34899   rm -f conftest.er1
34900   cat conftest.err >&5
34901   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34902   (exit $ac_status); } &&
34903          { ac_try='test -z "$ac_c_werror_flag"
34904                          || test ! -s conftest.err'
34905   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34906   (eval $ac_try) 2>&5
34907   ac_status=$?
34908   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34909   (exit $ac_status); }; } &&
34910          { ac_try='test -s conftest.$ac_objext'
34911   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34912   (eval $ac_try) 2>&5
34913   ac_status=$?
34914   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34915   (exit $ac_status); }; }; then
34916   ac_cv_c_const=yes
34917 else
34918   echo "$as_me: failed program was:" >&5
34919 sed 's/^/| /' conftest.$ac_ext >&5
34920
34921 ac_cv_c_const=no
34922 fi
34923 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34924 fi
34925 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
34926 echo "${ECHO_T}$ac_cv_c_const" >&6
34927 if test $ac_cv_c_const = no; then
34928
34929 cat >>confdefs.h <<\_ACEOF
34930 #define const
34931 _ACEOF
34932
34933 fi
34934
34935 echo "$as_me:$LINENO: checking if compiler understands volatile" >&5
34936 echo $ECHO_N "checking if compiler understands volatile... $ECHO_C" >&6
34937 if test "${ol_cv_c_volatile+set}" = set; then
34938   echo $ECHO_N "(cached) $ECHO_C" >&6
34939 else
34940   cat >conftest.$ac_ext <<_ACEOF
34941 /* confdefs.h.  */
34942 _ACEOF
34943 cat confdefs.h >>conftest.$ac_ext
34944 cat >>conftest.$ac_ext <<_ACEOF
34945 /* end confdefs.h.  */
34946 int x, y, z;
34947 int
34948 main ()
34949 {
34950 volatile int a; int * volatile b = x ? &y : &z;
34951       /* Older MIPS compilers (eg., in Ultrix 4.2) don't like *b = 0 */
34952       *b = 0;
34953   ;
34954   return 0;
34955 }
34956 _ACEOF
34957 rm -f conftest.$ac_objext
34958 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34959   (eval $ac_compile) 2>conftest.er1
34960   ac_status=$?
34961   grep -v '^ *+' conftest.er1 >conftest.err
34962   rm -f conftest.er1
34963   cat conftest.err >&5
34964   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34965   (exit $ac_status); } &&
34966          { ac_try='test -z "$ac_c_werror_flag"
34967                          || test ! -s conftest.err'
34968   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34969   (eval $ac_try) 2>&5
34970   ac_status=$?
34971   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34972   (exit $ac_status); }; } &&
34973          { ac_try='test -s conftest.$ac_objext'
34974   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34975   (eval $ac_try) 2>&5
34976   ac_status=$?
34977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34978   (exit $ac_status); }; }; then
34979   ol_cv_c_volatile=yes
34980 else
34981   echo "$as_me: failed program was:" >&5
34982 sed 's/^/| /' conftest.$ac_ext >&5
34983
34984 ol_cv_c_volatile=no
34985 fi
34986 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34987 fi
34988 echo "$as_me:$LINENO: result: $ol_cv_c_volatile" >&5
34989 echo "${ECHO_T}$ol_cv_c_volatile" >&6
34990   if test $ol_cv_c_volatile = yes; then
34991     :
34992   else
34993
34994 cat >>confdefs.h <<\_ACEOF
34995 #define volatile
34996 _ACEOF
34997
34998   fi
34999
35000
35001 if test $cross_compiling = yes ; then
35002         { echo "$as_me:$LINENO: WARNING: Crossing compiling... all bets are off!" >&5
35003 echo "$as_me: WARNING: Crossing compiling... all bets are off!" >&2;}
35004
35005 cat >>confdefs.h <<\_ACEOF
35006 #define CROSS_COMPILING 1
35007 _ACEOF
35008
35009 else
35010         echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
35011 echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
35012 if test "${ac_cv_c_bigendian+set}" = set; then
35013   echo $ECHO_N "(cached) $ECHO_C" >&6
35014 else
35015   # See if sys/param.h defines the BYTE_ORDER macro.
35016 cat >conftest.$ac_ext <<_ACEOF
35017 /* confdefs.h.  */
35018 _ACEOF
35019 cat confdefs.h >>conftest.$ac_ext
35020 cat >>conftest.$ac_ext <<_ACEOF
35021 /* end confdefs.h.  */
35022 #include <sys/types.h>
35023 #include <sys/param.h>
35024
35025 int
35026 main ()
35027 {
35028 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
35029  bogus endian macros
35030 #endif
35031
35032   ;
35033   return 0;
35034 }
35035 _ACEOF
35036 rm -f conftest.$ac_objext
35037 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35038   (eval $ac_compile) 2>conftest.er1
35039   ac_status=$?
35040   grep -v '^ *+' conftest.er1 >conftest.err
35041   rm -f conftest.er1
35042   cat conftest.err >&5
35043   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35044   (exit $ac_status); } &&
35045          { ac_try='test -z "$ac_c_werror_flag"
35046                          || test ! -s conftest.err'
35047   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35048   (eval $ac_try) 2>&5
35049   ac_status=$?
35050   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35051   (exit $ac_status); }; } &&
35052          { ac_try='test -s conftest.$ac_objext'
35053   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35054   (eval $ac_try) 2>&5
35055   ac_status=$?
35056   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35057   (exit $ac_status); }; }; then
35058   # It does; now see whether it defined to BIG_ENDIAN or not.
35059 cat >conftest.$ac_ext <<_ACEOF
35060 /* confdefs.h.  */
35061 _ACEOF
35062 cat confdefs.h >>conftest.$ac_ext
35063 cat >>conftest.$ac_ext <<_ACEOF
35064 /* end confdefs.h.  */
35065 #include <sys/types.h>
35066 #include <sys/param.h>
35067
35068 int
35069 main ()
35070 {
35071 #if BYTE_ORDER != BIG_ENDIAN
35072  not big endian
35073 #endif
35074
35075   ;
35076   return 0;
35077 }
35078 _ACEOF
35079 rm -f conftest.$ac_objext
35080 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35081   (eval $ac_compile) 2>conftest.er1
35082   ac_status=$?
35083   grep -v '^ *+' conftest.er1 >conftest.err
35084   rm -f conftest.er1
35085   cat conftest.err >&5
35086   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35087   (exit $ac_status); } &&
35088          { ac_try='test -z "$ac_c_werror_flag"
35089                          || test ! -s conftest.err'
35090   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35091   (eval $ac_try) 2>&5
35092   ac_status=$?
35093   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35094   (exit $ac_status); }; } &&
35095          { ac_try='test -s conftest.$ac_objext'
35096   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35097   (eval $ac_try) 2>&5
35098   ac_status=$?
35099   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35100   (exit $ac_status); }; }; then
35101   ac_cv_c_bigendian=yes
35102 else
35103   echo "$as_me: failed program was:" >&5
35104 sed 's/^/| /' conftest.$ac_ext >&5
35105
35106 ac_cv_c_bigendian=no
35107 fi
35108 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35109 else
35110   echo "$as_me: failed program was:" >&5
35111 sed 's/^/| /' conftest.$ac_ext >&5
35112
35113 # It does not; compile a test program.
35114 if test "$cross_compiling" = yes; then
35115   # try to guess the endianness by grepping values into an object file
35116   ac_cv_c_bigendian=unknown
35117   cat >conftest.$ac_ext <<_ACEOF
35118 /* confdefs.h.  */
35119 _ACEOF
35120 cat confdefs.h >>conftest.$ac_ext
35121 cat >>conftest.$ac_ext <<_ACEOF
35122 /* end confdefs.h.  */
35123 short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
35124 short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
35125 void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
35126 short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
35127 short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
35128 void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
35129 int
35130 main ()
35131 {
35132  _ascii (); _ebcdic ();
35133   ;
35134   return 0;
35135 }
35136 _ACEOF
35137 rm -f conftest.$ac_objext
35138 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35139   (eval $ac_compile) 2>conftest.er1
35140   ac_status=$?
35141   grep -v '^ *+' conftest.er1 >conftest.err
35142   rm -f conftest.er1
35143   cat conftest.err >&5
35144   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35145   (exit $ac_status); } &&
35146          { ac_try='test -z "$ac_c_werror_flag"
35147                          || test ! -s conftest.err'
35148   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35149   (eval $ac_try) 2>&5
35150   ac_status=$?
35151   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35152   (exit $ac_status); }; } &&
35153          { ac_try='test -s conftest.$ac_objext'
35154   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35155   (eval $ac_try) 2>&5
35156   ac_status=$?
35157   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35158   (exit $ac_status); }; }; then
35159   if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
35160   ac_cv_c_bigendian=yes
35161 fi
35162 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
35163   if test "$ac_cv_c_bigendian" = unknown; then
35164     ac_cv_c_bigendian=no
35165   else
35166     # finding both strings is unlikely to happen, but who knows?
35167     ac_cv_c_bigendian=unknown
35168   fi
35169 fi
35170 else
35171   echo "$as_me: failed program was:" >&5
35172 sed 's/^/| /' conftest.$ac_ext >&5
35173
35174 fi
35175 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35176 else
35177   cat >conftest.$ac_ext <<_ACEOF
35178 /* confdefs.h.  */
35179 _ACEOF
35180 cat confdefs.h >>conftest.$ac_ext
35181 cat >>conftest.$ac_ext <<_ACEOF
35182 /* end confdefs.h.  */
35183 int
35184 main ()
35185 {
35186   /* Are we little or big endian?  From Harbison&Steele.  */
35187   union
35188   {
35189     long l;
35190     char c[sizeof (long)];
35191   } u;
35192   u.l = 1;
35193   exit (u.c[sizeof (long) - 1] == 1);
35194 }
35195 _ACEOF
35196 rm -f conftest$ac_exeext
35197 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35198   (eval $ac_link) 2>&5
35199   ac_status=$?
35200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35201   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
35202   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35203   (eval $ac_try) 2>&5
35204   ac_status=$?
35205   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35206   (exit $ac_status); }; }; then
35207   ac_cv_c_bigendian=no
35208 else
35209   echo "$as_me: program exited with status $ac_status" >&5
35210 echo "$as_me: failed program was:" >&5
35211 sed 's/^/| /' conftest.$ac_ext >&5
35212
35213 ( exit $ac_status )
35214 ac_cv_c_bigendian=yes
35215 fi
35216 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
35217 fi
35218 fi
35219 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35220 fi
35221 echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
35222 echo "${ECHO_T}$ac_cv_c_bigendian" >&6
35223 case $ac_cv_c_bigendian in
35224   yes)
35225
35226 cat >>confdefs.h <<\_ACEOF
35227 #define WORDS_BIGENDIAN 1
35228 _ACEOF
35229  ;;
35230   no)
35231      ;;
35232   *)
35233     { { echo "$as_me:$LINENO: error: unknown endianness
35234 presetting ac_cv_c_bigendian=no (or yes) will help" >&5
35235 echo "$as_me: error: unknown endianness
35236 presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
35237    { (exit 1); exit 1; }; } ;;
35238 esac
35239
35240 fi
35241
35242 echo "$as_me:$LINENO: checking for short" >&5
35243 echo $ECHO_N "checking for short... $ECHO_C" >&6
35244 if test "${ac_cv_type_short+set}" = set; then
35245   echo $ECHO_N "(cached) $ECHO_C" >&6
35246 else
35247   cat >conftest.$ac_ext <<_ACEOF
35248 /* confdefs.h.  */
35249 _ACEOF
35250 cat confdefs.h >>conftest.$ac_ext
35251 cat >>conftest.$ac_ext <<_ACEOF
35252 /* end confdefs.h.  */
35253 $ac_includes_default
35254 int
35255 main ()
35256 {
35257 if ((short *) 0)
35258   return 0;
35259 if (sizeof (short))
35260   return 0;
35261   ;
35262   return 0;
35263 }
35264 _ACEOF
35265 rm -f conftest.$ac_objext
35266 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35267   (eval $ac_compile) 2>conftest.er1
35268   ac_status=$?
35269   grep -v '^ *+' conftest.er1 >conftest.err
35270   rm -f conftest.er1
35271   cat conftest.err >&5
35272   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35273   (exit $ac_status); } &&
35274          { ac_try='test -z "$ac_c_werror_flag"
35275                          || test ! -s conftest.err'
35276   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35277   (eval $ac_try) 2>&5
35278   ac_status=$?
35279   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35280   (exit $ac_status); }; } &&
35281          { ac_try='test -s conftest.$ac_objext'
35282   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35283   (eval $ac_try) 2>&5
35284   ac_status=$?
35285   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35286   (exit $ac_status); }; }; then
35287   ac_cv_type_short=yes
35288 else
35289   echo "$as_me: failed program was:" >&5
35290 sed 's/^/| /' conftest.$ac_ext >&5
35291
35292 ac_cv_type_short=no
35293 fi
35294 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35295 fi
35296 echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
35297 echo "${ECHO_T}$ac_cv_type_short" >&6
35298
35299 echo "$as_me:$LINENO: checking size of short" >&5
35300 echo $ECHO_N "checking size of short... $ECHO_C" >&6
35301 if test "${ac_cv_sizeof_short+set}" = set; then
35302   echo $ECHO_N "(cached) $ECHO_C" >&6
35303 else
35304   if test "$ac_cv_type_short" = yes; then
35305   # The cast to unsigned long works around a bug in the HP C Compiler
35306   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
35307   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
35308   # This bug is HP SR number 8606223364.
35309   if test "$cross_compiling" = yes; then
35310   # Depending upon the size, compute the lo and hi bounds.
35311 cat >conftest.$ac_ext <<_ACEOF
35312 /* confdefs.h.  */
35313 _ACEOF
35314 cat confdefs.h >>conftest.$ac_ext
35315 cat >>conftest.$ac_ext <<_ACEOF
35316 /* end confdefs.h.  */
35317 $ac_includes_default
35318 int
35319 main ()
35320 {
35321 static int test_array [1 - 2 * !(((long) (sizeof (short))) >= 0)];
35322 test_array [0] = 0
35323
35324   ;
35325   return 0;
35326 }
35327 _ACEOF
35328 rm -f conftest.$ac_objext
35329 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35330   (eval $ac_compile) 2>conftest.er1
35331   ac_status=$?
35332   grep -v '^ *+' conftest.er1 >conftest.err
35333   rm -f conftest.er1
35334   cat conftest.err >&5
35335   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35336   (exit $ac_status); } &&
35337          { ac_try='test -z "$ac_c_werror_flag"
35338                          || test ! -s conftest.err'
35339   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35340   (eval $ac_try) 2>&5
35341   ac_status=$?
35342   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35343   (exit $ac_status); }; } &&
35344          { ac_try='test -s conftest.$ac_objext'
35345   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35346   (eval $ac_try) 2>&5
35347   ac_status=$?
35348   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35349   (exit $ac_status); }; }; then
35350   ac_lo=0 ac_mid=0
35351   while :; do
35352     cat >conftest.$ac_ext <<_ACEOF
35353 /* confdefs.h.  */
35354 _ACEOF
35355 cat confdefs.h >>conftest.$ac_ext
35356 cat >>conftest.$ac_ext <<_ACEOF
35357 /* end confdefs.h.  */
35358 $ac_includes_default
35359 int
35360 main ()
35361 {
35362 static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
35363 test_array [0] = 0
35364
35365   ;
35366   return 0;
35367 }
35368 _ACEOF
35369 rm -f conftest.$ac_objext
35370 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35371   (eval $ac_compile) 2>conftest.er1
35372   ac_status=$?
35373   grep -v '^ *+' conftest.er1 >conftest.err
35374   rm -f conftest.er1
35375   cat conftest.err >&5
35376   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35377   (exit $ac_status); } &&
35378          { ac_try='test -z "$ac_c_werror_flag"
35379                          || test ! -s conftest.err'
35380   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35381   (eval $ac_try) 2>&5
35382   ac_status=$?
35383   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35384   (exit $ac_status); }; } &&
35385          { ac_try='test -s conftest.$ac_objext'
35386   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35387   (eval $ac_try) 2>&5
35388   ac_status=$?
35389   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35390   (exit $ac_status); }; }; then
35391   ac_hi=$ac_mid; break
35392 else
35393   echo "$as_me: failed program was:" >&5
35394 sed 's/^/| /' conftest.$ac_ext >&5
35395
35396 ac_lo=`expr $ac_mid + 1`
35397                     if test $ac_lo -le $ac_mid; then
35398                       ac_lo= ac_hi=
35399                       break
35400                     fi
35401                     ac_mid=`expr 2 '*' $ac_mid + 1`
35402 fi
35403 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35404   done
35405 else
35406   echo "$as_me: failed program was:" >&5
35407 sed 's/^/| /' conftest.$ac_ext >&5
35408
35409 cat >conftest.$ac_ext <<_ACEOF
35410 /* confdefs.h.  */
35411 _ACEOF
35412 cat confdefs.h >>conftest.$ac_ext
35413 cat >>conftest.$ac_ext <<_ACEOF
35414 /* end confdefs.h.  */
35415 $ac_includes_default
35416 int
35417 main ()
35418 {
35419 static int test_array [1 - 2 * !(((long) (sizeof (short))) < 0)];
35420 test_array [0] = 0
35421
35422   ;
35423   return 0;
35424 }
35425 _ACEOF
35426 rm -f conftest.$ac_objext
35427 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35428   (eval $ac_compile) 2>conftest.er1
35429   ac_status=$?
35430   grep -v '^ *+' conftest.er1 >conftest.err
35431   rm -f conftest.er1
35432   cat conftest.err >&5
35433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35434   (exit $ac_status); } &&
35435          { ac_try='test -z "$ac_c_werror_flag"
35436                          || test ! -s conftest.err'
35437   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35438   (eval $ac_try) 2>&5
35439   ac_status=$?
35440   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35441   (exit $ac_status); }; } &&
35442          { ac_try='test -s conftest.$ac_objext'
35443   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35444   (eval $ac_try) 2>&5
35445   ac_status=$?
35446   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35447   (exit $ac_status); }; }; then
35448   ac_hi=-1 ac_mid=-1
35449   while :; do
35450     cat >conftest.$ac_ext <<_ACEOF
35451 /* confdefs.h.  */
35452 _ACEOF
35453 cat confdefs.h >>conftest.$ac_ext
35454 cat >>conftest.$ac_ext <<_ACEOF
35455 /* end confdefs.h.  */
35456 $ac_includes_default
35457 int
35458 main ()
35459 {
35460 static int test_array [1 - 2 * !(((long) (sizeof (short))) >= $ac_mid)];
35461 test_array [0] = 0
35462
35463   ;
35464   return 0;
35465 }
35466 _ACEOF
35467 rm -f conftest.$ac_objext
35468 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35469   (eval $ac_compile) 2>conftest.er1
35470   ac_status=$?
35471   grep -v '^ *+' conftest.er1 >conftest.err
35472   rm -f conftest.er1
35473   cat conftest.err >&5
35474   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35475   (exit $ac_status); } &&
35476          { ac_try='test -z "$ac_c_werror_flag"
35477                          || test ! -s conftest.err'
35478   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35479   (eval $ac_try) 2>&5
35480   ac_status=$?
35481   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35482   (exit $ac_status); }; } &&
35483          { ac_try='test -s conftest.$ac_objext'
35484   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35485   (eval $ac_try) 2>&5
35486   ac_status=$?
35487   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35488   (exit $ac_status); }; }; then
35489   ac_lo=$ac_mid; break
35490 else
35491   echo "$as_me: failed program was:" >&5
35492 sed 's/^/| /' conftest.$ac_ext >&5
35493
35494 ac_hi=`expr '(' $ac_mid ')' - 1`
35495                        if test $ac_mid -le $ac_hi; then
35496                          ac_lo= ac_hi=
35497                          break
35498                        fi
35499                        ac_mid=`expr 2 '*' $ac_mid`
35500 fi
35501 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35502   done
35503 else
35504   echo "$as_me: failed program was:" >&5
35505 sed 's/^/| /' conftest.$ac_ext >&5
35506
35507 ac_lo= ac_hi=
35508 fi
35509 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35510 fi
35511 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35512 # Binary search between lo and hi bounds.
35513 while test "x$ac_lo" != "x$ac_hi"; do
35514   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
35515   cat >conftest.$ac_ext <<_ACEOF
35516 /* confdefs.h.  */
35517 _ACEOF
35518 cat confdefs.h >>conftest.$ac_ext
35519 cat >>conftest.$ac_ext <<_ACEOF
35520 /* end confdefs.h.  */
35521 $ac_includes_default
35522 int
35523 main ()
35524 {
35525 static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
35526 test_array [0] = 0
35527
35528   ;
35529   return 0;
35530 }
35531 _ACEOF
35532 rm -f conftest.$ac_objext
35533 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35534   (eval $ac_compile) 2>conftest.er1
35535   ac_status=$?
35536   grep -v '^ *+' conftest.er1 >conftest.err
35537   rm -f conftest.er1
35538   cat conftest.err >&5
35539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35540   (exit $ac_status); } &&
35541          { ac_try='test -z "$ac_c_werror_flag"
35542                          || test ! -s conftest.err'
35543   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35544   (eval $ac_try) 2>&5
35545   ac_status=$?
35546   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35547   (exit $ac_status); }; } &&
35548          { ac_try='test -s conftest.$ac_objext'
35549   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35550   (eval $ac_try) 2>&5
35551   ac_status=$?
35552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35553   (exit $ac_status); }; }; then
35554   ac_hi=$ac_mid
35555 else
35556   echo "$as_me: failed program was:" >&5
35557 sed 's/^/| /' conftest.$ac_ext >&5
35558
35559 ac_lo=`expr '(' $ac_mid ')' + 1`
35560 fi
35561 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35562 done
35563 case $ac_lo in
35564 ?*) ac_cv_sizeof_short=$ac_lo;;
35565 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
35566 See \`config.log' for more details." >&5
35567 echo "$as_me: error: cannot compute sizeof (short), 77
35568 See \`config.log' for more details." >&2;}
35569    { (exit 1); exit 1; }; } ;;
35570 esac
35571 else
35572   if test "$cross_compiling" = yes; then
35573   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
35574 See \`config.log' for more details." >&5
35575 echo "$as_me: error: cannot run test program while cross compiling
35576 See \`config.log' for more details." >&2;}
35577    { (exit 1); exit 1; }; }
35578 else
35579   cat >conftest.$ac_ext <<_ACEOF
35580 /* confdefs.h.  */
35581 _ACEOF
35582 cat confdefs.h >>conftest.$ac_ext
35583 cat >>conftest.$ac_ext <<_ACEOF
35584 /* end confdefs.h.  */
35585 $ac_includes_default
35586 long longval () { return (long) (sizeof (short)); }
35587 unsigned long ulongval () { return (long) (sizeof (short)); }
35588 #include <stdio.h>
35589 #include <stdlib.h>
35590 int
35591 main ()
35592 {
35593
35594   FILE *f = fopen ("conftest.val", "w");
35595   if (! f)
35596     exit (1);
35597   if (((long) (sizeof (short))) < 0)
35598     {
35599       long i = longval ();
35600       if (i != ((long) (sizeof (short))))
35601         exit (1);
35602       fprintf (f, "%ld\n", i);
35603     }
35604   else
35605     {
35606       unsigned long i = ulongval ();
35607       if (i != ((long) (sizeof (short))))
35608         exit (1);
35609       fprintf (f, "%lu\n", i);
35610     }
35611   exit (ferror (f) || fclose (f) != 0);
35612
35613   ;
35614   return 0;
35615 }
35616 _ACEOF
35617 rm -f conftest$ac_exeext
35618 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35619   (eval $ac_link) 2>&5
35620   ac_status=$?
35621   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35622   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
35623   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35624   (eval $ac_try) 2>&5
35625   ac_status=$?
35626   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35627   (exit $ac_status); }; }; then
35628   ac_cv_sizeof_short=`cat conftest.val`
35629 else
35630   echo "$as_me: program exited with status $ac_status" >&5
35631 echo "$as_me: failed program was:" >&5
35632 sed 's/^/| /' conftest.$ac_ext >&5
35633
35634 ( exit $ac_status )
35635 { { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
35636 See \`config.log' for more details." >&5
35637 echo "$as_me: error: cannot compute sizeof (short), 77
35638 See \`config.log' for more details." >&2;}
35639    { (exit 1); exit 1; }; }
35640 fi
35641 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
35642 fi
35643 fi
35644 rm -f conftest.val
35645 else
35646   ac_cv_sizeof_short=0
35647 fi
35648 fi
35649 echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
35650 echo "${ECHO_T}$ac_cv_sizeof_short" >&6
35651 cat >>confdefs.h <<_ACEOF
35652 #define SIZEOF_SHORT $ac_cv_sizeof_short
35653 _ACEOF
35654
35655
35656 echo "$as_me:$LINENO: checking for int" >&5
35657 echo $ECHO_N "checking for int... $ECHO_C" >&6
35658 if test "${ac_cv_type_int+set}" = set; then
35659   echo $ECHO_N "(cached) $ECHO_C" >&6
35660 else
35661   cat >conftest.$ac_ext <<_ACEOF
35662 /* confdefs.h.  */
35663 _ACEOF
35664 cat confdefs.h >>conftest.$ac_ext
35665 cat >>conftest.$ac_ext <<_ACEOF
35666 /* end confdefs.h.  */
35667 $ac_includes_default
35668 int
35669 main ()
35670 {
35671 if ((int *) 0)
35672   return 0;
35673 if (sizeof (int))
35674   return 0;
35675   ;
35676   return 0;
35677 }
35678 _ACEOF
35679 rm -f conftest.$ac_objext
35680 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35681   (eval $ac_compile) 2>conftest.er1
35682   ac_status=$?
35683   grep -v '^ *+' conftest.er1 >conftest.err
35684   rm -f conftest.er1
35685   cat conftest.err >&5
35686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35687   (exit $ac_status); } &&
35688          { ac_try='test -z "$ac_c_werror_flag"
35689                          || test ! -s conftest.err'
35690   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35691   (eval $ac_try) 2>&5
35692   ac_status=$?
35693   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35694   (exit $ac_status); }; } &&
35695          { ac_try='test -s conftest.$ac_objext'
35696   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35697   (eval $ac_try) 2>&5
35698   ac_status=$?
35699   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35700   (exit $ac_status); }; }; then
35701   ac_cv_type_int=yes
35702 else
35703   echo "$as_me: failed program was:" >&5
35704 sed 's/^/| /' conftest.$ac_ext >&5
35705
35706 ac_cv_type_int=no
35707 fi
35708 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35709 fi
35710 echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
35711 echo "${ECHO_T}$ac_cv_type_int" >&6
35712
35713 echo "$as_me:$LINENO: checking size of int" >&5
35714 echo $ECHO_N "checking size of int... $ECHO_C" >&6
35715 if test "${ac_cv_sizeof_int+set}" = set; then
35716   echo $ECHO_N "(cached) $ECHO_C" >&6
35717 else
35718   if test "$ac_cv_type_int" = yes; then
35719   # The cast to unsigned long works around a bug in the HP C Compiler
35720   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
35721   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
35722   # This bug is HP SR number 8606223364.
35723   if test "$cross_compiling" = yes; then
35724   # Depending upon the size, compute the lo and hi bounds.
35725 cat >conftest.$ac_ext <<_ACEOF
35726 /* confdefs.h.  */
35727 _ACEOF
35728 cat confdefs.h >>conftest.$ac_ext
35729 cat >>conftest.$ac_ext <<_ACEOF
35730 /* end confdefs.h.  */
35731 $ac_includes_default
35732 int
35733 main ()
35734 {
35735 static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
35736 test_array [0] = 0
35737
35738   ;
35739   return 0;
35740 }
35741 _ACEOF
35742 rm -f conftest.$ac_objext
35743 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35744   (eval $ac_compile) 2>conftest.er1
35745   ac_status=$?
35746   grep -v '^ *+' conftest.er1 >conftest.err
35747   rm -f conftest.er1
35748   cat conftest.err >&5
35749   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35750   (exit $ac_status); } &&
35751          { ac_try='test -z "$ac_c_werror_flag"
35752                          || test ! -s conftest.err'
35753   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35754   (eval $ac_try) 2>&5
35755   ac_status=$?
35756   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35757   (exit $ac_status); }; } &&
35758          { ac_try='test -s conftest.$ac_objext'
35759   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35760   (eval $ac_try) 2>&5
35761   ac_status=$?
35762   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35763   (exit $ac_status); }; }; then
35764   ac_lo=0 ac_mid=0
35765   while :; do
35766     cat >conftest.$ac_ext <<_ACEOF
35767 /* confdefs.h.  */
35768 _ACEOF
35769 cat confdefs.h >>conftest.$ac_ext
35770 cat >>conftest.$ac_ext <<_ACEOF
35771 /* end confdefs.h.  */
35772 $ac_includes_default
35773 int
35774 main ()
35775 {
35776 static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
35777 test_array [0] = 0
35778
35779   ;
35780   return 0;
35781 }
35782 _ACEOF
35783 rm -f conftest.$ac_objext
35784 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35785   (eval $ac_compile) 2>conftest.er1
35786   ac_status=$?
35787   grep -v '^ *+' conftest.er1 >conftest.err
35788   rm -f conftest.er1
35789   cat conftest.err >&5
35790   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35791   (exit $ac_status); } &&
35792          { ac_try='test -z "$ac_c_werror_flag"
35793                          || test ! -s conftest.err'
35794   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35795   (eval $ac_try) 2>&5
35796   ac_status=$?
35797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35798   (exit $ac_status); }; } &&
35799          { ac_try='test -s conftest.$ac_objext'
35800   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35801   (eval $ac_try) 2>&5
35802   ac_status=$?
35803   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35804   (exit $ac_status); }; }; then
35805   ac_hi=$ac_mid; break
35806 else
35807   echo "$as_me: failed program was:" >&5
35808 sed 's/^/| /' conftest.$ac_ext >&5
35809
35810 ac_lo=`expr $ac_mid + 1`
35811                     if test $ac_lo -le $ac_mid; then
35812                       ac_lo= ac_hi=
35813                       break
35814                     fi
35815                     ac_mid=`expr 2 '*' $ac_mid + 1`
35816 fi
35817 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35818   done
35819 else
35820   echo "$as_me: failed program was:" >&5
35821 sed 's/^/| /' conftest.$ac_ext >&5
35822
35823 cat >conftest.$ac_ext <<_ACEOF
35824 /* confdefs.h.  */
35825 _ACEOF
35826 cat confdefs.h >>conftest.$ac_ext
35827 cat >>conftest.$ac_ext <<_ACEOF
35828 /* end confdefs.h.  */
35829 $ac_includes_default
35830 int
35831 main ()
35832 {
35833 static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
35834 test_array [0] = 0
35835
35836   ;
35837   return 0;
35838 }
35839 _ACEOF
35840 rm -f conftest.$ac_objext
35841 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35842   (eval $ac_compile) 2>conftest.er1
35843   ac_status=$?
35844   grep -v '^ *+' conftest.er1 >conftest.err
35845   rm -f conftest.er1
35846   cat conftest.err >&5
35847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35848   (exit $ac_status); } &&
35849          { ac_try='test -z "$ac_c_werror_flag"
35850                          || test ! -s conftest.err'
35851   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35852   (eval $ac_try) 2>&5
35853   ac_status=$?
35854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35855   (exit $ac_status); }; } &&
35856          { ac_try='test -s conftest.$ac_objext'
35857   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35858   (eval $ac_try) 2>&5
35859   ac_status=$?
35860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35861   (exit $ac_status); }; }; then
35862   ac_hi=-1 ac_mid=-1
35863   while :; do
35864     cat >conftest.$ac_ext <<_ACEOF
35865 /* confdefs.h.  */
35866 _ACEOF
35867 cat confdefs.h >>conftest.$ac_ext
35868 cat >>conftest.$ac_ext <<_ACEOF
35869 /* end confdefs.h.  */
35870 $ac_includes_default
35871 int
35872 main ()
35873 {
35874 static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
35875 test_array [0] = 0
35876
35877   ;
35878   return 0;
35879 }
35880 _ACEOF
35881 rm -f conftest.$ac_objext
35882 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35883   (eval $ac_compile) 2>conftest.er1
35884   ac_status=$?
35885   grep -v '^ *+' conftest.er1 >conftest.err
35886   rm -f conftest.er1
35887   cat conftest.err >&5
35888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35889   (exit $ac_status); } &&
35890          { ac_try='test -z "$ac_c_werror_flag"
35891                          || test ! -s conftest.err'
35892   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35893   (eval $ac_try) 2>&5
35894   ac_status=$?
35895   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35896   (exit $ac_status); }; } &&
35897          { ac_try='test -s conftest.$ac_objext'
35898   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35899   (eval $ac_try) 2>&5
35900   ac_status=$?
35901   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35902   (exit $ac_status); }; }; then
35903   ac_lo=$ac_mid; break
35904 else
35905   echo "$as_me: failed program was:" >&5
35906 sed 's/^/| /' conftest.$ac_ext >&5
35907
35908 ac_hi=`expr '(' $ac_mid ')' - 1`
35909                        if test $ac_mid -le $ac_hi; then
35910                          ac_lo= ac_hi=
35911                          break
35912                        fi
35913                        ac_mid=`expr 2 '*' $ac_mid`
35914 fi
35915 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35916   done
35917 else
35918   echo "$as_me: failed program was:" >&5
35919 sed 's/^/| /' conftest.$ac_ext >&5
35920
35921 ac_lo= ac_hi=
35922 fi
35923 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35924 fi
35925 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35926 # Binary search between lo and hi bounds.
35927 while test "x$ac_lo" != "x$ac_hi"; do
35928   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
35929   cat >conftest.$ac_ext <<_ACEOF
35930 /* confdefs.h.  */
35931 _ACEOF
35932 cat confdefs.h >>conftest.$ac_ext
35933 cat >>conftest.$ac_ext <<_ACEOF
35934 /* end confdefs.h.  */
35935 $ac_includes_default
35936 int
35937 main ()
35938 {
35939 static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
35940 test_array [0] = 0
35941
35942   ;
35943   return 0;
35944 }
35945 _ACEOF
35946 rm -f conftest.$ac_objext
35947 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35948   (eval $ac_compile) 2>conftest.er1
35949   ac_status=$?
35950   grep -v '^ *+' conftest.er1 >conftest.err
35951   rm -f conftest.er1
35952   cat conftest.err >&5
35953   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35954   (exit $ac_status); } &&
35955          { ac_try='test -z "$ac_c_werror_flag"
35956                          || test ! -s conftest.err'
35957   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35958   (eval $ac_try) 2>&5
35959   ac_status=$?
35960   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35961   (exit $ac_status); }; } &&
35962          { ac_try='test -s conftest.$ac_objext'
35963   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35964   (eval $ac_try) 2>&5
35965   ac_status=$?
35966   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35967   (exit $ac_status); }; }; then
35968   ac_hi=$ac_mid
35969 else
35970   echo "$as_me: failed program was:" >&5
35971 sed 's/^/| /' conftest.$ac_ext >&5
35972
35973 ac_lo=`expr '(' $ac_mid ')' + 1`
35974 fi
35975 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35976 done
35977 case $ac_lo in
35978 ?*) ac_cv_sizeof_int=$ac_lo;;
35979 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
35980 See \`config.log' for more details." >&5
35981 echo "$as_me: error: cannot compute sizeof (int), 77
35982 See \`config.log' for more details." >&2;}
35983    { (exit 1); exit 1; }; } ;;
35984 esac
35985 else
35986   if test "$cross_compiling" = yes; then
35987   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
35988 See \`config.log' for more details." >&5
35989 echo "$as_me: error: cannot run test program while cross compiling
35990 See \`config.log' for more details." >&2;}
35991    { (exit 1); exit 1; }; }
35992 else
35993   cat >conftest.$ac_ext <<_ACEOF
35994 /* confdefs.h.  */
35995 _ACEOF
35996 cat confdefs.h >>conftest.$ac_ext
35997 cat >>conftest.$ac_ext <<_ACEOF
35998 /* end confdefs.h.  */
35999 $ac_includes_default
36000 long longval () { return (long) (sizeof (int)); }
36001 unsigned long ulongval () { return (long) (sizeof (int)); }
36002 #include <stdio.h>
36003 #include <stdlib.h>
36004 int
36005 main ()
36006 {
36007
36008   FILE *f = fopen ("conftest.val", "w");
36009   if (! f)
36010     exit (1);
36011   if (((long) (sizeof (int))) < 0)
36012     {
36013       long i = longval ();
36014       if (i != ((long) (sizeof (int))))
36015         exit (1);
36016       fprintf (f, "%ld\n", i);
36017     }
36018   else
36019     {
36020       unsigned long i = ulongval ();
36021       if (i != ((long) (sizeof (int))))
36022         exit (1);
36023       fprintf (f, "%lu\n", i);
36024     }
36025   exit (ferror (f) || fclose (f) != 0);
36026
36027   ;
36028   return 0;
36029 }
36030 _ACEOF
36031 rm -f conftest$ac_exeext
36032 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36033   (eval $ac_link) 2>&5
36034   ac_status=$?
36035   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36036   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
36037   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36038   (eval $ac_try) 2>&5
36039   ac_status=$?
36040   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36041   (exit $ac_status); }; }; then
36042   ac_cv_sizeof_int=`cat conftest.val`
36043 else
36044   echo "$as_me: program exited with status $ac_status" >&5
36045 echo "$as_me: failed program was:" >&5
36046 sed 's/^/| /' conftest.$ac_ext >&5
36047
36048 ( exit $ac_status )
36049 { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
36050 See \`config.log' for more details." >&5
36051 echo "$as_me: error: cannot compute sizeof (int), 77
36052 See \`config.log' for more details." >&2;}
36053    { (exit 1); exit 1; }; }
36054 fi
36055 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
36056 fi
36057 fi
36058 rm -f conftest.val
36059 else
36060   ac_cv_sizeof_int=0
36061 fi
36062 fi
36063 echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
36064 echo "${ECHO_T}$ac_cv_sizeof_int" >&6
36065 cat >>confdefs.h <<_ACEOF
36066 #define SIZEOF_INT $ac_cv_sizeof_int
36067 _ACEOF
36068
36069
36070 echo "$as_me:$LINENO: checking for long" >&5
36071 echo $ECHO_N "checking for long... $ECHO_C" >&6
36072 if test "${ac_cv_type_long+set}" = set; then
36073   echo $ECHO_N "(cached) $ECHO_C" >&6
36074 else
36075   cat >conftest.$ac_ext <<_ACEOF
36076 /* confdefs.h.  */
36077 _ACEOF
36078 cat confdefs.h >>conftest.$ac_ext
36079 cat >>conftest.$ac_ext <<_ACEOF
36080 /* end confdefs.h.  */
36081 $ac_includes_default
36082 int
36083 main ()
36084 {
36085 if ((long *) 0)
36086   return 0;
36087 if (sizeof (long))
36088   return 0;
36089   ;
36090   return 0;
36091 }
36092 _ACEOF
36093 rm -f conftest.$ac_objext
36094 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36095   (eval $ac_compile) 2>conftest.er1
36096   ac_status=$?
36097   grep -v '^ *+' conftest.er1 >conftest.err
36098   rm -f conftest.er1
36099   cat conftest.err >&5
36100   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36101   (exit $ac_status); } &&
36102          { ac_try='test -z "$ac_c_werror_flag"
36103                          || test ! -s conftest.err'
36104   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36105   (eval $ac_try) 2>&5
36106   ac_status=$?
36107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36108   (exit $ac_status); }; } &&
36109          { ac_try='test -s conftest.$ac_objext'
36110   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36111   (eval $ac_try) 2>&5
36112   ac_status=$?
36113   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36114   (exit $ac_status); }; }; then
36115   ac_cv_type_long=yes
36116 else
36117   echo "$as_me: failed program was:" >&5
36118 sed 's/^/| /' conftest.$ac_ext >&5
36119
36120 ac_cv_type_long=no
36121 fi
36122 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36123 fi
36124 echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
36125 echo "${ECHO_T}$ac_cv_type_long" >&6
36126
36127 echo "$as_me:$LINENO: checking size of long" >&5
36128 echo $ECHO_N "checking size of long... $ECHO_C" >&6
36129 if test "${ac_cv_sizeof_long+set}" = set; then
36130   echo $ECHO_N "(cached) $ECHO_C" >&6
36131 else
36132   if test "$ac_cv_type_long" = yes; then
36133   # The cast to unsigned long works around a bug in the HP C Compiler
36134   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
36135   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
36136   # This bug is HP SR number 8606223364.
36137   if test "$cross_compiling" = yes; then
36138   # Depending upon the size, compute the lo and hi bounds.
36139 cat >conftest.$ac_ext <<_ACEOF
36140 /* confdefs.h.  */
36141 _ACEOF
36142 cat confdefs.h >>conftest.$ac_ext
36143 cat >>conftest.$ac_ext <<_ACEOF
36144 /* end confdefs.h.  */
36145 $ac_includes_default
36146 int
36147 main ()
36148 {
36149 static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
36150 test_array [0] = 0
36151
36152   ;
36153   return 0;
36154 }
36155 _ACEOF
36156 rm -f conftest.$ac_objext
36157 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36158   (eval $ac_compile) 2>conftest.er1
36159   ac_status=$?
36160   grep -v '^ *+' conftest.er1 >conftest.err
36161   rm -f conftest.er1
36162   cat conftest.err >&5
36163   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36164   (exit $ac_status); } &&
36165          { ac_try='test -z "$ac_c_werror_flag"
36166                          || test ! -s conftest.err'
36167   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36168   (eval $ac_try) 2>&5
36169   ac_status=$?
36170   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36171   (exit $ac_status); }; } &&
36172          { ac_try='test -s conftest.$ac_objext'
36173   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36174   (eval $ac_try) 2>&5
36175   ac_status=$?
36176   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36177   (exit $ac_status); }; }; then
36178   ac_lo=0 ac_mid=0
36179   while :; do
36180     cat >conftest.$ac_ext <<_ACEOF
36181 /* confdefs.h.  */
36182 _ACEOF
36183 cat confdefs.h >>conftest.$ac_ext
36184 cat >>conftest.$ac_ext <<_ACEOF
36185 /* end confdefs.h.  */
36186 $ac_includes_default
36187 int
36188 main ()
36189 {
36190 static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
36191 test_array [0] = 0
36192
36193   ;
36194   return 0;
36195 }
36196 _ACEOF
36197 rm -f conftest.$ac_objext
36198 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36199   (eval $ac_compile) 2>conftest.er1
36200   ac_status=$?
36201   grep -v '^ *+' conftest.er1 >conftest.err
36202   rm -f conftest.er1
36203   cat conftest.err >&5
36204   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36205   (exit $ac_status); } &&
36206          { ac_try='test -z "$ac_c_werror_flag"
36207                          || test ! -s conftest.err'
36208   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36209   (eval $ac_try) 2>&5
36210   ac_status=$?
36211   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36212   (exit $ac_status); }; } &&
36213          { ac_try='test -s conftest.$ac_objext'
36214   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36215   (eval $ac_try) 2>&5
36216   ac_status=$?
36217   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36218   (exit $ac_status); }; }; then
36219   ac_hi=$ac_mid; break
36220 else
36221   echo "$as_me: failed program was:" >&5
36222 sed 's/^/| /' conftest.$ac_ext >&5
36223
36224 ac_lo=`expr $ac_mid + 1`
36225                     if test $ac_lo -le $ac_mid; then
36226                       ac_lo= ac_hi=
36227                       break
36228                     fi
36229                     ac_mid=`expr 2 '*' $ac_mid + 1`
36230 fi
36231 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36232   done
36233 else
36234   echo "$as_me: failed program was:" >&5
36235 sed 's/^/| /' conftest.$ac_ext >&5
36236
36237 cat >conftest.$ac_ext <<_ACEOF
36238 /* confdefs.h.  */
36239 _ACEOF
36240 cat confdefs.h >>conftest.$ac_ext
36241 cat >>conftest.$ac_ext <<_ACEOF
36242 /* end confdefs.h.  */
36243 $ac_includes_default
36244 int
36245 main ()
36246 {
36247 static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
36248 test_array [0] = 0
36249
36250   ;
36251   return 0;
36252 }
36253 _ACEOF
36254 rm -f conftest.$ac_objext
36255 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36256   (eval $ac_compile) 2>conftest.er1
36257   ac_status=$?
36258   grep -v '^ *+' conftest.er1 >conftest.err
36259   rm -f conftest.er1
36260   cat conftest.err >&5
36261   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36262   (exit $ac_status); } &&
36263          { ac_try='test -z "$ac_c_werror_flag"
36264                          || test ! -s conftest.err'
36265   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36266   (eval $ac_try) 2>&5
36267   ac_status=$?
36268   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36269   (exit $ac_status); }; } &&
36270          { ac_try='test -s conftest.$ac_objext'
36271   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36272   (eval $ac_try) 2>&5
36273   ac_status=$?
36274   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36275   (exit $ac_status); }; }; then
36276   ac_hi=-1 ac_mid=-1
36277   while :; do
36278     cat >conftest.$ac_ext <<_ACEOF
36279 /* confdefs.h.  */
36280 _ACEOF
36281 cat confdefs.h >>conftest.$ac_ext
36282 cat >>conftest.$ac_ext <<_ACEOF
36283 /* end confdefs.h.  */
36284 $ac_includes_default
36285 int
36286 main ()
36287 {
36288 static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
36289 test_array [0] = 0
36290
36291   ;
36292   return 0;
36293 }
36294 _ACEOF
36295 rm -f conftest.$ac_objext
36296 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36297   (eval $ac_compile) 2>conftest.er1
36298   ac_status=$?
36299   grep -v '^ *+' conftest.er1 >conftest.err
36300   rm -f conftest.er1
36301   cat conftest.err >&5
36302   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36303   (exit $ac_status); } &&
36304          { ac_try='test -z "$ac_c_werror_flag"
36305                          || test ! -s conftest.err'
36306   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36307   (eval $ac_try) 2>&5
36308   ac_status=$?
36309   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36310   (exit $ac_status); }; } &&
36311          { ac_try='test -s conftest.$ac_objext'
36312   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36313   (eval $ac_try) 2>&5
36314   ac_status=$?
36315   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36316   (exit $ac_status); }; }; then
36317   ac_lo=$ac_mid; break
36318 else
36319   echo "$as_me: failed program was:" >&5
36320 sed 's/^/| /' conftest.$ac_ext >&5
36321
36322 ac_hi=`expr '(' $ac_mid ')' - 1`
36323                        if test $ac_mid -le $ac_hi; then
36324                          ac_lo= ac_hi=
36325                          break
36326                        fi
36327                        ac_mid=`expr 2 '*' $ac_mid`
36328 fi
36329 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36330   done
36331 else
36332   echo "$as_me: failed program was:" >&5
36333 sed 's/^/| /' conftest.$ac_ext >&5
36334
36335 ac_lo= ac_hi=
36336 fi
36337 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36338 fi
36339 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36340 # Binary search between lo and hi bounds.
36341 while test "x$ac_lo" != "x$ac_hi"; do
36342   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
36343   cat >conftest.$ac_ext <<_ACEOF
36344 /* confdefs.h.  */
36345 _ACEOF
36346 cat confdefs.h >>conftest.$ac_ext
36347 cat >>conftest.$ac_ext <<_ACEOF
36348 /* end confdefs.h.  */
36349 $ac_includes_default
36350 int
36351 main ()
36352 {
36353 static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
36354 test_array [0] = 0
36355
36356   ;
36357   return 0;
36358 }
36359 _ACEOF
36360 rm -f conftest.$ac_objext
36361 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36362   (eval $ac_compile) 2>conftest.er1
36363   ac_status=$?
36364   grep -v '^ *+' conftest.er1 >conftest.err
36365   rm -f conftest.er1
36366   cat conftest.err >&5
36367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36368   (exit $ac_status); } &&
36369          { ac_try='test -z "$ac_c_werror_flag"
36370                          || test ! -s conftest.err'
36371   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36372   (eval $ac_try) 2>&5
36373   ac_status=$?
36374   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36375   (exit $ac_status); }; } &&
36376          { ac_try='test -s conftest.$ac_objext'
36377   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36378   (eval $ac_try) 2>&5
36379   ac_status=$?
36380   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36381   (exit $ac_status); }; }; then
36382   ac_hi=$ac_mid
36383 else
36384   echo "$as_me: failed program was:" >&5
36385 sed 's/^/| /' conftest.$ac_ext >&5
36386
36387 ac_lo=`expr '(' $ac_mid ')' + 1`
36388 fi
36389 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36390 done
36391 case $ac_lo in
36392 ?*) ac_cv_sizeof_long=$ac_lo;;
36393 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
36394 See \`config.log' for more details." >&5
36395 echo "$as_me: error: cannot compute sizeof (long), 77
36396 See \`config.log' for more details." >&2;}
36397    { (exit 1); exit 1; }; } ;;
36398 esac
36399 else
36400   if test "$cross_compiling" = yes; then
36401   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
36402 See \`config.log' for more details." >&5
36403 echo "$as_me: error: cannot run test program while cross compiling
36404 See \`config.log' for more details." >&2;}
36405    { (exit 1); exit 1; }; }
36406 else
36407   cat >conftest.$ac_ext <<_ACEOF
36408 /* confdefs.h.  */
36409 _ACEOF
36410 cat confdefs.h >>conftest.$ac_ext
36411 cat >>conftest.$ac_ext <<_ACEOF
36412 /* end confdefs.h.  */
36413 $ac_includes_default
36414 long longval () { return (long) (sizeof (long)); }
36415 unsigned long ulongval () { return (long) (sizeof (long)); }
36416 #include <stdio.h>
36417 #include <stdlib.h>
36418 int
36419 main ()
36420 {
36421
36422   FILE *f = fopen ("conftest.val", "w");
36423   if (! f)
36424     exit (1);
36425   if (((long) (sizeof (long))) < 0)
36426     {
36427       long i = longval ();
36428       if (i != ((long) (sizeof (long))))
36429         exit (1);
36430       fprintf (f, "%ld\n", i);
36431     }
36432   else
36433     {
36434       unsigned long i = ulongval ();
36435       if (i != ((long) (sizeof (long))))
36436         exit (1);
36437       fprintf (f, "%lu\n", i);
36438     }
36439   exit (ferror (f) || fclose (f) != 0);
36440
36441   ;
36442   return 0;
36443 }
36444 _ACEOF
36445 rm -f conftest$ac_exeext
36446 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36447   (eval $ac_link) 2>&5
36448   ac_status=$?
36449   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36450   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
36451   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36452   (eval $ac_try) 2>&5
36453   ac_status=$?
36454   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36455   (exit $ac_status); }; }; then
36456   ac_cv_sizeof_long=`cat conftest.val`
36457 else
36458   echo "$as_me: program exited with status $ac_status" >&5
36459 echo "$as_me: failed program was:" >&5
36460 sed 's/^/| /' conftest.$ac_ext >&5
36461
36462 ( exit $ac_status )
36463 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
36464 See \`config.log' for more details." >&5
36465 echo "$as_me: error: cannot compute sizeof (long), 77
36466 See \`config.log' for more details." >&2;}
36467    { (exit 1); exit 1; }; }
36468 fi
36469 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
36470 fi
36471 fi
36472 rm -f conftest.val
36473 else
36474   ac_cv_sizeof_long=0
36475 fi
36476 fi
36477 echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
36478 echo "${ECHO_T}$ac_cv_sizeof_long" >&6
36479 cat >>confdefs.h <<_ACEOF
36480 #define SIZEOF_LONG $ac_cv_sizeof_long
36481 _ACEOF
36482
36483
36484 echo "$as_me:$LINENO: checking for long long" >&5
36485 echo $ECHO_N "checking for long long... $ECHO_C" >&6
36486 if test "${ac_cv_type_long_long+set}" = set; then
36487   echo $ECHO_N "(cached) $ECHO_C" >&6
36488 else
36489   cat >conftest.$ac_ext <<_ACEOF
36490 /* confdefs.h.  */
36491 _ACEOF
36492 cat confdefs.h >>conftest.$ac_ext
36493 cat >>conftest.$ac_ext <<_ACEOF
36494 /* end confdefs.h.  */
36495 $ac_includes_default
36496 int
36497 main ()
36498 {
36499 if ((long long *) 0)
36500   return 0;
36501 if (sizeof (long long))
36502   return 0;
36503   ;
36504   return 0;
36505 }
36506 _ACEOF
36507 rm -f conftest.$ac_objext
36508 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36509   (eval $ac_compile) 2>conftest.er1
36510   ac_status=$?
36511   grep -v '^ *+' conftest.er1 >conftest.err
36512   rm -f conftest.er1
36513   cat conftest.err >&5
36514   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36515   (exit $ac_status); } &&
36516          { ac_try='test -z "$ac_c_werror_flag"
36517                          || test ! -s conftest.err'
36518   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36519   (eval $ac_try) 2>&5
36520   ac_status=$?
36521   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36522   (exit $ac_status); }; } &&
36523          { ac_try='test -s conftest.$ac_objext'
36524   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36525   (eval $ac_try) 2>&5
36526   ac_status=$?
36527   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36528   (exit $ac_status); }; }; then
36529   ac_cv_type_long_long=yes
36530 else
36531   echo "$as_me: failed program was:" >&5
36532 sed 's/^/| /' conftest.$ac_ext >&5
36533
36534 ac_cv_type_long_long=no
36535 fi
36536 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36537 fi
36538 echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
36539 echo "${ECHO_T}$ac_cv_type_long_long" >&6
36540
36541 echo "$as_me:$LINENO: checking size of long long" >&5
36542 echo $ECHO_N "checking size of long long... $ECHO_C" >&6
36543 if test "${ac_cv_sizeof_long_long+set}" = set; then
36544   echo $ECHO_N "(cached) $ECHO_C" >&6
36545 else
36546   if test "$ac_cv_type_long_long" = yes; then
36547   # The cast to unsigned long works around a bug in the HP C Compiler
36548   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
36549   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
36550   # This bug is HP SR number 8606223364.
36551   if test "$cross_compiling" = yes; then
36552   # Depending upon the size, compute the lo and hi bounds.
36553 cat >conftest.$ac_ext <<_ACEOF
36554 /* confdefs.h.  */
36555 _ACEOF
36556 cat confdefs.h >>conftest.$ac_ext
36557 cat >>conftest.$ac_ext <<_ACEOF
36558 /* end confdefs.h.  */
36559 $ac_includes_default
36560 int
36561 main ()
36562 {
36563 static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= 0)];
36564 test_array [0] = 0
36565
36566   ;
36567   return 0;
36568 }
36569 _ACEOF
36570 rm -f conftest.$ac_objext
36571 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36572   (eval $ac_compile) 2>conftest.er1
36573   ac_status=$?
36574   grep -v '^ *+' conftest.er1 >conftest.err
36575   rm -f conftest.er1
36576   cat conftest.err >&5
36577   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36578   (exit $ac_status); } &&
36579          { ac_try='test -z "$ac_c_werror_flag"
36580                          || test ! -s conftest.err'
36581   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36582   (eval $ac_try) 2>&5
36583   ac_status=$?
36584   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36585   (exit $ac_status); }; } &&
36586          { ac_try='test -s conftest.$ac_objext'
36587   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36588   (eval $ac_try) 2>&5
36589   ac_status=$?
36590   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36591   (exit $ac_status); }; }; then
36592   ac_lo=0 ac_mid=0
36593   while :; do
36594     cat >conftest.$ac_ext <<_ACEOF
36595 /* confdefs.h.  */
36596 _ACEOF
36597 cat confdefs.h >>conftest.$ac_ext
36598 cat >>conftest.$ac_ext <<_ACEOF
36599 /* end confdefs.h.  */
36600 $ac_includes_default
36601 int
36602 main ()
36603 {
36604 static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
36605 test_array [0] = 0
36606
36607   ;
36608   return 0;
36609 }
36610 _ACEOF
36611 rm -f conftest.$ac_objext
36612 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36613   (eval $ac_compile) 2>conftest.er1
36614   ac_status=$?
36615   grep -v '^ *+' conftest.er1 >conftest.err
36616   rm -f conftest.er1
36617   cat conftest.err >&5
36618   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36619   (exit $ac_status); } &&
36620          { ac_try='test -z "$ac_c_werror_flag"
36621                          || test ! -s conftest.err'
36622   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36623   (eval $ac_try) 2>&5
36624   ac_status=$?
36625   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36626   (exit $ac_status); }; } &&
36627          { ac_try='test -s conftest.$ac_objext'
36628   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36629   (eval $ac_try) 2>&5
36630   ac_status=$?
36631   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36632   (exit $ac_status); }; }; then
36633   ac_hi=$ac_mid; break
36634 else
36635   echo "$as_me: failed program was:" >&5
36636 sed 's/^/| /' conftest.$ac_ext >&5
36637
36638 ac_lo=`expr $ac_mid + 1`
36639                     if test $ac_lo -le $ac_mid; then
36640                       ac_lo= ac_hi=
36641                       break
36642                     fi
36643                     ac_mid=`expr 2 '*' $ac_mid + 1`
36644 fi
36645 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36646   done
36647 else
36648   echo "$as_me: failed program was:" >&5
36649 sed 's/^/| /' conftest.$ac_ext >&5
36650
36651 cat >conftest.$ac_ext <<_ACEOF
36652 /* confdefs.h.  */
36653 _ACEOF
36654 cat confdefs.h >>conftest.$ac_ext
36655 cat >>conftest.$ac_ext <<_ACEOF
36656 /* end confdefs.h.  */
36657 $ac_includes_default
36658 int
36659 main ()
36660 {
36661 static int test_array [1 - 2 * !(((long) (sizeof (long long))) < 0)];
36662 test_array [0] = 0
36663
36664   ;
36665   return 0;
36666 }
36667 _ACEOF
36668 rm -f conftest.$ac_objext
36669 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36670   (eval $ac_compile) 2>conftest.er1
36671   ac_status=$?
36672   grep -v '^ *+' conftest.er1 >conftest.err
36673   rm -f conftest.er1
36674   cat conftest.err >&5
36675   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36676   (exit $ac_status); } &&
36677          { ac_try='test -z "$ac_c_werror_flag"
36678                          || test ! -s conftest.err'
36679   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36680   (eval $ac_try) 2>&5
36681   ac_status=$?
36682   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36683   (exit $ac_status); }; } &&
36684          { ac_try='test -s conftest.$ac_objext'
36685   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36686   (eval $ac_try) 2>&5
36687   ac_status=$?
36688   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36689   (exit $ac_status); }; }; then
36690   ac_hi=-1 ac_mid=-1
36691   while :; do
36692     cat >conftest.$ac_ext <<_ACEOF
36693 /* confdefs.h.  */
36694 _ACEOF
36695 cat confdefs.h >>conftest.$ac_ext
36696 cat >>conftest.$ac_ext <<_ACEOF
36697 /* end confdefs.h.  */
36698 $ac_includes_default
36699 int
36700 main ()
36701 {
36702 static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= $ac_mid)];
36703 test_array [0] = 0
36704
36705   ;
36706   return 0;
36707 }
36708 _ACEOF
36709 rm -f conftest.$ac_objext
36710 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36711   (eval $ac_compile) 2>conftest.er1
36712   ac_status=$?
36713   grep -v '^ *+' conftest.er1 >conftest.err
36714   rm -f conftest.er1
36715   cat conftest.err >&5
36716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36717   (exit $ac_status); } &&
36718          { ac_try='test -z "$ac_c_werror_flag"
36719                          || test ! -s conftest.err'
36720   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36721   (eval $ac_try) 2>&5
36722   ac_status=$?
36723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36724   (exit $ac_status); }; } &&
36725          { ac_try='test -s conftest.$ac_objext'
36726   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36727   (eval $ac_try) 2>&5
36728   ac_status=$?
36729   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36730   (exit $ac_status); }; }; then
36731   ac_lo=$ac_mid; break
36732 else
36733   echo "$as_me: failed program was:" >&5
36734 sed 's/^/| /' conftest.$ac_ext >&5
36735
36736 ac_hi=`expr '(' $ac_mid ')' - 1`
36737                        if test $ac_mid -le $ac_hi; then
36738                          ac_lo= ac_hi=
36739                          break
36740                        fi
36741                        ac_mid=`expr 2 '*' $ac_mid`
36742 fi
36743 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36744   done
36745 else
36746   echo "$as_me: failed program was:" >&5
36747 sed 's/^/| /' conftest.$ac_ext >&5
36748
36749 ac_lo= ac_hi=
36750 fi
36751 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36752 fi
36753 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36754 # Binary search between lo and hi bounds.
36755 while test "x$ac_lo" != "x$ac_hi"; do
36756   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
36757   cat >conftest.$ac_ext <<_ACEOF
36758 /* confdefs.h.  */
36759 _ACEOF
36760 cat confdefs.h >>conftest.$ac_ext
36761 cat >>conftest.$ac_ext <<_ACEOF
36762 /* end confdefs.h.  */
36763 $ac_includes_default
36764 int
36765 main ()
36766 {
36767 static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
36768 test_array [0] = 0
36769
36770   ;
36771   return 0;
36772 }
36773 _ACEOF
36774 rm -f conftest.$ac_objext
36775 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36776   (eval $ac_compile) 2>conftest.er1
36777   ac_status=$?
36778   grep -v '^ *+' conftest.er1 >conftest.err
36779   rm -f conftest.er1
36780   cat conftest.err >&5
36781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36782   (exit $ac_status); } &&
36783          { ac_try='test -z "$ac_c_werror_flag"
36784                          || test ! -s conftest.err'
36785   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36786   (eval $ac_try) 2>&5
36787   ac_status=$?
36788   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36789   (exit $ac_status); }; } &&
36790          { ac_try='test -s conftest.$ac_objext'
36791   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36792   (eval $ac_try) 2>&5
36793   ac_status=$?
36794   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36795   (exit $ac_status); }; }; then
36796   ac_hi=$ac_mid
36797 else
36798   echo "$as_me: failed program was:" >&5
36799 sed 's/^/| /' conftest.$ac_ext >&5
36800
36801 ac_lo=`expr '(' $ac_mid ')' + 1`
36802 fi
36803 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36804 done
36805 case $ac_lo in
36806 ?*) ac_cv_sizeof_long_long=$ac_lo;;
36807 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
36808 See \`config.log' for more details." >&5
36809 echo "$as_me: error: cannot compute sizeof (long long), 77
36810 See \`config.log' for more details." >&2;}
36811    { (exit 1); exit 1; }; } ;;
36812 esac
36813 else
36814   if test "$cross_compiling" = yes; then
36815   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
36816 See \`config.log' for more details." >&5
36817 echo "$as_me: error: cannot run test program while cross compiling
36818 See \`config.log' for more details." >&2;}
36819    { (exit 1); exit 1; }; }
36820 else
36821   cat >conftest.$ac_ext <<_ACEOF
36822 /* confdefs.h.  */
36823 _ACEOF
36824 cat confdefs.h >>conftest.$ac_ext
36825 cat >>conftest.$ac_ext <<_ACEOF
36826 /* end confdefs.h.  */
36827 $ac_includes_default
36828 long longval () { return (long) (sizeof (long long)); }
36829 unsigned long ulongval () { return (long) (sizeof (long long)); }
36830 #include <stdio.h>
36831 #include <stdlib.h>
36832 int
36833 main ()
36834 {
36835
36836   FILE *f = fopen ("conftest.val", "w");
36837   if (! f)
36838     exit (1);
36839   if (((long) (sizeof (long long))) < 0)
36840     {
36841       long i = longval ();
36842       if (i != ((long) (sizeof (long long))))
36843         exit (1);
36844       fprintf (f, "%ld\n", i);
36845     }
36846   else
36847     {
36848       unsigned long i = ulongval ();
36849       if (i != ((long) (sizeof (long long))))
36850         exit (1);
36851       fprintf (f, "%lu\n", i);
36852     }
36853   exit (ferror (f) || fclose (f) != 0);
36854
36855   ;
36856   return 0;
36857 }
36858 _ACEOF
36859 rm -f conftest$ac_exeext
36860 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36861   (eval $ac_link) 2>&5
36862   ac_status=$?
36863   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36864   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
36865   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36866   (eval $ac_try) 2>&5
36867   ac_status=$?
36868   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36869   (exit $ac_status); }; }; then
36870   ac_cv_sizeof_long_long=`cat conftest.val`
36871 else
36872   echo "$as_me: program exited with status $ac_status" >&5
36873 echo "$as_me: failed program was:" >&5
36874 sed 's/^/| /' conftest.$ac_ext >&5
36875
36876 ( exit $ac_status )
36877 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
36878 See \`config.log' for more details." >&5
36879 echo "$as_me: error: cannot compute sizeof (long long), 77
36880 See \`config.log' for more details." >&2;}
36881    { (exit 1); exit 1; }; }
36882 fi
36883 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
36884 fi
36885 fi
36886 rm -f conftest.val
36887 else
36888   ac_cv_sizeof_long_long=0
36889 fi
36890 fi
36891 echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
36892 echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
36893 cat >>confdefs.h <<_ACEOF
36894 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
36895 _ACEOF
36896
36897
36898 echo "$as_me:$LINENO: checking for wchar_t" >&5
36899 echo $ECHO_N "checking for wchar_t... $ECHO_C" >&6
36900 if test "${ac_cv_type_wchar_t+set}" = set; then
36901   echo $ECHO_N "(cached) $ECHO_C" >&6
36902 else
36903   cat >conftest.$ac_ext <<_ACEOF
36904 /* confdefs.h.  */
36905 _ACEOF
36906 cat confdefs.h >>conftest.$ac_ext
36907 cat >>conftest.$ac_ext <<_ACEOF
36908 /* end confdefs.h.  */
36909 $ac_includes_default
36910 int
36911 main ()
36912 {
36913 if ((wchar_t *) 0)
36914   return 0;
36915 if (sizeof (wchar_t))
36916   return 0;
36917   ;
36918   return 0;
36919 }
36920 _ACEOF
36921 rm -f conftest.$ac_objext
36922 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36923   (eval $ac_compile) 2>conftest.er1
36924   ac_status=$?
36925   grep -v '^ *+' conftest.er1 >conftest.err
36926   rm -f conftest.er1
36927   cat conftest.err >&5
36928   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36929   (exit $ac_status); } &&
36930          { ac_try='test -z "$ac_c_werror_flag"
36931                          || test ! -s conftest.err'
36932   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36933   (eval $ac_try) 2>&5
36934   ac_status=$?
36935   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36936   (exit $ac_status); }; } &&
36937          { ac_try='test -s conftest.$ac_objext'
36938   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36939   (eval $ac_try) 2>&5
36940   ac_status=$?
36941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36942   (exit $ac_status); }; }; then
36943   ac_cv_type_wchar_t=yes
36944 else
36945   echo "$as_me: failed program was:" >&5
36946 sed 's/^/| /' conftest.$ac_ext >&5
36947
36948 ac_cv_type_wchar_t=no
36949 fi
36950 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36951 fi
36952 echo "$as_me:$LINENO: result: $ac_cv_type_wchar_t" >&5
36953 echo "${ECHO_T}$ac_cv_type_wchar_t" >&6
36954
36955 echo "$as_me:$LINENO: checking size of wchar_t" >&5
36956 echo $ECHO_N "checking size of wchar_t... $ECHO_C" >&6
36957 if test "${ac_cv_sizeof_wchar_t+set}" = set; then
36958   echo $ECHO_N "(cached) $ECHO_C" >&6
36959 else
36960   if test "$ac_cv_type_wchar_t" = yes; then
36961   # The cast to unsigned long works around a bug in the HP C Compiler
36962   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
36963   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
36964   # This bug is HP SR number 8606223364.
36965   if test "$cross_compiling" = yes; then
36966   # Depending upon the size, compute the lo and hi bounds.
36967 cat >conftest.$ac_ext <<_ACEOF
36968 /* confdefs.h.  */
36969 _ACEOF
36970 cat confdefs.h >>conftest.$ac_ext
36971 cat >>conftest.$ac_ext <<_ACEOF
36972 /* end confdefs.h.  */
36973 $ac_includes_default
36974 int
36975 main ()
36976 {
36977 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= 0)];
36978 test_array [0] = 0
36979
36980   ;
36981   return 0;
36982 }
36983 _ACEOF
36984 rm -f conftest.$ac_objext
36985 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36986   (eval $ac_compile) 2>conftest.er1
36987   ac_status=$?
36988   grep -v '^ *+' conftest.er1 >conftest.err
36989   rm -f conftest.er1
36990   cat conftest.err >&5
36991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36992   (exit $ac_status); } &&
36993          { ac_try='test -z "$ac_c_werror_flag"
36994                          || test ! -s conftest.err'
36995   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36996   (eval $ac_try) 2>&5
36997   ac_status=$?
36998   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36999   (exit $ac_status); }; } &&
37000          { ac_try='test -s conftest.$ac_objext'
37001   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37002   (eval $ac_try) 2>&5
37003   ac_status=$?
37004   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37005   (exit $ac_status); }; }; then
37006   ac_lo=0 ac_mid=0
37007   while :; do
37008     cat >conftest.$ac_ext <<_ACEOF
37009 /* confdefs.h.  */
37010 _ACEOF
37011 cat confdefs.h >>conftest.$ac_ext
37012 cat >>conftest.$ac_ext <<_ACEOF
37013 /* end confdefs.h.  */
37014 $ac_includes_default
37015 int
37016 main ()
37017 {
37018 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
37019 test_array [0] = 0
37020
37021   ;
37022   return 0;
37023 }
37024 _ACEOF
37025 rm -f conftest.$ac_objext
37026 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37027   (eval $ac_compile) 2>conftest.er1
37028   ac_status=$?
37029   grep -v '^ *+' conftest.er1 >conftest.err
37030   rm -f conftest.er1
37031   cat conftest.err >&5
37032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37033   (exit $ac_status); } &&
37034          { ac_try='test -z "$ac_c_werror_flag"
37035                          || test ! -s conftest.err'
37036   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37037   (eval $ac_try) 2>&5
37038   ac_status=$?
37039   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37040   (exit $ac_status); }; } &&
37041          { ac_try='test -s conftest.$ac_objext'
37042   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37043   (eval $ac_try) 2>&5
37044   ac_status=$?
37045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37046   (exit $ac_status); }; }; then
37047   ac_hi=$ac_mid; break
37048 else
37049   echo "$as_me: failed program was:" >&5
37050 sed 's/^/| /' conftest.$ac_ext >&5
37051
37052 ac_lo=`expr $ac_mid + 1`
37053                     if test $ac_lo -le $ac_mid; then
37054                       ac_lo= ac_hi=
37055                       break
37056                     fi
37057                     ac_mid=`expr 2 '*' $ac_mid + 1`
37058 fi
37059 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37060   done
37061 else
37062   echo "$as_me: failed program was:" >&5
37063 sed 's/^/| /' conftest.$ac_ext >&5
37064
37065 cat >conftest.$ac_ext <<_ACEOF
37066 /* confdefs.h.  */
37067 _ACEOF
37068 cat confdefs.h >>conftest.$ac_ext
37069 cat >>conftest.$ac_ext <<_ACEOF
37070 /* end confdefs.h.  */
37071 $ac_includes_default
37072 int
37073 main ()
37074 {
37075 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) < 0)];
37076 test_array [0] = 0
37077
37078   ;
37079   return 0;
37080 }
37081 _ACEOF
37082 rm -f conftest.$ac_objext
37083 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37084   (eval $ac_compile) 2>conftest.er1
37085   ac_status=$?
37086   grep -v '^ *+' conftest.er1 >conftest.err
37087   rm -f conftest.er1
37088   cat conftest.err >&5
37089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37090   (exit $ac_status); } &&
37091          { ac_try='test -z "$ac_c_werror_flag"
37092                          || test ! -s conftest.err'
37093   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37094   (eval $ac_try) 2>&5
37095   ac_status=$?
37096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37097   (exit $ac_status); }; } &&
37098          { ac_try='test -s conftest.$ac_objext'
37099   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37100   (eval $ac_try) 2>&5
37101   ac_status=$?
37102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37103   (exit $ac_status); }; }; then
37104   ac_hi=-1 ac_mid=-1
37105   while :; do
37106     cat >conftest.$ac_ext <<_ACEOF
37107 /* confdefs.h.  */
37108 _ACEOF
37109 cat confdefs.h >>conftest.$ac_ext
37110 cat >>conftest.$ac_ext <<_ACEOF
37111 /* end confdefs.h.  */
37112 $ac_includes_default
37113 int
37114 main ()
37115 {
37116 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= $ac_mid)];
37117 test_array [0] = 0
37118
37119   ;
37120   return 0;
37121 }
37122 _ACEOF
37123 rm -f conftest.$ac_objext
37124 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37125   (eval $ac_compile) 2>conftest.er1
37126   ac_status=$?
37127   grep -v '^ *+' conftest.er1 >conftest.err
37128   rm -f conftest.er1
37129   cat conftest.err >&5
37130   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37131   (exit $ac_status); } &&
37132          { ac_try='test -z "$ac_c_werror_flag"
37133                          || test ! -s conftest.err'
37134   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37135   (eval $ac_try) 2>&5
37136   ac_status=$?
37137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37138   (exit $ac_status); }; } &&
37139          { ac_try='test -s conftest.$ac_objext'
37140   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37141   (eval $ac_try) 2>&5
37142   ac_status=$?
37143   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37144   (exit $ac_status); }; }; then
37145   ac_lo=$ac_mid; break
37146 else
37147   echo "$as_me: failed program was:" >&5
37148 sed 's/^/| /' conftest.$ac_ext >&5
37149
37150 ac_hi=`expr '(' $ac_mid ')' - 1`
37151                        if test $ac_mid -le $ac_hi; then
37152                          ac_lo= ac_hi=
37153                          break
37154                        fi
37155                        ac_mid=`expr 2 '*' $ac_mid`
37156 fi
37157 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37158   done
37159 else
37160   echo "$as_me: failed program was:" >&5
37161 sed 's/^/| /' conftest.$ac_ext >&5
37162
37163 ac_lo= ac_hi=
37164 fi
37165 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37166 fi
37167 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37168 # Binary search between lo and hi bounds.
37169 while test "x$ac_lo" != "x$ac_hi"; do
37170   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
37171   cat >conftest.$ac_ext <<_ACEOF
37172 /* confdefs.h.  */
37173 _ACEOF
37174 cat confdefs.h >>conftest.$ac_ext
37175 cat >>conftest.$ac_ext <<_ACEOF
37176 /* end confdefs.h.  */
37177 $ac_includes_default
37178 int
37179 main ()
37180 {
37181 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
37182 test_array [0] = 0
37183
37184   ;
37185   return 0;
37186 }
37187 _ACEOF
37188 rm -f conftest.$ac_objext
37189 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37190   (eval $ac_compile) 2>conftest.er1
37191   ac_status=$?
37192   grep -v '^ *+' conftest.er1 >conftest.err
37193   rm -f conftest.er1
37194   cat conftest.err >&5
37195   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37196   (exit $ac_status); } &&
37197          { ac_try='test -z "$ac_c_werror_flag"
37198                          || test ! -s conftest.err'
37199   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37200   (eval $ac_try) 2>&5
37201   ac_status=$?
37202   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37203   (exit $ac_status); }; } &&
37204          { ac_try='test -s conftest.$ac_objext'
37205   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37206   (eval $ac_try) 2>&5
37207   ac_status=$?
37208   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37209   (exit $ac_status); }; }; then
37210   ac_hi=$ac_mid
37211 else
37212   echo "$as_me: failed program was:" >&5
37213 sed 's/^/| /' conftest.$ac_ext >&5
37214
37215 ac_lo=`expr '(' $ac_mid ')' + 1`
37216 fi
37217 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37218 done
37219 case $ac_lo in
37220 ?*) ac_cv_sizeof_wchar_t=$ac_lo;;
37221 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77
37222 See \`config.log' for more details." >&5
37223 echo "$as_me: error: cannot compute sizeof (wchar_t), 77
37224 See \`config.log' for more details." >&2;}
37225    { (exit 1); exit 1; }; } ;;
37226 esac
37227 else
37228   if test "$cross_compiling" = yes; then
37229   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
37230 See \`config.log' for more details." >&5
37231 echo "$as_me: error: cannot run test program while cross compiling
37232 See \`config.log' for more details." >&2;}
37233    { (exit 1); exit 1; }; }
37234 else
37235   cat >conftest.$ac_ext <<_ACEOF
37236 /* confdefs.h.  */
37237 _ACEOF
37238 cat confdefs.h >>conftest.$ac_ext
37239 cat >>conftest.$ac_ext <<_ACEOF
37240 /* end confdefs.h.  */
37241 $ac_includes_default
37242 long longval () { return (long) (sizeof (wchar_t)); }
37243 unsigned long ulongval () { return (long) (sizeof (wchar_t)); }
37244 #include <stdio.h>
37245 #include <stdlib.h>
37246 int
37247 main ()
37248 {
37249
37250   FILE *f = fopen ("conftest.val", "w");
37251   if (! f)
37252     exit (1);
37253   if (((long) (sizeof (wchar_t))) < 0)
37254     {
37255       long i = longval ();
37256       if (i != ((long) (sizeof (wchar_t))))
37257         exit (1);
37258       fprintf (f, "%ld\n", i);
37259     }
37260   else
37261     {
37262       unsigned long i = ulongval ();
37263       if (i != ((long) (sizeof (wchar_t))))
37264         exit (1);
37265       fprintf (f, "%lu\n", i);
37266     }
37267   exit (ferror (f) || fclose (f) != 0);
37268
37269   ;
37270   return 0;
37271 }
37272 _ACEOF
37273 rm -f conftest$ac_exeext
37274 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37275   (eval $ac_link) 2>&5
37276   ac_status=$?
37277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37278   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
37279   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37280   (eval $ac_try) 2>&5
37281   ac_status=$?
37282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37283   (exit $ac_status); }; }; then
37284   ac_cv_sizeof_wchar_t=`cat conftest.val`
37285 else
37286   echo "$as_me: program exited with status $ac_status" >&5
37287 echo "$as_me: failed program was:" >&5
37288 sed 's/^/| /' conftest.$ac_ext >&5
37289
37290 ( exit $ac_status )
37291 { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77
37292 See \`config.log' for more details." >&5
37293 echo "$as_me: error: cannot compute sizeof (wchar_t), 77
37294 See \`config.log' for more details." >&2;}
37295    { (exit 1); exit 1; }; }
37296 fi
37297 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
37298 fi
37299 fi
37300 rm -f conftest.val
37301 else
37302   ac_cv_sizeof_wchar_t=0
37303 fi
37304 fi
37305 echo "$as_me:$LINENO: result: $ac_cv_sizeof_wchar_t" >&5
37306 echo "${ECHO_T}$ac_cv_sizeof_wchar_t" >&6
37307 cat >>confdefs.h <<_ACEOF
37308 #define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t
37309 _ACEOF
37310
37311
37312
37313 if test "$ac_cv_sizeof_int" -lt 4 ; then
37314         { echo "$as_me:$LINENO: WARNING: OpenLDAP requires 'int' to be 32 bits or greater." >&5
37315 echo "$as_me: WARNING: OpenLDAP requires 'int' to be 32 bits or greater." >&2;}
37316
37317
37318 cat >>confdefs.h <<\_ACEOF
37319 #define LBER_INT_T long
37320 _ACEOF
37321
37322 else
37323
37324 cat >>confdefs.h <<\_ACEOF
37325 #define LBER_INT_T int
37326 _ACEOF
37327
37328 fi
37329
37330
37331 cat >>confdefs.h <<\_ACEOF
37332 #define LBER_LEN_T long
37333 _ACEOF
37334
37335
37336 cat >>confdefs.h <<\_ACEOF
37337 #define LBER_SOCKET_T int
37338 _ACEOF
37339
37340
37341 cat >>confdefs.h <<\_ACEOF
37342 #define LBER_TAG_T long
37343 _ACEOF
37344
37345
37346 if test $ol_with_mp = longlong || test $ol_with_mp = auto ; then
37347         if test $ac_cv_sizeof_long_long -gt 4 ; then
37348                 ol_with_mp=longlong
37349
37350 cat >>confdefs.h <<\_ACEOF
37351 #define USE_MP_LONG_LONG 1
37352 _ACEOF
37353
37354         elif test $ol_with_mp = longlong ; then
37355                 { { echo "$as_me:$LINENO: error: long long unusable for multiple precision" >&5
37356 echo "$as_me: error: long long unusable for multiple precision" >&2;}
37357    { (exit 1); exit 1; }; }
37358         fi
37359 fi
37360 if test $ol_with_mp = long || test $ol_with_mp = auto ; then
37361         if test $ac_cv_sizeof_long -gt 4 ; then
37362                 ol_with_mp=long
37363
37364 cat >>confdefs.h <<\_ACEOF
37365 #define USE_MP_LONG 1
37366 _ACEOF
37367
37368         elif test $ol_with_mp = long ; then
37369                 { { echo "$as_me:$LINENO: error: long unusable for multiple precision" >&5
37370 echo "$as_me: error: long unusable for multiple precision" >&2;}
37371    { (exit 1); exit 1; }; }
37372         fi
37373 fi
37374 if test $ol_with_mp = bignum || test $ol_with_mp = auto ; then
37375
37376 for ac_header in openssl/bn.h
37377 do
37378 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
37379 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37380   echo "$as_me:$LINENO: checking for $ac_header" >&5
37381 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37382 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37383   echo $ECHO_N "(cached) $ECHO_C" >&6
37384 fi
37385 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37386 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37387 else
37388   # Is the header compilable?
37389 echo "$as_me:$LINENO: checking $ac_header usability" >&5
37390 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
37391 cat >conftest.$ac_ext <<_ACEOF
37392 /* confdefs.h.  */
37393 _ACEOF
37394 cat confdefs.h >>conftest.$ac_ext
37395 cat >>conftest.$ac_ext <<_ACEOF
37396 /* end confdefs.h.  */
37397 $ac_includes_default
37398 #include <$ac_header>
37399 _ACEOF
37400 rm -f conftest.$ac_objext
37401 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37402   (eval $ac_compile) 2>conftest.er1
37403   ac_status=$?
37404   grep -v '^ *+' conftest.er1 >conftest.err
37405   rm -f conftest.er1
37406   cat conftest.err >&5
37407   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37408   (exit $ac_status); } &&
37409          { ac_try='test -z "$ac_c_werror_flag"
37410                          || test ! -s conftest.err'
37411   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37412   (eval $ac_try) 2>&5
37413   ac_status=$?
37414   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37415   (exit $ac_status); }; } &&
37416          { ac_try='test -s conftest.$ac_objext'
37417   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37418   (eval $ac_try) 2>&5
37419   ac_status=$?
37420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37421   (exit $ac_status); }; }; then
37422   ac_header_compiler=yes
37423 else
37424   echo "$as_me: failed program was:" >&5
37425 sed 's/^/| /' conftest.$ac_ext >&5
37426
37427 ac_header_compiler=no
37428 fi
37429 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37430 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
37431 echo "${ECHO_T}$ac_header_compiler" >&6
37432
37433 # Is the header present?
37434 echo "$as_me:$LINENO: checking $ac_header presence" >&5
37435 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
37436 cat >conftest.$ac_ext <<_ACEOF
37437 /* confdefs.h.  */
37438 _ACEOF
37439 cat confdefs.h >>conftest.$ac_ext
37440 cat >>conftest.$ac_ext <<_ACEOF
37441 /* end confdefs.h.  */
37442 #include <$ac_header>
37443 _ACEOF
37444 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
37445   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
37446   ac_status=$?
37447   grep -v '^ *+' conftest.er1 >conftest.err
37448   rm -f conftest.er1
37449   cat conftest.err >&5
37450   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37451   (exit $ac_status); } >/dev/null; then
37452   if test -s conftest.err; then
37453     ac_cpp_err=$ac_c_preproc_warn_flag
37454     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
37455   else
37456     ac_cpp_err=
37457   fi
37458 else
37459   ac_cpp_err=yes
37460 fi
37461 if test -z "$ac_cpp_err"; then
37462   ac_header_preproc=yes
37463 else
37464   echo "$as_me: failed program was:" >&5
37465 sed 's/^/| /' conftest.$ac_ext >&5
37466
37467   ac_header_preproc=no
37468 fi
37469 rm -f conftest.err conftest.$ac_ext
37470 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
37471 echo "${ECHO_T}$ac_header_preproc" >&6
37472
37473 # So?  What about this header?
37474 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
37475   yes:no: )
37476     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
37477 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
37478     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
37479 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
37480     ac_header_preproc=yes
37481     ;;
37482   no:yes:* )
37483     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
37484 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
37485     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
37486 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
37487     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
37488 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
37489     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
37490 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
37491     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
37492 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
37493     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
37494 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
37495     (
37496       cat <<\_ASBOX
37497 ## --------------------------------------------- ##
37498 ## Report this to <http://www.openldap.org/its/> ##
37499 ## --------------------------------------------- ##
37500 _ASBOX
37501     ) |
37502       sed "s/^/$as_me: WARNING:     /" >&2
37503     ;;
37504 esac
37505 echo "$as_me:$LINENO: checking for $ac_header" >&5
37506 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37507 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37508   echo $ECHO_N "(cached) $ECHO_C" >&6
37509 else
37510   eval "$as_ac_Header=\$ac_header_preproc"
37511 fi
37512 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37513 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37514
37515 fi
37516 if test `eval echo '${'$as_ac_Header'}'` = yes; then
37517   cat >>confdefs.h <<_ACEOF
37518 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
37519 _ACEOF
37520
37521 fi
37522
37523 done
37524
37525
37526 for ac_header in openssl/crypto.h
37527 do
37528 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
37529 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37530   echo "$as_me:$LINENO: checking for $ac_header" >&5
37531 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37532 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37533   echo $ECHO_N "(cached) $ECHO_C" >&6
37534 fi
37535 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37536 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37537 else
37538   # Is the header compilable?
37539 echo "$as_me:$LINENO: checking $ac_header usability" >&5
37540 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
37541 cat >conftest.$ac_ext <<_ACEOF
37542 /* confdefs.h.  */
37543 _ACEOF
37544 cat confdefs.h >>conftest.$ac_ext
37545 cat >>conftest.$ac_ext <<_ACEOF
37546 /* end confdefs.h.  */
37547 $ac_includes_default
37548 #include <$ac_header>
37549 _ACEOF
37550 rm -f conftest.$ac_objext
37551 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37552   (eval $ac_compile) 2>conftest.er1
37553   ac_status=$?
37554   grep -v '^ *+' conftest.er1 >conftest.err
37555   rm -f conftest.er1
37556   cat conftest.err >&5
37557   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37558   (exit $ac_status); } &&
37559          { ac_try='test -z "$ac_c_werror_flag"
37560                          || test ! -s conftest.err'
37561   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37562   (eval $ac_try) 2>&5
37563   ac_status=$?
37564   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37565   (exit $ac_status); }; } &&
37566          { ac_try='test -s conftest.$ac_objext'
37567   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37568   (eval $ac_try) 2>&5
37569   ac_status=$?
37570   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37571   (exit $ac_status); }; }; then
37572   ac_header_compiler=yes
37573 else
37574   echo "$as_me: failed program was:" >&5
37575 sed 's/^/| /' conftest.$ac_ext >&5
37576
37577 ac_header_compiler=no
37578 fi
37579 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37580 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
37581 echo "${ECHO_T}$ac_header_compiler" >&6
37582
37583 # Is the header present?
37584 echo "$as_me:$LINENO: checking $ac_header presence" >&5
37585 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
37586 cat >conftest.$ac_ext <<_ACEOF
37587 /* confdefs.h.  */
37588 _ACEOF
37589 cat confdefs.h >>conftest.$ac_ext
37590 cat >>conftest.$ac_ext <<_ACEOF
37591 /* end confdefs.h.  */
37592 #include <$ac_header>
37593 _ACEOF
37594 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
37595   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
37596   ac_status=$?
37597   grep -v '^ *+' conftest.er1 >conftest.err
37598   rm -f conftest.er1
37599   cat conftest.err >&5
37600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37601   (exit $ac_status); } >/dev/null; then
37602   if test -s conftest.err; then
37603     ac_cpp_err=$ac_c_preproc_warn_flag
37604     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
37605   else
37606     ac_cpp_err=
37607   fi
37608 else
37609   ac_cpp_err=yes
37610 fi
37611 if test -z "$ac_cpp_err"; then
37612   ac_header_preproc=yes
37613 else
37614   echo "$as_me: failed program was:" >&5
37615 sed 's/^/| /' conftest.$ac_ext >&5
37616
37617   ac_header_preproc=no
37618 fi
37619 rm -f conftest.err conftest.$ac_ext
37620 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
37621 echo "${ECHO_T}$ac_header_preproc" >&6
37622
37623 # So?  What about this header?
37624 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
37625   yes:no: )
37626     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
37627 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
37628     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
37629 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
37630     ac_header_preproc=yes
37631     ;;
37632   no:yes:* )
37633     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
37634 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
37635     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
37636 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
37637     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
37638 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
37639     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
37640 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
37641     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
37642 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
37643     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
37644 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
37645     (
37646       cat <<\_ASBOX
37647 ## --------------------------------------------- ##
37648 ## Report this to <http://www.openldap.org/its/> ##
37649 ## --------------------------------------------- ##
37650 _ASBOX
37651     ) |
37652       sed "s/^/$as_me: WARNING:     /" >&2
37653     ;;
37654 esac
37655 echo "$as_me:$LINENO: checking for $ac_header" >&5
37656 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37657 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37658   echo $ECHO_N "(cached) $ECHO_C" >&6
37659 else
37660   eval "$as_ac_Header=\$ac_header_preproc"
37661 fi
37662 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37663 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37664
37665 fi
37666 if test `eval echo '${'$as_ac_Header'}'` = yes; then
37667   cat >>confdefs.h <<_ACEOF
37668 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
37669 _ACEOF
37670
37671 fi
37672
37673 done
37674
37675         if test "$ac_cv_header_openssl_bn_h" = "yes" &&
37676                 test "$ac_cv_header_openssl_crypto_h" = "yes" &&
37677                 test "$ol_with_tls" = "found" ; then
37678                 ol_with_mp=bignum
37679
37680 cat >>confdefs.h <<\_ACEOF
37681 #define USE_MP_BIGNUM 1
37682 _ACEOF
37683
37684         elif test $ol_with_mp = bignum ; then
37685                 { { echo "$as_me:$LINENO: error: bignum not available" >&5
37686 echo "$as_me: error: bignum not available" >&2;}
37687    { (exit 1); exit 1; }; }
37688         fi
37689 fi
37690 if test $ol_with_mp = gmp || test $ol_with_mp = auto ; then
37691
37692 for ac_header in gmp.h
37693 do
37694 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
37695 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37696   echo "$as_me:$LINENO: checking for $ac_header" >&5
37697 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37698 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37699   echo $ECHO_N "(cached) $ECHO_C" >&6
37700 fi
37701 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37702 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37703 else
37704   # Is the header compilable?
37705 echo "$as_me:$LINENO: checking $ac_header usability" >&5
37706 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
37707 cat >conftest.$ac_ext <<_ACEOF
37708 /* confdefs.h.  */
37709 _ACEOF
37710 cat confdefs.h >>conftest.$ac_ext
37711 cat >>conftest.$ac_ext <<_ACEOF
37712 /* end confdefs.h.  */
37713 $ac_includes_default
37714 #include <$ac_header>
37715 _ACEOF
37716 rm -f conftest.$ac_objext
37717 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37718   (eval $ac_compile) 2>conftest.er1
37719   ac_status=$?
37720   grep -v '^ *+' conftest.er1 >conftest.err
37721   rm -f conftest.er1
37722   cat conftest.err >&5
37723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37724   (exit $ac_status); } &&
37725          { ac_try='test -z "$ac_c_werror_flag"
37726                          || test ! -s conftest.err'
37727   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37728   (eval $ac_try) 2>&5
37729   ac_status=$?
37730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37731   (exit $ac_status); }; } &&
37732          { ac_try='test -s conftest.$ac_objext'
37733   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37734   (eval $ac_try) 2>&5
37735   ac_status=$?
37736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37737   (exit $ac_status); }; }; then
37738   ac_header_compiler=yes
37739 else
37740   echo "$as_me: failed program was:" >&5
37741 sed 's/^/| /' conftest.$ac_ext >&5
37742
37743 ac_header_compiler=no
37744 fi
37745 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37746 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
37747 echo "${ECHO_T}$ac_header_compiler" >&6
37748
37749 # Is the header present?
37750 echo "$as_me:$LINENO: checking $ac_header presence" >&5
37751 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
37752 cat >conftest.$ac_ext <<_ACEOF
37753 /* confdefs.h.  */
37754 _ACEOF
37755 cat confdefs.h >>conftest.$ac_ext
37756 cat >>conftest.$ac_ext <<_ACEOF
37757 /* end confdefs.h.  */
37758 #include <$ac_header>
37759 _ACEOF
37760 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
37761   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
37762   ac_status=$?
37763   grep -v '^ *+' conftest.er1 >conftest.err
37764   rm -f conftest.er1
37765   cat conftest.err >&5
37766   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37767   (exit $ac_status); } >/dev/null; then
37768   if test -s conftest.err; then
37769     ac_cpp_err=$ac_c_preproc_warn_flag
37770     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
37771   else
37772     ac_cpp_err=
37773   fi
37774 else
37775   ac_cpp_err=yes
37776 fi
37777 if test -z "$ac_cpp_err"; then
37778   ac_header_preproc=yes
37779 else
37780   echo "$as_me: failed program was:" >&5
37781 sed 's/^/| /' conftest.$ac_ext >&5
37782
37783   ac_header_preproc=no
37784 fi
37785 rm -f conftest.err conftest.$ac_ext
37786 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
37787 echo "${ECHO_T}$ac_header_preproc" >&6
37788
37789 # So?  What about this header?
37790 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
37791   yes:no: )
37792     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
37793 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
37794     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
37795 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
37796     ac_header_preproc=yes
37797     ;;
37798   no:yes:* )
37799     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
37800 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
37801     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
37802 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
37803     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
37804 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
37805     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
37806 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
37807     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
37808 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
37809     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
37810 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
37811     (
37812       cat <<\_ASBOX
37813 ## --------------------------------------------- ##
37814 ## Report this to <http://www.openldap.org/its/> ##
37815 ## --------------------------------------------- ##
37816 _ASBOX
37817     ) |
37818       sed "s/^/$as_me: WARNING:     /" >&2
37819     ;;
37820 esac
37821 echo "$as_me:$LINENO: checking for $ac_header" >&5
37822 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37823 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37824   echo $ECHO_N "(cached) $ECHO_C" >&6
37825 else
37826   eval "$as_ac_Header=\$ac_header_preproc"
37827 fi
37828 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37829 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37830
37831 fi
37832 if test `eval echo '${'$as_ac_Header'}'` = yes; then
37833   cat >>confdefs.h <<_ACEOF
37834 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
37835 _ACEOF
37836
37837 fi
37838
37839 done
37840
37841
37842 echo "$as_me:$LINENO: checking for __gmpz_add_ui in -lgmp" >&5
37843 echo $ECHO_N "checking for __gmpz_add_ui in -lgmp... $ECHO_C" >&6
37844 if test "${ac_cv_lib_gmp___gmpz_add_ui+set}" = set; then
37845   echo $ECHO_N "(cached) $ECHO_C" >&6
37846 else
37847   ac_check_lib_save_LIBS=$LIBS
37848 LIBS="-lgmp  $LIBS"
37849 cat >conftest.$ac_ext <<_ACEOF
37850 /* confdefs.h.  */
37851 _ACEOF
37852 cat confdefs.h >>conftest.$ac_ext
37853 cat >>conftest.$ac_ext <<_ACEOF
37854 /* end confdefs.h.  */
37855
37856 /* Override any gcc2 internal prototype to avoid an error.  */
37857 #ifdef __cplusplus
37858 extern "C"
37859 #endif
37860 /* We use char because int might match the return type of a gcc2
37861    builtin and then its argument prototype would still apply.  */
37862 char __gmpz_add_ui ();
37863 int
37864 main ()
37865 {
37866 __gmpz_add_ui ();
37867   ;
37868   return 0;
37869 }
37870 _ACEOF
37871 rm -f conftest.$ac_objext conftest$ac_exeext
37872 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37873   (eval $ac_link) 2>conftest.er1
37874   ac_status=$?
37875   grep -v '^ *+' conftest.er1 >conftest.err
37876   rm -f conftest.er1
37877   cat conftest.err >&5
37878   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37879   (exit $ac_status); } &&
37880          { ac_try='test -z "$ac_c_werror_flag"
37881                          || test ! -s conftest.err'
37882   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37883   (eval $ac_try) 2>&5
37884   ac_status=$?
37885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37886   (exit $ac_status); }; } &&
37887          { ac_try='test -s conftest$ac_exeext'
37888   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37889   (eval $ac_try) 2>&5
37890   ac_status=$?
37891   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37892   (exit $ac_status); }; }; then
37893   ac_cv_lib_gmp___gmpz_add_ui=yes
37894 else
37895   echo "$as_me: failed program was:" >&5
37896 sed 's/^/| /' conftest.$ac_ext >&5
37897
37898 ac_cv_lib_gmp___gmpz_add_ui=no
37899 fi
37900 rm -f conftest.err conftest.$ac_objext \
37901       conftest$ac_exeext conftest.$ac_ext
37902 LIBS=$ac_check_lib_save_LIBS
37903 fi
37904 echo "$as_me:$LINENO: result: $ac_cv_lib_gmp___gmpz_add_ui" >&5
37905 echo "${ECHO_T}$ac_cv_lib_gmp___gmpz_add_ui" >&6
37906 if test $ac_cv_lib_gmp___gmpz_add_ui = yes; then
37907   cat >>confdefs.h <<_ACEOF
37908 #define HAVE_LIBGMP 1
37909 _ACEOF
37910
37911   LIBS="-lgmp $LIBS"
37912
37913 fi
37914
37915         if test $ac_cv_header_gmp_h = yes && test $ac_cv_lib_gmp___gmpz_add_ui = yes ; then
37916
37917 cat >>confdefs.h <<\_ACEOF
37918 #define USE_MP_GMP 1
37919 _ACEOF
37920
37921                 ol_with_mp=gmp
37922         elif test $ol_with_mp = gmp ; then
37923                 { { echo "$as_me:$LINENO: error: gmp not available" >&5
37924 echo "$as_me: error: gmp not available" >&2;}
37925    { (exit 1); exit 1; }; }
37926         fi
37927 fi
37928 if test $ol_with_mp = auto ; then
37929         ol_with_mp=no
37930 fi
37931
37932 echo "$as_me:$LINENO: checking for working memcmp" >&5
37933 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
37934 if test "${ac_cv_func_memcmp_working+set}" = set; then
37935   echo $ECHO_N "(cached) $ECHO_C" >&6
37936 else
37937   if test "$cross_compiling" = yes; then
37938   ac_cv_func_memcmp_working=no
37939 else
37940   cat >conftest.$ac_ext <<_ACEOF
37941 /* confdefs.h.  */
37942 _ACEOF
37943 cat confdefs.h >>conftest.$ac_ext
37944 cat >>conftest.$ac_ext <<_ACEOF
37945 /* end confdefs.h.  */
37946 $ac_includes_default
37947 int
37948 main ()
37949 {
37950
37951   /* Some versions of memcmp are not 8-bit clean.  */
37952   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
37953   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
37954     exit (1);
37955
37956   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
37957      or more and with at least one buffer not starting on a 4-byte boundary.
37958      William Lewis provided this test program.   */
37959   {
37960     char foo[21];
37961     char bar[21];
37962     int i;
37963     for (i = 0; i < 4; i++)
37964       {
37965         char *a = foo + i;
37966         char *b = bar + i;
37967         strcpy (a, "--------01111111");
37968         strcpy (b, "--------10000000");
37969         if (memcmp (a, b, 16) >= 0)
37970           exit (1);
37971       }
37972     exit (0);
37973   }
37974
37975   ;
37976   return 0;
37977 }
37978 _ACEOF
37979 rm -f conftest$ac_exeext
37980 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37981   (eval $ac_link) 2>&5
37982   ac_status=$?
37983   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37984   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
37985   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37986   (eval $ac_try) 2>&5
37987   ac_status=$?
37988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37989   (exit $ac_status); }; }; then
37990   ac_cv_func_memcmp_working=yes
37991 else
37992   echo "$as_me: program exited with status $ac_status" >&5
37993 echo "$as_me: failed program was:" >&5
37994 sed 's/^/| /' conftest.$ac_ext >&5
37995
37996 ( exit $ac_status )
37997 ac_cv_func_memcmp_working=no
37998 fi
37999 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
38000 fi
38001 fi
38002 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
38003 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
38004 test $ac_cv_func_memcmp_working = no && case $LIBOBJS in
38005     "memcmp.$ac_objext"   | \
38006   *" memcmp.$ac_objext"   | \
38007     "memcmp.$ac_objext "* | \
38008   *" memcmp.$ac_objext "* ) ;;
38009   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext" ;;
38010 esac
38011
38012
38013
38014 if test $ac_cv_func_memcmp_working = no ; then
38015
38016 cat >>confdefs.h <<\_ACEOF
38017 #define NEED_MEMCMP_REPLACEMENT 1
38018 _ACEOF
38019
38020 fi
38021
38022
38023 for ac_func in strftime
38024 do
38025 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
38026 echo "$as_me:$LINENO: checking for $ac_func" >&5
38027 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
38028 if eval "test \"\${$as_ac_var+set}\" = set"; then
38029   echo $ECHO_N "(cached) $ECHO_C" >&6
38030 else
38031   cat >conftest.$ac_ext <<_ACEOF
38032 /* confdefs.h.  */
38033 _ACEOF
38034 cat confdefs.h >>conftest.$ac_ext
38035 cat >>conftest.$ac_ext <<_ACEOF
38036 /* end confdefs.h.  */
38037 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
38038    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38039 #define $ac_func innocuous_$ac_func
38040
38041 /* System header to define __stub macros and hopefully few prototypes,
38042     which can conflict with char $ac_func (); below.
38043     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38044     <limits.h> exists even on freestanding compilers.  */
38045
38046 #ifdef __STDC__
38047 # include <limits.h>
38048 #else
38049 # include <assert.h>
38050 #endif
38051
38052 #undef $ac_func
38053
38054 /* Override any gcc2 internal prototype to avoid an error.  */
38055 #ifdef __cplusplus
38056 extern "C"
38057 {
38058 #endif
38059 /* We use char because int might match the return type of a gcc2
38060    builtin and then its argument prototype would still apply.  */
38061 char $ac_func ();
38062 /* The GNU C library defines this for functions which it implements
38063     to always fail with ENOSYS.  Some functions are actually named
38064     something starting with __ and the normal name is an alias.  */
38065 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
38066 choke me
38067 #else
38068 char (*f) () = $ac_func;
38069 #endif
38070 #ifdef __cplusplus
38071 }
38072 #endif
38073
38074 int
38075 main ()
38076 {
38077 return f != $ac_func;
38078   ;
38079   return 0;
38080 }
38081 _ACEOF
38082 rm -f conftest.$ac_objext conftest$ac_exeext
38083 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38084   (eval $ac_link) 2>conftest.er1
38085   ac_status=$?
38086   grep -v '^ *+' conftest.er1 >conftest.err
38087   rm -f conftest.er1
38088   cat conftest.err >&5
38089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38090   (exit $ac_status); } &&
38091          { ac_try='test -z "$ac_c_werror_flag"
38092                          || test ! -s conftest.err'
38093   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38094   (eval $ac_try) 2>&5
38095   ac_status=$?
38096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38097   (exit $ac_status); }; } &&
38098          { ac_try='test -s conftest$ac_exeext'
38099   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38100   (eval $ac_try) 2>&5
38101   ac_status=$?
38102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38103   (exit $ac_status); }; }; then
38104   eval "$as_ac_var=yes"
38105 else
38106   echo "$as_me: failed program was:" >&5
38107 sed 's/^/| /' conftest.$ac_ext >&5
38108
38109 eval "$as_ac_var=no"
38110 fi
38111 rm -f conftest.err conftest.$ac_objext \
38112       conftest$ac_exeext conftest.$ac_ext
38113 fi
38114 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
38115 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
38116 if test `eval echo '${'$as_ac_var'}'` = yes; then
38117   cat >>confdefs.h <<_ACEOF
38118 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
38119 _ACEOF
38120
38121 else
38122   # strftime is in -lintl on SCO UNIX.
38123 echo "$as_me:$LINENO: checking for strftime in -lintl" >&5
38124 echo $ECHO_N "checking for strftime in -lintl... $ECHO_C" >&6
38125 if test "${ac_cv_lib_intl_strftime+set}" = set; then
38126   echo $ECHO_N "(cached) $ECHO_C" >&6
38127 else
38128   ac_check_lib_save_LIBS=$LIBS
38129 LIBS="-lintl  $LIBS"
38130 cat >conftest.$ac_ext <<_ACEOF
38131 /* confdefs.h.  */
38132 _ACEOF
38133 cat confdefs.h >>conftest.$ac_ext
38134 cat >>conftest.$ac_ext <<_ACEOF
38135 /* end confdefs.h.  */
38136
38137 /* Override any gcc2 internal prototype to avoid an error.  */
38138 #ifdef __cplusplus
38139 extern "C"
38140 #endif
38141 /* We use char because int might match the return type of a gcc2
38142    builtin and then its argument prototype would still apply.  */
38143 char strftime ();
38144 int
38145 main ()
38146 {
38147 strftime ();
38148   ;
38149   return 0;
38150 }
38151 _ACEOF
38152 rm -f conftest.$ac_objext conftest$ac_exeext
38153 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38154   (eval $ac_link) 2>conftest.er1
38155   ac_status=$?
38156   grep -v '^ *+' conftest.er1 >conftest.err
38157   rm -f conftest.er1
38158   cat conftest.err >&5
38159   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38160   (exit $ac_status); } &&
38161          { ac_try='test -z "$ac_c_werror_flag"
38162                          || test ! -s conftest.err'
38163   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38164   (eval $ac_try) 2>&5
38165   ac_status=$?
38166   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38167   (exit $ac_status); }; } &&
38168          { ac_try='test -s conftest$ac_exeext'
38169   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38170   (eval $ac_try) 2>&5
38171   ac_status=$?
38172   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38173   (exit $ac_status); }; }; then
38174   ac_cv_lib_intl_strftime=yes
38175 else
38176   echo "$as_me: failed program was:" >&5
38177 sed 's/^/| /' conftest.$ac_ext >&5
38178
38179 ac_cv_lib_intl_strftime=no
38180 fi
38181 rm -f conftest.err conftest.$ac_objext \
38182       conftest$ac_exeext conftest.$ac_ext
38183 LIBS=$ac_check_lib_save_LIBS
38184 fi
38185 echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5
38186 echo "${ECHO_T}$ac_cv_lib_intl_strftime" >&6
38187 if test $ac_cv_lib_intl_strftime = yes; then
38188   cat >>confdefs.h <<\_ACEOF
38189 #define HAVE_STRFTIME 1
38190 _ACEOF
38191
38192 LIBS="-lintl $LIBS"
38193 fi
38194
38195 fi
38196 done
38197
38198
38199 echo "$as_me:$LINENO: checking for inet_aton()" >&5
38200 echo $ECHO_N "checking for inet_aton()... $ECHO_C" >&6
38201 if test "${ol_cv_func_inet_aton+set}" = set; then
38202   echo $ECHO_N "(cached) $ECHO_C" >&6
38203 else
38204   cat >conftest.$ac_ext <<_ACEOF
38205 /* confdefs.h.  */
38206 _ACEOF
38207 cat confdefs.h >>conftest.$ac_ext
38208 cat >>conftest.$ac_ext <<_ACEOF
38209 /* end confdefs.h.  */
38210
38211 #ifdef HAVE_SYS_TYPES_H
38212 #       include <sys/types.h>
38213 #endif
38214 #ifdef HAVE_SYS_SOCKET_H
38215 #       include <sys/socket.h>
38216 #       ifdef HAVE_SYS_SELECT_H
38217 #               include <sys/select.h>
38218 #       endif
38219 #       include <netinet/in.h>
38220 #       ifdef HAVE_ARPA_INET_H
38221 #               include <arpa/inet.h>
38222 #       endif
38223 #endif
38224
38225 int
38226 main ()
38227 {
38228 struct in_addr in;
38229 int rc = inet_aton( "255.255.255.255", &in );
38230   ;
38231   return 0;
38232 }
38233 _ACEOF
38234 rm -f conftest.$ac_objext conftest$ac_exeext
38235 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38236   (eval $ac_link) 2>conftest.er1
38237   ac_status=$?
38238   grep -v '^ *+' conftest.er1 >conftest.err
38239   rm -f conftest.er1
38240   cat conftest.err >&5
38241   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38242   (exit $ac_status); } &&
38243          { ac_try='test -z "$ac_c_werror_flag"
38244                          || test ! -s conftest.err'
38245   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38246   (eval $ac_try) 2>&5
38247   ac_status=$?
38248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38249   (exit $ac_status); }; } &&
38250          { ac_try='test -s conftest$ac_exeext'
38251   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38252   (eval $ac_try) 2>&5
38253   ac_status=$?
38254   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38255   (exit $ac_status); }; }; then
38256   ol_cv_func_inet_aton=yes
38257 else
38258   echo "$as_me: failed program was:" >&5
38259 sed 's/^/| /' conftest.$ac_ext >&5
38260
38261 ol_cv_func_inet_aton=no
38262 fi
38263 rm -f conftest.err conftest.$ac_objext \
38264       conftest$ac_exeext conftest.$ac_ext
38265 fi
38266 echo "$as_me:$LINENO: result: $ol_cv_func_inet_aton" >&5
38267 echo "${ECHO_T}$ol_cv_func_inet_aton" >&6
38268   if test $ol_cv_func_inet_aton != no; then
38269
38270 cat >>confdefs.h <<\_ACEOF
38271 #define HAVE_INET_ATON 1
38272 _ACEOF
38273
38274   fi
38275
38276
38277 echo "$as_me:$LINENO: checking for _spawnlp" >&5
38278 echo $ECHO_N "checking for _spawnlp... $ECHO_C" >&6
38279 if test "${ac_cv_func__spawnlp+set}" = set; then
38280   echo $ECHO_N "(cached) $ECHO_C" >&6
38281 else
38282   cat >conftest.$ac_ext <<_ACEOF
38283 /* confdefs.h.  */
38284 _ACEOF
38285 cat confdefs.h >>conftest.$ac_ext
38286 cat >>conftest.$ac_ext <<_ACEOF
38287 /* end confdefs.h.  */
38288 /* Define _spawnlp to an innocuous variant, in case <limits.h> declares _spawnlp.
38289    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38290 #define _spawnlp innocuous__spawnlp
38291
38292 /* System header to define __stub macros and hopefully few prototypes,
38293     which can conflict with char _spawnlp (); below.
38294     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38295     <limits.h> exists even on freestanding compilers.  */
38296
38297 #ifdef __STDC__
38298 # include <limits.h>
38299 #else
38300 # include <assert.h>
38301 #endif
38302
38303 #undef _spawnlp
38304
38305 /* Override any gcc2 internal prototype to avoid an error.  */
38306 #ifdef __cplusplus
38307 extern "C"
38308 {
38309 #endif
38310 /* We use char because int might match the return type of a gcc2
38311    builtin and then its argument prototype would still apply.  */
38312 char _spawnlp ();
38313 /* The GNU C library defines this for functions which it implements
38314     to always fail with ENOSYS.  Some functions are actually named
38315     something starting with __ and the normal name is an alias.  */
38316 #if defined (__stub__spawnlp) || defined (__stub____spawnlp)
38317 choke me
38318 #else
38319 char (*f) () = _spawnlp;
38320 #endif
38321 #ifdef __cplusplus
38322 }
38323 #endif
38324
38325 int
38326 main ()
38327 {
38328 return f != _spawnlp;
38329   ;
38330   return 0;
38331 }
38332 _ACEOF
38333 rm -f conftest.$ac_objext conftest$ac_exeext
38334 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38335   (eval $ac_link) 2>conftest.er1
38336   ac_status=$?
38337   grep -v '^ *+' conftest.er1 >conftest.err
38338   rm -f conftest.er1
38339   cat conftest.err >&5
38340   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38341   (exit $ac_status); } &&
38342          { ac_try='test -z "$ac_c_werror_flag"
38343                          || test ! -s conftest.err'
38344   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38345   (eval $ac_try) 2>&5
38346   ac_status=$?
38347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38348   (exit $ac_status); }; } &&
38349          { ac_try='test -s conftest$ac_exeext'
38350   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38351   (eval $ac_try) 2>&5
38352   ac_status=$?
38353   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38354   (exit $ac_status); }; }; then
38355   ac_cv_func__spawnlp=yes
38356 else
38357   echo "$as_me: failed program was:" >&5
38358 sed 's/^/| /' conftest.$ac_ext >&5
38359
38360 ac_cv_func__spawnlp=no
38361 fi
38362 rm -f conftest.err conftest.$ac_objext \
38363       conftest$ac_exeext conftest.$ac_ext
38364 fi
38365 echo "$as_me:$LINENO: result: $ac_cv_func__spawnlp" >&5
38366 echo "${ECHO_T}$ac_cv_func__spawnlp" >&6
38367 if test $ac_cv_func__spawnlp = yes; then
38368
38369 cat >>confdefs.h <<\_ACEOF
38370 #define HAVE_SPAWNLP 1
38371 _ACEOF
38372
38373 fi
38374
38375
38376 echo "$as_me:$LINENO: checking for _snprintf" >&5
38377 echo $ECHO_N "checking for _snprintf... $ECHO_C" >&6
38378 if test "${ac_cv_func__snprintf+set}" = set; then
38379   echo $ECHO_N "(cached) $ECHO_C" >&6
38380 else
38381   cat >conftest.$ac_ext <<_ACEOF
38382 /* confdefs.h.  */
38383 _ACEOF
38384 cat confdefs.h >>conftest.$ac_ext
38385 cat >>conftest.$ac_ext <<_ACEOF
38386 /* end confdefs.h.  */
38387 /* Define _snprintf to an innocuous variant, in case <limits.h> declares _snprintf.
38388    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38389 #define _snprintf innocuous__snprintf
38390
38391 /* System header to define __stub macros and hopefully few prototypes,
38392     which can conflict with char _snprintf (); below.
38393     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38394     <limits.h> exists even on freestanding compilers.  */
38395
38396 #ifdef __STDC__
38397 # include <limits.h>
38398 #else
38399 # include <assert.h>
38400 #endif
38401
38402 #undef _snprintf
38403
38404 /* Override any gcc2 internal prototype to avoid an error.  */
38405 #ifdef __cplusplus
38406 extern "C"
38407 {
38408 #endif
38409 /* We use char because int might match the return type of a gcc2
38410    builtin and then its argument prototype would still apply.  */
38411 char _snprintf ();
38412 /* The GNU C library defines this for functions which it implements
38413     to always fail with ENOSYS.  Some functions are actually named
38414     something starting with __ and the normal name is an alias.  */
38415 #if defined (__stub__snprintf) || defined (__stub____snprintf)
38416 choke me
38417 #else
38418 char (*f) () = _snprintf;
38419 #endif
38420 #ifdef __cplusplus
38421 }
38422 #endif
38423
38424 int
38425 main ()
38426 {
38427 return f != _snprintf;
38428   ;
38429   return 0;
38430 }
38431 _ACEOF
38432 rm -f conftest.$ac_objext conftest$ac_exeext
38433 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38434   (eval $ac_link) 2>conftest.er1
38435   ac_status=$?
38436   grep -v '^ *+' conftest.er1 >conftest.err
38437   rm -f conftest.er1
38438   cat conftest.err >&5
38439   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38440   (exit $ac_status); } &&
38441          { ac_try='test -z "$ac_c_werror_flag"
38442                          || test ! -s conftest.err'
38443   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38444   (eval $ac_try) 2>&5
38445   ac_status=$?
38446   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38447   (exit $ac_status); }; } &&
38448          { ac_try='test -s conftest$ac_exeext'
38449   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38450   (eval $ac_try) 2>&5
38451   ac_status=$?
38452   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38453   (exit $ac_status); }; }; then
38454   ac_cv_func__snprintf=yes
38455 else
38456   echo "$as_me: failed program was:" >&5
38457 sed 's/^/| /' conftest.$ac_ext >&5
38458
38459 ac_cv_func__snprintf=no
38460 fi
38461 rm -f conftest.err conftest.$ac_objext \
38462       conftest$ac_exeext conftest.$ac_ext
38463 fi
38464 echo "$as_me:$LINENO: result: $ac_cv_func__snprintf" >&5
38465 echo "${ECHO_T}$ac_cv_func__snprintf" >&6
38466 if test $ac_cv_func__snprintf = yes; then
38467   ac_cv_func_snprintf=yes
38468
38469 cat >>confdefs.h <<\_ACEOF
38470 #define snprintf _snprintf
38471 _ACEOF
38472
38473
38474 fi
38475
38476
38477 echo "$as_me:$LINENO: checking for _vsnprintf" >&5
38478 echo $ECHO_N "checking for _vsnprintf... $ECHO_C" >&6
38479 if test "${ac_cv_func__vsnprintf+set}" = set; then
38480   echo $ECHO_N "(cached) $ECHO_C" >&6
38481 else
38482   cat >conftest.$ac_ext <<_ACEOF
38483 /* confdefs.h.  */
38484 _ACEOF
38485 cat confdefs.h >>conftest.$ac_ext
38486 cat >>conftest.$ac_ext <<_ACEOF
38487 /* end confdefs.h.  */
38488 /* Define _vsnprintf to an innocuous variant, in case <limits.h> declares _vsnprintf.
38489    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38490 #define _vsnprintf innocuous__vsnprintf
38491
38492 /* System header to define __stub macros and hopefully few prototypes,
38493     which can conflict with char _vsnprintf (); below.
38494     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38495     <limits.h> exists even on freestanding compilers.  */
38496
38497 #ifdef __STDC__
38498 # include <limits.h>
38499 #else
38500 # include <assert.h>
38501 #endif
38502
38503 #undef _vsnprintf
38504
38505 /* Override any gcc2 internal prototype to avoid an error.  */
38506 #ifdef __cplusplus
38507 extern "C"
38508 {
38509 #endif
38510 /* We use char because int might match the return type of a gcc2
38511    builtin and then its argument prototype would still apply.  */
38512 char _vsnprintf ();
38513 /* The GNU C library defines this for functions which it implements
38514     to always fail with ENOSYS.  Some functions are actually named
38515     something starting with __ and the normal name is an alias.  */
38516 #if defined (__stub__vsnprintf) || defined (__stub____vsnprintf)
38517 choke me
38518 #else
38519 char (*f) () = _vsnprintf;
38520 #endif
38521 #ifdef __cplusplus
38522 }
38523 #endif
38524
38525 int
38526 main ()
38527 {
38528 return f != _vsnprintf;
38529   ;
38530   return 0;
38531 }
38532 _ACEOF
38533 rm -f conftest.$ac_objext conftest$ac_exeext
38534 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38535   (eval $ac_link) 2>conftest.er1
38536   ac_status=$?
38537   grep -v '^ *+' conftest.er1 >conftest.err
38538   rm -f conftest.er1
38539   cat conftest.err >&5
38540   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38541   (exit $ac_status); } &&
38542          { ac_try='test -z "$ac_c_werror_flag"
38543                          || test ! -s conftest.err'
38544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38545   (eval $ac_try) 2>&5
38546   ac_status=$?
38547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38548   (exit $ac_status); }; } &&
38549          { ac_try='test -s conftest$ac_exeext'
38550   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38551   (eval $ac_try) 2>&5
38552   ac_status=$?
38553   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38554   (exit $ac_status); }; }; then
38555   ac_cv_func__vsnprintf=yes
38556 else
38557   echo "$as_me: failed program was:" >&5
38558 sed 's/^/| /' conftest.$ac_ext >&5
38559
38560 ac_cv_func__vsnprintf=no
38561 fi
38562 rm -f conftest.err conftest.$ac_objext \
38563       conftest$ac_exeext conftest.$ac_ext
38564 fi
38565 echo "$as_me:$LINENO: result: $ac_cv_func__vsnprintf" >&5
38566 echo "${ECHO_T}$ac_cv_func__vsnprintf" >&6
38567 if test $ac_cv_func__vsnprintf = yes; then
38568   ac_cv_func_vsnprintf=yes
38569
38570 cat >>confdefs.h <<\_ACEOF
38571 #define vsnprintf _vsnprintf
38572 _ACEOF
38573
38574
38575 fi
38576
38577
38578
38579 for ac_func in vprintf
38580 do
38581 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
38582 echo "$as_me:$LINENO: checking for $ac_func" >&5
38583 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
38584 if eval "test \"\${$as_ac_var+set}\" = set"; then
38585   echo $ECHO_N "(cached) $ECHO_C" >&6
38586 else
38587   cat >conftest.$ac_ext <<_ACEOF
38588 /* confdefs.h.  */
38589 _ACEOF
38590 cat confdefs.h >>conftest.$ac_ext
38591 cat >>conftest.$ac_ext <<_ACEOF
38592 /* end confdefs.h.  */
38593 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
38594    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38595 #define $ac_func innocuous_$ac_func
38596
38597 /* System header to define __stub macros and hopefully few prototypes,
38598     which can conflict with char $ac_func (); below.
38599     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38600     <limits.h> exists even on freestanding compilers.  */
38601
38602 #ifdef __STDC__
38603 # include <limits.h>
38604 #else
38605 # include <assert.h>
38606 #endif
38607
38608 #undef $ac_func
38609
38610 /* Override any gcc2 internal prototype to avoid an error.  */
38611 #ifdef __cplusplus
38612 extern "C"
38613 {
38614 #endif
38615 /* We use char because int might match the return type of a gcc2
38616    builtin and then its argument prototype would still apply.  */
38617 char $ac_func ();
38618 /* The GNU C library defines this for functions which it implements
38619     to always fail with ENOSYS.  Some functions are actually named
38620     something starting with __ and the normal name is an alias.  */
38621 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
38622 choke me
38623 #else
38624 char (*f) () = $ac_func;
38625 #endif
38626 #ifdef __cplusplus
38627 }
38628 #endif
38629
38630 int
38631 main ()
38632 {
38633 return f != $ac_func;
38634   ;
38635   return 0;
38636 }
38637 _ACEOF
38638 rm -f conftest.$ac_objext conftest$ac_exeext
38639 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38640   (eval $ac_link) 2>conftest.er1
38641   ac_status=$?
38642   grep -v '^ *+' conftest.er1 >conftest.err
38643   rm -f conftest.er1
38644   cat conftest.err >&5
38645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38646   (exit $ac_status); } &&
38647          { ac_try='test -z "$ac_c_werror_flag"
38648                          || test ! -s conftest.err'
38649   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38650   (eval $ac_try) 2>&5
38651   ac_status=$?
38652   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38653   (exit $ac_status); }; } &&
38654          { ac_try='test -s conftest$ac_exeext'
38655   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38656   (eval $ac_try) 2>&5
38657   ac_status=$?
38658   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38659   (exit $ac_status); }; }; then
38660   eval "$as_ac_var=yes"
38661 else
38662   echo "$as_me: failed program was:" >&5
38663 sed 's/^/| /' conftest.$ac_ext >&5
38664
38665 eval "$as_ac_var=no"
38666 fi
38667 rm -f conftest.err conftest.$ac_objext \
38668       conftest$ac_exeext conftest.$ac_ext
38669 fi
38670 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
38671 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
38672 if test `eval echo '${'$as_ac_var'}'` = yes; then
38673   cat >>confdefs.h <<_ACEOF
38674 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
38675 _ACEOF
38676
38677 echo "$as_me:$LINENO: checking for _doprnt" >&5
38678 echo $ECHO_N "checking for _doprnt... $ECHO_C" >&6
38679 if test "${ac_cv_func__doprnt+set}" = set; then
38680   echo $ECHO_N "(cached) $ECHO_C" >&6
38681 else
38682   cat >conftest.$ac_ext <<_ACEOF
38683 /* confdefs.h.  */
38684 _ACEOF
38685 cat confdefs.h >>conftest.$ac_ext
38686 cat >>conftest.$ac_ext <<_ACEOF
38687 /* end confdefs.h.  */
38688 /* Define _doprnt to an innocuous variant, in case <limits.h> declares _doprnt.
38689    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38690 #define _doprnt innocuous__doprnt
38691
38692 /* System header to define __stub macros and hopefully few prototypes,
38693     which can conflict with char _doprnt (); below.
38694     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38695     <limits.h> exists even on freestanding compilers.  */
38696
38697 #ifdef __STDC__
38698 # include <limits.h>
38699 #else
38700 # include <assert.h>
38701 #endif
38702
38703 #undef _doprnt
38704
38705 /* Override any gcc2 internal prototype to avoid an error.  */
38706 #ifdef __cplusplus
38707 extern "C"
38708 {
38709 #endif
38710 /* We use char because int might match the return type of a gcc2
38711    builtin and then its argument prototype would still apply.  */
38712 char _doprnt ();
38713 /* The GNU C library defines this for functions which it implements
38714     to always fail with ENOSYS.  Some functions are actually named
38715     something starting with __ and the normal name is an alias.  */
38716 #if defined (__stub__doprnt) || defined (__stub____doprnt)
38717 choke me
38718 #else
38719 char (*f) () = _doprnt;
38720 #endif
38721 #ifdef __cplusplus
38722 }
38723 #endif
38724
38725 int
38726 main ()
38727 {
38728 return f != _doprnt;
38729   ;
38730   return 0;
38731 }
38732 _ACEOF
38733 rm -f conftest.$ac_objext conftest$ac_exeext
38734 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38735   (eval $ac_link) 2>conftest.er1
38736   ac_status=$?
38737   grep -v '^ *+' conftest.er1 >conftest.err
38738   rm -f conftest.er1
38739   cat conftest.err >&5
38740   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38741   (exit $ac_status); } &&
38742          { ac_try='test -z "$ac_c_werror_flag"
38743                          || test ! -s conftest.err'
38744   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38745   (eval $ac_try) 2>&5
38746   ac_status=$?
38747   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38748   (exit $ac_status); }; } &&
38749          { ac_try='test -s conftest$ac_exeext'
38750   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38751   (eval $ac_try) 2>&5
38752   ac_status=$?
38753   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38754   (exit $ac_status); }; }; then
38755   ac_cv_func__doprnt=yes
38756 else
38757   echo "$as_me: failed program was:" >&5
38758 sed 's/^/| /' conftest.$ac_ext >&5
38759
38760 ac_cv_func__doprnt=no
38761 fi
38762 rm -f conftest.err conftest.$ac_objext \
38763       conftest$ac_exeext conftest.$ac_ext
38764 fi
38765 echo "$as_me:$LINENO: result: $ac_cv_func__doprnt" >&5
38766 echo "${ECHO_T}$ac_cv_func__doprnt" >&6
38767 if test $ac_cv_func__doprnt = yes; then
38768
38769 cat >>confdefs.h <<\_ACEOF
38770 #define HAVE_DOPRNT 1
38771 _ACEOF
38772
38773 fi
38774
38775 fi
38776 done
38777
38778
38779
38780 if test $ac_cv_func_vprintf = yes ; then
38781
38782
38783 for ac_func in snprintf vsnprintf
38784 do
38785 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
38786 echo "$as_me:$LINENO: checking for $ac_func" >&5
38787 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
38788 if eval "test \"\${$as_ac_var+set}\" = set"; then
38789   echo $ECHO_N "(cached) $ECHO_C" >&6
38790 else
38791   cat >conftest.$ac_ext <<_ACEOF
38792 /* confdefs.h.  */
38793 _ACEOF
38794 cat confdefs.h >>conftest.$ac_ext
38795 cat >>conftest.$ac_ext <<_ACEOF
38796 /* end confdefs.h.  */
38797 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
38798    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38799 #define $ac_func innocuous_$ac_func
38800
38801 /* System header to define __stub macros and hopefully few prototypes,
38802     which can conflict with char $ac_func (); below.
38803     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38804     <limits.h> exists even on freestanding compilers.  */
38805
38806 #ifdef __STDC__
38807 # include <limits.h>
38808 #else
38809 # include <assert.h>
38810 #endif
38811
38812 #undef $ac_func
38813
38814 /* Override any gcc2 internal prototype to avoid an error.  */
38815 #ifdef __cplusplus
38816 extern "C"
38817 {
38818 #endif
38819 /* We use char because int might match the return type of a gcc2
38820    builtin and then its argument prototype would still apply.  */
38821 char $ac_func ();
38822 /* The GNU C library defines this for functions which it implements
38823     to always fail with ENOSYS.  Some functions are actually named
38824     something starting with __ and the normal name is an alias.  */
38825 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
38826 choke me
38827 #else
38828 char (*f) () = $ac_func;
38829 #endif
38830 #ifdef __cplusplus
38831 }
38832 #endif
38833
38834 int
38835 main ()
38836 {
38837 return f != $ac_func;
38838   ;
38839   return 0;
38840 }
38841 _ACEOF
38842 rm -f conftest.$ac_objext conftest$ac_exeext
38843 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38844   (eval $ac_link) 2>conftest.er1
38845   ac_status=$?
38846   grep -v '^ *+' conftest.er1 >conftest.err
38847   rm -f conftest.er1
38848   cat conftest.err >&5
38849   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38850   (exit $ac_status); } &&
38851          { ac_try='test -z "$ac_c_werror_flag"
38852                          || test ! -s conftest.err'
38853   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38854   (eval $ac_try) 2>&5
38855   ac_status=$?
38856   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38857   (exit $ac_status); }; } &&
38858          { ac_try='test -s conftest$ac_exeext'
38859   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38860   (eval $ac_try) 2>&5
38861   ac_status=$?
38862   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38863   (exit $ac_status); }; }; then
38864   eval "$as_ac_var=yes"
38865 else
38866   echo "$as_me: failed program was:" >&5
38867 sed 's/^/| /' conftest.$ac_ext >&5
38868
38869 eval "$as_ac_var=no"
38870 fi
38871 rm -f conftest.err conftest.$ac_objext \
38872       conftest$ac_exeext conftest.$ac_ext
38873 fi
38874 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
38875 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
38876 if test `eval echo '${'$as_ac_var'}'` = yes; then
38877   cat >>confdefs.h <<_ACEOF
38878 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
38879 _ACEOF
38880
38881 fi
38882 done
38883
38884 fi
38885
38886
38887
38888
38889
38890
38891
38892
38893
38894
38895
38896
38897
38898
38899
38900
38901
38902
38903
38904
38905
38906
38907
38908
38909
38910
38911
38912
38913
38914
38915
38916
38917
38918
38919
38920
38921
38922
38923
38924
38925
38926
38927
38928
38929
38930
38931
38932
38933
38934
38935
38936
38937
38938
38939
38940 for ac_func in \
38941         bcopy                   \
38942         closesocket             \
38943         chroot                  \
38944         endgrent                \
38945         endpwent                \
38946         fcntl                   \
38947         flock                   \
38948         fstat                   \
38949         getdtablesize   \
38950         getgrgid                \
38951         gethostname             \
38952         getpass                 \
38953         getpassphrase   \
38954         getpwuid                \
38955         getpwnam                \
38956         getspnam                \
38957         gettimeofday    \
38958         initgroups              \
38959         inet_ntoa_b             \
38960         lockf                   \
38961         memcpy                  \
38962         memmove                 \
38963         memrchr                 \
38964         mkstemp                 \
38965         mktemp                  \
38966         pipe                    \
38967         read                    \
38968         recv                    \
38969         recvfrom                \
38970         setpwfile               \
38971         setgid                  \
38972         setegid                 \
38973         setsid                  \
38974         setuid                  \
38975         seteuid                 \
38976         signal                  \
38977         strdup                  \
38978         strpbrk                 \
38979         strrchr                 \
38980         strsep                  \
38981         strstr                  \
38982         strtol                  \
38983         strtoul                 \
38984         strtoq                  \
38985         strtouq                 \
38986         strtoll                 \
38987         strspn                  \
38988         sysconf                 \
38989         waitpid                 \
38990         wait4                   \
38991         write                   \
38992         send                    \
38993         sendmsg                 \
38994         sendto                  \
38995
38996 do
38997 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
38998 echo "$as_me:$LINENO: checking for $ac_func" >&5
38999 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
39000 if eval "test \"\${$as_ac_var+set}\" = set"; then
39001   echo $ECHO_N "(cached) $ECHO_C" >&6
39002 else
39003   cat >conftest.$ac_ext <<_ACEOF
39004 /* confdefs.h.  */
39005 _ACEOF
39006 cat confdefs.h >>conftest.$ac_ext
39007 cat >>conftest.$ac_ext <<_ACEOF
39008 /* end confdefs.h.  */
39009 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
39010    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
39011 #define $ac_func innocuous_$ac_func
39012
39013 /* System header to define __stub macros and hopefully few prototypes,
39014     which can conflict with char $ac_func (); below.
39015     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
39016     <limits.h> exists even on freestanding compilers.  */
39017
39018 #ifdef __STDC__
39019 # include <limits.h>
39020 #else
39021 # include <assert.h>
39022 #endif
39023
39024 #undef $ac_func
39025
39026 /* Override any gcc2 internal prototype to avoid an error.  */
39027 #ifdef __cplusplus
39028 extern "C"
39029 {
39030 #endif
39031 /* We use char because int might match the return type of a gcc2
39032    builtin and then its argument prototype would still apply.  */
39033 char $ac_func ();
39034 /* The GNU C library defines this for functions which it implements
39035     to always fail with ENOSYS.  Some functions are actually named
39036     something starting with __ and the normal name is an alias.  */
39037 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
39038 choke me
39039 #else
39040 char (*f) () = $ac_func;
39041 #endif
39042 #ifdef __cplusplus
39043 }
39044 #endif
39045
39046 int
39047 main ()
39048 {
39049 return f != $ac_func;
39050   ;
39051   return 0;
39052 }
39053 _ACEOF
39054 rm -f conftest.$ac_objext conftest$ac_exeext
39055 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
39056   (eval $ac_link) 2>conftest.er1
39057   ac_status=$?
39058   grep -v '^ *+' conftest.er1 >conftest.err
39059   rm -f conftest.er1
39060   cat conftest.err >&5
39061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39062   (exit $ac_status); } &&
39063          { ac_try='test -z "$ac_c_werror_flag"
39064                          || test ! -s conftest.err'
39065   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39066   (eval $ac_try) 2>&5
39067   ac_status=$?
39068   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39069   (exit $ac_status); }; } &&
39070          { ac_try='test -s conftest$ac_exeext'
39071   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39072   (eval $ac_try) 2>&5
39073   ac_status=$?
39074   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39075   (exit $ac_status); }; }; then
39076   eval "$as_ac_var=yes"
39077 else
39078   echo "$as_me: failed program was:" >&5
39079 sed 's/^/| /' conftest.$ac_ext >&5
39080
39081 eval "$as_ac_var=no"
39082 fi
39083 rm -f conftest.err conftest.$ac_objext \
39084       conftest$ac_exeext conftest.$ac_ext
39085 fi
39086 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
39087 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
39088 if test `eval echo '${'$as_ac_var'}'` = yes; then
39089   cat >>confdefs.h <<_ACEOF
39090 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
39091 _ACEOF
39092
39093 fi
39094 done
39095
39096
39097
39098
39099 for ac_func in getopt getpeereid
39100 do
39101 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
39102 echo "$as_me:$LINENO: checking for $ac_func" >&5
39103 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
39104 if eval "test \"\${$as_ac_var+set}\" = set"; then
39105   echo $ECHO_N "(cached) $ECHO_C" >&6
39106 else
39107   cat >conftest.$ac_ext <<_ACEOF
39108 /* confdefs.h.  */
39109 _ACEOF
39110 cat confdefs.h >>conftest.$ac_ext
39111 cat >>conftest.$ac_ext <<_ACEOF
39112 /* end confdefs.h.  */
39113 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
39114    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
39115 #define $ac_func innocuous_$ac_func
39116
39117 /* System header to define __stub macros and hopefully few prototypes,
39118     which can conflict with char $ac_func (); below.
39119     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
39120     <limits.h> exists even on freestanding compilers.  */
39121
39122 #ifdef __STDC__
39123 # include <limits.h>
39124 #else
39125 # include <assert.h>
39126 #endif
39127
39128 #undef $ac_func
39129
39130 /* Override any gcc2 internal prototype to avoid an error.  */
39131 #ifdef __cplusplus
39132 extern "C"
39133 {
39134 #endif
39135 /* We use char because int might match the return type of a gcc2
39136    builtin and then its argument prototype would still apply.  */
39137 char $ac_func ();
39138 /* The GNU C library defines this for functions which it implements
39139     to always fail with ENOSYS.  Some functions are actually named
39140     something starting with __ and the normal name is an alias.  */
39141 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
39142 choke me
39143 #else
39144 char (*f) () = $ac_func;
39145 #endif
39146 #ifdef __cplusplus
39147 }
39148 #endif
39149
39150 int
39151 main ()
39152 {
39153 return f != $ac_func;
39154   ;
39155   return 0;
39156 }
39157 _ACEOF
39158 rm -f conftest.$ac_objext conftest$ac_exeext
39159 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
39160   (eval $ac_link) 2>conftest.er1
39161   ac_status=$?
39162   grep -v '^ *+' conftest.er1 >conftest.err
39163   rm -f conftest.er1
39164   cat conftest.err >&5
39165   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39166   (exit $ac_status); } &&
39167          { ac_try='test -z "$ac_c_werror_flag"
39168                          || test ! -s conftest.err'
39169   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39170   (eval $ac_try) 2>&5
39171   ac_status=$?
39172   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39173   (exit $ac_status); }; } &&
39174          { ac_try='test -s conftest$ac_exeext'
39175   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39176   (eval $ac_try) 2>&5
39177   ac_status=$?
39178   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39179   (exit $ac_status); }; }; then
39180   eval "$as_ac_var=yes"
39181 else
39182   echo "$as_me: failed program was:" >&5
39183 sed 's/^/| /' conftest.$ac_ext >&5
39184
39185 eval "$as_ac_var=no"
39186 fi
39187 rm -f conftest.err conftest.$ac_objext \
39188       conftest$ac_exeext conftest.$ac_ext
39189 fi
39190 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
39191 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
39192 if test `eval echo '${'$as_ac_var'}'` = yes; then
39193   cat >>confdefs.h <<_ACEOF
39194 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
39195 _ACEOF
39196
39197 else
39198   case $LIBOBJS in
39199     "$ac_func.$ac_objext"   | \
39200   *" $ac_func.$ac_objext"   | \
39201     "$ac_func.$ac_objext "* | \
39202   *" $ac_func.$ac_objext "* ) ;;
39203   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
39204 esac
39205
39206 fi
39207 done
39208
39209
39210
39211 if test "$ac_cv_func_getopt" != yes; then
39212         LIBSRCS="$LIBSRCS getopt.c"
39213 fi
39214
39215 if test "$ac_cv_func_getpeereid" != yes; then
39216
39217 for ac_func in getpeerucred
39218 do
39219 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
39220 echo "$as_me:$LINENO: checking for $ac_func" >&5
39221 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
39222 if eval "test \"\${$as_ac_var+set}\" = set"; then
39223   echo $ECHO_N "(cached) $ECHO_C" >&6
39224 else
39225   cat >conftest.$ac_ext <<_ACEOF
39226 /* confdefs.h.  */
39227 _ACEOF
39228 cat confdefs.h >>conftest.$ac_ext
39229 cat >>conftest.$ac_ext <<_ACEOF
39230 /* end confdefs.h.  */
39231 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
39232    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
39233 #define $ac_func innocuous_$ac_func
39234
39235 /* System header to define __stub macros and hopefully few prototypes,
39236     which can conflict with char $ac_func (); below.
39237     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
39238     <limits.h> exists even on freestanding compilers.  */
39239
39240 #ifdef __STDC__
39241 # include <limits.h>
39242 #else
39243 # include <assert.h>
39244 #endif
39245
39246 #undef $ac_func
39247
39248 /* Override any gcc2 internal prototype to avoid an error.  */
39249 #ifdef __cplusplus
39250 extern "C"
39251 {
39252 #endif
39253 /* We use char because int might match the return type of a gcc2
39254    builtin and then its argument prototype would still apply.  */
39255 char $ac_func ();
39256 /* The GNU C library defines this for functions which it implements
39257     to always fail with ENOSYS.  Some functions are actually named
39258     something starting with __ and the normal name is an alias.  */
39259 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
39260 choke me
39261 #else
39262 char (*f) () = $ac_func;
39263 #endif
39264 #ifdef __cplusplus
39265 }
39266 #endif
39267
39268 int
39269 main ()
39270 {
39271 return f != $ac_func;
39272   ;
39273   return 0;
39274 }
39275 _ACEOF
39276 rm -f conftest.$ac_objext conftest$ac_exeext
39277 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
39278   (eval $ac_link) 2>conftest.er1
39279   ac_status=$?
39280   grep -v '^ *+' conftest.er1 >conftest.err
39281   rm -f conftest.er1
39282   cat conftest.err >&5
39283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39284   (exit $ac_status); } &&
39285          { ac_try='test -z "$ac_c_werror_flag"
39286                          || test ! -s conftest.err'
39287   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39288   (eval $ac_try) 2>&5
39289   ac_status=$?
39290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39291   (exit $ac_status); }; } &&
39292          { ac_try='test -s conftest$ac_exeext'
39293   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39294   (eval $ac_try) 2>&5
39295   ac_status=$?
39296   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39297   (exit $ac_status); }; }; then
39298   eval "$as_ac_var=yes"
39299 else
39300   echo "$as_me: failed program was:" >&5
39301 sed 's/^/| /' conftest.$ac_ext >&5
39302
39303 eval "$as_ac_var=no"
39304 fi
39305 rm -f conftest.err conftest.$ac_objext \
39306       conftest$ac_exeext conftest.$ac_ext
39307 fi
39308 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
39309 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
39310 if test `eval echo '${'$as_ac_var'}'` = yes; then
39311   cat >>confdefs.h <<_ACEOF
39312 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
39313 _ACEOF
39314
39315 fi
39316 done
39317
39318         if test "$ac_cv_func_getpeerucred" != yes ; then
39319                 echo "$as_me:$LINENO: checking for struct msghdr.msg_accrightslen" >&5
39320 echo $ECHO_N "checking for struct msghdr.msg_accrightslen... $ECHO_C" >&6
39321 if test "${ac_cv_member_struct_msghdr_msg_accrightslen+set}" = set; then
39322   echo $ECHO_N "(cached) $ECHO_C" >&6
39323 else
39324   cat >conftest.$ac_ext <<_ACEOF
39325 /* confdefs.h.  */
39326 _ACEOF
39327 cat confdefs.h >>conftest.$ac_ext
39328 cat >>conftest.$ac_ext <<_ACEOF
39329 /* end confdefs.h.  */
39330 $ac_includes_default
39331 #ifdef HAVE_SYS_SOCKET_H
39332 #include <sys/socket.h>
39333 #endif
39334
39335 int
39336 main ()
39337 {
39338 static struct msghdr ac_aggr;
39339 if (ac_aggr.msg_accrightslen)
39340 return 0;
39341   ;
39342   return 0;
39343 }
39344 _ACEOF
39345 rm -f conftest.$ac_objext
39346 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39347   (eval $ac_compile) 2>conftest.er1
39348   ac_status=$?
39349   grep -v '^ *+' conftest.er1 >conftest.err
39350   rm -f conftest.er1
39351   cat conftest.err >&5
39352   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39353   (exit $ac_status); } &&
39354          { ac_try='test -z "$ac_c_werror_flag"
39355                          || test ! -s conftest.err'
39356   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39357   (eval $ac_try) 2>&5
39358   ac_status=$?
39359   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39360   (exit $ac_status); }; } &&
39361          { ac_try='test -s conftest.$ac_objext'
39362   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39363   (eval $ac_try) 2>&5
39364   ac_status=$?
39365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39366   (exit $ac_status); }; }; then
39367   ac_cv_member_struct_msghdr_msg_accrightslen=yes
39368 else
39369   echo "$as_me: failed program was:" >&5
39370 sed 's/^/| /' conftest.$ac_ext >&5
39371
39372 cat >conftest.$ac_ext <<_ACEOF
39373 /* confdefs.h.  */
39374 _ACEOF
39375 cat confdefs.h >>conftest.$ac_ext
39376 cat >>conftest.$ac_ext <<_ACEOF
39377 /* end confdefs.h.  */
39378 $ac_includes_default
39379 #ifdef HAVE_SYS_SOCKET_H
39380 #include <sys/socket.h>
39381 #endif
39382
39383 int
39384 main ()
39385 {
39386 static struct msghdr ac_aggr;
39387 if (sizeof ac_aggr.msg_accrightslen)
39388 return 0;
39389   ;
39390   return 0;
39391 }
39392 _ACEOF
39393 rm -f conftest.$ac_objext
39394 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39395   (eval $ac_compile) 2>conftest.er1
39396   ac_status=$?
39397   grep -v '^ *+' conftest.er1 >conftest.err
39398   rm -f conftest.er1
39399   cat conftest.err >&5
39400   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39401   (exit $ac_status); } &&
39402          { ac_try='test -z "$ac_c_werror_flag"
39403                          || test ! -s conftest.err'
39404   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39405   (eval $ac_try) 2>&5
39406   ac_status=$?
39407   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39408   (exit $ac_status); }; } &&
39409          { ac_try='test -s conftest.$ac_objext'
39410   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39411   (eval $ac_try) 2>&5
39412   ac_status=$?
39413   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39414   (exit $ac_status); }; }; then
39415   ac_cv_member_struct_msghdr_msg_accrightslen=yes
39416 else
39417   echo "$as_me: failed program was:" >&5
39418 sed 's/^/| /' conftest.$ac_ext >&5
39419
39420 ac_cv_member_struct_msghdr_msg_accrightslen=no
39421 fi
39422 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39423 fi
39424 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39425 fi
39426 echo "$as_me:$LINENO: result: $ac_cv_member_struct_msghdr_msg_accrightslen" >&5
39427 echo "${ECHO_T}$ac_cv_member_struct_msghdr_msg_accrightslen" >&6
39428 if test $ac_cv_member_struct_msghdr_msg_accrightslen = yes; then
39429
39430 cat >>confdefs.h <<_ACEOF
39431 #define HAVE_STRUCT_MSGHDR_MSG_ACCRIGHTSLEN 1
39432 _ACEOF
39433
39434
39435 fi
39436
39437                 if test "$ac_cv_member_struct_msghdr_msg_accrightslen" != yes; then
39438                         echo "$as_me:$LINENO: checking for struct msghdr.msg_control" >&5
39439 echo $ECHO_N "checking for struct msghdr.msg_control... $ECHO_C" >&6
39440 if test "${ac_cv_member_struct_msghdr_msg_control+set}" = set; then
39441   echo $ECHO_N "(cached) $ECHO_C" >&6
39442 else
39443   cat >conftest.$ac_ext <<_ACEOF
39444 /* confdefs.h.  */
39445 _ACEOF
39446 cat confdefs.h >>conftest.$ac_ext
39447 cat >>conftest.$ac_ext <<_ACEOF
39448 /* end confdefs.h.  */
39449 $ac_includes_default
39450 #ifdef HAVE_SYS_SOCKET_H
39451 #include <sys/socket.h>
39452 #endif
39453
39454 int
39455 main ()
39456 {
39457 static struct msghdr ac_aggr;
39458 if (ac_aggr.msg_control)
39459 return 0;
39460   ;
39461   return 0;
39462 }
39463 _ACEOF
39464 rm -f conftest.$ac_objext
39465 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39466   (eval $ac_compile) 2>conftest.er1
39467   ac_status=$?
39468   grep -v '^ *+' conftest.er1 >conftest.err
39469   rm -f conftest.er1
39470   cat conftest.err >&5
39471   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39472   (exit $ac_status); } &&
39473          { ac_try='test -z "$ac_c_werror_flag"
39474                          || test ! -s conftest.err'
39475   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39476   (eval $ac_try) 2>&5
39477   ac_status=$?
39478   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39479   (exit $ac_status); }; } &&
39480          { ac_try='test -s conftest.$ac_objext'
39481   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39482   (eval $ac_try) 2>&5
39483   ac_status=$?
39484   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39485   (exit $ac_status); }; }; then
39486   ac_cv_member_struct_msghdr_msg_control=yes
39487 else
39488   echo "$as_me: failed program was:" >&5
39489 sed 's/^/| /' conftest.$ac_ext >&5
39490
39491 cat >conftest.$ac_ext <<_ACEOF
39492 /* confdefs.h.  */
39493 _ACEOF
39494 cat confdefs.h >>conftest.$ac_ext
39495 cat >>conftest.$ac_ext <<_ACEOF
39496 /* end confdefs.h.  */
39497 $ac_includes_default
39498 #ifdef HAVE_SYS_SOCKET_H
39499 #include <sys/socket.h>
39500 #endif
39501
39502 int
39503 main ()
39504 {
39505 static struct msghdr ac_aggr;
39506 if (sizeof ac_aggr.msg_control)
39507 return 0;
39508   ;
39509   return 0;
39510 }
39511 _ACEOF
39512 rm -f conftest.$ac_objext
39513 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39514   (eval $ac_compile) 2>conftest.er1
39515   ac_status=$?
39516   grep -v '^ *+' conftest.er1 >conftest.err
39517   rm -f conftest.er1
39518   cat conftest.err >&5
39519   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39520   (exit $ac_status); } &&
39521          { ac_try='test -z "$ac_c_werror_flag"
39522                          || test ! -s conftest.err'
39523   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39524   (eval $ac_try) 2>&5
39525   ac_status=$?
39526   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39527   (exit $ac_status); }; } &&
39528          { ac_try='test -s conftest.$ac_objext'
39529   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39530   (eval $ac_try) 2>&5
39531   ac_status=$?
39532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39533   (exit $ac_status); }; }; then
39534   ac_cv_member_struct_msghdr_msg_control=yes
39535 else
39536   echo "$as_me: failed program was:" >&5
39537 sed 's/^/| /' conftest.$ac_ext >&5
39538
39539 ac_cv_member_struct_msghdr_msg_control=no
39540 fi
39541 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39542 fi
39543 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39544 fi
39545 echo "$as_me:$LINENO: result: $ac_cv_member_struct_msghdr_msg_control" >&5
39546 echo "${ECHO_T}$ac_cv_member_struct_msghdr_msg_control" >&6
39547 if test $ac_cv_member_struct_msghdr_msg_control = yes; then
39548
39549 cat >>confdefs.h <<_ACEOF
39550 #define HAVE_STRUCT_MSGHDR_MSG_CONTROL 1
39551 _ACEOF
39552
39553
39554 fi
39555
39556                 fi
39557         fi
39558         LIBSRCS="$LIBSRCS getpeereid.c"
39559 fi
39560
39561 if test "$ac_cv_func_snprintf" != yes ||
39562    test "$ac_cv_func_vsnprintf" != yes; then
39563         if test "$ac_cv_func_snprintf" != yes; then
39564
39565 cat >>confdefs.h <<\_ACEOF
39566 #define snprintf ber_pvt_snprintf
39567 _ACEOF
39568
39569         fi
39570         if test "$ac_cv_func_vsnprintf" != yes; then
39571
39572 cat >>confdefs.h <<\_ACEOF
39573 #define vsnprintf ber_pvt_vsnprintf
39574 _ACEOF
39575
39576         fi
39577 fi
39578
39579
39580 if test "$ol_enable_slapi" != no ; then
39581
39582 for ac_header in ltdl.h
39583 do
39584 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
39585 if eval "test \"\${$as_ac_Header+set}\" = set"; then
39586   echo "$as_me:$LINENO: checking for $ac_header" >&5
39587 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
39588 if eval "test \"\${$as_ac_Header+set}\" = set"; then
39589   echo $ECHO_N "(cached) $ECHO_C" >&6
39590 fi
39591 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
39592 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
39593 else
39594   # Is the header compilable?
39595 echo "$as_me:$LINENO: checking $ac_header usability" >&5
39596 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
39597 cat >conftest.$ac_ext <<_ACEOF
39598 /* confdefs.h.  */
39599 _ACEOF
39600 cat confdefs.h >>conftest.$ac_ext
39601 cat >>conftest.$ac_ext <<_ACEOF
39602 /* end confdefs.h.  */
39603 $ac_includes_default
39604 #include <$ac_header>
39605 _ACEOF
39606 rm -f conftest.$ac_objext
39607 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39608   (eval $ac_compile) 2>conftest.er1
39609   ac_status=$?
39610   grep -v '^ *+' conftest.er1 >conftest.err
39611   rm -f conftest.er1
39612   cat conftest.err >&5
39613   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39614   (exit $ac_status); } &&
39615          { ac_try='test -z "$ac_c_werror_flag"
39616                          || test ! -s conftest.err'
39617   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39618   (eval $ac_try) 2>&5
39619   ac_status=$?
39620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39621   (exit $ac_status); }; } &&
39622          { ac_try='test -s conftest.$ac_objext'
39623   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39624   (eval $ac_try) 2>&5
39625   ac_status=$?
39626   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39627   (exit $ac_status); }; }; then
39628   ac_header_compiler=yes
39629 else
39630   echo "$as_me: failed program was:" >&5
39631 sed 's/^/| /' conftest.$ac_ext >&5
39632
39633 ac_header_compiler=no
39634 fi
39635 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39636 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
39637 echo "${ECHO_T}$ac_header_compiler" >&6
39638
39639 # Is the header present?
39640 echo "$as_me:$LINENO: checking $ac_header presence" >&5
39641 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
39642 cat >conftest.$ac_ext <<_ACEOF
39643 /* confdefs.h.  */
39644 _ACEOF
39645 cat confdefs.h >>conftest.$ac_ext
39646 cat >>conftest.$ac_ext <<_ACEOF
39647 /* end confdefs.h.  */
39648 #include <$ac_header>
39649 _ACEOF
39650 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
39651   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
39652   ac_status=$?
39653   grep -v '^ *+' conftest.er1 >conftest.err
39654   rm -f conftest.er1
39655   cat conftest.err >&5
39656   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39657   (exit $ac_status); } >/dev/null; then
39658   if test -s conftest.err; then
39659     ac_cpp_err=$ac_c_preproc_warn_flag
39660     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
39661   else
39662     ac_cpp_err=
39663   fi
39664 else
39665   ac_cpp_err=yes
39666 fi
39667 if test -z "$ac_cpp_err"; then
39668   ac_header_preproc=yes
39669 else
39670   echo "$as_me: failed program was:" >&5
39671 sed 's/^/| /' conftest.$ac_ext >&5
39672
39673   ac_header_preproc=no
39674 fi
39675 rm -f conftest.err conftest.$ac_ext
39676 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
39677 echo "${ECHO_T}$ac_header_preproc" >&6
39678
39679 # So?  What about this header?
39680 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
39681   yes:no: )
39682     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
39683 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
39684     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
39685 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
39686     ac_header_preproc=yes
39687     ;;
39688   no:yes:* )
39689     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
39690 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
39691     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
39692 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
39693     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
39694 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
39695     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
39696 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
39697     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
39698 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
39699     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
39700 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
39701     (
39702       cat <<\_ASBOX
39703 ## --------------------------------------------- ##
39704 ## Report this to <http://www.openldap.org/its/> ##
39705 ## --------------------------------------------- ##
39706 _ASBOX
39707     ) |
39708       sed "s/^/$as_me: WARNING:     /" >&2
39709     ;;
39710 esac
39711 echo "$as_me:$LINENO: checking for $ac_header" >&5
39712 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
39713 if eval "test \"\${$as_ac_Header+set}\" = set"; then
39714   echo $ECHO_N "(cached) $ECHO_C" >&6
39715 else
39716   eval "$as_ac_Header=\$ac_header_preproc"
39717 fi
39718 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
39719 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
39720
39721 fi
39722 if test `eval echo '${'$as_ac_Header'}'` = yes; then
39723   cat >>confdefs.h <<_ACEOF
39724 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
39725 _ACEOF
39726
39727 fi
39728
39729 done
39730
39731
39732         if test $ac_cv_header_ltdl_h != yes ; then
39733                 { { echo "$as_me:$LINENO: error: could not locate <ltdl.h>" >&5
39734 echo "$as_me: error: could not locate <ltdl.h>" >&2;}
39735    { (exit 1); exit 1; }; }
39736         fi
39737         echo "$as_me:$LINENO: checking for lt_dlinit in -lltdl" >&5
39738 echo $ECHO_N "checking for lt_dlinit in -lltdl... $ECHO_C" >&6
39739 if test "${ac_cv_lib_ltdl_lt_dlinit+set}" = set; then
39740   echo $ECHO_N "(cached) $ECHO_C" >&6
39741 else
39742   ac_check_lib_save_LIBS=$LIBS
39743 LIBS="-lltdl  $LIBS"
39744 cat >conftest.$ac_ext <<_ACEOF
39745 /* confdefs.h.  */
39746 _ACEOF
39747 cat confdefs.h >>conftest.$ac_ext
39748 cat >>conftest.$ac_ext <<_ACEOF
39749 /* end confdefs.h.  */
39750
39751 /* Override any gcc2 internal prototype to avoid an error.  */
39752 #ifdef __cplusplus
39753 extern "C"
39754 #endif
39755 /* We use char because int might match the return type of a gcc2
39756    builtin and then its argument prototype would still apply.  */
39757 char lt_dlinit ();
39758 int
39759 main ()
39760 {
39761 lt_dlinit ();
39762   ;
39763   return 0;
39764 }
39765 _ACEOF
39766 rm -f conftest.$ac_objext conftest$ac_exeext
39767 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
39768   (eval $ac_link) 2>conftest.er1
39769   ac_status=$?
39770   grep -v '^ *+' conftest.er1 >conftest.err
39771   rm -f conftest.er1
39772   cat conftest.err >&5
39773   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39774   (exit $ac_status); } &&
39775          { ac_try='test -z "$ac_c_werror_flag"
39776                          || test ! -s conftest.err'
39777   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39778   (eval $ac_try) 2>&5
39779   ac_status=$?
39780   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39781   (exit $ac_status); }; } &&
39782          { ac_try='test -s conftest$ac_exeext'
39783   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39784   (eval $ac_try) 2>&5
39785   ac_status=$?
39786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39787   (exit $ac_status); }; }; then
39788   ac_cv_lib_ltdl_lt_dlinit=yes
39789 else
39790   echo "$as_me: failed program was:" >&5
39791 sed 's/^/| /' conftest.$ac_ext >&5
39792
39793 ac_cv_lib_ltdl_lt_dlinit=no
39794 fi
39795 rm -f conftest.err conftest.$ac_objext \
39796       conftest$ac_exeext conftest.$ac_ext
39797 LIBS=$ac_check_lib_save_LIBS
39798 fi
39799 echo "$as_me:$LINENO: result: $ac_cv_lib_ltdl_lt_dlinit" >&5
39800 echo "${ECHO_T}$ac_cv_lib_ltdl_lt_dlinit" >&6
39801 if test $ac_cv_lib_ltdl_lt_dlinit = yes; then
39802
39803                 SLAPI_LIBS=-lltdl
39804                 LIBSLAPI=libslapi.a
39805                 LIBSLAPITOOLS=../libslapi.a
39806
39807 cat >>confdefs.h <<\_ACEOF
39808 #define HAVE_LIBLTDL 1
39809 _ACEOF
39810
39811
39812 else
39813   { { echo "$as_me:$LINENO: error: could not locate libtool -lltdl" >&5
39814 echo "$as_me: error: could not locate libtool -lltdl" >&2;}
39815    { (exit 1); exit 1; }; }
39816 fi
39817
39818
39819
39820 cat >>confdefs.h <<\_ACEOF
39821 #define LDAP_SLAPI 1
39822 _ACEOF
39823
39824 fi
39825
39826 if test "$ol_enable_debug" != no ; then
39827         if test "$ol_enable_debug" = traditional; then
39828
39829 cat >>confdefs.h <<\_ACEOF
39830 #define OLD_DEBUG 1
39831 _ACEOF
39832
39833         fi
39834
39835 cat >>confdefs.h <<\_ACEOF
39836 #define LDAP_DEBUG 1
39837 _ACEOF
39838
39839 fi
39840 if test "$ol_enable_syslog" = yes ; then
39841
39842 cat >>confdefs.h <<\_ACEOF
39843 #define LDAP_SYSLOG 1
39844 _ACEOF
39845
39846 fi
39847 if test "$ol_link_kbind" != no ; then
39848
39849 cat >>confdefs.h <<\_ACEOF
39850 #define LDAP_API_FEATURE_X_OPENLDAP_V2_KBIND LDAP_VENDOR_VERSION
39851 _ACEOF
39852
39853 fi
39854 if test "$ol_enable_proctitle" != no ; then
39855
39856 cat >>confdefs.h <<\_ACEOF
39857 #define LDAP_PROCTITLE 1
39858 _ACEOF
39859
39860 fi
39861 if test "$ol_enable_referrals" != no ; then
39862
39863 cat >>confdefs.h <<\_ACEOF
39864 #define LDAP_API_FEATURE_X_OPENLDAP_V2_REFERRALS LDAP_VENDOR_VERSION
39865 _ACEOF
39866
39867 fi
39868 if test "$ol_enable_local" != no; then
39869
39870 cat >>confdefs.h <<\_ACEOF
39871 #define LDAP_PF_LOCAL 1
39872 _ACEOF
39873
39874 fi
39875 if test "$ol_link_ipv6" != no; then
39876
39877 cat >>confdefs.h <<\_ACEOF
39878 #define LDAP_PF_INET6 1
39879 _ACEOF
39880
39881 fi
39882 if test "$ol_enable_cleartext" != no ; then
39883
39884 cat >>confdefs.h <<\_ACEOF
39885 #define SLAPD_CLEARTEXT 1
39886 _ACEOF
39887
39888 fi
39889 if test "$ol_enable_crypt" != no ; then
39890
39891 cat >>confdefs.h <<\_ACEOF
39892 #define SLAPD_CRYPT 1
39893 _ACEOF
39894
39895 fi
39896 if test "$ol_link_spasswd" != no ; then
39897
39898 cat >>confdefs.h <<\_ACEOF
39899 #define SLAPD_SPASSWD 1
39900 _ACEOF
39901
39902 fi
39903 if test "$ol_enable_rlookups" != no ; then
39904
39905 cat >>confdefs.h <<\_ACEOF
39906 #define SLAPD_RLOOKUPS 1
39907 _ACEOF
39908
39909 fi
39910 if test "$ol_enable_aci" != no ; then
39911         if test $ol_enable_dynacl = no ; then
39912                 ol_enable_dynacl=yes
39913                 { echo "$as_me:$LINENO: WARNING: ACIs need dynacl" >&5
39914 echo "$as_me: WARNING: ACIs need dynacl" >&2;}
39915         fi
39916         if test "$ol_enable_aci" = mod ; then
39917                 MFLAG=SLAPD_MOD_DYNAMIC
39918                                 { { echo "$as_me:$LINENO: error: ACI build as dynamic module not supported (yet)" >&5
39919 echo "$as_me: error: ACI build as dynamic module not supported (yet)" >&2;}
39920    { (exit 1); exit 1; }; }
39921         else
39922                 MFLAG=SLAPD_MOD_STATIC
39923         fi
39924         WITH_ACI_ENABLED=$ol_enable_aci
39925
39926 cat >>confdefs.h <<_ACEOF
39927 #define SLAPD_ACI_ENABLED $MFLAG
39928 _ACEOF
39929
39930 else
39931         WITH_ACI_ENABLED=no
39932 fi
39933 if test "$ol_enable_dynacl" != no ; then
39934
39935 cat >>confdefs.h <<\_ACEOF
39936 #define SLAP_DYNACL 1
39937 _ACEOF
39938
39939 fi
39940
39941 if test "$ol_link_modules" != no ; then
39942
39943 cat >>confdefs.h <<\_ACEOF
39944 #define SLAPD_MODULES 1
39945 _ACEOF
39946
39947         BUILD_SLAPD=yes
39948         SLAPD_MODULES_LDFLAGS="-dlopen self"
39949 fi
39950
39951
39952 cat >>confdefs.h <<\_ACEOF
39953 #define SLAPD_MOD_STATIC 1
39954 _ACEOF
39955
39956
39957 cat >>confdefs.h <<\_ACEOF
39958 #define SLAPD_MOD_DYNAMIC 2
39959 _ACEOF
39960
39961
39962 if test "$ol_enable_bdb" != no ; then
39963         BUILD_SLAPD=yes
39964         BUILD_BDB=$ol_enable_bdb
39965         if test "$ol_enable_bdb" = mod ; then
39966                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-bdb"
39967                 MFLAG=SLAPD_MOD_DYNAMIC
39968         else
39969                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-bdb"
39970                 MFLAG=SLAPD_MOD_STATIC
39971         fi
39972
39973 cat >>confdefs.h <<_ACEOF
39974 #define SLAPD_BDB $MFLAG
39975 _ACEOF
39976
39977 fi
39978
39979 if test "$ol_enable_dnssrv" != no ; then
39980         BUILD_SLAPD=yes
39981         BUILD_DNSSRV=$ol_enable_dnssrv
39982         if test "$ol_enable_dnssrv" = mod ; then
39983                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-dnssrv"
39984                 MFLAG=SLAPD_MOD_DYNAMIC
39985         else
39986                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-dnssrv"
39987                 MFLAG=SLAPD_MOD_STATIC
39988         fi
39989
39990 cat >>confdefs.h <<_ACEOF
39991 #define SLAPD_DNSSRV $MFLAG
39992 _ACEOF
39993
39994 fi
39995
39996 if test "$ol_enable_hdb" != no ; then
39997         BUILD_SLAPD=yes
39998         BUILD_HDB=$ol_enable_hdb
39999         if test "$ol_enable_hdb" = mod ; then
40000                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-hdb"
40001                 MFLAG=SLAPD_MOD_DYNAMIC
40002         else
40003                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-hdb"
40004                 MFLAG=SLAPD_MOD_STATIC
40005         fi
40006
40007 cat >>confdefs.h <<_ACEOF
40008 #define SLAPD_HDB $MFLAG
40009 _ACEOF
40010
40011 fi
40012
40013 if test "$ol_enable_ldap" != no ; then
40014         BUILD_SLAPD=yes
40015         BUILD_LDAP=$ol_enable_ldap
40016         if test "$ol_enable_ldap" = mod ; then
40017                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-ldap"
40018                 MFLAG=SLAPD_MOD_DYNAMIC
40019         else
40020                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-ldap"
40021                 MFLAG=SLAPD_MOD_STATIC
40022         fi
40023
40024 cat >>confdefs.h <<_ACEOF
40025 #define SLAPD_LDAP $MFLAG
40026 _ACEOF
40027
40028 fi
40029
40030 if test "$ol_enable_meta" != no ; then
40031         BUILD_SLAPD=yes
40032         BUILD_META=$ol_enable_meta
40033         BUILD_REWRITE=yes
40034         if test "$ol_enable_meta" = mod ; then
40035                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-meta"
40036                 MFLAG=SLAPD_MOD_DYNAMIC
40037         else
40038                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-meta"
40039                 MFLAG=SLAPD_MOD_STATIC
40040         fi
40041
40042 cat >>confdefs.h <<_ACEOF
40043 #define SLAPD_META $MFLAG
40044 _ACEOF
40045
40046 fi
40047
40048 if test "$ol_enable_monitor" != no ; then
40049         BUILD_SLAPD=yes
40050         BUILD_MONITOR=$ol_enable_monitor
40051         if test "$ol_enable_monitor" = mod ; then
40052                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-monitor"
40053                 MFLAG=SLAPD_MOD_DYNAMIC
40054         else
40055                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-monitor"
40056                 MFLAG=SLAPD_MOD_STATIC
40057         fi
40058
40059 cat >>confdefs.h <<_ACEOF
40060 #define SLAPD_MONITOR $MFLAG
40061 _ACEOF
40062
40063 fi
40064
40065 if test "$ol_enable_null" != no ; then
40066         BUILD_SLAPD=yes
40067         BUILD_NULL=$ol_enable_null
40068         if test "$ol_enable_null" = mod ; then
40069                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-null"
40070                 MFLAG=SLAPD_MOD_DYNAMIC
40071         else
40072                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-null"
40073                 MFLAG=SLAPD_MOD_STATIC
40074         fi
40075
40076 cat >>confdefs.h <<_ACEOF
40077 #define SLAPD_NULL $MFLAG
40078 _ACEOF
40079
40080 fi
40081
40082 if test "$ol_enable_passwd" != no ; then
40083         BUILD_SLAPD=yes
40084         BUILD_PASSWD=$ol_enable_passwd
40085         if test "$ol_enable_passwd" = mod ; then
40086                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-passwd"
40087                 MFLAG=SLAPD_MOD_DYNAMIC
40088         else
40089                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-passwd"
40090                 MFLAG=SLAPD_MOD_STATIC
40091         fi
40092
40093 cat >>confdefs.h <<_ACEOF
40094 #define SLAPD_PASSWD $MFLAG
40095 _ACEOF
40096
40097 fi
40098
40099 if test "$ol_link_perl" != no ; then
40100         BUILD_SLAPD=yes
40101         BUILD_PERL=$ol_enable_perl
40102         if test "$ol_enable_perl" = mod ; then
40103                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-perl"
40104                 MFLAG=SLAPD_MOD_DYNAMIC
40105         else
40106                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-perl"
40107                 MFLAG=SLAPD_MOD_STATIC
40108         fi
40109
40110 cat >>confdefs.h <<_ACEOF
40111 #define SLAPD_PERL $MFLAG
40112 _ACEOF
40113
40114 fi
40115
40116 if test "$ol_enable_relay" != no ; then
40117         BUILD_SLAPD=yes
40118         BUILD_RELAY=$ol_enable_relay
40119         if test "$ol_enable_relay" = mod ; then
40120                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-relay"
40121                 MFLAG=SLAPD_MOD_DYNAMIC
40122         else
40123                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-relay"
40124                 MFLAG=SLAPD_MOD_STATIC
40125         fi
40126
40127 cat >>confdefs.h <<_ACEOF
40128 #define SLAPD_RELAY $MFLAG
40129 _ACEOF
40130
40131 fi
40132
40133 if test "$ol_enable_shell" != no ; then
40134         if test "$ol_link_threads" != no ; then
40135                 { echo "$as_me:$LINENO: WARNING: Use of --without-threads is recommended with back-shell" >&5
40136 echo "$as_me: WARNING: Use of --without-threads is recommended with back-shell" >&2;}
40137         fi
40138         BUILD_SLAPD=yes
40139         BUILD_SHELL=$ol_enable_shell
40140         if test "$ol_enable_shell" = mod ; then
40141                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-shell"
40142                 MFLAG=SLAPD_MOD_DYNAMIC
40143         else
40144                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-shell"
40145                 MFLAG=SLAPD_MOD_STATIC
40146         fi
40147
40148 cat >>confdefs.h <<_ACEOF
40149 #define SLAPD_SHELL $MFLAG
40150 _ACEOF
40151
40152 fi
40153
40154 if test "$ol_link_sql" != no ; then
40155         BUILD_SLAPD=yes
40156         BUILD_SQL=$ol_enable_sql
40157         if test "$ol_enable_sql" = mod; then
40158                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-sql"
40159                 MFLAG=SLAPD_MOD_DYNAMIC
40160         else
40161                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-sql"
40162                 MFLAG=SLAPD_MOD_STATIC
40163         fi
40164
40165 cat >>confdefs.h <<_ACEOF
40166 #define SLAPD_SQL $MFLAG
40167 _ACEOF
40168
40169 fi
40170
40171 if test "$ol_enable_accesslog" != no ; then
40172         BUILD_ACCESSLOG=$ol_enable_accesslog
40173         if test "$ol_enable_accesslog" = mod ; then
40174                 MFLAG=SLAPD_MOD_DYNAMIC
40175                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS accesslog.la"
40176         else
40177                 MFLAG=SLAPD_MOD_STATIC
40178                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS accesslog.o"
40179         fi
40180
40181 cat >>confdefs.h <<_ACEOF
40182 #define SLAPD_OVER_ACCESSLOG $MFLAG
40183 _ACEOF
40184
40185 fi
40186
40187 if test "$ol_enable_auditlog" != no ; then
40188         BUILD_AUDITLOG=$ol_enable_auditlog
40189         if test "$ol_enable_auditlog" = mod ; then
40190                 MFLAG=SLAPD_MOD_DYNAMIC
40191                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS auditlog.la"
40192         else
40193                 MFLAG=SLAPD_MOD_STATIC
40194                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS auditlog.o"
40195         fi
40196
40197 cat >>confdefs.h <<_ACEOF
40198 #define SLAPD_OVER_AUDITLOG $MFLAG
40199 _ACEOF
40200
40201 fi
40202
40203 if test "$ol_enable_constraint" != no ; then
40204         BUILD_CONSTRAINT=$ol_enable_constraint
40205         if test "$ol_enable_constraint" = mod ; then
40206                 MFLAG=SLAPD_MOD_DYNAMIC
40207                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS constraint.la"
40208         else
40209                 MFLAG=SLAPD_MOD_STATIC
40210                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS constraint.o"
40211         fi
40212
40213 cat >>confdefs.h <<_ACEOF
40214 #define SLAPD_OVER_CONSTRAINT $MFLAG
40215 _ACEOF
40216
40217 fi
40218
40219 if test "$ol_enable_dds" != no ; then
40220         BUILD_DDS=$ol_enable_dds
40221         if test "$ol_enable_dds" = mod ; then
40222                 MFLAG=SLAPD_MOD_DYNAMIC
40223                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS dds.la"
40224         else
40225                 MFLAG=SLAPD_MOD_STATIC
40226                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS dds.o"
40227         fi
40228
40229 cat >>confdefs.h <<_ACEOF
40230 #define SLAPD_OVER_DDS $MFLAG
40231 _ACEOF
40232
40233 fi
40234
40235 if test "$ol_enable_denyop" != no ; then
40236         BUILD_DENYOP=$ol_enable_denyop
40237         if test "$ol_enable_denyop" = mod ; then
40238                 MFLAG=SLAPD_MOD_DYNAMIC
40239                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS denyop.la"
40240         else
40241                 MFLAG=SLAPD_MOD_STATIC
40242                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS denyop.o"
40243         fi
40244
40245 cat >>confdefs.h <<_ACEOF
40246 #define SLAPD_OVER_DENYOP $MFLAG
40247 _ACEOF
40248
40249 fi
40250
40251 if test "$ol_enable_dyngroup" != no ; then
40252         BUILD_DYNGROUP=$ol_enable_dyngroup
40253         if test "$ol_enable_dyngroup" = mod ; then
40254                 MFLAG=SLAPD_MOD_DYNAMIC
40255                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS dyngroup.la"
40256         else
40257                 MFLAG=SLAPD_MOD_STATIC
40258                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS dyngroup.o"
40259         fi
40260
40261 cat >>confdefs.h <<_ACEOF
40262 #define SLAPD_OVER_DYNGROUP $MFLAG
40263 _ACEOF
40264
40265 fi
40266
40267 if test "$ol_enable_dynlist" != no ; then
40268         BUILD_DYNLIST=$ol_enable_dynlist
40269         if test "$ol_enable_dynlist" = mod ; then
40270                 MFLAG=SLAPD_MOD_DYNAMIC
40271                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS dynlist.la"
40272         else
40273                 MFLAG=SLAPD_MOD_STATIC
40274                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS dynlist.o"
40275         fi
40276
40277 cat >>confdefs.h <<_ACEOF
40278 #define SLAPD_OVER_DYNLIST $MFLAG
40279 _ACEOF
40280
40281 fi
40282
40283 if test "$ol_enable_lastmod" != no ; then
40284         BUILD_LASTMOD=$ol_enable_lastmod
40285         if test "$ol_enable_lastmod" = mod ; then
40286                 MFLAG=SLAPD_MOD_DYNAMIC
40287                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS lastmod.la"
40288         else
40289                 MFLAG=SLAPD_MOD_STATIC
40290                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS lastmod.o"
40291         fi
40292
40293 cat >>confdefs.h <<_ACEOF
40294 #define SLAPD_OVER_LASTMOD $MFLAG
40295 _ACEOF
40296
40297 fi
40298
40299 if test "$ol_enable_ppolicy" != no ; then
40300         BUILD_PPOLICY=$ol_enable_ppolicy
40301         if test "$ol_enable_ppolicy" = mod ; then
40302                 MFLAG=SLAPD_MOD_DYNAMIC
40303                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS ppolicy.la"
40304         else
40305                 MFLAG=SLAPD_MOD_STATIC
40306                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS ppolicy.o"
40307         fi
40308
40309 cat >>confdefs.h <<_ACEOF
40310 #define SLAPD_OVER_PPOLICY $MFLAG
40311 _ACEOF
40312
40313 fi
40314
40315 if test "$ol_enable_proxycache" != no ; then
40316         BUILD_PROXYCACHE=$ol_enable_proxycache
40317         if test "$ol_enable_proxycache" = mod ; then
40318                 MFLAG=SLAPD_MOD_DYNAMIC
40319                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS pcache.la"
40320         else
40321                 MFLAG=SLAPD_MOD_STATIC
40322                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS pcache.o"
40323         fi
40324
40325 cat >>confdefs.h <<_ACEOF
40326 #define SLAPD_OVER_PROXYCACHE $MFLAG
40327 _ACEOF
40328
40329 fi
40330
40331 if test "$ol_enable_refint" != no ; then
40332         BUILD_REFINT=$ol_enable_refint
40333         if test "$ol_enable_refint" = mod ; then
40334                 MFLAG=SLAPD_MOD_DYNAMIC
40335                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS refint.la"
40336         else
40337                 MFLAG=SLAPD_MOD_STATIC
40338                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS refint.o"
40339         fi
40340
40341 cat >>confdefs.h <<_ACEOF
40342 #define SLAPD_OVER_REFINT $MFLAG
40343 _ACEOF
40344
40345 fi
40346
40347 if test "$ol_enable_retcode" != no ; then
40348         BUILD_RETCODE=$ol_enable_retcode
40349         if test "$ol_enable_retcode" = mod ; then
40350                 MFLAG=SLAPD_MOD_DYNAMIC
40351                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS retcode.la"
40352         else
40353                 MFLAG=SLAPD_MOD_STATIC
40354                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS retcode.o"
40355         fi
40356
40357 cat >>confdefs.h <<_ACEOF
40358 #define SLAPD_OVER_RETCODE $MFLAG
40359 _ACEOF
40360
40361 fi
40362
40363 if test "$ol_enable_rwm" != no ; then
40364         BUILD_REWRITE=yes
40365         BUILD_RWM=$ol_enable_rwm
40366         if test "$ol_enable_rwm" = mod ; then
40367                 MFLAG=SLAPD_MOD_DYNAMIC
40368                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS rwm.la"
40369         else
40370                 MFLAG=SLAPD_MOD_STATIC
40371                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS rwm_x.o"
40372         fi
40373
40374 cat >>confdefs.h <<_ACEOF
40375 #define SLAPD_OVER_RWM $MFLAG
40376 _ACEOF
40377
40378 fi
40379
40380 if test "$ol_enable_seqmod" != no ; then
40381         BUILD_SEQMOD=$ol_enable_seqmod
40382         if test "$ol_enable_seqmod" = mod ; then
40383                 MFLAG=SLAPD_MOD_DYNAMIC
40384                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS seqmod.la"
40385         else
40386                 MFLAG=SLAPD_MOD_STATIC
40387                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS seqmod.o"
40388         fi
40389
40390 cat >>confdefs.h <<_ACEOF
40391 #define SLAPD_OVER_SEQMOD $MFLAG
40392 _ACEOF
40393
40394 fi
40395
40396 if test "$ol_enable_syncprov" != no ; then
40397         BUILD_SYNCPROV=$ol_enable_syncprov
40398         if test "$ol_enable_syncprov" = mod ; then
40399                 MFLAG=SLAPD_MOD_DYNAMIC
40400                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS syncprov.la"
40401         else
40402                 MFLAG=SLAPD_MOD_STATIC
40403                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS syncprov.o"
40404         fi
40405
40406 cat >>confdefs.h <<_ACEOF
40407 #define SLAPD_OVER_SYNCPROV $MFLAG
40408 _ACEOF
40409
40410 fi
40411
40412 if test "$ol_enable_translucent" != no ; then
40413         BUILD_TRANSLUCENT=$ol_enable_translucent
40414         if test "$ol_enable_translucent" = mod ; then
40415                 MFLAG=SLAPD_MOD_DYNAMIC
40416                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS translucent.la"
40417         else
40418                 MFLAG=SLAPD_MOD_STATIC
40419                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS translucent.o"
40420         fi
40421
40422 cat >>confdefs.h <<_ACEOF
40423 #define SLAPD_OVER_TRANSLUCENT $MFLAG
40424 _ACEOF
40425
40426 fi
40427
40428 if test "$ol_enable_unique" != no ; then
40429         BUILD_UNIQUE=$ol_enable_unique
40430         if test "$ol_enable_unique" = mod ; then
40431                 MFLAG=SLAPD_MOD_DYNAMIC
40432                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS unique.la"
40433         else
40434                 MFLAG=SLAPD_MOD_STATIC
40435                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS unique.o"
40436         fi
40437
40438 cat >>confdefs.h <<_ACEOF
40439 #define SLAPD_OVER_UNIQUE $MFLAG
40440 _ACEOF
40441
40442 fi
40443
40444 if test "$ol_enable_valsort" != no ; then
40445         BUILD_VALSORT=$ol_enable_valsort
40446         if test "$ol_enable_valsort" = mod ; then
40447                 MFLAG=SLAPD_MOD_DYNAMIC
40448                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS valsort.la"
40449         else
40450                 MFLAG=SLAPD_MOD_STATIC
40451                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS valsort.o"
40452         fi
40453
40454 cat >>confdefs.h <<_ACEOF
40455 #define SLAPD_OVER_VALSORT $MFLAG
40456 _ACEOF
40457
40458 fi
40459
40460 if test "$ol_enable_slurpd" != no &&
40461    test "$ol_link_threads" != no &&
40462    test $BUILD_SLAPD = yes ; then
40463         BUILD_SLURPD=yes
40464 fi
40465
40466 if test "$ol_enable_rewrite" != no ; then
40467
40468 cat >>confdefs.h <<\_ACEOF
40469 #define ENABLE_REWRITE 1
40470 _ACEOF
40471
40472         BUILD_REWRITE=yes
40473 fi
40474
40475 if test "$ol_enable_slapi" != no ; then
40476
40477 cat >>confdefs.h <<\_ACEOF
40478 #define ENABLE_SLAPI 1
40479 _ACEOF
40480
40481         BUILD_SLAPI=yes
40482         SLAPD_SLAPI_DEPEND=libslapi.a
40483 fi
40484
40485
40486
40487 if test "$ac_cv_mingw32" = yes ; then
40488         PLAT=NT
40489         SLAPD_MODULES_LDFLAGS=
40490 else
40491         PLAT=UNIX
40492 fi
40493
40494
40495
40496
40497
40498
40499
40500
40501
40502
40503
40504
40505
40506
40507
40508
40509
40510
40511
40512
40513
40514
40515
40516
40517
40518
40519
40520
40521
40522
40523
40524
40525
40526
40527
40528
40529
40530
40531
40532
40533
40534
40535
40536
40537
40538
40539
40540
40541
40542
40543
40544
40545
40546
40547
40548
40549
40550
40551
40552
40553
40554
40555
40556
40557
40558
40559
40560
40561
40562
40563
40564
40565
40566
40567
40568
40569
40570
40571
40572
40573
40574
40575
40576
40577
40578 # Check whether --with-xxinstall or --without-xxinstall was given.
40579 if test "${with_xxinstall+set}" = set; then
40580   withval="$with_xxinstall"
40581
40582 fi;
40583
40584
40585                                                                                                                                                                                                                                                                                                                                                                                                       ac_config_files="$ac_config_files Makefile:build/top.mk:Makefile.in:build/dir.mk doc/Makefile:build/top.mk:doc/Makefile.in:build/dir.mk doc/man/Makefile:build/top.mk:doc/man/Makefile.in:build/dir.mk doc/man/man1/Makefile:build/top.mk:doc/man/man1/Makefile.in:build/man.mk doc/man/man3/Makefile:build/top.mk:doc/man/man3/Makefile.in:build/man.mk doc/man/man5/Makefile:build/top.mk:doc/man/man5/Makefile.in:build/man.mk doc/man/man8/Makefile:build/top.mk:doc/man/man8/Makefile.in:build/man.mk clients/Makefile:build/top.mk:clients/Makefile.in:build/dir.mk clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk include/Makefile:build/top.mk:include/Makefile.in libraries/Makefile:build/top.mk:libraries/Makefile.in:build/dir.mk libraries/liblber/Makefile:build/top.mk:libraries/liblber/Makefile.in:build/lib.mk:build/lib-shared.mk libraries/libldap/Makefile:build/top.mk:libraries/libldap/Makefile.in:build/lib.mk:build/lib-shared.mk libraries/libldap_r/Makefile:build/top.mk:libraries/libldap_r/Makefile.in:build/lib.mk:build/lib-shared.mk libraries/liblunicode/Makefile:build/top.mk:libraries/liblunicode/Makefile.in:build/lib.mk:build/lib-static.mk libraries/liblutil/Makefile:build/top.mk:libraries/liblutil/Makefile.in:build/lib.mk:build/lib-static.mk libraries/librewrite/Makefile:build/top.mk:libraries/librewrite/Makefile.in:build/lib.mk:build/lib-static.mk servers/Makefile:build/top.mk:servers/Makefile.in:build/dir.mk servers/slapd/Makefile:build/top.mk:servers/slapd/Makefile.in:build/srv.mk servers/slapd/back-bdb/Makefile:build/top.mk:servers/slapd/back-bdb/Makefile.in:build/mod.mk servers/slapd/back-dnssrv/Makefile:build/top.mk:servers/slapd/back-dnssrv/Makefile.in:build/mod.mk servers/slapd/back-hdb/Makefile:build/top.mk:servers/slapd/back-hdb/Makefile.in:build/mod.mk servers/slapd/back-ldap/Makefile:build/top.mk:servers/slapd/back-ldap/Makefile.in:build/mod.mk servers/slapd/back-ldif/Makefile:build/top.mk:servers/slapd/back-ldif/Makefile.in:build/mod.mk servers/slapd/back-meta/Makefile:build/top.mk:servers/slapd/back-meta/Makefile.in:build/mod.mk servers/slapd/back-monitor/Makefile:build/top.mk:servers/slapd/back-monitor/Makefile.in:build/mod.mk servers/slapd/back-null/Makefile:build/top.mk:servers/slapd/back-null/Makefile.in:build/mod.mk servers/slapd/back-passwd/Makefile:build/top.mk:servers/slapd/back-passwd/Makefile.in:build/mod.mk servers/slapd/back-perl/Makefile:build/top.mk:servers/slapd/back-perl/Makefile.in:build/mod.mk servers/slapd/back-relay/Makefile:build/top.mk:servers/slapd/back-relay/Makefile.in:build/mod.mk servers/slapd/back-shell/Makefile:build/top.mk:servers/slapd/back-shell/Makefile.in:build/mod.mk servers/slapd/back-sql/Makefile:build/top.mk:servers/slapd/back-sql/Makefile.in:build/mod.mk servers/slapd/shell-backends/Makefile:build/top.mk:servers/slapd/shell-backends/Makefile.in:build/srv.mk servers/slapd/slapi/Makefile:build/top.mk:servers/slapd/slapi/Makefile.in:build/lib.mk:build/lib-shared.mk servers/slapd/overlays/Makefile:build/top.mk:servers/slapd/overlays/Makefile.in:build/lib.mk servers/slurpd/Makefile:build/top.mk:servers/slurpd/Makefile.in:build/srv.mk tests/Makefile:build/top.mk:tests/Makefile.in:build/dir.mk tests/run tests/progs/Makefile:build/top.mk:tests/progs/Makefile.in:build/rules.mk"
40586
40587
40588           ac_config_commands="$ac_config_commands default"
40589
40590
40591
40592 test "x$prefix" = xNONE && prefix=$ac_default_prefix
40593 # Let make expand exec_prefix.
40594 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
40595
40596 # VPATH may cause trouble with some makes, so we remove $(srcdir),
40597 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
40598 # trailing colons and then remove the whole line if VPATH becomes empty
40599 # (actually we leave an empty line to preserve line numbers).
40600 if test "x$srcdir" = x.; then
40601   ac_vpsub='/^[  ]*VPATH[        ]*=/{
40602 s/:*\$(srcdir):*/:/;
40603 s/:*\${srcdir}:*/:/;
40604 s/:*@srcdir@:*/:/;
40605 s/^\([^=]*=[     ]*\):*/\1/;
40606 s/:*$//;
40607 s/^[^=]*=[       ]*$//;
40608 }'
40609 fi
40610
40611 DEFS=-DHAVE_CONFIG_H
40612
40613 ac_libobjs=
40614 ac_ltlibobjs=
40615 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
40616   # 1. Remove the extension, and $U if already installed.
40617   ac_i=`echo "$ac_i" |
40618          sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
40619   # 2. Add them.
40620   ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
40621   ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
40622 done
40623 LIBOBJS=$ac_libobjs
40624
40625 LTLIBOBJS=$ac_ltlibobjs
40626
40627
40628 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
40629   { { echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined.
40630 Usually this means the macro was only invoked conditionally." >&5
40631 echo "$as_me: error: conditional \"AMDEP\" was never defined.
40632 Usually this means the macro was only invoked conditionally." >&2;}
40633    { (exit 1); exit 1; }; }
40634 fi
40635 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
40636   { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
40637 Usually this means the macro was only invoked conditionally." >&5
40638 echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
40639 Usually this means the macro was only invoked conditionally." >&2;}
40640    { (exit 1); exit 1; }; }
40641 fi
40642 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
40643   { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
40644 Usually this means the macro was only invoked conditionally." >&5
40645 echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
40646 Usually this means the macro was only invoked conditionally." >&2;}
40647    { (exit 1); exit 1; }; }
40648 fi
40649
40650 : ${CONFIG_STATUS=./config.status}
40651 ac_clean_files_save=$ac_clean_files
40652 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
40653 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
40654 echo "$as_me: creating $CONFIG_STATUS" >&6;}
40655 cat >$CONFIG_STATUS <<_ACEOF
40656 #! $SHELL
40657 # Generated by $as_me.
40658 # Run this file to recreate the current configuration.
40659 # Compiler output produced by configure, useful for debugging
40660 # configure, is in config.log if it exists.
40661
40662 debug=false
40663 ac_cs_recheck=false
40664 ac_cs_silent=false
40665 SHELL=\${CONFIG_SHELL-$SHELL}
40666 _ACEOF
40667
40668 cat >>$CONFIG_STATUS <<\_ACEOF
40669 ## --------------------- ##
40670 ## M4sh Initialization.  ##
40671 ## --------------------- ##
40672
40673 # Be Bourne compatible
40674 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
40675   emulate sh
40676   NULLCMD=:
40677   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
40678   # is contrary to our usage.  Disable this feature.
40679   alias -g '${1+"$@"}'='"$@"'
40680 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
40681   set -o posix
40682 fi
40683 DUALCASE=1; export DUALCASE # for MKS sh
40684
40685 # Support unset when possible.
40686 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
40687   as_unset=unset
40688 else
40689   as_unset=false
40690 fi
40691
40692
40693 # Work around bugs in pre-3.0 UWIN ksh.
40694 $as_unset ENV MAIL MAILPATH
40695 PS1='$ '
40696 PS2='> '
40697 PS4='+ '
40698
40699 # NLS nuisances.
40700 for as_var in \
40701   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
40702   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
40703   LC_TELEPHONE LC_TIME
40704 do
40705   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
40706     eval $as_var=C; export $as_var
40707   else
40708     $as_unset $as_var
40709   fi
40710 done
40711
40712 # Required to use basename.
40713 if expr a : '\(a\)' >/dev/null 2>&1; then
40714   as_expr=expr
40715 else
40716   as_expr=false
40717 fi
40718
40719 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
40720   as_basename=basename
40721 else
40722   as_basename=false
40723 fi
40724
40725
40726 # Name of the executable.
40727 as_me=`$as_basename "$0" ||
40728 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
40729          X"$0" : 'X\(//\)$' \| \
40730          X"$0" : 'X\(/\)$' \| \
40731          .     : '\(.\)' 2>/dev/null ||
40732 echo X/"$0" |
40733     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
40734           /^X\/\(\/\/\)$/{ s//\1/; q; }
40735           /^X\/\(\/\).*/{ s//\1/; q; }
40736           s/.*/./; q'`
40737
40738
40739 # PATH needs CR, and LINENO needs CR and PATH.
40740 # Avoid depending upon Character Ranges.
40741 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
40742 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
40743 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
40744 as_cr_digits='0123456789'
40745 as_cr_alnum=$as_cr_Letters$as_cr_digits
40746
40747 # The user is always right.
40748 if test "${PATH_SEPARATOR+set}" != set; then
40749   echo "#! /bin/sh" >conf$$.sh
40750   echo  "exit 0"   >>conf$$.sh
40751   chmod +x conf$$.sh
40752   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
40753     PATH_SEPARATOR=';'
40754   else
40755     PATH_SEPARATOR=:
40756   fi
40757   rm -f conf$$.sh
40758 fi
40759
40760
40761   as_lineno_1=$LINENO
40762   as_lineno_2=$LINENO
40763   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
40764   test "x$as_lineno_1" != "x$as_lineno_2" &&
40765   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
40766   # Find who we are.  Look in the path if we contain no path at all
40767   # relative or not.
40768   case $0 in
40769     *[\\/]* ) as_myself=$0 ;;
40770     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40771 for as_dir in $PATH
40772 do
40773   IFS=$as_save_IFS
40774   test -z "$as_dir" && as_dir=.
40775   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
40776 done
40777
40778        ;;
40779   esac
40780   # We did not find ourselves, most probably we were run as `sh COMMAND'
40781   # in which case we are not to be found in the path.
40782   if test "x$as_myself" = x; then
40783     as_myself=$0
40784   fi
40785   if test ! -f "$as_myself"; then
40786     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
40787 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
40788    { (exit 1); exit 1; }; }
40789   fi
40790   case $CONFIG_SHELL in
40791   '')
40792     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40793 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
40794 do
40795   IFS=$as_save_IFS
40796   test -z "$as_dir" && as_dir=.
40797   for as_base in sh bash ksh sh5; do
40798          case $as_dir in
40799          /*)
40800            if ("$as_dir/$as_base" -c '
40801   as_lineno_1=$LINENO
40802   as_lineno_2=$LINENO
40803   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
40804   test "x$as_lineno_1" != "x$as_lineno_2" &&
40805   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
40806              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
40807              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
40808              CONFIG_SHELL=$as_dir/$as_base
40809              export CONFIG_SHELL
40810              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
40811            fi;;
40812          esac
40813        done
40814 done
40815 ;;
40816   esac
40817
40818   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
40819   # uniformly replaced by the line number.  The first 'sed' inserts a
40820   # line-number line before each line; the second 'sed' does the real
40821   # work.  The second script uses 'N' to pair each line-number line
40822   # with the numbered line, and appends trailing '-' during
40823   # substitution so that $LINENO is not a special case at line end.
40824   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
40825   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
40826   sed '=' <$as_myself |
40827     sed '
40828       N
40829       s,$,-,
40830       : loop
40831       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
40832       t loop
40833       s,-$,,
40834       s,^['$as_cr_digits']*\n,,
40835     ' >$as_me.lineno &&
40836   chmod +x $as_me.lineno ||
40837     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
40838 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
40839    { (exit 1); exit 1; }; }
40840
40841   # Don't try to exec as it changes $[0], causing all sort of problems
40842   # (the dirname of $[0] is not the place where we might find the
40843   # original and so on.  Autoconf is especially sensible to this).
40844   . ./$as_me.lineno
40845   # Exit status is that of the last command.
40846   exit
40847 }
40848
40849
40850 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
40851   *c*,-n*) ECHO_N= ECHO_C='
40852 ' ECHO_T='      ' ;;
40853   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
40854   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
40855 esac
40856
40857 if expr a : '\(a\)' >/dev/null 2>&1; then
40858   as_expr=expr
40859 else
40860   as_expr=false
40861 fi
40862
40863 rm -f conf$$ conf$$.exe conf$$.file
40864 echo >conf$$.file
40865 if ln -s conf$$.file conf$$ 2>/dev/null; then
40866   # We could just check for DJGPP; but this test a) works b) is more generic
40867   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
40868   if test -f conf$$.exe; then
40869     # Don't use ln at all; we don't have any links
40870     as_ln_s='cp -p'
40871   else
40872     as_ln_s='ln -s'
40873   fi
40874 elif ln conf$$.file conf$$ 2>/dev/null; then
40875   as_ln_s=ln
40876 else
40877   as_ln_s='cp -p'
40878 fi
40879 rm -f conf$$ conf$$.exe conf$$.file
40880
40881 if mkdir -p . 2>/dev/null; then
40882   as_mkdir_p=:
40883 else
40884   test -d ./-p && rmdir ./-p
40885   as_mkdir_p=false
40886 fi
40887
40888 as_executable_p="test -f"
40889
40890 # Sed expression to map a string onto a valid CPP name.
40891 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
40892
40893 # Sed expression to map a string onto a valid variable name.
40894 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
40895
40896
40897 # IFS
40898 # We need space, tab and new line, in precisely that order.
40899 as_nl='
40900 '
40901 IFS="   $as_nl"
40902
40903 # CDPATH.
40904 $as_unset CDPATH
40905
40906 exec 6>&1
40907
40908 # Open the log real soon, to keep \$[0] and so on meaningful, and to
40909 # report actual input values of CONFIG_FILES etc. instead of their
40910 # values after options handling.  Logging --version etc. is OK.
40911 exec 5>>config.log
40912 {
40913   echo
40914   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
40915 ## Running $as_me. ##
40916 _ASBOX
40917 } >&5
40918 cat >&5 <<_CSEOF
40919
40920 This file was extended by $as_me, which was
40921 generated by GNU Autoconf 2.59.  Invocation command line was
40922
40923   CONFIG_FILES    = $CONFIG_FILES
40924   CONFIG_HEADERS  = $CONFIG_HEADERS
40925   CONFIG_LINKS    = $CONFIG_LINKS
40926   CONFIG_COMMANDS = $CONFIG_COMMANDS
40927   $ $0 $@
40928
40929 _CSEOF
40930 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
40931 echo >&5
40932 _ACEOF
40933
40934 # Files that config.status was made for.
40935 if test -n "$ac_config_files"; then
40936   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
40937 fi
40938
40939 if test -n "$ac_config_headers"; then
40940   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
40941 fi
40942
40943 if test -n "$ac_config_links"; then
40944   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
40945 fi
40946
40947 if test -n "$ac_config_commands"; then
40948   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
40949 fi
40950
40951 cat >>$CONFIG_STATUS <<\_ACEOF
40952
40953 ac_cs_usage="\
40954 \`$as_me' instantiates files from templates according to the
40955 current configuration.
40956
40957 Usage: $0 [OPTIONS] [FILE]...
40958
40959   -h, --help       print this help, then exit
40960   -V, --version    print version number, then exit
40961   -q, --quiet      do not print progress messages
40962   -d, --debug      don't remove temporary files
40963       --recheck    update $as_me by reconfiguring in the same conditions
40964   --file=FILE[:TEMPLATE]
40965                    instantiate the configuration file FILE
40966   --header=FILE[:TEMPLATE]
40967                    instantiate the configuration header FILE
40968
40969 Configuration files:
40970 $config_files
40971
40972 Configuration headers:
40973 $config_headers
40974
40975 Configuration commands:
40976 $config_commands
40977
40978 Report bugs to <bug-autoconf@gnu.org>."
40979 _ACEOF
40980
40981 cat >>$CONFIG_STATUS <<_ACEOF
40982 ac_cs_version="\\
40983 config.status
40984 configured by $0, generated by GNU Autoconf 2.59,
40985   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
40986
40987 Copyright (C) 2003 Free Software Foundation, Inc.
40988 This config.status script is free software; the Free Software Foundation
40989 gives unlimited permission to copy, distribute and modify it."
40990 srcdir=$srcdir
40991 INSTALL="$INSTALL"
40992 _ACEOF
40993
40994 cat >>$CONFIG_STATUS <<\_ACEOF
40995 # If no file are specified by the user, then we need to provide default
40996 # value.  By we need to know if files were specified by the user.
40997 ac_need_defaults=:
40998 while test $# != 0
40999 do
41000   case $1 in
41001   --*=*)
41002     ac_option=`expr "x$1" : 'x\([^=]*\)='`
41003     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
41004     ac_shift=:
41005     ;;
41006   -*)
41007     ac_option=$1
41008     ac_optarg=$2
41009     ac_shift=shift
41010     ;;
41011   *) # This is not an option, so the user has probably given explicit
41012      # arguments.
41013      ac_option=$1
41014      ac_need_defaults=false;;
41015   esac
41016
41017   case $ac_option in
41018   # Handling of the options.
41019 _ACEOF
41020 cat >>$CONFIG_STATUS <<\_ACEOF
41021   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
41022     ac_cs_recheck=: ;;
41023   --version | --vers* | -V )
41024     echo "$ac_cs_version"; exit 0 ;;
41025   --he | --h)
41026     # Conflict between --help and --header
41027     { { echo "$as_me:$LINENO: error: ambiguous option: $1
41028 Try \`$0 --help' for more information." >&5
41029 echo "$as_me: error: ambiguous option: $1
41030 Try \`$0 --help' for more information." >&2;}
41031    { (exit 1); exit 1; }; };;
41032   --help | --hel | -h )
41033     echo "$ac_cs_usage"; exit 0 ;;
41034   --debug | --d* | -d )
41035     debug=: ;;
41036   --file | --fil | --fi | --f )
41037     $ac_shift
41038     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
41039     ac_need_defaults=false;;
41040   --header | --heade | --head | --hea )
41041     $ac_shift
41042     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
41043     ac_need_defaults=false;;
41044   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
41045   | -silent | --silent | --silen | --sile | --sil | --si | --s)
41046     ac_cs_silent=: ;;
41047
41048   # This is an error.
41049   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
41050 Try \`$0 --help' for more information." >&5
41051 echo "$as_me: error: unrecognized option: $1
41052 Try \`$0 --help' for more information." >&2;}
41053    { (exit 1); exit 1; }; } ;;
41054
41055   *) ac_config_targets="$ac_config_targets $1" ;;
41056
41057   esac
41058   shift
41059 done
41060
41061 ac_configure_extra_args=
41062
41063 if $ac_cs_silent; then
41064   exec 6>/dev/null
41065   ac_configure_extra_args="$ac_configure_extra_args --silent"
41066 fi
41067
41068 _ACEOF
41069 cat >>$CONFIG_STATUS <<_ACEOF
41070 if \$ac_cs_recheck; then
41071   echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
41072   exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
41073 fi
41074
41075 _ACEOF
41076
41077 cat >>$CONFIG_STATUS <<_ACEOF
41078 #
41079 # INIT-COMMANDS section.
41080 #
41081
41082 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
41083
41084 STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS"
41085 STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS"
41086
41087
41088 _ACEOF
41089
41090
41091
41092 cat >>$CONFIG_STATUS <<\_ACEOF
41093 for ac_config_target in $ac_config_targets
41094 do
41095   case "$ac_config_target" in
41096   # Handling of arguments.
41097   "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile:build/top.mk:Makefile.in:build/dir.mk" ;;
41098   "doc/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/Makefile:build/top.mk:doc/Makefile.in:build/dir.mk" ;;
41099   "doc/man/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/Makefile:build/top.mk:doc/man/Makefile.in:build/dir.mk" ;;
41100   "doc/man/man1/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man1/Makefile:build/top.mk:doc/man/man1/Makefile.in:build/man.mk" ;;
41101   "doc/man/man3/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man3/Makefile:build/top.mk:doc/man/man3/Makefile.in:build/man.mk" ;;
41102   "doc/man/man5/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man5/Makefile:build/top.mk:doc/man/man5/Makefile.in:build/man.mk" ;;
41103   "doc/man/man8/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man8/Makefile:build/top.mk:doc/man/man8/Makefile.in:build/man.mk" ;;
41104   "clients/Makefile" ) CONFIG_FILES="$CONFIG_FILES clients/Makefile:build/top.mk:clients/Makefile.in:build/dir.mk" ;;
41105   "clients/tools/Makefile" ) CONFIG_FILES="$CONFIG_FILES clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk" ;;
41106   "include/Makefile" ) CONFIG_FILES="$CONFIG_FILES include/Makefile:build/top.mk:include/Makefile.in" ;;
41107   "libraries/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/Makefile:build/top.mk:libraries/Makefile.in:build/dir.mk" ;;
41108   "libraries/liblber/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblber/Makefile:build/top.mk:libraries/liblber/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
41109   "libraries/libldap/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/libldap/Makefile:build/top.mk:libraries/libldap/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
41110   "libraries/libldap_r/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/libldap_r/Makefile:build/top.mk:libraries/libldap_r/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
41111   "libraries/liblunicode/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblunicode/Makefile:build/top.mk:libraries/liblunicode/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
41112   "libraries/liblutil/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblutil/Makefile:build/top.mk:libraries/liblutil/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
41113   "libraries/librewrite/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/librewrite/Makefile:build/top.mk:libraries/librewrite/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
41114   "servers/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/Makefile:build/top.mk:servers/Makefile.in:build/dir.mk" ;;
41115   "servers/slapd/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/Makefile:build/top.mk:servers/slapd/Makefile.in:build/srv.mk" ;;
41116   "servers/slapd/back-bdb/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-bdb/Makefile:build/top.mk:servers/slapd/back-bdb/Makefile.in:build/mod.mk" ;;
41117   "servers/slapd/back-dnssrv/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-dnssrv/Makefile:build/top.mk:servers/slapd/back-dnssrv/Makefile.in:build/mod.mk" ;;
41118   "servers/slapd/back-hdb/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-hdb/Makefile:build/top.mk:servers/slapd/back-hdb/Makefile.in:build/mod.mk" ;;
41119   "servers/slapd/back-ldap/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-ldap/Makefile:build/top.mk:servers/slapd/back-ldap/Makefile.in:build/mod.mk" ;;
41120   "servers/slapd/back-ldif/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-ldif/Makefile:build/top.mk:servers/slapd/back-ldif/Makefile.in:build/mod.mk" ;;
41121   "servers/slapd/back-meta/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-meta/Makefile:build/top.mk:servers/slapd/back-meta/Makefile.in:build/mod.mk" ;;
41122   "servers/slapd/back-monitor/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-monitor/Makefile:build/top.mk:servers/slapd/back-monitor/Makefile.in:build/mod.mk" ;;
41123   "servers/slapd/back-null/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-null/Makefile:build/top.mk:servers/slapd/back-null/Makefile.in:build/mod.mk" ;;
41124   "servers/slapd/back-passwd/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-passwd/Makefile:build/top.mk:servers/slapd/back-passwd/Makefile.in:build/mod.mk" ;;
41125   "servers/slapd/back-perl/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-perl/Makefile:build/top.mk:servers/slapd/back-perl/Makefile.in:build/mod.mk" ;;
41126   "servers/slapd/back-relay/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-relay/Makefile:build/top.mk:servers/slapd/back-relay/Makefile.in:build/mod.mk" ;;
41127   "servers/slapd/back-shell/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-shell/Makefile:build/top.mk:servers/slapd/back-shell/Makefile.in:build/mod.mk" ;;
41128   "servers/slapd/back-sql/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-sql/Makefile:build/top.mk:servers/slapd/back-sql/Makefile.in:build/mod.mk" ;;
41129   "servers/slapd/shell-backends/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/shell-backends/Makefile:build/top.mk:servers/slapd/shell-backends/Makefile.in:build/srv.mk" ;;
41130   "servers/slapd/slapi/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/slapi/Makefile:build/top.mk:servers/slapd/slapi/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
41131   "servers/slapd/overlays/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/overlays/Makefile:build/top.mk:servers/slapd/overlays/Makefile.in:build/lib.mk" ;;
41132   "servers/slurpd/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slurpd/Makefile:build/top.mk:servers/slurpd/Makefile.in:build/srv.mk" ;;
41133   "tests/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/Makefile:build/top.mk:tests/Makefile.in:build/dir.mk" ;;
41134   "tests/run" ) CONFIG_FILES="$CONFIG_FILES tests/run" ;;
41135   "tests/progs/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/progs/Makefile:build/top.mk:tests/progs/Makefile.in:build/rules.mk" ;;
41136   "depfiles" ) CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
41137   "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
41138   "include/portable.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/portable.h:include/portable.hin" ;;
41139   "include/ldap_features.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ldap_features.h:include/ldap_features.hin" ;;
41140   "include/lber_types.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/lber_types.h:include/lber_types.hin" ;;
41141   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
41142 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
41143    { (exit 1); exit 1; }; };;
41144   esac
41145 done
41146
41147 # If the user did not use the arguments to specify the items to instantiate,
41148 # then the envvar interface is used.  Set only those that are not.
41149 # We use the long form for the default assignment because of an extremely
41150 # bizarre bug on SunOS 4.1.3.
41151 if $ac_need_defaults; then
41152   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
41153   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
41154   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
41155 fi
41156
41157 # Have a temporary directory for convenience.  Make it in the build tree
41158 # simply because there is no reason to put it here, and in addition,
41159 # creating and moving files from /tmp can sometimes cause problems.
41160 # Create a temporary directory, and hook for its removal unless debugging.
41161 $debug ||
41162 {
41163   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
41164   trap '{ (exit 1); exit 1; }' 1 2 13 15
41165 }
41166
41167 # Create a (secure) tmp directory for tmp files.
41168
41169 {
41170   tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
41171   test -n "$tmp" && test -d "$tmp"
41172 }  ||
41173 {
41174   tmp=./confstat$$-$RANDOM
41175   (umask 077 && mkdir $tmp)
41176 } ||
41177 {
41178    echo "$me: cannot create a temporary directory in ." >&2
41179    { (exit 1); exit 1; }
41180 }
41181
41182 _ACEOF
41183
41184 cat >>$CONFIG_STATUS <<_ACEOF
41185
41186 #
41187 # CONFIG_FILES section.
41188 #
41189
41190 # No need to generate the scripts if there are no CONFIG_FILES.
41191 # This happens for instance when ./config.status config.h
41192 if test -n "\$CONFIG_FILES"; then
41193   # Protect against being on the right side of a sed subst in config.status.
41194   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
41195    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
41196 s,@SHELL@,$SHELL,;t t
41197 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
41198 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
41199 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
41200 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
41201 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
41202 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
41203 s,@exec_prefix@,$exec_prefix,;t t
41204 s,@prefix@,$prefix,;t t
41205 s,@program_transform_name@,$program_transform_name,;t t
41206 s,@bindir@,$bindir,;t t
41207 s,@sbindir@,$sbindir,;t t
41208 s,@libexecdir@,$libexecdir,;t t
41209 s,@datadir@,$datadir,;t t
41210 s,@sysconfdir@,$sysconfdir,;t t
41211 s,@sharedstatedir@,$sharedstatedir,;t t
41212 s,@localstatedir@,$localstatedir,;t t
41213 s,@libdir@,$libdir,;t t
41214 s,@includedir@,$includedir,;t t
41215 s,@oldincludedir@,$oldincludedir,;t t
41216 s,@infodir@,$infodir,;t t
41217 s,@mandir@,$mandir,;t t
41218 s,@build_alias@,$build_alias,;t t
41219 s,@host_alias@,$host_alias,;t t
41220 s,@target_alias@,$target_alias,;t t
41221 s,@DEFS@,$DEFS,;t t
41222 s,@ECHO_C@,$ECHO_C,;t t
41223 s,@ECHO_N@,$ECHO_N,;t t
41224 s,@ECHO_T@,$ECHO_T,;t t
41225 s,@LIBS@,$LIBS,;t t
41226 s,@build@,$build,;t t
41227 s,@build_cpu@,$build_cpu,;t t
41228 s,@build_vendor@,$build_vendor,;t t
41229 s,@build_os@,$build_os,;t t
41230 s,@host@,$host,;t t
41231 s,@host_cpu@,$host_cpu,;t t
41232 s,@host_vendor@,$host_vendor,;t t
41233 s,@host_os@,$host_os,;t t
41234 s,@target@,$target,;t t
41235 s,@target_cpu@,$target_cpu,;t t
41236 s,@target_vendor@,$target_vendor,;t t
41237 s,@target_os@,$target_os,;t t
41238 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
41239 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
41240 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
41241 s,@CYGPATH_W@,$CYGPATH_W,;t t
41242 s,@PACKAGE@,$PACKAGE,;t t
41243 s,@VERSION@,$VERSION,;t t
41244 s,@ACLOCAL@,$ACLOCAL,;t t
41245 s,@AUTOCONF@,$AUTOCONF,;t t
41246 s,@AUTOMAKE@,$AUTOMAKE,;t t
41247 s,@AUTOHEADER@,$AUTOHEADER,;t t
41248 s,@MAKEINFO@,$MAKEINFO,;t t
41249 s,@install_sh@,$install_sh,;t t
41250 s,@STRIP@,$STRIP,;t t
41251 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
41252 s,@INSTALL_STRIP_PROGRAM@,$INSTALL_STRIP_PROGRAM,;t t
41253 s,@mkdir_p@,$mkdir_p,;t t
41254 s,@AWK@,$AWK,;t t
41255 s,@SET_MAKE@,$SET_MAKE,;t t
41256 s,@am__leading_dot@,$am__leading_dot,;t t
41257 s,@AMTAR@,$AMTAR,;t t
41258 s,@am__tar@,$am__tar,;t t
41259 s,@am__untar@,$am__untar,;t t
41260 s,@OPENLDAP_LIBRELEASE@,$OPENLDAP_LIBRELEASE,;t t
41261 s,@OPENLDAP_LIBVERSION@,$OPENLDAP_LIBVERSION,;t t
41262 s,@OPENLDAP_RELEASE_DATE@,$OPENLDAP_RELEASE_DATE,;t t
41263 s,@top_builddir@,$top_builddir,;t t
41264 s,@ldap_subdir@,$ldap_subdir,;t t
41265 s,@CC@,$CC,;t t
41266 s,@AR@,$AR,;t t
41267 s,@CFLAGS@,$CFLAGS,;t t
41268 s,@LDFLAGS@,$LDFLAGS,;t t
41269 s,@CPPFLAGS@,$CPPFLAGS,;t t
41270 s,@ac_ct_CC@,$ac_ct_CC,;t t
41271 s,@EXEEXT@,$EXEEXT,;t t
41272 s,@OBJEXT@,$OBJEXT,;t t
41273 s,@DEPDIR@,$DEPDIR,;t t
41274 s,@am__include@,$am__include,;t t
41275 s,@am__quote@,$am__quote,;t t
41276 s,@AMDEP_TRUE@,$AMDEP_TRUE,;t t
41277 s,@AMDEP_FALSE@,$AMDEP_FALSE,;t t
41278 s,@AMDEPBACKSLASH@,$AMDEPBACKSLASH,;t t
41279 s,@CCDEPMODE@,$CCDEPMODE,;t t
41280 s,@am__fastdepCC_TRUE@,$am__fastdepCC_TRUE,;t t
41281 s,@am__fastdepCC_FALSE@,$am__fastdepCC_FALSE,;t t
41282 s,@EGREP@,$EGREP,;t t
41283 s,@LN_S@,$LN_S,;t t
41284 s,@ECHO@,$ECHO,;t t
41285 s,@ac_ct_AR@,$ac_ct_AR,;t t
41286 s,@RANLIB@,$RANLIB,;t t
41287 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
41288 s,@DLLTOOL@,$DLLTOOL,;t t
41289 s,@ac_ct_DLLTOOL@,$ac_ct_DLLTOOL,;t t
41290 s,@AS@,$AS,;t t
41291 s,@ac_ct_AS@,$ac_ct_AS,;t t
41292 s,@OBJDUMP@,$OBJDUMP,;t t
41293 s,@ac_ct_OBJDUMP@,$ac_ct_OBJDUMP,;t t
41294 s,@CPP@,$CPP,;t t
41295 s,@LIBTOOL@,$LIBTOOL,;t t
41296 s,@PERLBIN@,$PERLBIN,;t t
41297 s,@OL_MKDEP@,$OL_MKDEP,;t t
41298 s,@OL_MKDEP_FLAGS@,$OL_MKDEP_FLAGS,;t t
41299 s,@LTSTATIC@,$LTSTATIC,;t t
41300 s,@LIBOBJS@,$LIBOBJS,;t t
41301 s,@LIBSRCS@,$LIBSRCS,;t t
41302 s,@PLAT@,$PLAT,;t t
41303 s,@WITH_SASL@,$WITH_SASL,;t t
41304 s,@WITH_TLS@,$WITH_TLS,;t t
41305 s,@WITH_MODULES_ENABLED@,$WITH_MODULES_ENABLED,;t t
41306 s,@WITH_ACI_ENABLED@,$WITH_ACI_ENABLED,;t t
41307 s,@BUILD_THREAD@,$BUILD_THREAD,;t t
41308 s,@BUILD_LIBS_DYNAMIC@,$BUILD_LIBS_DYNAMIC,;t t
41309 s,@BUILD_SLAPD@,$BUILD_SLAPD,;t t
41310 s,@BUILD_SLAPI@,$BUILD_SLAPI,;t t
41311 s,@SLAPD_SLAPI_DEPEND@,$SLAPD_SLAPI_DEPEND,;t t
41312 s,@BUILD_BDB@,$BUILD_BDB,;t t
41313 s,@BUILD_DNSSRV@,$BUILD_DNSSRV,;t t
41314 s,@BUILD_HDB@,$BUILD_HDB,;t t
41315 s,@BUILD_LDAP@,$BUILD_LDAP,;t t
41316 s,@BUILD_META@,$BUILD_META,;t t
41317 s,@BUILD_MONITOR@,$BUILD_MONITOR,;t t
41318 s,@BUILD_NULL@,$BUILD_NULL,;t t
41319 s,@BUILD_PASSWD@,$BUILD_PASSWD,;t t
41320 s,@BUILD_RELAY@,$BUILD_RELAY,;t t
41321 s,@BUILD_PERL@,$BUILD_PERL,;t t
41322 s,@BUILD_SHELL@,$BUILD_SHELL,;t t
41323 s,@BUILD_SQL@,$BUILD_SQL,;t t
41324 s,@BUILD_ACCESSLOG@,$BUILD_ACCESSLOG,;t t
41325 s,@BUILD_AUDITLOG@,$BUILD_AUDITLOG,;t t
41326 s,@BUILD_CONSTRAINT@,$BUILD_CONSTRAINT,;t t
41327 s,@BUILD_DDS@,$BUILD_DDS,;t t
41328 s,@BUILD_DENYOP@,$BUILD_DENYOP,;t t
41329 s,@BUILD_DYNGROUP@,$BUILD_DYNGROUP,;t t
41330 s,@BUILD_DYNLIST@,$BUILD_DYNLIST,;t t
41331 s,@BUILD_LASTMOD@,$BUILD_LASTMOD,;t t
41332 s,@BUILD_PPOLICY@,$BUILD_PPOLICY,;t t
41333 s,@BUILD_PROXYCACHE@,$BUILD_PROXYCACHE,;t t
41334 s,@BUILD_REFINT@,$BUILD_REFINT,;t t
41335 s,@BUILD_RETCODE@,$BUILD_RETCODE,;t t
41336 s,@BUILD_RWM@,$BUILD_RWM,;t t
41337 s,@BUILD_SEQMOD@,$BUILD_SEQMOD,;t t
41338 s,@BUILD_SYNCPROV@,$BUILD_SYNCPROV,;t t
41339 s,@BUILD_TRANSLUCENT@,$BUILD_TRANSLUCENT,;t t
41340 s,@BUILD_UNIQUE@,$BUILD_UNIQUE,;t t
41341 s,@BUILD_VALSORT@,$BUILD_VALSORT,;t t
41342 s,@BUILD_SLURPD@,$BUILD_SLURPD,;t t
41343 s,@LDAP_LIBS@,$LDAP_LIBS,;t t
41344 s,@SLAPD_LIBS@,$SLAPD_LIBS,;t t
41345 s,@SLURPD_LIBS@,$SLURPD_LIBS,;t t
41346 s,@BDB_LIBS@,$BDB_LIBS,;t t
41347 s,@LTHREAD_LIBS@,$LTHREAD_LIBS,;t t
41348 s,@LUTIL_LIBS@,$LUTIL_LIBS,;t t
41349 s,@WRAP_LIBS@,$WRAP_LIBS,;t t
41350 s,@SLAPD_MODULES_CPPFLAGS@,$SLAPD_MODULES_CPPFLAGS,;t t
41351 s,@SLAPD_MODULES_LDFLAGS@,$SLAPD_MODULES_LDFLAGS,;t t
41352 s,@SLAPD_NO_STATIC@,$SLAPD_NO_STATIC,;t t
41353 s,@SLAPD_STATIC_BACKENDS@,$SLAPD_STATIC_BACKENDS,;t t
41354 s,@SLAPD_DYNAMIC_BACKENDS@,$SLAPD_DYNAMIC_BACKENDS,;t t
41355 s,@SLAPD_STATIC_OVERLAYS@,$SLAPD_STATIC_OVERLAYS,;t t
41356 s,@SLAPD_DYNAMIC_OVERLAYS@,$SLAPD_DYNAMIC_OVERLAYS,;t t
41357 s,@PERL_CPPFLAGS@,$PERL_CPPFLAGS,;t t
41358 s,@SLAPD_PERL_LDFLAGS@,$SLAPD_PERL_LDFLAGS,;t t
41359 s,@MOD_PERL_LDFLAGS@,$MOD_PERL_LDFLAGS,;t t
41360 s,@KRB4_LIBS@,$KRB4_LIBS,;t t
41361 s,@KRB5_LIBS@,$KRB5_LIBS,;t t
41362 s,@SASL_LIBS@,$SASL_LIBS,;t t
41363 s,@TLS_LIBS@,$TLS_LIBS,;t t
41364 s,@MODULES_LIBS@,$MODULES_LIBS,;t t
41365 s,@SLAPI_LIBS@,$SLAPI_LIBS,;t t
41366 s,@LIBSLAPI@,$LIBSLAPI,;t t
41367 s,@LIBSLAPITOOLS@,$LIBSLAPITOOLS,;t t
41368 s,@AUTH_LIBS@,$AUTH_LIBS,;t t
41369 s,@ICU_LIBS@,$ICU_LIBS,;t t
41370 s,@SLAPD_SLP_LIBS@,$SLAPD_SLP_LIBS,;t t
41371 s,@SLAPD_GMP_LIBS@,$SLAPD_GMP_LIBS,;t t
41372 s,@SLAPD_SQL_LDFLAGS@,$SLAPD_SQL_LDFLAGS,;t t
41373 s,@SLAPD_SQL_LIBS@,$SLAPD_SQL_LIBS,;t t
41374 s,@SLAPD_SQL_INCLUDES@,$SLAPD_SQL_INCLUDES,;t t
41375 s,@LTLIBOBJS@,$LTLIBOBJS,;t t
41376 CEOF
41377
41378 _ACEOF
41379
41380   cat >>$CONFIG_STATUS <<\_ACEOF
41381   # Split the substitutions into bite-sized pieces for seds with
41382   # small command number limits, like on Digital OSF/1 and HP-UX.
41383   ac_max_sed_lines=48
41384   ac_sed_frag=1 # Number of current file.
41385   ac_beg=1 # First line for current file.
41386   ac_end=$ac_max_sed_lines # Line after last line for current file.
41387   ac_more_lines=:
41388   ac_sed_cmds=
41389   while $ac_more_lines; do
41390     if test $ac_beg -gt 1; then
41391       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
41392     else
41393       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
41394     fi
41395     if test ! -s $tmp/subs.frag; then
41396       ac_more_lines=false
41397     else
41398       # The purpose of the label and of the branching condition is to
41399       # speed up the sed processing (if there are no `@' at all, there
41400       # is no need to browse any of the substitutions).
41401       # These are the two extra sed commands mentioned above.
41402       (echo ':t
41403   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
41404       if test -z "$ac_sed_cmds"; then
41405         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
41406       else
41407         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
41408       fi
41409       ac_sed_frag=`expr $ac_sed_frag + 1`
41410       ac_beg=$ac_end
41411       ac_end=`expr $ac_end + $ac_max_sed_lines`
41412     fi
41413   done
41414   if test -z "$ac_sed_cmds"; then
41415     ac_sed_cmds=cat
41416   fi
41417 fi # test -n "$CONFIG_FILES"
41418
41419 _ACEOF
41420 cat >>$CONFIG_STATUS <<\_ACEOF
41421 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
41422   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
41423   case $ac_file in
41424   - | *:- | *:-:* ) # input from stdin
41425         cat >$tmp/stdin
41426         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
41427         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
41428   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
41429         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
41430   * )   ac_file_in=$ac_file.in ;;
41431   esac
41432
41433   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
41434   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
41435 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
41436          X"$ac_file" : 'X\(//\)[^/]' \| \
41437          X"$ac_file" : 'X\(//\)$' \| \
41438          X"$ac_file" : 'X\(/\)' \| \
41439          .     : '\(.\)' 2>/dev/null ||
41440 echo X"$ac_file" |
41441     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
41442           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
41443           /^X\(\/\/\)$/{ s//\1/; q; }
41444           /^X\(\/\).*/{ s//\1/; q; }
41445           s/.*/./; q'`
41446   { if $as_mkdir_p; then
41447     mkdir -p "$ac_dir"
41448   else
41449     as_dir="$ac_dir"
41450     as_dirs=
41451     while test ! -d "$as_dir"; do
41452       as_dirs="$as_dir $as_dirs"
41453       as_dir=`(dirname "$as_dir") 2>/dev/null ||
41454 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
41455          X"$as_dir" : 'X\(//\)[^/]' \| \
41456          X"$as_dir" : 'X\(//\)$' \| \
41457          X"$as_dir" : 'X\(/\)' \| \
41458          .     : '\(.\)' 2>/dev/null ||
41459 echo X"$as_dir" |
41460     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
41461           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
41462           /^X\(\/\/\)$/{ s//\1/; q; }
41463           /^X\(\/\).*/{ s//\1/; q; }
41464           s/.*/./; q'`
41465     done
41466     test ! -n "$as_dirs" || mkdir $as_dirs
41467   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
41468 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
41469    { (exit 1); exit 1; }; }; }
41470
41471   ac_builddir=.
41472
41473 if test "$ac_dir" != .; then
41474   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
41475   # A "../" for each directory in $ac_dir_suffix.
41476   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
41477 else
41478   ac_dir_suffix= ac_top_builddir=
41479 fi
41480
41481 case $srcdir in
41482   .)  # No --srcdir option.  We are building in place.
41483     ac_srcdir=.
41484     if test -z "$ac_top_builddir"; then
41485        ac_top_srcdir=.
41486     else
41487        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
41488     fi ;;
41489   [\\/]* | ?:[\\/]* )  # Absolute path.
41490     ac_srcdir=$srcdir$ac_dir_suffix;
41491     ac_top_srcdir=$srcdir ;;
41492   *) # Relative path.
41493     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
41494     ac_top_srcdir=$ac_top_builddir$srcdir ;;
41495 esac
41496
41497 # Do not use `cd foo && pwd` to compute absolute paths, because
41498 # the directories may not exist.
41499 case `pwd` in
41500 .) ac_abs_builddir="$ac_dir";;
41501 *)
41502   case "$ac_dir" in
41503   .) ac_abs_builddir=`pwd`;;
41504   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
41505   *) ac_abs_builddir=`pwd`/"$ac_dir";;
41506   esac;;
41507 esac
41508 case $ac_abs_builddir in
41509 .) ac_abs_top_builddir=${ac_top_builddir}.;;
41510 *)
41511   case ${ac_top_builddir}. in
41512   .) ac_abs_top_builddir=$ac_abs_builddir;;
41513   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
41514   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
41515   esac;;
41516 esac
41517 case $ac_abs_builddir in
41518 .) ac_abs_srcdir=$ac_srcdir;;
41519 *)
41520   case $ac_srcdir in
41521   .) ac_abs_srcdir=$ac_abs_builddir;;
41522   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
41523   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
41524   esac;;
41525 esac
41526 case $ac_abs_builddir in
41527 .) ac_abs_top_srcdir=$ac_top_srcdir;;
41528 *)
41529   case $ac_top_srcdir in
41530   .) ac_abs_top_srcdir=$ac_abs_builddir;;
41531   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
41532   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
41533   esac;;
41534 esac
41535
41536
41537   case $INSTALL in
41538   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
41539   *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
41540   esac
41541
41542   if test x"$ac_file" != x-; then
41543     { echo "$as_me:$LINENO: creating $ac_file" >&5
41544 echo "$as_me: creating $ac_file" >&6;}
41545     rm -f "$ac_file"
41546   fi
41547   # Let's still pretend it is `configure' which instantiates (i.e., don't
41548   # use $as_me), people would be surprised to read:
41549   #    /* config.h.  Generated by config.status.  */
41550   if test x"$ac_file" = x-; then
41551     configure_input=
41552   else
41553     configure_input="$ac_file.  "
41554   fi
41555   configure_input=$configure_input"Generated from `echo $ac_file_in |
41556                                      sed 's,.*/,,'` by configure."
41557
41558   # First look for the input files in the build tree, otherwise in the
41559   # src tree.
41560   ac_file_inputs=`IFS=:
41561     for f in $ac_file_in; do
41562       case $f in
41563       -) echo $tmp/stdin ;;
41564       [\\/$]*)
41565          # Absolute (can't be DOS-style, as IFS=:)
41566          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
41567 echo "$as_me: error: cannot find input file: $f" >&2;}
41568    { (exit 1); exit 1; }; }
41569          echo "$f";;
41570       *) # Relative
41571          if test -f "$f"; then
41572            # Build tree
41573            echo "$f"
41574          elif test -f "$srcdir/$f"; then
41575            # Source tree
41576            echo "$srcdir/$f"
41577          else
41578            # /dev/null tree
41579            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
41580 echo "$as_me: error: cannot find input file: $f" >&2;}
41581    { (exit 1); exit 1; }; }
41582          fi;;
41583       esac
41584     done` || { (exit 1); exit 1; }
41585 _ACEOF
41586 cat >>$CONFIG_STATUS <<_ACEOF
41587   sed "$ac_vpsub
41588 $extrasub
41589 _ACEOF
41590 cat >>$CONFIG_STATUS <<\_ACEOF
41591 :t
41592 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
41593 s,@configure_input@,$configure_input,;t t
41594 s,@srcdir@,$ac_srcdir,;t t
41595 s,@abs_srcdir@,$ac_abs_srcdir,;t t
41596 s,@top_srcdir@,$ac_top_srcdir,;t t
41597 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
41598 s,@builddir@,$ac_builddir,;t t
41599 s,@abs_builddir@,$ac_abs_builddir,;t t
41600 s,@top_builddir@,$ac_top_builddir,;t t
41601 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
41602 s,@INSTALL@,$ac_INSTALL,;t t
41603 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
41604   rm -f $tmp/stdin
41605   if test x"$ac_file" != x-; then
41606     mv $tmp/out $ac_file
41607   else
41608     cat $tmp/out
41609     rm -f $tmp/out
41610   fi
41611
41612 done
41613 _ACEOF
41614 cat >>$CONFIG_STATUS <<\_ACEOF
41615
41616 #
41617 # CONFIG_HEADER section.
41618 #
41619
41620 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
41621 # NAME is the cpp macro being defined and VALUE is the value it is being given.
41622 #
41623 # ac_d sets the value in "#define NAME VALUE" lines.
41624 ac_dA='s,^\([    ]*\)#\([        ]*define[       ][      ]*\)'
41625 ac_dB='[         ].*$,\1#\2'
41626 ac_dC=' '
41627 ac_dD=',;t'
41628 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
41629 ac_uA='s,^\([    ]*\)#\([        ]*\)undef\([    ][      ]*\)'
41630 ac_uB='$,\1#\2define\3'
41631 ac_uC=' '
41632 ac_uD=',;t'
41633
41634 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
41635   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
41636   case $ac_file in
41637   - | *:- | *:-:* ) # input from stdin
41638         cat >$tmp/stdin
41639         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
41640         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
41641   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
41642         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
41643   * )   ac_file_in=$ac_file.in ;;
41644   esac
41645
41646   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
41647 echo "$as_me: creating $ac_file" >&6;}
41648
41649   # First look for the input files in the build tree, otherwise in the
41650   # src tree.
41651   ac_file_inputs=`IFS=:
41652     for f in $ac_file_in; do
41653       case $f in
41654       -) echo $tmp/stdin ;;
41655       [\\/$]*)
41656          # Absolute (can't be DOS-style, as IFS=:)
41657          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
41658 echo "$as_me: error: cannot find input file: $f" >&2;}
41659    { (exit 1); exit 1; }; }
41660          # Do quote $f, to prevent DOS paths from being IFS'd.
41661          echo "$f";;
41662       *) # Relative
41663          if test -f "$f"; then
41664            # Build tree
41665            echo "$f"
41666          elif test -f "$srcdir/$f"; then
41667            # Source tree
41668            echo "$srcdir/$f"
41669          else
41670            # /dev/null tree
41671            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
41672 echo "$as_me: error: cannot find input file: $f" >&2;}
41673    { (exit 1); exit 1; }; }
41674          fi;;
41675       esac
41676     done` || { (exit 1); exit 1; }
41677   # Remove the trailing spaces.
41678   sed 's/[       ]*$//' $ac_file_inputs >$tmp/in
41679
41680 _ACEOF
41681
41682 # Transform confdefs.h into two sed scripts, `conftest.defines' and
41683 # `conftest.undefs', that substitutes the proper values into
41684 # config.h.in to produce config.h.  The first handles `#define'
41685 # templates, and the second `#undef' templates.
41686 # And first: Protect against being on the right side of a sed subst in
41687 # config.status.  Protect against being in an unquoted here document
41688 # in config.status.
41689 rm -f conftest.defines conftest.undefs
41690 # Using a here document instead of a string reduces the quoting nightmare.
41691 # Putting comments in sed scripts is not portable.
41692 #
41693 # `end' is used to avoid that the second main sed command (meant for
41694 # 0-ary CPP macros) applies to n-ary macro definitions.
41695 # See the Autoconf documentation for `clear'.
41696 cat >confdef2sed.sed <<\_ACEOF
41697 s/[\\&,]/\\&/g
41698 s,[\\$`],\\&,g
41699 t clear
41700 : clear
41701 s,^[     ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
41702 t end
41703 s,^[     ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
41704 : end
41705 _ACEOF
41706 # If some macros were called several times there might be several times
41707 # the same #defines, which is useless.  Nevertheless, we may not want to
41708 # sort them, since we want the *last* AC-DEFINE to be honored.
41709 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
41710 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
41711 rm -f confdef2sed.sed
41712
41713 # This sed command replaces #undef with comments.  This is necessary, for
41714 # example, in the case of _POSIX_SOURCE, which is predefined and required
41715 # on some systems where configure will not decide to define it.
41716 cat >>conftest.undefs <<\_ACEOF
41717 s,^[     ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
41718 _ACEOF
41719
41720 # Break up conftest.defines because some shells have a limit on the size
41721 # of here documents, and old seds have small limits too (100 cmds).
41722 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
41723 echo '  if grep "^[      ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
41724 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
41725 echo '  :' >>$CONFIG_STATUS
41726 rm -f conftest.tail
41727 while grep . conftest.defines >/dev/null
41728 do
41729   # Write a limited-size here document to $tmp/defines.sed.
41730   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
41731   # Speed up: don't consider the non `#define' lines.
41732   echo '/^[      ]*#[    ]*define/!b' >>$CONFIG_STATUS
41733   # Work around the forget-to-reset-the-flag bug.
41734   echo 't clr' >>$CONFIG_STATUS
41735   echo ': clr' >>$CONFIG_STATUS
41736   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
41737   echo 'CEOF
41738   sed -f $tmp/defines.sed $tmp/in >$tmp/out
41739   rm -f $tmp/in
41740   mv $tmp/out $tmp/in
41741 ' >>$CONFIG_STATUS
41742   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
41743   rm -f conftest.defines
41744   mv conftest.tail conftest.defines
41745 done
41746 rm -f conftest.defines
41747 echo '  fi # grep' >>$CONFIG_STATUS
41748 echo >>$CONFIG_STATUS
41749
41750 # Break up conftest.undefs because some shells have a limit on the size
41751 # of here documents, and old seds have small limits too (100 cmds).
41752 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
41753 rm -f conftest.tail
41754 while grep . conftest.undefs >/dev/null
41755 do
41756   # Write a limited-size here document to $tmp/undefs.sed.
41757   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
41758   # Speed up: don't consider the non `#undef'
41759   echo '/^[      ]*#[    ]*undef/!b' >>$CONFIG_STATUS
41760   # Work around the forget-to-reset-the-flag bug.
41761   echo 't clr' >>$CONFIG_STATUS
41762   echo ': clr' >>$CONFIG_STATUS
41763   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
41764   echo 'CEOF
41765   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
41766   rm -f $tmp/in
41767   mv $tmp/out $tmp/in
41768 ' >>$CONFIG_STATUS
41769   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
41770   rm -f conftest.undefs
41771   mv conftest.tail conftest.undefs
41772 done
41773 rm -f conftest.undefs
41774
41775 cat >>$CONFIG_STATUS <<\_ACEOF
41776   # Let's still pretend it is `configure' which instantiates (i.e., don't
41777   # use $as_me), people would be surprised to read:
41778   #    /* config.h.  Generated by config.status.  */
41779   if test x"$ac_file" = x-; then
41780     echo "/* Generated by configure.  */" >$tmp/config.h
41781   else
41782     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
41783   fi
41784   cat $tmp/in >>$tmp/config.h
41785   rm -f $tmp/in
41786   if test x"$ac_file" != x-; then
41787     if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
41788       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
41789 echo "$as_me: $ac_file is unchanged" >&6;}
41790     else
41791       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
41792 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
41793          X"$ac_file" : 'X\(//\)[^/]' \| \
41794          X"$ac_file" : 'X\(//\)$' \| \
41795          X"$ac_file" : 'X\(/\)' \| \
41796          .     : '\(.\)' 2>/dev/null ||
41797 echo X"$ac_file" |
41798     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
41799           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
41800           /^X\(\/\/\)$/{ s//\1/; q; }
41801           /^X\(\/\).*/{ s//\1/; q; }
41802           s/.*/./; q'`
41803       { if $as_mkdir_p; then
41804     mkdir -p "$ac_dir"
41805   else
41806     as_dir="$ac_dir"
41807     as_dirs=
41808     while test ! -d "$as_dir"; do
41809       as_dirs="$as_dir $as_dirs"
41810       as_dir=`(dirname "$as_dir") 2>/dev/null ||
41811 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
41812          X"$as_dir" : 'X\(//\)[^/]' \| \
41813          X"$as_dir" : 'X\(//\)$' \| \
41814          X"$as_dir" : 'X\(/\)' \| \
41815          .     : '\(.\)' 2>/dev/null ||
41816 echo X"$as_dir" |
41817     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
41818           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
41819           /^X\(\/\/\)$/{ s//\1/; q; }
41820           /^X\(\/\).*/{ s//\1/; q; }
41821           s/.*/./; q'`
41822     done
41823     test ! -n "$as_dirs" || mkdir $as_dirs
41824   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
41825 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
41826    { (exit 1); exit 1; }; }; }
41827
41828       rm -f $ac_file
41829       mv $tmp/config.h $ac_file
41830     fi
41831   else
41832     cat $tmp/config.h
41833     rm -f $tmp/config.h
41834   fi
41835 # Compute $ac_file's index in $config_headers.
41836 _am_stamp_count=1
41837 for _am_header in $config_headers :; do
41838   case $_am_header in
41839     $ac_file | $ac_file:* )
41840       break ;;
41841     * )
41842       _am_stamp_count=`expr $_am_stamp_count + 1` ;;
41843   esac
41844 done
41845 echo "timestamp for $ac_file" >`(dirname $ac_file) 2>/dev/null ||
41846 $as_expr X$ac_file : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
41847          X$ac_file : 'X\(//\)[^/]' \| \
41848          X$ac_file : 'X\(//\)$' \| \
41849          X$ac_file : 'X\(/\)' \| \
41850          .     : '\(.\)' 2>/dev/null ||
41851 echo X$ac_file |
41852     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
41853           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
41854           /^X\(\/\/\)$/{ s//\1/; q; }
41855           /^X\(\/\).*/{ s//\1/; q; }
41856           s/.*/./; q'`/stamp-h$_am_stamp_count
41857 done
41858 _ACEOF
41859 cat >>$CONFIG_STATUS <<\_ACEOF
41860
41861 #
41862 # CONFIG_COMMANDS section.
41863 #
41864 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
41865   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
41866   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
41867   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
41868 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
41869          X"$ac_dest" : 'X\(//\)[^/]' \| \
41870          X"$ac_dest" : 'X\(//\)$' \| \
41871          X"$ac_dest" : 'X\(/\)' \| \
41872          .     : '\(.\)' 2>/dev/null ||
41873 echo X"$ac_dest" |
41874     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
41875           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
41876           /^X\(\/\/\)$/{ s//\1/; q; }
41877           /^X\(\/\).*/{ s//\1/; q; }
41878           s/.*/./; q'`
41879   { if $as_mkdir_p; then
41880     mkdir -p "$ac_dir"
41881   else
41882     as_dir="$ac_dir"
41883     as_dirs=
41884     while test ! -d "$as_dir"; do
41885       as_dirs="$as_dir $as_dirs"
41886       as_dir=`(dirname "$as_dir") 2>/dev/null ||
41887 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
41888          X"$as_dir" : 'X\(//\)[^/]' \| \
41889          X"$as_dir" : 'X\(//\)$' \| \
41890          X"$as_dir" : 'X\(/\)' \| \
41891          .     : '\(.\)' 2>/dev/null ||
41892 echo X"$as_dir" |
41893     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
41894           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
41895           /^X\(\/\/\)$/{ s//\1/; q; }
41896           /^X\(\/\).*/{ s//\1/; q; }
41897           s/.*/./; q'`
41898     done
41899     test ! -n "$as_dirs" || mkdir $as_dirs
41900   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
41901 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
41902    { (exit 1); exit 1; }; }; }
41903
41904   ac_builddir=.
41905
41906 if test "$ac_dir" != .; then
41907   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
41908   # A "../" for each directory in $ac_dir_suffix.
41909   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
41910 else
41911   ac_dir_suffix= ac_top_builddir=
41912 fi
41913
41914 case $srcdir in
41915   .)  # No --srcdir option.  We are building in place.
41916     ac_srcdir=.
41917     if test -z "$ac_top_builddir"; then
41918        ac_top_srcdir=.
41919     else
41920        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
41921     fi ;;
41922   [\\/]* | ?:[\\/]* )  # Absolute path.
41923     ac_srcdir=$srcdir$ac_dir_suffix;
41924     ac_top_srcdir=$srcdir ;;
41925   *) # Relative path.
41926     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
41927     ac_top_srcdir=$ac_top_builddir$srcdir ;;
41928 esac
41929
41930 # Do not use `cd foo && pwd` to compute absolute paths, because
41931 # the directories may not exist.
41932 case `pwd` in
41933 .) ac_abs_builddir="$ac_dir";;
41934 *)
41935   case "$ac_dir" in
41936   .) ac_abs_builddir=`pwd`;;
41937   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
41938   *) ac_abs_builddir=`pwd`/"$ac_dir";;
41939   esac;;
41940 esac
41941 case $ac_abs_builddir in
41942 .) ac_abs_top_builddir=${ac_top_builddir}.;;
41943 *)
41944   case ${ac_top_builddir}. in
41945   .) ac_abs_top_builddir=$ac_abs_builddir;;
41946   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
41947   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
41948   esac;;
41949 esac
41950 case $ac_abs_builddir in
41951 .) ac_abs_srcdir=$ac_srcdir;;
41952 *)
41953   case $ac_srcdir in
41954   .) ac_abs_srcdir=$ac_abs_builddir;;
41955   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
41956   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
41957   esac;;
41958 esac
41959 case $ac_abs_builddir in
41960 .) ac_abs_top_srcdir=$ac_top_srcdir;;
41961 *)
41962   case $ac_top_srcdir in
41963   .) ac_abs_top_srcdir=$ac_abs_builddir;;
41964   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
41965   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
41966   esac;;
41967 esac
41968
41969
41970   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
41971 echo "$as_me: executing $ac_dest commands" >&6;}
41972   case $ac_dest in
41973     depfiles ) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do
41974   # Strip MF so we end up with the name of the file.
41975   mf=`echo "$mf" | sed -e 's/:.*$//'`
41976   # Check whether this is an Automake generated Makefile or not.
41977   # We used to match only the files named `Makefile.in', but
41978   # some people rename them; so instead we look at the file content.
41979   # Grep'ing the first line is not enough: some people post-process
41980   # each Makefile.in and add a new line on top of each file to say so.
41981   # So let's grep whole file.
41982   if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
41983     dirpart=`(dirname "$mf") 2>/dev/null ||
41984 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
41985          X"$mf" : 'X\(//\)[^/]' \| \
41986          X"$mf" : 'X\(//\)$' \| \
41987          X"$mf" : 'X\(/\)' \| \
41988          .     : '\(.\)' 2>/dev/null ||
41989 echo X"$mf" |
41990     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
41991           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
41992           /^X\(\/\/\)$/{ s//\1/; q; }
41993           /^X\(\/\).*/{ s//\1/; q; }
41994           s/.*/./; q'`
41995   else
41996     continue
41997   fi
41998   # Extract the definition of DEPDIR, am__include, and am__quote
41999   # from the Makefile without running `make'.
42000   DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
42001   test -z "$DEPDIR" && continue
42002   am__include=`sed -n 's/^am__include = //p' < "$mf"`
42003   test -z "am__include" && continue
42004   am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
42005   # When using ansi2knr, U may be empty or an underscore; expand it
42006   U=`sed -n 's/^U = //p' < "$mf"`
42007   # Find all dependency output files, they are included files with
42008   # $(DEPDIR) in their names.  We invoke sed twice because it is the
42009   # simplest approach to changing $(DEPDIR) to its actual value in the
42010   # expansion.
42011   for file in `sed -n "
42012     s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
42013        sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
42014     # Make sure the directory exists.
42015     test -f "$dirpart/$file" && continue
42016     fdir=`(dirname "$file") 2>/dev/null ||
42017 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42018          X"$file" : 'X\(//\)[^/]' \| \
42019          X"$file" : 'X\(//\)$' \| \
42020          X"$file" : 'X\(/\)' \| \
42021          .     : '\(.\)' 2>/dev/null ||
42022 echo X"$file" |
42023     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42024           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42025           /^X\(\/\/\)$/{ s//\1/; q; }
42026           /^X\(\/\).*/{ s//\1/; q; }
42027           s/.*/./; q'`
42028     { if $as_mkdir_p; then
42029     mkdir -p $dirpart/$fdir
42030   else
42031     as_dir=$dirpart/$fdir
42032     as_dirs=
42033     while test ! -d "$as_dir"; do
42034       as_dirs="$as_dir $as_dirs"
42035       as_dir=`(dirname "$as_dir") 2>/dev/null ||
42036 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42037          X"$as_dir" : 'X\(//\)[^/]' \| \
42038          X"$as_dir" : 'X\(//\)$' \| \
42039          X"$as_dir" : 'X\(/\)' \| \
42040          .     : '\(.\)' 2>/dev/null ||
42041 echo X"$as_dir" |
42042     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42043           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42044           /^X\(\/\/\)$/{ s//\1/; q; }
42045           /^X\(\/\).*/{ s//\1/; q; }
42046           s/.*/./; q'`
42047     done
42048     test ! -n "$as_dirs" || mkdir $as_dirs
42049   fi || { { echo "$as_me:$LINENO: error: cannot create directory $dirpart/$fdir" >&5
42050 echo "$as_me: error: cannot create directory $dirpart/$fdir" >&2;}
42051    { (exit 1); exit 1; }; }; }
42052
42053     # echo "creating $dirpart/$file"
42054     echo '# dummy' > "$dirpart/$file"
42055   done
42056 done
42057  ;;
42058     default )
42059 chmod +x tests/run
42060 date > stamp-h
42061 BACKENDSC="servers/slapd/backends.c"
42062 echo "Making $BACKENDSC"
42063 rm -f $BACKENDSC
42064 cat > $BACKENDSC << ENDX
42065 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
42066  *
42067  * Copyright 1998-2006 The OpenLDAP Foundation.
42068  * All rights reserved.
42069  *
42070  * Redistribution and use in source and binary forms, with or without
42071  * modification, are permitted only as authorized by the OpenLDAP
42072  * Public License.
42073  *
42074  * A copy of this license is available in the file LICENSE in the
42075  * top-level directory of the distribution or, alternatively, at
42076  * <http://www.OpenLDAP.org/license.html>.
42077  */
42078 /* This file is automatically generated by configure; please do not edit. */
42079
42080 #include "portable.h"
42081 #include "slap.h"
42082
42083 ENDX
42084 if test "${STATIC_BACKENDS}"; then
42085         for b in config ${STATIC_BACKENDS}; do
42086                 bb=`echo "${b}" | sed -e 's/back-//'`
42087                 cat >> $BACKENDSC << ENDX
42088 extern BI_init ${bb}_back_initialize;
42089 ENDX
42090         done
42091
42092         cat >> $BACKENDSC << ENDX
42093
42094 BackendInfo slap_binfo[] = {
42095 ENDX
42096
42097         for b in config ${STATIC_BACKENDS}; do
42098                 bb=`echo "${b}" | sed -e 's/back-//'`
42099                 echo "    Add ${bb} ..."
42100                 cat >> $BACKENDSC << ENDX
42101         { "${bb}", ${bb}_back_initialize },
42102 ENDX
42103         done
42104
42105         cat >> $BACKENDSC << ENDX
42106         { NULL, NULL },
42107 };
42108
42109 /* end of generated file */
42110 ENDX
42111 fi
42112 OVERLAYSC="servers/slapd/overlays/statover.c"
42113 echo "Making $OVERLAYSC"
42114 rm -f $OVERLAYSC
42115 cat > $OVERLAYSC << ENDX
42116 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
42117  *
42118  * Copyright 1998-2006 The OpenLDAP Foundation.
42119  * All rights reserved.
42120  *
42121  * Redistribution and use in source and binary forms, with or without
42122  * modification, are permitted only as authorized by the OpenLDAP
42123  * Public License.
42124  *
42125  * A copy of this license is available in the file LICENSE in the
42126  * top-level directory of the distribution or, alternatively, at
42127  * <http://www.OpenLDAP.org/license.html>.
42128  */
42129 /* This file is automatically generated by configure; please do not edit. */
42130
42131 #include "portable.h"
42132 #include "slap.h"
42133
42134 ENDX
42135 if test "${STATIC_OVERLAYS}"; then
42136         for o in ${STATIC_OVERLAYS}; do
42137                 oo=`echo "${o}" | sed -e 's/.o$//' -e 's/_x$//'`
42138                 cat >> $OVERLAYSC << ENDX
42139 extern OV_init ${oo}_initialize;
42140 ENDX
42141         done
42142 fi
42143
42144 cat >> $OVERLAYSC << ENDX
42145
42146 OverlayInit slap_oinfo[] = {
42147 ENDX
42148
42149 if test "${STATIC_OVERLAYS}"; then
42150         for o in ${STATIC_OVERLAYS}; do
42151                 oo=`echo "${o}" | sed -e 's/.o$//' -e 's/_x$//'`
42152                 echo "    Add ${oo} ..."
42153                 cat >> $OVERLAYSC << ENDX
42154         { "${oo}", ${oo}_initialize },
42155 ENDX
42156         done
42157 fi
42158
42159         cat >> $OVERLAYSC << ENDX
42160         { NULL, NULL },
42161 };
42162
42163 /* end of generated file */
42164 ENDX
42165
42166 echo Please run \"make depend\" to build dependencies
42167  ;;
42168   esac
42169 done
42170 _ACEOF
42171
42172 cat >>$CONFIG_STATUS <<\_ACEOF
42173
42174 { (exit 0); exit 0; }
42175 _ACEOF
42176 chmod +x $CONFIG_STATUS
42177 ac_clean_files=$ac_clean_files_save
42178
42179
42180 # configure is writing to config.log, and then calls config.status.
42181 # config.status does its own redirection, appending to config.log.
42182 # Unfortunately, on DOS this fails, as config.log is still kept open
42183 # by configure, so config.status won't be able to write to it; its
42184 # output is simply discarded.  So we exec the FD to /dev/null,
42185 # effectively closing config.log, so it can be properly (re)opened and
42186 # appended to by config.status.  When coming back to configure, we
42187 # need to make the FD available again.
42188 if test "$no_create" != yes; then
42189   ac_cs_success=:
42190   ac_config_status_args=
42191   test "$silent" = yes &&
42192     ac_config_status_args="$ac_config_status_args --quiet"
42193   exec 5>/dev/null
42194   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
42195   exec 5>>config.log
42196   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
42197   # would make configure fail if this is the last instruction.
42198   $ac_cs_success || { (exit 1); exit 1; }
42199 fi
42200