]> git.sur5r.net Git - openldap/blob - configure
More for ITS#5212 make conditional explicit
[openldap] / configure
1 #! /bin/sh
2 # From configure.in OpenLDAP: pkg/ldap/configure.in,v 1.631.2.7 2007/10/16 23:43:09 quanah Exp .
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated by GNU Autoconf 2.59.
5 #
6 # Copyright 1998-2007 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_MEMBEROF BUILD_PPOLICY BUILD_PROXYCACHE BUILD_REFINT BUILD_RETCODE BUILD_RWM BUILD_SEQMOD BUILD_SYNCPROV BUILD_TRANSLUCENT BUILD_UNIQUE BUILD_VALSORT LDAP_LIBS SLAPD_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-dyngroup     Dynamic Group overlay no|yes|mod [no]
1053     --enable-dynlist      Dynamic List overlay no|yes|mod [no]
1054     --enable-memberof     Reverse Group Membership overlay no|yes|mod [no]
1055     --enable-ppolicy      Password Policy overlay no|yes|mod [no]
1056     --enable-proxycache   Proxy Cache overlay no|yes|mod [no]
1057     --enable-refint       Referential Integrity overlay no|yes|mod [no]
1058     --enable-retcode      Return Code testing overlay no|yes|mod [no]
1059     --enable-rwm          Rewrite/Remap overlay no|yes|mod [no]
1060     --enable-seqmod       Sequential Modify overlay no|yes|mod [yes]
1061     --enable-syncprov     Syncrepl Provider overlay no|yes|mod [yes]
1062     --enable-translucent  Translucent Proxy overlay no|yes|mod [no]
1063     --enable-unique       Attribute Uniqueness overlay no|yes|mod [no]
1064     --enable-valsort      Value Sorting overlay no|yes|mod [no]
1065
1066 Library Generation & Linking Options
1067   --enable-static[=PKGS]
1068                           build static libraries [default=yes]
1069   --enable-shared[=PKGS]
1070                           build shared libraries [default=yes]
1071   --enable-fast-install[=PKGS]
1072                           optimize for fast installation [default=yes]
1073   --disable-dependency-tracking  speeds up one-time build
1074   --enable-dependency-tracking   do not reject slow dependency extractors
1075   --disable-libtool-lock  avoid locking (might break parallel builds)
1076
1077 Optional Packages:
1078   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1079   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1080   --with-subdir=DIR       change default subdirectory used for installs
1081   --with-cyrus-sasl       with Cyrus SASL support [auto]
1082   --with-fetch            with fetch(3) URL support [auto]
1083   --with-threads          with threads [auto]
1084   --with-tls              with TLS/SSL support auto|openssl|gnutls [auto]
1085   --with-yielding-select  with implicitly yielding select [auto]
1086   --with-mp               with multiple precision statistics auto|longlong|long|bignum|gmp [auto]
1087   --with-odbc             with specific ODBC support iodbc|unixodbc|auto [auto]
1088   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1089   --with-pic              try to use only PIC/non-PIC objects [default=use
1090                           both]
1091   --with-tags[=TAGS]
1092                           include additional configurations [automatic]
1093
1094 See INSTALL file for further details.
1095
1096 Some influential environment variables:
1097   CC          C compiler command
1098   CFLAGS      C compiler flags
1099   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1100               nonstandard directory <lib dir>
1101   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
1102               headers in a nonstandard directory <include dir>
1103   CPP         C preprocessor
1104
1105 Use these variables to override the choices made by `configure' or to help
1106 it to find libraries and programs with nonstandard names/locations.
1107
1108 _ACEOF
1109 fi
1110
1111 if test "$ac_init_help" = "recursive"; then
1112   # If there are subdirs, report their specific --help.
1113   ac_popdir=`pwd`
1114   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1115     test -d $ac_dir || continue
1116     ac_builddir=.
1117
1118 if test "$ac_dir" != .; then
1119   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
1120   # A "../" for each directory in $ac_dir_suffix.
1121   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
1122 else
1123   ac_dir_suffix= ac_top_builddir=
1124 fi
1125
1126 case $srcdir in
1127   .)  # No --srcdir option.  We are building in place.
1128     ac_srcdir=.
1129     if test -z "$ac_top_builddir"; then
1130        ac_top_srcdir=.
1131     else
1132        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
1133     fi ;;
1134   [\\/]* | ?:[\\/]* )  # Absolute path.
1135     ac_srcdir=$srcdir$ac_dir_suffix;
1136     ac_top_srcdir=$srcdir ;;
1137   *) # Relative path.
1138     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
1139     ac_top_srcdir=$ac_top_builddir$srcdir ;;
1140 esac
1141
1142 # Do not use `cd foo && pwd` to compute absolute paths, because
1143 # the directories may not exist.
1144 case `pwd` in
1145 .) ac_abs_builddir="$ac_dir";;
1146 *)
1147   case "$ac_dir" in
1148   .) ac_abs_builddir=`pwd`;;
1149   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
1150   *) ac_abs_builddir=`pwd`/"$ac_dir";;
1151   esac;;
1152 esac
1153 case $ac_abs_builddir in
1154 .) ac_abs_top_builddir=${ac_top_builddir}.;;
1155 *)
1156   case ${ac_top_builddir}. in
1157   .) ac_abs_top_builddir=$ac_abs_builddir;;
1158   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
1159   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
1160   esac;;
1161 esac
1162 case $ac_abs_builddir in
1163 .) ac_abs_srcdir=$ac_srcdir;;
1164 *)
1165   case $ac_srcdir in
1166   .) ac_abs_srcdir=$ac_abs_builddir;;
1167   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
1168   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
1169   esac;;
1170 esac
1171 case $ac_abs_builddir in
1172 .) ac_abs_top_srcdir=$ac_top_srcdir;;
1173 *)
1174   case $ac_top_srcdir in
1175   .) ac_abs_top_srcdir=$ac_abs_builddir;;
1176   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
1177   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
1178   esac;;
1179 esac
1180
1181     cd $ac_dir
1182     # Check for guested configure; otherwise get Cygnus style configure.
1183     if test -f $ac_srcdir/configure.gnu; then
1184       echo
1185       $SHELL $ac_srcdir/configure.gnu  --help=recursive
1186     elif test -f $ac_srcdir/configure; then
1187       echo
1188       $SHELL $ac_srcdir/configure  --help=recursive
1189     elif test -f $ac_srcdir/configure.ac ||
1190            test -f $ac_srcdir/configure.in; then
1191       echo
1192       $ac_configure --help
1193     else
1194       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1195     fi
1196     cd $ac_popdir
1197   done
1198 fi
1199
1200 test -n "$ac_init_help" && exit 0
1201 if $ac_init_version; then
1202   cat <<\_ACEOF
1203
1204 Copyright (C) 2003 Free Software Foundation, Inc.
1205 This configure script is free software; the Free Software Foundation
1206 gives unlimited permission to copy, distribute and modify it.
1207
1208 Copyright 1998-2007 The OpenLDAP Foundation. All rights reserved.
1209 Restrictions apply, see COPYRIGHT and LICENSE files.
1210 _ACEOF
1211   exit 0
1212 fi
1213 exec 5>config.log
1214 cat >&5 <<_ACEOF
1215 This file contains any messages produced by compilers while
1216 running configure, to aid debugging if configure makes a mistake.
1217
1218 It was created by $as_me, which was
1219 generated by GNU Autoconf 2.59.  Invocation command line was
1220
1221   $ $0 $@
1222
1223 _ACEOF
1224 {
1225 cat <<_ASUNAME
1226 ## --------- ##
1227 ## Platform. ##
1228 ## --------- ##
1229
1230 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1231 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1232 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1233 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1234 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1235
1236 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1237 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1238
1239 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1240 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1241 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1242 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
1243 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1244 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1245 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1246
1247 _ASUNAME
1248
1249 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1250 for as_dir in $PATH
1251 do
1252   IFS=$as_save_IFS
1253   test -z "$as_dir" && as_dir=.
1254   echo "PATH: $as_dir"
1255 done
1256
1257 } >&5
1258
1259 cat >&5 <<_ACEOF
1260
1261
1262 ## ----------- ##
1263 ## Core tests. ##
1264 ## ----------- ##
1265
1266 _ACEOF
1267
1268
1269 # Keep a trace of the command line.
1270 # Strip out --no-create and --no-recursion so they do not pile up.
1271 # Strip out --silent because we don't want to record it for future runs.
1272 # Also quote any args containing shell meta-characters.
1273 # Make two passes to allow for proper duplicate-argument suppression.
1274 ac_configure_args=
1275 ac_configure_args0=
1276 ac_configure_args1=
1277 ac_sep=
1278 ac_must_keep_next=false
1279 for ac_pass in 1 2
1280 do
1281   for ac_arg
1282   do
1283     case $ac_arg in
1284     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1285     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1286     | -silent | --silent | --silen | --sile | --sil)
1287       continue ;;
1288     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1289       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1290     esac
1291     case $ac_pass in
1292     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1293     2)
1294       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1295       if test $ac_must_keep_next = true; then
1296         ac_must_keep_next=false # Got value, back to normal.
1297       else
1298         case $ac_arg in
1299           *=* | --config-cache | -C | -disable-* | --disable-* \
1300           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1301           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1302           | -with-* | --with-* | -without-* | --without-* | --x)
1303             case "$ac_configure_args0 " in
1304               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1305             esac
1306             ;;
1307           -* ) ac_must_keep_next=true ;;
1308         esac
1309       fi
1310       ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1311       # Get rid of the leading space.
1312       ac_sep=" "
1313       ;;
1314     esac
1315   done
1316 done
1317 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1318 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1319
1320 # When interrupted or exit'd, cleanup temporary files, and complete
1321 # config.log.  We remove comments because anyway the quotes in there
1322 # would cause problems or look ugly.
1323 # WARNING: Be sure not to use single quotes in there, as some shells,
1324 # such as our DU 5.0 friend, will then `close' the trap.
1325 trap 'exit_status=$?
1326   # Save into config.log some information that might help in debugging.
1327   {
1328     echo
1329
1330     cat <<\_ASBOX
1331 ## ---------------- ##
1332 ## Cache variables. ##
1333 ## ---------------- ##
1334 _ASBOX
1335     echo
1336     # The following way of writing the cache mishandles newlines in values,
1337 {
1338   (set) 2>&1 |
1339     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1340     *ac_space=\ *)
1341       sed -n \
1342         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1343           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1344       ;;
1345     *)
1346       sed -n \
1347         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1348       ;;
1349     esac;
1350 }
1351     echo
1352
1353     cat <<\_ASBOX
1354 ## ----------------- ##
1355 ## Output variables. ##
1356 ## ----------------- ##
1357 _ASBOX
1358     echo
1359     for ac_var in $ac_subst_vars
1360     do
1361       eval ac_val=$`echo $ac_var`
1362       echo "$ac_var='"'"'$ac_val'"'"'"
1363     done | sort
1364     echo
1365
1366     if test -n "$ac_subst_files"; then
1367       cat <<\_ASBOX
1368 ## ------------- ##
1369 ## Output files. ##
1370 ## ------------- ##
1371 _ASBOX
1372       echo
1373       for ac_var in $ac_subst_files
1374       do
1375         eval ac_val=$`echo $ac_var`
1376         echo "$ac_var='"'"'$ac_val'"'"'"
1377       done | sort
1378       echo
1379     fi
1380
1381     if test -s confdefs.h; then
1382       cat <<\_ASBOX
1383 ## ----------- ##
1384 ## confdefs.h. ##
1385 ## ----------- ##
1386 _ASBOX
1387       echo
1388       sed "/^$/d" confdefs.h | sort
1389       echo
1390     fi
1391     test "$ac_signal" != 0 &&
1392       echo "$as_me: caught signal $ac_signal"
1393     echo "$as_me: exit $exit_status"
1394   } >&5
1395   rm -f core *.core &&
1396   rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1397     exit $exit_status
1398      ' 0
1399 for ac_signal in 1 2 13 15; do
1400   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1401 done
1402 ac_signal=0
1403
1404 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1405 rm -rf conftest* confdefs.h
1406 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1407 echo >confdefs.h
1408
1409 # Predefined preprocessor variables.
1410
1411 cat >>confdefs.h <<_ACEOF
1412 #define PACKAGE_NAME "$PACKAGE_NAME"
1413 _ACEOF
1414
1415
1416 cat >>confdefs.h <<_ACEOF
1417 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1418 _ACEOF
1419
1420
1421 cat >>confdefs.h <<_ACEOF
1422 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1423 _ACEOF
1424
1425
1426 cat >>confdefs.h <<_ACEOF
1427 #define PACKAGE_STRING "$PACKAGE_STRING"
1428 _ACEOF
1429
1430
1431 cat >>confdefs.h <<_ACEOF
1432 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1433 _ACEOF
1434
1435
1436 # Let the site file select an alternate cache file if it wants to.
1437 # Prefer explicitly selected file to automatically selected ones.
1438 if test -z "$CONFIG_SITE"; then
1439   if test "x$prefix" != xNONE; then
1440     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1441   else
1442     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1443   fi
1444 fi
1445 for ac_site_file in $CONFIG_SITE; do
1446   if test -r "$ac_site_file"; then
1447     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1448 echo "$as_me: loading site script $ac_site_file" >&6;}
1449     sed 's/^/| /' "$ac_site_file" >&5
1450     . "$ac_site_file"
1451   fi
1452 done
1453
1454
1455 # Check that the precious variables saved in the cache have kept the same
1456 # value.
1457 ac_cache_corrupted=false
1458 for ac_var in `(set) 2>&1 |
1459                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1460   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1461   eval ac_new_set=\$ac_env_${ac_var}_set
1462   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1463   eval ac_new_val="\$ac_env_${ac_var}_value"
1464   case $ac_old_set,$ac_new_set in
1465     set,)
1466       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1467 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1468       ac_cache_corrupted=: ;;
1469     ,set)
1470       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1471 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1472       ac_cache_corrupted=: ;;
1473     ,);;
1474     *)
1475       if test "x$ac_old_val" != "x$ac_new_val"; then
1476         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1477 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1478         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1479 echo "$as_me:   former value:  $ac_old_val" >&2;}
1480         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1481 echo "$as_me:   current value: $ac_new_val" >&2;}
1482         ac_cache_corrupted=:
1483       fi;;
1484   esac
1485   # Pass precious variables to config.status.
1486   if test "$ac_new_set" = set; then
1487     case $ac_new_val in
1488     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1489       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1490     *) ac_arg=$ac_var=$ac_new_val ;;
1491     esac
1492     case " $ac_configure_args " in
1493       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1494       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1495     esac
1496   fi
1497 done
1498 if $ac_cache_corrupted; then
1499   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1500 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1501   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1502 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1503    { (exit 1); exit 1; }; }
1504 fi
1505
1506 ac_ext=c
1507 ac_cpp='$CPP $CPPFLAGS'
1508 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1509 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1510 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1511
1512
1513
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 ac_aux_dir=
1555 for ac_dir in build $srcdir/build; do
1556   if test -f $ac_dir/install-sh; then
1557     ac_aux_dir=$ac_dir
1558     ac_install_sh="$ac_aux_dir/install-sh -c"
1559     break
1560   elif test -f $ac_dir/install.sh; then
1561     ac_aux_dir=$ac_dir
1562     ac_install_sh="$ac_aux_dir/install.sh -c"
1563     break
1564   elif test -f $ac_dir/shtool; then
1565     ac_aux_dir=$ac_dir
1566     ac_install_sh="$ac_aux_dir/shtool install -c"
1567     break
1568   fi
1569 done
1570 if test -z "$ac_aux_dir"; then
1571   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in build $srcdir/build" >&5
1572 echo "$as_me: error: cannot find install-sh or install.sh in build $srcdir/build" >&2;}
1573    { (exit 1); exit 1; }; }
1574 fi
1575 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1576 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1577 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1578
1579 eval `$ac_aux_dir/version.sh`
1580 if test -z "$OL_STRING"; then
1581         { { echo "$as_me:$LINENO: error: could not determine version" >&5
1582 echo "$as_me: error: could not determine version" >&2;}
1583    { (exit 1); exit 1; }; }
1584 fi
1585
1586 if test -f "$ac_aux_dir/shtool" && test ! -d $ac_aux_dir/shtool; then
1587         ac_cv_shtool="$ac_aux_dir/shtool"
1588 else
1589         { { echo "$as_me:$LINENO: error: no shtool found in $ac_aux_dir" >&5
1590 echo "$as_me: error: no shtool found in $ac_aux_dir" >&2;}
1591    { (exit 1); exit 1; }; }
1592 fi
1593
1594 SHTOOL="$ac_cv_shtool"
1595
1596 TB="" TN=""
1597 if test -t 1; then
1598         TB="`$SHTOOL echo -e '%B' 2>/dev/null`"
1599         TN="`$SHTOOL echo -e '%b' 2>/dev/null`"
1600 fi
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 # OpenLDAP --enable-ipv6
2266
2267         # Check whether --enable-ipv6 or --disable-ipv6 was given.
2268 if test "${enable_ipv6+set}" = set; then
2269   enableval="$enable_ipv6"
2270
2271         ol_arg=invalid
2272         for ol_val in auto yes no ; do
2273                 if test "$enableval" = "$ol_val" ; then
2274                         ol_arg="$ol_val"
2275                 fi
2276         done
2277         if test "$ol_arg" = "invalid" ; then
2278                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ipv6" >&5
2279 echo "$as_me: error: bad value $enableval for --enable-ipv6" >&2;}
2280    { (exit 1); exit 1; }; }
2281         fi
2282         ol_enable_ipv6="$ol_arg"
2283
2284 else
2285         ol_enable_ipv6=auto
2286 fi;
2287 # end --enable-ipv6
2288 # OpenLDAP --enable-local
2289
2290         # Check whether --enable-local or --disable-local was given.
2291 if test "${enable_local+set}" = set; then
2292   enableval="$enable_local"
2293
2294         ol_arg=invalid
2295         for ol_val in auto yes no ; do
2296                 if test "$enableval" = "$ol_val" ; then
2297                         ol_arg="$ol_val"
2298                 fi
2299         done
2300         if test "$ol_arg" = "invalid" ; then
2301                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-local" >&5
2302 echo "$as_me: error: bad value $enableval for --enable-local" >&2;}
2303    { (exit 1); exit 1; }; }
2304         fi
2305         ol_enable_local="$ol_arg"
2306
2307 else
2308         ol_enable_local=auto
2309 fi;
2310 # end --enable-local
2311
2312 # OpenLDAP --with-cyrus_sasl
2313
2314 # Check whether --with-cyrus_sasl or --without-cyrus_sasl was given.
2315 if test "${with_cyrus_sasl+set}" = set; then
2316   withval="$with_cyrus_sasl"
2317
2318         ol_arg=invalid
2319         for ol_val in auto yes no  ; do
2320                 if test "$withval" = "$ol_val" ; then
2321                         ol_arg="$ol_val"
2322                 fi
2323         done
2324         if test "$ol_arg" = "invalid" ; then
2325                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-cyrus_sasl" >&5
2326 echo "$as_me: error: bad value $withval for --with-cyrus_sasl" >&2;}
2327    { (exit 1); exit 1; }; }
2328         fi
2329         ol_with_cyrus_sasl="$ol_arg"
2330
2331 else
2332         ol_with_cyrus_sasl="auto"
2333 fi; # end --with-cyrus_sasl
2334
2335 # OpenLDAP --with-fetch
2336
2337 # Check whether --with-fetch or --without-fetch was given.
2338 if test "${with_fetch+set}" = set; then
2339   withval="$with_fetch"
2340
2341         ol_arg=invalid
2342         for ol_val in auto yes no  ; do
2343                 if test "$withval" = "$ol_val" ; then
2344                         ol_arg="$ol_val"
2345                 fi
2346         done
2347         if test "$ol_arg" = "invalid" ; then
2348                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-fetch" >&5
2349 echo "$as_me: error: bad value $withval for --with-fetch" >&2;}
2350    { (exit 1); exit 1; }; }
2351         fi
2352         ol_with_fetch="$ol_arg"
2353
2354 else
2355         ol_with_fetch="auto"
2356 fi; # end --with-fetch
2357
2358 # OpenLDAP --with-threads
2359
2360 # Check whether --with-threads or --without-threads was given.
2361 if test "${with_threads+set}" = set; then
2362   withval="$with_threads"
2363
2364         ol_arg=invalid
2365         for ol_val in auto nt posix mach pth lwp yes no manual  ; do
2366                 if test "$withval" = "$ol_val" ; then
2367                         ol_arg="$ol_val"
2368                 fi
2369         done
2370         if test "$ol_arg" = "invalid" ; then
2371                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-threads" >&5
2372 echo "$as_me: error: bad value $withval for --with-threads" >&2;}
2373    { (exit 1); exit 1; }; }
2374         fi
2375         ol_with_threads="$ol_arg"
2376
2377 else
2378         ol_with_threads="auto"
2379 fi; # end --with-threads
2380
2381 # OpenLDAP --with-tls
2382
2383 # Check whether --with-tls or --without-tls was given.
2384 if test "${with_tls+set}" = set; then
2385   withval="$with_tls"
2386
2387         ol_arg=invalid
2388         for ol_val in auto openssl gnutls yes no  ; do
2389                 if test "$withval" = "$ol_val" ; then
2390                         ol_arg="$ol_val"
2391                 fi
2392         done
2393         if test "$ol_arg" = "invalid" ; then
2394                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-tls" >&5
2395 echo "$as_me: error: bad value $withval for --with-tls" >&2;}
2396    { (exit 1); exit 1; }; }
2397         fi
2398         ol_with_tls="$ol_arg"
2399
2400 else
2401         ol_with_tls="auto"
2402 fi; # end --with-tls
2403
2404 # OpenLDAP --with-yielding_select
2405
2406 # Check whether --with-yielding_select or --without-yielding_select was given.
2407 if test "${with_yielding_select+set}" = set; then
2408   withval="$with_yielding_select"
2409
2410         ol_arg=invalid
2411         for ol_val in auto yes no manual  ; do
2412                 if test "$withval" = "$ol_val" ; then
2413                         ol_arg="$ol_val"
2414                 fi
2415         done
2416         if test "$ol_arg" = "invalid" ; then
2417                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-yielding_select" >&5
2418 echo "$as_me: error: bad value $withval for --with-yielding_select" >&2;}
2419    { (exit 1); exit 1; }; }
2420         fi
2421         ol_with_yielding_select="$ol_arg"
2422
2423 else
2424         ol_with_yielding_select="auto"
2425 fi; # end --with-yielding_select
2426
2427 # OpenLDAP --with-mp
2428
2429 # Check whether --with-mp or --without-mp was given.
2430 if test "${with_mp+set}" = set; then
2431   withval="$with_mp"
2432
2433         ol_arg=invalid
2434         for ol_val in auto longlong long bignum gmp yes no ; do
2435                 if test "$withval" = "$ol_val" ; then
2436                         ol_arg="$ol_val"
2437                 fi
2438         done
2439         if test "$ol_arg" = "invalid" ; then
2440                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-mp" >&5
2441 echo "$as_me: error: bad value $withval for --with-mp" >&2;}
2442    { (exit 1); exit 1; }; }
2443         fi
2444         ol_with_mp="$ol_arg"
2445
2446 else
2447         ol_with_mp="auto"
2448 fi; # end --with-mp
2449
2450 # OpenLDAP --with-odbc
2451
2452 # Check whether --with-odbc or --without-odbc was given.
2453 if test "${with_odbc+set}" = set; then
2454   withval="$with_odbc"
2455
2456         ol_arg=invalid
2457         for ol_val in auto iodbc unixodbc  ; do
2458                 if test "$withval" = "$ol_val" ; then
2459                         ol_arg="$ol_val"
2460                 fi
2461         done
2462         if test "$ol_arg" = "invalid" ; then
2463                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-odbc" >&5
2464 echo "$as_me: error: bad value $withval for --with-odbc" >&2;}
2465    { (exit 1); exit 1; }; }
2466         fi
2467         ol_with_odbc="$ol_arg"
2468
2469 else
2470         ol_with_odbc="auto"
2471 fi; # end --with-odbc
2472
2473
2474
2475 # Check whether --enable-xxslapdoptions or --disable-xxslapdoptions was given.
2476 if test "${enable_xxslapdoptions+set}" = set; then
2477   enableval="$enable_xxslapdoptions"
2478
2479 fi;
2480 # OpenLDAP --enable-slapd
2481
2482         # Check whether --enable-slapd or --disable-slapd was given.
2483 if test "${enable_slapd+set}" = set; then
2484   enableval="$enable_slapd"
2485
2486         ol_arg=invalid
2487         for ol_val in auto yes no ; do
2488                 if test "$enableval" = "$ol_val" ; then
2489                         ol_arg="$ol_val"
2490                 fi
2491         done
2492         if test "$ol_arg" = "invalid" ; then
2493                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slapd" >&5
2494 echo "$as_me: error: bad value $enableval for --enable-slapd" >&2;}
2495    { (exit 1); exit 1; }; }
2496         fi
2497         ol_enable_slapd="$ol_arg"
2498
2499 else
2500         ol_enable_slapd=yes
2501 fi;
2502 # end --enable-slapd
2503 # OpenLDAP --enable-dynacl
2504
2505         # Check whether --enable-dynacl or --disable-dynacl was given.
2506 if test "${enable_dynacl+set}" = set; then
2507   enableval="$enable_dynacl"
2508
2509         ol_arg=invalid
2510         for ol_val in auto yes no ; do
2511                 if test "$enableval" = "$ol_val" ; then
2512                         ol_arg="$ol_val"
2513                 fi
2514         done
2515         if test "$ol_arg" = "invalid" ; then
2516                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dynacl" >&5
2517 echo "$as_me: error: bad value $enableval for --enable-dynacl" >&2;}
2518    { (exit 1); exit 1; }; }
2519         fi
2520         ol_enable_dynacl="$ol_arg"
2521
2522 else
2523         ol_enable_dynacl=no
2524 fi;
2525 # end --enable-dynacl
2526 # OpenLDAP --enable-aci
2527
2528         # Check whether --enable-aci or --disable-aci was given.
2529 if test "${enable_aci+set}" = set; then
2530   enableval="$enable_aci"
2531
2532         ol_arg=invalid
2533         for ol_val in no yes mod ; do
2534                 if test "$enableval" = "$ol_val" ; then
2535                         ol_arg="$ol_val"
2536                 fi
2537         done
2538         if test "$ol_arg" = "invalid" ; then
2539                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-aci" >&5
2540 echo "$as_me: error: bad value $enableval for --enable-aci" >&2;}
2541    { (exit 1); exit 1; }; }
2542         fi
2543         ol_enable_aci="$ol_arg"
2544
2545 else
2546         ol_enable_aci=no
2547 fi;
2548 # end --enable-aci
2549 # OpenLDAP --enable-cleartext
2550
2551         # Check whether --enable-cleartext or --disable-cleartext was given.
2552 if test "${enable_cleartext+set}" = set; then
2553   enableval="$enable_cleartext"
2554
2555         ol_arg=invalid
2556         for ol_val in auto yes no ; do
2557                 if test "$enableval" = "$ol_val" ; then
2558                         ol_arg="$ol_val"
2559                 fi
2560         done
2561         if test "$ol_arg" = "invalid" ; then
2562                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-cleartext" >&5
2563 echo "$as_me: error: bad value $enableval for --enable-cleartext" >&2;}
2564    { (exit 1); exit 1; }; }
2565         fi
2566         ol_enable_cleartext="$ol_arg"
2567
2568 else
2569         ol_enable_cleartext=yes
2570 fi;
2571 # end --enable-cleartext
2572 # OpenLDAP --enable-crypt
2573
2574         # Check whether --enable-crypt or --disable-crypt was given.
2575 if test "${enable_crypt+set}" = set; then
2576   enableval="$enable_crypt"
2577
2578         ol_arg=invalid
2579         for ol_val in auto yes no ; do
2580                 if test "$enableval" = "$ol_val" ; then
2581                         ol_arg="$ol_val"
2582                 fi
2583         done
2584         if test "$ol_arg" = "invalid" ; then
2585                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-crypt" >&5
2586 echo "$as_me: error: bad value $enableval for --enable-crypt" >&2;}
2587    { (exit 1); exit 1; }; }
2588         fi
2589         ol_enable_crypt="$ol_arg"
2590
2591 else
2592         ol_enable_crypt=no
2593 fi;
2594 # end --enable-crypt
2595 # OpenLDAP --enable-lmpasswd
2596
2597         # Check whether --enable-lmpasswd or --disable-lmpasswd was given.
2598 if test "${enable_lmpasswd+set}" = set; then
2599   enableval="$enable_lmpasswd"
2600
2601         ol_arg=invalid
2602         for ol_val in auto yes no ; do
2603                 if test "$enableval" = "$ol_val" ; then
2604                         ol_arg="$ol_val"
2605                 fi
2606         done
2607         if test "$ol_arg" = "invalid" ; then
2608                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-lmpasswd" >&5
2609 echo "$as_me: error: bad value $enableval for --enable-lmpasswd" >&2;}
2610    { (exit 1); exit 1; }; }
2611         fi
2612         ol_enable_lmpasswd="$ol_arg"
2613
2614 else
2615         ol_enable_lmpasswd=no
2616 fi;
2617 # end --enable-lmpasswd
2618 # OpenLDAP --enable-spasswd
2619
2620         # Check whether --enable-spasswd or --disable-spasswd was given.
2621 if test "${enable_spasswd+set}" = set; then
2622   enableval="$enable_spasswd"
2623
2624         ol_arg=invalid
2625         for ol_val in auto yes no ; do
2626                 if test "$enableval" = "$ol_val" ; then
2627                         ol_arg="$ol_val"
2628                 fi
2629         done
2630         if test "$ol_arg" = "invalid" ; then
2631                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-spasswd" >&5
2632 echo "$as_me: error: bad value $enableval for --enable-spasswd" >&2;}
2633    { (exit 1); exit 1; }; }
2634         fi
2635         ol_enable_spasswd="$ol_arg"
2636
2637 else
2638         ol_enable_spasswd=no
2639 fi;
2640 # end --enable-spasswd
2641 # OpenLDAP --enable-modules
2642
2643         # Check whether --enable-modules or --disable-modules was given.
2644 if test "${enable_modules+set}" = set; then
2645   enableval="$enable_modules"
2646
2647         ol_arg=invalid
2648         for ol_val in auto yes no ; do
2649                 if test "$enableval" = "$ol_val" ; then
2650                         ol_arg="$ol_val"
2651                 fi
2652         done
2653         if test "$ol_arg" = "invalid" ; then
2654                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-modules" >&5
2655 echo "$as_me: error: bad value $enableval for --enable-modules" >&2;}
2656    { (exit 1); exit 1; }; }
2657         fi
2658         ol_enable_modules="$ol_arg"
2659
2660 else
2661         ol_enable_modules=no
2662 fi;
2663 # end --enable-modules
2664 # OpenLDAP --enable-rewrite
2665
2666         # Check whether --enable-rewrite or --disable-rewrite was given.
2667 if test "${enable_rewrite+set}" = set; then
2668   enableval="$enable_rewrite"
2669
2670         ol_arg=invalid
2671         for ol_val in auto yes no ; do
2672                 if test "$enableval" = "$ol_val" ; then
2673                         ol_arg="$ol_val"
2674                 fi
2675         done
2676         if test "$ol_arg" = "invalid" ; then
2677                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rewrite" >&5
2678 echo "$as_me: error: bad value $enableval for --enable-rewrite" >&2;}
2679    { (exit 1); exit 1; }; }
2680         fi
2681         ol_enable_rewrite="$ol_arg"
2682
2683 else
2684         ol_enable_rewrite=auto
2685 fi;
2686 # end --enable-rewrite
2687 # OpenLDAP --enable-rlookups
2688
2689         # Check whether --enable-rlookups or --disable-rlookups was given.
2690 if test "${enable_rlookups+set}" = set; then
2691   enableval="$enable_rlookups"
2692
2693         ol_arg=invalid
2694         for ol_val in auto yes no ; do
2695                 if test "$enableval" = "$ol_val" ; then
2696                         ol_arg="$ol_val"
2697                 fi
2698         done
2699         if test "$ol_arg" = "invalid" ; then
2700                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rlookups" >&5
2701 echo "$as_me: error: bad value $enableval for --enable-rlookups" >&2;}
2702    { (exit 1); exit 1; }; }
2703         fi
2704         ol_enable_rlookups="$ol_arg"
2705
2706 else
2707         ol_enable_rlookups=no
2708 fi;
2709 # end --enable-rlookups
2710 # OpenLDAP --enable-slapi
2711
2712         # Check whether --enable-slapi or --disable-slapi was given.
2713 if test "${enable_slapi+set}" = set; then
2714   enableval="$enable_slapi"
2715
2716         ol_arg=invalid
2717         for ol_val in auto yes no ; do
2718                 if test "$enableval" = "$ol_val" ; then
2719                         ol_arg="$ol_val"
2720                 fi
2721         done
2722         if test "$ol_arg" = "invalid" ; then
2723                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slapi" >&5
2724 echo "$as_me: error: bad value $enableval for --enable-slapi" >&2;}
2725    { (exit 1); exit 1; }; }
2726         fi
2727         ol_enable_slapi="$ol_arg"
2728
2729 else
2730         ol_enable_slapi=no
2731 fi;
2732 # end --enable-slapi
2733 # OpenLDAP --enable-slp
2734
2735         # Check whether --enable-slp or --disable-slp was given.
2736 if test "${enable_slp+set}" = set; then
2737   enableval="$enable_slp"
2738
2739         ol_arg=invalid
2740         for ol_val in auto yes no ; do
2741                 if test "$enableval" = "$ol_val" ; then
2742                         ol_arg="$ol_val"
2743                 fi
2744         done
2745         if test "$ol_arg" = "invalid" ; then
2746                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slp" >&5
2747 echo "$as_me: error: bad value $enableval for --enable-slp" >&2;}
2748    { (exit 1); exit 1; }; }
2749         fi
2750         ol_enable_slp="$ol_arg"
2751
2752 else
2753         ol_enable_slp=no
2754 fi;
2755 # end --enable-slp
2756 # OpenLDAP --enable-wrappers
2757
2758         # Check whether --enable-wrappers or --disable-wrappers was given.
2759 if test "${enable_wrappers+set}" = set; then
2760   enableval="$enable_wrappers"
2761
2762         ol_arg=invalid
2763         for ol_val in auto yes no ; do
2764                 if test "$enableval" = "$ol_val" ; then
2765                         ol_arg="$ol_val"
2766                 fi
2767         done
2768         if test "$ol_arg" = "invalid" ; then
2769                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-wrappers" >&5
2770 echo "$as_me: error: bad value $enableval for --enable-wrappers" >&2;}
2771    { (exit 1); exit 1; }; }
2772         fi
2773         ol_enable_wrappers="$ol_arg"
2774
2775 else
2776         ol_enable_wrappers=no
2777 fi;
2778 # end --enable-wrappers
2779
2780 Backends="bdb \
2781         dnssrv \
2782         hdb \
2783         ldap \
2784         meta \
2785         monitor \
2786         null \
2787         passwd \
2788         perl \
2789         relay \
2790         shell \
2791         sql"
2792
2793 # Check whether --enable-xxslapbackends or --disable-xxslapbackends was given.
2794 if test "${enable_xxslapbackends+set}" = set; then
2795   enableval="$enable_xxslapbackends"
2796
2797 fi;
2798
2799 # OpenLDAP --enable-backends
2800
2801         # Check whether --enable-backends or --disable-backends was given.
2802 if test "${enable_backends+set}" = set; then
2803   enableval="$enable_backends"
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-backends" >&5
2813 echo "$as_me: error: bad value $enableval for --enable-backends" >&2;}
2814    { (exit 1); exit 1; }; }
2815         fi
2816         ol_enable_backends="$ol_arg"
2817
2818 fi;
2819 # end --enable-backends
2820 # OpenLDAP --enable-bdb
2821
2822         # Check whether --enable-bdb or --disable-bdb was given.
2823 if test "${enable_bdb+set}" = set; then
2824   enableval="$enable_bdb"
2825
2826         ol_arg=invalid
2827         for ol_val in no yes mod ; do
2828                 if test "$enableval" = "$ol_val" ; then
2829                         ol_arg="$ol_val"
2830                 fi
2831         done
2832         if test "$ol_arg" = "invalid" ; then
2833                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-bdb" >&5
2834 echo "$as_me: error: bad value $enableval for --enable-bdb" >&2;}
2835    { (exit 1); exit 1; }; }
2836         fi
2837         ol_enable_bdb="$ol_arg"
2838
2839 else
2840         ol_enable_bdb=${ol_enable_backends:-yes}
2841 fi;
2842 # end --enable-bdb
2843 # OpenLDAP --enable-dnssrv
2844
2845         # Check whether --enable-dnssrv or --disable-dnssrv was given.
2846 if test "${enable_dnssrv+set}" = set; then
2847   enableval="$enable_dnssrv"
2848
2849         ol_arg=invalid
2850         for ol_val in no yes mod ; do
2851                 if test "$enableval" = "$ol_val" ; then
2852                         ol_arg="$ol_val"
2853                 fi
2854         done
2855         if test "$ol_arg" = "invalid" ; then
2856                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dnssrv" >&5
2857 echo "$as_me: error: bad value $enableval for --enable-dnssrv" >&2;}
2858    { (exit 1); exit 1; }; }
2859         fi
2860         ol_enable_dnssrv="$ol_arg"
2861
2862 else
2863         ol_enable_dnssrv=${ol_enable_backends:-no}
2864 fi;
2865 # end --enable-dnssrv
2866 # OpenLDAP --enable-hdb
2867
2868         # Check whether --enable-hdb or --disable-hdb was given.
2869 if test "${enable_hdb+set}" = set; then
2870   enableval="$enable_hdb"
2871
2872         ol_arg=invalid
2873         for ol_val in no yes mod ; do
2874                 if test "$enableval" = "$ol_val" ; then
2875                         ol_arg="$ol_val"
2876                 fi
2877         done
2878         if test "$ol_arg" = "invalid" ; then
2879                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-hdb" >&5
2880 echo "$as_me: error: bad value $enableval for --enable-hdb" >&2;}
2881    { (exit 1); exit 1; }; }
2882         fi
2883         ol_enable_hdb="$ol_arg"
2884
2885 else
2886         ol_enable_hdb=${ol_enable_backends:-yes}
2887 fi;
2888 # end --enable-hdb
2889 # OpenLDAP --enable-ldap
2890
2891         # Check whether --enable-ldap or --disable-ldap was given.
2892 if test "${enable_ldap+set}" = set; then
2893   enableval="$enable_ldap"
2894
2895         ol_arg=invalid
2896         for ol_val in no yes mod ; do
2897                 if test "$enableval" = "$ol_val" ; then
2898                         ol_arg="$ol_val"
2899                 fi
2900         done
2901         if test "$ol_arg" = "invalid" ; then
2902                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ldap" >&5
2903 echo "$as_me: error: bad value $enableval for --enable-ldap" >&2;}
2904    { (exit 1); exit 1; }; }
2905         fi
2906         ol_enable_ldap="$ol_arg"
2907
2908 else
2909         ol_enable_ldap=${ol_enable_backends:-no}
2910 fi;
2911 # end --enable-ldap
2912 # OpenLDAP --enable-meta
2913
2914         # Check whether --enable-meta or --disable-meta was given.
2915 if test "${enable_meta+set}" = set; then
2916   enableval="$enable_meta"
2917
2918         ol_arg=invalid
2919         for ol_val in no yes mod ; do
2920                 if test "$enableval" = "$ol_val" ; then
2921                         ol_arg="$ol_val"
2922                 fi
2923         done
2924         if test "$ol_arg" = "invalid" ; then
2925                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-meta" >&5
2926 echo "$as_me: error: bad value $enableval for --enable-meta" >&2;}
2927    { (exit 1); exit 1; }; }
2928         fi
2929         ol_enable_meta="$ol_arg"
2930
2931 else
2932         ol_enable_meta=${ol_enable_backends:-no}
2933 fi;
2934 # end --enable-meta
2935 # OpenLDAP --enable-monitor
2936
2937         # Check whether --enable-monitor or --disable-monitor was given.
2938 if test "${enable_monitor+set}" = set; then
2939   enableval="$enable_monitor"
2940
2941         ol_arg=invalid
2942         for ol_val in no yes mod ; do
2943                 if test "$enableval" = "$ol_val" ; then
2944                         ol_arg="$ol_val"
2945                 fi
2946         done
2947         if test "$ol_arg" = "invalid" ; then
2948                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-monitor" >&5
2949 echo "$as_me: error: bad value $enableval for --enable-monitor" >&2;}
2950    { (exit 1); exit 1; }; }
2951         fi
2952         ol_enable_monitor="$ol_arg"
2953
2954 else
2955         ol_enable_monitor=${ol_enable_backends:-yes}
2956 fi;
2957 # end --enable-monitor
2958 # OpenLDAP --enable-null
2959
2960         # Check whether --enable-null or --disable-null was given.
2961 if test "${enable_null+set}" = set; then
2962   enableval="$enable_null"
2963
2964         ol_arg=invalid
2965         for ol_val in no yes mod ; do
2966                 if test "$enableval" = "$ol_val" ; then
2967                         ol_arg="$ol_val"
2968                 fi
2969         done
2970         if test "$ol_arg" = "invalid" ; then
2971                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-null" >&5
2972 echo "$as_me: error: bad value $enableval for --enable-null" >&2;}
2973    { (exit 1); exit 1; }; }
2974         fi
2975         ol_enable_null="$ol_arg"
2976
2977 else
2978         ol_enable_null=${ol_enable_backends:-no}
2979 fi;
2980 # end --enable-null
2981 # OpenLDAP --enable-passwd
2982
2983         # Check whether --enable-passwd or --disable-passwd was given.
2984 if test "${enable_passwd+set}" = set; then
2985   enableval="$enable_passwd"
2986
2987         ol_arg=invalid
2988         for ol_val in no yes mod ; do
2989                 if test "$enableval" = "$ol_val" ; then
2990                         ol_arg="$ol_val"
2991                 fi
2992         done
2993         if test "$ol_arg" = "invalid" ; then
2994                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-passwd" >&5
2995 echo "$as_me: error: bad value $enableval for --enable-passwd" >&2;}
2996    { (exit 1); exit 1; }; }
2997         fi
2998         ol_enable_passwd="$ol_arg"
2999
3000 else
3001         ol_enable_passwd=${ol_enable_backends:-no}
3002 fi;
3003 # end --enable-passwd
3004 # OpenLDAP --enable-perl
3005
3006         # Check whether --enable-perl or --disable-perl was given.
3007 if test "${enable_perl+set}" = set; then
3008   enableval="$enable_perl"
3009
3010         ol_arg=invalid
3011         for ol_val in no yes mod ; do
3012                 if test "$enableval" = "$ol_val" ; then
3013                         ol_arg="$ol_val"
3014                 fi
3015         done
3016         if test "$ol_arg" = "invalid" ; then
3017                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-perl" >&5
3018 echo "$as_me: error: bad value $enableval for --enable-perl" >&2;}
3019    { (exit 1); exit 1; }; }
3020         fi
3021         ol_enable_perl="$ol_arg"
3022
3023 else
3024         ol_enable_perl=${ol_enable_backends:-no}
3025 fi;
3026 # end --enable-perl
3027 # OpenLDAP --enable-relay
3028
3029         # Check whether --enable-relay or --disable-relay was given.
3030 if test "${enable_relay+set}" = set; then
3031   enableval="$enable_relay"
3032
3033         ol_arg=invalid
3034         for ol_val in no yes mod ; do
3035                 if test "$enableval" = "$ol_val" ; then
3036                         ol_arg="$ol_val"
3037                 fi
3038         done
3039         if test "$ol_arg" = "invalid" ; then
3040                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-relay" >&5
3041 echo "$as_me: error: bad value $enableval for --enable-relay" >&2;}
3042    { (exit 1); exit 1; }; }
3043         fi
3044         ol_enable_relay="$ol_arg"
3045
3046 else
3047         ol_enable_relay=${ol_enable_backends:-yes}
3048 fi;
3049 # end --enable-relay
3050 # OpenLDAP --enable-shell
3051
3052         # Check whether --enable-shell or --disable-shell was given.
3053 if test "${enable_shell+set}" = set; then
3054   enableval="$enable_shell"
3055
3056         ol_arg=invalid
3057         for ol_val in no yes mod ; do
3058                 if test "$enableval" = "$ol_val" ; then
3059                         ol_arg="$ol_val"
3060                 fi
3061         done
3062         if test "$ol_arg" = "invalid" ; then
3063                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-shell" >&5
3064 echo "$as_me: error: bad value $enableval for --enable-shell" >&2;}
3065    { (exit 1); exit 1; }; }
3066         fi
3067         ol_enable_shell="$ol_arg"
3068
3069 else
3070         ol_enable_shell=${ol_enable_backends:-no}
3071 fi;
3072 # end --enable-shell
3073 # OpenLDAP --enable-sql
3074
3075         # Check whether --enable-sql or --disable-sql was given.
3076 if test "${enable_sql+set}" = set; then
3077   enableval="$enable_sql"
3078
3079         ol_arg=invalid
3080         for ol_val in no yes mod ; do
3081                 if test "$enableval" = "$ol_val" ; then
3082                         ol_arg="$ol_val"
3083                 fi
3084         done
3085         if test "$ol_arg" = "invalid" ; then
3086                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-sql" >&5
3087 echo "$as_me: error: bad value $enableval for --enable-sql" >&2;}
3088    { (exit 1); exit 1; }; }
3089         fi
3090         ol_enable_sql="$ol_arg"
3091
3092 else
3093         ol_enable_sql=${ol_enable_backends:-no}
3094 fi;
3095 # end --enable-sql
3096
3097 Overlays="accesslog \
3098         auditlog \
3099         constraint \
3100         dds \
3101         dyngroup \
3102         dynlist \
3103         memberof \
3104         ppolicy \
3105         proxycache \
3106         refint \
3107         retcode \
3108         rwm \
3109         seqmod \
3110         syncprov \
3111         translucent \
3112         unique \
3113         valsort"
3114
3115 # Check whether --enable-xxslapoverlays or --disable-xxslapoverlays was given.
3116 if test "${enable_xxslapoverlays+set}" = set; then
3117   enableval="$enable_xxslapoverlays"
3118
3119 fi;
3120
3121 # OpenLDAP --enable-overlays
3122
3123         # Check whether --enable-overlays or --disable-overlays was given.
3124 if test "${enable_overlays+set}" = set; then
3125   enableval="$enable_overlays"
3126
3127         ol_arg=invalid
3128         for ol_val in no yes mod ; do
3129                 if test "$enableval" = "$ol_val" ; then
3130                         ol_arg="$ol_val"
3131                 fi
3132         done
3133         if test "$ol_arg" = "invalid" ; then
3134                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-overlays" >&5
3135 echo "$as_me: error: bad value $enableval for --enable-overlays" >&2;}
3136    { (exit 1); exit 1; }; }
3137         fi
3138         ol_enable_overlays="$ol_arg"
3139
3140 fi;
3141 # end --enable-overlays
3142 # OpenLDAP --enable-accesslog
3143
3144         # Check whether --enable-accesslog or --disable-accesslog was given.
3145 if test "${enable_accesslog+set}" = set; then
3146   enableval="$enable_accesslog"
3147
3148         ol_arg=invalid
3149         for ol_val in no yes mod ; do
3150                 if test "$enableval" = "$ol_val" ; then
3151                         ol_arg="$ol_val"
3152                 fi
3153         done
3154         if test "$ol_arg" = "invalid" ; then
3155                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-accesslog" >&5
3156 echo "$as_me: error: bad value $enableval for --enable-accesslog" >&2;}
3157    { (exit 1); exit 1; }; }
3158         fi
3159         ol_enable_accesslog="$ol_arg"
3160
3161 else
3162         ol_enable_accesslog=${ol_enable_overlays:-no}
3163 fi;
3164 # end --enable-accesslog
3165
3166 # OpenLDAP --enable-auditlog
3167
3168         # Check whether --enable-auditlog or --disable-auditlog was given.
3169 if test "${enable_auditlog+set}" = set; then
3170   enableval="$enable_auditlog"
3171
3172         ol_arg=invalid
3173         for ol_val in no yes mod ; do
3174                 if test "$enableval" = "$ol_val" ; then
3175                         ol_arg="$ol_val"
3176                 fi
3177         done
3178         if test "$ol_arg" = "invalid" ; then
3179                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-auditlog" >&5
3180 echo "$as_me: error: bad value $enableval for --enable-auditlog" >&2;}
3181    { (exit 1); exit 1; }; }
3182         fi
3183         ol_enable_auditlog="$ol_arg"
3184
3185 else
3186         ol_enable_auditlog=${ol_enable_overlays:-no}
3187 fi;
3188 # end --enable-auditlog
3189
3190 # OpenLDAP --enable-constraint
3191
3192         # Check whether --enable-constraint or --disable-constraint was given.
3193 if test "${enable_constraint+set}" = set; then
3194   enableval="$enable_constraint"
3195
3196         ol_arg=invalid
3197         for ol_val in no yes mod ; do
3198                 if test "$enableval" = "$ol_val" ; then
3199                         ol_arg="$ol_val"
3200                 fi
3201         done
3202         if test "$ol_arg" = "invalid" ; then
3203                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-constraint" >&5
3204 echo "$as_me: error: bad value $enableval for --enable-constraint" >&2;}
3205    { (exit 1); exit 1; }; }
3206         fi
3207         ol_enable_constraint="$ol_arg"
3208
3209 else
3210         ol_enable_constraint=${ol_enable_overlays:-no}
3211 fi;
3212 # end --enable-constraint
3213
3214 # OpenLDAP --enable-dds
3215
3216         # Check whether --enable-dds or --disable-dds was given.
3217 if test "${enable_dds+set}" = set; then
3218   enableval="$enable_dds"
3219
3220         ol_arg=invalid
3221         for ol_val in no yes mod ; do
3222                 if test "$enableval" = "$ol_val" ; then
3223                         ol_arg="$ol_val"
3224                 fi
3225         done
3226         if test "$ol_arg" = "invalid" ; then
3227                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dds" >&5
3228 echo "$as_me: error: bad value $enableval for --enable-dds" >&2;}
3229    { (exit 1); exit 1; }; }
3230         fi
3231         ol_enable_dds="$ol_arg"
3232
3233 else
3234         ol_enable_dds=${ol_enable_overlays:-no}
3235 fi;
3236 # end --enable-dds
3237
3238 # OpenLDAP --enable-dyngroup
3239
3240         # Check whether --enable-dyngroup or --disable-dyngroup was given.
3241 if test "${enable_dyngroup+set}" = set; then
3242   enableval="$enable_dyngroup"
3243
3244         ol_arg=invalid
3245         for ol_val in no yes mod ; do
3246                 if test "$enableval" = "$ol_val" ; then
3247                         ol_arg="$ol_val"
3248                 fi
3249         done
3250         if test "$ol_arg" = "invalid" ; then
3251                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dyngroup" >&5
3252 echo "$as_me: error: bad value $enableval for --enable-dyngroup" >&2;}
3253    { (exit 1); exit 1; }; }
3254         fi
3255         ol_enable_dyngroup="$ol_arg"
3256
3257 else
3258         ol_enable_dyngroup=${ol_enable_overlays:-no}
3259 fi;
3260 # end --enable-dyngroup
3261
3262 # OpenLDAP --enable-dynlist
3263
3264         # Check whether --enable-dynlist or --disable-dynlist was given.
3265 if test "${enable_dynlist+set}" = set; then
3266   enableval="$enable_dynlist"
3267
3268         ol_arg=invalid
3269         for ol_val in no yes mod ; do
3270                 if test "$enableval" = "$ol_val" ; then
3271                         ol_arg="$ol_val"
3272                 fi
3273         done
3274         if test "$ol_arg" = "invalid" ; then
3275                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dynlist" >&5
3276 echo "$as_me: error: bad value $enableval for --enable-dynlist" >&2;}
3277    { (exit 1); exit 1; }; }
3278         fi
3279         ol_enable_dynlist="$ol_arg"
3280
3281 else
3282         ol_enable_dynlist=${ol_enable_overlays:-no}
3283 fi;
3284 # end --enable-dynlist
3285
3286 # OpenLDAP --enable-memberof
3287
3288         # Check whether --enable-memberof or --disable-memberof was given.
3289 if test "${enable_memberof+set}" = set; then
3290   enableval="$enable_memberof"
3291
3292         ol_arg=invalid
3293         for ol_val in no yes mod ; do
3294                 if test "$enableval" = "$ol_val" ; then
3295                         ol_arg="$ol_val"
3296                 fi
3297         done
3298         if test "$ol_arg" = "invalid" ; then
3299                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-memberof" >&5
3300 echo "$as_me: error: bad value $enableval for --enable-memberof" >&2;}
3301    { (exit 1); exit 1; }; }
3302         fi
3303         ol_enable_memberof="$ol_arg"
3304
3305 else
3306         ol_enable_memberof=${ol_enable_overlays:-no}
3307 fi;
3308 # end --enable-memberof
3309
3310 # OpenLDAP --enable-ppolicy
3311
3312         # Check whether --enable-ppolicy or --disable-ppolicy was given.
3313 if test "${enable_ppolicy+set}" = set; then
3314   enableval="$enable_ppolicy"
3315
3316         ol_arg=invalid
3317         for ol_val in no yes mod ; do
3318                 if test "$enableval" = "$ol_val" ; then
3319                         ol_arg="$ol_val"
3320                 fi
3321         done
3322         if test "$ol_arg" = "invalid" ; then
3323                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ppolicy" >&5
3324 echo "$as_me: error: bad value $enableval for --enable-ppolicy" >&2;}
3325    { (exit 1); exit 1; }; }
3326         fi
3327         ol_enable_ppolicy="$ol_arg"
3328
3329 else
3330         ol_enable_ppolicy=${ol_enable_overlays:-no}
3331 fi;
3332 # end --enable-ppolicy
3333
3334 # OpenLDAP --enable-proxycache
3335
3336         # Check whether --enable-proxycache or --disable-proxycache was given.
3337 if test "${enable_proxycache+set}" = set; then
3338   enableval="$enable_proxycache"
3339
3340         ol_arg=invalid
3341         for ol_val in no yes mod ; do
3342                 if test "$enableval" = "$ol_val" ; then
3343                         ol_arg="$ol_val"
3344                 fi
3345         done
3346         if test "$ol_arg" = "invalid" ; then
3347                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-proxycache" >&5
3348 echo "$as_me: error: bad value $enableval for --enable-proxycache" >&2;}
3349    { (exit 1); exit 1; }; }
3350         fi
3351         ol_enable_proxycache="$ol_arg"
3352
3353 else
3354         ol_enable_proxycache=${ol_enable_overlays:-no}
3355 fi;
3356 # end --enable-proxycache
3357
3358 # OpenLDAP --enable-refint
3359
3360         # Check whether --enable-refint or --disable-refint was given.
3361 if test "${enable_refint+set}" = set; then
3362   enableval="$enable_refint"
3363
3364         ol_arg=invalid
3365         for ol_val in no yes mod ; do
3366                 if test "$enableval" = "$ol_val" ; then
3367                         ol_arg="$ol_val"
3368                 fi
3369         done
3370         if test "$ol_arg" = "invalid" ; then
3371                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-refint" >&5
3372 echo "$as_me: error: bad value $enableval for --enable-refint" >&2;}
3373    { (exit 1); exit 1; }; }
3374         fi
3375         ol_enable_refint="$ol_arg"
3376
3377 else
3378         ol_enable_refint=${ol_enable_overlays:-no}
3379 fi;
3380 # end --enable-refint
3381
3382 # OpenLDAP --enable-retcode
3383
3384         # Check whether --enable-retcode or --disable-retcode was given.
3385 if test "${enable_retcode+set}" = set; then
3386   enableval="$enable_retcode"
3387
3388         ol_arg=invalid
3389         for ol_val in no yes mod ; do
3390                 if test "$enableval" = "$ol_val" ; then
3391                         ol_arg="$ol_val"
3392                 fi
3393         done
3394         if test "$ol_arg" = "invalid" ; then
3395                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-retcode" >&5
3396 echo "$as_me: error: bad value $enableval for --enable-retcode" >&2;}
3397    { (exit 1); exit 1; }; }
3398         fi
3399         ol_enable_retcode="$ol_arg"
3400
3401 else
3402         ol_enable_retcode=${ol_enable_overlays:-no}
3403 fi;
3404 # end --enable-retcode
3405
3406 # OpenLDAP --enable-rwm
3407
3408         # Check whether --enable-rwm or --disable-rwm was given.
3409 if test "${enable_rwm+set}" = set; then
3410   enableval="$enable_rwm"
3411
3412         ol_arg=invalid
3413         for ol_val in no yes mod ; do
3414                 if test "$enableval" = "$ol_val" ; then
3415                         ol_arg="$ol_val"
3416                 fi
3417         done
3418         if test "$ol_arg" = "invalid" ; then
3419                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rwm" >&5
3420 echo "$as_me: error: bad value $enableval for --enable-rwm" >&2;}
3421    { (exit 1); exit 1; }; }
3422         fi
3423         ol_enable_rwm="$ol_arg"
3424
3425 else
3426         ol_enable_rwm=${ol_enable_overlays:-no}
3427 fi;
3428 # end --enable-rwm
3429
3430 # OpenLDAP --enable-seqmod
3431
3432         # Check whether --enable-seqmod or --disable-seqmod was given.
3433 if test "${enable_seqmod+set}" = set; then
3434   enableval="$enable_seqmod"
3435
3436         ol_arg=invalid
3437         for ol_val in no yes mod ; do
3438                 if test "$enableval" = "$ol_val" ; then
3439                         ol_arg="$ol_val"
3440                 fi
3441         done
3442         if test "$ol_arg" = "invalid" ; then
3443                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-seqmod" >&5
3444 echo "$as_me: error: bad value $enableval for --enable-seqmod" >&2;}
3445    { (exit 1); exit 1; }; }
3446         fi
3447         ol_enable_seqmod="$ol_arg"
3448
3449 else
3450         ol_enable_seqmod=${ol_enable_overlays:-yes}
3451 fi;
3452 # end --enable-seqmod
3453
3454 # OpenLDAP --enable-syncprov
3455
3456         # Check whether --enable-syncprov or --disable-syncprov was given.
3457 if test "${enable_syncprov+set}" = set; then
3458   enableval="$enable_syncprov"
3459
3460         ol_arg=invalid
3461         for ol_val in no yes mod ; do
3462                 if test "$enableval" = "$ol_val" ; then
3463                         ol_arg="$ol_val"
3464                 fi
3465         done
3466         if test "$ol_arg" = "invalid" ; then
3467                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-syncprov" >&5
3468 echo "$as_me: error: bad value $enableval for --enable-syncprov" >&2;}
3469    { (exit 1); exit 1; }; }
3470         fi
3471         ol_enable_syncprov="$ol_arg"
3472
3473 else
3474         ol_enable_syncprov=${ol_enable_overlays:-yes}
3475 fi;
3476 # end --enable-syncprov
3477
3478 # OpenLDAP --enable-translucent
3479
3480         # Check whether --enable-translucent or --disable-translucent was given.
3481 if test "${enable_translucent+set}" = set; then
3482   enableval="$enable_translucent"
3483
3484         ol_arg=invalid
3485         for ol_val in no yes mod ; do
3486                 if test "$enableval" = "$ol_val" ; then
3487                         ol_arg="$ol_val"
3488                 fi
3489         done
3490         if test "$ol_arg" = "invalid" ; then
3491                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-translucent" >&5
3492 echo "$as_me: error: bad value $enableval for --enable-translucent" >&2;}
3493    { (exit 1); exit 1; }; }
3494         fi
3495         ol_enable_translucent="$ol_arg"
3496
3497 else
3498         ol_enable_translucent=${ol_enable_overlays:-no}
3499 fi;
3500 # end --enable-translucent
3501
3502 # OpenLDAP --enable-unique
3503
3504         # Check whether --enable-unique or --disable-unique was given.
3505 if test "${enable_unique+set}" = set; then
3506   enableval="$enable_unique"
3507
3508         ol_arg=invalid
3509         for ol_val in no yes mod ; do
3510                 if test "$enableval" = "$ol_val" ; then
3511                         ol_arg="$ol_val"
3512                 fi
3513         done
3514         if test "$ol_arg" = "invalid" ; then
3515                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-unique" >&5
3516 echo "$as_me: error: bad value $enableval for --enable-unique" >&2;}
3517    { (exit 1); exit 1; }; }
3518         fi
3519         ol_enable_unique="$ol_arg"
3520
3521 else
3522         ol_enable_unique=${ol_enable_overlays:-no}
3523 fi;
3524 # end --enable-unique
3525
3526 # OpenLDAP --enable-valsort
3527
3528         # Check whether --enable-valsort or --disable-valsort was given.
3529 if test "${enable_valsort+set}" = set; then
3530   enableval="$enable_valsort"
3531
3532         ol_arg=invalid
3533         for ol_val in no yes mod ; do
3534                 if test "$enableval" = "$ol_val" ; then
3535                         ol_arg="$ol_val"
3536                 fi
3537         done
3538         if test "$ol_arg" = "invalid" ; then
3539                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-valsort" >&5
3540 echo "$as_me: error: bad value $enableval for --enable-valsort" >&2;}
3541    { (exit 1); exit 1; }; }
3542         fi
3543         ol_enable_valsort="$ol_arg"
3544
3545 else
3546         ol_enable_valsort=${ol_enable_overlays:-no}
3547 fi;
3548 # end --enable-valsort
3549
3550
3551 # Check whether --enable-xxliboptions or --disable-xxliboptions was given.
3552 if test "${enable_xxliboptions+set}" = set; then
3553   enableval="$enable_xxliboptions"
3554
3555 fi;
3556 # Check whether --enable-static or --disable-static was given.
3557 if test "${enable_static+set}" = set; then
3558   enableval="$enable_static"
3559   p=${PACKAGE-default}
3560     case $enableval in
3561     yes) enable_static=yes ;;
3562     no) enable_static=no ;;
3563     *)
3564      enable_static=no
3565       # Look at the argument we got.  We use all the common list separators.
3566       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
3567       for pkg in $enableval; do
3568         IFS="$lt_save_ifs"
3569         if test "X$pkg" = "X$p"; then
3570           enable_static=yes
3571         fi
3572       done
3573       IFS="$lt_save_ifs"
3574       ;;
3575     esac
3576 else
3577   enable_static=yes
3578 fi;
3579
3580 # Check whether --enable-shared or --disable-shared was given.
3581 if test "${enable_shared+set}" = set; then
3582   enableval="$enable_shared"
3583   p=${PACKAGE-default}
3584     case $enableval in
3585     yes) enable_shared=yes ;;
3586     no) enable_shared=no ;;
3587     *)
3588       enable_shared=no
3589       # Look at the argument we got.  We use all the common list separators.
3590       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
3591       for pkg in $enableval; do
3592         IFS="$lt_save_ifs"
3593         if test "X$pkg" = "X$p"; then
3594           enable_shared=yes
3595         fi
3596       done
3597       IFS="$lt_save_ifs"
3598       ;;
3599     esac
3600 else
3601   enable_shared=yes
3602 fi;
3603
3604
3605
3606 # validate options
3607 if test $ol_enable_slapd = no ; then
3608                 if test $ol_enable_slapi = yes ; then
3609                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-slapi argument" >&5
3610 echo "$as_me: WARNING: slapd disabled, ignoring --enable-slapi argument" >&2;}
3611         fi
3612         case "$ol_enable_backends" in yes | mod)
3613                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-backends argument" >&5
3614 echo "$as_me: WARNING: slapd disabled, ignoring --enable-backends argument" >&2;}
3615         esac
3616         for i in $Backends; do
3617                 eval "ol_tmp=\$ol_enable_$i"
3618                 if test $ol_tmp != no ; then
3619                         { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-$i argument" >&5
3620 echo "$as_me: WARNING: slapd disabled, ignoring --enable-$i argument" >&2;}
3621                         eval "ol_enable_$i=no"
3622                 fi
3623         done
3624         if test $ol_enable_modules = yes ; then
3625                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-modules argument" >&5
3626 echo "$as_me: WARNING: slapd disabled, ignoring --enable-modules argument" >&2;}
3627         fi
3628         if test $ol_enable_wrappers = yes ; then
3629                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-wrappers argument" >&5
3630 echo "$as_me: WARNING: slapd disabled, ignoring --enable-wrappers argument" >&2;}
3631         fi
3632         if test $ol_enable_rlookups = yes ; then
3633                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-rlookups argument" >&5
3634 echo "$as_me: WARNING: slapd disabled, ignoring --enable-rlookups argument" >&2;}
3635         fi
3636         if test $ol_enable_dynacl = yes ; then
3637                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-dynacl argument" >&5
3638 echo "$as_me: WARNING: slapd disabled, ignoring --enable-dynacl argument" >&2;}
3639         fi
3640         if test $ol_enable_aci != no ; then
3641                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-aci argument" >&5
3642 echo "$as_me: WARNING: slapd disabled, ignoring --enable-aci argument" >&2;}
3643         fi
3644         if test $ol_enable_rewrite = yes ; then
3645                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-rewrite argument" >&5
3646 echo "$as_me: WARNING: slapd disabled, ignoring --enable-rewrite argument" >&2;}
3647         fi
3648                 case "$ol_enable_overlays" in yes | mod)
3649                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-overlays argument" >&5
3650 echo "$as_me: WARNING: slapd disabled, ignoring --enable-overlays argument" >&2;}
3651         esac
3652         for i in $Overlays; do
3653                 eval "ol_tmp=\$ol_enable_$i"
3654                 if test $ol_tmp != no ; then
3655                         { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-$i argument" >&5
3656 echo "$as_me: WARNING: slapd disabled, ignoring --enable-$i argument" >&2;}
3657                         eval "ol_enable_$i=no"
3658                 fi
3659         done
3660
3661         # force settings to no
3662         ol_enable_slapi=no
3663
3664         ol_enable_backends=
3665         ol_enable_overlays=
3666         ol_enable_modules=no
3667         ol_enable_rlookups=no
3668         ol_enable_dynacl=no
3669         ol_enable_aci=no
3670         ol_enable_wrappers=no
3671
3672         ol_enable_rewrite=no
3673
3674 elif test $ol_enable_modules != yes &&
3675         test $ol_enable_bdb = no &&
3676         test $ol_enable_dnssrv = no &&
3677         test $ol_enable_hdb = no &&
3678         test $ol_enable_ldap = no &&
3679         test $ol_enable_meta = no &&
3680         test $ol_enable_monitor = no &&
3681         test $ol_enable_null = no &&
3682         test $ol_enable_passwd = no &&
3683         test $ol_enable_perl = no &&
3684         test $ol_enable_relay = no &&
3685         test $ol_enable_shell = no &&
3686         test $ol_enable_sql = no ; then
3687
3688         if test $ol_enable_slapd = yes ; then
3689                 { { echo "$as_me:$LINENO: error: slapd requires a backend" >&5
3690 echo "$as_me: error: slapd requires a backend" >&2;}
3691    { (exit 1); exit 1; }; }
3692         else
3693                 { echo "$as_me:$LINENO: WARNING: skipping slapd, no backend specified" >&5
3694 echo "$as_me: WARNING: skipping slapd, no backend specified" >&2;}
3695                 ol_enable_slapd=no
3696         fi
3697 fi
3698
3699 if test $ol_enable_meta/$ol_enable_ldap = yes/no ; then
3700         { { echo "$as_me:$LINENO: error: --enable-meta requires --enable-ldap" >&5
3701 echo "$as_me: error: --enable-meta requires --enable-ldap" >&2;}
3702    { (exit 1); exit 1; }; }
3703 fi
3704
3705 if test $ol_enable_lmpasswd = yes ; then
3706         if test $ol_with_tls = no ; then
3707                 { { echo "$as_me:$LINENO: error: LAN Manager passwords require OpenSSL" >&5
3708 echo "$as_me: error: LAN Manager passwords require OpenSSL" >&2;}
3709    { (exit 1); exit 1; }; }
3710         fi
3711 fi
3712
3713 if test $ol_enable_spasswd = yes ; then
3714         if test $ol_with_cyrus_sasl = no ; then
3715                 { { echo "$as_me:$LINENO: error: options require --with-cyrus-sasl" >&5
3716 echo "$as_me: error: options require --with-cyrus-sasl" >&2;}
3717    { (exit 1); exit 1; }; }
3718         fi
3719         ol_with_cyrus_sasl=yes
3720 fi
3721
3722 echo "$as_me:$LINENO: result: done" >&5
3723 echo "${ECHO_T}done" >&6
3724
3725 LDAP_LIBS=
3726 BDB_LIBS=
3727 LTHREAD_LIBS=
3728 LUTIL_LIBS=
3729
3730 SLAPD_LIBS=
3731
3732 BUILD_SLAPD=no
3733
3734 BUILD_THREAD=no
3735
3736 BUILD_SLAPI=no
3737 SLAPD_SLAPI_DEPEND=
3738
3739 BUILD_BDB=no
3740 BUILD_DNSSRV=no
3741 BUILD_HDB=no
3742 BUILD_LDAP=no
3743 BUILD_META=no
3744 BUILD_MONITOR=no
3745 BUILD_NULL=no
3746 BUILD_PASSWD=no
3747 BUILD_PERL=no
3748 BUILD_RELAY=no
3749 BUILD_SHELL=no
3750 BUILD_SQL=no
3751
3752 BUILD_ACCESSLOG=no
3753 BUILD_AUDITLOG=no
3754 BUILD_CONSTRAINT=no
3755 BUILD_DDS=no
3756 BUILD_DENYOP=no
3757 BUILD_DYNGROUP=no
3758 BUILD_DYNLIST=no
3759 BUILD_LASTMOD=no
3760 BUILD_MEMBEROF=no
3761 BUILD_PPOLICY=no
3762 BUILD_PROXYCACHE=no
3763 BUILD_REFINT=no
3764 BUILD_RETCODE=no
3765 BUILD_RWM=no
3766 BUILD_SEQMOD=no
3767 BUILD_SYNCPROV=no
3768 BUILD_TRANSLUCENT=no
3769 BUILD_UNIQUE=no
3770 BUILD_VALSORT=no
3771
3772 SLAPD_STATIC_OVERLAYS=
3773 SLAPD_DYNAMIC_OVERLAYS=
3774
3775 SLAPD_MODULES_LDFLAGS=
3776 SLAPD_MODULES_CPPFLAGS=
3777
3778 SLAPD_STATIC_BACKENDS=back-ldif
3779 SLAPD_DYNAMIC_BACKENDS=
3780
3781 SLAPD_PERL_LDFLAGS=
3782 MOD_PERL_LDFLAGS=
3783 PERL_CPPFLAGS=
3784
3785 SLAPD_SQL_LDFLAGS=
3786 SLAPD_SQL_LIBS=
3787 SLAPD_SQL_INCLUDES=
3788
3789 KRB4_LIBS=
3790 KRB5_LIBS=
3791 SASL_LIBS=
3792 TLS_LIBS=
3793 MODULES_LIBS=
3794 SLAPI_LIBS=
3795 LIBSLAPI=
3796 LIBSLAPITOOLS=
3797 AUTH_LIBS=
3798 ICU_LIBS=
3799
3800 SLAPD_SLP_LIBS=
3801 SLAPD_GMP_LIBS=
3802
3803
3804
3805 cat >>confdefs.h <<\_ACEOF
3806 #define HAVE_MKVERSION 1
3807 _ACEOF
3808
3809
3810
3811
3812 ol_aix_threads=no
3813 case "$target" in
3814 *-*-aix*)       if test -z "$CC" ; then
3815                 case "$ol_with_threads" in
3816                 auto | yes |  posix) ol_aix_threads=yes ;;
3817                 esac
3818         fi
3819 ;;
3820 esac
3821
3822 if test $ol_aix_threads = yes ; then
3823         if test -z "${CC}" ; then
3824                 for ac_prog in cc_r xlc_r cc
3825 do
3826   # Extract the first word of "$ac_prog", so it can be a program name with args.
3827 set dummy $ac_prog; ac_word=$2
3828 echo "$as_me:$LINENO: checking for $ac_word" >&5
3829 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3830 if test "${ac_cv_prog_CC+set}" = set; then
3831   echo $ECHO_N "(cached) $ECHO_C" >&6
3832 else
3833   if test -n "$CC"; then
3834   ac_cv_prog_CC="$CC" # Let the user override the test.
3835 else
3836 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3837 for as_dir in $PATH
3838 do
3839   IFS=$as_save_IFS
3840   test -z "$as_dir" && as_dir=.
3841   for ac_exec_ext in '' $ac_executable_extensions; do
3842   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3843     ac_cv_prog_CC="$ac_prog"
3844     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3845     break 2
3846   fi
3847 done
3848 done
3849
3850 fi
3851 fi
3852 CC=$ac_cv_prog_CC
3853 if test -n "$CC"; then
3854   echo "$as_me:$LINENO: result: $CC" >&5
3855 echo "${ECHO_T}$CC" >&6
3856 else
3857   echo "$as_me:$LINENO: result: no" >&5
3858 echo "${ECHO_T}no" >&6
3859 fi
3860
3861   test -n "$CC" && break
3862 done
3863
3864
3865                 if test "$CC" = cc ; then
3866                                                 if test $ol_with_threads != auto ; then
3867                                 { { echo "$as_me:$LINENO: error: --with-threads requires cc_r (or other suitable compiler) on AIX" >&5
3868 echo "$as_me: error: --with-threads requires cc_r (or other suitable compiler) on AIX" >&2;}
3869    { (exit 1); exit 1; }; }
3870                         else
3871                                 { echo "$as_me:$LINENO: WARNING: disabling threads, no cc_r on AIX" >&5
3872 echo "$as_me: WARNING: disabling threads, no cc_r on AIX" >&2;}
3873                         fi
3874                         ol_with_threads=no
3875                 fi
3876         fi
3877
3878         case ${CC} in cc_r | xlc_r)
3879                 ol_with_threads=posix
3880                 ol_cv_pthread_create=yes
3881                 ;;
3882         esac
3883 fi
3884
3885 if test -z "${CC}"; then
3886         for ac_prog in cc gcc
3887 do
3888   # Extract the first word of "$ac_prog", so it can be a program name with args.
3889 set dummy $ac_prog; ac_word=$2
3890 echo "$as_me:$LINENO: checking for $ac_word" >&5
3891 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3892 if test "${ac_cv_prog_CC+set}" = set; then
3893   echo $ECHO_N "(cached) $ECHO_C" >&6
3894 else
3895   if test -n "$CC"; then
3896   ac_cv_prog_CC="$CC" # Let the user override the test.
3897 else
3898 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3899 for as_dir in $PATH
3900 do
3901   IFS=$as_save_IFS
3902   test -z "$as_dir" && as_dir=.
3903   for ac_exec_ext in '' $ac_executable_extensions; do
3904   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3905     ac_cv_prog_CC="$ac_prog"
3906     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3907     break 2
3908   fi
3909 done
3910 done
3911
3912 fi
3913 fi
3914 CC=$ac_cv_prog_CC
3915 if test -n "$CC"; then
3916   echo "$as_me:$LINENO: result: $CC" >&5
3917 echo "${ECHO_T}$CC" >&6
3918 else
3919   echo "$as_me:$LINENO: result: no" >&5
3920 echo "${ECHO_T}no" >&6
3921 fi
3922
3923   test -n "$CC" && break
3924 done
3925 test -n "$CC" || CC="missing"
3926
3927
3928         if test "${CC}" = "missing" ; then
3929                 { { echo "$as_me:$LINENO: error: Unable to locate cc(1) or suitable replacement.  Check PATH or set CC." >&5
3930 echo "$as_me: error: Unable to locate cc(1) or suitable replacement.  Check PATH or set CC." >&2;}
3931    { (exit 1); exit 1; }; }
3932         fi
3933 fi
3934
3935 if test -z "${AR}"; then
3936         for ac_prog in ar gar
3937 do
3938   # Extract the first word of "$ac_prog", so it can be a program name with args.
3939 set dummy $ac_prog; ac_word=$2
3940 echo "$as_me:$LINENO: checking for $ac_word" >&5
3941 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3942 if test "${ac_cv_prog_AR+set}" = set; then
3943   echo $ECHO_N "(cached) $ECHO_C" >&6
3944 else
3945   if test -n "$AR"; then
3946   ac_cv_prog_AR="$AR" # Let the user override the test.
3947 else
3948 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3949 for as_dir in $PATH
3950 do
3951   IFS=$as_save_IFS
3952   test -z "$as_dir" && as_dir=.
3953   for ac_exec_ext in '' $ac_executable_extensions; do
3954   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3955     ac_cv_prog_AR="$ac_prog"
3956     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3957     break 2
3958   fi
3959 done
3960 done
3961
3962 fi
3963 fi
3964 AR=$ac_cv_prog_AR
3965 if test -n "$AR"; then
3966   echo "$as_me:$LINENO: result: $AR" >&5
3967 echo "${ECHO_T}$AR" >&6
3968 else
3969   echo "$as_me:$LINENO: result: no" >&5
3970 echo "${ECHO_T}no" >&6
3971 fi
3972
3973   test -n "$AR" && break
3974 done
3975 test -n "$AR" || AR="missing"
3976
3977
3978         if test "${AR}" = "missing" ; then
3979                 { { echo "$as_me:$LINENO: error: Unable to locate ar(1) or suitable replacement.  Check PATH or set AR." >&5
3980 echo "$as_me: error: Unable to locate ar(1) or suitable replacement.  Check PATH or set AR." >&2;}
3981    { (exit 1); exit 1; }; }
3982         fi
3983 fi
3984
3985
3986
3987
3988
3989 # Check whether --enable-fast-install or --disable-fast-install was given.
3990 if test "${enable_fast_install+set}" = set; then
3991   enableval="$enable_fast_install"
3992   p=${PACKAGE-default}
3993     case $enableval in
3994     yes) enable_fast_install=yes ;;
3995     no) enable_fast_install=no ;;
3996     *)
3997       enable_fast_install=no
3998       # Look at the argument we got.  We use all the common list separators.
3999       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
4000       for pkg in $enableval; do
4001         IFS="$lt_save_ifs"
4002         if test "X$pkg" = "X$p"; then
4003           enable_fast_install=yes
4004         fi
4005       done
4006       IFS="$lt_save_ifs"
4007       ;;
4008     esac
4009 else
4010   enable_fast_install=yes
4011 fi;
4012
4013 DEPDIR="${am__leading_dot}deps"
4014
4015           ac_config_commands="$ac_config_commands depfiles"
4016
4017
4018 am_make=${MAKE-make}
4019 cat > confinc << 'END'
4020 am__doit:
4021         @echo done
4022 .PHONY: am__doit
4023 END
4024 # If we don't find an include directive, just comment out the code.
4025 echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5
4026 echo $ECHO_N "checking for style of include used by $am_make... $ECHO_C" >&6
4027 am__include="#"
4028 am__quote=
4029 _am_result=none
4030 # First try GNU make style include.
4031 echo "include confinc" > confmf
4032 # We grep out `Entering directory' and `Leaving directory'
4033 # messages which can occur if `w' ends up in MAKEFLAGS.
4034 # In particular we don't look at `^make:' because GNU make might
4035 # be invoked under some other name (usually "gmake"), in which
4036 # case it prints its new name instead of `make'.
4037 if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
4038    am__include=include
4039    am__quote=
4040    _am_result=GNU
4041 fi
4042 # Now try BSD make style include.
4043 if test "$am__include" = "#"; then
4044    echo '.include "confinc"' > confmf
4045    if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
4046       am__include=.include
4047       am__quote="\""
4048       _am_result=BSD
4049    fi
4050 fi
4051
4052
4053 echo "$as_me:$LINENO: result: $_am_result" >&5
4054 echo "${ECHO_T}$_am_result" >&6
4055 rm -f confinc confmf
4056
4057 # Check whether --enable-dependency-tracking or --disable-dependency-tracking was given.
4058 if test "${enable_dependency_tracking+set}" = set; then
4059   enableval="$enable_dependency_tracking"
4060
4061 fi;
4062 if test "x$enable_dependency_tracking" != xno; then
4063   am_depcomp="$ac_aux_dir/depcomp"
4064   AMDEPBACKSLASH='\'
4065 fi
4066
4067
4068 if test "x$enable_dependency_tracking" != xno; then
4069   AMDEP_TRUE=
4070   AMDEP_FALSE='#'
4071 else
4072   AMDEP_TRUE='#'
4073   AMDEP_FALSE=
4074 fi
4075
4076
4077
4078 ac_ext=c
4079 ac_cpp='$CPP $CPPFLAGS'
4080 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4081 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4082 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4083 if test -n "$ac_tool_prefix"; then
4084   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4085 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4086 echo "$as_me:$LINENO: checking for $ac_word" >&5
4087 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4088 if test "${ac_cv_prog_CC+set}" = set; then
4089   echo $ECHO_N "(cached) $ECHO_C" >&6
4090 else
4091   if test -n "$CC"; then
4092   ac_cv_prog_CC="$CC" # Let the user override the test.
4093 else
4094 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4095 for as_dir in $PATH
4096 do
4097   IFS=$as_save_IFS
4098   test -z "$as_dir" && as_dir=.
4099   for ac_exec_ext in '' $ac_executable_extensions; do
4100   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4101     ac_cv_prog_CC="${ac_tool_prefix}gcc"
4102     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4103     break 2
4104   fi
4105 done
4106 done
4107
4108 fi
4109 fi
4110 CC=$ac_cv_prog_CC
4111 if test -n "$CC"; then
4112   echo "$as_me:$LINENO: result: $CC" >&5
4113 echo "${ECHO_T}$CC" >&6
4114 else
4115   echo "$as_me:$LINENO: result: no" >&5
4116 echo "${ECHO_T}no" >&6
4117 fi
4118
4119 fi
4120 if test -z "$ac_cv_prog_CC"; then
4121   ac_ct_CC=$CC
4122   # Extract the first word of "gcc", so it can be a program name with args.
4123 set dummy gcc; ac_word=$2
4124 echo "$as_me:$LINENO: checking for $ac_word" >&5
4125 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4126 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
4127   echo $ECHO_N "(cached) $ECHO_C" >&6
4128 else
4129   if test -n "$ac_ct_CC"; then
4130   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4131 else
4132 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4133 for as_dir in $PATH
4134 do
4135   IFS=$as_save_IFS
4136   test -z "$as_dir" && as_dir=.
4137   for ac_exec_ext in '' $ac_executable_extensions; do
4138   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4139     ac_cv_prog_ac_ct_CC="gcc"
4140     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4141     break 2
4142   fi
4143 done
4144 done
4145
4146 fi
4147 fi
4148 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4149 if test -n "$ac_ct_CC"; then
4150   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4151 echo "${ECHO_T}$ac_ct_CC" >&6
4152 else
4153   echo "$as_me:$LINENO: result: no" >&5
4154 echo "${ECHO_T}no" >&6
4155 fi
4156
4157   CC=$ac_ct_CC
4158 else
4159   CC="$ac_cv_prog_CC"
4160 fi
4161
4162 if test -z "$CC"; then
4163   if test -n "$ac_tool_prefix"; then
4164   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4165 set dummy ${ac_tool_prefix}cc; ac_word=$2
4166 echo "$as_me:$LINENO: checking for $ac_word" >&5
4167 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4168 if test "${ac_cv_prog_CC+set}" = set; then
4169   echo $ECHO_N "(cached) $ECHO_C" >&6
4170 else
4171   if test -n "$CC"; then
4172   ac_cv_prog_CC="$CC" # Let the user override the test.
4173 else
4174 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4175 for as_dir in $PATH
4176 do
4177   IFS=$as_save_IFS
4178   test -z "$as_dir" && as_dir=.
4179   for ac_exec_ext in '' $ac_executable_extensions; do
4180   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4181     ac_cv_prog_CC="${ac_tool_prefix}cc"
4182     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4183     break 2
4184   fi
4185 done
4186 done
4187
4188 fi
4189 fi
4190 CC=$ac_cv_prog_CC
4191 if test -n "$CC"; then
4192   echo "$as_me:$LINENO: result: $CC" >&5
4193 echo "${ECHO_T}$CC" >&6
4194 else
4195   echo "$as_me:$LINENO: result: no" >&5
4196 echo "${ECHO_T}no" >&6
4197 fi
4198
4199 fi
4200 if test -z "$ac_cv_prog_CC"; then
4201   ac_ct_CC=$CC
4202   # Extract the first word of "cc", so it can be a program name with args.
4203 set dummy cc; ac_word=$2
4204 echo "$as_me:$LINENO: checking for $ac_word" >&5
4205 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4206 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
4207   echo $ECHO_N "(cached) $ECHO_C" >&6
4208 else
4209   if test -n "$ac_ct_CC"; then
4210   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4211 else
4212 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4213 for as_dir in $PATH
4214 do
4215   IFS=$as_save_IFS
4216   test -z "$as_dir" && as_dir=.
4217   for ac_exec_ext in '' $ac_executable_extensions; do
4218   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4219     ac_cv_prog_ac_ct_CC="cc"
4220     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4221     break 2
4222   fi
4223 done
4224 done
4225
4226 fi
4227 fi
4228 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4229 if test -n "$ac_ct_CC"; then
4230   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4231 echo "${ECHO_T}$ac_ct_CC" >&6
4232 else
4233   echo "$as_me:$LINENO: result: no" >&5
4234 echo "${ECHO_T}no" >&6
4235 fi
4236
4237   CC=$ac_ct_CC
4238 else
4239   CC="$ac_cv_prog_CC"
4240 fi
4241
4242 fi
4243 if test -z "$CC"; then
4244   # Extract the first word of "cc", so it can be a program name with args.
4245 set dummy cc; ac_word=$2
4246 echo "$as_me:$LINENO: checking for $ac_word" >&5
4247 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4248 if test "${ac_cv_prog_CC+set}" = set; then
4249   echo $ECHO_N "(cached) $ECHO_C" >&6
4250 else
4251   if test -n "$CC"; then
4252   ac_cv_prog_CC="$CC" # Let the user override the test.
4253 else
4254   ac_prog_rejected=no
4255 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4256 for as_dir in $PATH
4257 do
4258   IFS=$as_save_IFS
4259   test -z "$as_dir" && as_dir=.
4260   for ac_exec_ext in '' $ac_executable_extensions; do
4261   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4262     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4263        ac_prog_rejected=yes
4264        continue
4265      fi
4266     ac_cv_prog_CC="cc"
4267     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4268     break 2
4269   fi
4270 done
4271 done
4272
4273 if test $ac_prog_rejected = yes; then
4274   # We found a bogon in the path, so make sure we never use it.
4275   set dummy $ac_cv_prog_CC
4276   shift
4277   if test $# != 0; then
4278     # We chose a different compiler from the bogus one.
4279     # However, it has the same basename, so the bogon will be chosen
4280     # first if we set CC to just the basename; use the full file name.
4281     shift
4282     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4283   fi
4284 fi
4285 fi
4286 fi
4287 CC=$ac_cv_prog_CC
4288 if test -n "$CC"; then
4289   echo "$as_me:$LINENO: result: $CC" >&5
4290 echo "${ECHO_T}$CC" >&6
4291 else
4292   echo "$as_me:$LINENO: result: no" >&5
4293 echo "${ECHO_T}no" >&6
4294 fi
4295
4296 fi
4297 if test -z "$CC"; then
4298   if test -n "$ac_tool_prefix"; then
4299   for ac_prog in cl
4300   do
4301     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4302 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4303 echo "$as_me:$LINENO: checking for $ac_word" >&5
4304 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4305 if test "${ac_cv_prog_CC+set}" = set; then
4306   echo $ECHO_N "(cached) $ECHO_C" >&6
4307 else
4308   if test -n "$CC"; then
4309   ac_cv_prog_CC="$CC" # Let the user override the test.
4310 else
4311 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4312 for as_dir in $PATH
4313 do
4314   IFS=$as_save_IFS
4315   test -z "$as_dir" && as_dir=.
4316   for ac_exec_ext in '' $ac_executable_extensions; do
4317   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4318     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4319     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4320     break 2
4321   fi
4322 done
4323 done
4324
4325 fi
4326 fi
4327 CC=$ac_cv_prog_CC
4328 if test -n "$CC"; then
4329   echo "$as_me:$LINENO: result: $CC" >&5
4330 echo "${ECHO_T}$CC" >&6
4331 else
4332   echo "$as_me:$LINENO: result: no" >&5
4333 echo "${ECHO_T}no" >&6
4334 fi
4335
4336     test -n "$CC" && break
4337   done
4338 fi
4339 if test -z "$CC"; then
4340   ac_ct_CC=$CC
4341   for ac_prog in cl
4342 do
4343   # Extract the first word of "$ac_prog", so it can be a program name with args.
4344 set dummy $ac_prog; ac_word=$2
4345 echo "$as_me:$LINENO: checking for $ac_word" >&5
4346 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4347 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
4348   echo $ECHO_N "(cached) $ECHO_C" >&6
4349 else
4350   if test -n "$ac_ct_CC"; then
4351   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4352 else
4353 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4354 for as_dir in $PATH
4355 do
4356   IFS=$as_save_IFS
4357   test -z "$as_dir" && as_dir=.
4358   for ac_exec_ext in '' $ac_executable_extensions; do
4359   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4360     ac_cv_prog_ac_ct_CC="$ac_prog"
4361     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4362     break 2
4363   fi
4364 done
4365 done
4366
4367 fi
4368 fi
4369 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4370 if test -n "$ac_ct_CC"; then
4371   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4372 echo "${ECHO_T}$ac_ct_CC" >&6
4373 else
4374   echo "$as_me:$LINENO: result: no" >&5
4375 echo "${ECHO_T}no" >&6
4376 fi
4377
4378   test -n "$ac_ct_CC" && break
4379 done
4380
4381   CC=$ac_ct_CC
4382 fi
4383
4384 fi
4385
4386
4387 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
4388 See \`config.log' for more details." >&5
4389 echo "$as_me: error: no acceptable C compiler found in \$PATH
4390 See \`config.log' for more details." >&2;}
4391    { (exit 1); exit 1; }; }
4392
4393 # Provide some information about the compiler.
4394 echo "$as_me:$LINENO:" \
4395      "checking for C compiler version" >&5
4396 ac_compiler=`set X $ac_compile; echo $2`
4397 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
4398   (eval $ac_compiler --version </dev/null >&5) 2>&5
4399   ac_status=$?
4400   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4401   (exit $ac_status); }
4402 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
4403   (eval $ac_compiler -v </dev/null >&5) 2>&5
4404   ac_status=$?
4405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4406   (exit $ac_status); }
4407 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
4408   (eval $ac_compiler -V </dev/null >&5) 2>&5
4409   ac_status=$?
4410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4411   (exit $ac_status); }
4412
4413 cat >conftest.$ac_ext <<_ACEOF
4414 /* confdefs.h.  */
4415 _ACEOF
4416 cat confdefs.h >>conftest.$ac_ext
4417 cat >>conftest.$ac_ext <<_ACEOF
4418 /* end confdefs.h.  */
4419
4420 int
4421 main ()
4422 {
4423
4424   ;
4425   return 0;
4426 }
4427 _ACEOF
4428 ac_clean_files_save=$ac_clean_files
4429 ac_clean_files="$ac_clean_files a.out a.exe b.out"
4430 # Try to create an executable without -o first, disregard a.out.
4431 # It will help us diagnose broken compilers, and finding out an intuition
4432 # of exeext.
4433 echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
4434 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
4435 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4436 if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
4437   (eval $ac_link_default) 2>&5
4438   ac_status=$?
4439   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4440   (exit $ac_status); }; then
4441   # Find the output, starting from the most likely.  This scheme is
4442 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
4443 # resort.
4444
4445 # Be careful to initialize this variable, since it used to be cached.
4446 # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
4447 ac_cv_exeext=
4448 # b.out is created by i960 compilers.
4449 for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
4450 do
4451   test -f "$ac_file" || continue
4452   case $ac_file in
4453     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
4454         ;;
4455     conftest.$ac_ext )
4456         # This is the source file.
4457         ;;
4458     [ab].out )
4459         # We found the default executable, but exeext='' is most
4460         # certainly right.
4461         break;;
4462     *.* )
4463         ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4464         # FIXME: I believe we export ac_cv_exeext for Libtool,
4465         # but it would be cool to find out if it's true.  Does anybody
4466         # maintain Libtool? --akim.
4467         export ac_cv_exeext
4468         break;;
4469     * )
4470         break;;
4471   esac
4472 done
4473 else
4474   echo "$as_me: failed program was:" >&5
4475 sed 's/^/| /' conftest.$ac_ext >&5
4476
4477 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
4478 See \`config.log' for more details." >&5
4479 echo "$as_me: error: C compiler cannot create executables
4480 See \`config.log' for more details." >&2;}
4481    { (exit 77); exit 77; }; }
4482 fi
4483
4484 ac_exeext=$ac_cv_exeext
4485 echo "$as_me:$LINENO: result: $ac_file" >&5
4486 echo "${ECHO_T}$ac_file" >&6
4487
4488 # Check the compiler produces executables we can run.  If not, either
4489 # the compiler is broken, or we cross compile.
4490 echo "$as_me:$LINENO: checking whether the C compiler works" >&5
4491 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
4492 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
4493 # If not cross compiling, check that we can run a simple program.
4494 if test "$cross_compiling" != yes; then
4495   if { ac_try='./$ac_file'
4496   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4497   (eval $ac_try) 2>&5
4498   ac_status=$?
4499   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4500   (exit $ac_status); }; }; then
4501     cross_compiling=no
4502   else
4503     if test "$cross_compiling" = maybe; then
4504         cross_compiling=yes
4505     else
4506         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
4507 If you meant to cross compile, use \`--host'.
4508 See \`config.log' for more details." >&5
4509 echo "$as_me: error: cannot run C compiled programs.
4510 If you meant to cross compile, use \`--host'.
4511 See \`config.log' for more details." >&2;}
4512    { (exit 1); exit 1; }; }
4513     fi
4514   fi
4515 fi
4516 echo "$as_me:$LINENO: result: yes" >&5
4517 echo "${ECHO_T}yes" >&6
4518
4519 rm -f a.out a.exe conftest$ac_cv_exeext b.out
4520 ac_clean_files=$ac_clean_files_save
4521 # Check the compiler produces executables we can run.  If not, either
4522 # the compiler is broken, or we cross compile.
4523 echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
4524 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
4525 echo "$as_me:$LINENO: result: $cross_compiling" >&5
4526 echo "${ECHO_T}$cross_compiling" >&6
4527
4528 echo "$as_me:$LINENO: checking for suffix of executables" >&5
4529 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
4530 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4531   (eval $ac_link) 2>&5
4532   ac_status=$?
4533   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4534   (exit $ac_status); }; then
4535   # If both `conftest.exe' and `conftest' are `present' (well, observable)
4536 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
4537 # work properly (i.e., refer to `conftest.exe'), while it won't with
4538 # `rm'.
4539 for ac_file in conftest.exe conftest conftest.*; do
4540   test -f "$ac_file" || continue
4541   case $ac_file in
4542     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
4543     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4544           export ac_cv_exeext
4545           break;;
4546     * ) break;;
4547   esac
4548 done
4549 else
4550   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
4551 See \`config.log' for more details." >&5
4552 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
4553 See \`config.log' for more details." >&2;}
4554    { (exit 1); exit 1; }; }
4555 fi
4556
4557 rm -f conftest$ac_cv_exeext
4558 echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
4559 echo "${ECHO_T}$ac_cv_exeext" >&6
4560
4561 rm -f conftest.$ac_ext
4562 EXEEXT=$ac_cv_exeext
4563 ac_exeext=$EXEEXT
4564 echo "$as_me:$LINENO: checking for suffix of object files" >&5
4565 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
4566 if test "${ac_cv_objext+set}" = set; then
4567   echo $ECHO_N "(cached) $ECHO_C" >&6
4568 else
4569   cat >conftest.$ac_ext <<_ACEOF
4570 /* confdefs.h.  */
4571 _ACEOF
4572 cat confdefs.h >>conftest.$ac_ext
4573 cat >>conftest.$ac_ext <<_ACEOF
4574 /* end confdefs.h.  */
4575
4576 int
4577 main ()
4578 {
4579
4580   ;
4581   return 0;
4582 }
4583 _ACEOF
4584 rm -f conftest.o conftest.obj
4585 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4586   (eval $ac_compile) 2>&5
4587   ac_status=$?
4588   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4589   (exit $ac_status); }; then
4590   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
4591   case $ac_file in
4592     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
4593     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4594        break;;
4595   esac
4596 done
4597 else
4598   echo "$as_me: failed program was:" >&5
4599 sed 's/^/| /' conftest.$ac_ext >&5
4600
4601 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
4602 See \`config.log' for more details." >&5
4603 echo "$as_me: error: cannot compute suffix of object files: cannot compile
4604 See \`config.log' for more details." >&2;}
4605    { (exit 1); exit 1; }; }
4606 fi
4607
4608 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4609 fi
4610 echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
4611 echo "${ECHO_T}$ac_cv_objext" >&6
4612 OBJEXT=$ac_cv_objext
4613 ac_objext=$OBJEXT
4614 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
4615 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
4616 if test "${ac_cv_c_compiler_gnu+set}" = set; then
4617   echo $ECHO_N "(cached) $ECHO_C" >&6
4618 else
4619   cat >conftest.$ac_ext <<_ACEOF
4620 /* confdefs.h.  */
4621 _ACEOF
4622 cat confdefs.h >>conftest.$ac_ext
4623 cat >>conftest.$ac_ext <<_ACEOF
4624 /* end confdefs.h.  */
4625
4626 int
4627 main ()
4628 {
4629 #ifndef __GNUC__
4630        choke me
4631 #endif
4632
4633   ;
4634   return 0;
4635 }
4636 _ACEOF
4637 rm -f conftest.$ac_objext
4638 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4639   (eval $ac_compile) 2>conftest.er1
4640   ac_status=$?
4641   grep -v '^ *+' conftest.er1 >conftest.err
4642   rm -f conftest.er1
4643   cat conftest.err >&5
4644   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4645   (exit $ac_status); } &&
4646          { ac_try='test -z "$ac_c_werror_flag"
4647                          || test ! -s conftest.err'
4648   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4649   (eval $ac_try) 2>&5
4650   ac_status=$?
4651   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4652   (exit $ac_status); }; } &&
4653          { ac_try='test -s conftest.$ac_objext'
4654   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4655   (eval $ac_try) 2>&5
4656   ac_status=$?
4657   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4658   (exit $ac_status); }; }; then
4659   ac_compiler_gnu=yes
4660 else
4661   echo "$as_me: failed program was:" >&5
4662 sed 's/^/| /' conftest.$ac_ext >&5
4663
4664 ac_compiler_gnu=no
4665 fi
4666 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4667 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4668
4669 fi
4670 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
4671 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
4672 GCC=`test $ac_compiler_gnu = yes && echo yes`
4673 ac_test_CFLAGS=${CFLAGS+set}
4674 ac_save_CFLAGS=$CFLAGS
4675 CFLAGS="-g"
4676 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
4677 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
4678 if test "${ac_cv_prog_cc_g+set}" = set; then
4679   echo $ECHO_N "(cached) $ECHO_C" >&6
4680 else
4681   cat >conftest.$ac_ext <<_ACEOF
4682 /* confdefs.h.  */
4683 _ACEOF
4684 cat confdefs.h >>conftest.$ac_ext
4685 cat >>conftest.$ac_ext <<_ACEOF
4686 /* end confdefs.h.  */
4687
4688 int
4689 main ()
4690 {
4691
4692   ;
4693   return 0;
4694 }
4695 _ACEOF
4696 rm -f conftest.$ac_objext
4697 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4698   (eval $ac_compile) 2>conftest.er1
4699   ac_status=$?
4700   grep -v '^ *+' conftest.er1 >conftest.err
4701   rm -f conftest.er1
4702   cat conftest.err >&5
4703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4704   (exit $ac_status); } &&
4705          { ac_try='test -z "$ac_c_werror_flag"
4706                          || test ! -s conftest.err'
4707   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4708   (eval $ac_try) 2>&5
4709   ac_status=$?
4710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4711   (exit $ac_status); }; } &&
4712          { ac_try='test -s conftest.$ac_objext'
4713   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4714   (eval $ac_try) 2>&5
4715   ac_status=$?
4716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4717   (exit $ac_status); }; }; then
4718   ac_cv_prog_cc_g=yes
4719 else
4720   echo "$as_me: failed program was:" >&5
4721 sed 's/^/| /' conftest.$ac_ext >&5
4722
4723 ac_cv_prog_cc_g=no
4724 fi
4725 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4726 fi
4727 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
4728 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
4729 if test "$ac_test_CFLAGS" = set; then
4730   CFLAGS=$ac_save_CFLAGS
4731 elif test $ac_cv_prog_cc_g = yes; then
4732   if test "$GCC" = yes; then
4733     CFLAGS="-g -O2"
4734   else
4735     CFLAGS="-g"
4736   fi
4737 else
4738   if test "$GCC" = yes; then
4739     CFLAGS="-O2"
4740   else
4741     CFLAGS=
4742   fi
4743 fi
4744 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
4745 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
4746 if test "${ac_cv_prog_cc_stdc+set}" = set; then
4747   echo $ECHO_N "(cached) $ECHO_C" >&6
4748 else
4749   ac_cv_prog_cc_stdc=no
4750 ac_save_CC=$CC
4751 cat >conftest.$ac_ext <<_ACEOF
4752 /* confdefs.h.  */
4753 _ACEOF
4754 cat confdefs.h >>conftest.$ac_ext
4755 cat >>conftest.$ac_ext <<_ACEOF
4756 /* end confdefs.h.  */
4757 #include <stdarg.h>
4758 #include <stdio.h>
4759 #include <sys/types.h>
4760 #include <sys/stat.h>
4761 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4762 struct buf { int x; };
4763 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4764 static char *e (p, i)
4765      char **p;
4766      int i;
4767 {
4768   return p[i];
4769 }
4770 static char *f (char * (*g) (char **, int), char **p, ...)
4771 {
4772   char *s;
4773   va_list v;
4774   va_start (v,p);
4775   s = g (p, va_arg (v,int));
4776   va_end (v);
4777   return s;
4778 }
4779
4780 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
4781    function prototypes and stuff, but not '\xHH' hex character constants.
4782    These don't provoke an error unfortunately, instead are silently treated
4783    as 'x'.  The following induces an error, until -std1 is added to get
4784    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
4785    array size at least.  It's necessary to write '\x00'==0 to get something
4786    that's true only with -std1.  */
4787 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4788
4789 int test (int i, double x);
4790 struct s1 {int (*f) (int a);};
4791 struct s2 {int (*f) (double a);};
4792 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4793 int argc;
4794 char **argv;
4795 int
4796 main ()
4797 {
4798 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4799   ;
4800   return 0;
4801 }
4802 _ACEOF
4803 # Don't try gcc -ansi; that turns off useful extensions and
4804 # breaks some systems' header files.
4805 # AIX                   -qlanglvl=ansi
4806 # Ultrix and OSF/1      -std1
4807 # HP-UX 10.20 and later -Ae
4808 # HP-UX older versions  -Aa -D_HPUX_SOURCE
4809 # SVR4                  -Xc -D__EXTENSIONS__
4810 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4811 do
4812   CC="$ac_save_CC $ac_arg"
4813   rm -f conftest.$ac_objext
4814 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4815   (eval $ac_compile) 2>conftest.er1
4816   ac_status=$?
4817   grep -v '^ *+' conftest.er1 >conftest.err
4818   rm -f conftest.er1
4819   cat conftest.err >&5
4820   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4821   (exit $ac_status); } &&
4822          { ac_try='test -z "$ac_c_werror_flag"
4823                          || test ! -s conftest.err'
4824   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4825   (eval $ac_try) 2>&5
4826   ac_status=$?
4827   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4828   (exit $ac_status); }; } &&
4829          { ac_try='test -s conftest.$ac_objext'
4830   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4831   (eval $ac_try) 2>&5
4832   ac_status=$?
4833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4834   (exit $ac_status); }; }; then
4835   ac_cv_prog_cc_stdc=$ac_arg
4836 break
4837 else
4838   echo "$as_me: failed program was:" >&5
4839 sed 's/^/| /' conftest.$ac_ext >&5
4840
4841 fi
4842 rm -f conftest.err conftest.$ac_objext
4843 done
4844 rm -f conftest.$ac_ext conftest.$ac_objext
4845 CC=$ac_save_CC
4846
4847 fi
4848
4849 case "x$ac_cv_prog_cc_stdc" in
4850   x|xno)
4851     echo "$as_me:$LINENO: result: none needed" >&5
4852 echo "${ECHO_T}none needed" >&6 ;;
4853   *)
4854     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
4855 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
4856     CC="$CC $ac_cv_prog_cc_stdc" ;;
4857 esac
4858
4859 # Some people use a C++ compiler to compile C.  Since we use `exit',
4860 # in C++ we need to declare it.  In case someone uses the same compiler
4861 # for both compiling C and C++ we need to have the C++ compiler decide
4862 # the declaration of exit, since it's the most demanding environment.
4863 cat >conftest.$ac_ext <<_ACEOF
4864 #ifndef __cplusplus
4865   choke me
4866 #endif
4867 _ACEOF
4868 rm -f conftest.$ac_objext
4869 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4870   (eval $ac_compile) 2>conftest.er1
4871   ac_status=$?
4872   grep -v '^ *+' conftest.er1 >conftest.err
4873   rm -f conftest.er1
4874   cat conftest.err >&5
4875   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4876   (exit $ac_status); } &&
4877          { ac_try='test -z "$ac_c_werror_flag"
4878                          || test ! -s conftest.err'
4879   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4880   (eval $ac_try) 2>&5
4881   ac_status=$?
4882   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4883   (exit $ac_status); }; } &&
4884          { ac_try='test -s conftest.$ac_objext'
4885   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4886   (eval $ac_try) 2>&5
4887   ac_status=$?
4888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4889   (exit $ac_status); }; }; then
4890   for ac_declaration in \
4891    '' \
4892    'extern "C" void std::exit (int) throw (); using std::exit;' \
4893    'extern "C" void std::exit (int); using std::exit;' \
4894    'extern "C" void exit (int) throw ();' \
4895    'extern "C" void exit (int);' \
4896    'void exit (int);'
4897 do
4898   cat >conftest.$ac_ext <<_ACEOF
4899 /* confdefs.h.  */
4900 _ACEOF
4901 cat confdefs.h >>conftest.$ac_ext
4902 cat >>conftest.$ac_ext <<_ACEOF
4903 /* end confdefs.h.  */
4904 $ac_declaration
4905 #include <stdlib.h>
4906 int
4907 main ()
4908 {
4909 exit (42);
4910   ;
4911   return 0;
4912 }
4913 _ACEOF
4914 rm -f conftest.$ac_objext
4915 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4916   (eval $ac_compile) 2>conftest.er1
4917   ac_status=$?
4918   grep -v '^ *+' conftest.er1 >conftest.err
4919   rm -f conftest.er1
4920   cat conftest.err >&5
4921   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4922   (exit $ac_status); } &&
4923          { ac_try='test -z "$ac_c_werror_flag"
4924                          || test ! -s conftest.err'
4925   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4926   (eval $ac_try) 2>&5
4927   ac_status=$?
4928   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4929   (exit $ac_status); }; } &&
4930          { ac_try='test -s conftest.$ac_objext'
4931   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4932   (eval $ac_try) 2>&5
4933   ac_status=$?
4934   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4935   (exit $ac_status); }; }; then
4936   :
4937 else
4938   echo "$as_me: failed program was:" >&5
4939 sed 's/^/| /' conftest.$ac_ext >&5
4940
4941 continue
4942 fi
4943 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4944   cat >conftest.$ac_ext <<_ACEOF
4945 /* confdefs.h.  */
4946 _ACEOF
4947 cat confdefs.h >>conftest.$ac_ext
4948 cat >>conftest.$ac_ext <<_ACEOF
4949 /* end confdefs.h.  */
4950 $ac_declaration
4951 int
4952 main ()
4953 {
4954 exit (42);
4955   ;
4956   return 0;
4957 }
4958 _ACEOF
4959 rm -f conftest.$ac_objext
4960 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4961   (eval $ac_compile) 2>conftest.er1
4962   ac_status=$?
4963   grep -v '^ *+' conftest.er1 >conftest.err
4964   rm -f conftest.er1
4965   cat conftest.err >&5
4966   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4967   (exit $ac_status); } &&
4968          { ac_try='test -z "$ac_c_werror_flag"
4969                          || test ! -s conftest.err'
4970   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4971   (eval $ac_try) 2>&5
4972   ac_status=$?
4973   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4974   (exit $ac_status); }; } &&
4975          { ac_try='test -s conftest.$ac_objext'
4976   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4977   (eval $ac_try) 2>&5
4978   ac_status=$?
4979   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4980   (exit $ac_status); }; }; then
4981   break
4982 else
4983   echo "$as_me: failed program was:" >&5
4984 sed 's/^/| /' conftest.$ac_ext >&5
4985
4986 fi
4987 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4988 done
4989 rm -f conftest*
4990 if test -n "$ac_declaration"; then
4991   echo '#ifdef __cplusplus' >>confdefs.h
4992   echo $ac_declaration      >>confdefs.h
4993   echo '#endif'             >>confdefs.h
4994 fi
4995
4996 else
4997   echo "$as_me: failed program was:" >&5
4998 sed 's/^/| /' conftest.$ac_ext >&5
4999
5000 fi
5001 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5002 ac_ext=c
5003 ac_cpp='$CPP $CPPFLAGS'
5004 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5005 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5006 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5007
5008 depcc="$CC"   am_compiler_list=
5009
5010 echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
5011 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6
5012 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
5013   echo $ECHO_N "(cached) $ECHO_C" >&6
5014 else
5015   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5016   # We make a subdir and do the tests there.  Otherwise we can end up
5017   # making bogus files that we don't know about and never remove.  For
5018   # instance it was reported that on HP-UX the gcc test will end up
5019   # making a dummy file named `D' -- because `-MD' means `put the output
5020   # in D'.
5021   mkdir conftest.dir
5022   # Copy depcomp to subdir because otherwise we won't find it if we're
5023   # using a relative directory.
5024   cp "$am_depcomp" conftest.dir
5025   cd conftest.dir
5026   # We will build objects and dependencies in a subdirectory because
5027   # it helps to detect inapplicable dependency modes.  For instance
5028   # both Tru64's cc and ICC support -MD to output dependencies as a
5029   # side effect of compilation, but ICC will put the dependencies in
5030   # the current directory while Tru64 will put them in the object
5031   # directory.
5032   mkdir sub
5033
5034   am_cv_CC_dependencies_compiler_type=none
5035   if test "$am_compiler_list" = ""; then
5036      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5037   fi
5038   for depmode in $am_compiler_list; do
5039     # Setup a source with many dependencies, because some compilers
5040     # like to wrap large dependency lists on column 80 (with \), and
5041     # we should not choose a depcomp mode which is confused by this.
5042     #
5043     # We need to recreate these files for each test, as the compiler may
5044     # overwrite some of them when testing with obscure command lines.
5045     # This happens at least with the AIX C compiler.
5046     : > sub/conftest.c
5047     for i in 1 2 3 4 5 6; do
5048       echo '#include "conftst'$i'.h"' >> sub/conftest.c
5049       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5050       # Solaris 8's {/usr,}/bin/sh.
5051       touch sub/conftst$i.h
5052     done
5053     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5054
5055     case $depmode in
5056     nosideeffect)
5057       # after this tag, mechanisms are not by side-effect, so they'll
5058       # only be used when explicitly requested
5059       if test "x$enable_dependency_tracking" = xyes; then
5060         continue
5061       else
5062         break
5063       fi
5064       ;;
5065     none) break ;;
5066     esac
5067     # We check with `-c' and `-o' for the sake of the "dashmstdout"
5068     # mode.  It turns out that the SunPro C++ compiler does not properly
5069     # handle `-M -o', and we need to detect this.
5070     if depmode=$depmode \
5071        source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
5072        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5073        $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
5074          >/dev/null 2>conftest.err &&
5075        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5076        grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
5077        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5078       # icc doesn't choke on unknown options, it will just issue warnings
5079       # or remarks (even with -Werror).  So we grep stderr for any message
5080       # that says an option was ignored or not supported.
5081       # When given -MP, icc 7.0 and 7.1 complain thusly:
5082       #   icc: Command line warning: ignoring option '-M'; no argument required
5083       # The diagnosis changed in icc 8.0:
5084       #   icc: Command line remark: option '-MP' not supported
5085       if (grep 'ignoring option' conftest.err ||
5086           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5087         am_cv_CC_dependencies_compiler_type=$depmode
5088         break
5089       fi
5090     fi
5091   done
5092
5093   cd ..
5094   rm -rf conftest.dir
5095 else
5096   am_cv_CC_dependencies_compiler_type=none
5097 fi
5098
5099 fi
5100 echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
5101 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6
5102 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5103
5104
5105
5106 if
5107   test "x$enable_dependency_tracking" != xno \
5108   && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5109   am__fastdepCC_TRUE=
5110   am__fastdepCC_FALSE='#'
5111 else
5112   am__fastdepCC_TRUE='#'
5113   am__fastdepCC_FALSE=
5114 fi
5115
5116
5117 echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5
5118 echo $ECHO_N "checking for a sed that does not truncate output... $ECHO_C" >&6
5119 if test "${lt_cv_path_SED+set}" = set; then
5120   echo $ECHO_N "(cached) $ECHO_C" >&6
5121 else
5122   # Loop through the user's path and test for sed and gsed.
5123 # Then use that list of sed's as ones to test for truncation.
5124 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5125 for as_dir in $PATH
5126 do
5127   IFS=$as_save_IFS
5128   test -z "$as_dir" && as_dir=.
5129   for lt_ac_prog in sed gsed; do
5130     for ac_exec_ext in '' $ac_executable_extensions; do
5131       if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
5132         lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
5133       fi
5134     done
5135   done
5136 done
5137 lt_ac_max=0
5138 lt_ac_count=0
5139 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
5140 # along with /bin/sed that truncates output.
5141 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
5142   test ! -f $lt_ac_sed && continue
5143   cat /dev/null > conftest.in
5144   lt_ac_count=0
5145   echo $ECHO_N "0123456789$ECHO_C" >conftest.in
5146   # Check for GNU sed and select it if it is found.
5147   if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
5148     lt_cv_path_SED=$lt_ac_sed
5149     break
5150   fi
5151   while true; do
5152     cat conftest.in conftest.in >conftest.tmp
5153     mv conftest.tmp conftest.in
5154     cp conftest.in conftest.nl
5155     echo >>conftest.nl
5156     $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
5157     cmp -s conftest.out conftest.nl || break
5158     # 10000 chars as input seems more than enough
5159     test $lt_ac_count -gt 10 && break
5160     lt_ac_count=`expr $lt_ac_count + 1`
5161     if test $lt_ac_count -gt $lt_ac_max; then
5162       lt_ac_max=$lt_ac_count
5163       lt_cv_path_SED=$lt_ac_sed
5164     fi
5165   done
5166 done
5167
5168 fi
5169
5170 SED=$lt_cv_path_SED
5171 echo "$as_me:$LINENO: result: $SED" >&5
5172 echo "${ECHO_T}$SED" >&6
5173
5174 echo "$as_me:$LINENO: checking for egrep" >&5
5175 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
5176 if test "${ac_cv_prog_egrep+set}" = set; then
5177   echo $ECHO_N "(cached) $ECHO_C" >&6
5178 else
5179   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
5180     then ac_cv_prog_egrep='grep -E'
5181     else ac_cv_prog_egrep='egrep'
5182     fi
5183 fi
5184 echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
5185 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
5186  EGREP=$ac_cv_prog_egrep
5187
5188
5189
5190 # Check whether --with-gnu-ld or --without-gnu-ld was given.
5191 if test "${with_gnu_ld+set}" = set; then
5192   withval="$with_gnu_ld"
5193   test "$withval" = no || with_gnu_ld=yes
5194 else
5195   with_gnu_ld=no
5196 fi;
5197 ac_prog=ld
5198 if test "$GCC" = yes; then
5199   # Check if gcc -print-prog-name=ld gives a path.
5200   echo "$as_me:$LINENO: checking for ld used by $CC" >&5
5201 echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6
5202   case $host in
5203   *-*-mingw*)
5204     # gcc leaves a trailing carriage return which upsets mingw
5205     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
5206   *)
5207     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
5208   esac
5209   case $ac_prog in
5210     # Accept absolute paths.
5211     [\\/]* | ?:[\\/]*)
5212       re_direlt='/[^/][^/]*/\.\./'
5213       # Canonicalize the pathname of ld
5214       ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
5215       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
5216         ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
5217       done
5218       test -z "$LD" && LD="$ac_prog"
5219       ;;
5220   "")
5221     # If it fails, then pretend we aren't using GCC.
5222     ac_prog=ld
5223     ;;
5224   *)
5225     # If it is relative, then search for the first ld in PATH.
5226     with_gnu_ld=unknown
5227     ;;
5228   esac
5229 elif test "$with_gnu_ld" = yes; then
5230   echo "$as_me:$LINENO: checking for GNU ld" >&5
5231 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
5232 else
5233   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
5234 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
5235 fi
5236 if test "${lt_cv_path_LD+set}" = set; then
5237   echo $ECHO_N "(cached) $ECHO_C" >&6
5238 else
5239   if test -z "$LD"; then
5240   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
5241   for ac_dir in $PATH; do
5242     IFS="$lt_save_ifs"
5243     test -z "$ac_dir" && ac_dir=.
5244     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
5245       lt_cv_path_LD="$ac_dir/$ac_prog"
5246       # Check to see if the program is GNU ld.  I'd rather use --version,
5247       # but apparently some variants of GNU ld only accept -v.
5248       # Break only if it was the GNU/non-GNU ld that we prefer.
5249       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
5250       *GNU* | *'with BFD'*)
5251         test "$with_gnu_ld" != no && break
5252         ;;
5253       *)
5254         test "$with_gnu_ld" != yes && break
5255         ;;
5256       esac
5257     fi
5258   done
5259   IFS="$lt_save_ifs"
5260 else
5261   lt_cv_path_LD="$LD" # Let the user override the test with a path.
5262 fi
5263 fi
5264
5265 LD="$lt_cv_path_LD"
5266 if test -n "$LD"; then
5267   echo "$as_me:$LINENO: result: $LD" >&5
5268 echo "${ECHO_T}$LD" >&6
5269 else
5270   echo "$as_me:$LINENO: result: no" >&5
5271 echo "${ECHO_T}no" >&6
5272 fi
5273 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
5274 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
5275    { (exit 1); exit 1; }; }
5276 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
5277 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
5278 if test "${lt_cv_prog_gnu_ld+set}" = set; then
5279   echo $ECHO_N "(cached) $ECHO_C" >&6
5280 else
5281   # I'd rather use --version here, but apparently some GNU lds only accept -v.
5282 case `$LD -v 2>&1 </dev/null` in
5283 *GNU* | *'with BFD'*)
5284   lt_cv_prog_gnu_ld=yes
5285   ;;
5286 *)
5287   lt_cv_prog_gnu_ld=no
5288   ;;
5289 esac
5290 fi
5291 echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
5292 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6
5293 with_gnu_ld=$lt_cv_prog_gnu_ld
5294
5295
5296 echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5
5297 echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6
5298 if test "${lt_cv_ld_reload_flag+set}" = set; then
5299   echo $ECHO_N "(cached) $ECHO_C" >&6
5300 else
5301   lt_cv_ld_reload_flag='-r'
5302 fi
5303 echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5
5304 echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6
5305 reload_flag=$lt_cv_ld_reload_flag
5306 case $reload_flag in
5307 "" | " "*) ;;
5308 *) reload_flag=" $reload_flag" ;;
5309 esac
5310 reload_cmds='$LD$reload_flag -o $output$reload_objs'
5311 case $host_os in
5312   darwin*)
5313     if test "$GCC" = yes; then
5314       reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs'
5315     else
5316       reload_cmds='$LD$reload_flag -o $output$reload_objs'
5317     fi
5318     ;;
5319 esac
5320
5321 echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
5322 echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6
5323 if test "${lt_cv_path_NM+set}" = set; then
5324   echo $ECHO_N "(cached) $ECHO_C" >&6
5325 else
5326   if test -n "$NM"; then
5327   # Let the user override the test.
5328   lt_cv_path_NM="$NM"
5329 else
5330   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
5331   for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
5332     IFS="$lt_save_ifs"
5333     test -z "$ac_dir" && ac_dir=.
5334     tmp_nm="$ac_dir/${ac_tool_prefix}nm"
5335     if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
5336       # Check to see if the nm accepts a BSD-compat flag.
5337       # Adding the `sed 1q' prevents false positives on HP-UX, which says:
5338       #   nm: unknown option "B" ignored
5339       # Tru64's nm complains that /dev/null is an invalid object file
5340       case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
5341       */dev/null* | *'Invalid file or object type'*)
5342         lt_cv_path_NM="$tmp_nm -B"
5343         break
5344         ;;
5345       *)
5346         case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
5347         */dev/null*)
5348           lt_cv_path_NM="$tmp_nm -p"
5349           break
5350           ;;
5351         *)
5352           lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
5353           continue # so that we can try to find one that supports BSD flags
5354           ;;
5355         esac
5356       esac
5357     fi
5358   done
5359   IFS="$lt_save_ifs"
5360   test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
5361 fi
5362 fi
5363 echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5
5364 echo "${ECHO_T}$lt_cv_path_NM" >&6
5365 NM="$lt_cv_path_NM"
5366
5367 echo "$as_me:$LINENO: checking whether ln -s works" >&5
5368 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
5369 LN_S=$as_ln_s
5370 if test "$LN_S" = "ln -s"; then
5371   echo "$as_me:$LINENO: result: yes" >&5
5372 echo "${ECHO_T}yes" >&6
5373 else
5374   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
5375 echo "${ECHO_T}no, using $LN_S" >&6
5376 fi
5377
5378 echo "$as_me:$LINENO: checking how to recognise dependent libraries" >&5
5379 echo $ECHO_N "checking how to recognise dependent libraries... $ECHO_C" >&6
5380 if test "${lt_cv_deplibs_check_method+set}" = set; then
5381   echo $ECHO_N "(cached) $ECHO_C" >&6
5382 else
5383   lt_cv_file_magic_cmd='$MAGIC_CMD'
5384 lt_cv_file_magic_test_file=
5385 lt_cv_deplibs_check_method='unknown'
5386 # Need to set the preceding variable on all platforms that support
5387 # interlibrary dependencies.
5388 # 'none' -- dependencies not supported.
5389 # `unknown' -- same as none, but documents that we really don't know.
5390 # 'pass_all' -- all dependencies passed with no checks.
5391 # 'test_compile' -- check by making test program.
5392 # 'file_magic [[regex]]' -- check by looking for files in library path
5393 # which responds to the $file_magic_cmd with a given extended regex.
5394 # If you have `file' or equivalent on your system and you're not sure
5395 # whether `pass_all' will *always* work, you probably want this one.
5396
5397 case $host_os in
5398 aix4* | aix5*)
5399   lt_cv_deplibs_check_method=pass_all
5400   ;;
5401
5402 beos*)
5403   lt_cv_deplibs_check_method=pass_all
5404   ;;
5405
5406 bsdi[45]*)
5407   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
5408   lt_cv_file_magic_cmd='/usr/bin/file -L'
5409   lt_cv_file_magic_test_file=/shlib/libc.so
5410   ;;
5411
5412 cygwin*)
5413   # func_win32_libid is a shell function defined in ltmain.sh
5414   lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
5415   lt_cv_file_magic_cmd='func_win32_libid'
5416   ;;
5417
5418 mingw* | pw32*)
5419   # Base MSYS/MinGW do not provide the 'file' command needed by
5420   # func_win32_libid shell function, so use a weaker test based on 'objdump'.
5421   lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
5422   lt_cv_file_magic_cmd='$OBJDUMP -f'
5423   ;;
5424
5425 darwin* | rhapsody*)
5426   lt_cv_deplibs_check_method=pass_all
5427   ;;
5428
5429 freebsd* | kfreebsd*-gnu | dragonfly*)
5430   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
5431     case $host_cpu in
5432     i*86 )
5433       # Not sure whether the presence of OpenBSD here was a mistake.
5434       # Let's accept both of them until this is cleared up.
5435       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
5436       lt_cv_file_magic_cmd=/usr/bin/file
5437       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
5438       ;;
5439     esac
5440   else
5441     lt_cv_deplibs_check_method=pass_all
5442   fi
5443   ;;
5444
5445 gnu*)
5446   lt_cv_deplibs_check_method=pass_all
5447   ;;
5448
5449 hpux10.20* | hpux11*)
5450   lt_cv_file_magic_cmd=/usr/bin/file
5451   case $host_cpu in
5452   ia64*)
5453     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
5454     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
5455     ;;
5456   hppa*64*)
5457     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]'
5458     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
5459     ;;
5460   *)
5461     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
5462     lt_cv_file_magic_test_file=/usr/lib/libc.sl
5463     ;;
5464   esac
5465   ;;
5466
5467 irix5* | irix6* | nonstopux*)
5468   case $LD in
5469   *-32|*"-32 ") libmagic=32-bit;;
5470   *-n32|*"-n32 ") libmagic=N32;;
5471   *-64|*"-64 ") libmagic=64-bit;;
5472   *) libmagic=never-match;;
5473   esac
5474   lt_cv_deplibs_check_method=pass_all
5475   ;;
5476
5477 # This must be Linux ELF.
5478 linux*)
5479   lt_cv_deplibs_check_method=pass_all
5480   ;;
5481
5482 netbsd*)
5483   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
5484     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5485   else
5486     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
5487   fi
5488   ;;
5489
5490 newos6*)
5491   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
5492   lt_cv_file_magic_cmd=/usr/bin/file
5493   lt_cv_file_magic_test_file=/usr/lib/libnls.so
5494   ;;
5495
5496 nto-qnx*)
5497   lt_cv_deplibs_check_method=unknown
5498   ;;
5499
5500 openbsd*)
5501   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5502     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
5503   else
5504     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5505   fi
5506   ;;
5507
5508 osf3* | osf4* | osf5*)
5509   lt_cv_deplibs_check_method=pass_all
5510   ;;
5511
5512 sco3.2v5*)
5513   lt_cv_deplibs_check_method=pass_all
5514   ;;
5515
5516 solaris*)
5517   lt_cv_deplibs_check_method=pass_all
5518   ;;
5519
5520 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5521   case $host_vendor in
5522   motorola)
5523     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]'
5524     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
5525     ;;
5526   ncr)
5527     lt_cv_deplibs_check_method=pass_all
5528     ;;
5529   sequent)
5530     lt_cv_file_magic_cmd='/bin/file'
5531     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
5532     ;;
5533   sni)
5534     lt_cv_file_magic_cmd='/bin/file'
5535     lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
5536     lt_cv_file_magic_test_file=/lib/libc.so
5537     ;;
5538   siemens)
5539     lt_cv_deplibs_check_method=pass_all
5540     ;;
5541   esac
5542   ;;
5543
5544 sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7* | sysv4*uw2*)
5545   lt_cv_deplibs_check_method=pass_all
5546   ;;
5547 esac
5548
5549 fi
5550 echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5
5551 echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6
5552 file_magic_cmd=$lt_cv_file_magic_cmd
5553 deplibs_check_method=$lt_cv_deplibs_check_method
5554 test -z "$deplibs_check_method" && deplibs_check_method=unknown
5555
5556
5557
5558
5559 # If no C compiler was specified, use CC.
5560 LTCC=${LTCC-"$CC"}
5561
5562 # Allow CC to be a program name with arguments.
5563 compiler=$CC
5564
5565
5566 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
5567 if test "${enable_libtool_lock+set}" = set; then
5568   enableval="$enable_libtool_lock"
5569
5570 fi;
5571 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
5572
5573 # Some flags need to be propagated to the compiler or linker for good
5574 # libtool support.
5575 case $host in
5576 ia64-*-hpux*)
5577   # Find out which ABI we are using.
5578   echo 'int i;' > conftest.$ac_ext
5579   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5580   (eval $ac_compile) 2>&5
5581   ac_status=$?
5582   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5583   (exit $ac_status); }; then
5584     case `/usr/bin/file conftest.$ac_objext` in
5585     *ELF-32*)
5586       HPUX_IA64_MODE="32"
5587       ;;
5588     *ELF-64*)
5589       HPUX_IA64_MODE="64"
5590       ;;
5591     esac
5592   fi
5593   rm -rf conftest*
5594   ;;
5595 *-*-irix6*)
5596   # Find out which ABI we are using.
5597   echo '#line 5597 "configure"' > conftest.$ac_ext
5598   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5599   (eval $ac_compile) 2>&5
5600   ac_status=$?
5601   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5602   (exit $ac_status); }; then
5603    if test "$lt_cv_prog_gnu_ld" = yes; then
5604     case `/usr/bin/file conftest.$ac_objext` in
5605     *32-bit*)
5606       LD="${LD-ld} -melf32bsmip"
5607       ;;
5608     *N32*)
5609       LD="${LD-ld} -melf32bmipn32"
5610       ;;
5611     *64-bit*)
5612       LD="${LD-ld} -melf64bmip"
5613       ;;
5614     esac
5615    else
5616     case `/usr/bin/file conftest.$ac_objext` in
5617     *32-bit*)
5618       LD="${LD-ld} -32"
5619       ;;
5620     *N32*)
5621       LD="${LD-ld} -n32"
5622       ;;
5623     *64-bit*)
5624       LD="${LD-ld} -64"
5625       ;;
5626     esac
5627    fi
5628   fi
5629   rm -rf conftest*
5630   ;;
5631
5632 x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
5633   # Find out which ABI we are using.
5634   echo 'int i;' > conftest.$ac_ext
5635   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5636   (eval $ac_compile) 2>&5
5637   ac_status=$?
5638   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5639   (exit $ac_status); }; then
5640     case `/usr/bin/file conftest.o` in
5641     *32-bit*)
5642       case $host in
5643         x86_64-*linux*)
5644           LD="${LD-ld} -m elf_i386"
5645           ;;
5646         ppc64-*linux*|powerpc64-*linux*)
5647           LD="${LD-ld} -m elf32ppclinux"
5648           ;;
5649         s390x-*linux*)
5650           LD="${LD-ld} -m elf_s390"
5651           ;;
5652         sparc64-*linux*)
5653           LD="${LD-ld} -m elf32_sparc"
5654           ;;
5655       esac
5656       ;;
5657     *64-bit*)
5658       case $host in
5659         x86_64-*linux*)
5660           LD="${LD-ld} -m elf_x86_64"
5661           ;;
5662         ppc*-*linux*|powerpc*-*linux*)
5663           LD="${LD-ld} -m elf64ppc"
5664           ;;
5665         s390*-*linux*)
5666           LD="${LD-ld} -m elf64_s390"
5667           ;;
5668         sparc*-*linux*)
5669           LD="${LD-ld} -m elf64_sparc"
5670           ;;
5671       esac
5672       ;;
5673     esac
5674   fi
5675   rm -rf conftest*
5676   ;;
5677
5678 *-*-sco3.2v5*)
5679   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
5680   SAVE_CFLAGS="$CFLAGS"
5681   CFLAGS="$CFLAGS -belf"
5682   echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5
5683 echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6
5684 if test "${lt_cv_cc_needs_belf+set}" = set; then
5685   echo $ECHO_N "(cached) $ECHO_C" >&6
5686 else
5687   ac_ext=c
5688 ac_cpp='$CPP $CPPFLAGS'
5689 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5690 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5691 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5692
5693      cat >conftest.$ac_ext <<_ACEOF
5694 /* confdefs.h.  */
5695 _ACEOF
5696 cat confdefs.h >>conftest.$ac_ext
5697 cat >>conftest.$ac_ext <<_ACEOF
5698 /* end confdefs.h.  */
5699
5700 int
5701 main ()
5702 {
5703
5704   ;
5705   return 0;
5706 }
5707 _ACEOF
5708 rm -f conftest.$ac_objext conftest$ac_exeext
5709 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5710   (eval $ac_link) 2>conftest.er1
5711   ac_status=$?
5712   grep -v '^ *+' conftest.er1 >conftest.err
5713   rm -f conftest.er1
5714   cat conftest.err >&5
5715   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5716   (exit $ac_status); } &&
5717          { ac_try='test -z "$ac_c_werror_flag"
5718                          || test ! -s conftest.err'
5719   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5720   (eval $ac_try) 2>&5
5721   ac_status=$?
5722   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5723   (exit $ac_status); }; } &&
5724          { ac_try='test -s conftest$ac_exeext'
5725   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5726   (eval $ac_try) 2>&5
5727   ac_status=$?
5728   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5729   (exit $ac_status); }; }; then
5730   lt_cv_cc_needs_belf=yes
5731 else
5732   echo "$as_me: failed program was:" >&5
5733 sed 's/^/| /' conftest.$ac_ext >&5
5734
5735 lt_cv_cc_needs_belf=no
5736 fi
5737 rm -f conftest.err conftest.$ac_objext \
5738       conftest$ac_exeext conftest.$ac_ext
5739      ac_ext=c
5740 ac_cpp='$CPP $CPPFLAGS'
5741 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5742 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5743 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5744
5745 fi
5746 echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5
5747 echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6
5748   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
5749     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
5750     CFLAGS="$SAVE_CFLAGS"
5751   fi
5752   ;;
5753 *-*-cygwin* | *-*-mingw* | *-*-pw32*)
5754   if test -n "$ac_tool_prefix"; then
5755   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
5756 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
5757 echo "$as_me:$LINENO: checking for $ac_word" >&5
5758 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5759 if test "${ac_cv_prog_DLLTOOL+set}" = set; then
5760   echo $ECHO_N "(cached) $ECHO_C" >&6
5761 else
5762   if test -n "$DLLTOOL"; then
5763   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
5764 else
5765 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5766 for as_dir in $PATH
5767 do
5768   IFS=$as_save_IFS
5769   test -z "$as_dir" && as_dir=.
5770   for ac_exec_ext in '' $ac_executable_extensions; do
5771   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5772     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
5773     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5774     break 2
5775   fi
5776 done
5777 done
5778
5779 fi
5780 fi
5781 DLLTOOL=$ac_cv_prog_DLLTOOL
5782 if test -n "$DLLTOOL"; then
5783   echo "$as_me:$LINENO: result: $DLLTOOL" >&5
5784 echo "${ECHO_T}$DLLTOOL" >&6
5785 else
5786   echo "$as_me:$LINENO: result: no" >&5
5787 echo "${ECHO_T}no" >&6
5788 fi
5789
5790 fi
5791 if test -z "$ac_cv_prog_DLLTOOL"; then
5792   ac_ct_DLLTOOL=$DLLTOOL
5793   # Extract the first word of "dlltool", so it can be a program name with args.
5794 set dummy dlltool; ac_word=$2
5795 echo "$as_me:$LINENO: checking for $ac_word" >&5
5796 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5797 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
5798   echo $ECHO_N "(cached) $ECHO_C" >&6
5799 else
5800   if test -n "$ac_ct_DLLTOOL"; then
5801   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
5802 else
5803 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5804 for as_dir in $PATH
5805 do
5806   IFS=$as_save_IFS
5807   test -z "$as_dir" && as_dir=.
5808   for ac_exec_ext in '' $ac_executable_extensions; do
5809   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5810     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
5811     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5812     break 2
5813   fi
5814 done
5815 done
5816
5817   test -z "$ac_cv_prog_ac_ct_DLLTOOL" && ac_cv_prog_ac_ct_DLLTOOL="false"
5818 fi
5819 fi
5820 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
5821 if test -n "$ac_ct_DLLTOOL"; then
5822   echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
5823 echo "${ECHO_T}$ac_ct_DLLTOOL" >&6
5824 else
5825   echo "$as_me:$LINENO: result: no" >&5
5826 echo "${ECHO_T}no" >&6
5827 fi
5828
5829   DLLTOOL=$ac_ct_DLLTOOL
5830 else
5831   DLLTOOL="$ac_cv_prog_DLLTOOL"
5832 fi
5833
5834   if test -n "$ac_tool_prefix"; then
5835   # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
5836 set dummy ${ac_tool_prefix}as; ac_word=$2
5837 echo "$as_me:$LINENO: checking for $ac_word" >&5
5838 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5839 if test "${ac_cv_prog_AS+set}" = set; then
5840   echo $ECHO_N "(cached) $ECHO_C" >&6
5841 else
5842   if test -n "$AS"; then
5843   ac_cv_prog_AS="$AS" # Let the user override the test.
5844 else
5845 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5846 for as_dir in $PATH
5847 do
5848   IFS=$as_save_IFS
5849   test -z "$as_dir" && as_dir=.
5850   for ac_exec_ext in '' $ac_executable_extensions; do
5851   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5852     ac_cv_prog_AS="${ac_tool_prefix}as"
5853     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5854     break 2
5855   fi
5856 done
5857 done
5858
5859 fi
5860 fi
5861 AS=$ac_cv_prog_AS
5862 if test -n "$AS"; then
5863   echo "$as_me:$LINENO: result: $AS" >&5
5864 echo "${ECHO_T}$AS" >&6
5865 else
5866   echo "$as_me:$LINENO: result: no" >&5
5867 echo "${ECHO_T}no" >&6
5868 fi
5869
5870 fi
5871 if test -z "$ac_cv_prog_AS"; then
5872   ac_ct_AS=$AS
5873   # Extract the first word of "as", so it can be a program name with args.
5874 set dummy as; ac_word=$2
5875 echo "$as_me:$LINENO: checking for $ac_word" >&5
5876 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5877 if test "${ac_cv_prog_ac_ct_AS+set}" = set; then
5878   echo $ECHO_N "(cached) $ECHO_C" >&6
5879 else
5880   if test -n "$ac_ct_AS"; then
5881   ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test.
5882 else
5883 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5884 for as_dir in $PATH
5885 do
5886   IFS=$as_save_IFS
5887   test -z "$as_dir" && as_dir=.
5888   for ac_exec_ext in '' $ac_executable_extensions; do
5889   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5890     ac_cv_prog_ac_ct_AS="as"
5891     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5892     break 2
5893   fi
5894 done
5895 done
5896
5897   test -z "$ac_cv_prog_ac_ct_AS" && ac_cv_prog_ac_ct_AS="false"
5898 fi
5899 fi
5900 ac_ct_AS=$ac_cv_prog_ac_ct_AS
5901 if test -n "$ac_ct_AS"; then
5902   echo "$as_me:$LINENO: result: $ac_ct_AS" >&5
5903 echo "${ECHO_T}$ac_ct_AS" >&6
5904 else
5905   echo "$as_me:$LINENO: result: no" >&5
5906 echo "${ECHO_T}no" >&6
5907 fi
5908
5909   AS=$ac_ct_AS
5910 else
5911   AS="$ac_cv_prog_AS"
5912 fi
5913
5914   if test -n "$ac_tool_prefix"; then
5915   # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
5916 set dummy ${ac_tool_prefix}objdump; ac_word=$2
5917 echo "$as_me:$LINENO: checking for $ac_word" >&5
5918 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5919 if test "${ac_cv_prog_OBJDUMP+set}" = set; then
5920   echo $ECHO_N "(cached) $ECHO_C" >&6
5921 else
5922   if test -n "$OBJDUMP"; then
5923   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
5924 else
5925 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5926 for as_dir in $PATH
5927 do
5928   IFS=$as_save_IFS
5929   test -z "$as_dir" && as_dir=.
5930   for ac_exec_ext in '' $ac_executable_extensions; do
5931   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5932     ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
5933     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5934     break 2
5935   fi
5936 done
5937 done
5938
5939 fi
5940 fi
5941 OBJDUMP=$ac_cv_prog_OBJDUMP
5942 if test -n "$OBJDUMP"; then
5943   echo "$as_me:$LINENO: result: $OBJDUMP" >&5
5944 echo "${ECHO_T}$OBJDUMP" >&6
5945 else
5946   echo "$as_me:$LINENO: result: no" >&5
5947 echo "${ECHO_T}no" >&6
5948 fi
5949
5950 fi
5951 if test -z "$ac_cv_prog_OBJDUMP"; then
5952   ac_ct_OBJDUMP=$OBJDUMP
5953   # Extract the first word of "objdump", so it can be a program name with args.
5954 set dummy objdump; ac_word=$2
5955 echo "$as_me:$LINENO: checking for $ac_word" >&5
5956 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5957 if test "${ac_cv_prog_ac_ct_OBJDUMP+set}" = set; then
5958   echo $ECHO_N "(cached) $ECHO_C" >&6
5959 else
5960   if test -n "$ac_ct_OBJDUMP"; then
5961   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
5962 else
5963 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5964 for as_dir in $PATH
5965 do
5966   IFS=$as_save_IFS
5967   test -z "$as_dir" && as_dir=.
5968   for ac_exec_ext in '' $ac_executable_extensions; do
5969   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5970     ac_cv_prog_ac_ct_OBJDUMP="objdump"
5971     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5972     break 2
5973   fi
5974 done
5975 done
5976
5977   test -z "$ac_cv_prog_ac_ct_OBJDUMP" && ac_cv_prog_ac_ct_OBJDUMP="false"
5978 fi
5979 fi
5980 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
5981 if test -n "$ac_ct_OBJDUMP"; then
5982   echo "$as_me:$LINENO: result: $ac_ct_OBJDUMP" >&5
5983 echo "${ECHO_T}$ac_ct_OBJDUMP" >&6
5984 else
5985   echo "$as_me:$LINENO: result: no" >&5
5986 echo "${ECHO_T}no" >&6
5987 fi
5988
5989   OBJDUMP=$ac_ct_OBJDUMP
5990 else
5991   OBJDUMP="$ac_cv_prog_OBJDUMP"
5992 fi
5993
5994   ;;
5995
5996 esac
5997
5998 need_locks="$enable_libtool_lock"
5999
6000
6001 ac_ext=c
6002 ac_cpp='$CPP $CPPFLAGS'
6003 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6004 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6005 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6006 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
6007 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
6008 # On Suns, sometimes $CPP names a directory.
6009 if test -n "$CPP" && test -d "$CPP"; then
6010   CPP=
6011 fi
6012 if test -z "$CPP"; then
6013   if test "${ac_cv_prog_CPP+set}" = set; then
6014   echo $ECHO_N "(cached) $ECHO_C" >&6
6015 else
6016       # Double quotes because CPP needs to be expanded
6017     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6018     do
6019       ac_preproc_ok=false
6020 for ac_c_preproc_warn_flag in '' yes
6021 do
6022   # Use a header file that comes with gcc, so configuring glibc
6023   # with a fresh cross-compiler works.
6024   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6025   # <limits.h> exists even on freestanding compilers.
6026   # On the NeXT, cc -E runs the code through the compiler's parser,
6027   # not just through cpp. "Syntax error" is here to catch this case.
6028   cat >conftest.$ac_ext <<_ACEOF
6029 /* confdefs.h.  */
6030 _ACEOF
6031 cat confdefs.h >>conftest.$ac_ext
6032 cat >>conftest.$ac_ext <<_ACEOF
6033 /* end confdefs.h.  */
6034 #ifdef __STDC__
6035 # include <limits.h>
6036 #else
6037 # include <assert.h>
6038 #endif
6039                      Syntax error
6040 _ACEOF
6041 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6042   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6043   ac_status=$?
6044   grep -v '^ *+' conftest.er1 >conftest.err
6045   rm -f conftest.er1
6046   cat conftest.err >&5
6047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6048   (exit $ac_status); } >/dev/null; then
6049   if test -s conftest.err; then
6050     ac_cpp_err=$ac_c_preproc_warn_flag
6051     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6052   else
6053     ac_cpp_err=
6054   fi
6055 else
6056   ac_cpp_err=yes
6057 fi
6058 if test -z "$ac_cpp_err"; then
6059   :
6060 else
6061   echo "$as_me: failed program was:" >&5
6062 sed 's/^/| /' conftest.$ac_ext >&5
6063
6064   # Broken: fails on valid input.
6065 continue
6066 fi
6067 rm -f conftest.err conftest.$ac_ext
6068
6069   # OK, works on sane cases.  Now check whether non-existent headers
6070   # can be detected and how.
6071   cat >conftest.$ac_ext <<_ACEOF
6072 /* confdefs.h.  */
6073 _ACEOF
6074 cat confdefs.h >>conftest.$ac_ext
6075 cat >>conftest.$ac_ext <<_ACEOF
6076 /* end confdefs.h.  */
6077 #include <ac_nonexistent.h>
6078 _ACEOF
6079 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6080   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6081   ac_status=$?
6082   grep -v '^ *+' conftest.er1 >conftest.err
6083   rm -f conftest.er1
6084   cat conftest.err >&5
6085   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6086   (exit $ac_status); } >/dev/null; then
6087   if test -s conftest.err; then
6088     ac_cpp_err=$ac_c_preproc_warn_flag
6089     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6090   else
6091     ac_cpp_err=
6092   fi
6093 else
6094   ac_cpp_err=yes
6095 fi
6096 if test -z "$ac_cpp_err"; then
6097   # Broken: success on invalid input.
6098 continue
6099 else
6100   echo "$as_me: failed program was:" >&5
6101 sed 's/^/| /' conftest.$ac_ext >&5
6102
6103   # Passes both tests.
6104 ac_preproc_ok=:
6105 break
6106 fi
6107 rm -f conftest.err conftest.$ac_ext
6108
6109 done
6110 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6111 rm -f conftest.err conftest.$ac_ext
6112 if $ac_preproc_ok; then
6113   break
6114 fi
6115
6116     done
6117     ac_cv_prog_CPP=$CPP
6118
6119 fi
6120   CPP=$ac_cv_prog_CPP
6121 else
6122   ac_cv_prog_CPP=$CPP
6123 fi
6124 echo "$as_me:$LINENO: result: $CPP" >&5
6125 echo "${ECHO_T}$CPP" >&6
6126 ac_preproc_ok=false
6127 for ac_c_preproc_warn_flag in '' yes
6128 do
6129   # Use a header file that comes with gcc, so configuring glibc
6130   # with a fresh cross-compiler works.
6131   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6132   # <limits.h> exists even on freestanding compilers.
6133   # On the NeXT, cc -E runs the code through the compiler's parser,
6134   # not just through cpp. "Syntax error" is here to catch this case.
6135   cat >conftest.$ac_ext <<_ACEOF
6136 /* confdefs.h.  */
6137 _ACEOF
6138 cat confdefs.h >>conftest.$ac_ext
6139 cat >>conftest.$ac_ext <<_ACEOF
6140 /* end confdefs.h.  */
6141 #ifdef __STDC__
6142 # include <limits.h>
6143 #else
6144 # include <assert.h>
6145 #endif
6146                      Syntax error
6147 _ACEOF
6148 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6149   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6150   ac_status=$?
6151   grep -v '^ *+' conftest.er1 >conftest.err
6152   rm -f conftest.er1
6153   cat conftest.err >&5
6154   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6155   (exit $ac_status); } >/dev/null; then
6156   if test -s conftest.err; then
6157     ac_cpp_err=$ac_c_preproc_warn_flag
6158     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6159   else
6160     ac_cpp_err=
6161   fi
6162 else
6163   ac_cpp_err=yes
6164 fi
6165 if test -z "$ac_cpp_err"; then
6166   :
6167 else
6168   echo "$as_me: failed program was:" >&5
6169 sed 's/^/| /' conftest.$ac_ext >&5
6170
6171   # Broken: fails on valid input.
6172 continue
6173 fi
6174 rm -f conftest.err conftest.$ac_ext
6175
6176   # OK, works on sane cases.  Now check whether non-existent headers
6177   # can be detected and how.
6178   cat >conftest.$ac_ext <<_ACEOF
6179 /* confdefs.h.  */
6180 _ACEOF
6181 cat confdefs.h >>conftest.$ac_ext
6182 cat >>conftest.$ac_ext <<_ACEOF
6183 /* end confdefs.h.  */
6184 #include <ac_nonexistent.h>
6185 _ACEOF
6186 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6187   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6188   ac_status=$?
6189   grep -v '^ *+' conftest.er1 >conftest.err
6190   rm -f conftest.er1
6191   cat conftest.err >&5
6192   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6193   (exit $ac_status); } >/dev/null; then
6194   if test -s conftest.err; then
6195     ac_cpp_err=$ac_c_preproc_warn_flag
6196     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6197   else
6198     ac_cpp_err=
6199   fi
6200 else
6201   ac_cpp_err=yes
6202 fi
6203 if test -z "$ac_cpp_err"; then
6204   # Broken: success on invalid input.
6205 continue
6206 else
6207   echo "$as_me: failed program was:" >&5
6208 sed 's/^/| /' conftest.$ac_ext >&5
6209
6210   # Passes both tests.
6211 ac_preproc_ok=:
6212 break
6213 fi
6214 rm -f conftest.err conftest.$ac_ext
6215
6216 done
6217 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6218 rm -f conftest.err conftest.$ac_ext
6219 if $ac_preproc_ok; then
6220   :
6221 else
6222   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
6223 See \`config.log' for more details." >&5
6224 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
6225 See \`config.log' for more details." >&2;}
6226    { (exit 1); exit 1; }; }
6227 fi
6228
6229 ac_ext=c
6230 ac_cpp='$CPP $CPPFLAGS'
6231 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6232 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6233 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6234
6235
6236 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
6237 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
6238 if test "${ac_cv_header_stdc+set}" = set; then
6239   echo $ECHO_N "(cached) $ECHO_C" >&6
6240 else
6241   cat >conftest.$ac_ext <<_ACEOF
6242 /* confdefs.h.  */
6243 _ACEOF
6244 cat confdefs.h >>conftest.$ac_ext
6245 cat >>conftest.$ac_ext <<_ACEOF
6246 /* end confdefs.h.  */
6247 #include <stdlib.h>
6248 #include <stdarg.h>
6249 #include <string.h>
6250 #include <float.h>
6251
6252 int
6253 main ()
6254 {
6255
6256   ;
6257   return 0;
6258 }
6259 _ACEOF
6260 rm -f conftest.$ac_objext
6261 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6262   (eval $ac_compile) 2>conftest.er1
6263   ac_status=$?
6264   grep -v '^ *+' conftest.er1 >conftest.err
6265   rm -f conftest.er1
6266   cat conftest.err >&5
6267   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6268   (exit $ac_status); } &&
6269          { ac_try='test -z "$ac_c_werror_flag"
6270                          || test ! -s conftest.err'
6271   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6272   (eval $ac_try) 2>&5
6273   ac_status=$?
6274   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6275   (exit $ac_status); }; } &&
6276          { ac_try='test -s conftest.$ac_objext'
6277   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6278   (eval $ac_try) 2>&5
6279   ac_status=$?
6280   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6281   (exit $ac_status); }; }; then
6282   ac_cv_header_stdc=yes
6283 else
6284   echo "$as_me: failed program was:" >&5
6285 sed 's/^/| /' conftest.$ac_ext >&5
6286
6287 ac_cv_header_stdc=no
6288 fi
6289 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6290
6291 if test $ac_cv_header_stdc = yes; then
6292   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6293   cat >conftest.$ac_ext <<_ACEOF
6294 /* confdefs.h.  */
6295 _ACEOF
6296 cat confdefs.h >>conftest.$ac_ext
6297 cat >>conftest.$ac_ext <<_ACEOF
6298 /* end confdefs.h.  */
6299 #include <string.h>
6300
6301 _ACEOF
6302 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6303   $EGREP "memchr" >/dev/null 2>&1; then
6304   :
6305 else
6306   ac_cv_header_stdc=no
6307 fi
6308 rm -f conftest*
6309
6310 fi
6311
6312 if test $ac_cv_header_stdc = yes; then
6313   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6314   cat >conftest.$ac_ext <<_ACEOF
6315 /* confdefs.h.  */
6316 _ACEOF
6317 cat confdefs.h >>conftest.$ac_ext
6318 cat >>conftest.$ac_ext <<_ACEOF
6319 /* end confdefs.h.  */
6320 #include <stdlib.h>
6321
6322 _ACEOF
6323 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6324   $EGREP "free" >/dev/null 2>&1; then
6325   :
6326 else
6327   ac_cv_header_stdc=no
6328 fi
6329 rm -f conftest*
6330
6331 fi
6332
6333 if test $ac_cv_header_stdc = yes; then
6334   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6335   if test "$cross_compiling" = yes; then
6336   :
6337 else
6338   cat >conftest.$ac_ext <<_ACEOF
6339 /* confdefs.h.  */
6340 _ACEOF
6341 cat confdefs.h >>conftest.$ac_ext
6342 cat >>conftest.$ac_ext <<_ACEOF
6343 /* end confdefs.h.  */
6344 #include <ctype.h>
6345 #if ((' ' & 0x0FF) == 0x020)
6346 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6347 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6348 #else
6349 # define ISLOWER(c) \
6350                    (('a' <= (c) && (c) <= 'i') \
6351                      || ('j' <= (c) && (c) <= 'r') \
6352                      || ('s' <= (c) && (c) <= 'z'))
6353 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6354 #endif
6355
6356 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6357 int
6358 main ()
6359 {
6360   int i;
6361   for (i = 0; i < 256; i++)
6362     if (XOR (islower (i), ISLOWER (i))
6363         || toupper (i) != TOUPPER (i))
6364       exit(2);
6365   exit (0);
6366 }
6367 _ACEOF
6368 rm -f conftest$ac_exeext
6369 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6370   (eval $ac_link) 2>&5
6371   ac_status=$?
6372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6373   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6374   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6375   (eval $ac_try) 2>&5
6376   ac_status=$?
6377   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6378   (exit $ac_status); }; }; then
6379   :
6380 else
6381   echo "$as_me: program exited with status $ac_status" >&5
6382 echo "$as_me: failed program was:" >&5
6383 sed 's/^/| /' conftest.$ac_ext >&5
6384
6385 ( exit $ac_status )
6386 ac_cv_header_stdc=no
6387 fi
6388 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6389 fi
6390 fi
6391 fi
6392 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
6393 echo "${ECHO_T}$ac_cv_header_stdc" >&6
6394 if test $ac_cv_header_stdc = yes; then
6395
6396 cat >>confdefs.h <<\_ACEOF
6397 #define STDC_HEADERS 1
6398 _ACEOF
6399
6400 fi
6401
6402 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6403
6404
6405
6406
6407
6408
6409
6410
6411
6412 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6413                   inttypes.h stdint.h unistd.h
6414 do
6415 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6416 echo "$as_me:$LINENO: checking for $ac_header" >&5
6417 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6418 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6419   echo $ECHO_N "(cached) $ECHO_C" >&6
6420 else
6421   cat >conftest.$ac_ext <<_ACEOF
6422 /* confdefs.h.  */
6423 _ACEOF
6424 cat confdefs.h >>conftest.$ac_ext
6425 cat >>conftest.$ac_ext <<_ACEOF
6426 /* end confdefs.h.  */
6427 $ac_includes_default
6428
6429 #include <$ac_header>
6430 _ACEOF
6431 rm -f conftest.$ac_objext
6432 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6433   (eval $ac_compile) 2>conftest.er1
6434   ac_status=$?
6435   grep -v '^ *+' conftest.er1 >conftest.err
6436   rm -f conftest.er1
6437   cat conftest.err >&5
6438   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6439   (exit $ac_status); } &&
6440          { ac_try='test -z "$ac_c_werror_flag"
6441                          || test ! -s conftest.err'
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); }; } &&
6447          { ac_try='test -s conftest.$ac_objext'
6448   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6449   (eval $ac_try) 2>&5
6450   ac_status=$?
6451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6452   (exit $ac_status); }; }; then
6453   eval "$as_ac_Header=yes"
6454 else
6455   echo "$as_me: failed program was:" >&5
6456 sed 's/^/| /' conftest.$ac_ext >&5
6457
6458 eval "$as_ac_Header=no"
6459 fi
6460 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6461 fi
6462 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6463 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6464 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6465   cat >>confdefs.h <<_ACEOF
6466 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6467 _ACEOF
6468
6469 fi
6470
6471 done
6472
6473
6474
6475 for ac_header in dlfcn.h
6476 do
6477 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6478 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6479   echo "$as_me:$LINENO: checking for $ac_header" >&5
6480 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6481 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6482   echo $ECHO_N "(cached) $ECHO_C" >&6
6483 fi
6484 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6485 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6486 else
6487   # Is the header compilable?
6488 echo "$as_me:$LINENO: checking $ac_header usability" >&5
6489 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
6490 cat >conftest.$ac_ext <<_ACEOF
6491 /* confdefs.h.  */
6492 _ACEOF
6493 cat confdefs.h >>conftest.$ac_ext
6494 cat >>conftest.$ac_ext <<_ACEOF
6495 /* end confdefs.h.  */
6496 $ac_includes_default
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   ac_header_compiler=yes
6522 else
6523   echo "$as_me: failed program was:" >&5
6524 sed 's/^/| /' conftest.$ac_ext >&5
6525
6526 ac_header_compiler=no
6527 fi
6528 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6529 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6530 echo "${ECHO_T}$ac_header_compiler" >&6
6531
6532 # Is the header present?
6533 echo "$as_me:$LINENO: checking $ac_header presence" >&5
6534 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
6535 cat >conftest.$ac_ext <<_ACEOF
6536 /* confdefs.h.  */
6537 _ACEOF
6538 cat confdefs.h >>conftest.$ac_ext
6539 cat >>conftest.$ac_ext <<_ACEOF
6540 /* end confdefs.h.  */
6541 #include <$ac_header>
6542 _ACEOF
6543 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6544   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6545   ac_status=$?
6546   grep -v '^ *+' conftest.er1 >conftest.err
6547   rm -f conftest.er1
6548   cat conftest.err >&5
6549   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6550   (exit $ac_status); } >/dev/null; then
6551   if test -s conftest.err; then
6552     ac_cpp_err=$ac_c_preproc_warn_flag
6553     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6554   else
6555     ac_cpp_err=
6556   fi
6557 else
6558   ac_cpp_err=yes
6559 fi
6560 if test -z "$ac_cpp_err"; then
6561   ac_header_preproc=yes
6562 else
6563   echo "$as_me: failed program was:" >&5
6564 sed 's/^/| /' conftest.$ac_ext >&5
6565
6566   ac_header_preproc=no
6567 fi
6568 rm -f conftest.err conftest.$ac_ext
6569 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6570 echo "${ECHO_T}$ac_header_preproc" >&6
6571
6572 # So?  What about this header?
6573 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6574   yes:no: )
6575     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6576 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
6577     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
6578 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
6579     ac_header_preproc=yes
6580     ;;
6581   no:yes:* )
6582     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6583 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
6584     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
6585 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
6586     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
6587 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
6588     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
6589 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
6590     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6591 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
6592     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
6593 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
6594     (
6595       cat <<\_ASBOX
6596 ## --------------------------------------------- ##
6597 ## Report this to <http://www.openldap.org/its/> ##
6598 ## --------------------------------------------- ##
6599 _ASBOX
6600     ) |
6601       sed "s/^/$as_me: WARNING:     /" >&2
6602     ;;
6603 esac
6604 echo "$as_me:$LINENO: checking for $ac_header" >&5
6605 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6606 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6607   echo $ECHO_N "(cached) $ECHO_C" >&6
6608 else
6609   eval "$as_ac_Header=\$ac_header_preproc"
6610 fi
6611 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6612 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6613
6614 fi
6615 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6616   cat >>confdefs.h <<_ACEOF
6617 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6618 _ACEOF
6619
6620 fi
6621
6622 done
6623
6624
6625 # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
6626
6627 # find the maximum length of command line arguments
6628 echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5
6629 echo $ECHO_N "checking the maximum length of command line arguments... $ECHO_C" >&6
6630 if test "${lt_cv_sys_max_cmd_len+set}" = set; then
6631   echo $ECHO_N "(cached) $ECHO_C" >&6
6632 else
6633     i=0
6634   teststring="ABCD"
6635
6636   case $build_os in
6637   msdosdjgpp*)
6638     # On DJGPP, this test can blow up pretty badly due to problems in libc
6639     # (any single argument exceeding 2000 bytes causes a buffer overrun
6640     # during glob expansion).  Even if it were fixed, the result of this
6641     # check would be larger than it should be.
6642     lt_cv_sys_max_cmd_len=12288;    # 12K is about right
6643     ;;
6644
6645   gnu*)
6646     # Under GNU Hurd, this test is not required because there is
6647     # no limit to the length of command line arguments.
6648     # Libtool will interpret -1 as no limit whatsoever
6649     lt_cv_sys_max_cmd_len=-1;
6650     ;;
6651
6652   cygwin* | mingw*)
6653     # On Win9x/ME, this test blows up -- it succeeds, but takes
6654     # about 5 minutes as the teststring grows exponentially.
6655     # Worse, since 9x/ME are not pre-emptively multitasking,
6656     # you end up with a "frozen" computer, even though with patience
6657     # the test eventually succeeds (with a max line length of 256k).
6658     # Instead, let's just punt: use the minimum linelength reported by
6659     # all of the supported platforms: 8192 (on NT/2K/XP).
6660     lt_cv_sys_max_cmd_len=8192;
6661     ;;
6662
6663   amigaos*)
6664     # On AmigaOS with pdksh, this test takes hours, literally.
6665     # So we just punt and use a minimum line length of 8192.
6666     lt_cv_sys_max_cmd_len=8192;
6667     ;;
6668
6669   netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
6670     # This has been around since 386BSD, at least.  Likely further.
6671     if test -x /sbin/sysctl; then
6672       lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
6673     elif test -x /usr/sbin/sysctl; then
6674       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
6675     else
6676       lt_cv_sys_max_cmd_len=65536       # usable default for all BSDs
6677     fi
6678     # And add a safety zone
6679     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
6680     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
6681     ;;
6682   osf*)
6683     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
6684     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
6685     # nice to cause kernel panics so lets avoid the loop below.
6686     # First set a reasonable default.
6687     lt_cv_sys_max_cmd_len=16384
6688     #
6689     if test -x /sbin/sysconfig; then
6690       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
6691         *1*) lt_cv_sys_max_cmd_len=-1 ;;
6692       esac
6693     fi
6694     ;;
6695   *)
6696     # If test is not a shell built-in, we'll probably end up computing a
6697     # maximum length that is only half of the actual maximum length, but
6698     # we can't tell.
6699     SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
6700     while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \
6701                = "XX$teststring") >/dev/null 2>&1 &&
6702             new_result=`expr "X$teststring" : ".*" 2>&1` &&
6703             lt_cv_sys_max_cmd_len=$new_result &&
6704             test $i != 17 # 1/2 MB should be enough
6705     do
6706       i=`expr $i + 1`
6707       teststring=$teststring$teststring
6708     done
6709     teststring=
6710     # Add a significant safety factor because C++ compilers can tack on massive
6711     # amounts of additional arguments before passing them to the linker.
6712     # It appears as though 1/2 is a usable value.
6713     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
6714     ;;
6715   esac
6716
6717 fi
6718
6719 if test -n $lt_cv_sys_max_cmd_len ; then
6720   echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5
6721 echo "${ECHO_T}$lt_cv_sys_max_cmd_len" >&6
6722 else
6723   echo "$as_me:$LINENO: result: none" >&5
6724 echo "${ECHO_T}none" >&6
6725 fi
6726
6727
6728
6729
6730 # Check for command to grab the raw symbol name followed by C symbol from nm.
6731 echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5
6732 echo $ECHO_N "checking command to parse $NM output from $compiler object... $ECHO_C" >&6
6733 if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then
6734   echo $ECHO_N "(cached) $ECHO_C" >&6
6735 else
6736
6737 # These are sane defaults that work on at least a few old systems.
6738 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
6739
6740 # Character class describing NM global symbol codes.
6741 symcode='[BCDEGRST]'
6742
6743 # Regexp to match symbols that can be accessed directly from C.
6744 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
6745
6746 # Transform an extracted symbol line into a proper C declaration
6747 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
6748
6749 # Transform an extracted symbol line into symbol name and symbol address
6750 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'"
6751
6752 # Define system-specific variables.
6753 case $host_os in
6754 aix*)
6755   symcode='[BCDT]'
6756   ;;
6757 cygwin* | mingw* | pw32*)
6758   symcode='[ABCDGISTW]'
6759   ;;
6760 hpux*) # Its linker distinguishes data from code symbols
6761   if test "$host_cpu" = ia64; then
6762     symcode='[ABCDEGRST]'
6763   fi
6764   lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
6765   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'"
6766   ;;
6767 linux*)
6768   if test "$host_cpu" = ia64; then
6769     symcode='[ABCDGIRSTW]'
6770     lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
6771     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'"
6772   fi
6773   ;;
6774 irix* | nonstopux*)
6775   symcode='[BCDEGRST]'
6776   ;;
6777 osf*)
6778   symcode='[BCDEGQRST]'
6779   ;;
6780 solaris* | sysv5*)
6781   symcode='[BDRT]'
6782   ;;
6783 sysv4)
6784   symcode='[DFNSTU]'
6785   ;;
6786 esac
6787
6788 # Handle CRLF in mingw tool chain
6789 opt_cr=
6790 case $build_os in
6791 mingw*)
6792   opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
6793   ;;
6794 esac
6795
6796 # If we're using GNU nm, then use its standard symbol codes.
6797 case `$NM -V 2>&1` in
6798 *GNU* | *'with BFD'*)
6799   symcode='[ABCDGIRSTW]' ;;
6800 esac
6801
6802 # Try without a prefix undercore, then with it.
6803 for ac_symprfx in "" "_"; do
6804
6805   # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
6806   symxfrm="\\1 $ac_symprfx\\2 \\2"
6807
6808   # Write the raw and C identifiers.
6809   lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[       ]\($symcode$symcode*\)[         ][      ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
6810
6811   # Check to see that the pipe works correctly.
6812   pipe_works=no
6813
6814   rm -f conftest*
6815   cat > conftest.$ac_ext <<EOF
6816 #ifdef __cplusplus
6817 extern "C" {
6818 #endif
6819 char nm_test_var;
6820 void nm_test_func(){}
6821 #ifdef __cplusplus
6822 }
6823 #endif
6824 int main(){nm_test_var='a';nm_test_func();return(0);}
6825 EOF
6826
6827   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6828   (eval $ac_compile) 2>&5
6829   ac_status=$?
6830   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6831   (exit $ac_status); }; then
6832     # Now try to grab the symbols.
6833     nlist=conftest.nm
6834     if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5
6835   (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5
6836   ac_status=$?
6837   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6838   (exit $ac_status); } && test -s "$nlist"; then
6839       # Try sorting and uniquifying the output.
6840       if sort "$nlist" | uniq > "$nlist"T; then
6841         mv -f "$nlist"T "$nlist"
6842       else
6843         rm -f "$nlist"T
6844       fi
6845
6846       # Make sure that we snagged all the symbols we need.
6847       if grep ' nm_test_var$' "$nlist" >/dev/null; then
6848         if grep ' nm_test_func$' "$nlist" >/dev/null; then
6849           cat <<EOF > conftest.$ac_ext
6850 #ifdef __cplusplus
6851 extern "C" {
6852 #endif
6853
6854 EOF
6855           # Now generate the symbol file.
6856           eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
6857
6858           cat <<EOF >> conftest.$ac_ext
6859 #if defined (__STDC__) && __STDC__
6860 # define lt_ptr_t void *
6861 #else
6862 # define lt_ptr_t char *
6863 # define const
6864 #endif
6865
6866 /* The mapping between symbol names and symbols. */
6867 const struct {
6868   const char *name;
6869   lt_ptr_t address;
6870 }
6871 lt_preloaded_symbols[] =
6872 {
6873 EOF
6874           $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
6875           cat <<\EOF >> conftest.$ac_ext
6876   {0, (lt_ptr_t) 0}
6877 };
6878
6879 #ifdef __cplusplus
6880 }
6881 #endif
6882 EOF
6883           # Now try linking the two files.
6884           mv conftest.$ac_objext conftstm.$ac_objext
6885           lt_save_LIBS="$LIBS"
6886           lt_save_CFLAGS="$CFLAGS"
6887           LIBS="conftstm.$ac_objext"
6888           CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
6889           if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6890   (eval $ac_link) 2>&5
6891   ac_status=$?
6892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6893   (exit $ac_status); } && test -s conftest${ac_exeext}; then
6894             pipe_works=yes
6895           fi
6896           LIBS="$lt_save_LIBS"
6897           CFLAGS="$lt_save_CFLAGS"
6898         else
6899           echo "cannot find nm_test_func in $nlist" >&5
6900         fi
6901       else
6902         echo "cannot find nm_test_var in $nlist" >&5
6903       fi
6904     else
6905       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
6906     fi
6907   else
6908     echo "$progname: failed program was:" >&5
6909     cat conftest.$ac_ext >&5
6910   fi
6911   rm -f conftest* conftst*
6912
6913   # Do not use the global_symbol_pipe unless it works.
6914   if test "$pipe_works" = yes; then
6915     break
6916   else
6917     lt_cv_sys_global_symbol_pipe=
6918   fi
6919 done
6920
6921 fi
6922
6923 if test -z "$lt_cv_sys_global_symbol_pipe"; then
6924   lt_cv_sys_global_symbol_to_cdecl=
6925 fi
6926 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
6927   echo "$as_me:$LINENO: result: failed" >&5
6928 echo "${ECHO_T}failed" >&6
6929 else
6930   echo "$as_me:$LINENO: result: ok" >&5
6931 echo "${ECHO_T}ok" >&6
6932 fi
6933
6934 echo "$as_me:$LINENO: checking for objdir" >&5
6935 echo $ECHO_N "checking for objdir... $ECHO_C" >&6
6936 if test "${lt_cv_objdir+set}" = set; then
6937   echo $ECHO_N "(cached) $ECHO_C" >&6
6938 else
6939   rm -f .libs 2>/dev/null
6940 mkdir .libs 2>/dev/null
6941 if test -d .libs; then
6942   lt_cv_objdir=.libs
6943 else
6944   # MS-DOS does not allow filenames that begin with a dot.
6945   lt_cv_objdir=_libs
6946 fi
6947 rmdir .libs 2>/dev/null
6948 fi
6949 echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5
6950 echo "${ECHO_T}$lt_cv_objdir" >&6
6951 objdir=$lt_cv_objdir
6952
6953
6954
6955
6956
6957 case $host_os in
6958 aix3*)
6959   # AIX sometimes has problems with the GCC collect2 program.  For some
6960   # reason, if we set the COLLECT_NAMES environment variable, the problems
6961   # vanish in a puff of smoke.
6962   if test "X${COLLECT_NAMES+set}" != Xset; then
6963     COLLECT_NAMES=
6964     export COLLECT_NAMES
6965   fi
6966   ;;
6967 esac
6968
6969 # Sed substitution that helps us do robust quoting.  It backslashifies
6970 # metacharacters that are still active within double-quoted strings.
6971 Xsed='sed -e 1s/^X//'
6972 sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'
6973
6974 # Same as above, but do not quote variable references.
6975 double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'
6976
6977 # Sed substitution to delay expansion of an escaped shell variable in a
6978 # double_quote_subst'ed string.
6979 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
6980
6981 # Sed substitution to avoid accidental globbing in evaled expressions
6982 no_glob_subst='s/\*/\\\*/g'
6983
6984 # Constants:
6985 rm="rm -f"
6986
6987 # Global variables:
6988 default_ofile=libtool
6989 can_build_shared=yes
6990
6991 # All known linkers require a `.a' archive for static linking (except MSVC,
6992 # which needs '.lib').
6993 libext=a
6994 ltmain="$ac_aux_dir/ltmain.sh"
6995 ofile="$default_ofile"
6996 with_gnu_ld="$lt_cv_prog_gnu_ld"
6997
6998 if test -n "$ac_tool_prefix"; then
6999   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
7000 set dummy ${ac_tool_prefix}ar; ac_word=$2
7001 echo "$as_me:$LINENO: checking for $ac_word" >&5
7002 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7003 if test "${ac_cv_prog_AR+set}" = set; then
7004   echo $ECHO_N "(cached) $ECHO_C" >&6
7005 else
7006   if test -n "$AR"; then
7007   ac_cv_prog_AR="$AR" # Let the user override the test.
7008 else
7009 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7010 for as_dir in $PATH
7011 do
7012   IFS=$as_save_IFS
7013   test -z "$as_dir" && as_dir=.
7014   for ac_exec_ext in '' $ac_executable_extensions; do
7015   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7016     ac_cv_prog_AR="${ac_tool_prefix}ar"
7017     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7018     break 2
7019   fi
7020 done
7021 done
7022
7023 fi
7024 fi
7025 AR=$ac_cv_prog_AR
7026 if test -n "$AR"; then
7027   echo "$as_me:$LINENO: result: $AR" >&5
7028 echo "${ECHO_T}$AR" >&6
7029 else
7030   echo "$as_me:$LINENO: result: no" >&5
7031 echo "${ECHO_T}no" >&6
7032 fi
7033
7034 fi
7035 if test -z "$ac_cv_prog_AR"; then
7036   ac_ct_AR=$AR
7037   # Extract the first word of "ar", so it can be a program name with args.
7038 set dummy ar; ac_word=$2
7039 echo "$as_me:$LINENO: checking for $ac_word" >&5
7040 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7041 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
7042   echo $ECHO_N "(cached) $ECHO_C" >&6
7043 else
7044   if test -n "$ac_ct_AR"; then
7045   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
7046 else
7047 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7048 for as_dir in $PATH
7049 do
7050   IFS=$as_save_IFS
7051   test -z "$as_dir" && as_dir=.
7052   for ac_exec_ext in '' $ac_executable_extensions; do
7053   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7054     ac_cv_prog_ac_ct_AR="ar"
7055     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7056     break 2
7057   fi
7058 done
7059 done
7060
7061   test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="false"
7062 fi
7063 fi
7064 ac_ct_AR=$ac_cv_prog_ac_ct_AR
7065 if test -n "$ac_ct_AR"; then
7066   echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
7067 echo "${ECHO_T}$ac_ct_AR" >&6
7068 else
7069   echo "$as_me:$LINENO: result: no" >&5
7070 echo "${ECHO_T}no" >&6
7071 fi
7072
7073   AR=$ac_ct_AR
7074 else
7075   AR="$ac_cv_prog_AR"
7076 fi
7077
7078 if test -n "$ac_tool_prefix"; then
7079   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
7080 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
7081 echo "$as_me:$LINENO: checking for $ac_word" >&5
7082 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7083 if test "${ac_cv_prog_RANLIB+set}" = set; then
7084   echo $ECHO_N "(cached) $ECHO_C" >&6
7085 else
7086   if test -n "$RANLIB"; then
7087   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
7088 else
7089 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7090 for as_dir in $PATH
7091 do
7092   IFS=$as_save_IFS
7093   test -z "$as_dir" && as_dir=.
7094   for ac_exec_ext in '' $ac_executable_extensions; do
7095   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7096     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
7097     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7098     break 2
7099   fi
7100 done
7101 done
7102
7103 fi
7104 fi
7105 RANLIB=$ac_cv_prog_RANLIB
7106 if test -n "$RANLIB"; then
7107   echo "$as_me:$LINENO: result: $RANLIB" >&5
7108 echo "${ECHO_T}$RANLIB" >&6
7109 else
7110   echo "$as_me:$LINENO: result: no" >&5
7111 echo "${ECHO_T}no" >&6
7112 fi
7113
7114 fi
7115 if test -z "$ac_cv_prog_RANLIB"; then
7116   ac_ct_RANLIB=$RANLIB
7117   # Extract the first word of "ranlib", so it can be a program name with args.
7118 set dummy ranlib; ac_word=$2
7119 echo "$as_me:$LINENO: checking for $ac_word" >&5
7120 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7121 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
7122   echo $ECHO_N "(cached) $ECHO_C" >&6
7123 else
7124   if test -n "$ac_ct_RANLIB"; then
7125   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
7126 else
7127 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7128 for as_dir in $PATH
7129 do
7130   IFS=$as_save_IFS
7131   test -z "$as_dir" && as_dir=.
7132   for ac_exec_ext in '' $ac_executable_extensions; do
7133   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7134     ac_cv_prog_ac_ct_RANLIB="ranlib"
7135     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7136     break 2
7137   fi
7138 done
7139 done
7140
7141   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
7142 fi
7143 fi
7144 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
7145 if test -n "$ac_ct_RANLIB"; then
7146   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
7147 echo "${ECHO_T}$ac_ct_RANLIB" >&6
7148 else
7149   echo "$as_me:$LINENO: result: no" >&5
7150 echo "${ECHO_T}no" >&6
7151 fi
7152
7153   RANLIB=$ac_ct_RANLIB
7154 else
7155   RANLIB="$ac_cv_prog_RANLIB"
7156 fi
7157
7158 if test -n "$ac_tool_prefix"; then
7159   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
7160 set dummy ${ac_tool_prefix}strip; ac_word=$2
7161 echo "$as_me:$LINENO: checking for $ac_word" >&5
7162 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7163 if test "${ac_cv_prog_STRIP+set}" = set; then
7164   echo $ECHO_N "(cached) $ECHO_C" >&6
7165 else
7166   if test -n "$STRIP"; then
7167   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
7168 else
7169 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7170 for as_dir in $PATH
7171 do
7172   IFS=$as_save_IFS
7173   test -z "$as_dir" && as_dir=.
7174   for ac_exec_ext in '' $ac_executable_extensions; do
7175   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7176     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
7177     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7178     break 2
7179   fi
7180 done
7181 done
7182
7183 fi
7184 fi
7185 STRIP=$ac_cv_prog_STRIP
7186 if test -n "$STRIP"; then
7187   echo "$as_me:$LINENO: result: $STRIP" >&5
7188 echo "${ECHO_T}$STRIP" >&6
7189 else
7190   echo "$as_me:$LINENO: result: no" >&5
7191 echo "${ECHO_T}no" >&6
7192 fi
7193
7194 fi
7195 if test -z "$ac_cv_prog_STRIP"; then
7196   ac_ct_STRIP=$STRIP
7197   # Extract the first word of "strip", so it can be a program name with args.
7198 set dummy strip; ac_word=$2
7199 echo "$as_me:$LINENO: checking for $ac_word" >&5
7200 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7201 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
7202   echo $ECHO_N "(cached) $ECHO_C" >&6
7203 else
7204   if test -n "$ac_ct_STRIP"; then
7205   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
7206 else
7207 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7208 for as_dir in $PATH
7209 do
7210   IFS=$as_save_IFS
7211   test -z "$as_dir" && as_dir=.
7212   for ac_exec_ext in '' $ac_executable_extensions; do
7213   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7214     ac_cv_prog_ac_ct_STRIP="strip"
7215     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7216     break 2
7217   fi
7218 done
7219 done
7220
7221   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
7222 fi
7223 fi
7224 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
7225 if test -n "$ac_ct_STRIP"; then
7226   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
7227 echo "${ECHO_T}$ac_ct_STRIP" >&6
7228 else
7229   echo "$as_me:$LINENO: result: no" >&5
7230 echo "${ECHO_T}no" >&6
7231 fi
7232
7233   STRIP=$ac_ct_STRIP
7234 else
7235   STRIP="$ac_cv_prog_STRIP"
7236 fi
7237
7238
7239 old_CC="$CC"
7240 old_CFLAGS="$CFLAGS"
7241
7242 # Set sane defaults for various variables
7243 test -z "$AR" && AR=ar
7244 test -z "$AR_FLAGS" && AR_FLAGS=cru
7245 test -z "$AS" && AS=as
7246 test -z "$CC" && CC=cc
7247 test -z "$LTCC" && LTCC=$CC
7248 test -z "$DLLTOOL" && DLLTOOL=dlltool
7249 test -z "$LD" && LD=ld
7250 test -z "$LN_S" && LN_S="ln -s"
7251 test -z "$MAGIC_CMD" && MAGIC_CMD=file
7252 test -z "$NM" && NM=nm
7253 test -z "$SED" && SED=sed
7254 test -z "$OBJDUMP" && OBJDUMP=objdump
7255 test -z "$RANLIB" && RANLIB=:
7256 test -z "$STRIP" && STRIP=:
7257 test -z "$ac_objext" && ac_objext=o
7258
7259 # Determine commands to create old-style static archives.
7260 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
7261 old_postinstall_cmds='chmod 644 $oldlib'
7262 old_postuninstall_cmds=
7263
7264 if test -n "$RANLIB"; then
7265   case $host_os in
7266   openbsd*)
7267     old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
7268     ;;
7269   *)
7270     old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
7271     ;;
7272   esac
7273   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
7274 fi
7275
7276 for cc_temp in $compiler""; do
7277   case $cc_temp in
7278     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
7279     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
7280     \-*) ;;
7281     *) break;;
7282   esac
7283 done
7284 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
7285
7286
7287 # Only perform the check for file, if the check method requires it
7288 case $deplibs_check_method in
7289 file_magic*)
7290   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
7291     echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5
7292 echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6
7293 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7294   echo $ECHO_N "(cached) $ECHO_C" >&6
7295 else
7296   case $MAGIC_CMD in
7297 [\\/*] |  ?:[\\/]*)
7298   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7299   ;;
7300 *)
7301   lt_save_MAGIC_CMD="$MAGIC_CMD"
7302   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
7303   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
7304   for ac_dir in $ac_dummy; do
7305     IFS="$lt_save_ifs"
7306     test -z "$ac_dir" && ac_dir=.
7307     if test -f $ac_dir/${ac_tool_prefix}file; then
7308       lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
7309       if test -n "$file_magic_test_file"; then
7310         case $deplibs_check_method in
7311         "file_magic "*)
7312           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
7313           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7314           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7315             $EGREP "$file_magic_regex" > /dev/null; then
7316             :
7317           else
7318             cat <<EOF 1>&2
7319
7320 *** Warning: the command libtool uses to detect shared libraries,
7321 *** $file_magic_cmd, produces output that libtool cannot recognize.
7322 *** The result is that libtool may fail to recognize shared libraries
7323 *** as such.  This will affect the creation of libtool libraries that
7324 *** depend on shared libraries, but programs linked with such libtool
7325 *** libraries will work regardless of this problem.  Nevertheless, you
7326 *** may want to report the problem to your system manager and/or to
7327 *** bug-libtool@gnu.org
7328
7329 EOF
7330           fi ;;
7331         esac
7332       fi
7333       break
7334     fi
7335   done
7336   IFS="$lt_save_ifs"
7337   MAGIC_CMD="$lt_save_MAGIC_CMD"
7338   ;;
7339 esac
7340 fi
7341
7342 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7343 if test -n "$MAGIC_CMD"; then
7344   echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7345 echo "${ECHO_T}$MAGIC_CMD" >&6
7346 else
7347   echo "$as_me:$LINENO: result: no" >&5
7348 echo "${ECHO_T}no" >&6
7349 fi
7350
7351 if test -z "$lt_cv_path_MAGIC_CMD"; then
7352   if test -n "$ac_tool_prefix"; then
7353     echo "$as_me:$LINENO: checking for file" >&5
7354 echo $ECHO_N "checking for file... $ECHO_C" >&6
7355 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7356   echo $ECHO_N "(cached) $ECHO_C" >&6
7357 else
7358   case $MAGIC_CMD in
7359 [\\/*] |  ?:[\\/]*)
7360   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7361   ;;
7362 *)
7363   lt_save_MAGIC_CMD="$MAGIC_CMD"
7364   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
7365   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
7366   for ac_dir in $ac_dummy; do
7367     IFS="$lt_save_ifs"
7368     test -z "$ac_dir" && ac_dir=.
7369     if test -f $ac_dir/file; then
7370       lt_cv_path_MAGIC_CMD="$ac_dir/file"
7371       if test -n "$file_magic_test_file"; then
7372         case $deplibs_check_method in
7373         "file_magic "*)
7374           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
7375           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7376           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7377             $EGREP "$file_magic_regex" > /dev/null; then
7378             :
7379           else
7380             cat <<EOF 1>&2
7381
7382 *** Warning: the command libtool uses to detect shared libraries,
7383 *** $file_magic_cmd, produces output that libtool cannot recognize.
7384 *** The result is that libtool may fail to recognize shared libraries
7385 *** as such.  This will affect the creation of libtool libraries that
7386 *** depend on shared libraries, but programs linked with such libtool
7387 *** libraries will work regardless of this problem.  Nevertheless, you
7388 *** may want to report the problem to your system manager and/or to
7389 *** bug-libtool@gnu.org
7390
7391 EOF
7392           fi ;;
7393         esac
7394       fi
7395       break
7396     fi
7397   done
7398   IFS="$lt_save_ifs"
7399   MAGIC_CMD="$lt_save_MAGIC_CMD"
7400   ;;
7401 esac
7402 fi
7403
7404 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7405 if test -n "$MAGIC_CMD"; then
7406   echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7407 echo "${ECHO_T}$MAGIC_CMD" >&6
7408 else
7409   echo "$as_me:$LINENO: result: no" >&5
7410 echo "${ECHO_T}no" >&6
7411 fi
7412
7413   else
7414     MAGIC_CMD=:
7415   fi
7416 fi
7417
7418   fi
7419   ;;
7420 esac
7421
7422 enable_dlopen=yes
7423 enable_win32_dll=yes
7424
7425 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
7426 if test "${enable_libtool_lock+set}" = set; then
7427   enableval="$enable_libtool_lock"
7428
7429 fi;
7430 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
7431
7432
7433 # Check whether --with-pic or --without-pic was given.
7434 if test "${with_pic+set}" = set; then
7435   withval="$with_pic"
7436   pic_mode="$withval"
7437 else
7438   pic_mode=default
7439 fi;
7440 test -z "$pic_mode" && pic_mode=default
7441
7442 # Use C for the default configuration in the libtool script
7443 tagname=
7444 lt_save_CC="$CC"
7445 ac_ext=c
7446 ac_cpp='$CPP $CPPFLAGS'
7447 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7448 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7449 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7450
7451
7452 # Source file extension for C test sources.
7453 ac_ext=c
7454
7455 # Object file extension for compiled C test sources.
7456 objext=o
7457 objext=$objext
7458
7459 # Code to be used in simple compile tests
7460 lt_simple_compile_test_code="int some_variable = 0;\n"
7461
7462 # Code to be used in simple link tests
7463 lt_simple_link_test_code='int main(){return(0);}\n'
7464
7465
7466 # If no C compiler was specified, use CC.
7467 LTCC=${LTCC-"$CC"}
7468
7469 # Allow CC to be a program name with arguments.
7470 compiler=$CC
7471
7472
7473 # save warnings/boilerplate of simple test code
7474 ac_outfile=conftest.$ac_objext
7475 printf "$lt_simple_compile_test_code" >conftest.$ac_ext
7476 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
7477 _lt_compiler_boilerplate=`cat conftest.err`
7478 $rm conftest*
7479
7480 ac_outfile=conftest.$ac_objext
7481 printf "$lt_simple_link_test_code" >conftest.$ac_ext
7482 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
7483 _lt_linker_boilerplate=`cat conftest.err`
7484 $rm conftest*
7485
7486
7487 #
7488 # Check for any special shared library compilation flags.
7489 #
7490 lt_prog_cc_shlib=
7491 if test "$GCC" = no; then
7492   case $host_os in
7493   sco3.2v5*)
7494     lt_prog_cc_shlib='-belf'
7495     ;;
7496   esac
7497 fi
7498 if test -n "$lt_prog_cc_shlib"; then
7499   { echo "$as_me:$LINENO: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&5
7500 echo "$as_me: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&2;}
7501   if echo "$old_CC $old_CFLAGS " | grep "[      ]$lt_prog_cc_shlib[     ]" >/dev/null; then :
7502   else
7503     { echo "$as_me:$LINENO: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&5
7504 echo "$as_me: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&2;}
7505     lt_cv_prog_cc_can_build_shared=no
7506   fi
7507 fi
7508
7509
7510 #
7511 # Check to make sure the static flag actually works.
7512 #
7513 echo "$as_me:$LINENO: checking if $compiler static flag $lt_prog_compiler_static works" >&5
7514 echo $ECHO_N "checking if $compiler static flag $lt_prog_compiler_static works... $ECHO_C" >&6
7515 if test "${lt_prog_compiler_static_works+set}" = set; then
7516   echo $ECHO_N "(cached) $ECHO_C" >&6
7517 else
7518   lt_prog_compiler_static_works=no
7519    save_LDFLAGS="$LDFLAGS"
7520    LDFLAGS="$LDFLAGS $lt_prog_compiler_static"
7521    printf "$lt_simple_link_test_code" > conftest.$ac_ext
7522    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
7523      # The linker can only warn and ignore the option if not recognized
7524      # So say no if there are warnings
7525      if test -s conftest.err; then
7526        # Append any errors to the config.log.
7527        cat conftest.err 1>&5
7528        $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp
7529        $SED '/^$/d' conftest.err >conftest.er2
7530        if diff conftest.exp conftest.er2 >/dev/null; then
7531          lt_prog_compiler_static_works=yes
7532        fi
7533      else
7534        lt_prog_compiler_static_works=yes
7535      fi
7536    fi
7537    $rm conftest*
7538    LDFLAGS="$save_LDFLAGS"
7539
7540 fi
7541 echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works" >&5
7542 echo "${ECHO_T}$lt_prog_compiler_static_works" >&6
7543
7544 if test x"$lt_prog_compiler_static_works" = xyes; then
7545     :
7546 else
7547     lt_prog_compiler_static=
7548 fi
7549
7550
7551
7552
7553 lt_prog_compiler_no_builtin_flag=
7554
7555 if test "$GCC" = yes; then
7556   lt_prog_compiler_no_builtin_flag=' -fno-builtin'
7557
7558
7559 echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
7560 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6
7561 if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then
7562   echo $ECHO_N "(cached) $ECHO_C" >&6
7563 else
7564   lt_cv_prog_compiler_rtti_exceptions=no
7565   ac_outfile=conftest.$ac_objext
7566    printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7567    lt_compiler_flag="-fno-rtti -fno-exceptions"
7568    # Insert the option either (1) after the last *FLAGS variable, or
7569    # (2) before a word containing "conftest.", or (3) at the end.
7570    # Note that $ac_compile itself does not contain backslashes and begins
7571    # with a dollar sign (not a hyphen), so the echo should work correctly.
7572    # The option is referenced via a variable to avoid confusing sed.
7573    lt_compile=`echo "$ac_compile" | $SED \
7574    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7575    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7576    -e 's:$: $lt_compiler_flag:'`
7577    (eval echo "\"\$as_me:7577: $lt_compile\"" >&5)
7578    (eval "$lt_compile" 2>conftest.err)
7579    ac_status=$?
7580    cat conftest.err >&5
7581    echo "$as_me:7581: \$? = $ac_status" >&5
7582    if (exit $ac_status) && test -s "$ac_outfile"; then
7583      # The compiler can only warn and ignore the option if not recognized
7584      # So say no if there are warnings other than the usual output.
7585      $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
7586      $SED '/^$/d' conftest.err >conftest.er2
7587      if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
7588        lt_cv_prog_compiler_rtti_exceptions=yes
7589      fi
7590    fi
7591    $rm conftest*
7592
7593 fi
7594 echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
7595 echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6
7596
7597 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
7598     lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
7599 else
7600     :
7601 fi
7602
7603 fi
7604
7605 lt_prog_compiler_wl=
7606 lt_prog_compiler_pic=
7607 lt_prog_compiler_static=
7608
7609 echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
7610 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6
7611
7612   if test "$GCC" = yes; then
7613     lt_prog_compiler_wl='-Wl,'
7614     lt_prog_compiler_static='-static'
7615
7616     case $host_os in
7617       aix*)
7618       # All AIX code is PIC.
7619       if test "$host_cpu" = ia64; then
7620         # AIX 5 now supports IA64 processor
7621         lt_prog_compiler_static='-Bstatic'
7622       fi
7623       ;;
7624
7625     amigaos*)
7626       # FIXME: we need at least 68020 code to build shared libraries, but
7627       # adding the `-m68020' flag to GCC prevents building anything better,
7628       # like `-m68040'.
7629       lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
7630       ;;
7631
7632     beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
7633       # PIC is the default for these OSes.
7634       ;;
7635
7636     mingw* | pw32* | os2*)
7637       # This hack is so that the source file can tell whether it is being
7638       # built for inclusion in a dll (and should export symbols for example).
7639       lt_prog_compiler_pic='-DDLL_EXPORT'
7640       ;;
7641
7642     darwin* | rhapsody*)
7643       # PIC is the default on this platform
7644       # Common symbols not allowed in MH_DYLIB files
7645       lt_prog_compiler_pic='-fno-common'
7646       ;;
7647
7648     msdosdjgpp*)
7649       # Just because we use GCC doesn't mean we suddenly get shared libraries
7650       # on systems that don't support them.
7651       lt_prog_compiler_can_build_shared=no
7652       enable_shared=no
7653       ;;
7654
7655     sysv4*MP*)
7656       if test -d /usr/nec; then
7657         lt_prog_compiler_pic=-Kconform_pic
7658       fi
7659       ;;
7660
7661     hpux*)
7662       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
7663       # not for PA HP-UX.
7664       case $host_cpu in
7665       hppa*64*|ia64*)
7666         # +Z the default
7667         ;;
7668       *)
7669         lt_prog_compiler_pic='-fPIC'
7670         ;;
7671       esac
7672       ;;
7673
7674     *)
7675       lt_prog_compiler_pic='-fPIC'
7676       ;;
7677     esac
7678   else
7679     # PORTME Check for flag to pass linker flags through the system compiler.
7680     case $host_os in
7681     aix*)
7682       lt_prog_compiler_wl='-Wl,'
7683       if test "$host_cpu" = ia64; then
7684         # AIX 5 now supports IA64 processor
7685         lt_prog_compiler_static='-Bstatic'
7686       else
7687         lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
7688       fi
7689       ;;
7690       darwin*)
7691         # PIC is the default on this platform
7692         # Common symbols not allowed in MH_DYLIB files
7693        case $cc_basename in
7694          xlc*)
7695          lt_prog_compiler_pic='-qnocommon'
7696          lt_prog_compiler_wl='-Wl,'
7697          ;;
7698        esac
7699        ;;
7700
7701     mingw* | pw32* | os2*)
7702       # This hack is so that the source file can tell whether it is being
7703       # built for inclusion in a dll (and should export symbols for example).
7704       lt_prog_compiler_pic='-DDLL_EXPORT'
7705       ;;
7706
7707     hpux9* | hpux10* | hpux11*)
7708       lt_prog_compiler_wl='-Wl,'
7709       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
7710       # not for PA HP-UX.
7711       case $host_cpu in
7712       hppa*64*|ia64*)
7713         # +Z the default
7714         ;;
7715       *)
7716         lt_prog_compiler_pic='+Z'
7717         ;;
7718       esac
7719       # Is there a better lt_prog_compiler_static that works with the bundled CC?
7720       lt_prog_compiler_static='${wl}-a ${wl}archive'
7721       ;;
7722
7723     irix5* | irix6* | nonstopux*)
7724       lt_prog_compiler_wl='-Wl,'
7725       # PIC (with -KPIC) is the default.
7726       lt_prog_compiler_static='-non_shared'
7727       ;;
7728
7729     newsos6)
7730       lt_prog_compiler_pic='-KPIC'
7731       lt_prog_compiler_static='-Bstatic'
7732       ;;
7733
7734     linux*)
7735       case $cc_basename in
7736       icc* | ecc*)
7737         lt_prog_compiler_wl='-Wl,'
7738         lt_prog_compiler_pic='-KPIC'
7739         lt_prog_compiler_static='-static'
7740         ;;
7741       pgcc* | pgf77* | pgf90* | pgf95*)
7742         # Portland Group compilers (*not* the Pentium gcc compiler,
7743         # which looks to be a dead project)
7744         lt_prog_compiler_wl='-Wl,'
7745         lt_prog_compiler_pic='-fpic'
7746         lt_prog_compiler_static='-Bstatic'
7747         ;;
7748       ccc*)
7749         lt_prog_compiler_wl='-Wl,'
7750         # All Alpha code is PIC.
7751         lt_prog_compiler_static='-non_shared'
7752         ;;
7753       esac
7754       ;;
7755
7756     osf3* | osf4* | osf5*)
7757       lt_prog_compiler_wl='-Wl,'
7758       # All OSF/1 code is PIC.
7759       lt_prog_compiler_static='-non_shared'
7760       ;;
7761
7762     sco3.2v5*)
7763       lt_prog_compiler_pic='-Kpic'
7764       lt_prog_compiler_static='-dn'
7765       ;;
7766
7767     solaris*)
7768       lt_prog_compiler_pic='-KPIC'
7769       lt_prog_compiler_static='-Bstatic'
7770       case $cc_basename in
7771       f77* | f90* | f95*)
7772         lt_prog_compiler_wl='-Qoption ld ';;
7773       *)
7774         lt_prog_compiler_wl='-Wl,';;
7775       esac
7776       ;;
7777
7778     sunos4*)
7779       lt_prog_compiler_wl='-Qoption ld '
7780       lt_prog_compiler_pic='-PIC'
7781       lt_prog_compiler_static='-Bstatic'
7782       ;;
7783
7784     sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
7785       lt_prog_compiler_wl='-Wl,'
7786       lt_prog_compiler_pic='-KPIC'
7787       lt_prog_compiler_static='-Bstatic'
7788       ;;
7789
7790     sysv4*MP*)
7791       if test -d /usr/nec ;then
7792         lt_prog_compiler_pic='-Kconform_pic'
7793         lt_prog_compiler_static='-Bstatic'
7794       fi
7795       ;;
7796
7797     unicos*)
7798       lt_prog_compiler_wl='-Wl,'
7799       lt_prog_compiler_can_build_shared=no
7800       ;;
7801
7802     uts4*)
7803       lt_prog_compiler_pic='-pic'
7804       lt_prog_compiler_static='-Bstatic'
7805       ;;
7806
7807     *)
7808       lt_prog_compiler_can_build_shared=no
7809       ;;
7810     esac
7811   fi
7812
7813 echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5
7814 echo "${ECHO_T}$lt_prog_compiler_pic" >&6
7815
7816 #
7817 # Check to make sure the PIC flag actually works.
7818 #
7819 if test -n "$lt_prog_compiler_pic"; then
7820
7821 echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
7822 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic works... $ECHO_C" >&6
7823 if test "${lt_prog_compiler_pic_works+set}" = set; then
7824   echo $ECHO_N "(cached) $ECHO_C" >&6
7825 else
7826   lt_prog_compiler_pic_works=no
7827   ac_outfile=conftest.$ac_objext
7828    printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7829    lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
7830    # Insert the option either (1) after the last *FLAGS variable, or
7831    # (2) before a word containing "conftest.", or (3) at the end.
7832    # Note that $ac_compile itself does not contain backslashes and begins
7833    # with a dollar sign (not a hyphen), so the echo should work correctly.
7834    # The option is referenced via a variable to avoid confusing sed.
7835    lt_compile=`echo "$ac_compile" | $SED \
7836    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7837    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7838    -e 's:$: $lt_compiler_flag:'`
7839    (eval echo "\"\$as_me:7839: $lt_compile\"" >&5)
7840    (eval "$lt_compile" 2>conftest.err)
7841    ac_status=$?
7842    cat conftest.err >&5
7843    echo "$as_me:7843: \$? = $ac_status" >&5
7844    if (exit $ac_status) && test -s "$ac_outfile"; then
7845      # The compiler can only warn and ignore the option if not recognized
7846      # So say no if there are warnings other than the usual output.
7847      $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
7848      $SED '/^$/d' conftest.err >conftest.er2
7849      if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
7850        lt_prog_compiler_pic_works=yes
7851      fi
7852    fi
7853    $rm conftest*
7854
7855 fi
7856 echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works" >&5
7857 echo "${ECHO_T}$lt_prog_compiler_pic_works" >&6
7858
7859 if test x"$lt_prog_compiler_pic_works" = xyes; then
7860     case $lt_prog_compiler_pic in
7861      "" | " "*) ;;
7862      *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
7863      esac
7864 else
7865     lt_prog_compiler_pic=
7866      lt_prog_compiler_can_build_shared=no
7867 fi
7868
7869 fi
7870 case $host_os in
7871   # For platforms which do not support PIC, -DPIC is meaningless:
7872   *djgpp*)
7873     lt_prog_compiler_pic=
7874     ;;
7875   *)
7876     lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
7877     ;;
7878 esac
7879
7880 echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
7881 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6
7882 if test "${lt_cv_prog_compiler_c_o+set}" = set; then
7883   echo $ECHO_N "(cached) $ECHO_C" >&6
7884 else
7885   lt_cv_prog_compiler_c_o=no
7886    $rm -r conftest 2>/dev/null
7887    mkdir conftest
7888    cd conftest
7889    mkdir out
7890    printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7891
7892    lt_compiler_flag="-o out/conftest2.$ac_objext"
7893    # Insert the option either (1) after the last *FLAGS variable, or
7894    # (2) before a word containing "conftest.", or (3) at the end.
7895    # Note that $ac_compile itself does not contain backslashes and begins
7896    # with a dollar sign (not a hyphen), so the echo should work correctly.
7897    lt_compile=`echo "$ac_compile" | $SED \
7898    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7899    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7900    -e 's:$: $lt_compiler_flag:'`
7901    (eval echo "\"\$as_me:7901: $lt_compile\"" >&5)
7902    (eval "$lt_compile" 2>out/conftest.err)
7903    ac_status=$?
7904    cat out/conftest.err >&5
7905    echo "$as_me:7905: \$? = $ac_status" >&5
7906    if (exit $ac_status) && test -s out/conftest2.$ac_objext
7907    then
7908      # The compiler can only warn and ignore the option if not recognized
7909      # So say no if there are warnings
7910      $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp
7911      $SED '/^$/d' out/conftest.err >out/conftest.er2
7912      if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then
7913        lt_cv_prog_compiler_c_o=yes
7914      fi
7915    fi
7916    chmod u+w . 2>&5
7917    $rm conftest*
7918    # SGI C++ compiler will create directory out/ii_files/ for
7919    # template instantiation
7920    test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
7921    $rm out/* && rmdir out
7922    cd ..
7923    rmdir conftest
7924    $rm conftest*
7925
7926 fi
7927 echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5
7928 echo "${ECHO_T}$lt_cv_prog_compiler_c_o" >&6
7929
7930
7931 hard_links="nottested"
7932 if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
7933   # do not overwrite the value of need_locks provided by the user
7934   echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
7935 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6
7936   hard_links=yes
7937   $rm conftest*
7938   ln conftest.a conftest.b 2>/dev/null && hard_links=no
7939   touch conftest.a
7940   ln conftest.a conftest.b 2>&5 || hard_links=no
7941   ln conftest.a conftest.b 2>/dev/null && hard_links=no
7942   echo "$as_me:$LINENO: result: $hard_links" >&5
7943 echo "${ECHO_T}$hard_links" >&6
7944   if test "$hard_links" = no; then
7945     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
7946 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
7947     need_locks=warn
7948   fi
7949 else
7950   need_locks=no
7951 fi
7952
7953 echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
7954 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6
7955
7956   runpath_var=
7957   allow_undefined_flag=
7958   enable_shared_with_static_runtimes=no
7959   archive_cmds=
7960   archive_expsym_cmds=
7961   old_archive_From_new_cmds=
7962   old_archive_from_expsyms_cmds=
7963   export_dynamic_flag_spec=
7964   whole_archive_flag_spec=
7965   thread_safe_flag_spec=
7966   hardcode_libdir_flag_spec=
7967   hardcode_libdir_flag_spec_ld=
7968   hardcode_libdir_separator=
7969   hardcode_direct=no
7970   hardcode_minus_L=no
7971   hardcode_shlibpath_var=unsupported
7972   link_all_deplibs=unknown
7973   hardcode_automatic=no
7974   module_cmds=
7975   module_expsym_cmds=
7976   always_export_symbols=no
7977   export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
7978   # include_expsyms should be a list of space-separated symbols to be *always*
7979   # included in the symbol list
7980   include_expsyms=
7981   # exclude_expsyms can be an extended regexp of symbols to exclude
7982   # it will be wrapped by ` (' and `)$', so one must not match beginning or
7983   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
7984   # as well as any symbol that contains `d'.
7985   exclude_expsyms="_GLOBAL_OFFSET_TABLE_"
7986   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
7987   # platforms (ab)use it in PIC code, but their linkers get confused if
7988   # the symbol is explicitly referenced.  Since portable code cannot
7989   # rely on this symbol name, it's probably fine to never include it in
7990   # preloaded symbol tables.
7991   extract_expsyms_cmds=
7992   # Just being paranoid about ensuring that cc_basename is set.
7993   for cc_temp in $compiler""; do
7994   case $cc_temp in
7995     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
7996     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
7997     \-*) ;;
7998     *) break;;
7999   esac
8000 done
8001 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
8002
8003   case $host_os in
8004   cygwin* | mingw* | pw32*)
8005     # FIXME: the MSVC++ port hasn't been tested in a loooong time
8006     # When not using gcc, we currently assume that we are using
8007     # Microsoft Visual C++.
8008     if test "$GCC" != yes; then
8009       with_gnu_ld=no
8010     fi
8011     ;;
8012   openbsd*)
8013     with_gnu_ld=no
8014     ;;
8015   esac
8016
8017   ld_shlibs=yes
8018   if test "$with_gnu_ld" = yes; then
8019     # If archive_cmds runs LD, not CC, wlarc should be empty
8020     wlarc='${wl}'
8021
8022     # Set some defaults for GNU ld with shared library support. These
8023     # are reset later if shared libraries are not supported. Putting them
8024     # here allows them to be overridden if necessary.
8025     runpath_var=LD_RUN_PATH
8026     hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir'
8027     export_dynamic_flag_spec='${wl}--export-dynamic'
8028     # ancient GNU ld didn't support --whole-archive et. al.
8029     if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
8030         whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
8031       else
8032         whole_archive_flag_spec=
8033     fi
8034     supports_anon_versioning=no
8035     case `$LD -v 2>/dev/null` in
8036       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
8037       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
8038       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
8039       *\ 2.11.*) ;; # other 2.11 versions
8040       *) supports_anon_versioning=yes ;;
8041     esac
8042
8043     # See if GNU ld supports shared libraries.
8044     case $host_os in
8045     aix3* | aix4* | aix5*)
8046       # On AIX/PPC, the GNU linker is very broken
8047       if test "$host_cpu" != ia64; then
8048         ld_shlibs=no
8049         cat <<EOF 1>&2
8050
8051 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
8052 *** to be unable to reliably create shared libraries on AIX.
8053 *** Therefore, libtool is disabling shared libraries support.  If you
8054 *** really care for shared libraries, you may want to modify your PATH
8055 *** so that a non-GNU linker is found, and then restart.
8056
8057 EOF
8058       fi
8059       ;;
8060
8061     amigaos*)
8062       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)'
8063       hardcode_libdir_flag_spec='-L$libdir'
8064       hardcode_minus_L=yes
8065
8066       # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
8067       # that the semantics of dynamic libraries on AmigaOS, at least up
8068       # to version 4, is to share data among multiple programs linked
8069       # with the same dynamic library.  Since this doesn't match the
8070       # behavior of shared libraries on other platforms, we can't use
8071       # them.
8072       ld_shlibs=no
8073       ;;
8074
8075     beos*)
8076       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8077         allow_undefined_flag=unsupported
8078         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
8079         # support --undefined.  This deserves some investigation.  FIXME
8080         archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8081       else
8082         ld_shlibs=no
8083       fi
8084       ;;
8085
8086     cygwin* | mingw* | pw32*)
8087       # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
8088       # as there is no search path for DLLs.
8089       hardcode_libdir_flag_spec='-L$libdir'
8090       allow_undefined_flag=unsupported
8091       always_export_symbols=no
8092       enable_shared_with_static_runtimes=yes
8093       export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols'
8094
8095       if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
8096         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
8097         # If the export-symbols file already is a .def file (1st line
8098         # is EXPORTS), use it as is; otherwise, prepend...
8099         archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
8100           cp $export_symbols $output_objdir/$soname.def;
8101         else
8102           echo EXPORTS > $output_objdir/$soname.def;
8103           cat $export_symbols >> $output_objdir/$soname.def;
8104         fi~
8105         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000  ${wl}--out-implib,$lib'
8106       else
8107         ld_shlibs=no
8108       fi
8109       ;;
8110
8111     linux*)
8112       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8113         tmp_addflag=
8114         case $cc_basename,$host_cpu in
8115         pgcc*)                          # Portland Group C compiler
8116           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'
8117           tmp_addflag=' $pic_flag'
8118           ;;
8119         pgf77* | pgf90* | pgf95*)       # Portland Group f77 and f90 compilers
8120           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'
8121           tmp_addflag=' $pic_flag -Mnomain' ;;
8122         ecc*,ia64* | icc*,ia64*)                # Intel C compiler on ia64
8123           tmp_addflag=' -i_dynamic' ;;
8124         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
8125           tmp_addflag=' -i_dynamic -nofor_main' ;;
8126         ifc* | ifort*)                  # Intel Fortran compiler
8127           tmp_addflag=' -nofor_main' ;;
8128         esac
8129         archive_cmds='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8130
8131         if test $supports_anon_versioning = yes; then
8132           archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~
8133   cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
8134   $echo "local: *; };" >> $output_objdir/$libname.ver~
8135           $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
8136         fi
8137       else
8138         ld_shlibs=no
8139       fi
8140       ;;
8141
8142     netbsd*)
8143       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
8144         archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
8145         wlarc=
8146       else
8147         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8148         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8149       fi
8150       ;;
8151
8152     solaris* | sysv5*)
8153       if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
8154         ld_shlibs=no
8155         cat <<EOF 1>&2
8156
8157 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
8158 *** create shared libraries on Solaris systems.  Therefore, libtool
8159 *** is disabling shared libraries support.  We urge you to upgrade GNU
8160 *** binutils to release 2.9.1 or newer.  Another option is to modify
8161 *** your PATH or compiler configuration so that the native linker is
8162 *** used, and then restart.
8163
8164 EOF
8165       elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8166         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8167         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8168       else
8169         ld_shlibs=no
8170       fi
8171       ;;
8172
8173     sunos4*)
8174       archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8175       wlarc=
8176       hardcode_direct=yes
8177       hardcode_shlibpath_var=no
8178       ;;
8179
8180     *)
8181       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8182         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8183         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8184       else
8185         ld_shlibs=no
8186       fi
8187       ;;
8188     esac
8189
8190     if test "$ld_shlibs" = no; then
8191       runpath_var=
8192       hardcode_libdir_flag_spec=
8193       export_dynamic_flag_spec=
8194       whole_archive_flag_spec=
8195     fi
8196   else
8197     # PORTME fill in a description of your system's linker (not GNU ld)
8198     case $host_os in
8199     aix3*)
8200       allow_undefined_flag=unsupported
8201       always_export_symbols=yes
8202       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'
8203       # Note: this linker hardcodes the directories in LIBPATH if there
8204       # are no directories specified by -L.
8205       hardcode_minus_L=yes
8206       if test "$GCC" = yes && test -z "$link_static_flag"; then
8207         # Neither direct hardcoding nor static linking is supported with a
8208         # broken collect2.
8209         hardcode_direct=unsupported
8210       fi
8211       ;;
8212
8213     aix4* | aix5*)
8214       if test "$host_cpu" = ia64; then
8215         # On IA64, the linker does run time linking by default, so we don't
8216         # have to do anything special.
8217         aix_use_runtimelinking=no
8218         exp_sym_flag='-Bexport'
8219         no_entry_flag=""
8220       else
8221         # If we're using GNU nm, then we don't want the "-C" option.
8222         # -C means demangle to AIX nm, but means don't demangle with GNU nm
8223         if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
8224           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'
8225         else
8226           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'
8227         fi
8228         aix_use_runtimelinking=no
8229
8230         # Test if we are trying to use run time linking or normal
8231         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
8232         # need to do runtime linking.
8233         case $host_os in aix4.[23]|aix4.[23].*|aix5*)
8234           for ld_flag in $LDFLAGS; do
8235           if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
8236             aix_use_runtimelinking=yes
8237             break
8238           fi
8239           done
8240         esac
8241
8242         exp_sym_flag='-bexport'
8243         no_entry_flag='-bnoentry'
8244       fi
8245
8246       # When large executables or shared objects are built, AIX ld can
8247       # have problems creating the table of contents.  If linking a library
8248       # or program results in "error TOC overflow" add -mminimal-toc to
8249       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
8250       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
8251
8252       archive_cmds=''
8253       hardcode_direct=yes
8254       hardcode_libdir_separator=':'
8255       link_all_deplibs=yes
8256
8257       if test "$GCC" = yes; then
8258         case $host_os in aix4.[012]|aix4.[012].*)
8259         # We only want to do this on AIX 4.2 and lower, the check
8260         # below for broken collect2 doesn't work under 4.3+
8261           collect2name=`${CC} -print-prog-name=collect2`
8262           if test -f "$collect2name" && \
8263            strings "$collect2name" | grep resolve_lib_name >/dev/null
8264           then
8265           # We have reworked collect2
8266           hardcode_direct=yes
8267           else
8268           # We have old collect2
8269           hardcode_direct=unsupported
8270           # It fails to find uninstalled libraries when the uninstalled
8271           # path is not listed in the libpath.  Setting hardcode_minus_L
8272           # to unsupported forces relinking
8273           hardcode_minus_L=yes
8274           hardcode_libdir_flag_spec='-L$libdir'
8275           hardcode_libdir_separator=
8276           fi
8277         esac
8278         shared_flag='-shared'
8279         if test "$aix_use_runtimelinking" = yes; then
8280           shared_flag="$shared_flag "'${wl}-G'
8281         fi
8282       else
8283         # not using gcc
8284         if test "$host_cpu" = ia64; then
8285         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
8286         # chokes on -Wl,-G. The following line is correct:
8287           shared_flag='-G'
8288         else
8289         if test "$aix_use_runtimelinking" = yes; then
8290             shared_flag='${wl}-G'
8291           else
8292             shared_flag='${wl}-bM:SRE'
8293         fi
8294         fi
8295       fi
8296
8297       # It seems that -bexpall does not export symbols beginning with
8298       # underscore (_), so it is better to generate a list of symbols to export.
8299       always_export_symbols=yes
8300       if test "$aix_use_runtimelinking" = yes; then
8301         # Warning - without using the other runtime loading flags (-brtl),
8302         # -berok will link without error, but may produce a broken library.
8303         allow_undefined_flag='-berok'
8304        # Determine the default libpath from the value encoded in an empty executable.
8305        cat >conftest.$ac_ext <<_ACEOF
8306 /* confdefs.h.  */
8307 _ACEOF
8308 cat confdefs.h >>conftest.$ac_ext
8309 cat >>conftest.$ac_ext <<_ACEOF
8310 /* end confdefs.h.  */
8311
8312 int
8313 main ()
8314 {
8315
8316   ;
8317   return 0;
8318 }
8319 _ACEOF
8320 rm -f conftest.$ac_objext conftest$ac_exeext
8321 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8322   (eval $ac_link) 2>conftest.er1
8323   ac_status=$?
8324   grep -v '^ *+' conftest.er1 >conftest.err
8325   rm -f conftest.er1
8326   cat conftest.err >&5
8327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8328   (exit $ac_status); } &&
8329          { ac_try='test -z "$ac_c_werror_flag"
8330                          || test ! -s conftest.err'
8331   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8332   (eval $ac_try) 2>&5
8333   ac_status=$?
8334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8335   (exit $ac_status); }; } &&
8336          { ac_try='test -s conftest$ac_exeext'
8337   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8338   (eval $ac_try) 2>&5
8339   ac_status=$?
8340   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8341   (exit $ac_status); }; }; then
8342
8343 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
8344 }'`
8345 # Check for a 64-bit object if we didn't find anything.
8346 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; }
8347 }'`; fi
8348 else
8349   echo "$as_me: failed program was:" >&5
8350 sed 's/^/| /' conftest.$ac_ext >&5
8351
8352 fi
8353 rm -f conftest.err conftest.$ac_objext \
8354       conftest$ac_exeext conftest.$ac_ext
8355 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
8356
8357        hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
8358         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"
8359        else
8360         if test "$host_cpu" = ia64; then
8361           hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
8362           allow_undefined_flag="-z nodefs"
8363           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"
8364         else
8365          # Determine the default libpath from the value encoded in an empty executable.
8366          cat >conftest.$ac_ext <<_ACEOF
8367 /* confdefs.h.  */
8368 _ACEOF
8369 cat confdefs.h >>conftest.$ac_ext
8370 cat >>conftest.$ac_ext <<_ACEOF
8371 /* end confdefs.h.  */
8372
8373 int
8374 main ()
8375 {
8376
8377   ;
8378   return 0;
8379 }
8380 _ACEOF
8381 rm -f conftest.$ac_objext conftest$ac_exeext
8382 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8383   (eval $ac_link) 2>conftest.er1
8384   ac_status=$?
8385   grep -v '^ *+' conftest.er1 >conftest.err
8386   rm -f conftest.er1
8387   cat conftest.err >&5
8388   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8389   (exit $ac_status); } &&
8390          { ac_try='test -z "$ac_c_werror_flag"
8391                          || test ! -s conftest.err'
8392   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8393   (eval $ac_try) 2>&5
8394   ac_status=$?
8395   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8396   (exit $ac_status); }; } &&
8397          { ac_try='test -s conftest$ac_exeext'
8398   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8399   (eval $ac_try) 2>&5
8400   ac_status=$?
8401   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8402   (exit $ac_status); }; }; then
8403
8404 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
8405 }'`
8406 # Check for a 64-bit object if we didn't find anything.
8407 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; }
8408 }'`; fi
8409 else
8410   echo "$as_me: failed program was:" >&5
8411 sed 's/^/| /' conftest.$ac_ext >&5
8412
8413 fi
8414 rm -f conftest.err conftest.$ac_objext \
8415       conftest$ac_exeext conftest.$ac_ext
8416 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
8417
8418          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
8419           # Warning - without using the other run time loading flags,
8420           # -berok will link without error, but may produce a broken library.
8421           no_undefined_flag=' ${wl}-bernotok'
8422           allow_undefined_flag=' ${wl}-berok'
8423           # -bexpall does not export symbols beginning with underscore (_)
8424           always_export_symbols=yes
8425           # Exported symbols can be pulled into shared objects from archives
8426           whole_archive_flag_spec=' '
8427           archive_cmds_need_lc=yes
8428           # This is similar to how AIX traditionally builds its shared libraries.
8429           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'
8430         fi
8431       fi
8432       ;;
8433
8434     amigaos*)
8435       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)'
8436       hardcode_libdir_flag_spec='-L$libdir'
8437       hardcode_minus_L=yes
8438       # see comment about different semantics on the GNU ld section
8439       ld_shlibs=no
8440       ;;
8441
8442     bsdi[45]*)
8443       export_dynamic_flag_spec=-rdynamic
8444       ;;
8445
8446     cygwin* | mingw* | pw32*)
8447       # When not using gcc, we currently assume that we are using
8448       # Microsoft Visual C++.
8449       # hardcode_libdir_flag_spec is actually meaningless, as there is
8450       # no search path for DLLs.
8451       hardcode_libdir_flag_spec=' '
8452       allow_undefined_flag=unsupported
8453       # Tell ltmain to make .lib files, not .a files.
8454       libext=lib
8455       # Tell ltmain to make .dll files, not .so files.
8456       shrext_cmds=".dll"
8457       # FIXME: Setting linknames here is a bad hack.
8458       archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
8459       # The linker will automatically build a .lib file if we build a DLL.
8460       old_archive_From_new_cmds='true'
8461       # FIXME: Should let the user specify the lib program.
8462       old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs'
8463       fix_srcfile_path='`cygpath -w "$srcfile"`'
8464       enable_shared_with_static_runtimes=yes
8465       ;;
8466
8467     darwin* | rhapsody*)
8468       case $host_os in
8469         rhapsody* | darwin1.[012])
8470          allow_undefined_flag='${wl}-undefined ${wl}suppress'
8471          ;;
8472        *) # Darwin 1.3 on
8473          if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
8474            allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
8475          else
8476            case ${MACOSX_DEPLOYMENT_TARGET} in
8477              10.[012])
8478                allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
8479                ;;
8480              10.*)
8481                allow_undefined_flag='${wl}-undefined ${wl}dynamic_lookup'
8482                ;;
8483            esac
8484          fi
8485          ;;
8486       esac
8487       archive_cmds_need_lc=no
8488       hardcode_direct=no
8489       hardcode_automatic=yes
8490       hardcode_shlibpath_var=unsupported
8491       whole_archive_flag_spec=''
8492       link_all_deplibs=yes
8493     if test "$GCC" = yes ; then
8494         output_verbose_link_cmd='echo'
8495         archive_cmds='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
8496       module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
8497       # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
8498       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}'
8499       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}'
8500     else
8501       case $cc_basename in
8502         xlc*)
8503          output_verbose_link_cmd='echo'
8504          archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
8505          module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
8506           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
8507          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}'
8508           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}'
8509           ;;
8510        *)
8511          ld_shlibs=no
8512           ;;
8513       esac
8514     fi
8515       ;;
8516
8517     dgux*)
8518       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8519       hardcode_libdir_flag_spec='-L$libdir'
8520       hardcode_shlibpath_var=no
8521       ;;
8522
8523     freebsd1*)
8524       ld_shlibs=no
8525       ;;
8526
8527     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
8528     # support.  Future versions do this automatically, but an explicit c++rt0.o
8529     # does not break anything, and helps significantly (at the cost of a little
8530     # extra space).
8531     freebsd2.2*)
8532       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
8533       hardcode_libdir_flag_spec='-R$libdir'
8534       hardcode_direct=yes
8535       hardcode_shlibpath_var=no
8536       ;;
8537
8538     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
8539     freebsd2*)
8540       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8541       hardcode_direct=yes
8542       hardcode_minus_L=yes
8543       hardcode_shlibpath_var=no
8544       ;;
8545
8546     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
8547     freebsd* | kfreebsd*-gnu | dragonfly*)
8548       archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
8549       hardcode_libdir_flag_spec='-R$libdir'
8550       hardcode_direct=yes
8551       hardcode_shlibpath_var=no
8552       ;;
8553
8554     hpux9*)
8555       if test "$GCC" = yes; then
8556         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'
8557       else
8558         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'
8559       fi
8560       hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8561       hardcode_libdir_separator=:
8562       hardcode_direct=yes
8563
8564       # hardcode_minus_L: Not really in the search PATH,
8565       # but as the default location of the library.
8566       hardcode_minus_L=yes
8567       export_dynamic_flag_spec='${wl}-E'
8568       ;;
8569
8570     hpux10* | hpux11*)
8571       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
8572         case $host_cpu in
8573         hppa*64*|ia64*)
8574           archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8575           ;;
8576         *)
8577           archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
8578           ;;
8579         esac
8580       else
8581         case $host_cpu in
8582         hppa*64*|ia64*)
8583           archive_cmds='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags'
8584           ;;
8585         *)
8586           archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
8587           ;;
8588         esac
8589       fi
8590       if test "$with_gnu_ld" = no; then
8591         case $host_cpu in
8592         hppa*64*)
8593           hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8594           hardcode_libdir_flag_spec_ld='+b $libdir'
8595           hardcode_libdir_separator=:
8596           hardcode_direct=no
8597           hardcode_shlibpath_var=no
8598           ;;
8599         ia64*)
8600           hardcode_libdir_flag_spec='-L$libdir'
8601           hardcode_direct=no
8602           hardcode_shlibpath_var=no
8603
8604           # hardcode_minus_L: Not really in the search PATH,
8605           # but as the default location of the library.
8606           hardcode_minus_L=yes
8607           ;;
8608         *)
8609           hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8610           hardcode_libdir_separator=:
8611           hardcode_direct=yes
8612           export_dynamic_flag_spec='${wl}-E'
8613
8614           # hardcode_minus_L: Not really in the search PATH,
8615           # but as the default location of the library.
8616           hardcode_minus_L=yes
8617           ;;
8618         esac
8619       fi
8620       ;;
8621
8622     irix5* | irix6* | nonstopux*)
8623       if test "$GCC" = yes; then
8624         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'
8625       else
8626         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'
8627         hardcode_libdir_flag_spec_ld='-rpath $libdir'
8628       fi
8629       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8630       hardcode_libdir_separator=:
8631       link_all_deplibs=yes
8632       ;;
8633
8634     netbsd*)
8635       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
8636         archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
8637       else
8638         archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
8639       fi
8640       hardcode_libdir_flag_spec='-R$libdir'
8641       hardcode_direct=yes
8642       hardcode_shlibpath_var=no
8643       ;;
8644
8645     newsos6)
8646       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8647       hardcode_direct=yes
8648       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8649       hardcode_libdir_separator=:
8650       hardcode_shlibpath_var=no
8651       ;;
8652
8653     openbsd*)
8654       hardcode_direct=yes
8655       hardcode_shlibpath_var=no
8656       if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
8657         archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8658         archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
8659         hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8660         export_dynamic_flag_spec='${wl}-E'
8661       else
8662        case $host_os in
8663          openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
8664            archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8665            hardcode_libdir_flag_spec='-R$libdir'
8666            ;;
8667          *)
8668            archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8669            hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8670            ;;
8671        esac
8672       fi
8673       ;;
8674
8675     os2*)
8676       hardcode_libdir_flag_spec='-L$libdir'
8677       hardcode_minus_L=yes
8678       allow_undefined_flag=unsupported
8679       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'
8680       old_archive_From_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
8681       ;;
8682
8683     osf3*)
8684       if test "$GCC" = yes; then
8685         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
8686         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'
8687       else
8688         allow_undefined_flag=' -expect_unresolved \*'
8689         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'
8690       fi
8691       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8692       hardcode_libdir_separator=:
8693       ;;
8694
8695     osf4* | osf5*)      # as osf3* with the addition of -msym flag
8696       if test "$GCC" = yes; then
8697         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
8698         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'
8699         hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8700       else
8701         allow_undefined_flag=' -expect_unresolved \*'
8702         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'
8703         archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
8704         $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'
8705
8706         # Both c and cxx compiler support -rpath directly
8707         hardcode_libdir_flag_spec='-rpath $libdir'
8708       fi
8709       hardcode_libdir_separator=:
8710       ;;
8711
8712     sco3.2v5*)
8713       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8714       hardcode_shlibpath_var=no
8715       export_dynamic_flag_spec='${wl}-Bexport'
8716       runpath_var=LD_RUN_PATH
8717       hardcode_runpath_var=yes
8718       ;;
8719
8720     solaris*)
8721       no_undefined_flag=' -z text'
8722       if test "$GCC" = yes; then
8723         wlarc='${wl}'
8724         archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8725         archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8726           $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
8727       else
8728         wlarc=''
8729         archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
8730         archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8731         $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
8732       fi
8733       hardcode_libdir_flag_spec='-R$libdir'
8734       hardcode_shlibpath_var=no
8735       case $host_os in
8736       solaris2.[0-5] | solaris2.[0-5].*) ;;
8737       *)
8738         # The compiler driver will combine linker options so we
8739         # cannot just pass the convience library names through
8740         # without $wl, iff we do not link with $LD.
8741         # Luckily, gcc supports the same syntax we need for Sun Studio.
8742         # Supported since Solaris 2.6 (maybe 2.5.1?)
8743         case $wlarc in
8744         '')
8745           whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;;
8746         *)
8747           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' ;;
8748         esac ;;
8749       esac
8750       link_all_deplibs=yes
8751       ;;
8752
8753     sunos4*)
8754       if test "x$host_vendor" = xsequent; then
8755         # Use $CC to link under sequent, because it throws in some extra .o
8756         # files that make .init and .fini sections work.
8757         archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
8758       else
8759         archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
8760       fi
8761       hardcode_libdir_flag_spec='-L$libdir'
8762       hardcode_direct=yes
8763       hardcode_minus_L=yes
8764       hardcode_shlibpath_var=no
8765       ;;
8766
8767     sysv4)
8768       case $host_vendor in
8769         sni)
8770           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8771           hardcode_direct=yes # is this really true???
8772         ;;
8773         siemens)
8774           ## LD is ld it makes a PLAMLIB
8775           ## CC just makes a GrossModule.
8776           archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
8777           reload_cmds='$CC -r -o $output$reload_objs'
8778           hardcode_direct=no
8779         ;;
8780         motorola)
8781           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8782           hardcode_direct=no #Motorola manual says yes, but my tests say they lie
8783         ;;
8784       esac
8785       runpath_var='LD_RUN_PATH'
8786       hardcode_shlibpath_var=no
8787       ;;
8788
8789     sysv4.3*)
8790       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8791       hardcode_shlibpath_var=no
8792       export_dynamic_flag_spec='-Bexport'
8793       ;;
8794
8795     sysv4*MP*)
8796       if test -d /usr/nec; then
8797         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8798         hardcode_shlibpath_var=no
8799         runpath_var=LD_RUN_PATH
8800         hardcode_runpath_var=yes
8801         ld_shlibs=yes
8802       fi
8803       ;;
8804
8805     sysv4.2uw2*)
8806       archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
8807       hardcode_direct=yes
8808       hardcode_minus_L=no
8809       hardcode_shlibpath_var=no
8810       hardcode_runpath_var=yes
8811       runpath_var=LD_RUN_PATH
8812       ;;
8813
8814    sysv5OpenUNIX8* | sysv5UnixWare7* |  sysv5uw[78]* | unixware7*)
8815       no_undefined_flag='${wl}-z ${wl}text'
8816       if test "$GCC" = yes; then
8817         archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8818       else
8819         archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8820       fi
8821       runpath_var='LD_RUN_PATH'
8822       hardcode_shlibpath_var=no
8823       ;;
8824
8825     sysv5*)
8826       no_undefined_flag=' -z text'
8827       # $CC -shared without GNU ld will not create a library from C++
8828       # object files and a static libstdc++, better avoid it by now
8829       archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
8830       archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8831                 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
8832       hardcode_libdir_flag_spec=
8833       hardcode_shlibpath_var=no
8834       runpath_var='LD_RUN_PATH'
8835       ;;
8836
8837     uts4*)
8838       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8839       hardcode_libdir_flag_spec='-L$libdir'
8840       hardcode_shlibpath_var=no
8841       ;;
8842
8843     *)
8844       ld_shlibs=no
8845       ;;
8846     esac
8847   fi
8848
8849 echo "$as_me:$LINENO: result: $ld_shlibs" >&5
8850 echo "${ECHO_T}$ld_shlibs" >&6
8851 test "$ld_shlibs" = no && can_build_shared=no
8852
8853 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
8854 if test "$GCC" = yes; then
8855   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
8856 fi
8857
8858 #
8859 # Do we need to explicitly link libc?
8860 #
8861 case "x$archive_cmds_need_lc" in
8862 x|xyes)
8863   # Assume -lc should be added
8864   archive_cmds_need_lc=yes
8865
8866   if test "$enable_shared" = yes && test "$GCC" = yes; then
8867     case $archive_cmds in
8868     *'~'*)
8869       # FIXME: we may have to deal with multi-command sequences.
8870       ;;
8871     '$CC '*)
8872       # Test whether the compiler implicitly links with -lc since on some
8873       # systems, -lgcc has to come before -lc. If gcc already passes -lc
8874       # to ld, don't add -lc before -lgcc.
8875       echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
8876 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6
8877       $rm conftest*
8878       printf "$lt_simple_compile_test_code" > conftest.$ac_ext
8879
8880       if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8881   (eval $ac_compile) 2>&5
8882   ac_status=$?
8883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8884   (exit $ac_status); } 2>conftest.err; then
8885         soname=conftest
8886         lib=conftest
8887         libobjs=conftest.$ac_objext
8888         deplibs=
8889         wl=$lt_prog_compiler_wl
8890         compiler_flags=-v
8891         linker_flags=-v
8892         verstring=
8893         output_objdir=.
8894         libname=conftest
8895         lt_save_allow_undefined_flag=$allow_undefined_flag
8896         allow_undefined_flag=
8897         if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5
8898   (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5
8899   ac_status=$?
8900   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8901   (exit $ac_status); }
8902         then
8903           archive_cmds_need_lc=no
8904         else
8905           archive_cmds_need_lc=yes
8906         fi
8907         allow_undefined_flag=$lt_save_allow_undefined_flag
8908       else
8909         cat conftest.err 1>&5
8910       fi
8911       $rm conftest*
8912       echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5
8913 echo "${ECHO_T}$archive_cmds_need_lc" >&6
8914       ;;
8915     esac
8916   fi
8917   ;;
8918 esac
8919
8920 echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
8921 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6
8922 library_names_spec=
8923 libname_spec='lib$name'
8924 soname_spec=
8925 shrext_cmds=".so"
8926 postinstall_cmds=
8927 postuninstall_cmds=
8928 finish_cmds=
8929 finish_eval=
8930 shlibpath_var=
8931 shlibpath_overrides_runpath=unknown
8932 version_type=none
8933 dynamic_linker="$host_os ld.so"
8934 sys_lib_dlsearch_path_spec="/lib /usr/lib"
8935 if test "$GCC" = yes; then
8936   sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
8937   if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
8938     # if the path contains ";" then we assume it to be the separator
8939     # otherwise default to the standard path separator (i.e. ":") - it is
8940     # assumed that no part of a normal pathname contains ";" but that should
8941     # okay in the real world where ";" in dirpaths is itself problematic.
8942     sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
8943   else
8944     sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
8945   fi
8946 else
8947   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
8948 fi
8949 need_lib_prefix=unknown
8950 hardcode_into_libs=no
8951
8952 # when you set need_version to no, make sure it does not cause -set_version
8953 # flags to be left without arguments
8954 need_version=unknown
8955
8956 case $host_os in
8957 aix3*)
8958   version_type=linux
8959   library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
8960   shlibpath_var=LIBPATH
8961
8962   # AIX 3 has no versioning support, so we append a major version to the name.
8963   soname_spec='${libname}${release}${shared_ext}$major'
8964   ;;
8965
8966 aix4* | aix5*)
8967   version_type=linux
8968   need_lib_prefix=no
8969   need_version=no
8970   hardcode_into_libs=yes
8971   if test "$host_cpu" = ia64; then
8972     # AIX 5 supports IA64
8973     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
8974     shlibpath_var=LD_LIBRARY_PATH
8975   else
8976     # With GCC up to 2.95.x, collect2 would create an import file
8977     # for dependence libraries.  The import file would start with
8978     # the line `#! .'.  This would cause the generated library to
8979     # depend on `.', always an invalid library.  This was fixed in
8980     # development snapshots of GCC prior to 3.0.
8981     case $host_os in
8982       aix4 | aix4.[01] | aix4.[01].*)
8983       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
8984            echo ' yes '
8985            echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
8986         :
8987       else
8988         can_build_shared=no
8989       fi
8990       ;;
8991     esac
8992     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
8993     # soname into executable. Probably we can add versioning support to
8994     # collect2, so additional links can be useful in future.
8995     if test "$aix_use_runtimelinking" = yes; then
8996       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
8997       # instead of lib<name>.a to let people know that these are not
8998       # typical AIX shared libraries.
8999       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9000     else
9001       # We preserve .a as extension for shared libraries through AIX4.2
9002       # and later when we are not doing run time linking.
9003       library_names_spec='${libname}${release}.a $libname.a'
9004       soname_spec='${libname}${release}${shared_ext}$major'
9005     fi
9006     shlibpath_var=LIBPATH
9007   fi
9008   ;;
9009
9010 amigaos*)
9011   library_names_spec='$libname.ixlibrary $libname.a'
9012   # Create ${libname}_ixlibrary.a entries in /sys/libs.
9013   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'
9014   ;;
9015
9016 beos*)
9017   library_names_spec='${libname}${shared_ext}'
9018   dynamic_linker="$host_os ld.so"
9019   shlibpath_var=LIBRARY_PATH
9020   ;;
9021
9022 bsdi[45]*)
9023   version_type=linux
9024   need_version=no
9025   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9026   soname_spec='${libname}${release}${shared_ext}$major'
9027   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
9028   shlibpath_var=LD_LIBRARY_PATH
9029   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
9030   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
9031   # the default ld.so.conf also contains /usr/contrib/lib and
9032   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
9033   # libtool to hard-code these into programs
9034   ;;
9035
9036 cygwin* | mingw* | pw32*)
9037   version_type=windows
9038   shrext_cmds=".dll"
9039   need_version=no
9040   need_lib_prefix=no
9041
9042   case $GCC,$host_os in
9043   yes,cygwin* | yes,mingw* | yes,pw32*)
9044     library_names_spec='$libname.dll.a'
9045     # DLL is installed to $(libdir)/../bin by postinstall_cmds
9046     postinstall_cmds='base_file=`basename \${file}`~
9047       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
9048       dldir=$destdir/`dirname \$dlpath`~
9049       test -d \$dldir || mkdir -p \$dldir~
9050       $install_prog $dir/$dlname \$dldir/$dlname~
9051       chmod a+x \$dldir/$dlname'
9052     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
9053       dlpath=$dir/\$dldll~
9054        $rm \$dlpath'
9055     shlibpath_overrides_runpath=yes
9056
9057     case $host_os in
9058     cygwin*)
9059       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
9060       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9061       sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
9062       ;;
9063     mingw*)
9064       # MinGW DLLs use traditional 'lib' prefix
9065       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9066       sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
9067       if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then
9068         # It is most probably a Windows format PATH printed by
9069         # mingw gcc, but we are running on Cygwin. Gcc prints its search
9070         # path with ; separators, and with drive letters. We can handle the
9071         # drive letters (cygwin fileutils understands them), so leave them,
9072         # especially as we might pass files found there to a mingw objdump,
9073         # which wouldn't understand a cygwinified path. Ahh.
9074         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
9075       else
9076         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
9077       fi
9078       ;;
9079     pw32*)
9080       # pw32 DLLs use 'pw' prefix rather than 'lib'
9081       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9082       ;;
9083     esac
9084     ;;
9085
9086   *)
9087     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
9088     ;;
9089   esac
9090   dynamic_linker='Win32 ld.exe'
9091   # FIXME: first we should search . and the directory the executable is in
9092   shlibpath_var=PATH
9093   ;;
9094
9095 darwin* | rhapsody*)
9096   dynamic_linker="$host_os dyld"
9097   version_type=darwin
9098   need_lib_prefix=no
9099   need_version=no
9100   library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
9101   soname_spec='${libname}${release}${major}$shared_ext'
9102   shlibpath_overrides_runpath=yes
9103   shlibpath_var=DYLD_LIBRARY_PATH
9104   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
9105   # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
9106   if test "$GCC" = yes; then
9107     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"`
9108   else
9109     sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
9110   fi
9111   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
9112   ;;
9113
9114 dgux*)
9115   version_type=linux
9116   need_lib_prefix=no
9117   need_version=no
9118   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
9119   soname_spec='${libname}${release}${shared_ext}$major'
9120   shlibpath_var=LD_LIBRARY_PATH
9121   ;;
9122
9123 freebsd1*)
9124   dynamic_linker=no
9125   ;;
9126
9127 kfreebsd*-gnu)
9128   version_type=linux
9129   need_lib_prefix=no
9130   need_version=no
9131   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9132   soname_spec='${libname}${release}${shared_ext}$major'
9133   shlibpath_var=LD_LIBRARY_PATH
9134   shlibpath_overrides_runpath=no
9135   hardcode_into_libs=yes
9136   dynamic_linker='GNU ld.so'
9137   ;;
9138
9139 freebsd* | dragonfly*)
9140   # DragonFly does not have aout.  When/if they implement a new
9141   # versioning mechanism, adjust this.
9142   if test -x /usr/bin/objformat; then
9143     objformat=`/usr/bin/objformat`
9144   else
9145     case $host_os in
9146     freebsd[123]*) objformat=aout ;;
9147     *) objformat=elf ;;
9148     esac
9149   fi
9150   version_type=freebsd-$objformat
9151   case $version_type in
9152     freebsd-elf*)
9153       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
9154       need_version=no
9155       need_lib_prefix=no
9156       ;;
9157     freebsd-*)
9158       library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
9159       need_version=yes
9160       ;;
9161   esac
9162   shlibpath_var=LD_LIBRARY_PATH
9163   case $host_os in
9164   freebsd2*)
9165     shlibpath_overrides_runpath=yes
9166     ;;
9167   freebsd3.[01]* | freebsdelf3.[01]*)
9168     shlibpath_overrides_runpath=yes
9169     hardcode_into_libs=yes
9170     ;;
9171   *) # from 3.2 on
9172     shlibpath_overrides_runpath=no
9173     hardcode_into_libs=yes
9174     ;;
9175   esac
9176   ;;
9177
9178 gnu*)
9179   version_type=linux
9180   need_lib_prefix=no
9181   need_version=no
9182   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
9183   soname_spec='${libname}${release}${shared_ext}$major'
9184   shlibpath_var=LD_LIBRARY_PATH
9185   hardcode_into_libs=yes
9186   ;;
9187
9188 hpux9* | hpux10* | hpux11*)
9189   # Give a soname corresponding to the major version so that dld.sl refuses to
9190   # link against other versions.
9191   version_type=sunos
9192   need_lib_prefix=no
9193   need_version=no
9194   case $host_cpu in
9195   ia64*)
9196     shrext_cmds='.so'
9197     hardcode_into_libs=yes
9198     dynamic_linker="$host_os dld.so"
9199     shlibpath_var=LD_LIBRARY_PATH
9200     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
9201     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9202     soname_spec='${libname}${release}${shared_ext}$major'
9203     if test "X$HPUX_IA64_MODE" = X32; then
9204       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
9205     else
9206       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
9207     fi
9208     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
9209     ;;
9210    hppa*64*)
9211      shrext_cmds='.sl'
9212      hardcode_into_libs=yes
9213      dynamic_linker="$host_os dld.sl"
9214      shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
9215      shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
9216      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9217      soname_spec='${libname}${release}${shared_ext}$major'
9218      sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
9219      sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
9220      ;;
9221    *)
9222     shrext_cmds='.sl'
9223     dynamic_linker="$host_os dld.sl"
9224     shlibpath_var=SHLIB_PATH
9225     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
9226     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9227     soname_spec='${libname}${release}${shared_ext}$major'
9228     ;;
9229   esac
9230   # HP-UX runs *really* slowly unless shared libraries are mode 555.
9231   postinstall_cmds='chmod 555 $lib'
9232   ;;
9233
9234 irix5* | irix6* | nonstopux*)
9235   case $host_os in
9236     nonstopux*) version_type=nonstopux ;;
9237     *)
9238         if test "$lt_cv_prog_gnu_ld" = yes; then
9239                 version_type=linux
9240         else
9241                 version_type=irix
9242         fi ;;
9243   esac
9244   need_lib_prefix=no
9245   need_version=no
9246   soname_spec='${libname}${release}${shared_ext}$major'
9247   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
9248   case $host_os in
9249   irix5* | nonstopux*)
9250     libsuff= shlibsuff=
9251     ;;
9252   *)
9253     case $LD in # libtool.m4 will add one of these switches to LD
9254     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
9255       libsuff= shlibsuff= libmagic=32-bit;;
9256     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
9257       libsuff=32 shlibsuff=N32 libmagic=N32;;
9258     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
9259       libsuff=64 shlibsuff=64 libmagic=64-bit;;
9260     *) libsuff= shlibsuff= libmagic=never-match;;
9261     esac
9262     ;;
9263   esac
9264   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
9265   shlibpath_overrides_runpath=no
9266   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
9267   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
9268   hardcode_into_libs=yes
9269   ;;
9270
9271 # No shared lib support for Linux oldld, aout, or coff.
9272 linux*oldld* | linux*aout* | linux*coff*)
9273   dynamic_linker=no
9274   ;;
9275
9276 # This must be Linux ELF.
9277 linux*)
9278   version_type=linux
9279   need_lib_prefix=no
9280   need_version=no
9281   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9282   soname_spec='${libname}${release}${shared_ext}$major'
9283   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
9284   shlibpath_var=LD_LIBRARY_PATH
9285   shlibpath_overrides_runpath=no
9286   # This implies no fast_install, which is unacceptable.
9287   # Some rework will be needed to allow for fast_install
9288   # before this can be enabled.
9289   hardcode_into_libs=yes
9290
9291   # Append ld.so.conf contents to the search path
9292   if test -f /etc/ld.so.conf; then
9293     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' ' '`
9294     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
9295   fi
9296
9297   # We used to test for /lib/ld.so.1 and disable shared libraries on
9298   # powerpc, because MkLinux only supported shared libraries with the
9299   # GNU dynamic linker.  Since this was broken with cross compilers,
9300   # most powerpc-linux boxes support dynamic linking these days and
9301   # people can always --disable-shared, the test was removed, and we
9302   # assume the GNU/Linux dynamic linker is in use.
9303   dynamic_linker='GNU/Linux ld.so'
9304   ;;
9305
9306 knetbsd*-gnu)
9307   version_type=linux
9308   need_lib_prefix=no
9309   need_version=no
9310   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9311   soname_spec='${libname}${release}${shared_ext}$major'
9312   shlibpath_var=LD_LIBRARY_PATH
9313   shlibpath_overrides_runpath=no
9314   hardcode_into_libs=yes
9315   dynamic_linker='GNU ld.so'
9316   ;;
9317
9318 netbsd*)
9319   version_type=sunos
9320   need_lib_prefix=no
9321   need_version=no
9322   if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
9323     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9324     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
9325     dynamic_linker='NetBSD (a.out) ld.so'
9326   else
9327     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9328     soname_spec='${libname}${release}${shared_ext}$major'
9329     dynamic_linker='NetBSD ld.elf_so'
9330   fi
9331   shlibpath_var=LD_LIBRARY_PATH
9332   shlibpath_overrides_runpath=yes
9333   hardcode_into_libs=yes
9334   ;;
9335
9336 newsos6)
9337   version_type=linux
9338   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9339   shlibpath_var=LD_LIBRARY_PATH
9340   shlibpath_overrides_runpath=yes
9341   ;;
9342
9343 nto-qnx*)
9344   version_type=linux
9345   need_lib_prefix=no
9346   need_version=no
9347   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9348   soname_spec='${libname}${release}${shared_ext}$major'
9349   shlibpath_var=LD_LIBRARY_PATH
9350   shlibpath_overrides_runpath=yes
9351   ;;
9352
9353 openbsd*)
9354   version_type=sunos
9355   need_lib_prefix=no
9356   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
9357   case $host_os in
9358     openbsd3.3 | openbsd3.3.*) need_version=yes ;;
9359     *)                         need_version=no  ;;
9360   esac
9361   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9362   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
9363   shlibpath_var=LD_LIBRARY_PATH
9364   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
9365     case $host_os in
9366       openbsd2.[89] | openbsd2.[89].*)
9367         shlibpath_overrides_runpath=no
9368         ;;
9369       *)
9370         shlibpath_overrides_runpath=yes
9371         ;;
9372       esac
9373   else
9374     shlibpath_overrides_runpath=yes
9375   fi
9376   ;;
9377
9378 os2*)
9379   libname_spec='$name'
9380   shrext_cmds=".dll"
9381   need_lib_prefix=no
9382   library_names_spec='$libname${shared_ext} $libname.a'
9383   dynamic_linker='OS/2 ld.exe'
9384   shlibpath_var=LIBPATH
9385   ;;
9386
9387 osf3* | osf4* | osf5*)
9388   version_type=osf
9389   need_lib_prefix=no
9390   need_version=no
9391   soname_spec='${libname}${release}${shared_ext}$major'
9392   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9393   shlibpath_var=LD_LIBRARY_PATH
9394   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
9395   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
9396   ;;
9397
9398 sco3.2v5*)
9399   version_type=osf
9400   soname_spec='${libname}${release}${shared_ext}$major'
9401   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9402   shlibpath_var=LD_LIBRARY_PATH
9403   ;;
9404
9405 solaris*)
9406   version_type=linux
9407   need_lib_prefix=no
9408   need_version=no
9409   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9410   soname_spec='${libname}${release}${shared_ext}$major'
9411   shlibpath_var=LD_LIBRARY_PATH
9412   shlibpath_overrides_runpath=yes
9413   hardcode_into_libs=yes
9414   # ldd complains unless libraries are executable
9415   postinstall_cmds='chmod +x $lib'
9416   ;;
9417
9418 sunos4*)
9419   version_type=sunos
9420   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9421   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
9422   shlibpath_var=LD_LIBRARY_PATH
9423   shlibpath_overrides_runpath=yes
9424   if test "$with_gnu_ld" = yes; then
9425     need_lib_prefix=no
9426   fi
9427   need_version=yes
9428   ;;
9429
9430 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
9431   version_type=linux
9432   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9433   soname_spec='${libname}${release}${shared_ext}$major'
9434   shlibpath_var=LD_LIBRARY_PATH
9435   case $host_vendor in
9436     sni)
9437       shlibpath_overrides_runpath=no
9438       need_lib_prefix=no
9439       export_dynamic_flag_spec='${wl}-Blargedynsym'
9440       runpath_var=LD_RUN_PATH
9441       ;;
9442     siemens)
9443       need_lib_prefix=no
9444       ;;
9445     motorola)
9446       need_lib_prefix=no
9447       need_version=no
9448       shlibpath_overrides_runpath=no
9449       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
9450       ;;
9451   esac
9452   ;;
9453
9454 sysv4*MP*)
9455   if test -d /usr/nec ;then
9456     version_type=linux
9457     library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
9458     soname_spec='$libname${shared_ext}.$major'
9459     shlibpath_var=LD_LIBRARY_PATH
9460   fi
9461   ;;
9462
9463 uts4*)
9464   version_type=linux
9465   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9466   soname_spec='${libname}${release}${shared_ext}$major'
9467   shlibpath_var=LD_LIBRARY_PATH
9468   ;;
9469
9470 *)
9471   dynamic_linker=no
9472   ;;
9473 esac
9474 echo "$as_me:$LINENO: result: $dynamic_linker" >&5
9475 echo "${ECHO_T}$dynamic_linker" >&6
9476 test "$dynamic_linker" = no && can_build_shared=no
9477
9478 echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
9479 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6
9480 hardcode_action=
9481 if test -n "$hardcode_libdir_flag_spec" || \
9482    test -n "$runpath_var" || \
9483    test "X$hardcode_automatic" = "Xyes" ; then
9484
9485   # We can hardcode non-existant directories.
9486   if test "$hardcode_direct" != no &&
9487      # If the only mechanism to avoid hardcoding is shlibpath_var, we
9488      # have to relink, otherwise we might link with an installed library
9489      # when we should be linking with a yet-to-be-installed one
9490      ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, )" != no &&
9491      test "$hardcode_minus_L" != no; then
9492     # Linking always hardcodes the temporary library directory.
9493     hardcode_action=relink
9494   else
9495     # We can link without hardcoding, and we can hardcode nonexisting dirs.
9496     hardcode_action=immediate
9497   fi
9498 else
9499   # We cannot hardcode anything, or else we can only hardcode existing
9500   # directories.
9501   hardcode_action=unsupported
9502 fi
9503 echo "$as_me:$LINENO: result: $hardcode_action" >&5
9504 echo "${ECHO_T}$hardcode_action" >&6
9505
9506 if test "$hardcode_action" = relink; then
9507   # Fast installation is not supported
9508   enable_fast_install=no
9509 elif test "$shlibpath_overrides_runpath" = yes ||
9510      test "$enable_shared" = no; then
9511   # Fast installation is not necessary
9512   enable_fast_install=needless
9513 fi
9514
9515 striplib=
9516 old_striplib=
9517 echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5
9518 echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&6
9519 if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
9520   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
9521   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
9522   echo "$as_me:$LINENO: result: yes" >&5
9523 echo "${ECHO_T}yes" >&6
9524 else
9525 # FIXME - insert some real tests, host_os isn't really good enough
9526   case $host_os in
9527    darwin*)
9528        if test -n "$STRIP" ; then
9529          striplib="$STRIP -x"
9530          echo "$as_me:$LINENO: result: yes" >&5
9531 echo "${ECHO_T}yes" >&6
9532        else
9533   echo "$as_me:$LINENO: result: no" >&5
9534 echo "${ECHO_T}no" >&6
9535 fi
9536        ;;
9537    *)
9538   echo "$as_me:$LINENO: result: no" >&5
9539 echo "${ECHO_T}no" >&6
9540     ;;
9541   esac
9542 fi
9543
9544 if test "x$enable_dlopen" != xyes; then
9545   enable_dlopen=unknown
9546   enable_dlopen_self=unknown
9547   enable_dlopen_self_static=unknown
9548 else
9549   lt_cv_dlopen=no
9550   lt_cv_dlopen_libs=
9551
9552   case $host_os in
9553   beos*)
9554     lt_cv_dlopen="load_add_on"
9555     lt_cv_dlopen_libs=
9556     lt_cv_dlopen_self=yes
9557     ;;
9558
9559   mingw* | pw32*)
9560     lt_cv_dlopen="LoadLibrary"
9561     lt_cv_dlopen_libs=
9562    ;;
9563
9564   cygwin*)
9565     lt_cv_dlopen="dlopen"
9566     lt_cv_dlopen_libs=
9567    ;;
9568
9569   darwin*)
9570   # if libdl is installed we need to link against it
9571     echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
9572 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
9573 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
9574   echo $ECHO_N "(cached) $ECHO_C" >&6
9575 else
9576   ac_check_lib_save_LIBS=$LIBS
9577 LIBS="-ldl  $LIBS"
9578 cat >conftest.$ac_ext <<_ACEOF
9579 /* confdefs.h.  */
9580 _ACEOF
9581 cat confdefs.h >>conftest.$ac_ext
9582 cat >>conftest.$ac_ext <<_ACEOF
9583 /* end confdefs.h.  */
9584
9585 /* Override any gcc2 internal prototype to avoid an error.  */
9586 #ifdef __cplusplus
9587 extern "C"
9588 #endif
9589 /* We use char because int might match the return type of a gcc2
9590    builtin and then its argument prototype would still apply.  */
9591 char dlopen ();
9592 int
9593 main ()
9594 {
9595 dlopen ();
9596   ;
9597   return 0;
9598 }
9599 _ACEOF
9600 rm -f conftest.$ac_objext conftest$ac_exeext
9601 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9602   (eval $ac_link) 2>conftest.er1
9603   ac_status=$?
9604   grep -v '^ *+' conftest.er1 >conftest.err
9605   rm -f conftest.er1
9606   cat conftest.err >&5
9607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9608   (exit $ac_status); } &&
9609          { ac_try='test -z "$ac_c_werror_flag"
9610                          || test ! -s conftest.err'
9611   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9612   (eval $ac_try) 2>&5
9613   ac_status=$?
9614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9615   (exit $ac_status); }; } &&
9616          { ac_try='test -s conftest$ac_exeext'
9617   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9618   (eval $ac_try) 2>&5
9619   ac_status=$?
9620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9621   (exit $ac_status); }; }; then
9622   ac_cv_lib_dl_dlopen=yes
9623 else
9624   echo "$as_me: failed program was:" >&5
9625 sed 's/^/| /' conftest.$ac_ext >&5
9626
9627 ac_cv_lib_dl_dlopen=no
9628 fi
9629 rm -f conftest.err conftest.$ac_objext \
9630       conftest$ac_exeext conftest.$ac_ext
9631 LIBS=$ac_check_lib_save_LIBS
9632 fi
9633 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
9634 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
9635 if test $ac_cv_lib_dl_dlopen = yes; then
9636   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
9637 else
9638
9639     lt_cv_dlopen="dyld"
9640     lt_cv_dlopen_libs=
9641     lt_cv_dlopen_self=yes
9642
9643 fi
9644
9645    ;;
9646
9647   *)
9648     echo "$as_me:$LINENO: checking for shl_load" >&5
9649 echo $ECHO_N "checking for shl_load... $ECHO_C" >&6
9650 if test "${ac_cv_func_shl_load+set}" = set; then
9651   echo $ECHO_N "(cached) $ECHO_C" >&6
9652 else
9653   cat >conftest.$ac_ext <<_ACEOF
9654 /* confdefs.h.  */
9655 _ACEOF
9656 cat confdefs.h >>conftest.$ac_ext
9657 cat >>conftest.$ac_ext <<_ACEOF
9658 /* end confdefs.h.  */
9659 /* Define shl_load to an innocuous variant, in case <limits.h> declares shl_load.
9660    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9661 #define shl_load innocuous_shl_load
9662
9663 /* System header to define __stub macros and hopefully few prototypes,
9664     which can conflict with char shl_load (); below.
9665     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9666     <limits.h> exists even on freestanding compilers.  */
9667
9668 #ifdef __STDC__
9669 # include <limits.h>
9670 #else
9671 # include <assert.h>
9672 #endif
9673
9674 #undef shl_load
9675
9676 /* Override any gcc2 internal prototype to avoid an error.  */
9677 #ifdef __cplusplus
9678 extern "C"
9679 {
9680 #endif
9681 /* We use char because int might match the return type of a gcc2
9682    builtin and then its argument prototype would still apply.  */
9683 char shl_load ();
9684 /* The GNU C library defines this for functions which it implements
9685     to always fail with ENOSYS.  Some functions are actually named
9686     something starting with __ and the normal name is an alias.  */
9687 #if defined (__stub_shl_load) || defined (__stub___shl_load)
9688 choke me
9689 #else
9690 char (*f) () = shl_load;
9691 #endif
9692 #ifdef __cplusplus
9693 }
9694 #endif
9695
9696 int
9697 main ()
9698 {
9699 return f != shl_load;
9700   ;
9701   return 0;
9702 }
9703 _ACEOF
9704 rm -f conftest.$ac_objext conftest$ac_exeext
9705 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9706   (eval $ac_link) 2>conftest.er1
9707   ac_status=$?
9708   grep -v '^ *+' conftest.er1 >conftest.err
9709   rm -f conftest.er1
9710   cat conftest.err >&5
9711   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9712   (exit $ac_status); } &&
9713          { ac_try='test -z "$ac_c_werror_flag"
9714                          || test ! -s conftest.err'
9715   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9716   (eval $ac_try) 2>&5
9717   ac_status=$?
9718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9719   (exit $ac_status); }; } &&
9720          { ac_try='test -s conftest$ac_exeext'
9721   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9722   (eval $ac_try) 2>&5
9723   ac_status=$?
9724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9725   (exit $ac_status); }; }; then
9726   ac_cv_func_shl_load=yes
9727 else
9728   echo "$as_me: failed program was:" >&5
9729 sed 's/^/| /' conftest.$ac_ext >&5
9730
9731 ac_cv_func_shl_load=no
9732 fi
9733 rm -f conftest.err conftest.$ac_objext \
9734       conftest$ac_exeext conftest.$ac_ext
9735 fi
9736 echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5
9737 echo "${ECHO_T}$ac_cv_func_shl_load" >&6
9738 if test $ac_cv_func_shl_load = yes; then
9739   lt_cv_dlopen="shl_load"
9740 else
9741   echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
9742 echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6
9743 if test "${ac_cv_lib_dld_shl_load+set}" = set; then
9744   echo $ECHO_N "(cached) $ECHO_C" >&6
9745 else
9746   ac_check_lib_save_LIBS=$LIBS
9747 LIBS="-ldld  $LIBS"
9748 cat >conftest.$ac_ext <<_ACEOF
9749 /* confdefs.h.  */
9750 _ACEOF
9751 cat confdefs.h >>conftest.$ac_ext
9752 cat >>conftest.$ac_ext <<_ACEOF
9753 /* end confdefs.h.  */
9754
9755 /* Override any gcc2 internal prototype to avoid an error.  */
9756 #ifdef __cplusplus
9757 extern "C"
9758 #endif
9759 /* We use char because int might match the return type of a gcc2
9760    builtin and then its argument prototype would still apply.  */
9761 char shl_load ();
9762 int
9763 main ()
9764 {
9765 shl_load ();
9766   ;
9767   return 0;
9768 }
9769 _ACEOF
9770 rm -f conftest.$ac_objext conftest$ac_exeext
9771 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9772   (eval $ac_link) 2>conftest.er1
9773   ac_status=$?
9774   grep -v '^ *+' conftest.er1 >conftest.err
9775   rm -f conftest.er1
9776   cat conftest.err >&5
9777   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9778   (exit $ac_status); } &&
9779          { ac_try='test -z "$ac_c_werror_flag"
9780                          || test ! -s conftest.err'
9781   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9782   (eval $ac_try) 2>&5
9783   ac_status=$?
9784   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9785   (exit $ac_status); }; } &&
9786          { ac_try='test -s conftest$ac_exeext'
9787   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9788   (eval $ac_try) 2>&5
9789   ac_status=$?
9790   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9791   (exit $ac_status); }; }; then
9792   ac_cv_lib_dld_shl_load=yes
9793 else
9794   echo "$as_me: failed program was:" >&5
9795 sed 's/^/| /' conftest.$ac_ext >&5
9796
9797 ac_cv_lib_dld_shl_load=no
9798 fi
9799 rm -f conftest.err conftest.$ac_objext \
9800       conftest$ac_exeext conftest.$ac_ext
9801 LIBS=$ac_check_lib_save_LIBS
9802 fi
9803 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
9804 echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6
9805 if test $ac_cv_lib_dld_shl_load = yes; then
9806   lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"
9807 else
9808   echo "$as_me:$LINENO: checking for dlopen" >&5
9809 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6
9810 if test "${ac_cv_func_dlopen+set}" = set; then
9811   echo $ECHO_N "(cached) $ECHO_C" >&6
9812 else
9813   cat >conftest.$ac_ext <<_ACEOF
9814 /* confdefs.h.  */
9815 _ACEOF
9816 cat confdefs.h >>conftest.$ac_ext
9817 cat >>conftest.$ac_ext <<_ACEOF
9818 /* end confdefs.h.  */
9819 /* Define dlopen to an innocuous variant, in case <limits.h> declares dlopen.
9820    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9821 #define dlopen innocuous_dlopen
9822
9823 /* System header to define __stub macros and hopefully few prototypes,
9824     which can conflict with char dlopen (); below.
9825     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9826     <limits.h> exists even on freestanding compilers.  */
9827
9828 #ifdef __STDC__
9829 # include <limits.h>
9830 #else
9831 # include <assert.h>
9832 #endif
9833
9834 #undef dlopen
9835
9836 /* Override any gcc2 internal prototype to avoid an error.  */
9837 #ifdef __cplusplus
9838 extern "C"
9839 {
9840 #endif
9841 /* We use char because int might match the return type of a gcc2
9842    builtin and then its argument prototype would still apply.  */
9843 char dlopen ();
9844 /* The GNU C library defines this for functions which it implements
9845     to always fail with ENOSYS.  Some functions are actually named
9846     something starting with __ and the normal name is an alias.  */
9847 #if defined (__stub_dlopen) || defined (__stub___dlopen)
9848 choke me
9849 #else
9850 char (*f) () = dlopen;
9851 #endif
9852 #ifdef __cplusplus
9853 }
9854 #endif
9855
9856 int
9857 main ()
9858 {
9859 return f != dlopen;
9860   ;
9861   return 0;
9862 }
9863 _ACEOF
9864 rm -f conftest.$ac_objext conftest$ac_exeext
9865 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9866   (eval $ac_link) 2>conftest.er1
9867   ac_status=$?
9868   grep -v '^ *+' conftest.er1 >conftest.err
9869   rm -f conftest.er1
9870   cat conftest.err >&5
9871   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9872   (exit $ac_status); } &&
9873          { ac_try='test -z "$ac_c_werror_flag"
9874                          || test ! -s conftest.err'
9875   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9876   (eval $ac_try) 2>&5
9877   ac_status=$?
9878   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9879   (exit $ac_status); }; } &&
9880          { ac_try='test -s conftest$ac_exeext'
9881   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9882   (eval $ac_try) 2>&5
9883   ac_status=$?
9884   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9885   (exit $ac_status); }; }; then
9886   ac_cv_func_dlopen=yes
9887 else
9888   echo "$as_me: failed program was:" >&5
9889 sed 's/^/| /' conftest.$ac_ext >&5
9890
9891 ac_cv_func_dlopen=no
9892 fi
9893 rm -f conftest.err conftest.$ac_objext \
9894       conftest$ac_exeext conftest.$ac_ext
9895 fi
9896 echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
9897 echo "${ECHO_T}$ac_cv_func_dlopen" >&6
9898 if test $ac_cv_func_dlopen = yes; then
9899   lt_cv_dlopen="dlopen"
9900 else
9901   echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
9902 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
9903 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
9904   echo $ECHO_N "(cached) $ECHO_C" >&6
9905 else
9906   ac_check_lib_save_LIBS=$LIBS
9907 LIBS="-ldl  $LIBS"
9908 cat >conftest.$ac_ext <<_ACEOF
9909 /* confdefs.h.  */
9910 _ACEOF
9911 cat confdefs.h >>conftest.$ac_ext
9912 cat >>conftest.$ac_ext <<_ACEOF
9913 /* end confdefs.h.  */
9914
9915 /* Override any gcc2 internal prototype to avoid an error.  */
9916 #ifdef __cplusplus
9917 extern "C"
9918 #endif
9919 /* We use char because int might match the return type of a gcc2
9920    builtin and then its argument prototype would still apply.  */
9921 char dlopen ();
9922 int
9923 main ()
9924 {
9925 dlopen ();
9926   ;
9927   return 0;
9928 }
9929 _ACEOF
9930 rm -f conftest.$ac_objext conftest$ac_exeext
9931 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9932   (eval $ac_link) 2>conftest.er1
9933   ac_status=$?
9934   grep -v '^ *+' conftest.er1 >conftest.err
9935   rm -f conftest.er1
9936   cat conftest.err >&5
9937   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9938   (exit $ac_status); } &&
9939          { ac_try='test -z "$ac_c_werror_flag"
9940                          || test ! -s conftest.err'
9941   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9942   (eval $ac_try) 2>&5
9943   ac_status=$?
9944   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9945   (exit $ac_status); }; } &&
9946          { ac_try='test -s conftest$ac_exeext'
9947   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9948   (eval $ac_try) 2>&5
9949   ac_status=$?
9950   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9951   (exit $ac_status); }; }; then
9952   ac_cv_lib_dl_dlopen=yes
9953 else
9954   echo "$as_me: failed program was:" >&5
9955 sed 's/^/| /' conftest.$ac_ext >&5
9956
9957 ac_cv_lib_dl_dlopen=no
9958 fi
9959 rm -f conftest.err conftest.$ac_objext \
9960       conftest$ac_exeext conftest.$ac_ext
9961 LIBS=$ac_check_lib_save_LIBS
9962 fi
9963 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
9964 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
9965 if test $ac_cv_lib_dl_dlopen = yes; then
9966   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
9967 else
9968   echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5
9969 echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6
9970 if test "${ac_cv_lib_svld_dlopen+set}" = set; then
9971   echo $ECHO_N "(cached) $ECHO_C" >&6
9972 else
9973   ac_check_lib_save_LIBS=$LIBS
9974 LIBS="-lsvld  $LIBS"
9975 cat >conftest.$ac_ext <<_ACEOF
9976 /* confdefs.h.  */
9977 _ACEOF
9978 cat confdefs.h >>conftest.$ac_ext
9979 cat >>conftest.$ac_ext <<_ACEOF
9980 /* end confdefs.h.  */
9981
9982 /* Override any gcc2 internal prototype to avoid an error.  */
9983 #ifdef __cplusplus
9984 extern "C"
9985 #endif
9986 /* We use char because int might match the return type of a gcc2
9987    builtin and then its argument prototype would still apply.  */
9988 char dlopen ();
9989 int
9990 main ()
9991 {
9992 dlopen ();
9993   ;
9994   return 0;
9995 }
9996 _ACEOF
9997 rm -f conftest.$ac_objext conftest$ac_exeext
9998 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9999   (eval $ac_link) 2>conftest.er1
10000   ac_status=$?
10001   grep -v '^ *+' conftest.er1 >conftest.err
10002   rm -f conftest.er1
10003   cat conftest.err >&5
10004   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10005   (exit $ac_status); } &&
10006          { ac_try='test -z "$ac_c_werror_flag"
10007                          || test ! -s conftest.err'
10008   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10009   (eval $ac_try) 2>&5
10010   ac_status=$?
10011   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10012   (exit $ac_status); }; } &&
10013          { ac_try='test -s conftest$ac_exeext'
10014   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10015   (eval $ac_try) 2>&5
10016   ac_status=$?
10017   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10018   (exit $ac_status); }; }; then
10019   ac_cv_lib_svld_dlopen=yes
10020 else
10021   echo "$as_me: failed program was:" >&5
10022 sed 's/^/| /' conftest.$ac_ext >&5
10023
10024 ac_cv_lib_svld_dlopen=no
10025 fi
10026 rm -f conftest.err conftest.$ac_objext \
10027       conftest$ac_exeext conftest.$ac_ext
10028 LIBS=$ac_check_lib_save_LIBS
10029 fi
10030 echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5
10031 echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6
10032 if test $ac_cv_lib_svld_dlopen = yes; then
10033   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
10034 else
10035   echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5
10036 echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6
10037 if test "${ac_cv_lib_dld_dld_link+set}" = set; then
10038   echo $ECHO_N "(cached) $ECHO_C" >&6
10039 else
10040   ac_check_lib_save_LIBS=$LIBS
10041 LIBS="-ldld  $LIBS"
10042 cat >conftest.$ac_ext <<_ACEOF
10043 /* confdefs.h.  */
10044 _ACEOF
10045 cat confdefs.h >>conftest.$ac_ext
10046 cat >>conftest.$ac_ext <<_ACEOF
10047 /* end confdefs.h.  */
10048
10049 /* Override any gcc2 internal prototype to avoid an error.  */
10050 #ifdef __cplusplus
10051 extern "C"
10052 #endif
10053 /* We use char because int might match the return type of a gcc2
10054    builtin and then its argument prototype would still apply.  */
10055 char dld_link ();
10056 int
10057 main ()
10058 {
10059 dld_link ();
10060   ;
10061   return 0;
10062 }
10063 _ACEOF
10064 rm -f conftest.$ac_objext conftest$ac_exeext
10065 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10066   (eval $ac_link) 2>conftest.er1
10067   ac_status=$?
10068   grep -v '^ *+' conftest.er1 >conftest.err
10069   rm -f conftest.er1
10070   cat conftest.err >&5
10071   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10072   (exit $ac_status); } &&
10073          { ac_try='test -z "$ac_c_werror_flag"
10074                          || test ! -s conftest.err'
10075   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10076   (eval $ac_try) 2>&5
10077   ac_status=$?
10078   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10079   (exit $ac_status); }; } &&
10080          { ac_try='test -s conftest$ac_exeext'
10081   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10082   (eval $ac_try) 2>&5
10083   ac_status=$?
10084   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10085   (exit $ac_status); }; }; then
10086   ac_cv_lib_dld_dld_link=yes
10087 else
10088   echo "$as_me: failed program was:" >&5
10089 sed 's/^/| /' conftest.$ac_ext >&5
10090
10091 ac_cv_lib_dld_dld_link=no
10092 fi
10093 rm -f conftest.err conftest.$ac_objext \
10094       conftest$ac_exeext conftest.$ac_ext
10095 LIBS=$ac_check_lib_save_LIBS
10096 fi
10097 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5
10098 echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6
10099 if test $ac_cv_lib_dld_dld_link = yes; then
10100   lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"
10101 fi
10102
10103
10104 fi
10105
10106
10107 fi
10108
10109
10110 fi
10111
10112
10113 fi
10114
10115
10116 fi
10117
10118     ;;
10119   esac
10120
10121   if test "x$lt_cv_dlopen" != xno; then
10122     enable_dlopen=yes
10123   else
10124     enable_dlopen=no
10125   fi
10126
10127   case $lt_cv_dlopen in
10128   dlopen)
10129     save_CPPFLAGS="$CPPFLAGS"
10130     test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
10131
10132     save_LDFLAGS="$LDFLAGS"
10133     eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
10134
10135     save_LIBS="$LIBS"
10136     LIBS="$lt_cv_dlopen_libs $LIBS"
10137
10138     echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5
10139 echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6
10140 if test "${lt_cv_dlopen_self+set}" = set; then
10141   echo $ECHO_N "(cached) $ECHO_C" >&6
10142 else
10143           if test "$cross_compiling" = yes; then :
10144   lt_cv_dlopen_self=cross
10145 else
10146   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10147   lt_status=$lt_dlunknown
10148   cat > conftest.$ac_ext <<EOF
10149 #line 10149 "configure"
10150 #include "confdefs.h"
10151
10152 #if HAVE_DLFCN_H
10153 #include <dlfcn.h>
10154 #endif
10155
10156 #include <stdio.h>
10157
10158 #ifdef RTLD_GLOBAL
10159 #  define LT_DLGLOBAL           RTLD_GLOBAL
10160 #else
10161 #  ifdef DL_GLOBAL
10162 #    define LT_DLGLOBAL         DL_GLOBAL
10163 #  else
10164 #    define LT_DLGLOBAL         0
10165 #  endif
10166 #endif
10167
10168 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
10169    find out it does not work in some platform. */
10170 #ifndef LT_DLLAZY_OR_NOW
10171 #  ifdef RTLD_LAZY
10172 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
10173 #  else
10174 #    ifdef DL_LAZY
10175 #      define LT_DLLAZY_OR_NOW          DL_LAZY
10176 #    else
10177 #      ifdef RTLD_NOW
10178 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
10179 #      else
10180 #        ifdef DL_NOW
10181 #          define LT_DLLAZY_OR_NOW      DL_NOW
10182 #        else
10183 #          define LT_DLLAZY_OR_NOW      0
10184 #        endif
10185 #      endif
10186 #    endif
10187 #  endif
10188 #endif
10189
10190 #ifdef __cplusplus
10191 extern "C" void exit (int);
10192 #endif
10193
10194 void fnord() { int i=42;}
10195 int main ()
10196 {
10197   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10198   int status = $lt_dlunknown;
10199
10200   if (self)
10201     {
10202       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
10203       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
10204       /* dlclose (self); */
10205     }
10206
10207     exit (status);
10208 }
10209 EOF
10210   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10211   (eval $ac_link) 2>&5
10212   ac_status=$?
10213   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10214   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
10215     (./conftest; exit; ) >&5 2>/dev/null
10216     lt_status=$?
10217     case x$lt_status in
10218       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
10219       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
10220       x$lt_unknown|x*) lt_cv_dlopen_self=no ;;
10221     esac
10222   else :
10223     # compilation failed
10224     lt_cv_dlopen_self=no
10225   fi
10226 fi
10227 rm -fr conftest*
10228
10229
10230 fi
10231 echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5
10232 echo "${ECHO_T}$lt_cv_dlopen_self" >&6
10233
10234     if test "x$lt_cv_dlopen_self" = xyes; then
10235       LDFLAGS="$LDFLAGS $link_static_flag"
10236       echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5
10237 echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6
10238 if test "${lt_cv_dlopen_self_static+set}" = set; then
10239   echo $ECHO_N "(cached) $ECHO_C" >&6
10240 else
10241           if test "$cross_compiling" = yes; then :
10242   lt_cv_dlopen_self_static=cross
10243 else
10244   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10245   lt_status=$lt_dlunknown
10246   cat > conftest.$ac_ext <<EOF
10247 #line 10247 "configure"
10248 #include "confdefs.h"
10249
10250 #if HAVE_DLFCN_H
10251 #include <dlfcn.h>
10252 #endif
10253
10254 #include <stdio.h>
10255
10256 #ifdef RTLD_GLOBAL
10257 #  define LT_DLGLOBAL           RTLD_GLOBAL
10258 #else
10259 #  ifdef DL_GLOBAL
10260 #    define LT_DLGLOBAL         DL_GLOBAL
10261 #  else
10262 #    define LT_DLGLOBAL         0
10263 #  endif
10264 #endif
10265
10266 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
10267    find out it does not work in some platform. */
10268 #ifndef LT_DLLAZY_OR_NOW
10269 #  ifdef RTLD_LAZY
10270 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
10271 #  else
10272 #    ifdef DL_LAZY
10273 #      define LT_DLLAZY_OR_NOW          DL_LAZY
10274 #    else
10275 #      ifdef RTLD_NOW
10276 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
10277 #      else
10278 #        ifdef DL_NOW
10279 #          define LT_DLLAZY_OR_NOW      DL_NOW
10280 #        else
10281 #          define LT_DLLAZY_OR_NOW      0
10282 #        endif
10283 #      endif
10284 #    endif
10285 #  endif
10286 #endif
10287
10288 #ifdef __cplusplus
10289 extern "C" void exit (int);
10290 #endif
10291
10292 void fnord() { int i=42;}
10293 int main ()
10294 {
10295   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10296   int status = $lt_dlunknown;
10297
10298   if (self)
10299     {
10300       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
10301       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
10302       /* dlclose (self); */
10303     }
10304
10305     exit (status);
10306 }
10307 EOF
10308   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10309   (eval $ac_link) 2>&5
10310   ac_status=$?
10311   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10312   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
10313     (./conftest; exit; ) >&5 2>/dev/null
10314     lt_status=$?
10315     case x$lt_status in
10316       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
10317       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
10318       x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;;
10319     esac
10320   else :
10321     # compilation failed
10322     lt_cv_dlopen_self_static=no
10323   fi
10324 fi
10325 rm -fr conftest*
10326
10327
10328 fi
10329 echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5
10330 echo "${ECHO_T}$lt_cv_dlopen_self_static" >&6
10331     fi
10332
10333     CPPFLAGS="$save_CPPFLAGS"
10334     LDFLAGS="$save_LDFLAGS"
10335     LIBS="$save_LIBS"
10336     ;;
10337   esac
10338
10339   case $lt_cv_dlopen_self in
10340   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
10341   *) enable_dlopen_self=unknown ;;
10342   esac
10343
10344   case $lt_cv_dlopen_self_static in
10345   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
10346   *) enable_dlopen_self_static=unknown ;;
10347   esac
10348 fi
10349
10350
10351 # Report which librarie types wil actually be built
10352 echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
10353 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6
10354 echo "$as_me:$LINENO: result: $can_build_shared" >&5
10355 echo "${ECHO_T}$can_build_shared" >&6
10356
10357 echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
10358 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6
10359 test "$can_build_shared" = "no" && enable_shared=no
10360
10361 # On AIX, shared libraries and static libraries use the same namespace, and
10362 # are all built from PIC.
10363 case $host_os in
10364 aix3*)
10365   test "$enable_shared" = yes && enable_static=no
10366   if test -n "$RANLIB"; then
10367     archive_cmds="$archive_cmds~\$RANLIB \$lib"
10368     postinstall_cmds='$RANLIB $lib'
10369   fi
10370   ;;
10371
10372 aix4* | aix5*)
10373   if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
10374     test "$enable_shared" = yes && enable_static=no
10375   fi
10376     ;;
10377 esac
10378 echo "$as_me:$LINENO: result: $enable_shared" >&5
10379 echo "${ECHO_T}$enable_shared" >&6
10380
10381 echo "$as_me:$LINENO: checking whether to build static libraries" >&5
10382 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6
10383 # Make sure either enable_shared or enable_static is yes.
10384 test "$enable_shared" = yes || enable_static=yes
10385 echo "$as_me:$LINENO: result: $enable_static" >&5
10386 echo "${ECHO_T}$enable_static" >&6
10387
10388 # The else clause should only fire when bootstrapping the
10389 # libtool distribution, otherwise you forgot to ship ltmain.sh
10390 # with your package, and you will get complaints that there are
10391 # no rules to generate ltmain.sh.
10392 if test -f "$ltmain"; then
10393   # See if we are running on zsh, and set the options which allow our commands through
10394   # without removal of \ escapes.
10395   if test -n "${ZSH_VERSION+set}" ; then
10396     setopt NO_GLOB_SUBST
10397   fi
10398   # Now quote all the things that may contain metacharacters while being
10399   # careful not to overquote the AC_SUBSTed values.  We take copies of the
10400   # variables and quote the copies for generation of the libtool script.
10401   for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
10402     SED SHELL STRIP \
10403     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
10404     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
10405     deplibs_check_method reload_flag reload_cmds need_locks \
10406     lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
10407     lt_cv_sys_global_symbol_to_c_name_address \
10408     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
10409     old_postinstall_cmds old_postuninstall_cmds \
10410     compiler \
10411     CC \
10412     LD \
10413     lt_prog_compiler_wl \
10414     lt_prog_compiler_pic \
10415     lt_prog_compiler_static \
10416     lt_prog_compiler_no_builtin_flag \
10417     export_dynamic_flag_spec \
10418     thread_safe_flag_spec \
10419     whole_archive_flag_spec \
10420     enable_shared_with_static_runtimes \
10421     old_archive_cmds \
10422     old_archive_from_new_cmds \
10423     predep_objects \
10424     postdep_objects \
10425     predeps \
10426     postdeps \
10427     compiler_lib_search_path \
10428     archive_cmds \
10429     archive_expsym_cmds \
10430     postinstall_cmds \
10431     postuninstall_cmds \
10432     old_archive_from_expsyms_cmds \
10433     allow_undefined_flag \
10434     no_undefined_flag \
10435     export_symbols_cmds \
10436     hardcode_libdir_flag_spec \
10437     hardcode_libdir_flag_spec_ld \
10438     hardcode_libdir_separator \
10439     hardcode_automatic \
10440     module_cmds \
10441     module_expsym_cmds \
10442     lt_cv_prog_compiler_c_o \
10443     exclude_expsyms \
10444     include_expsyms; do
10445
10446     case $var in
10447     old_archive_cmds | \
10448     old_archive_from_new_cmds | \
10449     archive_cmds | \
10450     archive_expsym_cmds | \
10451     module_cmds | \
10452     module_expsym_cmds | \
10453     old_archive_from_expsyms_cmds | \
10454     export_symbols_cmds | \
10455     extract_expsyms_cmds | reload_cmds | finish_cmds | \
10456     postinstall_cmds | postuninstall_cmds | \
10457     old_postinstall_cmds | old_postuninstall_cmds | \
10458     sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
10459       # Double-quote double-evaled strings.
10460       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
10461       ;;
10462     *)
10463       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
10464       ;;
10465     esac
10466   done
10467
10468   case $lt_echo in
10469   *'\$0 --fallback-echo"')
10470     lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
10471     ;;
10472   esac
10473
10474 cfgfile="${ofile}T"
10475   trap "$rm \"$cfgfile\"; exit 1" 1 2 15
10476   $rm -f "$cfgfile"
10477   { echo "$as_me:$LINENO: creating $ofile" >&5
10478 echo "$as_me: creating $ofile" >&6;}
10479
10480   cat <<__EOF__ >> "$cfgfile"
10481 #! $SHELL
10482
10483 # `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
10484 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
10485 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
10486 #
10487 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
10488 # Free Software Foundation, Inc.
10489 #
10490 # This file is part of GNU Libtool:
10491 # Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
10492 #
10493 # This program is free software; you can redistribute it and/or modify
10494 # it under the terms of the GNU General Public License as published by
10495 # the Free Software Foundation; either version 2 of the License, or
10496 # (at your option) any later version.
10497 #
10498 # This program is distributed in the hope that it will be useful, but
10499 # WITHOUT ANY WARRANTY; without even the implied warranty of
10500 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
10501 # General Public License for more details.
10502 #
10503 # You should have received a copy of the GNU General Public License
10504 # along with this program; if not, write to the Free Software
10505 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
10506 #
10507 # As a special exception to the GNU General Public License, if you
10508 # distribute this file as part of a program that contains a
10509 # configuration script generated by Autoconf, you may include it under
10510 # the same distribution terms that you use for the rest of that program.
10511
10512 # A sed program that does not truncate output.
10513 SED=$lt_SED
10514
10515 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
10516 Xsed="$SED -e 1s/^X//"
10517
10518 # The HP-UX ksh and POSIX shell print the target directory to stdout
10519 # if CDPATH is set.
10520 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
10521
10522 # The names of the tagged configurations supported by this script.
10523 available_tags=
10524
10525 # ### BEGIN LIBTOOL CONFIG
10526
10527 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
10528
10529 # Shell to use when invoking shell scripts.
10530 SHELL=$lt_SHELL
10531
10532 # Whether or not to build shared libraries.
10533 build_libtool_libs=$enable_shared
10534
10535 # Whether or not to build static libraries.
10536 build_old_libs=$enable_static
10537
10538 # Whether or not to add -lc for building shared libraries.
10539 build_libtool_need_lc=$archive_cmds_need_lc
10540
10541 # Whether or not to disallow shared libs when runtime libs are static
10542 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
10543
10544 # Whether or not to optimize for fast installation.
10545 fast_install=$enable_fast_install
10546
10547 # The host system.
10548 host_alias=$host_alias
10549 host=$host
10550 host_os=$host_os
10551
10552 # The build system.
10553 build_alias=$build_alias
10554 build=$build
10555 build_os=$build_os
10556
10557 # An echo program that does not interpret backslashes.
10558 echo=$lt_echo
10559
10560 # The archiver.
10561 AR=$lt_AR
10562 AR_FLAGS=$lt_AR_FLAGS
10563
10564 # A C compiler.
10565 LTCC=$lt_LTCC
10566
10567 # A language-specific compiler.
10568 CC=$lt_compiler
10569
10570 # Is the compiler the GNU C compiler?
10571 with_gcc=$GCC
10572
10573 # An ERE matcher.
10574 EGREP=$lt_EGREP
10575
10576 # The linker used to build libraries.
10577 LD=$lt_LD
10578
10579 # Whether we need hard or soft links.
10580 LN_S=$lt_LN_S
10581
10582 # A BSD-compatible nm program.
10583 NM=$lt_NM
10584
10585 # A symbol stripping program
10586 STRIP=$lt_STRIP
10587
10588 # Used to examine libraries when file_magic_cmd begins "file"
10589 MAGIC_CMD=$MAGIC_CMD
10590
10591 # Used on cygwin: DLL creation program.
10592 DLLTOOL="$DLLTOOL"
10593
10594 # Used on cygwin: object dumper.
10595 OBJDUMP="$OBJDUMP"
10596
10597 # Used on cygwin: assembler.
10598 AS="$AS"
10599
10600 # The name of the directory that contains temporary libtool files.
10601 objdir=$objdir
10602
10603 # How to create reloadable object files.
10604 reload_flag=$lt_reload_flag
10605 reload_cmds=$lt_reload_cmds
10606
10607 # How to pass a linker flag through the compiler.
10608 wl=$lt_lt_prog_compiler_wl
10609
10610 # Object file suffix (normally "o").
10611 objext="$ac_objext"
10612
10613 # Old archive suffix (normally "a").
10614 libext="$libext"
10615
10616 # Shared library suffix (normally ".so").
10617 shrext_cmds='$shrext_cmds'
10618
10619 # Executable file suffix (normally "").
10620 exeext="$exeext"
10621
10622 # Additional compiler flags for building library objects.
10623 pic_flag=$lt_lt_prog_compiler_pic
10624 pic_mode=$pic_mode
10625
10626 # What is the maximum length of a command?
10627 max_cmd_len=$lt_cv_sys_max_cmd_len
10628
10629 # Does compiler simultaneously support -c and -o options?
10630 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
10631
10632 # Must we lock files when doing compilation?
10633 need_locks=$lt_need_locks
10634
10635 # Do we need the lib prefix for modules?
10636 need_lib_prefix=$need_lib_prefix
10637
10638 # Do we need a version for libraries?
10639 need_version=$need_version
10640
10641 # Whether dlopen is supported.
10642 dlopen_support=$enable_dlopen
10643
10644 # Whether dlopen of programs is supported.
10645 dlopen_self=$enable_dlopen_self
10646
10647 # Whether dlopen of statically linked programs is supported.
10648 dlopen_self_static=$enable_dlopen_self_static
10649
10650 # Compiler flag to prevent dynamic linking.
10651 link_static_flag=$lt_lt_prog_compiler_static
10652
10653 # Compiler flag to turn off builtin functions.
10654 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
10655
10656 # Compiler flag to allow reflexive dlopens.
10657 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
10658
10659 # Compiler flag to generate shared objects directly from archives.
10660 whole_archive_flag_spec=$lt_whole_archive_flag_spec
10661
10662 # Compiler flag to generate thread-safe objects.
10663 thread_safe_flag_spec=$lt_thread_safe_flag_spec
10664
10665 # Library versioning type.
10666 version_type=$version_type
10667
10668 # Format of library name prefix.
10669 libname_spec=$lt_libname_spec
10670
10671 # List of archive names.  First name is the real one, the rest are links.
10672 # The last name is the one that the linker finds with -lNAME.
10673 library_names_spec=$lt_library_names_spec
10674
10675 # The coded name of the library, if different from the real name.
10676 soname_spec=$lt_soname_spec
10677
10678 # Commands used to build and install an old-style archive.
10679 RANLIB=$lt_RANLIB
10680 old_archive_cmds=$lt_old_archive_cmds
10681 old_postinstall_cmds=$lt_old_postinstall_cmds
10682 old_postuninstall_cmds=$lt_old_postuninstall_cmds
10683
10684 # Create an old-style archive from a shared archive.
10685 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
10686
10687 # Create a temporary old-style archive to link instead of a shared archive.
10688 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
10689
10690 # Commands used to build and install a shared archive.
10691 archive_cmds=$lt_archive_cmds
10692 archive_expsym_cmds=$lt_archive_expsym_cmds
10693 postinstall_cmds=$lt_postinstall_cmds
10694 postuninstall_cmds=$lt_postuninstall_cmds
10695
10696 # Commands used to build a loadable module (assumed same as above if empty)
10697 module_cmds=$lt_module_cmds
10698 module_expsym_cmds=$lt_module_expsym_cmds
10699
10700 # Commands to strip libraries.
10701 old_striplib=$lt_old_striplib
10702 striplib=$lt_striplib
10703
10704 # Dependencies to place before the objects being linked to create a
10705 # shared library.
10706 predep_objects=$lt_predep_objects
10707
10708 # Dependencies to place after the objects being linked to create a
10709 # shared library.
10710 postdep_objects=$lt_postdep_objects
10711
10712 # Dependencies to place before the objects being linked to create a
10713 # shared library.
10714 predeps=$lt_predeps
10715
10716 # Dependencies to place after the objects being linked to create a
10717 # shared library.
10718 postdeps=$lt_postdeps
10719
10720 # The library search path used internally by the compiler when linking
10721 # a shared library.
10722 compiler_lib_search_path=$lt_compiler_lib_search_path
10723
10724 # Method to check whether dependent libraries are shared objects.
10725 deplibs_check_method=$lt_deplibs_check_method
10726
10727 # Command to use when deplibs_check_method == file_magic.
10728 file_magic_cmd=$lt_file_magic_cmd
10729
10730 # Flag that allows shared libraries with undefined symbols to be built.
10731 allow_undefined_flag=$lt_allow_undefined_flag
10732
10733 # Flag that forces no undefined symbols.
10734 no_undefined_flag=$lt_no_undefined_flag
10735
10736 # Commands used to finish a libtool library installation in a directory.
10737 finish_cmds=$lt_finish_cmds
10738
10739 # Same as above, but a single script fragment to be evaled but not shown.
10740 finish_eval=$lt_finish_eval
10741
10742 # Take the output of nm and produce a listing of raw symbols and C names.
10743 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
10744
10745 # Transform the output of nm in a proper C declaration
10746 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
10747
10748 # Transform the output of nm in a C name address pair
10749 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
10750
10751 # This is the shared library runtime path variable.
10752 runpath_var=$runpath_var
10753
10754 # This is the shared library path variable.
10755 shlibpath_var=$shlibpath_var
10756
10757 # Is shlibpath searched before the hard-coded library search path?
10758 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
10759
10760 # How to hardcode a shared library path into an executable.
10761 hardcode_action=$hardcode_action
10762
10763 # Whether we should hardcode library paths into libraries.
10764 hardcode_into_libs=$hardcode_into_libs
10765
10766 # Flag to hardcode \$libdir into a binary during linking.
10767 # This must work even if \$libdir does not exist.
10768 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
10769
10770 # If ld is used when linking, flag to hardcode \$libdir into
10771 # a binary during linking. This must work even if \$libdir does
10772 # not exist.
10773 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
10774
10775 # Whether we need a single -rpath flag with a separated argument.
10776 hardcode_libdir_separator=$lt_hardcode_libdir_separator
10777
10778 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
10779 # resulting binary.
10780 hardcode_direct=$hardcode_direct
10781
10782 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
10783 # resulting binary.
10784 hardcode_minus_L=$hardcode_minus_L
10785
10786 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
10787 # the resulting binary.
10788 hardcode_shlibpath_var=$hardcode_shlibpath_var
10789
10790 # Set to yes if building a shared library automatically hardcodes DIR into the library
10791 # and all subsequent libraries and executables linked against it.
10792 hardcode_automatic=$hardcode_automatic
10793
10794 # Variables whose values should be saved in libtool wrapper scripts and
10795 # restored at relink time.
10796 variables_saved_for_relink="$variables_saved_for_relink"
10797
10798 # Whether libtool must link a program against all its dependency libraries.
10799 link_all_deplibs=$link_all_deplibs
10800
10801 # Compile-time system search path for libraries
10802 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
10803
10804 # Run-time system search path for libraries
10805 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
10806
10807 # Fix the shell variable \$srcfile for the compiler.
10808 fix_srcfile_path="$fix_srcfile_path"
10809
10810 # Set to yes if exported symbols are required.
10811 always_export_symbols=$always_export_symbols
10812
10813 # The commands to list exported symbols.
10814 export_symbols_cmds=$lt_export_symbols_cmds
10815
10816 # The commands to extract the exported symbol list from a shared archive.
10817 extract_expsyms_cmds=$lt_extract_expsyms_cmds
10818
10819 # Symbols that should not be listed in the preloaded symbols.
10820 exclude_expsyms=$lt_exclude_expsyms
10821
10822 # Symbols that must always be exported.
10823 include_expsyms=$lt_include_expsyms
10824
10825 # ### END LIBTOOL CONFIG
10826
10827 __EOF__
10828
10829
10830   case $host_os in
10831   aix3*)
10832     cat <<\EOF >> "$cfgfile"
10833
10834 # AIX sometimes has problems with the GCC collect2 program.  For some
10835 # reason, if we set the COLLECT_NAMES environment variable, the problems
10836 # vanish in a puff of smoke.
10837 if test "X${COLLECT_NAMES+set}" != Xset; then
10838   COLLECT_NAMES=
10839   export COLLECT_NAMES
10840 fi
10841 EOF
10842     ;;
10843   esac
10844
10845   # We use sed instead of cat because bash on DJGPP gets confused if
10846   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
10847   # text mode, it properly converts lines to CR/LF.  This bash problem
10848   # is reportedly fixed, but why not run on old versions too?
10849   sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
10850
10851   mv -f "$cfgfile" "$ofile" || \
10852     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
10853   chmod +x "$ofile"
10854
10855 else
10856   # If there is no Makefile yet, we rely on a make rule to execute
10857   # `config.status --recheck' to rerun these tests and create the
10858   # libtool script then.
10859   ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
10860   if test -f "$ltmain_in"; then
10861     test -f Makefile && make "$ltmain"
10862   fi
10863 fi
10864
10865
10866 ac_ext=c
10867 ac_cpp='$CPP $CPPFLAGS'
10868 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10869 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10870 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10871
10872 CC="$lt_save_CC"
10873
10874
10875 # Check whether --with-tags or --without-tags was given.
10876 if test "${with_tags+set}" = set; then
10877   withval="$with_tags"
10878   tagnames="$withval"
10879 fi;
10880
10881 if test -f "$ltmain" && test -n "$tagnames"; then
10882   if test ! -f "${ofile}"; then
10883     { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not exist" >&5
10884 echo "$as_me: WARNING: output file \`$ofile' does not exist" >&2;}
10885   fi
10886
10887   if test -z "$LTCC"; then
10888     eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
10889     if test -z "$LTCC"; then
10890       { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not look like a libtool script" >&5
10891 echo "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;}
10892     else
10893       { echo "$as_me:$LINENO: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5
10894 echo "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;}
10895     fi
10896   fi
10897
10898   # Extract list of available tagged configurations in $ofile.
10899   # Note that this assumes the entire list is on one line.
10900   available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
10901
10902   lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
10903   for tagname in $tagnames; do
10904     IFS="$lt_save_ifs"
10905     # Check whether tagname contains only valid characters
10906     case `$echo "X$tagname" | $Xsed -e 's:[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]::g'` in
10907     "") ;;
10908     *)  { { echo "$as_me:$LINENO: error: invalid tag name: $tagname" >&5
10909 echo "$as_me: error: invalid tag name: $tagname" >&2;}
10910    { (exit 1); exit 1; }; }
10911         ;;
10912     esac
10913
10914     if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
10915     then
10916       { { echo "$as_me:$LINENO: error: tag name \"$tagname\" already exists" >&5
10917 echo "$as_me: error: tag name \"$tagname\" already exists" >&2;}
10918    { (exit 1); exit 1; }; }
10919     fi
10920
10921     # Update the list of available tags.
10922     if test -n "$tagname"; then
10923       echo appending configuration tag \"$tagname\" to $ofile
10924
10925       case $tagname in
10926       CXX)
10927         if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
10928             ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
10929             (test "X$CXX" != "Xg++"))) ; then
10930           :
10931         else
10932           tagname=""
10933         fi
10934         ;;
10935
10936       F77)
10937         if test -n "$F77" && test "X$F77" != "Xno"; then
10938           :
10939         else
10940           tagname=""
10941         fi
10942         ;;
10943
10944       GCJ)
10945         if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
10946           :
10947         else
10948           tagname=""
10949         fi
10950         ;;
10951
10952       RC)
10953
10954
10955
10956 # Source file extension for RC test sources.
10957 ac_ext=rc
10958
10959 # Object file extension for compiled RC test sources.
10960 objext=o
10961 objext_RC=$objext
10962
10963 # Code to be used in simple compile tests
10964 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
10965
10966 # Code to be used in simple link tests
10967 lt_simple_link_test_code="$lt_simple_compile_test_code"
10968
10969 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
10970
10971 # If no C compiler was specified, use CC.
10972 LTCC=${LTCC-"$CC"}
10973
10974 # Allow CC to be a program name with arguments.
10975 compiler=$CC
10976
10977
10978 # save warnings/boilerplate of simple test code
10979 ac_outfile=conftest.$ac_objext
10980 printf "$lt_simple_compile_test_code" >conftest.$ac_ext
10981 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
10982 _lt_compiler_boilerplate=`cat conftest.err`
10983 $rm conftest*
10984
10985 ac_outfile=conftest.$ac_objext
10986 printf "$lt_simple_link_test_code" >conftest.$ac_ext
10987 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
10988 _lt_linker_boilerplate=`cat conftest.err`
10989 $rm conftest*
10990
10991
10992 # Allow CC to be a program name with arguments.
10993 lt_save_CC="$CC"
10994 CC=${RC-"windres"}
10995 compiler=$CC
10996 compiler_RC=$CC
10997 for cc_temp in $compiler""; do
10998   case $cc_temp in
10999     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
11000     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
11001     \-*) ;;
11002     *) break;;
11003   esac
11004 done
11005 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
11006
11007 lt_cv_prog_compiler_c_o_RC=yes
11008
11009 # The else clause should only fire when bootstrapping the
11010 # libtool distribution, otherwise you forgot to ship ltmain.sh
11011 # with your package, and you will get complaints that there are
11012 # no rules to generate ltmain.sh.
11013 if test -f "$ltmain"; then
11014   # See if we are running on zsh, and set the options which allow our commands through
11015   # without removal of \ escapes.
11016   if test -n "${ZSH_VERSION+set}" ; then
11017     setopt NO_GLOB_SUBST
11018   fi
11019   # Now quote all the things that may contain metacharacters while being
11020   # careful not to overquote the AC_SUBSTed values.  We take copies of the
11021   # variables and quote the copies for generation of the libtool script.
11022   for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
11023     SED SHELL STRIP \
11024     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
11025     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
11026     deplibs_check_method reload_flag reload_cmds need_locks \
11027     lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
11028     lt_cv_sys_global_symbol_to_c_name_address \
11029     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
11030     old_postinstall_cmds old_postuninstall_cmds \
11031     compiler_RC \
11032     CC_RC \
11033     LD_RC \
11034     lt_prog_compiler_wl_RC \
11035     lt_prog_compiler_pic_RC \
11036     lt_prog_compiler_static_RC \
11037     lt_prog_compiler_no_builtin_flag_RC \
11038     export_dynamic_flag_spec_RC \
11039     thread_safe_flag_spec_RC \
11040     whole_archive_flag_spec_RC \
11041     enable_shared_with_static_runtimes_RC \
11042     old_archive_cmds_RC \
11043     old_archive_from_new_cmds_RC \
11044     predep_objects_RC \
11045     postdep_objects_RC \
11046     predeps_RC \
11047     postdeps_RC \
11048     compiler_lib_search_path_RC \
11049     archive_cmds_RC \
11050     archive_expsym_cmds_RC \
11051     postinstall_cmds_RC \
11052     postuninstall_cmds_RC \
11053     old_archive_from_expsyms_cmds_RC \
11054     allow_undefined_flag_RC \
11055     no_undefined_flag_RC \
11056     export_symbols_cmds_RC \
11057     hardcode_libdir_flag_spec_RC \
11058     hardcode_libdir_flag_spec_ld_RC \
11059     hardcode_libdir_separator_RC \
11060     hardcode_automatic_RC \
11061     module_cmds_RC \
11062     module_expsym_cmds_RC \
11063     lt_cv_prog_compiler_c_o_RC \
11064     exclude_expsyms_RC \
11065     include_expsyms_RC; do
11066
11067     case $var in
11068     old_archive_cmds_RC | \
11069     old_archive_from_new_cmds_RC | \
11070     archive_cmds_RC | \
11071     archive_expsym_cmds_RC | \
11072     module_cmds_RC | \
11073     module_expsym_cmds_RC | \
11074     old_archive_from_expsyms_cmds_RC | \
11075     export_symbols_cmds_RC | \
11076     extract_expsyms_cmds | reload_cmds | finish_cmds | \
11077     postinstall_cmds | postuninstall_cmds | \
11078     old_postinstall_cmds | old_postuninstall_cmds | \
11079     sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
11080       # Double-quote double-evaled strings.
11081       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
11082       ;;
11083     *)
11084       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
11085       ;;
11086     esac
11087   done
11088
11089   case $lt_echo in
11090   *'\$0 --fallback-echo"')
11091     lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
11092     ;;
11093   esac
11094
11095 cfgfile="$ofile"
11096
11097   cat <<__EOF__ >> "$cfgfile"
11098 # ### BEGIN LIBTOOL TAG CONFIG: $tagname
11099
11100 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
11101
11102 # Shell to use when invoking shell scripts.
11103 SHELL=$lt_SHELL
11104
11105 # Whether or not to build shared libraries.
11106 build_libtool_libs=$enable_shared
11107
11108 # Whether or not to build static libraries.
11109 build_old_libs=$enable_static
11110
11111 # Whether or not to add -lc for building shared libraries.
11112 build_libtool_need_lc=$archive_cmds_need_lc_RC
11113
11114 # Whether or not to disallow shared libs when runtime libs are static
11115 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_RC
11116
11117 # Whether or not to optimize for fast installation.
11118 fast_install=$enable_fast_install
11119
11120 # The host system.
11121 host_alias=$host_alias
11122 host=$host
11123 host_os=$host_os
11124
11125 # The build system.
11126 build_alias=$build_alias
11127 build=$build
11128 build_os=$build_os
11129
11130 # An echo program that does not interpret backslashes.
11131 echo=$lt_echo
11132
11133 # The archiver.
11134 AR=$lt_AR
11135 AR_FLAGS=$lt_AR_FLAGS
11136
11137 # A C compiler.
11138 LTCC=$lt_LTCC
11139
11140 # A language-specific compiler.
11141 CC=$lt_compiler_RC
11142
11143 # Is the compiler the GNU C compiler?
11144 with_gcc=$GCC_RC
11145
11146 # An ERE matcher.
11147 EGREP=$lt_EGREP
11148
11149 # The linker used to build libraries.
11150 LD=$lt_LD_RC
11151
11152 # Whether we need hard or soft links.
11153 LN_S=$lt_LN_S
11154
11155 # A BSD-compatible nm program.
11156 NM=$lt_NM
11157
11158 # A symbol stripping program
11159 STRIP=$lt_STRIP
11160
11161 # Used to examine libraries when file_magic_cmd begins "file"
11162 MAGIC_CMD=$MAGIC_CMD
11163
11164 # Used on cygwin: DLL creation program.
11165 DLLTOOL="$DLLTOOL"
11166
11167 # Used on cygwin: object dumper.
11168 OBJDUMP="$OBJDUMP"
11169
11170 # Used on cygwin: assembler.
11171 AS="$AS"
11172
11173 # The name of the directory that contains temporary libtool files.
11174 objdir=$objdir
11175
11176 # How to create reloadable object files.
11177 reload_flag=$lt_reload_flag
11178 reload_cmds=$lt_reload_cmds
11179
11180 # How to pass a linker flag through the compiler.
11181 wl=$lt_lt_prog_compiler_wl_RC
11182
11183 # Object file suffix (normally "o").
11184 objext="$ac_objext"
11185
11186 # Old archive suffix (normally "a").
11187 libext="$libext"
11188
11189 # Shared library suffix (normally ".so").
11190 shrext_cmds='$shrext_cmds'
11191
11192 # Executable file suffix (normally "").
11193 exeext="$exeext"
11194
11195 # Additional compiler flags for building library objects.
11196 pic_flag=$lt_lt_prog_compiler_pic_RC
11197 pic_mode=$pic_mode
11198
11199 # What is the maximum length of a command?
11200 max_cmd_len=$lt_cv_sys_max_cmd_len
11201
11202 # Does compiler simultaneously support -c and -o options?
11203 compiler_c_o=$lt_lt_cv_prog_compiler_c_o_RC
11204
11205 # Must we lock files when doing compilation?
11206 need_locks=$lt_need_locks
11207
11208 # Do we need the lib prefix for modules?
11209 need_lib_prefix=$need_lib_prefix
11210
11211 # Do we need a version for libraries?
11212 need_version=$need_version
11213
11214 # Whether dlopen is supported.
11215 dlopen_support=$enable_dlopen
11216
11217 # Whether dlopen of programs is supported.
11218 dlopen_self=$enable_dlopen_self
11219
11220 # Whether dlopen of statically linked programs is supported.
11221 dlopen_self_static=$enable_dlopen_self_static
11222
11223 # Compiler flag to prevent dynamic linking.
11224 link_static_flag=$lt_lt_prog_compiler_static_RC
11225
11226 # Compiler flag to turn off builtin functions.
11227 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_RC
11228
11229 # Compiler flag to allow reflexive dlopens.
11230 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_RC
11231
11232 # Compiler flag to generate shared objects directly from archives.
11233 whole_archive_flag_spec=$lt_whole_archive_flag_spec_RC
11234
11235 # Compiler flag to generate thread-safe objects.
11236 thread_safe_flag_spec=$lt_thread_safe_flag_spec_RC
11237
11238 # Library versioning type.
11239 version_type=$version_type
11240
11241 # Format of library name prefix.
11242 libname_spec=$lt_libname_spec
11243
11244 # List of archive names.  First name is the real one, the rest are links.
11245 # The last name is the one that the linker finds with -lNAME.
11246 library_names_spec=$lt_library_names_spec
11247
11248 # The coded name of the library, if different from the real name.
11249 soname_spec=$lt_soname_spec
11250
11251 # Commands used to build and install an old-style archive.
11252 RANLIB=$lt_RANLIB
11253 old_archive_cmds=$lt_old_archive_cmds_RC
11254 old_postinstall_cmds=$lt_old_postinstall_cmds
11255 old_postuninstall_cmds=$lt_old_postuninstall_cmds
11256
11257 # Create an old-style archive from a shared archive.
11258 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_RC
11259
11260 # Create a temporary old-style archive to link instead of a shared archive.
11261 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_RC
11262
11263 # Commands used to build and install a shared archive.
11264 archive_cmds=$lt_archive_cmds_RC
11265 archive_expsym_cmds=$lt_archive_expsym_cmds_RC
11266 postinstall_cmds=$lt_postinstall_cmds
11267 postuninstall_cmds=$lt_postuninstall_cmds
11268
11269 # Commands used to build a loadable module (assumed same as above if empty)
11270 module_cmds=$lt_module_cmds_RC
11271 module_expsym_cmds=$lt_module_expsym_cmds_RC
11272
11273 # Commands to strip libraries.
11274 old_striplib=$lt_old_striplib
11275 striplib=$lt_striplib
11276
11277 # Dependencies to place before the objects being linked to create a
11278 # shared library.
11279 predep_objects=$lt_predep_objects_RC
11280
11281 # Dependencies to place after the objects being linked to create a
11282 # shared library.
11283 postdep_objects=$lt_postdep_objects_RC
11284
11285 # Dependencies to place before the objects being linked to create a
11286 # shared library.
11287 predeps=$lt_predeps_RC
11288
11289 # Dependencies to place after the objects being linked to create a
11290 # shared library.
11291 postdeps=$lt_postdeps_RC
11292
11293 # The library search path used internally by the compiler when linking
11294 # a shared library.
11295 compiler_lib_search_path=$lt_compiler_lib_search_path_RC
11296
11297 # Method to check whether dependent libraries are shared objects.
11298 deplibs_check_method=$lt_deplibs_check_method
11299
11300 # Command to use when deplibs_check_method == file_magic.
11301 file_magic_cmd=$lt_file_magic_cmd
11302
11303 # Flag that allows shared libraries with undefined symbols to be built.
11304 allow_undefined_flag=$lt_allow_undefined_flag_RC
11305
11306 # Flag that forces no undefined symbols.
11307 no_undefined_flag=$lt_no_undefined_flag_RC
11308
11309 # Commands used to finish a libtool library installation in a directory.
11310 finish_cmds=$lt_finish_cmds
11311
11312 # Same as above, but a single script fragment to be evaled but not shown.
11313 finish_eval=$lt_finish_eval
11314
11315 # Take the output of nm and produce a listing of raw symbols and C names.
11316 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
11317
11318 # Transform the output of nm in a proper C declaration
11319 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
11320
11321 # Transform the output of nm in a C name address pair
11322 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
11323
11324 # This is the shared library runtime path variable.
11325 runpath_var=$runpath_var
11326
11327 # This is the shared library path variable.
11328 shlibpath_var=$shlibpath_var
11329
11330 # Is shlibpath searched before the hard-coded library search path?
11331 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
11332
11333 # How to hardcode a shared library path into an executable.
11334 hardcode_action=$hardcode_action_RC
11335
11336 # Whether we should hardcode library paths into libraries.
11337 hardcode_into_libs=$hardcode_into_libs
11338
11339 # Flag to hardcode \$libdir into a binary during linking.
11340 # This must work even if \$libdir does not exist.
11341 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_RC
11342
11343 # If ld is used when linking, flag to hardcode \$libdir into
11344 # a binary during linking. This must work even if \$libdir does
11345 # not exist.
11346 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_RC
11347
11348 # Whether we need a single -rpath flag with a separated argument.
11349 hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC
11350
11351 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
11352 # resulting binary.
11353 hardcode_direct=$hardcode_direct_RC
11354
11355 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
11356 # resulting binary.
11357 hardcode_minus_L=$hardcode_minus_L_RC
11358
11359 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
11360 # the resulting binary.
11361 hardcode_shlibpath_var=$hardcode_shlibpath_var_RC
11362
11363 # Set to yes if building a shared library automatically hardcodes DIR into the library
11364 # and all subsequent libraries and executables linked against it.
11365 hardcode_automatic=$hardcode_automatic_RC
11366
11367 # Variables whose values should be saved in libtool wrapper scripts and
11368 # restored at relink time.
11369 variables_saved_for_relink="$variables_saved_for_relink"
11370
11371 # Whether libtool must link a program against all its dependency libraries.
11372 link_all_deplibs=$link_all_deplibs_RC
11373
11374 # Compile-time system search path for libraries
11375 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
11376
11377 # Run-time system search path for libraries
11378 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
11379
11380 # Fix the shell variable \$srcfile for the compiler.
11381 fix_srcfile_path="$fix_srcfile_path_RC"
11382
11383 # Set to yes if exported symbols are required.
11384 always_export_symbols=$always_export_symbols_RC
11385
11386 # The commands to list exported symbols.
11387 export_symbols_cmds=$lt_export_symbols_cmds_RC
11388
11389 # The commands to extract the exported symbol list from a shared archive.
11390 extract_expsyms_cmds=$lt_extract_expsyms_cmds
11391
11392 # Symbols that should not be listed in the preloaded symbols.
11393 exclude_expsyms=$lt_exclude_expsyms_RC
11394
11395 # Symbols that must always be exported.
11396 include_expsyms=$lt_include_expsyms_RC
11397
11398 # ### END LIBTOOL TAG CONFIG: $tagname
11399
11400 __EOF__
11401
11402
11403 else
11404   # If there is no Makefile yet, we rely on a make rule to execute
11405   # `config.status --recheck' to rerun these tests and create the
11406   # libtool script then.
11407   ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
11408   if test -f "$ltmain_in"; then
11409     test -f Makefile && make "$ltmain"
11410   fi
11411 fi
11412
11413
11414 ac_ext=c
11415 ac_cpp='$CPP $CPPFLAGS'
11416 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11417 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11418 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11419
11420 CC="$lt_save_CC"
11421
11422         ;;
11423
11424       *)
11425         { { echo "$as_me:$LINENO: error: Unsupported tag name: $tagname" >&5
11426 echo "$as_me: error: Unsupported tag name: $tagname" >&2;}
11427    { (exit 1); exit 1; }; }
11428         ;;
11429       esac
11430
11431       # Append the new tag name to the list of available tags.
11432       if test -n "$tagname" ; then
11433       available_tags="$available_tags $tagname"
11434     fi
11435     fi
11436   done
11437   IFS="$lt_save_ifs"
11438
11439   # Now substitute the updated list of available tags.
11440   if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
11441     mv "${ofile}T" "$ofile"
11442     chmod +x "$ofile"
11443   else
11444     rm -f "${ofile}T"
11445     { { echo "$as_me:$LINENO: error: unable to update list of available tagged configurations." >&5
11446 echo "$as_me: error: unable to update list of available tagged configurations." >&2;}
11447    { (exit 1); exit 1; }; }
11448   fi
11449 fi
11450
11451
11452
11453 # This can be used to rebuild libtool when needed
11454 LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
11455
11456 # Always use our own libtool.
11457 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
11458
11459 # Prevent multiple expansion
11460
11461
11462
11463
11464
11465
11466
11467
11468
11469
11470 ol_link_perl=no
11471 if test $ol_enable_perl != no ; then
11472         # Extract the first word of "perl", so it can be a program name with args.
11473 set dummy perl; ac_word=$2
11474 echo "$as_me:$LINENO: checking for $ac_word" >&5
11475 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11476 if test "${ac_cv_path_PERLBIN+set}" = set; then
11477   echo $ECHO_N "(cached) $ECHO_C" >&6
11478 else
11479   case $PERLBIN in
11480   [\\/]* | ?:[\\/]*)
11481   ac_cv_path_PERLBIN="$PERLBIN" # Let the user override the test with a path.
11482   ;;
11483   *)
11484   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11485 for as_dir in $PATH
11486 do
11487   IFS=$as_save_IFS
11488   test -z "$as_dir" && as_dir=.
11489   for ac_exec_ext in '' $ac_executable_extensions; do
11490   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11491     ac_cv_path_PERLBIN="$as_dir/$ac_word$ac_exec_ext"
11492     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11493     break 2
11494   fi
11495 done
11496 done
11497
11498   test -z "$ac_cv_path_PERLBIN" && ac_cv_path_PERLBIN="/usr/bin/perl"
11499   ;;
11500 esac
11501 fi
11502 PERLBIN=$ac_cv_path_PERLBIN
11503
11504 if test -n "$PERLBIN"; then
11505   echo "$as_me:$LINENO: result: $PERLBIN" >&5
11506 echo "${ECHO_T}$PERLBIN" >&6
11507 else
11508   echo "$as_me:$LINENO: result: no" >&5
11509 echo "${ECHO_T}no" >&6
11510 fi
11511
11512
11513         if test "no$PERLBIN" = "no" ; then
11514                 if test $ol_enable_perl = yes ; then
11515                         { { echo "$as_me:$LINENO: error: could not locate perl" >&5
11516 echo "$as_me: error: could not locate perl" >&2;}
11517    { (exit 1); exit 1; }; }
11518                 fi
11519
11520         else
11521                 PERL_CPPFLAGS="`$PERLBIN -MExtUtils::Embed -e ccopts`"
11522                 PERL_LDFLAGS="`$PERLBIN -MExtUtils::Embed -e ldopts|sed -e 's/ -lc / /' -e 's/ -lc$//'`"
11523
11524                 if test x"$ol_enable_perl" = "xyes" ; then
11525                         SLAPD_PERL_LDFLAGS="$PERL_LDFLAGS"
11526                 else
11527                         MOD_PERL_LDFLAGS="$PERL_LDFLAGS"
11528                 fi
11529                                 ol_link_perl=yes
11530         fi
11531 fi
11532
11533 ac_ext=c
11534 ac_cpp='$CPP $CPPFLAGS'
11535 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11536 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11537 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11538 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
11539 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
11540 # On Suns, sometimes $CPP names a directory.
11541 if test -n "$CPP" && test -d "$CPP"; then
11542   CPP=
11543 fi
11544 if test -z "$CPP"; then
11545   if test "${ac_cv_prog_CPP+set}" = set; then
11546   echo $ECHO_N "(cached) $ECHO_C" >&6
11547 else
11548       # Double quotes because CPP needs to be expanded
11549     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
11550     do
11551       ac_preproc_ok=false
11552 for ac_c_preproc_warn_flag in '' yes
11553 do
11554   # Use a header file that comes with gcc, so configuring glibc
11555   # with a fresh cross-compiler works.
11556   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11557   # <limits.h> exists even on freestanding compilers.
11558   # On the NeXT, cc -E runs the code through the compiler's parser,
11559   # not just through cpp. "Syntax error" is here to catch this case.
11560   cat >conftest.$ac_ext <<_ACEOF
11561 /* confdefs.h.  */
11562 _ACEOF
11563 cat confdefs.h >>conftest.$ac_ext
11564 cat >>conftest.$ac_ext <<_ACEOF
11565 /* end confdefs.h.  */
11566 #ifdef __STDC__
11567 # include <limits.h>
11568 #else
11569 # include <assert.h>
11570 #endif
11571                      Syntax error
11572 _ACEOF
11573 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11574   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11575   ac_status=$?
11576   grep -v '^ *+' conftest.er1 >conftest.err
11577   rm -f conftest.er1
11578   cat conftest.err >&5
11579   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11580   (exit $ac_status); } >/dev/null; then
11581   if test -s conftest.err; then
11582     ac_cpp_err=$ac_c_preproc_warn_flag
11583     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11584   else
11585     ac_cpp_err=
11586   fi
11587 else
11588   ac_cpp_err=yes
11589 fi
11590 if test -z "$ac_cpp_err"; then
11591   :
11592 else
11593   echo "$as_me: failed program was:" >&5
11594 sed 's/^/| /' conftest.$ac_ext >&5
11595
11596   # Broken: fails on valid input.
11597 continue
11598 fi
11599 rm -f conftest.err conftest.$ac_ext
11600
11601   # OK, works on sane cases.  Now check whether non-existent headers
11602   # can be detected and how.
11603   cat >conftest.$ac_ext <<_ACEOF
11604 /* confdefs.h.  */
11605 _ACEOF
11606 cat confdefs.h >>conftest.$ac_ext
11607 cat >>conftest.$ac_ext <<_ACEOF
11608 /* end confdefs.h.  */
11609 #include <ac_nonexistent.h>
11610 _ACEOF
11611 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11612   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11613   ac_status=$?
11614   grep -v '^ *+' conftest.er1 >conftest.err
11615   rm -f conftest.er1
11616   cat conftest.err >&5
11617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11618   (exit $ac_status); } >/dev/null; then
11619   if test -s conftest.err; then
11620     ac_cpp_err=$ac_c_preproc_warn_flag
11621     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11622   else
11623     ac_cpp_err=
11624   fi
11625 else
11626   ac_cpp_err=yes
11627 fi
11628 if test -z "$ac_cpp_err"; then
11629   # Broken: success on invalid input.
11630 continue
11631 else
11632   echo "$as_me: failed program was:" >&5
11633 sed 's/^/| /' conftest.$ac_ext >&5
11634
11635   # Passes both tests.
11636 ac_preproc_ok=:
11637 break
11638 fi
11639 rm -f conftest.err conftest.$ac_ext
11640
11641 done
11642 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
11643 rm -f conftest.err conftest.$ac_ext
11644 if $ac_preproc_ok; then
11645   break
11646 fi
11647
11648     done
11649     ac_cv_prog_CPP=$CPP
11650
11651 fi
11652   CPP=$ac_cv_prog_CPP
11653 else
11654   ac_cv_prog_CPP=$CPP
11655 fi
11656 echo "$as_me:$LINENO: result: $CPP" >&5
11657 echo "${ECHO_T}$CPP" >&6
11658 ac_preproc_ok=false
11659 for ac_c_preproc_warn_flag in '' yes
11660 do
11661   # Use a header file that comes with gcc, so configuring glibc
11662   # with a fresh cross-compiler works.
11663   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11664   # <limits.h> exists even on freestanding compilers.
11665   # On the NeXT, cc -E runs the code through the compiler's parser,
11666   # not just through cpp. "Syntax error" is here to catch this case.
11667   cat >conftest.$ac_ext <<_ACEOF
11668 /* confdefs.h.  */
11669 _ACEOF
11670 cat confdefs.h >>conftest.$ac_ext
11671 cat >>conftest.$ac_ext <<_ACEOF
11672 /* end confdefs.h.  */
11673 #ifdef __STDC__
11674 # include <limits.h>
11675 #else
11676 # include <assert.h>
11677 #endif
11678                      Syntax error
11679 _ACEOF
11680 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11681   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11682   ac_status=$?
11683   grep -v '^ *+' conftest.er1 >conftest.err
11684   rm -f conftest.er1
11685   cat conftest.err >&5
11686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11687   (exit $ac_status); } >/dev/null; then
11688   if test -s conftest.err; then
11689     ac_cpp_err=$ac_c_preproc_warn_flag
11690     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11691   else
11692     ac_cpp_err=
11693   fi
11694 else
11695   ac_cpp_err=yes
11696 fi
11697 if test -z "$ac_cpp_err"; then
11698   :
11699 else
11700   echo "$as_me: failed program was:" >&5
11701 sed 's/^/| /' conftest.$ac_ext >&5
11702
11703   # Broken: fails on valid input.
11704 continue
11705 fi
11706 rm -f conftest.err conftest.$ac_ext
11707
11708   # OK, works on sane cases.  Now check whether non-existent headers
11709   # can be detected and how.
11710   cat >conftest.$ac_ext <<_ACEOF
11711 /* confdefs.h.  */
11712 _ACEOF
11713 cat confdefs.h >>conftest.$ac_ext
11714 cat >>conftest.$ac_ext <<_ACEOF
11715 /* end confdefs.h.  */
11716 #include <ac_nonexistent.h>
11717 _ACEOF
11718 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11719   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11720   ac_status=$?
11721   grep -v '^ *+' conftest.er1 >conftest.err
11722   rm -f conftest.er1
11723   cat conftest.err >&5
11724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11725   (exit $ac_status); } >/dev/null; then
11726   if test -s conftest.err; then
11727     ac_cpp_err=$ac_c_preproc_warn_flag
11728     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11729   else
11730     ac_cpp_err=
11731   fi
11732 else
11733   ac_cpp_err=yes
11734 fi
11735 if test -z "$ac_cpp_err"; then
11736   # Broken: success on invalid input.
11737 continue
11738 else
11739   echo "$as_me: failed program was:" >&5
11740 sed 's/^/| /' conftest.$ac_ext >&5
11741
11742   # Passes both tests.
11743 ac_preproc_ok=:
11744 break
11745 fi
11746 rm -f conftest.err conftest.$ac_ext
11747
11748 done
11749 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
11750 rm -f conftest.err conftest.$ac_ext
11751 if $ac_preproc_ok; then
11752   :
11753 else
11754   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
11755 See \`config.log' for more details." >&5
11756 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
11757 See \`config.log' for more details." >&2;}
11758    { (exit 1); exit 1; }; }
11759 fi
11760
11761 ac_ext=c
11762 ac_cpp='$CPP $CPPFLAGS'
11763 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11764 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11765 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11766
11767
11768 case $host_os in
11769   *mingw32* ) ac_cv_mingw32=yes ;;
11770   *cygwin* ) ac_cv_cygwin=yes ;;
11771 esac
11772
11773
11774
11775
11776 cat >>confdefs.h <<_ACEOF
11777 #define EXEEXT "${EXEEXT}"
11778 _ACEOF
11779
11780
11781 echo "$as_me:$LINENO: checking for be_app in -lbe" >&5
11782 echo $ECHO_N "checking for be_app in -lbe... $ECHO_C" >&6
11783 if test "${ac_cv_lib_be_be_app+set}" = set; then
11784   echo $ECHO_N "(cached) $ECHO_C" >&6
11785 else
11786   ac_check_lib_save_LIBS=$LIBS
11787 LIBS="-lbe -lroot -lnet $LIBS"
11788 cat >conftest.$ac_ext <<_ACEOF
11789 /* confdefs.h.  */
11790 _ACEOF
11791 cat confdefs.h >>conftest.$ac_ext
11792 cat >>conftest.$ac_ext <<_ACEOF
11793 /* end confdefs.h.  */
11794
11795 /* Override any gcc2 internal prototype to avoid an error.  */
11796 #ifdef __cplusplus
11797 extern "C"
11798 #endif
11799 /* We use char because int might match the return type of a gcc2
11800    builtin and then its argument prototype would still apply.  */
11801 char be_app ();
11802 int
11803 main ()
11804 {
11805 be_app ();
11806   ;
11807   return 0;
11808 }
11809 _ACEOF
11810 rm -f conftest.$ac_objext conftest$ac_exeext
11811 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11812   (eval $ac_link) 2>conftest.er1
11813   ac_status=$?
11814   grep -v '^ *+' conftest.er1 >conftest.err
11815   rm -f conftest.er1
11816   cat conftest.err >&5
11817   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11818   (exit $ac_status); } &&
11819          { ac_try='test -z "$ac_c_werror_flag"
11820                          || test ! -s conftest.err'
11821   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11822   (eval $ac_try) 2>&5
11823   ac_status=$?
11824   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11825   (exit $ac_status); }; } &&
11826          { ac_try='test -s conftest$ac_exeext'
11827   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11828   (eval $ac_try) 2>&5
11829   ac_status=$?
11830   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11831   (exit $ac_status); }; }; then
11832   ac_cv_lib_be_be_app=yes
11833 else
11834   echo "$as_me: failed program was:" >&5
11835 sed 's/^/| /' conftest.$ac_ext >&5
11836
11837 ac_cv_lib_be_be_app=no
11838 fi
11839 rm -f conftest.err conftest.$ac_objext \
11840       conftest$ac_exeext conftest.$ac_ext
11841 LIBS=$ac_check_lib_save_LIBS
11842 fi
11843 echo "$as_me:$LINENO: result: $ac_cv_lib_be_be_app" >&5
11844 echo "${ECHO_T}$ac_cv_lib_be_be_app" >&6
11845 if test $ac_cv_lib_be_be_app = yes; then
11846   LIBS="$LIBS -lbe -lroot -lnet"
11847 else
11848   :
11849 fi
11850
11851
11852 ac_ext=c
11853 ac_cpp='$CPP $CPPFLAGS'
11854 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11855 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11856 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11857 if test -n "$ac_tool_prefix"; then
11858   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
11859 set dummy ${ac_tool_prefix}gcc; ac_word=$2
11860 echo "$as_me:$LINENO: checking for $ac_word" >&5
11861 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11862 if test "${ac_cv_prog_CC+set}" = set; then
11863   echo $ECHO_N "(cached) $ECHO_C" >&6
11864 else
11865   if test -n "$CC"; then
11866   ac_cv_prog_CC="$CC" # Let the user override the test.
11867 else
11868 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11869 for as_dir in $PATH
11870 do
11871   IFS=$as_save_IFS
11872   test -z "$as_dir" && as_dir=.
11873   for ac_exec_ext in '' $ac_executable_extensions; do
11874   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11875     ac_cv_prog_CC="${ac_tool_prefix}gcc"
11876     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11877     break 2
11878   fi
11879 done
11880 done
11881
11882 fi
11883 fi
11884 CC=$ac_cv_prog_CC
11885 if test -n "$CC"; then
11886   echo "$as_me:$LINENO: result: $CC" >&5
11887 echo "${ECHO_T}$CC" >&6
11888 else
11889   echo "$as_me:$LINENO: result: no" >&5
11890 echo "${ECHO_T}no" >&6
11891 fi
11892
11893 fi
11894 if test -z "$ac_cv_prog_CC"; then
11895   ac_ct_CC=$CC
11896   # Extract the first word of "gcc", so it can be a program name with args.
11897 set dummy gcc; ac_word=$2
11898 echo "$as_me:$LINENO: checking for $ac_word" >&5
11899 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11900 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
11901   echo $ECHO_N "(cached) $ECHO_C" >&6
11902 else
11903   if test -n "$ac_ct_CC"; then
11904   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
11905 else
11906 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11907 for as_dir in $PATH
11908 do
11909   IFS=$as_save_IFS
11910   test -z "$as_dir" && as_dir=.
11911   for ac_exec_ext in '' $ac_executable_extensions; do
11912   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11913     ac_cv_prog_ac_ct_CC="gcc"
11914     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11915     break 2
11916   fi
11917 done
11918 done
11919
11920 fi
11921 fi
11922 ac_ct_CC=$ac_cv_prog_ac_ct_CC
11923 if test -n "$ac_ct_CC"; then
11924   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
11925 echo "${ECHO_T}$ac_ct_CC" >&6
11926 else
11927   echo "$as_me:$LINENO: result: no" >&5
11928 echo "${ECHO_T}no" >&6
11929 fi
11930
11931   CC=$ac_ct_CC
11932 else
11933   CC="$ac_cv_prog_CC"
11934 fi
11935
11936 if test -z "$CC"; then
11937   if test -n "$ac_tool_prefix"; then
11938   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
11939 set dummy ${ac_tool_prefix}cc; ac_word=$2
11940 echo "$as_me:$LINENO: checking for $ac_word" >&5
11941 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11942 if test "${ac_cv_prog_CC+set}" = set; then
11943   echo $ECHO_N "(cached) $ECHO_C" >&6
11944 else
11945   if test -n "$CC"; then
11946   ac_cv_prog_CC="$CC" # Let the user override the test.
11947 else
11948 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11949 for as_dir in $PATH
11950 do
11951   IFS=$as_save_IFS
11952   test -z "$as_dir" && as_dir=.
11953   for ac_exec_ext in '' $ac_executable_extensions; do
11954   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11955     ac_cv_prog_CC="${ac_tool_prefix}cc"
11956     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11957     break 2
11958   fi
11959 done
11960 done
11961
11962 fi
11963 fi
11964 CC=$ac_cv_prog_CC
11965 if test -n "$CC"; then
11966   echo "$as_me:$LINENO: result: $CC" >&5
11967 echo "${ECHO_T}$CC" >&6
11968 else
11969   echo "$as_me:$LINENO: result: no" >&5
11970 echo "${ECHO_T}no" >&6
11971 fi
11972
11973 fi
11974 if test -z "$ac_cv_prog_CC"; then
11975   ac_ct_CC=$CC
11976   # Extract the first word of "cc", so it can be a program name with args.
11977 set dummy cc; ac_word=$2
11978 echo "$as_me:$LINENO: checking for $ac_word" >&5
11979 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11980 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
11981   echo $ECHO_N "(cached) $ECHO_C" >&6
11982 else
11983   if test -n "$ac_ct_CC"; then
11984   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
11985 else
11986 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11987 for as_dir in $PATH
11988 do
11989   IFS=$as_save_IFS
11990   test -z "$as_dir" && as_dir=.
11991   for ac_exec_ext in '' $ac_executable_extensions; do
11992   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11993     ac_cv_prog_ac_ct_CC="cc"
11994     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11995     break 2
11996   fi
11997 done
11998 done
11999
12000 fi
12001 fi
12002 ac_ct_CC=$ac_cv_prog_ac_ct_CC
12003 if test -n "$ac_ct_CC"; then
12004   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
12005 echo "${ECHO_T}$ac_ct_CC" >&6
12006 else
12007   echo "$as_me:$LINENO: result: no" >&5
12008 echo "${ECHO_T}no" >&6
12009 fi
12010
12011   CC=$ac_ct_CC
12012 else
12013   CC="$ac_cv_prog_CC"
12014 fi
12015
12016 fi
12017 if test -z "$CC"; then
12018   # Extract the first word of "cc", so it can be a program name with args.
12019 set dummy cc; ac_word=$2
12020 echo "$as_me:$LINENO: checking for $ac_word" >&5
12021 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12022 if test "${ac_cv_prog_CC+set}" = set; then
12023   echo $ECHO_N "(cached) $ECHO_C" >&6
12024 else
12025   if test -n "$CC"; then
12026   ac_cv_prog_CC="$CC" # Let the user override the test.
12027 else
12028   ac_prog_rejected=no
12029 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12030 for as_dir in $PATH
12031 do
12032   IFS=$as_save_IFS
12033   test -z "$as_dir" && as_dir=.
12034   for ac_exec_ext in '' $ac_executable_extensions; do
12035   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12036     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
12037        ac_prog_rejected=yes
12038        continue
12039      fi
12040     ac_cv_prog_CC="cc"
12041     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12042     break 2
12043   fi
12044 done
12045 done
12046
12047 if test $ac_prog_rejected = yes; then
12048   # We found a bogon in the path, so make sure we never use it.
12049   set dummy $ac_cv_prog_CC
12050   shift
12051   if test $# != 0; then
12052     # We chose a different compiler from the bogus one.
12053     # However, it has the same basename, so the bogon will be chosen
12054     # first if we set CC to just the basename; use the full file name.
12055     shift
12056     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
12057   fi
12058 fi
12059 fi
12060 fi
12061 CC=$ac_cv_prog_CC
12062 if test -n "$CC"; then
12063   echo "$as_me:$LINENO: result: $CC" >&5
12064 echo "${ECHO_T}$CC" >&6
12065 else
12066   echo "$as_me:$LINENO: result: no" >&5
12067 echo "${ECHO_T}no" >&6
12068 fi
12069
12070 fi
12071 if test -z "$CC"; then
12072   if test -n "$ac_tool_prefix"; then
12073   for ac_prog in cl
12074   do
12075     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
12076 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
12077 echo "$as_me:$LINENO: checking for $ac_word" >&5
12078 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12079 if test "${ac_cv_prog_CC+set}" = set; then
12080   echo $ECHO_N "(cached) $ECHO_C" >&6
12081 else
12082   if test -n "$CC"; then
12083   ac_cv_prog_CC="$CC" # Let the user override the test.
12084 else
12085 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12086 for as_dir in $PATH
12087 do
12088   IFS=$as_save_IFS
12089   test -z "$as_dir" && as_dir=.
12090   for ac_exec_ext in '' $ac_executable_extensions; do
12091   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12092     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
12093     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12094     break 2
12095   fi
12096 done
12097 done
12098
12099 fi
12100 fi
12101 CC=$ac_cv_prog_CC
12102 if test -n "$CC"; then
12103   echo "$as_me:$LINENO: result: $CC" >&5
12104 echo "${ECHO_T}$CC" >&6
12105 else
12106   echo "$as_me:$LINENO: result: no" >&5
12107 echo "${ECHO_T}no" >&6
12108 fi
12109
12110     test -n "$CC" && break
12111   done
12112 fi
12113 if test -z "$CC"; then
12114   ac_ct_CC=$CC
12115   for ac_prog in cl
12116 do
12117   # Extract the first word of "$ac_prog", so it can be a program name with args.
12118 set dummy $ac_prog; ac_word=$2
12119 echo "$as_me:$LINENO: checking for $ac_word" >&5
12120 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12121 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
12122   echo $ECHO_N "(cached) $ECHO_C" >&6
12123 else
12124   if test -n "$ac_ct_CC"; then
12125   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
12126 else
12127 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12128 for as_dir in $PATH
12129 do
12130   IFS=$as_save_IFS
12131   test -z "$as_dir" && as_dir=.
12132   for ac_exec_ext in '' $ac_executable_extensions; do
12133   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12134     ac_cv_prog_ac_ct_CC="$ac_prog"
12135     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12136     break 2
12137   fi
12138 done
12139 done
12140
12141 fi
12142 fi
12143 ac_ct_CC=$ac_cv_prog_ac_ct_CC
12144 if test -n "$ac_ct_CC"; then
12145   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
12146 echo "${ECHO_T}$ac_ct_CC" >&6
12147 else
12148   echo "$as_me:$LINENO: result: no" >&5
12149 echo "${ECHO_T}no" >&6
12150 fi
12151
12152   test -n "$ac_ct_CC" && break
12153 done
12154
12155   CC=$ac_ct_CC
12156 fi
12157
12158 fi
12159
12160
12161 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
12162 See \`config.log' for more details." >&5
12163 echo "$as_me: error: no acceptable C compiler found in \$PATH
12164 See \`config.log' for more details." >&2;}
12165    { (exit 1); exit 1; }; }
12166
12167 # Provide some information about the compiler.
12168 echo "$as_me:$LINENO:" \
12169      "checking for C compiler version" >&5
12170 ac_compiler=`set X $ac_compile; echo $2`
12171 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
12172   (eval $ac_compiler --version </dev/null >&5) 2>&5
12173   ac_status=$?
12174   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12175   (exit $ac_status); }
12176 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
12177   (eval $ac_compiler -v </dev/null >&5) 2>&5
12178   ac_status=$?
12179   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12180   (exit $ac_status); }
12181 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
12182   (eval $ac_compiler -V </dev/null >&5) 2>&5
12183   ac_status=$?
12184   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12185   (exit $ac_status); }
12186
12187 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
12188 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
12189 if test "${ac_cv_c_compiler_gnu+set}" = set; then
12190   echo $ECHO_N "(cached) $ECHO_C" >&6
12191 else
12192   cat >conftest.$ac_ext <<_ACEOF
12193 /* confdefs.h.  */
12194 _ACEOF
12195 cat confdefs.h >>conftest.$ac_ext
12196 cat >>conftest.$ac_ext <<_ACEOF
12197 /* end confdefs.h.  */
12198
12199 int
12200 main ()
12201 {
12202 #ifndef __GNUC__
12203        choke me
12204 #endif
12205
12206   ;
12207   return 0;
12208 }
12209 _ACEOF
12210 rm -f conftest.$ac_objext
12211 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12212   (eval $ac_compile) 2>conftest.er1
12213   ac_status=$?
12214   grep -v '^ *+' conftest.er1 >conftest.err
12215   rm -f conftest.er1
12216   cat conftest.err >&5
12217   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12218   (exit $ac_status); } &&
12219          { ac_try='test -z "$ac_c_werror_flag"
12220                          || test ! -s conftest.err'
12221   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12222   (eval $ac_try) 2>&5
12223   ac_status=$?
12224   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12225   (exit $ac_status); }; } &&
12226          { ac_try='test -s conftest.$ac_objext'
12227   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12228   (eval $ac_try) 2>&5
12229   ac_status=$?
12230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12231   (exit $ac_status); }; }; then
12232   ac_compiler_gnu=yes
12233 else
12234   echo "$as_me: failed program was:" >&5
12235 sed 's/^/| /' conftest.$ac_ext >&5
12236
12237 ac_compiler_gnu=no
12238 fi
12239 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12240 ac_cv_c_compiler_gnu=$ac_compiler_gnu
12241
12242 fi
12243 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
12244 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
12245 GCC=`test $ac_compiler_gnu = yes && echo yes`
12246 ac_test_CFLAGS=${CFLAGS+set}
12247 ac_save_CFLAGS=$CFLAGS
12248 CFLAGS="-g"
12249 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
12250 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
12251 if test "${ac_cv_prog_cc_g+set}" = set; then
12252   echo $ECHO_N "(cached) $ECHO_C" >&6
12253 else
12254   cat >conftest.$ac_ext <<_ACEOF
12255 /* confdefs.h.  */
12256 _ACEOF
12257 cat confdefs.h >>conftest.$ac_ext
12258 cat >>conftest.$ac_ext <<_ACEOF
12259 /* end confdefs.h.  */
12260
12261 int
12262 main ()
12263 {
12264
12265   ;
12266   return 0;
12267 }
12268 _ACEOF
12269 rm -f conftest.$ac_objext
12270 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12271   (eval $ac_compile) 2>conftest.er1
12272   ac_status=$?
12273   grep -v '^ *+' conftest.er1 >conftest.err
12274   rm -f conftest.er1
12275   cat conftest.err >&5
12276   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12277   (exit $ac_status); } &&
12278          { ac_try='test -z "$ac_c_werror_flag"
12279                          || test ! -s conftest.err'
12280   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12281   (eval $ac_try) 2>&5
12282   ac_status=$?
12283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12284   (exit $ac_status); }; } &&
12285          { ac_try='test -s conftest.$ac_objext'
12286   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12287   (eval $ac_try) 2>&5
12288   ac_status=$?
12289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12290   (exit $ac_status); }; }; then
12291   ac_cv_prog_cc_g=yes
12292 else
12293   echo "$as_me: failed program was:" >&5
12294 sed 's/^/| /' conftest.$ac_ext >&5
12295
12296 ac_cv_prog_cc_g=no
12297 fi
12298 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12299 fi
12300 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
12301 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
12302 if test "$ac_test_CFLAGS" = set; then
12303   CFLAGS=$ac_save_CFLAGS
12304 elif test $ac_cv_prog_cc_g = yes; then
12305   if test "$GCC" = yes; then
12306     CFLAGS="-g -O2"
12307   else
12308     CFLAGS="-g"
12309   fi
12310 else
12311   if test "$GCC" = yes; then
12312     CFLAGS="-O2"
12313   else
12314     CFLAGS=
12315   fi
12316 fi
12317 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
12318 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
12319 if test "${ac_cv_prog_cc_stdc+set}" = set; then
12320   echo $ECHO_N "(cached) $ECHO_C" >&6
12321 else
12322   ac_cv_prog_cc_stdc=no
12323 ac_save_CC=$CC
12324 cat >conftest.$ac_ext <<_ACEOF
12325 /* confdefs.h.  */
12326 _ACEOF
12327 cat confdefs.h >>conftest.$ac_ext
12328 cat >>conftest.$ac_ext <<_ACEOF
12329 /* end confdefs.h.  */
12330 #include <stdarg.h>
12331 #include <stdio.h>
12332 #include <sys/types.h>
12333 #include <sys/stat.h>
12334 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
12335 struct buf { int x; };
12336 FILE * (*rcsopen) (struct buf *, struct stat *, int);
12337 static char *e (p, i)
12338      char **p;
12339      int i;
12340 {
12341   return p[i];
12342 }
12343 static char *f (char * (*g) (char **, int), char **p, ...)
12344 {
12345   char *s;
12346   va_list v;
12347   va_start (v,p);
12348   s = g (p, va_arg (v,int));
12349   va_end (v);
12350   return s;
12351 }
12352
12353 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
12354    function prototypes and stuff, but not '\xHH' hex character constants.
12355    These don't provoke an error unfortunately, instead are silently treated
12356    as 'x'.  The following induces an error, until -std1 is added to get
12357    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
12358    array size at least.  It's necessary to write '\x00'==0 to get something
12359    that's true only with -std1.  */
12360 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
12361
12362 int test (int i, double x);
12363 struct s1 {int (*f) (int a);};
12364 struct s2 {int (*f) (double a);};
12365 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
12366 int argc;
12367 char **argv;
12368 int
12369 main ()
12370 {
12371 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
12372   ;
12373   return 0;
12374 }
12375 _ACEOF
12376 # Don't try gcc -ansi; that turns off useful extensions and
12377 # breaks some systems' header files.
12378 # AIX                   -qlanglvl=ansi
12379 # Ultrix and OSF/1      -std1
12380 # HP-UX 10.20 and later -Ae
12381 # HP-UX older versions  -Aa -D_HPUX_SOURCE
12382 # SVR4                  -Xc -D__EXTENSIONS__
12383 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
12384 do
12385   CC="$ac_save_CC $ac_arg"
12386   rm -f conftest.$ac_objext
12387 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12388   (eval $ac_compile) 2>conftest.er1
12389   ac_status=$?
12390   grep -v '^ *+' conftest.er1 >conftest.err
12391   rm -f conftest.er1
12392   cat conftest.err >&5
12393   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12394   (exit $ac_status); } &&
12395          { ac_try='test -z "$ac_c_werror_flag"
12396                          || test ! -s conftest.err'
12397   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12398   (eval $ac_try) 2>&5
12399   ac_status=$?
12400   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12401   (exit $ac_status); }; } &&
12402          { ac_try='test -s conftest.$ac_objext'
12403   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12404   (eval $ac_try) 2>&5
12405   ac_status=$?
12406   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12407   (exit $ac_status); }; }; then
12408   ac_cv_prog_cc_stdc=$ac_arg
12409 break
12410 else
12411   echo "$as_me: failed program was:" >&5
12412 sed 's/^/| /' conftest.$ac_ext >&5
12413
12414 fi
12415 rm -f conftest.err conftest.$ac_objext
12416 done
12417 rm -f conftest.$ac_ext conftest.$ac_objext
12418 CC=$ac_save_CC
12419
12420 fi
12421
12422 case "x$ac_cv_prog_cc_stdc" in
12423   x|xno)
12424     echo "$as_me:$LINENO: result: none needed" >&5
12425 echo "${ECHO_T}none needed" >&6 ;;
12426   *)
12427     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
12428 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
12429     CC="$CC $ac_cv_prog_cc_stdc" ;;
12430 esac
12431
12432 # Some people use a C++ compiler to compile C.  Since we use `exit',
12433 # in C++ we need to declare it.  In case someone uses the same compiler
12434 # for both compiling C and C++ we need to have the C++ compiler decide
12435 # the declaration of exit, since it's the most demanding environment.
12436 cat >conftest.$ac_ext <<_ACEOF
12437 #ifndef __cplusplus
12438   choke me
12439 #endif
12440 _ACEOF
12441 rm -f conftest.$ac_objext
12442 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12443   (eval $ac_compile) 2>conftest.er1
12444   ac_status=$?
12445   grep -v '^ *+' conftest.er1 >conftest.err
12446   rm -f conftest.er1
12447   cat conftest.err >&5
12448   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12449   (exit $ac_status); } &&
12450          { ac_try='test -z "$ac_c_werror_flag"
12451                          || test ! -s conftest.err'
12452   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12453   (eval $ac_try) 2>&5
12454   ac_status=$?
12455   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12456   (exit $ac_status); }; } &&
12457          { ac_try='test -s conftest.$ac_objext'
12458   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12459   (eval $ac_try) 2>&5
12460   ac_status=$?
12461   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12462   (exit $ac_status); }; }; then
12463   for ac_declaration in \
12464    '' \
12465    'extern "C" void std::exit (int) throw (); using std::exit;' \
12466    'extern "C" void std::exit (int); using std::exit;' \
12467    'extern "C" void exit (int) throw ();' \
12468    'extern "C" void exit (int);' \
12469    'void exit (int);'
12470 do
12471   cat >conftest.$ac_ext <<_ACEOF
12472 /* confdefs.h.  */
12473 _ACEOF
12474 cat confdefs.h >>conftest.$ac_ext
12475 cat >>conftest.$ac_ext <<_ACEOF
12476 /* end confdefs.h.  */
12477 $ac_declaration
12478 #include <stdlib.h>
12479 int
12480 main ()
12481 {
12482 exit (42);
12483   ;
12484   return 0;
12485 }
12486 _ACEOF
12487 rm -f conftest.$ac_objext
12488 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12489   (eval $ac_compile) 2>conftest.er1
12490   ac_status=$?
12491   grep -v '^ *+' conftest.er1 >conftest.err
12492   rm -f conftest.er1
12493   cat conftest.err >&5
12494   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12495   (exit $ac_status); } &&
12496          { ac_try='test -z "$ac_c_werror_flag"
12497                          || test ! -s conftest.err'
12498   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12499   (eval $ac_try) 2>&5
12500   ac_status=$?
12501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12502   (exit $ac_status); }; } &&
12503          { ac_try='test -s conftest.$ac_objext'
12504   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12505   (eval $ac_try) 2>&5
12506   ac_status=$?
12507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12508   (exit $ac_status); }; }; then
12509   :
12510 else
12511   echo "$as_me: failed program was:" >&5
12512 sed 's/^/| /' conftest.$ac_ext >&5
12513
12514 continue
12515 fi
12516 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12517   cat >conftest.$ac_ext <<_ACEOF
12518 /* confdefs.h.  */
12519 _ACEOF
12520 cat confdefs.h >>conftest.$ac_ext
12521 cat >>conftest.$ac_ext <<_ACEOF
12522 /* end confdefs.h.  */
12523 $ac_declaration
12524 int
12525 main ()
12526 {
12527 exit (42);
12528   ;
12529   return 0;
12530 }
12531 _ACEOF
12532 rm -f conftest.$ac_objext
12533 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12534   (eval $ac_compile) 2>conftest.er1
12535   ac_status=$?
12536   grep -v '^ *+' conftest.er1 >conftest.err
12537   rm -f conftest.er1
12538   cat conftest.err >&5
12539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12540   (exit $ac_status); } &&
12541          { ac_try='test -z "$ac_c_werror_flag"
12542                          || test ! -s conftest.err'
12543   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12544   (eval $ac_try) 2>&5
12545   ac_status=$?
12546   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12547   (exit $ac_status); }; } &&
12548          { ac_try='test -s conftest.$ac_objext'
12549   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12550   (eval $ac_try) 2>&5
12551   ac_status=$?
12552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12553   (exit $ac_status); }; }; then
12554   break
12555 else
12556   echo "$as_me: failed program was:" >&5
12557 sed 's/^/| /' conftest.$ac_ext >&5
12558
12559 fi
12560 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12561 done
12562 rm -f conftest*
12563 if test -n "$ac_declaration"; then
12564   echo '#ifdef __cplusplus' >>confdefs.h
12565   echo $ac_declaration      >>confdefs.h
12566   echo '#endif'             >>confdefs.h
12567 fi
12568
12569 else
12570   echo "$as_me: failed program was:" >&5
12571 sed 's/^/| /' conftest.$ac_ext >&5
12572
12573 fi
12574 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12575 ac_ext=c
12576 ac_cpp='$CPP $CPPFLAGS'
12577 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
12578 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
12579 ac_compiler_gnu=$ac_cv_c_compiler_gnu
12580
12581 depcc="$CC"   am_compiler_list=
12582
12583 echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
12584 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6
12585 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
12586   echo $ECHO_N "(cached) $ECHO_C" >&6
12587 else
12588   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
12589   # We make a subdir and do the tests there.  Otherwise we can end up
12590   # making bogus files that we don't know about and never remove.  For
12591   # instance it was reported that on HP-UX the gcc test will end up
12592   # making a dummy file named `D' -- because `-MD' means `put the output
12593   # in D'.
12594   mkdir conftest.dir
12595   # Copy depcomp to subdir because otherwise we won't find it if we're
12596   # using a relative directory.
12597   cp "$am_depcomp" conftest.dir
12598   cd conftest.dir
12599   # We will build objects and dependencies in a subdirectory because
12600   # it helps to detect inapplicable dependency modes.  For instance
12601   # both Tru64's cc and ICC support -MD to output dependencies as a
12602   # side effect of compilation, but ICC will put the dependencies in
12603   # the current directory while Tru64 will put them in the object
12604   # directory.
12605   mkdir sub
12606
12607   am_cv_CC_dependencies_compiler_type=none
12608   if test "$am_compiler_list" = ""; then
12609      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
12610   fi
12611   for depmode in $am_compiler_list; do
12612     # Setup a source with many dependencies, because some compilers
12613     # like to wrap large dependency lists on column 80 (with \), and
12614     # we should not choose a depcomp mode which is confused by this.
12615     #
12616     # We need to recreate these files for each test, as the compiler may
12617     # overwrite some of them when testing with obscure command lines.
12618     # This happens at least with the AIX C compiler.
12619     : > sub/conftest.c
12620     for i in 1 2 3 4 5 6; do
12621       echo '#include "conftst'$i'.h"' >> sub/conftest.c
12622       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
12623       # Solaris 8's {/usr,}/bin/sh.
12624       touch sub/conftst$i.h
12625     done
12626     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
12627
12628     case $depmode in
12629     nosideeffect)
12630       # after this tag, mechanisms are not by side-effect, so they'll
12631       # only be used when explicitly requested
12632       if test "x$enable_dependency_tracking" = xyes; then
12633         continue
12634       else
12635         break
12636       fi
12637       ;;
12638     none) break ;;
12639     esac
12640     # We check with `-c' and `-o' for the sake of the "dashmstdout"
12641     # mode.  It turns out that the SunPro C++ compiler does not properly
12642     # handle `-M -o', and we need to detect this.
12643     if depmode=$depmode \
12644        source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
12645        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
12646        $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
12647          >/dev/null 2>conftest.err &&
12648        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
12649        grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
12650        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
12651       # icc doesn't choke on unknown options, it will just issue warnings
12652       # or remarks (even with -Werror).  So we grep stderr for any message
12653       # that says an option was ignored or not supported.
12654       # When given -MP, icc 7.0 and 7.1 complain thusly:
12655       #   icc: Command line warning: ignoring option '-M'; no argument required
12656       # The diagnosis changed in icc 8.0:
12657       #   icc: Command line remark: option '-MP' not supported
12658       if (grep 'ignoring option' conftest.err ||
12659           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
12660         am_cv_CC_dependencies_compiler_type=$depmode
12661         break
12662       fi
12663     fi
12664   done
12665
12666   cd ..
12667   rm -rf conftest.dir
12668 else
12669   am_cv_CC_dependencies_compiler_type=none
12670 fi
12671
12672 fi
12673 echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
12674 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6
12675 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
12676
12677
12678
12679 if
12680   test "x$enable_dependency_tracking" != xno \
12681   && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
12682   am__fastdepCC_TRUE=
12683   am__fastdepCC_FALSE='#'
12684 else
12685   am__fastdepCC_TRUE='#'
12686   am__fastdepCC_FALSE=
12687 fi
12688
12689
12690 if test "X${ac_cv_prog_cc_stdc}" = "Xno" ; then
12691         { { echo "$as_me:$LINENO: error: OpenLDAP requires compiler to support STDC constructs." >&5
12692 echo "$as_me: error: OpenLDAP requires compiler to support STDC constructs." >&2;}
12693    { (exit 1); exit 1; }; }
12694 fi
12695
12696 # test for make depend flag
12697 OL_MKDEP=
12698 OL_MKDEP_FLAGS=
12699 if test -z "${MKDEP}"; then
12700         OL_MKDEP="${CC-cc}"
12701         if test -z "${MKDEP_FLAGS}"; then
12702                 echo "$as_me:$LINENO: checking for ${OL_MKDEP} depend flag" >&5
12703 echo $ECHO_N "checking for ${OL_MKDEP} depend flag... $ECHO_C" >&6
12704 if test "${ol_cv_mkdep+set}" = set; then
12705   echo $ECHO_N "(cached) $ECHO_C" >&6
12706 else
12707
12708                         ol_cv_mkdep=no
12709                         for flag in "-M" "-xM"; do
12710                                 cat > conftest.c <<EOF
12711  noCode;
12712 EOF
12713                                 if { ac_try='$OL_MKDEP $flag conftest.c'
12714   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12715   (eval $ac_try) 2>&5
12716   ac_status=$?
12717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12718   (exit $ac_status); }; } \
12719                                         | grep '^conftest\.'"${ac_objext}" >/dev/null 2>&1
12720                                 then
12721                                         if test ! -f conftest."${ac_object}" ; then
12722                                                 ol_cv_mkdep=$flag
12723                                                 OL_MKDEP_FLAGS="$flag"
12724                                                 break
12725                                         fi
12726                                 fi
12727                         done
12728                         rm -f conftest*
12729
12730 fi
12731 echo "$as_me:$LINENO: result: $ol_cv_mkdep" >&5
12732 echo "${ECHO_T}$ol_cv_mkdep" >&6
12733                 test "$ol_cv_mkdep" = no && OL_MKDEP=":"
12734         else
12735                 cc_cv_mkdep=yes
12736                 OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
12737         fi
12738 else
12739         cc_cv_mkdep=yes
12740         OL_MKDEP="${MKDEP}"
12741         OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
12742 fi
12743
12744
12745
12746 if test "${ol_cv_mkdep}" = no ; then
12747         # this will soon become an error
12748         { echo "$as_me:$LINENO: WARNING: do not know how to generate dependencies" >&5
12749 echo "$as_me: WARNING: do not know how to generate dependencies" >&2;}
12750 fi
12751
12752 echo "$as_me:$LINENO: checking for afopen in -ls" >&5
12753 echo $ECHO_N "checking for afopen in -ls... $ECHO_C" >&6
12754 if test "${ac_cv_lib_s_afopen+set}" = set; then
12755   echo $ECHO_N "(cached) $ECHO_C" >&6
12756 else
12757   ac_check_lib_save_LIBS=$LIBS
12758 LIBS="-ls  $LIBS"
12759 cat >conftest.$ac_ext <<_ACEOF
12760 /* confdefs.h.  */
12761 _ACEOF
12762 cat confdefs.h >>conftest.$ac_ext
12763 cat >>conftest.$ac_ext <<_ACEOF
12764 /* end confdefs.h.  */
12765
12766 /* Override any gcc2 internal prototype to avoid an error.  */
12767 #ifdef __cplusplus
12768 extern "C"
12769 #endif
12770 /* We use char because int might match the return type of a gcc2
12771    builtin and then its argument prototype would still apply.  */
12772 char afopen ();
12773 int
12774 main ()
12775 {
12776 afopen ();
12777   ;
12778   return 0;
12779 }
12780 _ACEOF
12781 rm -f conftest.$ac_objext conftest$ac_exeext
12782 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12783   (eval $ac_link) 2>conftest.er1
12784   ac_status=$?
12785   grep -v '^ *+' conftest.er1 >conftest.err
12786   rm -f conftest.er1
12787   cat conftest.err >&5
12788   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12789   (exit $ac_status); } &&
12790          { ac_try='test -z "$ac_c_werror_flag"
12791                          || test ! -s conftest.err'
12792   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12793   (eval $ac_try) 2>&5
12794   ac_status=$?
12795   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12796   (exit $ac_status); }; } &&
12797          { ac_try='test -s conftest$ac_exeext'
12798   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12799   (eval $ac_try) 2>&5
12800   ac_status=$?
12801   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12802   (exit $ac_status); }; }; then
12803   ac_cv_lib_s_afopen=yes
12804 else
12805   echo "$as_me: failed program was:" >&5
12806 sed 's/^/| /' conftest.$ac_ext >&5
12807
12808 ac_cv_lib_s_afopen=no
12809 fi
12810 rm -f conftest.err conftest.$ac_objext \
12811       conftest$ac_exeext conftest.$ac_ext
12812 LIBS=$ac_check_lib_save_LIBS
12813 fi
12814 echo "$as_me:$LINENO: result: $ac_cv_lib_s_afopen" >&5
12815 echo "${ECHO_T}$ac_cv_lib_s_afopen" >&6
12816 if test $ac_cv_lib_s_afopen = yes; then
12817
12818         AUTH_LIBS=-ls
12819
12820 cat >>confdefs.h <<\_ACEOF
12821 #define HAVE_AIX_SECURITY 1
12822 _ACEOF
12823
12824
12825 fi
12826
12827
12828 case "$target" in
12829 *-ibm-openedition)
12830         ac_cv_func_getopt=no
12831
12832 cat >>confdefs.h <<\_ACEOF
12833 #define BOTH_STRINGS_H 1
12834 _ACEOF
12835
12836         ;;
12837 esac
12838
12839 ol_link_modules=no
12840 WITH_MODULES_ENABLED=no
12841 if test $ol_enable_modules != no ; then
12842
12843 for ac_header in ltdl.h
12844 do
12845 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12846 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12847   echo "$as_me:$LINENO: checking for $ac_header" >&5
12848 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12849 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12850   echo $ECHO_N "(cached) $ECHO_C" >&6
12851 fi
12852 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12853 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12854 else
12855   # Is the header compilable?
12856 echo "$as_me:$LINENO: checking $ac_header usability" >&5
12857 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
12858 cat >conftest.$ac_ext <<_ACEOF
12859 /* confdefs.h.  */
12860 _ACEOF
12861 cat confdefs.h >>conftest.$ac_ext
12862 cat >>conftest.$ac_ext <<_ACEOF
12863 /* end confdefs.h.  */
12864 $ac_includes_default
12865 #include <$ac_header>
12866 _ACEOF
12867 rm -f conftest.$ac_objext
12868 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12869   (eval $ac_compile) 2>conftest.er1
12870   ac_status=$?
12871   grep -v '^ *+' conftest.er1 >conftest.err
12872   rm -f conftest.er1
12873   cat conftest.err >&5
12874   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12875   (exit $ac_status); } &&
12876          { ac_try='test -z "$ac_c_werror_flag"
12877                          || test ! -s conftest.err'
12878   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12879   (eval $ac_try) 2>&5
12880   ac_status=$?
12881   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12882   (exit $ac_status); }; } &&
12883          { ac_try='test -s conftest.$ac_objext'
12884   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12885   (eval $ac_try) 2>&5
12886   ac_status=$?
12887   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12888   (exit $ac_status); }; }; then
12889   ac_header_compiler=yes
12890 else
12891   echo "$as_me: failed program was:" >&5
12892 sed 's/^/| /' conftest.$ac_ext >&5
12893
12894 ac_header_compiler=no
12895 fi
12896 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12897 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12898 echo "${ECHO_T}$ac_header_compiler" >&6
12899
12900 # Is the header present?
12901 echo "$as_me:$LINENO: checking $ac_header presence" >&5
12902 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
12903 cat >conftest.$ac_ext <<_ACEOF
12904 /* confdefs.h.  */
12905 _ACEOF
12906 cat confdefs.h >>conftest.$ac_ext
12907 cat >>conftest.$ac_ext <<_ACEOF
12908 /* end confdefs.h.  */
12909 #include <$ac_header>
12910 _ACEOF
12911 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
12912   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12913   ac_status=$?
12914   grep -v '^ *+' conftest.er1 >conftest.err
12915   rm -f conftest.er1
12916   cat conftest.err >&5
12917   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12918   (exit $ac_status); } >/dev/null; then
12919   if test -s conftest.err; then
12920     ac_cpp_err=$ac_c_preproc_warn_flag
12921     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
12922   else
12923     ac_cpp_err=
12924   fi
12925 else
12926   ac_cpp_err=yes
12927 fi
12928 if test -z "$ac_cpp_err"; then
12929   ac_header_preproc=yes
12930 else
12931   echo "$as_me: failed program was:" >&5
12932 sed 's/^/| /' conftest.$ac_ext >&5
12933
12934   ac_header_preproc=no
12935 fi
12936 rm -f conftest.err conftest.$ac_ext
12937 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12938 echo "${ECHO_T}$ac_header_preproc" >&6
12939
12940 # So?  What about this header?
12941 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12942   yes:no: )
12943     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12944 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12945     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12946 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12947     ac_header_preproc=yes
12948     ;;
12949   no:yes:* )
12950     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12951 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12952     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12953 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12954     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12955 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12956     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12957 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12958     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12959 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12960     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12961 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12962     (
12963       cat <<\_ASBOX
12964 ## --------------------------------------------- ##
12965 ## Report this to <http://www.openldap.org/its/> ##
12966 ## --------------------------------------------- ##
12967 _ASBOX
12968     ) |
12969       sed "s/^/$as_me: WARNING:     /" >&2
12970     ;;
12971 esac
12972 echo "$as_me:$LINENO: checking for $ac_header" >&5
12973 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12974 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12975   echo $ECHO_N "(cached) $ECHO_C" >&6
12976 else
12977   eval "$as_ac_Header=\$ac_header_preproc"
12978 fi
12979 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12980 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12981
12982 fi
12983 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12984   cat >>confdefs.h <<_ACEOF
12985 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12986 _ACEOF
12987
12988 fi
12989
12990 done
12991
12992
12993         if test $ac_cv_header_ltdl_h = no ; then
12994                 { { echo "$as_me:$LINENO: error: could not locate libtool ltdl.h" >&5
12995 echo "$as_me: error: could not locate libtool ltdl.h" >&2;}
12996    { (exit 1); exit 1; }; }
12997         fi
12998
12999         echo "$as_me:$LINENO: checking for lt_dlinit in -lltdl" >&5
13000 echo $ECHO_N "checking for lt_dlinit in -lltdl... $ECHO_C" >&6
13001 if test "${ac_cv_lib_ltdl_lt_dlinit+set}" = set; then
13002   echo $ECHO_N "(cached) $ECHO_C" >&6
13003 else
13004   ac_check_lib_save_LIBS=$LIBS
13005 LIBS="-lltdl  $LIBS"
13006 cat >conftest.$ac_ext <<_ACEOF
13007 /* confdefs.h.  */
13008 _ACEOF
13009 cat confdefs.h >>conftest.$ac_ext
13010 cat >>conftest.$ac_ext <<_ACEOF
13011 /* end confdefs.h.  */
13012
13013 /* Override any gcc2 internal prototype to avoid an error.  */
13014 #ifdef __cplusplus
13015 extern "C"
13016 #endif
13017 /* We use char because int might match the return type of a gcc2
13018    builtin and then its argument prototype would still apply.  */
13019 char lt_dlinit ();
13020 int
13021 main ()
13022 {
13023 lt_dlinit ();
13024   ;
13025   return 0;
13026 }
13027 _ACEOF
13028 rm -f conftest.$ac_objext conftest$ac_exeext
13029 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13030   (eval $ac_link) 2>conftest.er1
13031   ac_status=$?
13032   grep -v '^ *+' conftest.er1 >conftest.err
13033   rm -f conftest.er1
13034   cat conftest.err >&5
13035   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13036   (exit $ac_status); } &&
13037          { ac_try='test -z "$ac_c_werror_flag"
13038                          || test ! -s conftest.err'
13039   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13040   (eval $ac_try) 2>&5
13041   ac_status=$?
13042   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13043   (exit $ac_status); }; } &&
13044          { ac_try='test -s conftest$ac_exeext'
13045   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13046   (eval $ac_try) 2>&5
13047   ac_status=$?
13048   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13049   (exit $ac_status); }; }; then
13050   ac_cv_lib_ltdl_lt_dlinit=yes
13051 else
13052   echo "$as_me: failed program was:" >&5
13053 sed 's/^/| /' conftest.$ac_ext >&5
13054
13055 ac_cv_lib_ltdl_lt_dlinit=no
13056 fi
13057 rm -f conftest.err conftest.$ac_objext \
13058       conftest$ac_exeext conftest.$ac_ext
13059 LIBS=$ac_check_lib_save_LIBS
13060 fi
13061 echo "$as_me:$LINENO: result: $ac_cv_lib_ltdl_lt_dlinit" >&5
13062 echo "${ECHO_T}$ac_cv_lib_ltdl_lt_dlinit" >&6
13063 if test $ac_cv_lib_ltdl_lt_dlinit = yes; then
13064
13065                 MODULES_LIBS=-lltdl
13066
13067 cat >>confdefs.h <<\_ACEOF
13068 #define HAVE_LIBLTDL 1
13069 _ACEOF
13070
13071
13072 fi
13073
13074
13075         if test "$ac_cv_lib_ltdl_lt_dlinit" = no ; then
13076                 { { echo "$as_me:$LINENO: error: could not locate libtool -lltdl" >&5
13077 echo "$as_me: error: could not locate libtool -lltdl" >&2;}
13078    { (exit 1); exit 1; }; }
13079         fi
13080         ol_link_modules=yes
13081         WITH_MODULES_ENABLED=yes
13082
13083 else
13084         for i in $Backends; do
13085                 eval "ol_tmp=\$ol_enable_$i"
13086                 if test $ol_tmp = mod ; then
13087                         { echo "$as_me:$LINENO: WARNING: building static $i backend" >&5
13088 echo "$as_me: WARNING: building static $i backend" >&2;}
13089                         eval "ol_enable_$i=yes"
13090                 fi
13091         done
13092         for i in $Overlays; do
13093                 eval "ol_tmp=\$ol_enable_$i"
13094                 if test $ol_tmp = mod ; then
13095                         { echo "$as_me:$LINENO: WARNING: building static $i overlay" >&5
13096 echo "$as_me: WARNING: building static $i overlay" >&2;}
13097                         eval "ol_enable_$i=yes"
13098                 fi
13099         done
13100 fi
13101
13102 # test for EBCDIC
13103 echo "$as_me:$LINENO: checking for EBCDIC" >&5
13104 echo $ECHO_N "checking for EBCDIC... $ECHO_C" >&6
13105 if test "${ol_cv_cpp_ebcdic+set}" = set; then
13106   echo $ECHO_N "(cached) $ECHO_C" >&6
13107 else
13108
13109         cat >conftest.$ac_ext <<_ACEOF
13110 /* confdefs.h.  */
13111 _ACEOF
13112 cat confdefs.h >>conftest.$ac_ext
13113 cat >>conftest.$ac_ext <<_ACEOF
13114 /* end confdefs.h.  */
13115
13116 #if !('M' == 0xd4)
13117 #include <__ASCII__/generate_error.h>
13118 #endif
13119
13120 _ACEOF
13121 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13122   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13123   ac_status=$?
13124   grep -v '^ *+' conftest.er1 >conftest.err
13125   rm -f conftest.er1
13126   cat conftest.err >&5
13127   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13128   (exit $ac_status); } >/dev/null; then
13129   if test -s conftest.err; then
13130     ac_cpp_err=$ac_c_preproc_warn_flag
13131     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
13132   else
13133     ac_cpp_err=
13134   fi
13135 else
13136   ac_cpp_err=yes
13137 fi
13138 if test -z "$ac_cpp_err"; then
13139   ol_cv_cpp_ebcdic=yes
13140 else
13141   echo "$as_me: failed program was:" >&5
13142 sed 's/^/| /' conftest.$ac_ext >&5
13143
13144   ol_cv_cpp_ebcdic=no
13145 fi
13146 rm -f conftest.err conftest.$ac_ext
13147 fi
13148 echo "$as_me:$LINENO: result: $ol_cv_cpp_ebcdic" >&5
13149 echo "${ECHO_T}$ol_cv_cpp_ebcdic" >&6
13150 if test $ol_cv_cpp_ebcdic = yes ; then
13151
13152 cat >>confdefs.h <<\_ACEOF
13153 #define HAVE_EBCDIC 1
13154 _ACEOF
13155
13156 fi
13157
13158 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
13159 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
13160 if test "${ol_cv_header_stdc+set}" = set; then
13161   echo $ECHO_N "(cached) $ECHO_C" >&6
13162 else
13163   cat >conftest.$ac_ext <<_ACEOF
13164 /* confdefs.h.  */
13165 _ACEOF
13166 cat confdefs.h >>conftest.$ac_ext
13167 cat >>conftest.$ac_ext <<_ACEOF
13168 /* end confdefs.h.  */
13169 #include <stdlib.h>
13170 #include <stdarg.h>
13171 #include <string.h>
13172 #include <float.h>
13173 _ACEOF
13174 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13175   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13176   ac_status=$?
13177   grep -v '^ *+' conftest.er1 >conftest.err
13178   rm -f conftest.er1
13179   cat conftest.err >&5
13180   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13181   (exit $ac_status); } >/dev/null; then
13182   if test -s conftest.err; then
13183     ac_cpp_err=$ac_c_preproc_warn_flag
13184     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
13185   else
13186     ac_cpp_err=
13187   fi
13188 else
13189   ac_cpp_err=yes
13190 fi
13191 if test -z "$ac_cpp_err"; then
13192   ol_cv_header_stdc=yes
13193 else
13194   echo "$as_me: failed program was:" >&5
13195 sed 's/^/| /' conftest.$ac_ext >&5
13196
13197   ol_cv_header_stdc=no
13198 fi
13199 rm -f conftest.err conftest.$ac_ext
13200
13201 if test $ol_cv_header_stdc = yes; then
13202   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13203 cat >conftest.$ac_ext <<_ACEOF
13204 /* confdefs.h.  */
13205 _ACEOF
13206 cat confdefs.h >>conftest.$ac_ext
13207 cat >>conftest.$ac_ext <<_ACEOF
13208 /* end confdefs.h.  */
13209 #include <string.h>
13210
13211 _ACEOF
13212 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13213   $EGREP "memchr" >/dev/null 2>&1; then
13214   :
13215 else
13216   ol_cv_header_stdc=no
13217 fi
13218 rm -f conftest*
13219
13220 fi
13221
13222 if test $ol_cv_header_stdc = yes; then
13223   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13224 cat >conftest.$ac_ext <<_ACEOF
13225 /* confdefs.h.  */
13226 _ACEOF
13227 cat confdefs.h >>conftest.$ac_ext
13228 cat >>conftest.$ac_ext <<_ACEOF
13229 /* end confdefs.h.  */
13230 #include <stdlib.h>
13231
13232 _ACEOF
13233 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13234   $EGREP "free" >/dev/null 2>&1; then
13235   :
13236 else
13237   ol_cv_header_stdc=no
13238 fi
13239 rm -f conftest*
13240
13241 fi
13242
13243 if test $ol_cv_header_stdc = yes; then
13244   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13245 if test "$cross_compiling" = yes; then
13246   :
13247 else
13248   cat >conftest.$ac_ext <<_ACEOF
13249 /* confdefs.h.  */
13250 _ACEOF
13251 cat confdefs.h >>conftest.$ac_ext
13252 cat >>conftest.$ac_ext <<_ACEOF
13253 /* end confdefs.h.  */
13254 #include <ctype.h>
13255 #ifndef HAVE_EBCDIC
13256 #       define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13257 #       define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13258 #else
13259 #       define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13260                 || ('j' <= (c) && (c) <= 'r') \
13261                 || ('s' <= (c) && (c) <= 'z'))
13262 #       define TOUPPER(c)       (ISLOWER(c) ? ((c) | 0x40) : (c))
13263 #endif
13264 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13265 int main () { int i; for (i = 0; i < 256; i++)
13266 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
13267 exit (0); }
13268
13269 _ACEOF
13270 rm -f conftest$ac_exeext
13271 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13272   (eval $ac_link) 2>&5
13273   ac_status=$?
13274   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13275   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13276   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13277   (eval $ac_try) 2>&5
13278   ac_status=$?
13279   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13280   (exit $ac_status); }; }; then
13281   :
13282 else
13283   echo "$as_me: program exited with status $ac_status" >&5
13284 echo "$as_me: failed program was:" >&5
13285 sed 's/^/| /' conftest.$ac_ext >&5
13286
13287 ( exit $ac_status )
13288 ol_cv_header_stdc=no
13289 fi
13290 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13291 fi
13292 fi
13293 fi
13294 echo "$as_me:$LINENO: result: $ol_cv_header_stdc" >&5
13295 echo "${ECHO_T}$ol_cv_header_stdc" >&6
13296 if test $ol_cv_header_stdc = yes; then
13297   cat >>confdefs.h <<\_ACEOF
13298 #define STDC_HEADERS 1
13299 _ACEOF
13300
13301 fi
13302 ac_cv_header_stdc=disable
13303
13304
13305 if test $ol_cv_header_stdc != yes; then
13306         { echo "$as_me:$LINENO: WARNING: could not locate Standard C compliant headers" >&5
13307 echo "$as_me: WARNING: could not locate Standard C compliant headers" >&2;}
13308 fi
13309
13310
13311
13312
13313
13314
13315 ac_header_dirent=no
13316 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
13317   as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
13318 echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
13319 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
13320 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13321   echo $ECHO_N "(cached) $ECHO_C" >&6
13322 else
13323   cat >conftest.$ac_ext <<_ACEOF
13324 /* confdefs.h.  */
13325 _ACEOF
13326 cat confdefs.h >>conftest.$ac_ext
13327 cat >>conftest.$ac_ext <<_ACEOF
13328 /* end confdefs.h.  */
13329 #include <sys/types.h>
13330 #include <$ac_hdr>
13331
13332 int
13333 main ()
13334 {
13335 if ((DIR *) 0)
13336 return 0;
13337   ;
13338   return 0;
13339 }
13340 _ACEOF
13341 rm -f conftest.$ac_objext
13342 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13343   (eval $ac_compile) 2>conftest.er1
13344   ac_status=$?
13345   grep -v '^ *+' conftest.er1 >conftest.err
13346   rm -f conftest.er1
13347   cat conftest.err >&5
13348   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13349   (exit $ac_status); } &&
13350          { ac_try='test -z "$ac_c_werror_flag"
13351                          || test ! -s conftest.err'
13352   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13353   (eval $ac_try) 2>&5
13354   ac_status=$?
13355   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13356   (exit $ac_status); }; } &&
13357          { ac_try='test -s conftest.$ac_objext'
13358   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13359   (eval $ac_try) 2>&5
13360   ac_status=$?
13361   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13362   (exit $ac_status); }; }; then
13363   eval "$as_ac_Header=yes"
13364 else
13365   echo "$as_me: failed program was:" >&5
13366 sed 's/^/| /' conftest.$ac_ext >&5
13367
13368 eval "$as_ac_Header=no"
13369 fi
13370 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13371 fi
13372 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13373 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13374 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13375   cat >>confdefs.h <<_ACEOF
13376 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
13377 _ACEOF
13378
13379 ac_header_dirent=$ac_hdr; break
13380 fi
13381
13382 done
13383 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
13384 if test $ac_header_dirent = dirent.h; then
13385   echo "$as_me:$LINENO: checking for library containing opendir" >&5
13386 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
13387 if test "${ac_cv_search_opendir+set}" = set; then
13388   echo $ECHO_N "(cached) $ECHO_C" >&6
13389 else
13390   ac_func_search_save_LIBS=$LIBS
13391 ac_cv_search_opendir=no
13392 cat >conftest.$ac_ext <<_ACEOF
13393 /* confdefs.h.  */
13394 _ACEOF
13395 cat confdefs.h >>conftest.$ac_ext
13396 cat >>conftest.$ac_ext <<_ACEOF
13397 /* end confdefs.h.  */
13398
13399 /* Override any gcc2 internal prototype to avoid an error.  */
13400 #ifdef __cplusplus
13401 extern "C"
13402 #endif
13403 /* We use char because int might match the return type of a gcc2
13404    builtin and then its argument prototype would still apply.  */
13405 char opendir ();
13406 int
13407 main ()
13408 {
13409 opendir ();
13410   ;
13411   return 0;
13412 }
13413 _ACEOF
13414 rm -f conftest.$ac_objext conftest$ac_exeext
13415 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13416   (eval $ac_link) 2>conftest.er1
13417   ac_status=$?
13418   grep -v '^ *+' conftest.er1 >conftest.err
13419   rm -f conftest.er1
13420   cat conftest.err >&5
13421   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13422   (exit $ac_status); } &&
13423          { ac_try='test -z "$ac_c_werror_flag"
13424                          || test ! -s conftest.err'
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); }; } &&
13430          { ac_try='test -s conftest$ac_exeext'
13431   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13432   (eval $ac_try) 2>&5
13433   ac_status=$?
13434   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13435   (exit $ac_status); }; }; then
13436   ac_cv_search_opendir="none required"
13437 else
13438   echo "$as_me: failed program was:" >&5
13439 sed 's/^/| /' conftest.$ac_ext >&5
13440
13441 fi
13442 rm -f conftest.err conftest.$ac_objext \
13443       conftest$ac_exeext conftest.$ac_ext
13444 if test "$ac_cv_search_opendir" = no; then
13445   for ac_lib in dir; do
13446     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
13447     cat >conftest.$ac_ext <<_ACEOF
13448 /* confdefs.h.  */
13449 _ACEOF
13450 cat confdefs.h >>conftest.$ac_ext
13451 cat >>conftest.$ac_ext <<_ACEOF
13452 /* end confdefs.h.  */
13453
13454 /* Override any gcc2 internal prototype to avoid an error.  */
13455 #ifdef __cplusplus
13456 extern "C"
13457 #endif
13458 /* We use char because int might match the return type of a gcc2
13459    builtin and then its argument prototype would still apply.  */
13460 char opendir ();
13461 int
13462 main ()
13463 {
13464 opendir ();
13465   ;
13466   return 0;
13467 }
13468 _ACEOF
13469 rm -f conftest.$ac_objext conftest$ac_exeext
13470 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13471   (eval $ac_link) 2>conftest.er1
13472   ac_status=$?
13473   grep -v '^ *+' conftest.er1 >conftest.err
13474   rm -f conftest.er1
13475   cat conftest.err >&5
13476   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13477   (exit $ac_status); } &&
13478          { ac_try='test -z "$ac_c_werror_flag"
13479                          || test ! -s conftest.err'
13480   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13481   (eval $ac_try) 2>&5
13482   ac_status=$?
13483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13484   (exit $ac_status); }; } &&
13485          { ac_try='test -s conftest$ac_exeext'
13486   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13487   (eval $ac_try) 2>&5
13488   ac_status=$?
13489   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13490   (exit $ac_status); }; }; then
13491   ac_cv_search_opendir="-l$ac_lib"
13492 break
13493 else
13494   echo "$as_me: failed program was:" >&5
13495 sed 's/^/| /' conftest.$ac_ext >&5
13496
13497 fi
13498 rm -f conftest.err conftest.$ac_objext \
13499       conftest$ac_exeext conftest.$ac_ext
13500   done
13501 fi
13502 LIBS=$ac_func_search_save_LIBS
13503 fi
13504 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
13505 echo "${ECHO_T}$ac_cv_search_opendir" >&6
13506 if test "$ac_cv_search_opendir" != no; then
13507   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
13508
13509 fi
13510
13511 else
13512   echo "$as_me:$LINENO: checking for library containing opendir" >&5
13513 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
13514 if test "${ac_cv_search_opendir+set}" = set; then
13515   echo $ECHO_N "(cached) $ECHO_C" >&6
13516 else
13517   ac_func_search_save_LIBS=$LIBS
13518 ac_cv_search_opendir=no
13519 cat >conftest.$ac_ext <<_ACEOF
13520 /* confdefs.h.  */
13521 _ACEOF
13522 cat confdefs.h >>conftest.$ac_ext
13523 cat >>conftest.$ac_ext <<_ACEOF
13524 /* end confdefs.h.  */
13525
13526 /* Override any gcc2 internal prototype to avoid an error.  */
13527 #ifdef __cplusplus
13528 extern "C"
13529 #endif
13530 /* We use char because int might match the return type of a gcc2
13531    builtin and then its argument prototype would still apply.  */
13532 char opendir ();
13533 int
13534 main ()
13535 {
13536 opendir ();
13537   ;
13538   return 0;
13539 }
13540 _ACEOF
13541 rm -f conftest.$ac_objext conftest$ac_exeext
13542 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13543   (eval $ac_link) 2>conftest.er1
13544   ac_status=$?
13545   grep -v '^ *+' conftest.er1 >conftest.err
13546   rm -f conftest.er1
13547   cat conftest.err >&5
13548   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13549   (exit $ac_status); } &&
13550          { ac_try='test -z "$ac_c_werror_flag"
13551                          || test ! -s conftest.err'
13552   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13553   (eval $ac_try) 2>&5
13554   ac_status=$?
13555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13556   (exit $ac_status); }; } &&
13557          { ac_try='test -s conftest$ac_exeext'
13558   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13559   (eval $ac_try) 2>&5
13560   ac_status=$?
13561   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13562   (exit $ac_status); }; }; then
13563   ac_cv_search_opendir="none required"
13564 else
13565   echo "$as_me: failed program was:" >&5
13566 sed 's/^/| /' conftest.$ac_ext >&5
13567
13568 fi
13569 rm -f conftest.err conftest.$ac_objext \
13570       conftest$ac_exeext conftest.$ac_ext
13571 if test "$ac_cv_search_opendir" = no; then
13572   for ac_lib in x; do
13573     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
13574     cat >conftest.$ac_ext <<_ACEOF
13575 /* confdefs.h.  */
13576 _ACEOF
13577 cat confdefs.h >>conftest.$ac_ext
13578 cat >>conftest.$ac_ext <<_ACEOF
13579 /* end confdefs.h.  */
13580
13581 /* Override any gcc2 internal prototype to avoid an error.  */
13582 #ifdef __cplusplus
13583 extern "C"
13584 #endif
13585 /* We use char because int might match the return type of a gcc2
13586    builtin and then its argument prototype would still apply.  */
13587 char opendir ();
13588 int
13589 main ()
13590 {
13591 opendir ();
13592   ;
13593   return 0;
13594 }
13595 _ACEOF
13596 rm -f conftest.$ac_objext conftest$ac_exeext
13597 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13598   (eval $ac_link) 2>conftest.er1
13599   ac_status=$?
13600   grep -v '^ *+' conftest.er1 >conftest.err
13601   rm -f conftest.er1
13602   cat conftest.err >&5
13603   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13604   (exit $ac_status); } &&
13605          { ac_try='test -z "$ac_c_werror_flag"
13606                          || test ! -s conftest.err'
13607   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13608   (eval $ac_try) 2>&5
13609   ac_status=$?
13610   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13611   (exit $ac_status); }; } &&
13612          { ac_try='test -s conftest$ac_exeext'
13613   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13614   (eval $ac_try) 2>&5
13615   ac_status=$?
13616   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13617   (exit $ac_status); }; }; then
13618   ac_cv_search_opendir="-l$ac_lib"
13619 break
13620 else
13621   echo "$as_me: failed program was:" >&5
13622 sed 's/^/| /' conftest.$ac_ext >&5
13623
13624 fi
13625 rm -f conftest.err conftest.$ac_objext \
13626       conftest$ac_exeext conftest.$ac_ext
13627   done
13628 fi
13629 LIBS=$ac_func_search_save_LIBS
13630 fi
13631 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
13632 echo "${ECHO_T}$ac_cv_search_opendir" >&6
13633 if test "$ac_cv_search_opendir" != no; then
13634   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
13635
13636 fi
13637
13638 fi
13639
13640 echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
13641 echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
13642 if test "${ac_cv_header_sys_wait_h+set}" = set; then
13643   echo $ECHO_N "(cached) $ECHO_C" >&6
13644 else
13645   cat >conftest.$ac_ext <<_ACEOF
13646 /* confdefs.h.  */
13647 _ACEOF
13648 cat confdefs.h >>conftest.$ac_ext
13649 cat >>conftest.$ac_ext <<_ACEOF
13650 /* end confdefs.h.  */
13651 #include <sys/types.h>
13652 #include <sys/wait.h>
13653 #ifndef WEXITSTATUS
13654 # define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
13655 #endif
13656 #ifndef WIFEXITED
13657 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
13658 #endif
13659
13660 int
13661 main ()
13662 {
13663   int s;
13664   wait (&s);
13665   s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
13666   ;
13667   return 0;
13668 }
13669 _ACEOF
13670 rm -f conftest.$ac_objext
13671 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13672   (eval $ac_compile) 2>conftest.er1
13673   ac_status=$?
13674   grep -v '^ *+' conftest.er1 >conftest.err
13675   rm -f conftest.er1
13676   cat conftest.err >&5
13677   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13678   (exit $ac_status); } &&
13679          { ac_try='test -z "$ac_c_werror_flag"
13680                          || test ! -s conftest.err'
13681   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13682   (eval $ac_try) 2>&5
13683   ac_status=$?
13684   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13685   (exit $ac_status); }; } &&
13686          { ac_try='test -s conftest.$ac_objext'
13687   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13688   (eval $ac_try) 2>&5
13689   ac_status=$?
13690   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13691   (exit $ac_status); }; }; then
13692   ac_cv_header_sys_wait_h=yes
13693 else
13694   echo "$as_me: failed program was:" >&5
13695 sed 's/^/| /' conftest.$ac_ext >&5
13696
13697 ac_cv_header_sys_wait_h=no
13698 fi
13699 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13700 fi
13701 echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
13702 echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
13703 if test $ac_cv_header_sys_wait_h = yes; then
13704
13705 cat >>confdefs.h <<\_ACEOF
13706 #define HAVE_SYS_WAIT_H 1
13707 _ACEOF
13708
13709 fi
13710
13711 echo "$as_me:$LINENO: checking whether termios.h defines TIOCGWINSZ" >&5
13712 echo $ECHO_N "checking whether termios.h defines TIOCGWINSZ... $ECHO_C" >&6
13713 if test "${ac_cv_sys_tiocgwinsz_in_termios_h+set}" = set; then
13714   echo $ECHO_N "(cached) $ECHO_C" >&6
13715 else
13716   cat >conftest.$ac_ext <<_ACEOF
13717 /* confdefs.h.  */
13718 _ACEOF
13719 cat confdefs.h >>conftest.$ac_ext
13720 cat >>conftest.$ac_ext <<_ACEOF
13721 /* end confdefs.h.  */
13722 #include <sys/types.h>
13723 #include <termios.h>
13724 #ifdef TIOCGWINSZ
13725   yes
13726 #endif
13727
13728 _ACEOF
13729 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13730   $EGREP "yes" >/dev/null 2>&1; then
13731   ac_cv_sys_tiocgwinsz_in_termios_h=yes
13732 else
13733   ac_cv_sys_tiocgwinsz_in_termios_h=no
13734 fi
13735 rm -f conftest*
13736
13737 fi
13738 echo "$as_me:$LINENO: result: $ac_cv_sys_tiocgwinsz_in_termios_h" >&5
13739 echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_termios_h" >&6
13740
13741 if test $ac_cv_sys_tiocgwinsz_in_termios_h != yes; then
13742   echo "$as_me:$LINENO: checking whether sys/ioctl.h defines TIOCGWINSZ" >&5
13743 echo $ECHO_N "checking whether sys/ioctl.h defines TIOCGWINSZ... $ECHO_C" >&6
13744 if test "${ac_cv_sys_tiocgwinsz_in_sys_ioctl_h+set}" = set; then
13745   echo $ECHO_N "(cached) $ECHO_C" >&6
13746 else
13747   cat >conftest.$ac_ext <<_ACEOF
13748 /* confdefs.h.  */
13749 _ACEOF
13750 cat confdefs.h >>conftest.$ac_ext
13751 cat >>conftest.$ac_ext <<_ACEOF
13752 /* end confdefs.h.  */
13753 #include <sys/types.h>
13754 #include <sys/ioctl.h>
13755 #ifdef TIOCGWINSZ
13756   yes
13757 #endif
13758
13759 _ACEOF
13760 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13761   $EGREP "yes" >/dev/null 2>&1; then
13762   ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=yes
13763 else
13764   ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=no
13765 fi
13766 rm -f conftest*
13767
13768 fi
13769 echo "$as_me:$LINENO: result: $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&5
13770 echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&6
13771
13772   if test $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h = yes; then
13773
13774 cat >>confdefs.h <<\_ACEOF
13775 #define GWINSZ_IN_SYS_IOCTL 1
13776 _ACEOF
13777
13778   fi
13779 fi
13780
13781
13782
13783
13784
13785
13786
13787
13788
13789
13790
13791
13792
13793
13794
13795
13796
13797
13798
13799
13800
13801
13802
13803
13804
13805
13806
13807
13808
13809
13810
13811
13812
13813
13814
13815
13816
13817
13818
13819
13820
13821
13822
13823
13824
13825
13826
13827
13828
13829 for ac_header in \
13830         arpa/inet.h             \
13831         arpa/nameser.h  \
13832         assert.h                \
13833         bits/types.h    \
13834         conio.h                 \
13835         crypt.h                 \
13836         direct.h                \
13837         errno.h                 \
13838         fcntl.h                 \
13839         filio.h                 \
13840         getopt.h                \
13841         grp.h                   \
13842         io.h                    \
13843         libutil.h               \
13844         limits.h                \
13845         locale.h                \
13846         malloc.h                \
13847         memory.h                \
13848         psap.h                  \
13849         pwd.h                   \
13850         process.h               \
13851         sgtty.h                 \
13852         shadow.h                \
13853         stddef.h                \
13854         string.h                \
13855         strings.h               \
13856         sysexits.h              \
13857         sys/file.h              \
13858         sys/filio.h             \
13859         sys/fstyp.h             \
13860         sys/errno.h             \
13861         sys/ioctl.h             \
13862         sys/param.h             \
13863         sys/privgrp.h   \
13864         sys/resource.h  \
13865         sys/select.h    \
13866         sys/socket.h    \
13867         sys/stat.h              \
13868         sys/syslog.h    \
13869         sys/time.h              \
13870         sys/types.h             \
13871         sys/uio.h               \
13872         sys/vmount.h    \
13873         syslog.h                \
13874         termios.h               \
13875         unistd.h                \
13876         utime.h                 \
13877
13878 do
13879 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13880 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13881   echo "$as_me:$LINENO: checking for $ac_header" >&5
13882 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13883 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13884   echo $ECHO_N "(cached) $ECHO_C" >&6
13885 fi
13886 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13887 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13888 else
13889   # Is the header compilable?
13890 echo "$as_me:$LINENO: checking $ac_header usability" >&5
13891 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13892 cat >conftest.$ac_ext <<_ACEOF
13893 /* confdefs.h.  */
13894 _ACEOF
13895 cat confdefs.h >>conftest.$ac_ext
13896 cat >>conftest.$ac_ext <<_ACEOF
13897 /* end confdefs.h.  */
13898 $ac_includes_default
13899 #include <$ac_header>
13900 _ACEOF
13901 rm -f conftest.$ac_objext
13902 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13903   (eval $ac_compile) 2>conftest.er1
13904   ac_status=$?
13905   grep -v '^ *+' conftest.er1 >conftest.err
13906   rm -f conftest.er1
13907   cat conftest.err >&5
13908   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13909   (exit $ac_status); } &&
13910          { ac_try='test -z "$ac_c_werror_flag"
13911                          || test ! -s conftest.err'
13912   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13913   (eval $ac_try) 2>&5
13914   ac_status=$?
13915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13916   (exit $ac_status); }; } &&
13917          { ac_try='test -s conftest.$ac_objext'
13918   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13919   (eval $ac_try) 2>&5
13920   ac_status=$?
13921   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13922   (exit $ac_status); }; }; then
13923   ac_header_compiler=yes
13924 else
13925   echo "$as_me: failed program was:" >&5
13926 sed 's/^/| /' conftest.$ac_ext >&5
13927
13928 ac_header_compiler=no
13929 fi
13930 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13931 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13932 echo "${ECHO_T}$ac_header_compiler" >&6
13933
13934 # Is the header present?
13935 echo "$as_me:$LINENO: checking $ac_header presence" >&5
13936 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13937 cat >conftest.$ac_ext <<_ACEOF
13938 /* confdefs.h.  */
13939 _ACEOF
13940 cat confdefs.h >>conftest.$ac_ext
13941 cat >>conftest.$ac_ext <<_ACEOF
13942 /* end confdefs.h.  */
13943 #include <$ac_header>
13944 _ACEOF
13945 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13946   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13947   ac_status=$?
13948   grep -v '^ *+' conftest.er1 >conftest.err
13949   rm -f conftest.er1
13950   cat conftest.err >&5
13951   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13952   (exit $ac_status); } >/dev/null; then
13953   if test -s conftest.err; then
13954     ac_cpp_err=$ac_c_preproc_warn_flag
13955     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
13956   else
13957     ac_cpp_err=
13958   fi
13959 else
13960   ac_cpp_err=yes
13961 fi
13962 if test -z "$ac_cpp_err"; then
13963   ac_header_preproc=yes
13964 else
13965   echo "$as_me: failed program was:" >&5
13966 sed 's/^/| /' conftest.$ac_ext >&5
13967
13968   ac_header_preproc=no
13969 fi
13970 rm -f conftest.err conftest.$ac_ext
13971 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13972 echo "${ECHO_T}$ac_header_preproc" >&6
13973
13974 # So?  What about this header?
13975 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13976   yes:no: )
13977     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13978 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13979     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13980 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13981     ac_header_preproc=yes
13982     ;;
13983   no:yes:* )
13984     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13985 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13986     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13987 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13988     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13989 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13990     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13991 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13992     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13993 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13994     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13995 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13996     (
13997       cat <<\_ASBOX
13998 ## --------------------------------------------- ##
13999 ## Report this to <http://www.openldap.org/its/> ##
14000 ## --------------------------------------------- ##
14001 _ASBOX
14002     ) |
14003       sed "s/^/$as_me: WARNING:     /" >&2
14004     ;;
14005 esac
14006 echo "$as_me:$LINENO: checking for $ac_header" >&5
14007 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14008 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14009   echo $ECHO_N "(cached) $ECHO_C" >&6
14010 else
14011   eval "$as_ac_Header=\$ac_header_preproc"
14012 fi
14013 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14014 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14015
14016 fi
14017 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14018   cat >>confdefs.h <<_ACEOF
14019 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14020 _ACEOF
14021
14022 fi
14023
14024 done
14025
14026
14027 if test "$ac_cv_mingw32" = yes ; then
14028
14029
14030 for ac_header in winsock.h winsock2.h
14031 do
14032 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14033 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14034   echo "$as_me:$LINENO: checking for $ac_header" >&5
14035 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14036 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14037   echo $ECHO_N "(cached) $ECHO_C" >&6
14038 fi
14039 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14040 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14041 else
14042   # Is the header compilable?
14043 echo "$as_me:$LINENO: checking $ac_header usability" >&5
14044 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
14045 cat >conftest.$ac_ext <<_ACEOF
14046 /* confdefs.h.  */
14047 _ACEOF
14048 cat confdefs.h >>conftest.$ac_ext
14049 cat >>conftest.$ac_ext <<_ACEOF
14050 /* end confdefs.h.  */
14051 $ac_includes_default
14052 #include <$ac_header>
14053 _ACEOF
14054 rm -f conftest.$ac_objext
14055 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14056   (eval $ac_compile) 2>conftest.er1
14057   ac_status=$?
14058   grep -v '^ *+' conftest.er1 >conftest.err
14059   rm -f conftest.er1
14060   cat conftest.err >&5
14061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14062   (exit $ac_status); } &&
14063          { ac_try='test -z "$ac_c_werror_flag"
14064                          || test ! -s conftest.err'
14065   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14066   (eval $ac_try) 2>&5
14067   ac_status=$?
14068   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14069   (exit $ac_status); }; } &&
14070          { ac_try='test -s conftest.$ac_objext'
14071   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14072   (eval $ac_try) 2>&5
14073   ac_status=$?
14074   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14075   (exit $ac_status); }; }; then
14076   ac_header_compiler=yes
14077 else
14078   echo "$as_me: failed program was:" >&5
14079 sed 's/^/| /' conftest.$ac_ext >&5
14080
14081 ac_header_compiler=no
14082 fi
14083 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14084 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14085 echo "${ECHO_T}$ac_header_compiler" >&6
14086
14087 # Is the header present?
14088 echo "$as_me:$LINENO: checking $ac_header presence" >&5
14089 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
14090 cat >conftest.$ac_ext <<_ACEOF
14091 /* confdefs.h.  */
14092 _ACEOF
14093 cat confdefs.h >>conftest.$ac_ext
14094 cat >>conftest.$ac_ext <<_ACEOF
14095 /* end confdefs.h.  */
14096 #include <$ac_header>
14097 _ACEOF
14098 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
14099   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14100   ac_status=$?
14101   grep -v '^ *+' conftest.er1 >conftest.err
14102   rm -f conftest.er1
14103   cat conftest.err >&5
14104   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14105   (exit $ac_status); } >/dev/null; then
14106   if test -s conftest.err; then
14107     ac_cpp_err=$ac_c_preproc_warn_flag
14108     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
14109   else
14110     ac_cpp_err=
14111   fi
14112 else
14113   ac_cpp_err=yes
14114 fi
14115 if test -z "$ac_cpp_err"; then
14116   ac_header_preproc=yes
14117 else
14118   echo "$as_me: failed program was:" >&5
14119 sed 's/^/| /' conftest.$ac_ext >&5
14120
14121   ac_header_preproc=no
14122 fi
14123 rm -f conftest.err conftest.$ac_ext
14124 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14125 echo "${ECHO_T}$ac_header_preproc" >&6
14126
14127 # So?  What about this header?
14128 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14129   yes:no: )
14130     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14131 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14132     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14133 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14134     ac_header_preproc=yes
14135     ;;
14136   no:yes:* )
14137     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14138 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14139     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14140 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14141     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14142 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14143     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14144 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14145     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14146 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14147     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14148 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14149     (
14150       cat <<\_ASBOX
14151 ## --------------------------------------------- ##
14152 ## Report this to <http://www.openldap.org/its/> ##
14153 ## --------------------------------------------- ##
14154 _ASBOX
14155     ) |
14156       sed "s/^/$as_me: WARNING:     /" >&2
14157     ;;
14158 esac
14159 echo "$as_me:$LINENO: checking for $ac_header" >&5
14160 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14161 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14162   echo $ECHO_N "(cached) $ECHO_C" >&6
14163 else
14164   eval "$as_ac_Header=\$ac_header_preproc"
14165 fi
14166 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14167 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14168
14169 fi
14170 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14171   cat >>confdefs.h <<_ACEOF
14172 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14173 _ACEOF
14174
14175 fi
14176
14177 done
14178
14179 fi
14180
14181
14182 for ac_header in resolv.h
14183 do
14184 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14185 echo "$as_me:$LINENO: checking for $ac_header" >&5
14186 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14187 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14188   echo $ECHO_N "(cached) $ECHO_C" >&6
14189 else
14190   cat >conftest.$ac_ext <<_ACEOF
14191 /* confdefs.h.  */
14192 _ACEOF
14193 cat confdefs.h >>conftest.$ac_ext
14194 cat >>conftest.$ac_ext <<_ACEOF
14195 /* end confdefs.h.  */
14196 $ac_includes_default
14197 #include <netinet/in.h>
14198
14199
14200 #include <$ac_header>
14201 _ACEOF
14202 rm -f conftest.$ac_objext
14203 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14204   (eval $ac_compile) 2>conftest.er1
14205   ac_status=$?
14206   grep -v '^ *+' conftest.er1 >conftest.err
14207   rm -f conftest.er1
14208   cat conftest.err >&5
14209   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14210   (exit $ac_status); } &&
14211          { ac_try='test -z "$ac_c_werror_flag"
14212                          || test ! -s conftest.err'
14213   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14214   (eval $ac_try) 2>&5
14215   ac_status=$?
14216   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14217   (exit $ac_status); }; } &&
14218          { ac_try='test -s conftest.$ac_objext'
14219   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14220   (eval $ac_try) 2>&5
14221   ac_status=$?
14222   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14223   (exit $ac_status); }; }; then
14224   eval "$as_ac_Header=yes"
14225 else
14226   echo "$as_me: failed program was:" >&5
14227 sed 's/^/| /' conftest.$ac_ext >&5
14228
14229 eval "$as_ac_Header=no"
14230 fi
14231 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14232 fi
14233 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14234 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14235 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14236   cat >>confdefs.h <<_ACEOF
14237 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14238 _ACEOF
14239
14240 fi
14241
14242 done
14243
14244
14245
14246 for ac_header in netinet/tcp.h
14247 do
14248 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14249 echo "$as_me:$LINENO: checking for $ac_header" >&5
14250 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14251 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14252   echo $ECHO_N "(cached) $ECHO_C" >&6
14253 else
14254   cat >conftest.$ac_ext <<_ACEOF
14255 /* confdefs.h.  */
14256 _ACEOF
14257 cat confdefs.h >>conftest.$ac_ext
14258 cat >>conftest.$ac_ext <<_ACEOF
14259 /* end confdefs.h.  */
14260 $ac_includes_default
14261 #include <netinet/in.h>
14262
14263
14264 #include <$ac_header>
14265 _ACEOF
14266 rm -f conftest.$ac_objext
14267 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14268   (eval $ac_compile) 2>conftest.er1
14269   ac_status=$?
14270   grep -v '^ *+' conftest.er1 >conftest.err
14271   rm -f conftest.er1
14272   cat conftest.err >&5
14273   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14274   (exit $ac_status); } &&
14275          { ac_try='test -z "$ac_c_werror_flag"
14276                          || test ! -s conftest.err'
14277   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14278   (eval $ac_try) 2>&5
14279   ac_status=$?
14280   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14281   (exit $ac_status); }; } &&
14282          { ac_try='test -s conftest.$ac_objext'
14283   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14284   (eval $ac_try) 2>&5
14285   ac_status=$?
14286   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14287   (exit $ac_status); }; }; then
14288   eval "$as_ac_Header=yes"
14289 else
14290   echo "$as_me: failed program was:" >&5
14291 sed 's/^/| /' conftest.$ac_ext >&5
14292
14293 eval "$as_ac_Header=no"
14294 fi
14295 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14296 fi
14297 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14298 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14299 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14300   cat >>confdefs.h <<_ACEOF
14301 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14302 _ACEOF
14303
14304 fi
14305
14306 done
14307
14308
14309
14310 for ac_header in sys/ucred.h
14311 do
14312 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14313 echo "$as_me:$LINENO: checking for $ac_header" >&5
14314 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14315 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14316   echo $ECHO_N "(cached) $ECHO_C" >&6
14317 else
14318   cat >conftest.$ac_ext <<_ACEOF
14319 /* confdefs.h.  */
14320 _ACEOF
14321 cat confdefs.h >>conftest.$ac_ext
14322 cat >>conftest.$ac_ext <<_ACEOF
14323 /* end confdefs.h.  */
14324 $ac_includes_default
14325 #ifdef HAVE_SYS_PARAM_H
14326 #include <sys/param.h>
14327 #endif
14328
14329
14330 #include <$ac_header>
14331 _ACEOF
14332 rm -f conftest.$ac_objext
14333 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14334   (eval $ac_compile) 2>conftest.er1
14335   ac_status=$?
14336   grep -v '^ *+' conftest.er1 >conftest.err
14337   rm -f conftest.er1
14338   cat conftest.err >&5
14339   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14340   (exit $ac_status); } &&
14341          { ac_try='test -z "$ac_c_werror_flag"
14342                          || test ! -s conftest.err'
14343   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14344   (eval $ac_try) 2>&5
14345   ac_status=$?
14346   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14347   (exit $ac_status); }; } &&
14348          { ac_try='test -s conftest.$ac_objext'
14349   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14350   (eval $ac_try) 2>&5
14351   ac_status=$?
14352   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14353   (exit $ac_status); }; }; then
14354   eval "$as_ac_Header=yes"
14355 else
14356   echo "$as_me: failed program was:" >&5
14357 sed 's/^/| /' conftest.$ac_ext >&5
14358
14359 eval "$as_ac_Header=no"
14360 fi
14361 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14362 fi
14363 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14364 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14365 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14366   cat >>confdefs.h <<_ACEOF
14367 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14368 _ACEOF
14369
14370 fi
14371
14372 done
14373
14374
14375
14376
14377
14378 for ac_func in sigaction sigset
14379 do
14380 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14381 echo "$as_me:$LINENO: checking for $ac_func" >&5
14382 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14383 if eval "test \"\${$as_ac_var+set}\" = set"; then
14384   echo $ECHO_N "(cached) $ECHO_C" >&6
14385 else
14386   cat >conftest.$ac_ext <<_ACEOF
14387 /* confdefs.h.  */
14388 _ACEOF
14389 cat confdefs.h >>conftest.$ac_ext
14390 cat >>conftest.$ac_ext <<_ACEOF
14391 /* end confdefs.h.  */
14392 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14393    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14394 #define $ac_func innocuous_$ac_func
14395
14396 /* System header to define __stub macros and hopefully few prototypes,
14397     which can conflict with char $ac_func (); below.
14398     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14399     <limits.h> exists even on freestanding compilers.  */
14400
14401 #ifdef __STDC__
14402 # include <limits.h>
14403 #else
14404 # include <assert.h>
14405 #endif
14406
14407 #undef $ac_func
14408
14409 /* Override any gcc2 internal prototype to avoid an error.  */
14410 #ifdef __cplusplus
14411 extern "C"
14412 {
14413 #endif
14414 /* We use char because int might match the return type of a gcc2
14415    builtin and then its argument prototype would still apply.  */
14416 char $ac_func ();
14417 /* The GNU C library defines this for functions which it implements
14418     to always fail with ENOSYS.  Some functions are actually named
14419     something starting with __ and the normal name is an alias.  */
14420 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14421 choke me
14422 #else
14423 char (*f) () = $ac_func;
14424 #endif
14425 #ifdef __cplusplus
14426 }
14427 #endif
14428
14429 int
14430 main ()
14431 {
14432 return f != $ac_func;
14433   ;
14434   return 0;
14435 }
14436 _ACEOF
14437 rm -f conftest.$ac_objext conftest$ac_exeext
14438 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14439   (eval $ac_link) 2>conftest.er1
14440   ac_status=$?
14441   grep -v '^ *+' conftest.er1 >conftest.err
14442   rm -f conftest.er1
14443   cat conftest.err >&5
14444   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14445   (exit $ac_status); } &&
14446          { ac_try='test -z "$ac_c_werror_flag"
14447                          || test ! -s conftest.err'
14448   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14449   (eval $ac_try) 2>&5
14450   ac_status=$?
14451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14452   (exit $ac_status); }; } &&
14453          { ac_try='test -s conftest$ac_exeext'
14454   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14455   (eval $ac_try) 2>&5
14456   ac_status=$?
14457   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14458   (exit $ac_status); }; }; then
14459   eval "$as_ac_var=yes"
14460 else
14461   echo "$as_me: failed program was:" >&5
14462 sed 's/^/| /' conftest.$ac_ext >&5
14463
14464 eval "$as_ac_var=no"
14465 fi
14466 rm -f conftest.err conftest.$ac_objext \
14467       conftest$ac_exeext conftest.$ac_ext
14468 fi
14469 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14470 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14471 if test `eval echo '${'$as_ac_var'}'` = yes; then
14472   cat >>confdefs.h <<_ACEOF
14473 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14474 _ACEOF
14475
14476 fi
14477 done
14478
14479
14480 if test $ac_cv_func_sigaction = no && test $ac_cv_func_sigaction = no ; then
14481
14482 echo "$as_me:$LINENO: checking for sigset in -lV3" >&5
14483 echo $ECHO_N "checking for sigset in -lV3... $ECHO_C" >&6
14484 if test "${ac_cv_lib_V3_sigset+set}" = set; then
14485   echo $ECHO_N "(cached) $ECHO_C" >&6
14486 else
14487   ac_check_lib_save_LIBS=$LIBS
14488 LIBS="-lV3  $LIBS"
14489 cat >conftest.$ac_ext <<_ACEOF
14490 /* confdefs.h.  */
14491 _ACEOF
14492 cat confdefs.h >>conftest.$ac_ext
14493 cat >>conftest.$ac_ext <<_ACEOF
14494 /* end confdefs.h.  */
14495
14496 /* Override any gcc2 internal prototype to avoid an error.  */
14497 #ifdef __cplusplus
14498 extern "C"
14499 #endif
14500 /* We use char because int might match the return type of a gcc2
14501    builtin and then its argument prototype would still apply.  */
14502 char sigset ();
14503 int
14504 main ()
14505 {
14506 sigset ();
14507   ;
14508   return 0;
14509 }
14510 _ACEOF
14511 rm -f conftest.$ac_objext conftest$ac_exeext
14512 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14513   (eval $ac_link) 2>conftest.er1
14514   ac_status=$?
14515   grep -v '^ *+' conftest.er1 >conftest.err
14516   rm -f conftest.er1
14517   cat conftest.err >&5
14518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14519   (exit $ac_status); } &&
14520          { ac_try='test -z "$ac_c_werror_flag"
14521                          || test ! -s conftest.err'
14522   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14523   (eval $ac_try) 2>&5
14524   ac_status=$?
14525   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14526   (exit $ac_status); }; } &&
14527          { ac_try='test -s conftest$ac_exeext'
14528   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14529   (eval $ac_try) 2>&5
14530   ac_status=$?
14531   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14532   (exit $ac_status); }; }; then
14533   ac_cv_lib_V3_sigset=yes
14534 else
14535   echo "$as_me: failed program was:" >&5
14536 sed 's/^/| /' conftest.$ac_ext >&5
14537
14538 ac_cv_lib_V3_sigset=no
14539 fi
14540 rm -f conftest.err conftest.$ac_objext \
14541       conftest$ac_exeext conftest.$ac_ext
14542 LIBS=$ac_check_lib_save_LIBS
14543 fi
14544 echo "$as_me:$LINENO: result: $ac_cv_lib_V3_sigset" >&5
14545 echo "${ECHO_T}$ac_cv_lib_V3_sigset" >&6
14546 if test $ac_cv_lib_V3_sigset = yes; then
14547   cat >>confdefs.h <<_ACEOF
14548 #define HAVE_LIBV3 1
14549 _ACEOF
14550
14551   LIBS="-lV3 $LIBS"
14552
14553 fi
14554
14555 fi
14556
14557 if test "$ac_cv_header_winsock_h" = yes; then
14558 echo "$as_me:$LINENO: checking for winsock" >&5
14559 echo $ECHO_N "checking for winsock... $ECHO_C" >&6
14560 if test "${ol_cv_winsock+set}" = set; then
14561   echo $ECHO_N "(cached) $ECHO_C" >&6
14562 else
14563   save_LIBS="$LIBS"
14564 for curlib in ws2_32 wsock32; do
14565         LIBS="$LIBS -l$curlib"
14566         cat >conftest.$ac_ext <<_ACEOF
14567 /* confdefs.h.  */
14568 _ACEOF
14569 cat confdefs.h >>conftest.$ac_ext
14570 cat >>conftest.$ac_ext <<_ACEOF
14571 /* end confdefs.h.  */
14572 #include <winsock.h>
14573
14574 int
14575 main ()
14576 {
14577
14578                         socket(0,0,0);
14579                         select(0,NULL,NULL,NULL,NULL);
14580                         closesocket(0);
14581                         gethostname(NULL,0);
14582
14583   ;
14584   return 0;
14585 }
14586 _ACEOF
14587 rm -f conftest.$ac_objext conftest$ac_exeext
14588 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14589   (eval $ac_link) 2>conftest.er1
14590   ac_status=$?
14591   grep -v '^ *+' conftest.er1 >conftest.err
14592   rm -f conftest.er1
14593   cat conftest.err >&5
14594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14595   (exit $ac_status); } &&
14596          { ac_try='test -z "$ac_c_werror_flag"
14597                          || test ! -s conftest.err'
14598   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14599   (eval $ac_try) 2>&5
14600   ac_status=$?
14601   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14602   (exit $ac_status); }; } &&
14603          { ac_try='test -s conftest$ac_exeext'
14604   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14605   (eval $ac_try) 2>&5
14606   ac_status=$?
14607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14608   (exit $ac_status); }; }; then
14609   ol_cv_winsock=yes
14610 else
14611   echo "$as_me: failed program was:" >&5
14612 sed 's/^/| /' conftest.$ac_ext >&5
14613
14614 ol_cv_winsock=no
14615 fi
14616 rm -f conftest.err conftest.$ac_objext \
14617       conftest$ac_exeext conftest.$ac_ext
14618
14619         if test $ol_cv_winsock = yes; then
14620
14621 cat >>confdefs.h <<\_ACEOF
14622 #define HAVE_WINSOCK 1
14623 _ACEOF
14624
14625                 ac_cv_func_socket=yes
14626                 ac_cv_func_select=yes
14627                 ac_cv_func_closesocket=yes
14628                 ac_cv_func_gethostname=yes
14629                 if test $curlib = ws2_32; then
14630                         ol_cv_winsock=winsock2
14631
14632 cat >>confdefs.h <<\_ACEOF
14633 #define HAVE_WINSOCK2 1
14634 _ACEOF
14635
14636                 fi
14637                 break
14638         fi
14639         LIBS="$save_LIBS"
14640 done
14641 fi
14642 echo "$as_me:$LINENO: result: $ol_cv_winsock" >&5
14643 echo "${ECHO_T}$ol_cv_winsock" >&6
14644 fi
14645
14646
14647 echo "$as_me:$LINENO: checking for socket" >&5
14648 echo $ECHO_N "checking for socket... $ECHO_C" >&6
14649 if test "${ac_cv_func_socket+set}" = set; then
14650   echo $ECHO_N "(cached) $ECHO_C" >&6
14651 else
14652   cat >conftest.$ac_ext <<_ACEOF
14653 /* confdefs.h.  */
14654 _ACEOF
14655 cat confdefs.h >>conftest.$ac_ext
14656 cat >>conftest.$ac_ext <<_ACEOF
14657 /* end confdefs.h.  */
14658 /* Define socket to an innocuous variant, in case <limits.h> declares socket.
14659    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14660 #define socket innocuous_socket
14661
14662 /* System header to define __stub macros and hopefully few prototypes,
14663     which can conflict with char socket (); below.
14664     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14665     <limits.h> exists even on freestanding compilers.  */
14666
14667 #ifdef __STDC__
14668 # include <limits.h>
14669 #else
14670 # include <assert.h>
14671 #endif
14672
14673 #undef socket
14674
14675 /* Override any gcc2 internal prototype to avoid an error.  */
14676 #ifdef __cplusplus
14677 extern "C"
14678 {
14679 #endif
14680 /* We use char because int might match the return type of a gcc2
14681    builtin and then its argument prototype would still apply.  */
14682 char socket ();
14683 /* The GNU C library defines this for functions which it implements
14684     to always fail with ENOSYS.  Some functions are actually named
14685     something starting with __ and the normal name is an alias.  */
14686 #if defined (__stub_socket) || defined (__stub___socket)
14687 choke me
14688 #else
14689 char (*f) () = socket;
14690 #endif
14691 #ifdef __cplusplus
14692 }
14693 #endif
14694
14695 int
14696 main ()
14697 {
14698 return f != socket;
14699   ;
14700   return 0;
14701 }
14702 _ACEOF
14703 rm -f conftest.$ac_objext conftest$ac_exeext
14704 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14705   (eval $ac_link) 2>conftest.er1
14706   ac_status=$?
14707   grep -v '^ *+' conftest.er1 >conftest.err
14708   rm -f conftest.er1
14709   cat conftest.err >&5
14710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14711   (exit $ac_status); } &&
14712          { ac_try='test -z "$ac_c_werror_flag"
14713                          || test ! -s conftest.err'
14714   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14715   (eval $ac_try) 2>&5
14716   ac_status=$?
14717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14718   (exit $ac_status); }; } &&
14719          { ac_try='test -s conftest$ac_exeext'
14720   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14721   (eval $ac_try) 2>&5
14722   ac_status=$?
14723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14724   (exit $ac_status); }; }; then
14725   ac_cv_func_socket=yes
14726 else
14727   echo "$as_me: failed program was:" >&5
14728 sed 's/^/| /' conftest.$ac_ext >&5
14729
14730 ac_cv_func_socket=no
14731 fi
14732 rm -f conftest.err conftest.$ac_objext \
14733       conftest$ac_exeext conftest.$ac_ext
14734 fi
14735 echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
14736 echo "${ECHO_T}$ac_cv_func_socket" >&6
14737 if test $ac_cv_func_socket = yes; then
14738   :
14739 else
14740
14741
14742 echo "$as_me:$LINENO: checking for main in -lsocket" >&5
14743 echo $ECHO_N "checking for main in -lsocket... $ECHO_C" >&6
14744 if test "${ac_cv_lib_socket_main+set}" = set; then
14745   echo $ECHO_N "(cached) $ECHO_C" >&6
14746 else
14747   ac_check_lib_save_LIBS=$LIBS
14748 LIBS="-lsocket  $LIBS"
14749 cat >conftest.$ac_ext <<_ACEOF
14750 /* confdefs.h.  */
14751 _ACEOF
14752 cat confdefs.h >>conftest.$ac_ext
14753 cat >>conftest.$ac_ext <<_ACEOF
14754 /* end confdefs.h.  */
14755
14756
14757 int
14758 main ()
14759 {
14760 main ();
14761   ;
14762   return 0;
14763 }
14764 _ACEOF
14765 rm -f conftest.$ac_objext conftest$ac_exeext
14766 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14767   (eval $ac_link) 2>conftest.er1
14768   ac_status=$?
14769   grep -v '^ *+' conftest.er1 >conftest.err
14770   rm -f conftest.er1
14771   cat conftest.err >&5
14772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14773   (exit $ac_status); } &&
14774          { ac_try='test -z "$ac_c_werror_flag"
14775                          || test ! -s conftest.err'
14776   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14777   (eval $ac_try) 2>&5
14778   ac_status=$?
14779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14780   (exit $ac_status); }; } &&
14781          { ac_try='test -s conftest$ac_exeext'
14782   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14783   (eval $ac_try) 2>&5
14784   ac_status=$?
14785   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14786   (exit $ac_status); }; }; then
14787   ac_cv_lib_socket_main=yes
14788 else
14789   echo "$as_me: failed program was:" >&5
14790 sed 's/^/| /' conftest.$ac_ext >&5
14791
14792 ac_cv_lib_socket_main=no
14793 fi
14794 rm -f conftest.err conftest.$ac_objext \
14795       conftest$ac_exeext conftest.$ac_ext
14796 LIBS=$ac_check_lib_save_LIBS
14797 fi
14798 echo "$as_me:$LINENO: result: $ac_cv_lib_socket_main" >&5
14799 echo "${ECHO_T}$ac_cv_lib_socket_main" >&6
14800 if test $ac_cv_lib_socket_main = yes; then
14801   cat >>confdefs.h <<_ACEOF
14802 #define HAVE_LIBSOCKET 1
14803 _ACEOF
14804
14805   LIBS="-lsocket $LIBS"
14806
14807 fi
14808
14809
14810 echo "$as_me:$LINENO: checking for main in -lnet" >&5
14811 echo $ECHO_N "checking for main in -lnet... $ECHO_C" >&6
14812 if test "${ac_cv_lib_net_main+set}" = set; then
14813   echo $ECHO_N "(cached) $ECHO_C" >&6
14814 else
14815   ac_check_lib_save_LIBS=$LIBS
14816 LIBS="-lnet  $LIBS"
14817 cat >conftest.$ac_ext <<_ACEOF
14818 /* confdefs.h.  */
14819 _ACEOF
14820 cat confdefs.h >>conftest.$ac_ext
14821 cat >>conftest.$ac_ext <<_ACEOF
14822 /* end confdefs.h.  */
14823
14824
14825 int
14826 main ()
14827 {
14828 main ();
14829   ;
14830   return 0;
14831 }
14832 _ACEOF
14833 rm -f conftest.$ac_objext conftest$ac_exeext
14834 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14835   (eval $ac_link) 2>conftest.er1
14836   ac_status=$?
14837   grep -v '^ *+' conftest.er1 >conftest.err
14838   rm -f conftest.er1
14839   cat conftest.err >&5
14840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14841   (exit $ac_status); } &&
14842          { ac_try='test -z "$ac_c_werror_flag"
14843                          || test ! -s conftest.err'
14844   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14845   (eval $ac_try) 2>&5
14846   ac_status=$?
14847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14848   (exit $ac_status); }; } &&
14849          { ac_try='test -s conftest$ac_exeext'
14850   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14851   (eval $ac_try) 2>&5
14852   ac_status=$?
14853   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14854   (exit $ac_status); }; }; then
14855   ac_cv_lib_net_main=yes
14856 else
14857   echo "$as_me: failed program was:" >&5
14858 sed 's/^/| /' conftest.$ac_ext >&5
14859
14860 ac_cv_lib_net_main=no
14861 fi
14862 rm -f conftest.err conftest.$ac_objext \
14863       conftest$ac_exeext conftest.$ac_ext
14864 LIBS=$ac_check_lib_save_LIBS
14865 fi
14866 echo "$as_me:$LINENO: result: $ac_cv_lib_net_main" >&5
14867 echo "${ECHO_T}$ac_cv_lib_net_main" >&6
14868 if test $ac_cv_lib_net_main = yes; then
14869   cat >>confdefs.h <<_ACEOF
14870 #define HAVE_LIBNET 1
14871 _ACEOF
14872
14873   LIBS="-lnet $LIBS"
14874
14875 fi
14876
14877
14878 echo "$as_me:$LINENO: checking for main in -lnsl_s" >&5
14879 echo $ECHO_N "checking for main in -lnsl_s... $ECHO_C" >&6
14880 if test "${ac_cv_lib_nsl_s_main+set}" = set; then
14881   echo $ECHO_N "(cached) $ECHO_C" >&6
14882 else
14883   ac_check_lib_save_LIBS=$LIBS
14884 LIBS="-lnsl_s  $LIBS"
14885 cat >conftest.$ac_ext <<_ACEOF
14886 /* confdefs.h.  */
14887 _ACEOF
14888 cat confdefs.h >>conftest.$ac_ext
14889 cat >>conftest.$ac_ext <<_ACEOF
14890 /* end confdefs.h.  */
14891
14892
14893 int
14894 main ()
14895 {
14896 main ();
14897   ;
14898   return 0;
14899 }
14900 _ACEOF
14901 rm -f conftest.$ac_objext conftest$ac_exeext
14902 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14903   (eval $ac_link) 2>conftest.er1
14904   ac_status=$?
14905   grep -v '^ *+' conftest.er1 >conftest.err
14906   rm -f conftest.er1
14907   cat conftest.err >&5
14908   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14909   (exit $ac_status); } &&
14910          { ac_try='test -z "$ac_c_werror_flag"
14911                          || test ! -s conftest.err'
14912   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14913   (eval $ac_try) 2>&5
14914   ac_status=$?
14915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14916   (exit $ac_status); }; } &&
14917          { ac_try='test -s conftest$ac_exeext'
14918   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14919   (eval $ac_try) 2>&5
14920   ac_status=$?
14921   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14922   (exit $ac_status); }; }; then
14923   ac_cv_lib_nsl_s_main=yes
14924 else
14925   echo "$as_me: failed program was:" >&5
14926 sed 's/^/| /' conftest.$ac_ext >&5
14927
14928 ac_cv_lib_nsl_s_main=no
14929 fi
14930 rm -f conftest.err conftest.$ac_objext \
14931       conftest$ac_exeext conftest.$ac_ext
14932 LIBS=$ac_check_lib_save_LIBS
14933 fi
14934 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_s_main" >&5
14935 echo "${ECHO_T}$ac_cv_lib_nsl_s_main" >&6
14936 if test $ac_cv_lib_nsl_s_main = yes; then
14937   cat >>confdefs.h <<_ACEOF
14938 #define HAVE_LIBNSL_S 1
14939 _ACEOF
14940
14941   LIBS="-lnsl_s $LIBS"
14942
14943 fi
14944
14945
14946 echo "$as_me:$LINENO: checking for main in -lnsl" >&5
14947 echo $ECHO_N "checking for main in -lnsl... $ECHO_C" >&6
14948 if test "${ac_cv_lib_nsl_main+set}" = set; then
14949   echo $ECHO_N "(cached) $ECHO_C" >&6
14950 else
14951   ac_check_lib_save_LIBS=$LIBS
14952 LIBS="-lnsl  $LIBS"
14953 cat >conftest.$ac_ext <<_ACEOF
14954 /* confdefs.h.  */
14955 _ACEOF
14956 cat confdefs.h >>conftest.$ac_ext
14957 cat >>conftest.$ac_ext <<_ACEOF
14958 /* end confdefs.h.  */
14959
14960
14961 int
14962 main ()
14963 {
14964 main ();
14965   ;
14966   return 0;
14967 }
14968 _ACEOF
14969 rm -f conftest.$ac_objext conftest$ac_exeext
14970 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14971   (eval $ac_link) 2>conftest.er1
14972   ac_status=$?
14973   grep -v '^ *+' conftest.er1 >conftest.err
14974   rm -f conftest.er1
14975   cat conftest.err >&5
14976   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14977   (exit $ac_status); } &&
14978          { ac_try='test -z "$ac_c_werror_flag"
14979                          || test ! -s conftest.err'
14980   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14981   (eval $ac_try) 2>&5
14982   ac_status=$?
14983   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14984   (exit $ac_status); }; } &&
14985          { ac_try='test -s conftest$ac_exeext'
14986   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14987   (eval $ac_try) 2>&5
14988   ac_status=$?
14989   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14990   (exit $ac_status); }; }; then
14991   ac_cv_lib_nsl_main=yes
14992 else
14993   echo "$as_me: failed program was:" >&5
14994 sed 's/^/| /' conftest.$ac_ext >&5
14995
14996 ac_cv_lib_nsl_main=no
14997 fi
14998 rm -f conftest.err conftest.$ac_objext \
14999       conftest$ac_exeext conftest.$ac_ext
15000 LIBS=$ac_check_lib_save_LIBS
15001 fi
15002 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_main" >&5
15003 echo "${ECHO_T}$ac_cv_lib_nsl_main" >&6
15004 if test $ac_cv_lib_nsl_main = yes; then
15005   cat >>confdefs.h <<_ACEOF
15006 #define HAVE_LIBNSL 1
15007 _ACEOF
15008
15009   LIBS="-lnsl $LIBS"
15010
15011 fi
15012
15013
15014 echo "$as_me:$LINENO: checking for socket in -linet" >&5
15015 echo $ECHO_N "checking for socket in -linet... $ECHO_C" >&6
15016 if test "${ac_cv_lib_inet_socket+set}" = set; then
15017   echo $ECHO_N "(cached) $ECHO_C" >&6
15018 else
15019   ac_check_lib_save_LIBS=$LIBS
15020 LIBS="-linet  $LIBS"
15021 cat >conftest.$ac_ext <<_ACEOF
15022 /* confdefs.h.  */
15023 _ACEOF
15024 cat confdefs.h >>conftest.$ac_ext
15025 cat >>conftest.$ac_ext <<_ACEOF
15026 /* end confdefs.h.  */
15027
15028 /* Override any gcc2 internal prototype to avoid an error.  */
15029 #ifdef __cplusplus
15030 extern "C"
15031 #endif
15032 /* We use char because int might match the return type of a gcc2
15033    builtin and then its argument prototype would still apply.  */
15034 char socket ();
15035 int
15036 main ()
15037 {
15038 socket ();
15039   ;
15040   return 0;
15041 }
15042 _ACEOF
15043 rm -f conftest.$ac_objext conftest$ac_exeext
15044 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15045   (eval $ac_link) 2>conftest.er1
15046   ac_status=$?
15047   grep -v '^ *+' conftest.er1 >conftest.err
15048   rm -f conftest.er1
15049   cat conftest.err >&5
15050   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15051   (exit $ac_status); } &&
15052          { ac_try='test -z "$ac_c_werror_flag"
15053                          || test ! -s conftest.err'
15054   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15055   (eval $ac_try) 2>&5
15056   ac_status=$?
15057   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15058   (exit $ac_status); }; } &&
15059          { ac_try='test -s conftest$ac_exeext'
15060   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15061   (eval $ac_try) 2>&5
15062   ac_status=$?
15063   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15064   (exit $ac_status); }; }; then
15065   ac_cv_lib_inet_socket=yes
15066 else
15067   echo "$as_me: failed program was:" >&5
15068 sed 's/^/| /' conftest.$ac_ext >&5
15069
15070 ac_cv_lib_inet_socket=no
15071 fi
15072 rm -f conftest.err conftest.$ac_objext \
15073       conftest$ac_exeext conftest.$ac_ext
15074 LIBS=$ac_check_lib_save_LIBS
15075 fi
15076 echo "$as_me:$LINENO: result: $ac_cv_lib_inet_socket" >&5
15077 echo "${ECHO_T}$ac_cv_lib_inet_socket" >&6
15078 if test $ac_cv_lib_inet_socket = yes; then
15079   cat >>confdefs.h <<_ACEOF
15080 #define HAVE_LIBINET 1
15081 _ACEOF
15082
15083   LIBS="-linet $LIBS"
15084
15085 fi
15086
15087
15088 echo "$as_me:$LINENO: checking for main in -lgen" >&5
15089 echo $ECHO_N "checking for main in -lgen... $ECHO_C" >&6
15090 if test "${ac_cv_lib_gen_main+set}" = set; then
15091   echo $ECHO_N "(cached) $ECHO_C" >&6
15092 else
15093   ac_check_lib_save_LIBS=$LIBS
15094 LIBS="-lgen  $LIBS"
15095 cat >conftest.$ac_ext <<_ACEOF
15096 /* confdefs.h.  */
15097 _ACEOF
15098 cat confdefs.h >>conftest.$ac_ext
15099 cat >>conftest.$ac_ext <<_ACEOF
15100 /* end confdefs.h.  */
15101
15102
15103 int
15104 main ()
15105 {
15106 main ();
15107   ;
15108   return 0;
15109 }
15110 _ACEOF
15111 rm -f conftest.$ac_objext conftest$ac_exeext
15112 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15113   (eval $ac_link) 2>conftest.er1
15114   ac_status=$?
15115   grep -v '^ *+' conftest.er1 >conftest.err
15116   rm -f conftest.er1
15117   cat conftest.err >&5
15118   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15119   (exit $ac_status); } &&
15120          { ac_try='test -z "$ac_c_werror_flag"
15121                          || test ! -s conftest.err'
15122   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15123   (eval $ac_try) 2>&5
15124   ac_status=$?
15125   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15126   (exit $ac_status); }; } &&
15127          { ac_try='test -s conftest$ac_exeext'
15128   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15129   (eval $ac_try) 2>&5
15130   ac_status=$?
15131   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15132   (exit $ac_status); }; }; then
15133   ac_cv_lib_gen_main=yes
15134 else
15135   echo "$as_me: failed program was:" >&5
15136 sed 's/^/| /' conftest.$ac_ext >&5
15137
15138 ac_cv_lib_gen_main=no
15139 fi
15140 rm -f conftest.err conftest.$ac_objext \
15141       conftest$ac_exeext conftest.$ac_ext
15142 LIBS=$ac_check_lib_save_LIBS
15143 fi
15144 echo "$as_me:$LINENO: result: $ac_cv_lib_gen_main" >&5
15145 echo "${ECHO_T}$ac_cv_lib_gen_main" >&6
15146 if test $ac_cv_lib_gen_main = yes; then
15147   cat >>confdefs.h <<_ACEOF
15148 #define HAVE_LIBGEN 1
15149 _ACEOF
15150
15151   LIBS="-lgen $LIBS"
15152
15153 fi
15154
15155
15156 fi
15157
15158
15159 echo "$as_me:$LINENO: checking for select" >&5
15160 echo $ECHO_N "checking for select... $ECHO_C" >&6
15161 if test "${ac_cv_func_select+set}" = set; then
15162   echo $ECHO_N "(cached) $ECHO_C" >&6
15163 else
15164   cat >conftest.$ac_ext <<_ACEOF
15165 /* confdefs.h.  */
15166 _ACEOF
15167 cat confdefs.h >>conftest.$ac_ext
15168 cat >>conftest.$ac_ext <<_ACEOF
15169 /* end confdefs.h.  */
15170 /* Define select to an innocuous variant, in case <limits.h> declares select.
15171    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15172 #define select innocuous_select
15173
15174 /* System header to define __stub macros and hopefully few prototypes,
15175     which can conflict with char select (); below.
15176     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15177     <limits.h> exists even on freestanding compilers.  */
15178
15179 #ifdef __STDC__
15180 # include <limits.h>
15181 #else
15182 # include <assert.h>
15183 #endif
15184
15185 #undef select
15186
15187 /* Override any gcc2 internal prototype to avoid an error.  */
15188 #ifdef __cplusplus
15189 extern "C"
15190 {
15191 #endif
15192 /* We use char because int might match the return type of a gcc2
15193    builtin and then its argument prototype would still apply.  */
15194 char select ();
15195 /* The GNU C library defines this for functions which it implements
15196     to always fail with ENOSYS.  Some functions are actually named
15197     something starting with __ and the normal name is an alias.  */
15198 #if defined (__stub_select) || defined (__stub___select)
15199 choke me
15200 #else
15201 char (*f) () = select;
15202 #endif
15203 #ifdef __cplusplus
15204 }
15205 #endif
15206
15207 int
15208 main ()
15209 {
15210 return f != select;
15211   ;
15212   return 0;
15213 }
15214 _ACEOF
15215 rm -f conftest.$ac_objext conftest$ac_exeext
15216 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15217   (eval $ac_link) 2>conftest.er1
15218   ac_status=$?
15219   grep -v '^ *+' conftest.er1 >conftest.err
15220   rm -f conftest.er1
15221   cat conftest.err >&5
15222   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15223   (exit $ac_status); } &&
15224          { ac_try='test -z "$ac_c_werror_flag"
15225                          || test ! -s conftest.err'
15226   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15227   (eval $ac_try) 2>&5
15228   ac_status=$?
15229   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15230   (exit $ac_status); }; } &&
15231          { ac_try='test -s conftest$ac_exeext'
15232   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15233   (eval $ac_try) 2>&5
15234   ac_status=$?
15235   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15236   (exit $ac_status); }; }; then
15237   ac_cv_func_select=yes
15238 else
15239   echo "$as_me: failed program was:" >&5
15240 sed 's/^/| /' conftest.$ac_ext >&5
15241
15242 ac_cv_func_select=no
15243 fi
15244 rm -f conftest.err conftest.$ac_objext \
15245       conftest$ac_exeext conftest.$ac_ext
15246 fi
15247 echo "$as_me:$LINENO: result: $ac_cv_func_select" >&5
15248 echo "${ECHO_T}$ac_cv_func_select" >&6
15249 if test $ac_cv_func_select = yes; then
15250   :
15251 else
15252   { { echo "$as_me:$LINENO: error: select() required." >&5
15253 echo "$as_me: error: select() required." >&2;}
15254    { (exit 1); exit 1; }; }
15255 fi
15256
15257
15258 if test "${ac_cv_header_winsock_h}" != yes; then
15259
15260
15261 for ac_header in sys/select.h sys/socket.h
15262 do
15263 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15264 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15265   echo "$as_me:$LINENO: checking for $ac_header" >&5
15266 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15267 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15268   echo $ECHO_N "(cached) $ECHO_C" >&6
15269 fi
15270 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15271 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15272 else
15273   # Is the header compilable?
15274 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15275 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15276 cat >conftest.$ac_ext <<_ACEOF
15277 /* confdefs.h.  */
15278 _ACEOF
15279 cat confdefs.h >>conftest.$ac_ext
15280 cat >>conftest.$ac_ext <<_ACEOF
15281 /* end confdefs.h.  */
15282 $ac_includes_default
15283 #include <$ac_header>
15284 _ACEOF
15285 rm -f conftest.$ac_objext
15286 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15287   (eval $ac_compile) 2>conftest.er1
15288   ac_status=$?
15289   grep -v '^ *+' conftest.er1 >conftest.err
15290   rm -f conftest.er1
15291   cat conftest.err >&5
15292   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15293   (exit $ac_status); } &&
15294          { ac_try='test -z "$ac_c_werror_flag"
15295                          || test ! -s conftest.err'
15296   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15297   (eval $ac_try) 2>&5
15298   ac_status=$?
15299   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15300   (exit $ac_status); }; } &&
15301          { ac_try='test -s conftest.$ac_objext'
15302   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15303   (eval $ac_try) 2>&5
15304   ac_status=$?
15305   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15306   (exit $ac_status); }; }; then
15307   ac_header_compiler=yes
15308 else
15309   echo "$as_me: failed program was:" >&5
15310 sed 's/^/| /' conftest.$ac_ext >&5
15311
15312 ac_header_compiler=no
15313 fi
15314 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15315 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15316 echo "${ECHO_T}$ac_header_compiler" >&6
15317
15318 # Is the header present?
15319 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15320 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15321 cat >conftest.$ac_ext <<_ACEOF
15322 /* confdefs.h.  */
15323 _ACEOF
15324 cat confdefs.h >>conftest.$ac_ext
15325 cat >>conftest.$ac_ext <<_ACEOF
15326 /* end confdefs.h.  */
15327 #include <$ac_header>
15328 _ACEOF
15329 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15330   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15331   ac_status=$?
15332   grep -v '^ *+' conftest.er1 >conftest.err
15333   rm -f conftest.er1
15334   cat conftest.err >&5
15335   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15336   (exit $ac_status); } >/dev/null; then
15337   if test -s conftest.err; then
15338     ac_cpp_err=$ac_c_preproc_warn_flag
15339     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15340   else
15341     ac_cpp_err=
15342   fi
15343 else
15344   ac_cpp_err=yes
15345 fi
15346 if test -z "$ac_cpp_err"; then
15347   ac_header_preproc=yes
15348 else
15349   echo "$as_me: failed program was:" >&5
15350 sed 's/^/| /' conftest.$ac_ext >&5
15351
15352   ac_header_preproc=no
15353 fi
15354 rm -f conftest.err conftest.$ac_ext
15355 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15356 echo "${ECHO_T}$ac_header_preproc" >&6
15357
15358 # So?  What about this header?
15359 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15360   yes:no: )
15361     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15362 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15363     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15364 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15365     ac_header_preproc=yes
15366     ;;
15367   no:yes:* )
15368     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15369 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15370     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15371 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15372     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15373 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15374     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15375 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15376     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15377 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15378     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15379 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15380     (
15381       cat <<\_ASBOX
15382 ## --------------------------------------------- ##
15383 ## Report this to <http://www.openldap.org/its/> ##
15384 ## --------------------------------------------- ##
15385 _ASBOX
15386     ) |
15387       sed "s/^/$as_me: WARNING:     /" >&2
15388     ;;
15389 esac
15390 echo "$as_me:$LINENO: checking for $ac_header" >&5
15391 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15392 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15393   echo $ECHO_N "(cached) $ECHO_C" >&6
15394 else
15395   eval "$as_ac_Header=\$ac_header_preproc"
15396 fi
15397 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15398 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15399
15400 fi
15401 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15402   cat >>confdefs.h <<_ACEOF
15403 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15404 _ACEOF
15405
15406 fi
15407
15408 done
15409
15410 echo "$as_me:$LINENO: checking types of arguments for select" >&5
15411 echo $ECHO_N "checking types of arguments for select... $ECHO_C" >&6
15412 if test "${ac_cv_func_select_args+set}" = set; then
15413   echo $ECHO_N "(cached) $ECHO_C" >&6
15414 else
15415   for ac_arg234 in 'fd_set *' 'int *' 'void *'; do
15416  for ac_arg1 in 'int' 'size_t' 'unsigned long' 'unsigned'; do
15417   for ac_arg5 in 'struct timeval *' 'const struct timeval *'; do
15418    cat >conftest.$ac_ext <<_ACEOF
15419 /* confdefs.h.  */
15420 _ACEOF
15421 cat confdefs.h >>conftest.$ac_ext
15422 cat >>conftest.$ac_ext <<_ACEOF
15423 /* end confdefs.h.  */
15424 $ac_includes_default
15425 #if HAVE_SYS_SELECT_H
15426 # include <sys/select.h>
15427 #endif
15428 #if HAVE_SYS_SOCKET_H
15429 # include <sys/socket.h>
15430 #endif
15431
15432 int
15433 main ()
15434 {
15435 extern int select ($ac_arg1,
15436                                             $ac_arg234, $ac_arg234, $ac_arg234,
15437                                             $ac_arg5);
15438   ;
15439   return 0;
15440 }
15441 _ACEOF
15442 rm -f conftest.$ac_objext
15443 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15444   (eval $ac_compile) 2>conftest.er1
15445   ac_status=$?
15446   grep -v '^ *+' conftest.er1 >conftest.err
15447   rm -f conftest.er1
15448   cat conftest.err >&5
15449   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15450   (exit $ac_status); } &&
15451          { ac_try='test -z "$ac_c_werror_flag"
15452                          || test ! -s conftest.err'
15453   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15454   (eval $ac_try) 2>&5
15455   ac_status=$?
15456   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15457   (exit $ac_status); }; } &&
15458          { ac_try='test -s conftest.$ac_objext'
15459   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15460   (eval $ac_try) 2>&5
15461   ac_status=$?
15462   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15463   (exit $ac_status); }; }; then
15464   ac_cv_func_select_args="$ac_arg1,$ac_arg234,$ac_arg5"; break 3
15465 else
15466   echo "$as_me: failed program was:" >&5
15467 sed 's/^/| /' conftest.$ac_ext >&5
15468
15469 fi
15470 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15471   done
15472  done
15473 done
15474 # Provide a safe default value.
15475 : ${ac_cv_func_select_args='int,int *,struct timeval *'}
15476
15477 fi
15478 echo "$as_me:$LINENO: result: $ac_cv_func_select_args" >&5
15479 echo "${ECHO_T}$ac_cv_func_select_args" >&6
15480 ac_save_IFS=$IFS; IFS=','
15481 set dummy `echo "$ac_cv_func_select_args" | sed 's/\*/\*/g'`
15482 IFS=$ac_save_IFS
15483 shift
15484
15485 cat >>confdefs.h <<_ACEOF
15486 #define SELECT_TYPE_ARG1 $1
15487 _ACEOF
15488
15489
15490 cat >>confdefs.h <<_ACEOF
15491 #define SELECT_TYPE_ARG234 ($2)
15492 _ACEOF
15493
15494
15495 cat >>confdefs.h <<_ACEOF
15496 #define SELECT_TYPE_ARG5 ($3)
15497 _ACEOF
15498
15499 rm -f conftest*
15500
15501 fi
15502
15503
15504
15505 for ac_func in poll
15506 do
15507 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15508 echo "$as_me:$LINENO: checking for $ac_func" >&5
15509 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15510 if eval "test \"\${$as_ac_var+set}\" = set"; then
15511   echo $ECHO_N "(cached) $ECHO_C" >&6
15512 else
15513   cat >conftest.$ac_ext <<_ACEOF
15514 /* confdefs.h.  */
15515 _ACEOF
15516 cat confdefs.h >>conftest.$ac_ext
15517 cat >>conftest.$ac_ext <<_ACEOF
15518 /* end confdefs.h.  */
15519 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15520    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15521 #define $ac_func innocuous_$ac_func
15522
15523 /* System header to define __stub macros and hopefully few prototypes,
15524     which can conflict with char $ac_func (); below.
15525     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15526     <limits.h> exists even on freestanding compilers.  */
15527
15528 #ifdef __STDC__
15529 # include <limits.h>
15530 #else
15531 # include <assert.h>
15532 #endif
15533
15534 #undef $ac_func
15535
15536 /* Override any gcc2 internal prototype to avoid an error.  */
15537 #ifdef __cplusplus
15538 extern "C"
15539 {
15540 #endif
15541 /* We use char because int might match the return type of a gcc2
15542    builtin and then its argument prototype would still apply.  */
15543 char $ac_func ();
15544 /* The GNU C library defines this for functions which it implements
15545     to always fail with ENOSYS.  Some functions are actually named
15546     something starting with __ and the normal name is an alias.  */
15547 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15548 choke me
15549 #else
15550 char (*f) () = $ac_func;
15551 #endif
15552 #ifdef __cplusplus
15553 }
15554 #endif
15555
15556 int
15557 main ()
15558 {
15559 return f != $ac_func;
15560   ;
15561   return 0;
15562 }
15563 _ACEOF
15564 rm -f conftest.$ac_objext conftest$ac_exeext
15565 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15566   (eval $ac_link) 2>conftest.er1
15567   ac_status=$?
15568   grep -v '^ *+' conftest.er1 >conftest.err
15569   rm -f conftest.er1
15570   cat conftest.err >&5
15571   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15572   (exit $ac_status); } &&
15573          { ac_try='test -z "$ac_c_werror_flag"
15574                          || test ! -s conftest.err'
15575   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15576   (eval $ac_try) 2>&5
15577   ac_status=$?
15578   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15579   (exit $ac_status); }; } &&
15580          { ac_try='test -s conftest$ac_exeext'
15581   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15582   (eval $ac_try) 2>&5
15583   ac_status=$?
15584   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15585   (exit $ac_status); }; }; then
15586   eval "$as_ac_var=yes"
15587 else
15588   echo "$as_me: failed program was:" >&5
15589 sed 's/^/| /' conftest.$ac_ext >&5
15590
15591 eval "$as_ac_var=no"
15592 fi
15593 rm -f conftest.err conftest.$ac_objext \
15594       conftest$ac_exeext conftest.$ac_ext
15595 fi
15596 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15597 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15598 if test `eval echo '${'$as_ac_var'}'` = yes; then
15599   cat >>confdefs.h <<_ACEOF
15600 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15601 _ACEOF
15602
15603 fi
15604 done
15605
15606 if test $ac_cv_func_poll = yes; then
15607
15608
15609 for ac_header in poll.h sys/poll.h
15610 do
15611 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15612 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15613   echo "$as_me:$LINENO: checking for $ac_header" >&5
15614 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15615 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15616   echo $ECHO_N "(cached) $ECHO_C" >&6
15617 fi
15618 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15619 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15620 else
15621   # Is the header compilable?
15622 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15623 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15624 cat >conftest.$ac_ext <<_ACEOF
15625 /* confdefs.h.  */
15626 _ACEOF
15627 cat confdefs.h >>conftest.$ac_ext
15628 cat >>conftest.$ac_ext <<_ACEOF
15629 /* end confdefs.h.  */
15630 $ac_includes_default
15631 #include <$ac_header>
15632 _ACEOF
15633 rm -f conftest.$ac_objext
15634 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15635   (eval $ac_compile) 2>conftest.er1
15636   ac_status=$?
15637   grep -v '^ *+' conftest.er1 >conftest.err
15638   rm -f conftest.er1
15639   cat conftest.err >&5
15640   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15641   (exit $ac_status); } &&
15642          { ac_try='test -z "$ac_c_werror_flag"
15643                          || test ! -s conftest.err'
15644   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15645   (eval $ac_try) 2>&5
15646   ac_status=$?
15647   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15648   (exit $ac_status); }; } &&
15649          { ac_try='test -s conftest.$ac_objext'
15650   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15651   (eval $ac_try) 2>&5
15652   ac_status=$?
15653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15654   (exit $ac_status); }; }; then
15655   ac_header_compiler=yes
15656 else
15657   echo "$as_me: failed program was:" >&5
15658 sed 's/^/| /' conftest.$ac_ext >&5
15659
15660 ac_header_compiler=no
15661 fi
15662 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15663 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15664 echo "${ECHO_T}$ac_header_compiler" >&6
15665
15666 # Is the header present?
15667 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15668 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15669 cat >conftest.$ac_ext <<_ACEOF
15670 /* confdefs.h.  */
15671 _ACEOF
15672 cat confdefs.h >>conftest.$ac_ext
15673 cat >>conftest.$ac_ext <<_ACEOF
15674 /* end confdefs.h.  */
15675 #include <$ac_header>
15676 _ACEOF
15677 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15678   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15679   ac_status=$?
15680   grep -v '^ *+' conftest.er1 >conftest.err
15681   rm -f conftest.er1
15682   cat conftest.err >&5
15683   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15684   (exit $ac_status); } >/dev/null; then
15685   if test -s conftest.err; then
15686     ac_cpp_err=$ac_c_preproc_warn_flag
15687     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15688   else
15689     ac_cpp_err=
15690   fi
15691 else
15692   ac_cpp_err=yes
15693 fi
15694 if test -z "$ac_cpp_err"; then
15695   ac_header_preproc=yes
15696 else
15697   echo "$as_me: failed program was:" >&5
15698 sed 's/^/| /' conftest.$ac_ext >&5
15699
15700   ac_header_preproc=no
15701 fi
15702 rm -f conftest.err conftest.$ac_ext
15703 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15704 echo "${ECHO_T}$ac_header_preproc" >&6
15705
15706 # So?  What about this header?
15707 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15708   yes:no: )
15709     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15710 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15711     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15712 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15713     ac_header_preproc=yes
15714     ;;
15715   no:yes:* )
15716     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15717 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15718     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15719 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15720     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15721 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15722     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15723 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15724     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15725 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15726     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15727 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15728     (
15729       cat <<\_ASBOX
15730 ## --------------------------------------------- ##
15731 ## Report this to <http://www.openldap.org/its/> ##
15732 ## --------------------------------------------- ##
15733 _ASBOX
15734     ) |
15735       sed "s/^/$as_me: WARNING:     /" >&2
15736     ;;
15737 esac
15738 echo "$as_me:$LINENO: checking for $ac_header" >&5
15739 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15740 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15741   echo $ECHO_N "(cached) $ECHO_C" >&6
15742 else
15743   eval "$as_ac_Header=\$ac_header_preproc"
15744 fi
15745 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15746 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15747
15748 fi
15749 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15750   cat >>confdefs.h <<_ACEOF
15751 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15752 _ACEOF
15753
15754 fi
15755
15756 done
15757
15758 fi
15759
15760
15761 for ac_header in sys/epoll.h
15762 do
15763 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15764 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15765   echo "$as_me:$LINENO: checking for $ac_header" >&5
15766 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15767 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15768   echo $ECHO_N "(cached) $ECHO_C" >&6
15769 fi
15770 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15771 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15772 else
15773   # Is the header compilable?
15774 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15775 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15776 cat >conftest.$ac_ext <<_ACEOF
15777 /* confdefs.h.  */
15778 _ACEOF
15779 cat confdefs.h >>conftest.$ac_ext
15780 cat >>conftest.$ac_ext <<_ACEOF
15781 /* end confdefs.h.  */
15782 $ac_includes_default
15783 #include <$ac_header>
15784 _ACEOF
15785 rm -f conftest.$ac_objext
15786 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15787   (eval $ac_compile) 2>conftest.er1
15788   ac_status=$?
15789   grep -v '^ *+' conftest.er1 >conftest.err
15790   rm -f conftest.er1
15791   cat conftest.err >&5
15792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15793   (exit $ac_status); } &&
15794          { ac_try='test -z "$ac_c_werror_flag"
15795                          || test ! -s conftest.err'
15796   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15797   (eval $ac_try) 2>&5
15798   ac_status=$?
15799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15800   (exit $ac_status); }; } &&
15801          { ac_try='test -s conftest.$ac_objext'
15802   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15803   (eval $ac_try) 2>&5
15804   ac_status=$?
15805   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15806   (exit $ac_status); }; }; then
15807   ac_header_compiler=yes
15808 else
15809   echo "$as_me: failed program was:" >&5
15810 sed 's/^/| /' conftest.$ac_ext >&5
15811
15812 ac_header_compiler=no
15813 fi
15814 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15815 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15816 echo "${ECHO_T}$ac_header_compiler" >&6
15817
15818 # Is the header present?
15819 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15820 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15821 cat >conftest.$ac_ext <<_ACEOF
15822 /* confdefs.h.  */
15823 _ACEOF
15824 cat confdefs.h >>conftest.$ac_ext
15825 cat >>conftest.$ac_ext <<_ACEOF
15826 /* end confdefs.h.  */
15827 #include <$ac_header>
15828 _ACEOF
15829 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15830   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15831   ac_status=$?
15832   grep -v '^ *+' conftest.er1 >conftest.err
15833   rm -f conftest.er1
15834   cat conftest.err >&5
15835   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15836   (exit $ac_status); } >/dev/null; then
15837   if test -s conftest.err; then
15838     ac_cpp_err=$ac_c_preproc_warn_flag
15839     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15840   else
15841     ac_cpp_err=
15842   fi
15843 else
15844   ac_cpp_err=yes
15845 fi
15846 if test -z "$ac_cpp_err"; then
15847   ac_header_preproc=yes
15848 else
15849   echo "$as_me: failed program was:" >&5
15850 sed 's/^/| /' conftest.$ac_ext >&5
15851
15852   ac_header_preproc=no
15853 fi
15854 rm -f conftest.err conftest.$ac_ext
15855 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15856 echo "${ECHO_T}$ac_header_preproc" >&6
15857
15858 # So?  What about this header?
15859 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15860   yes:no: )
15861     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15862 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15863     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15864 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15865     ac_header_preproc=yes
15866     ;;
15867   no:yes:* )
15868     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15869 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15870     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15871 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15872     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15873 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15874     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15875 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15876     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15877 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15878     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15879 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15880     (
15881       cat <<\_ASBOX
15882 ## --------------------------------------------- ##
15883 ## Report this to <http://www.openldap.org/its/> ##
15884 ## --------------------------------------------- ##
15885 _ASBOX
15886     ) |
15887       sed "s/^/$as_me: WARNING:     /" >&2
15888     ;;
15889 esac
15890 echo "$as_me:$LINENO: checking for $ac_header" >&5
15891 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15892 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15893   echo $ECHO_N "(cached) $ECHO_C" >&6
15894 else
15895   eval "$as_ac_Header=\$ac_header_preproc"
15896 fi
15897 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15898 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15899
15900 fi
15901 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15902   cat >>confdefs.h <<_ACEOF
15903 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15904 _ACEOF
15905
15906 fi
15907
15908 done
15909
15910 if test "${ac_cv_header_sys_epoll_h}" = yes; then
15911         echo "$as_me:$LINENO: checking for epoll system call" >&5
15912 echo $ECHO_N "checking for epoll system call... $ECHO_C" >&6
15913         if test "$cross_compiling" = yes; then
15914   echo "$as_me:$LINENO: result: no" >&5
15915 echo "${ECHO_T}no" >&6
15916 else
15917   cat >conftest.$ac_ext <<_ACEOF
15918 /* confdefs.h.  */
15919 _ACEOF
15920 cat confdefs.h >>conftest.$ac_ext
15921 cat >>conftest.$ac_ext <<_ACEOF
15922 /* end confdefs.h.  */
15923 int main(int argc, char **argv)
15924 {
15925         int epfd = epoll_create(256);
15926         exit (epfd == -1 ? 1 : 0);
15927 }
15928 _ACEOF
15929 rm -f conftest$ac_exeext
15930 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15931   (eval $ac_link) 2>&5
15932   ac_status=$?
15933   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15934   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15935   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15936   (eval $ac_try) 2>&5
15937   ac_status=$?
15938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15939   (exit $ac_status); }; }; then
15940   echo "$as_me:$LINENO: result: yes" >&5
15941 echo "${ECHO_T}yes" >&6
15942
15943 cat >>confdefs.h <<\_ACEOF
15944 #define HAVE_EPOLL 1
15945 _ACEOF
15946
15947 else
15948   echo "$as_me: program exited with status $ac_status" >&5
15949 echo "$as_me: failed program was:" >&5
15950 sed 's/^/| /' conftest.$ac_ext >&5
15951
15952 ( exit $ac_status )
15953 echo "$as_me:$LINENO: result: no" >&5
15954 echo "${ECHO_T}no" >&6
15955 fi
15956 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15957 fi
15958 fi
15959
15960
15961 for ac_header in sys/devpoll.h
15962 do
15963 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15964 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15965   echo "$as_me:$LINENO: checking for $ac_header" >&5
15966 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15967 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15968   echo $ECHO_N "(cached) $ECHO_C" >&6
15969 fi
15970 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15971 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15972 else
15973   # Is the header compilable?
15974 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15975 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15976 cat >conftest.$ac_ext <<_ACEOF
15977 /* confdefs.h.  */
15978 _ACEOF
15979 cat confdefs.h >>conftest.$ac_ext
15980 cat >>conftest.$ac_ext <<_ACEOF
15981 /* end confdefs.h.  */
15982 $ac_includes_default
15983 #include <$ac_header>
15984 _ACEOF
15985 rm -f conftest.$ac_objext
15986 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15987   (eval $ac_compile) 2>conftest.er1
15988   ac_status=$?
15989   grep -v '^ *+' conftest.er1 >conftest.err
15990   rm -f conftest.er1
15991   cat conftest.err >&5
15992   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15993   (exit $ac_status); } &&
15994          { ac_try='test -z "$ac_c_werror_flag"
15995                          || test ! -s conftest.err'
15996   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15997   (eval $ac_try) 2>&5
15998   ac_status=$?
15999   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16000   (exit $ac_status); }; } &&
16001          { ac_try='test -s conftest.$ac_objext'
16002   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16003   (eval $ac_try) 2>&5
16004   ac_status=$?
16005   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16006   (exit $ac_status); }; }; then
16007   ac_header_compiler=yes
16008 else
16009   echo "$as_me: failed program was:" >&5
16010 sed 's/^/| /' conftest.$ac_ext >&5
16011
16012 ac_header_compiler=no
16013 fi
16014 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16015 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16016 echo "${ECHO_T}$ac_header_compiler" >&6
16017
16018 # Is the header present?
16019 echo "$as_me:$LINENO: checking $ac_header presence" >&5
16020 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
16021 cat >conftest.$ac_ext <<_ACEOF
16022 /* confdefs.h.  */
16023 _ACEOF
16024 cat confdefs.h >>conftest.$ac_ext
16025 cat >>conftest.$ac_ext <<_ACEOF
16026 /* end confdefs.h.  */
16027 #include <$ac_header>
16028 _ACEOF
16029 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
16030   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16031   ac_status=$?
16032   grep -v '^ *+' conftest.er1 >conftest.err
16033   rm -f conftest.er1
16034   cat conftest.err >&5
16035   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16036   (exit $ac_status); } >/dev/null; then
16037   if test -s conftest.err; then
16038     ac_cpp_err=$ac_c_preproc_warn_flag
16039     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
16040   else
16041     ac_cpp_err=
16042   fi
16043 else
16044   ac_cpp_err=yes
16045 fi
16046 if test -z "$ac_cpp_err"; then
16047   ac_header_preproc=yes
16048 else
16049   echo "$as_me: failed program was:" >&5
16050 sed 's/^/| /' conftest.$ac_ext >&5
16051
16052   ac_header_preproc=no
16053 fi
16054 rm -f conftest.err conftest.$ac_ext
16055 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16056 echo "${ECHO_T}$ac_header_preproc" >&6
16057
16058 # So?  What about this header?
16059 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16060   yes:no: )
16061     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
16062 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
16063     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
16064 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
16065     ac_header_preproc=yes
16066     ;;
16067   no:yes:* )
16068     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
16069 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
16070     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
16071 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
16072     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
16073 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
16074     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
16075 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
16076     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
16077 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16078     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
16079 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
16080     (
16081       cat <<\_ASBOX
16082 ## --------------------------------------------- ##
16083 ## Report this to <http://www.openldap.org/its/> ##
16084 ## --------------------------------------------- ##
16085 _ASBOX
16086     ) |
16087       sed "s/^/$as_me: WARNING:     /" >&2
16088     ;;
16089 esac
16090 echo "$as_me:$LINENO: checking for $ac_header" >&5
16091 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16092 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16093   echo $ECHO_N "(cached) $ECHO_C" >&6
16094 else
16095   eval "$as_ac_Header=\$ac_header_preproc"
16096 fi
16097 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16098 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16099
16100 fi
16101 if test `eval echo '${'$as_ac_Header'}'` = yes; then
16102   cat >>confdefs.h <<_ACEOF
16103 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16104 _ACEOF
16105
16106 fi
16107
16108 done
16109
16110 if test "${ac_cv_header_sys_devpoll_h}" = yes \
16111                 -a "${ac_cv_header_poll_h}" = yes ; \
16112 then
16113         echo "$as_me:$LINENO: checking for /dev/poll" >&5
16114 echo $ECHO_N "checking for /dev/poll... $ECHO_C" >&6
16115         if test "$cross_compiling" = yes; then
16116   echo "$as_me:$LINENO: result: no" >&5
16117 echo "${ECHO_T}no" >&6
16118 else
16119   cat >conftest.$ac_ext <<_ACEOF
16120 /* confdefs.h.  */
16121 _ACEOF
16122 cat confdefs.h >>conftest.$ac_ext
16123 cat >>conftest.$ac_ext <<_ACEOF
16124 /* end confdefs.h.  */
16125 int main(int argc, char **argv)
16126 {
16127         int devpollfd = open("/dev/poll", /* O_RDWR */ 2);
16128         exit (devpollfd == -1 ? 1 : 0);
16129 }
16130 _ACEOF
16131 rm -f conftest$ac_exeext
16132 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16133   (eval $ac_link) 2>&5
16134   ac_status=$?
16135   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16136   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16137   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16138   (eval $ac_try) 2>&5
16139   ac_status=$?
16140   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16141   (exit $ac_status); }; }; then
16142   echo "$as_me:$LINENO: result: yes" >&5
16143 echo "${ECHO_T}yes" >&6
16144
16145 cat >>confdefs.h <<\_ACEOF
16146 #define HAVE_DEVPOLL 1
16147 _ACEOF
16148
16149 else
16150   echo "$as_me: program exited with status $ac_status" >&5
16151 echo "$as_me: failed program was:" >&5
16152 sed 's/^/| /' conftest.$ac_ext >&5
16153
16154 ( exit $ac_status )
16155 echo "$as_me:$LINENO: result: no" >&5
16156 echo "${ECHO_T}no" >&6
16157 fi
16158 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16159 fi
16160 fi
16161
16162 # strerror checks
16163 echo "$as_me:$LINENO: checking declaration of sys_errlist" >&5
16164 echo $ECHO_N "checking declaration of sys_errlist... $ECHO_C" >&6
16165 if test "${ol_cv_dcl_sys_errlist+set}" = set; then
16166   echo $ECHO_N "(cached) $ECHO_C" >&6
16167 else
16168
16169         cat >conftest.$ac_ext <<_ACEOF
16170 /* confdefs.h.  */
16171 _ACEOF
16172 cat confdefs.h >>conftest.$ac_ext
16173 cat >>conftest.$ac_ext <<_ACEOF
16174 /* end confdefs.h.  */
16175
16176 #include <stdio.h>
16177 #include <sys/types.h>
16178 #include <errno.h>
16179 #ifdef _WIN32
16180 #include <stdlib.h>
16181 #endif
16182 int
16183 main ()
16184 {
16185 char *c = (char *) *sys_errlist
16186   ;
16187   return 0;
16188 }
16189 _ACEOF
16190 rm -f conftest.$ac_objext
16191 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16192   (eval $ac_compile) 2>conftest.er1
16193   ac_status=$?
16194   grep -v '^ *+' conftest.er1 >conftest.err
16195   rm -f conftest.er1
16196   cat conftest.err >&5
16197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16198   (exit $ac_status); } &&
16199          { ac_try='test -z "$ac_c_werror_flag"
16200                          || test ! -s conftest.err'
16201   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16202   (eval $ac_try) 2>&5
16203   ac_status=$?
16204   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16205   (exit $ac_status); }; } &&
16206          { ac_try='test -s conftest.$ac_objext'
16207   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16208   (eval $ac_try) 2>&5
16209   ac_status=$?
16210   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16211   (exit $ac_status); }; }; then
16212   ol_cv_dcl_sys_errlist=yes
16213         ol_cv_have_sys_errlist=yes
16214 else
16215   echo "$as_me: failed program was:" >&5
16216 sed 's/^/| /' conftest.$ac_ext >&5
16217
16218 ol_cv_dcl_sys_errlist=no
16219 fi
16220 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16221 fi
16222 echo "$as_me:$LINENO: result: $ol_cv_dcl_sys_errlist" >&5
16223 echo "${ECHO_T}$ol_cv_dcl_sys_errlist" >&6
16224 #
16225 # It's possible (for near-UNIX clones) that sys_errlist doesn't exist
16226 if test $ol_cv_dcl_sys_errlist = no ; then
16227
16228 cat >>confdefs.h <<\_ACEOF
16229 #define DECL_SYS_ERRLIST 1
16230 _ACEOF
16231
16232
16233         echo "$as_me:$LINENO: checking existence of sys_errlist" >&5
16234 echo $ECHO_N "checking existence of sys_errlist... $ECHO_C" >&6
16235 if test "${ol_cv_have_sys_errlist+set}" = set; then
16236   echo $ECHO_N "(cached) $ECHO_C" >&6
16237 else
16238
16239                 cat >conftest.$ac_ext <<_ACEOF
16240 /* confdefs.h.  */
16241 _ACEOF
16242 cat confdefs.h >>conftest.$ac_ext
16243 cat >>conftest.$ac_ext <<_ACEOF
16244 /* end confdefs.h.  */
16245 #include <errno.h>
16246 int
16247 main ()
16248 {
16249 char *c = (char *) *sys_errlist
16250   ;
16251   return 0;
16252 }
16253 _ACEOF
16254 rm -f conftest.$ac_objext conftest$ac_exeext
16255 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16256   (eval $ac_link) 2>conftest.er1
16257   ac_status=$?
16258   grep -v '^ *+' conftest.er1 >conftest.err
16259   rm -f conftest.er1
16260   cat conftest.err >&5
16261   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16262   (exit $ac_status); } &&
16263          { ac_try='test -z "$ac_c_werror_flag"
16264                          || test ! -s conftest.err'
16265   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16266   (eval $ac_try) 2>&5
16267   ac_status=$?
16268   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16269   (exit $ac_status); }; } &&
16270          { ac_try='test -s conftest$ac_exeext'
16271   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16272   (eval $ac_try) 2>&5
16273   ac_status=$?
16274   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16275   (exit $ac_status); }; }; then
16276   ol_cv_have_sys_errlist=yes
16277 else
16278   echo "$as_me: failed program was:" >&5
16279 sed 's/^/| /' conftest.$ac_ext >&5
16280
16281 ol_cv_have_sys_errlist=no
16282 fi
16283 rm -f conftest.err conftest.$ac_objext \
16284       conftest$ac_exeext conftest.$ac_ext
16285 fi
16286 echo "$as_me:$LINENO: result: $ol_cv_have_sys_errlist" >&5
16287 echo "${ECHO_T}$ol_cv_have_sys_errlist" >&6
16288 fi
16289 if test $ol_cv_have_sys_errlist = yes ; then
16290
16291 cat >>confdefs.h <<\_ACEOF
16292 #define HAVE_SYS_ERRLIST 1
16293 _ACEOF
16294
16295 fi
16296
16297
16298 for ac_func in strerror strerror_r
16299 do
16300 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16301 echo "$as_me:$LINENO: checking for $ac_func" >&5
16302 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16303 if eval "test \"\${$as_ac_var+set}\" = set"; then
16304   echo $ECHO_N "(cached) $ECHO_C" >&6
16305 else
16306   cat >conftest.$ac_ext <<_ACEOF
16307 /* confdefs.h.  */
16308 _ACEOF
16309 cat confdefs.h >>conftest.$ac_ext
16310 cat >>conftest.$ac_ext <<_ACEOF
16311 /* end confdefs.h.  */
16312 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16313    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16314 #define $ac_func innocuous_$ac_func
16315
16316 /* System header to define __stub macros and hopefully few prototypes,
16317     which can conflict with char $ac_func (); below.
16318     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16319     <limits.h> exists even on freestanding compilers.  */
16320
16321 #ifdef __STDC__
16322 # include <limits.h>
16323 #else
16324 # include <assert.h>
16325 #endif
16326
16327 #undef $ac_func
16328
16329 /* Override any gcc2 internal prototype to avoid an error.  */
16330 #ifdef __cplusplus
16331 extern "C"
16332 {
16333 #endif
16334 /* We use char because int might match the return type of a gcc2
16335    builtin and then its argument prototype would still apply.  */
16336 char $ac_func ();
16337 /* The GNU C library defines this for functions which it implements
16338     to always fail with ENOSYS.  Some functions are actually named
16339     something starting with __ and the normal name is an alias.  */
16340 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16341 choke me
16342 #else
16343 char (*f) () = $ac_func;
16344 #endif
16345 #ifdef __cplusplus
16346 }
16347 #endif
16348
16349 int
16350 main ()
16351 {
16352 return f != $ac_func;
16353   ;
16354   return 0;
16355 }
16356 _ACEOF
16357 rm -f conftest.$ac_objext conftest$ac_exeext
16358 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16359   (eval $ac_link) 2>conftest.er1
16360   ac_status=$?
16361   grep -v '^ *+' conftest.er1 >conftest.err
16362   rm -f conftest.er1
16363   cat conftest.err >&5
16364   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16365   (exit $ac_status); } &&
16366          { ac_try='test -z "$ac_c_werror_flag"
16367                          || test ! -s conftest.err'
16368   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16369   (eval $ac_try) 2>&5
16370   ac_status=$?
16371   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16372   (exit $ac_status); }; } &&
16373          { ac_try='test -s conftest$ac_exeext'
16374   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16375   (eval $ac_try) 2>&5
16376   ac_status=$?
16377   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16378   (exit $ac_status); }; }; then
16379   eval "$as_ac_var=yes"
16380 else
16381   echo "$as_me: failed program was:" >&5
16382 sed 's/^/| /' conftest.$ac_ext >&5
16383
16384 eval "$as_ac_var=no"
16385 fi
16386 rm -f conftest.err conftest.$ac_objext \
16387       conftest$ac_exeext conftest.$ac_ext
16388 fi
16389 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16390 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16391 if test `eval echo '${'$as_ac_var'}'` = yes; then
16392   cat >>confdefs.h <<_ACEOF
16393 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16394 _ACEOF
16395
16396 fi
16397 done
16398
16399 ol_cv_func_strerror_r=no
16400 if test "${ac_cv_func_strerror_r}" = yes ; then
16401         echo "$as_me:$LINENO: checking non-posix strerror_r" >&5
16402 echo $ECHO_N "checking non-posix strerror_r... $ECHO_C" >&6
16403 if test "${ol_cv_nonposix_strerror_r+set}" = set; then
16404   echo $ECHO_N "(cached) $ECHO_C" >&6
16405 else
16406
16407         cat >conftest.$ac_ext <<_ACEOF
16408 /* confdefs.h.  */
16409 _ACEOF
16410 cat confdefs.h >>conftest.$ac_ext
16411 cat >>conftest.$ac_ext <<_ACEOF
16412 /* end confdefs.h.  */
16413 #include <string.h>
16414 _ACEOF
16415 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16416   $EGREP "strerror_r" >/dev/null 2>&1; then
16417   ol_decl_strerror_r=yes
16418 else
16419   ol_decl_strerror_r=no
16420 fi
16421 rm -f conftest*
16422
16423         if test $ol_decl_strerror_r = yes ; then
16424                 cat >conftest.$ac_ext <<_ACEOF
16425 /* confdefs.h.  */
16426 _ACEOF
16427 cat confdefs.h >>conftest.$ac_ext
16428 cat >>conftest.$ac_ext <<_ACEOF
16429 /* end confdefs.h.  */
16430 #include <string.h>
16431 int
16432 main ()
16433 {
16434    /* from autoconf 2.59 */
16435                                 char buf[100];
16436                                 char x = *strerror_r (0, buf, sizeof buf);
16437                                 char *p = strerror_r (0, buf, sizeof buf);
16438
16439   ;
16440   return 0;
16441 }
16442 _ACEOF
16443 rm -f conftest.$ac_objext
16444 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16445   (eval $ac_compile) 2>conftest.er1
16446   ac_status=$?
16447   grep -v '^ *+' conftest.er1 >conftest.err
16448   rm -f conftest.er1
16449   cat conftest.err >&5
16450   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16451   (exit $ac_status); } &&
16452          { ac_try='test -z "$ac_c_werror_flag"
16453                          || test ! -s conftest.err'
16454   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16455   (eval $ac_try) 2>&5
16456   ac_status=$?
16457   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16458   (exit $ac_status); }; } &&
16459          { ac_try='test -s conftest.$ac_objext'
16460   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16461   (eval $ac_try) 2>&5
16462   ac_status=$?
16463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16464   (exit $ac_status); }; }; then
16465   ol_cv_nonposix_strerror_r=yes
16466 else
16467   echo "$as_me: failed program was:" >&5
16468 sed 's/^/| /' conftest.$ac_ext >&5
16469
16470 ol_cv_nonposix_strerror_r=no
16471 fi
16472 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16473         else
16474                 if test "$cross_compiling" = yes; then
16475   ol_cv_nonposix_strerror=no
16476 else
16477   cat >conftest.$ac_ext <<_ACEOF
16478 /* confdefs.h.  */
16479 _ACEOF
16480 cat confdefs.h >>conftest.$ac_ext
16481 cat >>conftest.$ac_ext <<_ACEOF
16482 /* end confdefs.h.  */
16483
16484                         main() {
16485                                 char buf[100];
16486                                 buf[0] = 0;
16487                                 strerror_r( 1, buf, sizeof buf );
16488                                 exit( buf[0] == 0 );
16489                         }
16490
16491 _ACEOF
16492 rm -f conftest$ac_exeext
16493 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16494   (eval $ac_link) 2>&5
16495   ac_status=$?
16496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16497   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16498   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16499   (eval $ac_try) 2>&5
16500   ac_status=$?
16501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16502   (exit $ac_status); }; }; then
16503   ol_cv_nonposix_strerror_r=yes
16504 else
16505   echo "$as_me: program exited with status $ac_status" >&5
16506 echo "$as_me: failed program was:" >&5
16507 sed 's/^/| /' conftest.$ac_ext >&5
16508
16509 ( exit $ac_status )
16510 ol_cv_nonposix_strerror=no
16511 fi
16512 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16513 fi
16514         fi
16515
16516 fi
16517 echo "$as_me:$LINENO: result: $ol_cv_nonposix_strerror_r" >&5
16518 echo "${ECHO_T}$ol_cv_nonposix_strerror_r" >&6
16519 if test $ol_cv_nonposix_strerror_r = yes ; then
16520
16521 cat >>confdefs.h <<\_ACEOF
16522 #define HAVE_NONPOSIX_STRERROR_R 1
16523 _ACEOF
16524
16525 fi
16526
16527 elif test "${ac_cv_func_strerror}" = no ; then
16528         echo "$as_me:$LINENO: checking declaration of sys_errlist" >&5
16529 echo $ECHO_N "checking declaration of sys_errlist... $ECHO_C" >&6
16530 if test "${ol_cv_dcl_sys_errlist+set}" = set; then
16531   echo $ECHO_N "(cached) $ECHO_C" >&6
16532 else
16533
16534         cat >conftest.$ac_ext <<_ACEOF
16535 /* confdefs.h.  */
16536 _ACEOF
16537 cat confdefs.h >>conftest.$ac_ext
16538 cat >>conftest.$ac_ext <<_ACEOF
16539 /* end confdefs.h.  */
16540
16541 #include <stdio.h>
16542 #include <sys/types.h>
16543 #include <errno.h>
16544 #ifdef _WIN32
16545 #include <stdlib.h>
16546 #endif
16547 int
16548 main ()
16549 {
16550 char *c = (char *) *sys_errlist
16551   ;
16552   return 0;
16553 }
16554 _ACEOF
16555 rm -f conftest.$ac_objext
16556 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16557   (eval $ac_compile) 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_objext'
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   ol_cv_dcl_sys_errlist=yes
16578         ol_cv_have_sys_errlist=yes
16579 else
16580   echo "$as_me: failed program was:" >&5
16581 sed 's/^/| /' conftest.$ac_ext >&5
16582
16583 ol_cv_dcl_sys_errlist=no
16584 fi
16585 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16586 fi
16587 echo "$as_me:$LINENO: result: $ol_cv_dcl_sys_errlist" >&5
16588 echo "${ECHO_T}$ol_cv_dcl_sys_errlist" >&6
16589 #
16590 # It's possible (for near-UNIX clones) that sys_errlist doesn't exist
16591 if test $ol_cv_dcl_sys_errlist = no ; then
16592
16593 cat >>confdefs.h <<\_ACEOF
16594 #define DECL_SYS_ERRLIST 1
16595 _ACEOF
16596
16597
16598         echo "$as_me:$LINENO: checking existence of sys_errlist" >&5
16599 echo $ECHO_N "checking existence of sys_errlist... $ECHO_C" >&6
16600 if test "${ol_cv_have_sys_errlist+set}" = set; then
16601   echo $ECHO_N "(cached) $ECHO_C" >&6
16602 else
16603
16604                 cat >conftest.$ac_ext <<_ACEOF
16605 /* confdefs.h.  */
16606 _ACEOF
16607 cat confdefs.h >>conftest.$ac_ext
16608 cat >>conftest.$ac_ext <<_ACEOF
16609 /* end confdefs.h.  */
16610 #include <errno.h>
16611 int
16612 main ()
16613 {
16614 char *c = (char *) *sys_errlist
16615   ;
16616   return 0;
16617 }
16618 _ACEOF
16619 rm -f conftest.$ac_objext conftest$ac_exeext
16620 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16621   (eval $ac_link) 2>conftest.er1
16622   ac_status=$?
16623   grep -v '^ *+' conftest.er1 >conftest.err
16624   rm -f conftest.er1
16625   cat conftest.err >&5
16626   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16627   (exit $ac_status); } &&
16628          { ac_try='test -z "$ac_c_werror_flag"
16629                          || test ! -s conftest.err'
16630   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16631   (eval $ac_try) 2>&5
16632   ac_status=$?
16633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16634   (exit $ac_status); }; } &&
16635          { ac_try='test -s conftest$ac_exeext'
16636   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16637   (eval $ac_try) 2>&5
16638   ac_status=$?
16639   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16640   (exit $ac_status); }; }; then
16641   ol_cv_have_sys_errlist=yes
16642 else
16643   echo "$as_me: failed program was:" >&5
16644 sed 's/^/| /' conftest.$ac_ext >&5
16645
16646 ol_cv_have_sys_errlist=no
16647 fi
16648 rm -f conftest.err conftest.$ac_objext \
16649       conftest$ac_exeext conftest.$ac_ext
16650 fi
16651 echo "$as_me:$LINENO: result: $ol_cv_have_sys_errlist" >&5
16652 echo "${ECHO_T}$ol_cv_have_sys_errlist" >&6
16653 fi
16654 if test $ol_cv_have_sys_errlist = yes ; then
16655
16656 cat >>confdefs.h <<\_ACEOF
16657 #define HAVE_SYS_ERRLIST 1
16658 _ACEOF
16659
16660 fi
16661
16662 fi
16663
16664
16665
16666 for ac_header in regex.h
16667 do
16668 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16669 echo "$as_me:$LINENO: checking for $ac_header" >&5
16670 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16671 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16672   echo $ECHO_N "(cached) $ECHO_C" >&6
16673 else
16674   cat >conftest.$ac_ext <<_ACEOF
16675 /* confdefs.h.  */
16676 _ACEOF
16677 cat confdefs.h >>conftest.$ac_ext
16678 cat >>conftest.$ac_ext <<_ACEOF
16679 /* end confdefs.h.  */
16680 $ac_includes_default
16681 #ifdef HAVE_SYS_TYPES_H
16682 #include <sys/types.h>
16683 #endif
16684
16685
16686 #include <$ac_header>
16687 _ACEOF
16688 rm -f conftest.$ac_objext
16689 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16690   (eval $ac_compile) 2>conftest.er1
16691   ac_status=$?
16692   grep -v '^ *+' conftest.er1 >conftest.err
16693   rm -f conftest.er1
16694   cat conftest.err >&5
16695   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16696   (exit $ac_status); } &&
16697          { ac_try='test -z "$ac_c_werror_flag"
16698                          || test ! -s conftest.err'
16699   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16700   (eval $ac_try) 2>&5
16701   ac_status=$?
16702   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16703   (exit $ac_status); }; } &&
16704          { ac_try='test -s conftest.$ac_objext'
16705   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16706   (eval $ac_try) 2>&5
16707   ac_status=$?
16708   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16709   (exit $ac_status); }; }; then
16710   eval "$as_ac_Header=yes"
16711 else
16712   echo "$as_me: failed program was:" >&5
16713 sed 's/^/| /' conftest.$ac_ext >&5
16714
16715 eval "$as_ac_Header=no"
16716 fi
16717 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16718 fi
16719 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16720 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16721 if test `eval echo '${'$as_ac_Header'}'` = yes; then
16722   cat >>confdefs.h <<_ACEOF
16723 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16724 _ACEOF
16725
16726 fi
16727
16728 done
16729
16730
16731 if test "$ac_cv_header_regex_h" != yes ; then
16732         { { echo "$as_me:$LINENO: error: POSIX regex.h required." >&5
16733 echo "$as_me: error: POSIX regex.h required." >&2;}
16734    { (exit 1); exit 1; }; }
16735 fi
16736 echo "$as_me:$LINENO: checking for library containing regfree" >&5
16737 echo $ECHO_N "checking for library containing regfree... $ECHO_C" >&6
16738 if test "${ac_cv_search_regfree+set}" = set; then
16739   echo $ECHO_N "(cached) $ECHO_C" >&6
16740 else
16741   ac_func_search_save_LIBS=$LIBS
16742 ac_cv_search_regfree=no
16743 cat >conftest.$ac_ext <<_ACEOF
16744 /* confdefs.h.  */
16745 _ACEOF
16746 cat confdefs.h >>conftest.$ac_ext
16747 cat >>conftest.$ac_ext <<_ACEOF
16748 /* end confdefs.h.  */
16749
16750 /* Override any gcc2 internal prototype to avoid an error.  */
16751 #ifdef __cplusplus
16752 extern "C"
16753 #endif
16754 /* We use char because int might match the return type of a gcc2
16755    builtin and then its argument prototype would still apply.  */
16756 char regfree ();
16757 int
16758 main ()
16759 {
16760 regfree ();
16761   ;
16762   return 0;
16763 }
16764 _ACEOF
16765 rm -f conftest.$ac_objext conftest$ac_exeext
16766 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16767   (eval $ac_link) 2>conftest.er1
16768   ac_status=$?
16769   grep -v '^ *+' conftest.er1 >conftest.err
16770   rm -f conftest.er1
16771   cat conftest.err >&5
16772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16773   (exit $ac_status); } &&
16774          { ac_try='test -z "$ac_c_werror_flag"
16775                          || test ! -s conftest.err'
16776   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16777   (eval $ac_try) 2>&5
16778   ac_status=$?
16779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16780   (exit $ac_status); }; } &&
16781          { ac_try='test -s conftest$ac_exeext'
16782   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16783   (eval $ac_try) 2>&5
16784   ac_status=$?
16785   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16786   (exit $ac_status); }; }; then
16787   ac_cv_search_regfree="none required"
16788 else
16789   echo "$as_me: failed program was:" >&5
16790 sed 's/^/| /' conftest.$ac_ext >&5
16791
16792 fi
16793 rm -f conftest.err conftest.$ac_objext \
16794       conftest$ac_exeext conftest.$ac_ext
16795 if test "$ac_cv_search_regfree" = no; then
16796   for ac_lib in regex gnuregex; do
16797     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
16798     cat >conftest.$ac_ext <<_ACEOF
16799 /* confdefs.h.  */
16800 _ACEOF
16801 cat confdefs.h >>conftest.$ac_ext
16802 cat >>conftest.$ac_ext <<_ACEOF
16803 /* end confdefs.h.  */
16804
16805 /* Override any gcc2 internal prototype to avoid an error.  */
16806 #ifdef __cplusplus
16807 extern "C"
16808 #endif
16809 /* We use char because int might match the return type of a gcc2
16810    builtin and then its argument prototype would still apply.  */
16811 char regfree ();
16812 int
16813 main ()
16814 {
16815 regfree ();
16816   ;
16817   return 0;
16818 }
16819 _ACEOF
16820 rm -f conftest.$ac_objext conftest$ac_exeext
16821 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16822   (eval $ac_link) 2>conftest.er1
16823   ac_status=$?
16824   grep -v '^ *+' conftest.er1 >conftest.err
16825   rm -f conftest.er1
16826   cat conftest.err >&5
16827   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16828   (exit $ac_status); } &&
16829          { ac_try='test -z "$ac_c_werror_flag"
16830                          || test ! -s conftest.err'
16831   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16832   (eval $ac_try) 2>&5
16833   ac_status=$?
16834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16835   (exit $ac_status); }; } &&
16836          { ac_try='test -s conftest$ac_exeext'
16837   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16838   (eval $ac_try) 2>&5
16839   ac_status=$?
16840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16841   (exit $ac_status); }; }; then
16842   ac_cv_search_regfree="-l$ac_lib"
16843 break
16844 else
16845   echo "$as_me: failed program was:" >&5
16846 sed 's/^/| /' conftest.$ac_ext >&5
16847
16848 fi
16849 rm -f conftest.err conftest.$ac_objext \
16850       conftest$ac_exeext conftest.$ac_ext
16851   done
16852 fi
16853 LIBS=$ac_func_search_save_LIBS
16854 fi
16855 echo "$as_me:$LINENO: result: $ac_cv_search_regfree" >&5
16856 echo "${ECHO_T}$ac_cv_search_regfree" >&6
16857 if test "$ac_cv_search_regfree" != no; then
16858   test "$ac_cv_search_regfree" = "none required" || LIBS="$ac_cv_search_regfree $LIBS"
16859   :
16860 else
16861   { { echo "$as_me:$LINENO: error: POSIX regex required." >&5
16862 echo "$as_me: error: POSIX regex required." >&2;}
16863    { (exit 1); exit 1; }; }
16864 fi
16865
16866
16867
16868 echo "$as_me:$LINENO: checking for compatible POSIX regex" >&5
16869 echo $ECHO_N "checking for compatible POSIX regex... $ECHO_C" >&6
16870 if test "${ol_cv_c_posix_regex+set}" = set; then
16871   echo $ECHO_N "(cached) $ECHO_C" >&6
16872 else
16873
16874         if test "$cross_compiling" = yes; then
16875   ol_cv_c_posix_regex=cross
16876 else
16877   cat >conftest.$ac_ext <<_ACEOF
16878 /* confdefs.h.  */
16879 _ACEOF
16880 cat confdefs.h >>conftest.$ac_ext
16881 cat >>conftest.$ac_ext <<_ACEOF
16882 /* end confdefs.h.  */
16883
16884 #include <sys/types.h>
16885 #include <regex.h>
16886 static char *pattern, *string;
16887 main()
16888 {
16889         int rc;
16890         regex_t re;
16891
16892         pattern = "^A";
16893
16894         if(regcomp(&re, pattern, 0)) {
16895                 return -1;
16896         }
16897
16898         string = "ALL MATCH";
16899
16900         rc = regexec(&re, string, 0, (void*)0, 0);
16901
16902         regfree(&re);
16903
16904         return rc;
16905 }
16906 _ACEOF
16907 rm -f conftest$ac_exeext
16908 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16909   (eval $ac_link) 2>&5
16910   ac_status=$?
16911   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16912   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16913   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16914   (eval $ac_try) 2>&5
16915   ac_status=$?
16916   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16917   (exit $ac_status); }; }; then
16918   ol_cv_c_posix_regex=yes
16919 else
16920   echo "$as_me: program exited with status $ac_status" >&5
16921 echo "$as_me: failed program was:" >&5
16922 sed 's/^/| /' conftest.$ac_ext >&5
16923
16924 ( exit $ac_status )
16925 ol_cv_c_posix_regex=no
16926 fi
16927 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16928 fi
16929 fi
16930 echo "$as_me:$LINENO: result: $ol_cv_c_posix_regex" >&5
16931 echo "${ECHO_T}$ol_cv_c_posix_regex" >&6
16932
16933 if test "$ol_cv_c_posix_regex" = no ; then
16934         { { echo "$as_me:$LINENO: error: broken POSIX regex!" >&5
16935 echo "$as_me: error: broken POSIX regex!" >&2;}
16936    { (exit 1); exit 1; }; }
16937 fi
16938
16939
16940 have_uuid=no
16941
16942 for ac_header in sys/uuid.h
16943 do
16944 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16945 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16946   echo "$as_me:$LINENO: checking for $ac_header" >&5
16947 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16948 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16949   echo $ECHO_N "(cached) $ECHO_C" >&6
16950 fi
16951 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16952 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16953 else
16954   # Is the header compilable?
16955 echo "$as_me:$LINENO: checking $ac_header usability" >&5
16956 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16957 cat >conftest.$ac_ext <<_ACEOF
16958 /* confdefs.h.  */
16959 _ACEOF
16960 cat confdefs.h >>conftest.$ac_ext
16961 cat >>conftest.$ac_ext <<_ACEOF
16962 /* end confdefs.h.  */
16963 $ac_includes_default
16964 #include <$ac_header>
16965 _ACEOF
16966 rm -f conftest.$ac_objext
16967 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16968   (eval $ac_compile) 2>conftest.er1
16969   ac_status=$?
16970   grep -v '^ *+' conftest.er1 >conftest.err
16971   rm -f conftest.er1
16972   cat conftest.err >&5
16973   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16974   (exit $ac_status); } &&
16975          { ac_try='test -z "$ac_c_werror_flag"
16976                          || test ! -s conftest.err'
16977   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16978   (eval $ac_try) 2>&5
16979   ac_status=$?
16980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16981   (exit $ac_status); }; } &&
16982          { ac_try='test -s conftest.$ac_objext'
16983   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16984   (eval $ac_try) 2>&5
16985   ac_status=$?
16986   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16987   (exit $ac_status); }; }; then
16988   ac_header_compiler=yes
16989 else
16990   echo "$as_me: failed program was:" >&5
16991 sed 's/^/| /' conftest.$ac_ext >&5
16992
16993 ac_header_compiler=no
16994 fi
16995 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16996 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16997 echo "${ECHO_T}$ac_header_compiler" >&6
16998
16999 # Is the header present?
17000 echo "$as_me:$LINENO: checking $ac_header presence" >&5
17001 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17002 cat >conftest.$ac_ext <<_ACEOF
17003 /* confdefs.h.  */
17004 _ACEOF
17005 cat confdefs.h >>conftest.$ac_ext
17006 cat >>conftest.$ac_ext <<_ACEOF
17007 /* end confdefs.h.  */
17008 #include <$ac_header>
17009 _ACEOF
17010 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
17011   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17012   ac_status=$?
17013   grep -v '^ *+' conftest.er1 >conftest.err
17014   rm -f conftest.er1
17015   cat conftest.err >&5
17016   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17017   (exit $ac_status); } >/dev/null; then
17018   if test -s conftest.err; then
17019     ac_cpp_err=$ac_c_preproc_warn_flag
17020     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
17021   else
17022     ac_cpp_err=
17023   fi
17024 else
17025   ac_cpp_err=yes
17026 fi
17027 if test -z "$ac_cpp_err"; then
17028   ac_header_preproc=yes
17029 else
17030   echo "$as_me: failed program was:" >&5
17031 sed 's/^/| /' conftest.$ac_ext >&5
17032
17033   ac_header_preproc=no
17034 fi
17035 rm -f conftest.err conftest.$ac_ext
17036 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17037 echo "${ECHO_T}$ac_header_preproc" >&6
17038
17039 # So?  What about this header?
17040 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17041   yes:no: )
17042     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17043 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17044     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
17045 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
17046     ac_header_preproc=yes
17047     ;;
17048   no:yes:* )
17049     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17050 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17051     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
17052 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
17053     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
17054 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
17055     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
17056 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
17057     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17058 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17059     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
17060 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
17061     (
17062       cat <<\_ASBOX
17063 ## --------------------------------------------- ##
17064 ## Report this to <http://www.openldap.org/its/> ##
17065 ## --------------------------------------------- ##
17066 _ASBOX
17067     ) |
17068       sed "s/^/$as_me: WARNING:     /" >&2
17069     ;;
17070 esac
17071 echo "$as_me:$LINENO: checking for $ac_header" >&5
17072 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17073 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17074   echo $ECHO_N "(cached) $ECHO_C" >&6
17075 else
17076   eval "$as_ac_Header=\$ac_header_preproc"
17077 fi
17078 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17079 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17080
17081 fi
17082 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17083   cat >>confdefs.h <<_ACEOF
17084 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17085 _ACEOF
17086
17087 fi
17088
17089 done
17090
17091 if test $ac_cv_header_sys_uuid_h = yes ; then
17092         save_LIBS="$LIBS"
17093         echo "$as_me:$LINENO: checking for library containing uuid_to_str" >&5
17094 echo $ECHO_N "checking for library containing uuid_to_str... $ECHO_C" >&6
17095 if test "${ac_cv_search_uuid_to_str+set}" = set; then
17096   echo $ECHO_N "(cached) $ECHO_C" >&6
17097 else
17098   ac_func_search_save_LIBS=$LIBS
17099 ac_cv_search_uuid_to_str=no
17100 cat >conftest.$ac_ext <<_ACEOF
17101 /* confdefs.h.  */
17102 _ACEOF
17103 cat confdefs.h >>conftest.$ac_ext
17104 cat >>conftest.$ac_ext <<_ACEOF
17105 /* end confdefs.h.  */
17106
17107 /* Override any gcc2 internal prototype to avoid an error.  */
17108 #ifdef __cplusplus
17109 extern "C"
17110 #endif
17111 /* We use char because int might match the return type of a gcc2
17112    builtin and then its argument prototype would still apply.  */
17113 char uuid_to_str ();
17114 int
17115 main ()
17116 {
17117 uuid_to_str ();
17118   ;
17119   return 0;
17120 }
17121 _ACEOF
17122 rm -f conftest.$ac_objext conftest$ac_exeext
17123 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17124   (eval $ac_link) 2>conftest.er1
17125   ac_status=$?
17126   grep -v '^ *+' conftest.er1 >conftest.err
17127   rm -f conftest.er1
17128   cat conftest.err >&5
17129   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17130   (exit $ac_status); } &&
17131          { ac_try='test -z "$ac_c_werror_flag"
17132                          || test ! -s conftest.err'
17133   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17134   (eval $ac_try) 2>&5
17135   ac_status=$?
17136   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17137   (exit $ac_status); }; } &&
17138          { ac_try='test -s conftest$ac_exeext'
17139   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17140   (eval $ac_try) 2>&5
17141   ac_status=$?
17142   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17143   (exit $ac_status); }; }; then
17144   ac_cv_search_uuid_to_str="none required"
17145 else
17146   echo "$as_me: failed program was:" >&5
17147 sed 's/^/| /' conftest.$ac_ext >&5
17148
17149 fi
17150 rm -f conftest.err conftest.$ac_objext \
17151       conftest$ac_exeext conftest.$ac_ext
17152 if test "$ac_cv_search_uuid_to_str" = no; then
17153   for ac_lib in uuid; do
17154     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17155     cat >conftest.$ac_ext <<_ACEOF
17156 /* confdefs.h.  */
17157 _ACEOF
17158 cat confdefs.h >>conftest.$ac_ext
17159 cat >>conftest.$ac_ext <<_ACEOF
17160 /* end confdefs.h.  */
17161
17162 /* Override any gcc2 internal prototype to avoid an error.  */
17163 #ifdef __cplusplus
17164 extern "C"
17165 #endif
17166 /* We use char because int might match the return type of a gcc2
17167    builtin and then its argument prototype would still apply.  */
17168 char uuid_to_str ();
17169 int
17170 main ()
17171 {
17172 uuid_to_str ();
17173   ;
17174   return 0;
17175 }
17176 _ACEOF
17177 rm -f conftest.$ac_objext conftest$ac_exeext
17178 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17179   (eval $ac_link) 2>conftest.er1
17180   ac_status=$?
17181   grep -v '^ *+' conftest.er1 >conftest.err
17182   rm -f conftest.er1
17183   cat conftest.err >&5
17184   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17185   (exit $ac_status); } &&
17186          { ac_try='test -z "$ac_c_werror_flag"
17187                          || test ! -s conftest.err'
17188   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17189   (eval $ac_try) 2>&5
17190   ac_status=$?
17191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17192   (exit $ac_status); }; } &&
17193          { ac_try='test -s conftest$ac_exeext'
17194   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17195   (eval $ac_try) 2>&5
17196   ac_status=$?
17197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17198   (exit $ac_status); }; }; then
17199   ac_cv_search_uuid_to_str="-l$ac_lib"
17200 break
17201 else
17202   echo "$as_me: failed program was:" >&5
17203 sed 's/^/| /' conftest.$ac_ext >&5
17204
17205 fi
17206 rm -f conftest.err conftest.$ac_objext \
17207       conftest$ac_exeext conftest.$ac_ext
17208   done
17209 fi
17210 LIBS=$ac_func_search_save_LIBS
17211 fi
17212 echo "$as_me:$LINENO: result: $ac_cv_search_uuid_to_str" >&5
17213 echo "${ECHO_T}$ac_cv_search_uuid_to_str" >&6
17214 if test "$ac_cv_search_uuid_to_str" != no; then
17215   test "$ac_cv_search_uuid_to_str" = "none required" || LIBS="$ac_cv_search_uuid_to_str $LIBS"
17216   have_uuid=yes
17217 else
17218   :
17219 fi
17220
17221         LIBS="$save_LIBS"
17222
17223         if test have_uuid = yes ; then
17224
17225 cat >>confdefs.h <<\_ACEOF
17226 #define HAVE_UUID_TO_STR 1
17227 _ACEOF
17228
17229
17230                 test "$ac_cv_search_uuid_to_str" = "none required" || \
17231                         SLAPD_LIBS="$SLAPD_LIBS $ac_cv_search_uuid_to_str"
17232         fi
17233 fi
17234
17235 if test $have_uuid = no ; then
17236
17237 for ac_header in uuid/uuid.h
17238 do
17239 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17240 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17241   echo "$as_me:$LINENO: checking for $ac_header" >&5
17242 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17243 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17244   echo $ECHO_N "(cached) $ECHO_C" >&6
17245 fi
17246 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17247 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17248 else
17249   # Is the header compilable?
17250 echo "$as_me:$LINENO: checking $ac_header usability" >&5
17251 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17252 cat >conftest.$ac_ext <<_ACEOF
17253 /* confdefs.h.  */
17254 _ACEOF
17255 cat confdefs.h >>conftest.$ac_ext
17256 cat >>conftest.$ac_ext <<_ACEOF
17257 /* end confdefs.h.  */
17258 $ac_includes_default
17259 #include <$ac_header>
17260 _ACEOF
17261 rm -f conftest.$ac_objext
17262 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17263   (eval $ac_compile) 2>conftest.er1
17264   ac_status=$?
17265   grep -v '^ *+' conftest.er1 >conftest.err
17266   rm -f conftest.er1
17267   cat conftest.err >&5
17268   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17269   (exit $ac_status); } &&
17270          { ac_try='test -z "$ac_c_werror_flag"
17271                          || test ! -s conftest.err'
17272   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17273   (eval $ac_try) 2>&5
17274   ac_status=$?
17275   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17276   (exit $ac_status); }; } &&
17277          { ac_try='test -s conftest.$ac_objext'
17278   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17279   (eval $ac_try) 2>&5
17280   ac_status=$?
17281   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17282   (exit $ac_status); }; }; then
17283   ac_header_compiler=yes
17284 else
17285   echo "$as_me: failed program was:" >&5
17286 sed 's/^/| /' conftest.$ac_ext >&5
17287
17288 ac_header_compiler=no
17289 fi
17290 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17291 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17292 echo "${ECHO_T}$ac_header_compiler" >&6
17293
17294 # Is the header present?
17295 echo "$as_me:$LINENO: checking $ac_header presence" >&5
17296 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17297 cat >conftest.$ac_ext <<_ACEOF
17298 /* confdefs.h.  */
17299 _ACEOF
17300 cat confdefs.h >>conftest.$ac_ext
17301 cat >>conftest.$ac_ext <<_ACEOF
17302 /* end confdefs.h.  */
17303 #include <$ac_header>
17304 _ACEOF
17305 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
17306   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17307   ac_status=$?
17308   grep -v '^ *+' conftest.er1 >conftest.err
17309   rm -f conftest.er1
17310   cat conftest.err >&5
17311   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17312   (exit $ac_status); } >/dev/null; then
17313   if test -s conftest.err; then
17314     ac_cpp_err=$ac_c_preproc_warn_flag
17315     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
17316   else
17317     ac_cpp_err=
17318   fi
17319 else
17320   ac_cpp_err=yes
17321 fi
17322 if test -z "$ac_cpp_err"; then
17323   ac_header_preproc=yes
17324 else
17325   echo "$as_me: failed program was:" >&5
17326 sed 's/^/| /' conftest.$ac_ext >&5
17327
17328   ac_header_preproc=no
17329 fi
17330 rm -f conftest.err conftest.$ac_ext
17331 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17332 echo "${ECHO_T}$ac_header_preproc" >&6
17333
17334 # So?  What about this header?
17335 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17336   yes:no: )
17337     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17338 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17339     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
17340 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
17341     ac_header_preproc=yes
17342     ;;
17343   no:yes:* )
17344     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17345 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17346     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
17347 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
17348     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
17349 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
17350     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
17351 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
17352     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17353 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17354     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
17355 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
17356     (
17357       cat <<\_ASBOX
17358 ## --------------------------------------------- ##
17359 ## Report this to <http://www.openldap.org/its/> ##
17360 ## --------------------------------------------- ##
17361 _ASBOX
17362     ) |
17363       sed "s/^/$as_me: WARNING:     /" >&2
17364     ;;
17365 esac
17366 echo "$as_me:$LINENO: checking for $ac_header" >&5
17367 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17368 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17369   echo $ECHO_N "(cached) $ECHO_C" >&6
17370 else
17371   eval "$as_ac_Header=\$ac_header_preproc"
17372 fi
17373 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17374 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17375
17376 fi
17377 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17378   cat >>confdefs.h <<_ACEOF
17379 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17380 _ACEOF
17381
17382 fi
17383
17384 done
17385
17386         if test $ac_cv_header_uuid_uuid_h = yes ; then
17387                 save_LIBS="$LIBS"
17388                 echo "$as_me:$LINENO: checking for library containing uuid_generate" >&5
17389 echo $ECHO_N "checking for library containing uuid_generate... $ECHO_C" >&6
17390 if test "${ac_cv_search_uuid_generate+set}" = set; then
17391   echo $ECHO_N "(cached) $ECHO_C" >&6
17392 else
17393   ac_func_search_save_LIBS=$LIBS
17394 ac_cv_search_uuid_generate=no
17395 cat >conftest.$ac_ext <<_ACEOF
17396 /* confdefs.h.  */
17397 _ACEOF
17398 cat confdefs.h >>conftest.$ac_ext
17399 cat >>conftest.$ac_ext <<_ACEOF
17400 /* end confdefs.h.  */
17401
17402 /* Override any gcc2 internal prototype to avoid an error.  */
17403 #ifdef __cplusplus
17404 extern "C"
17405 #endif
17406 /* We use char because int might match the return type of a gcc2
17407    builtin and then its argument prototype would still apply.  */
17408 char uuid_generate ();
17409 int
17410 main ()
17411 {
17412 uuid_generate ();
17413   ;
17414   return 0;
17415 }
17416 _ACEOF
17417 rm -f conftest.$ac_objext conftest$ac_exeext
17418 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17419   (eval $ac_link) 2>conftest.er1
17420   ac_status=$?
17421   grep -v '^ *+' conftest.er1 >conftest.err
17422   rm -f conftest.er1
17423   cat conftest.err >&5
17424   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17425   (exit $ac_status); } &&
17426          { ac_try='test -z "$ac_c_werror_flag"
17427                          || test ! -s conftest.err'
17428   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17429   (eval $ac_try) 2>&5
17430   ac_status=$?
17431   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17432   (exit $ac_status); }; } &&
17433          { ac_try='test -s conftest$ac_exeext'
17434   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17435   (eval $ac_try) 2>&5
17436   ac_status=$?
17437   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17438   (exit $ac_status); }; }; then
17439   ac_cv_search_uuid_generate="none required"
17440 else
17441   echo "$as_me: failed program was:" >&5
17442 sed 's/^/| /' conftest.$ac_ext >&5
17443
17444 fi
17445 rm -f conftest.err conftest.$ac_objext \
17446       conftest$ac_exeext conftest.$ac_ext
17447 if test "$ac_cv_search_uuid_generate" = no; then
17448   for ac_lib in uuid; do
17449     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17450     cat >conftest.$ac_ext <<_ACEOF
17451 /* confdefs.h.  */
17452 _ACEOF
17453 cat confdefs.h >>conftest.$ac_ext
17454 cat >>conftest.$ac_ext <<_ACEOF
17455 /* end confdefs.h.  */
17456
17457 /* Override any gcc2 internal prototype to avoid an error.  */
17458 #ifdef __cplusplus
17459 extern "C"
17460 #endif
17461 /* We use char because int might match the return type of a gcc2
17462    builtin and then its argument prototype would still apply.  */
17463 char uuid_generate ();
17464 int
17465 main ()
17466 {
17467 uuid_generate ();
17468   ;
17469   return 0;
17470 }
17471 _ACEOF
17472 rm -f conftest.$ac_objext conftest$ac_exeext
17473 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17474   (eval $ac_link) 2>conftest.er1
17475   ac_status=$?
17476   grep -v '^ *+' conftest.er1 >conftest.err
17477   rm -f conftest.er1
17478   cat conftest.err >&5
17479   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17480   (exit $ac_status); } &&
17481          { ac_try='test -z "$ac_c_werror_flag"
17482                          || test ! -s conftest.err'
17483   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17484   (eval $ac_try) 2>&5
17485   ac_status=$?
17486   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17487   (exit $ac_status); }; } &&
17488          { ac_try='test -s conftest$ac_exeext'
17489   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17490   (eval $ac_try) 2>&5
17491   ac_status=$?
17492   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17493   (exit $ac_status); }; }; then
17494   ac_cv_search_uuid_generate="-l$ac_lib"
17495 break
17496 else
17497   echo "$as_me: failed program was:" >&5
17498 sed 's/^/| /' conftest.$ac_ext >&5
17499
17500 fi
17501 rm -f conftest.err conftest.$ac_objext \
17502       conftest$ac_exeext conftest.$ac_ext
17503   done
17504 fi
17505 LIBS=$ac_func_search_save_LIBS
17506 fi
17507 echo "$as_me:$LINENO: result: $ac_cv_search_uuid_generate" >&5
17508 echo "${ECHO_T}$ac_cv_search_uuid_generate" >&6
17509 if test "$ac_cv_search_uuid_generate" != no; then
17510   test "$ac_cv_search_uuid_generate" = "none required" || LIBS="$ac_cv_search_uuid_generate $LIBS"
17511   have_uuid=yes
17512 else
17513   :
17514 fi
17515
17516                 LIBS="$save_LIBS"
17517
17518                 if test have_uuid = yes ; then
17519
17520 cat >>confdefs.h <<\_ACEOF
17521 #define HAVE_UUID_GENERATE 1
17522 _ACEOF
17523
17524
17525                         test "$ac_cv_search_uuid_generate" = "none required" || \
17526                                 SLAPD_LIBS="$SLAPD_LIBS $ac_cv_search_uuid_generate"
17527                 fi
17528         fi
17529 fi
17530
17531 if test $have_uuid = no ; then
17532         echo "$as_me:$LINENO: checking to see if -lrpcrt4 is needed for win32 UUID support" >&5
17533 echo $ECHO_N "checking to see if -lrpcrt4 is needed for win32 UUID support... $ECHO_C" >&6
17534         save_LIBS="$LIBS"
17535         LIBS="$LIBS -lrpcrt4"
17536         cat >conftest.$ac_ext <<_ACEOF
17537 /* confdefs.h.  */
17538 _ACEOF
17539 cat confdefs.h >>conftest.$ac_ext
17540 cat >>conftest.$ac_ext <<_ACEOF
17541 /* end confdefs.h.  */
17542
17543                 int __stdcall UuidCreate(void *);
17544                 int __stdcall UuidToStringA(void *,void **);
17545
17546 int
17547 main ()
17548 {
17549
17550                 UuidCreate(0);
17551                 UuidToStringA(0,0);
17552
17553   ;
17554   return 0;
17555 }
17556 _ACEOF
17557 rm -f conftest.$ac_objext conftest$ac_exeext
17558 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17559   (eval $ac_link) 2>conftest.er1
17560   ac_status=$?
17561   grep -v '^ *+' conftest.er1 >conftest.err
17562   rm -f conftest.er1
17563   cat conftest.err >&5
17564   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17565   (exit $ac_status); } &&
17566          { ac_try='test -z "$ac_c_werror_flag"
17567                          || test ! -s conftest.err'
17568   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17569   (eval $ac_try) 2>&5
17570   ac_status=$?
17571   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17572   (exit $ac_status); }; } &&
17573          { ac_try='test -s conftest$ac_exeext'
17574   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17575   (eval $ac_try) 2>&5
17576   ac_status=$?
17577   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17578   (exit $ac_status); }; }; then
17579   need_rpcrt=yes
17580 else
17581   echo "$as_me: failed program was:" >&5
17582 sed 's/^/| /' conftest.$ac_ext >&5
17583
17584 need_rpcrt=no
17585 fi
17586 rm -f conftest.err conftest.$ac_objext \
17587       conftest$ac_exeext conftest.$ac_ext
17588         if test $need_rpcrt = yes; then
17589                 SLAPD_LIBS="$SLAPD_LIBS -lrpcrt4"
17590         fi
17591         LIBS="$save_LIBS"
17592         echo "$as_me:$LINENO: result: $need_rpcrt" >&5
17593 echo "${ECHO_T}$need_rpcrt" >&6
17594 fi
17595
17596 ol_cv_lib_resolver=no
17597 if test $ol_cv_lib_resolver = no ; then
17598         echo "$as_me:$LINENO: checking for resolver link (default)" >&5
17599 echo $ECHO_N "checking for resolver link (default)... $ECHO_C" >&6
17600 if test "${ol_cv_resolver_none+set}" = set; then
17601   echo $ECHO_N "(cached) $ECHO_C" >&6
17602 else
17603
17604         ol_RESOLVER_LIB=
17605         ol_LIBS=$LIBS
17606         LIBS="$ol_RESOLVER_LIB $LIBS"
17607
17608         cat >conftest.$ac_ext <<_ACEOF
17609 /* confdefs.h.  */
17610 _ACEOF
17611 cat confdefs.h >>conftest.$ac_ext
17612 cat >>conftest.$ac_ext <<_ACEOF
17613 /* end confdefs.h.  */
17614
17615 #ifdef HAVE_SYS_TYPES_H
17616 #       include <sys/types.h>
17617 #endif
17618 #include <netinet/in.h>
17619 #ifdef HAVE_ARPA_NAMESER_H
17620 #       include <arpa/nameser.h>
17621 #endif
17622 #ifdef HAVE_RESOLV_H
17623 #       include <resolv.h>
17624 #endif
17625
17626 int
17627 main ()
17628 {
17629 {
17630         int len, status;
17631         char *request = NULL;
17632         unsigned char reply[64*1024];
17633         unsigned char host[64*1024];
17634         unsigned char *p;
17635
17636 #ifdef NS_HFIXEDSZ
17637         /* Bind 8/9 interface */
17638         len = res_query(request, ns_c_in, ns_t_srv, reply, sizeof(reply));
17639 #else
17640         /* Bind 4 interface */
17641 # ifndef T_SRV
17642 #  define T_SRV 33
17643 # endif
17644         len = res_query(request, C_IN, T_SRV, reply, sizeof(reply));
17645 #endif
17646         p = reply;
17647 #ifdef NS_HFIXEDSZ
17648         /* Bind 8/9 interface */
17649         p += NS_HFIXEDSZ;
17650 #elif defined(HFIXEDSZ)
17651         /* Bind 4 interface w/ HFIXEDSZ */
17652         p += HFIXEDSZ;
17653 #else
17654         /* Bind 4 interface w/o HFIXEDSZ */
17655         p += sizeof(HEADER);
17656 #endif
17657         status = dn_expand( reply, reply+len, p, host, sizeof(host));
17658 }
17659   ;
17660   return 0;
17661 }
17662 _ACEOF
17663 rm -f conftest.$ac_objext conftest$ac_exeext
17664 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17665   (eval $ac_link) 2>conftest.er1
17666   ac_status=$?
17667   grep -v '^ *+' conftest.er1 >conftest.err
17668   rm -f conftest.er1
17669   cat conftest.err >&5
17670   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17671   (exit $ac_status); } &&
17672          { ac_try='test -z "$ac_c_werror_flag"
17673                          || test ! -s conftest.err'
17674   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17675   (eval $ac_try) 2>&5
17676   ac_status=$?
17677   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17678   (exit $ac_status); }; } &&
17679          { ac_try='test -s conftest$ac_exeext'
17680   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17681   (eval $ac_try) 2>&5
17682   ac_status=$?
17683   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17684   (exit $ac_status); }; }; then
17685   ol_cv_resolver_none=yes
17686 else
17687   echo "$as_me: failed program was:" >&5
17688 sed 's/^/| /' conftest.$ac_ext >&5
17689
17690 ol_cv_resolver_none=no
17691 fi
17692 rm -f conftest.err conftest.$ac_objext \
17693       conftest$ac_exeext conftest.$ac_ext
17694
17695         LIBS="$ol_LIBS"
17696
17697 fi
17698 echo "$as_me:$LINENO: result: $ol_cv_resolver_none" >&5
17699 echo "${ECHO_T}$ol_cv_resolver_none" >&6
17700
17701         if test $ol_cv_resolver_none = yes ; then
17702                 ol_cv_lib_resolver=yes
17703         fi
17704 fi
17705
17706 if test $ol_cv_lib_resolver = no ; then
17707         echo "$as_me:$LINENO: checking for resolver link (-lresolv)" >&5
17708 echo $ECHO_N "checking for resolver link (-lresolv)... $ECHO_C" >&6
17709 if test "${ol_cv_resolver_resolv+set}" = set; then
17710   echo $ECHO_N "(cached) $ECHO_C" >&6
17711 else
17712
17713         ol_RESOLVER_LIB=-lresolv
17714         ol_LIBS=$LIBS
17715         LIBS="$ol_RESOLVER_LIB $LIBS"
17716
17717         cat >conftest.$ac_ext <<_ACEOF
17718 /* confdefs.h.  */
17719 _ACEOF
17720 cat confdefs.h >>conftest.$ac_ext
17721 cat >>conftest.$ac_ext <<_ACEOF
17722 /* end confdefs.h.  */
17723
17724 #ifdef HAVE_SYS_TYPES_H
17725 #       include <sys/types.h>
17726 #endif
17727 #include <netinet/in.h>
17728 #ifdef HAVE_ARPA_NAMESER_H
17729 #       include <arpa/nameser.h>
17730 #endif
17731 #ifdef HAVE_RESOLV_H
17732 #       include <resolv.h>
17733 #endif
17734
17735 int
17736 main ()
17737 {
17738 {
17739         int len, status;
17740         char *request = NULL;
17741         unsigned char reply[64*1024];
17742         unsigned char host[64*1024];
17743         unsigned char *p;
17744
17745 #ifdef NS_HFIXEDSZ
17746         /* Bind 8/9 interface */
17747         len = res_query(request, ns_c_in, ns_t_srv, reply, sizeof(reply));
17748 #else
17749         /* Bind 4 interface */
17750 # ifndef T_SRV
17751 #  define T_SRV 33
17752 # endif
17753         len = res_query(request, C_IN, T_SRV, reply, sizeof(reply));
17754 #endif
17755         p = reply;
17756 #ifdef NS_HFIXEDSZ
17757         /* Bind 8/9 interface */
17758         p += NS_HFIXEDSZ;
17759 #elif defined(HFIXEDSZ)
17760         /* Bind 4 interface w/ HFIXEDSZ */
17761         p += HFIXEDSZ;
17762 #else
17763         /* Bind 4 interface w/o HFIXEDSZ */
17764         p += sizeof(HEADER);
17765 #endif
17766         status = dn_expand( reply, reply+len, p, host, sizeof(host));
17767 }
17768   ;
17769   return 0;
17770 }
17771 _ACEOF
17772 rm -f conftest.$ac_objext conftest$ac_exeext
17773 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17774   (eval $ac_link) 2>conftest.er1
17775   ac_status=$?
17776   grep -v '^ *+' conftest.er1 >conftest.err
17777   rm -f conftest.er1
17778   cat conftest.err >&5
17779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17780   (exit $ac_status); } &&
17781          { ac_try='test -z "$ac_c_werror_flag"
17782                          || test ! -s conftest.err'
17783   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17784   (eval $ac_try) 2>&5
17785   ac_status=$?
17786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17787   (exit $ac_status); }; } &&
17788          { ac_try='test -s conftest$ac_exeext'
17789   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17790   (eval $ac_try) 2>&5
17791   ac_status=$?
17792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17793   (exit $ac_status); }; }; then
17794   ol_cv_resolver_resolv=yes
17795 else
17796   echo "$as_me: failed program was:" >&5
17797 sed 's/^/| /' conftest.$ac_ext >&5
17798
17799 ol_cv_resolver_resolv=no
17800 fi
17801 rm -f conftest.err conftest.$ac_objext \
17802       conftest$ac_exeext conftest.$ac_ext
17803
17804         LIBS="$ol_LIBS"
17805
17806 fi
17807 echo "$as_me:$LINENO: result: $ol_cv_resolver_resolv" >&5
17808 echo "${ECHO_T}$ol_cv_resolver_resolv" >&6
17809
17810         if test $ol_cv_resolver_resolv = yes ; then
17811                 ol_cv_lib_resolver=-lresolv
17812         fi
17813 fi
17814
17815 if test $ol_cv_lib_resolver = no ; then
17816         echo "$as_me:$LINENO: checking for resolver link (-lbind)" >&5
17817 echo $ECHO_N "checking for resolver link (-lbind)... $ECHO_C" >&6
17818 if test "${ol_cv_resolver_bind+set}" = set; then
17819   echo $ECHO_N "(cached) $ECHO_C" >&6
17820 else
17821
17822         ol_RESOLVER_LIB=-lbind
17823         ol_LIBS=$LIBS
17824         LIBS="$ol_RESOLVER_LIB $LIBS"
17825
17826         cat >conftest.$ac_ext <<_ACEOF
17827 /* confdefs.h.  */
17828 _ACEOF
17829 cat confdefs.h >>conftest.$ac_ext
17830 cat >>conftest.$ac_ext <<_ACEOF
17831 /* end confdefs.h.  */
17832
17833 #ifdef HAVE_SYS_TYPES_H
17834 #       include <sys/types.h>
17835 #endif
17836 #include <netinet/in.h>
17837 #ifdef HAVE_ARPA_NAMESER_H
17838 #       include <arpa/nameser.h>
17839 #endif
17840 #ifdef HAVE_RESOLV_H
17841 #       include <resolv.h>
17842 #endif
17843
17844 int
17845 main ()
17846 {
17847 {
17848         int len, status;
17849         char *request = NULL;
17850         unsigned char reply[64*1024];
17851         unsigned char host[64*1024];
17852         unsigned char *p;
17853
17854 #ifdef NS_HFIXEDSZ
17855         /* Bind 8/9 interface */
17856         len = res_query(request, ns_c_in, ns_t_srv, reply, sizeof(reply));
17857 #else
17858         /* Bind 4 interface */
17859 # ifndef T_SRV
17860 #  define T_SRV 33
17861 # endif
17862         len = res_query(request, C_IN, T_SRV, reply, sizeof(reply));
17863 #endif
17864         p = reply;
17865 #ifdef NS_HFIXEDSZ
17866         /* Bind 8/9 interface */
17867         p += NS_HFIXEDSZ;
17868 #elif defined(HFIXEDSZ)
17869         /* Bind 4 interface w/ HFIXEDSZ */
17870         p += HFIXEDSZ;
17871 #else
17872         /* Bind 4 interface w/o HFIXEDSZ */
17873         p += sizeof(HEADER);
17874 #endif
17875         status = dn_expand( reply, reply+len, p, host, sizeof(host));
17876 }
17877   ;
17878   return 0;
17879 }
17880 _ACEOF
17881 rm -f conftest.$ac_objext conftest$ac_exeext
17882 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17883   (eval $ac_link) 2>conftest.er1
17884   ac_status=$?
17885   grep -v '^ *+' conftest.er1 >conftest.err
17886   rm -f conftest.er1
17887   cat conftest.err >&5
17888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17889   (exit $ac_status); } &&
17890          { ac_try='test -z "$ac_c_werror_flag"
17891                          || test ! -s conftest.err'
17892   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17893   (eval $ac_try) 2>&5
17894   ac_status=$?
17895   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17896   (exit $ac_status); }; } &&
17897          { ac_try='test -s conftest$ac_exeext'
17898   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17899   (eval $ac_try) 2>&5
17900   ac_status=$?
17901   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17902   (exit $ac_status); }; }; then
17903   ol_cv_resolver_bind=yes
17904 else
17905   echo "$as_me: failed program was:" >&5
17906 sed 's/^/| /' conftest.$ac_ext >&5
17907
17908 ol_cv_resolver_bind=no
17909 fi
17910 rm -f conftest.err conftest.$ac_objext \
17911       conftest$ac_exeext conftest.$ac_ext
17912
17913         LIBS="$ol_LIBS"
17914
17915 fi
17916 echo "$as_me:$LINENO: result: $ol_cv_resolver_bind" >&5
17917 echo "${ECHO_T}$ol_cv_resolver_bind" >&6
17918
17919         if test $ol_cv_resolver_bind = yes ; then
17920                 ol_cv_lib_resolver=-lbind
17921         fi
17922 fi
17923
17924
17925
17926 ol_link_dnssrv=no
17927 if test "$ol_cv_lib_resolver" != no ; then
17928
17929 cat >>confdefs.h <<\_ACEOF
17930 #define HAVE_RES_QUERY 1
17931 _ACEOF
17932
17933
17934         if test "$ol_enable_dnssrv" != no ; then
17935                 ol_link_dnssrv=yes
17936         fi
17937
17938         if test "$ol_cv_lib_resolver" != yes ; then
17939                 LIBS="$ol_cv_lib_resolver $LIBS"
17940         fi
17941 fi
17942
17943 if test "$ol_enable_dnssrv" = yes || test "$ol_enable_dnssrv" = mod ; then
17944         if test "$ol_link_dnssrv" = no ; then
17945                 { { echo "$as_me:$LINENO: error: DNSSRV requires res_query()" >&5
17946 echo "$as_me: error: DNSSRV requires res_query()" >&2;}
17947    { (exit 1); exit 1; }; }
17948         fi
17949 else
17950         ol_enable_dnssrv=no
17951 fi
17952
17953
17954 for ac_func in hstrerror
17955 do
17956 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17957 echo "$as_me:$LINENO: checking for $ac_func" >&5
17958 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17959 if eval "test \"\${$as_ac_var+set}\" = set"; then
17960   echo $ECHO_N "(cached) $ECHO_C" >&6
17961 else
17962   cat >conftest.$ac_ext <<_ACEOF
17963 /* confdefs.h.  */
17964 _ACEOF
17965 cat confdefs.h >>conftest.$ac_ext
17966 cat >>conftest.$ac_ext <<_ACEOF
17967 /* end confdefs.h.  */
17968 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17969    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17970 #define $ac_func innocuous_$ac_func
17971
17972 /* System header to define __stub macros and hopefully few prototypes,
17973     which can conflict with char $ac_func (); below.
17974     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17975     <limits.h> exists even on freestanding compilers.  */
17976
17977 #ifdef __STDC__
17978 # include <limits.h>
17979 #else
17980 # include <assert.h>
17981 #endif
17982
17983 #undef $ac_func
17984
17985 /* Override any gcc2 internal prototype to avoid an error.  */
17986 #ifdef __cplusplus
17987 extern "C"
17988 {
17989 #endif
17990 /* We use char because int might match the return type of a gcc2
17991    builtin and then its argument prototype would still apply.  */
17992 char $ac_func ();
17993 /* The GNU C library defines this for functions which it implements
17994     to always fail with ENOSYS.  Some functions are actually named
17995     something starting with __ and the normal name is an alias.  */
17996 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17997 choke me
17998 #else
17999 char (*f) () = $ac_func;
18000 #endif
18001 #ifdef __cplusplus
18002 }
18003 #endif
18004
18005 int
18006 main ()
18007 {
18008 return f != $ac_func;
18009   ;
18010   return 0;
18011 }
18012 _ACEOF
18013 rm -f conftest.$ac_objext conftest$ac_exeext
18014 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18015   (eval $ac_link) 2>conftest.er1
18016   ac_status=$?
18017   grep -v '^ *+' conftest.er1 >conftest.err
18018   rm -f conftest.er1
18019   cat conftest.err >&5
18020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18021   (exit $ac_status); } &&
18022          { ac_try='test -z "$ac_c_werror_flag"
18023                          || test ! -s conftest.err'
18024   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18025   (eval $ac_try) 2>&5
18026   ac_status=$?
18027   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18028   (exit $ac_status); }; } &&
18029          { ac_try='test -s conftest$ac_exeext'
18030   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18031   (eval $ac_try) 2>&5
18032   ac_status=$?
18033   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18034   (exit $ac_status); }; }; then
18035   eval "$as_ac_var=yes"
18036 else
18037   echo "$as_me: failed program was:" >&5
18038 sed 's/^/| /' conftest.$ac_ext >&5
18039
18040 eval "$as_ac_var=no"
18041 fi
18042 rm -f conftest.err conftest.$ac_objext \
18043       conftest$ac_exeext conftest.$ac_ext
18044 fi
18045 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
18046 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
18047 if test `eval echo '${'$as_ac_var'}'` = yes; then
18048   cat >>confdefs.h <<_ACEOF
18049 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18050 _ACEOF
18051
18052 fi
18053 done
18054
18055
18056
18057
18058
18059
18060 for ac_func in getaddrinfo getnameinfo gai_strerror inet_ntop
18061 do
18062 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18063 echo "$as_me:$LINENO: checking for $ac_func" >&5
18064 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
18065 if eval "test \"\${$as_ac_var+set}\" = set"; then
18066   echo $ECHO_N "(cached) $ECHO_C" >&6
18067 else
18068   cat >conftest.$ac_ext <<_ACEOF
18069 /* confdefs.h.  */
18070 _ACEOF
18071 cat confdefs.h >>conftest.$ac_ext
18072 cat >>conftest.$ac_ext <<_ACEOF
18073 /* end confdefs.h.  */
18074 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18075    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18076 #define $ac_func innocuous_$ac_func
18077
18078 /* System header to define __stub macros and hopefully few prototypes,
18079     which can conflict with char $ac_func (); below.
18080     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18081     <limits.h> exists even on freestanding compilers.  */
18082
18083 #ifdef __STDC__
18084 # include <limits.h>
18085 #else
18086 # include <assert.h>
18087 #endif
18088
18089 #undef $ac_func
18090
18091 /* Override any gcc2 internal prototype to avoid an error.  */
18092 #ifdef __cplusplus
18093 extern "C"
18094 {
18095 #endif
18096 /* We use char because int might match the return type of a gcc2
18097    builtin and then its argument prototype would still apply.  */
18098 char $ac_func ();
18099 /* The GNU C library defines this for functions which it implements
18100     to always fail with ENOSYS.  Some functions are actually named
18101     something starting with __ and the normal name is an alias.  */
18102 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
18103 choke me
18104 #else
18105 char (*f) () = $ac_func;
18106 #endif
18107 #ifdef __cplusplus
18108 }
18109 #endif
18110
18111 int
18112 main ()
18113 {
18114 return f != $ac_func;
18115   ;
18116   return 0;
18117 }
18118 _ACEOF
18119 rm -f conftest.$ac_objext conftest$ac_exeext
18120 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18121   (eval $ac_link) 2>conftest.er1
18122   ac_status=$?
18123   grep -v '^ *+' conftest.er1 >conftest.err
18124   rm -f conftest.er1
18125   cat conftest.err >&5
18126   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18127   (exit $ac_status); } &&
18128          { ac_try='test -z "$ac_c_werror_flag"
18129                          || test ! -s conftest.err'
18130   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18131   (eval $ac_try) 2>&5
18132   ac_status=$?
18133   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18134   (exit $ac_status); }; } &&
18135          { ac_try='test -s conftest$ac_exeext'
18136   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18137   (eval $ac_try) 2>&5
18138   ac_status=$?
18139   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18140   (exit $ac_status); }; }; then
18141   eval "$as_ac_var=yes"
18142 else
18143   echo "$as_me: failed program was:" >&5
18144 sed 's/^/| /' conftest.$ac_ext >&5
18145
18146 eval "$as_ac_var=no"
18147 fi
18148 rm -f conftest.err conftest.$ac_objext \
18149       conftest$ac_exeext conftest.$ac_ext
18150 fi
18151 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
18152 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
18153 if test `eval echo '${'$as_ac_var'}'` = yes; then
18154   cat >>confdefs.h <<_ACEOF
18155 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18156 _ACEOF
18157
18158 fi
18159 done
18160
18161
18162 ol_link_ipv6=no
18163 if test $ac_cv_func_getaddrinfo = no || test $ac_cv_func_inet_ntop = no ; then
18164         if test $ol_enable_ipv6 = yes ; then
18165                 { { echo "$as_me:$LINENO: error: IPv6 support requires getaddrinfo() and inet_ntop()" >&5
18166 echo "$as_me: error: IPv6 support requires getaddrinfo() and inet_ntop()" >&2;}
18167    { (exit 1); exit 1; }; }
18168         fi
18169 elif test $ol_enable_ipv6 != no ; then
18170         echo "$as_me:$LINENO: checking INET6_ADDRSTRLEN" >&5
18171 echo $ECHO_N "checking INET6_ADDRSTRLEN... $ECHO_C" >&6
18172 if test "${ol_cv_inet6_addrstrlen+set}" = set; then
18173   echo $ECHO_N "(cached) $ECHO_C" >&6
18174 else
18175
18176                 cat >conftest.$ac_ext <<_ACEOF
18177 /* confdefs.h.  */
18178 _ACEOF
18179 cat confdefs.h >>conftest.$ac_ext
18180 cat >>conftest.$ac_ext <<_ACEOF
18181 /* end confdefs.h.  */
18182
18183 #                       include <netinet/in.h>
18184 #                       ifdef INET6_ADDRSTRLEN
18185                                 __has_inet6_addrstrlen__;
18186 #                       endif
18187
18188 _ACEOF
18189 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18190   $EGREP "__has_inet6_addrstrlen__" >/dev/null 2>&1; then
18191   ol_cv_inet6_addrstrlen=yes
18192 else
18193   ol_cv_inet6_addrstrlen=no
18194 fi
18195 rm -f conftest*
18196
18197 fi
18198 echo "$as_me:$LINENO: result: $ol_cv_inet6_addrstrlen" >&5
18199 echo "${ECHO_T}$ol_cv_inet6_addrstrlen" >&6
18200
18201
18202         echo "$as_me:$LINENO: checking struct sockaddr_storage" >&5
18203 echo $ECHO_N "checking struct sockaddr_storage... $ECHO_C" >&6
18204 if test "${ol_cv_struct_sockaddr_storage+set}" = set; then
18205   echo $ECHO_N "(cached) $ECHO_C" >&6
18206 else
18207
18208                 cat >conftest.$ac_ext <<_ACEOF
18209 /* confdefs.h.  */
18210 _ACEOF
18211 cat confdefs.h >>conftest.$ac_ext
18212 cat >>conftest.$ac_ext <<_ACEOF
18213 /* end confdefs.h.  */
18214
18215 #include <sys/types.h>
18216 #include <sys/socket.h>
18217
18218 int
18219 main ()
18220 {
18221
18222                         struct sockaddr_storage ss;
18223
18224   ;
18225   return 0;
18226 }
18227 _ACEOF
18228 rm -f conftest.$ac_objext
18229 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18230   (eval $ac_compile) 2>conftest.er1
18231   ac_status=$?
18232   grep -v '^ *+' conftest.er1 >conftest.err
18233   rm -f conftest.er1
18234   cat conftest.err >&5
18235   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18236   (exit $ac_status); } &&
18237          { ac_try='test -z "$ac_c_werror_flag"
18238                          || test ! -s conftest.err'
18239   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18240   (eval $ac_try) 2>&5
18241   ac_status=$?
18242   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18243   (exit $ac_status); }; } &&
18244          { ac_try='test -s conftest.$ac_objext'
18245   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18246   (eval $ac_try) 2>&5
18247   ac_status=$?
18248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18249   (exit $ac_status); }; }; then
18250   ol_cv_struct_sockaddr_storage=yes
18251 else
18252   echo "$as_me: failed program was:" >&5
18253 sed 's/^/| /' conftest.$ac_ext >&5
18254
18255 ol_cv_struct_sockaddr_storage=no
18256 fi
18257 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18258 fi
18259 echo "$as_me:$LINENO: result: $ol_cv_struct_sockaddr_storage" >&5
18260 echo "${ECHO_T}$ol_cv_struct_sockaddr_storage" >&6
18261
18262         if test $ol_cv_inet6_addrstrlen = yes &&
18263            test $ol_cv_struct_sockaddr_storage = yes ; then
18264                 ol_link_ipv6=yes
18265         elif test $ol_enable_ipv6 = yes &&
18266              test $ol_cv_inet6_addrstrlen = no ; then
18267                 { { echo "$as_me:$LINENO: error: IPv6 support requires INET6_ADDRSTRLEN" >&5
18268 echo "$as_me: error: IPv6 support requires INET6_ADDRSTRLEN" >&2;}
18269    { (exit 1); exit 1; }; }
18270         elif test $ol_enable_ipv6 = yes &&
18271              test $ol_cv_struct_sockaddr_storage = no ; then
18272                 { { echo "$as_me:$LINENO: error: IPv6 support requires struct sockaddr_storage" >&5
18273 echo "$as_me: error: IPv6 support requires struct sockaddr_storage" >&2;}
18274    { (exit 1); exit 1; }; }
18275         fi
18276 fi
18277
18278 if test $ol_enable_local != no ; then
18279
18280 for ac_header in sys/un.h
18281 do
18282 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18283 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18284   echo "$as_me:$LINENO: checking for $ac_header" >&5
18285 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18286 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18287   echo $ECHO_N "(cached) $ECHO_C" >&6
18288 fi
18289 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18290 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18291 else
18292   # Is the header compilable?
18293 echo "$as_me:$LINENO: checking $ac_header usability" >&5
18294 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18295 cat >conftest.$ac_ext <<_ACEOF
18296 /* confdefs.h.  */
18297 _ACEOF
18298 cat confdefs.h >>conftest.$ac_ext
18299 cat >>conftest.$ac_ext <<_ACEOF
18300 /* end confdefs.h.  */
18301 $ac_includes_default
18302 #include <$ac_header>
18303 _ACEOF
18304 rm -f conftest.$ac_objext
18305 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18306   (eval $ac_compile) 2>conftest.er1
18307   ac_status=$?
18308   grep -v '^ *+' conftest.er1 >conftest.err
18309   rm -f conftest.er1
18310   cat conftest.err >&5
18311   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18312   (exit $ac_status); } &&
18313          { ac_try='test -z "$ac_c_werror_flag"
18314                          || test ! -s conftest.err'
18315   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18316   (eval $ac_try) 2>&5
18317   ac_status=$?
18318   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18319   (exit $ac_status); }; } &&
18320          { ac_try='test -s conftest.$ac_objext'
18321   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18322   (eval $ac_try) 2>&5
18323   ac_status=$?
18324   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18325   (exit $ac_status); }; }; then
18326   ac_header_compiler=yes
18327 else
18328   echo "$as_me: failed program was:" >&5
18329 sed 's/^/| /' conftest.$ac_ext >&5
18330
18331 ac_header_compiler=no
18332 fi
18333 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18334 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18335 echo "${ECHO_T}$ac_header_compiler" >&6
18336
18337 # Is the header present?
18338 echo "$as_me:$LINENO: checking $ac_header presence" >&5
18339 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18340 cat >conftest.$ac_ext <<_ACEOF
18341 /* confdefs.h.  */
18342 _ACEOF
18343 cat confdefs.h >>conftest.$ac_ext
18344 cat >>conftest.$ac_ext <<_ACEOF
18345 /* end confdefs.h.  */
18346 #include <$ac_header>
18347 _ACEOF
18348 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18349   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18350   ac_status=$?
18351   grep -v '^ *+' conftest.er1 >conftest.err
18352   rm -f conftest.er1
18353   cat conftest.err >&5
18354   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18355   (exit $ac_status); } >/dev/null; then
18356   if test -s conftest.err; then
18357     ac_cpp_err=$ac_c_preproc_warn_flag
18358     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
18359   else
18360     ac_cpp_err=
18361   fi
18362 else
18363   ac_cpp_err=yes
18364 fi
18365 if test -z "$ac_cpp_err"; then
18366   ac_header_preproc=yes
18367 else
18368   echo "$as_me: failed program was:" >&5
18369 sed 's/^/| /' conftest.$ac_ext >&5
18370
18371   ac_header_preproc=no
18372 fi
18373 rm -f conftest.err conftest.$ac_ext
18374 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18375 echo "${ECHO_T}$ac_header_preproc" >&6
18376
18377 # So?  What about this header?
18378 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18379   yes:no: )
18380     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18381 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18382     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18383 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18384     ac_header_preproc=yes
18385     ;;
18386   no:yes:* )
18387     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18388 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
18389     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
18390 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
18391     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18392 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18393     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
18394 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
18395     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18396 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18397     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18398 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
18399     (
18400       cat <<\_ASBOX
18401 ## --------------------------------------------- ##
18402 ## Report this to <http://www.openldap.org/its/> ##
18403 ## --------------------------------------------- ##
18404 _ASBOX
18405     ) |
18406       sed "s/^/$as_me: WARNING:     /" >&2
18407     ;;
18408 esac
18409 echo "$as_me:$LINENO: checking for $ac_header" >&5
18410 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18411 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18412   echo $ECHO_N "(cached) $ECHO_C" >&6
18413 else
18414   eval "$as_ac_Header=\$ac_header_preproc"
18415 fi
18416 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18417 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18418
18419 fi
18420 if test `eval echo '${'$as_ac_Header'}'` = yes; then
18421   cat >>confdefs.h <<_ACEOF
18422 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18423 _ACEOF
18424
18425 fi
18426
18427 done
18428
18429
18430         if test $ol_enable_local = auto ; then
18431                 ol_enable_local=$ac_cv_header_sys_un_h
18432         elif test $ac_cv_header_sys_un_h = no ; then
18433                 { { echo "$as_me:$LINENO: error: AF_LOCAL domain support requires sys/un.h" >&5
18434 echo "$as_me: error: AF_LOCAL domain support requires sys/un.h" >&2;}
18435    { (exit 1); exit 1; }; }
18436         fi
18437 fi
18438
18439
18440 if test $ol_with_tls = yes ; then
18441         ol_with_tls=auto
18442 fi
18443
18444 ol_link_tls=no
18445 if test $ol_with_tls = openssl || test $ol_with_tls = auto ; then
18446
18447 for ac_header in openssl/ssl.h
18448 do
18449 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18450 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18451   echo "$as_me:$LINENO: checking for $ac_header" >&5
18452 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18453 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18454   echo $ECHO_N "(cached) $ECHO_C" >&6
18455 fi
18456 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18457 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18458 else
18459   # Is the header compilable?
18460 echo "$as_me:$LINENO: checking $ac_header usability" >&5
18461 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18462 cat >conftest.$ac_ext <<_ACEOF
18463 /* confdefs.h.  */
18464 _ACEOF
18465 cat confdefs.h >>conftest.$ac_ext
18466 cat >>conftest.$ac_ext <<_ACEOF
18467 /* end confdefs.h.  */
18468 $ac_includes_default
18469 #include <$ac_header>
18470 _ACEOF
18471 rm -f conftest.$ac_objext
18472 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18473   (eval $ac_compile) 2>conftest.er1
18474   ac_status=$?
18475   grep -v '^ *+' conftest.er1 >conftest.err
18476   rm -f conftest.er1
18477   cat conftest.err >&5
18478   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18479   (exit $ac_status); } &&
18480          { ac_try='test -z "$ac_c_werror_flag"
18481                          || test ! -s conftest.err'
18482   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18483   (eval $ac_try) 2>&5
18484   ac_status=$?
18485   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18486   (exit $ac_status); }; } &&
18487          { ac_try='test -s conftest.$ac_objext'
18488   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18489   (eval $ac_try) 2>&5
18490   ac_status=$?
18491   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18492   (exit $ac_status); }; }; then
18493   ac_header_compiler=yes
18494 else
18495   echo "$as_me: failed program was:" >&5
18496 sed 's/^/| /' conftest.$ac_ext >&5
18497
18498 ac_header_compiler=no
18499 fi
18500 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18501 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18502 echo "${ECHO_T}$ac_header_compiler" >&6
18503
18504 # Is the header present?
18505 echo "$as_me:$LINENO: checking $ac_header presence" >&5
18506 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18507 cat >conftest.$ac_ext <<_ACEOF
18508 /* confdefs.h.  */
18509 _ACEOF
18510 cat confdefs.h >>conftest.$ac_ext
18511 cat >>conftest.$ac_ext <<_ACEOF
18512 /* end confdefs.h.  */
18513 #include <$ac_header>
18514 _ACEOF
18515 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18516   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18517   ac_status=$?
18518   grep -v '^ *+' conftest.er1 >conftest.err
18519   rm -f conftest.er1
18520   cat conftest.err >&5
18521   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18522   (exit $ac_status); } >/dev/null; then
18523   if test -s conftest.err; then
18524     ac_cpp_err=$ac_c_preproc_warn_flag
18525     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
18526   else
18527     ac_cpp_err=
18528   fi
18529 else
18530   ac_cpp_err=yes
18531 fi
18532 if test -z "$ac_cpp_err"; then
18533   ac_header_preproc=yes
18534 else
18535   echo "$as_me: failed program was:" >&5
18536 sed 's/^/| /' conftest.$ac_ext >&5
18537
18538   ac_header_preproc=no
18539 fi
18540 rm -f conftest.err conftest.$ac_ext
18541 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18542 echo "${ECHO_T}$ac_header_preproc" >&6
18543
18544 # So?  What about this header?
18545 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18546   yes:no: )
18547     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18548 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18549     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18550 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18551     ac_header_preproc=yes
18552     ;;
18553   no:yes:* )
18554     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18555 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
18556     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
18557 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
18558     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18559 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18560     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
18561 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
18562     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18563 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18564     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18565 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
18566     (
18567       cat <<\_ASBOX
18568 ## --------------------------------------------- ##
18569 ## Report this to <http://www.openldap.org/its/> ##
18570 ## --------------------------------------------- ##
18571 _ASBOX
18572     ) |
18573       sed "s/^/$as_me: WARNING:     /" >&2
18574     ;;
18575 esac
18576 echo "$as_me:$LINENO: checking for $ac_header" >&5
18577 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18578 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18579   echo $ECHO_N "(cached) $ECHO_C" >&6
18580 else
18581   eval "$as_ac_Header=\$ac_header_preproc"
18582 fi
18583 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18584 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18585
18586 fi
18587 if test `eval echo '${'$as_ac_Header'}'` = yes; then
18588   cat >>confdefs.h <<_ACEOF
18589 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18590 _ACEOF
18591
18592 fi
18593
18594 done
18595
18596
18597         if test $ac_cv_header_openssl_ssl_h = yes ; then
18598                 echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
18599 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6
18600 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
18601   echo $ECHO_N "(cached) $ECHO_C" >&6
18602 else
18603   ac_check_lib_save_LIBS=$LIBS
18604 LIBS="-lssl -lcrypto $LIBS"
18605 cat >conftest.$ac_ext <<_ACEOF
18606 /* confdefs.h.  */
18607 _ACEOF
18608 cat confdefs.h >>conftest.$ac_ext
18609 cat >>conftest.$ac_ext <<_ACEOF
18610 /* end confdefs.h.  */
18611
18612 /* Override any gcc2 internal prototype to avoid an error.  */
18613 #ifdef __cplusplus
18614 extern "C"
18615 #endif
18616 /* We use char because int might match the return type of a gcc2
18617    builtin and then its argument prototype would still apply.  */
18618 char SSL_library_init ();
18619 int
18620 main ()
18621 {
18622 SSL_library_init ();
18623   ;
18624   return 0;
18625 }
18626 _ACEOF
18627 rm -f conftest.$ac_objext conftest$ac_exeext
18628 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18629   (eval $ac_link) 2>conftest.er1
18630   ac_status=$?
18631   grep -v '^ *+' conftest.er1 >conftest.err
18632   rm -f conftest.er1
18633   cat conftest.err >&5
18634   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18635   (exit $ac_status); } &&
18636          { ac_try='test -z "$ac_c_werror_flag"
18637                          || test ! -s conftest.err'
18638   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18639   (eval $ac_try) 2>&5
18640   ac_status=$?
18641   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18642   (exit $ac_status); }; } &&
18643          { ac_try='test -s conftest$ac_exeext'
18644   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18645   (eval $ac_try) 2>&5
18646   ac_status=$?
18647   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18648   (exit $ac_status); }; }; then
18649   ac_cv_lib_ssl_SSL_library_init=yes
18650 else
18651   echo "$as_me: failed program was:" >&5
18652 sed 's/^/| /' conftest.$ac_ext >&5
18653
18654 ac_cv_lib_ssl_SSL_library_init=no
18655 fi
18656 rm -f conftest.err conftest.$ac_objext \
18657       conftest$ac_exeext conftest.$ac_ext
18658 LIBS=$ac_check_lib_save_LIBS
18659 fi
18660 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
18661 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6
18662 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
18663   have_openssl=yes
18664                         need_rsaref=no
18665 else
18666   have_openssl=no
18667 fi
18668
18669
18670                 if test $have_openssl = no ; then
18671                         echo "$as_me:$LINENO: checking for ssl3_accept in -lssl" >&5
18672 echo $ECHO_N "checking for ssl3_accept in -lssl... $ECHO_C" >&6
18673 if test "${ac_cv_lib_ssl_ssl3_accept+set}" = set; then
18674   echo $ECHO_N "(cached) $ECHO_C" >&6
18675 else
18676   ac_check_lib_save_LIBS=$LIBS
18677 LIBS="-lssl -lcrypto -lRSAglue -lrsaref $LIBS"
18678 cat >conftest.$ac_ext <<_ACEOF
18679 /* confdefs.h.  */
18680 _ACEOF
18681 cat confdefs.h >>conftest.$ac_ext
18682 cat >>conftest.$ac_ext <<_ACEOF
18683 /* end confdefs.h.  */
18684
18685 /* Override any gcc2 internal prototype to avoid an error.  */
18686 #ifdef __cplusplus
18687 extern "C"
18688 #endif
18689 /* We use char because int might match the return type of a gcc2
18690    builtin and then its argument prototype would still apply.  */
18691 char ssl3_accept ();
18692 int
18693 main ()
18694 {
18695 ssl3_accept ();
18696   ;
18697   return 0;
18698 }
18699 _ACEOF
18700 rm -f conftest.$ac_objext conftest$ac_exeext
18701 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18702   (eval $ac_link) 2>conftest.er1
18703   ac_status=$?
18704   grep -v '^ *+' conftest.er1 >conftest.err
18705   rm -f conftest.er1
18706   cat conftest.err >&5
18707   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18708   (exit $ac_status); } &&
18709          { ac_try='test -z "$ac_c_werror_flag"
18710                          || test ! -s conftest.err'
18711   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18712   (eval $ac_try) 2>&5
18713   ac_status=$?
18714   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18715   (exit $ac_status); }; } &&
18716          { ac_try='test -s conftest$ac_exeext'
18717   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18718   (eval $ac_try) 2>&5
18719   ac_status=$?
18720   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18721   (exit $ac_status); }; }; then
18722   ac_cv_lib_ssl_ssl3_accept=yes
18723 else
18724   echo "$as_me: failed program was:" >&5
18725 sed 's/^/| /' conftest.$ac_ext >&5
18726
18727 ac_cv_lib_ssl_ssl3_accept=no
18728 fi
18729 rm -f conftest.err conftest.$ac_objext \
18730       conftest$ac_exeext conftest.$ac_ext
18731 LIBS=$ac_check_lib_save_LIBS
18732 fi
18733 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_ssl3_accept" >&5
18734 echo "${ECHO_T}$ac_cv_lib_ssl_ssl3_accept" >&6
18735 if test $ac_cv_lib_ssl_ssl3_accept = yes; then
18736   have_openssl=yes
18737                                 need_rsaref=yes
18738 else
18739   have_openssl=no
18740 fi
18741
18742                 fi
18743
18744                 if test $have_openssl = yes ; then
18745                         ol_with_tls=openssl
18746                         ol_link_tls=yes
18747
18748
18749 cat >>confdefs.h <<\_ACEOF
18750 #define HAVE_OPENSSL 1
18751 _ACEOF
18752
18753
18754                         if test $need_rsaref = yes; then
18755
18756 cat >>confdefs.h <<\_ACEOF
18757 #define HAVE_RSAREF 1
18758 _ACEOF
18759
18760
18761                                 TLS_LIBS="-lssl -lcrypto -lRSAglue -lrsaref"
18762                         else
18763                                 TLS_LIBS="-lssl -lcrypto"
18764                         fi
18765
18766                         echo "$as_me:$LINENO: checking OpenSSL library version (CRL checking capability)" >&5
18767 echo $ECHO_N "checking OpenSSL library version (CRL checking capability)... $ECHO_C" >&6
18768 if test "${ol_cv_ssl_crl_compat+set}" = set; then
18769   echo $ECHO_N "(cached) $ECHO_C" >&6
18770 else
18771
18772                 cat >conftest.$ac_ext <<_ACEOF
18773 /* confdefs.h.  */
18774 _ACEOF
18775 cat confdefs.h >>conftest.$ac_ext
18776 cat >>conftest.$ac_ext <<_ACEOF
18777 /* end confdefs.h.  */
18778
18779 #ifdef HAVE_OPENSSL_SSL_H
18780 #include <openssl/ssl.h>
18781 #endif
18782
18783 /* Require 0.9.7d+ */
18784 #if OPENSSL_VERSION_NUMBER >= 0x0090704fL
18785         char *__ssl_compat = "0.9.7d";
18786 #endif
18787
18788 _ACEOF
18789 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18790   $EGREP "__ssl_compat" >/dev/null 2>&1; then
18791   ol_cv_ssl_crl_compat=yes
18792 else
18793   ol_cv_ssl_crl_compat=no
18794 fi
18795 rm -f conftest*
18796
18797 fi
18798 echo "$as_me:$LINENO: result: $ol_cv_ssl_crl_compat" >&5
18799 echo "${ECHO_T}$ol_cv_ssl_crl_compat" >&6
18800
18801                         if test $ol_cv_ssl_crl_compat = yes ; then
18802
18803 cat >>confdefs.h <<\_ACEOF
18804 #define HAVE_OPENSSL_CRL 1
18805 _ACEOF
18806
18807                         fi
18808                 fi
18809         fi
18810 fi
18811
18812 if test $ol_link_tls = no ; then
18813         if test $ol_with_tls = gnutls || test $ol_with_tls = auto ; then
18814
18815 for ac_header in gnutls/gnutls.h
18816 do
18817 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18818 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18819   echo "$as_me:$LINENO: checking for $ac_header" >&5
18820 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18821 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18822   echo $ECHO_N "(cached) $ECHO_C" >&6
18823 fi
18824 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18825 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18826 else
18827   # Is the header compilable?
18828 echo "$as_me:$LINENO: checking $ac_header usability" >&5
18829 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18830 cat >conftest.$ac_ext <<_ACEOF
18831 /* confdefs.h.  */
18832 _ACEOF
18833 cat confdefs.h >>conftest.$ac_ext
18834 cat >>conftest.$ac_ext <<_ACEOF
18835 /* end confdefs.h.  */
18836 $ac_includes_default
18837 #include <$ac_header>
18838 _ACEOF
18839 rm -f conftest.$ac_objext
18840 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18841   (eval $ac_compile) 2>conftest.er1
18842   ac_status=$?
18843   grep -v '^ *+' conftest.er1 >conftest.err
18844   rm -f conftest.er1
18845   cat conftest.err >&5
18846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18847   (exit $ac_status); } &&
18848          { ac_try='test -z "$ac_c_werror_flag"
18849                          || test ! -s conftest.err'
18850   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18851   (eval $ac_try) 2>&5
18852   ac_status=$?
18853   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18854   (exit $ac_status); }; } &&
18855          { ac_try='test -s conftest.$ac_objext'
18856   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18857   (eval $ac_try) 2>&5
18858   ac_status=$?
18859   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18860   (exit $ac_status); }; }; then
18861   ac_header_compiler=yes
18862 else
18863   echo "$as_me: failed program was:" >&5
18864 sed 's/^/| /' conftest.$ac_ext >&5
18865
18866 ac_header_compiler=no
18867 fi
18868 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18869 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18870 echo "${ECHO_T}$ac_header_compiler" >&6
18871
18872 # Is the header present?
18873 echo "$as_me:$LINENO: checking $ac_header presence" >&5
18874 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18875 cat >conftest.$ac_ext <<_ACEOF
18876 /* confdefs.h.  */
18877 _ACEOF
18878 cat confdefs.h >>conftest.$ac_ext
18879 cat >>conftest.$ac_ext <<_ACEOF
18880 /* end confdefs.h.  */
18881 #include <$ac_header>
18882 _ACEOF
18883 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18884   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18885   ac_status=$?
18886   grep -v '^ *+' conftest.er1 >conftest.err
18887   rm -f conftest.er1
18888   cat conftest.err >&5
18889   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18890   (exit $ac_status); } >/dev/null; then
18891   if test -s conftest.err; then
18892     ac_cpp_err=$ac_c_preproc_warn_flag
18893     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
18894   else
18895     ac_cpp_err=
18896   fi
18897 else
18898   ac_cpp_err=yes
18899 fi
18900 if test -z "$ac_cpp_err"; then
18901   ac_header_preproc=yes
18902 else
18903   echo "$as_me: failed program was:" >&5
18904 sed 's/^/| /' conftest.$ac_ext >&5
18905
18906   ac_header_preproc=no
18907 fi
18908 rm -f conftest.err conftest.$ac_ext
18909 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18910 echo "${ECHO_T}$ac_header_preproc" >&6
18911
18912 # So?  What about this header?
18913 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18914   yes:no: )
18915     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18916 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18917     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18918 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18919     ac_header_preproc=yes
18920     ;;
18921   no:yes:* )
18922     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18923 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
18924     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
18925 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
18926     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18927 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18928     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
18929 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
18930     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18931 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18932     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18933 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
18934     (
18935       cat <<\_ASBOX
18936 ## --------------------------------------------- ##
18937 ## Report this to <http://www.openldap.org/its/> ##
18938 ## --------------------------------------------- ##
18939 _ASBOX
18940     ) |
18941       sed "s/^/$as_me: WARNING:     /" >&2
18942     ;;
18943 esac
18944 echo "$as_me:$LINENO: checking for $ac_header" >&5
18945 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18946 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18947   echo $ECHO_N "(cached) $ECHO_C" >&6
18948 else
18949   eval "$as_ac_Header=\$ac_header_preproc"
18950 fi
18951 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18952 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18953
18954 fi
18955 if test `eval echo '${'$as_ac_Header'}'` = yes; then
18956   cat >>confdefs.h <<_ACEOF
18957 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18958 _ACEOF
18959
18960 fi
18961
18962 done
18963
18964
18965                 if test $ac_cv_header_gnutls_gnutls_h = yes ; then
18966                         echo "$as_me:$LINENO: checking for gnutls_init in -lgnutls" >&5
18967 echo $ECHO_N "checking for gnutls_init in -lgnutls... $ECHO_C" >&6
18968 if test "${ac_cv_lib_gnutls_gnutls_init+set}" = set; then
18969   echo $ECHO_N "(cached) $ECHO_C" >&6
18970 else
18971   ac_check_lib_save_LIBS=$LIBS
18972 LIBS="-lgnutls  $LIBS"
18973 cat >conftest.$ac_ext <<_ACEOF
18974 /* confdefs.h.  */
18975 _ACEOF
18976 cat confdefs.h >>conftest.$ac_ext
18977 cat >>conftest.$ac_ext <<_ACEOF
18978 /* end confdefs.h.  */
18979
18980 /* Override any gcc2 internal prototype to avoid an error.  */
18981 #ifdef __cplusplus
18982 extern "C"
18983 #endif
18984 /* We use char because int might match the return type of a gcc2
18985    builtin and then its argument prototype would still apply.  */
18986 char gnutls_init ();
18987 int
18988 main ()
18989 {
18990 gnutls_init ();
18991   ;
18992   return 0;
18993 }
18994 _ACEOF
18995 rm -f conftest.$ac_objext conftest$ac_exeext
18996 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18997   (eval $ac_link) 2>conftest.er1
18998   ac_status=$?
18999   grep -v '^ *+' conftest.er1 >conftest.err
19000   rm -f conftest.er1
19001   cat conftest.err >&5
19002   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19003   (exit $ac_status); } &&
19004          { ac_try='test -z "$ac_c_werror_flag"
19005                          || test ! -s conftest.err'
19006   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19007   (eval $ac_try) 2>&5
19008   ac_status=$?
19009   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19010   (exit $ac_status); }; } &&
19011          { ac_try='test -s conftest$ac_exeext'
19012   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19013   (eval $ac_try) 2>&5
19014   ac_status=$?
19015   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19016   (exit $ac_status); }; }; then
19017   ac_cv_lib_gnutls_gnutls_init=yes
19018 else
19019   echo "$as_me: failed program was:" >&5
19020 sed 's/^/| /' conftest.$ac_ext >&5
19021
19022 ac_cv_lib_gnutls_gnutls_init=no
19023 fi
19024 rm -f conftest.err conftest.$ac_objext \
19025       conftest$ac_exeext conftest.$ac_ext
19026 LIBS=$ac_check_lib_save_LIBS
19027 fi
19028 echo "$as_me:$LINENO: result: $ac_cv_lib_gnutls_gnutls_init" >&5
19029 echo "${ECHO_T}$ac_cv_lib_gnutls_gnutls_init" >&6
19030 if test $ac_cv_lib_gnutls_gnutls_init = yes; then
19031   have_gnutls=yes
19032 else
19033   have_gnutls=no
19034 fi
19035
19036
19037                         if test $have_gnutls = yes ; then
19038                                 ol_with_tls=gnutls
19039                                 ol_link_tls=yes
19040
19041                                 TLS_LIBS="-lgnutls"
19042
19043
19044 cat >>confdefs.h <<\_ACEOF
19045 #define HAVE_GNUTLS 1
19046 _ACEOF
19047
19048                         fi
19049                 fi
19050         fi
19051 fi
19052
19053 WITH_TLS=no
19054 if test $ol_link_tls = yes ; then
19055
19056 cat >>confdefs.h <<\_ACEOF
19057 #define HAVE_TLS 1
19058 _ACEOF
19059
19060         WITH_TLS=yes
19061 elif test $ol_with_tls = auto ; then
19062         { echo "$as_me:$LINENO: WARNING: Could not locate TLS/SSL package" >&5
19063 echo "$as_me: WARNING: Could not locate TLS/SSL package" >&2;}
19064         { echo "$as_me:$LINENO: WARNING: TLS data protection not supported!" >&5
19065 echo "$as_me: WARNING: TLS data protection not supported!" >&2;}
19066 elif test $ol_with_tls != no ; then
19067         { { echo "$as_me:$LINENO: error: Could not locate TLS/SSL package" >&5
19068 echo "$as_me: error: Could not locate TLS/SSL package" >&2;}
19069    { (exit 1); exit 1; }; }
19070 else
19071         { echo "$as_me:$LINENO: WARNING: TLS data protection not supported!" >&5
19072 echo "$as_me: WARNING: TLS data protection not supported!" >&2;}
19073 fi
19074
19075 if test $ol_enable_lmpasswd != no; then
19076         if test $ol_link_tls != yes ; then
19077                 { { echo "$as_me:$LINENO: error: LAN Manager passwords require OpenSSL" >&5
19078 echo "$as_me: error: LAN Manager passwords require OpenSSL" >&2;}
19079    { (exit 1); exit 1; }; }
19080         fi
19081
19082
19083 cat >>confdefs.h <<\_ACEOF
19084 #define SLAPD_LMHASH 1
19085 _ACEOF
19086
19087 fi
19088
19089 ol_link_threads=no
19090
19091 case $ol_with_threads in auto | yes | nt)
19092
19093
19094         echo "$as_me:$LINENO: checking for _beginthread" >&5
19095 echo $ECHO_N "checking for _beginthread... $ECHO_C" >&6
19096 if test "${ac_cv_func__beginthread+set}" = set; then
19097   echo $ECHO_N "(cached) $ECHO_C" >&6
19098 else
19099   cat >conftest.$ac_ext <<_ACEOF
19100 /* confdefs.h.  */
19101 _ACEOF
19102 cat confdefs.h >>conftest.$ac_ext
19103 cat >>conftest.$ac_ext <<_ACEOF
19104 /* end confdefs.h.  */
19105 /* Define _beginthread to an innocuous variant, in case <limits.h> declares _beginthread.
19106    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19107 #define _beginthread innocuous__beginthread
19108
19109 /* System header to define __stub macros and hopefully few prototypes,
19110     which can conflict with char _beginthread (); below.
19111     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19112     <limits.h> exists even on freestanding compilers.  */
19113
19114 #ifdef __STDC__
19115 # include <limits.h>
19116 #else
19117 # include <assert.h>
19118 #endif
19119
19120 #undef _beginthread
19121
19122 /* Override any gcc2 internal prototype to avoid an error.  */
19123 #ifdef __cplusplus
19124 extern "C"
19125 {
19126 #endif
19127 /* We use char because int might match the return type of a gcc2
19128    builtin and then its argument prototype would still apply.  */
19129 char _beginthread ();
19130 /* The GNU C library defines this for functions which it implements
19131     to always fail with ENOSYS.  Some functions are actually named
19132     something starting with __ and the normal name is an alias.  */
19133 #if defined (__stub__beginthread) || defined (__stub____beginthread)
19134 choke me
19135 #else
19136 char (*f) () = _beginthread;
19137 #endif
19138 #ifdef __cplusplus
19139 }
19140 #endif
19141
19142 int
19143 main ()
19144 {
19145 return f != _beginthread;
19146   ;
19147   return 0;
19148 }
19149 _ACEOF
19150 rm -f conftest.$ac_objext conftest$ac_exeext
19151 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19152   (eval $ac_link) 2>conftest.er1
19153   ac_status=$?
19154   grep -v '^ *+' conftest.er1 >conftest.err
19155   rm -f conftest.er1
19156   cat conftest.err >&5
19157   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19158   (exit $ac_status); } &&
19159          { ac_try='test -z "$ac_c_werror_flag"
19160                          || test ! -s conftest.err'
19161   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19162   (eval $ac_try) 2>&5
19163   ac_status=$?
19164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19165   (exit $ac_status); }; } &&
19166          { ac_try='test -s conftest$ac_exeext'
19167   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19168   (eval $ac_try) 2>&5
19169   ac_status=$?
19170   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19171   (exit $ac_status); }; }; then
19172   ac_cv_func__beginthread=yes
19173 else
19174   echo "$as_me: failed program was:" >&5
19175 sed 's/^/| /' conftest.$ac_ext >&5
19176
19177 ac_cv_func__beginthread=no
19178 fi
19179 rm -f conftest.err conftest.$ac_objext \
19180       conftest$ac_exeext conftest.$ac_ext
19181 fi
19182 echo "$as_me:$LINENO: result: $ac_cv_func__beginthread" >&5
19183 echo "${ECHO_T}$ac_cv_func__beginthread" >&6
19184
19185
19186         if test $ac_cv_func__beginthread = yes ; then
19187
19188 cat >>confdefs.h <<\_ACEOF
19189 #define HAVE_NT_THREADS 1
19190 _ACEOF
19191
19192                 ol_cv_nt_threads=yes
19193         fi
19194
19195
19196         if test "$ol_cv_nt_threads" = yes ; then
19197                 ol_link_threads=nt
19198                 ol_with_threads=found
19199                 ol_with_yielding_select=yes
19200
19201
19202 cat >>confdefs.h <<\_ACEOF
19203 #define HAVE_NT_SERVICE_MANAGER 1
19204 _ACEOF
19205
19206
19207 cat >>confdefs.h <<\_ACEOF
19208 #define HAVE_NT_EVENT_LOG 1
19209 _ACEOF
19210
19211         fi
19212
19213         if test $ol_with_threads = nt ; then
19214                 { { echo "$as_me:$LINENO: error: could not locate NT Threads" >&5
19215 echo "$as_me: error: could not locate NT Threads" >&2;}
19216    { (exit 1); exit 1; }; }
19217         fi
19218         ;;
19219 esac
19220
19221 case $ol_with_threads in auto | yes | posix)
19222
19223
19224 for ac_header in pthread.h
19225 do
19226 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
19227 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19228   echo "$as_me:$LINENO: checking for $ac_header" >&5
19229 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19230 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19231   echo $ECHO_N "(cached) $ECHO_C" >&6
19232 fi
19233 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19234 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19235 else
19236   # Is the header compilable?
19237 echo "$as_me:$LINENO: checking $ac_header usability" >&5
19238 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19239 cat >conftest.$ac_ext <<_ACEOF
19240 /* confdefs.h.  */
19241 _ACEOF
19242 cat confdefs.h >>conftest.$ac_ext
19243 cat >>conftest.$ac_ext <<_ACEOF
19244 /* end confdefs.h.  */
19245 $ac_includes_default
19246 #include <$ac_header>
19247 _ACEOF
19248 rm -f conftest.$ac_objext
19249 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19250   (eval $ac_compile) 2>conftest.er1
19251   ac_status=$?
19252   grep -v '^ *+' conftest.er1 >conftest.err
19253   rm -f conftest.er1
19254   cat conftest.err >&5
19255   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19256   (exit $ac_status); } &&
19257          { ac_try='test -z "$ac_c_werror_flag"
19258                          || test ! -s conftest.err'
19259   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19260   (eval $ac_try) 2>&5
19261   ac_status=$?
19262   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19263   (exit $ac_status); }; } &&
19264          { ac_try='test -s conftest.$ac_objext'
19265   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19266   (eval $ac_try) 2>&5
19267   ac_status=$?
19268   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19269   (exit $ac_status); }; }; then
19270   ac_header_compiler=yes
19271 else
19272   echo "$as_me: failed program was:" >&5
19273 sed 's/^/| /' conftest.$ac_ext >&5
19274
19275 ac_header_compiler=no
19276 fi
19277 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19278 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19279 echo "${ECHO_T}$ac_header_compiler" >&6
19280
19281 # Is the header present?
19282 echo "$as_me:$LINENO: checking $ac_header presence" >&5
19283 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19284 cat >conftest.$ac_ext <<_ACEOF
19285 /* confdefs.h.  */
19286 _ACEOF
19287 cat confdefs.h >>conftest.$ac_ext
19288 cat >>conftest.$ac_ext <<_ACEOF
19289 /* end confdefs.h.  */
19290 #include <$ac_header>
19291 _ACEOF
19292 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
19293   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19294   ac_status=$?
19295   grep -v '^ *+' conftest.er1 >conftest.err
19296   rm -f conftest.er1
19297   cat conftest.err >&5
19298   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19299   (exit $ac_status); } >/dev/null; then
19300   if test -s conftest.err; then
19301     ac_cpp_err=$ac_c_preproc_warn_flag
19302     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
19303   else
19304     ac_cpp_err=
19305   fi
19306 else
19307   ac_cpp_err=yes
19308 fi
19309 if test -z "$ac_cpp_err"; then
19310   ac_header_preproc=yes
19311 else
19312   echo "$as_me: failed program was:" >&5
19313 sed 's/^/| /' conftest.$ac_ext >&5
19314
19315   ac_header_preproc=no
19316 fi
19317 rm -f conftest.err conftest.$ac_ext
19318 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19319 echo "${ECHO_T}$ac_header_preproc" >&6
19320
19321 # So?  What about this header?
19322 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19323   yes:no: )
19324     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19325 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
19326     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19327 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19328     ac_header_preproc=yes
19329     ;;
19330   no:yes:* )
19331     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19332 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
19333     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
19334 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
19335     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19336 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19337     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
19338 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
19339     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19340 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19341     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19342 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19343     (
19344       cat <<\_ASBOX
19345 ## --------------------------------------------- ##
19346 ## Report this to <http://www.openldap.org/its/> ##
19347 ## --------------------------------------------- ##
19348 _ASBOX
19349     ) |
19350       sed "s/^/$as_me: WARNING:     /" >&2
19351     ;;
19352 esac
19353 echo "$as_me:$LINENO: checking for $ac_header" >&5
19354 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19355 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19356   echo $ECHO_N "(cached) $ECHO_C" >&6
19357 else
19358   eval "$as_ac_Header=\$ac_header_preproc"
19359 fi
19360 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19361 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19362
19363 fi
19364 if test `eval echo '${'$as_ac_Header'}'` = yes; then
19365   cat >>confdefs.h <<_ACEOF
19366 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
19367 _ACEOF
19368
19369 fi
19370
19371 done
19372
19373
19374         if test $ac_cv_header_pthread_h = yes ; then
19375                 echo "$as_me:$LINENO: checking POSIX thread version" >&5
19376 echo $ECHO_N "checking POSIX thread version... $ECHO_C" >&6
19377 if test "${ol_cv_pthread_version+set}" = set; then
19378   echo $ECHO_N "(cached) $ECHO_C" >&6
19379 else
19380
19381         cat >conftest.$ac_ext <<_ACEOF
19382 /* confdefs.h.  */
19383 _ACEOF
19384 cat confdefs.h >>conftest.$ac_ext
19385 cat >>conftest.$ac_ext <<_ACEOF
19386 /* end confdefs.h.  */
19387
19388 #               include <pthread.h>
19389
19390 int
19391 main ()
19392 {
19393
19394                 int i = PTHREAD_CREATE_JOINABLE;
19395
19396   ;
19397   return 0;
19398 }
19399 _ACEOF
19400 rm -f conftest.$ac_objext
19401 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19402   (eval $ac_compile) 2>conftest.er1
19403   ac_status=$?
19404   grep -v '^ *+' conftest.er1 >conftest.err
19405   rm -f conftest.er1
19406   cat conftest.err >&5
19407   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19408   (exit $ac_status); } &&
19409          { ac_try='test -z "$ac_c_werror_flag"
19410                          || test ! -s conftest.err'
19411   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19412   (eval $ac_try) 2>&5
19413   ac_status=$?
19414   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19415   (exit $ac_status); }; } &&
19416          { ac_try='test -s conftest.$ac_objext'
19417   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19418   (eval $ac_try) 2>&5
19419   ac_status=$?
19420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19421   (exit $ac_status); }; }; then
19422
19423         cat >conftest.$ac_ext <<_ACEOF
19424 /* confdefs.h.  */
19425 _ACEOF
19426 cat confdefs.h >>conftest.$ac_ext
19427 cat >>conftest.$ac_ext <<_ACEOF
19428 /* end confdefs.h.  */
19429 #include <pthread.h>
19430
19431 _ACEOF
19432 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19433   $EGREP "pthread_detach" >/dev/null 2>&1; then
19434   ol_cv_pthread_version=10
19435 else
19436   ol_cv_pthread_version=8
19437 fi
19438 rm -f conftest*
19439
19440 else
19441   echo "$as_me: failed program was:" >&5
19442 sed 's/^/| /' conftest.$ac_ext >&5
19443
19444
19445         cat >conftest.$ac_ext <<_ACEOF
19446 /* confdefs.h.  */
19447 _ACEOF
19448 cat confdefs.h >>conftest.$ac_ext
19449 cat >>conftest.$ac_ext <<_ACEOF
19450 /* end confdefs.h.  */
19451
19452 #               include <pthread.h>
19453 #               ifdef PTHREAD_CREATE_UNDETACHED
19454                 draft7
19455 #               endif
19456
19457 _ACEOF
19458 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19459   $EGREP "draft7" >/dev/null 2>&1; then
19460   ol_cv_pthread_version=7
19461 else
19462
19463         cat >conftest.$ac_ext <<_ACEOF
19464 /* confdefs.h.  */
19465 _ACEOF
19466 cat confdefs.h >>conftest.$ac_ext
19467 cat >>conftest.$ac_ext <<_ACEOF
19468 /* end confdefs.h.  */
19469 #include <pthread.h>
19470
19471 _ACEOF
19472 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19473   $EGREP "pthread_attr_init" >/dev/null 2>&1; then
19474   ol_cv_pthread_version=6
19475 else
19476
19477         cat >conftest.$ac_ext <<_ACEOF
19478 /* confdefs.h.  */
19479 _ACEOF
19480 cat confdefs.h >>conftest.$ac_ext
19481 cat >>conftest.$ac_ext <<_ACEOF
19482 /* end confdefs.h.  */
19483
19484 #               include <pthread.h>
19485 #ifdef          PTHREAD_MUTEX_INITIALIZER
19486                 draft5
19487 #endif
19488
19489 _ACEOF
19490 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19491   $EGREP "draft5" >/dev/null 2>&1; then
19492   ol_cv_pthread_version=5
19493 else
19494   ol_cv_pthread_version=4
19495 fi
19496 rm -f conftest*
19497
19498 fi
19499 rm -f conftest*
19500
19501 fi
19502 rm -f conftest*
19503
19504 fi
19505 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19506
19507 fi
19508 echo "$as_me:$LINENO: result: $ol_cv_pthread_version" >&5
19509 echo "${ECHO_T}$ol_cv_pthread_version" >&6
19510
19511
19512                 if test $ol_cv_pthread_version != 0 ; then
19513
19514 cat >>confdefs.h <<_ACEOF
19515 #define HAVE_PTHREADS $ol_cv_pthread_version
19516 _ACEOF
19517
19518                 else
19519                         { { echo "$as_me:$LINENO: error: unknown pthread version" >&5
19520 echo "$as_me: error: unknown pthread version" >&2;}
19521    { (exit 1); exit 1; }; }
19522                 fi
19523
19524                 # consider threads found
19525                 ol_with_threads=found
19526
19527
19528         echo "$as_me:$LINENO: checking for LinuxThreads pthread.h" >&5
19529 echo $ECHO_N "checking for LinuxThreads pthread.h... $ECHO_C" >&6
19530 if test "${ol_cv_header_linux_threads+set}" = set; then
19531   echo $ECHO_N "(cached) $ECHO_C" >&6
19532 else
19533   cat >conftest.$ac_ext <<_ACEOF
19534 /* confdefs.h.  */
19535 _ACEOF
19536 cat confdefs.h >>conftest.$ac_ext
19537 cat >>conftest.$ac_ext <<_ACEOF
19538 /* end confdefs.h.  */
19539 #include <pthread.h>
19540 _ACEOF
19541 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19542   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then
19543   ol_cv_header_linux_threads=yes
19544 else
19545   ol_cv_header_linux_threads=no
19546 fi
19547 rm -f conftest*
19548
19549
19550 fi
19551 echo "$as_me:$LINENO: result: $ol_cv_header_linux_threads" >&5
19552 echo "${ECHO_T}$ol_cv_header_linux_threads" >&6
19553         if test $ol_cv_header_linux_threads = yes; then
19554
19555 cat >>confdefs.h <<\_ACEOF
19556 #define HAVE_LINUX_THREADS 1
19557 _ACEOF
19558
19559         fi
19560
19561
19562         echo "$as_me:$LINENO: checking for GNU Pth pthread.h" >&5
19563 echo $ECHO_N "checking for GNU Pth pthread.h... $ECHO_C" >&6
19564 if test "${ol_cv_header_gnu_pth_pthread_h+set}" = set; then
19565   echo $ECHO_N "(cached) $ECHO_C" >&6
19566 else
19567   cat >conftest.$ac_ext <<_ACEOF
19568 /* confdefs.h.  */
19569 _ACEOF
19570 cat confdefs.h >>conftest.$ac_ext
19571 cat >>conftest.$ac_ext <<_ACEOF
19572 /* end confdefs.h.  */
19573 #include <pthread.h>
19574 #ifdef _POSIX_THREAD_IS_GNU_PTH
19575         __gnu_pth__;
19576 #endif
19577
19578 _ACEOF
19579 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19580   $EGREP "__gnu_pth__" >/dev/null 2>&1; then
19581   ol_cv_header_gnu_pth_pthread_h=yes
19582 else
19583   ol_cv_header_gnu_pth_pthread_h=no
19584 fi
19585 rm -f conftest*
19586
19587
19588 fi
19589 echo "$as_me:$LINENO: result: $ol_cv_header_gnu_pth_pthread_h" >&5
19590 echo "${ECHO_T}$ol_cv_header_gnu_pth_pthread_h" >&6
19591
19592
19593                 if test $ol_cv_header_gnu_pth_pthread_h = no ; then
19594
19595 for ac_header in sched.h
19596 do
19597 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
19598 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19599   echo "$as_me:$LINENO: checking for $ac_header" >&5
19600 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19601 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19602   echo $ECHO_N "(cached) $ECHO_C" >&6
19603 fi
19604 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19605 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19606 else
19607   # Is the header compilable?
19608 echo "$as_me:$LINENO: checking $ac_header usability" >&5
19609 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19610 cat >conftest.$ac_ext <<_ACEOF
19611 /* confdefs.h.  */
19612 _ACEOF
19613 cat confdefs.h >>conftest.$ac_ext
19614 cat >>conftest.$ac_ext <<_ACEOF
19615 /* end confdefs.h.  */
19616 $ac_includes_default
19617 #include <$ac_header>
19618 _ACEOF
19619 rm -f conftest.$ac_objext
19620 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19621   (eval $ac_compile) 2>conftest.er1
19622   ac_status=$?
19623   grep -v '^ *+' conftest.er1 >conftest.err
19624   rm -f conftest.er1
19625   cat conftest.err >&5
19626   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19627   (exit $ac_status); } &&
19628          { ac_try='test -z "$ac_c_werror_flag"
19629                          || test ! -s conftest.err'
19630   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19631   (eval $ac_try) 2>&5
19632   ac_status=$?
19633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19634   (exit $ac_status); }; } &&
19635          { ac_try='test -s conftest.$ac_objext'
19636   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19637   (eval $ac_try) 2>&5
19638   ac_status=$?
19639   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19640   (exit $ac_status); }; }; then
19641   ac_header_compiler=yes
19642 else
19643   echo "$as_me: failed program was:" >&5
19644 sed 's/^/| /' conftest.$ac_ext >&5
19645
19646 ac_header_compiler=no
19647 fi
19648 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19649 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19650 echo "${ECHO_T}$ac_header_compiler" >&6
19651
19652 # Is the header present?
19653 echo "$as_me:$LINENO: checking $ac_header presence" >&5
19654 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19655 cat >conftest.$ac_ext <<_ACEOF
19656 /* confdefs.h.  */
19657 _ACEOF
19658 cat confdefs.h >>conftest.$ac_ext
19659 cat >>conftest.$ac_ext <<_ACEOF
19660 /* end confdefs.h.  */
19661 #include <$ac_header>
19662 _ACEOF
19663 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
19664   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19665   ac_status=$?
19666   grep -v '^ *+' conftest.er1 >conftest.err
19667   rm -f conftest.er1
19668   cat conftest.err >&5
19669   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19670   (exit $ac_status); } >/dev/null; then
19671   if test -s conftest.err; then
19672     ac_cpp_err=$ac_c_preproc_warn_flag
19673     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
19674   else
19675     ac_cpp_err=
19676   fi
19677 else
19678   ac_cpp_err=yes
19679 fi
19680 if test -z "$ac_cpp_err"; then
19681   ac_header_preproc=yes
19682 else
19683   echo "$as_me: failed program was:" >&5
19684 sed 's/^/| /' conftest.$ac_ext >&5
19685
19686   ac_header_preproc=no
19687 fi
19688 rm -f conftest.err conftest.$ac_ext
19689 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19690 echo "${ECHO_T}$ac_header_preproc" >&6
19691
19692 # So?  What about this header?
19693 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19694   yes:no: )
19695     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19696 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
19697     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19698 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19699     ac_header_preproc=yes
19700     ;;
19701   no:yes:* )
19702     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19703 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
19704     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
19705 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
19706     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19707 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19708     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
19709 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
19710     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19711 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19712     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19713 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19714     (
19715       cat <<\_ASBOX
19716 ## --------------------------------------------- ##
19717 ## Report this to <http://www.openldap.org/its/> ##
19718 ## --------------------------------------------- ##
19719 _ASBOX
19720     ) |
19721       sed "s/^/$as_me: WARNING:     /" >&2
19722     ;;
19723 esac
19724 echo "$as_me:$LINENO: checking for $ac_header" >&5
19725 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19726 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19727   echo $ECHO_N "(cached) $ECHO_C" >&6
19728 else
19729   eval "$as_ac_Header=\$ac_header_preproc"
19730 fi
19731 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19732 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19733
19734 fi
19735 if test `eval echo '${'$as_ac_Header'}'` = yes; then
19736   cat >>confdefs.h <<_ACEOF
19737 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
19738 _ACEOF
19739
19740 fi
19741
19742 done
19743
19744                 fi
19745
19746
19747                                 echo "$as_me:$LINENO: checking for pthread_create in default libraries" >&5
19748 echo $ECHO_N "checking for pthread_create in default libraries... $ECHO_C" >&6
19749 if test "${ol_cv_pthread_create+set}" = set; then
19750   echo $ECHO_N "(cached) $ECHO_C" >&6
19751 else
19752
19753                         if test "$cross_compiling" = yes; then
19754   cat >conftest.$ac_ext <<_ACEOF
19755 /* confdefs.h.  */
19756 _ACEOF
19757 cat confdefs.h >>conftest.$ac_ext
19758 cat >>conftest.$ac_ext <<_ACEOF
19759 /* end confdefs.h.  */
19760
19761 /* pthread test headers */
19762 #include <pthread.h>
19763 #if HAVE_PTHREADS < 7
19764 #include <errno.h>
19765 #endif
19766 #ifndef NULL
19767 #define NULL (void*)0
19768 #endif
19769
19770 static void *task(p)
19771         void *p;
19772 {
19773         return (void *) (p == NULL);
19774 }
19775
19776 int
19777 main ()
19778 {
19779
19780         /* pthread test function */
19781 #ifndef PTHREAD_CREATE_DETACHED
19782 #define PTHREAD_CREATE_DETACHED 1
19783 #endif
19784         pthread_t t;
19785         int status;
19786         int detach = PTHREAD_CREATE_DETACHED;
19787
19788 #if HAVE_PTHREADS > 4
19789         /* Final pthreads */
19790         pthread_attr_t attr;
19791
19792         status = pthread_attr_init(&attr);
19793         if( status ) return status;
19794
19795 #if HAVE_PTHREADS < 7
19796         status = pthread_attr_setdetachstate(&attr, &detach);
19797         if( status < 0 ) status = errno;
19798 #else
19799         status = pthread_attr_setdetachstate(&attr, detach);
19800 #endif
19801         if( status ) return status;
19802         status = pthread_create( &t, &attr, task, NULL );
19803 #if HAVE_PTHREADS < 7
19804         if( status < 0 ) status = errno;
19805 #endif
19806         if( status ) return status;
19807 #else
19808         /* Draft 4 pthreads */
19809         status = pthread_create( &t, pthread_attr_default, task, NULL );
19810         if( status ) return errno;
19811
19812         /* give thread a chance to complete */
19813         /* it should remain joinable and hence detachable */
19814         sleep( 1 );
19815
19816         status = pthread_detach( &t );
19817         if( status ) return errno;
19818 #endif
19819
19820 #ifdef HAVE_LINUX_THREADS
19821         pthread_kill_other_threads_np();
19822 #endif
19823
19824         return 0;
19825
19826   ;
19827   return 0;
19828 }
19829 _ACEOF
19830 rm -f conftest.$ac_objext conftest$ac_exeext
19831 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19832   (eval $ac_link) 2>conftest.er1
19833   ac_status=$?
19834   grep -v '^ *+' conftest.er1 >conftest.err
19835   rm -f conftest.er1
19836   cat conftest.err >&5
19837   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19838   (exit $ac_status); } &&
19839          { ac_try='test -z "$ac_c_werror_flag"
19840                          || test ! -s conftest.err'
19841   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19842   (eval $ac_try) 2>&5
19843   ac_status=$?
19844   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19845   (exit $ac_status); }; } &&
19846          { ac_try='test -s conftest$ac_exeext'
19847   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19848   (eval $ac_try) 2>&5
19849   ac_status=$?
19850   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19851   (exit $ac_status); }; }; then
19852   ol_cv_pthread_create=yes
19853 else
19854   echo "$as_me: failed program was:" >&5
19855 sed 's/^/| /' conftest.$ac_ext >&5
19856
19857 ol_cv_pthread_create=no
19858 fi
19859 rm -f conftest.err conftest.$ac_objext \
19860       conftest$ac_exeext conftest.$ac_ext
19861 else
19862   cat >conftest.$ac_ext <<_ACEOF
19863 /* confdefs.h.  */
19864 _ACEOF
19865 cat confdefs.h >>conftest.$ac_ext
19866 cat >>conftest.$ac_ext <<_ACEOF
19867 /* end confdefs.h.  */
19868
19869 /* pthread test headers */
19870 #include <pthread.h>
19871 #if HAVE_PTHREADS < 7
19872 #include <errno.h>
19873 #endif
19874 #ifndef NULL
19875 #define NULL (void*)0
19876 #endif
19877
19878 static void *task(p)
19879         void *p;
19880 {
19881         return (void *) (p == NULL);
19882 }
19883
19884
19885 int main(argc, argv)
19886         int argc;
19887         char **argv;
19888 {
19889
19890         /* pthread test function */
19891 #ifndef PTHREAD_CREATE_DETACHED
19892 #define PTHREAD_CREATE_DETACHED 1
19893 #endif
19894         pthread_t t;
19895         int status;
19896         int detach = PTHREAD_CREATE_DETACHED;
19897
19898 #if HAVE_PTHREADS > 4
19899         /* Final pthreads */
19900         pthread_attr_t attr;
19901
19902         status = pthread_attr_init(&attr);
19903         if( status ) return status;
19904
19905 #if HAVE_PTHREADS < 7
19906         status = pthread_attr_setdetachstate(&attr, &detach);
19907         if( status < 0 ) status = errno;
19908 #else
19909         status = pthread_attr_setdetachstate(&attr, detach);
19910 #endif
19911         if( status ) return status;
19912         status = pthread_create( &t, &attr, task, NULL );
19913 #if HAVE_PTHREADS < 7
19914         if( status < 0 ) status = errno;
19915 #endif
19916         if( status ) return status;
19917 #else
19918         /* Draft 4 pthreads */
19919         status = pthread_create( &t, pthread_attr_default, task, NULL );
19920         if( status ) return errno;
19921
19922         /* give thread a chance to complete */
19923         /* it should remain joinable and hence detachable */
19924         sleep( 1 );
19925
19926         status = pthread_detach( &t );
19927         if( status ) return errno;
19928 #endif
19929
19930 #ifdef HAVE_LINUX_THREADS
19931         pthread_kill_other_threads_np();
19932 #endif
19933
19934         return 0;
19935
19936 }
19937
19938 _ACEOF
19939 rm -f conftest$ac_exeext
19940 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19941   (eval $ac_link) 2>&5
19942   ac_status=$?
19943   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19944   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19945   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19946   (eval $ac_try) 2>&5
19947   ac_status=$?
19948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19949   (exit $ac_status); }; }; then
19950   ol_cv_pthread_create=yes
19951 else
19952   echo "$as_me: program exited with status $ac_status" >&5
19953 echo "$as_me: failed program was:" >&5
19954 sed 's/^/| /' conftest.$ac_ext >&5
19955
19956 ( exit $ac_status )
19957 ol_cv_pthread_create=no
19958 fi
19959 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19960 fi
19961 fi
19962 echo "$as_me:$LINENO: result: $ol_cv_pthread_create" >&5
19963 echo "${ECHO_T}$ol_cv_pthread_create" >&6
19964
19965                 if test $ol_cv_pthread_create != no ; then
19966                         ol_link_threads=posix
19967                         ol_link_pthreads=""
19968                 fi
19969
19970                 # Pthread try link: -kthread (ol_cv_pthread_kthread)
19971 if test "$ol_link_threads" = no ; then
19972         # try -kthread
19973         echo "$as_me:$LINENO: checking for pthread link with -kthread" >&5
19974 echo $ECHO_N "checking for pthread link with -kthread... $ECHO_C" >&6
19975 if test "${ol_cv_pthread_kthread+set}" = set; then
19976   echo $ECHO_N "(cached) $ECHO_C" >&6
19977 else
19978
19979                 # save the flags
19980                 ol_LIBS="$LIBS"
19981                 LIBS="-kthread $LIBS"
19982
19983                 if test "$cross_compiling" = yes; then
19984   cat >conftest.$ac_ext <<_ACEOF
19985 /* confdefs.h.  */
19986 _ACEOF
19987 cat confdefs.h >>conftest.$ac_ext
19988 cat >>conftest.$ac_ext <<_ACEOF
19989 /* end confdefs.h.  */
19990
19991 /* pthread test headers */
19992 #include <pthread.h>
19993 #if HAVE_PTHREADS < 7
19994 #include <errno.h>
19995 #endif
19996 #ifndef NULL
19997 #define NULL (void*)0
19998 #endif
19999
20000 static void *task(p)
20001         void *p;
20002 {
20003         return (void *) (p == NULL);
20004 }
20005
20006 int
20007 main ()
20008 {
20009
20010         /* pthread test function */
20011 #ifndef PTHREAD_CREATE_DETACHED
20012 #define PTHREAD_CREATE_DETACHED 1
20013 #endif
20014         pthread_t t;
20015         int status;
20016         int detach = PTHREAD_CREATE_DETACHED;
20017
20018 #if HAVE_PTHREADS > 4
20019         /* Final pthreads */
20020         pthread_attr_t attr;
20021
20022         status = pthread_attr_init(&attr);
20023         if( status ) return status;
20024
20025 #if HAVE_PTHREADS < 7
20026         status = pthread_attr_setdetachstate(&attr, &detach);
20027         if( status < 0 ) status = errno;
20028 #else
20029         status = pthread_attr_setdetachstate(&attr, detach);
20030 #endif
20031         if( status ) return status;
20032         status = pthread_create( &t, &attr, task, NULL );
20033 #if HAVE_PTHREADS < 7
20034         if( status < 0 ) status = errno;
20035 #endif
20036         if( status ) return status;
20037 #else
20038         /* Draft 4 pthreads */
20039         status = pthread_create( &t, pthread_attr_default, task, NULL );
20040         if( status ) return errno;
20041
20042         /* give thread a chance to complete */
20043         /* it should remain joinable and hence detachable */
20044         sleep( 1 );
20045
20046         status = pthread_detach( &t );
20047         if( status ) return errno;
20048 #endif
20049
20050 #ifdef HAVE_LINUX_THREADS
20051         pthread_kill_other_threads_np();
20052 #endif
20053
20054         return 0;
20055
20056   ;
20057   return 0;
20058 }
20059 _ACEOF
20060 rm -f conftest.$ac_objext conftest$ac_exeext
20061 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20062   (eval $ac_link) 2>conftest.er1
20063   ac_status=$?
20064   grep -v '^ *+' conftest.er1 >conftest.err
20065   rm -f conftest.er1
20066   cat conftest.err >&5
20067   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20068   (exit $ac_status); } &&
20069          { ac_try='test -z "$ac_c_werror_flag"
20070                          || test ! -s conftest.err'
20071   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20072   (eval $ac_try) 2>&5
20073   ac_status=$?
20074   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20075   (exit $ac_status); }; } &&
20076          { ac_try='test -s conftest$ac_exeext'
20077   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20078   (eval $ac_try) 2>&5
20079   ac_status=$?
20080   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20081   (exit $ac_status); }; }; then
20082   ol_cv_pthread_kthread=yes
20083 else
20084   echo "$as_me: failed program was:" >&5
20085 sed 's/^/| /' conftest.$ac_ext >&5
20086
20087 ol_cv_pthread_kthread=no
20088 fi
20089 rm -f conftest.err conftest.$ac_objext \
20090       conftest$ac_exeext conftest.$ac_ext
20091 else
20092   cat >conftest.$ac_ext <<_ACEOF
20093 /* confdefs.h.  */
20094 _ACEOF
20095 cat confdefs.h >>conftest.$ac_ext
20096 cat >>conftest.$ac_ext <<_ACEOF
20097 /* end confdefs.h.  */
20098
20099 /* pthread test headers */
20100 #include <pthread.h>
20101 #if HAVE_PTHREADS < 7
20102 #include <errno.h>
20103 #endif
20104 #ifndef NULL
20105 #define NULL (void*)0
20106 #endif
20107
20108 static void *task(p)
20109         void *p;
20110 {
20111         return (void *) (p == NULL);
20112 }
20113
20114
20115 int main(argc, argv)
20116         int argc;
20117         char **argv;
20118 {
20119
20120         /* pthread test function */
20121 #ifndef PTHREAD_CREATE_DETACHED
20122 #define PTHREAD_CREATE_DETACHED 1
20123 #endif
20124         pthread_t t;
20125         int status;
20126         int detach = PTHREAD_CREATE_DETACHED;
20127
20128 #if HAVE_PTHREADS > 4
20129         /* Final pthreads */
20130         pthread_attr_t attr;
20131
20132         status = pthread_attr_init(&attr);
20133         if( status ) return status;
20134
20135 #if HAVE_PTHREADS < 7
20136         status = pthread_attr_setdetachstate(&attr, &detach);
20137         if( status < 0 ) status = errno;
20138 #else
20139         status = pthread_attr_setdetachstate(&attr, detach);
20140 #endif
20141         if( status ) return status;
20142         status = pthread_create( &t, &attr, task, NULL );
20143 #if HAVE_PTHREADS < 7
20144         if( status < 0 ) status = errno;
20145 #endif
20146         if( status ) return status;
20147 #else
20148         /* Draft 4 pthreads */
20149         status = pthread_create( &t, pthread_attr_default, task, NULL );
20150         if( status ) return errno;
20151
20152         /* give thread a chance to complete */
20153         /* it should remain joinable and hence detachable */
20154         sleep( 1 );
20155
20156         status = pthread_detach( &t );
20157         if( status ) return errno;
20158 #endif
20159
20160 #ifdef HAVE_LINUX_THREADS
20161         pthread_kill_other_threads_np();
20162 #endif
20163
20164         return 0;
20165
20166 }
20167
20168 _ACEOF
20169 rm -f conftest$ac_exeext
20170 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20171   (eval $ac_link) 2>&5
20172   ac_status=$?
20173   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20174   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20175   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20176   (eval $ac_try) 2>&5
20177   ac_status=$?
20178   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20179   (exit $ac_status); }; }; then
20180   ol_cv_pthread_kthread=yes
20181 else
20182   echo "$as_me: program exited with status $ac_status" >&5
20183 echo "$as_me: failed program was:" >&5
20184 sed 's/^/| /' conftest.$ac_ext >&5
20185
20186 ( exit $ac_status )
20187 ol_cv_pthread_kthread=no
20188 fi
20189 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20190 fi
20191
20192                 # restore the LIBS
20193                 LIBS="$ol_LIBS"
20194
20195 fi
20196 echo "$as_me:$LINENO: result: $ol_cv_pthread_kthread" >&5
20197 echo "${ECHO_T}$ol_cv_pthread_kthread" >&6
20198
20199         if test $ol_cv_pthread_kthread = yes ; then
20200                 ol_link_pthreads="-kthread"
20201                 ol_link_threads=posix
20202         fi
20203 fi
20204
20205                 # Pthread try link: -pthread (ol_cv_pthread_pthread)
20206 if test "$ol_link_threads" = no ; then
20207         # try -pthread
20208         echo "$as_me:$LINENO: checking for pthread link with -pthread" >&5
20209 echo $ECHO_N "checking for pthread link with -pthread... $ECHO_C" >&6
20210 if test "${ol_cv_pthread_pthread+set}" = set; then
20211   echo $ECHO_N "(cached) $ECHO_C" >&6
20212 else
20213
20214                 # save the flags
20215                 ol_LIBS="$LIBS"
20216                 LIBS="-pthread $LIBS"
20217
20218                 if test "$cross_compiling" = yes; then
20219   cat >conftest.$ac_ext <<_ACEOF
20220 /* confdefs.h.  */
20221 _ACEOF
20222 cat confdefs.h >>conftest.$ac_ext
20223 cat >>conftest.$ac_ext <<_ACEOF
20224 /* end confdefs.h.  */
20225
20226 /* pthread test headers */
20227 #include <pthread.h>
20228 #if HAVE_PTHREADS < 7
20229 #include <errno.h>
20230 #endif
20231 #ifndef NULL
20232 #define NULL (void*)0
20233 #endif
20234
20235 static void *task(p)
20236         void *p;
20237 {
20238         return (void *) (p == NULL);
20239 }
20240
20241 int
20242 main ()
20243 {
20244
20245         /* pthread test function */
20246 #ifndef PTHREAD_CREATE_DETACHED
20247 #define PTHREAD_CREATE_DETACHED 1
20248 #endif
20249         pthread_t t;
20250         int status;
20251         int detach = PTHREAD_CREATE_DETACHED;
20252
20253 #if HAVE_PTHREADS > 4
20254         /* Final pthreads */
20255         pthread_attr_t attr;
20256
20257         status = pthread_attr_init(&attr);
20258         if( status ) return status;
20259
20260 #if HAVE_PTHREADS < 7
20261         status = pthread_attr_setdetachstate(&attr, &detach);
20262         if( status < 0 ) status = errno;
20263 #else
20264         status = pthread_attr_setdetachstate(&attr, detach);
20265 #endif
20266         if( status ) return status;
20267         status = pthread_create( &t, &attr, task, NULL );
20268 #if HAVE_PTHREADS < 7
20269         if( status < 0 ) status = errno;
20270 #endif
20271         if( status ) return status;
20272 #else
20273         /* Draft 4 pthreads */
20274         status = pthread_create( &t, pthread_attr_default, task, NULL );
20275         if( status ) return errno;
20276
20277         /* give thread a chance to complete */
20278         /* it should remain joinable and hence detachable */
20279         sleep( 1 );
20280
20281         status = pthread_detach( &t );
20282         if( status ) return errno;
20283 #endif
20284
20285 #ifdef HAVE_LINUX_THREADS
20286         pthread_kill_other_threads_np();
20287 #endif
20288
20289         return 0;
20290
20291   ;
20292   return 0;
20293 }
20294 _ACEOF
20295 rm -f conftest.$ac_objext conftest$ac_exeext
20296 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20297   (eval $ac_link) 2>conftest.er1
20298   ac_status=$?
20299   grep -v '^ *+' conftest.er1 >conftest.err
20300   rm -f conftest.er1
20301   cat conftest.err >&5
20302   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20303   (exit $ac_status); } &&
20304          { ac_try='test -z "$ac_c_werror_flag"
20305                          || test ! -s conftest.err'
20306   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20307   (eval $ac_try) 2>&5
20308   ac_status=$?
20309   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20310   (exit $ac_status); }; } &&
20311          { ac_try='test -s conftest$ac_exeext'
20312   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20313   (eval $ac_try) 2>&5
20314   ac_status=$?
20315   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20316   (exit $ac_status); }; }; then
20317   ol_cv_pthread_pthread=yes
20318 else
20319   echo "$as_me: failed program was:" >&5
20320 sed 's/^/| /' conftest.$ac_ext >&5
20321
20322 ol_cv_pthread_pthread=no
20323 fi
20324 rm -f conftest.err conftest.$ac_objext \
20325       conftest$ac_exeext conftest.$ac_ext
20326 else
20327   cat >conftest.$ac_ext <<_ACEOF
20328 /* confdefs.h.  */
20329 _ACEOF
20330 cat confdefs.h >>conftest.$ac_ext
20331 cat >>conftest.$ac_ext <<_ACEOF
20332 /* end confdefs.h.  */
20333
20334 /* pthread test headers */
20335 #include <pthread.h>
20336 #if HAVE_PTHREADS < 7
20337 #include <errno.h>
20338 #endif
20339 #ifndef NULL
20340 #define NULL (void*)0
20341 #endif
20342
20343 static void *task(p)
20344         void *p;
20345 {
20346         return (void *) (p == NULL);
20347 }
20348
20349
20350 int main(argc, argv)
20351         int argc;
20352         char **argv;
20353 {
20354
20355         /* pthread test function */
20356 #ifndef PTHREAD_CREATE_DETACHED
20357 #define PTHREAD_CREATE_DETACHED 1
20358 #endif
20359         pthread_t t;
20360         int status;
20361         int detach = PTHREAD_CREATE_DETACHED;
20362
20363 #if HAVE_PTHREADS > 4
20364         /* Final pthreads */
20365         pthread_attr_t attr;
20366
20367         status = pthread_attr_init(&attr);
20368         if( status ) return status;
20369
20370 #if HAVE_PTHREADS < 7
20371         status = pthread_attr_setdetachstate(&attr, &detach);
20372         if( status < 0 ) status = errno;
20373 #else
20374         status = pthread_attr_setdetachstate(&attr, detach);
20375 #endif
20376         if( status ) return status;
20377         status = pthread_create( &t, &attr, task, NULL );
20378 #if HAVE_PTHREADS < 7
20379         if( status < 0 ) status = errno;
20380 #endif
20381         if( status ) return status;
20382 #else
20383         /* Draft 4 pthreads */
20384         status = pthread_create( &t, pthread_attr_default, task, NULL );
20385         if( status ) return errno;
20386
20387         /* give thread a chance to complete */
20388         /* it should remain joinable and hence detachable */
20389         sleep( 1 );
20390
20391         status = pthread_detach( &t );
20392         if( status ) return errno;
20393 #endif
20394
20395 #ifdef HAVE_LINUX_THREADS
20396         pthread_kill_other_threads_np();
20397 #endif
20398
20399         return 0;
20400
20401 }
20402
20403 _ACEOF
20404 rm -f conftest$ac_exeext
20405 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20406   (eval $ac_link) 2>&5
20407   ac_status=$?
20408   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20409   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20410   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20411   (eval $ac_try) 2>&5
20412   ac_status=$?
20413   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20414   (exit $ac_status); }; }; then
20415   ol_cv_pthread_pthread=yes
20416 else
20417   echo "$as_me: program exited with status $ac_status" >&5
20418 echo "$as_me: failed program was:" >&5
20419 sed 's/^/| /' conftest.$ac_ext >&5
20420
20421 ( exit $ac_status )
20422 ol_cv_pthread_pthread=no
20423 fi
20424 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20425 fi
20426
20427                 # restore the LIBS
20428                 LIBS="$ol_LIBS"
20429
20430 fi
20431 echo "$as_me:$LINENO: result: $ol_cv_pthread_pthread" >&5
20432 echo "${ECHO_T}$ol_cv_pthread_pthread" >&6
20433
20434         if test $ol_cv_pthread_pthread = yes ; then
20435                 ol_link_pthreads="-pthread"
20436                 ol_link_threads=posix
20437         fi
20438 fi
20439
20440                 # Pthread try link: -pthreads (ol_cv_pthread_pthreads)
20441 if test "$ol_link_threads" = no ; then
20442         # try -pthreads
20443         echo "$as_me:$LINENO: checking for pthread link with -pthreads" >&5
20444 echo $ECHO_N "checking for pthread link with -pthreads... $ECHO_C" >&6
20445 if test "${ol_cv_pthread_pthreads+set}" = set; then
20446   echo $ECHO_N "(cached) $ECHO_C" >&6
20447 else
20448
20449                 # save the flags
20450                 ol_LIBS="$LIBS"
20451                 LIBS="-pthreads $LIBS"
20452
20453                 if test "$cross_compiling" = yes; then
20454   cat >conftest.$ac_ext <<_ACEOF
20455 /* confdefs.h.  */
20456 _ACEOF
20457 cat confdefs.h >>conftest.$ac_ext
20458 cat >>conftest.$ac_ext <<_ACEOF
20459 /* end confdefs.h.  */
20460
20461 /* pthread test headers */
20462 #include <pthread.h>
20463 #if HAVE_PTHREADS < 7
20464 #include <errno.h>
20465 #endif
20466 #ifndef NULL
20467 #define NULL (void*)0
20468 #endif
20469
20470 static void *task(p)
20471         void *p;
20472 {
20473         return (void *) (p == NULL);
20474 }
20475
20476 int
20477 main ()
20478 {
20479
20480         /* pthread test function */
20481 #ifndef PTHREAD_CREATE_DETACHED
20482 #define PTHREAD_CREATE_DETACHED 1
20483 #endif
20484         pthread_t t;
20485         int status;
20486         int detach = PTHREAD_CREATE_DETACHED;
20487
20488 #if HAVE_PTHREADS > 4
20489         /* Final pthreads */
20490         pthread_attr_t attr;
20491
20492         status = pthread_attr_init(&attr);
20493         if( status ) return status;
20494
20495 #if HAVE_PTHREADS < 7
20496         status = pthread_attr_setdetachstate(&attr, &detach);
20497         if( status < 0 ) status = errno;
20498 #else
20499         status = pthread_attr_setdetachstate(&attr, detach);
20500 #endif
20501         if( status ) return status;
20502         status = pthread_create( &t, &attr, task, NULL );
20503 #if HAVE_PTHREADS < 7
20504         if( status < 0 ) status = errno;
20505 #endif
20506         if( status ) return status;
20507 #else
20508         /* Draft 4 pthreads */
20509         status = pthread_create( &t, pthread_attr_default, task, NULL );
20510         if( status ) return errno;
20511
20512         /* give thread a chance to complete */
20513         /* it should remain joinable and hence detachable */
20514         sleep( 1 );
20515
20516         status = pthread_detach( &t );
20517         if( status ) return errno;
20518 #endif
20519
20520 #ifdef HAVE_LINUX_THREADS
20521         pthread_kill_other_threads_np();
20522 #endif
20523
20524         return 0;
20525
20526   ;
20527   return 0;
20528 }
20529 _ACEOF
20530 rm -f conftest.$ac_objext conftest$ac_exeext
20531 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20532   (eval $ac_link) 2>conftest.er1
20533   ac_status=$?
20534   grep -v '^ *+' conftest.er1 >conftest.err
20535   rm -f conftest.er1
20536   cat conftest.err >&5
20537   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20538   (exit $ac_status); } &&
20539          { ac_try='test -z "$ac_c_werror_flag"
20540                          || test ! -s conftest.err'
20541   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20542   (eval $ac_try) 2>&5
20543   ac_status=$?
20544   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20545   (exit $ac_status); }; } &&
20546          { ac_try='test -s conftest$ac_exeext'
20547   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20548   (eval $ac_try) 2>&5
20549   ac_status=$?
20550   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20551   (exit $ac_status); }; }; then
20552   ol_cv_pthread_pthreads=yes
20553 else
20554   echo "$as_me: failed program was:" >&5
20555 sed 's/^/| /' conftest.$ac_ext >&5
20556
20557 ol_cv_pthread_pthreads=no
20558 fi
20559 rm -f conftest.err conftest.$ac_objext \
20560       conftest$ac_exeext conftest.$ac_ext
20561 else
20562   cat >conftest.$ac_ext <<_ACEOF
20563 /* confdefs.h.  */
20564 _ACEOF
20565 cat confdefs.h >>conftest.$ac_ext
20566 cat >>conftest.$ac_ext <<_ACEOF
20567 /* end confdefs.h.  */
20568
20569 /* pthread test headers */
20570 #include <pthread.h>
20571 #if HAVE_PTHREADS < 7
20572 #include <errno.h>
20573 #endif
20574 #ifndef NULL
20575 #define NULL (void*)0
20576 #endif
20577
20578 static void *task(p)
20579         void *p;
20580 {
20581         return (void *) (p == NULL);
20582 }
20583
20584
20585 int main(argc, argv)
20586         int argc;
20587         char **argv;
20588 {
20589
20590         /* pthread test function */
20591 #ifndef PTHREAD_CREATE_DETACHED
20592 #define PTHREAD_CREATE_DETACHED 1
20593 #endif
20594         pthread_t t;
20595         int status;
20596         int detach = PTHREAD_CREATE_DETACHED;
20597
20598 #if HAVE_PTHREADS > 4
20599         /* Final pthreads */
20600         pthread_attr_t attr;
20601
20602         status = pthread_attr_init(&attr);
20603         if( status ) return status;
20604
20605 #if HAVE_PTHREADS < 7
20606         status = pthread_attr_setdetachstate(&attr, &detach);
20607         if( status < 0 ) status = errno;
20608 #else
20609         status = pthread_attr_setdetachstate(&attr, detach);
20610 #endif
20611         if( status ) return status;
20612         status = pthread_create( &t, &attr, task, NULL );
20613 #if HAVE_PTHREADS < 7
20614         if( status < 0 ) status = errno;
20615 #endif
20616         if( status ) return status;
20617 #else
20618         /* Draft 4 pthreads */
20619         status = pthread_create( &t, pthread_attr_default, task, NULL );
20620         if( status ) return errno;
20621
20622         /* give thread a chance to complete */
20623         /* it should remain joinable and hence detachable */
20624         sleep( 1 );
20625
20626         status = pthread_detach( &t );
20627         if( status ) return errno;
20628 #endif
20629
20630 #ifdef HAVE_LINUX_THREADS
20631         pthread_kill_other_threads_np();
20632 #endif
20633
20634         return 0;
20635
20636 }
20637
20638 _ACEOF
20639 rm -f conftest$ac_exeext
20640 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20641   (eval $ac_link) 2>&5
20642   ac_status=$?
20643   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20644   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20645   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20646   (eval $ac_try) 2>&5
20647   ac_status=$?
20648   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20649   (exit $ac_status); }; }; then
20650   ol_cv_pthread_pthreads=yes
20651 else
20652   echo "$as_me: program exited with status $ac_status" >&5
20653 echo "$as_me: failed program was:" >&5
20654 sed 's/^/| /' conftest.$ac_ext >&5
20655
20656 ( exit $ac_status )
20657 ol_cv_pthread_pthreads=no
20658 fi
20659 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20660 fi
20661
20662                 # restore the LIBS
20663                 LIBS="$ol_LIBS"
20664
20665 fi
20666 echo "$as_me:$LINENO: result: $ol_cv_pthread_pthreads" >&5
20667 echo "${ECHO_T}$ol_cv_pthread_pthreads" >&6
20668
20669         if test $ol_cv_pthread_pthreads = yes ; then
20670                 ol_link_pthreads="-pthreads"
20671                 ol_link_threads=posix
20672         fi
20673 fi
20674
20675                 # Pthread try link: -mthreads (ol_cv_pthread_mthreads)
20676 if test "$ol_link_threads" = no ; then
20677         # try -mthreads
20678         echo "$as_me:$LINENO: checking for pthread link with -mthreads" >&5
20679 echo $ECHO_N "checking for pthread link with -mthreads... $ECHO_C" >&6
20680 if test "${ol_cv_pthread_mthreads+set}" = set; then
20681   echo $ECHO_N "(cached) $ECHO_C" >&6
20682 else
20683
20684                 # save the flags
20685                 ol_LIBS="$LIBS"
20686                 LIBS="-mthreads $LIBS"
20687
20688                 if test "$cross_compiling" = yes; then
20689   cat >conftest.$ac_ext <<_ACEOF
20690 /* confdefs.h.  */
20691 _ACEOF
20692 cat confdefs.h >>conftest.$ac_ext
20693 cat >>conftest.$ac_ext <<_ACEOF
20694 /* end confdefs.h.  */
20695
20696 /* pthread test headers */
20697 #include <pthread.h>
20698 #if HAVE_PTHREADS < 7
20699 #include <errno.h>
20700 #endif
20701 #ifndef NULL
20702 #define NULL (void*)0
20703 #endif
20704
20705 static void *task(p)
20706         void *p;
20707 {
20708         return (void *) (p == NULL);
20709 }
20710
20711 int
20712 main ()
20713 {
20714
20715         /* pthread test function */
20716 #ifndef PTHREAD_CREATE_DETACHED
20717 #define PTHREAD_CREATE_DETACHED 1
20718 #endif
20719         pthread_t t;
20720         int status;
20721         int detach = PTHREAD_CREATE_DETACHED;
20722
20723 #if HAVE_PTHREADS > 4
20724         /* Final pthreads */
20725         pthread_attr_t attr;
20726
20727         status = pthread_attr_init(&attr);
20728         if( status ) return status;
20729
20730 #if HAVE_PTHREADS < 7
20731         status = pthread_attr_setdetachstate(&attr, &detach);
20732         if( status < 0 ) status = errno;
20733 #else
20734         status = pthread_attr_setdetachstate(&attr, detach);
20735 #endif
20736         if( status ) return status;
20737         status = pthread_create( &t, &attr, task, NULL );
20738 #if HAVE_PTHREADS < 7
20739         if( status < 0 ) status = errno;
20740 #endif
20741         if( status ) return status;
20742 #else
20743         /* Draft 4 pthreads */
20744         status = pthread_create( &t, pthread_attr_default, task, NULL );
20745         if( status ) return errno;
20746
20747         /* give thread a chance to complete */
20748         /* it should remain joinable and hence detachable */
20749         sleep( 1 );
20750
20751         status = pthread_detach( &t );
20752         if( status ) return errno;
20753 #endif
20754
20755 #ifdef HAVE_LINUX_THREADS
20756         pthread_kill_other_threads_np();
20757 #endif
20758
20759         return 0;
20760
20761   ;
20762   return 0;
20763 }
20764 _ACEOF
20765 rm -f conftest.$ac_objext conftest$ac_exeext
20766 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20767   (eval $ac_link) 2>conftest.er1
20768   ac_status=$?
20769   grep -v '^ *+' conftest.er1 >conftest.err
20770   rm -f conftest.er1
20771   cat conftest.err >&5
20772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20773   (exit $ac_status); } &&
20774          { ac_try='test -z "$ac_c_werror_flag"
20775                          || test ! -s conftest.err'
20776   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20777   (eval $ac_try) 2>&5
20778   ac_status=$?
20779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20780   (exit $ac_status); }; } &&
20781          { ac_try='test -s conftest$ac_exeext'
20782   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20783   (eval $ac_try) 2>&5
20784   ac_status=$?
20785   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20786   (exit $ac_status); }; }; then
20787   ol_cv_pthread_mthreads=yes
20788 else
20789   echo "$as_me: failed program was:" >&5
20790 sed 's/^/| /' conftest.$ac_ext >&5
20791
20792 ol_cv_pthread_mthreads=no
20793 fi
20794 rm -f conftest.err conftest.$ac_objext \
20795       conftest$ac_exeext conftest.$ac_ext
20796 else
20797   cat >conftest.$ac_ext <<_ACEOF
20798 /* confdefs.h.  */
20799 _ACEOF
20800 cat confdefs.h >>conftest.$ac_ext
20801 cat >>conftest.$ac_ext <<_ACEOF
20802 /* end confdefs.h.  */
20803
20804 /* pthread test headers */
20805 #include <pthread.h>
20806 #if HAVE_PTHREADS < 7
20807 #include <errno.h>
20808 #endif
20809 #ifndef NULL
20810 #define NULL (void*)0
20811 #endif
20812
20813 static void *task(p)
20814         void *p;
20815 {
20816         return (void *) (p == NULL);
20817 }
20818
20819
20820 int main(argc, argv)
20821         int argc;
20822         char **argv;
20823 {
20824
20825         /* pthread test function */
20826 #ifndef PTHREAD_CREATE_DETACHED
20827 #define PTHREAD_CREATE_DETACHED 1
20828 #endif
20829         pthread_t t;
20830         int status;
20831         int detach = PTHREAD_CREATE_DETACHED;
20832
20833 #if HAVE_PTHREADS > 4
20834         /* Final pthreads */
20835         pthread_attr_t attr;
20836
20837         status = pthread_attr_init(&attr);
20838         if( status ) return status;
20839
20840 #if HAVE_PTHREADS < 7
20841         status = pthread_attr_setdetachstate(&attr, &detach);
20842         if( status < 0 ) status = errno;
20843 #else
20844         status = pthread_attr_setdetachstate(&attr, detach);
20845 #endif
20846         if( status ) return status;
20847         status = pthread_create( &t, &attr, task, NULL );
20848 #if HAVE_PTHREADS < 7
20849         if( status < 0 ) status = errno;
20850 #endif
20851         if( status ) return status;
20852 #else
20853         /* Draft 4 pthreads */
20854         status = pthread_create( &t, pthread_attr_default, task, NULL );
20855         if( status ) return errno;
20856
20857         /* give thread a chance to complete */
20858         /* it should remain joinable and hence detachable */
20859         sleep( 1 );
20860
20861         status = pthread_detach( &t );
20862         if( status ) return errno;
20863 #endif
20864
20865 #ifdef HAVE_LINUX_THREADS
20866         pthread_kill_other_threads_np();
20867 #endif
20868
20869         return 0;
20870
20871 }
20872
20873 _ACEOF
20874 rm -f conftest$ac_exeext
20875 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20876   (eval $ac_link) 2>&5
20877   ac_status=$?
20878   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20879   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20880   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20881   (eval $ac_try) 2>&5
20882   ac_status=$?
20883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20884   (exit $ac_status); }; }; then
20885   ol_cv_pthread_mthreads=yes
20886 else
20887   echo "$as_me: program exited with status $ac_status" >&5
20888 echo "$as_me: failed program was:" >&5
20889 sed 's/^/| /' conftest.$ac_ext >&5
20890
20891 ( exit $ac_status )
20892 ol_cv_pthread_mthreads=no
20893 fi
20894 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20895 fi
20896
20897                 # restore the LIBS
20898                 LIBS="$ol_LIBS"
20899
20900 fi
20901 echo "$as_me:$LINENO: result: $ol_cv_pthread_mthreads" >&5
20902 echo "${ECHO_T}$ol_cv_pthread_mthreads" >&6
20903
20904         if test $ol_cv_pthread_mthreads = yes ; then
20905                 ol_link_pthreads="-mthreads"
20906                 ol_link_threads=posix
20907         fi
20908 fi
20909
20910                 # Pthread try link: -thread (ol_cv_pthread_thread)
20911 if test "$ol_link_threads" = no ; then
20912         # try -thread
20913         echo "$as_me:$LINENO: checking for pthread link with -thread" >&5
20914 echo $ECHO_N "checking for pthread link with -thread... $ECHO_C" >&6
20915 if test "${ol_cv_pthread_thread+set}" = set; then
20916   echo $ECHO_N "(cached) $ECHO_C" >&6
20917 else
20918
20919                 # save the flags
20920                 ol_LIBS="$LIBS"
20921                 LIBS="-thread $LIBS"
20922
20923                 if test "$cross_compiling" = yes; then
20924   cat >conftest.$ac_ext <<_ACEOF
20925 /* confdefs.h.  */
20926 _ACEOF
20927 cat confdefs.h >>conftest.$ac_ext
20928 cat >>conftest.$ac_ext <<_ACEOF
20929 /* end confdefs.h.  */
20930
20931 /* pthread test headers */
20932 #include <pthread.h>
20933 #if HAVE_PTHREADS < 7
20934 #include <errno.h>
20935 #endif
20936 #ifndef NULL
20937 #define NULL (void*)0
20938 #endif
20939
20940 static void *task(p)
20941         void *p;
20942 {
20943         return (void *) (p == NULL);
20944 }
20945
20946 int
20947 main ()
20948 {
20949
20950         /* pthread test function */
20951 #ifndef PTHREAD_CREATE_DETACHED
20952 #define PTHREAD_CREATE_DETACHED 1
20953 #endif
20954         pthread_t t;
20955         int status;
20956         int detach = PTHREAD_CREATE_DETACHED;
20957
20958 #if HAVE_PTHREADS > 4
20959         /* Final pthreads */
20960         pthread_attr_t attr;
20961
20962         status = pthread_attr_init(&attr);
20963         if( status ) return status;
20964
20965 #if HAVE_PTHREADS < 7
20966         status = pthread_attr_setdetachstate(&attr, &detach);
20967         if( status < 0 ) status = errno;
20968 #else
20969         status = pthread_attr_setdetachstate(&attr, detach);
20970 #endif
20971         if( status ) return status;
20972         status = pthread_create( &t, &attr, task, NULL );
20973 #if HAVE_PTHREADS < 7
20974         if( status < 0 ) status = errno;
20975 #endif
20976         if( status ) return status;
20977 #else
20978         /* Draft 4 pthreads */
20979         status = pthread_create( &t, pthread_attr_default, task, NULL );
20980         if( status ) return errno;
20981
20982         /* give thread a chance to complete */
20983         /* it should remain joinable and hence detachable */
20984         sleep( 1 );
20985
20986         status = pthread_detach( &t );
20987         if( status ) return errno;
20988 #endif
20989
20990 #ifdef HAVE_LINUX_THREADS
20991         pthread_kill_other_threads_np();
20992 #endif
20993
20994         return 0;
20995
20996   ;
20997   return 0;
20998 }
20999 _ACEOF
21000 rm -f conftest.$ac_objext conftest$ac_exeext
21001 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21002   (eval $ac_link) 2>conftest.er1
21003   ac_status=$?
21004   grep -v '^ *+' conftest.er1 >conftest.err
21005   rm -f conftest.er1
21006   cat conftest.err >&5
21007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21008   (exit $ac_status); } &&
21009          { ac_try='test -z "$ac_c_werror_flag"
21010                          || test ! -s conftest.err'
21011   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21012   (eval $ac_try) 2>&5
21013   ac_status=$?
21014   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21015   (exit $ac_status); }; } &&
21016          { ac_try='test -s conftest$ac_exeext'
21017   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21018   (eval $ac_try) 2>&5
21019   ac_status=$?
21020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21021   (exit $ac_status); }; }; then
21022   ol_cv_pthread_thread=yes
21023 else
21024   echo "$as_me: failed program was:" >&5
21025 sed 's/^/| /' conftest.$ac_ext >&5
21026
21027 ol_cv_pthread_thread=no
21028 fi
21029 rm -f conftest.err conftest.$ac_objext \
21030       conftest$ac_exeext conftest.$ac_ext
21031 else
21032   cat >conftest.$ac_ext <<_ACEOF
21033 /* confdefs.h.  */
21034 _ACEOF
21035 cat confdefs.h >>conftest.$ac_ext
21036 cat >>conftest.$ac_ext <<_ACEOF
21037 /* end confdefs.h.  */
21038
21039 /* pthread test headers */
21040 #include <pthread.h>
21041 #if HAVE_PTHREADS < 7
21042 #include <errno.h>
21043 #endif
21044 #ifndef NULL
21045 #define NULL (void*)0
21046 #endif
21047
21048 static void *task(p)
21049         void *p;
21050 {
21051         return (void *) (p == NULL);
21052 }
21053
21054
21055 int main(argc, argv)
21056         int argc;
21057         char **argv;
21058 {
21059
21060         /* pthread test function */
21061 #ifndef PTHREAD_CREATE_DETACHED
21062 #define PTHREAD_CREATE_DETACHED 1
21063 #endif
21064         pthread_t t;
21065         int status;
21066         int detach = PTHREAD_CREATE_DETACHED;
21067
21068 #if HAVE_PTHREADS > 4
21069         /* Final pthreads */
21070         pthread_attr_t attr;
21071
21072         status = pthread_attr_init(&attr);
21073         if( status ) return status;
21074
21075 #if HAVE_PTHREADS < 7
21076         status = pthread_attr_setdetachstate(&attr, &detach);
21077         if( status < 0 ) status = errno;
21078 #else
21079         status = pthread_attr_setdetachstate(&attr, detach);
21080 #endif
21081         if( status ) return status;
21082         status = pthread_create( &t, &attr, task, NULL );
21083 #if HAVE_PTHREADS < 7
21084         if( status < 0 ) status = errno;
21085 #endif
21086         if( status ) return status;
21087 #else
21088         /* Draft 4 pthreads */
21089         status = pthread_create( &t, pthread_attr_default, task, NULL );
21090         if( status ) return errno;
21091
21092         /* give thread a chance to complete */
21093         /* it should remain joinable and hence detachable */
21094         sleep( 1 );
21095
21096         status = pthread_detach( &t );
21097         if( status ) return errno;
21098 #endif
21099
21100 #ifdef HAVE_LINUX_THREADS
21101         pthread_kill_other_threads_np();
21102 #endif
21103
21104         return 0;
21105
21106 }
21107
21108 _ACEOF
21109 rm -f conftest$ac_exeext
21110 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21111   (eval $ac_link) 2>&5
21112   ac_status=$?
21113   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21114   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21115   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21116   (eval $ac_try) 2>&5
21117   ac_status=$?
21118   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21119   (exit $ac_status); }; }; then
21120   ol_cv_pthread_thread=yes
21121 else
21122   echo "$as_me: program exited with status $ac_status" >&5
21123 echo "$as_me: failed program was:" >&5
21124 sed 's/^/| /' conftest.$ac_ext >&5
21125
21126 ( exit $ac_status )
21127 ol_cv_pthread_thread=no
21128 fi
21129 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21130 fi
21131
21132                 # restore the LIBS
21133                 LIBS="$ol_LIBS"
21134
21135 fi
21136 echo "$as_me:$LINENO: result: $ol_cv_pthread_thread" >&5
21137 echo "${ECHO_T}$ol_cv_pthread_thread" >&6
21138
21139         if test $ol_cv_pthread_thread = yes ; then
21140                 ol_link_pthreads="-thread"
21141                 ol_link_threads=posix
21142         fi
21143 fi
21144
21145
21146                 # Pthread try link: -lpthread -lmach -lexc -lc_r (ol_cv_pthread_lpthread_lmach_lexc_lc_r)
21147 if test "$ol_link_threads" = no ; then
21148         # try -lpthread -lmach -lexc -lc_r
21149         echo "$as_me:$LINENO: checking for pthread link with -lpthread -lmach -lexc -lc_r" >&5
21150 echo $ECHO_N "checking for pthread link with -lpthread -lmach -lexc -lc_r... $ECHO_C" >&6
21151 if test "${ol_cv_pthread_lpthread_lmach_lexc_lc_r+set}" = set; then
21152   echo $ECHO_N "(cached) $ECHO_C" >&6
21153 else
21154
21155                 # save the flags
21156                 ol_LIBS="$LIBS"
21157                 LIBS="-lpthread -lmach -lexc -lc_r $LIBS"
21158
21159                 if test "$cross_compiling" = yes; then
21160   cat >conftest.$ac_ext <<_ACEOF
21161 /* confdefs.h.  */
21162 _ACEOF
21163 cat confdefs.h >>conftest.$ac_ext
21164 cat >>conftest.$ac_ext <<_ACEOF
21165 /* end confdefs.h.  */
21166
21167 /* pthread test headers */
21168 #include <pthread.h>
21169 #if HAVE_PTHREADS < 7
21170 #include <errno.h>
21171 #endif
21172 #ifndef NULL
21173 #define NULL (void*)0
21174 #endif
21175
21176 static void *task(p)
21177         void *p;
21178 {
21179         return (void *) (p == NULL);
21180 }
21181
21182 int
21183 main ()
21184 {
21185
21186         /* pthread test function */
21187 #ifndef PTHREAD_CREATE_DETACHED
21188 #define PTHREAD_CREATE_DETACHED 1
21189 #endif
21190         pthread_t t;
21191         int status;
21192         int detach = PTHREAD_CREATE_DETACHED;
21193
21194 #if HAVE_PTHREADS > 4
21195         /* Final pthreads */
21196         pthread_attr_t attr;
21197
21198         status = pthread_attr_init(&attr);
21199         if( status ) return status;
21200
21201 #if HAVE_PTHREADS < 7
21202         status = pthread_attr_setdetachstate(&attr, &detach);
21203         if( status < 0 ) status = errno;
21204 #else
21205         status = pthread_attr_setdetachstate(&attr, detach);
21206 #endif
21207         if( status ) return status;
21208         status = pthread_create( &t, &attr, task, NULL );
21209 #if HAVE_PTHREADS < 7
21210         if( status < 0 ) status = errno;
21211 #endif
21212         if( status ) return status;
21213 #else
21214         /* Draft 4 pthreads */
21215         status = pthread_create( &t, pthread_attr_default, task, NULL );
21216         if( status ) return errno;
21217
21218         /* give thread a chance to complete */
21219         /* it should remain joinable and hence detachable */
21220         sleep( 1 );
21221
21222         status = pthread_detach( &t );
21223         if( status ) return errno;
21224 #endif
21225
21226 #ifdef HAVE_LINUX_THREADS
21227         pthread_kill_other_threads_np();
21228 #endif
21229
21230         return 0;
21231
21232   ;
21233   return 0;
21234 }
21235 _ACEOF
21236 rm -f conftest.$ac_objext conftest$ac_exeext
21237 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21238   (eval $ac_link) 2>conftest.er1
21239   ac_status=$?
21240   grep -v '^ *+' conftest.er1 >conftest.err
21241   rm -f conftest.er1
21242   cat conftest.err >&5
21243   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21244   (exit $ac_status); } &&
21245          { ac_try='test -z "$ac_c_werror_flag"
21246                          || test ! -s conftest.err'
21247   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21248   (eval $ac_try) 2>&5
21249   ac_status=$?
21250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21251   (exit $ac_status); }; } &&
21252          { ac_try='test -s conftest$ac_exeext'
21253   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21254   (eval $ac_try) 2>&5
21255   ac_status=$?
21256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21257   (exit $ac_status); }; }; then
21258   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
21259 else
21260   echo "$as_me: failed program was:" >&5
21261 sed 's/^/| /' conftest.$ac_ext >&5
21262
21263 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
21264 fi
21265 rm -f conftest.err conftest.$ac_objext \
21266       conftest$ac_exeext conftest.$ac_ext
21267 else
21268   cat >conftest.$ac_ext <<_ACEOF
21269 /* confdefs.h.  */
21270 _ACEOF
21271 cat confdefs.h >>conftest.$ac_ext
21272 cat >>conftest.$ac_ext <<_ACEOF
21273 /* end confdefs.h.  */
21274
21275 /* pthread test headers */
21276 #include <pthread.h>
21277 #if HAVE_PTHREADS < 7
21278 #include <errno.h>
21279 #endif
21280 #ifndef NULL
21281 #define NULL (void*)0
21282 #endif
21283
21284 static void *task(p)
21285         void *p;
21286 {
21287         return (void *) (p == NULL);
21288 }
21289
21290
21291 int main(argc, argv)
21292         int argc;
21293         char **argv;
21294 {
21295
21296         /* pthread test function */
21297 #ifndef PTHREAD_CREATE_DETACHED
21298 #define PTHREAD_CREATE_DETACHED 1
21299 #endif
21300         pthread_t t;
21301         int status;
21302         int detach = PTHREAD_CREATE_DETACHED;
21303
21304 #if HAVE_PTHREADS > 4
21305         /* Final pthreads */
21306         pthread_attr_t attr;
21307
21308         status = pthread_attr_init(&attr);
21309         if( status ) return status;
21310
21311 #if HAVE_PTHREADS < 7
21312         status = pthread_attr_setdetachstate(&attr, &detach);
21313         if( status < 0 ) status = errno;
21314 #else
21315         status = pthread_attr_setdetachstate(&attr, detach);
21316 #endif
21317         if( status ) return status;
21318         status = pthread_create( &t, &attr, task, NULL );
21319 #if HAVE_PTHREADS < 7
21320         if( status < 0 ) status = errno;
21321 #endif
21322         if( status ) return status;
21323 #else
21324         /* Draft 4 pthreads */
21325         status = pthread_create( &t, pthread_attr_default, task, NULL );
21326         if( status ) return errno;
21327
21328         /* give thread a chance to complete */
21329         /* it should remain joinable and hence detachable */
21330         sleep( 1 );
21331
21332         status = pthread_detach( &t );
21333         if( status ) return errno;
21334 #endif
21335
21336 #ifdef HAVE_LINUX_THREADS
21337         pthread_kill_other_threads_np();
21338 #endif
21339
21340         return 0;
21341
21342 }
21343
21344 _ACEOF
21345 rm -f conftest$ac_exeext
21346 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21347   (eval $ac_link) 2>&5
21348   ac_status=$?
21349   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21350   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21351   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21352   (eval $ac_try) 2>&5
21353   ac_status=$?
21354   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21355   (exit $ac_status); }; }; then
21356   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
21357 else
21358   echo "$as_me: program exited with status $ac_status" >&5
21359 echo "$as_me: failed program was:" >&5
21360 sed 's/^/| /' conftest.$ac_ext >&5
21361
21362 ( exit $ac_status )
21363 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
21364 fi
21365 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21366 fi
21367
21368                 # restore the LIBS
21369                 LIBS="$ol_LIBS"
21370
21371 fi
21372 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&5
21373 echo "${ECHO_T}$ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&6
21374
21375         if test $ol_cv_pthread_lpthread_lmach_lexc_lc_r = yes ; then
21376                 ol_link_pthreads="-lpthread -lmach -lexc -lc_r"
21377                 ol_link_threads=posix
21378         fi
21379 fi
21380
21381                 # Pthread try link: -lpthread -lmach -lexc (ol_cv_pthread_lpthread_lmach_lexc)
21382 if test "$ol_link_threads" = no ; then
21383         # try -lpthread -lmach -lexc
21384         echo "$as_me:$LINENO: checking for pthread link with -lpthread -lmach -lexc" >&5
21385 echo $ECHO_N "checking for pthread link with -lpthread -lmach -lexc... $ECHO_C" >&6
21386 if test "${ol_cv_pthread_lpthread_lmach_lexc+set}" = set; then
21387   echo $ECHO_N "(cached) $ECHO_C" >&6
21388 else
21389
21390                 # save the flags
21391                 ol_LIBS="$LIBS"
21392                 LIBS="-lpthread -lmach -lexc $LIBS"
21393
21394                 if test "$cross_compiling" = yes; then
21395   cat >conftest.$ac_ext <<_ACEOF
21396 /* confdefs.h.  */
21397 _ACEOF
21398 cat confdefs.h >>conftest.$ac_ext
21399 cat >>conftest.$ac_ext <<_ACEOF
21400 /* end confdefs.h.  */
21401
21402 /* pthread test headers */
21403 #include <pthread.h>
21404 #if HAVE_PTHREADS < 7
21405 #include <errno.h>
21406 #endif
21407 #ifndef NULL
21408 #define NULL (void*)0
21409 #endif
21410
21411 static void *task(p)
21412         void *p;
21413 {
21414         return (void *) (p == NULL);
21415 }
21416
21417 int
21418 main ()
21419 {
21420
21421         /* pthread test function */
21422 #ifndef PTHREAD_CREATE_DETACHED
21423 #define PTHREAD_CREATE_DETACHED 1
21424 #endif
21425         pthread_t t;
21426         int status;
21427         int detach = PTHREAD_CREATE_DETACHED;
21428
21429 #if HAVE_PTHREADS > 4
21430         /* Final pthreads */
21431         pthread_attr_t attr;
21432
21433         status = pthread_attr_init(&attr);
21434         if( status ) return status;
21435
21436 #if HAVE_PTHREADS < 7
21437         status = pthread_attr_setdetachstate(&attr, &detach);
21438         if( status < 0 ) status = errno;
21439 #else
21440         status = pthread_attr_setdetachstate(&attr, detach);
21441 #endif
21442         if( status ) return status;
21443         status = pthread_create( &t, &attr, task, NULL );
21444 #if HAVE_PTHREADS < 7
21445         if( status < 0 ) status = errno;
21446 #endif
21447         if( status ) return status;
21448 #else
21449         /* Draft 4 pthreads */
21450         status = pthread_create( &t, pthread_attr_default, task, NULL );
21451         if( status ) return errno;
21452
21453         /* give thread a chance to complete */
21454         /* it should remain joinable and hence detachable */
21455         sleep( 1 );
21456
21457         status = pthread_detach( &t );
21458         if( status ) return errno;
21459 #endif
21460
21461 #ifdef HAVE_LINUX_THREADS
21462         pthread_kill_other_threads_np();
21463 #endif
21464
21465         return 0;
21466
21467   ;
21468   return 0;
21469 }
21470 _ACEOF
21471 rm -f conftest.$ac_objext conftest$ac_exeext
21472 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21473   (eval $ac_link) 2>conftest.er1
21474   ac_status=$?
21475   grep -v '^ *+' conftest.er1 >conftest.err
21476   rm -f conftest.er1
21477   cat conftest.err >&5
21478   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21479   (exit $ac_status); } &&
21480          { ac_try='test -z "$ac_c_werror_flag"
21481                          || test ! -s conftest.err'
21482   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21483   (eval $ac_try) 2>&5
21484   ac_status=$?
21485   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21486   (exit $ac_status); }; } &&
21487          { ac_try='test -s conftest$ac_exeext'
21488   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21489   (eval $ac_try) 2>&5
21490   ac_status=$?
21491   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21492   (exit $ac_status); }; }; then
21493   ol_cv_pthread_lpthread_lmach_lexc=yes
21494 else
21495   echo "$as_me: failed program was:" >&5
21496 sed 's/^/| /' conftest.$ac_ext >&5
21497
21498 ol_cv_pthread_lpthread_lmach_lexc=no
21499 fi
21500 rm -f conftest.err conftest.$ac_objext \
21501       conftest$ac_exeext conftest.$ac_ext
21502 else
21503   cat >conftest.$ac_ext <<_ACEOF
21504 /* confdefs.h.  */
21505 _ACEOF
21506 cat confdefs.h >>conftest.$ac_ext
21507 cat >>conftest.$ac_ext <<_ACEOF
21508 /* end confdefs.h.  */
21509
21510 /* pthread test headers */
21511 #include <pthread.h>
21512 #if HAVE_PTHREADS < 7
21513 #include <errno.h>
21514 #endif
21515 #ifndef NULL
21516 #define NULL (void*)0
21517 #endif
21518
21519 static void *task(p)
21520         void *p;
21521 {
21522         return (void *) (p == NULL);
21523 }
21524
21525
21526 int main(argc, argv)
21527         int argc;
21528         char **argv;
21529 {
21530
21531         /* pthread test function */
21532 #ifndef PTHREAD_CREATE_DETACHED
21533 #define PTHREAD_CREATE_DETACHED 1
21534 #endif
21535         pthread_t t;
21536         int status;
21537         int detach = PTHREAD_CREATE_DETACHED;
21538
21539 #if HAVE_PTHREADS > 4
21540         /* Final pthreads */
21541         pthread_attr_t attr;
21542
21543         status = pthread_attr_init(&attr);
21544         if( status ) return status;
21545
21546 #if HAVE_PTHREADS < 7
21547         status = pthread_attr_setdetachstate(&attr, &detach);
21548         if( status < 0 ) status = errno;
21549 #else
21550         status = pthread_attr_setdetachstate(&attr, detach);
21551 #endif
21552         if( status ) return status;
21553         status = pthread_create( &t, &attr, task, NULL );
21554 #if HAVE_PTHREADS < 7
21555         if( status < 0 ) status = errno;
21556 #endif
21557         if( status ) return status;
21558 #else
21559         /* Draft 4 pthreads */
21560         status = pthread_create( &t, pthread_attr_default, task, NULL );
21561         if( status ) return errno;
21562
21563         /* give thread a chance to complete */
21564         /* it should remain joinable and hence detachable */
21565         sleep( 1 );
21566
21567         status = pthread_detach( &t );
21568         if( status ) return errno;
21569 #endif
21570
21571 #ifdef HAVE_LINUX_THREADS
21572         pthread_kill_other_threads_np();
21573 #endif
21574
21575         return 0;
21576
21577 }
21578
21579 _ACEOF
21580 rm -f conftest$ac_exeext
21581 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21582   (eval $ac_link) 2>&5
21583   ac_status=$?
21584   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21585   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21586   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21587   (eval $ac_try) 2>&5
21588   ac_status=$?
21589   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21590   (exit $ac_status); }; }; then
21591   ol_cv_pthread_lpthread_lmach_lexc=yes
21592 else
21593   echo "$as_me: program exited with status $ac_status" >&5
21594 echo "$as_me: failed program was:" >&5
21595 sed 's/^/| /' conftest.$ac_ext >&5
21596
21597 ( exit $ac_status )
21598 ol_cv_pthread_lpthread_lmach_lexc=no
21599 fi
21600 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21601 fi
21602
21603                 # restore the LIBS
21604                 LIBS="$ol_LIBS"
21605
21606 fi
21607 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread_lmach_lexc" >&5
21608 echo "${ECHO_T}$ol_cv_pthread_lpthread_lmach_lexc" >&6
21609
21610         if test $ol_cv_pthread_lpthread_lmach_lexc = yes ; then
21611                 ol_link_pthreads="-lpthread -lmach -lexc"
21612                 ol_link_threads=posix
21613         fi
21614 fi
21615
21616
21617                 # Pthread try link: -lpthread -Wl,-woff,85 (ol_cv_pthread_lib_lpthread_woff)
21618 if test "$ol_link_threads" = no ; then
21619         # try -lpthread -Wl,-woff,85
21620         echo "$as_me:$LINENO: checking for pthread link with -lpthread -Wl,-woff,85" >&5
21621 echo $ECHO_N "checking for pthread link with -lpthread -Wl,-woff,85... $ECHO_C" >&6
21622 if test "${ol_cv_pthread_lib_lpthread_woff+set}" = set; then
21623   echo $ECHO_N "(cached) $ECHO_C" >&6
21624 else
21625
21626                 # save the flags
21627                 ol_LIBS="$LIBS"
21628                 LIBS="-lpthread -Wl,-woff,85 $LIBS"
21629
21630                 if test "$cross_compiling" = yes; then
21631   cat >conftest.$ac_ext <<_ACEOF
21632 /* confdefs.h.  */
21633 _ACEOF
21634 cat confdefs.h >>conftest.$ac_ext
21635 cat >>conftest.$ac_ext <<_ACEOF
21636 /* end confdefs.h.  */
21637
21638 /* pthread test headers */
21639 #include <pthread.h>
21640 #if HAVE_PTHREADS < 7
21641 #include <errno.h>
21642 #endif
21643 #ifndef NULL
21644 #define NULL (void*)0
21645 #endif
21646
21647 static void *task(p)
21648         void *p;
21649 {
21650         return (void *) (p == NULL);
21651 }
21652
21653 int
21654 main ()
21655 {
21656
21657         /* pthread test function */
21658 #ifndef PTHREAD_CREATE_DETACHED
21659 #define PTHREAD_CREATE_DETACHED 1
21660 #endif
21661         pthread_t t;
21662         int status;
21663         int detach = PTHREAD_CREATE_DETACHED;
21664
21665 #if HAVE_PTHREADS > 4
21666         /* Final pthreads */
21667         pthread_attr_t attr;
21668
21669         status = pthread_attr_init(&attr);
21670         if( status ) return status;
21671
21672 #if HAVE_PTHREADS < 7
21673         status = pthread_attr_setdetachstate(&attr, &detach);
21674         if( status < 0 ) status = errno;
21675 #else
21676         status = pthread_attr_setdetachstate(&attr, detach);
21677 #endif
21678         if( status ) return status;
21679         status = pthread_create( &t, &attr, task, NULL );
21680 #if HAVE_PTHREADS < 7
21681         if( status < 0 ) status = errno;
21682 #endif
21683         if( status ) return status;
21684 #else
21685         /* Draft 4 pthreads */
21686         status = pthread_create( &t, pthread_attr_default, task, NULL );
21687         if( status ) return errno;
21688
21689         /* give thread a chance to complete */
21690         /* it should remain joinable and hence detachable */
21691         sleep( 1 );
21692
21693         status = pthread_detach( &t );
21694         if( status ) return errno;
21695 #endif
21696
21697 #ifdef HAVE_LINUX_THREADS
21698         pthread_kill_other_threads_np();
21699 #endif
21700
21701         return 0;
21702
21703   ;
21704   return 0;
21705 }
21706 _ACEOF
21707 rm -f conftest.$ac_objext conftest$ac_exeext
21708 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21709   (eval $ac_link) 2>conftest.er1
21710   ac_status=$?
21711   grep -v '^ *+' conftest.er1 >conftest.err
21712   rm -f conftest.er1
21713   cat conftest.err >&5
21714   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21715   (exit $ac_status); } &&
21716          { ac_try='test -z "$ac_c_werror_flag"
21717                          || test ! -s conftest.err'
21718   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21719   (eval $ac_try) 2>&5
21720   ac_status=$?
21721   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21722   (exit $ac_status); }; } &&
21723          { ac_try='test -s conftest$ac_exeext'
21724   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21725   (eval $ac_try) 2>&5
21726   ac_status=$?
21727   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21728   (exit $ac_status); }; }; then
21729   ol_cv_pthread_lib_lpthread_woff=yes
21730 else
21731   echo "$as_me: failed program was:" >&5
21732 sed 's/^/| /' conftest.$ac_ext >&5
21733
21734 ol_cv_pthread_lib_lpthread_woff=no
21735 fi
21736 rm -f conftest.err conftest.$ac_objext \
21737       conftest$ac_exeext conftest.$ac_ext
21738 else
21739   cat >conftest.$ac_ext <<_ACEOF
21740 /* confdefs.h.  */
21741 _ACEOF
21742 cat confdefs.h >>conftest.$ac_ext
21743 cat >>conftest.$ac_ext <<_ACEOF
21744 /* end confdefs.h.  */
21745
21746 /* pthread test headers */
21747 #include <pthread.h>
21748 #if HAVE_PTHREADS < 7
21749 #include <errno.h>
21750 #endif
21751 #ifndef NULL
21752 #define NULL (void*)0
21753 #endif
21754
21755 static void *task(p)
21756         void *p;
21757 {
21758         return (void *) (p == NULL);
21759 }
21760
21761
21762 int main(argc, argv)
21763         int argc;
21764         char **argv;
21765 {
21766
21767         /* pthread test function */
21768 #ifndef PTHREAD_CREATE_DETACHED
21769 #define PTHREAD_CREATE_DETACHED 1
21770 #endif
21771         pthread_t t;
21772         int status;
21773         int detach = PTHREAD_CREATE_DETACHED;
21774
21775 #if HAVE_PTHREADS > 4
21776         /* Final pthreads */
21777         pthread_attr_t attr;
21778
21779         status = pthread_attr_init(&attr);
21780         if( status ) return status;
21781
21782 #if HAVE_PTHREADS < 7
21783         status = pthread_attr_setdetachstate(&attr, &detach);
21784         if( status < 0 ) status = errno;
21785 #else
21786         status = pthread_attr_setdetachstate(&attr, detach);
21787 #endif
21788         if( status ) return status;
21789         status = pthread_create( &t, &attr, task, NULL );
21790 #if HAVE_PTHREADS < 7
21791         if( status < 0 ) status = errno;
21792 #endif
21793         if( status ) return status;
21794 #else
21795         /* Draft 4 pthreads */
21796         status = pthread_create( &t, pthread_attr_default, task, NULL );
21797         if( status ) return errno;
21798
21799         /* give thread a chance to complete */
21800         /* it should remain joinable and hence detachable */
21801         sleep( 1 );
21802
21803         status = pthread_detach( &t );
21804         if( status ) return errno;
21805 #endif
21806
21807 #ifdef HAVE_LINUX_THREADS
21808         pthread_kill_other_threads_np();
21809 #endif
21810
21811         return 0;
21812
21813 }
21814
21815 _ACEOF
21816 rm -f conftest$ac_exeext
21817 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21818   (eval $ac_link) 2>&5
21819   ac_status=$?
21820   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21821   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21822   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21823   (eval $ac_try) 2>&5
21824   ac_status=$?
21825   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21826   (exit $ac_status); }; }; then
21827   ol_cv_pthread_lib_lpthread_woff=yes
21828 else
21829   echo "$as_me: program exited with status $ac_status" >&5
21830 echo "$as_me: failed program was:" >&5
21831 sed 's/^/| /' conftest.$ac_ext >&5
21832
21833 ( exit $ac_status )
21834 ol_cv_pthread_lib_lpthread_woff=no
21835 fi
21836 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21837 fi
21838
21839                 # restore the LIBS
21840                 LIBS="$ol_LIBS"
21841
21842 fi
21843 echo "$as_me:$LINENO: result: $ol_cv_pthread_lib_lpthread_woff" >&5
21844 echo "${ECHO_T}$ol_cv_pthread_lib_lpthread_woff" >&6
21845
21846         if test $ol_cv_pthread_lib_lpthread_woff = yes ; then
21847                 ol_link_pthreads="-lpthread -Wl,-woff,85"
21848                 ol_link_threads=posix
21849         fi
21850 fi
21851
21852
21853                 # Pthread try link: -lpthread (ol_cv_pthread_lpthread)
21854 if test "$ol_link_threads" = no ; then
21855         # try -lpthread
21856         echo "$as_me:$LINENO: checking for pthread link with -lpthread" >&5
21857 echo $ECHO_N "checking for pthread link with -lpthread... $ECHO_C" >&6
21858 if test "${ol_cv_pthread_lpthread+set}" = set; then
21859   echo $ECHO_N "(cached) $ECHO_C" >&6
21860 else
21861
21862                 # save the flags
21863                 ol_LIBS="$LIBS"
21864                 LIBS="-lpthread $LIBS"
21865
21866                 if test "$cross_compiling" = yes; then
21867   cat >conftest.$ac_ext <<_ACEOF
21868 /* confdefs.h.  */
21869 _ACEOF
21870 cat confdefs.h >>conftest.$ac_ext
21871 cat >>conftest.$ac_ext <<_ACEOF
21872 /* end confdefs.h.  */
21873
21874 /* pthread test headers */
21875 #include <pthread.h>
21876 #if HAVE_PTHREADS < 7
21877 #include <errno.h>
21878 #endif
21879 #ifndef NULL
21880 #define NULL (void*)0
21881 #endif
21882
21883 static void *task(p)
21884         void *p;
21885 {
21886         return (void *) (p == NULL);
21887 }
21888
21889 int
21890 main ()
21891 {
21892
21893         /* pthread test function */
21894 #ifndef PTHREAD_CREATE_DETACHED
21895 #define PTHREAD_CREATE_DETACHED 1
21896 #endif
21897         pthread_t t;
21898         int status;
21899         int detach = PTHREAD_CREATE_DETACHED;
21900
21901 #if HAVE_PTHREADS > 4
21902         /* Final pthreads */
21903         pthread_attr_t attr;
21904
21905         status = pthread_attr_init(&attr);
21906         if( status ) return status;
21907
21908 #if HAVE_PTHREADS < 7
21909         status = pthread_attr_setdetachstate(&attr, &detach);
21910         if( status < 0 ) status = errno;
21911 #else
21912         status = pthread_attr_setdetachstate(&attr, detach);
21913 #endif
21914         if( status ) return status;
21915         status = pthread_create( &t, &attr, task, NULL );
21916 #if HAVE_PTHREADS < 7
21917         if( status < 0 ) status = errno;
21918 #endif
21919         if( status ) return status;
21920 #else
21921         /* Draft 4 pthreads */
21922         status = pthread_create( &t, pthread_attr_default, task, NULL );
21923         if( status ) return errno;
21924
21925         /* give thread a chance to complete */
21926         /* it should remain joinable and hence detachable */
21927         sleep( 1 );
21928
21929         status = pthread_detach( &t );
21930         if( status ) return errno;
21931 #endif
21932
21933 #ifdef HAVE_LINUX_THREADS
21934         pthread_kill_other_threads_np();
21935 #endif
21936
21937         return 0;
21938
21939   ;
21940   return 0;
21941 }
21942 _ACEOF
21943 rm -f conftest.$ac_objext conftest$ac_exeext
21944 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21945   (eval $ac_link) 2>conftest.er1
21946   ac_status=$?
21947   grep -v '^ *+' conftest.er1 >conftest.err
21948   rm -f conftest.er1
21949   cat conftest.err >&5
21950   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21951   (exit $ac_status); } &&
21952          { ac_try='test -z "$ac_c_werror_flag"
21953                          || test ! -s conftest.err'
21954   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21955   (eval $ac_try) 2>&5
21956   ac_status=$?
21957   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21958   (exit $ac_status); }; } &&
21959          { ac_try='test -s conftest$ac_exeext'
21960   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21961   (eval $ac_try) 2>&5
21962   ac_status=$?
21963   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21964   (exit $ac_status); }; }; then
21965   ol_cv_pthread_lpthread=yes
21966 else
21967   echo "$as_me: failed program was:" >&5
21968 sed 's/^/| /' conftest.$ac_ext >&5
21969
21970 ol_cv_pthread_lpthread=no
21971 fi
21972 rm -f conftest.err conftest.$ac_objext \
21973       conftest$ac_exeext conftest.$ac_ext
21974 else
21975   cat >conftest.$ac_ext <<_ACEOF
21976 /* confdefs.h.  */
21977 _ACEOF
21978 cat confdefs.h >>conftest.$ac_ext
21979 cat >>conftest.$ac_ext <<_ACEOF
21980 /* end confdefs.h.  */
21981
21982 /* pthread test headers */
21983 #include <pthread.h>
21984 #if HAVE_PTHREADS < 7
21985 #include <errno.h>
21986 #endif
21987 #ifndef NULL
21988 #define NULL (void*)0
21989 #endif
21990
21991 static void *task(p)
21992         void *p;
21993 {
21994         return (void *) (p == NULL);
21995 }
21996
21997
21998 int main(argc, argv)
21999         int argc;
22000         char **argv;
22001 {
22002
22003         /* pthread test function */
22004 #ifndef PTHREAD_CREATE_DETACHED
22005 #define PTHREAD_CREATE_DETACHED 1
22006 #endif
22007         pthread_t t;
22008         int status;
22009         int detach = PTHREAD_CREATE_DETACHED;
22010
22011 #if HAVE_PTHREADS > 4
22012         /* Final pthreads */
22013         pthread_attr_t attr;
22014
22015         status = pthread_attr_init(&attr);
22016         if( status ) return status;
22017
22018 #if HAVE_PTHREADS < 7
22019         status = pthread_attr_setdetachstate(&attr, &detach);
22020         if( status < 0 ) status = errno;
22021 #else
22022         status = pthread_attr_setdetachstate(&attr, detach);
22023 #endif
22024         if( status ) return status;
22025         status = pthread_create( &t, &attr, task, NULL );
22026 #if HAVE_PTHREADS < 7
22027         if( status < 0 ) status = errno;
22028 #endif
22029         if( status ) return status;
22030 #else
22031         /* Draft 4 pthreads */
22032         status = pthread_create( &t, pthread_attr_default, task, NULL );
22033         if( status ) return errno;
22034
22035         /* give thread a chance to complete */
22036         /* it should remain joinable and hence detachable */
22037         sleep( 1 );
22038
22039         status = pthread_detach( &t );
22040         if( status ) return errno;
22041 #endif
22042
22043 #ifdef HAVE_LINUX_THREADS
22044         pthread_kill_other_threads_np();
22045 #endif
22046
22047         return 0;
22048
22049 }
22050
22051 _ACEOF
22052 rm -f conftest$ac_exeext
22053 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22054   (eval $ac_link) 2>&5
22055   ac_status=$?
22056   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22057   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22058   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22059   (eval $ac_try) 2>&5
22060   ac_status=$?
22061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22062   (exit $ac_status); }; }; then
22063   ol_cv_pthread_lpthread=yes
22064 else
22065   echo "$as_me: program exited with status $ac_status" >&5
22066 echo "$as_me: failed program was:" >&5
22067 sed 's/^/| /' conftest.$ac_ext >&5
22068
22069 ( exit $ac_status )
22070 ol_cv_pthread_lpthread=no
22071 fi
22072 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22073 fi
22074
22075                 # restore the LIBS
22076                 LIBS="$ol_LIBS"
22077
22078 fi
22079 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread" >&5
22080 echo "${ECHO_T}$ol_cv_pthread_lpthread" >&6
22081
22082         if test $ol_cv_pthread_lpthread = yes ; then
22083                 ol_link_pthreads="-lpthread"
22084                 ol_link_threads=posix
22085         fi
22086 fi
22087
22088                 # Pthread try link: -lc_r (ol_cv_pthread_lc_r)
22089 if test "$ol_link_threads" = no ; then
22090         # try -lc_r
22091         echo "$as_me:$LINENO: checking for pthread link with -lc_r" >&5
22092 echo $ECHO_N "checking for pthread link with -lc_r... $ECHO_C" >&6
22093 if test "${ol_cv_pthread_lc_r+set}" = set; then
22094   echo $ECHO_N "(cached) $ECHO_C" >&6
22095 else
22096
22097                 # save the flags
22098                 ol_LIBS="$LIBS"
22099                 LIBS="-lc_r $LIBS"
22100
22101                 if test "$cross_compiling" = yes; then
22102   cat >conftest.$ac_ext <<_ACEOF
22103 /* confdefs.h.  */
22104 _ACEOF
22105 cat confdefs.h >>conftest.$ac_ext
22106 cat >>conftest.$ac_ext <<_ACEOF
22107 /* end confdefs.h.  */
22108
22109 /* pthread test headers */
22110 #include <pthread.h>
22111 #if HAVE_PTHREADS < 7
22112 #include <errno.h>
22113 #endif
22114 #ifndef NULL
22115 #define NULL (void*)0
22116 #endif
22117
22118 static void *task(p)
22119         void *p;
22120 {
22121         return (void *) (p == NULL);
22122 }
22123
22124 int
22125 main ()
22126 {
22127
22128         /* pthread test function */
22129 #ifndef PTHREAD_CREATE_DETACHED
22130 #define PTHREAD_CREATE_DETACHED 1
22131 #endif
22132         pthread_t t;
22133         int status;
22134         int detach = PTHREAD_CREATE_DETACHED;
22135
22136 #if HAVE_PTHREADS > 4
22137         /* Final pthreads */
22138         pthread_attr_t attr;
22139
22140         status = pthread_attr_init(&attr);
22141         if( status ) return status;
22142
22143 #if HAVE_PTHREADS < 7
22144         status = pthread_attr_setdetachstate(&attr, &detach);
22145         if( status < 0 ) status = errno;
22146 #else
22147         status = pthread_attr_setdetachstate(&attr, detach);
22148 #endif
22149         if( status ) return status;
22150         status = pthread_create( &t, &attr, task, NULL );
22151 #if HAVE_PTHREADS < 7
22152         if( status < 0 ) status = errno;
22153 #endif
22154         if( status ) return status;
22155 #else
22156         /* Draft 4 pthreads */
22157         status = pthread_create( &t, pthread_attr_default, task, NULL );
22158         if( status ) return errno;
22159
22160         /* give thread a chance to complete */
22161         /* it should remain joinable and hence detachable */
22162         sleep( 1 );
22163
22164         status = pthread_detach( &t );
22165         if( status ) return errno;
22166 #endif
22167
22168 #ifdef HAVE_LINUX_THREADS
22169         pthread_kill_other_threads_np();
22170 #endif
22171
22172         return 0;
22173
22174   ;
22175   return 0;
22176 }
22177 _ACEOF
22178 rm -f conftest.$ac_objext conftest$ac_exeext
22179 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22180   (eval $ac_link) 2>conftest.er1
22181   ac_status=$?
22182   grep -v '^ *+' conftest.er1 >conftest.err
22183   rm -f conftest.er1
22184   cat conftest.err >&5
22185   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22186   (exit $ac_status); } &&
22187          { ac_try='test -z "$ac_c_werror_flag"
22188                          || test ! -s conftest.err'
22189   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22190   (eval $ac_try) 2>&5
22191   ac_status=$?
22192   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22193   (exit $ac_status); }; } &&
22194          { ac_try='test -s conftest$ac_exeext'
22195   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22196   (eval $ac_try) 2>&5
22197   ac_status=$?
22198   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22199   (exit $ac_status); }; }; then
22200   ol_cv_pthread_lc_r=yes
22201 else
22202   echo "$as_me: failed program was:" >&5
22203 sed 's/^/| /' conftest.$ac_ext >&5
22204
22205 ol_cv_pthread_lc_r=no
22206 fi
22207 rm -f conftest.err conftest.$ac_objext \
22208       conftest$ac_exeext conftest.$ac_ext
22209 else
22210   cat >conftest.$ac_ext <<_ACEOF
22211 /* confdefs.h.  */
22212 _ACEOF
22213 cat confdefs.h >>conftest.$ac_ext
22214 cat >>conftest.$ac_ext <<_ACEOF
22215 /* end confdefs.h.  */
22216
22217 /* pthread test headers */
22218 #include <pthread.h>
22219 #if HAVE_PTHREADS < 7
22220 #include <errno.h>
22221 #endif
22222 #ifndef NULL
22223 #define NULL (void*)0
22224 #endif
22225
22226 static void *task(p)
22227         void *p;
22228 {
22229         return (void *) (p == NULL);
22230 }
22231
22232
22233 int main(argc, argv)
22234         int argc;
22235         char **argv;
22236 {
22237
22238         /* pthread test function */
22239 #ifndef PTHREAD_CREATE_DETACHED
22240 #define PTHREAD_CREATE_DETACHED 1
22241 #endif
22242         pthread_t t;
22243         int status;
22244         int detach = PTHREAD_CREATE_DETACHED;
22245
22246 #if HAVE_PTHREADS > 4
22247         /* Final pthreads */
22248         pthread_attr_t attr;
22249
22250         status = pthread_attr_init(&attr);
22251         if( status ) return status;
22252
22253 #if HAVE_PTHREADS < 7
22254         status = pthread_attr_setdetachstate(&attr, &detach);
22255         if( status < 0 ) status = errno;
22256 #else
22257         status = pthread_attr_setdetachstate(&attr, detach);
22258 #endif
22259         if( status ) return status;
22260         status = pthread_create( &t, &attr, task, NULL );
22261 #if HAVE_PTHREADS < 7
22262         if( status < 0 ) status = errno;
22263 #endif
22264         if( status ) return status;
22265 #else
22266         /* Draft 4 pthreads */
22267         status = pthread_create( &t, pthread_attr_default, task, NULL );
22268         if( status ) return errno;
22269
22270         /* give thread a chance to complete */
22271         /* it should remain joinable and hence detachable */
22272         sleep( 1 );
22273
22274         status = pthread_detach( &t );
22275         if( status ) return errno;
22276 #endif
22277
22278 #ifdef HAVE_LINUX_THREADS
22279         pthread_kill_other_threads_np();
22280 #endif
22281
22282         return 0;
22283
22284 }
22285
22286 _ACEOF
22287 rm -f conftest$ac_exeext
22288 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22289   (eval $ac_link) 2>&5
22290   ac_status=$?
22291   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22292   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22293   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22294   (eval $ac_try) 2>&5
22295   ac_status=$?
22296   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22297   (exit $ac_status); }; }; then
22298   ol_cv_pthread_lc_r=yes
22299 else
22300   echo "$as_me: program exited with status $ac_status" >&5
22301 echo "$as_me: failed program was:" >&5
22302 sed 's/^/| /' conftest.$ac_ext >&5
22303
22304 ( exit $ac_status )
22305 ol_cv_pthread_lc_r=no
22306 fi
22307 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22308 fi
22309
22310                 # restore the LIBS
22311                 LIBS="$ol_LIBS"
22312
22313 fi
22314 echo "$as_me:$LINENO: result: $ol_cv_pthread_lc_r" >&5
22315 echo "${ECHO_T}$ol_cv_pthread_lc_r" >&6
22316
22317         if test $ol_cv_pthread_lc_r = yes ; then
22318                 ol_link_pthreads="-lc_r"
22319                 ol_link_threads=posix
22320         fi
22321 fi
22322
22323
22324                 # Pthread try link: -threads (ol_cv_pthread_threads)
22325 if test "$ol_link_threads" = no ; then
22326         # try -threads
22327         echo "$as_me:$LINENO: checking for pthread link with -threads" >&5
22328 echo $ECHO_N "checking for pthread link with -threads... $ECHO_C" >&6
22329 if test "${ol_cv_pthread_threads+set}" = set; then
22330   echo $ECHO_N "(cached) $ECHO_C" >&6
22331 else
22332
22333                 # save the flags
22334                 ol_LIBS="$LIBS"
22335                 LIBS="-threads $LIBS"
22336
22337                 if test "$cross_compiling" = yes; then
22338   cat >conftest.$ac_ext <<_ACEOF
22339 /* confdefs.h.  */
22340 _ACEOF
22341 cat confdefs.h >>conftest.$ac_ext
22342 cat >>conftest.$ac_ext <<_ACEOF
22343 /* end confdefs.h.  */
22344
22345 /* pthread test headers */
22346 #include <pthread.h>
22347 #if HAVE_PTHREADS < 7
22348 #include <errno.h>
22349 #endif
22350 #ifndef NULL
22351 #define NULL (void*)0
22352 #endif
22353
22354 static void *task(p)
22355         void *p;
22356 {
22357         return (void *) (p == NULL);
22358 }
22359
22360 int
22361 main ()
22362 {
22363
22364         /* pthread test function */
22365 #ifndef PTHREAD_CREATE_DETACHED
22366 #define PTHREAD_CREATE_DETACHED 1
22367 #endif
22368         pthread_t t;
22369         int status;
22370         int detach = PTHREAD_CREATE_DETACHED;
22371
22372 #if HAVE_PTHREADS > 4
22373         /* Final pthreads */
22374         pthread_attr_t attr;
22375
22376         status = pthread_attr_init(&attr);
22377         if( status ) return status;
22378
22379 #if HAVE_PTHREADS < 7
22380         status = pthread_attr_setdetachstate(&attr, &detach);
22381         if( status < 0 ) status = errno;
22382 #else
22383         status = pthread_attr_setdetachstate(&attr, detach);
22384 #endif
22385         if( status ) return status;
22386         status = pthread_create( &t, &attr, task, NULL );
22387 #if HAVE_PTHREADS < 7
22388         if( status < 0 ) status = errno;
22389 #endif
22390         if( status ) return status;
22391 #else
22392         /* Draft 4 pthreads */
22393         status = pthread_create( &t, pthread_attr_default, task, NULL );
22394         if( status ) return errno;
22395
22396         /* give thread a chance to complete */
22397         /* it should remain joinable and hence detachable */
22398         sleep( 1 );
22399
22400         status = pthread_detach( &t );
22401         if( status ) return errno;
22402 #endif
22403
22404 #ifdef HAVE_LINUX_THREADS
22405         pthread_kill_other_threads_np();
22406 #endif
22407
22408         return 0;
22409
22410   ;
22411   return 0;
22412 }
22413 _ACEOF
22414 rm -f conftest.$ac_objext conftest$ac_exeext
22415 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22416   (eval $ac_link) 2>conftest.er1
22417   ac_status=$?
22418   grep -v '^ *+' conftest.er1 >conftest.err
22419   rm -f conftest.er1
22420   cat conftest.err >&5
22421   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22422   (exit $ac_status); } &&
22423          { ac_try='test -z "$ac_c_werror_flag"
22424                          || test ! -s conftest.err'
22425   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22426   (eval $ac_try) 2>&5
22427   ac_status=$?
22428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22429   (exit $ac_status); }; } &&
22430          { ac_try='test -s conftest$ac_exeext'
22431   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22432   (eval $ac_try) 2>&5
22433   ac_status=$?
22434   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22435   (exit $ac_status); }; }; then
22436   ol_cv_pthread_threads=yes
22437 else
22438   echo "$as_me: failed program was:" >&5
22439 sed 's/^/| /' conftest.$ac_ext >&5
22440
22441 ol_cv_pthread_threads=no
22442 fi
22443 rm -f conftest.err conftest.$ac_objext \
22444       conftest$ac_exeext conftest.$ac_ext
22445 else
22446   cat >conftest.$ac_ext <<_ACEOF
22447 /* confdefs.h.  */
22448 _ACEOF
22449 cat confdefs.h >>conftest.$ac_ext
22450 cat >>conftest.$ac_ext <<_ACEOF
22451 /* end confdefs.h.  */
22452
22453 /* pthread test headers */
22454 #include <pthread.h>
22455 #if HAVE_PTHREADS < 7
22456 #include <errno.h>
22457 #endif
22458 #ifndef NULL
22459 #define NULL (void*)0
22460 #endif
22461
22462 static void *task(p)
22463         void *p;
22464 {
22465         return (void *) (p == NULL);
22466 }
22467
22468
22469 int main(argc, argv)
22470         int argc;
22471         char **argv;
22472 {
22473
22474         /* pthread test function */
22475 #ifndef PTHREAD_CREATE_DETACHED
22476 #define PTHREAD_CREATE_DETACHED 1
22477 #endif
22478         pthread_t t;
22479         int status;
22480         int detach = PTHREAD_CREATE_DETACHED;
22481
22482 #if HAVE_PTHREADS > 4
22483         /* Final pthreads */
22484         pthread_attr_t attr;
22485
22486         status = pthread_attr_init(&attr);
22487         if( status ) return status;
22488
22489 #if HAVE_PTHREADS < 7
22490         status = pthread_attr_setdetachstate(&attr, &detach);
22491         if( status < 0 ) status = errno;
22492 #else
22493         status = pthread_attr_setdetachstate(&attr, detach);
22494 #endif
22495         if( status ) return status;
22496         status = pthread_create( &t, &attr, task, NULL );
22497 #if HAVE_PTHREADS < 7
22498         if( status < 0 ) status = errno;
22499 #endif
22500         if( status ) return status;
22501 #else
22502         /* Draft 4 pthreads */
22503         status = pthread_create( &t, pthread_attr_default, task, NULL );
22504         if( status ) return errno;
22505
22506         /* give thread a chance to complete */
22507         /* it should remain joinable and hence detachable */
22508         sleep( 1 );
22509
22510         status = pthread_detach( &t );
22511         if( status ) return errno;
22512 #endif
22513
22514 #ifdef HAVE_LINUX_THREADS
22515         pthread_kill_other_threads_np();
22516 #endif
22517
22518         return 0;
22519
22520 }
22521
22522 _ACEOF
22523 rm -f conftest$ac_exeext
22524 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22525   (eval $ac_link) 2>&5
22526   ac_status=$?
22527   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22528   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22529   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22530   (eval $ac_try) 2>&5
22531   ac_status=$?
22532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22533   (exit $ac_status); }; }; then
22534   ol_cv_pthread_threads=yes
22535 else
22536   echo "$as_me: program exited with status $ac_status" >&5
22537 echo "$as_me: failed program was:" >&5
22538 sed 's/^/| /' conftest.$ac_ext >&5
22539
22540 ( exit $ac_status )
22541 ol_cv_pthread_threads=no
22542 fi
22543 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22544 fi
22545
22546                 # restore the LIBS
22547                 LIBS="$ol_LIBS"
22548
22549 fi
22550 echo "$as_me:$LINENO: result: $ol_cv_pthread_threads" >&5
22551 echo "${ECHO_T}$ol_cv_pthread_threads" >&6
22552
22553         if test $ol_cv_pthread_threads = yes ; then
22554                 ol_link_pthreads="-threads"
22555                 ol_link_threads=posix
22556         fi
22557 fi
22558
22559
22560                 # Pthread try link: -lpthreads -lmach -lexc -lc_r (ol_cv_pthread_lpthreads_lmach_lexc_lc_r)
22561 if test "$ol_link_threads" = no ; then
22562         # try -lpthreads -lmach -lexc -lc_r
22563         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lmach -lexc -lc_r" >&5
22564 echo $ECHO_N "checking for pthread link with -lpthreads -lmach -lexc -lc_r... $ECHO_C" >&6
22565 if test "${ol_cv_pthread_lpthreads_lmach_lexc_lc_r+set}" = set; then
22566   echo $ECHO_N "(cached) $ECHO_C" >&6
22567 else
22568
22569                 # save the flags
22570                 ol_LIBS="$LIBS"
22571                 LIBS="-lpthreads -lmach -lexc -lc_r $LIBS"
22572
22573                 if test "$cross_compiling" = yes; then
22574   cat >conftest.$ac_ext <<_ACEOF
22575 /* confdefs.h.  */
22576 _ACEOF
22577 cat confdefs.h >>conftest.$ac_ext
22578 cat >>conftest.$ac_ext <<_ACEOF
22579 /* end confdefs.h.  */
22580
22581 /* pthread test headers */
22582 #include <pthread.h>
22583 #if HAVE_PTHREADS < 7
22584 #include <errno.h>
22585 #endif
22586 #ifndef NULL
22587 #define NULL (void*)0
22588 #endif
22589
22590 static void *task(p)
22591         void *p;
22592 {
22593         return (void *) (p == NULL);
22594 }
22595
22596 int
22597 main ()
22598 {
22599
22600         /* pthread test function */
22601 #ifndef PTHREAD_CREATE_DETACHED
22602 #define PTHREAD_CREATE_DETACHED 1
22603 #endif
22604         pthread_t t;
22605         int status;
22606         int detach = PTHREAD_CREATE_DETACHED;
22607
22608 #if HAVE_PTHREADS > 4
22609         /* Final pthreads */
22610         pthread_attr_t attr;
22611
22612         status = pthread_attr_init(&attr);
22613         if( status ) return status;
22614
22615 #if HAVE_PTHREADS < 7
22616         status = pthread_attr_setdetachstate(&attr, &detach);
22617         if( status < 0 ) status = errno;
22618 #else
22619         status = pthread_attr_setdetachstate(&attr, detach);
22620 #endif
22621         if( status ) return status;
22622         status = pthread_create( &t, &attr, task, NULL );
22623 #if HAVE_PTHREADS < 7
22624         if( status < 0 ) status = errno;
22625 #endif
22626         if( status ) return status;
22627 #else
22628         /* Draft 4 pthreads */
22629         status = pthread_create( &t, pthread_attr_default, task, NULL );
22630         if( status ) return errno;
22631
22632         /* give thread a chance to complete */
22633         /* it should remain joinable and hence detachable */
22634         sleep( 1 );
22635
22636         status = pthread_detach( &t );
22637         if( status ) return errno;
22638 #endif
22639
22640 #ifdef HAVE_LINUX_THREADS
22641         pthread_kill_other_threads_np();
22642 #endif
22643
22644         return 0;
22645
22646   ;
22647   return 0;
22648 }
22649 _ACEOF
22650 rm -f conftest.$ac_objext conftest$ac_exeext
22651 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22652   (eval $ac_link) 2>conftest.er1
22653   ac_status=$?
22654   grep -v '^ *+' conftest.er1 >conftest.err
22655   rm -f conftest.er1
22656   cat conftest.err >&5
22657   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22658   (exit $ac_status); } &&
22659          { ac_try='test -z "$ac_c_werror_flag"
22660                          || test ! -s conftest.err'
22661   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22662   (eval $ac_try) 2>&5
22663   ac_status=$?
22664   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22665   (exit $ac_status); }; } &&
22666          { ac_try='test -s conftest$ac_exeext'
22667   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22668   (eval $ac_try) 2>&5
22669   ac_status=$?
22670   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22671   (exit $ac_status); }; }; then
22672   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
22673 else
22674   echo "$as_me: failed program was:" >&5
22675 sed 's/^/| /' conftest.$ac_ext >&5
22676
22677 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
22678 fi
22679 rm -f conftest.err conftest.$ac_objext \
22680       conftest$ac_exeext conftest.$ac_ext
22681 else
22682   cat >conftest.$ac_ext <<_ACEOF
22683 /* confdefs.h.  */
22684 _ACEOF
22685 cat confdefs.h >>conftest.$ac_ext
22686 cat >>conftest.$ac_ext <<_ACEOF
22687 /* end confdefs.h.  */
22688
22689 /* pthread test headers */
22690 #include <pthread.h>
22691 #if HAVE_PTHREADS < 7
22692 #include <errno.h>
22693 #endif
22694 #ifndef NULL
22695 #define NULL (void*)0
22696 #endif
22697
22698 static void *task(p)
22699         void *p;
22700 {
22701         return (void *) (p == NULL);
22702 }
22703
22704
22705 int main(argc, argv)
22706         int argc;
22707         char **argv;
22708 {
22709
22710         /* pthread test function */
22711 #ifndef PTHREAD_CREATE_DETACHED
22712 #define PTHREAD_CREATE_DETACHED 1
22713 #endif
22714         pthread_t t;
22715         int status;
22716         int detach = PTHREAD_CREATE_DETACHED;
22717
22718 #if HAVE_PTHREADS > 4
22719         /* Final pthreads */
22720         pthread_attr_t attr;
22721
22722         status = pthread_attr_init(&attr);
22723         if( status ) return status;
22724
22725 #if HAVE_PTHREADS < 7
22726         status = pthread_attr_setdetachstate(&attr, &detach);
22727         if( status < 0 ) status = errno;
22728 #else
22729         status = pthread_attr_setdetachstate(&attr, detach);
22730 #endif
22731         if( status ) return status;
22732         status = pthread_create( &t, &attr, task, NULL );
22733 #if HAVE_PTHREADS < 7
22734         if( status < 0 ) status = errno;
22735 #endif
22736         if( status ) return status;
22737 #else
22738         /* Draft 4 pthreads */
22739         status = pthread_create( &t, pthread_attr_default, task, NULL );
22740         if( status ) return errno;
22741
22742         /* give thread a chance to complete */
22743         /* it should remain joinable and hence detachable */
22744         sleep( 1 );
22745
22746         status = pthread_detach( &t );
22747         if( status ) return errno;
22748 #endif
22749
22750 #ifdef HAVE_LINUX_THREADS
22751         pthread_kill_other_threads_np();
22752 #endif
22753
22754         return 0;
22755
22756 }
22757
22758 _ACEOF
22759 rm -f conftest$ac_exeext
22760 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22761   (eval $ac_link) 2>&5
22762   ac_status=$?
22763   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22764   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22765   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22766   (eval $ac_try) 2>&5
22767   ac_status=$?
22768   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22769   (exit $ac_status); }; }; then
22770   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
22771 else
22772   echo "$as_me: program exited with status $ac_status" >&5
22773 echo "$as_me: failed program was:" >&5
22774 sed 's/^/| /' conftest.$ac_ext >&5
22775
22776 ( exit $ac_status )
22777 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
22778 fi
22779 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22780 fi
22781
22782                 # restore the LIBS
22783                 LIBS="$ol_LIBS"
22784
22785 fi
22786 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&5
22787 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&6
22788
22789         if test $ol_cv_pthread_lpthreads_lmach_lexc_lc_r = yes ; then
22790                 ol_link_pthreads="-lpthreads -lmach -lexc -lc_r"
22791                 ol_link_threads=posix
22792         fi
22793 fi
22794
22795                 # Pthread try link: -lpthreads -lmach -lexc (ol_cv_pthread_lpthreads_lmach_lexc)
22796 if test "$ol_link_threads" = no ; then
22797         # try -lpthreads -lmach -lexc
22798         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lmach -lexc" >&5
22799 echo $ECHO_N "checking for pthread link with -lpthreads -lmach -lexc... $ECHO_C" >&6
22800 if test "${ol_cv_pthread_lpthreads_lmach_lexc+set}" = set; then
22801   echo $ECHO_N "(cached) $ECHO_C" >&6
22802 else
22803
22804                 # save the flags
22805                 ol_LIBS="$LIBS"
22806                 LIBS="-lpthreads -lmach -lexc $LIBS"
22807
22808                 if test "$cross_compiling" = yes; then
22809   cat >conftest.$ac_ext <<_ACEOF
22810 /* confdefs.h.  */
22811 _ACEOF
22812 cat confdefs.h >>conftest.$ac_ext
22813 cat >>conftest.$ac_ext <<_ACEOF
22814 /* end confdefs.h.  */
22815
22816 /* pthread test headers */
22817 #include <pthread.h>
22818 #if HAVE_PTHREADS < 7
22819 #include <errno.h>
22820 #endif
22821 #ifndef NULL
22822 #define NULL (void*)0
22823 #endif
22824
22825 static void *task(p)
22826         void *p;
22827 {
22828         return (void *) (p == NULL);
22829 }
22830
22831 int
22832 main ()
22833 {
22834
22835         /* pthread test function */
22836 #ifndef PTHREAD_CREATE_DETACHED
22837 #define PTHREAD_CREATE_DETACHED 1
22838 #endif
22839         pthread_t t;
22840         int status;
22841         int detach = PTHREAD_CREATE_DETACHED;
22842
22843 #if HAVE_PTHREADS > 4
22844         /* Final pthreads */
22845         pthread_attr_t attr;
22846
22847         status = pthread_attr_init(&attr);
22848         if( status ) return status;
22849
22850 #if HAVE_PTHREADS < 7
22851         status = pthread_attr_setdetachstate(&attr, &detach);
22852         if( status < 0 ) status = errno;
22853 #else
22854         status = pthread_attr_setdetachstate(&attr, detach);
22855 #endif
22856         if( status ) return status;
22857         status = pthread_create( &t, &attr, task, NULL );
22858 #if HAVE_PTHREADS < 7
22859         if( status < 0 ) status = errno;
22860 #endif
22861         if( status ) return status;
22862 #else
22863         /* Draft 4 pthreads */
22864         status = pthread_create( &t, pthread_attr_default, task, NULL );
22865         if( status ) return errno;
22866
22867         /* give thread a chance to complete */
22868         /* it should remain joinable and hence detachable */
22869         sleep( 1 );
22870
22871         status = pthread_detach( &t );
22872         if( status ) return errno;
22873 #endif
22874
22875 #ifdef HAVE_LINUX_THREADS
22876         pthread_kill_other_threads_np();
22877 #endif
22878
22879         return 0;
22880
22881   ;
22882   return 0;
22883 }
22884 _ACEOF
22885 rm -f conftest.$ac_objext conftest$ac_exeext
22886 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22887   (eval $ac_link) 2>conftest.er1
22888   ac_status=$?
22889   grep -v '^ *+' conftest.er1 >conftest.err
22890   rm -f conftest.er1
22891   cat conftest.err >&5
22892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22893   (exit $ac_status); } &&
22894          { ac_try='test -z "$ac_c_werror_flag"
22895                          || test ! -s conftest.err'
22896   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22897   (eval $ac_try) 2>&5
22898   ac_status=$?
22899   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22900   (exit $ac_status); }; } &&
22901          { ac_try='test -s conftest$ac_exeext'
22902   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22903   (eval $ac_try) 2>&5
22904   ac_status=$?
22905   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22906   (exit $ac_status); }; }; then
22907   ol_cv_pthread_lpthreads_lmach_lexc=yes
22908 else
22909   echo "$as_me: failed program was:" >&5
22910 sed 's/^/| /' conftest.$ac_ext >&5
22911
22912 ol_cv_pthread_lpthreads_lmach_lexc=no
22913 fi
22914 rm -f conftest.err conftest.$ac_objext \
22915       conftest$ac_exeext conftest.$ac_ext
22916 else
22917   cat >conftest.$ac_ext <<_ACEOF
22918 /* confdefs.h.  */
22919 _ACEOF
22920 cat confdefs.h >>conftest.$ac_ext
22921 cat >>conftest.$ac_ext <<_ACEOF
22922 /* end confdefs.h.  */
22923
22924 /* pthread test headers */
22925 #include <pthread.h>
22926 #if HAVE_PTHREADS < 7
22927 #include <errno.h>
22928 #endif
22929 #ifndef NULL
22930 #define NULL (void*)0
22931 #endif
22932
22933 static void *task(p)
22934         void *p;
22935 {
22936         return (void *) (p == NULL);
22937 }
22938
22939
22940 int main(argc, argv)
22941         int argc;
22942         char **argv;
22943 {
22944
22945         /* pthread test function */
22946 #ifndef PTHREAD_CREATE_DETACHED
22947 #define PTHREAD_CREATE_DETACHED 1
22948 #endif
22949         pthread_t t;
22950         int status;
22951         int detach = PTHREAD_CREATE_DETACHED;
22952
22953 #if HAVE_PTHREADS > 4
22954         /* Final pthreads */
22955         pthread_attr_t attr;
22956
22957         status = pthread_attr_init(&attr);
22958         if( status ) return status;
22959
22960 #if HAVE_PTHREADS < 7
22961         status = pthread_attr_setdetachstate(&attr, &detach);
22962         if( status < 0 ) status = errno;
22963 #else
22964         status = pthread_attr_setdetachstate(&attr, detach);
22965 #endif
22966         if( status ) return status;
22967         status = pthread_create( &t, &attr, task, NULL );
22968 #if HAVE_PTHREADS < 7
22969         if( status < 0 ) status = errno;
22970 #endif
22971         if( status ) return status;
22972 #else
22973         /* Draft 4 pthreads */
22974         status = pthread_create( &t, pthread_attr_default, task, NULL );
22975         if( status ) return errno;
22976
22977         /* give thread a chance to complete */
22978         /* it should remain joinable and hence detachable */
22979         sleep( 1 );
22980
22981         status = pthread_detach( &t );
22982         if( status ) return errno;
22983 #endif
22984
22985 #ifdef HAVE_LINUX_THREADS
22986         pthread_kill_other_threads_np();
22987 #endif
22988
22989         return 0;
22990
22991 }
22992
22993 _ACEOF
22994 rm -f conftest$ac_exeext
22995 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22996   (eval $ac_link) 2>&5
22997   ac_status=$?
22998   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22999   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23000   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23001   (eval $ac_try) 2>&5
23002   ac_status=$?
23003   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23004   (exit $ac_status); }; }; then
23005   ol_cv_pthread_lpthreads_lmach_lexc=yes
23006 else
23007   echo "$as_me: program exited with status $ac_status" >&5
23008 echo "$as_me: failed program was:" >&5
23009 sed 's/^/| /' conftest.$ac_ext >&5
23010
23011 ( exit $ac_status )
23012 ol_cv_pthread_lpthreads_lmach_lexc=no
23013 fi
23014 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23015 fi
23016
23017                 # restore the LIBS
23018                 LIBS="$ol_LIBS"
23019
23020 fi
23021 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lmach_lexc" >&5
23022 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lmach_lexc" >&6
23023
23024         if test $ol_cv_pthread_lpthreads_lmach_lexc = yes ; then
23025                 ol_link_pthreads="-lpthreads -lmach -lexc"
23026                 ol_link_threads=posix
23027         fi
23028 fi
23029
23030                 # Pthread try link: -lpthreads -lexc (ol_cv_pthread_lpthreads_lexc)
23031 if test "$ol_link_threads" = no ; then
23032         # try -lpthreads -lexc
23033         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lexc" >&5
23034 echo $ECHO_N "checking for pthread link with -lpthreads -lexc... $ECHO_C" >&6
23035 if test "${ol_cv_pthread_lpthreads_lexc+set}" = set; then
23036   echo $ECHO_N "(cached) $ECHO_C" >&6
23037 else
23038
23039                 # save the flags
23040                 ol_LIBS="$LIBS"
23041                 LIBS="-lpthreads -lexc $LIBS"
23042
23043                 if test "$cross_compiling" = yes; then
23044   cat >conftest.$ac_ext <<_ACEOF
23045 /* confdefs.h.  */
23046 _ACEOF
23047 cat confdefs.h >>conftest.$ac_ext
23048 cat >>conftest.$ac_ext <<_ACEOF
23049 /* end confdefs.h.  */
23050
23051 /* pthread test headers */
23052 #include <pthread.h>
23053 #if HAVE_PTHREADS < 7
23054 #include <errno.h>
23055 #endif
23056 #ifndef NULL
23057 #define NULL (void*)0
23058 #endif
23059
23060 static void *task(p)
23061         void *p;
23062 {
23063         return (void *) (p == NULL);
23064 }
23065
23066 int
23067 main ()
23068 {
23069
23070         /* pthread test function */
23071 #ifndef PTHREAD_CREATE_DETACHED
23072 #define PTHREAD_CREATE_DETACHED 1
23073 #endif
23074         pthread_t t;
23075         int status;
23076         int detach = PTHREAD_CREATE_DETACHED;
23077
23078 #if HAVE_PTHREADS > 4
23079         /* Final pthreads */
23080         pthread_attr_t attr;
23081
23082         status = pthread_attr_init(&attr);
23083         if( status ) return status;
23084
23085 #if HAVE_PTHREADS < 7
23086         status = pthread_attr_setdetachstate(&attr, &detach);
23087         if( status < 0 ) status = errno;
23088 #else
23089         status = pthread_attr_setdetachstate(&attr, detach);
23090 #endif
23091         if( status ) return status;
23092         status = pthread_create( &t, &attr, task, NULL );
23093 #if HAVE_PTHREADS < 7
23094         if( status < 0 ) status = errno;
23095 #endif
23096         if( status ) return status;
23097 #else
23098         /* Draft 4 pthreads */
23099         status = pthread_create( &t, pthread_attr_default, task, NULL );
23100         if( status ) return errno;
23101
23102         /* give thread a chance to complete */
23103         /* it should remain joinable and hence detachable */
23104         sleep( 1 );
23105
23106         status = pthread_detach( &t );
23107         if( status ) return errno;
23108 #endif
23109
23110 #ifdef HAVE_LINUX_THREADS
23111         pthread_kill_other_threads_np();
23112 #endif
23113
23114         return 0;
23115
23116   ;
23117   return 0;
23118 }
23119 _ACEOF
23120 rm -f conftest.$ac_objext conftest$ac_exeext
23121 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23122   (eval $ac_link) 2>conftest.er1
23123   ac_status=$?
23124   grep -v '^ *+' conftest.er1 >conftest.err
23125   rm -f conftest.er1
23126   cat conftest.err >&5
23127   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23128   (exit $ac_status); } &&
23129          { ac_try='test -z "$ac_c_werror_flag"
23130                          || test ! -s conftest.err'
23131   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23132   (eval $ac_try) 2>&5
23133   ac_status=$?
23134   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23135   (exit $ac_status); }; } &&
23136          { ac_try='test -s conftest$ac_exeext'
23137   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23138   (eval $ac_try) 2>&5
23139   ac_status=$?
23140   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23141   (exit $ac_status); }; }; then
23142   ol_cv_pthread_lpthreads_lexc=yes
23143 else
23144   echo "$as_me: failed program was:" >&5
23145 sed 's/^/| /' conftest.$ac_ext >&5
23146
23147 ol_cv_pthread_lpthreads_lexc=no
23148 fi
23149 rm -f conftest.err conftest.$ac_objext \
23150       conftest$ac_exeext conftest.$ac_ext
23151 else
23152   cat >conftest.$ac_ext <<_ACEOF
23153 /* confdefs.h.  */
23154 _ACEOF
23155 cat confdefs.h >>conftest.$ac_ext
23156 cat >>conftest.$ac_ext <<_ACEOF
23157 /* end confdefs.h.  */
23158
23159 /* pthread test headers */
23160 #include <pthread.h>
23161 #if HAVE_PTHREADS < 7
23162 #include <errno.h>
23163 #endif
23164 #ifndef NULL
23165 #define NULL (void*)0
23166 #endif
23167
23168 static void *task(p)
23169         void *p;
23170 {
23171         return (void *) (p == NULL);
23172 }
23173
23174
23175 int main(argc, argv)
23176         int argc;
23177         char **argv;
23178 {
23179
23180         /* pthread test function */
23181 #ifndef PTHREAD_CREATE_DETACHED
23182 #define PTHREAD_CREATE_DETACHED 1
23183 #endif
23184         pthread_t t;
23185         int status;
23186         int detach = PTHREAD_CREATE_DETACHED;
23187
23188 #if HAVE_PTHREADS > 4
23189         /* Final pthreads */
23190         pthread_attr_t attr;
23191
23192         status = pthread_attr_init(&attr);
23193         if( status ) return status;
23194
23195 #if HAVE_PTHREADS < 7
23196         status = pthread_attr_setdetachstate(&attr, &detach);
23197         if( status < 0 ) status = errno;
23198 #else
23199         status = pthread_attr_setdetachstate(&attr, detach);
23200 #endif
23201         if( status ) return status;
23202         status = pthread_create( &t, &attr, task, NULL );
23203 #if HAVE_PTHREADS < 7
23204         if( status < 0 ) status = errno;
23205 #endif
23206         if( status ) return status;
23207 #else
23208         /* Draft 4 pthreads */
23209         status = pthread_create( &t, pthread_attr_default, task, NULL );
23210         if( status ) return errno;
23211
23212         /* give thread a chance to complete */
23213         /* it should remain joinable and hence detachable */
23214         sleep( 1 );
23215
23216         status = pthread_detach( &t );
23217         if( status ) return errno;
23218 #endif
23219
23220 #ifdef HAVE_LINUX_THREADS
23221         pthread_kill_other_threads_np();
23222 #endif
23223
23224         return 0;
23225
23226 }
23227
23228 _ACEOF
23229 rm -f conftest$ac_exeext
23230 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23231   (eval $ac_link) 2>&5
23232   ac_status=$?
23233   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23234   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23235   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23236   (eval $ac_try) 2>&5
23237   ac_status=$?
23238   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23239   (exit $ac_status); }; }; then
23240   ol_cv_pthread_lpthreads_lexc=yes
23241 else
23242   echo "$as_me: program exited with status $ac_status" >&5
23243 echo "$as_me: failed program was:" >&5
23244 sed 's/^/| /' conftest.$ac_ext >&5
23245
23246 ( exit $ac_status )
23247 ol_cv_pthread_lpthreads_lexc=no
23248 fi
23249 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23250 fi
23251
23252                 # restore the LIBS
23253                 LIBS="$ol_LIBS"
23254
23255 fi
23256 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lexc" >&5
23257 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lexc" >&6
23258
23259         if test $ol_cv_pthread_lpthreads_lexc = yes ; then
23260                 ol_link_pthreads="-lpthreads -lexc"
23261                 ol_link_threads=posix
23262         fi
23263 fi
23264
23265
23266                 # Pthread try link: -lpthreads (ol_cv_pthread_lib_lpthreads)
23267 if test "$ol_link_threads" = no ; then
23268         # try -lpthreads
23269         echo "$as_me:$LINENO: checking for pthread link with -lpthreads" >&5
23270 echo $ECHO_N "checking for pthread link with -lpthreads... $ECHO_C" >&6
23271 if test "${ol_cv_pthread_lib_lpthreads+set}" = set; then
23272   echo $ECHO_N "(cached) $ECHO_C" >&6
23273 else
23274
23275                 # save the flags
23276                 ol_LIBS="$LIBS"
23277                 LIBS="-lpthreads $LIBS"
23278
23279                 if test "$cross_compiling" = yes; then
23280   cat >conftest.$ac_ext <<_ACEOF
23281 /* confdefs.h.  */
23282 _ACEOF
23283 cat confdefs.h >>conftest.$ac_ext
23284 cat >>conftest.$ac_ext <<_ACEOF
23285 /* end confdefs.h.  */
23286
23287 /* pthread test headers */
23288 #include <pthread.h>
23289 #if HAVE_PTHREADS < 7
23290 #include <errno.h>
23291 #endif
23292 #ifndef NULL
23293 #define NULL (void*)0
23294 #endif
23295
23296 static void *task(p)
23297         void *p;
23298 {
23299         return (void *) (p == NULL);
23300 }
23301
23302 int
23303 main ()
23304 {
23305
23306         /* pthread test function */
23307 #ifndef PTHREAD_CREATE_DETACHED
23308 #define PTHREAD_CREATE_DETACHED 1
23309 #endif
23310         pthread_t t;
23311         int status;
23312         int detach = PTHREAD_CREATE_DETACHED;
23313
23314 #if HAVE_PTHREADS > 4
23315         /* Final pthreads */
23316         pthread_attr_t attr;
23317
23318         status = pthread_attr_init(&attr);
23319         if( status ) return status;
23320
23321 #if HAVE_PTHREADS < 7
23322         status = pthread_attr_setdetachstate(&attr, &detach);
23323         if( status < 0 ) status = errno;
23324 #else
23325         status = pthread_attr_setdetachstate(&attr, detach);
23326 #endif
23327         if( status ) return status;
23328         status = pthread_create( &t, &attr, task, NULL );
23329 #if HAVE_PTHREADS < 7
23330         if( status < 0 ) status = errno;
23331 #endif
23332         if( status ) return status;
23333 #else
23334         /* Draft 4 pthreads */
23335         status = pthread_create( &t, pthread_attr_default, task, NULL );
23336         if( status ) return errno;
23337
23338         /* give thread a chance to complete */
23339         /* it should remain joinable and hence detachable */
23340         sleep( 1 );
23341
23342         status = pthread_detach( &t );
23343         if( status ) return errno;
23344 #endif
23345
23346 #ifdef HAVE_LINUX_THREADS
23347         pthread_kill_other_threads_np();
23348 #endif
23349
23350         return 0;
23351
23352   ;
23353   return 0;
23354 }
23355 _ACEOF
23356 rm -f conftest.$ac_objext conftest$ac_exeext
23357 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23358   (eval $ac_link) 2>conftest.er1
23359   ac_status=$?
23360   grep -v '^ *+' conftest.er1 >conftest.err
23361   rm -f conftest.er1
23362   cat conftest.err >&5
23363   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23364   (exit $ac_status); } &&
23365          { ac_try='test -z "$ac_c_werror_flag"
23366                          || test ! -s conftest.err'
23367   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23368   (eval $ac_try) 2>&5
23369   ac_status=$?
23370   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23371   (exit $ac_status); }; } &&
23372          { ac_try='test -s conftest$ac_exeext'
23373   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23374   (eval $ac_try) 2>&5
23375   ac_status=$?
23376   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23377   (exit $ac_status); }; }; then
23378   ol_cv_pthread_lib_lpthreads=yes
23379 else
23380   echo "$as_me: failed program was:" >&5
23381 sed 's/^/| /' conftest.$ac_ext >&5
23382
23383 ol_cv_pthread_lib_lpthreads=no
23384 fi
23385 rm -f conftest.err conftest.$ac_objext \
23386       conftest$ac_exeext conftest.$ac_ext
23387 else
23388   cat >conftest.$ac_ext <<_ACEOF
23389 /* confdefs.h.  */
23390 _ACEOF
23391 cat confdefs.h >>conftest.$ac_ext
23392 cat >>conftest.$ac_ext <<_ACEOF
23393 /* end confdefs.h.  */
23394
23395 /* pthread test headers */
23396 #include <pthread.h>
23397 #if HAVE_PTHREADS < 7
23398 #include <errno.h>
23399 #endif
23400 #ifndef NULL
23401 #define NULL (void*)0
23402 #endif
23403
23404 static void *task(p)
23405         void *p;
23406 {
23407         return (void *) (p == NULL);
23408 }
23409
23410
23411 int main(argc, argv)
23412         int argc;
23413         char **argv;
23414 {
23415
23416         /* pthread test function */
23417 #ifndef PTHREAD_CREATE_DETACHED
23418 #define PTHREAD_CREATE_DETACHED 1
23419 #endif
23420         pthread_t t;
23421         int status;
23422         int detach = PTHREAD_CREATE_DETACHED;
23423
23424 #if HAVE_PTHREADS > 4
23425         /* Final pthreads */
23426         pthread_attr_t attr;
23427
23428         status = pthread_attr_init(&attr);
23429         if( status ) return status;
23430
23431 #if HAVE_PTHREADS < 7
23432         status = pthread_attr_setdetachstate(&attr, &detach);
23433         if( status < 0 ) status = errno;
23434 #else
23435         status = pthread_attr_setdetachstate(&attr, detach);
23436 #endif
23437         if( status ) return status;
23438         status = pthread_create( &t, &attr, task, NULL );
23439 #if HAVE_PTHREADS < 7
23440         if( status < 0 ) status = errno;
23441 #endif
23442         if( status ) return status;
23443 #else
23444         /* Draft 4 pthreads */
23445         status = pthread_create( &t, pthread_attr_default, task, NULL );
23446         if( status ) return errno;
23447
23448         /* give thread a chance to complete */
23449         /* it should remain joinable and hence detachable */
23450         sleep( 1 );
23451
23452         status = pthread_detach( &t );
23453         if( status ) return errno;
23454 #endif
23455
23456 #ifdef HAVE_LINUX_THREADS
23457         pthread_kill_other_threads_np();
23458 #endif
23459
23460         return 0;
23461
23462 }
23463
23464 _ACEOF
23465 rm -f conftest$ac_exeext
23466 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23467   (eval $ac_link) 2>&5
23468   ac_status=$?
23469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23470   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23471   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23472   (eval $ac_try) 2>&5
23473   ac_status=$?
23474   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23475   (exit $ac_status); }; }; then
23476   ol_cv_pthread_lib_lpthreads=yes
23477 else
23478   echo "$as_me: program exited with status $ac_status" >&5
23479 echo "$as_me: failed program was:" >&5
23480 sed 's/^/| /' conftest.$ac_ext >&5
23481
23482 ( exit $ac_status )
23483 ol_cv_pthread_lib_lpthreads=no
23484 fi
23485 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23486 fi
23487
23488                 # restore the LIBS
23489                 LIBS="$ol_LIBS"
23490
23491 fi
23492 echo "$as_me:$LINENO: result: $ol_cv_pthread_lib_lpthreads" >&5
23493 echo "${ECHO_T}$ol_cv_pthread_lib_lpthreads" >&6
23494
23495         if test $ol_cv_pthread_lib_lpthreads = yes ; then
23496                 ol_link_pthreads="-lpthreads"
23497                 ol_link_threads=posix
23498         fi
23499 fi
23500
23501
23502                 if test $ol_link_threads != no ; then
23503                         LTHREAD_LIBS="$LTHREAD_LIBS $ol_link_pthreads"
23504
23505                                                 save_CPPFLAGS="$CPPFLAGS"
23506                         save_LIBS="$LIBS"
23507                         LIBS="$LTHREAD_LIBS $LIBS"
23508
23509
23510
23511
23512 for ac_func in sched_yield pthread_yield thr_yield
23513 do
23514 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
23515 echo "$as_me:$LINENO: checking for $ac_func" >&5
23516 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
23517 if eval "test \"\${$as_ac_var+set}\" = set"; then
23518   echo $ECHO_N "(cached) $ECHO_C" >&6
23519 else
23520   cat >conftest.$ac_ext <<_ACEOF
23521 /* confdefs.h.  */
23522 _ACEOF
23523 cat confdefs.h >>conftest.$ac_ext
23524 cat >>conftest.$ac_ext <<_ACEOF
23525 /* end confdefs.h.  */
23526 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23527    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23528 #define $ac_func innocuous_$ac_func
23529
23530 /* System header to define __stub macros and hopefully few prototypes,
23531     which can conflict with char $ac_func (); below.
23532     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23533     <limits.h> exists even on freestanding compilers.  */
23534
23535 #ifdef __STDC__
23536 # include <limits.h>
23537 #else
23538 # include <assert.h>
23539 #endif
23540
23541 #undef $ac_func
23542
23543 /* Override any gcc2 internal prototype to avoid an error.  */
23544 #ifdef __cplusplus
23545 extern "C"
23546 {
23547 #endif
23548 /* We use char because int might match the return type of a gcc2
23549    builtin and then its argument prototype would still apply.  */
23550 char $ac_func ();
23551 /* The GNU C library defines this for functions which it implements
23552     to always fail with ENOSYS.  Some functions are actually named
23553     something starting with __ and the normal name is an alias.  */
23554 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
23555 choke me
23556 #else
23557 char (*f) () = $ac_func;
23558 #endif
23559 #ifdef __cplusplus
23560 }
23561 #endif
23562
23563 int
23564 main ()
23565 {
23566 return f != $ac_func;
23567   ;
23568   return 0;
23569 }
23570 _ACEOF
23571 rm -f conftest.$ac_objext conftest$ac_exeext
23572 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23573   (eval $ac_link) 2>conftest.er1
23574   ac_status=$?
23575   grep -v '^ *+' conftest.er1 >conftest.err
23576   rm -f conftest.er1
23577   cat conftest.err >&5
23578   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23579   (exit $ac_status); } &&
23580          { ac_try='test -z "$ac_c_werror_flag"
23581                          || test ! -s conftest.err'
23582   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23583   (eval $ac_try) 2>&5
23584   ac_status=$?
23585   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23586   (exit $ac_status); }; } &&
23587          { ac_try='test -s conftest$ac_exeext'
23588   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23589   (eval $ac_try) 2>&5
23590   ac_status=$?
23591   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23592   (exit $ac_status); }; }; then
23593   eval "$as_ac_var=yes"
23594 else
23595   echo "$as_me: failed program was:" >&5
23596 sed 's/^/| /' conftest.$ac_ext >&5
23597
23598 eval "$as_ac_var=no"
23599 fi
23600 rm -f conftest.err conftest.$ac_objext \
23601       conftest$ac_exeext conftest.$ac_ext
23602 fi
23603 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
23604 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
23605 if test `eval echo '${'$as_ac_var'}'` = yes; then
23606   cat >>confdefs.h <<_ACEOF
23607 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
23608 _ACEOF
23609
23610 fi
23611 done
23612
23613
23614                         if test $ac_cv_func_sched_yield = no &&
23615                            test $ac_cv_func_pthread_yield = no &&
23616                            test $ac_cv_func_thr_yield = no ; then
23617                                                                 echo "$as_me:$LINENO: checking for sched_yield in -lrt" >&5
23618 echo $ECHO_N "checking for sched_yield in -lrt... $ECHO_C" >&6
23619 if test "${ac_cv_lib_rt_sched_yield+set}" = set; then
23620   echo $ECHO_N "(cached) $ECHO_C" >&6
23621 else
23622   ac_check_lib_save_LIBS=$LIBS
23623 LIBS="-lrt  $LIBS"
23624 cat >conftest.$ac_ext <<_ACEOF
23625 /* confdefs.h.  */
23626 _ACEOF
23627 cat confdefs.h >>conftest.$ac_ext
23628 cat >>conftest.$ac_ext <<_ACEOF
23629 /* end confdefs.h.  */
23630
23631 /* Override any gcc2 internal prototype to avoid an error.  */
23632 #ifdef __cplusplus
23633 extern "C"
23634 #endif
23635 /* We use char because int might match the return type of a gcc2
23636    builtin and then its argument prototype would still apply.  */
23637 char sched_yield ();
23638 int
23639 main ()
23640 {
23641 sched_yield ();
23642   ;
23643   return 0;
23644 }
23645 _ACEOF
23646 rm -f conftest.$ac_objext conftest$ac_exeext
23647 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23648   (eval $ac_link) 2>conftest.er1
23649   ac_status=$?
23650   grep -v '^ *+' conftest.er1 >conftest.err
23651   rm -f conftest.er1
23652   cat conftest.err >&5
23653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23654   (exit $ac_status); } &&
23655          { ac_try='test -z "$ac_c_werror_flag"
23656                          || test ! -s conftest.err'
23657   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23658   (eval $ac_try) 2>&5
23659   ac_status=$?
23660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23661   (exit $ac_status); }; } &&
23662          { ac_try='test -s conftest$ac_exeext'
23663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23664   (eval $ac_try) 2>&5
23665   ac_status=$?
23666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23667   (exit $ac_status); }; }; then
23668   ac_cv_lib_rt_sched_yield=yes
23669 else
23670   echo "$as_me: failed program was:" >&5
23671 sed 's/^/| /' conftest.$ac_ext >&5
23672
23673 ac_cv_lib_rt_sched_yield=no
23674 fi
23675 rm -f conftest.err conftest.$ac_objext \
23676       conftest$ac_exeext conftest.$ac_ext
23677 LIBS=$ac_check_lib_save_LIBS
23678 fi
23679 echo "$as_me:$LINENO: result: $ac_cv_lib_rt_sched_yield" >&5
23680 echo "${ECHO_T}$ac_cv_lib_rt_sched_yield" >&6
23681 if test $ac_cv_lib_rt_sched_yield = yes; then
23682   LTHREAD_LIBS="$LTHREAD_LIBS -lrt"
23683
23684 cat >>confdefs.h <<\_ACEOF
23685 #define HAVE_SCHED_YIELD 1
23686 _ACEOF
23687
23688                                         ac_cv_func_sched_yield=yes
23689 else
23690   ac_cv_func_sched_yield=no
23691 fi
23692
23693                         fi
23694                         if test $ac_cv_func_sched_yield = no &&
23695                            test $ac_cv_func_pthread_yield = no &&
23696                            test "$ac_cv_func_thr_yield" = no ; then
23697                                 { echo "$as_me:$LINENO: WARNING: could not locate sched_yield() or pthread_yield()" >&5
23698 echo "$as_me: WARNING: could not locate sched_yield() or pthread_yield()" >&2;}
23699                         fi
23700
23701
23702 for ac_func in pthread_kill
23703 do
23704 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
23705 echo "$as_me:$LINENO: checking for $ac_func" >&5
23706 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
23707 if eval "test \"\${$as_ac_var+set}\" = set"; then
23708   echo $ECHO_N "(cached) $ECHO_C" >&6
23709 else
23710   cat >conftest.$ac_ext <<_ACEOF
23711 /* confdefs.h.  */
23712 _ACEOF
23713 cat confdefs.h >>conftest.$ac_ext
23714 cat >>conftest.$ac_ext <<_ACEOF
23715 /* end confdefs.h.  */
23716 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23717    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23718 #define $ac_func innocuous_$ac_func
23719
23720 /* System header to define __stub macros and hopefully few prototypes,
23721     which can conflict with char $ac_func (); below.
23722     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23723     <limits.h> exists even on freestanding compilers.  */
23724
23725 #ifdef __STDC__
23726 # include <limits.h>
23727 #else
23728 # include <assert.h>
23729 #endif
23730
23731 #undef $ac_func
23732
23733 /* Override any gcc2 internal prototype to avoid an error.  */
23734 #ifdef __cplusplus
23735 extern "C"
23736 {
23737 #endif
23738 /* We use char because int might match the return type of a gcc2
23739    builtin and then its argument prototype would still apply.  */
23740 char $ac_func ();
23741 /* The GNU C library defines this for functions which it implements
23742     to always fail with ENOSYS.  Some functions are actually named
23743     something starting with __ and the normal name is an alias.  */
23744 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
23745 choke me
23746 #else
23747 char (*f) () = $ac_func;
23748 #endif
23749 #ifdef __cplusplus
23750 }
23751 #endif
23752
23753 int
23754 main ()
23755 {
23756 return f != $ac_func;
23757   ;
23758   return 0;
23759 }
23760 _ACEOF
23761 rm -f conftest.$ac_objext conftest$ac_exeext
23762 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23763   (eval $ac_link) 2>conftest.er1
23764   ac_status=$?
23765   grep -v '^ *+' conftest.er1 >conftest.err
23766   rm -f conftest.er1
23767   cat conftest.err >&5
23768   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23769   (exit $ac_status); } &&
23770          { ac_try='test -z "$ac_c_werror_flag"
23771                          || test ! -s conftest.err'
23772   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23773   (eval $ac_try) 2>&5
23774   ac_status=$?
23775   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23776   (exit $ac_status); }; } &&
23777          { ac_try='test -s conftest$ac_exeext'
23778   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23779   (eval $ac_try) 2>&5
23780   ac_status=$?
23781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23782   (exit $ac_status); }; }; then
23783   eval "$as_ac_var=yes"
23784 else
23785   echo "$as_me: failed program was:" >&5
23786 sed 's/^/| /' conftest.$ac_ext >&5
23787
23788 eval "$as_ac_var=no"
23789 fi
23790 rm -f conftest.err conftest.$ac_objext \
23791       conftest$ac_exeext conftest.$ac_ext
23792 fi
23793 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
23794 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
23795 if test `eval echo '${'$as_ac_var'}'` = yes; then
23796   cat >>confdefs.h <<_ACEOF
23797 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
23798 _ACEOF
23799
23800 fi
23801 done
23802
23803
23804                                                                         echo "$as_me:$LINENO: checking for pthread_rwlock_destroy with <pthread.h>" >&5
23805 echo $ECHO_N "checking for pthread_rwlock_destroy with <pthread.h>... $ECHO_C" >&6
23806 if test "${ol_cv_func_pthread_rwlock_destroy+set}" = set; then
23807   echo $ECHO_N "(cached) $ECHO_C" >&6
23808 else
23809
23810                                                                 cat >conftest.$ac_ext <<_ACEOF
23811 /* confdefs.h.  */
23812 _ACEOF
23813 cat confdefs.h >>conftest.$ac_ext
23814 cat >>conftest.$ac_ext <<_ACEOF
23815 /* end confdefs.h.  */
23816
23817 #include <pthread.h>
23818 pthread_rwlock_t rwlock;
23819
23820 int
23821 main ()
23822 {
23823 pthread_rwlock_destroy(&rwlock);
23824   ;
23825   return 0;
23826 }
23827 _ACEOF
23828 rm -f conftest.$ac_objext conftest$ac_exeext
23829 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23830   (eval $ac_link) 2>conftest.er1
23831   ac_status=$?
23832   grep -v '^ *+' conftest.er1 >conftest.err
23833   rm -f conftest.er1
23834   cat conftest.err >&5
23835   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23836   (exit $ac_status); } &&
23837          { ac_try='test -z "$ac_c_werror_flag"
23838                          || test ! -s conftest.err'
23839   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23840   (eval $ac_try) 2>&5
23841   ac_status=$?
23842   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23843   (exit $ac_status); }; } &&
23844          { ac_try='test -s conftest$ac_exeext'
23845   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23846   (eval $ac_try) 2>&5
23847   ac_status=$?
23848   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23849   (exit $ac_status); }; }; then
23850   ol_cv_func_pthread_rwlock_destroy=yes
23851 else
23852   echo "$as_me: failed program was:" >&5
23853 sed 's/^/| /' conftest.$ac_ext >&5
23854
23855 ol_cv_func_pthread_rwlock_destroy=no
23856 fi
23857 rm -f conftest.err conftest.$ac_objext \
23858       conftest$ac_exeext conftest.$ac_ext
23859
23860 fi
23861 echo "$as_me:$LINENO: result: $ol_cv_func_pthread_rwlock_destroy" >&5
23862 echo "${ECHO_T}$ol_cv_func_pthread_rwlock_destroy" >&6
23863                         if test $ol_cv_func_pthread_rwlock_destroy = yes ; then
23864
23865 cat >>confdefs.h <<\_ACEOF
23866 #define HAVE_PTHREAD_RWLOCK_DESTROY 1
23867 _ACEOF
23868
23869                         fi
23870
23871                                                                         echo "$as_me:$LINENO: checking for pthread_detach with <pthread.h>" >&5
23872 echo $ECHO_N "checking for pthread_detach with <pthread.h>... $ECHO_C" >&6
23873 if test "${ol_cv_func_pthread_detach+set}" = set; then
23874   echo $ECHO_N "(cached) $ECHO_C" >&6
23875 else
23876
23877                                                                 cat >conftest.$ac_ext <<_ACEOF
23878 /* confdefs.h.  */
23879 _ACEOF
23880 cat confdefs.h >>conftest.$ac_ext
23881 cat >>conftest.$ac_ext <<_ACEOF
23882 /* end confdefs.h.  */
23883
23884 #include <pthread.h>
23885 #ifndef NULL
23886 #define NULL (void*)0
23887 #endif
23888
23889 int
23890 main ()
23891 {
23892 pthread_detach(NULL);
23893   ;
23894   return 0;
23895 }
23896 _ACEOF
23897 rm -f conftest.$ac_objext conftest$ac_exeext
23898 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23899   (eval $ac_link) 2>conftest.er1
23900   ac_status=$?
23901   grep -v '^ *+' conftest.er1 >conftest.err
23902   rm -f conftest.er1
23903   cat conftest.err >&5
23904   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23905   (exit $ac_status); } &&
23906          { ac_try='test -z "$ac_c_werror_flag"
23907                          || test ! -s conftest.err'
23908   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23909   (eval $ac_try) 2>&5
23910   ac_status=$?
23911   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23912   (exit $ac_status); }; } &&
23913          { ac_try='test -s conftest$ac_exeext'
23914   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23915   (eval $ac_try) 2>&5
23916   ac_status=$?
23917   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23918   (exit $ac_status); }; }; then
23919   ol_cv_func_pthread_detach=yes
23920 else
23921   echo "$as_me: failed program was:" >&5
23922 sed 's/^/| /' conftest.$ac_ext >&5
23923
23924 ol_cv_func_pthread_detach=no
23925 fi
23926 rm -f conftest.err conftest.$ac_objext \
23927       conftest$ac_exeext conftest.$ac_ext
23928
23929 fi
23930 echo "$as_me:$LINENO: result: $ol_cv_func_pthread_detach" >&5
23931 echo "${ECHO_T}$ol_cv_func_pthread_detach" >&6
23932
23933                         if test $ol_cv_func_pthread_detach = no ; then
23934                                 { { echo "$as_me:$LINENO: error: could not locate pthread_detach()" >&5
23935 echo "$as_me: error: could not locate pthread_detach()" >&2;}
23936    { (exit 1); exit 1; }; }
23937                         fi
23938
23939
23940 cat >>confdefs.h <<\_ACEOF
23941 #define HAVE_PTHREAD_DETACH 1
23942 _ACEOF
23943
23944
23945
23946
23947
23948
23949 for ac_func in \
23950                                 pthread_setconcurrency \
23951                                 pthread_getconcurrency \
23952                                 thr_setconcurrency \
23953                                 thr_getconcurrency \
23954
23955 do
23956 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
23957 echo "$as_me:$LINENO: checking for $ac_func" >&5
23958 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
23959 if eval "test \"\${$as_ac_var+set}\" = set"; then
23960   echo $ECHO_N "(cached) $ECHO_C" >&6
23961 else
23962   cat >conftest.$ac_ext <<_ACEOF
23963 /* confdefs.h.  */
23964 _ACEOF
23965 cat confdefs.h >>conftest.$ac_ext
23966 cat >>conftest.$ac_ext <<_ACEOF
23967 /* end confdefs.h.  */
23968 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23969    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23970 #define $ac_func innocuous_$ac_func
23971
23972 /* System header to define __stub macros and hopefully few prototypes,
23973     which can conflict with char $ac_func (); below.
23974     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23975     <limits.h> exists even on freestanding compilers.  */
23976
23977 #ifdef __STDC__
23978 # include <limits.h>
23979 #else
23980 # include <assert.h>
23981 #endif
23982
23983 #undef $ac_func
23984
23985 /* Override any gcc2 internal prototype to avoid an error.  */
23986 #ifdef __cplusplus
23987 extern "C"
23988 {
23989 #endif
23990 /* We use char because int might match the return type of a gcc2
23991    builtin and then its argument prototype would still apply.  */
23992 char $ac_func ();
23993 /* The GNU C library defines this for functions which it implements
23994     to always fail with ENOSYS.  Some functions are actually named
23995     something starting with __ and the normal name is an alias.  */
23996 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
23997 choke me
23998 #else
23999 char (*f) () = $ac_func;
24000 #endif
24001 #ifdef __cplusplus
24002 }
24003 #endif
24004
24005 int
24006 main ()
24007 {
24008 return f != $ac_func;
24009   ;
24010   return 0;
24011 }
24012 _ACEOF
24013 rm -f conftest.$ac_objext conftest$ac_exeext
24014 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24015   (eval $ac_link) 2>conftest.er1
24016   ac_status=$?
24017   grep -v '^ *+' conftest.er1 >conftest.err
24018   rm -f conftest.er1
24019   cat conftest.err >&5
24020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24021   (exit $ac_status); } &&
24022          { ac_try='test -z "$ac_c_werror_flag"
24023                          || test ! -s conftest.err'
24024   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24025   (eval $ac_try) 2>&5
24026   ac_status=$?
24027   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24028   (exit $ac_status); }; } &&
24029          { ac_try='test -s conftest$ac_exeext'
24030   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24031   (eval $ac_try) 2>&5
24032   ac_status=$?
24033   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24034   (exit $ac_status); }; }; then
24035   eval "$as_ac_var=yes"
24036 else
24037   echo "$as_me: failed program was:" >&5
24038 sed 's/^/| /' conftest.$ac_ext >&5
24039
24040 eval "$as_ac_var=no"
24041 fi
24042 rm -f conftest.err conftest.$ac_objext \
24043       conftest$ac_exeext conftest.$ac_ext
24044 fi
24045 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
24046 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
24047 if test `eval echo '${'$as_ac_var'}'` = yes; then
24048   cat >>confdefs.h <<_ACEOF
24049 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
24050 _ACEOF
24051
24052 fi
24053 done
24054
24055
24056
24057
24058 for ac_func in pthread_kill_other_threads_np
24059 do
24060 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
24061 echo "$as_me:$LINENO: checking for $ac_func" >&5
24062 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
24063 if eval "test \"\${$as_ac_var+set}\" = set"; then
24064   echo $ECHO_N "(cached) $ECHO_C" >&6
24065 else
24066   cat >conftest.$ac_ext <<_ACEOF
24067 /* confdefs.h.  */
24068 _ACEOF
24069 cat confdefs.h >>conftest.$ac_ext
24070 cat >>conftest.$ac_ext <<_ACEOF
24071 /* end confdefs.h.  */
24072 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
24073    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24074 #define $ac_func innocuous_$ac_func
24075
24076 /* System header to define __stub macros and hopefully few prototypes,
24077     which can conflict with char $ac_func (); below.
24078     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24079     <limits.h> exists even on freestanding compilers.  */
24080
24081 #ifdef __STDC__
24082 # include <limits.h>
24083 #else
24084 # include <assert.h>
24085 #endif
24086
24087 #undef $ac_func
24088
24089 /* Override any gcc2 internal prototype to avoid an error.  */
24090 #ifdef __cplusplus
24091 extern "C"
24092 {
24093 #endif
24094 /* We use char because int might match the return type of a gcc2
24095    builtin and then its argument prototype would still apply.  */
24096 char $ac_func ();
24097 /* The GNU C library defines this for functions which it implements
24098     to always fail with ENOSYS.  Some functions are actually named
24099     something starting with __ and the normal name is an alias.  */
24100 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
24101 choke me
24102 #else
24103 char (*f) () = $ac_func;
24104 #endif
24105 #ifdef __cplusplus
24106 }
24107 #endif
24108
24109 int
24110 main ()
24111 {
24112 return f != $ac_func;
24113   ;
24114   return 0;
24115 }
24116 _ACEOF
24117 rm -f conftest.$ac_objext conftest$ac_exeext
24118 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24119   (eval $ac_link) 2>conftest.er1
24120   ac_status=$?
24121   grep -v '^ *+' conftest.er1 >conftest.err
24122   rm -f conftest.er1
24123   cat conftest.err >&5
24124   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24125   (exit $ac_status); } &&
24126          { ac_try='test -z "$ac_c_werror_flag"
24127                          || test ! -s conftest.err'
24128   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24129   (eval $ac_try) 2>&5
24130   ac_status=$?
24131   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24132   (exit $ac_status); }; } &&
24133          { ac_try='test -s conftest$ac_exeext'
24134   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24135   (eval $ac_try) 2>&5
24136   ac_status=$?
24137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24138   (exit $ac_status); }; }; then
24139   eval "$as_ac_var=yes"
24140 else
24141   echo "$as_me: failed program was:" >&5
24142 sed 's/^/| /' conftest.$ac_ext >&5
24143
24144 eval "$as_ac_var=no"
24145 fi
24146 rm -f conftest.err conftest.$ac_objext \
24147       conftest$ac_exeext conftest.$ac_ext
24148 fi
24149 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
24150 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
24151 if test `eval echo '${'$as_ac_var'}'` = yes; then
24152   cat >>confdefs.h <<_ACEOF
24153 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
24154 _ACEOF
24155
24156 fi
24157 done
24158
24159         echo "$as_me:$LINENO: checking for LinuxThreads implementation" >&5
24160 echo $ECHO_N "checking for LinuxThreads implementation... $ECHO_C" >&6
24161 if test "${ol_cv_sys_linux_threads+set}" = set; then
24162   echo $ECHO_N "(cached) $ECHO_C" >&6
24163 else
24164   ol_cv_sys_linux_threads=$ac_cv_func_pthread_kill_other_threads_np
24165 fi
24166 echo "$as_me:$LINENO: result: $ol_cv_sys_linux_threads" >&5
24167 echo "${ECHO_T}$ol_cv_sys_linux_threads" >&6
24168
24169
24170
24171
24172         echo "$as_me:$LINENO: checking for LinuxThreads consistency" >&5
24173 echo $ECHO_N "checking for LinuxThreads consistency... $ECHO_C" >&6
24174 if test "${ol_cv_linux_threads+set}" = set; then
24175   echo $ECHO_N "(cached) $ECHO_C" >&6
24176 else
24177
24178                 if test $ol_cv_header_linux_threads = yes &&
24179                    test $ol_cv_sys_linux_threads = yes; then
24180                         ol_cv_linux_threads=yes
24181                 elif test $ol_cv_header_linux_threads = no &&
24182                      test $ol_cv_sys_linux_threads = no; then
24183                         ol_cv_linux_threads=no
24184                 else
24185                         ol_cv_linux_threads=error
24186                 fi
24187
24188 fi
24189 echo "$as_me:$LINENO: result: $ol_cv_linux_threads" >&5
24190 echo "${ECHO_T}$ol_cv_linux_threads" >&6
24191
24192
24193                         if test $ol_cv_linux_threads = error; then
24194                                 { { echo "$as_me:$LINENO: error: LinuxThreads header/library mismatch" >&5
24195 echo "$as_me: error: LinuxThreads header/library mismatch" >&2;}
24196    { (exit 1); exit 1; }; };
24197                         fi
24198
24199                         echo "$as_me:$LINENO: checking if pthread_create() works" >&5
24200 echo $ECHO_N "checking if pthread_create() works... $ECHO_C" >&6
24201 if test "${ol_cv_pthread_create_works+set}" = set; then
24202   echo $ECHO_N "(cached) $ECHO_C" >&6
24203 else
24204
24205                         if test "$cross_compiling" = yes; then
24206                                 ol_cv_pthread_create_works=yes
24207 else
24208   cat >conftest.$ac_ext <<_ACEOF
24209 /* confdefs.h.  */
24210 _ACEOF
24211 cat confdefs.h >>conftest.$ac_ext
24212 cat >>conftest.$ac_ext <<_ACEOF
24213 /* end confdefs.h.  */
24214
24215 /* pthread test headers */
24216 #include <pthread.h>
24217 #if HAVE_PTHREADS < 7
24218 #include <errno.h>
24219 #endif
24220 #ifndef NULL
24221 #define NULL (void*)0
24222 #endif
24223
24224 static void *task(p)
24225         void *p;
24226 {
24227         return (void *) (p == NULL);
24228 }
24229
24230
24231 int main(argc, argv)
24232         int argc;
24233         char **argv;
24234 {
24235
24236         /* pthread test function */
24237 #ifndef PTHREAD_CREATE_DETACHED
24238 #define PTHREAD_CREATE_DETACHED 1
24239 #endif
24240         pthread_t t;
24241         int status;
24242         int detach = PTHREAD_CREATE_DETACHED;
24243
24244 #if HAVE_PTHREADS > 4
24245         /* Final pthreads */
24246         pthread_attr_t attr;
24247
24248         status = pthread_attr_init(&attr);
24249         if( status ) return status;
24250
24251 #if HAVE_PTHREADS < 7
24252         status = pthread_attr_setdetachstate(&attr, &detach);
24253         if( status < 0 ) status = errno;
24254 #else
24255         status = pthread_attr_setdetachstate(&attr, detach);
24256 #endif
24257         if( status ) return status;
24258         status = pthread_create( &t, &attr, task, NULL );
24259 #if HAVE_PTHREADS < 7
24260         if( status < 0 ) status = errno;
24261 #endif
24262         if( status ) return status;
24263 #else
24264         /* Draft 4 pthreads */
24265         status = pthread_create( &t, pthread_attr_default, task, NULL );
24266         if( status ) return errno;
24267
24268         /* give thread a chance to complete */
24269         /* it should remain joinable and hence detachable */
24270         sleep( 1 );
24271
24272         status = pthread_detach( &t );
24273         if( status ) return errno;
24274 #endif
24275
24276 #ifdef HAVE_LINUX_THREADS
24277         pthread_kill_other_threads_np();
24278 #endif
24279
24280         return 0;
24281
24282 }
24283
24284 _ACEOF
24285 rm -f conftest$ac_exeext
24286 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24287   (eval $ac_link) 2>&5
24288   ac_status=$?
24289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24290   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24291   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24292   (eval $ac_try) 2>&5
24293   ac_status=$?
24294   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24295   (exit $ac_status); }; }; then
24296   ol_cv_pthread_create_works=yes
24297 else
24298   echo "$as_me: program exited with status $ac_status" >&5
24299 echo "$as_me: failed program was:" >&5
24300 sed 's/^/| /' conftest.$ac_ext >&5
24301
24302 ( exit $ac_status )
24303 ol_cv_pthread_create_works=no
24304 fi
24305 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24306 fi
24307 fi
24308 echo "$as_me:$LINENO: result: $ol_cv_pthread_create_works" >&5
24309 echo "${ECHO_T}$ol_cv_pthread_create_works" >&6
24310
24311                         if test $ol_cv_pthread_create_works = no ; then
24312                                 { { echo "$as_me:$LINENO: error: pthread_create is not usable, check environment settings" >&5
24313 echo "$as_me: error: pthread_create is not usable, check environment settings" >&2;}
24314    { (exit 1); exit 1; }; }
24315                         fi
24316
24317                         ol_replace_broken_yield=no
24318
24319                         if test $ol_replace_broken_yield = yes ; then
24320
24321 cat >>confdefs.h <<\_ACEOF
24322 #define REPLACE_BROKEN_YIELD 1
24323 _ACEOF
24324
24325                         fi
24326
24327                                                 if test $ol_with_yielding_select = auto ; then
24328                                 echo "$as_me:$LINENO: checking if select yields when using pthreads" >&5
24329 echo $ECHO_N "checking if select yields when using pthreads... $ECHO_C" >&6
24330 if test "${ol_cv_pthread_select_yields+set}" = set; then
24331   echo $ECHO_N "(cached) $ECHO_C" >&6
24332 else
24333
24334                                 if test "$cross_compiling" = yes; then
24335   ol_cv_pthread_select_yields=cross
24336 else
24337   cat >conftest.$ac_ext <<_ACEOF
24338 /* confdefs.h.  */
24339 _ACEOF
24340 cat confdefs.h >>conftest.$ac_ext
24341 cat >>conftest.$ac_ext <<_ACEOF
24342 /* end confdefs.h.  */
24343
24344 #include <sys/types.h>
24345 #include <sys/time.h>
24346 #include <unistd.h>
24347 #include <pthread.h>
24348 #ifndef NULL
24349 #define NULL (void*) 0
24350 #endif
24351
24352 static int fildes[2];
24353
24354 static void *task(p)
24355         void *p;
24356 {
24357         int i;
24358         struct timeval tv;
24359
24360         fd_set rfds;
24361
24362         tv.tv_sec=10;
24363         tv.tv_usec=0;
24364
24365         FD_ZERO(&rfds);
24366         FD_SET(fildes[0], &rfds);
24367
24368         /* we're not interested in any fds */
24369         i = select(FD_SETSIZE, &rfds, NULL, NULL, &tv);
24370
24371         if(i < 0) {
24372                 perror("select");
24373                 exit(10);
24374         }
24375
24376         exit(0); /* if we exit here, the select blocked the whole process */
24377 }
24378
24379 int main(argc, argv)
24380         int argc;
24381         char **argv;
24382 {
24383         pthread_t t;
24384
24385         /* create a pipe to select */
24386         if(pipe(&fildes[0])) {
24387                 perror("select");
24388                 exit(1);
24389         }
24390
24391 #ifdef HAVE_PTHREAD_SETCONCURRENCY
24392         (void) pthread_setconcurrency(2);
24393 #else
24394 #ifdef HAVE_THR_SETCONCURRENCY
24395         /* Set Solaris LWP concurrency to 2 */
24396         thr_setconcurrency(2);
24397 #endif
24398 #endif
24399
24400 #if HAVE_PTHREADS < 6
24401         pthread_create(&t, pthread_attr_default, task, NULL);
24402 #else
24403         pthread_create(&t, NULL, task, NULL);
24404 #endif
24405
24406         /* make sure task runs first */
24407 #ifdef HAVE_THR_YIELD
24408         thr_yield();
24409 #elif defined( HAVE_SCHED_YIELD )
24410         sched_yield();
24411 #elif defined( HAVE_PTHREAD_YIELD )
24412         pthread_yield();
24413 #endif
24414
24415         exit(2);
24416 }
24417 _ACEOF
24418 rm -f conftest$ac_exeext
24419 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24420   (eval $ac_link) 2>&5
24421   ac_status=$?
24422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24423   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24424   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24425   (eval $ac_try) 2>&5
24426   ac_status=$?
24427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24428   (exit $ac_status); }; }; then
24429   ol_cv_pthread_select_yields=no
24430 else
24431   echo "$as_me: program exited with status $ac_status" >&5
24432 echo "$as_me: failed program was:" >&5
24433 sed 's/^/| /' conftest.$ac_ext >&5
24434
24435 ( exit $ac_status )
24436 ol_cv_pthread_select_yields=yes
24437 fi
24438 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24439 fi
24440 fi
24441 echo "$as_me:$LINENO: result: $ol_cv_pthread_select_yields" >&5
24442 echo "${ECHO_T}$ol_cv_pthread_select_yields" >&6
24443
24444                                 if test $ol_cv_pthread_select_yields = cross ; then
24445                                         { { echo "$as_me:$LINENO: error: crossing compiling: use --with-yielding_select=yes|no|manual" >&5
24446 echo "$as_me: error: crossing compiling: use --with-yielding_select=yes|no|manual" >&2;}
24447    { (exit 1); exit 1; }; }
24448                                 fi
24449
24450                                 if test $ol_cv_pthread_select_yields = yes ; then
24451                                         ol_with_yielding_select=yes
24452                                 fi
24453                         fi
24454
24455                                                 CPPFLAGS="$save_CPPFLAGS"
24456                         LIBS="$save_LIBS"
24457                 else
24458                         { { echo "$as_me:$LINENO: error: could not locate usable POSIX Threads" >&5
24459 echo "$as_me: error: could not locate usable POSIX Threads" >&2;}
24460    { (exit 1); exit 1; }; }
24461                 fi
24462         fi
24463
24464         if test $ol_with_threads = posix ; then
24465                 { { echo "$as_me:$LINENO: error: could not locate POSIX Threads" >&5
24466 echo "$as_me: error: could not locate POSIX Threads" >&2;}
24467    { (exit 1); exit 1; }; }
24468         fi
24469         ;;
24470 esac
24471
24472 case $ol_with_threads in auto | yes | mach)
24473
24474
24475
24476 for ac_header in mach/cthreads.h cthreads.h
24477 do
24478 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
24479 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24480   echo "$as_me:$LINENO: checking for $ac_header" >&5
24481 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24482 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24483   echo $ECHO_N "(cached) $ECHO_C" >&6
24484 fi
24485 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24486 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24487 else
24488   # Is the header compilable?
24489 echo "$as_me:$LINENO: checking $ac_header usability" >&5
24490 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
24491 cat >conftest.$ac_ext <<_ACEOF
24492 /* confdefs.h.  */
24493 _ACEOF
24494 cat confdefs.h >>conftest.$ac_ext
24495 cat >>conftest.$ac_ext <<_ACEOF
24496 /* end confdefs.h.  */
24497 $ac_includes_default
24498 #include <$ac_header>
24499 _ACEOF
24500 rm -f conftest.$ac_objext
24501 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
24502   (eval $ac_compile) 2>conftest.er1
24503   ac_status=$?
24504   grep -v '^ *+' conftest.er1 >conftest.err
24505   rm -f conftest.er1
24506   cat conftest.err >&5
24507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24508   (exit $ac_status); } &&
24509          { ac_try='test -z "$ac_c_werror_flag"
24510                          || test ! -s conftest.err'
24511   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24512   (eval $ac_try) 2>&5
24513   ac_status=$?
24514   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24515   (exit $ac_status); }; } &&
24516          { ac_try='test -s conftest.$ac_objext'
24517   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24518   (eval $ac_try) 2>&5
24519   ac_status=$?
24520   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24521   (exit $ac_status); }; }; then
24522   ac_header_compiler=yes
24523 else
24524   echo "$as_me: failed program was:" >&5
24525 sed 's/^/| /' conftest.$ac_ext >&5
24526
24527 ac_header_compiler=no
24528 fi
24529 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
24530 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
24531 echo "${ECHO_T}$ac_header_compiler" >&6
24532
24533 # Is the header present?
24534 echo "$as_me:$LINENO: checking $ac_header presence" >&5
24535 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
24536 cat >conftest.$ac_ext <<_ACEOF
24537 /* confdefs.h.  */
24538 _ACEOF
24539 cat confdefs.h >>conftest.$ac_ext
24540 cat >>conftest.$ac_ext <<_ACEOF
24541 /* end confdefs.h.  */
24542 #include <$ac_header>
24543 _ACEOF
24544 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
24545   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
24546   ac_status=$?
24547   grep -v '^ *+' conftest.er1 >conftest.err
24548   rm -f conftest.er1
24549   cat conftest.err >&5
24550   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24551   (exit $ac_status); } >/dev/null; then
24552   if test -s conftest.err; then
24553     ac_cpp_err=$ac_c_preproc_warn_flag
24554     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
24555   else
24556     ac_cpp_err=
24557   fi
24558 else
24559   ac_cpp_err=yes
24560 fi
24561 if test -z "$ac_cpp_err"; then
24562   ac_header_preproc=yes
24563 else
24564   echo "$as_me: failed program was:" >&5
24565 sed 's/^/| /' conftest.$ac_ext >&5
24566
24567   ac_header_preproc=no
24568 fi
24569 rm -f conftest.err conftest.$ac_ext
24570 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
24571 echo "${ECHO_T}$ac_header_preproc" >&6
24572
24573 # So?  What about this header?
24574 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
24575   yes:no: )
24576     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
24577 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
24578     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
24579 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
24580     ac_header_preproc=yes
24581     ;;
24582   no:yes:* )
24583     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
24584 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
24585     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
24586 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
24587     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
24588 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
24589     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
24590 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
24591     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
24592 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
24593     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
24594 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
24595     (
24596       cat <<\_ASBOX
24597 ## --------------------------------------------- ##
24598 ## Report this to <http://www.openldap.org/its/> ##
24599 ## --------------------------------------------- ##
24600 _ASBOX
24601     ) |
24602       sed "s/^/$as_me: WARNING:     /" >&2
24603     ;;
24604 esac
24605 echo "$as_me:$LINENO: checking for $ac_header" >&5
24606 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24607 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24608   echo $ECHO_N "(cached) $ECHO_C" >&6
24609 else
24610   eval "$as_ac_Header=\$ac_header_preproc"
24611 fi
24612 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24613 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24614
24615 fi
24616 if test `eval echo '${'$as_ac_Header'}'` = yes; then
24617   cat >>confdefs.h <<_ACEOF
24618 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
24619 _ACEOF
24620
24621 fi
24622
24623 done
24624
24625         if test $ac_cv_header_mach_cthreads_h = yes ; then
24626                 ol_with_threads=found
24627
24628                                 echo "$as_me:$LINENO: checking for cthread_fork" >&5
24629 echo $ECHO_N "checking for cthread_fork... $ECHO_C" >&6
24630 if test "${ac_cv_func_cthread_fork+set}" = set; then
24631   echo $ECHO_N "(cached) $ECHO_C" >&6
24632 else
24633   cat >conftest.$ac_ext <<_ACEOF
24634 /* confdefs.h.  */
24635 _ACEOF
24636 cat confdefs.h >>conftest.$ac_ext
24637 cat >>conftest.$ac_ext <<_ACEOF
24638 /* end confdefs.h.  */
24639 /* Define cthread_fork to an innocuous variant, in case <limits.h> declares cthread_fork.
24640    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24641 #define cthread_fork innocuous_cthread_fork
24642
24643 /* System header to define __stub macros and hopefully few prototypes,
24644     which can conflict with char cthread_fork (); below.
24645     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24646     <limits.h> exists even on freestanding compilers.  */
24647
24648 #ifdef __STDC__
24649 # include <limits.h>
24650 #else
24651 # include <assert.h>
24652 #endif
24653
24654 #undef cthread_fork
24655
24656 /* Override any gcc2 internal prototype to avoid an error.  */
24657 #ifdef __cplusplus
24658 extern "C"
24659 {
24660 #endif
24661 /* We use char because int might match the return type of a gcc2
24662    builtin and then its argument prototype would still apply.  */
24663 char cthread_fork ();
24664 /* The GNU C library defines this for functions which it implements
24665     to always fail with ENOSYS.  Some functions are actually named
24666     something starting with __ and the normal name is an alias.  */
24667 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
24668 choke me
24669 #else
24670 char (*f) () = cthread_fork;
24671 #endif
24672 #ifdef __cplusplus
24673 }
24674 #endif
24675
24676 int
24677 main ()
24678 {
24679 return f != cthread_fork;
24680   ;
24681   return 0;
24682 }
24683 _ACEOF
24684 rm -f conftest.$ac_objext conftest$ac_exeext
24685 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24686   (eval $ac_link) 2>conftest.er1
24687   ac_status=$?
24688   grep -v '^ *+' conftest.er1 >conftest.err
24689   rm -f conftest.er1
24690   cat conftest.err >&5
24691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24692   (exit $ac_status); } &&
24693          { ac_try='test -z "$ac_c_werror_flag"
24694                          || test ! -s conftest.err'
24695   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24696   (eval $ac_try) 2>&5
24697   ac_status=$?
24698   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24699   (exit $ac_status); }; } &&
24700          { ac_try='test -s conftest$ac_exeext'
24701   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24702   (eval $ac_try) 2>&5
24703   ac_status=$?
24704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24705   (exit $ac_status); }; }; then
24706   ac_cv_func_cthread_fork=yes
24707 else
24708   echo "$as_me: failed program was:" >&5
24709 sed 's/^/| /' conftest.$ac_ext >&5
24710
24711 ac_cv_func_cthread_fork=no
24712 fi
24713 rm -f conftest.err conftest.$ac_objext \
24714       conftest$ac_exeext conftest.$ac_ext
24715 fi
24716 echo "$as_me:$LINENO: result: $ac_cv_func_cthread_fork" >&5
24717 echo "${ECHO_T}$ac_cv_func_cthread_fork" >&6
24718 if test $ac_cv_func_cthread_fork = yes; then
24719   ol_link_threads=yes
24720 fi
24721
24722
24723                 if test $ol_link_threads = no ; then
24724                                                                         echo "$as_me:$LINENO: checking for cthread_fork with -all_load" >&5
24725 echo $ECHO_N "checking for cthread_fork with -all_load... $ECHO_C" >&6
24726 if test "${ol_cv_cthread_all_load+set}" = set; then
24727   echo $ECHO_N "(cached) $ECHO_C" >&6
24728 else
24729
24730                                                                 save_LIBS="$LIBS"
24731                                 LIBS="-all_load $LIBS"
24732                                 cat >conftest.$ac_ext <<_ACEOF
24733 /* confdefs.h.  */
24734 _ACEOF
24735 cat confdefs.h >>conftest.$ac_ext
24736 cat >>conftest.$ac_ext <<_ACEOF
24737 /* end confdefs.h.  */
24738 #include <mach/cthreads.h>
24739 int
24740 main ()
24741 {
24742
24743                                         cthread_fork((void *)0, (void *)0);
24744
24745   ;
24746   return 0;
24747 }
24748 _ACEOF
24749 rm -f conftest.$ac_objext conftest$ac_exeext
24750 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24751   (eval $ac_link) 2>conftest.er1
24752   ac_status=$?
24753   grep -v '^ *+' conftest.er1 >conftest.err
24754   rm -f conftest.er1
24755   cat conftest.err >&5
24756   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24757   (exit $ac_status); } &&
24758          { ac_try='test -z "$ac_c_werror_flag"
24759                          || test ! -s conftest.err'
24760   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24761   (eval $ac_try) 2>&5
24762   ac_status=$?
24763   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24764   (exit $ac_status); }; } &&
24765          { ac_try='test -s conftest$ac_exeext'
24766   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24767   (eval $ac_try) 2>&5
24768   ac_status=$?
24769   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24770   (exit $ac_status); }; }; then
24771   ol_cv_cthread_all_load=yes
24772 else
24773   echo "$as_me: failed program was:" >&5
24774 sed 's/^/| /' conftest.$ac_ext >&5
24775
24776 ol_cv_cthread_all_load=no
24777 fi
24778 rm -f conftest.err conftest.$ac_objext \
24779       conftest$ac_exeext conftest.$ac_ext
24780                                                                 LIBS="$save_LIBS"
24781
24782 fi
24783 echo "$as_me:$LINENO: result: $ol_cv_cthread_all_load" >&5
24784 echo "${ECHO_T}$ol_cv_cthread_all_load" >&6
24785
24786                         if test $ol_cv_cthread_all_load = yes ; then
24787                                 LTHREAD_LIBS="$LTHREAD_LIBS -all_load"
24788                                 ol_link_threads=mach
24789                                 ol_with_threads=found
24790                         fi
24791                 fi
24792
24793         elif test $ac_cv_header_cthreads_h = yes ; then
24794
24795                 ol_with_threads=found
24796
24797                                 save_LIBS="$LIBS"
24798                 LIBS="$LIBS -lthreads"
24799                 echo "$as_me:$LINENO: checking for cthread_fork" >&5
24800 echo $ECHO_N "checking for cthread_fork... $ECHO_C" >&6
24801 if test "${ac_cv_func_cthread_fork+set}" = set; then
24802   echo $ECHO_N "(cached) $ECHO_C" >&6
24803 else
24804   cat >conftest.$ac_ext <<_ACEOF
24805 /* confdefs.h.  */
24806 _ACEOF
24807 cat confdefs.h >>conftest.$ac_ext
24808 cat >>conftest.$ac_ext <<_ACEOF
24809 /* end confdefs.h.  */
24810 /* Define cthread_fork to an innocuous variant, in case <limits.h> declares cthread_fork.
24811    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24812 #define cthread_fork innocuous_cthread_fork
24813
24814 /* System header to define __stub macros and hopefully few prototypes,
24815     which can conflict with char cthread_fork (); below.
24816     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24817     <limits.h> exists even on freestanding compilers.  */
24818
24819 #ifdef __STDC__
24820 # include <limits.h>
24821 #else
24822 # include <assert.h>
24823 #endif
24824
24825 #undef cthread_fork
24826
24827 /* Override any gcc2 internal prototype to avoid an error.  */
24828 #ifdef __cplusplus
24829 extern "C"
24830 {
24831 #endif
24832 /* We use char because int might match the return type of a gcc2
24833    builtin and then its argument prototype would still apply.  */
24834 char cthread_fork ();
24835 /* The GNU C library defines this for functions which it implements
24836     to always fail with ENOSYS.  Some functions are actually named
24837     something starting with __ and the normal name is an alias.  */
24838 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
24839 choke me
24840 #else
24841 char (*f) () = cthread_fork;
24842 #endif
24843 #ifdef __cplusplus
24844 }
24845 #endif
24846
24847 int
24848 main ()
24849 {
24850 return f != cthread_fork;
24851   ;
24852   return 0;
24853 }
24854 _ACEOF
24855 rm -f conftest.$ac_objext conftest$ac_exeext
24856 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24857   (eval $ac_link) 2>conftest.er1
24858   ac_status=$?
24859   grep -v '^ *+' conftest.er1 >conftest.err
24860   rm -f conftest.er1
24861   cat conftest.err >&5
24862   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24863   (exit $ac_status); } &&
24864          { ac_try='test -z "$ac_c_werror_flag"
24865                          || test ! -s conftest.err'
24866   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24867   (eval $ac_try) 2>&5
24868   ac_status=$?
24869   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24870   (exit $ac_status); }; } &&
24871          { ac_try='test -s conftest$ac_exeext'
24872   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24873   (eval $ac_try) 2>&5
24874   ac_status=$?
24875   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24876   (exit $ac_status); }; }; then
24877   ac_cv_func_cthread_fork=yes
24878 else
24879   echo "$as_me: failed program was:" >&5
24880 sed 's/^/| /' conftest.$ac_ext >&5
24881
24882 ac_cv_func_cthread_fork=no
24883 fi
24884 rm -f conftest.err conftest.$ac_objext \
24885       conftest$ac_exeext conftest.$ac_ext
24886 fi
24887 echo "$as_me:$LINENO: result: $ac_cv_func_cthread_fork" >&5
24888 echo "${ECHO_T}$ac_cv_func_cthread_fork" >&6
24889 if test $ac_cv_func_cthread_fork = yes; then
24890   ol_link_threads=yes
24891 fi
24892
24893                 LIBS="$save_LIBS"
24894
24895                 if test $ol_link_threads = yes ; then
24896                         LTHREAD_LIBS="-lthreads"
24897                         ol_link_threads=mach
24898                         ol_with_threads=found
24899                 else
24900                         { { echo "$as_me:$LINENO: error: could not link with Mach CThreads" >&5
24901 echo "$as_me: error: could not link with Mach CThreads" >&2;}
24902    { (exit 1); exit 1; }; }
24903                 fi
24904
24905         elif test $ol_with_threads = mach ; then
24906                 { { echo "$as_me:$LINENO: error: could not locate Mach CThreads" >&5
24907 echo "$as_me: error: could not locate Mach CThreads" >&2;}
24908    { (exit 1); exit 1; }; }
24909         fi
24910
24911         if test $ol_link_threads = mach ; then
24912
24913 cat >>confdefs.h <<\_ACEOF
24914 #define HAVE_MACH_CTHREADS 1
24915 _ACEOF
24916
24917         elif test $ol_with_threads = found ; then
24918                 { { echo "$as_me:$LINENO: error: could not link with Mach CThreads" >&5
24919 echo "$as_me: error: could not link with Mach CThreads" >&2;}
24920    { (exit 1); exit 1; }; }
24921         fi
24922         ;;
24923 esac
24924
24925 case $ol_with_threads in auto | yes | pth)
24926
24927
24928 for ac_header in pth.h
24929 do
24930 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
24931 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24932   echo "$as_me:$LINENO: checking for $ac_header" >&5
24933 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24934 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24935   echo $ECHO_N "(cached) $ECHO_C" >&6
24936 fi
24937 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24938 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24939 else
24940   # Is the header compilable?
24941 echo "$as_me:$LINENO: checking $ac_header usability" >&5
24942 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
24943 cat >conftest.$ac_ext <<_ACEOF
24944 /* confdefs.h.  */
24945 _ACEOF
24946 cat confdefs.h >>conftest.$ac_ext
24947 cat >>conftest.$ac_ext <<_ACEOF
24948 /* end confdefs.h.  */
24949 $ac_includes_default
24950 #include <$ac_header>
24951 _ACEOF
24952 rm -f conftest.$ac_objext
24953 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
24954   (eval $ac_compile) 2>conftest.er1
24955   ac_status=$?
24956   grep -v '^ *+' conftest.er1 >conftest.err
24957   rm -f conftest.er1
24958   cat conftest.err >&5
24959   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24960   (exit $ac_status); } &&
24961          { ac_try='test -z "$ac_c_werror_flag"
24962                          || test ! -s conftest.err'
24963   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24964   (eval $ac_try) 2>&5
24965   ac_status=$?
24966   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24967   (exit $ac_status); }; } &&
24968          { ac_try='test -s conftest.$ac_objext'
24969   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24970   (eval $ac_try) 2>&5
24971   ac_status=$?
24972   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24973   (exit $ac_status); }; }; then
24974   ac_header_compiler=yes
24975 else
24976   echo "$as_me: failed program was:" >&5
24977 sed 's/^/| /' conftest.$ac_ext >&5
24978
24979 ac_header_compiler=no
24980 fi
24981 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
24982 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
24983 echo "${ECHO_T}$ac_header_compiler" >&6
24984
24985 # Is the header present?
24986 echo "$as_me:$LINENO: checking $ac_header presence" >&5
24987 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
24988 cat >conftest.$ac_ext <<_ACEOF
24989 /* confdefs.h.  */
24990 _ACEOF
24991 cat confdefs.h >>conftest.$ac_ext
24992 cat >>conftest.$ac_ext <<_ACEOF
24993 /* end confdefs.h.  */
24994 #include <$ac_header>
24995 _ACEOF
24996 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
24997   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
24998   ac_status=$?
24999   grep -v '^ *+' conftest.er1 >conftest.err
25000   rm -f conftest.er1
25001   cat conftest.err >&5
25002   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25003   (exit $ac_status); } >/dev/null; then
25004   if test -s conftest.err; then
25005     ac_cpp_err=$ac_c_preproc_warn_flag
25006     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25007   else
25008     ac_cpp_err=
25009   fi
25010 else
25011   ac_cpp_err=yes
25012 fi
25013 if test -z "$ac_cpp_err"; then
25014   ac_header_preproc=yes
25015 else
25016   echo "$as_me: failed program was:" >&5
25017 sed 's/^/| /' conftest.$ac_ext >&5
25018
25019   ac_header_preproc=no
25020 fi
25021 rm -f conftest.err conftest.$ac_ext
25022 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25023 echo "${ECHO_T}$ac_header_preproc" >&6
25024
25025 # So?  What about this header?
25026 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25027   yes:no: )
25028     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25029 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25030     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25031 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25032     ac_header_preproc=yes
25033     ;;
25034   no:yes:* )
25035     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25036 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25037     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25038 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25039     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25040 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25041     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25042 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25043     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25044 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25045     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25046 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25047     (
25048       cat <<\_ASBOX
25049 ## --------------------------------------------- ##
25050 ## Report this to <http://www.openldap.org/its/> ##
25051 ## --------------------------------------------- ##
25052 _ASBOX
25053     ) |
25054       sed "s/^/$as_me: WARNING:     /" >&2
25055     ;;
25056 esac
25057 echo "$as_me:$LINENO: checking for $ac_header" >&5
25058 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25059 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25060   echo $ECHO_N "(cached) $ECHO_C" >&6
25061 else
25062   eval "$as_ac_Header=\$ac_header_preproc"
25063 fi
25064 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25065 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25066
25067 fi
25068 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25069   cat >>confdefs.h <<_ACEOF
25070 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25071 _ACEOF
25072
25073 fi
25074
25075 done
25076
25077
25078         if test $ac_cv_header_pth_h = yes ; then
25079                 echo "$as_me:$LINENO: checking for pth_version in -lpth" >&5
25080 echo $ECHO_N "checking for pth_version in -lpth... $ECHO_C" >&6
25081 if test "${ac_cv_lib_pth_pth_version+set}" = set; then
25082   echo $ECHO_N "(cached) $ECHO_C" >&6
25083 else
25084   ac_check_lib_save_LIBS=$LIBS
25085 LIBS="-lpth  $LIBS"
25086 cat >conftest.$ac_ext <<_ACEOF
25087 /* confdefs.h.  */
25088 _ACEOF
25089 cat confdefs.h >>conftest.$ac_ext
25090 cat >>conftest.$ac_ext <<_ACEOF
25091 /* end confdefs.h.  */
25092
25093 /* Override any gcc2 internal prototype to avoid an error.  */
25094 #ifdef __cplusplus
25095 extern "C"
25096 #endif
25097 /* We use char because int might match the return type of a gcc2
25098    builtin and then its argument prototype would still apply.  */
25099 char pth_version ();
25100 int
25101 main ()
25102 {
25103 pth_version ();
25104   ;
25105   return 0;
25106 }
25107 _ACEOF
25108 rm -f conftest.$ac_objext conftest$ac_exeext
25109 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25110   (eval $ac_link) 2>conftest.er1
25111   ac_status=$?
25112   grep -v '^ *+' conftest.er1 >conftest.err
25113   rm -f conftest.er1
25114   cat conftest.err >&5
25115   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25116   (exit $ac_status); } &&
25117          { ac_try='test -z "$ac_c_werror_flag"
25118                          || test ! -s conftest.err'
25119   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25120   (eval $ac_try) 2>&5
25121   ac_status=$?
25122   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25123   (exit $ac_status); }; } &&
25124          { ac_try='test -s conftest$ac_exeext'
25125   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25126   (eval $ac_try) 2>&5
25127   ac_status=$?
25128   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25129   (exit $ac_status); }; }; then
25130   ac_cv_lib_pth_pth_version=yes
25131 else
25132   echo "$as_me: failed program was:" >&5
25133 sed 's/^/| /' conftest.$ac_ext >&5
25134
25135 ac_cv_lib_pth_pth_version=no
25136 fi
25137 rm -f conftest.err conftest.$ac_objext \
25138       conftest$ac_exeext conftest.$ac_ext
25139 LIBS=$ac_check_lib_save_LIBS
25140 fi
25141 echo "$as_me:$LINENO: result: $ac_cv_lib_pth_pth_version" >&5
25142 echo "${ECHO_T}$ac_cv_lib_pth_pth_version" >&6
25143 if test $ac_cv_lib_pth_pth_version = yes; then
25144   have_pth=yes
25145 else
25146   have_pth=no
25147 fi
25148
25149
25150                 if test $have_pth = yes ; then
25151
25152 cat >>confdefs.h <<\_ACEOF
25153 #define HAVE_GNU_PTH 1
25154 _ACEOF
25155
25156                         LTHREAD_LIBS="$LTHREAD_LIBS -lpth"
25157                         ol_link_threads=pth
25158                         ol_with_threads=found
25159
25160                         if test $ol_with_yielding_select = auto ; then
25161                                 ol_with_yielding_select=yes
25162                         fi
25163                 fi
25164         fi
25165         ;;
25166 esac
25167
25168 case $ol_with_threads in auto | yes | lwp)
25169
25170
25171
25172 for ac_header in thread.h synch.h
25173 do
25174 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25175 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25176   echo "$as_me:$LINENO: checking for $ac_header" >&5
25177 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25178 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25179   echo $ECHO_N "(cached) $ECHO_C" >&6
25180 fi
25181 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25182 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25183 else
25184   # Is the header compilable?
25185 echo "$as_me:$LINENO: checking $ac_header usability" >&5
25186 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
25187 cat >conftest.$ac_ext <<_ACEOF
25188 /* confdefs.h.  */
25189 _ACEOF
25190 cat confdefs.h >>conftest.$ac_ext
25191 cat >>conftest.$ac_ext <<_ACEOF
25192 /* end confdefs.h.  */
25193 $ac_includes_default
25194 #include <$ac_header>
25195 _ACEOF
25196 rm -f conftest.$ac_objext
25197 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
25198   (eval $ac_compile) 2>conftest.er1
25199   ac_status=$?
25200   grep -v '^ *+' conftest.er1 >conftest.err
25201   rm -f conftest.er1
25202   cat conftest.err >&5
25203   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25204   (exit $ac_status); } &&
25205          { ac_try='test -z "$ac_c_werror_flag"
25206                          || test ! -s conftest.err'
25207   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25208   (eval $ac_try) 2>&5
25209   ac_status=$?
25210   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25211   (exit $ac_status); }; } &&
25212          { ac_try='test -s conftest.$ac_objext'
25213   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25214   (eval $ac_try) 2>&5
25215   ac_status=$?
25216   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25217   (exit $ac_status); }; }; then
25218   ac_header_compiler=yes
25219 else
25220   echo "$as_me: failed program was:" >&5
25221 sed 's/^/| /' conftest.$ac_ext >&5
25222
25223 ac_header_compiler=no
25224 fi
25225 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
25226 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25227 echo "${ECHO_T}$ac_header_compiler" >&6
25228
25229 # Is the header present?
25230 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25231 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25232 cat >conftest.$ac_ext <<_ACEOF
25233 /* confdefs.h.  */
25234 _ACEOF
25235 cat confdefs.h >>conftest.$ac_ext
25236 cat >>conftest.$ac_ext <<_ACEOF
25237 /* end confdefs.h.  */
25238 #include <$ac_header>
25239 _ACEOF
25240 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25241   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25242   ac_status=$?
25243   grep -v '^ *+' conftest.er1 >conftest.err
25244   rm -f conftest.er1
25245   cat conftest.err >&5
25246   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25247   (exit $ac_status); } >/dev/null; then
25248   if test -s conftest.err; then
25249     ac_cpp_err=$ac_c_preproc_warn_flag
25250     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25251   else
25252     ac_cpp_err=
25253   fi
25254 else
25255   ac_cpp_err=yes
25256 fi
25257 if test -z "$ac_cpp_err"; then
25258   ac_header_preproc=yes
25259 else
25260   echo "$as_me: failed program was:" >&5
25261 sed 's/^/| /' conftest.$ac_ext >&5
25262
25263   ac_header_preproc=no
25264 fi
25265 rm -f conftest.err conftest.$ac_ext
25266 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25267 echo "${ECHO_T}$ac_header_preproc" >&6
25268
25269 # So?  What about this header?
25270 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25271   yes:no: )
25272     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25273 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25274     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25275 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25276     ac_header_preproc=yes
25277     ;;
25278   no:yes:* )
25279     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25280 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25281     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25282 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25283     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25284 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25285     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25286 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25287     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25288 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25289     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25290 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25291     (
25292       cat <<\_ASBOX
25293 ## --------------------------------------------- ##
25294 ## Report this to <http://www.openldap.org/its/> ##
25295 ## --------------------------------------------- ##
25296 _ASBOX
25297     ) |
25298       sed "s/^/$as_me: WARNING:     /" >&2
25299     ;;
25300 esac
25301 echo "$as_me:$LINENO: checking for $ac_header" >&5
25302 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25303 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25304   echo $ECHO_N "(cached) $ECHO_C" >&6
25305 else
25306   eval "$as_ac_Header=\$ac_header_preproc"
25307 fi
25308 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25309 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25310
25311 fi
25312 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25313   cat >>confdefs.h <<_ACEOF
25314 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25315 _ACEOF
25316
25317 fi
25318
25319 done
25320
25321         if test $ac_cv_header_thread_h = yes &&
25322            test $ac_cv_header_synch_h = yes ; then
25323                 echo "$as_me:$LINENO: checking for thr_create in -lthread" >&5
25324 echo $ECHO_N "checking for thr_create in -lthread... $ECHO_C" >&6
25325 if test "${ac_cv_lib_thread_thr_create+set}" = set; then
25326   echo $ECHO_N "(cached) $ECHO_C" >&6
25327 else
25328   ac_check_lib_save_LIBS=$LIBS
25329 LIBS="-lthread  $LIBS"
25330 cat >conftest.$ac_ext <<_ACEOF
25331 /* confdefs.h.  */
25332 _ACEOF
25333 cat confdefs.h >>conftest.$ac_ext
25334 cat >>conftest.$ac_ext <<_ACEOF
25335 /* end confdefs.h.  */
25336
25337 /* Override any gcc2 internal prototype to avoid an error.  */
25338 #ifdef __cplusplus
25339 extern "C"
25340 #endif
25341 /* We use char because int might match the return type of a gcc2
25342    builtin and then its argument prototype would still apply.  */
25343 char thr_create ();
25344 int
25345 main ()
25346 {
25347 thr_create ();
25348   ;
25349   return 0;
25350 }
25351 _ACEOF
25352 rm -f conftest.$ac_objext conftest$ac_exeext
25353 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25354   (eval $ac_link) 2>conftest.er1
25355   ac_status=$?
25356   grep -v '^ *+' conftest.er1 >conftest.err
25357   rm -f conftest.er1
25358   cat conftest.err >&5
25359   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25360   (exit $ac_status); } &&
25361          { ac_try='test -z "$ac_c_werror_flag"
25362                          || test ! -s conftest.err'
25363   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25364   (eval $ac_try) 2>&5
25365   ac_status=$?
25366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25367   (exit $ac_status); }; } &&
25368          { ac_try='test -s conftest$ac_exeext'
25369   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25370   (eval $ac_try) 2>&5
25371   ac_status=$?
25372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25373   (exit $ac_status); }; }; then
25374   ac_cv_lib_thread_thr_create=yes
25375 else
25376   echo "$as_me: failed program was:" >&5
25377 sed 's/^/| /' conftest.$ac_ext >&5
25378
25379 ac_cv_lib_thread_thr_create=no
25380 fi
25381 rm -f conftest.err conftest.$ac_objext \
25382       conftest$ac_exeext conftest.$ac_ext
25383 LIBS=$ac_check_lib_save_LIBS
25384 fi
25385 echo "$as_me:$LINENO: result: $ac_cv_lib_thread_thr_create" >&5
25386 echo "${ECHO_T}$ac_cv_lib_thread_thr_create" >&6
25387 if test $ac_cv_lib_thread_thr_create = yes; then
25388   have_thr=yes
25389 else
25390   have_thr=no
25391 fi
25392
25393
25394                 if test $have_thr = yes ; then
25395
25396 cat >>confdefs.h <<\_ACEOF
25397 #define HAVE_THR 1
25398 _ACEOF
25399
25400                         LTHREAD_LIBS="$LTHREAD_LIBS -lthread"
25401                         ol_link_threads=thr
25402
25403                         if test $ol_with_yielding_select = auto ; then
25404                                 ol_with_yielding_select=yes
25405                         fi
25406
25407
25408
25409 for ac_func in \
25410                                 thr_setconcurrency \
25411                                 thr_getconcurrency \
25412
25413 do
25414 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
25415 echo "$as_me:$LINENO: checking for $ac_func" >&5
25416 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
25417 if eval "test \"\${$as_ac_var+set}\" = set"; then
25418   echo $ECHO_N "(cached) $ECHO_C" >&6
25419 else
25420   cat >conftest.$ac_ext <<_ACEOF
25421 /* confdefs.h.  */
25422 _ACEOF
25423 cat confdefs.h >>conftest.$ac_ext
25424 cat >>conftest.$ac_ext <<_ACEOF
25425 /* end confdefs.h.  */
25426 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
25427    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
25428 #define $ac_func innocuous_$ac_func
25429
25430 /* System header to define __stub macros and hopefully few prototypes,
25431     which can conflict with char $ac_func (); below.
25432     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
25433     <limits.h> exists even on freestanding compilers.  */
25434
25435 #ifdef __STDC__
25436 # include <limits.h>
25437 #else
25438 # include <assert.h>
25439 #endif
25440
25441 #undef $ac_func
25442
25443 /* Override any gcc2 internal prototype to avoid an error.  */
25444 #ifdef __cplusplus
25445 extern "C"
25446 {
25447 #endif
25448 /* We use char because int might match the return type of a gcc2
25449    builtin and then its argument prototype would still apply.  */
25450 char $ac_func ();
25451 /* The GNU C library defines this for functions which it implements
25452     to always fail with ENOSYS.  Some functions are actually named
25453     something starting with __ and the normal name is an alias.  */
25454 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
25455 choke me
25456 #else
25457 char (*f) () = $ac_func;
25458 #endif
25459 #ifdef __cplusplus
25460 }
25461 #endif
25462
25463 int
25464 main ()
25465 {
25466 return f != $ac_func;
25467   ;
25468   return 0;
25469 }
25470 _ACEOF
25471 rm -f conftest.$ac_objext conftest$ac_exeext
25472 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25473   (eval $ac_link) 2>conftest.er1
25474   ac_status=$?
25475   grep -v '^ *+' conftest.er1 >conftest.err
25476   rm -f conftest.er1
25477   cat conftest.err >&5
25478   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25479   (exit $ac_status); } &&
25480          { ac_try='test -z "$ac_c_werror_flag"
25481                          || test ! -s conftest.err'
25482   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25483   (eval $ac_try) 2>&5
25484   ac_status=$?
25485   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25486   (exit $ac_status); }; } &&
25487          { ac_try='test -s conftest$ac_exeext'
25488   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25489   (eval $ac_try) 2>&5
25490   ac_status=$?
25491   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25492   (exit $ac_status); }; }; then
25493   eval "$as_ac_var=yes"
25494 else
25495   echo "$as_me: failed program was:" >&5
25496 sed 's/^/| /' conftest.$ac_ext >&5
25497
25498 eval "$as_ac_var=no"
25499 fi
25500 rm -f conftest.err conftest.$ac_objext \
25501       conftest$ac_exeext conftest.$ac_ext
25502 fi
25503 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
25504 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
25505 if test `eval echo '${'$as_ac_var'}'` = yes; then
25506   cat >>confdefs.h <<_ACEOF
25507 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
25508 _ACEOF
25509
25510 fi
25511 done
25512
25513                 fi
25514         fi
25515
25516
25517 for ac_header in lwp/lwp.h
25518 do
25519 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25520 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25521   echo "$as_me:$LINENO: checking for $ac_header" >&5
25522 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25523 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25524   echo $ECHO_N "(cached) $ECHO_C" >&6
25525 fi
25526 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25527 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25528 else
25529   # Is the header compilable?
25530 echo "$as_me:$LINENO: checking $ac_header usability" >&5
25531 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
25532 cat >conftest.$ac_ext <<_ACEOF
25533 /* confdefs.h.  */
25534 _ACEOF
25535 cat confdefs.h >>conftest.$ac_ext
25536 cat >>conftest.$ac_ext <<_ACEOF
25537 /* end confdefs.h.  */
25538 $ac_includes_default
25539 #include <$ac_header>
25540 _ACEOF
25541 rm -f conftest.$ac_objext
25542 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
25543   (eval $ac_compile) 2>conftest.er1
25544   ac_status=$?
25545   grep -v '^ *+' conftest.er1 >conftest.err
25546   rm -f conftest.er1
25547   cat conftest.err >&5
25548   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25549   (exit $ac_status); } &&
25550          { ac_try='test -z "$ac_c_werror_flag"
25551                          || test ! -s conftest.err'
25552   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25553   (eval $ac_try) 2>&5
25554   ac_status=$?
25555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25556   (exit $ac_status); }; } &&
25557          { ac_try='test -s conftest.$ac_objext'
25558   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25559   (eval $ac_try) 2>&5
25560   ac_status=$?
25561   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25562   (exit $ac_status); }; }; then
25563   ac_header_compiler=yes
25564 else
25565   echo "$as_me: failed program was:" >&5
25566 sed 's/^/| /' conftest.$ac_ext >&5
25567
25568 ac_header_compiler=no
25569 fi
25570 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
25571 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25572 echo "${ECHO_T}$ac_header_compiler" >&6
25573
25574 # Is the header present?
25575 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25576 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25577 cat >conftest.$ac_ext <<_ACEOF
25578 /* confdefs.h.  */
25579 _ACEOF
25580 cat confdefs.h >>conftest.$ac_ext
25581 cat >>conftest.$ac_ext <<_ACEOF
25582 /* end confdefs.h.  */
25583 #include <$ac_header>
25584 _ACEOF
25585 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25586   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25587   ac_status=$?
25588   grep -v '^ *+' conftest.er1 >conftest.err
25589   rm -f conftest.er1
25590   cat conftest.err >&5
25591   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25592   (exit $ac_status); } >/dev/null; then
25593   if test -s conftest.err; then
25594     ac_cpp_err=$ac_c_preproc_warn_flag
25595     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25596   else
25597     ac_cpp_err=
25598   fi
25599 else
25600   ac_cpp_err=yes
25601 fi
25602 if test -z "$ac_cpp_err"; then
25603   ac_header_preproc=yes
25604 else
25605   echo "$as_me: failed program was:" >&5
25606 sed 's/^/| /' conftest.$ac_ext >&5
25607
25608   ac_header_preproc=no
25609 fi
25610 rm -f conftest.err conftest.$ac_ext
25611 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25612 echo "${ECHO_T}$ac_header_preproc" >&6
25613
25614 # So?  What about this header?
25615 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25616   yes:no: )
25617     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25618 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25619     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25620 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25621     ac_header_preproc=yes
25622     ;;
25623   no:yes:* )
25624     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25625 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25626     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25627 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25628     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25629 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25630     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25631 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25632     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25633 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25634     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25635 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25636     (
25637       cat <<\_ASBOX
25638 ## --------------------------------------------- ##
25639 ## Report this to <http://www.openldap.org/its/> ##
25640 ## --------------------------------------------- ##
25641 _ASBOX
25642     ) |
25643       sed "s/^/$as_me: WARNING:     /" >&2
25644     ;;
25645 esac
25646 echo "$as_me:$LINENO: checking for $ac_header" >&5
25647 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25648 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25649   echo $ECHO_N "(cached) $ECHO_C" >&6
25650 else
25651   eval "$as_ac_Header=\$ac_header_preproc"
25652 fi
25653 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25654 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25655
25656 fi
25657 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25658   cat >>confdefs.h <<_ACEOF
25659 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25660 _ACEOF
25661
25662 fi
25663
25664 done
25665
25666         if test $ac_cv_header_lwp_lwp_h = yes ; then
25667                 echo "$as_me:$LINENO: checking for lwp_create in -llwp" >&5
25668 echo $ECHO_N "checking for lwp_create in -llwp... $ECHO_C" >&6
25669 if test "${ac_cv_lib_lwp_lwp_create+set}" = set; then
25670   echo $ECHO_N "(cached) $ECHO_C" >&6
25671 else
25672   ac_check_lib_save_LIBS=$LIBS
25673 LIBS="-llwp  $LIBS"
25674 cat >conftest.$ac_ext <<_ACEOF
25675 /* confdefs.h.  */
25676 _ACEOF
25677 cat confdefs.h >>conftest.$ac_ext
25678 cat >>conftest.$ac_ext <<_ACEOF
25679 /* end confdefs.h.  */
25680
25681 /* Override any gcc2 internal prototype to avoid an error.  */
25682 #ifdef __cplusplus
25683 extern "C"
25684 #endif
25685 /* We use char because int might match the return type of a gcc2
25686    builtin and then its argument prototype would still apply.  */
25687 char lwp_create ();
25688 int
25689 main ()
25690 {
25691 lwp_create ();
25692   ;
25693   return 0;
25694 }
25695 _ACEOF
25696 rm -f conftest.$ac_objext conftest$ac_exeext
25697 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25698   (eval $ac_link) 2>conftest.er1
25699   ac_status=$?
25700   grep -v '^ *+' conftest.er1 >conftest.err
25701   rm -f conftest.er1
25702   cat conftest.err >&5
25703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25704   (exit $ac_status); } &&
25705          { ac_try='test -z "$ac_c_werror_flag"
25706                          || test ! -s conftest.err'
25707   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25708   (eval $ac_try) 2>&5
25709   ac_status=$?
25710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25711   (exit $ac_status); }; } &&
25712          { ac_try='test -s conftest$ac_exeext'
25713   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25714   (eval $ac_try) 2>&5
25715   ac_status=$?
25716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25717   (exit $ac_status); }; }; then
25718   ac_cv_lib_lwp_lwp_create=yes
25719 else
25720   echo "$as_me: failed program was:" >&5
25721 sed 's/^/| /' conftest.$ac_ext >&5
25722
25723 ac_cv_lib_lwp_lwp_create=no
25724 fi
25725 rm -f conftest.err conftest.$ac_objext \
25726       conftest$ac_exeext conftest.$ac_ext
25727 LIBS=$ac_check_lib_save_LIBS
25728 fi
25729 echo "$as_me:$LINENO: result: $ac_cv_lib_lwp_lwp_create" >&5
25730 echo "${ECHO_T}$ac_cv_lib_lwp_lwp_create" >&6
25731 if test $ac_cv_lib_lwp_lwp_create = yes; then
25732   have_lwp=yes
25733 else
25734   have_lwp=no
25735 fi
25736
25737
25738                 if test $have_lwp = yes ; then
25739
25740 cat >>confdefs.h <<\_ACEOF
25741 #define HAVE_LWP 1
25742 _ACEOF
25743
25744                         LTHREAD_LIBS="$LTHREAD_LIBS -llwp"
25745                         ol_link_threads=lwp
25746
25747                         if test $ol_with_yielding_select = auto ; then
25748                                 ol_with_yielding_select=no
25749                         fi
25750                 fi
25751         fi
25752         ;;
25753 esac
25754
25755 if test $ol_with_yielding_select = yes ; then
25756
25757 cat >>confdefs.h <<\_ACEOF
25758 #define HAVE_YIELDING_SELECT 1
25759 _ACEOF
25760
25761 fi
25762
25763 if test $ol_with_threads = manual ; then
25764                 ol_link_threads=yes
25765
25766         { echo "$as_me:$LINENO: WARNING: thread defines and link options must be set manually" >&5
25767 echo "$as_me: WARNING: thread defines and link options must be set manually" >&2;}
25768
25769
25770
25771 for ac_header in pthread.h sched.h
25772 do
25773 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25774 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25775   echo "$as_me:$LINENO: checking for $ac_header" >&5
25776 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25777 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25778   echo $ECHO_N "(cached) $ECHO_C" >&6
25779 fi
25780 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25781 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25782 else
25783   # Is the header compilable?
25784 echo "$as_me:$LINENO: checking $ac_header usability" >&5
25785 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
25786 cat >conftest.$ac_ext <<_ACEOF
25787 /* confdefs.h.  */
25788 _ACEOF
25789 cat confdefs.h >>conftest.$ac_ext
25790 cat >>conftest.$ac_ext <<_ACEOF
25791 /* end confdefs.h.  */
25792 $ac_includes_default
25793 #include <$ac_header>
25794 _ACEOF
25795 rm -f conftest.$ac_objext
25796 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
25797   (eval $ac_compile) 2>conftest.er1
25798   ac_status=$?
25799   grep -v '^ *+' conftest.er1 >conftest.err
25800   rm -f conftest.er1
25801   cat conftest.err >&5
25802   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25803   (exit $ac_status); } &&
25804          { ac_try='test -z "$ac_c_werror_flag"
25805                          || test ! -s conftest.err'
25806   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25807   (eval $ac_try) 2>&5
25808   ac_status=$?
25809   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25810   (exit $ac_status); }; } &&
25811          { ac_try='test -s conftest.$ac_objext'
25812   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25813   (eval $ac_try) 2>&5
25814   ac_status=$?
25815   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25816   (exit $ac_status); }; }; then
25817   ac_header_compiler=yes
25818 else
25819   echo "$as_me: failed program was:" >&5
25820 sed 's/^/| /' conftest.$ac_ext >&5
25821
25822 ac_header_compiler=no
25823 fi
25824 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
25825 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25826 echo "${ECHO_T}$ac_header_compiler" >&6
25827
25828 # Is the header present?
25829 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25830 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25831 cat >conftest.$ac_ext <<_ACEOF
25832 /* confdefs.h.  */
25833 _ACEOF
25834 cat confdefs.h >>conftest.$ac_ext
25835 cat >>conftest.$ac_ext <<_ACEOF
25836 /* end confdefs.h.  */
25837 #include <$ac_header>
25838 _ACEOF
25839 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25840   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25841   ac_status=$?
25842   grep -v '^ *+' conftest.er1 >conftest.err
25843   rm -f conftest.er1
25844   cat conftest.err >&5
25845   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25846   (exit $ac_status); } >/dev/null; then
25847   if test -s conftest.err; then
25848     ac_cpp_err=$ac_c_preproc_warn_flag
25849     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25850   else
25851     ac_cpp_err=
25852   fi
25853 else
25854   ac_cpp_err=yes
25855 fi
25856 if test -z "$ac_cpp_err"; then
25857   ac_header_preproc=yes
25858 else
25859   echo "$as_me: failed program was:" >&5
25860 sed 's/^/| /' conftest.$ac_ext >&5
25861
25862   ac_header_preproc=no
25863 fi
25864 rm -f conftest.err conftest.$ac_ext
25865 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25866 echo "${ECHO_T}$ac_header_preproc" >&6
25867
25868 # So?  What about this header?
25869 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25870   yes:no: )
25871     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25872 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25873     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25874 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25875     ac_header_preproc=yes
25876     ;;
25877   no:yes:* )
25878     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25879 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25880     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25881 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25882     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25883 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25884     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25885 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25886     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25887 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25888     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25889 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25890     (
25891       cat <<\_ASBOX
25892 ## --------------------------------------------- ##
25893 ## Report this to <http://www.openldap.org/its/> ##
25894 ## --------------------------------------------- ##
25895 _ASBOX
25896     ) |
25897       sed "s/^/$as_me: WARNING:     /" >&2
25898     ;;
25899 esac
25900 echo "$as_me:$LINENO: checking for $ac_header" >&5
25901 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25902 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25903   echo $ECHO_N "(cached) $ECHO_C" >&6
25904 else
25905   eval "$as_ac_Header=\$ac_header_preproc"
25906 fi
25907 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25908 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25909
25910 fi
25911 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25912   cat >>confdefs.h <<_ACEOF
25913 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25914 _ACEOF
25915
25916 fi
25917
25918 done
25919
25920
25921
25922 for ac_func in sched_yield pthread_yield
25923 do
25924 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
25925 echo "$as_me:$LINENO: checking for $ac_func" >&5
25926 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
25927 if eval "test \"\${$as_ac_var+set}\" = set"; then
25928   echo $ECHO_N "(cached) $ECHO_C" >&6
25929 else
25930   cat >conftest.$ac_ext <<_ACEOF
25931 /* confdefs.h.  */
25932 _ACEOF
25933 cat confdefs.h >>conftest.$ac_ext
25934 cat >>conftest.$ac_ext <<_ACEOF
25935 /* end confdefs.h.  */
25936 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
25937    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
25938 #define $ac_func innocuous_$ac_func
25939
25940 /* System header to define __stub macros and hopefully few prototypes,
25941     which can conflict with char $ac_func (); below.
25942     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
25943     <limits.h> exists even on freestanding compilers.  */
25944
25945 #ifdef __STDC__
25946 # include <limits.h>
25947 #else
25948 # include <assert.h>
25949 #endif
25950
25951 #undef $ac_func
25952
25953 /* Override any gcc2 internal prototype to avoid an error.  */
25954 #ifdef __cplusplus
25955 extern "C"
25956 {
25957 #endif
25958 /* We use char because int might match the return type of a gcc2
25959    builtin and then its argument prototype would still apply.  */
25960 char $ac_func ();
25961 /* The GNU C library defines this for functions which it implements
25962     to always fail with ENOSYS.  Some functions are actually named
25963     something starting with __ and the normal name is an alias.  */
25964 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
25965 choke me
25966 #else
25967 char (*f) () = $ac_func;
25968 #endif
25969 #ifdef __cplusplus
25970 }
25971 #endif
25972
25973 int
25974 main ()
25975 {
25976 return f != $ac_func;
25977   ;
25978   return 0;
25979 }
25980 _ACEOF
25981 rm -f conftest.$ac_objext conftest$ac_exeext
25982 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25983   (eval $ac_link) 2>conftest.er1
25984   ac_status=$?
25985   grep -v '^ *+' conftest.er1 >conftest.err
25986   rm -f conftest.er1
25987   cat conftest.err >&5
25988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25989   (exit $ac_status); } &&
25990          { ac_try='test -z "$ac_c_werror_flag"
25991                          || test ! -s conftest.err'
25992   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25993   (eval $ac_try) 2>&5
25994   ac_status=$?
25995   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25996   (exit $ac_status); }; } &&
25997          { ac_try='test -s conftest$ac_exeext'
25998   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25999   (eval $ac_try) 2>&5
26000   ac_status=$?
26001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26002   (exit $ac_status); }; }; then
26003   eval "$as_ac_var=yes"
26004 else
26005   echo "$as_me: failed program was:" >&5
26006 sed 's/^/| /' conftest.$ac_ext >&5
26007
26008 eval "$as_ac_var=no"
26009 fi
26010 rm -f conftest.err conftest.$ac_objext \
26011       conftest$ac_exeext conftest.$ac_ext
26012 fi
26013 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
26014 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
26015 if test `eval echo '${'$as_ac_var'}'` = yes; then
26016   cat >>confdefs.h <<_ACEOF
26017 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
26018 _ACEOF
26019
26020 fi
26021 done
26022
26023
26024         echo "$as_me:$LINENO: checking for LinuxThreads pthread.h" >&5
26025 echo $ECHO_N "checking for LinuxThreads pthread.h... $ECHO_C" >&6
26026 if test "${ol_cv_header_linux_threads+set}" = set; then
26027   echo $ECHO_N "(cached) $ECHO_C" >&6
26028 else
26029   cat >conftest.$ac_ext <<_ACEOF
26030 /* confdefs.h.  */
26031 _ACEOF
26032 cat confdefs.h >>conftest.$ac_ext
26033 cat >>conftest.$ac_ext <<_ACEOF
26034 /* end confdefs.h.  */
26035 #include <pthread.h>
26036 _ACEOF
26037 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
26038   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then
26039   ol_cv_header_linux_threads=yes
26040 else
26041   ol_cv_header_linux_threads=no
26042 fi
26043 rm -f conftest*
26044
26045
26046 fi
26047 echo "$as_me:$LINENO: result: $ol_cv_header_linux_threads" >&5
26048 echo "${ECHO_T}$ol_cv_header_linux_threads" >&6
26049         if test $ol_cv_header_linux_threads = yes; then
26050
26051 cat >>confdefs.h <<\_ACEOF
26052 #define HAVE_LINUX_THREADS 1
26053 _ACEOF
26054
26055         fi
26056
26057
26058
26059 for ac_header in mach/cthreads.h
26060 do
26061 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26062 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26063   echo "$as_me:$LINENO: checking for $ac_header" >&5
26064 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26065 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26066   echo $ECHO_N "(cached) $ECHO_C" >&6
26067 fi
26068 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26069 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26070 else
26071   # Is the header compilable?
26072 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26073 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26074 cat >conftest.$ac_ext <<_ACEOF
26075 /* confdefs.h.  */
26076 _ACEOF
26077 cat confdefs.h >>conftest.$ac_ext
26078 cat >>conftest.$ac_ext <<_ACEOF
26079 /* end confdefs.h.  */
26080 $ac_includes_default
26081 #include <$ac_header>
26082 _ACEOF
26083 rm -f conftest.$ac_objext
26084 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26085   (eval $ac_compile) 2>conftest.er1
26086   ac_status=$?
26087   grep -v '^ *+' conftest.er1 >conftest.err
26088   rm -f conftest.er1
26089   cat conftest.err >&5
26090   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26091   (exit $ac_status); } &&
26092          { ac_try='test -z "$ac_c_werror_flag"
26093                          || test ! -s conftest.err'
26094   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26095   (eval $ac_try) 2>&5
26096   ac_status=$?
26097   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26098   (exit $ac_status); }; } &&
26099          { ac_try='test -s conftest.$ac_objext'
26100   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26101   (eval $ac_try) 2>&5
26102   ac_status=$?
26103   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26104   (exit $ac_status); }; }; then
26105   ac_header_compiler=yes
26106 else
26107   echo "$as_me: failed program was:" >&5
26108 sed 's/^/| /' conftest.$ac_ext >&5
26109
26110 ac_header_compiler=no
26111 fi
26112 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26113 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26114 echo "${ECHO_T}$ac_header_compiler" >&6
26115
26116 # Is the header present?
26117 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26118 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26119 cat >conftest.$ac_ext <<_ACEOF
26120 /* confdefs.h.  */
26121 _ACEOF
26122 cat confdefs.h >>conftest.$ac_ext
26123 cat >>conftest.$ac_ext <<_ACEOF
26124 /* end confdefs.h.  */
26125 #include <$ac_header>
26126 _ACEOF
26127 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26128   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26129   ac_status=$?
26130   grep -v '^ *+' conftest.er1 >conftest.err
26131   rm -f conftest.er1
26132   cat conftest.err >&5
26133   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26134   (exit $ac_status); } >/dev/null; then
26135   if test -s conftest.err; then
26136     ac_cpp_err=$ac_c_preproc_warn_flag
26137     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26138   else
26139     ac_cpp_err=
26140   fi
26141 else
26142   ac_cpp_err=yes
26143 fi
26144 if test -z "$ac_cpp_err"; then
26145   ac_header_preproc=yes
26146 else
26147   echo "$as_me: failed program was:" >&5
26148 sed 's/^/| /' conftest.$ac_ext >&5
26149
26150   ac_header_preproc=no
26151 fi
26152 rm -f conftest.err conftest.$ac_ext
26153 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26154 echo "${ECHO_T}$ac_header_preproc" >&6
26155
26156 # So?  What about this header?
26157 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26158   yes:no: )
26159     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26160 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26161     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26162 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26163     ac_header_preproc=yes
26164     ;;
26165   no:yes:* )
26166     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26167 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26168     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26169 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26170     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26171 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26172     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26173 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26174     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26175 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26176     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26177 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26178     (
26179       cat <<\_ASBOX
26180 ## --------------------------------------------- ##
26181 ## Report this to <http://www.openldap.org/its/> ##
26182 ## --------------------------------------------- ##
26183 _ASBOX
26184     ) |
26185       sed "s/^/$as_me: WARNING:     /" >&2
26186     ;;
26187 esac
26188 echo "$as_me:$LINENO: checking for $ac_header" >&5
26189 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26190 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26191   echo $ECHO_N "(cached) $ECHO_C" >&6
26192 else
26193   eval "$as_ac_Header=\$ac_header_preproc"
26194 fi
26195 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26196 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26197
26198 fi
26199 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26200   cat >>confdefs.h <<_ACEOF
26201 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26202 _ACEOF
26203
26204 fi
26205
26206 done
26207
26208
26209 for ac_header in lwp/lwp.h
26210 do
26211 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26212 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26213   echo "$as_me:$LINENO: checking for $ac_header" >&5
26214 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26215 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26216   echo $ECHO_N "(cached) $ECHO_C" >&6
26217 fi
26218 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26219 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26220 else
26221   # Is the header compilable?
26222 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26223 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26224 cat >conftest.$ac_ext <<_ACEOF
26225 /* confdefs.h.  */
26226 _ACEOF
26227 cat confdefs.h >>conftest.$ac_ext
26228 cat >>conftest.$ac_ext <<_ACEOF
26229 /* end confdefs.h.  */
26230 $ac_includes_default
26231 #include <$ac_header>
26232 _ACEOF
26233 rm -f conftest.$ac_objext
26234 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26235   (eval $ac_compile) 2>conftest.er1
26236   ac_status=$?
26237   grep -v '^ *+' conftest.er1 >conftest.err
26238   rm -f conftest.er1
26239   cat conftest.err >&5
26240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26241   (exit $ac_status); } &&
26242          { ac_try='test -z "$ac_c_werror_flag"
26243                          || test ! -s conftest.err'
26244   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26245   (eval $ac_try) 2>&5
26246   ac_status=$?
26247   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26248   (exit $ac_status); }; } &&
26249          { ac_try='test -s conftest.$ac_objext'
26250   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26251   (eval $ac_try) 2>&5
26252   ac_status=$?
26253   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26254   (exit $ac_status); }; }; then
26255   ac_header_compiler=yes
26256 else
26257   echo "$as_me: failed program was:" >&5
26258 sed 's/^/| /' conftest.$ac_ext >&5
26259
26260 ac_header_compiler=no
26261 fi
26262 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26263 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26264 echo "${ECHO_T}$ac_header_compiler" >&6
26265
26266 # Is the header present?
26267 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26268 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26269 cat >conftest.$ac_ext <<_ACEOF
26270 /* confdefs.h.  */
26271 _ACEOF
26272 cat confdefs.h >>conftest.$ac_ext
26273 cat >>conftest.$ac_ext <<_ACEOF
26274 /* end confdefs.h.  */
26275 #include <$ac_header>
26276 _ACEOF
26277 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26278   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26279   ac_status=$?
26280   grep -v '^ *+' conftest.er1 >conftest.err
26281   rm -f conftest.er1
26282   cat conftest.err >&5
26283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26284   (exit $ac_status); } >/dev/null; then
26285   if test -s conftest.err; then
26286     ac_cpp_err=$ac_c_preproc_warn_flag
26287     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26288   else
26289     ac_cpp_err=
26290   fi
26291 else
26292   ac_cpp_err=yes
26293 fi
26294 if test -z "$ac_cpp_err"; then
26295   ac_header_preproc=yes
26296 else
26297   echo "$as_me: failed program was:" >&5
26298 sed 's/^/| /' conftest.$ac_ext >&5
26299
26300   ac_header_preproc=no
26301 fi
26302 rm -f conftest.err conftest.$ac_ext
26303 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26304 echo "${ECHO_T}$ac_header_preproc" >&6
26305
26306 # So?  What about this header?
26307 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26308   yes:no: )
26309     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26310 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26311     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26312 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26313     ac_header_preproc=yes
26314     ;;
26315   no:yes:* )
26316     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26317 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26318     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26319 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26320     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26321 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26322     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26323 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26324     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26325 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26326     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26327 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26328     (
26329       cat <<\_ASBOX
26330 ## --------------------------------------------- ##
26331 ## Report this to <http://www.openldap.org/its/> ##
26332 ## --------------------------------------------- ##
26333 _ASBOX
26334     ) |
26335       sed "s/^/$as_me: WARNING:     /" >&2
26336     ;;
26337 esac
26338 echo "$as_me:$LINENO: checking for $ac_header" >&5
26339 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26340 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26341   echo $ECHO_N "(cached) $ECHO_C" >&6
26342 else
26343   eval "$as_ac_Header=\$ac_header_preproc"
26344 fi
26345 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26346 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26347
26348 fi
26349 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26350   cat >>confdefs.h <<_ACEOF
26351 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26352 _ACEOF
26353
26354 fi
26355
26356 done
26357
26358
26359
26360 for ac_header in thread.h synch.h
26361 do
26362 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26363 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26364   echo "$as_me:$LINENO: checking for $ac_header" >&5
26365 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26366 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26367   echo $ECHO_N "(cached) $ECHO_C" >&6
26368 fi
26369 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26370 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26371 else
26372   # Is the header compilable?
26373 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26374 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26375 cat >conftest.$ac_ext <<_ACEOF
26376 /* confdefs.h.  */
26377 _ACEOF
26378 cat confdefs.h >>conftest.$ac_ext
26379 cat >>conftest.$ac_ext <<_ACEOF
26380 /* end confdefs.h.  */
26381 $ac_includes_default
26382 #include <$ac_header>
26383 _ACEOF
26384 rm -f conftest.$ac_objext
26385 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26386   (eval $ac_compile) 2>conftest.er1
26387   ac_status=$?
26388   grep -v '^ *+' conftest.er1 >conftest.err
26389   rm -f conftest.er1
26390   cat conftest.err >&5
26391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26392   (exit $ac_status); } &&
26393          { ac_try='test -z "$ac_c_werror_flag"
26394                          || test ! -s conftest.err'
26395   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26396   (eval $ac_try) 2>&5
26397   ac_status=$?
26398   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26399   (exit $ac_status); }; } &&
26400          { ac_try='test -s conftest.$ac_objext'
26401   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26402   (eval $ac_try) 2>&5
26403   ac_status=$?
26404   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26405   (exit $ac_status); }; }; then
26406   ac_header_compiler=yes
26407 else
26408   echo "$as_me: failed program was:" >&5
26409 sed 's/^/| /' conftest.$ac_ext >&5
26410
26411 ac_header_compiler=no
26412 fi
26413 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26414 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26415 echo "${ECHO_T}$ac_header_compiler" >&6
26416
26417 # Is the header present?
26418 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26419 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26420 cat >conftest.$ac_ext <<_ACEOF
26421 /* confdefs.h.  */
26422 _ACEOF
26423 cat confdefs.h >>conftest.$ac_ext
26424 cat >>conftest.$ac_ext <<_ACEOF
26425 /* end confdefs.h.  */
26426 #include <$ac_header>
26427 _ACEOF
26428 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26429   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26430   ac_status=$?
26431   grep -v '^ *+' conftest.er1 >conftest.err
26432   rm -f conftest.er1
26433   cat conftest.err >&5
26434   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26435   (exit $ac_status); } >/dev/null; then
26436   if test -s conftest.err; then
26437     ac_cpp_err=$ac_c_preproc_warn_flag
26438     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26439   else
26440     ac_cpp_err=
26441   fi
26442 else
26443   ac_cpp_err=yes
26444 fi
26445 if test -z "$ac_cpp_err"; then
26446   ac_header_preproc=yes
26447 else
26448   echo "$as_me: failed program was:" >&5
26449 sed 's/^/| /' conftest.$ac_ext >&5
26450
26451   ac_header_preproc=no
26452 fi
26453 rm -f conftest.err conftest.$ac_ext
26454 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26455 echo "${ECHO_T}$ac_header_preproc" >&6
26456
26457 # So?  What about this header?
26458 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26459   yes:no: )
26460     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26461 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26462     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26463 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26464     ac_header_preproc=yes
26465     ;;
26466   no:yes:* )
26467     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26468 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26469     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26470 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26471     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26472 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26473     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26474 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26475     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26476 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26477     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26478 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26479     (
26480       cat <<\_ASBOX
26481 ## --------------------------------------------- ##
26482 ## Report this to <http://www.openldap.org/its/> ##
26483 ## --------------------------------------------- ##
26484 _ASBOX
26485     ) |
26486       sed "s/^/$as_me: WARNING:     /" >&2
26487     ;;
26488 esac
26489 echo "$as_me:$LINENO: checking for $ac_header" >&5
26490 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26491 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26492   echo $ECHO_N "(cached) $ECHO_C" >&6
26493 else
26494   eval "$as_ac_Header=\$ac_header_preproc"
26495 fi
26496 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26497 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26498
26499 fi
26500 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26501   cat >>confdefs.h <<_ACEOF
26502 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26503 _ACEOF
26504
26505 fi
26506
26507 done
26508
26509 fi
26510
26511 if test $ol_link_threads != no && test $ol_link_threads != nt ; then
26512                         cat >>confdefs.h <<\_ACEOF
26513 #define REENTRANT 1
26514 _ACEOF
26515
26516         cat >>confdefs.h <<\_ACEOF
26517 #define _REENTRANT 1
26518 _ACEOF
26519
26520         cat >>confdefs.h <<\_ACEOF
26521 #define THREAD_SAFE 1
26522 _ACEOF
26523
26524         cat >>confdefs.h <<\_ACEOF
26525 #define _THREAD_SAFE 1
26526 _ACEOF
26527
26528         cat >>confdefs.h <<\_ACEOF
26529 #define THREADSAFE 1
26530 _ACEOF
26531
26532         cat >>confdefs.h <<\_ACEOF
26533 #define _THREADSAFE 1
26534 _ACEOF
26535
26536         cat >>confdefs.h <<\_ACEOF
26537 #define _SGI_MP_SOURCE 1
26538 _ACEOF
26539
26540
26541                         echo "$as_me:$LINENO: checking for thread specific errno" >&5
26542 echo $ECHO_N "checking for thread specific errno... $ECHO_C" >&6
26543 if test "${ol_cv_errno_thread_specific+set}" = set; then
26544   echo $ECHO_N "(cached) $ECHO_C" >&6
26545 else
26546
26547                 cat >conftest.$ac_ext <<_ACEOF
26548 /* confdefs.h.  */
26549 _ACEOF
26550 cat confdefs.h >>conftest.$ac_ext
26551 cat >>conftest.$ac_ext <<_ACEOF
26552 /* end confdefs.h.  */
26553 #include <errno.h>
26554 int
26555 main ()
26556 {
26557 errno = 0;
26558   ;
26559   return 0;
26560 }
26561 _ACEOF
26562 rm -f conftest.$ac_objext conftest$ac_exeext
26563 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26564   (eval $ac_link) 2>conftest.er1
26565   ac_status=$?
26566   grep -v '^ *+' conftest.er1 >conftest.err
26567   rm -f conftest.er1
26568   cat conftest.err >&5
26569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26570   (exit $ac_status); } &&
26571          { ac_try='test -z "$ac_c_werror_flag"
26572                          || test ! -s conftest.err'
26573   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26574   (eval $ac_try) 2>&5
26575   ac_status=$?
26576   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26577   (exit $ac_status); }; } &&
26578          { ac_try='test -s conftest$ac_exeext'
26579   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26580   (eval $ac_try) 2>&5
26581   ac_status=$?
26582   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26583   (exit $ac_status); }; }; then
26584   ol_cv_errno_thread_specific=yes
26585 else
26586   echo "$as_me: failed program was:" >&5
26587 sed 's/^/| /' conftest.$ac_ext >&5
26588
26589 ol_cv_errno_thread_specific=no
26590 fi
26591 rm -f conftest.err conftest.$ac_objext \
26592       conftest$ac_exeext conftest.$ac_ext
26593
26594 fi
26595 echo "$as_me:$LINENO: result: $ol_cv_errno_thread_specific" >&5
26596 echo "${ECHO_T}$ol_cv_errno_thread_specific" >&6
26597
26598                         echo "$as_me:$LINENO: checking for thread specific h_errno" >&5
26599 echo $ECHO_N "checking for thread specific h_errno... $ECHO_C" >&6
26600 if test "${ol_cv_h_errno_thread_specific+set}" = set; then
26601   echo $ECHO_N "(cached) $ECHO_C" >&6
26602 else
26603
26604                 cat >conftest.$ac_ext <<_ACEOF
26605 /* confdefs.h.  */
26606 _ACEOF
26607 cat confdefs.h >>conftest.$ac_ext
26608 cat >>conftest.$ac_ext <<_ACEOF
26609 /* end confdefs.h.  */
26610 #include <netdb.h>
26611 int
26612 main ()
26613 {
26614 h_errno = 0;
26615   ;
26616   return 0;
26617 }
26618 _ACEOF
26619 rm -f conftest.$ac_objext conftest$ac_exeext
26620 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26621   (eval $ac_link) 2>conftest.er1
26622   ac_status=$?
26623   grep -v '^ *+' conftest.er1 >conftest.err
26624   rm -f conftest.er1
26625   cat conftest.err >&5
26626   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26627   (exit $ac_status); } &&
26628          { ac_try='test -z "$ac_c_werror_flag"
26629                          || test ! -s conftest.err'
26630   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26631   (eval $ac_try) 2>&5
26632   ac_status=$?
26633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26634   (exit $ac_status); }; } &&
26635          { ac_try='test -s conftest$ac_exeext'
26636   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26637   (eval $ac_try) 2>&5
26638   ac_status=$?
26639   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26640   (exit $ac_status); }; }; then
26641   ol_cv_h_errno_thread_specific=yes
26642 else
26643   echo "$as_me: failed program was:" >&5
26644 sed 's/^/| /' conftest.$ac_ext >&5
26645
26646 ol_cv_h_errno_thread_specific=no
26647 fi
26648 rm -f conftest.err conftest.$ac_objext \
26649       conftest$ac_exeext conftest.$ac_ext
26650
26651 fi
26652 echo "$as_me:$LINENO: result: $ol_cv_h_errno_thread_specific" >&5
26653 echo "${ECHO_T}$ol_cv_h_errno_thread_specific" >&6
26654
26655         if test $ol_cv_errno_thread_specific != yes ||
26656            test $ol_cv_h_errno_thread_specific != yes ; then
26657                 LIBS="$LTHREAD_LIBS $LIBS"
26658                 LTHREAD_LIBS=""
26659         fi
26660
26661 fi
26662
26663 if test $ol_link_threads = no ; then
26664         if test $ol_with_threads = yes ; then
26665                 { { echo "$as_me:$LINENO: error: no suitable thread support" >&5
26666 echo "$as_me: error: no suitable thread support" >&2;}
26667    { (exit 1); exit 1; }; }
26668         fi
26669
26670         if test $ol_with_threads = auto ; then
26671                 { echo "$as_me:$LINENO: WARNING: no suitable thread support, disabling threads" >&5
26672 echo "$as_me: WARNING: no suitable thread support, disabling threads" >&2;}
26673                 ol_with_threads=no
26674         fi
26675
26676
26677 cat >>confdefs.h <<\_ACEOF
26678 #define NO_THREADS 1
26679 _ACEOF
26680
26681         LTHREAD_LIBS=""
26682         BUILD_THREAD=no
26683 else
26684         BUILD_THREAD=yes
26685 fi
26686
26687 if test $ol_link_threads != no ; then
26688
26689 cat >>confdefs.h <<\_ACEOF
26690 #define LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE 1
26691 _ACEOF
26692
26693 fi
26694
26695
26696
26697
26698 for ac_func in \
26699         ctime_r                 \
26700         gethostbyname_r gethostbyaddr_r \
26701
26702 do
26703 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
26704 echo "$as_me:$LINENO: checking for $ac_func" >&5
26705 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
26706 if eval "test \"\${$as_ac_var+set}\" = set"; then
26707   echo $ECHO_N "(cached) $ECHO_C" >&6
26708 else
26709   cat >conftest.$ac_ext <<_ACEOF
26710 /* confdefs.h.  */
26711 _ACEOF
26712 cat confdefs.h >>conftest.$ac_ext
26713 cat >>conftest.$ac_ext <<_ACEOF
26714 /* end confdefs.h.  */
26715 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
26716    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
26717 #define $ac_func innocuous_$ac_func
26718
26719 /* System header to define __stub macros and hopefully few prototypes,
26720     which can conflict with char $ac_func (); below.
26721     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
26722     <limits.h> exists even on freestanding compilers.  */
26723
26724 #ifdef __STDC__
26725 # include <limits.h>
26726 #else
26727 # include <assert.h>
26728 #endif
26729
26730 #undef $ac_func
26731
26732 /* Override any gcc2 internal prototype to avoid an error.  */
26733 #ifdef __cplusplus
26734 extern "C"
26735 {
26736 #endif
26737 /* We use char because int might match the return type of a gcc2
26738    builtin and then its argument prototype would still apply.  */
26739 char $ac_func ();
26740 /* The GNU C library defines this for functions which it implements
26741     to always fail with ENOSYS.  Some functions are actually named
26742     something starting with __ and the normal name is an alias.  */
26743 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
26744 choke me
26745 #else
26746 char (*f) () = $ac_func;
26747 #endif
26748 #ifdef __cplusplus
26749 }
26750 #endif
26751
26752 int
26753 main ()
26754 {
26755 return f != $ac_func;
26756   ;
26757   return 0;
26758 }
26759 _ACEOF
26760 rm -f conftest.$ac_objext conftest$ac_exeext
26761 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26762   (eval $ac_link) 2>conftest.er1
26763   ac_status=$?
26764   grep -v '^ *+' conftest.er1 >conftest.err
26765   rm -f conftest.er1
26766   cat conftest.err >&5
26767   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26768   (exit $ac_status); } &&
26769          { ac_try='test -z "$ac_c_werror_flag"
26770                          || test ! -s conftest.err'
26771   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26772   (eval $ac_try) 2>&5
26773   ac_status=$?
26774   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26775   (exit $ac_status); }; } &&
26776          { ac_try='test -s conftest$ac_exeext'
26777   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26778   (eval $ac_try) 2>&5
26779   ac_status=$?
26780   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26781   (exit $ac_status); }; }; then
26782   eval "$as_ac_var=yes"
26783 else
26784   echo "$as_me: failed program was:" >&5
26785 sed 's/^/| /' conftest.$ac_ext >&5
26786
26787 eval "$as_ac_var=no"
26788 fi
26789 rm -f conftest.err conftest.$ac_objext \
26790       conftest$ac_exeext conftest.$ac_ext
26791 fi
26792 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
26793 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
26794 if test `eval echo '${'$as_ac_var'}'` = yes; then
26795   cat >>confdefs.h <<_ACEOF
26796 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
26797 _ACEOF
26798
26799 fi
26800 done
26801
26802
26803 if test "$ac_cv_func_ctime_r" = no ; then
26804         ol_cv_func_ctime_r_nargs=0
26805 else
26806         echo "$as_me:$LINENO: checking number of arguments of ctime_r" >&5
26807 echo $ECHO_N "checking number of arguments of ctime_r... $ECHO_C" >&6
26808 if test "${ol_cv_func_ctime_r_nargs+set}" = set; then
26809   echo $ECHO_N "(cached) $ECHO_C" >&6
26810 else
26811   cat >conftest.$ac_ext <<_ACEOF
26812 /* confdefs.h.  */
26813 _ACEOF
26814 cat confdefs.h >>conftest.$ac_ext
26815 cat >>conftest.$ac_ext <<_ACEOF
26816 /* end confdefs.h.  */
26817 #include <time.h>
26818 int
26819 main ()
26820 {
26821 time_t ti; char *buffer; ctime_r(&ti,buffer,32);
26822   ;
26823   return 0;
26824 }
26825 _ACEOF
26826 rm -f conftest.$ac_objext
26827 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26828   (eval $ac_compile) 2>conftest.er1
26829   ac_status=$?
26830   grep -v '^ *+' conftest.er1 >conftest.err
26831   rm -f conftest.er1
26832   cat conftest.err >&5
26833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26834   (exit $ac_status); } &&
26835          { ac_try='test -z "$ac_c_werror_flag"
26836                          || test ! -s conftest.err'
26837   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26838   (eval $ac_try) 2>&5
26839   ac_status=$?
26840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26841   (exit $ac_status); }; } &&
26842          { ac_try='test -s conftest.$ac_objext'
26843   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26844   (eval $ac_try) 2>&5
26845   ac_status=$?
26846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26847   (exit $ac_status); }; }; then
26848   ol_cv_func_ctime_r_nargs3=yes
26849 else
26850   echo "$as_me: failed program was:" >&5
26851 sed 's/^/| /' conftest.$ac_ext >&5
26852
26853 ol_cv_func_ctime_r_nargs3=no
26854 fi
26855 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26856
26857         cat >conftest.$ac_ext <<_ACEOF
26858 /* confdefs.h.  */
26859 _ACEOF
26860 cat confdefs.h >>conftest.$ac_ext
26861 cat >>conftest.$ac_ext <<_ACEOF
26862 /* end confdefs.h.  */
26863 #include <time.h>
26864 int
26865 main ()
26866 {
26867 time_t ti; char *buffer; ctime_r(&ti,buffer);
26868   ;
26869   return 0;
26870 }
26871 _ACEOF
26872 rm -f conftest.$ac_objext
26873 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26874   (eval $ac_compile) 2>conftest.er1
26875   ac_status=$?
26876   grep -v '^ *+' conftest.er1 >conftest.err
26877   rm -f conftest.er1
26878   cat conftest.err >&5
26879   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26880   (exit $ac_status); } &&
26881          { ac_try='test -z "$ac_c_werror_flag"
26882                          || test ! -s conftest.err'
26883   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26884   (eval $ac_try) 2>&5
26885   ac_status=$?
26886   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26887   (exit $ac_status); }; } &&
26888          { ac_try='test -s conftest.$ac_objext'
26889   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26890   (eval $ac_try) 2>&5
26891   ac_status=$?
26892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26893   (exit $ac_status); }; }; then
26894   ol_cv_func_ctime_r_nargs2=yes
26895 else
26896   echo "$as_me: failed program was:" >&5
26897 sed 's/^/| /' conftest.$ac_ext >&5
26898
26899 ol_cv_func_ctime_r_nargs2=no
26900 fi
26901 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26902
26903         if test $ol_cv_func_ctime_r_nargs3 = yes &&
26904            test $ol_cv_func_ctime_r_nargs2 = no ; then
26905
26906                 ol_cv_func_ctime_r_nargs=3
26907
26908         elif test $ol_cv_func_ctime_r_nargs3 = no &&
26909              test $ol_cv_func_ctime_r_nargs2 = yes ; then
26910
26911                 ol_cv_func_ctime_r_nargs=2
26912
26913         else
26914                 ol_cv_func_ctime_r_nargs=0
26915         fi
26916
26917 fi
26918 echo "$as_me:$LINENO: result: $ol_cv_func_ctime_r_nargs" >&5
26919 echo "${ECHO_T}$ol_cv_func_ctime_r_nargs" >&6
26920
26921   if test $ol_cv_func_ctime_r_nargs -gt 1 ; then
26922
26923 cat >>confdefs.h <<_ACEOF
26924 #define CTIME_R_NARGS $ol_cv_func_ctime_r_nargs
26925 _ACEOF
26926
26927   fi
26928
26929 fi
26930
26931 if test "$ac_cv_func_gethostbyname_r" = yes ; then
26932         echo "$as_me:$LINENO: checking number of arguments of gethostbyname_r" >&5
26933 echo $ECHO_N "checking number of arguments of gethostbyname_r... $ECHO_C" >&6
26934 if test "${ol_cv_func_gethostbyname_r_nargs+set}" = set; then
26935   echo $ECHO_N "(cached) $ECHO_C" >&6
26936 else
26937   cat >conftest.$ac_ext <<_ACEOF
26938 /* confdefs.h.  */
26939 _ACEOF
26940 cat confdefs.h >>conftest.$ac_ext
26941 cat >>conftest.$ac_ext <<_ACEOF
26942 /* end confdefs.h.  */
26943 #include <sys/types.h>
26944 #include <sys/socket.h>
26945 #include <netinet/in.h>
26946 #include <netdb.h>
26947 #define BUFSIZE (sizeof(struct hostent)+10)
26948 int
26949 main ()
26950 {
26951 struct hostent hent; char buffer[BUFSIZE];
26952                 int bufsize=BUFSIZE;int h_errno;
26953                 (void)gethostbyname_r("segovia.cs.purdue.edu", &hent,
26954                         buffer, bufsize, &h_errno);
26955   ;
26956   return 0;
26957 }
26958 _ACEOF
26959 rm -f conftest.$ac_objext
26960 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26961   (eval $ac_compile) 2>conftest.er1
26962   ac_status=$?
26963   grep -v '^ *+' conftest.er1 >conftest.err
26964   rm -f conftest.er1
26965   cat conftest.err >&5
26966   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26967   (exit $ac_status); } &&
26968          { ac_try='test -z "$ac_c_werror_flag"
26969                          || test ! -s conftest.err'
26970   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26971   (eval $ac_try) 2>&5
26972   ac_status=$?
26973   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26974   (exit $ac_status); }; } &&
26975          { ac_try='test -s conftest.$ac_objext'
26976   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26977   (eval $ac_try) 2>&5
26978   ac_status=$?
26979   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26980   (exit $ac_status); }; }; then
26981   ol_cv_func_gethostbyname_r_nargs5=yes
26982 else
26983   echo "$as_me: failed program was:" >&5
26984 sed 's/^/| /' conftest.$ac_ext >&5
26985
26986 ol_cv_func_gethostbyname_r_nargs5=no
26987 fi
26988 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26989
26990         cat >conftest.$ac_ext <<_ACEOF
26991 /* confdefs.h.  */
26992 _ACEOF
26993 cat confdefs.h >>conftest.$ac_ext
26994 cat >>conftest.$ac_ext <<_ACEOF
26995 /* end confdefs.h.  */
26996 #include <sys/types.h>
26997 #include <sys/socket.h>
26998 #include <netinet/in.h>
26999 #include <netdb.h>
27000 #define BUFSIZE (sizeof(struct hostent)+10)
27001 int
27002 main ()
27003 {
27004 struct hostent hent;struct hostent *rhent;
27005                 char buffer[BUFSIZE];
27006                 int bufsize=BUFSIZE;int h_errno;
27007                 (void)gethostbyname_r("localhost", &hent, buffer, bufsize,
27008                         &rhent, &h_errno);
27009   ;
27010   return 0;
27011 }
27012 _ACEOF
27013 rm -f conftest.$ac_objext
27014 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27015   (eval $ac_compile) 2>conftest.er1
27016   ac_status=$?
27017   grep -v '^ *+' conftest.er1 >conftest.err
27018   rm -f conftest.er1
27019   cat conftest.err >&5
27020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27021   (exit $ac_status); } &&
27022          { ac_try='test -z "$ac_c_werror_flag"
27023                          || test ! -s conftest.err'
27024   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27025   (eval $ac_try) 2>&5
27026   ac_status=$?
27027   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27028   (exit $ac_status); }; } &&
27029          { ac_try='test -s conftest.$ac_objext'
27030   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27031   (eval $ac_try) 2>&5
27032   ac_status=$?
27033   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27034   (exit $ac_status); }; }; then
27035   ol_cv_func_gethostbyname_r_nargs6=yes
27036 else
27037   echo "$as_me: failed program was:" >&5
27038 sed 's/^/| /' conftest.$ac_ext >&5
27039
27040 ol_cv_func_gethostbyname_r_nargs6=no
27041 fi
27042 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27043
27044         if test $ol_cv_func_gethostbyname_r_nargs5 = yes &&
27045            test $ol_cv_func_gethostbyname_r_nargs6 = no ; then
27046
27047                 ol_cv_func_gethostbyname_r_nargs=5
27048
27049         elif test $ol_cv_func_gethostbyname_r_nargs5 = no &&
27050              test $ol_cv_func_gethostbyname_r_nargs6 = yes ; then
27051
27052                 ol_cv_func_gethostbyname_r_nargs=6
27053
27054         else
27055                 ol_cv_func_gethostbyname_r_nargs=0
27056         fi
27057
27058 fi
27059 echo "$as_me:$LINENO: result: $ol_cv_func_gethostbyname_r_nargs" >&5
27060 echo "${ECHO_T}$ol_cv_func_gethostbyname_r_nargs" >&6
27061   if test $ol_cv_func_gethostbyname_r_nargs -gt 1 ; then
27062
27063 cat >>confdefs.h <<_ACEOF
27064 #define GETHOSTBYNAME_R_NARGS $ol_cv_func_gethostbyname_r_nargs
27065 _ACEOF
27066
27067   fi
27068
27069 else
27070         ol_cv_func_gethostbyname_r_nargs=0
27071 fi
27072
27073 if test "$ac_cv_func_gethostbyaddr_r" = yes ; then
27074         echo "$as_me:$LINENO: checking number of arguments of gethostbyaddr_r" >&5
27075 echo $ECHO_N "checking number of arguments of gethostbyaddr_r... $ECHO_C" >&6
27076 if test "${ol_cv_func_gethostbyaddr_r_nargs+set}" = set; then
27077   echo $ECHO_N "(cached) $ECHO_C" >&6
27078 else
27079   cat >conftest.$ac_ext <<_ACEOF
27080 /* confdefs.h.  */
27081 _ACEOF
27082 cat confdefs.h >>conftest.$ac_ext
27083 cat >>conftest.$ac_ext <<_ACEOF
27084 /* end confdefs.h.  */
27085 #include <sys/types.h>
27086 #include <sys/socket.h>
27087 #include <netinet/in.h>
27088 #include <netdb.h>
27089 #define BUFSIZE (sizeof(struct hostent)+10)
27090 int
27091 main ()
27092 {
27093 struct hostent hent; char buffer[BUFSIZE];
27094             struct in_addr add;
27095             size_t alen=sizeof(struct in_addr);
27096             int bufsize=BUFSIZE;int h_errno;
27097                 (void)gethostbyaddr_r( (void *)&(add.s_addr),
27098                         alen, AF_INET, &hent, buffer, bufsize, &h_errno);
27099   ;
27100   return 0;
27101 }
27102 _ACEOF
27103 rm -f conftest.$ac_objext
27104 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27105   (eval $ac_compile) 2>conftest.er1
27106   ac_status=$?
27107   grep -v '^ *+' conftest.er1 >conftest.err
27108   rm -f conftest.er1
27109   cat conftest.err >&5
27110   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27111   (exit $ac_status); } &&
27112          { ac_try='test -z "$ac_c_werror_flag"
27113                          || test ! -s conftest.err'
27114   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27115   (eval $ac_try) 2>&5
27116   ac_status=$?
27117   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27118   (exit $ac_status); }; } &&
27119          { ac_try='test -s conftest.$ac_objext'
27120   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27121   (eval $ac_try) 2>&5
27122   ac_status=$?
27123   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27124   (exit $ac_status); }; }; then
27125   ol_cv_func_gethostbyaddr_r_nargs7=yes
27126 else
27127   echo "$as_me: failed program was:" >&5
27128 sed 's/^/| /' conftest.$ac_ext >&5
27129
27130 ol_cv_func_gethostbyaddr_r_nargs7=no
27131 fi
27132 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27133
27134         cat >conftest.$ac_ext <<_ACEOF
27135 /* confdefs.h.  */
27136 _ACEOF
27137 cat confdefs.h >>conftest.$ac_ext
27138 cat >>conftest.$ac_ext <<_ACEOF
27139 /* end confdefs.h.  */
27140 #include <sys/types.h>
27141 #include <sys/socket.h>
27142 #include <netinet/in.h>
27143 #include <netdb.h>
27144 #define BUFSIZE (sizeof(struct hostent)+10)
27145 int
27146 main ()
27147 {
27148 struct hostent hent;
27149                 struct hostent *rhent; char buffer[BUFSIZE];
27150                 struct in_addr add;
27151                 size_t alen=sizeof(struct in_addr);
27152                 int bufsize=BUFSIZE;int h_errno;
27153                 (void)gethostbyaddr_r( (void *)&(add.s_addr),
27154                         alen, AF_INET, &hent, buffer, bufsize,
27155                         &rhent, &h_errno);
27156   ;
27157   return 0;
27158 }
27159 _ACEOF
27160 rm -f conftest.$ac_objext
27161 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27162   (eval $ac_compile) 2>conftest.er1
27163   ac_status=$?
27164   grep -v '^ *+' conftest.er1 >conftest.err
27165   rm -f conftest.er1
27166   cat conftest.err >&5
27167   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27168   (exit $ac_status); } &&
27169          { ac_try='test -z "$ac_c_werror_flag"
27170                          || test ! -s conftest.err'
27171   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27172   (eval $ac_try) 2>&5
27173   ac_status=$?
27174   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27175   (exit $ac_status); }; } &&
27176          { ac_try='test -s conftest.$ac_objext'
27177   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27178   (eval $ac_try) 2>&5
27179   ac_status=$?
27180   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27181   (exit $ac_status); }; }; then
27182   ol_cv_func_gethostbyaddr_r_nargs8=yes
27183 else
27184   echo "$as_me: failed program was:" >&5
27185 sed 's/^/| /' conftest.$ac_ext >&5
27186
27187 ol_cv_func_gethostbyaddr_r_nargs8=no
27188 fi
27189 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27190
27191         if test $ol_cv_func_gethostbyaddr_r_nargs7 = yes &&
27192            test $ol_cv_func_gethostbyaddr_r_nargs8 = no ; then
27193
27194                 ol_cv_func_gethostbyaddr_r_nargs=7
27195
27196         elif test $ol_cv_func_gethostbyaddr_r_nargs7 = no &&
27197              test $ol_cv_func_gethostbyaddr_r_nargs8 = yes ; then
27198
27199                 ol_cv_func_gethostbyaddr_r_nargs=8
27200
27201         else
27202                 ol_cv_func_gethostbyaddr_r_nargs=0
27203         fi
27204
27205 fi
27206 echo "$as_me:$LINENO: result: $ol_cv_func_gethostbyaddr_r_nargs" >&5
27207 echo "${ECHO_T}$ol_cv_func_gethostbyaddr_r_nargs" >&6
27208   if test $ol_cv_func_gethostbyaddr_r_nargs -gt 1 ; then
27209
27210 cat >>confdefs.h <<_ACEOF
27211 #define GETHOSTBYADDR_R_NARGS $ol_cv_func_gethostbyaddr_r_nargs
27212 _ACEOF
27213
27214   fi
27215
27216 else
27217         ol_cv_func_gethostbyaddr_r_nargs=0
27218 fi
27219
27220 ol_link_bdb=no
27221
27222 if test $ol_enable_bdb/$ol_enable_hdb != no/no; then
27223         ol_cv_berkeley_db=no
27224
27225 for ac_header in db.h
27226 do
27227 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
27228 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27229   echo "$as_me:$LINENO: checking for $ac_header" >&5
27230 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27231 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27232   echo $ECHO_N "(cached) $ECHO_C" >&6
27233 fi
27234 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27235 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27236 else
27237   # Is the header compilable?
27238 echo "$as_me:$LINENO: checking $ac_header usability" >&5
27239 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
27240 cat >conftest.$ac_ext <<_ACEOF
27241 /* confdefs.h.  */
27242 _ACEOF
27243 cat confdefs.h >>conftest.$ac_ext
27244 cat >>conftest.$ac_ext <<_ACEOF
27245 /* end confdefs.h.  */
27246 $ac_includes_default
27247 #include <$ac_header>
27248 _ACEOF
27249 rm -f conftest.$ac_objext
27250 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27251   (eval $ac_compile) 2>conftest.er1
27252   ac_status=$?
27253   grep -v '^ *+' conftest.er1 >conftest.err
27254   rm -f conftest.er1
27255   cat conftest.err >&5
27256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27257   (exit $ac_status); } &&
27258          { ac_try='test -z "$ac_c_werror_flag"
27259                          || test ! -s conftest.err'
27260   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27261   (eval $ac_try) 2>&5
27262   ac_status=$?
27263   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27264   (exit $ac_status); }; } &&
27265          { ac_try='test -s conftest.$ac_objext'
27266   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27267   (eval $ac_try) 2>&5
27268   ac_status=$?
27269   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27270   (exit $ac_status); }; }; then
27271   ac_header_compiler=yes
27272 else
27273   echo "$as_me: failed program was:" >&5
27274 sed 's/^/| /' conftest.$ac_ext >&5
27275
27276 ac_header_compiler=no
27277 fi
27278 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27279 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
27280 echo "${ECHO_T}$ac_header_compiler" >&6
27281
27282 # Is the header present?
27283 echo "$as_me:$LINENO: checking $ac_header presence" >&5
27284 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
27285 cat >conftest.$ac_ext <<_ACEOF
27286 /* confdefs.h.  */
27287 _ACEOF
27288 cat confdefs.h >>conftest.$ac_ext
27289 cat >>conftest.$ac_ext <<_ACEOF
27290 /* end confdefs.h.  */
27291 #include <$ac_header>
27292 _ACEOF
27293 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
27294   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
27295   ac_status=$?
27296   grep -v '^ *+' conftest.er1 >conftest.err
27297   rm -f conftest.er1
27298   cat conftest.err >&5
27299   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27300   (exit $ac_status); } >/dev/null; then
27301   if test -s conftest.err; then
27302     ac_cpp_err=$ac_c_preproc_warn_flag
27303     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
27304   else
27305     ac_cpp_err=
27306   fi
27307 else
27308   ac_cpp_err=yes
27309 fi
27310 if test -z "$ac_cpp_err"; then
27311   ac_header_preproc=yes
27312 else
27313   echo "$as_me: failed program was:" >&5
27314 sed 's/^/| /' conftest.$ac_ext >&5
27315
27316   ac_header_preproc=no
27317 fi
27318 rm -f conftest.err conftest.$ac_ext
27319 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
27320 echo "${ECHO_T}$ac_header_preproc" >&6
27321
27322 # So?  What about this header?
27323 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
27324   yes:no: )
27325     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
27326 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
27327     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
27328 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
27329     ac_header_preproc=yes
27330     ;;
27331   no:yes:* )
27332     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
27333 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
27334     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
27335 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
27336     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
27337 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
27338     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
27339 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
27340     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27341 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27342     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
27343 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
27344     (
27345       cat <<\_ASBOX
27346 ## --------------------------------------------- ##
27347 ## Report this to <http://www.openldap.org/its/> ##
27348 ## --------------------------------------------- ##
27349 _ASBOX
27350     ) |
27351       sed "s/^/$as_me: WARNING:     /" >&2
27352     ;;
27353 esac
27354 echo "$as_me:$LINENO: checking for $ac_header" >&5
27355 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27356 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27357   echo $ECHO_N "(cached) $ECHO_C" >&6
27358 else
27359   eval "$as_ac_Header=\$ac_header_preproc"
27360 fi
27361 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27362 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27363
27364 fi
27365 if test `eval echo '${'$as_ac_Header'}'` = yes; then
27366   cat >>confdefs.h <<_ACEOF
27367 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
27368 _ACEOF
27369
27370 fi
27371
27372 done
27373
27374 if test $ac_cv_header_db_h = yes; then
27375         ol_cv_lib_db=no
27376
27377 echo "$as_me:$LINENO: checking for Berkeley DB major version" >&5
27378 echo $ECHO_N "checking for Berkeley DB major version... $ECHO_C" >&6
27379 if test "${ol_cv_bdb_major+set}" = set; then
27380   echo $ECHO_N "(cached) $ECHO_C" >&6
27381 else
27382
27383         ol_cv_bdb_major=0
27384         if test $ol_cv_bdb_major = 0 ; then
27385                 cat >conftest.$ac_ext <<_ACEOF
27386 /* confdefs.h.  */
27387 _ACEOF
27388 cat confdefs.h >>conftest.$ac_ext
27389 cat >>conftest.$ac_ext <<_ACEOF
27390 /* end confdefs.h.  */
27391
27392 #include <db.h>
27393 #ifndef DB_VERSION_MAJOR
27394 #       define DB_VERSION_MAJOR 1
27395 #endif
27396 #if DB_VERSION_MAJOR == 4
27397 __db_version
27398 #endif
27399
27400 _ACEOF
27401 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27402   $EGREP "__db_version" >/dev/null 2>&1; then
27403   ol_cv_bdb_major=4
27404 else
27405   :
27406 fi
27407 rm -f conftest*
27408
27409         fi
27410         if test $ol_cv_bdb_major = 0 ; then
27411                 cat >conftest.$ac_ext <<_ACEOF
27412 /* confdefs.h.  */
27413 _ACEOF
27414 cat confdefs.h >>conftest.$ac_ext
27415 cat >>conftest.$ac_ext <<_ACEOF
27416 /* end confdefs.h.  */
27417
27418 #include <db.h>
27419 #ifndef DB_VERSION_MAJOR
27420 #       define DB_VERSION_MAJOR 1
27421 #endif
27422 #if DB_VERSION_MAJOR == 3
27423 __db_version
27424 #endif
27425
27426 _ACEOF
27427 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27428   $EGREP "__db_version" >/dev/null 2>&1; then
27429   ol_cv_bdb_major=3
27430 else
27431   :
27432 fi
27433 rm -f conftest*
27434
27435         fi
27436         if test $ol_cv_bdb_major = 0 ; then
27437                 cat >conftest.$ac_ext <<_ACEOF
27438 /* confdefs.h.  */
27439 _ACEOF
27440 cat confdefs.h >>conftest.$ac_ext
27441 cat >>conftest.$ac_ext <<_ACEOF
27442 /* end confdefs.h.  */
27443
27444 #include <db.h>
27445 #ifndef DB_VERSION_MAJOR
27446 #       define DB_VERSION_MAJOR 1
27447 #endif
27448 #if DB_VERSION_MAJOR == 2
27449 __db_version
27450 #endif
27451
27452 _ACEOF
27453 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27454   $EGREP "__db_version" >/dev/null 2>&1; then
27455   ol_cv_bdb_major=2
27456 else
27457   :
27458 fi
27459 rm -f conftest*
27460
27461         fi
27462         if test $ol_cv_bdb_major = 0 ; then
27463                 cat >conftest.$ac_ext <<_ACEOF
27464 /* confdefs.h.  */
27465 _ACEOF
27466 cat confdefs.h >>conftest.$ac_ext
27467 cat >>conftest.$ac_ext <<_ACEOF
27468 /* end confdefs.h.  */
27469
27470 #include <db.h>
27471 #ifndef DB_VERSION_MAJOR
27472 #       define DB_VERSION_MAJOR 1
27473 #endif
27474 #if DB_VERSION_MAJOR == 1
27475 __db_version
27476 #endif
27477
27478 _ACEOF
27479 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27480   $EGREP "__db_version" >/dev/null 2>&1; then
27481   ol_cv_bdb_major=1
27482 else
27483   :
27484 fi
27485 rm -f conftest*
27486
27487         fi
27488
27489         if test $ol_cv_bdb_major = 0 ; then
27490                 { { echo "$as_me:$LINENO: error: Unknown Berkeley DB major version" >&5
27491 echo "$as_me: error: Unknown Berkeley DB major version" >&2;}
27492    { (exit 1); exit 1; }; }
27493         fi
27494
27495 fi
27496 echo "$as_me:$LINENO: result: $ol_cv_bdb_major" >&5
27497 echo "${ECHO_T}$ol_cv_bdb_major" >&6
27498
27499 echo "$as_me:$LINENO: checking for Berkeley DB minor version" >&5
27500 echo $ECHO_N "checking for Berkeley DB minor version... $ECHO_C" >&6
27501 if test "${ol_cv_bdb_minor+set}" = set; then
27502   echo $ECHO_N "(cached) $ECHO_C" >&6
27503 else
27504
27505         ol_cv_bdb_minor=0
27506         if test $ol_cv_bdb_minor = 0 ; then
27507                 cat >conftest.$ac_ext <<_ACEOF
27508 /* confdefs.h.  */
27509 _ACEOF
27510 cat confdefs.h >>conftest.$ac_ext
27511 cat >>conftest.$ac_ext <<_ACEOF
27512 /* end confdefs.h.  */
27513
27514 #include <db.h>
27515 #ifndef DB_VERSION_MINOR
27516 #       define DB_VERSION_MINOR 0
27517 #endif
27518 #if DB_VERSION_MINOR == 9
27519 __db_version
27520 #endif
27521
27522 _ACEOF
27523 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27524   $EGREP "__db_version" >/dev/null 2>&1; then
27525   ol_cv_bdb_minor=9
27526 else
27527   :
27528 fi
27529 rm -f conftest*
27530
27531         fi
27532         if test $ol_cv_bdb_minor = 0 ; then
27533                 cat >conftest.$ac_ext <<_ACEOF
27534 /* confdefs.h.  */
27535 _ACEOF
27536 cat confdefs.h >>conftest.$ac_ext
27537 cat >>conftest.$ac_ext <<_ACEOF
27538 /* end confdefs.h.  */
27539
27540 #include <db.h>
27541 #ifndef DB_VERSION_MINOR
27542 #       define DB_VERSION_MINOR 0
27543 #endif
27544 #if DB_VERSION_MINOR == 8
27545 __db_version
27546 #endif
27547
27548 _ACEOF
27549 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27550   $EGREP "__db_version" >/dev/null 2>&1; then
27551   ol_cv_bdb_minor=8
27552 else
27553   :
27554 fi
27555 rm -f conftest*
27556
27557         fi
27558         if test $ol_cv_bdb_minor = 0 ; then
27559                 cat >conftest.$ac_ext <<_ACEOF
27560 /* confdefs.h.  */
27561 _ACEOF
27562 cat confdefs.h >>conftest.$ac_ext
27563 cat >>conftest.$ac_ext <<_ACEOF
27564 /* end confdefs.h.  */
27565
27566 #include <db.h>
27567 #ifndef DB_VERSION_MINOR
27568 #       define DB_VERSION_MINOR 0
27569 #endif
27570 #if DB_VERSION_MINOR == 7
27571 __db_version
27572 #endif
27573
27574 _ACEOF
27575 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27576   $EGREP "__db_version" >/dev/null 2>&1; then
27577   ol_cv_bdb_minor=7
27578 else
27579   :
27580 fi
27581 rm -f conftest*
27582
27583         fi
27584         if test $ol_cv_bdb_minor = 0 ; then
27585                 cat >conftest.$ac_ext <<_ACEOF
27586 /* confdefs.h.  */
27587 _ACEOF
27588 cat confdefs.h >>conftest.$ac_ext
27589 cat >>conftest.$ac_ext <<_ACEOF
27590 /* end confdefs.h.  */
27591
27592 #include <db.h>
27593 #ifndef DB_VERSION_MINOR
27594 #       define DB_VERSION_MINOR 0
27595 #endif
27596 #if DB_VERSION_MINOR == 6
27597 __db_version
27598 #endif
27599
27600 _ACEOF
27601 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27602   $EGREP "__db_version" >/dev/null 2>&1; then
27603   ol_cv_bdb_minor=6
27604 else
27605   :
27606 fi
27607 rm -f conftest*
27608
27609         fi
27610         if test $ol_cv_bdb_minor = 0 ; then
27611                 cat >conftest.$ac_ext <<_ACEOF
27612 /* confdefs.h.  */
27613 _ACEOF
27614 cat confdefs.h >>conftest.$ac_ext
27615 cat >>conftest.$ac_ext <<_ACEOF
27616 /* end confdefs.h.  */
27617
27618 #include <db.h>
27619 #ifndef DB_VERSION_MINOR
27620 #       define DB_VERSION_MINOR 0
27621 #endif
27622 #if DB_VERSION_MINOR == 5
27623 __db_version
27624 #endif
27625
27626 _ACEOF
27627 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27628   $EGREP "__db_version" >/dev/null 2>&1; then
27629   ol_cv_bdb_minor=5
27630 else
27631   :
27632 fi
27633 rm -f conftest*
27634
27635         fi
27636         if test $ol_cv_bdb_minor = 0 ; then
27637                 cat >conftest.$ac_ext <<_ACEOF
27638 /* confdefs.h.  */
27639 _ACEOF
27640 cat confdefs.h >>conftest.$ac_ext
27641 cat >>conftest.$ac_ext <<_ACEOF
27642 /* end confdefs.h.  */
27643
27644 #include <db.h>
27645 #ifndef DB_VERSION_MINOR
27646 #       define DB_VERSION_MINOR 0
27647 #endif
27648 #if DB_VERSION_MINOR == 4
27649 __db_version
27650 #endif
27651
27652 _ACEOF
27653 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27654   $EGREP "__db_version" >/dev/null 2>&1; then
27655   ol_cv_bdb_minor=4
27656 else
27657   :
27658 fi
27659 rm -f conftest*
27660
27661         fi
27662         if test $ol_cv_bdb_minor = 0 ; then
27663                 cat >conftest.$ac_ext <<_ACEOF
27664 /* confdefs.h.  */
27665 _ACEOF
27666 cat confdefs.h >>conftest.$ac_ext
27667 cat >>conftest.$ac_ext <<_ACEOF
27668 /* end confdefs.h.  */
27669
27670 #include <db.h>
27671 #ifndef DB_VERSION_MINOR
27672 #       define DB_VERSION_MINOR 0
27673 #endif
27674 #if DB_VERSION_MINOR == 3
27675 __db_version
27676 #endif
27677
27678 _ACEOF
27679 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27680   $EGREP "__db_version" >/dev/null 2>&1; then
27681   ol_cv_bdb_minor=3
27682 else
27683   :
27684 fi
27685 rm -f conftest*
27686
27687         fi
27688         if test $ol_cv_bdb_minor = 0 ; then
27689                 cat >conftest.$ac_ext <<_ACEOF
27690 /* confdefs.h.  */
27691 _ACEOF
27692 cat confdefs.h >>conftest.$ac_ext
27693 cat >>conftest.$ac_ext <<_ACEOF
27694 /* end confdefs.h.  */
27695
27696 #include <db.h>
27697 #ifndef DB_VERSION_MINOR
27698 #       define DB_VERSION_MINOR 0
27699 #endif
27700 #if DB_VERSION_MINOR == 2
27701 __db_version
27702 #endif
27703
27704 _ACEOF
27705 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27706   $EGREP "__db_version" >/dev/null 2>&1; then
27707   ol_cv_bdb_minor=2
27708 else
27709   :
27710 fi
27711 rm -f conftest*
27712
27713         fi
27714         if test $ol_cv_bdb_minor = 0 ; then
27715                 cat >conftest.$ac_ext <<_ACEOF
27716 /* confdefs.h.  */
27717 _ACEOF
27718 cat confdefs.h >>conftest.$ac_ext
27719 cat >>conftest.$ac_ext <<_ACEOF
27720 /* end confdefs.h.  */
27721
27722 #include <db.h>
27723 #ifndef DB_VERSION_MINOR
27724 #       define DB_VERSION_MINOR 0
27725 #endif
27726 #if DB_VERSION_MINOR == 1
27727 __db_version
27728 #endif
27729
27730 _ACEOF
27731 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27732   $EGREP "__db_version" >/dev/null 2>&1; then
27733   ol_cv_bdb_minor=1
27734 else
27735   :
27736 fi
27737 rm -f conftest*
27738
27739         fi
27740
27741 fi
27742 echo "$as_me:$LINENO: result: $ol_cv_bdb_minor" >&5
27743 echo "${ECHO_T}$ol_cv_bdb_minor" >&6
27744
27745 if test $ol_cv_bdb_major = 4 ; then
27746         if test $ol_cv_bdb_minor = 6 ; then
27747                 if test $ol_cv_lib_db = no ; then
27748         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.6)" >&5
27749 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.6)... $ECHO_C" >&6
27750 if test "${ol_cv_db_db_4_dot_6+set}" = set; then
27751   echo $ECHO_N "(cached) $ECHO_C" >&6
27752 else
27753
27754         ol_DB_LIB=-ldb-4.6
27755         ol_LIBS=$LIBS
27756         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
27757
27758         cat >conftest.$ac_ext <<_ACEOF
27759 /* confdefs.h.  */
27760 _ACEOF
27761 cat confdefs.h >>conftest.$ac_ext
27762 cat >>conftest.$ac_ext <<_ACEOF
27763 /* end confdefs.h.  */
27764
27765 #ifdef HAVE_DB_185_H
27766 # include <db_185.h>
27767 #else
27768 # include <db.h>
27769 #endif
27770
27771 #ifndef DB_VERSION_MAJOR
27772 # define DB_VERSION_MAJOR 1
27773 #endif
27774
27775 #ifndef NULL
27776 #define NULL ((void*)0)
27777 #endif
27778
27779 int
27780 main ()
27781 {
27782
27783 #if DB_VERSION_MAJOR > 1
27784         {
27785                 char *version;
27786                 int major, minor, patch;
27787
27788                 version = db_version( &major, &minor, &patch );
27789
27790                 if( major != DB_VERSION_MAJOR ||
27791                         minor < DB_VERSION_MINOR )
27792                 {
27793                         printf("Berkeley DB version mismatch\n"
27794                                 "\theader: %s\n\tlibrary: %s\n",
27795                                 DB_VERSION_STRING, version);
27796                         return 1;
27797                 }
27798         }
27799 #endif
27800
27801 #if DB_VERSION_MAJOR > 2
27802         db_env_create( NULL, 0 );
27803 #elif DB_VERSION_MAJOR > 1
27804         db_appexit( NULL );
27805 #else
27806         (void) dbopen( NULL, 0, 0, 0, NULL);
27807 #endif
27808
27809   ;
27810   return 0;
27811 }
27812 _ACEOF
27813 rm -f conftest.$ac_objext conftest$ac_exeext
27814 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27815   (eval $ac_link) 2>conftest.er1
27816   ac_status=$?
27817   grep -v '^ *+' conftest.er1 >conftest.err
27818   rm -f conftest.er1
27819   cat conftest.err >&5
27820   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27821   (exit $ac_status); } &&
27822          { ac_try='test -z "$ac_c_werror_flag"
27823                          || test ! -s conftest.err'
27824   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27825   (eval $ac_try) 2>&5
27826   ac_status=$?
27827   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27828   (exit $ac_status); }; } &&
27829          { ac_try='test -s conftest$ac_exeext'
27830   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27831   (eval $ac_try) 2>&5
27832   ac_status=$?
27833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27834   (exit $ac_status); }; }; then
27835   ol_cv_db_db_4_dot_6=yes
27836 else
27837   echo "$as_me: failed program was:" >&5
27838 sed 's/^/| /' conftest.$ac_ext >&5
27839
27840 ol_cv_db_db_4_dot_6=no
27841 fi
27842 rm -f conftest.err conftest.$ac_objext \
27843       conftest$ac_exeext conftest.$ac_ext
27844
27845         LIBS="$ol_LIBS"
27846
27847 fi
27848 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_6" >&5
27849 echo "${ECHO_T}$ol_cv_db_db_4_dot_6" >&6
27850
27851         if test $ol_cv_db_db_4_dot_6 = yes ; then
27852                 ol_cv_lib_db=-ldb-4.6
27853         fi
27854 fi
27855
27856                 if test $ol_cv_lib_db = no ; then
27857         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb46)" >&5
27858 echo $ECHO_N "checking for Berkeley DB link (-ldb46)... $ECHO_C" >&6
27859 if test "${ol_cv_db_db46+set}" = set; then
27860   echo $ECHO_N "(cached) $ECHO_C" >&6
27861 else
27862
27863         ol_DB_LIB=-ldb46
27864         ol_LIBS=$LIBS
27865         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
27866
27867         cat >conftest.$ac_ext <<_ACEOF
27868 /* confdefs.h.  */
27869 _ACEOF
27870 cat confdefs.h >>conftest.$ac_ext
27871 cat >>conftest.$ac_ext <<_ACEOF
27872 /* end confdefs.h.  */
27873
27874 #ifdef HAVE_DB_185_H
27875 # include <db_185.h>
27876 #else
27877 # include <db.h>
27878 #endif
27879
27880 #ifndef DB_VERSION_MAJOR
27881 # define DB_VERSION_MAJOR 1
27882 #endif
27883
27884 #ifndef NULL
27885 #define NULL ((void*)0)
27886 #endif
27887
27888 int
27889 main ()
27890 {
27891
27892 #if DB_VERSION_MAJOR > 1
27893         {
27894                 char *version;
27895                 int major, minor, patch;
27896
27897                 version = db_version( &major, &minor, &patch );
27898
27899                 if( major != DB_VERSION_MAJOR ||
27900                         minor < DB_VERSION_MINOR )
27901                 {
27902                         printf("Berkeley DB version mismatch\n"
27903                                 "\theader: %s\n\tlibrary: %s\n",
27904                                 DB_VERSION_STRING, version);
27905                         return 1;
27906                 }
27907         }
27908 #endif
27909
27910 #if DB_VERSION_MAJOR > 2
27911         db_env_create( NULL, 0 );
27912 #elif DB_VERSION_MAJOR > 1
27913         db_appexit( NULL );
27914 #else
27915         (void) dbopen( NULL, 0, 0, 0, NULL);
27916 #endif
27917
27918   ;
27919   return 0;
27920 }
27921 _ACEOF
27922 rm -f conftest.$ac_objext conftest$ac_exeext
27923 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27924   (eval $ac_link) 2>conftest.er1
27925   ac_status=$?
27926   grep -v '^ *+' conftest.er1 >conftest.err
27927   rm -f conftest.er1
27928   cat conftest.err >&5
27929   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27930   (exit $ac_status); } &&
27931          { ac_try='test -z "$ac_c_werror_flag"
27932                          || test ! -s conftest.err'
27933   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27934   (eval $ac_try) 2>&5
27935   ac_status=$?
27936   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27937   (exit $ac_status); }; } &&
27938          { ac_try='test -s conftest$ac_exeext'
27939   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27940   (eval $ac_try) 2>&5
27941   ac_status=$?
27942   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27943   (exit $ac_status); }; }; then
27944   ol_cv_db_db46=yes
27945 else
27946   echo "$as_me: failed program was:" >&5
27947 sed 's/^/| /' conftest.$ac_ext >&5
27948
27949 ol_cv_db_db46=no
27950 fi
27951 rm -f conftest.err conftest.$ac_objext \
27952       conftest$ac_exeext conftest.$ac_ext
27953
27954         LIBS="$ol_LIBS"
27955
27956 fi
27957 echo "$as_me:$LINENO: result: $ol_cv_db_db46" >&5
27958 echo "${ECHO_T}$ol_cv_db_db46" >&6
27959
27960         if test $ol_cv_db_db46 = yes ; then
27961                 ol_cv_lib_db=-ldb46
27962         fi
27963 fi
27964
27965                 if test $ol_cv_lib_db = no ; then
27966         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-46)" >&5
27967 echo $ECHO_N "checking for Berkeley DB link (-ldb-46)... $ECHO_C" >&6
27968 if test "${ol_cv_db_db_46+set}" = set; then
27969   echo $ECHO_N "(cached) $ECHO_C" >&6
27970 else
27971
27972         ol_DB_LIB=-ldb-46
27973         ol_LIBS=$LIBS
27974         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
27975
27976         cat >conftest.$ac_ext <<_ACEOF
27977 /* confdefs.h.  */
27978 _ACEOF
27979 cat confdefs.h >>conftest.$ac_ext
27980 cat >>conftest.$ac_ext <<_ACEOF
27981 /* end confdefs.h.  */
27982
27983 #ifdef HAVE_DB_185_H
27984 # include <db_185.h>
27985 #else
27986 # include <db.h>
27987 #endif
27988
27989 #ifndef DB_VERSION_MAJOR
27990 # define DB_VERSION_MAJOR 1
27991 #endif
27992
27993 #ifndef NULL
27994 #define NULL ((void*)0)
27995 #endif
27996
27997 int
27998 main ()
27999 {
28000
28001 #if DB_VERSION_MAJOR > 1
28002         {
28003                 char *version;
28004                 int major, minor, patch;
28005
28006                 version = db_version( &major, &minor, &patch );
28007
28008                 if( major != DB_VERSION_MAJOR ||
28009                         minor < DB_VERSION_MINOR )
28010                 {
28011                         printf("Berkeley DB version mismatch\n"
28012                                 "\theader: %s\n\tlibrary: %s\n",
28013                                 DB_VERSION_STRING, version);
28014                         return 1;
28015                 }
28016         }
28017 #endif
28018
28019 #if DB_VERSION_MAJOR > 2
28020         db_env_create( NULL, 0 );
28021 #elif DB_VERSION_MAJOR > 1
28022         db_appexit( NULL );
28023 #else
28024         (void) dbopen( NULL, 0, 0, 0, NULL);
28025 #endif
28026
28027   ;
28028   return 0;
28029 }
28030 _ACEOF
28031 rm -f conftest.$ac_objext conftest$ac_exeext
28032 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28033   (eval $ac_link) 2>conftest.er1
28034   ac_status=$?
28035   grep -v '^ *+' conftest.er1 >conftest.err
28036   rm -f conftest.er1
28037   cat conftest.err >&5
28038   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28039   (exit $ac_status); } &&
28040          { ac_try='test -z "$ac_c_werror_flag"
28041                          || test ! -s conftest.err'
28042   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28043   (eval $ac_try) 2>&5
28044   ac_status=$?
28045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28046   (exit $ac_status); }; } &&
28047          { ac_try='test -s conftest$ac_exeext'
28048   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28049   (eval $ac_try) 2>&5
28050   ac_status=$?
28051   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28052   (exit $ac_status); }; }; then
28053   ol_cv_db_db_46=yes
28054 else
28055   echo "$as_me: failed program was:" >&5
28056 sed 's/^/| /' conftest.$ac_ext >&5
28057
28058 ol_cv_db_db_46=no
28059 fi
28060 rm -f conftest.err conftest.$ac_objext \
28061       conftest$ac_exeext conftest.$ac_ext
28062
28063         LIBS="$ol_LIBS"
28064
28065 fi
28066 echo "$as_me:$LINENO: result: $ol_cv_db_db_46" >&5
28067 echo "${ECHO_T}$ol_cv_db_db_46" >&6
28068
28069         if test $ol_cv_db_db_46 = yes ; then
28070                 ol_cv_lib_db=-ldb-46
28071         fi
28072 fi
28073
28074                 if test $ol_cv_lib_db = no ; then
28075         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-6)" >&5
28076 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-6)... $ECHO_C" >&6
28077 if test "${ol_cv_db_db_4_6+set}" = set; then
28078   echo $ECHO_N "(cached) $ECHO_C" >&6
28079 else
28080
28081         ol_DB_LIB=-ldb-4-6
28082         ol_LIBS=$LIBS
28083         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28084
28085         cat >conftest.$ac_ext <<_ACEOF
28086 /* confdefs.h.  */
28087 _ACEOF
28088 cat confdefs.h >>conftest.$ac_ext
28089 cat >>conftest.$ac_ext <<_ACEOF
28090 /* end confdefs.h.  */
28091
28092 #ifdef HAVE_DB_185_H
28093 # include <db_185.h>
28094 #else
28095 # include <db.h>
28096 #endif
28097
28098 #ifndef DB_VERSION_MAJOR
28099 # define DB_VERSION_MAJOR 1
28100 #endif
28101
28102 #ifndef NULL
28103 #define NULL ((void*)0)
28104 #endif
28105
28106 int
28107 main ()
28108 {
28109
28110 #if DB_VERSION_MAJOR > 1
28111         {
28112                 char *version;
28113                 int major, minor, patch;
28114
28115                 version = db_version( &major, &minor, &patch );
28116
28117                 if( major != DB_VERSION_MAJOR ||
28118                         minor < DB_VERSION_MINOR )
28119                 {
28120                         printf("Berkeley DB version mismatch\n"
28121                                 "\theader: %s\n\tlibrary: %s\n",
28122                                 DB_VERSION_STRING, version);
28123                         return 1;
28124                 }
28125         }
28126 #endif
28127
28128 #if DB_VERSION_MAJOR > 2
28129         db_env_create( NULL, 0 );
28130 #elif DB_VERSION_MAJOR > 1
28131         db_appexit( NULL );
28132 #else
28133         (void) dbopen( NULL, 0, 0, 0, NULL);
28134 #endif
28135
28136   ;
28137   return 0;
28138 }
28139 _ACEOF
28140 rm -f conftest.$ac_objext conftest$ac_exeext
28141 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28142   (eval $ac_link) 2>conftest.er1
28143   ac_status=$?
28144   grep -v '^ *+' conftest.er1 >conftest.err
28145   rm -f conftest.er1
28146   cat conftest.err >&5
28147   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28148   (exit $ac_status); } &&
28149          { ac_try='test -z "$ac_c_werror_flag"
28150                          || test ! -s conftest.err'
28151   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28152   (eval $ac_try) 2>&5
28153   ac_status=$?
28154   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28155   (exit $ac_status); }; } &&
28156          { ac_try='test -s conftest$ac_exeext'
28157   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28158   (eval $ac_try) 2>&5
28159   ac_status=$?
28160   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28161   (exit $ac_status); }; }; then
28162   ol_cv_db_db_4_6=yes
28163 else
28164   echo "$as_me: failed program was:" >&5
28165 sed 's/^/| /' conftest.$ac_ext >&5
28166
28167 ol_cv_db_db_4_6=no
28168 fi
28169 rm -f conftest.err conftest.$ac_objext \
28170       conftest$ac_exeext conftest.$ac_ext
28171
28172         LIBS="$ol_LIBS"
28173
28174 fi
28175 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_6" >&5
28176 echo "${ECHO_T}$ol_cv_db_db_4_6" >&6
28177
28178         if test $ol_cv_db_db_4_6 = yes ; then
28179                 ol_cv_lib_db=-ldb-4-6
28180         fi
28181 fi
28182
28183         elif test $ol_cv_bdb_minor = 5 ; then
28184                 if test $ol_cv_lib_db = no ; then
28185         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.5)" >&5
28186 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.5)... $ECHO_C" >&6
28187 if test "${ol_cv_db_db_4_dot_5+set}" = set; then
28188   echo $ECHO_N "(cached) $ECHO_C" >&6
28189 else
28190
28191         ol_DB_LIB=-ldb-4.5
28192         ol_LIBS=$LIBS
28193         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28194
28195         cat >conftest.$ac_ext <<_ACEOF
28196 /* confdefs.h.  */
28197 _ACEOF
28198 cat confdefs.h >>conftest.$ac_ext
28199 cat >>conftest.$ac_ext <<_ACEOF
28200 /* end confdefs.h.  */
28201
28202 #ifdef HAVE_DB_185_H
28203 # include <db_185.h>
28204 #else
28205 # include <db.h>
28206 #endif
28207
28208 #ifndef DB_VERSION_MAJOR
28209 # define DB_VERSION_MAJOR 1
28210 #endif
28211
28212 #ifndef NULL
28213 #define NULL ((void*)0)
28214 #endif
28215
28216 int
28217 main ()
28218 {
28219
28220 #if DB_VERSION_MAJOR > 1
28221         {
28222                 char *version;
28223                 int major, minor, patch;
28224
28225                 version = db_version( &major, &minor, &patch );
28226
28227                 if( major != DB_VERSION_MAJOR ||
28228                         minor < DB_VERSION_MINOR )
28229                 {
28230                         printf("Berkeley DB version mismatch\n"
28231                                 "\theader: %s\n\tlibrary: %s\n",
28232                                 DB_VERSION_STRING, version);
28233                         return 1;
28234                 }
28235         }
28236 #endif
28237
28238 #if DB_VERSION_MAJOR > 2
28239         db_env_create( NULL, 0 );
28240 #elif DB_VERSION_MAJOR > 1
28241         db_appexit( NULL );
28242 #else
28243         (void) dbopen( NULL, 0, 0, 0, NULL);
28244 #endif
28245
28246   ;
28247   return 0;
28248 }
28249 _ACEOF
28250 rm -f conftest.$ac_objext conftest$ac_exeext
28251 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28252   (eval $ac_link) 2>conftest.er1
28253   ac_status=$?
28254   grep -v '^ *+' conftest.er1 >conftest.err
28255   rm -f conftest.er1
28256   cat conftest.err >&5
28257   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28258   (exit $ac_status); } &&
28259          { ac_try='test -z "$ac_c_werror_flag"
28260                          || test ! -s conftest.err'
28261   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28262   (eval $ac_try) 2>&5
28263   ac_status=$?
28264   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28265   (exit $ac_status); }; } &&
28266          { ac_try='test -s conftest$ac_exeext'
28267   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28268   (eval $ac_try) 2>&5
28269   ac_status=$?
28270   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28271   (exit $ac_status); }; }; then
28272   ol_cv_db_db_4_dot_5=yes
28273 else
28274   echo "$as_me: failed program was:" >&5
28275 sed 's/^/| /' conftest.$ac_ext >&5
28276
28277 ol_cv_db_db_4_dot_5=no
28278 fi
28279 rm -f conftest.err conftest.$ac_objext \
28280       conftest$ac_exeext conftest.$ac_ext
28281
28282         LIBS="$ol_LIBS"
28283
28284 fi
28285 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_5" >&5
28286 echo "${ECHO_T}$ol_cv_db_db_4_dot_5" >&6
28287
28288         if test $ol_cv_db_db_4_dot_5 = yes ; then
28289                 ol_cv_lib_db=-ldb-4.5
28290         fi
28291 fi
28292
28293                 if test $ol_cv_lib_db = no ; then
28294         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb45)" >&5
28295 echo $ECHO_N "checking for Berkeley DB link (-ldb45)... $ECHO_C" >&6
28296 if test "${ol_cv_db_db45+set}" = set; then
28297   echo $ECHO_N "(cached) $ECHO_C" >&6
28298 else
28299
28300         ol_DB_LIB=-ldb45
28301         ol_LIBS=$LIBS
28302         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28303
28304         cat >conftest.$ac_ext <<_ACEOF
28305 /* confdefs.h.  */
28306 _ACEOF
28307 cat confdefs.h >>conftest.$ac_ext
28308 cat >>conftest.$ac_ext <<_ACEOF
28309 /* end confdefs.h.  */
28310
28311 #ifdef HAVE_DB_185_H
28312 # include <db_185.h>
28313 #else
28314 # include <db.h>
28315 #endif
28316
28317 #ifndef DB_VERSION_MAJOR
28318 # define DB_VERSION_MAJOR 1
28319 #endif
28320
28321 #ifndef NULL
28322 #define NULL ((void*)0)
28323 #endif
28324
28325 int
28326 main ()
28327 {
28328
28329 #if DB_VERSION_MAJOR > 1
28330         {
28331                 char *version;
28332                 int major, minor, patch;
28333
28334                 version = db_version( &major, &minor, &patch );
28335
28336                 if( major != DB_VERSION_MAJOR ||
28337                         minor < DB_VERSION_MINOR )
28338                 {
28339                         printf("Berkeley DB version mismatch\n"
28340                                 "\theader: %s\n\tlibrary: %s\n",
28341                                 DB_VERSION_STRING, version);
28342                         return 1;
28343                 }
28344         }
28345 #endif
28346
28347 #if DB_VERSION_MAJOR > 2
28348         db_env_create( NULL, 0 );
28349 #elif DB_VERSION_MAJOR > 1
28350         db_appexit( NULL );
28351 #else
28352         (void) dbopen( NULL, 0, 0, 0, NULL);
28353 #endif
28354
28355   ;
28356   return 0;
28357 }
28358 _ACEOF
28359 rm -f conftest.$ac_objext conftest$ac_exeext
28360 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28361   (eval $ac_link) 2>conftest.er1
28362   ac_status=$?
28363   grep -v '^ *+' conftest.er1 >conftest.err
28364   rm -f conftest.er1
28365   cat conftest.err >&5
28366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28367   (exit $ac_status); } &&
28368          { ac_try='test -z "$ac_c_werror_flag"
28369                          || test ! -s conftest.err'
28370   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28371   (eval $ac_try) 2>&5
28372   ac_status=$?
28373   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28374   (exit $ac_status); }; } &&
28375          { ac_try='test -s conftest$ac_exeext'
28376   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28377   (eval $ac_try) 2>&5
28378   ac_status=$?
28379   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28380   (exit $ac_status); }; }; then
28381   ol_cv_db_db45=yes
28382 else
28383   echo "$as_me: failed program was:" >&5
28384 sed 's/^/| /' conftest.$ac_ext >&5
28385
28386 ol_cv_db_db45=no
28387 fi
28388 rm -f conftest.err conftest.$ac_objext \
28389       conftest$ac_exeext conftest.$ac_ext
28390
28391         LIBS="$ol_LIBS"
28392
28393 fi
28394 echo "$as_me:$LINENO: result: $ol_cv_db_db45" >&5
28395 echo "${ECHO_T}$ol_cv_db_db45" >&6
28396
28397         if test $ol_cv_db_db45 = yes ; then
28398                 ol_cv_lib_db=-ldb45
28399         fi
28400 fi
28401
28402                 if test $ol_cv_lib_db = no ; then
28403         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-45)" >&5
28404 echo $ECHO_N "checking for Berkeley DB link (-ldb-45)... $ECHO_C" >&6
28405 if test "${ol_cv_db_db_45+set}" = set; then
28406   echo $ECHO_N "(cached) $ECHO_C" >&6
28407 else
28408
28409         ol_DB_LIB=-ldb-45
28410         ol_LIBS=$LIBS
28411         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28412
28413         cat >conftest.$ac_ext <<_ACEOF
28414 /* confdefs.h.  */
28415 _ACEOF
28416 cat confdefs.h >>conftest.$ac_ext
28417 cat >>conftest.$ac_ext <<_ACEOF
28418 /* end confdefs.h.  */
28419
28420 #ifdef HAVE_DB_185_H
28421 # include <db_185.h>
28422 #else
28423 # include <db.h>
28424 #endif
28425
28426 #ifndef DB_VERSION_MAJOR
28427 # define DB_VERSION_MAJOR 1
28428 #endif
28429
28430 #ifndef NULL
28431 #define NULL ((void*)0)
28432 #endif
28433
28434 int
28435 main ()
28436 {
28437
28438 #if DB_VERSION_MAJOR > 1
28439         {
28440                 char *version;
28441                 int major, minor, patch;
28442
28443                 version = db_version( &major, &minor, &patch );
28444
28445                 if( major != DB_VERSION_MAJOR ||
28446                         minor < DB_VERSION_MINOR )
28447                 {
28448                         printf("Berkeley DB version mismatch\n"
28449                                 "\theader: %s\n\tlibrary: %s\n",
28450                                 DB_VERSION_STRING, version);
28451                         return 1;
28452                 }
28453         }
28454 #endif
28455
28456 #if DB_VERSION_MAJOR > 2
28457         db_env_create( NULL, 0 );
28458 #elif DB_VERSION_MAJOR > 1
28459         db_appexit( NULL );
28460 #else
28461         (void) dbopen( NULL, 0, 0, 0, NULL);
28462 #endif
28463
28464   ;
28465   return 0;
28466 }
28467 _ACEOF
28468 rm -f conftest.$ac_objext conftest$ac_exeext
28469 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28470   (eval $ac_link) 2>conftest.er1
28471   ac_status=$?
28472   grep -v '^ *+' conftest.er1 >conftest.err
28473   rm -f conftest.er1
28474   cat conftest.err >&5
28475   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28476   (exit $ac_status); } &&
28477          { ac_try='test -z "$ac_c_werror_flag"
28478                          || test ! -s conftest.err'
28479   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28480   (eval $ac_try) 2>&5
28481   ac_status=$?
28482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28483   (exit $ac_status); }; } &&
28484          { ac_try='test -s conftest$ac_exeext'
28485   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28486   (eval $ac_try) 2>&5
28487   ac_status=$?
28488   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28489   (exit $ac_status); }; }; then
28490   ol_cv_db_db_45=yes
28491 else
28492   echo "$as_me: failed program was:" >&5
28493 sed 's/^/| /' conftest.$ac_ext >&5
28494
28495 ol_cv_db_db_45=no
28496 fi
28497 rm -f conftest.err conftest.$ac_objext \
28498       conftest$ac_exeext conftest.$ac_ext
28499
28500         LIBS="$ol_LIBS"
28501
28502 fi
28503 echo "$as_me:$LINENO: result: $ol_cv_db_db_45" >&5
28504 echo "${ECHO_T}$ol_cv_db_db_45" >&6
28505
28506         if test $ol_cv_db_db_45 = yes ; then
28507                 ol_cv_lib_db=-ldb-45
28508         fi
28509 fi
28510
28511                 if test $ol_cv_lib_db = no ; then
28512         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-5)" >&5
28513 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-5)... $ECHO_C" >&6
28514 if test "${ol_cv_db_db_4_5+set}" = set; then
28515   echo $ECHO_N "(cached) $ECHO_C" >&6
28516 else
28517
28518         ol_DB_LIB=-ldb-4-5
28519         ol_LIBS=$LIBS
28520         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28521
28522         cat >conftest.$ac_ext <<_ACEOF
28523 /* confdefs.h.  */
28524 _ACEOF
28525 cat confdefs.h >>conftest.$ac_ext
28526 cat >>conftest.$ac_ext <<_ACEOF
28527 /* end confdefs.h.  */
28528
28529 #ifdef HAVE_DB_185_H
28530 # include <db_185.h>
28531 #else
28532 # include <db.h>
28533 #endif
28534
28535 #ifndef DB_VERSION_MAJOR
28536 # define DB_VERSION_MAJOR 1
28537 #endif
28538
28539 #ifndef NULL
28540 #define NULL ((void*)0)
28541 #endif
28542
28543 int
28544 main ()
28545 {
28546
28547 #if DB_VERSION_MAJOR > 1
28548         {
28549                 char *version;
28550                 int major, minor, patch;
28551
28552                 version = db_version( &major, &minor, &patch );
28553
28554                 if( major != DB_VERSION_MAJOR ||
28555                         minor < DB_VERSION_MINOR )
28556                 {
28557                         printf("Berkeley DB version mismatch\n"
28558                                 "\theader: %s\n\tlibrary: %s\n",
28559                                 DB_VERSION_STRING, version);
28560                         return 1;
28561                 }
28562         }
28563 #endif
28564
28565 #if DB_VERSION_MAJOR > 2
28566         db_env_create( NULL, 0 );
28567 #elif DB_VERSION_MAJOR > 1
28568         db_appexit( NULL );
28569 #else
28570         (void) dbopen( NULL, 0, 0, 0, NULL);
28571 #endif
28572
28573   ;
28574   return 0;
28575 }
28576 _ACEOF
28577 rm -f conftest.$ac_objext conftest$ac_exeext
28578 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28579   (eval $ac_link) 2>conftest.er1
28580   ac_status=$?
28581   grep -v '^ *+' conftest.er1 >conftest.err
28582   rm -f conftest.er1
28583   cat conftest.err >&5
28584   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28585   (exit $ac_status); } &&
28586          { ac_try='test -z "$ac_c_werror_flag"
28587                          || test ! -s conftest.err'
28588   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28589   (eval $ac_try) 2>&5
28590   ac_status=$?
28591   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28592   (exit $ac_status); }; } &&
28593          { ac_try='test -s conftest$ac_exeext'
28594   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28595   (eval $ac_try) 2>&5
28596   ac_status=$?
28597   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28598   (exit $ac_status); }; }; then
28599   ol_cv_db_db_4_5=yes
28600 else
28601   echo "$as_me: failed program was:" >&5
28602 sed 's/^/| /' conftest.$ac_ext >&5
28603
28604 ol_cv_db_db_4_5=no
28605 fi
28606 rm -f conftest.err conftest.$ac_objext \
28607       conftest$ac_exeext conftest.$ac_ext
28608
28609         LIBS="$ol_LIBS"
28610
28611 fi
28612 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_5" >&5
28613 echo "${ECHO_T}$ol_cv_db_db_4_5" >&6
28614
28615         if test $ol_cv_db_db_4_5 = yes ; then
28616                 ol_cv_lib_db=-ldb-4-5
28617         fi
28618 fi
28619
28620         elif test $ol_cv_bdb_minor = 4 ; then
28621                 if test $ol_cv_lib_db = no ; then
28622         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.4)" >&5
28623 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.4)... $ECHO_C" >&6
28624 if test "${ol_cv_db_db_4_dot_4+set}" = set; then
28625   echo $ECHO_N "(cached) $ECHO_C" >&6
28626 else
28627
28628         ol_DB_LIB=-ldb-4.4
28629         ol_LIBS=$LIBS
28630         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28631
28632         cat >conftest.$ac_ext <<_ACEOF
28633 /* confdefs.h.  */
28634 _ACEOF
28635 cat confdefs.h >>conftest.$ac_ext
28636 cat >>conftest.$ac_ext <<_ACEOF
28637 /* end confdefs.h.  */
28638
28639 #ifdef HAVE_DB_185_H
28640 # include <db_185.h>
28641 #else
28642 # include <db.h>
28643 #endif
28644
28645 #ifndef DB_VERSION_MAJOR
28646 # define DB_VERSION_MAJOR 1
28647 #endif
28648
28649 #ifndef NULL
28650 #define NULL ((void*)0)
28651 #endif
28652
28653 int
28654 main ()
28655 {
28656
28657 #if DB_VERSION_MAJOR > 1
28658         {
28659                 char *version;
28660                 int major, minor, patch;
28661
28662                 version = db_version( &major, &minor, &patch );
28663
28664                 if( major != DB_VERSION_MAJOR ||
28665                         minor < DB_VERSION_MINOR )
28666                 {
28667                         printf("Berkeley DB version mismatch\n"
28668                                 "\theader: %s\n\tlibrary: %s\n",
28669                                 DB_VERSION_STRING, version);
28670                         return 1;
28671                 }
28672         }
28673 #endif
28674
28675 #if DB_VERSION_MAJOR > 2
28676         db_env_create( NULL, 0 );
28677 #elif DB_VERSION_MAJOR > 1
28678         db_appexit( NULL );
28679 #else
28680         (void) dbopen( NULL, 0, 0, 0, NULL);
28681 #endif
28682
28683   ;
28684   return 0;
28685 }
28686 _ACEOF
28687 rm -f conftest.$ac_objext conftest$ac_exeext
28688 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28689   (eval $ac_link) 2>conftest.er1
28690   ac_status=$?
28691   grep -v '^ *+' conftest.er1 >conftest.err
28692   rm -f conftest.er1
28693   cat conftest.err >&5
28694   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28695   (exit $ac_status); } &&
28696          { ac_try='test -z "$ac_c_werror_flag"
28697                          || test ! -s conftest.err'
28698   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28699   (eval $ac_try) 2>&5
28700   ac_status=$?
28701   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28702   (exit $ac_status); }; } &&
28703          { ac_try='test -s conftest$ac_exeext'
28704   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28705   (eval $ac_try) 2>&5
28706   ac_status=$?
28707   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28708   (exit $ac_status); }; }; then
28709   ol_cv_db_db_4_dot_4=yes
28710 else
28711   echo "$as_me: failed program was:" >&5
28712 sed 's/^/| /' conftest.$ac_ext >&5
28713
28714 ol_cv_db_db_4_dot_4=no
28715 fi
28716 rm -f conftest.err conftest.$ac_objext \
28717       conftest$ac_exeext conftest.$ac_ext
28718
28719         LIBS="$ol_LIBS"
28720
28721 fi
28722 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_4" >&5
28723 echo "${ECHO_T}$ol_cv_db_db_4_dot_4" >&6
28724
28725         if test $ol_cv_db_db_4_dot_4 = yes ; then
28726                 ol_cv_lib_db=-ldb-4.4
28727         fi
28728 fi
28729
28730                 if test $ol_cv_lib_db = no ; then
28731         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb44)" >&5
28732 echo $ECHO_N "checking for Berkeley DB link (-ldb44)... $ECHO_C" >&6
28733 if test "${ol_cv_db_db44+set}" = set; then
28734   echo $ECHO_N "(cached) $ECHO_C" >&6
28735 else
28736
28737         ol_DB_LIB=-ldb44
28738         ol_LIBS=$LIBS
28739         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28740
28741         cat >conftest.$ac_ext <<_ACEOF
28742 /* confdefs.h.  */
28743 _ACEOF
28744 cat confdefs.h >>conftest.$ac_ext
28745 cat >>conftest.$ac_ext <<_ACEOF
28746 /* end confdefs.h.  */
28747
28748 #ifdef HAVE_DB_185_H
28749 # include <db_185.h>
28750 #else
28751 # include <db.h>
28752 #endif
28753
28754 #ifndef DB_VERSION_MAJOR
28755 # define DB_VERSION_MAJOR 1
28756 #endif
28757
28758 #ifndef NULL
28759 #define NULL ((void*)0)
28760 #endif
28761
28762 int
28763 main ()
28764 {
28765
28766 #if DB_VERSION_MAJOR > 1
28767         {
28768                 char *version;
28769                 int major, minor, patch;
28770
28771                 version = db_version( &major, &minor, &patch );
28772
28773                 if( major != DB_VERSION_MAJOR ||
28774                         minor < DB_VERSION_MINOR )
28775                 {
28776                         printf("Berkeley DB version mismatch\n"
28777                                 "\theader: %s\n\tlibrary: %s\n",
28778                                 DB_VERSION_STRING, version);
28779                         return 1;
28780                 }
28781         }
28782 #endif
28783
28784 #if DB_VERSION_MAJOR > 2
28785         db_env_create( NULL, 0 );
28786 #elif DB_VERSION_MAJOR > 1
28787         db_appexit( NULL );
28788 #else
28789         (void) dbopen( NULL, 0, 0, 0, NULL);
28790 #endif
28791
28792   ;
28793   return 0;
28794 }
28795 _ACEOF
28796 rm -f conftest.$ac_objext conftest$ac_exeext
28797 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28798   (eval $ac_link) 2>conftest.er1
28799   ac_status=$?
28800   grep -v '^ *+' conftest.er1 >conftest.err
28801   rm -f conftest.er1
28802   cat conftest.err >&5
28803   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28804   (exit $ac_status); } &&
28805          { ac_try='test -z "$ac_c_werror_flag"
28806                          || test ! -s conftest.err'
28807   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28808   (eval $ac_try) 2>&5
28809   ac_status=$?
28810   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28811   (exit $ac_status); }; } &&
28812          { ac_try='test -s conftest$ac_exeext'
28813   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28814   (eval $ac_try) 2>&5
28815   ac_status=$?
28816   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28817   (exit $ac_status); }; }; then
28818   ol_cv_db_db44=yes
28819 else
28820   echo "$as_me: failed program was:" >&5
28821 sed 's/^/| /' conftest.$ac_ext >&5
28822
28823 ol_cv_db_db44=no
28824 fi
28825 rm -f conftest.err conftest.$ac_objext \
28826       conftest$ac_exeext conftest.$ac_ext
28827
28828         LIBS="$ol_LIBS"
28829
28830 fi
28831 echo "$as_me:$LINENO: result: $ol_cv_db_db44" >&5
28832 echo "${ECHO_T}$ol_cv_db_db44" >&6
28833
28834         if test $ol_cv_db_db44 = yes ; then
28835                 ol_cv_lib_db=-ldb44
28836         fi
28837 fi
28838
28839                 if test $ol_cv_lib_db = no ; then
28840         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-44)" >&5
28841 echo $ECHO_N "checking for Berkeley DB link (-ldb-44)... $ECHO_C" >&6
28842 if test "${ol_cv_db_db_44+set}" = set; then
28843   echo $ECHO_N "(cached) $ECHO_C" >&6
28844 else
28845
28846         ol_DB_LIB=-ldb-44
28847         ol_LIBS=$LIBS
28848         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28849
28850         cat >conftest.$ac_ext <<_ACEOF
28851 /* confdefs.h.  */
28852 _ACEOF
28853 cat confdefs.h >>conftest.$ac_ext
28854 cat >>conftest.$ac_ext <<_ACEOF
28855 /* end confdefs.h.  */
28856
28857 #ifdef HAVE_DB_185_H
28858 # include <db_185.h>
28859 #else
28860 # include <db.h>
28861 #endif
28862
28863 #ifndef DB_VERSION_MAJOR
28864 # define DB_VERSION_MAJOR 1
28865 #endif
28866
28867 #ifndef NULL
28868 #define NULL ((void*)0)
28869 #endif
28870
28871 int
28872 main ()
28873 {
28874
28875 #if DB_VERSION_MAJOR > 1
28876         {
28877                 char *version;
28878                 int major, minor, patch;
28879
28880                 version = db_version( &major, &minor, &patch );
28881
28882                 if( major != DB_VERSION_MAJOR ||
28883                         minor < DB_VERSION_MINOR )
28884                 {
28885                         printf("Berkeley DB version mismatch\n"
28886                                 "\theader: %s\n\tlibrary: %s\n",
28887                                 DB_VERSION_STRING, version);
28888                         return 1;
28889                 }
28890         }
28891 #endif
28892
28893 #if DB_VERSION_MAJOR > 2
28894         db_env_create( NULL, 0 );
28895 #elif DB_VERSION_MAJOR > 1
28896         db_appexit( NULL );
28897 #else
28898         (void) dbopen( NULL, 0, 0, 0, NULL);
28899 #endif
28900
28901   ;
28902   return 0;
28903 }
28904 _ACEOF
28905 rm -f conftest.$ac_objext conftest$ac_exeext
28906 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28907   (eval $ac_link) 2>conftest.er1
28908   ac_status=$?
28909   grep -v '^ *+' conftest.er1 >conftest.err
28910   rm -f conftest.er1
28911   cat conftest.err >&5
28912   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28913   (exit $ac_status); } &&
28914          { ac_try='test -z "$ac_c_werror_flag"
28915                          || test ! -s conftest.err'
28916   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28917   (eval $ac_try) 2>&5
28918   ac_status=$?
28919   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28920   (exit $ac_status); }; } &&
28921          { ac_try='test -s conftest$ac_exeext'
28922   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28923   (eval $ac_try) 2>&5
28924   ac_status=$?
28925   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28926   (exit $ac_status); }; }; then
28927   ol_cv_db_db_44=yes
28928 else
28929   echo "$as_me: failed program was:" >&5
28930 sed 's/^/| /' conftest.$ac_ext >&5
28931
28932 ol_cv_db_db_44=no
28933 fi
28934 rm -f conftest.err conftest.$ac_objext \
28935       conftest$ac_exeext conftest.$ac_ext
28936
28937         LIBS="$ol_LIBS"
28938
28939 fi
28940 echo "$as_me:$LINENO: result: $ol_cv_db_db_44" >&5
28941 echo "${ECHO_T}$ol_cv_db_db_44" >&6
28942
28943         if test $ol_cv_db_db_44 = yes ; then
28944                 ol_cv_lib_db=-ldb-44
28945         fi
28946 fi
28947
28948                 if test $ol_cv_lib_db = no ; then
28949         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-4)" >&5
28950 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-4)... $ECHO_C" >&6
28951 if test "${ol_cv_db_db_4_4+set}" = set; then
28952   echo $ECHO_N "(cached) $ECHO_C" >&6
28953 else
28954
28955         ol_DB_LIB=-ldb-4-4
28956         ol_LIBS=$LIBS
28957         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28958
28959         cat >conftest.$ac_ext <<_ACEOF
28960 /* confdefs.h.  */
28961 _ACEOF
28962 cat confdefs.h >>conftest.$ac_ext
28963 cat >>conftest.$ac_ext <<_ACEOF
28964 /* end confdefs.h.  */
28965
28966 #ifdef HAVE_DB_185_H
28967 # include <db_185.h>
28968 #else
28969 # include <db.h>
28970 #endif
28971
28972 #ifndef DB_VERSION_MAJOR
28973 # define DB_VERSION_MAJOR 1
28974 #endif
28975
28976 #ifndef NULL
28977 #define NULL ((void*)0)
28978 #endif
28979
28980 int
28981 main ()
28982 {
28983
28984 #if DB_VERSION_MAJOR > 1
28985         {
28986                 char *version;
28987                 int major, minor, patch;
28988
28989                 version = db_version( &major, &minor, &patch );
28990
28991                 if( major != DB_VERSION_MAJOR ||
28992                         minor < DB_VERSION_MINOR )
28993                 {
28994                         printf("Berkeley DB version mismatch\n"
28995                                 "\theader: %s\n\tlibrary: %s\n",
28996                                 DB_VERSION_STRING, version);
28997                         return 1;
28998                 }
28999         }
29000 #endif
29001
29002 #if DB_VERSION_MAJOR > 2
29003         db_env_create( NULL, 0 );
29004 #elif DB_VERSION_MAJOR > 1
29005         db_appexit( NULL );
29006 #else
29007         (void) dbopen( NULL, 0, 0, 0, NULL);
29008 #endif
29009
29010   ;
29011   return 0;
29012 }
29013 _ACEOF
29014 rm -f conftest.$ac_objext conftest$ac_exeext
29015 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29016   (eval $ac_link) 2>conftest.er1
29017   ac_status=$?
29018   grep -v '^ *+' conftest.er1 >conftest.err
29019   rm -f conftest.er1
29020   cat conftest.err >&5
29021   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29022   (exit $ac_status); } &&
29023          { ac_try='test -z "$ac_c_werror_flag"
29024                          || test ! -s conftest.err'
29025   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29026   (eval $ac_try) 2>&5
29027   ac_status=$?
29028   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29029   (exit $ac_status); }; } &&
29030          { ac_try='test -s conftest$ac_exeext'
29031   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29032   (eval $ac_try) 2>&5
29033   ac_status=$?
29034   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29035   (exit $ac_status); }; }; then
29036   ol_cv_db_db_4_4=yes
29037 else
29038   echo "$as_me: failed program was:" >&5
29039 sed 's/^/| /' conftest.$ac_ext >&5
29040
29041 ol_cv_db_db_4_4=no
29042 fi
29043 rm -f conftest.err conftest.$ac_objext \
29044       conftest$ac_exeext conftest.$ac_ext
29045
29046         LIBS="$ol_LIBS"
29047
29048 fi
29049 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_4" >&5
29050 echo "${ECHO_T}$ol_cv_db_db_4_4" >&6
29051
29052         if test $ol_cv_db_db_4_4 = yes ; then
29053                 ol_cv_lib_db=-ldb-4-4
29054         fi
29055 fi
29056
29057         elif test $ol_cv_bdb_minor = 3 ; then
29058                 if test $ol_cv_lib_db = no ; then
29059         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.3)" >&5
29060 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.3)... $ECHO_C" >&6
29061 if test "${ol_cv_db_db_4_dot_3+set}" = set; then
29062   echo $ECHO_N "(cached) $ECHO_C" >&6
29063 else
29064
29065         ol_DB_LIB=-ldb-4.3
29066         ol_LIBS=$LIBS
29067         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29068
29069         cat >conftest.$ac_ext <<_ACEOF
29070 /* confdefs.h.  */
29071 _ACEOF
29072 cat confdefs.h >>conftest.$ac_ext
29073 cat >>conftest.$ac_ext <<_ACEOF
29074 /* end confdefs.h.  */
29075
29076 #ifdef HAVE_DB_185_H
29077 # include <db_185.h>
29078 #else
29079 # include <db.h>
29080 #endif
29081
29082 #ifndef DB_VERSION_MAJOR
29083 # define DB_VERSION_MAJOR 1
29084 #endif
29085
29086 #ifndef NULL
29087 #define NULL ((void*)0)
29088 #endif
29089
29090 int
29091 main ()
29092 {
29093
29094 #if DB_VERSION_MAJOR > 1
29095         {
29096                 char *version;
29097                 int major, minor, patch;
29098
29099                 version = db_version( &major, &minor, &patch );
29100
29101                 if( major != DB_VERSION_MAJOR ||
29102                         minor < DB_VERSION_MINOR )
29103                 {
29104                         printf("Berkeley DB version mismatch\n"
29105                                 "\theader: %s\n\tlibrary: %s\n",
29106                                 DB_VERSION_STRING, version);
29107                         return 1;
29108                 }
29109         }
29110 #endif
29111
29112 #if DB_VERSION_MAJOR > 2
29113         db_env_create( NULL, 0 );
29114 #elif DB_VERSION_MAJOR > 1
29115         db_appexit( NULL );
29116 #else
29117         (void) dbopen( NULL, 0, 0, 0, NULL);
29118 #endif
29119
29120   ;
29121   return 0;
29122 }
29123 _ACEOF
29124 rm -f conftest.$ac_objext conftest$ac_exeext
29125 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29126   (eval $ac_link) 2>conftest.er1
29127   ac_status=$?
29128   grep -v '^ *+' conftest.er1 >conftest.err
29129   rm -f conftest.er1
29130   cat conftest.err >&5
29131   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29132   (exit $ac_status); } &&
29133          { ac_try='test -z "$ac_c_werror_flag"
29134                          || test ! -s conftest.err'
29135   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29136   (eval $ac_try) 2>&5
29137   ac_status=$?
29138   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29139   (exit $ac_status); }; } &&
29140          { ac_try='test -s conftest$ac_exeext'
29141   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29142   (eval $ac_try) 2>&5
29143   ac_status=$?
29144   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29145   (exit $ac_status); }; }; then
29146   ol_cv_db_db_4_dot_3=yes
29147 else
29148   echo "$as_me: failed program was:" >&5
29149 sed 's/^/| /' conftest.$ac_ext >&5
29150
29151 ol_cv_db_db_4_dot_3=no
29152 fi
29153 rm -f conftest.err conftest.$ac_objext \
29154       conftest$ac_exeext conftest.$ac_ext
29155
29156         LIBS="$ol_LIBS"
29157
29158 fi
29159 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_3" >&5
29160 echo "${ECHO_T}$ol_cv_db_db_4_dot_3" >&6
29161
29162         if test $ol_cv_db_db_4_dot_3 = yes ; then
29163                 ol_cv_lib_db=-ldb-4.3
29164         fi
29165 fi
29166
29167                 if test $ol_cv_lib_db = no ; then
29168         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb43)" >&5
29169 echo $ECHO_N "checking for Berkeley DB link (-ldb43)... $ECHO_C" >&6
29170 if test "${ol_cv_db_db43+set}" = set; then
29171   echo $ECHO_N "(cached) $ECHO_C" >&6
29172 else
29173
29174         ol_DB_LIB=-ldb43
29175         ol_LIBS=$LIBS
29176         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29177
29178         cat >conftest.$ac_ext <<_ACEOF
29179 /* confdefs.h.  */
29180 _ACEOF
29181 cat confdefs.h >>conftest.$ac_ext
29182 cat >>conftest.$ac_ext <<_ACEOF
29183 /* end confdefs.h.  */
29184
29185 #ifdef HAVE_DB_185_H
29186 # include <db_185.h>
29187 #else
29188 # include <db.h>
29189 #endif
29190
29191 #ifndef DB_VERSION_MAJOR
29192 # define DB_VERSION_MAJOR 1
29193 #endif
29194
29195 #ifndef NULL
29196 #define NULL ((void*)0)
29197 #endif
29198
29199 int
29200 main ()
29201 {
29202
29203 #if DB_VERSION_MAJOR > 1
29204         {
29205                 char *version;
29206                 int major, minor, patch;
29207
29208                 version = db_version( &major, &minor, &patch );
29209
29210                 if( major != DB_VERSION_MAJOR ||
29211                         minor < DB_VERSION_MINOR )
29212                 {
29213                         printf("Berkeley DB version mismatch\n"
29214                                 "\theader: %s\n\tlibrary: %s\n",
29215                                 DB_VERSION_STRING, version);
29216                         return 1;
29217                 }
29218         }
29219 #endif
29220
29221 #if DB_VERSION_MAJOR > 2
29222         db_env_create( NULL, 0 );
29223 #elif DB_VERSION_MAJOR > 1
29224         db_appexit( NULL );
29225 #else
29226         (void) dbopen( NULL, 0, 0, 0, NULL);
29227 #endif
29228
29229   ;
29230   return 0;
29231 }
29232 _ACEOF
29233 rm -f conftest.$ac_objext conftest$ac_exeext
29234 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29235   (eval $ac_link) 2>conftest.er1
29236   ac_status=$?
29237   grep -v '^ *+' conftest.er1 >conftest.err
29238   rm -f conftest.er1
29239   cat conftest.err >&5
29240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29241   (exit $ac_status); } &&
29242          { ac_try='test -z "$ac_c_werror_flag"
29243                          || test ! -s conftest.err'
29244   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29245   (eval $ac_try) 2>&5
29246   ac_status=$?
29247   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29248   (exit $ac_status); }; } &&
29249          { ac_try='test -s conftest$ac_exeext'
29250   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29251   (eval $ac_try) 2>&5
29252   ac_status=$?
29253   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29254   (exit $ac_status); }; }; then
29255   ol_cv_db_db43=yes
29256 else
29257   echo "$as_me: failed program was:" >&5
29258 sed 's/^/| /' conftest.$ac_ext >&5
29259
29260 ol_cv_db_db43=no
29261 fi
29262 rm -f conftest.err conftest.$ac_objext \
29263       conftest$ac_exeext conftest.$ac_ext
29264
29265         LIBS="$ol_LIBS"
29266
29267 fi
29268 echo "$as_me:$LINENO: result: $ol_cv_db_db43" >&5
29269 echo "${ECHO_T}$ol_cv_db_db43" >&6
29270
29271         if test $ol_cv_db_db43 = yes ; then
29272                 ol_cv_lib_db=-ldb43
29273         fi
29274 fi
29275
29276                 if test $ol_cv_lib_db = no ; then
29277         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-43)" >&5
29278 echo $ECHO_N "checking for Berkeley DB link (-ldb-43)... $ECHO_C" >&6
29279 if test "${ol_cv_db_db_43+set}" = set; then
29280   echo $ECHO_N "(cached) $ECHO_C" >&6
29281 else
29282
29283         ol_DB_LIB=-ldb-43
29284         ol_LIBS=$LIBS
29285         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29286
29287         cat >conftest.$ac_ext <<_ACEOF
29288 /* confdefs.h.  */
29289 _ACEOF
29290 cat confdefs.h >>conftest.$ac_ext
29291 cat >>conftest.$ac_ext <<_ACEOF
29292 /* end confdefs.h.  */
29293
29294 #ifdef HAVE_DB_185_H
29295 # include <db_185.h>
29296 #else
29297 # include <db.h>
29298 #endif
29299
29300 #ifndef DB_VERSION_MAJOR
29301 # define DB_VERSION_MAJOR 1
29302 #endif
29303
29304 #ifndef NULL
29305 #define NULL ((void*)0)
29306 #endif
29307
29308 int
29309 main ()
29310 {
29311
29312 #if DB_VERSION_MAJOR > 1
29313         {
29314                 char *version;
29315                 int major, minor, patch;
29316
29317                 version = db_version( &major, &minor, &patch );
29318
29319                 if( major != DB_VERSION_MAJOR ||
29320                         minor < DB_VERSION_MINOR )
29321                 {
29322                         printf("Berkeley DB version mismatch\n"
29323                                 "\theader: %s\n\tlibrary: %s\n",
29324                                 DB_VERSION_STRING, version);
29325                         return 1;
29326                 }
29327         }
29328 #endif
29329
29330 #if DB_VERSION_MAJOR > 2
29331         db_env_create( NULL, 0 );
29332 #elif DB_VERSION_MAJOR > 1
29333         db_appexit( NULL );
29334 #else
29335         (void) dbopen( NULL, 0, 0, 0, NULL);
29336 #endif
29337
29338   ;
29339   return 0;
29340 }
29341 _ACEOF
29342 rm -f conftest.$ac_objext conftest$ac_exeext
29343 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29344   (eval $ac_link) 2>conftest.er1
29345   ac_status=$?
29346   grep -v '^ *+' conftest.er1 >conftest.err
29347   rm -f conftest.er1
29348   cat conftest.err >&5
29349   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29350   (exit $ac_status); } &&
29351          { ac_try='test -z "$ac_c_werror_flag"
29352                          || test ! -s conftest.err'
29353   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29354   (eval $ac_try) 2>&5
29355   ac_status=$?
29356   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29357   (exit $ac_status); }; } &&
29358          { ac_try='test -s conftest$ac_exeext'
29359   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29360   (eval $ac_try) 2>&5
29361   ac_status=$?
29362   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29363   (exit $ac_status); }; }; then
29364   ol_cv_db_db_43=yes
29365 else
29366   echo "$as_me: failed program was:" >&5
29367 sed 's/^/| /' conftest.$ac_ext >&5
29368
29369 ol_cv_db_db_43=no
29370 fi
29371 rm -f conftest.err conftest.$ac_objext \
29372       conftest$ac_exeext conftest.$ac_ext
29373
29374         LIBS="$ol_LIBS"
29375
29376 fi
29377 echo "$as_me:$LINENO: result: $ol_cv_db_db_43" >&5
29378 echo "${ECHO_T}$ol_cv_db_db_43" >&6
29379
29380         if test $ol_cv_db_db_43 = yes ; then
29381                 ol_cv_lib_db=-ldb-43
29382         fi
29383 fi
29384
29385                 if test $ol_cv_lib_db = no ; then
29386         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-3)" >&5
29387 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-3)... $ECHO_C" >&6
29388 if test "${ol_cv_db_db_4_3+set}" = set; then
29389   echo $ECHO_N "(cached) $ECHO_C" >&6
29390 else
29391
29392         ol_DB_LIB=-ldb-4-3
29393         ol_LIBS=$LIBS
29394         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29395
29396         cat >conftest.$ac_ext <<_ACEOF
29397 /* confdefs.h.  */
29398 _ACEOF
29399 cat confdefs.h >>conftest.$ac_ext
29400 cat >>conftest.$ac_ext <<_ACEOF
29401 /* end confdefs.h.  */
29402
29403 #ifdef HAVE_DB_185_H
29404 # include <db_185.h>
29405 #else
29406 # include <db.h>
29407 #endif
29408
29409 #ifndef DB_VERSION_MAJOR
29410 # define DB_VERSION_MAJOR 1
29411 #endif
29412
29413 #ifndef NULL
29414 #define NULL ((void*)0)
29415 #endif
29416
29417 int
29418 main ()
29419 {
29420
29421 #if DB_VERSION_MAJOR > 1
29422         {
29423                 char *version;
29424                 int major, minor, patch;
29425
29426                 version = db_version( &major, &minor, &patch );
29427
29428                 if( major != DB_VERSION_MAJOR ||
29429                         minor < DB_VERSION_MINOR )
29430                 {
29431                         printf("Berkeley DB version mismatch\n"
29432                                 "\theader: %s\n\tlibrary: %s\n",
29433                                 DB_VERSION_STRING, version);
29434                         return 1;
29435                 }
29436         }
29437 #endif
29438
29439 #if DB_VERSION_MAJOR > 2
29440         db_env_create( NULL, 0 );
29441 #elif DB_VERSION_MAJOR > 1
29442         db_appexit( NULL );
29443 #else
29444         (void) dbopen( NULL, 0, 0, 0, NULL);
29445 #endif
29446
29447   ;
29448   return 0;
29449 }
29450 _ACEOF
29451 rm -f conftest.$ac_objext conftest$ac_exeext
29452 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29453   (eval $ac_link) 2>conftest.er1
29454   ac_status=$?
29455   grep -v '^ *+' conftest.er1 >conftest.err
29456   rm -f conftest.er1
29457   cat conftest.err >&5
29458   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29459   (exit $ac_status); } &&
29460          { ac_try='test -z "$ac_c_werror_flag"
29461                          || test ! -s conftest.err'
29462   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29463   (eval $ac_try) 2>&5
29464   ac_status=$?
29465   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29466   (exit $ac_status); }; } &&
29467          { ac_try='test -s conftest$ac_exeext'
29468   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29469   (eval $ac_try) 2>&5
29470   ac_status=$?
29471   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29472   (exit $ac_status); }; }; then
29473   ol_cv_db_db_4_3=yes
29474 else
29475   echo "$as_me: failed program was:" >&5
29476 sed 's/^/| /' conftest.$ac_ext >&5
29477
29478 ol_cv_db_db_4_3=no
29479 fi
29480 rm -f conftest.err conftest.$ac_objext \
29481       conftest$ac_exeext conftest.$ac_ext
29482
29483         LIBS="$ol_LIBS"
29484
29485 fi
29486 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_3" >&5
29487 echo "${ECHO_T}$ol_cv_db_db_4_3" >&6
29488
29489         if test $ol_cv_db_db_4_3 = yes ; then
29490                 ol_cv_lib_db=-ldb-4-3
29491         fi
29492 fi
29493
29494         elif test $ol_cv_bdb_minor = 2 ; then
29495                 if test $ol_cv_lib_db = no ; then
29496         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.2)" >&5
29497 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.2)... $ECHO_C" >&6
29498 if test "${ol_cv_db_db_4_dot_2+set}" = set; then
29499   echo $ECHO_N "(cached) $ECHO_C" >&6
29500 else
29501
29502         ol_DB_LIB=-ldb-4.2
29503         ol_LIBS=$LIBS
29504         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29505
29506         cat >conftest.$ac_ext <<_ACEOF
29507 /* confdefs.h.  */
29508 _ACEOF
29509 cat confdefs.h >>conftest.$ac_ext
29510 cat >>conftest.$ac_ext <<_ACEOF
29511 /* end confdefs.h.  */
29512
29513 #ifdef HAVE_DB_185_H
29514 # include <db_185.h>
29515 #else
29516 # include <db.h>
29517 #endif
29518
29519 #ifndef DB_VERSION_MAJOR
29520 # define DB_VERSION_MAJOR 1
29521 #endif
29522
29523 #ifndef NULL
29524 #define NULL ((void*)0)
29525 #endif
29526
29527 int
29528 main ()
29529 {
29530
29531 #if DB_VERSION_MAJOR > 1
29532         {
29533                 char *version;
29534                 int major, minor, patch;
29535
29536                 version = db_version( &major, &minor, &patch );
29537
29538                 if( major != DB_VERSION_MAJOR ||
29539                         minor < DB_VERSION_MINOR )
29540                 {
29541                         printf("Berkeley DB version mismatch\n"
29542                                 "\theader: %s\n\tlibrary: %s\n",
29543                                 DB_VERSION_STRING, version);
29544                         return 1;
29545                 }
29546         }
29547 #endif
29548
29549 #if DB_VERSION_MAJOR > 2
29550         db_env_create( NULL, 0 );
29551 #elif DB_VERSION_MAJOR > 1
29552         db_appexit( NULL );
29553 #else
29554         (void) dbopen( NULL, 0, 0, 0, NULL);
29555 #endif
29556
29557   ;
29558   return 0;
29559 }
29560 _ACEOF
29561 rm -f conftest.$ac_objext conftest$ac_exeext
29562 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29563   (eval $ac_link) 2>conftest.er1
29564   ac_status=$?
29565   grep -v '^ *+' conftest.er1 >conftest.err
29566   rm -f conftest.er1
29567   cat conftest.err >&5
29568   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29569   (exit $ac_status); } &&
29570          { ac_try='test -z "$ac_c_werror_flag"
29571                          || test ! -s conftest.err'
29572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29573   (eval $ac_try) 2>&5
29574   ac_status=$?
29575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29576   (exit $ac_status); }; } &&
29577          { ac_try='test -s conftest$ac_exeext'
29578   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29579   (eval $ac_try) 2>&5
29580   ac_status=$?
29581   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29582   (exit $ac_status); }; }; then
29583   ol_cv_db_db_4_dot_2=yes
29584 else
29585   echo "$as_me: failed program was:" >&5
29586 sed 's/^/| /' conftest.$ac_ext >&5
29587
29588 ol_cv_db_db_4_dot_2=no
29589 fi
29590 rm -f conftest.err conftest.$ac_objext \
29591       conftest$ac_exeext conftest.$ac_ext
29592
29593         LIBS="$ol_LIBS"
29594
29595 fi
29596 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_2" >&5
29597 echo "${ECHO_T}$ol_cv_db_db_4_dot_2" >&6
29598
29599         if test $ol_cv_db_db_4_dot_2 = yes ; then
29600                 ol_cv_lib_db=-ldb-4.2
29601         fi
29602 fi
29603
29604                 if test $ol_cv_lib_db = no ; then
29605         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb42)" >&5
29606 echo $ECHO_N "checking for Berkeley DB link (-ldb42)... $ECHO_C" >&6
29607 if test "${ol_cv_db_db42+set}" = set; then
29608   echo $ECHO_N "(cached) $ECHO_C" >&6
29609 else
29610
29611         ol_DB_LIB=-ldb42
29612         ol_LIBS=$LIBS
29613         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29614
29615         cat >conftest.$ac_ext <<_ACEOF
29616 /* confdefs.h.  */
29617 _ACEOF
29618 cat confdefs.h >>conftest.$ac_ext
29619 cat >>conftest.$ac_ext <<_ACEOF
29620 /* end confdefs.h.  */
29621
29622 #ifdef HAVE_DB_185_H
29623 # include <db_185.h>
29624 #else
29625 # include <db.h>
29626 #endif
29627
29628 #ifndef DB_VERSION_MAJOR
29629 # define DB_VERSION_MAJOR 1
29630 #endif
29631
29632 #ifndef NULL
29633 #define NULL ((void*)0)
29634 #endif
29635
29636 int
29637 main ()
29638 {
29639
29640 #if DB_VERSION_MAJOR > 1
29641         {
29642                 char *version;
29643                 int major, minor, patch;
29644
29645                 version = db_version( &major, &minor, &patch );
29646
29647                 if( major != DB_VERSION_MAJOR ||
29648                         minor < DB_VERSION_MINOR )
29649                 {
29650                         printf("Berkeley DB version mismatch\n"
29651                                 "\theader: %s\n\tlibrary: %s\n",
29652                                 DB_VERSION_STRING, version);
29653                         return 1;
29654                 }
29655         }
29656 #endif
29657
29658 #if DB_VERSION_MAJOR > 2
29659         db_env_create( NULL, 0 );
29660 #elif DB_VERSION_MAJOR > 1
29661         db_appexit( NULL );
29662 #else
29663         (void) dbopen( NULL, 0, 0, 0, NULL);
29664 #endif
29665
29666   ;
29667   return 0;
29668 }
29669 _ACEOF
29670 rm -f conftest.$ac_objext conftest$ac_exeext
29671 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29672   (eval $ac_link) 2>conftest.er1
29673   ac_status=$?
29674   grep -v '^ *+' conftest.er1 >conftest.err
29675   rm -f conftest.er1
29676   cat conftest.err >&5
29677   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29678   (exit $ac_status); } &&
29679          { ac_try='test -z "$ac_c_werror_flag"
29680                          || test ! -s conftest.err'
29681   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29682   (eval $ac_try) 2>&5
29683   ac_status=$?
29684   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29685   (exit $ac_status); }; } &&
29686          { ac_try='test -s conftest$ac_exeext'
29687   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29688   (eval $ac_try) 2>&5
29689   ac_status=$?
29690   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29691   (exit $ac_status); }; }; then
29692   ol_cv_db_db42=yes
29693 else
29694   echo "$as_me: failed program was:" >&5
29695 sed 's/^/| /' conftest.$ac_ext >&5
29696
29697 ol_cv_db_db42=no
29698 fi
29699 rm -f conftest.err conftest.$ac_objext \
29700       conftest$ac_exeext conftest.$ac_ext
29701
29702         LIBS="$ol_LIBS"
29703
29704 fi
29705 echo "$as_me:$LINENO: result: $ol_cv_db_db42" >&5
29706 echo "${ECHO_T}$ol_cv_db_db42" >&6
29707
29708         if test $ol_cv_db_db42 = yes ; then
29709                 ol_cv_lib_db=-ldb42
29710         fi
29711 fi
29712
29713                 if test $ol_cv_lib_db = no ; then
29714         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-42)" >&5
29715 echo $ECHO_N "checking for Berkeley DB link (-ldb-42)... $ECHO_C" >&6
29716 if test "${ol_cv_db_db_42+set}" = set; then
29717   echo $ECHO_N "(cached) $ECHO_C" >&6
29718 else
29719
29720         ol_DB_LIB=-ldb-42
29721         ol_LIBS=$LIBS
29722         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29723
29724         cat >conftest.$ac_ext <<_ACEOF
29725 /* confdefs.h.  */
29726 _ACEOF
29727 cat confdefs.h >>conftest.$ac_ext
29728 cat >>conftest.$ac_ext <<_ACEOF
29729 /* end confdefs.h.  */
29730
29731 #ifdef HAVE_DB_185_H
29732 # include <db_185.h>
29733 #else
29734 # include <db.h>
29735 #endif
29736
29737 #ifndef DB_VERSION_MAJOR
29738 # define DB_VERSION_MAJOR 1
29739 #endif
29740
29741 #ifndef NULL
29742 #define NULL ((void*)0)
29743 #endif
29744
29745 int
29746 main ()
29747 {
29748
29749 #if DB_VERSION_MAJOR > 1
29750         {
29751                 char *version;
29752                 int major, minor, patch;
29753
29754                 version = db_version( &major, &minor, &patch );
29755
29756                 if( major != DB_VERSION_MAJOR ||
29757                         minor < DB_VERSION_MINOR )
29758                 {
29759                         printf("Berkeley DB version mismatch\n"
29760                                 "\theader: %s\n\tlibrary: %s\n",
29761                                 DB_VERSION_STRING, version);
29762                         return 1;
29763                 }
29764         }
29765 #endif
29766
29767 #if DB_VERSION_MAJOR > 2
29768         db_env_create( NULL, 0 );
29769 #elif DB_VERSION_MAJOR > 1
29770         db_appexit( NULL );
29771 #else
29772         (void) dbopen( NULL, 0, 0, 0, NULL);
29773 #endif
29774
29775   ;
29776   return 0;
29777 }
29778 _ACEOF
29779 rm -f conftest.$ac_objext conftest$ac_exeext
29780 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29781   (eval $ac_link) 2>conftest.er1
29782   ac_status=$?
29783   grep -v '^ *+' conftest.er1 >conftest.err
29784   rm -f conftest.er1
29785   cat conftest.err >&5
29786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29787   (exit $ac_status); } &&
29788          { ac_try='test -z "$ac_c_werror_flag"
29789                          || test ! -s conftest.err'
29790   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29791   (eval $ac_try) 2>&5
29792   ac_status=$?
29793   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29794   (exit $ac_status); }; } &&
29795          { ac_try='test -s conftest$ac_exeext'
29796   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29797   (eval $ac_try) 2>&5
29798   ac_status=$?
29799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29800   (exit $ac_status); }; }; then
29801   ol_cv_db_db_42=yes
29802 else
29803   echo "$as_me: failed program was:" >&5
29804 sed 's/^/| /' conftest.$ac_ext >&5
29805
29806 ol_cv_db_db_42=no
29807 fi
29808 rm -f conftest.err conftest.$ac_objext \
29809       conftest$ac_exeext conftest.$ac_ext
29810
29811         LIBS="$ol_LIBS"
29812
29813 fi
29814 echo "$as_me:$LINENO: result: $ol_cv_db_db_42" >&5
29815 echo "${ECHO_T}$ol_cv_db_db_42" >&6
29816
29817         if test $ol_cv_db_db_42 = yes ; then
29818                 ol_cv_lib_db=-ldb-42
29819         fi
29820 fi
29821
29822                 if test $ol_cv_lib_db = no ; then
29823         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-2)" >&5
29824 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-2)... $ECHO_C" >&6
29825 if test "${ol_cv_db_db_4_2+set}" = set; then
29826   echo $ECHO_N "(cached) $ECHO_C" >&6
29827 else
29828
29829         ol_DB_LIB=-ldb-4-2
29830         ol_LIBS=$LIBS
29831         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29832
29833         cat >conftest.$ac_ext <<_ACEOF
29834 /* confdefs.h.  */
29835 _ACEOF
29836 cat confdefs.h >>conftest.$ac_ext
29837 cat >>conftest.$ac_ext <<_ACEOF
29838 /* end confdefs.h.  */
29839
29840 #ifdef HAVE_DB_185_H
29841 # include <db_185.h>
29842 #else
29843 # include <db.h>
29844 #endif
29845
29846 #ifndef DB_VERSION_MAJOR
29847 # define DB_VERSION_MAJOR 1
29848 #endif
29849
29850 #ifndef NULL
29851 #define NULL ((void*)0)
29852 #endif
29853
29854 int
29855 main ()
29856 {
29857
29858 #if DB_VERSION_MAJOR > 1
29859         {
29860                 char *version;
29861                 int major, minor, patch;
29862
29863                 version = db_version( &major, &minor, &patch );
29864
29865                 if( major != DB_VERSION_MAJOR ||
29866                         minor < DB_VERSION_MINOR )
29867                 {
29868                         printf("Berkeley DB version mismatch\n"
29869                                 "\theader: %s\n\tlibrary: %s\n",
29870                                 DB_VERSION_STRING, version);
29871                         return 1;
29872                 }
29873         }
29874 #endif
29875
29876 #if DB_VERSION_MAJOR > 2
29877         db_env_create( NULL, 0 );
29878 #elif DB_VERSION_MAJOR > 1
29879         db_appexit( NULL );
29880 #else
29881         (void) dbopen( NULL, 0, 0, 0, NULL);
29882 #endif
29883
29884   ;
29885   return 0;
29886 }
29887 _ACEOF
29888 rm -f conftest.$ac_objext conftest$ac_exeext
29889 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29890   (eval $ac_link) 2>conftest.er1
29891   ac_status=$?
29892   grep -v '^ *+' conftest.er1 >conftest.err
29893   rm -f conftest.er1
29894   cat conftest.err >&5
29895   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29896   (exit $ac_status); } &&
29897          { ac_try='test -z "$ac_c_werror_flag"
29898                          || test ! -s conftest.err'
29899   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29900   (eval $ac_try) 2>&5
29901   ac_status=$?
29902   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29903   (exit $ac_status); }; } &&
29904          { ac_try='test -s conftest$ac_exeext'
29905   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29906   (eval $ac_try) 2>&5
29907   ac_status=$?
29908   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29909   (exit $ac_status); }; }; then
29910   ol_cv_db_db_4_2=yes
29911 else
29912   echo "$as_me: failed program was:" >&5
29913 sed 's/^/| /' conftest.$ac_ext >&5
29914
29915 ol_cv_db_db_4_2=no
29916 fi
29917 rm -f conftest.err conftest.$ac_objext \
29918       conftest$ac_exeext conftest.$ac_ext
29919
29920         LIBS="$ol_LIBS"
29921
29922 fi
29923 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_2" >&5
29924 echo "${ECHO_T}$ol_cv_db_db_4_2" >&6
29925
29926         if test $ol_cv_db_db_4_2 = yes ; then
29927                 ol_cv_lib_db=-ldb-4-2
29928         fi
29929 fi
29930
29931         fi
29932         if test $ol_cv_lib_db = no ; then
29933         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4)" >&5
29934 echo $ECHO_N "checking for Berkeley DB link (-ldb-4)... $ECHO_C" >&6
29935 if test "${ol_cv_db_db_4+set}" = set; then
29936   echo $ECHO_N "(cached) $ECHO_C" >&6
29937 else
29938
29939         ol_DB_LIB=-ldb-4
29940         ol_LIBS=$LIBS
29941         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29942
29943         cat >conftest.$ac_ext <<_ACEOF
29944 /* confdefs.h.  */
29945 _ACEOF
29946 cat confdefs.h >>conftest.$ac_ext
29947 cat >>conftest.$ac_ext <<_ACEOF
29948 /* end confdefs.h.  */
29949
29950 #ifdef HAVE_DB_185_H
29951 # include <db_185.h>
29952 #else
29953 # include <db.h>
29954 #endif
29955
29956 #ifndef DB_VERSION_MAJOR
29957 # define DB_VERSION_MAJOR 1
29958 #endif
29959
29960 #ifndef NULL
29961 #define NULL ((void*)0)
29962 #endif
29963
29964 int
29965 main ()
29966 {
29967
29968 #if DB_VERSION_MAJOR > 1
29969         {
29970                 char *version;
29971                 int major, minor, patch;
29972
29973                 version = db_version( &major, &minor, &patch );
29974
29975                 if( major != DB_VERSION_MAJOR ||
29976                         minor < DB_VERSION_MINOR )
29977                 {
29978                         printf("Berkeley DB version mismatch\n"
29979                                 "\theader: %s\n\tlibrary: %s\n",
29980                                 DB_VERSION_STRING, version);
29981                         return 1;
29982                 }
29983         }
29984 #endif
29985
29986 #if DB_VERSION_MAJOR > 2
29987         db_env_create( NULL, 0 );
29988 #elif DB_VERSION_MAJOR > 1
29989         db_appexit( NULL );
29990 #else
29991         (void) dbopen( NULL, 0, 0, 0, NULL);
29992 #endif
29993
29994   ;
29995   return 0;
29996 }
29997 _ACEOF
29998 rm -f conftest.$ac_objext conftest$ac_exeext
29999 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30000   (eval $ac_link) 2>conftest.er1
30001   ac_status=$?
30002   grep -v '^ *+' conftest.er1 >conftest.err
30003   rm -f conftest.er1
30004   cat conftest.err >&5
30005   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30006   (exit $ac_status); } &&
30007          { ac_try='test -z "$ac_c_werror_flag"
30008                          || test ! -s conftest.err'
30009   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30010   (eval $ac_try) 2>&5
30011   ac_status=$?
30012   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30013   (exit $ac_status); }; } &&
30014          { ac_try='test -s conftest$ac_exeext'
30015   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30016   (eval $ac_try) 2>&5
30017   ac_status=$?
30018   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30019   (exit $ac_status); }; }; then
30020   ol_cv_db_db_4=yes
30021 else
30022   echo "$as_me: failed program was:" >&5
30023 sed 's/^/| /' conftest.$ac_ext >&5
30024
30025 ol_cv_db_db_4=no
30026 fi
30027 rm -f conftest.err conftest.$ac_objext \
30028       conftest$ac_exeext conftest.$ac_ext
30029
30030         LIBS="$ol_LIBS"
30031
30032 fi
30033 echo "$as_me:$LINENO: result: $ol_cv_db_db_4" >&5
30034 echo "${ECHO_T}$ol_cv_db_db_4" >&6
30035
30036         if test $ol_cv_db_db_4 = yes ; then
30037                 ol_cv_lib_db=-ldb-4
30038         fi
30039 fi
30040
30041         if test $ol_cv_lib_db = no ; then
30042         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb4)" >&5
30043 echo $ECHO_N "checking for Berkeley DB link (-ldb4)... $ECHO_C" >&6
30044 if test "${ol_cv_db_db4+set}" = set; then
30045   echo $ECHO_N "(cached) $ECHO_C" >&6
30046 else
30047
30048         ol_DB_LIB=-ldb4
30049         ol_LIBS=$LIBS
30050         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30051
30052         cat >conftest.$ac_ext <<_ACEOF
30053 /* confdefs.h.  */
30054 _ACEOF
30055 cat confdefs.h >>conftest.$ac_ext
30056 cat >>conftest.$ac_ext <<_ACEOF
30057 /* end confdefs.h.  */
30058
30059 #ifdef HAVE_DB_185_H
30060 # include <db_185.h>
30061 #else
30062 # include <db.h>
30063 #endif
30064
30065 #ifndef DB_VERSION_MAJOR
30066 # define DB_VERSION_MAJOR 1
30067 #endif
30068
30069 #ifndef NULL
30070 #define NULL ((void*)0)
30071 #endif
30072
30073 int
30074 main ()
30075 {
30076
30077 #if DB_VERSION_MAJOR > 1
30078         {
30079                 char *version;
30080                 int major, minor, patch;
30081
30082                 version = db_version( &major, &minor, &patch );
30083
30084                 if( major != DB_VERSION_MAJOR ||
30085                         minor < DB_VERSION_MINOR )
30086                 {
30087                         printf("Berkeley DB version mismatch\n"
30088                                 "\theader: %s\n\tlibrary: %s\n",
30089                                 DB_VERSION_STRING, version);
30090                         return 1;
30091                 }
30092         }
30093 #endif
30094
30095 #if DB_VERSION_MAJOR > 2
30096         db_env_create( NULL, 0 );
30097 #elif DB_VERSION_MAJOR > 1
30098         db_appexit( NULL );
30099 #else
30100         (void) dbopen( NULL, 0, 0, 0, NULL);
30101 #endif
30102
30103   ;
30104   return 0;
30105 }
30106 _ACEOF
30107 rm -f conftest.$ac_objext conftest$ac_exeext
30108 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30109   (eval $ac_link) 2>conftest.er1
30110   ac_status=$?
30111   grep -v '^ *+' conftest.er1 >conftest.err
30112   rm -f conftest.er1
30113   cat conftest.err >&5
30114   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30115   (exit $ac_status); } &&
30116          { ac_try='test -z "$ac_c_werror_flag"
30117                          || test ! -s conftest.err'
30118   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30119   (eval $ac_try) 2>&5
30120   ac_status=$?
30121   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30122   (exit $ac_status); }; } &&
30123          { ac_try='test -s conftest$ac_exeext'
30124   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30125   (eval $ac_try) 2>&5
30126   ac_status=$?
30127   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30128   (exit $ac_status); }; }; then
30129   ol_cv_db_db4=yes
30130 else
30131   echo "$as_me: failed program was:" >&5
30132 sed 's/^/| /' conftest.$ac_ext >&5
30133
30134 ol_cv_db_db4=no
30135 fi
30136 rm -f conftest.err conftest.$ac_objext \
30137       conftest$ac_exeext conftest.$ac_ext
30138
30139         LIBS="$ol_LIBS"
30140
30141 fi
30142 echo "$as_me:$LINENO: result: $ol_cv_db_db4" >&5
30143 echo "${ECHO_T}$ol_cv_db_db4" >&6
30144
30145         if test $ol_cv_db_db4 = yes ; then
30146                 ol_cv_lib_db=-ldb4
30147         fi
30148 fi
30149
30150         if test $ol_cv_lib_db = no ; then
30151         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb)" >&5
30152 echo $ECHO_N "checking for Berkeley DB link (-ldb)... $ECHO_C" >&6
30153 if test "${ol_cv_db_db+set}" = set; then
30154   echo $ECHO_N "(cached) $ECHO_C" >&6
30155 else
30156
30157         ol_DB_LIB=-ldb
30158         ol_LIBS=$LIBS
30159         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30160
30161         cat >conftest.$ac_ext <<_ACEOF
30162 /* confdefs.h.  */
30163 _ACEOF
30164 cat confdefs.h >>conftest.$ac_ext
30165 cat >>conftest.$ac_ext <<_ACEOF
30166 /* end confdefs.h.  */
30167
30168 #ifdef HAVE_DB_185_H
30169 # include <db_185.h>
30170 #else
30171 # include <db.h>
30172 #endif
30173
30174 #ifndef DB_VERSION_MAJOR
30175 # define DB_VERSION_MAJOR 1
30176 #endif
30177
30178 #ifndef NULL
30179 #define NULL ((void*)0)
30180 #endif
30181
30182 int
30183 main ()
30184 {
30185
30186 #if DB_VERSION_MAJOR > 1
30187         {
30188                 char *version;
30189                 int major, minor, patch;
30190
30191                 version = db_version( &major, &minor, &patch );
30192
30193                 if( major != DB_VERSION_MAJOR ||
30194                         minor < DB_VERSION_MINOR )
30195                 {
30196                         printf("Berkeley DB version mismatch\n"
30197                                 "\theader: %s\n\tlibrary: %s\n",
30198                                 DB_VERSION_STRING, version);
30199                         return 1;
30200                 }
30201         }
30202 #endif
30203
30204 #if DB_VERSION_MAJOR > 2
30205         db_env_create( NULL, 0 );
30206 #elif DB_VERSION_MAJOR > 1
30207         db_appexit( NULL );
30208 #else
30209         (void) dbopen( NULL, 0, 0, 0, NULL);
30210 #endif
30211
30212   ;
30213   return 0;
30214 }
30215 _ACEOF
30216 rm -f conftest.$ac_objext conftest$ac_exeext
30217 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30218   (eval $ac_link) 2>conftest.er1
30219   ac_status=$?
30220   grep -v '^ *+' conftest.er1 >conftest.err
30221   rm -f conftest.er1
30222   cat conftest.err >&5
30223   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30224   (exit $ac_status); } &&
30225          { ac_try='test -z "$ac_c_werror_flag"
30226                          || test ! -s conftest.err'
30227   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30228   (eval $ac_try) 2>&5
30229   ac_status=$?
30230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30231   (exit $ac_status); }; } &&
30232          { ac_try='test -s conftest$ac_exeext'
30233   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30234   (eval $ac_try) 2>&5
30235   ac_status=$?
30236   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30237   (exit $ac_status); }; }; then
30238   ol_cv_db_db=yes
30239 else
30240   echo "$as_me: failed program was:" >&5
30241 sed 's/^/| /' conftest.$ac_ext >&5
30242
30243 ol_cv_db_db=no
30244 fi
30245 rm -f conftest.err conftest.$ac_objext \
30246       conftest$ac_exeext conftest.$ac_ext
30247
30248         LIBS="$ol_LIBS"
30249
30250 fi
30251 echo "$as_me:$LINENO: result: $ol_cv_db_db" >&5
30252 echo "${ECHO_T}$ol_cv_db_db" >&6
30253
30254         if test $ol_cv_db_db = yes ; then
30255                 ol_cv_lib_db=-ldb
30256         fi
30257 fi
30258
30259
30260 elif test $ol_cv_bdb_major = 3 ; then
30261         if test $ol_cv_lib_db = no ; then
30262         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb3)" >&5
30263 echo $ECHO_N "checking for Berkeley DB link (-ldb3)... $ECHO_C" >&6
30264 if test "${ol_cv_db_db3+set}" = set; then
30265   echo $ECHO_N "(cached) $ECHO_C" >&6
30266 else
30267
30268         ol_DB_LIB=-ldb3
30269         ol_LIBS=$LIBS
30270         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30271
30272         cat >conftest.$ac_ext <<_ACEOF
30273 /* confdefs.h.  */
30274 _ACEOF
30275 cat confdefs.h >>conftest.$ac_ext
30276 cat >>conftest.$ac_ext <<_ACEOF
30277 /* end confdefs.h.  */
30278
30279 #ifdef HAVE_DB_185_H
30280 # include <db_185.h>
30281 #else
30282 # include <db.h>
30283 #endif
30284
30285 #ifndef DB_VERSION_MAJOR
30286 # define DB_VERSION_MAJOR 1
30287 #endif
30288
30289 #ifndef NULL
30290 #define NULL ((void*)0)
30291 #endif
30292
30293 int
30294 main ()
30295 {
30296
30297 #if DB_VERSION_MAJOR > 1
30298         {
30299                 char *version;
30300                 int major, minor, patch;
30301
30302                 version = db_version( &major, &minor, &patch );
30303
30304                 if( major != DB_VERSION_MAJOR ||
30305                         minor < DB_VERSION_MINOR )
30306                 {
30307                         printf("Berkeley DB version mismatch\n"
30308                                 "\theader: %s\n\tlibrary: %s\n",
30309                                 DB_VERSION_STRING, version);
30310                         return 1;
30311                 }
30312         }
30313 #endif
30314
30315 #if DB_VERSION_MAJOR > 2
30316         db_env_create( NULL, 0 );
30317 #elif DB_VERSION_MAJOR > 1
30318         db_appexit( NULL );
30319 #else
30320         (void) dbopen( NULL, 0, 0, 0, NULL);
30321 #endif
30322
30323   ;
30324   return 0;
30325 }
30326 _ACEOF
30327 rm -f conftest.$ac_objext conftest$ac_exeext
30328 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30329   (eval $ac_link) 2>conftest.er1
30330   ac_status=$?
30331   grep -v '^ *+' conftest.er1 >conftest.err
30332   rm -f conftest.er1
30333   cat conftest.err >&5
30334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30335   (exit $ac_status); } &&
30336          { ac_try='test -z "$ac_c_werror_flag"
30337                          || test ! -s conftest.err'
30338   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30339   (eval $ac_try) 2>&5
30340   ac_status=$?
30341   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30342   (exit $ac_status); }; } &&
30343          { ac_try='test -s conftest$ac_exeext'
30344   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30345   (eval $ac_try) 2>&5
30346   ac_status=$?
30347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30348   (exit $ac_status); }; }; then
30349   ol_cv_db_db3=yes
30350 else
30351   echo "$as_me: failed program was:" >&5
30352 sed 's/^/| /' conftest.$ac_ext >&5
30353
30354 ol_cv_db_db3=no
30355 fi
30356 rm -f conftest.err conftest.$ac_objext \
30357       conftest$ac_exeext conftest.$ac_ext
30358
30359         LIBS="$ol_LIBS"
30360
30361 fi
30362 echo "$as_me:$LINENO: result: $ol_cv_db_db3" >&5
30363 echo "${ECHO_T}$ol_cv_db_db3" >&6
30364
30365         if test $ol_cv_db_db3 = yes ; then
30366                 ol_cv_lib_db=-ldb3
30367         fi
30368 fi
30369
30370         if test $ol_cv_lib_db = no ; then
30371         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-3)" >&5
30372 echo $ECHO_N "checking for Berkeley DB link (-ldb-3)... $ECHO_C" >&6
30373 if test "${ol_cv_db_db_3+set}" = set; then
30374   echo $ECHO_N "(cached) $ECHO_C" >&6
30375 else
30376
30377         ol_DB_LIB=-ldb-3
30378         ol_LIBS=$LIBS
30379         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30380
30381         cat >conftest.$ac_ext <<_ACEOF
30382 /* confdefs.h.  */
30383 _ACEOF
30384 cat confdefs.h >>conftest.$ac_ext
30385 cat >>conftest.$ac_ext <<_ACEOF
30386 /* end confdefs.h.  */
30387
30388 #ifdef HAVE_DB_185_H
30389 # include <db_185.h>
30390 #else
30391 # include <db.h>
30392 #endif
30393
30394 #ifndef DB_VERSION_MAJOR
30395 # define DB_VERSION_MAJOR 1
30396 #endif
30397
30398 #ifndef NULL
30399 #define NULL ((void*)0)
30400 #endif
30401
30402 int
30403 main ()
30404 {
30405
30406 #if DB_VERSION_MAJOR > 1
30407         {
30408                 char *version;
30409                 int major, minor, patch;
30410
30411                 version = db_version( &major, &minor, &patch );
30412
30413                 if( major != DB_VERSION_MAJOR ||
30414                         minor < DB_VERSION_MINOR )
30415                 {
30416                         printf("Berkeley DB version mismatch\n"
30417                                 "\theader: %s\n\tlibrary: %s\n",
30418                                 DB_VERSION_STRING, version);
30419                         return 1;
30420                 }
30421         }
30422 #endif
30423
30424 #if DB_VERSION_MAJOR > 2
30425         db_env_create( NULL, 0 );
30426 #elif DB_VERSION_MAJOR > 1
30427         db_appexit( NULL );
30428 #else
30429         (void) dbopen( NULL, 0, 0, 0, NULL);
30430 #endif
30431
30432   ;
30433   return 0;
30434 }
30435 _ACEOF
30436 rm -f conftest.$ac_objext conftest$ac_exeext
30437 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30438   (eval $ac_link) 2>conftest.er1
30439   ac_status=$?
30440   grep -v '^ *+' conftest.er1 >conftest.err
30441   rm -f conftest.er1
30442   cat conftest.err >&5
30443   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30444   (exit $ac_status); } &&
30445          { ac_try='test -z "$ac_c_werror_flag"
30446                          || test ! -s conftest.err'
30447   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30448   (eval $ac_try) 2>&5
30449   ac_status=$?
30450   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30451   (exit $ac_status); }; } &&
30452          { ac_try='test -s conftest$ac_exeext'
30453   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30454   (eval $ac_try) 2>&5
30455   ac_status=$?
30456   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30457   (exit $ac_status); }; }; then
30458   ol_cv_db_db_3=yes
30459 else
30460   echo "$as_me: failed program was:" >&5
30461 sed 's/^/| /' conftest.$ac_ext >&5
30462
30463 ol_cv_db_db_3=no
30464 fi
30465 rm -f conftest.err conftest.$ac_objext \
30466       conftest$ac_exeext conftest.$ac_ext
30467
30468         LIBS="$ol_LIBS"
30469
30470 fi
30471 echo "$as_me:$LINENO: result: $ol_cv_db_db_3" >&5
30472 echo "${ECHO_T}$ol_cv_db_db_3" >&6
30473
30474         if test $ol_cv_db_db_3 = yes ; then
30475                 ol_cv_lib_db=-ldb-3
30476         fi
30477 fi
30478
30479
30480 elif test $ol_cv_bdb_major = 2 ; then
30481         if test $ol_cv_lib_db = no ; then
30482         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb2)" >&5
30483 echo $ECHO_N "checking for Berkeley DB link (-ldb2)... $ECHO_C" >&6
30484 if test "${ol_cv_db_db2+set}" = set; then
30485   echo $ECHO_N "(cached) $ECHO_C" >&6
30486 else
30487
30488         ol_DB_LIB=-ldb2
30489         ol_LIBS=$LIBS
30490         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30491
30492         cat >conftest.$ac_ext <<_ACEOF
30493 /* confdefs.h.  */
30494 _ACEOF
30495 cat confdefs.h >>conftest.$ac_ext
30496 cat >>conftest.$ac_ext <<_ACEOF
30497 /* end confdefs.h.  */
30498
30499 #ifdef HAVE_DB_185_H
30500 # include <db_185.h>
30501 #else
30502 # include <db.h>
30503 #endif
30504
30505 #ifndef DB_VERSION_MAJOR
30506 # define DB_VERSION_MAJOR 1
30507 #endif
30508
30509 #ifndef NULL
30510 #define NULL ((void*)0)
30511 #endif
30512
30513 int
30514 main ()
30515 {
30516
30517 #if DB_VERSION_MAJOR > 1
30518         {
30519                 char *version;
30520                 int major, minor, patch;
30521
30522                 version = db_version( &major, &minor, &patch );
30523
30524                 if( major != DB_VERSION_MAJOR ||
30525                         minor < DB_VERSION_MINOR )
30526                 {
30527                         printf("Berkeley DB version mismatch\n"
30528                                 "\theader: %s\n\tlibrary: %s\n",
30529                                 DB_VERSION_STRING, version);
30530                         return 1;
30531                 }
30532         }
30533 #endif
30534
30535 #if DB_VERSION_MAJOR > 2
30536         db_env_create( NULL, 0 );
30537 #elif DB_VERSION_MAJOR > 1
30538         db_appexit( NULL );
30539 #else
30540         (void) dbopen( NULL, 0, 0, 0, NULL);
30541 #endif
30542
30543   ;
30544   return 0;
30545 }
30546 _ACEOF
30547 rm -f conftest.$ac_objext conftest$ac_exeext
30548 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30549   (eval $ac_link) 2>conftest.er1
30550   ac_status=$?
30551   grep -v '^ *+' conftest.er1 >conftest.err
30552   rm -f conftest.er1
30553   cat conftest.err >&5
30554   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30555   (exit $ac_status); } &&
30556          { ac_try='test -z "$ac_c_werror_flag"
30557                          || test ! -s conftest.err'
30558   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30559   (eval $ac_try) 2>&5
30560   ac_status=$?
30561   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30562   (exit $ac_status); }; } &&
30563          { ac_try='test -s conftest$ac_exeext'
30564   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30565   (eval $ac_try) 2>&5
30566   ac_status=$?
30567   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30568   (exit $ac_status); }; }; then
30569   ol_cv_db_db2=yes
30570 else
30571   echo "$as_me: failed program was:" >&5
30572 sed 's/^/| /' conftest.$ac_ext >&5
30573
30574 ol_cv_db_db2=no
30575 fi
30576 rm -f conftest.err conftest.$ac_objext \
30577       conftest$ac_exeext conftest.$ac_ext
30578
30579         LIBS="$ol_LIBS"
30580
30581 fi
30582 echo "$as_me:$LINENO: result: $ol_cv_db_db2" >&5
30583 echo "${ECHO_T}$ol_cv_db_db2" >&6
30584
30585         if test $ol_cv_db_db2 = yes ; then
30586                 ol_cv_lib_db=-ldb2
30587         fi
30588 fi
30589
30590         if test $ol_cv_lib_db = no ; then
30591         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-2)" >&5
30592 echo $ECHO_N "checking for Berkeley DB link (-ldb-2)... $ECHO_C" >&6
30593 if test "${ol_cv_db_db_2+set}" = set; then
30594   echo $ECHO_N "(cached) $ECHO_C" >&6
30595 else
30596
30597         ol_DB_LIB=-ldb-2
30598         ol_LIBS=$LIBS
30599         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30600
30601         cat >conftest.$ac_ext <<_ACEOF
30602 /* confdefs.h.  */
30603 _ACEOF
30604 cat confdefs.h >>conftest.$ac_ext
30605 cat >>conftest.$ac_ext <<_ACEOF
30606 /* end confdefs.h.  */
30607
30608 #ifdef HAVE_DB_185_H
30609 # include <db_185.h>
30610 #else
30611 # include <db.h>
30612 #endif
30613
30614 #ifndef DB_VERSION_MAJOR
30615 # define DB_VERSION_MAJOR 1
30616 #endif
30617
30618 #ifndef NULL
30619 #define NULL ((void*)0)
30620 #endif
30621
30622 int
30623 main ()
30624 {
30625
30626 #if DB_VERSION_MAJOR > 1
30627         {
30628                 char *version;
30629                 int major, minor, patch;
30630
30631                 version = db_version( &major, &minor, &patch );
30632
30633                 if( major != DB_VERSION_MAJOR ||
30634                         minor < DB_VERSION_MINOR )
30635                 {
30636                         printf("Berkeley DB version mismatch\n"
30637                                 "\theader: %s\n\tlibrary: %s\n",
30638                                 DB_VERSION_STRING, version);
30639                         return 1;
30640                 }
30641         }
30642 #endif
30643
30644 #if DB_VERSION_MAJOR > 2
30645         db_env_create( NULL, 0 );
30646 #elif DB_VERSION_MAJOR > 1
30647         db_appexit( NULL );
30648 #else
30649         (void) dbopen( NULL, 0, 0, 0, NULL);
30650 #endif
30651
30652   ;
30653   return 0;
30654 }
30655 _ACEOF
30656 rm -f conftest.$ac_objext conftest$ac_exeext
30657 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30658   (eval $ac_link) 2>conftest.er1
30659   ac_status=$?
30660   grep -v '^ *+' conftest.er1 >conftest.err
30661   rm -f conftest.er1
30662   cat conftest.err >&5
30663   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30664   (exit $ac_status); } &&
30665          { ac_try='test -z "$ac_c_werror_flag"
30666                          || test ! -s conftest.err'
30667   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30668   (eval $ac_try) 2>&5
30669   ac_status=$?
30670   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30671   (exit $ac_status); }; } &&
30672          { ac_try='test -s conftest$ac_exeext'
30673   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30674   (eval $ac_try) 2>&5
30675   ac_status=$?
30676   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30677   (exit $ac_status); }; }; then
30678   ol_cv_db_db_2=yes
30679 else
30680   echo "$as_me: failed program was:" >&5
30681 sed 's/^/| /' conftest.$ac_ext >&5
30682
30683 ol_cv_db_db_2=no
30684 fi
30685 rm -f conftest.err conftest.$ac_objext \
30686       conftest$ac_exeext conftest.$ac_ext
30687
30688         LIBS="$ol_LIBS"
30689
30690 fi
30691 echo "$as_me:$LINENO: result: $ol_cv_db_db_2" >&5
30692 echo "${ECHO_T}$ol_cv_db_db_2" >&6
30693
30694         if test $ol_cv_db_db_2 = yes ; then
30695                 ol_cv_lib_db=-ldb-2
30696         fi
30697 fi
30698
30699
30700 elif test $ol_cv_bdb_major = 1 ; then
30701         if test $ol_cv_lib_db = no ; then
30702         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb1)" >&5
30703 echo $ECHO_N "checking for Berkeley DB link (-ldb1)... $ECHO_C" >&6
30704 if test "${ol_cv_db_db1+set}" = set; then
30705   echo $ECHO_N "(cached) $ECHO_C" >&6
30706 else
30707
30708         ol_DB_LIB=-ldb1
30709         ol_LIBS=$LIBS
30710         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30711
30712         cat >conftest.$ac_ext <<_ACEOF
30713 /* confdefs.h.  */
30714 _ACEOF
30715 cat confdefs.h >>conftest.$ac_ext
30716 cat >>conftest.$ac_ext <<_ACEOF
30717 /* end confdefs.h.  */
30718
30719 #ifdef HAVE_DB_185_H
30720 # include <db_185.h>
30721 #else
30722 # include <db.h>
30723 #endif
30724
30725 #ifndef DB_VERSION_MAJOR
30726 # define DB_VERSION_MAJOR 1
30727 #endif
30728
30729 #ifndef NULL
30730 #define NULL ((void*)0)
30731 #endif
30732
30733 int
30734 main ()
30735 {
30736
30737 #if DB_VERSION_MAJOR > 1
30738         {
30739                 char *version;
30740                 int major, minor, patch;
30741
30742                 version = db_version( &major, &minor, &patch );
30743
30744                 if( major != DB_VERSION_MAJOR ||
30745                         minor < DB_VERSION_MINOR )
30746                 {
30747                         printf("Berkeley DB version mismatch\n"
30748                                 "\theader: %s\n\tlibrary: %s\n",
30749                                 DB_VERSION_STRING, version);
30750                         return 1;
30751                 }
30752         }
30753 #endif
30754
30755 #if DB_VERSION_MAJOR > 2
30756         db_env_create( NULL, 0 );
30757 #elif DB_VERSION_MAJOR > 1
30758         db_appexit( NULL );
30759 #else
30760         (void) dbopen( NULL, 0, 0, 0, NULL);
30761 #endif
30762
30763   ;
30764   return 0;
30765 }
30766 _ACEOF
30767 rm -f conftest.$ac_objext conftest$ac_exeext
30768 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30769   (eval $ac_link) 2>conftest.er1
30770   ac_status=$?
30771   grep -v '^ *+' conftest.er1 >conftest.err
30772   rm -f conftest.er1
30773   cat conftest.err >&5
30774   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30775   (exit $ac_status); } &&
30776          { ac_try='test -z "$ac_c_werror_flag"
30777                          || test ! -s conftest.err'
30778   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30779   (eval $ac_try) 2>&5
30780   ac_status=$?
30781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30782   (exit $ac_status); }; } &&
30783          { ac_try='test -s conftest$ac_exeext'
30784   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30785   (eval $ac_try) 2>&5
30786   ac_status=$?
30787   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30788   (exit $ac_status); }; }; then
30789   ol_cv_db_db1=yes
30790 else
30791   echo "$as_me: failed program was:" >&5
30792 sed 's/^/| /' conftest.$ac_ext >&5
30793
30794 ol_cv_db_db1=no
30795 fi
30796 rm -f conftest.err conftest.$ac_objext \
30797       conftest$ac_exeext conftest.$ac_ext
30798
30799         LIBS="$ol_LIBS"
30800
30801 fi
30802 echo "$as_me:$LINENO: result: $ol_cv_db_db1" >&5
30803 echo "${ECHO_T}$ol_cv_db_db1" >&6
30804
30805         if test $ol_cv_db_db1 = yes ; then
30806                 ol_cv_lib_db=-ldb1
30807         fi
30808 fi
30809
30810         if test $ol_cv_lib_db = no ; then
30811         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-1)" >&5
30812 echo $ECHO_N "checking for Berkeley DB link (-ldb-1)... $ECHO_C" >&6
30813 if test "${ol_cv_db_db_1+set}" = set; then
30814   echo $ECHO_N "(cached) $ECHO_C" >&6
30815 else
30816
30817         ol_DB_LIB=-ldb-1
30818         ol_LIBS=$LIBS
30819         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30820
30821         cat >conftest.$ac_ext <<_ACEOF
30822 /* confdefs.h.  */
30823 _ACEOF
30824 cat confdefs.h >>conftest.$ac_ext
30825 cat >>conftest.$ac_ext <<_ACEOF
30826 /* end confdefs.h.  */
30827
30828 #ifdef HAVE_DB_185_H
30829 # include <db_185.h>
30830 #else
30831 # include <db.h>
30832 #endif
30833
30834 #ifndef DB_VERSION_MAJOR
30835 # define DB_VERSION_MAJOR 1
30836 #endif
30837
30838 #ifndef NULL
30839 #define NULL ((void*)0)
30840 #endif
30841
30842 int
30843 main ()
30844 {
30845
30846 #if DB_VERSION_MAJOR > 1
30847         {
30848                 char *version;
30849                 int major, minor, patch;
30850
30851                 version = db_version( &major, &minor, &patch );
30852
30853                 if( major != DB_VERSION_MAJOR ||
30854                         minor < DB_VERSION_MINOR )
30855                 {
30856                         printf("Berkeley DB version mismatch\n"
30857                                 "\theader: %s\n\tlibrary: %s\n",
30858                                 DB_VERSION_STRING, version);
30859                         return 1;
30860                 }
30861         }
30862 #endif
30863
30864 #if DB_VERSION_MAJOR > 2
30865         db_env_create( NULL, 0 );
30866 #elif DB_VERSION_MAJOR > 1
30867         db_appexit( NULL );
30868 #else
30869         (void) dbopen( NULL, 0, 0, 0, NULL);
30870 #endif
30871
30872   ;
30873   return 0;
30874 }
30875 _ACEOF
30876 rm -f conftest.$ac_objext conftest$ac_exeext
30877 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30878   (eval $ac_link) 2>conftest.er1
30879   ac_status=$?
30880   grep -v '^ *+' conftest.er1 >conftest.err
30881   rm -f conftest.er1
30882   cat conftest.err >&5
30883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30884   (exit $ac_status); } &&
30885          { ac_try='test -z "$ac_c_werror_flag"
30886                          || test ! -s conftest.err'
30887   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30888   (eval $ac_try) 2>&5
30889   ac_status=$?
30890   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30891   (exit $ac_status); }; } &&
30892          { ac_try='test -s conftest$ac_exeext'
30893   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30894   (eval $ac_try) 2>&5
30895   ac_status=$?
30896   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30897   (exit $ac_status); }; }; then
30898   ol_cv_db_db_1=yes
30899 else
30900   echo "$as_me: failed program was:" >&5
30901 sed 's/^/| /' conftest.$ac_ext >&5
30902
30903 ol_cv_db_db_1=no
30904 fi
30905 rm -f conftest.err conftest.$ac_objext \
30906       conftest$ac_exeext conftest.$ac_ext
30907
30908         LIBS="$ol_LIBS"
30909
30910 fi
30911 echo "$as_me:$LINENO: result: $ol_cv_db_db_1" >&5
30912 echo "${ECHO_T}$ol_cv_db_db_1" >&6
30913
30914         if test $ol_cv_db_db_1 = yes ; then
30915                 ol_cv_lib_db=-ldb-1
30916         fi
30917 fi
30918
30919 fi
30920 if test $ol_cv_lib_db = no ; then
30921         echo "$as_me:$LINENO: checking for Berkeley DB link (default)" >&5
30922 echo $ECHO_N "checking for Berkeley DB link (default)... $ECHO_C" >&6
30923 if test "${ol_cv_db_none+set}" = set; then
30924   echo $ECHO_N "(cached) $ECHO_C" >&6
30925 else
30926
30927         ol_DB_LIB=
30928         ol_LIBS=$LIBS
30929         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30930
30931         cat >conftest.$ac_ext <<_ACEOF
30932 /* confdefs.h.  */
30933 _ACEOF
30934 cat confdefs.h >>conftest.$ac_ext
30935 cat >>conftest.$ac_ext <<_ACEOF
30936 /* end confdefs.h.  */
30937
30938 #ifdef HAVE_DB_185_H
30939 # include <db_185.h>
30940 #else
30941 # include <db.h>
30942 #endif
30943
30944 #ifndef DB_VERSION_MAJOR
30945 # define DB_VERSION_MAJOR 1
30946 #endif
30947
30948 #ifndef NULL
30949 #define NULL ((void*)0)
30950 #endif
30951
30952 int
30953 main ()
30954 {
30955
30956 #if DB_VERSION_MAJOR > 1
30957         {
30958                 char *version;
30959                 int major, minor, patch;
30960
30961                 version = db_version( &major, &minor, &patch );
30962
30963                 if( major != DB_VERSION_MAJOR ||
30964                         minor < DB_VERSION_MINOR )
30965                 {
30966                         printf("Berkeley DB version mismatch\n"
30967                                 "\theader: %s\n\tlibrary: %s\n",
30968                                 DB_VERSION_STRING, version);
30969                         return 1;
30970                 }
30971         }
30972 #endif
30973
30974 #if DB_VERSION_MAJOR > 2
30975         db_env_create( NULL, 0 );
30976 #elif DB_VERSION_MAJOR > 1
30977         db_appexit( NULL );
30978 #else
30979         (void) dbopen( NULL, 0, 0, 0, NULL);
30980 #endif
30981
30982   ;
30983   return 0;
30984 }
30985 _ACEOF
30986 rm -f conftest.$ac_objext conftest$ac_exeext
30987 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30988   (eval $ac_link) 2>conftest.er1
30989   ac_status=$?
30990   grep -v '^ *+' conftest.er1 >conftest.err
30991   rm -f conftest.er1
30992   cat conftest.err >&5
30993   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30994   (exit $ac_status); } &&
30995          { ac_try='test -z "$ac_c_werror_flag"
30996                          || test ! -s conftest.err'
30997   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30998   (eval $ac_try) 2>&5
30999   ac_status=$?
31000   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31001   (exit $ac_status); }; } &&
31002          { ac_try='test -s conftest$ac_exeext'
31003   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31004   (eval $ac_try) 2>&5
31005   ac_status=$?
31006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31007   (exit $ac_status); }; }; then
31008   ol_cv_db_none=yes
31009 else
31010   echo "$as_me: failed program was:" >&5
31011 sed 's/^/| /' conftest.$ac_ext >&5
31012
31013 ol_cv_db_none=no
31014 fi
31015 rm -f conftest.err conftest.$ac_objext \
31016       conftest$ac_exeext conftest.$ac_ext
31017
31018         LIBS="$ol_LIBS"
31019
31020 fi
31021 echo "$as_me:$LINENO: result: $ol_cv_db_none" >&5
31022 echo "${ECHO_T}$ol_cv_db_none" >&6
31023
31024         if test $ol_cv_db_none = yes ; then
31025                 ol_cv_lib_db=yes
31026         fi
31027 fi
31028
31029
31030         if test "$ol_cv_lib_db" != no ; then
31031                 ol_cv_berkeley_db=yes
31032                 echo "$as_me:$LINENO: checking for Berkeley DB version match" >&5
31033 echo $ECHO_N "checking for Berkeley DB version match... $ECHO_C" >&6
31034 if test "${ol_cv_berkeley_db_version+set}" = set; then
31035   echo $ECHO_N "(cached) $ECHO_C" >&6
31036 else
31037
31038         ol_LIBS="$LIBS"
31039         LIBS="$LTHREAD_LIBS $LIBS"
31040         if test $ol_cv_lib_db != yes ; then
31041                 LIBS="$ol_cv_lib_db $LIBS"
31042         fi
31043
31044         if test "$cross_compiling" = yes; then
31045   ol_cv_berkeley_db_version=cross
31046 else
31047   cat >conftest.$ac_ext <<_ACEOF
31048 /* confdefs.h.  */
31049 _ACEOF
31050 cat confdefs.h >>conftest.$ac_ext
31051 cat >>conftest.$ac_ext <<_ACEOF
31052 /* end confdefs.h.  */
31053
31054 #ifdef HAVE_DB_185_H
31055         choke me;
31056 #else
31057 #include <db.h>
31058 #endif
31059 #ifndef DB_VERSION_MAJOR
31060 # define DB_VERSION_MAJOR 1
31061 #endif
31062 #ifndef NULL
31063 #define NULL ((void *)0)
31064 #endif
31065 main()
31066 {
31067 #if DB_VERSION_MAJOR > 1
31068         char *version;
31069         int major, minor, patch;
31070
31071         version = db_version( &major, &minor, &patch );
31072
31073         if( major != DB_VERSION_MAJOR ||
31074                 minor != DB_VERSION_MINOR ||
31075                 patch != DB_VERSION_PATCH )
31076         {
31077                 printf("Berkeley DB version mismatch\n"
31078                         "\theader: %s\n\tlibrary: %s\n",
31079                         DB_VERSION_STRING, version);
31080                 return 1;
31081         }
31082 #endif
31083
31084         return 0;
31085 }
31086 _ACEOF
31087 rm -f conftest$ac_exeext
31088 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31089   (eval $ac_link) 2>&5
31090   ac_status=$?
31091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31092   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
31093   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31094   (eval $ac_try) 2>&5
31095   ac_status=$?
31096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31097   (exit $ac_status); }; }; then
31098   ol_cv_berkeley_db_version=yes
31099 else
31100   echo "$as_me: program exited with status $ac_status" >&5
31101 echo "$as_me: failed program was:" >&5
31102 sed 's/^/| /' conftest.$ac_ext >&5
31103
31104 ( exit $ac_status )
31105 ol_cv_berkeley_db_version=no
31106 fi
31107 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
31108 fi
31109
31110         LIBS="$ol_LIBS"
31111
31112 fi
31113 echo "$as_me:$LINENO: result: $ol_cv_berkeley_db_version" >&5
31114 echo "${ECHO_T}$ol_cv_berkeley_db_version" >&6
31115
31116         if test $ol_cv_berkeley_db_version = no ; then
31117                 { { echo "$as_me:$LINENO: error: Berkeley DB version mismatch" >&5
31118 echo "$as_me: error: Berkeley DB version mismatch" >&2;}
31119    { (exit 1); exit 1; }; }
31120         fi
31121
31122                 echo "$as_me:$LINENO: checking for Berkeley DB thread support" >&5
31123 echo $ECHO_N "checking for Berkeley DB thread support... $ECHO_C" >&6
31124 if test "${ol_cv_berkeley_db_thread+set}" = set; then
31125   echo $ECHO_N "(cached) $ECHO_C" >&6
31126 else
31127
31128         ol_LIBS="$LIBS"
31129         LIBS="$LTHREAD_LIBS $LIBS"
31130         if test $ol_cv_lib_db != yes ; then
31131                 LIBS="$ol_cv_lib_db $LIBS"
31132         fi
31133
31134         if test "$cross_compiling" = yes; then
31135   ol_cv_berkeley_db_thread=cross
31136 else
31137   cat >conftest.$ac_ext <<_ACEOF
31138 /* confdefs.h.  */
31139 _ACEOF
31140 cat confdefs.h >>conftest.$ac_ext
31141 cat >>conftest.$ac_ext <<_ACEOF
31142 /* end confdefs.h.  */
31143
31144 #ifdef HAVE_DB_185_H
31145         choke me;
31146 #else
31147 #include <db.h>
31148 #endif
31149 #ifndef NULL
31150 #define NULL ((void *)0)
31151 #endif
31152 main()
31153 {
31154         int rc;
31155         u_int32_t flags = DB_CREATE |
31156 #ifdef DB_PRIVATE
31157                 DB_PRIVATE |
31158 #endif
31159                 DB_THREAD;
31160
31161 #if DB_VERSION_MAJOR > 2
31162         DB_ENV *env = NULL;
31163
31164         rc = db_env_create( &env, 0 );
31165
31166         flags |= DB_INIT_MPOOL;
31167 #ifdef DB_MPOOL_PRIVATE
31168         flags |= DB_MPOOL_PRIVATE;
31169 #endif
31170
31171         if( rc ) {
31172                 printf("BerkeleyDB: %s\n", db_strerror(rc) );
31173                 return rc;
31174         }
31175
31176 #if (DB_VERSION_MAJOR > 3) || (DB_VERSION_MINOR >= 1)
31177         rc = (env->open)( env, NULL, flags, 0 );
31178 #else
31179         rc = (env->open)( env, NULL, NULL, flags, 0 );
31180 #endif
31181
31182         if ( rc == 0 ) {
31183                 rc = env->close( env, 0 );
31184         }
31185
31186         if( rc ) {
31187                 printf("BerkeleyDB: %s\n", db_strerror(rc) );
31188                 return rc;
31189         }
31190
31191 #else
31192         DB_ENV env;
31193         memset( &env, '\0', sizeof(env) );
31194
31195         rc = db_appinit( NULL, NULL, &env, flags );
31196
31197         if( rc == 0 ) {
31198                 db_appexit( &env );
31199         }
31200
31201         unlink("__db_mpool.share");
31202         unlink("__db_lock.share");
31203 #endif
31204
31205         return rc;
31206 }
31207 _ACEOF
31208 rm -f conftest$ac_exeext
31209 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31210   (eval $ac_link) 2>&5
31211   ac_status=$?
31212   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31213   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
31214   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31215   (eval $ac_try) 2>&5
31216   ac_status=$?
31217   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31218   (exit $ac_status); }; }; then
31219   ol_cv_berkeley_db_thread=yes
31220 else
31221   echo "$as_me: program exited with status $ac_status" >&5
31222 echo "$as_me: failed program was:" >&5
31223 sed 's/^/| /' conftest.$ac_ext >&5
31224
31225 ( exit $ac_status )
31226 ol_cv_berkeley_db_thread=no
31227 fi
31228 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
31229 fi
31230
31231         LIBS="$ol_LIBS"
31232
31233 fi
31234 echo "$as_me:$LINENO: result: $ol_cv_berkeley_db_thread" >&5
31235 echo "${ECHO_T}$ol_cv_berkeley_db_thread" >&6
31236
31237         if test $ol_cv_berkeley_db_thread != no ; then
31238
31239 cat >>confdefs.h <<\_ACEOF
31240 #define HAVE_BERKELEY_DB_THREAD 1
31241 _ACEOF
31242
31243         fi
31244
31245         fi
31246 fi
31247
31248
31249         if test $ol_cv_berkeley_db = no ; then
31250                 { { echo "$as_me:$LINENO: error: BDB/HDB: BerkeleyDB not available" >&5
31251 echo "$as_me: error: BDB/HDB: BerkeleyDB not available" >&2;}
31252    { (exit 1); exit 1; }; }
31253         fi
31254
31255
31256 cat >>confdefs.h <<\_ACEOF
31257 #define HAVE_BERKELEY_DB 1
31258 _ACEOF
31259
31260
31261                         if test $ol_cv_lib_db != yes ; then
31262                 BDB_LIBS="$BDB_LIBS $ol_cv_lib_db"
31263         fi
31264
31265         echo "$as_me:$LINENO: checking Berkeley DB version for BDB/HDB backends" >&5
31266 echo $ECHO_N "checking Berkeley DB version for BDB/HDB backends... $ECHO_C" >&6
31267 if test "${ol_cv_bdb_compat+set}" = set; then
31268   echo $ECHO_N "(cached) $ECHO_C" >&6
31269 else
31270
31271         cat >conftest.$ac_ext <<_ACEOF
31272 /* confdefs.h.  */
31273 _ACEOF
31274 cat confdefs.h >>conftest.$ac_ext
31275 cat >>conftest.$ac_ext <<_ACEOF
31276 /* end confdefs.h.  */
31277
31278 #include <db.h>
31279
31280  /* this check could be improved */
31281 #ifndef DB_VERSION_MAJOR
31282 #       define DB_VERSION_MAJOR 1
31283 #endif
31284 #ifndef DB_VERSION_MINOR
31285 #       define DB_VERSION_MINOR 0
31286 #endif
31287
31288 /* require 4.2 or later, but exclude 4.3 */
31289 #if (DB_VERSION_MAJOR >= 4) && (DB_VERSION_MINOR >= 2) && (DB_VERSION_MINOR !=3)
31290         __db_version_compat
31291 #endif
31292
31293 _ACEOF
31294 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
31295   $EGREP "__db_version_compat" >/dev/null 2>&1; then
31296   ol_cv_bdb_compat=yes
31297 else
31298   ol_cv_bdb_compat=no
31299 fi
31300 rm -f conftest*
31301
31302 fi
31303 echo "$as_me:$LINENO: result: $ol_cv_bdb_compat" >&5
31304 echo "${ECHO_T}$ol_cv_bdb_compat" >&6
31305
31306
31307         if test $ol_cv_bdb_compat != yes ; then
31308                 { { echo "$as_me:$LINENO: error: BDB/HDB: BerkeleyDB version incompatible" >&5
31309 echo "$as_me: error: BDB/HDB: BerkeleyDB version incompatible" >&2;}
31310    { (exit 1); exit 1; }; }
31311         fi
31312
31313         SLAPD_LIBS="$SLAPD_LIBS \$(BDB_LIBS)"
31314
31315         ol_link_bdb=yes
31316 fi
31317
31318
31319 if test $ol_enable_dynamic = yes && test $enable_shared = yes ; then
31320         BUILD_LIBS_DYNAMIC=shared
31321
31322 cat >>confdefs.h <<\_ACEOF
31323 #define LDAP_LIBS_DYNAMIC 1
31324 _ACEOF
31325
31326         LTSTATIC=""
31327 else
31328         BUILD_LIBS_DYNAMIC=static
31329         LTSTATIC="-static"
31330 fi
31331
31332 if test $ol_enable_wrappers != no ; then
31333
31334 for ac_header in tcpd.h
31335 do
31336 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
31337 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31338   echo "$as_me:$LINENO: checking for $ac_header" >&5
31339 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31340 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31341   echo $ECHO_N "(cached) $ECHO_C" >&6
31342 fi
31343 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31344 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31345 else
31346   # Is the header compilable?
31347 echo "$as_me:$LINENO: checking $ac_header usability" >&5
31348 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
31349 cat >conftest.$ac_ext <<_ACEOF
31350 /* confdefs.h.  */
31351 _ACEOF
31352 cat confdefs.h >>conftest.$ac_ext
31353 cat >>conftest.$ac_ext <<_ACEOF
31354 /* end confdefs.h.  */
31355 $ac_includes_default
31356 #include <$ac_header>
31357 _ACEOF
31358 rm -f conftest.$ac_objext
31359 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31360   (eval $ac_compile) 2>conftest.er1
31361   ac_status=$?
31362   grep -v '^ *+' conftest.er1 >conftest.err
31363   rm -f conftest.er1
31364   cat conftest.err >&5
31365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31366   (exit $ac_status); } &&
31367          { ac_try='test -z "$ac_c_werror_flag"
31368                          || test ! -s conftest.err'
31369   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31370   (eval $ac_try) 2>&5
31371   ac_status=$?
31372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31373   (exit $ac_status); }; } &&
31374          { ac_try='test -s conftest.$ac_objext'
31375   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31376   (eval $ac_try) 2>&5
31377   ac_status=$?
31378   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31379   (exit $ac_status); }; }; then
31380   ac_header_compiler=yes
31381 else
31382   echo "$as_me: failed program was:" >&5
31383 sed 's/^/| /' conftest.$ac_ext >&5
31384
31385 ac_header_compiler=no
31386 fi
31387 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
31388 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
31389 echo "${ECHO_T}$ac_header_compiler" >&6
31390
31391 # Is the header present?
31392 echo "$as_me:$LINENO: checking $ac_header presence" >&5
31393 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
31394 cat >conftest.$ac_ext <<_ACEOF
31395 /* confdefs.h.  */
31396 _ACEOF
31397 cat confdefs.h >>conftest.$ac_ext
31398 cat >>conftest.$ac_ext <<_ACEOF
31399 /* end confdefs.h.  */
31400 #include <$ac_header>
31401 _ACEOF
31402 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
31403   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
31404   ac_status=$?
31405   grep -v '^ *+' conftest.er1 >conftest.err
31406   rm -f conftest.er1
31407   cat conftest.err >&5
31408   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31409   (exit $ac_status); } >/dev/null; then
31410   if test -s conftest.err; then
31411     ac_cpp_err=$ac_c_preproc_warn_flag
31412     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
31413   else
31414     ac_cpp_err=
31415   fi
31416 else
31417   ac_cpp_err=yes
31418 fi
31419 if test -z "$ac_cpp_err"; then
31420   ac_header_preproc=yes
31421 else
31422   echo "$as_me: failed program was:" >&5
31423 sed 's/^/| /' conftest.$ac_ext >&5
31424
31425   ac_header_preproc=no
31426 fi
31427 rm -f conftest.err conftest.$ac_ext
31428 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
31429 echo "${ECHO_T}$ac_header_preproc" >&6
31430
31431 # So?  What about this header?
31432 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
31433   yes:no: )
31434     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
31435 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
31436     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
31437 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
31438     ac_header_preproc=yes
31439     ;;
31440   no:yes:* )
31441     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
31442 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
31443     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
31444 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
31445     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
31446 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
31447     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
31448 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
31449     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
31450 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
31451     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
31452 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
31453     (
31454       cat <<\_ASBOX
31455 ## --------------------------------------------- ##
31456 ## Report this to <http://www.openldap.org/its/> ##
31457 ## --------------------------------------------- ##
31458 _ASBOX
31459     ) |
31460       sed "s/^/$as_me: WARNING:     /" >&2
31461     ;;
31462 esac
31463 echo "$as_me:$LINENO: checking for $ac_header" >&5
31464 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31465 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31466   echo $ECHO_N "(cached) $ECHO_C" >&6
31467 else
31468   eval "$as_ac_Header=\$ac_header_preproc"
31469 fi
31470 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31471 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31472
31473 fi
31474 if test `eval echo '${'$as_ac_Header'}'` = yes; then
31475   cat >>confdefs.h <<_ACEOF
31476 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
31477 _ACEOF
31478
31479                 echo "$as_me:$LINENO: checking for TCP wrappers library" >&5
31480 echo $ECHO_N "checking for TCP wrappers library... $ECHO_C" >&6
31481                 save_LIBS="$LIBS"
31482                 LIBS="$LIBS -lwrap"
31483                 cat >conftest.$ac_ext <<_ACEOF
31484 /* confdefs.h.  */
31485 _ACEOF
31486 cat confdefs.h >>conftest.$ac_ext
31487 cat >>conftest.$ac_ext <<_ACEOF
31488 /* end confdefs.h.  */
31489
31490 #include <tcpd.h>
31491 int allow_severity = 0;
31492 int deny_severity  = 0;
31493
31494 struct request_info *req;
31495
31496 int
31497 main ()
31498 {
31499
31500 hosts_access(req)
31501
31502   ;
31503   return 0;
31504 }
31505 _ACEOF
31506 rm -f conftest.$ac_objext conftest$ac_exeext
31507 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31508   (eval $ac_link) 2>conftest.er1
31509   ac_status=$?
31510   grep -v '^ *+' conftest.er1 >conftest.err
31511   rm -f conftest.er1
31512   cat conftest.err >&5
31513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31514   (exit $ac_status); } &&
31515          { ac_try='test -z "$ac_c_werror_flag"
31516                          || test ! -s conftest.err'
31517   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31518   (eval $ac_try) 2>&5
31519   ac_status=$?
31520   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31521   (exit $ac_status); }; } &&
31522          { ac_try='test -s conftest$ac_exeext'
31523   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31524   (eval $ac_try) 2>&5
31525   ac_status=$?
31526   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31527   (exit $ac_status); }; }; then
31528   echo "$as_me:$LINENO: result: -lwrap" >&5
31529 echo "${ECHO_T}-lwrap" >&6
31530                 have_wrappers=yes
31531                 LIBS="$save_LIBS"
31532 else
31533   echo "$as_me: failed program was:" >&5
31534 sed 's/^/| /' conftest.$ac_ext >&5
31535
31536
31537                                 LIBS="$LIBS -lnsl"
31538                 cat >conftest.$ac_ext <<_ACEOF
31539 /* confdefs.h.  */
31540 _ACEOF
31541 cat confdefs.h >>conftest.$ac_ext
31542 cat >>conftest.$ac_ext <<_ACEOF
31543 /* end confdefs.h.  */
31544
31545 #include <tcpd.h>
31546 int allow_severity = 0;
31547 int deny_severity  = 0;
31548
31549 struct request_info *req;
31550
31551 int
31552 main ()
31553 {
31554
31555 hosts_access(req)
31556
31557   ;
31558   return 0;
31559 }
31560 _ACEOF
31561 rm -f conftest.$ac_objext conftest$ac_exeext
31562 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31563   (eval $ac_link) 2>conftest.er1
31564   ac_status=$?
31565   grep -v '^ *+' conftest.er1 >conftest.err
31566   rm -f conftest.er1
31567   cat conftest.err >&5
31568   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31569   (exit $ac_status); } &&
31570          { ac_try='test -z "$ac_c_werror_flag"
31571                          || test ! -s conftest.err'
31572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31573   (eval $ac_try) 2>&5
31574   ac_status=$?
31575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31576   (exit $ac_status); }; } &&
31577          { ac_try='test -s conftest$ac_exeext'
31578   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31579   (eval $ac_try) 2>&5
31580   ac_status=$?
31581   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31582   (exit $ac_status); }; }; then
31583   echo "$as_me:$LINENO: result: -lwrap -lnsl" >&5
31584 echo "${ECHO_T}-lwrap -lnsl" >&6
31585                 have_wrappers=yes
31586                 LIBS="$save_LIBS -lnsl"
31587 else
31588   echo "$as_me: failed program was:" >&5
31589 sed 's/^/| /' conftest.$ac_ext >&5
31590
31591
31592                 echo "$as_me:$LINENO: result: no" >&5
31593 echo "${ECHO_T}no" >&6
31594                 have_wrappers=no
31595                 LIBS=$save_LIBS
31596 fi
31597 rm -f conftest.err conftest.$ac_objext \
31598       conftest$ac_exeext conftest.$ac_ext
31599 fi
31600 rm -f conftest.err conftest.$ac_objext \
31601       conftest$ac_exeext conftest.$ac_ext
31602 else
31603   have_wrappers=no
31604 fi
31605
31606 done
31607
31608
31609         if test $have_wrappers = yes ; then
31610
31611 cat >>confdefs.h <<\_ACEOF
31612 #define HAVE_TCPD 1
31613 _ACEOF
31614
31615                 WRAP_LIBS="-lwrap"
31616         elif test $ol_enable_wrappers = yes ; then
31617                 { { echo "$as_me:$LINENO: error: could not find TCP wrappers, select apppropriate options or disable" >&5
31618 echo "$as_me: error: could not find TCP wrappers, select apppropriate options or disable" >&2;}
31619    { (exit 1); exit 1; }; }
31620         else
31621                 { echo "$as_me:$LINENO: WARNING: could not find TCP wrappers, support disabled" >&5
31622 echo "$as_me: WARNING: could not find TCP wrappers, support disabled" >&2;}
31623                 WRAP_LIBS=""
31624         fi
31625 fi
31626
31627 if test $ol_enable_syslog != no ; then
31628         echo "$as_me:$LINENO: checking for openlog" >&5
31629 echo $ECHO_N "checking for openlog... $ECHO_C" >&6
31630 if test "${ac_cv_func_openlog+set}" = set; then
31631   echo $ECHO_N "(cached) $ECHO_C" >&6
31632 else
31633   cat >conftest.$ac_ext <<_ACEOF
31634 /* confdefs.h.  */
31635 _ACEOF
31636 cat confdefs.h >>conftest.$ac_ext
31637 cat >>conftest.$ac_ext <<_ACEOF
31638 /* end confdefs.h.  */
31639 /* Define openlog to an innocuous variant, in case <limits.h> declares openlog.
31640    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
31641 #define openlog innocuous_openlog
31642
31643 /* System header to define __stub macros and hopefully few prototypes,
31644     which can conflict with char openlog (); below.
31645     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31646     <limits.h> exists even on freestanding compilers.  */
31647
31648 #ifdef __STDC__
31649 # include <limits.h>
31650 #else
31651 # include <assert.h>
31652 #endif
31653
31654 #undef openlog
31655
31656 /* Override any gcc2 internal prototype to avoid an error.  */
31657 #ifdef __cplusplus
31658 extern "C"
31659 {
31660 #endif
31661 /* We use char because int might match the return type of a gcc2
31662    builtin and then its argument prototype would still apply.  */
31663 char openlog ();
31664 /* The GNU C library defines this for functions which it implements
31665     to always fail with ENOSYS.  Some functions are actually named
31666     something starting with __ and the normal name is an alias.  */
31667 #if defined (__stub_openlog) || defined (__stub___openlog)
31668 choke me
31669 #else
31670 char (*f) () = openlog;
31671 #endif
31672 #ifdef __cplusplus
31673 }
31674 #endif
31675
31676 int
31677 main ()
31678 {
31679 return f != openlog;
31680   ;
31681   return 0;
31682 }
31683 _ACEOF
31684 rm -f conftest.$ac_objext conftest$ac_exeext
31685 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31686   (eval $ac_link) 2>conftest.er1
31687   ac_status=$?
31688   grep -v '^ *+' conftest.er1 >conftest.err
31689   rm -f conftest.er1
31690   cat conftest.err >&5
31691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31692   (exit $ac_status); } &&
31693          { ac_try='test -z "$ac_c_werror_flag"
31694                          || test ! -s conftest.err'
31695   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31696   (eval $ac_try) 2>&5
31697   ac_status=$?
31698   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31699   (exit $ac_status); }; } &&
31700          { ac_try='test -s conftest$ac_exeext'
31701   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31702   (eval $ac_try) 2>&5
31703   ac_status=$?
31704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31705   (exit $ac_status); }; }; then
31706   ac_cv_func_openlog=yes
31707 else
31708   echo "$as_me: failed program was:" >&5
31709 sed 's/^/| /' conftest.$ac_ext >&5
31710
31711 ac_cv_func_openlog=no
31712 fi
31713 rm -f conftest.err conftest.$ac_objext \
31714       conftest$ac_exeext conftest.$ac_ext
31715 fi
31716 echo "$as_me:$LINENO: result: $ac_cv_func_openlog" >&5
31717 echo "${ECHO_T}$ac_cv_func_openlog" >&6
31718
31719         if test $ac_cv_func_openlog = no && test $ol_enable_syslog = yes; then
31720                 { { echo "$as_me:$LINENO: error: could not find syslog" >&5
31721 echo "$as_me: error: could not find syslog" >&2;}
31722    { (exit select appropriate options or disable); exit select appropriate options or disable; }; }
31723         fi
31724         ol_enable_syslog=$ac_cv_func_openlog
31725 fi
31726
31727 ol_link_sql=no
31728 if test $ol_enable_sql != no ; then
31729
31730
31731 for ac_header in sql.h sqlext.h
31732 do
31733 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
31734 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31735   echo "$as_me:$LINENO: checking for $ac_header" >&5
31736 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31737 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31738   echo $ECHO_N "(cached) $ECHO_C" >&6
31739 fi
31740 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31741 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31742 else
31743   # Is the header compilable?
31744 echo "$as_me:$LINENO: checking $ac_header usability" >&5
31745 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
31746 cat >conftest.$ac_ext <<_ACEOF
31747 /* confdefs.h.  */
31748 _ACEOF
31749 cat confdefs.h >>conftest.$ac_ext
31750 cat >>conftest.$ac_ext <<_ACEOF
31751 /* end confdefs.h.  */
31752 $ac_includes_default
31753 #include <$ac_header>
31754 _ACEOF
31755 rm -f conftest.$ac_objext
31756 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31757   (eval $ac_compile) 2>conftest.er1
31758   ac_status=$?
31759   grep -v '^ *+' conftest.er1 >conftest.err
31760   rm -f conftest.er1
31761   cat conftest.err >&5
31762   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31763   (exit $ac_status); } &&
31764          { ac_try='test -z "$ac_c_werror_flag"
31765                          || test ! -s conftest.err'
31766   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31767   (eval $ac_try) 2>&5
31768   ac_status=$?
31769   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31770   (exit $ac_status); }; } &&
31771          { ac_try='test -s conftest.$ac_objext'
31772   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31773   (eval $ac_try) 2>&5
31774   ac_status=$?
31775   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31776   (exit $ac_status); }; }; then
31777   ac_header_compiler=yes
31778 else
31779   echo "$as_me: failed program was:" >&5
31780 sed 's/^/| /' conftest.$ac_ext >&5
31781
31782 ac_header_compiler=no
31783 fi
31784 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
31785 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
31786 echo "${ECHO_T}$ac_header_compiler" >&6
31787
31788 # Is the header present?
31789 echo "$as_me:$LINENO: checking $ac_header presence" >&5
31790 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
31791 cat >conftest.$ac_ext <<_ACEOF
31792 /* confdefs.h.  */
31793 _ACEOF
31794 cat confdefs.h >>conftest.$ac_ext
31795 cat >>conftest.$ac_ext <<_ACEOF
31796 /* end confdefs.h.  */
31797 #include <$ac_header>
31798 _ACEOF
31799 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
31800   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
31801   ac_status=$?
31802   grep -v '^ *+' conftest.er1 >conftest.err
31803   rm -f conftest.er1
31804   cat conftest.err >&5
31805   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31806   (exit $ac_status); } >/dev/null; then
31807   if test -s conftest.err; then
31808     ac_cpp_err=$ac_c_preproc_warn_flag
31809     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
31810   else
31811     ac_cpp_err=
31812   fi
31813 else
31814   ac_cpp_err=yes
31815 fi
31816 if test -z "$ac_cpp_err"; then
31817   ac_header_preproc=yes
31818 else
31819   echo "$as_me: failed program was:" >&5
31820 sed 's/^/| /' conftest.$ac_ext >&5
31821
31822   ac_header_preproc=no
31823 fi
31824 rm -f conftest.err conftest.$ac_ext
31825 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
31826 echo "${ECHO_T}$ac_header_preproc" >&6
31827
31828 # So?  What about this header?
31829 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
31830   yes:no: )
31831     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
31832 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
31833     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
31834 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
31835     ac_header_preproc=yes
31836     ;;
31837   no:yes:* )
31838     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
31839 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
31840     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
31841 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
31842     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
31843 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
31844     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
31845 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
31846     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
31847 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
31848     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
31849 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
31850     (
31851       cat <<\_ASBOX
31852 ## --------------------------------------------- ##
31853 ## Report this to <http://www.openldap.org/its/> ##
31854 ## --------------------------------------------- ##
31855 _ASBOX
31856     ) |
31857       sed "s/^/$as_me: WARNING:     /" >&2
31858     ;;
31859 esac
31860 echo "$as_me:$LINENO: checking for $ac_header" >&5
31861 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31862 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31863   echo $ECHO_N "(cached) $ECHO_C" >&6
31864 else
31865   eval "$as_ac_Header=\$ac_header_preproc"
31866 fi
31867 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31868 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31869
31870 fi
31871 if test `eval echo '${'$as_ac_Header'}'` = yes; then
31872   cat >>confdefs.h <<_ACEOF
31873 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
31874 _ACEOF
31875
31876 else
31877
31878                 { { echo "$as_me:$LINENO: error: could not locate SQL headers" >&5
31879 echo "$as_me: error: could not locate SQL headers" >&2;}
31880    { (exit 1); exit 1; }; }
31881
31882 fi
31883
31884 done
31885
31886
31887         sql_LIBS="$LIBS"
31888         LIBS="$LTHREAD_LIBS"
31889
31890         if test $ol_with_odbc = auto ; then
31891                 ol_with_odbc="iodbc unixodbc"
31892         fi
31893
31894         for odbc in $ol_with_odbc ; do
31895                 if test $ol_link_sql = no ; then
31896                         case $odbc in
31897                         iodbc)
31898                                 echo "$as_me:$LINENO: checking for SQLDriverConnect in -liodbc" >&5
31899 echo $ECHO_N "checking for SQLDriverConnect in -liodbc... $ECHO_C" >&6
31900 if test "${ac_cv_lib_iodbc_SQLDriverConnect+set}" = set; then
31901   echo $ECHO_N "(cached) $ECHO_C" >&6
31902 else
31903   ac_check_lib_save_LIBS=$LIBS
31904 LIBS="-liodbc  $LIBS"
31905 cat >conftest.$ac_ext <<_ACEOF
31906 /* confdefs.h.  */
31907 _ACEOF
31908 cat confdefs.h >>conftest.$ac_ext
31909 cat >>conftest.$ac_ext <<_ACEOF
31910 /* end confdefs.h.  */
31911
31912 /* Override any gcc2 internal prototype to avoid an error.  */
31913 #ifdef __cplusplus
31914 extern "C"
31915 #endif
31916 /* We use char because int might match the return type of a gcc2
31917    builtin and then its argument prototype would still apply.  */
31918 char SQLDriverConnect ();
31919 int
31920 main ()
31921 {
31922 SQLDriverConnect ();
31923   ;
31924   return 0;
31925 }
31926 _ACEOF
31927 rm -f conftest.$ac_objext conftest$ac_exeext
31928 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31929   (eval $ac_link) 2>conftest.er1
31930   ac_status=$?
31931   grep -v '^ *+' conftest.er1 >conftest.err
31932   rm -f conftest.er1
31933   cat conftest.err >&5
31934   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31935   (exit $ac_status); } &&
31936          { ac_try='test -z "$ac_c_werror_flag"
31937                          || test ! -s conftest.err'
31938   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31939   (eval $ac_try) 2>&5
31940   ac_status=$?
31941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31942   (exit $ac_status); }; } &&
31943          { ac_try='test -s conftest$ac_exeext'
31944   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31945   (eval $ac_try) 2>&5
31946   ac_status=$?
31947   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31948   (exit $ac_status); }; }; then
31949   ac_cv_lib_iodbc_SQLDriverConnect=yes
31950 else
31951   echo "$as_me: failed program was:" >&5
31952 sed 's/^/| /' conftest.$ac_ext >&5
31953
31954 ac_cv_lib_iodbc_SQLDriverConnect=no
31955 fi
31956 rm -f conftest.err conftest.$ac_objext \
31957       conftest$ac_exeext conftest.$ac_ext
31958 LIBS=$ac_check_lib_save_LIBS
31959 fi
31960 echo "$as_me:$LINENO: result: $ac_cv_lib_iodbc_SQLDriverConnect" >&5
31961 echo "${ECHO_T}$ac_cv_lib_iodbc_SQLDriverConnect" >&6
31962 if test $ac_cv_lib_iodbc_SQLDriverConnect = yes; then
31963   have_iodbc=yes
31964 else
31965   have_iodbc=no
31966 fi
31967
31968                                 if test $have_iodbc = yes ; then
31969                                         ol_link_sql="-liodbc"
31970                                 fi
31971                                 ;;
31972
31973                         unixodbc)
31974                                 echo "$as_me:$LINENO: checking for SQLDriverConnect in -lodbc" >&5
31975 echo $ECHO_N "checking for SQLDriverConnect in -lodbc... $ECHO_C" >&6
31976 if test "${ac_cv_lib_odbc_SQLDriverConnect+set}" = set; then
31977   echo $ECHO_N "(cached) $ECHO_C" >&6
31978 else
31979   ac_check_lib_save_LIBS=$LIBS
31980 LIBS="-lodbc  $LIBS"
31981 cat >conftest.$ac_ext <<_ACEOF
31982 /* confdefs.h.  */
31983 _ACEOF
31984 cat confdefs.h >>conftest.$ac_ext
31985 cat >>conftest.$ac_ext <<_ACEOF
31986 /* end confdefs.h.  */
31987
31988 /* Override any gcc2 internal prototype to avoid an error.  */
31989 #ifdef __cplusplus
31990 extern "C"
31991 #endif
31992 /* We use char because int might match the return type of a gcc2
31993    builtin and then its argument prototype would still apply.  */
31994 char SQLDriverConnect ();
31995 int
31996 main ()
31997 {
31998 SQLDriverConnect ();
31999   ;
32000   return 0;
32001 }
32002 _ACEOF
32003 rm -f conftest.$ac_objext conftest$ac_exeext
32004 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32005   (eval $ac_link) 2>conftest.er1
32006   ac_status=$?
32007   grep -v '^ *+' conftest.er1 >conftest.err
32008   rm -f conftest.er1
32009   cat conftest.err >&5
32010   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32011   (exit $ac_status); } &&
32012          { ac_try='test -z "$ac_c_werror_flag"
32013                          || test ! -s conftest.err'
32014   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32015   (eval $ac_try) 2>&5
32016   ac_status=$?
32017   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32018   (exit $ac_status); }; } &&
32019          { ac_try='test -s conftest$ac_exeext'
32020   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32021   (eval $ac_try) 2>&5
32022   ac_status=$?
32023   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32024   (exit $ac_status); }; }; then
32025   ac_cv_lib_odbc_SQLDriverConnect=yes
32026 else
32027   echo "$as_me: failed program was:" >&5
32028 sed 's/^/| /' conftest.$ac_ext >&5
32029
32030 ac_cv_lib_odbc_SQLDriverConnect=no
32031 fi
32032 rm -f conftest.err conftest.$ac_objext \
32033       conftest$ac_exeext conftest.$ac_ext
32034 LIBS=$ac_check_lib_save_LIBS
32035 fi
32036 echo "$as_me:$LINENO: result: $ac_cv_lib_odbc_SQLDriverConnect" >&5
32037 echo "${ECHO_T}$ac_cv_lib_odbc_SQLDriverConnect" >&6
32038 if test $ac_cv_lib_odbc_SQLDriverConnect = yes; then
32039   have_odbc=yes
32040 else
32041   have_odbc=no
32042 fi
32043
32044                                 if test $have_odbc = yes ; then
32045                                         ol_link_sql="-lodbc"
32046                                 fi
32047                                 ;;
32048
32049                         *)
32050                                 { { echo "$as_me:$LINENO: error: unknown ODBC library" >&5
32051 echo "$as_me: error: unknown ODBC library" >&2;}
32052    { (exit 1); exit 1; }; }
32053                                 ;;
32054                         esac
32055                 fi
32056         done
32057
32058         LIBS="$sql_LIBS"
32059
32060         if test $ol_link_sql != no ; then
32061                 SLAPD_SQL_LIBS="$ol_link_sql"
32062
32063         elif test $ol_enable_sql != auto ; then
32064                 { { echo "$as_me:$LINENO: error: could not locate suitable ODBC library" >&5
32065 echo "$as_me: error: could not locate suitable ODBC library" >&2;}
32066    { (exit 1); exit 1; }; }
32067         fi
32068 fi
32069
32070 ol_icu=no
32071
32072 for ac_header in unicode/utypes.h
32073 do
32074 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
32075 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32076   echo "$as_me:$LINENO: checking for $ac_header" >&5
32077 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32078 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32079   echo $ECHO_N "(cached) $ECHO_C" >&6
32080 fi
32081 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32082 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32083 else
32084   # Is the header compilable?
32085 echo "$as_me:$LINENO: checking $ac_header usability" >&5
32086 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
32087 cat >conftest.$ac_ext <<_ACEOF
32088 /* confdefs.h.  */
32089 _ACEOF
32090 cat confdefs.h >>conftest.$ac_ext
32091 cat >>conftest.$ac_ext <<_ACEOF
32092 /* end confdefs.h.  */
32093 $ac_includes_default
32094 #include <$ac_header>
32095 _ACEOF
32096 rm -f conftest.$ac_objext
32097 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32098   (eval $ac_compile) 2>conftest.er1
32099   ac_status=$?
32100   grep -v '^ *+' conftest.er1 >conftest.err
32101   rm -f conftest.er1
32102   cat conftest.err >&5
32103   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32104   (exit $ac_status); } &&
32105          { ac_try='test -z "$ac_c_werror_flag"
32106                          || test ! -s conftest.err'
32107   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32108   (eval $ac_try) 2>&5
32109   ac_status=$?
32110   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32111   (exit $ac_status); }; } &&
32112          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
32118   ac_header_compiler=yes
32119 else
32120   echo "$as_me: failed program was:" >&5
32121 sed 's/^/| /' conftest.$ac_ext >&5
32122
32123 ac_header_compiler=no
32124 fi
32125 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32126 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
32127 echo "${ECHO_T}$ac_header_compiler" >&6
32128
32129 # Is the header present?
32130 echo "$as_me:$LINENO: checking $ac_header presence" >&5
32131 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
32132 cat >conftest.$ac_ext <<_ACEOF
32133 /* confdefs.h.  */
32134 _ACEOF
32135 cat confdefs.h >>conftest.$ac_ext
32136 cat >>conftest.$ac_ext <<_ACEOF
32137 /* end confdefs.h.  */
32138 #include <$ac_header>
32139 _ACEOF
32140 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
32141   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
32142   ac_status=$?
32143   grep -v '^ *+' conftest.er1 >conftest.err
32144   rm -f conftest.er1
32145   cat conftest.err >&5
32146   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32147   (exit $ac_status); } >/dev/null; then
32148   if test -s conftest.err; then
32149     ac_cpp_err=$ac_c_preproc_warn_flag
32150     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
32151   else
32152     ac_cpp_err=
32153   fi
32154 else
32155   ac_cpp_err=yes
32156 fi
32157 if test -z "$ac_cpp_err"; then
32158   ac_header_preproc=yes
32159 else
32160   echo "$as_me: failed program was:" >&5
32161 sed 's/^/| /' conftest.$ac_ext >&5
32162
32163   ac_header_preproc=no
32164 fi
32165 rm -f conftest.err conftest.$ac_ext
32166 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
32167 echo "${ECHO_T}$ac_header_preproc" >&6
32168
32169 # So?  What about this header?
32170 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
32171   yes:no: )
32172     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
32173 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
32174     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
32175 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
32176     ac_header_preproc=yes
32177     ;;
32178   no:yes:* )
32179     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
32180 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
32181     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
32182 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
32183     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
32184 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
32185     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
32186 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
32187     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
32188 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
32189     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
32190 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
32191     (
32192       cat <<\_ASBOX
32193 ## --------------------------------------------- ##
32194 ## Report this to <http://www.openldap.org/its/> ##
32195 ## --------------------------------------------- ##
32196 _ASBOX
32197     ) |
32198       sed "s/^/$as_me: WARNING:     /" >&2
32199     ;;
32200 esac
32201 echo "$as_me:$LINENO: checking for $ac_header" >&5
32202 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32203 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32204   echo $ECHO_N "(cached) $ECHO_C" >&6
32205 else
32206   eval "$as_ac_Header=\$ac_header_preproc"
32207 fi
32208 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32209 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32210
32211 fi
32212 if test `eval echo '${'$as_ac_Header'}'` = yes; then
32213   cat >>confdefs.h <<_ACEOF
32214 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
32215 _ACEOF
32216
32217 fi
32218
32219 done
32220
32221 if test $ac_cv_header_unicode_utypes_h = yes ; then
32222                 OL_ICULIBS="-licuuc -licudata"
32223
32224         echo "$as_me:$LINENO: checking for ICU libraries" >&5
32225 echo $ECHO_N "checking for ICU libraries... $ECHO_C" >&6
32226 if test "${ol_cv_lib_icu+set}" = set; then
32227   echo $ECHO_N "(cached) $ECHO_C" >&6
32228 else
32229
32230                 ol_LIBS="$LIBS"
32231                 LIBS="$OL_ICULIBS $LIBS"
32232                 cat >conftest.$ac_ext <<_ACEOF
32233 /* confdefs.h.  */
32234 _ACEOF
32235 cat confdefs.h >>conftest.$ac_ext
32236 cat >>conftest.$ac_ext <<_ACEOF
32237 /* end confdefs.h.  */
32238
32239 #include <unicode/utypes.h>
32240
32241 int
32242 main ()
32243 {
32244
32245 (void) u_errorName(0);
32246
32247   ;
32248   return 0;
32249 }
32250 _ACEOF
32251 rm -f conftest.$ac_objext conftest$ac_exeext
32252 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32253   (eval $ac_link) 2>conftest.er1
32254   ac_status=$?
32255   grep -v '^ *+' conftest.er1 >conftest.err
32256   rm -f conftest.er1
32257   cat conftest.err >&5
32258   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32259   (exit $ac_status); } &&
32260          { ac_try='test -z "$ac_c_werror_flag"
32261                          || test ! -s conftest.err'
32262   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32263   (eval $ac_try) 2>&5
32264   ac_status=$?
32265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32266   (exit $ac_status); }; } &&
32267          { ac_try='test -s conftest$ac_exeext'
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); }; }; then
32273   ol_cv_lib_icu=yes
32274 else
32275   echo "$as_me: failed program was:" >&5
32276 sed 's/^/| /' conftest.$ac_ext >&5
32277
32278 ol_cv_lib_icu=no
32279 fi
32280 rm -f conftest.err conftest.$ac_objext \
32281       conftest$ac_exeext conftest.$ac_ext
32282                 LIBS="$ol_LIBS"
32283
32284 fi
32285 echo "$as_me:$LINENO: result: $ol_cv_lib_icu" >&5
32286 echo "${ECHO_T}$ol_cv_lib_icu" >&6
32287
32288         if test $ol_cv_lib_icu != no ; then
32289                 ol_icu="$OL_ICULIBS"
32290
32291 cat >>confdefs.h <<\_ACEOF
32292 #define HAVE_ICU 1
32293 _ACEOF
32294
32295         fi
32296 fi
32297
32298 if test "$ol_icu" = no ; then
32299         { echo "$as_me:$LINENO: WARNING: ICU not available" >&5
32300 echo "$as_me: WARNING: ICU not available" >&2;}
32301 else
32302         ICU_LIBS="$ol_icu"
32303 fi
32304 WITH_SASL=no
32305 ol_link_sasl=no
32306 ol_link_spasswd=no
32307 if test $ol_with_cyrus_sasl != no ; then
32308
32309
32310 for ac_header in sasl/sasl.h sasl.h
32311 do
32312 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
32313 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32314   echo "$as_me:$LINENO: checking for $ac_header" >&5
32315 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32316 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32317   echo $ECHO_N "(cached) $ECHO_C" >&6
32318 fi
32319 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32320 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32321 else
32322   # Is the header compilable?
32323 echo "$as_me:$LINENO: checking $ac_header usability" >&5
32324 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
32325 cat >conftest.$ac_ext <<_ACEOF
32326 /* confdefs.h.  */
32327 _ACEOF
32328 cat confdefs.h >>conftest.$ac_ext
32329 cat >>conftest.$ac_ext <<_ACEOF
32330 /* end confdefs.h.  */
32331 $ac_includes_default
32332 #include <$ac_header>
32333 _ACEOF
32334 rm -f conftest.$ac_objext
32335 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32336   (eval $ac_compile) 2>conftest.er1
32337   ac_status=$?
32338   grep -v '^ *+' conftest.er1 >conftest.err
32339   rm -f conftest.er1
32340   cat conftest.err >&5
32341   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32342   (exit $ac_status); } &&
32343          { ac_try='test -z "$ac_c_werror_flag"
32344                          || test ! -s conftest.err'
32345   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32346   (eval $ac_try) 2>&5
32347   ac_status=$?
32348   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32349   (exit $ac_status); }; } &&
32350          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
32356   ac_header_compiler=yes
32357 else
32358   echo "$as_me: failed program was:" >&5
32359 sed 's/^/| /' conftest.$ac_ext >&5
32360
32361 ac_header_compiler=no
32362 fi
32363 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32364 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
32365 echo "${ECHO_T}$ac_header_compiler" >&6
32366
32367 # Is the header present?
32368 echo "$as_me:$LINENO: checking $ac_header presence" >&5
32369 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
32370 cat >conftest.$ac_ext <<_ACEOF
32371 /* confdefs.h.  */
32372 _ACEOF
32373 cat confdefs.h >>conftest.$ac_ext
32374 cat >>conftest.$ac_ext <<_ACEOF
32375 /* end confdefs.h.  */
32376 #include <$ac_header>
32377 _ACEOF
32378 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
32379   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
32380   ac_status=$?
32381   grep -v '^ *+' conftest.er1 >conftest.err
32382   rm -f conftest.er1
32383   cat conftest.err >&5
32384   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32385   (exit $ac_status); } >/dev/null; then
32386   if test -s conftest.err; then
32387     ac_cpp_err=$ac_c_preproc_warn_flag
32388     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
32389   else
32390     ac_cpp_err=
32391   fi
32392 else
32393   ac_cpp_err=yes
32394 fi
32395 if test -z "$ac_cpp_err"; then
32396   ac_header_preproc=yes
32397 else
32398   echo "$as_me: failed program was:" >&5
32399 sed 's/^/| /' conftest.$ac_ext >&5
32400
32401   ac_header_preproc=no
32402 fi
32403 rm -f conftest.err conftest.$ac_ext
32404 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
32405 echo "${ECHO_T}$ac_header_preproc" >&6
32406
32407 # So?  What about this header?
32408 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
32409   yes:no: )
32410     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
32411 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
32412     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
32413 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
32414     ac_header_preproc=yes
32415     ;;
32416   no:yes:* )
32417     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
32418 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
32419     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
32420 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
32421     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
32422 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
32423     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
32424 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
32425     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
32426 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
32427     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
32428 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
32429     (
32430       cat <<\_ASBOX
32431 ## --------------------------------------------- ##
32432 ## Report this to <http://www.openldap.org/its/> ##
32433 ## --------------------------------------------- ##
32434 _ASBOX
32435     ) |
32436       sed "s/^/$as_me: WARNING:     /" >&2
32437     ;;
32438 esac
32439 echo "$as_me:$LINENO: checking for $ac_header" >&5
32440 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32441 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32442   echo $ECHO_N "(cached) $ECHO_C" >&6
32443 else
32444   eval "$as_ac_Header=\$ac_header_preproc"
32445 fi
32446 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32447 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32448
32449 fi
32450 if test `eval echo '${'$as_ac_Header'}'` = yes; then
32451   cat >>confdefs.h <<_ACEOF
32452 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
32453 _ACEOF
32454
32455 fi
32456
32457 done
32458
32459
32460         if test $ac_cv_header_sasl_sasl_h = yes ||
32461            test $ac_cv_header_sasl_h = yes; then
32462                 echo "$as_me:$LINENO: checking for sasl_client_init in -lsasl2" >&5
32463 echo $ECHO_N "checking for sasl_client_init in -lsasl2... $ECHO_C" >&6
32464 if test "${ac_cv_lib_sasl2_sasl_client_init+set}" = set; then
32465   echo $ECHO_N "(cached) $ECHO_C" >&6
32466 else
32467   ac_check_lib_save_LIBS=$LIBS
32468 LIBS="-lsasl2  $LIBS"
32469 cat >conftest.$ac_ext <<_ACEOF
32470 /* confdefs.h.  */
32471 _ACEOF
32472 cat confdefs.h >>conftest.$ac_ext
32473 cat >>conftest.$ac_ext <<_ACEOF
32474 /* end confdefs.h.  */
32475
32476 /* Override any gcc2 internal prototype to avoid an error.  */
32477 #ifdef __cplusplus
32478 extern "C"
32479 #endif
32480 /* We use char because int might match the return type of a gcc2
32481    builtin and then its argument prototype would still apply.  */
32482 char sasl_client_init ();
32483 int
32484 main ()
32485 {
32486 sasl_client_init ();
32487   ;
32488   return 0;
32489 }
32490 _ACEOF
32491 rm -f conftest.$ac_objext conftest$ac_exeext
32492 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32493   (eval $ac_link) 2>conftest.er1
32494   ac_status=$?
32495   grep -v '^ *+' conftest.er1 >conftest.err
32496   rm -f conftest.er1
32497   cat conftest.err >&5
32498   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32499   (exit $ac_status); } &&
32500          { ac_try='test -z "$ac_c_werror_flag"
32501                          || test ! -s conftest.err'
32502   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32503   (eval $ac_try) 2>&5
32504   ac_status=$?
32505   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32506   (exit $ac_status); }; } &&
32507          { ac_try='test -s conftest$ac_exeext'
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); }; }; then
32513   ac_cv_lib_sasl2_sasl_client_init=yes
32514 else
32515   echo "$as_me: failed program was:" >&5
32516 sed 's/^/| /' conftest.$ac_ext >&5
32517
32518 ac_cv_lib_sasl2_sasl_client_init=no
32519 fi
32520 rm -f conftest.err conftest.$ac_objext \
32521       conftest$ac_exeext conftest.$ac_ext
32522 LIBS=$ac_check_lib_save_LIBS
32523 fi
32524 echo "$as_me:$LINENO: result: $ac_cv_lib_sasl2_sasl_client_init" >&5
32525 echo "${ECHO_T}$ac_cv_lib_sasl2_sasl_client_init" >&6
32526 if test $ac_cv_lib_sasl2_sasl_client_init = yes; then
32527   ol_link_sasl="-lsasl2"
32528 else
32529   echo "$as_me:$LINENO: checking for sasl_client_init in -lsasl" >&5
32530 echo $ECHO_N "checking for sasl_client_init in -lsasl... $ECHO_C" >&6
32531 if test "${ac_cv_lib_sasl_sasl_client_init+set}" = set; then
32532   echo $ECHO_N "(cached) $ECHO_C" >&6
32533 else
32534   ac_check_lib_save_LIBS=$LIBS
32535 LIBS="-lsasl  $LIBS"
32536 cat >conftest.$ac_ext <<_ACEOF
32537 /* confdefs.h.  */
32538 _ACEOF
32539 cat confdefs.h >>conftest.$ac_ext
32540 cat >>conftest.$ac_ext <<_ACEOF
32541 /* end confdefs.h.  */
32542
32543 /* Override any gcc2 internal prototype to avoid an error.  */
32544 #ifdef __cplusplus
32545 extern "C"
32546 #endif
32547 /* We use char because int might match the return type of a gcc2
32548    builtin and then its argument prototype would still apply.  */
32549 char sasl_client_init ();
32550 int
32551 main ()
32552 {
32553 sasl_client_init ();
32554   ;
32555   return 0;
32556 }
32557 _ACEOF
32558 rm -f conftest.$ac_objext conftest$ac_exeext
32559 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32560   (eval $ac_link) 2>conftest.er1
32561   ac_status=$?
32562   grep -v '^ *+' conftest.er1 >conftest.err
32563   rm -f conftest.er1
32564   cat conftest.err >&5
32565   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32566   (exit $ac_status); } &&
32567          { ac_try='test -z "$ac_c_werror_flag"
32568                          || test ! -s conftest.err'
32569   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32570   (eval $ac_try) 2>&5
32571   ac_status=$?
32572   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32573   (exit $ac_status); }; } &&
32574          { ac_try='test -s conftest$ac_exeext'
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); }; }; then
32580   ac_cv_lib_sasl_sasl_client_init=yes
32581 else
32582   echo "$as_me: failed program was:" >&5
32583 sed 's/^/| /' conftest.$ac_ext >&5
32584
32585 ac_cv_lib_sasl_sasl_client_init=no
32586 fi
32587 rm -f conftest.err conftest.$ac_objext \
32588       conftest$ac_exeext conftest.$ac_ext
32589 LIBS=$ac_check_lib_save_LIBS
32590 fi
32591 echo "$as_me:$LINENO: result: $ac_cv_lib_sasl_sasl_client_init" >&5
32592 echo "${ECHO_T}$ac_cv_lib_sasl_sasl_client_init" >&6
32593 if test $ac_cv_lib_sasl_sasl_client_init = yes; then
32594   ol_link_sasl="-lsasl"
32595 fi
32596
32597 fi
32598
32599         fi
32600
32601         if test $ol_link_sasl = no ; then
32602                 if test $ol_with_cyrus_sasl != auto ; then
32603                         { { echo "$as_me:$LINENO: error: Could not locate Cyrus SASL" >&5
32604 echo "$as_me: error: Could not locate Cyrus SASL" >&2;}
32605    { (exit 1); exit 1; }; }
32606                 else
32607                         { echo "$as_me:$LINENO: WARNING: Could not locate Cyrus SASL" >&5
32608 echo "$as_me: WARNING: Could not locate Cyrus SASL" >&2;}
32609                         { echo "$as_me:$LINENO: WARNING: SASL authentication not supported!" >&5
32610 echo "$as_me: WARNING: SASL authentication not supported!" >&2;}
32611                         if test $ol_link_tls = no ; then
32612                                 { echo "$as_me:$LINENO: WARNING: Strong authentication not supported!" >&5
32613 echo "$as_me: WARNING: Strong authentication not supported!" >&2;}
32614                         fi
32615                 fi
32616         else
32617                 echo "$as_me:$LINENO: checking Cyrus SASL library version" >&5
32618 echo $ECHO_N "checking Cyrus SASL library version... $ECHO_C" >&6
32619 if test "${ol_cv_sasl_compat+set}" = set; then
32620   echo $ECHO_N "(cached) $ECHO_C" >&6
32621 else
32622
32623         cat >conftest.$ac_ext <<_ACEOF
32624 /* confdefs.h.  */
32625 _ACEOF
32626 cat confdefs.h >>conftest.$ac_ext
32627 cat >>conftest.$ac_ext <<_ACEOF
32628 /* end confdefs.h.  */
32629
32630 #ifdef HAVE_SASL_SASL_H
32631 #include <sasl/sasl.h>
32632 #else
32633 #include <sasl.h>
32634 #endif
32635
32636 /* Require 2.1.15+ */
32637 #if SASL_VERSION_MAJOR == 2  && SASL_VERSION_MINOR > 1
32638         char *__sasl_compat = "2.2+ or better okay (we guess)";
32639 #elif SASL_VERSION_MAJOR == 2  && SASL_VERSION_MINOR == 1 \
32640         && SASL_VERSION_STEP >=15
32641         char *__sasl_compat = "2.1.15+ or better okay";
32642 #endif
32643
32644 _ACEOF
32645 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32646   $EGREP "__sasl_compat" >/dev/null 2>&1; then
32647   ol_cv_sasl_compat=yes
32648 else
32649   ol_cv_sasl_compat=no
32650 fi
32651 rm -f conftest*
32652
32653 fi
32654 echo "$as_me:$LINENO: result: $ol_cv_sasl_compat" >&5
32655 echo "${ECHO_T}$ol_cv_sasl_compat" >&6
32656
32657                 if test $ol_cv_sasl_compat = no ; then
32658                         ol_link_sasl=no
32659                         { { echo "$as_me:$LINENO: error: Cyrus SASL library located but is incompatible" >&5
32660 echo "$as_me: error: Cyrus SASL library located but is incompatible" >&2;}
32661    { (exit 1); exit 1; }; }
32662                 fi
32663
32664
32665 cat >>confdefs.h <<\_ACEOF
32666 #define HAVE_CYRUS_SASL 1
32667 _ACEOF
32668
32669                 SASL_LIBS="$ol_link_sasl"
32670                 if test $ol_enable_spasswd != no ; then
32671                         ol_link_spasswd=yes
32672                 fi
32673
32674                 ac_save_LIBS="$LIBS"
32675                 LIBS="$LIBS $ol_link_sasl"
32676                 echo "$as_me:$LINENO: checking for sasl_version" >&5
32677 echo $ECHO_N "checking for sasl_version... $ECHO_C" >&6
32678 if test "${ac_cv_func_sasl_version+set}" = set; then
32679   echo $ECHO_N "(cached) $ECHO_C" >&6
32680 else
32681   cat >conftest.$ac_ext <<_ACEOF
32682 /* confdefs.h.  */
32683 _ACEOF
32684 cat confdefs.h >>conftest.$ac_ext
32685 cat >>conftest.$ac_ext <<_ACEOF
32686 /* end confdefs.h.  */
32687 /* Define sasl_version to an innocuous variant, in case <limits.h> declares sasl_version.
32688    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
32689 #define sasl_version innocuous_sasl_version
32690
32691 /* System header to define __stub macros and hopefully few prototypes,
32692     which can conflict with char sasl_version (); below.
32693     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
32694     <limits.h> exists even on freestanding compilers.  */
32695
32696 #ifdef __STDC__
32697 # include <limits.h>
32698 #else
32699 # include <assert.h>
32700 #endif
32701
32702 #undef sasl_version
32703
32704 /* Override any gcc2 internal prototype to avoid an error.  */
32705 #ifdef __cplusplus
32706 extern "C"
32707 {
32708 #endif
32709 /* We use char because int might match the return type of a gcc2
32710    builtin and then its argument prototype would still apply.  */
32711 char sasl_version ();
32712 /* The GNU C library defines this for functions which it implements
32713     to always fail with ENOSYS.  Some functions are actually named
32714     something starting with __ and the normal name is an alias.  */
32715 #if defined (__stub_sasl_version) || defined (__stub___sasl_version)
32716 choke me
32717 #else
32718 char (*f) () = sasl_version;
32719 #endif
32720 #ifdef __cplusplus
32721 }
32722 #endif
32723
32724 int
32725 main ()
32726 {
32727 return f != sasl_version;
32728   ;
32729   return 0;
32730 }
32731 _ACEOF
32732 rm -f conftest.$ac_objext conftest$ac_exeext
32733 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32734   (eval $ac_link) 2>conftest.er1
32735   ac_status=$?
32736   grep -v '^ *+' conftest.er1 >conftest.err
32737   rm -f conftest.er1
32738   cat conftest.err >&5
32739   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32740   (exit $ac_status); } &&
32741          { ac_try='test -z "$ac_c_werror_flag"
32742                          || test ! -s conftest.err'
32743   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32744   (eval $ac_try) 2>&5
32745   ac_status=$?
32746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32747   (exit $ac_status); }; } &&
32748          { ac_try='test -s conftest$ac_exeext'
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); }; }; then
32754   ac_cv_func_sasl_version=yes
32755 else
32756   echo "$as_me: failed program was:" >&5
32757 sed 's/^/| /' conftest.$ac_ext >&5
32758
32759 ac_cv_func_sasl_version=no
32760 fi
32761 rm -f conftest.err conftest.$ac_objext \
32762       conftest$ac_exeext conftest.$ac_ext
32763 fi
32764 echo "$as_me:$LINENO: result: $ac_cv_func_sasl_version" >&5
32765 echo "${ECHO_T}$ac_cv_func_sasl_version" >&6
32766 if test $ac_cv_func_sasl_version = yes; then
32767
32768 cat >>confdefs.h <<\_ACEOF
32769 #define HAVE_SASL_VERSION 1
32770 _ACEOF
32771
32772 fi
32773
32774                 LIBS="$ac_save_LIBS"
32775
32776                 WITH_SASL=yes
32777         fi
32778
32779 else
32780         { echo "$as_me:$LINENO: WARNING: SASL authentication not supported!" >&5
32781 echo "$as_me: WARNING: SASL authentication not supported!" >&2;}
32782         if test $ol_link_tls = no ; then
32783                 { echo "$as_me:$LINENO: WARNING: Strong authentication not supported!" >&5
32784 echo "$as_me: WARNING: Strong authentication not supported!" >&2;}
32785         fi
32786 fi
32787
32788 if test $cross_compiling != yes && test "$ac_cv_mingw32" != yes ; then
32789         dev=no
32790         if test -r /dev/urandom ; then
32791                 dev="/dev/urandom";
32792         elif test -r /idev/urandom ; then
32793                 dev="/idev/urandom";
32794         elif test -r /dev/srandom ; then
32795                 dev="/dev/srandom";
32796         elif test -r /dev/random ; then
32797                 dev="/dev/random";
32798         elif test -r /idev/random ; then
32799                 dev="/idev/random";
32800         fi
32801
32802         if test $dev != no ; then
32803
32804 cat >>confdefs.h <<_ACEOF
32805 #define URANDOM_DEVICE "$dev"
32806 _ACEOF
32807
32808         fi
32809 fi
32810
32811 ol_link_fetch=no
32812 if test $ol_with_fetch != no ; then
32813         ol_LIBS=$LIBS
32814 LIBS="-lfetch -lcom_err $LIBS"
32815 echo "$as_me:$LINENO: checking fetch(3) library" >&5
32816 echo $ECHO_N "checking fetch(3) library... $ECHO_C" >&6
32817 if test "${ol_cv_lib_fetch+set}" = set; then
32818   echo $ECHO_N "(cached) $ECHO_C" >&6
32819 else
32820
32821         cat >conftest.$ac_ext <<_ACEOF
32822 /* confdefs.h.  */
32823 _ACEOF
32824 cat confdefs.h >>conftest.$ac_ext
32825 cat >>conftest.$ac_ext <<_ACEOF
32826 /* end confdefs.h.  */
32827
32828 #include <sys/param.h>
32829 #include <stdio.h>
32830 #include <fetch.h>
32831 int
32832 main ()
32833 {
32834 struct url *u = fetchParseURL("file:///");
32835   ;
32836   return 0;
32837 }
32838 _ACEOF
32839 rm -f conftest.$ac_objext conftest$ac_exeext
32840 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32841   (eval $ac_link) 2>conftest.er1
32842   ac_status=$?
32843   grep -v '^ *+' conftest.er1 >conftest.err
32844   rm -f conftest.er1
32845   cat conftest.err >&5
32846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32847   (exit $ac_status); } &&
32848          { ac_try='test -z "$ac_c_werror_flag"
32849                          || test ! -s conftest.err'
32850   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32851   (eval $ac_try) 2>&5
32852   ac_status=$?
32853   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32854   (exit $ac_status); }; } &&
32855          { ac_try='test -s conftest$ac_exeext'
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); }; }; then
32861   ol_cv_lib_fetch=yes
32862 else
32863   echo "$as_me: failed program was:" >&5
32864 sed 's/^/| /' conftest.$ac_ext >&5
32865
32866 ol_cv_lib_fetch=no
32867 fi
32868 rm -f conftest.err conftest.$ac_objext \
32869       conftest$ac_exeext conftest.$ac_ext
32870 fi
32871 echo "$as_me:$LINENO: result: $ol_cv_lib_fetch" >&5
32872 echo "${ECHO_T}$ol_cv_lib_fetch" >&6
32873 LIBS=$ol_LIBS
32874 if test $ol_cv_lib_fetch != no ; then
32875         ol_link_fetch="-lfetch -lcom_err"
32876
32877 cat >>confdefs.h <<\_ACEOF
32878 #define HAVE_FETCH 1
32879 _ACEOF
32880
32881 fi
32882
32883
32884         if test $ol_cv_lib_fetch != no ; then
32885                 LUTIL_LIBS="$LUTIL_LIBS $ol_link_fetch"
32886                 ol_link_fetch=freebsd
32887
32888         elif test $ol_with_fetch != auto ; then
32889                 { { echo "$as_me:$LINENO: error: no suitable API for --with-fetch=$ol_with_fetch" >&5
32890 echo "$as_me: error: no suitable API for --with-fetch=$ol_with_fetch" >&2;}
32891    { (exit 1); exit 1; }; }
32892         fi
32893 fi
32894
32895 if test $ol_enable_crypt != no ; then
32896         save_LIBS="$LIBS"
32897         LIBS="$TLS_LIBS $LIBS"
32898
32899         echo "$as_me:$LINENO: checking for crypt" >&5
32900 echo $ECHO_N "checking for crypt... $ECHO_C" >&6
32901 if test "${ac_cv_func_crypt+set}" = set; then
32902   echo $ECHO_N "(cached) $ECHO_C" >&6
32903 else
32904   cat >conftest.$ac_ext <<_ACEOF
32905 /* confdefs.h.  */
32906 _ACEOF
32907 cat confdefs.h >>conftest.$ac_ext
32908 cat >>conftest.$ac_ext <<_ACEOF
32909 /* end confdefs.h.  */
32910 /* Define crypt to an innocuous variant, in case <limits.h> declares crypt.
32911    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
32912 #define crypt innocuous_crypt
32913
32914 /* System header to define __stub macros and hopefully few prototypes,
32915     which can conflict with char crypt (); below.
32916     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
32917     <limits.h> exists even on freestanding compilers.  */
32918
32919 #ifdef __STDC__
32920 # include <limits.h>
32921 #else
32922 # include <assert.h>
32923 #endif
32924
32925 #undef crypt
32926
32927 /* Override any gcc2 internal prototype to avoid an error.  */
32928 #ifdef __cplusplus
32929 extern "C"
32930 {
32931 #endif
32932 /* We use char because int might match the return type of a gcc2
32933    builtin and then its argument prototype would still apply.  */
32934 char crypt ();
32935 /* The GNU C library defines this for functions which it implements
32936     to always fail with ENOSYS.  Some functions are actually named
32937     something starting with __ and the normal name is an alias.  */
32938 #if defined (__stub_crypt) || defined (__stub___crypt)
32939 choke me
32940 #else
32941 char (*f) () = crypt;
32942 #endif
32943 #ifdef __cplusplus
32944 }
32945 #endif
32946
32947 int
32948 main ()
32949 {
32950 return f != crypt;
32951   ;
32952   return 0;
32953 }
32954 _ACEOF
32955 rm -f conftest.$ac_objext conftest$ac_exeext
32956 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32957   (eval $ac_link) 2>conftest.er1
32958   ac_status=$?
32959   grep -v '^ *+' conftest.er1 >conftest.err
32960   rm -f conftest.er1
32961   cat conftest.err >&5
32962   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32963   (exit $ac_status); } &&
32964          { ac_try='test -z "$ac_c_werror_flag"
32965                          || test ! -s conftest.err'
32966   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32967   (eval $ac_try) 2>&5
32968   ac_status=$?
32969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32970   (exit $ac_status); }; } &&
32971          { ac_try='test -s conftest$ac_exeext'
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); }; }; then
32977   ac_cv_func_crypt=yes
32978 else
32979   echo "$as_me: failed program was:" >&5
32980 sed 's/^/| /' conftest.$ac_ext >&5
32981
32982 ac_cv_func_crypt=no
32983 fi
32984 rm -f conftest.err conftest.$ac_objext \
32985       conftest$ac_exeext conftest.$ac_ext
32986 fi
32987 echo "$as_me:$LINENO: result: $ac_cv_func_crypt" >&5
32988 echo "${ECHO_T}$ac_cv_func_crypt" >&6
32989 if test $ac_cv_func_crypt = yes; then
32990   have_crypt=yes
32991 else
32992
32993                 LIBS="$save_LIBS"
32994                 echo "$as_me:$LINENO: checking for crypt in -lcrypt" >&5
32995 echo $ECHO_N "checking for crypt in -lcrypt... $ECHO_C" >&6
32996 if test "${ac_cv_lib_crypt_crypt+set}" = set; then
32997   echo $ECHO_N "(cached) $ECHO_C" >&6
32998 else
32999   ac_check_lib_save_LIBS=$LIBS
33000 LIBS="-lcrypt  $LIBS"
33001 cat >conftest.$ac_ext <<_ACEOF
33002 /* confdefs.h.  */
33003 _ACEOF
33004 cat confdefs.h >>conftest.$ac_ext
33005 cat >>conftest.$ac_ext <<_ACEOF
33006 /* end confdefs.h.  */
33007
33008 /* Override any gcc2 internal prototype to avoid an error.  */
33009 #ifdef __cplusplus
33010 extern "C"
33011 #endif
33012 /* We use char because int might match the return type of a gcc2
33013    builtin and then its argument prototype would still apply.  */
33014 char crypt ();
33015 int
33016 main ()
33017 {
33018 crypt ();
33019   ;
33020   return 0;
33021 }
33022 _ACEOF
33023 rm -f conftest.$ac_objext conftest$ac_exeext
33024 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33025   (eval $ac_link) 2>conftest.er1
33026   ac_status=$?
33027   grep -v '^ *+' conftest.er1 >conftest.err
33028   rm -f conftest.er1
33029   cat conftest.err >&5
33030   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33031   (exit $ac_status); } &&
33032          { ac_try='test -z "$ac_c_werror_flag"
33033                          || test ! -s conftest.err'
33034   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33035   (eval $ac_try) 2>&5
33036   ac_status=$?
33037   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33038   (exit $ac_status); }; } &&
33039          { ac_try='test -s conftest$ac_exeext'
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); }; }; then
33045   ac_cv_lib_crypt_crypt=yes
33046 else
33047   echo "$as_me: failed program was:" >&5
33048 sed 's/^/| /' conftest.$ac_ext >&5
33049
33050 ac_cv_lib_crypt_crypt=no
33051 fi
33052 rm -f conftest.err conftest.$ac_objext \
33053       conftest$ac_exeext conftest.$ac_ext
33054 LIBS=$ac_check_lib_save_LIBS
33055 fi
33056 echo "$as_me:$LINENO: result: $ac_cv_lib_crypt_crypt" >&5
33057 echo "${ECHO_T}$ac_cv_lib_crypt_crypt" >&6
33058 if test $ac_cv_lib_crypt_crypt = yes; then
33059   LUTIL_LIBS="$LUTIL_LIBS -lcrypt"
33060                         have_crypt=yes
33061 else
33062   have_crypt=no
33063 fi
33064
33065 fi
33066
33067
33068         LIBS="$save_LIBS"
33069
33070         if test $have_crypt = yes ; then
33071
33072 cat >>confdefs.h <<\_ACEOF
33073 #define HAVE_CRYPT 1
33074 _ACEOF
33075
33076         else
33077                 { echo "$as_me:$LINENO: WARNING: could not find crypt" >&5
33078 echo "$as_me: WARNING: could not find crypt" >&2;}
33079                 if test $ol_enable_crypt = yes ; then
33080                         { { echo "$as_me:$LINENO: error: could not find crypt, select appropriate options or disable" >&5
33081 echo "$as_me: error: could not find crypt, select appropriate options or disable" >&2;}
33082    { (exit 1); exit 1; }; }
33083                 fi
33084
33085                 { echo "$as_me:$LINENO: WARNING: disabling crypt support" >&5
33086 echo "$as_me: WARNING: disabling crypt support" >&2;}
33087                 ol_enable_crypt=no
33088         fi
33089 fi
33090
33091 if test $ol_enable_proctitle != no ; then
33092         echo "$as_me:$LINENO: checking for setproctitle" >&5
33093 echo $ECHO_N "checking for setproctitle... $ECHO_C" >&6
33094 if test "${ac_cv_func_setproctitle+set}" = set; then
33095   echo $ECHO_N "(cached) $ECHO_C" >&6
33096 else
33097   cat >conftest.$ac_ext <<_ACEOF
33098 /* confdefs.h.  */
33099 _ACEOF
33100 cat confdefs.h >>conftest.$ac_ext
33101 cat >>conftest.$ac_ext <<_ACEOF
33102 /* end confdefs.h.  */
33103 /* Define setproctitle to an innocuous variant, in case <limits.h> declares setproctitle.
33104    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
33105 #define setproctitle innocuous_setproctitle
33106
33107 /* System header to define __stub macros and hopefully few prototypes,
33108     which can conflict with char setproctitle (); below.
33109     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
33110     <limits.h> exists even on freestanding compilers.  */
33111
33112 #ifdef __STDC__
33113 # include <limits.h>
33114 #else
33115 # include <assert.h>
33116 #endif
33117
33118 #undef setproctitle
33119
33120 /* Override any gcc2 internal prototype to avoid an error.  */
33121 #ifdef __cplusplus
33122 extern "C"
33123 {
33124 #endif
33125 /* We use char because int might match the return type of a gcc2
33126    builtin and then its argument prototype would still apply.  */
33127 char setproctitle ();
33128 /* The GNU C library defines this for functions which it implements
33129     to always fail with ENOSYS.  Some functions are actually named
33130     something starting with __ and the normal name is an alias.  */
33131 #if defined (__stub_setproctitle) || defined (__stub___setproctitle)
33132 choke me
33133 #else
33134 char (*f) () = setproctitle;
33135 #endif
33136 #ifdef __cplusplus
33137 }
33138 #endif
33139
33140 int
33141 main ()
33142 {
33143 return f != setproctitle;
33144   ;
33145   return 0;
33146 }
33147 _ACEOF
33148 rm -f conftest.$ac_objext conftest$ac_exeext
33149 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33150   (eval $ac_link) 2>conftest.er1
33151   ac_status=$?
33152   grep -v '^ *+' conftest.er1 >conftest.err
33153   rm -f conftest.er1
33154   cat conftest.err >&5
33155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33156   (exit $ac_status); } &&
33157          { ac_try='test -z "$ac_c_werror_flag"
33158                          || test ! -s conftest.err'
33159   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33160   (eval $ac_try) 2>&5
33161   ac_status=$?
33162   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33163   (exit $ac_status); }; } &&
33164          { ac_try='test -s conftest$ac_exeext'
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); }; }; then
33170   ac_cv_func_setproctitle=yes
33171 else
33172   echo "$as_me: failed program was:" >&5
33173 sed 's/^/| /' conftest.$ac_ext >&5
33174
33175 ac_cv_func_setproctitle=no
33176 fi
33177 rm -f conftest.err conftest.$ac_objext \
33178       conftest$ac_exeext conftest.$ac_ext
33179 fi
33180 echo "$as_me:$LINENO: result: $ac_cv_func_setproctitle" >&5
33181 echo "${ECHO_T}$ac_cv_func_setproctitle" >&6
33182 if test $ac_cv_func_setproctitle = yes; then
33183   have_setproctitle=yes
33184 else
33185
33186                 echo "$as_me:$LINENO: checking for setproctitle in -lutil" >&5
33187 echo $ECHO_N "checking for setproctitle in -lutil... $ECHO_C" >&6
33188 if test "${ac_cv_lib_util_setproctitle+set}" = set; then
33189   echo $ECHO_N "(cached) $ECHO_C" >&6
33190 else
33191   ac_check_lib_save_LIBS=$LIBS
33192 LIBS="-lutil  $LIBS"
33193 cat >conftest.$ac_ext <<_ACEOF
33194 /* confdefs.h.  */
33195 _ACEOF
33196 cat confdefs.h >>conftest.$ac_ext
33197 cat >>conftest.$ac_ext <<_ACEOF
33198 /* end confdefs.h.  */
33199
33200 /* Override any gcc2 internal prototype to avoid an error.  */
33201 #ifdef __cplusplus
33202 extern "C"
33203 #endif
33204 /* We use char because int might match the return type of a gcc2
33205    builtin and then its argument prototype would still apply.  */
33206 char setproctitle ();
33207 int
33208 main ()
33209 {
33210 setproctitle ();
33211   ;
33212   return 0;
33213 }
33214 _ACEOF
33215 rm -f conftest.$ac_objext conftest$ac_exeext
33216 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33217   (eval $ac_link) 2>conftest.er1
33218   ac_status=$?
33219   grep -v '^ *+' conftest.er1 >conftest.err
33220   rm -f conftest.er1
33221   cat conftest.err >&5
33222   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33223   (exit $ac_status); } &&
33224          { ac_try='test -z "$ac_c_werror_flag"
33225                          || test ! -s conftest.err'
33226   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33227   (eval $ac_try) 2>&5
33228   ac_status=$?
33229   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33230   (exit $ac_status); }; } &&
33231          { ac_try='test -s conftest$ac_exeext'
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); }; }; then
33237   ac_cv_lib_util_setproctitle=yes
33238 else
33239   echo "$as_me: failed program was:" >&5
33240 sed 's/^/| /' conftest.$ac_ext >&5
33241
33242 ac_cv_lib_util_setproctitle=no
33243 fi
33244 rm -f conftest.err conftest.$ac_objext \
33245       conftest$ac_exeext conftest.$ac_ext
33246 LIBS=$ac_check_lib_save_LIBS
33247 fi
33248 echo "$as_me:$LINENO: result: $ac_cv_lib_util_setproctitle" >&5
33249 echo "${ECHO_T}$ac_cv_lib_util_setproctitle" >&6
33250 if test $ac_cv_lib_util_setproctitle = yes; then
33251   have_setproctitle=yes
33252                         LUTIL_LIBS="$LUTIL_LIBS -lutil"
33253 else
33254   have_setproctitle=no
33255                         case $LIBOBJS in
33256     "setproctitle.$ac_objext"   | \
33257   *" setproctitle.$ac_objext"   | \
33258     "setproctitle.$ac_objext "* | \
33259   *" setproctitle.$ac_objext "* ) ;;
33260   *) LIBOBJS="$LIBOBJS setproctitle.$ac_objext" ;;
33261 esac
33262
33263                         LIBSRCS="$LIBSRCS setproctitle.c"
33264 fi
33265
33266 fi
33267
33268
33269         if test $have_setproctitle = yes ; then
33270
33271 cat >>confdefs.h <<\_ACEOF
33272 #define HAVE_SETPROCTITLE 1
33273 _ACEOF
33274
33275         fi
33276 fi
33277
33278 if test $ol_enable_slp != no ; then
33279
33280 for ac_header in slp.h
33281 do
33282 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
33283 if eval "test \"\${$as_ac_Header+set}\" = set"; then
33284   echo "$as_me:$LINENO: checking for $ac_header" >&5
33285 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
33286 if eval "test \"\${$as_ac_Header+set}\" = set"; then
33287   echo $ECHO_N "(cached) $ECHO_C" >&6
33288 fi
33289 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
33290 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
33291 else
33292   # Is the header compilable?
33293 echo "$as_me:$LINENO: checking $ac_header usability" >&5
33294 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
33295 cat >conftest.$ac_ext <<_ACEOF
33296 /* confdefs.h.  */
33297 _ACEOF
33298 cat confdefs.h >>conftest.$ac_ext
33299 cat >>conftest.$ac_ext <<_ACEOF
33300 /* end confdefs.h.  */
33301 $ac_includes_default
33302 #include <$ac_header>
33303 _ACEOF
33304 rm -f conftest.$ac_objext
33305 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33306   (eval $ac_compile) 2>conftest.er1
33307   ac_status=$?
33308   grep -v '^ *+' conftest.er1 >conftest.err
33309   rm -f conftest.er1
33310   cat conftest.err >&5
33311   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33312   (exit $ac_status); } &&
33313          { ac_try='test -z "$ac_c_werror_flag"
33314                          || test ! -s conftest.err'
33315   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33316   (eval $ac_try) 2>&5
33317   ac_status=$?
33318   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33319   (exit $ac_status); }; } &&
33320          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
33326   ac_header_compiler=yes
33327 else
33328   echo "$as_me: failed program was:" >&5
33329 sed 's/^/| /' conftest.$ac_ext >&5
33330
33331 ac_header_compiler=no
33332 fi
33333 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33334 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
33335 echo "${ECHO_T}$ac_header_compiler" >&6
33336
33337 # Is the header present?
33338 echo "$as_me:$LINENO: checking $ac_header presence" >&5
33339 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
33340 cat >conftest.$ac_ext <<_ACEOF
33341 /* confdefs.h.  */
33342 _ACEOF
33343 cat confdefs.h >>conftest.$ac_ext
33344 cat >>conftest.$ac_ext <<_ACEOF
33345 /* end confdefs.h.  */
33346 #include <$ac_header>
33347 _ACEOF
33348 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
33349   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
33350   ac_status=$?
33351   grep -v '^ *+' conftest.er1 >conftest.err
33352   rm -f conftest.er1
33353   cat conftest.err >&5
33354   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33355   (exit $ac_status); } >/dev/null; then
33356   if test -s conftest.err; then
33357     ac_cpp_err=$ac_c_preproc_warn_flag
33358     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
33359   else
33360     ac_cpp_err=
33361   fi
33362 else
33363   ac_cpp_err=yes
33364 fi
33365 if test -z "$ac_cpp_err"; then
33366   ac_header_preproc=yes
33367 else
33368   echo "$as_me: failed program was:" >&5
33369 sed 's/^/| /' conftest.$ac_ext >&5
33370
33371   ac_header_preproc=no
33372 fi
33373 rm -f conftest.err conftest.$ac_ext
33374 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
33375 echo "${ECHO_T}$ac_header_preproc" >&6
33376
33377 # So?  What about this header?
33378 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
33379   yes:no: )
33380     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
33381 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
33382     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
33383 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
33384     ac_header_preproc=yes
33385     ;;
33386   no:yes:* )
33387     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
33388 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
33389     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
33390 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
33391     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
33392 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
33393     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
33394 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
33395     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
33396 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
33397     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
33398 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
33399     (
33400       cat <<\_ASBOX
33401 ## --------------------------------------------- ##
33402 ## Report this to <http://www.openldap.org/its/> ##
33403 ## --------------------------------------------- ##
33404 _ASBOX
33405     ) |
33406       sed "s/^/$as_me: WARNING:     /" >&2
33407     ;;
33408 esac
33409 echo "$as_me:$LINENO: checking for $ac_header" >&5
33410 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
33411 if eval "test \"\${$as_ac_Header+set}\" = set"; then
33412   echo $ECHO_N "(cached) $ECHO_C" >&6
33413 else
33414   eval "$as_ac_Header=\$ac_header_preproc"
33415 fi
33416 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
33417 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
33418
33419 fi
33420 if test `eval echo '${'$as_ac_Header'}'` = yes; then
33421   cat >>confdefs.h <<_ACEOF
33422 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
33423 _ACEOF
33424
33425 fi
33426
33427 done
33428
33429
33430         if test $ac_cv_header_slp_h = yes ; then
33431                 echo "$as_me:$LINENO: checking for SLPOpen in -lslp" >&5
33432 echo $ECHO_N "checking for SLPOpen in -lslp... $ECHO_C" >&6
33433 if test "${ac_cv_lib_slp_SLPOpen+set}" = set; then
33434   echo $ECHO_N "(cached) $ECHO_C" >&6
33435 else
33436   ac_check_lib_save_LIBS=$LIBS
33437 LIBS="-lslp  $LIBS"
33438 cat >conftest.$ac_ext <<_ACEOF
33439 /* confdefs.h.  */
33440 _ACEOF
33441 cat confdefs.h >>conftest.$ac_ext
33442 cat >>conftest.$ac_ext <<_ACEOF
33443 /* end confdefs.h.  */
33444
33445 /* Override any gcc2 internal prototype to avoid an error.  */
33446 #ifdef __cplusplus
33447 extern "C"
33448 #endif
33449 /* We use char because int might match the return type of a gcc2
33450    builtin and then its argument prototype would still apply.  */
33451 char SLPOpen ();
33452 int
33453 main ()
33454 {
33455 SLPOpen ();
33456   ;
33457   return 0;
33458 }
33459 _ACEOF
33460 rm -f conftest.$ac_objext conftest$ac_exeext
33461 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33462   (eval $ac_link) 2>conftest.er1
33463   ac_status=$?
33464   grep -v '^ *+' conftest.er1 >conftest.err
33465   rm -f conftest.er1
33466   cat conftest.err >&5
33467   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33468   (exit $ac_status); } &&
33469          { ac_try='test -z "$ac_c_werror_flag"
33470                          || test ! -s conftest.err'
33471   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33472   (eval $ac_try) 2>&5
33473   ac_status=$?
33474   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33475   (exit $ac_status); }; } &&
33476          { ac_try='test -s conftest$ac_exeext'
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); }; }; then
33482   ac_cv_lib_slp_SLPOpen=yes
33483 else
33484   echo "$as_me: failed program was:" >&5
33485 sed 's/^/| /' conftest.$ac_ext >&5
33486
33487 ac_cv_lib_slp_SLPOpen=no
33488 fi
33489 rm -f conftest.err conftest.$ac_objext \
33490       conftest$ac_exeext conftest.$ac_ext
33491 LIBS=$ac_check_lib_save_LIBS
33492 fi
33493 echo "$as_me:$LINENO: result: $ac_cv_lib_slp_SLPOpen" >&5
33494 echo "${ECHO_T}$ac_cv_lib_slp_SLPOpen" >&6
33495 if test $ac_cv_lib_slp_SLPOpen = yes; then
33496   have_slp=yes
33497 else
33498   have_slp=no
33499 fi
33500
33501                 if test $have_slp = yes ; then
33502
33503 cat >>confdefs.h <<\_ACEOF
33504 #define HAVE_SLP 1
33505 _ACEOF
33506
33507                         SLAPD_SLP_LIBS=-lslp
33508                 fi
33509
33510         elif test $ol_enable_slp = yes ; then
33511                 { { echo "$as_me:$LINENO: error: SLP not found" >&5
33512 echo "$as_me: error: SLP not found" >&2;}
33513    { (exit 1); exit 1; }; }
33514         fi
33515 fi
33516
33517
33518 echo "$as_me:$LINENO: checking for mode_t" >&5
33519 echo $ECHO_N "checking for mode_t... $ECHO_C" >&6
33520 if test "${ac_cv_type_mode_t+set}" = set; then
33521   echo $ECHO_N "(cached) $ECHO_C" >&6
33522 else
33523   cat >conftest.$ac_ext <<_ACEOF
33524 /* confdefs.h.  */
33525 _ACEOF
33526 cat confdefs.h >>conftest.$ac_ext
33527 cat >>conftest.$ac_ext <<_ACEOF
33528 /* end confdefs.h.  */
33529 $ac_includes_default
33530 int
33531 main ()
33532 {
33533 if ((mode_t *) 0)
33534   return 0;
33535 if (sizeof (mode_t))
33536   return 0;
33537   ;
33538   return 0;
33539 }
33540 _ACEOF
33541 rm -f conftest.$ac_objext
33542 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33543   (eval $ac_compile) 2>conftest.er1
33544   ac_status=$?
33545   grep -v '^ *+' conftest.er1 >conftest.err
33546   rm -f conftest.er1
33547   cat conftest.err >&5
33548   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33549   (exit $ac_status); } &&
33550          { ac_try='test -z "$ac_c_werror_flag"
33551                          || test ! -s conftest.err'
33552   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33553   (eval $ac_try) 2>&5
33554   ac_status=$?
33555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33556   (exit $ac_status); }; } &&
33557          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
33563   ac_cv_type_mode_t=yes
33564 else
33565   echo "$as_me: failed program was:" >&5
33566 sed 's/^/| /' conftest.$ac_ext >&5
33567
33568 ac_cv_type_mode_t=no
33569 fi
33570 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33571 fi
33572 echo "$as_me:$LINENO: result: $ac_cv_type_mode_t" >&5
33573 echo "${ECHO_T}$ac_cv_type_mode_t" >&6
33574 if test $ac_cv_type_mode_t = yes; then
33575   :
33576 else
33577
33578 cat >>confdefs.h <<_ACEOF
33579 #define mode_t int
33580 _ACEOF
33581
33582 fi
33583
33584 echo "$as_me:$LINENO: checking for off_t" >&5
33585 echo $ECHO_N "checking for off_t... $ECHO_C" >&6
33586 if test "${ac_cv_type_off_t+set}" = set; then
33587   echo $ECHO_N "(cached) $ECHO_C" >&6
33588 else
33589   cat >conftest.$ac_ext <<_ACEOF
33590 /* confdefs.h.  */
33591 _ACEOF
33592 cat confdefs.h >>conftest.$ac_ext
33593 cat >>conftest.$ac_ext <<_ACEOF
33594 /* end confdefs.h.  */
33595 $ac_includes_default
33596 int
33597 main ()
33598 {
33599 if ((off_t *) 0)
33600   return 0;
33601 if (sizeof (off_t))
33602   return 0;
33603   ;
33604   return 0;
33605 }
33606 _ACEOF
33607 rm -f conftest.$ac_objext
33608 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33609   (eval $ac_compile) 2>conftest.er1
33610   ac_status=$?
33611   grep -v '^ *+' conftest.er1 >conftest.err
33612   rm -f conftest.er1
33613   cat conftest.err >&5
33614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33615   (exit $ac_status); } &&
33616          { ac_try='test -z "$ac_c_werror_flag"
33617                          || test ! -s conftest.err'
33618   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33619   (eval $ac_try) 2>&5
33620   ac_status=$?
33621   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33622   (exit $ac_status); }; } &&
33623          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
33629   ac_cv_type_off_t=yes
33630 else
33631   echo "$as_me: failed program was:" >&5
33632 sed 's/^/| /' conftest.$ac_ext >&5
33633
33634 ac_cv_type_off_t=no
33635 fi
33636 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33637 fi
33638 echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
33639 echo "${ECHO_T}$ac_cv_type_off_t" >&6
33640 if test $ac_cv_type_off_t = yes; then
33641   :
33642 else
33643
33644 cat >>confdefs.h <<_ACEOF
33645 #define off_t long
33646 _ACEOF
33647
33648 fi
33649
33650 echo "$as_me:$LINENO: checking for pid_t" >&5
33651 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
33652 if test "${ac_cv_type_pid_t+set}" = set; then
33653   echo $ECHO_N "(cached) $ECHO_C" >&6
33654 else
33655   cat >conftest.$ac_ext <<_ACEOF
33656 /* confdefs.h.  */
33657 _ACEOF
33658 cat confdefs.h >>conftest.$ac_ext
33659 cat >>conftest.$ac_ext <<_ACEOF
33660 /* end confdefs.h.  */
33661 $ac_includes_default
33662 int
33663 main ()
33664 {
33665 if ((pid_t *) 0)
33666   return 0;
33667 if (sizeof (pid_t))
33668   return 0;
33669   ;
33670   return 0;
33671 }
33672 _ACEOF
33673 rm -f conftest.$ac_objext
33674 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33675   (eval $ac_compile) 2>conftest.er1
33676   ac_status=$?
33677   grep -v '^ *+' conftest.er1 >conftest.err
33678   rm -f conftest.er1
33679   cat conftest.err >&5
33680   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33681   (exit $ac_status); } &&
33682          { ac_try='test -z "$ac_c_werror_flag"
33683                          || test ! -s conftest.err'
33684   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33685   (eval $ac_try) 2>&5
33686   ac_status=$?
33687   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33688   (exit $ac_status); }; } &&
33689          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
33695   ac_cv_type_pid_t=yes
33696 else
33697   echo "$as_me: failed program was:" >&5
33698 sed 's/^/| /' conftest.$ac_ext >&5
33699
33700 ac_cv_type_pid_t=no
33701 fi
33702 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33703 fi
33704 echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
33705 echo "${ECHO_T}$ac_cv_type_pid_t" >&6
33706 if test $ac_cv_type_pid_t = yes; then
33707   :
33708 else
33709
33710 cat >>confdefs.h <<_ACEOF
33711 #define pid_t int
33712 _ACEOF
33713
33714 fi
33715
33716 echo "$as_me:$LINENO: checking for ssize_t" >&5
33717 echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6
33718 if test "${ac_cv_type_ssize_t+set}" = set; then
33719   echo $ECHO_N "(cached) $ECHO_C" >&6
33720 else
33721   cat >conftest.$ac_ext <<_ACEOF
33722 /* confdefs.h.  */
33723 _ACEOF
33724 cat confdefs.h >>conftest.$ac_ext
33725 cat >>conftest.$ac_ext <<_ACEOF
33726 /* end confdefs.h.  */
33727 $ac_includes_default
33728 int
33729 main ()
33730 {
33731 if ((ssize_t *) 0)
33732   return 0;
33733 if (sizeof (ssize_t))
33734   return 0;
33735   ;
33736   return 0;
33737 }
33738 _ACEOF
33739 rm -f conftest.$ac_objext
33740 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33741   (eval $ac_compile) 2>conftest.er1
33742   ac_status=$?
33743   grep -v '^ *+' conftest.er1 >conftest.err
33744   rm -f conftest.er1
33745   cat conftest.err >&5
33746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33747   (exit $ac_status); } &&
33748          { ac_try='test -z "$ac_c_werror_flag"
33749                          || test ! -s conftest.err'
33750   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33751   (eval $ac_try) 2>&5
33752   ac_status=$?
33753   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33754   (exit $ac_status); }; } &&
33755          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
33761   ac_cv_type_ssize_t=yes
33762 else
33763   echo "$as_me: failed program was:" >&5
33764 sed 's/^/| /' conftest.$ac_ext >&5
33765
33766 ac_cv_type_ssize_t=no
33767 fi
33768 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33769 fi
33770 echo "$as_me:$LINENO: result: $ac_cv_type_ssize_t" >&5
33771 echo "${ECHO_T}$ac_cv_type_ssize_t" >&6
33772 if test $ac_cv_type_ssize_t = yes; then
33773   :
33774 else
33775
33776 cat >>confdefs.h <<_ACEOF
33777 #define ssize_t signed int
33778 _ACEOF
33779
33780 fi
33781
33782 echo "$as_me:$LINENO: checking for caddr_t" >&5
33783 echo $ECHO_N "checking for caddr_t... $ECHO_C" >&6
33784 if test "${ac_cv_type_caddr_t+set}" = set; then
33785   echo $ECHO_N "(cached) $ECHO_C" >&6
33786 else
33787   cat >conftest.$ac_ext <<_ACEOF
33788 /* confdefs.h.  */
33789 _ACEOF
33790 cat confdefs.h >>conftest.$ac_ext
33791 cat >>conftest.$ac_ext <<_ACEOF
33792 /* end confdefs.h.  */
33793 $ac_includes_default
33794 int
33795 main ()
33796 {
33797 if ((caddr_t *) 0)
33798   return 0;
33799 if (sizeof (caddr_t))
33800   return 0;
33801   ;
33802   return 0;
33803 }
33804 _ACEOF
33805 rm -f conftest.$ac_objext
33806 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33807   (eval $ac_compile) 2>conftest.er1
33808   ac_status=$?
33809   grep -v '^ *+' conftest.er1 >conftest.err
33810   rm -f conftest.er1
33811   cat conftest.err >&5
33812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33813   (exit $ac_status); } &&
33814          { ac_try='test -z "$ac_c_werror_flag"
33815                          || test ! -s conftest.err'
33816   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33817   (eval $ac_try) 2>&5
33818   ac_status=$?
33819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33820   (exit $ac_status); }; } &&
33821          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
33827   ac_cv_type_caddr_t=yes
33828 else
33829   echo "$as_me: failed program was:" >&5
33830 sed 's/^/| /' conftest.$ac_ext >&5
33831
33832 ac_cv_type_caddr_t=no
33833 fi
33834 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33835 fi
33836 echo "$as_me:$LINENO: result: $ac_cv_type_caddr_t" >&5
33837 echo "${ECHO_T}$ac_cv_type_caddr_t" >&6
33838 if test $ac_cv_type_caddr_t = yes; then
33839   :
33840 else
33841
33842 cat >>confdefs.h <<_ACEOF
33843 #define caddr_t char *
33844 _ACEOF
33845
33846 fi
33847
33848 echo "$as_me:$LINENO: checking for size_t" >&5
33849 echo $ECHO_N "checking for size_t... $ECHO_C" >&6
33850 if test "${ac_cv_type_size_t+set}" = set; then
33851   echo $ECHO_N "(cached) $ECHO_C" >&6
33852 else
33853   cat >conftest.$ac_ext <<_ACEOF
33854 /* confdefs.h.  */
33855 _ACEOF
33856 cat confdefs.h >>conftest.$ac_ext
33857 cat >>conftest.$ac_ext <<_ACEOF
33858 /* end confdefs.h.  */
33859 $ac_includes_default
33860 int
33861 main ()
33862 {
33863 if ((size_t *) 0)
33864   return 0;
33865 if (sizeof (size_t))
33866   return 0;
33867   ;
33868   return 0;
33869 }
33870 _ACEOF
33871 rm -f conftest.$ac_objext
33872 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33873   (eval $ac_compile) 2>conftest.er1
33874   ac_status=$?
33875   grep -v '^ *+' conftest.er1 >conftest.err
33876   rm -f conftest.er1
33877   cat conftest.err >&5
33878   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33879   (exit $ac_status); } &&
33880          { ac_try='test -z "$ac_c_werror_flag"
33881                          || test ! -s conftest.err'
33882   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33883   (eval $ac_try) 2>&5
33884   ac_status=$?
33885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33886   (exit $ac_status); }; } &&
33887          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
33893   ac_cv_type_size_t=yes
33894 else
33895   echo "$as_me: failed program was:" >&5
33896 sed 's/^/| /' conftest.$ac_ext >&5
33897
33898 ac_cv_type_size_t=no
33899 fi
33900 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33901 fi
33902 echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
33903 echo "${ECHO_T}$ac_cv_type_size_t" >&6
33904 if test $ac_cv_type_size_t = yes; then
33905   :
33906 else
33907
33908 cat >>confdefs.h <<_ACEOF
33909 #define size_t unsigned
33910 _ACEOF
33911
33912 fi
33913
33914
33915 echo "$as_me:$LINENO: checking for long long" >&5
33916 echo $ECHO_N "checking for long long... $ECHO_C" >&6
33917 if test "${ac_cv_type_long_long+set}" = set; then
33918   echo $ECHO_N "(cached) $ECHO_C" >&6
33919 else
33920   cat >conftest.$ac_ext <<_ACEOF
33921 /* confdefs.h.  */
33922 _ACEOF
33923 cat confdefs.h >>conftest.$ac_ext
33924 cat >>conftest.$ac_ext <<_ACEOF
33925 /* end confdefs.h.  */
33926 $ac_includes_default
33927 int
33928 main ()
33929 {
33930 if ((long long *) 0)
33931   return 0;
33932 if (sizeof (long long))
33933   return 0;
33934   ;
33935   return 0;
33936 }
33937 _ACEOF
33938 rm -f conftest.$ac_objext
33939 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33940   (eval $ac_compile) 2>conftest.er1
33941   ac_status=$?
33942   grep -v '^ *+' conftest.er1 >conftest.err
33943   rm -f conftest.er1
33944   cat conftest.err >&5
33945   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33946   (exit $ac_status); } &&
33947          { ac_try='test -z "$ac_c_werror_flag"
33948                          || test ! -s conftest.err'
33949   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33950   (eval $ac_try) 2>&5
33951   ac_status=$?
33952   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33953   (exit $ac_status); }; } &&
33954          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
33960   ac_cv_type_long_long=yes
33961 else
33962   echo "$as_me: failed program was:" >&5
33963 sed 's/^/| /' conftest.$ac_ext >&5
33964
33965 ac_cv_type_long_long=no
33966 fi
33967 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33968 fi
33969 echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
33970 echo "${ECHO_T}$ac_cv_type_long_long" >&6
33971 if test $ac_cv_type_long_long = yes; then
33972
33973 cat >>confdefs.h <<_ACEOF
33974 #define HAVE_LONG_LONG 1
33975 _ACEOF
33976
33977
33978 fi
33979
33980 echo "$as_me:$LINENO: checking for ptrdiff_t" >&5
33981 echo $ECHO_N "checking for ptrdiff_t... $ECHO_C" >&6
33982 if test "${ac_cv_type_ptrdiff_t+set}" = set; then
33983   echo $ECHO_N "(cached) $ECHO_C" >&6
33984 else
33985   cat >conftest.$ac_ext <<_ACEOF
33986 /* confdefs.h.  */
33987 _ACEOF
33988 cat confdefs.h >>conftest.$ac_ext
33989 cat >>conftest.$ac_ext <<_ACEOF
33990 /* end confdefs.h.  */
33991 $ac_includes_default
33992 int
33993 main ()
33994 {
33995 if ((ptrdiff_t *) 0)
33996   return 0;
33997 if (sizeof (ptrdiff_t))
33998   return 0;
33999   ;
34000   return 0;
34001 }
34002 _ACEOF
34003 rm -f conftest.$ac_objext
34004 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34005   (eval $ac_compile) 2>conftest.er1
34006   ac_status=$?
34007   grep -v '^ *+' conftest.er1 >conftest.err
34008   rm -f conftest.er1
34009   cat conftest.err >&5
34010   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34011   (exit $ac_status); } &&
34012          { ac_try='test -z "$ac_c_werror_flag"
34013                          || test ! -s conftest.err'
34014   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34015   (eval $ac_try) 2>&5
34016   ac_status=$?
34017   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34018   (exit $ac_status); }; } &&
34019          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
34025   ac_cv_type_ptrdiff_t=yes
34026 else
34027   echo "$as_me: failed program was:" >&5
34028 sed 's/^/| /' conftest.$ac_ext >&5
34029
34030 ac_cv_type_ptrdiff_t=no
34031 fi
34032 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34033 fi
34034 echo "$as_me:$LINENO: result: $ac_cv_type_ptrdiff_t" >&5
34035 echo "${ECHO_T}$ac_cv_type_ptrdiff_t" >&6
34036 if test $ac_cv_type_ptrdiff_t = yes; then
34037
34038 cat >>confdefs.h <<_ACEOF
34039 #define HAVE_PTRDIFF_T 1
34040 _ACEOF
34041
34042
34043 fi
34044
34045
34046
34047 echo "$as_me:$LINENO: checking for socklen_t" >&5
34048 echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6
34049 if test "${ac_cv_type_socklen_t+set}" = set; then
34050   echo $ECHO_N "(cached) $ECHO_C" >&6
34051 else
34052   cat >conftest.$ac_ext <<_ACEOF
34053 /* confdefs.h.  */
34054 _ACEOF
34055 cat confdefs.h >>conftest.$ac_ext
34056 cat >>conftest.$ac_ext <<_ACEOF
34057 /* end confdefs.h.  */
34058 $ac_includes_default
34059 #ifdef HAVE_SYS_SOCKET_H
34060 #include <sys/socket.h>
34061 #endif
34062
34063 int
34064 main ()
34065 {
34066 if ((socklen_t *) 0)
34067   return 0;
34068 if (sizeof (socklen_t))
34069   return 0;
34070   ;
34071   return 0;
34072 }
34073 _ACEOF
34074 rm -f conftest.$ac_objext
34075 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34076   (eval $ac_compile) 2>conftest.er1
34077   ac_status=$?
34078   grep -v '^ *+' conftest.er1 >conftest.err
34079   rm -f conftest.er1
34080   cat conftest.err >&5
34081   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34082   (exit $ac_status); } &&
34083          { ac_try='test -z "$ac_c_werror_flag"
34084                          || test ! -s conftest.err'
34085   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34086   (eval $ac_try) 2>&5
34087   ac_status=$?
34088   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34089   (exit $ac_status); }; } &&
34090          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
34096   ac_cv_type_socklen_t=yes
34097 else
34098   echo "$as_me: failed program was:" >&5
34099 sed 's/^/| /' conftest.$ac_ext >&5
34100
34101 ac_cv_type_socklen_t=no
34102 fi
34103 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34104 fi
34105 echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5
34106 echo "${ECHO_T}$ac_cv_type_socklen_t" >&6
34107
34108
34109 echo "$as_me:$LINENO: checking the type of arg 3 to accept()" >&5
34110 echo $ECHO_N "checking the type of arg 3 to accept()... $ECHO_C" >&6
34111 if test "${ol_cv_type_ber_socklen_t+set}" = set; then
34112   echo $ECHO_N "(cached) $ECHO_C" >&6
34113 else
34114
34115         set socklen_t int unsigned "unsigned long" long size_t
34116         test "$ac_cv_type_socklen_t" = yes || shift
34117         ol_cv_type_ber_socklen_t=$1 guessing="guessing "
34118         for lentype in "$@" ; do for addrtype in "struct sockaddr" void ; do
34119                 cat >conftest.$ac_ext <<_ACEOF
34120 /* confdefs.h.  */
34121 _ACEOF
34122 cat confdefs.h >>conftest.$ac_ext
34123 cat >>conftest.$ac_ext <<_ACEOF
34124 /* end confdefs.h.  */
34125 $ac_includes_default
34126 #ifdef HAVE_SYS_SOCKET_H
34127 #include <sys/socket.h>
34128 #endif
34129 extern int accept(int s, $addrtype *ap, $lentype *lp);
34130
34131 int
34132 main ()
34133 {
34134
34135 accept(0, (struct sockaddr *) 0, ($lentype *) 0);
34136
34137   ;
34138   return 0;
34139 }
34140 _ACEOF
34141 rm -f conftest.$ac_objext
34142 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34143   (eval $ac_compile) 2>conftest.er1
34144   ac_status=$?
34145   grep -v '^ *+' conftest.er1 >conftest.err
34146   rm -f conftest.er1
34147   cat conftest.err >&5
34148   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34149   (exit $ac_status); } &&
34150          { ac_try='test -z "$ac_c_werror_flag"
34151                          || test ! -s conftest.err'
34152   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34153   (eval $ac_try) 2>&5
34154   ac_status=$?
34155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34156   (exit $ac_status); }; } &&
34157          { ac_try='test -s conftest.$ac_objext'
34158   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34159   (eval $ac_try) 2>&5
34160   ac_status=$?
34161   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34162   (exit $ac_status); }; }; then
34163   ol_cv_type_ber_socklen_t=$lentype guessing= ; break 2
34164 else
34165   echo "$as_me: failed program was:" >&5
34166 sed 's/^/| /' conftest.$ac_ext >&5
34167
34168 fi
34169 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34170         done ; done
34171 fi
34172
34173 echo "$as_me:$LINENO: result: $guessing$ol_cv_type_ber_socklen_t *" >&5
34174 echo "${ECHO_T}$guessing$ol_cv_type_ber_socklen_t *" >&6
34175
34176 cat >>confdefs.h <<_ACEOF
34177 #define ber_socklen_t $ol_cv_type_ber_socklen_t
34178 _ACEOF
34179
34180
34181 if test "$ac_cv_type_socklen_t" != yes; then
34182
34183 cat >>confdefs.h <<_ACEOF
34184 #define socklen_t $ol_cv_type_ber_socklen_t
34185 _ACEOF
34186
34187 fi
34188
34189
34190 echo "$as_me:$LINENO: checking return type of signal handlers" >&5
34191 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
34192 if test "${ac_cv_type_signal+set}" = set; then
34193   echo $ECHO_N "(cached) $ECHO_C" >&6
34194 else
34195   cat >conftest.$ac_ext <<_ACEOF
34196 /* confdefs.h.  */
34197 _ACEOF
34198 cat confdefs.h >>conftest.$ac_ext
34199 cat >>conftest.$ac_ext <<_ACEOF
34200 /* end confdefs.h.  */
34201 #include <sys/types.h>
34202 #include <signal.h>
34203 #ifdef signal
34204 # undef signal
34205 #endif
34206 #ifdef __cplusplus
34207 extern "C" void (*signal (int, void (*)(int)))(int);
34208 #else
34209 void (*signal ()) ();
34210 #endif
34211
34212 int
34213 main ()
34214 {
34215 int i;
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_signal=void
34243 else
34244   echo "$as_me: failed program was:" >&5
34245 sed 's/^/| /' conftest.$ac_ext >&5
34246
34247 ac_cv_type_signal=int
34248 fi
34249 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34250 fi
34251 echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
34252 echo "${ECHO_T}$ac_cv_type_signal" >&6
34253
34254 cat >>confdefs.h <<_ACEOF
34255 #define RETSIGTYPE $ac_cv_type_signal
34256 _ACEOF
34257
34258
34259
34260 echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
34261 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6
34262 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
34263   echo $ECHO_N "(cached) $ECHO_C" >&6
34264 else
34265   cat >conftest.$ac_ext <<_ACEOF
34266 /* confdefs.h.  */
34267 _ACEOF
34268 cat confdefs.h >>conftest.$ac_ext
34269 cat >>conftest.$ac_ext <<_ACEOF
34270 /* end confdefs.h.  */
34271 $ac_includes_default
34272 #include <signal.h>
34273
34274
34275 int
34276 main ()
34277 {
34278 if ((sig_atomic_t *) 0)
34279   return 0;
34280 if (sizeof (sig_atomic_t))
34281   return 0;
34282   ;
34283   return 0;
34284 }
34285 _ACEOF
34286 rm -f conftest.$ac_objext
34287 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34288   (eval $ac_compile) 2>conftest.er1
34289   ac_status=$?
34290   grep -v '^ *+' conftest.er1 >conftest.err
34291   rm -f conftest.er1
34292   cat conftest.err >&5
34293   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34294   (exit $ac_status); } &&
34295          { ac_try='test -z "$ac_c_werror_flag"
34296                          || test ! -s conftest.err'
34297   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34298   (eval $ac_try) 2>&5
34299   ac_status=$?
34300   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34301   (exit $ac_status); }; } &&
34302          { ac_try='test -s conftest.$ac_objext'
34303   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34304   (eval $ac_try) 2>&5
34305   ac_status=$?
34306   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34307   (exit $ac_status); }; }; then
34308   ac_cv_type_sig_atomic_t=yes
34309 else
34310   echo "$as_me: failed program was:" >&5
34311 sed 's/^/| /' conftest.$ac_ext >&5
34312
34313 ac_cv_type_sig_atomic_t=no
34314 fi
34315 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34316 fi
34317 echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
34318 echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6
34319 if test $ac_cv_type_sig_atomic_t = yes; then
34320   :
34321 else
34322
34323 cat >>confdefs.h <<_ACEOF
34324 #define sig_atomic_t int
34325 _ACEOF
34326
34327 fi
34328
34329
34330 echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5
34331 echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6
34332 if test "${ac_cv_type_uid_t+set}" = set; then
34333   echo $ECHO_N "(cached) $ECHO_C" >&6
34334 else
34335   cat >conftest.$ac_ext <<_ACEOF
34336 /* confdefs.h.  */
34337 _ACEOF
34338 cat confdefs.h >>conftest.$ac_ext
34339 cat >>conftest.$ac_ext <<_ACEOF
34340 /* end confdefs.h.  */
34341 #include <sys/types.h>
34342
34343 _ACEOF
34344 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34345   $EGREP "uid_t" >/dev/null 2>&1; then
34346   ac_cv_type_uid_t=yes
34347 else
34348   ac_cv_type_uid_t=no
34349 fi
34350 rm -f conftest*
34351
34352 fi
34353 echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5
34354 echo "${ECHO_T}$ac_cv_type_uid_t" >&6
34355 if test $ac_cv_type_uid_t = no; then
34356
34357 cat >>confdefs.h <<\_ACEOF
34358 #define uid_t int
34359 _ACEOF
34360
34361
34362 cat >>confdefs.h <<\_ACEOF
34363 #define gid_t int
34364 _ACEOF
34365
34366 fi
34367
34368
34369 echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
34370 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
34371 if test "${ac_cv_header_time+set}" = set; then
34372   echo $ECHO_N "(cached) $ECHO_C" >&6
34373 else
34374   cat >conftest.$ac_ext <<_ACEOF
34375 /* confdefs.h.  */
34376 _ACEOF
34377 cat confdefs.h >>conftest.$ac_ext
34378 cat >>conftest.$ac_ext <<_ACEOF
34379 /* end confdefs.h.  */
34380 #include <sys/types.h>
34381 #include <sys/time.h>
34382 #include <time.h>
34383
34384 int
34385 main ()
34386 {
34387 if ((struct tm *) 0)
34388 return 0;
34389   ;
34390   return 0;
34391 }
34392 _ACEOF
34393 rm -f conftest.$ac_objext
34394 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34395   (eval $ac_compile) 2>conftest.er1
34396   ac_status=$?
34397   grep -v '^ *+' conftest.er1 >conftest.err
34398   rm -f conftest.er1
34399   cat conftest.err >&5
34400   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34401   (exit $ac_status); } &&
34402          { ac_try='test -z "$ac_c_werror_flag"
34403                          || test ! -s conftest.err'
34404   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34405   (eval $ac_try) 2>&5
34406   ac_status=$?
34407   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34408   (exit $ac_status); }; } &&
34409          { ac_try='test -s conftest.$ac_objext'
34410   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34411   (eval $ac_try) 2>&5
34412   ac_status=$?
34413   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34414   (exit $ac_status); }; }; then
34415   ac_cv_header_time=yes
34416 else
34417   echo "$as_me: failed program was:" >&5
34418 sed 's/^/| /' conftest.$ac_ext >&5
34419
34420 ac_cv_header_time=no
34421 fi
34422 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34423 fi
34424 echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
34425 echo "${ECHO_T}$ac_cv_header_time" >&6
34426 if test $ac_cv_header_time = yes; then
34427
34428 cat >>confdefs.h <<\_ACEOF
34429 #define TIME_WITH_SYS_TIME 1
34430 _ACEOF
34431
34432 fi
34433
34434 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
34435 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
34436 if test "${ac_cv_struct_tm+set}" = set; then
34437   echo $ECHO_N "(cached) $ECHO_C" >&6
34438 else
34439   cat >conftest.$ac_ext <<_ACEOF
34440 /* confdefs.h.  */
34441 _ACEOF
34442 cat confdefs.h >>conftest.$ac_ext
34443 cat >>conftest.$ac_ext <<_ACEOF
34444 /* end confdefs.h.  */
34445 #include <sys/types.h>
34446 #include <time.h>
34447
34448 int
34449 main ()
34450 {
34451 struct tm *tp; tp->tm_sec;
34452   ;
34453   return 0;
34454 }
34455 _ACEOF
34456 rm -f conftest.$ac_objext
34457 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34458   (eval $ac_compile) 2>conftest.er1
34459   ac_status=$?
34460   grep -v '^ *+' conftest.er1 >conftest.err
34461   rm -f conftest.er1
34462   cat conftest.err >&5
34463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34464   (exit $ac_status); } &&
34465          { ac_try='test -z "$ac_c_werror_flag"
34466                          || test ! -s conftest.err'
34467   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34468   (eval $ac_try) 2>&5
34469   ac_status=$?
34470   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34471   (exit $ac_status); }; } &&
34472          { ac_try='test -s conftest.$ac_objext'
34473   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34474   (eval $ac_try) 2>&5
34475   ac_status=$?
34476   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34477   (exit $ac_status); }; }; then
34478   ac_cv_struct_tm=time.h
34479 else
34480   echo "$as_me: failed program was:" >&5
34481 sed 's/^/| /' conftest.$ac_ext >&5
34482
34483 ac_cv_struct_tm=sys/time.h
34484 fi
34485 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34486 fi
34487 echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
34488 echo "${ECHO_T}$ac_cv_struct_tm" >&6
34489 if test $ac_cv_struct_tm = sys/time.h; then
34490
34491 cat >>confdefs.h <<\_ACEOF
34492 #define TM_IN_SYS_TIME 1
34493 _ACEOF
34494
34495 fi
34496
34497 echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
34498 echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6
34499 if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
34500   echo $ECHO_N "(cached) $ECHO_C" >&6
34501 else
34502   cat >conftest.$ac_ext <<_ACEOF
34503 /* confdefs.h.  */
34504 _ACEOF
34505 cat confdefs.h >>conftest.$ac_ext
34506 cat >>conftest.$ac_ext <<_ACEOF
34507 /* end confdefs.h.  */
34508 $ac_includes_default
34509 int
34510 main ()
34511 {
34512 static struct stat ac_aggr;
34513 if (ac_aggr.st_blksize)
34514 return 0;
34515   ;
34516   return 0;
34517 }
34518 _ACEOF
34519 rm -f conftest.$ac_objext
34520 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34521   (eval $ac_compile) 2>conftest.er1
34522   ac_status=$?
34523   grep -v '^ *+' conftest.er1 >conftest.err
34524   rm -f conftest.er1
34525   cat conftest.err >&5
34526   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34527   (exit $ac_status); } &&
34528          { ac_try='test -z "$ac_c_werror_flag"
34529                          || test ! -s conftest.err'
34530   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34531   (eval $ac_try) 2>&5
34532   ac_status=$?
34533   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34534   (exit $ac_status); }; } &&
34535          { ac_try='test -s conftest.$ac_objext'
34536   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34537   (eval $ac_try) 2>&5
34538   ac_status=$?
34539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34540   (exit $ac_status); }; }; then
34541   ac_cv_member_struct_stat_st_blksize=yes
34542 else
34543   echo "$as_me: failed program was:" >&5
34544 sed 's/^/| /' conftest.$ac_ext >&5
34545
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 int
34554 main ()
34555 {
34556 static struct stat ac_aggr;
34557 if (sizeof ac_aggr.st_blksize)
34558 return 0;
34559   ;
34560   return 0;
34561 }
34562 _ACEOF
34563 rm -f conftest.$ac_objext
34564 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34565   (eval $ac_compile) 2>conftest.er1
34566   ac_status=$?
34567   grep -v '^ *+' conftest.er1 >conftest.err
34568   rm -f conftest.er1
34569   cat conftest.err >&5
34570   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34571   (exit $ac_status); } &&
34572          { ac_try='test -z "$ac_c_werror_flag"
34573                          || test ! -s conftest.err'
34574   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34575   (eval $ac_try) 2>&5
34576   ac_status=$?
34577   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34578   (exit $ac_status); }; } &&
34579          { ac_try='test -s conftest.$ac_objext'
34580   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34581   (eval $ac_try) 2>&5
34582   ac_status=$?
34583   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34584   (exit $ac_status); }; }; then
34585   ac_cv_member_struct_stat_st_blksize=yes
34586 else
34587   echo "$as_me: failed program was:" >&5
34588 sed 's/^/| /' conftest.$ac_ext >&5
34589
34590 ac_cv_member_struct_stat_st_blksize=no
34591 fi
34592 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34593 fi
34594 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34595 fi
34596 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
34597 echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6
34598 if test $ac_cv_member_struct_stat_st_blksize = yes; then
34599
34600 cat >>confdefs.h <<_ACEOF
34601 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
34602 _ACEOF
34603
34604
34605 fi
34606
34607 echo "$as_me:$LINENO: checking for struct passwd.pw_gecos" >&5
34608 echo $ECHO_N "checking for struct passwd.pw_gecos... $ECHO_C" >&6
34609 if test "${ac_cv_member_struct_passwd_pw_gecos+set}" = set; then
34610   echo $ECHO_N "(cached) $ECHO_C" >&6
34611 else
34612   cat >conftest.$ac_ext <<_ACEOF
34613 /* confdefs.h.  */
34614 _ACEOF
34615 cat confdefs.h >>conftest.$ac_ext
34616 cat >>conftest.$ac_ext <<_ACEOF
34617 /* end confdefs.h.  */
34618 $ac_includes_default
34619 #include <pwd.h>
34620
34621 int
34622 main ()
34623 {
34624 static struct passwd ac_aggr;
34625 if (ac_aggr.pw_gecos)
34626 return 0;
34627   ;
34628   return 0;
34629 }
34630 _ACEOF
34631 rm -f conftest.$ac_objext
34632 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34633   (eval $ac_compile) 2>conftest.er1
34634   ac_status=$?
34635   grep -v '^ *+' conftest.er1 >conftest.err
34636   rm -f conftest.er1
34637   cat conftest.err >&5
34638   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34639   (exit $ac_status); } &&
34640          { ac_try='test -z "$ac_c_werror_flag"
34641                          || test ! -s conftest.err'
34642   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34643   (eval $ac_try) 2>&5
34644   ac_status=$?
34645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34646   (exit $ac_status); }; } &&
34647          { ac_try='test -s conftest.$ac_objext'
34648   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34649   (eval $ac_try) 2>&5
34650   ac_status=$?
34651   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34652   (exit $ac_status); }; }; then
34653   ac_cv_member_struct_passwd_pw_gecos=yes
34654 else
34655   echo "$as_me: failed program was:" >&5
34656 sed 's/^/| /' conftest.$ac_ext >&5
34657
34658 cat >conftest.$ac_ext <<_ACEOF
34659 /* confdefs.h.  */
34660 _ACEOF
34661 cat confdefs.h >>conftest.$ac_ext
34662 cat >>conftest.$ac_ext <<_ACEOF
34663 /* end confdefs.h.  */
34664 $ac_includes_default
34665 #include <pwd.h>
34666
34667 int
34668 main ()
34669 {
34670 static struct passwd ac_aggr;
34671 if (sizeof ac_aggr.pw_gecos)
34672 return 0;
34673   ;
34674   return 0;
34675 }
34676 _ACEOF
34677 rm -f conftest.$ac_objext
34678 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34679   (eval $ac_compile) 2>conftest.er1
34680   ac_status=$?
34681   grep -v '^ *+' conftest.er1 >conftest.err
34682   rm -f conftest.er1
34683   cat conftest.err >&5
34684   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34685   (exit $ac_status); } &&
34686          { ac_try='test -z "$ac_c_werror_flag"
34687                          || test ! -s conftest.err'
34688   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34689   (eval $ac_try) 2>&5
34690   ac_status=$?
34691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34692   (exit $ac_status); }; } &&
34693          { ac_try='test -s conftest.$ac_objext'
34694   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34695   (eval $ac_try) 2>&5
34696   ac_status=$?
34697   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34698   (exit $ac_status); }; }; then
34699   ac_cv_member_struct_passwd_pw_gecos=yes
34700 else
34701   echo "$as_me: failed program was:" >&5
34702 sed 's/^/| /' conftest.$ac_ext >&5
34703
34704 ac_cv_member_struct_passwd_pw_gecos=no
34705 fi
34706 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34707 fi
34708 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34709 fi
34710 echo "$as_me:$LINENO: result: $ac_cv_member_struct_passwd_pw_gecos" >&5
34711 echo "${ECHO_T}$ac_cv_member_struct_passwd_pw_gecos" >&6
34712 if test $ac_cv_member_struct_passwd_pw_gecos = yes; then
34713
34714 cat >>confdefs.h <<_ACEOF
34715 #define HAVE_STRUCT_PASSWD_PW_GECOS 1
34716 _ACEOF
34717
34718
34719 fi
34720
34721 echo "$as_me:$LINENO: checking for struct passwd.pw_passwd" >&5
34722 echo $ECHO_N "checking for struct passwd.pw_passwd... $ECHO_C" >&6
34723 if test "${ac_cv_member_struct_passwd_pw_passwd+set}" = set; then
34724   echo $ECHO_N "(cached) $ECHO_C" >&6
34725 else
34726   cat >conftest.$ac_ext <<_ACEOF
34727 /* confdefs.h.  */
34728 _ACEOF
34729 cat confdefs.h >>conftest.$ac_ext
34730 cat >>conftest.$ac_ext <<_ACEOF
34731 /* end confdefs.h.  */
34732 $ac_includes_default
34733 #include <pwd.h>
34734
34735 int
34736 main ()
34737 {
34738 static struct passwd ac_aggr;
34739 if (ac_aggr.pw_passwd)
34740 return 0;
34741   ;
34742   return 0;
34743 }
34744 _ACEOF
34745 rm -f conftest.$ac_objext
34746 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34747   (eval $ac_compile) 2>conftest.er1
34748   ac_status=$?
34749   grep -v '^ *+' conftest.er1 >conftest.err
34750   rm -f conftest.er1
34751   cat conftest.err >&5
34752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34753   (exit $ac_status); } &&
34754          { ac_try='test -z "$ac_c_werror_flag"
34755                          || test ! -s conftest.err'
34756   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34757   (eval $ac_try) 2>&5
34758   ac_status=$?
34759   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34760   (exit $ac_status); }; } &&
34761          { ac_try='test -s conftest.$ac_objext'
34762   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34763   (eval $ac_try) 2>&5
34764   ac_status=$?
34765   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34766   (exit $ac_status); }; }; then
34767   ac_cv_member_struct_passwd_pw_passwd=yes
34768 else
34769   echo "$as_me: failed program was:" >&5
34770 sed 's/^/| /' conftest.$ac_ext >&5
34771
34772 cat >conftest.$ac_ext <<_ACEOF
34773 /* confdefs.h.  */
34774 _ACEOF
34775 cat confdefs.h >>conftest.$ac_ext
34776 cat >>conftest.$ac_ext <<_ACEOF
34777 /* end confdefs.h.  */
34778 $ac_includes_default
34779 #include <pwd.h>
34780
34781 int
34782 main ()
34783 {
34784 static struct passwd ac_aggr;
34785 if (sizeof ac_aggr.pw_passwd)
34786 return 0;
34787   ;
34788   return 0;
34789 }
34790 _ACEOF
34791 rm -f conftest.$ac_objext
34792 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34793   (eval $ac_compile) 2>conftest.er1
34794   ac_status=$?
34795   grep -v '^ *+' conftest.er1 >conftest.err
34796   rm -f conftest.er1
34797   cat conftest.err >&5
34798   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34799   (exit $ac_status); } &&
34800          { ac_try='test -z "$ac_c_werror_flag"
34801                          || test ! -s conftest.err'
34802   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34803   (eval $ac_try) 2>&5
34804   ac_status=$?
34805   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34806   (exit $ac_status); }; } &&
34807          { ac_try='test -s conftest.$ac_objext'
34808   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34809   (eval $ac_try) 2>&5
34810   ac_status=$?
34811   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34812   (exit $ac_status); }; }; then
34813   ac_cv_member_struct_passwd_pw_passwd=yes
34814 else
34815   echo "$as_me: failed program was:" >&5
34816 sed 's/^/| /' conftest.$ac_ext >&5
34817
34818 ac_cv_member_struct_passwd_pw_passwd=no
34819 fi
34820 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34821 fi
34822 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34823 fi
34824 echo "$as_me:$LINENO: result: $ac_cv_member_struct_passwd_pw_passwd" >&5
34825 echo "${ECHO_T}$ac_cv_member_struct_passwd_pw_passwd" >&6
34826 if test $ac_cv_member_struct_passwd_pw_passwd = yes; then
34827
34828 cat >>confdefs.h <<_ACEOF
34829 #define HAVE_STRUCT_PASSWD_PW_PASSWD 1
34830 _ACEOF
34831
34832
34833 fi
34834
34835
34836 echo "$as_me:$LINENO: checking if toupper() requires islower()" >&5
34837 echo $ECHO_N "checking if toupper() requires islower()... $ECHO_C" >&6
34838 if test "${ol_cv_c_upper_lower+set}" = set; then
34839   echo $ECHO_N "(cached) $ECHO_C" >&6
34840 else
34841
34842         if test "$cross_compiling" = yes; then
34843   ol_cv_c_upper_lower=safe
34844 else
34845   cat >conftest.$ac_ext <<_ACEOF
34846 /* confdefs.h.  */
34847 _ACEOF
34848 cat confdefs.h >>conftest.$ac_ext
34849 cat >>conftest.$ac_ext <<_ACEOF
34850 /* end confdefs.h.  */
34851
34852 #include <ctype.h>
34853 main()
34854 {
34855         if ('C' == toupper('C'))
34856                 exit(0);
34857         else
34858                 exit(1);
34859 }
34860 _ACEOF
34861 rm -f conftest$ac_exeext
34862 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
34863   (eval $ac_link) 2>&5
34864   ac_status=$?
34865   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34866   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
34867   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34868   (eval $ac_try) 2>&5
34869   ac_status=$?
34870   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34871   (exit $ac_status); }; }; then
34872   ol_cv_c_upper_lower=no
34873 else
34874   echo "$as_me: program exited with status $ac_status" >&5
34875 echo "$as_me: failed program was:" >&5
34876 sed 's/^/| /' conftest.$ac_ext >&5
34877
34878 ( exit $ac_status )
34879 ol_cv_c_upper_lower=yes
34880 fi
34881 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
34882 fi
34883 fi
34884 echo "$as_me:$LINENO: result: $ol_cv_c_upper_lower" >&5
34885 echo "${ECHO_T}$ol_cv_c_upper_lower" >&6
34886 if test $ol_cv_c_upper_lower != no ; then
34887
34888 cat >>confdefs.h <<\_ACEOF
34889 #define C_UPPER_LOWER 1
34890 _ACEOF
34891
34892 fi
34893
34894 echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
34895 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
34896 if test "${ac_cv_c_const+set}" = set; then
34897   echo $ECHO_N "(cached) $ECHO_C" >&6
34898 else
34899   cat >conftest.$ac_ext <<_ACEOF
34900 /* confdefs.h.  */
34901 _ACEOF
34902 cat confdefs.h >>conftest.$ac_ext
34903 cat >>conftest.$ac_ext <<_ACEOF
34904 /* end confdefs.h.  */
34905
34906 int
34907 main ()
34908 {
34909 /* FIXME: Include the comments suggested by Paul. */
34910 #ifndef __cplusplus
34911   /* Ultrix mips cc rejects this.  */
34912   typedef int charset[2];
34913   const charset x;
34914   /* SunOS 4.1.1 cc rejects this.  */
34915   char const *const *ccp;
34916   char **p;
34917   /* NEC SVR4.0.2 mips cc rejects this.  */
34918   struct point {int x, y;};
34919   static struct point const zero = {0,0};
34920   /* AIX XL C 1.02.0.0 rejects this.
34921      It does not let you subtract one const X* pointer from another in
34922      an arm of an if-expression whose if-part is not a constant
34923      expression */
34924   const char *g = "string";
34925   ccp = &g + (g ? g-g : 0);
34926   /* HPUX 7.0 cc rejects these. */
34927   ++ccp;
34928   p = (char**) ccp;
34929   ccp = (char const *const *) p;
34930   { /* SCO 3.2v4 cc rejects this.  */
34931     char *t;
34932     char const *s = 0 ? (char *) 0 : (char const *) 0;
34933
34934     *t++ = 0;
34935   }
34936   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
34937     int x[] = {25, 17};
34938     const int *foo = &x[0];
34939     ++foo;
34940   }
34941   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
34942     typedef const int *iptr;
34943     iptr p = 0;
34944     ++p;
34945   }
34946   { /* AIX XL C 1.02.0.0 rejects this saying
34947        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
34948     struct s { int j; const int *ap[3]; };
34949     struct s *b; b->j = 5;
34950   }
34951   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
34952     const int foo = 10;
34953   }
34954 #endif
34955
34956   ;
34957   return 0;
34958 }
34959 _ACEOF
34960 rm -f conftest.$ac_objext
34961 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34962   (eval $ac_compile) 2>conftest.er1
34963   ac_status=$?
34964   grep -v '^ *+' conftest.er1 >conftest.err
34965   rm -f conftest.er1
34966   cat conftest.err >&5
34967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34968   (exit $ac_status); } &&
34969          { ac_try='test -z "$ac_c_werror_flag"
34970                          || test ! -s conftest.err'
34971   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34972   (eval $ac_try) 2>&5
34973   ac_status=$?
34974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34975   (exit $ac_status); }; } &&
34976          { ac_try='test -s conftest.$ac_objext'
34977   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34978   (eval $ac_try) 2>&5
34979   ac_status=$?
34980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34981   (exit $ac_status); }; }; then
34982   ac_cv_c_const=yes
34983 else
34984   echo "$as_me: failed program was:" >&5
34985 sed 's/^/| /' conftest.$ac_ext >&5
34986
34987 ac_cv_c_const=no
34988 fi
34989 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34990 fi
34991 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
34992 echo "${ECHO_T}$ac_cv_c_const" >&6
34993 if test $ac_cv_c_const = no; then
34994
34995 cat >>confdefs.h <<\_ACEOF
34996 #define const
34997 _ACEOF
34998
34999 fi
35000
35001 echo "$as_me:$LINENO: checking if compiler understands volatile" >&5
35002 echo $ECHO_N "checking if compiler understands volatile... $ECHO_C" >&6
35003 if test "${ol_cv_c_volatile+set}" = set; then
35004   echo $ECHO_N "(cached) $ECHO_C" >&6
35005 else
35006   cat >conftest.$ac_ext <<_ACEOF
35007 /* confdefs.h.  */
35008 _ACEOF
35009 cat confdefs.h >>conftest.$ac_ext
35010 cat >>conftest.$ac_ext <<_ACEOF
35011 /* end confdefs.h.  */
35012 int x, y, z;
35013 int
35014 main ()
35015 {
35016 volatile int a; int * volatile b = x ? &y : &z;
35017       /* Older MIPS compilers (eg., in Ultrix 4.2) don't like *b = 0 */
35018       *b = 0;
35019   ;
35020   return 0;
35021 }
35022 _ACEOF
35023 rm -f conftest.$ac_objext
35024 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35025   (eval $ac_compile) 2>conftest.er1
35026   ac_status=$?
35027   grep -v '^ *+' conftest.er1 >conftest.err
35028   rm -f conftest.er1
35029   cat conftest.err >&5
35030   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35031   (exit $ac_status); } &&
35032          { ac_try='test -z "$ac_c_werror_flag"
35033                          || test ! -s conftest.err'
35034   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35035   (eval $ac_try) 2>&5
35036   ac_status=$?
35037   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35038   (exit $ac_status); }; } &&
35039          { ac_try='test -s conftest.$ac_objext'
35040   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35041   (eval $ac_try) 2>&5
35042   ac_status=$?
35043   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35044   (exit $ac_status); }; }; then
35045   ol_cv_c_volatile=yes
35046 else
35047   echo "$as_me: failed program was:" >&5
35048 sed 's/^/| /' conftest.$ac_ext >&5
35049
35050 ol_cv_c_volatile=no
35051 fi
35052 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35053 fi
35054 echo "$as_me:$LINENO: result: $ol_cv_c_volatile" >&5
35055 echo "${ECHO_T}$ol_cv_c_volatile" >&6
35056   if test $ol_cv_c_volatile = yes; then
35057     :
35058   else
35059
35060 cat >>confdefs.h <<\_ACEOF
35061 #define volatile
35062 _ACEOF
35063
35064   fi
35065
35066
35067 if test $cross_compiling = yes ; then
35068         { echo "$as_me:$LINENO: WARNING: Crossing compiling... all bets are off!" >&5
35069 echo "$as_me: WARNING: Crossing compiling... all bets are off!" >&2;}
35070
35071 cat >>confdefs.h <<\_ACEOF
35072 #define CROSS_COMPILING 1
35073 _ACEOF
35074
35075 else
35076         echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
35077 echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
35078 if test "${ac_cv_c_bigendian+set}" = set; then
35079   echo $ECHO_N "(cached) $ECHO_C" >&6
35080 else
35081   # See if sys/param.h defines the BYTE_ORDER macro.
35082 cat >conftest.$ac_ext <<_ACEOF
35083 /* confdefs.h.  */
35084 _ACEOF
35085 cat confdefs.h >>conftest.$ac_ext
35086 cat >>conftest.$ac_ext <<_ACEOF
35087 /* end confdefs.h.  */
35088 #include <sys/types.h>
35089 #include <sys/param.h>
35090
35091 int
35092 main ()
35093 {
35094 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
35095  bogus endian macros
35096 #endif
35097
35098   ;
35099   return 0;
35100 }
35101 _ACEOF
35102 rm -f conftest.$ac_objext
35103 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35104   (eval $ac_compile) 2>conftest.er1
35105   ac_status=$?
35106   grep -v '^ *+' conftest.er1 >conftest.err
35107   rm -f conftest.er1
35108   cat conftest.err >&5
35109   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35110   (exit $ac_status); } &&
35111          { ac_try='test -z "$ac_c_werror_flag"
35112                          || test ! -s conftest.err'
35113   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35114   (eval $ac_try) 2>&5
35115   ac_status=$?
35116   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35117   (exit $ac_status); }; } &&
35118          { ac_try='test -s conftest.$ac_objext'
35119   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35120   (eval $ac_try) 2>&5
35121   ac_status=$?
35122   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35123   (exit $ac_status); }; }; then
35124   # It does; now see whether it defined to BIG_ENDIAN or not.
35125 cat >conftest.$ac_ext <<_ACEOF
35126 /* confdefs.h.  */
35127 _ACEOF
35128 cat confdefs.h >>conftest.$ac_ext
35129 cat >>conftest.$ac_ext <<_ACEOF
35130 /* end confdefs.h.  */
35131 #include <sys/types.h>
35132 #include <sys/param.h>
35133
35134 int
35135 main ()
35136 {
35137 #if BYTE_ORDER != BIG_ENDIAN
35138  not big endian
35139 #endif
35140
35141   ;
35142   return 0;
35143 }
35144 _ACEOF
35145 rm -f conftest.$ac_objext
35146 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35147   (eval $ac_compile) 2>conftest.er1
35148   ac_status=$?
35149   grep -v '^ *+' conftest.er1 >conftest.err
35150   rm -f conftest.er1
35151   cat conftest.err >&5
35152   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35153   (exit $ac_status); } &&
35154          { ac_try='test -z "$ac_c_werror_flag"
35155                          || test ! -s conftest.err'
35156   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35157   (eval $ac_try) 2>&5
35158   ac_status=$?
35159   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35160   (exit $ac_status); }; } &&
35161          { ac_try='test -s conftest.$ac_objext'
35162   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35163   (eval $ac_try) 2>&5
35164   ac_status=$?
35165   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35166   (exit $ac_status); }; }; then
35167   ac_cv_c_bigendian=yes
35168 else
35169   echo "$as_me: failed program was:" >&5
35170 sed 's/^/| /' conftest.$ac_ext >&5
35171
35172 ac_cv_c_bigendian=no
35173 fi
35174 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35175 else
35176   echo "$as_me: failed program was:" >&5
35177 sed 's/^/| /' conftest.$ac_ext >&5
35178
35179 # It does not; compile a test program.
35180 if test "$cross_compiling" = yes; then
35181   # try to guess the endianness by grepping values into an object file
35182   ac_cv_c_bigendian=unknown
35183   cat >conftest.$ac_ext <<_ACEOF
35184 /* confdefs.h.  */
35185 _ACEOF
35186 cat confdefs.h >>conftest.$ac_ext
35187 cat >>conftest.$ac_ext <<_ACEOF
35188 /* end confdefs.h.  */
35189 short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
35190 short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
35191 void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
35192 short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
35193 short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
35194 void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
35195 int
35196 main ()
35197 {
35198  _ascii (); _ebcdic ();
35199   ;
35200   return 0;
35201 }
35202 _ACEOF
35203 rm -f conftest.$ac_objext
35204 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35205   (eval $ac_compile) 2>conftest.er1
35206   ac_status=$?
35207   grep -v '^ *+' conftest.er1 >conftest.err
35208   rm -f conftest.er1
35209   cat conftest.err >&5
35210   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35211   (exit $ac_status); } &&
35212          { ac_try='test -z "$ac_c_werror_flag"
35213                          || test ! -s conftest.err'
35214   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35215   (eval $ac_try) 2>&5
35216   ac_status=$?
35217   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35218   (exit $ac_status); }; } &&
35219          { ac_try='test -s conftest.$ac_objext'
35220   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35221   (eval $ac_try) 2>&5
35222   ac_status=$?
35223   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35224   (exit $ac_status); }; }; then
35225   if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
35226   ac_cv_c_bigendian=yes
35227 fi
35228 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
35229   if test "$ac_cv_c_bigendian" = unknown; then
35230     ac_cv_c_bigendian=no
35231   else
35232     # finding both strings is unlikely to happen, but who knows?
35233     ac_cv_c_bigendian=unknown
35234   fi
35235 fi
35236 else
35237   echo "$as_me: failed program was:" >&5
35238 sed 's/^/| /' conftest.$ac_ext >&5
35239
35240 fi
35241 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35242 else
35243   cat >conftest.$ac_ext <<_ACEOF
35244 /* confdefs.h.  */
35245 _ACEOF
35246 cat confdefs.h >>conftest.$ac_ext
35247 cat >>conftest.$ac_ext <<_ACEOF
35248 /* end confdefs.h.  */
35249 int
35250 main ()
35251 {
35252   /* Are we little or big endian?  From Harbison&Steele.  */
35253   union
35254   {
35255     long l;
35256     char c[sizeof (long)];
35257   } u;
35258   u.l = 1;
35259   exit (u.c[sizeof (long) - 1] == 1);
35260 }
35261 _ACEOF
35262 rm -f conftest$ac_exeext
35263 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35264   (eval $ac_link) 2>&5
35265   ac_status=$?
35266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35267   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
35268   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35269   (eval $ac_try) 2>&5
35270   ac_status=$?
35271   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35272   (exit $ac_status); }; }; then
35273   ac_cv_c_bigendian=no
35274 else
35275   echo "$as_me: program exited with status $ac_status" >&5
35276 echo "$as_me: failed program was:" >&5
35277 sed 's/^/| /' conftest.$ac_ext >&5
35278
35279 ( exit $ac_status )
35280 ac_cv_c_bigendian=yes
35281 fi
35282 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
35283 fi
35284 fi
35285 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35286 fi
35287 echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
35288 echo "${ECHO_T}$ac_cv_c_bigendian" >&6
35289 case $ac_cv_c_bigendian in
35290   yes)
35291
35292 cat >>confdefs.h <<\_ACEOF
35293 #define WORDS_BIGENDIAN 1
35294 _ACEOF
35295  ;;
35296   no)
35297      ;;
35298   *)
35299     { { echo "$as_me:$LINENO: error: unknown endianness
35300 presetting ac_cv_c_bigendian=no (or yes) will help" >&5
35301 echo "$as_me: error: unknown endianness
35302 presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
35303    { (exit 1); exit 1; }; } ;;
35304 esac
35305
35306 fi
35307
35308 echo "$as_me:$LINENO: checking for short" >&5
35309 echo $ECHO_N "checking for short... $ECHO_C" >&6
35310 if test "${ac_cv_type_short+set}" = set; then
35311   echo $ECHO_N "(cached) $ECHO_C" >&6
35312 else
35313   cat >conftest.$ac_ext <<_ACEOF
35314 /* confdefs.h.  */
35315 _ACEOF
35316 cat confdefs.h >>conftest.$ac_ext
35317 cat >>conftest.$ac_ext <<_ACEOF
35318 /* end confdefs.h.  */
35319 $ac_includes_default
35320 int
35321 main ()
35322 {
35323 if ((short *) 0)
35324   return 0;
35325 if (sizeof (short))
35326   return 0;
35327   ;
35328   return 0;
35329 }
35330 _ACEOF
35331 rm -f conftest.$ac_objext
35332 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35333   (eval $ac_compile) 2>conftest.er1
35334   ac_status=$?
35335   grep -v '^ *+' conftest.er1 >conftest.err
35336   rm -f conftest.er1
35337   cat conftest.err >&5
35338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35339   (exit $ac_status); } &&
35340          { ac_try='test -z "$ac_c_werror_flag"
35341                          || test ! -s conftest.err'
35342   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35343   (eval $ac_try) 2>&5
35344   ac_status=$?
35345   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35346   (exit $ac_status); }; } &&
35347          { ac_try='test -s conftest.$ac_objext'
35348   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35349   (eval $ac_try) 2>&5
35350   ac_status=$?
35351   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35352   (exit $ac_status); }; }; then
35353   ac_cv_type_short=yes
35354 else
35355   echo "$as_me: failed program was:" >&5
35356 sed 's/^/| /' conftest.$ac_ext >&5
35357
35358 ac_cv_type_short=no
35359 fi
35360 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35361 fi
35362 echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
35363 echo "${ECHO_T}$ac_cv_type_short" >&6
35364
35365 echo "$as_me:$LINENO: checking size of short" >&5
35366 echo $ECHO_N "checking size of short... $ECHO_C" >&6
35367 if test "${ac_cv_sizeof_short+set}" = set; then
35368   echo $ECHO_N "(cached) $ECHO_C" >&6
35369 else
35370   if test "$ac_cv_type_short" = yes; then
35371   # The cast to unsigned long works around a bug in the HP C Compiler
35372   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
35373   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
35374   # This bug is HP SR number 8606223364.
35375   if test "$cross_compiling" = yes; then
35376   # Depending upon the size, compute the lo and hi bounds.
35377 cat >conftest.$ac_ext <<_ACEOF
35378 /* confdefs.h.  */
35379 _ACEOF
35380 cat confdefs.h >>conftest.$ac_ext
35381 cat >>conftest.$ac_ext <<_ACEOF
35382 /* end confdefs.h.  */
35383 $ac_includes_default
35384 int
35385 main ()
35386 {
35387 static int test_array [1 - 2 * !(((long) (sizeof (short))) >= 0)];
35388 test_array [0] = 0
35389
35390   ;
35391   return 0;
35392 }
35393 _ACEOF
35394 rm -f conftest.$ac_objext
35395 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35396   (eval $ac_compile) 2>conftest.er1
35397   ac_status=$?
35398   grep -v '^ *+' conftest.er1 >conftest.err
35399   rm -f conftest.er1
35400   cat conftest.err >&5
35401   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35402   (exit $ac_status); } &&
35403          { ac_try='test -z "$ac_c_werror_flag"
35404                          || test ! -s conftest.err'
35405   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35406   (eval $ac_try) 2>&5
35407   ac_status=$?
35408   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35409   (exit $ac_status); }; } &&
35410          { ac_try='test -s conftest.$ac_objext'
35411   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35412   (eval $ac_try) 2>&5
35413   ac_status=$?
35414   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35415   (exit $ac_status); }; }; then
35416   ac_lo=0 ac_mid=0
35417   while :; do
35418     cat >conftest.$ac_ext <<_ACEOF
35419 /* confdefs.h.  */
35420 _ACEOF
35421 cat confdefs.h >>conftest.$ac_ext
35422 cat >>conftest.$ac_ext <<_ACEOF
35423 /* end confdefs.h.  */
35424 $ac_includes_default
35425 int
35426 main ()
35427 {
35428 static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
35429 test_array [0] = 0
35430
35431   ;
35432   return 0;
35433 }
35434 _ACEOF
35435 rm -f conftest.$ac_objext
35436 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35437   (eval $ac_compile) 2>conftest.er1
35438   ac_status=$?
35439   grep -v '^ *+' conftest.er1 >conftest.err
35440   rm -f conftest.er1
35441   cat conftest.err >&5
35442   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35443   (exit $ac_status); } &&
35444          { ac_try='test -z "$ac_c_werror_flag"
35445                          || test ! -s conftest.err'
35446   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35447   (eval $ac_try) 2>&5
35448   ac_status=$?
35449   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35450   (exit $ac_status); }; } &&
35451          { ac_try='test -s conftest.$ac_objext'
35452   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35453   (eval $ac_try) 2>&5
35454   ac_status=$?
35455   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35456   (exit $ac_status); }; }; then
35457   ac_hi=$ac_mid; break
35458 else
35459   echo "$as_me: failed program was:" >&5
35460 sed 's/^/| /' conftest.$ac_ext >&5
35461
35462 ac_lo=`expr $ac_mid + 1`
35463                     if test $ac_lo -le $ac_mid; then
35464                       ac_lo= ac_hi=
35465                       break
35466                     fi
35467                     ac_mid=`expr 2 '*' $ac_mid + 1`
35468 fi
35469 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35470   done
35471 else
35472   echo "$as_me: failed program was:" >&5
35473 sed 's/^/| /' conftest.$ac_ext >&5
35474
35475 cat >conftest.$ac_ext <<_ACEOF
35476 /* confdefs.h.  */
35477 _ACEOF
35478 cat confdefs.h >>conftest.$ac_ext
35479 cat >>conftest.$ac_ext <<_ACEOF
35480 /* end confdefs.h.  */
35481 $ac_includes_default
35482 int
35483 main ()
35484 {
35485 static int test_array [1 - 2 * !(((long) (sizeof (short))) < 0)];
35486 test_array [0] = 0
35487
35488   ;
35489   return 0;
35490 }
35491 _ACEOF
35492 rm -f conftest.$ac_objext
35493 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35494   (eval $ac_compile) 2>conftest.er1
35495   ac_status=$?
35496   grep -v '^ *+' conftest.er1 >conftest.err
35497   rm -f conftest.er1
35498   cat conftest.err >&5
35499   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35500   (exit $ac_status); } &&
35501          { ac_try='test -z "$ac_c_werror_flag"
35502                          || test ! -s conftest.err'
35503   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35504   (eval $ac_try) 2>&5
35505   ac_status=$?
35506   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35507   (exit $ac_status); }; } &&
35508          { ac_try='test -s conftest.$ac_objext'
35509   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35510   (eval $ac_try) 2>&5
35511   ac_status=$?
35512   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35513   (exit $ac_status); }; }; then
35514   ac_hi=-1 ac_mid=-1
35515   while :; do
35516     cat >conftest.$ac_ext <<_ACEOF
35517 /* confdefs.h.  */
35518 _ACEOF
35519 cat confdefs.h >>conftest.$ac_ext
35520 cat >>conftest.$ac_ext <<_ACEOF
35521 /* end confdefs.h.  */
35522 $ac_includes_default
35523 int
35524 main ()
35525 {
35526 static int test_array [1 - 2 * !(((long) (sizeof (short))) >= $ac_mid)];
35527 test_array [0] = 0
35528
35529   ;
35530   return 0;
35531 }
35532 _ACEOF
35533 rm -f conftest.$ac_objext
35534 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35535   (eval $ac_compile) 2>conftest.er1
35536   ac_status=$?
35537   grep -v '^ *+' conftest.er1 >conftest.err
35538   rm -f conftest.er1
35539   cat conftest.err >&5
35540   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35541   (exit $ac_status); } &&
35542          { ac_try='test -z "$ac_c_werror_flag"
35543                          || test ! -s conftest.err'
35544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35545   (eval $ac_try) 2>&5
35546   ac_status=$?
35547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35548   (exit $ac_status); }; } &&
35549          { ac_try='test -s conftest.$ac_objext'
35550   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35551   (eval $ac_try) 2>&5
35552   ac_status=$?
35553   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35554   (exit $ac_status); }; }; then
35555   ac_lo=$ac_mid; break
35556 else
35557   echo "$as_me: failed program was:" >&5
35558 sed 's/^/| /' conftest.$ac_ext >&5
35559
35560 ac_hi=`expr '(' $ac_mid ')' - 1`
35561                        if test $ac_mid -le $ac_hi; then
35562                          ac_lo= ac_hi=
35563                          break
35564                        fi
35565                        ac_mid=`expr 2 '*' $ac_mid`
35566 fi
35567 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35568   done
35569 else
35570   echo "$as_me: failed program was:" >&5
35571 sed 's/^/| /' conftest.$ac_ext >&5
35572
35573 ac_lo= ac_hi=
35574 fi
35575 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35576 fi
35577 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35578 # Binary search between lo and hi bounds.
35579 while test "x$ac_lo" != "x$ac_hi"; do
35580   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
35581   cat >conftest.$ac_ext <<_ACEOF
35582 /* confdefs.h.  */
35583 _ACEOF
35584 cat confdefs.h >>conftest.$ac_ext
35585 cat >>conftest.$ac_ext <<_ACEOF
35586 /* end confdefs.h.  */
35587 $ac_includes_default
35588 int
35589 main ()
35590 {
35591 static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
35592 test_array [0] = 0
35593
35594   ;
35595   return 0;
35596 }
35597 _ACEOF
35598 rm -f conftest.$ac_objext
35599 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35600   (eval $ac_compile) 2>conftest.er1
35601   ac_status=$?
35602   grep -v '^ *+' conftest.er1 >conftest.err
35603   rm -f conftest.er1
35604   cat conftest.err >&5
35605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35606   (exit $ac_status); } &&
35607          { ac_try='test -z "$ac_c_werror_flag"
35608                          || test ! -s conftest.err'
35609   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35610   (eval $ac_try) 2>&5
35611   ac_status=$?
35612   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35613   (exit $ac_status); }; } &&
35614          { ac_try='test -s conftest.$ac_objext'
35615   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35616   (eval $ac_try) 2>&5
35617   ac_status=$?
35618   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35619   (exit $ac_status); }; }; then
35620   ac_hi=$ac_mid
35621 else
35622   echo "$as_me: failed program was:" >&5
35623 sed 's/^/| /' conftest.$ac_ext >&5
35624
35625 ac_lo=`expr '(' $ac_mid ')' + 1`
35626 fi
35627 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35628 done
35629 case $ac_lo in
35630 ?*) ac_cv_sizeof_short=$ac_lo;;
35631 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
35632 See \`config.log' for more details." >&5
35633 echo "$as_me: error: cannot compute sizeof (short), 77
35634 See \`config.log' for more details." >&2;}
35635    { (exit 1); exit 1; }; } ;;
35636 esac
35637 else
35638   if test "$cross_compiling" = yes; then
35639   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
35640 See \`config.log' for more details." >&5
35641 echo "$as_me: error: cannot run test program while cross compiling
35642 See \`config.log' for more details." >&2;}
35643    { (exit 1); exit 1; }; }
35644 else
35645   cat >conftest.$ac_ext <<_ACEOF
35646 /* confdefs.h.  */
35647 _ACEOF
35648 cat confdefs.h >>conftest.$ac_ext
35649 cat >>conftest.$ac_ext <<_ACEOF
35650 /* end confdefs.h.  */
35651 $ac_includes_default
35652 long longval () { return (long) (sizeof (short)); }
35653 unsigned long ulongval () { return (long) (sizeof (short)); }
35654 #include <stdio.h>
35655 #include <stdlib.h>
35656 int
35657 main ()
35658 {
35659
35660   FILE *f = fopen ("conftest.val", "w");
35661   if (! f)
35662     exit (1);
35663   if (((long) (sizeof (short))) < 0)
35664     {
35665       long i = longval ();
35666       if (i != ((long) (sizeof (short))))
35667         exit (1);
35668       fprintf (f, "%ld\n", i);
35669     }
35670   else
35671     {
35672       unsigned long i = ulongval ();
35673       if (i != ((long) (sizeof (short))))
35674         exit (1);
35675       fprintf (f, "%lu\n", i);
35676     }
35677   exit (ferror (f) || fclose (f) != 0);
35678
35679   ;
35680   return 0;
35681 }
35682 _ACEOF
35683 rm -f conftest$ac_exeext
35684 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35685   (eval $ac_link) 2>&5
35686   ac_status=$?
35687   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35688   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
35689   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35690   (eval $ac_try) 2>&5
35691   ac_status=$?
35692   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35693   (exit $ac_status); }; }; then
35694   ac_cv_sizeof_short=`cat conftest.val`
35695 else
35696   echo "$as_me: program exited with status $ac_status" >&5
35697 echo "$as_me: failed program was:" >&5
35698 sed 's/^/| /' conftest.$ac_ext >&5
35699
35700 ( exit $ac_status )
35701 { { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
35702 See \`config.log' for more details." >&5
35703 echo "$as_me: error: cannot compute sizeof (short), 77
35704 See \`config.log' for more details." >&2;}
35705    { (exit 1); exit 1; }; }
35706 fi
35707 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
35708 fi
35709 fi
35710 rm -f conftest.val
35711 else
35712   ac_cv_sizeof_short=0
35713 fi
35714 fi
35715 echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
35716 echo "${ECHO_T}$ac_cv_sizeof_short" >&6
35717 cat >>confdefs.h <<_ACEOF
35718 #define SIZEOF_SHORT $ac_cv_sizeof_short
35719 _ACEOF
35720
35721
35722 echo "$as_me:$LINENO: checking for int" >&5
35723 echo $ECHO_N "checking for int... $ECHO_C" >&6
35724 if test "${ac_cv_type_int+set}" = set; then
35725   echo $ECHO_N "(cached) $ECHO_C" >&6
35726 else
35727   cat >conftest.$ac_ext <<_ACEOF
35728 /* confdefs.h.  */
35729 _ACEOF
35730 cat confdefs.h >>conftest.$ac_ext
35731 cat >>conftest.$ac_ext <<_ACEOF
35732 /* end confdefs.h.  */
35733 $ac_includes_default
35734 int
35735 main ()
35736 {
35737 if ((int *) 0)
35738   return 0;
35739 if (sizeof (int))
35740   return 0;
35741   ;
35742   return 0;
35743 }
35744 _ACEOF
35745 rm -f conftest.$ac_objext
35746 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35747   (eval $ac_compile) 2>conftest.er1
35748   ac_status=$?
35749   grep -v '^ *+' conftest.er1 >conftest.err
35750   rm -f conftest.er1
35751   cat conftest.err >&5
35752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35753   (exit $ac_status); } &&
35754          { ac_try='test -z "$ac_c_werror_flag"
35755                          || test ! -s conftest.err'
35756   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35757   (eval $ac_try) 2>&5
35758   ac_status=$?
35759   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35760   (exit $ac_status); }; } &&
35761          { ac_try='test -s conftest.$ac_objext'
35762   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35763   (eval $ac_try) 2>&5
35764   ac_status=$?
35765   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35766   (exit $ac_status); }; }; then
35767   ac_cv_type_int=yes
35768 else
35769   echo "$as_me: failed program was:" >&5
35770 sed 's/^/| /' conftest.$ac_ext >&5
35771
35772 ac_cv_type_int=no
35773 fi
35774 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35775 fi
35776 echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
35777 echo "${ECHO_T}$ac_cv_type_int" >&6
35778
35779 echo "$as_me:$LINENO: checking size of int" >&5
35780 echo $ECHO_N "checking size of int... $ECHO_C" >&6
35781 if test "${ac_cv_sizeof_int+set}" = set; then
35782   echo $ECHO_N "(cached) $ECHO_C" >&6
35783 else
35784   if test "$ac_cv_type_int" = yes; then
35785   # The cast to unsigned long works around a bug in the HP C Compiler
35786   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
35787   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
35788   # This bug is HP SR number 8606223364.
35789   if test "$cross_compiling" = yes; then
35790   # Depending upon the size, compute the lo and hi bounds.
35791 cat >conftest.$ac_ext <<_ACEOF
35792 /* confdefs.h.  */
35793 _ACEOF
35794 cat confdefs.h >>conftest.$ac_ext
35795 cat >>conftest.$ac_ext <<_ACEOF
35796 /* end confdefs.h.  */
35797 $ac_includes_default
35798 int
35799 main ()
35800 {
35801 static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
35802 test_array [0] = 0
35803
35804   ;
35805   return 0;
35806 }
35807 _ACEOF
35808 rm -f conftest.$ac_objext
35809 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35810   (eval $ac_compile) 2>conftest.er1
35811   ac_status=$?
35812   grep -v '^ *+' conftest.er1 >conftest.err
35813   rm -f conftest.er1
35814   cat conftest.err >&5
35815   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35816   (exit $ac_status); } &&
35817          { ac_try='test -z "$ac_c_werror_flag"
35818                          || test ! -s conftest.err'
35819   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35820   (eval $ac_try) 2>&5
35821   ac_status=$?
35822   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35823   (exit $ac_status); }; } &&
35824          { ac_try='test -s conftest.$ac_objext'
35825   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35826   (eval $ac_try) 2>&5
35827   ac_status=$?
35828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35829   (exit $ac_status); }; }; then
35830   ac_lo=0 ac_mid=0
35831   while :; do
35832     cat >conftest.$ac_ext <<_ACEOF
35833 /* confdefs.h.  */
35834 _ACEOF
35835 cat confdefs.h >>conftest.$ac_ext
35836 cat >>conftest.$ac_ext <<_ACEOF
35837 /* end confdefs.h.  */
35838 $ac_includes_default
35839 int
35840 main ()
35841 {
35842 static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
35843 test_array [0] = 0
35844
35845   ;
35846   return 0;
35847 }
35848 _ACEOF
35849 rm -f conftest.$ac_objext
35850 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35851   (eval $ac_compile) 2>conftest.er1
35852   ac_status=$?
35853   grep -v '^ *+' conftest.er1 >conftest.err
35854   rm -f conftest.er1
35855   cat conftest.err >&5
35856   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35857   (exit $ac_status); } &&
35858          { ac_try='test -z "$ac_c_werror_flag"
35859                          || test ! -s conftest.err'
35860   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35861   (eval $ac_try) 2>&5
35862   ac_status=$?
35863   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35864   (exit $ac_status); }; } &&
35865          { ac_try='test -s conftest.$ac_objext'
35866   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35867   (eval $ac_try) 2>&5
35868   ac_status=$?
35869   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35870   (exit $ac_status); }; }; then
35871   ac_hi=$ac_mid; break
35872 else
35873   echo "$as_me: failed program was:" >&5
35874 sed 's/^/| /' conftest.$ac_ext >&5
35875
35876 ac_lo=`expr $ac_mid + 1`
35877                     if test $ac_lo -le $ac_mid; then
35878                       ac_lo= ac_hi=
35879                       break
35880                     fi
35881                     ac_mid=`expr 2 '*' $ac_mid + 1`
35882 fi
35883 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35884   done
35885 else
35886   echo "$as_me: failed program was:" >&5
35887 sed 's/^/| /' conftest.$ac_ext >&5
35888
35889 cat >conftest.$ac_ext <<_ACEOF
35890 /* confdefs.h.  */
35891 _ACEOF
35892 cat confdefs.h >>conftest.$ac_ext
35893 cat >>conftest.$ac_ext <<_ACEOF
35894 /* end confdefs.h.  */
35895 $ac_includes_default
35896 int
35897 main ()
35898 {
35899 static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
35900 test_array [0] = 0
35901
35902   ;
35903   return 0;
35904 }
35905 _ACEOF
35906 rm -f conftest.$ac_objext
35907 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35908   (eval $ac_compile) 2>conftest.er1
35909   ac_status=$?
35910   grep -v '^ *+' conftest.er1 >conftest.err
35911   rm -f conftest.er1
35912   cat conftest.err >&5
35913   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35914   (exit $ac_status); } &&
35915          { ac_try='test -z "$ac_c_werror_flag"
35916                          || test ! -s conftest.err'
35917   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35918   (eval $ac_try) 2>&5
35919   ac_status=$?
35920   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35921   (exit $ac_status); }; } &&
35922          { ac_try='test -s conftest.$ac_objext'
35923   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35924   (eval $ac_try) 2>&5
35925   ac_status=$?
35926   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35927   (exit $ac_status); }; }; then
35928   ac_hi=-1 ac_mid=-1
35929   while :; do
35930     cat >conftest.$ac_ext <<_ACEOF
35931 /* confdefs.h.  */
35932 _ACEOF
35933 cat confdefs.h >>conftest.$ac_ext
35934 cat >>conftest.$ac_ext <<_ACEOF
35935 /* end confdefs.h.  */
35936 $ac_includes_default
35937 int
35938 main ()
35939 {
35940 static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
35941 test_array [0] = 0
35942
35943   ;
35944   return 0;
35945 }
35946 _ACEOF
35947 rm -f conftest.$ac_objext
35948 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35949   (eval $ac_compile) 2>conftest.er1
35950   ac_status=$?
35951   grep -v '^ *+' conftest.er1 >conftest.err
35952   rm -f conftest.er1
35953   cat conftest.err >&5
35954   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35955   (exit $ac_status); } &&
35956          { ac_try='test -z "$ac_c_werror_flag"
35957                          || test ! -s conftest.err'
35958   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35959   (eval $ac_try) 2>&5
35960   ac_status=$?
35961   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35962   (exit $ac_status); }; } &&
35963          { ac_try='test -s conftest.$ac_objext'
35964   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35965   (eval $ac_try) 2>&5
35966   ac_status=$?
35967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35968   (exit $ac_status); }; }; then
35969   ac_lo=$ac_mid; break
35970 else
35971   echo "$as_me: failed program was:" >&5
35972 sed 's/^/| /' conftest.$ac_ext >&5
35973
35974 ac_hi=`expr '(' $ac_mid ')' - 1`
35975                        if test $ac_mid -le $ac_hi; then
35976                          ac_lo= ac_hi=
35977                          break
35978                        fi
35979                        ac_mid=`expr 2 '*' $ac_mid`
35980 fi
35981 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35982   done
35983 else
35984   echo "$as_me: failed program was:" >&5
35985 sed 's/^/| /' conftest.$ac_ext >&5
35986
35987 ac_lo= ac_hi=
35988 fi
35989 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35990 fi
35991 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35992 # Binary search between lo and hi bounds.
35993 while test "x$ac_lo" != "x$ac_hi"; do
35994   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
35995   cat >conftest.$ac_ext <<_ACEOF
35996 /* confdefs.h.  */
35997 _ACEOF
35998 cat confdefs.h >>conftest.$ac_ext
35999 cat >>conftest.$ac_ext <<_ACEOF
36000 /* end confdefs.h.  */
36001 $ac_includes_default
36002 int
36003 main ()
36004 {
36005 static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
36006 test_array [0] = 0
36007
36008   ;
36009   return 0;
36010 }
36011 _ACEOF
36012 rm -f conftest.$ac_objext
36013 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36014   (eval $ac_compile) 2>conftest.er1
36015   ac_status=$?
36016   grep -v '^ *+' conftest.er1 >conftest.err
36017   rm -f conftest.er1
36018   cat conftest.err >&5
36019   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36020   (exit $ac_status); } &&
36021          { ac_try='test -z "$ac_c_werror_flag"
36022                          || test ! -s conftest.err'
36023   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36024   (eval $ac_try) 2>&5
36025   ac_status=$?
36026   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36027   (exit $ac_status); }; } &&
36028          { ac_try='test -s conftest.$ac_objext'
36029   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36030   (eval $ac_try) 2>&5
36031   ac_status=$?
36032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36033   (exit $ac_status); }; }; then
36034   ac_hi=$ac_mid
36035 else
36036   echo "$as_me: failed program was:" >&5
36037 sed 's/^/| /' conftest.$ac_ext >&5
36038
36039 ac_lo=`expr '(' $ac_mid ')' + 1`
36040 fi
36041 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36042 done
36043 case $ac_lo in
36044 ?*) ac_cv_sizeof_int=$ac_lo;;
36045 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
36046 See \`config.log' for more details." >&5
36047 echo "$as_me: error: cannot compute sizeof (int), 77
36048 See \`config.log' for more details." >&2;}
36049    { (exit 1); exit 1; }; } ;;
36050 esac
36051 else
36052   if test "$cross_compiling" = yes; then
36053   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
36054 See \`config.log' for more details." >&5
36055 echo "$as_me: error: cannot run test program while cross compiling
36056 See \`config.log' for more details." >&2;}
36057    { (exit 1); exit 1; }; }
36058 else
36059   cat >conftest.$ac_ext <<_ACEOF
36060 /* confdefs.h.  */
36061 _ACEOF
36062 cat confdefs.h >>conftest.$ac_ext
36063 cat >>conftest.$ac_ext <<_ACEOF
36064 /* end confdefs.h.  */
36065 $ac_includes_default
36066 long longval () { return (long) (sizeof (int)); }
36067 unsigned long ulongval () { return (long) (sizeof (int)); }
36068 #include <stdio.h>
36069 #include <stdlib.h>
36070 int
36071 main ()
36072 {
36073
36074   FILE *f = fopen ("conftest.val", "w");
36075   if (! f)
36076     exit (1);
36077   if (((long) (sizeof (int))) < 0)
36078     {
36079       long i = longval ();
36080       if (i != ((long) (sizeof (int))))
36081         exit (1);
36082       fprintf (f, "%ld\n", i);
36083     }
36084   else
36085     {
36086       unsigned long i = ulongval ();
36087       if (i != ((long) (sizeof (int))))
36088         exit (1);
36089       fprintf (f, "%lu\n", i);
36090     }
36091   exit (ferror (f) || fclose (f) != 0);
36092
36093   ;
36094   return 0;
36095 }
36096 _ACEOF
36097 rm -f conftest$ac_exeext
36098 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36099   (eval $ac_link) 2>&5
36100   ac_status=$?
36101   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36102   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
36103   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36104   (eval $ac_try) 2>&5
36105   ac_status=$?
36106   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36107   (exit $ac_status); }; }; then
36108   ac_cv_sizeof_int=`cat conftest.val`
36109 else
36110   echo "$as_me: program exited with status $ac_status" >&5
36111 echo "$as_me: failed program was:" >&5
36112 sed 's/^/| /' conftest.$ac_ext >&5
36113
36114 ( exit $ac_status )
36115 { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
36116 See \`config.log' for more details." >&5
36117 echo "$as_me: error: cannot compute sizeof (int), 77
36118 See \`config.log' for more details." >&2;}
36119    { (exit 1); exit 1; }; }
36120 fi
36121 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
36122 fi
36123 fi
36124 rm -f conftest.val
36125 else
36126   ac_cv_sizeof_int=0
36127 fi
36128 fi
36129 echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
36130 echo "${ECHO_T}$ac_cv_sizeof_int" >&6
36131 cat >>confdefs.h <<_ACEOF
36132 #define SIZEOF_INT $ac_cv_sizeof_int
36133 _ACEOF
36134
36135
36136 echo "$as_me:$LINENO: checking for long" >&5
36137 echo $ECHO_N "checking for long... $ECHO_C" >&6
36138 if test "${ac_cv_type_long+set}" = set; then
36139   echo $ECHO_N "(cached) $ECHO_C" >&6
36140 else
36141   cat >conftest.$ac_ext <<_ACEOF
36142 /* confdefs.h.  */
36143 _ACEOF
36144 cat confdefs.h >>conftest.$ac_ext
36145 cat >>conftest.$ac_ext <<_ACEOF
36146 /* end confdefs.h.  */
36147 $ac_includes_default
36148 int
36149 main ()
36150 {
36151 if ((long *) 0)
36152   return 0;
36153 if (sizeof (long))
36154   return 0;
36155   ;
36156   return 0;
36157 }
36158 _ACEOF
36159 rm -f conftest.$ac_objext
36160 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36161   (eval $ac_compile) 2>conftest.er1
36162   ac_status=$?
36163   grep -v '^ *+' conftest.er1 >conftest.err
36164   rm -f conftest.er1
36165   cat conftest.err >&5
36166   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36167   (exit $ac_status); } &&
36168          { ac_try='test -z "$ac_c_werror_flag"
36169                          || test ! -s conftest.err'
36170   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36171   (eval $ac_try) 2>&5
36172   ac_status=$?
36173   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36174   (exit $ac_status); }; } &&
36175          { ac_try='test -s conftest.$ac_objext'
36176   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36177   (eval $ac_try) 2>&5
36178   ac_status=$?
36179   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36180   (exit $ac_status); }; }; then
36181   ac_cv_type_long=yes
36182 else
36183   echo "$as_me: failed program was:" >&5
36184 sed 's/^/| /' conftest.$ac_ext >&5
36185
36186 ac_cv_type_long=no
36187 fi
36188 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36189 fi
36190 echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
36191 echo "${ECHO_T}$ac_cv_type_long" >&6
36192
36193 echo "$as_me:$LINENO: checking size of long" >&5
36194 echo $ECHO_N "checking size of long... $ECHO_C" >&6
36195 if test "${ac_cv_sizeof_long+set}" = set; then
36196   echo $ECHO_N "(cached) $ECHO_C" >&6
36197 else
36198   if test "$ac_cv_type_long" = yes; then
36199   # The cast to unsigned long works around a bug in the HP C Compiler
36200   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
36201   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
36202   # This bug is HP SR number 8606223364.
36203   if test "$cross_compiling" = yes; then
36204   # Depending upon the size, compute the lo and hi bounds.
36205 cat >conftest.$ac_ext <<_ACEOF
36206 /* confdefs.h.  */
36207 _ACEOF
36208 cat confdefs.h >>conftest.$ac_ext
36209 cat >>conftest.$ac_ext <<_ACEOF
36210 /* end confdefs.h.  */
36211 $ac_includes_default
36212 int
36213 main ()
36214 {
36215 static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
36216 test_array [0] = 0
36217
36218   ;
36219   return 0;
36220 }
36221 _ACEOF
36222 rm -f conftest.$ac_objext
36223 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36224   (eval $ac_compile) 2>conftest.er1
36225   ac_status=$?
36226   grep -v '^ *+' conftest.er1 >conftest.err
36227   rm -f conftest.er1
36228   cat conftest.err >&5
36229   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36230   (exit $ac_status); } &&
36231          { ac_try='test -z "$ac_c_werror_flag"
36232                          || test ! -s conftest.err'
36233   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36234   (eval $ac_try) 2>&5
36235   ac_status=$?
36236   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36237   (exit $ac_status); }; } &&
36238          { ac_try='test -s conftest.$ac_objext'
36239   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36240   (eval $ac_try) 2>&5
36241   ac_status=$?
36242   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36243   (exit $ac_status); }; }; then
36244   ac_lo=0 ac_mid=0
36245   while :; do
36246     cat >conftest.$ac_ext <<_ACEOF
36247 /* confdefs.h.  */
36248 _ACEOF
36249 cat confdefs.h >>conftest.$ac_ext
36250 cat >>conftest.$ac_ext <<_ACEOF
36251 /* end confdefs.h.  */
36252 $ac_includes_default
36253 int
36254 main ()
36255 {
36256 static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
36257 test_array [0] = 0
36258
36259   ;
36260   return 0;
36261 }
36262 _ACEOF
36263 rm -f conftest.$ac_objext
36264 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36265   (eval $ac_compile) 2>conftest.er1
36266   ac_status=$?
36267   grep -v '^ *+' conftest.er1 >conftest.err
36268   rm -f conftest.er1
36269   cat conftest.err >&5
36270   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36271   (exit $ac_status); } &&
36272          { ac_try='test -z "$ac_c_werror_flag"
36273                          || test ! -s conftest.err'
36274   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36275   (eval $ac_try) 2>&5
36276   ac_status=$?
36277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36278   (exit $ac_status); }; } &&
36279          { ac_try='test -s conftest.$ac_objext'
36280   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36281   (eval $ac_try) 2>&5
36282   ac_status=$?
36283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36284   (exit $ac_status); }; }; then
36285   ac_hi=$ac_mid; break
36286 else
36287   echo "$as_me: failed program was:" >&5
36288 sed 's/^/| /' conftest.$ac_ext >&5
36289
36290 ac_lo=`expr $ac_mid + 1`
36291                     if test $ac_lo -le $ac_mid; then
36292                       ac_lo= ac_hi=
36293                       break
36294                     fi
36295                     ac_mid=`expr 2 '*' $ac_mid + 1`
36296 fi
36297 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36298   done
36299 else
36300   echo "$as_me: failed program was:" >&5
36301 sed 's/^/| /' conftest.$ac_ext >&5
36302
36303 cat >conftest.$ac_ext <<_ACEOF
36304 /* confdefs.h.  */
36305 _ACEOF
36306 cat confdefs.h >>conftest.$ac_ext
36307 cat >>conftest.$ac_ext <<_ACEOF
36308 /* end confdefs.h.  */
36309 $ac_includes_default
36310 int
36311 main ()
36312 {
36313 static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
36314 test_array [0] = 0
36315
36316   ;
36317   return 0;
36318 }
36319 _ACEOF
36320 rm -f conftest.$ac_objext
36321 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36322   (eval $ac_compile) 2>conftest.er1
36323   ac_status=$?
36324   grep -v '^ *+' conftest.er1 >conftest.err
36325   rm -f conftest.er1
36326   cat conftest.err >&5
36327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36328   (exit $ac_status); } &&
36329          { ac_try='test -z "$ac_c_werror_flag"
36330                          || test ! -s conftest.err'
36331   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36332   (eval $ac_try) 2>&5
36333   ac_status=$?
36334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36335   (exit $ac_status); }; } &&
36336          { ac_try='test -s conftest.$ac_objext'
36337   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36338   (eval $ac_try) 2>&5
36339   ac_status=$?
36340   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36341   (exit $ac_status); }; }; then
36342   ac_hi=-1 ac_mid=-1
36343   while :; do
36344     cat >conftest.$ac_ext <<_ACEOF
36345 /* confdefs.h.  */
36346 _ACEOF
36347 cat confdefs.h >>conftest.$ac_ext
36348 cat >>conftest.$ac_ext <<_ACEOF
36349 /* end confdefs.h.  */
36350 $ac_includes_default
36351 int
36352 main ()
36353 {
36354 static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
36355 test_array [0] = 0
36356
36357   ;
36358   return 0;
36359 }
36360 _ACEOF
36361 rm -f conftest.$ac_objext
36362 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36363   (eval $ac_compile) 2>conftest.er1
36364   ac_status=$?
36365   grep -v '^ *+' conftest.er1 >conftest.err
36366   rm -f conftest.er1
36367   cat conftest.err >&5
36368   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36369   (exit $ac_status); } &&
36370          { ac_try='test -z "$ac_c_werror_flag"
36371                          || test ! -s conftest.err'
36372   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36373   (eval $ac_try) 2>&5
36374   ac_status=$?
36375   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36376   (exit $ac_status); }; } &&
36377          { ac_try='test -s conftest.$ac_objext'
36378   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36379   (eval $ac_try) 2>&5
36380   ac_status=$?
36381   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36382   (exit $ac_status); }; }; then
36383   ac_lo=$ac_mid; break
36384 else
36385   echo "$as_me: failed program was:" >&5
36386 sed 's/^/| /' conftest.$ac_ext >&5
36387
36388 ac_hi=`expr '(' $ac_mid ')' - 1`
36389                        if test $ac_mid -le $ac_hi; then
36390                          ac_lo= ac_hi=
36391                          break
36392                        fi
36393                        ac_mid=`expr 2 '*' $ac_mid`
36394 fi
36395 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36396   done
36397 else
36398   echo "$as_me: failed program was:" >&5
36399 sed 's/^/| /' conftest.$ac_ext >&5
36400
36401 ac_lo= ac_hi=
36402 fi
36403 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36404 fi
36405 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36406 # Binary search between lo and hi bounds.
36407 while test "x$ac_lo" != "x$ac_hi"; do
36408   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
36409   cat >conftest.$ac_ext <<_ACEOF
36410 /* confdefs.h.  */
36411 _ACEOF
36412 cat confdefs.h >>conftest.$ac_ext
36413 cat >>conftest.$ac_ext <<_ACEOF
36414 /* end confdefs.h.  */
36415 $ac_includes_default
36416 int
36417 main ()
36418 {
36419 static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
36420 test_array [0] = 0
36421
36422   ;
36423   return 0;
36424 }
36425 _ACEOF
36426 rm -f conftest.$ac_objext
36427 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36428   (eval $ac_compile) 2>conftest.er1
36429   ac_status=$?
36430   grep -v '^ *+' conftest.er1 >conftest.err
36431   rm -f conftest.er1
36432   cat conftest.err >&5
36433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36434   (exit $ac_status); } &&
36435          { ac_try='test -z "$ac_c_werror_flag"
36436                          || test ! -s conftest.err'
36437   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36438   (eval $ac_try) 2>&5
36439   ac_status=$?
36440   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36441   (exit $ac_status); }; } &&
36442          { ac_try='test -s conftest.$ac_objext'
36443   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36444   (eval $ac_try) 2>&5
36445   ac_status=$?
36446   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36447   (exit $ac_status); }; }; then
36448   ac_hi=$ac_mid
36449 else
36450   echo "$as_me: failed program was:" >&5
36451 sed 's/^/| /' conftest.$ac_ext >&5
36452
36453 ac_lo=`expr '(' $ac_mid ')' + 1`
36454 fi
36455 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36456 done
36457 case $ac_lo in
36458 ?*) ac_cv_sizeof_long=$ac_lo;;
36459 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
36460 See \`config.log' for more details." >&5
36461 echo "$as_me: error: cannot compute sizeof (long), 77
36462 See \`config.log' for more details." >&2;}
36463    { (exit 1); exit 1; }; } ;;
36464 esac
36465 else
36466   if test "$cross_compiling" = yes; then
36467   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
36468 See \`config.log' for more details." >&5
36469 echo "$as_me: error: cannot run test program while cross compiling
36470 See \`config.log' for more details." >&2;}
36471    { (exit 1); exit 1; }; }
36472 else
36473   cat >conftest.$ac_ext <<_ACEOF
36474 /* confdefs.h.  */
36475 _ACEOF
36476 cat confdefs.h >>conftest.$ac_ext
36477 cat >>conftest.$ac_ext <<_ACEOF
36478 /* end confdefs.h.  */
36479 $ac_includes_default
36480 long longval () { return (long) (sizeof (long)); }
36481 unsigned long ulongval () { return (long) (sizeof (long)); }
36482 #include <stdio.h>
36483 #include <stdlib.h>
36484 int
36485 main ()
36486 {
36487
36488   FILE *f = fopen ("conftest.val", "w");
36489   if (! f)
36490     exit (1);
36491   if (((long) (sizeof (long))) < 0)
36492     {
36493       long i = longval ();
36494       if (i != ((long) (sizeof (long))))
36495         exit (1);
36496       fprintf (f, "%ld\n", i);
36497     }
36498   else
36499     {
36500       unsigned long i = ulongval ();
36501       if (i != ((long) (sizeof (long))))
36502         exit (1);
36503       fprintf (f, "%lu\n", i);
36504     }
36505   exit (ferror (f) || fclose (f) != 0);
36506
36507   ;
36508   return 0;
36509 }
36510 _ACEOF
36511 rm -f conftest$ac_exeext
36512 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36513   (eval $ac_link) 2>&5
36514   ac_status=$?
36515   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36516   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
36517   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36518   (eval $ac_try) 2>&5
36519   ac_status=$?
36520   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36521   (exit $ac_status); }; }; then
36522   ac_cv_sizeof_long=`cat conftest.val`
36523 else
36524   echo "$as_me: program exited with status $ac_status" >&5
36525 echo "$as_me: failed program was:" >&5
36526 sed 's/^/| /' conftest.$ac_ext >&5
36527
36528 ( exit $ac_status )
36529 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
36530 See \`config.log' for more details." >&5
36531 echo "$as_me: error: cannot compute sizeof (long), 77
36532 See \`config.log' for more details." >&2;}
36533    { (exit 1); exit 1; }; }
36534 fi
36535 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
36536 fi
36537 fi
36538 rm -f conftest.val
36539 else
36540   ac_cv_sizeof_long=0
36541 fi
36542 fi
36543 echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
36544 echo "${ECHO_T}$ac_cv_sizeof_long" >&6
36545 cat >>confdefs.h <<_ACEOF
36546 #define SIZEOF_LONG $ac_cv_sizeof_long
36547 _ACEOF
36548
36549
36550 echo "$as_me:$LINENO: checking for long long" >&5
36551 echo $ECHO_N "checking for long long... $ECHO_C" >&6
36552 if test "${ac_cv_type_long_long+set}" = set; then
36553   echo $ECHO_N "(cached) $ECHO_C" >&6
36554 else
36555   cat >conftest.$ac_ext <<_ACEOF
36556 /* confdefs.h.  */
36557 _ACEOF
36558 cat confdefs.h >>conftest.$ac_ext
36559 cat >>conftest.$ac_ext <<_ACEOF
36560 /* end confdefs.h.  */
36561 $ac_includes_default
36562 int
36563 main ()
36564 {
36565 if ((long long *) 0)
36566   return 0;
36567 if (sizeof (long long))
36568   return 0;
36569   ;
36570   return 0;
36571 }
36572 _ACEOF
36573 rm -f conftest.$ac_objext
36574 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36575   (eval $ac_compile) 2>conftest.er1
36576   ac_status=$?
36577   grep -v '^ *+' conftest.er1 >conftest.err
36578   rm -f conftest.er1
36579   cat conftest.err >&5
36580   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36581   (exit $ac_status); } &&
36582          { ac_try='test -z "$ac_c_werror_flag"
36583                          || test ! -s conftest.err'
36584   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36585   (eval $ac_try) 2>&5
36586   ac_status=$?
36587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36588   (exit $ac_status); }; } &&
36589          { ac_try='test -s conftest.$ac_objext'
36590   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36591   (eval $ac_try) 2>&5
36592   ac_status=$?
36593   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36594   (exit $ac_status); }; }; then
36595   ac_cv_type_long_long=yes
36596 else
36597   echo "$as_me: failed program was:" >&5
36598 sed 's/^/| /' conftest.$ac_ext >&5
36599
36600 ac_cv_type_long_long=no
36601 fi
36602 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36603 fi
36604 echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
36605 echo "${ECHO_T}$ac_cv_type_long_long" >&6
36606
36607 echo "$as_me:$LINENO: checking size of long long" >&5
36608 echo $ECHO_N "checking size of long long... $ECHO_C" >&6
36609 if test "${ac_cv_sizeof_long_long+set}" = set; then
36610   echo $ECHO_N "(cached) $ECHO_C" >&6
36611 else
36612   if test "$ac_cv_type_long_long" = yes; then
36613   # The cast to unsigned long works around a bug in the HP C Compiler
36614   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
36615   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
36616   # This bug is HP SR number 8606223364.
36617   if test "$cross_compiling" = yes; then
36618   # Depending upon the size, compute the lo and hi bounds.
36619 cat >conftest.$ac_ext <<_ACEOF
36620 /* confdefs.h.  */
36621 _ACEOF
36622 cat confdefs.h >>conftest.$ac_ext
36623 cat >>conftest.$ac_ext <<_ACEOF
36624 /* end confdefs.h.  */
36625 $ac_includes_default
36626 int
36627 main ()
36628 {
36629 static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= 0)];
36630 test_array [0] = 0
36631
36632   ;
36633   return 0;
36634 }
36635 _ACEOF
36636 rm -f conftest.$ac_objext
36637 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36638   (eval $ac_compile) 2>conftest.er1
36639   ac_status=$?
36640   grep -v '^ *+' conftest.er1 >conftest.err
36641   rm -f conftest.er1
36642   cat conftest.err >&5
36643   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36644   (exit $ac_status); } &&
36645          { ac_try='test -z "$ac_c_werror_flag"
36646                          || test ! -s conftest.err'
36647   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36648   (eval $ac_try) 2>&5
36649   ac_status=$?
36650   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36651   (exit $ac_status); }; } &&
36652          { ac_try='test -s conftest.$ac_objext'
36653   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36654   (eval $ac_try) 2>&5
36655   ac_status=$?
36656   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36657   (exit $ac_status); }; }; then
36658   ac_lo=0 ac_mid=0
36659   while :; do
36660     cat >conftest.$ac_ext <<_ACEOF
36661 /* confdefs.h.  */
36662 _ACEOF
36663 cat confdefs.h >>conftest.$ac_ext
36664 cat >>conftest.$ac_ext <<_ACEOF
36665 /* end confdefs.h.  */
36666 $ac_includes_default
36667 int
36668 main ()
36669 {
36670 static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
36671 test_array [0] = 0
36672
36673   ;
36674   return 0;
36675 }
36676 _ACEOF
36677 rm -f conftest.$ac_objext
36678 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36679   (eval $ac_compile) 2>conftest.er1
36680   ac_status=$?
36681   grep -v '^ *+' conftest.er1 >conftest.err
36682   rm -f conftest.er1
36683   cat conftest.err >&5
36684   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36685   (exit $ac_status); } &&
36686          { ac_try='test -z "$ac_c_werror_flag"
36687                          || test ! -s conftest.err'
36688   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36689   (eval $ac_try) 2>&5
36690   ac_status=$?
36691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36692   (exit $ac_status); }; } &&
36693          { ac_try='test -s conftest.$ac_objext'
36694   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36695   (eval $ac_try) 2>&5
36696   ac_status=$?
36697   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36698   (exit $ac_status); }; }; then
36699   ac_hi=$ac_mid; break
36700 else
36701   echo "$as_me: failed program was:" >&5
36702 sed 's/^/| /' conftest.$ac_ext >&5
36703
36704 ac_lo=`expr $ac_mid + 1`
36705                     if test $ac_lo -le $ac_mid; then
36706                       ac_lo= ac_hi=
36707                       break
36708                     fi
36709                     ac_mid=`expr 2 '*' $ac_mid + 1`
36710 fi
36711 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36712   done
36713 else
36714   echo "$as_me: failed program was:" >&5
36715 sed 's/^/| /' conftest.$ac_ext >&5
36716
36717 cat >conftest.$ac_ext <<_ACEOF
36718 /* confdefs.h.  */
36719 _ACEOF
36720 cat confdefs.h >>conftest.$ac_ext
36721 cat >>conftest.$ac_ext <<_ACEOF
36722 /* end confdefs.h.  */
36723 $ac_includes_default
36724 int
36725 main ()
36726 {
36727 static int test_array [1 - 2 * !(((long) (sizeof (long long))) < 0)];
36728 test_array [0] = 0
36729
36730   ;
36731   return 0;
36732 }
36733 _ACEOF
36734 rm -f conftest.$ac_objext
36735 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36736   (eval $ac_compile) 2>conftest.er1
36737   ac_status=$?
36738   grep -v '^ *+' conftest.er1 >conftest.err
36739   rm -f conftest.er1
36740   cat conftest.err >&5
36741   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36742   (exit $ac_status); } &&
36743          { ac_try='test -z "$ac_c_werror_flag"
36744                          || test ! -s conftest.err'
36745   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36746   (eval $ac_try) 2>&5
36747   ac_status=$?
36748   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36749   (exit $ac_status); }; } &&
36750          { ac_try='test -s conftest.$ac_objext'
36751   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36752   (eval $ac_try) 2>&5
36753   ac_status=$?
36754   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36755   (exit $ac_status); }; }; then
36756   ac_hi=-1 ac_mid=-1
36757   while :; do
36758     cat >conftest.$ac_ext <<_ACEOF
36759 /* confdefs.h.  */
36760 _ACEOF
36761 cat confdefs.h >>conftest.$ac_ext
36762 cat >>conftest.$ac_ext <<_ACEOF
36763 /* end confdefs.h.  */
36764 $ac_includes_default
36765 int
36766 main ()
36767 {
36768 static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= $ac_mid)];
36769 test_array [0] = 0
36770
36771   ;
36772   return 0;
36773 }
36774 _ACEOF
36775 rm -f conftest.$ac_objext
36776 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36777   (eval $ac_compile) 2>conftest.er1
36778   ac_status=$?
36779   grep -v '^ *+' conftest.er1 >conftest.err
36780   rm -f conftest.er1
36781   cat conftest.err >&5
36782   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36783   (exit $ac_status); } &&
36784          { ac_try='test -z "$ac_c_werror_flag"
36785                          || test ! -s conftest.err'
36786   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36787   (eval $ac_try) 2>&5
36788   ac_status=$?
36789   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36790   (exit $ac_status); }; } &&
36791          { ac_try='test -s conftest.$ac_objext'
36792   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36793   (eval $ac_try) 2>&5
36794   ac_status=$?
36795   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36796   (exit $ac_status); }; }; then
36797   ac_lo=$ac_mid; break
36798 else
36799   echo "$as_me: failed program was:" >&5
36800 sed 's/^/| /' conftest.$ac_ext >&5
36801
36802 ac_hi=`expr '(' $ac_mid ')' - 1`
36803                        if test $ac_mid -le $ac_hi; then
36804                          ac_lo= ac_hi=
36805                          break
36806                        fi
36807                        ac_mid=`expr 2 '*' $ac_mid`
36808 fi
36809 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36810   done
36811 else
36812   echo "$as_me: failed program was:" >&5
36813 sed 's/^/| /' conftest.$ac_ext >&5
36814
36815 ac_lo= ac_hi=
36816 fi
36817 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36818 fi
36819 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36820 # Binary search between lo and hi bounds.
36821 while test "x$ac_lo" != "x$ac_hi"; do
36822   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
36823   cat >conftest.$ac_ext <<_ACEOF
36824 /* confdefs.h.  */
36825 _ACEOF
36826 cat confdefs.h >>conftest.$ac_ext
36827 cat >>conftest.$ac_ext <<_ACEOF
36828 /* end confdefs.h.  */
36829 $ac_includes_default
36830 int
36831 main ()
36832 {
36833 static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
36834 test_array [0] = 0
36835
36836   ;
36837   return 0;
36838 }
36839 _ACEOF
36840 rm -f conftest.$ac_objext
36841 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36842   (eval $ac_compile) 2>conftest.er1
36843   ac_status=$?
36844   grep -v '^ *+' conftest.er1 >conftest.err
36845   rm -f conftest.er1
36846   cat conftest.err >&5
36847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36848   (exit $ac_status); } &&
36849          { ac_try='test -z "$ac_c_werror_flag"
36850                          || test ! -s conftest.err'
36851   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36852   (eval $ac_try) 2>&5
36853   ac_status=$?
36854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36855   (exit $ac_status); }; } &&
36856          { ac_try='test -s conftest.$ac_objext'
36857   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36858   (eval $ac_try) 2>&5
36859   ac_status=$?
36860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36861   (exit $ac_status); }; }; then
36862   ac_hi=$ac_mid
36863 else
36864   echo "$as_me: failed program was:" >&5
36865 sed 's/^/| /' conftest.$ac_ext >&5
36866
36867 ac_lo=`expr '(' $ac_mid ')' + 1`
36868 fi
36869 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36870 done
36871 case $ac_lo in
36872 ?*) ac_cv_sizeof_long_long=$ac_lo;;
36873 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
36874 See \`config.log' for more details." >&5
36875 echo "$as_me: error: cannot compute sizeof (long long), 77
36876 See \`config.log' for more details." >&2;}
36877    { (exit 1); exit 1; }; } ;;
36878 esac
36879 else
36880   if test "$cross_compiling" = yes; then
36881   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
36882 See \`config.log' for more details." >&5
36883 echo "$as_me: error: cannot run test program while cross compiling
36884 See \`config.log' for more details." >&2;}
36885    { (exit 1); exit 1; }; }
36886 else
36887   cat >conftest.$ac_ext <<_ACEOF
36888 /* confdefs.h.  */
36889 _ACEOF
36890 cat confdefs.h >>conftest.$ac_ext
36891 cat >>conftest.$ac_ext <<_ACEOF
36892 /* end confdefs.h.  */
36893 $ac_includes_default
36894 long longval () { return (long) (sizeof (long long)); }
36895 unsigned long ulongval () { return (long) (sizeof (long long)); }
36896 #include <stdio.h>
36897 #include <stdlib.h>
36898 int
36899 main ()
36900 {
36901
36902   FILE *f = fopen ("conftest.val", "w");
36903   if (! f)
36904     exit (1);
36905   if (((long) (sizeof (long long))) < 0)
36906     {
36907       long i = longval ();
36908       if (i != ((long) (sizeof (long long))))
36909         exit (1);
36910       fprintf (f, "%ld\n", i);
36911     }
36912   else
36913     {
36914       unsigned long i = ulongval ();
36915       if (i != ((long) (sizeof (long long))))
36916         exit (1);
36917       fprintf (f, "%lu\n", i);
36918     }
36919   exit (ferror (f) || fclose (f) != 0);
36920
36921   ;
36922   return 0;
36923 }
36924 _ACEOF
36925 rm -f conftest$ac_exeext
36926 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36927   (eval $ac_link) 2>&5
36928   ac_status=$?
36929   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36930   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
36931   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36932   (eval $ac_try) 2>&5
36933   ac_status=$?
36934   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36935   (exit $ac_status); }; }; then
36936   ac_cv_sizeof_long_long=`cat conftest.val`
36937 else
36938   echo "$as_me: program exited with status $ac_status" >&5
36939 echo "$as_me: failed program was:" >&5
36940 sed 's/^/| /' conftest.$ac_ext >&5
36941
36942 ( exit $ac_status )
36943 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
36944 See \`config.log' for more details." >&5
36945 echo "$as_me: error: cannot compute sizeof (long long), 77
36946 See \`config.log' for more details." >&2;}
36947    { (exit 1); exit 1; }; }
36948 fi
36949 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
36950 fi
36951 fi
36952 rm -f conftest.val
36953 else
36954   ac_cv_sizeof_long_long=0
36955 fi
36956 fi
36957 echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
36958 echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
36959 cat >>confdefs.h <<_ACEOF
36960 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
36961 _ACEOF
36962
36963
36964 echo "$as_me:$LINENO: checking for wchar_t" >&5
36965 echo $ECHO_N "checking for wchar_t... $ECHO_C" >&6
36966 if test "${ac_cv_type_wchar_t+set}" = set; then
36967   echo $ECHO_N "(cached) $ECHO_C" >&6
36968 else
36969   cat >conftest.$ac_ext <<_ACEOF
36970 /* confdefs.h.  */
36971 _ACEOF
36972 cat confdefs.h >>conftest.$ac_ext
36973 cat >>conftest.$ac_ext <<_ACEOF
36974 /* end confdefs.h.  */
36975 $ac_includes_default
36976 int
36977 main ()
36978 {
36979 if ((wchar_t *) 0)
36980   return 0;
36981 if (sizeof (wchar_t))
36982   return 0;
36983   ;
36984   return 0;
36985 }
36986 _ACEOF
36987 rm -f conftest.$ac_objext
36988 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36989   (eval $ac_compile) 2>conftest.er1
36990   ac_status=$?
36991   grep -v '^ *+' conftest.er1 >conftest.err
36992   rm -f conftest.er1
36993   cat conftest.err >&5
36994   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36995   (exit $ac_status); } &&
36996          { ac_try='test -z "$ac_c_werror_flag"
36997                          || test ! -s conftest.err'
36998   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36999   (eval $ac_try) 2>&5
37000   ac_status=$?
37001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37002   (exit $ac_status); }; } &&
37003          { ac_try='test -s conftest.$ac_objext'
37004   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37005   (eval $ac_try) 2>&5
37006   ac_status=$?
37007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37008   (exit $ac_status); }; }; then
37009   ac_cv_type_wchar_t=yes
37010 else
37011   echo "$as_me: failed program was:" >&5
37012 sed 's/^/| /' conftest.$ac_ext >&5
37013
37014 ac_cv_type_wchar_t=no
37015 fi
37016 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37017 fi
37018 echo "$as_me:$LINENO: result: $ac_cv_type_wchar_t" >&5
37019 echo "${ECHO_T}$ac_cv_type_wchar_t" >&6
37020
37021 echo "$as_me:$LINENO: checking size of wchar_t" >&5
37022 echo $ECHO_N "checking size of wchar_t... $ECHO_C" >&6
37023 if test "${ac_cv_sizeof_wchar_t+set}" = set; then
37024   echo $ECHO_N "(cached) $ECHO_C" >&6
37025 else
37026   if test "$ac_cv_type_wchar_t" = yes; then
37027   # The cast to unsigned long works around a bug in the HP C Compiler
37028   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
37029   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
37030   # This bug is HP SR number 8606223364.
37031   if test "$cross_compiling" = yes; then
37032   # Depending upon the size, compute the lo and hi bounds.
37033 cat >conftest.$ac_ext <<_ACEOF
37034 /* confdefs.h.  */
37035 _ACEOF
37036 cat confdefs.h >>conftest.$ac_ext
37037 cat >>conftest.$ac_ext <<_ACEOF
37038 /* end confdefs.h.  */
37039 $ac_includes_default
37040 int
37041 main ()
37042 {
37043 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= 0)];
37044 test_array [0] = 0
37045
37046   ;
37047   return 0;
37048 }
37049 _ACEOF
37050 rm -f conftest.$ac_objext
37051 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37052   (eval $ac_compile) 2>conftest.er1
37053   ac_status=$?
37054   grep -v '^ *+' conftest.er1 >conftest.err
37055   rm -f conftest.er1
37056   cat conftest.err >&5
37057   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37058   (exit $ac_status); } &&
37059          { ac_try='test -z "$ac_c_werror_flag"
37060                          || test ! -s conftest.err'
37061   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37062   (eval $ac_try) 2>&5
37063   ac_status=$?
37064   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37065   (exit $ac_status); }; } &&
37066          { ac_try='test -s conftest.$ac_objext'
37067   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37068   (eval $ac_try) 2>&5
37069   ac_status=$?
37070   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37071   (exit $ac_status); }; }; then
37072   ac_lo=0 ac_mid=0
37073   while :; do
37074     cat >conftest.$ac_ext <<_ACEOF
37075 /* confdefs.h.  */
37076 _ACEOF
37077 cat confdefs.h >>conftest.$ac_ext
37078 cat >>conftest.$ac_ext <<_ACEOF
37079 /* end confdefs.h.  */
37080 $ac_includes_default
37081 int
37082 main ()
37083 {
37084 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
37085 test_array [0] = 0
37086
37087   ;
37088   return 0;
37089 }
37090 _ACEOF
37091 rm -f conftest.$ac_objext
37092 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37093   (eval $ac_compile) 2>conftest.er1
37094   ac_status=$?
37095   grep -v '^ *+' conftest.er1 >conftest.err
37096   rm -f conftest.er1
37097   cat conftest.err >&5
37098   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37099   (exit $ac_status); } &&
37100          { ac_try='test -z "$ac_c_werror_flag"
37101                          || test ! -s conftest.err'
37102   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37103   (eval $ac_try) 2>&5
37104   ac_status=$?
37105   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37106   (exit $ac_status); }; } &&
37107          { ac_try='test -s conftest.$ac_objext'
37108   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37109   (eval $ac_try) 2>&5
37110   ac_status=$?
37111   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37112   (exit $ac_status); }; }; then
37113   ac_hi=$ac_mid; break
37114 else
37115   echo "$as_me: failed program was:" >&5
37116 sed 's/^/| /' conftest.$ac_ext >&5
37117
37118 ac_lo=`expr $ac_mid + 1`
37119                     if test $ac_lo -le $ac_mid; then
37120                       ac_lo= ac_hi=
37121                       break
37122                     fi
37123                     ac_mid=`expr 2 '*' $ac_mid + 1`
37124 fi
37125 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37126   done
37127 else
37128   echo "$as_me: failed program was:" >&5
37129 sed 's/^/| /' conftest.$ac_ext >&5
37130
37131 cat >conftest.$ac_ext <<_ACEOF
37132 /* confdefs.h.  */
37133 _ACEOF
37134 cat confdefs.h >>conftest.$ac_ext
37135 cat >>conftest.$ac_ext <<_ACEOF
37136 /* end confdefs.h.  */
37137 $ac_includes_default
37138 int
37139 main ()
37140 {
37141 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) < 0)];
37142 test_array [0] = 0
37143
37144   ;
37145   return 0;
37146 }
37147 _ACEOF
37148 rm -f conftest.$ac_objext
37149 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37150   (eval $ac_compile) 2>conftest.er1
37151   ac_status=$?
37152   grep -v '^ *+' conftest.er1 >conftest.err
37153   rm -f conftest.er1
37154   cat conftest.err >&5
37155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37156   (exit $ac_status); } &&
37157          { ac_try='test -z "$ac_c_werror_flag"
37158                          || test ! -s conftest.err'
37159   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37160   (eval $ac_try) 2>&5
37161   ac_status=$?
37162   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37163   (exit $ac_status); }; } &&
37164          { ac_try='test -s conftest.$ac_objext'
37165   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37166   (eval $ac_try) 2>&5
37167   ac_status=$?
37168   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37169   (exit $ac_status); }; }; then
37170   ac_hi=-1 ac_mid=-1
37171   while :; do
37172     cat >conftest.$ac_ext <<_ACEOF
37173 /* confdefs.h.  */
37174 _ACEOF
37175 cat confdefs.h >>conftest.$ac_ext
37176 cat >>conftest.$ac_ext <<_ACEOF
37177 /* end confdefs.h.  */
37178 $ac_includes_default
37179 int
37180 main ()
37181 {
37182 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= $ac_mid)];
37183 test_array [0] = 0
37184
37185   ;
37186   return 0;
37187 }
37188 _ACEOF
37189 rm -f conftest.$ac_objext
37190 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37191   (eval $ac_compile) 2>conftest.er1
37192   ac_status=$?
37193   grep -v '^ *+' conftest.er1 >conftest.err
37194   rm -f conftest.er1
37195   cat conftest.err >&5
37196   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37197   (exit $ac_status); } &&
37198          { ac_try='test -z "$ac_c_werror_flag"
37199                          || test ! -s conftest.err'
37200   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37201   (eval $ac_try) 2>&5
37202   ac_status=$?
37203   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37204   (exit $ac_status); }; } &&
37205          { ac_try='test -s conftest.$ac_objext'
37206   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37207   (eval $ac_try) 2>&5
37208   ac_status=$?
37209   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37210   (exit $ac_status); }; }; then
37211   ac_lo=$ac_mid; break
37212 else
37213   echo "$as_me: failed program was:" >&5
37214 sed 's/^/| /' conftest.$ac_ext >&5
37215
37216 ac_hi=`expr '(' $ac_mid ')' - 1`
37217                        if test $ac_mid -le $ac_hi; then
37218                          ac_lo= ac_hi=
37219                          break
37220                        fi
37221                        ac_mid=`expr 2 '*' $ac_mid`
37222 fi
37223 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37224   done
37225 else
37226   echo "$as_me: failed program was:" >&5
37227 sed 's/^/| /' conftest.$ac_ext >&5
37228
37229 ac_lo= ac_hi=
37230 fi
37231 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37232 fi
37233 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37234 # Binary search between lo and hi bounds.
37235 while test "x$ac_lo" != "x$ac_hi"; do
37236   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
37237   cat >conftest.$ac_ext <<_ACEOF
37238 /* confdefs.h.  */
37239 _ACEOF
37240 cat confdefs.h >>conftest.$ac_ext
37241 cat >>conftest.$ac_ext <<_ACEOF
37242 /* end confdefs.h.  */
37243 $ac_includes_default
37244 int
37245 main ()
37246 {
37247 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
37248 test_array [0] = 0
37249
37250   ;
37251   return 0;
37252 }
37253 _ACEOF
37254 rm -f conftest.$ac_objext
37255 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37256   (eval $ac_compile) 2>conftest.er1
37257   ac_status=$?
37258   grep -v '^ *+' conftest.er1 >conftest.err
37259   rm -f conftest.er1
37260   cat conftest.err >&5
37261   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37262   (exit $ac_status); } &&
37263          { ac_try='test -z "$ac_c_werror_flag"
37264                          || test ! -s conftest.err'
37265   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37266   (eval $ac_try) 2>&5
37267   ac_status=$?
37268   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37269   (exit $ac_status); }; } &&
37270          { ac_try='test -s conftest.$ac_objext'
37271   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37272   (eval $ac_try) 2>&5
37273   ac_status=$?
37274   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37275   (exit $ac_status); }; }; then
37276   ac_hi=$ac_mid
37277 else
37278   echo "$as_me: failed program was:" >&5
37279 sed 's/^/| /' conftest.$ac_ext >&5
37280
37281 ac_lo=`expr '(' $ac_mid ')' + 1`
37282 fi
37283 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37284 done
37285 case $ac_lo in
37286 ?*) ac_cv_sizeof_wchar_t=$ac_lo;;
37287 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77
37288 See \`config.log' for more details." >&5
37289 echo "$as_me: error: cannot compute sizeof (wchar_t), 77
37290 See \`config.log' for more details." >&2;}
37291    { (exit 1); exit 1; }; } ;;
37292 esac
37293 else
37294   if test "$cross_compiling" = yes; then
37295   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
37296 See \`config.log' for more details." >&5
37297 echo "$as_me: error: cannot run test program while cross compiling
37298 See \`config.log' for more details." >&2;}
37299    { (exit 1); exit 1; }; }
37300 else
37301   cat >conftest.$ac_ext <<_ACEOF
37302 /* confdefs.h.  */
37303 _ACEOF
37304 cat confdefs.h >>conftest.$ac_ext
37305 cat >>conftest.$ac_ext <<_ACEOF
37306 /* end confdefs.h.  */
37307 $ac_includes_default
37308 long longval () { return (long) (sizeof (wchar_t)); }
37309 unsigned long ulongval () { return (long) (sizeof (wchar_t)); }
37310 #include <stdio.h>
37311 #include <stdlib.h>
37312 int
37313 main ()
37314 {
37315
37316   FILE *f = fopen ("conftest.val", "w");
37317   if (! f)
37318     exit (1);
37319   if (((long) (sizeof (wchar_t))) < 0)
37320     {
37321       long i = longval ();
37322       if (i != ((long) (sizeof (wchar_t))))
37323         exit (1);
37324       fprintf (f, "%ld\n", i);
37325     }
37326   else
37327     {
37328       unsigned long i = ulongval ();
37329       if (i != ((long) (sizeof (wchar_t))))
37330         exit (1);
37331       fprintf (f, "%lu\n", i);
37332     }
37333   exit (ferror (f) || fclose (f) != 0);
37334
37335   ;
37336   return 0;
37337 }
37338 _ACEOF
37339 rm -f conftest$ac_exeext
37340 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37341   (eval $ac_link) 2>&5
37342   ac_status=$?
37343   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37344   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
37345   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37346   (eval $ac_try) 2>&5
37347   ac_status=$?
37348   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37349   (exit $ac_status); }; }; then
37350   ac_cv_sizeof_wchar_t=`cat conftest.val`
37351 else
37352   echo "$as_me: program exited with status $ac_status" >&5
37353 echo "$as_me: failed program was:" >&5
37354 sed 's/^/| /' conftest.$ac_ext >&5
37355
37356 ( exit $ac_status )
37357 { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77
37358 See \`config.log' for more details." >&5
37359 echo "$as_me: error: cannot compute sizeof (wchar_t), 77
37360 See \`config.log' for more details." >&2;}
37361    { (exit 1); exit 1; }; }
37362 fi
37363 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
37364 fi
37365 fi
37366 rm -f conftest.val
37367 else
37368   ac_cv_sizeof_wchar_t=0
37369 fi
37370 fi
37371 echo "$as_me:$LINENO: result: $ac_cv_sizeof_wchar_t" >&5
37372 echo "${ECHO_T}$ac_cv_sizeof_wchar_t" >&6
37373 cat >>confdefs.h <<_ACEOF
37374 #define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t
37375 _ACEOF
37376
37377
37378
37379 if test "$ac_cv_sizeof_int" -lt 4 ; then
37380         { echo "$as_me:$LINENO: WARNING: OpenLDAP requires 'int' to be 32 bits or greater." >&5
37381 echo "$as_me: WARNING: OpenLDAP requires 'int' to be 32 bits or greater." >&2;}
37382
37383
37384 cat >>confdefs.h <<\_ACEOF
37385 #define LBER_INT_T long
37386 _ACEOF
37387
37388 else
37389
37390 cat >>confdefs.h <<\_ACEOF
37391 #define LBER_INT_T int
37392 _ACEOF
37393
37394 fi
37395
37396
37397 cat >>confdefs.h <<\_ACEOF
37398 #define LBER_LEN_T long
37399 _ACEOF
37400
37401
37402 cat >>confdefs.h <<\_ACEOF
37403 #define LBER_SOCKET_T int
37404 _ACEOF
37405
37406
37407 cat >>confdefs.h <<\_ACEOF
37408 #define LBER_TAG_T long
37409 _ACEOF
37410
37411
37412 if test $ol_with_mp = longlong || test $ol_with_mp = auto ; then
37413         if test $ac_cv_sizeof_long_long -gt 4 ; then
37414                 ol_with_mp=longlong
37415
37416 cat >>confdefs.h <<\_ACEOF
37417 #define USE_MP_LONG_LONG 1
37418 _ACEOF
37419
37420         elif test $ol_with_mp = longlong ; then
37421                 { { echo "$as_me:$LINENO: error: long long unusable for multiple precision" >&5
37422 echo "$as_me: error: long long unusable for multiple precision" >&2;}
37423    { (exit 1); exit 1; }; }
37424         fi
37425 fi
37426 if test $ol_with_mp = long || test $ol_with_mp = auto ; then
37427         if test $ac_cv_sizeof_long -gt 4 ; then
37428                 ol_with_mp=long
37429
37430 cat >>confdefs.h <<\_ACEOF
37431 #define USE_MP_LONG 1
37432 _ACEOF
37433
37434         elif test $ol_with_mp = long ; then
37435                 { { echo "$as_me:$LINENO: error: long unusable for multiple precision" >&5
37436 echo "$as_me: error: long unusable for multiple precision" >&2;}
37437    { (exit 1); exit 1; }; }
37438         fi
37439 fi
37440 if test $ol_with_mp = bignum || test $ol_with_mp = auto ; then
37441
37442 for ac_header in openssl/bn.h
37443 do
37444 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
37445 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37446   echo "$as_me:$LINENO: checking for $ac_header" >&5
37447 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37448 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37449   echo $ECHO_N "(cached) $ECHO_C" >&6
37450 fi
37451 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37452 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37453 else
37454   # Is the header compilable?
37455 echo "$as_me:$LINENO: checking $ac_header usability" >&5
37456 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
37457 cat >conftest.$ac_ext <<_ACEOF
37458 /* confdefs.h.  */
37459 _ACEOF
37460 cat confdefs.h >>conftest.$ac_ext
37461 cat >>conftest.$ac_ext <<_ACEOF
37462 /* end confdefs.h.  */
37463 $ac_includes_default
37464 #include <$ac_header>
37465 _ACEOF
37466 rm -f conftest.$ac_objext
37467 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37468   (eval $ac_compile) 2>conftest.er1
37469   ac_status=$?
37470   grep -v '^ *+' conftest.er1 >conftest.err
37471   rm -f conftest.er1
37472   cat conftest.err >&5
37473   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37474   (exit $ac_status); } &&
37475          { ac_try='test -z "$ac_c_werror_flag"
37476                          || test ! -s conftest.err'
37477   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37478   (eval $ac_try) 2>&5
37479   ac_status=$?
37480   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37481   (exit $ac_status); }; } &&
37482          { ac_try='test -s conftest.$ac_objext'
37483   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37484   (eval $ac_try) 2>&5
37485   ac_status=$?
37486   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37487   (exit $ac_status); }; }; then
37488   ac_header_compiler=yes
37489 else
37490   echo "$as_me: failed program was:" >&5
37491 sed 's/^/| /' conftest.$ac_ext >&5
37492
37493 ac_header_compiler=no
37494 fi
37495 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37496 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
37497 echo "${ECHO_T}$ac_header_compiler" >&6
37498
37499 # Is the header present?
37500 echo "$as_me:$LINENO: checking $ac_header presence" >&5
37501 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
37502 cat >conftest.$ac_ext <<_ACEOF
37503 /* confdefs.h.  */
37504 _ACEOF
37505 cat confdefs.h >>conftest.$ac_ext
37506 cat >>conftest.$ac_ext <<_ACEOF
37507 /* end confdefs.h.  */
37508 #include <$ac_header>
37509 _ACEOF
37510 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
37511   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
37512   ac_status=$?
37513   grep -v '^ *+' conftest.er1 >conftest.err
37514   rm -f conftest.er1
37515   cat conftest.err >&5
37516   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37517   (exit $ac_status); } >/dev/null; then
37518   if test -s conftest.err; then
37519     ac_cpp_err=$ac_c_preproc_warn_flag
37520     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
37521   else
37522     ac_cpp_err=
37523   fi
37524 else
37525   ac_cpp_err=yes
37526 fi
37527 if test -z "$ac_cpp_err"; then
37528   ac_header_preproc=yes
37529 else
37530   echo "$as_me: failed program was:" >&5
37531 sed 's/^/| /' conftest.$ac_ext >&5
37532
37533   ac_header_preproc=no
37534 fi
37535 rm -f conftest.err conftest.$ac_ext
37536 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
37537 echo "${ECHO_T}$ac_header_preproc" >&6
37538
37539 # So?  What about this header?
37540 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
37541   yes:no: )
37542     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
37543 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
37544     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
37545 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
37546     ac_header_preproc=yes
37547     ;;
37548   no:yes:* )
37549     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
37550 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
37551     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
37552 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
37553     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
37554 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
37555     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
37556 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
37557     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
37558 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
37559     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
37560 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
37561     (
37562       cat <<\_ASBOX
37563 ## --------------------------------------------- ##
37564 ## Report this to <http://www.openldap.org/its/> ##
37565 ## --------------------------------------------- ##
37566 _ASBOX
37567     ) |
37568       sed "s/^/$as_me: WARNING:     /" >&2
37569     ;;
37570 esac
37571 echo "$as_me:$LINENO: checking for $ac_header" >&5
37572 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37573 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37574   echo $ECHO_N "(cached) $ECHO_C" >&6
37575 else
37576   eval "$as_ac_Header=\$ac_header_preproc"
37577 fi
37578 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37579 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37580
37581 fi
37582 if test `eval echo '${'$as_ac_Header'}'` = yes; then
37583   cat >>confdefs.h <<_ACEOF
37584 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
37585 _ACEOF
37586
37587 fi
37588
37589 done
37590
37591
37592 for ac_header in openssl/crypto.h
37593 do
37594 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
37595 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37596   echo "$as_me:$LINENO: checking for $ac_header" >&5
37597 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37598 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37599   echo $ECHO_N "(cached) $ECHO_C" >&6
37600 fi
37601 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37602 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37603 else
37604   # Is the header compilable?
37605 echo "$as_me:$LINENO: checking $ac_header usability" >&5
37606 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
37607 cat >conftest.$ac_ext <<_ACEOF
37608 /* confdefs.h.  */
37609 _ACEOF
37610 cat confdefs.h >>conftest.$ac_ext
37611 cat >>conftest.$ac_ext <<_ACEOF
37612 /* end confdefs.h.  */
37613 $ac_includes_default
37614 #include <$ac_header>
37615 _ACEOF
37616 rm -f conftest.$ac_objext
37617 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37618   (eval $ac_compile) 2>conftest.er1
37619   ac_status=$?
37620   grep -v '^ *+' conftest.er1 >conftest.err
37621   rm -f conftest.er1
37622   cat conftest.err >&5
37623   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37624   (exit $ac_status); } &&
37625          { ac_try='test -z "$ac_c_werror_flag"
37626                          || test ! -s conftest.err'
37627   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37628   (eval $ac_try) 2>&5
37629   ac_status=$?
37630   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37631   (exit $ac_status); }; } &&
37632          { ac_try='test -s conftest.$ac_objext'
37633   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37634   (eval $ac_try) 2>&5
37635   ac_status=$?
37636   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37637   (exit $ac_status); }; }; then
37638   ac_header_compiler=yes
37639 else
37640   echo "$as_me: failed program was:" >&5
37641 sed 's/^/| /' conftest.$ac_ext >&5
37642
37643 ac_header_compiler=no
37644 fi
37645 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37646 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
37647 echo "${ECHO_T}$ac_header_compiler" >&6
37648
37649 # Is the header present?
37650 echo "$as_me:$LINENO: checking $ac_header presence" >&5
37651 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
37652 cat >conftest.$ac_ext <<_ACEOF
37653 /* confdefs.h.  */
37654 _ACEOF
37655 cat confdefs.h >>conftest.$ac_ext
37656 cat >>conftest.$ac_ext <<_ACEOF
37657 /* end confdefs.h.  */
37658 #include <$ac_header>
37659 _ACEOF
37660 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
37661   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
37662   ac_status=$?
37663   grep -v '^ *+' conftest.er1 >conftest.err
37664   rm -f conftest.er1
37665   cat conftest.err >&5
37666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37667   (exit $ac_status); } >/dev/null; then
37668   if test -s conftest.err; then
37669     ac_cpp_err=$ac_c_preproc_warn_flag
37670     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
37671   else
37672     ac_cpp_err=
37673   fi
37674 else
37675   ac_cpp_err=yes
37676 fi
37677 if test -z "$ac_cpp_err"; then
37678   ac_header_preproc=yes
37679 else
37680   echo "$as_me: failed program was:" >&5
37681 sed 's/^/| /' conftest.$ac_ext >&5
37682
37683   ac_header_preproc=no
37684 fi
37685 rm -f conftest.err conftest.$ac_ext
37686 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
37687 echo "${ECHO_T}$ac_header_preproc" >&6
37688
37689 # So?  What about this header?
37690 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
37691   yes:no: )
37692     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
37693 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
37694     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
37695 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
37696     ac_header_preproc=yes
37697     ;;
37698   no:yes:* )
37699     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
37700 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
37701     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
37702 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
37703     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
37704 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
37705     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
37706 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
37707     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
37708 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
37709     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
37710 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
37711     (
37712       cat <<\_ASBOX
37713 ## --------------------------------------------- ##
37714 ## Report this to <http://www.openldap.org/its/> ##
37715 ## --------------------------------------------- ##
37716 _ASBOX
37717     ) |
37718       sed "s/^/$as_me: WARNING:     /" >&2
37719     ;;
37720 esac
37721 echo "$as_me:$LINENO: checking for $ac_header" >&5
37722 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37723 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37724   echo $ECHO_N "(cached) $ECHO_C" >&6
37725 else
37726   eval "$as_ac_Header=\$ac_header_preproc"
37727 fi
37728 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37729 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37730
37731 fi
37732 if test `eval echo '${'$as_ac_Header'}'` = yes; then
37733   cat >>confdefs.h <<_ACEOF
37734 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
37735 _ACEOF
37736
37737 fi
37738
37739 done
37740
37741         if test "$ac_cv_header_openssl_bn_h" = "yes" &&
37742                 test "$ac_cv_header_openssl_crypto_h" = "yes" &&
37743                 test "$ol_with_tls" = "found" ; then
37744                 ol_with_mp=bignum
37745
37746 cat >>confdefs.h <<\_ACEOF
37747 #define USE_MP_BIGNUM 1
37748 _ACEOF
37749
37750         elif test $ol_with_mp = bignum ; then
37751                 { { echo "$as_me:$LINENO: error: bignum not available" >&5
37752 echo "$as_me: error: bignum not available" >&2;}
37753    { (exit 1); exit 1; }; }
37754         fi
37755 fi
37756 if test $ol_with_mp = gmp || test $ol_with_mp = auto ; then
37757
37758 for ac_header in gmp.h
37759 do
37760 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
37761 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37762   echo "$as_me:$LINENO: checking for $ac_header" >&5
37763 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37764 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37765   echo $ECHO_N "(cached) $ECHO_C" >&6
37766 fi
37767 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37768 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37769 else
37770   # Is the header compilable?
37771 echo "$as_me:$LINENO: checking $ac_header usability" >&5
37772 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
37773 cat >conftest.$ac_ext <<_ACEOF
37774 /* confdefs.h.  */
37775 _ACEOF
37776 cat confdefs.h >>conftest.$ac_ext
37777 cat >>conftest.$ac_ext <<_ACEOF
37778 /* end confdefs.h.  */
37779 $ac_includes_default
37780 #include <$ac_header>
37781 _ACEOF
37782 rm -f conftest.$ac_objext
37783 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37784   (eval $ac_compile) 2>conftest.er1
37785   ac_status=$?
37786   grep -v '^ *+' conftest.er1 >conftest.err
37787   rm -f conftest.er1
37788   cat conftest.err >&5
37789   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37790   (exit $ac_status); } &&
37791          { ac_try='test -z "$ac_c_werror_flag"
37792                          || test ! -s conftest.err'
37793   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37794   (eval $ac_try) 2>&5
37795   ac_status=$?
37796   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37797   (exit $ac_status); }; } &&
37798          { ac_try='test -s conftest.$ac_objext'
37799   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37800   (eval $ac_try) 2>&5
37801   ac_status=$?
37802   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37803   (exit $ac_status); }; }; then
37804   ac_header_compiler=yes
37805 else
37806   echo "$as_me: failed program was:" >&5
37807 sed 's/^/| /' conftest.$ac_ext >&5
37808
37809 ac_header_compiler=no
37810 fi
37811 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37812 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
37813 echo "${ECHO_T}$ac_header_compiler" >&6
37814
37815 # Is the header present?
37816 echo "$as_me:$LINENO: checking $ac_header presence" >&5
37817 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
37818 cat >conftest.$ac_ext <<_ACEOF
37819 /* confdefs.h.  */
37820 _ACEOF
37821 cat confdefs.h >>conftest.$ac_ext
37822 cat >>conftest.$ac_ext <<_ACEOF
37823 /* end confdefs.h.  */
37824 #include <$ac_header>
37825 _ACEOF
37826 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
37827   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
37828   ac_status=$?
37829   grep -v '^ *+' conftest.er1 >conftest.err
37830   rm -f conftest.er1
37831   cat conftest.err >&5
37832   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37833   (exit $ac_status); } >/dev/null; then
37834   if test -s conftest.err; then
37835     ac_cpp_err=$ac_c_preproc_warn_flag
37836     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
37837   else
37838     ac_cpp_err=
37839   fi
37840 else
37841   ac_cpp_err=yes
37842 fi
37843 if test -z "$ac_cpp_err"; then
37844   ac_header_preproc=yes
37845 else
37846   echo "$as_me: failed program was:" >&5
37847 sed 's/^/| /' conftest.$ac_ext >&5
37848
37849   ac_header_preproc=no
37850 fi
37851 rm -f conftest.err conftest.$ac_ext
37852 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
37853 echo "${ECHO_T}$ac_header_preproc" >&6
37854
37855 # So?  What about this header?
37856 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
37857   yes:no: )
37858     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
37859 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
37860     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
37861 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
37862     ac_header_preproc=yes
37863     ;;
37864   no:yes:* )
37865     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
37866 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
37867     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
37868 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
37869     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
37870 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
37871     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
37872 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
37873     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
37874 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
37875     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
37876 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
37877     (
37878       cat <<\_ASBOX
37879 ## --------------------------------------------- ##
37880 ## Report this to <http://www.openldap.org/its/> ##
37881 ## --------------------------------------------- ##
37882 _ASBOX
37883     ) |
37884       sed "s/^/$as_me: WARNING:     /" >&2
37885     ;;
37886 esac
37887 echo "$as_me:$LINENO: checking for $ac_header" >&5
37888 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37889 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37890   echo $ECHO_N "(cached) $ECHO_C" >&6
37891 else
37892   eval "$as_ac_Header=\$ac_header_preproc"
37893 fi
37894 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37895 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37896
37897 fi
37898 if test `eval echo '${'$as_ac_Header'}'` = yes; then
37899   cat >>confdefs.h <<_ACEOF
37900 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
37901 _ACEOF
37902
37903 fi
37904
37905 done
37906
37907
37908 echo "$as_me:$LINENO: checking for __gmpz_add_ui in -lgmp" >&5
37909 echo $ECHO_N "checking for __gmpz_add_ui in -lgmp... $ECHO_C" >&6
37910 if test "${ac_cv_lib_gmp___gmpz_add_ui+set}" = set; then
37911   echo $ECHO_N "(cached) $ECHO_C" >&6
37912 else
37913   ac_check_lib_save_LIBS=$LIBS
37914 LIBS="-lgmp  $LIBS"
37915 cat >conftest.$ac_ext <<_ACEOF
37916 /* confdefs.h.  */
37917 _ACEOF
37918 cat confdefs.h >>conftest.$ac_ext
37919 cat >>conftest.$ac_ext <<_ACEOF
37920 /* end confdefs.h.  */
37921
37922 /* Override any gcc2 internal prototype to avoid an error.  */
37923 #ifdef __cplusplus
37924 extern "C"
37925 #endif
37926 /* We use char because int might match the return type of a gcc2
37927    builtin and then its argument prototype would still apply.  */
37928 char __gmpz_add_ui ();
37929 int
37930 main ()
37931 {
37932 __gmpz_add_ui ();
37933   ;
37934   return 0;
37935 }
37936 _ACEOF
37937 rm -f conftest.$ac_objext conftest$ac_exeext
37938 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37939   (eval $ac_link) 2>conftest.er1
37940   ac_status=$?
37941   grep -v '^ *+' conftest.er1 >conftest.err
37942   rm -f conftest.er1
37943   cat conftest.err >&5
37944   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37945   (exit $ac_status); } &&
37946          { ac_try='test -z "$ac_c_werror_flag"
37947                          || test ! -s conftest.err'
37948   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37949   (eval $ac_try) 2>&5
37950   ac_status=$?
37951   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37952   (exit $ac_status); }; } &&
37953          { ac_try='test -s conftest$ac_exeext'
37954   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37955   (eval $ac_try) 2>&5
37956   ac_status=$?
37957   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37958   (exit $ac_status); }; }; then
37959   ac_cv_lib_gmp___gmpz_add_ui=yes
37960 else
37961   echo "$as_me: failed program was:" >&5
37962 sed 's/^/| /' conftest.$ac_ext >&5
37963
37964 ac_cv_lib_gmp___gmpz_add_ui=no
37965 fi
37966 rm -f conftest.err conftest.$ac_objext \
37967       conftest$ac_exeext conftest.$ac_ext
37968 LIBS=$ac_check_lib_save_LIBS
37969 fi
37970 echo "$as_me:$LINENO: result: $ac_cv_lib_gmp___gmpz_add_ui" >&5
37971 echo "${ECHO_T}$ac_cv_lib_gmp___gmpz_add_ui" >&6
37972 if test $ac_cv_lib_gmp___gmpz_add_ui = yes; then
37973   cat >>confdefs.h <<_ACEOF
37974 #define HAVE_LIBGMP 1
37975 _ACEOF
37976
37977   LIBS="-lgmp $LIBS"
37978
37979 fi
37980
37981         if test $ac_cv_header_gmp_h = yes && test $ac_cv_lib_gmp___gmpz_add_ui = yes ; then
37982
37983 cat >>confdefs.h <<\_ACEOF
37984 #define USE_MP_GMP 1
37985 _ACEOF
37986
37987                 ol_with_mp=gmp
37988         elif test $ol_with_mp = gmp ; then
37989                 { { echo "$as_me:$LINENO: error: gmp not available" >&5
37990 echo "$as_me: error: gmp not available" >&2;}
37991    { (exit 1); exit 1; }; }
37992         fi
37993 fi
37994 if test $ol_with_mp = auto ; then
37995         ol_with_mp=no
37996 fi
37997
37998 echo "$as_me:$LINENO: checking for working memcmp" >&5
37999 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
38000 if test "${ac_cv_func_memcmp_working+set}" = set; then
38001   echo $ECHO_N "(cached) $ECHO_C" >&6
38002 else
38003   if test "$cross_compiling" = yes; then
38004   ac_cv_func_memcmp_working=no
38005 else
38006   cat >conftest.$ac_ext <<_ACEOF
38007 /* confdefs.h.  */
38008 _ACEOF
38009 cat confdefs.h >>conftest.$ac_ext
38010 cat >>conftest.$ac_ext <<_ACEOF
38011 /* end confdefs.h.  */
38012 $ac_includes_default
38013 int
38014 main ()
38015 {
38016
38017   /* Some versions of memcmp are not 8-bit clean.  */
38018   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
38019   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
38020     exit (1);
38021
38022   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
38023      or more and with at least one buffer not starting on a 4-byte boundary.
38024      William Lewis provided this test program.   */
38025   {
38026     char foo[21];
38027     char bar[21];
38028     int i;
38029     for (i = 0; i < 4; i++)
38030       {
38031         char *a = foo + i;
38032         char *b = bar + i;
38033         strcpy (a, "--------01111111");
38034         strcpy (b, "--------10000000");
38035         if (memcmp (a, b, 16) >= 0)
38036           exit (1);
38037       }
38038     exit (0);
38039   }
38040
38041   ;
38042   return 0;
38043 }
38044 _ACEOF
38045 rm -f conftest$ac_exeext
38046 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38047   (eval $ac_link) 2>&5
38048   ac_status=$?
38049   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38050   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
38051   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38052   (eval $ac_try) 2>&5
38053   ac_status=$?
38054   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38055   (exit $ac_status); }; }; then
38056   ac_cv_func_memcmp_working=yes
38057 else
38058   echo "$as_me: program exited with status $ac_status" >&5
38059 echo "$as_me: failed program was:" >&5
38060 sed 's/^/| /' conftest.$ac_ext >&5
38061
38062 ( exit $ac_status )
38063 ac_cv_func_memcmp_working=no
38064 fi
38065 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
38066 fi
38067 fi
38068 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
38069 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
38070 test $ac_cv_func_memcmp_working = no && case $LIBOBJS in
38071     "memcmp.$ac_objext"   | \
38072   *" memcmp.$ac_objext"   | \
38073     "memcmp.$ac_objext "* | \
38074   *" memcmp.$ac_objext "* ) ;;
38075   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext" ;;
38076 esac
38077
38078
38079
38080 if test $ac_cv_func_memcmp_working = no ; then
38081
38082 cat >>confdefs.h <<\_ACEOF
38083 #define NEED_MEMCMP_REPLACEMENT 1
38084 _ACEOF
38085
38086 fi
38087
38088
38089 for ac_func in strftime
38090 do
38091 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
38092 echo "$as_me:$LINENO: checking for $ac_func" >&5
38093 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
38094 if eval "test \"\${$as_ac_var+set}\" = set"; then
38095   echo $ECHO_N "(cached) $ECHO_C" >&6
38096 else
38097   cat >conftest.$ac_ext <<_ACEOF
38098 /* confdefs.h.  */
38099 _ACEOF
38100 cat confdefs.h >>conftest.$ac_ext
38101 cat >>conftest.$ac_ext <<_ACEOF
38102 /* end confdefs.h.  */
38103 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
38104    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38105 #define $ac_func innocuous_$ac_func
38106
38107 /* System header to define __stub macros and hopefully few prototypes,
38108     which can conflict with char $ac_func (); below.
38109     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38110     <limits.h> exists even on freestanding compilers.  */
38111
38112 #ifdef __STDC__
38113 # include <limits.h>
38114 #else
38115 # include <assert.h>
38116 #endif
38117
38118 #undef $ac_func
38119
38120 /* Override any gcc2 internal prototype to avoid an error.  */
38121 #ifdef __cplusplus
38122 extern "C"
38123 {
38124 #endif
38125 /* We use char because int might match the return type of a gcc2
38126    builtin and then its argument prototype would still apply.  */
38127 char $ac_func ();
38128 /* The GNU C library defines this for functions which it implements
38129     to always fail with ENOSYS.  Some functions are actually named
38130     something starting with __ and the normal name is an alias.  */
38131 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
38132 choke me
38133 #else
38134 char (*f) () = $ac_func;
38135 #endif
38136 #ifdef __cplusplus
38137 }
38138 #endif
38139
38140 int
38141 main ()
38142 {
38143 return f != $ac_func;
38144   ;
38145   return 0;
38146 }
38147 _ACEOF
38148 rm -f conftest.$ac_objext conftest$ac_exeext
38149 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38150   (eval $ac_link) 2>conftest.er1
38151   ac_status=$?
38152   grep -v '^ *+' conftest.er1 >conftest.err
38153   rm -f conftest.er1
38154   cat conftest.err >&5
38155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38156   (exit $ac_status); } &&
38157          { ac_try='test -z "$ac_c_werror_flag"
38158                          || test ! -s conftest.err'
38159   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38160   (eval $ac_try) 2>&5
38161   ac_status=$?
38162   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38163   (exit $ac_status); }; } &&
38164          { ac_try='test -s conftest$ac_exeext'
38165   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38166   (eval $ac_try) 2>&5
38167   ac_status=$?
38168   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38169   (exit $ac_status); }; }; then
38170   eval "$as_ac_var=yes"
38171 else
38172   echo "$as_me: failed program was:" >&5
38173 sed 's/^/| /' conftest.$ac_ext >&5
38174
38175 eval "$as_ac_var=no"
38176 fi
38177 rm -f conftest.err conftest.$ac_objext \
38178       conftest$ac_exeext conftest.$ac_ext
38179 fi
38180 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
38181 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
38182 if test `eval echo '${'$as_ac_var'}'` = yes; then
38183   cat >>confdefs.h <<_ACEOF
38184 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
38185 _ACEOF
38186
38187 else
38188   # strftime is in -lintl on SCO UNIX.
38189 echo "$as_me:$LINENO: checking for strftime in -lintl" >&5
38190 echo $ECHO_N "checking for strftime in -lintl... $ECHO_C" >&6
38191 if test "${ac_cv_lib_intl_strftime+set}" = set; then
38192   echo $ECHO_N "(cached) $ECHO_C" >&6
38193 else
38194   ac_check_lib_save_LIBS=$LIBS
38195 LIBS="-lintl  $LIBS"
38196 cat >conftest.$ac_ext <<_ACEOF
38197 /* confdefs.h.  */
38198 _ACEOF
38199 cat confdefs.h >>conftest.$ac_ext
38200 cat >>conftest.$ac_ext <<_ACEOF
38201 /* end confdefs.h.  */
38202
38203 /* Override any gcc2 internal prototype to avoid an error.  */
38204 #ifdef __cplusplus
38205 extern "C"
38206 #endif
38207 /* We use char because int might match the return type of a gcc2
38208    builtin and then its argument prototype would still apply.  */
38209 char strftime ();
38210 int
38211 main ()
38212 {
38213 strftime ();
38214   ;
38215   return 0;
38216 }
38217 _ACEOF
38218 rm -f conftest.$ac_objext conftest$ac_exeext
38219 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38220   (eval $ac_link) 2>conftest.er1
38221   ac_status=$?
38222   grep -v '^ *+' conftest.er1 >conftest.err
38223   rm -f conftest.er1
38224   cat conftest.err >&5
38225   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38226   (exit $ac_status); } &&
38227          { ac_try='test -z "$ac_c_werror_flag"
38228                          || test ! -s conftest.err'
38229   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38230   (eval $ac_try) 2>&5
38231   ac_status=$?
38232   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38233   (exit $ac_status); }; } &&
38234          { ac_try='test -s conftest$ac_exeext'
38235   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38236   (eval $ac_try) 2>&5
38237   ac_status=$?
38238   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38239   (exit $ac_status); }; }; then
38240   ac_cv_lib_intl_strftime=yes
38241 else
38242   echo "$as_me: failed program was:" >&5
38243 sed 's/^/| /' conftest.$ac_ext >&5
38244
38245 ac_cv_lib_intl_strftime=no
38246 fi
38247 rm -f conftest.err conftest.$ac_objext \
38248       conftest$ac_exeext conftest.$ac_ext
38249 LIBS=$ac_check_lib_save_LIBS
38250 fi
38251 echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5
38252 echo "${ECHO_T}$ac_cv_lib_intl_strftime" >&6
38253 if test $ac_cv_lib_intl_strftime = yes; then
38254   cat >>confdefs.h <<\_ACEOF
38255 #define HAVE_STRFTIME 1
38256 _ACEOF
38257
38258 LIBS="-lintl $LIBS"
38259 fi
38260
38261 fi
38262 done
38263
38264
38265 echo "$as_me:$LINENO: checking for inet_aton()" >&5
38266 echo $ECHO_N "checking for inet_aton()... $ECHO_C" >&6
38267 if test "${ol_cv_func_inet_aton+set}" = set; then
38268   echo $ECHO_N "(cached) $ECHO_C" >&6
38269 else
38270   cat >conftest.$ac_ext <<_ACEOF
38271 /* confdefs.h.  */
38272 _ACEOF
38273 cat confdefs.h >>conftest.$ac_ext
38274 cat >>conftest.$ac_ext <<_ACEOF
38275 /* end confdefs.h.  */
38276
38277 #ifdef HAVE_SYS_TYPES_H
38278 #       include <sys/types.h>
38279 #endif
38280 #ifdef HAVE_SYS_SOCKET_H
38281 #       include <sys/socket.h>
38282 #       ifdef HAVE_SYS_SELECT_H
38283 #               include <sys/select.h>
38284 #       endif
38285 #       include <netinet/in.h>
38286 #       ifdef HAVE_ARPA_INET_H
38287 #               include <arpa/inet.h>
38288 #       endif
38289 #endif
38290
38291 int
38292 main ()
38293 {
38294 struct in_addr in;
38295 int rc = inet_aton( "255.255.255.255", &in );
38296   ;
38297   return 0;
38298 }
38299 _ACEOF
38300 rm -f conftest.$ac_objext conftest$ac_exeext
38301 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38302   (eval $ac_link) 2>conftest.er1
38303   ac_status=$?
38304   grep -v '^ *+' conftest.er1 >conftest.err
38305   rm -f conftest.er1
38306   cat conftest.err >&5
38307   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38308   (exit $ac_status); } &&
38309          { ac_try='test -z "$ac_c_werror_flag"
38310                          || test ! -s conftest.err'
38311   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38312   (eval $ac_try) 2>&5
38313   ac_status=$?
38314   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38315   (exit $ac_status); }; } &&
38316          { ac_try='test -s conftest$ac_exeext'
38317   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38318   (eval $ac_try) 2>&5
38319   ac_status=$?
38320   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38321   (exit $ac_status); }; }; then
38322   ol_cv_func_inet_aton=yes
38323 else
38324   echo "$as_me: failed program was:" >&5
38325 sed 's/^/| /' conftest.$ac_ext >&5
38326
38327 ol_cv_func_inet_aton=no
38328 fi
38329 rm -f conftest.err conftest.$ac_objext \
38330       conftest$ac_exeext conftest.$ac_ext
38331 fi
38332 echo "$as_me:$LINENO: result: $ol_cv_func_inet_aton" >&5
38333 echo "${ECHO_T}$ol_cv_func_inet_aton" >&6
38334   if test $ol_cv_func_inet_aton != no; then
38335
38336 cat >>confdefs.h <<\_ACEOF
38337 #define HAVE_INET_ATON 1
38338 _ACEOF
38339
38340   fi
38341
38342
38343 echo "$as_me:$LINENO: checking for _spawnlp" >&5
38344 echo $ECHO_N "checking for _spawnlp... $ECHO_C" >&6
38345 if test "${ac_cv_func__spawnlp+set}" = set; then
38346   echo $ECHO_N "(cached) $ECHO_C" >&6
38347 else
38348   cat >conftest.$ac_ext <<_ACEOF
38349 /* confdefs.h.  */
38350 _ACEOF
38351 cat confdefs.h >>conftest.$ac_ext
38352 cat >>conftest.$ac_ext <<_ACEOF
38353 /* end confdefs.h.  */
38354 /* Define _spawnlp to an innocuous variant, in case <limits.h> declares _spawnlp.
38355    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38356 #define _spawnlp innocuous__spawnlp
38357
38358 /* System header to define __stub macros and hopefully few prototypes,
38359     which can conflict with char _spawnlp (); below.
38360     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38361     <limits.h> exists even on freestanding compilers.  */
38362
38363 #ifdef __STDC__
38364 # include <limits.h>
38365 #else
38366 # include <assert.h>
38367 #endif
38368
38369 #undef _spawnlp
38370
38371 /* Override any gcc2 internal prototype to avoid an error.  */
38372 #ifdef __cplusplus
38373 extern "C"
38374 {
38375 #endif
38376 /* We use char because int might match the return type of a gcc2
38377    builtin and then its argument prototype would still apply.  */
38378 char _spawnlp ();
38379 /* The GNU C library defines this for functions which it implements
38380     to always fail with ENOSYS.  Some functions are actually named
38381     something starting with __ and the normal name is an alias.  */
38382 #if defined (__stub__spawnlp) || defined (__stub____spawnlp)
38383 choke me
38384 #else
38385 char (*f) () = _spawnlp;
38386 #endif
38387 #ifdef __cplusplus
38388 }
38389 #endif
38390
38391 int
38392 main ()
38393 {
38394 return f != _spawnlp;
38395   ;
38396   return 0;
38397 }
38398 _ACEOF
38399 rm -f conftest.$ac_objext conftest$ac_exeext
38400 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38401   (eval $ac_link) 2>conftest.er1
38402   ac_status=$?
38403   grep -v '^ *+' conftest.er1 >conftest.err
38404   rm -f conftest.er1
38405   cat conftest.err >&5
38406   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38407   (exit $ac_status); } &&
38408          { ac_try='test -z "$ac_c_werror_flag"
38409                          || test ! -s conftest.err'
38410   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38411   (eval $ac_try) 2>&5
38412   ac_status=$?
38413   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38414   (exit $ac_status); }; } &&
38415          { ac_try='test -s conftest$ac_exeext'
38416   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38417   (eval $ac_try) 2>&5
38418   ac_status=$?
38419   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38420   (exit $ac_status); }; }; then
38421   ac_cv_func__spawnlp=yes
38422 else
38423   echo "$as_me: failed program was:" >&5
38424 sed 's/^/| /' conftest.$ac_ext >&5
38425
38426 ac_cv_func__spawnlp=no
38427 fi
38428 rm -f conftest.err conftest.$ac_objext \
38429       conftest$ac_exeext conftest.$ac_ext
38430 fi
38431 echo "$as_me:$LINENO: result: $ac_cv_func__spawnlp" >&5
38432 echo "${ECHO_T}$ac_cv_func__spawnlp" >&6
38433 if test $ac_cv_func__spawnlp = yes; then
38434
38435 cat >>confdefs.h <<\_ACEOF
38436 #define HAVE_SPAWNLP 1
38437 _ACEOF
38438
38439 fi
38440
38441
38442 echo "$as_me:$LINENO: checking for _snprintf" >&5
38443 echo $ECHO_N "checking for _snprintf... $ECHO_C" >&6
38444 if test "${ac_cv_func__snprintf+set}" = set; then
38445   echo $ECHO_N "(cached) $ECHO_C" >&6
38446 else
38447   cat >conftest.$ac_ext <<_ACEOF
38448 /* confdefs.h.  */
38449 _ACEOF
38450 cat confdefs.h >>conftest.$ac_ext
38451 cat >>conftest.$ac_ext <<_ACEOF
38452 /* end confdefs.h.  */
38453 /* Define _snprintf to an innocuous variant, in case <limits.h> declares _snprintf.
38454    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38455 #define _snprintf innocuous__snprintf
38456
38457 /* System header to define __stub macros and hopefully few prototypes,
38458     which can conflict with char _snprintf (); below.
38459     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38460     <limits.h> exists even on freestanding compilers.  */
38461
38462 #ifdef __STDC__
38463 # include <limits.h>
38464 #else
38465 # include <assert.h>
38466 #endif
38467
38468 #undef _snprintf
38469
38470 /* Override any gcc2 internal prototype to avoid an error.  */
38471 #ifdef __cplusplus
38472 extern "C"
38473 {
38474 #endif
38475 /* We use char because int might match the return type of a gcc2
38476    builtin and then its argument prototype would still apply.  */
38477 char _snprintf ();
38478 /* The GNU C library defines this for functions which it implements
38479     to always fail with ENOSYS.  Some functions are actually named
38480     something starting with __ and the normal name is an alias.  */
38481 #if defined (__stub__snprintf) || defined (__stub____snprintf)
38482 choke me
38483 #else
38484 char (*f) () = _snprintf;
38485 #endif
38486 #ifdef __cplusplus
38487 }
38488 #endif
38489
38490 int
38491 main ()
38492 {
38493 return f != _snprintf;
38494   ;
38495   return 0;
38496 }
38497 _ACEOF
38498 rm -f conftest.$ac_objext conftest$ac_exeext
38499 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38500   (eval $ac_link) 2>conftest.er1
38501   ac_status=$?
38502   grep -v '^ *+' conftest.er1 >conftest.err
38503   rm -f conftest.er1
38504   cat conftest.err >&5
38505   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38506   (exit $ac_status); } &&
38507          { ac_try='test -z "$ac_c_werror_flag"
38508                          || test ! -s conftest.err'
38509   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38510   (eval $ac_try) 2>&5
38511   ac_status=$?
38512   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38513   (exit $ac_status); }; } &&
38514          { ac_try='test -s conftest$ac_exeext'
38515   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38516   (eval $ac_try) 2>&5
38517   ac_status=$?
38518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38519   (exit $ac_status); }; }; then
38520   ac_cv_func__snprintf=yes
38521 else
38522   echo "$as_me: failed program was:" >&5
38523 sed 's/^/| /' conftest.$ac_ext >&5
38524
38525 ac_cv_func__snprintf=no
38526 fi
38527 rm -f conftest.err conftest.$ac_objext \
38528       conftest$ac_exeext conftest.$ac_ext
38529 fi
38530 echo "$as_me:$LINENO: result: $ac_cv_func__snprintf" >&5
38531 echo "${ECHO_T}$ac_cv_func__snprintf" >&6
38532 if test $ac_cv_func__snprintf = yes; then
38533   ac_cv_func_snprintf=yes
38534
38535 cat >>confdefs.h <<\_ACEOF
38536 #define snprintf _snprintf
38537 _ACEOF
38538
38539
38540 fi
38541
38542
38543 echo "$as_me:$LINENO: checking for _vsnprintf" >&5
38544 echo $ECHO_N "checking for _vsnprintf... $ECHO_C" >&6
38545 if test "${ac_cv_func__vsnprintf+set}" = set; then
38546   echo $ECHO_N "(cached) $ECHO_C" >&6
38547 else
38548   cat >conftest.$ac_ext <<_ACEOF
38549 /* confdefs.h.  */
38550 _ACEOF
38551 cat confdefs.h >>conftest.$ac_ext
38552 cat >>conftest.$ac_ext <<_ACEOF
38553 /* end confdefs.h.  */
38554 /* Define _vsnprintf to an innocuous variant, in case <limits.h> declares _vsnprintf.
38555    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38556 #define _vsnprintf innocuous__vsnprintf
38557
38558 /* System header to define __stub macros and hopefully few prototypes,
38559     which can conflict with char _vsnprintf (); below.
38560     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38561     <limits.h> exists even on freestanding compilers.  */
38562
38563 #ifdef __STDC__
38564 # include <limits.h>
38565 #else
38566 # include <assert.h>
38567 #endif
38568
38569 #undef _vsnprintf
38570
38571 /* Override any gcc2 internal prototype to avoid an error.  */
38572 #ifdef __cplusplus
38573 extern "C"
38574 {
38575 #endif
38576 /* We use char because int might match the return type of a gcc2
38577    builtin and then its argument prototype would still apply.  */
38578 char _vsnprintf ();
38579 /* The GNU C library defines this for functions which it implements
38580     to always fail with ENOSYS.  Some functions are actually named
38581     something starting with __ and the normal name is an alias.  */
38582 #if defined (__stub__vsnprintf) || defined (__stub____vsnprintf)
38583 choke me
38584 #else
38585 char (*f) () = _vsnprintf;
38586 #endif
38587 #ifdef __cplusplus
38588 }
38589 #endif
38590
38591 int
38592 main ()
38593 {
38594 return f != _vsnprintf;
38595   ;
38596   return 0;
38597 }
38598 _ACEOF
38599 rm -f conftest.$ac_objext conftest$ac_exeext
38600 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38601   (eval $ac_link) 2>conftest.er1
38602   ac_status=$?
38603   grep -v '^ *+' conftest.er1 >conftest.err
38604   rm -f conftest.er1
38605   cat conftest.err >&5
38606   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38607   (exit $ac_status); } &&
38608          { ac_try='test -z "$ac_c_werror_flag"
38609                          || test ! -s conftest.err'
38610   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38611   (eval $ac_try) 2>&5
38612   ac_status=$?
38613   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38614   (exit $ac_status); }; } &&
38615          { ac_try='test -s conftest$ac_exeext'
38616   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38617   (eval $ac_try) 2>&5
38618   ac_status=$?
38619   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38620   (exit $ac_status); }; }; then
38621   ac_cv_func__vsnprintf=yes
38622 else
38623   echo "$as_me: failed program was:" >&5
38624 sed 's/^/| /' conftest.$ac_ext >&5
38625
38626 ac_cv_func__vsnprintf=no
38627 fi
38628 rm -f conftest.err conftest.$ac_objext \
38629       conftest$ac_exeext conftest.$ac_ext
38630 fi
38631 echo "$as_me:$LINENO: result: $ac_cv_func__vsnprintf" >&5
38632 echo "${ECHO_T}$ac_cv_func__vsnprintf" >&6
38633 if test $ac_cv_func__vsnprintf = yes; then
38634   ac_cv_func_vsnprintf=yes
38635
38636 cat >>confdefs.h <<\_ACEOF
38637 #define vsnprintf _vsnprintf
38638 _ACEOF
38639
38640
38641 fi
38642
38643
38644
38645 for ac_func in vprintf
38646 do
38647 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
38648 echo "$as_me:$LINENO: checking for $ac_func" >&5
38649 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
38650 if eval "test \"\${$as_ac_var+set}\" = set"; then
38651   echo $ECHO_N "(cached) $ECHO_C" >&6
38652 else
38653   cat >conftest.$ac_ext <<_ACEOF
38654 /* confdefs.h.  */
38655 _ACEOF
38656 cat confdefs.h >>conftest.$ac_ext
38657 cat >>conftest.$ac_ext <<_ACEOF
38658 /* end confdefs.h.  */
38659 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
38660    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38661 #define $ac_func innocuous_$ac_func
38662
38663 /* System header to define __stub macros and hopefully few prototypes,
38664     which can conflict with char $ac_func (); below.
38665     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38666     <limits.h> exists even on freestanding compilers.  */
38667
38668 #ifdef __STDC__
38669 # include <limits.h>
38670 #else
38671 # include <assert.h>
38672 #endif
38673
38674 #undef $ac_func
38675
38676 /* Override any gcc2 internal prototype to avoid an error.  */
38677 #ifdef __cplusplus
38678 extern "C"
38679 {
38680 #endif
38681 /* We use char because int might match the return type of a gcc2
38682    builtin and then its argument prototype would still apply.  */
38683 char $ac_func ();
38684 /* The GNU C library defines this for functions which it implements
38685     to always fail with ENOSYS.  Some functions are actually named
38686     something starting with __ and the normal name is an alias.  */
38687 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
38688 choke me
38689 #else
38690 char (*f) () = $ac_func;
38691 #endif
38692 #ifdef __cplusplus
38693 }
38694 #endif
38695
38696 int
38697 main ()
38698 {
38699 return f != $ac_func;
38700   ;
38701   return 0;
38702 }
38703 _ACEOF
38704 rm -f conftest.$ac_objext conftest$ac_exeext
38705 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38706   (eval $ac_link) 2>conftest.er1
38707   ac_status=$?
38708   grep -v '^ *+' conftest.er1 >conftest.err
38709   rm -f conftest.er1
38710   cat conftest.err >&5
38711   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38712   (exit $ac_status); } &&
38713          { ac_try='test -z "$ac_c_werror_flag"
38714                          || test ! -s conftest.err'
38715   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38716   (eval $ac_try) 2>&5
38717   ac_status=$?
38718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38719   (exit $ac_status); }; } &&
38720          { ac_try='test -s conftest$ac_exeext'
38721   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38722   (eval $ac_try) 2>&5
38723   ac_status=$?
38724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38725   (exit $ac_status); }; }; then
38726   eval "$as_ac_var=yes"
38727 else
38728   echo "$as_me: failed program was:" >&5
38729 sed 's/^/| /' conftest.$ac_ext >&5
38730
38731 eval "$as_ac_var=no"
38732 fi
38733 rm -f conftest.err conftest.$ac_objext \
38734       conftest$ac_exeext conftest.$ac_ext
38735 fi
38736 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
38737 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
38738 if test `eval echo '${'$as_ac_var'}'` = yes; then
38739   cat >>confdefs.h <<_ACEOF
38740 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
38741 _ACEOF
38742
38743 echo "$as_me:$LINENO: checking for _doprnt" >&5
38744 echo $ECHO_N "checking for _doprnt... $ECHO_C" >&6
38745 if test "${ac_cv_func__doprnt+set}" = set; then
38746   echo $ECHO_N "(cached) $ECHO_C" >&6
38747 else
38748   cat >conftest.$ac_ext <<_ACEOF
38749 /* confdefs.h.  */
38750 _ACEOF
38751 cat confdefs.h >>conftest.$ac_ext
38752 cat >>conftest.$ac_ext <<_ACEOF
38753 /* end confdefs.h.  */
38754 /* Define _doprnt to an innocuous variant, in case <limits.h> declares _doprnt.
38755    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38756 #define _doprnt innocuous__doprnt
38757
38758 /* System header to define __stub macros and hopefully few prototypes,
38759     which can conflict with char _doprnt (); below.
38760     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38761     <limits.h> exists even on freestanding compilers.  */
38762
38763 #ifdef __STDC__
38764 # include <limits.h>
38765 #else
38766 # include <assert.h>
38767 #endif
38768
38769 #undef _doprnt
38770
38771 /* Override any gcc2 internal prototype to avoid an error.  */
38772 #ifdef __cplusplus
38773 extern "C"
38774 {
38775 #endif
38776 /* We use char because int might match the return type of a gcc2
38777    builtin and then its argument prototype would still apply.  */
38778 char _doprnt ();
38779 /* The GNU C library defines this for functions which it implements
38780     to always fail with ENOSYS.  Some functions are actually named
38781     something starting with __ and the normal name is an alias.  */
38782 #if defined (__stub__doprnt) || defined (__stub____doprnt)
38783 choke me
38784 #else
38785 char (*f) () = _doprnt;
38786 #endif
38787 #ifdef __cplusplus
38788 }
38789 #endif
38790
38791 int
38792 main ()
38793 {
38794 return f != _doprnt;
38795   ;
38796   return 0;
38797 }
38798 _ACEOF
38799 rm -f conftest.$ac_objext conftest$ac_exeext
38800 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38801   (eval $ac_link) 2>conftest.er1
38802   ac_status=$?
38803   grep -v '^ *+' conftest.er1 >conftest.err
38804   rm -f conftest.er1
38805   cat conftest.err >&5
38806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38807   (exit $ac_status); } &&
38808          { ac_try='test -z "$ac_c_werror_flag"
38809                          || test ! -s conftest.err'
38810   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38811   (eval $ac_try) 2>&5
38812   ac_status=$?
38813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38814   (exit $ac_status); }; } &&
38815          { ac_try='test -s conftest$ac_exeext'
38816   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38817   (eval $ac_try) 2>&5
38818   ac_status=$?
38819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38820   (exit $ac_status); }; }; then
38821   ac_cv_func__doprnt=yes
38822 else
38823   echo "$as_me: failed program was:" >&5
38824 sed 's/^/| /' conftest.$ac_ext >&5
38825
38826 ac_cv_func__doprnt=no
38827 fi
38828 rm -f conftest.err conftest.$ac_objext \
38829       conftest$ac_exeext conftest.$ac_ext
38830 fi
38831 echo "$as_me:$LINENO: result: $ac_cv_func__doprnt" >&5
38832 echo "${ECHO_T}$ac_cv_func__doprnt" >&6
38833 if test $ac_cv_func__doprnt = yes; then
38834
38835 cat >>confdefs.h <<\_ACEOF
38836 #define HAVE_DOPRNT 1
38837 _ACEOF
38838
38839 fi
38840
38841 fi
38842 done
38843
38844
38845
38846 if test $ac_cv_func_vprintf = yes ; then
38847
38848
38849 for ac_func in snprintf vsnprintf
38850 do
38851 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
38852 echo "$as_me:$LINENO: checking for $ac_func" >&5
38853 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
38854 if eval "test \"\${$as_ac_var+set}\" = set"; then
38855   echo $ECHO_N "(cached) $ECHO_C" >&6
38856 else
38857   cat >conftest.$ac_ext <<_ACEOF
38858 /* confdefs.h.  */
38859 _ACEOF
38860 cat confdefs.h >>conftest.$ac_ext
38861 cat >>conftest.$ac_ext <<_ACEOF
38862 /* end confdefs.h.  */
38863 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
38864    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38865 #define $ac_func innocuous_$ac_func
38866
38867 /* System header to define __stub macros and hopefully few prototypes,
38868     which can conflict with char $ac_func (); below.
38869     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38870     <limits.h> exists even on freestanding compilers.  */
38871
38872 #ifdef __STDC__
38873 # include <limits.h>
38874 #else
38875 # include <assert.h>
38876 #endif
38877
38878 #undef $ac_func
38879
38880 /* Override any gcc2 internal prototype to avoid an error.  */
38881 #ifdef __cplusplus
38882 extern "C"
38883 {
38884 #endif
38885 /* We use char because int might match the return type of a gcc2
38886    builtin and then its argument prototype would still apply.  */
38887 char $ac_func ();
38888 /* The GNU C library defines this for functions which it implements
38889     to always fail with ENOSYS.  Some functions are actually named
38890     something starting with __ and the normal name is an alias.  */
38891 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
38892 choke me
38893 #else
38894 char (*f) () = $ac_func;
38895 #endif
38896 #ifdef __cplusplus
38897 }
38898 #endif
38899
38900 int
38901 main ()
38902 {
38903 return f != $ac_func;
38904   ;
38905   return 0;
38906 }
38907 _ACEOF
38908 rm -f conftest.$ac_objext conftest$ac_exeext
38909 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38910   (eval $ac_link) 2>conftest.er1
38911   ac_status=$?
38912   grep -v '^ *+' conftest.er1 >conftest.err
38913   rm -f conftest.er1
38914   cat conftest.err >&5
38915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38916   (exit $ac_status); } &&
38917          { ac_try='test -z "$ac_c_werror_flag"
38918                          || test ! -s conftest.err'
38919   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38920   (eval $ac_try) 2>&5
38921   ac_status=$?
38922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38923   (exit $ac_status); }; } &&
38924          { ac_try='test -s conftest$ac_exeext'
38925   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38926   (eval $ac_try) 2>&5
38927   ac_status=$?
38928   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38929   (exit $ac_status); }; }; then
38930   eval "$as_ac_var=yes"
38931 else
38932   echo "$as_me: failed program was:" >&5
38933 sed 's/^/| /' conftest.$ac_ext >&5
38934
38935 eval "$as_ac_var=no"
38936 fi
38937 rm -f conftest.err conftest.$ac_objext \
38938       conftest$ac_exeext conftest.$ac_ext
38939 fi
38940 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
38941 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
38942 if test `eval echo '${'$as_ac_var'}'` = yes; then
38943   cat >>confdefs.h <<_ACEOF
38944 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
38945 _ACEOF
38946
38947 fi
38948 done
38949
38950 fi
38951
38952
38953
38954
38955
38956
38957
38958
38959
38960
38961
38962
38963
38964
38965
38966
38967
38968
38969
38970
38971
38972
38973
38974
38975
38976
38977
38978
38979
38980
38981
38982
38983
38984
38985
38986
38987
38988
38989
38990
38991
38992
38993
38994
38995
38996
38997
38998
38999
39000
39001
39002
39003
39004
39005
39006
39007 for ac_func in \
39008         bcopy                   \
39009         closesocket             \
39010         chroot                  \
39011         endgrent                \
39012         endpwent                \
39013         fcntl                   \
39014         flock                   \
39015         fstat                   \
39016         getdtablesize           \
39017         getgrgid                \
39018         gethostname             \
39019         getpass                 \
39020         getpassphrase           \
39021         getpwuid                \
39022         getpwnam                \
39023         getspnam                \
39024         gettimeofday            \
39025         initgroups              \
39026         inet_ntoa_b             \
39027         ioctl                   \
39028         lockf                   \
39029         memcpy                  \
39030         memmove                 \
39031         memrchr                 \
39032         mkstemp                 \
39033         mktemp                  \
39034         pipe                    \
39035         read                    \
39036         recv                    \
39037         recvfrom                \
39038         setpwfile               \
39039         setgid                  \
39040         setegid                 \
39041         setsid                  \
39042         setuid                  \
39043         seteuid                 \
39044         signal                  \
39045         strdup                  \
39046         strpbrk                 \
39047         strrchr                 \
39048         strsep                  \
39049         strstr                  \
39050         strtol                  \
39051         strtoul                 \
39052         strtoq                  \
39053         strtouq                 \
39054         strtoll                 \
39055         strspn                  \
39056         sysconf                 \
39057         waitpid                 \
39058         wait4                   \
39059         write                   \
39060         send                    \
39061         sendmsg                 \
39062         sendto                  \
39063
39064 do
39065 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
39066 echo "$as_me:$LINENO: checking for $ac_func" >&5
39067 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
39068 if eval "test \"\${$as_ac_var+set}\" = set"; then
39069   echo $ECHO_N "(cached) $ECHO_C" >&6
39070 else
39071   cat >conftest.$ac_ext <<_ACEOF
39072 /* confdefs.h.  */
39073 _ACEOF
39074 cat confdefs.h >>conftest.$ac_ext
39075 cat >>conftest.$ac_ext <<_ACEOF
39076 /* end confdefs.h.  */
39077 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
39078    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
39079 #define $ac_func innocuous_$ac_func
39080
39081 /* System header to define __stub macros and hopefully few prototypes,
39082     which can conflict with char $ac_func (); below.
39083     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
39084     <limits.h> exists even on freestanding compilers.  */
39085
39086 #ifdef __STDC__
39087 # include <limits.h>
39088 #else
39089 # include <assert.h>
39090 #endif
39091
39092 #undef $ac_func
39093
39094 /* Override any gcc2 internal prototype to avoid an error.  */
39095 #ifdef __cplusplus
39096 extern "C"
39097 {
39098 #endif
39099 /* We use char because int might match the return type of a gcc2
39100    builtin and then its argument prototype would still apply.  */
39101 char $ac_func ();
39102 /* The GNU C library defines this for functions which it implements
39103     to always fail with ENOSYS.  Some functions are actually named
39104     something starting with __ and the normal name is an alias.  */
39105 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
39106 choke me
39107 #else
39108 char (*f) () = $ac_func;
39109 #endif
39110 #ifdef __cplusplus
39111 }
39112 #endif
39113
39114 int
39115 main ()
39116 {
39117 return f != $ac_func;
39118   ;
39119   return 0;
39120 }
39121 _ACEOF
39122 rm -f conftest.$ac_objext conftest$ac_exeext
39123 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
39124   (eval $ac_link) 2>conftest.er1
39125   ac_status=$?
39126   grep -v '^ *+' conftest.er1 >conftest.err
39127   rm -f conftest.er1
39128   cat conftest.err >&5
39129   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39130   (exit $ac_status); } &&
39131          { ac_try='test -z "$ac_c_werror_flag"
39132                          || test ! -s conftest.err'
39133   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39134   (eval $ac_try) 2>&5
39135   ac_status=$?
39136   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39137   (exit $ac_status); }; } &&
39138          { ac_try='test -s conftest$ac_exeext'
39139   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39140   (eval $ac_try) 2>&5
39141   ac_status=$?
39142   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39143   (exit $ac_status); }; }; then
39144   eval "$as_ac_var=yes"
39145 else
39146   echo "$as_me: failed program was:" >&5
39147 sed 's/^/| /' conftest.$ac_ext >&5
39148
39149 eval "$as_ac_var=no"
39150 fi
39151 rm -f conftest.err conftest.$ac_objext \
39152       conftest$ac_exeext conftest.$ac_ext
39153 fi
39154 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
39155 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
39156 if test `eval echo '${'$as_ac_var'}'` = yes; then
39157   cat >>confdefs.h <<_ACEOF
39158 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
39159 _ACEOF
39160
39161 fi
39162 done
39163
39164
39165
39166
39167 for ac_func in getopt getpeereid
39168 do
39169 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
39170 echo "$as_me:$LINENO: checking for $ac_func" >&5
39171 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
39172 if eval "test \"\${$as_ac_var+set}\" = set"; then
39173   echo $ECHO_N "(cached) $ECHO_C" >&6
39174 else
39175   cat >conftest.$ac_ext <<_ACEOF
39176 /* confdefs.h.  */
39177 _ACEOF
39178 cat confdefs.h >>conftest.$ac_ext
39179 cat >>conftest.$ac_ext <<_ACEOF
39180 /* end confdefs.h.  */
39181 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
39182    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
39183 #define $ac_func innocuous_$ac_func
39184
39185 /* System header to define __stub macros and hopefully few prototypes,
39186     which can conflict with char $ac_func (); below.
39187     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
39188     <limits.h> exists even on freestanding compilers.  */
39189
39190 #ifdef __STDC__
39191 # include <limits.h>
39192 #else
39193 # include <assert.h>
39194 #endif
39195
39196 #undef $ac_func
39197
39198 /* Override any gcc2 internal prototype to avoid an error.  */
39199 #ifdef __cplusplus
39200 extern "C"
39201 {
39202 #endif
39203 /* We use char because int might match the return type of a gcc2
39204    builtin and then its argument prototype would still apply.  */
39205 char $ac_func ();
39206 /* The GNU C library defines this for functions which it implements
39207     to always fail with ENOSYS.  Some functions are actually named
39208     something starting with __ and the normal name is an alias.  */
39209 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
39210 choke me
39211 #else
39212 char (*f) () = $ac_func;
39213 #endif
39214 #ifdef __cplusplus
39215 }
39216 #endif
39217
39218 int
39219 main ()
39220 {
39221 return f != $ac_func;
39222   ;
39223   return 0;
39224 }
39225 _ACEOF
39226 rm -f conftest.$ac_objext conftest$ac_exeext
39227 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
39228   (eval $ac_link) 2>conftest.er1
39229   ac_status=$?
39230   grep -v '^ *+' conftest.er1 >conftest.err
39231   rm -f conftest.er1
39232   cat conftest.err >&5
39233   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39234   (exit $ac_status); } &&
39235          { ac_try='test -z "$ac_c_werror_flag"
39236                          || test ! -s conftest.err'
39237   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39238   (eval $ac_try) 2>&5
39239   ac_status=$?
39240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39241   (exit $ac_status); }; } &&
39242          { ac_try='test -s conftest$ac_exeext'
39243   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39244   (eval $ac_try) 2>&5
39245   ac_status=$?
39246   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39247   (exit $ac_status); }; }; then
39248   eval "$as_ac_var=yes"
39249 else
39250   echo "$as_me: failed program was:" >&5
39251 sed 's/^/| /' conftest.$ac_ext >&5
39252
39253 eval "$as_ac_var=no"
39254 fi
39255 rm -f conftest.err conftest.$ac_objext \
39256       conftest$ac_exeext conftest.$ac_ext
39257 fi
39258 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
39259 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
39260 if test `eval echo '${'$as_ac_var'}'` = yes; then
39261   cat >>confdefs.h <<_ACEOF
39262 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
39263 _ACEOF
39264
39265 else
39266   case $LIBOBJS in
39267     "$ac_func.$ac_objext"   | \
39268   *" $ac_func.$ac_objext"   | \
39269     "$ac_func.$ac_objext "* | \
39270   *" $ac_func.$ac_objext "* ) ;;
39271   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
39272 esac
39273
39274 fi
39275 done
39276
39277
39278
39279 if test "$ac_cv_func_getopt" != yes; then
39280         LIBSRCS="$LIBSRCS getopt.c"
39281 fi
39282
39283 if test "$ac_cv_func_getpeereid" != yes; then
39284
39285 for ac_func in getpeerucred
39286 do
39287 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
39288 echo "$as_me:$LINENO: checking for $ac_func" >&5
39289 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
39290 if eval "test \"\${$as_ac_var+set}\" = set"; then
39291   echo $ECHO_N "(cached) $ECHO_C" >&6
39292 else
39293   cat >conftest.$ac_ext <<_ACEOF
39294 /* confdefs.h.  */
39295 _ACEOF
39296 cat confdefs.h >>conftest.$ac_ext
39297 cat >>conftest.$ac_ext <<_ACEOF
39298 /* end confdefs.h.  */
39299 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
39300    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
39301 #define $ac_func innocuous_$ac_func
39302
39303 /* System header to define __stub macros and hopefully few prototypes,
39304     which can conflict with char $ac_func (); below.
39305     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
39306     <limits.h> exists even on freestanding compilers.  */
39307
39308 #ifdef __STDC__
39309 # include <limits.h>
39310 #else
39311 # include <assert.h>
39312 #endif
39313
39314 #undef $ac_func
39315
39316 /* Override any gcc2 internal prototype to avoid an error.  */
39317 #ifdef __cplusplus
39318 extern "C"
39319 {
39320 #endif
39321 /* We use char because int might match the return type of a gcc2
39322    builtin and then its argument prototype would still apply.  */
39323 char $ac_func ();
39324 /* The GNU C library defines this for functions which it implements
39325     to always fail with ENOSYS.  Some functions are actually named
39326     something starting with __ and the normal name is an alias.  */
39327 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
39328 choke me
39329 #else
39330 char (*f) () = $ac_func;
39331 #endif
39332 #ifdef __cplusplus
39333 }
39334 #endif
39335
39336 int
39337 main ()
39338 {
39339 return f != $ac_func;
39340   ;
39341   return 0;
39342 }
39343 _ACEOF
39344 rm -f conftest.$ac_objext conftest$ac_exeext
39345 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
39346   (eval $ac_link) 2>conftest.er1
39347   ac_status=$?
39348   grep -v '^ *+' conftest.er1 >conftest.err
39349   rm -f conftest.er1
39350   cat conftest.err >&5
39351   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39352   (exit $ac_status); } &&
39353          { ac_try='test -z "$ac_c_werror_flag"
39354                          || test ! -s conftest.err'
39355   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39356   (eval $ac_try) 2>&5
39357   ac_status=$?
39358   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39359   (exit $ac_status); }; } &&
39360          { ac_try='test -s conftest$ac_exeext'
39361   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39362   (eval $ac_try) 2>&5
39363   ac_status=$?
39364   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39365   (exit $ac_status); }; }; then
39366   eval "$as_ac_var=yes"
39367 else
39368   echo "$as_me: failed program was:" >&5
39369 sed 's/^/| /' conftest.$ac_ext >&5
39370
39371 eval "$as_ac_var=no"
39372 fi
39373 rm -f conftest.err conftest.$ac_objext \
39374       conftest$ac_exeext conftest.$ac_ext
39375 fi
39376 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
39377 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
39378 if test `eval echo '${'$as_ac_var'}'` = yes; then
39379   cat >>confdefs.h <<_ACEOF
39380 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
39381 _ACEOF
39382
39383 fi
39384 done
39385
39386         if test "$ac_cv_func_getpeerucred" != yes ; then
39387                 echo "$as_me:$LINENO: checking for struct msghdr.msg_accrightslen" >&5
39388 echo $ECHO_N "checking for struct msghdr.msg_accrightslen... $ECHO_C" >&6
39389 if test "${ac_cv_member_struct_msghdr_msg_accrightslen+set}" = set; then
39390   echo $ECHO_N "(cached) $ECHO_C" >&6
39391 else
39392   cat >conftest.$ac_ext <<_ACEOF
39393 /* confdefs.h.  */
39394 _ACEOF
39395 cat confdefs.h >>conftest.$ac_ext
39396 cat >>conftest.$ac_ext <<_ACEOF
39397 /* end confdefs.h.  */
39398 $ac_includes_default
39399 #ifdef HAVE_SYS_SOCKET_H
39400 #include <sys/socket.h>
39401 #endif
39402
39403 int
39404 main ()
39405 {
39406 static struct msghdr ac_aggr;
39407 if (ac_aggr.msg_accrightslen)
39408 return 0;
39409   ;
39410   return 0;
39411 }
39412 _ACEOF
39413 rm -f conftest.$ac_objext
39414 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39415   (eval $ac_compile) 2>conftest.er1
39416   ac_status=$?
39417   grep -v '^ *+' conftest.er1 >conftest.err
39418   rm -f conftest.er1
39419   cat conftest.err >&5
39420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39421   (exit $ac_status); } &&
39422          { ac_try='test -z "$ac_c_werror_flag"
39423                          || test ! -s conftest.err'
39424   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39425   (eval $ac_try) 2>&5
39426   ac_status=$?
39427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39428   (exit $ac_status); }; } &&
39429          { ac_try='test -s conftest.$ac_objext'
39430   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39431   (eval $ac_try) 2>&5
39432   ac_status=$?
39433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39434   (exit $ac_status); }; }; then
39435   ac_cv_member_struct_msghdr_msg_accrightslen=yes
39436 else
39437   echo "$as_me: failed program was:" >&5
39438 sed 's/^/| /' conftest.$ac_ext >&5
39439
39440 cat >conftest.$ac_ext <<_ACEOF
39441 /* confdefs.h.  */
39442 _ACEOF
39443 cat confdefs.h >>conftest.$ac_ext
39444 cat >>conftest.$ac_ext <<_ACEOF
39445 /* end confdefs.h.  */
39446 $ac_includes_default
39447 #ifdef HAVE_SYS_SOCKET_H
39448 #include <sys/socket.h>
39449 #endif
39450
39451 int
39452 main ()
39453 {
39454 static struct msghdr ac_aggr;
39455 if (sizeof ac_aggr.msg_accrightslen)
39456 return 0;
39457   ;
39458   return 0;
39459 }
39460 _ACEOF
39461 rm -f conftest.$ac_objext
39462 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39463   (eval $ac_compile) 2>conftest.er1
39464   ac_status=$?
39465   grep -v '^ *+' conftest.er1 >conftest.err
39466   rm -f conftest.er1
39467   cat conftest.err >&5
39468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39469   (exit $ac_status); } &&
39470          { ac_try='test -z "$ac_c_werror_flag"
39471                          || test ! -s conftest.err'
39472   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39473   (eval $ac_try) 2>&5
39474   ac_status=$?
39475   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39476   (exit $ac_status); }; } &&
39477          { ac_try='test -s conftest.$ac_objext'
39478   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39479   (eval $ac_try) 2>&5
39480   ac_status=$?
39481   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39482   (exit $ac_status); }; }; then
39483   ac_cv_member_struct_msghdr_msg_accrightslen=yes
39484 else
39485   echo "$as_me: failed program was:" >&5
39486 sed 's/^/| /' conftest.$ac_ext >&5
39487
39488 ac_cv_member_struct_msghdr_msg_accrightslen=no
39489 fi
39490 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39491 fi
39492 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39493 fi
39494 echo "$as_me:$LINENO: result: $ac_cv_member_struct_msghdr_msg_accrightslen" >&5
39495 echo "${ECHO_T}$ac_cv_member_struct_msghdr_msg_accrightslen" >&6
39496 if test $ac_cv_member_struct_msghdr_msg_accrightslen = yes; then
39497
39498 cat >>confdefs.h <<_ACEOF
39499 #define HAVE_STRUCT_MSGHDR_MSG_ACCRIGHTSLEN 1
39500 _ACEOF
39501
39502
39503 fi
39504
39505                 if test "$ac_cv_member_struct_msghdr_msg_accrightslen" != yes; then
39506                         echo "$as_me:$LINENO: checking for struct msghdr.msg_control" >&5
39507 echo $ECHO_N "checking for struct msghdr.msg_control... $ECHO_C" >&6
39508 if test "${ac_cv_member_struct_msghdr_msg_control+set}" = set; then
39509   echo $ECHO_N "(cached) $ECHO_C" >&6
39510 else
39511   cat >conftest.$ac_ext <<_ACEOF
39512 /* confdefs.h.  */
39513 _ACEOF
39514 cat confdefs.h >>conftest.$ac_ext
39515 cat >>conftest.$ac_ext <<_ACEOF
39516 /* end confdefs.h.  */
39517 $ac_includes_default
39518 #ifdef HAVE_SYS_SOCKET_H
39519 #include <sys/socket.h>
39520 #endif
39521
39522 int
39523 main ()
39524 {
39525 static struct msghdr ac_aggr;
39526 if (ac_aggr.msg_control)
39527 return 0;
39528   ;
39529   return 0;
39530 }
39531 _ACEOF
39532 rm -f conftest.$ac_objext
39533 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39534   (eval $ac_compile) 2>conftest.er1
39535   ac_status=$?
39536   grep -v '^ *+' conftest.er1 >conftest.err
39537   rm -f conftest.er1
39538   cat conftest.err >&5
39539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39540   (exit $ac_status); } &&
39541          { ac_try='test -z "$ac_c_werror_flag"
39542                          || test ! -s conftest.err'
39543   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39544   (eval $ac_try) 2>&5
39545   ac_status=$?
39546   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39547   (exit $ac_status); }; } &&
39548          { ac_try='test -s conftest.$ac_objext'
39549   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39550   (eval $ac_try) 2>&5
39551   ac_status=$?
39552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39553   (exit $ac_status); }; }; then
39554   ac_cv_member_struct_msghdr_msg_control=yes
39555 else
39556   echo "$as_me: failed program was:" >&5
39557 sed 's/^/| /' conftest.$ac_ext >&5
39558
39559 cat >conftest.$ac_ext <<_ACEOF
39560 /* confdefs.h.  */
39561 _ACEOF
39562 cat confdefs.h >>conftest.$ac_ext
39563 cat >>conftest.$ac_ext <<_ACEOF
39564 /* end confdefs.h.  */
39565 $ac_includes_default
39566 #ifdef HAVE_SYS_SOCKET_H
39567 #include <sys/socket.h>
39568 #endif
39569
39570 int
39571 main ()
39572 {
39573 static struct msghdr ac_aggr;
39574 if (sizeof ac_aggr.msg_control)
39575 return 0;
39576   ;
39577   return 0;
39578 }
39579 _ACEOF
39580 rm -f conftest.$ac_objext
39581 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39582   (eval $ac_compile) 2>conftest.er1
39583   ac_status=$?
39584   grep -v '^ *+' conftest.er1 >conftest.err
39585   rm -f conftest.er1
39586   cat conftest.err >&5
39587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39588   (exit $ac_status); } &&
39589          { ac_try='test -z "$ac_c_werror_flag"
39590                          || test ! -s conftest.err'
39591   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39592   (eval $ac_try) 2>&5
39593   ac_status=$?
39594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39595   (exit $ac_status); }; } &&
39596          { ac_try='test -s conftest.$ac_objext'
39597   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39598   (eval $ac_try) 2>&5
39599   ac_status=$?
39600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39601   (exit $ac_status); }; }; then
39602   ac_cv_member_struct_msghdr_msg_control=yes
39603 else
39604   echo "$as_me: failed program was:" >&5
39605 sed 's/^/| /' conftest.$ac_ext >&5
39606
39607 ac_cv_member_struct_msghdr_msg_control=no
39608 fi
39609 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39610 fi
39611 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39612 fi
39613 echo "$as_me:$LINENO: result: $ac_cv_member_struct_msghdr_msg_control" >&5
39614 echo "${ECHO_T}$ac_cv_member_struct_msghdr_msg_control" >&6
39615 if test $ac_cv_member_struct_msghdr_msg_control = yes; then
39616
39617 cat >>confdefs.h <<_ACEOF
39618 #define HAVE_STRUCT_MSGHDR_MSG_CONTROL 1
39619 _ACEOF
39620
39621
39622 fi
39623
39624                 fi
39625                 echo "$as_me:$LINENO: checking for struct stat.st_fstype" >&5
39626 echo $ECHO_N "checking for struct stat.st_fstype... $ECHO_C" >&6
39627 if test "${ac_cv_member_struct_stat_st_fstype+set}" = set; then
39628   echo $ECHO_N "(cached) $ECHO_C" >&6
39629 else
39630   cat >conftest.$ac_ext <<_ACEOF
39631 /* confdefs.h.  */
39632 _ACEOF
39633 cat confdefs.h >>conftest.$ac_ext
39634 cat >>conftest.$ac_ext <<_ACEOF
39635 /* end confdefs.h.  */
39636 $ac_includes_default
39637 int
39638 main ()
39639 {
39640 static struct stat ac_aggr;
39641 if (ac_aggr.st_fstype)
39642 return 0;
39643   ;
39644   return 0;
39645 }
39646 _ACEOF
39647 rm -f conftest.$ac_objext
39648 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39649   (eval $ac_compile) 2>conftest.er1
39650   ac_status=$?
39651   grep -v '^ *+' conftest.er1 >conftest.err
39652   rm -f conftest.er1
39653   cat conftest.err >&5
39654   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39655   (exit $ac_status); } &&
39656          { ac_try='test -z "$ac_c_werror_flag"
39657                          || test ! -s conftest.err'
39658   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39659   (eval $ac_try) 2>&5
39660   ac_status=$?
39661   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39662   (exit $ac_status); }; } &&
39663          { ac_try='test -s conftest.$ac_objext'
39664   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39665   (eval $ac_try) 2>&5
39666   ac_status=$?
39667   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39668   (exit $ac_status); }; }; then
39669   ac_cv_member_struct_stat_st_fstype=yes
39670 else
39671   echo "$as_me: failed program was:" >&5
39672 sed 's/^/| /' conftest.$ac_ext >&5
39673
39674 cat >conftest.$ac_ext <<_ACEOF
39675 /* confdefs.h.  */
39676 _ACEOF
39677 cat confdefs.h >>conftest.$ac_ext
39678 cat >>conftest.$ac_ext <<_ACEOF
39679 /* end confdefs.h.  */
39680 $ac_includes_default
39681 int
39682 main ()
39683 {
39684 static struct stat ac_aggr;
39685 if (sizeof ac_aggr.st_fstype)
39686 return 0;
39687   ;
39688   return 0;
39689 }
39690 _ACEOF
39691 rm -f conftest.$ac_objext
39692 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39693   (eval $ac_compile) 2>conftest.er1
39694   ac_status=$?
39695   grep -v '^ *+' conftest.er1 >conftest.err
39696   rm -f conftest.er1
39697   cat conftest.err >&5
39698   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39699   (exit $ac_status); } &&
39700          { ac_try='test -z "$ac_c_werror_flag"
39701                          || test ! -s conftest.err'
39702   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39703   (eval $ac_try) 2>&5
39704   ac_status=$?
39705   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39706   (exit $ac_status); }; } &&
39707          { ac_try='test -s conftest.$ac_objext'
39708   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39709   (eval $ac_try) 2>&5
39710   ac_status=$?
39711   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39712   (exit $ac_status); }; }; then
39713   ac_cv_member_struct_stat_st_fstype=yes
39714 else
39715   echo "$as_me: failed program was:" >&5
39716 sed 's/^/| /' conftest.$ac_ext >&5
39717
39718 ac_cv_member_struct_stat_st_fstype=no
39719 fi
39720 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39721 fi
39722 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39723 fi
39724 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_fstype" >&5
39725 echo "${ECHO_T}$ac_cv_member_struct_stat_st_fstype" >&6
39726 if test $ac_cv_member_struct_stat_st_fstype = yes; then
39727
39728 cat >>confdefs.h <<_ACEOF
39729 #define HAVE_STRUCT_STAT_ST_FSTYPE 1
39730 _ACEOF
39731
39732
39733 fi
39734 echo "$as_me:$LINENO: checking for struct stat.st_vfstype" >&5
39735 echo $ECHO_N "checking for struct stat.st_vfstype... $ECHO_C" >&6
39736 if test "${ac_cv_member_struct_stat_st_vfstype+set}" = set; then
39737   echo $ECHO_N "(cached) $ECHO_C" >&6
39738 else
39739   cat >conftest.$ac_ext <<_ACEOF
39740 /* confdefs.h.  */
39741 _ACEOF
39742 cat confdefs.h >>conftest.$ac_ext
39743 cat >>conftest.$ac_ext <<_ACEOF
39744 /* end confdefs.h.  */
39745 $ac_includes_default
39746 int
39747 main ()
39748 {
39749 static struct stat ac_aggr;
39750 if (ac_aggr.st_vfstype)
39751 return 0;
39752   ;
39753   return 0;
39754 }
39755 _ACEOF
39756 rm -f conftest.$ac_objext
39757 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39758   (eval $ac_compile) 2>conftest.er1
39759   ac_status=$?
39760   grep -v '^ *+' conftest.er1 >conftest.err
39761   rm -f conftest.er1
39762   cat conftest.err >&5
39763   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39764   (exit $ac_status); } &&
39765          { ac_try='test -z "$ac_c_werror_flag"
39766                          || test ! -s conftest.err'
39767   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39768   (eval $ac_try) 2>&5
39769   ac_status=$?
39770   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39771   (exit $ac_status); }; } &&
39772          { ac_try='test -s conftest.$ac_objext'
39773   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39774   (eval $ac_try) 2>&5
39775   ac_status=$?
39776   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39777   (exit $ac_status); }; }; then
39778   ac_cv_member_struct_stat_st_vfstype=yes
39779 else
39780   echo "$as_me: failed program was:" >&5
39781 sed 's/^/| /' conftest.$ac_ext >&5
39782
39783 cat >conftest.$ac_ext <<_ACEOF
39784 /* confdefs.h.  */
39785 _ACEOF
39786 cat confdefs.h >>conftest.$ac_ext
39787 cat >>conftest.$ac_ext <<_ACEOF
39788 /* end confdefs.h.  */
39789 $ac_includes_default
39790 int
39791 main ()
39792 {
39793 static struct stat ac_aggr;
39794 if (sizeof ac_aggr.st_vfstype)
39795 return 0;
39796   ;
39797   return 0;
39798 }
39799 _ACEOF
39800 rm -f conftest.$ac_objext
39801 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39802   (eval $ac_compile) 2>conftest.er1
39803   ac_status=$?
39804   grep -v '^ *+' conftest.er1 >conftest.err
39805   rm -f conftest.er1
39806   cat conftest.err >&5
39807   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39808   (exit $ac_status); } &&
39809          { ac_try='test -z "$ac_c_werror_flag"
39810                          || test ! -s conftest.err'
39811   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39812   (eval $ac_try) 2>&5
39813   ac_status=$?
39814   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39815   (exit $ac_status); }; } &&
39816          { ac_try='test -s conftest.$ac_objext'
39817   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39818   (eval $ac_try) 2>&5
39819   ac_status=$?
39820   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39821   (exit $ac_status); }; }; then
39822   ac_cv_member_struct_stat_st_vfstype=yes
39823 else
39824   echo "$as_me: failed program was:" >&5
39825 sed 's/^/| /' conftest.$ac_ext >&5
39826
39827 ac_cv_member_struct_stat_st_vfstype=no
39828 fi
39829 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39830 fi
39831 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39832 fi
39833 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_vfstype" >&5
39834 echo "${ECHO_T}$ac_cv_member_struct_stat_st_vfstype" >&6
39835 if test $ac_cv_member_struct_stat_st_vfstype = yes; then
39836
39837 cat >>confdefs.h <<_ACEOF
39838 #define HAVE_STRUCT_STAT_ST_VFSTYPE 1
39839 _ACEOF
39840
39841
39842 fi
39843
39844                 if test "$ac_cv_member_struct_stat_st_fstype" = yes; then
39845                         cat >conftest.$ac_ext <<_ACEOF
39846 struct stat st; char *ptr=st.st_fstype;
39847 _ACEOF
39848 rm -f conftest.$ac_objext
39849 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39850   (eval $ac_compile) 2>conftest.er1
39851   ac_status=$?
39852   grep -v '^ *+' conftest.er1 >conftest.err
39853   rm -f conftest.er1
39854   cat conftest.err >&5
39855   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39856   (exit $ac_status); } &&
39857          { ac_try='test -z "$ac_c_werror_flag"
39858                          || test ! -s conftest.err'
39859   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39860   (eval $ac_try) 2>&5
39861   ac_status=$?
39862   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39863   (exit $ac_status); }; } &&
39864          { ac_try='test -s conftest.$ac_objext'
39865   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39866   (eval $ac_try) 2>&5
39867   ac_status=$?
39868   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39869   (exit $ac_status); }; }; then
39870
39871 cat >>confdefs.h <<\_ACEOF
39872 #define HAVE_STRUCT_STAT_ST_FSTYPE_CHAR 1
39873 _ACEOF
39874
39875 else
39876   echo "$as_me: failed program was:" >&5
39877 sed 's/^/| /' conftest.$ac_ext >&5
39878
39879
39880 cat >>confdefs.h <<\_ACEOF
39881 #define HAVE_STRUCT_STAT_ST_FSTYPE_INT 1
39882 _ACEOF
39883
39884 fi
39885 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39886                 fi
39887         fi
39888         LIBSRCS="$LIBSRCS getpeereid.c"
39889 fi
39890
39891 if test "$ac_cv_func_snprintf" != yes ||
39892    test "$ac_cv_func_vsnprintf" != yes; then
39893         if test "$ac_cv_func_snprintf" != yes; then
39894
39895 cat >>confdefs.h <<\_ACEOF
39896 #define snprintf ber_pvt_snprintf
39897 _ACEOF
39898
39899         fi
39900         if test "$ac_cv_func_vsnprintf" != yes; then
39901
39902 cat >>confdefs.h <<\_ACEOF
39903 #define vsnprintf ber_pvt_vsnprintf
39904 _ACEOF
39905
39906         fi
39907 fi
39908
39909
39910 if test "$ol_enable_slapi" != no ; then
39911
39912 for ac_header in ltdl.h
39913 do
39914 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
39915 if eval "test \"\${$as_ac_Header+set}\" = set"; then
39916   echo "$as_me:$LINENO: checking for $ac_header" >&5
39917 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
39918 if eval "test \"\${$as_ac_Header+set}\" = set"; then
39919   echo $ECHO_N "(cached) $ECHO_C" >&6
39920 fi
39921 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
39922 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
39923 else
39924   # Is the header compilable?
39925 echo "$as_me:$LINENO: checking $ac_header usability" >&5
39926 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
39927 cat >conftest.$ac_ext <<_ACEOF
39928 /* confdefs.h.  */
39929 _ACEOF
39930 cat confdefs.h >>conftest.$ac_ext
39931 cat >>conftest.$ac_ext <<_ACEOF
39932 /* end confdefs.h.  */
39933 $ac_includes_default
39934 #include <$ac_header>
39935 _ACEOF
39936 rm -f conftest.$ac_objext
39937 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39938   (eval $ac_compile) 2>conftest.er1
39939   ac_status=$?
39940   grep -v '^ *+' conftest.er1 >conftest.err
39941   rm -f conftest.er1
39942   cat conftest.err >&5
39943   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39944   (exit $ac_status); } &&
39945          { ac_try='test -z "$ac_c_werror_flag"
39946                          || test ! -s conftest.err'
39947   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39948   (eval $ac_try) 2>&5
39949   ac_status=$?
39950   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39951   (exit $ac_status); }; } &&
39952          { ac_try='test -s conftest.$ac_objext'
39953   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39954   (eval $ac_try) 2>&5
39955   ac_status=$?
39956   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39957   (exit $ac_status); }; }; then
39958   ac_header_compiler=yes
39959 else
39960   echo "$as_me: failed program was:" >&5
39961 sed 's/^/| /' conftest.$ac_ext >&5
39962
39963 ac_header_compiler=no
39964 fi
39965 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39966 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
39967 echo "${ECHO_T}$ac_header_compiler" >&6
39968
39969 # Is the header present?
39970 echo "$as_me:$LINENO: checking $ac_header presence" >&5
39971 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
39972 cat >conftest.$ac_ext <<_ACEOF
39973 /* confdefs.h.  */
39974 _ACEOF
39975 cat confdefs.h >>conftest.$ac_ext
39976 cat >>conftest.$ac_ext <<_ACEOF
39977 /* end confdefs.h.  */
39978 #include <$ac_header>
39979 _ACEOF
39980 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
39981   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
39982   ac_status=$?
39983   grep -v '^ *+' conftest.er1 >conftest.err
39984   rm -f conftest.er1
39985   cat conftest.err >&5
39986   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39987   (exit $ac_status); } >/dev/null; then
39988   if test -s conftest.err; then
39989     ac_cpp_err=$ac_c_preproc_warn_flag
39990     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
39991   else
39992     ac_cpp_err=
39993   fi
39994 else
39995   ac_cpp_err=yes
39996 fi
39997 if test -z "$ac_cpp_err"; then
39998   ac_header_preproc=yes
39999 else
40000   echo "$as_me: failed program was:" >&5
40001 sed 's/^/| /' conftest.$ac_ext >&5
40002
40003   ac_header_preproc=no
40004 fi
40005 rm -f conftest.err conftest.$ac_ext
40006 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
40007 echo "${ECHO_T}$ac_header_preproc" >&6
40008
40009 # So?  What about this header?
40010 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
40011   yes:no: )
40012     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
40013 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
40014     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
40015 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
40016     ac_header_preproc=yes
40017     ;;
40018   no:yes:* )
40019     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
40020 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
40021     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
40022 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
40023     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
40024 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
40025     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
40026 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
40027     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
40028 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
40029     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
40030 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
40031     (
40032       cat <<\_ASBOX
40033 ## --------------------------------------------- ##
40034 ## Report this to <http://www.openldap.org/its/> ##
40035 ## --------------------------------------------- ##
40036 _ASBOX
40037     ) |
40038       sed "s/^/$as_me: WARNING:     /" >&2
40039     ;;
40040 esac
40041 echo "$as_me:$LINENO: checking for $ac_header" >&5
40042 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
40043 if eval "test \"\${$as_ac_Header+set}\" = set"; then
40044   echo $ECHO_N "(cached) $ECHO_C" >&6
40045 else
40046   eval "$as_ac_Header=\$ac_header_preproc"
40047 fi
40048 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
40049 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
40050
40051 fi
40052 if test `eval echo '${'$as_ac_Header'}'` = yes; then
40053   cat >>confdefs.h <<_ACEOF
40054 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
40055 _ACEOF
40056
40057 fi
40058
40059 done
40060
40061
40062         if test $ac_cv_header_ltdl_h != yes ; then
40063                 { { echo "$as_me:$LINENO: error: could not locate <ltdl.h>" >&5
40064 echo "$as_me: error: could not locate <ltdl.h>" >&2;}
40065    { (exit 1); exit 1; }; }
40066         fi
40067         echo "$as_me:$LINENO: checking for lt_dlinit in -lltdl" >&5
40068 echo $ECHO_N "checking for lt_dlinit in -lltdl... $ECHO_C" >&6
40069 if test "${ac_cv_lib_ltdl_lt_dlinit+set}" = set; then
40070   echo $ECHO_N "(cached) $ECHO_C" >&6
40071 else
40072   ac_check_lib_save_LIBS=$LIBS
40073 LIBS="-lltdl  $LIBS"
40074 cat >conftest.$ac_ext <<_ACEOF
40075 /* confdefs.h.  */
40076 _ACEOF
40077 cat confdefs.h >>conftest.$ac_ext
40078 cat >>conftest.$ac_ext <<_ACEOF
40079 /* end confdefs.h.  */
40080
40081 /* Override any gcc2 internal prototype to avoid an error.  */
40082 #ifdef __cplusplus
40083 extern "C"
40084 #endif
40085 /* We use char because int might match the return type of a gcc2
40086    builtin and then its argument prototype would still apply.  */
40087 char lt_dlinit ();
40088 int
40089 main ()
40090 {
40091 lt_dlinit ();
40092   ;
40093   return 0;
40094 }
40095 _ACEOF
40096 rm -f conftest.$ac_objext conftest$ac_exeext
40097 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
40098   (eval $ac_link) 2>conftest.er1
40099   ac_status=$?
40100   grep -v '^ *+' conftest.er1 >conftest.err
40101   rm -f conftest.er1
40102   cat conftest.err >&5
40103   echo "$as_me:$LINENO: \$? = $ac_status" >&5
40104   (exit $ac_status); } &&
40105          { ac_try='test -z "$ac_c_werror_flag"
40106                          || test ! -s conftest.err'
40107   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
40108   (eval $ac_try) 2>&5
40109   ac_status=$?
40110   echo "$as_me:$LINENO: \$? = $ac_status" >&5
40111   (exit $ac_status); }; } &&
40112          { ac_try='test -s conftest$ac_exeext'
40113   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
40114   (eval $ac_try) 2>&5
40115   ac_status=$?
40116   echo "$as_me:$LINENO: \$? = $ac_status" >&5
40117   (exit $ac_status); }; }; then
40118   ac_cv_lib_ltdl_lt_dlinit=yes
40119 else
40120   echo "$as_me: failed program was:" >&5
40121 sed 's/^/| /' conftest.$ac_ext >&5
40122
40123 ac_cv_lib_ltdl_lt_dlinit=no
40124 fi
40125 rm -f conftest.err conftest.$ac_objext \
40126       conftest$ac_exeext conftest.$ac_ext
40127 LIBS=$ac_check_lib_save_LIBS
40128 fi
40129 echo "$as_me:$LINENO: result: $ac_cv_lib_ltdl_lt_dlinit" >&5
40130 echo "${ECHO_T}$ac_cv_lib_ltdl_lt_dlinit" >&6
40131 if test $ac_cv_lib_ltdl_lt_dlinit = yes; then
40132
40133                 SLAPI_LIBS=-lltdl
40134                 LIBSLAPI=libslapi.a
40135                 LIBSLAPITOOLS=../libslapi.a
40136
40137 cat >>confdefs.h <<\_ACEOF
40138 #define HAVE_LIBLTDL 1
40139 _ACEOF
40140
40141
40142 else
40143   { { echo "$as_me:$LINENO: error: could not locate libtool -lltdl" >&5
40144 echo "$as_me: error: could not locate libtool -lltdl" >&2;}
40145    { (exit 1); exit 1; }; }
40146 fi
40147
40148
40149
40150 cat >>confdefs.h <<\_ACEOF
40151 #define LDAP_SLAPI 1
40152 _ACEOF
40153
40154 fi
40155
40156 if test "$ol_enable_debug" != no ; then
40157         if test "$ol_enable_debug" = traditional; then
40158
40159 cat >>confdefs.h <<\_ACEOF
40160 #define OLD_DEBUG 1
40161 _ACEOF
40162
40163         fi
40164
40165 cat >>confdefs.h <<\_ACEOF
40166 #define LDAP_DEBUG 1
40167 _ACEOF
40168
40169 fi
40170 if test "$ol_enable_syslog" = yes ; then
40171
40172 cat >>confdefs.h <<\_ACEOF
40173 #define LDAP_SYSLOG 1
40174 _ACEOF
40175
40176 fi
40177 if test "$ol_enable_proctitle" != no ; then
40178
40179 cat >>confdefs.h <<\_ACEOF
40180 #define LDAP_PROCTITLE 1
40181 _ACEOF
40182
40183 fi
40184 if test "$ol_enable_referrals" != no ; then
40185
40186 cat >>confdefs.h <<\_ACEOF
40187 #define LDAP_API_FEATURE_X_OPENLDAP_V2_REFERRALS LDAP_VENDOR_VERSION
40188 _ACEOF
40189
40190 fi
40191 if test "$ol_enable_local" != no; then
40192
40193 cat >>confdefs.h <<\_ACEOF
40194 #define LDAP_PF_LOCAL 1
40195 _ACEOF
40196
40197 fi
40198 if test "$ol_link_ipv6" != no; then
40199
40200 cat >>confdefs.h <<\_ACEOF
40201 #define LDAP_PF_INET6 1
40202 _ACEOF
40203
40204 fi
40205 if test "$ol_enable_cleartext" != no ; then
40206
40207 cat >>confdefs.h <<\_ACEOF
40208 #define SLAPD_CLEARTEXT 1
40209 _ACEOF
40210
40211 fi
40212 if test "$ol_enable_crypt" != no ; then
40213
40214 cat >>confdefs.h <<\_ACEOF
40215 #define SLAPD_CRYPT 1
40216 _ACEOF
40217
40218 fi
40219 if test "$ol_link_spasswd" != no ; then
40220
40221 cat >>confdefs.h <<\_ACEOF
40222 #define SLAPD_SPASSWD 1
40223 _ACEOF
40224
40225 fi
40226 if test "$ol_enable_rlookups" != no ; then
40227
40228 cat >>confdefs.h <<\_ACEOF
40229 #define SLAPD_RLOOKUPS 1
40230 _ACEOF
40231
40232 fi
40233 if test "$ol_enable_aci" != no ; then
40234         if test $ol_enable_dynacl = no ; then
40235                 ol_enable_dynacl=yes
40236                 { echo "$as_me:$LINENO: WARNING: ACIs need dynacl" >&5
40237 echo "$as_me: WARNING: ACIs need dynacl" >&2;}
40238         fi
40239         if test "$ol_enable_aci" = mod ; then
40240                 MFLAG=SLAPD_MOD_DYNAMIC
40241                                 { { echo "$as_me:$LINENO: error: ACI build as dynamic module not supported (yet)" >&5
40242 echo "$as_me: error: ACI build as dynamic module not supported (yet)" >&2;}
40243    { (exit 1); exit 1; }; }
40244         else
40245                 MFLAG=SLAPD_MOD_STATIC
40246         fi
40247         WITH_ACI_ENABLED=$ol_enable_aci
40248
40249 cat >>confdefs.h <<_ACEOF
40250 #define SLAPD_ACI_ENABLED $MFLAG
40251 _ACEOF
40252
40253 else
40254         WITH_ACI_ENABLED=no
40255 fi
40256 if test "$ol_enable_dynacl" != no ; then
40257
40258 cat >>confdefs.h <<\_ACEOF
40259 #define SLAP_DYNACL 1
40260 _ACEOF
40261
40262 fi
40263
40264 if test "$ol_link_modules" != no ; then
40265
40266 cat >>confdefs.h <<\_ACEOF
40267 #define SLAPD_MODULES 1
40268 _ACEOF
40269
40270         BUILD_SLAPD=yes
40271         SLAPD_MODULES_LDFLAGS="-dlopen self"
40272 fi
40273
40274
40275 cat >>confdefs.h <<\_ACEOF
40276 #define SLAPD_MOD_STATIC 1
40277 _ACEOF
40278
40279
40280 cat >>confdefs.h <<\_ACEOF
40281 #define SLAPD_MOD_DYNAMIC 2
40282 _ACEOF
40283
40284
40285 if test "$ol_enable_monitor" != no ; then
40286         BUILD_SLAPD=yes
40287         BUILD_MONITOR=$ol_enable_monitor
40288         if test "$ol_enable_monitor" = mod ; then
40289                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-monitor"
40290                 MFLAG=SLAPD_MOD_DYNAMIC
40291         else
40292                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-monitor"
40293                 MFLAG=SLAPD_MOD_STATIC
40294         fi
40295
40296 cat >>confdefs.h <<_ACEOF
40297 #define SLAPD_MONITOR $MFLAG
40298 _ACEOF
40299
40300 fi
40301
40302 if test "$ol_enable_bdb" != no ; then
40303         BUILD_SLAPD=yes
40304         BUILD_BDB=$ol_enable_bdb
40305         if test "$ol_enable_bdb" = mod ; then
40306                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-bdb"
40307                 MFLAG=SLAPD_MOD_DYNAMIC
40308         else
40309                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-bdb"
40310                 MFLAG=SLAPD_MOD_STATIC
40311         fi
40312
40313 cat >>confdefs.h <<_ACEOF
40314 #define SLAPD_BDB $MFLAG
40315 _ACEOF
40316
40317 fi
40318
40319 if test "$ol_enable_dnssrv" != no ; then
40320         BUILD_SLAPD=yes
40321         BUILD_DNSSRV=$ol_enable_dnssrv
40322         if test "$ol_enable_dnssrv" = mod ; then
40323                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-dnssrv"
40324                 MFLAG=SLAPD_MOD_DYNAMIC
40325         else
40326                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-dnssrv"
40327                 MFLAG=SLAPD_MOD_STATIC
40328         fi
40329
40330 cat >>confdefs.h <<_ACEOF
40331 #define SLAPD_DNSSRV $MFLAG
40332 _ACEOF
40333
40334 fi
40335
40336 if test "$ol_enable_hdb" != no ; then
40337         BUILD_SLAPD=yes
40338         BUILD_HDB=$ol_enable_hdb
40339         if test "$ol_enable_hdb" = mod ; then
40340                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-hdb"
40341                 MFLAG=SLAPD_MOD_DYNAMIC
40342         else
40343                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-hdb"
40344                 MFLAG=SLAPD_MOD_STATIC
40345         fi
40346
40347 cat >>confdefs.h <<_ACEOF
40348 #define SLAPD_HDB $MFLAG
40349 _ACEOF
40350
40351 fi
40352
40353 if test "$ol_enable_ldap" != no ; then
40354         BUILD_SLAPD=yes
40355         BUILD_LDAP=$ol_enable_ldap
40356         if test "$ol_enable_ldap" = mod ; then
40357                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-ldap"
40358                 MFLAG=SLAPD_MOD_DYNAMIC
40359         else
40360                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-ldap"
40361                 MFLAG=SLAPD_MOD_STATIC
40362         fi
40363
40364 cat >>confdefs.h <<_ACEOF
40365 #define SLAPD_LDAP $MFLAG
40366 _ACEOF
40367
40368 fi
40369
40370 if test "$ol_enable_meta" != no ; then
40371         BUILD_SLAPD=yes
40372         BUILD_META=$ol_enable_meta
40373         BUILD_REWRITE=yes
40374         if test "$ol_enable_meta" = mod ; then
40375                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-meta"
40376                 MFLAG=SLAPD_MOD_DYNAMIC
40377         else
40378                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-meta"
40379                 MFLAG=SLAPD_MOD_STATIC
40380         fi
40381
40382 cat >>confdefs.h <<_ACEOF
40383 #define SLAPD_META $MFLAG
40384 _ACEOF
40385
40386 fi
40387
40388 if test "$ol_enable_null" != no ; then
40389         BUILD_SLAPD=yes
40390         BUILD_NULL=$ol_enable_null
40391         if test "$ol_enable_null" = mod ; then
40392                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-null"
40393                 MFLAG=SLAPD_MOD_DYNAMIC
40394         else
40395                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-null"
40396                 MFLAG=SLAPD_MOD_STATIC
40397         fi
40398
40399 cat >>confdefs.h <<_ACEOF
40400 #define SLAPD_NULL $MFLAG
40401 _ACEOF
40402
40403 fi
40404
40405 if test "$ol_enable_passwd" != no ; then
40406         BUILD_SLAPD=yes
40407         BUILD_PASSWD=$ol_enable_passwd
40408         if test "$ol_enable_passwd" = mod ; then
40409                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-passwd"
40410                 MFLAG=SLAPD_MOD_DYNAMIC
40411         else
40412                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-passwd"
40413                 MFLAG=SLAPD_MOD_STATIC
40414         fi
40415
40416 cat >>confdefs.h <<_ACEOF
40417 #define SLAPD_PASSWD $MFLAG
40418 _ACEOF
40419
40420 fi
40421
40422 if test "$ol_link_perl" != no ; then
40423         BUILD_SLAPD=yes
40424         BUILD_PERL=$ol_enable_perl
40425         if test "$ol_enable_perl" = mod ; then
40426                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-perl"
40427                 MFLAG=SLAPD_MOD_DYNAMIC
40428         else
40429                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-perl"
40430                 MFLAG=SLAPD_MOD_STATIC
40431         fi
40432
40433 cat >>confdefs.h <<_ACEOF
40434 #define SLAPD_PERL $MFLAG
40435 _ACEOF
40436
40437 fi
40438
40439 if test "$ol_enable_relay" != no ; then
40440         BUILD_SLAPD=yes
40441         BUILD_RELAY=$ol_enable_relay
40442         if test "$ol_enable_relay" = mod ; then
40443                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-relay"
40444                 MFLAG=SLAPD_MOD_DYNAMIC
40445         else
40446                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-relay"
40447                 MFLAG=SLAPD_MOD_STATIC
40448         fi
40449
40450 cat >>confdefs.h <<_ACEOF
40451 #define SLAPD_RELAY $MFLAG
40452 _ACEOF
40453
40454 fi
40455
40456 if test "$ol_enable_shell" != no ; then
40457         if test "$ol_link_threads" != no ; then
40458                 { echo "$as_me:$LINENO: WARNING: Use of --without-threads is recommended with back-shell" >&5
40459 echo "$as_me: WARNING: Use of --without-threads is recommended with back-shell" >&2;}
40460         fi
40461         BUILD_SLAPD=yes
40462         BUILD_SHELL=$ol_enable_shell
40463         if test "$ol_enable_shell" = mod ; then
40464                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-shell"
40465                 MFLAG=SLAPD_MOD_DYNAMIC
40466         else
40467                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-shell"
40468                 MFLAG=SLAPD_MOD_STATIC
40469         fi
40470
40471 cat >>confdefs.h <<_ACEOF
40472 #define SLAPD_SHELL $MFLAG
40473 _ACEOF
40474
40475 fi
40476
40477 if test "$ol_link_sql" != no ; then
40478         BUILD_SLAPD=yes
40479         BUILD_SQL=$ol_enable_sql
40480         if test "$ol_enable_sql" = mod; then
40481                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-sql"
40482                 MFLAG=SLAPD_MOD_DYNAMIC
40483         else
40484                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-sql"
40485                 MFLAG=SLAPD_MOD_STATIC
40486         fi
40487
40488 cat >>confdefs.h <<_ACEOF
40489 #define SLAPD_SQL $MFLAG
40490 _ACEOF
40491
40492 fi
40493
40494 if test "$ol_enable_accesslog" != no ; then
40495         BUILD_ACCESSLOG=$ol_enable_accesslog
40496         if test "$ol_enable_accesslog" = mod ; then
40497                 MFLAG=SLAPD_MOD_DYNAMIC
40498                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS accesslog.la"
40499         else
40500                 MFLAG=SLAPD_MOD_STATIC
40501                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS accesslog.o"
40502         fi
40503
40504 cat >>confdefs.h <<_ACEOF
40505 #define SLAPD_OVER_ACCESSLOG $MFLAG
40506 _ACEOF
40507
40508 fi
40509
40510 if test "$ol_enable_auditlog" != no ; then
40511         BUILD_AUDITLOG=$ol_enable_auditlog
40512         if test "$ol_enable_auditlog" = mod ; then
40513                 MFLAG=SLAPD_MOD_DYNAMIC
40514                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS auditlog.la"
40515         else
40516                 MFLAG=SLAPD_MOD_STATIC
40517                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS auditlog.o"
40518         fi
40519
40520 cat >>confdefs.h <<_ACEOF
40521 #define SLAPD_OVER_AUDITLOG $MFLAG
40522 _ACEOF
40523
40524 fi
40525
40526 if test "$ol_enable_constraint" != no ; then
40527         BUILD_CONSTRAINT=$ol_enable_constraint
40528         if test "$ol_enable_constraint" = mod ; then
40529                 MFLAG=SLAPD_MOD_DYNAMIC
40530                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS constraint.la"
40531         else
40532                 MFLAG=SLAPD_MOD_STATIC
40533                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS constraint.o"
40534         fi
40535
40536 cat >>confdefs.h <<_ACEOF
40537 #define SLAPD_OVER_CONSTRAINT $MFLAG
40538 _ACEOF
40539
40540 fi
40541
40542 if test "$ol_enable_dds" != no ; then
40543         BUILD_DDS=$ol_enable_dds
40544         if test "$ol_enable_dds" = mod ; then
40545                 MFLAG=SLAPD_MOD_DYNAMIC
40546                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS dds.la"
40547         else
40548                 MFLAG=SLAPD_MOD_STATIC
40549                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS dds.o"
40550         fi
40551
40552 cat >>confdefs.h <<_ACEOF
40553 #define SLAPD_OVER_DDS $MFLAG
40554 _ACEOF
40555
40556 fi
40557
40558 if test "$ol_enable_dyngroup" != no ; then
40559         BUILD_DYNGROUP=$ol_enable_dyngroup
40560         if test "$ol_enable_dyngroup" = mod ; then
40561                 MFLAG=SLAPD_MOD_DYNAMIC
40562                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS dyngroup.la"
40563         else
40564                 MFLAG=SLAPD_MOD_STATIC
40565                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS dyngroup.o"
40566         fi
40567
40568 cat >>confdefs.h <<_ACEOF
40569 #define SLAPD_OVER_DYNGROUP $MFLAG
40570 _ACEOF
40571
40572 fi
40573
40574 if test "$ol_enable_dynlist" != no ; then
40575         BUILD_DYNLIST=$ol_enable_dynlist
40576         if test "$ol_enable_dynlist" = mod ; then
40577                 MFLAG=SLAPD_MOD_DYNAMIC
40578                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS dynlist.la"
40579         else
40580                 MFLAG=SLAPD_MOD_STATIC
40581                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS dynlist.o"
40582         fi
40583
40584 cat >>confdefs.h <<_ACEOF
40585 #define SLAPD_OVER_DYNLIST $MFLAG
40586 _ACEOF
40587
40588 fi
40589
40590 if test "$ol_enable_memberof" != no ; then
40591         BUILD_MEMBEROF=$ol_enable_memberof
40592         if test "$ol_enable_memberof" = mod ; then
40593                 MFLAG=SLAPD_MOD_DYNAMIC
40594                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS memberof.la"
40595         else
40596                 MFLAG=SLAPD_MOD_STATIC
40597                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS memberof.o"
40598         fi
40599
40600 cat >>confdefs.h <<_ACEOF
40601 #define SLAPD_OVER_MEMBEROF $MFLAG
40602 _ACEOF
40603
40604 fi
40605
40606 if test "$ol_enable_ppolicy" != no ; then
40607         BUILD_PPOLICY=$ol_enable_ppolicy
40608         if test "$ol_enable_ppolicy" = mod ; then
40609                 MFLAG=SLAPD_MOD_DYNAMIC
40610                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS ppolicy.la"
40611         else
40612                 MFLAG=SLAPD_MOD_STATIC
40613                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS ppolicy.o"
40614         fi
40615
40616 cat >>confdefs.h <<_ACEOF
40617 #define SLAPD_OVER_PPOLICY $MFLAG
40618 _ACEOF
40619
40620 fi
40621
40622 if test "$ol_enable_proxycache" != no ; then
40623         BUILD_PROXYCACHE=$ol_enable_proxycache
40624         if test "$ol_enable_proxycache" = mod ; then
40625                 MFLAG=SLAPD_MOD_DYNAMIC
40626                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS pcache.la"
40627         else
40628                 MFLAG=SLAPD_MOD_STATIC
40629                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS pcache.o"
40630         fi
40631
40632 cat >>confdefs.h <<_ACEOF
40633 #define SLAPD_OVER_PROXYCACHE $MFLAG
40634 _ACEOF
40635
40636 fi
40637
40638 if test "$ol_enable_refint" != no ; then
40639         BUILD_REFINT=$ol_enable_refint
40640         if test "$ol_enable_refint" = mod ; then
40641                 MFLAG=SLAPD_MOD_DYNAMIC
40642                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS refint.la"
40643         else
40644                 MFLAG=SLAPD_MOD_STATIC
40645                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS refint.o"
40646         fi
40647
40648 cat >>confdefs.h <<_ACEOF
40649 #define SLAPD_OVER_REFINT $MFLAG
40650 _ACEOF
40651
40652 fi
40653
40654 if test "$ol_enable_retcode" != no ; then
40655         BUILD_RETCODE=$ol_enable_retcode
40656         if test "$ol_enable_retcode" = mod ; then
40657                 MFLAG=SLAPD_MOD_DYNAMIC
40658                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS retcode.la"
40659         else
40660                 MFLAG=SLAPD_MOD_STATIC
40661                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS retcode.o"
40662         fi
40663
40664 cat >>confdefs.h <<_ACEOF
40665 #define SLAPD_OVER_RETCODE $MFLAG
40666 _ACEOF
40667
40668 fi
40669
40670 if test "$ol_enable_rwm" != no ; then
40671         BUILD_REWRITE=yes
40672         BUILD_RWM=$ol_enable_rwm
40673         if test "$ol_enable_rwm" = mod ; then
40674                 MFLAG=SLAPD_MOD_DYNAMIC
40675                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS rwm.la"
40676         else
40677                 MFLAG=SLAPD_MOD_STATIC
40678                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS rwm_x.o"
40679         fi
40680
40681 cat >>confdefs.h <<_ACEOF
40682 #define SLAPD_OVER_RWM $MFLAG
40683 _ACEOF
40684
40685 fi
40686
40687 if test "$ol_enable_seqmod" != no ; then
40688         BUILD_SEQMOD=$ol_enable_seqmod
40689         if test "$ol_enable_seqmod" = mod ; then
40690                 MFLAG=SLAPD_MOD_DYNAMIC
40691                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS seqmod.la"
40692         else
40693                 MFLAG=SLAPD_MOD_STATIC
40694                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS seqmod.o"
40695         fi
40696
40697 cat >>confdefs.h <<_ACEOF
40698 #define SLAPD_OVER_SEQMOD $MFLAG
40699 _ACEOF
40700
40701 fi
40702
40703 if test "$ol_enable_syncprov" != no ; then
40704         BUILD_SYNCPROV=$ol_enable_syncprov
40705         if test "$ol_enable_syncprov" = mod ; then
40706                 MFLAG=SLAPD_MOD_DYNAMIC
40707                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS syncprov.la"
40708         else
40709                 MFLAG=SLAPD_MOD_STATIC
40710                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS syncprov.o"
40711         fi
40712
40713 cat >>confdefs.h <<_ACEOF
40714 #define SLAPD_OVER_SYNCPROV $MFLAG
40715 _ACEOF
40716
40717 fi
40718
40719 if test "$ol_enable_translucent" != no ; then
40720         BUILD_TRANSLUCENT=$ol_enable_translucent
40721         if test "$ol_enable_translucent" = mod ; then
40722                 MFLAG=SLAPD_MOD_DYNAMIC
40723                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS translucent.la"
40724         else
40725                 MFLAG=SLAPD_MOD_STATIC
40726                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS translucent.o"
40727         fi
40728
40729 cat >>confdefs.h <<_ACEOF
40730 #define SLAPD_OVER_TRANSLUCENT $MFLAG
40731 _ACEOF
40732
40733 fi
40734
40735 if test "$ol_enable_unique" != no ; then
40736         BUILD_UNIQUE=$ol_enable_unique
40737         if test "$ol_enable_unique" = mod ; then
40738                 MFLAG=SLAPD_MOD_DYNAMIC
40739                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS unique.la"
40740         else
40741                 MFLAG=SLAPD_MOD_STATIC
40742                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS unique.o"
40743         fi
40744
40745 cat >>confdefs.h <<_ACEOF
40746 #define SLAPD_OVER_UNIQUE $MFLAG
40747 _ACEOF
40748
40749 fi
40750
40751 if test "$ol_enable_valsort" != no ; then
40752         BUILD_VALSORT=$ol_enable_valsort
40753         if test "$ol_enable_valsort" = mod ; then
40754                 MFLAG=SLAPD_MOD_DYNAMIC
40755                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS valsort.la"
40756         else
40757                 MFLAG=SLAPD_MOD_STATIC
40758                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS valsort.o"
40759         fi
40760
40761 cat >>confdefs.h <<_ACEOF
40762 #define SLAPD_OVER_VALSORT $MFLAG
40763 _ACEOF
40764
40765 fi
40766
40767 if test "$ol_enable_rewrite" != no ; then
40768
40769 cat >>confdefs.h <<\_ACEOF
40770 #define ENABLE_REWRITE 1
40771 _ACEOF
40772
40773         BUILD_REWRITE=yes
40774 fi
40775
40776 if test "$ol_enable_slapi" != no ; then
40777
40778 cat >>confdefs.h <<\_ACEOF
40779 #define ENABLE_SLAPI 1
40780 _ACEOF
40781
40782         BUILD_SLAPI=yes
40783         SLAPD_SLAPI_DEPEND=libslapi.a
40784 fi
40785
40786
40787
40788 if test "$ac_cv_mingw32" = yes ; then
40789         PLAT=NT
40790         SLAPD_MODULES_LDFLAGS=
40791 else
40792         PLAT=UNIX
40793 fi
40794
40795
40796
40797
40798
40799
40800
40801
40802
40803
40804
40805
40806
40807
40808
40809
40810
40811
40812
40813
40814
40815
40816
40817
40818
40819
40820
40821
40822
40823
40824
40825
40826
40827
40828
40829
40830
40831
40832
40833
40834
40835
40836
40837
40838
40839
40840
40841
40842
40843
40844
40845
40846
40847
40848
40849
40850
40851
40852
40853
40854
40855
40856
40857
40858
40859
40860
40861
40862
40863
40864
40865
40866
40867
40868
40869
40870
40871
40872
40873
40874
40875
40876
40877
40878 # Check whether --with-xxinstall or --without-xxinstall was given.
40879 if test "${with_xxinstall+set}" = set; then
40880   withval="$with_xxinstall"
40881
40882 fi;
40883
40884
40885                                                                                                                                                                                                                                                                                                                                                                                             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 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"
40886
40887
40888           ac_config_commands="$ac_config_commands default"
40889
40890
40891
40892 test "x$prefix" = xNONE && prefix=$ac_default_prefix
40893 # Let make expand exec_prefix.
40894 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
40895
40896 # VPATH may cause trouble with some makes, so we remove $(srcdir),
40897 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
40898 # trailing colons and then remove the whole line if VPATH becomes empty
40899 # (actually we leave an empty line to preserve line numbers).
40900 if test "x$srcdir" = x.; then
40901   ac_vpsub='/^[  ]*VPATH[        ]*=/{
40902 s/:*\$(srcdir):*/:/;
40903 s/:*\${srcdir}:*/:/;
40904 s/:*@srcdir@:*/:/;
40905 s/^\([^=]*=[     ]*\):*/\1/;
40906 s/:*$//;
40907 s/^[^=]*=[       ]*$//;
40908 }'
40909 fi
40910
40911 DEFS=-DHAVE_CONFIG_H
40912
40913 ac_libobjs=
40914 ac_ltlibobjs=
40915 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
40916   # 1. Remove the extension, and $U if already installed.
40917   ac_i=`echo "$ac_i" |
40918          sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
40919   # 2. Add them.
40920   ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
40921   ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
40922 done
40923 LIBOBJS=$ac_libobjs
40924
40925 LTLIBOBJS=$ac_ltlibobjs
40926
40927
40928 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
40929   { { echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined.
40930 Usually this means the macro was only invoked conditionally." >&5
40931 echo "$as_me: error: conditional \"AMDEP\" was never defined.
40932 Usually this means the macro was only invoked conditionally." >&2;}
40933    { (exit 1); exit 1; }; }
40934 fi
40935 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
40936   { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
40937 Usually this means the macro was only invoked conditionally." >&5
40938 echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
40939 Usually this means the macro was only invoked conditionally." >&2;}
40940    { (exit 1); exit 1; }; }
40941 fi
40942 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
40943   { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
40944 Usually this means the macro was only invoked conditionally." >&5
40945 echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
40946 Usually this means the macro was only invoked conditionally." >&2;}
40947    { (exit 1); exit 1; }; }
40948 fi
40949
40950 : ${CONFIG_STATUS=./config.status}
40951 ac_clean_files_save=$ac_clean_files
40952 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
40953 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
40954 echo "$as_me: creating $CONFIG_STATUS" >&6;}
40955 cat >$CONFIG_STATUS <<_ACEOF
40956 #! $SHELL
40957 # Generated by $as_me.
40958 # Run this file to recreate the current configuration.
40959 # Compiler output produced by configure, useful for debugging
40960 # configure, is in config.log if it exists.
40961
40962 debug=false
40963 ac_cs_recheck=false
40964 ac_cs_silent=false
40965 SHELL=\${CONFIG_SHELL-$SHELL}
40966 _ACEOF
40967
40968 cat >>$CONFIG_STATUS <<\_ACEOF
40969 ## --------------------- ##
40970 ## M4sh Initialization.  ##
40971 ## --------------------- ##
40972
40973 # Be Bourne compatible
40974 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
40975   emulate sh
40976   NULLCMD=:
40977   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
40978   # is contrary to our usage.  Disable this feature.
40979   alias -g '${1+"$@"}'='"$@"'
40980 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
40981   set -o posix
40982 fi
40983 DUALCASE=1; export DUALCASE # for MKS sh
40984
40985 # Support unset when possible.
40986 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
40987   as_unset=unset
40988 else
40989   as_unset=false
40990 fi
40991
40992
40993 # Work around bugs in pre-3.0 UWIN ksh.
40994 $as_unset ENV MAIL MAILPATH
40995 PS1='$ '
40996 PS2='> '
40997 PS4='+ '
40998
40999 # NLS nuisances.
41000 for as_var in \
41001   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
41002   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
41003   LC_TELEPHONE LC_TIME
41004 do
41005   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
41006     eval $as_var=C; export $as_var
41007   else
41008     $as_unset $as_var
41009   fi
41010 done
41011
41012 # Required to use basename.
41013 if expr a : '\(a\)' >/dev/null 2>&1; then
41014   as_expr=expr
41015 else
41016   as_expr=false
41017 fi
41018
41019 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
41020   as_basename=basename
41021 else
41022   as_basename=false
41023 fi
41024
41025
41026 # Name of the executable.
41027 as_me=`$as_basename "$0" ||
41028 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
41029          X"$0" : 'X\(//\)$' \| \
41030          X"$0" : 'X\(/\)$' \| \
41031          .     : '\(.\)' 2>/dev/null ||
41032 echo X/"$0" |
41033     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
41034           /^X\/\(\/\/\)$/{ s//\1/; q; }
41035           /^X\/\(\/\).*/{ s//\1/; q; }
41036           s/.*/./; q'`
41037
41038
41039 # PATH needs CR, and LINENO needs CR and PATH.
41040 # Avoid depending upon Character Ranges.
41041 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
41042 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
41043 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
41044 as_cr_digits='0123456789'
41045 as_cr_alnum=$as_cr_Letters$as_cr_digits
41046
41047 # The user is always right.
41048 if test "${PATH_SEPARATOR+set}" != set; then
41049   echo "#! /bin/sh" >conf$$.sh
41050   echo  "exit 0"   >>conf$$.sh
41051   chmod +x conf$$.sh
41052   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
41053     PATH_SEPARATOR=';'
41054   else
41055     PATH_SEPARATOR=:
41056   fi
41057   rm -f conf$$.sh
41058 fi
41059
41060
41061   as_lineno_1=$LINENO
41062   as_lineno_2=$LINENO
41063   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
41064   test "x$as_lineno_1" != "x$as_lineno_2" &&
41065   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
41066   # Find who we are.  Look in the path if we contain no path at all
41067   # relative or not.
41068   case $0 in
41069     *[\\/]* ) as_myself=$0 ;;
41070     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
41071 for as_dir in $PATH
41072 do
41073   IFS=$as_save_IFS
41074   test -z "$as_dir" && as_dir=.
41075   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
41076 done
41077
41078        ;;
41079   esac
41080   # We did not find ourselves, most probably we were run as `sh COMMAND'
41081   # in which case we are not to be found in the path.
41082   if test "x$as_myself" = x; then
41083     as_myself=$0
41084   fi
41085   if test ! -f "$as_myself"; then
41086     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
41087 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
41088    { (exit 1); exit 1; }; }
41089   fi
41090   case $CONFIG_SHELL in
41091   '')
41092     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
41093 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
41094 do
41095   IFS=$as_save_IFS
41096   test -z "$as_dir" && as_dir=.
41097   for as_base in sh bash ksh sh5; do
41098          case $as_dir in
41099          /*)
41100            if ("$as_dir/$as_base" -c '
41101   as_lineno_1=$LINENO
41102   as_lineno_2=$LINENO
41103   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
41104   test "x$as_lineno_1" != "x$as_lineno_2" &&
41105   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
41106              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
41107              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
41108              CONFIG_SHELL=$as_dir/$as_base
41109              export CONFIG_SHELL
41110              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
41111            fi;;
41112          esac
41113        done
41114 done
41115 ;;
41116   esac
41117
41118   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
41119   # uniformly replaced by the line number.  The first 'sed' inserts a
41120   # line-number line before each line; the second 'sed' does the real
41121   # work.  The second script uses 'N' to pair each line-number line
41122   # with the numbered line, and appends trailing '-' during
41123   # substitution so that $LINENO is not a special case at line end.
41124   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
41125   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
41126   sed '=' <$as_myself |
41127     sed '
41128       N
41129       s,$,-,
41130       : loop
41131       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
41132       t loop
41133       s,-$,,
41134       s,^['$as_cr_digits']*\n,,
41135     ' >$as_me.lineno &&
41136   chmod +x $as_me.lineno ||
41137     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
41138 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
41139    { (exit 1); exit 1; }; }
41140
41141   # Don't try to exec as it changes $[0], causing all sort of problems
41142   # (the dirname of $[0] is not the place where we might find the
41143   # original and so on.  Autoconf is especially sensible to this).
41144   . ./$as_me.lineno
41145   # Exit status is that of the last command.
41146   exit
41147 }
41148
41149
41150 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
41151   *c*,-n*) ECHO_N= ECHO_C='
41152 ' ECHO_T='      ' ;;
41153   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
41154   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
41155 esac
41156
41157 if expr a : '\(a\)' >/dev/null 2>&1; then
41158   as_expr=expr
41159 else
41160   as_expr=false
41161 fi
41162
41163 rm -f conf$$ conf$$.exe conf$$.file
41164 echo >conf$$.file
41165 if ln -s conf$$.file conf$$ 2>/dev/null; then
41166   # We could just check for DJGPP; but this test a) works b) is more generic
41167   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
41168   if test -f conf$$.exe; then
41169     # Don't use ln at all; we don't have any links
41170     as_ln_s='cp -p'
41171   else
41172     as_ln_s='ln -s'
41173   fi
41174 elif ln conf$$.file conf$$ 2>/dev/null; then
41175   as_ln_s=ln
41176 else
41177   as_ln_s='cp -p'
41178 fi
41179 rm -f conf$$ conf$$.exe conf$$.file
41180
41181 if mkdir -p . 2>/dev/null; then
41182   as_mkdir_p=:
41183 else
41184   test -d ./-p && rmdir ./-p
41185   as_mkdir_p=false
41186 fi
41187
41188 as_executable_p="test -f"
41189
41190 # Sed expression to map a string onto a valid CPP name.
41191 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
41192
41193 # Sed expression to map a string onto a valid variable name.
41194 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
41195
41196
41197 # IFS
41198 # We need space, tab and new line, in precisely that order.
41199 as_nl='
41200 '
41201 IFS="   $as_nl"
41202
41203 # CDPATH.
41204 $as_unset CDPATH
41205
41206 exec 6>&1
41207
41208 # Open the log real soon, to keep \$[0] and so on meaningful, and to
41209 # report actual input values of CONFIG_FILES etc. instead of their
41210 # values after options handling.  Logging --version etc. is OK.
41211 exec 5>>config.log
41212 {
41213   echo
41214   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
41215 ## Running $as_me. ##
41216 _ASBOX
41217 } >&5
41218 cat >&5 <<_CSEOF
41219
41220 This file was extended by $as_me, which was
41221 generated by GNU Autoconf 2.59.  Invocation command line was
41222
41223   CONFIG_FILES    = $CONFIG_FILES
41224   CONFIG_HEADERS  = $CONFIG_HEADERS
41225   CONFIG_LINKS    = $CONFIG_LINKS
41226   CONFIG_COMMANDS = $CONFIG_COMMANDS
41227   $ $0 $@
41228
41229 _CSEOF
41230 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
41231 echo >&5
41232 _ACEOF
41233
41234 # Files that config.status was made for.
41235 if test -n "$ac_config_files"; then
41236   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
41237 fi
41238
41239 if test -n "$ac_config_headers"; then
41240   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
41241 fi
41242
41243 if test -n "$ac_config_links"; then
41244   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
41245 fi
41246
41247 if test -n "$ac_config_commands"; then
41248   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
41249 fi
41250
41251 cat >>$CONFIG_STATUS <<\_ACEOF
41252
41253 ac_cs_usage="\
41254 \`$as_me' instantiates files from templates according to the
41255 current configuration.
41256
41257 Usage: $0 [OPTIONS] [FILE]...
41258
41259   -h, --help       print this help, then exit
41260   -V, --version    print version number, then exit
41261   -q, --quiet      do not print progress messages
41262   -d, --debug      don't remove temporary files
41263       --recheck    update $as_me by reconfiguring in the same conditions
41264   --file=FILE[:TEMPLATE]
41265                    instantiate the configuration file FILE
41266   --header=FILE[:TEMPLATE]
41267                    instantiate the configuration header FILE
41268
41269 Configuration files:
41270 $config_files
41271
41272 Configuration headers:
41273 $config_headers
41274
41275 Configuration commands:
41276 $config_commands
41277
41278 Report bugs to <bug-autoconf@gnu.org>."
41279 _ACEOF
41280
41281 cat >>$CONFIG_STATUS <<_ACEOF
41282 ac_cs_version="\\
41283 config.status
41284 configured by $0, generated by GNU Autoconf 2.59,
41285   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
41286
41287 Copyright (C) 2003 Free Software Foundation, Inc.
41288 This config.status script is free software; the Free Software Foundation
41289 gives unlimited permission to copy, distribute and modify it."
41290 srcdir=$srcdir
41291 INSTALL="$INSTALL"
41292 _ACEOF
41293
41294 cat >>$CONFIG_STATUS <<\_ACEOF
41295 # If no file are specified by the user, then we need to provide default
41296 # value.  By we need to know if files were specified by the user.
41297 ac_need_defaults=:
41298 while test $# != 0
41299 do
41300   case $1 in
41301   --*=*)
41302     ac_option=`expr "x$1" : 'x\([^=]*\)='`
41303     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
41304     ac_shift=:
41305     ;;
41306   -*)
41307     ac_option=$1
41308     ac_optarg=$2
41309     ac_shift=shift
41310     ;;
41311   *) # This is not an option, so the user has probably given explicit
41312      # arguments.
41313      ac_option=$1
41314      ac_need_defaults=false;;
41315   esac
41316
41317   case $ac_option in
41318   # Handling of the options.
41319 _ACEOF
41320 cat >>$CONFIG_STATUS <<\_ACEOF
41321   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
41322     ac_cs_recheck=: ;;
41323   --version | --vers* | -V )
41324     echo "$ac_cs_version"; exit 0 ;;
41325   --he | --h)
41326     # Conflict between --help and --header
41327     { { echo "$as_me:$LINENO: error: ambiguous option: $1
41328 Try \`$0 --help' for more information." >&5
41329 echo "$as_me: error: ambiguous option: $1
41330 Try \`$0 --help' for more information." >&2;}
41331    { (exit 1); exit 1; }; };;
41332   --help | --hel | -h )
41333     echo "$ac_cs_usage"; exit 0 ;;
41334   --debug | --d* | -d )
41335     debug=: ;;
41336   --file | --fil | --fi | --f )
41337     $ac_shift
41338     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
41339     ac_need_defaults=false;;
41340   --header | --heade | --head | --hea )
41341     $ac_shift
41342     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
41343     ac_need_defaults=false;;
41344   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
41345   | -silent | --silent | --silen | --sile | --sil | --si | --s)
41346     ac_cs_silent=: ;;
41347
41348   # This is an error.
41349   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
41350 Try \`$0 --help' for more information." >&5
41351 echo "$as_me: error: unrecognized option: $1
41352 Try \`$0 --help' for more information." >&2;}
41353    { (exit 1); exit 1; }; } ;;
41354
41355   *) ac_config_targets="$ac_config_targets $1" ;;
41356
41357   esac
41358   shift
41359 done
41360
41361 ac_configure_extra_args=
41362
41363 if $ac_cs_silent; then
41364   exec 6>/dev/null
41365   ac_configure_extra_args="$ac_configure_extra_args --silent"
41366 fi
41367
41368 _ACEOF
41369 cat >>$CONFIG_STATUS <<_ACEOF
41370 if \$ac_cs_recheck; then
41371   echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
41372   exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
41373 fi
41374
41375 _ACEOF
41376
41377 cat >>$CONFIG_STATUS <<_ACEOF
41378 #
41379 # INIT-COMMANDS section.
41380 #
41381
41382 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
41383
41384 STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS"
41385 STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS"
41386
41387
41388 _ACEOF
41389
41390
41391
41392 cat >>$CONFIG_STATUS <<\_ACEOF
41393 for ac_config_target in $ac_config_targets
41394 do
41395   case "$ac_config_target" in
41396   # Handling of arguments.
41397   "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile:build/top.mk:Makefile.in:build/dir.mk" ;;
41398   "doc/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/Makefile:build/top.mk:doc/Makefile.in:build/dir.mk" ;;
41399   "doc/man/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/Makefile:build/top.mk:doc/man/Makefile.in:build/dir.mk" ;;
41400   "doc/man/man1/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man1/Makefile:build/top.mk:doc/man/man1/Makefile.in:build/man.mk" ;;
41401   "doc/man/man3/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man3/Makefile:build/top.mk:doc/man/man3/Makefile.in:build/man.mk" ;;
41402   "doc/man/man5/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man5/Makefile:build/top.mk:doc/man/man5/Makefile.in:build/man.mk" ;;
41403   "doc/man/man8/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man8/Makefile:build/top.mk:doc/man/man8/Makefile.in:build/man.mk" ;;
41404   "clients/Makefile" ) CONFIG_FILES="$CONFIG_FILES clients/Makefile:build/top.mk:clients/Makefile.in:build/dir.mk" ;;
41405   "clients/tools/Makefile" ) CONFIG_FILES="$CONFIG_FILES clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk" ;;
41406   "include/Makefile" ) CONFIG_FILES="$CONFIG_FILES include/Makefile:build/top.mk:include/Makefile.in" ;;
41407   "libraries/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/Makefile:build/top.mk:libraries/Makefile.in:build/dir.mk" ;;
41408   "libraries/liblber/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblber/Makefile:build/top.mk:libraries/liblber/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
41409   "libraries/libldap/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/libldap/Makefile:build/top.mk:libraries/libldap/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
41410   "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" ;;
41411   "libraries/liblunicode/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblunicode/Makefile:build/top.mk:libraries/liblunicode/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
41412   "libraries/liblutil/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblutil/Makefile:build/top.mk:libraries/liblutil/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
41413   "libraries/librewrite/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/librewrite/Makefile:build/top.mk:libraries/librewrite/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
41414   "servers/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/Makefile:build/top.mk:servers/Makefile.in:build/dir.mk" ;;
41415   "servers/slapd/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/Makefile:build/top.mk:servers/slapd/Makefile.in:build/srv.mk" ;;
41416   "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" ;;
41417   "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" ;;
41418   "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" ;;
41419   "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" ;;
41420   "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" ;;
41421   "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" ;;
41422   "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" ;;
41423   "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" ;;
41424   "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" ;;
41425   "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" ;;
41426   "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" ;;
41427   "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" ;;
41428   "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" ;;
41429   "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" ;;
41430   "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" ;;
41431   "servers/slapd/overlays/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/overlays/Makefile:build/top.mk:servers/slapd/overlays/Makefile.in:build/lib.mk" ;;
41432   "tests/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/Makefile:build/top.mk:tests/Makefile.in:build/dir.mk" ;;
41433   "tests/run" ) CONFIG_FILES="$CONFIG_FILES tests/run" ;;
41434   "tests/progs/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/progs/Makefile:build/top.mk:tests/progs/Makefile.in:build/rules.mk" ;;
41435   "depfiles" ) CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
41436   "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
41437   "include/portable.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/portable.h:include/portable.hin" ;;
41438   "include/ldap_features.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ldap_features.h:include/ldap_features.hin" ;;
41439   "include/lber_types.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/lber_types.h:include/lber_types.hin" ;;
41440   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
41441 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
41442    { (exit 1); exit 1; }; };;
41443   esac
41444 done
41445
41446 # If the user did not use the arguments to specify the items to instantiate,
41447 # then the envvar interface is used.  Set only those that are not.
41448 # We use the long form for the default assignment because of an extremely
41449 # bizarre bug on SunOS 4.1.3.
41450 if $ac_need_defaults; then
41451   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
41452   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
41453   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
41454 fi
41455
41456 # Have a temporary directory for convenience.  Make it in the build tree
41457 # simply because there is no reason to put it here, and in addition,
41458 # creating and moving files from /tmp can sometimes cause problems.
41459 # Create a temporary directory, and hook for its removal unless debugging.
41460 $debug ||
41461 {
41462   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
41463   trap '{ (exit 1); exit 1; }' 1 2 13 15
41464 }
41465
41466 # Create a (secure) tmp directory for tmp files.
41467
41468 {
41469   tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
41470   test -n "$tmp" && test -d "$tmp"
41471 }  ||
41472 {
41473   tmp=./confstat$$-$RANDOM
41474   (umask 077 && mkdir $tmp)
41475 } ||
41476 {
41477    echo "$me: cannot create a temporary directory in ." >&2
41478    { (exit 1); exit 1; }
41479 }
41480
41481 _ACEOF
41482
41483 cat >>$CONFIG_STATUS <<_ACEOF
41484
41485 #
41486 # CONFIG_FILES section.
41487 #
41488
41489 # No need to generate the scripts if there are no CONFIG_FILES.
41490 # This happens for instance when ./config.status config.h
41491 if test -n "\$CONFIG_FILES"; then
41492   # Protect against being on the right side of a sed subst in config.status.
41493   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
41494    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
41495 s,@SHELL@,$SHELL,;t t
41496 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
41497 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
41498 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
41499 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
41500 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
41501 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
41502 s,@exec_prefix@,$exec_prefix,;t t
41503 s,@prefix@,$prefix,;t t
41504 s,@program_transform_name@,$program_transform_name,;t t
41505 s,@bindir@,$bindir,;t t
41506 s,@sbindir@,$sbindir,;t t
41507 s,@libexecdir@,$libexecdir,;t t
41508 s,@datadir@,$datadir,;t t
41509 s,@sysconfdir@,$sysconfdir,;t t
41510 s,@sharedstatedir@,$sharedstatedir,;t t
41511 s,@localstatedir@,$localstatedir,;t t
41512 s,@libdir@,$libdir,;t t
41513 s,@includedir@,$includedir,;t t
41514 s,@oldincludedir@,$oldincludedir,;t t
41515 s,@infodir@,$infodir,;t t
41516 s,@mandir@,$mandir,;t t
41517 s,@build_alias@,$build_alias,;t t
41518 s,@host_alias@,$host_alias,;t t
41519 s,@target_alias@,$target_alias,;t t
41520 s,@DEFS@,$DEFS,;t t
41521 s,@ECHO_C@,$ECHO_C,;t t
41522 s,@ECHO_N@,$ECHO_N,;t t
41523 s,@ECHO_T@,$ECHO_T,;t t
41524 s,@LIBS@,$LIBS,;t t
41525 s,@build@,$build,;t t
41526 s,@build_cpu@,$build_cpu,;t t
41527 s,@build_vendor@,$build_vendor,;t t
41528 s,@build_os@,$build_os,;t t
41529 s,@host@,$host,;t t
41530 s,@host_cpu@,$host_cpu,;t t
41531 s,@host_vendor@,$host_vendor,;t t
41532 s,@host_os@,$host_os,;t t
41533 s,@target@,$target,;t t
41534 s,@target_cpu@,$target_cpu,;t t
41535 s,@target_vendor@,$target_vendor,;t t
41536 s,@target_os@,$target_os,;t t
41537 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
41538 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
41539 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
41540 s,@CYGPATH_W@,$CYGPATH_W,;t t
41541 s,@PACKAGE@,$PACKAGE,;t t
41542 s,@VERSION@,$VERSION,;t t
41543 s,@ACLOCAL@,$ACLOCAL,;t t
41544 s,@AUTOCONF@,$AUTOCONF,;t t
41545 s,@AUTOMAKE@,$AUTOMAKE,;t t
41546 s,@AUTOHEADER@,$AUTOHEADER,;t t
41547 s,@MAKEINFO@,$MAKEINFO,;t t
41548 s,@install_sh@,$install_sh,;t t
41549 s,@STRIP@,$STRIP,;t t
41550 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
41551 s,@INSTALL_STRIP_PROGRAM@,$INSTALL_STRIP_PROGRAM,;t t
41552 s,@mkdir_p@,$mkdir_p,;t t
41553 s,@AWK@,$AWK,;t t
41554 s,@SET_MAKE@,$SET_MAKE,;t t
41555 s,@am__leading_dot@,$am__leading_dot,;t t
41556 s,@AMTAR@,$AMTAR,;t t
41557 s,@am__tar@,$am__tar,;t t
41558 s,@am__untar@,$am__untar,;t t
41559 s,@OPENLDAP_LIBRELEASE@,$OPENLDAP_LIBRELEASE,;t t
41560 s,@OPENLDAP_LIBVERSION@,$OPENLDAP_LIBVERSION,;t t
41561 s,@OPENLDAP_RELEASE_DATE@,$OPENLDAP_RELEASE_DATE,;t t
41562 s,@top_builddir@,$top_builddir,;t t
41563 s,@ldap_subdir@,$ldap_subdir,;t t
41564 s,@CC@,$CC,;t t
41565 s,@AR@,$AR,;t t
41566 s,@CFLAGS@,$CFLAGS,;t t
41567 s,@LDFLAGS@,$LDFLAGS,;t t
41568 s,@CPPFLAGS@,$CPPFLAGS,;t t
41569 s,@ac_ct_CC@,$ac_ct_CC,;t t
41570 s,@EXEEXT@,$EXEEXT,;t t
41571 s,@OBJEXT@,$OBJEXT,;t t
41572 s,@DEPDIR@,$DEPDIR,;t t
41573 s,@am__include@,$am__include,;t t
41574 s,@am__quote@,$am__quote,;t t
41575 s,@AMDEP_TRUE@,$AMDEP_TRUE,;t t
41576 s,@AMDEP_FALSE@,$AMDEP_FALSE,;t t
41577 s,@AMDEPBACKSLASH@,$AMDEPBACKSLASH,;t t
41578 s,@CCDEPMODE@,$CCDEPMODE,;t t
41579 s,@am__fastdepCC_TRUE@,$am__fastdepCC_TRUE,;t t
41580 s,@am__fastdepCC_FALSE@,$am__fastdepCC_FALSE,;t t
41581 s,@EGREP@,$EGREP,;t t
41582 s,@LN_S@,$LN_S,;t t
41583 s,@ECHO@,$ECHO,;t t
41584 s,@ac_ct_AR@,$ac_ct_AR,;t t
41585 s,@RANLIB@,$RANLIB,;t t
41586 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
41587 s,@DLLTOOL@,$DLLTOOL,;t t
41588 s,@ac_ct_DLLTOOL@,$ac_ct_DLLTOOL,;t t
41589 s,@AS@,$AS,;t t
41590 s,@ac_ct_AS@,$ac_ct_AS,;t t
41591 s,@OBJDUMP@,$OBJDUMP,;t t
41592 s,@ac_ct_OBJDUMP@,$ac_ct_OBJDUMP,;t t
41593 s,@CPP@,$CPP,;t t
41594 s,@LIBTOOL@,$LIBTOOL,;t t
41595 s,@PERLBIN@,$PERLBIN,;t t
41596 s,@OL_MKDEP@,$OL_MKDEP,;t t
41597 s,@OL_MKDEP_FLAGS@,$OL_MKDEP_FLAGS,;t t
41598 s,@LTSTATIC@,$LTSTATIC,;t t
41599 s,@LIBOBJS@,$LIBOBJS,;t t
41600 s,@LIBSRCS@,$LIBSRCS,;t t
41601 s,@PLAT@,$PLAT,;t t
41602 s,@WITH_SASL@,$WITH_SASL,;t t
41603 s,@WITH_TLS@,$WITH_TLS,;t t
41604 s,@WITH_MODULES_ENABLED@,$WITH_MODULES_ENABLED,;t t
41605 s,@WITH_ACI_ENABLED@,$WITH_ACI_ENABLED,;t t
41606 s,@BUILD_THREAD@,$BUILD_THREAD,;t t
41607 s,@BUILD_LIBS_DYNAMIC@,$BUILD_LIBS_DYNAMIC,;t t
41608 s,@BUILD_SLAPD@,$BUILD_SLAPD,;t t
41609 s,@BUILD_SLAPI@,$BUILD_SLAPI,;t t
41610 s,@SLAPD_SLAPI_DEPEND@,$SLAPD_SLAPI_DEPEND,;t t
41611 s,@BUILD_BDB@,$BUILD_BDB,;t t
41612 s,@BUILD_DNSSRV@,$BUILD_DNSSRV,;t t
41613 s,@BUILD_HDB@,$BUILD_HDB,;t t
41614 s,@BUILD_LDAP@,$BUILD_LDAP,;t t
41615 s,@BUILD_META@,$BUILD_META,;t t
41616 s,@BUILD_MONITOR@,$BUILD_MONITOR,;t t
41617 s,@BUILD_NULL@,$BUILD_NULL,;t t
41618 s,@BUILD_PASSWD@,$BUILD_PASSWD,;t t
41619 s,@BUILD_RELAY@,$BUILD_RELAY,;t t
41620 s,@BUILD_PERL@,$BUILD_PERL,;t t
41621 s,@BUILD_SHELL@,$BUILD_SHELL,;t t
41622 s,@BUILD_SQL@,$BUILD_SQL,;t t
41623 s,@BUILD_ACCESSLOG@,$BUILD_ACCESSLOG,;t t
41624 s,@BUILD_AUDITLOG@,$BUILD_AUDITLOG,;t t
41625 s,@BUILD_CONSTRAINT@,$BUILD_CONSTRAINT,;t t
41626 s,@BUILD_DDS@,$BUILD_DDS,;t t
41627 s,@BUILD_DENYOP@,$BUILD_DENYOP,;t t
41628 s,@BUILD_DYNGROUP@,$BUILD_DYNGROUP,;t t
41629 s,@BUILD_DYNLIST@,$BUILD_DYNLIST,;t t
41630 s,@BUILD_LASTMOD@,$BUILD_LASTMOD,;t t
41631 s,@BUILD_MEMBEROF@,$BUILD_MEMBEROF,;t t
41632 s,@BUILD_PPOLICY@,$BUILD_PPOLICY,;t t
41633 s,@BUILD_PROXYCACHE@,$BUILD_PROXYCACHE,;t t
41634 s,@BUILD_REFINT@,$BUILD_REFINT,;t t
41635 s,@BUILD_RETCODE@,$BUILD_RETCODE,;t t
41636 s,@BUILD_RWM@,$BUILD_RWM,;t t
41637 s,@BUILD_SEQMOD@,$BUILD_SEQMOD,;t t
41638 s,@BUILD_SYNCPROV@,$BUILD_SYNCPROV,;t t
41639 s,@BUILD_TRANSLUCENT@,$BUILD_TRANSLUCENT,;t t
41640 s,@BUILD_UNIQUE@,$BUILD_UNIQUE,;t t
41641 s,@BUILD_VALSORT@,$BUILD_VALSORT,;t t
41642 s,@LDAP_LIBS@,$LDAP_LIBS,;t t
41643 s,@SLAPD_LIBS@,$SLAPD_LIBS,;t t
41644 s,@BDB_LIBS@,$BDB_LIBS,;t t
41645 s,@LTHREAD_LIBS@,$LTHREAD_LIBS,;t t
41646 s,@LUTIL_LIBS@,$LUTIL_LIBS,;t t
41647 s,@WRAP_LIBS@,$WRAP_LIBS,;t t
41648 s,@SLAPD_MODULES_CPPFLAGS@,$SLAPD_MODULES_CPPFLAGS,;t t
41649 s,@SLAPD_MODULES_LDFLAGS@,$SLAPD_MODULES_LDFLAGS,;t t
41650 s,@SLAPD_NO_STATIC@,$SLAPD_NO_STATIC,;t t
41651 s,@SLAPD_STATIC_BACKENDS@,$SLAPD_STATIC_BACKENDS,;t t
41652 s,@SLAPD_DYNAMIC_BACKENDS@,$SLAPD_DYNAMIC_BACKENDS,;t t
41653 s,@SLAPD_STATIC_OVERLAYS@,$SLAPD_STATIC_OVERLAYS,;t t
41654 s,@SLAPD_DYNAMIC_OVERLAYS@,$SLAPD_DYNAMIC_OVERLAYS,;t t
41655 s,@PERL_CPPFLAGS@,$PERL_CPPFLAGS,;t t
41656 s,@SLAPD_PERL_LDFLAGS@,$SLAPD_PERL_LDFLAGS,;t t
41657 s,@MOD_PERL_LDFLAGS@,$MOD_PERL_LDFLAGS,;t t
41658 s,@KRB4_LIBS@,$KRB4_LIBS,;t t
41659 s,@KRB5_LIBS@,$KRB5_LIBS,;t t
41660 s,@SASL_LIBS@,$SASL_LIBS,;t t
41661 s,@TLS_LIBS@,$TLS_LIBS,;t t
41662 s,@MODULES_LIBS@,$MODULES_LIBS,;t t
41663 s,@SLAPI_LIBS@,$SLAPI_LIBS,;t t
41664 s,@LIBSLAPI@,$LIBSLAPI,;t t
41665 s,@LIBSLAPITOOLS@,$LIBSLAPITOOLS,;t t
41666 s,@AUTH_LIBS@,$AUTH_LIBS,;t t
41667 s,@ICU_LIBS@,$ICU_LIBS,;t t
41668 s,@SLAPD_SLP_LIBS@,$SLAPD_SLP_LIBS,;t t
41669 s,@SLAPD_GMP_LIBS@,$SLAPD_GMP_LIBS,;t t
41670 s,@SLAPD_SQL_LDFLAGS@,$SLAPD_SQL_LDFLAGS,;t t
41671 s,@SLAPD_SQL_LIBS@,$SLAPD_SQL_LIBS,;t t
41672 s,@SLAPD_SQL_INCLUDES@,$SLAPD_SQL_INCLUDES,;t t
41673 s,@LTLIBOBJS@,$LTLIBOBJS,;t t
41674 CEOF
41675
41676 _ACEOF
41677
41678   cat >>$CONFIG_STATUS <<\_ACEOF
41679   # Split the substitutions into bite-sized pieces for seds with
41680   # small command number limits, like on Digital OSF/1 and HP-UX.
41681   ac_max_sed_lines=48
41682   ac_sed_frag=1 # Number of current file.
41683   ac_beg=1 # First line for current file.
41684   ac_end=$ac_max_sed_lines # Line after last line for current file.
41685   ac_more_lines=:
41686   ac_sed_cmds=
41687   while $ac_more_lines; do
41688     if test $ac_beg -gt 1; then
41689       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
41690     else
41691       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
41692     fi
41693     if test ! -s $tmp/subs.frag; then
41694       ac_more_lines=false
41695     else
41696       # The purpose of the label and of the branching condition is to
41697       # speed up the sed processing (if there are no `@' at all, there
41698       # is no need to browse any of the substitutions).
41699       # These are the two extra sed commands mentioned above.
41700       (echo ':t
41701   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
41702       if test -z "$ac_sed_cmds"; then
41703         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
41704       else
41705         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
41706       fi
41707       ac_sed_frag=`expr $ac_sed_frag + 1`
41708       ac_beg=$ac_end
41709       ac_end=`expr $ac_end + $ac_max_sed_lines`
41710     fi
41711   done
41712   if test -z "$ac_sed_cmds"; then
41713     ac_sed_cmds=cat
41714   fi
41715 fi # test -n "$CONFIG_FILES"
41716
41717 _ACEOF
41718 cat >>$CONFIG_STATUS <<\_ACEOF
41719 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
41720   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
41721   case $ac_file in
41722   - | *:- | *:-:* ) # input from stdin
41723         cat >$tmp/stdin
41724         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
41725         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
41726   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
41727         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
41728   * )   ac_file_in=$ac_file.in ;;
41729   esac
41730
41731   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
41732   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
41733 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
41734          X"$ac_file" : 'X\(//\)[^/]' \| \
41735          X"$ac_file" : 'X\(//\)$' \| \
41736          X"$ac_file" : 'X\(/\)' \| \
41737          .     : '\(.\)' 2>/dev/null ||
41738 echo X"$ac_file" |
41739     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
41740           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
41741           /^X\(\/\/\)$/{ s//\1/; q; }
41742           /^X\(\/\).*/{ s//\1/; q; }
41743           s/.*/./; q'`
41744   { if $as_mkdir_p; then
41745     mkdir -p "$ac_dir"
41746   else
41747     as_dir="$ac_dir"
41748     as_dirs=
41749     while test ! -d "$as_dir"; do
41750       as_dirs="$as_dir $as_dirs"
41751       as_dir=`(dirname "$as_dir") 2>/dev/null ||
41752 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
41753          X"$as_dir" : 'X\(//\)[^/]' \| \
41754          X"$as_dir" : 'X\(//\)$' \| \
41755          X"$as_dir" : 'X\(/\)' \| \
41756          .     : '\(.\)' 2>/dev/null ||
41757 echo X"$as_dir" |
41758     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
41759           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
41760           /^X\(\/\/\)$/{ s//\1/; q; }
41761           /^X\(\/\).*/{ s//\1/; q; }
41762           s/.*/./; q'`
41763     done
41764     test ! -n "$as_dirs" || mkdir $as_dirs
41765   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
41766 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
41767    { (exit 1); exit 1; }; }; }
41768
41769   ac_builddir=.
41770
41771 if test "$ac_dir" != .; then
41772   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
41773   # A "../" for each directory in $ac_dir_suffix.
41774   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
41775 else
41776   ac_dir_suffix= ac_top_builddir=
41777 fi
41778
41779 case $srcdir in
41780   .)  # No --srcdir option.  We are building in place.
41781     ac_srcdir=.
41782     if test -z "$ac_top_builddir"; then
41783        ac_top_srcdir=.
41784     else
41785        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
41786     fi ;;
41787   [\\/]* | ?:[\\/]* )  # Absolute path.
41788     ac_srcdir=$srcdir$ac_dir_suffix;
41789     ac_top_srcdir=$srcdir ;;
41790   *) # Relative path.
41791     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
41792     ac_top_srcdir=$ac_top_builddir$srcdir ;;
41793 esac
41794
41795 # Do not use `cd foo && pwd` to compute absolute paths, because
41796 # the directories may not exist.
41797 case `pwd` in
41798 .) ac_abs_builddir="$ac_dir";;
41799 *)
41800   case "$ac_dir" in
41801   .) ac_abs_builddir=`pwd`;;
41802   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
41803   *) ac_abs_builddir=`pwd`/"$ac_dir";;
41804   esac;;
41805 esac
41806 case $ac_abs_builddir in
41807 .) ac_abs_top_builddir=${ac_top_builddir}.;;
41808 *)
41809   case ${ac_top_builddir}. in
41810   .) ac_abs_top_builddir=$ac_abs_builddir;;
41811   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
41812   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
41813   esac;;
41814 esac
41815 case $ac_abs_builddir in
41816 .) ac_abs_srcdir=$ac_srcdir;;
41817 *)
41818   case $ac_srcdir in
41819   .) ac_abs_srcdir=$ac_abs_builddir;;
41820   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
41821   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
41822   esac;;
41823 esac
41824 case $ac_abs_builddir in
41825 .) ac_abs_top_srcdir=$ac_top_srcdir;;
41826 *)
41827   case $ac_top_srcdir in
41828   .) ac_abs_top_srcdir=$ac_abs_builddir;;
41829   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
41830   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
41831   esac;;
41832 esac
41833
41834
41835   case $INSTALL in
41836   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
41837   *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
41838   esac
41839
41840   if test x"$ac_file" != x-; then
41841     { echo "$as_me:$LINENO: creating $ac_file" >&5
41842 echo "$as_me: creating $ac_file" >&6;}
41843     rm -f "$ac_file"
41844   fi
41845   # Let's still pretend it is `configure' which instantiates (i.e., don't
41846   # use $as_me), people would be surprised to read:
41847   #    /* config.h.  Generated by config.status.  */
41848   if test x"$ac_file" = x-; then
41849     configure_input=
41850   else
41851     configure_input="$ac_file.  "
41852   fi
41853   configure_input=$configure_input"Generated from `echo $ac_file_in |
41854                                      sed 's,.*/,,'` by configure."
41855
41856   # First look for the input files in the build tree, otherwise in the
41857   # src tree.
41858   ac_file_inputs=`IFS=:
41859     for f in $ac_file_in; do
41860       case $f in
41861       -) echo $tmp/stdin ;;
41862       [\\/$]*)
41863          # Absolute (can't be DOS-style, as IFS=:)
41864          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
41865 echo "$as_me: error: cannot find input file: $f" >&2;}
41866    { (exit 1); exit 1; }; }
41867          echo "$f";;
41868       *) # Relative
41869          if test -f "$f"; then
41870            # Build tree
41871            echo "$f"
41872          elif test -f "$srcdir/$f"; then
41873            # Source tree
41874            echo "$srcdir/$f"
41875          else
41876            # /dev/null tree
41877            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
41878 echo "$as_me: error: cannot find input file: $f" >&2;}
41879    { (exit 1); exit 1; }; }
41880          fi;;
41881       esac
41882     done` || { (exit 1); exit 1; }
41883 _ACEOF
41884 cat >>$CONFIG_STATUS <<_ACEOF
41885   sed "$ac_vpsub
41886 $extrasub
41887 _ACEOF
41888 cat >>$CONFIG_STATUS <<\_ACEOF
41889 :t
41890 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
41891 s,@configure_input@,$configure_input,;t t
41892 s,@srcdir@,$ac_srcdir,;t t
41893 s,@abs_srcdir@,$ac_abs_srcdir,;t t
41894 s,@top_srcdir@,$ac_top_srcdir,;t t
41895 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
41896 s,@builddir@,$ac_builddir,;t t
41897 s,@abs_builddir@,$ac_abs_builddir,;t t
41898 s,@top_builddir@,$ac_top_builddir,;t t
41899 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
41900 s,@INSTALL@,$ac_INSTALL,;t t
41901 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
41902   rm -f $tmp/stdin
41903   if test x"$ac_file" != x-; then
41904     mv $tmp/out $ac_file
41905   else
41906     cat $tmp/out
41907     rm -f $tmp/out
41908   fi
41909
41910 done
41911 _ACEOF
41912 cat >>$CONFIG_STATUS <<\_ACEOF
41913
41914 #
41915 # CONFIG_HEADER section.
41916 #
41917
41918 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
41919 # NAME is the cpp macro being defined and VALUE is the value it is being given.
41920 #
41921 # ac_d sets the value in "#define NAME VALUE" lines.
41922 ac_dA='s,^\([    ]*\)#\([        ]*define[       ][      ]*\)'
41923 ac_dB='[         ].*$,\1#\2'
41924 ac_dC=' '
41925 ac_dD=',;t'
41926 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
41927 ac_uA='s,^\([    ]*\)#\([        ]*\)undef\([    ][      ]*\)'
41928 ac_uB='$,\1#\2define\3'
41929 ac_uC=' '
41930 ac_uD=',;t'
41931
41932 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
41933   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
41934   case $ac_file in
41935   - | *:- | *:-:* ) # input from stdin
41936         cat >$tmp/stdin
41937         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
41938         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
41939   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
41940         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
41941   * )   ac_file_in=$ac_file.in ;;
41942   esac
41943
41944   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
41945 echo "$as_me: creating $ac_file" >&6;}
41946
41947   # First look for the input files in the build tree, otherwise in the
41948   # src tree.
41949   ac_file_inputs=`IFS=:
41950     for f in $ac_file_in; do
41951       case $f in
41952       -) echo $tmp/stdin ;;
41953       [\\/$]*)
41954          # Absolute (can't be DOS-style, as IFS=:)
41955          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
41956 echo "$as_me: error: cannot find input file: $f" >&2;}
41957    { (exit 1); exit 1; }; }
41958          # Do quote $f, to prevent DOS paths from being IFS'd.
41959          echo "$f";;
41960       *) # Relative
41961          if test -f "$f"; then
41962            # Build tree
41963            echo "$f"
41964          elif test -f "$srcdir/$f"; then
41965            # Source tree
41966            echo "$srcdir/$f"
41967          else
41968            # /dev/null tree
41969            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
41970 echo "$as_me: error: cannot find input file: $f" >&2;}
41971    { (exit 1); exit 1; }; }
41972          fi;;
41973       esac
41974     done` || { (exit 1); exit 1; }
41975   # Remove the trailing spaces.
41976   sed 's/[       ]*$//' $ac_file_inputs >$tmp/in
41977
41978 _ACEOF
41979
41980 # Transform confdefs.h into two sed scripts, `conftest.defines' and
41981 # `conftest.undefs', that substitutes the proper values into
41982 # config.h.in to produce config.h.  The first handles `#define'
41983 # templates, and the second `#undef' templates.
41984 # And first: Protect against being on the right side of a sed subst in
41985 # config.status.  Protect against being in an unquoted here document
41986 # in config.status.
41987 rm -f conftest.defines conftest.undefs
41988 # Using a here document instead of a string reduces the quoting nightmare.
41989 # Putting comments in sed scripts is not portable.
41990 #
41991 # `end' is used to avoid that the second main sed command (meant for
41992 # 0-ary CPP macros) applies to n-ary macro definitions.
41993 # See the Autoconf documentation for `clear'.
41994 cat >confdef2sed.sed <<\_ACEOF
41995 s/[\\&,]/\\&/g
41996 s,[\\$`],\\&,g
41997 t clear
41998 : clear
41999 s,^[     ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
42000 t end
42001 s,^[     ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
42002 : end
42003 _ACEOF
42004 # If some macros were called several times there might be several times
42005 # the same #defines, which is useless.  Nevertheless, we may not want to
42006 # sort them, since we want the *last* AC-DEFINE to be honored.
42007 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
42008 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
42009 rm -f confdef2sed.sed
42010
42011 # This sed command replaces #undef with comments.  This is necessary, for
42012 # example, in the case of _POSIX_SOURCE, which is predefined and required
42013 # on some systems where configure will not decide to define it.
42014 cat >>conftest.undefs <<\_ACEOF
42015 s,^[     ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
42016 _ACEOF
42017
42018 # Break up conftest.defines because some shells have a limit on the size
42019 # of here documents, and old seds have small limits too (100 cmds).
42020 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
42021 echo '  if grep "^[      ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
42022 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
42023 echo '  :' >>$CONFIG_STATUS
42024 rm -f conftest.tail
42025 while grep . conftest.defines >/dev/null
42026 do
42027   # Write a limited-size here document to $tmp/defines.sed.
42028   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
42029   # Speed up: don't consider the non `#define' lines.
42030   echo '/^[      ]*#[    ]*define/!b' >>$CONFIG_STATUS
42031   # Work around the forget-to-reset-the-flag bug.
42032   echo 't clr' >>$CONFIG_STATUS
42033   echo ': clr' >>$CONFIG_STATUS
42034   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
42035   echo 'CEOF
42036   sed -f $tmp/defines.sed $tmp/in >$tmp/out
42037   rm -f $tmp/in
42038   mv $tmp/out $tmp/in
42039 ' >>$CONFIG_STATUS
42040   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
42041   rm -f conftest.defines
42042   mv conftest.tail conftest.defines
42043 done
42044 rm -f conftest.defines
42045 echo '  fi # grep' >>$CONFIG_STATUS
42046 echo >>$CONFIG_STATUS
42047
42048 # Break up conftest.undefs because some shells have a limit on the size
42049 # of here documents, and old seds have small limits too (100 cmds).
42050 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
42051 rm -f conftest.tail
42052 while grep . conftest.undefs >/dev/null
42053 do
42054   # Write a limited-size here document to $tmp/undefs.sed.
42055   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
42056   # Speed up: don't consider the non `#undef'
42057   echo '/^[      ]*#[    ]*undef/!b' >>$CONFIG_STATUS
42058   # Work around the forget-to-reset-the-flag bug.
42059   echo 't clr' >>$CONFIG_STATUS
42060   echo ': clr' >>$CONFIG_STATUS
42061   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
42062   echo 'CEOF
42063   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
42064   rm -f $tmp/in
42065   mv $tmp/out $tmp/in
42066 ' >>$CONFIG_STATUS
42067   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
42068   rm -f conftest.undefs
42069   mv conftest.tail conftest.undefs
42070 done
42071 rm -f conftest.undefs
42072
42073 cat >>$CONFIG_STATUS <<\_ACEOF
42074   # Let's still pretend it is `configure' which instantiates (i.e., don't
42075   # use $as_me), people would be surprised to read:
42076   #    /* config.h.  Generated by config.status.  */
42077   if test x"$ac_file" = x-; then
42078     echo "/* Generated by configure.  */" >$tmp/config.h
42079   else
42080     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
42081   fi
42082   cat $tmp/in >>$tmp/config.h
42083   rm -f $tmp/in
42084   if test x"$ac_file" != x-; then
42085     if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
42086       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
42087 echo "$as_me: $ac_file is unchanged" >&6;}
42088     else
42089       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
42090 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42091          X"$ac_file" : 'X\(//\)[^/]' \| \
42092          X"$ac_file" : 'X\(//\)$' \| \
42093          X"$ac_file" : 'X\(/\)' \| \
42094          .     : '\(.\)' 2>/dev/null ||
42095 echo X"$ac_file" |
42096     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42097           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42098           /^X\(\/\/\)$/{ s//\1/; q; }
42099           /^X\(\/\).*/{ s//\1/; q; }
42100           s/.*/./; q'`
42101       { if $as_mkdir_p; then
42102     mkdir -p "$ac_dir"
42103   else
42104     as_dir="$ac_dir"
42105     as_dirs=
42106     while test ! -d "$as_dir"; do
42107       as_dirs="$as_dir $as_dirs"
42108       as_dir=`(dirname "$as_dir") 2>/dev/null ||
42109 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42110          X"$as_dir" : 'X\(//\)[^/]' \| \
42111          X"$as_dir" : 'X\(//\)$' \| \
42112          X"$as_dir" : 'X\(/\)' \| \
42113          .     : '\(.\)' 2>/dev/null ||
42114 echo X"$as_dir" |
42115     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42116           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42117           /^X\(\/\/\)$/{ s//\1/; q; }
42118           /^X\(\/\).*/{ s//\1/; q; }
42119           s/.*/./; q'`
42120     done
42121     test ! -n "$as_dirs" || mkdir $as_dirs
42122   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
42123 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
42124    { (exit 1); exit 1; }; }; }
42125
42126       rm -f $ac_file
42127       mv $tmp/config.h $ac_file
42128     fi
42129   else
42130     cat $tmp/config.h
42131     rm -f $tmp/config.h
42132   fi
42133 # Compute $ac_file's index in $config_headers.
42134 _am_stamp_count=1
42135 for _am_header in $config_headers :; do
42136   case $_am_header in
42137     $ac_file | $ac_file:* )
42138       break ;;
42139     * )
42140       _am_stamp_count=`expr $_am_stamp_count + 1` ;;
42141   esac
42142 done
42143 echo "timestamp for $ac_file" >`(dirname $ac_file) 2>/dev/null ||
42144 $as_expr X$ac_file : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42145          X$ac_file : 'X\(//\)[^/]' \| \
42146          X$ac_file : 'X\(//\)$' \| \
42147          X$ac_file : 'X\(/\)' \| \
42148          .     : '\(.\)' 2>/dev/null ||
42149 echo X$ac_file |
42150     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42151           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42152           /^X\(\/\/\)$/{ s//\1/; q; }
42153           /^X\(\/\).*/{ s//\1/; q; }
42154           s/.*/./; q'`/stamp-h$_am_stamp_count
42155 done
42156 _ACEOF
42157 cat >>$CONFIG_STATUS <<\_ACEOF
42158
42159 #
42160 # CONFIG_COMMANDS section.
42161 #
42162 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
42163   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
42164   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
42165   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
42166 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42167          X"$ac_dest" : 'X\(//\)[^/]' \| \
42168          X"$ac_dest" : 'X\(//\)$' \| \
42169          X"$ac_dest" : 'X\(/\)' \| \
42170          .     : '\(.\)' 2>/dev/null ||
42171 echo X"$ac_dest" |
42172     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42173           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42174           /^X\(\/\/\)$/{ s//\1/; q; }
42175           /^X\(\/\).*/{ s//\1/; q; }
42176           s/.*/./; q'`
42177   { if $as_mkdir_p; then
42178     mkdir -p "$ac_dir"
42179   else
42180     as_dir="$ac_dir"
42181     as_dirs=
42182     while test ! -d "$as_dir"; do
42183       as_dirs="$as_dir $as_dirs"
42184       as_dir=`(dirname "$as_dir") 2>/dev/null ||
42185 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42186          X"$as_dir" : 'X\(//\)[^/]' \| \
42187          X"$as_dir" : 'X\(//\)$' \| \
42188          X"$as_dir" : 'X\(/\)' \| \
42189          .     : '\(.\)' 2>/dev/null ||
42190 echo X"$as_dir" |
42191     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42192           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42193           /^X\(\/\/\)$/{ s//\1/; q; }
42194           /^X\(\/\).*/{ s//\1/; q; }
42195           s/.*/./; q'`
42196     done
42197     test ! -n "$as_dirs" || mkdir $as_dirs
42198   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
42199 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
42200    { (exit 1); exit 1; }; }; }
42201
42202   ac_builddir=.
42203
42204 if test "$ac_dir" != .; then
42205   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
42206   # A "../" for each directory in $ac_dir_suffix.
42207   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
42208 else
42209   ac_dir_suffix= ac_top_builddir=
42210 fi
42211
42212 case $srcdir in
42213   .)  # No --srcdir option.  We are building in place.
42214     ac_srcdir=.
42215     if test -z "$ac_top_builddir"; then
42216        ac_top_srcdir=.
42217     else
42218        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
42219     fi ;;
42220   [\\/]* | ?:[\\/]* )  # Absolute path.
42221     ac_srcdir=$srcdir$ac_dir_suffix;
42222     ac_top_srcdir=$srcdir ;;
42223   *) # Relative path.
42224     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
42225     ac_top_srcdir=$ac_top_builddir$srcdir ;;
42226 esac
42227
42228 # Do not use `cd foo && pwd` to compute absolute paths, because
42229 # the directories may not exist.
42230 case `pwd` in
42231 .) ac_abs_builddir="$ac_dir";;
42232 *)
42233   case "$ac_dir" in
42234   .) ac_abs_builddir=`pwd`;;
42235   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
42236   *) ac_abs_builddir=`pwd`/"$ac_dir";;
42237   esac;;
42238 esac
42239 case $ac_abs_builddir in
42240 .) ac_abs_top_builddir=${ac_top_builddir}.;;
42241 *)
42242   case ${ac_top_builddir}. in
42243   .) ac_abs_top_builddir=$ac_abs_builddir;;
42244   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
42245   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
42246   esac;;
42247 esac
42248 case $ac_abs_builddir in
42249 .) ac_abs_srcdir=$ac_srcdir;;
42250 *)
42251   case $ac_srcdir in
42252   .) ac_abs_srcdir=$ac_abs_builddir;;
42253   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
42254   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
42255   esac;;
42256 esac
42257 case $ac_abs_builddir in
42258 .) ac_abs_top_srcdir=$ac_top_srcdir;;
42259 *)
42260   case $ac_top_srcdir in
42261   .) ac_abs_top_srcdir=$ac_abs_builddir;;
42262   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
42263   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
42264   esac;;
42265 esac
42266
42267
42268   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
42269 echo "$as_me: executing $ac_dest commands" >&6;}
42270   case $ac_dest in
42271     depfiles ) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do
42272   # Strip MF so we end up with the name of the file.
42273   mf=`echo "$mf" | sed -e 's/:.*$//'`
42274   # Check whether this is an Automake generated Makefile or not.
42275   # We used to match only the files named `Makefile.in', but
42276   # some people rename them; so instead we look at the file content.
42277   # Grep'ing the first line is not enough: some people post-process
42278   # each Makefile.in and add a new line on top of each file to say so.
42279   # So let's grep whole file.
42280   if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
42281     dirpart=`(dirname "$mf") 2>/dev/null ||
42282 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42283          X"$mf" : 'X\(//\)[^/]' \| \
42284          X"$mf" : 'X\(//\)$' \| \
42285          X"$mf" : 'X\(/\)' \| \
42286          .     : '\(.\)' 2>/dev/null ||
42287 echo X"$mf" |
42288     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42289           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42290           /^X\(\/\/\)$/{ s//\1/; q; }
42291           /^X\(\/\).*/{ s//\1/; q; }
42292           s/.*/./; q'`
42293   else
42294     continue
42295   fi
42296   # Extract the definition of DEPDIR, am__include, and am__quote
42297   # from the Makefile without running `make'.
42298   DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
42299   test -z "$DEPDIR" && continue
42300   am__include=`sed -n 's/^am__include = //p' < "$mf"`
42301   test -z "am__include" && continue
42302   am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
42303   # When using ansi2knr, U may be empty or an underscore; expand it
42304   U=`sed -n 's/^U = //p' < "$mf"`
42305   # Find all dependency output files, they are included files with
42306   # $(DEPDIR) in their names.  We invoke sed twice because it is the
42307   # simplest approach to changing $(DEPDIR) to its actual value in the
42308   # expansion.
42309   for file in `sed -n "
42310     s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
42311        sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
42312     # Make sure the directory exists.
42313     test -f "$dirpart/$file" && continue
42314     fdir=`(dirname "$file") 2>/dev/null ||
42315 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42316          X"$file" : 'X\(//\)[^/]' \| \
42317          X"$file" : 'X\(//\)$' \| \
42318          X"$file" : 'X\(/\)' \| \
42319          .     : '\(.\)' 2>/dev/null ||
42320 echo X"$file" |
42321     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42322           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42323           /^X\(\/\/\)$/{ s//\1/; q; }
42324           /^X\(\/\).*/{ s//\1/; q; }
42325           s/.*/./; q'`
42326     { if $as_mkdir_p; then
42327     mkdir -p $dirpart/$fdir
42328   else
42329     as_dir=$dirpart/$fdir
42330     as_dirs=
42331     while test ! -d "$as_dir"; do
42332       as_dirs="$as_dir $as_dirs"
42333       as_dir=`(dirname "$as_dir") 2>/dev/null ||
42334 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42335          X"$as_dir" : 'X\(//\)[^/]' \| \
42336          X"$as_dir" : 'X\(//\)$' \| \
42337          X"$as_dir" : 'X\(/\)' \| \
42338          .     : '\(.\)' 2>/dev/null ||
42339 echo X"$as_dir" |
42340     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42341           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42342           /^X\(\/\/\)$/{ s//\1/; q; }
42343           /^X\(\/\).*/{ s//\1/; q; }
42344           s/.*/./; q'`
42345     done
42346     test ! -n "$as_dirs" || mkdir $as_dirs
42347   fi || { { echo "$as_me:$LINENO: error: cannot create directory $dirpart/$fdir" >&5
42348 echo "$as_me: error: cannot create directory $dirpart/$fdir" >&2;}
42349    { (exit 1); exit 1; }; }; }
42350
42351     # echo "creating $dirpart/$file"
42352     echo '# dummy' > "$dirpart/$file"
42353   done
42354 done
42355  ;;
42356     default )
42357 chmod +x tests/run
42358 date > stamp-h
42359 BACKENDSC="servers/slapd/backends.c"
42360 echo "Making $BACKENDSC"
42361 rm -f $BACKENDSC
42362 cat > $BACKENDSC << ENDX
42363 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
42364  *
42365  * Copyright 1998-2007 The OpenLDAP Foundation.
42366  * All rights reserved.
42367  *
42368  * Redistribution and use in source and binary forms, with or without
42369  * modification, are permitted only as authorized by the OpenLDAP
42370  * Public License.
42371  *
42372  * A copy of this license is available in the file LICENSE in the
42373  * top-level directory of the distribution or, alternatively, at
42374  * <http://www.OpenLDAP.org/license.html>.
42375  */
42376 /* This file is automatically generated by configure; please do not edit. */
42377
42378 #include "portable.h"
42379 #include "slap.h"
42380
42381 ENDX
42382 if test "${STATIC_BACKENDS}"; then
42383         for b in config ${STATIC_BACKENDS}; do
42384                 bb=`echo "${b}" | sed -e 's/back-//'`
42385                 cat >> $BACKENDSC << ENDX
42386 extern BI_init ${bb}_back_initialize;
42387 ENDX
42388         done
42389
42390         cat >> $BACKENDSC << ENDX
42391
42392 BackendInfo slap_binfo[] = {
42393 ENDX
42394
42395         for b in config ${STATIC_BACKENDS}; do
42396                 bb=`echo "${b}" | sed -e 's/back-//'`
42397                 echo "    Add ${bb} ..."
42398                 cat >> $BACKENDSC << ENDX
42399         { "${bb}", ${bb}_back_initialize },
42400 ENDX
42401         done
42402
42403         cat >> $BACKENDSC << ENDX
42404         { NULL, NULL },
42405 };
42406
42407 /* end of generated file */
42408 ENDX
42409 fi
42410 OVERLAYSC="servers/slapd/overlays/statover.c"
42411 echo "Making $OVERLAYSC"
42412 rm -f $OVERLAYSC
42413 cat > $OVERLAYSC << ENDX
42414 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
42415  *
42416  * Copyright 1998-2007 The OpenLDAP Foundation.
42417  * All rights reserved.
42418  *
42419  * Redistribution and use in source and binary forms, with or without
42420  * modification, are permitted only as authorized by the OpenLDAP
42421  * Public License.
42422  *
42423  * A copy of this license is available in the file LICENSE in the
42424  * top-level directory of the distribution or, alternatively, at
42425  * <http://www.OpenLDAP.org/license.html>.
42426  */
42427 /* This file is automatically generated by configure; please do not edit. */
42428
42429 #include "portable.h"
42430 #include "slap.h"
42431
42432 ENDX
42433 if test "${STATIC_OVERLAYS}"; then
42434         for o in ${STATIC_OVERLAYS}; do
42435                 oo=`echo "${o}" | sed -e 's/.o$//' -e 's/_x$//'`
42436                 cat >> $OVERLAYSC << ENDX
42437 extern OV_init ${oo}_initialize;
42438 ENDX
42439         done
42440 fi
42441
42442 cat >> $OVERLAYSC << ENDX
42443
42444 OverlayInit slap_oinfo[] = {
42445 ENDX
42446
42447 if test "${STATIC_OVERLAYS}"; then
42448         for o in ${STATIC_OVERLAYS}; do
42449                 oo=`echo "${o}" | sed -e 's/.o$//' -e 's/_x$//'`
42450                 echo "    Add ${oo} ..."
42451                 cat >> $OVERLAYSC << ENDX
42452         { "${oo}", ${oo}_initialize },
42453 ENDX
42454         done
42455 fi
42456
42457         cat >> $OVERLAYSC << ENDX
42458         { NULL, NULL },
42459 };
42460
42461 /* end of generated file */
42462 ENDX
42463
42464 if test "${ol_cv_mkdep}" = no; then
42465         echo '(Do not "make depend"; we do not know how to build dependencies)'
42466 else
42467         echo 'Please run "make depend" to build dependencies'
42468 fi
42469  ;;
42470   esac
42471 done
42472 _ACEOF
42473
42474 cat >>$CONFIG_STATUS <<\_ACEOF
42475
42476 { (exit 0); exit 0; }
42477 _ACEOF
42478 chmod +x $CONFIG_STATUS
42479 ac_clean_files=$ac_clean_files_save
42480
42481
42482 # configure is writing to config.log, and then calls config.status.
42483 # config.status does its own redirection, appending to config.log.
42484 # Unfortunately, on DOS this fails, as config.log is still kept open
42485 # by configure, so config.status won't be able to write to it; its
42486 # output is simply discarded.  So we exec the FD to /dev/null,
42487 # effectively closing config.log, so it can be properly (re)opened and
42488 # appended to by config.status.  When coming back to configure, we
42489 # need to make the FD available again.
42490 if test "$no_create" != yes; then
42491   ac_cs_success=:
42492   ac_config_status_args=
42493   test "$silent" = yes &&
42494     ac_config_status_args="$ac_config_status_args --quiet"
42495   exec 5>/dev/null
42496   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
42497   exec 5>>config.log
42498   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
42499   # would make configure fail if this is the last instruction.
42500   $ac_cs_success || { (exit 1); exit 1; }
42501 fi
42502