]> git.sur5r.net Git - openldap/blob - configure
Sync with HEAD
[openldap] / configure
1 #! /bin/sh
2 # From configure.in OpenLDAP: pkg/ldap/configure.in,v 1.631.2.9 2008/02/11 23:26:37 kurt Exp .
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated by GNU Autoconf 2.59.
5 #
6 # Copyright 1998-2008 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_SOCK 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-sock         enable sock backend no|yes|mod [no]
1045     --enable-sql          enable sql backend no|yes|mod [no]
1046
1047 SLAPD Overlay Options:
1048     --enable-overlays     enable all available overlays no|yes|mod
1049     --enable-accesslog    In-Directory Access Logging overlay no|yes|mod [no]
1050     --enable-auditlog     Audit Logging overlay no|yes|mod [no]
1051     --enable-constraint   Attribute Constraint overlay no|yes|mod [no]
1052     --enable-dds          Dynamic Directory Services overlay no|yes|mod [no]
1053     --enable-dyngroup     Dynamic Group overlay no|yes|mod [no]
1054     --enable-dynlist      Dynamic List overlay no|yes|mod [no]
1055     --enable-memberof     Reverse Group Membership overlay no|yes|mod [no]
1056     --enable-ppolicy      Password Policy overlay no|yes|mod [no]
1057     --enable-proxycache   Proxy Cache overlay no|yes|mod [no]
1058     --enable-refint       Referential Integrity overlay no|yes|mod [no]
1059     --enable-retcode      Return Code testing overlay no|yes|mod [no]
1060     --enable-rwm          Rewrite/Remap overlay no|yes|mod [no]
1061     --enable-seqmod       Sequential Modify overlay no|yes|mod [yes]
1062     --enable-syncprov     Syncrepl Provider overlay no|yes|mod [yes]
1063     --enable-translucent  Translucent Proxy overlay no|yes|mod [no]
1064     --enable-unique       Attribute Uniqueness overlay no|yes|mod [no]
1065     --enable-valsort      Value Sorting overlay no|yes|mod [no]
1066
1067 Library Generation & Linking Options
1068   --enable-static[=PKGS]
1069                           build static libraries [default=yes]
1070   --enable-shared[=PKGS]
1071                           build shared libraries [default=yes]
1072   --enable-fast-install[=PKGS]
1073                           optimize for fast installation [default=yes]
1074   --disable-dependency-tracking  speeds up one-time build
1075   --enable-dependency-tracking   do not reject slow dependency extractors
1076   --disable-libtool-lock  avoid locking (might break parallel builds)
1077
1078 Optional Packages:
1079   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1080   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1081   --with-subdir=DIR       change default subdirectory used for installs
1082   --with-cyrus-sasl       with Cyrus SASL support [auto]
1083   --with-fetch            with fetch(3) URL support [auto]
1084   --with-threads          with threads [auto]
1085   --with-tls              with TLS/SSL support auto|openssl|gnutls [auto]
1086   --with-yielding-select  with implicitly yielding select [auto]
1087   --with-mp               with multiple precision statistics auto|longlong|long|bignum|gmp [auto]
1088   --with-odbc             with specific ODBC support iodbc|unixodbc|auto [auto]
1089   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1090   --with-pic              try to use only PIC/non-PIC objects [default=use
1091                           both]
1092   --with-tags[=TAGS]
1093                           include additional configurations [automatic]
1094
1095 See INSTALL file for further details.
1096
1097 Some influential environment variables:
1098   CC          C compiler command
1099   CFLAGS      C compiler flags
1100   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1101               nonstandard directory <lib dir>
1102   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
1103               headers in a nonstandard directory <include dir>
1104   CPP         C preprocessor
1105
1106 Use these variables to override the choices made by `configure' or to help
1107 it to find libraries and programs with nonstandard names/locations.
1108
1109 _ACEOF
1110 fi
1111
1112 if test "$ac_init_help" = "recursive"; then
1113   # If there are subdirs, report their specific --help.
1114   ac_popdir=`pwd`
1115   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1116     test -d $ac_dir || continue
1117     ac_builddir=.
1118
1119 if test "$ac_dir" != .; then
1120   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
1121   # A "../" for each directory in $ac_dir_suffix.
1122   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
1123 else
1124   ac_dir_suffix= ac_top_builddir=
1125 fi
1126
1127 case $srcdir in
1128   .)  # No --srcdir option.  We are building in place.
1129     ac_srcdir=.
1130     if test -z "$ac_top_builddir"; then
1131        ac_top_srcdir=.
1132     else
1133        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
1134     fi ;;
1135   [\\/]* | ?:[\\/]* )  # Absolute path.
1136     ac_srcdir=$srcdir$ac_dir_suffix;
1137     ac_top_srcdir=$srcdir ;;
1138   *) # Relative path.
1139     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
1140     ac_top_srcdir=$ac_top_builddir$srcdir ;;
1141 esac
1142
1143 # Do not use `cd foo && pwd` to compute absolute paths, because
1144 # the directories may not exist.
1145 case `pwd` in
1146 .) ac_abs_builddir="$ac_dir";;
1147 *)
1148   case "$ac_dir" in
1149   .) ac_abs_builddir=`pwd`;;
1150   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
1151   *) ac_abs_builddir=`pwd`/"$ac_dir";;
1152   esac;;
1153 esac
1154 case $ac_abs_builddir in
1155 .) ac_abs_top_builddir=${ac_top_builddir}.;;
1156 *)
1157   case ${ac_top_builddir}. in
1158   .) ac_abs_top_builddir=$ac_abs_builddir;;
1159   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
1160   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
1161   esac;;
1162 esac
1163 case $ac_abs_builddir in
1164 .) ac_abs_srcdir=$ac_srcdir;;
1165 *)
1166   case $ac_srcdir in
1167   .) ac_abs_srcdir=$ac_abs_builddir;;
1168   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
1169   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
1170   esac;;
1171 esac
1172 case $ac_abs_builddir in
1173 .) ac_abs_top_srcdir=$ac_top_srcdir;;
1174 *)
1175   case $ac_top_srcdir in
1176   .) ac_abs_top_srcdir=$ac_abs_builddir;;
1177   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
1178   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
1179   esac;;
1180 esac
1181
1182     cd $ac_dir
1183     # Check for guested configure; otherwise get Cygnus style configure.
1184     if test -f $ac_srcdir/configure.gnu; then
1185       echo
1186       $SHELL $ac_srcdir/configure.gnu  --help=recursive
1187     elif test -f $ac_srcdir/configure; then
1188       echo
1189       $SHELL $ac_srcdir/configure  --help=recursive
1190     elif test -f $ac_srcdir/configure.ac ||
1191            test -f $ac_srcdir/configure.in; then
1192       echo
1193       $ac_configure --help
1194     else
1195       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1196     fi
1197     cd $ac_popdir
1198   done
1199 fi
1200
1201 test -n "$ac_init_help" && exit 0
1202 if $ac_init_version; then
1203   cat <<\_ACEOF
1204
1205 Copyright (C) 2003 Free Software Foundation, Inc.
1206 This configure script is free software; the Free Software Foundation
1207 gives unlimited permission to copy, distribute and modify it.
1208
1209 Copyright 1998-2008 The OpenLDAP Foundation. All rights reserved.
1210 Restrictions apply, see COPYRIGHT and LICENSE files.
1211 _ACEOF
1212   exit 0
1213 fi
1214 exec 5>config.log
1215 cat >&5 <<_ACEOF
1216 This file contains any messages produced by compilers while
1217 running configure, to aid debugging if configure makes a mistake.
1218
1219 It was created by $as_me, which was
1220 generated by GNU Autoconf 2.59.  Invocation command line was
1221
1222   $ $0 $@
1223
1224 _ACEOF
1225 {
1226 cat <<_ASUNAME
1227 ## --------- ##
1228 ## Platform. ##
1229 ## --------- ##
1230
1231 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1232 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1233 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1234 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1235 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1236
1237 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1238 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1239
1240 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1241 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1242 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1243 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
1244 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1245 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1246 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1247
1248 _ASUNAME
1249
1250 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1251 for as_dir in $PATH
1252 do
1253   IFS=$as_save_IFS
1254   test -z "$as_dir" && as_dir=.
1255   echo "PATH: $as_dir"
1256 done
1257
1258 } >&5
1259
1260 cat >&5 <<_ACEOF
1261
1262
1263 ## ----------- ##
1264 ## Core tests. ##
1265 ## ----------- ##
1266
1267 _ACEOF
1268
1269
1270 # Keep a trace of the command line.
1271 # Strip out --no-create and --no-recursion so they do not pile up.
1272 # Strip out --silent because we don't want to record it for future runs.
1273 # Also quote any args containing shell meta-characters.
1274 # Make two passes to allow for proper duplicate-argument suppression.
1275 ac_configure_args=
1276 ac_configure_args0=
1277 ac_configure_args1=
1278 ac_sep=
1279 ac_must_keep_next=false
1280 for ac_pass in 1 2
1281 do
1282   for ac_arg
1283   do
1284     case $ac_arg in
1285     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1286     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1287     | -silent | --silent | --silen | --sile | --sil)
1288       continue ;;
1289     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1290       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1291     esac
1292     case $ac_pass in
1293     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1294     2)
1295       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1296       if test $ac_must_keep_next = true; then
1297         ac_must_keep_next=false # Got value, back to normal.
1298       else
1299         case $ac_arg in
1300           *=* | --config-cache | -C | -disable-* | --disable-* \
1301           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1302           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1303           | -with-* | --with-* | -without-* | --without-* | --x)
1304             case "$ac_configure_args0 " in
1305               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1306             esac
1307             ;;
1308           -* ) ac_must_keep_next=true ;;
1309         esac
1310       fi
1311       ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1312       # Get rid of the leading space.
1313       ac_sep=" "
1314       ;;
1315     esac
1316   done
1317 done
1318 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1319 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1320
1321 # When interrupted or exit'd, cleanup temporary files, and complete
1322 # config.log.  We remove comments because anyway the quotes in there
1323 # would cause problems or look ugly.
1324 # WARNING: Be sure not to use single quotes in there, as some shells,
1325 # such as our DU 5.0 friend, will then `close' the trap.
1326 trap 'exit_status=$?
1327   # Save into config.log some information that might help in debugging.
1328   {
1329     echo
1330
1331     cat <<\_ASBOX
1332 ## ---------------- ##
1333 ## Cache variables. ##
1334 ## ---------------- ##
1335 _ASBOX
1336     echo
1337     # The following way of writing the cache mishandles newlines in values,
1338 {
1339   (set) 2>&1 |
1340     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1341     *ac_space=\ *)
1342       sed -n \
1343         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1344           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1345       ;;
1346     *)
1347       sed -n \
1348         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1349       ;;
1350     esac;
1351 }
1352     echo
1353
1354     cat <<\_ASBOX
1355 ## ----------------- ##
1356 ## Output variables. ##
1357 ## ----------------- ##
1358 _ASBOX
1359     echo
1360     for ac_var in $ac_subst_vars
1361     do
1362       eval ac_val=$`echo $ac_var`
1363       echo "$ac_var='"'"'$ac_val'"'"'"
1364     done | sort
1365     echo
1366
1367     if test -n "$ac_subst_files"; then
1368       cat <<\_ASBOX
1369 ## ------------- ##
1370 ## Output files. ##
1371 ## ------------- ##
1372 _ASBOX
1373       echo
1374       for ac_var in $ac_subst_files
1375       do
1376         eval ac_val=$`echo $ac_var`
1377         echo "$ac_var='"'"'$ac_val'"'"'"
1378       done | sort
1379       echo
1380     fi
1381
1382     if test -s confdefs.h; then
1383       cat <<\_ASBOX
1384 ## ----------- ##
1385 ## confdefs.h. ##
1386 ## ----------- ##
1387 _ASBOX
1388       echo
1389       sed "/^$/d" confdefs.h | sort
1390       echo
1391     fi
1392     test "$ac_signal" != 0 &&
1393       echo "$as_me: caught signal $ac_signal"
1394     echo "$as_me: exit $exit_status"
1395   } >&5
1396   rm -f core *.core &&
1397   rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1398     exit $exit_status
1399      ' 0
1400 for ac_signal in 1 2 13 15; do
1401   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1402 done
1403 ac_signal=0
1404
1405 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1406 rm -rf conftest* confdefs.h
1407 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1408 echo >confdefs.h
1409
1410 # Predefined preprocessor variables.
1411
1412 cat >>confdefs.h <<_ACEOF
1413 #define PACKAGE_NAME "$PACKAGE_NAME"
1414 _ACEOF
1415
1416
1417 cat >>confdefs.h <<_ACEOF
1418 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1419 _ACEOF
1420
1421
1422 cat >>confdefs.h <<_ACEOF
1423 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1424 _ACEOF
1425
1426
1427 cat >>confdefs.h <<_ACEOF
1428 #define PACKAGE_STRING "$PACKAGE_STRING"
1429 _ACEOF
1430
1431
1432 cat >>confdefs.h <<_ACEOF
1433 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1434 _ACEOF
1435
1436
1437 # Let the site file select an alternate cache file if it wants to.
1438 # Prefer explicitly selected file to automatically selected ones.
1439 if test -z "$CONFIG_SITE"; then
1440   if test "x$prefix" != xNONE; then
1441     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1442   else
1443     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1444   fi
1445 fi
1446 for ac_site_file in $CONFIG_SITE; do
1447   if test -r "$ac_site_file"; then
1448     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1449 echo "$as_me: loading site script $ac_site_file" >&6;}
1450     sed 's/^/| /' "$ac_site_file" >&5
1451     . "$ac_site_file"
1452   fi
1453 done
1454
1455
1456 # Check that the precious variables saved in the cache have kept the same
1457 # value.
1458 ac_cache_corrupted=false
1459 for ac_var in `(set) 2>&1 |
1460                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1461   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1462   eval ac_new_set=\$ac_env_${ac_var}_set
1463   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1464   eval ac_new_val="\$ac_env_${ac_var}_value"
1465   case $ac_old_set,$ac_new_set in
1466     set,)
1467       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1468 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1469       ac_cache_corrupted=: ;;
1470     ,set)
1471       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1472 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1473       ac_cache_corrupted=: ;;
1474     ,);;
1475     *)
1476       if test "x$ac_old_val" != "x$ac_new_val"; then
1477         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1478 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1479         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1480 echo "$as_me:   former value:  $ac_old_val" >&2;}
1481         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1482 echo "$as_me:   current value: $ac_new_val" >&2;}
1483         ac_cache_corrupted=:
1484       fi;;
1485   esac
1486   # Pass precious variables to config.status.
1487   if test "$ac_new_set" = set; then
1488     case $ac_new_val in
1489     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1490       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1491     *) ac_arg=$ac_var=$ac_new_val ;;
1492     esac
1493     case " $ac_configure_args " in
1494       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1495       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1496     esac
1497   fi
1498 done
1499 if $ac_cache_corrupted; then
1500   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1501 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1502   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1503 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1504    { (exit 1); exit 1; }; }
1505 fi
1506
1507 ac_ext=c
1508 ac_cpp='$CPP $CPPFLAGS'
1509 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1510 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1511 ac_compiler_gnu=$ac_cv_c_compiler_gnu
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
1555 ac_aux_dir=
1556 for ac_dir in build $srcdir/build; do
1557   if test -f $ac_dir/install-sh; then
1558     ac_aux_dir=$ac_dir
1559     ac_install_sh="$ac_aux_dir/install-sh -c"
1560     break
1561   elif test -f $ac_dir/install.sh; then
1562     ac_aux_dir=$ac_dir
1563     ac_install_sh="$ac_aux_dir/install.sh -c"
1564     break
1565   elif test -f $ac_dir/shtool; then
1566     ac_aux_dir=$ac_dir
1567     ac_install_sh="$ac_aux_dir/shtool install -c"
1568     break
1569   fi
1570 done
1571 if test -z "$ac_aux_dir"; then
1572   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in build $srcdir/build" >&5
1573 echo "$as_me: error: cannot find install-sh or install.sh in build $srcdir/build" >&2;}
1574    { (exit 1); exit 1; }; }
1575 fi
1576 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1577 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1578 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1579
1580 eval `$ac_aux_dir/version.sh`
1581 if test -z "$OL_STRING"; then
1582         { { echo "$as_me:$LINENO: error: could not determine version" >&5
1583 echo "$as_me: error: could not determine version" >&2;}
1584    { (exit 1); exit 1; }; }
1585 fi
1586
1587 if test -f "$ac_aux_dir/shtool" && test ! -d $ac_aux_dir/shtool; then
1588         ac_cv_shtool="$ac_aux_dir/shtool"
1589 else
1590         { { echo "$as_me:$LINENO: error: no shtool found in $ac_aux_dir" >&5
1591 echo "$as_me: error: no shtool found in $ac_aux_dir" >&2;}
1592    { (exit 1); exit 1; }; }
1593 fi
1594
1595 SHTOOL="$ac_cv_shtool"
1596
1597 TB="" TN=""
1598 if test -t 1; then
1599         TB="`$SHTOOL echo -e '%B' 2>/dev/null`"
1600         TN="`$SHTOOL echo -e '%b' 2>/dev/null`"
1601 fi
1602
1603 OPENLDAP_CVS=""
1604 if test -d $ac_aux_dir/CVS; then
1605         OPENLDAP_CVS="(from CVS sources) "
1606 fi
1607
1608 echo "Configuring ${TB}${OL_STRING}${TN} ${OPENLDAP_CVS}..."
1609
1610 # Make sure we can run config.sub.
1611 $ac_config_sub sun4 >/dev/null 2>&1 ||
1612   { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
1613 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1614    { (exit 1); exit 1; }; }
1615
1616 echo "$as_me:$LINENO: checking build system type" >&5
1617 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1618 if test "${ac_cv_build+set}" = set; then
1619   echo $ECHO_N "(cached) $ECHO_C" >&6
1620 else
1621   ac_cv_build_alias=$build_alias
1622 test -z "$ac_cv_build_alias" &&
1623   ac_cv_build_alias=`$ac_config_guess`
1624 test -z "$ac_cv_build_alias" &&
1625   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1626 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1627    { (exit 1); exit 1; }; }
1628 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1629   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1630 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
1631    { (exit 1); exit 1; }; }
1632
1633 fi
1634 echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1635 echo "${ECHO_T}$ac_cv_build" >&6
1636 build=$ac_cv_build
1637 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1638 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1639 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1640
1641
1642 echo "$as_me:$LINENO: checking host system type" >&5
1643 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1644 if test "${ac_cv_host+set}" = set; then
1645   echo $ECHO_N "(cached) $ECHO_C" >&6
1646 else
1647   ac_cv_host_alias=$host_alias
1648 test -z "$ac_cv_host_alias" &&
1649   ac_cv_host_alias=$ac_cv_build_alias
1650 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1651   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1652 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1653    { (exit 1); exit 1; }; }
1654
1655 fi
1656 echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1657 echo "${ECHO_T}$ac_cv_host" >&6
1658 host=$ac_cv_host
1659 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1660 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1661 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1662
1663
1664 echo "$as_me:$LINENO: checking target system type" >&5
1665 echo $ECHO_N "checking target system type... $ECHO_C" >&6
1666 if test "${ac_cv_target+set}" = set; then
1667   echo $ECHO_N "(cached) $ECHO_C" >&6
1668 else
1669   ac_cv_target_alias=$target_alias
1670 test "x$ac_cv_target_alias" = "x" &&
1671   ac_cv_target_alias=$ac_cv_host_alias
1672 ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
1673   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1674 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
1675    { (exit 1); exit 1; }; }
1676
1677 fi
1678 echo "$as_me:$LINENO: result: $ac_cv_target" >&5
1679 echo "${ECHO_T}$ac_cv_target" >&6
1680 target=$ac_cv_target
1681 target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1682 target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1683 target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1684
1685
1686 # The aliases save the names the user supplied, while $host etc.
1687 # will get canonicalized.
1688 test -n "$target_alias" &&
1689   test "$program_prefix$program_suffix$program_transform_name" = \
1690     NONENONEs,x,x, &&
1691   program_prefix=${target_alias}-
1692
1693 am__api_version="1.9"
1694 # Find a good install program.  We prefer a C program (faster),
1695 # so one script is as good as another.  But avoid the broken or
1696 # incompatible versions:
1697 # SysV /etc/install, /usr/sbin/install
1698 # SunOS /usr/etc/install
1699 # IRIX /sbin/install
1700 # AIX /bin/install
1701 # AmigaOS /C/install, which installs bootblocks on floppy discs
1702 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1703 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
1704 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1705 # OS/2's system install, which has a completely different semantic
1706 # ./install, which can be erroneously created by make from ./install.sh.
1707 echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
1708 echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
1709 if test -z "$INSTALL"; then
1710 if test "${ac_cv_path_install+set}" = set; then
1711   echo $ECHO_N "(cached) $ECHO_C" >&6
1712 else
1713   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1714 for as_dir in $PATH
1715 do
1716   IFS=$as_save_IFS
1717   test -z "$as_dir" && as_dir=.
1718   # Account for people who put trailing slashes in PATH elements.
1719 case $as_dir/ in
1720   ./ | .// | /cC/* | \
1721   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
1722   ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
1723   /usr/ucb/* ) ;;
1724   *)
1725     # OSF1 and SCO ODT 3.0 have their own names for install.
1726     # Don't use installbsd from OSF since it installs stuff as root
1727     # by default.
1728     for ac_prog in ginstall scoinst install; do
1729       for ac_exec_ext in '' $ac_executable_extensions; do
1730         if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
1731           if test $ac_prog = install &&
1732             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
1733             # AIX install.  It has an incompatible calling convention.
1734             :
1735           elif test $ac_prog = install &&
1736             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
1737             # program-specific install script used by HP pwplus--don't use.
1738             :
1739           else
1740             ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
1741             break 3
1742           fi
1743         fi
1744       done
1745     done
1746     ;;
1747 esac
1748 done
1749
1750
1751 fi
1752   if test "${ac_cv_path_install+set}" = set; then
1753     INSTALL=$ac_cv_path_install
1754   else
1755     # As a last resort, use the slow shell script.  We don't cache a
1756     # path for INSTALL within a source directory, because that will
1757     # break other packages using the cache if that directory is
1758     # removed, or if the path is relative.
1759     INSTALL=$ac_install_sh
1760   fi
1761 fi
1762 echo "$as_me:$LINENO: result: $INSTALL" >&5
1763 echo "${ECHO_T}$INSTALL" >&6
1764
1765 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1766 # It thinks the first close brace ends the variable substitution.
1767 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1768
1769 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
1770
1771 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1772
1773 echo "$as_me:$LINENO: checking whether build environment is sane" >&5
1774 echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6
1775 # Just in case
1776 sleep 1
1777 echo timestamp > conftest.file
1778 # Do `set' in a subshell so we don't clobber the current shell's
1779 # arguments.  Must try -L first in case configure is actually a
1780 # symlink; some systems play weird games with the mod time of symlinks
1781 # (eg FreeBSD returns the mod time of the symlink's containing
1782 # directory).
1783 if (
1784    set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
1785    if test "$*" = "X"; then
1786       # -L didn't work.
1787       set X `ls -t $srcdir/configure conftest.file`
1788    fi
1789    rm -f conftest.file
1790    if test "$*" != "X $srcdir/configure conftest.file" \
1791       && test "$*" != "X conftest.file $srcdir/configure"; then
1792
1793       # If neither matched, then we have a broken ls.  This can happen
1794       # if, for instance, CONFIG_SHELL is bash and it inherits a
1795       # broken ls alias from the environment.  This has actually
1796       # happened.  Such a system could not be considered "sane".
1797       { { echo "$as_me:$LINENO: error: ls -t appears to fail.  Make sure there is not a broken
1798 alias in your environment" >&5
1799 echo "$as_me: error: ls -t appears to fail.  Make sure there is not a broken
1800 alias in your environment" >&2;}
1801    { (exit 1); exit 1; }; }
1802    fi
1803
1804    test "$2" = conftest.file
1805    )
1806 then
1807    # Ok.
1808    :
1809 else
1810    { { echo "$as_me:$LINENO: error: newly created file is older than distributed files!
1811 Check your system clock" >&5
1812 echo "$as_me: error: newly created file is older than distributed files!
1813 Check your system clock" >&2;}
1814    { (exit 1); exit 1; }; }
1815 fi
1816 echo "$as_me:$LINENO: result: yes" >&5
1817 echo "${ECHO_T}yes" >&6
1818 test "$program_prefix" != NONE &&
1819   program_transform_name="s,^,$program_prefix,;$program_transform_name"
1820 # Use a double $ so make ignores it.
1821 test "$program_suffix" != NONE &&
1822   program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1823 # Double any \ or $.  echo might interpret backslashes.
1824 # By default was `s,x,x', remove it if useless.
1825 cat <<\_ACEOF >conftest.sed
1826 s/[\\$]/&&/g;s/;s,x,x,$//
1827 _ACEOF
1828 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1829 rm conftest.sed
1830
1831 # expand $ac_aux_dir to an absolute path
1832 am_aux_dir=`cd $ac_aux_dir && pwd`
1833
1834 test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
1835 # Use eval to expand $SHELL
1836 if eval "$MISSING --run true"; then
1837   am_missing_run="$MISSING --run "
1838 else
1839   am_missing_run=
1840   { echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5
1841 echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
1842 fi
1843
1844 if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then
1845   # We used to keeping the `.' as first argument, in order to
1846   # allow $(mkdir_p) to be used without argument.  As in
1847   #   $(mkdir_p) $(somedir)
1848   # where $(somedir) is conditionally defined.  However this is wrong
1849   # for two reasons:
1850   #  1. if the package is installed by a user who cannot write `.'
1851   #     make install will fail,
1852   #  2. the above comment should most certainly read
1853   #     $(mkdir_p) $(DESTDIR)$(somedir)
1854   #     so it does not work when $(somedir) is undefined and
1855   #     $(DESTDIR) is not.
1856   #  To support the latter case, we have to write
1857   #     test -z "$(somedir)" || $(mkdir_p) $(DESTDIR)$(somedir),
1858   #  so the `.' trick is pointless.
1859   mkdir_p='mkdir -p --'
1860 else
1861   # On NextStep and OpenStep, the `mkdir' command does not
1862   # recognize any option.  It will interpret all options as
1863   # directories to create, and then abort because `.' already
1864   # exists.
1865   for d in ./-p ./--version;
1866   do
1867     test -d $d && rmdir $d
1868   done
1869   # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists.
1870   if test -f "$ac_aux_dir/mkinstalldirs"; then
1871     mkdir_p='$(mkinstalldirs)'
1872   else
1873     mkdir_p='$(install_sh) -d'
1874   fi
1875 fi
1876
1877 for ac_prog in gawk mawk nawk awk
1878 do
1879   # Extract the first word of "$ac_prog", so it can be a program name with args.
1880 set dummy $ac_prog; ac_word=$2
1881 echo "$as_me:$LINENO: checking for $ac_word" >&5
1882 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1883 if test "${ac_cv_prog_AWK+set}" = set; then
1884   echo $ECHO_N "(cached) $ECHO_C" >&6
1885 else
1886   if test -n "$AWK"; then
1887   ac_cv_prog_AWK="$AWK" # Let the user override the test.
1888 else
1889 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1890 for as_dir in $PATH
1891 do
1892   IFS=$as_save_IFS
1893   test -z "$as_dir" && as_dir=.
1894   for ac_exec_ext in '' $ac_executable_extensions; do
1895   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1896     ac_cv_prog_AWK="$ac_prog"
1897     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1898     break 2
1899   fi
1900 done
1901 done
1902
1903 fi
1904 fi
1905 AWK=$ac_cv_prog_AWK
1906 if test -n "$AWK"; then
1907   echo "$as_me:$LINENO: result: $AWK" >&5
1908 echo "${ECHO_T}$AWK" >&6
1909 else
1910   echo "$as_me:$LINENO: result: no" >&5
1911 echo "${ECHO_T}no" >&6
1912 fi
1913
1914   test -n "$AWK" && break
1915 done
1916
1917 echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
1918 echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
1919 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'`
1920 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1921   echo $ECHO_N "(cached) $ECHO_C" >&6
1922 else
1923   cat >conftest.make <<\_ACEOF
1924 all:
1925         @echo 'ac_maketemp="$(MAKE)"'
1926 _ACEOF
1927 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1928 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1929 if test -n "$ac_maketemp"; then
1930   eval ac_cv_prog_make_${ac_make}_set=yes
1931 else
1932   eval ac_cv_prog_make_${ac_make}_set=no
1933 fi
1934 rm -f conftest.make
1935 fi
1936 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1937   echo "$as_me:$LINENO: result: yes" >&5
1938 echo "${ECHO_T}yes" >&6
1939   SET_MAKE=
1940 else
1941   echo "$as_me:$LINENO: result: no" >&5
1942 echo "${ECHO_T}no" >&6
1943   SET_MAKE="MAKE=${MAKE-make}"
1944 fi
1945
1946 rm -rf .tst 2>/dev/null
1947 mkdir .tst 2>/dev/null
1948 if test -d .tst; then
1949   am__leading_dot=.
1950 else
1951   am__leading_dot=_
1952 fi
1953 rmdir .tst 2>/dev/null
1954
1955 # test to see if srcdir already configured
1956 if test "`cd $srcdir && pwd`" != "`pwd`" &&
1957    test -f $srcdir/config.status; then
1958   { { echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5
1959 echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;}
1960    { (exit 1); exit 1; }; }
1961 fi
1962
1963 # test whether we have cygpath
1964 if test -z "$CYGPATH_W"; then
1965   if (cygpath --version) >/dev/null 2>/dev/null; then
1966     CYGPATH_W='cygpath -w'
1967   else
1968     CYGPATH_W=echo
1969   fi
1970 fi
1971
1972
1973 # Define the identity of the package.
1974  PACKAGE=$OL_PACKAGE
1975  VERSION=$OL_VERSION
1976
1977
1978 # Some tools Automake needs.
1979
1980 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
1981
1982
1983 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
1984
1985
1986 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
1987
1988
1989 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
1990
1991
1992 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
1993
1994 install_sh=${install_sh-"$am_aux_dir/install-sh"}
1995
1996 # Installed binaries are usually stripped using `strip' when the user
1997 # run `make install-strip'.  However `strip' might not be the right
1998 # tool to use in cross-compilation environments, therefore Automake
1999 # will honor the `STRIP' environment variable to overrule this program.
2000 if test "$cross_compiling" != no; then
2001   if test -n "$ac_tool_prefix"; then
2002   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
2003 set dummy ${ac_tool_prefix}strip; ac_word=$2
2004 echo "$as_me:$LINENO: checking for $ac_word" >&5
2005 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2006 if test "${ac_cv_prog_STRIP+set}" = set; then
2007   echo $ECHO_N "(cached) $ECHO_C" >&6
2008 else
2009   if test -n "$STRIP"; then
2010   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
2011 else
2012 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2013 for as_dir in $PATH
2014 do
2015   IFS=$as_save_IFS
2016   test -z "$as_dir" && as_dir=.
2017   for ac_exec_ext in '' $ac_executable_extensions; do
2018   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2019     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
2020     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2021     break 2
2022   fi
2023 done
2024 done
2025
2026 fi
2027 fi
2028 STRIP=$ac_cv_prog_STRIP
2029 if test -n "$STRIP"; then
2030   echo "$as_me:$LINENO: result: $STRIP" >&5
2031 echo "${ECHO_T}$STRIP" >&6
2032 else
2033   echo "$as_me:$LINENO: result: no" >&5
2034 echo "${ECHO_T}no" >&6
2035 fi
2036
2037 fi
2038 if test -z "$ac_cv_prog_STRIP"; then
2039   ac_ct_STRIP=$STRIP
2040   # Extract the first word of "strip", so it can be a program name with args.
2041 set dummy strip; ac_word=$2
2042 echo "$as_me:$LINENO: checking for $ac_word" >&5
2043 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2044 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
2045   echo $ECHO_N "(cached) $ECHO_C" >&6
2046 else
2047   if test -n "$ac_ct_STRIP"; then
2048   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
2049 else
2050 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2051 for as_dir in $PATH
2052 do
2053   IFS=$as_save_IFS
2054   test -z "$as_dir" && as_dir=.
2055   for ac_exec_ext in '' $ac_executable_extensions; do
2056   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2057     ac_cv_prog_ac_ct_STRIP="strip"
2058     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2059     break 2
2060   fi
2061 done
2062 done
2063
2064   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
2065 fi
2066 fi
2067 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
2068 if test -n "$ac_ct_STRIP"; then
2069   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
2070 echo "${ECHO_T}$ac_ct_STRIP" >&6
2071 else
2072   echo "$as_me:$LINENO: result: no" >&5
2073 echo "${ECHO_T}no" >&6
2074 fi
2075
2076   STRIP=$ac_ct_STRIP
2077 else
2078   STRIP="$ac_cv_prog_STRIP"
2079 fi
2080
2081 fi
2082 INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
2083
2084 # We need awk for the "check" target.  The system "awk" is bad on
2085 # some platforms.
2086 # Always define AMTAR for backward compatibility.
2087
2088 AMTAR=${AMTAR-"${am_missing_run}tar"}
2089
2090 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
2091
2092
2093
2094
2095
2096 cat >>confdefs.h <<_ACEOF
2097 #define OPENLDAP_PACKAGE "$PACKAGE"
2098 _ACEOF
2099
2100
2101 cat >>confdefs.h <<_ACEOF
2102 #define OPENLDAP_VERSION "$VERSION"
2103 _ACEOF
2104
2105
2106
2107 cat >>confdefs.h <<_ACEOF
2108 #define LDAP_VENDOR_VERSION $OL_API_INC
2109 _ACEOF
2110
2111
2112 cat >>confdefs.h <<_ACEOF
2113 #define LDAP_VENDOR_VERSION_MAJOR $OL_MAJOR
2114 _ACEOF
2115
2116
2117 cat >>confdefs.h <<_ACEOF
2118 #define LDAP_VENDOR_VERSION_MINOR $OL_MINOR
2119 _ACEOF
2120
2121
2122 cat >>confdefs.h <<_ACEOF
2123 #define LDAP_VENDOR_VERSION_PATCH $OL_PATCH
2124 _ACEOF
2125
2126
2127 OPENLDAP_LIBRELEASE=$OL_API_LIB_RELEASE
2128
2129 OPENLDAP_LIBVERSION=$OL_API_LIB_VERSION
2130
2131 OPENLDAP_RELEASE_DATE="$OL_RELEASE_DATE"
2132
2133
2134
2135
2136
2137
2138
2139           ac_config_headers="$ac_config_headers include/portable.h:include/portable.hin"
2140
2141           ac_config_headers="$ac_config_headers include/ldap_features.h:include/ldap_features.hin"
2142
2143           ac_config_headers="$ac_config_headers include/lber_types.h:include/lber_types.hin"
2144
2145
2146 echo "$as_me:$LINENO: checking configure arguments" >&5
2147 echo $ECHO_N "checking configure arguments... $ECHO_C" >&6
2148
2149
2150 top_builddir=`pwd`
2151
2152 ldap_subdir="/openldap"
2153
2154
2155 # Check whether --with-subdir or --without-subdir was given.
2156 if test "${with_subdir+set}" = set; then
2157   withval="$with_subdir"
2158   case "$withval" in
2159         no) ldap_subdir=""
2160                 ;;
2161         yes)
2162                 ;;
2163         /*|\\*)
2164                 ldap_subdir="$withval"
2165                 ;;
2166         *)
2167                 ldap_subdir="/$withval"
2168                 ;;
2169 esac
2170
2171 fi;
2172
2173 # OpenLDAP --enable-debug
2174
2175         # Check whether --enable-debug or --disable-debug was given.
2176 if test "${enable_debug+set}" = set; then
2177   enableval="$enable_debug"
2178
2179         ol_arg=invalid
2180         for ol_val in no yes traditional ; do
2181                 if test "$enableval" = "$ol_val" ; then
2182                         ol_arg="$ol_val"
2183                 fi
2184         done
2185         if test "$ol_arg" = "invalid" ; then
2186                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-debug" >&5
2187 echo "$as_me: error: bad value $enableval for --enable-debug" >&2;}
2188    { (exit 1); exit 1; }; }
2189         fi
2190         ol_enable_debug="$ol_arg"
2191
2192 else
2193         ol_enable_debug=yes
2194 fi;
2195 # end --enable-debug
2196 # OpenLDAP --enable-dynamic
2197
2198         # Check whether --enable-dynamic or --disable-dynamic was given.
2199 if test "${enable_dynamic+set}" = set; then
2200   enableval="$enable_dynamic"
2201
2202         ol_arg=invalid
2203         for ol_val in auto yes no ; do
2204                 if test "$enableval" = "$ol_val" ; then
2205                         ol_arg="$ol_val"
2206                 fi
2207         done
2208         if test "$ol_arg" = "invalid" ; then
2209                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dynamic" >&5
2210 echo "$as_me: error: bad value $enableval for --enable-dynamic" >&2;}
2211    { (exit 1); exit 1; }; }
2212         fi
2213         ol_enable_dynamic="$ol_arg"
2214
2215 else
2216         ol_enable_dynamic=no
2217 fi;
2218 # end --enable-dynamic
2219 # OpenLDAP --enable-syslog
2220
2221         # Check whether --enable-syslog or --disable-syslog was given.
2222 if test "${enable_syslog+set}" = set; then
2223   enableval="$enable_syslog"
2224
2225         ol_arg=invalid
2226         for ol_val in auto yes no ; do
2227                 if test "$enableval" = "$ol_val" ; then
2228                         ol_arg="$ol_val"
2229                 fi
2230         done
2231         if test "$ol_arg" = "invalid" ; then
2232                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-syslog" >&5
2233 echo "$as_me: error: bad value $enableval for --enable-syslog" >&2;}
2234    { (exit 1); exit 1; }; }
2235         fi
2236         ol_enable_syslog="$ol_arg"
2237
2238 else
2239         ol_enable_syslog=auto
2240 fi;
2241 # end --enable-syslog
2242 # OpenLDAP --enable-proctitle
2243
2244         # Check whether --enable-proctitle or --disable-proctitle was given.
2245 if test "${enable_proctitle+set}" = set; then
2246   enableval="$enable_proctitle"
2247
2248         ol_arg=invalid
2249         for ol_val in auto yes no ; do
2250                 if test "$enableval" = "$ol_val" ; then
2251                         ol_arg="$ol_val"
2252                 fi
2253         done
2254         if test "$ol_arg" = "invalid" ; then
2255                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-proctitle" >&5
2256 echo "$as_me: error: bad value $enableval for --enable-proctitle" >&2;}
2257    { (exit 1); exit 1; }; }
2258         fi
2259         ol_enable_proctitle="$ol_arg"
2260
2261 else
2262         ol_enable_proctitle=yes
2263 fi;
2264 # end --enable-proctitle
2265 ol_enable_referrals=${ol_enable_referrals-no}
2266 # OpenLDAP --enable-ipv6
2267
2268         # Check whether --enable-ipv6 or --disable-ipv6 was given.
2269 if test "${enable_ipv6+set}" = set; then
2270   enableval="$enable_ipv6"
2271
2272         ol_arg=invalid
2273         for ol_val in auto yes no ; do
2274                 if test "$enableval" = "$ol_val" ; then
2275                         ol_arg="$ol_val"
2276                 fi
2277         done
2278         if test "$ol_arg" = "invalid" ; then
2279                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ipv6" >&5
2280 echo "$as_me: error: bad value $enableval for --enable-ipv6" >&2;}
2281    { (exit 1); exit 1; }; }
2282         fi
2283         ol_enable_ipv6="$ol_arg"
2284
2285 else
2286         ol_enable_ipv6=auto
2287 fi;
2288 # end --enable-ipv6
2289 # OpenLDAP --enable-local
2290
2291         # Check whether --enable-local or --disable-local was given.
2292 if test "${enable_local+set}" = set; then
2293   enableval="$enable_local"
2294
2295         ol_arg=invalid
2296         for ol_val in auto yes no ; do
2297                 if test "$enableval" = "$ol_val" ; then
2298                         ol_arg="$ol_val"
2299                 fi
2300         done
2301         if test "$ol_arg" = "invalid" ; then
2302                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-local" >&5
2303 echo "$as_me: error: bad value $enableval for --enable-local" >&2;}
2304    { (exit 1); exit 1; }; }
2305         fi
2306         ol_enable_local="$ol_arg"
2307
2308 else
2309         ol_enable_local=auto
2310 fi;
2311 # end --enable-local
2312
2313 # OpenLDAP --with-cyrus_sasl
2314
2315 # Check whether --with-cyrus_sasl or --without-cyrus_sasl was given.
2316 if test "${with_cyrus_sasl+set}" = set; then
2317   withval="$with_cyrus_sasl"
2318
2319         ol_arg=invalid
2320         for ol_val in auto yes no  ; do
2321                 if test "$withval" = "$ol_val" ; then
2322                         ol_arg="$ol_val"
2323                 fi
2324         done
2325         if test "$ol_arg" = "invalid" ; then
2326                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-cyrus_sasl" >&5
2327 echo "$as_me: error: bad value $withval for --with-cyrus_sasl" >&2;}
2328    { (exit 1); exit 1; }; }
2329         fi
2330         ol_with_cyrus_sasl="$ol_arg"
2331
2332 else
2333         ol_with_cyrus_sasl="auto"
2334 fi; # end --with-cyrus_sasl
2335
2336 # OpenLDAP --with-fetch
2337
2338 # Check whether --with-fetch or --without-fetch was given.
2339 if test "${with_fetch+set}" = set; then
2340   withval="$with_fetch"
2341
2342         ol_arg=invalid
2343         for ol_val in auto yes no  ; do
2344                 if test "$withval" = "$ol_val" ; then
2345                         ol_arg="$ol_val"
2346                 fi
2347         done
2348         if test "$ol_arg" = "invalid" ; then
2349                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-fetch" >&5
2350 echo "$as_me: error: bad value $withval for --with-fetch" >&2;}
2351    { (exit 1); exit 1; }; }
2352         fi
2353         ol_with_fetch="$ol_arg"
2354
2355 else
2356         ol_with_fetch="auto"
2357 fi; # end --with-fetch
2358
2359 # OpenLDAP --with-threads
2360
2361 # Check whether --with-threads or --without-threads was given.
2362 if test "${with_threads+set}" = set; then
2363   withval="$with_threads"
2364
2365         ol_arg=invalid
2366         for ol_val in auto nt posix mach pth lwp yes no manual  ; do
2367                 if test "$withval" = "$ol_val" ; then
2368                         ol_arg="$ol_val"
2369                 fi
2370         done
2371         if test "$ol_arg" = "invalid" ; then
2372                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-threads" >&5
2373 echo "$as_me: error: bad value $withval for --with-threads" >&2;}
2374    { (exit 1); exit 1; }; }
2375         fi
2376         ol_with_threads="$ol_arg"
2377
2378 else
2379         ol_with_threads="auto"
2380 fi; # end --with-threads
2381
2382 # OpenLDAP --with-tls
2383
2384 # Check whether --with-tls or --without-tls was given.
2385 if test "${with_tls+set}" = set; then
2386   withval="$with_tls"
2387
2388         ol_arg=invalid
2389         for ol_val in auto openssl gnutls yes no  ; do
2390                 if test "$withval" = "$ol_val" ; then
2391                         ol_arg="$ol_val"
2392                 fi
2393         done
2394         if test "$ol_arg" = "invalid" ; then
2395                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-tls" >&5
2396 echo "$as_me: error: bad value $withval for --with-tls" >&2;}
2397    { (exit 1); exit 1; }; }
2398         fi
2399         ol_with_tls="$ol_arg"
2400
2401 else
2402         ol_with_tls="auto"
2403 fi; # end --with-tls
2404
2405 # OpenLDAP --with-yielding_select
2406
2407 # Check whether --with-yielding_select or --without-yielding_select was given.
2408 if test "${with_yielding_select+set}" = set; then
2409   withval="$with_yielding_select"
2410
2411         ol_arg=invalid
2412         for ol_val in auto yes no manual  ; do
2413                 if test "$withval" = "$ol_val" ; then
2414                         ol_arg="$ol_val"
2415                 fi
2416         done
2417         if test "$ol_arg" = "invalid" ; then
2418                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-yielding_select" >&5
2419 echo "$as_me: error: bad value $withval for --with-yielding_select" >&2;}
2420    { (exit 1); exit 1; }; }
2421         fi
2422         ol_with_yielding_select="$ol_arg"
2423
2424 else
2425         ol_with_yielding_select="auto"
2426 fi; # end --with-yielding_select
2427
2428 # OpenLDAP --with-mp
2429
2430 # Check whether --with-mp or --without-mp was given.
2431 if test "${with_mp+set}" = set; then
2432   withval="$with_mp"
2433
2434         ol_arg=invalid
2435         for ol_val in auto longlong long bignum gmp yes no ; do
2436                 if test "$withval" = "$ol_val" ; then
2437                         ol_arg="$ol_val"
2438                 fi
2439         done
2440         if test "$ol_arg" = "invalid" ; then
2441                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-mp" >&5
2442 echo "$as_me: error: bad value $withval for --with-mp" >&2;}
2443    { (exit 1); exit 1; }; }
2444         fi
2445         ol_with_mp="$ol_arg"
2446
2447 else
2448         ol_with_mp="auto"
2449 fi; # end --with-mp
2450
2451 # OpenLDAP --with-odbc
2452
2453 # Check whether --with-odbc or --without-odbc was given.
2454 if test "${with_odbc+set}" = set; then
2455   withval="$with_odbc"
2456
2457         ol_arg=invalid
2458         for ol_val in auto iodbc unixodbc  ; do
2459                 if test "$withval" = "$ol_val" ; then
2460                         ol_arg="$ol_val"
2461                 fi
2462         done
2463         if test "$ol_arg" = "invalid" ; then
2464                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-odbc" >&5
2465 echo "$as_me: error: bad value $withval for --with-odbc" >&2;}
2466    { (exit 1); exit 1; }; }
2467         fi
2468         ol_with_odbc="$ol_arg"
2469
2470 else
2471         ol_with_odbc="auto"
2472 fi; # end --with-odbc
2473
2474
2475
2476 # Check whether --enable-xxslapdoptions or --disable-xxslapdoptions was given.
2477 if test "${enable_xxslapdoptions+set}" = set; then
2478   enableval="$enable_xxslapdoptions"
2479
2480 fi;
2481 # OpenLDAP --enable-slapd
2482
2483         # Check whether --enable-slapd or --disable-slapd was given.
2484 if test "${enable_slapd+set}" = set; then
2485   enableval="$enable_slapd"
2486
2487         ol_arg=invalid
2488         for ol_val in auto yes no ; do
2489                 if test "$enableval" = "$ol_val" ; then
2490                         ol_arg="$ol_val"
2491                 fi
2492         done
2493         if test "$ol_arg" = "invalid" ; then
2494                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slapd" >&5
2495 echo "$as_me: error: bad value $enableval for --enable-slapd" >&2;}
2496    { (exit 1); exit 1; }; }
2497         fi
2498         ol_enable_slapd="$ol_arg"
2499
2500 else
2501         ol_enable_slapd=yes
2502 fi;
2503 # end --enable-slapd
2504 # OpenLDAP --enable-dynacl
2505
2506         # Check whether --enable-dynacl or --disable-dynacl was given.
2507 if test "${enable_dynacl+set}" = set; then
2508   enableval="$enable_dynacl"
2509
2510         ol_arg=invalid
2511         for ol_val in auto yes no ; do
2512                 if test "$enableval" = "$ol_val" ; then
2513                         ol_arg="$ol_val"
2514                 fi
2515         done
2516         if test "$ol_arg" = "invalid" ; then
2517                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dynacl" >&5
2518 echo "$as_me: error: bad value $enableval for --enable-dynacl" >&2;}
2519    { (exit 1); exit 1; }; }
2520         fi
2521         ol_enable_dynacl="$ol_arg"
2522
2523 else
2524         ol_enable_dynacl=no
2525 fi;
2526 # end --enable-dynacl
2527 # OpenLDAP --enable-aci
2528
2529         # Check whether --enable-aci or --disable-aci was given.
2530 if test "${enable_aci+set}" = set; then
2531   enableval="$enable_aci"
2532
2533         ol_arg=invalid
2534         for ol_val in no yes mod ; do
2535                 if test "$enableval" = "$ol_val" ; then
2536                         ol_arg="$ol_val"
2537                 fi
2538         done
2539         if test "$ol_arg" = "invalid" ; then
2540                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-aci" >&5
2541 echo "$as_me: error: bad value $enableval for --enable-aci" >&2;}
2542    { (exit 1); exit 1; }; }
2543         fi
2544         ol_enable_aci="$ol_arg"
2545
2546 else
2547         ol_enable_aci=no
2548 fi;
2549 # end --enable-aci
2550 # OpenLDAP --enable-cleartext
2551
2552         # Check whether --enable-cleartext or --disable-cleartext was given.
2553 if test "${enable_cleartext+set}" = set; then
2554   enableval="$enable_cleartext"
2555
2556         ol_arg=invalid
2557         for ol_val in auto yes no ; do
2558                 if test "$enableval" = "$ol_val" ; then
2559                         ol_arg="$ol_val"
2560                 fi
2561         done
2562         if test "$ol_arg" = "invalid" ; then
2563                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-cleartext" >&5
2564 echo "$as_me: error: bad value $enableval for --enable-cleartext" >&2;}
2565    { (exit 1); exit 1; }; }
2566         fi
2567         ol_enable_cleartext="$ol_arg"
2568
2569 else
2570         ol_enable_cleartext=yes
2571 fi;
2572 # end --enable-cleartext
2573 # OpenLDAP --enable-crypt
2574
2575         # Check whether --enable-crypt or --disable-crypt was given.
2576 if test "${enable_crypt+set}" = set; then
2577   enableval="$enable_crypt"
2578
2579         ol_arg=invalid
2580         for ol_val in auto yes no ; do
2581                 if test "$enableval" = "$ol_val" ; then
2582                         ol_arg="$ol_val"
2583                 fi
2584         done
2585         if test "$ol_arg" = "invalid" ; then
2586                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-crypt" >&5
2587 echo "$as_me: error: bad value $enableval for --enable-crypt" >&2;}
2588    { (exit 1); exit 1; }; }
2589         fi
2590         ol_enable_crypt="$ol_arg"
2591
2592 else
2593         ol_enable_crypt=no
2594 fi;
2595 # end --enable-crypt
2596 # OpenLDAP --enable-lmpasswd
2597
2598         # Check whether --enable-lmpasswd or --disable-lmpasswd was given.
2599 if test "${enable_lmpasswd+set}" = set; then
2600   enableval="$enable_lmpasswd"
2601
2602         ol_arg=invalid
2603         for ol_val in auto yes no ; do
2604                 if test "$enableval" = "$ol_val" ; then
2605                         ol_arg="$ol_val"
2606                 fi
2607         done
2608         if test "$ol_arg" = "invalid" ; then
2609                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-lmpasswd" >&5
2610 echo "$as_me: error: bad value $enableval for --enable-lmpasswd" >&2;}
2611    { (exit 1); exit 1; }; }
2612         fi
2613         ol_enable_lmpasswd="$ol_arg"
2614
2615 else
2616         ol_enable_lmpasswd=no
2617 fi;
2618 # end --enable-lmpasswd
2619 # OpenLDAP --enable-spasswd
2620
2621         # Check whether --enable-spasswd or --disable-spasswd was given.
2622 if test "${enable_spasswd+set}" = set; then
2623   enableval="$enable_spasswd"
2624
2625         ol_arg=invalid
2626         for ol_val in auto yes no ; do
2627                 if test "$enableval" = "$ol_val" ; then
2628                         ol_arg="$ol_val"
2629                 fi
2630         done
2631         if test "$ol_arg" = "invalid" ; then
2632                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-spasswd" >&5
2633 echo "$as_me: error: bad value $enableval for --enable-spasswd" >&2;}
2634    { (exit 1); exit 1; }; }
2635         fi
2636         ol_enable_spasswd="$ol_arg"
2637
2638 else
2639         ol_enable_spasswd=no
2640 fi;
2641 # end --enable-spasswd
2642 # OpenLDAP --enable-modules
2643
2644         # Check whether --enable-modules or --disable-modules was given.
2645 if test "${enable_modules+set}" = set; then
2646   enableval="$enable_modules"
2647
2648         ol_arg=invalid
2649         for ol_val in auto yes no ; do
2650                 if test "$enableval" = "$ol_val" ; then
2651                         ol_arg="$ol_val"
2652                 fi
2653         done
2654         if test "$ol_arg" = "invalid" ; then
2655                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-modules" >&5
2656 echo "$as_me: error: bad value $enableval for --enable-modules" >&2;}
2657    { (exit 1); exit 1; }; }
2658         fi
2659         ol_enable_modules="$ol_arg"
2660
2661 else
2662         ol_enable_modules=no
2663 fi;
2664 # end --enable-modules
2665 # OpenLDAP --enable-rewrite
2666
2667         # Check whether --enable-rewrite or --disable-rewrite was given.
2668 if test "${enable_rewrite+set}" = set; then
2669   enableval="$enable_rewrite"
2670
2671         ol_arg=invalid
2672         for ol_val in auto yes no ; do
2673                 if test "$enableval" = "$ol_val" ; then
2674                         ol_arg="$ol_val"
2675                 fi
2676         done
2677         if test "$ol_arg" = "invalid" ; then
2678                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rewrite" >&5
2679 echo "$as_me: error: bad value $enableval for --enable-rewrite" >&2;}
2680    { (exit 1); exit 1; }; }
2681         fi
2682         ol_enable_rewrite="$ol_arg"
2683
2684 else
2685         ol_enable_rewrite=auto
2686 fi;
2687 # end --enable-rewrite
2688 # OpenLDAP --enable-rlookups
2689
2690         # Check whether --enable-rlookups or --disable-rlookups was given.
2691 if test "${enable_rlookups+set}" = set; then
2692   enableval="$enable_rlookups"
2693
2694         ol_arg=invalid
2695         for ol_val in auto yes no ; do
2696                 if test "$enableval" = "$ol_val" ; then
2697                         ol_arg="$ol_val"
2698                 fi
2699         done
2700         if test "$ol_arg" = "invalid" ; then
2701                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rlookups" >&5
2702 echo "$as_me: error: bad value $enableval for --enable-rlookups" >&2;}
2703    { (exit 1); exit 1; }; }
2704         fi
2705         ol_enable_rlookups="$ol_arg"
2706
2707 else
2708         ol_enable_rlookups=no
2709 fi;
2710 # end --enable-rlookups
2711 # OpenLDAP --enable-slapi
2712
2713         # Check whether --enable-slapi or --disable-slapi was given.
2714 if test "${enable_slapi+set}" = set; then
2715   enableval="$enable_slapi"
2716
2717         ol_arg=invalid
2718         for ol_val in auto yes no ; do
2719                 if test "$enableval" = "$ol_val" ; then
2720                         ol_arg="$ol_val"
2721                 fi
2722         done
2723         if test "$ol_arg" = "invalid" ; then
2724                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slapi" >&5
2725 echo "$as_me: error: bad value $enableval for --enable-slapi" >&2;}
2726    { (exit 1); exit 1; }; }
2727         fi
2728         ol_enable_slapi="$ol_arg"
2729
2730 else
2731         ol_enable_slapi=no
2732 fi;
2733 # end --enable-slapi
2734 # OpenLDAP --enable-slp
2735
2736         # Check whether --enable-slp or --disable-slp was given.
2737 if test "${enable_slp+set}" = set; then
2738   enableval="$enable_slp"
2739
2740         ol_arg=invalid
2741         for ol_val in auto yes no ; do
2742                 if test "$enableval" = "$ol_val" ; then
2743                         ol_arg="$ol_val"
2744                 fi
2745         done
2746         if test "$ol_arg" = "invalid" ; then
2747                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slp" >&5
2748 echo "$as_me: error: bad value $enableval for --enable-slp" >&2;}
2749    { (exit 1); exit 1; }; }
2750         fi
2751         ol_enable_slp="$ol_arg"
2752
2753 else
2754         ol_enable_slp=no
2755 fi;
2756 # end --enable-slp
2757 # OpenLDAP --enable-wrappers
2758
2759         # Check whether --enable-wrappers or --disable-wrappers was given.
2760 if test "${enable_wrappers+set}" = set; then
2761   enableval="$enable_wrappers"
2762
2763         ol_arg=invalid
2764         for ol_val in auto yes no ; do
2765                 if test "$enableval" = "$ol_val" ; then
2766                         ol_arg="$ol_val"
2767                 fi
2768         done
2769         if test "$ol_arg" = "invalid" ; then
2770                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-wrappers" >&5
2771 echo "$as_me: error: bad value $enableval for --enable-wrappers" >&2;}
2772    { (exit 1); exit 1; }; }
2773         fi
2774         ol_enable_wrappers="$ol_arg"
2775
2776 else
2777         ol_enable_wrappers=no
2778 fi;
2779 # end --enable-wrappers
2780
2781 Backends="bdb \
2782         dnssrv \
2783         hdb \
2784         ldap \
2785         meta \
2786         monitor \
2787         null \
2788         passwd \
2789         perl \
2790         relay \
2791         shell \
2792         sock \
2793         sql"
2794
2795 # Check whether --enable-xxslapbackends or --disable-xxslapbackends was given.
2796 if test "${enable_xxslapbackends+set}" = set; then
2797   enableval="$enable_xxslapbackends"
2798
2799 fi;
2800
2801 # OpenLDAP --enable-backends
2802
2803         # Check whether --enable-backends or --disable-backends was given.
2804 if test "${enable_backends+set}" = set; then
2805   enableval="$enable_backends"
2806
2807         ol_arg=invalid
2808         for ol_val in no yes mod ; do
2809                 if test "$enableval" = "$ol_val" ; then
2810                         ol_arg="$ol_val"
2811                 fi
2812         done
2813         if test "$ol_arg" = "invalid" ; then
2814                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-backends" >&5
2815 echo "$as_me: error: bad value $enableval for --enable-backends" >&2;}
2816    { (exit 1); exit 1; }; }
2817         fi
2818         ol_enable_backends="$ol_arg"
2819
2820 fi;
2821 # end --enable-backends
2822 # OpenLDAP --enable-bdb
2823
2824         # Check whether --enable-bdb or --disable-bdb was given.
2825 if test "${enable_bdb+set}" = set; then
2826   enableval="$enable_bdb"
2827
2828         ol_arg=invalid
2829         for ol_val in no yes mod ; do
2830                 if test "$enableval" = "$ol_val" ; then
2831                         ol_arg="$ol_val"
2832                 fi
2833         done
2834         if test "$ol_arg" = "invalid" ; then
2835                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-bdb" >&5
2836 echo "$as_me: error: bad value $enableval for --enable-bdb" >&2;}
2837    { (exit 1); exit 1; }; }
2838         fi
2839         ol_enable_bdb="$ol_arg"
2840
2841 else
2842         ol_enable_bdb=${ol_enable_backends:-yes}
2843 fi;
2844 # end --enable-bdb
2845 # OpenLDAP --enable-dnssrv
2846
2847         # Check whether --enable-dnssrv or --disable-dnssrv was given.
2848 if test "${enable_dnssrv+set}" = set; then
2849   enableval="$enable_dnssrv"
2850
2851         ol_arg=invalid
2852         for ol_val in no yes mod ; do
2853                 if test "$enableval" = "$ol_val" ; then
2854                         ol_arg="$ol_val"
2855                 fi
2856         done
2857         if test "$ol_arg" = "invalid" ; then
2858                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dnssrv" >&5
2859 echo "$as_me: error: bad value $enableval for --enable-dnssrv" >&2;}
2860    { (exit 1); exit 1; }; }
2861         fi
2862         ol_enable_dnssrv="$ol_arg"
2863
2864 else
2865         ol_enable_dnssrv=${ol_enable_backends:-no}
2866 fi;
2867 # end --enable-dnssrv
2868 # OpenLDAP --enable-hdb
2869
2870         # Check whether --enable-hdb or --disable-hdb was given.
2871 if test "${enable_hdb+set}" = set; then
2872   enableval="$enable_hdb"
2873
2874         ol_arg=invalid
2875         for ol_val in no yes mod ; do
2876                 if test "$enableval" = "$ol_val" ; then
2877                         ol_arg="$ol_val"
2878                 fi
2879         done
2880         if test "$ol_arg" = "invalid" ; then
2881                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-hdb" >&5
2882 echo "$as_me: error: bad value $enableval for --enable-hdb" >&2;}
2883    { (exit 1); exit 1; }; }
2884         fi
2885         ol_enable_hdb="$ol_arg"
2886
2887 else
2888         ol_enable_hdb=${ol_enable_backends:-yes}
2889 fi;
2890 # end --enable-hdb
2891 # OpenLDAP --enable-ldap
2892
2893         # Check whether --enable-ldap or --disable-ldap was given.
2894 if test "${enable_ldap+set}" = set; then
2895   enableval="$enable_ldap"
2896
2897         ol_arg=invalid
2898         for ol_val in no yes mod ; do
2899                 if test "$enableval" = "$ol_val" ; then
2900                         ol_arg="$ol_val"
2901                 fi
2902         done
2903         if test "$ol_arg" = "invalid" ; then
2904                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ldap" >&5
2905 echo "$as_me: error: bad value $enableval for --enable-ldap" >&2;}
2906    { (exit 1); exit 1; }; }
2907         fi
2908         ol_enable_ldap="$ol_arg"
2909
2910 else
2911         ol_enable_ldap=${ol_enable_backends:-no}
2912 fi;
2913 # end --enable-ldap
2914 # OpenLDAP --enable-meta
2915
2916         # Check whether --enable-meta or --disable-meta was given.
2917 if test "${enable_meta+set}" = set; then
2918   enableval="$enable_meta"
2919
2920         ol_arg=invalid
2921         for ol_val in no yes mod ; do
2922                 if test "$enableval" = "$ol_val" ; then
2923                         ol_arg="$ol_val"
2924                 fi
2925         done
2926         if test "$ol_arg" = "invalid" ; then
2927                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-meta" >&5
2928 echo "$as_me: error: bad value $enableval for --enable-meta" >&2;}
2929    { (exit 1); exit 1; }; }
2930         fi
2931         ol_enable_meta="$ol_arg"
2932
2933 else
2934         ol_enable_meta=${ol_enable_backends:-no}
2935 fi;
2936 # end --enable-meta
2937 # OpenLDAP --enable-monitor
2938
2939         # Check whether --enable-monitor or --disable-monitor was given.
2940 if test "${enable_monitor+set}" = set; then
2941   enableval="$enable_monitor"
2942
2943         ol_arg=invalid
2944         for ol_val in no yes mod ; do
2945                 if test "$enableval" = "$ol_val" ; then
2946                         ol_arg="$ol_val"
2947                 fi
2948         done
2949         if test "$ol_arg" = "invalid" ; then
2950                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-monitor" >&5
2951 echo "$as_me: error: bad value $enableval for --enable-monitor" >&2;}
2952    { (exit 1); exit 1; }; }
2953         fi
2954         ol_enable_monitor="$ol_arg"
2955
2956 else
2957         ol_enable_monitor=${ol_enable_backends:-yes}
2958 fi;
2959 # end --enable-monitor
2960 # OpenLDAP --enable-null
2961
2962         # Check whether --enable-null or --disable-null was given.
2963 if test "${enable_null+set}" = set; then
2964   enableval="$enable_null"
2965
2966         ol_arg=invalid
2967         for ol_val in no yes mod ; do
2968                 if test "$enableval" = "$ol_val" ; then
2969                         ol_arg="$ol_val"
2970                 fi
2971         done
2972         if test "$ol_arg" = "invalid" ; then
2973                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-null" >&5
2974 echo "$as_me: error: bad value $enableval for --enable-null" >&2;}
2975    { (exit 1); exit 1; }; }
2976         fi
2977         ol_enable_null="$ol_arg"
2978
2979 else
2980         ol_enable_null=${ol_enable_backends:-no}
2981 fi;
2982 # end --enable-null
2983 # OpenLDAP --enable-passwd
2984
2985         # Check whether --enable-passwd or --disable-passwd was given.
2986 if test "${enable_passwd+set}" = set; then
2987   enableval="$enable_passwd"
2988
2989         ol_arg=invalid
2990         for ol_val in no yes mod ; do
2991                 if test "$enableval" = "$ol_val" ; then
2992                         ol_arg="$ol_val"
2993                 fi
2994         done
2995         if test "$ol_arg" = "invalid" ; then
2996                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-passwd" >&5
2997 echo "$as_me: error: bad value $enableval for --enable-passwd" >&2;}
2998    { (exit 1); exit 1; }; }
2999         fi
3000         ol_enable_passwd="$ol_arg"
3001
3002 else
3003         ol_enable_passwd=${ol_enable_backends:-no}
3004 fi;
3005 # end --enable-passwd
3006 # OpenLDAP --enable-perl
3007
3008         # Check whether --enable-perl or --disable-perl was given.
3009 if test "${enable_perl+set}" = set; then
3010   enableval="$enable_perl"
3011
3012         ol_arg=invalid
3013         for ol_val in no yes mod ; do
3014                 if test "$enableval" = "$ol_val" ; then
3015                         ol_arg="$ol_val"
3016                 fi
3017         done
3018         if test "$ol_arg" = "invalid" ; then
3019                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-perl" >&5
3020 echo "$as_me: error: bad value $enableval for --enable-perl" >&2;}
3021    { (exit 1); exit 1; }; }
3022         fi
3023         ol_enable_perl="$ol_arg"
3024
3025 else
3026         ol_enable_perl=${ol_enable_backends:-no}
3027 fi;
3028 # end --enable-perl
3029 # OpenLDAP --enable-relay
3030
3031         # Check whether --enable-relay or --disable-relay was given.
3032 if test "${enable_relay+set}" = set; then
3033   enableval="$enable_relay"
3034
3035         ol_arg=invalid
3036         for ol_val in no yes mod ; do
3037                 if test "$enableval" = "$ol_val" ; then
3038                         ol_arg="$ol_val"
3039                 fi
3040         done
3041         if test "$ol_arg" = "invalid" ; then
3042                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-relay" >&5
3043 echo "$as_me: error: bad value $enableval for --enable-relay" >&2;}
3044    { (exit 1); exit 1; }; }
3045         fi
3046         ol_enable_relay="$ol_arg"
3047
3048 else
3049         ol_enable_relay=${ol_enable_backends:-yes}
3050 fi;
3051 # end --enable-relay
3052 # OpenLDAP --enable-shell
3053
3054         # Check whether --enable-shell or --disable-shell was given.
3055 if test "${enable_shell+set}" = set; then
3056   enableval="$enable_shell"
3057
3058         ol_arg=invalid
3059         for ol_val in no yes mod ; do
3060                 if test "$enableval" = "$ol_val" ; then
3061                         ol_arg="$ol_val"
3062                 fi
3063         done
3064         if test "$ol_arg" = "invalid" ; then
3065                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-shell" >&5
3066 echo "$as_me: error: bad value $enableval for --enable-shell" >&2;}
3067    { (exit 1); exit 1; }; }
3068         fi
3069         ol_enable_shell="$ol_arg"
3070
3071 else
3072         ol_enable_shell=${ol_enable_backends:-no}
3073 fi;
3074 # end --enable-shell
3075 # OpenLDAP --enable-sock
3076
3077         # Check whether --enable-sock or --disable-sock was given.
3078 if test "${enable_sock+set}" = set; then
3079   enableval="$enable_sock"
3080
3081         ol_arg=invalid
3082         for ol_val in no yes mod ; do
3083                 if test "$enableval" = "$ol_val" ; then
3084                         ol_arg="$ol_val"
3085                 fi
3086         done
3087         if test "$ol_arg" = "invalid" ; then
3088                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-sock" >&5
3089 echo "$as_me: error: bad value $enableval for --enable-sock" >&2;}
3090    { (exit 1); exit 1; }; }
3091         fi
3092         ol_enable_sock="$ol_arg"
3093
3094 else
3095         ol_enable_sock=${ol_enable_backends:-no}
3096 fi;
3097 # end --enable-sock
3098 # OpenLDAP --enable-sql
3099
3100         # Check whether --enable-sql or --disable-sql was given.
3101 if test "${enable_sql+set}" = set; then
3102   enableval="$enable_sql"
3103
3104         ol_arg=invalid
3105         for ol_val in no yes mod ; do
3106                 if test "$enableval" = "$ol_val" ; then
3107                         ol_arg="$ol_val"
3108                 fi
3109         done
3110         if test "$ol_arg" = "invalid" ; then
3111                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-sql" >&5
3112 echo "$as_me: error: bad value $enableval for --enable-sql" >&2;}
3113    { (exit 1); exit 1; }; }
3114         fi
3115         ol_enable_sql="$ol_arg"
3116
3117 else
3118         ol_enable_sql=${ol_enable_backends:-no}
3119 fi;
3120 # end --enable-sql
3121
3122 Overlays="accesslog \
3123         auditlog \
3124         constraint \
3125         dds \
3126         dyngroup \
3127         dynlist \
3128         memberof \
3129         ppolicy \
3130         proxycache \
3131         refint \
3132         retcode \
3133         rwm \
3134         seqmod \
3135         syncprov \
3136         translucent \
3137         unique \
3138         valsort"
3139
3140 # Check whether --enable-xxslapoverlays or --disable-xxslapoverlays was given.
3141 if test "${enable_xxslapoverlays+set}" = set; then
3142   enableval="$enable_xxslapoverlays"
3143
3144 fi;
3145
3146 # OpenLDAP --enable-overlays
3147
3148         # Check whether --enable-overlays or --disable-overlays was given.
3149 if test "${enable_overlays+set}" = set; then
3150   enableval="$enable_overlays"
3151
3152         ol_arg=invalid
3153         for ol_val in no yes mod ; do
3154                 if test "$enableval" = "$ol_val" ; then
3155                         ol_arg="$ol_val"
3156                 fi
3157         done
3158         if test "$ol_arg" = "invalid" ; then
3159                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-overlays" >&5
3160 echo "$as_me: error: bad value $enableval for --enable-overlays" >&2;}
3161    { (exit 1); exit 1; }; }
3162         fi
3163         ol_enable_overlays="$ol_arg"
3164
3165 fi;
3166 # end --enable-overlays
3167 # OpenLDAP --enable-accesslog
3168
3169         # Check whether --enable-accesslog or --disable-accesslog was given.
3170 if test "${enable_accesslog+set}" = set; then
3171   enableval="$enable_accesslog"
3172
3173         ol_arg=invalid
3174         for ol_val in no yes mod ; do
3175                 if test "$enableval" = "$ol_val" ; then
3176                         ol_arg="$ol_val"
3177                 fi
3178         done
3179         if test "$ol_arg" = "invalid" ; then
3180                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-accesslog" >&5
3181 echo "$as_me: error: bad value $enableval for --enable-accesslog" >&2;}
3182    { (exit 1); exit 1; }; }
3183         fi
3184         ol_enable_accesslog="$ol_arg"
3185
3186 else
3187         ol_enable_accesslog=${ol_enable_overlays:-no}
3188 fi;
3189 # end --enable-accesslog
3190
3191 # OpenLDAP --enable-auditlog
3192
3193         # Check whether --enable-auditlog or --disable-auditlog was given.
3194 if test "${enable_auditlog+set}" = set; then
3195   enableval="$enable_auditlog"
3196
3197         ol_arg=invalid
3198         for ol_val in no yes mod ; do
3199                 if test "$enableval" = "$ol_val" ; then
3200                         ol_arg="$ol_val"
3201                 fi
3202         done
3203         if test "$ol_arg" = "invalid" ; then
3204                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-auditlog" >&5
3205 echo "$as_me: error: bad value $enableval for --enable-auditlog" >&2;}
3206    { (exit 1); exit 1; }; }
3207         fi
3208         ol_enable_auditlog="$ol_arg"
3209
3210 else
3211         ol_enable_auditlog=${ol_enable_overlays:-no}
3212 fi;
3213 # end --enable-auditlog
3214
3215 # OpenLDAP --enable-constraint
3216
3217         # Check whether --enable-constraint or --disable-constraint was given.
3218 if test "${enable_constraint+set}" = set; then
3219   enableval="$enable_constraint"
3220
3221         ol_arg=invalid
3222         for ol_val in no yes mod ; do
3223                 if test "$enableval" = "$ol_val" ; then
3224                         ol_arg="$ol_val"
3225                 fi
3226         done
3227         if test "$ol_arg" = "invalid" ; then
3228                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-constraint" >&5
3229 echo "$as_me: error: bad value $enableval for --enable-constraint" >&2;}
3230    { (exit 1); exit 1; }; }
3231         fi
3232         ol_enable_constraint="$ol_arg"
3233
3234 else
3235         ol_enable_constraint=${ol_enable_overlays:-no}
3236 fi;
3237 # end --enable-constraint
3238
3239 # OpenLDAP --enable-dds
3240
3241         # Check whether --enable-dds or --disable-dds was given.
3242 if test "${enable_dds+set}" = set; then
3243   enableval="$enable_dds"
3244
3245         ol_arg=invalid
3246         for ol_val in no yes mod ; do
3247                 if test "$enableval" = "$ol_val" ; then
3248                         ol_arg="$ol_val"
3249                 fi
3250         done
3251         if test "$ol_arg" = "invalid" ; then
3252                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dds" >&5
3253 echo "$as_me: error: bad value $enableval for --enable-dds" >&2;}
3254    { (exit 1); exit 1; }; }
3255         fi
3256         ol_enable_dds="$ol_arg"
3257
3258 else
3259         ol_enable_dds=${ol_enable_overlays:-no}
3260 fi;
3261 # end --enable-dds
3262
3263 # OpenLDAP --enable-dyngroup
3264
3265         # Check whether --enable-dyngroup or --disable-dyngroup was given.
3266 if test "${enable_dyngroup+set}" = set; then
3267   enableval="$enable_dyngroup"
3268
3269         ol_arg=invalid
3270         for ol_val in no yes mod ; do
3271                 if test "$enableval" = "$ol_val" ; then
3272                         ol_arg="$ol_val"
3273                 fi
3274         done
3275         if test "$ol_arg" = "invalid" ; then
3276                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dyngroup" >&5
3277 echo "$as_me: error: bad value $enableval for --enable-dyngroup" >&2;}
3278    { (exit 1); exit 1; }; }
3279         fi
3280         ol_enable_dyngroup="$ol_arg"
3281
3282 else
3283         ol_enable_dyngroup=${ol_enable_overlays:-no}
3284 fi;
3285 # end --enable-dyngroup
3286
3287 # OpenLDAP --enable-dynlist
3288
3289         # Check whether --enable-dynlist or --disable-dynlist was given.
3290 if test "${enable_dynlist+set}" = set; then
3291   enableval="$enable_dynlist"
3292
3293         ol_arg=invalid
3294         for ol_val in no yes mod ; do
3295                 if test "$enableval" = "$ol_val" ; then
3296                         ol_arg="$ol_val"
3297                 fi
3298         done
3299         if test "$ol_arg" = "invalid" ; then
3300                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dynlist" >&5
3301 echo "$as_me: error: bad value $enableval for --enable-dynlist" >&2;}
3302    { (exit 1); exit 1; }; }
3303         fi
3304         ol_enable_dynlist="$ol_arg"
3305
3306 else
3307         ol_enable_dynlist=${ol_enable_overlays:-no}
3308 fi;
3309 # end --enable-dynlist
3310
3311 # OpenLDAP --enable-memberof
3312
3313         # Check whether --enable-memberof or --disable-memberof was given.
3314 if test "${enable_memberof+set}" = set; then
3315   enableval="$enable_memberof"
3316
3317         ol_arg=invalid
3318         for ol_val in no yes mod ; do
3319                 if test "$enableval" = "$ol_val" ; then
3320                         ol_arg="$ol_val"
3321                 fi
3322         done
3323         if test "$ol_arg" = "invalid" ; then
3324                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-memberof" >&5
3325 echo "$as_me: error: bad value $enableval for --enable-memberof" >&2;}
3326    { (exit 1); exit 1; }; }
3327         fi
3328         ol_enable_memberof="$ol_arg"
3329
3330 else
3331         ol_enable_memberof=${ol_enable_overlays:-no}
3332 fi;
3333 # end --enable-memberof
3334
3335 # OpenLDAP --enable-ppolicy
3336
3337         # Check whether --enable-ppolicy or --disable-ppolicy was given.
3338 if test "${enable_ppolicy+set}" = set; then
3339   enableval="$enable_ppolicy"
3340
3341         ol_arg=invalid
3342         for ol_val in no yes mod ; do
3343                 if test "$enableval" = "$ol_val" ; then
3344                         ol_arg="$ol_val"
3345                 fi
3346         done
3347         if test "$ol_arg" = "invalid" ; then
3348                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ppolicy" >&5
3349 echo "$as_me: error: bad value $enableval for --enable-ppolicy" >&2;}
3350    { (exit 1); exit 1; }; }
3351         fi
3352         ol_enable_ppolicy="$ol_arg"
3353
3354 else
3355         ol_enable_ppolicy=${ol_enable_overlays:-no}
3356 fi;
3357 # end --enable-ppolicy
3358
3359 # OpenLDAP --enable-proxycache
3360
3361         # Check whether --enable-proxycache or --disable-proxycache was given.
3362 if test "${enable_proxycache+set}" = set; then
3363   enableval="$enable_proxycache"
3364
3365         ol_arg=invalid
3366         for ol_val in no yes mod ; do
3367                 if test "$enableval" = "$ol_val" ; then
3368                         ol_arg="$ol_val"
3369                 fi
3370         done
3371         if test "$ol_arg" = "invalid" ; then
3372                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-proxycache" >&5
3373 echo "$as_me: error: bad value $enableval for --enable-proxycache" >&2;}
3374    { (exit 1); exit 1; }; }
3375         fi
3376         ol_enable_proxycache="$ol_arg"
3377
3378 else
3379         ol_enable_proxycache=${ol_enable_overlays:-no}
3380 fi;
3381 # end --enable-proxycache
3382
3383 # OpenLDAP --enable-refint
3384
3385         # Check whether --enable-refint or --disable-refint was given.
3386 if test "${enable_refint+set}" = set; then
3387   enableval="$enable_refint"
3388
3389         ol_arg=invalid
3390         for ol_val in no yes mod ; do
3391                 if test "$enableval" = "$ol_val" ; then
3392                         ol_arg="$ol_val"
3393                 fi
3394         done
3395         if test "$ol_arg" = "invalid" ; then
3396                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-refint" >&5
3397 echo "$as_me: error: bad value $enableval for --enable-refint" >&2;}
3398    { (exit 1); exit 1; }; }
3399         fi
3400         ol_enable_refint="$ol_arg"
3401
3402 else
3403         ol_enable_refint=${ol_enable_overlays:-no}
3404 fi;
3405 # end --enable-refint
3406
3407 # OpenLDAP --enable-retcode
3408
3409         # Check whether --enable-retcode or --disable-retcode was given.
3410 if test "${enable_retcode+set}" = set; then
3411   enableval="$enable_retcode"
3412
3413         ol_arg=invalid
3414         for ol_val in no yes mod ; do
3415                 if test "$enableval" = "$ol_val" ; then
3416                         ol_arg="$ol_val"
3417                 fi
3418         done
3419         if test "$ol_arg" = "invalid" ; then
3420                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-retcode" >&5
3421 echo "$as_me: error: bad value $enableval for --enable-retcode" >&2;}
3422    { (exit 1); exit 1; }; }
3423         fi
3424         ol_enable_retcode="$ol_arg"
3425
3426 else
3427         ol_enable_retcode=${ol_enable_overlays:-no}
3428 fi;
3429 # end --enable-retcode
3430
3431 # OpenLDAP --enable-rwm
3432
3433         # Check whether --enable-rwm or --disable-rwm was given.
3434 if test "${enable_rwm+set}" = set; then
3435   enableval="$enable_rwm"
3436
3437         ol_arg=invalid
3438         for ol_val in no yes mod ; do
3439                 if test "$enableval" = "$ol_val" ; then
3440                         ol_arg="$ol_val"
3441                 fi
3442         done
3443         if test "$ol_arg" = "invalid" ; then
3444                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rwm" >&5
3445 echo "$as_me: error: bad value $enableval for --enable-rwm" >&2;}
3446    { (exit 1); exit 1; }; }
3447         fi
3448         ol_enable_rwm="$ol_arg"
3449
3450 else
3451         ol_enable_rwm=${ol_enable_overlays:-no}
3452 fi;
3453 # end --enable-rwm
3454
3455 # OpenLDAP --enable-seqmod
3456
3457         # Check whether --enable-seqmod or --disable-seqmod was given.
3458 if test "${enable_seqmod+set}" = set; then
3459   enableval="$enable_seqmod"
3460
3461         ol_arg=invalid
3462         for ol_val in no yes mod ; do
3463                 if test "$enableval" = "$ol_val" ; then
3464                         ol_arg="$ol_val"
3465                 fi
3466         done
3467         if test "$ol_arg" = "invalid" ; then
3468                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-seqmod" >&5
3469 echo "$as_me: error: bad value $enableval for --enable-seqmod" >&2;}
3470    { (exit 1); exit 1; }; }
3471         fi
3472         ol_enable_seqmod="$ol_arg"
3473
3474 else
3475         ol_enable_seqmod=${ol_enable_overlays:-yes}
3476 fi;
3477 # end --enable-seqmod
3478
3479 # OpenLDAP --enable-syncprov
3480
3481         # Check whether --enable-syncprov or --disable-syncprov was given.
3482 if test "${enable_syncprov+set}" = set; then
3483   enableval="$enable_syncprov"
3484
3485         ol_arg=invalid
3486         for ol_val in no yes mod ; do
3487                 if test "$enableval" = "$ol_val" ; then
3488                         ol_arg="$ol_val"
3489                 fi
3490         done
3491         if test "$ol_arg" = "invalid" ; then
3492                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-syncprov" >&5
3493 echo "$as_me: error: bad value $enableval for --enable-syncprov" >&2;}
3494    { (exit 1); exit 1; }; }
3495         fi
3496         ol_enable_syncprov="$ol_arg"
3497
3498 else
3499         ol_enable_syncprov=${ol_enable_overlays:-yes}
3500 fi;
3501 # end --enable-syncprov
3502
3503 # OpenLDAP --enable-translucent
3504
3505         # Check whether --enable-translucent or --disable-translucent was given.
3506 if test "${enable_translucent+set}" = set; then
3507   enableval="$enable_translucent"
3508
3509         ol_arg=invalid
3510         for ol_val in no yes mod ; do
3511                 if test "$enableval" = "$ol_val" ; then
3512                         ol_arg="$ol_val"
3513                 fi
3514         done
3515         if test "$ol_arg" = "invalid" ; then
3516                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-translucent" >&5
3517 echo "$as_me: error: bad value $enableval for --enable-translucent" >&2;}
3518    { (exit 1); exit 1; }; }
3519         fi
3520         ol_enable_translucent="$ol_arg"
3521
3522 else
3523         ol_enable_translucent=${ol_enable_overlays:-no}
3524 fi;
3525 # end --enable-translucent
3526
3527 # OpenLDAP --enable-unique
3528
3529         # Check whether --enable-unique or --disable-unique was given.
3530 if test "${enable_unique+set}" = set; then
3531   enableval="$enable_unique"
3532
3533         ol_arg=invalid
3534         for ol_val in no yes mod ; do
3535                 if test "$enableval" = "$ol_val" ; then
3536                         ol_arg="$ol_val"
3537                 fi
3538         done
3539         if test "$ol_arg" = "invalid" ; then
3540                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-unique" >&5
3541 echo "$as_me: error: bad value $enableval for --enable-unique" >&2;}
3542    { (exit 1); exit 1; }; }
3543         fi
3544         ol_enable_unique="$ol_arg"
3545
3546 else
3547         ol_enable_unique=${ol_enable_overlays:-no}
3548 fi;
3549 # end --enable-unique
3550
3551 # OpenLDAP --enable-valsort
3552
3553         # Check whether --enable-valsort or --disable-valsort was given.
3554 if test "${enable_valsort+set}" = set; then
3555   enableval="$enable_valsort"
3556
3557         ol_arg=invalid
3558         for ol_val in no yes mod ; do
3559                 if test "$enableval" = "$ol_val" ; then
3560                         ol_arg="$ol_val"
3561                 fi
3562         done
3563         if test "$ol_arg" = "invalid" ; then
3564                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-valsort" >&5
3565 echo "$as_me: error: bad value $enableval for --enable-valsort" >&2;}
3566    { (exit 1); exit 1; }; }
3567         fi
3568         ol_enable_valsort="$ol_arg"
3569
3570 else
3571         ol_enable_valsort=${ol_enable_overlays:-no}
3572 fi;
3573 # end --enable-valsort
3574
3575
3576 # Check whether --enable-xxliboptions or --disable-xxliboptions was given.
3577 if test "${enable_xxliboptions+set}" = set; then
3578   enableval="$enable_xxliboptions"
3579
3580 fi;
3581 # Check whether --enable-static or --disable-static was given.
3582 if test "${enable_static+set}" = set; then
3583   enableval="$enable_static"
3584   p=${PACKAGE-default}
3585     case $enableval in
3586     yes) enable_static=yes ;;
3587     no) enable_static=no ;;
3588     *)
3589      enable_static=no
3590       # Look at the argument we got.  We use all the common list separators.
3591       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
3592       for pkg in $enableval; do
3593         IFS="$lt_save_ifs"
3594         if test "X$pkg" = "X$p"; then
3595           enable_static=yes
3596         fi
3597       done
3598       IFS="$lt_save_ifs"
3599       ;;
3600     esac
3601 else
3602   enable_static=yes
3603 fi;
3604
3605 # Check whether --enable-shared or --disable-shared was given.
3606 if test "${enable_shared+set}" = set; then
3607   enableval="$enable_shared"
3608   p=${PACKAGE-default}
3609     case $enableval in
3610     yes) enable_shared=yes ;;
3611     no) enable_shared=no ;;
3612     *)
3613       enable_shared=no
3614       # Look at the argument we got.  We use all the common list separators.
3615       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
3616       for pkg in $enableval; do
3617         IFS="$lt_save_ifs"
3618         if test "X$pkg" = "X$p"; then
3619           enable_shared=yes
3620         fi
3621       done
3622       IFS="$lt_save_ifs"
3623       ;;
3624     esac
3625 else
3626   enable_shared=yes
3627 fi;
3628
3629
3630
3631 # validate options
3632 if test $ol_enable_slapd = no ; then
3633                 if test $ol_enable_slapi = yes ; then
3634                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-slapi argument" >&5
3635 echo "$as_me: WARNING: slapd disabled, ignoring --enable-slapi argument" >&2;}
3636         fi
3637         case "$ol_enable_backends" in yes | mod)
3638                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-backends argument" >&5
3639 echo "$as_me: WARNING: slapd disabled, ignoring --enable-backends argument" >&2;}
3640         esac
3641         for i in $Backends; do
3642                 eval "ol_tmp=\$ol_enable_$i"
3643                 if test $ol_tmp != no ; then
3644                         { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-$i argument" >&5
3645 echo "$as_me: WARNING: slapd disabled, ignoring --enable-$i argument" >&2;}
3646                         eval "ol_enable_$i=no"
3647                 fi
3648         done
3649         if test $ol_enable_modules = yes ; then
3650                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-modules argument" >&5
3651 echo "$as_me: WARNING: slapd disabled, ignoring --enable-modules argument" >&2;}
3652         fi
3653         if test $ol_enable_wrappers = yes ; then
3654                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-wrappers argument" >&5
3655 echo "$as_me: WARNING: slapd disabled, ignoring --enable-wrappers argument" >&2;}
3656         fi
3657         if test $ol_enable_rlookups = yes ; then
3658                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-rlookups argument" >&5
3659 echo "$as_me: WARNING: slapd disabled, ignoring --enable-rlookups argument" >&2;}
3660         fi
3661         if test $ol_enable_dynacl = yes ; then
3662                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-dynacl argument" >&5
3663 echo "$as_me: WARNING: slapd disabled, ignoring --enable-dynacl argument" >&2;}
3664         fi
3665         if test $ol_enable_aci != no ; then
3666                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-aci argument" >&5
3667 echo "$as_me: WARNING: slapd disabled, ignoring --enable-aci argument" >&2;}
3668         fi
3669         if test $ol_enable_rewrite = yes ; then
3670                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-rewrite argument" >&5
3671 echo "$as_me: WARNING: slapd disabled, ignoring --enable-rewrite argument" >&2;}
3672         fi
3673                 case "$ol_enable_overlays" in yes | mod)
3674                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-overlays argument" >&5
3675 echo "$as_me: WARNING: slapd disabled, ignoring --enable-overlays argument" >&2;}
3676         esac
3677         for i in $Overlays; do
3678                 eval "ol_tmp=\$ol_enable_$i"
3679                 if test $ol_tmp != no ; then
3680                         { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-$i argument" >&5
3681 echo "$as_me: WARNING: slapd disabled, ignoring --enable-$i argument" >&2;}
3682                         eval "ol_enable_$i=no"
3683                 fi
3684         done
3685
3686         # force settings to no
3687         ol_enable_slapi=no
3688
3689         ol_enable_backends=
3690         ol_enable_overlays=
3691         ol_enable_modules=no
3692         ol_enable_rlookups=no
3693         ol_enable_dynacl=no
3694         ol_enable_aci=no
3695         ol_enable_wrappers=no
3696
3697         ol_enable_rewrite=no
3698
3699 elif test $ol_enable_modules != yes &&
3700         test $ol_enable_bdb = no &&
3701         test $ol_enable_dnssrv = no &&
3702         test $ol_enable_hdb = no &&
3703         test $ol_enable_ldap = no &&
3704         test $ol_enable_meta = no &&
3705         test $ol_enable_monitor = no &&
3706         test $ol_enable_null = no &&
3707         test $ol_enable_passwd = no &&
3708         test $ol_enable_perl = no &&
3709         test $ol_enable_relay = no &&
3710         test $ol_enable_shell = no &&
3711         test $ol_enable_sock = no &&
3712         test $ol_enable_sql = no ; then
3713
3714         if test $ol_enable_slapd = yes ; then
3715                 { { echo "$as_me:$LINENO: error: slapd requires a backend" >&5
3716 echo "$as_me: error: slapd requires a backend" >&2;}
3717    { (exit 1); exit 1; }; }
3718         else
3719                 { echo "$as_me:$LINENO: WARNING: skipping slapd, no backend specified" >&5
3720 echo "$as_me: WARNING: skipping slapd, no backend specified" >&2;}
3721                 ol_enable_slapd=no
3722         fi
3723 fi
3724
3725 if test $ol_enable_meta/$ol_enable_ldap = yes/no ; then
3726         { { echo "$as_me:$LINENO: error: --enable-meta requires --enable-ldap" >&5
3727 echo "$as_me: error: --enable-meta requires --enable-ldap" >&2;}
3728    { (exit 1); exit 1; }; }
3729 fi
3730
3731 if test $ol_enable_lmpasswd = yes ; then
3732         if test $ol_with_tls = no ; then
3733                 { { echo "$as_me:$LINENO: error: LAN Manager passwords require OpenSSL" >&5
3734 echo "$as_me: error: LAN Manager passwords require OpenSSL" >&2;}
3735    { (exit 1); exit 1; }; }
3736         fi
3737 fi
3738
3739 if test $ol_enable_spasswd = yes ; then
3740         if test $ol_with_cyrus_sasl = no ; then
3741                 { { echo "$as_me:$LINENO: error: options require --with-cyrus-sasl" >&5
3742 echo "$as_me: error: options require --with-cyrus-sasl" >&2;}
3743    { (exit 1); exit 1; }; }
3744         fi
3745         ol_with_cyrus_sasl=yes
3746 fi
3747
3748 echo "$as_me:$LINENO: result: done" >&5
3749 echo "${ECHO_T}done" >&6
3750
3751 LDAP_LIBS=
3752 BDB_LIBS=
3753 LTHREAD_LIBS=
3754 LUTIL_LIBS=
3755
3756 SLAPD_LIBS=
3757
3758 BUILD_SLAPD=no
3759
3760 BUILD_THREAD=no
3761
3762 BUILD_SLAPI=no
3763 SLAPD_SLAPI_DEPEND=
3764
3765 BUILD_BDB=no
3766 BUILD_DNSSRV=no
3767 BUILD_HDB=no
3768 BUILD_LDAP=no
3769 BUILD_META=no
3770 BUILD_MONITOR=no
3771 BUILD_NULL=no
3772 BUILD_PASSWD=no
3773 BUILD_PERL=no
3774 BUILD_RELAY=no
3775 BUILD_SHELL=no
3776 BUILD_SOCK=no
3777 BUILD_SQL=no
3778
3779 BUILD_ACCESSLOG=no
3780 BUILD_AUDITLOG=no
3781 BUILD_CONSTRAINT=no
3782 BUILD_DDS=no
3783 BUILD_DENYOP=no
3784 BUILD_DYNGROUP=no
3785 BUILD_DYNLIST=no
3786 BUILD_LASTMOD=no
3787 BUILD_MEMBEROF=no
3788 BUILD_PPOLICY=no
3789 BUILD_PROXYCACHE=no
3790 BUILD_REFINT=no
3791 BUILD_RETCODE=no
3792 BUILD_RWM=no
3793 BUILD_SEQMOD=no
3794 BUILD_SYNCPROV=no
3795 BUILD_TRANSLUCENT=no
3796 BUILD_UNIQUE=no
3797 BUILD_VALSORT=no
3798
3799 SLAPD_STATIC_OVERLAYS=
3800 SLAPD_DYNAMIC_OVERLAYS=
3801
3802 SLAPD_MODULES_LDFLAGS=
3803 SLAPD_MODULES_CPPFLAGS=
3804
3805 SLAPD_STATIC_BACKENDS=back-ldif
3806 SLAPD_DYNAMIC_BACKENDS=
3807
3808 SLAPD_PERL_LDFLAGS=
3809 MOD_PERL_LDFLAGS=
3810 PERL_CPPFLAGS=
3811
3812 SLAPD_SQL_LDFLAGS=
3813 SLAPD_SQL_LIBS=
3814 SLAPD_SQL_INCLUDES=
3815
3816 KRB4_LIBS=
3817 KRB5_LIBS=
3818 SASL_LIBS=
3819 TLS_LIBS=
3820 MODULES_LIBS=
3821 SLAPI_LIBS=
3822 LIBSLAPI=
3823 LIBSLAPITOOLS=
3824 AUTH_LIBS=
3825 ICU_LIBS=
3826
3827 SLAPD_SLP_LIBS=
3828 SLAPD_GMP_LIBS=
3829
3830
3831
3832 cat >>confdefs.h <<\_ACEOF
3833 #define HAVE_MKVERSION 1
3834 _ACEOF
3835
3836
3837
3838
3839 ol_aix_threads=no
3840 case "$target" in
3841 *-*-aix*)       if test -z "$CC" ; then
3842                 case "$ol_with_threads" in
3843                 auto | yes |  posix) ol_aix_threads=yes ;;
3844                 esac
3845         fi
3846 ;;
3847 esac
3848
3849 if test $ol_aix_threads = yes ; then
3850         if test -z "${CC}" ; then
3851                 for ac_prog in cc_r xlc_r cc
3852 do
3853   # Extract the first word of "$ac_prog", so it can be a program name with args.
3854 set dummy $ac_prog; ac_word=$2
3855 echo "$as_me:$LINENO: checking for $ac_word" >&5
3856 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3857 if test "${ac_cv_prog_CC+set}" = set; then
3858   echo $ECHO_N "(cached) $ECHO_C" >&6
3859 else
3860   if test -n "$CC"; then
3861   ac_cv_prog_CC="$CC" # Let the user override the test.
3862 else
3863 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3864 for as_dir in $PATH
3865 do
3866   IFS=$as_save_IFS
3867   test -z "$as_dir" && as_dir=.
3868   for ac_exec_ext in '' $ac_executable_extensions; do
3869   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3870     ac_cv_prog_CC="$ac_prog"
3871     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3872     break 2
3873   fi
3874 done
3875 done
3876
3877 fi
3878 fi
3879 CC=$ac_cv_prog_CC
3880 if test -n "$CC"; then
3881   echo "$as_me:$LINENO: result: $CC" >&5
3882 echo "${ECHO_T}$CC" >&6
3883 else
3884   echo "$as_me:$LINENO: result: no" >&5
3885 echo "${ECHO_T}no" >&6
3886 fi
3887
3888   test -n "$CC" && break
3889 done
3890
3891
3892                 if test "$CC" = cc ; then
3893                                                 if test $ol_with_threads != auto ; then
3894                                 { { echo "$as_me:$LINENO: error: --with-threads requires cc_r (or other suitable compiler) on AIX" >&5
3895 echo "$as_me: error: --with-threads requires cc_r (or other suitable compiler) on AIX" >&2;}
3896    { (exit 1); exit 1; }; }
3897                         else
3898                                 { echo "$as_me:$LINENO: WARNING: disabling threads, no cc_r on AIX" >&5
3899 echo "$as_me: WARNING: disabling threads, no cc_r on AIX" >&2;}
3900                         fi
3901                         ol_with_threads=no
3902                 fi
3903         fi
3904
3905         case ${CC} in cc_r | xlc_r)
3906                 ol_with_threads=posix
3907                 ol_cv_pthread_create=yes
3908                 ;;
3909         esac
3910 fi
3911
3912 if test -z "${CC}"; then
3913         for ac_prog in cc gcc
3914 do
3915   # Extract the first word of "$ac_prog", so it can be a program name with args.
3916 set dummy $ac_prog; ac_word=$2
3917 echo "$as_me:$LINENO: checking for $ac_word" >&5
3918 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3919 if test "${ac_cv_prog_CC+set}" = set; then
3920   echo $ECHO_N "(cached) $ECHO_C" >&6
3921 else
3922   if test -n "$CC"; then
3923   ac_cv_prog_CC="$CC" # Let the user override the test.
3924 else
3925 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3926 for as_dir in $PATH
3927 do
3928   IFS=$as_save_IFS
3929   test -z "$as_dir" && as_dir=.
3930   for ac_exec_ext in '' $ac_executable_extensions; do
3931   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3932     ac_cv_prog_CC="$ac_prog"
3933     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3934     break 2
3935   fi
3936 done
3937 done
3938
3939 fi
3940 fi
3941 CC=$ac_cv_prog_CC
3942 if test -n "$CC"; then
3943   echo "$as_me:$LINENO: result: $CC" >&5
3944 echo "${ECHO_T}$CC" >&6
3945 else
3946   echo "$as_me:$LINENO: result: no" >&5
3947 echo "${ECHO_T}no" >&6
3948 fi
3949
3950   test -n "$CC" && break
3951 done
3952 test -n "$CC" || CC="missing"
3953
3954
3955         if test "${CC}" = "missing" ; then
3956                 { { echo "$as_me:$LINENO: error: Unable to locate cc(1) or suitable replacement.  Check PATH or set CC." >&5
3957 echo "$as_me: error: Unable to locate cc(1) or suitable replacement.  Check PATH or set CC." >&2;}
3958    { (exit 1); exit 1; }; }
3959         fi
3960 fi
3961
3962 if test -z "${AR}"; then
3963         for ac_prog in ar gar
3964 do
3965   # Extract the first word of "$ac_prog", so it can be a program name with args.
3966 set dummy $ac_prog; ac_word=$2
3967 echo "$as_me:$LINENO: checking for $ac_word" >&5
3968 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3969 if test "${ac_cv_prog_AR+set}" = set; then
3970   echo $ECHO_N "(cached) $ECHO_C" >&6
3971 else
3972   if test -n "$AR"; then
3973   ac_cv_prog_AR="$AR" # Let the user override the test.
3974 else
3975 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3976 for as_dir in $PATH
3977 do
3978   IFS=$as_save_IFS
3979   test -z "$as_dir" && as_dir=.
3980   for ac_exec_ext in '' $ac_executable_extensions; do
3981   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3982     ac_cv_prog_AR="$ac_prog"
3983     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3984     break 2
3985   fi
3986 done
3987 done
3988
3989 fi
3990 fi
3991 AR=$ac_cv_prog_AR
3992 if test -n "$AR"; then
3993   echo "$as_me:$LINENO: result: $AR" >&5
3994 echo "${ECHO_T}$AR" >&6
3995 else
3996   echo "$as_me:$LINENO: result: no" >&5
3997 echo "${ECHO_T}no" >&6
3998 fi
3999
4000   test -n "$AR" && break
4001 done
4002 test -n "$AR" || AR="missing"
4003
4004
4005         if test "${AR}" = "missing" ; then
4006                 { { echo "$as_me:$LINENO: error: Unable to locate ar(1) or suitable replacement.  Check PATH or set AR." >&5
4007 echo "$as_me: error: Unable to locate ar(1) or suitable replacement.  Check PATH or set AR." >&2;}
4008    { (exit 1); exit 1; }; }
4009         fi
4010 fi
4011
4012
4013
4014
4015
4016 # Check whether --enable-fast-install or --disable-fast-install was given.
4017 if test "${enable_fast_install+set}" = set; then
4018   enableval="$enable_fast_install"
4019   p=${PACKAGE-default}
4020     case $enableval in
4021     yes) enable_fast_install=yes ;;
4022     no) enable_fast_install=no ;;
4023     *)
4024       enable_fast_install=no
4025       # Look at the argument we got.  We use all the common list separators.
4026       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
4027       for pkg in $enableval; do
4028         IFS="$lt_save_ifs"
4029         if test "X$pkg" = "X$p"; then
4030           enable_fast_install=yes
4031         fi
4032       done
4033       IFS="$lt_save_ifs"
4034       ;;
4035     esac
4036 else
4037   enable_fast_install=yes
4038 fi;
4039
4040 DEPDIR="${am__leading_dot}deps"
4041
4042           ac_config_commands="$ac_config_commands depfiles"
4043
4044
4045 am_make=${MAKE-make}
4046 cat > confinc << 'END'
4047 am__doit:
4048         @echo done
4049 .PHONY: am__doit
4050 END
4051 # If we don't find an include directive, just comment out the code.
4052 echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5
4053 echo $ECHO_N "checking for style of include used by $am_make... $ECHO_C" >&6
4054 am__include="#"
4055 am__quote=
4056 _am_result=none
4057 # First try GNU make style include.
4058 echo "include confinc" > confmf
4059 # We grep out `Entering directory' and `Leaving directory'
4060 # messages which can occur if `w' ends up in MAKEFLAGS.
4061 # In particular we don't look at `^make:' because GNU make might
4062 # be invoked under some other name (usually "gmake"), in which
4063 # case it prints its new name instead of `make'.
4064 if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
4065    am__include=include
4066    am__quote=
4067    _am_result=GNU
4068 fi
4069 # Now try BSD make style include.
4070 if test "$am__include" = "#"; then
4071    echo '.include "confinc"' > confmf
4072    if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
4073       am__include=.include
4074       am__quote="\""
4075       _am_result=BSD
4076    fi
4077 fi
4078
4079
4080 echo "$as_me:$LINENO: result: $_am_result" >&5
4081 echo "${ECHO_T}$_am_result" >&6
4082 rm -f confinc confmf
4083
4084 # Check whether --enable-dependency-tracking or --disable-dependency-tracking was given.
4085 if test "${enable_dependency_tracking+set}" = set; then
4086   enableval="$enable_dependency_tracking"
4087
4088 fi;
4089 if test "x$enable_dependency_tracking" != xno; then
4090   am_depcomp="$ac_aux_dir/depcomp"
4091   AMDEPBACKSLASH='\'
4092 fi
4093
4094
4095 if test "x$enable_dependency_tracking" != xno; then
4096   AMDEP_TRUE=
4097   AMDEP_FALSE='#'
4098 else
4099   AMDEP_TRUE='#'
4100   AMDEP_FALSE=
4101 fi
4102
4103
4104
4105 ac_ext=c
4106 ac_cpp='$CPP $CPPFLAGS'
4107 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4108 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4109 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4110 if test -n "$ac_tool_prefix"; then
4111   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4112 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4113 echo "$as_me:$LINENO: checking for $ac_word" >&5
4114 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4115 if test "${ac_cv_prog_CC+set}" = set; then
4116   echo $ECHO_N "(cached) $ECHO_C" >&6
4117 else
4118   if test -n "$CC"; then
4119   ac_cv_prog_CC="$CC" # Let the user override the test.
4120 else
4121 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4122 for as_dir in $PATH
4123 do
4124   IFS=$as_save_IFS
4125   test -z "$as_dir" && as_dir=.
4126   for ac_exec_ext in '' $ac_executable_extensions; do
4127   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4128     ac_cv_prog_CC="${ac_tool_prefix}gcc"
4129     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4130     break 2
4131   fi
4132 done
4133 done
4134
4135 fi
4136 fi
4137 CC=$ac_cv_prog_CC
4138 if test -n "$CC"; then
4139   echo "$as_me:$LINENO: result: $CC" >&5
4140 echo "${ECHO_T}$CC" >&6
4141 else
4142   echo "$as_me:$LINENO: result: no" >&5
4143 echo "${ECHO_T}no" >&6
4144 fi
4145
4146 fi
4147 if test -z "$ac_cv_prog_CC"; then
4148   ac_ct_CC=$CC
4149   # Extract the first word of "gcc", so it can be a program name with args.
4150 set dummy gcc; ac_word=$2
4151 echo "$as_me:$LINENO: checking for $ac_word" >&5
4152 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4153 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
4154   echo $ECHO_N "(cached) $ECHO_C" >&6
4155 else
4156   if test -n "$ac_ct_CC"; then
4157   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4158 else
4159 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4160 for as_dir in $PATH
4161 do
4162   IFS=$as_save_IFS
4163   test -z "$as_dir" && as_dir=.
4164   for ac_exec_ext in '' $ac_executable_extensions; do
4165   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4166     ac_cv_prog_ac_ct_CC="gcc"
4167     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4168     break 2
4169   fi
4170 done
4171 done
4172
4173 fi
4174 fi
4175 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4176 if test -n "$ac_ct_CC"; then
4177   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4178 echo "${ECHO_T}$ac_ct_CC" >&6
4179 else
4180   echo "$as_me:$LINENO: result: no" >&5
4181 echo "${ECHO_T}no" >&6
4182 fi
4183
4184   CC=$ac_ct_CC
4185 else
4186   CC="$ac_cv_prog_CC"
4187 fi
4188
4189 if test -z "$CC"; then
4190   if test -n "$ac_tool_prefix"; then
4191   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4192 set dummy ${ac_tool_prefix}cc; ac_word=$2
4193 echo "$as_me:$LINENO: checking for $ac_word" >&5
4194 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4195 if test "${ac_cv_prog_CC+set}" = set; then
4196   echo $ECHO_N "(cached) $ECHO_C" >&6
4197 else
4198   if test -n "$CC"; then
4199   ac_cv_prog_CC="$CC" # Let the user override the test.
4200 else
4201 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4202 for as_dir in $PATH
4203 do
4204   IFS=$as_save_IFS
4205   test -z "$as_dir" && as_dir=.
4206   for ac_exec_ext in '' $ac_executable_extensions; do
4207   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4208     ac_cv_prog_CC="${ac_tool_prefix}cc"
4209     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4210     break 2
4211   fi
4212 done
4213 done
4214
4215 fi
4216 fi
4217 CC=$ac_cv_prog_CC
4218 if test -n "$CC"; then
4219   echo "$as_me:$LINENO: result: $CC" >&5
4220 echo "${ECHO_T}$CC" >&6
4221 else
4222   echo "$as_me:$LINENO: result: no" >&5
4223 echo "${ECHO_T}no" >&6
4224 fi
4225
4226 fi
4227 if test -z "$ac_cv_prog_CC"; then
4228   ac_ct_CC=$CC
4229   # Extract the first word of "cc", so it can be a program name with args.
4230 set dummy cc; ac_word=$2
4231 echo "$as_me:$LINENO: checking for $ac_word" >&5
4232 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4233 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
4234   echo $ECHO_N "(cached) $ECHO_C" >&6
4235 else
4236   if test -n "$ac_ct_CC"; then
4237   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4238 else
4239 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4240 for as_dir in $PATH
4241 do
4242   IFS=$as_save_IFS
4243   test -z "$as_dir" && as_dir=.
4244   for ac_exec_ext in '' $ac_executable_extensions; do
4245   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4246     ac_cv_prog_ac_ct_CC="cc"
4247     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4248     break 2
4249   fi
4250 done
4251 done
4252
4253 fi
4254 fi
4255 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4256 if test -n "$ac_ct_CC"; then
4257   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4258 echo "${ECHO_T}$ac_ct_CC" >&6
4259 else
4260   echo "$as_me:$LINENO: result: no" >&5
4261 echo "${ECHO_T}no" >&6
4262 fi
4263
4264   CC=$ac_ct_CC
4265 else
4266   CC="$ac_cv_prog_CC"
4267 fi
4268
4269 fi
4270 if test -z "$CC"; then
4271   # Extract the first word of "cc", so it can be a program name with args.
4272 set dummy cc; ac_word=$2
4273 echo "$as_me:$LINENO: checking for $ac_word" >&5
4274 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4275 if test "${ac_cv_prog_CC+set}" = set; then
4276   echo $ECHO_N "(cached) $ECHO_C" >&6
4277 else
4278   if test -n "$CC"; then
4279   ac_cv_prog_CC="$CC" # Let the user override the test.
4280 else
4281   ac_prog_rejected=no
4282 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4283 for as_dir in $PATH
4284 do
4285   IFS=$as_save_IFS
4286   test -z "$as_dir" && as_dir=.
4287   for ac_exec_ext in '' $ac_executable_extensions; do
4288   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4289     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4290        ac_prog_rejected=yes
4291        continue
4292      fi
4293     ac_cv_prog_CC="cc"
4294     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4295     break 2
4296   fi
4297 done
4298 done
4299
4300 if test $ac_prog_rejected = yes; then
4301   # We found a bogon in the path, so make sure we never use it.
4302   set dummy $ac_cv_prog_CC
4303   shift
4304   if test $# != 0; then
4305     # We chose a different compiler from the bogus one.
4306     # However, it has the same basename, so the bogon will be chosen
4307     # first if we set CC to just the basename; use the full file name.
4308     shift
4309     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4310   fi
4311 fi
4312 fi
4313 fi
4314 CC=$ac_cv_prog_CC
4315 if test -n "$CC"; then
4316   echo "$as_me:$LINENO: result: $CC" >&5
4317 echo "${ECHO_T}$CC" >&6
4318 else
4319   echo "$as_me:$LINENO: result: no" >&5
4320 echo "${ECHO_T}no" >&6
4321 fi
4322
4323 fi
4324 if test -z "$CC"; then
4325   if test -n "$ac_tool_prefix"; then
4326   for ac_prog in cl
4327   do
4328     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4329 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4330 echo "$as_me:$LINENO: checking for $ac_word" >&5
4331 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4332 if test "${ac_cv_prog_CC+set}" = set; then
4333   echo $ECHO_N "(cached) $ECHO_C" >&6
4334 else
4335   if test -n "$CC"; then
4336   ac_cv_prog_CC="$CC" # Let the user override the test.
4337 else
4338 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4339 for as_dir in $PATH
4340 do
4341   IFS=$as_save_IFS
4342   test -z "$as_dir" && as_dir=.
4343   for ac_exec_ext in '' $ac_executable_extensions; do
4344   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4345     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4346     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4347     break 2
4348   fi
4349 done
4350 done
4351
4352 fi
4353 fi
4354 CC=$ac_cv_prog_CC
4355 if test -n "$CC"; then
4356   echo "$as_me:$LINENO: result: $CC" >&5
4357 echo "${ECHO_T}$CC" >&6
4358 else
4359   echo "$as_me:$LINENO: result: no" >&5
4360 echo "${ECHO_T}no" >&6
4361 fi
4362
4363     test -n "$CC" && break
4364   done
4365 fi
4366 if test -z "$CC"; then
4367   ac_ct_CC=$CC
4368   for ac_prog in cl
4369 do
4370   # Extract the first word of "$ac_prog", so it can be a program name with args.
4371 set dummy $ac_prog; ac_word=$2
4372 echo "$as_me:$LINENO: checking for $ac_word" >&5
4373 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4374 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
4375   echo $ECHO_N "(cached) $ECHO_C" >&6
4376 else
4377   if test -n "$ac_ct_CC"; then
4378   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4379 else
4380 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4381 for as_dir in $PATH
4382 do
4383   IFS=$as_save_IFS
4384   test -z "$as_dir" && as_dir=.
4385   for ac_exec_ext in '' $ac_executable_extensions; do
4386   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4387     ac_cv_prog_ac_ct_CC="$ac_prog"
4388     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4389     break 2
4390   fi
4391 done
4392 done
4393
4394 fi
4395 fi
4396 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4397 if test -n "$ac_ct_CC"; then
4398   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4399 echo "${ECHO_T}$ac_ct_CC" >&6
4400 else
4401   echo "$as_me:$LINENO: result: no" >&5
4402 echo "${ECHO_T}no" >&6
4403 fi
4404
4405   test -n "$ac_ct_CC" && break
4406 done
4407
4408   CC=$ac_ct_CC
4409 fi
4410
4411 fi
4412
4413
4414 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
4415 See \`config.log' for more details." >&5
4416 echo "$as_me: error: no acceptable C compiler found in \$PATH
4417 See \`config.log' for more details." >&2;}
4418    { (exit 1); exit 1; }; }
4419
4420 # Provide some information about the compiler.
4421 echo "$as_me:$LINENO:" \
4422      "checking for C compiler version" >&5
4423 ac_compiler=`set X $ac_compile; echo $2`
4424 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
4425   (eval $ac_compiler --version </dev/null >&5) 2>&5
4426   ac_status=$?
4427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4428   (exit $ac_status); }
4429 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
4430   (eval $ac_compiler -v </dev/null >&5) 2>&5
4431   ac_status=$?
4432   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4433   (exit $ac_status); }
4434 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
4435   (eval $ac_compiler -V </dev/null >&5) 2>&5
4436   ac_status=$?
4437   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4438   (exit $ac_status); }
4439
4440 cat >conftest.$ac_ext <<_ACEOF
4441 /* confdefs.h.  */
4442 _ACEOF
4443 cat confdefs.h >>conftest.$ac_ext
4444 cat >>conftest.$ac_ext <<_ACEOF
4445 /* end confdefs.h.  */
4446
4447 int
4448 main ()
4449 {
4450
4451   ;
4452   return 0;
4453 }
4454 _ACEOF
4455 ac_clean_files_save=$ac_clean_files
4456 ac_clean_files="$ac_clean_files a.out a.exe b.out"
4457 # Try to create an executable without -o first, disregard a.out.
4458 # It will help us diagnose broken compilers, and finding out an intuition
4459 # of exeext.
4460 echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
4461 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
4462 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4463 if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
4464   (eval $ac_link_default) 2>&5
4465   ac_status=$?
4466   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4467   (exit $ac_status); }; then
4468   # Find the output, starting from the most likely.  This scheme is
4469 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
4470 # resort.
4471
4472 # Be careful to initialize this variable, since it used to be cached.
4473 # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
4474 ac_cv_exeext=
4475 # b.out is created by i960 compilers.
4476 for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
4477 do
4478   test -f "$ac_file" || continue
4479   case $ac_file in
4480     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
4481         ;;
4482     conftest.$ac_ext )
4483         # This is the source file.
4484         ;;
4485     [ab].out )
4486         # We found the default executable, but exeext='' is most
4487         # certainly right.
4488         break;;
4489     *.* )
4490         ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4491         # FIXME: I believe we export ac_cv_exeext for Libtool,
4492         # but it would be cool to find out if it's true.  Does anybody
4493         # maintain Libtool? --akim.
4494         export ac_cv_exeext
4495         break;;
4496     * )
4497         break;;
4498   esac
4499 done
4500 else
4501   echo "$as_me: failed program was:" >&5
4502 sed 's/^/| /' conftest.$ac_ext >&5
4503
4504 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
4505 See \`config.log' for more details." >&5
4506 echo "$as_me: error: C compiler cannot create executables
4507 See \`config.log' for more details." >&2;}
4508    { (exit 77); exit 77; }; }
4509 fi
4510
4511 ac_exeext=$ac_cv_exeext
4512 echo "$as_me:$LINENO: result: $ac_file" >&5
4513 echo "${ECHO_T}$ac_file" >&6
4514
4515 # Check the compiler produces executables we can run.  If not, either
4516 # the compiler is broken, or we cross compile.
4517 echo "$as_me:$LINENO: checking whether the C compiler works" >&5
4518 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
4519 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
4520 # If not cross compiling, check that we can run a simple program.
4521 if test "$cross_compiling" != yes; then
4522   if { ac_try='./$ac_file'
4523   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4524   (eval $ac_try) 2>&5
4525   ac_status=$?
4526   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4527   (exit $ac_status); }; }; then
4528     cross_compiling=no
4529   else
4530     if test "$cross_compiling" = maybe; then
4531         cross_compiling=yes
4532     else
4533         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
4534 If you meant to cross compile, use \`--host'.
4535 See \`config.log' for more details." >&5
4536 echo "$as_me: error: cannot run C compiled programs.
4537 If you meant to cross compile, use \`--host'.
4538 See \`config.log' for more details." >&2;}
4539    { (exit 1); exit 1; }; }
4540     fi
4541   fi
4542 fi
4543 echo "$as_me:$LINENO: result: yes" >&5
4544 echo "${ECHO_T}yes" >&6
4545
4546 rm -f a.out a.exe conftest$ac_cv_exeext b.out
4547 ac_clean_files=$ac_clean_files_save
4548 # Check the compiler produces executables we can run.  If not, either
4549 # the compiler is broken, or we cross compile.
4550 echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
4551 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
4552 echo "$as_me:$LINENO: result: $cross_compiling" >&5
4553 echo "${ECHO_T}$cross_compiling" >&6
4554
4555 echo "$as_me:$LINENO: checking for suffix of executables" >&5
4556 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
4557 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4558   (eval $ac_link) 2>&5
4559   ac_status=$?
4560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4561   (exit $ac_status); }; then
4562   # If both `conftest.exe' and `conftest' are `present' (well, observable)
4563 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
4564 # work properly (i.e., refer to `conftest.exe'), while it won't with
4565 # `rm'.
4566 for ac_file in conftest.exe conftest conftest.*; do
4567   test -f "$ac_file" || continue
4568   case $ac_file in
4569     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
4570     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4571           export ac_cv_exeext
4572           break;;
4573     * ) break;;
4574   esac
4575 done
4576 else
4577   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
4578 See \`config.log' for more details." >&5
4579 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
4580 See \`config.log' for more details." >&2;}
4581    { (exit 1); exit 1; }; }
4582 fi
4583
4584 rm -f conftest$ac_cv_exeext
4585 echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
4586 echo "${ECHO_T}$ac_cv_exeext" >&6
4587
4588 rm -f conftest.$ac_ext
4589 EXEEXT=$ac_cv_exeext
4590 ac_exeext=$EXEEXT
4591 echo "$as_me:$LINENO: checking for suffix of object files" >&5
4592 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
4593 if test "${ac_cv_objext+set}" = set; then
4594   echo $ECHO_N "(cached) $ECHO_C" >&6
4595 else
4596   cat >conftest.$ac_ext <<_ACEOF
4597 /* confdefs.h.  */
4598 _ACEOF
4599 cat confdefs.h >>conftest.$ac_ext
4600 cat >>conftest.$ac_ext <<_ACEOF
4601 /* end confdefs.h.  */
4602
4603 int
4604 main ()
4605 {
4606
4607   ;
4608   return 0;
4609 }
4610 _ACEOF
4611 rm -f conftest.o conftest.obj
4612 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4613   (eval $ac_compile) 2>&5
4614   ac_status=$?
4615   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4616   (exit $ac_status); }; then
4617   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
4618   case $ac_file in
4619     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
4620     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4621        break;;
4622   esac
4623 done
4624 else
4625   echo "$as_me: failed program was:" >&5
4626 sed 's/^/| /' conftest.$ac_ext >&5
4627
4628 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
4629 See \`config.log' for more details." >&5
4630 echo "$as_me: error: cannot compute suffix of object files: cannot compile
4631 See \`config.log' for more details." >&2;}
4632    { (exit 1); exit 1; }; }
4633 fi
4634
4635 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4636 fi
4637 echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
4638 echo "${ECHO_T}$ac_cv_objext" >&6
4639 OBJEXT=$ac_cv_objext
4640 ac_objext=$OBJEXT
4641 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
4642 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
4643 if test "${ac_cv_c_compiler_gnu+set}" = set; then
4644   echo $ECHO_N "(cached) $ECHO_C" >&6
4645 else
4646   cat >conftest.$ac_ext <<_ACEOF
4647 /* confdefs.h.  */
4648 _ACEOF
4649 cat confdefs.h >>conftest.$ac_ext
4650 cat >>conftest.$ac_ext <<_ACEOF
4651 /* end confdefs.h.  */
4652
4653 int
4654 main ()
4655 {
4656 #ifndef __GNUC__
4657        choke me
4658 #endif
4659
4660   ;
4661   return 0;
4662 }
4663 _ACEOF
4664 rm -f conftest.$ac_objext
4665 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4666   (eval $ac_compile) 2>conftest.er1
4667   ac_status=$?
4668   grep -v '^ *+' conftest.er1 >conftest.err
4669   rm -f conftest.er1
4670   cat conftest.err >&5
4671   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4672   (exit $ac_status); } &&
4673          { ac_try='test -z "$ac_c_werror_flag"
4674                          || test ! -s conftest.err'
4675   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4676   (eval $ac_try) 2>&5
4677   ac_status=$?
4678   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4679   (exit $ac_status); }; } &&
4680          { ac_try='test -s conftest.$ac_objext'
4681   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4682   (eval $ac_try) 2>&5
4683   ac_status=$?
4684   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4685   (exit $ac_status); }; }; then
4686   ac_compiler_gnu=yes
4687 else
4688   echo "$as_me: failed program was:" >&5
4689 sed 's/^/| /' conftest.$ac_ext >&5
4690
4691 ac_compiler_gnu=no
4692 fi
4693 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4694 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4695
4696 fi
4697 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
4698 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
4699 GCC=`test $ac_compiler_gnu = yes && echo yes`
4700 ac_test_CFLAGS=${CFLAGS+set}
4701 ac_save_CFLAGS=$CFLAGS
4702 CFLAGS="-g"
4703 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
4704 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
4705 if test "${ac_cv_prog_cc_g+set}" = set; then
4706   echo $ECHO_N "(cached) $ECHO_C" >&6
4707 else
4708   cat >conftest.$ac_ext <<_ACEOF
4709 /* confdefs.h.  */
4710 _ACEOF
4711 cat confdefs.h >>conftest.$ac_ext
4712 cat >>conftest.$ac_ext <<_ACEOF
4713 /* end confdefs.h.  */
4714
4715 int
4716 main ()
4717 {
4718
4719   ;
4720   return 0;
4721 }
4722 _ACEOF
4723 rm -f conftest.$ac_objext
4724 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4725   (eval $ac_compile) 2>conftest.er1
4726   ac_status=$?
4727   grep -v '^ *+' conftest.er1 >conftest.err
4728   rm -f conftest.er1
4729   cat conftest.err >&5
4730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4731   (exit $ac_status); } &&
4732          { ac_try='test -z "$ac_c_werror_flag"
4733                          || test ! -s conftest.err'
4734   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4735   (eval $ac_try) 2>&5
4736   ac_status=$?
4737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4738   (exit $ac_status); }; } &&
4739          { ac_try='test -s conftest.$ac_objext'
4740   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4741   (eval $ac_try) 2>&5
4742   ac_status=$?
4743   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4744   (exit $ac_status); }; }; then
4745   ac_cv_prog_cc_g=yes
4746 else
4747   echo "$as_me: failed program was:" >&5
4748 sed 's/^/| /' conftest.$ac_ext >&5
4749
4750 ac_cv_prog_cc_g=no
4751 fi
4752 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4753 fi
4754 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
4755 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
4756 if test "$ac_test_CFLAGS" = set; then
4757   CFLAGS=$ac_save_CFLAGS
4758 elif test $ac_cv_prog_cc_g = yes; then
4759   if test "$GCC" = yes; then
4760     CFLAGS="-g -O2"
4761   else
4762     CFLAGS="-g"
4763   fi
4764 else
4765   if test "$GCC" = yes; then
4766     CFLAGS="-O2"
4767   else
4768     CFLAGS=
4769   fi
4770 fi
4771 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
4772 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
4773 if test "${ac_cv_prog_cc_stdc+set}" = set; then
4774   echo $ECHO_N "(cached) $ECHO_C" >&6
4775 else
4776   ac_cv_prog_cc_stdc=no
4777 ac_save_CC=$CC
4778 cat >conftest.$ac_ext <<_ACEOF
4779 /* confdefs.h.  */
4780 _ACEOF
4781 cat confdefs.h >>conftest.$ac_ext
4782 cat >>conftest.$ac_ext <<_ACEOF
4783 /* end confdefs.h.  */
4784 #include <stdarg.h>
4785 #include <stdio.h>
4786 #include <sys/types.h>
4787 #include <sys/stat.h>
4788 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4789 struct buf { int x; };
4790 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4791 static char *e (p, i)
4792      char **p;
4793      int i;
4794 {
4795   return p[i];
4796 }
4797 static char *f (char * (*g) (char **, int), char **p, ...)
4798 {
4799   char *s;
4800   va_list v;
4801   va_start (v,p);
4802   s = g (p, va_arg (v,int));
4803   va_end (v);
4804   return s;
4805 }
4806
4807 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
4808    function prototypes and stuff, but not '\xHH' hex character constants.
4809    These don't provoke an error unfortunately, instead are silently treated
4810    as 'x'.  The following induces an error, until -std1 is added to get
4811    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
4812    array size at least.  It's necessary to write '\x00'==0 to get something
4813    that's true only with -std1.  */
4814 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4815
4816 int test (int i, double x);
4817 struct s1 {int (*f) (int a);};
4818 struct s2 {int (*f) (double a);};
4819 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4820 int argc;
4821 char **argv;
4822 int
4823 main ()
4824 {
4825 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4826   ;
4827   return 0;
4828 }
4829 _ACEOF
4830 # Don't try gcc -ansi; that turns off useful extensions and
4831 # breaks some systems' header files.
4832 # AIX                   -qlanglvl=ansi
4833 # Ultrix and OSF/1      -std1
4834 # HP-UX 10.20 and later -Ae
4835 # HP-UX older versions  -Aa -D_HPUX_SOURCE
4836 # SVR4                  -Xc -D__EXTENSIONS__
4837 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4838 do
4839   CC="$ac_save_CC $ac_arg"
4840   rm -f conftest.$ac_objext
4841 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4842   (eval $ac_compile) 2>conftest.er1
4843   ac_status=$?
4844   grep -v '^ *+' conftest.er1 >conftest.err
4845   rm -f conftest.er1
4846   cat conftest.err >&5
4847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4848   (exit $ac_status); } &&
4849          { ac_try='test -z "$ac_c_werror_flag"
4850                          || test ! -s conftest.err'
4851   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4852   (eval $ac_try) 2>&5
4853   ac_status=$?
4854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4855   (exit $ac_status); }; } &&
4856          { ac_try='test -s conftest.$ac_objext'
4857   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4858   (eval $ac_try) 2>&5
4859   ac_status=$?
4860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4861   (exit $ac_status); }; }; then
4862   ac_cv_prog_cc_stdc=$ac_arg
4863 break
4864 else
4865   echo "$as_me: failed program was:" >&5
4866 sed 's/^/| /' conftest.$ac_ext >&5
4867
4868 fi
4869 rm -f conftest.err conftest.$ac_objext
4870 done
4871 rm -f conftest.$ac_ext conftest.$ac_objext
4872 CC=$ac_save_CC
4873
4874 fi
4875
4876 case "x$ac_cv_prog_cc_stdc" in
4877   x|xno)
4878     echo "$as_me:$LINENO: result: none needed" >&5
4879 echo "${ECHO_T}none needed" >&6 ;;
4880   *)
4881     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
4882 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
4883     CC="$CC $ac_cv_prog_cc_stdc" ;;
4884 esac
4885
4886 # Some people use a C++ compiler to compile C.  Since we use `exit',
4887 # in C++ we need to declare it.  In case someone uses the same compiler
4888 # for both compiling C and C++ we need to have the C++ compiler decide
4889 # the declaration of exit, since it's the most demanding environment.
4890 cat >conftest.$ac_ext <<_ACEOF
4891 #ifndef __cplusplus
4892   choke me
4893 #endif
4894 _ACEOF
4895 rm -f conftest.$ac_objext
4896 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4897   (eval $ac_compile) 2>conftest.er1
4898   ac_status=$?
4899   grep -v '^ *+' conftest.er1 >conftest.err
4900   rm -f conftest.er1
4901   cat conftest.err >&5
4902   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4903   (exit $ac_status); } &&
4904          { ac_try='test -z "$ac_c_werror_flag"
4905                          || test ! -s conftest.err'
4906   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4907   (eval $ac_try) 2>&5
4908   ac_status=$?
4909   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4910   (exit $ac_status); }; } &&
4911          { ac_try='test -s conftest.$ac_objext'
4912   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4913   (eval $ac_try) 2>&5
4914   ac_status=$?
4915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4916   (exit $ac_status); }; }; then
4917   for ac_declaration in \
4918    '' \
4919    'extern "C" void std::exit (int) throw (); using std::exit;' \
4920    'extern "C" void std::exit (int); using std::exit;' \
4921    'extern "C" void exit (int) throw ();' \
4922    'extern "C" void exit (int);' \
4923    'void exit (int);'
4924 do
4925   cat >conftest.$ac_ext <<_ACEOF
4926 /* confdefs.h.  */
4927 _ACEOF
4928 cat confdefs.h >>conftest.$ac_ext
4929 cat >>conftest.$ac_ext <<_ACEOF
4930 /* end confdefs.h.  */
4931 $ac_declaration
4932 #include <stdlib.h>
4933 int
4934 main ()
4935 {
4936 exit (42);
4937   ;
4938   return 0;
4939 }
4940 _ACEOF
4941 rm -f conftest.$ac_objext
4942 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4943   (eval $ac_compile) 2>conftest.er1
4944   ac_status=$?
4945   grep -v '^ *+' conftest.er1 >conftest.err
4946   rm -f conftest.er1
4947   cat conftest.err >&5
4948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4949   (exit $ac_status); } &&
4950          { ac_try='test -z "$ac_c_werror_flag"
4951                          || test ! -s conftest.err'
4952   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4953   (eval $ac_try) 2>&5
4954   ac_status=$?
4955   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4956   (exit $ac_status); }; } &&
4957          { ac_try='test -s conftest.$ac_objext'
4958   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4959   (eval $ac_try) 2>&5
4960   ac_status=$?
4961   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4962   (exit $ac_status); }; }; then
4963   :
4964 else
4965   echo "$as_me: failed program was:" >&5
4966 sed 's/^/| /' conftest.$ac_ext >&5
4967
4968 continue
4969 fi
4970 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4971   cat >conftest.$ac_ext <<_ACEOF
4972 /* confdefs.h.  */
4973 _ACEOF
4974 cat confdefs.h >>conftest.$ac_ext
4975 cat >>conftest.$ac_ext <<_ACEOF
4976 /* end confdefs.h.  */
4977 $ac_declaration
4978 int
4979 main ()
4980 {
4981 exit (42);
4982   ;
4983   return 0;
4984 }
4985 _ACEOF
4986 rm -f conftest.$ac_objext
4987 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4988   (eval $ac_compile) 2>conftest.er1
4989   ac_status=$?
4990   grep -v '^ *+' conftest.er1 >conftest.err
4991   rm -f conftest.er1
4992   cat conftest.err >&5
4993   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4994   (exit $ac_status); } &&
4995          { ac_try='test -z "$ac_c_werror_flag"
4996                          || test ! -s conftest.err'
4997   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4998   (eval $ac_try) 2>&5
4999   ac_status=$?
5000   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5001   (exit $ac_status); }; } &&
5002          { ac_try='test -s conftest.$ac_objext'
5003   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5004   (eval $ac_try) 2>&5
5005   ac_status=$?
5006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5007   (exit $ac_status); }; }; then
5008   break
5009 else
5010   echo "$as_me: failed program was:" >&5
5011 sed 's/^/| /' conftest.$ac_ext >&5
5012
5013 fi
5014 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5015 done
5016 rm -f conftest*
5017 if test -n "$ac_declaration"; then
5018   echo '#ifdef __cplusplus' >>confdefs.h
5019   echo $ac_declaration      >>confdefs.h
5020   echo '#endif'             >>confdefs.h
5021 fi
5022
5023 else
5024   echo "$as_me: failed program was:" >&5
5025 sed 's/^/| /' conftest.$ac_ext >&5
5026
5027 fi
5028 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5029 ac_ext=c
5030 ac_cpp='$CPP $CPPFLAGS'
5031 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5032 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5033 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5034
5035 depcc="$CC"   am_compiler_list=
5036
5037 echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
5038 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6
5039 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
5040   echo $ECHO_N "(cached) $ECHO_C" >&6
5041 else
5042   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5043   # We make a subdir and do the tests there.  Otherwise we can end up
5044   # making bogus files that we don't know about and never remove.  For
5045   # instance it was reported that on HP-UX the gcc test will end up
5046   # making a dummy file named `D' -- because `-MD' means `put the output
5047   # in D'.
5048   mkdir conftest.dir
5049   # Copy depcomp to subdir because otherwise we won't find it if we're
5050   # using a relative directory.
5051   cp "$am_depcomp" conftest.dir
5052   cd conftest.dir
5053   # We will build objects and dependencies in a subdirectory because
5054   # it helps to detect inapplicable dependency modes.  For instance
5055   # both Tru64's cc and ICC support -MD to output dependencies as a
5056   # side effect of compilation, but ICC will put the dependencies in
5057   # the current directory while Tru64 will put them in the object
5058   # directory.
5059   mkdir sub
5060
5061   am_cv_CC_dependencies_compiler_type=none
5062   if test "$am_compiler_list" = ""; then
5063      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5064   fi
5065   for depmode in $am_compiler_list; do
5066     # Setup a source with many dependencies, because some compilers
5067     # like to wrap large dependency lists on column 80 (with \), and
5068     # we should not choose a depcomp mode which is confused by this.
5069     #
5070     # We need to recreate these files for each test, as the compiler may
5071     # overwrite some of them when testing with obscure command lines.
5072     # This happens at least with the AIX C compiler.
5073     : > sub/conftest.c
5074     for i in 1 2 3 4 5 6; do
5075       echo '#include "conftst'$i'.h"' >> sub/conftest.c
5076       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5077       # Solaris 8's {/usr,}/bin/sh.
5078       touch sub/conftst$i.h
5079     done
5080     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5081
5082     case $depmode in
5083     nosideeffect)
5084       # after this tag, mechanisms are not by side-effect, so they'll
5085       # only be used when explicitly requested
5086       if test "x$enable_dependency_tracking" = xyes; then
5087         continue
5088       else
5089         break
5090       fi
5091       ;;
5092     none) break ;;
5093     esac
5094     # We check with `-c' and `-o' for the sake of the "dashmstdout"
5095     # mode.  It turns out that the SunPro C++ compiler does not properly
5096     # handle `-M -o', and we need to detect this.
5097     if depmode=$depmode \
5098        source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
5099        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5100        $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
5101          >/dev/null 2>conftest.err &&
5102        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5103        grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
5104        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5105       # icc doesn't choke on unknown options, it will just issue warnings
5106       # or remarks (even with -Werror).  So we grep stderr for any message
5107       # that says an option was ignored or not supported.
5108       # When given -MP, icc 7.0 and 7.1 complain thusly:
5109       #   icc: Command line warning: ignoring option '-M'; no argument required
5110       # The diagnosis changed in icc 8.0:
5111       #   icc: Command line remark: option '-MP' not supported
5112       if (grep 'ignoring option' conftest.err ||
5113           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5114         am_cv_CC_dependencies_compiler_type=$depmode
5115         break
5116       fi
5117     fi
5118   done
5119
5120   cd ..
5121   rm -rf conftest.dir
5122 else
5123   am_cv_CC_dependencies_compiler_type=none
5124 fi
5125
5126 fi
5127 echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
5128 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6
5129 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5130
5131
5132
5133 if
5134   test "x$enable_dependency_tracking" != xno \
5135   && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5136   am__fastdepCC_TRUE=
5137   am__fastdepCC_FALSE='#'
5138 else
5139   am__fastdepCC_TRUE='#'
5140   am__fastdepCC_FALSE=
5141 fi
5142
5143
5144 echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5
5145 echo $ECHO_N "checking for a sed that does not truncate output... $ECHO_C" >&6
5146 if test "${lt_cv_path_SED+set}" = set; then
5147   echo $ECHO_N "(cached) $ECHO_C" >&6
5148 else
5149   # Loop through the user's path and test for sed and gsed.
5150 # Then use that list of sed's as ones to test for truncation.
5151 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5152 for as_dir in $PATH
5153 do
5154   IFS=$as_save_IFS
5155   test -z "$as_dir" && as_dir=.
5156   for lt_ac_prog in sed gsed; do
5157     for ac_exec_ext in '' $ac_executable_extensions; do
5158       if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
5159         lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
5160       fi
5161     done
5162   done
5163 done
5164 lt_ac_max=0
5165 lt_ac_count=0
5166 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
5167 # along with /bin/sed that truncates output.
5168 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
5169   test ! -f $lt_ac_sed && continue
5170   cat /dev/null > conftest.in
5171   lt_ac_count=0
5172   echo $ECHO_N "0123456789$ECHO_C" >conftest.in
5173   # Check for GNU sed and select it if it is found.
5174   if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
5175     lt_cv_path_SED=$lt_ac_sed
5176     break
5177   fi
5178   while true; do
5179     cat conftest.in conftest.in >conftest.tmp
5180     mv conftest.tmp conftest.in
5181     cp conftest.in conftest.nl
5182     echo >>conftest.nl
5183     $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
5184     cmp -s conftest.out conftest.nl || break
5185     # 10000 chars as input seems more than enough
5186     test $lt_ac_count -gt 10 && break
5187     lt_ac_count=`expr $lt_ac_count + 1`
5188     if test $lt_ac_count -gt $lt_ac_max; then
5189       lt_ac_max=$lt_ac_count
5190       lt_cv_path_SED=$lt_ac_sed
5191     fi
5192   done
5193 done
5194
5195 fi
5196
5197 SED=$lt_cv_path_SED
5198 echo "$as_me:$LINENO: result: $SED" >&5
5199 echo "${ECHO_T}$SED" >&6
5200
5201 echo "$as_me:$LINENO: checking for egrep" >&5
5202 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
5203 if test "${ac_cv_prog_egrep+set}" = set; then
5204   echo $ECHO_N "(cached) $ECHO_C" >&6
5205 else
5206   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
5207     then ac_cv_prog_egrep='grep -E'
5208     else ac_cv_prog_egrep='egrep'
5209     fi
5210 fi
5211 echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
5212 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
5213  EGREP=$ac_cv_prog_egrep
5214
5215
5216
5217 # Check whether --with-gnu-ld or --without-gnu-ld was given.
5218 if test "${with_gnu_ld+set}" = set; then
5219   withval="$with_gnu_ld"
5220   test "$withval" = no || with_gnu_ld=yes
5221 else
5222   with_gnu_ld=no
5223 fi;
5224 ac_prog=ld
5225 if test "$GCC" = yes; then
5226   # Check if gcc -print-prog-name=ld gives a path.
5227   echo "$as_me:$LINENO: checking for ld used by $CC" >&5
5228 echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6
5229   case $host in
5230   *-*-mingw*)
5231     # gcc leaves a trailing carriage return which upsets mingw
5232     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
5233   *)
5234     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
5235   esac
5236   case $ac_prog in
5237     # Accept absolute paths.
5238     [\\/]* | ?:[\\/]*)
5239       re_direlt='/[^/][^/]*/\.\./'
5240       # Canonicalize the pathname of ld
5241       ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
5242       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
5243         ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
5244       done
5245       test -z "$LD" && LD="$ac_prog"
5246       ;;
5247   "")
5248     # If it fails, then pretend we aren't using GCC.
5249     ac_prog=ld
5250     ;;
5251   *)
5252     # If it is relative, then search for the first ld in PATH.
5253     with_gnu_ld=unknown
5254     ;;
5255   esac
5256 elif test "$with_gnu_ld" = yes; then
5257   echo "$as_me:$LINENO: checking for GNU ld" >&5
5258 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
5259 else
5260   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
5261 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
5262 fi
5263 if test "${lt_cv_path_LD+set}" = set; then
5264   echo $ECHO_N "(cached) $ECHO_C" >&6
5265 else
5266   if test -z "$LD"; then
5267   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
5268   for ac_dir in $PATH; do
5269     IFS="$lt_save_ifs"
5270     test -z "$ac_dir" && ac_dir=.
5271     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
5272       lt_cv_path_LD="$ac_dir/$ac_prog"
5273       # Check to see if the program is GNU ld.  I'd rather use --version,
5274       # but apparently some variants of GNU ld only accept -v.
5275       # Break only if it was the GNU/non-GNU ld that we prefer.
5276       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
5277       *GNU* | *'with BFD'*)
5278         test "$with_gnu_ld" != no && break
5279         ;;
5280       *)
5281         test "$with_gnu_ld" != yes && break
5282         ;;
5283       esac
5284     fi
5285   done
5286   IFS="$lt_save_ifs"
5287 else
5288   lt_cv_path_LD="$LD" # Let the user override the test with a path.
5289 fi
5290 fi
5291
5292 LD="$lt_cv_path_LD"
5293 if test -n "$LD"; then
5294   echo "$as_me:$LINENO: result: $LD" >&5
5295 echo "${ECHO_T}$LD" >&6
5296 else
5297   echo "$as_me:$LINENO: result: no" >&5
5298 echo "${ECHO_T}no" >&6
5299 fi
5300 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
5301 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
5302    { (exit 1); exit 1; }; }
5303 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
5304 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
5305 if test "${lt_cv_prog_gnu_ld+set}" = set; then
5306   echo $ECHO_N "(cached) $ECHO_C" >&6
5307 else
5308   # I'd rather use --version here, but apparently some GNU lds only accept -v.
5309 case `$LD -v 2>&1 </dev/null` in
5310 *GNU* | *'with BFD'*)
5311   lt_cv_prog_gnu_ld=yes
5312   ;;
5313 *)
5314   lt_cv_prog_gnu_ld=no
5315   ;;
5316 esac
5317 fi
5318 echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
5319 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6
5320 with_gnu_ld=$lt_cv_prog_gnu_ld
5321
5322
5323 echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5
5324 echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6
5325 if test "${lt_cv_ld_reload_flag+set}" = set; then
5326   echo $ECHO_N "(cached) $ECHO_C" >&6
5327 else
5328   lt_cv_ld_reload_flag='-r'
5329 fi
5330 echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5
5331 echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6
5332 reload_flag=$lt_cv_ld_reload_flag
5333 case $reload_flag in
5334 "" | " "*) ;;
5335 *) reload_flag=" $reload_flag" ;;
5336 esac
5337 reload_cmds='$LD$reload_flag -o $output$reload_objs'
5338 case $host_os in
5339   darwin*)
5340     if test "$GCC" = yes; then
5341       reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs'
5342     else
5343       reload_cmds='$LD$reload_flag -o $output$reload_objs'
5344     fi
5345     ;;
5346 esac
5347
5348 echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
5349 echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6
5350 if test "${lt_cv_path_NM+set}" = set; then
5351   echo $ECHO_N "(cached) $ECHO_C" >&6
5352 else
5353   if test -n "$NM"; then
5354   # Let the user override the test.
5355   lt_cv_path_NM="$NM"
5356 else
5357   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
5358   for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
5359     IFS="$lt_save_ifs"
5360     test -z "$ac_dir" && ac_dir=.
5361     tmp_nm="$ac_dir/${ac_tool_prefix}nm"
5362     if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
5363       # Check to see if the nm accepts a BSD-compat flag.
5364       # Adding the `sed 1q' prevents false positives on HP-UX, which says:
5365       #   nm: unknown option "B" ignored
5366       # Tru64's nm complains that /dev/null is an invalid object file
5367       case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
5368       */dev/null* | *'Invalid file or object type'*)
5369         lt_cv_path_NM="$tmp_nm -B"
5370         break
5371         ;;
5372       *)
5373         case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
5374         */dev/null*)
5375           lt_cv_path_NM="$tmp_nm -p"
5376           break
5377           ;;
5378         *)
5379           lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
5380           continue # so that we can try to find one that supports BSD flags
5381           ;;
5382         esac
5383       esac
5384     fi
5385   done
5386   IFS="$lt_save_ifs"
5387   test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
5388 fi
5389 fi
5390 echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5
5391 echo "${ECHO_T}$lt_cv_path_NM" >&6
5392 NM="$lt_cv_path_NM"
5393
5394 echo "$as_me:$LINENO: checking whether ln -s works" >&5
5395 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
5396 LN_S=$as_ln_s
5397 if test "$LN_S" = "ln -s"; then
5398   echo "$as_me:$LINENO: result: yes" >&5
5399 echo "${ECHO_T}yes" >&6
5400 else
5401   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
5402 echo "${ECHO_T}no, using $LN_S" >&6
5403 fi
5404
5405 echo "$as_me:$LINENO: checking how to recognise dependent libraries" >&5
5406 echo $ECHO_N "checking how to recognise dependent libraries... $ECHO_C" >&6
5407 if test "${lt_cv_deplibs_check_method+set}" = set; then
5408   echo $ECHO_N "(cached) $ECHO_C" >&6
5409 else
5410   lt_cv_file_magic_cmd='$MAGIC_CMD'
5411 lt_cv_file_magic_test_file=
5412 lt_cv_deplibs_check_method='unknown'
5413 # Need to set the preceding variable on all platforms that support
5414 # interlibrary dependencies.
5415 # 'none' -- dependencies not supported.
5416 # `unknown' -- same as none, but documents that we really don't know.
5417 # 'pass_all' -- all dependencies passed with no checks.
5418 # 'test_compile' -- check by making test program.
5419 # 'file_magic [[regex]]' -- check by looking for files in library path
5420 # which responds to the $file_magic_cmd with a given extended regex.
5421 # If you have `file' or equivalent on your system and you're not sure
5422 # whether `pass_all' will *always* work, you probably want this one.
5423
5424 case $host_os in
5425 aix4* | aix5*)
5426   lt_cv_deplibs_check_method=pass_all
5427   ;;
5428
5429 beos*)
5430   lt_cv_deplibs_check_method=pass_all
5431   ;;
5432
5433 bsdi[45]*)
5434   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
5435   lt_cv_file_magic_cmd='/usr/bin/file -L'
5436   lt_cv_file_magic_test_file=/shlib/libc.so
5437   ;;
5438
5439 cygwin*)
5440   # func_win32_libid is a shell function defined in ltmain.sh
5441   lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
5442   lt_cv_file_magic_cmd='func_win32_libid'
5443   ;;
5444
5445 mingw* | pw32*)
5446   # Base MSYS/MinGW do not provide the 'file' command needed by
5447   # func_win32_libid shell function, so use a weaker test based on 'objdump'.
5448   lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
5449   lt_cv_file_magic_cmd='$OBJDUMP -f'
5450   ;;
5451
5452 darwin* | rhapsody*)
5453   lt_cv_deplibs_check_method=pass_all
5454   ;;
5455
5456 freebsd* | kfreebsd*-gnu | dragonfly*)
5457   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
5458     case $host_cpu in
5459     i*86 )
5460       # Not sure whether the presence of OpenBSD here was a mistake.
5461       # Let's accept both of them until this is cleared up.
5462       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
5463       lt_cv_file_magic_cmd=/usr/bin/file
5464       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
5465       ;;
5466     esac
5467   else
5468     lt_cv_deplibs_check_method=pass_all
5469   fi
5470   ;;
5471
5472 gnu*)
5473   lt_cv_deplibs_check_method=pass_all
5474   ;;
5475
5476 hpux10.20* | hpux11*)
5477   lt_cv_file_magic_cmd=/usr/bin/file
5478   case $host_cpu in
5479   ia64*)
5480     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
5481     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
5482     ;;
5483   hppa*64*)
5484     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]'
5485     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
5486     ;;
5487   *)
5488     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
5489     lt_cv_file_magic_test_file=/usr/lib/libc.sl
5490     ;;
5491   esac
5492   ;;
5493
5494 irix5* | irix6* | nonstopux*)
5495   case $LD in
5496   *-32|*"-32 ") libmagic=32-bit;;
5497   *-n32|*"-n32 ") libmagic=N32;;
5498   *-64|*"-64 ") libmagic=64-bit;;
5499   *) libmagic=never-match;;
5500   esac
5501   lt_cv_deplibs_check_method=pass_all
5502   ;;
5503
5504 # This must be Linux ELF.
5505 linux*)
5506   lt_cv_deplibs_check_method=pass_all
5507   ;;
5508
5509 netbsd*)
5510   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
5511     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5512   else
5513     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
5514   fi
5515   ;;
5516
5517 newos6*)
5518   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
5519   lt_cv_file_magic_cmd=/usr/bin/file
5520   lt_cv_file_magic_test_file=/usr/lib/libnls.so
5521   ;;
5522
5523 nto-qnx*)
5524   lt_cv_deplibs_check_method=unknown
5525   ;;
5526
5527 openbsd*)
5528   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5529     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
5530   else
5531     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5532   fi
5533   ;;
5534
5535 osf3* | osf4* | osf5*)
5536   lt_cv_deplibs_check_method=pass_all
5537   ;;
5538
5539 sco3.2v5*)
5540   lt_cv_deplibs_check_method=pass_all
5541   ;;
5542
5543 solaris*)
5544   lt_cv_deplibs_check_method=pass_all
5545   ;;
5546
5547 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5548   case $host_vendor in
5549   motorola)
5550     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]'
5551     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
5552     ;;
5553   ncr)
5554     lt_cv_deplibs_check_method=pass_all
5555     ;;
5556   sequent)
5557     lt_cv_file_magic_cmd='/bin/file'
5558     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
5559     ;;
5560   sni)
5561     lt_cv_file_magic_cmd='/bin/file'
5562     lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
5563     lt_cv_file_magic_test_file=/lib/libc.so
5564     ;;
5565   siemens)
5566     lt_cv_deplibs_check_method=pass_all
5567     ;;
5568   esac
5569   ;;
5570
5571 sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7* | sysv4*uw2*)
5572   lt_cv_deplibs_check_method=pass_all
5573   ;;
5574 esac
5575
5576 fi
5577 echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5
5578 echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6
5579 file_magic_cmd=$lt_cv_file_magic_cmd
5580 deplibs_check_method=$lt_cv_deplibs_check_method
5581 test -z "$deplibs_check_method" && deplibs_check_method=unknown
5582
5583
5584
5585
5586 # If no C compiler was specified, use CC.
5587 LTCC=${LTCC-"$CC"}
5588
5589 # Allow CC to be a program name with arguments.
5590 compiler=$CC
5591
5592
5593 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
5594 if test "${enable_libtool_lock+set}" = set; then
5595   enableval="$enable_libtool_lock"
5596
5597 fi;
5598 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
5599
5600 # Some flags need to be propagated to the compiler or linker for good
5601 # libtool support.
5602 case $host in
5603 ia64-*-hpux*)
5604   # Find out which ABI we are using.
5605   echo 'int i;' > conftest.$ac_ext
5606   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5607   (eval $ac_compile) 2>&5
5608   ac_status=$?
5609   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5610   (exit $ac_status); }; then
5611     case `/usr/bin/file conftest.$ac_objext` in
5612     *ELF-32*)
5613       HPUX_IA64_MODE="32"
5614       ;;
5615     *ELF-64*)
5616       HPUX_IA64_MODE="64"
5617       ;;
5618     esac
5619   fi
5620   rm -rf conftest*
5621   ;;
5622 *-*-irix6*)
5623   # Find out which ABI we are using.
5624   echo '#line 5624 "configure"' > conftest.$ac_ext
5625   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5626   (eval $ac_compile) 2>&5
5627   ac_status=$?
5628   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5629   (exit $ac_status); }; then
5630    if test "$lt_cv_prog_gnu_ld" = yes; then
5631     case `/usr/bin/file conftest.$ac_objext` in
5632     *32-bit*)
5633       LD="${LD-ld} -melf32bsmip"
5634       ;;
5635     *N32*)
5636       LD="${LD-ld} -melf32bmipn32"
5637       ;;
5638     *64-bit*)
5639       LD="${LD-ld} -melf64bmip"
5640       ;;
5641     esac
5642    else
5643     case `/usr/bin/file conftest.$ac_objext` in
5644     *32-bit*)
5645       LD="${LD-ld} -32"
5646       ;;
5647     *N32*)
5648       LD="${LD-ld} -n32"
5649       ;;
5650     *64-bit*)
5651       LD="${LD-ld} -64"
5652       ;;
5653     esac
5654    fi
5655   fi
5656   rm -rf conftest*
5657   ;;
5658
5659 x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
5660   # Find out which ABI we are using.
5661   echo 'int i;' > conftest.$ac_ext
5662   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5663   (eval $ac_compile) 2>&5
5664   ac_status=$?
5665   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5666   (exit $ac_status); }; then
5667     case `/usr/bin/file conftest.o` in
5668     *32-bit*)
5669       case $host in
5670         x86_64-*linux*)
5671           LD="${LD-ld} -m elf_i386"
5672           ;;
5673         ppc64-*linux*|powerpc64-*linux*)
5674           LD="${LD-ld} -m elf32ppclinux"
5675           ;;
5676         s390x-*linux*)
5677           LD="${LD-ld} -m elf_s390"
5678           ;;
5679         sparc64-*linux*)
5680           LD="${LD-ld} -m elf32_sparc"
5681           ;;
5682       esac
5683       ;;
5684     *64-bit*)
5685       case $host in
5686         x86_64-*linux*)
5687           LD="${LD-ld} -m elf_x86_64"
5688           ;;
5689         ppc*-*linux*|powerpc*-*linux*)
5690           LD="${LD-ld} -m elf64ppc"
5691           ;;
5692         s390*-*linux*)
5693           LD="${LD-ld} -m elf64_s390"
5694           ;;
5695         sparc*-*linux*)
5696           LD="${LD-ld} -m elf64_sparc"
5697           ;;
5698       esac
5699       ;;
5700     esac
5701   fi
5702   rm -rf conftest*
5703   ;;
5704
5705 *-*-sco3.2v5*)
5706   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
5707   SAVE_CFLAGS="$CFLAGS"
5708   CFLAGS="$CFLAGS -belf"
5709   echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5
5710 echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6
5711 if test "${lt_cv_cc_needs_belf+set}" = set; then
5712   echo $ECHO_N "(cached) $ECHO_C" >&6
5713 else
5714   ac_ext=c
5715 ac_cpp='$CPP $CPPFLAGS'
5716 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5717 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5718 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5719
5720      cat >conftest.$ac_ext <<_ACEOF
5721 /* confdefs.h.  */
5722 _ACEOF
5723 cat confdefs.h >>conftest.$ac_ext
5724 cat >>conftest.$ac_ext <<_ACEOF
5725 /* end confdefs.h.  */
5726
5727 int
5728 main ()
5729 {
5730
5731   ;
5732   return 0;
5733 }
5734 _ACEOF
5735 rm -f conftest.$ac_objext conftest$ac_exeext
5736 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5737   (eval $ac_link) 2>conftest.er1
5738   ac_status=$?
5739   grep -v '^ *+' conftest.er1 >conftest.err
5740   rm -f conftest.er1
5741   cat conftest.err >&5
5742   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5743   (exit $ac_status); } &&
5744          { ac_try='test -z "$ac_c_werror_flag"
5745                          || test ! -s conftest.err'
5746   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5747   (eval $ac_try) 2>&5
5748   ac_status=$?
5749   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5750   (exit $ac_status); }; } &&
5751          { ac_try='test -s conftest$ac_exeext'
5752   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5753   (eval $ac_try) 2>&5
5754   ac_status=$?
5755   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5756   (exit $ac_status); }; }; then
5757   lt_cv_cc_needs_belf=yes
5758 else
5759   echo "$as_me: failed program was:" >&5
5760 sed 's/^/| /' conftest.$ac_ext >&5
5761
5762 lt_cv_cc_needs_belf=no
5763 fi
5764 rm -f conftest.err conftest.$ac_objext \
5765       conftest$ac_exeext conftest.$ac_ext
5766      ac_ext=c
5767 ac_cpp='$CPP $CPPFLAGS'
5768 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5769 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5770 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5771
5772 fi
5773 echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5
5774 echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6
5775   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
5776     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
5777     CFLAGS="$SAVE_CFLAGS"
5778   fi
5779   ;;
5780 *-*-cygwin* | *-*-mingw* | *-*-pw32*)
5781   if test -n "$ac_tool_prefix"; then
5782   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
5783 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
5784 echo "$as_me:$LINENO: checking for $ac_word" >&5
5785 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5786 if test "${ac_cv_prog_DLLTOOL+set}" = set; then
5787   echo $ECHO_N "(cached) $ECHO_C" >&6
5788 else
5789   if test -n "$DLLTOOL"; then
5790   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
5791 else
5792 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5793 for as_dir in $PATH
5794 do
5795   IFS=$as_save_IFS
5796   test -z "$as_dir" && as_dir=.
5797   for ac_exec_ext in '' $ac_executable_extensions; do
5798   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5799     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
5800     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5801     break 2
5802   fi
5803 done
5804 done
5805
5806 fi
5807 fi
5808 DLLTOOL=$ac_cv_prog_DLLTOOL
5809 if test -n "$DLLTOOL"; then
5810   echo "$as_me:$LINENO: result: $DLLTOOL" >&5
5811 echo "${ECHO_T}$DLLTOOL" >&6
5812 else
5813   echo "$as_me:$LINENO: result: no" >&5
5814 echo "${ECHO_T}no" >&6
5815 fi
5816
5817 fi
5818 if test -z "$ac_cv_prog_DLLTOOL"; then
5819   ac_ct_DLLTOOL=$DLLTOOL
5820   # Extract the first word of "dlltool", so it can be a program name with args.
5821 set dummy dlltool; ac_word=$2
5822 echo "$as_me:$LINENO: checking for $ac_word" >&5
5823 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5824 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
5825   echo $ECHO_N "(cached) $ECHO_C" >&6
5826 else
5827   if test -n "$ac_ct_DLLTOOL"; then
5828   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
5829 else
5830 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5831 for as_dir in $PATH
5832 do
5833   IFS=$as_save_IFS
5834   test -z "$as_dir" && as_dir=.
5835   for ac_exec_ext in '' $ac_executable_extensions; do
5836   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5837     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
5838     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5839     break 2
5840   fi
5841 done
5842 done
5843
5844   test -z "$ac_cv_prog_ac_ct_DLLTOOL" && ac_cv_prog_ac_ct_DLLTOOL="false"
5845 fi
5846 fi
5847 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
5848 if test -n "$ac_ct_DLLTOOL"; then
5849   echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
5850 echo "${ECHO_T}$ac_ct_DLLTOOL" >&6
5851 else
5852   echo "$as_me:$LINENO: result: no" >&5
5853 echo "${ECHO_T}no" >&6
5854 fi
5855
5856   DLLTOOL=$ac_ct_DLLTOOL
5857 else
5858   DLLTOOL="$ac_cv_prog_DLLTOOL"
5859 fi
5860
5861   if test -n "$ac_tool_prefix"; then
5862   # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
5863 set dummy ${ac_tool_prefix}as; ac_word=$2
5864 echo "$as_me:$LINENO: checking for $ac_word" >&5
5865 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5866 if test "${ac_cv_prog_AS+set}" = set; then
5867   echo $ECHO_N "(cached) $ECHO_C" >&6
5868 else
5869   if test -n "$AS"; then
5870   ac_cv_prog_AS="$AS" # Let the user override the test.
5871 else
5872 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5873 for as_dir in $PATH
5874 do
5875   IFS=$as_save_IFS
5876   test -z "$as_dir" && as_dir=.
5877   for ac_exec_ext in '' $ac_executable_extensions; do
5878   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5879     ac_cv_prog_AS="${ac_tool_prefix}as"
5880     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5881     break 2
5882   fi
5883 done
5884 done
5885
5886 fi
5887 fi
5888 AS=$ac_cv_prog_AS
5889 if test -n "$AS"; then
5890   echo "$as_me:$LINENO: result: $AS" >&5
5891 echo "${ECHO_T}$AS" >&6
5892 else
5893   echo "$as_me:$LINENO: result: no" >&5
5894 echo "${ECHO_T}no" >&6
5895 fi
5896
5897 fi
5898 if test -z "$ac_cv_prog_AS"; then
5899   ac_ct_AS=$AS
5900   # Extract the first word of "as", so it can be a program name with args.
5901 set dummy as; ac_word=$2
5902 echo "$as_me:$LINENO: checking for $ac_word" >&5
5903 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5904 if test "${ac_cv_prog_ac_ct_AS+set}" = set; then
5905   echo $ECHO_N "(cached) $ECHO_C" >&6
5906 else
5907   if test -n "$ac_ct_AS"; then
5908   ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test.
5909 else
5910 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5911 for as_dir in $PATH
5912 do
5913   IFS=$as_save_IFS
5914   test -z "$as_dir" && as_dir=.
5915   for ac_exec_ext in '' $ac_executable_extensions; do
5916   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5917     ac_cv_prog_ac_ct_AS="as"
5918     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5919     break 2
5920   fi
5921 done
5922 done
5923
5924   test -z "$ac_cv_prog_ac_ct_AS" && ac_cv_prog_ac_ct_AS="false"
5925 fi
5926 fi
5927 ac_ct_AS=$ac_cv_prog_ac_ct_AS
5928 if test -n "$ac_ct_AS"; then
5929   echo "$as_me:$LINENO: result: $ac_ct_AS" >&5
5930 echo "${ECHO_T}$ac_ct_AS" >&6
5931 else
5932   echo "$as_me:$LINENO: result: no" >&5
5933 echo "${ECHO_T}no" >&6
5934 fi
5935
5936   AS=$ac_ct_AS
5937 else
5938   AS="$ac_cv_prog_AS"
5939 fi
5940
5941   if test -n "$ac_tool_prefix"; then
5942   # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
5943 set dummy ${ac_tool_prefix}objdump; ac_word=$2
5944 echo "$as_me:$LINENO: checking for $ac_word" >&5
5945 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5946 if test "${ac_cv_prog_OBJDUMP+set}" = set; then
5947   echo $ECHO_N "(cached) $ECHO_C" >&6
5948 else
5949   if test -n "$OBJDUMP"; then
5950   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
5951 else
5952 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5953 for as_dir in $PATH
5954 do
5955   IFS=$as_save_IFS
5956   test -z "$as_dir" && as_dir=.
5957   for ac_exec_ext in '' $ac_executable_extensions; do
5958   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5959     ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
5960     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5961     break 2
5962   fi
5963 done
5964 done
5965
5966 fi
5967 fi
5968 OBJDUMP=$ac_cv_prog_OBJDUMP
5969 if test -n "$OBJDUMP"; then
5970   echo "$as_me:$LINENO: result: $OBJDUMP" >&5
5971 echo "${ECHO_T}$OBJDUMP" >&6
5972 else
5973   echo "$as_me:$LINENO: result: no" >&5
5974 echo "${ECHO_T}no" >&6
5975 fi
5976
5977 fi
5978 if test -z "$ac_cv_prog_OBJDUMP"; then
5979   ac_ct_OBJDUMP=$OBJDUMP
5980   # Extract the first word of "objdump", so it can be a program name with args.
5981 set dummy objdump; ac_word=$2
5982 echo "$as_me:$LINENO: checking for $ac_word" >&5
5983 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5984 if test "${ac_cv_prog_ac_ct_OBJDUMP+set}" = set; then
5985   echo $ECHO_N "(cached) $ECHO_C" >&6
5986 else
5987   if test -n "$ac_ct_OBJDUMP"; then
5988   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
5989 else
5990 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5991 for as_dir in $PATH
5992 do
5993   IFS=$as_save_IFS
5994   test -z "$as_dir" && as_dir=.
5995   for ac_exec_ext in '' $ac_executable_extensions; do
5996   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5997     ac_cv_prog_ac_ct_OBJDUMP="objdump"
5998     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5999     break 2
6000   fi
6001 done
6002 done
6003
6004   test -z "$ac_cv_prog_ac_ct_OBJDUMP" && ac_cv_prog_ac_ct_OBJDUMP="false"
6005 fi
6006 fi
6007 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
6008 if test -n "$ac_ct_OBJDUMP"; then
6009   echo "$as_me:$LINENO: result: $ac_ct_OBJDUMP" >&5
6010 echo "${ECHO_T}$ac_ct_OBJDUMP" >&6
6011 else
6012   echo "$as_me:$LINENO: result: no" >&5
6013 echo "${ECHO_T}no" >&6
6014 fi
6015
6016   OBJDUMP=$ac_ct_OBJDUMP
6017 else
6018   OBJDUMP="$ac_cv_prog_OBJDUMP"
6019 fi
6020
6021   ;;
6022
6023 esac
6024
6025 need_locks="$enable_libtool_lock"
6026
6027
6028 ac_ext=c
6029 ac_cpp='$CPP $CPPFLAGS'
6030 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6031 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6032 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6033 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
6034 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
6035 # On Suns, sometimes $CPP names a directory.
6036 if test -n "$CPP" && test -d "$CPP"; then
6037   CPP=
6038 fi
6039 if test -z "$CPP"; then
6040   if test "${ac_cv_prog_CPP+set}" = set; then
6041   echo $ECHO_N "(cached) $ECHO_C" >&6
6042 else
6043       # Double quotes because CPP needs to be expanded
6044     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6045     do
6046       ac_preproc_ok=false
6047 for ac_c_preproc_warn_flag in '' yes
6048 do
6049   # Use a header file that comes with gcc, so configuring glibc
6050   # with a fresh cross-compiler works.
6051   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6052   # <limits.h> exists even on freestanding compilers.
6053   # On the NeXT, cc -E runs the code through the compiler's parser,
6054   # not just through cpp. "Syntax error" is here to catch this case.
6055   cat >conftest.$ac_ext <<_ACEOF
6056 /* confdefs.h.  */
6057 _ACEOF
6058 cat confdefs.h >>conftest.$ac_ext
6059 cat >>conftest.$ac_ext <<_ACEOF
6060 /* end confdefs.h.  */
6061 #ifdef __STDC__
6062 # include <limits.h>
6063 #else
6064 # include <assert.h>
6065 #endif
6066                      Syntax error
6067 _ACEOF
6068 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6069   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6070   ac_status=$?
6071   grep -v '^ *+' conftest.er1 >conftest.err
6072   rm -f conftest.er1
6073   cat conftest.err >&5
6074   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6075   (exit $ac_status); } >/dev/null; then
6076   if test -s conftest.err; then
6077     ac_cpp_err=$ac_c_preproc_warn_flag
6078     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6079   else
6080     ac_cpp_err=
6081   fi
6082 else
6083   ac_cpp_err=yes
6084 fi
6085 if test -z "$ac_cpp_err"; then
6086   :
6087 else
6088   echo "$as_me: failed program was:" >&5
6089 sed 's/^/| /' conftest.$ac_ext >&5
6090
6091   # Broken: fails on valid input.
6092 continue
6093 fi
6094 rm -f conftest.err conftest.$ac_ext
6095
6096   # OK, works on sane cases.  Now check whether non-existent headers
6097   # can be detected and how.
6098   cat >conftest.$ac_ext <<_ACEOF
6099 /* confdefs.h.  */
6100 _ACEOF
6101 cat confdefs.h >>conftest.$ac_ext
6102 cat >>conftest.$ac_ext <<_ACEOF
6103 /* end confdefs.h.  */
6104 #include <ac_nonexistent.h>
6105 _ACEOF
6106 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6107   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6108   ac_status=$?
6109   grep -v '^ *+' conftest.er1 >conftest.err
6110   rm -f conftest.er1
6111   cat conftest.err >&5
6112   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6113   (exit $ac_status); } >/dev/null; then
6114   if test -s conftest.err; then
6115     ac_cpp_err=$ac_c_preproc_warn_flag
6116     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6117   else
6118     ac_cpp_err=
6119   fi
6120 else
6121   ac_cpp_err=yes
6122 fi
6123 if test -z "$ac_cpp_err"; then
6124   # Broken: success on invalid input.
6125 continue
6126 else
6127   echo "$as_me: failed program was:" >&5
6128 sed 's/^/| /' conftest.$ac_ext >&5
6129
6130   # Passes both tests.
6131 ac_preproc_ok=:
6132 break
6133 fi
6134 rm -f conftest.err conftest.$ac_ext
6135
6136 done
6137 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6138 rm -f conftest.err conftest.$ac_ext
6139 if $ac_preproc_ok; then
6140   break
6141 fi
6142
6143     done
6144     ac_cv_prog_CPP=$CPP
6145
6146 fi
6147   CPP=$ac_cv_prog_CPP
6148 else
6149   ac_cv_prog_CPP=$CPP
6150 fi
6151 echo "$as_me:$LINENO: result: $CPP" >&5
6152 echo "${ECHO_T}$CPP" >&6
6153 ac_preproc_ok=false
6154 for ac_c_preproc_warn_flag in '' yes
6155 do
6156   # Use a header file that comes with gcc, so configuring glibc
6157   # with a fresh cross-compiler works.
6158   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6159   # <limits.h> exists even on freestanding compilers.
6160   # On the NeXT, cc -E runs the code through the compiler's parser,
6161   # not just through cpp. "Syntax error" is here to catch this case.
6162   cat >conftest.$ac_ext <<_ACEOF
6163 /* confdefs.h.  */
6164 _ACEOF
6165 cat confdefs.h >>conftest.$ac_ext
6166 cat >>conftest.$ac_ext <<_ACEOF
6167 /* end confdefs.h.  */
6168 #ifdef __STDC__
6169 # include <limits.h>
6170 #else
6171 # include <assert.h>
6172 #endif
6173                      Syntax error
6174 _ACEOF
6175 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6176   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6177   ac_status=$?
6178   grep -v '^ *+' conftest.er1 >conftest.err
6179   rm -f conftest.er1
6180   cat conftest.err >&5
6181   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6182   (exit $ac_status); } >/dev/null; then
6183   if test -s conftest.err; then
6184     ac_cpp_err=$ac_c_preproc_warn_flag
6185     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6186   else
6187     ac_cpp_err=
6188   fi
6189 else
6190   ac_cpp_err=yes
6191 fi
6192 if test -z "$ac_cpp_err"; then
6193   :
6194 else
6195   echo "$as_me: failed program was:" >&5
6196 sed 's/^/| /' conftest.$ac_ext >&5
6197
6198   # Broken: fails on valid input.
6199 continue
6200 fi
6201 rm -f conftest.err conftest.$ac_ext
6202
6203   # OK, works on sane cases.  Now check whether non-existent headers
6204   # can be detected and how.
6205   cat >conftest.$ac_ext <<_ACEOF
6206 /* confdefs.h.  */
6207 _ACEOF
6208 cat confdefs.h >>conftest.$ac_ext
6209 cat >>conftest.$ac_ext <<_ACEOF
6210 /* end confdefs.h.  */
6211 #include <ac_nonexistent.h>
6212 _ACEOF
6213 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6214   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6215   ac_status=$?
6216   grep -v '^ *+' conftest.er1 >conftest.err
6217   rm -f conftest.er1
6218   cat conftest.err >&5
6219   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6220   (exit $ac_status); } >/dev/null; then
6221   if test -s conftest.err; then
6222     ac_cpp_err=$ac_c_preproc_warn_flag
6223     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6224   else
6225     ac_cpp_err=
6226   fi
6227 else
6228   ac_cpp_err=yes
6229 fi
6230 if test -z "$ac_cpp_err"; then
6231   # Broken: success on invalid input.
6232 continue
6233 else
6234   echo "$as_me: failed program was:" >&5
6235 sed 's/^/| /' conftest.$ac_ext >&5
6236
6237   # Passes both tests.
6238 ac_preproc_ok=:
6239 break
6240 fi
6241 rm -f conftest.err conftest.$ac_ext
6242
6243 done
6244 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6245 rm -f conftest.err conftest.$ac_ext
6246 if $ac_preproc_ok; then
6247   :
6248 else
6249   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
6250 See \`config.log' for more details." >&5
6251 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
6252 See \`config.log' for more details." >&2;}
6253    { (exit 1); exit 1; }; }
6254 fi
6255
6256 ac_ext=c
6257 ac_cpp='$CPP $CPPFLAGS'
6258 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6259 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6260 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6261
6262
6263 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
6264 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
6265 if test "${ac_cv_header_stdc+set}" = set; then
6266   echo $ECHO_N "(cached) $ECHO_C" >&6
6267 else
6268   cat >conftest.$ac_ext <<_ACEOF
6269 /* confdefs.h.  */
6270 _ACEOF
6271 cat confdefs.h >>conftest.$ac_ext
6272 cat >>conftest.$ac_ext <<_ACEOF
6273 /* end confdefs.h.  */
6274 #include <stdlib.h>
6275 #include <stdarg.h>
6276 #include <string.h>
6277 #include <float.h>
6278
6279 int
6280 main ()
6281 {
6282
6283   ;
6284   return 0;
6285 }
6286 _ACEOF
6287 rm -f conftest.$ac_objext
6288 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6289   (eval $ac_compile) 2>conftest.er1
6290   ac_status=$?
6291   grep -v '^ *+' conftest.er1 >conftest.err
6292   rm -f conftest.er1
6293   cat conftest.err >&5
6294   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6295   (exit $ac_status); } &&
6296          { ac_try='test -z "$ac_c_werror_flag"
6297                          || test ! -s conftest.err'
6298   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6299   (eval $ac_try) 2>&5
6300   ac_status=$?
6301   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6302   (exit $ac_status); }; } &&
6303          { ac_try='test -s conftest.$ac_objext'
6304   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6305   (eval $ac_try) 2>&5
6306   ac_status=$?
6307   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6308   (exit $ac_status); }; }; then
6309   ac_cv_header_stdc=yes
6310 else
6311   echo "$as_me: failed program was:" >&5
6312 sed 's/^/| /' conftest.$ac_ext >&5
6313
6314 ac_cv_header_stdc=no
6315 fi
6316 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6317
6318 if test $ac_cv_header_stdc = yes; then
6319   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6320   cat >conftest.$ac_ext <<_ACEOF
6321 /* confdefs.h.  */
6322 _ACEOF
6323 cat confdefs.h >>conftest.$ac_ext
6324 cat >>conftest.$ac_ext <<_ACEOF
6325 /* end confdefs.h.  */
6326 #include <string.h>
6327
6328 _ACEOF
6329 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6330   $EGREP "memchr" >/dev/null 2>&1; then
6331   :
6332 else
6333   ac_cv_header_stdc=no
6334 fi
6335 rm -f conftest*
6336
6337 fi
6338
6339 if test $ac_cv_header_stdc = yes; then
6340   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6341   cat >conftest.$ac_ext <<_ACEOF
6342 /* confdefs.h.  */
6343 _ACEOF
6344 cat confdefs.h >>conftest.$ac_ext
6345 cat >>conftest.$ac_ext <<_ACEOF
6346 /* end confdefs.h.  */
6347 #include <stdlib.h>
6348
6349 _ACEOF
6350 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6351   $EGREP "free" >/dev/null 2>&1; then
6352   :
6353 else
6354   ac_cv_header_stdc=no
6355 fi
6356 rm -f conftest*
6357
6358 fi
6359
6360 if test $ac_cv_header_stdc = yes; then
6361   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6362   if test "$cross_compiling" = yes; then
6363   :
6364 else
6365   cat >conftest.$ac_ext <<_ACEOF
6366 /* confdefs.h.  */
6367 _ACEOF
6368 cat confdefs.h >>conftest.$ac_ext
6369 cat >>conftest.$ac_ext <<_ACEOF
6370 /* end confdefs.h.  */
6371 #include <ctype.h>
6372 #if ((' ' & 0x0FF) == 0x020)
6373 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6374 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6375 #else
6376 # define ISLOWER(c) \
6377                    (('a' <= (c) && (c) <= 'i') \
6378                      || ('j' <= (c) && (c) <= 'r') \
6379                      || ('s' <= (c) && (c) <= 'z'))
6380 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6381 #endif
6382
6383 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6384 int
6385 main ()
6386 {
6387   int i;
6388   for (i = 0; i < 256; i++)
6389     if (XOR (islower (i), ISLOWER (i))
6390         || toupper (i) != TOUPPER (i))
6391       exit(2);
6392   exit (0);
6393 }
6394 _ACEOF
6395 rm -f conftest$ac_exeext
6396 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6397   (eval $ac_link) 2>&5
6398   ac_status=$?
6399   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6400   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6401   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6402   (eval $ac_try) 2>&5
6403   ac_status=$?
6404   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6405   (exit $ac_status); }; }; then
6406   :
6407 else
6408   echo "$as_me: program exited with status $ac_status" >&5
6409 echo "$as_me: failed program was:" >&5
6410 sed 's/^/| /' conftest.$ac_ext >&5
6411
6412 ( exit $ac_status )
6413 ac_cv_header_stdc=no
6414 fi
6415 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6416 fi
6417 fi
6418 fi
6419 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
6420 echo "${ECHO_T}$ac_cv_header_stdc" >&6
6421 if test $ac_cv_header_stdc = yes; then
6422
6423 cat >>confdefs.h <<\_ACEOF
6424 #define STDC_HEADERS 1
6425 _ACEOF
6426
6427 fi
6428
6429 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6430
6431
6432
6433
6434
6435
6436
6437
6438
6439 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6440                   inttypes.h stdint.h unistd.h
6441 do
6442 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6443 echo "$as_me:$LINENO: checking for $ac_header" >&5
6444 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6445 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6446   echo $ECHO_N "(cached) $ECHO_C" >&6
6447 else
6448   cat >conftest.$ac_ext <<_ACEOF
6449 /* confdefs.h.  */
6450 _ACEOF
6451 cat confdefs.h >>conftest.$ac_ext
6452 cat >>conftest.$ac_ext <<_ACEOF
6453 /* end confdefs.h.  */
6454 $ac_includes_default
6455
6456 #include <$ac_header>
6457 _ACEOF
6458 rm -f conftest.$ac_objext
6459 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6460   (eval $ac_compile) 2>conftest.er1
6461   ac_status=$?
6462   grep -v '^ *+' conftest.er1 >conftest.err
6463   rm -f conftest.er1
6464   cat conftest.err >&5
6465   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6466   (exit $ac_status); } &&
6467          { ac_try='test -z "$ac_c_werror_flag"
6468                          || test ! -s conftest.err'
6469   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6470   (eval $ac_try) 2>&5
6471   ac_status=$?
6472   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6473   (exit $ac_status); }; } &&
6474          { ac_try='test -s conftest.$ac_objext'
6475   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6476   (eval $ac_try) 2>&5
6477   ac_status=$?
6478   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6479   (exit $ac_status); }; }; then
6480   eval "$as_ac_Header=yes"
6481 else
6482   echo "$as_me: failed program was:" >&5
6483 sed 's/^/| /' conftest.$ac_ext >&5
6484
6485 eval "$as_ac_Header=no"
6486 fi
6487 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6488 fi
6489 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6490 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6491 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6492   cat >>confdefs.h <<_ACEOF
6493 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6494 _ACEOF
6495
6496 fi
6497
6498 done
6499
6500
6501
6502 for ac_header in dlfcn.h
6503 do
6504 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6505 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6506   echo "$as_me:$LINENO: checking for $ac_header" >&5
6507 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6508 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6509   echo $ECHO_N "(cached) $ECHO_C" >&6
6510 fi
6511 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6512 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6513 else
6514   # Is the header compilable?
6515 echo "$as_me:$LINENO: checking $ac_header usability" >&5
6516 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
6517 cat >conftest.$ac_ext <<_ACEOF
6518 /* confdefs.h.  */
6519 _ACEOF
6520 cat confdefs.h >>conftest.$ac_ext
6521 cat >>conftest.$ac_ext <<_ACEOF
6522 /* end confdefs.h.  */
6523 $ac_includes_default
6524 #include <$ac_header>
6525 _ACEOF
6526 rm -f conftest.$ac_objext
6527 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6528   (eval $ac_compile) 2>conftest.er1
6529   ac_status=$?
6530   grep -v '^ *+' conftest.er1 >conftest.err
6531   rm -f conftest.er1
6532   cat conftest.err >&5
6533   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6534   (exit $ac_status); } &&
6535          { ac_try='test -z "$ac_c_werror_flag"
6536                          || test ! -s conftest.err'
6537   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6538   (eval $ac_try) 2>&5
6539   ac_status=$?
6540   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6541   (exit $ac_status); }; } &&
6542          { ac_try='test -s conftest.$ac_objext'
6543   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6544   (eval $ac_try) 2>&5
6545   ac_status=$?
6546   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6547   (exit $ac_status); }; }; then
6548   ac_header_compiler=yes
6549 else
6550   echo "$as_me: failed program was:" >&5
6551 sed 's/^/| /' conftest.$ac_ext >&5
6552
6553 ac_header_compiler=no
6554 fi
6555 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6556 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6557 echo "${ECHO_T}$ac_header_compiler" >&6
6558
6559 # Is the header present?
6560 echo "$as_me:$LINENO: checking $ac_header presence" >&5
6561 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
6562 cat >conftest.$ac_ext <<_ACEOF
6563 /* confdefs.h.  */
6564 _ACEOF
6565 cat confdefs.h >>conftest.$ac_ext
6566 cat >>conftest.$ac_ext <<_ACEOF
6567 /* end confdefs.h.  */
6568 #include <$ac_header>
6569 _ACEOF
6570 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6571   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6572   ac_status=$?
6573   grep -v '^ *+' conftest.er1 >conftest.err
6574   rm -f conftest.er1
6575   cat conftest.err >&5
6576   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6577   (exit $ac_status); } >/dev/null; then
6578   if test -s conftest.err; then
6579     ac_cpp_err=$ac_c_preproc_warn_flag
6580     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6581   else
6582     ac_cpp_err=
6583   fi
6584 else
6585   ac_cpp_err=yes
6586 fi
6587 if test -z "$ac_cpp_err"; then
6588   ac_header_preproc=yes
6589 else
6590   echo "$as_me: failed program was:" >&5
6591 sed 's/^/| /' conftest.$ac_ext >&5
6592
6593   ac_header_preproc=no
6594 fi
6595 rm -f conftest.err conftest.$ac_ext
6596 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6597 echo "${ECHO_T}$ac_header_preproc" >&6
6598
6599 # So?  What about this header?
6600 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6601   yes:no: )
6602     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6603 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
6604     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
6605 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
6606     ac_header_preproc=yes
6607     ;;
6608   no:yes:* )
6609     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6610 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
6611     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
6612 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
6613     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
6614 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
6615     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
6616 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
6617     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6618 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
6619     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
6620 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
6621     (
6622       cat <<\_ASBOX
6623 ## --------------------------------------------- ##
6624 ## Report this to <http://www.openldap.org/its/> ##
6625 ## --------------------------------------------- ##
6626 _ASBOX
6627     ) |
6628       sed "s/^/$as_me: WARNING:     /" >&2
6629     ;;
6630 esac
6631 echo "$as_me:$LINENO: checking for $ac_header" >&5
6632 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6633 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6634   echo $ECHO_N "(cached) $ECHO_C" >&6
6635 else
6636   eval "$as_ac_Header=\$ac_header_preproc"
6637 fi
6638 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6639 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6640
6641 fi
6642 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6643   cat >>confdefs.h <<_ACEOF
6644 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6645 _ACEOF
6646
6647 fi
6648
6649 done
6650
6651
6652 # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
6653
6654 # find the maximum length of command line arguments
6655 echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5
6656 echo $ECHO_N "checking the maximum length of command line arguments... $ECHO_C" >&6
6657 if test "${lt_cv_sys_max_cmd_len+set}" = set; then
6658   echo $ECHO_N "(cached) $ECHO_C" >&6
6659 else
6660     i=0
6661   teststring="ABCD"
6662
6663   case $build_os in
6664   msdosdjgpp*)
6665     # On DJGPP, this test can blow up pretty badly due to problems in libc
6666     # (any single argument exceeding 2000 bytes causes a buffer overrun
6667     # during glob expansion).  Even if it were fixed, the result of this
6668     # check would be larger than it should be.
6669     lt_cv_sys_max_cmd_len=12288;    # 12K is about right
6670     ;;
6671
6672   gnu*)
6673     # Under GNU Hurd, this test is not required because there is
6674     # no limit to the length of command line arguments.
6675     # Libtool will interpret -1 as no limit whatsoever
6676     lt_cv_sys_max_cmd_len=-1;
6677     ;;
6678
6679   cygwin* | mingw*)
6680     # On Win9x/ME, this test blows up -- it succeeds, but takes
6681     # about 5 minutes as the teststring grows exponentially.
6682     # Worse, since 9x/ME are not pre-emptively multitasking,
6683     # you end up with a "frozen" computer, even though with patience
6684     # the test eventually succeeds (with a max line length of 256k).
6685     # Instead, let's just punt: use the minimum linelength reported by
6686     # all of the supported platforms: 8192 (on NT/2K/XP).
6687     lt_cv_sys_max_cmd_len=8192;
6688     ;;
6689
6690   amigaos*)
6691     # On AmigaOS with pdksh, this test takes hours, literally.
6692     # So we just punt and use a minimum line length of 8192.
6693     lt_cv_sys_max_cmd_len=8192;
6694     ;;
6695
6696   netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
6697     # This has been around since 386BSD, at least.  Likely further.
6698     if test -x /sbin/sysctl; then
6699       lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
6700     elif test -x /usr/sbin/sysctl; then
6701       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
6702     else
6703       lt_cv_sys_max_cmd_len=65536       # usable default for all BSDs
6704     fi
6705     # And add a safety zone
6706     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
6707     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
6708     ;;
6709   osf*)
6710     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
6711     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
6712     # nice to cause kernel panics so lets avoid the loop below.
6713     # First set a reasonable default.
6714     lt_cv_sys_max_cmd_len=16384
6715     #
6716     if test -x /sbin/sysconfig; then
6717       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
6718         *1*) lt_cv_sys_max_cmd_len=-1 ;;
6719       esac
6720     fi
6721     ;;
6722   *)
6723     # If test is not a shell built-in, we'll probably end up computing a
6724     # maximum length that is only half of the actual maximum length, but
6725     # we can't tell.
6726     SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
6727     while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \
6728                = "XX$teststring") >/dev/null 2>&1 &&
6729             new_result=`expr "X$teststring" : ".*" 2>&1` &&
6730             lt_cv_sys_max_cmd_len=$new_result &&
6731             test $i != 17 # 1/2 MB should be enough
6732     do
6733       i=`expr $i + 1`
6734       teststring=$teststring$teststring
6735     done
6736     teststring=
6737     # Add a significant safety factor because C++ compilers can tack on massive
6738     # amounts of additional arguments before passing them to the linker.
6739     # It appears as though 1/2 is a usable value.
6740     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
6741     ;;
6742   esac
6743
6744 fi
6745
6746 if test -n $lt_cv_sys_max_cmd_len ; then
6747   echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5
6748 echo "${ECHO_T}$lt_cv_sys_max_cmd_len" >&6
6749 else
6750   echo "$as_me:$LINENO: result: none" >&5
6751 echo "${ECHO_T}none" >&6
6752 fi
6753
6754
6755
6756
6757 # Check for command to grab the raw symbol name followed by C symbol from nm.
6758 echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5
6759 echo $ECHO_N "checking command to parse $NM output from $compiler object... $ECHO_C" >&6
6760 if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then
6761   echo $ECHO_N "(cached) $ECHO_C" >&6
6762 else
6763
6764 # These are sane defaults that work on at least a few old systems.
6765 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
6766
6767 # Character class describing NM global symbol codes.
6768 symcode='[BCDEGRST]'
6769
6770 # Regexp to match symbols that can be accessed directly from C.
6771 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
6772
6773 # Transform an extracted symbol line into a proper C declaration
6774 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
6775
6776 # Transform an extracted symbol line into symbol name and symbol address
6777 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'"
6778
6779 # Define system-specific variables.
6780 case $host_os in
6781 aix*)
6782   symcode='[BCDT]'
6783   ;;
6784 cygwin* | mingw* | pw32*)
6785   symcode='[ABCDGISTW]'
6786   ;;
6787 hpux*) # Its linker distinguishes data from code symbols
6788   if test "$host_cpu" = ia64; then
6789     symcode='[ABCDEGRST]'
6790   fi
6791   lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
6792   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'"
6793   ;;
6794 linux*)
6795   if test "$host_cpu" = ia64; then
6796     symcode='[ABCDGIRSTW]'
6797     lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
6798     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'"
6799   fi
6800   ;;
6801 irix* | nonstopux*)
6802   symcode='[BCDEGRST]'
6803   ;;
6804 osf*)
6805   symcode='[BCDEGQRST]'
6806   ;;
6807 solaris* | sysv5*)
6808   symcode='[BDRT]'
6809   ;;
6810 sysv4)
6811   symcode='[DFNSTU]'
6812   ;;
6813 esac
6814
6815 # Handle CRLF in mingw tool chain
6816 opt_cr=
6817 case $build_os in
6818 mingw*)
6819   opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
6820   ;;
6821 esac
6822
6823 # If we're using GNU nm, then use its standard symbol codes.
6824 case `$NM -V 2>&1` in
6825 *GNU* | *'with BFD'*)
6826   symcode='[ABCDGIRSTW]' ;;
6827 esac
6828
6829 # Try without a prefix undercore, then with it.
6830 for ac_symprfx in "" "_"; do
6831
6832   # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
6833   symxfrm="\\1 $ac_symprfx\\2 \\2"
6834
6835   # Write the raw and C identifiers.
6836   lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[       ]\($symcode$symcode*\)[         ][      ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
6837
6838   # Check to see that the pipe works correctly.
6839   pipe_works=no
6840
6841   rm -f conftest*
6842   cat > conftest.$ac_ext <<EOF
6843 #ifdef __cplusplus
6844 extern "C" {
6845 #endif
6846 char nm_test_var;
6847 void nm_test_func(){}
6848 #ifdef __cplusplus
6849 }
6850 #endif
6851 int main(){nm_test_var='a';nm_test_func();return(0);}
6852 EOF
6853
6854   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6855   (eval $ac_compile) 2>&5
6856   ac_status=$?
6857   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6858   (exit $ac_status); }; then
6859     # Now try to grab the symbols.
6860     nlist=conftest.nm
6861     if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5
6862   (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5
6863   ac_status=$?
6864   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6865   (exit $ac_status); } && test -s "$nlist"; then
6866       # Try sorting and uniquifying the output.
6867       if sort "$nlist" | uniq > "$nlist"T; then
6868         mv -f "$nlist"T "$nlist"
6869       else
6870         rm -f "$nlist"T
6871       fi
6872
6873       # Make sure that we snagged all the symbols we need.
6874       if grep ' nm_test_var$' "$nlist" >/dev/null; then
6875         if grep ' nm_test_func$' "$nlist" >/dev/null; then
6876           cat <<EOF > conftest.$ac_ext
6877 #ifdef __cplusplus
6878 extern "C" {
6879 #endif
6880
6881 EOF
6882           # Now generate the symbol file.
6883           eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
6884
6885           cat <<EOF >> conftest.$ac_ext
6886 #if defined (__STDC__) && __STDC__
6887 # define lt_ptr_t void *
6888 #else
6889 # define lt_ptr_t char *
6890 # define const
6891 #endif
6892
6893 /* The mapping between symbol names and symbols. */
6894 const struct {
6895   const char *name;
6896   lt_ptr_t address;
6897 }
6898 lt_preloaded_symbols[] =
6899 {
6900 EOF
6901           $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
6902           cat <<\EOF >> conftest.$ac_ext
6903   {0, (lt_ptr_t) 0}
6904 };
6905
6906 #ifdef __cplusplus
6907 }
6908 #endif
6909 EOF
6910           # Now try linking the two files.
6911           mv conftest.$ac_objext conftstm.$ac_objext
6912           lt_save_LIBS="$LIBS"
6913           lt_save_CFLAGS="$CFLAGS"
6914           LIBS="conftstm.$ac_objext"
6915           CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
6916           if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6917   (eval $ac_link) 2>&5
6918   ac_status=$?
6919   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6920   (exit $ac_status); } && test -s conftest${ac_exeext}; then
6921             pipe_works=yes
6922           fi
6923           LIBS="$lt_save_LIBS"
6924           CFLAGS="$lt_save_CFLAGS"
6925         else
6926           echo "cannot find nm_test_func in $nlist" >&5
6927         fi
6928       else
6929         echo "cannot find nm_test_var in $nlist" >&5
6930       fi
6931     else
6932       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
6933     fi
6934   else
6935     echo "$progname: failed program was:" >&5
6936     cat conftest.$ac_ext >&5
6937   fi
6938   rm -f conftest* conftst*
6939
6940   # Do not use the global_symbol_pipe unless it works.
6941   if test "$pipe_works" = yes; then
6942     break
6943   else
6944     lt_cv_sys_global_symbol_pipe=
6945   fi
6946 done
6947
6948 fi
6949
6950 if test -z "$lt_cv_sys_global_symbol_pipe"; then
6951   lt_cv_sys_global_symbol_to_cdecl=
6952 fi
6953 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
6954   echo "$as_me:$LINENO: result: failed" >&5
6955 echo "${ECHO_T}failed" >&6
6956 else
6957   echo "$as_me:$LINENO: result: ok" >&5
6958 echo "${ECHO_T}ok" >&6
6959 fi
6960
6961 echo "$as_me:$LINENO: checking for objdir" >&5
6962 echo $ECHO_N "checking for objdir... $ECHO_C" >&6
6963 if test "${lt_cv_objdir+set}" = set; then
6964   echo $ECHO_N "(cached) $ECHO_C" >&6
6965 else
6966   rm -f .libs 2>/dev/null
6967 mkdir .libs 2>/dev/null
6968 if test -d .libs; then
6969   lt_cv_objdir=.libs
6970 else
6971   # MS-DOS does not allow filenames that begin with a dot.
6972   lt_cv_objdir=_libs
6973 fi
6974 rmdir .libs 2>/dev/null
6975 fi
6976 echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5
6977 echo "${ECHO_T}$lt_cv_objdir" >&6
6978 objdir=$lt_cv_objdir
6979
6980
6981
6982
6983
6984 case $host_os in
6985 aix3*)
6986   # AIX sometimes has problems with the GCC collect2 program.  For some
6987   # reason, if we set the COLLECT_NAMES environment variable, the problems
6988   # vanish in a puff of smoke.
6989   if test "X${COLLECT_NAMES+set}" != Xset; then
6990     COLLECT_NAMES=
6991     export COLLECT_NAMES
6992   fi
6993   ;;
6994 esac
6995
6996 # Sed substitution that helps us do robust quoting.  It backslashifies
6997 # metacharacters that are still active within double-quoted strings.
6998 Xsed='sed -e 1s/^X//'
6999 sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'
7000
7001 # Same as above, but do not quote variable references.
7002 double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'
7003
7004 # Sed substitution to delay expansion of an escaped shell variable in a
7005 # double_quote_subst'ed string.
7006 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
7007
7008 # Sed substitution to avoid accidental globbing in evaled expressions
7009 no_glob_subst='s/\*/\\\*/g'
7010
7011 # Constants:
7012 rm="rm -f"
7013
7014 # Global variables:
7015 default_ofile=libtool
7016 can_build_shared=yes
7017
7018 # All known linkers require a `.a' archive for static linking (except MSVC,
7019 # which needs '.lib').
7020 libext=a
7021 ltmain="$ac_aux_dir/ltmain.sh"
7022 ofile="$default_ofile"
7023 with_gnu_ld="$lt_cv_prog_gnu_ld"
7024
7025 if test -n "$ac_tool_prefix"; then
7026   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
7027 set dummy ${ac_tool_prefix}ar; ac_word=$2
7028 echo "$as_me:$LINENO: checking for $ac_word" >&5
7029 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7030 if test "${ac_cv_prog_AR+set}" = set; then
7031   echo $ECHO_N "(cached) $ECHO_C" >&6
7032 else
7033   if test -n "$AR"; then
7034   ac_cv_prog_AR="$AR" # Let the user override the test.
7035 else
7036 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7037 for as_dir in $PATH
7038 do
7039   IFS=$as_save_IFS
7040   test -z "$as_dir" && as_dir=.
7041   for ac_exec_ext in '' $ac_executable_extensions; do
7042   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7043     ac_cv_prog_AR="${ac_tool_prefix}ar"
7044     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7045     break 2
7046   fi
7047 done
7048 done
7049
7050 fi
7051 fi
7052 AR=$ac_cv_prog_AR
7053 if test -n "$AR"; then
7054   echo "$as_me:$LINENO: result: $AR" >&5
7055 echo "${ECHO_T}$AR" >&6
7056 else
7057   echo "$as_me:$LINENO: result: no" >&5
7058 echo "${ECHO_T}no" >&6
7059 fi
7060
7061 fi
7062 if test -z "$ac_cv_prog_AR"; then
7063   ac_ct_AR=$AR
7064   # Extract the first word of "ar", so it can be a program name with args.
7065 set dummy ar; ac_word=$2
7066 echo "$as_me:$LINENO: checking for $ac_word" >&5
7067 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7068 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
7069   echo $ECHO_N "(cached) $ECHO_C" >&6
7070 else
7071   if test -n "$ac_ct_AR"; then
7072   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
7073 else
7074 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7075 for as_dir in $PATH
7076 do
7077   IFS=$as_save_IFS
7078   test -z "$as_dir" && as_dir=.
7079   for ac_exec_ext in '' $ac_executable_extensions; do
7080   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7081     ac_cv_prog_ac_ct_AR="ar"
7082     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7083     break 2
7084   fi
7085 done
7086 done
7087
7088   test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="false"
7089 fi
7090 fi
7091 ac_ct_AR=$ac_cv_prog_ac_ct_AR
7092 if test -n "$ac_ct_AR"; then
7093   echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
7094 echo "${ECHO_T}$ac_ct_AR" >&6
7095 else
7096   echo "$as_me:$LINENO: result: no" >&5
7097 echo "${ECHO_T}no" >&6
7098 fi
7099
7100   AR=$ac_ct_AR
7101 else
7102   AR="$ac_cv_prog_AR"
7103 fi
7104
7105 if test -n "$ac_tool_prefix"; then
7106   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
7107 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
7108 echo "$as_me:$LINENO: checking for $ac_word" >&5
7109 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7110 if test "${ac_cv_prog_RANLIB+set}" = set; then
7111   echo $ECHO_N "(cached) $ECHO_C" >&6
7112 else
7113   if test -n "$RANLIB"; then
7114   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
7115 else
7116 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7117 for as_dir in $PATH
7118 do
7119   IFS=$as_save_IFS
7120   test -z "$as_dir" && as_dir=.
7121   for ac_exec_ext in '' $ac_executable_extensions; do
7122   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7123     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
7124     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7125     break 2
7126   fi
7127 done
7128 done
7129
7130 fi
7131 fi
7132 RANLIB=$ac_cv_prog_RANLIB
7133 if test -n "$RANLIB"; then
7134   echo "$as_me:$LINENO: result: $RANLIB" >&5
7135 echo "${ECHO_T}$RANLIB" >&6
7136 else
7137   echo "$as_me:$LINENO: result: no" >&5
7138 echo "${ECHO_T}no" >&6
7139 fi
7140
7141 fi
7142 if test -z "$ac_cv_prog_RANLIB"; then
7143   ac_ct_RANLIB=$RANLIB
7144   # Extract the first word of "ranlib", so it can be a program name with args.
7145 set dummy ranlib; ac_word=$2
7146 echo "$as_me:$LINENO: checking for $ac_word" >&5
7147 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7148 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
7149   echo $ECHO_N "(cached) $ECHO_C" >&6
7150 else
7151   if test -n "$ac_ct_RANLIB"; then
7152   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
7153 else
7154 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7155 for as_dir in $PATH
7156 do
7157   IFS=$as_save_IFS
7158   test -z "$as_dir" && as_dir=.
7159   for ac_exec_ext in '' $ac_executable_extensions; do
7160   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7161     ac_cv_prog_ac_ct_RANLIB="ranlib"
7162     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7163     break 2
7164   fi
7165 done
7166 done
7167
7168   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
7169 fi
7170 fi
7171 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
7172 if test -n "$ac_ct_RANLIB"; then
7173   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
7174 echo "${ECHO_T}$ac_ct_RANLIB" >&6
7175 else
7176   echo "$as_me:$LINENO: result: no" >&5
7177 echo "${ECHO_T}no" >&6
7178 fi
7179
7180   RANLIB=$ac_ct_RANLIB
7181 else
7182   RANLIB="$ac_cv_prog_RANLIB"
7183 fi
7184
7185 if test -n "$ac_tool_prefix"; then
7186   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
7187 set dummy ${ac_tool_prefix}strip; ac_word=$2
7188 echo "$as_me:$LINENO: checking for $ac_word" >&5
7189 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7190 if test "${ac_cv_prog_STRIP+set}" = set; then
7191   echo $ECHO_N "(cached) $ECHO_C" >&6
7192 else
7193   if test -n "$STRIP"; then
7194   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
7195 else
7196 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7197 for as_dir in $PATH
7198 do
7199   IFS=$as_save_IFS
7200   test -z "$as_dir" && as_dir=.
7201   for ac_exec_ext in '' $ac_executable_extensions; do
7202   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7203     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
7204     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7205     break 2
7206   fi
7207 done
7208 done
7209
7210 fi
7211 fi
7212 STRIP=$ac_cv_prog_STRIP
7213 if test -n "$STRIP"; then
7214   echo "$as_me:$LINENO: result: $STRIP" >&5
7215 echo "${ECHO_T}$STRIP" >&6
7216 else
7217   echo "$as_me:$LINENO: result: no" >&5
7218 echo "${ECHO_T}no" >&6
7219 fi
7220
7221 fi
7222 if test -z "$ac_cv_prog_STRIP"; then
7223   ac_ct_STRIP=$STRIP
7224   # Extract the first word of "strip", so it can be a program name with args.
7225 set dummy strip; ac_word=$2
7226 echo "$as_me:$LINENO: checking for $ac_word" >&5
7227 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7228 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
7229   echo $ECHO_N "(cached) $ECHO_C" >&6
7230 else
7231   if test -n "$ac_ct_STRIP"; then
7232   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
7233 else
7234 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7235 for as_dir in $PATH
7236 do
7237   IFS=$as_save_IFS
7238   test -z "$as_dir" && as_dir=.
7239   for ac_exec_ext in '' $ac_executable_extensions; do
7240   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7241     ac_cv_prog_ac_ct_STRIP="strip"
7242     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7243     break 2
7244   fi
7245 done
7246 done
7247
7248   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
7249 fi
7250 fi
7251 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
7252 if test -n "$ac_ct_STRIP"; then
7253   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
7254 echo "${ECHO_T}$ac_ct_STRIP" >&6
7255 else
7256   echo "$as_me:$LINENO: result: no" >&5
7257 echo "${ECHO_T}no" >&6
7258 fi
7259
7260   STRIP=$ac_ct_STRIP
7261 else
7262   STRIP="$ac_cv_prog_STRIP"
7263 fi
7264
7265
7266 old_CC="$CC"
7267 old_CFLAGS="$CFLAGS"
7268
7269 # Set sane defaults for various variables
7270 test -z "$AR" && AR=ar
7271 test -z "$AR_FLAGS" && AR_FLAGS=cru
7272 test -z "$AS" && AS=as
7273 test -z "$CC" && CC=cc
7274 test -z "$LTCC" && LTCC=$CC
7275 test -z "$DLLTOOL" && DLLTOOL=dlltool
7276 test -z "$LD" && LD=ld
7277 test -z "$LN_S" && LN_S="ln -s"
7278 test -z "$MAGIC_CMD" && MAGIC_CMD=file
7279 test -z "$NM" && NM=nm
7280 test -z "$SED" && SED=sed
7281 test -z "$OBJDUMP" && OBJDUMP=objdump
7282 test -z "$RANLIB" && RANLIB=:
7283 test -z "$STRIP" && STRIP=:
7284 test -z "$ac_objext" && ac_objext=o
7285
7286 # Determine commands to create old-style static archives.
7287 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
7288 old_postinstall_cmds='chmod 644 $oldlib'
7289 old_postuninstall_cmds=
7290
7291 if test -n "$RANLIB"; then
7292   case $host_os in
7293   openbsd*)
7294     old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
7295     ;;
7296   *)
7297     old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
7298     ;;
7299   esac
7300   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
7301 fi
7302
7303 for cc_temp in $compiler""; do
7304   case $cc_temp in
7305     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
7306     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
7307     \-*) ;;
7308     *) break;;
7309   esac
7310 done
7311 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
7312
7313
7314 # Only perform the check for file, if the check method requires it
7315 case $deplibs_check_method in
7316 file_magic*)
7317   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
7318     echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5
7319 echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6
7320 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7321   echo $ECHO_N "(cached) $ECHO_C" >&6
7322 else
7323   case $MAGIC_CMD in
7324 [\\/*] |  ?:[\\/]*)
7325   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7326   ;;
7327 *)
7328   lt_save_MAGIC_CMD="$MAGIC_CMD"
7329   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
7330   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
7331   for ac_dir in $ac_dummy; do
7332     IFS="$lt_save_ifs"
7333     test -z "$ac_dir" && ac_dir=.
7334     if test -f $ac_dir/${ac_tool_prefix}file; then
7335       lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
7336       if test -n "$file_magic_test_file"; then
7337         case $deplibs_check_method in
7338         "file_magic "*)
7339           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
7340           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7341           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7342             $EGREP "$file_magic_regex" > /dev/null; then
7343             :
7344           else
7345             cat <<EOF 1>&2
7346
7347 *** Warning: the command libtool uses to detect shared libraries,
7348 *** $file_magic_cmd, produces output that libtool cannot recognize.
7349 *** The result is that libtool may fail to recognize shared libraries
7350 *** as such.  This will affect the creation of libtool libraries that
7351 *** depend on shared libraries, but programs linked with such libtool
7352 *** libraries will work regardless of this problem.  Nevertheless, you
7353 *** may want to report the problem to your system manager and/or to
7354 *** bug-libtool@gnu.org
7355
7356 EOF
7357           fi ;;
7358         esac
7359       fi
7360       break
7361     fi
7362   done
7363   IFS="$lt_save_ifs"
7364   MAGIC_CMD="$lt_save_MAGIC_CMD"
7365   ;;
7366 esac
7367 fi
7368
7369 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7370 if test -n "$MAGIC_CMD"; then
7371   echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7372 echo "${ECHO_T}$MAGIC_CMD" >&6
7373 else
7374   echo "$as_me:$LINENO: result: no" >&5
7375 echo "${ECHO_T}no" >&6
7376 fi
7377
7378 if test -z "$lt_cv_path_MAGIC_CMD"; then
7379   if test -n "$ac_tool_prefix"; then
7380     echo "$as_me:$LINENO: checking for file" >&5
7381 echo $ECHO_N "checking for file... $ECHO_C" >&6
7382 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7383   echo $ECHO_N "(cached) $ECHO_C" >&6
7384 else
7385   case $MAGIC_CMD in
7386 [\\/*] |  ?:[\\/]*)
7387   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7388   ;;
7389 *)
7390   lt_save_MAGIC_CMD="$MAGIC_CMD"
7391   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
7392   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
7393   for ac_dir in $ac_dummy; do
7394     IFS="$lt_save_ifs"
7395     test -z "$ac_dir" && ac_dir=.
7396     if test -f $ac_dir/file; then
7397       lt_cv_path_MAGIC_CMD="$ac_dir/file"
7398       if test -n "$file_magic_test_file"; then
7399         case $deplibs_check_method in
7400         "file_magic "*)
7401           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
7402           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7403           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7404             $EGREP "$file_magic_regex" > /dev/null; then
7405             :
7406           else
7407             cat <<EOF 1>&2
7408
7409 *** Warning: the command libtool uses to detect shared libraries,
7410 *** $file_magic_cmd, produces output that libtool cannot recognize.
7411 *** The result is that libtool may fail to recognize shared libraries
7412 *** as such.  This will affect the creation of libtool libraries that
7413 *** depend on shared libraries, but programs linked with such libtool
7414 *** libraries will work regardless of this problem.  Nevertheless, you
7415 *** may want to report the problem to your system manager and/or to
7416 *** bug-libtool@gnu.org
7417
7418 EOF
7419           fi ;;
7420         esac
7421       fi
7422       break
7423     fi
7424   done
7425   IFS="$lt_save_ifs"
7426   MAGIC_CMD="$lt_save_MAGIC_CMD"
7427   ;;
7428 esac
7429 fi
7430
7431 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7432 if test -n "$MAGIC_CMD"; then
7433   echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7434 echo "${ECHO_T}$MAGIC_CMD" >&6
7435 else
7436   echo "$as_me:$LINENO: result: no" >&5
7437 echo "${ECHO_T}no" >&6
7438 fi
7439
7440   else
7441     MAGIC_CMD=:
7442   fi
7443 fi
7444
7445   fi
7446   ;;
7447 esac
7448
7449 enable_dlopen=yes
7450 enable_win32_dll=yes
7451
7452 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
7453 if test "${enable_libtool_lock+set}" = set; then
7454   enableval="$enable_libtool_lock"
7455
7456 fi;
7457 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
7458
7459
7460 # Check whether --with-pic or --without-pic was given.
7461 if test "${with_pic+set}" = set; then
7462   withval="$with_pic"
7463   pic_mode="$withval"
7464 else
7465   pic_mode=default
7466 fi;
7467 test -z "$pic_mode" && pic_mode=default
7468
7469 # Use C for the default configuration in the libtool script
7470 tagname=
7471 lt_save_CC="$CC"
7472 ac_ext=c
7473 ac_cpp='$CPP $CPPFLAGS'
7474 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7475 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7476 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7477
7478
7479 # Source file extension for C test sources.
7480 ac_ext=c
7481
7482 # Object file extension for compiled C test sources.
7483 objext=o
7484 objext=$objext
7485
7486 # Code to be used in simple compile tests
7487 lt_simple_compile_test_code="int some_variable = 0;\n"
7488
7489 # Code to be used in simple link tests
7490 lt_simple_link_test_code='int main(){return(0);}\n'
7491
7492
7493 # If no C compiler was specified, use CC.
7494 LTCC=${LTCC-"$CC"}
7495
7496 # Allow CC to be a program name with arguments.
7497 compiler=$CC
7498
7499
7500 # save warnings/boilerplate of simple test code
7501 ac_outfile=conftest.$ac_objext
7502 printf "$lt_simple_compile_test_code" >conftest.$ac_ext
7503 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
7504 _lt_compiler_boilerplate=`cat conftest.err`
7505 $rm conftest*
7506
7507 ac_outfile=conftest.$ac_objext
7508 printf "$lt_simple_link_test_code" >conftest.$ac_ext
7509 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
7510 _lt_linker_boilerplate=`cat conftest.err`
7511 $rm conftest*
7512
7513
7514 #
7515 # Check for any special shared library compilation flags.
7516 #
7517 lt_prog_cc_shlib=
7518 if test "$GCC" = no; then
7519   case $host_os in
7520   sco3.2v5*)
7521     lt_prog_cc_shlib='-belf'
7522     ;;
7523   esac
7524 fi
7525 if test -n "$lt_prog_cc_shlib"; then
7526   { echo "$as_me:$LINENO: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&5
7527 echo "$as_me: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&2;}
7528   if echo "$old_CC $old_CFLAGS " | grep "[      ]$lt_prog_cc_shlib[     ]" >/dev/null; then :
7529   else
7530     { echo "$as_me:$LINENO: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&5
7531 echo "$as_me: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&2;}
7532     lt_cv_prog_cc_can_build_shared=no
7533   fi
7534 fi
7535
7536
7537 #
7538 # Check to make sure the static flag actually works.
7539 #
7540 echo "$as_me:$LINENO: checking if $compiler static flag $lt_prog_compiler_static works" >&5
7541 echo $ECHO_N "checking if $compiler static flag $lt_prog_compiler_static works... $ECHO_C" >&6
7542 if test "${lt_prog_compiler_static_works+set}" = set; then
7543   echo $ECHO_N "(cached) $ECHO_C" >&6
7544 else
7545   lt_prog_compiler_static_works=no
7546    save_LDFLAGS="$LDFLAGS"
7547    LDFLAGS="$LDFLAGS $lt_prog_compiler_static"
7548    printf "$lt_simple_link_test_code" > conftest.$ac_ext
7549    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
7550      # The linker can only warn and ignore the option if not recognized
7551      # So say no if there are warnings
7552      if test -s conftest.err; then
7553        # Append any errors to the config.log.
7554        cat conftest.err 1>&5
7555        $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp
7556        $SED '/^$/d' conftest.err >conftest.er2
7557        if diff conftest.exp conftest.er2 >/dev/null; then
7558          lt_prog_compiler_static_works=yes
7559        fi
7560      else
7561        lt_prog_compiler_static_works=yes
7562      fi
7563    fi
7564    $rm conftest*
7565    LDFLAGS="$save_LDFLAGS"
7566
7567 fi
7568 echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works" >&5
7569 echo "${ECHO_T}$lt_prog_compiler_static_works" >&6
7570
7571 if test x"$lt_prog_compiler_static_works" = xyes; then
7572     :
7573 else
7574     lt_prog_compiler_static=
7575 fi
7576
7577
7578
7579
7580 lt_prog_compiler_no_builtin_flag=
7581
7582 if test "$GCC" = yes; then
7583   lt_prog_compiler_no_builtin_flag=' -fno-builtin'
7584
7585
7586 echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
7587 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6
7588 if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then
7589   echo $ECHO_N "(cached) $ECHO_C" >&6
7590 else
7591   lt_cv_prog_compiler_rtti_exceptions=no
7592   ac_outfile=conftest.$ac_objext
7593    printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7594    lt_compiler_flag="-fno-rtti -fno-exceptions"
7595    # Insert the option either (1) after the last *FLAGS variable, or
7596    # (2) before a word containing "conftest.", or (3) at the end.
7597    # Note that $ac_compile itself does not contain backslashes and begins
7598    # with a dollar sign (not a hyphen), so the echo should work correctly.
7599    # The option is referenced via a variable to avoid confusing sed.
7600    lt_compile=`echo "$ac_compile" | $SED \
7601    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7602    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7603    -e 's:$: $lt_compiler_flag:'`
7604    (eval echo "\"\$as_me:7604: $lt_compile\"" >&5)
7605    (eval "$lt_compile" 2>conftest.err)
7606    ac_status=$?
7607    cat conftest.err >&5
7608    echo "$as_me:7608: \$? = $ac_status" >&5
7609    if (exit $ac_status) && test -s "$ac_outfile"; then
7610      # The compiler can only warn and ignore the option if not recognized
7611      # So say no if there are warnings other than the usual output.
7612      $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
7613      $SED '/^$/d' conftest.err >conftest.er2
7614      if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
7615        lt_cv_prog_compiler_rtti_exceptions=yes
7616      fi
7617    fi
7618    $rm conftest*
7619
7620 fi
7621 echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
7622 echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6
7623
7624 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
7625     lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
7626 else
7627     :
7628 fi
7629
7630 fi
7631
7632 lt_prog_compiler_wl=
7633 lt_prog_compiler_pic=
7634 lt_prog_compiler_static=
7635
7636 echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
7637 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6
7638
7639   if test "$GCC" = yes; then
7640     lt_prog_compiler_wl='-Wl,'
7641     lt_prog_compiler_static='-static'
7642
7643     case $host_os in
7644       aix*)
7645       # All AIX code is PIC.
7646       if test "$host_cpu" = ia64; then
7647         # AIX 5 now supports IA64 processor
7648         lt_prog_compiler_static='-Bstatic'
7649       fi
7650       ;;
7651
7652     amigaos*)
7653       # FIXME: we need at least 68020 code to build shared libraries, but
7654       # adding the `-m68020' flag to GCC prevents building anything better,
7655       # like `-m68040'.
7656       lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
7657       ;;
7658
7659     beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
7660       # PIC is the default for these OSes.
7661       ;;
7662
7663     mingw* | pw32* | os2*)
7664       # This hack is so that the source file can tell whether it is being
7665       # built for inclusion in a dll (and should export symbols for example).
7666       lt_prog_compiler_pic='-DDLL_EXPORT'
7667       ;;
7668
7669     darwin* | rhapsody*)
7670       # PIC is the default on this platform
7671       # Common symbols not allowed in MH_DYLIB files
7672       lt_prog_compiler_pic='-fno-common'
7673       ;;
7674
7675     msdosdjgpp*)
7676       # Just because we use GCC doesn't mean we suddenly get shared libraries
7677       # on systems that don't support them.
7678       lt_prog_compiler_can_build_shared=no
7679       enable_shared=no
7680       ;;
7681
7682     sysv4*MP*)
7683       if test -d /usr/nec; then
7684         lt_prog_compiler_pic=-Kconform_pic
7685       fi
7686       ;;
7687
7688     hpux*)
7689       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
7690       # not for PA HP-UX.
7691       case $host_cpu in
7692       hppa*64*|ia64*)
7693         # +Z the default
7694         ;;
7695       *)
7696         lt_prog_compiler_pic='-fPIC'
7697         ;;
7698       esac
7699       ;;
7700
7701     *)
7702       lt_prog_compiler_pic='-fPIC'
7703       ;;
7704     esac
7705   else
7706     # PORTME Check for flag to pass linker flags through the system compiler.
7707     case $host_os in
7708     aix*)
7709       lt_prog_compiler_wl='-Wl,'
7710       if test "$host_cpu" = ia64; then
7711         # AIX 5 now supports IA64 processor
7712         lt_prog_compiler_static='-Bstatic'
7713       else
7714         lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
7715       fi
7716       ;;
7717       darwin*)
7718         # PIC is the default on this platform
7719         # Common symbols not allowed in MH_DYLIB files
7720        case $cc_basename in
7721          xlc*)
7722          lt_prog_compiler_pic='-qnocommon'
7723          lt_prog_compiler_wl='-Wl,'
7724          ;;
7725        esac
7726        ;;
7727
7728     mingw* | pw32* | os2*)
7729       # This hack is so that the source file can tell whether it is being
7730       # built for inclusion in a dll (and should export symbols for example).
7731       lt_prog_compiler_pic='-DDLL_EXPORT'
7732       ;;
7733
7734     hpux9* | hpux10* | hpux11*)
7735       lt_prog_compiler_wl='-Wl,'
7736       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
7737       # not for PA HP-UX.
7738       case $host_cpu in
7739       hppa*64*|ia64*)
7740         # +Z the default
7741         ;;
7742       *)
7743         lt_prog_compiler_pic='+Z'
7744         ;;
7745       esac
7746       # Is there a better lt_prog_compiler_static that works with the bundled CC?
7747       lt_prog_compiler_static='${wl}-a ${wl}archive'
7748       ;;
7749
7750     irix5* | irix6* | nonstopux*)
7751       lt_prog_compiler_wl='-Wl,'
7752       # PIC (with -KPIC) is the default.
7753       lt_prog_compiler_static='-non_shared'
7754       ;;
7755
7756     newsos6)
7757       lt_prog_compiler_pic='-KPIC'
7758       lt_prog_compiler_static='-Bstatic'
7759       ;;
7760
7761     linux*)
7762       case $cc_basename in
7763       icc* | ecc*)
7764         lt_prog_compiler_wl='-Wl,'
7765         lt_prog_compiler_pic='-KPIC'
7766         lt_prog_compiler_static='-static'
7767         ;;
7768       pgcc* | pgf77* | pgf90* | pgf95*)
7769         # Portland Group compilers (*not* the Pentium gcc compiler,
7770         # which looks to be a dead project)
7771         lt_prog_compiler_wl='-Wl,'
7772         lt_prog_compiler_pic='-fpic'
7773         lt_prog_compiler_static='-Bstatic'
7774         ;;
7775       ccc*)
7776         lt_prog_compiler_wl='-Wl,'
7777         # All Alpha code is PIC.
7778         lt_prog_compiler_static='-non_shared'
7779         ;;
7780       esac
7781       ;;
7782
7783     osf3* | osf4* | osf5*)
7784       lt_prog_compiler_wl='-Wl,'
7785       # All OSF/1 code is PIC.
7786       lt_prog_compiler_static='-non_shared'
7787       ;;
7788
7789     sco3.2v5*)
7790       lt_prog_compiler_pic='-Kpic'
7791       lt_prog_compiler_static='-dn'
7792       ;;
7793
7794     solaris*)
7795       lt_prog_compiler_pic='-KPIC'
7796       lt_prog_compiler_static='-Bstatic'
7797       case $cc_basename in
7798       f77* | f90* | f95*)
7799         lt_prog_compiler_wl='-Qoption ld ';;
7800       *)
7801         lt_prog_compiler_wl='-Wl,';;
7802       esac
7803       ;;
7804
7805     sunos4*)
7806       lt_prog_compiler_wl='-Qoption ld '
7807       lt_prog_compiler_pic='-PIC'
7808       lt_prog_compiler_static='-Bstatic'
7809       ;;
7810
7811     sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
7812       lt_prog_compiler_wl='-Wl,'
7813       lt_prog_compiler_pic='-KPIC'
7814       lt_prog_compiler_static='-Bstatic'
7815       ;;
7816
7817     sysv4*MP*)
7818       if test -d /usr/nec ;then
7819         lt_prog_compiler_pic='-Kconform_pic'
7820         lt_prog_compiler_static='-Bstatic'
7821       fi
7822       ;;
7823
7824     unicos*)
7825       lt_prog_compiler_wl='-Wl,'
7826       lt_prog_compiler_can_build_shared=no
7827       ;;
7828
7829     uts4*)
7830       lt_prog_compiler_pic='-pic'
7831       lt_prog_compiler_static='-Bstatic'
7832       ;;
7833
7834     *)
7835       lt_prog_compiler_can_build_shared=no
7836       ;;
7837     esac
7838   fi
7839
7840 echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5
7841 echo "${ECHO_T}$lt_prog_compiler_pic" >&6
7842
7843 #
7844 # Check to make sure the PIC flag actually works.
7845 #
7846 if test -n "$lt_prog_compiler_pic"; then
7847
7848 echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
7849 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic works... $ECHO_C" >&6
7850 if test "${lt_prog_compiler_pic_works+set}" = set; then
7851   echo $ECHO_N "(cached) $ECHO_C" >&6
7852 else
7853   lt_prog_compiler_pic_works=no
7854   ac_outfile=conftest.$ac_objext
7855    printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7856    lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
7857    # Insert the option either (1) after the last *FLAGS variable, or
7858    # (2) before a word containing "conftest.", or (3) at the end.
7859    # Note that $ac_compile itself does not contain backslashes and begins
7860    # with a dollar sign (not a hyphen), so the echo should work correctly.
7861    # The option is referenced via a variable to avoid confusing sed.
7862    lt_compile=`echo "$ac_compile" | $SED \
7863    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7864    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7865    -e 's:$: $lt_compiler_flag:'`
7866    (eval echo "\"\$as_me:7866: $lt_compile\"" >&5)
7867    (eval "$lt_compile" 2>conftest.err)
7868    ac_status=$?
7869    cat conftest.err >&5
7870    echo "$as_me:7870: \$? = $ac_status" >&5
7871    if (exit $ac_status) && test -s "$ac_outfile"; then
7872      # The compiler can only warn and ignore the option if not recognized
7873      # So say no if there are warnings other than the usual output.
7874      $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
7875      $SED '/^$/d' conftest.err >conftest.er2
7876      if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
7877        lt_prog_compiler_pic_works=yes
7878      fi
7879    fi
7880    $rm conftest*
7881
7882 fi
7883 echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works" >&5
7884 echo "${ECHO_T}$lt_prog_compiler_pic_works" >&6
7885
7886 if test x"$lt_prog_compiler_pic_works" = xyes; then
7887     case $lt_prog_compiler_pic in
7888      "" | " "*) ;;
7889      *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
7890      esac
7891 else
7892     lt_prog_compiler_pic=
7893      lt_prog_compiler_can_build_shared=no
7894 fi
7895
7896 fi
7897 case $host_os in
7898   # For platforms which do not support PIC, -DPIC is meaningless:
7899   *djgpp*)
7900     lt_prog_compiler_pic=
7901     ;;
7902   *)
7903     lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
7904     ;;
7905 esac
7906
7907 echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
7908 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6
7909 if test "${lt_cv_prog_compiler_c_o+set}" = set; then
7910   echo $ECHO_N "(cached) $ECHO_C" >&6
7911 else
7912   lt_cv_prog_compiler_c_o=no
7913    $rm -r conftest 2>/dev/null
7914    mkdir conftest
7915    cd conftest
7916    mkdir out
7917    printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7918
7919    lt_compiler_flag="-o out/conftest2.$ac_objext"
7920    # Insert the option either (1) after the last *FLAGS variable, or
7921    # (2) before a word containing "conftest.", or (3) at the end.
7922    # Note that $ac_compile itself does not contain backslashes and begins
7923    # with a dollar sign (not a hyphen), so the echo should work correctly.
7924    lt_compile=`echo "$ac_compile" | $SED \
7925    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7926    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7927    -e 's:$: $lt_compiler_flag:'`
7928    (eval echo "\"\$as_me:7928: $lt_compile\"" >&5)
7929    (eval "$lt_compile" 2>out/conftest.err)
7930    ac_status=$?
7931    cat out/conftest.err >&5
7932    echo "$as_me:7932: \$? = $ac_status" >&5
7933    if (exit $ac_status) && test -s out/conftest2.$ac_objext
7934    then
7935      # The compiler can only warn and ignore the option if not recognized
7936      # So say no if there are warnings
7937      $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp
7938      $SED '/^$/d' out/conftest.err >out/conftest.er2
7939      if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then
7940        lt_cv_prog_compiler_c_o=yes
7941      fi
7942    fi
7943    chmod u+w . 2>&5
7944    $rm conftest*
7945    # SGI C++ compiler will create directory out/ii_files/ for
7946    # template instantiation
7947    test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
7948    $rm out/* && rmdir out
7949    cd ..
7950    rmdir conftest
7951    $rm conftest*
7952
7953 fi
7954 echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5
7955 echo "${ECHO_T}$lt_cv_prog_compiler_c_o" >&6
7956
7957
7958 hard_links="nottested"
7959 if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
7960   # do not overwrite the value of need_locks provided by the user
7961   echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
7962 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6
7963   hard_links=yes
7964   $rm conftest*
7965   ln conftest.a conftest.b 2>/dev/null && hard_links=no
7966   touch conftest.a
7967   ln conftest.a conftest.b 2>&5 || hard_links=no
7968   ln conftest.a conftest.b 2>/dev/null && hard_links=no
7969   echo "$as_me:$LINENO: result: $hard_links" >&5
7970 echo "${ECHO_T}$hard_links" >&6
7971   if test "$hard_links" = no; then
7972     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
7973 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
7974     need_locks=warn
7975   fi
7976 else
7977   need_locks=no
7978 fi
7979
7980 echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
7981 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6
7982
7983   runpath_var=
7984   allow_undefined_flag=
7985   enable_shared_with_static_runtimes=no
7986   archive_cmds=
7987   archive_expsym_cmds=
7988   old_archive_From_new_cmds=
7989   old_archive_from_expsyms_cmds=
7990   export_dynamic_flag_spec=
7991   whole_archive_flag_spec=
7992   thread_safe_flag_spec=
7993   hardcode_libdir_flag_spec=
7994   hardcode_libdir_flag_spec_ld=
7995   hardcode_libdir_separator=
7996   hardcode_direct=no
7997   hardcode_minus_L=no
7998   hardcode_shlibpath_var=unsupported
7999   link_all_deplibs=unknown
8000   hardcode_automatic=no
8001   module_cmds=
8002   module_expsym_cmds=
8003   always_export_symbols=no
8004   export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
8005   # include_expsyms should be a list of space-separated symbols to be *always*
8006   # included in the symbol list
8007   include_expsyms=
8008   # exclude_expsyms can be an extended regexp of symbols to exclude
8009   # it will be wrapped by ` (' and `)$', so one must not match beginning or
8010   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
8011   # as well as any symbol that contains `d'.
8012   exclude_expsyms="_GLOBAL_OFFSET_TABLE_"
8013   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
8014   # platforms (ab)use it in PIC code, but their linkers get confused if
8015   # the symbol is explicitly referenced.  Since portable code cannot
8016   # rely on this symbol name, it's probably fine to never include it in
8017   # preloaded symbol tables.
8018   extract_expsyms_cmds=
8019   # Just being paranoid about ensuring that cc_basename is set.
8020   for cc_temp in $compiler""; do
8021   case $cc_temp in
8022     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
8023     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
8024     \-*) ;;
8025     *) break;;
8026   esac
8027 done
8028 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
8029
8030   case $host_os in
8031   cygwin* | mingw* | pw32*)
8032     # FIXME: the MSVC++ port hasn't been tested in a loooong time
8033     # When not using gcc, we currently assume that we are using
8034     # Microsoft Visual C++.
8035     if test "$GCC" != yes; then
8036       with_gnu_ld=no
8037     fi
8038     ;;
8039   openbsd*)
8040     with_gnu_ld=no
8041     ;;
8042   esac
8043
8044   ld_shlibs=yes
8045   if test "$with_gnu_ld" = yes; then
8046     # If archive_cmds runs LD, not CC, wlarc should be empty
8047     wlarc='${wl}'
8048
8049     # Set some defaults for GNU ld with shared library support. These
8050     # are reset later if shared libraries are not supported. Putting them
8051     # here allows them to be overridden if necessary.
8052     runpath_var=LD_RUN_PATH
8053     hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir'
8054     export_dynamic_flag_spec='${wl}--export-dynamic'
8055     # ancient GNU ld didn't support --whole-archive et. al.
8056     if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
8057         whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
8058       else
8059         whole_archive_flag_spec=
8060     fi
8061     supports_anon_versioning=no
8062     case `$LD -v 2>/dev/null` in
8063       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
8064       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
8065       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
8066       *\ 2.11.*) ;; # other 2.11 versions
8067       *) supports_anon_versioning=yes ;;
8068     esac
8069
8070     # See if GNU ld supports shared libraries.
8071     case $host_os in
8072     aix3* | aix4* | aix5*)
8073       # On AIX/PPC, the GNU linker is very broken
8074       if test "$host_cpu" != ia64; then
8075         ld_shlibs=no
8076         cat <<EOF 1>&2
8077
8078 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
8079 *** to be unable to reliably create shared libraries on AIX.
8080 *** Therefore, libtool is disabling shared libraries support.  If you
8081 *** really care for shared libraries, you may want to modify your PATH
8082 *** so that a non-GNU linker is found, and then restart.
8083
8084 EOF
8085       fi
8086       ;;
8087
8088     amigaos*)
8089       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)'
8090       hardcode_libdir_flag_spec='-L$libdir'
8091       hardcode_minus_L=yes
8092
8093       # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
8094       # that the semantics of dynamic libraries on AmigaOS, at least up
8095       # to version 4, is to share data among multiple programs linked
8096       # with the same dynamic library.  Since this doesn't match the
8097       # behavior of shared libraries on other platforms, we can't use
8098       # them.
8099       ld_shlibs=no
8100       ;;
8101
8102     beos*)
8103       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8104         allow_undefined_flag=unsupported
8105         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
8106         # support --undefined.  This deserves some investigation.  FIXME
8107         archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8108       else
8109         ld_shlibs=no
8110       fi
8111       ;;
8112
8113     cygwin* | mingw* | pw32*)
8114       # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
8115       # as there is no search path for DLLs.
8116       hardcode_libdir_flag_spec='-L$libdir'
8117       allow_undefined_flag=unsupported
8118       always_export_symbols=no
8119       enable_shared_with_static_runtimes=yes
8120       export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols'
8121
8122       if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
8123         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
8124         # If the export-symbols file already is a .def file (1st line
8125         # is EXPORTS), use it as is; otherwise, prepend...
8126         archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
8127           cp $export_symbols $output_objdir/$soname.def;
8128         else
8129           echo EXPORTS > $output_objdir/$soname.def;
8130           cat $export_symbols >> $output_objdir/$soname.def;
8131         fi~
8132         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000  ${wl}--out-implib,$lib'
8133       else
8134         ld_shlibs=no
8135       fi
8136       ;;
8137
8138     linux*)
8139       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8140         tmp_addflag=
8141         case $cc_basename,$host_cpu in
8142         pgcc*)                          # Portland Group C compiler
8143           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'
8144           tmp_addflag=' $pic_flag'
8145           ;;
8146         pgf77* | pgf90* | pgf95*)       # Portland Group f77 and f90 compilers
8147           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'
8148           tmp_addflag=' $pic_flag -Mnomain' ;;
8149         ecc*,ia64* | icc*,ia64*)                # Intel C compiler on ia64
8150           tmp_addflag=' -i_dynamic' ;;
8151         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
8152           tmp_addflag=' -i_dynamic -nofor_main' ;;
8153         ifc* | ifort*)                  # Intel Fortran compiler
8154           tmp_addflag=' -nofor_main' ;;
8155         esac
8156         archive_cmds='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8157
8158         if test $supports_anon_versioning = yes; then
8159           archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~
8160   cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
8161   $echo "local: *; };" >> $output_objdir/$libname.ver~
8162           $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
8163         fi
8164       else
8165         ld_shlibs=no
8166       fi
8167       ;;
8168
8169     netbsd*)
8170       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
8171         archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
8172         wlarc=
8173       else
8174         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8175         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8176       fi
8177       ;;
8178
8179     solaris* | sysv5*)
8180       if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
8181         ld_shlibs=no
8182         cat <<EOF 1>&2
8183
8184 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
8185 *** create shared libraries on Solaris systems.  Therefore, libtool
8186 *** is disabling shared libraries support.  We urge you to upgrade GNU
8187 *** binutils to release 2.9.1 or newer.  Another option is to modify
8188 *** your PATH or compiler configuration so that the native linker is
8189 *** used, and then restart.
8190
8191 EOF
8192       elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8193         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8194         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8195       else
8196         ld_shlibs=no
8197       fi
8198       ;;
8199
8200     sunos4*)
8201       archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8202       wlarc=
8203       hardcode_direct=yes
8204       hardcode_shlibpath_var=no
8205       ;;
8206
8207     *)
8208       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8209         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8210         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8211       else
8212         ld_shlibs=no
8213       fi
8214       ;;
8215     esac
8216
8217     if test "$ld_shlibs" = no; then
8218       runpath_var=
8219       hardcode_libdir_flag_spec=
8220       export_dynamic_flag_spec=
8221       whole_archive_flag_spec=
8222     fi
8223   else
8224     # PORTME fill in a description of your system's linker (not GNU ld)
8225     case $host_os in
8226     aix3*)
8227       allow_undefined_flag=unsupported
8228       always_export_symbols=yes
8229       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'
8230       # Note: this linker hardcodes the directories in LIBPATH if there
8231       # are no directories specified by -L.
8232       hardcode_minus_L=yes
8233       if test "$GCC" = yes && test -z "$link_static_flag"; then
8234         # Neither direct hardcoding nor static linking is supported with a
8235         # broken collect2.
8236         hardcode_direct=unsupported
8237       fi
8238       ;;
8239
8240     aix4* | aix5*)
8241       if test "$host_cpu" = ia64; then
8242         # On IA64, the linker does run time linking by default, so we don't
8243         # have to do anything special.
8244         aix_use_runtimelinking=no
8245         exp_sym_flag='-Bexport'
8246         no_entry_flag=""
8247       else
8248         # If we're using GNU nm, then we don't want the "-C" option.
8249         # -C means demangle to AIX nm, but means don't demangle with GNU nm
8250         if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
8251           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'
8252         else
8253           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'
8254         fi
8255         aix_use_runtimelinking=no
8256
8257         # Test if we are trying to use run time linking or normal
8258         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
8259         # need to do runtime linking.
8260         case $host_os in aix4.[23]|aix4.[23].*|aix5*)
8261           for ld_flag in $LDFLAGS; do
8262           if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
8263             aix_use_runtimelinking=yes
8264             break
8265           fi
8266           done
8267         esac
8268
8269         exp_sym_flag='-bexport'
8270         no_entry_flag='-bnoentry'
8271       fi
8272
8273       # When large executables or shared objects are built, AIX ld can
8274       # have problems creating the table of contents.  If linking a library
8275       # or program results in "error TOC overflow" add -mminimal-toc to
8276       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
8277       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
8278
8279       archive_cmds=''
8280       hardcode_direct=yes
8281       hardcode_libdir_separator=':'
8282       link_all_deplibs=yes
8283
8284       if test "$GCC" = yes; then
8285         case $host_os in aix4.[012]|aix4.[012].*)
8286         # We only want to do this on AIX 4.2 and lower, the check
8287         # below for broken collect2 doesn't work under 4.3+
8288           collect2name=`${CC} -print-prog-name=collect2`
8289           if test -f "$collect2name" && \
8290            strings "$collect2name" | grep resolve_lib_name >/dev/null
8291           then
8292           # We have reworked collect2
8293           hardcode_direct=yes
8294           else
8295           # We have old collect2
8296           hardcode_direct=unsupported
8297           # It fails to find uninstalled libraries when the uninstalled
8298           # path is not listed in the libpath.  Setting hardcode_minus_L
8299           # to unsupported forces relinking
8300           hardcode_minus_L=yes
8301           hardcode_libdir_flag_spec='-L$libdir'
8302           hardcode_libdir_separator=
8303           fi
8304         esac
8305         shared_flag='-shared'
8306         if test "$aix_use_runtimelinking" = yes; then
8307           shared_flag="$shared_flag "'${wl}-G'
8308         fi
8309       else
8310         # not using gcc
8311         if test "$host_cpu" = ia64; then
8312         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
8313         # chokes on -Wl,-G. The following line is correct:
8314           shared_flag='-G'
8315         else
8316         if test "$aix_use_runtimelinking" = yes; then
8317             shared_flag='${wl}-G'
8318           else
8319             shared_flag='${wl}-bM:SRE'
8320         fi
8321         fi
8322       fi
8323
8324       # It seems that -bexpall does not export symbols beginning with
8325       # underscore (_), so it is better to generate a list of symbols to export.
8326       always_export_symbols=yes
8327       if test "$aix_use_runtimelinking" = yes; then
8328         # Warning - without using the other runtime loading flags (-brtl),
8329         # -berok will link without error, but may produce a broken library.
8330         allow_undefined_flag='-berok'
8331        # Determine the default libpath from the value encoded in an empty executable.
8332        cat >conftest.$ac_ext <<_ACEOF
8333 /* confdefs.h.  */
8334 _ACEOF
8335 cat confdefs.h >>conftest.$ac_ext
8336 cat >>conftest.$ac_ext <<_ACEOF
8337 /* end confdefs.h.  */
8338
8339 int
8340 main ()
8341 {
8342
8343   ;
8344   return 0;
8345 }
8346 _ACEOF
8347 rm -f conftest.$ac_objext conftest$ac_exeext
8348 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8349   (eval $ac_link) 2>conftest.er1
8350   ac_status=$?
8351   grep -v '^ *+' conftest.er1 >conftest.err
8352   rm -f conftest.er1
8353   cat conftest.err >&5
8354   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8355   (exit $ac_status); } &&
8356          { ac_try='test -z "$ac_c_werror_flag"
8357                          || test ! -s conftest.err'
8358   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8359   (eval $ac_try) 2>&5
8360   ac_status=$?
8361   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8362   (exit $ac_status); }; } &&
8363          { ac_try='test -s conftest$ac_exeext'
8364   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8365   (eval $ac_try) 2>&5
8366   ac_status=$?
8367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8368   (exit $ac_status); }; }; then
8369
8370 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
8371 }'`
8372 # Check for a 64-bit object if we didn't find anything.
8373 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; }
8374 }'`; fi
8375 else
8376   echo "$as_me: failed program was:" >&5
8377 sed 's/^/| /' conftest.$ac_ext >&5
8378
8379 fi
8380 rm -f conftest.err conftest.$ac_objext \
8381       conftest$ac_exeext conftest.$ac_ext
8382 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
8383
8384        hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
8385         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"
8386        else
8387         if test "$host_cpu" = ia64; then
8388           hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
8389           allow_undefined_flag="-z nodefs"
8390           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"
8391         else
8392          # Determine the default libpath from the value encoded in an empty executable.
8393          cat >conftest.$ac_ext <<_ACEOF
8394 /* confdefs.h.  */
8395 _ACEOF
8396 cat confdefs.h >>conftest.$ac_ext
8397 cat >>conftest.$ac_ext <<_ACEOF
8398 /* end confdefs.h.  */
8399
8400 int
8401 main ()
8402 {
8403
8404   ;
8405   return 0;
8406 }
8407 _ACEOF
8408 rm -f conftest.$ac_objext conftest$ac_exeext
8409 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8410   (eval $ac_link) 2>conftest.er1
8411   ac_status=$?
8412   grep -v '^ *+' conftest.er1 >conftest.err
8413   rm -f conftest.er1
8414   cat conftest.err >&5
8415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8416   (exit $ac_status); } &&
8417          { ac_try='test -z "$ac_c_werror_flag"
8418                          || test ! -s conftest.err'
8419   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8420   (eval $ac_try) 2>&5
8421   ac_status=$?
8422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8423   (exit $ac_status); }; } &&
8424          { ac_try='test -s conftest$ac_exeext'
8425   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8426   (eval $ac_try) 2>&5
8427   ac_status=$?
8428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8429   (exit $ac_status); }; }; then
8430
8431 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
8432 }'`
8433 # Check for a 64-bit object if we didn't find anything.
8434 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; }
8435 }'`; fi
8436 else
8437   echo "$as_me: failed program was:" >&5
8438 sed 's/^/| /' conftest.$ac_ext >&5
8439
8440 fi
8441 rm -f conftest.err conftest.$ac_objext \
8442       conftest$ac_exeext conftest.$ac_ext
8443 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
8444
8445          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
8446           # Warning - without using the other run time loading flags,
8447           # -berok will link without error, but may produce a broken library.
8448           no_undefined_flag=' ${wl}-bernotok'
8449           allow_undefined_flag=' ${wl}-berok'
8450           # -bexpall does not export symbols beginning with underscore (_)
8451           always_export_symbols=yes
8452           # Exported symbols can be pulled into shared objects from archives
8453           whole_archive_flag_spec=' '
8454           archive_cmds_need_lc=yes
8455           # This is similar to how AIX traditionally builds its shared libraries.
8456           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'
8457         fi
8458       fi
8459       ;;
8460
8461     amigaos*)
8462       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)'
8463       hardcode_libdir_flag_spec='-L$libdir'
8464       hardcode_minus_L=yes
8465       # see comment about different semantics on the GNU ld section
8466       ld_shlibs=no
8467       ;;
8468
8469     bsdi[45]*)
8470       export_dynamic_flag_spec=-rdynamic
8471       ;;
8472
8473     cygwin* | mingw* | pw32*)
8474       # When not using gcc, we currently assume that we are using
8475       # Microsoft Visual C++.
8476       # hardcode_libdir_flag_spec is actually meaningless, as there is
8477       # no search path for DLLs.
8478       hardcode_libdir_flag_spec=' '
8479       allow_undefined_flag=unsupported
8480       # Tell ltmain to make .lib files, not .a files.
8481       libext=lib
8482       # Tell ltmain to make .dll files, not .so files.
8483       shrext_cmds=".dll"
8484       # FIXME: Setting linknames here is a bad hack.
8485       archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
8486       # The linker will automatically build a .lib file if we build a DLL.
8487       old_archive_From_new_cmds='true'
8488       # FIXME: Should let the user specify the lib program.
8489       old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs'
8490       fix_srcfile_path='`cygpath -w "$srcfile"`'
8491       enable_shared_with_static_runtimes=yes
8492       ;;
8493
8494     darwin* | rhapsody*)
8495       case $host_os in
8496         rhapsody* | darwin1.[012])
8497          allow_undefined_flag='${wl}-undefined ${wl}suppress'
8498          ;;
8499        *) # Darwin 1.3 on
8500          if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
8501            allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
8502          else
8503            case ${MACOSX_DEPLOYMENT_TARGET} in
8504              10.[012])
8505                allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
8506                ;;
8507              10.*)
8508                allow_undefined_flag='${wl}-undefined ${wl}dynamic_lookup'
8509                ;;
8510            esac
8511          fi
8512          ;;
8513       esac
8514       archive_cmds_need_lc=no
8515       hardcode_direct=no
8516       hardcode_automatic=yes
8517       hardcode_shlibpath_var=unsupported
8518       whole_archive_flag_spec=''
8519       link_all_deplibs=yes
8520     if test "$GCC" = yes ; then
8521         output_verbose_link_cmd='echo'
8522         archive_cmds='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
8523       module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
8524       # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
8525       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}'
8526       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}'
8527     else
8528       case $cc_basename in
8529         xlc*)
8530          output_verbose_link_cmd='echo'
8531          archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
8532          module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
8533           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
8534          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}'
8535           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}'
8536           ;;
8537        *)
8538          ld_shlibs=no
8539           ;;
8540       esac
8541     fi
8542       ;;
8543
8544     dgux*)
8545       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8546       hardcode_libdir_flag_spec='-L$libdir'
8547       hardcode_shlibpath_var=no
8548       ;;
8549
8550     freebsd1*)
8551       ld_shlibs=no
8552       ;;
8553
8554     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
8555     # support.  Future versions do this automatically, but an explicit c++rt0.o
8556     # does not break anything, and helps significantly (at the cost of a little
8557     # extra space).
8558     freebsd2.2*)
8559       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
8560       hardcode_libdir_flag_spec='-R$libdir'
8561       hardcode_direct=yes
8562       hardcode_shlibpath_var=no
8563       ;;
8564
8565     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
8566     freebsd2*)
8567       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8568       hardcode_direct=yes
8569       hardcode_minus_L=yes
8570       hardcode_shlibpath_var=no
8571       ;;
8572
8573     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
8574     freebsd* | kfreebsd*-gnu | dragonfly*)
8575       archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
8576       hardcode_libdir_flag_spec='-R$libdir'
8577       hardcode_direct=yes
8578       hardcode_shlibpath_var=no
8579       ;;
8580
8581     hpux9*)
8582       if test "$GCC" = yes; then
8583         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'
8584       else
8585         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'
8586       fi
8587       hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8588       hardcode_libdir_separator=:
8589       hardcode_direct=yes
8590
8591       # hardcode_minus_L: Not really in the search PATH,
8592       # but as the default location of the library.
8593       hardcode_minus_L=yes
8594       export_dynamic_flag_spec='${wl}-E'
8595       ;;
8596
8597     hpux10* | hpux11*)
8598       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
8599         case $host_cpu in
8600         hppa*64*|ia64*)
8601           archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8602           ;;
8603         *)
8604           archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
8605           ;;
8606         esac
8607       else
8608         case $host_cpu in
8609         hppa*64*|ia64*)
8610           archive_cmds='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags'
8611           ;;
8612         *)
8613           archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
8614           ;;
8615         esac
8616       fi
8617       if test "$with_gnu_ld" = no; then
8618         case $host_cpu in
8619         hppa*64*)
8620           hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8621           hardcode_libdir_flag_spec_ld='+b $libdir'
8622           hardcode_libdir_separator=:
8623           hardcode_direct=no
8624           hardcode_shlibpath_var=no
8625           ;;
8626         ia64*)
8627           hardcode_libdir_flag_spec='-L$libdir'
8628           hardcode_direct=no
8629           hardcode_shlibpath_var=no
8630
8631           # hardcode_minus_L: Not really in the search PATH,
8632           # but as the default location of the library.
8633           hardcode_minus_L=yes
8634           ;;
8635         *)
8636           hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8637           hardcode_libdir_separator=:
8638           hardcode_direct=yes
8639           export_dynamic_flag_spec='${wl}-E'
8640
8641           # hardcode_minus_L: Not really in the search PATH,
8642           # but as the default location of the library.
8643           hardcode_minus_L=yes
8644           ;;
8645         esac
8646       fi
8647       ;;
8648
8649     irix5* | irix6* | nonstopux*)
8650       if test "$GCC" = yes; then
8651         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'
8652       else
8653         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'
8654         hardcode_libdir_flag_spec_ld='-rpath $libdir'
8655       fi
8656       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8657       hardcode_libdir_separator=:
8658       link_all_deplibs=yes
8659       ;;
8660
8661     netbsd*)
8662       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
8663         archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
8664       else
8665         archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
8666       fi
8667       hardcode_libdir_flag_spec='-R$libdir'
8668       hardcode_direct=yes
8669       hardcode_shlibpath_var=no
8670       ;;
8671
8672     newsos6)
8673       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8674       hardcode_direct=yes
8675       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8676       hardcode_libdir_separator=:
8677       hardcode_shlibpath_var=no
8678       ;;
8679
8680     openbsd*)
8681       hardcode_direct=yes
8682       hardcode_shlibpath_var=no
8683       if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
8684         archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8685         archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
8686         hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8687         export_dynamic_flag_spec='${wl}-E'
8688       else
8689        case $host_os in
8690          openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
8691            archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8692            hardcode_libdir_flag_spec='-R$libdir'
8693            ;;
8694          *)
8695            archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8696            hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8697            ;;
8698        esac
8699       fi
8700       ;;
8701
8702     os2*)
8703       hardcode_libdir_flag_spec='-L$libdir'
8704       hardcode_minus_L=yes
8705       allow_undefined_flag=unsupported
8706       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'
8707       old_archive_From_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
8708       ;;
8709
8710     osf3*)
8711       if test "$GCC" = yes; then
8712         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
8713         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'
8714       else
8715         allow_undefined_flag=' -expect_unresolved \*'
8716         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'
8717       fi
8718       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8719       hardcode_libdir_separator=:
8720       ;;
8721
8722     osf4* | osf5*)      # as osf3* with the addition of -msym flag
8723       if test "$GCC" = yes; then
8724         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
8725         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'
8726         hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8727       else
8728         allow_undefined_flag=' -expect_unresolved \*'
8729         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'
8730         archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
8731         $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'
8732
8733         # Both c and cxx compiler support -rpath directly
8734         hardcode_libdir_flag_spec='-rpath $libdir'
8735       fi
8736       hardcode_libdir_separator=:
8737       ;;
8738
8739     sco3.2v5*)
8740       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8741       hardcode_shlibpath_var=no
8742       export_dynamic_flag_spec='${wl}-Bexport'
8743       runpath_var=LD_RUN_PATH
8744       hardcode_runpath_var=yes
8745       ;;
8746
8747     solaris*)
8748       no_undefined_flag=' -z text'
8749       if test "$GCC" = yes; then
8750         wlarc='${wl}'
8751         archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8752         archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8753           $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
8754       else
8755         wlarc=''
8756         archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
8757         archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8758         $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
8759       fi
8760       hardcode_libdir_flag_spec='-R$libdir'
8761       hardcode_shlibpath_var=no
8762       case $host_os in
8763       solaris2.[0-5] | solaris2.[0-5].*) ;;
8764       *)
8765         # The compiler driver will combine linker options so we
8766         # cannot just pass the convience library names through
8767         # without $wl, iff we do not link with $LD.
8768         # Luckily, gcc supports the same syntax we need for Sun Studio.
8769         # Supported since Solaris 2.6 (maybe 2.5.1?)
8770         case $wlarc in
8771         '')
8772           whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;;
8773         *)
8774           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' ;;
8775         esac ;;
8776       esac
8777       link_all_deplibs=yes
8778       ;;
8779
8780     sunos4*)
8781       if test "x$host_vendor" = xsequent; then
8782         # Use $CC to link under sequent, because it throws in some extra .o
8783         # files that make .init and .fini sections work.
8784         archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
8785       else
8786         archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
8787       fi
8788       hardcode_libdir_flag_spec='-L$libdir'
8789       hardcode_direct=yes
8790       hardcode_minus_L=yes
8791       hardcode_shlibpath_var=no
8792       ;;
8793
8794     sysv4)
8795       case $host_vendor in
8796         sni)
8797           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8798           hardcode_direct=yes # is this really true???
8799         ;;
8800         siemens)
8801           ## LD is ld it makes a PLAMLIB
8802           ## CC just makes a GrossModule.
8803           archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
8804           reload_cmds='$CC -r -o $output$reload_objs'
8805           hardcode_direct=no
8806         ;;
8807         motorola)
8808           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8809           hardcode_direct=no #Motorola manual says yes, but my tests say they lie
8810         ;;
8811       esac
8812       runpath_var='LD_RUN_PATH'
8813       hardcode_shlibpath_var=no
8814       ;;
8815
8816     sysv4.3*)
8817       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8818       hardcode_shlibpath_var=no
8819       export_dynamic_flag_spec='-Bexport'
8820       ;;
8821
8822     sysv4*MP*)
8823       if test -d /usr/nec; then
8824         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8825         hardcode_shlibpath_var=no
8826         runpath_var=LD_RUN_PATH
8827         hardcode_runpath_var=yes
8828         ld_shlibs=yes
8829       fi
8830       ;;
8831
8832     sysv4.2uw2*)
8833       archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
8834       hardcode_direct=yes
8835       hardcode_minus_L=no
8836       hardcode_shlibpath_var=no
8837       hardcode_runpath_var=yes
8838       runpath_var=LD_RUN_PATH
8839       ;;
8840
8841    sysv5OpenUNIX8* | sysv5UnixWare7* |  sysv5uw[78]* | unixware7*)
8842       no_undefined_flag='${wl}-z ${wl}text'
8843       if test "$GCC" = yes; then
8844         archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8845       else
8846         archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8847       fi
8848       runpath_var='LD_RUN_PATH'
8849       hardcode_shlibpath_var=no
8850       ;;
8851
8852     sysv5*)
8853       no_undefined_flag=' -z text'
8854       # $CC -shared without GNU ld will not create a library from C++
8855       # object files and a static libstdc++, better avoid it by now
8856       archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
8857       archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8858                 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
8859       hardcode_libdir_flag_spec=
8860       hardcode_shlibpath_var=no
8861       runpath_var='LD_RUN_PATH'
8862       ;;
8863
8864     uts4*)
8865       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8866       hardcode_libdir_flag_spec='-L$libdir'
8867       hardcode_shlibpath_var=no
8868       ;;
8869
8870     *)
8871       ld_shlibs=no
8872       ;;
8873     esac
8874   fi
8875
8876 echo "$as_me:$LINENO: result: $ld_shlibs" >&5
8877 echo "${ECHO_T}$ld_shlibs" >&6
8878 test "$ld_shlibs" = no && can_build_shared=no
8879
8880 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
8881 if test "$GCC" = yes; then
8882   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
8883 fi
8884
8885 #
8886 # Do we need to explicitly link libc?
8887 #
8888 case "x$archive_cmds_need_lc" in
8889 x|xyes)
8890   # Assume -lc should be added
8891   archive_cmds_need_lc=yes
8892
8893   if test "$enable_shared" = yes && test "$GCC" = yes; then
8894     case $archive_cmds in
8895     *'~'*)
8896       # FIXME: we may have to deal with multi-command sequences.
8897       ;;
8898     '$CC '*)
8899       # Test whether the compiler implicitly links with -lc since on some
8900       # systems, -lgcc has to come before -lc. If gcc already passes -lc
8901       # to ld, don't add -lc before -lgcc.
8902       echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
8903 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6
8904       $rm conftest*
8905       printf "$lt_simple_compile_test_code" > conftest.$ac_ext
8906
8907       if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8908   (eval $ac_compile) 2>&5
8909   ac_status=$?
8910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8911   (exit $ac_status); } 2>conftest.err; then
8912         soname=conftest
8913         lib=conftest
8914         libobjs=conftest.$ac_objext
8915         deplibs=
8916         wl=$lt_prog_compiler_wl
8917         compiler_flags=-v
8918         linker_flags=-v
8919         verstring=
8920         output_objdir=.
8921         libname=conftest
8922         lt_save_allow_undefined_flag=$allow_undefined_flag
8923         allow_undefined_flag=
8924         if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5
8925   (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5
8926   ac_status=$?
8927   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8928   (exit $ac_status); }
8929         then
8930           archive_cmds_need_lc=no
8931         else
8932           archive_cmds_need_lc=yes
8933         fi
8934         allow_undefined_flag=$lt_save_allow_undefined_flag
8935       else
8936         cat conftest.err 1>&5
8937       fi
8938       $rm conftest*
8939       echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5
8940 echo "${ECHO_T}$archive_cmds_need_lc" >&6
8941       ;;
8942     esac
8943   fi
8944   ;;
8945 esac
8946
8947 echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
8948 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6
8949 library_names_spec=
8950 libname_spec='lib$name'
8951 soname_spec=
8952 shrext_cmds=".so"
8953 postinstall_cmds=
8954 postuninstall_cmds=
8955 finish_cmds=
8956 finish_eval=
8957 shlibpath_var=
8958 shlibpath_overrides_runpath=unknown
8959 version_type=none
8960 dynamic_linker="$host_os ld.so"
8961 sys_lib_dlsearch_path_spec="/lib /usr/lib"
8962 if test "$GCC" = yes; then
8963   sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
8964   if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
8965     # if the path contains ";" then we assume it to be the separator
8966     # otherwise default to the standard path separator (i.e. ":") - it is
8967     # assumed that no part of a normal pathname contains ";" but that should
8968     # okay in the real world where ";" in dirpaths is itself problematic.
8969     sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
8970   else
8971     sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
8972   fi
8973 else
8974   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
8975 fi
8976 need_lib_prefix=unknown
8977 hardcode_into_libs=no
8978
8979 # when you set need_version to no, make sure it does not cause -set_version
8980 # flags to be left without arguments
8981 need_version=unknown
8982
8983 case $host_os in
8984 aix3*)
8985   version_type=linux
8986   library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
8987   shlibpath_var=LIBPATH
8988
8989   # AIX 3 has no versioning support, so we append a major version to the name.
8990   soname_spec='${libname}${release}${shared_ext}$major'
8991   ;;
8992
8993 aix4* | aix5*)
8994   version_type=linux
8995   need_lib_prefix=no
8996   need_version=no
8997   hardcode_into_libs=yes
8998   if test "$host_cpu" = ia64; then
8999     # AIX 5 supports IA64
9000     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
9001     shlibpath_var=LD_LIBRARY_PATH
9002   else
9003     # With GCC up to 2.95.x, collect2 would create an import file
9004     # for dependence libraries.  The import file would start with
9005     # the line `#! .'.  This would cause the generated library to
9006     # depend on `.', always an invalid library.  This was fixed in
9007     # development snapshots of GCC prior to 3.0.
9008     case $host_os in
9009       aix4 | aix4.[01] | aix4.[01].*)
9010       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
9011            echo ' yes '
9012            echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
9013         :
9014       else
9015         can_build_shared=no
9016       fi
9017       ;;
9018     esac
9019     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
9020     # soname into executable. Probably we can add versioning support to
9021     # collect2, so additional links can be useful in future.
9022     if test "$aix_use_runtimelinking" = yes; then
9023       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
9024       # instead of lib<name>.a to let people know that these are not
9025       # typical AIX shared libraries.
9026       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9027     else
9028       # We preserve .a as extension for shared libraries through AIX4.2
9029       # and later when we are not doing run time linking.
9030       library_names_spec='${libname}${release}.a $libname.a'
9031       soname_spec='${libname}${release}${shared_ext}$major'
9032     fi
9033     shlibpath_var=LIBPATH
9034   fi
9035   ;;
9036
9037 amigaos*)
9038   library_names_spec='$libname.ixlibrary $libname.a'
9039   # Create ${libname}_ixlibrary.a entries in /sys/libs.
9040   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'
9041   ;;
9042
9043 beos*)
9044   library_names_spec='${libname}${shared_ext}'
9045   dynamic_linker="$host_os ld.so"
9046   shlibpath_var=LIBRARY_PATH
9047   ;;
9048
9049 bsdi[45]*)
9050   version_type=linux
9051   need_version=no
9052   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9053   soname_spec='${libname}${release}${shared_ext}$major'
9054   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
9055   shlibpath_var=LD_LIBRARY_PATH
9056   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
9057   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
9058   # the default ld.so.conf also contains /usr/contrib/lib and
9059   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
9060   # libtool to hard-code these into programs
9061   ;;
9062
9063 cygwin* | mingw* | pw32*)
9064   version_type=windows
9065   shrext_cmds=".dll"
9066   need_version=no
9067   need_lib_prefix=no
9068
9069   case $GCC,$host_os in
9070   yes,cygwin* | yes,mingw* | yes,pw32*)
9071     library_names_spec='$libname.dll.a'
9072     # DLL is installed to $(libdir)/../bin by postinstall_cmds
9073     postinstall_cmds='base_file=`basename \${file}`~
9074       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
9075       dldir=$destdir/`dirname \$dlpath`~
9076       test -d \$dldir || mkdir -p \$dldir~
9077       $install_prog $dir/$dlname \$dldir/$dlname~
9078       chmod a+x \$dldir/$dlname'
9079     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
9080       dlpath=$dir/\$dldll~
9081        $rm \$dlpath'
9082     shlibpath_overrides_runpath=yes
9083
9084     case $host_os in
9085     cygwin*)
9086       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
9087       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9088       sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
9089       ;;
9090     mingw*)
9091       # MinGW DLLs use traditional 'lib' prefix
9092       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9093       sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
9094       if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then
9095         # It is most probably a Windows format PATH printed by
9096         # mingw gcc, but we are running on Cygwin. Gcc prints its search
9097         # path with ; separators, and with drive letters. We can handle the
9098         # drive letters (cygwin fileutils understands them), so leave them,
9099         # especially as we might pass files found there to a mingw objdump,
9100         # which wouldn't understand a cygwinified path. Ahh.
9101         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
9102       else
9103         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
9104       fi
9105       ;;
9106     pw32*)
9107       # pw32 DLLs use 'pw' prefix rather than 'lib'
9108       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9109       ;;
9110     esac
9111     ;;
9112
9113   *)
9114     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
9115     ;;
9116   esac
9117   dynamic_linker='Win32 ld.exe'
9118   # FIXME: first we should search . and the directory the executable is in
9119   shlibpath_var=PATH
9120   ;;
9121
9122 darwin* | rhapsody*)
9123   dynamic_linker="$host_os dyld"
9124   version_type=darwin
9125   need_lib_prefix=no
9126   need_version=no
9127   library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
9128   soname_spec='${libname}${release}${major}$shared_ext'
9129   shlibpath_overrides_runpath=yes
9130   shlibpath_var=DYLD_LIBRARY_PATH
9131   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
9132   # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
9133   if test "$GCC" = yes; then
9134     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"`
9135   else
9136     sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
9137   fi
9138   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
9139   ;;
9140
9141 dgux*)
9142   version_type=linux
9143   need_lib_prefix=no
9144   need_version=no
9145   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
9146   soname_spec='${libname}${release}${shared_ext}$major'
9147   shlibpath_var=LD_LIBRARY_PATH
9148   ;;
9149
9150 freebsd1*)
9151   dynamic_linker=no
9152   ;;
9153
9154 kfreebsd*-gnu)
9155   version_type=linux
9156   need_lib_prefix=no
9157   need_version=no
9158   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9159   soname_spec='${libname}${release}${shared_ext}$major'
9160   shlibpath_var=LD_LIBRARY_PATH
9161   shlibpath_overrides_runpath=no
9162   hardcode_into_libs=yes
9163   dynamic_linker='GNU ld.so'
9164   ;;
9165
9166 freebsd* | dragonfly*)
9167   # DragonFly does not have aout.  When/if they implement a new
9168   # versioning mechanism, adjust this.
9169   if test -x /usr/bin/objformat; then
9170     objformat=`/usr/bin/objformat`
9171   else
9172     case $host_os in
9173     freebsd[123]*) objformat=aout ;;
9174     *) objformat=elf ;;
9175     esac
9176   fi
9177   version_type=freebsd-$objformat
9178   case $version_type in
9179     freebsd-elf*)
9180       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
9181       need_version=no
9182       need_lib_prefix=no
9183       ;;
9184     freebsd-*)
9185       library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
9186       need_version=yes
9187       ;;
9188   esac
9189   shlibpath_var=LD_LIBRARY_PATH
9190   case $host_os in
9191   freebsd2*)
9192     shlibpath_overrides_runpath=yes
9193     ;;
9194   freebsd3.[01]* | freebsdelf3.[01]*)
9195     shlibpath_overrides_runpath=yes
9196     hardcode_into_libs=yes
9197     ;;
9198   *) # from 3.2 on
9199     shlibpath_overrides_runpath=no
9200     hardcode_into_libs=yes
9201     ;;
9202   esac
9203   ;;
9204
9205 gnu*)
9206   version_type=linux
9207   need_lib_prefix=no
9208   need_version=no
9209   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
9210   soname_spec='${libname}${release}${shared_ext}$major'
9211   shlibpath_var=LD_LIBRARY_PATH
9212   hardcode_into_libs=yes
9213   ;;
9214
9215 hpux9* | hpux10* | hpux11*)
9216   # Give a soname corresponding to the major version so that dld.sl refuses to
9217   # link against other versions.
9218   version_type=sunos
9219   need_lib_prefix=no
9220   need_version=no
9221   case $host_cpu in
9222   ia64*)
9223     shrext_cmds='.so'
9224     hardcode_into_libs=yes
9225     dynamic_linker="$host_os dld.so"
9226     shlibpath_var=LD_LIBRARY_PATH
9227     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
9228     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9229     soname_spec='${libname}${release}${shared_ext}$major'
9230     if test "X$HPUX_IA64_MODE" = X32; then
9231       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
9232     else
9233       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
9234     fi
9235     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
9236     ;;
9237    hppa*64*)
9238      shrext_cmds='.sl'
9239      hardcode_into_libs=yes
9240      dynamic_linker="$host_os dld.sl"
9241      shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
9242      shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
9243      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9244      soname_spec='${libname}${release}${shared_ext}$major'
9245      sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
9246      sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
9247      ;;
9248    *)
9249     shrext_cmds='.sl'
9250     dynamic_linker="$host_os dld.sl"
9251     shlibpath_var=SHLIB_PATH
9252     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
9253     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9254     soname_spec='${libname}${release}${shared_ext}$major'
9255     ;;
9256   esac
9257   # HP-UX runs *really* slowly unless shared libraries are mode 555.
9258   postinstall_cmds='chmod 555 $lib'
9259   ;;
9260
9261 irix5* | irix6* | nonstopux*)
9262   case $host_os in
9263     nonstopux*) version_type=nonstopux ;;
9264     *)
9265         if test "$lt_cv_prog_gnu_ld" = yes; then
9266                 version_type=linux
9267         else
9268                 version_type=irix
9269         fi ;;
9270   esac
9271   need_lib_prefix=no
9272   need_version=no
9273   soname_spec='${libname}${release}${shared_ext}$major'
9274   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
9275   case $host_os in
9276   irix5* | nonstopux*)
9277     libsuff= shlibsuff=
9278     ;;
9279   *)
9280     case $LD in # libtool.m4 will add one of these switches to LD
9281     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
9282       libsuff= shlibsuff= libmagic=32-bit;;
9283     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
9284       libsuff=32 shlibsuff=N32 libmagic=N32;;
9285     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
9286       libsuff=64 shlibsuff=64 libmagic=64-bit;;
9287     *) libsuff= shlibsuff= libmagic=never-match;;
9288     esac
9289     ;;
9290   esac
9291   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
9292   shlibpath_overrides_runpath=no
9293   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
9294   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
9295   hardcode_into_libs=yes
9296   ;;
9297
9298 # No shared lib support for Linux oldld, aout, or coff.
9299 linux*oldld* | linux*aout* | linux*coff*)
9300   dynamic_linker=no
9301   ;;
9302
9303 # This must be Linux ELF.
9304 linux*)
9305   version_type=linux
9306   need_lib_prefix=no
9307   need_version=no
9308   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9309   soname_spec='${libname}${release}${shared_ext}$major'
9310   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
9311   shlibpath_var=LD_LIBRARY_PATH
9312   shlibpath_overrides_runpath=no
9313   # This implies no fast_install, which is unacceptable.
9314   # Some rework will be needed to allow for fast_install
9315   # before this can be enabled.
9316   hardcode_into_libs=yes
9317
9318   # Append ld.so.conf contents to the search path
9319   if test -f /etc/ld.so.conf; then
9320     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' ' '`
9321     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
9322   fi
9323
9324   # We used to test for /lib/ld.so.1 and disable shared libraries on
9325   # powerpc, because MkLinux only supported shared libraries with the
9326   # GNU dynamic linker.  Since this was broken with cross compilers,
9327   # most powerpc-linux boxes support dynamic linking these days and
9328   # people can always --disable-shared, the test was removed, and we
9329   # assume the GNU/Linux dynamic linker is in use.
9330   dynamic_linker='GNU/Linux ld.so'
9331   ;;
9332
9333 knetbsd*-gnu)
9334   version_type=linux
9335   need_lib_prefix=no
9336   need_version=no
9337   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9338   soname_spec='${libname}${release}${shared_ext}$major'
9339   shlibpath_var=LD_LIBRARY_PATH
9340   shlibpath_overrides_runpath=no
9341   hardcode_into_libs=yes
9342   dynamic_linker='GNU ld.so'
9343   ;;
9344
9345 netbsd*)
9346   version_type=sunos
9347   need_lib_prefix=no
9348   need_version=no
9349   if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
9350     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9351     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
9352     dynamic_linker='NetBSD (a.out) ld.so'
9353   else
9354     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9355     soname_spec='${libname}${release}${shared_ext}$major'
9356     dynamic_linker='NetBSD ld.elf_so'
9357   fi
9358   shlibpath_var=LD_LIBRARY_PATH
9359   shlibpath_overrides_runpath=yes
9360   hardcode_into_libs=yes
9361   ;;
9362
9363 newsos6)
9364   version_type=linux
9365   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9366   shlibpath_var=LD_LIBRARY_PATH
9367   shlibpath_overrides_runpath=yes
9368   ;;
9369
9370 nto-qnx*)
9371   version_type=linux
9372   need_lib_prefix=no
9373   need_version=no
9374   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9375   soname_spec='${libname}${release}${shared_ext}$major'
9376   shlibpath_var=LD_LIBRARY_PATH
9377   shlibpath_overrides_runpath=yes
9378   ;;
9379
9380 openbsd*)
9381   version_type=sunos
9382   need_lib_prefix=no
9383   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
9384   case $host_os in
9385     openbsd3.3 | openbsd3.3.*) need_version=yes ;;
9386     *)                         need_version=no  ;;
9387   esac
9388   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9389   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
9390   shlibpath_var=LD_LIBRARY_PATH
9391   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
9392     case $host_os in
9393       openbsd2.[89] | openbsd2.[89].*)
9394         shlibpath_overrides_runpath=no
9395         ;;
9396       *)
9397         shlibpath_overrides_runpath=yes
9398         ;;
9399       esac
9400   else
9401     shlibpath_overrides_runpath=yes
9402   fi
9403   ;;
9404
9405 os2*)
9406   libname_spec='$name'
9407   shrext_cmds=".dll"
9408   need_lib_prefix=no
9409   library_names_spec='$libname${shared_ext} $libname.a'
9410   dynamic_linker='OS/2 ld.exe'
9411   shlibpath_var=LIBPATH
9412   ;;
9413
9414 osf3* | osf4* | osf5*)
9415   version_type=osf
9416   need_lib_prefix=no
9417   need_version=no
9418   soname_spec='${libname}${release}${shared_ext}$major'
9419   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9420   shlibpath_var=LD_LIBRARY_PATH
9421   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
9422   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
9423   ;;
9424
9425 sco3.2v5*)
9426   version_type=osf
9427   soname_spec='${libname}${release}${shared_ext}$major'
9428   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9429   shlibpath_var=LD_LIBRARY_PATH
9430   ;;
9431
9432 solaris*)
9433   version_type=linux
9434   need_lib_prefix=no
9435   need_version=no
9436   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9437   soname_spec='${libname}${release}${shared_ext}$major'
9438   shlibpath_var=LD_LIBRARY_PATH
9439   shlibpath_overrides_runpath=yes
9440   hardcode_into_libs=yes
9441   # ldd complains unless libraries are executable
9442   postinstall_cmds='chmod +x $lib'
9443   ;;
9444
9445 sunos4*)
9446   version_type=sunos
9447   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9448   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
9449   shlibpath_var=LD_LIBRARY_PATH
9450   shlibpath_overrides_runpath=yes
9451   if test "$with_gnu_ld" = yes; then
9452     need_lib_prefix=no
9453   fi
9454   need_version=yes
9455   ;;
9456
9457 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
9458   version_type=linux
9459   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9460   soname_spec='${libname}${release}${shared_ext}$major'
9461   shlibpath_var=LD_LIBRARY_PATH
9462   case $host_vendor in
9463     sni)
9464       shlibpath_overrides_runpath=no
9465       need_lib_prefix=no
9466       export_dynamic_flag_spec='${wl}-Blargedynsym'
9467       runpath_var=LD_RUN_PATH
9468       ;;
9469     siemens)
9470       need_lib_prefix=no
9471       ;;
9472     motorola)
9473       need_lib_prefix=no
9474       need_version=no
9475       shlibpath_overrides_runpath=no
9476       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
9477       ;;
9478   esac
9479   ;;
9480
9481 sysv4*MP*)
9482   if test -d /usr/nec ;then
9483     version_type=linux
9484     library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
9485     soname_spec='$libname${shared_ext}.$major'
9486     shlibpath_var=LD_LIBRARY_PATH
9487   fi
9488   ;;
9489
9490 uts4*)
9491   version_type=linux
9492   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9493   soname_spec='${libname}${release}${shared_ext}$major'
9494   shlibpath_var=LD_LIBRARY_PATH
9495   ;;
9496
9497 *)
9498   dynamic_linker=no
9499   ;;
9500 esac
9501 echo "$as_me:$LINENO: result: $dynamic_linker" >&5
9502 echo "${ECHO_T}$dynamic_linker" >&6
9503 test "$dynamic_linker" = no && can_build_shared=no
9504
9505 echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
9506 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6
9507 hardcode_action=
9508 if test -n "$hardcode_libdir_flag_spec" || \
9509    test -n "$runpath_var" || \
9510    test "X$hardcode_automatic" = "Xyes" ; then
9511
9512   # We can hardcode non-existant directories.
9513   if test "$hardcode_direct" != no &&
9514      # If the only mechanism to avoid hardcoding is shlibpath_var, we
9515      # have to relink, otherwise we might link with an installed library
9516      # when we should be linking with a yet-to-be-installed one
9517      ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, )" != no &&
9518      test "$hardcode_minus_L" != no; then
9519     # Linking always hardcodes the temporary library directory.
9520     hardcode_action=relink
9521   else
9522     # We can link without hardcoding, and we can hardcode nonexisting dirs.
9523     hardcode_action=immediate
9524   fi
9525 else
9526   # We cannot hardcode anything, or else we can only hardcode existing
9527   # directories.
9528   hardcode_action=unsupported
9529 fi
9530 echo "$as_me:$LINENO: result: $hardcode_action" >&5
9531 echo "${ECHO_T}$hardcode_action" >&6
9532
9533 if test "$hardcode_action" = relink; then
9534   # Fast installation is not supported
9535   enable_fast_install=no
9536 elif test "$shlibpath_overrides_runpath" = yes ||
9537      test "$enable_shared" = no; then
9538   # Fast installation is not necessary
9539   enable_fast_install=needless
9540 fi
9541
9542 striplib=
9543 old_striplib=
9544 echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5
9545 echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&6
9546 if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
9547   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
9548   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
9549   echo "$as_me:$LINENO: result: yes" >&5
9550 echo "${ECHO_T}yes" >&6
9551 else
9552 # FIXME - insert some real tests, host_os isn't really good enough
9553   case $host_os in
9554    darwin*)
9555        if test -n "$STRIP" ; then
9556          striplib="$STRIP -x"
9557          echo "$as_me:$LINENO: result: yes" >&5
9558 echo "${ECHO_T}yes" >&6
9559        else
9560   echo "$as_me:$LINENO: result: no" >&5
9561 echo "${ECHO_T}no" >&6
9562 fi
9563        ;;
9564    *)
9565   echo "$as_me:$LINENO: result: no" >&5
9566 echo "${ECHO_T}no" >&6
9567     ;;
9568   esac
9569 fi
9570
9571 if test "x$enable_dlopen" != xyes; then
9572   enable_dlopen=unknown
9573   enable_dlopen_self=unknown
9574   enable_dlopen_self_static=unknown
9575 else
9576   lt_cv_dlopen=no
9577   lt_cv_dlopen_libs=
9578
9579   case $host_os in
9580   beos*)
9581     lt_cv_dlopen="load_add_on"
9582     lt_cv_dlopen_libs=
9583     lt_cv_dlopen_self=yes
9584     ;;
9585
9586   mingw* | pw32*)
9587     lt_cv_dlopen="LoadLibrary"
9588     lt_cv_dlopen_libs=
9589    ;;
9590
9591   cygwin*)
9592     lt_cv_dlopen="dlopen"
9593     lt_cv_dlopen_libs=
9594    ;;
9595
9596   darwin*)
9597   # if libdl is installed we need to link against it
9598     echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
9599 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
9600 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
9601   echo $ECHO_N "(cached) $ECHO_C" >&6
9602 else
9603   ac_check_lib_save_LIBS=$LIBS
9604 LIBS="-ldl  $LIBS"
9605 cat >conftest.$ac_ext <<_ACEOF
9606 /* confdefs.h.  */
9607 _ACEOF
9608 cat confdefs.h >>conftest.$ac_ext
9609 cat >>conftest.$ac_ext <<_ACEOF
9610 /* end confdefs.h.  */
9611
9612 /* Override any gcc2 internal prototype to avoid an error.  */
9613 #ifdef __cplusplus
9614 extern "C"
9615 #endif
9616 /* We use char because int might match the return type of a gcc2
9617    builtin and then its argument prototype would still apply.  */
9618 char dlopen ();
9619 int
9620 main ()
9621 {
9622 dlopen ();
9623   ;
9624   return 0;
9625 }
9626 _ACEOF
9627 rm -f conftest.$ac_objext conftest$ac_exeext
9628 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9629   (eval $ac_link) 2>conftest.er1
9630   ac_status=$?
9631   grep -v '^ *+' conftest.er1 >conftest.err
9632   rm -f conftest.er1
9633   cat conftest.err >&5
9634   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9635   (exit $ac_status); } &&
9636          { ac_try='test -z "$ac_c_werror_flag"
9637                          || test ! -s conftest.err'
9638   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9639   (eval $ac_try) 2>&5
9640   ac_status=$?
9641   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9642   (exit $ac_status); }; } &&
9643          { ac_try='test -s conftest$ac_exeext'
9644   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9645   (eval $ac_try) 2>&5
9646   ac_status=$?
9647   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9648   (exit $ac_status); }; }; then
9649   ac_cv_lib_dl_dlopen=yes
9650 else
9651   echo "$as_me: failed program was:" >&5
9652 sed 's/^/| /' conftest.$ac_ext >&5
9653
9654 ac_cv_lib_dl_dlopen=no
9655 fi
9656 rm -f conftest.err conftest.$ac_objext \
9657       conftest$ac_exeext conftest.$ac_ext
9658 LIBS=$ac_check_lib_save_LIBS
9659 fi
9660 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
9661 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
9662 if test $ac_cv_lib_dl_dlopen = yes; then
9663   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
9664 else
9665
9666     lt_cv_dlopen="dyld"
9667     lt_cv_dlopen_libs=
9668     lt_cv_dlopen_self=yes
9669
9670 fi
9671
9672    ;;
9673
9674   *)
9675     echo "$as_me:$LINENO: checking for shl_load" >&5
9676 echo $ECHO_N "checking for shl_load... $ECHO_C" >&6
9677 if test "${ac_cv_func_shl_load+set}" = set; then
9678   echo $ECHO_N "(cached) $ECHO_C" >&6
9679 else
9680   cat >conftest.$ac_ext <<_ACEOF
9681 /* confdefs.h.  */
9682 _ACEOF
9683 cat confdefs.h >>conftest.$ac_ext
9684 cat >>conftest.$ac_ext <<_ACEOF
9685 /* end confdefs.h.  */
9686 /* Define shl_load to an innocuous variant, in case <limits.h> declares shl_load.
9687    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9688 #define shl_load innocuous_shl_load
9689
9690 /* System header to define __stub macros and hopefully few prototypes,
9691     which can conflict with char shl_load (); below.
9692     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9693     <limits.h> exists even on freestanding compilers.  */
9694
9695 #ifdef __STDC__
9696 # include <limits.h>
9697 #else
9698 # include <assert.h>
9699 #endif
9700
9701 #undef shl_load
9702
9703 /* Override any gcc2 internal prototype to avoid an error.  */
9704 #ifdef __cplusplus
9705 extern "C"
9706 {
9707 #endif
9708 /* We use char because int might match the return type of a gcc2
9709    builtin and then its argument prototype would still apply.  */
9710 char shl_load ();
9711 /* The GNU C library defines this for functions which it implements
9712     to always fail with ENOSYS.  Some functions are actually named
9713     something starting with __ and the normal name is an alias.  */
9714 #if defined (__stub_shl_load) || defined (__stub___shl_load)
9715 choke me
9716 #else
9717 char (*f) () = shl_load;
9718 #endif
9719 #ifdef __cplusplus
9720 }
9721 #endif
9722
9723 int
9724 main ()
9725 {
9726 return f != shl_load;
9727   ;
9728   return 0;
9729 }
9730 _ACEOF
9731 rm -f conftest.$ac_objext conftest$ac_exeext
9732 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9733   (eval $ac_link) 2>conftest.er1
9734   ac_status=$?
9735   grep -v '^ *+' conftest.er1 >conftest.err
9736   rm -f conftest.er1
9737   cat conftest.err >&5
9738   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9739   (exit $ac_status); } &&
9740          { ac_try='test -z "$ac_c_werror_flag"
9741                          || test ! -s conftest.err'
9742   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9743   (eval $ac_try) 2>&5
9744   ac_status=$?
9745   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9746   (exit $ac_status); }; } &&
9747          { ac_try='test -s conftest$ac_exeext'
9748   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9749   (eval $ac_try) 2>&5
9750   ac_status=$?
9751   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9752   (exit $ac_status); }; }; then
9753   ac_cv_func_shl_load=yes
9754 else
9755   echo "$as_me: failed program was:" >&5
9756 sed 's/^/| /' conftest.$ac_ext >&5
9757
9758 ac_cv_func_shl_load=no
9759 fi
9760 rm -f conftest.err conftest.$ac_objext \
9761       conftest$ac_exeext conftest.$ac_ext
9762 fi
9763 echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5
9764 echo "${ECHO_T}$ac_cv_func_shl_load" >&6
9765 if test $ac_cv_func_shl_load = yes; then
9766   lt_cv_dlopen="shl_load"
9767 else
9768   echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
9769 echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6
9770 if test "${ac_cv_lib_dld_shl_load+set}" = set; then
9771   echo $ECHO_N "(cached) $ECHO_C" >&6
9772 else
9773   ac_check_lib_save_LIBS=$LIBS
9774 LIBS="-ldld  $LIBS"
9775 cat >conftest.$ac_ext <<_ACEOF
9776 /* confdefs.h.  */
9777 _ACEOF
9778 cat confdefs.h >>conftest.$ac_ext
9779 cat >>conftest.$ac_ext <<_ACEOF
9780 /* end confdefs.h.  */
9781
9782 /* Override any gcc2 internal prototype to avoid an error.  */
9783 #ifdef __cplusplus
9784 extern "C"
9785 #endif
9786 /* We use char because int might match the return type of a gcc2
9787    builtin and then its argument prototype would still apply.  */
9788 char shl_load ();
9789 int
9790 main ()
9791 {
9792 shl_load ();
9793   ;
9794   return 0;
9795 }
9796 _ACEOF
9797 rm -f conftest.$ac_objext conftest$ac_exeext
9798 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9799   (eval $ac_link) 2>conftest.er1
9800   ac_status=$?
9801   grep -v '^ *+' conftest.er1 >conftest.err
9802   rm -f conftest.er1
9803   cat conftest.err >&5
9804   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9805   (exit $ac_status); } &&
9806          { ac_try='test -z "$ac_c_werror_flag"
9807                          || test ! -s conftest.err'
9808   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9809   (eval $ac_try) 2>&5
9810   ac_status=$?
9811   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9812   (exit $ac_status); }; } &&
9813          { ac_try='test -s conftest$ac_exeext'
9814   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9815   (eval $ac_try) 2>&5
9816   ac_status=$?
9817   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9818   (exit $ac_status); }; }; then
9819   ac_cv_lib_dld_shl_load=yes
9820 else
9821   echo "$as_me: failed program was:" >&5
9822 sed 's/^/| /' conftest.$ac_ext >&5
9823
9824 ac_cv_lib_dld_shl_load=no
9825 fi
9826 rm -f conftest.err conftest.$ac_objext \
9827       conftest$ac_exeext conftest.$ac_ext
9828 LIBS=$ac_check_lib_save_LIBS
9829 fi
9830 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
9831 echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6
9832 if test $ac_cv_lib_dld_shl_load = yes; then
9833   lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"
9834 else
9835   echo "$as_me:$LINENO: checking for dlopen" >&5
9836 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6
9837 if test "${ac_cv_func_dlopen+set}" = set; then
9838   echo $ECHO_N "(cached) $ECHO_C" >&6
9839 else
9840   cat >conftest.$ac_ext <<_ACEOF
9841 /* confdefs.h.  */
9842 _ACEOF
9843 cat confdefs.h >>conftest.$ac_ext
9844 cat >>conftest.$ac_ext <<_ACEOF
9845 /* end confdefs.h.  */
9846 /* Define dlopen to an innocuous variant, in case <limits.h> declares dlopen.
9847    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9848 #define dlopen innocuous_dlopen
9849
9850 /* System header to define __stub macros and hopefully few prototypes,
9851     which can conflict with char dlopen (); below.
9852     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9853     <limits.h> exists even on freestanding compilers.  */
9854
9855 #ifdef __STDC__
9856 # include <limits.h>
9857 #else
9858 # include <assert.h>
9859 #endif
9860
9861 #undef dlopen
9862
9863 /* Override any gcc2 internal prototype to avoid an error.  */
9864 #ifdef __cplusplus
9865 extern "C"
9866 {
9867 #endif
9868 /* We use char because int might match the return type of a gcc2
9869    builtin and then its argument prototype would still apply.  */
9870 char dlopen ();
9871 /* The GNU C library defines this for functions which it implements
9872     to always fail with ENOSYS.  Some functions are actually named
9873     something starting with __ and the normal name is an alias.  */
9874 #if defined (__stub_dlopen) || defined (__stub___dlopen)
9875 choke me
9876 #else
9877 char (*f) () = dlopen;
9878 #endif
9879 #ifdef __cplusplus
9880 }
9881 #endif
9882
9883 int
9884 main ()
9885 {
9886 return f != dlopen;
9887   ;
9888   return 0;
9889 }
9890 _ACEOF
9891 rm -f conftest.$ac_objext conftest$ac_exeext
9892 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9893   (eval $ac_link) 2>conftest.er1
9894   ac_status=$?
9895   grep -v '^ *+' conftest.er1 >conftest.err
9896   rm -f conftest.er1
9897   cat conftest.err >&5
9898   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9899   (exit $ac_status); } &&
9900          { ac_try='test -z "$ac_c_werror_flag"
9901                          || test ! -s conftest.err'
9902   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9903   (eval $ac_try) 2>&5
9904   ac_status=$?
9905   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9906   (exit $ac_status); }; } &&
9907          { ac_try='test -s conftest$ac_exeext'
9908   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9909   (eval $ac_try) 2>&5
9910   ac_status=$?
9911   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9912   (exit $ac_status); }; }; then
9913   ac_cv_func_dlopen=yes
9914 else
9915   echo "$as_me: failed program was:" >&5
9916 sed 's/^/| /' conftest.$ac_ext >&5
9917
9918 ac_cv_func_dlopen=no
9919 fi
9920 rm -f conftest.err conftest.$ac_objext \
9921       conftest$ac_exeext conftest.$ac_ext
9922 fi
9923 echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
9924 echo "${ECHO_T}$ac_cv_func_dlopen" >&6
9925 if test $ac_cv_func_dlopen = yes; then
9926   lt_cv_dlopen="dlopen"
9927 else
9928   echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
9929 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
9930 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
9931   echo $ECHO_N "(cached) $ECHO_C" >&6
9932 else
9933   ac_check_lib_save_LIBS=$LIBS
9934 LIBS="-ldl  $LIBS"
9935 cat >conftest.$ac_ext <<_ACEOF
9936 /* confdefs.h.  */
9937 _ACEOF
9938 cat confdefs.h >>conftest.$ac_ext
9939 cat >>conftest.$ac_ext <<_ACEOF
9940 /* end confdefs.h.  */
9941
9942 /* Override any gcc2 internal prototype to avoid an error.  */
9943 #ifdef __cplusplus
9944 extern "C"
9945 #endif
9946 /* We use char because int might match the return type of a gcc2
9947    builtin and then its argument prototype would still apply.  */
9948 char dlopen ();
9949 int
9950 main ()
9951 {
9952 dlopen ();
9953   ;
9954   return 0;
9955 }
9956 _ACEOF
9957 rm -f conftest.$ac_objext conftest$ac_exeext
9958 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9959   (eval $ac_link) 2>conftest.er1
9960   ac_status=$?
9961   grep -v '^ *+' conftest.er1 >conftest.err
9962   rm -f conftest.er1
9963   cat conftest.err >&5
9964   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9965   (exit $ac_status); } &&
9966          { ac_try='test -z "$ac_c_werror_flag"
9967                          || test ! -s conftest.err'
9968   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9969   (eval $ac_try) 2>&5
9970   ac_status=$?
9971   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9972   (exit $ac_status); }; } &&
9973          { ac_try='test -s conftest$ac_exeext'
9974   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9975   (eval $ac_try) 2>&5
9976   ac_status=$?
9977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9978   (exit $ac_status); }; }; then
9979   ac_cv_lib_dl_dlopen=yes
9980 else
9981   echo "$as_me: failed program was:" >&5
9982 sed 's/^/| /' conftest.$ac_ext >&5
9983
9984 ac_cv_lib_dl_dlopen=no
9985 fi
9986 rm -f conftest.err conftest.$ac_objext \
9987       conftest$ac_exeext conftest.$ac_ext
9988 LIBS=$ac_check_lib_save_LIBS
9989 fi
9990 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
9991 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
9992 if test $ac_cv_lib_dl_dlopen = yes; then
9993   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
9994 else
9995   echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5
9996 echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6
9997 if test "${ac_cv_lib_svld_dlopen+set}" = set; then
9998   echo $ECHO_N "(cached) $ECHO_C" >&6
9999 else
10000   ac_check_lib_save_LIBS=$LIBS
10001 LIBS="-lsvld  $LIBS"
10002 cat >conftest.$ac_ext <<_ACEOF
10003 /* confdefs.h.  */
10004 _ACEOF
10005 cat confdefs.h >>conftest.$ac_ext
10006 cat >>conftest.$ac_ext <<_ACEOF
10007 /* end confdefs.h.  */
10008
10009 /* Override any gcc2 internal prototype to avoid an error.  */
10010 #ifdef __cplusplus
10011 extern "C"
10012 #endif
10013 /* We use char because int might match the return type of a gcc2
10014    builtin and then its argument prototype would still apply.  */
10015 char dlopen ();
10016 int
10017 main ()
10018 {
10019 dlopen ();
10020   ;
10021   return 0;
10022 }
10023 _ACEOF
10024 rm -f conftest.$ac_objext conftest$ac_exeext
10025 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10026   (eval $ac_link) 2>conftest.er1
10027   ac_status=$?
10028   grep -v '^ *+' conftest.er1 >conftest.err
10029   rm -f conftest.er1
10030   cat conftest.err >&5
10031   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10032   (exit $ac_status); } &&
10033          { ac_try='test -z "$ac_c_werror_flag"
10034                          || test ! -s conftest.err'
10035   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10036   (eval $ac_try) 2>&5
10037   ac_status=$?
10038   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10039   (exit $ac_status); }; } &&
10040          { ac_try='test -s conftest$ac_exeext'
10041   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10042   (eval $ac_try) 2>&5
10043   ac_status=$?
10044   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10045   (exit $ac_status); }; }; then
10046   ac_cv_lib_svld_dlopen=yes
10047 else
10048   echo "$as_me: failed program was:" >&5
10049 sed 's/^/| /' conftest.$ac_ext >&5
10050
10051 ac_cv_lib_svld_dlopen=no
10052 fi
10053 rm -f conftest.err conftest.$ac_objext \
10054       conftest$ac_exeext conftest.$ac_ext
10055 LIBS=$ac_check_lib_save_LIBS
10056 fi
10057 echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5
10058 echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6
10059 if test $ac_cv_lib_svld_dlopen = yes; then
10060   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
10061 else
10062   echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5
10063 echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6
10064 if test "${ac_cv_lib_dld_dld_link+set}" = set; then
10065   echo $ECHO_N "(cached) $ECHO_C" >&6
10066 else
10067   ac_check_lib_save_LIBS=$LIBS
10068 LIBS="-ldld  $LIBS"
10069 cat >conftest.$ac_ext <<_ACEOF
10070 /* confdefs.h.  */
10071 _ACEOF
10072 cat confdefs.h >>conftest.$ac_ext
10073 cat >>conftest.$ac_ext <<_ACEOF
10074 /* end confdefs.h.  */
10075
10076 /* Override any gcc2 internal prototype to avoid an error.  */
10077 #ifdef __cplusplus
10078 extern "C"
10079 #endif
10080 /* We use char because int might match the return type of a gcc2
10081    builtin and then its argument prototype would still apply.  */
10082 char dld_link ();
10083 int
10084 main ()
10085 {
10086 dld_link ();
10087   ;
10088   return 0;
10089 }
10090 _ACEOF
10091 rm -f conftest.$ac_objext conftest$ac_exeext
10092 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10093   (eval $ac_link) 2>conftest.er1
10094   ac_status=$?
10095   grep -v '^ *+' conftest.er1 >conftest.err
10096   rm -f conftest.er1
10097   cat conftest.err >&5
10098   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10099   (exit $ac_status); } &&
10100          { ac_try='test -z "$ac_c_werror_flag"
10101                          || test ! -s conftest.err'
10102   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10103   (eval $ac_try) 2>&5
10104   ac_status=$?
10105   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10106   (exit $ac_status); }; } &&
10107          { ac_try='test -s conftest$ac_exeext'
10108   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10109   (eval $ac_try) 2>&5
10110   ac_status=$?
10111   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10112   (exit $ac_status); }; }; then
10113   ac_cv_lib_dld_dld_link=yes
10114 else
10115   echo "$as_me: failed program was:" >&5
10116 sed 's/^/| /' conftest.$ac_ext >&5
10117
10118 ac_cv_lib_dld_dld_link=no
10119 fi
10120 rm -f conftest.err conftest.$ac_objext \
10121       conftest$ac_exeext conftest.$ac_ext
10122 LIBS=$ac_check_lib_save_LIBS
10123 fi
10124 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5
10125 echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6
10126 if test $ac_cv_lib_dld_dld_link = yes; then
10127   lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"
10128 fi
10129
10130
10131 fi
10132
10133
10134 fi
10135
10136
10137 fi
10138
10139
10140 fi
10141
10142
10143 fi
10144
10145     ;;
10146   esac
10147
10148   if test "x$lt_cv_dlopen" != xno; then
10149     enable_dlopen=yes
10150   else
10151     enable_dlopen=no
10152   fi
10153
10154   case $lt_cv_dlopen in
10155   dlopen)
10156     save_CPPFLAGS="$CPPFLAGS"
10157     test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
10158
10159     save_LDFLAGS="$LDFLAGS"
10160     eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
10161
10162     save_LIBS="$LIBS"
10163     LIBS="$lt_cv_dlopen_libs $LIBS"
10164
10165     echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5
10166 echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6
10167 if test "${lt_cv_dlopen_self+set}" = set; then
10168   echo $ECHO_N "(cached) $ECHO_C" >&6
10169 else
10170           if test "$cross_compiling" = yes; then :
10171   lt_cv_dlopen_self=cross
10172 else
10173   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10174   lt_status=$lt_dlunknown
10175   cat > conftest.$ac_ext <<EOF
10176 #line 10176 "configure"
10177 #include "confdefs.h"
10178
10179 #if HAVE_DLFCN_H
10180 #include <dlfcn.h>
10181 #endif
10182
10183 #include <stdio.h>
10184
10185 #ifdef RTLD_GLOBAL
10186 #  define LT_DLGLOBAL           RTLD_GLOBAL
10187 #else
10188 #  ifdef DL_GLOBAL
10189 #    define LT_DLGLOBAL         DL_GLOBAL
10190 #  else
10191 #    define LT_DLGLOBAL         0
10192 #  endif
10193 #endif
10194
10195 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
10196    find out it does not work in some platform. */
10197 #ifndef LT_DLLAZY_OR_NOW
10198 #  ifdef RTLD_LAZY
10199 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
10200 #  else
10201 #    ifdef DL_LAZY
10202 #      define LT_DLLAZY_OR_NOW          DL_LAZY
10203 #    else
10204 #      ifdef RTLD_NOW
10205 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
10206 #      else
10207 #        ifdef DL_NOW
10208 #          define LT_DLLAZY_OR_NOW      DL_NOW
10209 #        else
10210 #          define LT_DLLAZY_OR_NOW      0
10211 #        endif
10212 #      endif
10213 #    endif
10214 #  endif
10215 #endif
10216
10217 #ifdef __cplusplus
10218 extern "C" void exit (int);
10219 #endif
10220
10221 void fnord() { int i=42;}
10222 int main ()
10223 {
10224   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10225   int status = $lt_dlunknown;
10226
10227   if (self)
10228     {
10229       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
10230       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
10231       /* dlclose (self); */
10232     }
10233
10234     exit (status);
10235 }
10236 EOF
10237   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10238   (eval $ac_link) 2>&5
10239   ac_status=$?
10240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10241   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
10242     (./conftest; exit; ) >&5 2>/dev/null
10243     lt_status=$?
10244     case x$lt_status in
10245       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
10246       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
10247       x$lt_unknown|x*) lt_cv_dlopen_self=no ;;
10248     esac
10249   else :
10250     # compilation failed
10251     lt_cv_dlopen_self=no
10252   fi
10253 fi
10254 rm -fr conftest*
10255
10256
10257 fi
10258 echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5
10259 echo "${ECHO_T}$lt_cv_dlopen_self" >&6
10260
10261     if test "x$lt_cv_dlopen_self" = xyes; then
10262       LDFLAGS="$LDFLAGS $link_static_flag"
10263       echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5
10264 echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6
10265 if test "${lt_cv_dlopen_self_static+set}" = set; then
10266   echo $ECHO_N "(cached) $ECHO_C" >&6
10267 else
10268           if test "$cross_compiling" = yes; then :
10269   lt_cv_dlopen_self_static=cross
10270 else
10271   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10272   lt_status=$lt_dlunknown
10273   cat > conftest.$ac_ext <<EOF
10274 #line 10274 "configure"
10275 #include "confdefs.h"
10276
10277 #if HAVE_DLFCN_H
10278 #include <dlfcn.h>
10279 #endif
10280
10281 #include <stdio.h>
10282
10283 #ifdef RTLD_GLOBAL
10284 #  define LT_DLGLOBAL           RTLD_GLOBAL
10285 #else
10286 #  ifdef DL_GLOBAL
10287 #    define LT_DLGLOBAL         DL_GLOBAL
10288 #  else
10289 #    define LT_DLGLOBAL         0
10290 #  endif
10291 #endif
10292
10293 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
10294    find out it does not work in some platform. */
10295 #ifndef LT_DLLAZY_OR_NOW
10296 #  ifdef RTLD_LAZY
10297 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
10298 #  else
10299 #    ifdef DL_LAZY
10300 #      define LT_DLLAZY_OR_NOW          DL_LAZY
10301 #    else
10302 #      ifdef RTLD_NOW
10303 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
10304 #      else
10305 #        ifdef DL_NOW
10306 #          define LT_DLLAZY_OR_NOW      DL_NOW
10307 #        else
10308 #          define LT_DLLAZY_OR_NOW      0
10309 #        endif
10310 #      endif
10311 #    endif
10312 #  endif
10313 #endif
10314
10315 #ifdef __cplusplus
10316 extern "C" void exit (int);
10317 #endif
10318
10319 void fnord() { int i=42;}
10320 int main ()
10321 {
10322   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10323   int status = $lt_dlunknown;
10324
10325   if (self)
10326     {
10327       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
10328       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
10329       /* dlclose (self); */
10330     }
10331
10332     exit (status);
10333 }
10334 EOF
10335   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10336   (eval $ac_link) 2>&5
10337   ac_status=$?
10338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10339   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
10340     (./conftest; exit; ) >&5 2>/dev/null
10341     lt_status=$?
10342     case x$lt_status in
10343       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
10344       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
10345       x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;;
10346     esac
10347   else :
10348     # compilation failed
10349     lt_cv_dlopen_self_static=no
10350   fi
10351 fi
10352 rm -fr conftest*
10353
10354
10355 fi
10356 echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5
10357 echo "${ECHO_T}$lt_cv_dlopen_self_static" >&6
10358     fi
10359
10360     CPPFLAGS="$save_CPPFLAGS"
10361     LDFLAGS="$save_LDFLAGS"
10362     LIBS="$save_LIBS"
10363     ;;
10364   esac
10365
10366   case $lt_cv_dlopen_self in
10367   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
10368   *) enable_dlopen_self=unknown ;;
10369   esac
10370
10371   case $lt_cv_dlopen_self_static in
10372   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
10373   *) enable_dlopen_self_static=unknown ;;
10374   esac
10375 fi
10376
10377
10378 # Report which librarie types wil actually be built
10379 echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
10380 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6
10381 echo "$as_me:$LINENO: result: $can_build_shared" >&5
10382 echo "${ECHO_T}$can_build_shared" >&6
10383
10384 echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
10385 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6
10386 test "$can_build_shared" = "no" && enable_shared=no
10387
10388 # On AIX, shared libraries and static libraries use the same namespace, and
10389 # are all built from PIC.
10390 case $host_os in
10391 aix3*)
10392   test "$enable_shared" = yes && enable_static=no
10393   if test -n "$RANLIB"; then
10394     archive_cmds="$archive_cmds~\$RANLIB \$lib"
10395     postinstall_cmds='$RANLIB $lib'
10396   fi
10397   ;;
10398
10399 aix4* | aix5*)
10400   if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
10401     test "$enable_shared" = yes && enable_static=no
10402   fi
10403     ;;
10404 esac
10405 echo "$as_me:$LINENO: result: $enable_shared" >&5
10406 echo "${ECHO_T}$enable_shared" >&6
10407
10408 echo "$as_me:$LINENO: checking whether to build static libraries" >&5
10409 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6
10410 # Make sure either enable_shared or enable_static is yes.
10411 test "$enable_shared" = yes || enable_static=yes
10412 echo "$as_me:$LINENO: result: $enable_static" >&5
10413 echo "${ECHO_T}$enable_static" >&6
10414
10415 # The else clause should only fire when bootstrapping the
10416 # libtool distribution, otherwise you forgot to ship ltmain.sh
10417 # with your package, and you will get complaints that there are
10418 # no rules to generate ltmain.sh.
10419 if test -f "$ltmain"; then
10420   # See if we are running on zsh, and set the options which allow our commands through
10421   # without removal of \ escapes.
10422   if test -n "${ZSH_VERSION+set}" ; then
10423     setopt NO_GLOB_SUBST
10424   fi
10425   # Now quote all the things that may contain metacharacters while being
10426   # careful not to overquote the AC_SUBSTed values.  We take copies of the
10427   # variables and quote the copies for generation of the libtool script.
10428   for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
10429     SED SHELL STRIP \
10430     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
10431     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
10432     deplibs_check_method reload_flag reload_cmds need_locks \
10433     lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
10434     lt_cv_sys_global_symbol_to_c_name_address \
10435     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
10436     old_postinstall_cmds old_postuninstall_cmds \
10437     compiler \
10438     CC \
10439     LD \
10440     lt_prog_compiler_wl \
10441     lt_prog_compiler_pic \
10442     lt_prog_compiler_static \
10443     lt_prog_compiler_no_builtin_flag \
10444     export_dynamic_flag_spec \
10445     thread_safe_flag_spec \
10446     whole_archive_flag_spec \
10447     enable_shared_with_static_runtimes \
10448     old_archive_cmds \
10449     old_archive_from_new_cmds \
10450     predep_objects \
10451     postdep_objects \
10452     predeps \
10453     postdeps \
10454     compiler_lib_search_path \
10455     archive_cmds \
10456     archive_expsym_cmds \
10457     postinstall_cmds \
10458     postuninstall_cmds \
10459     old_archive_from_expsyms_cmds \
10460     allow_undefined_flag \
10461     no_undefined_flag \
10462     export_symbols_cmds \
10463     hardcode_libdir_flag_spec \
10464     hardcode_libdir_flag_spec_ld \
10465     hardcode_libdir_separator \
10466     hardcode_automatic \
10467     module_cmds \
10468     module_expsym_cmds \
10469     lt_cv_prog_compiler_c_o \
10470     exclude_expsyms \
10471     include_expsyms; do
10472
10473     case $var in
10474     old_archive_cmds | \
10475     old_archive_from_new_cmds | \
10476     archive_cmds | \
10477     archive_expsym_cmds | \
10478     module_cmds | \
10479     module_expsym_cmds | \
10480     old_archive_from_expsyms_cmds | \
10481     export_symbols_cmds | \
10482     extract_expsyms_cmds | reload_cmds | finish_cmds | \
10483     postinstall_cmds | postuninstall_cmds | \
10484     old_postinstall_cmds | old_postuninstall_cmds | \
10485     sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
10486       # Double-quote double-evaled strings.
10487       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
10488       ;;
10489     *)
10490       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
10491       ;;
10492     esac
10493   done
10494
10495   case $lt_echo in
10496   *'\$0 --fallback-echo"')
10497     lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
10498     ;;
10499   esac
10500
10501 cfgfile="${ofile}T"
10502   trap "$rm \"$cfgfile\"; exit 1" 1 2 15
10503   $rm -f "$cfgfile"
10504   { echo "$as_me:$LINENO: creating $ofile" >&5
10505 echo "$as_me: creating $ofile" >&6;}
10506
10507   cat <<__EOF__ >> "$cfgfile"
10508 #! $SHELL
10509
10510 # `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
10511 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
10512 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
10513 #
10514 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
10515 # Free Software Foundation, Inc.
10516 #
10517 # This file is part of GNU Libtool:
10518 # Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
10519 #
10520 # This program is free software; you can redistribute it and/or modify
10521 # it under the terms of the GNU General Public License as published by
10522 # the Free Software Foundation; either version 2 of the License, or
10523 # (at your option) any later version.
10524 #
10525 # This program is distributed in the hope that it will be useful, but
10526 # WITHOUT ANY WARRANTY; without even the implied warranty of
10527 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
10528 # General Public License for more details.
10529 #
10530 # You should have received a copy of the GNU General Public License
10531 # along with this program; if not, write to the Free Software
10532 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
10533 #
10534 # As a special exception to the GNU General Public License, if you
10535 # distribute this file as part of a program that contains a
10536 # configuration script generated by Autoconf, you may include it under
10537 # the same distribution terms that you use for the rest of that program.
10538
10539 # A sed program that does not truncate output.
10540 SED=$lt_SED
10541
10542 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
10543 Xsed="$SED -e 1s/^X//"
10544
10545 # The HP-UX ksh and POSIX shell print the target directory to stdout
10546 # if CDPATH is set.
10547 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
10548
10549 # The names of the tagged configurations supported by this script.
10550 available_tags=
10551
10552 # ### BEGIN LIBTOOL CONFIG
10553
10554 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
10555
10556 # Shell to use when invoking shell scripts.
10557 SHELL=$lt_SHELL
10558
10559 # Whether or not to build shared libraries.
10560 build_libtool_libs=$enable_shared
10561
10562 # Whether or not to build static libraries.
10563 build_old_libs=$enable_static
10564
10565 # Whether or not to add -lc for building shared libraries.
10566 build_libtool_need_lc=$archive_cmds_need_lc
10567
10568 # Whether or not to disallow shared libs when runtime libs are static
10569 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
10570
10571 # Whether or not to optimize for fast installation.
10572 fast_install=$enable_fast_install
10573
10574 # The host system.
10575 host_alias=$host_alias
10576 host=$host
10577 host_os=$host_os
10578
10579 # The build system.
10580 build_alias=$build_alias
10581 build=$build
10582 build_os=$build_os
10583
10584 # An echo program that does not interpret backslashes.
10585 echo=$lt_echo
10586
10587 # The archiver.
10588 AR=$lt_AR
10589 AR_FLAGS=$lt_AR_FLAGS
10590
10591 # A C compiler.
10592 LTCC=$lt_LTCC
10593
10594 # A language-specific compiler.
10595 CC=$lt_compiler
10596
10597 # Is the compiler the GNU C compiler?
10598 with_gcc=$GCC
10599
10600 # An ERE matcher.
10601 EGREP=$lt_EGREP
10602
10603 # The linker used to build libraries.
10604 LD=$lt_LD
10605
10606 # Whether we need hard or soft links.
10607 LN_S=$lt_LN_S
10608
10609 # A BSD-compatible nm program.
10610 NM=$lt_NM
10611
10612 # A symbol stripping program
10613 STRIP=$lt_STRIP
10614
10615 # Used to examine libraries when file_magic_cmd begins "file"
10616 MAGIC_CMD=$MAGIC_CMD
10617
10618 # Used on cygwin: DLL creation program.
10619 DLLTOOL="$DLLTOOL"
10620
10621 # Used on cygwin: object dumper.
10622 OBJDUMP="$OBJDUMP"
10623
10624 # Used on cygwin: assembler.
10625 AS="$AS"
10626
10627 # The name of the directory that contains temporary libtool files.
10628 objdir=$objdir
10629
10630 # How to create reloadable object files.
10631 reload_flag=$lt_reload_flag
10632 reload_cmds=$lt_reload_cmds
10633
10634 # How to pass a linker flag through the compiler.
10635 wl=$lt_lt_prog_compiler_wl
10636
10637 # Object file suffix (normally "o").
10638 objext="$ac_objext"
10639
10640 # Old archive suffix (normally "a").
10641 libext="$libext"
10642
10643 # Shared library suffix (normally ".so").
10644 shrext_cmds='$shrext_cmds'
10645
10646 # Executable file suffix (normally "").
10647 exeext="$exeext"
10648
10649 # Additional compiler flags for building library objects.
10650 pic_flag=$lt_lt_prog_compiler_pic
10651 pic_mode=$pic_mode
10652
10653 # What is the maximum length of a command?
10654 max_cmd_len=$lt_cv_sys_max_cmd_len
10655
10656 # Does compiler simultaneously support -c and -o options?
10657 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
10658
10659 # Must we lock files when doing compilation?
10660 need_locks=$lt_need_locks
10661
10662 # Do we need the lib prefix for modules?
10663 need_lib_prefix=$need_lib_prefix
10664
10665 # Do we need a version for libraries?
10666 need_version=$need_version
10667
10668 # Whether dlopen is supported.
10669 dlopen_support=$enable_dlopen
10670
10671 # Whether dlopen of programs is supported.
10672 dlopen_self=$enable_dlopen_self
10673
10674 # Whether dlopen of statically linked programs is supported.
10675 dlopen_self_static=$enable_dlopen_self_static
10676
10677 # Compiler flag to prevent dynamic linking.
10678 link_static_flag=$lt_lt_prog_compiler_static
10679
10680 # Compiler flag to turn off builtin functions.
10681 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
10682
10683 # Compiler flag to allow reflexive dlopens.
10684 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
10685
10686 # Compiler flag to generate shared objects directly from archives.
10687 whole_archive_flag_spec=$lt_whole_archive_flag_spec
10688
10689 # Compiler flag to generate thread-safe objects.
10690 thread_safe_flag_spec=$lt_thread_safe_flag_spec
10691
10692 # Library versioning type.
10693 version_type=$version_type
10694
10695 # Format of library name prefix.
10696 libname_spec=$lt_libname_spec
10697
10698 # List of archive names.  First name is the real one, the rest are links.
10699 # The last name is the one that the linker finds with -lNAME.
10700 library_names_spec=$lt_library_names_spec
10701
10702 # The coded name of the library, if different from the real name.
10703 soname_spec=$lt_soname_spec
10704
10705 # Commands used to build and install an old-style archive.
10706 RANLIB=$lt_RANLIB
10707 old_archive_cmds=$lt_old_archive_cmds
10708 old_postinstall_cmds=$lt_old_postinstall_cmds
10709 old_postuninstall_cmds=$lt_old_postuninstall_cmds
10710
10711 # Create an old-style archive from a shared archive.
10712 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
10713
10714 # Create a temporary old-style archive to link instead of a shared archive.
10715 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
10716
10717 # Commands used to build and install a shared archive.
10718 archive_cmds=$lt_archive_cmds
10719 archive_expsym_cmds=$lt_archive_expsym_cmds
10720 postinstall_cmds=$lt_postinstall_cmds
10721 postuninstall_cmds=$lt_postuninstall_cmds
10722
10723 # Commands used to build a loadable module (assumed same as above if empty)
10724 module_cmds=$lt_module_cmds
10725 module_expsym_cmds=$lt_module_expsym_cmds
10726
10727 # Commands to strip libraries.
10728 old_striplib=$lt_old_striplib
10729 striplib=$lt_striplib
10730
10731 # Dependencies to place before the objects being linked to create a
10732 # shared library.
10733 predep_objects=$lt_predep_objects
10734
10735 # Dependencies to place after the objects being linked to create a
10736 # shared library.
10737 postdep_objects=$lt_postdep_objects
10738
10739 # Dependencies to place before the objects being linked to create a
10740 # shared library.
10741 predeps=$lt_predeps
10742
10743 # Dependencies to place after the objects being linked to create a
10744 # shared library.
10745 postdeps=$lt_postdeps
10746
10747 # The library search path used internally by the compiler when linking
10748 # a shared library.
10749 compiler_lib_search_path=$lt_compiler_lib_search_path
10750
10751 # Method to check whether dependent libraries are shared objects.
10752 deplibs_check_method=$lt_deplibs_check_method
10753
10754 # Command to use when deplibs_check_method == file_magic.
10755 file_magic_cmd=$lt_file_magic_cmd
10756
10757 # Flag that allows shared libraries with undefined symbols to be built.
10758 allow_undefined_flag=$lt_allow_undefined_flag
10759
10760 # Flag that forces no undefined symbols.
10761 no_undefined_flag=$lt_no_undefined_flag
10762
10763 # Commands used to finish a libtool library installation in a directory.
10764 finish_cmds=$lt_finish_cmds
10765
10766 # Same as above, but a single script fragment to be evaled but not shown.
10767 finish_eval=$lt_finish_eval
10768
10769 # Take the output of nm and produce a listing of raw symbols and C names.
10770 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
10771
10772 # Transform the output of nm in a proper C declaration
10773 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
10774
10775 # Transform the output of nm in a C name address pair
10776 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
10777
10778 # This is the shared library runtime path variable.
10779 runpath_var=$runpath_var
10780
10781 # This is the shared library path variable.
10782 shlibpath_var=$shlibpath_var
10783
10784 # Is shlibpath searched before the hard-coded library search path?
10785 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
10786
10787 # How to hardcode a shared library path into an executable.
10788 hardcode_action=$hardcode_action
10789
10790 # Whether we should hardcode library paths into libraries.
10791 hardcode_into_libs=$hardcode_into_libs
10792
10793 # Flag to hardcode \$libdir into a binary during linking.
10794 # This must work even if \$libdir does not exist.
10795 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
10796
10797 # If ld is used when linking, flag to hardcode \$libdir into
10798 # a binary during linking. This must work even if \$libdir does
10799 # not exist.
10800 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
10801
10802 # Whether we need a single -rpath flag with a separated argument.
10803 hardcode_libdir_separator=$lt_hardcode_libdir_separator
10804
10805 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
10806 # resulting binary.
10807 hardcode_direct=$hardcode_direct
10808
10809 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
10810 # resulting binary.
10811 hardcode_minus_L=$hardcode_minus_L
10812
10813 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
10814 # the resulting binary.
10815 hardcode_shlibpath_var=$hardcode_shlibpath_var
10816
10817 # Set to yes if building a shared library automatically hardcodes DIR into the library
10818 # and all subsequent libraries and executables linked against it.
10819 hardcode_automatic=$hardcode_automatic
10820
10821 # Variables whose values should be saved in libtool wrapper scripts and
10822 # restored at relink time.
10823 variables_saved_for_relink="$variables_saved_for_relink"
10824
10825 # Whether libtool must link a program against all its dependency libraries.
10826 link_all_deplibs=$link_all_deplibs
10827
10828 # Compile-time system search path for libraries
10829 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
10830
10831 # Run-time system search path for libraries
10832 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
10833
10834 # Fix the shell variable \$srcfile for the compiler.
10835 fix_srcfile_path="$fix_srcfile_path"
10836
10837 # Set to yes if exported symbols are required.
10838 always_export_symbols=$always_export_symbols
10839
10840 # The commands to list exported symbols.
10841 export_symbols_cmds=$lt_export_symbols_cmds
10842
10843 # The commands to extract the exported symbol list from a shared archive.
10844 extract_expsyms_cmds=$lt_extract_expsyms_cmds
10845
10846 # Symbols that should not be listed in the preloaded symbols.
10847 exclude_expsyms=$lt_exclude_expsyms
10848
10849 # Symbols that must always be exported.
10850 include_expsyms=$lt_include_expsyms
10851
10852 # ### END LIBTOOL CONFIG
10853
10854 __EOF__
10855
10856
10857   case $host_os in
10858   aix3*)
10859     cat <<\EOF >> "$cfgfile"
10860
10861 # AIX sometimes has problems with the GCC collect2 program.  For some
10862 # reason, if we set the COLLECT_NAMES environment variable, the problems
10863 # vanish in a puff of smoke.
10864 if test "X${COLLECT_NAMES+set}" != Xset; then
10865   COLLECT_NAMES=
10866   export COLLECT_NAMES
10867 fi
10868 EOF
10869     ;;
10870   esac
10871
10872   # We use sed instead of cat because bash on DJGPP gets confused if
10873   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
10874   # text mode, it properly converts lines to CR/LF.  This bash problem
10875   # is reportedly fixed, but why not run on old versions too?
10876   sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
10877
10878   mv -f "$cfgfile" "$ofile" || \
10879     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
10880   chmod +x "$ofile"
10881
10882 else
10883   # If there is no Makefile yet, we rely on a make rule to execute
10884   # `config.status --recheck' to rerun these tests and create the
10885   # libtool script then.
10886   ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
10887   if test -f "$ltmain_in"; then
10888     test -f Makefile && make "$ltmain"
10889   fi
10890 fi
10891
10892
10893 ac_ext=c
10894 ac_cpp='$CPP $CPPFLAGS'
10895 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10896 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10897 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10898
10899 CC="$lt_save_CC"
10900
10901
10902 # Check whether --with-tags or --without-tags was given.
10903 if test "${with_tags+set}" = set; then
10904   withval="$with_tags"
10905   tagnames="$withval"
10906 fi;
10907
10908 if test -f "$ltmain" && test -n "$tagnames"; then
10909   if test ! -f "${ofile}"; then
10910     { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not exist" >&5
10911 echo "$as_me: WARNING: output file \`$ofile' does not exist" >&2;}
10912   fi
10913
10914   if test -z "$LTCC"; then
10915     eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
10916     if test -z "$LTCC"; then
10917       { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not look like a libtool script" >&5
10918 echo "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;}
10919     else
10920       { echo "$as_me:$LINENO: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5
10921 echo "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;}
10922     fi
10923   fi
10924
10925   # Extract list of available tagged configurations in $ofile.
10926   # Note that this assumes the entire list is on one line.
10927   available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
10928
10929   lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
10930   for tagname in $tagnames; do
10931     IFS="$lt_save_ifs"
10932     # Check whether tagname contains only valid characters
10933     case `$echo "X$tagname" | $Xsed -e 's:[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]::g'` in
10934     "") ;;
10935     *)  { { echo "$as_me:$LINENO: error: invalid tag name: $tagname" >&5
10936 echo "$as_me: error: invalid tag name: $tagname" >&2;}
10937    { (exit 1); exit 1; }; }
10938         ;;
10939     esac
10940
10941     if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
10942     then
10943       { { echo "$as_me:$LINENO: error: tag name \"$tagname\" already exists" >&5
10944 echo "$as_me: error: tag name \"$tagname\" already exists" >&2;}
10945    { (exit 1); exit 1; }; }
10946     fi
10947
10948     # Update the list of available tags.
10949     if test -n "$tagname"; then
10950       echo appending configuration tag \"$tagname\" to $ofile
10951
10952       case $tagname in
10953       CXX)
10954         if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
10955             ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
10956             (test "X$CXX" != "Xg++"))) ; then
10957           :
10958         else
10959           tagname=""
10960         fi
10961         ;;
10962
10963       F77)
10964         if test -n "$F77" && test "X$F77" != "Xno"; then
10965           :
10966         else
10967           tagname=""
10968         fi
10969         ;;
10970
10971       GCJ)
10972         if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
10973           :
10974         else
10975           tagname=""
10976         fi
10977         ;;
10978
10979       RC)
10980
10981
10982
10983 # Source file extension for RC test sources.
10984 ac_ext=rc
10985
10986 # Object file extension for compiled RC test sources.
10987 objext=o
10988 objext_RC=$objext
10989
10990 # Code to be used in simple compile tests
10991 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
10992
10993 # Code to be used in simple link tests
10994 lt_simple_link_test_code="$lt_simple_compile_test_code"
10995
10996 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
10997
10998 # If no C compiler was specified, use CC.
10999 LTCC=${LTCC-"$CC"}
11000
11001 # Allow CC to be a program name with arguments.
11002 compiler=$CC
11003
11004
11005 # save warnings/boilerplate of simple test code
11006 ac_outfile=conftest.$ac_objext
11007 printf "$lt_simple_compile_test_code" >conftest.$ac_ext
11008 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
11009 _lt_compiler_boilerplate=`cat conftest.err`
11010 $rm conftest*
11011
11012 ac_outfile=conftest.$ac_objext
11013 printf "$lt_simple_link_test_code" >conftest.$ac_ext
11014 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
11015 _lt_linker_boilerplate=`cat conftest.err`
11016 $rm conftest*
11017
11018
11019 # Allow CC to be a program name with arguments.
11020 lt_save_CC="$CC"
11021 CC=${RC-"windres"}
11022 compiler=$CC
11023 compiler_RC=$CC
11024 for cc_temp in $compiler""; do
11025   case $cc_temp in
11026     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
11027     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
11028     \-*) ;;
11029     *) break;;
11030   esac
11031 done
11032 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
11033
11034 lt_cv_prog_compiler_c_o_RC=yes
11035
11036 # The else clause should only fire when bootstrapping the
11037 # libtool distribution, otherwise you forgot to ship ltmain.sh
11038 # with your package, and you will get complaints that there are
11039 # no rules to generate ltmain.sh.
11040 if test -f "$ltmain"; then
11041   # See if we are running on zsh, and set the options which allow our commands through
11042   # without removal of \ escapes.
11043   if test -n "${ZSH_VERSION+set}" ; then
11044     setopt NO_GLOB_SUBST
11045   fi
11046   # Now quote all the things that may contain metacharacters while being
11047   # careful not to overquote the AC_SUBSTed values.  We take copies of the
11048   # variables and quote the copies for generation of the libtool script.
11049   for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
11050     SED SHELL STRIP \
11051     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
11052     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
11053     deplibs_check_method reload_flag reload_cmds need_locks \
11054     lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
11055     lt_cv_sys_global_symbol_to_c_name_address \
11056     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
11057     old_postinstall_cmds old_postuninstall_cmds \
11058     compiler_RC \
11059     CC_RC \
11060     LD_RC \
11061     lt_prog_compiler_wl_RC \
11062     lt_prog_compiler_pic_RC \
11063     lt_prog_compiler_static_RC \
11064     lt_prog_compiler_no_builtin_flag_RC \
11065     export_dynamic_flag_spec_RC \
11066     thread_safe_flag_spec_RC \
11067     whole_archive_flag_spec_RC \
11068     enable_shared_with_static_runtimes_RC \
11069     old_archive_cmds_RC \
11070     old_archive_from_new_cmds_RC \
11071     predep_objects_RC \
11072     postdep_objects_RC \
11073     predeps_RC \
11074     postdeps_RC \
11075     compiler_lib_search_path_RC \
11076     archive_cmds_RC \
11077     archive_expsym_cmds_RC \
11078     postinstall_cmds_RC \
11079     postuninstall_cmds_RC \
11080     old_archive_from_expsyms_cmds_RC \
11081     allow_undefined_flag_RC \
11082     no_undefined_flag_RC \
11083     export_symbols_cmds_RC \
11084     hardcode_libdir_flag_spec_RC \
11085     hardcode_libdir_flag_spec_ld_RC \
11086     hardcode_libdir_separator_RC \
11087     hardcode_automatic_RC \
11088     module_cmds_RC \
11089     module_expsym_cmds_RC \
11090     lt_cv_prog_compiler_c_o_RC \
11091     exclude_expsyms_RC \
11092     include_expsyms_RC; do
11093
11094     case $var in
11095     old_archive_cmds_RC | \
11096     old_archive_from_new_cmds_RC | \
11097     archive_cmds_RC | \
11098     archive_expsym_cmds_RC | \
11099     module_cmds_RC | \
11100     module_expsym_cmds_RC | \
11101     old_archive_from_expsyms_cmds_RC | \
11102     export_symbols_cmds_RC | \
11103     extract_expsyms_cmds | reload_cmds | finish_cmds | \
11104     postinstall_cmds | postuninstall_cmds | \
11105     old_postinstall_cmds | old_postuninstall_cmds | \
11106     sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
11107       # Double-quote double-evaled strings.
11108       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
11109       ;;
11110     *)
11111       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
11112       ;;
11113     esac
11114   done
11115
11116   case $lt_echo in
11117   *'\$0 --fallback-echo"')
11118     lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
11119     ;;
11120   esac
11121
11122 cfgfile="$ofile"
11123
11124   cat <<__EOF__ >> "$cfgfile"
11125 # ### BEGIN LIBTOOL TAG CONFIG: $tagname
11126
11127 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
11128
11129 # Shell to use when invoking shell scripts.
11130 SHELL=$lt_SHELL
11131
11132 # Whether or not to build shared libraries.
11133 build_libtool_libs=$enable_shared
11134
11135 # Whether or not to build static libraries.
11136 build_old_libs=$enable_static
11137
11138 # Whether or not to add -lc for building shared libraries.
11139 build_libtool_need_lc=$archive_cmds_need_lc_RC
11140
11141 # Whether or not to disallow shared libs when runtime libs are static
11142 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_RC
11143
11144 # Whether or not to optimize for fast installation.
11145 fast_install=$enable_fast_install
11146
11147 # The host system.
11148 host_alias=$host_alias
11149 host=$host
11150 host_os=$host_os
11151
11152 # The build system.
11153 build_alias=$build_alias
11154 build=$build
11155 build_os=$build_os
11156
11157 # An echo program that does not interpret backslashes.
11158 echo=$lt_echo
11159
11160 # The archiver.
11161 AR=$lt_AR
11162 AR_FLAGS=$lt_AR_FLAGS
11163
11164 # A C compiler.
11165 LTCC=$lt_LTCC
11166
11167 # A language-specific compiler.
11168 CC=$lt_compiler_RC
11169
11170 # Is the compiler the GNU C compiler?
11171 with_gcc=$GCC_RC
11172
11173 # An ERE matcher.
11174 EGREP=$lt_EGREP
11175
11176 # The linker used to build libraries.
11177 LD=$lt_LD_RC
11178
11179 # Whether we need hard or soft links.
11180 LN_S=$lt_LN_S
11181
11182 # A BSD-compatible nm program.
11183 NM=$lt_NM
11184
11185 # A symbol stripping program
11186 STRIP=$lt_STRIP
11187
11188 # Used to examine libraries when file_magic_cmd begins "file"
11189 MAGIC_CMD=$MAGIC_CMD
11190
11191 # Used on cygwin: DLL creation program.
11192 DLLTOOL="$DLLTOOL"
11193
11194 # Used on cygwin: object dumper.
11195 OBJDUMP="$OBJDUMP"
11196
11197 # Used on cygwin: assembler.
11198 AS="$AS"
11199
11200 # The name of the directory that contains temporary libtool files.
11201 objdir=$objdir
11202
11203 # How to create reloadable object files.
11204 reload_flag=$lt_reload_flag
11205 reload_cmds=$lt_reload_cmds
11206
11207 # How to pass a linker flag through the compiler.
11208 wl=$lt_lt_prog_compiler_wl_RC
11209
11210 # Object file suffix (normally "o").
11211 objext="$ac_objext"
11212
11213 # Old archive suffix (normally "a").
11214 libext="$libext"
11215
11216 # Shared library suffix (normally ".so").
11217 shrext_cmds='$shrext_cmds'
11218
11219 # Executable file suffix (normally "").
11220 exeext="$exeext"
11221
11222 # Additional compiler flags for building library objects.
11223 pic_flag=$lt_lt_prog_compiler_pic_RC
11224 pic_mode=$pic_mode
11225
11226 # What is the maximum length of a command?
11227 max_cmd_len=$lt_cv_sys_max_cmd_len
11228
11229 # Does compiler simultaneously support -c and -o options?
11230 compiler_c_o=$lt_lt_cv_prog_compiler_c_o_RC
11231
11232 # Must we lock files when doing compilation?
11233 need_locks=$lt_need_locks
11234
11235 # Do we need the lib prefix for modules?
11236 need_lib_prefix=$need_lib_prefix
11237
11238 # Do we need a version for libraries?
11239 need_version=$need_version
11240
11241 # Whether dlopen is supported.
11242 dlopen_support=$enable_dlopen
11243
11244 # Whether dlopen of programs is supported.
11245 dlopen_self=$enable_dlopen_self
11246
11247 # Whether dlopen of statically linked programs is supported.
11248 dlopen_self_static=$enable_dlopen_self_static
11249
11250 # Compiler flag to prevent dynamic linking.
11251 link_static_flag=$lt_lt_prog_compiler_static_RC
11252
11253 # Compiler flag to turn off builtin functions.
11254 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_RC
11255
11256 # Compiler flag to allow reflexive dlopens.
11257 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_RC
11258
11259 # Compiler flag to generate shared objects directly from archives.
11260 whole_archive_flag_spec=$lt_whole_archive_flag_spec_RC
11261
11262 # Compiler flag to generate thread-safe objects.
11263 thread_safe_flag_spec=$lt_thread_safe_flag_spec_RC
11264
11265 # Library versioning type.
11266 version_type=$version_type
11267
11268 # Format of library name prefix.
11269 libname_spec=$lt_libname_spec
11270
11271 # List of archive names.  First name is the real one, the rest are links.
11272 # The last name is the one that the linker finds with -lNAME.
11273 library_names_spec=$lt_library_names_spec
11274
11275 # The coded name of the library, if different from the real name.
11276 soname_spec=$lt_soname_spec
11277
11278 # Commands used to build and install an old-style archive.
11279 RANLIB=$lt_RANLIB
11280 old_archive_cmds=$lt_old_archive_cmds_RC
11281 old_postinstall_cmds=$lt_old_postinstall_cmds
11282 old_postuninstall_cmds=$lt_old_postuninstall_cmds
11283
11284 # Create an old-style archive from a shared archive.
11285 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_RC
11286
11287 # Create a temporary old-style archive to link instead of a shared archive.
11288 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_RC
11289
11290 # Commands used to build and install a shared archive.
11291 archive_cmds=$lt_archive_cmds_RC
11292 archive_expsym_cmds=$lt_archive_expsym_cmds_RC
11293 postinstall_cmds=$lt_postinstall_cmds
11294 postuninstall_cmds=$lt_postuninstall_cmds
11295
11296 # Commands used to build a loadable module (assumed same as above if empty)
11297 module_cmds=$lt_module_cmds_RC
11298 module_expsym_cmds=$lt_module_expsym_cmds_RC
11299
11300 # Commands to strip libraries.
11301 old_striplib=$lt_old_striplib
11302 striplib=$lt_striplib
11303
11304 # Dependencies to place before the objects being linked to create a
11305 # shared library.
11306 predep_objects=$lt_predep_objects_RC
11307
11308 # Dependencies to place after the objects being linked to create a
11309 # shared library.
11310 postdep_objects=$lt_postdep_objects_RC
11311
11312 # Dependencies to place before the objects being linked to create a
11313 # shared library.
11314 predeps=$lt_predeps_RC
11315
11316 # Dependencies to place after the objects being linked to create a
11317 # shared library.
11318 postdeps=$lt_postdeps_RC
11319
11320 # The library search path used internally by the compiler when linking
11321 # a shared library.
11322 compiler_lib_search_path=$lt_compiler_lib_search_path_RC
11323
11324 # Method to check whether dependent libraries are shared objects.
11325 deplibs_check_method=$lt_deplibs_check_method
11326
11327 # Command to use when deplibs_check_method == file_magic.
11328 file_magic_cmd=$lt_file_magic_cmd
11329
11330 # Flag that allows shared libraries with undefined symbols to be built.
11331 allow_undefined_flag=$lt_allow_undefined_flag_RC
11332
11333 # Flag that forces no undefined symbols.
11334 no_undefined_flag=$lt_no_undefined_flag_RC
11335
11336 # Commands used to finish a libtool library installation in a directory.
11337 finish_cmds=$lt_finish_cmds
11338
11339 # Same as above, but a single script fragment to be evaled but not shown.
11340 finish_eval=$lt_finish_eval
11341
11342 # Take the output of nm and produce a listing of raw symbols and C names.
11343 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
11344
11345 # Transform the output of nm in a proper C declaration
11346 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
11347
11348 # Transform the output of nm in a C name address pair
11349 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
11350
11351 # This is the shared library runtime path variable.
11352 runpath_var=$runpath_var
11353
11354 # This is the shared library path variable.
11355 shlibpath_var=$shlibpath_var
11356
11357 # Is shlibpath searched before the hard-coded library search path?
11358 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
11359
11360 # How to hardcode a shared library path into an executable.
11361 hardcode_action=$hardcode_action_RC
11362
11363 # Whether we should hardcode library paths into libraries.
11364 hardcode_into_libs=$hardcode_into_libs
11365
11366 # Flag to hardcode \$libdir into a binary during linking.
11367 # This must work even if \$libdir does not exist.
11368 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_RC
11369
11370 # If ld is used when linking, flag to hardcode \$libdir into
11371 # a binary during linking. This must work even if \$libdir does
11372 # not exist.
11373 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_RC
11374
11375 # Whether we need a single -rpath flag with a separated argument.
11376 hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC
11377
11378 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
11379 # resulting binary.
11380 hardcode_direct=$hardcode_direct_RC
11381
11382 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
11383 # resulting binary.
11384 hardcode_minus_L=$hardcode_minus_L_RC
11385
11386 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
11387 # the resulting binary.
11388 hardcode_shlibpath_var=$hardcode_shlibpath_var_RC
11389
11390 # Set to yes if building a shared library automatically hardcodes DIR into the library
11391 # and all subsequent libraries and executables linked against it.
11392 hardcode_automatic=$hardcode_automatic_RC
11393
11394 # Variables whose values should be saved in libtool wrapper scripts and
11395 # restored at relink time.
11396 variables_saved_for_relink="$variables_saved_for_relink"
11397
11398 # Whether libtool must link a program against all its dependency libraries.
11399 link_all_deplibs=$link_all_deplibs_RC
11400
11401 # Compile-time system search path for libraries
11402 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
11403
11404 # Run-time system search path for libraries
11405 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
11406
11407 # Fix the shell variable \$srcfile for the compiler.
11408 fix_srcfile_path="$fix_srcfile_path_RC"
11409
11410 # Set to yes if exported symbols are required.
11411 always_export_symbols=$always_export_symbols_RC
11412
11413 # The commands to list exported symbols.
11414 export_symbols_cmds=$lt_export_symbols_cmds_RC
11415
11416 # The commands to extract the exported symbol list from a shared archive.
11417 extract_expsyms_cmds=$lt_extract_expsyms_cmds
11418
11419 # Symbols that should not be listed in the preloaded symbols.
11420 exclude_expsyms=$lt_exclude_expsyms_RC
11421
11422 # Symbols that must always be exported.
11423 include_expsyms=$lt_include_expsyms_RC
11424
11425 # ### END LIBTOOL TAG CONFIG: $tagname
11426
11427 __EOF__
11428
11429
11430 else
11431   # If there is no Makefile yet, we rely on a make rule to execute
11432   # `config.status --recheck' to rerun these tests and create the
11433   # libtool script then.
11434   ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
11435   if test -f "$ltmain_in"; then
11436     test -f Makefile && make "$ltmain"
11437   fi
11438 fi
11439
11440
11441 ac_ext=c
11442 ac_cpp='$CPP $CPPFLAGS'
11443 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11444 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11445 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11446
11447 CC="$lt_save_CC"
11448
11449         ;;
11450
11451       *)
11452         { { echo "$as_me:$LINENO: error: Unsupported tag name: $tagname" >&5
11453 echo "$as_me: error: Unsupported tag name: $tagname" >&2;}
11454    { (exit 1); exit 1; }; }
11455         ;;
11456       esac
11457
11458       # Append the new tag name to the list of available tags.
11459       if test -n "$tagname" ; then
11460       available_tags="$available_tags $tagname"
11461     fi
11462     fi
11463   done
11464   IFS="$lt_save_ifs"
11465
11466   # Now substitute the updated list of available tags.
11467   if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
11468     mv "${ofile}T" "$ofile"
11469     chmod +x "$ofile"
11470   else
11471     rm -f "${ofile}T"
11472     { { echo "$as_me:$LINENO: error: unable to update list of available tagged configurations." >&5
11473 echo "$as_me: error: unable to update list of available tagged configurations." >&2;}
11474    { (exit 1); exit 1; }; }
11475   fi
11476 fi
11477
11478
11479
11480 # This can be used to rebuild libtool when needed
11481 LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
11482
11483 # Always use our own libtool.
11484 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
11485
11486 # Prevent multiple expansion
11487
11488
11489
11490
11491
11492
11493
11494
11495
11496
11497 ol_link_perl=no
11498 if test $ol_enable_perl != no ; then
11499         # Extract the first word of "perl", so it can be a program name with args.
11500 set dummy perl; ac_word=$2
11501 echo "$as_me:$LINENO: checking for $ac_word" >&5
11502 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11503 if test "${ac_cv_path_PERLBIN+set}" = set; then
11504   echo $ECHO_N "(cached) $ECHO_C" >&6
11505 else
11506   case $PERLBIN in
11507   [\\/]* | ?:[\\/]*)
11508   ac_cv_path_PERLBIN="$PERLBIN" # Let the user override the test with a path.
11509   ;;
11510   *)
11511   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11512 for as_dir in $PATH
11513 do
11514   IFS=$as_save_IFS
11515   test -z "$as_dir" && as_dir=.
11516   for ac_exec_ext in '' $ac_executable_extensions; do
11517   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11518     ac_cv_path_PERLBIN="$as_dir/$ac_word$ac_exec_ext"
11519     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11520     break 2
11521   fi
11522 done
11523 done
11524
11525   test -z "$ac_cv_path_PERLBIN" && ac_cv_path_PERLBIN="/usr/bin/perl"
11526   ;;
11527 esac
11528 fi
11529 PERLBIN=$ac_cv_path_PERLBIN
11530
11531 if test -n "$PERLBIN"; then
11532   echo "$as_me:$LINENO: result: $PERLBIN" >&5
11533 echo "${ECHO_T}$PERLBIN" >&6
11534 else
11535   echo "$as_me:$LINENO: result: no" >&5
11536 echo "${ECHO_T}no" >&6
11537 fi
11538
11539
11540         if test "no$PERLBIN" = "no" ; then
11541                 if test $ol_enable_perl = yes ; then
11542                         { { echo "$as_me:$LINENO: error: could not locate perl" >&5
11543 echo "$as_me: error: could not locate perl" >&2;}
11544    { (exit 1); exit 1; }; }
11545                 fi
11546
11547         else
11548                 PERL_CPPFLAGS="`$PERLBIN -MExtUtils::Embed -e ccopts`"
11549                 PERL_LDFLAGS="`$PERLBIN -MExtUtils::Embed -e ldopts|sed -e 's/ -lc / /' -e 's/ -lc$//'`"
11550
11551                 if test x"$ol_enable_perl" = "xyes" ; then
11552                         SLAPD_PERL_LDFLAGS="$PERL_LDFLAGS"
11553                 else
11554                         MOD_PERL_LDFLAGS="$PERL_LDFLAGS"
11555                 fi
11556                                 ol_link_perl=yes
11557         fi
11558 fi
11559
11560 ac_ext=c
11561 ac_cpp='$CPP $CPPFLAGS'
11562 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11563 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11564 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11565 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
11566 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
11567 # On Suns, sometimes $CPP names a directory.
11568 if test -n "$CPP" && test -d "$CPP"; then
11569   CPP=
11570 fi
11571 if test -z "$CPP"; then
11572   if test "${ac_cv_prog_CPP+set}" = set; then
11573   echo $ECHO_N "(cached) $ECHO_C" >&6
11574 else
11575       # Double quotes because CPP needs to be expanded
11576     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
11577     do
11578       ac_preproc_ok=false
11579 for ac_c_preproc_warn_flag in '' yes
11580 do
11581   # Use a header file that comes with gcc, so configuring glibc
11582   # with a fresh cross-compiler works.
11583   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11584   # <limits.h> exists even on freestanding compilers.
11585   # On the NeXT, cc -E runs the code through the compiler's parser,
11586   # not just through cpp. "Syntax error" is here to catch this case.
11587   cat >conftest.$ac_ext <<_ACEOF
11588 /* confdefs.h.  */
11589 _ACEOF
11590 cat confdefs.h >>conftest.$ac_ext
11591 cat >>conftest.$ac_ext <<_ACEOF
11592 /* end confdefs.h.  */
11593 #ifdef __STDC__
11594 # include <limits.h>
11595 #else
11596 # include <assert.h>
11597 #endif
11598                      Syntax error
11599 _ACEOF
11600 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11601   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11602   ac_status=$?
11603   grep -v '^ *+' conftest.er1 >conftest.err
11604   rm -f conftest.er1
11605   cat conftest.err >&5
11606   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11607   (exit $ac_status); } >/dev/null; then
11608   if test -s conftest.err; then
11609     ac_cpp_err=$ac_c_preproc_warn_flag
11610     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11611   else
11612     ac_cpp_err=
11613   fi
11614 else
11615   ac_cpp_err=yes
11616 fi
11617 if test -z "$ac_cpp_err"; then
11618   :
11619 else
11620   echo "$as_me: failed program was:" >&5
11621 sed 's/^/| /' conftest.$ac_ext >&5
11622
11623   # Broken: fails on valid input.
11624 continue
11625 fi
11626 rm -f conftest.err conftest.$ac_ext
11627
11628   # OK, works on sane cases.  Now check whether non-existent headers
11629   # can be detected and how.
11630   cat >conftest.$ac_ext <<_ACEOF
11631 /* confdefs.h.  */
11632 _ACEOF
11633 cat confdefs.h >>conftest.$ac_ext
11634 cat >>conftest.$ac_ext <<_ACEOF
11635 /* end confdefs.h.  */
11636 #include <ac_nonexistent.h>
11637 _ACEOF
11638 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11639   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11640   ac_status=$?
11641   grep -v '^ *+' conftest.er1 >conftest.err
11642   rm -f conftest.er1
11643   cat conftest.err >&5
11644   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11645   (exit $ac_status); } >/dev/null; then
11646   if test -s conftest.err; then
11647     ac_cpp_err=$ac_c_preproc_warn_flag
11648     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11649   else
11650     ac_cpp_err=
11651   fi
11652 else
11653   ac_cpp_err=yes
11654 fi
11655 if test -z "$ac_cpp_err"; then
11656   # Broken: success on invalid input.
11657 continue
11658 else
11659   echo "$as_me: failed program was:" >&5
11660 sed 's/^/| /' conftest.$ac_ext >&5
11661
11662   # Passes both tests.
11663 ac_preproc_ok=:
11664 break
11665 fi
11666 rm -f conftest.err conftest.$ac_ext
11667
11668 done
11669 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
11670 rm -f conftest.err conftest.$ac_ext
11671 if $ac_preproc_ok; then
11672   break
11673 fi
11674
11675     done
11676     ac_cv_prog_CPP=$CPP
11677
11678 fi
11679   CPP=$ac_cv_prog_CPP
11680 else
11681   ac_cv_prog_CPP=$CPP
11682 fi
11683 echo "$as_me:$LINENO: result: $CPP" >&5
11684 echo "${ECHO_T}$CPP" >&6
11685 ac_preproc_ok=false
11686 for ac_c_preproc_warn_flag in '' yes
11687 do
11688   # Use a header file that comes with gcc, so configuring glibc
11689   # with a fresh cross-compiler works.
11690   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11691   # <limits.h> exists even on freestanding compilers.
11692   # On the NeXT, cc -E runs the code through the compiler's parser,
11693   # not just through cpp. "Syntax error" is here to catch this case.
11694   cat >conftest.$ac_ext <<_ACEOF
11695 /* confdefs.h.  */
11696 _ACEOF
11697 cat confdefs.h >>conftest.$ac_ext
11698 cat >>conftest.$ac_ext <<_ACEOF
11699 /* end confdefs.h.  */
11700 #ifdef __STDC__
11701 # include <limits.h>
11702 #else
11703 # include <assert.h>
11704 #endif
11705                      Syntax error
11706 _ACEOF
11707 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11708   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11709   ac_status=$?
11710   grep -v '^ *+' conftest.er1 >conftest.err
11711   rm -f conftest.er1
11712   cat conftest.err >&5
11713   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11714   (exit $ac_status); } >/dev/null; then
11715   if test -s conftest.err; then
11716     ac_cpp_err=$ac_c_preproc_warn_flag
11717     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11718   else
11719     ac_cpp_err=
11720   fi
11721 else
11722   ac_cpp_err=yes
11723 fi
11724 if test -z "$ac_cpp_err"; then
11725   :
11726 else
11727   echo "$as_me: failed program was:" >&5
11728 sed 's/^/| /' conftest.$ac_ext >&5
11729
11730   # Broken: fails on valid input.
11731 continue
11732 fi
11733 rm -f conftest.err conftest.$ac_ext
11734
11735   # OK, works on sane cases.  Now check whether non-existent headers
11736   # can be detected and how.
11737   cat >conftest.$ac_ext <<_ACEOF
11738 /* confdefs.h.  */
11739 _ACEOF
11740 cat confdefs.h >>conftest.$ac_ext
11741 cat >>conftest.$ac_ext <<_ACEOF
11742 /* end confdefs.h.  */
11743 #include <ac_nonexistent.h>
11744 _ACEOF
11745 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11746   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11747   ac_status=$?
11748   grep -v '^ *+' conftest.er1 >conftest.err
11749   rm -f conftest.er1
11750   cat conftest.err >&5
11751   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11752   (exit $ac_status); } >/dev/null; then
11753   if test -s conftest.err; then
11754     ac_cpp_err=$ac_c_preproc_warn_flag
11755     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11756   else
11757     ac_cpp_err=
11758   fi
11759 else
11760   ac_cpp_err=yes
11761 fi
11762 if test -z "$ac_cpp_err"; then
11763   # Broken: success on invalid input.
11764 continue
11765 else
11766   echo "$as_me: failed program was:" >&5
11767 sed 's/^/| /' conftest.$ac_ext >&5
11768
11769   # Passes both tests.
11770 ac_preproc_ok=:
11771 break
11772 fi
11773 rm -f conftest.err conftest.$ac_ext
11774
11775 done
11776 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
11777 rm -f conftest.err conftest.$ac_ext
11778 if $ac_preproc_ok; then
11779   :
11780 else
11781   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
11782 See \`config.log' for more details." >&5
11783 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
11784 See \`config.log' for more details." >&2;}
11785    { (exit 1); exit 1; }; }
11786 fi
11787
11788 ac_ext=c
11789 ac_cpp='$CPP $CPPFLAGS'
11790 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11791 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11792 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11793
11794
11795 case $host_os in
11796   *mingw32* ) ac_cv_mingw32=yes ;;
11797   *cygwin* ) ac_cv_cygwin=yes ;;
11798 esac
11799
11800
11801
11802
11803 cat >>confdefs.h <<_ACEOF
11804 #define EXEEXT "${EXEEXT}"
11805 _ACEOF
11806
11807
11808 echo "$as_me:$LINENO: checking for be_app in -lbe" >&5
11809 echo $ECHO_N "checking for be_app in -lbe... $ECHO_C" >&6
11810 if test "${ac_cv_lib_be_be_app+set}" = set; then
11811   echo $ECHO_N "(cached) $ECHO_C" >&6
11812 else
11813   ac_check_lib_save_LIBS=$LIBS
11814 LIBS="-lbe -lroot -lnet $LIBS"
11815 cat >conftest.$ac_ext <<_ACEOF
11816 /* confdefs.h.  */
11817 _ACEOF
11818 cat confdefs.h >>conftest.$ac_ext
11819 cat >>conftest.$ac_ext <<_ACEOF
11820 /* end confdefs.h.  */
11821
11822 /* Override any gcc2 internal prototype to avoid an error.  */
11823 #ifdef __cplusplus
11824 extern "C"
11825 #endif
11826 /* We use char because int might match the return type of a gcc2
11827    builtin and then its argument prototype would still apply.  */
11828 char be_app ();
11829 int
11830 main ()
11831 {
11832 be_app ();
11833   ;
11834   return 0;
11835 }
11836 _ACEOF
11837 rm -f conftest.$ac_objext conftest$ac_exeext
11838 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11839   (eval $ac_link) 2>conftest.er1
11840   ac_status=$?
11841   grep -v '^ *+' conftest.er1 >conftest.err
11842   rm -f conftest.er1
11843   cat conftest.err >&5
11844   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11845   (exit $ac_status); } &&
11846          { ac_try='test -z "$ac_c_werror_flag"
11847                          || test ! -s conftest.err'
11848   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11849   (eval $ac_try) 2>&5
11850   ac_status=$?
11851   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11852   (exit $ac_status); }; } &&
11853          { ac_try='test -s conftest$ac_exeext'
11854   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11855   (eval $ac_try) 2>&5
11856   ac_status=$?
11857   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11858   (exit $ac_status); }; }; then
11859   ac_cv_lib_be_be_app=yes
11860 else
11861   echo "$as_me: failed program was:" >&5
11862 sed 's/^/| /' conftest.$ac_ext >&5
11863
11864 ac_cv_lib_be_be_app=no
11865 fi
11866 rm -f conftest.err conftest.$ac_objext \
11867       conftest$ac_exeext conftest.$ac_ext
11868 LIBS=$ac_check_lib_save_LIBS
11869 fi
11870 echo "$as_me:$LINENO: result: $ac_cv_lib_be_be_app" >&5
11871 echo "${ECHO_T}$ac_cv_lib_be_be_app" >&6
11872 if test $ac_cv_lib_be_be_app = yes; then
11873   LIBS="$LIBS -lbe -lroot -lnet"
11874 else
11875   :
11876 fi
11877
11878
11879 ac_ext=c
11880 ac_cpp='$CPP $CPPFLAGS'
11881 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11882 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11883 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11884 if test -n "$ac_tool_prefix"; then
11885   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
11886 set dummy ${ac_tool_prefix}gcc; ac_word=$2
11887 echo "$as_me:$LINENO: checking for $ac_word" >&5
11888 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11889 if test "${ac_cv_prog_CC+set}" = set; then
11890   echo $ECHO_N "(cached) $ECHO_C" >&6
11891 else
11892   if test -n "$CC"; then
11893   ac_cv_prog_CC="$CC" # Let the user override the test.
11894 else
11895 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11896 for as_dir in $PATH
11897 do
11898   IFS=$as_save_IFS
11899   test -z "$as_dir" && as_dir=.
11900   for ac_exec_ext in '' $ac_executable_extensions; do
11901   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11902     ac_cv_prog_CC="${ac_tool_prefix}gcc"
11903     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11904     break 2
11905   fi
11906 done
11907 done
11908
11909 fi
11910 fi
11911 CC=$ac_cv_prog_CC
11912 if test -n "$CC"; then
11913   echo "$as_me:$LINENO: result: $CC" >&5
11914 echo "${ECHO_T}$CC" >&6
11915 else
11916   echo "$as_me:$LINENO: result: no" >&5
11917 echo "${ECHO_T}no" >&6
11918 fi
11919
11920 fi
11921 if test -z "$ac_cv_prog_CC"; then
11922   ac_ct_CC=$CC
11923   # Extract the first word of "gcc", so it can be a program name with args.
11924 set dummy gcc; ac_word=$2
11925 echo "$as_me:$LINENO: checking for $ac_word" >&5
11926 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11927 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
11928   echo $ECHO_N "(cached) $ECHO_C" >&6
11929 else
11930   if test -n "$ac_ct_CC"; then
11931   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
11932 else
11933 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11934 for as_dir in $PATH
11935 do
11936   IFS=$as_save_IFS
11937   test -z "$as_dir" && as_dir=.
11938   for ac_exec_ext in '' $ac_executable_extensions; do
11939   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11940     ac_cv_prog_ac_ct_CC="gcc"
11941     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11942     break 2
11943   fi
11944 done
11945 done
11946
11947 fi
11948 fi
11949 ac_ct_CC=$ac_cv_prog_ac_ct_CC
11950 if test -n "$ac_ct_CC"; then
11951   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
11952 echo "${ECHO_T}$ac_ct_CC" >&6
11953 else
11954   echo "$as_me:$LINENO: result: no" >&5
11955 echo "${ECHO_T}no" >&6
11956 fi
11957
11958   CC=$ac_ct_CC
11959 else
11960   CC="$ac_cv_prog_CC"
11961 fi
11962
11963 if test -z "$CC"; then
11964   if test -n "$ac_tool_prefix"; then
11965   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
11966 set dummy ${ac_tool_prefix}cc; ac_word=$2
11967 echo "$as_me:$LINENO: checking for $ac_word" >&5
11968 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11969 if test "${ac_cv_prog_CC+set}" = set; then
11970   echo $ECHO_N "(cached) $ECHO_C" >&6
11971 else
11972   if test -n "$CC"; then
11973   ac_cv_prog_CC="$CC" # Let the user override the test.
11974 else
11975 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11976 for as_dir in $PATH
11977 do
11978   IFS=$as_save_IFS
11979   test -z "$as_dir" && as_dir=.
11980   for ac_exec_ext in '' $ac_executable_extensions; do
11981   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11982     ac_cv_prog_CC="${ac_tool_prefix}cc"
11983     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11984     break 2
11985   fi
11986 done
11987 done
11988
11989 fi
11990 fi
11991 CC=$ac_cv_prog_CC
11992 if test -n "$CC"; then
11993   echo "$as_me:$LINENO: result: $CC" >&5
11994 echo "${ECHO_T}$CC" >&6
11995 else
11996   echo "$as_me:$LINENO: result: no" >&5
11997 echo "${ECHO_T}no" >&6
11998 fi
11999
12000 fi
12001 if test -z "$ac_cv_prog_CC"; then
12002   ac_ct_CC=$CC
12003   # Extract the first word of "cc", so it can be a program name with args.
12004 set dummy cc; ac_word=$2
12005 echo "$as_me:$LINENO: checking for $ac_word" >&5
12006 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12007 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
12008   echo $ECHO_N "(cached) $ECHO_C" >&6
12009 else
12010   if test -n "$ac_ct_CC"; then
12011   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
12012 else
12013 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12014 for as_dir in $PATH
12015 do
12016   IFS=$as_save_IFS
12017   test -z "$as_dir" && as_dir=.
12018   for ac_exec_ext in '' $ac_executable_extensions; do
12019   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12020     ac_cv_prog_ac_ct_CC="cc"
12021     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12022     break 2
12023   fi
12024 done
12025 done
12026
12027 fi
12028 fi
12029 ac_ct_CC=$ac_cv_prog_ac_ct_CC
12030 if test -n "$ac_ct_CC"; then
12031   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
12032 echo "${ECHO_T}$ac_ct_CC" >&6
12033 else
12034   echo "$as_me:$LINENO: result: no" >&5
12035 echo "${ECHO_T}no" >&6
12036 fi
12037
12038   CC=$ac_ct_CC
12039 else
12040   CC="$ac_cv_prog_CC"
12041 fi
12042
12043 fi
12044 if test -z "$CC"; then
12045   # Extract the first word of "cc", so it can be a program name with args.
12046 set dummy cc; ac_word=$2
12047 echo "$as_me:$LINENO: checking for $ac_word" >&5
12048 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12049 if test "${ac_cv_prog_CC+set}" = set; then
12050   echo $ECHO_N "(cached) $ECHO_C" >&6
12051 else
12052   if test -n "$CC"; then
12053   ac_cv_prog_CC="$CC" # Let the user override the test.
12054 else
12055   ac_prog_rejected=no
12056 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12057 for as_dir in $PATH
12058 do
12059   IFS=$as_save_IFS
12060   test -z "$as_dir" && as_dir=.
12061   for ac_exec_ext in '' $ac_executable_extensions; do
12062   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12063     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
12064        ac_prog_rejected=yes
12065        continue
12066      fi
12067     ac_cv_prog_CC="cc"
12068     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12069     break 2
12070   fi
12071 done
12072 done
12073
12074 if test $ac_prog_rejected = yes; then
12075   # We found a bogon in the path, so make sure we never use it.
12076   set dummy $ac_cv_prog_CC
12077   shift
12078   if test $# != 0; then
12079     # We chose a different compiler from the bogus one.
12080     # However, it has the same basename, so the bogon will be chosen
12081     # first if we set CC to just the basename; use the full file name.
12082     shift
12083     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
12084   fi
12085 fi
12086 fi
12087 fi
12088 CC=$ac_cv_prog_CC
12089 if test -n "$CC"; then
12090   echo "$as_me:$LINENO: result: $CC" >&5
12091 echo "${ECHO_T}$CC" >&6
12092 else
12093   echo "$as_me:$LINENO: result: no" >&5
12094 echo "${ECHO_T}no" >&6
12095 fi
12096
12097 fi
12098 if test -z "$CC"; then
12099   if test -n "$ac_tool_prefix"; then
12100   for ac_prog in cl
12101   do
12102     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
12103 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
12104 echo "$as_me:$LINENO: checking for $ac_word" >&5
12105 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12106 if test "${ac_cv_prog_CC+set}" = set; then
12107   echo $ECHO_N "(cached) $ECHO_C" >&6
12108 else
12109   if test -n "$CC"; then
12110   ac_cv_prog_CC="$CC" # Let the user override the test.
12111 else
12112 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12113 for as_dir in $PATH
12114 do
12115   IFS=$as_save_IFS
12116   test -z "$as_dir" && as_dir=.
12117   for ac_exec_ext in '' $ac_executable_extensions; do
12118   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12119     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
12120     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12121     break 2
12122   fi
12123 done
12124 done
12125
12126 fi
12127 fi
12128 CC=$ac_cv_prog_CC
12129 if test -n "$CC"; then
12130   echo "$as_me:$LINENO: result: $CC" >&5
12131 echo "${ECHO_T}$CC" >&6
12132 else
12133   echo "$as_me:$LINENO: result: no" >&5
12134 echo "${ECHO_T}no" >&6
12135 fi
12136
12137     test -n "$CC" && break
12138   done
12139 fi
12140 if test -z "$CC"; then
12141   ac_ct_CC=$CC
12142   for ac_prog in cl
12143 do
12144   # Extract the first word of "$ac_prog", so it can be a program name with args.
12145 set dummy $ac_prog; ac_word=$2
12146 echo "$as_me:$LINENO: checking for $ac_word" >&5
12147 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12148 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
12149   echo $ECHO_N "(cached) $ECHO_C" >&6
12150 else
12151   if test -n "$ac_ct_CC"; then
12152   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
12153 else
12154 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12155 for as_dir in $PATH
12156 do
12157   IFS=$as_save_IFS
12158   test -z "$as_dir" && as_dir=.
12159   for ac_exec_ext in '' $ac_executable_extensions; do
12160   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12161     ac_cv_prog_ac_ct_CC="$ac_prog"
12162     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12163     break 2
12164   fi
12165 done
12166 done
12167
12168 fi
12169 fi
12170 ac_ct_CC=$ac_cv_prog_ac_ct_CC
12171 if test -n "$ac_ct_CC"; then
12172   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
12173 echo "${ECHO_T}$ac_ct_CC" >&6
12174 else
12175   echo "$as_me:$LINENO: result: no" >&5
12176 echo "${ECHO_T}no" >&6
12177 fi
12178
12179   test -n "$ac_ct_CC" && break
12180 done
12181
12182   CC=$ac_ct_CC
12183 fi
12184
12185 fi
12186
12187
12188 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
12189 See \`config.log' for more details." >&5
12190 echo "$as_me: error: no acceptable C compiler found in \$PATH
12191 See \`config.log' for more details." >&2;}
12192    { (exit 1); exit 1; }; }
12193
12194 # Provide some information about the compiler.
12195 echo "$as_me:$LINENO:" \
12196      "checking for C compiler version" >&5
12197 ac_compiler=`set X $ac_compile; echo $2`
12198 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
12199   (eval $ac_compiler --version </dev/null >&5) 2>&5
12200   ac_status=$?
12201   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12202   (exit $ac_status); }
12203 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
12204   (eval $ac_compiler -v </dev/null >&5) 2>&5
12205   ac_status=$?
12206   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12207   (exit $ac_status); }
12208 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
12209   (eval $ac_compiler -V </dev/null >&5) 2>&5
12210   ac_status=$?
12211   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12212   (exit $ac_status); }
12213
12214 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
12215 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
12216 if test "${ac_cv_c_compiler_gnu+set}" = set; then
12217   echo $ECHO_N "(cached) $ECHO_C" >&6
12218 else
12219   cat >conftest.$ac_ext <<_ACEOF
12220 /* confdefs.h.  */
12221 _ACEOF
12222 cat confdefs.h >>conftest.$ac_ext
12223 cat >>conftest.$ac_ext <<_ACEOF
12224 /* end confdefs.h.  */
12225
12226 int
12227 main ()
12228 {
12229 #ifndef __GNUC__
12230        choke me
12231 #endif
12232
12233   ;
12234   return 0;
12235 }
12236 _ACEOF
12237 rm -f conftest.$ac_objext
12238 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12239   (eval $ac_compile) 2>conftest.er1
12240   ac_status=$?
12241   grep -v '^ *+' conftest.er1 >conftest.err
12242   rm -f conftest.er1
12243   cat conftest.err >&5
12244   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12245   (exit $ac_status); } &&
12246          { ac_try='test -z "$ac_c_werror_flag"
12247                          || test ! -s conftest.err'
12248   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12249   (eval $ac_try) 2>&5
12250   ac_status=$?
12251   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12252   (exit $ac_status); }; } &&
12253          { ac_try='test -s conftest.$ac_objext'
12254   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12255   (eval $ac_try) 2>&5
12256   ac_status=$?
12257   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12258   (exit $ac_status); }; }; then
12259   ac_compiler_gnu=yes
12260 else
12261   echo "$as_me: failed program was:" >&5
12262 sed 's/^/| /' conftest.$ac_ext >&5
12263
12264 ac_compiler_gnu=no
12265 fi
12266 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12267 ac_cv_c_compiler_gnu=$ac_compiler_gnu
12268
12269 fi
12270 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
12271 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
12272 GCC=`test $ac_compiler_gnu = yes && echo yes`
12273 ac_test_CFLAGS=${CFLAGS+set}
12274 ac_save_CFLAGS=$CFLAGS
12275 CFLAGS="-g"
12276 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
12277 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
12278 if test "${ac_cv_prog_cc_g+set}" = set; then
12279   echo $ECHO_N "(cached) $ECHO_C" >&6
12280 else
12281   cat >conftest.$ac_ext <<_ACEOF
12282 /* confdefs.h.  */
12283 _ACEOF
12284 cat confdefs.h >>conftest.$ac_ext
12285 cat >>conftest.$ac_ext <<_ACEOF
12286 /* end confdefs.h.  */
12287
12288 int
12289 main ()
12290 {
12291
12292   ;
12293   return 0;
12294 }
12295 _ACEOF
12296 rm -f conftest.$ac_objext
12297 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12298   (eval $ac_compile) 2>conftest.er1
12299   ac_status=$?
12300   grep -v '^ *+' conftest.er1 >conftest.err
12301   rm -f conftest.er1
12302   cat conftest.err >&5
12303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12304   (exit $ac_status); } &&
12305          { ac_try='test -z "$ac_c_werror_flag"
12306                          || test ! -s conftest.err'
12307   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12308   (eval $ac_try) 2>&5
12309   ac_status=$?
12310   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12311   (exit $ac_status); }; } &&
12312          { ac_try='test -s conftest.$ac_objext'
12313   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12314   (eval $ac_try) 2>&5
12315   ac_status=$?
12316   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12317   (exit $ac_status); }; }; then
12318   ac_cv_prog_cc_g=yes
12319 else
12320   echo "$as_me: failed program was:" >&5
12321 sed 's/^/| /' conftest.$ac_ext >&5
12322
12323 ac_cv_prog_cc_g=no
12324 fi
12325 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12326 fi
12327 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
12328 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
12329 if test "$ac_test_CFLAGS" = set; then
12330   CFLAGS=$ac_save_CFLAGS
12331 elif test $ac_cv_prog_cc_g = yes; then
12332   if test "$GCC" = yes; then
12333     CFLAGS="-g -O2"
12334   else
12335     CFLAGS="-g"
12336   fi
12337 else
12338   if test "$GCC" = yes; then
12339     CFLAGS="-O2"
12340   else
12341     CFLAGS=
12342   fi
12343 fi
12344 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
12345 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
12346 if test "${ac_cv_prog_cc_stdc+set}" = set; then
12347   echo $ECHO_N "(cached) $ECHO_C" >&6
12348 else
12349   ac_cv_prog_cc_stdc=no
12350 ac_save_CC=$CC
12351 cat >conftest.$ac_ext <<_ACEOF
12352 /* confdefs.h.  */
12353 _ACEOF
12354 cat confdefs.h >>conftest.$ac_ext
12355 cat >>conftest.$ac_ext <<_ACEOF
12356 /* end confdefs.h.  */
12357 #include <stdarg.h>
12358 #include <stdio.h>
12359 #include <sys/types.h>
12360 #include <sys/stat.h>
12361 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
12362 struct buf { int x; };
12363 FILE * (*rcsopen) (struct buf *, struct stat *, int);
12364 static char *e (p, i)
12365      char **p;
12366      int i;
12367 {
12368   return p[i];
12369 }
12370 static char *f (char * (*g) (char **, int), char **p, ...)
12371 {
12372   char *s;
12373   va_list v;
12374   va_start (v,p);
12375   s = g (p, va_arg (v,int));
12376   va_end (v);
12377   return s;
12378 }
12379
12380 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
12381    function prototypes and stuff, but not '\xHH' hex character constants.
12382    These don't provoke an error unfortunately, instead are silently treated
12383    as 'x'.  The following induces an error, until -std1 is added to get
12384    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
12385    array size at least.  It's necessary to write '\x00'==0 to get something
12386    that's true only with -std1.  */
12387 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
12388
12389 int test (int i, double x);
12390 struct s1 {int (*f) (int a);};
12391 struct s2 {int (*f) (double a);};
12392 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
12393 int argc;
12394 char **argv;
12395 int
12396 main ()
12397 {
12398 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
12399   ;
12400   return 0;
12401 }
12402 _ACEOF
12403 # Don't try gcc -ansi; that turns off useful extensions and
12404 # breaks some systems' header files.
12405 # AIX                   -qlanglvl=ansi
12406 # Ultrix and OSF/1      -std1
12407 # HP-UX 10.20 and later -Ae
12408 # HP-UX older versions  -Aa -D_HPUX_SOURCE
12409 # SVR4                  -Xc -D__EXTENSIONS__
12410 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
12411 do
12412   CC="$ac_save_CC $ac_arg"
12413   rm -f conftest.$ac_objext
12414 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12415   (eval $ac_compile) 2>conftest.er1
12416   ac_status=$?
12417   grep -v '^ *+' conftest.er1 >conftest.err
12418   rm -f conftest.er1
12419   cat conftest.err >&5
12420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12421   (exit $ac_status); } &&
12422          { ac_try='test -z "$ac_c_werror_flag"
12423                          || test ! -s conftest.err'
12424   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12425   (eval $ac_try) 2>&5
12426   ac_status=$?
12427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12428   (exit $ac_status); }; } &&
12429          { ac_try='test -s conftest.$ac_objext'
12430   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12431   (eval $ac_try) 2>&5
12432   ac_status=$?
12433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12434   (exit $ac_status); }; }; then
12435   ac_cv_prog_cc_stdc=$ac_arg
12436 break
12437 else
12438   echo "$as_me: failed program was:" >&5
12439 sed 's/^/| /' conftest.$ac_ext >&5
12440
12441 fi
12442 rm -f conftest.err conftest.$ac_objext
12443 done
12444 rm -f conftest.$ac_ext conftest.$ac_objext
12445 CC=$ac_save_CC
12446
12447 fi
12448
12449 case "x$ac_cv_prog_cc_stdc" in
12450   x|xno)
12451     echo "$as_me:$LINENO: result: none needed" >&5
12452 echo "${ECHO_T}none needed" >&6 ;;
12453   *)
12454     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
12455 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
12456     CC="$CC $ac_cv_prog_cc_stdc" ;;
12457 esac
12458
12459 # Some people use a C++ compiler to compile C.  Since we use `exit',
12460 # in C++ we need to declare it.  In case someone uses the same compiler
12461 # for both compiling C and C++ we need to have the C++ compiler decide
12462 # the declaration of exit, since it's the most demanding environment.
12463 cat >conftest.$ac_ext <<_ACEOF
12464 #ifndef __cplusplus
12465   choke me
12466 #endif
12467 _ACEOF
12468 rm -f conftest.$ac_objext
12469 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12470   (eval $ac_compile) 2>conftest.er1
12471   ac_status=$?
12472   grep -v '^ *+' conftest.er1 >conftest.err
12473   rm -f conftest.er1
12474   cat conftest.err >&5
12475   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12476   (exit $ac_status); } &&
12477          { ac_try='test -z "$ac_c_werror_flag"
12478                          || test ! -s conftest.err'
12479   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12480   (eval $ac_try) 2>&5
12481   ac_status=$?
12482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12483   (exit $ac_status); }; } &&
12484          { ac_try='test -s conftest.$ac_objext'
12485   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12486   (eval $ac_try) 2>&5
12487   ac_status=$?
12488   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12489   (exit $ac_status); }; }; then
12490   for ac_declaration in \
12491    '' \
12492    'extern "C" void std::exit (int) throw (); using std::exit;' \
12493    'extern "C" void std::exit (int); using std::exit;' \
12494    'extern "C" void exit (int) throw ();' \
12495    'extern "C" void exit (int);' \
12496    'void exit (int);'
12497 do
12498   cat >conftest.$ac_ext <<_ACEOF
12499 /* confdefs.h.  */
12500 _ACEOF
12501 cat confdefs.h >>conftest.$ac_ext
12502 cat >>conftest.$ac_ext <<_ACEOF
12503 /* end confdefs.h.  */
12504 $ac_declaration
12505 #include <stdlib.h>
12506 int
12507 main ()
12508 {
12509 exit (42);
12510   ;
12511   return 0;
12512 }
12513 _ACEOF
12514 rm -f conftest.$ac_objext
12515 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12516   (eval $ac_compile) 2>conftest.er1
12517   ac_status=$?
12518   grep -v '^ *+' conftest.er1 >conftest.err
12519   rm -f conftest.er1
12520   cat conftest.err >&5
12521   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12522   (exit $ac_status); } &&
12523          { ac_try='test -z "$ac_c_werror_flag"
12524                          || test ! -s conftest.err'
12525   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12526   (eval $ac_try) 2>&5
12527   ac_status=$?
12528   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12529   (exit $ac_status); }; } &&
12530          { ac_try='test -s conftest.$ac_objext'
12531   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12532   (eval $ac_try) 2>&5
12533   ac_status=$?
12534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12535   (exit $ac_status); }; }; then
12536   :
12537 else
12538   echo "$as_me: failed program was:" >&5
12539 sed 's/^/| /' conftest.$ac_ext >&5
12540
12541 continue
12542 fi
12543 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12544   cat >conftest.$ac_ext <<_ACEOF
12545 /* confdefs.h.  */
12546 _ACEOF
12547 cat confdefs.h >>conftest.$ac_ext
12548 cat >>conftest.$ac_ext <<_ACEOF
12549 /* end confdefs.h.  */
12550 $ac_declaration
12551 int
12552 main ()
12553 {
12554 exit (42);
12555   ;
12556   return 0;
12557 }
12558 _ACEOF
12559 rm -f conftest.$ac_objext
12560 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12561   (eval $ac_compile) 2>conftest.er1
12562   ac_status=$?
12563   grep -v '^ *+' conftest.er1 >conftest.err
12564   rm -f conftest.er1
12565   cat conftest.err >&5
12566   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12567   (exit $ac_status); } &&
12568          { ac_try='test -z "$ac_c_werror_flag"
12569                          || test ! -s conftest.err'
12570   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12571   (eval $ac_try) 2>&5
12572   ac_status=$?
12573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12574   (exit $ac_status); }; } &&
12575          { ac_try='test -s conftest.$ac_objext'
12576   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12577   (eval $ac_try) 2>&5
12578   ac_status=$?
12579   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12580   (exit $ac_status); }; }; then
12581   break
12582 else
12583   echo "$as_me: failed program was:" >&5
12584 sed 's/^/| /' conftest.$ac_ext >&5
12585
12586 fi
12587 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12588 done
12589 rm -f conftest*
12590 if test -n "$ac_declaration"; then
12591   echo '#ifdef __cplusplus' >>confdefs.h
12592   echo $ac_declaration      >>confdefs.h
12593   echo '#endif'             >>confdefs.h
12594 fi
12595
12596 else
12597   echo "$as_me: failed program was:" >&5
12598 sed 's/^/| /' conftest.$ac_ext >&5
12599
12600 fi
12601 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12602 ac_ext=c
12603 ac_cpp='$CPP $CPPFLAGS'
12604 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
12605 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
12606 ac_compiler_gnu=$ac_cv_c_compiler_gnu
12607
12608 depcc="$CC"   am_compiler_list=
12609
12610 echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
12611 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6
12612 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
12613   echo $ECHO_N "(cached) $ECHO_C" >&6
12614 else
12615   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
12616   # We make a subdir and do the tests there.  Otherwise we can end up
12617   # making bogus files that we don't know about and never remove.  For
12618   # instance it was reported that on HP-UX the gcc test will end up
12619   # making a dummy file named `D' -- because `-MD' means `put the output
12620   # in D'.
12621   mkdir conftest.dir
12622   # Copy depcomp to subdir because otherwise we won't find it if we're
12623   # using a relative directory.
12624   cp "$am_depcomp" conftest.dir
12625   cd conftest.dir
12626   # We will build objects and dependencies in a subdirectory because
12627   # it helps to detect inapplicable dependency modes.  For instance
12628   # both Tru64's cc and ICC support -MD to output dependencies as a
12629   # side effect of compilation, but ICC will put the dependencies in
12630   # the current directory while Tru64 will put them in the object
12631   # directory.
12632   mkdir sub
12633
12634   am_cv_CC_dependencies_compiler_type=none
12635   if test "$am_compiler_list" = ""; then
12636      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
12637   fi
12638   for depmode in $am_compiler_list; do
12639     # Setup a source with many dependencies, because some compilers
12640     # like to wrap large dependency lists on column 80 (with \), and
12641     # we should not choose a depcomp mode which is confused by this.
12642     #
12643     # We need to recreate these files for each test, as the compiler may
12644     # overwrite some of them when testing with obscure command lines.
12645     # This happens at least with the AIX C compiler.
12646     : > sub/conftest.c
12647     for i in 1 2 3 4 5 6; do
12648       echo '#include "conftst'$i'.h"' >> sub/conftest.c
12649       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
12650       # Solaris 8's {/usr,}/bin/sh.
12651       touch sub/conftst$i.h
12652     done
12653     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
12654
12655     case $depmode in
12656     nosideeffect)
12657       # after this tag, mechanisms are not by side-effect, so they'll
12658       # only be used when explicitly requested
12659       if test "x$enable_dependency_tracking" = xyes; then
12660         continue
12661       else
12662         break
12663       fi
12664       ;;
12665     none) break ;;
12666     esac
12667     # We check with `-c' and `-o' for the sake of the "dashmstdout"
12668     # mode.  It turns out that the SunPro C++ compiler does not properly
12669     # handle `-M -o', and we need to detect this.
12670     if depmode=$depmode \
12671        source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
12672        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
12673        $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
12674          >/dev/null 2>conftest.err &&
12675        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
12676        grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
12677        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
12678       # icc doesn't choke on unknown options, it will just issue warnings
12679       # or remarks (even with -Werror).  So we grep stderr for any message
12680       # that says an option was ignored or not supported.
12681       # When given -MP, icc 7.0 and 7.1 complain thusly:
12682       #   icc: Command line warning: ignoring option '-M'; no argument required
12683       # The diagnosis changed in icc 8.0:
12684       #   icc: Command line remark: option '-MP' not supported
12685       if (grep 'ignoring option' conftest.err ||
12686           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
12687         am_cv_CC_dependencies_compiler_type=$depmode
12688         break
12689       fi
12690     fi
12691   done
12692
12693   cd ..
12694   rm -rf conftest.dir
12695 else
12696   am_cv_CC_dependencies_compiler_type=none
12697 fi
12698
12699 fi
12700 echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
12701 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6
12702 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
12703
12704
12705
12706 if
12707   test "x$enable_dependency_tracking" != xno \
12708   && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
12709   am__fastdepCC_TRUE=
12710   am__fastdepCC_FALSE='#'
12711 else
12712   am__fastdepCC_TRUE='#'
12713   am__fastdepCC_FALSE=
12714 fi
12715
12716
12717 if test "X${ac_cv_prog_cc_stdc}" = "Xno" ; then
12718         { { echo "$as_me:$LINENO: error: OpenLDAP requires compiler to support STDC constructs." >&5
12719 echo "$as_me: error: OpenLDAP requires compiler to support STDC constructs." >&2;}
12720    { (exit 1); exit 1; }; }
12721 fi
12722
12723 # test for make depend flag
12724 OL_MKDEP=
12725 OL_MKDEP_FLAGS=
12726 if test -z "${MKDEP}"; then
12727         OL_MKDEP="${CC-cc}"
12728         if test -z "${MKDEP_FLAGS}"; then
12729                 echo "$as_me:$LINENO: checking for ${OL_MKDEP} depend flag" >&5
12730 echo $ECHO_N "checking for ${OL_MKDEP} depend flag... $ECHO_C" >&6
12731 if test "${ol_cv_mkdep+set}" = set; then
12732   echo $ECHO_N "(cached) $ECHO_C" >&6
12733 else
12734
12735                         ol_cv_mkdep=no
12736                         for flag in "-M" "-xM"; do
12737                                 cat > conftest.c <<EOF
12738  noCode;
12739 EOF
12740                                 if { ac_try='$OL_MKDEP $flag conftest.c'
12741   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12742   (eval $ac_try) 2>&5
12743   ac_status=$?
12744   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12745   (exit $ac_status); }; } \
12746                                         | grep '^conftest\.'"${ac_objext}" >/dev/null 2>&1
12747                                 then
12748                                         if test ! -f conftest."${ac_object}" ; then
12749                                                 ol_cv_mkdep=$flag
12750                                                 OL_MKDEP_FLAGS="$flag"
12751                                                 break
12752                                         fi
12753                                 fi
12754                         done
12755                         rm -f conftest*
12756
12757 fi
12758 echo "$as_me:$LINENO: result: $ol_cv_mkdep" >&5
12759 echo "${ECHO_T}$ol_cv_mkdep" >&6
12760                 test "$ol_cv_mkdep" = no && OL_MKDEP=":"
12761         else
12762                 cc_cv_mkdep=yes
12763                 OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
12764         fi
12765 else
12766         cc_cv_mkdep=yes
12767         OL_MKDEP="${MKDEP}"
12768         OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
12769 fi
12770
12771
12772
12773 if test "${ol_cv_mkdep}" = no ; then
12774         # this will soon become an error
12775         { echo "$as_me:$LINENO: WARNING: do not know how to generate dependencies" >&5
12776 echo "$as_me: WARNING: do not know how to generate dependencies" >&2;}
12777 fi
12778
12779 echo "$as_me:$LINENO: checking for afopen in -ls" >&5
12780 echo $ECHO_N "checking for afopen in -ls... $ECHO_C" >&6
12781 if test "${ac_cv_lib_s_afopen+set}" = set; then
12782   echo $ECHO_N "(cached) $ECHO_C" >&6
12783 else
12784   ac_check_lib_save_LIBS=$LIBS
12785 LIBS="-ls  $LIBS"
12786 cat >conftest.$ac_ext <<_ACEOF
12787 /* confdefs.h.  */
12788 _ACEOF
12789 cat confdefs.h >>conftest.$ac_ext
12790 cat >>conftest.$ac_ext <<_ACEOF
12791 /* end confdefs.h.  */
12792
12793 /* Override any gcc2 internal prototype to avoid an error.  */
12794 #ifdef __cplusplus
12795 extern "C"
12796 #endif
12797 /* We use char because int might match the return type of a gcc2
12798    builtin and then its argument prototype would still apply.  */
12799 char afopen ();
12800 int
12801 main ()
12802 {
12803 afopen ();
12804   ;
12805   return 0;
12806 }
12807 _ACEOF
12808 rm -f conftest.$ac_objext conftest$ac_exeext
12809 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12810   (eval $ac_link) 2>conftest.er1
12811   ac_status=$?
12812   grep -v '^ *+' conftest.er1 >conftest.err
12813   rm -f conftest.er1
12814   cat conftest.err >&5
12815   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12816   (exit $ac_status); } &&
12817          { ac_try='test -z "$ac_c_werror_flag"
12818                          || test ! -s conftest.err'
12819   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12820   (eval $ac_try) 2>&5
12821   ac_status=$?
12822   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12823   (exit $ac_status); }; } &&
12824          { ac_try='test -s conftest$ac_exeext'
12825   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12826   (eval $ac_try) 2>&5
12827   ac_status=$?
12828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12829   (exit $ac_status); }; }; then
12830   ac_cv_lib_s_afopen=yes
12831 else
12832   echo "$as_me: failed program was:" >&5
12833 sed 's/^/| /' conftest.$ac_ext >&5
12834
12835 ac_cv_lib_s_afopen=no
12836 fi
12837 rm -f conftest.err conftest.$ac_objext \
12838       conftest$ac_exeext conftest.$ac_ext
12839 LIBS=$ac_check_lib_save_LIBS
12840 fi
12841 echo "$as_me:$LINENO: result: $ac_cv_lib_s_afopen" >&5
12842 echo "${ECHO_T}$ac_cv_lib_s_afopen" >&6
12843 if test $ac_cv_lib_s_afopen = yes; then
12844
12845         AUTH_LIBS=-ls
12846
12847 cat >>confdefs.h <<\_ACEOF
12848 #define HAVE_AIX_SECURITY 1
12849 _ACEOF
12850
12851
12852 fi
12853
12854
12855 case "$target" in
12856 *-ibm-openedition)
12857         ac_cv_func_getopt=no
12858
12859 cat >>confdefs.h <<\_ACEOF
12860 #define BOTH_STRINGS_H 1
12861 _ACEOF
12862
12863         ;;
12864 esac
12865
12866 ol_link_modules=no
12867 WITH_MODULES_ENABLED=no
12868 if test $ol_enable_modules != no ; then
12869
12870 for ac_header in ltdl.h
12871 do
12872 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12873 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12874   echo "$as_me:$LINENO: checking for $ac_header" >&5
12875 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12876 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12877   echo $ECHO_N "(cached) $ECHO_C" >&6
12878 fi
12879 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12880 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12881 else
12882   # Is the header compilable?
12883 echo "$as_me:$LINENO: checking $ac_header usability" >&5
12884 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
12885 cat >conftest.$ac_ext <<_ACEOF
12886 /* confdefs.h.  */
12887 _ACEOF
12888 cat confdefs.h >>conftest.$ac_ext
12889 cat >>conftest.$ac_ext <<_ACEOF
12890 /* end confdefs.h.  */
12891 $ac_includes_default
12892 #include <$ac_header>
12893 _ACEOF
12894 rm -f conftest.$ac_objext
12895 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12896   (eval $ac_compile) 2>conftest.er1
12897   ac_status=$?
12898   grep -v '^ *+' conftest.er1 >conftest.err
12899   rm -f conftest.er1
12900   cat conftest.err >&5
12901   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12902   (exit $ac_status); } &&
12903          { ac_try='test -z "$ac_c_werror_flag"
12904                          || test ! -s conftest.err'
12905   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12906   (eval $ac_try) 2>&5
12907   ac_status=$?
12908   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12909   (exit $ac_status); }; } &&
12910          { ac_try='test -s conftest.$ac_objext'
12911   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12912   (eval $ac_try) 2>&5
12913   ac_status=$?
12914   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12915   (exit $ac_status); }; }; then
12916   ac_header_compiler=yes
12917 else
12918   echo "$as_me: failed program was:" >&5
12919 sed 's/^/| /' conftest.$ac_ext >&5
12920
12921 ac_header_compiler=no
12922 fi
12923 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12924 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12925 echo "${ECHO_T}$ac_header_compiler" >&6
12926
12927 # Is the header present?
12928 echo "$as_me:$LINENO: checking $ac_header presence" >&5
12929 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
12930 cat >conftest.$ac_ext <<_ACEOF
12931 /* confdefs.h.  */
12932 _ACEOF
12933 cat confdefs.h >>conftest.$ac_ext
12934 cat >>conftest.$ac_ext <<_ACEOF
12935 /* end confdefs.h.  */
12936 #include <$ac_header>
12937 _ACEOF
12938 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
12939   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12940   ac_status=$?
12941   grep -v '^ *+' conftest.er1 >conftest.err
12942   rm -f conftest.er1
12943   cat conftest.err >&5
12944   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12945   (exit $ac_status); } >/dev/null; then
12946   if test -s conftest.err; then
12947     ac_cpp_err=$ac_c_preproc_warn_flag
12948     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
12949   else
12950     ac_cpp_err=
12951   fi
12952 else
12953   ac_cpp_err=yes
12954 fi
12955 if test -z "$ac_cpp_err"; then
12956   ac_header_preproc=yes
12957 else
12958   echo "$as_me: failed program was:" >&5
12959 sed 's/^/| /' conftest.$ac_ext >&5
12960
12961   ac_header_preproc=no
12962 fi
12963 rm -f conftest.err conftest.$ac_ext
12964 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12965 echo "${ECHO_T}$ac_header_preproc" >&6
12966
12967 # So?  What about this header?
12968 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12969   yes:no: )
12970     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12971 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12972     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12973 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12974     ac_header_preproc=yes
12975     ;;
12976   no:yes:* )
12977     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12978 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12979     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12980 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12981     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12982 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12983     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12984 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12985     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12986 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12987     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12988 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12989     (
12990       cat <<\_ASBOX
12991 ## --------------------------------------------- ##
12992 ## Report this to <http://www.openldap.org/its/> ##
12993 ## --------------------------------------------- ##
12994 _ASBOX
12995     ) |
12996       sed "s/^/$as_me: WARNING:     /" >&2
12997     ;;
12998 esac
12999 echo "$as_me:$LINENO: checking for $ac_header" >&5
13000 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13001 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13002   echo $ECHO_N "(cached) $ECHO_C" >&6
13003 else
13004   eval "$as_ac_Header=\$ac_header_preproc"
13005 fi
13006 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13007 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13008
13009 fi
13010 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13011   cat >>confdefs.h <<_ACEOF
13012 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13013 _ACEOF
13014
13015 fi
13016
13017 done
13018
13019
13020         if test $ac_cv_header_ltdl_h = no ; then
13021                 { { echo "$as_me:$LINENO: error: could not locate libtool ltdl.h" >&5
13022 echo "$as_me: error: could not locate libtool ltdl.h" >&2;}
13023    { (exit 1); exit 1; }; }
13024         fi
13025
13026         echo "$as_me:$LINENO: checking for lt_dlinit in -lltdl" >&5
13027 echo $ECHO_N "checking for lt_dlinit in -lltdl... $ECHO_C" >&6
13028 if test "${ac_cv_lib_ltdl_lt_dlinit+set}" = set; then
13029   echo $ECHO_N "(cached) $ECHO_C" >&6
13030 else
13031   ac_check_lib_save_LIBS=$LIBS
13032 LIBS="-lltdl  $LIBS"
13033 cat >conftest.$ac_ext <<_ACEOF
13034 /* confdefs.h.  */
13035 _ACEOF
13036 cat confdefs.h >>conftest.$ac_ext
13037 cat >>conftest.$ac_ext <<_ACEOF
13038 /* end confdefs.h.  */
13039
13040 /* Override any gcc2 internal prototype to avoid an error.  */
13041 #ifdef __cplusplus
13042 extern "C"
13043 #endif
13044 /* We use char because int might match the return type of a gcc2
13045    builtin and then its argument prototype would still apply.  */
13046 char lt_dlinit ();
13047 int
13048 main ()
13049 {
13050 lt_dlinit ();
13051   ;
13052   return 0;
13053 }
13054 _ACEOF
13055 rm -f conftest.$ac_objext conftest$ac_exeext
13056 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13057   (eval $ac_link) 2>conftest.er1
13058   ac_status=$?
13059   grep -v '^ *+' conftest.er1 >conftest.err
13060   rm -f conftest.er1
13061   cat conftest.err >&5
13062   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13063   (exit $ac_status); } &&
13064          { ac_try='test -z "$ac_c_werror_flag"
13065                          || test ! -s conftest.err'
13066   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13067   (eval $ac_try) 2>&5
13068   ac_status=$?
13069   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13070   (exit $ac_status); }; } &&
13071          { ac_try='test -s conftest$ac_exeext'
13072   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13073   (eval $ac_try) 2>&5
13074   ac_status=$?
13075   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13076   (exit $ac_status); }; }; then
13077   ac_cv_lib_ltdl_lt_dlinit=yes
13078 else
13079   echo "$as_me: failed program was:" >&5
13080 sed 's/^/| /' conftest.$ac_ext >&5
13081
13082 ac_cv_lib_ltdl_lt_dlinit=no
13083 fi
13084 rm -f conftest.err conftest.$ac_objext \
13085       conftest$ac_exeext conftest.$ac_ext
13086 LIBS=$ac_check_lib_save_LIBS
13087 fi
13088 echo "$as_me:$LINENO: result: $ac_cv_lib_ltdl_lt_dlinit" >&5
13089 echo "${ECHO_T}$ac_cv_lib_ltdl_lt_dlinit" >&6
13090 if test $ac_cv_lib_ltdl_lt_dlinit = yes; then
13091
13092                 MODULES_LIBS=-lltdl
13093
13094 cat >>confdefs.h <<\_ACEOF
13095 #define HAVE_LIBLTDL 1
13096 _ACEOF
13097
13098
13099 fi
13100
13101
13102         if test "$ac_cv_lib_ltdl_lt_dlinit" = no ; then
13103                 { { echo "$as_me:$LINENO: error: could not locate libtool -lltdl" >&5
13104 echo "$as_me: error: could not locate libtool -lltdl" >&2;}
13105    { (exit 1); exit 1; }; }
13106         fi
13107         ol_link_modules=yes
13108         WITH_MODULES_ENABLED=yes
13109
13110 else
13111         for i in $Backends; do
13112                 eval "ol_tmp=\$ol_enable_$i"
13113                 if test $ol_tmp = mod ; then
13114                         { echo "$as_me:$LINENO: WARNING: building static $i backend" >&5
13115 echo "$as_me: WARNING: building static $i backend" >&2;}
13116                         eval "ol_enable_$i=yes"
13117                 fi
13118         done
13119         for i in $Overlays; do
13120                 eval "ol_tmp=\$ol_enable_$i"
13121                 if test $ol_tmp = mod ; then
13122                         { echo "$as_me:$LINENO: WARNING: building static $i overlay" >&5
13123 echo "$as_me: WARNING: building static $i overlay" >&2;}
13124                         eval "ol_enable_$i=yes"
13125                 fi
13126         done
13127 fi
13128
13129 # test for EBCDIC
13130 echo "$as_me:$LINENO: checking for EBCDIC" >&5
13131 echo $ECHO_N "checking for EBCDIC... $ECHO_C" >&6
13132 if test "${ol_cv_cpp_ebcdic+set}" = set; then
13133   echo $ECHO_N "(cached) $ECHO_C" >&6
13134 else
13135
13136         cat >conftest.$ac_ext <<_ACEOF
13137 /* confdefs.h.  */
13138 _ACEOF
13139 cat confdefs.h >>conftest.$ac_ext
13140 cat >>conftest.$ac_ext <<_ACEOF
13141 /* end confdefs.h.  */
13142
13143 #if !('M' == 0xd4)
13144 #include <__ASCII__/generate_error.h>
13145 #endif
13146
13147 _ACEOF
13148 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13149   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13150   ac_status=$?
13151   grep -v '^ *+' conftest.er1 >conftest.err
13152   rm -f conftest.er1
13153   cat conftest.err >&5
13154   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13155   (exit $ac_status); } >/dev/null; then
13156   if test -s conftest.err; then
13157     ac_cpp_err=$ac_c_preproc_warn_flag
13158     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
13159   else
13160     ac_cpp_err=
13161   fi
13162 else
13163   ac_cpp_err=yes
13164 fi
13165 if test -z "$ac_cpp_err"; then
13166   ol_cv_cpp_ebcdic=yes
13167 else
13168   echo "$as_me: failed program was:" >&5
13169 sed 's/^/| /' conftest.$ac_ext >&5
13170
13171   ol_cv_cpp_ebcdic=no
13172 fi
13173 rm -f conftest.err conftest.$ac_ext
13174 fi
13175 echo "$as_me:$LINENO: result: $ol_cv_cpp_ebcdic" >&5
13176 echo "${ECHO_T}$ol_cv_cpp_ebcdic" >&6
13177 if test $ol_cv_cpp_ebcdic = yes ; then
13178
13179 cat >>confdefs.h <<\_ACEOF
13180 #define HAVE_EBCDIC 1
13181 _ACEOF
13182
13183 fi
13184
13185 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
13186 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
13187 if test "${ol_cv_header_stdc+set}" = set; then
13188   echo $ECHO_N "(cached) $ECHO_C" >&6
13189 else
13190   cat >conftest.$ac_ext <<_ACEOF
13191 /* confdefs.h.  */
13192 _ACEOF
13193 cat confdefs.h >>conftest.$ac_ext
13194 cat >>conftest.$ac_ext <<_ACEOF
13195 /* end confdefs.h.  */
13196 #include <stdlib.h>
13197 #include <stdarg.h>
13198 #include <string.h>
13199 #include <float.h>
13200 _ACEOF
13201 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13202   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13203   ac_status=$?
13204   grep -v '^ *+' conftest.er1 >conftest.err
13205   rm -f conftest.er1
13206   cat conftest.err >&5
13207   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13208   (exit $ac_status); } >/dev/null; then
13209   if test -s conftest.err; then
13210     ac_cpp_err=$ac_c_preproc_warn_flag
13211     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
13212   else
13213     ac_cpp_err=
13214   fi
13215 else
13216   ac_cpp_err=yes
13217 fi
13218 if test -z "$ac_cpp_err"; then
13219   ol_cv_header_stdc=yes
13220 else
13221   echo "$as_me: failed program was:" >&5
13222 sed 's/^/| /' conftest.$ac_ext >&5
13223
13224   ol_cv_header_stdc=no
13225 fi
13226 rm -f conftest.err conftest.$ac_ext
13227
13228 if test $ol_cv_header_stdc = yes; then
13229   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13230 cat >conftest.$ac_ext <<_ACEOF
13231 /* confdefs.h.  */
13232 _ACEOF
13233 cat confdefs.h >>conftest.$ac_ext
13234 cat >>conftest.$ac_ext <<_ACEOF
13235 /* end confdefs.h.  */
13236 #include <string.h>
13237
13238 _ACEOF
13239 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13240   $EGREP "memchr" >/dev/null 2>&1; then
13241   :
13242 else
13243   ol_cv_header_stdc=no
13244 fi
13245 rm -f conftest*
13246
13247 fi
13248
13249 if test $ol_cv_header_stdc = yes; then
13250   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13251 cat >conftest.$ac_ext <<_ACEOF
13252 /* confdefs.h.  */
13253 _ACEOF
13254 cat confdefs.h >>conftest.$ac_ext
13255 cat >>conftest.$ac_ext <<_ACEOF
13256 /* end confdefs.h.  */
13257 #include <stdlib.h>
13258
13259 _ACEOF
13260 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13261   $EGREP "free" >/dev/null 2>&1; then
13262   :
13263 else
13264   ol_cv_header_stdc=no
13265 fi
13266 rm -f conftest*
13267
13268 fi
13269
13270 if test $ol_cv_header_stdc = yes; then
13271   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13272 if test "$cross_compiling" = yes; then
13273   :
13274 else
13275   cat >conftest.$ac_ext <<_ACEOF
13276 /* confdefs.h.  */
13277 _ACEOF
13278 cat confdefs.h >>conftest.$ac_ext
13279 cat >>conftest.$ac_ext <<_ACEOF
13280 /* end confdefs.h.  */
13281 #include <ctype.h>
13282 #ifndef HAVE_EBCDIC
13283 #       define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13284 #       define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13285 #else
13286 #       define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13287                 || ('j' <= (c) && (c) <= 'r') \
13288                 || ('s' <= (c) && (c) <= 'z'))
13289 #       define TOUPPER(c)       (ISLOWER(c) ? ((c) | 0x40) : (c))
13290 #endif
13291 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13292 int main () { int i; for (i = 0; i < 256; i++)
13293 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
13294 exit (0); }
13295
13296 _ACEOF
13297 rm -f conftest$ac_exeext
13298 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13299   (eval $ac_link) 2>&5
13300   ac_status=$?
13301   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13302   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13303   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13304   (eval $ac_try) 2>&5
13305   ac_status=$?
13306   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13307   (exit $ac_status); }; }; then
13308   :
13309 else
13310   echo "$as_me: program exited with status $ac_status" >&5
13311 echo "$as_me: failed program was:" >&5
13312 sed 's/^/| /' conftest.$ac_ext >&5
13313
13314 ( exit $ac_status )
13315 ol_cv_header_stdc=no
13316 fi
13317 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13318 fi
13319 fi
13320 fi
13321 echo "$as_me:$LINENO: result: $ol_cv_header_stdc" >&5
13322 echo "${ECHO_T}$ol_cv_header_stdc" >&6
13323 if test $ol_cv_header_stdc = yes; then
13324   cat >>confdefs.h <<\_ACEOF
13325 #define STDC_HEADERS 1
13326 _ACEOF
13327
13328 fi
13329 ac_cv_header_stdc=disable
13330
13331
13332 if test $ol_cv_header_stdc != yes; then
13333         { echo "$as_me:$LINENO: WARNING: could not locate Standard C compliant headers" >&5
13334 echo "$as_me: WARNING: could not locate Standard C compliant headers" >&2;}
13335 fi
13336
13337
13338
13339
13340
13341
13342 ac_header_dirent=no
13343 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
13344   as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
13345 echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
13346 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
13347 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13348   echo $ECHO_N "(cached) $ECHO_C" >&6
13349 else
13350   cat >conftest.$ac_ext <<_ACEOF
13351 /* confdefs.h.  */
13352 _ACEOF
13353 cat confdefs.h >>conftest.$ac_ext
13354 cat >>conftest.$ac_ext <<_ACEOF
13355 /* end confdefs.h.  */
13356 #include <sys/types.h>
13357 #include <$ac_hdr>
13358
13359 int
13360 main ()
13361 {
13362 if ((DIR *) 0)
13363 return 0;
13364   ;
13365   return 0;
13366 }
13367 _ACEOF
13368 rm -f conftest.$ac_objext
13369 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13370   (eval $ac_compile) 2>conftest.er1
13371   ac_status=$?
13372   grep -v '^ *+' conftest.er1 >conftest.err
13373   rm -f conftest.er1
13374   cat conftest.err >&5
13375   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13376   (exit $ac_status); } &&
13377          { ac_try='test -z "$ac_c_werror_flag"
13378                          || test ! -s conftest.err'
13379   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13380   (eval $ac_try) 2>&5
13381   ac_status=$?
13382   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13383   (exit $ac_status); }; } &&
13384          { ac_try='test -s conftest.$ac_objext'
13385   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13386   (eval $ac_try) 2>&5
13387   ac_status=$?
13388   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13389   (exit $ac_status); }; }; then
13390   eval "$as_ac_Header=yes"
13391 else
13392   echo "$as_me: failed program was:" >&5
13393 sed 's/^/| /' conftest.$ac_ext >&5
13394
13395 eval "$as_ac_Header=no"
13396 fi
13397 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13398 fi
13399 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13400 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13401 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13402   cat >>confdefs.h <<_ACEOF
13403 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
13404 _ACEOF
13405
13406 ac_header_dirent=$ac_hdr; break
13407 fi
13408
13409 done
13410 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
13411 if test $ac_header_dirent = dirent.h; then
13412   echo "$as_me:$LINENO: checking for library containing opendir" >&5
13413 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
13414 if test "${ac_cv_search_opendir+set}" = set; then
13415   echo $ECHO_N "(cached) $ECHO_C" >&6
13416 else
13417   ac_func_search_save_LIBS=$LIBS
13418 ac_cv_search_opendir=no
13419 cat >conftest.$ac_ext <<_ACEOF
13420 /* confdefs.h.  */
13421 _ACEOF
13422 cat confdefs.h >>conftest.$ac_ext
13423 cat >>conftest.$ac_ext <<_ACEOF
13424 /* end confdefs.h.  */
13425
13426 /* Override any gcc2 internal prototype to avoid an error.  */
13427 #ifdef __cplusplus
13428 extern "C"
13429 #endif
13430 /* We use char because int might match the return type of a gcc2
13431    builtin and then its argument prototype would still apply.  */
13432 char opendir ();
13433 int
13434 main ()
13435 {
13436 opendir ();
13437   ;
13438   return 0;
13439 }
13440 _ACEOF
13441 rm -f conftest.$ac_objext conftest$ac_exeext
13442 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13443   (eval $ac_link) 2>conftest.er1
13444   ac_status=$?
13445   grep -v '^ *+' conftest.er1 >conftest.err
13446   rm -f conftest.er1
13447   cat conftest.err >&5
13448   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13449   (exit $ac_status); } &&
13450          { ac_try='test -z "$ac_c_werror_flag"
13451                          || test ! -s conftest.err'
13452   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13453   (eval $ac_try) 2>&5
13454   ac_status=$?
13455   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13456   (exit $ac_status); }; } &&
13457          { ac_try='test -s conftest$ac_exeext'
13458   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13459   (eval $ac_try) 2>&5
13460   ac_status=$?
13461   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13462   (exit $ac_status); }; }; then
13463   ac_cv_search_opendir="none required"
13464 else
13465   echo "$as_me: failed program was:" >&5
13466 sed 's/^/| /' conftest.$ac_ext >&5
13467
13468 fi
13469 rm -f conftest.err conftest.$ac_objext \
13470       conftest$ac_exeext conftest.$ac_ext
13471 if test "$ac_cv_search_opendir" = no; then
13472   for ac_lib in dir; do
13473     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
13474     cat >conftest.$ac_ext <<_ACEOF
13475 /* confdefs.h.  */
13476 _ACEOF
13477 cat confdefs.h >>conftest.$ac_ext
13478 cat >>conftest.$ac_ext <<_ACEOF
13479 /* end confdefs.h.  */
13480
13481 /* Override any gcc2 internal prototype to avoid an error.  */
13482 #ifdef __cplusplus
13483 extern "C"
13484 #endif
13485 /* We use char because int might match the return type of a gcc2
13486    builtin and then its argument prototype would still apply.  */
13487 char opendir ();
13488 int
13489 main ()
13490 {
13491 opendir ();
13492   ;
13493   return 0;
13494 }
13495 _ACEOF
13496 rm -f conftest.$ac_objext conftest$ac_exeext
13497 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13498   (eval $ac_link) 2>conftest.er1
13499   ac_status=$?
13500   grep -v '^ *+' conftest.er1 >conftest.err
13501   rm -f conftest.er1
13502   cat conftest.err >&5
13503   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13504   (exit $ac_status); } &&
13505          { ac_try='test -z "$ac_c_werror_flag"
13506                          || test ! -s conftest.err'
13507   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13508   (eval $ac_try) 2>&5
13509   ac_status=$?
13510   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13511   (exit $ac_status); }; } &&
13512          { ac_try='test -s conftest$ac_exeext'
13513   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13514   (eval $ac_try) 2>&5
13515   ac_status=$?
13516   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13517   (exit $ac_status); }; }; then
13518   ac_cv_search_opendir="-l$ac_lib"
13519 break
13520 else
13521   echo "$as_me: failed program was:" >&5
13522 sed 's/^/| /' conftest.$ac_ext >&5
13523
13524 fi
13525 rm -f conftest.err conftest.$ac_objext \
13526       conftest$ac_exeext conftest.$ac_ext
13527   done
13528 fi
13529 LIBS=$ac_func_search_save_LIBS
13530 fi
13531 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
13532 echo "${ECHO_T}$ac_cv_search_opendir" >&6
13533 if test "$ac_cv_search_opendir" != no; then
13534   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
13535
13536 fi
13537
13538 else
13539   echo "$as_me:$LINENO: checking for library containing opendir" >&5
13540 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
13541 if test "${ac_cv_search_opendir+set}" = set; then
13542   echo $ECHO_N "(cached) $ECHO_C" >&6
13543 else
13544   ac_func_search_save_LIBS=$LIBS
13545 ac_cv_search_opendir=no
13546 cat >conftest.$ac_ext <<_ACEOF
13547 /* confdefs.h.  */
13548 _ACEOF
13549 cat confdefs.h >>conftest.$ac_ext
13550 cat >>conftest.$ac_ext <<_ACEOF
13551 /* end confdefs.h.  */
13552
13553 /* Override any gcc2 internal prototype to avoid an error.  */
13554 #ifdef __cplusplus
13555 extern "C"
13556 #endif
13557 /* We use char because int might match the return type of a gcc2
13558    builtin and then its argument prototype would still apply.  */
13559 char opendir ();
13560 int
13561 main ()
13562 {
13563 opendir ();
13564   ;
13565   return 0;
13566 }
13567 _ACEOF
13568 rm -f conftest.$ac_objext conftest$ac_exeext
13569 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13570   (eval $ac_link) 2>conftest.er1
13571   ac_status=$?
13572   grep -v '^ *+' conftest.er1 >conftest.err
13573   rm -f conftest.er1
13574   cat conftest.err >&5
13575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13576   (exit $ac_status); } &&
13577          { ac_try='test -z "$ac_c_werror_flag"
13578                          || test ! -s conftest.err'
13579   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13580   (eval $ac_try) 2>&5
13581   ac_status=$?
13582   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13583   (exit $ac_status); }; } &&
13584          { ac_try='test -s conftest$ac_exeext'
13585   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13586   (eval $ac_try) 2>&5
13587   ac_status=$?
13588   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13589   (exit $ac_status); }; }; then
13590   ac_cv_search_opendir="none required"
13591 else
13592   echo "$as_me: failed program was:" >&5
13593 sed 's/^/| /' conftest.$ac_ext >&5
13594
13595 fi
13596 rm -f conftest.err conftest.$ac_objext \
13597       conftest$ac_exeext conftest.$ac_ext
13598 if test "$ac_cv_search_opendir" = no; then
13599   for ac_lib in x; do
13600     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
13601     cat >conftest.$ac_ext <<_ACEOF
13602 /* confdefs.h.  */
13603 _ACEOF
13604 cat confdefs.h >>conftest.$ac_ext
13605 cat >>conftest.$ac_ext <<_ACEOF
13606 /* end confdefs.h.  */
13607
13608 /* Override any gcc2 internal prototype to avoid an error.  */
13609 #ifdef __cplusplus
13610 extern "C"
13611 #endif
13612 /* We use char because int might match the return type of a gcc2
13613    builtin and then its argument prototype would still apply.  */
13614 char opendir ();
13615 int
13616 main ()
13617 {
13618 opendir ();
13619   ;
13620   return 0;
13621 }
13622 _ACEOF
13623 rm -f conftest.$ac_objext conftest$ac_exeext
13624 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13625   (eval $ac_link) 2>conftest.er1
13626   ac_status=$?
13627   grep -v '^ *+' conftest.er1 >conftest.err
13628   rm -f conftest.er1
13629   cat conftest.err >&5
13630   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13631   (exit $ac_status); } &&
13632          { ac_try='test -z "$ac_c_werror_flag"
13633                          || test ! -s conftest.err'
13634   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13635   (eval $ac_try) 2>&5
13636   ac_status=$?
13637   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13638   (exit $ac_status); }; } &&
13639          { ac_try='test -s conftest$ac_exeext'
13640   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13641   (eval $ac_try) 2>&5
13642   ac_status=$?
13643   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13644   (exit $ac_status); }; }; then
13645   ac_cv_search_opendir="-l$ac_lib"
13646 break
13647 else
13648   echo "$as_me: failed program was:" >&5
13649 sed 's/^/| /' conftest.$ac_ext >&5
13650
13651 fi
13652 rm -f conftest.err conftest.$ac_objext \
13653       conftest$ac_exeext conftest.$ac_ext
13654   done
13655 fi
13656 LIBS=$ac_func_search_save_LIBS
13657 fi
13658 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
13659 echo "${ECHO_T}$ac_cv_search_opendir" >&6
13660 if test "$ac_cv_search_opendir" != no; then
13661   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
13662
13663 fi
13664
13665 fi
13666
13667 echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
13668 echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
13669 if test "${ac_cv_header_sys_wait_h+set}" = set; then
13670   echo $ECHO_N "(cached) $ECHO_C" >&6
13671 else
13672   cat >conftest.$ac_ext <<_ACEOF
13673 /* confdefs.h.  */
13674 _ACEOF
13675 cat confdefs.h >>conftest.$ac_ext
13676 cat >>conftest.$ac_ext <<_ACEOF
13677 /* end confdefs.h.  */
13678 #include <sys/types.h>
13679 #include <sys/wait.h>
13680 #ifndef WEXITSTATUS
13681 # define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
13682 #endif
13683 #ifndef WIFEXITED
13684 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
13685 #endif
13686
13687 int
13688 main ()
13689 {
13690   int s;
13691   wait (&s);
13692   s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
13693   ;
13694   return 0;
13695 }
13696 _ACEOF
13697 rm -f conftest.$ac_objext
13698 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13699   (eval $ac_compile) 2>conftest.er1
13700   ac_status=$?
13701   grep -v '^ *+' conftest.er1 >conftest.err
13702   rm -f conftest.er1
13703   cat conftest.err >&5
13704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13705   (exit $ac_status); } &&
13706          { ac_try='test -z "$ac_c_werror_flag"
13707                          || test ! -s conftest.err'
13708   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13709   (eval $ac_try) 2>&5
13710   ac_status=$?
13711   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13712   (exit $ac_status); }; } &&
13713          { ac_try='test -s conftest.$ac_objext'
13714   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13715   (eval $ac_try) 2>&5
13716   ac_status=$?
13717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13718   (exit $ac_status); }; }; then
13719   ac_cv_header_sys_wait_h=yes
13720 else
13721   echo "$as_me: failed program was:" >&5
13722 sed 's/^/| /' conftest.$ac_ext >&5
13723
13724 ac_cv_header_sys_wait_h=no
13725 fi
13726 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13727 fi
13728 echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
13729 echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
13730 if test $ac_cv_header_sys_wait_h = yes; then
13731
13732 cat >>confdefs.h <<\_ACEOF
13733 #define HAVE_SYS_WAIT_H 1
13734 _ACEOF
13735
13736 fi
13737
13738 echo "$as_me:$LINENO: checking whether termios.h defines TIOCGWINSZ" >&5
13739 echo $ECHO_N "checking whether termios.h defines TIOCGWINSZ... $ECHO_C" >&6
13740 if test "${ac_cv_sys_tiocgwinsz_in_termios_h+set}" = set; then
13741   echo $ECHO_N "(cached) $ECHO_C" >&6
13742 else
13743   cat >conftest.$ac_ext <<_ACEOF
13744 /* confdefs.h.  */
13745 _ACEOF
13746 cat confdefs.h >>conftest.$ac_ext
13747 cat >>conftest.$ac_ext <<_ACEOF
13748 /* end confdefs.h.  */
13749 #include <sys/types.h>
13750 #include <termios.h>
13751 #ifdef TIOCGWINSZ
13752   yes
13753 #endif
13754
13755 _ACEOF
13756 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13757   $EGREP "yes" >/dev/null 2>&1; then
13758   ac_cv_sys_tiocgwinsz_in_termios_h=yes
13759 else
13760   ac_cv_sys_tiocgwinsz_in_termios_h=no
13761 fi
13762 rm -f conftest*
13763
13764 fi
13765 echo "$as_me:$LINENO: result: $ac_cv_sys_tiocgwinsz_in_termios_h" >&5
13766 echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_termios_h" >&6
13767
13768 if test $ac_cv_sys_tiocgwinsz_in_termios_h != yes; then
13769   echo "$as_me:$LINENO: checking whether sys/ioctl.h defines TIOCGWINSZ" >&5
13770 echo $ECHO_N "checking whether sys/ioctl.h defines TIOCGWINSZ... $ECHO_C" >&6
13771 if test "${ac_cv_sys_tiocgwinsz_in_sys_ioctl_h+set}" = set; then
13772   echo $ECHO_N "(cached) $ECHO_C" >&6
13773 else
13774   cat >conftest.$ac_ext <<_ACEOF
13775 /* confdefs.h.  */
13776 _ACEOF
13777 cat confdefs.h >>conftest.$ac_ext
13778 cat >>conftest.$ac_ext <<_ACEOF
13779 /* end confdefs.h.  */
13780 #include <sys/types.h>
13781 #include <sys/ioctl.h>
13782 #ifdef TIOCGWINSZ
13783   yes
13784 #endif
13785
13786 _ACEOF
13787 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13788   $EGREP "yes" >/dev/null 2>&1; then
13789   ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=yes
13790 else
13791   ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=no
13792 fi
13793 rm -f conftest*
13794
13795 fi
13796 echo "$as_me:$LINENO: result: $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&5
13797 echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&6
13798
13799   if test $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h = yes; then
13800
13801 cat >>confdefs.h <<\_ACEOF
13802 #define GWINSZ_IN_SYS_IOCTL 1
13803 _ACEOF
13804
13805   fi
13806 fi
13807
13808
13809
13810
13811
13812
13813
13814
13815
13816
13817
13818
13819
13820
13821
13822
13823
13824
13825
13826
13827
13828
13829
13830
13831
13832
13833
13834
13835
13836
13837
13838
13839
13840
13841
13842
13843
13844
13845
13846
13847
13848
13849
13850
13851
13852
13853
13854
13855
13856 for ac_header in \
13857         arpa/inet.h             \
13858         arpa/nameser.h  \
13859         assert.h                \
13860         bits/types.h    \
13861         conio.h                 \
13862         crypt.h                 \
13863         direct.h                \
13864         errno.h                 \
13865         fcntl.h                 \
13866         filio.h                 \
13867         getopt.h                \
13868         grp.h                   \
13869         io.h                    \
13870         libutil.h               \
13871         limits.h                \
13872         locale.h                \
13873         malloc.h                \
13874         memory.h                \
13875         psap.h                  \
13876         pwd.h                   \
13877         process.h               \
13878         sgtty.h                 \
13879         shadow.h                \
13880         stddef.h                \
13881         string.h                \
13882         strings.h               \
13883         sysexits.h              \
13884         sys/file.h              \
13885         sys/filio.h             \
13886         sys/fstyp.h             \
13887         sys/errno.h             \
13888         sys/ioctl.h             \
13889         sys/param.h             \
13890         sys/privgrp.h   \
13891         sys/resource.h  \
13892         sys/select.h    \
13893         sys/socket.h    \
13894         sys/stat.h              \
13895         sys/syslog.h    \
13896         sys/time.h              \
13897         sys/types.h             \
13898         sys/uio.h               \
13899         sys/vmount.h    \
13900         syslog.h                \
13901         termios.h               \
13902         unistd.h                \
13903         utime.h                 \
13904
13905 do
13906 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13907 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13908   echo "$as_me:$LINENO: checking for $ac_header" >&5
13909 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13910 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13911   echo $ECHO_N "(cached) $ECHO_C" >&6
13912 fi
13913 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13914 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13915 else
13916   # Is the header compilable?
13917 echo "$as_me:$LINENO: checking $ac_header usability" >&5
13918 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13919 cat >conftest.$ac_ext <<_ACEOF
13920 /* confdefs.h.  */
13921 _ACEOF
13922 cat confdefs.h >>conftest.$ac_ext
13923 cat >>conftest.$ac_ext <<_ACEOF
13924 /* end confdefs.h.  */
13925 $ac_includes_default
13926 #include <$ac_header>
13927 _ACEOF
13928 rm -f conftest.$ac_objext
13929 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13930   (eval $ac_compile) 2>conftest.er1
13931   ac_status=$?
13932   grep -v '^ *+' conftest.er1 >conftest.err
13933   rm -f conftest.er1
13934   cat conftest.err >&5
13935   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13936   (exit $ac_status); } &&
13937          { ac_try='test -z "$ac_c_werror_flag"
13938                          || test ! -s conftest.err'
13939   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13940   (eval $ac_try) 2>&5
13941   ac_status=$?
13942   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13943   (exit $ac_status); }; } &&
13944          { ac_try='test -s conftest.$ac_objext'
13945   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13946   (eval $ac_try) 2>&5
13947   ac_status=$?
13948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13949   (exit $ac_status); }; }; then
13950   ac_header_compiler=yes
13951 else
13952   echo "$as_me: failed program was:" >&5
13953 sed 's/^/| /' conftest.$ac_ext >&5
13954
13955 ac_header_compiler=no
13956 fi
13957 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13958 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13959 echo "${ECHO_T}$ac_header_compiler" >&6
13960
13961 # Is the header present?
13962 echo "$as_me:$LINENO: checking $ac_header presence" >&5
13963 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13964 cat >conftest.$ac_ext <<_ACEOF
13965 /* confdefs.h.  */
13966 _ACEOF
13967 cat confdefs.h >>conftest.$ac_ext
13968 cat >>conftest.$ac_ext <<_ACEOF
13969 /* end confdefs.h.  */
13970 #include <$ac_header>
13971 _ACEOF
13972 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13973   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13974   ac_status=$?
13975   grep -v '^ *+' conftest.er1 >conftest.err
13976   rm -f conftest.er1
13977   cat conftest.err >&5
13978   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13979   (exit $ac_status); } >/dev/null; then
13980   if test -s conftest.err; then
13981     ac_cpp_err=$ac_c_preproc_warn_flag
13982     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
13983   else
13984     ac_cpp_err=
13985   fi
13986 else
13987   ac_cpp_err=yes
13988 fi
13989 if test -z "$ac_cpp_err"; then
13990   ac_header_preproc=yes
13991 else
13992   echo "$as_me: failed program was:" >&5
13993 sed 's/^/| /' conftest.$ac_ext >&5
13994
13995   ac_header_preproc=no
13996 fi
13997 rm -f conftest.err conftest.$ac_ext
13998 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13999 echo "${ECHO_T}$ac_header_preproc" >&6
14000
14001 # So?  What about this header?
14002 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14003   yes:no: )
14004     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14005 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14006     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14007 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14008     ac_header_preproc=yes
14009     ;;
14010   no:yes:* )
14011     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14012 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14013     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14014 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14015     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14016 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14017     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14018 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14019     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14020 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14021     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14022 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14023     (
14024       cat <<\_ASBOX
14025 ## --------------------------------------------- ##
14026 ## Report this to <http://www.openldap.org/its/> ##
14027 ## --------------------------------------------- ##
14028 _ASBOX
14029     ) |
14030       sed "s/^/$as_me: WARNING:     /" >&2
14031     ;;
14032 esac
14033 echo "$as_me:$LINENO: checking for $ac_header" >&5
14034 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14035 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14036   echo $ECHO_N "(cached) $ECHO_C" >&6
14037 else
14038   eval "$as_ac_Header=\$ac_header_preproc"
14039 fi
14040 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14041 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14042
14043 fi
14044 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14045   cat >>confdefs.h <<_ACEOF
14046 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14047 _ACEOF
14048
14049 fi
14050
14051 done
14052
14053
14054 if test "$ac_cv_mingw32" = yes ; then
14055
14056
14057 for ac_header in winsock.h winsock2.h
14058 do
14059 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14060 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14061   echo "$as_me:$LINENO: checking for $ac_header" >&5
14062 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14063 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14064   echo $ECHO_N "(cached) $ECHO_C" >&6
14065 fi
14066 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14067 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14068 else
14069   # Is the header compilable?
14070 echo "$as_me:$LINENO: checking $ac_header usability" >&5
14071 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
14072 cat >conftest.$ac_ext <<_ACEOF
14073 /* confdefs.h.  */
14074 _ACEOF
14075 cat confdefs.h >>conftest.$ac_ext
14076 cat >>conftest.$ac_ext <<_ACEOF
14077 /* end confdefs.h.  */
14078 $ac_includes_default
14079 #include <$ac_header>
14080 _ACEOF
14081 rm -f conftest.$ac_objext
14082 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14083   (eval $ac_compile) 2>conftest.er1
14084   ac_status=$?
14085   grep -v '^ *+' conftest.er1 >conftest.err
14086   rm -f conftest.er1
14087   cat conftest.err >&5
14088   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14089   (exit $ac_status); } &&
14090          { ac_try='test -z "$ac_c_werror_flag"
14091                          || test ! -s conftest.err'
14092   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14093   (eval $ac_try) 2>&5
14094   ac_status=$?
14095   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14096   (exit $ac_status); }; } &&
14097          { ac_try='test -s conftest.$ac_objext'
14098   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14099   (eval $ac_try) 2>&5
14100   ac_status=$?
14101   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14102   (exit $ac_status); }; }; then
14103   ac_header_compiler=yes
14104 else
14105   echo "$as_me: failed program was:" >&5
14106 sed 's/^/| /' conftest.$ac_ext >&5
14107
14108 ac_header_compiler=no
14109 fi
14110 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14111 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14112 echo "${ECHO_T}$ac_header_compiler" >&6
14113
14114 # Is the header present?
14115 echo "$as_me:$LINENO: checking $ac_header presence" >&5
14116 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
14117 cat >conftest.$ac_ext <<_ACEOF
14118 /* confdefs.h.  */
14119 _ACEOF
14120 cat confdefs.h >>conftest.$ac_ext
14121 cat >>conftest.$ac_ext <<_ACEOF
14122 /* end confdefs.h.  */
14123 #include <$ac_header>
14124 _ACEOF
14125 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
14126   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14127   ac_status=$?
14128   grep -v '^ *+' conftest.er1 >conftest.err
14129   rm -f conftest.er1
14130   cat conftest.err >&5
14131   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14132   (exit $ac_status); } >/dev/null; then
14133   if test -s conftest.err; then
14134     ac_cpp_err=$ac_c_preproc_warn_flag
14135     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
14136   else
14137     ac_cpp_err=
14138   fi
14139 else
14140   ac_cpp_err=yes
14141 fi
14142 if test -z "$ac_cpp_err"; then
14143   ac_header_preproc=yes
14144 else
14145   echo "$as_me: failed program was:" >&5
14146 sed 's/^/| /' conftest.$ac_ext >&5
14147
14148   ac_header_preproc=no
14149 fi
14150 rm -f conftest.err conftest.$ac_ext
14151 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14152 echo "${ECHO_T}$ac_header_preproc" >&6
14153
14154 # So?  What about this header?
14155 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14156   yes:no: )
14157     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14158 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14159     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14160 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14161     ac_header_preproc=yes
14162     ;;
14163   no:yes:* )
14164     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14165 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14166     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14167 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14168     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14169 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14170     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14171 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14172     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14173 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14174     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14175 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14176     (
14177       cat <<\_ASBOX
14178 ## --------------------------------------------- ##
14179 ## Report this to <http://www.openldap.org/its/> ##
14180 ## --------------------------------------------- ##
14181 _ASBOX
14182     ) |
14183       sed "s/^/$as_me: WARNING:     /" >&2
14184     ;;
14185 esac
14186 echo "$as_me:$LINENO: checking for $ac_header" >&5
14187 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14188 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14189   echo $ECHO_N "(cached) $ECHO_C" >&6
14190 else
14191   eval "$as_ac_Header=\$ac_header_preproc"
14192 fi
14193 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14194 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14195
14196 fi
14197 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14198   cat >>confdefs.h <<_ACEOF
14199 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14200 _ACEOF
14201
14202 fi
14203
14204 done
14205
14206 fi
14207
14208
14209 for ac_header in resolv.h
14210 do
14211 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14212 echo "$as_me:$LINENO: checking for $ac_header" >&5
14213 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14214 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14215   echo $ECHO_N "(cached) $ECHO_C" >&6
14216 else
14217   cat >conftest.$ac_ext <<_ACEOF
14218 /* confdefs.h.  */
14219 _ACEOF
14220 cat confdefs.h >>conftest.$ac_ext
14221 cat >>conftest.$ac_ext <<_ACEOF
14222 /* end confdefs.h.  */
14223 $ac_includes_default
14224 #include <netinet/in.h>
14225
14226
14227 #include <$ac_header>
14228 _ACEOF
14229 rm -f conftest.$ac_objext
14230 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14231   (eval $ac_compile) 2>conftest.er1
14232   ac_status=$?
14233   grep -v '^ *+' conftest.er1 >conftest.err
14234   rm -f conftest.er1
14235   cat conftest.err >&5
14236   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14237   (exit $ac_status); } &&
14238          { ac_try='test -z "$ac_c_werror_flag"
14239                          || test ! -s conftest.err'
14240   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14241   (eval $ac_try) 2>&5
14242   ac_status=$?
14243   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14244   (exit $ac_status); }; } &&
14245          { ac_try='test -s conftest.$ac_objext'
14246   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14247   (eval $ac_try) 2>&5
14248   ac_status=$?
14249   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14250   (exit $ac_status); }; }; then
14251   eval "$as_ac_Header=yes"
14252 else
14253   echo "$as_me: failed program was:" >&5
14254 sed 's/^/| /' conftest.$ac_ext >&5
14255
14256 eval "$as_ac_Header=no"
14257 fi
14258 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14259 fi
14260 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14261 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14262 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14263   cat >>confdefs.h <<_ACEOF
14264 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14265 _ACEOF
14266
14267 fi
14268
14269 done
14270
14271
14272
14273 for ac_header in netinet/tcp.h
14274 do
14275 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14276 echo "$as_me:$LINENO: checking for $ac_header" >&5
14277 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14278 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14279   echo $ECHO_N "(cached) $ECHO_C" >&6
14280 else
14281   cat >conftest.$ac_ext <<_ACEOF
14282 /* confdefs.h.  */
14283 _ACEOF
14284 cat confdefs.h >>conftest.$ac_ext
14285 cat >>conftest.$ac_ext <<_ACEOF
14286 /* end confdefs.h.  */
14287 $ac_includes_default
14288 #include <netinet/in.h>
14289
14290
14291 #include <$ac_header>
14292 _ACEOF
14293 rm -f conftest.$ac_objext
14294 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14295   (eval $ac_compile) 2>conftest.er1
14296   ac_status=$?
14297   grep -v '^ *+' conftest.er1 >conftest.err
14298   rm -f conftest.er1
14299   cat conftest.err >&5
14300   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14301   (exit $ac_status); } &&
14302          { ac_try='test -z "$ac_c_werror_flag"
14303                          || test ! -s conftest.err'
14304   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14305   (eval $ac_try) 2>&5
14306   ac_status=$?
14307   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14308   (exit $ac_status); }; } &&
14309          { ac_try='test -s conftest.$ac_objext'
14310   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14311   (eval $ac_try) 2>&5
14312   ac_status=$?
14313   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14314   (exit $ac_status); }; }; then
14315   eval "$as_ac_Header=yes"
14316 else
14317   echo "$as_me: failed program was:" >&5
14318 sed 's/^/| /' conftest.$ac_ext >&5
14319
14320 eval "$as_ac_Header=no"
14321 fi
14322 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14323 fi
14324 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14325 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14326 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14327   cat >>confdefs.h <<_ACEOF
14328 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14329 _ACEOF
14330
14331 fi
14332
14333 done
14334
14335
14336
14337 for ac_header in sys/ucred.h
14338 do
14339 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14340 echo "$as_me:$LINENO: checking for $ac_header" >&5
14341 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14342 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14343   echo $ECHO_N "(cached) $ECHO_C" >&6
14344 else
14345   cat >conftest.$ac_ext <<_ACEOF
14346 /* confdefs.h.  */
14347 _ACEOF
14348 cat confdefs.h >>conftest.$ac_ext
14349 cat >>conftest.$ac_ext <<_ACEOF
14350 /* end confdefs.h.  */
14351 $ac_includes_default
14352 #ifdef HAVE_SYS_PARAM_H
14353 #include <sys/param.h>
14354 #endif
14355
14356
14357 #include <$ac_header>
14358 _ACEOF
14359 rm -f conftest.$ac_objext
14360 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14361   (eval $ac_compile) 2>conftest.er1
14362   ac_status=$?
14363   grep -v '^ *+' conftest.er1 >conftest.err
14364   rm -f conftest.er1
14365   cat conftest.err >&5
14366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14367   (exit $ac_status); } &&
14368          { ac_try='test -z "$ac_c_werror_flag"
14369                          || test ! -s conftest.err'
14370   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14371   (eval $ac_try) 2>&5
14372   ac_status=$?
14373   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14374   (exit $ac_status); }; } &&
14375          { ac_try='test -s conftest.$ac_objext'
14376   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14377   (eval $ac_try) 2>&5
14378   ac_status=$?
14379   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14380   (exit $ac_status); }; }; then
14381   eval "$as_ac_Header=yes"
14382 else
14383   echo "$as_me: failed program was:" >&5
14384 sed 's/^/| /' conftest.$ac_ext >&5
14385
14386 eval "$as_ac_Header=no"
14387 fi
14388 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14389 fi
14390 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14391 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14392 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14393   cat >>confdefs.h <<_ACEOF
14394 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14395 _ACEOF
14396
14397 fi
14398
14399 done
14400
14401
14402
14403
14404
14405 for ac_func in sigaction sigset
14406 do
14407 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14408 echo "$as_me:$LINENO: checking for $ac_func" >&5
14409 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14410 if eval "test \"\${$as_ac_var+set}\" = set"; then
14411   echo $ECHO_N "(cached) $ECHO_C" >&6
14412 else
14413   cat >conftest.$ac_ext <<_ACEOF
14414 /* confdefs.h.  */
14415 _ACEOF
14416 cat confdefs.h >>conftest.$ac_ext
14417 cat >>conftest.$ac_ext <<_ACEOF
14418 /* end confdefs.h.  */
14419 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14420    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14421 #define $ac_func innocuous_$ac_func
14422
14423 /* System header to define __stub macros and hopefully few prototypes,
14424     which can conflict with char $ac_func (); below.
14425     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14426     <limits.h> exists even on freestanding compilers.  */
14427
14428 #ifdef __STDC__
14429 # include <limits.h>
14430 #else
14431 # include <assert.h>
14432 #endif
14433
14434 #undef $ac_func
14435
14436 /* Override any gcc2 internal prototype to avoid an error.  */
14437 #ifdef __cplusplus
14438 extern "C"
14439 {
14440 #endif
14441 /* We use char because int might match the return type of a gcc2
14442    builtin and then its argument prototype would still apply.  */
14443 char $ac_func ();
14444 /* The GNU C library defines this for functions which it implements
14445     to always fail with ENOSYS.  Some functions are actually named
14446     something starting with __ and the normal name is an alias.  */
14447 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14448 choke me
14449 #else
14450 char (*f) () = $ac_func;
14451 #endif
14452 #ifdef __cplusplus
14453 }
14454 #endif
14455
14456 int
14457 main ()
14458 {
14459 return f != $ac_func;
14460   ;
14461   return 0;
14462 }
14463 _ACEOF
14464 rm -f conftest.$ac_objext conftest$ac_exeext
14465 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14466   (eval $ac_link) 2>conftest.er1
14467   ac_status=$?
14468   grep -v '^ *+' conftest.er1 >conftest.err
14469   rm -f conftest.er1
14470   cat conftest.err >&5
14471   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14472   (exit $ac_status); } &&
14473          { ac_try='test -z "$ac_c_werror_flag"
14474                          || test ! -s conftest.err'
14475   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14476   (eval $ac_try) 2>&5
14477   ac_status=$?
14478   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14479   (exit $ac_status); }; } &&
14480          { ac_try='test -s conftest$ac_exeext'
14481   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14482   (eval $ac_try) 2>&5
14483   ac_status=$?
14484   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14485   (exit $ac_status); }; }; then
14486   eval "$as_ac_var=yes"
14487 else
14488   echo "$as_me: failed program was:" >&5
14489 sed 's/^/| /' conftest.$ac_ext >&5
14490
14491 eval "$as_ac_var=no"
14492 fi
14493 rm -f conftest.err conftest.$ac_objext \
14494       conftest$ac_exeext conftest.$ac_ext
14495 fi
14496 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14497 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14498 if test `eval echo '${'$as_ac_var'}'` = yes; then
14499   cat >>confdefs.h <<_ACEOF
14500 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14501 _ACEOF
14502
14503 fi
14504 done
14505
14506
14507 if test $ac_cv_func_sigaction = no && test $ac_cv_func_sigaction = no ; then
14508
14509 echo "$as_me:$LINENO: checking for sigset in -lV3" >&5
14510 echo $ECHO_N "checking for sigset in -lV3... $ECHO_C" >&6
14511 if test "${ac_cv_lib_V3_sigset+set}" = set; then
14512   echo $ECHO_N "(cached) $ECHO_C" >&6
14513 else
14514   ac_check_lib_save_LIBS=$LIBS
14515 LIBS="-lV3  $LIBS"
14516 cat >conftest.$ac_ext <<_ACEOF
14517 /* confdefs.h.  */
14518 _ACEOF
14519 cat confdefs.h >>conftest.$ac_ext
14520 cat >>conftest.$ac_ext <<_ACEOF
14521 /* end confdefs.h.  */
14522
14523 /* Override any gcc2 internal prototype to avoid an error.  */
14524 #ifdef __cplusplus
14525 extern "C"
14526 #endif
14527 /* We use char because int might match the return type of a gcc2
14528    builtin and then its argument prototype would still apply.  */
14529 char sigset ();
14530 int
14531 main ()
14532 {
14533 sigset ();
14534   ;
14535   return 0;
14536 }
14537 _ACEOF
14538 rm -f conftest.$ac_objext conftest$ac_exeext
14539 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14540   (eval $ac_link) 2>conftest.er1
14541   ac_status=$?
14542   grep -v '^ *+' conftest.er1 >conftest.err
14543   rm -f conftest.er1
14544   cat conftest.err >&5
14545   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14546   (exit $ac_status); } &&
14547          { ac_try='test -z "$ac_c_werror_flag"
14548                          || test ! -s conftest.err'
14549   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14550   (eval $ac_try) 2>&5
14551   ac_status=$?
14552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14553   (exit $ac_status); }; } &&
14554          { ac_try='test -s conftest$ac_exeext'
14555   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14556   (eval $ac_try) 2>&5
14557   ac_status=$?
14558   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14559   (exit $ac_status); }; }; then
14560   ac_cv_lib_V3_sigset=yes
14561 else
14562   echo "$as_me: failed program was:" >&5
14563 sed 's/^/| /' conftest.$ac_ext >&5
14564
14565 ac_cv_lib_V3_sigset=no
14566 fi
14567 rm -f conftest.err conftest.$ac_objext \
14568       conftest$ac_exeext conftest.$ac_ext
14569 LIBS=$ac_check_lib_save_LIBS
14570 fi
14571 echo "$as_me:$LINENO: result: $ac_cv_lib_V3_sigset" >&5
14572 echo "${ECHO_T}$ac_cv_lib_V3_sigset" >&6
14573 if test $ac_cv_lib_V3_sigset = yes; then
14574   cat >>confdefs.h <<_ACEOF
14575 #define HAVE_LIBV3 1
14576 _ACEOF
14577
14578   LIBS="-lV3 $LIBS"
14579
14580 fi
14581
14582 fi
14583
14584 if test "$ac_cv_header_winsock_h" = yes; then
14585 echo "$as_me:$LINENO: checking for winsock" >&5
14586 echo $ECHO_N "checking for winsock... $ECHO_C" >&6
14587 if test "${ol_cv_winsock+set}" = set; then
14588   echo $ECHO_N "(cached) $ECHO_C" >&6
14589 else
14590   save_LIBS="$LIBS"
14591 for curlib in ws2_32 wsock32; do
14592         LIBS="$LIBS -l$curlib"
14593         cat >conftest.$ac_ext <<_ACEOF
14594 /* confdefs.h.  */
14595 _ACEOF
14596 cat confdefs.h >>conftest.$ac_ext
14597 cat >>conftest.$ac_ext <<_ACEOF
14598 /* end confdefs.h.  */
14599 #include <winsock.h>
14600
14601 int
14602 main ()
14603 {
14604
14605                         socket(0,0,0);
14606                         select(0,NULL,NULL,NULL,NULL);
14607                         closesocket(0);
14608                         gethostname(NULL,0);
14609
14610   ;
14611   return 0;
14612 }
14613 _ACEOF
14614 rm -f conftest.$ac_objext conftest$ac_exeext
14615 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14616   (eval $ac_link) 2>conftest.er1
14617   ac_status=$?
14618   grep -v '^ *+' conftest.er1 >conftest.err
14619   rm -f conftest.er1
14620   cat conftest.err >&5
14621   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14622   (exit $ac_status); } &&
14623          { ac_try='test -z "$ac_c_werror_flag"
14624                          || test ! -s conftest.err'
14625   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14626   (eval $ac_try) 2>&5
14627   ac_status=$?
14628   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14629   (exit $ac_status); }; } &&
14630          { ac_try='test -s conftest$ac_exeext'
14631   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14632   (eval $ac_try) 2>&5
14633   ac_status=$?
14634   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14635   (exit $ac_status); }; }; then
14636   ol_cv_winsock=yes
14637 else
14638   echo "$as_me: failed program was:" >&5
14639 sed 's/^/| /' conftest.$ac_ext >&5
14640
14641 ol_cv_winsock=no
14642 fi
14643 rm -f conftest.err conftest.$ac_objext \
14644       conftest$ac_exeext conftest.$ac_ext
14645
14646         if test $ol_cv_winsock = yes; then
14647
14648 cat >>confdefs.h <<\_ACEOF
14649 #define HAVE_WINSOCK 1
14650 _ACEOF
14651
14652                 ac_cv_func_socket=yes
14653                 ac_cv_func_select=yes
14654                 ac_cv_func_closesocket=yes
14655                 ac_cv_func_gethostname=yes
14656                 if test $curlib = ws2_32; then
14657                         ol_cv_winsock=winsock2
14658
14659 cat >>confdefs.h <<\_ACEOF
14660 #define HAVE_WINSOCK2 1
14661 _ACEOF
14662
14663                 fi
14664                 break
14665         fi
14666         LIBS="$save_LIBS"
14667 done
14668 fi
14669 echo "$as_me:$LINENO: result: $ol_cv_winsock" >&5
14670 echo "${ECHO_T}$ol_cv_winsock" >&6
14671 fi
14672
14673
14674 echo "$as_me:$LINENO: checking for socket" >&5
14675 echo $ECHO_N "checking for socket... $ECHO_C" >&6
14676 if test "${ac_cv_func_socket+set}" = set; then
14677   echo $ECHO_N "(cached) $ECHO_C" >&6
14678 else
14679   cat >conftest.$ac_ext <<_ACEOF
14680 /* confdefs.h.  */
14681 _ACEOF
14682 cat confdefs.h >>conftest.$ac_ext
14683 cat >>conftest.$ac_ext <<_ACEOF
14684 /* end confdefs.h.  */
14685 /* Define socket to an innocuous variant, in case <limits.h> declares socket.
14686    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14687 #define socket innocuous_socket
14688
14689 /* System header to define __stub macros and hopefully few prototypes,
14690     which can conflict with char socket (); below.
14691     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14692     <limits.h> exists even on freestanding compilers.  */
14693
14694 #ifdef __STDC__
14695 # include <limits.h>
14696 #else
14697 # include <assert.h>
14698 #endif
14699
14700 #undef socket
14701
14702 /* Override any gcc2 internal prototype to avoid an error.  */
14703 #ifdef __cplusplus
14704 extern "C"
14705 {
14706 #endif
14707 /* We use char because int might match the return type of a gcc2
14708    builtin and then its argument prototype would still apply.  */
14709 char socket ();
14710 /* The GNU C library defines this for functions which it implements
14711     to always fail with ENOSYS.  Some functions are actually named
14712     something starting with __ and the normal name is an alias.  */
14713 #if defined (__stub_socket) || defined (__stub___socket)
14714 choke me
14715 #else
14716 char (*f) () = socket;
14717 #endif
14718 #ifdef __cplusplus
14719 }
14720 #endif
14721
14722 int
14723 main ()
14724 {
14725 return f != socket;
14726   ;
14727   return 0;
14728 }
14729 _ACEOF
14730 rm -f conftest.$ac_objext conftest$ac_exeext
14731 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14732   (eval $ac_link) 2>conftest.er1
14733   ac_status=$?
14734   grep -v '^ *+' conftest.er1 >conftest.err
14735   rm -f conftest.er1
14736   cat conftest.err >&5
14737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14738   (exit $ac_status); } &&
14739          { ac_try='test -z "$ac_c_werror_flag"
14740                          || test ! -s conftest.err'
14741   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14742   (eval $ac_try) 2>&5
14743   ac_status=$?
14744   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14745   (exit $ac_status); }; } &&
14746          { ac_try='test -s conftest$ac_exeext'
14747   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14748   (eval $ac_try) 2>&5
14749   ac_status=$?
14750   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14751   (exit $ac_status); }; }; then
14752   ac_cv_func_socket=yes
14753 else
14754   echo "$as_me: failed program was:" >&5
14755 sed 's/^/| /' conftest.$ac_ext >&5
14756
14757 ac_cv_func_socket=no
14758 fi
14759 rm -f conftest.err conftest.$ac_objext \
14760       conftest$ac_exeext conftest.$ac_ext
14761 fi
14762 echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
14763 echo "${ECHO_T}$ac_cv_func_socket" >&6
14764 if test $ac_cv_func_socket = yes; then
14765   :
14766 else
14767
14768
14769 echo "$as_me:$LINENO: checking for main in -lsocket" >&5
14770 echo $ECHO_N "checking for main in -lsocket... $ECHO_C" >&6
14771 if test "${ac_cv_lib_socket_main+set}" = set; then
14772   echo $ECHO_N "(cached) $ECHO_C" >&6
14773 else
14774   ac_check_lib_save_LIBS=$LIBS
14775 LIBS="-lsocket  $LIBS"
14776 cat >conftest.$ac_ext <<_ACEOF
14777 /* confdefs.h.  */
14778 _ACEOF
14779 cat confdefs.h >>conftest.$ac_ext
14780 cat >>conftest.$ac_ext <<_ACEOF
14781 /* end confdefs.h.  */
14782
14783
14784 int
14785 main ()
14786 {
14787 main ();
14788   ;
14789   return 0;
14790 }
14791 _ACEOF
14792 rm -f conftest.$ac_objext conftest$ac_exeext
14793 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14794   (eval $ac_link) 2>conftest.er1
14795   ac_status=$?
14796   grep -v '^ *+' conftest.er1 >conftest.err
14797   rm -f conftest.er1
14798   cat conftest.err >&5
14799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14800   (exit $ac_status); } &&
14801          { ac_try='test -z "$ac_c_werror_flag"
14802                          || test ! -s conftest.err'
14803   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14804   (eval $ac_try) 2>&5
14805   ac_status=$?
14806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14807   (exit $ac_status); }; } &&
14808          { ac_try='test -s conftest$ac_exeext'
14809   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14810   (eval $ac_try) 2>&5
14811   ac_status=$?
14812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14813   (exit $ac_status); }; }; then
14814   ac_cv_lib_socket_main=yes
14815 else
14816   echo "$as_me: failed program was:" >&5
14817 sed 's/^/| /' conftest.$ac_ext >&5
14818
14819 ac_cv_lib_socket_main=no
14820 fi
14821 rm -f conftest.err conftest.$ac_objext \
14822       conftest$ac_exeext conftest.$ac_ext
14823 LIBS=$ac_check_lib_save_LIBS
14824 fi
14825 echo "$as_me:$LINENO: result: $ac_cv_lib_socket_main" >&5
14826 echo "${ECHO_T}$ac_cv_lib_socket_main" >&6
14827 if test $ac_cv_lib_socket_main = yes; then
14828   cat >>confdefs.h <<_ACEOF
14829 #define HAVE_LIBSOCKET 1
14830 _ACEOF
14831
14832   LIBS="-lsocket $LIBS"
14833
14834 fi
14835
14836
14837 echo "$as_me:$LINENO: checking for main in -lnet" >&5
14838 echo $ECHO_N "checking for main in -lnet... $ECHO_C" >&6
14839 if test "${ac_cv_lib_net_main+set}" = set; then
14840   echo $ECHO_N "(cached) $ECHO_C" >&6
14841 else
14842   ac_check_lib_save_LIBS=$LIBS
14843 LIBS="-lnet  $LIBS"
14844 cat >conftest.$ac_ext <<_ACEOF
14845 /* confdefs.h.  */
14846 _ACEOF
14847 cat confdefs.h >>conftest.$ac_ext
14848 cat >>conftest.$ac_ext <<_ACEOF
14849 /* end confdefs.h.  */
14850
14851
14852 int
14853 main ()
14854 {
14855 main ();
14856   ;
14857   return 0;
14858 }
14859 _ACEOF
14860 rm -f conftest.$ac_objext conftest$ac_exeext
14861 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14862   (eval $ac_link) 2>conftest.er1
14863   ac_status=$?
14864   grep -v '^ *+' conftest.er1 >conftest.err
14865   rm -f conftest.er1
14866   cat conftest.err >&5
14867   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14868   (exit $ac_status); } &&
14869          { ac_try='test -z "$ac_c_werror_flag"
14870                          || test ! -s conftest.err'
14871   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14872   (eval $ac_try) 2>&5
14873   ac_status=$?
14874   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14875   (exit $ac_status); }; } &&
14876          { ac_try='test -s conftest$ac_exeext'
14877   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14878   (eval $ac_try) 2>&5
14879   ac_status=$?
14880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14881   (exit $ac_status); }; }; then
14882   ac_cv_lib_net_main=yes
14883 else
14884   echo "$as_me: failed program was:" >&5
14885 sed 's/^/| /' conftest.$ac_ext >&5
14886
14887 ac_cv_lib_net_main=no
14888 fi
14889 rm -f conftest.err conftest.$ac_objext \
14890       conftest$ac_exeext conftest.$ac_ext
14891 LIBS=$ac_check_lib_save_LIBS
14892 fi
14893 echo "$as_me:$LINENO: result: $ac_cv_lib_net_main" >&5
14894 echo "${ECHO_T}$ac_cv_lib_net_main" >&6
14895 if test $ac_cv_lib_net_main = yes; then
14896   cat >>confdefs.h <<_ACEOF
14897 #define HAVE_LIBNET 1
14898 _ACEOF
14899
14900   LIBS="-lnet $LIBS"
14901
14902 fi
14903
14904
14905 echo "$as_me:$LINENO: checking for main in -lnsl_s" >&5
14906 echo $ECHO_N "checking for main in -lnsl_s... $ECHO_C" >&6
14907 if test "${ac_cv_lib_nsl_s_main+set}" = set; then
14908   echo $ECHO_N "(cached) $ECHO_C" >&6
14909 else
14910   ac_check_lib_save_LIBS=$LIBS
14911 LIBS="-lnsl_s  $LIBS"
14912 cat >conftest.$ac_ext <<_ACEOF
14913 /* confdefs.h.  */
14914 _ACEOF
14915 cat confdefs.h >>conftest.$ac_ext
14916 cat >>conftest.$ac_ext <<_ACEOF
14917 /* end confdefs.h.  */
14918
14919
14920 int
14921 main ()
14922 {
14923 main ();
14924   ;
14925   return 0;
14926 }
14927 _ACEOF
14928 rm -f conftest.$ac_objext conftest$ac_exeext
14929 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14930   (eval $ac_link) 2>conftest.er1
14931   ac_status=$?
14932   grep -v '^ *+' conftest.er1 >conftest.err
14933   rm -f conftest.er1
14934   cat conftest.err >&5
14935   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14936   (exit $ac_status); } &&
14937          { ac_try='test -z "$ac_c_werror_flag"
14938                          || test ! -s conftest.err'
14939   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14940   (eval $ac_try) 2>&5
14941   ac_status=$?
14942   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14943   (exit $ac_status); }; } &&
14944          { ac_try='test -s conftest$ac_exeext'
14945   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14946   (eval $ac_try) 2>&5
14947   ac_status=$?
14948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14949   (exit $ac_status); }; }; then
14950   ac_cv_lib_nsl_s_main=yes
14951 else
14952   echo "$as_me: failed program was:" >&5
14953 sed 's/^/| /' conftest.$ac_ext >&5
14954
14955 ac_cv_lib_nsl_s_main=no
14956 fi
14957 rm -f conftest.err conftest.$ac_objext \
14958       conftest$ac_exeext conftest.$ac_ext
14959 LIBS=$ac_check_lib_save_LIBS
14960 fi
14961 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_s_main" >&5
14962 echo "${ECHO_T}$ac_cv_lib_nsl_s_main" >&6
14963 if test $ac_cv_lib_nsl_s_main = yes; then
14964   cat >>confdefs.h <<_ACEOF
14965 #define HAVE_LIBNSL_S 1
14966 _ACEOF
14967
14968   LIBS="-lnsl_s $LIBS"
14969
14970 fi
14971
14972
14973 echo "$as_me:$LINENO: checking for main in -lnsl" >&5
14974 echo $ECHO_N "checking for main in -lnsl... $ECHO_C" >&6
14975 if test "${ac_cv_lib_nsl_main+set}" = set; then
14976   echo $ECHO_N "(cached) $ECHO_C" >&6
14977 else
14978   ac_check_lib_save_LIBS=$LIBS
14979 LIBS="-lnsl  $LIBS"
14980 cat >conftest.$ac_ext <<_ACEOF
14981 /* confdefs.h.  */
14982 _ACEOF
14983 cat confdefs.h >>conftest.$ac_ext
14984 cat >>conftest.$ac_ext <<_ACEOF
14985 /* end confdefs.h.  */
14986
14987
14988 int
14989 main ()
14990 {
14991 main ();
14992   ;
14993   return 0;
14994 }
14995 _ACEOF
14996 rm -f conftest.$ac_objext conftest$ac_exeext
14997 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14998   (eval $ac_link) 2>conftest.er1
14999   ac_status=$?
15000   grep -v '^ *+' conftest.er1 >conftest.err
15001   rm -f conftest.er1
15002   cat conftest.err >&5
15003   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15004   (exit $ac_status); } &&
15005          { ac_try='test -z "$ac_c_werror_flag"
15006                          || test ! -s conftest.err'
15007   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15008   (eval $ac_try) 2>&5
15009   ac_status=$?
15010   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15011   (exit $ac_status); }; } &&
15012          { ac_try='test -s conftest$ac_exeext'
15013   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15014   (eval $ac_try) 2>&5
15015   ac_status=$?
15016   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15017   (exit $ac_status); }; }; then
15018   ac_cv_lib_nsl_main=yes
15019 else
15020   echo "$as_me: failed program was:" >&5
15021 sed 's/^/| /' conftest.$ac_ext >&5
15022
15023 ac_cv_lib_nsl_main=no
15024 fi
15025 rm -f conftest.err conftest.$ac_objext \
15026       conftest$ac_exeext conftest.$ac_ext
15027 LIBS=$ac_check_lib_save_LIBS
15028 fi
15029 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_main" >&5
15030 echo "${ECHO_T}$ac_cv_lib_nsl_main" >&6
15031 if test $ac_cv_lib_nsl_main = yes; then
15032   cat >>confdefs.h <<_ACEOF
15033 #define HAVE_LIBNSL 1
15034 _ACEOF
15035
15036   LIBS="-lnsl $LIBS"
15037
15038 fi
15039
15040
15041 echo "$as_me:$LINENO: checking for socket in -linet" >&5
15042 echo $ECHO_N "checking for socket in -linet... $ECHO_C" >&6
15043 if test "${ac_cv_lib_inet_socket+set}" = set; then
15044   echo $ECHO_N "(cached) $ECHO_C" >&6
15045 else
15046   ac_check_lib_save_LIBS=$LIBS
15047 LIBS="-linet  $LIBS"
15048 cat >conftest.$ac_ext <<_ACEOF
15049 /* confdefs.h.  */
15050 _ACEOF
15051 cat confdefs.h >>conftest.$ac_ext
15052 cat >>conftest.$ac_ext <<_ACEOF
15053 /* end confdefs.h.  */
15054
15055 /* Override any gcc2 internal prototype to avoid an error.  */
15056 #ifdef __cplusplus
15057 extern "C"
15058 #endif
15059 /* We use char because int might match the return type of a gcc2
15060    builtin and then its argument prototype would still apply.  */
15061 char socket ();
15062 int
15063 main ()
15064 {
15065 socket ();
15066   ;
15067   return 0;
15068 }
15069 _ACEOF
15070 rm -f conftest.$ac_objext conftest$ac_exeext
15071 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15072   (eval $ac_link) 2>conftest.er1
15073   ac_status=$?
15074   grep -v '^ *+' conftest.er1 >conftest.err
15075   rm -f conftest.er1
15076   cat conftest.err >&5
15077   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15078   (exit $ac_status); } &&
15079          { ac_try='test -z "$ac_c_werror_flag"
15080                          || test ! -s conftest.err'
15081   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15082   (eval $ac_try) 2>&5
15083   ac_status=$?
15084   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15085   (exit $ac_status); }; } &&
15086          { ac_try='test -s conftest$ac_exeext'
15087   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15088   (eval $ac_try) 2>&5
15089   ac_status=$?
15090   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15091   (exit $ac_status); }; }; then
15092   ac_cv_lib_inet_socket=yes
15093 else
15094   echo "$as_me: failed program was:" >&5
15095 sed 's/^/| /' conftest.$ac_ext >&5
15096
15097 ac_cv_lib_inet_socket=no
15098 fi
15099 rm -f conftest.err conftest.$ac_objext \
15100       conftest$ac_exeext conftest.$ac_ext
15101 LIBS=$ac_check_lib_save_LIBS
15102 fi
15103 echo "$as_me:$LINENO: result: $ac_cv_lib_inet_socket" >&5
15104 echo "${ECHO_T}$ac_cv_lib_inet_socket" >&6
15105 if test $ac_cv_lib_inet_socket = yes; then
15106   cat >>confdefs.h <<_ACEOF
15107 #define HAVE_LIBINET 1
15108 _ACEOF
15109
15110   LIBS="-linet $LIBS"
15111
15112 fi
15113
15114
15115 echo "$as_me:$LINENO: checking for main in -lgen" >&5
15116 echo $ECHO_N "checking for main in -lgen... $ECHO_C" >&6
15117 if test "${ac_cv_lib_gen_main+set}" = set; then
15118   echo $ECHO_N "(cached) $ECHO_C" >&6
15119 else
15120   ac_check_lib_save_LIBS=$LIBS
15121 LIBS="-lgen  $LIBS"
15122 cat >conftest.$ac_ext <<_ACEOF
15123 /* confdefs.h.  */
15124 _ACEOF
15125 cat confdefs.h >>conftest.$ac_ext
15126 cat >>conftest.$ac_ext <<_ACEOF
15127 /* end confdefs.h.  */
15128
15129
15130 int
15131 main ()
15132 {
15133 main ();
15134   ;
15135   return 0;
15136 }
15137 _ACEOF
15138 rm -f conftest.$ac_objext conftest$ac_exeext
15139 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15140   (eval $ac_link) 2>conftest.er1
15141   ac_status=$?
15142   grep -v '^ *+' conftest.er1 >conftest.err
15143   rm -f conftest.er1
15144   cat conftest.err >&5
15145   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15146   (exit $ac_status); } &&
15147          { ac_try='test -z "$ac_c_werror_flag"
15148                          || test ! -s conftest.err'
15149   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15150   (eval $ac_try) 2>&5
15151   ac_status=$?
15152   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15153   (exit $ac_status); }; } &&
15154          { ac_try='test -s conftest$ac_exeext'
15155   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15156   (eval $ac_try) 2>&5
15157   ac_status=$?
15158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15159   (exit $ac_status); }; }; then
15160   ac_cv_lib_gen_main=yes
15161 else
15162   echo "$as_me: failed program was:" >&5
15163 sed 's/^/| /' conftest.$ac_ext >&5
15164
15165 ac_cv_lib_gen_main=no
15166 fi
15167 rm -f conftest.err conftest.$ac_objext \
15168       conftest$ac_exeext conftest.$ac_ext
15169 LIBS=$ac_check_lib_save_LIBS
15170 fi
15171 echo "$as_me:$LINENO: result: $ac_cv_lib_gen_main" >&5
15172 echo "${ECHO_T}$ac_cv_lib_gen_main" >&6
15173 if test $ac_cv_lib_gen_main = yes; then
15174   cat >>confdefs.h <<_ACEOF
15175 #define HAVE_LIBGEN 1
15176 _ACEOF
15177
15178   LIBS="-lgen $LIBS"
15179
15180 fi
15181
15182
15183 fi
15184
15185
15186 echo "$as_me:$LINENO: checking for select" >&5
15187 echo $ECHO_N "checking for select... $ECHO_C" >&6
15188 if test "${ac_cv_func_select+set}" = set; then
15189   echo $ECHO_N "(cached) $ECHO_C" >&6
15190 else
15191   cat >conftest.$ac_ext <<_ACEOF
15192 /* confdefs.h.  */
15193 _ACEOF
15194 cat confdefs.h >>conftest.$ac_ext
15195 cat >>conftest.$ac_ext <<_ACEOF
15196 /* end confdefs.h.  */
15197 /* Define select to an innocuous variant, in case <limits.h> declares select.
15198    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15199 #define select innocuous_select
15200
15201 /* System header to define __stub macros and hopefully few prototypes,
15202     which can conflict with char select (); below.
15203     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15204     <limits.h> exists even on freestanding compilers.  */
15205
15206 #ifdef __STDC__
15207 # include <limits.h>
15208 #else
15209 # include <assert.h>
15210 #endif
15211
15212 #undef select
15213
15214 /* Override any gcc2 internal prototype to avoid an error.  */
15215 #ifdef __cplusplus
15216 extern "C"
15217 {
15218 #endif
15219 /* We use char because int might match the return type of a gcc2
15220    builtin and then its argument prototype would still apply.  */
15221 char select ();
15222 /* The GNU C library defines this for functions which it implements
15223     to always fail with ENOSYS.  Some functions are actually named
15224     something starting with __ and the normal name is an alias.  */
15225 #if defined (__stub_select) || defined (__stub___select)
15226 choke me
15227 #else
15228 char (*f) () = select;
15229 #endif
15230 #ifdef __cplusplus
15231 }
15232 #endif
15233
15234 int
15235 main ()
15236 {
15237 return f != select;
15238   ;
15239   return 0;
15240 }
15241 _ACEOF
15242 rm -f conftest.$ac_objext conftest$ac_exeext
15243 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15244   (eval $ac_link) 2>conftest.er1
15245   ac_status=$?
15246   grep -v '^ *+' conftest.er1 >conftest.err
15247   rm -f conftest.er1
15248   cat conftest.err >&5
15249   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15250   (exit $ac_status); } &&
15251          { ac_try='test -z "$ac_c_werror_flag"
15252                          || test ! -s conftest.err'
15253   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15254   (eval $ac_try) 2>&5
15255   ac_status=$?
15256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15257   (exit $ac_status); }; } &&
15258          { ac_try='test -s conftest$ac_exeext'
15259   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15260   (eval $ac_try) 2>&5
15261   ac_status=$?
15262   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15263   (exit $ac_status); }; }; then
15264   ac_cv_func_select=yes
15265 else
15266   echo "$as_me: failed program was:" >&5
15267 sed 's/^/| /' conftest.$ac_ext >&5
15268
15269 ac_cv_func_select=no
15270 fi
15271 rm -f conftest.err conftest.$ac_objext \
15272       conftest$ac_exeext conftest.$ac_ext
15273 fi
15274 echo "$as_me:$LINENO: result: $ac_cv_func_select" >&5
15275 echo "${ECHO_T}$ac_cv_func_select" >&6
15276 if test $ac_cv_func_select = yes; then
15277   :
15278 else
15279   { { echo "$as_me:$LINENO: error: select() required." >&5
15280 echo "$as_me: error: select() required." >&2;}
15281    { (exit 1); exit 1; }; }
15282 fi
15283
15284
15285 if test "${ac_cv_header_winsock_h}" != yes; then
15286
15287
15288 for ac_header in sys/select.h sys/socket.h
15289 do
15290 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15291 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15292   echo "$as_me:$LINENO: checking for $ac_header" >&5
15293 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15294 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15295   echo $ECHO_N "(cached) $ECHO_C" >&6
15296 fi
15297 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15298 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15299 else
15300   # Is the header compilable?
15301 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15302 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15303 cat >conftest.$ac_ext <<_ACEOF
15304 /* confdefs.h.  */
15305 _ACEOF
15306 cat confdefs.h >>conftest.$ac_ext
15307 cat >>conftest.$ac_ext <<_ACEOF
15308 /* end confdefs.h.  */
15309 $ac_includes_default
15310 #include <$ac_header>
15311 _ACEOF
15312 rm -f conftest.$ac_objext
15313 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15314   (eval $ac_compile) 2>conftest.er1
15315   ac_status=$?
15316   grep -v '^ *+' conftest.er1 >conftest.err
15317   rm -f conftest.er1
15318   cat conftest.err >&5
15319   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15320   (exit $ac_status); } &&
15321          { ac_try='test -z "$ac_c_werror_flag"
15322                          || test ! -s conftest.err'
15323   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15324   (eval $ac_try) 2>&5
15325   ac_status=$?
15326   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15327   (exit $ac_status); }; } &&
15328          { ac_try='test -s conftest.$ac_objext'
15329   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15330   (eval $ac_try) 2>&5
15331   ac_status=$?
15332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15333   (exit $ac_status); }; }; then
15334   ac_header_compiler=yes
15335 else
15336   echo "$as_me: failed program was:" >&5
15337 sed 's/^/| /' conftest.$ac_ext >&5
15338
15339 ac_header_compiler=no
15340 fi
15341 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15342 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15343 echo "${ECHO_T}$ac_header_compiler" >&6
15344
15345 # Is the header present?
15346 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15347 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15348 cat >conftest.$ac_ext <<_ACEOF
15349 /* confdefs.h.  */
15350 _ACEOF
15351 cat confdefs.h >>conftest.$ac_ext
15352 cat >>conftest.$ac_ext <<_ACEOF
15353 /* end confdefs.h.  */
15354 #include <$ac_header>
15355 _ACEOF
15356 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15357   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15358   ac_status=$?
15359   grep -v '^ *+' conftest.er1 >conftest.err
15360   rm -f conftest.er1
15361   cat conftest.err >&5
15362   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15363   (exit $ac_status); } >/dev/null; then
15364   if test -s conftest.err; then
15365     ac_cpp_err=$ac_c_preproc_warn_flag
15366     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15367   else
15368     ac_cpp_err=
15369   fi
15370 else
15371   ac_cpp_err=yes
15372 fi
15373 if test -z "$ac_cpp_err"; then
15374   ac_header_preproc=yes
15375 else
15376   echo "$as_me: failed program was:" >&5
15377 sed 's/^/| /' conftest.$ac_ext >&5
15378
15379   ac_header_preproc=no
15380 fi
15381 rm -f conftest.err conftest.$ac_ext
15382 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15383 echo "${ECHO_T}$ac_header_preproc" >&6
15384
15385 # So?  What about this header?
15386 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15387   yes:no: )
15388     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15389 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15390     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15391 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15392     ac_header_preproc=yes
15393     ;;
15394   no:yes:* )
15395     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15396 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15397     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15398 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15399     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15400 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15401     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15402 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15403     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15404 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15405     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15406 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15407     (
15408       cat <<\_ASBOX
15409 ## --------------------------------------------- ##
15410 ## Report this to <http://www.openldap.org/its/> ##
15411 ## --------------------------------------------- ##
15412 _ASBOX
15413     ) |
15414       sed "s/^/$as_me: WARNING:     /" >&2
15415     ;;
15416 esac
15417 echo "$as_me:$LINENO: checking for $ac_header" >&5
15418 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15419 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15420   echo $ECHO_N "(cached) $ECHO_C" >&6
15421 else
15422   eval "$as_ac_Header=\$ac_header_preproc"
15423 fi
15424 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15425 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15426
15427 fi
15428 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15429   cat >>confdefs.h <<_ACEOF
15430 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15431 _ACEOF
15432
15433 fi
15434
15435 done
15436
15437 echo "$as_me:$LINENO: checking types of arguments for select" >&5
15438 echo $ECHO_N "checking types of arguments for select... $ECHO_C" >&6
15439 if test "${ac_cv_func_select_args+set}" = set; then
15440   echo $ECHO_N "(cached) $ECHO_C" >&6
15441 else
15442   for ac_arg234 in 'fd_set *' 'int *' 'void *'; do
15443  for ac_arg1 in 'int' 'size_t' 'unsigned long' 'unsigned'; do
15444   for ac_arg5 in 'struct timeval *' 'const struct timeval *'; do
15445    cat >conftest.$ac_ext <<_ACEOF
15446 /* confdefs.h.  */
15447 _ACEOF
15448 cat confdefs.h >>conftest.$ac_ext
15449 cat >>conftest.$ac_ext <<_ACEOF
15450 /* end confdefs.h.  */
15451 $ac_includes_default
15452 #if HAVE_SYS_SELECT_H
15453 # include <sys/select.h>
15454 #endif
15455 #if HAVE_SYS_SOCKET_H
15456 # include <sys/socket.h>
15457 #endif
15458
15459 int
15460 main ()
15461 {
15462 extern int select ($ac_arg1,
15463                                             $ac_arg234, $ac_arg234, $ac_arg234,
15464                                             $ac_arg5);
15465   ;
15466   return 0;
15467 }
15468 _ACEOF
15469 rm -f conftest.$ac_objext
15470 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15471   (eval $ac_compile) 2>conftest.er1
15472   ac_status=$?
15473   grep -v '^ *+' conftest.er1 >conftest.err
15474   rm -f conftest.er1
15475   cat conftest.err >&5
15476   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15477   (exit $ac_status); } &&
15478          { ac_try='test -z "$ac_c_werror_flag"
15479                          || test ! -s conftest.err'
15480   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15481   (eval $ac_try) 2>&5
15482   ac_status=$?
15483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15484   (exit $ac_status); }; } &&
15485          { ac_try='test -s conftest.$ac_objext'
15486   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15487   (eval $ac_try) 2>&5
15488   ac_status=$?
15489   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15490   (exit $ac_status); }; }; then
15491   ac_cv_func_select_args="$ac_arg1,$ac_arg234,$ac_arg5"; break 3
15492 else
15493   echo "$as_me: failed program was:" >&5
15494 sed 's/^/| /' conftest.$ac_ext >&5
15495
15496 fi
15497 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15498   done
15499  done
15500 done
15501 # Provide a safe default value.
15502 : ${ac_cv_func_select_args='int,int *,struct timeval *'}
15503
15504 fi
15505 echo "$as_me:$LINENO: result: $ac_cv_func_select_args" >&5
15506 echo "${ECHO_T}$ac_cv_func_select_args" >&6
15507 ac_save_IFS=$IFS; IFS=','
15508 set dummy `echo "$ac_cv_func_select_args" | sed 's/\*/\*/g'`
15509 IFS=$ac_save_IFS
15510 shift
15511
15512 cat >>confdefs.h <<_ACEOF
15513 #define SELECT_TYPE_ARG1 $1
15514 _ACEOF
15515
15516
15517 cat >>confdefs.h <<_ACEOF
15518 #define SELECT_TYPE_ARG234 ($2)
15519 _ACEOF
15520
15521
15522 cat >>confdefs.h <<_ACEOF
15523 #define SELECT_TYPE_ARG5 ($3)
15524 _ACEOF
15525
15526 rm -f conftest*
15527
15528 fi
15529
15530
15531
15532 for ac_func in poll
15533 do
15534 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15535 echo "$as_me:$LINENO: checking for $ac_func" >&5
15536 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15537 if eval "test \"\${$as_ac_var+set}\" = set"; then
15538   echo $ECHO_N "(cached) $ECHO_C" >&6
15539 else
15540   cat >conftest.$ac_ext <<_ACEOF
15541 /* confdefs.h.  */
15542 _ACEOF
15543 cat confdefs.h >>conftest.$ac_ext
15544 cat >>conftest.$ac_ext <<_ACEOF
15545 /* end confdefs.h.  */
15546 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15547    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15548 #define $ac_func innocuous_$ac_func
15549
15550 /* System header to define __stub macros and hopefully few prototypes,
15551     which can conflict with char $ac_func (); below.
15552     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15553     <limits.h> exists even on freestanding compilers.  */
15554
15555 #ifdef __STDC__
15556 # include <limits.h>
15557 #else
15558 # include <assert.h>
15559 #endif
15560
15561 #undef $ac_func
15562
15563 /* Override any gcc2 internal prototype to avoid an error.  */
15564 #ifdef __cplusplus
15565 extern "C"
15566 {
15567 #endif
15568 /* We use char because int might match the return type of a gcc2
15569    builtin and then its argument prototype would still apply.  */
15570 char $ac_func ();
15571 /* The GNU C library defines this for functions which it implements
15572     to always fail with ENOSYS.  Some functions are actually named
15573     something starting with __ and the normal name is an alias.  */
15574 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15575 choke me
15576 #else
15577 char (*f) () = $ac_func;
15578 #endif
15579 #ifdef __cplusplus
15580 }
15581 #endif
15582
15583 int
15584 main ()
15585 {
15586 return f != $ac_func;
15587   ;
15588   return 0;
15589 }
15590 _ACEOF
15591 rm -f conftest.$ac_objext conftest$ac_exeext
15592 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15593   (eval $ac_link) 2>conftest.er1
15594   ac_status=$?
15595   grep -v '^ *+' conftest.er1 >conftest.err
15596   rm -f conftest.er1
15597   cat conftest.err >&5
15598   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15599   (exit $ac_status); } &&
15600          { ac_try='test -z "$ac_c_werror_flag"
15601                          || test ! -s conftest.err'
15602   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15603   (eval $ac_try) 2>&5
15604   ac_status=$?
15605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15606   (exit $ac_status); }; } &&
15607          { ac_try='test -s conftest$ac_exeext'
15608   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15609   (eval $ac_try) 2>&5
15610   ac_status=$?
15611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15612   (exit $ac_status); }; }; then
15613   eval "$as_ac_var=yes"
15614 else
15615   echo "$as_me: failed program was:" >&5
15616 sed 's/^/| /' conftest.$ac_ext >&5
15617
15618 eval "$as_ac_var=no"
15619 fi
15620 rm -f conftest.err conftest.$ac_objext \
15621       conftest$ac_exeext conftest.$ac_ext
15622 fi
15623 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15624 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15625 if test `eval echo '${'$as_ac_var'}'` = yes; then
15626   cat >>confdefs.h <<_ACEOF
15627 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15628 _ACEOF
15629
15630 fi
15631 done
15632
15633 if test $ac_cv_func_poll = yes; then
15634
15635
15636 for ac_header in poll.h sys/poll.h
15637 do
15638 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15639 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15640   echo "$as_me:$LINENO: checking for $ac_header" >&5
15641 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15642 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15643   echo $ECHO_N "(cached) $ECHO_C" >&6
15644 fi
15645 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15646 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15647 else
15648   # Is the header compilable?
15649 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15650 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15651 cat >conftest.$ac_ext <<_ACEOF
15652 /* confdefs.h.  */
15653 _ACEOF
15654 cat confdefs.h >>conftest.$ac_ext
15655 cat >>conftest.$ac_ext <<_ACEOF
15656 /* end confdefs.h.  */
15657 $ac_includes_default
15658 #include <$ac_header>
15659 _ACEOF
15660 rm -f conftest.$ac_objext
15661 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15662   (eval $ac_compile) 2>conftest.er1
15663   ac_status=$?
15664   grep -v '^ *+' conftest.er1 >conftest.err
15665   rm -f conftest.er1
15666   cat conftest.err >&5
15667   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15668   (exit $ac_status); } &&
15669          { ac_try='test -z "$ac_c_werror_flag"
15670                          || test ! -s conftest.err'
15671   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15672   (eval $ac_try) 2>&5
15673   ac_status=$?
15674   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15675   (exit $ac_status); }; } &&
15676          { ac_try='test -s conftest.$ac_objext'
15677   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15678   (eval $ac_try) 2>&5
15679   ac_status=$?
15680   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15681   (exit $ac_status); }; }; then
15682   ac_header_compiler=yes
15683 else
15684   echo "$as_me: failed program was:" >&5
15685 sed 's/^/| /' conftest.$ac_ext >&5
15686
15687 ac_header_compiler=no
15688 fi
15689 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15690 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15691 echo "${ECHO_T}$ac_header_compiler" >&6
15692
15693 # Is the header present?
15694 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15695 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15696 cat >conftest.$ac_ext <<_ACEOF
15697 /* confdefs.h.  */
15698 _ACEOF
15699 cat confdefs.h >>conftest.$ac_ext
15700 cat >>conftest.$ac_ext <<_ACEOF
15701 /* end confdefs.h.  */
15702 #include <$ac_header>
15703 _ACEOF
15704 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15705   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15706   ac_status=$?
15707   grep -v '^ *+' conftest.er1 >conftest.err
15708   rm -f conftest.er1
15709   cat conftest.err >&5
15710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15711   (exit $ac_status); } >/dev/null; then
15712   if test -s conftest.err; then
15713     ac_cpp_err=$ac_c_preproc_warn_flag
15714     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15715   else
15716     ac_cpp_err=
15717   fi
15718 else
15719   ac_cpp_err=yes
15720 fi
15721 if test -z "$ac_cpp_err"; then
15722   ac_header_preproc=yes
15723 else
15724   echo "$as_me: failed program was:" >&5
15725 sed 's/^/| /' conftest.$ac_ext >&5
15726
15727   ac_header_preproc=no
15728 fi
15729 rm -f conftest.err conftest.$ac_ext
15730 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15731 echo "${ECHO_T}$ac_header_preproc" >&6
15732
15733 # So?  What about this header?
15734 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15735   yes:no: )
15736     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15737 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15738     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15739 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15740     ac_header_preproc=yes
15741     ;;
15742   no:yes:* )
15743     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15744 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15745     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15746 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15747     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15748 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15749     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15750 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15751     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15752 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15753     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15754 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15755     (
15756       cat <<\_ASBOX
15757 ## --------------------------------------------- ##
15758 ## Report this to <http://www.openldap.org/its/> ##
15759 ## --------------------------------------------- ##
15760 _ASBOX
15761     ) |
15762       sed "s/^/$as_me: WARNING:     /" >&2
15763     ;;
15764 esac
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 else
15770   eval "$as_ac_Header=\$ac_header_preproc"
15771 fi
15772 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15773 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15774
15775 fi
15776 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15777   cat >>confdefs.h <<_ACEOF
15778 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15779 _ACEOF
15780
15781 fi
15782
15783 done
15784
15785 fi
15786
15787
15788 for ac_header in sys/epoll.h
15789 do
15790 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15791 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15792   echo "$as_me:$LINENO: checking for $ac_header" >&5
15793 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15794 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15795   echo $ECHO_N "(cached) $ECHO_C" >&6
15796 fi
15797 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15798 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15799 else
15800   # Is the header compilable?
15801 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15802 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15803 cat >conftest.$ac_ext <<_ACEOF
15804 /* confdefs.h.  */
15805 _ACEOF
15806 cat confdefs.h >>conftest.$ac_ext
15807 cat >>conftest.$ac_ext <<_ACEOF
15808 /* end confdefs.h.  */
15809 $ac_includes_default
15810 #include <$ac_header>
15811 _ACEOF
15812 rm -f conftest.$ac_objext
15813 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15814   (eval $ac_compile) 2>conftest.er1
15815   ac_status=$?
15816   grep -v '^ *+' conftest.er1 >conftest.err
15817   rm -f conftest.er1
15818   cat conftest.err >&5
15819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15820   (exit $ac_status); } &&
15821          { ac_try='test -z "$ac_c_werror_flag"
15822                          || test ! -s conftest.err'
15823   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15824   (eval $ac_try) 2>&5
15825   ac_status=$?
15826   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15827   (exit $ac_status); }; } &&
15828          { ac_try='test -s conftest.$ac_objext'
15829   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15830   (eval $ac_try) 2>&5
15831   ac_status=$?
15832   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15833   (exit $ac_status); }; }; then
15834   ac_header_compiler=yes
15835 else
15836   echo "$as_me: failed program was:" >&5
15837 sed 's/^/| /' conftest.$ac_ext >&5
15838
15839 ac_header_compiler=no
15840 fi
15841 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15842 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15843 echo "${ECHO_T}$ac_header_compiler" >&6
15844
15845 # Is the header present?
15846 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15847 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15848 cat >conftest.$ac_ext <<_ACEOF
15849 /* confdefs.h.  */
15850 _ACEOF
15851 cat confdefs.h >>conftest.$ac_ext
15852 cat >>conftest.$ac_ext <<_ACEOF
15853 /* end confdefs.h.  */
15854 #include <$ac_header>
15855 _ACEOF
15856 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15857   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15858   ac_status=$?
15859   grep -v '^ *+' conftest.er1 >conftest.err
15860   rm -f conftest.er1
15861   cat conftest.err >&5
15862   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15863   (exit $ac_status); } >/dev/null; then
15864   if test -s conftest.err; then
15865     ac_cpp_err=$ac_c_preproc_warn_flag
15866     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15867   else
15868     ac_cpp_err=
15869   fi
15870 else
15871   ac_cpp_err=yes
15872 fi
15873 if test -z "$ac_cpp_err"; then
15874   ac_header_preproc=yes
15875 else
15876   echo "$as_me: failed program was:" >&5
15877 sed 's/^/| /' conftest.$ac_ext >&5
15878
15879   ac_header_preproc=no
15880 fi
15881 rm -f conftest.err conftest.$ac_ext
15882 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15883 echo "${ECHO_T}$ac_header_preproc" >&6
15884
15885 # So?  What about this header?
15886 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15887   yes:no: )
15888     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15889 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15890     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15891 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15892     ac_header_preproc=yes
15893     ;;
15894   no:yes:* )
15895     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15896 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15897     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15898 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15899     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15900 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15901     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15902 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15903     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15904 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15905     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15906 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15907     (
15908       cat <<\_ASBOX
15909 ## --------------------------------------------- ##
15910 ## Report this to <http://www.openldap.org/its/> ##
15911 ## --------------------------------------------- ##
15912 _ASBOX
15913     ) |
15914       sed "s/^/$as_me: WARNING:     /" >&2
15915     ;;
15916 esac
15917 echo "$as_me:$LINENO: checking for $ac_header" >&5
15918 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15919 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15920   echo $ECHO_N "(cached) $ECHO_C" >&6
15921 else
15922   eval "$as_ac_Header=\$ac_header_preproc"
15923 fi
15924 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15925 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15926
15927 fi
15928 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15929   cat >>confdefs.h <<_ACEOF
15930 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15931 _ACEOF
15932
15933 fi
15934
15935 done
15936
15937 if test "${ac_cv_header_sys_epoll_h}" = yes; then
15938         echo "$as_me:$LINENO: checking for epoll system call" >&5
15939 echo $ECHO_N "checking for epoll system call... $ECHO_C" >&6
15940         if test "$cross_compiling" = yes; then
15941   echo "$as_me:$LINENO: result: no" >&5
15942 echo "${ECHO_T}no" >&6
15943 else
15944   cat >conftest.$ac_ext <<_ACEOF
15945 /* confdefs.h.  */
15946 _ACEOF
15947 cat confdefs.h >>conftest.$ac_ext
15948 cat >>conftest.$ac_ext <<_ACEOF
15949 /* end confdefs.h.  */
15950 int main(int argc, char **argv)
15951 {
15952         int epfd = epoll_create(256);
15953         exit (epfd == -1 ? 1 : 0);
15954 }
15955 _ACEOF
15956 rm -f conftest$ac_exeext
15957 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15958   (eval $ac_link) 2>&5
15959   ac_status=$?
15960   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15961   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15962   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15963   (eval $ac_try) 2>&5
15964   ac_status=$?
15965   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15966   (exit $ac_status); }; }; then
15967   echo "$as_me:$LINENO: result: yes" >&5
15968 echo "${ECHO_T}yes" >&6
15969
15970 cat >>confdefs.h <<\_ACEOF
15971 #define HAVE_EPOLL 1
15972 _ACEOF
15973
15974 else
15975   echo "$as_me: program exited with status $ac_status" >&5
15976 echo "$as_me: failed program was:" >&5
15977 sed 's/^/| /' conftest.$ac_ext >&5
15978
15979 ( exit $ac_status )
15980 echo "$as_me:$LINENO: result: no" >&5
15981 echo "${ECHO_T}no" >&6
15982 fi
15983 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15984 fi
15985 fi
15986
15987
15988 for ac_header in sys/devpoll.h
15989 do
15990 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15991 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15992   echo "$as_me:$LINENO: checking for $ac_header" >&5
15993 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15994 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15995   echo $ECHO_N "(cached) $ECHO_C" >&6
15996 fi
15997 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15998 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15999 else
16000   # Is the header compilable?
16001 echo "$as_me:$LINENO: checking $ac_header usability" >&5
16002 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16003 cat >conftest.$ac_ext <<_ACEOF
16004 /* confdefs.h.  */
16005 _ACEOF
16006 cat confdefs.h >>conftest.$ac_ext
16007 cat >>conftest.$ac_ext <<_ACEOF
16008 /* end confdefs.h.  */
16009 $ac_includes_default
16010 #include <$ac_header>
16011 _ACEOF
16012 rm -f conftest.$ac_objext
16013 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16014   (eval $ac_compile) 2>conftest.er1
16015   ac_status=$?
16016   grep -v '^ *+' conftest.er1 >conftest.err
16017   rm -f conftest.er1
16018   cat conftest.err >&5
16019   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16020   (exit $ac_status); } &&
16021          { ac_try='test -z "$ac_c_werror_flag"
16022                          || test ! -s conftest.err'
16023   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16024   (eval $ac_try) 2>&5
16025   ac_status=$?
16026   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16027   (exit $ac_status); }; } &&
16028          { ac_try='test -s conftest.$ac_objext'
16029   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16030   (eval $ac_try) 2>&5
16031   ac_status=$?
16032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16033   (exit $ac_status); }; }; then
16034   ac_header_compiler=yes
16035 else
16036   echo "$as_me: failed program was:" >&5
16037 sed 's/^/| /' conftest.$ac_ext >&5
16038
16039 ac_header_compiler=no
16040 fi
16041 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16042 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16043 echo "${ECHO_T}$ac_header_compiler" >&6
16044
16045 # Is the header present?
16046 echo "$as_me:$LINENO: checking $ac_header presence" >&5
16047 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
16048 cat >conftest.$ac_ext <<_ACEOF
16049 /* confdefs.h.  */
16050 _ACEOF
16051 cat confdefs.h >>conftest.$ac_ext
16052 cat >>conftest.$ac_ext <<_ACEOF
16053 /* end confdefs.h.  */
16054 #include <$ac_header>
16055 _ACEOF
16056 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
16057   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16058   ac_status=$?
16059   grep -v '^ *+' conftest.er1 >conftest.err
16060   rm -f conftest.er1
16061   cat conftest.err >&5
16062   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16063   (exit $ac_status); } >/dev/null; then
16064   if test -s conftest.err; then
16065     ac_cpp_err=$ac_c_preproc_warn_flag
16066     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
16067   else
16068     ac_cpp_err=
16069   fi
16070 else
16071   ac_cpp_err=yes
16072 fi
16073 if test -z "$ac_cpp_err"; then
16074   ac_header_preproc=yes
16075 else
16076   echo "$as_me: failed program was:" >&5
16077 sed 's/^/| /' conftest.$ac_ext >&5
16078
16079   ac_header_preproc=no
16080 fi
16081 rm -f conftest.err conftest.$ac_ext
16082 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16083 echo "${ECHO_T}$ac_header_preproc" >&6
16084
16085 # So?  What about this header?
16086 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16087   yes:no: )
16088     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
16089 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
16090     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
16091 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
16092     ac_header_preproc=yes
16093     ;;
16094   no:yes:* )
16095     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
16096 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
16097     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
16098 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
16099     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
16100 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
16101     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
16102 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
16103     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
16104 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16105     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
16106 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
16107     (
16108       cat <<\_ASBOX
16109 ## --------------------------------------------- ##
16110 ## Report this to <http://www.openldap.org/its/> ##
16111 ## --------------------------------------------- ##
16112 _ASBOX
16113     ) |
16114       sed "s/^/$as_me: WARNING:     /" >&2
16115     ;;
16116 esac
16117 echo "$as_me:$LINENO: checking for $ac_header" >&5
16118 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16119 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16120   echo $ECHO_N "(cached) $ECHO_C" >&6
16121 else
16122   eval "$as_ac_Header=\$ac_header_preproc"
16123 fi
16124 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16125 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16126
16127 fi
16128 if test `eval echo '${'$as_ac_Header'}'` = yes; then
16129   cat >>confdefs.h <<_ACEOF
16130 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16131 _ACEOF
16132
16133 fi
16134
16135 done
16136
16137 if test "${ac_cv_header_sys_devpoll_h}" = yes \
16138                 -a "${ac_cv_header_poll_h}" = yes ; \
16139 then
16140         echo "$as_me:$LINENO: checking for /dev/poll" >&5
16141 echo $ECHO_N "checking for /dev/poll... $ECHO_C" >&6
16142         if test "$cross_compiling" = yes; then
16143   echo "$as_me:$LINENO: result: no" >&5
16144 echo "${ECHO_T}no" >&6
16145 else
16146   cat >conftest.$ac_ext <<_ACEOF
16147 /* confdefs.h.  */
16148 _ACEOF
16149 cat confdefs.h >>conftest.$ac_ext
16150 cat >>conftest.$ac_ext <<_ACEOF
16151 /* end confdefs.h.  */
16152 int main(int argc, char **argv)
16153 {
16154         int devpollfd = open("/dev/poll", /* O_RDWR */ 2);
16155         exit (devpollfd == -1 ? 1 : 0);
16156 }
16157 _ACEOF
16158 rm -f conftest$ac_exeext
16159 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16160   (eval $ac_link) 2>&5
16161   ac_status=$?
16162   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16163   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16164   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16165   (eval $ac_try) 2>&5
16166   ac_status=$?
16167   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16168   (exit $ac_status); }; }; then
16169   echo "$as_me:$LINENO: result: yes" >&5
16170 echo "${ECHO_T}yes" >&6
16171
16172 cat >>confdefs.h <<\_ACEOF
16173 #define HAVE_DEVPOLL 1
16174 _ACEOF
16175
16176 else
16177   echo "$as_me: program exited with status $ac_status" >&5
16178 echo "$as_me: failed program was:" >&5
16179 sed 's/^/| /' conftest.$ac_ext >&5
16180
16181 ( exit $ac_status )
16182 echo "$as_me:$LINENO: result: no" >&5
16183 echo "${ECHO_T}no" >&6
16184 fi
16185 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16186 fi
16187 fi
16188
16189 # strerror checks
16190 echo "$as_me:$LINENO: checking declaration of sys_errlist" >&5
16191 echo $ECHO_N "checking declaration of sys_errlist... $ECHO_C" >&6
16192 if test "${ol_cv_dcl_sys_errlist+set}" = set; then
16193   echo $ECHO_N "(cached) $ECHO_C" >&6
16194 else
16195
16196         cat >conftest.$ac_ext <<_ACEOF
16197 /* confdefs.h.  */
16198 _ACEOF
16199 cat confdefs.h >>conftest.$ac_ext
16200 cat >>conftest.$ac_ext <<_ACEOF
16201 /* end confdefs.h.  */
16202
16203 #include <stdio.h>
16204 #include <sys/types.h>
16205 #include <errno.h>
16206 #ifdef _WIN32
16207 #include <stdlib.h>
16208 #endif
16209 int
16210 main ()
16211 {
16212 char *c = (char *) *sys_errlist
16213   ;
16214   return 0;
16215 }
16216 _ACEOF
16217 rm -f conftest.$ac_objext
16218 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16219   (eval $ac_compile) 2>conftest.er1
16220   ac_status=$?
16221   grep -v '^ *+' conftest.er1 >conftest.err
16222   rm -f conftest.er1
16223   cat conftest.err >&5
16224   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16225   (exit $ac_status); } &&
16226          { ac_try='test -z "$ac_c_werror_flag"
16227                          || test ! -s conftest.err'
16228   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16229   (eval $ac_try) 2>&5
16230   ac_status=$?
16231   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16232   (exit $ac_status); }; } &&
16233          { ac_try='test -s conftest.$ac_objext'
16234   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16235   (eval $ac_try) 2>&5
16236   ac_status=$?
16237   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16238   (exit $ac_status); }; }; then
16239   ol_cv_dcl_sys_errlist=yes
16240         ol_cv_have_sys_errlist=yes
16241 else
16242   echo "$as_me: failed program was:" >&5
16243 sed 's/^/| /' conftest.$ac_ext >&5
16244
16245 ol_cv_dcl_sys_errlist=no
16246 fi
16247 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16248 fi
16249 echo "$as_me:$LINENO: result: $ol_cv_dcl_sys_errlist" >&5
16250 echo "${ECHO_T}$ol_cv_dcl_sys_errlist" >&6
16251 #
16252 # It's possible (for near-UNIX clones) that sys_errlist doesn't exist
16253 if test $ol_cv_dcl_sys_errlist = no ; then
16254
16255 cat >>confdefs.h <<\_ACEOF
16256 #define DECL_SYS_ERRLIST 1
16257 _ACEOF
16258
16259
16260         echo "$as_me:$LINENO: checking existence of sys_errlist" >&5
16261 echo $ECHO_N "checking existence of sys_errlist... $ECHO_C" >&6
16262 if test "${ol_cv_have_sys_errlist+set}" = set; then
16263   echo $ECHO_N "(cached) $ECHO_C" >&6
16264 else
16265
16266                 cat >conftest.$ac_ext <<_ACEOF
16267 /* confdefs.h.  */
16268 _ACEOF
16269 cat confdefs.h >>conftest.$ac_ext
16270 cat >>conftest.$ac_ext <<_ACEOF
16271 /* end confdefs.h.  */
16272 #include <errno.h>
16273 int
16274 main ()
16275 {
16276 char *c = (char *) *sys_errlist
16277   ;
16278   return 0;
16279 }
16280 _ACEOF
16281 rm -f conftest.$ac_objext conftest$ac_exeext
16282 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16283   (eval $ac_link) 2>conftest.er1
16284   ac_status=$?
16285   grep -v '^ *+' conftest.er1 >conftest.err
16286   rm -f conftest.er1
16287   cat conftest.err >&5
16288   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16289   (exit $ac_status); } &&
16290          { ac_try='test -z "$ac_c_werror_flag"
16291                          || test ! -s conftest.err'
16292   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16293   (eval $ac_try) 2>&5
16294   ac_status=$?
16295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16296   (exit $ac_status); }; } &&
16297          { ac_try='test -s conftest$ac_exeext'
16298   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16299   (eval $ac_try) 2>&5
16300   ac_status=$?
16301   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16302   (exit $ac_status); }; }; then
16303   ol_cv_have_sys_errlist=yes
16304 else
16305   echo "$as_me: failed program was:" >&5
16306 sed 's/^/| /' conftest.$ac_ext >&5
16307
16308 ol_cv_have_sys_errlist=no
16309 fi
16310 rm -f conftest.err conftest.$ac_objext \
16311       conftest$ac_exeext conftest.$ac_ext
16312 fi
16313 echo "$as_me:$LINENO: result: $ol_cv_have_sys_errlist" >&5
16314 echo "${ECHO_T}$ol_cv_have_sys_errlist" >&6
16315 fi
16316 if test $ol_cv_have_sys_errlist = yes ; then
16317
16318 cat >>confdefs.h <<\_ACEOF
16319 #define HAVE_SYS_ERRLIST 1
16320 _ACEOF
16321
16322 fi
16323
16324
16325 for ac_func in strerror strerror_r
16326 do
16327 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16328 echo "$as_me:$LINENO: checking for $ac_func" >&5
16329 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16330 if eval "test \"\${$as_ac_var+set}\" = set"; then
16331   echo $ECHO_N "(cached) $ECHO_C" >&6
16332 else
16333   cat >conftest.$ac_ext <<_ACEOF
16334 /* confdefs.h.  */
16335 _ACEOF
16336 cat confdefs.h >>conftest.$ac_ext
16337 cat >>conftest.$ac_ext <<_ACEOF
16338 /* end confdefs.h.  */
16339 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16340    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16341 #define $ac_func innocuous_$ac_func
16342
16343 /* System header to define __stub macros and hopefully few prototypes,
16344     which can conflict with char $ac_func (); below.
16345     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16346     <limits.h> exists even on freestanding compilers.  */
16347
16348 #ifdef __STDC__
16349 # include <limits.h>
16350 #else
16351 # include <assert.h>
16352 #endif
16353
16354 #undef $ac_func
16355
16356 /* Override any gcc2 internal prototype to avoid an error.  */
16357 #ifdef __cplusplus
16358 extern "C"
16359 {
16360 #endif
16361 /* We use char because int might match the return type of a gcc2
16362    builtin and then its argument prototype would still apply.  */
16363 char $ac_func ();
16364 /* The GNU C library defines this for functions which it implements
16365     to always fail with ENOSYS.  Some functions are actually named
16366     something starting with __ and the normal name is an alias.  */
16367 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16368 choke me
16369 #else
16370 char (*f) () = $ac_func;
16371 #endif
16372 #ifdef __cplusplus
16373 }
16374 #endif
16375
16376 int
16377 main ()
16378 {
16379 return f != $ac_func;
16380   ;
16381   return 0;
16382 }
16383 _ACEOF
16384 rm -f conftest.$ac_objext conftest$ac_exeext
16385 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16386   (eval $ac_link) 2>conftest.er1
16387   ac_status=$?
16388   grep -v '^ *+' conftest.er1 >conftest.err
16389   rm -f conftest.er1
16390   cat conftest.err >&5
16391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16392   (exit $ac_status); } &&
16393          { ac_try='test -z "$ac_c_werror_flag"
16394                          || test ! -s conftest.err'
16395   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16396   (eval $ac_try) 2>&5
16397   ac_status=$?
16398   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16399   (exit $ac_status); }; } &&
16400          { ac_try='test -s conftest$ac_exeext'
16401   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16402   (eval $ac_try) 2>&5
16403   ac_status=$?
16404   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16405   (exit $ac_status); }; }; then
16406   eval "$as_ac_var=yes"
16407 else
16408   echo "$as_me: failed program was:" >&5
16409 sed 's/^/| /' conftest.$ac_ext >&5
16410
16411 eval "$as_ac_var=no"
16412 fi
16413 rm -f conftest.err conftest.$ac_objext \
16414       conftest$ac_exeext conftest.$ac_ext
16415 fi
16416 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16417 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16418 if test `eval echo '${'$as_ac_var'}'` = yes; then
16419   cat >>confdefs.h <<_ACEOF
16420 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16421 _ACEOF
16422
16423 fi
16424 done
16425
16426 ol_cv_func_strerror_r=no
16427 if test "${ac_cv_func_strerror_r}" = yes ; then
16428         echo "$as_me:$LINENO: checking non-posix strerror_r" >&5
16429 echo $ECHO_N "checking non-posix strerror_r... $ECHO_C" >&6
16430 if test "${ol_cv_nonposix_strerror_r+set}" = set; then
16431   echo $ECHO_N "(cached) $ECHO_C" >&6
16432 else
16433
16434         cat >conftest.$ac_ext <<_ACEOF
16435 /* confdefs.h.  */
16436 _ACEOF
16437 cat confdefs.h >>conftest.$ac_ext
16438 cat >>conftest.$ac_ext <<_ACEOF
16439 /* end confdefs.h.  */
16440 #include <string.h>
16441 _ACEOF
16442 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16443   $EGREP "strerror_r" >/dev/null 2>&1; then
16444   ol_decl_strerror_r=yes
16445 else
16446   ol_decl_strerror_r=no
16447 fi
16448 rm -f conftest*
16449
16450         if test $ol_decl_strerror_r = yes ; then
16451                 cat >conftest.$ac_ext <<_ACEOF
16452 /* confdefs.h.  */
16453 _ACEOF
16454 cat confdefs.h >>conftest.$ac_ext
16455 cat >>conftest.$ac_ext <<_ACEOF
16456 /* end confdefs.h.  */
16457 #include <string.h>
16458 int
16459 main ()
16460 {
16461    /* from autoconf 2.59 */
16462                                 char buf[100];
16463                                 char x = *strerror_r (0, buf, sizeof buf);
16464                                 char *p = strerror_r (0, buf, sizeof buf);
16465
16466   ;
16467   return 0;
16468 }
16469 _ACEOF
16470 rm -f conftest.$ac_objext
16471 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16472   (eval $ac_compile) 2>conftest.er1
16473   ac_status=$?
16474   grep -v '^ *+' conftest.er1 >conftest.err
16475   rm -f conftest.er1
16476   cat conftest.err >&5
16477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16478   (exit $ac_status); } &&
16479          { ac_try='test -z "$ac_c_werror_flag"
16480                          || test ! -s conftest.err'
16481   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16482   (eval $ac_try) 2>&5
16483   ac_status=$?
16484   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16485   (exit $ac_status); }; } &&
16486          { ac_try='test -s conftest.$ac_objext'
16487   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16488   (eval $ac_try) 2>&5
16489   ac_status=$?
16490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16491   (exit $ac_status); }; }; then
16492   ol_cv_nonposix_strerror_r=yes
16493 else
16494   echo "$as_me: failed program was:" >&5
16495 sed 's/^/| /' conftest.$ac_ext >&5
16496
16497 ol_cv_nonposix_strerror_r=no
16498 fi
16499 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16500         else
16501                 if test "$cross_compiling" = yes; then
16502   ol_cv_nonposix_strerror=no
16503 else
16504   cat >conftest.$ac_ext <<_ACEOF
16505 /* confdefs.h.  */
16506 _ACEOF
16507 cat confdefs.h >>conftest.$ac_ext
16508 cat >>conftest.$ac_ext <<_ACEOF
16509 /* end confdefs.h.  */
16510
16511                         main() {
16512                                 char buf[100];
16513                                 buf[0] = 0;
16514                                 strerror_r( 1, buf, sizeof buf );
16515                                 exit( buf[0] == 0 );
16516                         }
16517
16518 _ACEOF
16519 rm -f conftest$ac_exeext
16520 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16521   (eval $ac_link) 2>&5
16522   ac_status=$?
16523   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16524   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16525   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16526   (eval $ac_try) 2>&5
16527   ac_status=$?
16528   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16529   (exit $ac_status); }; }; then
16530   ol_cv_nonposix_strerror_r=yes
16531 else
16532   echo "$as_me: program exited with status $ac_status" >&5
16533 echo "$as_me: failed program was:" >&5
16534 sed 's/^/| /' conftest.$ac_ext >&5
16535
16536 ( exit $ac_status )
16537 ol_cv_nonposix_strerror=no
16538 fi
16539 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16540 fi
16541         fi
16542
16543 fi
16544 echo "$as_me:$LINENO: result: $ol_cv_nonposix_strerror_r" >&5
16545 echo "${ECHO_T}$ol_cv_nonposix_strerror_r" >&6
16546 if test $ol_cv_nonposix_strerror_r = yes ; then
16547
16548 cat >>confdefs.h <<\_ACEOF
16549 #define HAVE_NONPOSIX_STRERROR_R 1
16550 _ACEOF
16551
16552 fi
16553
16554 elif test "${ac_cv_func_strerror}" = no ; then
16555         echo "$as_me:$LINENO: checking declaration of sys_errlist" >&5
16556 echo $ECHO_N "checking declaration of sys_errlist... $ECHO_C" >&6
16557 if test "${ol_cv_dcl_sys_errlist+set}" = set; then
16558   echo $ECHO_N "(cached) $ECHO_C" >&6
16559 else
16560
16561         cat >conftest.$ac_ext <<_ACEOF
16562 /* confdefs.h.  */
16563 _ACEOF
16564 cat confdefs.h >>conftest.$ac_ext
16565 cat >>conftest.$ac_ext <<_ACEOF
16566 /* end confdefs.h.  */
16567
16568 #include <stdio.h>
16569 #include <sys/types.h>
16570 #include <errno.h>
16571 #ifdef _WIN32
16572 #include <stdlib.h>
16573 #endif
16574 int
16575 main ()
16576 {
16577 char *c = (char *) *sys_errlist
16578   ;
16579   return 0;
16580 }
16581 _ACEOF
16582 rm -f conftest.$ac_objext
16583 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16584   (eval $ac_compile) 2>conftest.er1
16585   ac_status=$?
16586   grep -v '^ *+' conftest.er1 >conftest.err
16587   rm -f conftest.er1
16588   cat conftest.err >&5
16589   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16590   (exit $ac_status); } &&
16591          { ac_try='test -z "$ac_c_werror_flag"
16592                          || test ! -s conftest.err'
16593   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16594   (eval $ac_try) 2>&5
16595   ac_status=$?
16596   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16597   (exit $ac_status); }; } &&
16598          { ac_try='test -s conftest.$ac_objext'
16599   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16600   (eval $ac_try) 2>&5
16601   ac_status=$?
16602   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16603   (exit $ac_status); }; }; then
16604   ol_cv_dcl_sys_errlist=yes
16605         ol_cv_have_sys_errlist=yes
16606 else
16607   echo "$as_me: failed program was:" >&5
16608 sed 's/^/| /' conftest.$ac_ext >&5
16609
16610 ol_cv_dcl_sys_errlist=no
16611 fi
16612 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16613 fi
16614 echo "$as_me:$LINENO: result: $ol_cv_dcl_sys_errlist" >&5
16615 echo "${ECHO_T}$ol_cv_dcl_sys_errlist" >&6
16616 #
16617 # It's possible (for near-UNIX clones) that sys_errlist doesn't exist
16618 if test $ol_cv_dcl_sys_errlist = no ; then
16619
16620 cat >>confdefs.h <<\_ACEOF
16621 #define DECL_SYS_ERRLIST 1
16622 _ACEOF
16623
16624
16625         echo "$as_me:$LINENO: checking existence of sys_errlist" >&5
16626 echo $ECHO_N "checking existence of sys_errlist... $ECHO_C" >&6
16627 if test "${ol_cv_have_sys_errlist+set}" = set; then
16628   echo $ECHO_N "(cached) $ECHO_C" >&6
16629 else
16630
16631                 cat >conftest.$ac_ext <<_ACEOF
16632 /* confdefs.h.  */
16633 _ACEOF
16634 cat confdefs.h >>conftest.$ac_ext
16635 cat >>conftest.$ac_ext <<_ACEOF
16636 /* end confdefs.h.  */
16637 #include <errno.h>
16638 int
16639 main ()
16640 {
16641 char *c = (char *) *sys_errlist
16642   ;
16643   return 0;
16644 }
16645 _ACEOF
16646 rm -f conftest.$ac_objext conftest$ac_exeext
16647 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16648   (eval $ac_link) 2>conftest.er1
16649   ac_status=$?
16650   grep -v '^ *+' conftest.er1 >conftest.err
16651   rm -f conftest.er1
16652   cat conftest.err >&5
16653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16654   (exit $ac_status); } &&
16655          { ac_try='test -z "$ac_c_werror_flag"
16656                          || test ! -s conftest.err'
16657   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16658   (eval $ac_try) 2>&5
16659   ac_status=$?
16660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16661   (exit $ac_status); }; } &&
16662          { ac_try='test -s conftest$ac_exeext'
16663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16664   (eval $ac_try) 2>&5
16665   ac_status=$?
16666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16667   (exit $ac_status); }; }; then
16668   ol_cv_have_sys_errlist=yes
16669 else
16670   echo "$as_me: failed program was:" >&5
16671 sed 's/^/| /' conftest.$ac_ext >&5
16672
16673 ol_cv_have_sys_errlist=no
16674 fi
16675 rm -f conftest.err conftest.$ac_objext \
16676       conftest$ac_exeext conftest.$ac_ext
16677 fi
16678 echo "$as_me:$LINENO: result: $ol_cv_have_sys_errlist" >&5
16679 echo "${ECHO_T}$ol_cv_have_sys_errlist" >&6
16680 fi
16681 if test $ol_cv_have_sys_errlist = yes ; then
16682
16683 cat >>confdefs.h <<\_ACEOF
16684 #define HAVE_SYS_ERRLIST 1
16685 _ACEOF
16686
16687 fi
16688
16689 fi
16690
16691
16692
16693 for ac_header in regex.h
16694 do
16695 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16696 echo "$as_me:$LINENO: checking for $ac_header" >&5
16697 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16698 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16699   echo $ECHO_N "(cached) $ECHO_C" >&6
16700 else
16701   cat >conftest.$ac_ext <<_ACEOF
16702 /* confdefs.h.  */
16703 _ACEOF
16704 cat confdefs.h >>conftest.$ac_ext
16705 cat >>conftest.$ac_ext <<_ACEOF
16706 /* end confdefs.h.  */
16707 $ac_includes_default
16708 #ifdef HAVE_SYS_TYPES_H
16709 #include <sys/types.h>
16710 #endif
16711
16712
16713 #include <$ac_header>
16714 _ACEOF
16715 rm -f conftest.$ac_objext
16716 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16717   (eval $ac_compile) 2>conftest.er1
16718   ac_status=$?
16719   grep -v '^ *+' conftest.er1 >conftest.err
16720   rm -f conftest.er1
16721   cat conftest.err >&5
16722   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16723   (exit $ac_status); } &&
16724          { ac_try='test -z "$ac_c_werror_flag"
16725                          || test ! -s conftest.err'
16726   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16727   (eval $ac_try) 2>&5
16728   ac_status=$?
16729   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16730   (exit $ac_status); }; } &&
16731          { ac_try='test -s conftest.$ac_objext'
16732   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16733   (eval $ac_try) 2>&5
16734   ac_status=$?
16735   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16736   (exit $ac_status); }; }; then
16737   eval "$as_ac_Header=yes"
16738 else
16739   echo "$as_me: failed program was:" >&5
16740 sed 's/^/| /' conftest.$ac_ext >&5
16741
16742 eval "$as_ac_Header=no"
16743 fi
16744 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16745 fi
16746 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16747 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16748 if test `eval echo '${'$as_ac_Header'}'` = yes; then
16749   cat >>confdefs.h <<_ACEOF
16750 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16751 _ACEOF
16752
16753 fi
16754
16755 done
16756
16757
16758 if test "$ac_cv_header_regex_h" != yes ; then
16759         { { echo "$as_me:$LINENO: error: POSIX regex.h required." >&5
16760 echo "$as_me: error: POSIX regex.h required." >&2;}
16761    { (exit 1); exit 1; }; }
16762 fi
16763 echo "$as_me:$LINENO: checking for library containing regfree" >&5
16764 echo $ECHO_N "checking for library containing regfree... $ECHO_C" >&6
16765 if test "${ac_cv_search_regfree+set}" = set; then
16766   echo $ECHO_N "(cached) $ECHO_C" >&6
16767 else
16768   ac_func_search_save_LIBS=$LIBS
16769 ac_cv_search_regfree=no
16770 cat >conftest.$ac_ext <<_ACEOF
16771 /* confdefs.h.  */
16772 _ACEOF
16773 cat confdefs.h >>conftest.$ac_ext
16774 cat >>conftest.$ac_ext <<_ACEOF
16775 /* end confdefs.h.  */
16776
16777 /* Override any gcc2 internal prototype to avoid an error.  */
16778 #ifdef __cplusplus
16779 extern "C"
16780 #endif
16781 /* We use char because int might match the return type of a gcc2
16782    builtin and then its argument prototype would still apply.  */
16783 char regfree ();
16784 int
16785 main ()
16786 {
16787 regfree ();
16788   ;
16789   return 0;
16790 }
16791 _ACEOF
16792 rm -f conftest.$ac_objext conftest$ac_exeext
16793 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16794   (eval $ac_link) 2>conftest.er1
16795   ac_status=$?
16796   grep -v '^ *+' conftest.er1 >conftest.err
16797   rm -f conftest.er1
16798   cat conftest.err >&5
16799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16800   (exit $ac_status); } &&
16801          { ac_try='test -z "$ac_c_werror_flag"
16802                          || test ! -s conftest.err'
16803   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16804   (eval $ac_try) 2>&5
16805   ac_status=$?
16806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16807   (exit $ac_status); }; } &&
16808          { ac_try='test -s conftest$ac_exeext'
16809   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16810   (eval $ac_try) 2>&5
16811   ac_status=$?
16812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16813   (exit $ac_status); }; }; then
16814   ac_cv_search_regfree="none required"
16815 else
16816   echo "$as_me: failed program was:" >&5
16817 sed 's/^/| /' conftest.$ac_ext >&5
16818
16819 fi
16820 rm -f conftest.err conftest.$ac_objext \
16821       conftest$ac_exeext conftest.$ac_ext
16822 if test "$ac_cv_search_regfree" = no; then
16823   for ac_lib in regex gnuregex; do
16824     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
16825     cat >conftest.$ac_ext <<_ACEOF
16826 /* confdefs.h.  */
16827 _ACEOF
16828 cat confdefs.h >>conftest.$ac_ext
16829 cat >>conftest.$ac_ext <<_ACEOF
16830 /* end confdefs.h.  */
16831
16832 /* Override any gcc2 internal prototype to avoid an error.  */
16833 #ifdef __cplusplus
16834 extern "C"
16835 #endif
16836 /* We use char because int might match the return type of a gcc2
16837    builtin and then its argument prototype would still apply.  */
16838 char regfree ();
16839 int
16840 main ()
16841 {
16842 regfree ();
16843   ;
16844   return 0;
16845 }
16846 _ACEOF
16847 rm -f conftest.$ac_objext conftest$ac_exeext
16848 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16849   (eval $ac_link) 2>conftest.er1
16850   ac_status=$?
16851   grep -v '^ *+' conftest.er1 >conftest.err
16852   rm -f conftest.er1
16853   cat conftest.err >&5
16854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16855   (exit $ac_status); } &&
16856          { ac_try='test -z "$ac_c_werror_flag"
16857                          || test ! -s conftest.err'
16858   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16859   (eval $ac_try) 2>&5
16860   ac_status=$?
16861   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16862   (exit $ac_status); }; } &&
16863          { ac_try='test -s conftest$ac_exeext'
16864   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16865   (eval $ac_try) 2>&5
16866   ac_status=$?
16867   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16868   (exit $ac_status); }; }; then
16869   ac_cv_search_regfree="-l$ac_lib"
16870 break
16871 else
16872   echo "$as_me: failed program was:" >&5
16873 sed 's/^/| /' conftest.$ac_ext >&5
16874
16875 fi
16876 rm -f conftest.err conftest.$ac_objext \
16877       conftest$ac_exeext conftest.$ac_ext
16878   done
16879 fi
16880 LIBS=$ac_func_search_save_LIBS
16881 fi
16882 echo "$as_me:$LINENO: result: $ac_cv_search_regfree" >&5
16883 echo "${ECHO_T}$ac_cv_search_regfree" >&6
16884 if test "$ac_cv_search_regfree" != no; then
16885   test "$ac_cv_search_regfree" = "none required" || LIBS="$ac_cv_search_regfree $LIBS"
16886   :
16887 else
16888   { { echo "$as_me:$LINENO: error: POSIX regex required." >&5
16889 echo "$as_me: error: POSIX regex required." >&2;}
16890    { (exit 1); exit 1; }; }
16891 fi
16892
16893
16894
16895 echo "$as_me:$LINENO: checking for compatible POSIX regex" >&5
16896 echo $ECHO_N "checking for compatible POSIX regex... $ECHO_C" >&6
16897 if test "${ol_cv_c_posix_regex+set}" = set; then
16898   echo $ECHO_N "(cached) $ECHO_C" >&6
16899 else
16900
16901         if test "$cross_compiling" = yes; then
16902   ol_cv_c_posix_regex=cross
16903 else
16904   cat >conftest.$ac_ext <<_ACEOF
16905 /* confdefs.h.  */
16906 _ACEOF
16907 cat confdefs.h >>conftest.$ac_ext
16908 cat >>conftest.$ac_ext <<_ACEOF
16909 /* end confdefs.h.  */
16910
16911 #include <sys/types.h>
16912 #include <regex.h>
16913 static char *pattern, *string;
16914 main()
16915 {
16916         int rc;
16917         regex_t re;
16918
16919         pattern = "^A";
16920
16921         if(regcomp(&re, pattern, 0)) {
16922                 return -1;
16923         }
16924
16925         string = "ALL MATCH";
16926
16927         rc = regexec(&re, string, 0, (void*)0, 0);
16928
16929         regfree(&re);
16930
16931         return rc;
16932 }
16933 _ACEOF
16934 rm -f conftest$ac_exeext
16935 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16936   (eval $ac_link) 2>&5
16937   ac_status=$?
16938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16939   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16940   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16941   (eval $ac_try) 2>&5
16942   ac_status=$?
16943   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16944   (exit $ac_status); }; }; then
16945   ol_cv_c_posix_regex=yes
16946 else
16947   echo "$as_me: program exited with status $ac_status" >&5
16948 echo "$as_me: failed program was:" >&5
16949 sed 's/^/| /' conftest.$ac_ext >&5
16950
16951 ( exit $ac_status )
16952 ol_cv_c_posix_regex=no
16953 fi
16954 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16955 fi
16956 fi
16957 echo "$as_me:$LINENO: result: $ol_cv_c_posix_regex" >&5
16958 echo "${ECHO_T}$ol_cv_c_posix_regex" >&6
16959
16960 if test "$ol_cv_c_posix_regex" = no ; then
16961         { { echo "$as_me:$LINENO: error: broken POSIX regex!" >&5
16962 echo "$as_me: error: broken POSIX regex!" >&2;}
16963    { (exit 1); exit 1; }; }
16964 fi
16965
16966
16967 have_uuid=no
16968
16969 for ac_header in sys/uuid.h
16970 do
16971 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16972 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16973   echo "$as_me:$LINENO: checking for $ac_header" >&5
16974 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16975 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16976   echo $ECHO_N "(cached) $ECHO_C" >&6
16977 fi
16978 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16979 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16980 else
16981   # Is the header compilable?
16982 echo "$as_me:$LINENO: checking $ac_header usability" >&5
16983 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16984 cat >conftest.$ac_ext <<_ACEOF
16985 /* confdefs.h.  */
16986 _ACEOF
16987 cat confdefs.h >>conftest.$ac_ext
16988 cat >>conftest.$ac_ext <<_ACEOF
16989 /* end confdefs.h.  */
16990 $ac_includes_default
16991 #include <$ac_header>
16992 _ACEOF
16993 rm -f conftest.$ac_objext
16994 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16995   (eval $ac_compile) 2>conftest.er1
16996   ac_status=$?
16997   grep -v '^ *+' conftest.er1 >conftest.err
16998   rm -f conftest.er1
16999   cat conftest.err >&5
17000   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17001   (exit $ac_status); } &&
17002          { ac_try='test -z "$ac_c_werror_flag"
17003                          || test ! -s conftest.err'
17004   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17005   (eval $ac_try) 2>&5
17006   ac_status=$?
17007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17008   (exit $ac_status); }; } &&
17009          { ac_try='test -s conftest.$ac_objext'
17010   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17011   (eval $ac_try) 2>&5
17012   ac_status=$?
17013   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17014   (exit $ac_status); }; }; then
17015   ac_header_compiler=yes
17016 else
17017   echo "$as_me: failed program was:" >&5
17018 sed 's/^/| /' conftest.$ac_ext >&5
17019
17020 ac_header_compiler=no
17021 fi
17022 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17023 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17024 echo "${ECHO_T}$ac_header_compiler" >&6
17025
17026 # Is the header present?
17027 echo "$as_me:$LINENO: checking $ac_header presence" >&5
17028 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17029 cat >conftest.$ac_ext <<_ACEOF
17030 /* confdefs.h.  */
17031 _ACEOF
17032 cat confdefs.h >>conftest.$ac_ext
17033 cat >>conftest.$ac_ext <<_ACEOF
17034 /* end confdefs.h.  */
17035 #include <$ac_header>
17036 _ACEOF
17037 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
17038   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17039   ac_status=$?
17040   grep -v '^ *+' conftest.er1 >conftest.err
17041   rm -f conftest.er1
17042   cat conftest.err >&5
17043   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17044   (exit $ac_status); } >/dev/null; then
17045   if test -s conftest.err; then
17046     ac_cpp_err=$ac_c_preproc_warn_flag
17047     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
17048   else
17049     ac_cpp_err=
17050   fi
17051 else
17052   ac_cpp_err=yes
17053 fi
17054 if test -z "$ac_cpp_err"; then
17055   ac_header_preproc=yes
17056 else
17057   echo "$as_me: failed program was:" >&5
17058 sed 's/^/| /' conftest.$ac_ext >&5
17059
17060   ac_header_preproc=no
17061 fi
17062 rm -f conftest.err conftest.$ac_ext
17063 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17064 echo "${ECHO_T}$ac_header_preproc" >&6
17065
17066 # So?  What about this header?
17067 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17068   yes:no: )
17069     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17070 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17071     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
17072 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
17073     ac_header_preproc=yes
17074     ;;
17075   no:yes:* )
17076     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17077 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17078     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
17079 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
17080     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
17081 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
17082     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
17083 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
17084     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17085 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17086     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
17087 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
17088     (
17089       cat <<\_ASBOX
17090 ## --------------------------------------------- ##
17091 ## Report this to <http://www.openldap.org/its/> ##
17092 ## --------------------------------------------- ##
17093 _ASBOX
17094     ) |
17095       sed "s/^/$as_me: WARNING:     /" >&2
17096     ;;
17097 esac
17098 echo "$as_me:$LINENO: checking for $ac_header" >&5
17099 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17100 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17101   echo $ECHO_N "(cached) $ECHO_C" >&6
17102 else
17103   eval "$as_ac_Header=\$ac_header_preproc"
17104 fi
17105 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17106 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17107
17108 fi
17109 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17110   cat >>confdefs.h <<_ACEOF
17111 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17112 _ACEOF
17113
17114 fi
17115
17116 done
17117
17118 if test $ac_cv_header_sys_uuid_h = yes ; then
17119         save_LIBS="$LIBS"
17120         echo "$as_me:$LINENO: checking for library containing uuid_to_str" >&5
17121 echo $ECHO_N "checking for library containing uuid_to_str... $ECHO_C" >&6
17122 if test "${ac_cv_search_uuid_to_str+set}" = set; then
17123   echo $ECHO_N "(cached) $ECHO_C" >&6
17124 else
17125   ac_func_search_save_LIBS=$LIBS
17126 ac_cv_search_uuid_to_str=no
17127 cat >conftest.$ac_ext <<_ACEOF
17128 /* confdefs.h.  */
17129 _ACEOF
17130 cat confdefs.h >>conftest.$ac_ext
17131 cat >>conftest.$ac_ext <<_ACEOF
17132 /* end confdefs.h.  */
17133
17134 /* Override any gcc2 internal prototype to avoid an error.  */
17135 #ifdef __cplusplus
17136 extern "C"
17137 #endif
17138 /* We use char because int might match the return type of a gcc2
17139    builtin and then its argument prototype would still apply.  */
17140 char uuid_to_str ();
17141 int
17142 main ()
17143 {
17144 uuid_to_str ();
17145   ;
17146   return 0;
17147 }
17148 _ACEOF
17149 rm -f conftest.$ac_objext conftest$ac_exeext
17150 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17151   (eval $ac_link) 2>conftest.er1
17152   ac_status=$?
17153   grep -v '^ *+' conftest.er1 >conftest.err
17154   rm -f conftest.er1
17155   cat conftest.err >&5
17156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17157   (exit $ac_status); } &&
17158          { ac_try='test -z "$ac_c_werror_flag"
17159                          || test ! -s conftest.err'
17160   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17161   (eval $ac_try) 2>&5
17162   ac_status=$?
17163   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17164   (exit $ac_status); }; } &&
17165          { ac_try='test -s conftest$ac_exeext'
17166   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17167   (eval $ac_try) 2>&5
17168   ac_status=$?
17169   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17170   (exit $ac_status); }; }; then
17171   ac_cv_search_uuid_to_str="none required"
17172 else
17173   echo "$as_me: failed program was:" >&5
17174 sed 's/^/| /' conftest.$ac_ext >&5
17175
17176 fi
17177 rm -f conftest.err conftest.$ac_objext \
17178       conftest$ac_exeext conftest.$ac_ext
17179 if test "$ac_cv_search_uuid_to_str" = no; then
17180   for ac_lib in uuid; do
17181     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17182     cat >conftest.$ac_ext <<_ACEOF
17183 /* confdefs.h.  */
17184 _ACEOF
17185 cat confdefs.h >>conftest.$ac_ext
17186 cat >>conftest.$ac_ext <<_ACEOF
17187 /* end confdefs.h.  */
17188
17189 /* Override any gcc2 internal prototype to avoid an error.  */
17190 #ifdef __cplusplus
17191 extern "C"
17192 #endif
17193 /* We use char because int might match the return type of a gcc2
17194    builtin and then its argument prototype would still apply.  */
17195 char uuid_to_str ();
17196 int
17197 main ()
17198 {
17199 uuid_to_str ();
17200   ;
17201   return 0;
17202 }
17203 _ACEOF
17204 rm -f conftest.$ac_objext conftest$ac_exeext
17205 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17206   (eval $ac_link) 2>conftest.er1
17207   ac_status=$?
17208   grep -v '^ *+' conftest.er1 >conftest.err
17209   rm -f conftest.er1
17210   cat conftest.err >&5
17211   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17212   (exit $ac_status); } &&
17213          { ac_try='test -z "$ac_c_werror_flag"
17214                          || test ! -s conftest.err'
17215   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17216   (eval $ac_try) 2>&5
17217   ac_status=$?
17218   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17219   (exit $ac_status); }; } &&
17220          { ac_try='test -s conftest$ac_exeext'
17221   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17222   (eval $ac_try) 2>&5
17223   ac_status=$?
17224   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17225   (exit $ac_status); }; }; then
17226   ac_cv_search_uuid_to_str="-l$ac_lib"
17227 break
17228 else
17229   echo "$as_me: failed program was:" >&5
17230 sed 's/^/| /' conftest.$ac_ext >&5
17231
17232 fi
17233 rm -f conftest.err conftest.$ac_objext \
17234       conftest$ac_exeext conftest.$ac_ext
17235   done
17236 fi
17237 LIBS=$ac_func_search_save_LIBS
17238 fi
17239 echo "$as_me:$LINENO: result: $ac_cv_search_uuid_to_str" >&5
17240 echo "${ECHO_T}$ac_cv_search_uuid_to_str" >&6
17241 if test "$ac_cv_search_uuid_to_str" != no; then
17242   test "$ac_cv_search_uuid_to_str" = "none required" || LIBS="$ac_cv_search_uuid_to_str $LIBS"
17243   have_uuid=yes
17244 else
17245   :
17246 fi
17247
17248         LIBS="$save_LIBS"
17249
17250         if test have_uuid = yes ; then
17251
17252 cat >>confdefs.h <<\_ACEOF
17253 #define HAVE_UUID_TO_STR 1
17254 _ACEOF
17255
17256
17257                 test "$ac_cv_search_uuid_to_str" = "none required" || \
17258                         SLAPD_LIBS="$SLAPD_LIBS $ac_cv_search_uuid_to_str"
17259         fi
17260 fi
17261
17262 if test $have_uuid = no ; then
17263
17264 for ac_header in uuid/uuid.h
17265 do
17266 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17267 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17268   echo "$as_me:$LINENO: checking for $ac_header" >&5
17269 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17270 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17271   echo $ECHO_N "(cached) $ECHO_C" >&6
17272 fi
17273 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17274 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17275 else
17276   # Is the header compilable?
17277 echo "$as_me:$LINENO: checking $ac_header usability" >&5
17278 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17279 cat >conftest.$ac_ext <<_ACEOF
17280 /* confdefs.h.  */
17281 _ACEOF
17282 cat confdefs.h >>conftest.$ac_ext
17283 cat >>conftest.$ac_ext <<_ACEOF
17284 /* end confdefs.h.  */
17285 $ac_includes_default
17286 #include <$ac_header>
17287 _ACEOF
17288 rm -f conftest.$ac_objext
17289 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17290   (eval $ac_compile) 2>conftest.er1
17291   ac_status=$?
17292   grep -v '^ *+' conftest.er1 >conftest.err
17293   rm -f conftest.er1
17294   cat conftest.err >&5
17295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17296   (exit $ac_status); } &&
17297          { ac_try='test -z "$ac_c_werror_flag"
17298                          || test ! -s conftest.err'
17299   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17300   (eval $ac_try) 2>&5
17301   ac_status=$?
17302   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17303   (exit $ac_status); }; } &&
17304          { ac_try='test -s conftest.$ac_objext'
17305   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17306   (eval $ac_try) 2>&5
17307   ac_status=$?
17308   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17309   (exit $ac_status); }; }; then
17310   ac_header_compiler=yes
17311 else
17312   echo "$as_me: failed program was:" >&5
17313 sed 's/^/| /' conftest.$ac_ext >&5
17314
17315 ac_header_compiler=no
17316 fi
17317 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17318 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17319 echo "${ECHO_T}$ac_header_compiler" >&6
17320
17321 # Is the header present?
17322 echo "$as_me:$LINENO: checking $ac_header presence" >&5
17323 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17324 cat >conftest.$ac_ext <<_ACEOF
17325 /* confdefs.h.  */
17326 _ACEOF
17327 cat confdefs.h >>conftest.$ac_ext
17328 cat >>conftest.$ac_ext <<_ACEOF
17329 /* end confdefs.h.  */
17330 #include <$ac_header>
17331 _ACEOF
17332 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
17333   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17334   ac_status=$?
17335   grep -v '^ *+' conftest.er1 >conftest.err
17336   rm -f conftest.er1
17337   cat conftest.err >&5
17338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17339   (exit $ac_status); } >/dev/null; then
17340   if test -s conftest.err; then
17341     ac_cpp_err=$ac_c_preproc_warn_flag
17342     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
17343   else
17344     ac_cpp_err=
17345   fi
17346 else
17347   ac_cpp_err=yes
17348 fi
17349 if test -z "$ac_cpp_err"; then
17350   ac_header_preproc=yes
17351 else
17352   echo "$as_me: failed program was:" >&5
17353 sed 's/^/| /' conftest.$ac_ext >&5
17354
17355   ac_header_preproc=no
17356 fi
17357 rm -f conftest.err conftest.$ac_ext
17358 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17359 echo "${ECHO_T}$ac_header_preproc" >&6
17360
17361 # So?  What about this header?
17362 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17363   yes:no: )
17364     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17365 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17366     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
17367 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
17368     ac_header_preproc=yes
17369     ;;
17370   no:yes:* )
17371     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17372 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17373     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
17374 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
17375     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
17376 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
17377     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
17378 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
17379     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17380 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17381     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
17382 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
17383     (
17384       cat <<\_ASBOX
17385 ## --------------------------------------------- ##
17386 ## Report this to <http://www.openldap.org/its/> ##
17387 ## --------------------------------------------- ##
17388 _ASBOX
17389     ) |
17390       sed "s/^/$as_me: WARNING:     /" >&2
17391     ;;
17392 esac
17393 echo "$as_me:$LINENO: checking for $ac_header" >&5
17394 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17395 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17396   echo $ECHO_N "(cached) $ECHO_C" >&6
17397 else
17398   eval "$as_ac_Header=\$ac_header_preproc"
17399 fi
17400 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17401 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17402
17403 fi
17404 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17405   cat >>confdefs.h <<_ACEOF
17406 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17407 _ACEOF
17408
17409 fi
17410
17411 done
17412
17413         if test $ac_cv_header_uuid_uuid_h = yes ; then
17414                 save_LIBS="$LIBS"
17415                 echo "$as_me:$LINENO: checking for library containing uuid_generate" >&5
17416 echo $ECHO_N "checking for library containing uuid_generate... $ECHO_C" >&6
17417 if test "${ac_cv_search_uuid_generate+set}" = set; then
17418   echo $ECHO_N "(cached) $ECHO_C" >&6
17419 else
17420   ac_func_search_save_LIBS=$LIBS
17421 ac_cv_search_uuid_generate=no
17422 cat >conftest.$ac_ext <<_ACEOF
17423 /* confdefs.h.  */
17424 _ACEOF
17425 cat confdefs.h >>conftest.$ac_ext
17426 cat >>conftest.$ac_ext <<_ACEOF
17427 /* end confdefs.h.  */
17428
17429 /* Override any gcc2 internal prototype to avoid an error.  */
17430 #ifdef __cplusplus
17431 extern "C"
17432 #endif
17433 /* We use char because int might match the return type of a gcc2
17434    builtin and then its argument prototype would still apply.  */
17435 char uuid_generate ();
17436 int
17437 main ()
17438 {
17439 uuid_generate ();
17440   ;
17441   return 0;
17442 }
17443 _ACEOF
17444 rm -f conftest.$ac_objext conftest$ac_exeext
17445 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17446   (eval $ac_link) 2>conftest.er1
17447   ac_status=$?
17448   grep -v '^ *+' conftest.er1 >conftest.err
17449   rm -f conftest.er1
17450   cat conftest.err >&5
17451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17452   (exit $ac_status); } &&
17453          { ac_try='test -z "$ac_c_werror_flag"
17454                          || test ! -s conftest.err'
17455   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17456   (eval $ac_try) 2>&5
17457   ac_status=$?
17458   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17459   (exit $ac_status); }; } &&
17460          { ac_try='test -s conftest$ac_exeext'
17461   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17462   (eval $ac_try) 2>&5
17463   ac_status=$?
17464   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17465   (exit $ac_status); }; }; then
17466   ac_cv_search_uuid_generate="none required"
17467 else
17468   echo "$as_me: failed program was:" >&5
17469 sed 's/^/| /' conftest.$ac_ext >&5
17470
17471 fi
17472 rm -f conftest.err conftest.$ac_objext \
17473       conftest$ac_exeext conftest.$ac_ext
17474 if test "$ac_cv_search_uuid_generate" = no; then
17475   for ac_lib in uuid; do
17476     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17477     cat >conftest.$ac_ext <<_ACEOF
17478 /* confdefs.h.  */
17479 _ACEOF
17480 cat confdefs.h >>conftest.$ac_ext
17481 cat >>conftest.$ac_ext <<_ACEOF
17482 /* end confdefs.h.  */
17483
17484 /* Override any gcc2 internal prototype to avoid an error.  */
17485 #ifdef __cplusplus
17486 extern "C"
17487 #endif
17488 /* We use char because int might match the return type of a gcc2
17489    builtin and then its argument prototype would still apply.  */
17490 char uuid_generate ();
17491 int
17492 main ()
17493 {
17494 uuid_generate ();
17495   ;
17496   return 0;
17497 }
17498 _ACEOF
17499 rm -f conftest.$ac_objext conftest$ac_exeext
17500 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17501   (eval $ac_link) 2>conftest.er1
17502   ac_status=$?
17503   grep -v '^ *+' conftest.er1 >conftest.err
17504   rm -f conftest.er1
17505   cat conftest.err >&5
17506   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17507   (exit $ac_status); } &&
17508          { ac_try='test -z "$ac_c_werror_flag"
17509                          || test ! -s conftest.err'
17510   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17511   (eval $ac_try) 2>&5
17512   ac_status=$?
17513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17514   (exit $ac_status); }; } &&
17515          { ac_try='test -s conftest$ac_exeext'
17516   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17517   (eval $ac_try) 2>&5
17518   ac_status=$?
17519   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17520   (exit $ac_status); }; }; then
17521   ac_cv_search_uuid_generate="-l$ac_lib"
17522 break
17523 else
17524   echo "$as_me: failed program was:" >&5
17525 sed 's/^/| /' conftest.$ac_ext >&5
17526
17527 fi
17528 rm -f conftest.err conftest.$ac_objext \
17529       conftest$ac_exeext conftest.$ac_ext
17530   done
17531 fi
17532 LIBS=$ac_func_search_save_LIBS
17533 fi
17534 echo "$as_me:$LINENO: result: $ac_cv_search_uuid_generate" >&5
17535 echo "${ECHO_T}$ac_cv_search_uuid_generate" >&6
17536 if test "$ac_cv_search_uuid_generate" != no; then
17537   test "$ac_cv_search_uuid_generate" = "none required" || LIBS="$ac_cv_search_uuid_generate $LIBS"
17538   have_uuid=yes
17539 else
17540   :
17541 fi
17542
17543                 LIBS="$save_LIBS"
17544
17545                 if test have_uuid = yes ; then
17546
17547 cat >>confdefs.h <<\_ACEOF
17548 #define HAVE_UUID_GENERATE 1
17549 _ACEOF
17550
17551
17552                         test "$ac_cv_search_uuid_generate" = "none required" || \
17553                                 SLAPD_LIBS="$SLAPD_LIBS $ac_cv_search_uuid_generate"
17554                 fi
17555         fi
17556 fi
17557
17558 if test $have_uuid = no ; then
17559         echo "$as_me:$LINENO: checking to see if -lrpcrt4 is needed for win32 UUID support" >&5
17560 echo $ECHO_N "checking to see if -lrpcrt4 is needed for win32 UUID support... $ECHO_C" >&6
17561         save_LIBS="$LIBS"
17562         LIBS="$LIBS -lrpcrt4"
17563         cat >conftest.$ac_ext <<_ACEOF
17564 /* confdefs.h.  */
17565 _ACEOF
17566 cat confdefs.h >>conftest.$ac_ext
17567 cat >>conftest.$ac_ext <<_ACEOF
17568 /* end confdefs.h.  */
17569
17570                 int __stdcall UuidCreate(void *);
17571                 int __stdcall UuidToStringA(void *,void **);
17572
17573 int
17574 main ()
17575 {
17576
17577                 UuidCreate(0);
17578                 UuidToStringA(0,0);
17579
17580   ;
17581   return 0;
17582 }
17583 _ACEOF
17584 rm -f conftest.$ac_objext conftest$ac_exeext
17585 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17586   (eval $ac_link) 2>conftest.er1
17587   ac_status=$?
17588   grep -v '^ *+' conftest.er1 >conftest.err
17589   rm -f conftest.er1
17590   cat conftest.err >&5
17591   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17592   (exit $ac_status); } &&
17593          { ac_try='test -z "$ac_c_werror_flag"
17594                          || test ! -s conftest.err'
17595   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17596   (eval $ac_try) 2>&5
17597   ac_status=$?
17598   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17599   (exit $ac_status); }; } &&
17600          { ac_try='test -s conftest$ac_exeext'
17601   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17602   (eval $ac_try) 2>&5
17603   ac_status=$?
17604   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17605   (exit $ac_status); }; }; then
17606   need_rpcrt=yes
17607 else
17608   echo "$as_me: failed program was:" >&5
17609 sed 's/^/| /' conftest.$ac_ext >&5
17610
17611 need_rpcrt=no
17612 fi
17613 rm -f conftest.err conftest.$ac_objext \
17614       conftest$ac_exeext conftest.$ac_ext
17615         if test $need_rpcrt = yes; then
17616                 SLAPD_LIBS="$SLAPD_LIBS -lrpcrt4"
17617         fi
17618         LIBS="$save_LIBS"
17619         echo "$as_me:$LINENO: result: $need_rpcrt" >&5
17620 echo "${ECHO_T}$need_rpcrt" >&6
17621 fi
17622
17623 ol_cv_lib_resolver=no
17624 if test $ol_cv_lib_resolver = no ; then
17625         echo "$as_me:$LINENO: checking for resolver link (default)" >&5
17626 echo $ECHO_N "checking for resolver link (default)... $ECHO_C" >&6
17627 if test "${ol_cv_resolver_none+set}" = set; then
17628   echo $ECHO_N "(cached) $ECHO_C" >&6
17629 else
17630
17631         ol_RESOLVER_LIB=
17632         ol_LIBS=$LIBS
17633         LIBS="$ol_RESOLVER_LIB $LIBS"
17634
17635         cat >conftest.$ac_ext <<_ACEOF
17636 /* confdefs.h.  */
17637 _ACEOF
17638 cat confdefs.h >>conftest.$ac_ext
17639 cat >>conftest.$ac_ext <<_ACEOF
17640 /* end confdefs.h.  */
17641
17642 #ifdef HAVE_SYS_TYPES_H
17643 #       include <sys/types.h>
17644 #endif
17645 #include <netinet/in.h>
17646 #ifdef HAVE_ARPA_NAMESER_H
17647 #       include <arpa/nameser.h>
17648 #endif
17649 #ifdef HAVE_RESOLV_H
17650 #       include <resolv.h>
17651 #endif
17652
17653 int
17654 main ()
17655 {
17656 {
17657         int len, status;
17658         char *request = NULL;
17659         unsigned char reply[64*1024];
17660         unsigned char host[64*1024];
17661         unsigned char *p;
17662
17663 #ifdef NS_HFIXEDSZ
17664         /* Bind 8/9 interface */
17665         len = res_query(request, ns_c_in, ns_t_srv, reply, sizeof(reply));
17666 #else
17667         /* Bind 4 interface */
17668 # ifndef T_SRV
17669 #  define T_SRV 33
17670 # endif
17671         len = res_query(request, C_IN, T_SRV, reply, sizeof(reply));
17672 #endif
17673         p = reply;
17674 #ifdef NS_HFIXEDSZ
17675         /* Bind 8/9 interface */
17676         p += NS_HFIXEDSZ;
17677 #elif defined(HFIXEDSZ)
17678         /* Bind 4 interface w/ HFIXEDSZ */
17679         p += HFIXEDSZ;
17680 #else
17681         /* Bind 4 interface w/o HFIXEDSZ */
17682         p += sizeof(HEADER);
17683 #endif
17684         status = dn_expand( reply, reply+len, p, host, sizeof(host));
17685 }
17686   ;
17687   return 0;
17688 }
17689 _ACEOF
17690 rm -f conftest.$ac_objext conftest$ac_exeext
17691 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17692   (eval $ac_link) 2>conftest.er1
17693   ac_status=$?
17694   grep -v '^ *+' conftest.er1 >conftest.err
17695   rm -f conftest.er1
17696   cat conftest.err >&5
17697   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17698   (exit $ac_status); } &&
17699          { ac_try='test -z "$ac_c_werror_flag"
17700                          || test ! -s conftest.err'
17701   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17702   (eval $ac_try) 2>&5
17703   ac_status=$?
17704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17705   (exit $ac_status); }; } &&
17706          { ac_try='test -s conftest$ac_exeext'
17707   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17708   (eval $ac_try) 2>&5
17709   ac_status=$?
17710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17711   (exit $ac_status); }; }; then
17712   ol_cv_resolver_none=yes
17713 else
17714   echo "$as_me: failed program was:" >&5
17715 sed 's/^/| /' conftest.$ac_ext >&5
17716
17717 ol_cv_resolver_none=no
17718 fi
17719 rm -f conftest.err conftest.$ac_objext \
17720       conftest$ac_exeext conftest.$ac_ext
17721
17722         LIBS="$ol_LIBS"
17723
17724 fi
17725 echo "$as_me:$LINENO: result: $ol_cv_resolver_none" >&5
17726 echo "${ECHO_T}$ol_cv_resolver_none" >&6
17727
17728         if test $ol_cv_resolver_none = yes ; then
17729                 ol_cv_lib_resolver=yes
17730         fi
17731 fi
17732
17733 if test $ol_cv_lib_resolver = no ; then
17734         echo "$as_me:$LINENO: checking for resolver link (-lresolv)" >&5
17735 echo $ECHO_N "checking for resolver link (-lresolv)... $ECHO_C" >&6
17736 if test "${ol_cv_resolver_resolv+set}" = set; then
17737   echo $ECHO_N "(cached) $ECHO_C" >&6
17738 else
17739
17740         ol_RESOLVER_LIB=-lresolv
17741         ol_LIBS=$LIBS
17742         LIBS="$ol_RESOLVER_LIB $LIBS"
17743
17744         cat >conftest.$ac_ext <<_ACEOF
17745 /* confdefs.h.  */
17746 _ACEOF
17747 cat confdefs.h >>conftest.$ac_ext
17748 cat >>conftest.$ac_ext <<_ACEOF
17749 /* end confdefs.h.  */
17750
17751 #ifdef HAVE_SYS_TYPES_H
17752 #       include <sys/types.h>
17753 #endif
17754 #include <netinet/in.h>
17755 #ifdef HAVE_ARPA_NAMESER_H
17756 #       include <arpa/nameser.h>
17757 #endif
17758 #ifdef HAVE_RESOLV_H
17759 #       include <resolv.h>
17760 #endif
17761
17762 int
17763 main ()
17764 {
17765 {
17766         int len, status;
17767         char *request = NULL;
17768         unsigned char reply[64*1024];
17769         unsigned char host[64*1024];
17770         unsigned char *p;
17771
17772 #ifdef NS_HFIXEDSZ
17773         /* Bind 8/9 interface */
17774         len = res_query(request, ns_c_in, ns_t_srv, reply, sizeof(reply));
17775 #else
17776         /* Bind 4 interface */
17777 # ifndef T_SRV
17778 #  define T_SRV 33
17779 # endif
17780         len = res_query(request, C_IN, T_SRV, reply, sizeof(reply));
17781 #endif
17782         p = reply;
17783 #ifdef NS_HFIXEDSZ
17784         /* Bind 8/9 interface */
17785         p += NS_HFIXEDSZ;
17786 #elif defined(HFIXEDSZ)
17787         /* Bind 4 interface w/ HFIXEDSZ */
17788         p += HFIXEDSZ;
17789 #else
17790         /* Bind 4 interface w/o HFIXEDSZ */
17791         p += sizeof(HEADER);
17792 #endif
17793         status = dn_expand( reply, reply+len, p, host, sizeof(host));
17794 }
17795   ;
17796   return 0;
17797 }
17798 _ACEOF
17799 rm -f conftest.$ac_objext conftest$ac_exeext
17800 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17801   (eval $ac_link) 2>conftest.er1
17802   ac_status=$?
17803   grep -v '^ *+' conftest.er1 >conftest.err
17804   rm -f conftest.er1
17805   cat conftest.err >&5
17806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17807   (exit $ac_status); } &&
17808          { ac_try='test -z "$ac_c_werror_flag"
17809                          || test ! -s conftest.err'
17810   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17811   (eval $ac_try) 2>&5
17812   ac_status=$?
17813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17814   (exit $ac_status); }; } &&
17815          { ac_try='test -s conftest$ac_exeext'
17816   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17817   (eval $ac_try) 2>&5
17818   ac_status=$?
17819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17820   (exit $ac_status); }; }; then
17821   ol_cv_resolver_resolv=yes
17822 else
17823   echo "$as_me: failed program was:" >&5
17824 sed 's/^/| /' conftest.$ac_ext >&5
17825
17826 ol_cv_resolver_resolv=no
17827 fi
17828 rm -f conftest.err conftest.$ac_objext \
17829       conftest$ac_exeext conftest.$ac_ext
17830
17831         LIBS="$ol_LIBS"
17832
17833 fi
17834 echo "$as_me:$LINENO: result: $ol_cv_resolver_resolv" >&5
17835 echo "${ECHO_T}$ol_cv_resolver_resolv" >&6
17836
17837         if test $ol_cv_resolver_resolv = yes ; then
17838                 ol_cv_lib_resolver=-lresolv
17839         fi
17840 fi
17841
17842 if test $ol_cv_lib_resolver = no ; then
17843         echo "$as_me:$LINENO: checking for resolver link (-lbind)" >&5
17844 echo $ECHO_N "checking for resolver link (-lbind)... $ECHO_C" >&6
17845 if test "${ol_cv_resolver_bind+set}" = set; then
17846   echo $ECHO_N "(cached) $ECHO_C" >&6
17847 else
17848
17849         ol_RESOLVER_LIB=-lbind
17850         ol_LIBS=$LIBS
17851         LIBS="$ol_RESOLVER_LIB $LIBS"
17852
17853         cat >conftest.$ac_ext <<_ACEOF
17854 /* confdefs.h.  */
17855 _ACEOF
17856 cat confdefs.h >>conftest.$ac_ext
17857 cat >>conftest.$ac_ext <<_ACEOF
17858 /* end confdefs.h.  */
17859
17860 #ifdef HAVE_SYS_TYPES_H
17861 #       include <sys/types.h>
17862 #endif
17863 #include <netinet/in.h>
17864 #ifdef HAVE_ARPA_NAMESER_H
17865 #       include <arpa/nameser.h>
17866 #endif
17867 #ifdef HAVE_RESOLV_H
17868 #       include <resolv.h>
17869 #endif
17870
17871 int
17872 main ()
17873 {
17874 {
17875         int len, status;
17876         char *request = NULL;
17877         unsigned char reply[64*1024];
17878         unsigned char host[64*1024];
17879         unsigned char *p;
17880
17881 #ifdef NS_HFIXEDSZ
17882         /* Bind 8/9 interface */
17883         len = res_query(request, ns_c_in, ns_t_srv, reply, sizeof(reply));
17884 #else
17885         /* Bind 4 interface */
17886 # ifndef T_SRV
17887 #  define T_SRV 33
17888 # endif
17889         len = res_query(request, C_IN, T_SRV, reply, sizeof(reply));
17890 #endif
17891         p = reply;
17892 #ifdef NS_HFIXEDSZ
17893         /* Bind 8/9 interface */
17894         p += NS_HFIXEDSZ;
17895 #elif defined(HFIXEDSZ)
17896         /* Bind 4 interface w/ HFIXEDSZ */
17897         p += HFIXEDSZ;
17898 #else
17899         /* Bind 4 interface w/o HFIXEDSZ */
17900         p += sizeof(HEADER);
17901 #endif
17902         status = dn_expand( reply, reply+len, p, host, sizeof(host));
17903 }
17904   ;
17905   return 0;
17906 }
17907 _ACEOF
17908 rm -f conftest.$ac_objext conftest$ac_exeext
17909 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17910   (eval $ac_link) 2>conftest.er1
17911   ac_status=$?
17912   grep -v '^ *+' conftest.er1 >conftest.err
17913   rm -f conftest.er1
17914   cat conftest.err >&5
17915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17916   (exit $ac_status); } &&
17917          { ac_try='test -z "$ac_c_werror_flag"
17918                          || test ! -s conftest.err'
17919   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17920   (eval $ac_try) 2>&5
17921   ac_status=$?
17922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17923   (exit $ac_status); }; } &&
17924          { ac_try='test -s conftest$ac_exeext'
17925   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17926   (eval $ac_try) 2>&5
17927   ac_status=$?
17928   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17929   (exit $ac_status); }; }; then
17930   ol_cv_resolver_bind=yes
17931 else
17932   echo "$as_me: failed program was:" >&5
17933 sed 's/^/| /' conftest.$ac_ext >&5
17934
17935 ol_cv_resolver_bind=no
17936 fi
17937 rm -f conftest.err conftest.$ac_objext \
17938       conftest$ac_exeext conftest.$ac_ext
17939
17940         LIBS="$ol_LIBS"
17941
17942 fi
17943 echo "$as_me:$LINENO: result: $ol_cv_resolver_bind" >&5
17944 echo "${ECHO_T}$ol_cv_resolver_bind" >&6
17945
17946         if test $ol_cv_resolver_bind = yes ; then
17947                 ol_cv_lib_resolver=-lbind
17948         fi
17949 fi
17950
17951
17952
17953 ol_link_dnssrv=no
17954 if test "$ol_cv_lib_resolver" != no ; then
17955
17956 cat >>confdefs.h <<\_ACEOF
17957 #define HAVE_RES_QUERY 1
17958 _ACEOF
17959
17960
17961         if test "$ol_enable_dnssrv" != no ; then
17962                 ol_link_dnssrv=yes
17963         fi
17964
17965         if test "$ol_cv_lib_resolver" != yes ; then
17966                 LIBS="$ol_cv_lib_resolver $LIBS"
17967         fi
17968 fi
17969
17970 if test "$ol_enable_dnssrv" = yes || test "$ol_enable_dnssrv" = mod ; then
17971         if test "$ol_link_dnssrv" = no ; then
17972                 { { echo "$as_me:$LINENO: error: DNSSRV requires res_query()" >&5
17973 echo "$as_me: error: DNSSRV requires res_query()" >&2;}
17974    { (exit 1); exit 1; }; }
17975         fi
17976 else
17977         ol_enable_dnssrv=no
17978 fi
17979
17980
17981 for ac_func in hstrerror
17982 do
17983 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17984 echo "$as_me:$LINENO: checking for $ac_func" >&5
17985 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17986 if eval "test \"\${$as_ac_var+set}\" = set"; then
17987   echo $ECHO_N "(cached) $ECHO_C" >&6
17988 else
17989   cat >conftest.$ac_ext <<_ACEOF
17990 /* confdefs.h.  */
17991 _ACEOF
17992 cat confdefs.h >>conftest.$ac_ext
17993 cat >>conftest.$ac_ext <<_ACEOF
17994 /* end confdefs.h.  */
17995 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17996    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17997 #define $ac_func innocuous_$ac_func
17998
17999 /* System header to define __stub macros and hopefully few prototypes,
18000     which can conflict with char $ac_func (); below.
18001     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18002     <limits.h> exists even on freestanding compilers.  */
18003
18004 #ifdef __STDC__
18005 # include <limits.h>
18006 #else
18007 # include <assert.h>
18008 #endif
18009
18010 #undef $ac_func
18011
18012 /* Override any gcc2 internal prototype to avoid an error.  */
18013 #ifdef __cplusplus
18014 extern "C"
18015 {
18016 #endif
18017 /* We use char because int might match the return type of a gcc2
18018    builtin and then its argument prototype would still apply.  */
18019 char $ac_func ();
18020 /* The GNU C library defines this for functions which it implements
18021     to always fail with ENOSYS.  Some functions are actually named
18022     something starting with __ and the normal name is an alias.  */
18023 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
18024 choke me
18025 #else
18026 char (*f) () = $ac_func;
18027 #endif
18028 #ifdef __cplusplus
18029 }
18030 #endif
18031
18032 int
18033 main ()
18034 {
18035 return f != $ac_func;
18036   ;
18037   return 0;
18038 }
18039 _ACEOF
18040 rm -f conftest.$ac_objext conftest$ac_exeext
18041 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18042   (eval $ac_link) 2>conftest.er1
18043   ac_status=$?
18044   grep -v '^ *+' conftest.er1 >conftest.err
18045   rm -f conftest.er1
18046   cat conftest.err >&5
18047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18048   (exit $ac_status); } &&
18049          { ac_try='test -z "$ac_c_werror_flag"
18050                          || test ! -s conftest.err'
18051   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18052   (eval $ac_try) 2>&5
18053   ac_status=$?
18054   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18055   (exit $ac_status); }; } &&
18056          { ac_try='test -s conftest$ac_exeext'
18057   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18058   (eval $ac_try) 2>&5
18059   ac_status=$?
18060   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18061   (exit $ac_status); }; }; then
18062   eval "$as_ac_var=yes"
18063 else
18064   echo "$as_me: failed program was:" >&5
18065 sed 's/^/| /' conftest.$ac_ext >&5
18066
18067 eval "$as_ac_var=no"
18068 fi
18069 rm -f conftest.err conftest.$ac_objext \
18070       conftest$ac_exeext conftest.$ac_ext
18071 fi
18072 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
18073 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
18074 if test `eval echo '${'$as_ac_var'}'` = yes; then
18075   cat >>confdefs.h <<_ACEOF
18076 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18077 _ACEOF
18078
18079 fi
18080 done
18081
18082
18083
18084
18085
18086
18087 for ac_func in getaddrinfo getnameinfo gai_strerror inet_ntop
18088 do
18089 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18090 echo "$as_me:$LINENO: checking for $ac_func" >&5
18091 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
18092 if eval "test \"\${$as_ac_var+set}\" = set"; then
18093   echo $ECHO_N "(cached) $ECHO_C" >&6
18094 else
18095   cat >conftest.$ac_ext <<_ACEOF
18096 /* confdefs.h.  */
18097 _ACEOF
18098 cat confdefs.h >>conftest.$ac_ext
18099 cat >>conftest.$ac_ext <<_ACEOF
18100 /* end confdefs.h.  */
18101 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18102    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18103 #define $ac_func innocuous_$ac_func
18104
18105 /* System header to define __stub macros and hopefully few prototypes,
18106     which can conflict with char $ac_func (); below.
18107     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18108     <limits.h> exists even on freestanding compilers.  */
18109
18110 #ifdef __STDC__
18111 # include <limits.h>
18112 #else
18113 # include <assert.h>
18114 #endif
18115
18116 #undef $ac_func
18117
18118 /* Override any gcc2 internal prototype to avoid an error.  */
18119 #ifdef __cplusplus
18120 extern "C"
18121 {
18122 #endif
18123 /* We use char because int might match the return type of a gcc2
18124    builtin and then its argument prototype would still apply.  */
18125 char $ac_func ();
18126 /* The GNU C library defines this for functions which it implements
18127     to always fail with ENOSYS.  Some functions are actually named
18128     something starting with __ and the normal name is an alias.  */
18129 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
18130 choke me
18131 #else
18132 char (*f) () = $ac_func;
18133 #endif
18134 #ifdef __cplusplus
18135 }
18136 #endif
18137
18138 int
18139 main ()
18140 {
18141 return f != $ac_func;
18142   ;
18143   return 0;
18144 }
18145 _ACEOF
18146 rm -f conftest.$ac_objext conftest$ac_exeext
18147 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18148   (eval $ac_link) 2>conftest.er1
18149   ac_status=$?
18150   grep -v '^ *+' conftest.er1 >conftest.err
18151   rm -f conftest.er1
18152   cat conftest.err >&5
18153   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18154   (exit $ac_status); } &&
18155          { ac_try='test -z "$ac_c_werror_flag"
18156                          || test ! -s conftest.err'
18157   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18158   (eval $ac_try) 2>&5
18159   ac_status=$?
18160   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18161   (exit $ac_status); }; } &&
18162          { ac_try='test -s conftest$ac_exeext'
18163   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18164   (eval $ac_try) 2>&5
18165   ac_status=$?
18166   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18167   (exit $ac_status); }; }; then
18168   eval "$as_ac_var=yes"
18169 else
18170   echo "$as_me: failed program was:" >&5
18171 sed 's/^/| /' conftest.$ac_ext >&5
18172
18173 eval "$as_ac_var=no"
18174 fi
18175 rm -f conftest.err conftest.$ac_objext \
18176       conftest$ac_exeext conftest.$ac_ext
18177 fi
18178 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
18179 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
18180 if test `eval echo '${'$as_ac_var'}'` = yes; then
18181   cat >>confdefs.h <<_ACEOF
18182 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18183 _ACEOF
18184
18185 fi
18186 done
18187
18188
18189 ol_link_ipv6=no
18190 if test $ac_cv_func_getaddrinfo = no || test $ac_cv_func_inet_ntop = no ; then
18191         if test $ol_enable_ipv6 = yes ; then
18192                 { { echo "$as_me:$LINENO: error: IPv6 support requires getaddrinfo() and inet_ntop()" >&5
18193 echo "$as_me: error: IPv6 support requires getaddrinfo() and inet_ntop()" >&2;}
18194    { (exit 1); exit 1; }; }
18195         fi
18196 elif test $ol_enable_ipv6 != no ; then
18197         echo "$as_me:$LINENO: checking INET6_ADDRSTRLEN" >&5
18198 echo $ECHO_N "checking INET6_ADDRSTRLEN... $ECHO_C" >&6
18199 if test "${ol_cv_inet6_addrstrlen+set}" = set; then
18200   echo $ECHO_N "(cached) $ECHO_C" >&6
18201 else
18202
18203                 cat >conftest.$ac_ext <<_ACEOF
18204 /* confdefs.h.  */
18205 _ACEOF
18206 cat confdefs.h >>conftest.$ac_ext
18207 cat >>conftest.$ac_ext <<_ACEOF
18208 /* end confdefs.h.  */
18209
18210 #                       include <netinet/in.h>
18211 #                       ifdef INET6_ADDRSTRLEN
18212                                 __has_inet6_addrstrlen__;
18213 #                       endif
18214
18215 _ACEOF
18216 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18217   $EGREP "__has_inet6_addrstrlen__" >/dev/null 2>&1; then
18218   ol_cv_inet6_addrstrlen=yes
18219 else
18220   ol_cv_inet6_addrstrlen=no
18221 fi
18222 rm -f conftest*
18223
18224 fi
18225 echo "$as_me:$LINENO: result: $ol_cv_inet6_addrstrlen" >&5
18226 echo "${ECHO_T}$ol_cv_inet6_addrstrlen" >&6
18227
18228
18229         echo "$as_me:$LINENO: checking struct sockaddr_storage" >&5
18230 echo $ECHO_N "checking struct sockaddr_storage... $ECHO_C" >&6
18231 if test "${ol_cv_struct_sockaddr_storage+set}" = set; then
18232   echo $ECHO_N "(cached) $ECHO_C" >&6
18233 else
18234
18235                 cat >conftest.$ac_ext <<_ACEOF
18236 /* confdefs.h.  */
18237 _ACEOF
18238 cat confdefs.h >>conftest.$ac_ext
18239 cat >>conftest.$ac_ext <<_ACEOF
18240 /* end confdefs.h.  */
18241
18242 #include <sys/types.h>
18243 #include <sys/socket.h>
18244
18245 int
18246 main ()
18247 {
18248
18249                         struct sockaddr_storage ss;
18250
18251   ;
18252   return 0;
18253 }
18254 _ACEOF
18255 rm -f conftest.$ac_objext
18256 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18257   (eval $ac_compile) 2>conftest.er1
18258   ac_status=$?
18259   grep -v '^ *+' conftest.er1 >conftest.err
18260   rm -f conftest.er1
18261   cat conftest.err >&5
18262   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18263   (exit $ac_status); } &&
18264          { ac_try='test -z "$ac_c_werror_flag"
18265                          || test ! -s conftest.err'
18266   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18267   (eval $ac_try) 2>&5
18268   ac_status=$?
18269   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18270   (exit $ac_status); }; } &&
18271          { ac_try='test -s conftest.$ac_objext'
18272   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18273   (eval $ac_try) 2>&5
18274   ac_status=$?
18275   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18276   (exit $ac_status); }; }; then
18277   ol_cv_struct_sockaddr_storage=yes
18278 else
18279   echo "$as_me: failed program was:" >&5
18280 sed 's/^/| /' conftest.$ac_ext >&5
18281
18282 ol_cv_struct_sockaddr_storage=no
18283 fi
18284 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18285 fi
18286 echo "$as_me:$LINENO: result: $ol_cv_struct_sockaddr_storage" >&5
18287 echo "${ECHO_T}$ol_cv_struct_sockaddr_storage" >&6
18288
18289         if test $ol_cv_inet6_addrstrlen = yes &&
18290            test $ol_cv_struct_sockaddr_storage = yes ; then
18291                 ol_link_ipv6=yes
18292         elif test $ol_enable_ipv6 = yes &&
18293              test $ol_cv_inet6_addrstrlen = no ; then
18294                 { { echo "$as_me:$LINENO: error: IPv6 support requires INET6_ADDRSTRLEN" >&5
18295 echo "$as_me: error: IPv6 support requires INET6_ADDRSTRLEN" >&2;}
18296    { (exit 1); exit 1; }; }
18297         elif test $ol_enable_ipv6 = yes &&
18298              test $ol_cv_struct_sockaddr_storage = no ; then
18299                 { { echo "$as_me:$LINENO: error: IPv6 support requires struct sockaddr_storage" >&5
18300 echo "$as_me: error: IPv6 support requires struct sockaddr_storage" >&2;}
18301    { (exit 1); exit 1; }; }
18302         fi
18303 fi
18304
18305 if test $ol_enable_local != no ; then
18306
18307 for ac_header in sys/un.h
18308 do
18309 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18310 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18311   echo "$as_me:$LINENO: checking for $ac_header" >&5
18312 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18313 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18314   echo $ECHO_N "(cached) $ECHO_C" >&6
18315 fi
18316 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18317 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18318 else
18319   # Is the header compilable?
18320 echo "$as_me:$LINENO: checking $ac_header usability" >&5
18321 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18322 cat >conftest.$ac_ext <<_ACEOF
18323 /* confdefs.h.  */
18324 _ACEOF
18325 cat confdefs.h >>conftest.$ac_ext
18326 cat >>conftest.$ac_ext <<_ACEOF
18327 /* end confdefs.h.  */
18328 $ac_includes_default
18329 #include <$ac_header>
18330 _ACEOF
18331 rm -f conftest.$ac_objext
18332 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18333   (eval $ac_compile) 2>conftest.er1
18334   ac_status=$?
18335   grep -v '^ *+' conftest.er1 >conftest.err
18336   rm -f conftest.er1
18337   cat conftest.err >&5
18338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18339   (exit $ac_status); } &&
18340          { ac_try='test -z "$ac_c_werror_flag"
18341                          || test ! -s conftest.err'
18342   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18343   (eval $ac_try) 2>&5
18344   ac_status=$?
18345   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18346   (exit $ac_status); }; } &&
18347          { ac_try='test -s conftest.$ac_objext'
18348   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18349   (eval $ac_try) 2>&5
18350   ac_status=$?
18351   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18352   (exit $ac_status); }; }; then
18353   ac_header_compiler=yes
18354 else
18355   echo "$as_me: failed program was:" >&5
18356 sed 's/^/| /' conftest.$ac_ext >&5
18357
18358 ac_header_compiler=no
18359 fi
18360 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18361 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18362 echo "${ECHO_T}$ac_header_compiler" >&6
18363
18364 # Is the header present?
18365 echo "$as_me:$LINENO: checking $ac_header presence" >&5
18366 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18367 cat >conftest.$ac_ext <<_ACEOF
18368 /* confdefs.h.  */
18369 _ACEOF
18370 cat confdefs.h >>conftest.$ac_ext
18371 cat >>conftest.$ac_ext <<_ACEOF
18372 /* end confdefs.h.  */
18373 #include <$ac_header>
18374 _ACEOF
18375 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18376   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18377   ac_status=$?
18378   grep -v '^ *+' conftest.er1 >conftest.err
18379   rm -f conftest.er1
18380   cat conftest.err >&5
18381   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18382   (exit $ac_status); } >/dev/null; then
18383   if test -s conftest.err; then
18384     ac_cpp_err=$ac_c_preproc_warn_flag
18385     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
18386   else
18387     ac_cpp_err=
18388   fi
18389 else
18390   ac_cpp_err=yes
18391 fi
18392 if test -z "$ac_cpp_err"; then
18393   ac_header_preproc=yes
18394 else
18395   echo "$as_me: failed program was:" >&5
18396 sed 's/^/| /' conftest.$ac_ext >&5
18397
18398   ac_header_preproc=no
18399 fi
18400 rm -f conftest.err conftest.$ac_ext
18401 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18402 echo "${ECHO_T}$ac_header_preproc" >&6
18403
18404 # So?  What about this header?
18405 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18406   yes:no: )
18407     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18408 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18409     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18410 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18411     ac_header_preproc=yes
18412     ;;
18413   no:yes:* )
18414     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18415 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
18416     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
18417 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
18418     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18419 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18420     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
18421 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
18422     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18423 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18424     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18425 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
18426     (
18427       cat <<\_ASBOX
18428 ## --------------------------------------------- ##
18429 ## Report this to <http://www.openldap.org/its/> ##
18430 ## --------------------------------------------- ##
18431 _ASBOX
18432     ) |
18433       sed "s/^/$as_me: WARNING:     /" >&2
18434     ;;
18435 esac
18436 echo "$as_me:$LINENO: checking for $ac_header" >&5
18437 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18438 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18439   echo $ECHO_N "(cached) $ECHO_C" >&6
18440 else
18441   eval "$as_ac_Header=\$ac_header_preproc"
18442 fi
18443 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18444 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18445
18446 fi
18447 if test `eval echo '${'$as_ac_Header'}'` = yes; then
18448   cat >>confdefs.h <<_ACEOF
18449 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18450 _ACEOF
18451
18452 fi
18453
18454 done
18455
18456
18457         if test $ol_enable_local = auto ; then
18458                 ol_enable_local=$ac_cv_header_sys_un_h
18459         elif test $ac_cv_header_sys_un_h = no ; then
18460                 { { echo "$as_me:$LINENO: error: AF_LOCAL domain support requires sys/un.h" >&5
18461 echo "$as_me: error: AF_LOCAL domain support requires sys/un.h" >&2;}
18462    { (exit 1); exit 1; }; }
18463         fi
18464 fi
18465
18466
18467 if test $ol_with_tls = yes ; then
18468         ol_with_tls=auto
18469 fi
18470
18471 ol_link_tls=no
18472 if test $ol_with_tls = openssl || test $ol_with_tls = auto ; then
18473
18474 for ac_header in openssl/ssl.h
18475 do
18476 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18477 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18478   echo "$as_me:$LINENO: checking for $ac_header" >&5
18479 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18480 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18481   echo $ECHO_N "(cached) $ECHO_C" >&6
18482 fi
18483 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18484 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18485 else
18486   # Is the header compilable?
18487 echo "$as_me:$LINENO: checking $ac_header usability" >&5
18488 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18489 cat >conftest.$ac_ext <<_ACEOF
18490 /* confdefs.h.  */
18491 _ACEOF
18492 cat confdefs.h >>conftest.$ac_ext
18493 cat >>conftest.$ac_ext <<_ACEOF
18494 /* end confdefs.h.  */
18495 $ac_includes_default
18496 #include <$ac_header>
18497 _ACEOF
18498 rm -f conftest.$ac_objext
18499 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18500   (eval $ac_compile) 2>conftest.er1
18501   ac_status=$?
18502   grep -v '^ *+' conftest.er1 >conftest.err
18503   rm -f conftest.er1
18504   cat conftest.err >&5
18505   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18506   (exit $ac_status); } &&
18507          { ac_try='test -z "$ac_c_werror_flag"
18508                          || test ! -s conftest.err'
18509   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18510   (eval $ac_try) 2>&5
18511   ac_status=$?
18512   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18513   (exit $ac_status); }; } &&
18514          { ac_try='test -s conftest.$ac_objext'
18515   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18516   (eval $ac_try) 2>&5
18517   ac_status=$?
18518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18519   (exit $ac_status); }; }; then
18520   ac_header_compiler=yes
18521 else
18522   echo "$as_me: failed program was:" >&5
18523 sed 's/^/| /' conftest.$ac_ext >&5
18524
18525 ac_header_compiler=no
18526 fi
18527 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18528 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18529 echo "${ECHO_T}$ac_header_compiler" >&6
18530
18531 # Is the header present?
18532 echo "$as_me:$LINENO: checking $ac_header presence" >&5
18533 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18534 cat >conftest.$ac_ext <<_ACEOF
18535 /* confdefs.h.  */
18536 _ACEOF
18537 cat confdefs.h >>conftest.$ac_ext
18538 cat >>conftest.$ac_ext <<_ACEOF
18539 /* end confdefs.h.  */
18540 #include <$ac_header>
18541 _ACEOF
18542 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18543   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18544   ac_status=$?
18545   grep -v '^ *+' conftest.er1 >conftest.err
18546   rm -f conftest.er1
18547   cat conftest.err >&5
18548   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18549   (exit $ac_status); } >/dev/null; then
18550   if test -s conftest.err; then
18551     ac_cpp_err=$ac_c_preproc_warn_flag
18552     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
18553   else
18554     ac_cpp_err=
18555   fi
18556 else
18557   ac_cpp_err=yes
18558 fi
18559 if test -z "$ac_cpp_err"; then
18560   ac_header_preproc=yes
18561 else
18562   echo "$as_me: failed program was:" >&5
18563 sed 's/^/| /' conftest.$ac_ext >&5
18564
18565   ac_header_preproc=no
18566 fi
18567 rm -f conftest.err conftest.$ac_ext
18568 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18569 echo "${ECHO_T}$ac_header_preproc" >&6
18570
18571 # So?  What about this header?
18572 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18573   yes:no: )
18574     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18575 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18576     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18577 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18578     ac_header_preproc=yes
18579     ;;
18580   no:yes:* )
18581     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18582 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
18583     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
18584 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
18585     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18586 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18587     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
18588 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
18589     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18590 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18591     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18592 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
18593     (
18594       cat <<\_ASBOX
18595 ## --------------------------------------------- ##
18596 ## Report this to <http://www.openldap.org/its/> ##
18597 ## --------------------------------------------- ##
18598 _ASBOX
18599     ) |
18600       sed "s/^/$as_me: WARNING:     /" >&2
18601     ;;
18602 esac
18603 echo "$as_me:$LINENO: checking for $ac_header" >&5
18604 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18605 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18606   echo $ECHO_N "(cached) $ECHO_C" >&6
18607 else
18608   eval "$as_ac_Header=\$ac_header_preproc"
18609 fi
18610 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18611 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18612
18613 fi
18614 if test `eval echo '${'$as_ac_Header'}'` = yes; then
18615   cat >>confdefs.h <<_ACEOF
18616 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18617 _ACEOF
18618
18619 fi
18620
18621 done
18622
18623
18624         if test $ac_cv_header_openssl_ssl_h = yes ; then
18625                 echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
18626 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6
18627 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
18628   echo $ECHO_N "(cached) $ECHO_C" >&6
18629 else
18630   ac_check_lib_save_LIBS=$LIBS
18631 LIBS="-lssl -lcrypto $LIBS"
18632 cat >conftest.$ac_ext <<_ACEOF
18633 /* confdefs.h.  */
18634 _ACEOF
18635 cat confdefs.h >>conftest.$ac_ext
18636 cat >>conftest.$ac_ext <<_ACEOF
18637 /* end confdefs.h.  */
18638
18639 /* Override any gcc2 internal prototype to avoid an error.  */
18640 #ifdef __cplusplus
18641 extern "C"
18642 #endif
18643 /* We use char because int might match the return type of a gcc2
18644    builtin and then its argument prototype would still apply.  */
18645 char SSL_library_init ();
18646 int
18647 main ()
18648 {
18649 SSL_library_init ();
18650   ;
18651   return 0;
18652 }
18653 _ACEOF
18654 rm -f conftest.$ac_objext conftest$ac_exeext
18655 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18656   (eval $ac_link) 2>conftest.er1
18657   ac_status=$?
18658   grep -v '^ *+' conftest.er1 >conftest.err
18659   rm -f conftest.er1
18660   cat conftest.err >&5
18661   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18662   (exit $ac_status); } &&
18663          { ac_try='test -z "$ac_c_werror_flag"
18664                          || test ! -s conftest.err'
18665   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18666   (eval $ac_try) 2>&5
18667   ac_status=$?
18668   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18669   (exit $ac_status); }; } &&
18670          { ac_try='test -s conftest$ac_exeext'
18671   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18672   (eval $ac_try) 2>&5
18673   ac_status=$?
18674   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18675   (exit $ac_status); }; }; then
18676   ac_cv_lib_ssl_SSL_library_init=yes
18677 else
18678   echo "$as_me: failed program was:" >&5
18679 sed 's/^/| /' conftest.$ac_ext >&5
18680
18681 ac_cv_lib_ssl_SSL_library_init=no
18682 fi
18683 rm -f conftest.err conftest.$ac_objext \
18684       conftest$ac_exeext conftest.$ac_ext
18685 LIBS=$ac_check_lib_save_LIBS
18686 fi
18687 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
18688 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6
18689 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
18690   have_openssl=yes
18691                         need_rsaref=no
18692 else
18693   have_openssl=no
18694 fi
18695
18696
18697                 if test $have_openssl = no ; then
18698                         echo "$as_me:$LINENO: checking for ssl3_accept in -lssl" >&5
18699 echo $ECHO_N "checking for ssl3_accept in -lssl... $ECHO_C" >&6
18700 if test "${ac_cv_lib_ssl_ssl3_accept+set}" = set; then
18701   echo $ECHO_N "(cached) $ECHO_C" >&6
18702 else
18703   ac_check_lib_save_LIBS=$LIBS
18704 LIBS="-lssl -lcrypto -lRSAglue -lrsaref $LIBS"
18705 cat >conftest.$ac_ext <<_ACEOF
18706 /* confdefs.h.  */
18707 _ACEOF
18708 cat confdefs.h >>conftest.$ac_ext
18709 cat >>conftest.$ac_ext <<_ACEOF
18710 /* end confdefs.h.  */
18711
18712 /* Override any gcc2 internal prototype to avoid an error.  */
18713 #ifdef __cplusplus
18714 extern "C"
18715 #endif
18716 /* We use char because int might match the return type of a gcc2
18717    builtin and then its argument prototype would still apply.  */
18718 char ssl3_accept ();
18719 int
18720 main ()
18721 {
18722 ssl3_accept ();
18723   ;
18724   return 0;
18725 }
18726 _ACEOF
18727 rm -f conftest.$ac_objext conftest$ac_exeext
18728 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18729   (eval $ac_link) 2>conftest.er1
18730   ac_status=$?
18731   grep -v '^ *+' conftest.er1 >conftest.err
18732   rm -f conftest.er1
18733   cat conftest.err >&5
18734   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18735   (exit $ac_status); } &&
18736          { ac_try='test -z "$ac_c_werror_flag"
18737                          || test ! -s conftest.err'
18738   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18739   (eval $ac_try) 2>&5
18740   ac_status=$?
18741   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18742   (exit $ac_status); }; } &&
18743          { ac_try='test -s conftest$ac_exeext'
18744   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18745   (eval $ac_try) 2>&5
18746   ac_status=$?
18747   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18748   (exit $ac_status); }; }; then
18749   ac_cv_lib_ssl_ssl3_accept=yes
18750 else
18751   echo "$as_me: failed program was:" >&5
18752 sed 's/^/| /' conftest.$ac_ext >&5
18753
18754 ac_cv_lib_ssl_ssl3_accept=no
18755 fi
18756 rm -f conftest.err conftest.$ac_objext \
18757       conftest$ac_exeext conftest.$ac_ext
18758 LIBS=$ac_check_lib_save_LIBS
18759 fi
18760 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_ssl3_accept" >&5
18761 echo "${ECHO_T}$ac_cv_lib_ssl_ssl3_accept" >&6
18762 if test $ac_cv_lib_ssl_ssl3_accept = yes; then
18763   have_openssl=yes
18764                                 need_rsaref=yes
18765 else
18766   have_openssl=no
18767 fi
18768
18769                 fi
18770
18771                 if test $have_openssl = yes ; then
18772                         ol_with_tls=openssl
18773                         ol_link_tls=yes
18774
18775
18776 cat >>confdefs.h <<\_ACEOF
18777 #define HAVE_OPENSSL 1
18778 _ACEOF
18779
18780
18781                         if test $need_rsaref = yes; then
18782
18783 cat >>confdefs.h <<\_ACEOF
18784 #define HAVE_RSAREF 1
18785 _ACEOF
18786
18787
18788                                 TLS_LIBS="-lssl -lcrypto -lRSAglue -lrsaref"
18789                         else
18790                                 TLS_LIBS="-lssl -lcrypto"
18791                         fi
18792
18793                         echo "$as_me:$LINENO: checking OpenSSL library version (CRL checking capability)" >&5
18794 echo $ECHO_N "checking OpenSSL library version (CRL checking capability)... $ECHO_C" >&6
18795 if test "${ol_cv_ssl_crl_compat+set}" = set; then
18796   echo $ECHO_N "(cached) $ECHO_C" >&6
18797 else
18798
18799                 cat >conftest.$ac_ext <<_ACEOF
18800 /* confdefs.h.  */
18801 _ACEOF
18802 cat confdefs.h >>conftest.$ac_ext
18803 cat >>conftest.$ac_ext <<_ACEOF
18804 /* end confdefs.h.  */
18805
18806 #ifdef HAVE_OPENSSL_SSL_H
18807 #include <openssl/ssl.h>
18808 #endif
18809
18810 /* Require 0.9.7d+ */
18811 #if OPENSSL_VERSION_NUMBER >= 0x0090704fL
18812         char *__ssl_compat = "0.9.7d";
18813 #endif
18814
18815 _ACEOF
18816 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18817   $EGREP "__ssl_compat" >/dev/null 2>&1; then
18818   ol_cv_ssl_crl_compat=yes
18819 else
18820   ol_cv_ssl_crl_compat=no
18821 fi
18822 rm -f conftest*
18823
18824 fi
18825 echo "$as_me:$LINENO: result: $ol_cv_ssl_crl_compat" >&5
18826 echo "${ECHO_T}$ol_cv_ssl_crl_compat" >&6
18827
18828                         if test $ol_cv_ssl_crl_compat = yes ; then
18829
18830 cat >>confdefs.h <<\_ACEOF
18831 #define HAVE_OPENSSL_CRL 1
18832 _ACEOF
18833
18834                         fi
18835                 fi
18836         fi
18837 fi
18838
18839 if test $ol_link_tls = no ; then
18840         if test $ol_with_tls = gnutls || test $ol_with_tls = auto ; then
18841
18842 for ac_header in gnutls/gnutls.h
18843 do
18844 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18845 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18846   echo "$as_me:$LINENO: checking for $ac_header" >&5
18847 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18848 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18849   echo $ECHO_N "(cached) $ECHO_C" >&6
18850 fi
18851 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18852 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18853 else
18854   # Is the header compilable?
18855 echo "$as_me:$LINENO: checking $ac_header usability" >&5
18856 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18857 cat >conftest.$ac_ext <<_ACEOF
18858 /* confdefs.h.  */
18859 _ACEOF
18860 cat confdefs.h >>conftest.$ac_ext
18861 cat >>conftest.$ac_ext <<_ACEOF
18862 /* end confdefs.h.  */
18863 $ac_includes_default
18864 #include <$ac_header>
18865 _ACEOF
18866 rm -f conftest.$ac_objext
18867 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18868   (eval $ac_compile) 2>conftest.er1
18869   ac_status=$?
18870   grep -v '^ *+' conftest.er1 >conftest.err
18871   rm -f conftest.er1
18872   cat conftest.err >&5
18873   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18874   (exit $ac_status); } &&
18875          { ac_try='test -z "$ac_c_werror_flag"
18876                          || test ! -s conftest.err'
18877   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18878   (eval $ac_try) 2>&5
18879   ac_status=$?
18880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18881   (exit $ac_status); }; } &&
18882          { ac_try='test -s conftest.$ac_objext'
18883   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18884   (eval $ac_try) 2>&5
18885   ac_status=$?
18886   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18887   (exit $ac_status); }; }; then
18888   ac_header_compiler=yes
18889 else
18890   echo "$as_me: failed program was:" >&5
18891 sed 's/^/| /' conftest.$ac_ext >&5
18892
18893 ac_header_compiler=no
18894 fi
18895 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18896 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18897 echo "${ECHO_T}$ac_header_compiler" >&6
18898
18899 # Is the header present?
18900 echo "$as_me:$LINENO: checking $ac_header presence" >&5
18901 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18902 cat >conftest.$ac_ext <<_ACEOF
18903 /* confdefs.h.  */
18904 _ACEOF
18905 cat confdefs.h >>conftest.$ac_ext
18906 cat >>conftest.$ac_ext <<_ACEOF
18907 /* end confdefs.h.  */
18908 #include <$ac_header>
18909 _ACEOF
18910 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18911   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18912   ac_status=$?
18913   grep -v '^ *+' conftest.er1 >conftest.err
18914   rm -f conftest.er1
18915   cat conftest.err >&5
18916   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18917   (exit $ac_status); } >/dev/null; then
18918   if test -s conftest.err; then
18919     ac_cpp_err=$ac_c_preproc_warn_flag
18920     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
18921   else
18922     ac_cpp_err=
18923   fi
18924 else
18925   ac_cpp_err=yes
18926 fi
18927 if test -z "$ac_cpp_err"; then
18928   ac_header_preproc=yes
18929 else
18930   echo "$as_me: failed program was:" >&5
18931 sed 's/^/| /' conftest.$ac_ext >&5
18932
18933   ac_header_preproc=no
18934 fi
18935 rm -f conftest.err conftest.$ac_ext
18936 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18937 echo "${ECHO_T}$ac_header_preproc" >&6
18938
18939 # So?  What about this header?
18940 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18941   yes:no: )
18942     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18943 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18944     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18945 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18946     ac_header_preproc=yes
18947     ;;
18948   no:yes:* )
18949     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18950 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
18951     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
18952 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
18953     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18954 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18955     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
18956 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
18957     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18958 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18959     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18960 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
18961     (
18962       cat <<\_ASBOX
18963 ## --------------------------------------------- ##
18964 ## Report this to <http://www.openldap.org/its/> ##
18965 ## --------------------------------------------- ##
18966 _ASBOX
18967     ) |
18968       sed "s/^/$as_me: WARNING:     /" >&2
18969     ;;
18970 esac
18971 echo "$as_me:$LINENO: checking for $ac_header" >&5
18972 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18973 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18974   echo $ECHO_N "(cached) $ECHO_C" >&6
18975 else
18976   eval "$as_ac_Header=\$ac_header_preproc"
18977 fi
18978 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18979 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18980
18981 fi
18982 if test `eval echo '${'$as_ac_Header'}'` = yes; then
18983   cat >>confdefs.h <<_ACEOF
18984 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18985 _ACEOF
18986
18987 fi
18988
18989 done
18990
18991
18992                 if test $ac_cv_header_gnutls_gnutls_h = yes ; then
18993                         echo "$as_me:$LINENO: checking for gnutls_init in -lgnutls" >&5
18994 echo $ECHO_N "checking for gnutls_init in -lgnutls... $ECHO_C" >&6
18995 if test "${ac_cv_lib_gnutls_gnutls_init+set}" = set; then
18996   echo $ECHO_N "(cached) $ECHO_C" >&6
18997 else
18998   ac_check_lib_save_LIBS=$LIBS
18999 LIBS="-lgnutls  $LIBS"
19000 cat >conftest.$ac_ext <<_ACEOF
19001 /* confdefs.h.  */
19002 _ACEOF
19003 cat confdefs.h >>conftest.$ac_ext
19004 cat >>conftest.$ac_ext <<_ACEOF
19005 /* end confdefs.h.  */
19006
19007 /* Override any gcc2 internal prototype to avoid an error.  */
19008 #ifdef __cplusplus
19009 extern "C"
19010 #endif
19011 /* We use char because int might match the return type of a gcc2
19012    builtin and then its argument prototype would still apply.  */
19013 char gnutls_init ();
19014 int
19015 main ()
19016 {
19017 gnutls_init ();
19018   ;
19019   return 0;
19020 }
19021 _ACEOF
19022 rm -f conftest.$ac_objext conftest$ac_exeext
19023 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19024   (eval $ac_link) 2>conftest.er1
19025   ac_status=$?
19026   grep -v '^ *+' conftest.er1 >conftest.err
19027   rm -f conftest.er1
19028   cat conftest.err >&5
19029   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19030   (exit $ac_status); } &&
19031          { ac_try='test -z "$ac_c_werror_flag"
19032                          || test ! -s conftest.err'
19033   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19034   (eval $ac_try) 2>&5
19035   ac_status=$?
19036   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19037   (exit $ac_status); }; } &&
19038          { ac_try='test -s conftest$ac_exeext'
19039   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19040   (eval $ac_try) 2>&5
19041   ac_status=$?
19042   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19043   (exit $ac_status); }; }; then
19044   ac_cv_lib_gnutls_gnutls_init=yes
19045 else
19046   echo "$as_me: failed program was:" >&5
19047 sed 's/^/| /' conftest.$ac_ext >&5
19048
19049 ac_cv_lib_gnutls_gnutls_init=no
19050 fi
19051 rm -f conftest.err conftest.$ac_objext \
19052       conftest$ac_exeext conftest.$ac_ext
19053 LIBS=$ac_check_lib_save_LIBS
19054 fi
19055 echo "$as_me:$LINENO: result: $ac_cv_lib_gnutls_gnutls_init" >&5
19056 echo "${ECHO_T}$ac_cv_lib_gnutls_gnutls_init" >&6
19057 if test $ac_cv_lib_gnutls_gnutls_init = yes; then
19058   have_gnutls=yes
19059 else
19060   have_gnutls=no
19061 fi
19062
19063
19064                         if test $have_gnutls = yes ; then
19065                                 ol_with_tls=gnutls
19066                                 ol_link_tls=yes
19067
19068                                 TLS_LIBS="-lgnutls"
19069
19070
19071 cat >>confdefs.h <<\_ACEOF
19072 #define HAVE_GNUTLS 1
19073 _ACEOF
19074
19075                         fi
19076                 fi
19077         fi
19078 fi
19079
19080 WITH_TLS=no
19081 if test $ol_link_tls = yes ; then
19082
19083 cat >>confdefs.h <<\_ACEOF
19084 #define HAVE_TLS 1
19085 _ACEOF
19086
19087         WITH_TLS=yes
19088 elif test $ol_with_tls = auto ; then
19089         { echo "$as_me:$LINENO: WARNING: Could not locate TLS/SSL package" >&5
19090 echo "$as_me: WARNING: Could not locate TLS/SSL package" >&2;}
19091         { echo "$as_me:$LINENO: WARNING: TLS data protection not supported!" >&5
19092 echo "$as_me: WARNING: TLS data protection not supported!" >&2;}
19093 elif test $ol_with_tls != no ; then
19094         { { echo "$as_me:$LINENO: error: Could not locate TLS/SSL package" >&5
19095 echo "$as_me: error: Could not locate TLS/SSL package" >&2;}
19096    { (exit 1); exit 1; }; }
19097 else
19098         { echo "$as_me:$LINENO: WARNING: TLS data protection not supported!" >&5
19099 echo "$as_me: WARNING: TLS data protection not supported!" >&2;}
19100 fi
19101
19102 if test $ol_enable_lmpasswd != no; then
19103         if test $ol_link_tls != yes ; then
19104                 { { echo "$as_me:$LINENO: error: LAN Manager passwords require OpenSSL" >&5
19105 echo "$as_me: error: LAN Manager passwords require OpenSSL" >&2;}
19106    { (exit 1); exit 1; }; }
19107         fi
19108
19109
19110 cat >>confdefs.h <<\_ACEOF
19111 #define SLAPD_LMHASH 1
19112 _ACEOF
19113
19114 fi
19115
19116 ol_link_threads=no
19117
19118 case $ol_with_threads in auto | yes | nt)
19119
19120
19121         echo "$as_me:$LINENO: checking for _beginthread" >&5
19122 echo $ECHO_N "checking for _beginthread... $ECHO_C" >&6
19123 if test "${ac_cv_func__beginthread+set}" = set; then
19124   echo $ECHO_N "(cached) $ECHO_C" >&6
19125 else
19126   cat >conftest.$ac_ext <<_ACEOF
19127 /* confdefs.h.  */
19128 _ACEOF
19129 cat confdefs.h >>conftest.$ac_ext
19130 cat >>conftest.$ac_ext <<_ACEOF
19131 /* end confdefs.h.  */
19132 /* Define _beginthread to an innocuous variant, in case <limits.h> declares _beginthread.
19133    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19134 #define _beginthread innocuous__beginthread
19135
19136 /* System header to define __stub macros and hopefully few prototypes,
19137     which can conflict with char _beginthread (); below.
19138     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19139     <limits.h> exists even on freestanding compilers.  */
19140
19141 #ifdef __STDC__
19142 # include <limits.h>
19143 #else
19144 # include <assert.h>
19145 #endif
19146
19147 #undef _beginthread
19148
19149 /* Override any gcc2 internal prototype to avoid an error.  */
19150 #ifdef __cplusplus
19151 extern "C"
19152 {
19153 #endif
19154 /* We use char because int might match the return type of a gcc2
19155    builtin and then its argument prototype would still apply.  */
19156 char _beginthread ();
19157 /* The GNU C library defines this for functions which it implements
19158     to always fail with ENOSYS.  Some functions are actually named
19159     something starting with __ and the normal name is an alias.  */
19160 #if defined (__stub__beginthread) || defined (__stub____beginthread)
19161 choke me
19162 #else
19163 char (*f) () = _beginthread;
19164 #endif
19165 #ifdef __cplusplus
19166 }
19167 #endif
19168
19169 int
19170 main ()
19171 {
19172 return f != _beginthread;
19173   ;
19174   return 0;
19175 }
19176 _ACEOF
19177 rm -f conftest.$ac_objext conftest$ac_exeext
19178 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19179   (eval $ac_link) 2>conftest.er1
19180   ac_status=$?
19181   grep -v '^ *+' conftest.er1 >conftest.err
19182   rm -f conftest.er1
19183   cat conftest.err >&5
19184   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19185   (exit $ac_status); } &&
19186          { ac_try='test -z "$ac_c_werror_flag"
19187                          || test ! -s conftest.err'
19188   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19189   (eval $ac_try) 2>&5
19190   ac_status=$?
19191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19192   (exit $ac_status); }; } &&
19193          { ac_try='test -s conftest$ac_exeext'
19194   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19195   (eval $ac_try) 2>&5
19196   ac_status=$?
19197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19198   (exit $ac_status); }; }; then
19199   ac_cv_func__beginthread=yes
19200 else
19201   echo "$as_me: failed program was:" >&5
19202 sed 's/^/| /' conftest.$ac_ext >&5
19203
19204 ac_cv_func__beginthread=no
19205 fi
19206 rm -f conftest.err conftest.$ac_objext \
19207       conftest$ac_exeext conftest.$ac_ext
19208 fi
19209 echo "$as_me:$LINENO: result: $ac_cv_func__beginthread" >&5
19210 echo "${ECHO_T}$ac_cv_func__beginthread" >&6
19211
19212
19213         if test $ac_cv_func__beginthread = yes ; then
19214
19215 cat >>confdefs.h <<\_ACEOF
19216 #define HAVE_NT_THREADS 1
19217 _ACEOF
19218
19219                 ol_cv_nt_threads=yes
19220         fi
19221
19222
19223         if test "$ol_cv_nt_threads" = yes ; then
19224                 ol_link_threads=nt
19225                 ol_with_threads=found
19226                 ol_with_yielding_select=yes
19227
19228
19229 cat >>confdefs.h <<\_ACEOF
19230 #define HAVE_NT_SERVICE_MANAGER 1
19231 _ACEOF
19232
19233
19234 cat >>confdefs.h <<\_ACEOF
19235 #define HAVE_NT_EVENT_LOG 1
19236 _ACEOF
19237
19238         fi
19239
19240         if test $ol_with_threads = nt ; then
19241                 { { echo "$as_me:$LINENO: error: could not locate NT Threads" >&5
19242 echo "$as_me: error: could not locate NT Threads" >&2;}
19243    { (exit 1); exit 1; }; }
19244         fi
19245         ;;
19246 esac
19247
19248 case $ol_with_threads in auto | yes | posix)
19249
19250
19251 for ac_header in pthread.h
19252 do
19253 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
19254 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19255   echo "$as_me:$LINENO: checking for $ac_header" >&5
19256 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19257 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19258   echo $ECHO_N "(cached) $ECHO_C" >&6
19259 fi
19260 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19261 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19262 else
19263   # Is the header compilable?
19264 echo "$as_me:$LINENO: checking $ac_header usability" >&5
19265 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19266 cat >conftest.$ac_ext <<_ACEOF
19267 /* confdefs.h.  */
19268 _ACEOF
19269 cat confdefs.h >>conftest.$ac_ext
19270 cat >>conftest.$ac_ext <<_ACEOF
19271 /* end confdefs.h.  */
19272 $ac_includes_default
19273 #include <$ac_header>
19274 _ACEOF
19275 rm -f conftest.$ac_objext
19276 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19277   (eval $ac_compile) 2>conftest.er1
19278   ac_status=$?
19279   grep -v '^ *+' conftest.er1 >conftest.err
19280   rm -f conftest.er1
19281   cat conftest.err >&5
19282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19283   (exit $ac_status); } &&
19284          { ac_try='test -z "$ac_c_werror_flag"
19285                          || test ! -s conftest.err'
19286   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19287   (eval $ac_try) 2>&5
19288   ac_status=$?
19289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19290   (exit $ac_status); }; } &&
19291          { ac_try='test -s conftest.$ac_objext'
19292   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19293   (eval $ac_try) 2>&5
19294   ac_status=$?
19295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19296   (exit $ac_status); }; }; then
19297   ac_header_compiler=yes
19298 else
19299   echo "$as_me: failed program was:" >&5
19300 sed 's/^/| /' conftest.$ac_ext >&5
19301
19302 ac_header_compiler=no
19303 fi
19304 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19305 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19306 echo "${ECHO_T}$ac_header_compiler" >&6
19307
19308 # Is the header present?
19309 echo "$as_me:$LINENO: checking $ac_header presence" >&5
19310 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19311 cat >conftest.$ac_ext <<_ACEOF
19312 /* confdefs.h.  */
19313 _ACEOF
19314 cat confdefs.h >>conftest.$ac_ext
19315 cat >>conftest.$ac_ext <<_ACEOF
19316 /* end confdefs.h.  */
19317 #include <$ac_header>
19318 _ACEOF
19319 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
19320   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19321   ac_status=$?
19322   grep -v '^ *+' conftest.er1 >conftest.err
19323   rm -f conftest.er1
19324   cat conftest.err >&5
19325   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19326   (exit $ac_status); } >/dev/null; then
19327   if test -s conftest.err; then
19328     ac_cpp_err=$ac_c_preproc_warn_flag
19329     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
19330   else
19331     ac_cpp_err=
19332   fi
19333 else
19334   ac_cpp_err=yes
19335 fi
19336 if test -z "$ac_cpp_err"; then
19337   ac_header_preproc=yes
19338 else
19339   echo "$as_me: failed program was:" >&5
19340 sed 's/^/| /' conftest.$ac_ext >&5
19341
19342   ac_header_preproc=no
19343 fi
19344 rm -f conftest.err conftest.$ac_ext
19345 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19346 echo "${ECHO_T}$ac_header_preproc" >&6
19347
19348 # So?  What about this header?
19349 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19350   yes:no: )
19351     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19352 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
19353     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19354 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19355     ac_header_preproc=yes
19356     ;;
19357   no:yes:* )
19358     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19359 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
19360     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
19361 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
19362     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19363 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19364     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
19365 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
19366     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19367 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19368     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19369 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19370     (
19371       cat <<\_ASBOX
19372 ## --------------------------------------------- ##
19373 ## Report this to <http://www.openldap.org/its/> ##
19374 ## --------------------------------------------- ##
19375 _ASBOX
19376     ) |
19377       sed "s/^/$as_me: WARNING:     /" >&2
19378     ;;
19379 esac
19380 echo "$as_me:$LINENO: checking for $ac_header" >&5
19381 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19382 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19383   echo $ECHO_N "(cached) $ECHO_C" >&6
19384 else
19385   eval "$as_ac_Header=\$ac_header_preproc"
19386 fi
19387 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19388 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19389
19390 fi
19391 if test `eval echo '${'$as_ac_Header'}'` = yes; then
19392   cat >>confdefs.h <<_ACEOF
19393 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
19394 _ACEOF
19395
19396 fi
19397
19398 done
19399
19400
19401         if test $ac_cv_header_pthread_h = yes ; then
19402                 echo "$as_me:$LINENO: checking POSIX thread version" >&5
19403 echo $ECHO_N "checking POSIX thread version... $ECHO_C" >&6
19404 if test "${ol_cv_pthread_version+set}" = set; then
19405   echo $ECHO_N "(cached) $ECHO_C" >&6
19406 else
19407
19408         cat >conftest.$ac_ext <<_ACEOF
19409 /* confdefs.h.  */
19410 _ACEOF
19411 cat confdefs.h >>conftest.$ac_ext
19412 cat >>conftest.$ac_ext <<_ACEOF
19413 /* end confdefs.h.  */
19414
19415 #               include <pthread.h>
19416
19417 int
19418 main ()
19419 {
19420
19421                 int i = PTHREAD_CREATE_JOINABLE;
19422
19423   ;
19424   return 0;
19425 }
19426 _ACEOF
19427 rm -f conftest.$ac_objext
19428 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19429   (eval $ac_compile) 2>conftest.er1
19430   ac_status=$?
19431   grep -v '^ *+' conftest.er1 >conftest.err
19432   rm -f conftest.er1
19433   cat conftest.err >&5
19434   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19435   (exit $ac_status); } &&
19436          { ac_try='test -z "$ac_c_werror_flag"
19437                          || test ! -s conftest.err'
19438   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19439   (eval $ac_try) 2>&5
19440   ac_status=$?
19441   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19442   (exit $ac_status); }; } &&
19443          { ac_try='test -s conftest.$ac_objext'
19444   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19445   (eval $ac_try) 2>&5
19446   ac_status=$?
19447   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19448   (exit $ac_status); }; }; then
19449
19450         cat >conftest.$ac_ext <<_ACEOF
19451 /* confdefs.h.  */
19452 _ACEOF
19453 cat confdefs.h >>conftest.$ac_ext
19454 cat >>conftest.$ac_ext <<_ACEOF
19455 /* end confdefs.h.  */
19456 #include <pthread.h>
19457
19458 _ACEOF
19459 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19460   $EGREP "pthread_detach" >/dev/null 2>&1; then
19461   ol_cv_pthread_version=10
19462 else
19463   ol_cv_pthread_version=8
19464 fi
19465 rm -f conftest*
19466
19467 else
19468   echo "$as_me: failed program was:" >&5
19469 sed 's/^/| /' conftest.$ac_ext >&5
19470
19471
19472         cat >conftest.$ac_ext <<_ACEOF
19473 /* confdefs.h.  */
19474 _ACEOF
19475 cat confdefs.h >>conftest.$ac_ext
19476 cat >>conftest.$ac_ext <<_ACEOF
19477 /* end confdefs.h.  */
19478
19479 #               include <pthread.h>
19480 #               ifdef PTHREAD_CREATE_UNDETACHED
19481                 draft7
19482 #               endif
19483
19484 _ACEOF
19485 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19486   $EGREP "draft7" >/dev/null 2>&1; then
19487   ol_cv_pthread_version=7
19488 else
19489
19490         cat >conftest.$ac_ext <<_ACEOF
19491 /* confdefs.h.  */
19492 _ACEOF
19493 cat confdefs.h >>conftest.$ac_ext
19494 cat >>conftest.$ac_ext <<_ACEOF
19495 /* end confdefs.h.  */
19496 #include <pthread.h>
19497
19498 _ACEOF
19499 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19500   $EGREP "pthread_attr_init" >/dev/null 2>&1; then
19501   ol_cv_pthread_version=6
19502 else
19503
19504         cat >conftest.$ac_ext <<_ACEOF
19505 /* confdefs.h.  */
19506 _ACEOF
19507 cat confdefs.h >>conftest.$ac_ext
19508 cat >>conftest.$ac_ext <<_ACEOF
19509 /* end confdefs.h.  */
19510
19511 #               include <pthread.h>
19512 #ifdef          PTHREAD_MUTEX_INITIALIZER
19513                 draft5
19514 #endif
19515
19516 _ACEOF
19517 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19518   $EGREP "draft5" >/dev/null 2>&1; then
19519   ol_cv_pthread_version=5
19520 else
19521   ol_cv_pthread_version=4
19522 fi
19523 rm -f conftest*
19524
19525 fi
19526 rm -f conftest*
19527
19528 fi
19529 rm -f conftest*
19530
19531 fi
19532 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19533
19534 fi
19535 echo "$as_me:$LINENO: result: $ol_cv_pthread_version" >&5
19536 echo "${ECHO_T}$ol_cv_pthread_version" >&6
19537
19538
19539                 if test $ol_cv_pthread_version != 0 ; then
19540
19541 cat >>confdefs.h <<_ACEOF
19542 #define HAVE_PTHREADS $ol_cv_pthread_version
19543 _ACEOF
19544
19545                 else
19546                         { { echo "$as_me:$LINENO: error: unknown pthread version" >&5
19547 echo "$as_me: error: unknown pthread version" >&2;}
19548    { (exit 1); exit 1; }; }
19549                 fi
19550
19551                 # consider threads found
19552                 ol_with_threads=found
19553
19554
19555         echo "$as_me:$LINENO: checking for LinuxThreads pthread.h" >&5
19556 echo $ECHO_N "checking for LinuxThreads pthread.h... $ECHO_C" >&6
19557 if test "${ol_cv_header_linux_threads+set}" = set; then
19558   echo $ECHO_N "(cached) $ECHO_C" >&6
19559 else
19560   cat >conftest.$ac_ext <<_ACEOF
19561 /* confdefs.h.  */
19562 _ACEOF
19563 cat confdefs.h >>conftest.$ac_ext
19564 cat >>conftest.$ac_ext <<_ACEOF
19565 /* end confdefs.h.  */
19566 #include <pthread.h>
19567 _ACEOF
19568 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19569   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then
19570   ol_cv_header_linux_threads=yes
19571 else
19572   ol_cv_header_linux_threads=no
19573 fi
19574 rm -f conftest*
19575
19576
19577 fi
19578 echo "$as_me:$LINENO: result: $ol_cv_header_linux_threads" >&5
19579 echo "${ECHO_T}$ol_cv_header_linux_threads" >&6
19580         if test $ol_cv_header_linux_threads = yes; then
19581
19582 cat >>confdefs.h <<\_ACEOF
19583 #define HAVE_LINUX_THREADS 1
19584 _ACEOF
19585
19586         fi
19587
19588
19589         echo "$as_me:$LINENO: checking for GNU Pth pthread.h" >&5
19590 echo $ECHO_N "checking for GNU Pth pthread.h... $ECHO_C" >&6
19591 if test "${ol_cv_header_gnu_pth_pthread_h+set}" = set; then
19592   echo $ECHO_N "(cached) $ECHO_C" >&6
19593 else
19594   cat >conftest.$ac_ext <<_ACEOF
19595 /* confdefs.h.  */
19596 _ACEOF
19597 cat confdefs.h >>conftest.$ac_ext
19598 cat >>conftest.$ac_ext <<_ACEOF
19599 /* end confdefs.h.  */
19600 #include <pthread.h>
19601 #ifdef _POSIX_THREAD_IS_GNU_PTH
19602         __gnu_pth__;
19603 #endif
19604
19605 _ACEOF
19606 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19607   $EGREP "__gnu_pth__" >/dev/null 2>&1; then
19608   ol_cv_header_gnu_pth_pthread_h=yes
19609 else
19610   ol_cv_header_gnu_pth_pthread_h=no
19611 fi
19612 rm -f conftest*
19613
19614
19615 fi
19616 echo "$as_me:$LINENO: result: $ol_cv_header_gnu_pth_pthread_h" >&5
19617 echo "${ECHO_T}$ol_cv_header_gnu_pth_pthread_h" >&6
19618
19619
19620                 if test $ol_cv_header_gnu_pth_pthread_h = no ; then
19621
19622 for ac_header in sched.h
19623 do
19624 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
19625 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19626   echo "$as_me:$LINENO: checking for $ac_header" >&5
19627 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19628 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19629   echo $ECHO_N "(cached) $ECHO_C" >&6
19630 fi
19631 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19632 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19633 else
19634   # Is the header compilable?
19635 echo "$as_me:$LINENO: checking $ac_header usability" >&5
19636 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19637 cat >conftest.$ac_ext <<_ACEOF
19638 /* confdefs.h.  */
19639 _ACEOF
19640 cat confdefs.h >>conftest.$ac_ext
19641 cat >>conftest.$ac_ext <<_ACEOF
19642 /* end confdefs.h.  */
19643 $ac_includes_default
19644 #include <$ac_header>
19645 _ACEOF
19646 rm -f conftest.$ac_objext
19647 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19648   (eval $ac_compile) 2>conftest.er1
19649   ac_status=$?
19650   grep -v '^ *+' conftest.er1 >conftest.err
19651   rm -f conftest.er1
19652   cat conftest.err >&5
19653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19654   (exit $ac_status); } &&
19655          { ac_try='test -z "$ac_c_werror_flag"
19656                          || test ! -s conftest.err'
19657   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19658   (eval $ac_try) 2>&5
19659   ac_status=$?
19660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19661   (exit $ac_status); }; } &&
19662          { ac_try='test -s conftest.$ac_objext'
19663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19664   (eval $ac_try) 2>&5
19665   ac_status=$?
19666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19667   (exit $ac_status); }; }; then
19668   ac_header_compiler=yes
19669 else
19670   echo "$as_me: failed program was:" >&5
19671 sed 's/^/| /' conftest.$ac_ext >&5
19672
19673 ac_header_compiler=no
19674 fi
19675 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19676 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19677 echo "${ECHO_T}$ac_header_compiler" >&6
19678
19679 # Is the header present?
19680 echo "$as_me:$LINENO: checking $ac_header presence" >&5
19681 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19682 cat >conftest.$ac_ext <<_ACEOF
19683 /* confdefs.h.  */
19684 _ACEOF
19685 cat confdefs.h >>conftest.$ac_ext
19686 cat >>conftest.$ac_ext <<_ACEOF
19687 /* end confdefs.h.  */
19688 #include <$ac_header>
19689 _ACEOF
19690 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
19691   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19692   ac_status=$?
19693   grep -v '^ *+' conftest.er1 >conftest.err
19694   rm -f conftest.er1
19695   cat conftest.err >&5
19696   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19697   (exit $ac_status); } >/dev/null; then
19698   if test -s conftest.err; then
19699     ac_cpp_err=$ac_c_preproc_warn_flag
19700     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
19701   else
19702     ac_cpp_err=
19703   fi
19704 else
19705   ac_cpp_err=yes
19706 fi
19707 if test -z "$ac_cpp_err"; then
19708   ac_header_preproc=yes
19709 else
19710   echo "$as_me: failed program was:" >&5
19711 sed 's/^/| /' conftest.$ac_ext >&5
19712
19713   ac_header_preproc=no
19714 fi
19715 rm -f conftest.err conftest.$ac_ext
19716 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19717 echo "${ECHO_T}$ac_header_preproc" >&6
19718
19719 # So?  What about this header?
19720 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19721   yes:no: )
19722     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19723 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
19724     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19725 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19726     ac_header_preproc=yes
19727     ;;
19728   no:yes:* )
19729     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19730 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
19731     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
19732 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
19733     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19734 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19735     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
19736 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
19737     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19738 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19739     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19740 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19741     (
19742       cat <<\_ASBOX
19743 ## --------------------------------------------- ##
19744 ## Report this to <http://www.openldap.org/its/> ##
19745 ## --------------------------------------------- ##
19746 _ASBOX
19747     ) |
19748       sed "s/^/$as_me: WARNING:     /" >&2
19749     ;;
19750 esac
19751 echo "$as_me:$LINENO: checking for $ac_header" >&5
19752 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19753 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19754   echo $ECHO_N "(cached) $ECHO_C" >&6
19755 else
19756   eval "$as_ac_Header=\$ac_header_preproc"
19757 fi
19758 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19759 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19760
19761 fi
19762 if test `eval echo '${'$as_ac_Header'}'` = yes; then
19763   cat >>confdefs.h <<_ACEOF
19764 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
19765 _ACEOF
19766
19767 fi
19768
19769 done
19770
19771                 fi
19772
19773
19774                                 echo "$as_me:$LINENO: checking for pthread_create in default libraries" >&5
19775 echo $ECHO_N "checking for pthread_create in default libraries... $ECHO_C" >&6
19776 if test "${ol_cv_pthread_create+set}" = set; then
19777   echo $ECHO_N "(cached) $ECHO_C" >&6
19778 else
19779
19780                         if test "$cross_compiling" = yes; then
19781   cat >conftest.$ac_ext <<_ACEOF
19782 /* confdefs.h.  */
19783 _ACEOF
19784 cat confdefs.h >>conftest.$ac_ext
19785 cat >>conftest.$ac_ext <<_ACEOF
19786 /* end confdefs.h.  */
19787
19788 /* pthread test headers */
19789 #include <pthread.h>
19790 #if HAVE_PTHREADS < 7
19791 #include <errno.h>
19792 #endif
19793 #ifndef NULL
19794 #define NULL (void*)0
19795 #endif
19796
19797 static void *task(p)
19798         void *p;
19799 {
19800         return (void *) (p == NULL);
19801 }
19802
19803 int
19804 main ()
19805 {
19806
19807         /* pthread test function */
19808 #ifndef PTHREAD_CREATE_DETACHED
19809 #define PTHREAD_CREATE_DETACHED 1
19810 #endif
19811         pthread_t t;
19812         int status;
19813         int detach = PTHREAD_CREATE_DETACHED;
19814
19815 #if HAVE_PTHREADS > 4
19816         /* Final pthreads */
19817         pthread_attr_t attr;
19818
19819         status = pthread_attr_init(&attr);
19820         if( status ) return status;
19821
19822 #if HAVE_PTHREADS < 7
19823         status = pthread_attr_setdetachstate(&attr, &detach);
19824         if( status < 0 ) status = errno;
19825 #else
19826         status = pthread_attr_setdetachstate(&attr, detach);
19827 #endif
19828         if( status ) return status;
19829         status = pthread_create( &t, &attr, task, NULL );
19830 #if HAVE_PTHREADS < 7
19831         if( status < 0 ) status = errno;
19832 #endif
19833         if( status ) return status;
19834 #else
19835         /* Draft 4 pthreads */
19836         status = pthread_create( &t, pthread_attr_default, task, NULL );
19837         if( status ) return errno;
19838
19839         /* give thread a chance to complete */
19840         /* it should remain joinable and hence detachable */
19841         sleep( 1 );
19842
19843         status = pthread_detach( &t );
19844         if( status ) return errno;
19845 #endif
19846
19847 #ifdef HAVE_LINUX_THREADS
19848         pthread_kill_other_threads_np();
19849 #endif
19850
19851         return 0;
19852
19853   ;
19854   return 0;
19855 }
19856 _ACEOF
19857 rm -f conftest.$ac_objext conftest$ac_exeext
19858 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19859   (eval $ac_link) 2>conftest.er1
19860   ac_status=$?
19861   grep -v '^ *+' conftest.er1 >conftest.err
19862   rm -f conftest.er1
19863   cat conftest.err >&5
19864   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19865   (exit $ac_status); } &&
19866          { ac_try='test -z "$ac_c_werror_flag"
19867                          || test ! -s conftest.err'
19868   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19869   (eval $ac_try) 2>&5
19870   ac_status=$?
19871   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19872   (exit $ac_status); }; } &&
19873          { ac_try='test -s conftest$ac_exeext'
19874   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19875   (eval $ac_try) 2>&5
19876   ac_status=$?
19877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19878   (exit $ac_status); }; }; then
19879   ol_cv_pthread_create=yes
19880 else
19881   echo "$as_me: failed program was:" >&5
19882 sed 's/^/| /' conftest.$ac_ext >&5
19883
19884 ol_cv_pthread_create=no
19885 fi
19886 rm -f conftest.err conftest.$ac_objext \
19887       conftest$ac_exeext conftest.$ac_ext
19888 else
19889   cat >conftest.$ac_ext <<_ACEOF
19890 /* confdefs.h.  */
19891 _ACEOF
19892 cat confdefs.h >>conftest.$ac_ext
19893 cat >>conftest.$ac_ext <<_ACEOF
19894 /* end confdefs.h.  */
19895
19896 /* pthread test headers */
19897 #include <pthread.h>
19898 #if HAVE_PTHREADS < 7
19899 #include <errno.h>
19900 #endif
19901 #ifndef NULL
19902 #define NULL (void*)0
19903 #endif
19904
19905 static void *task(p)
19906         void *p;
19907 {
19908         return (void *) (p == NULL);
19909 }
19910
19911
19912 int main(argc, argv)
19913         int argc;
19914         char **argv;
19915 {
19916
19917         /* pthread test function */
19918 #ifndef PTHREAD_CREATE_DETACHED
19919 #define PTHREAD_CREATE_DETACHED 1
19920 #endif
19921         pthread_t t;
19922         int status;
19923         int detach = PTHREAD_CREATE_DETACHED;
19924
19925 #if HAVE_PTHREADS > 4
19926         /* Final pthreads */
19927         pthread_attr_t attr;
19928
19929         status = pthread_attr_init(&attr);
19930         if( status ) return status;
19931
19932 #if HAVE_PTHREADS < 7
19933         status = pthread_attr_setdetachstate(&attr, &detach);
19934         if( status < 0 ) status = errno;
19935 #else
19936         status = pthread_attr_setdetachstate(&attr, detach);
19937 #endif
19938         if( status ) return status;
19939         status = pthread_create( &t, &attr, task, NULL );
19940 #if HAVE_PTHREADS < 7
19941         if( status < 0 ) status = errno;
19942 #endif
19943         if( status ) return status;
19944 #else
19945         /* Draft 4 pthreads */
19946         status = pthread_create( &t, pthread_attr_default, task, NULL );
19947         if( status ) return errno;
19948
19949         /* give thread a chance to complete */
19950         /* it should remain joinable and hence detachable */
19951         sleep( 1 );
19952
19953         status = pthread_detach( &t );
19954         if( status ) return errno;
19955 #endif
19956
19957 #ifdef HAVE_LINUX_THREADS
19958         pthread_kill_other_threads_np();
19959 #endif
19960
19961         return 0;
19962
19963 }
19964
19965 _ACEOF
19966 rm -f conftest$ac_exeext
19967 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19968   (eval $ac_link) 2>&5
19969   ac_status=$?
19970   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19971   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19972   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19973   (eval $ac_try) 2>&5
19974   ac_status=$?
19975   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19976   (exit $ac_status); }; }; then
19977   ol_cv_pthread_create=yes
19978 else
19979   echo "$as_me: program exited with status $ac_status" >&5
19980 echo "$as_me: failed program was:" >&5
19981 sed 's/^/| /' conftest.$ac_ext >&5
19982
19983 ( exit $ac_status )
19984 ol_cv_pthread_create=no
19985 fi
19986 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19987 fi
19988 fi
19989 echo "$as_me:$LINENO: result: $ol_cv_pthread_create" >&5
19990 echo "${ECHO_T}$ol_cv_pthread_create" >&6
19991
19992                 if test $ol_cv_pthread_create != no ; then
19993                         ol_link_threads=posix
19994                         ol_link_pthreads=""
19995                 fi
19996
19997                 # Pthread try link: -kthread (ol_cv_pthread_kthread)
19998 if test "$ol_link_threads" = no ; then
19999         # try -kthread
20000         echo "$as_me:$LINENO: checking for pthread link with -kthread" >&5
20001 echo $ECHO_N "checking for pthread link with -kthread... $ECHO_C" >&6
20002 if test "${ol_cv_pthread_kthread+set}" = set; then
20003   echo $ECHO_N "(cached) $ECHO_C" >&6
20004 else
20005
20006                 # save the flags
20007                 ol_LIBS="$LIBS"
20008                 LIBS="-kthread $LIBS"
20009
20010                 if test "$cross_compiling" = yes; then
20011   cat >conftest.$ac_ext <<_ACEOF
20012 /* confdefs.h.  */
20013 _ACEOF
20014 cat confdefs.h >>conftest.$ac_ext
20015 cat >>conftest.$ac_ext <<_ACEOF
20016 /* end confdefs.h.  */
20017
20018 /* pthread test headers */
20019 #include <pthread.h>
20020 #if HAVE_PTHREADS < 7
20021 #include <errno.h>
20022 #endif
20023 #ifndef NULL
20024 #define NULL (void*)0
20025 #endif
20026
20027 static void *task(p)
20028         void *p;
20029 {
20030         return (void *) (p == NULL);
20031 }
20032
20033 int
20034 main ()
20035 {
20036
20037         /* pthread test function */
20038 #ifndef PTHREAD_CREATE_DETACHED
20039 #define PTHREAD_CREATE_DETACHED 1
20040 #endif
20041         pthread_t t;
20042         int status;
20043         int detach = PTHREAD_CREATE_DETACHED;
20044
20045 #if HAVE_PTHREADS > 4
20046         /* Final pthreads */
20047         pthread_attr_t attr;
20048
20049         status = pthread_attr_init(&attr);
20050         if( status ) return status;
20051
20052 #if HAVE_PTHREADS < 7
20053         status = pthread_attr_setdetachstate(&attr, &detach);
20054         if( status < 0 ) status = errno;
20055 #else
20056         status = pthread_attr_setdetachstate(&attr, detach);
20057 #endif
20058         if( status ) return status;
20059         status = pthread_create( &t, &attr, task, NULL );
20060 #if HAVE_PTHREADS < 7
20061         if( status < 0 ) status = errno;
20062 #endif
20063         if( status ) return status;
20064 #else
20065         /* Draft 4 pthreads */
20066         status = pthread_create( &t, pthread_attr_default, task, NULL );
20067         if( status ) return errno;
20068
20069         /* give thread a chance to complete */
20070         /* it should remain joinable and hence detachable */
20071         sleep( 1 );
20072
20073         status = pthread_detach( &t );
20074         if( status ) return errno;
20075 #endif
20076
20077 #ifdef HAVE_LINUX_THREADS
20078         pthread_kill_other_threads_np();
20079 #endif
20080
20081         return 0;
20082
20083   ;
20084   return 0;
20085 }
20086 _ACEOF
20087 rm -f conftest.$ac_objext conftest$ac_exeext
20088 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20089   (eval $ac_link) 2>conftest.er1
20090   ac_status=$?
20091   grep -v '^ *+' conftest.er1 >conftest.err
20092   rm -f conftest.er1
20093   cat conftest.err >&5
20094   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20095   (exit $ac_status); } &&
20096          { ac_try='test -z "$ac_c_werror_flag"
20097                          || test ! -s conftest.err'
20098   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20099   (eval $ac_try) 2>&5
20100   ac_status=$?
20101   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20102   (exit $ac_status); }; } &&
20103          { ac_try='test -s conftest$ac_exeext'
20104   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20105   (eval $ac_try) 2>&5
20106   ac_status=$?
20107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20108   (exit $ac_status); }; }; then
20109   ol_cv_pthread_kthread=yes
20110 else
20111   echo "$as_me: failed program was:" >&5
20112 sed 's/^/| /' conftest.$ac_ext >&5
20113
20114 ol_cv_pthread_kthread=no
20115 fi
20116 rm -f conftest.err conftest.$ac_objext \
20117       conftest$ac_exeext conftest.$ac_ext
20118 else
20119   cat >conftest.$ac_ext <<_ACEOF
20120 /* confdefs.h.  */
20121 _ACEOF
20122 cat confdefs.h >>conftest.$ac_ext
20123 cat >>conftest.$ac_ext <<_ACEOF
20124 /* end confdefs.h.  */
20125
20126 /* pthread test headers */
20127 #include <pthread.h>
20128 #if HAVE_PTHREADS < 7
20129 #include <errno.h>
20130 #endif
20131 #ifndef NULL
20132 #define NULL (void*)0
20133 #endif
20134
20135 static void *task(p)
20136         void *p;
20137 {
20138         return (void *) (p == NULL);
20139 }
20140
20141
20142 int main(argc, argv)
20143         int argc;
20144         char **argv;
20145 {
20146
20147         /* pthread test function */
20148 #ifndef PTHREAD_CREATE_DETACHED
20149 #define PTHREAD_CREATE_DETACHED 1
20150 #endif
20151         pthread_t t;
20152         int status;
20153         int detach = PTHREAD_CREATE_DETACHED;
20154
20155 #if HAVE_PTHREADS > 4
20156         /* Final pthreads */
20157         pthread_attr_t attr;
20158
20159         status = pthread_attr_init(&attr);
20160         if( status ) return status;
20161
20162 #if HAVE_PTHREADS < 7
20163         status = pthread_attr_setdetachstate(&attr, &detach);
20164         if( status < 0 ) status = errno;
20165 #else
20166         status = pthread_attr_setdetachstate(&attr, detach);
20167 #endif
20168         if( status ) return status;
20169         status = pthread_create( &t, &attr, task, NULL );
20170 #if HAVE_PTHREADS < 7
20171         if( status < 0 ) status = errno;
20172 #endif
20173         if( status ) return status;
20174 #else
20175         /* Draft 4 pthreads */
20176         status = pthread_create( &t, pthread_attr_default, task, NULL );
20177         if( status ) return errno;
20178
20179         /* give thread a chance to complete */
20180         /* it should remain joinable and hence detachable */
20181         sleep( 1 );
20182
20183         status = pthread_detach( &t );
20184         if( status ) return errno;
20185 #endif
20186
20187 #ifdef HAVE_LINUX_THREADS
20188         pthread_kill_other_threads_np();
20189 #endif
20190
20191         return 0;
20192
20193 }
20194
20195 _ACEOF
20196 rm -f conftest$ac_exeext
20197 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20198   (eval $ac_link) 2>&5
20199   ac_status=$?
20200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20201   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20202   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20203   (eval $ac_try) 2>&5
20204   ac_status=$?
20205   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20206   (exit $ac_status); }; }; then
20207   ol_cv_pthread_kthread=yes
20208 else
20209   echo "$as_me: program exited with status $ac_status" >&5
20210 echo "$as_me: failed program was:" >&5
20211 sed 's/^/| /' conftest.$ac_ext >&5
20212
20213 ( exit $ac_status )
20214 ol_cv_pthread_kthread=no
20215 fi
20216 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20217 fi
20218
20219                 # restore the LIBS
20220                 LIBS="$ol_LIBS"
20221
20222 fi
20223 echo "$as_me:$LINENO: result: $ol_cv_pthread_kthread" >&5
20224 echo "${ECHO_T}$ol_cv_pthread_kthread" >&6
20225
20226         if test $ol_cv_pthread_kthread = yes ; then
20227                 ol_link_pthreads="-kthread"
20228                 ol_link_threads=posix
20229         fi
20230 fi
20231
20232                 # Pthread try link: -pthread (ol_cv_pthread_pthread)
20233 if test "$ol_link_threads" = no ; then
20234         # try -pthread
20235         echo "$as_me:$LINENO: checking for pthread link with -pthread" >&5
20236 echo $ECHO_N "checking for pthread link with -pthread... $ECHO_C" >&6
20237 if test "${ol_cv_pthread_pthread+set}" = set; then
20238   echo $ECHO_N "(cached) $ECHO_C" >&6
20239 else
20240
20241                 # save the flags
20242                 ol_LIBS="$LIBS"
20243                 LIBS="-pthread $LIBS"
20244
20245                 if test "$cross_compiling" = yes; then
20246   cat >conftest.$ac_ext <<_ACEOF
20247 /* confdefs.h.  */
20248 _ACEOF
20249 cat confdefs.h >>conftest.$ac_ext
20250 cat >>conftest.$ac_ext <<_ACEOF
20251 /* end confdefs.h.  */
20252
20253 /* pthread test headers */
20254 #include <pthread.h>
20255 #if HAVE_PTHREADS < 7
20256 #include <errno.h>
20257 #endif
20258 #ifndef NULL
20259 #define NULL (void*)0
20260 #endif
20261
20262 static void *task(p)
20263         void *p;
20264 {
20265         return (void *) (p == NULL);
20266 }
20267
20268 int
20269 main ()
20270 {
20271
20272         /* pthread test function */
20273 #ifndef PTHREAD_CREATE_DETACHED
20274 #define PTHREAD_CREATE_DETACHED 1
20275 #endif
20276         pthread_t t;
20277         int status;
20278         int detach = PTHREAD_CREATE_DETACHED;
20279
20280 #if HAVE_PTHREADS > 4
20281         /* Final pthreads */
20282         pthread_attr_t attr;
20283
20284         status = pthread_attr_init(&attr);
20285         if( status ) return status;
20286
20287 #if HAVE_PTHREADS < 7
20288         status = pthread_attr_setdetachstate(&attr, &detach);
20289         if( status < 0 ) status = errno;
20290 #else
20291         status = pthread_attr_setdetachstate(&attr, detach);
20292 #endif
20293         if( status ) return status;
20294         status = pthread_create( &t, &attr, task, NULL );
20295 #if HAVE_PTHREADS < 7
20296         if( status < 0 ) status = errno;
20297 #endif
20298         if( status ) return status;
20299 #else
20300         /* Draft 4 pthreads */
20301         status = pthread_create( &t, pthread_attr_default, task, NULL );
20302         if( status ) return errno;
20303
20304         /* give thread a chance to complete */
20305         /* it should remain joinable and hence detachable */
20306         sleep( 1 );
20307
20308         status = pthread_detach( &t );
20309         if( status ) return errno;
20310 #endif
20311
20312 #ifdef HAVE_LINUX_THREADS
20313         pthread_kill_other_threads_np();
20314 #endif
20315
20316         return 0;
20317
20318   ;
20319   return 0;
20320 }
20321 _ACEOF
20322 rm -f conftest.$ac_objext conftest$ac_exeext
20323 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20324   (eval $ac_link) 2>conftest.er1
20325   ac_status=$?
20326   grep -v '^ *+' conftest.er1 >conftest.err
20327   rm -f conftest.er1
20328   cat conftest.err >&5
20329   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20330   (exit $ac_status); } &&
20331          { ac_try='test -z "$ac_c_werror_flag"
20332                          || test ! -s conftest.err'
20333   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20334   (eval $ac_try) 2>&5
20335   ac_status=$?
20336   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20337   (exit $ac_status); }; } &&
20338          { ac_try='test -s conftest$ac_exeext'
20339   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20340   (eval $ac_try) 2>&5
20341   ac_status=$?
20342   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20343   (exit $ac_status); }; }; then
20344   ol_cv_pthread_pthread=yes
20345 else
20346   echo "$as_me: failed program was:" >&5
20347 sed 's/^/| /' conftest.$ac_ext >&5
20348
20349 ol_cv_pthread_pthread=no
20350 fi
20351 rm -f conftest.err conftest.$ac_objext \
20352       conftest$ac_exeext conftest.$ac_ext
20353 else
20354   cat >conftest.$ac_ext <<_ACEOF
20355 /* confdefs.h.  */
20356 _ACEOF
20357 cat confdefs.h >>conftest.$ac_ext
20358 cat >>conftest.$ac_ext <<_ACEOF
20359 /* end confdefs.h.  */
20360
20361 /* pthread test headers */
20362 #include <pthread.h>
20363 #if HAVE_PTHREADS < 7
20364 #include <errno.h>
20365 #endif
20366 #ifndef NULL
20367 #define NULL (void*)0
20368 #endif
20369
20370 static void *task(p)
20371         void *p;
20372 {
20373         return (void *) (p == NULL);
20374 }
20375
20376
20377 int main(argc, argv)
20378         int argc;
20379         char **argv;
20380 {
20381
20382         /* pthread test function */
20383 #ifndef PTHREAD_CREATE_DETACHED
20384 #define PTHREAD_CREATE_DETACHED 1
20385 #endif
20386         pthread_t t;
20387         int status;
20388         int detach = PTHREAD_CREATE_DETACHED;
20389
20390 #if HAVE_PTHREADS > 4
20391         /* Final pthreads */
20392         pthread_attr_t attr;
20393
20394         status = pthread_attr_init(&attr);
20395         if( status ) return status;
20396
20397 #if HAVE_PTHREADS < 7
20398         status = pthread_attr_setdetachstate(&attr, &detach);
20399         if( status < 0 ) status = errno;
20400 #else
20401         status = pthread_attr_setdetachstate(&attr, detach);
20402 #endif
20403         if( status ) return status;
20404         status = pthread_create( &t, &attr, task, NULL );
20405 #if HAVE_PTHREADS < 7
20406         if( status < 0 ) status = errno;
20407 #endif
20408         if( status ) return status;
20409 #else
20410         /* Draft 4 pthreads */
20411         status = pthread_create( &t, pthread_attr_default, task, NULL );
20412         if( status ) return errno;
20413
20414         /* give thread a chance to complete */
20415         /* it should remain joinable and hence detachable */
20416         sleep( 1 );
20417
20418         status = pthread_detach( &t );
20419         if( status ) return errno;
20420 #endif
20421
20422 #ifdef HAVE_LINUX_THREADS
20423         pthread_kill_other_threads_np();
20424 #endif
20425
20426         return 0;
20427
20428 }
20429
20430 _ACEOF
20431 rm -f conftest$ac_exeext
20432 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20433   (eval $ac_link) 2>&5
20434   ac_status=$?
20435   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20436   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20437   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20438   (eval $ac_try) 2>&5
20439   ac_status=$?
20440   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20441   (exit $ac_status); }; }; then
20442   ol_cv_pthread_pthread=yes
20443 else
20444   echo "$as_me: program exited with status $ac_status" >&5
20445 echo "$as_me: failed program was:" >&5
20446 sed 's/^/| /' conftest.$ac_ext >&5
20447
20448 ( exit $ac_status )
20449 ol_cv_pthread_pthread=no
20450 fi
20451 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20452 fi
20453
20454                 # restore the LIBS
20455                 LIBS="$ol_LIBS"
20456
20457 fi
20458 echo "$as_me:$LINENO: result: $ol_cv_pthread_pthread" >&5
20459 echo "${ECHO_T}$ol_cv_pthread_pthread" >&6
20460
20461         if test $ol_cv_pthread_pthread = yes ; then
20462                 ol_link_pthreads="-pthread"
20463                 ol_link_threads=posix
20464         fi
20465 fi
20466
20467                 # Pthread try link: -pthreads (ol_cv_pthread_pthreads)
20468 if test "$ol_link_threads" = no ; then
20469         # try -pthreads
20470         echo "$as_me:$LINENO: checking for pthread link with -pthreads" >&5
20471 echo $ECHO_N "checking for pthread link with -pthreads... $ECHO_C" >&6
20472 if test "${ol_cv_pthread_pthreads+set}" = set; then
20473   echo $ECHO_N "(cached) $ECHO_C" >&6
20474 else
20475
20476                 # save the flags
20477                 ol_LIBS="$LIBS"
20478                 LIBS="-pthreads $LIBS"
20479
20480                 if test "$cross_compiling" = yes; then
20481   cat >conftest.$ac_ext <<_ACEOF
20482 /* confdefs.h.  */
20483 _ACEOF
20484 cat confdefs.h >>conftest.$ac_ext
20485 cat >>conftest.$ac_ext <<_ACEOF
20486 /* end confdefs.h.  */
20487
20488 /* pthread test headers */
20489 #include <pthread.h>
20490 #if HAVE_PTHREADS < 7
20491 #include <errno.h>
20492 #endif
20493 #ifndef NULL
20494 #define NULL (void*)0
20495 #endif
20496
20497 static void *task(p)
20498         void *p;
20499 {
20500         return (void *) (p == NULL);
20501 }
20502
20503 int
20504 main ()
20505 {
20506
20507         /* pthread test function */
20508 #ifndef PTHREAD_CREATE_DETACHED
20509 #define PTHREAD_CREATE_DETACHED 1
20510 #endif
20511         pthread_t t;
20512         int status;
20513         int detach = PTHREAD_CREATE_DETACHED;
20514
20515 #if HAVE_PTHREADS > 4
20516         /* Final pthreads */
20517         pthread_attr_t attr;
20518
20519         status = pthread_attr_init(&attr);
20520         if( status ) return status;
20521
20522 #if HAVE_PTHREADS < 7
20523         status = pthread_attr_setdetachstate(&attr, &detach);
20524         if( status < 0 ) status = errno;
20525 #else
20526         status = pthread_attr_setdetachstate(&attr, detach);
20527 #endif
20528         if( status ) return status;
20529         status = pthread_create( &t, &attr, task, NULL );
20530 #if HAVE_PTHREADS < 7
20531         if( status < 0 ) status = errno;
20532 #endif
20533         if( status ) return status;
20534 #else
20535         /* Draft 4 pthreads */
20536         status = pthread_create( &t, pthread_attr_default, task, NULL );
20537         if( status ) return errno;
20538
20539         /* give thread a chance to complete */
20540         /* it should remain joinable and hence detachable */
20541         sleep( 1 );
20542
20543         status = pthread_detach( &t );
20544         if( status ) return errno;
20545 #endif
20546
20547 #ifdef HAVE_LINUX_THREADS
20548         pthread_kill_other_threads_np();
20549 #endif
20550
20551         return 0;
20552
20553   ;
20554   return 0;
20555 }
20556 _ACEOF
20557 rm -f conftest.$ac_objext conftest$ac_exeext
20558 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20559   (eval $ac_link) 2>conftest.er1
20560   ac_status=$?
20561   grep -v '^ *+' conftest.er1 >conftest.err
20562   rm -f conftest.er1
20563   cat conftest.err >&5
20564   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20565   (exit $ac_status); } &&
20566          { ac_try='test -z "$ac_c_werror_flag"
20567                          || test ! -s conftest.err'
20568   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20569   (eval $ac_try) 2>&5
20570   ac_status=$?
20571   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20572   (exit $ac_status); }; } &&
20573          { ac_try='test -s conftest$ac_exeext'
20574   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20575   (eval $ac_try) 2>&5
20576   ac_status=$?
20577   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20578   (exit $ac_status); }; }; then
20579   ol_cv_pthread_pthreads=yes
20580 else
20581   echo "$as_me: failed program was:" >&5
20582 sed 's/^/| /' conftest.$ac_ext >&5
20583
20584 ol_cv_pthread_pthreads=no
20585 fi
20586 rm -f conftest.err conftest.$ac_objext \
20587       conftest$ac_exeext conftest.$ac_ext
20588 else
20589   cat >conftest.$ac_ext <<_ACEOF
20590 /* confdefs.h.  */
20591 _ACEOF
20592 cat confdefs.h >>conftest.$ac_ext
20593 cat >>conftest.$ac_ext <<_ACEOF
20594 /* end confdefs.h.  */
20595
20596 /* pthread test headers */
20597 #include <pthread.h>
20598 #if HAVE_PTHREADS < 7
20599 #include <errno.h>
20600 #endif
20601 #ifndef NULL
20602 #define NULL (void*)0
20603 #endif
20604
20605 static void *task(p)
20606         void *p;
20607 {
20608         return (void *) (p == NULL);
20609 }
20610
20611
20612 int main(argc, argv)
20613         int argc;
20614         char **argv;
20615 {
20616
20617         /* pthread test function */
20618 #ifndef PTHREAD_CREATE_DETACHED
20619 #define PTHREAD_CREATE_DETACHED 1
20620 #endif
20621         pthread_t t;
20622         int status;
20623         int detach = PTHREAD_CREATE_DETACHED;
20624
20625 #if HAVE_PTHREADS > 4
20626         /* Final pthreads */
20627         pthread_attr_t attr;
20628
20629         status = pthread_attr_init(&attr);
20630         if( status ) return status;
20631
20632 #if HAVE_PTHREADS < 7
20633         status = pthread_attr_setdetachstate(&attr, &detach);
20634         if( status < 0 ) status = errno;
20635 #else
20636         status = pthread_attr_setdetachstate(&attr, detach);
20637 #endif
20638         if( status ) return status;
20639         status = pthread_create( &t, &attr, task, NULL );
20640 #if HAVE_PTHREADS < 7
20641         if( status < 0 ) status = errno;
20642 #endif
20643         if( status ) return status;
20644 #else
20645         /* Draft 4 pthreads */
20646         status = pthread_create( &t, pthread_attr_default, task, NULL );
20647         if( status ) return errno;
20648
20649         /* give thread a chance to complete */
20650         /* it should remain joinable and hence detachable */
20651         sleep( 1 );
20652
20653         status = pthread_detach( &t );
20654         if( status ) return errno;
20655 #endif
20656
20657 #ifdef HAVE_LINUX_THREADS
20658         pthread_kill_other_threads_np();
20659 #endif
20660
20661         return 0;
20662
20663 }
20664
20665 _ACEOF
20666 rm -f conftest$ac_exeext
20667 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20668   (eval $ac_link) 2>&5
20669   ac_status=$?
20670   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20671   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20672   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20673   (eval $ac_try) 2>&5
20674   ac_status=$?
20675   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20676   (exit $ac_status); }; }; then
20677   ol_cv_pthread_pthreads=yes
20678 else
20679   echo "$as_me: program exited with status $ac_status" >&5
20680 echo "$as_me: failed program was:" >&5
20681 sed 's/^/| /' conftest.$ac_ext >&5
20682
20683 ( exit $ac_status )
20684 ol_cv_pthread_pthreads=no
20685 fi
20686 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20687 fi
20688
20689                 # restore the LIBS
20690                 LIBS="$ol_LIBS"
20691
20692 fi
20693 echo "$as_me:$LINENO: result: $ol_cv_pthread_pthreads" >&5
20694 echo "${ECHO_T}$ol_cv_pthread_pthreads" >&6
20695
20696         if test $ol_cv_pthread_pthreads = yes ; then
20697                 ol_link_pthreads="-pthreads"
20698                 ol_link_threads=posix
20699         fi
20700 fi
20701
20702                 # Pthread try link: -mthreads (ol_cv_pthread_mthreads)
20703 if test "$ol_link_threads" = no ; then
20704         # try -mthreads
20705         echo "$as_me:$LINENO: checking for pthread link with -mthreads" >&5
20706 echo $ECHO_N "checking for pthread link with -mthreads... $ECHO_C" >&6
20707 if test "${ol_cv_pthread_mthreads+set}" = set; then
20708   echo $ECHO_N "(cached) $ECHO_C" >&6
20709 else
20710
20711                 # save the flags
20712                 ol_LIBS="$LIBS"
20713                 LIBS="-mthreads $LIBS"
20714
20715                 if test "$cross_compiling" = yes; then
20716   cat >conftest.$ac_ext <<_ACEOF
20717 /* confdefs.h.  */
20718 _ACEOF
20719 cat confdefs.h >>conftest.$ac_ext
20720 cat >>conftest.$ac_ext <<_ACEOF
20721 /* end confdefs.h.  */
20722
20723 /* pthread test headers */
20724 #include <pthread.h>
20725 #if HAVE_PTHREADS < 7
20726 #include <errno.h>
20727 #endif
20728 #ifndef NULL
20729 #define NULL (void*)0
20730 #endif
20731
20732 static void *task(p)
20733         void *p;
20734 {
20735         return (void *) (p == NULL);
20736 }
20737
20738 int
20739 main ()
20740 {
20741
20742         /* pthread test function */
20743 #ifndef PTHREAD_CREATE_DETACHED
20744 #define PTHREAD_CREATE_DETACHED 1
20745 #endif
20746         pthread_t t;
20747         int status;
20748         int detach = PTHREAD_CREATE_DETACHED;
20749
20750 #if HAVE_PTHREADS > 4
20751         /* Final pthreads */
20752         pthread_attr_t attr;
20753
20754         status = pthread_attr_init(&attr);
20755         if( status ) return status;
20756
20757 #if HAVE_PTHREADS < 7
20758         status = pthread_attr_setdetachstate(&attr, &detach);
20759         if( status < 0 ) status = errno;
20760 #else
20761         status = pthread_attr_setdetachstate(&attr, detach);
20762 #endif
20763         if( status ) return status;
20764         status = pthread_create( &t, &attr, task, NULL );
20765 #if HAVE_PTHREADS < 7
20766         if( status < 0 ) status = errno;
20767 #endif
20768         if( status ) return status;
20769 #else
20770         /* Draft 4 pthreads */
20771         status = pthread_create( &t, pthread_attr_default, task, NULL );
20772         if( status ) return errno;
20773
20774         /* give thread a chance to complete */
20775         /* it should remain joinable and hence detachable */
20776         sleep( 1 );
20777
20778         status = pthread_detach( &t );
20779         if( status ) return errno;
20780 #endif
20781
20782 #ifdef HAVE_LINUX_THREADS
20783         pthread_kill_other_threads_np();
20784 #endif
20785
20786         return 0;
20787
20788   ;
20789   return 0;
20790 }
20791 _ACEOF
20792 rm -f conftest.$ac_objext conftest$ac_exeext
20793 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20794   (eval $ac_link) 2>conftest.er1
20795   ac_status=$?
20796   grep -v '^ *+' conftest.er1 >conftest.err
20797   rm -f conftest.er1
20798   cat conftest.err >&5
20799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20800   (exit $ac_status); } &&
20801          { ac_try='test -z "$ac_c_werror_flag"
20802                          || test ! -s conftest.err'
20803   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20804   (eval $ac_try) 2>&5
20805   ac_status=$?
20806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20807   (exit $ac_status); }; } &&
20808          { ac_try='test -s conftest$ac_exeext'
20809   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20810   (eval $ac_try) 2>&5
20811   ac_status=$?
20812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20813   (exit $ac_status); }; }; then
20814   ol_cv_pthread_mthreads=yes
20815 else
20816   echo "$as_me: failed program was:" >&5
20817 sed 's/^/| /' conftest.$ac_ext >&5
20818
20819 ol_cv_pthread_mthreads=no
20820 fi
20821 rm -f conftest.err conftest.$ac_objext \
20822       conftest$ac_exeext conftest.$ac_ext
20823 else
20824   cat >conftest.$ac_ext <<_ACEOF
20825 /* confdefs.h.  */
20826 _ACEOF
20827 cat confdefs.h >>conftest.$ac_ext
20828 cat >>conftest.$ac_ext <<_ACEOF
20829 /* end confdefs.h.  */
20830
20831 /* pthread test headers */
20832 #include <pthread.h>
20833 #if HAVE_PTHREADS < 7
20834 #include <errno.h>
20835 #endif
20836 #ifndef NULL
20837 #define NULL (void*)0
20838 #endif
20839
20840 static void *task(p)
20841         void *p;
20842 {
20843         return (void *) (p == NULL);
20844 }
20845
20846
20847 int main(argc, argv)
20848         int argc;
20849         char **argv;
20850 {
20851
20852         /* pthread test function */
20853 #ifndef PTHREAD_CREATE_DETACHED
20854 #define PTHREAD_CREATE_DETACHED 1
20855 #endif
20856         pthread_t t;
20857         int status;
20858         int detach = PTHREAD_CREATE_DETACHED;
20859
20860 #if HAVE_PTHREADS > 4
20861         /* Final pthreads */
20862         pthread_attr_t attr;
20863
20864         status = pthread_attr_init(&attr);
20865         if( status ) return status;
20866
20867 #if HAVE_PTHREADS < 7
20868         status = pthread_attr_setdetachstate(&attr, &detach);
20869         if( status < 0 ) status = errno;
20870 #else
20871         status = pthread_attr_setdetachstate(&attr, detach);
20872 #endif
20873         if( status ) return status;
20874         status = pthread_create( &t, &attr, task, NULL );
20875 #if HAVE_PTHREADS < 7
20876         if( status < 0 ) status = errno;
20877 #endif
20878         if( status ) return status;
20879 #else
20880         /* Draft 4 pthreads */
20881         status = pthread_create( &t, pthread_attr_default, task, NULL );
20882         if( status ) return errno;
20883
20884         /* give thread a chance to complete */
20885         /* it should remain joinable and hence detachable */
20886         sleep( 1 );
20887
20888         status = pthread_detach( &t );
20889         if( status ) return errno;
20890 #endif
20891
20892 #ifdef HAVE_LINUX_THREADS
20893         pthread_kill_other_threads_np();
20894 #endif
20895
20896         return 0;
20897
20898 }
20899
20900 _ACEOF
20901 rm -f conftest$ac_exeext
20902 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20903   (eval $ac_link) 2>&5
20904   ac_status=$?
20905   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20906   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20907   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20908   (eval $ac_try) 2>&5
20909   ac_status=$?
20910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20911   (exit $ac_status); }; }; then
20912   ol_cv_pthread_mthreads=yes
20913 else
20914   echo "$as_me: program exited with status $ac_status" >&5
20915 echo "$as_me: failed program was:" >&5
20916 sed 's/^/| /' conftest.$ac_ext >&5
20917
20918 ( exit $ac_status )
20919 ol_cv_pthread_mthreads=no
20920 fi
20921 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20922 fi
20923
20924                 # restore the LIBS
20925                 LIBS="$ol_LIBS"
20926
20927 fi
20928 echo "$as_me:$LINENO: result: $ol_cv_pthread_mthreads" >&5
20929 echo "${ECHO_T}$ol_cv_pthread_mthreads" >&6
20930
20931         if test $ol_cv_pthread_mthreads = yes ; then
20932                 ol_link_pthreads="-mthreads"
20933                 ol_link_threads=posix
20934         fi
20935 fi
20936
20937                 # Pthread try link: -thread (ol_cv_pthread_thread)
20938 if test "$ol_link_threads" = no ; then
20939         # try -thread
20940         echo "$as_me:$LINENO: checking for pthread link with -thread" >&5
20941 echo $ECHO_N "checking for pthread link with -thread... $ECHO_C" >&6
20942 if test "${ol_cv_pthread_thread+set}" = set; then
20943   echo $ECHO_N "(cached) $ECHO_C" >&6
20944 else
20945
20946                 # save the flags
20947                 ol_LIBS="$LIBS"
20948                 LIBS="-thread $LIBS"
20949
20950                 if test "$cross_compiling" = yes; then
20951   cat >conftest.$ac_ext <<_ACEOF
20952 /* confdefs.h.  */
20953 _ACEOF
20954 cat confdefs.h >>conftest.$ac_ext
20955 cat >>conftest.$ac_ext <<_ACEOF
20956 /* end confdefs.h.  */
20957
20958 /* pthread test headers */
20959 #include <pthread.h>
20960 #if HAVE_PTHREADS < 7
20961 #include <errno.h>
20962 #endif
20963 #ifndef NULL
20964 #define NULL (void*)0
20965 #endif
20966
20967 static void *task(p)
20968         void *p;
20969 {
20970         return (void *) (p == NULL);
20971 }
20972
20973 int
20974 main ()
20975 {
20976
20977         /* pthread test function */
20978 #ifndef PTHREAD_CREATE_DETACHED
20979 #define PTHREAD_CREATE_DETACHED 1
20980 #endif
20981         pthread_t t;
20982         int status;
20983         int detach = PTHREAD_CREATE_DETACHED;
20984
20985 #if HAVE_PTHREADS > 4
20986         /* Final pthreads */
20987         pthread_attr_t attr;
20988
20989         status = pthread_attr_init(&attr);
20990         if( status ) return status;
20991
20992 #if HAVE_PTHREADS < 7
20993         status = pthread_attr_setdetachstate(&attr, &detach);
20994         if( status < 0 ) status = errno;
20995 #else
20996         status = pthread_attr_setdetachstate(&attr, detach);
20997 #endif
20998         if( status ) return status;
20999         status = pthread_create( &t, &attr, task, NULL );
21000 #if HAVE_PTHREADS < 7
21001         if( status < 0 ) status = errno;
21002 #endif
21003         if( status ) return status;
21004 #else
21005         /* Draft 4 pthreads */
21006         status = pthread_create( &t, pthread_attr_default, task, NULL );
21007         if( status ) return errno;
21008
21009         /* give thread a chance to complete */
21010         /* it should remain joinable and hence detachable */
21011         sleep( 1 );
21012
21013         status = pthread_detach( &t );
21014         if( status ) return errno;
21015 #endif
21016
21017 #ifdef HAVE_LINUX_THREADS
21018         pthread_kill_other_threads_np();
21019 #endif
21020
21021         return 0;
21022
21023   ;
21024   return 0;
21025 }
21026 _ACEOF
21027 rm -f conftest.$ac_objext conftest$ac_exeext
21028 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21029   (eval $ac_link) 2>conftest.er1
21030   ac_status=$?
21031   grep -v '^ *+' conftest.er1 >conftest.err
21032   rm -f conftest.er1
21033   cat conftest.err >&5
21034   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21035   (exit $ac_status); } &&
21036          { ac_try='test -z "$ac_c_werror_flag"
21037                          || test ! -s conftest.err'
21038   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21039   (eval $ac_try) 2>&5
21040   ac_status=$?
21041   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21042   (exit $ac_status); }; } &&
21043          { ac_try='test -s conftest$ac_exeext'
21044   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21045   (eval $ac_try) 2>&5
21046   ac_status=$?
21047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21048   (exit $ac_status); }; }; then
21049   ol_cv_pthread_thread=yes
21050 else
21051   echo "$as_me: failed program was:" >&5
21052 sed 's/^/| /' conftest.$ac_ext >&5
21053
21054 ol_cv_pthread_thread=no
21055 fi
21056 rm -f conftest.err conftest.$ac_objext \
21057       conftest$ac_exeext conftest.$ac_ext
21058 else
21059   cat >conftest.$ac_ext <<_ACEOF
21060 /* confdefs.h.  */
21061 _ACEOF
21062 cat confdefs.h >>conftest.$ac_ext
21063 cat >>conftest.$ac_ext <<_ACEOF
21064 /* end confdefs.h.  */
21065
21066 /* pthread test headers */
21067 #include <pthread.h>
21068 #if HAVE_PTHREADS < 7
21069 #include <errno.h>
21070 #endif
21071 #ifndef NULL
21072 #define NULL (void*)0
21073 #endif
21074
21075 static void *task(p)
21076         void *p;
21077 {
21078         return (void *) (p == NULL);
21079 }
21080
21081
21082 int main(argc, argv)
21083         int argc;
21084         char **argv;
21085 {
21086
21087         /* pthread test function */
21088 #ifndef PTHREAD_CREATE_DETACHED
21089 #define PTHREAD_CREATE_DETACHED 1
21090 #endif
21091         pthread_t t;
21092         int status;
21093         int detach = PTHREAD_CREATE_DETACHED;
21094
21095 #if HAVE_PTHREADS > 4
21096         /* Final pthreads */
21097         pthread_attr_t attr;
21098
21099         status = pthread_attr_init(&attr);
21100         if( status ) return status;
21101
21102 #if HAVE_PTHREADS < 7
21103         status = pthread_attr_setdetachstate(&attr, &detach);
21104         if( status < 0 ) status = errno;
21105 #else
21106         status = pthread_attr_setdetachstate(&attr, detach);
21107 #endif
21108         if( status ) return status;
21109         status = pthread_create( &t, &attr, task, NULL );
21110 #if HAVE_PTHREADS < 7
21111         if( status < 0 ) status = errno;
21112 #endif
21113         if( status ) return status;
21114 #else
21115         /* Draft 4 pthreads */
21116         status = pthread_create( &t, pthread_attr_default, task, NULL );
21117         if( status ) return errno;
21118
21119         /* give thread a chance to complete */
21120         /* it should remain joinable and hence detachable */
21121         sleep( 1 );
21122
21123         status = pthread_detach( &t );
21124         if( status ) return errno;
21125 #endif
21126
21127 #ifdef HAVE_LINUX_THREADS
21128         pthread_kill_other_threads_np();
21129 #endif
21130
21131         return 0;
21132
21133 }
21134
21135 _ACEOF
21136 rm -f conftest$ac_exeext
21137 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21138   (eval $ac_link) 2>&5
21139   ac_status=$?
21140   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21141   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21142   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21143   (eval $ac_try) 2>&5
21144   ac_status=$?
21145   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21146   (exit $ac_status); }; }; then
21147   ol_cv_pthread_thread=yes
21148 else
21149   echo "$as_me: program exited with status $ac_status" >&5
21150 echo "$as_me: failed program was:" >&5
21151 sed 's/^/| /' conftest.$ac_ext >&5
21152
21153 ( exit $ac_status )
21154 ol_cv_pthread_thread=no
21155 fi
21156 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21157 fi
21158
21159                 # restore the LIBS
21160                 LIBS="$ol_LIBS"
21161
21162 fi
21163 echo "$as_me:$LINENO: result: $ol_cv_pthread_thread" >&5
21164 echo "${ECHO_T}$ol_cv_pthread_thread" >&6
21165
21166         if test $ol_cv_pthread_thread = yes ; then
21167                 ol_link_pthreads="-thread"
21168                 ol_link_threads=posix
21169         fi
21170 fi
21171
21172
21173                 # Pthread try link: -lpthread -lmach -lexc -lc_r (ol_cv_pthread_lpthread_lmach_lexc_lc_r)
21174 if test "$ol_link_threads" = no ; then
21175         # try -lpthread -lmach -lexc -lc_r
21176         echo "$as_me:$LINENO: checking for pthread link with -lpthread -lmach -lexc -lc_r" >&5
21177 echo $ECHO_N "checking for pthread link with -lpthread -lmach -lexc -lc_r... $ECHO_C" >&6
21178 if test "${ol_cv_pthread_lpthread_lmach_lexc_lc_r+set}" = set; then
21179   echo $ECHO_N "(cached) $ECHO_C" >&6
21180 else
21181
21182                 # save the flags
21183                 ol_LIBS="$LIBS"
21184                 LIBS="-lpthread -lmach -lexc -lc_r $LIBS"
21185
21186                 if test "$cross_compiling" = yes; then
21187   cat >conftest.$ac_ext <<_ACEOF
21188 /* confdefs.h.  */
21189 _ACEOF
21190 cat confdefs.h >>conftest.$ac_ext
21191 cat >>conftest.$ac_ext <<_ACEOF
21192 /* end confdefs.h.  */
21193
21194 /* pthread test headers */
21195 #include <pthread.h>
21196 #if HAVE_PTHREADS < 7
21197 #include <errno.h>
21198 #endif
21199 #ifndef NULL
21200 #define NULL (void*)0
21201 #endif
21202
21203 static void *task(p)
21204         void *p;
21205 {
21206         return (void *) (p == NULL);
21207 }
21208
21209 int
21210 main ()
21211 {
21212
21213         /* pthread test function */
21214 #ifndef PTHREAD_CREATE_DETACHED
21215 #define PTHREAD_CREATE_DETACHED 1
21216 #endif
21217         pthread_t t;
21218         int status;
21219         int detach = PTHREAD_CREATE_DETACHED;
21220
21221 #if HAVE_PTHREADS > 4
21222         /* Final pthreads */
21223         pthread_attr_t attr;
21224
21225         status = pthread_attr_init(&attr);
21226         if( status ) return status;
21227
21228 #if HAVE_PTHREADS < 7
21229         status = pthread_attr_setdetachstate(&attr, &detach);
21230         if( status < 0 ) status = errno;
21231 #else
21232         status = pthread_attr_setdetachstate(&attr, detach);
21233 #endif
21234         if( status ) return status;
21235         status = pthread_create( &t, &attr, task, NULL );
21236 #if HAVE_PTHREADS < 7
21237         if( status < 0 ) status = errno;
21238 #endif
21239         if( status ) return status;
21240 #else
21241         /* Draft 4 pthreads */
21242         status = pthread_create( &t, pthread_attr_default, task, NULL );
21243         if( status ) return errno;
21244
21245         /* give thread a chance to complete */
21246         /* it should remain joinable and hence detachable */
21247         sleep( 1 );
21248
21249         status = pthread_detach( &t );
21250         if( status ) return errno;
21251 #endif
21252
21253 #ifdef HAVE_LINUX_THREADS
21254         pthread_kill_other_threads_np();
21255 #endif
21256
21257         return 0;
21258
21259   ;
21260   return 0;
21261 }
21262 _ACEOF
21263 rm -f conftest.$ac_objext conftest$ac_exeext
21264 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21265   (eval $ac_link) 2>conftest.er1
21266   ac_status=$?
21267   grep -v '^ *+' conftest.er1 >conftest.err
21268   rm -f conftest.er1
21269   cat conftest.err >&5
21270   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21271   (exit $ac_status); } &&
21272          { ac_try='test -z "$ac_c_werror_flag"
21273                          || test ! -s conftest.err'
21274   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21275   (eval $ac_try) 2>&5
21276   ac_status=$?
21277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21278   (exit $ac_status); }; } &&
21279          { ac_try='test -s conftest$ac_exeext'
21280   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21281   (eval $ac_try) 2>&5
21282   ac_status=$?
21283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21284   (exit $ac_status); }; }; then
21285   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
21286 else
21287   echo "$as_me: failed program was:" >&5
21288 sed 's/^/| /' conftest.$ac_ext >&5
21289
21290 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
21291 fi
21292 rm -f conftest.err conftest.$ac_objext \
21293       conftest$ac_exeext conftest.$ac_ext
21294 else
21295   cat >conftest.$ac_ext <<_ACEOF
21296 /* confdefs.h.  */
21297 _ACEOF
21298 cat confdefs.h >>conftest.$ac_ext
21299 cat >>conftest.$ac_ext <<_ACEOF
21300 /* end confdefs.h.  */
21301
21302 /* pthread test headers */
21303 #include <pthread.h>
21304 #if HAVE_PTHREADS < 7
21305 #include <errno.h>
21306 #endif
21307 #ifndef NULL
21308 #define NULL (void*)0
21309 #endif
21310
21311 static void *task(p)
21312         void *p;
21313 {
21314         return (void *) (p == NULL);
21315 }
21316
21317
21318 int main(argc, argv)
21319         int argc;
21320         char **argv;
21321 {
21322
21323         /* pthread test function */
21324 #ifndef PTHREAD_CREATE_DETACHED
21325 #define PTHREAD_CREATE_DETACHED 1
21326 #endif
21327         pthread_t t;
21328         int status;
21329         int detach = PTHREAD_CREATE_DETACHED;
21330
21331 #if HAVE_PTHREADS > 4
21332         /* Final pthreads */
21333         pthread_attr_t attr;
21334
21335         status = pthread_attr_init(&attr);
21336         if( status ) return status;
21337
21338 #if HAVE_PTHREADS < 7
21339         status = pthread_attr_setdetachstate(&attr, &detach);
21340         if( status < 0 ) status = errno;
21341 #else
21342         status = pthread_attr_setdetachstate(&attr, detach);
21343 #endif
21344         if( status ) return status;
21345         status = pthread_create( &t, &attr, task, NULL );
21346 #if HAVE_PTHREADS < 7
21347         if( status < 0 ) status = errno;
21348 #endif
21349         if( status ) return status;
21350 #else
21351         /* Draft 4 pthreads */
21352         status = pthread_create( &t, pthread_attr_default, task, NULL );
21353         if( status ) return errno;
21354
21355         /* give thread a chance to complete */
21356         /* it should remain joinable and hence detachable */
21357         sleep( 1 );
21358
21359         status = pthread_detach( &t );
21360         if( status ) return errno;
21361 #endif
21362
21363 #ifdef HAVE_LINUX_THREADS
21364         pthread_kill_other_threads_np();
21365 #endif
21366
21367         return 0;
21368
21369 }
21370
21371 _ACEOF
21372 rm -f conftest$ac_exeext
21373 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21374   (eval $ac_link) 2>&5
21375   ac_status=$?
21376   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21377   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21378   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21379   (eval $ac_try) 2>&5
21380   ac_status=$?
21381   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21382   (exit $ac_status); }; }; then
21383   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
21384 else
21385   echo "$as_me: program exited with status $ac_status" >&5
21386 echo "$as_me: failed program was:" >&5
21387 sed 's/^/| /' conftest.$ac_ext >&5
21388
21389 ( exit $ac_status )
21390 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
21391 fi
21392 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21393 fi
21394
21395                 # restore the LIBS
21396                 LIBS="$ol_LIBS"
21397
21398 fi
21399 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&5
21400 echo "${ECHO_T}$ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&6
21401
21402         if test $ol_cv_pthread_lpthread_lmach_lexc_lc_r = yes ; then
21403                 ol_link_pthreads="-lpthread -lmach -lexc -lc_r"
21404                 ol_link_threads=posix
21405         fi
21406 fi
21407
21408                 # Pthread try link: -lpthread -lmach -lexc (ol_cv_pthread_lpthread_lmach_lexc)
21409 if test "$ol_link_threads" = no ; then
21410         # try -lpthread -lmach -lexc
21411         echo "$as_me:$LINENO: checking for pthread link with -lpthread -lmach -lexc" >&5
21412 echo $ECHO_N "checking for pthread link with -lpthread -lmach -lexc... $ECHO_C" >&6
21413 if test "${ol_cv_pthread_lpthread_lmach_lexc+set}" = set; then
21414   echo $ECHO_N "(cached) $ECHO_C" >&6
21415 else
21416
21417                 # save the flags
21418                 ol_LIBS="$LIBS"
21419                 LIBS="-lpthread -lmach -lexc $LIBS"
21420
21421                 if test "$cross_compiling" = yes; then
21422   cat >conftest.$ac_ext <<_ACEOF
21423 /* confdefs.h.  */
21424 _ACEOF
21425 cat confdefs.h >>conftest.$ac_ext
21426 cat >>conftest.$ac_ext <<_ACEOF
21427 /* end confdefs.h.  */
21428
21429 /* pthread test headers */
21430 #include <pthread.h>
21431 #if HAVE_PTHREADS < 7
21432 #include <errno.h>
21433 #endif
21434 #ifndef NULL
21435 #define NULL (void*)0
21436 #endif
21437
21438 static void *task(p)
21439         void *p;
21440 {
21441         return (void *) (p == NULL);
21442 }
21443
21444 int
21445 main ()
21446 {
21447
21448         /* pthread test function */
21449 #ifndef PTHREAD_CREATE_DETACHED
21450 #define PTHREAD_CREATE_DETACHED 1
21451 #endif
21452         pthread_t t;
21453         int status;
21454         int detach = PTHREAD_CREATE_DETACHED;
21455
21456 #if HAVE_PTHREADS > 4
21457         /* Final pthreads */
21458         pthread_attr_t attr;
21459
21460         status = pthread_attr_init(&attr);
21461         if( status ) return status;
21462
21463 #if HAVE_PTHREADS < 7
21464         status = pthread_attr_setdetachstate(&attr, &detach);
21465         if( status < 0 ) status = errno;
21466 #else
21467         status = pthread_attr_setdetachstate(&attr, detach);
21468 #endif
21469         if( status ) return status;
21470         status = pthread_create( &t, &attr, task, NULL );
21471 #if HAVE_PTHREADS < 7
21472         if( status < 0 ) status = errno;
21473 #endif
21474         if( status ) return status;
21475 #else
21476         /* Draft 4 pthreads */
21477         status = pthread_create( &t, pthread_attr_default, task, NULL );
21478         if( status ) return errno;
21479
21480         /* give thread a chance to complete */
21481         /* it should remain joinable and hence detachable */
21482         sleep( 1 );
21483
21484         status = pthread_detach( &t );
21485         if( status ) return errno;
21486 #endif
21487
21488 #ifdef HAVE_LINUX_THREADS
21489         pthread_kill_other_threads_np();
21490 #endif
21491
21492         return 0;
21493
21494   ;
21495   return 0;
21496 }
21497 _ACEOF
21498 rm -f conftest.$ac_objext conftest$ac_exeext
21499 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21500   (eval $ac_link) 2>conftest.er1
21501   ac_status=$?
21502   grep -v '^ *+' conftest.er1 >conftest.err
21503   rm -f conftest.er1
21504   cat conftest.err >&5
21505   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21506   (exit $ac_status); } &&
21507          { ac_try='test -z "$ac_c_werror_flag"
21508                          || test ! -s conftest.err'
21509   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21510   (eval $ac_try) 2>&5
21511   ac_status=$?
21512   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21513   (exit $ac_status); }; } &&
21514          { ac_try='test -s conftest$ac_exeext'
21515   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21516   (eval $ac_try) 2>&5
21517   ac_status=$?
21518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21519   (exit $ac_status); }; }; then
21520   ol_cv_pthread_lpthread_lmach_lexc=yes
21521 else
21522   echo "$as_me: failed program was:" >&5
21523 sed 's/^/| /' conftest.$ac_ext >&5
21524
21525 ol_cv_pthread_lpthread_lmach_lexc=no
21526 fi
21527 rm -f conftest.err conftest.$ac_objext \
21528       conftest$ac_exeext conftest.$ac_ext
21529 else
21530   cat >conftest.$ac_ext <<_ACEOF
21531 /* confdefs.h.  */
21532 _ACEOF
21533 cat confdefs.h >>conftest.$ac_ext
21534 cat >>conftest.$ac_ext <<_ACEOF
21535 /* end confdefs.h.  */
21536
21537 /* pthread test headers */
21538 #include <pthread.h>
21539 #if HAVE_PTHREADS < 7
21540 #include <errno.h>
21541 #endif
21542 #ifndef NULL
21543 #define NULL (void*)0
21544 #endif
21545
21546 static void *task(p)
21547         void *p;
21548 {
21549         return (void *) (p == NULL);
21550 }
21551
21552
21553 int main(argc, argv)
21554         int argc;
21555         char **argv;
21556 {
21557
21558         /* pthread test function */
21559 #ifndef PTHREAD_CREATE_DETACHED
21560 #define PTHREAD_CREATE_DETACHED 1
21561 #endif
21562         pthread_t t;
21563         int status;
21564         int detach = PTHREAD_CREATE_DETACHED;
21565
21566 #if HAVE_PTHREADS > 4
21567         /* Final pthreads */
21568         pthread_attr_t attr;
21569
21570         status = pthread_attr_init(&attr);
21571         if( status ) return status;
21572
21573 #if HAVE_PTHREADS < 7
21574         status = pthread_attr_setdetachstate(&attr, &detach);
21575         if( status < 0 ) status = errno;
21576 #else
21577         status = pthread_attr_setdetachstate(&attr, detach);
21578 #endif
21579         if( status ) return status;
21580         status = pthread_create( &t, &attr, task, NULL );
21581 #if HAVE_PTHREADS < 7
21582         if( status < 0 ) status = errno;
21583 #endif
21584         if( status ) return status;
21585 #else
21586         /* Draft 4 pthreads */
21587         status = pthread_create( &t, pthread_attr_default, task, NULL );
21588         if( status ) return errno;
21589
21590         /* give thread a chance to complete */
21591         /* it should remain joinable and hence detachable */
21592         sleep( 1 );
21593
21594         status = pthread_detach( &t );
21595         if( status ) return errno;
21596 #endif
21597
21598 #ifdef HAVE_LINUX_THREADS
21599         pthread_kill_other_threads_np();
21600 #endif
21601
21602         return 0;
21603
21604 }
21605
21606 _ACEOF
21607 rm -f conftest$ac_exeext
21608 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21609   (eval $ac_link) 2>&5
21610   ac_status=$?
21611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21612   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21613   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21614   (eval $ac_try) 2>&5
21615   ac_status=$?
21616   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21617   (exit $ac_status); }; }; then
21618   ol_cv_pthread_lpthread_lmach_lexc=yes
21619 else
21620   echo "$as_me: program exited with status $ac_status" >&5
21621 echo "$as_me: failed program was:" >&5
21622 sed 's/^/| /' conftest.$ac_ext >&5
21623
21624 ( exit $ac_status )
21625 ol_cv_pthread_lpthread_lmach_lexc=no
21626 fi
21627 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21628 fi
21629
21630                 # restore the LIBS
21631                 LIBS="$ol_LIBS"
21632
21633 fi
21634 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread_lmach_lexc" >&5
21635 echo "${ECHO_T}$ol_cv_pthread_lpthread_lmach_lexc" >&6
21636
21637         if test $ol_cv_pthread_lpthread_lmach_lexc = yes ; then
21638                 ol_link_pthreads="-lpthread -lmach -lexc"
21639                 ol_link_threads=posix
21640         fi
21641 fi
21642
21643
21644                 # Pthread try link: -lpthread -Wl,-woff,85 (ol_cv_pthread_lib_lpthread_woff)
21645 if test "$ol_link_threads" = no ; then
21646         # try -lpthread -Wl,-woff,85
21647         echo "$as_me:$LINENO: checking for pthread link with -lpthread -Wl,-woff,85" >&5
21648 echo $ECHO_N "checking for pthread link with -lpthread -Wl,-woff,85... $ECHO_C" >&6
21649 if test "${ol_cv_pthread_lib_lpthread_woff+set}" = set; then
21650   echo $ECHO_N "(cached) $ECHO_C" >&6
21651 else
21652
21653                 # save the flags
21654                 ol_LIBS="$LIBS"
21655                 LIBS="-lpthread -Wl,-woff,85 $LIBS"
21656
21657                 if test "$cross_compiling" = yes; then
21658   cat >conftest.$ac_ext <<_ACEOF
21659 /* confdefs.h.  */
21660 _ACEOF
21661 cat confdefs.h >>conftest.$ac_ext
21662 cat >>conftest.$ac_ext <<_ACEOF
21663 /* end confdefs.h.  */
21664
21665 /* pthread test headers */
21666 #include <pthread.h>
21667 #if HAVE_PTHREADS < 7
21668 #include <errno.h>
21669 #endif
21670 #ifndef NULL
21671 #define NULL (void*)0
21672 #endif
21673
21674 static void *task(p)
21675         void *p;
21676 {
21677         return (void *) (p == NULL);
21678 }
21679
21680 int
21681 main ()
21682 {
21683
21684         /* pthread test function */
21685 #ifndef PTHREAD_CREATE_DETACHED
21686 #define PTHREAD_CREATE_DETACHED 1
21687 #endif
21688         pthread_t t;
21689         int status;
21690         int detach = PTHREAD_CREATE_DETACHED;
21691
21692 #if HAVE_PTHREADS > 4
21693         /* Final pthreads */
21694         pthread_attr_t attr;
21695
21696         status = pthread_attr_init(&attr);
21697         if( status ) return status;
21698
21699 #if HAVE_PTHREADS < 7
21700         status = pthread_attr_setdetachstate(&attr, &detach);
21701         if( status < 0 ) status = errno;
21702 #else
21703         status = pthread_attr_setdetachstate(&attr, detach);
21704 #endif
21705         if( status ) return status;
21706         status = pthread_create( &t, &attr, task, NULL );
21707 #if HAVE_PTHREADS < 7
21708         if( status < 0 ) status = errno;
21709 #endif
21710         if( status ) return status;
21711 #else
21712         /* Draft 4 pthreads */
21713         status = pthread_create( &t, pthread_attr_default, task, NULL );
21714         if( status ) return errno;
21715
21716         /* give thread a chance to complete */
21717         /* it should remain joinable and hence detachable */
21718         sleep( 1 );
21719
21720         status = pthread_detach( &t );
21721         if( status ) return errno;
21722 #endif
21723
21724 #ifdef HAVE_LINUX_THREADS
21725         pthread_kill_other_threads_np();
21726 #endif
21727
21728         return 0;
21729
21730   ;
21731   return 0;
21732 }
21733 _ACEOF
21734 rm -f conftest.$ac_objext conftest$ac_exeext
21735 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21736   (eval $ac_link) 2>conftest.er1
21737   ac_status=$?
21738   grep -v '^ *+' conftest.er1 >conftest.err
21739   rm -f conftest.er1
21740   cat conftest.err >&5
21741   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21742   (exit $ac_status); } &&
21743          { ac_try='test -z "$ac_c_werror_flag"
21744                          || test ! -s conftest.err'
21745   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21746   (eval $ac_try) 2>&5
21747   ac_status=$?
21748   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21749   (exit $ac_status); }; } &&
21750          { ac_try='test -s conftest$ac_exeext'
21751   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21752   (eval $ac_try) 2>&5
21753   ac_status=$?
21754   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21755   (exit $ac_status); }; }; then
21756   ol_cv_pthread_lib_lpthread_woff=yes
21757 else
21758   echo "$as_me: failed program was:" >&5
21759 sed 's/^/| /' conftest.$ac_ext >&5
21760
21761 ol_cv_pthread_lib_lpthread_woff=no
21762 fi
21763 rm -f conftest.err conftest.$ac_objext \
21764       conftest$ac_exeext conftest.$ac_ext
21765 else
21766   cat >conftest.$ac_ext <<_ACEOF
21767 /* confdefs.h.  */
21768 _ACEOF
21769 cat confdefs.h >>conftest.$ac_ext
21770 cat >>conftest.$ac_ext <<_ACEOF
21771 /* end confdefs.h.  */
21772
21773 /* pthread test headers */
21774 #include <pthread.h>
21775 #if HAVE_PTHREADS < 7
21776 #include <errno.h>
21777 #endif
21778 #ifndef NULL
21779 #define NULL (void*)0
21780 #endif
21781
21782 static void *task(p)
21783         void *p;
21784 {
21785         return (void *) (p == NULL);
21786 }
21787
21788
21789 int main(argc, argv)
21790         int argc;
21791         char **argv;
21792 {
21793
21794         /* pthread test function */
21795 #ifndef PTHREAD_CREATE_DETACHED
21796 #define PTHREAD_CREATE_DETACHED 1
21797 #endif
21798         pthread_t t;
21799         int status;
21800         int detach = PTHREAD_CREATE_DETACHED;
21801
21802 #if HAVE_PTHREADS > 4
21803         /* Final pthreads */
21804         pthread_attr_t attr;
21805
21806         status = pthread_attr_init(&attr);
21807         if( status ) return status;
21808
21809 #if HAVE_PTHREADS < 7
21810         status = pthread_attr_setdetachstate(&attr, &detach);
21811         if( status < 0 ) status = errno;
21812 #else
21813         status = pthread_attr_setdetachstate(&attr, detach);
21814 #endif
21815         if( status ) return status;
21816         status = pthread_create( &t, &attr, task, NULL );
21817 #if HAVE_PTHREADS < 7
21818         if( status < 0 ) status = errno;
21819 #endif
21820         if( status ) return status;
21821 #else
21822         /* Draft 4 pthreads */
21823         status = pthread_create( &t, pthread_attr_default, task, NULL );
21824         if( status ) return errno;
21825
21826         /* give thread a chance to complete */
21827         /* it should remain joinable and hence detachable */
21828         sleep( 1 );
21829
21830         status = pthread_detach( &t );
21831         if( status ) return errno;
21832 #endif
21833
21834 #ifdef HAVE_LINUX_THREADS
21835         pthread_kill_other_threads_np();
21836 #endif
21837
21838         return 0;
21839
21840 }
21841
21842 _ACEOF
21843 rm -f conftest$ac_exeext
21844 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21845   (eval $ac_link) 2>&5
21846   ac_status=$?
21847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21848   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21849   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21850   (eval $ac_try) 2>&5
21851   ac_status=$?
21852   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21853   (exit $ac_status); }; }; then
21854   ol_cv_pthread_lib_lpthread_woff=yes
21855 else
21856   echo "$as_me: program exited with status $ac_status" >&5
21857 echo "$as_me: failed program was:" >&5
21858 sed 's/^/| /' conftest.$ac_ext >&5
21859
21860 ( exit $ac_status )
21861 ol_cv_pthread_lib_lpthread_woff=no
21862 fi
21863 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21864 fi
21865
21866                 # restore the LIBS
21867                 LIBS="$ol_LIBS"
21868
21869 fi
21870 echo "$as_me:$LINENO: result: $ol_cv_pthread_lib_lpthread_woff" >&5
21871 echo "${ECHO_T}$ol_cv_pthread_lib_lpthread_woff" >&6
21872
21873         if test $ol_cv_pthread_lib_lpthread_woff = yes ; then
21874                 ol_link_pthreads="-lpthread -Wl,-woff,85"
21875                 ol_link_threads=posix
21876         fi
21877 fi
21878
21879
21880                 # Pthread try link: -lpthread (ol_cv_pthread_lpthread)
21881 if test "$ol_link_threads" = no ; then
21882         # try -lpthread
21883         echo "$as_me:$LINENO: checking for pthread link with -lpthread" >&5
21884 echo $ECHO_N "checking for pthread link with -lpthread... $ECHO_C" >&6
21885 if test "${ol_cv_pthread_lpthread+set}" = set; then
21886   echo $ECHO_N "(cached) $ECHO_C" >&6
21887 else
21888
21889                 # save the flags
21890                 ol_LIBS="$LIBS"
21891                 LIBS="-lpthread $LIBS"
21892
21893                 if test "$cross_compiling" = yes; then
21894   cat >conftest.$ac_ext <<_ACEOF
21895 /* confdefs.h.  */
21896 _ACEOF
21897 cat confdefs.h >>conftest.$ac_ext
21898 cat >>conftest.$ac_ext <<_ACEOF
21899 /* end confdefs.h.  */
21900
21901 /* pthread test headers */
21902 #include <pthread.h>
21903 #if HAVE_PTHREADS < 7
21904 #include <errno.h>
21905 #endif
21906 #ifndef NULL
21907 #define NULL (void*)0
21908 #endif
21909
21910 static void *task(p)
21911         void *p;
21912 {
21913         return (void *) (p == NULL);
21914 }
21915
21916 int
21917 main ()
21918 {
21919
21920         /* pthread test function */
21921 #ifndef PTHREAD_CREATE_DETACHED
21922 #define PTHREAD_CREATE_DETACHED 1
21923 #endif
21924         pthread_t t;
21925         int status;
21926         int detach = PTHREAD_CREATE_DETACHED;
21927
21928 #if HAVE_PTHREADS > 4
21929         /* Final pthreads */
21930         pthread_attr_t attr;
21931
21932         status = pthread_attr_init(&attr);
21933         if( status ) return status;
21934
21935 #if HAVE_PTHREADS < 7
21936         status = pthread_attr_setdetachstate(&attr, &detach);
21937         if( status < 0 ) status = errno;
21938 #else
21939         status = pthread_attr_setdetachstate(&attr, detach);
21940 #endif
21941         if( status ) return status;
21942         status = pthread_create( &t, &attr, task, NULL );
21943 #if HAVE_PTHREADS < 7
21944         if( status < 0 ) status = errno;
21945 #endif
21946         if( status ) return status;
21947 #else
21948         /* Draft 4 pthreads */
21949         status = pthread_create( &t, pthread_attr_default, task, NULL );
21950         if( status ) return errno;
21951
21952         /* give thread a chance to complete */
21953         /* it should remain joinable and hence detachable */
21954         sleep( 1 );
21955
21956         status = pthread_detach( &t );
21957         if( status ) return errno;
21958 #endif
21959
21960 #ifdef HAVE_LINUX_THREADS
21961         pthread_kill_other_threads_np();
21962 #endif
21963
21964         return 0;
21965
21966   ;
21967   return 0;
21968 }
21969 _ACEOF
21970 rm -f conftest.$ac_objext conftest$ac_exeext
21971 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21972   (eval $ac_link) 2>conftest.er1
21973   ac_status=$?
21974   grep -v '^ *+' conftest.er1 >conftest.err
21975   rm -f conftest.er1
21976   cat conftest.err >&5
21977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21978   (exit $ac_status); } &&
21979          { ac_try='test -z "$ac_c_werror_flag"
21980                          || test ! -s conftest.err'
21981   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21982   (eval $ac_try) 2>&5
21983   ac_status=$?
21984   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21985   (exit $ac_status); }; } &&
21986          { ac_try='test -s conftest$ac_exeext'
21987   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21988   (eval $ac_try) 2>&5
21989   ac_status=$?
21990   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21991   (exit $ac_status); }; }; then
21992   ol_cv_pthread_lpthread=yes
21993 else
21994   echo "$as_me: failed program was:" >&5
21995 sed 's/^/| /' conftest.$ac_ext >&5
21996
21997 ol_cv_pthread_lpthread=no
21998 fi
21999 rm -f conftest.err conftest.$ac_objext \
22000       conftest$ac_exeext conftest.$ac_ext
22001 else
22002   cat >conftest.$ac_ext <<_ACEOF
22003 /* confdefs.h.  */
22004 _ACEOF
22005 cat confdefs.h >>conftest.$ac_ext
22006 cat >>conftest.$ac_ext <<_ACEOF
22007 /* end confdefs.h.  */
22008
22009 /* pthread test headers */
22010 #include <pthread.h>
22011 #if HAVE_PTHREADS < 7
22012 #include <errno.h>
22013 #endif
22014 #ifndef NULL
22015 #define NULL (void*)0
22016 #endif
22017
22018 static void *task(p)
22019         void *p;
22020 {
22021         return (void *) (p == NULL);
22022 }
22023
22024
22025 int main(argc, argv)
22026         int argc;
22027         char **argv;
22028 {
22029
22030         /* pthread test function */
22031 #ifndef PTHREAD_CREATE_DETACHED
22032 #define PTHREAD_CREATE_DETACHED 1
22033 #endif
22034         pthread_t t;
22035         int status;
22036         int detach = PTHREAD_CREATE_DETACHED;
22037
22038 #if HAVE_PTHREADS > 4
22039         /* Final pthreads */
22040         pthread_attr_t attr;
22041
22042         status = pthread_attr_init(&attr);
22043         if( status ) return status;
22044
22045 #if HAVE_PTHREADS < 7
22046         status = pthread_attr_setdetachstate(&attr, &detach);
22047         if( status < 0 ) status = errno;
22048 #else
22049         status = pthread_attr_setdetachstate(&attr, detach);
22050 #endif
22051         if( status ) return status;
22052         status = pthread_create( &t, &attr, task, NULL );
22053 #if HAVE_PTHREADS < 7
22054         if( status < 0 ) status = errno;
22055 #endif
22056         if( status ) return status;
22057 #else
22058         /* Draft 4 pthreads */
22059         status = pthread_create( &t, pthread_attr_default, task, NULL );
22060         if( status ) return errno;
22061
22062         /* give thread a chance to complete */
22063         /* it should remain joinable and hence detachable */
22064         sleep( 1 );
22065
22066         status = pthread_detach( &t );
22067         if( status ) return errno;
22068 #endif
22069
22070 #ifdef HAVE_LINUX_THREADS
22071         pthread_kill_other_threads_np();
22072 #endif
22073
22074         return 0;
22075
22076 }
22077
22078 _ACEOF
22079 rm -f conftest$ac_exeext
22080 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22081   (eval $ac_link) 2>&5
22082   ac_status=$?
22083   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22084   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22085   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22086   (eval $ac_try) 2>&5
22087   ac_status=$?
22088   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22089   (exit $ac_status); }; }; then
22090   ol_cv_pthread_lpthread=yes
22091 else
22092   echo "$as_me: program exited with status $ac_status" >&5
22093 echo "$as_me: failed program was:" >&5
22094 sed 's/^/| /' conftest.$ac_ext >&5
22095
22096 ( exit $ac_status )
22097 ol_cv_pthread_lpthread=no
22098 fi
22099 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22100 fi
22101
22102                 # restore the LIBS
22103                 LIBS="$ol_LIBS"
22104
22105 fi
22106 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread" >&5
22107 echo "${ECHO_T}$ol_cv_pthread_lpthread" >&6
22108
22109         if test $ol_cv_pthread_lpthread = yes ; then
22110                 ol_link_pthreads="-lpthread"
22111                 ol_link_threads=posix
22112         fi
22113 fi
22114
22115                 # Pthread try link: -lc_r (ol_cv_pthread_lc_r)
22116 if test "$ol_link_threads" = no ; then
22117         # try -lc_r
22118         echo "$as_me:$LINENO: checking for pthread link with -lc_r" >&5
22119 echo $ECHO_N "checking for pthread link with -lc_r... $ECHO_C" >&6
22120 if test "${ol_cv_pthread_lc_r+set}" = set; then
22121   echo $ECHO_N "(cached) $ECHO_C" >&6
22122 else
22123
22124                 # save the flags
22125                 ol_LIBS="$LIBS"
22126                 LIBS="-lc_r $LIBS"
22127
22128                 if test "$cross_compiling" = yes; then
22129   cat >conftest.$ac_ext <<_ACEOF
22130 /* confdefs.h.  */
22131 _ACEOF
22132 cat confdefs.h >>conftest.$ac_ext
22133 cat >>conftest.$ac_ext <<_ACEOF
22134 /* end confdefs.h.  */
22135
22136 /* pthread test headers */
22137 #include <pthread.h>
22138 #if HAVE_PTHREADS < 7
22139 #include <errno.h>
22140 #endif
22141 #ifndef NULL
22142 #define NULL (void*)0
22143 #endif
22144
22145 static void *task(p)
22146         void *p;
22147 {
22148         return (void *) (p == NULL);
22149 }
22150
22151 int
22152 main ()
22153 {
22154
22155         /* pthread test function */
22156 #ifndef PTHREAD_CREATE_DETACHED
22157 #define PTHREAD_CREATE_DETACHED 1
22158 #endif
22159         pthread_t t;
22160         int status;
22161         int detach = PTHREAD_CREATE_DETACHED;
22162
22163 #if HAVE_PTHREADS > 4
22164         /* Final pthreads */
22165         pthread_attr_t attr;
22166
22167         status = pthread_attr_init(&attr);
22168         if( status ) return status;
22169
22170 #if HAVE_PTHREADS < 7
22171         status = pthread_attr_setdetachstate(&attr, &detach);
22172         if( status < 0 ) status = errno;
22173 #else
22174         status = pthread_attr_setdetachstate(&attr, detach);
22175 #endif
22176         if( status ) return status;
22177         status = pthread_create( &t, &attr, task, NULL );
22178 #if HAVE_PTHREADS < 7
22179         if( status < 0 ) status = errno;
22180 #endif
22181         if( status ) return status;
22182 #else
22183         /* Draft 4 pthreads */
22184         status = pthread_create( &t, pthread_attr_default, task, NULL );
22185         if( status ) return errno;
22186
22187         /* give thread a chance to complete */
22188         /* it should remain joinable and hence detachable */
22189         sleep( 1 );
22190
22191         status = pthread_detach( &t );
22192         if( status ) return errno;
22193 #endif
22194
22195 #ifdef HAVE_LINUX_THREADS
22196         pthread_kill_other_threads_np();
22197 #endif
22198
22199         return 0;
22200
22201   ;
22202   return 0;
22203 }
22204 _ACEOF
22205 rm -f conftest.$ac_objext conftest$ac_exeext
22206 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22207   (eval $ac_link) 2>conftest.er1
22208   ac_status=$?
22209   grep -v '^ *+' conftest.er1 >conftest.err
22210   rm -f conftest.er1
22211   cat conftest.err >&5
22212   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22213   (exit $ac_status); } &&
22214          { ac_try='test -z "$ac_c_werror_flag"
22215                          || test ! -s conftest.err'
22216   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22217   (eval $ac_try) 2>&5
22218   ac_status=$?
22219   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22220   (exit $ac_status); }; } &&
22221          { ac_try='test -s conftest$ac_exeext'
22222   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22223   (eval $ac_try) 2>&5
22224   ac_status=$?
22225   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22226   (exit $ac_status); }; }; then
22227   ol_cv_pthread_lc_r=yes
22228 else
22229   echo "$as_me: failed program was:" >&5
22230 sed 's/^/| /' conftest.$ac_ext >&5
22231
22232 ol_cv_pthread_lc_r=no
22233 fi
22234 rm -f conftest.err conftest.$ac_objext \
22235       conftest$ac_exeext conftest.$ac_ext
22236 else
22237   cat >conftest.$ac_ext <<_ACEOF
22238 /* confdefs.h.  */
22239 _ACEOF
22240 cat confdefs.h >>conftest.$ac_ext
22241 cat >>conftest.$ac_ext <<_ACEOF
22242 /* end confdefs.h.  */
22243
22244 /* pthread test headers */
22245 #include <pthread.h>
22246 #if HAVE_PTHREADS < 7
22247 #include <errno.h>
22248 #endif
22249 #ifndef NULL
22250 #define NULL (void*)0
22251 #endif
22252
22253 static void *task(p)
22254         void *p;
22255 {
22256         return (void *) (p == NULL);
22257 }
22258
22259
22260 int main(argc, argv)
22261         int argc;
22262         char **argv;
22263 {
22264
22265         /* pthread test function */
22266 #ifndef PTHREAD_CREATE_DETACHED
22267 #define PTHREAD_CREATE_DETACHED 1
22268 #endif
22269         pthread_t t;
22270         int status;
22271         int detach = PTHREAD_CREATE_DETACHED;
22272
22273 #if HAVE_PTHREADS > 4
22274         /* Final pthreads */
22275         pthread_attr_t attr;
22276
22277         status = pthread_attr_init(&attr);
22278         if( status ) return status;
22279
22280 #if HAVE_PTHREADS < 7
22281         status = pthread_attr_setdetachstate(&attr, &detach);
22282         if( status < 0 ) status = errno;
22283 #else
22284         status = pthread_attr_setdetachstate(&attr, detach);
22285 #endif
22286         if( status ) return status;
22287         status = pthread_create( &t, &attr, task, NULL );
22288 #if HAVE_PTHREADS < 7
22289         if( status < 0 ) status = errno;
22290 #endif
22291         if( status ) return status;
22292 #else
22293         /* Draft 4 pthreads */
22294         status = pthread_create( &t, pthread_attr_default, task, NULL );
22295         if( status ) return errno;
22296
22297         /* give thread a chance to complete */
22298         /* it should remain joinable and hence detachable */
22299         sleep( 1 );
22300
22301         status = pthread_detach( &t );
22302         if( status ) return errno;
22303 #endif
22304
22305 #ifdef HAVE_LINUX_THREADS
22306         pthread_kill_other_threads_np();
22307 #endif
22308
22309         return 0;
22310
22311 }
22312
22313 _ACEOF
22314 rm -f conftest$ac_exeext
22315 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22316   (eval $ac_link) 2>&5
22317   ac_status=$?
22318   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22319   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22320   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22321   (eval $ac_try) 2>&5
22322   ac_status=$?
22323   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22324   (exit $ac_status); }; }; then
22325   ol_cv_pthread_lc_r=yes
22326 else
22327   echo "$as_me: program exited with status $ac_status" >&5
22328 echo "$as_me: failed program was:" >&5
22329 sed 's/^/| /' conftest.$ac_ext >&5
22330
22331 ( exit $ac_status )
22332 ol_cv_pthread_lc_r=no
22333 fi
22334 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22335 fi
22336
22337                 # restore the LIBS
22338                 LIBS="$ol_LIBS"
22339
22340 fi
22341 echo "$as_me:$LINENO: result: $ol_cv_pthread_lc_r" >&5
22342 echo "${ECHO_T}$ol_cv_pthread_lc_r" >&6
22343
22344         if test $ol_cv_pthread_lc_r = yes ; then
22345                 ol_link_pthreads="-lc_r"
22346                 ol_link_threads=posix
22347         fi
22348 fi
22349
22350
22351                 # Pthread try link: -threads (ol_cv_pthread_threads)
22352 if test "$ol_link_threads" = no ; then
22353         # try -threads
22354         echo "$as_me:$LINENO: checking for pthread link with -threads" >&5
22355 echo $ECHO_N "checking for pthread link with -threads... $ECHO_C" >&6
22356 if test "${ol_cv_pthread_threads+set}" = set; then
22357   echo $ECHO_N "(cached) $ECHO_C" >&6
22358 else
22359
22360                 # save the flags
22361                 ol_LIBS="$LIBS"
22362                 LIBS="-threads $LIBS"
22363
22364                 if test "$cross_compiling" = yes; then
22365   cat >conftest.$ac_ext <<_ACEOF
22366 /* confdefs.h.  */
22367 _ACEOF
22368 cat confdefs.h >>conftest.$ac_ext
22369 cat >>conftest.$ac_ext <<_ACEOF
22370 /* end confdefs.h.  */
22371
22372 /* pthread test headers */
22373 #include <pthread.h>
22374 #if HAVE_PTHREADS < 7
22375 #include <errno.h>
22376 #endif
22377 #ifndef NULL
22378 #define NULL (void*)0
22379 #endif
22380
22381 static void *task(p)
22382         void *p;
22383 {
22384         return (void *) (p == NULL);
22385 }
22386
22387 int
22388 main ()
22389 {
22390
22391         /* pthread test function */
22392 #ifndef PTHREAD_CREATE_DETACHED
22393 #define PTHREAD_CREATE_DETACHED 1
22394 #endif
22395         pthread_t t;
22396         int status;
22397         int detach = PTHREAD_CREATE_DETACHED;
22398
22399 #if HAVE_PTHREADS > 4
22400         /* Final pthreads */
22401         pthread_attr_t attr;
22402
22403         status = pthread_attr_init(&attr);
22404         if( status ) return status;
22405
22406 #if HAVE_PTHREADS < 7
22407         status = pthread_attr_setdetachstate(&attr, &detach);
22408         if( status < 0 ) status = errno;
22409 #else
22410         status = pthread_attr_setdetachstate(&attr, detach);
22411 #endif
22412         if( status ) return status;
22413         status = pthread_create( &t, &attr, task, NULL );
22414 #if HAVE_PTHREADS < 7
22415         if( status < 0 ) status = errno;
22416 #endif
22417         if( status ) return status;
22418 #else
22419         /* Draft 4 pthreads */
22420         status = pthread_create( &t, pthread_attr_default, task, NULL );
22421         if( status ) return errno;
22422
22423         /* give thread a chance to complete */
22424         /* it should remain joinable and hence detachable */
22425         sleep( 1 );
22426
22427         status = pthread_detach( &t );
22428         if( status ) return errno;
22429 #endif
22430
22431 #ifdef HAVE_LINUX_THREADS
22432         pthread_kill_other_threads_np();
22433 #endif
22434
22435         return 0;
22436
22437   ;
22438   return 0;
22439 }
22440 _ACEOF
22441 rm -f conftest.$ac_objext conftest$ac_exeext
22442 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22443   (eval $ac_link) 2>conftest.er1
22444   ac_status=$?
22445   grep -v '^ *+' conftest.er1 >conftest.err
22446   rm -f conftest.er1
22447   cat conftest.err >&5
22448   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22449   (exit $ac_status); } &&
22450          { ac_try='test -z "$ac_c_werror_flag"
22451                          || test ! -s conftest.err'
22452   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22453   (eval $ac_try) 2>&5
22454   ac_status=$?
22455   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22456   (exit $ac_status); }; } &&
22457          { ac_try='test -s conftest$ac_exeext'
22458   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22459   (eval $ac_try) 2>&5
22460   ac_status=$?
22461   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22462   (exit $ac_status); }; }; then
22463   ol_cv_pthread_threads=yes
22464 else
22465   echo "$as_me: failed program was:" >&5
22466 sed 's/^/| /' conftest.$ac_ext >&5
22467
22468 ol_cv_pthread_threads=no
22469 fi
22470 rm -f conftest.err conftest.$ac_objext \
22471       conftest$ac_exeext conftest.$ac_ext
22472 else
22473   cat >conftest.$ac_ext <<_ACEOF
22474 /* confdefs.h.  */
22475 _ACEOF
22476 cat confdefs.h >>conftest.$ac_ext
22477 cat >>conftest.$ac_ext <<_ACEOF
22478 /* end confdefs.h.  */
22479
22480 /* pthread test headers */
22481 #include <pthread.h>
22482 #if HAVE_PTHREADS < 7
22483 #include <errno.h>
22484 #endif
22485 #ifndef NULL
22486 #define NULL (void*)0
22487 #endif
22488
22489 static void *task(p)
22490         void *p;
22491 {
22492         return (void *) (p == NULL);
22493 }
22494
22495
22496 int main(argc, argv)
22497         int argc;
22498         char **argv;
22499 {
22500
22501         /* pthread test function */
22502 #ifndef PTHREAD_CREATE_DETACHED
22503 #define PTHREAD_CREATE_DETACHED 1
22504 #endif
22505         pthread_t t;
22506         int status;
22507         int detach = PTHREAD_CREATE_DETACHED;
22508
22509 #if HAVE_PTHREADS > 4
22510         /* Final pthreads */
22511         pthread_attr_t attr;
22512
22513         status = pthread_attr_init(&attr);
22514         if( status ) return status;
22515
22516 #if HAVE_PTHREADS < 7
22517         status = pthread_attr_setdetachstate(&attr, &detach);
22518         if( status < 0 ) status = errno;
22519 #else
22520         status = pthread_attr_setdetachstate(&attr, detach);
22521 #endif
22522         if( status ) return status;
22523         status = pthread_create( &t, &attr, task, NULL );
22524 #if HAVE_PTHREADS < 7
22525         if( status < 0 ) status = errno;
22526 #endif
22527         if( status ) return status;
22528 #else
22529         /* Draft 4 pthreads */
22530         status = pthread_create( &t, pthread_attr_default, task, NULL );
22531         if( status ) return errno;
22532
22533         /* give thread a chance to complete */
22534         /* it should remain joinable and hence detachable */
22535         sleep( 1 );
22536
22537         status = pthread_detach( &t );
22538         if( status ) return errno;
22539 #endif
22540
22541 #ifdef HAVE_LINUX_THREADS
22542         pthread_kill_other_threads_np();
22543 #endif
22544
22545         return 0;
22546
22547 }
22548
22549 _ACEOF
22550 rm -f conftest$ac_exeext
22551 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22552   (eval $ac_link) 2>&5
22553   ac_status=$?
22554   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22555   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22556   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22557   (eval $ac_try) 2>&5
22558   ac_status=$?
22559   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22560   (exit $ac_status); }; }; then
22561   ol_cv_pthread_threads=yes
22562 else
22563   echo "$as_me: program exited with status $ac_status" >&5
22564 echo "$as_me: failed program was:" >&5
22565 sed 's/^/| /' conftest.$ac_ext >&5
22566
22567 ( exit $ac_status )
22568 ol_cv_pthread_threads=no
22569 fi
22570 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22571 fi
22572
22573                 # restore the LIBS
22574                 LIBS="$ol_LIBS"
22575
22576 fi
22577 echo "$as_me:$LINENO: result: $ol_cv_pthread_threads" >&5
22578 echo "${ECHO_T}$ol_cv_pthread_threads" >&6
22579
22580         if test $ol_cv_pthread_threads = yes ; then
22581                 ol_link_pthreads="-threads"
22582                 ol_link_threads=posix
22583         fi
22584 fi
22585
22586
22587                 # Pthread try link: -lpthreads -lmach -lexc -lc_r (ol_cv_pthread_lpthreads_lmach_lexc_lc_r)
22588 if test "$ol_link_threads" = no ; then
22589         # try -lpthreads -lmach -lexc -lc_r
22590         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lmach -lexc -lc_r" >&5
22591 echo $ECHO_N "checking for pthread link with -lpthreads -lmach -lexc -lc_r... $ECHO_C" >&6
22592 if test "${ol_cv_pthread_lpthreads_lmach_lexc_lc_r+set}" = set; then
22593   echo $ECHO_N "(cached) $ECHO_C" >&6
22594 else
22595
22596                 # save the flags
22597                 ol_LIBS="$LIBS"
22598                 LIBS="-lpthreads -lmach -lexc -lc_r $LIBS"
22599
22600                 if test "$cross_compiling" = yes; then
22601   cat >conftest.$ac_ext <<_ACEOF
22602 /* confdefs.h.  */
22603 _ACEOF
22604 cat confdefs.h >>conftest.$ac_ext
22605 cat >>conftest.$ac_ext <<_ACEOF
22606 /* end confdefs.h.  */
22607
22608 /* pthread test headers */
22609 #include <pthread.h>
22610 #if HAVE_PTHREADS < 7
22611 #include <errno.h>
22612 #endif
22613 #ifndef NULL
22614 #define NULL (void*)0
22615 #endif
22616
22617 static void *task(p)
22618         void *p;
22619 {
22620         return (void *) (p == NULL);
22621 }
22622
22623 int
22624 main ()
22625 {
22626
22627         /* pthread test function */
22628 #ifndef PTHREAD_CREATE_DETACHED
22629 #define PTHREAD_CREATE_DETACHED 1
22630 #endif
22631         pthread_t t;
22632         int status;
22633         int detach = PTHREAD_CREATE_DETACHED;
22634
22635 #if HAVE_PTHREADS > 4
22636         /* Final pthreads */
22637         pthread_attr_t attr;
22638
22639         status = pthread_attr_init(&attr);
22640         if( status ) return status;
22641
22642 #if HAVE_PTHREADS < 7
22643         status = pthread_attr_setdetachstate(&attr, &detach);
22644         if( status < 0 ) status = errno;
22645 #else
22646         status = pthread_attr_setdetachstate(&attr, detach);
22647 #endif
22648         if( status ) return status;
22649         status = pthread_create( &t, &attr, task, NULL );
22650 #if HAVE_PTHREADS < 7
22651         if( status < 0 ) status = errno;
22652 #endif
22653         if( status ) return status;
22654 #else
22655         /* Draft 4 pthreads */
22656         status = pthread_create( &t, pthread_attr_default, task, NULL );
22657         if( status ) return errno;
22658
22659         /* give thread a chance to complete */
22660         /* it should remain joinable and hence detachable */
22661         sleep( 1 );
22662
22663         status = pthread_detach( &t );
22664         if( status ) return errno;
22665 #endif
22666
22667 #ifdef HAVE_LINUX_THREADS
22668         pthread_kill_other_threads_np();
22669 #endif
22670
22671         return 0;
22672
22673   ;
22674   return 0;
22675 }
22676 _ACEOF
22677 rm -f conftest.$ac_objext conftest$ac_exeext
22678 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22679   (eval $ac_link) 2>conftest.er1
22680   ac_status=$?
22681   grep -v '^ *+' conftest.er1 >conftest.err
22682   rm -f conftest.er1
22683   cat conftest.err >&5
22684   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22685   (exit $ac_status); } &&
22686          { ac_try='test -z "$ac_c_werror_flag"
22687                          || test ! -s conftest.err'
22688   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22689   (eval $ac_try) 2>&5
22690   ac_status=$?
22691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22692   (exit $ac_status); }; } &&
22693          { ac_try='test -s conftest$ac_exeext'
22694   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22695   (eval $ac_try) 2>&5
22696   ac_status=$?
22697   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22698   (exit $ac_status); }; }; then
22699   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
22700 else
22701   echo "$as_me: failed program was:" >&5
22702 sed 's/^/| /' conftest.$ac_ext >&5
22703
22704 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
22705 fi
22706 rm -f conftest.err conftest.$ac_objext \
22707       conftest$ac_exeext conftest.$ac_ext
22708 else
22709   cat >conftest.$ac_ext <<_ACEOF
22710 /* confdefs.h.  */
22711 _ACEOF
22712 cat confdefs.h >>conftest.$ac_ext
22713 cat >>conftest.$ac_ext <<_ACEOF
22714 /* end confdefs.h.  */
22715
22716 /* pthread test headers */
22717 #include <pthread.h>
22718 #if HAVE_PTHREADS < 7
22719 #include <errno.h>
22720 #endif
22721 #ifndef NULL
22722 #define NULL (void*)0
22723 #endif
22724
22725 static void *task(p)
22726         void *p;
22727 {
22728         return (void *) (p == NULL);
22729 }
22730
22731
22732 int main(argc, argv)
22733         int argc;
22734         char **argv;
22735 {
22736
22737         /* pthread test function */
22738 #ifndef PTHREAD_CREATE_DETACHED
22739 #define PTHREAD_CREATE_DETACHED 1
22740 #endif
22741         pthread_t t;
22742         int status;
22743         int detach = PTHREAD_CREATE_DETACHED;
22744
22745 #if HAVE_PTHREADS > 4
22746         /* Final pthreads */
22747         pthread_attr_t attr;
22748
22749         status = pthread_attr_init(&attr);
22750         if( status ) return status;
22751
22752 #if HAVE_PTHREADS < 7
22753         status = pthread_attr_setdetachstate(&attr, &detach);
22754         if( status < 0 ) status = errno;
22755 #else
22756         status = pthread_attr_setdetachstate(&attr, detach);
22757 #endif
22758         if( status ) return status;
22759         status = pthread_create( &t, &attr, task, NULL );
22760 #if HAVE_PTHREADS < 7
22761         if( status < 0 ) status = errno;
22762 #endif
22763         if( status ) return status;
22764 #else
22765         /* Draft 4 pthreads */
22766         status = pthread_create( &t, pthread_attr_default, task, NULL );
22767         if( status ) return errno;
22768
22769         /* give thread a chance to complete */
22770         /* it should remain joinable and hence detachable */
22771         sleep( 1 );
22772
22773         status = pthread_detach( &t );
22774         if( status ) return errno;
22775 #endif
22776
22777 #ifdef HAVE_LINUX_THREADS
22778         pthread_kill_other_threads_np();
22779 #endif
22780
22781         return 0;
22782
22783 }
22784
22785 _ACEOF
22786 rm -f conftest$ac_exeext
22787 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22788   (eval $ac_link) 2>&5
22789   ac_status=$?
22790   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22791   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22792   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22793   (eval $ac_try) 2>&5
22794   ac_status=$?
22795   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22796   (exit $ac_status); }; }; then
22797   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
22798 else
22799   echo "$as_me: program exited with status $ac_status" >&5
22800 echo "$as_me: failed program was:" >&5
22801 sed 's/^/| /' conftest.$ac_ext >&5
22802
22803 ( exit $ac_status )
22804 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
22805 fi
22806 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22807 fi
22808
22809                 # restore the LIBS
22810                 LIBS="$ol_LIBS"
22811
22812 fi
22813 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&5
22814 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&6
22815
22816         if test $ol_cv_pthread_lpthreads_lmach_lexc_lc_r = yes ; then
22817                 ol_link_pthreads="-lpthreads -lmach -lexc -lc_r"
22818                 ol_link_threads=posix
22819         fi
22820 fi
22821
22822                 # Pthread try link: -lpthreads -lmach -lexc (ol_cv_pthread_lpthreads_lmach_lexc)
22823 if test "$ol_link_threads" = no ; then
22824         # try -lpthreads -lmach -lexc
22825         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lmach -lexc" >&5
22826 echo $ECHO_N "checking for pthread link with -lpthreads -lmach -lexc... $ECHO_C" >&6
22827 if test "${ol_cv_pthread_lpthreads_lmach_lexc+set}" = set; then
22828   echo $ECHO_N "(cached) $ECHO_C" >&6
22829 else
22830
22831                 # save the flags
22832                 ol_LIBS="$LIBS"
22833                 LIBS="-lpthreads -lmach -lexc $LIBS"
22834
22835                 if test "$cross_compiling" = yes; then
22836   cat >conftest.$ac_ext <<_ACEOF
22837 /* confdefs.h.  */
22838 _ACEOF
22839 cat confdefs.h >>conftest.$ac_ext
22840 cat >>conftest.$ac_ext <<_ACEOF
22841 /* end confdefs.h.  */
22842
22843 /* pthread test headers */
22844 #include <pthread.h>
22845 #if HAVE_PTHREADS < 7
22846 #include <errno.h>
22847 #endif
22848 #ifndef NULL
22849 #define NULL (void*)0
22850 #endif
22851
22852 static void *task(p)
22853         void *p;
22854 {
22855         return (void *) (p == NULL);
22856 }
22857
22858 int
22859 main ()
22860 {
22861
22862         /* pthread test function */
22863 #ifndef PTHREAD_CREATE_DETACHED
22864 #define PTHREAD_CREATE_DETACHED 1
22865 #endif
22866         pthread_t t;
22867         int status;
22868         int detach = PTHREAD_CREATE_DETACHED;
22869
22870 #if HAVE_PTHREADS > 4
22871         /* Final pthreads */
22872         pthread_attr_t attr;
22873
22874         status = pthread_attr_init(&attr);
22875         if( status ) return status;
22876
22877 #if HAVE_PTHREADS < 7
22878         status = pthread_attr_setdetachstate(&attr, &detach);
22879         if( status < 0 ) status = errno;
22880 #else
22881         status = pthread_attr_setdetachstate(&attr, detach);
22882 #endif
22883         if( status ) return status;
22884         status = pthread_create( &t, &attr, task, NULL );
22885 #if HAVE_PTHREADS < 7
22886         if( status < 0 ) status = errno;
22887 #endif
22888         if( status ) return status;
22889 #else
22890         /* Draft 4 pthreads */
22891         status = pthread_create( &t, pthread_attr_default, task, NULL );
22892         if( status ) return errno;
22893
22894         /* give thread a chance to complete */
22895         /* it should remain joinable and hence detachable */
22896         sleep( 1 );
22897
22898         status = pthread_detach( &t );
22899         if( status ) return errno;
22900 #endif
22901
22902 #ifdef HAVE_LINUX_THREADS
22903         pthread_kill_other_threads_np();
22904 #endif
22905
22906         return 0;
22907
22908   ;
22909   return 0;
22910 }
22911 _ACEOF
22912 rm -f conftest.$ac_objext conftest$ac_exeext
22913 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22914   (eval $ac_link) 2>conftest.er1
22915   ac_status=$?
22916   grep -v '^ *+' conftest.er1 >conftest.err
22917   rm -f conftest.er1
22918   cat conftest.err >&5
22919   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22920   (exit $ac_status); } &&
22921          { ac_try='test -z "$ac_c_werror_flag"
22922                          || test ! -s conftest.err'
22923   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22924   (eval $ac_try) 2>&5
22925   ac_status=$?
22926   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22927   (exit $ac_status); }; } &&
22928          { ac_try='test -s conftest$ac_exeext'
22929   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22930   (eval $ac_try) 2>&5
22931   ac_status=$?
22932   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22933   (exit $ac_status); }; }; then
22934   ol_cv_pthread_lpthreads_lmach_lexc=yes
22935 else
22936   echo "$as_me: failed program was:" >&5
22937 sed 's/^/| /' conftest.$ac_ext >&5
22938
22939 ol_cv_pthread_lpthreads_lmach_lexc=no
22940 fi
22941 rm -f conftest.err conftest.$ac_objext \
22942       conftest$ac_exeext conftest.$ac_ext
22943 else
22944   cat >conftest.$ac_ext <<_ACEOF
22945 /* confdefs.h.  */
22946 _ACEOF
22947 cat confdefs.h >>conftest.$ac_ext
22948 cat >>conftest.$ac_ext <<_ACEOF
22949 /* end confdefs.h.  */
22950
22951 /* pthread test headers */
22952 #include <pthread.h>
22953 #if HAVE_PTHREADS < 7
22954 #include <errno.h>
22955 #endif
22956 #ifndef NULL
22957 #define NULL (void*)0
22958 #endif
22959
22960 static void *task(p)
22961         void *p;
22962 {
22963         return (void *) (p == NULL);
22964 }
22965
22966
22967 int main(argc, argv)
22968         int argc;
22969         char **argv;
22970 {
22971
22972         /* pthread test function */
22973 #ifndef PTHREAD_CREATE_DETACHED
22974 #define PTHREAD_CREATE_DETACHED 1
22975 #endif
22976         pthread_t t;
22977         int status;
22978         int detach = PTHREAD_CREATE_DETACHED;
22979
22980 #if HAVE_PTHREADS > 4
22981         /* Final pthreads */
22982         pthread_attr_t attr;
22983
22984         status = pthread_attr_init(&attr);
22985         if( status ) return status;
22986
22987 #if HAVE_PTHREADS < 7
22988         status = pthread_attr_setdetachstate(&attr, &detach);
22989         if( status < 0 ) status = errno;
22990 #else
22991         status = pthread_attr_setdetachstate(&attr, detach);
22992 #endif
22993         if( status ) return status;
22994         status = pthread_create( &t, &attr, task, NULL );
22995 #if HAVE_PTHREADS < 7
22996         if( status < 0 ) status = errno;
22997 #endif
22998         if( status ) return status;
22999 #else
23000         /* Draft 4 pthreads */
23001         status = pthread_create( &t, pthread_attr_default, task, NULL );
23002         if( status ) return errno;
23003
23004         /* give thread a chance to complete */
23005         /* it should remain joinable and hence detachable */
23006         sleep( 1 );
23007
23008         status = pthread_detach( &t );
23009         if( status ) return errno;
23010 #endif
23011
23012 #ifdef HAVE_LINUX_THREADS
23013         pthread_kill_other_threads_np();
23014 #endif
23015
23016         return 0;
23017
23018 }
23019
23020 _ACEOF
23021 rm -f conftest$ac_exeext
23022 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23023   (eval $ac_link) 2>&5
23024   ac_status=$?
23025   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23026   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23027   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23028   (eval $ac_try) 2>&5
23029   ac_status=$?
23030   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23031   (exit $ac_status); }; }; then
23032   ol_cv_pthread_lpthreads_lmach_lexc=yes
23033 else
23034   echo "$as_me: program exited with status $ac_status" >&5
23035 echo "$as_me: failed program was:" >&5
23036 sed 's/^/| /' conftest.$ac_ext >&5
23037
23038 ( exit $ac_status )
23039 ol_cv_pthread_lpthreads_lmach_lexc=no
23040 fi
23041 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23042 fi
23043
23044                 # restore the LIBS
23045                 LIBS="$ol_LIBS"
23046
23047 fi
23048 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lmach_lexc" >&5
23049 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lmach_lexc" >&6
23050
23051         if test $ol_cv_pthread_lpthreads_lmach_lexc = yes ; then
23052                 ol_link_pthreads="-lpthreads -lmach -lexc"
23053                 ol_link_threads=posix
23054         fi
23055 fi
23056
23057                 # Pthread try link: -lpthreads -lexc (ol_cv_pthread_lpthreads_lexc)
23058 if test "$ol_link_threads" = no ; then
23059         # try -lpthreads -lexc
23060         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lexc" >&5
23061 echo $ECHO_N "checking for pthread link with -lpthreads -lexc... $ECHO_C" >&6
23062 if test "${ol_cv_pthread_lpthreads_lexc+set}" = set; then
23063   echo $ECHO_N "(cached) $ECHO_C" >&6
23064 else
23065
23066                 # save the flags
23067                 ol_LIBS="$LIBS"
23068                 LIBS="-lpthreads -lexc $LIBS"
23069
23070                 if test "$cross_compiling" = yes; then
23071   cat >conftest.$ac_ext <<_ACEOF
23072 /* confdefs.h.  */
23073 _ACEOF
23074 cat confdefs.h >>conftest.$ac_ext
23075 cat >>conftest.$ac_ext <<_ACEOF
23076 /* end confdefs.h.  */
23077
23078 /* pthread test headers */
23079 #include <pthread.h>
23080 #if HAVE_PTHREADS < 7
23081 #include <errno.h>
23082 #endif
23083 #ifndef NULL
23084 #define NULL (void*)0
23085 #endif
23086
23087 static void *task(p)
23088         void *p;
23089 {
23090         return (void *) (p == NULL);
23091 }
23092
23093 int
23094 main ()
23095 {
23096
23097         /* pthread test function */
23098 #ifndef PTHREAD_CREATE_DETACHED
23099 #define PTHREAD_CREATE_DETACHED 1
23100 #endif
23101         pthread_t t;
23102         int status;
23103         int detach = PTHREAD_CREATE_DETACHED;
23104
23105 #if HAVE_PTHREADS > 4
23106         /* Final pthreads */
23107         pthread_attr_t attr;
23108
23109         status = pthread_attr_init(&attr);
23110         if( status ) return status;
23111
23112 #if HAVE_PTHREADS < 7
23113         status = pthread_attr_setdetachstate(&attr, &detach);
23114         if( status < 0 ) status = errno;
23115 #else
23116         status = pthread_attr_setdetachstate(&attr, detach);
23117 #endif
23118         if( status ) return status;
23119         status = pthread_create( &t, &attr, task, NULL );
23120 #if HAVE_PTHREADS < 7
23121         if( status < 0 ) status = errno;
23122 #endif
23123         if( status ) return status;
23124 #else
23125         /* Draft 4 pthreads */
23126         status = pthread_create( &t, pthread_attr_default, task, NULL );
23127         if( status ) return errno;
23128
23129         /* give thread a chance to complete */
23130         /* it should remain joinable and hence detachable */
23131         sleep( 1 );
23132
23133         status = pthread_detach( &t );
23134         if( status ) return errno;
23135 #endif
23136
23137 #ifdef HAVE_LINUX_THREADS
23138         pthread_kill_other_threads_np();
23139 #endif
23140
23141         return 0;
23142
23143   ;
23144   return 0;
23145 }
23146 _ACEOF
23147 rm -f conftest.$ac_objext conftest$ac_exeext
23148 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23149   (eval $ac_link) 2>conftest.er1
23150   ac_status=$?
23151   grep -v '^ *+' conftest.er1 >conftest.err
23152   rm -f conftest.er1
23153   cat conftest.err >&5
23154   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23155   (exit $ac_status); } &&
23156          { ac_try='test -z "$ac_c_werror_flag"
23157                          || test ! -s conftest.err'
23158   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23159   (eval $ac_try) 2>&5
23160   ac_status=$?
23161   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23162   (exit $ac_status); }; } &&
23163          { ac_try='test -s conftest$ac_exeext'
23164   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23165   (eval $ac_try) 2>&5
23166   ac_status=$?
23167   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23168   (exit $ac_status); }; }; then
23169   ol_cv_pthread_lpthreads_lexc=yes
23170 else
23171   echo "$as_me: failed program was:" >&5
23172 sed 's/^/| /' conftest.$ac_ext >&5
23173
23174 ol_cv_pthread_lpthreads_lexc=no
23175 fi
23176 rm -f conftest.err conftest.$ac_objext \
23177       conftest$ac_exeext conftest.$ac_ext
23178 else
23179   cat >conftest.$ac_ext <<_ACEOF
23180 /* confdefs.h.  */
23181 _ACEOF
23182 cat confdefs.h >>conftest.$ac_ext
23183 cat >>conftest.$ac_ext <<_ACEOF
23184 /* end confdefs.h.  */
23185
23186 /* pthread test headers */
23187 #include <pthread.h>
23188 #if HAVE_PTHREADS < 7
23189 #include <errno.h>
23190 #endif
23191 #ifndef NULL
23192 #define NULL (void*)0
23193 #endif
23194
23195 static void *task(p)
23196         void *p;
23197 {
23198         return (void *) (p == NULL);
23199 }
23200
23201
23202 int main(argc, argv)
23203         int argc;
23204         char **argv;
23205 {
23206
23207         /* pthread test function */
23208 #ifndef PTHREAD_CREATE_DETACHED
23209 #define PTHREAD_CREATE_DETACHED 1
23210 #endif
23211         pthread_t t;
23212         int status;
23213         int detach = PTHREAD_CREATE_DETACHED;
23214
23215 #if HAVE_PTHREADS > 4
23216         /* Final pthreads */
23217         pthread_attr_t attr;
23218
23219         status = pthread_attr_init(&attr);
23220         if( status ) return status;
23221
23222 #if HAVE_PTHREADS < 7
23223         status = pthread_attr_setdetachstate(&attr, &detach);
23224         if( status < 0 ) status = errno;
23225 #else
23226         status = pthread_attr_setdetachstate(&attr, detach);
23227 #endif
23228         if( status ) return status;
23229         status = pthread_create( &t, &attr, task, NULL );
23230 #if HAVE_PTHREADS < 7
23231         if( status < 0 ) status = errno;
23232 #endif
23233         if( status ) return status;
23234 #else
23235         /* Draft 4 pthreads */
23236         status = pthread_create( &t, pthread_attr_default, task, NULL );
23237         if( status ) return errno;
23238
23239         /* give thread a chance to complete */
23240         /* it should remain joinable and hence detachable */
23241         sleep( 1 );
23242
23243         status = pthread_detach( &t );
23244         if( status ) return errno;
23245 #endif
23246
23247 #ifdef HAVE_LINUX_THREADS
23248         pthread_kill_other_threads_np();
23249 #endif
23250
23251         return 0;
23252
23253 }
23254
23255 _ACEOF
23256 rm -f conftest$ac_exeext
23257 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23258   (eval $ac_link) 2>&5
23259   ac_status=$?
23260   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23261   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23262   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23263   (eval $ac_try) 2>&5
23264   ac_status=$?
23265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23266   (exit $ac_status); }; }; then
23267   ol_cv_pthread_lpthreads_lexc=yes
23268 else
23269   echo "$as_me: program exited with status $ac_status" >&5
23270 echo "$as_me: failed program was:" >&5
23271 sed 's/^/| /' conftest.$ac_ext >&5
23272
23273 ( exit $ac_status )
23274 ol_cv_pthread_lpthreads_lexc=no
23275 fi
23276 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23277 fi
23278
23279                 # restore the LIBS
23280                 LIBS="$ol_LIBS"
23281
23282 fi
23283 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lexc" >&5
23284 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lexc" >&6
23285
23286         if test $ol_cv_pthread_lpthreads_lexc = yes ; then
23287                 ol_link_pthreads="-lpthreads -lexc"
23288                 ol_link_threads=posix
23289         fi
23290 fi
23291
23292
23293                 # Pthread try link: -lpthreads (ol_cv_pthread_lib_lpthreads)
23294 if test "$ol_link_threads" = no ; then
23295         # try -lpthreads
23296         echo "$as_me:$LINENO: checking for pthread link with -lpthreads" >&5
23297 echo $ECHO_N "checking for pthread link with -lpthreads... $ECHO_C" >&6
23298 if test "${ol_cv_pthread_lib_lpthreads+set}" = set; then
23299   echo $ECHO_N "(cached) $ECHO_C" >&6
23300 else
23301
23302                 # save the flags
23303                 ol_LIBS="$LIBS"
23304                 LIBS="-lpthreads $LIBS"
23305
23306                 if test "$cross_compiling" = yes; then
23307   cat >conftest.$ac_ext <<_ACEOF
23308 /* confdefs.h.  */
23309 _ACEOF
23310 cat confdefs.h >>conftest.$ac_ext
23311 cat >>conftest.$ac_ext <<_ACEOF
23312 /* end confdefs.h.  */
23313
23314 /* pthread test headers */
23315 #include <pthread.h>
23316 #if HAVE_PTHREADS < 7
23317 #include <errno.h>
23318 #endif
23319 #ifndef NULL
23320 #define NULL (void*)0
23321 #endif
23322
23323 static void *task(p)
23324         void *p;
23325 {
23326         return (void *) (p == NULL);
23327 }
23328
23329 int
23330 main ()
23331 {
23332
23333         /* pthread test function */
23334 #ifndef PTHREAD_CREATE_DETACHED
23335 #define PTHREAD_CREATE_DETACHED 1
23336 #endif
23337         pthread_t t;
23338         int status;
23339         int detach = PTHREAD_CREATE_DETACHED;
23340
23341 #if HAVE_PTHREADS > 4
23342         /* Final pthreads */
23343         pthread_attr_t attr;
23344
23345         status = pthread_attr_init(&attr);
23346         if( status ) return status;
23347
23348 #if HAVE_PTHREADS < 7
23349         status = pthread_attr_setdetachstate(&attr, &detach);
23350         if( status < 0 ) status = errno;
23351 #else
23352         status = pthread_attr_setdetachstate(&attr, detach);
23353 #endif
23354         if( status ) return status;
23355         status = pthread_create( &t, &attr, task, NULL );
23356 #if HAVE_PTHREADS < 7
23357         if( status < 0 ) status = errno;
23358 #endif
23359         if( status ) return status;
23360 #else
23361         /* Draft 4 pthreads */
23362         status = pthread_create( &t, pthread_attr_default, task, NULL );
23363         if( status ) return errno;
23364
23365         /* give thread a chance to complete */
23366         /* it should remain joinable and hence detachable */
23367         sleep( 1 );
23368
23369         status = pthread_detach( &t );
23370         if( status ) return errno;
23371 #endif
23372
23373 #ifdef HAVE_LINUX_THREADS
23374         pthread_kill_other_threads_np();
23375 #endif
23376
23377         return 0;
23378
23379   ;
23380   return 0;
23381 }
23382 _ACEOF
23383 rm -f conftest.$ac_objext conftest$ac_exeext
23384 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23385   (eval $ac_link) 2>conftest.er1
23386   ac_status=$?
23387   grep -v '^ *+' conftest.er1 >conftest.err
23388   rm -f conftest.er1
23389   cat conftest.err >&5
23390   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23391   (exit $ac_status); } &&
23392          { ac_try='test -z "$ac_c_werror_flag"
23393                          || test ! -s conftest.err'
23394   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23395   (eval $ac_try) 2>&5
23396   ac_status=$?
23397   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23398   (exit $ac_status); }; } &&
23399          { ac_try='test -s conftest$ac_exeext'
23400   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23401   (eval $ac_try) 2>&5
23402   ac_status=$?
23403   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23404   (exit $ac_status); }; }; then
23405   ol_cv_pthread_lib_lpthreads=yes
23406 else
23407   echo "$as_me: failed program was:" >&5
23408 sed 's/^/| /' conftest.$ac_ext >&5
23409
23410 ol_cv_pthread_lib_lpthreads=no
23411 fi
23412 rm -f conftest.err conftest.$ac_objext \
23413       conftest$ac_exeext conftest.$ac_ext
23414 else
23415   cat >conftest.$ac_ext <<_ACEOF
23416 /* confdefs.h.  */
23417 _ACEOF
23418 cat confdefs.h >>conftest.$ac_ext
23419 cat >>conftest.$ac_ext <<_ACEOF
23420 /* end confdefs.h.  */
23421
23422 /* pthread test headers */
23423 #include <pthread.h>
23424 #if HAVE_PTHREADS < 7
23425 #include <errno.h>
23426 #endif
23427 #ifndef NULL
23428 #define NULL (void*)0
23429 #endif
23430
23431 static void *task(p)
23432         void *p;
23433 {
23434         return (void *) (p == NULL);
23435 }
23436
23437
23438 int main(argc, argv)
23439         int argc;
23440         char **argv;
23441 {
23442
23443         /* pthread test function */
23444 #ifndef PTHREAD_CREATE_DETACHED
23445 #define PTHREAD_CREATE_DETACHED 1
23446 #endif
23447         pthread_t t;
23448         int status;
23449         int detach = PTHREAD_CREATE_DETACHED;
23450
23451 #if HAVE_PTHREADS > 4
23452         /* Final pthreads */
23453         pthread_attr_t attr;
23454
23455         status = pthread_attr_init(&attr);
23456         if( status ) return status;
23457
23458 #if HAVE_PTHREADS < 7
23459         status = pthread_attr_setdetachstate(&attr, &detach);
23460         if( status < 0 ) status = errno;
23461 #else
23462         status = pthread_attr_setdetachstate(&attr, detach);
23463 #endif
23464         if( status ) return status;
23465         status = pthread_create( &t, &attr, task, NULL );
23466 #if HAVE_PTHREADS < 7
23467         if( status < 0 ) status = errno;
23468 #endif
23469         if( status ) return status;
23470 #else
23471         /* Draft 4 pthreads */
23472         status = pthread_create( &t, pthread_attr_default, task, NULL );
23473         if( status ) return errno;
23474
23475         /* give thread a chance to complete */
23476         /* it should remain joinable and hence detachable */
23477         sleep( 1 );
23478
23479         status = pthread_detach( &t );
23480         if( status ) return errno;
23481 #endif
23482
23483 #ifdef HAVE_LINUX_THREADS
23484         pthread_kill_other_threads_np();
23485 #endif
23486
23487         return 0;
23488
23489 }
23490
23491 _ACEOF
23492 rm -f conftest$ac_exeext
23493 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23494   (eval $ac_link) 2>&5
23495   ac_status=$?
23496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23497   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23498   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23499   (eval $ac_try) 2>&5
23500   ac_status=$?
23501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23502   (exit $ac_status); }; }; then
23503   ol_cv_pthread_lib_lpthreads=yes
23504 else
23505   echo "$as_me: program exited with status $ac_status" >&5
23506 echo "$as_me: failed program was:" >&5
23507 sed 's/^/| /' conftest.$ac_ext >&5
23508
23509 ( exit $ac_status )
23510 ol_cv_pthread_lib_lpthreads=no
23511 fi
23512 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23513 fi
23514
23515                 # restore the LIBS
23516                 LIBS="$ol_LIBS"
23517
23518 fi
23519 echo "$as_me:$LINENO: result: $ol_cv_pthread_lib_lpthreads" >&5
23520 echo "${ECHO_T}$ol_cv_pthread_lib_lpthreads" >&6
23521
23522         if test $ol_cv_pthread_lib_lpthreads = yes ; then
23523                 ol_link_pthreads="-lpthreads"
23524                 ol_link_threads=posix
23525         fi
23526 fi
23527
23528
23529                 if test $ol_link_threads != no ; then
23530                         LTHREAD_LIBS="$LTHREAD_LIBS $ol_link_pthreads"
23531
23532                                                 save_CPPFLAGS="$CPPFLAGS"
23533                         save_LIBS="$LIBS"
23534                         LIBS="$LTHREAD_LIBS $LIBS"
23535
23536
23537
23538
23539 for ac_func in sched_yield pthread_yield thr_yield
23540 do
23541 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
23542 echo "$as_me:$LINENO: checking for $ac_func" >&5
23543 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
23544 if eval "test \"\${$as_ac_var+set}\" = set"; then
23545   echo $ECHO_N "(cached) $ECHO_C" >&6
23546 else
23547   cat >conftest.$ac_ext <<_ACEOF
23548 /* confdefs.h.  */
23549 _ACEOF
23550 cat confdefs.h >>conftest.$ac_ext
23551 cat >>conftest.$ac_ext <<_ACEOF
23552 /* end confdefs.h.  */
23553 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23554    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23555 #define $ac_func innocuous_$ac_func
23556
23557 /* System header to define __stub macros and hopefully few prototypes,
23558     which can conflict with char $ac_func (); below.
23559     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23560     <limits.h> exists even on freestanding compilers.  */
23561
23562 #ifdef __STDC__
23563 # include <limits.h>
23564 #else
23565 # include <assert.h>
23566 #endif
23567
23568 #undef $ac_func
23569
23570 /* Override any gcc2 internal prototype to avoid an error.  */
23571 #ifdef __cplusplus
23572 extern "C"
23573 {
23574 #endif
23575 /* We use char because int might match the return type of a gcc2
23576    builtin and then its argument prototype would still apply.  */
23577 char $ac_func ();
23578 /* The GNU C library defines this for functions which it implements
23579     to always fail with ENOSYS.  Some functions are actually named
23580     something starting with __ and the normal name is an alias.  */
23581 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
23582 choke me
23583 #else
23584 char (*f) () = $ac_func;
23585 #endif
23586 #ifdef __cplusplus
23587 }
23588 #endif
23589
23590 int
23591 main ()
23592 {
23593 return f != $ac_func;
23594   ;
23595   return 0;
23596 }
23597 _ACEOF
23598 rm -f conftest.$ac_objext conftest$ac_exeext
23599 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23600   (eval $ac_link) 2>conftest.er1
23601   ac_status=$?
23602   grep -v '^ *+' conftest.er1 >conftest.err
23603   rm -f conftest.er1
23604   cat conftest.err >&5
23605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23606   (exit $ac_status); } &&
23607          { ac_try='test -z "$ac_c_werror_flag"
23608                          || test ! -s conftest.err'
23609   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23610   (eval $ac_try) 2>&5
23611   ac_status=$?
23612   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23613   (exit $ac_status); }; } &&
23614          { ac_try='test -s conftest$ac_exeext'
23615   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23616   (eval $ac_try) 2>&5
23617   ac_status=$?
23618   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23619   (exit $ac_status); }; }; then
23620   eval "$as_ac_var=yes"
23621 else
23622   echo "$as_me: failed program was:" >&5
23623 sed 's/^/| /' conftest.$ac_ext >&5
23624
23625 eval "$as_ac_var=no"
23626 fi
23627 rm -f conftest.err conftest.$ac_objext \
23628       conftest$ac_exeext conftest.$ac_ext
23629 fi
23630 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
23631 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
23632 if test `eval echo '${'$as_ac_var'}'` = yes; then
23633   cat >>confdefs.h <<_ACEOF
23634 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
23635 _ACEOF
23636
23637 fi
23638 done
23639
23640
23641                         if test $ac_cv_func_sched_yield = no &&
23642                            test $ac_cv_func_pthread_yield = no &&
23643                            test $ac_cv_func_thr_yield = no ; then
23644                                                                 echo "$as_me:$LINENO: checking for sched_yield in -lrt" >&5
23645 echo $ECHO_N "checking for sched_yield in -lrt... $ECHO_C" >&6
23646 if test "${ac_cv_lib_rt_sched_yield+set}" = set; then
23647   echo $ECHO_N "(cached) $ECHO_C" >&6
23648 else
23649   ac_check_lib_save_LIBS=$LIBS
23650 LIBS="-lrt  $LIBS"
23651 cat >conftest.$ac_ext <<_ACEOF
23652 /* confdefs.h.  */
23653 _ACEOF
23654 cat confdefs.h >>conftest.$ac_ext
23655 cat >>conftest.$ac_ext <<_ACEOF
23656 /* end confdefs.h.  */
23657
23658 /* Override any gcc2 internal prototype to avoid an error.  */
23659 #ifdef __cplusplus
23660 extern "C"
23661 #endif
23662 /* We use char because int might match the return type of a gcc2
23663    builtin and then its argument prototype would still apply.  */
23664 char sched_yield ();
23665 int
23666 main ()
23667 {
23668 sched_yield ();
23669   ;
23670   return 0;
23671 }
23672 _ACEOF
23673 rm -f conftest.$ac_objext conftest$ac_exeext
23674 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23675   (eval $ac_link) 2>conftest.er1
23676   ac_status=$?
23677   grep -v '^ *+' conftest.er1 >conftest.err
23678   rm -f conftest.er1
23679   cat conftest.err >&5
23680   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23681   (exit $ac_status); } &&
23682          { ac_try='test -z "$ac_c_werror_flag"
23683                          || test ! -s conftest.err'
23684   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23685   (eval $ac_try) 2>&5
23686   ac_status=$?
23687   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23688   (exit $ac_status); }; } &&
23689          { ac_try='test -s conftest$ac_exeext'
23690   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23691   (eval $ac_try) 2>&5
23692   ac_status=$?
23693   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23694   (exit $ac_status); }; }; then
23695   ac_cv_lib_rt_sched_yield=yes
23696 else
23697   echo "$as_me: failed program was:" >&5
23698 sed 's/^/| /' conftest.$ac_ext >&5
23699
23700 ac_cv_lib_rt_sched_yield=no
23701 fi
23702 rm -f conftest.err conftest.$ac_objext \
23703       conftest$ac_exeext conftest.$ac_ext
23704 LIBS=$ac_check_lib_save_LIBS
23705 fi
23706 echo "$as_me:$LINENO: result: $ac_cv_lib_rt_sched_yield" >&5
23707 echo "${ECHO_T}$ac_cv_lib_rt_sched_yield" >&6
23708 if test $ac_cv_lib_rt_sched_yield = yes; then
23709   LTHREAD_LIBS="$LTHREAD_LIBS -lrt"
23710
23711 cat >>confdefs.h <<\_ACEOF
23712 #define HAVE_SCHED_YIELD 1
23713 _ACEOF
23714
23715                                         ac_cv_func_sched_yield=yes
23716 else
23717   ac_cv_func_sched_yield=no
23718 fi
23719
23720                         fi
23721                         if test $ac_cv_func_sched_yield = no &&
23722                            test $ac_cv_func_pthread_yield = no &&
23723                            test "$ac_cv_func_thr_yield" = no ; then
23724                                 { echo "$as_me:$LINENO: WARNING: could not locate sched_yield() or pthread_yield()" >&5
23725 echo "$as_me: WARNING: could not locate sched_yield() or pthread_yield()" >&2;}
23726                         fi
23727
23728
23729 for ac_func in pthread_kill
23730 do
23731 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
23732 echo "$as_me:$LINENO: checking for $ac_func" >&5
23733 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
23734 if eval "test \"\${$as_ac_var+set}\" = set"; then
23735   echo $ECHO_N "(cached) $ECHO_C" >&6
23736 else
23737   cat >conftest.$ac_ext <<_ACEOF
23738 /* confdefs.h.  */
23739 _ACEOF
23740 cat confdefs.h >>conftest.$ac_ext
23741 cat >>conftest.$ac_ext <<_ACEOF
23742 /* end confdefs.h.  */
23743 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23744    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23745 #define $ac_func innocuous_$ac_func
23746
23747 /* System header to define __stub macros and hopefully few prototypes,
23748     which can conflict with char $ac_func (); below.
23749     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23750     <limits.h> exists even on freestanding compilers.  */
23751
23752 #ifdef __STDC__
23753 # include <limits.h>
23754 #else
23755 # include <assert.h>
23756 #endif
23757
23758 #undef $ac_func
23759
23760 /* Override any gcc2 internal prototype to avoid an error.  */
23761 #ifdef __cplusplus
23762 extern "C"
23763 {
23764 #endif
23765 /* We use char because int might match the return type of a gcc2
23766    builtin and then its argument prototype would still apply.  */
23767 char $ac_func ();
23768 /* The GNU C library defines this for functions which it implements
23769     to always fail with ENOSYS.  Some functions are actually named
23770     something starting with __ and the normal name is an alias.  */
23771 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
23772 choke me
23773 #else
23774 char (*f) () = $ac_func;
23775 #endif
23776 #ifdef __cplusplus
23777 }
23778 #endif
23779
23780 int
23781 main ()
23782 {
23783 return f != $ac_func;
23784   ;
23785   return 0;
23786 }
23787 _ACEOF
23788 rm -f conftest.$ac_objext conftest$ac_exeext
23789 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23790   (eval $ac_link) 2>conftest.er1
23791   ac_status=$?
23792   grep -v '^ *+' conftest.er1 >conftest.err
23793   rm -f conftest.er1
23794   cat conftest.err >&5
23795   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23796   (exit $ac_status); } &&
23797          { ac_try='test -z "$ac_c_werror_flag"
23798                          || test ! -s conftest.err'
23799   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23800   (eval $ac_try) 2>&5
23801   ac_status=$?
23802   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23803   (exit $ac_status); }; } &&
23804          { ac_try='test -s conftest$ac_exeext'
23805   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23806   (eval $ac_try) 2>&5
23807   ac_status=$?
23808   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23809   (exit $ac_status); }; }; then
23810   eval "$as_ac_var=yes"
23811 else
23812   echo "$as_me: failed program was:" >&5
23813 sed 's/^/| /' conftest.$ac_ext >&5
23814
23815 eval "$as_ac_var=no"
23816 fi
23817 rm -f conftest.err conftest.$ac_objext \
23818       conftest$ac_exeext conftest.$ac_ext
23819 fi
23820 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
23821 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
23822 if test `eval echo '${'$as_ac_var'}'` = yes; then
23823   cat >>confdefs.h <<_ACEOF
23824 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
23825 _ACEOF
23826
23827 fi
23828 done
23829
23830
23831                                                                         echo "$as_me:$LINENO: checking for pthread_rwlock_destroy with <pthread.h>" >&5
23832 echo $ECHO_N "checking for pthread_rwlock_destroy with <pthread.h>... $ECHO_C" >&6
23833 if test "${ol_cv_func_pthread_rwlock_destroy+set}" = set; then
23834   echo $ECHO_N "(cached) $ECHO_C" >&6
23835 else
23836
23837                                                                 cat >conftest.$ac_ext <<_ACEOF
23838 /* confdefs.h.  */
23839 _ACEOF
23840 cat confdefs.h >>conftest.$ac_ext
23841 cat >>conftest.$ac_ext <<_ACEOF
23842 /* end confdefs.h.  */
23843
23844 #include <pthread.h>
23845 pthread_rwlock_t rwlock;
23846
23847 int
23848 main ()
23849 {
23850 pthread_rwlock_destroy(&rwlock);
23851   ;
23852   return 0;
23853 }
23854 _ACEOF
23855 rm -f conftest.$ac_objext conftest$ac_exeext
23856 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23857   (eval $ac_link) 2>conftest.er1
23858   ac_status=$?
23859   grep -v '^ *+' conftest.er1 >conftest.err
23860   rm -f conftest.er1
23861   cat conftest.err >&5
23862   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23863   (exit $ac_status); } &&
23864          { ac_try='test -z "$ac_c_werror_flag"
23865                          || test ! -s conftest.err'
23866   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23867   (eval $ac_try) 2>&5
23868   ac_status=$?
23869   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23870   (exit $ac_status); }; } &&
23871          { ac_try='test -s conftest$ac_exeext'
23872   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23873   (eval $ac_try) 2>&5
23874   ac_status=$?
23875   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23876   (exit $ac_status); }; }; then
23877   ol_cv_func_pthread_rwlock_destroy=yes
23878 else
23879   echo "$as_me: failed program was:" >&5
23880 sed 's/^/| /' conftest.$ac_ext >&5
23881
23882 ol_cv_func_pthread_rwlock_destroy=no
23883 fi
23884 rm -f conftest.err conftest.$ac_objext \
23885       conftest$ac_exeext conftest.$ac_ext
23886
23887 fi
23888 echo "$as_me:$LINENO: result: $ol_cv_func_pthread_rwlock_destroy" >&5
23889 echo "${ECHO_T}$ol_cv_func_pthread_rwlock_destroy" >&6
23890                         if test $ol_cv_func_pthread_rwlock_destroy = yes ; then
23891
23892 cat >>confdefs.h <<\_ACEOF
23893 #define HAVE_PTHREAD_RWLOCK_DESTROY 1
23894 _ACEOF
23895
23896                         fi
23897
23898                                                                         echo "$as_me:$LINENO: checking for pthread_detach with <pthread.h>" >&5
23899 echo $ECHO_N "checking for pthread_detach with <pthread.h>... $ECHO_C" >&6
23900 if test "${ol_cv_func_pthread_detach+set}" = set; then
23901   echo $ECHO_N "(cached) $ECHO_C" >&6
23902 else
23903
23904                                                                 cat >conftest.$ac_ext <<_ACEOF
23905 /* confdefs.h.  */
23906 _ACEOF
23907 cat confdefs.h >>conftest.$ac_ext
23908 cat >>conftest.$ac_ext <<_ACEOF
23909 /* end confdefs.h.  */
23910
23911 #include <pthread.h>
23912 #ifndef NULL
23913 #define NULL (void*)0
23914 #endif
23915
23916 int
23917 main ()
23918 {
23919 pthread_detach(NULL);
23920   ;
23921   return 0;
23922 }
23923 _ACEOF
23924 rm -f conftest.$ac_objext conftest$ac_exeext
23925 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23926   (eval $ac_link) 2>conftest.er1
23927   ac_status=$?
23928   grep -v '^ *+' conftest.er1 >conftest.err
23929   rm -f conftest.er1
23930   cat conftest.err >&5
23931   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23932   (exit $ac_status); } &&
23933          { ac_try='test -z "$ac_c_werror_flag"
23934                          || test ! -s conftest.err'
23935   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23936   (eval $ac_try) 2>&5
23937   ac_status=$?
23938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23939   (exit $ac_status); }; } &&
23940          { ac_try='test -s conftest$ac_exeext'
23941   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23942   (eval $ac_try) 2>&5
23943   ac_status=$?
23944   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23945   (exit $ac_status); }; }; then
23946   ol_cv_func_pthread_detach=yes
23947 else
23948   echo "$as_me: failed program was:" >&5
23949 sed 's/^/| /' conftest.$ac_ext >&5
23950
23951 ol_cv_func_pthread_detach=no
23952 fi
23953 rm -f conftest.err conftest.$ac_objext \
23954       conftest$ac_exeext conftest.$ac_ext
23955
23956 fi
23957 echo "$as_me:$LINENO: result: $ol_cv_func_pthread_detach" >&5
23958 echo "${ECHO_T}$ol_cv_func_pthread_detach" >&6
23959
23960                         if test $ol_cv_func_pthread_detach = no ; then
23961                                 { { echo "$as_me:$LINENO: error: could not locate pthread_detach()" >&5
23962 echo "$as_me: error: could not locate pthread_detach()" >&2;}
23963    { (exit 1); exit 1; }; }
23964                         fi
23965
23966
23967 cat >>confdefs.h <<\_ACEOF
23968 #define HAVE_PTHREAD_DETACH 1
23969 _ACEOF
23970
23971
23972
23973
23974
23975
23976 for ac_func in \
23977                                 pthread_setconcurrency \
23978                                 pthread_getconcurrency \
23979                                 thr_setconcurrency \
23980                                 thr_getconcurrency \
23981
23982 do
23983 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
23984 echo "$as_me:$LINENO: checking for $ac_func" >&5
23985 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
23986 if eval "test \"\${$as_ac_var+set}\" = set"; then
23987   echo $ECHO_N "(cached) $ECHO_C" >&6
23988 else
23989   cat >conftest.$ac_ext <<_ACEOF
23990 /* confdefs.h.  */
23991 _ACEOF
23992 cat confdefs.h >>conftest.$ac_ext
23993 cat >>conftest.$ac_ext <<_ACEOF
23994 /* end confdefs.h.  */
23995 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23996    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23997 #define $ac_func innocuous_$ac_func
23998
23999 /* System header to define __stub macros and hopefully few prototypes,
24000     which can conflict with char $ac_func (); below.
24001     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24002     <limits.h> exists even on freestanding compilers.  */
24003
24004 #ifdef __STDC__
24005 # include <limits.h>
24006 #else
24007 # include <assert.h>
24008 #endif
24009
24010 #undef $ac_func
24011
24012 /* Override any gcc2 internal prototype to avoid an error.  */
24013 #ifdef __cplusplus
24014 extern "C"
24015 {
24016 #endif
24017 /* We use char because int might match the return type of a gcc2
24018    builtin and then its argument prototype would still apply.  */
24019 char $ac_func ();
24020 /* The GNU C library defines this for functions which it implements
24021     to always fail with ENOSYS.  Some functions are actually named
24022     something starting with __ and the normal name is an alias.  */
24023 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
24024 choke me
24025 #else
24026 char (*f) () = $ac_func;
24027 #endif
24028 #ifdef __cplusplus
24029 }
24030 #endif
24031
24032 int
24033 main ()
24034 {
24035 return f != $ac_func;
24036   ;
24037   return 0;
24038 }
24039 _ACEOF
24040 rm -f conftest.$ac_objext conftest$ac_exeext
24041 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24042   (eval $ac_link) 2>conftest.er1
24043   ac_status=$?
24044   grep -v '^ *+' conftest.er1 >conftest.err
24045   rm -f conftest.er1
24046   cat conftest.err >&5
24047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24048   (exit $ac_status); } &&
24049          { ac_try='test -z "$ac_c_werror_flag"
24050                          || test ! -s conftest.err'
24051   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24052   (eval $ac_try) 2>&5
24053   ac_status=$?
24054   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24055   (exit $ac_status); }; } &&
24056          { ac_try='test -s conftest$ac_exeext'
24057   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24058   (eval $ac_try) 2>&5
24059   ac_status=$?
24060   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24061   (exit $ac_status); }; }; then
24062   eval "$as_ac_var=yes"
24063 else
24064   echo "$as_me: failed program was:" >&5
24065 sed 's/^/| /' conftest.$ac_ext >&5
24066
24067 eval "$as_ac_var=no"
24068 fi
24069 rm -f conftest.err conftest.$ac_objext \
24070       conftest$ac_exeext conftest.$ac_ext
24071 fi
24072 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
24073 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
24074 if test `eval echo '${'$as_ac_var'}'` = yes; then
24075   cat >>confdefs.h <<_ACEOF
24076 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
24077 _ACEOF
24078
24079 fi
24080 done
24081
24082
24083
24084
24085 for ac_func in pthread_kill_other_threads_np
24086 do
24087 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
24088 echo "$as_me:$LINENO: checking for $ac_func" >&5
24089 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
24090 if eval "test \"\${$as_ac_var+set}\" = set"; then
24091   echo $ECHO_N "(cached) $ECHO_C" >&6
24092 else
24093   cat >conftest.$ac_ext <<_ACEOF
24094 /* confdefs.h.  */
24095 _ACEOF
24096 cat confdefs.h >>conftest.$ac_ext
24097 cat >>conftest.$ac_ext <<_ACEOF
24098 /* end confdefs.h.  */
24099 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
24100    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24101 #define $ac_func innocuous_$ac_func
24102
24103 /* System header to define __stub macros and hopefully few prototypes,
24104     which can conflict with char $ac_func (); below.
24105     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24106     <limits.h> exists even on freestanding compilers.  */
24107
24108 #ifdef __STDC__
24109 # include <limits.h>
24110 #else
24111 # include <assert.h>
24112 #endif
24113
24114 #undef $ac_func
24115
24116 /* Override any gcc2 internal prototype to avoid an error.  */
24117 #ifdef __cplusplus
24118 extern "C"
24119 {
24120 #endif
24121 /* We use char because int might match the return type of a gcc2
24122    builtin and then its argument prototype would still apply.  */
24123 char $ac_func ();
24124 /* The GNU C library defines this for functions which it implements
24125     to always fail with ENOSYS.  Some functions are actually named
24126     something starting with __ and the normal name is an alias.  */
24127 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
24128 choke me
24129 #else
24130 char (*f) () = $ac_func;
24131 #endif
24132 #ifdef __cplusplus
24133 }
24134 #endif
24135
24136 int
24137 main ()
24138 {
24139 return f != $ac_func;
24140   ;
24141   return 0;
24142 }
24143 _ACEOF
24144 rm -f conftest.$ac_objext conftest$ac_exeext
24145 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24146   (eval $ac_link) 2>conftest.er1
24147   ac_status=$?
24148   grep -v '^ *+' conftest.er1 >conftest.err
24149   rm -f conftest.er1
24150   cat conftest.err >&5
24151   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24152   (exit $ac_status); } &&
24153          { ac_try='test -z "$ac_c_werror_flag"
24154                          || test ! -s conftest.err'
24155   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24156   (eval $ac_try) 2>&5
24157   ac_status=$?
24158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24159   (exit $ac_status); }; } &&
24160          { ac_try='test -s conftest$ac_exeext'
24161   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24162   (eval $ac_try) 2>&5
24163   ac_status=$?
24164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24165   (exit $ac_status); }; }; then
24166   eval "$as_ac_var=yes"
24167 else
24168   echo "$as_me: failed program was:" >&5
24169 sed 's/^/| /' conftest.$ac_ext >&5
24170
24171 eval "$as_ac_var=no"
24172 fi
24173 rm -f conftest.err conftest.$ac_objext \
24174       conftest$ac_exeext conftest.$ac_ext
24175 fi
24176 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
24177 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
24178 if test `eval echo '${'$as_ac_var'}'` = yes; then
24179   cat >>confdefs.h <<_ACEOF
24180 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
24181 _ACEOF
24182
24183 fi
24184 done
24185
24186         echo "$as_me:$LINENO: checking for LinuxThreads implementation" >&5
24187 echo $ECHO_N "checking for LinuxThreads implementation... $ECHO_C" >&6
24188 if test "${ol_cv_sys_linux_threads+set}" = set; then
24189   echo $ECHO_N "(cached) $ECHO_C" >&6
24190 else
24191   ol_cv_sys_linux_threads=$ac_cv_func_pthread_kill_other_threads_np
24192 fi
24193 echo "$as_me:$LINENO: result: $ol_cv_sys_linux_threads" >&5
24194 echo "${ECHO_T}$ol_cv_sys_linux_threads" >&6
24195
24196
24197
24198
24199         echo "$as_me:$LINENO: checking for LinuxThreads consistency" >&5
24200 echo $ECHO_N "checking for LinuxThreads consistency... $ECHO_C" >&6
24201 if test "${ol_cv_linux_threads+set}" = set; then
24202   echo $ECHO_N "(cached) $ECHO_C" >&6
24203 else
24204
24205                 if test $ol_cv_header_linux_threads = yes &&
24206                    test $ol_cv_sys_linux_threads = yes; then
24207                         ol_cv_linux_threads=yes
24208                 elif test $ol_cv_header_linux_threads = no &&
24209                      test $ol_cv_sys_linux_threads = no; then
24210                         ol_cv_linux_threads=no
24211                 else
24212                         ol_cv_linux_threads=error
24213                 fi
24214
24215 fi
24216 echo "$as_me:$LINENO: result: $ol_cv_linux_threads" >&5
24217 echo "${ECHO_T}$ol_cv_linux_threads" >&6
24218
24219
24220                         if test $ol_cv_linux_threads = error; then
24221                                 { { echo "$as_me:$LINENO: error: LinuxThreads header/library mismatch" >&5
24222 echo "$as_me: error: LinuxThreads header/library mismatch" >&2;}
24223    { (exit 1); exit 1; }; };
24224                         fi
24225
24226                         echo "$as_me:$LINENO: checking if pthread_create() works" >&5
24227 echo $ECHO_N "checking if pthread_create() works... $ECHO_C" >&6
24228 if test "${ol_cv_pthread_create_works+set}" = set; then
24229   echo $ECHO_N "(cached) $ECHO_C" >&6
24230 else
24231
24232                         if test "$cross_compiling" = yes; then
24233                                 ol_cv_pthread_create_works=yes
24234 else
24235   cat >conftest.$ac_ext <<_ACEOF
24236 /* confdefs.h.  */
24237 _ACEOF
24238 cat confdefs.h >>conftest.$ac_ext
24239 cat >>conftest.$ac_ext <<_ACEOF
24240 /* end confdefs.h.  */
24241
24242 /* pthread test headers */
24243 #include <pthread.h>
24244 #if HAVE_PTHREADS < 7
24245 #include <errno.h>
24246 #endif
24247 #ifndef NULL
24248 #define NULL (void*)0
24249 #endif
24250
24251 static void *task(p)
24252         void *p;
24253 {
24254         return (void *) (p == NULL);
24255 }
24256
24257
24258 int main(argc, argv)
24259         int argc;
24260         char **argv;
24261 {
24262
24263         /* pthread test function */
24264 #ifndef PTHREAD_CREATE_DETACHED
24265 #define PTHREAD_CREATE_DETACHED 1
24266 #endif
24267         pthread_t t;
24268         int status;
24269         int detach = PTHREAD_CREATE_DETACHED;
24270
24271 #if HAVE_PTHREADS > 4
24272         /* Final pthreads */
24273         pthread_attr_t attr;
24274
24275         status = pthread_attr_init(&attr);
24276         if( status ) return status;
24277
24278 #if HAVE_PTHREADS < 7
24279         status = pthread_attr_setdetachstate(&attr, &detach);
24280         if( status < 0 ) status = errno;
24281 #else
24282         status = pthread_attr_setdetachstate(&attr, detach);
24283 #endif
24284         if( status ) return status;
24285         status = pthread_create( &t, &attr, task, NULL );
24286 #if HAVE_PTHREADS < 7
24287         if( status < 0 ) status = errno;
24288 #endif
24289         if( status ) return status;
24290 #else
24291         /* Draft 4 pthreads */
24292         status = pthread_create( &t, pthread_attr_default, task, NULL );
24293         if( status ) return errno;
24294
24295         /* give thread a chance to complete */
24296         /* it should remain joinable and hence detachable */
24297         sleep( 1 );
24298
24299         status = pthread_detach( &t );
24300         if( status ) return errno;
24301 #endif
24302
24303 #ifdef HAVE_LINUX_THREADS
24304         pthread_kill_other_threads_np();
24305 #endif
24306
24307         return 0;
24308
24309 }
24310
24311 _ACEOF
24312 rm -f conftest$ac_exeext
24313 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24314   (eval $ac_link) 2>&5
24315   ac_status=$?
24316   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24317   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24318   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24319   (eval $ac_try) 2>&5
24320   ac_status=$?
24321   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24322   (exit $ac_status); }; }; then
24323   ol_cv_pthread_create_works=yes
24324 else
24325   echo "$as_me: program exited with status $ac_status" >&5
24326 echo "$as_me: failed program was:" >&5
24327 sed 's/^/| /' conftest.$ac_ext >&5
24328
24329 ( exit $ac_status )
24330 ol_cv_pthread_create_works=no
24331 fi
24332 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24333 fi
24334 fi
24335 echo "$as_me:$LINENO: result: $ol_cv_pthread_create_works" >&5
24336 echo "${ECHO_T}$ol_cv_pthread_create_works" >&6
24337
24338                         if test $ol_cv_pthread_create_works = no ; then
24339                                 { { echo "$as_me:$LINENO: error: pthread_create is not usable, check environment settings" >&5
24340 echo "$as_me: error: pthread_create is not usable, check environment settings" >&2;}
24341    { (exit 1); exit 1; }; }
24342                         fi
24343
24344                         ol_replace_broken_yield=no
24345
24346                         if test $ol_replace_broken_yield = yes ; then
24347
24348 cat >>confdefs.h <<\_ACEOF
24349 #define REPLACE_BROKEN_YIELD 1
24350 _ACEOF
24351
24352                         fi
24353
24354                                                 if test $ol_with_yielding_select = auto ; then
24355                                 echo "$as_me:$LINENO: checking if select yields when using pthreads" >&5
24356 echo $ECHO_N "checking if select yields when using pthreads... $ECHO_C" >&6
24357 if test "${ol_cv_pthread_select_yields+set}" = set; then
24358   echo $ECHO_N "(cached) $ECHO_C" >&6
24359 else
24360
24361                                 if test "$cross_compiling" = yes; then
24362   ol_cv_pthread_select_yields=cross
24363 else
24364   cat >conftest.$ac_ext <<_ACEOF
24365 /* confdefs.h.  */
24366 _ACEOF
24367 cat confdefs.h >>conftest.$ac_ext
24368 cat >>conftest.$ac_ext <<_ACEOF
24369 /* end confdefs.h.  */
24370
24371 #include <sys/types.h>
24372 #include <sys/time.h>
24373 #include <unistd.h>
24374 #include <pthread.h>
24375 #ifndef NULL
24376 #define NULL (void*) 0
24377 #endif
24378
24379 static int fildes[2];
24380
24381 static void *task(p)
24382         void *p;
24383 {
24384         int i;
24385         struct timeval tv;
24386
24387         fd_set rfds;
24388
24389         tv.tv_sec=10;
24390         tv.tv_usec=0;
24391
24392         FD_ZERO(&rfds);
24393         FD_SET(fildes[0], &rfds);
24394
24395         /* we're not interested in any fds */
24396         i = select(FD_SETSIZE, &rfds, NULL, NULL, &tv);
24397
24398         if(i < 0) {
24399                 perror("select");
24400                 exit(10);
24401         }
24402
24403         exit(0); /* if we exit here, the select blocked the whole process */
24404 }
24405
24406 int main(argc, argv)
24407         int argc;
24408         char **argv;
24409 {
24410         pthread_t t;
24411
24412         /* create a pipe to select */
24413         if(pipe(&fildes[0])) {
24414                 perror("select");
24415                 exit(1);
24416         }
24417
24418 #ifdef HAVE_PTHREAD_SETCONCURRENCY
24419         (void) pthread_setconcurrency(2);
24420 #else
24421 #ifdef HAVE_THR_SETCONCURRENCY
24422         /* Set Solaris LWP concurrency to 2 */
24423         thr_setconcurrency(2);
24424 #endif
24425 #endif
24426
24427 #if HAVE_PTHREADS < 6
24428         pthread_create(&t, pthread_attr_default, task, NULL);
24429 #else
24430         pthread_create(&t, NULL, task, NULL);
24431 #endif
24432
24433         /* make sure task runs first */
24434 #ifdef HAVE_THR_YIELD
24435         thr_yield();
24436 #elif defined( HAVE_SCHED_YIELD )
24437         sched_yield();
24438 #elif defined( HAVE_PTHREAD_YIELD )
24439         pthread_yield();
24440 #endif
24441
24442         exit(2);
24443 }
24444 _ACEOF
24445 rm -f conftest$ac_exeext
24446 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24447   (eval $ac_link) 2>&5
24448   ac_status=$?
24449   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24450   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24451   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24452   (eval $ac_try) 2>&5
24453   ac_status=$?
24454   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24455   (exit $ac_status); }; }; then
24456   ol_cv_pthread_select_yields=no
24457 else
24458   echo "$as_me: program exited with status $ac_status" >&5
24459 echo "$as_me: failed program was:" >&5
24460 sed 's/^/| /' conftest.$ac_ext >&5
24461
24462 ( exit $ac_status )
24463 ol_cv_pthread_select_yields=yes
24464 fi
24465 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24466 fi
24467 fi
24468 echo "$as_me:$LINENO: result: $ol_cv_pthread_select_yields" >&5
24469 echo "${ECHO_T}$ol_cv_pthread_select_yields" >&6
24470
24471                                 if test $ol_cv_pthread_select_yields = cross ; then
24472                                         { { echo "$as_me:$LINENO: error: crossing compiling: use --with-yielding_select=yes|no|manual" >&5
24473 echo "$as_me: error: crossing compiling: use --with-yielding_select=yes|no|manual" >&2;}
24474    { (exit 1); exit 1; }; }
24475                                 fi
24476
24477                                 if test $ol_cv_pthread_select_yields = yes ; then
24478                                         ol_with_yielding_select=yes
24479                                 fi
24480                         fi
24481
24482                                                 CPPFLAGS="$save_CPPFLAGS"
24483                         LIBS="$save_LIBS"
24484                 else
24485                         { { echo "$as_me:$LINENO: error: could not locate usable POSIX Threads" >&5
24486 echo "$as_me: error: could not locate usable POSIX Threads" >&2;}
24487    { (exit 1); exit 1; }; }
24488                 fi
24489         fi
24490
24491         if test $ol_with_threads = posix ; then
24492                 { { echo "$as_me:$LINENO: error: could not locate POSIX Threads" >&5
24493 echo "$as_me: error: could not locate POSIX Threads" >&2;}
24494    { (exit 1); exit 1; }; }
24495         fi
24496         ;;
24497 esac
24498
24499 case $ol_with_threads in auto | yes | mach)
24500
24501
24502
24503 for ac_header in mach/cthreads.h cthreads.h
24504 do
24505 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
24506 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24507   echo "$as_me:$LINENO: checking for $ac_header" >&5
24508 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24509 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24510   echo $ECHO_N "(cached) $ECHO_C" >&6
24511 fi
24512 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24513 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24514 else
24515   # Is the header compilable?
24516 echo "$as_me:$LINENO: checking $ac_header usability" >&5
24517 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
24518 cat >conftest.$ac_ext <<_ACEOF
24519 /* confdefs.h.  */
24520 _ACEOF
24521 cat confdefs.h >>conftest.$ac_ext
24522 cat >>conftest.$ac_ext <<_ACEOF
24523 /* end confdefs.h.  */
24524 $ac_includes_default
24525 #include <$ac_header>
24526 _ACEOF
24527 rm -f conftest.$ac_objext
24528 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
24529   (eval $ac_compile) 2>conftest.er1
24530   ac_status=$?
24531   grep -v '^ *+' conftest.er1 >conftest.err
24532   rm -f conftest.er1
24533   cat conftest.err >&5
24534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24535   (exit $ac_status); } &&
24536          { ac_try='test -z "$ac_c_werror_flag"
24537                          || test ! -s conftest.err'
24538   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24539   (eval $ac_try) 2>&5
24540   ac_status=$?
24541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24542   (exit $ac_status); }; } &&
24543          { ac_try='test -s conftest.$ac_objext'
24544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24545   (eval $ac_try) 2>&5
24546   ac_status=$?
24547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24548   (exit $ac_status); }; }; then
24549   ac_header_compiler=yes
24550 else
24551   echo "$as_me: failed program was:" >&5
24552 sed 's/^/| /' conftest.$ac_ext >&5
24553
24554 ac_header_compiler=no
24555 fi
24556 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
24557 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
24558 echo "${ECHO_T}$ac_header_compiler" >&6
24559
24560 # Is the header present?
24561 echo "$as_me:$LINENO: checking $ac_header presence" >&5
24562 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
24563 cat >conftest.$ac_ext <<_ACEOF
24564 /* confdefs.h.  */
24565 _ACEOF
24566 cat confdefs.h >>conftest.$ac_ext
24567 cat >>conftest.$ac_ext <<_ACEOF
24568 /* end confdefs.h.  */
24569 #include <$ac_header>
24570 _ACEOF
24571 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
24572   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
24573   ac_status=$?
24574   grep -v '^ *+' conftest.er1 >conftest.err
24575   rm -f conftest.er1
24576   cat conftest.err >&5
24577   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24578   (exit $ac_status); } >/dev/null; then
24579   if test -s conftest.err; then
24580     ac_cpp_err=$ac_c_preproc_warn_flag
24581     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
24582   else
24583     ac_cpp_err=
24584   fi
24585 else
24586   ac_cpp_err=yes
24587 fi
24588 if test -z "$ac_cpp_err"; then
24589   ac_header_preproc=yes
24590 else
24591   echo "$as_me: failed program was:" >&5
24592 sed 's/^/| /' conftest.$ac_ext >&5
24593
24594   ac_header_preproc=no
24595 fi
24596 rm -f conftest.err conftest.$ac_ext
24597 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
24598 echo "${ECHO_T}$ac_header_preproc" >&6
24599
24600 # So?  What about this header?
24601 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
24602   yes:no: )
24603     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
24604 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
24605     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
24606 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
24607     ac_header_preproc=yes
24608     ;;
24609   no:yes:* )
24610     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
24611 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
24612     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
24613 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
24614     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
24615 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
24616     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
24617 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
24618     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
24619 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
24620     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
24621 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
24622     (
24623       cat <<\_ASBOX
24624 ## --------------------------------------------- ##
24625 ## Report this to <http://www.openldap.org/its/> ##
24626 ## --------------------------------------------- ##
24627 _ASBOX
24628     ) |
24629       sed "s/^/$as_me: WARNING:     /" >&2
24630     ;;
24631 esac
24632 echo "$as_me:$LINENO: checking for $ac_header" >&5
24633 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24634 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24635   echo $ECHO_N "(cached) $ECHO_C" >&6
24636 else
24637   eval "$as_ac_Header=\$ac_header_preproc"
24638 fi
24639 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24640 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24641
24642 fi
24643 if test `eval echo '${'$as_ac_Header'}'` = yes; then
24644   cat >>confdefs.h <<_ACEOF
24645 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
24646 _ACEOF
24647
24648 fi
24649
24650 done
24651
24652         if test $ac_cv_header_mach_cthreads_h = yes ; then
24653                 ol_with_threads=found
24654
24655                                 echo "$as_me:$LINENO: checking for cthread_fork" >&5
24656 echo $ECHO_N "checking for cthread_fork... $ECHO_C" >&6
24657 if test "${ac_cv_func_cthread_fork+set}" = set; then
24658   echo $ECHO_N "(cached) $ECHO_C" >&6
24659 else
24660   cat >conftest.$ac_ext <<_ACEOF
24661 /* confdefs.h.  */
24662 _ACEOF
24663 cat confdefs.h >>conftest.$ac_ext
24664 cat >>conftest.$ac_ext <<_ACEOF
24665 /* end confdefs.h.  */
24666 /* Define cthread_fork to an innocuous variant, in case <limits.h> declares cthread_fork.
24667    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24668 #define cthread_fork innocuous_cthread_fork
24669
24670 /* System header to define __stub macros and hopefully few prototypes,
24671     which can conflict with char cthread_fork (); below.
24672     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24673     <limits.h> exists even on freestanding compilers.  */
24674
24675 #ifdef __STDC__
24676 # include <limits.h>
24677 #else
24678 # include <assert.h>
24679 #endif
24680
24681 #undef cthread_fork
24682
24683 /* Override any gcc2 internal prototype to avoid an error.  */
24684 #ifdef __cplusplus
24685 extern "C"
24686 {
24687 #endif
24688 /* We use char because int might match the return type of a gcc2
24689    builtin and then its argument prototype would still apply.  */
24690 char cthread_fork ();
24691 /* The GNU C library defines this for functions which it implements
24692     to always fail with ENOSYS.  Some functions are actually named
24693     something starting with __ and the normal name is an alias.  */
24694 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
24695 choke me
24696 #else
24697 char (*f) () = cthread_fork;
24698 #endif
24699 #ifdef __cplusplus
24700 }
24701 #endif
24702
24703 int
24704 main ()
24705 {
24706 return f != cthread_fork;
24707   ;
24708   return 0;
24709 }
24710 _ACEOF
24711 rm -f conftest.$ac_objext conftest$ac_exeext
24712 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24713   (eval $ac_link) 2>conftest.er1
24714   ac_status=$?
24715   grep -v '^ *+' conftest.er1 >conftest.err
24716   rm -f conftest.er1
24717   cat conftest.err >&5
24718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24719   (exit $ac_status); } &&
24720          { ac_try='test -z "$ac_c_werror_flag"
24721                          || test ! -s conftest.err'
24722   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24723   (eval $ac_try) 2>&5
24724   ac_status=$?
24725   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24726   (exit $ac_status); }; } &&
24727          { ac_try='test -s conftest$ac_exeext'
24728   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24729   (eval $ac_try) 2>&5
24730   ac_status=$?
24731   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24732   (exit $ac_status); }; }; then
24733   ac_cv_func_cthread_fork=yes
24734 else
24735   echo "$as_me: failed program was:" >&5
24736 sed 's/^/| /' conftest.$ac_ext >&5
24737
24738 ac_cv_func_cthread_fork=no
24739 fi
24740 rm -f conftest.err conftest.$ac_objext \
24741       conftest$ac_exeext conftest.$ac_ext
24742 fi
24743 echo "$as_me:$LINENO: result: $ac_cv_func_cthread_fork" >&5
24744 echo "${ECHO_T}$ac_cv_func_cthread_fork" >&6
24745 if test $ac_cv_func_cthread_fork = yes; then
24746   ol_link_threads=yes
24747 fi
24748
24749
24750                 if test $ol_link_threads = no ; then
24751                                                                         echo "$as_me:$LINENO: checking for cthread_fork with -all_load" >&5
24752 echo $ECHO_N "checking for cthread_fork with -all_load... $ECHO_C" >&6
24753 if test "${ol_cv_cthread_all_load+set}" = set; then
24754   echo $ECHO_N "(cached) $ECHO_C" >&6
24755 else
24756
24757                                                                 save_LIBS="$LIBS"
24758                                 LIBS="-all_load $LIBS"
24759                                 cat >conftest.$ac_ext <<_ACEOF
24760 /* confdefs.h.  */
24761 _ACEOF
24762 cat confdefs.h >>conftest.$ac_ext
24763 cat >>conftest.$ac_ext <<_ACEOF
24764 /* end confdefs.h.  */
24765 #include <mach/cthreads.h>
24766 int
24767 main ()
24768 {
24769
24770                                         cthread_fork((void *)0, (void *)0);
24771
24772   ;
24773   return 0;
24774 }
24775 _ACEOF
24776 rm -f conftest.$ac_objext conftest$ac_exeext
24777 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24778   (eval $ac_link) 2>conftest.er1
24779   ac_status=$?
24780   grep -v '^ *+' conftest.er1 >conftest.err
24781   rm -f conftest.er1
24782   cat conftest.err >&5
24783   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24784   (exit $ac_status); } &&
24785          { ac_try='test -z "$ac_c_werror_flag"
24786                          || test ! -s conftest.err'
24787   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24788   (eval $ac_try) 2>&5
24789   ac_status=$?
24790   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24791   (exit $ac_status); }; } &&
24792          { ac_try='test -s conftest$ac_exeext'
24793   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24794   (eval $ac_try) 2>&5
24795   ac_status=$?
24796   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24797   (exit $ac_status); }; }; then
24798   ol_cv_cthread_all_load=yes
24799 else
24800   echo "$as_me: failed program was:" >&5
24801 sed 's/^/| /' conftest.$ac_ext >&5
24802
24803 ol_cv_cthread_all_load=no
24804 fi
24805 rm -f conftest.err conftest.$ac_objext \
24806       conftest$ac_exeext conftest.$ac_ext
24807                                                                 LIBS="$save_LIBS"
24808
24809 fi
24810 echo "$as_me:$LINENO: result: $ol_cv_cthread_all_load" >&5
24811 echo "${ECHO_T}$ol_cv_cthread_all_load" >&6
24812
24813                         if test $ol_cv_cthread_all_load = yes ; then
24814                                 LTHREAD_LIBS="$LTHREAD_LIBS -all_load"
24815                                 ol_link_threads=mach
24816                                 ol_with_threads=found
24817                         fi
24818                 fi
24819
24820         elif test $ac_cv_header_cthreads_h = yes ; then
24821
24822                 ol_with_threads=found
24823
24824                                 save_LIBS="$LIBS"
24825                 LIBS="$LIBS -lthreads"
24826                 echo "$as_me:$LINENO: checking for cthread_fork" >&5
24827 echo $ECHO_N "checking for cthread_fork... $ECHO_C" >&6
24828 if test "${ac_cv_func_cthread_fork+set}" = set; then
24829   echo $ECHO_N "(cached) $ECHO_C" >&6
24830 else
24831   cat >conftest.$ac_ext <<_ACEOF
24832 /* confdefs.h.  */
24833 _ACEOF
24834 cat confdefs.h >>conftest.$ac_ext
24835 cat >>conftest.$ac_ext <<_ACEOF
24836 /* end confdefs.h.  */
24837 /* Define cthread_fork to an innocuous variant, in case <limits.h> declares cthread_fork.
24838    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24839 #define cthread_fork innocuous_cthread_fork
24840
24841 /* System header to define __stub macros and hopefully few prototypes,
24842     which can conflict with char cthread_fork (); below.
24843     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24844     <limits.h> exists even on freestanding compilers.  */
24845
24846 #ifdef __STDC__
24847 # include <limits.h>
24848 #else
24849 # include <assert.h>
24850 #endif
24851
24852 #undef cthread_fork
24853
24854 /* Override any gcc2 internal prototype to avoid an error.  */
24855 #ifdef __cplusplus
24856 extern "C"
24857 {
24858 #endif
24859 /* We use char because int might match the return type of a gcc2
24860    builtin and then its argument prototype would still apply.  */
24861 char cthread_fork ();
24862 /* The GNU C library defines this for functions which it implements
24863     to always fail with ENOSYS.  Some functions are actually named
24864     something starting with __ and the normal name is an alias.  */
24865 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
24866 choke me
24867 #else
24868 char (*f) () = cthread_fork;
24869 #endif
24870 #ifdef __cplusplus
24871 }
24872 #endif
24873
24874 int
24875 main ()
24876 {
24877 return f != cthread_fork;
24878   ;
24879   return 0;
24880 }
24881 _ACEOF
24882 rm -f conftest.$ac_objext conftest$ac_exeext
24883 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24884   (eval $ac_link) 2>conftest.er1
24885   ac_status=$?
24886   grep -v '^ *+' conftest.er1 >conftest.err
24887   rm -f conftest.er1
24888   cat conftest.err >&5
24889   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24890   (exit $ac_status); } &&
24891          { ac_try='test -z "$ac_c_werror_flag"
24892                          || test ! -s conftest.err'
24893   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24894   (eval $ac_try) 2>&5
24895   ac_status=$?
24896   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24897   (exit $ac_status); }; } &&
24898          { ac_try='test -s conftest$ac_exeext'
24899   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24900   (eval $ac_try) 2>&5
24901   ac_status=$?
24902   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24903   (exit $ac_status); }; }; then
24904   ac_cv_func_cthread_fork=yes
24905 else
24906   echo "$as_me: failed program was:" >&5
24907 sed 's/^/| /' conftest.$ac_ext >&5
24908
24909 ac_cv_func_cthread_fork=no
24910 fi
24911 rm -f conftest.err conftest.$ac_objext \
24912       conftest$ac_exeext conftest.$ac_ext
24913 fi
24914 echo "$as_me:$LINENO: result: $ac_cv_func_cthread_fork" >&5
24915 echo "${ECHO_T}$ac_cv_func_cthread_fork" >&6
24916 if test $ac_cv_func_cthread_fork = yes; then
24917   ol_link_threads=yes
24918 fi
24919
24920                 LIBS="$save_LIBS"
24921
24922                 if test $ol_link_threads = yes ; then
24923                         LTHREAD_LIBS="-lthreads"
24924                         ol_link_threads=mach
24925                         ol_with_threads=found
24926                 else
24927                         { { echo "$as_me:$LINENO: error: could not link with Mach CThreads" >&5
24928 echo "$as_me: error: could not link with Mach CThreads" >&2;}
24929    { (exit 1); exit 1; }; }
24930                 fi
24931
24932         elif test $ol_with_threads = mach ; then
24933                 { { echo "$as_me:$LINENO: error: could not locate Mach CThreads" >&5
24934 echo "$as_me: error: could not locate Mach CThreads" >&2;}
24935    { (exit 1); exit 1; }; }
24936         fi
24937
24938         if test $ol_link_threads = mach ; then
24939
24940 cat >>confdefs.h <<\_ACEOF
24941 #define HAVE_MACH_CTHREADS 1
24942 _ACEOF
24943
24944         elif test $ol_with_threads = found ; then
24945                 { { echo "$as_me:$LINENO: error: could not link with Mach CThreads" >&5
24946 echo "$as_me: error: could not link with Mach CThreads" >&2;}
24947    { (exit 1); exit 1; }; }
24948         fi
24949         ;;
24950 esac
24951
24952 case $ol_with_threads in auto | yes | pth)
24953
24954
24955 for ac_header in pth.h
24956 do
24957 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
24958 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24959   echo "$as_me:$LINENO: checking for $ac_header" >&5
24960 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24961 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24962   echo $ECHO_N "(cached) $ECHO_C" >&6
24963 fi
24964 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24965 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24966 else
24967   # Is the header compilable?
24968 echo "$as_me:$LINENO: checking $ac_header usability" >&5
24969 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
24970 cat >conftest.$ac_ext <<_ACEOF
24971 /* confdefs.h.  */
24972 _ACEOF
24973 cat confdefs.h >>conftest.$ac_ext
24974 cat >>conftest.$ac_ext <<_ACEOF
24975 /* end confdefs.h.  */
24976 $ac_includes_default
24977 #include <$ac_header>
24978 _ACEOF
24979 rm -f conftest.$ac_objext
24980 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
24981   (eval $ac_compile) 2>conftest.er1
24982   ac_status=$?
24983   grep -v '^ *+' conftest.er1 >conftest.err
24984   rm -f conftest.er1
24985   cat conftest.err >&5
24986   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24987   (exit $ac_status); } &&
24988          { ac_try='test -z "$ac_c_werror_flag"
24989                          || test ! -s conftest.err'
24990   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24991   (eval $ac_try) 2>&5
24992   ac_status=$?
24993   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24994   (exit $ac_status); }; } &&
24995          { ac_try='test -s conftest.$ac_objext'
24996   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24997   (eval $ac_try) 2>&5
24998   ac_status=$?
24999   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25000   (exit $ac_status); }; }; then
25001   ac_header_compiler=yes
25002 else
25003   echo "$as_me: failed program was:" >&5
25004 sed 's/^/| /' conftest.$ac_ext >&5
25005
25006 ac_header_compiler=no
25007 fi
25008 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
25009 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25010 echo "${ECHO_T}$ac_header_compiler" >&6
25011
25012 # Is the header present?
25013 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25014 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25015 cat >conftest.$ac_ext <<_ACEOF
25016 /* confdefs.h.  */
25017 _ACEOF
25018 cat confdefs.h >>conftest.$ac_ext
25019 cat >>conftest.$ac_ext <<_ACEOF
25020 /* end confdefs.h.  */
25021 #include <$ac_header>
25022 _ACEOF
25023 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25024   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25025   ac_status=$?
25026   grep -v '^ *+' conftest.er1 >conftest.err
25027   rm -f conftest.er1
25028   cat conftest.err >&5
25029   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25030   (exit $ac_status); } >/dev/null; then
25031   if test -s conftest.err; then
25032     ac_cpp_err=$ac_c_preproc_warn_flag
25033     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25034   else
25035     ac_cpp_err=
25036   fi
25037 else
25038   ac_cpp_err=yes
25039 fi
25040 if test -z "$ac_cpp_err"; then
25041   ac_header_preproc=yes
25042 else
25043   echo "$as_me: failed program was:" >&5
25044 sed 's/^/| /' conftest.$ac_ext >&5
25045
25046   ac_header_preproc=no
25047 fi
25048 rm -f conftest.err conftest.$ac_ext
25049 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25050 echo "${ECHO_T}$ac_header_preproc" >&6
25051
25052 # So?  What about this header?
25053 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25054   yes:no: )
25055     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25056 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25057     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25058 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25059     ac_header_preproc=yes
25060     ;;
25061   no:yes:* )
25062     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25063 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25064     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25065 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25066     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25067 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25068     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25069 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25070     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25071 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25072     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25073 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25074     (
25075       cat <<\_ASBOX
25076 ## --------------------------------------------- ##
25077 ## Report this to <http://www.openldap.org/its/> ##
25078 ## --------------------------------------------- ##
25079 _ASBOX
25080     ) |
25081       sed "s/^/$as_me: WARNING:     /" >&2
25082     ;;
25083 esac
25084 echo "$as_me:$LINENO: checking for $ac_header" >&5
25085 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25086 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25087   echo $ECHO_N "(cached) $ECHO_C" >&6
25088 else
25089   eval "$as_ac_Header=\$ac_header_preproc"
25090 fi
25091 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25092 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25093
25094 fi
25095 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25096   cat >>confdefs.h <<_ACEOF
25097 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25098 _ACEOF
25099
25100 fi
25101
25102 done
25103
25104
25105         if test $ac_cv_header_pth_h = yes ; then
25106                 echo "$as_me:$LINENO: checking for pth_version in -lpth" >&5
25107 echo $ECHO_N "checking for pth_version in -lpth... $ECHO_C" >&6
25108 if test "${ac_cv_lib_pth_pth_version+set}" = set; then
25109   echo $ECHO_N "(cached) $ECHO_C" >&6
25110 else
25111   ac_check_lib_save_LIBS=$LIBS
25112 LIBS="-lpth  $LIBS"
25113 cat >conftest.$ac_ext <<_ACEOF
25114 /* confdefs.h.  */
25115 _ACEOF
25116 cat confdefs.h >>conftest.$ac_ext
25117 cat >>conftest.$ac_ext <<_ACEOF
25118 /* end confdefs.h.  */
25119
25120 /* Override any gcc2 internal prototype to avoid an error.  */
25121 #ifdef __cplusplus
25122 extern "C"
25123 #endif
25124 /* We use char because int might match the return type of a gcc2
25125    builtin and then its argument prototype would still apply.  */
25126 char pth_version ();
25127 int
25128 main ()
25129 {
25130 pth_version ();
25131   ;
25132   return 0;
25133 }
25134 _ACEOF
25135 rm -f conftest.$ac_objext conftest$ac_exeext
25136 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25137   (eval $ac_link) 2>conftest.er1
25138   ac_status=$?
25139   grep -v '^ *+' conftest.er1 >conftest.err
25140   rm -f conftest.er1
25141   cat conftest.err >&5
25142   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25143   (exit $ac_status); } &&
25144          { ac_try='test -z "$ac_c_werror_flag"
25145                          || test ! -s conftest.err'
25146   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25147   (eval $ac_try) 2>&5
25148   ac_status=$?
25149   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25150   (exit $ac_status); }; } &&
25151          { ac_try='test -s conftest$ac_exeext'
25152   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25153   (eval $ac_try) 2>&5
25154   ac_status=$?
25155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25156   (exit $ac_status); }; }; then
25157   ac_cv_lib_pth_pth_version=yes
25158 else
25159   echo "$as_me: failed program was:" >&5
25160 sed 's/^/| /' conftest.$ac_ext >&5
25161
25162 ac_cv_lib_pth_pth_version=no
25163 fi
25164 rm -f conftest.err conftest.$ac_objext \
25165       conftest$ac_exeext conftest.$ac_ext
25166 LIBS=$ac_check_lib_save_LIBS
25167 fi
25168 echo "$as_me:$LINENO: result: $ac_cv_lib_pth_pth_version" >&5
25169 echo "${ECHO_T}$ac_cv_lib_pth_pth_version" >&6
25170 if test $ac_cv_lib_pth_pth_version = yes; then
25171   have_pth=yes
25172 else
25173   have_pth=no
25174 fi
25175
25176
25177                 if test $have_pth = yes ; then
25178
25179 cat >>confdefs.h <<\_ACEOF
25180 #define HAVE_GNU_PTH 1
25181 _ACEOF
25182
25183                         LTHREAD_LIBS="$LTHREAD_LIBS -lpth"
25184                         ol_link_threads=pth
25185                         ol_with_threads=found
25186
25187                         if test $ol_with_yielding_select = auto ; then
25188                                 ol_with_yielding_select=yes
25189                         fi
25190                 fi
25191         fi
25192         ;;
25193 esac
25194
25195 case $ol_with_threads in auto | yes | lwp)
25196
25197
25198
25199 for ac_header in thread.h synch.h
25200 do
25201 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25202 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25203   echo "$as_me:$LINENO: checking for $ac_header" >&5
25204 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25205 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25206   echo $ECHO_N "(cached) $ECHO_C" >&6
25207 fi
25208 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25209 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25210 else
25211   # Is the header compilable?
25212 echo "$as_me:$LINENO: checking $ac_header usability" >&5
25213 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
25214 cat >conftest.$ac_ext <<_ACEOF
25215 /* confdefs.h.  */
25216 _ACEOF
25217 cat confdefs.h >>conftest.$ac_ext
25218 cat >>conftest.$ac_ext <<_ACEOF
25219 /* end confdefs.h.  */
25220 $ac_includes_default
25221 #include <$ac_header>
25222 _ACEOF
25223 rm -f conftest.$ac_objext
25224 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
25225   (eval $ac_compile) 2>conftest.er1
25226   ac_status=$?
25227   grep -v '^ *+' conftest.er1 >conftest.err
25228   rm -f conftest.er1
25229   cat conftest.err >&5
25230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25231   (exit $ac_status); } &&
25232          { ac_try='test -z "$ac_c_werror_flag"
25233                          || test ! -s conftest.err'
25234   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25235   (eval $ac_try) 2>&5
25236   ac_status=$?
25237   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25238   (exit $ac_status); }; } &&
25239          { ac_try='test -s conftest.$ac_objext'
25240   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25241   (eval $ac_try) 2>&5
25242   ac_status=$?
25243   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25244   (exit $ac_status); }; }; then
25245   ac_header_compiler=yes
25246 else
25247   echo "$as_me: failed program was:" >&5
25248 sed 's/^/| /' conftest.$ac_ext >&5
25249
25250 ac_header_compiler=no
25251 fi
25252 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
25253 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25254 echo "${ECHO_T}$ac_header_compiler" >&6
25255
25256 # Is the header present?
25257 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25258 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25259 cat >conftest.$ac_ext <<_ACEOF
25260 /* confdefs.h.  */
25261 _ACEOF
25262 cat confdefs.h >>conftest.$ac_ext
25263 cat >>conftest.$ac_ext <<_ACEOF
25264 /* end confdefs.h.  */
25265 #include <$ac_header>
25266 _ACEOF
25267 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25268   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25269   ac_status=$?
25270   grep -v '^ *+' conftest.er1 >conftest.err
25271   rm -f conftest.er1
25272   cat conftest.err >&5
25273   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25274   (exit $ac_status); } >/dev/null; then
25275   if test -s conftest.err; then
25276     ac_cpp_err=$ac_c_preproc_warn_flag
25277     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25278   else
25279     ac_cpp_err=
25280   fi
25281 else
25282   ac_cpp_err=yes
25283 fi
25284 if test -z "$ac_cpp_err"; then
25285   ac_header_preproc=yes
25286 else
25287   echo "$as_me: failed program was:" >&5
25288 sed 's/^/| /' conftest.$ac_ext >&5
25289
25290   ac_header_preproc=no
25291 fi
25292 rm -f conftest.err conftest.$ac_ext
25293 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25294 echo "${ECHO_T}$ac_header_preproc" >&6
25295
25296 # So?  What about this header?
25297 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25298   yes:no: )
25299     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25300 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25301     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25302 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25303     ac_header_preproc=yes
25304     ;;
25305   no:yes:* )
25306     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25307 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25308     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25309 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25310     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25311 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25312     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25313 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25314     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25315 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25316     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25317 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25318     (
25319       cat <<\_ASBOX
25320 ## --------------------------------------------- ##
25321 ## Report this to <http://www.openldap.org/its/> ##
25322 ## --------------------------------------------- ##
25323 _ASBOX
25324     ) |
25325       sed "s/^/$as_me: WARNING:     /" >&2
25326     ;;
25327 esac
25328 echo "$as_me:$LINENO: checking for $ac_header" >&5
25329 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25330 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25331   echo $ECHO_N "(cached) $ECHO_C" >&6
25332 else
25333   eval "$as_ac_Header=\$ac_header_preproc"
25334 fi
25335 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25336 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25337
25338 fi
25339 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25340   cat >>confdefs.h <<_ACEOF
25341 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25342 _ACEOF
25343
25344 fi
25345
25346 done
25347
25348         if test $ac_cv_header_thread_h = yes &&
25349            test $ac_cv_header_synch_h = yes ; then
25350                 echo "$as_me:$LINENO: checking for thr_create in -lthread" >&5
25351 echo $ECHO_N "checking for thr_create in -lthread... $ECHO_C" >&6
25352 if test "${ac_cv_lib_thread_thr_create+set}" = set; then
25353   echo $ECHO_N "(cached) $ECHO_C" >&6
25354 else
25355   ac_check_lib_save_LIBS=$LIBS
25356 LIBS="-lthread  $LIBS"
25357 cat >conftest.$ac_ext <<_ACEOF
25358 /* confdefs.h.  */
25359 _ACEOF
25360 cat confdefs.h >>conftest.$ac_ext
25361 cat >>conftest.$ac_ext <<_ACEOF
25362 /* end confdefs.h.  */
25363
25364 /* Override any gcc2 internal prototype to avoid an error.  */
25365 #ifdef __cplusplus
25366 extern "C"
25367 #endif
25368 /* We use char because int might match the return type of a gcc2
25369    builtin and then its argument prototype would still apply.  */
25370 char thr_create ();
25371 int
25372 main ()
25373 {
25374 thr_create ();
25375   ;
25376   return 0;
25377 }
25378 _ACEOF
25379 rm -f conftest.$ac_objext conftest$ac_exeext
25380 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25381   (eval $ac_link) 2>conftest.er1
25382   ac_status=$?
25383   grep -v '^ *+' conftest.er1 >conftest.err
25384   rm -f conftest.er1
25385   cat conftest.err >&5
25386   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25387   (exit $ac_status); } &&
25388          { ac_try='test -z "$ac_c_werror_flag"
25389                          || test ! -s conftest.err'
25390   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25391   (eval $ac_try) 2>&5
25392   ac_status=$?
25393   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25394   (exit $ac_status); }; } &&
25395          { ac_try='test -s conftest$ac_exeext'
25396   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25397   (eval $ac_try) 2>&5
25398   ac_status=$?
25399   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25400   (exit $ac_status); }; }; then
25401   ac_cv_lib_thread_thr_create=yes
25402 else
25403   echo "$as_me: failed program was:" >&5
25404 sed 's/^/| /' conftest.$ac_ext >&5
25405
25406 ac_cv_lib_thread_thr_create=no
25407 fi
25408 rm -f conftest.err conftest.$ac_objext \
25409       conftest$ac_exeext conftest.$ac_ext
25410 LIBS=$ac_check_lib_save_LIBS
25411 fi
25412 echo "$as_me:$LINENO: result: $ac_cv_lib_thread_thr_create" >&5
25413 echo "${ECHO_T}$ac_cv_lib_thread_thr_create" >&6
25414 if test $ac_cv_lib_thread_thr_create = yes; then
25415   have_thr=yes
25416 else
25417   have_thr=no
25418 fi
25419
25420
25421                 if test $have_thr = yes ; then
25422
25423 cat >>confdefs.h <<\_ACEOF
25424 #define HAVE_THR 1
25425 _ACEOF
25426
25427                         LTHREAD_LIBS="$LTHREAD_LIBS -lthread"
25428                         ol_link_threads=thr
25429
25430                         if test $ol_with_yielding_select = auto ; then
25431                                 ol_with_yielding_select=yes
25432                         fi
25433
25434
25435
25436 for ac_func in \
25437                                 thr_setconcurrency \
25438                                 thr_getconcurrency \
25439
25440 do
25441 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
25442 echo "$as_me:$LINENO: checking for $ac_func" >&5
25443 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
25444 if eval "test \"\${$as_ac_var+set}\" = set"; then
25445   echo $ECHO_N "(cached) $ECHO_C" >&6
25446 else
25447   cat >conftest.$ac_ext <<_ACEOF
25448 /* confdefs.h.  */
25449 _ACEOF
25450 cat confdefs.h >>conftest.$ac_ext
25451 cat >>conftest.$ac_ext <<_ACEOF
25452 /* end confdefs.h.  */
25453 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
25454    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
25455 #define $ac_func innocuous_$ac_func
25456
25457 /* System header to define __stub macros and hopefully few prototypes,
25458     which can conflict with char $ac_func (); below.
25459     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
25460     <limits.h> exists even on freestanding compilers.  */
25461
25462 #ifdef __STDC__
25463 # include <limits.h>
25464 #else
25465 # include <assert.h>
25466 #endif
25467
25468 #undef $ac_func
25469
25470 /* Override any gcc2 internal prototype to avoid an error.  */
25471 #ifdef __cplusplus
25472 extern "C"
25473 {
25474 #endif
25475 /* We use char because int might match the return type of a gcc2
25476    builtin and then its argument prototype would still apply.  */
25477 char $ac_func ();
25478 /* The GNU C library defines this for functions which it implements
25479     to always fail with ENOSYS.  Some functions are actually named
25480     something starting with __ and the normal name is an alias.  */
25481 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
25482 choke me
25483 #else
25484 char (*f) () = $ac_func;
25485 #endif
25486 #ifdef __cplusplus
25487 }
25488 #endif
25489
25490 int
25491 main ()
25492 {
25493 return f != $ac_func;
25494   ;
25495   return 0;
25496 }
25497 _ACEOF
25498 rm -f conftest.$ac_objext conftest$ac_exeext
25499 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25500   (eval $ac_link) 2>conftest.er1
25501   ac_status=$?
25502   grep -v '^ *+' conftest.er1 >conftest.err
25503   rm -f conftest.er1
25504   cat conftest.err >&5
25505   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25506   (exit $ac_status); } &&
25507          { ac_try='test -z "$ac_c_werror_flag"
25508                          || test ! -s conftest.err'
25509   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25510   (eval $ac_try) 2>&5
25511   ac_status=$?
25512   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25513   (exit $ac_status); }; } &&
25514          { ac_try='test -s conftest$ac_exeext'
25515   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25516   (eval $ac_try) 2>&5
25517   ac_status=$?
25518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25519   (exit $ac_status); }; }; then
25520   eval "$as_ac_var=yes"
25521 else
25522   echo "$as_me: failed program was:" >&5
25523 sed 's/^/| /' conftest.$ac_ext >&5
25524
25525 eval "$as_ac_var=no"
25526 fi
25527 rm -f conftest.err conftest.$ac_objext \
25528       conftest$ac_exeext conftest.$ac_ext
25529 fi
25530 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
25531 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
25532 if test `eval echo '${'$as_ac_var'}'` = yes; then
25533   cat >>confdefs.h <<_ACEOF
25534 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
25535 _ACEOF
25536
25537 fi
25538 done
25539
25540                 fi
25541         fi
25542
25543
25544 for ac_header in lwp/lwp.h
25545 do
25546 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25547 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25548   echo "$as_me:$LINENO: checking for $ac_header" >&5
25549 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25550 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25551   echo $ECHO_N "(cached) $ECHO_C" >&6
25552 fi
25553 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25554 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25555 else
25556   # Is the header compilable?
25557 echo "$as_me:$LINENO: checking $ac_header usability" >&5
25558 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
25559 cat >conftest.$ac_ext <<_ACEOF
25560 /* confdefs.h.  */
25561 _ACEOF
25562 cat confdefs.h >>conftest.$ac_ext
25563 cat >>conftest.$ac_ext <<_ACEOF
25564 /* end confdefs.h.  */
25565 $ac_includes_default
25566 #include <$ac_header>
25567 _ACEOF
25568 rm -f conftest.$ac_objext
25569 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
25570   (eval $ac_compile) 2>conftest.er1
25571   ac_status=$?
25572   grep -v '^ *+' conftest.er1 >conftest.err
25573   rm -f conftest.er1
25574   cat conftest.err >&5
25575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25576   (exit $ac_status); } &&
25577          { ac_try='test -z "$ac_c_werror_flag"
25578                          || test ! -s conftest.err'
25579   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25580   (eval $ac_try) 2>&5
25581   ac_status=$?
25582   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25583   (exit $ac_status); }; } &&
25584          { ac_try='test -s conftest.$ac_objext'
25585   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25586   (eval $ac_try) 2>&5
25587   ac_status=$?
25588   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25589   (exit $ac_status); }; }; then
25590   ac_header_compiler=yes
25591 else
25592   echo "$as_me: failed program was:" >&5
25593 sed 's/^/| /' conftest.$ac_ext >&5
25594
25595 ac_header_compiler=no
25596 fi
25597 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
25598 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25599 echo "${ECHO_T}$ac_header_compiler" >&6
25600
25601 # Is the header present?
25602 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25603 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25604 cat >conftest.$ac_ext <<_ACEOF
25605 /* confdefs.h.  */
25606 _ACEOF
25607 cat confdefs.h >>conftest.$ac_ext
25608 cat >>conftest.$ac_ext <<_ACEOF
25609 /* end confdefs.h.  */
25610 #include <$ac_header>
25611 _ACEOF
25612 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25613   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25614   ac_status=$?
25615   grep -v '^ *+' conftest.er1 >conftest.err
25616   rm -f conftest.er1
25617   cat conftest.err >&5
25618   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25619   (exit $ac_status); } >/dev/null; then
25620   if test -s conftest.err; then
25621     ac_cpp_err=$ac_c_preproc_warn_flag
25622     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25623   else
25624     ac_cpp_err=
25625   fi
25626 else
25627   ac_cpp_err=yes
25628 fi
25629 if test -z "$ac_cpp_err"; then
25630   ac_header_preproc=yes
25631 else
25632   echo "$as_me: failed program was:" >&5
25633 sed 's/^/| /' conftest.$ac_ext >&5
25634
25635   ac_header_preproc=no
25636 fi
25637 rm -f conftest.err conftest.$ac_ext
25638 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25639 echo "${ECHO_T}$ac_header_preproc" >&6
25640
25641 # So?  What about this header?
25642 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25643   yes:no: )
25644     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25645 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25646     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25647 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25648     ac_header_preproc=yes
25649     ;;
25650   no:yes:* )
25651     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25652 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25653     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25654 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25655     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25656 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25657     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25658 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25659     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25660 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25661     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25662 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25663     (
25664       cat <<\_ASBOX
25665 ## --------------------------------------------- ##
25666 ## Report this to <http://www.openldap.org/its/> ##
25667 ## --------------------------------------------- ##
25668 _ASBOX
25669     ) |
25670       sed "s/^/$as_me: WARNING:     /" >&2
25671     ;;
25672 esac
25673 echo "$as_me:$LINENO: checking for $ac_header" >&5
25674 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25675 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25676   echo $ECHO_N "(cached) $ECHO_C" >&6
25677 else
25678   eval "$as_ac_Header=\$ac_header_preproc"
25679 fi
25680 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25681 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25682
25683 fi
25684 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25685   cat >>confdefs.h <<_ACEOF
25686 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25687 _ACEOF
25688
25689 fi
25690
25691 done
25692
25693         if test $ac_cv_header_lwp_lwp_h = yes ; then
25694                 echo "$as_me:$LINENO: checking for lwp_create in -llwp" >&5
25695 echo $ECHO_N "checking for lwp_create in -llwp... $ECHO_C" >&6
25696 if test "${ac_cv_lib_lwp_lwp_create+set}" = set; then
25697   echo $ECHO_N "(cached) $ECHO_C" >&6
25698 else
25699   ac_check_lib_save_LIBS=$LIBS
25700 LIBS="-llwp  $LIBS"
25701 cat >conftest.$ac_ext <<_ACEOF
25702 /* confdefs.h.  */
25703 _ACEOF
25704 cat confdefs.h >>conftest.$ac_ext
25705 cat >>conftest.$ac_ext <<_ACEOF
25706 /* end confdefs.h.  */
25707
25708 /* Override any gcc2 internal prototype to avoid an error.  */
25709 #ifdef __cplusplus
25710 extern "C"
25711 #endif
25712 /* We use char because int might match the return type of a gcc2
25713    builtin and then its argument prototype would still apply.  */
25714 char lwp_create ();
25715 int
25716 main ()
25717 {
25718 lwp_create ();
25719   ;
25720   return 0;
25721 }
25722 _ACEOF
25723 rm -f conftest.$ac_objext conftest$ac_exeext
25724 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25725   (eval $ac_link) 2>conftest.er1
25726   ac_status=$?
25727   grep -v '^ *+' conftest.er1 >conftest.err
25728   rm -f conftest.er1
25729   cat conftest.err >&5
25730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25731   (exit $ac_status); } &&
25732          { ac_try='test -z "$ac_c_werror_flag"
25733                          || test ! -s conftest.err'
25734   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25735   (eval $ac_try) 2>&5
25736   ac_status=$?
25737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25738   (exit $ac_status); }; } &&
25739          { ac_try='test -s conftest$ac_exeext'
25740   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25741   (eval $ac_try) 2>&5
25742   ac_status=$?
25743   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25744   (exit $ac_status); }; }; then
25745   ac_cv_lib_lwp_lwp_create=yes
25746 else
25747   echo "$as_me: failed program was:" >&5
25748 sed 's/^/| /' conftest.$ac_ext >&5
25749
25750 ac_cv_lib_lwp_lwp_create=no
25751 fi
25752 rm -f conftest.err conftest.$ac_objext \
25753       conftest$ac_exeext conftest.$ac_ext
25754 LIBS=$ac_check_lib_save_LIBS
25755 fi
25756 echo "$as_me:$LINENO: result: $ac_cv_lib_lwp_lwp_create" >&5
25757 echo "${ECHO_T}$ac_cv_lib_lwp_lwp_create" >&6
25758 if test $ac_cv_lib_lwp_lwp_create = yes; then
25759   have_lwp=yes
25760 else
25761   have_lwp=no
25762 fi
25763
25764
25765                 if test $have_lwp = yes ; then
25766
25767 cat >>confdefs.h <<\_ACEOF
25768 #define HAVE_LWP 1
25769 _ACEOF
25770
25771                         LTHREAD_LIBS="$LTHREAD_LIBS -llwp"
25772                         ol_link_threads=lwp
25773
25774                         if test $ol_with_yielding_select = auto ; then
25775                                 ol_with_yielding_select=no
25776                         fi
25777                 fi
25778         fi
25779         ;;
25780 esac
25781
25782 if test $ol_with_yielding_select = yes ; then
25783
25784 cat >>confdefs.h <<\_ACEOF
25785 #define HAVE_YIELDING_SELECT 1
25786 _ACEOF
25787
25788 fi
25789
25790 if test $ol_with_threads = manual ; then
25791                 ol_link_threads=yes
25792
25793         { echo "$as_me:$LINENO: WARNING: thread defines and link options must be set manually" >&5
25794 echo "$as_me: WARNING: thread defines and link options must be set manually" >&2;}
25795
25796
25797
25798 for ac_header in pthread.h sched.h
25799 do
25800 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25801 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25802   echo "$as_me:$LINENO: checking for $ac_header" >&5
25803 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25804 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25805   echo $ECHO_N "(cached) $ECHO_C" >&6
25806 fi
25807 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25808 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25809 else
25810   # Is the header compilable?
25811 echo "$as_me:$LINENO: checking $ac_header usability" >&5
25812 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
25813 cat >conftest.$ac_ext <<_ACEOF
25814 /* confdefs.h.  */
25815 _ACEOF
25816 cat confdefs.h >>conftest.$ac_ext
25817 cat >>conftest.$ac_ext <<_ACEOF
25818 /* end confdefs.h.  */
25819 $ac_includes_default
25820 #include <$ac_header>
25821 _ACEOF
25822 rm -f conftest.$ac_objext
25823 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
25824   (eval $ac_compile) 2>conftest.er1
25825   ac_status=$?
25826   grep -v '^ *+' conftest.er1 >conftest.err
25827   rm -f conftest.er1
25828   cat conftest.err >&5
25829   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25830   (exit $ac_status); } &&
25831          { ac_try='test -z "$ac_c_werror_flag"
25832                          || test ! -s conftest.err'
25833   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25834   (eval $ac_try) 2>&5
25835   ac_status=$?
25836   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25837   (exit $ac_status); }; } &&
25838          { ac_try='test -s conftest.$ac_objext'
25839   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25840   (eval $ac_try) 2>&5
25841   ac_status=$?
25842   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25843   (exit $ac_status); }; }; then
25844   ac_header_compiler=yes
25845 else
25846   echo "$as_me: failed program was:" >&5
25847 sed 's/^/| /' conftest.$ac_ext >&5
25848
25849 ac_header_compiler=no
25850 fi
25851 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
25852 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25853 echo "${ECHO_T}$ac_header_compiler" >&6
25854
25855 # Is the header present?
25856 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25857 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25858 cat >conftest.$ac_ext <<_ACEOF
25859 /* confdefs.h.  */
25860 _ACEOF
25861 cat confdefs.h >>conftest.$ac_ext
25862 cat >>conftest.$ac_ext <<_ACEOF
25863 /* end confdefs.h.  */
25864 #include <$ac_header>
25865 _ACEOF
25866 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25867   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25868   ac_status=$?
25869   grep -v '^ *+' conftest.er1 >conftest.err
25870   rm -f conftest.er1
25871   cat conftest.err >&5
25872   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25873   (exit $ac_status); } >/dev/null; then
25874   if test -s conftest.err; then
25875     ac_cpp_err=$ac_c_preproc_warn_flag
25876     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25877   else
25878     ac_cpp_err=
25879   fi
25880 else
25881   ac_cpp_err=yes
25882 fi
25883 if test -z "$ac_cpp_err"; then
25884   ac_header_preproc=yes
25885 else
25886   echo "$as_me: failed program was:" >&5
25887 sed 's/^/| /' conftest.$ac_ext >&5
25888
25889   ac_header_preproc=no
25890 fi
25891 rm -f conftest.err conftest.$ac_ext
25892 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25893 echo "${ECHO_T}$ac_header_preproc" >&6
25894
25895 # So?  What about this header?
25896 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25897   yes:no: )
25898     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25899 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25900     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25901 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25902     ac_header_preproc=yes
25903     ;;
25904   no:yes:* )
25905     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25906 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25907     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25908 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25909     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25910 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25911     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25912 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25913     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25914 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25915     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25916 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25917     (
25918       cat <<\_ASBOX
25919 ## --------------------------------------------- ##
25920 ## Report this to <http://www.openldap.org/its/> ##
25921 ## --------------------------------------------- ##
25922 _ASBOX
25923     ) |
25924       sed "s/^/$as_me: WARNING:     /" >&2
25925     ;;
25926 esac
25927 echo "$as_me:$LINENO: checking for $ac_header" >&5
25928 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25929 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25930   echo $ECHO_N "(cached) $ECHO_C" >&6
25931 else
25932   eval "$as_ac_Header=\$ac_header_preproc"
25933 fi
25934 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25935 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25936
25937 fi
25938 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25939   cat >>confdefs.h <<_ACEOF
25940 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25941 _ACEOF
25942
25943 fi
25944
25945 done
25946
25947
25948
25949 for ac_func in sched_yield pthread_yield
25950 do
25951 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
25952 echo "$as_me:$LINENO: checking for $ac_func" >&5
25953 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
25954 if eval "test \"\${$as_ac_var+set}\" = set"; then
25955   echo $ECHO_N "(cached) $ECHO_C" >&6
25956 else
25957   cat >conftest.$ac_ext <<_ACEOF
25958 /* confdefs.h.  */
25959 _ACEOF
25960 cat confdefs.h >>conftest.$ac_ext
25961 cat >>conftest.$ac_ext <<_ACEOF
25962 /* end confdefs.h.  */
25963 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
25964    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
25965 #define $ac_func innocuous_$ac_func
25966
25967 /* System header to define __stub macros and hopefully few prototypes,
25968     which can conflict with char $ac_func (); below.
25969     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
25970     <limits.h> exists even on freestanding compilers.  */
25971
25972 #ifdef __STDC__
25973 # include <limits.h>
25974 #else
25975 # include <assert.h>
25976 #endif
25977
25978 #undef $ac_func
25979
25980 /* Override any gcc2 internal prototype to avoid an error.  */
25981 #ifdef __cplusplus
25982 extern "C"
25983 {
25984 #endif
25985 /* We use char because int might match the return type of a gcc2
25986    builtin and then its argument prototype would still apply.  */
25987 char $ac_func ();
25988 /* The GNU C library defines this for functions which it implements
25989     to always fail with ENOSYS.  Some functions are actually named
25990     something starting with __ and the normal name is an alias.  */
25991 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
25992 choke me
25993 #else
25994 char (*f) () = $ac_func;
25995 #endif
25996 #ifdef __cplusplus
25997 }
25998 #endif
25999
26000 int
26001 main ()
26002 {
26003 return f != $ac_func;
26004   ;
26005   return 0;
26006 }
26007 _ACEOF
26008 rm -f conftest.$ac_objext conftest$ac_exeext
26009 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26010   (eval $ac_link) 2>conftest.er1
26011   ac_status=$?
26012   grep -v '^ *+' conftest.er1 >conftest.err
26013   rm -f conftest.er1
26014   cat conftest.err >&5
26015   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26016   (exit $ac_status); } &&
26017          { ac_try='test -z "$ac_c_werror_flag"
26018                          || test ! -s conftest.err'
26019   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26020   (eval $ac_try) 2>&5
26021   ac_status=$?
26022   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26023   (exit $ac_status); }; } &&
26024          { ac_try='test -s conftest$ac_exeext'
26025   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26026   (eval $ac_try) 2>&5
26027   ac_status=$?
26028   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26029   (exit $ac_status); }; }; then
26030   eval "$as_ac_var=yes"
26031 else
26032   echo "$as_me: failed program was:" >&5
26033 sed 's/^/| /' conftest.$ac_ext >&5
26034
26035 eval "$as_ac_var=no"
26036 fi
26037 rm -f conftest.err conftest.$ac_objext \
26038       conftest$ac_exeext conftest.$ac_ext
26039 fi
26040 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
26041 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
26042 if test `eval echo '${'$as_ac_var'}'` = yes; then
26043   cat >>confdefs.h <<_ACEOF
26044 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
26045 _ACEOF
26046
26047 fi
26048 done
26049
26050
26051         echo "$as_me:$LINENO: checking for LinuxThreads pthread.h" >&5
26052 echo $ECHO_N "checking for LinuxThreads pthread.h... $ECHO_C" >&6
26053 if test "${ol_cv_header_linux_threads+set}" = set; then
26054   echo $ECHO_N "(cached) $ECHO_C" >&6
26055 else
26056   cat >conftest.$ac_ext <<_ACEOF
26057 /* confdefs.h.  */
26058 _ACEOF
26059 cat confdefs.h >>conftest.$ac_ext
26060 cat >>conftest.$ac_ext <<_ACEOF
26061 /* end confdefs.h.  */
26062 #include <pthread.h>
26063 _ACEOF
26064 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
26065   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then
26066   ol_cv_header_linux_threads=yes
26067 else
26068   ol_cv_header_linux_threads=no
26069 fi
26070 rm -f conftest*
26071
26072
26073 fi
26074 echo "$as_me:$LINENO: result: $ol_cv_header_linux_threads" >&5
26075 echo "${ECHO_T}$ol_cv_header_linux_threads" >&6
26076         if test $ol_cv_header_linux_threads = yes; then
26077
26078 cat >>confdefs.h <<\_ACEOF
26079 #define HAVE_LINUX_THREADS 1
26080 _ACEOF
26081
26082         fi
26083
26084
26085
26086 for ac_header in mach/cthreads.h
26087 do
26088 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26089 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26090   echo "$as_me:$LINENO: checking for $ac_header" >&5
26091 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26092 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26093   echo $ECHO_N "(cached) $ECHO_C" >&6
26094 fi
26095 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26096 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26097 else
26098   # Is the header compilable?
26099 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26100 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26101 cat >conftest.$ac_ext <<_ACEOF
26102 /* confdefs.h.  */
26103 _ACEOF
26104 cat confdefs.h >>conftest.$ac_ext
26105 cat >>conftest.$ac_ext <<_ACEOF
26106 /* end confdefs.h.  */
26107 $ac_includes_default
26108 #include <$ac_header>
26109 _ACEOF
26110 rm -f conftest.$ac_objext
26111 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26112   (eval $ac_compile) 2>conftest.er1
26113   ac_status=$?
26114   grep -v '^ *+' conftest.er1 >conftest.err
26115   rm -f conftest.er1
26116   cat conftest.err >&5
26117   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26118   (exit $ac_status); } &&
26119          { ac_try='test -z "$ac_c_werror_flag"
26120                          || test ! -s conftest.err'
26121   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26122   (eval $ac_try) 2>&5
26123   ac_status=$?
26124   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26125   (exit $ac_status); }; } &&
26126          { ac_try='test -s conftest.$ac_objext'
26127   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26128   (eval $ac_try) 2>&5
26129   ac_status=$?
26130   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26131   (exit $ac_status); }; }; then
26132   ac_header_compiler=yes
26133 else
26134   echo "$as_me: failed program was:" >&5
26135 sed 's/^/| /' conftest.$ac_ext >&5
26136
26137 ac_header_compiler=no
26138 fi
26139 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26140 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26141 echo "${ECHO_T}$ac_header_compiler" >&6
26142
26143 # Is the header present?
26144 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26145 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26146 cat >conftest.$ac_ext <<_ACEOF
26147 /* confdefs.h.  */
26148 _ACEOF
26149 cat confdefs.h >>conftest.$ac_ext
26150 cat >>conftest.$ac_ext <<_ACEOF
26151 /* end confdefs.h.  */
26152 #include <$ac_header>
26153 _ACEOF
26154 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26155   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26156   ac_status=$?
26157   grep -v '^ *+' conftest.er1 >conftest.err
26158   rm -f conftest.er1
26159   cat conftest.err >&5
26160   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26161   (exit $ac_status); } >/dev/null; then
26162   if test -s conftest.err; then
26163     ac_cpp_err=$ac_c_preproc_warn_flag
26164     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26165   else
26166     ac_cpp_err=
26167   fi
26168 else
26169   ac_cpp_err=yes
26170 fi
26171 if test -z "$ac_cpp_err"; then
26172   ac_header_preproc=yes
26173 else
26174   echo "$as_me: failed program was:" >&5
26175 sed 's/^/| /' conftest.$ac_ext >&5
26176
26177   ac_header_preproc=no
26178 fi
26179 rm -f conftest.err conftest.$ac_ext
26180 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26181 echo "${ECHO_T}$ac_header_preproc" >&6
26182
26183 # So?  What about this header?
26184 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26185   yes:no: )
26186     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26187 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26188     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26189 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26190     ac_header_preproc=yes
26191     ;;
26192   no:yes:* )
26193     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26194 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26195     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26196 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26197     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26198 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26199     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26200 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26201     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26202 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26203     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26204 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26205     (
26206       cat <<\_ASBOX
26207 ## --------------------------------------------- ##
26208 ## Report this to <http://www.openldap.org/its/> ##
26209 ## --------------------------------------------- ##
26210 _ASBOX
26211     ) |
26212       sed "s/^/$as_me: WARNING:     /" >&2
26213     ;;
26214 esac
26215 echo "$as_me:$LINENO: checking for $ac_header" >&5
26216 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26217 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26218   echo $ECHO_N "(cached) $ECHO_C" >&6
26219 else
26220   eval "$as_ac_Header=\$ac_header_preproc"
26221 fi
26222 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26223 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26224
26225 fi
26226 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26227   cat >>confdefs.h <<_ACEOF
26228 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26229 _ACEOF
26230
26231 fi
26232
26233 done
26234
26235
26236 for ac_header in lwp/lwp.h
26237 do
26238 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26239 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26240   echo "$as_me:$LINENO: checking for $ac_header" >&5
26241 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26242 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26243   echo $ECHO_N "(cached) $ECHO_C" >&6
26244 fi
26245 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26246 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26247 else
26248   # Is the header compilable?
26249 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26250 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26251 cat >conftest.$ac_ext <<_ACEOF
26252 /* confdefs.h.  */
26253 _ACEOF
26254 cat confdefs.h >>conftest.$ac_ext
26255 cat >>conftest.$ac_ext <<_ACEOF
26256 /* end confdefs.h.  */
26257 $ac_includes_default
26258 #include <$ac_header>
26259 _ACEOF
26260 rm -f conftest.$ac_objext
26261 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26262   (eval $ac_compile) 2>conftest.er1
26263   ac_status=$?
26264   grep -v '^ *+' conftest.er1 >conftest.err
26265   rm -f conftest.er1
26266   cat conftest.err >&5
26267   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26268   (exit $ac_status); } &&
26269          { ac_try='test -z "$ac_c_werror_flag"
26270                          || test ! -s conftest.err'
26271   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26272   (eval $ac_try) 2>&5
26273   ac_status=$?
26274   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26275   (exit $ac_status); }; } &&
26276          { ac_try='test -s conftest.$ac_objext'
26277   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26278   (eval $ac_try) 2>&5
26279   ac_status=$?
26280   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26281   (exit $ac_status); }; }; then
26282   ac_header_compiler=yes
26283 else
26284   echo "$as_me: failed program was:" >&5
26285 sed 's/^/| /' conftest.$ac_ext >&5
26286
26287 ac_header_compiler=no
26288 fi
26289 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26290 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26291 echo "${ECHO_T}$ac_header_compiler" >&6
26292
26293 # Is the header present?
26294 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26295 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26296 cat >conftest.$ac_ext <<_ACEOF
26297 /* confdefs.h.  */
26298 _ACEOF
26299 cat confdefs.h >>conftest.$ac_ext
26300 cat >>conftest.$ac_ext <<_ACEOF
26301 /* end confdefs.h.  */
26302 #include <$ac_header>
26303 _ACEOF
26304 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26305   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26306   ac_status=$?
26307   grep -v '^ *+' conftest.er1 >conftest.err
26308   rm -f conftest.er1
26309   cat conftest.err >&5
26310   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26311   (exit $ac_status); } >/dev/null; then
26312   if test -s conftest.err; then
26313     ac_cpp_err=$ac_c_preproc_warn_flag
26314     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26315   else
26316     ac_cpp_err=
26317   fi
26318 else
26319   ac_cpp_err=yes
26320 fi
26321 if test -z "$ac_cpp_err"; then
26322   ac_header_preproc=yes
26323 else
26324   echo "$as_me: failed program was:" >&5
26325 sed 's/^/| /' conftest.$ac_ext >&5
26326
26327   ac_header_preproc=no
26328 fi
26329 rm -f conftest.err conftest.$ac_ext
26330 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26331 echo "${ECHO_T}$ac_header_preproc" >&6
26332
26333 # So?  What about this header?
26334 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26335   yes:no: )
26336     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26337 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26338     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26339 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26340     ac_header_preproc=yes
26341     ;;
26342   no:yes:* )
26343     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26344 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26345     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26346 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26347     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26348 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26349     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26350 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26351     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26352 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26353     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26354 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26355     (
26356       cat <<\_ASBOX
26357 ## --------------------------------------------- ##
26358 ## Report this to <http://www.openldap.org/its/> ##
26359 ## --------------------------------------------- ##
26360 _ASBOX
26361     ) |
26362       sed "s/^/$as_me: WARNING:     /" >&2
26363     ;;
26364 esac
26365 echo "$as_me:$LINENO: checking for $ac_header" >&5
26366 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26367 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26368   echo $ECHO_N "(cached) $ECHO_C" >&6
26369 else
26370   eval "$as_ac_Header=\$ac_header_preproc"
26371 fi
26372 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26373 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26374
26375 fi
26376 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26377   cat >>confdefs.h <<_ACEOF
26378 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26379 _ACEOF
26380
26381 fi
26382
26383 done
26384
26385
26386
26387 for ac_header in thread.h synch.h
26388 do
26389 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26390 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26391   echo "$as_me:$LINENO: checking for $ac_header" >&5
26392 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26393 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26394   echo $ECHO_N "(cached) $ECHO_C" >&6
26395 fi
26396 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26397 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26398 else
26399   # Is the header compilable?
26400 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26401 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26402 cat >conftest.$ac_ext <<_ACEOF
26403 /* confdefs.h.  */
26404 _ACEOF
26405 cat confdefs.h >>conftest.$ac_ext
26406 cat >>conftest.$ac_ext <<_ACEOF
26407 /* end confdefs.h.  */
26408 $ac_includes_default
26409 #include <$ac_header>
26410 _ACEOF
26411 rm -f conftest.$ac_objext
26412 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26413   (eval $ac_compile) 2>conftest.er1
26414   ac_status=$?
26415   grep -v '^ *+' conftest.er1 >conftest.err
26416   rm -f conftest.er1
26417   cat conftest.err >&5
26418   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26419   (exit $ac_status); } &&
26420          { ac_try='test -z "$ac_c_werror_flag"
26421                          || test ! -s conftest.err'
26422   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26423   (eval $ac_try) 2>&5
26424   ac_status=$?
26425   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26426   (exit $ac_status); }; } &&
26427          { ac_try='test -s conftest.$ac_objext'
26428   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26429   (eval $ac_try) 2>&5
26430   ac_status=$?
26431   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26432   (exit $ac_status); }; }; then
26433   ac_header_compiler=yes
26434 else
26435   echo "$as_me: failed program was:" >&5
26436 sed 's/^/| /' conftest.$ac_ext >&5
26437
26438 ac_header_compiler=no
26439 fi
26440 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26441 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26442 echo "${ECHO_T}$ac_header_compiler" >&6
26443
26444 # Is the header present?
26445 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26446 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26447 cat >conftest.$ac_ext <<_ACEOF
26448 /* confdefs.h.  */
26449 _ACEOF
26450 cat confdefs.h >>conftest.$ac_ext
26451 cat >>conftest.$ac_ext <<_ACEOF
26452 /* end confdefs.h.  */
26453 #include <$ac_header>
26454 _ACEOF
26455 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26456   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26457   ac_status=$?
26458   grep -v '^ *+' conftest.er1 >conftest.err
26459   rm -f conftest.er1
26460   cat conftest.err >&5
26461   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26462   (exit $ac_status); } >/dev/null; then
26463   if test -s conftest.err; then
26464     ac_cpp_err=$ac_c_preproc_warn_flag
26465     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26466   else
26467     ac_cpp_err=
26468   fi
26469 else
26470   ac_cpp_err=yes
26471 fi
26472 if test -z "$ac_cpp_err"; then
26473   ac_header_preproc=yes
26474 else
26475   echo "$as_me: failed program was:" >&5
26476 sed 's/^/| /' conftest.$ac_ext >&5
26477
26478   ac_header_preproc=no
26479 fi
26480 rm -f conftest.err conftest.$ac_ext
26481 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26482 echo "${ECHO_T}$ac_header_preproc" >&6
26483
26484 # So?  What about this header?
26485 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26486   yes:no: )
26487     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26488 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26489     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26490 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26491     ac_header_preproc=yes
26492     ;;
26493   no:yes:* )
26494     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26495 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26496     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26497 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26498     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26499 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26500     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26501 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26502     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26503 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26504     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26505 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26506     (
26507       cat <<\_ASBOX
26508 ## --------------------------------------------- ##
26509 ## Report this to <http://www.openldap.org/its/> ##
26510 ## --------------------------------------------- ##
26511 _ASBOX
26512     ) |
26513       sed "s/^/$as_me: WARNING:     /" >&2
26514     ;;
26515 esac
26516 echo "$as_me:$LINENO: checking for $ac_header" >&5
26517 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26518 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26519   echo $ECHO_N "(cached) $ECHO_C" >&6
26520 else
26521   eval "$as_ac_Header=\$ac_header_preproc"
26522 fi
26523 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26524 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26525
26526 fi
26527 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26528   cat >>confdefs.h <<_ACEOF
26529 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26530 _ACEOF
26531
26532 fi
26533
26534 done
26535
26536 fi
26537
26538 if test $ol_link_threads != no && test $ol_link_threads != nt ; then
26539                         cat >>confdefs.h <<\_ACEOF
26540 #define REENTRANT 1
26541 _ACEOF
26542
26543         cat >>confdefs.h <<\_ACEOF
26544 #define _REENTRANT 1
26545 _ACEOF
26546
26547         cat >>confdefs.h <<\_ACEOF
26548 #define THREAD_SAFE 1
26549 _ACEOF
26550
26551         cat >>confdefs.h <<\_ACEOF
26552 #define _THREAD_SAFE 1
26553 _ACEOF
26554
26555         cat >>confdefs.h <<\_ACEOF
26556 #define THREADSAFE 1
26557 _ACEOF
26558
26559         cat >>confdefs.h <<\_ACEOF
26560 #define _THREADSAFE 1
26561 _ACEOF
26562
26563         cat >>confdefs.h <<\_ACEOF
26564 #define _SGI_MP_SOURCE 1
26565 _ACEOF
26566
26567
26568                         echo "$as_me:$LINENO: checking for thread specific errno" >&5
26569 echo $ECHO_N "checking for thread specific errno... $ECHO_C" >&6
26570 if test "${ol_cv_errno_thread_specific+set}" = set; then
26571   echo $ECHO_N "(cached) $ECHO_C" >&6
26572 else
26573
26574                 cat >conftest.$ac_ext <<_ACEOF
26575 /* confdefs.h.  */
26576 _ACEOF
26577 cat confdefs.h >>conftest.$ac_ext
26578 cat >>conftest.$ac_ext <<_ACEOF
26579 /* end confdefs.h.  */
26580 #include <errno.h>
26581 int
26582 main ()
26583 {
26584 errno = 0;
26585   ;
26586   return 0;
26587 }
26588 _ACEOF
26589 rm -f conftest.$ac_objext conftest$ac_exeext
26590 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26591   (eval $ac_link) 2>conftest.er1
26592   ac_status=$?
26593   grep -v '^ *+' conftest.er1 >conftest.err
26594   rm -f conftest.er1
26595   cat conftest.err >&5
26596   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26597   (exit $ac_status); } &&
26598          { ac_try='test -z "$ac_c_werror_flag"
26599                          || test ! -s conftest.err'
26600   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26601   (eval $ac_try) 2>&5
26602   ac_status=$?
26603   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26604   (exit $ac_status); }; } &&
26605          { ac_try='test -s conftest$ac_exeext'
26606   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26607   (eval $ac_try) 2>&5
26608   ac_status=$?
26609   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26610   (exit $ac_status); }; }; then
26611   ol_cv_errno_thread_specific=yes
26612 else
26613   echo "$as_me: failed program was:" >&5
26614 sed 's/^/| /' conftest.$ac_ext >&5
26615
26616 ol_cv_errno_thread_specific=no
26617 fi
26618 rm -f conftest.err conftest.$ac_objext \
26619       conftest$ac_exeext conftest.$ac_ext
26620
26621 fi
26622 echo "$as_me:$LINENO: result: $ol_cv_errno_thread_specific" >&5
26623 echo "${ECHO_T}$ol_cv_errno_thread_specific" >&6
26624
26625                         echo "$as_me:$LINENO: checking for thread specific h_errno" >&5
26626 echo $ECHO_N "checking for thread specific h_errno... $ECHO_C" >&6
26627 if test "${ol_cv_h_errno_thread_specific+set}" = set; then
26628   echo $ECHO_N "(cached) $ECHO_C" >&6
26629 else
26630
26631                 cat >conftest.$ac_ext <<_ACEOF
26632 /* confdefs.h.  */
26633 _ACEOF
26634 cat confdefs.h >>conftest.$ac_ext
26635 cat >>conftest.$ac_ext <<_ACEOF
26636 /* end confdefs.h.  */
26637 #include <netdb.h>
26638 int
26639 main ()
26640 {
26641 h_errno = 0;
26642   ;
26643   return 0;
26644 }
26645 _ACEOF
26646 rm -f conftest.$ac_objext conftest$ac_exeext
26647 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26648   (eval $ac_link) 2>conftest.er1
26649   ac_status=$?
26650   grep -v '^ *+' conftest.er1 >conftest.err
26651   rm -f conftest.er1
26652   cat conftest.err >&5
26653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26654   (exit $ac_status); } &&
26655          { ac_try='test -z "$ac_c_werror_flag"
26656                          || test ! -s conftest.err'
26657   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26658   (eval $ac_try) 2>&5
26659   ac_status=$?
26660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26661   (exit $ac_status); }; } &&
26662          { ac_try='test -s conftest$ac_exeext'
26663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26664   (eval $ac_try) 2>&5
26665   ac_status=$?
26666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26667   (exit $ac_status); }; }; then
26668   ol_cv_h_errno_thread_specific=yes
26669 else
26670   echo "$as_me: failed program was:" >&5
26671 sed 's/^/| /' conftest.$ac_ext >&5
26672
26673 ol_cv_h_errno_thread_specific=no
26674 fi
26675 rm -f conftest.err conftest.$ac_objext \
26676       conftest$ac_exeext conftest.$ac_ext
26677
26678 fi
26679 echo "$as_me:$LINENO: result: $ol_cv_h_errno_thread_specific" >&5
26680 echo "${ECHO_T}$ol_cv_h_errno_thread_specific" >&6
26681
26682         if test $ol_cv_errno_thread_specific != yes ||
26683            test $ol_cv_h_errno_thread_specific != yes ; then
26684                 LIBS="$LTHREAD_LIBS $LIBS"
26685                 LTHREAD_LIBS=""
26686         fi
26687
26688 fi
26689
26690 if test $ol_link_threads = no ; then
26691         if test $ol_with_threads = yes ; then
26692                 { { echo "$as_me:$LINENO: error: no suitable thread support" >&5
26693 echo "$as_me: error: no suitable thread support" >&2;}
26694    { (exit 1); exit 1; }; }
26695         fi
26696
26697         if test $ol_with_threads = auto ; then
26698                 { echo "$as_me:$LINENO: WARNING: no suitable thread support, disabling threads" >&5
26699 echo "$as_me: WARNING: no suitable thread support, disabling threads" >&2;}
26700                 ol_with_threads=no
26701         fi
26702
26703
26704 cat >>confdefs.h <<\_ACEOF
26705 #define NO_THREADS 1
26706 _ACEOF
26707
26708         LTHREAD_LIBS=""
26709         BUILD_THREAD=no
26710 else
26711         BUILD_THREAD=yes
26712 fi
26713
26714 if test $ol_link_threads != no ; then
26715
26716 cat >>confdefs.h <<\_ACEOF
26717 #define LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE 1
26718 _ACEOF
26719
26720 fi
26721
26722
26723
26724
26725 for ac_func in \
26726         ctime_r                 \
26727         gethostbyname_r gethostbyaddr_r \
26728
26729 do
26730 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
26731 echo "$as_me:$LINENO: checking for $ac_func" >&5
26732 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
26733 if eval "test \"\${$as_ac_var+set}\" = set"; then
26734   echo $ECHO_N "(cached) $ECHO_C" >&6
26735 else
26736   cat >conftest.$ac_ext <<_ACEOF
26737 /* confdefs.h.  */
26738 _ACEOF
26739 cat confdefs.h >>conftest.$ac_ext
26740 cat >>conftest.$ac_ext <<_ACEOF
26741 /* end confdefs.h.  */
26742 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
26743    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
26744 #define $ac_func innocuous_$ac_func
26745
26746 /* System header to define __stub macros and hopefully few prototypes,
26747     which can conflict with char $ac_func (); below.
26748     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
26749     <limits.h> exists even on freestanding compilers.  */
26750
26751 #ifdef __STDC__
26752 # include <limits.h>
26753 #else
26754 # include <assert.h>
26755 #endif
26756
26757 #undef $ac_func
26758
26759 /* Override any gcc2 internal prototype to avoid an error.  */
26760 #ifdef __cplusplus
26761 extern "C"
26762 {
26763 #endif
26764 /* We use char because int might match the return type of a gcc2
26765    builtin and then its argument prototype would still apply.  */
26766 char $ac_func ();
26767 /* The GNU C library defines this for functions which it implements
26768     to always fail with ENOSYS.  Some functions are actually named
26769     something starting with __ and the normal name is an alias.  */
26770 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
26771 choke me
26772 #else
26773 char (*f) () = $ac_func;
26774 #endif
26775 #ifdef __cplusplus
26776 }
26777 #endif
26778
26779 int
26780 main ()
26781 {
26782 return f != $ac_func;
26783   ;
26784   return 0;
26785 }
26786 _ACEOF
26787 rm -f conftest.$ac_objext conftest$ac_exeext
26788 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26789   (eval $ac_link) 2>conftest.er1
26790   ac_status=$?
26791   grep -v '^ *+' conftest.er1 >conftest.err
26792   rm -f conftest.er1
26793   cat conftest.err >&5
26794   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26795   (exit $ac_status); } &&
26796          { ac_try='test -z "$ac_c_werror_flag"
26797                          || test ! -s conftest.err'
26798   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26799   (eval $ac_try) 2>&5
26800   ac_status=$?
26801   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26802   (exit $ac_status); }; } &&
26803          { ac_try='test -s conftest$ac_exeext'
26804   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26805   (eval $ac_try) 2>&5
26806   ac_status=$?
26807   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26808   (exit $ac_status); }; }; then
26809   eval "$as_ac_var=yes"
26810 else
26811   echo "$as_me: failed program was:" >&5
26812 sed 's/^/| /' conftest.$ac_ext >&5
26813
26814 eval "$as_ac_var=no"
26815 fi
26816 rm -f conftest.err conftest.$ac_objext \
26817       conftest$ac_exeext conftest.$ac_ext
26818 fi
26819 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
26820 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
26821 if test `eval echo '${'$as_ac_var'}'` = yes; then
26822   cat >>confdefs.h <<_ACEOF
26823 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
26824 _ACEOF
26825
26826 fi
26827 done
26828
26829
26830 if test "$ac_cv_func_ctime_r" = no ; then
26831         ol_cv_func_ctime_r_nargs=0
26832 else
26833         echo "$as_me:$LINENO: checking number of arguments of ctime_r" >&5
26834 echo $ECHO_N "checking number of arguments of ctime_r... $ECHO_C" >&6
26835 if test "${ol_cv_func_ctime_r_nargs+set}" = set; then
26836   echo $ECHO_N "(cached) $ECHO_C" >&6
26837 else
26838   cat >conftest.$ac_ext <<_ACEOF
26839 /* confdefs.h.  */
26840 _ACEOF
26841 cat confdefs.h >>conftest.$ac_ext
26842 cat >>conftest.$ac_ext <<_ACEOF
26843 /* end confdefs.h.  */
26844 #include <time.h>
26845 int
26846 main ()
26847 {
26848 time_t ti; char *buffer; ctime_r(&ti,buffer,32);
26849   ;
26850   return 0;
26851 }
26852 _ACEOF
26853 rm -f conftest.$ac_objext
26854 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26855   (eval $ac_compile) 2>conftest.er1
26856   ac_status=$?
26857   grep -v '^ *+' conftest.er1 >conftest.err
26858   rm -f conftest.er1
26859   cat conftest.err >&5
26860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26861   (exit $ac_status); } &&
26862          { ac_try='test -z "$ac_c_werror_flag"
26863                          || test ! -s conftest.err'
26864   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26865   (eval $ac_try) 2>&5
26866   ac_status=$?
26867   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26868   (exit $ac_status); }; } &&
26869          { ac_try='test -s conftest.$ac_objext'
26870   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26871   (eval $ac_try) 2>&5
26872   ac_status=$?
26873   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26874   (exit $ac_status); }; }; then
26875   ol_cv_func_ctime_r_nargs3=yes
26876 else
26877   echo "$as_me: failed program was:" >&5
26878 sed 's/^/| /' conftest.$ac_ext >&5
26879
26880 ol_cv_func_ctime_r_nargs3=no
26881 fi
26882 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26883
26884         cat >conftest.$ac_ext <<_ACEOF
26885 /* confdefs.h.  */
26886 _ACEOF
26887 cat confdefs.h >>conftest.$ac_ext
26888 cat >>conftest.$ac_ext <<_ACEOF
26889 /* end confdefs.h.  */
26890 #include <time.h>
26891 int
26892 main ()
26893 {
26894 time_t ti; char *buffer; ctime_r(&ti,buffer);
26895   ;
26896   return 0;
26897 }
26898 _ACEOF
26899 rm -f conftest.$ac_objext
26900 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26901   (eval $ac_compile) 2>conftest.er1
26902   ac_status=$?
26903   grep -v '^ *+' conftest.er1 >conftest.err
26904   rm -f conftest.er1
26905   cat conftest.err >&5
26906   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26907   (exit $ac_status); } &&
26908          { ac_try='test -z "$ac_c_werror_flag"
26909                          || test ! -s conftest.err'
26910   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26911   (eval $ac_try) 2>&5
26912   ac_status=$?
26913   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26914   (exit $ac_status); }; } &&
26915          { ac_try='test -s conftest.$ac_objext'
26916   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26917   (eval $ac_try) 2>&5
26918   ac_status=$?
26919   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26920   (exit $ac_status); }; }; then
26921   ol_cv_func_ctime_r_nargs2=yes
26922 else
26923   echo "$as_me: failed program was:" >&5
26924 sed 's/^/| /' conftest.$ac_ext >&5
26925
26926 ol_cv_func_ctime_r_nargs2=no
26927 fi
26928 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26929
26930         if test $ol_cv_func_ctime_r_nargs3 = yes &&
26931            test $ol_cv_func_ctime_r_nargs2 = no ; then
26932
26933                 ol_cv_func_ctime_r_nargs=3
26934
26935         elif test $ol_cv_func_ctime_r_nargs3 = no &&
26936              test $ol_cv_func_ctime_r_nargs2 = yes ; then
26937
26938                 ol_cv_func_ctime_r_nargs=2
26939
26940         else
26941                 ol_cv_func_ctime_r_nargs=0
26942         fi
26943
26944 fi
26945 echo "$as_me:$LINENO: result: $ol_cv_func_ctime_r_nargs" >&5
26946 echo "${ECHO_T}$ol_cv_func_ctime_r_nargs" >&6
26947
26948   if test $ol_cv_func_ctime_r_nargs -gt 1 ; then
26949
26950 cat >>confdefs.h <<_ACEOF
26951 #define CTIME_R_NARGS $ol_cv_func_ctime_r_nargs
26952 _ACEOF
26953
26954   fi
26955
26956 fi
26957
26958 if test "$ac_cv_func_gethostbyname_r" = yes ; then
26959         echo "$as_me:$LINENO: checking number of arguments of gethostbyname_r" >&5
26960 echo $ECHO_N "checking number of arguments of gethostbyname_r... $ECHO_C" >&6
26961 if test "${ol_cv_func_gethostbyname_r_nargs+set}" = set; then
26962   echo $ECHO_N "(cached) $ECHO_C" >&6
26963 else
26964   cat >conftest.$ac_ext <<_ACEOF
26965 /* confdefs.h.  */
26966 _ACEOF
26967 cat confdefs.h >>conftest.$ac_ext
26968 cat >>conftest.$ac_ext <<_ACEOF
26969 /* end confdefs.h.  */
26970 #include <sys/types.h>
26971 #include <sys/socket.h>
26972 #include <netinet/in.h>
26973 #include <netdb.h>
26974 #define BUFSIZE (sizeof(struct hostent)+10)
26975 int
26976 main ()
26977 {
26978 struct hostent hent; char buffer[BUFSIZE];
26979                 int bufsize=BUFSIZE;int h_errno;
26980                 (void)gethostbyname_r("segovia.cs.purdue.edu", &hent,
26981                         buffer, bufsize, &h_errno);
26982   ;
26983   return 0;
26984 }
26985 _ACEOF
26986 rm -f conftest.$ac_objext
26987 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26988   (eval $ac_compile) 2>conftest.er1
26989   ac_status=$?
26990   grep -v '^ *+' conftest.er1 >conftest.err
26991   rm -f conftest.er1
26992   cat conftest.err >&5
26993   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26994   (exit $ac_status); } &&
26995          { ac_try='test -z "$ac_c_werror_flag"
26996                          || test ! -s conftest.err'
26997   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26998   (eval $ac_try) 2>&5
26999   ac_status=$?
27000   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27001   (exit $ac_status); }; } &&
27002          { ac_try='test -s conftest.$ac_objext'
27003   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27004   (eval $ac_try) 2>&5
27005   ac_status=$?
27006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27007   (exit $ac_status); }; }; then
27008   ol_cv_func_gethostbyname_r_nargs5=yes
27009 else
27010   echo "$as_me: failed program was:" >&5
27011 sed 's/^/| /' conftest.$ac_ext >&5
27012
27013 ol_cv_func_gethostbyname_r_nargs5=no
27014 fi
27015 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27016
27017         cat >conftest.$ac_ext <<_ACEOF
27018 /* confdefs.h.  */
27019 _ACEOF
27020 cat confdefs.h >>conftest.$ac_ext
27021 cat >>conftest.$ac_ext <<_ACEOF
27022 /* end confdefs.h.  */
27023 #include <sys/types.h>
27024 #include <sys/socket.h>
27025 #include <netinet/in.h>
27026 #include <netdb.h>
27027 #define BUFSIZE (sizeof(struct hostent)+10)
27028 int
27029 main ()
27030 {
27031 struct hostent hent;struct hostent *rhent;
27032                 char buffer[BUFSIZE];
27033                 int bufsize=BUFSIZE;int h_errno;
27034                 (void)gethostbyname_r("localhost", &hent, buffer, bufsize,
27035                         &rhent, &h_errno);
27036   ;
27037   return 0;
27038 }
27039 _ACEOF
27040 rm -f conftest.$ac_objext
27041 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27042   (eval $ac_compile) 2>conftest.er1
27043   ac_status=$?
27044   grep -v '^ *+' conftest.er1 >conftest.err
27045   rm -f conftest.er1
27046   cat conftest.err >&5
27047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27048   (exit $ac_status); } &&
27049          { ac_try='test -z "$ac_c_werror_flag"
27050                          || test ! -s conftest.err'
27051   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27052   (eval $ac_try) 2>&5
27053   ac_status=$?
27054   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27055   (exit $ac_status); }; } &&
27056          { ac_try='test -s conftest.$ac_objext'
27057   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27058   (eval $ac_try) 2>&5
27059   ac_status=$?
27060   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27061   (exit $ac_status); }; }; then
27062   ol_cv_func_gethostbyname_r_nargs6=yes
27063 else
27064   echo "$as_me: failed program was:" >&5
27065 sed 's/^/| /' conftest.$ac_ext >&5
27066
27067 ol_cv_func_gethostbyname_r_nargs6=no
27068 fi
27069 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27070
27071         if test $ol_cv_func_gethostbyname_r_nargs5 = yes &&
27072            test $ol_cv_func_gethostbyname_r_nargs6 = no ; then
27073
27074                 ol_cv_func_gethostbyname_r_nargs=5
27075
27076         elif test $ol_cv_func_gethostbyname_r_nargs5 = no &&
27077              test $ol_cv_func_gethostbyname_r_nargs6 = yes ; then
27078
27079                 ol_cv_func_gethostbyname_r_nargs=6
27080
27081         else
27082                 ol_cv_func_gethostbyname_r_nargs=0
27083         fi
27084
27085 fi
27086 echo "$as_me:$LINENO: result: $ol_cv_func_gethostbyname_r_nargs" >&5
27087 echo "${ECHO_T}$ol_cv_func_gethostbyname_r_nargs" >&6
27088   if test $ol_cv_func_gethostbyname_r_nargs -gt 1 ; then
27089
27090 cat >>confdefs.h <<_ACEOF
27091 #define GETHOSTBYNAME_R_NARGS $ol_cv_func_gethostbyname_r_nargs
27092 _ACEOF
27093
27094   fi
27095
27096 else
27097         ol_cv_func_gethostbyname_r_nargs=0
27098 fi
27099
27100 if test "$ac_cv_func_gethostbyaddr_r" = yes ; then
27101         echo "$as_me:$LINENO: checking number of arguments of gethostbyaddr_r" >&5
27102 echo $ECHO_N "checking number of arguments of gethostbyaddr_r... $ECHO_C" >&6
27103 if test "${ol_cv_func_gethostbyaddr_r_nargs+set}" = set; then
27104   echo $ECHO_N "(cached) $ECHO_C" >&6
27105 else
27106   cat >conftest.$ac_ext <<_ACEOF
27107 /* confdefs.h.  */
27108 _ACEOF
27109 cat confdefs.h >>conftest.$ac_ext
27110 cat >>conftest.$ac_ext <<_ACEOF
27111 /* end confdefs.h.  */
27112 #include <sys/types.h>
27113 #include <sys/socket.h>
27114 #include <netinet/in.h>
27115 #include <netdb.h>
27116 #define BUFSIZE (sizeof(struct hostent)+10)
27117 int
27118 main ()
27119 {
27120 struct hostent hent; char buffer[BUFSIZE];
27121             struct in_addr add;
27122             size_t alen=sizeof(struct in_addr);
27123             int bufsize=BUFSIZE;int h_errno;
27124                 (void)gethostbyaddr_r( (void *)&(add.s_addr),
27125                         alen, AF_INET, &hent, buffer, bufsize, &h_errno);
27126   ;
27127   return 0;
27128 }
27129 _ACEOF
27130 rm -f conftest.$ac_objext
27131 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27132   (eval $ac_compile) 2>conftest.er1
27133   ac_status=$?
27134   grep -v '^ *+' conftest.er1 >conftest.err
27135   rm -f conftest.er1
27136   cat conftest.err >&5
27137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27138   (exit $ac_status); } &&
27139          { ac_try='test -z "$ac_c_werror_flag"
27140                          || test ! -s conftest.err'
27141   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27142   (eval $ac_try) 2>&5
27143   ac_status=$?
27144   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27145   (exit $ac_status); }; } &&
27146          { ac_try='test -s conftest.$ac_objext'
27147   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27148   (eval $ac_try) 2>&5
27149   ac_status=$?
27150   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27151   (exit $ac_status); }; }; then
27152   ol_cv_func_gethostbyaddr_r_nargs7=yes
27153 else
27154   echo "$as_me: failed program was:" >&5
27155 sed 's/^/| /' conftest.$ac_ext >&5
27156
27157 ol_cv_func_gethostbyaddr_r_nargs7=no
27158 fi
27159 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27160
27161         cat >conftest.$ac_ext <<_ACEOF
27162 /* confdefs.h.  */
27163 _ACEOF
27164 cat confdefs.h >>conftest.$ac_ext
27165 cat >>conftest.$ac_ext <<_ACEOF
27166 /* end confdefs.h.  */
27167 #include <sys/types.h>
27168 #include <sys/socket.h>
27169 #include <netinet/in.h>
27170 #include <netdb.h>
27171 #define BUFSIZE (sizeof(struct hostent)+10)
27172 int
27173 main ()
27174 {
27175 struct hostent hent;
27176                 struct hostent *rhent; char buffer[BUFSIZE];
27177                 struct in_addr add;
27178                 size_t alen=sizeof(struct in_addr);
27179                 int bufsize=BUFSIZE;int h_errno;
27180                 (void)gethostbyaddr_r( (void *)&(add.s_addr),
27181                         alen, AF_INET, &hent, buffer, bufsize,
27182                         &rhent, &h_errno);
27183   ;
27184   return 0;
27185 }
27186 _ACEOF
27187 rm -f conftest.$ac_objext
27188 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27189   (eval $ac_compile) 2>conftest.er1
27190   ac_status=$?
27191   grep -v '^ *+' conftest.er1 >conftest.err
27192   rm -f conftest.er1
27193   cat conftest.err >&5
27194   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27195   (exit $ac_status); } &&
27196          { ac_try='test -z "$ac_c_werror_flag"
27197                          || test ! -s conftest.err'
27198   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27199   (eval $ac_try) 2>&5
27200   ac_status=$?
27201   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27202   (exit $ac_status); }; } &&
27203          { ac_try='test -s conftest.$ac_objext'
27204   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27205   (eval $ac_try) 2>&5
27206   ac_status=$?
27207   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27208   (exit $ac_status); }; }; then
27209   ol_cv_func_gethostbyaddr_r_nargs8=yes
27210 else
27211   echo "$as_me: failed program was:" >&5
27212 sed 's/^/| /' conftest.$ac_ext >&5
27213
27214 ol_cv_func_gethostbyaddr_r_nargs8=no
27215 fi
27216 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27217
27218         if test $ol_cv_func_gethostbyaddr_r_nargs7 = yes &&
27219            test $ol_cv_func_gethostbyaddr_r_nargs8 = no ; then
27220
27221                 ol_cv_func_gethostbyaddr_r_nargs=7
27222
27223         elif test $ol_cv_func_gethostbyaddr_r_nargs7 = no &&
27224              test $ol_cv_func_gethostbyaddr_r_nargs8 = yes ; then
27225
27226                 ol_cv_func_gethostbyaddr_r_nargs=8
27227
27228         else
27229                 ol_cv_func_gethostbyaddr_r_nargs=0
27230         fi
27231
27232 fi
27233 echo "$as_me:$LINENO: result: $ol_cv_func_gethostbyaddr_r_nargs" >&5
27234 echo "${ECHO_T}$ol_cv_func_gethostbyaddr_r_nargs" >&6
27235   if test $ol_cv_func_gethostbyaddr_r_nargs -gt 1 ; then
27236
27237 cat >>confdefs.h <<_ACEOF
27238 #define GETHOSTBYADDR_R_NARGS $ol_cv_func_gethostbyaddr_r_nargs
27239 _ACEOF
27240
27241   fi
27242
27243 else
27244         ol_cv_func_gethostbyaddr_r_nargs=0
27245 fi
27246
27247 ol_link_bdb=no
27248
27249 if test $ol_enable_bdb/$ol_enable_hdb != no/no; then
27250         ol_cv_berkeley_db=no
27251
27252 for ac_header in db.h
27253 do
27254 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
27255 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27256   echo "$as_me:$LINENO: checking for $ac_header" >&5
27257 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27258 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27259   echo $ECHO_N "(cached) $ECHO_C" >&6
27260 fi
27261 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27262 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27263 else
27264   # Is the header compilable?
27265 echo "$as_me:$LINENO: checking $ac_header usability" >&5
27266 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
27267 cat >conftest.$ac_ext <<_ACEOF
27268 /* confdefs.h.  */
27269 _ACEOF
27270 cat confdefs.h >>conftest.$ac_ext
27271 cat >>conftest.$ac_ext <<_ACEOF
27272 /* end confdefs.h.  */
27273 $ac_includes_default
27274 #include <$ac_header>
27275 _ACEOF
27276 rm -f conftest.$ac_objext
27277 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27278   (eval $ac_compile) 2>conftest.er1
27279   ac_status=$?
27280   grep -v '^ *+' conftest.er1 >conftest.err
27281   rm -f conftest.er1
27282   cat conftest.err >&5
27283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27284   (exit $ac_status); } &&
27285          { ac_try='test -z "$ac_c_werror_flag"
27286                          || test ! -s conftest.err'
27287   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27288   (eval $ac_try) 2>&5
27289   ac_status=$?
27290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27291   (exit $ac_status); }; } &&
27292          { ac_try='test -s conftest.$ac_objext'
27293   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27294   (eval $ac_try) 2>&5
27295   ac_status=$?
27296   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27297   (exit $ac_status); }; }; then
27298   ac_header_compiler=yes
27299 else
27300   echo "$as_me: failed program was:" >&5
27301 sed 's/^/| /' conftest.$ac_ext >&5
27302
27303 ac_header_compiler=no
27304 fi
27305 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27306 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
27307 echo "${ECHO_T}$ac_header_compiler" >&6
27308
27309 # Is the header present?
27310 echo "$as_me:$LINENO: checking $ac_header presence" >&5
27311 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
27312 cat >conftest.$ac_ext <<_ACEOF
27313 /* confdefs.h.  */
27314 _ACEOF
27315 cat confdefs.h >>conftest.$ac_ext
27316 cat >>conftest.$ac_ext <<_ACEOF
27317 /* end confdefs.h.  */
27318 #include <$ac_header>
27319 _ACEOF
27320 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
27321   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
27322   ac_status=$?
27323   grep -v '^ *+' conftest.er1 >conftest.err
27324   rm -f conftest.er1
27325   cat conftest.err >&5
27326   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27327   (exit $ac_status); } >/dev/null; then
27328   if test -s conftest.err; then
27329     ac_cpp_err=$ac_c_preproc_warn_flag
27330     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
27331   else
27332     ac_cpp_err=
27333   fi
27334 else
27335   ac_cpp_err=yes
27336 fi
27337 if test -z "$ac_cpp_err"; then
27338   ac_header_preproc=yes
27339 else
27340   echo "$as_me: failed program was:" >&5
27341 sed 's/^/| /' conftest.$ac_ext >&5
27342
27343   ac_header_preproc=no
27344 fi
27345 rm -f conftest.err conftest.$ac_ext
27346 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
27347 echo "${ECHO_T}$ac_header_preproc" >&6
27348
27349 # So?  What about this header?
27350 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
27351   yes:no: )
27352     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
27353 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
27354     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
27355 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
27356     ac_header_preproc=yes
27357     ;;
27358   no:yes:* )
27359     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
27360 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
27361     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
27362 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
27363     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
27364 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
27365     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
27366 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
27367     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27368 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27369     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
27370 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
27371     (
27372       cat <<\_ASBOX
27373 ## --------------------------------------------- ##
27374 ## Report this to <http://www.openldap.org/its/> ##
27375 ## --------------------------------------------- ##
27376 _ASBOX
27377     ) |
27378       sed "s/^/$as_me: WARNING:     /" >&2
27379     ;;
27380 esac
27381 echo "$as_me:$LINENO: checking for $ac_header" >&5
27382 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27383 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27384   echo $ECHO_N "(cached) $ECHO_C" >&6
27385 else
27386   eval "$as_ac_Header=\$ac_header_preproc"
27387 fi
27388 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27389 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27390
27391 fi
27392 if test `eval echo '${'$as_ac_Header'}'` = yes; then
27393   cat >>confdefs.h <<_ACEOF
27394 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
27395 _ACEOF
27396
27397 fi
27398
27399 done
27400
27401 if test $ac_cv_header_db_h = yes; then
27402         ol_cv_lib_db=no
27403
27404 echo "$as_me:$LINENO: checking for Berkeley DB major version" >&5
27405 echo $ECHO_N "checking for Berkeley DB major version... $ECHO_C" >&6
27406 if test "${ol_cv_bdb_major+set}" = set; then
27407   echo $ECHO_N "(cached) $ECHO_C" >&6
27408 else
27409
27410         ol_cv_bdb_major=0
27411         if test $ol_cv_bdb_major = 0 ; then
27412                 cat >conftest.$ac_ext <<_ACEOF
27413 /* confdefs.h.  */
27414 _ACEOF
27415 cat confdefs.h >>conftest.$ac_ext
27416 cat >>conftest.$ac_ext <<_ACEOF
27417 /* end confdefs.h.  */
27418
27419 #include <db.h>
27420 #ifndef DB_VERSION_MAJOR
27421 #       define DB_VERSION_MAJOR 1
27422 #endif
27423 #if DB_VERSION_MAJOR == 4
27424 __db_version
27425 #endif
27426
27427 _ACEOF
27428 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27429   $EGREP "__db_version" >/dev/null 2>&1; then
27430   ol_cv_bdb_major=4
27431 else
27432   :
27433 fi
27434 rm -f conftest*
27435
27436         fi
27437         if test $ol_cv_bdb_major = 0 ; then
27438                 cat >conftest.$ac_ext <<_ACEOF
27439 /* confdefs.h.  */
27440 _ACEOF
27441 cat confdefs.h >>conftest.$ac_ext
27442 cat >>conftest.$ac_ext <<_ACEOF
27443 /* end confdefs.h.  */
27444
27445 #include <db.h>
27446 #ifndef DB_VERSION_MAJOR
27447 #       define DB_VERSION_MAJOR 1
27448 #endif
27449 #if DB_VERSION_MAJOR == 3
27450 __db_version
27451 #endif
27452
27453 _ACEOF
27454 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27455   $EGREP "__db_version" >/dev/null 2>&1; then
27456   ol_cv_bdb_major=3
27457 else
27458   :
27459 fi
27460 rm -f conftest*
27461
27462         fi
27463         if test $ol_cv_bdb_major = 0 ; then
27464                 cat >conftest.$ac_ext <<_ACEOF
27465 /* confdefs.h.  */
27466 _ACEOF
27467 cat confdefs.h >>conftest.$ac_ext
27468 cat >>conftest.$ac_ext <<_ACEOF
27469 /* end confdefs.h.  */
27470
27471 #include <db.h>
27472 #ifndef DB_VERSION_MAJOR
27473 #       define DB_VERSION_MAJOR 1
27474 #endif
27475 #if DB_VERSION_MAJOR == 2
27476 __db_version
27477 #endif
27478
27479 _ACEOF
27480 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27481   $EGREP "__db_version" >/dev/null 2>&1; then
27482   ol_cv_bdb_major=2
27483 else
27484   :
27485 fi
27486 rm -f conftest*
27487
27488         fi
27489         if test $ol_cv_bdb_major = 0 ; then
27490                 cat >conftest.$ac_ext <<_ACEOF
27491 /* confdefs.h.  */
27492 _ACEOF
27493 cat confdefs.h >>conftest.$ac_ext
27494 cat >>conftest.$ac_ext <<_ACEOF
27495 /* end confdefs.h.  */
27496
27497 #include <db.h>
27498 #ifndef DB_VERSION_MAJOR
27499 #       define DB_VERSION_MAJOR 1
27500 #endif
27501 #if DB_VERSION_MAJOR == 1
27502 __db_version
27503 #endif
27504
27505 _ACEOF
27506 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27507   $EGREP "__db_version" >/dev/null 2>&1; then
27508   ol_cv_bdb_major=1
27509 else
27510   :
27511 fi
27512 rm -f conftest*
27513
27514         fi
27515
27516         if test $ol_cv_bdb_major = 0 ; then
27517                 { { echo "$as_me:$LINENO: error: Unknown Berkeley DB major version" >&5
27518 echo "$as_me: error: Unknown Berkeley DB major version" >&2;}
27519    { (exit 1); exit 1; }; }
27520         fi
27521
27522 fi
27523 echo "$as_me:$LINENO: result: $ol_cv_bdb_major" >&5
27524 echo "${ECHO_T}$ol_cv_bdb_major" >&6
27525
27526 echo "$as_me:$LINENO: checking for Berkeley DB minor version" >&5
27527 echo $ECHO_N "checking for Berkeley DB minor version... $ECHO_C" >&6
27528 if test "${ol_cv_bdb_minor+set}" = set; then
27529   echo $ECHO_N "(cached) $ECHO_C" >&6
27530 else
27531
27532         ol_cv_bdb_minor=0
27533         if test $ol_cv_bdb_minor = 0 ; then
27534                 cat >conftest.$ac_ext <<_ACEOF
27535 /* confdefs.h.  */
27536 _ACEOF
27537 cat confdefs.h >>conftest.$ac_ext
27538 cat >>conftest.$ac_ext <<_ACEOF
27539 /* end confdefs.h.  */
27540
27541 #include <db.h>
27542 #ifndef DB_VERSION_MINOR
27543 #       define DB_VERSION_MINOR 0
27544 #endif
27545 #if DB_VERSION_MINOR == 9
27546 __db_version
27547 #endif
27548
27549 _ACEOF
27550 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27551   $EGREP "__db_version" >/dev/null 2>&1; then
27552   ol_cv_bdb_minor=9
27553 else
27554   :
27555 fi
27556 rm -f conftest*
27557
27558         fi
27559         if test $ol_cv_bdb_minor = 0 ; then
27560                 cat >conftest.$ac_ext <<_ACEOF
27561 /* confdefs.h.  */
27562 _ACEOF
27563 cat confdefs.h >>conftest.$ac_ext
27564 cat >>conftest.$ac_ext <<_ACEOF
27565 /* end confdefs.h.  */
27566
27567 #include <db.h>
27568 #ifndef DB_VERSION_MINOR
27569 #       define DB_VERSION_MINOR 0
27570 #endif
27571 #if DB_VERSION_MINOR == 8
27572 __db_version
27573 #endif
27574
27575 _ACEOF
27576 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27577   $EGREP "__db_version" >/dev/null 2>&1; then
27578   ol_cv_bdb_minor=8
27579 else
27580   :
27581 fi
27582 rm -f conftest*
27583
27584         fi
27585         if test $ol_cv_bdb_minor = 0 ; then
27586                 cat >conftest.$ac_ext <<_ACEOF
27587 /* confdefs.h.  */
27588 _ACEOF
27589 cat confdefs.h >>conftest.$ac_ext
27590 cat >>conftest.$ac_ext <<_ACEOF
27591 /* end confdefs.h.  */
27592
27593 #include <db.h>
27594 #ifndef DB_VERSION_MINOR
27595 #       define DB_VERSION_MINOR 0
27596 #endif
27597 #if DB_VERSION_MINOR == 7
27598 __db_version
27599 #endif
27600
27601 _ACEOF
27602 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27603   $EGREP "__db_version" >/dev/null 2>&1; then
27604   ol_cv_bdb_minor=7
27605 else
27606   :
27607 fi
27608 rm -f conftest*
27609
27610         fi
27611         if test $ol_cv_bdb_minor = 0 ; then
27612                 cat >conftest.$ac_ext <<_ACEOF
27613 /* confdefs.h.  */
27614 _ACEOF
27615 cat confdefs.h >>conftest.$ac_ext
27616 cat >>conftest.$ac_ext <<_ACEOF
27617 /* end confdefs.h.  */
27618
27619 #include <db.h>
27620 #ifndef DB_VERSION_MINOR
27621 #       define DB_VERSION_MINOR 0
27622 #endif
27623 #if DB_VERSION_MINOR == 6
27624 __db_version
27625 #endif
27626
27627 _ACEOF
27628 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27629   $EGREP "__db_version" >/dev/null 2>&1; then
27630   ol_cv_bdb_minor=6
27631 else
27632   :
27633 fi
27634 rm -f conftest*
27635
27636         fi
27637         if test $ol_cv_bdb_minor = 0 ; then
27638                 cat >conftest.$ac_ext <<_ACEOF
27639 /* confdefs.h.  */
27640 _ACEOF
27641 cat confdefs.h >>conftest.$ac_ext
27642 cat >>conftest.$ac_ext <<_ACEOF
27643 /* end confdefs.h.  */
27644
27645 #include <db.h>
27646 #ifndef DB_VERSION_MINOR
27647 #       define DB_VERSION_MINOR 0
27648 #endif
27649 #if DB_VERSION_MINOR == 5
27650 __db_version
27651 #endif
27652
27653 _ACEOF
27654 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27655   $EGREP "__db_version" >/dev/null 2>&1; then
27656   ol_cv_bdb_minor=5
27657 else
27658   :
27659 fi
27660 rm -f conftest*
27661
27662         fi
27663         if test $ol_cv_bdb_minor = 0 ; then
27664                 cat >conftest.$ac_ext <<_ACEOF
27665 /* confdefs.h.  */
27666 _ACEOF
27667 cat confdefs.h >>conftest.$ac_ext
27668 cat >>conftest.$ac_ext <<_ACEOF
27669 /* end confdefs.h.  */
27670
27671 #include <db.h>
27672 #ifndef DB_VERSION_MINOR
27673 #       define DB_VERSION_MINOR 0
27674 #endif
27675 #if DB_VERSION_MINOR == 4
27676 __db_version
27677 #endif
27678
27679 _ACEOF
27680 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27681   $EGREP "__db_version" >/dev/null 2>&1; then
27682   ol_cv_bdb_minor=4
27683 else
27684   :
27685 fi
27686 rm -f conftest*
27687
27688         fi
27689         if test $ol_cv_bdb_minor = 0 ; then
27690                 cat >conftest.$ac_ext <<_ACEOF
27691 /* confdefs.h.  */
27692 _ACEOF
27693 cat confdefs.h >>conftest.$ac_ext
27694 cat >>conftest.$ac_ext <<_ACEOF
27695 /* end confdefs.h.  */
27696
27697 #include <db.h>
27698 #ifndef DB_VERSION_MINOR
27699 #       define DB_VERSION_MINOR 0
27700 #endif
27701 #if DB_VERSION_MINOR == 3
27702 __db_version
27703 #endif
27704
27705 _ACEOF
27706 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27707   $EGREP "__db_version" >/dev/null 2>&1; then
27708   ol_cv_bdb_minor=3
27709 else
27710   :
27711 fi
27712 rm -f conftest*
27713
27714         fi
27715         if test $ol_cv_bdb_minor = 0 ; then
27716                 cat >conftest.$ac_ext <<_ACEOF
27717 /* confdefs.h.  */
27718 _ACEOF
27719 cat confdefs.h >>conftest.$ac_ext
27720 cat >>conftest.$ac_ext <<_ACEOF
27721 /* end confdefs.h.  */
27722
27723 #include <db.h>
27724 #ifndef DB_VERSION_MINOR
27725 #       define DB_VERSION_MINOR 0
27726 #endif
27727 #if DB_VERSION_MINOR == 2
27728 __db_version
27729 #endif
27730
27731 _ACEOF
27732 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27733   $EGREP "__db_version" >/dev/null 2>&1; then
27734   ol_cv_bdb_minor=2
27735 else
27736   :
27737 fi
27738 rm -f conftest*
27739
27740         fi
27741         if test $ol_cv_bdb_minor = 0 ; then
27742                 cat >conftest.$ac_ext <<_ACEOF
27743 /* confdefs.h.  */
27744 _ACEOF
27745 cat confdefs.h >>conftest.$ac_ext
27746 cat >>conftest.$ac_ext <<_ACEOF
27747 /* end confdefs.h.  */
27748
27749 #include <db.h>
27750 #ifndef DB_VERSION_MINOR
27751 #       define DB_VERSION_MINOR 0
27752 #endif
27753 #if DB_VERSION_MINOR == 1
27754 __db_version
27755 #endif
27756
27757 _ACEOF
27758 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27759   $EGREP "__db_version" >/dev/null 2>&1; then
27760   ol_cv_bdb_minor=1
27761 else
27762   :
27763 fi
27764 rm -f conftest*
27765
27766         fi
27767
27768 fi
27769 echo "$as_me:$LINENO: result: $ol_cv_bdb_minor" >&5
27770 echo "${ECHO_T}$ol_cv_bdb_minor" >&6
27771
27772 if test $ol_cv_bdb_major = 4 ; then
27773         if test $ol_cv_bdb_minor = 6 ; then
27774                 if test $ol_cv_lib_db = no ; then
27775         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.6)" >&5
27776 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.6)... $ECHO_C" >&6
27777 if test "${ol_cv_db_db_4_dot_6+set}" = set; then
27778   echo $ECHO_N "(cached) $ECHO_C" >&6
27779 else
27780
27781         ol_DB_LIB=-ldb-4.6
27782         ol_LIBS=$LIBS
27783         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
27784
27785         cat >conftest.$ac_ext <<_ACEOF
27786 /* confdefs.h.  */
27787 _ACEOF
27788 cat confdefs.h >>conftest.$ac_ext
27789 cat >>conftest.$ac_ext <<_ACEOF
27790 /* end confdefs.h.  */
27791
27792 #ifdef HAVE_DB_185_H
27793 # include <db_185.h>
27794 #else
27795 # include <db.h>
27796 #endif
27797
27798 #ifndef DB_VERSION_MAJOR
27799 # define DB_VERSION_MAJOR 1
27800 #endif
27801
27802 #ifndef NULL
27803 #define NULL ((void*)0)
27804 #endif
27805
27806 int
27807 main ()
27808 {
27809
27810 #if DB_VERSION_MAJOR > 1
27811         {
27812                 char *version;
27813                 int major, minor, patch;
27814
27815                 version = db_version( &major, &minor, &patch );
27816
27817                 if( major != DB_VERSION_MAJOR ||
27818                         minor < DB_VERSION_MINOR )
27819                 {
27820                         printf("Berkeley DB version mismatch\n"
27821                                 "\theader: %s\n\tlibrary: %s\n",
27822                                 DB_VERSION_STRING, version);
27823                         return 1;
27824                 }
27825         }
27826 #endif
27827
27828 #if DB_VERSION_MAJOR > 2
27829         db_env_create( NULL, 0 );
27830 #elif DB_VERSION_MAJOR > 1
27831         db_appexit( NULL );
27832 #else
27833         (void) dbopen( NULL, 0, 0, 0, NULL);
27834 #endif
27835
27836   ;
27837   return 0;
27838 }
27839 _ACEOF
27840 rm -f conftest.$ac_objext conftest$ac_exeext
27841 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27842   (eval $ac_link) 2>conftest.er1
27843   ac_status=$?
27844   grep -v '^ *+' conftest.er1 >conftest.err
27845   rm -f conftest.er1
27846   cat conftest.err >&5
27847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27848   (exit $ac_status); } &&
27849          { ac_try='test -z "$ac_c_werror_flag"
27850                          || test ! -s conftest.err'
27851   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27852   (eval $ac_try) 2>&5
27853   ac_status=$?
27854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27855   (exit $ac_status); }; } &&
27856          { ac_try='test -s conftest$ac_exeext'
27857   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27858   (eval $ac_try) 2>&5
27859   ac_status=$?
27860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27861   (exit $ac_status); }; }; then
27862   ol_cv_db_db_4_dot_6=yes
27863 else
27864   echo "$as_me: failed program was:" >&5
27865 sed 's/^/| /' conftest.$ac_ext >&5
27866
27867 ol_cv_db_db_4_dot_6=no
27868 fi
27869 rm -f conftest.err conftest.$ac_objext \
27870       conftest$ac_exeext conftest.$ac_ext
27871
27872         LIBS="$ol_LIBS"
27873
27874 fi
27875 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_6" >&5
27876 echo "${ECHO_T}$ol_cv_db_db_4_dot_6" >&6
27877
27878         if test $ol_cv_db_db_4_dot_6 = yes ; then
27879                 ol_cv_lib_db=-ldb-4.6
27880         fi
27881 fi
27882
27883                 if test $ol_cv_lib_db = no ; then
27884         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb46)" >&5
27885 echo $ECHO_N "checking for Berkeley DB link (-ldb46)... $ECHO_C" >&6
27886 if test "${ol_cv_db_db46+set}" = set; then
27887   echo $ECHO_N "(cached) $ECHO_C" >&6
27888 else
27889
27890         ol_DB_LIB=-ldb46
27891         ol_LIBS=$LIBS
27892         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
27893
27894         cat >conftest.$ac_ext <<_ACEOF
27895 /* confdefs.h.  */
27896 _ACEOF
27897 cat confdefs.h >>conftest.$ac_ext
27898 cat >>conftest.$ac_ext <<_ACEOF
27899 /* end confdefs.h.  */
27900
27901 #ifdef HAVE_DB_185_H
27902 # include <db_185.h>
27903 #else
27904 # include <db.h>
27905 #endif
27906
27907 #ifndef DB_VERSION_MAJOR
27908 # define DB_VERSION_MAJOR 1
27909 #endif
27910
27911 #ifndef NULL
27912 #define NULL ((void*)0)
27913 #endif
27914
27915 int
27916 main ()
27917 {
27918
27919 #if DB_VERSION_MAJOR > 1
27920         {
27921                 char *version;
27922                 int major, minor, patch;
27923
27924                 version = db_version( &major, &minor, &patch );
27925
27926                 if( major != DB_VERSION_MAJOR ||
27927                         minor < DB_VERSION_MINOR )
27928                 {
27929                         printf("Berkeley DB version mismatch\n"
27930                                 "\theader: %s\n\tlibrary: %s\n",
27931                                 DB_VERSION_STRING, version);
27932                         return 1;
27933                 }
27934         }
27935 #endif
27936
27937 #if DB_VERSION_MAJOR > 2
27938         db_env_create( NULL, 0 );
27939 #elif DB_VERSION_MAJOR > 1
27940         db_appexit( NULL );
27941 #else
27942         (void) dbopen( NULL, 0, 0, 0, NULL);
27943 #endif
27944
27945   ;
27946   return 0;
27947 }
27948 _ACEOF
27949 rm -f conftest.$ac_objext conftest$ac_exeext
27950 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27951   (eval $ac_link) 2>conftest.er1
27952   ac_status=$?
27953   grep -v '^ *+' conftest.er1 >conftest.err
27954   rm -f conftest.er1
27955   cat conftest.err >&5
27956   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27957   (exit $ac_status); } &&
27958          { ac_try='test -z "$ac_c_werror_flag"
27959                          || test ! -s conftest.err'
27960   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27961   (eval $ac_try) 2>&5
27962   ac_status=$?
27963   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27964   (exit $ac_status); }; } &&
27965          { ac_try='test -s conftest$ac_exeext'
27966   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27967   (eval $ac_try) 2>&5
27968   ac_status=$?
27969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27970   (exit $ac_status); }; }; then
27971   ol_cv_db_db46=yes
27972 else
27973   echo "$as_me: failed program was:" >&5
27974 sed 's/^/| /' conftest.$ac_ext >&5
27975
27976 ol_cv_db_db46=no
27977 fi
27978 rm -f conftest.err conftest.$ac_objext \
27979       conftest$ac_exeext conftest.$ac_ext
27980
27981         LIBS="$ol_LIBS"
27982
27983 fi
27984 echo "$as_me:$LINENO: result: $ol_cv_db_db46" >&5
27985 echo "${ECHO_T}$ol_cv_db_db46" >&6
27986
27987         if test $ol_cv_db_db46 = yes ; then
27988                 ol_cv_lib_db=-ldb46
27989         fi
27990 fi
27991
27992                 if test $ol_cv_lib_db = no ; then
27993         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-46)" >&5
27994 echo $ECHO_N "checking for Berkeley DB link (-ldb-46)... $ECHO_C" >&6
27995 if test "${ol_cv_db_db_46+set}" = set; then
27996   echo $ECHO_N "(cached) $ECHO_C" >&6
27997 else
27998
27999         ol_DB_LIB=-ldb-46
28000         ol_LIBS=$LIBS
28001         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28002
28003         cat >conftest.$ac_ext <<_ACEOF
28004 /* confdefs.h.  */
28005 _ACEOF
28006 cat confdefs.h >>conftest.$ac_ext
28007 cat >>conftest.$ac_ext <<_ACEOF
28008 /* end confdefs.h.  */
28009
28010 #ifdef HAVE_DB_185_H
28011 # include <db_185.h>
28012 #else
28013 # include <db.h>
28014 #endif
28015
28016 #ifndef DB_VERSION_MAJOR
28017 # define DB_VERSION_MAJOR 1
28018 #endif
28019
28020 #ifndef NULL
28021 #define NULL ((void*)0)
28022 #endif
28023
28024 int
28025 main ()
28026 {
28027
28028 #if DB_VERSION_MAJOR > 1
28029         {
28030                 char *version;
28031                 int major, minor, patch;
28032
28033                 version = db_version( &major, &minor, &patch );
28034
28035                 if( major != DB_VERSION_MAJOR ||
28036                         minor < DB_VERSION_MINOR )
28037                 {
28038                         printf("Berkeley DB version mismatch\n"
28039                                 "\theader: %s\n\tlibrary: %s\n",
28040                                 DB_VERSION_STRING, version);
28041                         return 1;
28042                 }
28043         }
28044 #endif
28045
28046 #if DB_VERSION_MAJOR > 2
28047         db_env_create( NULL, 0 );
28048 #elif DB_VERSION_MAJOR > 1
28049         db_appexit( NULL );
28050 #else
28051         (void) dbopen( NULL, 0, 0, 0, NULL);
28052 #endif
28053
28054   ;
28055   return 0;
28056 }
28057 _ACEOF
28058 rm -f conftest.$ac_objext conftest$ac_exeext
28059 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28060   (eval $ac_link) 2>conftest.er1
28061   ac_status=$?
28062   grep -v '^ *+' conftest.er1 >conftest.err
28063   rm -f conftest.er1
28064   cat conftest.err >&5
28065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28066   (exit $ac_status); } &&
28067          { ac_try='test -z "$ac_c_werror_flag"
28068                          || test ! -s conftest.err'
28069   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28070   (eval $ac_try) 2>&5
28071   ac_status=$?
28072   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28073   (exit $ac_status); }; } &&
28074          { ac_try='test -s conftest$ac_exeext'
28075   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28076   (eval $ac_try) 2>&5
28077   ac_status=$?
28078   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28079   (exit $ac_status); }; }; then
28080   ol_cv_db_db_46=yes
28081 else
28082   echo "$as_me: failed program was:" >&5
28083 sed 's/^/| /' conftest.$ac_ext >&5
28084
28085 ol_cv_db_db_46=no
28086 fi
28087 rm -f conftest.err conftest.$ac_objext \
28088       conftest$ac_exeext conftest.$ac_ext
28089
28090         LIBS="$ol_LIBS"
28091
28092 fi
28093 echo "$as_me:$LINENO: result: $ol_cv_db_db_46" >&5
28094 echo "${ECHO_T}$ol_cv_db_db_46" >&6
28095
28096         if test $ol_cv_db_db_46 = yes ; then
28097                 ol_cv_lib_db=-ldb-46
28098         fi
28099 fi
28100
28101                 if test $ol_cv_lib_db = no ; then
28102         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-6)" >&5
28103 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-6)... $ECHO_C" >&6
28104 if test "${ol_cv_db_db_4_6+set}" = set; then
28105   echo $ECHO_N "(cached) $ECHO_C" >&6
28106 else
28107
28108         ol_DB_LIB=-ldb-4-6
28109         ol_LIBS=$LIBS
28110         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28111
28112         cat >conftest.$ac_ext <<_ACEOF
28113 /* confdefs.h.  */
28114 _ACEOF
28115 cat confdefs.h >>conftest.$ac_ext
28116 cat >>conftest.$ac_ext <<_ACEOF
28117 /* end confdefs.h.  */
28118
28119 #ifdef HAVE_DB_185_H
28120 # include <db_185.h>
28121 #else
28122 # include <db.h>
28123 #endif
28124
28125 #ifndef DB_VERSION_MAJOR
28126 # define DB_VERSION_MAJOR 1
28127 #endif
28128
28129 #ifndef NULL
28130 #define NULL ((void*)0)
28131 #endif
28132
28133 int
28134 main ()
28135 {
28136
28137 #if DB_VERSION_MAJOR > 1
28138         {
28139                 char *version;
28140                 int major, minor, patch;
28141
28142                 version = db_version( &major, &minor, &patch );
28143
28144                 if( major != DB_VERSION_MAJOR ||
28145                         minor < DB_VERSION_MINOR )
28146                 {
28147                         printf("Berkeley DB version mismatch\n"
28148                                 "\theader: %s\n\tlibrary: %s\n",
28149                                 DB_VERSION_STRING, version);
28150                         return 1;
28151                 }
28152         }
28153 #endif
28154
28155 #if DB_VERSION_MAJOR > 2
28156         db_env_create( NULL, 0 );
28157 #elif DB_VERSION_MAJOR > 1
28158         db_appexit( NULL );
28159 #else
28160         (void) dbopen( NULL, 0, 0, 0, NULL);
28161 #endif
28162
28163   ;
28164   return 0;
28165 }
28166 _ACEOF
28167 rm -f conftest.$ac_objext conftest$ac_exeext
28168 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28169   (eval $ac_link) 2>conftest.er1
28170   ac_status=$?
28171   grep -v '^ *+' conftest.er1 >conftest.err
28172   rm -f conftest.er1
28173   cat conftest.err >&5
28174   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28175   (exit $ac_status); } &&
28176          { ac_try='test -z "$ac_c_werror_flag"
28177                          || test ! -s conftest.err'
28178   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28179   (eval $ac_try) 2>&5
28180   ac_status=$?
28181   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28182   (exit $ac_status); }; } &&
28183          { ac_try='test -s conftest$ac_exeext'
28184   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28185   (eval $ac_try) 2>&5
28186   ac_status=$?
28187   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28188   (exit $ac_status); }; }; then
28189   ol_cv_db_db_4_6=yes
28190 else
28191   echo "$as_me: failed program was:" >&5
28192 sed 's/^/| /' conftest.$ac_ext >&5
28193
28194 ol_cv_db_db_4_6=no
28195 fi
28196 rm -f conftest.err conftest.$ac_objext \
28197       conftest$ac_exeext conftest.$ac_ext
28198
28199         LIBS="$ol_LIBS"
28200
28201 fi
28202 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_6" >&5
28203 echo "${ECHO_T}$ol_cv_db_db_4_6" >&6
28204
28205         if test $ol_cv_db_db_4_6 = yes ; then
28206                 ol_cv_lib_db=-ldb-4-6
28207         fi
28208 fi
28209
28210         elif test $ol_cv_bdb_minor = 5 ; then
28211                 if test $ol_cv_lib_db = no ; then
28212         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.5)" >&5
28213 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.5)... $ECHO_C" >&6
28214 if test "${ol_cv_db_db_4_dot_5+set}" = set; then
28215   echo $ECHO_N "(cached) $ECHO_C" >&6
28216 else
28217
28218         ol_DB_LIB=-ldb-4.5
28219         ol_LIBS=$LIBS
28220         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28221
28222         cat >conftest.$ac_ext <<_ACEOF
28223 /* confdefs.h.  */
28224 _ACEOF
28225 cat confdefs.h >>conftest.$ac_ext
28226 cat >>conftest.$ac_ext <<_ACEOF
28227 /* end confdefs.h.  */
28228
28229 #ifdef HAVE_DB_185_H
28230 # include <db_185.h>
28231 #else
28232 # include <db.h>
28233 #endif
28234
28235 #ifndef DB_VERSION_MAJOR
28236 # define DB_VERSION_MAJOR 1
28237 #endif
28238
28239 #ifndef NULL
28240 #define NULL ((void*)0)
28241 #endif
28242
28243 int
28244 main ()
28245 {
28246
28247 #if DB_VERSION_MAJOR > 1
28248         {
28249                 char *version;
28250                 int major, minor, patch;
28251
28252                 version = db_version( &major, &minor, &patch );
28253
28254                 if( major != DB_VERSION_MAJOR ||
28255                         minor < DB_VERSION_MINOR )
28256                 {
28257                         printf("Berkeley DB version mismatch\n"
28258                                 "\theader: %s\n\tlibrary: %s\n",
28259                                 DB_VERSION_STRING, version);
28260                         return 1;
28261                 }
28262         }
28263 #endif
28264
28265 #if DB_VERSION_MAJOR > 2
28266         db_env_create( NULL, 0 );
28267 #elif DB_VERSION_MAJOR > 1
28268         db_appexit( NULL );
28269 #else
28270         (void) dbopen( NULL, 0, 0, 0, NULL);
28271 #endif
28272
28273   ;
28274   return 0;
28275 }
28276 _ACEOF
28277 rm -f conftest.$ac_objext conftest$ac_exeext
28278 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28279   (eval $ac_link) 2>conftest.er1
28280   ac_status=$?
28281   grep -v '^ *+' conftest.er1 >conftest.err
28282   rm -f conftest.er1
28283   cat conftest.err >&5
28284   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28285   (exit $ac_status); } &&
28286          { ac_try='test -z "$ac_c_werror_flag"
28287                          || test ! -s conftest.err'
28288   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28289   (eval $ac_try) 2>&5
28290   ac_status=$?
28291   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28292   (exit $ac_status); }; } &&
28293          { ac_try='test -s conftest$ac_exeext'
28294   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28295   (eval $ac_try) 2>&5
28296   ac_status=$?
28297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28298   (exit $ac_status); }; }; then
28299   ol_cv_db_db_4_dot_5=yes
28300 else
28301   echo "$as_me: failed program was:" >&5
28302 sed 's/^/| /' conftest.$ac_ext >&5
28303
28304 ol_cv_db_db_4_dot_5=no
28305 fi
28306 rm -f conftest.err conftest.$ac_objext \
28307       conftest$ac_exeext conftest.$ac_ext
28308
28309         LIBS="$ol_LIBS"
28310
28311 fi
28312 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_5" >&5
28313 echo "${ECHO_T}$ol_cv_db_db_4_dot_5" >&6
28314
28315         if test $ol_cv_db_db_4_dot_5 = yes ; then
28316                 ol_cv_lib_db=-ldb-4.5
28317         fi
28318 fi
28319
28320                 if test $ol_cv_lib_db = no ; then
28321         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb45)" >&5
28322 echo $ECHO_N "checking for Berkeley DB link (-ldb45)... $ECHO_C" >&6
28323 if test "${ol_cv_db_db45+set}" = set; then
28324   echo $ECHO_N "(cached) $ECHO_C" >&6
28325 else
28326
28327         ol_DB_LIB=-ldb45
28328         ol_LIBS=$LIBS
28329         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28330
28331         cat >conftest.$ac_ext <<_ACEOF
28332 /* confdefs.h.  */
28333 _ACEOF
28334 cat confdefs.h >>conftest.$ac_ext
28335 cat >>conftest.$ac_ext <<_ACEOF
28336 /* end confdefs.h.  */
28337
28338 #ifdef HAVE_DB_185_H
28339 # include <db_185.h>
28340 #else
28341 # include <db.h>
28342 #endif
28343
28344 #ifndef DB_VERSION_MAJOR
28345 # define DB_VERSION_MAJOR 1
28346 #endif
28347
28348 #ifndef NULL
28349 #define NULL ((void*)0)
28350 #endif
28351
28352 int
28353 main ()
28354 {
28355
28356 #if DB_VERSION_MAJOR > 1
28357         {
28358                 char *version;
28359                 int major, minor, patch;
28360
28361                 version = db_version( &major, &minor, &patch );
28362
28363                 if( major != DB_VERSION_MAJOR ||
28364                         minor < DB_VERSION_MINOR )
28365                 {
28366                         printf("Berkeley DB version mismatch\n"
28367                                 "\theader: %s\n\tlibrary: %s\n",
28368                                 DB_VERSION_STRING, version);
28369                         return 1;
28370                 }
28371         }
28372 #endif
28373
28374 #if DB_VERSION_MAJOR > 2
28375         db_env_create( NULL, 0 );
28376 #elif DB_VERSION_MAJOR > 1
28377         db_appexit( NULL );
28378 #else
28379         (void) dbopen( NULL, 0, 0, 0, NULL);
28380 #endif
28381
28382   ;
28383   return 0;
28384 }
28385 _ACEOF
28386 rm -f conftest.$ac_objext conftest$ac_exeext
28387 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28388   (eval $ac_link) 2>conftest.er1
28389   ac_status=$?
28390   grep -v '^ *+' conftest.er1 >conftest.err
28391   rm -f conftest.er1
28392   cat conftest.err >&5
28393   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28394   (exit $ac_status); } &&
28395          { ac_try='test -z "$ac_c_werror_flag"
28396                          || test ! -s conftest.err'
28397   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28398   (eval $ac_try) 2>&5
28399   ac_status=$?
28400   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28401   (exit $ac_status); }; } &&
28402          { ac_try='test -s conftest$ac_exeext'
28403   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28404   (eval $ac_try) 2>&5
28405   ac_status=$?
28406   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28407   (exit $ac_status); }; }; then
28408   ol_cv_db_db45=yes
28409 else
28410   echo "$as_me: failed program was:" >&5
28411 sed 's/^/| /' conftest.$ac_ext >&5
28412
28413 ol_cv_db_db45=no
28414 fi
28415 rm -f conftest.err conftest.$ac_objext \
28416       conftest$ac_exeext conftest.$ac_ext
28417
28418         LIBS="$ol_LIBS"
28419
28420 fi
28421 echo "$as_me:$LINENO: result: $ol_cv_db_db45" >&5
28422 echo "${ECHO_T}$ol_cv_db_db45" >&6
28423
28424         if test $ol_cv_db_db45 = yes ; then
28425                 ol_cv_lib_db=-ldb45
28426         fi
28427 fi
28428
28429                 if test $ol_cv_lib_db = no ; then
28430         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-45)" >&5
28431 echo $ECHO_N "checking for Berkeley DB link (-ldb-45)... $ECHO_C" >&6
28432 if test "${ol_cv_db_db_45+set}" = set; then
28433   echo $ECHO_N "(cached) $ECHO_C" >&6
28434 else
28435
28436         ol_DB_LIB=-ldb-45
28437         ol_LIBS=$LIBS
28438         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28439
28440         cat >conftest.$ac_ext <<_ACEOF
28441 /* confdefs.h.  */
28442 _ACEOF
28443 cat confdefs.h >>conftest.$ac_ext
28444 cat >>conftest.$ac_ext <<_ACEOF
28445 /* end confdefs.h.  */
28446
28447 #ifdef HAVE_DB_185_H
28448 # include <db_185.h>
28449 #else
28450 # include <db.h>
28451 #endif
28452
28453 #ifndef DB_VERSION_MAJOR
28454 # define DB_VERSION_MAJOR 1
28455 #endif
28456
28457 #ifndef NULL
28458 #define NULL ((void*)0)
28459 #endif
28460
28461 int
28462 main ()
28463 {
28464
28465 #if DB_VERSION_MAJOR > 1
28466         {
28467                 char *version;
28468                 int major, minor, patch;
28469
28470                 version = db_version( &major, &minor, &patch );
28471
28472                 if( major != DB_VERSION_MAJOR ||
28473                         minor < DB_VERSION_MINOR )
28474                 {
28475                         printf("Berkeley DB version mismatch\n"
28476                                 "\theader: %s\n\tlibrary: %s\n",
28477                                 DB_VERSION_STRING, version);
28478                         return 1;
28479                 }
28480         }
28481 #endif
28482
28483 #if DB_VERSION_MAJOR > 2
28484         db_env_create( NULL, 0 );
28485 #elif DB_VERSION_MAJOR > 1
28486         db_appexit( NULL );
28487 #else
28488         (void) dbopen( NULL, 0, 0, 0, NULL);
28489 #endif
28490
28491   ;
28492   return 0;
28493 }
28494 _ACEOF
28495 rm -f conftest.$ac_objext conftest$ac_exeext
28496 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28497   (eval $ac_link) 2>conftest.er1
28498   ac_status=$?
28499   grep -v '^ *+' conftest.er1 >conftest.err
28500   rm -f conftest.er1
28501   cat conftest.err >&5
28502   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28503   (exit $ac_status); } &&
28504          { ac_try='test -z "$ac_c_werror_flag"
28505                          || test ! -s conftest.err'
28506   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28507   (eval $ac_try) 2>&5
28508   ac_status=$?
28509   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28510   (exit $ac_status); }; } &&
28511          { ac_try='test -s conftest$ac_exeext'
28512   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28513   (eval $ac_try) 2>&5
28514   ac_status=$?
28515   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28516   (exit $ac_status); }; }; then
28517   ol_cv_db_db_45=yes
28518 else
28519   echo "$as_me: failed program was:" >&5
28520 sed 's/^/| /' conftest.$ac_ext >&5
28521
28522 ol_cv_db_db_45=no
28523 fi
28524 rm -f conftest.err conftest.$ac_objext \
28525       conftest$ac_exeext conftest.$ac_ext
28526
28527         LIBS="$ol_LIBS"
28528
28529 fi
28530 echo "$as_me:$LINENO: result: $ol_cv_db_db_45" >&5
28531 echo "${ECHO_T}$ol_cv_db_db_45" >&6
28532
28533         if test $ol_cv_db_db_45 = yes ; then
28534                 ol_cv_lib_db=-ldb-45
28535         fi
28536 fi
28537
28538                 if test $ol_cv_lib_db = no ; then
28539         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-5)" >&5
28540 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-5)... $ECHO_C" >&6
28541 if test "${ol_cv_db_db_4_5+set}" = set; then
28542   echo $ECHO_N "(cached) $ECHO_C" >&6
28543 else
28544
28545         ol_DB_LIB=-ldb-4-5
28546         ol_LIBS=$LIBS
28547         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28548
28549         cat >conftest.$ac_ext <<_ACEOF
28550 /* confdefs.h.  */
28551 _ACEOF
28552 cat confdefs.h >>conftest.$ac_ext
28553 cat >>conftest.$ac_ext <<_ACEOF
28554 /* end confdefs.h.  */
28555
28556 #ifdef HAVE_DB_185_H
28557 # include <db_185.h>
28558 #else
28559 # include <db.h>
28560 #endif
28561
28562 #ifndef DB_VERSION_MAJOR
28563 # define DB_VERSION_MAJOR 1
28564 #endif
28565
28566 #ifndef NULL
28567 #define NULL ((void*)0)
28568 #endif
28569
28570 int
28571 main ()
28572 {
28573
28574 #if DB_VERSION_MAJOR > 1
28575         {
28576                 char *version;
28577                 int major, minor, patch;
28578
28579                 version = db_version( &major, &minor, &patch );
28580
28581                 if( major != DB_VERSION_MAJOR ||
28582                         minor < DB_VERSION_MINOR )
28583                 {
28584                         printf("Berkeley DB version mismatch\n"
28585                                 "\theader: %s\n\tlibrary: %s\n",
28586                                 DB_VERSION_STRING, version);
28587                         return 1;
28588                 }
28589         }
28590 #endif
28591
28592 #if DB_VERSION_MAJOR > 2
28593         db_env_create( NULL, 0 );
28594 #elif DB_VERSION_MAJOR > 1
28595         db_appexit( NULL );
28596 #else
28597         (void) dbopen( NULL, 0, 0, 0, NULL);
28598 #endif
28599
28600   ;
28601   return 0;
28602 }
28603 _ACEOF
28604 rm -f conftest.$ac_objext conftest$ac_exeext
28605 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28606   (eval $ac_link) 2>conftest.er1
28607   ac_status=$?
28608   grep -v '^ *+' conftest.er1 >conftest.err
28609   rm -f conftest.er1
28610   cat conftest.err >&5
28611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28612   (exit $ac_status); } &&
28613          { ac_try='test -z "$ac_c_werror_flag"
28614                          || test ! -s conftest.err'
28615   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28616   (eval $ac_try) 2>&5
28617   ac_status=$?
28618   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28619   (exit $ac_status); }; } &&
28620          { ac_try='test -s conftest$ac_exeext'
28621   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28622   (eval $ac_try) 2>&5
28623   ac_status=$?
28624   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28625   (exit $ac_status); }; }; then
28626   ol_cv_db_db_4_5=yes
28627 else
28628   echo "$as_me: failed program was:" >&5
28629 sed 's/^/| /' conftest.$ac_ext >&5
28630
28631 ol_cv_db_db_4_5=no
28632 fi
28633 rm -f conftest.err conftest.$ac_objext \
28634       conftest$ac_exeext conftest.$ac_ext
28635
28636         LIBS="$ol_LIBS"
28637
28638 fi
28639 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_5" >&5
28640 echo "${ECHO_T}$ol_cv_db_db_4_5" >&6
28641
28642         if test $ol_cv_db_db_4_5 = yes ; then
28643                 ol_cv_lib_db=-ldb-4-5
28644         fi
28645 fi
28646
28647         elif test $ol_cv_bdb_minor = 4 ; then
28648                 if test $ol_cv_lib_db = no ; then
28649         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.4)" >&5
28650 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.4)... $ECHO_C" >&6
28651 if test "${ol_cv_db_db_4_dot_4+set}" = set; then
28652   echo $ECHO_N "(cached) $ECHO_C" >&6
28653 else
28654
28655         ol_DB_LIB=-ldb-4.4
28656         ol_LIBS=$LIBS
28657         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28658
28659         cat >conftest.$ac_ext <<_ACEOF
28660 /* confdefs.h.  */
28661 _ACEOF
28662 cat confdefs.h >>conftest.$ac_ext
28663 cat >>conftest.$ac_ext <<_ACEOF
28664 /* end confdefs.h.  */
28665
28666 #ifdef HAVE_DB_185_H
28667 # include <db_185.h>
28668 #else
28669 # include <db.h>
28670 #endif
28671
28672 #ifndef DB_VERSION_MAJOR
28673 # define DB_VERSION_MAJOR 1
28674 #endif
28675
28676 #ifndef NULL
28677 #define NULL ((void*)0)
28678 #endif
28679
28680 int
28681 main ()
28682 {
28683
28684 #if DB_VERSION_MAJOR > 1
28685         {
28686                 char *version;
28687                 int major, minor, patch;
28688
28689                 version = db_version( &major, &minor, &patch );
28690
28691                 if( major != DB_VERSION_MAJOR ||
28692                         minor < DB_VERSION_MINOR )
28693                 {
28694                         printf("Berkeley DB version mismatch\n"
28695                                 "\theader: %s\n\tlibrary: %s\n",
28696                                 DB_VERSION_STRING, version);
28697                         return 1;
28698                 }
28699         }
28700 #endif
28701
28702 #if DB_VERSION_MAJOR > 2
28703         db_env_create( NULL, 0 );
28704 #elif DB_VERSION_MAJOR > 1
28705         db_appexit( NULL );
28706 #else
28707         (void) dbopen( NULL, 0, 0, 0, NULL);
28708 #endif
28709
28710   ;
28711   return 0;
28712 }
28713 _ACEOF
28714 rm -f conftest.$ac_objext conftest$ac_exeext
28715 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28716   (eval $ac_link) 2>conftest.er1
28717   ac_status=$?
28718   grep -v '^ *+' conftest.er1 >conftest.err
28719   rm -f conftest.er1
28720   cat conftest.err >&5
28721   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28722   (exit $ac_status); } &&
28723          { ac_try='test -z "$ac_c_werror_flag"
28724                          || test ! -s conftest.err'
28725   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28726   (eval $ac_try) 2>&5
28727   ac_status=$?
28728   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28729   (exit $ac_status); }; } &&
28730          { ac_try='test -s conftest$ac_exeext'
28731   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28732   (eval $ac_try) 2>&5
28733   ac_status=$?
28734   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28735   (exit $ac_status); }; }; then
28736   ol_cv_db_db_4_dot_4=yes
28737 else
28738   echo "$as_me: failed program was:" >&5
28739 sed 's/^/| /' conftest.$ac_ext >&5
28740
28741 ol_cv_db_db_4_dot_4=no
28742 fi
28743 rm -f conftest.err conftest.$ac_objext \
28744       conftest$ac_exeext conftest.$ac_ext
28745
28746         LIBS="$ol_LIBS"
28747
28748 fi
28749 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_4" >&5
28750 echo "${ECHO_T}$ol_cv_db_db_4_dot_4" >&6
28751
28752         if test $ol_cv_db_db_4_dot_4 = yes ; then
28753                 ol_cv_lib_db=-ldb-4.4
28754         fi
28755 fi
28756
28757                 if test $ol_cv_lib_db = no ; then
28758         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb44)" >&5
28759 echo $ECHO_N "checking for Berkeley DB link (-ldb44)... $ECHO_C" >&6
28760 if test "${ol_cv_db_db44+set}" = set; then
28761   echo $ECHO_N "(cached) $ECHO_C" >&6
28762 else
28763
28764         ol_DB_LIB=-ldb44
28765         ol_LIBS=$LIBS
28766         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28767
28768         cat >conftest.$ac_ext <<_ACEOF
28769 /* confdefs.h.  */
28770 _ACEOF
28771 cat confdefs.h >>conftest.$ac_ext
28772 cat >>conftest.$ac_ext <<_ACEOF
28773 /* end confdefs.h.  */
28774
28775 #ifdef HAVE_DB_185_H
28776 # include <db_185.h>
28777 #else
28778 # include <db.h>
28779 #endif
28780
28781 #ifndef DB_VERSION_MAJOR
28782 # define DB_VERSION_MAJOR 1
28783 #endif
28784
28785 #ifndef NULL
28786 #define NULL ((void*)0)
28787 #endif
28788
28789 int
28790 main ()
28791 {
28792
28793 #if DB_VERSION_MAJOR > 1
28794         {
28795                 char *version;
28796                 int major, minor, patch;
28797
28798                 version = db_version( &major, &minor, &patch );
28799
28800                 if( major != DB_VERSION_MAJOR ||
28801                         minor < DB_VERSION_MINOR )
28802                 {
28803                         printf("Berkeley DB version mismatch\n"
28804                                 "\theader: %s\n\tlibrary: %s\n",
28805                                 DB_VERSION_STRING, version);
28806                         return 1;
28807                 }
28808         }
28809 #endif
28810
28811 #if DB_VERSION_MAJOR > 2
28812         db_env_create( NULL, 0 );
28813 #elif DB_VERSION_MAJOR > 1
28814         db_appexit( NULL );
28815 #else
28816         (void) dbopen( NULL, 0, 0, 0, NULL);
28817 #endif
28818
28819   ;
28820   return 0;
28821 }
28822 _ACEOF
28823 rm -f conftest.$ac_objext conftest$ac_exeext
28824 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28825   (eval $ac_link) 2>conftest.er1
28826   ac_status=$?
28827   grep -v '^ *+' conftest.er1 >conftest.err
28828   rm -f conftest.er1
28829   cat conftest.err >&5
28830   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28831   (exit $ac_status); } &&
28832          { ac_try='test -z "$ac_c_werror_flag"
28833                          || test ! -s conftest.err'
28834   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28835   (eval $ac_try) 2>&5
28836   ac_status=$?
28837   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28838   (exit $ac_status); }; } &&
28839          { ac_try='test -s conftest$ac_exeext'
28840   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28841   (eval $ac_try) 2>&5
28842   ac_status=$?
28843   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28844   (exit $ac_status); }; }; then
28845   ol_cv_db_db44=yes
28846 else
28847   echo "$as_me: failed program was:" >&5
28848 sed 's/^/| /' conftest.$ac_ext >&5
28849
28850 ol_cv_db_db44=no
28851 fi
28852 rm -f conftest.err conftest.$ac_objext \
28853       conftest$ac_exeext conftest.$ac_ext
28854
28855         LIBS="$ol_LIBS"
28856
28857 fi
28858 echo "$as_me:$LINENO: result: $ol_cv_db_db44" >&5
28859 echo "${ECHO_T}$ol_cv_db_db44" >&6
28860
28861         if test $ol_cv_db_db44 = yes ; then
28862                 ol_cv_lib_db=-ldb44
28863         fi
28864 fi
28865
28866                 if test $ol_cv_lib_db = no ; then
28867         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-44)" >&5
28868 echo $ECHO_N "checking for Berkeley DB link (-ldb-44)... $ECHO_C" >&6
28869 if test "${ol_cv_db_db_44+set}" = set; then
28870   echo $ECHO_N "(cached) $ECHO_C" >&6
28871 else
28872
28873         ol_DB_LIB=-ldb-44
28874         ol_LIBS=$LIBS
28875         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28876
28877         cat >conftest.$ac_ext <<_ACEOF
28878 /* confdefs.h.  */
28879 _ACEOF
28880 cat confdefs.h >>conftest.$ac_ext
28881 cat >>conftest.$ac_ext <<_ACEOF
28882 /* end confdefs.h.  */
28883
28884 #ifdef HAVE_DB_185_H
28885 # include <db_185.h>
28886 #else
28887 # include <db.h>
28888 #endif
28889
28890 #ifndef DB_VERSION_MAJOR
28891 # define DB_VERSION_MAJOR 1
28892 #endif
28893
28894 #ifndef NULL
28895 #define NULL ((void*)0)
28896 #endif
28897
28898 int
28899 main ()
28900 {
28901
28902 #if DB_VERSION_MAJOR > 1
28903         {
28904                 char *version;
28905                 int major, minor, patch;
28906
28907                 version = db_version( &major, &minor, &patch );
28908
28909                 if( major != DB_VERSION_MAJOR ||
28910                         minor < DB_VERSION_MINOR )
28911                 {
28912                         printf("Berkeley DB version mismatch\n"
28913                                 "\theader: %s\n\tlibrary: %s\n",
28914                                 DB_VERSION_STRING, version);
28915                         return 1;
28916                 }
28917         }
28918 #endif
28919
28920 #if DB_VERSION_MAJOR > 2
28921         db_env_create( NULL, 0 );
28922 #elif DB_VERSION_MAJOR > 1
28923         db_appexit( NULL );
28924 #else
28925         (void) dbopen( NULL, 0, 0, 0, NULL);
28926 #endif
28927
28928   ;
28929   return 0;
28930 }
28931 _ACEOF
28932 rm -f conftest.$ac_objext conftest$ac_exeext
28933 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28934   (eval $ac_link) 2>conftest.er1
28935   ac_status=$?
28936   grep -v '^ *+' conftest.er1 >conftest.err
28937   rm -f conftest.er1
28938   cat conftest.err >&5
28939   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28940   (exit $ac_status); } &&
28941          { ac_try='test -z "$ac_c_werror_flag"
28942                          || test ! -s conftest.err'
28943   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28944   (eval $ac_try) 2>&5
28945   ac_status=$?
28946   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28947   (exit $ac_status); }; } &&
28948          { ac_try='test -s conftest$ac_exeext'
28949   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28950   (eval $ac_try) 2>&5
28951   ac_status=$?
28952   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28953   (exit $ac_status); }; }; then
28954   ol_cv_db_db_44=yes
28955 else
28956   echo "$as_me: failed program was:" >&5
28957 sed 's/^/| /' conftest.$ac_ext >&5
28958
28959 ol_cv_db_db_44=no
28960 fi
28961 rm -f conftest.err conftest.$ac_objext \
28962       conftest$ac_exeext conftest.$ac_ext
28963
28964         LIBS="$ol_LIBS"
28965
28966 fi
28967 echo "$as_me:$LINENO: result: $ol_cv_db_db_44" >&5
28968 echo "${ECHO_T}$ol_cv_db_db_44" >&6
28969
28970         if test $ol_cv_db_db_44 = yes ; then
28971                 ol_cv_lib_db=-ldb-44
28972         fi
28973 fi
28974
28975                 if test $ol_cv_lib_db = no ; then
28976         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-4)" >&5
28977 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-4)... $ECHO_C" >&6
28978 if test "${ol_cv_db_db_4_4+set}" = set; then
28979   echo $ECHO_N "(cached) $ECHO_C" >&6
28980 else
28981
28982         ol_DB_LIB=-ldb-4-4
28983         ol_LIBS=$LIBS
28984         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28985
28986         cat >conftest.$ac_ext <<_ACEOF
28987 /* confdefs.h.  */
28988 _ACEOF
28989 cat confdefs.h >>conftest.$ac_ext
28990 cat >>conftest.$ac_ext <<_ACEOF
28991 /* end confdefs.h.  */
28992
28993 #ifdef HAVE_DB_185_H
28994 # include <db_185.h>
28995 #else
28996 # include <db.h>
28997 #endif
28998
28999 #ifndef DB_VERSION_MAJOR
29000 # define DB_VERSION_MAJOR 1
29001 #endif
29002
29003 #ifndef NULL
29004 #define NULL ((void*)0)
29005 #endif
29006
29007 int
29008 main ()
29009 {
29010
29011 #if DB_VERSION_MAJOR > 1
29012         {
29013                 char *version;
29014                 int major, minor, patch;
29015
29016                 version = db_version( &major, &minor, &patch );
29017
29018                 if( major != DB_VERSION_MAJOR ||
29019                         minor < DB_VERSION_MINOR )
29020                 {
29021                         printf("Berkeley DB version mismatch\n"
29022                                 "\theader: %s\n\tlibrary: %s\n",
29023                                 DB_VERSION_STRING, version);
29024                         return 1;
29025                 }
29026         }
29027 #endif
29028
29029 #if DB_VERSION_MAJOR > 2
29030         db_env_create( NULL, 0 );
29031 #elif DB_VERSION_MAJOR > 1
29032         db_appexit( NULL );
29033 #else
29034         (void) dbopen( NULL, 0, 0, 0, NULL);
29035 #endif
29036
29037   ;
29038   return 0;
29039 }
29040 _ACEOF
29041 rm -f conftest.$ac_objext conftest$ac_exeext
29042 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29043   (eval $ac_link) 2>conftest.er1
29044   ac_status=$?
29045   grep -v '^ *+' conftest.er1 >conftest.err
29046   rm -f conftest.er1
29047   cat conftest.err >&5
29048   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29049   (exit $ac_status); } &&
29050          { ac_try='test -z "$ac_c_werror_flag"
29051                          || test ! -s conftest.err'
29052   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29053   (eval $ac_try) 2>&5
29054   ac_status=$?
29055   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29056   (exit $ac_status); }; } &&
29057          { ac_try='test -s conftest$ac_exeext'
29058   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29059   (eval $ac_try) 2>&5
29060   ac_status=$?
29061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29062   (exit $ac_status); }; }; then
29063   ol_cv_db_db_4_4=yes
29064 else
29065   echo "$as_me: failed program was:" >&5
29066 sed 's/^/| /' conftest.$ac_ext >&5
29067
29068 ol_cv_db_db_4_4=no
29069 fi
29070 rm -f conftest.err conftest.$ac_objext \
29071       conftest$ac_exeext conftest.$ac_ext
29072
29073         LIBS="$ol_LIBS"
29074
29075 fi
29076 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_4" >&5
29077 echo "${ECHO_T}$ol_cv_db_db_4_4" >&6
29078
29079         if test $ol_cv_db_db_4_4 = yes ; then
29080                 ol_cv_lib_db=-ldb-4-4
29081         fi
29082 fi
29083
29084         elif test $ol_cv_bdb_minor = 3 ; then
29085                 if test $ol_cv_lib_db = no ; then
29086         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.3)" >&5
29087 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.3)... $ECHO_C" >&6
29088 if test "${ol_cv_db_db_4_dot_3+set}" = set; then
29089   echo $ECHO_N "(cached) $ECHO_C" >&6
29090 else
29091
29092         ol_DB_LIB=-ldb-4.3
29093         ol_LIBS=$LIBS
29094         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29095
29096         cat >conftest.$ac_ext <<_ACEOF
29097 /* confdefs.h.  */
29098 _ACEOF
29099 cat confdefs.h >>conftest.$ac_ext
29100 cat >>conftest.$ac_ext <<_ACEOF
29101 /* end confdefs.h.  */
29102
29103 #ifdef HAVE_DB_185_H
29104 # include <db_185.h>
29105 #else
29106 # include <db.h>
29107 #endif
29108
29109 #ifndef DB_VERSION_MAJOR
29110 # define DB_VERSION_MAJOR 1
29111 #endif
29112
29113 #ifndef NULL
29114 #define NULL ((void*)0)
29115 #endif
29116
29117 int
29118 main ()
29119 {
29120
29121 #if DB_VERSION_MAJOR > 1
29122         {
29123                 char *version;
29124                 int major, minor, patch;
29125
29126                 version = db_version( &major, &minor, &patch );
29127
29128                 if( major != DB_VERSION_MAJOR ||
29129                         minor < DB_VERSION_MINOR )
29130                 {
29131                         printf("Berkeley DB version mismatch\n"
29132                                 "\theader: %s\n\tlibrary: %s\n",
29133                                 DB_VERSION_STRING, version);
29134                         return 1;
29135                 }
29136         }
29137 #endif
29138
29139 #if DB_VERSION_MAJOR > 2
29140         db_env_create( NULL, 0 );
29141 #elif DB_VERSION_MAJOR > 1
29142         db_appexit( NULL );
29143 #else
29144         (void) dbopen( NULL, 0, 0, 0, NULL);
29145 #endif
29146
29147   ;
29148   return 0;
29149 }
29150 _ACEOF
29151 rm -f conftest.$ac_objext conftest$ac_exeext
29152 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29153   (eval $ac_link) 2>conftest.er1
29154   ac_status=$?
29155   grep -v '^ *+' conftest.er1 >conftest.err
29156   rm -f conftest.er1
29157   cat conftest.err >&5
29158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29159   (exit $ac_status); } &&
29160          { ac_try='test -z "$ac_c_werror_flag"
29161                          || test ! -s conftest.err'
29162   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29163   (eval $ac_try) 2>&5
29164   ac_status=$?
29165   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29166   (exit $ac_status); }; } &&
29167          { ac_try='test -s conftest$ac_exeext'
29168   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29169   (eval $ac_try) 2>&5
29170   ac_status=$?
29171   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29172   (exit $ac_status); }; }; then
29173   ol_cv_db_db_4_dot_3=yes
29174 else
29175   echo "$as_me: failed program was:" >&5
29176 sed 's/^/| /' conftest.$ac_ext >&5
29177
29178 ol_cv_db_db_4_dot_3=no
29179 fi
29180 rm -f conftest.err conftest.$ac_objext \
29181       conftest$ac_exeext conftest.$ac_ext
29182
29183         LIBS="$ol_LIBS"
29184
29185 fi
29186 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_3" >&5
29187 echo "${ECHO_T}$ol_cv_db_db_4_dot_3" >&6
29188
29189         if test $ol_cv_db_db_4_dot_3 = yes ; then
29190                 ol_cv_lib_db=-ldb-4.3
29191         fi
29192 fi
29193
29194                 if test $ol_cv_lib_db = no ; then
29195         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb43)" >&5
29196 echo $ECHO_N "checking for Berkeley DB link (-ldb43)... $ECHO_C" >&6
29197 if test "${ol_cv_db_db43+set}" = set; then
29198   echo $ECHO_N "(cached) $ECHO_C" >&6
29199 else
29200
29201         ol_DB_LIB=-ldb43
29202         ol_LIBS=$LIBS
29203         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29204
29205         cat >conftest.$ac_ext <<_ACEOF
29206 /* confdefs.h.  */
29207 _ACEOF
29208 cat confdefs.h >>conftest.$ac_ext
29209 cat >>conftest.$ac_ext <<_ACEOF
29210 /* end confdefs.h.  */
29211
29212 #ifdef HAVE_DB_185_H
29213 # include <db_185.h>
29214 #else
29215 # include <db.h>
29216 #endif
29217
29218 #ifndef DB_VERSION_MAJOR
29219 # define DB_VERSION_MAJOR 1
29220 #endif
29221
29222 #ifndef NULL
29223 #define NULL ((void*)0)
29224 #endif
29225
29226 int
29227 main ()
29228 {
29229
29230 #if DB_VERSION_MAJOR > 1
29231         {
29232                 char *version;
29233                 int major, minor, patch;
29234
29235                 version = db_version( &major, &minor, &patch );
29236
29237                 if( major != DB_VERSION_MAJOR ||
29238                         minor < DB_VERSION_MINOR )
29239                 {
29240                         printf("Berkeley DB version mismatch\n"
29241                                 "\theader: %s\n\tlibrary: %s\n",
29242                                 DB_VERSION_STRING, version);
29243                         return 1;
29244                 }
29245         }
29246 #endif
29247
29248 #if DB_VERSION_MAJOR > 2
29249         db_env_create( NULL, 0 );
29250 #elif DB_VERSION_MAJOR > 1
29251         db_appexit( NULL );
29252 #else
29253         (void) dbopen( NULL, 0, 0, 0, NULL);
29254 #endif
29255
29256   ;
29257   return 0;
29258 }
29259 _ACEOF
29260 rm -f conftest.$ac_objext conftest$ac_exeext
29261 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29262   (eval $ac_link) 2>conftest.er1
29263   ac_status=$?
29264   grep -v '^ *+' conftest.er1 >conftest.err
29265   rm -f conftest.er1
29266   cat conftest.err >&5
29267   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29268   (exit $ac_status); } &&
29269          { ac_try='test -z "$ac_c_werror_flag"
29270                          || test ! -s conftest.err'
29271   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29272   (eval $ac_try) 2>&5
29273   ac_status=$?
29274   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29275   (exit $ac_status); }; } &&
29276          { ac_try='test -s conftest$ac_exeext'
29277   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29278   (eval $ac_try) 2>&5
29279   ac_status=$?
29280   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29281   (exit $ac_status); }; }; then
29282   ol_cv_db_db43=yes
29283 else
29284   echo "$as_me: failed program was:" >&5
29285 sed 's/^/| /' conftest.$ac_ext >&5
29286
29287 ol_cv_db_db43=no
29288 fi
29289 rm -f conftest.err conftest.$ac_objext \
29290       conftest$ac_exeext conftest.$ac_ext
29291
29292         LIBS="$ol_LIBS"
29293
29294 fi
29295 echo "$as_me:$LINENO: result: $ol_cv_db_db43" >&5
29296 echo "${ECHO_T}$ol_cv_db_db43" >&6
29297
29298         if test $ol_cv_db_db43 = yes ; then
29299                 ol_cv_lib_db=-ldb43
29300         fi
29301 fi
29302
29303                 if test $ol_cv_lib_db = no ; then
29304         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-43)" >&5
29305 echo $ECHO_N "checking for Berkeley DB link (-ldb-43)... $ECHO_C" >&6
29306 if test "${ol_cv_db_db_43+set}" = set; then
29307   echo $ECHO_N "(cached) $ECHO_C" >&6
29308 else
29309
29310         ol_DB_LIB=-ldb-43
29311         ol_LIBS=$LIBS
29312         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29313
29314         cat >conftest.$ac_ext <<_ACEOF
29315 /* confdefs.h.  */
29316 _ACEOF
29317 cat confdefs.h >>conftest.$ac_ext
29318 cat >>conftest.$ac_ext <<_ACEOF
29319 /* end confdefs.h.  */
29320
29321 #ifdef HAVE_DB_185_H
29322 # include <db_185.h>
29323 #else
29324 # include <db.h>
29325 #endif
29326
29327 #ifndef DB_VERSION_MAJOR
29328 # define DB_VERSION_MAJOR 1
29329 #endif
29330
29331 #ifndef NULL
29332 #define NULL ((void*)0)
29333 #endif
29334
29335 int
29336 main ()
29337 {
29338
29339 #if DB_VERSION_MAJOR > 1
29340         {
29341                 char *version;
29342                 int major, minor, patch;
29343
29344                 version = db_version( &major, &minor, &patch );
29345
29346                 if( major != DB_VERSION_MAJOR ||
29347                         minor < DB_VERSION_MINOR )
29348                 {
29349                         printf("Berkeley DB version mismatch\n"
29350                                 "\theader: %s\n\tlibrary: %s\n",
29351                                 DB_VERSION_STRING, version);
29352                         return 1;
29353                 }
29354         }
29355 #endif
29356
29357 #if DB_VERSION_MAJOR > 2
29358         db_env_create( NULL, 0 );
29359 #elif DB_VERSION_MAJOR > 1
29360         db_appexit( NULL );
29361 #else
29362         (void) dbopen( NULL, 0, 0, 0, NULL);
29363 #endif
29364
29365   ;
29366   return 0;
29367 }
29368 _ACEOF
29369 rm -f conftest.$ac_objext conftest$ac_exeext
29370 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29371   (eval $ac_link) 2>conftest.er1
29372   ac_status=$?
29373   grep -v '^ *+' conftest.er1 >conftest.err
29374   rm -f conftest.er1
29375   cat conftest.err >&5
29376   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29377   (exit $ac_status); } &&
29378          { ac_try='test -z "$ac_c_werror_flag"
29379                          || test ! -s conftest.err'
29380   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29381   (eval $ac_try) 2>&5
29382   ac_status=$?
29383   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29384   (exit $ac_status); }; } &&
29385          { ac_try='test -s conftest$ac_exeext'
29386   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29387   (eval $ac_try) 2>&5
29388   ac_status=$?
29389   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29390   (exit $ac_status); }; }; then
29391   ol_cv_db_db_43=yes
29392 else
29393   echo "$as_me: failed program was:" >&5
29394 sed 's/^/| /' conftest.$ac_ext >&5
29395
29396 ol_cv_db_db_43=no
29397 fi
29398 rm -f conftest.err conftest.$ac_objext \
29399       conftest$ac_exeext conftest.$ac_ext
29400
29401         LIBS="$ol_LIBS"
29402
29403 fi
29404 echo "$as_me:$LINENO: result: $ol_cv_db_db_43" >&5
29405 echo "${ECHO_T}$ol_cv_db_db_43" >&6
29406
29407         if test $ol_cv_db_db_43 = yes ; then
29408                 ol_cv_lib_db=-ldb-43
29409         fi
29410 fi
29411
29412                 if test $ol_cv_lib_db = no ; then
29413         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-3)" >&5
29414 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-3)... $ECHO_C" >&6
29415 if test "${ol_cv_db_db_4_3+set}" = set; then
29416   echo $ECHO_N "(cached) $ECHO_C" >&6
29417 else
29418
29419         ol_DB_LIB=-ldb-4-3
29420         ol_LIBS=$LIBS
29421         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29422
29423         cat >conftest.$ac_ext <<_ACEOF
29424 /* confdefs.h.  */
29425 _ACEOF
29426 cat confdefs.h >>conftest.$ac_ext
29427 cat >>conftest.$ac_ext <<_ACEOF
29428 /* end confdefs.h.  */
29429
29430 #ifdef HAVE_DB_185_H
29431 # include <db_185.h>
29432 #else
29433 # include <db.h>
29434 #endif
29435
29436 #ifndef DB_VERSION_MAJOR
29437 # define DB_VERSION_MAJOR 1
29438 #endif
29439
29440 #ifndef NULL
29441 #define NULL ((void*)0)
29442 #endif
29443
29444 int
29445 main ()
29446 {
29447
29448 #if DB_VERSION_MAJOR > 1
29449         {
29450                 char *version;
29451                 int major, minor, patch;
29452
29453                 version = db_version( &major, &minor, &patch );
29454
29455                 if( major != DB_VERSION_MAJOR ||
29456                         minor < DB_VERSION_MINOR )
29457                 {
29458                         printf("Berkeley DB version mismatch\n"
29459                                 "\theader: %s\n\tlibrary: %s\n",
29460                                 DB_VERSION_STRING, version);
29461                         return 1;
29462                 }
29463         }
29464 #endif
29465
29466 #if DB_VERSION_MAJOR > 2
29467         db_env_create( NULL, 0 );
29468 #elif DB_VERSION_MAJOR > 1
29469         db_appexit( NULL );
29470 #else
29471         (void) dbopen( NULL, 0, 0, 0, NULL);
29472 #endif
29473
29474   ;
29475   return 0;
29476 }
29477 _ACEOF
29478 rm -f conftest.$ac_objext conftest$ac_exeext
29479 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29480   (eval $ac_link) 2>conftest.er1
29481   ac_status=$?
29482   grep -v '^ *+' conftest.er1 >conftest.err
29483   rm -f conftest.er1
29484   cat conftest.err >&5
29485   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29486   (exit $ac_status); } &&
29487          { ac_try='test -z "$ac_c_werror_flag"
29488                          || test ! -s conftest.err'
29489   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29490   (eval $ac_try) 2>&5
29491   ac_status=$?
29492   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29493   (exit $ac_status); }; } &&
29494          { ac_try='test -s conftest$ac_exeext'
29495   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29496   (eval $ac_try) 2>&5
29497   ac_status=$?
29498   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29499   (exit $ac_status); }; }; then
29500   ol_cv_db_db_4_3=yes
29501 else
29502   echo "$as_me: failed program was:" >&5
29503 sed 's/^/| /' conftest.$ac_ext >&5
29504
29505 ol_cv_db_db_4_3=no
29506 fi
29507 rm -f conftest.err conftest.$ac_objext \
29508       conftest$ac_exeext conftest.$ac_ext
29509
29510         LIBS="$ol_LIBS"
29511
29512 fi
29513 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_3" >&5
29514 echo "${ECHO_T}$ol_cv_db_db_4_3" >&6
29515
29516         if test $ol_cv_db_db_4_3 = yes ; then
29517                 ol_cv_lib_db=-ldb-4-3
29518         fi
29519 fi
29520
29521         elif test $ol_cv_bdb_minor = 2 ; then
29522                 if test $ol_cv_lib_db = no ; then
29523         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.2)" >&5
29524 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.2)... $ECHO_C" >&6
29525 if test "${ol_cv_db_db_4_dot_2+set}" = set; then
29526   echo $ECHO_N "(cached) $ECHO_C" >&6
29527 else
29528
29529         ol_DB_LIB=-ldb-4.2
29530         ol_LIBS=$LIBS
29531         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29532
29533         cat >conftest.$ac_ext <<_ACEOF
29534 /* confdefs.h.  */
29535 _ACEOF
29536 cat confdefs.h >>conftest.$ac_ext
29537 cat >>conftest.$ac_ext <<_ACEOF
29538 /* end confdefs.h.  */
29539
29540 #ifdef HAVE_DB_185_H
29541 # include <db_185.h>
29542 #else
29543 # include <db.h>
29544 #endif
29545
29546 #ifndef DB_VERSION_MAJOR
29547 # define DB_VERSION_MAJOR 1
29548 #endif
29549
29550 #ifndef NULL
29551 #define NULL ((void*)0)
29552 #endif
29553
29554 int
29555 main ()
29556 {
29557
29558 #if DB_VERSION_MAJOR > 1
29559         {
29560                 char *version;
29561                 int major, minor, patch;
29562
29563                 version = db_version( &major, &minor, &patch );
29564
29565                 if( major != DB_VERSION_MAJOR ||
29566                         minor < DB_VERSION_MINOR )
29567                 {
29568                         printf("Berkeley DB version mismatch\n"
29569                                 "\theader: %s\n\tlibrary: %s\n",
29570                                 DB_VERSION_STRING, version);
29571                         return 1;
29572                 }
29573         }
29574 #endif
29575
29576 #if DB_VERSION_MAJOR > 2
29577         db_env_create( NULL, 0 );
29578 #elif DB_VERSION_MAJOR > 1
29579         db_appexit( NULL );
29580 #else
29581         (void) dbopen( NULL, 0, 0, 0, NULL);
29582 #endif
29583
29584   ;
29585   return 0;
29586 }
29587 _ACEOF
29588 rm -f conftest.$ac_objext conftest$ac_exeext
29589 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29590   (eval $ac_link) 2>conftest.er1
29591   ac_status=$?
29592   grep -v '^ *+' conftest.er1 >conftest.err
29593   rm -f conftest.er1
29594   cat conftest.err >&5
29595   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29596   (exit $ac_status); } &&
29597          { ac_try='test -z "$ac_c_werror_flag"
29598                          || test ! -s conftest.err'
29599   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29600   (eval $ac_try) 2>&5
29601   ac_status=$?
29602   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29603   (exit $ac_status); }; } &&
29604          { ac_try='test -s conftest$ac_exeext'
29605   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29606   (eval $ac_try) 2>&5
29607   ac_status=$?
29608   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29609   (exit $ac_status); }; }; then
29610   ol_cv_db_db_4_dot_2=yes
29611 else
29612   echo "$as_me: failed program was:" >&5
29613 sed 's/^/| /' conftest.$ac_ext >&5
29614
29615 ol_cv_db_db_4_dot_2=no
29616 fi
29617 rm -f conftest.err conftest.$ac_objext \
29618       conftest$ac_exeext conftest.$ac_ext
29619
29620         LIBS="$ol_LIBS"
29621
29622 fi
29623 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_2" >&5
29624 echo "${ECHO_T}$ol_cv_db_db_4_dot_2" >&6
29625
29626         if test $ol_cv_db_db_4_dot_2 = yes ; then
29627                 ol_cv_lib_db=-ldb-4.2
29628         fi
29629 fi
29630
29631                 if test $ol_cv_lib_db = no ; then
29632         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb42)" >&5
29633 echo $ECHO_N "checking for Berkeley DB link (-ldb42)... $ECHO_C" >&6
29634 if test "${ol_cv_db_db42+set}" = set; then
29635   echo $ECHO_N "(cached) $ECHO_C" >&6
29636 else
29637
29638         ol_DB_LIB=-ldb42
29639         ol_LIBS=$LIBS
29640         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29641
29642         cat >conftest.$ac_ext <<_ACEOF
29643 /* confdefs.h.  */
29644 _ACEOF
29645 cat confdefs.h >>conftest.$ac_ext
29646 cat >>conftest.$ac_ext <<_ACEOF
29647 /* end confdefs.h.  */
29648
29649 #ifdef HAVE_DB_185_H
29650 # include <db_185.h>
29651 #else
29652 # include <db.h>
29653 #endif
29654
29655 #ifndef DB_VERSION_MAJOR
29656 # define DB_VERSION_MAJOR 1
29657 #endif
29658
29659 #ifndef NULL
29660 #define NULL ((void*)0)
29661 #endif
29662
29663 int
29664 main ()
29665 {
29666
29667 #if DB_VERSION_MAJOR > 1
29668         {
29669                 char *version;
29670                 int major, minor, patch;
29671
29672                 version = db_version( &major, &minor, &patch );
29673
29674                 if( major != DB_VERSION_MAJOR ||
29675                         minor < DB_VERSION_MINOR )
29676                 {
29677                         printf("Berkeley DB version mismatch\n"
29678                                 "\theader: %s\n\tlibrary: %s\n",
29679                                 DB_VERSION_STRING, version);
29680                         return 1;
29681                 }
29682         }
29683 #endif
29684
29685 #if DB_VERSION_MAJOR > 2
29686         db_env_create( NULL, 0 );
29687 #elif DB_VERSION_MAJOR > 1
29688         db_appexit( NULL );
29689 #else
29690         (void) dbopen( NULL, 0, 0, 0, NULL);
29691 #endif
29692
29693   ;
29694   return 0;
29695 }
29696 _ACEOF
29697 rm -f conftest.$ac_objext conftest$ac_exeext
29698 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29699   (eval $ac_link) 2>conftest.er1
29700   ac_status=$?
29701   grep -v '^ *+' conftest.er1 >conftest.err
29702   rm -f conftest.er1
29703   cat conftest.err >&5
29704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29705   (exit $ac_status); } &&
29706          { ac_try='test -z "$ac_c_werror_flag"
29707                          || test ! -s conftest.err'
29708   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29709   (eval $ac_try) 2>&5
29710   ac_status=$?
29711   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29712   (exit $ac_status); }; } &&
29713          { ac_try='test -s conftest$ac_exeext'
29714   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29715   (eval $ac_try) 2>&5
29716   ac_status=$?
29717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29718   (exit $ac_status); }; }; then
29719   ol_cv_db_db42=yes
29720 else
29721   echo "$as_me: failed program was:" >&5
29722 sed 's/^/| /' conftest.$ac_ext >&5
29723
29724 ol_cv_db_db42=no
29725 fi
29726 rm -f conftest.err conftest.$ac_objext \
29727       conftest$ac_exeext conftest.$ac_ext
29728
29729         LIBS="$ol_LIBS"
29730
29731 fi
29732 echo "$as_me:$LINENO: result: $ol_cv_db_db42" >&5
29733 echo "${ECHO_T}$ol_cv_db_db42" >&6
29734
29735         if test $ol_cv_db_db42 = yes ; then
29736                 ol_cv_lib_db=-ldb42
29737         fi
29738 fi
29739
29740                 if test $ol_cv_lib_db = no ; then
29741         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-42)" >&5
29742 echo $ECHO_N "checking for Berkeley DB link (-ldb-42)... $ECHO_C" >&6
29743 if test "${ol_cv_db_db_42+set}" = set; then
29744   echo $ECHO_N "(cached) $ECHO_C" >&6
29745 else
29746
29747         ol_DB_LIB=-ldb-42
29748         ol_LIBS=$LIBS
29749         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29750
29751         cat >conftest.$ac_ext <<_ACEOF
29752 /* confdefs.h.  */
29753 _ACEOF
29754 cat confdefs.h >>conftest.$ac_ext
29755 cat >>conftest.$ac_ext <<_ACEOF
29756 /* end confdefs.h.  */
29757
29758 #ifdef HAVE_DB_185_H
29759 # include <db_185.h>
29760 #else
29761 # include <db.h>
29762 #endif
29763
29764 #ifndef DB_VERSION_MAJOR
29765 # define DB_VERSION_MAJOR 1
29766 #endif
29767
29768 #ifndef NULL
29769 #define NULL ((void*)0)
29770 #endif
29771
29772 int
29773 main ()
29774 {
29775
29776 #if DB_VERSION_MAJOR > 1
29777         {
29778                 char *version;
29779                 int major, minor, patch;
29780
29781                 version = db_version( &major, &minor, &patch );
29782
29783                 if( major != DB_VERSION_MAJOR ||
29784                         minor < DB_VERSION_MINOR )
29785                 {
29786                         printf("Berkeley DB version mismatch\n"
29787                                 "\theader: %s\n\tlibrary: %s\n",
29788                                 DB_VERSION_STRING, version);
29789                         return 1;
29790                 }
29791         }
29792 #endif
29793
29794 #if DB_VERSION_MAJOR > 2
29795         db_env_create( NULL, 0 );
29796 #elif DB_VERSION_MAJOR > 1
29797         db_appexit( NULL );
29798 #else
29799         (void) dbopen( NULL, 0, 0, 0, NULL);
29800 #endif
29801
29802   ;
29803   return 0;
29804 }
29805 _ACEOF
29806 rm -f conftest.$ac_objext conftest$ac_exeext
29807 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29808   (eval $ac_link) 2>conftest.er1
29809   ac_status=$?
29810   grep -v '^ *+' conftest.er1 >conftest.err
29811   rm -f conftest.er1
29812   cat conftest.err >&5
29813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29814   (exit $ac_status); } &&
29815          { ac_try='test -z "$ac_c_werror_flag"
29816                          || test ! -s conftest.err'
29817   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29818   (eval $ac_try) 2>&5
29819   ac_status=$?
29820   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29821   (exit $ac_status); }; } &&
29822          { ac_try='test -s conftest$ac_exeext'
29823   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29824   (eval $ac_try) 2>&5
29825   ac_status=$?
29826   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29827   (exit $ac_status); }; }; then
29828   ol_cv_db_db_42=yes
29829 else
29830   echo "$as_me: failed program was:" >&5
29831 sed 's/^/| /' conftest.$ac_ext >&5
29832
29833 ol_cv_db_db_42=no
29834 fi
29835 rm -f conftest.err conftest.$ac_objext \
29836       conftest$ac_exeext conftest.$ac_ext
29837
29838         LIBS="$ol_LIBS"
29839
29840 fi
29841 echo "$as_me:$LINENO: result: $ol_cv_db_db_42" >&5
29842 echo "${ECHO_T}$ol_cv_db_db_42" >&6
29843
29844         if test $ol_cv_db_db_42 = yes ; then
29845                 ol_cv_lib_db=-ldb-42
29846         fi
29847 fi
29848
29849                 if test $ol_cv_lib_db = no ; then
29850         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-2)" >&5
29851 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-2)... $ECHO_C" >&6
29852 if test "${ol_cv_db_db_4_2+set}" = set; then
29853   echo $ECHO_N "(cached) $ECHO_C" >&6
29854 else
29855
29856         ol_DB_LIB=-ldb-4-2
29857         ol_LIBS=$LIBS
29858         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29859
29860         cat >conftest.$ac_ext <<_ACEOF
29861 /* confdefs.h.  */
29862 _ACEOF
29863 cat confdefs.h >>conftest.$ac_ext
29864 cat >>conftest.$ac_ext <<_ACEOF
29865 /* end confdefs.h.  */
29866
29867 #ifdef HAVE_DB_185_H
29868 # include <db_185.h>
29869 #else
29870 # include <db.h>
29871 #endif
29872
29873 #ifndef DB_VERSION_MAJOR
29874 # define DB_VERSION_MAJOR 1
29875 #endif
29876
29877 #ifndef NULL
29878 #define NULL ((void*)0)
29879 #endif
29880
29881 int
29882 main ()
29883 {
29884
29885 #if DB_VERSION_MAJOR > 1
29886         {
29887                 char *version;
29888                 int major, minor, patch;
29889
29890                 version = db_version( &major, &minor, &patch );
29891
29892                 if( major != DB_VERSION_MAJOR ||
29893                         minor < DB_VERSION_MINOR )
29894                 {
29895                         printf("Berkeley DB version mismatch\n"
29896                                 "\theader: %s\n\tlibrary: %s\n",
29897                                 DB_VERSION_STRING, version);
29898                         return 1;
29899                 }
29900         }
29901 #endif
29902
29903 #if DB_VERSION_MAJOR > 2
29904         db_env_create( NULL, 0 );
29905 #elif DB_VERSION_MAJOR > 1
29906         db_appexit( NULL );
29907 #else
29908         (void) dbopen( NULL, 0, 0, 0, NULL);
29909 #endif
29910
29911   ;
29912   return 0;
29913 }
29914 _ACEOF
29915 rm -f conftest.$ac_objext conftest$ac_exeext
29916 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29917   (eval $ac_link) 2>conftest.er1
29918   ac_status=$?
29919   grep -v '^ *+' conftest.er1 >conftest.err
29920   rm -f conftest.er1
29921   cat conftest.err >&5
29922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29923   (exit $ac_status); } &&
29924          { ac_try='test -z "$ac_c_werror_flag"
29925                          || test ! -s conftest.err'
29926   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29927   (eval $ac_try) 2>&5
29928   ac_status=$?
29929   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29930   (exit $ac_status); }; } &&
29931          { ac_try='test -s conftest$ac_exeext'
29932   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29933   (eval $ac_try) 2>&5
29934   ac_status=$?
29935   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29936   (exit $ac_status); }; }; then
29937   ol_cv_db_db_4_2=yes
29938 else
29939   echo "$as_me: failed program was:" >&5
29940 sed 's/^/| /' conftest.$ac_ext >&5
29941
29942 ol_cv_db_db_4_2=no
29943 fi
29944 rm -f conftest.err conftest.$ac_objext \
29945       conftest$ac_exeext conftest.$ac_ext
29946
29947         LIBS="$ol_LIBS"
29948
29949 fi
29950 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_2" >&5
29951 echo "${ECHO_T}$ol_cv_db_db_4_2" >&6
29952
29953         if test $ol_cv_db_db_4_2 = yes ; then
29954                 ol_cv_lib_db=-ldb-4-2
29955         fi
29956 fi
29957
29958         fi
29959         if test $ol_cv_lib_db = no ; then
29960         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4)" >&5
29961 echo $ECHO_N "checking for Berkeley DB link (-ldb-4)... $ECHO_C" >&6
29962 if test "${ol_cv_db_db_4+set}" = set; then
29963   echo $ECHO_N "(cached) $ECHO_C" >&6
29964 else
29965
29966         ol_DB_LIB=-ldb-4
29967         ol_LIBS=$LIBS
29968         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29969
29970         cat >conftest.$ac_ext <<_ACEOF
29971 /* confdefs.h.  */
29972 _ACEOF
29973 cat confdefs.h >>conftest.$ac_ext
29974 cat >>conftest.$ac_ext <<_ACEOF
29975 /* end confdefs.h.  */
29976
29977 #ifdef HAVE_DB_185_H
29978 # include <db_185.h>
29979 #else
29980 # include <db.h>
29981 #endif
29982
29983 #ifndef DB_VERSION_MAJOR
29984 # define DB_VERSION_MAJOR 1
29985 #endif
29986
29987 #ifndef NULL
29988 #define NULL ((void*)0)
29989 #endif
29990
29991 int
29992 main ()
29993 {
29994
29995 #if DB_VERSION_MAJOR > 1
29996         {
29997                 char *version;
29998                 int major, minor, patch;
29999
30000                 version = db_version( &major, &minor, &patch );
30001
30002                 if( major != DB_VERSION_MAJOR ||
30003                         minor < DB_VERSION_MINOR )
30004                 {
30005                         printf("Berkeley DB version mismatch\n"
30006                                 "\theader: %s\n\tlibrary: %s\n",
30007                                 DB_VERSION_STRING, version);
30008                         return 1;
30009                 }
30010         }
30011 #endif
30012
30013 #if DB_VERSION_MAJOR > 2
30014         db_env_create( NULL, 0 );
30015 #elif DB_VERSION_MAJOR > 1
30016         db_appexit( NULL );
30017 #else
30018         (void) dbopen( NULL, 0, 0, 0, NULL);
30019 #endif
30020
30021   ;
30022   return 0;
30023 }
30024 _ACEOF
30025 rm -f conftest.$ac_objext conftest$ac_exeext
30026 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30027   (eval $ac_link) 2>conftest.er1
30028   ac_status=$?
30029   grep -v '^ *+' conftest.er1 >conftest.err
30030   rm -f conftest.er1
30031   cat conftest.err >&5
30032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30033   (exit $ac_status); } &&
30034          { ac_try='test -z "$ac_c_werror_flag"
30035                          || test ! -s conftest.err'
30036   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30037   (eval $ac_try) 2>&5
30038   ac_status=$?
30039   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30040   (exit $ac_status); }; } &&
30041          { ac_try='test -s conftest$ac_exeext'
30042   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30043   (eval $ac_try) 2>&5
30044   ac_status=$?
30045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30046   (exit $ac_status); }; }; then
30047   ol_cv_db_db_4=yes
30048 else
30049   echo "$as_me: failed program was:" >&5
30050 sed 's/^/| /' conftest.$ac_ext >&5
30051
30052 ol_cv_db_db_4=no
30053 fi
30054 rm -f conftest.err conftest.$ac_objext \
30055       conftest$ac_exeext conftest.$ac_ext
30056
30057         LIBS="$ol_LIBS"
30058
30059 fi
30060 echo "$as_me:$LINENO: result: $ol_cv_db_db_4" >&5
30061 echo "${ECHO_T}$ol_cv_db_db_4" >&6
30062
30063         if test $ol_cv_db_db_4 = yes ; then
30064                 ol_cv_lib_db=-ldb-4
30065         fi
30066 fi
30067
30068         if test $ol_cv_lib_db = no ; then
30069         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb4)" >&5
30070 echo $ECHO_N "checking for Berkeley DB link (-ldb4)... $ECHO_C" >&6
30071 if test "${ol_cv_db_db4+set}" = set; then
30072   echo $ECHO_N "(cached) $ECHO_C" >&6
30073 else
30074
30075         ol_DB_LIB=-ldb4
30076         ol_LIBS=$LIBS
30077         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30078
30079         cat >conftest.$ac_ext <<_ACEOF
30080 /* confdefs.h.  */
30081 _ACEOF
30082 cat confdefs.h >>conftest.$ac_ext
30083 cat >>conftest.$ac_ext <<_ACEOF
30084 /* end confdefs.h.  */
30085
30086 #ifdef HAVE_DB_185_H
30087 # include <db_185.h>
30088 #else
30089 # include <db.h>
30090 #endif
30091
30092 #ifndef DB_VERSION_MAJOR
30093 # define DB_VERSION_MAJOR 1
30094 #endif
30095
30096 #ifndef NULL
30097 #define NULL ((void*)0)
30098 #endif
30099
30100 int
30101 main ()
30102 {
30103
30104 #if DB_VERSION_MAJOR > 1
30105         {
30106                 char *version;
30107                 int major, minor, patch;
30108
30109                 version = db_version( &major, &minor, &patch );
30110
30111                 if( major != DB_VERSION_MAJOR ||
30112                         minor < DB_VERSION_MINOR )
30113                 {
30114                         printf("Berkeley DB version mismatch\n"
30115                                 "\theader: %s\n\tlibrary: %s\n",
30116                                 DB_VERSION_STRING, version);
30117                         return 1;
30118                 }
30119         }
30120 #endif
30121
30122 #if DB_VERSION_MAJOR > 2
30123         db_env_create( NULL, 0 );
30124 #elif DB_VERSION_MAJOR > 1
30125         db_appexit( NULL );
30126 #else
30127         (void) dbopen( NULL, 0, 0, 0, NULL);
30128 #endif
30129
30130   ;
30131   return 0;
30132 }
30133 _ACEOF
30134 rm -f conftest.$ac_objext conftest$ac_exeext
30135 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30136   (eval $ac_link) 2>conftest.er1
30137   ac_status=$?
30138   grep -v '^ *+' conftest.er1 >conftest.err
30139   rm -f conftest.er1
30140   cat conftest.err >&5
30141   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30142   (exit $ac_status); } &&
30143          { ac_try='test -z "$ac_c_werror_flag"
30144                          || test ! -s conftest.err'
30145   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30146   (eval $ac_try) 2>&5
30147   ac_status=$?
30148   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30149   (exit $ac_status); }; } &&
30150          { ac_try='test -s conftest$ac_exeext'
30151   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30152   (eval $ac_try) 2>&5
30153   ac_status=$?
30154   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30155   (exit $ac_status); }; }; then
30156   ol_cv_db_db4=yes
30157 else
30158   echo "$as_me: failed program was:" >&5
30159 sed 's/^/| /' conftest.$ac_ext >&5
30160
30161 ol_cv_db_db4=no
30162 fi
30163 rm -f conftest.err conftest.$ac_objext \
30164       conftest$ac_exeext conftest.$ac_ext
30165
30166         LIBS="$ol_LIBS"
30167
30168 fi
30169 echo "$as_me:$LINENO: result: $ol_cv_db_db4" >&5
30170 echo "${ECHO_T}$ol_cv_db_db4" >&6
30171
30172         if test $ol_cv_db_db4 = yes ; then
30173                 ol_cv_lib_db=-ldb4
30174         fi
30175 fi
30176
30177         if test $ol_cv_lib_db = no ; then
30178         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb)" >&5
30179 echo $ECHO_N "checking for Berkeley DB link (-ldb)... $ECHO_C" >&6
30180 if test "${ol_cv_db_db+set}" = set; then
30181   echo $ECHO_N "(cached) $ECHO_C" >&6
30182 else
30183
30184         ol_DB_LIB=-ldb
30185         ol_LIBS=$LIBS
30186         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30187
30188         cat >conftest.$ac_ext <<_ACEOF
30189 /* confdefs.h.  */
30190 _ACEOF
30191 cat confdefs.h >>conftest.$ac_ext
30192 cat >>conftest.$ac_ext <<_ACEOF
30193 /* end confdefs.h.  */
30194
30195 #ifdef HAVE_DB_185_H
30196 # include <db_185.h>
30197 #else
30198 # include <db.h>
30199 #endif
30200
30201 #ifndef DB_VERSION_MAJOR
30202 # define DB_VERSION_MAJOR 1
30203 #endif
30204
30205 #ifndef NULL
30206 #define NULL ((void*)0)
30207 #endif
30208
30209 int
30210 main ()
30211 {
30212
30213 #if DB_VERSION_MAJOR > 1
30214         {
30215                 char *version;
30216                 int major, minor, patch;
30217
30218                 version = db_version( &major, &minor, &patch );
30219
30220                 if( major != DB_VERSION_MAJOR ||
30221                         minor < DB_VERSION_MINOR )
30222                 {
30223                         printf("Berkeley DB version mismatch\n"
30224                                 "\theader: %s\n\tlibrary: %s\n",
30225                                 DB_VERSION_STRING, version);
30226                         return 1;
30227                 }
30228         }
30229 #endif
30230
30231 #if DB_VERSION_MAJOR > 2
30232         db_env_create( NULL, 0 );
30233 #elif DB_VERSION_MAJOR > 1
30234         db_appexit( NULL );
30235 #else
30236         (void) dbopen( NULL, 0, 0, 0, NULL);
30237 #endif
30238
30239   ;
30240   return 0;
30241 }
30242 _ACEOF
30243 rm -f conftest.$ac_objext conftest$ac_exeext
30244 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30245   (eval $ac_link) 2>conftest.er1
30246   ac_status=$?
30247   grep -v '^ *+' conftest.er1 >conftest.err
30248   rm -f conftest.er1
30249   cat conftest.err >&5
30250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30251   (exit $ac_status); } &&
30252          { ac_try='test -z "$ac_c_werror_flag"
30253                          || test ! -s conftest.err'
30254   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30255   (eval $ac_try) 2>&5
30256   ac_status=$?
30257   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30258   (exit $ac_status); }; } &&
30259          { ac_try='test -s conftest$ac_exeext'
30260   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30261   (eval $ac_try) 2>&5
30262   ac_status=$?
30263   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30264   (exit $ac_status); }; }; then
30265   ol_cv_db_db=yes
30266 else
30267   echo "$as_me: failed program was:" >&5
30268 sed 's/^/| /' conftest.$ac_ext >&5
30269
30270 ol_cv_db_db=no
30271 fi
30272 rm -f conftest.err conftest.$ac_objext \
30273       conftest$ac_exeext conftest.$ac_ext
30274
30275         LIBS="$ol_LIBS"
30276
30277 fi
30278 echo "$as_me:$LINENO: result: $ol_cv_db_db" >&5
30279 echo "${ECHO_T}$ol_cv_db_db" >&6
30280
30281         if test $ol_cv_db_db = yes ; then
30282                 ol_cv_lib_db=-ldb
30283         fi
30284 fi
30285
30286
30287 elif test $ol_cv_bdb_major = 3 ; then
30288         if test $ol_cv_lib_db = no ; then
30289         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb3)" >&5
30290 echo $ECHO_N "checking for Berkeley DB link (-ldb3)... $ECHO_C" >&6
30291 if test "${ol_cv_db_db3+set}" = set; then
30292   echo $ECHO_N "(cached) $ECHO_C" >&6
30293 else
30294
30295         ol_DB_LIB=-ldb3
30296         ol_LIBS=$LIBS
30297         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30298
30299         cat >conftest.$ac_ext <<_ACEOF
30300 /* confdefs.h.  */
30301 _ACEOF
30302 cat confdefs.h >>conftest.$ac_ext
30303 cat >>conftest.$ac_ext <<_ACEOF
30304 /* end confdefs.h.  */
30305
30306 #ifdef HAVE_DB_185_H
30307 # include <db_185.h>
30308 #else
30309 # include <db.h>
30310 #endif
30311
30312 #ifndef DB_VERSION_MAJOR
30313 # define DB_VERSION_MAJOR 1
30314 #endif
30315
30316 #ifndef NULL
30317 #define NULL ((void*)0)
30318 #endif
30319
30320 int
30321 main ()
30322 {
30323
30324 #if DB_VERSION_MAJOR > 1
30325         {
30326                 char *version;
30327                 int major, minor, patch;
30328
30329                 version = db_version( &major, &minor, &patch );
30330
30331                 if( major != DB_VERSION_MAJOR ||
30332                         minor < DB_VERSION_MINOR )
30333                 {
30334                         printf("Berkeley DB version mismatch\n"
30335                                 "\theader: %s\n\tlibrary: %s\n",
30336                                 DB_VERSION_STRING, version);
30337                         return 1;
30338                 }
30339         }
30340 #endif
30341
30342 #if DB_VERSION_MAJOR > 2
30343         db_env_create( NULL, 0 );
30344 #elif DB_VERSION_MAJOR > 1
30345         db_appexit( NULL );
30346 #else
30347         (void) dbopen( NULL, 0, 0, 0, NULL);
30348 #endif
30349
30350   ;
30351   return 0;
30352 }
30353 _ACEOF
30354 rm -f conftest.$ac_objext conftest$ac_exeext
30355 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30356   (eval $ac_link) 2>conftest.er1
30357   ac_status=$?
30358   grep -v '^ *+' conftest.er1 >conftest.err
30359   rm -f conftest.er1
30360   cat conftest.err >&5
30361   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30362   (exit $ac_status); } &&
30363          { ac_try='test -z "$ac_c_werror_flag"
30364                          || test ! -s conftest.err'
30365   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30366   (eval $ac_try) 2>&5
30367   ac_status=$?
30368   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30369   (exit $ac_status); }; } &&
30370          { ac_try='test -s conftest$ac_exeext'
30371   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30372   (eval $ac_try) 2>&5
30373   ac_status=$?
30374   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30375   (exit $ac_status); }; }; then
30376   ol_cv_db_db3=yes
30377 else
30378   echo "$as_me: failed program was:" >&5
30379 sed 's/^/| /' conftest.$ac_ext >&5
30380
30381 ol_cv_db_db3=no
30382 fi
30383 rm -f conftest.err conftest.$ac_objext \
30384       conftest$ac_exeext conftest.$ac_ext
30385
30386         LIBS="$ol_LIBS"
30387
30388 fi
30389 echo "$as_me:$LINENO: result: $ol_cv_db_db3" >&5
30390 echo "${ECHO_T}$ol_cv_db_db3" >&6
30391
30392         if test $ol_cv_db_db3 = yes ; then
30393                 ol_cv_lib_db=-ldb3
30394         fi
30395 fi
30396
30397         if test $ol_cv_lib_db = no ; then
30398         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-3)" >&5
30399 echo $ECHO_N "checking for Berkeley DB link (-ldb-3)... $ECHO_C" >&6
30400 if test "${ol_cv_db_db_3+set}" = set; then
30401   echo $ECHO_N "(cached) $ECHO_C" >&6
30402 else
30403
30404         ol_DB_LIB=-ldb-3
30405         ol_LIBS=$LIBS
30406         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30407
30408         cat >conftest.$ac_ext <<_ACEOF
30409 /* confdefs.h.  */
30410 _ACEOF
30411 cat confdefs.h >>conftest.$ac_ext
30412 cat >>conftest.$ac_ext <<_ACEOF
30413 /* end confdefs.h.  */
30414
30415 #ifdef HAVE_DB_185_H
30416 # include <db_185.h>
30417 #else
30418 # include <db.h>
30419 #endif
30420
30421 #ifndef DB_VERSION_MAJOR
30422 # define DB_VERSION_MAJOR 1
30423 #endif
30424
30425 #ifndef NULL
30426 #define NULL ((void*)0)
30427 #endif
30428
30429 int
30430 main ()
30431 {
30432
30433 #if DB_VERSION_MAJOR > 1
30434         {
30435                 char *version;
30436                 int major, minor, patch;
30437
30438                 version = db_version( &major, &minor, &patch );
30439
30440                 if( major != DB_VERSION_MAJOR ||
30441                         minor < DB_VERSION_MINOR )
30442                 {
30443                         printf("Berkeley DB version mismatch\n"
30444                                 "\theader: %s\n\tlibrary: %s\n",
30445                                 DB_VERSION_STRING, version);
30446                         return 1;
30447                 }
30448         }
30449 #endif
30450
30451 #if DB_VERSION_MAJOR > 2
30452         db_env_create( NULL, 0 );
30453 #elif DB_VERSION_MAJOR > 1
30454         db_appexit( NULL );
30455 #else
30456         (void) dbopen( NULL, 0, 0, 0, NULL);
30457 #endif
30458
30459   ;
30460   return 0;
30461 }
30462 _ACEOF
30463 rm -f conftest.$ac_objext conftest$ac_exeext
30464 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30465   (eval $ac_link) 2>conftest.er1
30466   ac_status=$?
30467   grep -v '^ *+' conftest.er1 >conftest.err
30468   rm -f conftest.er1
30469   cat conftest.err >&5
30470   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30471   (exit $ac_status); } &&
30472          { ac_try='test -z "$ac_c_werror_flag"
30473                          || test ! -s conftest.err'
30474   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30475   (eval $ac_try) 2>&5
30476   ac_status=$?
30477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30478   (exit $ac_status); }; } &&
30479          { ac_try='test -s conftest$ac_exeext'
30480   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30481   (eval $ac_try) 2>&5
30482   ac_status=$?
30483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30484   (exit $ac_status); }; }; then
30485   ol_cv_db_db_3=yes
30486 else
30487   echo "$as_me: failed program was:" >&5
30488 sed 's/^/| /' conftest.$ac_ext >&5
30489
30490 ol_cv_db_db_3=no
30491 fi
30492 rm -f conftest.err conftest.$ac_objext \
30493       conftest$ac_exeext conftest.$ac_ext
30494
30495         LIBS="$ol_LIBS"
30496
30497 fi
30498 echo "$as_me:$LINENO: result: $ol_cv_db_db_3" >&5
30499 echo "${ECHO_T}$ol_cv_db_db_3" >&6
30500
30501         if test $ol_cv_db_db_3 = yes ; then
30502                 ol_cv_lib_db=-ldb-3
30503         fi
30504 fi
30505
30506
30507 elif test $ol_cv_bdb_major = 2 ; then
30508         if test $ol_cv_lib_db = no ; then
30509         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb2)" >&5
30510 echo $ECHO_N "checking for Berkeley DB link (-ldb2)... $ECHO_C" >&6
30511 if test "${ol_cv_db_db2+set}" = set; then
30512   echo $ECHO_N "(cached) $ECHO_C" >&6
30513 else
30514
30515         ol_DB_LIB=-ldb2
30516         ol_LIBS=$LIBS
30517         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30518
30519         cat >conftest.$ac_ext <<_ACEOF
30520 /* confdefs.h.  */
30521 _ACEOF
30522 cat confdefs.h >>conftest.$ac_ext
30523 cat >>conftest.$ac_ext <<_ACEOF
30524 /* end confdefs.h.  */
30525
30526 #ifdef HAVE_DB_185_H
30527 # include <db_185.h>
30528 #else
30529 # include <db.h>
30530 #endif
30531
30532 #ifndef DB_VERSION_MAJOR
30533 # define DB_VERSION_MAJOR 1
30534 #endif
30535
30536 #ifndef NULL
30537 #define NULL ((void*)0)
30538 #endif
30539
30540 int
30541 main ()
30542 {
30543
30544 #if DB_VERSION_MAJOR > 1
30545         {
30546                 char *version;
30547                 int major, minor, patch;
30548
30549                 version = db_version( &major, &minor, &patch );
30550
30551                 if( major != DB_VERSION_MAJOR ||
30552                         minor < DB_VERSION_MINOR )
30553                 {
30554                         printf("Berkeley DB version mismatch\n"
30555                                 "\theader: %s\n\tlibrary: %s\n",
30556                                 DB_VERSION_STRING, version);
30557                         return 1;
30558                 }
30559         }
30560 #endif
30561
30562 #if DB_VERSION_MAJOR > 2
30563         db_env_create( NULL, 0 );
30564 #elif DB_VERSION_MAJOR > 1
30565         db_appexit( NULL );
30566 #else
30567         (void) dbopen( NULL, 0, 0, 0, NULL);
30568 #endif
30569
30570   ;
30571   return 0;
30572 }
30573 _ACEOF
30574 rm -f conftest.$ac_objext conftest$ac_exeext
30575 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30576   (eval $ac_link) 2>conftest.er1
30577   ac_status=$?
30578   grep -v '^ *+' conftest.er1 >conftest.err
30579   rm -f conftest.er1
30580   cat conftest.err >&5
30581   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30582   (exit $ac_status); } &&
30583          { ac_try='test -z "$ac_c_werror_flag"
30584                          || test ! -s conftest.err'
30585   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30586   (eval $ac_try) 2>&5
30587   ac_status=$?
30588   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30589   (exit $ac_status); }; } &&
30590          { ac_try='test -s conftest$ac_exeext'
30591   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30592   (eval $ac_try) 2>&5
30593   ac_status=$?
30594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30595   (exit $ac_status); }; }; then
30596   ol_cv_db_db2=yes
30597 else
30598   echo "$as_me: failed program was:" >&5
30599 sed 's/^/| /' conftest.$ac_ext >&5
30600
30601 ol_cv_db_db2=no
30602 fi
30603 rm -f conftest.err conftest.$ac_objext \
30604       conftest$ac_exeext conftest.$ac_ext
30605
30606         LIBS="$ol_LIBS"
30607
30608 fi
30609 echo "$as_me:$LINENO: result: $ol_cv_db_db2" >&5
30610 echo "${ECHO_T}$ol_cv_db_db2" >&6
30611
30612         if test $ol_cv_db_db2 = yes ; then
30613                 ol_cv_lib_db=-ldb2
30614         fi
30615 fi
30616
30617         if test $ol_cv_lib_db = no ; then
30618         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-2)" >&5
30619 echo $ECHO_N "checking for Berkeley DB link (-ldb-2)... $ECHO_C" >&6
30620 if test "${ol_cv_db_db_2+set}" = set; then
30621   echo $ECHO_N "(cached) $ECHO_C" >&6
30622 else
30623
30624         ol_DB_LIB=-ldb-2
30625         ol_LIBS=$LIBS
30626         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30627
30628         cat >conftest.$ac_ext <<_ACEOF
30629 /* confdefs.h.  */
30630 _ACEOF
30631 cat confdefs.h >>conftest.$ac_ext
30632 cat >>conftest.$ac_ext <<_ACEOF
30633 /* end confdefs.h.  */
30634
30635 #ifdef HAVE_DB_185_H
30636 # include <db_185.h>
30637 #else
30638 # include <db.h>
30639 #endif
30640
30641 #ifndef DB_VERSION_MAJOR
30642 # define DB_VERSION_MAJOR 1
30643 #endif
30644
30645 #ifndef NULL
30646 #define NULL ((void*)0)
30647 #endif
30648
30649 int
30650 main ()
30651 {
30652
30653 #if DB_VERSION_MAJOR > 1
30654         {
30655                 char *version;
30656                 int major, minor, patch;
30657
30658                 version = db_version( &major, &minor, &patch );
30659
30660                 if( major != DB_VERSION_MAJOR ||
30661                         minor < DB_VERSION_MINOR )
30662                 {
30663                         printf("Berkeley DB version mismatch\n"
30664                                 "\theader: %s\n\tlibrary: %s\n",
30665                                 DB_VERSION_STRING, version);
30666                         return 1;
30667                 }
30668         }
30669 #endif
30670
30671 #if DB_VERSION_MAJOR > 2
30672         db_env_create( NULL, 0 );
30673 #elif DB_VERSION_MAJOR > 1
30674         db_appexit( NULL );
30675 #else
30676         (void) dbopen( NULL, 0, 0, 0, NULL);
30677 #endif
30678
30679   ;
30680   return 0;
30681 }
30682 _ACEOF
30683 rm -f conftest.$ac_objext conftest$ac_exeext
30684 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30685   (eval $ac_link) 2>conftest.er1
30686   ac_status=$?
30687   grep -v '^ *+' conftest.er1 >conftest.err
30688   rm -f conftest.er1
30689   cat conftest.err >&5
30690   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30691   (exit $ac_status); } &&
30692          { ac_try='test -z "$ac_c_werror_flag"
30693                          || test ! -s conftest.err'
30694   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30695   (eval $ac_try) 2>&5
30696   ac_status=$?
30697   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30698   (exit $ac_status); }; } &&
30699          { ac_try='test -s conftest$ac_exeext'
30700   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30701   (eval $ac_try) 2>&5
30702   ac_status=$?
30703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30704   (exit $ac_status); }; }; then
30705   ol_cv_db_db_2=yes
30706 else
30707   echo "$as_me: failed program was:" >&5
30708 sed 's/^/| /' conftest.$ac_ext >&5
30709
30710 ol_cv_db_db_2=no
30711 fi
30712 rm -f conftest.err conftest.$ac_objext \
30713       conftest$ac_exeext conftest.$ac_ext
30714
30715         LIBS="$ol_LIBS"
30716
30717 fi
30718 echo "$as_me:$LINENO: result: $ol_cv_db_db_2" >&5
30719 echo "${ECHO_T}$ol_cv_db_db_2" >&6
30720
30721         if test $ol_cv_db_db_2 = yes ; then
30722                 ol_cv_lib_db=-ldb-2
30723         fi
30724 fi
30725
30726
30727 elif test $ol_cv_bdb_major = 1 ; then
30728         if test $ol_cv_lib_db = no ; then
30729         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb1)" >&5
30730 echo $ECHO_N "checking for Berkeley DB link (-ldb1)... $ECHO_C" >&6
30731 if test "${ol_cv_db_db1+set}" = set; then
30732   echo $ECHO_N "(cached) $ECHO_C" >&6
30733 else
30734
30735         ol_DB_LIB=-ldb1
30736         ol_LIBS=$LIBS
30737         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30738
30739         cat >conftest.$ac_ext <<_ACEOF
30740 /* confdefs.h.  */
30741 _ACEOF
30742 cat confdefs.h >>conftest.$ac_ext
30743 cat >>conftest.$ac_ext <<_ACEOF
30744 /* end confdefs.h.  */
30745
30746 #ifdef HAVE_DB_185_H
30747 # include <db_185.h>
30748 #else
30749 # include <db.h>
30750 #endif
30751
30752 #ifndef DB_VERSION_MAJOR
30753 # define DB_VERSION_MAJOR 1
30754 #endif
30755
30756 #ifndef NULL
30757 #define NULL ((void*)0)
30758 #endif
30759
30760 int
30761 main ()
30762 {
30763
30764 #if DB_VERSION_MAJOR > 1
30765         {
30766                 char *version;
30767                 int major, minor, patch;
30768
30769                 version = db_version( &major, &minor, &patch );
30770
30771                 if( major != DB_VERSION_MAJOR ||
30772                         minor < DB_VERSION_MINOR )
30773                 {
30774                         printf("Berkeley DB version mismatch\n"
30775                                 "\theader: %s\n\tlibrary: %s\n",
30776                                 DB_VERSION_STRING, version);
30777                         return 1;
30778                 }
30779         }
30780 #endif
30781
30782 #if DB_VERSION_MAJOR > 2
30783         db_env_create( NULL, 0 );
30784 #elif DB_VERSION_MAJOR > 1
30785         db_appexit( NULL );
30786 #else
30787         (void) dbopen( NULL, 0, 0, 0, NULL);
30788 #endif
30789
30790   ;
30791   return 0;
30792 }
30793 _ACEOF
30794 rm -f conftest.$ac_objext conftest$ac_exeext
30795 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30796   (eval $ac_link) 2>conftest.er1
30797   ac_status=$?
30798   grep -v '^ *+' conftest.er1 >conftest.err
30799   rm -f conftest.er1
30800   cat conftest.err >&5
30801   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30802   (exit $ac_status); } &&
30803          { ac_try='test -z "$ac_c_werror_flag"
30804                          || test ! -s conftest.err'
30805   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30806   (eval $ac_try) 2>&5
30807   ac_status=$?
30808   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30809   (exit $ac_status); }; } &&
30810          { ac_try='test -s conftest$ac_exeext'
30811   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30812   (eval $ac_try) 2>&5
30813   ac_status=$?
30814   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30815   (exit $ac_status); }; }; then
30816   ol_cv_db_db1=yes
30817 else
30818   echo "$as_me: failed program was:" >&5
30819 sed 's/^/| /' conftest.$ac_ext >&5
30820
30821 ol_cv_db_db1=no
30822 fi
30823 rm -f conftest.err conftest.$ac_objext \
30824       conftest$ac_exeext conftest.$ac_ext
30825
30826         LIBS="$ol_LIBS"
30827
30828 fi
30829 echo "$as_me:$LINENO: result: $ol_cv_db_db1" >&5
30830 echo "${ECHO_T}$ol_cv_db_db1" >&6
30831
30832         if test $ol_cv_db_db1 = yes ; then
30833                 ol_cv_lib_db=-ldb1
30834         fi
30835 fi
30836
30837         if test $ol_cv_lib_db = no ; then
30838         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-1)" >&5
30839 echo $ECHO_N "checking for Berkeley DB link (-ldb-1)... $ECHO_C" >&6
30840 if test "${ol_cv_db_db_1+set}" = set; then
30841   echo $ECHO_N "(cached) $ECHO_C" >&6
30842 else
30843
30844         ol_DB_LIB=-ldb-1
30845         ol_LIBS=$LIBS
30846         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30847
30848         cat >conftest.$ac_ext <<_ACEOF
30849 /* confdefs.h.  */
30850 _ACEOF
30851 cat confdefs.h >>conftest.$ac_ext
30852 cat >>conftest.$ac_ext <<_ACEOF
30853 /* end confdefs.h.  */
30854
30855 #ifdef HAVE_DB_185_H
30856 # include <db_185.h>
30857 #else
30858 # include <db.h>
30859 #endif
30860
30861 #ifndef DB_VERSION_MAJOR
30862 # define DB_VERSION_MAJOR 1
30863 #endif
30864
30865 #ifndef NULL
30866 #define NULL ((void*)0)
30867 #endif
30868
30869 int
30870 main ()
30871 {
30872
30873 #if DB_VERSION_MAJOR > 1
30874         {
30875                 char *version;
30876                 int major, minor, patch;
30877
30878                 version = db_version( &major, &minor, &patch );
30879
30880                 if( major != DB_VERSION_MAJOR ||
30881                         minor < DB_VERSION_MINOR )
30882                 {
30883                         printf("Berkeley DB version mismatch\n"
30884                                 "\theader: %s\n\tlibrary: %s\n",
30885                                 DB_VERSION_STRING, version);
30886                         return 1;
30887                 }
30888         }
30889 #endif
30890
30891 #if DB_VERSION_MAJOR > 2
30892         db_env_create( NULL, 0 );
30893 #elif DB_VERSION_MAJOR > 1
30894         db_appexit( NULL );
30895 #else
30896         (void) dbopen( NULL, 0, 0, 0, NULL);
30897 #endif
30898
30899   ;
30900   return 0;
30901 }
30902 _ACEOF
30903 rm -f conftest.$ac_objext conftest$ac_exeext
30904 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30905   (eval $ac_link) 2>conftest.er1
30906   ac_status=$?
30907   grep -v '^ *+' conftest.er1 >conftest.err
30908   rm -f conftest.er1
30909   cat conftest.err >&5
30910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30911   (exit $ac_status); } &&
30912          { ac_try='test -z "$ac_c_werror_flag"
30913                          || test ! -s conftest.err'
30914   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30915   (eval $ac_try) 2>&5
30916   ac_status=$?
30917   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30918   (exit $ac_status); }; } &&
30919          { ac_try='test -s conftest$ac_exeext'
30920   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30921   (eval $ac_try) 2>&5
30922   ac_status=$?
30923   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30924   (exit $ac_status); }; }; then
30925   ol_cv_db_db_1=yes
30926 else
30927   echo "$as_me: failed program was:" >&5
30928 sed 's/^/| /' conftest.$ac_ext >&5
30929
30930 ol_cv_db_db_1=no
30931 fi
30932 rm -f conftest.err conftest.$ac_objext \
30933       conftest$ac_exeext conftest.$ac_ext
30934
30935         LIBS="$ol_LIBS"
30936
30937 fi
30938 echo "$as_me:$LINENO: result: $ol_cv_db_db_1" >&5
30939 echo "${ECHO_T}$ol_cv_db_db_1" >&6
30940
30941         if test $ol_cv_db_db_1 = yes ; then
30942                 ol_cv_lib_db=-ldb-1
30943         fi
30944 fi
30945
30946 fi
30947 if test $ol_cv_lib_db = no ; then
30948         echo "$as_me:$LINENO: checking for Berkeley DB link (default)" >&5
30949 echo $ECHO_N "checking for Berkeley DB link (default)... $ECHO_C" >&6
30950 if test "${ol_cv_db_none+set}" = set; then
30951   echo $ECHO_N "(cached) $ECHO_C" >&6
30952 else
30953
30954         ol_DB_LIB=
30955         ol_LIBS=$LIBS
30956         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
30957
30958         cat >conftest.$ac_ext <<_ACEOF
30959 /* confdefs.h.  */
30960 _ACEOF
30961 cat confdefs.h >>conftest.$ac_ext
30962 cat >>conftest.$ac_ext <<_ACEOF
30963 /* end confdefs.h.  */
30964
30965 #ifdef HAVE_DB_185_H
30966 # include <db_185.h>
30967 #else
30968 # include <db.h>
30969 #endif
30970
30971 #ifndef DB_VERSION_MAJOR
30972 # define DB_VERSION_MAJOR 1
30973 #endif
30974
30975 #ifndef NULL
30976 #define NULL ((void*)0)
30977 #endif
30978
30979 int
30980 main ()
30981 {
30982
30983 #if DB_VERSION_MAJOR > 1
30984         {
30985                 char *version;
30986                 int major, minor, patch;
30987
30988                 version = db_version( &major, &minor, &patch );
30989
30990                 if( major != DB_VERSION_MAJOR ||
30991                         minor < DB_VERSION_MINOR )
30992                 {
30993                         printf("Berkeley DB version mismatch\n"
30994                                 "\theader: %s\n\tlibrary: %s\n",
30995                                 DB_VERSION_STRING, version);
30996                         return 1;
30997                 }
30998         }
30999 #endif
31000
31001 #if DB_VERSION_MAJOR > 2
31002         db_env_create( NULL, 0 );
31003 #elif DB_VERSION_MAJOR > 1
31004         db_appexit( NULL );
31005 #else
31006         (void) dbopen( NULL, 0, 0, 0, NULL);
31007 #endif
31008
31009   ;
31010   return 0;
31011 }
31012 _ACEOF
31013 rm -f conftest.$ac_objext conftest$ac_exeext
31014 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31015   (eval $ac_link) 2>conftest.er1
31016   ac_status=$?
31017   grep -v '^ *+' conftest.er1 >conftest.err
31018   rm -f conftest.er1
31019   cat conftest.err >&5
31020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31021   (exit $ac_status); } &&
31022          { ac_try='test -z "$ac_c_werror_flag"
31023                          || test ! -s conftest.err'
31024   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31025   (eval $ac_try) 2>&5
31026   ac_status=$?
31027   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31028   (exit $ac_status); }; } &&
31029          { ac_try='test -s conftest$ac_exeext'
31030   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31031   (eval $ac_try) 2>&5
31032   ac_status=$?
31033   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31034   (exit $ac_status); }; }; then
31035   ol_cv_db_none=yes
31036 else
31037   echo "$as_me: failed program was:" >&5
31038 sed 's/^/| /' conftest.$ac_ext >&5
31039
31040 ol_cv_db_none=no
31041 fi
31042 rm -f conftest.err conftest.$ac_objext \
31043       conftest$ac_exeext conftest.$ac_ext
31044
31045         LIBS="$ol_LIBS"
31046
31047 fi
31048 echo "$as_me:$LINENO: result: $ol_cv_db_none" >&5
31049 echo "${ECHO_T}$ol_cv_db_none" >&6
31050
31051         if test $ol_cv_db_none = yes ; then
31052                 ol_cv_lib_db=yes
31053         fi
31054 fi
31055
31056
31057         if test "$ol_cv_lib_db" != no ; then
31058                 ol_cv_berkeley_db=yes
31059                 echo "$as_me:$LINENO: checking for Berkeley DB version match" >&5
31060 echo $ECHO_N "checking for Berkeley DB version match... $ECHO_C" >&6
31061 if test "${ol_cv_berkeley_db_version+set}" = set; then
31062   echo $ECHO_N "(cached) $ECHO_C" >&6
31063 else
31064
31065         ol_LIBS="$LIBS"
31066         LIBS="$LTHREAD_LIBS $LIBS"
31067         if test $ol_cv_lib_db != yes ; then
31068                 LIBS="$ol_cv_lib_db $LIBS"
31069         fi
31070
31071         if test "$cross_compiling" = yes; then
31072   ol_cv_berkeley_db_version=cross
31073 else
31074   cat >conftest.$ac_ext <<_ACEOF
31075 /* confdefs.h.  */
31076 _ACEOF
31077 cat confdefs.h >>conftest.$ac_ext
31078 cat >>conftest.$ac_ext <<_ACEOF
31079 /* end confdefs.h.  */
31080
31081 #ifdef HAVE_DB_185_H
31082         choke me;
31083 #else
31084 #include <db.h>
31085 #endif
31086 #ifndef DB_VERSION_MAJOR
31087 # define DB_VERSION_MAJOR 1
31088 #endif
31089 #ifndef NULL
31090 #define NULL ((void *)0)
31091 #endif
31092 main()
31093 {
31094 #if DB_VERSION_MAJOR > 1
31095         char *version;
31096         int major, minor, patch;
31097
31098         version = db_version( &major, &minor, &patch );
31099
31100         if( major != DB_VERSION_MAJOR ||
31101                 minor != DB_VERSION_MINOR ||
31102                 patch != DB_VERSION_PATCH )
31103         {
31104                 printf("Berkeley DB version mismatch\n"
31105                         "\theader: %s\n\tlibrary: %s\n",
31106                         DB_VERSION_STRING, version);
31107                 return 1;
31108         }
31109 #endif
31110
31111         return 0;
31112 }
31113 _ACEOF
31114 rm -f conftest$ac_exeext
31115 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31116   (eval $ac_link) 2>&5
31117   ac_status=$?
31118   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31119   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
31120   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31121   (eval $ac_try) 2>&5
31122   ac_status=$?
31123   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31124   (exit $ac_status); }; }; then
31125   ol_cv_berkeley_db_version=yes
31126 else
31127   echo "$as_me: program exited with status $ac_status" >&5
31128 echo "$as_me: failed program was:" >&5
31129 sed 's/^/| /' conftest.$ac_ext >&5
31130
31131 ( exit $ac_status )
31132 ol_cv_berkeley_db_version=no
31133 fi
31134 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
31135 fi
31136
31137         LIBS="$ol_LIBS"
31138
31139 fi
31140 echo "$as_me:$LINENO: result: $ol_cv_berkeley_db_version" >&5
31141 echo "${ECHO_T}$ol_cv_berkeley_db_version" >&6
31142
31143         if test $ol_cv_berkeley_db_version = no ; then
31144                 { { echo "$as_me:$LINENO: error: Berkeley DB version mismatch" >&5
31145 echo "$as_me: error: Berkeley DB version mismatch" >&2;}
31146    { (exit 1); exit 1; }; }
31147         fi
31148
31149                 echo "$as_me:$LINENO: checking for Berkeley DB thread support" >&5
31150 echo $ECHO_N "checking for Berkeley DB thread support... $ECHO_C" >&6
31151 if test "${ol_cv_berkeley_db_thread+set}" = set; then
31152   echo $ECHO_N "(cached) $ECHO_C" >&6
31153 else
31154
31155         ol_LIBS="$LIBS"
31156         LIBS="$LTHREAD_LIBS $LIBS"
31157         if test $ol_cv_lib_db != yes ; then
31158                 LIBS="$ol_cv_lib_db $LIBS"
31159         fi
31160
31161         if test "$cross_compiling" = yes; then
31162   ol_cv_berkeley_db_thread=cross
31163 else
31164   cat >conftest.$ac_ext <<_ACEOF
31165 /* confdefs.h.  */
31166 _ACEOF
31167 cat confdefs.h >>conftest.$ac_ext
31168 cat >>conftest.$ac_ext <<_ACEOF
31169 /* end confdefs.h.  */
31170
31171 #ifdef HAVE_DB_185_H
31172         choke me;
31173 #else
31174 #include <db.h>
31175 #endif
31176 #ifndef NULL
31177 #define NULL ((void *)0)
31178 #endif
31179 main()
31180 {
31181         int rc;
31182         u_int32_t flags = DB_CREATE |
31183 #ifdef DB_PRIVATE
31184                 DB_PRIVATE |
31185 #endif
31186                 DB_THREAD;
31187
31188 #if DB_VERSION_MAJOR > 2
31189         DB_ENV *env = NULL;
31190
31191         rc = db_env_create( &env, 0 );
31192
31193         flags |= DB_INIT_MPOOL;
31194 #ifdef DB_MPOOL_PRIVATE
31195         flags |= DB_MPOOL_PRIVATE;
31196 #endif
31197
31198         if( rc ) {
31199                 printf("BerkeleyDB: %s\n", db_strerror(rc) );
31200                 return rc;
31201         }
31202
31203 #if (DB_VERSION_MAJOR > 3) || (DB_VERSION_MINOR >= 1)
31204         rc = (env->open)( env, NULL, flags, 0 );
31205 #else
31206         rc = (env->open)( env, NULL, NULL, flags, 0 );
31207 #endif
31208
31209         if ( rc == 0 ) {
31210                 rc = env->close( env, 0 );
31211         }
31212
31213         if( rc ) {
31214                 printf("BerkeleyDB: %s\n", db_strerror(rc) );
31215                 return rc;
31216         }
31217
31218 #else
31219         DB_ENV env;
31220         memset( &env, '\0', sizeof(env) );
31221
31222         rc = db_appinit( NULL, NULL, &env, flags );
31223
31224         if( rc == 0 ) {
31225                 db_appexit( &env );
31226         }
31227
31228         unlink("__db_mpool.share");
31229         unlink("__db_lock.share");
31230 #endif
31231
31232         return rc;
31233 }
31234 _ACEOF
31235 rm -f conftest$ac_exeext
31236 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31237   (eval $ac_link) 2>&5
31238   ac_status=$?
31239   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31240   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
31241   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31242   (eval $ac_try) 2>&5
31243   ac_status=$?
31244   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31245   (exit $ac_status); }; }; then
31246   ol_cv_berkeley_db_thread=yes
31247 else
31248   echo "$as_me: program exited with status $ac_status" >&5
31249 echo "$as_me: failed program was:" >&5
31250 sed 's/^/| /' conftest.$ac_ext >&5
31251
31252 ( exit $ac_status )
31253 ol_cv_berkeley_db_thread=no
31254 fi
31255 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
31256 fi
31257
31258         LIBS="$ol_LIBS"
31259
31260 fi
31261 echo "$as_me:$LINENO: result: $ol_cv_berkeley_db_thread" >&5
31262 echo "${ECHO_T}$ol_cv_berkeley_db_thread" >&6
31263
31264         if test $ol_cv_berkeley_db_thread != no ; then
31265
31266 cat >>confdefs.h <<\_ACEOF
31267 #define HAVE_BERKELEY_DB_THREAD 1
31268 _ACEOF
31269
31270         fi
31271
31272         fi
31273 fi
31274
31275
31276         if test $ol_cv_berkeley_db = no ; then
31277                 { { echo "$as_me:$LINENO: error: BDB/HDB: BerkeleyDB not available" >&5
31278 echo "$as_me: error: BDB/HDB: BerkeleyDB not available" >&2;}
31279    { (exit 1); exit 1; }; }
31280         fi
31281
31282
31283 cat >>confdefs.h <<\_ACEOF
31284 #define HAVE_BERKELEY_DB 1
31285 _ACEOF
31286
31287
31288                         if test $ol_cv_lib_db != yes ; then
31289                 BDB_LIBS="$BDB_LIBS $ol_cv_lib_db"
31290         fi
31291
31292         echo "$as_me:$LINENO: checking Berkeley DB version for BDB/HDB backends" >&5
31293 echo $ECHO_N "checking Berkeley DB version for BDB/HDB backends... $ECHO_C" >&6
31294 if test "${ol_cv_bdb_compat+set}" = set; then
31295   echo $ECHO_N "(cached) $ECHO_C" >&6
31296 else
31297
31298         cat >conftest.$ac_ext <<_ACEOF
31299 /* confdefs.h.  */
31300 _ACEOF
31301 cat confdefs.h >>conftest.$ac_ext
31302 cat >>conftest.$ac_ext <<_ACEOF
31303 /* end confdefs.h.  */
31304
31305 #include <db.h>
31306
31307  /* this check could be improved */
31308 #ifndef DB_VERSION_MAJOR
31309 #       define DB_VERSION_MAJOR 1
31310 #endif
31311 #ifndef DB_VERSION_MINOR
31312 #       define DB_VERSION_MINOR 0
31313 #endif
31314
31315 /* require 4.2 or later, but exclude 4.3 */
31316 #if (DB_VERSION_MAJOR >= 4) && (DB_VERSION_MINOR >= 2) && (DB_VERSION_MINOR !=3)
31317         __db_version_compat
31318 #endif
31319
31320 _ACEOF
31321 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
31322   $EGREP "__db_version_compat" >/dev/null 2>&1; then
31323   ol_cv_bdb_compat=yes
31324 else
31325   ol_cv_bdb_compat=no
31326 fi
31327 rm -f conftest*
31328
31329 fi
31330 echo "$as_me:$LINENO: result: $ol_cv_bdb_compat" >&5
31331 echo "${ECHO_T}$ol_cv_bdb_compat" >&6
31332
31333
31334         if test $ol_cv_bdb_compat != yes ; then
31335                 { { echo "$as_me:$LINENO: error: BDB/HDB: BerkeleyDB version incompatible" >&5
31336 echo "$as_me: error: BDB/HDB: BerkeleyDB version incompatible" >&2;}
31337    { (exit 1); exit 1; }; }
31338         fi
31339
31340         SLAPD_LIBS="$SLAPD_LIBS \$(BDB_LIBS)"
31341
31342         ol_link_bdb=yes
31343 fi
31344
31345
31346 if test $ol_enable_dynamic = yes && test $enable_shared = yes ; then
31347         BUILD_LIBS_DYNAMIC=shared
31348
31349 cat >>confdefs.h <<\_ACEOF
31350 #define LDAP_LIBS_DYNAMIC 1
31351 _ACEOF
31352
31353         LTSTATIC=""
31354 else
31355         BUILD_LIBS_DYNAMIC=static
31356         LTSTATIC="-static"
31357 fi
31358
31359 if test $ol_enable_wrappers != no ; then
31360
31361 for ac_header in tcpd.h
31362 do
31363 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
31364 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31365   echo "$as_me:$LINENO: checking for $ac_header" >&5
31366 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31367 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31368   echo $ECHO_N "(cached) $ECHO_C" >&6
31369 fi
31370 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31371 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31372 else
31373   # Is the header compilable?
31374 echo "$as_me:$LINENO: checking $ac_header usability" >&5
31375 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
31376 cat >conftest.$ac_ext <<_ACEOF
31377 /* confdefs.h.  */
31378 _ACEOF
31379 cat confdefs.h >>conftest.$ac_ext
31380 cat >>conftest.$ac_ext <<_ACEOF
31381 /* end confdefs.h.  */
31382 $ac_includes_default
31383 #include <$ac_header>
31384 _ACEOF
31385 rm -f conftest.$ac_objext
31386 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31387   (eval $ac_compile) 2>conftest.er1
31388   ac_status=$?
31389   grep -v '^ *+' conftest.er1 >conftest.err
31390   rm -f conftest.er1
31391   cat conftest.err >&5
31392   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31393   (exit $ac_status); } &&
31394          { ac_try='test -z "$ac_c_werror_flag"
31395                          || test ! -s conftest.err'
31396   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31397   (eval $ac_try) 2>&5
31398   ac_status=$?
31399   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31400   (exit $ac_status); }; } &&
31401          { ac_try='test -s conftest.$ac_objext'
31402   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31403   (eval $ac_try) 2>&5
31404   ac_status=$?
31405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31406   (exit $ac_status); }; }; then
31407   ac_header_compiler=yes
31408 else
31409   echo "$as_me: failed program was:" >&5
31410 sed 's/^/| /' conftest.$ac_ext >&5
31411
31412 ac_header_compiler=no
31413 fi
31414 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
31415 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
31416 echo "${ECHO_T}$ac_header_compiler" >&6
31417
31418 # Is the header present?
31419 echo "$as_me:$LINENO: checking $ac_header presence" >&5
31420 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
31421 cat >conftest.$ac_ext <<_ACEOF
31422 /* confdefs.h.  */
31423 _ACEOF
31424 cat confdefs.h >>conftest.$ac_ext
31425 cat >>conftest.$ac_ext <<_ACEOF
31426 /* end confdefs.h.  */
31427 #include <$ac_header>
31428 _ACEOF
31429 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
31430   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
31431   ac_status=$?
31432   grep -v '^ *+' conftest.er1 >conftest.err
31433   rm -f conftest.er1
31434   cat conftest.err >&5
31435   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31436   (exit $ac_status); } >/dev/null; then
31437   if test -s conftest.err; then
31438     ac_cpp_err=$ac_c_preproc_warn_flag
31439     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
31440   else
31441     ac_cpp_err=
31442   fi
31443 else
31444   ac_cpp_err=yes
31445 fi
31446 if test -z "$ac_cpp_err"; then
31447   ac_header_preproc=yes
31448 else
31449   echo "$as_me: failed program was:" >&5
31450 sed 's/^/| /' conftest.$ac_ext >&5
31451
31452   ac_header_preproc=no
31453 fi
31454 rm -f conftest.err conftest.$ac_ext
31455 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
31456 echo "${ECHO_T}$ac_header_preproc" >&6
31457
31458 # So?  What about this header?
31459 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
31460   yes:no: )
31461     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
31462 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
31463     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
31464 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
31465     ac_header_preproc=yes
31466     ;;
31467   no:yes:* )
31468     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
31469 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
31470     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
31471 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
31472     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
31473 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
31474     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
31475 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
31476     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
31477 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
31478     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
31479 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
31480     (
31481       cat <<\_ASBOX
31482 ## --------------------------------------------- ##
31483 ## Report this to <http://www.openldap.org/its/> ##
31484 ## --------------------------------------------- ##
31485 _ASBOX
31486     ) |
31487       sed "s/^/$as_me: WARNING:     /" >&2
31488     ;;
31489 esac
31490 echo "$as_me:$LINENO: checking for $ac_header" >&5
31491 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31492 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31493   echo $ECHO_N "(cached) $ECHO_C" >&6
31494 else
31495   eval "$as_ac_Header=\$ac_header_preproc"
31496 fi
31497 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31498 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31499
31500 fi
31501 if test `eval echo '${'$as_ac_Header'}'` = yes; then
31502   cat >>confdefs.h <<_ACEOF
31503 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
31504 _ACEOF
31505
31506                 echo "$as_me:$LINENO: checking for TCP wrappers library" >&5
31507 echo $ECHO_N "checking for TCP wrappers library... $ECHO_C" >&6
31508                 save_LIBS="$LIBS"
31509                 LIBS="$LIBS -lwrap"
31510                 cat >conftest.$ac_ext <<_ACEOF
31511 /* confdefs.h.  */
31512 _ACEOF
31513 cat confdefs.h >>conftest.$ac_ext
31514 cat >>conftest.$ac_ext <<_ACEOF
31515 /* end confdefs.h.  */
31516
31517 #include <tcpd.h>
31518 int allow_severity = 0;
31519 int deny_severity  = 0;
31520
31521 struct request_info *req;
31522
31523 int
31524 main ()
31525 {
31526
31527 hosts_access(req)
31528
31529   ;
31530   return 0;
31531 }
31532 _ACEOF
31533 rm -f conftest.$ac_objext conftest$ac_exeext
31534 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31535   (eval $ac_link) 2>conftest.er1
31536   ac_status=$?
31537   grep -v '^ *+' conftest.er1 >conftest.err
31538   rm -f conftest.er1
31539   cat conftest.err >&5
31540   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31541   (exit $ac_status); } &&
31542          { ac_try='test -z "$ac_c_werror_flag"
31543                          || test ! -s conftest.err'
31544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31545   (eval $ac_try) 2>&5
31546   ac_status=$?
31547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31548   (exit $ac_status); }; } &&
31549          { ac_try='test -s conftest$ac_exeext'
31550   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31551   (eval $ac_try) 2>&5
31552   ac_status=$?
31553   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31554   (exit $ac_status); }; }; then
31555   echo "$as_me:$LINENO: result: -lwrap" >&5
31556 echo "${ECHO_T}-lwrap" >&6
31557                 have_wrappers=yes
31558                 LIBS="$save_LIBS"
31559 else
31560   echo "$as_me: failed program was:" >&5
31561 sed 's/^/| /' conftest.$ac_ext >&5
31562
31563
31564                                 LIBS="$LIBS -lnsl"
31565                 cat >conftest.$ac_ext <<_ACEOF
31566 /* confdefs.h.  */
31567 _ACEOF
31568 cat confdefs.h >>conftest.$ac_ext
31569 cat >>conftest.$ac_ext <<_ACEOF
31570 /* end confdefs.h.  */
31571
31572 #include <tcpd.h>
31573 int allow_severity = 0;
31574 int deny_severity  = 0;
31575
31576 struct request_info *req;
31577
31578 int
31579 main ()
31580 {
31581
31582 hosts_access(req)
31583
31584   ;
31585   return 0;
31586 }
31587 _ACEOF
31588 rm -f conftest.$ac_objext conftest$ac_exeext
31589 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31590   (eval $ac_link) 2>conftest.er1
31591   ac_status=$?
31592   grep -v '^ *+' conftest.er1 >conftest.err
31593   rm -f conftest.er1
31594   cat conftest.err >&5
31595   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31596   (exit $ac_status); } &&
31597          { ac_try='test -z "$ac_c_werror_flag"
31598                          || test ! -s conftest.err'
31599   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31600   (eval $ac_try) 2>&5
31601   ac_status=$?
31602   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31603   (exit $ac_status); }; } &&
31604          { ac_try='test -s conftest$ac_exeext'
31605   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31606   (eval $ac_try) 2>&5
31607   ac_status=$?
31608   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31609   (exit $ac_status); }; }; then
31610   echo "$as_me:$LINENO: result: -lwrap -lnsl" >&5
31611 echo "${ECHO_T}-lwrap -lnsl" >&6
31612                 have_wrappers=yes
31613                 LIBS="$save_LIBS -lnsl"
31614 else
31615   echo "$as_me: failed program was:" >&5
31616 sed 's/^/| /' conftest.$ac_ext >&5
31617
31618
31619                 echo "$as_me:$LINENO: result: no" >&5
31620 echo "${ECHO_T}no" >&6
31621                 have_wrappers=no
31622                 LIBS=$save_LIBS
31623 fi
31624 rm -f conftest.err conftest.$ac_objext \
31625       conftest$ac_exeext conftest.$ac_ext
31626 fi
31627 rm -f conftest.err conftest.$ac_objext \
31628       conftest$ac_exeext conftest.$ac_ext
31629 else
31630   have_wrappers=no
31631 fi
31632
31633 done
31634
31635
31636         if test $have_wrappers = yes ; then
31637
31638 cat >>confdefs.h <<\_ACEOF
31639 #define HAVE_TCPD 1
31640 _ACEOF
31641
31642                 WRAP_LIBS="-lwrap"
31643         elif test $ol_enable_wrappers = yes ; then
31644                 { { echo "$as_me:$LINENO: error: could not find TCP wrappers, select apppropriate options or disable" >&5
31645 echo "$as_me: error: could not find TCP wrappers, select apppropriate options or disable" >&2;}
31646    { (exit 1); exit 1; }; }
31647         else
31648                 { echo "$as_me:$LINENO: WARNING: could not find TCP wrappers, support disabled" >&5
31649 echo "$as_me: WARNING: could not find TCP wrappers, support disabled" >&2;}
31650                 WRAP_LIBS=""
31651         fi
31652 fi
31653
31654 if test $ol_enable_syslog != no ; then
31655         echo "$as_me:$LINENO: checking for openlog" >&5
31656 echo $ECHO_N "checking for openlog... $ECHO_C" >&6
31657 if test "${ac_cv_func_openlog+set}" = set; then
31658   echo $ECHO_N "(cached) $ECHO_C" >&6
31659 else
31660   cat >conftest.$ac_ext <<_ACEOF
31661 /* confdefs.h.  */
31662 _ACEOF
31663 cat confdefs.h >>conftest.$ac_ext
31664 cat >>conftest.$ac_ext <<_ACEOF
31665 /* end confdefs.h.  */
31666 /* Define openlog to an innocuous variant, in case <limits.h> declares openlog.
31667    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
31668 #define openlog innocuous_openlog
31669
31670 /* System header to define __stub macros and hopefully few prototypes,
31671     which can conflict with char openlog (); below.
31672     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31673     <limits.h> exists even on freestanding compilers.  */
31674
31675 #ifdef __STDC__
31676 # include <limits.h>
31677 #else
31678 # include <assert.h>
31679 #endif
31680
31681 #undef openlog
31682
31683 /* Override any gcc2 internal prototype to avoid an error.  */
31684 #ifdef __cplusplus
31685 extern "C"
31686 {
31687 #endif
31688 /* We use char because int might match the return type of a gcc2
31689    builtin and then its argument prototype would still apply.  */
31690 char openlog ();
31691 /* The GNU C library defines this for functions which it implements
31692     to always fail with ENOSYS.  Some functions are actually named
31693     something starting with __ and the normal name is an alias.  */
31694 #if defined (__stub_openlog) || defined (__stub___openlog)
31695 choke me
31696 #else
31697 char (*f) () = openlog;
31698 #endif
31699 #ifdef __cplusplus
31700 }
31701 #endif
31702
31703 int
31704 main ()
31705 {
31706 return f != openlog;
31707   ;
31708   return 0;
31709 }
31710 _ACEOF
31711 rm -f conftest.$ac_objext conftest$ac_exeext
31712 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31713   (eval $ac_link) 2>conftest.er1
31714   ac_status=$?
31715   grep -v '^ *+' conftest.er1 >conftest.err
31716   rm -f conftest.er1
31717   cat conftest.err >&5
31718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31719   (exit $ac_status); } &&
31720          { ac_try='test -z "$ac_c_werror_flag"
31721                          || test ! -s conftest.err'
31722   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31723   (eval $ac_try) 2>&5
31724   ac_status=$?
31725   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31726   (exit $ac_status); }; } &&
31727          { ac_try='test -s conftest$ac_exeext'
31728   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31729   (eval $ac_try) 2>&5
31730   ac_status=$?
31731   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31732   (exit $ac_status); }; }; then
31733   ac_cv_func_openlog=yes
31734 else
31735   echo "$as_me: failed program was:" >&5
31736 sed 's/^/| /' conftest.$ac_ext >&5
31737
31738 ac_cv_func_openlog=no
31739 fi
31740 rm -f conftest.err conftest.$ac_objext \
31741       conftest$ac_exeext conftest.$ac_ext
31742 fi
31743 echo "$as_me:$LINENO: result: $ac_cv_func_openlog" >&5
31744 echo "${ECHO_T}$ac_cv_func_openlog" >&6
31745
31746         if test $ac_cv_func_openlog = no && test $ol_enable_syslog = yes; then
31747                 { { echo "$as_me:$LINENO: error: could not find syslog" >&5
31748 echo "$as_me: error: could not find syslog" >&2;}
31749    { (exit select appropriate options or disable); exit select appropriate options or disable; }; }
31750         fi
31751         ol_enable_syslog=$ac_cv_func_openlog
31752 fi
31753
31754 ol_link_sql=no
31755 if test $ol_enable_sql != no ; then
31756
31757
31758 for ac_header in sql.h sqlext.h
31759 do
31760 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
31761 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31762   echo "$as_me:$LINENO: checking for $ac_header" >&5
31763 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31764 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31765   echo $ECHO_N "(cached) $ECHO_C" >&6
31766 fi
31767 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31768 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31769 else
31770   # Is the header compilable?
31771 echo "$as_me:$LINENO: checking $ac_header usability" >&5
31772 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
31773 cat >conftest.$ac_ext <<_ACEOF
31774 /* confdefs.h.  */
31775 _ACEOF
31776 cat confdefs.h >>conftest.$ac_ext
31777 cat >>conftest.$ac_ext <<_ACEOF
31778 /* end confdefs.h.  */
31779 $ac_includes_default
31780 #include <$ac_header>
31781 _ACEOF
31782 rm -f conftest.$ac_objext
31783 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31784   (eval $ac_compile) 2>conftest.er1
31785   ac_status=$?
31786   grep -v '^ *+' conftest.er1 >conftest.err
31787   rm -f conftest.er1
31788   cat conftest.err >&5
31789   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31790   (exit $ac_status); } &&
31791          { ac_try='test -z "$ac_c_werror_flag"
31792                          || test ! -s conftest.err'
31793   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31794   (eval $ac_try) 2>&5
31795   ac_status=$?
31796   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31797   (exit $ac_status); }; } &&
31798          { ac_try='test -s conftest.$ac_objext'
31799   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31800   (eval $ac_try) 2>&5
31801   ac_status=$?
31802   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31803   (exit $ac_status); }; }; then
31804   ac_header_compiler=yes
31805 else
31806   echo "$as_me: failed program was:" >&5
31807 sed 's/^/| /' conftest.$ac_ext >&5
31808
31809 ac_header_compiler=no
31810 fi
31811 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
31812 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
31813 echo "${ECHO_T}$ac_header_compiler" >&6
31814
31815 # Is the header present?
31816 echo "$as_me:$LINENO: checking $ac_header presence" >&5
31817 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
31818 cat >conftest.$ac_ext <<_ACEOF
31819 /* confdefs.h.  */
31820 _ACEOF
31821 cat confdefs.h >>conftest.$ac_ext
31822 cat >>conftest.$ac_ext <<_ACEOF
31823 /* end confdefs.h.  */
31824 #include <$ac_header>
31825 _ACEOF
31826 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
31827   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
31828   ac_status=$?
31829   grep -v '^ *+' conftest.er1 >conftest.err
31830   rm -f conftest.er1
31831   cat conftest.err >&5
31832   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31833   (exit $ac_status); } >/dev/null; then
31834   if test -s conftest.err; then
31835     ac_cpp_err=$ac_c_preproc_warn_flag
31836     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
31837   else
31838     ac_cpp_err=
31839   fi
31840 else
31841   ac_cpp_err=yes
31842 fi
31843 if test -z "$ac_cpp_err"; then
31844   ac_header_preproc=yes
31845 else
31846   echo "$as_me: failed program was:" >&5
31847 sed 's/^/| /' conftest.$ac_ext >&5
31848
31849   ac_header_preproc=no
31850 fi
31851 rm -f conftest.err conftest.$ac_ext
31852 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
31853 echo "${ECHO_T}$ac_header_preproc" >&6
31854
31855 # So?  What about this header?
31856 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
31857   yes:no: )
31858     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
31859 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
31860     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
31861 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
31862     ac_header_preproc=yes
31863     ;;
31864   no:yes:* )
31865     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
31866 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
31867     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
31868 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
31869     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
31870 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
31871     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
31872 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
31873     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
31874 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
31875     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
31876 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
31877     (
31878       cat <<\_ASBOX
31879 ## --------------------------------------------- ##
31880 ## Report this to <http://www.openldap.org/its/> ##
31881 ## --------------------------------------------- ##
31882 _ASBOX
31883     ) |
31884       sed "s/^/$as_me: WARNING:     /" >&2
31885     ;;
31886 esac
31887 echo "$as_me:$LINENO: checking for $ac_header" >&5
31888 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31889 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31890   echo $ECHO_N "(cached) $ECHO_C" >&6
31891 else
31892   eval "$as_ac_Header=\$ac_header_preproc"
31893 fi
31894 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31895 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31896
31897 fi
31898 if test `eval echo '${'$as_ac_Header'}'` = yes; then
31899   cat >>confdefs.h <<_ACEOF
31900 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
31901 _ACEOF
31902
31903 else
31904
31905                 { { echo "$as_me:$LINENO: error: could not locate SQL headers" >&5
31906 echo "$as_me: error: could not locate SQL headers" >&2;}
31907    { (exit 1); exit 1; }; }
31908
31909 fi
31910
31911 done
31912
31913
31914         sql_LIBS="$LIBS"
31915         LIBS="$LTHREAD_LIBS"
31916
31917         if test $ol_with_odbc = auto ; then
31918                 ol_with_odbc="iodbc unixodbc"
31919         fi
31920
31921         for odbc in $ol_with_odbc ; do
31922                 if test $ol_link_sql = no ; then
31923                         case $odbc in
31924                         iodbc)
31925                                 echo "$as_me:$LINENO: checking for SQLDriverConnect in -liodbc" >&5
31926 echo $ECHO_N "checking for SQLDriverConnect in -liodbc... $ECHO_C" >&6
31927 if test "${ac_cv_lib_iodbc_SQLDriverConnect+set}" = set; then
31928   echo $ECHO_N "(cached) $ECHO_C" >&6
31929 else
31930   ac_check_lib_save_LIBS=$LIBS
31931 LIBS="-liodbc  $LIBS"
31932 cat >conftest.$ac_ext <<_ACEOF
31933 /* confdefs.h.  */
31934 _ACEOF
31935 cat confdefs.h >>conftest.$ac_ext
31936 cat >>conftest.$ac_ext <<_ACEOF
31937 /* end confdefs.h.  */
31938
31939 /* Override any gcc2 internal prototype to avoid an error.  */
31940 #ifdef __cplusplus
31941 extern "C"
31942 #endif
31943 /* We use char because int might match the return type of a gcc2
31944    builtin and then its argument prototype would still apply.  */
31945 char SQLDriverConnect ();
31946 int
31947 main ()
31948 {
31949 SQLDriverConnect ();
31950   ;
31951   return 0;
31952 }
31953 _ACEOF
31954 rm -f conftest.$ac_objext conftest$ac_exeext
31955 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31956   (eval $ac_link) 2>conftest.er1
31957   ac_status=$?
31958   grep -v '^ *+' conftest.er1 >conftest.err
31959   rm -f conftest.er1
31960   cat conftest.err >&5
31961   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31962   (exit $ac_status); } &&
31963          { ac_try='test -z "$ac_c_werror_flag"
31964                          || test ! -s conftest.err'
31965   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31966   (eval $ac_try) 2>&5
31967   ac_status=$?
31968   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31969   (exit $ac_status); }; } &&
31970          { ac_try='test -s conftest$ac_exeext'
31971   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31972   (eval $ac_try) 2>&5
31973   ac_status=$?
31974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31975   (exit $ac_status); }; }; then
31976   ac_cv_lib_iodbc_SQLDriverConnect=yes
31977 else
31978   echo "$as_me: failed program was:" >&5
31979 sed 's/^/| /' conftest.$ac_ext >&5
31980
31981 ac_cv_lib_iodbc_SQLDriverConnect=no
31982 fi
31983 rm -f conftest.err conftest.$ac_objext \
31984       conftest$ac_exeext conftest.$ac_ext
31985 LIBS=$ac_check_lib_save_LIBS
31986 fi
31987 echo "$as_me:$LINENO: result: $ac_cv_lib_iodbc_SQLDriverConnect" >&5
31988 echo "${ECHO_T}$ac_cv_lib_iodbc_SQLDriverConnect" >&6
31989 if test $ac_cv_lib_iodbc_SQLDriverConnect = yes; then
31990   have_iodbc=yes
31991 else
31992   have_iodbc=no
31993 fi
31994
31995                                 if test $have_iodbc = yes ; then
31996                                         ol_link_sql="-liodbc"
31997                                 fi
31998                                 ;;
31999
32000                         unixodbc)
32001                                 echo "$as_me:$LINENO: checking for SQLDriverConnect in -lodbc" >&5
32002 echo $ECHO_N "checking for SQLDriverConnect in -lodbc... $ECHO_C" >&6
32003 if test "${ac_cv_lib_odbc_SQLDriverConnect+set}" = set; then
32004   echo $ECHO_N "(cached) $ECHO_C" >&6
32005 else
32006   ac_check_lib_save_LIBS=$LIBS
32007 LIBS="-lodbc  $LIBS"
32008 cat >conftest.$ac_ext <<_ACEOF
32009 /* confdefs.h.  */
32010 _ACEOF
32011 cat confdefs.h >>conftest.$ac_ext
32012 cat >>conftest.$ac_ext <<_ACEOF
32013 /* end confdefs.h.  */
32014
32015 /* Override any gcc2 internal prototype to avoid an error.  */
32016 #ifdef __cplusplus
32017 extern "C"
32018 #endif
32019 /* We use char because int might match the return type of a gcc2
32020    builtin and then its argument prototype would still apply.  */
32021 char SQLDriverConnect ();
32022 int
32023 main ()
32024 {
32025 SQLDriverConnect ();
32026   ;
32027   return 0;
32028 }
32029 _ACEOF
32030 rm -f conftest.$ac_objext conftest$ac_exeext
32031 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32032   (eval $ac_link) 2>conftest.er1
32033   ac_status=$?
32034   grep -v '^ *+' conftest.er1 >conftest.err
32035   rm -f conftest.er1
32036   cat conftest.err >&5
32037   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32038   (exit $ac_status); } &&
32039          { ac_try='test -z "$ac_c_werror_flag"
32040                          || test ! -s conftest.err'
32041   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32042   (eval $ac_try) 2>&5
32043   ac_status=$?
32044   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32045   (exit $ac_status); }; } &&
32046          { ac_try='test -s conftest$ac_exeext'
32047   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32048   (eval $ac_try) 2>&5
32049   ac_status=$?
32050   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32051   (exit $ac_status); }; }; then
32052   ac_cv_lib_odbc_SQLDriverConnect=yes
32053 else
32054   echo "$as_me: failed program was:" >&5
32055 sed 's/^/| /' conftest.$ac_ext >&5
32056
32057 ac_cv_lib_odbc_SQLDriverConnect=no
32058 fi
32059 rm -f conftest.err conftest.$ac_objext \
32060       conftest$ac_exeext conftest.$ac_ext
32061 LIBS=$ac_check_lib_save_LIBS
32062 fi
32063 echo "$as_me:$LINENO: result: $ac_cv_lib_odbc_SQLDriverConnect" >&5
32064 echo "${ECHO_T}$ac_cv_lib_odbc_SQLDriverConnect" >&6
32065 if test $ac_cv_lib_odbc_SQLDriverConnect = yes; then
32066   have_odbc=yes
32067 else
32068   have_odbc=no
32069 fi
32070
32071                                 if test $have_odbc = yes ; then
32072                                         ol_link_sql="-lodbc"
32073                                 fi
32074                                 ;;
32075
32076                         *)
32077                                 { { echo "$as_me:$LINENO: error: unknown ODBC library" >&5
32078 echo "$as_me: error: unknown ODBC library" >&2;}
32079    { (exit 1); exit 1; }; }
32080                                 ;;
32081                         esac
32082                 fi
32083         done
32084
32085         LIBS="$sql_LIBS"
32086
32087         if test $ol_link_sql != no ; then
32088                 SLAPD_SQL_LIBS="$ol_link_sql"
32089
32090         elif test $ol_enable_sql != auto ; then
32091                 { { echo "$as_me:$LINENO: error: could not locate suitable ODBC library" >&5
32092 echo "$as_me: error: could not locate suitable ODBC library" >&2;}
32093    { (exit 1); exit 1; }; }
32094         fi
32095 fi
32096
32097 ol_icu=no
32098
32099 for ac_header in unicode/utypes.h
32100 do
32101 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
32102 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32103   echo "$as_me:$LINENO: checking for $ac_header" >&5
32104 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32105 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32106   echo $ECHO_N "(cached) $ECHO_C" >&6
32107 fi
32108 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32109 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32110 else
32111   # Is the header compilable?
32112 echo "$as_me:$LINENO: checking $ac_header usability" >&5
32113 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
32114 cat >conftest.$ac_ext <<_ACEOF
32115 /* confdefs.h.  */
32116 _ACEOF
32117 cat confdefs.h >>conftest.$ac_ext
32118 cat >>conftest.$ac_ext <<_ACEOF
32119 /* end confdefs.h.  */
32120 $ac_includes_default
32121 #include <$ac_header>
32122 _ACEOF
32123 rm -f conftest.$ac_objext
32124 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32125   (eval $ac_compile) 2>conftest.er1
32126   ac_status=$?
32127   grep -v '^ *+' conftest.er1 >conftest.err
32128   rm -f conftest.er1
32129   cat conftest.err >&5
32130   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32131   (exit $ac_status); } &&
32132          { ac_try='test -z "$ac_c_werror_flag"
32133                          || test ! -s conftest.err'
32134   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32135   (eval $ac_try) 2>&5
32136   ac_status=$?
32137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32138   (exit $ac_status); }; } &&
32139          { ac_try='test -s conftest.$ac_objext'
32140   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32141   (eval $ac_try) 2>&5
32142   ac_status=$?
32143   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32144   (exit $ac_status); }; }; then
32145   ac_header_compiler=yes
32146 else
32147   echo "$as_me: failed program was:" >&5
32148 sed 's/^/| /' conftest.$ac_ext >&5
32149
32150 ac_header_compiler=no
32151 fi
32152 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32153 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
32154 echo "${ECHO_T}$ac_header_compiler" >&6
32155
32156 # Is the header present?
32157 echo "$as_me:$LINENO: checking $ac_header presence" >&5
32158 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
32159 cat >conftest.$ac_ext <<_ACEOF
32160 /* confdefs.h.  */
32161 _ACEOF
32162 cat confdefs.h >>conftest.$ac_ext
32163 cat >>conftest.$ac_ext <<_ACEOF
32164 /* end confdefs.h.  */
32165 #include <$ac_header>
32166 _ACEOF
32167 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
32168   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
32169   ac_status=$?
32170   grep -v '^ *+' conftest.er1 >conftest.err
32171   rm -f conftest.er1
32172   cat conftest.err >&5
32173   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32174   (exit $ac_status); } >/dev/null; then
32175   if test -s conftest.err; then
32176     ac_cpp_err=$ac_c_preproc_warn_flag
32177     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
32178   else
32179     ac_cpp_err=
32180   fi
32181 else
32182   ac_cpp_err=yes
32183 fi
32184 if test -z "$ac_cpp_err"; then
32185   ac_header_preproc=yes
32186 else
32187   echo "$as_me: failed program was:" >&5
32188 sed 's/^/| /' conftest.$ac_ext >&5
32189
32190   ac_header_preproc=no
32191 fi
32192 rm -f conftest.err conftest.$ac_ext
32193 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
32194 echo "${ECHO_T}$ac_header_preproc" >&6
32195
32196 # So?  What about this header?
32197 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
32198   yes:no: )
32199     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
32200 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
32201     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
32202 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
32203     ac_header_preproc=yes
32204     ;;
32205   no:yes:* )
32206     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
32207 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
32208     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
32209 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
32210     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
32211 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
32212     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
32213 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
32214     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
32215 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
32216     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
32217 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
32218     (
32219       cat <<\_ASBOX
32220 ## --------------------------------------------- ##
32221 ## Report this to <http://www.openldap.org/its/> ##
32222 ## --------------------------------------------- ##
32223 _ASBOX
32224     ) |
32225       sed "s/^/$as_me: WARNING:     /" >&2
32226     ;;
32227 esac
32228 echo "$as_me:$LINENO: checking for $ac_header" >&5
32229 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32230 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32231   echo $ECHO_N "(cached) $ECHO_C" >&6
32232 else
32233   eval "$as_ac_Header=\$ac_header_preproc"
32234 fi
32235 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32236 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32237
32238 fi
32239 if test `eval echo '${'$as_ac_Header'}'` = yes; then
32240   cat >>confdefs.h <<_ACEOF
32241 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
32242 _ACEOF
32243
32244 fi
32245
32246 done
32247
32248 if test $ac_cv_header_unicode_utypes_h = yes ; then
32249                 OL_ICULIBS="-licuuc -licudata"
32250
32251         echo "$as_me:$LINENO: checking for ICU libraries" >&5
32252 echo $ECHO_N "checking for ICU libraries... $ECHO_C" >&6
32253 if test "${ol_cv_lib_icu+set}" = set; then
32254   echo $ECHO_N "(cached) $ECHO_C" >&6
32255 else
32256
32257                 ol_LIBS="$LIBS"
32258                 LIBS="$OL_ICULIBS $LIBS"
32259                 cat >conftest.$ac_ext <<_ACEOF
32260 /* confdefs.h.  */
32261 _ACEOF
32262 cat confdefs.h >>conftest.$ac_ext
32263 cat >>conftest.$ac_ext <<_ACEOF
32264 /* end confdefs.h.  */
32265
32266 #include <unicode/utypes.h>
32267
32268 int
32269 main ()
32270 {
32271
32272 (void) u_errorName(0);
32273
32274   ;
32275   return 0;
32276 }
32277 _ACEOF
32278 rm -f conftest.$ac_objext conftest$ac_exeext
32279 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32280   (eval $ac_link) 2>conftest.er1
32281   ac_status=$?
32282   grep -v '^ *+' conftest.er1 >conftest.err
32283   rm -f conftest.er1
32284   cat conftest.err >&5
32285   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32286   (exit $ac_status); } &&
32287          { ac_try='test -z "$ac_c_werror_flag"
32288                          || test ! -s conftest.err'
32289   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32290   (eval $ac_try) 2>&5
32291   ac_status=$?
32292   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32293   (exit $ac_status); }; } &&
32294          { ac_try='test -s conftest$ac_exeext'
32295   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32296   (eval $ac_try) 2>&5
32297   ac_status=$?
32298   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32299   (exit $ac_status); }; }; then
32300   ol_cv_lib_icu=yes
32301 else
32302   echo "$as_me: failed program was:" >&5
32303 sed 's/^/| /' conftest.$ac_ext >&5
32304
32305 ol_cv_lib_icu=no
32306 fi
32307 rm -f conftest.err conftest.$ac_objext \
32308       conftest$ac_exeext conftest.$ac_ext
32309                 LIBS="$ol_LIBS"
32310
32311 fi
32312 echo "$as_me:$LINENO: result: $ol_cv_lib_icu" >&5
32313 echo "${ECHO_T}$ol_cv_lib_icu" >&6
32314
32315         if test $ol_cv_lib_icu != no ; then
32316                 ol_icu="$OL_ICULIBS"
32317
32318 cat >>confdefs.h <<\_ACEOF
32319 #define HAVE_ICU 1
32320 _ACEOF
32321
32322         fi
32323 fi
32324
32325 if test "$ol_icu" = no ; then
32326         { echo "$as_me:$LINENO: WARNING: ICU not available" >&5
32327 echo "$as_me: WARNING: ICU not available" >&2;}
32328 else
32329         ICU_LIBS="$ol_icu"
32330 fi
32331 WITH_SASL=no
32332 ol_link_sasl=no
32333 ol_link_spasswd=no
32334 if test $ol_with_cyrus_sasl != no ; then
32335
32336
32337 for ac_header in sasl/sasl.h sasl.h
32338 do
32339 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
32340 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32341   echo "$as_me:$LINENO: checking for $ac_header" >&5
32342 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32343 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32344   echo $ECHO_N "(cached) $ECHO_C" >&6
32345 fi
32346 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32347 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32348 else
32349   # Is the header compilable?
32350 echo "$as_me:$LINENO: checking $ac_header usability" >&5
32351 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
32352 cat >conftest.$ac_ext <<_ACEOF
32353 /* confdefs.h.  */
32354 _ACEOF
32355 cat confdefs.h >>conftest.$ac_ext
32356 cat >>conftest.$ac_ext <<_ACEOF
32357 /* end confdefs.h.  */
32358 $ac_includes_default
32359 #include <$ac_header>
32360 _ACEOF
32361 rm -f conftest.$ac_objext
32362 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32363   (eval $ac_compile) 2>conftest.er1
32364   ac_status=$?
32365   grep -v '^ *+' conftest.er1 >conftest.err
32366   rm -f conftest.er1
32367   cat conftest.err >&5
32368   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32369   (exit $ac_status); } &&
32370          { ac_try='test -z "$ac_c_werror_flag"
32371                          || test ! -s conftest.err'
32372   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32373   (eval $ac_try) 2>&5
32374   ac_status=$?
32375   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32376   (exit $ac_status); }; } &&
32377          { ac_try='test -s conftest.$ac_objext'
32378   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32379   (eval $ac_try) 2>&5
32380   ac_status=$?
32381   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32382   (exit $ac_status); }; }; then
32383   ac_header_compiler=yes
32384 else
32385   echo "$as_me: failed program was:" >&5
32386 sed 's/^/| /' conftest.$ac_ext >&5
32387
32388 ac_header_compiler=no
32389 fi
32390 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32391 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
32392 echo "${ECHO_T}$ac_header_compiler" >&6
32393
32394 # Is the header present?
32395 echo "$as_me:$LINENO: checking $ac_header presence" >&5
32396 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
32397 cat >conftest.$ac_ext <<_ACEOF
32398 /* confdefs.h.  */
32399 _ACEOF
32400 cat confdefs.h >>conftest.$ac_ext
32401 cat >>conftest.$ac_ext <<_ACEOF
32402 /* end confdefs.h.  */
32403 #include <$ac_header>
32404 _ACEOF
32405 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
32406   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
32407   ac_status=$?
32408   grep -v '^ *+' conftest.er1 >conftest.err
32409   rm -f conftest.er1
32410   cat conftest.err >&5
32411   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32412   (exit $ac_status); } >/dev/null; then
32413   if test -s conftest.err; then
32414     ac_cpp_err=$ac_c_preproc_warn_flag
32415     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
32416   else
32417     ac_cpp_err=
32418   fi
32419 else
32420   ac_cpp_err=yes
32421 fi
32422 if test -z "$ac_cpp_err"; then
32423   ac_header_preproc=yes
32424 else
32425   echo "$as_me: failed program was:" >&5
32426 sed 's/^/| /' conftest.$ac_ext >&5
32427
32428   ac_header_preproc=no
32429 fi
32430 rm -f conftest.err conftest.$ac_ext
32431 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
32432 echo "${ECHO_T}$ac_header_preproc" >&6
32433
32434 # So?  What about this header?
32435 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
32436   yes:no: )
32437     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
32438 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
32439     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
32440 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
32441     ac_header_preproc=yes
32442     ;;
32443   no:yes:* )
32444     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
32445 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
32446     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
32447 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
32448     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
32449 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
32450     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
32451 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
32452     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
32453 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
32454     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
32455 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
32456     (
32457       cat <<\_ASBOX
32458 ## --------------------------------------------- ##
32459 ## Report this to <http://www.openldap.org/its/> ##
32460 ## --------------------------------------------- ##
32461 _ASBOX
32462     ) |
32463       sed "s/^/$as_me: WARNING:     /" >&2
32464     ;;
32465 esac
32466 echo "$as_me:$LINENO: checking for $ac_header" >&5
32467 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32468 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32469   echo $ECHO_N "(cached) $ECHO_C" >&6
32470 else
32471   eval "$as_ac_Header=\$ac_header_preproc"
32472 fi
32473 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32474 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32475
32476 fi
32477 if test `eval echo '${'$as_ac_Header'}'` = yes; then
32478   cat >>confdefs.h <<_ACEOF
32479 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
32480 _ACEOF
32481
32482 fi
32483
32484 done
32485
32486
32487         if test $ac_cv_header_sasl_sasl_h = yes ||
32488            test $ac_cv_header_sasl_h = yes; then
32489                 echo "$as_me:$LINENO: checking for sasl_client_init in -lsasl2" >&5
32490 echo $ECHO_N "checking for sasl_client_init in -lsasl2... $ECHO_C" >&6
32491 if test "${ac_cv_lib_sasl2_sasl_client_init+set}" = set; then
32492   echo $ECHO_N "(cached) $ECHO_C" >&6
32493 else
32494   ac_check_lib_save_LIBS=$LIBS
32495 LIBS="-lsasl2  $LIBS"
32496 cat >conftest.$ac_ext <<_ACEOF
32497 /* confdefs.h.  */
32498 _ACEOF
32499 cat confdefs.h >>conftest.$ac_ext
32500 cat >>conftest.$ac_ext <<_ACEOF
32501 /* end confdefs.h.  */
32502
32503 /* Override any gcc2 internal prototype to avoid an error.  */
32504 #ifdef __cplusplus
32505 extern "C"
32506 #endif
32507 /* We use char because int might match the return type of a gcc2
32508    builtin and then its argument prototype would still apply.  */
32509 char sasl_client_init ();
32510 int
32511 main ()
32512 {
32513 sasl_client_init ();
32514   ;
32515   return 0;
32516 }
32517 _ACEOF
32518 rm -f conftest.$ac_objext conftest$ac_exeext
32519 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32520   (eval $ac_link) 2>conftest.er1
32521   ac_status=$?
32522   grep -v '^ *+' conftest.er1 >conftest.err
32523   rm -f conftest.er1
32524   cat conftest.err >&5
32525   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32526   (exit $ac_status); } &&
32527          { ac_try='test -z "$ac_c_werror_flag"
32528                          || test ! -s conftest.err'
32529   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32530   (eval $ac_try) 2>&5
32531   ac_status=$?
32532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32533   (exit $ac_status); }; } &&
32534          { ac_try='test -s conftest$ac_exeext'
32535   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32536   (eval $ac_try) 2>&5
32537   ac_status=$?
32538   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32539   (exit $ac_status); }; }; then
32540   ac_cv_lib_sasl2_sasl_client_init=yes
32541 else
32542   echo "$as_me: failed program was:" >&5
32543 sed 's/^/| /' conftest.$ac_ext >&5
32544
32545 ac_cv_lib_sasl2_sasl_client_init=no
32546 fi
32547 rm -f conftest.err conftest.$ac_objext \
32548       conftest$ac_exeext conftest.$ac_ext
32549 LIBS=$ac_check_lib_save_LIBS
32550 fi
32551 echo "$as_me:$LINENO: result: $ac_cv_lib_sasl2_sasl_client_init" >&5
32552 echo "${ECHO_T}$ac_cv_lib_sasl2_sasl_client_init" >&6
32553 if test $ac_cv_lib_sasl2_sasl_client_init = yes; then
32554   ol_link_sasl="-lsasl2"
32555 else
32556   echo "$as_me:$LINENO: checking for sasl_client_init in -lsasl" >&5
32557 echo $ECHO_N "checking for sasl_client_init in -lsasl... $ECHO_C" >&6
32558 if test "${ac_cv_lib_sasl_sasl_client_init+set}" = set; then
32559   echo $ECHO_N "(cached) $ECHO_C" >&6
32560 else
32561   ac_check_lib_save_LIBS=$LIBS
32562 LIBS="-lsasl  $LIBS"
32563 cat >conftest.$ac_ext <<_ACEOF
32564 /* confdefs.h.  */
32565 _ACEOF
32566 cat confdefs.h >>conftest.$ac_ext
32567 cat >>conftest.$ac_ext <<_ACEOF
32568 /* end confdefs.h.  */
32569
32570 /* Override any gcc2 internal prototype to avoid an error.  */
32571 #ifdef __cplusplus
32572 extern "C"
32573 #endif
32574 /* We use char because int might match the return type of a gcc2
32575    builtin and then its argument prototype would still apply.  */
32576 char sasl_client_init ();
32577 int
32578 main ()
32579 {
32580 sasl_client_init ();
32581   ;
32582   return 0;
32583 }
32584 _ACEOF
32585 rm -f conftest.$ac_objext conftest$ac_exeext
32586 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32587   (eval $ac_link) 2>conftest.er1
32588   ac_status=$?
32589   grep -v '^ *+' conftest.er1 >conftest.err
32590   rm -f conftest.er1
32591   cat conftest.err >&5
32592   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32593   (exit $ac_status); } &&
32594          { ac_try='test -z "$ac_c_werror_flag"
32595                          || test ! -s conftest.err'
32596   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32597   (eval $ac_try) 2>&5
32598   ac_status=$?
32599   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32600   (exit $ac_status); }; } &&
32601          { ac_try='test -s conftest$ac_exeext'
32602   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32603   (eval $ac_try) 2>&5
32604   ac_status=$?
32605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32606   (exit $ac_status); }; }; then
32607   ac_cv_lib_sasl_sasl_client_init=yes
32608 else
32609   echo "$as_me: failed program was:" >&5
32610 sed 's/^/| /' conftest.$ac_ext >&5
32611
32612 ac_cv_lib_sasl_sasl_client_init=no
32613 fi
32614 rm -f conftest.err conftest.$ac_objext \
32615       conftest$ac_exeext conftest.$ac_ext
32616 LIBS=$ac_check_lib_save_LIBS
32617 fi
32618 echo "$as_me:$LINENO: result: $ac_cv_lib_sasl_sasl_client_init" >&5
32619 echo "${ECHO_T}$ac_cv_lib_sasl_sasl_client_init" >&6
32620 if test $ac_cv_lib_sasl_sasl_client_init = yes; then
32621   ol_link_sasl="-lsasl"
32622 fi
32623
32624 fi
32625
32626         fi
32627
32628         if test $ol_link_sasl = no ; then
32629                 if test $ol_with_cyrus_sasl != auto ; then
32630                         { { echo "$as_me:$LINENO: error: Could not locate Cyrus SASL" >&5
32631 echo "$as_me: error: Could not locate Cyrus SASL" >&2;}
32632    { (exit 1); exit 1; }; }
32633                 else
32634                         { echo "$as_me:$LINENO: WARNING: Could not locate Cyrus SASL" >&5
32635 echo "$as_me: WARNING: Could not locate Cyrus SASL" >&2;}
32636                         { echo "$as_me:$LINENO: WARNING: SASL authentication not supported!" >&5
32637 echo "$as_me: WARNING: SASL authentication not supported!" >&2;}
32638                         if test $ol_link_tls = no ; then
32639                                 { echo "$as_me:$LINENO: WARNING: Strong authentication not supported!" >&5
32640 echo "$as_me: WARNING: Strong authentication not supported!" >&2;}
32641                         fi
32642                 fi
32643         else
32644                 echo "$as_me:$LINENO: checking Cyrus SASL library version" >&5
32645 echo $ECHO_N "checking Cyrus SASL library version... $ECHO_C" >&6
32646 if test "${ol_cv_sasl_compat+set}" = set; then
32647   echo $ECHO_N "(cached) $ECHO_C" >&6
32648 else
32649
32650         cat >conftest.$ac_ext <<_ACEOF
32651 /* confdefs.h.  */
32652 _ACEOF
32653 cat confdefs.h >>conftest.$ac_ext
32654 cat >>conftest.$ac_ext <<_ACEOF
32655 /* end confdefs.h.  */
32656
32657 #ifdef HAVE_SASL_SASL_H
32658 #include <sasl/sasl.h>
32659 #else
32660 #include <sasl.h>
32661 #endif
32662
32663 /* Require 2.1.15+ */
32664 #if SASL_VERSION_MAJOR == 2  && SASL_VERSION_MINOR > 1
32665         char *__sasl_compat = "2.2+ or better okay (we guess)";
32666 #elif SASL_VERSION_MAJOR == 2  && SASL_VERSION_MINOR == 1 \
32667         && SASL_VERSION_STEP >=15
32668         char *__sasl_compat = "2.1.15+ or better okay";
32669 #endif
32670
32671 _ACEOF
32672 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32673   $EGREP "__sasl_compat" >/dev/null 2>&1; then
32674   ol_cv_sasl_compat=yes
32675 else
32676   ol_cv_sasl_compat=no
32677 fi
32678 rm -f conftest*
32679
32680 fi
32681 echo "$as_me:$LINENO: result: $ol_cv_sasl_compat" >&5
32682 echo "${ECHO_T}$ol_cv_sasl_compat" >&6
32683
32684                 if test $ol_cv_sasl_compat = no ; then
32685                         ol_link_sasl=no
32686                         { { echo "$as_me:$LINENO: error: Cyrus SASL library located but is incompatible" >&5
32687 echo "$as_me: error: Cyrus SASL library located but is incompatible" >&2;}
32688    { (exit 1); exit 1; }; }
32689                 fi
32690
32691
32692 cat >>confdefs.h <<\_ACEOF
32693 #define HAVE_CYRUS_SASL 1
32694 _ACEOF
32695
32696                 SASL_LIBS="$ol_link_sasl"
32697                 if test $ol_enable_spasswd != no ; then
32698                         ol_link_spasswd=yes
32699                 fi
32700
32701                 ac_save_LIBS="$LIBS"
32702                 LIBS="$LIBS $ol_link_sasl"
32703                 echo "$as_me:$LINENO: checking for sasl_version" >&5
32704 echo $ECHO_N "checking for sasl_version... $ECHO_C" >&6
32705 if test "${ac_cv_func_sasl_version+set}" = set; then
32706   echo $ECHO_N "(cached) $ECHO_C" >&6
32707 else
32708   cat >conftest.$ac_ext <<_ACEOF
32709 /* confdefs.h.  */
32710 _ACEOF
32711 cat confdefs.h >>conftest.$ac_ext
32712 cat >>conftest.$ac_ext <<_ACEOF
32713 /* end confdefs.h.  */
32714 /* Define sasl_version to an innocuous variant, in case <limits.h> declares sasl_version.
32715    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
32716 #define sasl_version innocuous_sasl_version
32717
32718 /* System header to define __stub macros and hopefully few prototypes,
32719     which can conflict with char sasl_version (); below.
32720     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
32721     <limits.h> exists even on freestanding compilers.  */
32722
32723 #ifdef __STDC__
32724 # include <limits.h>
32725 #else
32726 # include <assert.h>
32727 #endif
32728
32729 #undef sasl_version
32730
32731 /* Override any gcc2 internal prototype to avoid an error.  */
32732 #ifdef __cplusplus
32733 extern "C"
32734 {
32735 #endif
32736 /* We use char because int might match the return type of a gcc2
32737    builtin and then its argument prototype would still apply.  */
32738 char sasl_version ();
32739 /* The GNU C library defines this for functions which it implements
32740     to always fail with ENOSYS.  Some functions are actually named
32741     something starting with __ and the normal name is an alias.  */
32742 #if defined (__stub_sasl_version) || defined (__stub___sasl_version)
32743 choke me
32744 #else
32745 char (*f) () = sasl_version;
32746 #endif
32747 #ifdef __cplusplus
32748 }
32749 #endif
32750
32751 int
32752 main ()
32753 {
32754 return f != sasl_version;
32755   ;
32756   return 0;
32757 }
32758 _ACEOF
32759 rm -f conftest.$ac_objext conftest$ac_exeext
32760 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32761   (eval $ac_link) 2>conftest.er1
32762   ac_status=$?
32763   grep -v '^ *+' conftest.er1 >conftest.err
32764   rm -f conftest.er1
32765   cat conftest.err >&5
32766   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32767   (exit $ac_status); } &&
32768          { ac_try='test -z "$ac_c_werror_flag"
32769                          || test ! -s conftest.err'
32770   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32771   (eval $ac_try) 2>&5
32772   ac_status=$?
32773   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32774   (exit $ac_status); }; } &&
32775          { ac_try='test -s conftest$ac_exeext'
32776   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32777   (eval $ac_try) 2>&5
32778   ac_status=$?
32779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32780   (exit $ac_status); }; }; then
32781   ac_cv_func_sasl_version=yes
32782 else
32783   echo "$as_me: failed program was:" >&5
32784 sed 's/^/| /' conftest.$ac_ext >&5
32785
32786 ac_cv_func_sasl_version=no
32787 fi
32788 rm -f conftest.err conftest.$ac_objext \
32789       conftest$ac_exeext conftest.$ac_ext
32790 fi
32791 echo "$as_me:$LINENO: result: $ac_cv_func_sasl_version" >&5
32792 echo "${ECHO_T}$ac_cv_func_sasl_version" >&6
32793 if test $ac_cv_func_sasl_version = yes; then
32794
32795 cat >>confdefs.h <<\_ACEOF
32796 #define HAVE_SASL_VERSION 1
32797 _ACEOF
32798
32799 fi
32800
32801                 LIBS="$ac_save_LIBS"
32802
32803                 WITH_SASL=yes
32804         fi
32805
32806 else
32807         { echo "$as_me:$LINENO: WARNING: SASL authentication not supported!" >&5
32808 echo "$as_me: WARNING: SASL authentication not supported!" >&2;}
32809         if test $ol_link_tls = no ; then
32810                 { echo "$as_me:$LINENO: WARNING: Strong authentication not supported!" >&5
32811 echo "$as_me: WARNING: Strong authentication not supported!" >&2;}
32812         fi
32813 fi
32814
32815 if test $cross_compiling != yes && test "$ac_cv_mingw32" != yes ; then
32816         dev=no
32817         if test -r /dev/urandom ; then
32818                 dev="/dev/urandom";
32819         elif test -r /idev/urandom ; then
32820                 dev="/idev/urandom";
32821         elif test -r /dev/srandom ; then
32822                 dev="/dev/srandom";
32823         elif test -r /dev/random ; then
32824                 dev="/dev/random";
32825         elif test -r /idev/random ; then
32826                 dev="/idev/random";
32827         fi
32828
32829         if test $dev != no ; then
32830
32831 cat >>confdefs.h <<_ACEOF
32832 #define URANDOM_DEVICE "$dev"
32833 _ACEOF
32834
32835         fi
32836 fi
32837
32838 ol_link_fetch=no
32839 if test $ol_with_fetch != no ; then
32840         ol_LIBS=$LIBS
32841 LIBS="-lfetch -lcom_err $LIBS"
32842 echo "$as_me:$LINENO: checking fetch(3) library" >&5
32843 echo $ECHO_N "checking fetch(3) library... $ECHO_C" >&6
32844 if test "${ol_cv_lib_fetch+set}" = set; then
32845   echo $ECHO_N "(cached) $ECHO_C" >&6
32846 else
32847
32848         cat >conftest.$ac_ext <<_ACEOF
32849 /* confdefs.h.  */
32850 _ACEOF
32851 cat confdefs.h >>conftest.$ac_ext
32852 cat >>conftest.$ac_ext <<_ACEOF
32853 /* end confdefs.h.  */
32854
32855 #include <sys/param.h>
32856 #include <stdio.h>
32857 #include <fetch.h>
32858 int
32859 main ()
32860 {
32861 struct url *u = fetchParseURL("file:///");
32862   ;
32863   return 0;
32864 }
32865 _ACEOF
32866 rm -f conftest.$ac_objext conftest$ac_exeext
32867 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32868   (eval $ac_link) 2>conftest.er1
32869   ac_status=$?
32870   grep -v '^ *+' conftest.er1 >conftest.err
32871   rm -f conftest.er1
32872   cat conftest.err >&5
32873   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32874   (exit $ac_status); } &&
32875          { ac_try='test -z "$ac_c_werror_flag"
32876                          || test ! -s conftest.err'
32877   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32878   (eval $ac_try) 2>&5
32879   ac_status=$?
32880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32881   (exit $ac_status); }; } &&
32882          { ac_try='test -s conftest$ac_exeext'
32883   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32884   (eval $ac_try) 2>&5
32885   ac_status=$?
32886   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32887   (exit $ac_status); }; }; then
32888   ol_cv_lib_fetch=yes
32889 else
32890   echo "$as_me: failed program was:" >&5
32891 sed 's/^/| /' conftest.$ac_ext >&5
32892
32893 ol_cv_lib_fetch=no
32894 fi
32895 rm -f conftest.err conftest.$ac_objext \
32896       conftest$ac_exeext conftest.$ac_ext
32897 fi
32898 echo "$as_me:$LINENO: result: $ol_cv_lib_fetch" >&5
32899 echo "${ECHO_T}$ol_cv_lib_fetch" >&6
32900 LIBS=$ol_LIBS
32901 if test $ol_cv_lib_fetch != no ; then
32902         ol_link_fetch="-lfetch -lcom_err"
32903
32904 cat >>confdefs.h <<\_ACEOF
32905 #define HAVE_FETCH 1
32906 _ACEOF
32907
32908 fi
32909
32910
32911         if test $ol_cv_lib_fetch != no ; then
32912                 LUTIL_LIBS="$LUTIL_LIBS $ol_link_fetch"
32913                 ol_link_fetch=freebsd
32914
32915         elif test $ol_with_fetch != auto ; then
32916                 { { echo "$as_me:$LINENO: error: no suitable API for --with-fetch=$ol_with_fetch" >&5
32917 echo "$as_me: error: no suitable API for --with-fetch=$ol_with_fetch" >&2;}
32918    { (exit 1); exit 1; }; }
32919         fi
32920 fi
32921
32922 if test $ol_enable_crypt != no ; then
32923         save_LIBS="$LIBS"
32924         LIBS="$TLS_LIBS $LIBS"
32925
32926         echo "$as_me:$LINENO: checking for crypt" >&5
32927 echo $ECHO_N "checking for crypt... $ECHO_C" >&6
32928 if test "${ac_cv_func_crypt+set}" = set; then
32929   echo $ECHO_N "(cached) $ECHO_C" >&6
32930 else
32931   cat >conftest.$ac_ext <<_ACEOF
32932 /* confdefs.h.  */
32933 _ACEOF
32934 cat confdefs.h >>conftest.$ac_ext
32935 cat >>conftest.$ac_ext <<_ACEOF
32936 /* end confdefs.h.  */
32937 /* Define crypt to an innocuous variant, in case <limits.h> declares crypt.
32938    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
32939 #define crypt innocuous_crypt
32940
32941 /* System header to define __stub macros and hopefully few prototypes,
32942     which can conflict with char crypt (); below.
32943     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
32944     <limits.h> exists even on freestanding compilers.  */
32945
32946 #ifdef __STDC__
32947 # include <limits.h>
32948 #else
32949 # include <assert.h>
32950 #endif
32951
32952 #undef crypt
32953
32954 /* Override any gcc2 internal prototype to avoid an error.  */
32955 #ifdef __cplusplus
32956 extern "C"
32957 {
32958 #endif
32959 /* We use char because int might match the return type of a gcc2
32960    builtin and then its argument prototype would still apply.  */
32961 char crypt ();
32962 /* The GNU C library defines this for functions which it implements
32963     to always fail with ENOSYS.  Some functions are actually named
32964     something starting with __ and the normal name is an alias.  */
32965 #if defined (__stub_crypt) || defined (__stub___crypt)
32966 choke me
32967 #else
32968 char (*f) () = crypt;
32969 #endif
32970 #ifdef __cplusplus
32971 }
32972 #endif
32973
32974 int
32975 main ()
32976 {
32977 return f != crypt;
32978   ;
32979   return 0;
32980 }
32981 _ACEOF
32982 rm -f conftest.$ac_objext conftest$ac_exeext
32983 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32984   (eval $ac_link) 2>conftest.er1
32985   ac_status=$?
32986   grep -v '^ *+' conftest.er1 >conftest.err
32987   rm -f conftest.er1
32988   cat conftest.err >&5
32989   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32990   (exit $ac_status); } &&
32991          { ac_try='test -z "$ac_c_werror_flag"
32992                          || test ! -s conftest.err'
32993   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32994   (eval $ac_try) 2>&5
32995   ac_status=$?
32996   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32997   (exit $ac_status); }; } &&
32998          { ac_try='test -s conftest$ac_exeext'
32999   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33000   (eval $ac_try) 2>&5
33001   ac_status=$?
33002   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33003   (exit $ac_status); }; }; then
33004   ac_cv_func_crypt=yes
33005 else
33006   echo "$as_me: failed program was:" >&5
33007 sed 's/^/| /' conftest.$ac_ext >&5
33008
33009 ac_cv_func_crypt=no
33010 fi
33011 rm -f conftest.err conftest.$ac_objext \
33012       conftest$ac_exeext conftest.$ac_ext
33013 fi
33014 echo "$as_me:$LINENO: result: $ac_cv_func_crypt" >&5
33015 echo "${ECHO_T}$ac_cv_func_crypt" >&6
33016 if test $ac_cv_func_crypt = yes; then
33017   have_crypt=yes
33018 else
33019
33020                 LIBS="$save_LIBS"
33021                 echo "$as_me:$LINENO: checking for crypt in -lcrypt" >&5
33022 echo $ECHO_N "checking for crypt in -lcrypt... $ECHO_C" >&6
33023 if test "${ac_cv_lib_crypt_crypt+set}" = set; then
33024   echo $ECHO_N "(cached) $ECHO_C" >&6
33025 else
33026   ac_check_lib_save_LIBS=$LIBS
33027 LIBS="-lcrypt  $LIBS"
33028 cat >conftest.$ac_ext <<_ACEOF
33029 /* confdefs.h.  */
33030 _ACEOF
33031 cat confdefs.h >>conftest.$ac_ext
33032 cat >>conftest.$ac_ext <<_ACEOF
33033 /* end confdefs.h.  */
33034
33035 /* Override any gcc2 internal prototype to avoid an error.  */
33036 #ifdef __cplusplus
33037 extern "C"
33038 #endif
33039 /* We use char because int might match the return type of a gcc2
33040    builtin and then its argument prototype would still apply.  */
33041 char crypt ();
33042 int
33043 main ()
33044 {
33045 crypt ();
33046   ;
33047   return 0;
33048 }
33049 _ACEOF
33050 rm -f conftest.$ac_objext conftest$ac_exeext
33051 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33052   (eval $ac_link) 2>conftest.er1
33053   ac_status=$?
33054   grep -v '^ *+' conftest.er1 >conftest.err
33055   rm -f conftest.er1
33056   cat conftest.err >&5
33057   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33058   (exit $ac_status); } &&
33059          { ac_try='test -z "$ac_c_werror_flag"
33060                          || test ! -s conftest.err'
33061   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33062   (eval $ac_try) 2>&5
33063   ac_status=$?
33064   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33065   (exit $ac_status); }; } &&
33066          { ac_try='test -s conftest$ac_exeext'
33067   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33068   (eval $ac_try) 2>&5
33069   ac_status=$?
33070   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33071   (exit $ac_status); }; }; then
33072   ac_cv_lib_crypt_crypt=yes
33073 else
33074   echo "$as_me: failed program was:" >&5
33075 sed 's/^/| /' conftest.$ac_ext >&5
33076
33077 ac_cv_lib_crypt_crypt=no
33078 fi
33079 rm -f conftest.err conftest.$ac_objext \
33080       conftest$ac_exeext conftest.$ac_ext
33081 LIBS=$ac_check_lib_save_LIBS
33082 fi
33083 echo "$as_me:$LINENO: result: $ac_cv_lib_crypt_crypt" >&5
33084 echo "${ECHO_T}$ac_cv_lib_crypt_crypt" >&6
33085 if test $ac_cv_lib_crypt_crypt = yes; then
33086   LUTIL_LIBS="$LUTIL_LIBS -lcrypt"
33087                         have_crypt=yes
33088 else
33089   have_crypt=no
33090 fi
33091
33092 fi
33093
33094
33095         LIBS="$save_LIBS"
33096
33097         if test $have_crypt = yes ; then
33098
33099 cat >>confdefs.h <<\_ACEOF
33100 #define HAVE_CRYPT 1
33101 _ACEOF
33102
33103         else
33104                 { echo "$as_me:$LINENO: WARNING: could not find crypt" >&5
33105 echo "$as_me: WARNING: could not find crypt" >&2;}
33106                 if test $ol_enable_crypt = yes ; then
33107                         { { echo "$as_me:$LINENO: error: could not find crypt, select appropriate options or disable" >&5
33108 echo "$as_me: error: could not find crypt, select appropriate options or disable" >&2;}
33109    { (exit 1); exit 1; }; }
33110                 fi
33111
33112                 { echo "$as_me:$LINENO: WARNING: disabling crypt support" >&5
33113 echo "$as_me: WARNING: disabling crypt support" >&2;}
33114                 ol_enable_crypt=no
33115         fi
33116 fi
33117
33118 if test $ol_enable_proctitle != no ; then
33119         echo "$as_me:$LINENO: checking for setproctitle" >&5
33120 echo $ECHO_N "checking for setproctitle... $ECHO_C" >&6
33121 if test "${ac_cv_func_setproctitle+set}" = set; then
33122   echo $ECHO_N "(cached) $ECHO_C" >&6
33123 else
33124   cat >conftest.$ac_ext <<_ACEOF
33125 /* confdefs.h.  */
33126 _ACEOF
33127 cat confdefs.h >>conftest.$ac_ext
33128 cat >>conftest.$ac_ext <<_ACEOF
33129 /* end confdefs.h.  */
33130 /* Define setproctitle to an innocuous variant, in case <limits.h> declares setproctitle.
33131    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
33132 #define setproctitle innocuous_setproctitle
33133
33134 /* System header to define __stub macros and hopefully few prototypes,
33135     which can conflict with char setproctitle (); below.
33136     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
33137     <limits.h> exists even on freestanding compilers.  */
33138
33139 #ifdef __STDC__
33140 # include <limits.h>
33141 #else
33142 # include <assert.h>
33143 #endif
33144
33145 #undef setproctitle
33146
33147 /* Override any gcc2 internal prototype to avoid an error.  */
33148 #ifdef __cplusplus
33149 extern "C"
33150 {
33151 #endif
33152 /* We use char because int might match the return type of a gcc2
33153    builtin and then its argument prototype would still apply.  */
33154 char setproctitle ();
33155 /* The GNU C library defines this for functions which it implements
33156     to always fail with ENOSYS.  Some functions are actually named
33157     something starting with __ and the normal name is an alias.  */
33158 #if defined (__stub_setproctitle) || defined (__stub___setproctitle)
33159 choke me
33160 #else
33161 char (*f) () = setproctitle;
33162 #endif
33163 #ifdef __cplusplus
33164 }
33165 #endif
33166
33167 int
33168 main ()
33169 {
33170 return f != setproctitle;
33171   ;
33172   return 0;
33173 }
33174 _ACEOF
33175 rm -f conftest.$ac_objext conftest$ac_exeext
33176 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33177   (eval $ac_link) 2>conftest.er1
33178   ac_status=$?
33179   grep -v '^ *+' conftest.er1 >conftest.err
33180   rm -f conftest.er1
33181   cat conftest.err >&5
33182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33183   (exit $ac_status); } &&
33184          { ac_try='test -z "$ac_c_werror_flag"
33185                          || test ! -s conftest.err'
33186   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33187   (eval $ac_try) 2>&5
33188   ac_status=$?
33189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33190   (exit $ac_status); }; } &&
33191          { ac_try='test -s conftest$ac_exeext'
33192   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33193   (eval $ac_try) 2>&5
33194   ac_status=$?
33195   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33196   (exit $ac_status); }; }; then
33197   ac_cv_func_setproctitle=yes
33198 else
33199   echo "$as_me: failed program was:" >&5
33200 sed 's/^/| /' conftest.$ac_ext >&5
33201
33202 ac_cv_func_setproctitle=no
33203 fi
33204 rm -f conftest.err conftest.$ac_objext \
33205       conftest$ac_exeext conftest.$ac_ext
33206 fi
33207 echo "$as_me:$LINENO: result: $ac_cv_func_setproctitle" >&5
33208 echo "${ECHO_T}$ac_cv_func_setproctitle" >&6
33209 if test $ac_cv_func_setproctitle = yes; then
33210   have_setproctitle=yes
33211 else
33212
33213                 echo "$as_me:$LINENO: checking for setproctitle in -lutil" >&5
33214 echo $ECHO_N "checking for setproctitle in -lutil... $ECHO_C" >&6
33215 if test "${ac_cv_lib_util_setproctitle+set}" = set; then
33216   echo $ECHO_N "(cached) $ECHO_C" >&6
33217 else
33218   ac_check_lib_save_LIBS=$LIBS
33219 LIBS="-lutil  $LIBS"
33220 cat >conftest.$ac_ext <<_ACEOF
33221 /* confdefs.h.  */
33222 _ACEOF
33223 cat confdefs.h >>conftest.$ac_ext
33224 cat >>conftest.$ac_ext <<_ACEOF
33225 /* end confdefs.h.  */
33226
33227 /* Override any gcc2 internal prototype to avoid an error.  */
33228 #ifdef __cplusplus
33229 extern "C"
33230 #endif
33231 /* We use char because int might match the return type of a gcc2
33232    builtin and then its argument prototype would still apply.  */
33233 char setproctitle ();
33234 int
33235 main ()
33236 {
33237 setproctitle ();
33238   ;
33239   return 0;
33240 }
33241 _ACEOF
33242 rm -f conftest.$ac_objext conftest$ac_exeext
33243 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33244   (eval $ac_link) 2>conftest.er1
33245   ac_status=$?
33246   grep -v '^ *+' conftest.er1 >conftest.err
33247   rm -f conftest.er1
33248   cat conftest.err >&5
33249   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33250   (exit $ac_status); } &&
33251          { ac_try='test -z "$ac_c_werror_flag"
33252                          || test ! -s conftest.err'
33253   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33254   (eval $ac_try) 2>&5
33255   ac_status=$?
33256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33257   (exit $ac_status); }; } &&
33258          { ac_try='test -s conftest$ac_exeext'
33259   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33260   (eval $ac_try) 2>&5
33261   ac_status=$?
33262   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33263   (exit $ac_status); }; }; then
33264   ac_cv_lib_util_setproctitle=yes
33265 else
33266   echo "$as_me: failed program was:" >&5
33267 sed 's/^/| /' conftest.$ac_ext >&5
33268
33269 ac_cv_lib_util_setproctitle=no
33270 fi
33271 rm -f conftest.err conftest.$ac_objext \
33272       conftest$ac_exeext conftest.$ac_ext
33273 LIBS=$ac_check_lib_save_LIBS
33274 fi
33275 echo "$as_me:$LINENO: result: $ac_cv_lib_util_setproctitle" >&5
33276 echo "${ECHO_T}$ac_cv_lib_util_setproctitle" >&6
33277 if test $ac_cv_lib_util_setproctitle = yes; then
33278   have_setproctitle=yes
33279                         LUTIL_LIBS="$LUTIL_LIBS -lutil"
33280 else
33281   have_setproctitle=no
33282                         case $LIBOBJS in
33283     "setproctitle.$ac_objext"   | \
33284   *" setproctitle.$ac_objext"   | \
33285     "setproctitle.$ac_objext "* | \
33286   *" setproctitle.$ac_objext "* ) ;;
33287   *) LIBOBJS="$LIBOBJS setproctitle.$ac_objext" ;;
33288 esac
33289
33290                         LIBSRCS="$LIBSRCS setproctitle.c"
33291 fi
33292
33293 fi
33294
33295
33296         if test $have_setproctitle = yes ; then
33297
33298 cat >>confdefs.h <<\_ACEOF
33299 #define HAVE_SETPROCTITLE 1
33300 _ACEOF
33301
33302         fi
33303 fi
33304
33305 if test $ol_enable_slp != no ; then
33306
33307 for ac_header in slp.h
33308 do
33309 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
33310 if eval "test \"\${$as_ac_Header+set}\" = set"; then
33311   echo "$as_me:$LINENO: checking for $ac_header" >&5
33312 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
33313 if eval "test \"\${$as_ac_Header+set}\" = set"; then
33314   echo $ECHO_N "(cached) $ECHO_C" >&6
33315 fi
33316 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
33317 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
33318 else
33319   # Is the header compilable?
33320 echo "$as_me:$LINENO: checking $ac_header usability" >&5
33321 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
33322 cat >conftest.$ac_ext <<_ACEOF
33323 /* confdefs.h.  */
33324 _ACEOF
33325 cat confdefs.h >>conftest.$ac_ext
33326 cat >>conftest.$ac_ext <<_ACEOF
33327 /* end confdefs.h.  */
33328 $ac_includes_default
33329 #include <$ac_header>
33330 _ACEOF
33331 rm -f conftest.$ac_objext
33332 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33333   (eval $ac_compile) 2>conftest.er1
33334   ac_status=$?
33335   grep -v '^ *+' conftest.er1 >conftest.err
33336   rm -f conftest.er1
33337   cat conftest.err >&5
33338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33339   (exit $ac_status); } &&
33340          { ac_try='test -z "$ac_c_werror_flag"
33341                          || test ! -s conftest.err'
33342   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33343   (eval $ac_try) 2>&5
33344   ac_status=$?
33345   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33346   (exit $ac_status); }; } &&
33347          { ac_try='test -s conftest.$ac_objext'
33348   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33349   (eval $ac_try) 2>&5
33350   ac_status=$?
33351   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33352   (exit $ac_status); }; }; then
33353   ac_header_compiler=yes
33354 else
33355   echo "$as_me: failed program was:" >&5
33356 sed 's/^/| /' conftest.$ac_ext >&5
33357
33358 ac_header_compiler=no
33359 fi
33360 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33361 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
33362 echo "${ECHO_T}$ac_header_compiler" >&6
33363
33364 # Is the header present?
33365 echo "$as_me:$LINENO: checking $ac_header presence" >&5
33366 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
33367 cat >conftest.$ac_ext <<_ACEOF
33368 /* confdefs.h.  */
33369 _ACEOF
33370 cat confdefs.h >>conftest.$ac_ext
33371 cat >>conftest.$ac_ext <<_ACEOF
33372 /* end confdefs.h.  */
33373 #include <$ac_header>
33374 _ACEOF
33375 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
33376   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
33377   ac_status=$?
33378   grep -v '^ *+' conftest.er1 >conftest.err
33379   rm -f conftest.er1
33380   cat conftest.err >&5
33381   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33382   (exit $ac_status); } >/dev/null; then
33383   if test -s conftest.err; then
33384     ac_cpp_err=$ac_c_preproc_warn_flag
33385     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
33386   else
33387     ac_cpp_err=
33388   fi
33389 else
33390   ac_cpp_err=yes
33391 fi
33392 if test -z "$ac_cpp_err"; then
33393   ac_header_preproc=yes
33394 else
33395   echo "$as_me: failed program was:" >&5
33396 sed 's/^/| /' conftest.$ac_ext >&5
33397
33398   ac_header_preproc=no
33399 fi
33400 rm -f conftest.err conftest.$ac_ext
33401 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
33402 echo "${ECHO_T}$ac_header_preproc" >&6
33403
33404 # So?  What about this header?
33405 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
33406   yes:no: )
33407     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
33408 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
33409     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
33410 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
33411     ac_header_preproc=yes
33412     ;;
33413   no:yes:* )
33414     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
33415 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
33416     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
33417 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
33418     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
33419 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
33420     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
33421 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
33422     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
33423 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
33424     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
33425 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
33426     (
33427       cat <<\_ASBOX
33428 ## --------------------------------------------- ##
33429 ## Report this to <http://www.openldap.org/its/> ##
33430 ## --------------------------------------------- ##
33431 _ASBOX
33432     ) |
33433       sed "s/^/$as_me: WARNING:     /" >&2
33434     ;;
33435 esac
33436 echo "$as_me:$LINENO: checking for $ac_header" >&5
33437 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
33438 if eval "test \"\${$as_ac_Header+set}\" = set"; then
33439   echo $ECHO_N "(cached) $ECHO_C" >&6
33440 else
33441   eval "$as_ac_Header=\$ac_header_preproc"
33442 fi
33443 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
33444 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
33445
33446 fi
33447 if test `eval echo '${'$as_ac_Header'}'` = yes; then
33448   cat >>confdefs.h <<_ACEOF
33449 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
33450 _ACEOF
33451
33452 fi
33453
33454 done
33455
33456
33457         if test $ac_cv_header_slp_h = yes ; then
33458                 echo "$as_me:$LINENO: checking for SLPOpen in -lslp" >&5
33459 echo $ECHO_N "checking for SLPOpen in -lslp... $ECHO_C" >&6
33460 if test "${ac_cv_lib_slp_SLPOpen+set}" = set; then
33461   echo $ECHO_N "(cached) $ECHO_C" >&6
33462 else
33463   ac_check_lib_save_LIBS=$LIBS
33464 LIBS="-lslp  $LIBS"
33465 cat >conftest.$ac_ext <<_ACEOF
33466 /* confdefs.h.  */
33467 _ACEOF
33468 cat confdefs.h >>conftest.$ac_ext
33469 cat >>conftest.$ac_ext <<_ACEOF
33470 /* end confdefs.h.  */
33471
33472 /* Override any gcc2 internal prototype to avoid an error.  */
33473 #ifdef __cplusplus
33474 extern "C"
33475 #endif
33476 /* We use char because int might match the return type of a gcc2
33477    builtin and then its argument prototype would still apply.  */
33478 char SLPOpen ();
33479 int
33480 main ()
33481 {
33482 SLPOpen ();
33483   ;
33484   return 0;
33485 }
33486 _ACEOF
33487 rm -f conftest.$ac_objext conftest$ac_exeext
33488 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33489   (eval $ac_link) 2>conftest.er1
33490   ac_status=$?
33491   grep -v '^ *+' conftest.er1 >conftest.err
33492   rm -f conftest.er1
33493   cat conftest.err >&5
33494   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33495   (exit $ac_status); } &&
33496          { ac_try='test -z "$ac_c_werror_flag"
33497                          || test ! -s conftest.err'
33498   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33499   (eval $ac_try) 2>&5
33500   ac_status=$?
33501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33502   (exit $ac_status); }; } &&
33503          { ac_try='test -s conftest$ac_exeext'
33504   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33505   (eval $ac_try) 2>&5
33506   ac_status=$?
33507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33508   (exit $ac_status); }; }; then
33509   ac_cv_lib_slp_SLPOpen=yes
33510 else
33511   echo "$as_me: failed program was:" >&5
33512 sed 's/^/| /' conftest.$ac_ext >&5
33513
33514 ac_cv_lib_slp_SLPOpen=no
33515 fi
33516 rm -f conftest.err conftest.$ac_objext \
33517       conftest$ac_exeext conftest.$ac_ext
33518 LIBS=$ac_check_lib_save_LIBS
33519 fi
33520 echo "$as_me:$LINENO: result: $ac_cv_lib_slp_SLPOpen" >&5
33521 echo "${ECHO_T}$ac_cv_lib_slp_SLPOpen" >&6
33522 if test $ac_cv_lib_slp_SLPOpen = yes; then
33523   have_slp=yes
33524 else
33525   have_slp=no
33526 fi
33527
33528                 if test $have_slp = yes ; then
33529
33530 cat >>confdefs.h <<\_ACEOF
33531 #define HAVE_SLP 1
33532 _ACEOF
33533
33534                         SLAPD_SLP_LIBS=-lslp
33535                 fi
33536
33537         elif test $ol_enable_slp = yes ; then
33538                 { { echo "$as_me:$LINENO: error: SLP not found" >&5
33539 echo "$as_me: error: SLP not found" >&2;}
33540    { (exit 1); exit 1; }; }
33541         fi
33542 fi
33543
33544
33545 echo "$as_me:$LINENO: checking for mode_t" >&5
33546 echo $ECHO_N "checking for mode_t... $ECHO_C" >&6
33547 if test "${ac_cv_type_mode_t+set}" = set; then
33548   echo $ECHO_N "(cached) $ECHO_C" >&6
33549 else
33550   cat >conftest.$ac_ext <<_ACEOF
33551 /* confdefs.h.  */
33552 _ACEOF
33553 cat confdefs.h >>conftest.$ac_ext
33554 cat >>conftest.$ac_ext <<_ACEOF
33555 /* end confdefs.h.  */
33556 $ac_includes_default
33557 int
33558 main ()
33559 {
33560 if ((mode_t *) 0)
33561   return 0;
33562 if (sizeof (mode_t))
33563   return 0;
33564   ;
33565   return 0;
33566 }
33567 _ACEOF
33568 rm -f conftest.$ac_objext
33569 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33570   (eval $ac_compile) 2>conftest.er1
33571   ac_status=$?
33572   grep -v '^ *+' conftest.er1 >conftest.err
33573   rm -f conftest.er1
33574   cat conftest.err >&5
33575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33576   (exit $ac_status); } &&
33577          { ac_try='test -z "$ac_c_werror_flag"
33578                          || test ! -s conftest.err'
33579   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33580   (eval $ac_try) 2>&5
33581   ac_status=$?
33582   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33583   (exit $ac_status); }; } &&
33584          { ac_try='test -s conftest.$ac_objext'
33585   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33586   (eval $ac_try) 2>&5
33587   ac_status=$?
33588   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33589   (exit $ac_status); }; }; then
33590   ac_cv_type_mode_t=yes
33591 else
33592   echo "$as_me: failed program was:" >&5
33593 sed 's/^/| /' conftest.$ac_ext >&5
33594
33595 ac_cv_type_mode_t=no
33596 fi
33597 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33598 fi
33599 echo "$as_me:$LINENO: result: $ac_cv_type_mode_t" >&5
33600 echo "${ECHO_T}$ac_cv_type_mode_t" >&6
33601 if test $ac_cv_type_mode_t = yes; then
33602   :
33603 else
33604
33605 cat >>confdefs.h <<_ACEOF
33606 #define mode_t int
33607 _ACEOF
33608
33609 fi
33610
33611 echo "$as_me:$LINENO: checking for off_t" >&5
33612 echo $ECHO_N "checking for off_t... $ECHO_C" >&6
33613 if test "${ac_cv_type_off_t+set}" = set; then
33614   echo $ECHO_N "(cached) $ECHO_C" >&6
33615 else
33616   cat >conftest.$ac_ext <<_ACEOF
33617 /* confdefs.h.  */
33618 _ACEOF
33619 cat confdefs.h >>conftest.$ac_ext
33620 cat >>conftest.$ac_ext <<_ACEOF
33621 /* end confdefs.h.  */
33622 $ac_includes_default
33623 int
33624 main ()
33625 {
33626 if ((off_t *) 0)
33627   return 0;
33628 if (sizeof (off_t))
33629   return 0;
33630   ;
33631   return 0;
33632 }
33633 _ACEOF
33634 rm -f conftest.$ac_objext
33635 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33636   (eval $ac_compile) 2>conftest.er1
33637   ac_status=$?
33638   grep -v '^ *+' conftest.er1 >conftest.err
33639   rm -f conftest.er1
33640   cat conftest.err >&5
33641   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33642   (exit $ac_status); } &&
33643          { ac_try='test -z "$ac_c_werror_flag"
33644                          || test ! -s conftest.err'
33645   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33646   (eval $ac_try) 2>&5
33647   ac_status=$?
33648   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33649   (exit $ac_status); }; } &&
33650          { ac_try='test -s conftest.$ac_objext'
33651   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33652   (eval $ac_try) 2>&5
33653   ac_status=$?
33654   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33655   (exit $ac_status); }; }; then
33656   ac_cv_type_off_t=yes
33657 else
33658   echo "$as_me: failed program was:" >&5
33659 sed 's/^/| /' conftest.$ac_ext >&5
33660
33661 ac_cv_type_off_t=no
33662 fi
33663 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33664 fi
33665 echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
33666 echo "${ECHO_T}$ac_cv_type_off_t" >&6
33667 if test $ac_cv_type_off_t = yes; then
33668   :
33669 else
33670
33671 cat >>confdefs.h <<_ACEOF
33672 #define off_t long
33673 _ACEOF
33674
33675 fi
33676
33677 echo "$as_me:$LINENO: checking for pid_t" >&5
33678 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
33679 if test "${ac_cv_type_pid_t+set}" = set; then
33680   echo $ECHO_N "(cached) $ECHO_C" >&6
33681 else
33682   cat >conftest.$ac_ext <<_ACEOF
33683 /* confdefs.h.  */
33684 _ACEOF
33685 cat confdefs.h >>conftest.$ac_ext
33686 cat >>conftest.$ac_ext <<_ACEOF
33687 /* end confdefs.h.  */
33688 $ac_includes_default
33689 int
33690 main ()
33691 {
33692 if ((pid_t *) 0)
33693   return 0;
33694 if (sizeof (pid_t))
33695   return 0;
33696   ;
33697   return 0;
33698 }
33699 _ACEOF
33700 rm -f conftest.$ac_objext
33701 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33702   (eval $ac_compile) 2>conftest.er1
33703   ac_status=$?
33704   grep -v '^ *+' conftest.er1 >conftest.err
33705   rm -f conftest.er1
33706   cat conftest.err >&5
33707   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33708   (exit $ac_status); } &&
33709          { ac_try='test -z "$ac_c_werror_flag"
33710                          || test ! -s conftest.err'
33711   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33712   (eval $ac_try) 2>&5
33713   ac_status=$?
33714   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33715   (exit $ac_status); }; } &&
33716          { ac_try='test -s conftest.$ac_objext'
33717   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33718   (eval $ac_try) 2>&5
33719   ac_status=$?
33720   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33721   (exit $ac_status); }; }; then
33722   ac_cv_type_pid_t=yes
33723 else
33724   echo "$as_me: failed program was:" >&5
33725 sed 's/^/| /' conftest.$ac_ext >&5
33726
33727 ac_cv_type_pid_t=no
33728 fi
33729 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33730 fi
33731 echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
33732 echo "${ECHO_T}$ac_cv_type_pid_t" >&6
33733 if test $ac_cv_type_pid_t = yes; then
33734   :
33735 else
33736
33737 cat >>confdefs.h <<_ACEOF
33738 #define pid_t int
33739 _ACEOF
33740
33741 fi
33742
33743 echo "$as_me:$LINENO: checking for ssize_t" >&5
33744 echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6
33745 if test "${ac_cv_type_ssize_t+set}" = set; then
33746   echo $ECHO_N "(cached) $ECHO_C" >&6
33747 else
33748   cat >conftest.$ac_ext <<_ACEOF
33749 /* confdefs.h.  */
33750 _ACEOF
33751 cat confdefs.h >>conftest.$ac_ext
33752 cat >>conftest.$ac_ext <<_ACEOF
33753 /* end confdefs.h.  */
33754 $ac_includes_default
33755 int
33756 main ()
33757 {
33758 if ((ssize_t *) 0)
33759   return 0;
33760 if (sizeof (ssize_t))
33761   return 0;
33762   ;
33763   return 0;
33764 }
33765 _ACEOF
33766 rm -f conftest.$ac_objext
33767 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33768   (eval $ac_compile) 2>conftest.er1
33769   ac_status=$?
33770   grep -v '^ *+' conftest.er1 >conftest.err
33771   rm -f conftest.er1
33772   cat conftest.err >&5
33773   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33774   (exit $ac_status); } &&
33775          { ac_try='test -z "$ac_c_werror_flag"
33776                          || test ! -s conftest.err'
33777   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33778   (eval $ac_try) 2>&5
33779   ac_status=$?
33780   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33781   (exit $ac_status); }; } &&
33782          { ac_try='test -s conftest.$ac_objext'
33783   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33784   (eval $ac_try) 2>&5
33785   ac_status=$?
33786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33787   (exit $ac_status); }; }; then
33788   ac_cv_type_ssize_t=yes
33789 else
33790   echo "$as_me: failed program was:" >&5
33791 sed 's/^/| /' conftest.$ac_ext >&5
33792
33793 ac_cv_type_ssize_t=no
33794 fi
33795 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33796 fi
33797 echo "$as_me:$LINENO: result: $ac_cv_type_ssize_t" >&5
33798 echo "${ECHO_T}$ac_cv_type_ssize_t" >&6
33799 if test $ac_cv_type_ssize_t = yes; then
33800   :
33801 else
33802
33803 cat >>confdefs.h <<_ACEOF
33804 #define ssize_t signed int
33805 _ACEOF
33806
33807 fi
33808
33809 echo "$as_me:$LINENO: checking for caddr_t" >&5
33810 echo $ECHO_N "checking for caddr_t... $ECHO_C" >&6
33811 if test "${ac_cv_type_caddr_t+set}" = set; then
33812   echo $ECHO_N "(cached) $ECHO_C" >&6
33813 else
33814   cat >conftest.$ac_ext <<_ACEOF
33815 /* confdefs.h.  */
33816 _ACEOF
33817 cat confdefs.h >>conftest.$ac_ext
33818 cat >>conftest.$ac_ext <<_ACEOF
33819 /* end confdefs.h.  */
33820 $ac_includes_default
33821 int
33822 main ()
33823 {
33824 if ((caddr_t *) 0)
33825   return 0;
33826 if (sizeof (caddr_t))
33827   return 0;
33828   ;
33829   return 0;
33830 }
33831 _ACEOF
33832 rm -f conftest.$ac_objext
33833 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33834   (eval $ac_compile) 2>conftest.er1
33835   ac_status=$?
33836   grep -v '^ *+' conftest.er1 >conftest.err
33837   rm -f conftest.er1
33838   cat conftest.err >&5
33839   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33840   (exit $ac_status); } &&
33841          { ac_try='test -z "$ac_c_werror_flag"
33842                          || test ! -s conftest.err'
33843   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33844   (eval $ac_try) 2>&5
33845   ac_status=$?
33846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33847   (exit $ac_status); }; } &&
33848          { ac_try='test -s conftest.$ac_objext'
33849   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33850   (eval $ac_try) 2>&5
33851   ac_status=$?
33852   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33853   (exit $ac_status); }; }; then
33854   ac_cv_type_caddr_t=yes
33855 else
33856   echo "$as_me: failed program was:" >&5
33857 sed 's/^/| /' conftest.$ac_ext >&5
33858
33859 ac_cv_type_caddr_t=no
33860 fi
33861 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33862 fi
33863 echo "$as_me:$LINENO: result: $ac_cv_type_caddr_t" >&5
33864 echo "${ECHO_T}$ac_cv_type_caddr_t" >&6
33865 if test $ac_cv_type_caddr_t = yes; then
33866   :
33867 else
33868
33869 cat >>confdefs.h <<_ACEOF
33870 #define caddr_t char *
33871 _ACEOF
33872
33873 fi
33874
33875 echo "$as_me:$LINENO: checking for size_t" >&5
33876 echo $ECHO_N "checking for size_t... $ECHO_C" >&6
33877 if test "${ac_cv_type_size_t+set}" = set; then
33878   echo $ECHO_N "(cached) $ECHO_C" >&6
33879 else
33880   cat >conftest.$ac_ext <<_ACEOF
33881 /* confdefs.h.  */
33882 _ACEOF
33883 cat confdefs.h >>conftest.$ac_ext
33884 cat >>conftest.$ac_ext <<_ACEOF
33885 /* end confdefs.h.  */
33886 $ac_includes_default
33887 int
33888 main ()
33889 {
33890 if ((size_t *) 0)
33891   return 0;
33892 if (sizeof (size_t))
33893   return 0;
33894   ;
33895   return 0;
33896 }
33897 _ACEOF
33898 rm -f conftest.$ac_objext
33899 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33900   (eval $ac_compile) 2>conftest.er1
33901   ac_status=$?
33902   grep -v '^ *+' conftest.er1 >conftest.err
33903   rm -f conftest.er1
33904   cat conftest.err >&5
33905   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33906   (exit $ac_status); } &&
33907          { ac_try='test -z "$ac_c_werror_flag"
33908                          || test ! -s conftest.err'
33909   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33910   (eval $ac_try) 2>&5
33911   ac_status=$?
33912   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33913   (exit $ac_status); }; } &&
33914          { ac_try='test -s conftest.$ac_objext'
33915   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33916   (eval $ac_try) 2>&5
33917   ac_status=$?
33918   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33919   (exit $ac_status); }; }; then
33920   ac_cv_type_size_t=yes
33921 else
33922   echo "$as_me: failed program was:" >&5
33923 sed 's/^/| /' conftest.$ac_ext >&5
33924
33925 ac_cv_type_size_t=no
33926 fi
33927 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33928 fi
33929 echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
33930 echo "${ECHO_T}$ac_cv_type_size_t" >&6
33931 if test $ac_cv_type_size_t = yes; then
33932   :
33933 else
33934
33935 cat >>confdefs.h <<_ACEOF
33936 #define size_t unsigned
33937 _ACEOF
33938
33939 fi
33940
33941
33942 echo "$as_me:$LINENO: checking for long long" >&5
33943 echo $ECHO_N "checking for long long... $ECHO_C" >&6
33944 if test "${ac_cv_type_long_long+set}" = set; then
33945   echo $ECHO_N "(cached) $ECHO_C" >&6
33946 else
33947   cat >conftest.$ac_ext <<_ACEOF
33948 /* confdefs.h.  */
33949 _ACEOF
33950 cat confdefs.h >>conftest.$ac_ext
33951 cat >>conftest.$ac_ext <<_ACEOF
33952 /* end confdefs.h.  */
33953 $ac_includes_default
33954 int
33955 main ()
33956 {
33957 if ((long long *) 0)
33958   return 0;
33959 if (sizeof (long long))
33960   return 0;
33961   ;
33962   return 0;
33963 }
33964 _ACEOF
33965 rm -f conftest.$ac_objext
33966 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33967   (eval $ac_compile) 2>conftest.er1
33968   ac_status=$?
33969   grep -v '^ *+' conftest.er1 >conftest.err
33970   rm -f conftest.er1
33971   cat conftest.err >&5
33972   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33973   (exit $ac_status); } &&
33974          { ac_try='test -z "$ac_c_werror_flag"
33975                          || test ! -s conftest.err'
33976   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33977   (eval $ac_try) 2>&5
33978   ac_status=$?
33979   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33980   (exit $ac_status); }; } &&
33981          { ac_try='test -s conftest.$ac_objext'
33982   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33983   (eval $ac_try) 2>&5
33984   ac_status=$?
33985   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33986   (exit $ac_status); }; }; then
33987   ac_cv_type_long_long=yes
33988 else
33989   echo "$as_me: failed program was:" >&5
33990 sed 's/^/| /' conftest.$ac_ext >&5
33991
33992 ac_cv_type_long_long=no
33993 fi
33994 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33995 fi
33996 echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
33997 echo "${ECHO_T}$ac_cv_type_long_long" >&6
33998 if test $ac_cv_type_long_long = yes; then
33999
34000 cat >>confdefs.h <<_ACEOF
34001 #define HAVE_LONG_LONG 1
34002 _ACEOF
34003
34004
34005 fi
34006
34007 echo "$as_me:$LINENO: checking for ptrdiff_t" >&5
34008 echo $ECHO_N "checking for ptrdiff_t... $ECHO_C" >&6
34009 if test "${ac_cv_type_ptrdiff_t+set}" = set; then
34010   echo $ECHO_N "(cached) $ECHO_C" >&6
34011 else
34012   cat >conftest.$ac_ext <<_ACEOF
34013 /* confdefs.h.  */
34014 _ACEOF
34015 cat confdefs.h >>conftest.$ac_ext
34016 cat >>conftest.$ac_ext <<_ACEOF
34017 /* end confdefs.h.  */
34018 $ac_includes_default
34019 int
34020 main ()
34021 {
34022 if ((ptrdiff_t *) 0)
34023   return 0;
34024 if (sizeof (ptrdiff_t))
34025   return 0;
34026   ;
34027   return 0;
34028 }
34029 _ACEOF
34030 rm -f conftest.$ac_objext
34031 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34032   (eval $ac_compile) 2>conftest.er1
34033   ac_status=$?
34034   grep -v '^ *+' conftest.er1 >conftest.err
34035   rm -f conftest.er1
34036   cat conftest.err >&5
34037   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34038   (exit $ac_status); } &&
34039          { ac_try='test -z "$ac_c_werror_flag"
34040                          || test ! -s conftest.err'
34041   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34042   (eval $ac_try) 2>&5
34043   ac_status=$?
34044   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34045   (exit $ac_status); }; } &&
34046          { ac_try='test -s conftest.$ac_objext'
34047   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34048   (eval $ac_try) 2>&5
34049   ac_status=$?
34050   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34051   (exit $ac_status); }; }; then
34052   ac_cv_type_ptrdiff_t=yes
34053 else
34054   echo "$as_me: failed program was:" >&5
34055 sed 's/^/| /' conftest.$ac_ext >&5
34056
34057 ac_cv_type_ptrdiff_t=no
34058 fi
34059 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34060 fi
34061 echo "$as_me:$LINENO: result: $ac_cv_type_ptrdiff_t" >&5
34062 echo "${ECHO_T}$ac_cv_type_ptrdiff_t" >&6
34063 if test $ac_cv_type_ptrdiff_t = yes; then
34064
34065 cat >>confdefs.h <<_ACEOF
34066 #define HAVE_PTRDIFF_T 1
34067 _ACEOF
34068
34069
34070 fi
34071
34072
34073
34074 echo "$as_me:$LINENO: checking for socklen_t" >&5
34075 echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6
34076 if test "${ac_cv_type_socklen_t+set}" = set; then
34077   echo $ECHO_N "(cached) $ECHO_C" >&6
34078 else
34079   cat >conftest.$ac_ext <<_ACEOF
34080 /* confdefs.h.  */
34081 _ACEOF
34082 cat confdefs.h >>conftest.$ac_ext
34083 cat >>conftest.$ac_ext <<_ACEOF
34084 /* end confdefs.h.  */
34085 $ac_includes_default
34086 #ifdef HAVE_SYS_SOCKET_H
34087 #include <sys/socket.h>
34088 #endif
34089
34090 int
34091 main ()
34092 {
34093 if ((socklen_t *) 0)
34094   return 0;
34095 if (sizeof (socklen_t))
34096   return 0;
34097   ;
34098   return 0;
34099 }
34100 _ACEOF
34101 rm -f conftest.$ac_objext
34102 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34103   (eval $ac_compile) 2>conftest.er1
34104   ac_status=$?
34105   grep -v '^ *+' conftest.er1 >conftest.err
34106   rm -f conftest.er1
34107   cat conftest.err >&5
34108   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34109   (exit $ac_status); } &&
34110          { ac_try='test -z "$ac_c_werror_flag"
34111                          || test ! -s conftest.err'
34112   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34113   (eval $ac_try) 2>&5
34114   ac_status=$?
34115   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34116   (exit $ac_status); }; } &&
34117          { ac_try='test -s conftest.$ac_objext'
34118   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34119   (eval $ac_try) 2>&5
34120   ac_status=$?
34121   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34122   (exit $ac_status); }; }; then
34123   ac_cv_type_socklen_t=yes
34124 else
34125   echo "$as_me: failed program was:" >&5
34126 sed 's/^/| /' conftest.$ac_ext >&5
34127
34128 ac_cv_type_socklen_t=no
34129 fi
34130 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34131 fi
34132 echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5
34133 echo "${ECHO_T}$ac_cv_type_socklen_t" >&6
34134
34135
34136 echo "$as_me:$LINENO: checking the type of arg 3 to accept()" >&5
34137 echo $ECHO_N "checking the type of arg 3 to accept()... $ECHO_C" >&6
34138 if test "${ol_cv_type_ber_socklen_t+set}" = set; then
34139   echo $ECHO_N "(cached) $ECHO_C" >&6
34140 else
34141
34142         set socklen_t int unsigned "unsigned long" long size_t
34143         test "$ac_cv_type_socklen_t" = yes || shift
34144         ol_cv_type_ber_socklen_t=$1 guessing="guessing "
34145         for lentype in "$@" ; do for addrtype in "struct sockaddr" void ; do
34146                 cat >conftest.$ac_ext <<_ACEOF
34147 /* confdefs.h.  */
34148 _ACEOF
34149 cat confdefs.h >>conftest.$ac_ext
34150 cat >>conftest.$ac_ext <<_ACEOF
34151 /* end confdefs.h.  */
34152 $ac_includes_default
34153 #ifdef HAVE_SYS_SOCKET_H
34154 #include <sys/socket.h>
34155 #endif
34156 extern int accept(int s, $addrtype *ap, $lentype *lp);
34157
34158 int
34159 main ()
34160 {
34161
34162 accept(0, (struct sockaddr *) 0, ($lentype *) 0);
34163
34164   ;
34165   return 0;
34166 }
34167 _ACEOF
34168 rm -f conftest.$ac_objext
34169 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34170   (eval $ac_compile) 2>conftest.er1
34171   ac_status=$?
34172   grep -v '^ *+' conftest.er1 >conftest.err
34173   rm -f conftest.er1
34174   cat conftest.err >&5
34175   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34176   (exit $ac_status); } &&
34177          { ac_try='test -z "$ac_c_werror_flag"
34178                          || test ! -s conftest.err'
34179   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34180   (eval $ac_try) 2>&5
34181   ac_status=$?
34182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34183   (exit $ac_status); }; } &&
34184          { ac_try='test -s conftest.$ac_objext'
34185   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34186   (eval $ac_try) 2>&5
34187   ac_status=$?
34188   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34189   (exit $ac_status); }; }; then
34190   ol_cv_type_ber_socklen_t=$lentype guessing= ; break 2
34191 else
34192   echo "$as_me: failed program was:" >&5
34193 sed 's/^/| /' conftest.$ac_ext >&5
34194
34195 fi
34196 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34197         done ; done
34198 fi
34199
34200 echo "$as_me:$LINENO: result: $guessing$ol_cv_type_ber_socklen_t *" >&5
34201 echo "${ECHO_T}$guessing$ol_cv_type_ber_socklen_t *" >&6
34202
34203 cat >>confdefs.h <<_ACEOF
34204 #define ber_socklen_t $ol_cv_type_ber_socklen_t
34205 _ACEOF
34206
34207
34208 if test "$ac_cv_type_socklen_t" != yes; then
34209
34210 cat >>confdefs.h <<_ACEOF
34211 #define socklen_t $ol_cv_type_ber_socklen_t
34212 _ACEOF
34213
34214 fi
34215
34216
34217 echo "$as_me:$LINENO: checking return type of signal handlers" >&5
34218 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
34219 if test "${ac_cv_type_signal+set}" = set; then
34220   echo $ECHO_N "(cached) $ECHO_C" >&6
34221 else
34222   cat >conftest.$ac_ext <<_ACEOF
34223 /* confdefs.h.  */
34224 _ACEOF
34225 cat confdefs.h >>conftest.$ac_ext
34226 cat >>conftest.$ac_ext <<_ACEOF
34227 /* end confdefs.h.  */
34228 #include <sys/types.h>
34229 #include <signal.h>
34230 #ifdef signal
34231 # undef signal
34232 #endif
34233 #ifdef __cplusplus
34234 extern "C" void (*signal (int, void (*)(int)))(int);
34235 #else
34236 void (*signal ()) ();
34237 #endif
34238
34239 int
34240 main ()
34241 {
34242 int i;
34243   ;
34244   return 0;
34245 }
34246 _ACEOF
34247 rm -f conftest.$ac_objext
34248 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34249   (eval $ac_compile) 2>conftest.er1
34250   ac_status=$?
34251   grep -v '^ *+' conftest.er1 >conftest.err
34252   rm -f conftest.er1
34253   cat conftest.err >&5
34254   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34255   (exit $ac_status); } &&
34256          { ac_try='test -z "$ac_c_werror_flag"
34257                          || test ! -s conftest.err'
34258   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34259   (eval $ac_try) 2>&5
34260   ac_status=$?
34261   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34262   (exit $ac_status); }; } &&
34263          { ac_try='test -s conftest.$ac_objext'
34264   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34265   (eval $ac_try) 2>&5
34266   ac_status=$?
34267   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34268   (exit $ac_status); }; }; then
34269   ac_cv_type_signal=void
34270 else
34271   echo "$as_me: failed program was:" >&5
34272 sed 's/^/| /' conftest.$ac_ext >&5
34273
34274 ac_cv_type_signal=int
34275 fi
34276 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34277 fi
34278 echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
34279 echo "${ECHO_T}$ac_cv_type_signal" >&6
34280
34281 cat >>confdefs.h <<_ACEOF
34282 #define RETSIGTYPE $ac_cv_type_signal
34283 _ACEOF
34284
34285
34286
34287 echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
34288 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6
34289 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
34290   echo $ECHO_N "(cached) $ECHO_C" >&6
34291 else
34292   cat >conftest.$ac_ext <<_ACEOF
34293 /* confdefs.h.  */
34294 _ACEOF
34295 cat confdefs.h >>conftest.$ac_ext
34296 cat >>conftest.$ac_ext <<_ACEOF
34297 /* end confdefs.h.  */
34298 $ac_includes_default
34299 #include <signal.h>
34300
34301
34302 int
34303 main ()
34304 {
34305 if ((sig_atomic_t *) 0)
34306   return 0;
34307 if (sizeof (sig_atomic_t))
34308   return 0;
34309   ;
34310   return 0;
34311 }
34312 _ACEOF
34313 rm -f conftest.$ac_objext
34314 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34315   (eval $ac_compile) 2>conftest.er1
34316   ac_status=$?
34317   grep -v '^ *+' conftest.er1 >conftest.err
34318   rm -f conftest.er1
34319   cat conftest.err >&5
34320   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34321   (exit $ac_status); } &&
34322          { ac_try='test -z "$ac_c_werror_flag"
34323                          || test ! -s conftest.err'
34324   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34325   (eval $ac_try) 2>&5
34326   ac_status=$?
34327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34328   (exit $ac_status); }; } &&
34329          { ac_try='test -s conftest.$ac_objext'
34330   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34331   (eval $ac_try) 2>&5
34332   ac_status=$?
34333   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34334   (exit $ac_status); }; }; then
34335   ac_cv_type_sig_atomic_t=yes
34336 else
34337   echo "$as_me: failed program was:" >&5
34338 sed 's/^/| /' conftest.$ac_ext >&5
34339
34340 ac_cv_type_sig_atomic_t=no
34341 fi
34342 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34343 fi
34344 echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
34345 echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6
34346 if test $ac_cv_type_sig_atomic_t = yes; then
34347   :
34348 else
34349
34350 cat >>confdefs.h <<_ACEOF
34351 #define sig_atomic_t int
34352 _ACEOF
34353
34354 fi
34355
34356
34357 echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5
34358 echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6
34359 if test "${ac_cv_type_uid_t+set}" = set; then
34360   echo $ECHO_N "(cached) $ECHO_C" >&6
34361 else
34362   cat >conftest.$ac_ext <<_ACEOF
34363 /* confdefs.h.  */
34364 _ACEOF
34365 cat confdefs.h >>conftest.$ac_ext
34366 cat >>conftest.$ac_ext <<_ACEOF
34367 /* end confdefs.h.  */
34368 #include <sys/types.h>
34369
34370 _ACEOF
34371 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34372   $EGREP "uid_t" >/dev/null 2>&1; then
34373   ac_cv_type_uid_t=yes
34374 else
34375   ac_cv_type_uid_t=no
34376 fi
34377 rm -f conftest*
34378
34379 fi
34380 echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5
34381 echo "${ECHO_T}$ac_cv_type_uid_t" >&6
34382 if test $ac_cv_type_uid_t = no; then
34383
34384 cat >>confdefs.h <<\_ACEOF
34385 #define uid_t int
34386 _ACEOF
34387
34388
34389 cat >>confdefs.h <<\_ACEOF
34390 #define gid_t int
34391 _ACEOF
34392
34393 fi
34394
34395
34396 echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
34397 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
34398 if test "${ac_cv_header_time+set}" = set; then
34399   echo $ECHO_N "(cached) $ECHO_C" >&6
34400 else
34401   cat >conftest.$ac_ext <<_ACEOF
34402 /* confdefs.h.  */
34403 _ACEOF
34404 cat confdefs.h >>conftest.$ac_ext
34405 cat >>conftest.$ac_ext <<_ACEOF
34406 /* end confdefs.h.  */
34407 #include <sys/types.h>
34408 #include <sys/time.h>
34409 #include <time.h>
34410
34411 int
34412 main ()
34413 {
34414 if ((struct tm *) 0)
34415 return 0;
34416   ;
34417   return 0;
34418 }
34419 _ACEOF
34420 rm -f conftest.$ac_objext
34421 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34422   (eval $ac_compile) 2>conftest.er1
34423   ac_status=$?
34424   grep -v '^ *+' conftest.er1 >conftest.err
34425   rm -f conftest.er1
34426   cat conftest.err >&5
34427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34428   (exit $ac_status); } &&
34429          { ac_try='test -z "$ac_c_werror_flag"
34430                          || test ! -s conftest.err'
34431   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34432   (eval $ac_try) 2>&5
34433   ac_status=$?
34434   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34435   (exit $ac_status); }; } &&
34436          { ac_try='test -s conftest.$ac_objext'
34437   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34438   (eval $ac_try) 2>&5
34439   ac_status=$?
34440   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34441   (exit $ac_status); }; }; then
34442   ac_cv_header_time=yes
34443 else
34444   echo "$as_me: failed program was:" >&5
34445 sed 's/^/| /' conftest.$ac_ext >&5
34446
34447 ac_cv_header_time=no
34448 fi
34449 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34450 fi
34451 echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
34452 echo "${ECHO_T}$ac_cv_header_time" >&6
34453 if test $ac_cv_header_time = yes; then
34454
34455 cat >>confdefs.h <<\_ACEOF
34456 #define TIME_WITH_SYS_TIME 1
34457 _ACEOF
34458
34459 fi
34460
34461 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
34462 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
34463 if test "${ac_cv_struct_tm+set}" = set; then
34464   echo $ECHO_N "(cached) $ECHO_C" >&6
34465 else
34466   cat >conftest.$ac_ext <<_ACEOF
34467 /* confdefs.h.  */
34468 _ACEOF
34469 cat confdefs.h >>conftest.$ac_ext
34470 cat >>conftest.$ac_ext <<_ACEOF
34471 /* end confdefs.h.  */
34472 #include <sys/types.h>
34473 #include <time.h>
34474
34475 int
34476 main ()
34477 {
34478 struct tm *tp; tp->tm_sec;
34479   ;
34480   return 0;
34481 }
34482 _ACEOF
34483 rm -f conftest.$ac_objext
34484 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34485   (eval $ac_compile) 2>conftest.er1
34486   ac_status=$?
34487   grep -v '^ *+' conftest.er1 >conftest.err
34488   rm -f conftest.er1
34489   cat conftest.err >&5
34490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34491   (exit $ac_status); } &&
34492          { ac_try='test -z "$ac_c_werror_flag"
34493                          || test ! -s conftest.err'
34494   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34495   (eval $ac_try) 2>&5
34496   ac_status=$?
34497   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34498   (exit $ac_status); }; } &&
34499          { ac_try='test -s conftest.$ac_objext'
34500   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34501   (eval $ac_try) 2>&5
34502   ac_status=$?
34503   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34504   (exit $ac_status); }; }; then
34505   ac_cv_struct_tm=time.h
34506 else
34507   echo "$as_me: failed program was:" >&5
34508 sed 's/^/| /' conftest.$ac_ext >&5
34509
34510 ac_cv_struct_tm=sys/time.h
34511 fi
34512 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34513 fi
34514 echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
34515 echo "${ECHO_T}$ac_cv_struct_tm" >&6
34516 if test $ac_cv_struct_tm = sys/time.h; then
34517
34518 cat >>confdefs.h <<\_ACEOF
34519 #define TM_IN_SYS_TIME 1
34520 _ACEOF
34521
34522 fi
34523
34524 echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
34525 echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6
34526 if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
34527   echo $ECHO_N "(cached) $ECHO_C" >&6
34528 else
34529   cat >conftest.$ac_ext <<_ACEOF
34530 /* confdefs.h.  */
34531 _ACEOF
34532 cat confdefs.h >>conftest.$ac_ext
34533 cat >>conftest.$ac_ext <<_ACEOF
34534 /* end confdefs.h.  */
34535 $ac_includes_default
34536 int
34537 main ()
34538 {
34539 static struct stat ac_aggr;
34540 if (ac_aggr.st_blksize)
34541 return 0;
34542   ;
34543   return 0;
34544 }
34545 _ACEOF
34546 rm -f conftest.$ac_objext
34547 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34548   (eval $ac_compile) 2>conftest.er1
34549   ac_status=$?
34550   grep -v '^ *+' conftest.er1 >conftest.err
34551   rm -f conftest.er1
34552   cat conftest.err >&5
34553   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34554   (exit $ac_status); } &&
34555          { ac_try='test -z "$ac_c_werror_flag"
34556                          || test ! -s conftest.err'
34557   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34558   (eval $ac_try) 2>&5
34559   ac_status=$?
34560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34561   (exit $ac_status); }; } &&
34562          { ac_try='test -s conftest.$ac_objext'
34563   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34564   (eval $ac_try) 2>&5
34565   ac_status=$?
34566   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34567   (exit $ac_status); }; }; then
34568   ac_cv_member_struct_stat_st_blksize=yes
34569 else
34570   echo "$as_me: failed program was:" >&5
34571 sed 's/^/| /' conftest.$ac_ext >&5
34572
34573 cat >conftest.$ac_ext <<_ACEOF
34574 /* confdefs.h.  */
34575 _ACEOF
34576 cat confdefs.h >>conftest.$ac_ext
34577 cat >>conftest.$ac_ext <<_ACEOF
34578 /* end confdefs.h.  */
34579 $ac_includes_default
34580 int
34581 main ()
34582 {
34583 static struct stat ac_aggr;
34584 if (sizeof ac_aggr.st_blksize)
34585 return 0;
34586   ;
34587   return 0;
34588 }
34589 _ACEOF
34590 rm -f conftest.$ac_objext
34591 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34592   (eval $ac_compile) 2>conftest.er1
34593   ac_status=$?
34594   grep -v '^ *+' conftest.er1 >conftest.err
34595   rm -f conftest.er1
34596   cat conftest.err >&5
34597   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34598   (exit $ac_status); } &&
34599          { ac_try='test -z "$ac_c_werror_flag"
34600                          || test ! -s conftest.err'
34601   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34602   (eval $ac_try) 2>&5
34603   ac_status=$?
34604   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34605   (exit $ac_status); }; } &&
34606          { ac_try='test -s conftest.$ac_objext'
34607   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34608   (eval $ac_try) 2>&5
34609   ac_status=$?
34610   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34611   (exit $ac_status); }; }; then
34612   ac_cv_member_struct_stat_st_blksize=yes
34613 else
34614   echo "$as_me: failed program was:" >&5
34615 sed 's/^/| /' conftest.$ac_ext >&5
34616
34617 ac_cv_member_struct_stat_st_blksize=no
34618 fi
34619 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34620 fi
34621 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34622 fi
34623 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
34624 echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6
34625 if test $ac_cv_member_struct_stat_st_blksize = yes; then
34626
34627 cat >>confdefs.h <<_ACEOF
34628 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
34629 _ACEOF
34630
34631
34632 fi
34633
34634 echo "$as_me:$LINENO: checking for struct passwd.pw_gecos" >&5
34635 echo $ECHO_N "checking for struct passwd.pw_gecos... $ECHO_C" >&6
34636 if test "${ac_cv_member_struct_passwd_pw_gecos+set}" = set; then
34637   echo $ECHO_N "(cached) $ECHO_C" >&6
34638 else
34639   cat >conftest.$ac_ext <<_ACEOF
34640 /* confdefs.h.  */
34641 _ACEOF
34642 cat confdefs.h >>conftest.$ac_ext
34643 cat >>conftest.$ac_ext <<_ACEOF
34644 /* end confdefs.h.  */
34645 $ac_includes_default
34646 #include <pwd.h>
34647
34648 int
34649 main ()
34650 {
34651 static struct passwd ac_aggr;
34652 if (ac_aggr.pw_gecos)
34653 return 0;
34654   ;
34655   return 0;
34656 }
34657 _ACEOF
34658 rm -f conftest.$ac_objext
34659 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34660   (eval $ac_compile) 2>conftest.er1
34661   ac_status=$?
34662   grep -v '^ *+' conftest.er1 >conftest.err
34663   rm -f conftest.er1
34664   cat conftest.err >&5
34665   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34666   (exit $ac_status); } &&
34667          { ac_try='test -z "$ac_c_werror_flag"
34668                          || test ! -s conftest.err'
34669   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34670   (eval $ac_try) 2>&5
34671   ac_status=$?
34672   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34673   (exit $ac_status); }; } &&
34674          { ac_try='test -s conftest.$ac_objext'
34675   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34676   (eval $ac_try) 2>&5
34677   ac_status=$?
34678   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34679   (exit $ac_status); }; }; then
34680   ac_cv_member_struct_passwd_pw_gecos=yes
34681 else
34682   echo "$as_me: failed program was:" >&5
34683 sed 's/^/| /' conftest.$ac_ext >&5
34684
34685 cat >conftest.$ac_ext <<_ACEOF
34686 /* confdefs.h.  */
34687 _ACEOF
34688 cat confdefs.h >>conftest.$ac_ext
34689 cat >>conftest.$ac_ext <<_ACEOF
34690 /* end confdefs.h.  */
34691 $ac_includes_default
34692 #include <pwd.h>
34693
34694 int
34695 main ()
34696 {
34697 static struct passwd ac_aggr;
34698 if (sizeof ac_aggr.pw_gecos)
34699 return 0;
34700   ;
34701   return 0;
34702 }
34703 _ACEOF
34704 rm -f conftest.$ac_objext
34705 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34706   (eval $ac_compile) 2>conftest.er1
34707   ac_status=$?
34708   grep -v '^ *+' conftest.er1 >conftest.err
34709   rm -f conftest.er1
34710   cat conftest.err >&5
34711   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34712   (exit $ac_status); } &&
34713          { ac_try='test -z "$ac_c_werror_flag"
34714                          || test ! -s conftest.err'
34715   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34716   (eval $ac_try) 2>&5
34717   ac_status=$?
34718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34719   (exit $ac_status); }; } &&
34720          { ac_try='test -s conftest.$ac_objext'
34721   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34722   (eval $ac_try) 2>&5
34723   ac_status=$?
34724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34725   (exit $ac_status); }; }; then
34726   ac_cv_member_struct_passwd_pw_gecos=yes
34727 else
34728   echo "$as_me: failed program was:" >&5
34729 sed 's/^/| /' conftest.$ac_ext >&5
34730
34731 ac_cv_member_struct_passwd_pw_gecos=no
34732 fi
34733 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34734 fi
34735 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34736 fi
34737 echo "$as_me:$LINENO: result: $ac_cv_member_struct_passwd_pw_gecos" >&5
34738 echo "${ECHO_T}$ac_cv_member_struct_passwd_pw_gecos" >&6
34739 if test $ac_cv_member_struct_passwd_pw_gecos = yes; then
34740
34741 cat >>confdefs.h <<_ACEOF
34742 #define HAVE_STRUCT_PASSWD_PW_GECOS 1
34743 _ACEOF
34744
34745
34746 fi
34747
34748 echo "$as_me:$LINENO: checking for struct passwd.pw_passwd" >&5
34749 echo $ECHO_N "checking for struct passwd.pw_passwd... $ECHO_C" >&6
34750 if test "${ac_cv_member_struct_passwd_pw_passwd+set}" = set; then
34751   echo $ECHO_N "(cached) $ECHO_C" >&6
34752 else
34753   cat >conftest.$ac_ext <<_ACEOF
34754 /* confdefs.h.  */
34755 _ACEOF
34756 cat confdefs.h >>conftest.$ac_ext
34757 cat >>conftest.$ac_ext <<_ACEOF
34758 /* end confdefs.h.  */
34759 $ac_includes_default
34760 #include <pwd.h>
34761
34762 int
34763 main ()
34764 {
34765 static struct passwd ac_aggr;
34766 if (ac_aggr.pw_passwd)
34767 return 0;
34768   ;
34769   return 0;
34770 }
34771 _ACEOF
34772 rm -f conftest.$ac_objext
34773 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34774   (eval $ac_compile) 2>conftest.er1
34775   ac_status=$?
34776   grep -v '^ *+' conftest.er1 >conftest.err
34777   rm -f conftest.er1
34778   cat conftest.err >&5
34779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34780   (exit $ac_status); } &&
34781          { ac_try='test -z "$ac_c_werror_flag"
34782                          || test ! -s conftest.err'
34783   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34784   (eval $ac_try) 2>&5
34785   ac_status=$?
34786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34787   (exit $ac_status); }; } &&
34788          { ac_try='test -s conftest.$ac_objext'
34789   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34790   (eval $ac_try) 2>&5
34791   ac_status=$?
34792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34793   (exit $ac_status); }; }; then
34794   ac_cv_member_struct_passwd_pw_passwd=yes
34795 else
34796   echo "$as_me: failed program was:" >&5
34797 sed 's/^/| /' conftest.$ac_ext >&5
34798
34799 cat >conftest.$ac_ext <<_ACEOF
34800 /* confdefs.h.  */
34801 _ACEOF
34802 cat confdefs.h >>conftest.$ac_ext
34803 cat >>conftest.$ac_ext <<_ACEOF
34804 /* end confdefs.h.  */
34805 $ac_includes_default
34806 #include <pwd.h>
34807
34808 int
34809 main ()
34810 {
34811 static struct passwd ac_aggr;
34812 if (sizeof ac_aggr.pw_passwd)
34813 return 0;
34814   ;
34815   return 0;
34816 }
34817 _ACEOF
34818 rm -f conftest.$ac_objext
34819 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34820   (eval $ac_compile) 2>conftest.er1
34821   ac_status=$?
34822   grep -v '^ *+' conftest.er1 >conftest.err
34823   rm -f conftest.er1
34824   cat conftest.err >&5
34825   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34826   (exit $ac_status); } &&
34827          { ac_try='test -z "$ac_c_werror_flag"
34828                          || test ! -s conftest.err'
34829   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34830   (eval $ac_try) 2>&5
34831   ac_status=$?
34832   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34833   (exit $ac_status); }; } &&
34834          { ac_try='test -s conftest.$ac_objext'
34835   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34836   (eval $ac_try) 2>&5
34837   ac_status=$?
34838   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34839   (exit $ac_status); }; }; then
34840   ac_cv_member_struct_passwd_pw_passwd=yes
34841 else
34842   echo "$as_me: failed program was:" >&5
34843 sed 's/^/| /' conftest.$ac_ext >&5
34844
34845 ac_cv_member_struct_passwd_pw_passwd=no
34846 fi
34847 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34848 fi
34849 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34850 fi
34851 echo "$as_me:$LINENO: result: $ac_cv_member_struct_passwd_pw_passwd" >&5
34852 echo "${ECHO_T}$ac_cv_member_struct_passwd_pw_passwd" >&6
34853 if test $ac_cv_member_struct_passwd_pw_passwd = yes; then
34854
34855 cat >>confdefs.h <<_ACEOF
34856 #define HAVE_STRUCT_PASSWD_PW_PASSWD 1
34857 _ACEOF
34858
34859
34860 fi
34861
34862
34863 echo "$as_me:$LINENO: checking if toupper() requires islower()" >&5
34864 echo $ECHO_N "checking if toupper() requires islower()... $ECHO_C" >&6
34865 if test "${ol_cv_c_upper_lower+set}" = set; then
34866   echo $ECHO_N "(cached) $ECHO_C" >&6
34867 else
34868
34869         if test "$cross_compiling" = yes; then
34870   ol_cv_c_upper_lower=safe
34871 else
34872   cat >conftest.$ac_ext <<_ACEOF
34873 /* confdefs.h.  */
34874 _ACEOF
34875 cat confdefs.h >>conftest.$ac_ext
34876 cat >>conftest.$ac_ext <<_ACEOF
34877 /* end confdefs.h.  */
34878
34879 #include <ctype.h>
34880 main()
34881 {
34882         if ('C' == toupper('C'))
34883                 exit(0);
34884         else
34885                 exit(1);
34886 }
34887 _ACEOF
34888 rm -f conftest$ac_exeext
34889 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
34890   (eval $ac_link) 2>&5
34891   ac_status=$?
34892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34893   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
34894   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34895   (eval $ac_try) 2>&5
34896   ac_status=$?
34897   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34898   (exit $ac_status); }; }; then
34899   ol_cv_c_upper_lower=no
34900 else
34901   echo "$as_me: program exited with status $ac_status" >&5
34902 echo "$as_me: failed program was:" >&5
34903 sed 's/^/| /' conftest.$ac_ext >&5
34904
34905 ( exit $ac_status )
34906 ol_cv_c_upper_lower=yes
34907 fi
34908 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
34909 fi
34910 fi
34911 echo "$as_me:$LINENO: result: $ol_cv_c_upper_lower" >&5
34912 echo "${ECHO_T}$ol_cv_c_upper_lower" >&6
34913 if test $ol_cv_c_upper_lower != no ; then
34914
34915 cat >>confdefs.h <<\_ACEOF
34916 #define C_UPPER_LOWER 1
34917 _ACEOF
34918
34919 fi
34920
34921 echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
34922 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
34923 if test "${ac_cv_c_const+set}" = set; then
34924   echo $ECHO_N "(cached) $ECHO_C" >&6
34925 else
34926   cat >conftest.$ac_ext <<_ACEOF
34927 /* confdefs.h.  */
34928 _ACEOF
34929 cat confdefs.h >>conftest.$ac_ext
34930 cat >>conftest.$ac_ext <<_ACEOF
34931 /* end confdefs.h.  */
34932
34933 int
34934 main ()
34935 {
34936 /* FIXME: Include the comments suggested by Paul. */
34937 #ifndef __cplusplus
34938   /* Ultrix mips cc rejects this.  */
34939   typedef int charset[2];
34940   const charset x;
34941   /* SunOS 4.1.1 cc rejects this.  */
34942   char const *const *ccp;
34943   char **p;
34944   /* NEC SVR4.0.2 mips cc rejects this.  */
34945   struct point {int x, y;};
34946   static struct point const zero = {0,0};
34947   /* AIX XL C 1.02.0.0 rejects this.
34948      It does not let you subtract one const X* pointer from another in
34949      an arm of an if-expression whose if-part is not a constant
34950      expression */
34951   const char *g = "string";
34952   ccp = &g + (g ? g-g : 0);
34953   /* HPUX 7.0 cc rejects these. */
34954   ++ccp;
34955   p = (char**) ccp;
34956   ccp = (char const *const *) p;
34957   { /* SCO 3.2v4 cc rejects this.  */
34958     char *t;
34959     char const *s = 0 ? (char *) 0 : (char const *) 0;
34960
34961     *t++ = 0;
34962   }
34963   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
34964     int x[] = {25, 17};
34965     const int *foo = &x[0];
34966     ++foo;
34967   }
34968   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
34969     typedef const int *iptr;
34970     iptr p = 0;
34971     ++p;
34972   }
34973   { /* AIX XL C 1.02.0.0 rejects this saying
34974        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
34975     struct s { int j; const int *ap[3]; };
34976     struct s *b; b->j = 5;
34977   }
34978   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
34979     const int foo = 10;
34980   }
34981 #endif
34982
34983   ;
34984   return 0;
34985 }
34986 _ACEOF
34987 rm -f conftest.$ac_objext
34988 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34989   (eval $ac_compile) 2>conftest.er1
34990   ac_status=$?
34991   grep -v '^ *+' conftest.er1 >conftest.err
34992   rm -f conftest.er1
34993   cat conftest.err >&5
34994   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34995   (exit $ac_status); } &&
34996          { ac_try='test -z "$ac_c_werror_flag"
34997                          || test ! -s conftest.err'
34998   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34999   (eval $ac_try) 2>&5
35000   ac_status=$?
35001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35002   (exit $ac_status); }; } &&
35003          { ac_try='test -s conftest.$ac_objext'
35004   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35005   (eval $ac_try) 2>&5
35006   ac_status=$?
35007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35008   (exit $ac_status); }; }; then
35009   ac_cv_c_const=yes
35010 else
35011   echo "$as_me: failed program was:" >&5
35012 sed 's/^/| /' conftest.$ac_ext >&5
35013
35014 ac_cv_c_const=no
35015 fi
35016 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35017 fi
35018 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
35019 echo "${ECHO_T}$ac_cv_c_const" >&6
35020 if test $ac_cv_c_const = no; then
35021
35022 cat >>confdefs.h <<\_ACEOF
35023 #define const
35024 _ACEOF
35025
35026 fi
35027
35028 echo "$as_me:$LINENO: checking if compiler understands volatile" >&5
35029 echo $ECHO_N "checking if compiler understands volatile... $ECHO_C" >&6
35030 if test "${ol_cv_c_volatile+set}" = set; then
35031   echo $ECHO_N "(cached) $ECHO_C" >&6
35032 else
35033   cat >conftest.$ac_ext <<_ACEOF
35034 /* confdefs.h.  */
35035 _ACEOF
35036 cat confdefs.h >>conftest.$ac_ext
35037 cat >>conftest.$ac_ext <<_ACEOF
35038 /* end confdefs.h.  */
35039 int x, y, z;
35040 int
35041 main ()
35042 {
35043 volatile int a; int * volatile b = x ? &y : &z;
35044       /* Older MIPS compilers (eg., in Ultrix 4.2) don't like *b = 0 */
35045       *b = 0;
35046   ;
35047   return 0;
35048 }
35049 _ACEOF
35050 rm -f conftest.$ac_objext
35051 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35052   (eval $ac_compile) 2>conftest.er1
35053   ac_status=$?
35054   grep -v '^ *+' conftest.er1 >conftest.err
35055   rm -f conftest.er1
35056   cat conftest.err >&5
35057   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35058   (exit $ac_status); } &&
35059          { ac_try='test -z "$ac_c_werror_flag"
35060                          || test ! -s conftest.err'
35061   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35062   (eval $ac_try) 2>&5
35063   ac_status=$?
35064   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35065   (exit $ac_status); }; } &&
35066          { ac_try='test -s conftest.$ac_objext'
35067   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35068   (eval $ac_try) 2>&5
35069   ac_status=$?
35070   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35071   (exit $ac_status); }; }; then
35072   ol_cv_c_volatile=yes
35073 else
35074   echo "$as_me: failed program was:" >&5
35075 sed 's/^/| /' conftest.$ac_ext >&5
35076
35077 ol_cv_c_volatile=no
35078 fi
35079 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35080 fi
35081 echo "$as_me:$LINENO: result: $ol_cv_c_volatile" >&5
35082 echo "${ECHO_T}$ol_cv_c_volatile" >&6
35083   if test $ol_cv_c_volatile = yes; then
35084     :
35085   else
35086
35087 cat >>confdefs.h <<\_ACEOF
35088 #define volatile
35089 _ACEOF
35090
35091   fi
35092
35093
35094 if test $cross_compiling = yes ; then
35095         { echo "$as_me:$LINENO: WARNING: Crossing compiling... all bets are off!" >&5
35096 echo "$as_me: WARNING: Crossing compiling... all bets are off!" >&2;}
35097
35098 cat >>confdefs.h <<\_ACEOF
35099 #define CROSS_COMPILING 1
35100 _ACEOF
35101
35102 else
35103         echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
35104 echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
35105 if test "${ac_cv_c_bigendian+set}" = set; then
35106   echo $ECHO_N "(cached) $ECHO_C" >&6
35107 else
35108   # See if sys/param.h defines the BYTE_ORDER macro.
35109 cat >conftest.$ac_ext <<_ACEOF
35110 /* confdefs.h.  */
35111 _ACEOF
35112 cat confdefs.h >>conftest.$ac_ext
35113 cat >>conftest.$ac_ext <<_ACEOF
35114 /* end confdefs.h.  */
35115 #include <sys/types.h>
35116 #include <sys/param.h>
35117
35118 int
35119 main ()
35120 {
35121 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
35122  bogus endian macros
35123 #endif
35124
35125   ;
35126   return 0;
35127 }
35128 _ACEOF
35129 rm -f conftest.$ac_objext
35130 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35131   (eval $ac_compile) 2>conftest.er1
35132   ac_status=$?
35133   grep -v '^ *+' conftest.er1 >conftest.err
35134   rm -f conftest.er1
35135   cat conftest.err >&5
35136   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35137   (exit $ac_status); } &&
35138          { ac_try='test -z "$ac_c_werror_flag"
35139                          || test ! -s conftest.err'
35140   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35141   (eval $ac_try) 2>&5
35142   ac_status=$?
35143   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35144   (exit $ac_status); }; } &&
35145          { ac_try='test -s conftest.$ac_objext'
35146   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35147   (eval $ac_try) 2>&5
35148   ac_status=$?
35149   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35150   (exit $ac_status); }; }; then
35151   # It does; now see whether it defined to BIG_ENDIAN or not.
35152 cat >conftest.$ac_ext <<_ACEOF
35153 /* confdefs.h.  */
35154 _ACEOF
35155 cat confdefs.h >>conftest.$ac_ext
35156 cat >>conftest.$ac_ext <<_ACEOF
35157 /* end confdefs.h.  */
35158 #include <sys/types.h>
35159 #include <sys/param.h>
35160
35161 int
35162 main ()
35163 {
35164 #if BYTE_ORDER != BIG_ENDIAN
35165  not big endian
35166 #endif
35167
35168   ;
35169   return 0;
35170 }
35171 _ACEOF
35172 rm -f conftest.$ac_objext
35173 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35174   (eval $ac_compile) 2>conftest.er1
35175   ac_status=$?
35176   grep -v '^ *+' conftest.er1 >conftest.err
35177   rm -f conftest.er1
35178   cat conftest.err >&5
35179   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35180   (exit $ac_status); } &&
35181          { ac_try='test -z "$ac_c_werror_flag"
35182                          || test ! -s conftest.err'
35183   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35184   (eval $ac_try) 2>&5
35185   ac_status=$?
35186   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35187   (exit $ac_status); }; } &&
35188          { ac_try='test -s conftest.$ac_objext'
35189   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35190   (eval $ac_try) 2>&5
35191   ac_status=$?
35192   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35193   (exit $ac_status); }; }; then
35194   ac_cv_c_bigendian=yes
35195 else
35196   echo "$as_me: failed program was:" >&5
35197 sed 's/^/| /' conftest.$ac_ext >&5
35198
35199 ac_cv_c_bigendian=no
35200 fi
35201 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35202 else
35203   echo "$as_me: failed program was:" >&5
35204 sed 's/^/| /' conftest.$ac_ext >&5
35205
35206 # It does not; compile a test program.
35207 if test "$cross_compiling" = yes; then
35208   # try to guess the endianness by grepping values into an object file
35209   ac_cv_c_bigendian=unknown
35210   cat >conftest.$ac_ext <<_ACEOF
35211 /* confdefs.h.  */
35212 _ACEOF
35213 cat confdefs.h >>conftest.$ac_ext
35214 cat >>conftest.$ac_ext <<_ACEOF
35215 /* end confdefs.h.  */
35216 short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
35217 short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
35218 void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
35219 short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
35220 short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
35221 void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
35222 int
35223 main ()
35224 {
35225  _ascii (); _ebcdic ();
35226   ;
35227   return 0;
35228 }
35229 _ACEOF
35230 rm -f conftest.$ac_objext
35231 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35232   (eval $ac_compile) 2>conftest.er1
35233   ac_status=$?
35234   grep -v '^ *+' conftest.er1 >conftest.err
35235   rm -f conftest.er1
35236   cat conftest.err >&5
35237   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35238   (exit $ac_status); } &&
35239          { ac_try='test -z "$ac_c_werror_flag"
35240                          || test ! -s conftest.err'
35241   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35242   (eval $ac_try) 2>&5
35243   ac_status=$?
35244   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35245   (exit $ac_status); }; } &&
35246          { ac_try='test -s conftest.$ac_objext'
35247   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35248   (eval $ac_try) 2>&5
35249   ac_status=$?
35250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35251   (exit $ac_status); }; }; then
35252   if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
35253   ac_cv_c_bigendian=yes
35254 fi
35255 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
35256   if test "$ac_cv_c_bigendian" = unknown; then
35257     ac_cv_c_bigendian=no
35258   else
35259     # finding both strings is unlikely to happen, but who knows?
35260     ac_cv_c_bigendian=unknown
35261   fi
35262 fi
35263 else
35264   echo "$as_me: failed program was:" >&5
35265 sed 's/^/| /' conftest.$ac_ext >&5
35266
35267 fi
35268 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35269 else
35270   cat >conftest.$ac_ext <<_ACEOF
35271 /* confdefs.h.  */
35272 _ACEOF
35273 cat confdefs.h >>conftest.$ac_ext
35274 cat >>conftest.$ac_ext <<_ACEOF
35275 /* end confdefs.h.  */
35276 int
35277 main ()
35278 {
35279   /* Are we little or big endian?  From Harbison&Steele.  */
35280   union
35281   {
35282     long l;
35283     char c[sizeof (long)];
35284   } u;
35285   u.l = 1;
35286   exit (u.c[sizeof (long) - 1] == 1);
35287 }
35288 _ACEOF
35289 rm -f conftest$ac_exeext
35290 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35291   (eval $ac_link) 2>&5
35292   ac_status=$?
35293   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35294   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
35295   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35296   (eval $ac_try) 2>&5
35297   ac_status=$?
35298   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35299   (exit $ac_status); }; }; then
35300   ac_cv_c_bigendian=no
35301 else
35302   echo "$as_me: program exited with status $ac_status" >&5
35303 echo "$as_me: failed program was:" >&5
35304 sed 's/^/| /' conftest.$ac_ext >&5
35305
35306 ( exit $ac_status )
35307 ac_cv_c_bigendian=yes
35308 fi
35309 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
35310 fi
35311 fi
35312 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35313 fi
35314 echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
35315 echo "${ECHO_T}$ac_cv_c_bigendian" >&6
35316 case $ac_cv_c_bigendian in
35317   yes)
35318
35319 cat >>confdefs.h <<\_ACEOF
35320 #define WORDS_BIGENDIAN 1
35321 _ACEOF
35322  ;;
35323   no)
35324      ;;
35325   *)
35326     { { echo "$as_me:$LINENO: error: unknown endianness
35327 presetting ac_cv_c_bigendian=no (or yes) will help" >&5
35328 echo "$as_me: error: unknown endianness
35329 presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
35330    { (exit 1); exit 1; }; } ;;
35331 esac
35332
35333 fi
35334
35335 echo "$as_me:$LINENO: checking for short" >&5
35336 echo $ECHO_N "checking for short... $ECHO_C" >&6
35337 if test "${ac_cv_type_short+set}" = set; then
35338   echo $ECHO_N "(cached) $ECHO_C" >&6
35339 else
35340   cat >conftest.$ac_ext <<_ACEOF
35341 /* confdefs.h.  */
35342 _ACEOF
35343 cat confdefs.h >>conftest.$ac_ext
35344 cat >>conftest.$ac_ext <<_ACEOF
35345 /* end confdefs.h.  */
35346 $ac_includes_default
35347 int
35348 main ()
35349 {
35350 if ((short *) 0)
35351   return 0;
35352 if (sizeof (short))
35353   return 0;
35354   ;
35355   return 0;
35356 }
35357 _ACEOF
35358 rm -f conftest.$ac_objext
35359 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35360   (eval $ac_compile) 2>conftest.er1
35361   ac_status=$?
35362   grep -v '^ *+' conftest.er1 >conftest.err
35363   rm -f conftest.er1
35364   cat conftest.err >&5
35365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35366   (exit $ac_status); } &&
35367          { ac_try='test -z "$ac_c_werror_flag"
35368                          || test ! -s conftest.err'
35369   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35370   (eval $ac_try) 2>&5
35371   ac_status=$?
35372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35373   (exit $ac_status); }; } &&
35374          { ac_try='test -s conftest.$ac_objext'
35375   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35376   (eval $ac_try) 2>&5
35377   ac_status=$?
35378   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35379   (exit $ac_status); }; }; then
35380   ac_cv_type_short=yes
35381 else
35382   echo "$as_me: failed program was:" >&5
35383 sed 's/^/| /' conftest.$ac_ext >&5
35384
35385 ac_cv_type_short=no
35386 fi
35387 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35388 fi
35389 echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
35390 echo "${ECHO_T}$ac_cv_type_short" >&6
35391
35392 echo "$as_me:$LINENO: checking size of short" >&5
35393 echo $ECHO_N "checking size of short... $ECHO_C" >&6
35394 if test "${ac_cv_sizeof_short+set}" = set; then
35395   echo $ECHO_N "(cached) $ECHO_C" >&6
35396 else
35397   if test "$ac_cv_type_short" = yes; then
35398   # The cast to unsigned long works around a bug in the HP C Compiler
35399   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
35400   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
35401   # This bug is HP SR number 8606223364.
35402   if test "$cross_compiling" = yes; then
35403   # Depending upon the size, compute the lo and hi bounds.
35404 cat >conftest.$ac_ext <<_ACEOF
35405 /* confdefs.h.  */
35406 _ACEOF
35407 cat confdefs.h >>conftest.$ac_ext
35408 cat >>conftest.$ac_ext <<_ACEOF
35409 /* end confdefs.h.  */
35410 $ac_includes_default
35411 int
35412 main ()
35413 {
35414 static int test_array [1 - 2 * !(((long) (sizeof (short))) >= 0)];
35415 test_array [0] = 0
35416
35417   ;
35418   return 0;
35419 }
35420 _ACEOF
35421 rm -f conftest.$ac_objext
35422 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35423   (eval $ac_compile) 2>conftest.er1
35424   ac_status=$?
35425   grep -v '^ *+' conftest.er1 >conftest.err
35426   rm -f conftest.er1
35427   cat conftest.err >&5
35428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35429   (exit $ac_status); } &&
35430          { ac_try='test -z "$ac_c_werror_flag"
35431                          || test ! -s conftest.err'
35432   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35433   (eval $ac_try) 2>&5
35434   ac_status=$?
35435   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35436   (exit $ac_status); }; } &&
35437          { ac_try='test -s conftest.$ac_objext'
35438   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35439   (eval $ac_try) 2>&5
35440   ac_status=$?
35441   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35442   (exit $ac_status); }; }; then
35443   ac_lo=0 ac_mid=0
35444   while :; do
35445     cat >conftest.$ac_ext <<_ACEOF
35446 /* confdefs.h.  */
35447 _ACEOF
35448 cat confdefs.h >>conftest.$ac_ext
35449 cat >>conftest.$ac_ext <<_ACEOF
35450 /* end confdefs.h.  */
35451 $ac_includes_default
35452 int
35453 main ()
35454 {
35455 static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
35456 test_array [0] = 0
35457
35458   ;
35459   return 0;
35460 }
35461 _ACEOF
35462 rm -f conftest.$ac_objext
35463 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35464   (eval $ac_compile) 2>conftest.er1
35465   ac_status=$?
35466   grep -v '^ *+' conftest.er1 >conftest.err
35467   rm -f conftest.er1
35468   cat conftest.err >&5
35469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35470   (exit $ac_status); } &&
35471          { ac_try='test -z "$ac_c_werror_flag"
35472                          || test ! -s conftest.err'
35473   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35474   (eval $ac_try) 2>&5
35475   ac_status=$?
35476   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35477   (exit $ac_status); }; } &&
35478          { ac_try='test -s conftest.$ac_objext'
35479   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35480   (eval $ac_try) 2>&5
35481   ac_status=$?
35482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35483   (exit $ac_status); }; }; then
35484   ac_hi=$ac_mid; break
35485 else
35486   echo "$as_me: failed program was:" >&5
35487 sed 's/^/| /' conftest.$ac_ext >&5
35488
35489 ac_lo=`expr $ac_mid + 1`
35490                     if test $ac_lo -le $ac_mid; then
35491                       ac_lo= ac_hi=
35492                       break
35493                     fi
35494                     ac_mid=`expr 2 '*' $ac_mid + 1`
35495 fi
35496 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35497   done
35498 else
35499   echo "$as_me: failed program was:" >&5
35500 sed 's/^/| /' conftest.$ac_ext >&5
35501
35502 cat >conftest.$ac_ext <<_ACEOF
35503 /* confdefs.h.  */
35504 _ACEOF
35505 cat confdefs.h >>conftest.$ac_ext
35506 cat >>conftest.$ac_ext <<_ACEOF
35507 /* end confdefs.h.  */
35508 $ac_includes_default
35509 int
35510 main ()
35511 {
35512 static int test_array [1 - 2 * !(((long) (sizeof (short))) < 0)];
35513 test_array [0] = 0
35514
35515   ;
35516   return 0;
35517 }
35518 _ACEOF
35519 rm -f conftest.$ac_objext
35520 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35521   (eval $ac_compile) 2>conftest.er1
35522   ac_status=$?
35523   grep -v '^ *+' conftest.er1 >conftest.err
35524   rm -f conftest.er1
35525   cat conftest.err >&5
35526   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35527   (exit $ac_status); } &&
35528          { ac_try='test -z "$ac_c_werror_flag"
35529                          || test ! -s conftest.err'
35530   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35531   (eval $ac_try) 2>&5
35532   ac_status=$?
35533   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35534   (exit $ac_status); }; } &&
35535          { ac_try='test -s conftest.$ac_objext'
35536   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35537   (eval $ac_try) 2>&5
35538   ac_status=$?
35539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35540   (exit $ac_status); }; }; then
35541   ac_hi=-1 ac_mid=-1
35542   while :; do
35543     cat >conftest.$ac_ext <<_ACEOF
35544 /* confdefs.h.  */
35545 _ACEOF
35546 cat confdefs.h >>conftest.$ac_ext
35547 cat >>conftest.$ac_ext <<_ACEOF
35548 /* end confdefs.h.  */
35549 $ac_includes_default
35550 int
35551 main ()
35552 {
35553 static int test_array [1 - 2 * !(((long) (sizeof (short))) >= $ac_mid)];
35554 test_array [0] = 0
35555
35556   ;
35557   return 0;
35558 }
35559 _ACEOF
35560 rm -f conftest.$ac_objext
35561 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35562   (eval $ac_compile) 2>conftest.er1
35563   ac_status=$?
35564   grep -v '^ *+' conftest.er1 >conftest.err
35565   rm -f conftest.er1
35566   cat conftest.err >&5
35567   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35568   (exit $ac_status); } &&
35569          { ac_try='test -z "$ac_c_werror_flag"
35570                          || test ! -s conftest.err'
35571   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35572   (eval $ac_try) 2>&5
35573   ac_status=$?
35574   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35575   (exit $ac_status); }; } &&
35576          { ac_try='test -s conftest.$ac_objext'
35577   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35578   (eval $ac_try) 2>&5
35579   ac_status=$?
35580   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35581   (exit $ac_status); }; }; then
35582   ac_lo=$ac_mid; break
35583 else
35584   echo "$as_me: failed program was:" >&5
35585 sed 's/^/| /' conftest.$ac_ext >&5
35586
35587 ac_hi=`expr '(' $ac_mid ')' - 1`
35588                        if test $ac_mid -le $ac_hi; then
35589                          ac_lo= ac_hi=
35590                          break
35591                        fi
35592                        ac_mid=`expr 2 '*' $ac_mid`
35593 fi
35594 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35595   done
35596 else
35597   echo "$as_me: failed program was:" >&5
35598 sed 's/^/| /' conftest.$ac_ext >&5
35599
35600 ac_lo= ac_hi=
35601 fi
35602 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35603 fi
35604 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35605 # Binary search between lo and hi bounds.
35606 while test "x$ac_lo" != "x$ac_hi"; do
35607   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
35608   cat >conftest.$ac_ext <<_ACEOF
35609 /* confdefs.h.  */
35610 _ACEOF
35611 cat confdefs.h >>conftest.$ac_ext
35612 cat >>conftest.$ac_ext <<_ACEOF
35613 /* end confdefs.h.  */
35614 $ac_includes_default
35615 int
35616 main ()
35617 {
35618 static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
35619 test_array [0] = 0
35620
35621   ;
35622   return 0;
35623 }
35624 _ACEOF
35625 rm -f conftest.$ac_objext
35626 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35627   (eval $ac_compile) 2>conftest.er1
35628   ac_status=$?
35629   grep -v '^ *+' conftest.er1 >conftest.err
35630   rm -f conftest.er1
35631   cat conftest.err >&5
35632   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35633   (exit $ac_status); } &&
35634          { ac_try='test -z "$ac_c_werror_flag"
35635                          || test ! -s conftest.err'
35636   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35637   (eval $ac_try) 2>&5
35638   ac_status=$?
35639   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35640   (exit $ac_status); }; } &&
35641          { ac_try='test -s conftest.$ac_objext'
35642   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35643   (eval $ac_try) 2>&5
35644   ac_status=$?
35645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35646   (exit $ac_status); }; }; then
35647   ac_hi=$ac_mid
35648 else
35649   echo "$as_me: failed program was:" >&5
35650 sed 's/^/| /' conftest.$ac_ext >&5
35651
35652 ac_lo=`expr '(' $ac_mid ')' + 1`
35653 fi
35654 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35655 done
35656 case $ac_lo in
35657 ?*) ac_cv_sizeof_short=$ac_lo;;
35658 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
35659 See \`config.log' for more details." >&5
35660 echo "$as_me: error: cannot compute sizeof (short), 77
35661 See \`config.log' for more details." >&2;}
35662    { (exit 1); exit 1; }; } ;;
35663 esac
35664 else
35665   if test "$cross_compiling" = yes; then
35666   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
35667 See \`config.log' for more details." >&5
35668 echo "$as_me: error: cannot run test program while cross compiling
35669 See \`config.log' for more details." >&2;}
35670    { (exit 1); exit 1; }; }
35671 else
35672   cat >conftest.$ac_ext <<_ACEOF
35673 /* confdefs.h.  */
35674 _ACEOF
35675 cat confdefs.h >>conftest.$ac_ext
35676 cat >>conftest.$ac_ext <<_ACEOF
35677 /* end confdefs.h.  */
35678 $ac_includes_default
35679 long longval () { return (long) (sizeof (short)); }
35680 unsigned long ulongval () { return (long) (sizeof (short)); }
35681 #include <stdio.h>
35682 #include <stdlib.h>
35683 int
35684 main ()
35685 {
35686
35687   FILE *f = fopen ("conftest.val", "w");
35688   if (! f)
35689     exit (1);
35690   if (((long) (sizeof (short))) < 0)
35691     {
35692       long i = longval ();
35693       if (i != ((long) (sizeof (short))))
35694         exit (1);
35695       fprintf (f, "%ld\n", i);
35696     }
35697   else
35698     {
35699       unsigned long i = ulongval ();
35700       if (i != ((long) (sizeof (short))))
35701         exit (1);
35702       fprintf (f, "%lu\n", i);
35703     }
35704   exit (ferror (f) || fclose (f) != 0);
35705
35706   ;
35707   return 0;
35708 }
35709 _ACEOF
35710 rm -f conftest$ac_exeext
35711 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35712   (eval $ac_link) 2>&5
35713   ac_status=$?
35714   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35715   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
35716   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35717   (eval $ac_try) 2>&5
35718   ac_status=$?
35719   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35720   (exit $ac_status); }; }; then
35721   ac_cv_sizeof_short=`cat conftest.val`
35722 else
35723   echo "$as_me: program exited with status $ac_status" >&5
35724 echo "$as_me: failed program was:" >&5
35725 sed 's/^/| /' conftest.$ac_ext >&5
35726
35727 ( exit $ac_status )
35728 { { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
35729 See \`config.log' for more details." >&5
35730 echo "$as_me: error: cannot compute sizeof (short), 77
35731 See \`config.log' for more details." >&2;}
35732    { (exit 1); exit 1; }; }
35733 fi
35734 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
35735 fi
35736 fi
35737 rm -f conftest.val
35738 else
35739   ac_cv_sizeof_short=0
35740 fi
35741 fi
35742 echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
35743 echo "${ECHO_T}$ac_cv_sizeof_short" >&6
35744 cat >>confdefs.h <<_ACEOF
35745 #define SIZEOF_SHORT $ac_cv_sizeof_short
35746 _ACEOF
35747
35748
35749 echo "$as_me:$LINENO: checking for int" >&5
35750 echo $ECHO_N "checking for int... $ECHO_C" >&6
35751 if test "${ac_cv_type_int+set}" = set; then
35752   echo $ECHO_N "(cached) $ECHO_C" >&6
35753 else
35754   cat >conftest.$ac_ext <<_ACEOF
35755 /* confdefs.h.  */
35756 _ACEOF
35757 cat confdefs.h >>conftest.$ac_ext
35758 cat >>conftest.$ac_ext <<_ACEOF
35759 /* end confdefs.h.  */
35760 $ac_includes_default
35761 int
35762 main ()
35763 {
35764 if ((int *) 0)
35765   return 0;
35766 if (sizeof (int))
35767   return 0;
35768   ;
35769   return 0;
35770 }
35771 _ACEOF
35772 rm -f conftest.$ac_objext
35773 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35774   (eval $ac_compile) 2>conftest.er1
35775   ac_status=$?
35776   grep -v '^ *+' conftest.er1 >conftest.err
35777   rm -f conftest.er1
35778   cat conftest.err >&5
35779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35780   (exit $ac_status); } &&
35781          { ac_try='test -z "$ac_c_werror_flag"
35782                          || test ! -s conftest.err'
35783   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35784   (eval $ac_try) 2>&5
35785   ac_status=$?
35786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35787   (exit $ac_status); }; } &&
35788          { ac_try='test -s conftest.$ac_objext'
35789   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35790   (eval $ac_try) 2>&5
35791   ac_status=$?
35792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35793   (exit $ac_status); }; }; then
35794   ac_cv_type_int=yes
35795 else
35796   echo "$as_me: failed program was:" >&5
35797 sed 's/^/| /' conftest.$ac_ext >&5
35798
35799 ac_cv_type_int=no
35800 fi
35801 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35802 fi
35803 echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
35804 echo "${ECHO_T}$ac_cv_type_int" >&6
35805
35806 echo "$as_me:$LINENO: checking size of int" >&5
35807 echo $ECHO_N "checking size of int... $ECHO_C" >&6
35808 if test "${ac_cv_sizeof_int+set}" = set; then
35809   echo $ECHO_N "(cached) $ECHO_C" >&6
35810 else
35811   if test "$ac_cv_type_int" = yes; then
35812   # The cast to unsigned long works around a bug in the HP C Compiler
35813   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
35814   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
35815   # This bug is HP SR number 8606223364.
35816   if test "$cross_compiling" = yes; then
35817   # Depending upon the size, compute the lo and hi bounds.
35818 cat >conftest.$ac_ext <<_ACEOF
35819 /* confdefs.h.  */
35820 _ACEOF
35821 cat confdefs.h >>conftest.$ac_ext
35822 cat >>conftest.$ac_ext <<_ACEOF
35823 /* end confdefs.h.  */
35824 $ac_includes_default
35825 int
35826 main ()
35827 {
35828 static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
35829 test_array [0] = 0
35830
35831   ;
35832   return 0;
35833 }
35834 _ACEOF
35835 rm -f conftest.$ac_objext
35836 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35837   (eval $ac_compile) 2>conftest.er1
35838   ac_status=$?
35839   grep -v '^ *+' conftest.er1 >conftest.err
35840   rm -f conftest.er1
35841   cat conftest.err >&5
35842   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35843   (exit $ac_status); } &&
35844          { ac_try='test -z "$ac_c_werror_flag"
35845                          || test ! -s conftest.err'
35846   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35847   (eval $ac_try) 2>&5
35848   ac_status=$?
35849   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35850   (exit $ac_status); }; } &&
35851          { ac_try='test -s conftest.$ac_objext'
35852   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35853   (eval $ac_try) 2>&5
35854   ac_status=$?
35855   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35856   (exit $ac_status); }; }; then
35857   ac_lo=0 ac_mid=0
35858   while :; do
35859     cat >conftest.$ac_ext <<_ACEOF
35860 /* confdefs.h.  */
35861 _ACEOF
35862 cat confdefs.h >>conftest.$ac_ext
35863 cat >>conftest.$ac_ext <<_ACEOF
35864 /* end confdefs.h.  */
35865 $ac_includes_default
35866 int
35867 main ()
35868 {
35869 static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
35870 test_array [0] = 0
35871
35872   ;
35873   return 0;
35874 }
35875 _ACEOF
35876 rm -f conftest.$ac_objext
35877 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35878   (eval $ac_compile) 2>conftest.er1
35879   ac_status=$?
35880   grep -v '^ *+' conftest.er1 >conftest.err
35881   rm -f conftest.er1
35882   cat conftest.err >&5
35883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35884   (exit $ac_status); } &&
35885          { ac_try='test -z "$ac_c_werror_flag"
35886                          || test ! -s conftest.err'
35887   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35888   (eval $ac_try) 2>&5
35889   ac_status=$?
35890   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35891   (exit $ac_status); }; } &&
35892          { ac_try='test -s conftest.$ac_objext'
35893   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35894   (eval $ac_try) 2>&5
35895   ac_status=$?
35896   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35897   (exit $ac_status); }; }; then
35898   ac_hi=$ac_mid; break
35899 else
35900   echo "$as_me: failed program was:" >&5
35901 sed 's/^/| /' conftest.$ac_ext >&5
35902
35903 ac_lo=`expr $ac_mid + 1`
35904                     if test $ac_lo -le $ac_mid; then
35905                       ac_lo= ac_hi=
35906                       break
35907                     fi
35908                     ac_mid=`expr 2 '*' $ac_mid + 1`
35909 fi
35910 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35911   done
35912 else
35913   echo "$as_me: failed program was:" >&5
35914 sed 's/^/| /' conftest.$ac_ext >&5
35915
35916 cat >conftest.$ac_ext <<_ACEOF
35917 /* confdefs.h.  */
35918 _ACEOF
35919 cat confdefs.h >>conftest.$ac_ext
35920 cat >>conftest.$ac_ext <<_ACEOF
35921 /* end confdefs.h.  */
35922 $ac_includes_default
35923 int
35924 main ()
35925 {
35926 static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
35927 test_array [0] = 0
35928
35929   ;
35930   return 0;
35931 }
35932 _ACEOF
35933 rm -f conftest.$ac_objext
35934 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35935   (eval $ac_compile) 2>conftest.er1
35936   ac_status=$?
35937   grep -v '^ *+' conftest.er1 >conftest.err
35938   rm -f conftest.er1
35939   cat conftest.err >&5
35940   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35941   (exit $ac_status); } &&
35942          { ac_try='test -z "$ac_c_werror_flag"
35943                          || test ! -s conftest.err'
35944   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35945   (eval $ac_try) 2>&5
35946   ac_status=$?
35947   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35948   (exit $ac_status); }; } &&
35949          { ac_try='test -s conftest.$ac_objext'
35950   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35951   (eval $ac_try) 2>&5
35952   ac_status=$?
35953   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35954   (exit $ac_status); }; }; then
35955   ac_hi=-1 ac_mid=-1
35956   while :; do
35957     cat >conftest.$ac_ext <<_ACEOF
35958 /* confdefs.h.  */
35959 _ACEOF
35960 cat confdefs.h >>conftest.$ac_ext
35961 cat >>conftest.$ac_ext <<_ACEOF
35962 /* end confdefs.h.  */
35963 $ac_includes_default
35964 int
35965 main ()
35966 {
35967 static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
35968 test_array [0] = 0
35969
35970   ;
35971   return 0;
35972 }
35973 _ACEOF
35974 rm -f conftest.$ac_objext
35975 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35976   (eval $ac_compile) 2>conftest.er1
35977   ac_status=$?
35978   grep -v '^ *+' conftest.er1 >conftest.err
35979   rm -f conftest.er1
35980   cat conftest.err >&5
35981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35982   (exit $ac_status); } &&
35983          { ac_try='test -z "$ac_c_werror_flag"
35984                          || test ! -s conftest.err'
35985   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35986   (eval $ac_try) 2>&5
35987   ac_status=$?
35988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35989   (exit $ac_status); }; } &&
35990          { ac_try='test -s conftest.$ac_objext'
35991   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35992   (eval $ac_try) 2>&5
35993   ac_status=$?
35994   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35995   (exit $ac_status); }; }; then
35996   ac_lo=$ac_mid; break
35997 else
35998   echo "$as_me: failed program was:" >&5
35999 sed 's/^/| /' conftest.$ac_ext >&5
36000
36001 ac_hi=`expr '(' $ac_mid ')' - 1`
36002                        if test $ac_mid -le $ac_hi; then
36003                          ac_lo= ac_hi=
36004                          break
36005                        fi
36006                        ac_mid=`expr 2 '*' $ac_mid`
36007 fi
36008 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36009   done
36010 else
36011   echo "$as_me: failed program was:" >&5
36012 sed 's/^/| /' conftest.$ac_ext >&5
36013
36014 ac_lo= ac_hi=
36015 fi
36016 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36017 fi
36018 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36019 # Binary search between lo and hi bounds.
36020 while test "x$ac_lo" != "x$ac_hi"; do
36021   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
36022   cat >conftest.$ac_ext <<_ACEOF
36023 /* confdefs.h.  */
36024 _ACEOF
36025 cat confdefs.h >>conftest.$ac_ext
36026 cat >>conftest.$ac_ext <<_ACEOF
36027 /* end confdefs.h.  */
36028 $ac_includes_default
36029 int
36030 main ()
36031 {
36032 static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
36033 test_array [0] = 0
36034
36035   ;
36036   return 0;
36037 }
36038 _ACEOF
36039 rm -f conftest.$ac_objext
36040 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36041   (eval $ac_compile) 2>conftest.er1
36042   ac_status=$?
36043   grep -v '^ *+' conftest.er1 >conftest.err
36044   rm -f conftest.er1
36045   cat conftest.err >&5
36046   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36047   (exit $ac_status); } &&
36048          { ac_try='test -z "$ac_c_werror_flag"
36049                          || test ! -s conftest.err'
36050   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36051   (eval $ac_try) 2>&5
36052   ac_status=$?
36053   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36054   (exit $ac_status); }; } &&
36055          { ac_try='test -s conftest.$ac_objext'
36056   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36057   (eval $ac_try) 2>&5
36058   ac_status=$?
36059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36060   (exit $ac_status); }; }; then
36061   ac_hi=$ac_mid
36062 else
36063   echo "$as_me: failed program was:" >&5
36064 sed 's/^/| /' conftest.$ac_ext >&5
36065
36066 ac_lo=`expr '(' $ac_mid ')' + 1`
36067 fi
36068 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36069 done
36070 case $ac_lo in
36071 ?*) ac_cv_sizeof_int=$ac_lo;;
36072 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
36073 See \`config.log' for more details." >&5
36074 echo "$as_me: error: cannot compute sizeof (int), 77
36075 See \`config.log' for more details." >&2;}
36076    { (exit 1); exit 1; }; } ;;
36077 esac
36078 else
36079   if test "$cross_compiling" = yes; then
36080   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
36081 See \`config.log' for more details." >&5
36082 echo "$as_me: error: cannot run test program while cross compiling
36083 See \`config.log' for more details." >&2;}
36084    { (exit 1); exit 1; }; }
36085 else
36086   cat >conftest.$ac_ext <<_ACEOF
36087 /* confdefs.h.  */
36088 _ACEOF
36089 cat confdefs.h >>conftest.$ac_ext
36090 cat >>conftest.$ac_ext <<_ACEOF
36091 /* end confdefs.h.  */
36092 $ac_includes_default
36093 long longval () { return (long) (sizeof (int)); }
36094 unsigned long ulongval () { return (long) (sizeof (int)); }
36095 #include <stdio.h>
36096 #include <stdlib.h>
36097 int
36098 main ()
36099 {
36100
36101   FILE *f = fopen ("conftest.val", "w");
36102   if (! f)
36103     exit (1);
36104   if (((long) (sizeof (int))) < 0)
36105     {
36106       long i = longval ();
36107       if (i != ((long) (sizeof (int))))
36108         exit (1);
36109       fprintf (f, "%ld\n", i);
36110     }
36111   else
36112     {
36113       unsigned long i = ulongval ();
36114       if (i != ((long) (sizeof (int))))
36115         exit (1);
36116       fprintf (f, "%lu\n", i);
36117     }
36118   exit (ferror (f) || fclose (f) != 0);
36119
36120   ;
36121   return 0;
36122 }
36123 _ACEOF
36124 rm -f conftest$ac_exeext
36125 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36126   (eval $ac_link) 2>&5
36127   ac_status=$?
36128   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36129   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
36130   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36131   (eval $ac_try) 2>&5
36132   ac_status=$?
36133   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36134   (exit $ac_status); }; }; then
36135   ac_cv_sizeof_int=`cat conftest.val`
36136 else
36137   echo "$as_me: program exited with status $ac_status" >&5
36138 echo "$as_me: failed program was:" >&5
36139 sed 's/^/| /' conftest.$ac_ext >&5
36140
36141 ( exit $ac_status )
36142 { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
36143 See \`config.log' for more details." >&5
36144 echo "$as_me: error: cannot compute sizeof (int), 77
36145 See \`config.log' for more details." >&2;}
36146    { (exit 1); exit 1; }; }
36147 fi
36148 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
36149 fi
36150 fi
36151 rm -f conftest.val
36152 else
36153   ac_cv_sizeof_int=0
36154 fi
36155 fi
36156 echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
36157 echo "${ECHO_T}$ac_cv_sizeof_int" >&6
36158 cat >>confdefs.h <<_ACEOF
36159 #define SIZEOF_INT $ac_cv_sizeof_int
36160 _ACEOF
36161
36162
36163 echo "$as_me:$LINENO: checking for long" >&5
36164 echo $ECHO_N "checking for long... $ECHO_C" >&6
36165 if test "${ac_cv_type_long+set}" = set; then
36166   echo $ECHO_N "(cached) $ECHO_C" >&6
36167 else
36168   cat >conftest.$ac_ext <<_ACEOF
36169 /* confdefs.h.  */
36170 _ACEOF
36171 cat confdefs.h >>conftest.$ac_ext
36172 cat >>conftest.$ac_ext <<_ACEOF
36173 /* end confdefs.h.  */
36174 $ac_includes_default
36175 int
36176 main ()
36177 {
36178 if ((long *) 0)
36179   return 0;
36180 if (sizeof (long))
36181   return 0;
36182   ;
36183   return 0;
36184 }
36185 _ACEOF
36186 rm -f conftest.$ac_objext
36187 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36188   (eval $ac_compile) 2>conftest.er1
36189   ac_status=$?
36190   grep -v '^ *+' conftest.er1 >conftest.err
36191   rm -f conftest.er1
36192   cat conftest.err >&5
36193   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36194   (exit $ac_status); } &&
36195          { ac_try='test -z "$ac_c_werror_flag"
36196                          || test ! -s conftest.err'
36197   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36198   (eval $ac_try) 2>&5
36199   ac_status=$?
36200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36201   (exit $ac_status); }; } &&
36202          { ac_try='test -s conftest.$ac_objext'
36203   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36204   (eval $ac_try) 2>&5
36205   ac_status=$?
36206   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36207   (exit $ac_status); }; }; then
36208   ac_cv_type_long=yes
36209 else
36210   echo "$as_me: failed program was:" >&5
36211 sed 's/^/| /' conftest.$ac_ext >&5
36212
36213 ac_cv_type_long=no
36214 fi
36215 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36216 fi
36217 echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
36218 echo "${ECHO_T}$ac_cv_type_long" >&6
36219
36220 echo "$as_me:$LINENO: checking size of long" >&5
36221 echo $ECHO_N "checking size of long... $ECHO_C" >&6
36222 if test "${ac_cv_sizeof_long+set}" = set; then
36223   echo $ECHO_N "(cached) $ECHO_C" >&6
36224 else
36225   if test "$ac_cv_type_long" = yes; then
36226   # The cast to unsigned long works around a bug in the HP C Compiler
36227   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
36228   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
36229   # This bug is HP SR number 8606223364.
36230   if test "$cross_compiling" = yes; then
36231   # Depending upon the size, compute the lo and hi bounds.
36232 cat >conftest.$ac_ext <<_ACEOF
36233 /* confdefs.h.  */
36234 _ACEOF
36235 cat confdefs.h >>conftest.$ac_ext
36236 cat >>conftest.$ac_ext <<_ACEOF
36237 /* end confdefs.h.  */
36238 $ac_includes_default
36239 int
36240 main ()
36241 {
36242 static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
36243 test_array [0] = 0
36244
36245   ;
36246   return 0;
36247 }
36248 _ACEOF
36249 rm -f conftest.$ac_objext
36250 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36251   (eval $ac_compile) 2>conftest.er1
36252   ac_status=$?
36253   grep -v '^ *+' conftest.er1 >conftest.err
36254   rm -f conftest.er1
36255   cat conftest.err >&5
36256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36257   (exit $ac_status); } &&
36258          { ac_try='test -z "$ac_c_werror_flag"
36259                          || test ! -s conftest.err'
36260   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36261   (eval $ac_try) 2>&5
36262   ac_status=$?
36263   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36264   (exit $ac_status); }; } &&
36265          { ac_try='test -s conftest.$ac_objext'
36266   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36267   (eval $ac_try) 2>&5
36268   ac_status=$?
36269   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36270   (exit $ac_status); }; }; then
36271   ac_lo=0 ac_mid=0
36272   while :; do
36273     cat >conftest.$ac_ext <<_ACEOF
36274 /* confdefs.h.  */
36275 _ACEOF
36276 cat confdefs.h >>conftest.$ac_ext
36277 cat >>conftest.$ac_ext <<_ACEOF
36278 /* end confdefs.h.  */
36279 $ac_includes_default
36280 int
36281 main ()
36282 {
36283 static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
36284 test_array [0] = 0
36285
36286   ;
36287   return 0;
36288 }
36289 _ACEOF
36290 rm -f conftest.$ac_objext
36291 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36292   (eval $ac_compile) 2>conftest.er1
36293   ac_status=$?
36294   grep -v '^ *+' conftest.er1 >conftest.err
36295   rm -f conftest.er1
36296   cat conftest.err >&5
36297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36298   (exit $ac_status); } &&
36299          { ac_try='test -z "$ac_c_werror_flag"
36300                          || test ! -s conftest.err'
36301   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36302   (eval $ac_try) 2>&5
36303   ac_status=$?
36304   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36305   (exit $ac_status); }; } &&
36306          { ac_try='test -s conftest.$ac_objext'
36307   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36308   (eval $ac_try) 2>&5
36309   ac_status=$?
36310   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36311   (exit $ac_status); }; }; then
36312   ac_hi=$ac_mid; break
36313 else
36314   echo "$as_me: failed program was:" >&5
36315 sed 's/^/| /' conftest.$ac_ext >&5
36316
36317 ac_lo=`expr $ac_mid + 1`
36318                     if test $ac_lo -le $ac_mid; then
36319                       ac_lo= ac_hi=
36320                       break
36321                     fi
36322                     ac_mid=`expr 2 '*' $ac_mid + 1`
36323 fi
36324 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36325   done
36326 else
36327   echo "$as_me: failed program was:" >&5
36328 sed 's/^/| /' conftest.$ac_ext >&5
36329
36330 cat >conftest.$ac_ext <<_ACEOF
36331 /* confdefs.h.  */
36332 _ACEOF
36333 cat confdefs.h >>conftest.$ac_ext
36334 cat >>conftest.$ac_ext <<_ACEOF
36335 /* end confdefs.h.  */
36336 $ac_includes_default
36337 int
36338 main ()
36339 {
36340 static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
36341 test_array [0] = 0
36342
36343   ;
36344   return 0;
36345 }
36346 _ACEOF
36347 rm -f conftest.$ac_objext
36348 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36349   (eval $ac_compile) 2>conftest.er1
36350   ac_status=$?
36351   grep -v '^ *+' conftest.er1 >conftest.err
36352   rm -f conftest.er1
36353   cat conftest.err >&5
36354   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36355   (exit $ac_status); } &&
36356          { ac_try='test -z "$ac_c_werror_flag"
36357                          || test ! -s conftest.err'
36358   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36359   (eval $ac_try) 2>&5
36360   ac_status=$?
36361   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36362   (exit $ac_status); }; } &&
36363          { ac_try='test -s conftest.$ac_objext'
36364   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36365   (eval $ac_try) 2>&5
36366   ac_status=$?
36367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36368   (exit $ac_status); }; }; then
36369   ac_hi=-1 ac_mid=-1
36370   while :; do
36371     cat >conftest.$ac_ext <<_ACEOF
36372 /* confdefs.h.  */
36373 _ACEOF
36374 cat confdefs.h >>conftest.$ac_ext
36375 cat >>conftest.$ac_ext <<_ACEOF
36376 /* end confdefs.h.  */
36377 $ac_includes_default
36378 int
36379 main ()
36380 {
36381 static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
36382 test_array [0] = 0
36383
36384   ;
36385   return 0;
36386 }
36387 _ACEOF
36388 rm -f conftest.$ac_objext
36389 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36390   (eval $ac_compile) 2>conftest.er1
36391   ac_status=$?
36392   grep -v '^ *+' conftest.er1 >conftest.err
36393   rm -f conftest.er1
36394   cat conftest.err >&5
36395   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36396   (exit $ac_status); } &&
36397          { ac_try='test -z "$ac_c_werror_flag"
36398                          || test ! -s conftest.err'
36399   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36400   (eval $ac_try) 2>&5
36401   ac_status=$?
36402   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36403   (exit $ac_status); }; } &&
36404          { ac_try='test -s conftest.$ac_objext'
36405   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36406   (eval $ac_try) 2>&5
36407   ac_status=$?
36408   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36409   (exit $ac_status); }; }; then
36410   ac_lo=$ac_mid; break
36411 else
36412   echo "$as_me: failed program was:" >&5
36413 sed 's/^/| /' conftest.$ac_ext >&5
36414
36415 ac_hi=`expr '(' $ac_mid ')' - 1`
36416                        if test $ac_mid -le $ac_hi; then
36417                          ac_lo= ac_hi=
36418                          break
36419                        fi
36420                        ac_mid=`expr 2 '*' $ac_mid`
36421 fi
36422 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36423   done
36424 else
36425   echo "$as_me: failed program was:" >&5
36426 sed 's/^/| /' conftest.$ac_ext >&5
36427
36428 ac_lo= ac_hi=
36429 fi
36430 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36431 fi
36432 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36433 # Binary search between lo and hi bounds.
36434 while test "x$ac_lo" != "x$ac_hi"; do
36435   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
36436   cat >conftest.$ac_ext <<_ACEOF
36437 /* confdefs.h.  */
36438 _ACEOF
36439 cat confdefs.h >>conftest.$ac_ext
36440 cat >>conftest.$ac_ext <<_ACEOF
36441 /* end confdefs.h.  */
36442 $ac_includes_default
36443 int
36444 main ()
36445 {
36446 static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
36447 test_array [0] = 0
36448
36449   ;
36450   return 0;
36451 }
36452 _ACEOF
36453 rm -f conftest.$ac_objext
36454 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36455   (eval $ac_compile) 2>conftest.er1
36456   ac_status=$?
36457   grep -v '^ *+' conftest.er1 >conftest.err
36458   rm -f conftest.er1
36459   cat conftest.err >&5
36460   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36461   (exit $ac_status); } &&
36462          { ac_try='test -z "$ac_c_werror_flag"
36463                          || test ! -s conftest.err'
36464   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36465   (eval $ac_try) 2>&5
36466   ac_status=$?
36467   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36468   (exit $ac_status); }; } &&
36469          { ac_try='test -s conftest.$ac_objext'
36470   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36471   (eval $ac_try) 2>&5
36472   ac_status=$?
36473   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36474   (exit $ac_status); }; }; then
36475   ac_hi=$ac_mid
36476 else
36477   echo "$as_me: failed program was:" >&5
36478 sed 's/^/| /' conftest.$ac_ext >&5
36479
36480 ac_lo=`expr '(' $ac_mid ')' + 1`
36481 fi
36482 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36483 done
36484 case $ac_lo in
36485 ?*) ac_cv_sizeof_long=$ac_lo;;
36486 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
36487 See \`config.log' for more details." >&5
36488 echo "$as_me: error: cannot compute sizeof (long), 77
36489 See \`config.log' for more details." >&2;}
36490    { (exit 1); exit 1; }; } ;;
36491 esac
36492 else
36493   if test "$cross_compiling" = yes; then
36494   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
36495 See \`config.log' for more details." >&5
36496 echo "$as_me: error: cannot run test program while cross compiling
36497 See \`config.log' for more details." >&2;}
36498    { (exit 1); exit 1; }; }
36499 else
36500   cat >conftest.$ac_ext <<_ACEOF
36501 /* confdefs.h.  */
36502 _ACEOF
36503 cat confdefs.h >>conftest.$ac_ext
36504 cat >>conftest.$ac_ext <<_ACEOF
36505 /* end confdefs.h.  */
36506 $ac_includes_default
36507 long longval () { return (long) (sizeof (long)); }
36508 unsigned long ulongval () { return (long) (sizeof (long)); }
36509 #include <stdio.h>
36510 #include <stdlib.h>
36511 int
36512 main ()
36513 {
36514
36515   FILE *f = fopen ("conftest.val", "w");
36516   if (! f)
36517     exit (1);
36518   if (((long) (sizeof (long))) < 0)
36519     {
36520       long i = longval ();
36521       if (i != ((long) (sizeof (long))))
36522         exit (1);
36523       fprintf (f, "%ld\n", i);
36524     }
36525   else
36526     {
36527       unsigned long i = ulongval ();
36528       if (i != ((long) (sizeof (long))))
36529         exit (1);
36530       fprintf (f, "%lu\n", i);
36531     }
36532   exit (ferror (f) || fclose (f) != 0);
36533
36534   ;
36535   return 0;
36536 }
36537 _ACEOF
36538 rm -f conftest$ac_exeext
36539 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36540   (eval $ac_link) 2>&5
36541   ac_status=$?
36542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36543   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
36544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36545   (eval $ac_try) 2>&5
36546   ac_status=$?
36547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36548   (exit $ac_status); }; }; then
36549   ac_cv_sizeof_long=`cat conftest.val`
36550 else
36551   echo "$as_me: program exited with status $ac_status" >&5
36552 echo "$as_me: failed program was:" >&5
36553 sed 's/^/| /' conftest.$ac_ext >&5
36554
36555 ( exit $ac_status )
36556 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
36557 See \`config.log' for more details." >&5
36558 echo "$as_me: error: cannot compute sizeof (long), 77
36559 See \`config.log' for more details." >&2;}
36560    { (exit 1); exit 1; }; }
36561 fi
36562 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
36563 fi
36564 fi
36565 rm -f conftest.val
36566 else
36567   ac_cv_sizeof_long=0
36568 fi
36569 fi
36570 echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
36571 echo "${ECHO_T}$ac_cv_sizeof_long" >&6
36572 cat >>confdefs.h <<_ACEOF
36573 #define SIZEOF_LONG $ac_cv_sizeof_long
36574 _ACEOF
36575
36576
36577 echo "$as_me:$LINENO: checking for long long" >&5
36578 echo $ECHO_N "checking for long long... $ECHO_C" >&6
36579 if test "${ac_cv_type_long_long+set}" = set; then
36580   echo $ECHO_N "(cached) $ECHO_C" >&6
36581 else
36582   cat >conftest.$ac_ext <<_ACEOF
36583 /* confdefs.h.  */
36584 _ACEOF
36585 cat confdefs.h >>conftest.$ac_ext
36586 cat >>conftest.$ac_ext <<_ACEOF
36587 /* end confdefs.h.  */
36588 $ac_includes_default
36589 int
36590 main ()
36591 {
36592 if ((long long *) 0)
36593   return 0;
36594 if (sizeof (long long))
36595   return 0;
36596   ;
36597   return 0;
36598 }
36599 _ACEOF
36600 rm -f conftest.$ac_objext
36601 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36602   (eval $ac_compile) 2>conftest.er1
36603   ac_status=$?
36604   grep -v '^ *+' conftest.er1 >conftest.err
36605   rm -f conftest.er1
36606   cat conftest.err >&5
36607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36608   (exit $ac_status); } &&
36609          { ac_try='test -z "$ac_c_werror_flag"
36610                          || test ! -s conftest.err'
36611   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36612   (eval $ac_try) 2>&5
36613   ac_status=$?
36614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36615   (exit $ac_status); }; } &&
36616          { ac_try='test -s conftest.$ac_objext'
36617   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36618   (eval $ac_try) 2>&5
36619   ac_status=$?
36620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36621   (exit $ac_status); }; }; then
36622   ac_cv_type_long_long=yes
36623 else
36624   echo "$as_me: failed program was:" >&5
36625 sed 's/^/| /' conftest.$ac_ext >&5
36626
36627 ac_cv_type_long_long=no
36628 fi
36629 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36630 fi
36631 echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
36632 echo "${ECHO_T}$ac_cv_type_long_long" >&6
36633
36634 echo "$as_me:$LINENO: checking size of long long" >&5
36635 echo $ECHO_N "checking size of long long... $ECHO_C" >&6
36636 if test "${ac_cv_sizeof_long_long+set}" = set; then
36637   echo $ECHO_N "(cached) $ECHO_C" >&6
36638 else
36639   if test "$ac_cv_type_long_long" = yes; then
36640   # The cast to unsigned long works around a bug in the HP C Compiler
36641   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
36642   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
36643   # This bug is HP SR number 8606223364.
36644   if test "$cross_compiling" = yes; then
36645   # Depending upon the size, compute the lo and hi bounds.
36646 cat >conftest.$ac_ext <<_ACEOF
36647 /* confdefs.h.  */
36648 _ACEOF
36649 cat confdefs.h >>conftest.$ac_ext
36650 cat >>conftest.$ac_ext <<_ACEOF
36651 /* end confdefs.h.  */
36652 $ac_includes_default
36653 int
36654 main ()
36655 {
36656 static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= 0)];
36657 test_array [0] = 0
36658
36659   ;
36660   return 0;
36661 }
36662 _ACEOF
36663 rm -f conftest.$ac_objext
36664 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36665   (eval $ac_compile) 2>conftest.er1
36666   ac_status=$?
36667   grep -v '^ *+' conftest.er1 >conftest.err
36668   rm -f conftest.er1
36669   cat conftest.err >&5
36670   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36671   (exit $ac_status); } &&
36672          { ac_try='test -z "$ac_c_werror_flag"
36673                          || test ! -s conftest.err'
36674   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36675   (eval $ac_try) 2>&5
36676   ac_status=$?
36677   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36678   (exit $ac_status); }; } &&
36679          { ac_try='test -s conftest.$ac_objext'
36680   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36681   (eval $ac_try) 2>&5
36682   ac_status=$?
36683   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36684   (exit $ac_status); }; }; then
36685   ac_lo=0 ac_mid=0
36686   while :; do
36687     cat >conftest.$ac_ext <<_ACEOF
36688 /* confdefs.h.  */
36689 _ACEOF
36690 cat confdefs.h >>conftest.$ac_ext
36691 cat >>conftest.$ac_ext <<_ACEOF
36692 /* end confdefs.h.  */
36693 $ac_includes_default
36694 int
36695 main ()
36696 {
36697 static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
36698 test_array [0] = 0
36699
36700   ;
36701   return 0;
36702 }
36703 _ACEOF
36704 rm -f conftest.$ac_objext
36705 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36706   (eval $ac_compile) 2>conftest.er1
36707   ac_status=$?
36708   grep -v '^ *+' conftest.er1 >conftest.err
36709   rm -f conftest.er1
36710   cat conftest.err >&5
36711   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36712   (exit $ac_status); } &&
36713          { ac_try='test -z "$ac_c_werror_flag"
36714                          || test ! -s conftest.err'
36715   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36716   (eval $ac_try) 2>&5
36717   ac_status=$?
36718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36719   (exit $ac_status); }; } &&
36720          { ac_try='test -s conftest.$ac_objext'
36721   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36722   (eval $ac_try) 2>&5
36723   ac_status=$?
36724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36725   (exit $ac_status); }; }; then
36726   ac_hi=$ac_mid; break
36727 else
36728   echo "$as_me: failed program was:" >&5
36729 sed 's/^/| /' conftest.$ac_ext >&5
36730
36731 ac_lo=`expr $ac_mid + 1`
36732                     if test $ac_lo -le $ac_mid; then
36733                       ac_lo= ac_hi=
36734                       break
36735                     fi
36736                     ac_mid=`expr 2 '*' $ac_mid + 1`
36737 fi
36738 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36739   done
36740 else
36741   echo "$as_me: failed program was:" >&5
36742 sed 's/^/| /' conftest.$ac_ext >&5
36743
36744 cat >conftest.$ac_ext <<_ACEOF
36745 /* confdefs.h.  */
36746 _ACEOF
36747 cat confdefs.h >>conftest.$ac_ext
36748 cat >>conftest.$ac_ext <<_ACEOF
36749 /* end confdefs.h.  */
36750 $ac_includes_default
36751 int
36752 main ()
36753 {
36754 static int test_array [1 - 2 * !(((long) (sizeof (long long))) < 0)];
36755 test_array [0] = 0
36756
36757   ;
36758   return 0;
36759 }
36760 _ACEOF
36761 rm -f conftest.$ac_objext
36762 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36763   (eval $ac_compile) 2>conftest.er1
36764   ac_status=$?
36765   grep -v '^ *+' conftest.er1 >conftest.err
36766   rm -f conftest.er1
36767   cat conftest.err >&5
36768   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36769   (exit $ac_status); } &&
36770          { ac_try='test -z "$ac_c_werror_flag"
36771                          || test ! -s conftest.err'
36772   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36773   (eval $ac_try) 2>&5
36774   ac_status=$?
36775   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36776   (exit $ac_status); }; } &&
36777          { ac_try='test -s conftest.$ac_objext'
36778   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36779   (eval $ac_try) 2>&5
36780   ac_status=$?
36781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36782   (exit $ac_status); }; }; then
36783   ac_hi=-1 ac_mid=-1
36784   while :; do
36785     cat >conftest.$ac_ext <<_ACEOF
36786 /* confdefs.h.  */
36787 _ACEOF
36788 cat confdefs.h >>conftest.$ac_ext
36789 cat >>conftest.$ac_ext <<_ACEOF
36790 /* end confdefs.h.  */
36791 $ac_includes_default
36792 int
36793 main ()
36794 {
36795 static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= $ac_mid)];
36796 test_array [0] = 0
36797
36798   ;
36799   return 0;
36800 }
36801 _ACEOF
36802 rm -f conftest.$ac_objext
36803 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36804   (eval $ac_compile) 2>conftest.er1
36805   ac_status=$?
36806   grep -v '^ *+' conftest.er1 >conftest.err
36807   rm -f conftest.er1
36808   cat conftest.err >&5
36809   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36810   (exit $ac_status); } &&
36811          { ac_try='test -z "$ac_c_werror_flag"
36812                          || test ! -s conftest.err'
36813   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36814   (eval $ac_try) 2>&5
36815   ac_status=$?
36816   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36817   (exit $ac_status); }; } &&
36818          { ac_try='test -s conftest.$ac_objext'
36819   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36820   (eval $ac_try) 2>&5
36821   ac_status=$?
36822   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36823   (exit $ac_status); }; }; then
36824   ac_lo=$ac_mid; break
36825 else
36826   echo "$as_me: failed program was:" >&5
36827 sed 's/^/| /' conftest.$ac_ext >&5
36828
36829 ac_hi=`expr '(' $ac_mid ')' - 1`
36830                        if test $ac_mid -le $ac_hi; then
36831                          ac_lo= ac_hi=
36832                          break
36833                        fi
36834                        ac_mid=`expr 2 '*' $ac_mid`
36835 fi
36836 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36837   done
36838 else
36839   echo "$as_me: failed program was:" >&5
36840 sed 's/^/| /' conftest.$ac_ext >&5
36841
36842 ac_lo= ac_hi=
36843 fi
36844 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36845 fi
36846 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36847 # Binary search between lo and hi bounds.
36848 while test "x$ac_lo" != "x$ac_hi"; do
36849   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
36850   cat >conftest.$ac_ext <<_ACEOF
36851 /* confdefs.h.  */
36852 _ACEOF
36853 cat confdefs.h >>conftest.$ac_ext
36854 cat >>conftest.$ac_ext <<_ACEOF
36855 /* end confdefs.h.  */
36856 $ac_includes_default
36857 int
36858 main ()
36859 {
36860 static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
36861 test_array [0] = 0
36862
36863   ;
36864   return 0;
36865 }
36866 _ACEOF
36867 rm -f conftest.$ac_objext
36868 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36869   (eval $ac_compile) 2>conftest.er1
36870   ac_status=$?
36871   grep -v '^ *+' conftest.er1 >conftest.err
36872   rm -f conftest.er1
36873   cat conftest.err >&5
36874   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36875   (exit $ac_status); } &&
36876          { ac_try='test -z "$ac_c_werror_flag"
36877                          || test ! -s conftest.err'
36878   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36879   (eval $ac_try) 2>&5
36880   ac_status=$?
36881   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36882   (exit $ac_status); }; } &&
36883          { ac_try='test -s conftest.$ac_objext'
36884   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36885   (eval $ac_try) 2>&5
36886   ac_status=$?
36887   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36888   (exit $ac_status); }; }; then
36889   ac_hi=$ac_mid
36890 else
36891   echo "$as_me: failed program was:" >&5
36892 sed 's/^/| /' conftest.$ac_ext >&5
36893
36894 ac_lo=`expr '(' $ac_mid ')' + 1`
36895 fi
36896 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36897 done
36898 case $ac_lo in
36899 ?*) ac_cv_sizeof_long_long=$ac_lo;;
36900 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
36901 See \`config.log' for more details." >&5
36902 echo "$as_me: error: cannot compute sizeof (long long), 77
36903 See \`config.log' for more details." >&2;}
36904    { (exit 1); exit 1; }; } ;;
36905 esac
36906 else
36907   if test "$cross_compiling" = yes; then
36908   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
36909 See \`config.log' for more details." >&5
36910 echo "$as_me: error: cannot run test program while cross compiling
36911 See \`config.log' for more details." >&2;}
36912    { (exit 1); exit 1; }; }
36913 else
36914   cat >conftest.$ac_ext <<_ACEOF
36915 /* confdefs.h.  */
36916 _ACEOF
36917 cat confdefs.h >>conftest.$ac_ext
36918 cat >>conftest.$ac_ext <<_ACEOF
36919 /* end confdefs.h.  */
36920 $ac_includes_default
36921 long longval () { return (long) (sizeof (long long)); }
36922 unsigned long ulongval () { return (long) (sizeof (long long)); }
36923 #include <stdio.h>
36924 #include <stdlib.h>
36925 int
36926 main ()
36927 {
36928
36929   FILE *f = fopen ("conftest.val", "w");
36930   if (! f)
36931     exit (1);
36932   if (((long) (sizeof (long long))) < 0)
36933     {
36934       long i = longval ();
36935       if (i != ((long) (sizeof (long long))))
36936         exit (1);
36937       fprintf (f, "%ld\n", i);
36938     }
36939   else
36940     {
36941       unsigned long i = ulongval ();
36942       if (i != ((long) (sizeof (long long))))
36943         exit (1);
36944       fprintf (f, "%lu\n", i);
36945     }
36946   exit (ferror (f) || fclose (f) != 0);
36947
36948   ;
36949   return 0;
36950 }
36951 _ACEOF
36952 rm -f conftest$ac_exeext
36953 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36954   (eval $ac_link) 2>&5
36955   ac_status=$?
36956   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36957   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
36958   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36959   (eval $ac_try) 2>&5
36960   ac_status=$?
36961   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36962   (exit $ac_status); }; }; then
36963   ac_cv_sizeof_long_long=`cat conftest.val`
36964 else
36965   echo "$as_me: program exited with status $ac_status" >&5
36966 echo "$as_me: failed program was:" >&5
36967 sed 's/^/| /' conftest.$ac_ext >&5
36968
36969 ( exit $ac_status )
36970 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
36971 See \`config.log' for more details." >&5
36972 echo "$as_me: error: cannot compute sizeof (long long), 77
36973 See \`config.log' for more details." >&2;}
36974    { (exit 1); exit 1; }; }
36975 fi
36976 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
36977 fi
36978 fi
36979 rm -f conftest.val
36980 else
36981   ac_cv_sizeof_long_long=0
36982 fi
36983 fi
36984 echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
36985 echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
36986 cat >>confdefs.h <<_ACEOF
36987 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
36988 _ACEOF
36989
36990
36991 echo "$as_me:$LINENO: checking for wchar_t" >&5
36992 echo $ECHO_N "checking for wchar_t... $ECHO_C" >&6
36993 if test "${ac_cv_type_wchar_t+set}" = set; then
36994   echo $ECHO_N "(cached) $ECHO_C" >&6
36995 else
36996   cat >conftest.$ac_ext <<_ACEOF
36997 /* confdefs.h.  */
36998 _ACEOF
36999 cat confdefs.h >>conftest.$ac_ext
37000 cat >>conftest.$ac_ext <<_ACEOF
37001 /* end confdefs.h.  */
37002 $ac_includes_default
37003 int
37004 main ()
37005 {
37006 if ((wchar_t *) 0)
37007   return 0;
37008 if (sizeof (wchar_t))
37009   return 0;
37010   ;
37011   return 0;
37012 }
37013 _ACEOF
37014 rm -f conftest.$ac_objext
37015 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37016   (eval $ac_compile) 2>conftest.er1
37017   ac_status=$?
37018   grep -v '^ *+' conftest.er1 >conftest.err
37019   rm -f conftest.er1
37020   cat conftest.err >&5
37021   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37022   (exit $ac_status); } &&
37023          { ac_try='test -z "$ac_c_werror_flag"
37024                          || test ! -s conftest.err'
37025   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37026   (eval $ac_try) 2>&5
37027   ac_status=$?
37028   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37029   (exit $ac_status); }; } &&
37030          { ac_try='test -s conftest.$ac_objext'
37031   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37032   (eval $ac_try) 2>&5
37033   ac_status=$?
37034   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37035   (exit $ac_status); }; }; then
37036   ac_cv_type_wchar_t=yes
37037 else
37038   echo "$as_me: failed program was:" >&5
37039 sed 's/^/| /' conftest.$ac_ext >&5
37040
37041 ac_cv_type_wchar_t=no
37042 fi
37043 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37044 fi
37045 echo "$as_me:$LINENO: result: $ac_cv_type_wchar_t" >&5
37046 echo "${ECHO_T}$ac_cv_type_wchar_t" >&6
37047
37048 echo "$as_me:$LINENO: checking size of wchar_t" >&5
37049 echo $ECHO_N "checking size of wchar_t... $ECHO_C" >&6
37050 if test "${ac_cv_sizeof_wchar_t+set}" = set; then
37051   echo $ECHO_N "(cached) $ECHO_C" >&6
37052 else
37053   if test "$ac_cv_type_wchar_t" = yes; then
37054   # The cast to unsigned long works around a bug in the HP C Compiler
37055   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
37056   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
37057   # This bug is HP SR number 8606223364.
37058   if test "$cross_compiling" = yes; then
37059   # Depending upon the size, compute the lo and hi bounds.
37060 cat >conftest.$ac_ext <<_ACEOF
37061 /* confdefs.h.  */
37062 _ACEOF
37063 cat confdefs.h >>conftest.$ac_ext
37064 cat >>conftest.$ac_ext <<_ACEOF
37065 /* end confdefs.h.  */
37066 $ac_includes_default
37067 int
37068 main ()
37069 {
37070 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= 0)];
37071 test_array [0] = 0
37072
37073   ;
37074   return 0;
37075 }
37076 _ACEOF
37077 rm -f conftest.$ac_objext
37078 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37079   (eval $ac_compile) 2>conftest.er1
37080   ac_status=$?
37081   grep -v '^ *+' conftest.er1 >conftest.err
37082   rm -f conftest.er1
37083   cat conftest.err >&5
37084   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37085   (exit $ac_status); } &&
37086          { ac_try='test -z "$ac_c_werror_flag"
37087                          || test ! -s conftest.err'
37088   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37089   (eval $ac_try) 2>&5
37090   ac_status=$?
37091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37092   (exit $ac_status); }; } &&
37093          { ac_try='test -s conftest.$ac_objext'
37094   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37095   (eval $ac_try) 2>&5
37096   ac_status=$?
37097   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37098   (exit $ac_status); }; }; then
37099   ac_lo=0 ac_mid=0
37100   while :; do
37101     cat >conftest.$ac_ext <<_ACEOF
37102 /* confdefs.h.  */
37103 _ACEOF
37104 cat confdefs.h >>conftest.$ac_ext
37105 cat >>conftest.$ac_ext <<_ACEOF
37106 /* end confdefs.h.  */
37107 $ac_includes_default
37108 int
37109 main ()
37110 {
37111 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
37112 test_array [0] = 0
37113
37114   ;
37115   return 0;
37116 }
37117 _ACEOF
37118 rm -f conftest.$ac_objext
37119 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37120   (eval $ac_compile) 2>conftest.er1
37121   ac_status=$?
37122   grep -v '^ *+' conftest.er1 >conftest.err
37123   rm -f conftest.er1
37124   cat conftest.err >&5
37125   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37126   (exit $ac_status); } &&
37127          { ac_try='test -z "$ac_c_werror_flag"
37128                          || test ! -s conftest.err'
37129   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37130   (eval $ac_try) 2>&5
37131   ac_status=$?
37132   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37133   (exit $ac_status); }; } &&
37134          { ac_try='test -s conftest.$ac_objext'
37135   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37136   (eval $ac_try) 2>&5
37137   ac_status=$?
37138   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37139   (exit $ac_status); }; }; then
37140   ac_hi=$ac_mid; break
37141 else
37142   echo "$as_me: failed program was:" >&5
37143 sed 's/^/| /' conftest.$ac_ext >&5
37144
37145 ac_lo=`expr $ac_mid + 1`
37146                     if test $ac_lo -le $ac_mid; then
37147                       ac_lo= ac_hi=
37148                       break
37149                     fi
37150                     ac_mid=`expr 2 '*' $ac_mid + 1`
37151 fi
37152 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37153   done
37154 else
37155   echo "$as_me: failed program was:" >&5
37156 sed 's/^/| /' conftest.$ac_ext >&5
37157
37158 cat >conftest.$ac_ext <<_ACEOF
37159 /* confdefs.h.  */
37160 _ACEOF
37161 cat confdefs.h >>conftest.$ac_ext
37162 cat >>conftest.$ac_ext <<_ACEOF
37163 /* end confdefs.h.  */
37164 $ac_includes_default
37165 int
37166 main ()
37167 {
37168 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) < 0)];
37169 test_array [0] = 0
37170
37171   ;
37172   return 0;
37173 }
37174 _ACEOF
37175 rm -f conftest.$ac_objext
37176 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37177   (eval $ac_compile) 2>conftest.er1
37178   ac_status=$?
37179   grep -v '^ *+' conftest.er1 >conftest.err
37180   rm -f conftest.er1
37181   cat conftest.err >&5
37182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37183   (exit $ac_status); } &&
37184          { ac_try='test -z "$ac_c_werror_flag"
37185                          || test ! -s conftest.err'
37186   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37187   (eval $ac_try) 2>&5
37188   ac_status=$?
37189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37190   (exit $ac_status); }; } &&
37191          { ac_try='test -s conftest.$ac_objext'
37192   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37193   (eval $ac_try) 2>&5
37194   ac_status=$?
37195   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37196   (exit $ac_status); }; }; then
37197   ac_hi=-1 ac_mid=-1
37198   while :; do
37199     cat >conftest.$ac_ext <<_ACEOF
37200 /* confdefs.h.  */
37201 _ACEOF
37202 cat confdefs.h >>conftest.$ac_ext
37203 cat >>conftest.$ac_ext <<_ACEOF
37204 /* end confdefs.h.  */
37205 $ac_includes_default
37206 int
37207 main ()
37208 {
37209 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= $ac_mid)];
37210 test_array [0] = 0
37211
37212   ;
37213   return 0;
37214 }
37215 _ACEOF
37216 rm -f conftest.$ac_objext
37217 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37218   (eval $ac_compile) 2>conftest.er1
37219   ac_status=$?
37220   grep -v '^ *+' conftest.er1 >conftest.err
37221   rm -f conftest.er1
37222   cat conftest.err >&5
37223   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37224   (exit $ac_status); } &&
37225          { ac_try='test -z "$ac_c_werror_flag"
37226                          || test ! -s conftest.err'
37227   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37228   (eval $ac_try) 2>&5
37229   ac_status=$?
37230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37231   (exit $ac_status); }; } &&
37232          { ac_try='test -s conftest.$ac_objext'
37233   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37234   (eval $ac_try) 2>&5
37235   ac_status=$?
37236   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37237   (exit $ac_status); }; }; then
37238   ac_lo=$ac_mid; break
37239 else
37240   echo "$as_me: failed program was:" >&5
37241 sed 's/^/| /' conftest.$ac_ext >&5
37242
37243 ac_hi=`expr '(' $ac_mid ')' - 1`
37244                        if test $ac_mid -le $ac_hi; then
37245                          ac_lo= ac_hi=
37246                          break
37247                        fi
37248                        ac_mid=`expr 2 '*' $ac_mid`
37249 fi
37250 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37251   done
37252 else
37253   echo "$as_me: failed program was:" >&5
37254 sed 's/^/| /' conftest.$ac_ext >&5
37255
37256 ac_lo= ac_hi=
37257 fi
37258 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37259 fi
37260 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37261 # Binary search between lo and hi bounds.
37262 while test "x$ac_lo" != "x$ac_hi"; do
37263   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
37264   cat >conftest.$ac_ext <<_ACEOF
37265 /* confdefs.h.  */
37266 _ACEOF
37267 cat confdefs.h >>conftest.$ac_ext
37268 cat >>conftest.$ac_ext <<_ACEOF
37269 /* end confdefs.h.  */
37270 $ac_includes_default
37271 int
37272 main ()
37273 {
37274 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
37275 test_array [0] = 0
37276
37277   ;
37278   return 0;
37279 }
37280 _ACEOF
37281 rm -f conftest.$ac_objext
37282 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37283   (eval $ac_compile) 2>conftest.er1
37284   ac_status=$?
37285   grep -v '^ *+' conftest.er1 >conftest.err
37286   rm -f conftest.er1
37287   cat conftest.err >&5
37288   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37289   (exit $ac_status); } &&
37290          { ac_try='test -z "$ac_c_werror_flag"
37291                          || test ! -s conftest.err'
37292   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37293   (eval $ac_try) 2>&5
37294   ac_status=$?
37295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37296   (exit $ac_status); }; } &&
37297          { ac_try='test -s conftest.$ac_objext'
37298   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37299   (eval $ac_try) 2>&5
37300   ac_status=$?
37301   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37302   (exit $ac_status); }; }; then
37303   ac_hi=$ac_mid
37304 else
37305   echo "$as_me: failed program was:" >&5
37306 sed 's/^/| /' conftest.$ac_ext >&5
37307
37308 ac_lo=`expr '(' $ac_mid ')' + 1`
37309 fi
37310 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37311 done
37312 case $ac_lo in
37313 ?*) ac_cv_sizeof_wchar_t=$ac_lo;;
37314 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77
37315 See \`config.log' for more details." >&5
37316 echo "$as_me: error: cannot compute sizeof (wchar_t), 77
37317 See \`config.log' for more details." >&2;}
37318    { (exit 1); exit 1; }; } ;;
37319 esac
37320 else
37321   if test "$cross_compiling" = yes; then
37322   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
37323 See \`config.log' for more details." >&5
37324 echo "$as_me: error: cannot run test program while cross compiling
37325 See \`config.log' for more details." >&2;}
37326    { (exit 1); exit 1; }; }
37327 else
37328   cat >conftest.$ac_ext <<_ACEOF
37329 /* confdefs.h.  */
37330 _ACEOF
37331 cat confdefs.h >>conftest.$ac_ext
37332 cat >>conftest.$ac_ext <<_ACEOF
37333 /* end confdefs.h.  */
37334 $ac_includes_default
37335 long longval () { return (long) (sizeof (wchar_t)); }
37336 unsigned long ulongval () { return (long) (sizeof (wchar_t)); }
37337 #include <stdio.h>
37338 #include <stdlib.h>
37339 int
37340 main ()
37341 {
37342
37343   FILE *f = fopen ("conftest.val", "w");
37344   if (! f)
37345     exit (1);
37346   if (((long) (sizeof (wchar_t))) < 0)
37347     {
37348       long i = longval ();
37349       if (i != ((long) (sizeof (wchar_t))))
37350         exit (1);
37351       fprintf (f, "%ld\n", i);
37352     }
37353   else
37354     {
37355       unsigned long i = ulongval ();
37356       if (i != ((long) (sizeof (wchar_t))))
37357         exit (1);
37358       fprintf (f, "%lu\n", i);
37359     }
37360   exit (ferror (f) || fclose (f) != 0);
37361
37362   ;
37363   return 0;
37364 }
37365 _ACEOF
37366 rm -f conftest$ac_exeext
37367 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37368   (eval $ac_link) 2>&5
37369   ac_status=$?
37370   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37371   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
37372   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37373   (eval $ac_try) 2>&5
37374   ac_status=$?
37375   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37376   (exit $ac_status); }; }; then
37377   ac_cv_sizeof_wchar_t=`cat conftest.val`
37378 else
37379   echo "$as_me: program exited with status $ac_status" >&5
37380 echo "$as_me: failed program was:" >&5
37381 sed 's/^/| /' conftest.$ac_ext >&5
37382
37383 ( exit $ac_status )
37384 { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77
37385 See \`config.log' for more details." >&5
37386 echo "$as_me: error: cannot compute sizeof (wchar_t), 77
37387 See \`config.log' for more details." >&2;}
37388    { (exit 1); exit 1; }; }
37389 fi
37390 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
37391 fi
37392 fi
37393 rm -f conftest.val
37394 else
37395   ac_cv_sizeof_wchar_t=0
37396 fi
37397 fi
37398 echo "$as_me:$LINENO: result: $ac_cv_sizeof_wchar_t" >&5
37399 echo "${ECHO_T}$ac_cv_sizeof_wchar_t" >&6
37400 cat >>confdefs.h <<_ACEOF
37401 #define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t
37402 _ACEOF
37403
37404
37405
37406 if test "$ac_cv_sizeof_int" -lt 4 ; then
37407         { echo "$as_me:$LINENO: WARNING: OpenLDAP requires 'int' to be 32 bits or greater." >&5
37408 echo "$as_me: WARNING: OpenLDAP requires 'int' to be 32 bits or greater." >&2;}
37409
37410
37411 cat >>confdefs.h <<\_ACEOF
37412 #define LBER_INT_T long
37413 _ACEOF
37414
37415 else
37416
37417 cat >>confdefs.h <<\_ACEOF
37418 #define LBER_INT_T int
37419 _ACEOF
37420
37421 fi
37422
37423
37424 cat >>confdefs.h <<\_ACEOF
37425 #define LBER_LEN_T long
37426 _ACEOF
37427
37428
37429 cat >>confdefs.h <<\_ACEOF
37430 #define LBER_SOCKET_T int
37431 _ACEOF
37432
37433
37434 cat >>confdefs.h <<\_ACEOF
37435 #define LBER_TAG_T long
37436 _ACEOF
37437
37438
37439 if test $ol_with_mp = longlong || test $ol_with_mp = auto ; then
37440         if test $ac_cv_sizeof_long_long -gt 4 ; then
37441                 ol_with_mp=longlong
37442
37443 cat >>confdefs.h <<\_ACEOF
37444 #define USE_MP_LONG_LONG 1
37445 _ACEOF
37446
37447         elif test $ol_with_mp = longlong ; then
37448                 { { echo "$as_me:$LINENO: error: long long unusable for multiple precision" >&5
37449 echo "$as_me: error: long long unusable for multiple precision" >&2;}
37450    { (exit 1); exit 1; }; }
37451         fi
37452 fi
37453 if test $ol_with_mp = long || test $ol_with_mp = auto ; then
37454         if test $ac_cv_sizeof_long -gt 4 ; then
37455                 ol_with_mp=long
37456
37457 cat >>confdefs.h <<\_ACEOF
37458 #define USE_MP_LONG 1
37459 _ACEOF
37460
37461         elif test $ol_with_mp = long ; then
37462                 { { echo "$as_me:$LINENO: error: long unusable for multiple precision" >&5
37463 echo "$as_me: error: long unusable for multiple precision" >&2;}
37464    { (exit 1); exit 1; }; }
37465         fi
37466 fi
37467 if test $ol_with_mp = bignum || test $ol_with_mp = auto ; then
37468
37469 for ac_header in openssl/bn.h
37470 do
37471 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
37472 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37473   echo "$as_me:$LINENO: checking for $ac_header" >&5
37474 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37475 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37476   echo $ECHO_N "(cached) $ECHO_C" >&6
37477 fi
37478 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37479 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37480 else
37481   # Is the header compilable?
37482 echo "$as_me:$LINENO: checking $ac_header usability" >&5
37483 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
37484 cat >conftest.$ac_ext <<_ACEOF
37485 /* confdefs.h.  */
37486 _ACEOF
37487 cat confdefs.h >>conftest.$ac_ext
37488 cat >>conftest.$ac_ext <<_ACEOF
37489 /* end confdefs.h.  */
37490 $ac_includes_default
37491 #include <$ac_header>
37492 _ACEOF
37493 rm -f conftest.$ac_objext
37494 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37495   (eval $ac_compile) 2>conftest.er1
37496   ac_status=$?
37497   grep -v '^ *+' conftest.er1 >conftest.err
37498   rm -f conftest.er1
37499   cat conftest.err >&5
37500   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37501   (exit $ac_status); } &&
37502          { ac_try='test -z "$ac_c_werror_flag"
37503                          || test ! -s conftest.err'
37504   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37505   (eval $ac_try) 2>&5
37506   ac_status=$?
37507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37508   (exit $ac_status); }; } &&
37509          { ac_try='test -s conftest.$ac_objext'
37510   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37511   (eval $ac_try) 2>&5
37512   ac_status=$?
37513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37514   (exit $ac_status); }; }; then
37515   ac_header_compiler=yes
37516 else
37517   echo "$as_me: failed program was:" >&5
37518 sed 's/^/| /' conftest.$ac_ext >&5
37519
37520 ac_header_compiler=no
37521 fi
37522 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37523 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
37524 echo "${ECHO_T}$ac_header_compiler" >&6
37525
37526 # Is the header present?
37527 echo "$as_me:$LINENO: checking $ac_header presence" >&5
37528 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
37529 cat >conftest.$ac_ext <<_ACEOF
37530 /* confdefs.h.  */
37531 _ACEOF
37532 cat confdefs.h >>conftest.$ac_ext
37533 cat >>conftest.$ac_ext <<_ACEOF
37534 /* end confdefs.h.  */
37535 #include <$ac_header>
37536 _ACEOF
37537 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
37538   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
37539   ac_status=$?
37540   grep -v '^ *+' conftest.er1 >conftest.err
37541   rm -f conftest.er1
37542   cat conftest.err >&5
37543   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37544   (exit $ac_status); } >/dev/null; then
37545   if test -s conftest.err; then
37546     ac_cpp_err=$ac_c_preproc_warn_flag
37547     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
37548   else
37549     ac_cpp_err=
37550   fi
37551 else
37552   ac_cpp_err=yes
37553 fi
37554 if test -z "$ac_cpp_err"; then
37555   ac_header_preproc=yes
37556 else
37557   echo "$as_me: failed program was:" >&5
37558 sed 's/^/| /' conftest.$ac_ext >&5
37559
37560   ac_header_preproc=no
37561 fi
37562 rm -f conftest.err conftest.$ac_ext
37563 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
37564 echo "${ECHO_T}$ac_header_preproc" >&6
37565
37566 # So?  What about this header?
37567 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
37568   yes:no: )
37569     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
37570 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
37571     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
37572 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
37573     ac_header_preproc=yes
37574     ;;
37575   no:yes:* )
37576     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
37577 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
37578     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
37579 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
37580     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
37581 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
37582     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
37583 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
37584     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
37585 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
37586     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
37587 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
37588     (
37589       cat <<\_ASBOX
37590 ## --------------------------------------------- ##
37591 ## Report this to <http://www.openldap.org/its/> ##
37592 ## --------------------------------------------- ##
37593 _ASBOX
37594     ) |
37595       sed "s/^/$as_me: WARNING:     /" >&2
37596     ;;
37597 esac
37598 echo "$as_me:$LINENO: checking for $ac_header" >&5
37599 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37600 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37601   echo $ECHO_N "(cached) $ECHO_C" >&6
37602 else
37603   eval "$as_ac_Header=\$ac_header_preproc"
37604 fi
37605 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37606 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37607
37608 fi
37609 if test `eval echo '${'$as_ac_Header'}'` = yes; then
37610   cat >>confdefs.h <<_ACEOF
37611 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
37612 _ACEOF
37613
37614 fi
37615
37616 done
37617
37618
37619 for ac_header in openssl/crypto.h
37620 do
37621 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
37622 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37623   echo "$as_me:$LINENO: checking for $ac_header" >&5
37624 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37625 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37626   echo $ECHO_N "(cached) $ECHO_C" >&6
37627 fi
37628 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37629 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37630 else
37631   # Is the header compilable?
37632 echo "$as_me:$LINENO: checking $ac_header usability" >&5
37633 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
37634 cat >conftest.$ac_ext <<_ACEOF
37635 /* confdefs.h.  */
37636 _ACEOF
37637 cat confdefs.h >>conftest.$ac_ext
37638 cat >>conftest.$ac_ext <<_ACEOF
37639 /* end confdefs.h.  */
37640 $ac_includes_default
37641 #include <$ac_header>
37642 _ACEOF
37643 rm -f conftest.$ac_objext
37644 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37645   (eval $ac_compile) 2>conftest.er1
37646   ac_status=$?
37647   grep -v '^ *+' conftest.er1 >conftest.err
37648   rm -f conftest.er1
37649   cat conftest.err >&5
37650   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37651   (exit $ac_status); } &&
37652          { ac_try='test -z "$ac_c_werror_flag"
37653                          || test ! -s conftest.err'
37654   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37655   (eval $ac_try) 2>&5
37656   ac_status=$?
37657   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37658   (exit $ac_status); }; } &&
37659          { ac_try='test -s conftest.$ac_objext'
37660   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37661   (eval $ac_try) 2>&5
37662   ac_status=$?
37663   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37664   (exit $ac_status); }; }; then
37665   ac_header_compiler=yes
37666 else
37667   echo "$as_me: failed program was:" >&5
37668 sed 's/^/| /' conftest.$ac_ext >&5
37669
37670 ac_header_compiler=no
37671 fi
37672 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37673 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
37674 echo "${ECHO_T}$ac_header_compiler" >&6
37675
37676 # Is the header present?
37677 echo "$as_me:$LINENO: checking $ac_header presence" >&5
37678 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
37679 cat >conftest.$ac_ext <<_ACEOF
37680 /* confdefs.h.  */
37681 _ACEOF
37682 cat confdefs.h >>conftest.$ac_ext
37683 cat >>conftest.$ac_ext <<_ACEOF
37684 /* end confdefs.h.  */
37685 #include <$ac_header>
37686 _ACEOF
37687 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
37688   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
37689   ac_status=$?
37690   grep -v '^ *+' conftest.er1 >conftest.err
37691   rm -f conftest.er1
37692   cat conftest.err >&5
37693   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37694   (exit $ac_status); } >/dev/null; then
37695   if test -s conftest.err; then
37696     ac_cpp_err=$ac_c_preproc_warn_flag
37697     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
37698   else
37699     ac_cpp_err=
37700   fi
37701 else
37702   ac_cpp_err=yes
37703 fi
37704 if test -z "$ac_cpp_err"; then
37705   ac_header_preproc=yes
37706 else
37707   echo "$as_me: failed program was:" >&5
37708 sed 's/^/| /' conftest.$ac_ext >&5
37709
37710   ac_header_preproc=no
37711 fi
37712 rm -f conftest.err conftest.$ac_ext
37713 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
37714 echo "${ECHO_T}$ac_header_preproc" >&6
37715
37716 # So?  What about this header?
37717 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
37718   yes:no: )
37719     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
37720 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
37721     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
37722 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
37723     ac_header_preproc=yes
37724     ;;
37725   no:yes:* )
37726     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
37727 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
37728     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
37729 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
37730     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
37731 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
37732     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
37733 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
37734     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
37735 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
37736     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
37737 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
37738     (
37739       cat <<\_ASBOX
37740 ## --------------------------------------------- ##
37741 ## Report this to <http://www.openldap.org/its/> ##
37742 ## --------------------------------------------- ##
37743 _ASBOX
37744     ) |
37745       sed "s/^/$as_me: WARNING:     /" >&2
37746     ;;
37747 esac
37748 echo "$as_me:$LINENO: checking for $ac_header" >&5
37749 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37750 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37751   echo $ECHO_N "(cached) $ECHO_C" >&6
37752 else
37753   eval "$as_ac_Header=\$ac_header_preproc"
37754 fi
37755 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37756 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37757
37758 fi
37759 if test `eval echo '${'$as_ac_Header'}'` = yes; then
37760   cat >>confdefs.h <<_ACEOF
37761 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
37762 _ACEOF
37763
37764 fi
37765
37766 done
37767
37768         if test "$ac_cv_header_openssl_bn_h" = "yes" &&
37769                 test "$ac_cv_header_openssl_crypto_h" = "yes" &&
37770                 test "$ol_with_tls" = "found" ; then
37771                 ol_with_mp=bignum
37772
37773 cat >>confdefs.h <<\_ACEOF
37774 #define USE_MP_BIGNUM 1
37775 _ACEOF
37776
37777         elif test $ol_with_mp = bignum ; then
37778                 { { echo "$as_me:$LINENO: error: bignum not available" >&5
37779 echo "$as_me: error: bignum not available" >&2;}
37780    { (exit 1); exit 1; }; }
37781         fi
37782 fi
37783 if test $ol_with_mp = gmp || test $ol_with_mp = auto ; then
37784
37785 for ac_header in gmp.h
37786 do
37787 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
37788 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37789   echo "$as_me:$LINENO: checking for $ac_header" >&5
37790 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37791 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37792   echo $ECHO_N "(cached) $ECHO_C" >&6
37793 fi
37794 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37795 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37796 else
37797   # Is the header compilable?
37798 echo "$as_me:$LINENO: checking $ac_header usability" >&5
37799 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
37800 cat >conftest.$ac_ext <<_ACEOF
37801 /* confdefs.h.  */
37802 _ACEOF
37803 cat confdefs.h >>conftest.$ac_ext
37804 cat >>conftest.$ac_ext <<_ACEOF
37805 /* end confdefs.h.  */
37806 $ac_includes_default
37807 #include <$ac_header>
37808 _ACEOF
37809 rm -f conftest.$ac_objext
37810 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37811   (eval $ac_compile) 2>conftest.er1
37812   ac_status=$?
37813   grep -v '^ *+' conftest.er1 >conftest.err
37814   rm -f conftest.er1
37815   cat conftest.err >&5
37816   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37817   (exit $ac_status); } &&
37818          { ac_try='test -z "$ac_c_werror_flag"
37819                          || test ! -s conftest.err'
37820   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37821   (eval $ac_try) 2>&5
37822   ac_status=$?
37823   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37824   (exit $ac_status); }; } &&
37825          { ac_try='test -s conftest.$ac_objext'
37826   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37827   (eval $ac_try) 2>&5
37828   ac_status=$?
37829   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37830   (exit $ac_status); }; }; then
37831   ac_header_compiler=yes
37832 else
37833   echo "$as_me: failed program was:" >&5
37834 sed 's/^/| /' conftest.$ac_ext >&5
37835
37836 ac_header_compiler=no
37837 fi
37838 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
37839 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
37840 echo "${ECHO_T}$ac_header_compiler" >&6
37841
37842 # Is the header present?
37843 echo "$as_me:$LINENO: checking $ac_header presence" >&5
37844 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
37845 cat >conftest.$ac_ext <<_ACEOF
37846 /* confdefs.h.  */
37847 _ACEOF
37848 cat confdefs.h >>conftest.$ac_ext
37849 cat >>conftest.$ac_ext <<_ACEOF
37850 /* end confdefs.h.  */
37851 #include <$ac_header>
37852 _ACEOF
37853 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
37854   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
37855   ac_status=$?
37856   grep -v '^ *+' conftest.er1 >conftest.err
37857   rm -f conftest.er1
37858   cat conftest.err >&5
37859   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37860   (exit $ac_status); } >/dev/null; then
37861   if test -s conftest.err; then
37862     ac_cpp_err=$ac_c_preproc_warn_flag
37863     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
37864   else
37865     ac_cpp_err=
37866   fi
37867 else
37868   ac_cpp_err=yes
37869 fi
37870 if test -z "$ac_cpp_err"; then
37871   ac_header_preproc=yes
37872 else
37873   echo "$as_me: failed program was:" >&5
37874 sed 's/^/| /' conftest.$ac_ext >&5
37875
37876   ac_header_preproc=no
37877 fi
37878 rm -f conftest.err conftest.$ac_ext
37879 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
37880 echo "${ECHO_T}$ac_header_preproc" >&6
37881
37882 # So?  What about this header?
37883 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
37884   yes:no: )
37885     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
37886 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
37887     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
37888 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
37889     ac_header_preproc=yes
37890     ;;
37891   no:yes:* )
37892     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
37893 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
37894     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
37895 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
37896     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
37897 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
37898     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
37899 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
37900     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
37901 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
37902     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
37903 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
37904     (
37905       cat <<\_ASBOX
37906 ## --------------------------------------------- ##
37907 ## Report this to <http://www.openldap.org/its/> ##
37908 ## --------------------------------------------- ##
37909 _ASBOX
37910     ) |
37911       sed "s/^/$as_me: WARNING:     /" >&2
37912     ;;
37913 esac
37914 echo "$as_me:$LINENO: checking for $ac_header" >&5
37915 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
37916 if eval "test \"\${$as_ac_Header+set}\" = set"; then
37917   echo $ECHO_N "(cached) $ECHO_C" >&6
37918 else
37919   eval "$as_ac_Header=\$ac_header_preproc"
37920 fi
37921 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
37922 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
37923
37924 fi
37925 if test `eval echo '${'$as_ac_Header'}'` = yes; then
37926   cat >>confdefs.h <<_ACEOF
37927 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
37928 _ACEOF
37929
37930 fi
37931
37932 done
37933
37934
37935 echo "$as_me:$LINENO: checking for __gmpz_add_ui in -lgmp" >&5
37936 echo $ECHO_N "checking for __gmpz_add_ui in -lgmp... $ECHO_C" >&6
37937 if test "${ac_cv_lib_gmp___gmpz_add_ui+set}" = set; then
37938   echo $ECHO_N "(cached) $ECHO_C" >&6
37939 else
37940   ac_check_lib_save_LIBS=$LIBS
37941 LIBS="-lgmp  $LIBS"
37942 cat >conftest.$ac_ext <<_ACEOF
37943 /* confdefs.h.  */
37944 _ACEOF
37945 cat confdefs.h >>conftest.$ac_ext
37946 cat >>conftest.$ac_ext <<_ACEOF
37947 /* end confdefs.h.  */
37948
37949 /* Override any gcc2 internal prototype to avoid an error.  */
37950 #ifdef __cplusplus
37951 extern "C"
37952 #endif
37953 /* We use char because int might match the return type of a gcc2
37954    builtin and then its argument prototype would still apply.  */
37955 char __gmpz_add_ui ();
37956 int
37957 main ()
37958 {
37959 __gmpz_add_ui ();
37960   ;
37961   return 0;
37962 }
37963 _ACEOF
37964 rm -f conftest.$ac_objext conftest$ac_exeext
37965 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37966   (eval $ac_link) 2>conftest.er1
37967   ac_status=$?
37968   grep -v '^ *+' conftest.er1 >conftest.err
37969   rm -f conftest.er1
37970   cat conftest.err >&5
37971   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37972   (exit $ac_status); } &&
37973          { ac_try='test -z "$ac_c_werror_flag"
37974                          || test ! -s conftest.err'
37975   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37976   (eval $ac_try) 2>&5
37977   ac_status=$?
37978   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37979   (exit $ac_status); }; } &&
37980          { ac_try='test -s conftest$ac_exeext'
37981   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37982   (eval $ac_try) 2>&5
37983   ac_status=$?
37984   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37985   (exit $ac_status); }; }; then
37986   ac_cv_lib_gmp___gmpz_add_ui=yes
37987 else
37988   echo "$as_me: failed program was:" >&5
37989 sed 's/^/| /' conftest.$ac_ext >&5
37990
37991 ac_cv_lib_gmp___gmpz_add_ui=no
37992 fi
37993 rm -f conftest.err conftest.$ac_objext \
37994       conftest$ac_exeext conftest.$ac_ext
37995 LIBS=$ac_check_lib_save_LIBS
37996 fi
37997 echo "$as_me:$LINENO: result: $ac_cv_lib_gmp___gmpz_add_ui" >&5
37998 echo "${ECHO_T}$ac_cv_lib_gmp___gmpz_add_ui" >&6
37999 if test $ac_cv_lib_gmp___gmpz_add_ui = yes; then
38000   cat >>confdefs.h <<_ACEOF
38001 #define HAVE_LIBGMP 1
38002 _ACEOF
38003
38004   LIBS="-lgmp $LIBS"
38005
38006 fi
38007
38008         if test $ac_cv_header_gmp_h = yes && test $ac_cv_lib_gmp___gmpz_add_ui = yes ; then
38009
38010 cat >>confdefs.h <<\_ACEOF
38011 #define USE_MP_GMP 1
38012 _ACEOF
38013
38014                 ol_with_mp=gmp
38015         elif test $ol_with_mp = gmp ; then
38016                 { { echo "$as_me:$LINENO: error: gmp not available" >&5
38017 echo "$as_me: error: gmp not available" >&2;}
38018    { (exit 1); exit 1; }; }
38019         fi
38020 fi
38021 if test $ol_with_mp = auto ; then
38022         ol_with_mp=no
38023 fi
38024
38025 echo "$as_me:$LINENO: checking for working memcmp" >&5
38026 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
38027 if test "${ac_cv_func_memcmp_working+set}" = set; then
38028   echo $ECHO_N "(cached) $ECHO_C" >&6
38029 else
38030   if test "$cross_compiling" = yes; then
38031   ac_cv_func_memcmp_working=no
38032 else
38033   cat >conftest.$ac_ext <<_ACEOF
38034 /* confdefs.h.  */
38035 _ACEOF
38036 cat confdefs.h >>conftest.$ac_ext
38037 cat >>conftest.$ac_ext <<_ACEOF
38038 /* end confdefs.h.  */
38039 $ac_includes_default
38040 int
38041 main ()
38042 {
38043
38044   /* Some versions of memcmp are not 8-bit clean.  */
38045   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
38046   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
38047     exit (1);
38048
38049   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
38050      or more and with at least one buffer not starting on a 4-byte boundary.
38051      William Lewis provided this test program.   */
38052   {
38053     char foo[21];
38054     char bar[21];
38055     int i;
38056     for (i = 0; i < 4; i++)
38057       {
38058         char *a = foo + i;
38059         char *b = bar + i;
38060         strcpy (a, "--------01111111");
38061         strcpy (b, "--------10000000");
38062         if (memcmp (a, b, 16) >= 0)
38063           exit (1);
38064       }
38065     exit (0);
38066   }
38067
38068   ;
38069   return 0;
38070 }
38071 _ACEOF
38072 rm -f conftest$ac_exeext
38073 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38074   (eval $ac_link) 2>&5
38075   ac_status=$?
38076   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38077   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
38078   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38079   (eval $ac_try) 2>&5
38080   ac_status=$?
38081   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38082   (exit $ac_status); }; }; then
38083   ac_cv_func_memcmp_working=yes
38084 else
38085   echo "$as_me: program exited with status $ac_status" >&5
38086 echo "$as_me: failed program was:" >&5
38087 sed 's/^/| /' conftest.$ac_ext >&5
38088
38089 ( exit $ac_status )
38090 ac_cv_func_memcmp_working=no
38091 fi
38092 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
38093 fi
38094 fi
38095 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
38096 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
38097 test $ac_cv_func_memcmp_working = no && case $LIBOBJS in
38098     "memcmp.$ac_objext"   | \
38099   *" memcmp.$ac_objext"   | \
38100     "memcmp.$ac_objext "* | \
38101   *" memcmp.$ac_objext "* ) ;;
38102   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext" ;;
38103 esac
38104
38105
38106
38107 if test $ac_cv_func_memcmp_working = no ; then
38108
38109 cat >>confdefs.h <<\_ACEOF
38110 #define NEED_MEMCMP_REPLACEMENT 1
38111 _ACEOF
38112
38113 fi
38114
38115
38116 for ac_func in strftime
38117 do
38118 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
38119 echo "$as_me:$LINENO: checking for $ac_func" >&5
38120 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
38121 if eval "test \"\${$as_ac_var+set}\" = set"; then
38122   echo $ECHO_N "(cached) $ECHO_C" >&6
38123 else
38124   cat >conftest.$ac_ext <<_ACEOF
38125 /* confdefs.h.  */
38126 _ACEOF
38127 cat confdefs.h >>conftest.$ac_ext
38128 cat >>conftest.$ac_ext <<_ACEOF
38129 /* end confdefs.h.  */
38130 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
38131    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38132 #define $ac_func innocuous_$ac_func
38133
38134 /* System header to define __stub macros and hopefully few prototypes,
38135     which can conflict with char $ac_func (); below.
38136     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38137     <limits.h> exists even on freestanding compilers.  */
38138
38139 #ifdef __STDC__
38140 # include <limits.h>
38141 #else
38142 # include <assert.h>
38143 #endif
38144
38145 #undef $ac_func
38146
38147 /* Override any gcc2 internal prototype to avoid an error.  */
38148 #ifdef __cplusplus
38149 extern "C"
38150 {
38151 #endif
38152 /* We use char because int might match the return type of a gcc2
38153    builtin and then its argument prototype would still apply.  */
38154 char $ac_func ();
38155 /* The GNU C library defines this for functions which it implements
38156     to always fail with ENOSYS.  Some functions are actually named
38157     something starting with __ and the normal name is an alias.  */
38158 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
38159 choke me
38160 #else
38161 char (*f) () = $ac_func;
38162 #endif
38163 #ifdef __cplusplus
38164 }
38165 #endif
38166
38167 int
38168 main ()
38169 {
38170 return f != $ac_func;
38171   ;
38172   return 0;
38173 }
38174 _ACEOF
38175 rm -f conftest.$ac_objext conftest$ac_exeext
38176 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38177   (eval $ac_link) 2>conftest.er1
38178   ac_status=$?
38179   grep -v '^ *+' conftest.er1 >conftest.err
38180   rm -f conftest.er1
38181   cat conftest.err >&5
38182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38183   (exit $ac_status); } &&
38184          { ac_try='test -z "$ac_c_werror_flag"
38185                          || test ! -s conftest.err'
38186   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38187   (eval $ac_try) 2>&5
38188   ac_status=$?
38189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38190   (exit $ac_status); }; } &&
38191          { ac_try='test -s conftest$ac_exeext'
38192   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38193   (eval $ac_try) 2>&5
38194   ac_status=$?
38195   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38196   (exit $ac_status); }; }; then
38197   eval "$as_ac_var=yes"
38198 else
38199   echo "$as_me: failed program was:" >&5
38200 sed 's/^/| /' conftest.$ac_ext >&5
38201
38202 eval "$as_ac_var=no"
38203 fi
38204 rm -f conftest.err conftest.$ac_objext \
38205       conftest$ac_exeext conftest.$ac_ext
38206 fi
38207 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
38208 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
38209 if test `eval echo '${'$as_ac_var'}'` = yes; then
38210   cat >>confdefs.h <<_ACEOF
38211 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
38212 _ACEOF
38213
38214 else
38215   # strftime is in -lintl on SCO UNIX.
38216 echo "$as_me:$LINENO: checking for strftime in -lintl" >&5
38217 echo $ECHO_N "checking for strftime in -lintl... $ECHO_C" >&6
38218 if test "${ac_cv_lib_intl_strftime+set}" = set; then
38219   echo $ECHO_N "(cached) $ECHO_C" >&6
38220 else
38221   ac_check_lib_save_LIBS=$LIBS
38222 LIBS="-lintl  $LIBS"
38223 cat >conftest.$ac_ext <<_ACEOF
38224 /* confdefs.h.  */
38225 _ACEOF
38226 cat confdefs.h >>conftest.$ac_ext
38227 cat >>conftest.$ac_ext <<_ACEOF
38228 /* end confdefs.h.  */
38229
38230 /* Override any gcc2 internal prototype to avoid an error.  */
38231 #ifdef __cplusplus
38232 extern "C"
38233 #endif
38234 /* We use char because int might match the return type of a gcc2
38235    builtin and then its argument prototype would still apply.  */
38236 char strftime ();
38237 int
38238 main ()
38239 {
38240 strftime ();
38241   ;
38242   return 0;
38243 }
38244 _ACEOF
38245 rm -f conftest.$ac_objext conftest$ac_exeext
38246 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38247   (eval $ac_link) 2>conftest.er1
38248   ac_status=$?
38249   grep -v '^ *+' conftest.er1 >conftest.err
38250   rm -f conftest.er1
38251   cat conftest.err >&5
38252   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38253   (exit $ac_status); } &&
38254          { ac_try='test -z "$ac_c_werror_flag"
38255                          || test ! -s conftest.err'
38256   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38257   (eval $ac_try) 2>&5
38258   ac_status=$?
38259   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38260   (exit $ac_status); }; } &&
38261          { ac_try='test -s conftest$ac_exeext'
38262   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38263   (eval $ac_try) 2>&5
38264   ac_status=$?
38265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38266   (exit $ac_status); }; }; then
38267   ac_cv_lib_intl_strftime=yes
38268 else
38269   echo "$as_me: failed program was:" >&5
38270 sed 's/^/| /' conftest.$ac_ext >&5
38271
38272 ac_cv_lib_intl_strftime=no
38273 fi
38274 rm -f conftest.err conftest.$ac_objext \
38275       conftest$ac_exeext conftest.$ac_ext
38276 LIBS=$ac_check_lib_save_LIBS
38277 fi
38278 echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5
38279 echo "${ECHO_T}$ac_cv_lib_intl_strftime" >&6
38280 if test $ac_cv_lib_intl_strftime = yes; then
38281   cat >>confdefs.h <<\_ACEOF
38282 #define HAVE_STRFTIME 1
38283 _ACEOF
38284
38285 LIBS="-lintl $LIBS"
38286 fi
38287
38288 fi
38289 done
38290
38291
38292 echo "$as_me:$LINENO: checking for inet_aton()" >&5
38293 echo $ECHO_N "checking for inet_aton()... $ECHO_C" >&6
38294 if test "${ol_cv_func_inet_aton+set}" = set; then
38295   echo $ECHO_N "(cached) $ECHO_C" >&6
38296 else
38297   cat >conftest.$ac_ext <<_ACEOF
38298 /* confdefs.h.  */
38299 _ACEOF
38300 cat confdefs.h >>conftest.$ac_ext
38301 cat >>conftest.$ac_ext <<_ACEOF
38302 /* end confdefs.h.  */
38303
38304 #ifdef HAVE_SYS_TYPES_H
38305 #       include <sys/types.h>
38306 #endif
38307 #ifdef HAVE_SYS_SOCKET_H
38308 #       include <sys/socket.h>
38309 #       ifdef HAVE_SYS_SELECT_H
38310 #               include <sys/select.h>
38311 #       endif
38312 #       include <netinet/in.h>
38313 #       ifdef HAVE_ARPA_INET_H
38314 #               include <arpa/inet.h>
38315 #       endif
38316 #endif
38317
38318 int
38319 main ()
38320 {
38321 struct in_addr in;
38322 int rc = inet_aton( "255.255.255.255", &in );
38323   ;
38324   return 0;
38325 }
38326 _ACEOF
38327 rm -f conftest.$ac_objext conftest$ac_exeext
38328 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38329   (eval $ac_link) 2>conftest.er1
38330   ac_status=$?
38331   grep -v '^ *+' conftest.er1 >conftest.err
38332   rm -f conftest.er1
38333   cat conftest.err >&5
38334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38335   (exit $ac_status); } &&
38336          { ac_try='test -z "$ac_c_werror_flag"
38337                          || test ! -s conftest.err'
38338   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38339   (eval $ac_try) 2>&5
38340   ac_status=$?
38341   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38342   (exit $ac_status); }; } &&
38343          { ac_try='test -s conftest$ac_exeext'
38344   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38345   (eval $ac_try) 2>&5
38346   ac_status=$?
38347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38348   (exit $ac_status); }; }; then
38349   ol_cv_func_inet_aton=yes
38350 else
38351   echo "$as_me: failed program was:" >&5
38352 sed 's/^/| /' conftest.$ac_ext >&5
38353
38354 ol_cv_func_inet_aton=no
38355 fi
38356 rm -f conftest.err conftest.$ac_objext \
38357       conftest$ac_exeext conftest.$ac_ext
38358 fi
38359 echo "$as_me:$LINENO: result: $ol_cv_func_inet_aton" >&5
38360 echo "${ECHO_T}$ol_cv_func_inet_aton" >&6
38361   if test $ol_cv_func_inet_aton != no; then
38362
38363 cat >>confdefs.h <<\_ACEOF
38364 #define HAVE_INET_ATON 1
38365 _ACEOF
38366
38367   fi
38368
38369
38370 echo "$as_me:$LINENO: checking for _spawnlp" >&5
38371 echo $ECHO_N "checking for _spawnlp... $ECHO_C" >&6
38372 if test "${ac_cv_func__spawnlp+set}" = set; then
38373   echo $ECHO_N "(cached) $ECHO_C" >&6
38374 else
38375   cat >conftest.$ac_ext <<_ACEOF
38376 /* confdefs.h.  */
38377 _ACEOF
38378 cat confdefs.h >>conftest.$ac_ext
38379 cat >>conftest.$ac_ext <<_ACEOF
38380 /* end confdefs.h.  */
38381 /* Define _spawnlp to an innocuous variant, in case <limits.h> declares _spawnlp.
38382    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38383 #define _spawnlp innocuous__spawnlp
38384
38385 /* System header to define __stub macros and hopefully few prototypes,
38386     which can conflict with char _spawnlp (); below.
38387     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38388     <limits.h> exists even on freestanding compilers.  */
38389
38390 #ifdef __STDC__
38391 # include <limits.h>
38392 #else
38393 # include <assert.h>
38394 #endif
38395
38396 #undef _spawnlp
38397
38398 /* Override any gcc2 internal prototype to avoid an error.  */
38399 #ifdef __cplusplus
38400 extern "C"
38401 {
38402 #endif
38403 /* We use char because int might match the return type of a gcc2
38404    builtin and then its argument prototype would still apply.  */
38405 char _spawnlp ();
38406 /* The GNU C library defines this for functions which it implements
38407     to always fail with ENOSYS.  Some functions are actually named
38408     something starting with __ and the normal name is an alias.  */
38409 #if defined (__stub__spawnlp) || defined (__stub____spawnlp)
38410 choke me
38411 #else
38412 char (*f) () = _spawnlp;
38413 #endif
38414 #ifdef __cplusplus
38415 }
38416 #endif
38417
38418 int
38419 main ()
38420 {
38421 return f != _spawnlp;
38422   ;
38423   return 0;
38424 }
38425 _ACEOF
38426 rm -f conftest.$ac_objext conftest$ac_exeext
38427 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38428   (eval $ac_link) 2>conftest.er1
38429   ac_status=$?
38430   grep -v '^ *+' conftest.er1 >conftest.err
38431   rm -f conftest.er1
38432   cat conftest.err >&5
38433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38434   (exit $ac_status); } &&
38435          { ac_try='test -z "$ac_c_werror_flag"
38436                          || test ! -s conftest.err'
38437   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38438   (eval $ac_try) 2>&5
38439   ac_status=$?
38440   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38441   (exit $ac_status); }; } &&
38442          { ac_try='test -s conftest$ac_exeext'
38443   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38444   (eval $ac_try) 2>&5
38445   ac_status=$?
38446   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38447   (exit $ac_status); }; }; then
38448   ac_cv_func__spawnlp=yes
38449 else
38450   echo "$as_me: failed program was:" >&5
38451 sed 's/^/| /' conftest.$ac_ext >&5
38452
38453 ac_cv_func__spawnlp=no
38454 fi
38455 rm -f conftest.err conftest.$ac_objext \
38456       conftest$ac_exeext conftest.$ac_ext
38457 fi
38458 echo "$as_me:$LINENO: result: $ac_cv_func__spawnlp" >&5
38459 echo "${ECHO_T}$ac_cv_func__spawnlp" >&6
38460 if test $ac_cv_func__spawnlp = yes; then
38461
38462 cat >>confdefs.h <<\_ACEOF
38463 #define HAVE_SPAWNLP 1
38464 _ACEOF
38465
38466 fi
38467
38468
38469 echo "$as_me:$LINENO: checking for _snprintf" >&5
38470 echo $ECHO_N "checking for _snprintf... $ECHO_C" >&6
38471 if test "${ac_cv_func__snprintf+set}" = set; then
38472   echo $ECHO_N "(cached) $ECHO_C" >&6
38473 else
38474   cat >conftest.$ac_ext <<_ACEOF
38475 /* confdefs.h.  */
38476 _ACEOF
38477 cat confdefs.h >>conftest.$ac_ext
38478 cat >>conftest.$ac_ext <<_ACEOF
38479 /* end confdefs.h.  */
38480 /* Define _snprintf to an innocuous variant, in case <limits.h> declares _snprintf.
38481    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38482 #define _snprintf innocuous__snprintf
38483
38484 /* System header to define __stub macros and hopefully few prototypes,
38485     which can conflict with char _snprintf (); below.
38486     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38487     <limits.h> exists even on freestanding compilers.  */
38488
38489 #ifdef __STDC__
38490 # include <limits.h>
38491 #else
38492 # include <assert.h>
38493 #endif
38494
38495 #undef _snprintf
38496
38497 /* Override any gcc2 internal prototype to avoid an error.  */
38498 #ifdef __cplusplus
38499 extern "C"
38500 {
38501 #endif
38502 /* We use char because int might match the return type of a gcc2
38503    builtin and then its argument prototype would still apply.  */
38504 char _snprintf ();
38505 /* The GNU C library defines this for functions which it implements
38506     to always fail with ENOSYS.  Some functions are actually named
38507     something starting with __ and the normal name is an alias.  */
38508 #if defined (__stub__snprintf) || defined (__stub____snprintf)
38509 choke me
38510 #else
38511 char (*f) () = _snprintf;
38512 #endif
38513 #ifdef __cplusplus
38514 }
38515 #endif
38516
38517 int
38518 main ()
38519 {
38520 return f != _snprintf;
38521   ;
38522   return 0;
38523 }
38524 _ACEOF
38525 rm -f conftest.$ac_objext conftest$ac_exeext
38526 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38527   (eval $ac_link) 2>conftest.er1
38528   ac_status=$?
38529   grep -v '^ *+' conftest.er1 >conftest.err
38530   rm -f conftest.er1
38531   cat conftest.err >&5
38532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38533   (exit $ac_status); } &&
38534          { ac_try='test -z "$ac_c_werror_flag"
38535                          || test ! -s conftest.err'
38536   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38537   (eval $ac_try) 2>&5
38538   ac_status=$?
38539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38540   (exit $ac_status); }; } &&
38541          { ac_try='test -s conftest$ac_exeext'
38542   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38543   (eval $ac_try) 2>&5
38544   ac_status=$?
38545   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38546   (exit $ac_status); }; }; then
38547   ac_cv_func__snprintf=yes
38548 else
38549   echo "$as_me: failed program was:" >&5
38550 sed 's/^/| /' conftest.$ac_ext >&5
38551
38552 ac_cv_func__snprintf=no
38553 fi
38554 rm -f conftest.err conftest.$ac_objext \
38555       conftest$ac_exeext conftest.$ac_ext
38556 fi
38557 echo "$as_me:$LINENO: result: $ac_cv_func__snprintf" >&5
38558 echo "${ECHO_T}$ac_cv_func__snprintf" >&6
38559 if test $ac_cv_func__snprintf = yes; then
38560   ac_cv_func_snprintf=yes
38561
38562 cat >>confdefs.h <<\_ACEOF
38563 #define snprintf _snprintf
38564 _ACEOF
38565
38566
38567 fi
38568
38569
38570 echo "$as_me:$LINENO: checking for _vsnprintf" >&5
38571 echo $ECHO_N "checking for _vsnprintf... $ECHO_C" >&6
38572 if test "${ac_cv_func__vsnprintf+set}" = set; then
38573   echo $ECHO_N "(cached) $ECHO_C" >&6
38574 else
38575   cat >conftest.$ac_ext <<_ACEOF
38576 /* confdefs.h.  */
38577 _ACEOF
38578 cat confdefs.h >>conftest.$ac_ext
38579 cat >>conftest.$ac_ext <<_ACEOF
38580 /* end confdefs.h.  */
38581 /* Define _vsnprintf to an innocuous variant, in case <limits.h> declares _vsnprintf.
38582    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38583 #define _vsnprintf innocuous__vsnprintf
38584
38585 /* System header to define __stub macros and hopefully few prototypes,
38586     which can conflict with char _vsnprintf (); below.
38587     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38588     <limits.h> exists even on freestanding compilers.  */
38589
38590 #ifdef __STDC__
38591 # include <limits.h>
38592 #else
38593 # include <assert.h>
38594 #endif
38595
38596 #undef _vsnprintf
38597
38598 /* Override any gcc2 internal prototype to avoid an error.  */
38599 #ifdef __cplusplus
38600 extern "C"
38601 {
38602 #endif
38603 /* We use char because int might match the return type of a gcc2
38604    builtin and then its argument prototype would still apply.  */
38605 char _vsnprintf ();
38606 /* The GNU C library defines this for functions which it implements
38607     to always fail with ENOSYS.  Some functions are actually named
38608     something starting with __ and the normal name is an alias.  */
38609 #if defined (__stub__vsnprintf) || defined (__stub____vsnprintf)
38610 choke me
38611 #else
38612 char (*f) () = _vsnprintf;
38613 #endif
38614 #ifdef __cplusplus
38615 }
38616 #endif
38617
38618 int
38619 main ()
38620 {
38621 return f != _vsnprintf;
38622   ;
38623   return 0;
38624 }
38625 _ACEOF
38626 rm -f conftest.$ac_objext conftest$ac_exeext
38627 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38628   (eval $ac_link) 2>conftest.er1
38629   ac_status=$?
38630   grep -v '^ *+' conftest.er1 >conftest.err
38631   rm -f conftest.er1
38632   cat conftest.err >&5
38633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38634   (exit $ac_status); } &&
38635          { ac_try='test -z "$ac_c_werror_flag"
38636                          || test ! -s conftest.err'
38637   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38638   (eval $ac_try) 2>&5
38639   ac_status=$?
38640   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38641   (exit $ac_status); }; } &&
38642          { ac_try='test -s conftest$ac_exeext'
38643   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38644   (eval $ac_try) 2>&5
38645   ac_status=$?
38646   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38647   (exit $ac_status); }; }; then
38648   ac_cv_func__vsnprintf=yes
38649 else
38650   echo "$as_me: failed program was:" >&5
38651 sed 's/^/| /' conftest.$ac_ext >&5
38652
38653 ac_cv_func__vsnprintf=no
38654 fi
38655 rm -f conftest.err conftest.$ac_objext \
38656       conftest$ac_exeext conftest.$ac_ext
38657 fi
38658 echo "$as_me:$LINENO: result: $ac_cv_func__vsnprintf" >&5
38659 echo "${ECHO_T}$ac_cv_func__vsnprintf" >&6
38660 if test $ac_cv_func__vsnprintf = yes; then
38661   ac_cv_func_vsnprintf=yes
38662
38663 cat >>confdefs.h <<\_ACEOF
38664 #define vsnprintf _vsnprintf
38665 _ACEOF
38666
38667
38668 fi
38669
38670
38671
38672 for ac_func in vprintf
38673 do
38674 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
38675 echo "$as_me:$LINENO: checking for $ac_func" >&5
38676 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
38677 if eval "test \"\${$as_ac_var+set}\" = set"; then
38678   echo $ECHO_N "(cached) $ECHO_C" >&6
38679 else
38680   cat >conftest.$ac_ext <<_ACEOF
38681 /* confdefs.h.  */
38682 _ACEOF
38683 cat confdefs.h >>conftest.$ac_ext
38684 cat >>conftest.$ac_ext <<_ACEOF
38685 /* end confdefs.h.  */
38686 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
38687    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38688 #define $ac_func innocuous_$ac_func
38689
38690 /* System header to define __stub macros and hopefully few prototypes,
38691     which can conflict with char $ac_func (); below.
38692     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38693     <limits.h> exists even on freestanding compilers.  */
38694
38695 #ifdef __STDC__
38696 # include <limits.h>
38697 #else
38698 # include <assert.h>
38699 #endif
38700
38701 #undef $ac_func
38702
38703 /* Override any gcc2 internal prototype to avoid an error.  */
38704 #ifdef __cplusplus
38705 extern "C"
38706 {
38707 #endif
38708 /* We use char because int might match the return type of a gcc2
38709    builtin and then its argument prototype would still apply.  */
38710 char $ac_func ();
38711 /* The GNU C library defines this for functions which it implements
38712     to always fail with ENOSYS.  Some functions are actually named
38713     something starting with __ and the normal name is an alias.  */
38714 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
38715 choke me
38716 #else
38717 char (*f) () = $ac_func;
38718 #endif
38719 #ifdef __cplusplus
38720 }
38721 #endif
38722
38723 int
38724 main ()
38725 {
38726 return f != $ac_func;
38727   ;
38728   return 0;
38729 }
38730 _ACEOF
38731 rm -f conftest.$ac_objext conftest$ac_exeext
38732 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38733   (eval $ac_link) 2>conftest.er1
38734   ac_status=$?
38735   grep -v '^ *+' conftest.er1 >conftest.err
38736   rm -f conftest.er1
38737   cat conftest.err >&5
38738   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38739   (exit $ac_status); } &&
38740          { ac_try='test -z "$ac_c_werror_flag"
38741                          || test ! -s conftest.err'
38742   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38743   (eval $ac_try) 2>&5
38744   ac_status=$?
38745   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38746   (exit $ac_status); }; } &&
38747          { ac_try='test -s conftest$ac_exeext'
38748   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38749   (eval $ac_try) 2>&5
38750   ac_status=$?
38751   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38752   (exit $ac_status); }; }; then
38753   eval "$as_ac_var=yes"
38754 else
38755   echo "$as_me: failed program was:" >&5
38756 sed 's/^/| /' conftest.$ac_ext >&5
38757
38758 eval "$as_ac_var=no"
38759 fi
38760 rm -f conftest.err conftest.$ac_objext \
38761       conftest$ac_exeext conftest.$ac_ext
38762 fi
38763 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
38764 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
38765 if test `eval echo '${'$as_ac_var'}'` = yes; then
38766   cat >>confdefs.h <<_ACEOF
38767 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
38768 _ACEOF
38769
38770 echo "$as_me:$LINENO: checking for _doprnt" >&5
38771 echo $ECHO_N "checking for _doprnt... $ECHO_C" >&6
38772 if test "${ac_cv_func__doprnt+set}" = set; then
38773   echo $ECHO_N "(cached) $ECHO_C" >&6
38774 else
38775   cat >conftest.$ac_ext <<_ACEOF
38776 /* confdefs.h.  */
38777 _ACEOF
38778 cat confdefs.h >>conftest.$ac_ext
38779 cat >>conftest.$ac_ext <<_ACEOF
38780 /* end confdefs.h.  */
38781 /* Define _doprnt to an innocuous variant, in case <limits.h> declares _doprnt.
38782    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38783 #define _doprnt innocuous__doprnt
38784
38785 /* System header to define __stub macros and hopefully few prototypes,
38786     which can conflict with char _doprnt (); below.
38787     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38788     <limits.h> exists even on freestanding compilers.  */
38789
38790 #ifdef __STDC__
38791 # include <limits.h>
38792 #else
38793 # include <assert.h>
38794 #endif
38795
38796 #undef _doprnt
38797
38798 /* Override any gcc2 internal prototype to avoid an error.  */
38799 #ifdef __cplusplus
38800 extern "C"
38801 {
38802 #endif
38803 /* We use char because int might match the return type of a gcc2
38804    builtin and then its argument prototype would still apply.  */
38805 char _doprnt ();
38806 /* The GNU C library defines this for functions which it implements
38807     to always fail with ENOSYS.  Some functions are actually named
38808     something starting with __ and the normal name is an alias.  */
38809 #if defined (__stub__doprnt) || defined (__stub____doprnt)
38810 choke me
38811 #else
38812 char (*f) () = _doprnt;
38813 #endif
38814 #ifdef __cplusplus
38815 }
38816 #endif
38817
38818 int
38819 main ()
38820 {
38821 return f != _doprnt;
38822   ;
38823   return 0;
38824 }
38825 _ACEOF
38826 rm -f conftest.$ac_objext conftest$ac_exeext
38827 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38828   (eval $ac_link) 2>conftest.er1
38829   ac_status=$?
38830   grep -v '^ *+' conftest.er1 >conftest.err
38831   rm -f conftest.er1
38832   cat conftest.err >&5
38833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38834   (exit $ac_status); } &&
38835          { ac_try='test -z "$ac_c_werror_flag"
38836                          || test ! -s conftest.err'
38837   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38838   (eval $ac_try) 2>&5
38839   ac_status=$?
38840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38841   (exit $ac_status); }; } &&
38842          { ac_try='test -s conftest$ac_exeext'
38843   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38844   (eval $ac_try) 2>&5
38845   ac_status=$?
38846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38847   (exit $ac_status); }; }; then
38848   ac_cv_func__doprnt=yes
38849 else
38850   echo "$as_me: failed program was:" >&5
38851 sed 's/^/| /' conftest.$ac_ext >&5
38852
38853 ac_cv_func__doprnt=no
38854 fi
38855 rm -f conftest.err conftest.$ac_objext \
38856       conftest$ac_exeext conftest.$ac_ext
38857 fi
38858 echo "$as_me:$LINENO: result: $ac_cv_func__doprnt" >&5
38859 echo "${ECHO_T}$ac_cv_func__doprnt" >&6
38860 if test $ac_cv_func__doprnt = yes; then
38861
38862 cat >>confdefs.h <<\_ACEOF
38863 #define HAVE_DOPRNT 1
38864 _ACEOF
38865
38866 fi
38867
38868 fi
38869 done
38870
38871
38872
38873 if test $ac_cv_func_vprintf = yes ; then
38874
38875
38876 for ac_func in snprintf vsnprintf
38877 do
38878 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
38879 echo "$as_me:$LINENO: checking for $ac_func" >&5
38880 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
38881 if eval "test \"\${$as_ac_var+set}\" = set"; then
38882   echo $ECHO_N "(cached) $ECHO_C" >&6
38883 else
38884   cat >conftest.$ac_ext <<_ACEOF
38885 /* confdefs.h.  */
38886 _ACEOF
38887 cat confdefs.h >>conftest.$ac_ext
38888 cat >>conftest.$ac_ext <<_ACEOF
38889 /* end confdefs.h.  */
38890 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
38891    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
38892 #define $ac_func innocuous_$ac_func
38893
38894 /* System header to define __stub macros and hopefully few prototypes,
38895     which can conflict with char $ac_func (); below.
38896     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
38897     <limits.h> exists even on freestanding compilers.  */
38898
38899 #ifdef __STDC__
38900 # include <limits.h>
38901 #else
38902 # include <assert.h>
38903 #endif
38904
38905 #undef $ac_func
38906
38907 /* Override any gcc2 internal prototype to avoid an error.  */
38908 #ifdef __cplusplus
38909 extern "C"
38910 {
38911 #endif
38912 /* We use char because int might match the return type of a gcc2
38913    builtin and then its argument prototype would still apply.  */
38914 char $ac_func ();
38915 /* The GNU C library defines this for functions which it implements
38916     to always fail with ENOSYS.  Some functions are actually named
38917     something starting with __ and the normal name is an alias.  */
38918 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
38919 choke me
38920 #else
38921 char (*f) () = $ac_func;
38922 #endif
38923 #ifdef __cplusplus
38924 }
38925 #endif
38926
38927 int
38928 main ()
38929 {
38930 return f != $ac_func;
38931   ;
38932   return 0;
38933 }
38934 _ACEOF
38935 rm -f conftest.$ac_objext conftest$ac_exeext
38936 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38937   (eval $ac_link) 2>conftest.er1
38938   ac_status=$?
38939   grep -v '^ *+' conftest.er1 >conftest.err
38940   rm -f conftest.er1
38941   cat conftest.err >&5
38942   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38943   (exit $ac_status); } &&
38944          { ac_try='test -z "$ac_c_werror_flag"
38945                          || test ! -s conftest.err'
38946   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38947   (eval $ac_try) 2>&5
38948   ac_status=$?
38949   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38950   (exit $ac_status); }; } &&
38951          { ac_try='test -s conftest$ac_exeext'
38952   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38953   (eval $ac_try) 2>&5
38954   ac_status=$?
38955   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38956   (exit $ac_status); }; }; then
38957   eval "$as_ac_var=yes"
38958 else
38959   echo "$as_me: failed program was:" >&5
38960 sed 's/^/| /' conftest.$ac_ext >&5
38961
38962 eval "$as_ac_var=no"
38963 fi
38964 rm -f conftest.err conftest.$ac_objext \
38965       conftest$ac_exeext conftest.$ac_ext
38966 fi
38967 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
38968 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
38969 if test `eval echo '${'$as_ac_var'}'` = yes; then
38970   cat >>confdefs.h <<_ACEOF
38971 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
38972 _ACEOF
38973
38974 fi
38975 done
38976
38977 fi
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
39008
39009
39010
39011
39012
39013
39014
39015
39016
39017
39018
39019
39020
39021
39022
39023
39024
39025
39026
39027
39028
39029
39030
39031
39032
39033
39034 for ac_func in \
39035         bcopy                   \
39036         closesocket             \
39037         chroot                  \
39038         endgrent                \
39039         endpwent                \
39040         fcntl                   \
39041         flock                   \
39042         fstat                   \
39043         getdtablesize           \
39044         getgrgid                \
39045         gethostname             \
39046         getpass                 \
39047         getpassphrase           \
39048         getpwuid                \
39049         getpwnam                \
39050         getspnam                \
39051         gettimeofday            \
39052         initgroups              \
39053         inet_ntoa_b             \
39054         ioctl                   \
39055         lockf                   \
39056         memcpy                  \
39057         memmove                 \
39058         memrchr                 \
39059         mkstemp                 \
39060         mktemp                  \
39061         pipe                    \
39062         read                    \
39063         recv                    \
39064         recvfrom                \
39065         setpwfile               \
39066         setgid                  \
39067         setegid                 \
39068         setsid                  \
39069         setuid                  \
39070         seteuid                 \
39071         signal                  \
39072         strdup                  \
39073         strpbrk                 \
39074         strrchr                 \
39075         strsep                  \
39076         strstr                  \
39077         strtol                  \
39078         strtoul                 \
39079         strtoq                  \
39080         strtouq                 \
39081         strtoll                 \
39082         strspn                  \
39083         sysconf                 \
39084         waitpid                 \
39085         wait4                   \
39086         write                   \
39087         send                    \
39088         sendmsg                 \
39089         sendto                  \
39090
39091 do
39092 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
39093 echo "$as_me:$LINENO: checking for $ac_func" >&5
39094 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
39095 if eval "test \"\${$as_ac_var+set}\" = set"; then
39096   echo $ECHO_N "(cached) $ECHO_C" >&6
39097 else
39098   cat >conftest.$ac_ext <<_ACEOF
39099 /* confdefs.h.  */
39100 _ACEOF
39101 cat confdefs.h >>conftest.$ac_ext
39102 cat >>conftest.$ac_ext <<_ACEOF
39103 /* end confdefs.h.  */
39104 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
39105    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
39106 #define $ac_func innocuous_$ac_func
39107
39108 /* System header to define __stub macros and hopefully few prototypes,
39109     which can conflict with char $ac_func (); below.
39110     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
39111     <limits.h> exists even on freestanding compilers.  */
39112
39113 #ifdef __STDC__
39114 # include <limits.h>
39115 #else
39116 # include <assert.h>
39117 #endif
39118
39119 #undef $ac_func
39120
39121 /* Override any gcc2 internal prototype to avoid an error.  */
39122 #ifdef __cplusplus
39123 extern "C"
39124 {
39125 #endif
39126 /* We use char because int might match the return type of a gcc2
39127    builtin and then its argument prototype would still apply.  */
39128 char $ac_func ();
39129 /* The GNU C library defines this for functions which it implements
39130     to always fail with ENOSYS.  Some functions are actually named
39131     something starting with __ and the normal name is an alias.  */
39132 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
39133 choke me
39134 #else
39135 char (*f) () = $ac_func;
39136 #endif
39137 #ifdef __cplusplus
39138 }
39139 #endif
39140
39141 int
39142 main ()
39143 {
39144 return f != $ac_func;
39145   ;
39146   return 0;
39147 }
39148 _ACEOF
39149 rm -f conftest.$ac_objext conftest$ac_exeext
39150 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
39151   (eval $ac_link) 2>conftest.er1
39152   ac_status=$?
39153   grep -v '^ *+' conftest.er1 >conftest.err
39154   rm -f conftest.er1
39155   cat conftest.err >&5
39156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39157   (exit $ac_status); } &&
39158          { ac_try='test -z "$ac_c_werror_flag"
39159                          || test ! -s conftest.err'
39160   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39161   (eval $ac_try) 2>&5
39162   ac_status=$?
39163   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39164   (exit $ac_status); }; } &&
39165          { ac_try='test -s conftest$ac_exeext'
39166   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39167   (eval $ac_try) 2>&5
39168   ac_status=$?
39169   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39170   (exit $ac_status); }; }; then
39171   eval "$as_ac_var=yes"
39172 else
39173   echo "$as_me: failed program was:" >&5
39174 sed 's/^/| /' conftest.$ac_ext >&5
39175
39176 eval "$as_ac_var=no"
39177 fi
39178 rm -f conftest.err conftest.$ac_objext \
39179       conftest$ac_exeext conftest.$ac_ext
39180 fi
39181 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
39182 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
39183 if test `eval echo '${'$as_ac_var'}'` = yes; then
39184   cat >>confdefs.h <<_ACEOF
39185 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
39186 _ACEOF
39187
39188 fi
39189 done
39190
39191
39192
39193
39194 for ac_func in getopt getpeereid
39195 do
39196 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
39197 echo "$as_me:$LINENO: checking for $ac_func" >&5
39198 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
39199 if eval "test \"\${$as_ac_var+set}\" = set"; then
39200   echo $ECHO_N "(cached) $ECHO_C" >&6
39201 else
39202   cat >conftest.$ac_ext <<_ACEOF
39203 /* confdefs.h.  */
39204 _ACEOF
39205 cat confdefs.h >>conftest.$ac_ext
39206 cat >>conftest.$ac_ext <<_ACEOF
39207 /* end confdefs.h.  */
39208 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
39209    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
39210 #define $ac_func innocuous_$ac_func
39211
39212 /* System header to define __stub macros and hopefully few prototypes,
39213     which can conflict with char $ac_func (); below.
39214     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
39215     <limits.h> exists even on freestanding compilers.  */
39216
39217 #ifdef __STDC__
39218 # include <limits.h>
39219 #else
39220 # include <assert.h>
39221 #endif
39222
39223 #undef $ac_func
39224
39225 /* Override any gcc2 internal prototype to avoid an error.  */
39226 #ifdef __cplusplus
39227 extern "C"
39228 {
39229 #endif
39230 /* We use char because int might match the return type of a gcc2
39231    builtin and then its argument prototype would still apply.  */
39232 char $ac_func ();
39233 /* The GNU C library defines this for functions which it implements
39234     to always fail with ENOSYS.  Some functions are actually named
39235     something starting with __ and the normal name is an alias.  */
39236 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
39237 choke me
39238 #else
39239 char (*f) () = $ac_func;
39240 #endif
39241 #ifdef __cplusplus
39242 }
39243 #endif
39244
39245 int
39246 main ()
39247 {
39248 return f != $ac_func;
39249   ;
39250   return 0;
39251 }
39252 _ACEOF
39253 rm -f conftest.$ac_objext conftest$ac_exeext
39254 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
39255   (eval $ac_link) 2>conftest.er1
39256   ac_status=$?
39257   grep -v '^ *+' conftest.er1 >conftest.err
39258   rm -f conftest.er1
39259   cat conftest.err >&5
39260   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39261   (exit $ac_status); } &&
39262          { ac_try='test -z "$ac_c_werror_flag"
39263                          || test ! -s conftest.err'
39264   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39265   (eval $ac_try) 2>&5
39266   ac_status=$?
39267   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39268   (exit $ac_status); }; } &&
39269          { ac_try='test -s conftest$ac_exeext'
39270   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39271   (eval $ac_try) 2>&5
39272   ac_status=$?
39273   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39274   (exit $ac_status); }; }; then
39275   eval "$as_ac_var=yes"
39276 else
39277   echo "$as_me: failed program was:" >&5
39278 sed 's/^/| /' conftest.$ac_ext >&5
39279
39280 eval "$as_ac_var=no"
39281 fi
39282 rm -f conftest.err conftest.$ac_objext \
39283       conftest$ac_exeext conftest.$ac_ext
39284 fi
39285 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
39286 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
39287 if test `eval echo '${'$as_ac_var'}'` = yes; then
39288   cat >>confdefs.h <<_ACEOF
39289 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
39290 _ACEOF
39291
39292 else
39293   case $LIBOBJS in
39294     "$ac_func.$ac_objext"   | \
39295   *" $ac_func.$ac_objext"   | \
39296     "$ac_func.$ac_objext "* | \
39297   *" $ac_func.$ac_objext "* ) ;;
39298   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
39299 esac
39300
39301 fi
39302 done
39303
39304
39305
39306 if test "$ac_cv_func_getopt" != yes; then
39307         LIBSRCS="$LIBSRCS getopt.c"
39308 fi
39309
39310 if test "$ac_cv_func_getpeereid" != yes; then
39311
39312 for ac_func in getpeerucred
39313 do
39314 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
39315 echo "$as_me:$LINENO: checking for $ac_func" >&5
39316 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
39317 if eval "test \"\${$as_ac_var+set}\" = set"; then
39318   echo $ECHO_N "(cached) $ECHO_C" >&6
39319 else
39320   cat >conftest.$ac_ext <<_ACEOF
39321 /* confdefs.h.  */
39322 _ACEOF
39323 cat confdefs.h >>conftest.$ac_ext
39324 cat >>conftest.$ac_ext <<_ACEOF
39325 /* end confdefs.h.  */
39326 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
39327    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
39328 #define $ac_func innocuous_$ac_func
39329
39330 /* System header to define __stub macros and hopefully few prototypes,
39331     which can conflict with char $ac_func (); below.
39332     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
39333     <limits.h> exists even on freestanding compilers.  */
39334
39335 #ifdef __STDC__
39336 # include <limits.h>
39337 #else
39338 # include <assert.h>
39339 #endif
39340
39341 #undef $ac_func
39342
39343 /* Override any gcc2 internal prototype to avoid an error.  */
39344 #ifdef __cplusplus
39345 extern "C"
39346 {
39347 #endif
39348 /* We use char because int might match the return type of a gcc2
39349    builtin and then its argument prototype would still apply.  */
39350 char $ac_func ();
39351 /* The GNU C library defines this for functions which it implements
39352     to always fail with ENOSYS.  Some functions are actually named
39353     something starting with __ and the normal name is an alias.  */
39354 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
39355 choke me
39356 #else
39357 char (*f) () = $ac_func;
39358 #endif
39359 #ifdef __cplusplus
39360 }
39361 #endif
39362
39363 int
39364 main ()
39365 {
39366 return f != $ac_func;
39367   ;
39368   return 0;
39369 }
39370 _ACEOF
39371 rm -f conftest.$ac_objext conftest$ac_exeext
39372 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
39373   (eval $ac_link) 2>conftest.er1
39374   ac_status=$?
39375   grep -v '^ *+' conftest.er1 >conftest.err
39376   rm -f conftest.er1
39377   cat conftest.err >&5
39378   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39379   (exit $ac_status); } &&
39380          { ac_try='test -z "$ac_c_werror_flag"
39381                          || test ! -s conftest.err'
39382   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39383   (eval $ac_try) 2>&5
39384   ac_status=$?
39385   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39386   (exit $ac_status); }; } &&
39387          { ac_try='test -s conftest$ac_exeext'
39388   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39389   (eval $ac_try) 2>&5
39390   ac_status=$?
39391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39392   (exit $ac_status); }; }; then
39393   eval "$as_ac_var=yes"
39394 else
39395   echo "$as_me: failed program was:" >&5
39396 sed 's/^/| /' conftest.$ac_ext >&5
39397
39398 eval "$as_ac_var=no"
39399 fi
39400 rm -f conftest.err conftest.$ac_objext \
39401       conftest$ac_exeext conftest.$ac_ext
39402 fi
39403 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
39404 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
39405 if test `eval echo '${'$as_ac_var'}'` = yes; then
39406   cat >>confdefs.h <<_ACEOF
39407 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
39408 _ACEOF
39409
39410 fi
39411 done
39412
39413         if test "$ac_cv_func_getpeerucred" != yes ; then
39414                 echo "$as_me:$LINENO: checking for struct msghdr.msg_accrightslen" >&5
39415 echo $ECHO_N "checking for struct msghdr.msg_accrightslen... $ECHO_C" >&6
39416 if test "${ac_cv_member_struct_msghdr_msg_accrightslen+set}" = set; then
39417   echo $ECHO_N "(cached) $ECHO_C" >&6
39418 else
39419   cat >conftest.$ac_ext <<_ACEOF
39420 /* confdefs.h.  */
39421 _ACEOF
39422 cat confdefs.h >>conftest.$ac_ext
39423 cat >>conftest.$ac_ext <<_ACEOF
39424 /* end confdefs.h.  */
39425 $ac_includes_default
39426 #ifdef HAVE_SYS_SOCKET_H
39427 #include <sys/socket.h>
39428 #endif
39429
39430 int
39431 main ()
39432 {
39433 static struct msghdr ac_aggr;
39434 if (ac_aggr.msg_accrightslen)
39435 return 0;
39436   ;
39437   return 0;
39438 }
39439 _ACEOF
39440 rm -f conftest.$ac_objext
39441 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39442   (eval $ac_compile) 2>conftest.er1
39443   ac_status=$?
39444   grep -v '^ *+' conftest.er1 >conftest.err
39445   rm -f conftest.er1
39446   cat conftest.err >&5
39447   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39448   (exit $ac_status); } &&
39449          { ac_try='test -z "$ac_c_werror_flag"
39450                          || test ! -s conftest.err'
39451   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39452   (eval $ac_try) 2>&5
39453   ac_status=$?
39454   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39455   (exit $ac_status); }; } &&
39456          { ac_try='test -s conftest.$ac_objext'
39457   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39458   (eval $ac_try) 2>&5
39459   ac_status=$?
39460   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39461   (exit $ac_status); }; }; then
39462   ac_cv_member_struct_msghdr_msg_accrightslen=yes
39463 else
39464   echo "$as_me: failed program was:" >&5
39465 sed 's/^/| /' conftest.$ac_ext >&5
39466
39467 cat >conftest.$ac_ext <<_ACEOF
39468 /* confdefs.h.  */
39469 _ACEOF
39470 cat confdefs.h >>conftest.$ac_ext
39471 cat >>conftest.$ac_ext <<_ACEOF
39472 /* end confdefs.h.  */
39473 $ac_includes_default
39474 #ifdef HAVE_SYS_SOCKET_H
39475 #include <sys/socket.h>
39476 #endif
39477
39478 int
39479 main ()
39480 {
39481 static struct msghdr ac_aggr;
39482 if (sizeof ac_aggr.msg_accrightslen)
39483 return 0;
39484   ;
39485   return 0;
39486 }
39487 _ACEOF
39488 rm -f conftest.$ac_objext
39489 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39490   (eval $ac_compile) 2>conftest.er1
39491   ac_status=$?
39492   grep -v '^ *+' conftest.er1 >conftest.err
39493   rm -f conftest.er1
39494   cat conftest.err >&5
39495   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39496   (exit $ac_status); } &&
39497          { ac_try='test -z "$ac_c_werror_flag"
39498                          || test ! -s conftest.err'
39499   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39500   (eval $ac_try) 2>&5
39501   ac_status=$?
39502   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39503   (exit $ac_status); }; } &&
39504          { ac_try='test -s conftest.$ac_objext'
39505   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39506   (eval $ac_try) 2>&5
39507   ac_status=$?
39508   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39509   (exit $ac_status); }; }; then
39510   ac_cv_member_struct_msghdr_msg_accrightslen=yes
39511 else
39512   echo "$as_me: failed program was:" >&5
39513 sed 's/^/| /' conftest.$ac_ext >&5
39514
39515 ac_cv_member_struct_msghdr_msg_accrightslen=no
39516 fi
39517 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39518 fi
39519 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39520 fi
39521 echo "$as_me:$LINENO: result: $ac_cv_member_struct_msghdr_msg_accrightslen" >&5
39522 echo "${ECHO_T}$ac_cv_member_struct_msghdr_msg_accrightslen" >&6
39523 if test $ac_cv_member_struct_msghdr_msg_accrightslen = yes; then
39524
39525 cat >>confdefs.h <<_ACEOF
39526 #define HAVE_STRUCT_MSGHDR_MSG_ACCRIGHTSLEN 1
39527 _ACEOF
39528
39529
39530 fi
39531
39532                 if test "$ac_cv_member_struct_msghdr_msg_accrightslen" != yes; then
39533                         echo "$as_me:$LINENO: checking for struct msghdr.msg_control" >&5
39534 echo $ECHO_N "checking for struct msghdr.msg_control... $ECHO_C" >&6
39535 if test "${ac_cv_member_struct_msghdr_msg_control+set}" = set; then
39536   echo $ECHO_N "(cached) $ECHO_C" >&6
39537 else
39538   cat >conftest.$ac_ext <<_ACEOF
39539 /* confdefs.h.  */
39540 _ACEOF
39541 cat confdefs.h >>conftest.$ac_ext
39542 cat >>conftest.$ac_ext <<_ACEOF
39543 /* end confdefs.h.  */
39544 $ac_includes_default
39545 #ifdef HAVE_SYS_SOCKET_H
39546 #include <sys/socket.h>
39547 #endif
39548
39549 int
39550 main ()
39551 {
39552 static struct msghdr ac_aggr;
39553 if (ac_aggr.msg_control)
39554 return 0;
39555   ;
39556   return 0;
39557 }
39558 _ACEOF
39559 rm -f conftest.$ac_objext
39560 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39561   (eval $ac_compile) 2>conftest.er1
39562   ac_status=$?
39563   grep -v '^ *+' conftest.er1 >conftest.err
39564   rm -f conftest.er1
39565   cat conftest.err >&5
39566   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39567   (exit $ac_status); } &&
39568          { ac_try='test -z "$ac_c_werror_flag"
39569                          || test ! -s conftest.err'
39570   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39571   (eval $ac_try) 2>&5
39572   ac_status=$?
39573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39574   (exit $ac_status); }; } &&
39575          { ac_try='test -s conftest.$ac_objext'
39576   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39577   (eval $ac_try) 2>&5
39578   ac_status=$?
39579   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39580   (exit $ac_status); }; }; then
39581   ac_cv_member_struct_msghdr_msg_control=yes
39582 else
39583   echo "$as_me: failed program was:" >&5
39584 sed 's/^/| /' conftest.$ac_ext >&5
39585
39586 cat >conftest.$ac_ext <<_ACEOF
39587 /* confdefs.h.  */
39588 _ACEOF
39589 cat confdefs.h >>conftest.$ac_ext
39590 cat >>conftest.$ac_ext <<_ACEOF
39591 /* end confdefs.h.  */
39592 $ac_includes_default
39593 #ifdef HAVE_SYS_SOCKET_H
39594 #include <sys/socket.h>
39595 #endif
39596
39597 int
39598 main ()
39599 {
39600 static struct msghdr ac_aggr;
39601 if (sizeof ac_aggr.msg_control)
39602 return 0;
39603   ;
39604   return 0;
39605 }
39606 _ACEOF
39607 rm -f conftest.$ac_objext
39608 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39609   (eval $ac_compile) 2>conftest.er1
39610   ac_status=$?
39611   grep -v '^ *+' conftest.er1 >conftest.err
39612   rm -f conftest.er1
39613   cat conftest.err >&5
39614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39615   (exit $ac_status); } &&
39616          { ac_try='test -z "$ac_c_werror_flag"
39617                          || test ! -s conftest.err'
39618   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39619   (eval $ac_try) 2>&5
39620   ac_status=$?
39621   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39622   (exit $ac_status); }; } &&
39623          { ac_try='test -s conftest.$ac_objext'
39624   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39625   (eval $ac_try) 2>&5
39626   ac_status=$?
39627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39628   (exit $ac_status); }; }; then
39629   ac_cv_member_struct_msghdr_msg_control=yes
39630 else
39631   echo "$as_me: failed program was:" >&5
39632 sed 's/^/| /' conftest.$ac_ext >&5
39633
39634 ac_cv_member_struct_msghdr_msg_control=no
39635 fi
39636 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39637 fi
39638 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39639 fi
39640 echo "$as_me:$LINENO: result: $ac_cv_member_struct_msghdr_msg_control" >&5
39641 echo "${ECHO_T}$ac_cv_member_struct_msghdr_msg_control" >&6
39642 if test $ac_cv_member_struct_msghdr_msg_control = yes; then
39643
39644 cat >>confdefs.h <<_ACEOF
39645 #define HAVE_STRUCT_MSGHDR_MSG_CONTROL 1
39646 _ACEOF
39647
39648
39649 fi
39650
39651                 fi
39652                 echo "$as_me:$LINENO: checking for struct stat.st_fstype" >&5
39653 echo $ECHO_N "checking for struct stat.st_fstype... $ECHO_C" >&6
39654 if test "${ac_cv_member_struct_stat_st_fstype+set}" = set; then
39655   echo $ECHO_N "(cached) $ECHO_C" >&6
39656 else
39657   cat >conftest.$ac_ext <<_ACEOF
39658 /* confdefs.h.  */
39659 _ACEOF
39660 cat confdefs.h >>conftest.$ac_ext
39661 cat >>conftest.$ac_ext <<_ACEOF
39662 /* end confdefs.h.  */
39663 $ac_includes_default
39664 int
39665 main ()
39666 {
39667 static struct stat ac_aggr;
39668 if (ac_aggr.st_fstype)
39669 return 0;
39670   ;
39671   return 0;
39672 }
39673 _ACEOF
39674 rm -f conftest.$ac_objext
39675 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39676   (eval $ac_compile) 2>conftest.er1
39677   ac_status=$?
39678   grep -v '^ *+' conftest.er1 >conftest.err
39679   rm -f conftest.er1
39680   cat conftest.err >&5
39681   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39682   (exit $ac_status); } &&
39683          { ac_try='test -z "$ac_c_werror_flag"
39684                          || test ! -s conftest.err'
39685   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39686   (eval $ac_try) 2>&5
39687   ac_status=$?
39688   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39689   (exit $ac_status); }; } &&
39690          { ac_try='test -s conftest.$ac_objext'
39691   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39692   (eval $ac_try) 2>&5
39693   ac_status=$?
39694   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39695   (exit $ac_status); }; }; then
39696   ac_cv_member_struct_stat_st_fstype=yes
39697 else
39698   echo "$as_me: failed program was:" >&5
39699 sed 's/^/| /' conftest.$ac_ext >&5
39700
39701 cat >conftest.$ac_ext <<_ACEOF
39702 /* confdefs.h.  */
39703 _ACEOF
39704 cat confdefs.h >>conftest.$ac_ext
39705 cat >>conftest.$ac_ext <<_ACEOF
39706 /* end confdefs.h.  */
39707 $ac_includes_default
39708 int
39709 main ()
39710 {
39711 static struct stat ac_aggr;
39712 if (sizeof ac_aggr.st_fstype)
39713 return 0;
39714   ;
39715   return 0;
39716 }
39717 _ACEOF
39718 rm -f conftest.$ac_objext
39719 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39720   (eval $ac_compile) 2>conftest.er1
39721   ac_status=$?
39722   grep -v '^ *+' conftest.er1 >conftest.err
39723   rm -f conftest.er1
39724   cat conftest.err >&5
39725   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39726   (exit $ac_status); } &&
39727          { ac_try='test -z "$ac_c_werror_flag"
39728                          || test ! -s conftest.err'
39729   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39730   (eval $ac_try) 2>&5
39731   ac_status=$?
39732   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39733   (exit $ac_status); }; } &&
39734          { ac_try='test -s conftest.$ac_objext'
39735   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39736   (eval $ac_try) 2>&5
39737   ac_status=$?
39738   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39739   (exit $ac_status); }; }; then
39740   ac_cv_member_struct_stat_st_fstype=yes
39741 else
39742   echo "$as_me: failed program was:" >&5
39743 sed 's/^/| /' conftest.$ac_ext >&5
39744
39745 ac_cv_member_struct_stat_st_fstype=no
39746 fi
39747 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39748 fi
39749 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39750 fi
39751 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_fstype" >&5
39752 echo "${ECHO_T}$ac_cv_member_struct_stat_st_fstype" >&6
39753 if test $ac_cv_member_struct_stat_st_fstype = yes; then
39754
39755 cat >>confdefs.h <<_ACEOF
39756 #define HAVE_STRUCT_STAT_ST_FSTYPE 1
39757 _ACEOF
39758
39759
39760 fi
39761 echo "$as_me:$LINENO: checking for struct stat.st_vfstype" >&5
39762 echo $ECHO_N "checking for struct stat.st_vfstype... $ECHO_C" >&6
39763 if test "${ac_cv_member_struct_stat_st_vfstype+set}" = set; then
39764   echo $ECHO_N "(cached) $ECHO_C" >&6
39765 else
39766   cat >conftest.$ac_ext <<_ACEOF
39767 /* confdefs.h.  */
39768 _ACEOF
39769 cat confdefs.h >>conftest.$ac_ext
39770 cat >>conftest.$ac_ext <<_ACEOF
39771 /* end confdefs.h.  */
39772 $ac_includes_default
39773 int
39774 main ()
39775 {
39776 static struct stat ac_aggr;
39777 if (ac_aggr.st_vfstype)
39778 return 0;
39779   ;
39780   return 0;
39781 }
39782 _ACEOF
39783 rm -f conftest.$ac_objext
39784 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39785   (eval $ac_compile) 2>conftest.er1
39786   ac_status=$?
39787   grep -v '^ *+' conftest.er1 >conftest.err
39788   rm -f conftest.er1
39789   cat conftest.err >&5
39790   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39791   (exit $ac_status); } &&
39792          { ac_try='test -z "$ac_c_werror_flag"
39793                          || test ! -s conftest.err'
39794   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39795   (eval $ac_try) 2>&5
39796   ac_status=$?
39797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39798   (exit $ac_status); }; } &&
39799          { ac_try='test -s conftest.$ac_objext'
39800   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39801   (eval $ac_try) 2>&5
39802   ac_status=$?
39803   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39804   (exit $ac_status); }; }; then
39805   ac_cv_member_struct_stat_st_vfstype=yes
39806 else
39807   echo "$as_me: failed program was:" >&5
39808 sed 's/^/| /' conftest.$ac_ext >&5
39809
39810 cat >conftest.$ac_ext <<_ACEOF
39811 /* confdefs.h.  */
39812 _ACEOF
39813 cat confdefs.h >>conftest.$ac_ext
39814 cat >>conftest.$ac_ext <<_ACEOF
39815 /* end confdefs.h.  */
39816 $ac_includes_default
39817 int
39818 main ()
39819 {
39820 static struct stat ac_aggr;
39821 if (sizeof ac_aggr.st_vfstype)
39822 return 0;
39823   ;
39824   return 0;
39825 }
39826 _ACEOF
39827 rm -f conftest.$ac_objext
39828 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39829   (eval $ac_compile) 2>conftest.er1
39830   ac_status=$?
39831   grep -v '^ *+' conftest.er1 >conftest.err
39832   rm -f conftest.er1
39833   cat conftest.err >&5
39834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39835   (exit $ac_status); } &&
39836          { ac_try='test -z "$ac_c_werror_flag"
39837                          || test ! -s conftest.err'
39838   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39839   (eval $ac_try) 2>&5
39840   ac_status=$?
39841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39842   (exit $ac_status); }; } &&
39843          { ac_try='test -s conftest.$ac_objext'
39844   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39845   (eval $ac_try) 2>&5
39846   ac_status=$?
39847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39848   (exit $ac_status); }; }; then
39849   ac_cv_member_struct_stat_st_vfstype=yes
39850 else
39851   echo "$as_me: failed program was:" >&5
39852 sed 's/^/| /' conftest.$ac_ext >&5
39853
39854 ac_cv_member_struct_stat_st_vfstype=no
39855 fi
39856 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39857 fi
39858 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39859 fi
39860 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_vfstype" >&5
39861 echo "${ECHO_T}$ac_cv_member_struct_stat_st_vfstype" >&6
39862 if test $ac_cv_member_struct_stat_st_vfstype = yes; then
39863
39864 cat >>confdefs.h <<_ACEOF
39865 #define HAVE_STRUCT_STAT_ST_VFSTYPE 1
39866 _ACEOF
39867
39868
39869 fi
39870
39871                 if test "$ac_cv_member_struct_stat_st_fstype" = yes; then
39872                         cat >conftest.$ac_ext <<_ACEOF
39873 struct stat st; char *ptr=st.st_fstype;
39874 _ACEOF
39875 rm -f conftest.$ac_objext
39876 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39877   (eval $ac_compile) 2>conftest.er1
39878   ac_status=$?
39879   grep -v '^ *+' conftest.er1 >conftest.err
39880   rm -f conftest.er1
39881   cat conftest.err >&5
39882   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39883   (exit $ac_status); } &&
39884          { ac_try='test -z "$ac_c_werror_flag"
39885                          || test ! -s conftest.err'
39886   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39887   (eval $ac_try) 2>&5
39888   ac_status=$?
39889   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39890   (exit $ac_status); }; } &&
39891          { ac_try='test -s conftest.$ac_objext'
39892   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39893   (eval $ac_try) 2>&5
39894   ac_status=$?
39895   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39896   (exit $ac_status); }; }; then
39897
39898 cat >>confdefs.h <<\_ACEOF
39899 #define HAVE_STRUCT_STAT_ST_FSTYPE_CHAR 1
39900 _ACEOF
39901
39902 else
39903   echo "$as_me: failed program was:" >&5
39904 sed 's/^/| /' conftest.$ac_ext >&5
39905
39906
39907 cat >>confdefs.h <<\_ACEOF
39908 #define HAVE_STRUCT_STAT_ST_FSTYPE_INT 1
39909 _ACEOF
39910
39911 fi
39912 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39913                 fi
39914         fi
39915         LIBSRCS="$LIBSRCS getpeereid.c"
39916 fi
39917
39918 if test "$ac_cv_func_snprintf" != yes ||
39919    test "$ac_cv_func_vsnprintf" != yes; then
39920         if test "$ac_cv_func_snprintf" != yes; then
39921
39922 cat >>confdefs.h <<\_ACEOF
39923 #define snprintf ber_pvt_snprintf
39924 _ACEOF
39925
39926         fi
39927         if test "$ac_cv_func_vsnprintf" != yes; then
39928
39929 cat >>confdefs.h <<\_ACEOF
39930 #define vsnprintf ber_pvt_vsnprintf
39931 _ACEOF
39932
39933         fi
39934 fi
39935
39936
39937 if test "$ol_enable_slapi" != no ; then
39938
39939 for ac_header in ltdl.h
39940 do
39941 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
39942 if eval "test \"\${$as_ac_Header+set}\" = set"; then
39943   echo "$as_me:$LINENO: checking for $ac_header" >&5
39944 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
39945 if eval "test \"\${$as_ac_Header+set}\" = set"; then
39946   echo $ECHO_N "(cached) $ECHO_C" >&6
39947 fi
39948 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
39949 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
39950 else
39951   # Is the header compilable?
39952 echo "$as_me:$LINENO: checking $ac_header usability" >&5
39953 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
39954 cat >conftest.$ac_ext <<_ACEOF
39955 /* confdefs.h.  */
39956 _ACEOF
39957 cat confdefs.h >>conftest.$ac_ext
39958 cat >>conftest.$ac_ext <<_ACEOF
39959 /* end confdefs.h.  */
39960 $ac_includes_default
39961 #include <$ac_header>
39962 _ACEOF
39963 rm -f conftest.$ac_objext
39964 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
39965   (eval $ac_compile) 2>conftest.er1
39966   ac_status=$?
39967   grep -v '^ *+' conftest.er1 >conftest.err
39968   rm -f conftest.er1
39969   cat conftest.err >&5
39970   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39971   (exit $ac_status); } &&
39972          { ac_try='test -z "$ac_c_werror_flag"
39973                          || test ! -s conftest.err'
39974   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39975   (eval $ac_try) 2>&5
39976   ac_status=$?
39977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39978   (exit $ac_status); }; } &&
39979          { ac_try='test -s conftest.$ac_objext'
39980   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
39981   (eval $ac_try) 2>&5
39982   ac_status=$?
39983   echo "$as_me:$LINENO: \$? = $ac_status" >&5
39984   (exit $ac_status); }; }; then
39985   ac_header_compiler=yes
39986 else
39987   echo "$as_me: failed program was:" >&5
39988 sed 's/^/| /' conftest.$ac_ext >&5
39989
39990 ac_header_compiler=no
39991 fi
39992 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
39993 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
39994 echo "${ECHO_T}$ac_header_compiler" >&6
39995
39996 # Is the header present?
39997 echo "$as_me:$LINENO: checking $ac_header presence" >&5
39998 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
39999 cat >conftest.$ac_ext <<_ACEOF
40000 /* confdefs.h.  */
40001 _ACEOF
40002 cat confdefs.h >>conftest.$ac_ext
40003 cat >>conftest.$ac_ext <<_ACEOF
40004 /* end confdefs.h.  */
40005 #include <$ac_header>
40006 _ACEOF
40007 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
40008   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
40009   ac_status=$?
40010   grep -v '^ *+' conftest.er1 >conftest.err
40011   rm -f conftest.er1
40012   cat conftest.err >&5
40013   echo "$as_me:$LINENO: \$? = $ac_status" >&5
40014   (exit $ac_status); } >/dev/null; then
40015   if test -s conftest.err; then
40016     ac_cpp_err=$ac_c_preproc_warn_flag
40017     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
40018   else
40019     ac_cpp_err=
40020   fi
40021 else
40022   ac_cpp_err=yes
40023 fi
40024 if test -z "$ac_cpp_err"; then
40025   ac_header_preproc=yes
40026 else
40027   echo "$as_me: failed program was:" >&5
40028 sed 's/^/| /' conftest.$ac_ext >&5
40029
40030   ac_header_preproc=no
40031 fi
40032 rm -f conftest.err conftest.$ac_ext
40033 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
40034 echo "${ECHO_T}$ac_header_preproc" >&6
40035
40036 # So?  What about this header?
40037 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
40038   yes:no: )
40039     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
40040 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
40041     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
40042 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
40043     ac_header_preproc=yes
40044     ;;
40045   no:yes:* )
40046     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
40047 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
40048     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
40049 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
40050     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
40051 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
40052     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
40053 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
40054     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
40055 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
40056     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
40057 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
40058     (
40059       cat <<\_ASBOX
40060 ## --------------------------------------------- ##
40061 ## Report this to <http://www.openldap.org/its/> ##
40062 ## --------------------------------------------- ##
40063 _ASBOX
40064     ) |
40065       sed "s/^/$as_me: WARNING:     /" >&2
40066     ;;
40067 esac
40068 echo "$as_me:$LINENO: checking for $ac_header" >&5
40069 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
40070 if eval "test \"\${$as_ac_Header+set}\" = set"; then
40071   echo $ECHO_N "(cached) $ECHO_C" >&6
40072 else
40073   eval "$as_ac_Header=\$ac_header_preproc"
40074 fi
40075 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
40076 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
40077
40078 fi
40079 if test `eval echo '${'$as_ac_Header'}'` = yes; then
40080   cat >>confdefs.h <<_ACEOF
40081 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
40082 _ACEOF
40083
40084 fi
40085
40086 done
40087
40088
40089         if test $ac_cv_header_ltdl_h != yes ; then
40090                 { { echo "$as_me:$LINENO: error: could not locate <ltdl.h>" >&5
40091 echo "$as_me: error: could not locate <ltdl.h>" >&2;}
40092    { (exit 1); exit 1; }; }
40093         fi
40094         echo "$as_me:$LINENO: checking for lt_dlinit in -lltdl" >&5
40095 echo $ECHO_N "checking for lt_dlinit in -lltdl... $ECHO_C" >&6
40096 if test "${ac_cv_lib_ltdl_lt_dlinit+set}" = set; then
40097   echo $ECHO_N "(cached) $ECHO_C" >&6
40098 else
40099   ac_check_lib_save_LIBS=$LIBS
40100 LIBS="-lltdl  $LIBS"
40101 cat >conftest.$ac_ext <<_ACEOF
40102 /* confdefs.h.  */
40103 _ACEOF
40104 cat confdefs.h >>conftest.$ac_ext
40105 cat >>conftest.$ac_ext <<_ACEOF
40106 /* end confdefs.h.  */
40107
40108 /* Override any gcc2 internal prototype to avoid an error.  */
40109 #ifdef __cplusplus
40110 extern "C"
40111 #endif
40112 /* We use char because int might match the return type of a gcc2
40113    builtin and then its argument prototype would still apply.  */
40114 char lt_dlinit ();
40115 int
40116 main ()
40117 {
40118 lt_dlinit ();
40119   ;
40120   return 0;
40121 }
40122 _ACEOF
40123 rm -f conftest.$ac_objext conftest$ac_exeext
40124 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
40125   (eval $ac_link) 2>conftest.er1
40126   ac_status=$?
40127   grep -v '^ *+' conftest.er1 >conftest.err
40128   rm -f conftest.er1
40129   cat conftest.err >&5
40130   echo "$as_me:$LINENO: \$? = $ac_status" >&5
40131   (exit $ac_status); } &&
40132          { ac_try='test -z "$ac_c_werror_flag"
40133                          || test ! -s conftest.err'
40134   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
40135   (eval $ac_try) 2>&5
40136   ac_status=$?
40137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
40138   (exit $ac_status); }; } &&
40139          { ac_try='test -s conftest$ac_exeext'
40140   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
40141   (eval $ac_try) 2>&5
40142   ac_status=$?
40143   echo "$as_me:$LINENO: \$? = $ac_status" >&5
40144   (exit $ac_status); }; }; then
40145   ac_cv_lib_ltdl_lt_dlinit=yes
40146 else
40147   echo "$as_me: failed program was:" >&5
40148 sed 's/^/| /' conftest.$ac_ext >&5
40149
40150 ac_cv_lib_ltdl_lt_dlinit=no
40151 fi
40152 rm -f conftest.err conftest.$ac_objext \
40153       conftest$ac_exeext conftest.$ac_ext
40154 LIBS=$ac_check_lib_save_LIBS
40155 fi
40156 echo "$as_me:$LINENO: result: $ac_cv_lib_ltdl_lt_dlinit" >&5
40157 echo "${ECHO_T}$ac_cv_lib_ltdl_lt_dlinit" >&6
40158 if test $ac_cv_lib_ltdl_lt_dlinit = yes; then
40159
40160                 SLAPI_LIBS=-lltdl
40161                 LIBSLAPI=libslapi.a
40162                 LIBSLAPITOOLS=../libslapi.a
40163
40164 cat >>confdefs.h <<\_ACEOF
40165 #define HAVE_LIBLTDL 1
40166 _ACEOF
40167
40168
40169 else
40170   { { echo "$as_me:$LINENO: error: could not locate libtool -lltdl" >&5
40171 echo "$as_me: error: could not locate libtool -lltdl" >&2;}
40172    { (exit 1); exit 1; }; }
40173 fi
40174
40175
40176
40177 cat >>confdefs.h <<\_ACEOF
40178 #define LDAP_SLAPI 1
40179 _ACEOF
40180
40181 fi
40182
40183 if test "$ol_enable_debug" != no ; then
40184         if test "$ol_enable_debug" = traditional; then
40185
40186 cat >>confdefs.h <<\_ACEOF
40187 #define OLD_DEBUG 1
40188 _ACEOF
40189
40190         fi
40191
40192 cat >>confdefs.h <<\_ACEOF
40193 #define LDAP_DEBUG 1
40194 _ACEOF
40195
40196 fi
40197 if test "$ol_enable_syslog" = yes ; then
40198
40199 cat >>confdefs.h <<\_ACEOF
40200 #define LDAP_SYSLOG 1
40201 _ACEOF
40202
40203 fi
40204 if test "$ol_enable_proctitle" != no ; then
40205
40206 cat >>confdefs.h <<\_ACEOF
40207 #define LDAP_PROCTITLE 1
40208 _ACEOF
40209
40210 fi
40211 if test "$ol_enable_referrals" != no ; then
40212
40213 cat >>confdefs.h <<\_ACEOF
40214 #define LDAP_API_FEATURE_X_OPENLDAP_V2_REFERRALS LDAP_VENDOR_VERSION
40215 _ACEOF
40216
40217 fi
40218 if test "$ol_enable_local" != no; then
40219
40220 cat >>confdefs.h <<\_ACEOF
40221 #define LDAP_PF_LOCAL 1
40222 _ACEOF
40223
40224 fi
40225 if test "$ol_link_ipv6" != no; then
40226
40227 cat >>confdefs.h <<\_ACEOF
40228 #define LDAP_PF_INET6 1
40229 _ACEOF
40230
40231 fi
40232 if test "$ol_enable_cleartext" != no ; then
40233
40234 cat >>confdefs.h <<\_ACEOF
40235 #define SLAPD_CLEARTEXT 1
40236 _ACEOF
40237
40238 fi
40239 if test "$ol_enable_crypt" != no ; then
40240
40241 cat >>confdefs.h <<\_ACEOF
40242 #define SLAPD_CRYPT 1
40243 _ACEOF
40244
40245 fi
40246 if test "$ol_link_spasswd" != no ; then
40247
40248 cat >>confdefs.h <<\_ACEOF
40249 #define SLAPD_SPASSWD 1
40250 _ACEOF
40251
40252 fi
40253 if test "$ol_enable_rlookups" != no ; then
40254
40255 cat >>confdefs.h <<\_ACEOF
40256 #define SLAPD_RLOOKUPS 1
40257 _ACEOF
40258
40259 fi
40260 if test "$ol_enable_aci" != no ; then
40261         if test $ol_enable_dynacl = no ; then
40262                 ol_enable_dynacl=yes
40263                 { echo "$as_me:$LINENO: WARNING: ACIs need dynacl" >&5
40264 echo "$as_me: WARNING: ACIs need dynacl" >&2;}
40265         fi
40266         if test "$ol_enable_aci" = mod ; then
40267                 MFLAG=SLAPD_MOD_DYNAMIC
40268                                 { { echo "$as_me:$LINENO: error: ACI build as dynamic module not supported (yet)" >&5
40269 echo "$as_me: error: ACI build as dynamic module not supported (yet)" >&2;}
40270    { (exit 1); exit 1; }; }
40271         else
40272                 MFLAG=SLAPD_MOD_STATIC
40273         fi
40274         WITH_ACI_ENABLED=$ol_enable_aci
40275
40276 cat >>confdefs.h <<_ACEOF
40277 #define SLAPD_ACI_ENABLED $MFLAG
40278 _ACEOF
40279
40280 else
40281         WITH_ACI_ENABLED=no
40282 fi
40283 if test "$ol_enable_dynacl" != no ; then
40284
40285 cat >>confdefs.h <<\_ACEOF
40286 #define SLAP_DYNACL 1
40287 _ACEOF
40288
40289 fi
40290
40291 if test "$ol_link_modules" != no ; then
40292
40293 cat >>confdefs.h <<\_ACEOF
40294 #define SLAPD_MODULES 1
40295 _ACEOF
40296
40297         BUILD_SLAPD=yes
40298         SLAPD_MODULES_LDFLAGS="-dlopen self"
40299 fi
40300
40301
40302 cat >>confdefs.h <<\_ACEOF
40303 #define SLAPD_MOD_STATIC 1
40304 _ACEOF
40305
40306
40307 cat >>confdefs.h <<\_ACEOF
40308 #define SLAPD_MOD_DYNAMIC 2
40309 _ACEOF
40310
40311
40312 if test "$ol_enable_monitor" != no ; then
40313         BUILD_SLAPD=yes
40314         BUILD_MONITOR=$ol_enable_monitor
40315         if test "$ol_enable_monitor" = mod ; then
40316                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-monitor"
40317                 MFLAG=SLAPD_MOD_DYNAMIC
40318         else
40319                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-monitor"
40320                 MFLAG=SLAPD_MOD_STATIC
40321         fi
40322
40323 cat >>confdefs.h <<_ACEOF
40324 #define SLAPD_MONITOR $MFLAG
40325 _ACEOF
40326
40327 fi
40328
40329 if test "$ol_enable_bdb" != no ; then
40330         BUILD_SLAPD=yes
40331         BUILD_BDB=$ol_enable_bdb
40332         if test "$ol_enable_bdb" = mod ; then
40333                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-bdb"
40334                 MFLAG=SLAPD_MOD_DYNAMIC
40335         else
40336                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-bdb"
40337                 MFLAG=SLAPD_MOD_STATIC
40338         fi
40339
40340 cat >>confdefs.h <<_ACEOF
40341 #define SLAPD_BDB $MFLAG
40342 _ACEOF
40343
40344 fi
40345
40346 if test "$ol_enable_dnssrv" != no ; then
40347         BUILD_SLAPD=yes
40348         BUILD_DNSSRV=$ol_enable_dnssrv
40349         if test "$ol_enable_dnssrv" = mod ; then
40350                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-dnssrv"
40351                 MFLAG=SLAPD_MOD_DYNAMIC
40352         else
40353                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-dnssrv"
40354                 MFLAG=SLAPD_MOD_STATIC
40355         fi
40356
40357 cat >>confdefs.h <<_ACEOF
40358 #define SLAPD_DNSSRV $MFLAG
40359 _ACEOF
40360
40361 fi
40362
40363 if test "$ol_enable_hdb" != no ; then
40364         BUILD_SLAPD=yes
40365         BUILD_HDB=$ol_enable_hdb
40366         if test "$ol_enable_hdb" = mod ; then
40367                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-hdb"
40368                 MFLAG=SLAPD_MOD_DYNAMIC
40369         else
40370                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-hdb"
40371                 MFLAG=SLAPD_MOD_STATIC
40372         fi
40373
40374 cat >>confdefs.h <<_ACEOF
40375 #define SLAPD_HDB $MFLAG
40376 _ACEOF
40377
40378 fi
40379
40380 if test "$ol_enable_ldap" != no ; then
40381         BUILD_SLAPD=yes
40382         BUILD_LDAP=$ol_enable_ldap
40383         if test "$ol_enable_ldap" = mod ; then
40384                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-ldap"
40385                 MFLAG=SLAPD_MOD_DYNAMIC
40386         else
40387                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-ldap"
40388                 MFLAG=SLAPD_MOD_STATIC
40389         fi
40390
40391 cat >>confdefs.h <<_ACEOF
40392 #define SLAPD_LDAP $MFLAG
40393 _ACEOF
40394
40395 fi
40396
40397 if test "$ol_enable_meta" != no ; then
40398         BUILD_SLAPD=yes
40399         BUILD_META=$ol_enable_meta
40400         BUILD_REWRITE=yes
40401         if test "$ol_enable_meta" = mod ; then
40402                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-meta"
40403                 MFLAG=SLAPD_MOD_DYNAMIC
40404         else
40405                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-meta"
40406                 MFLAG=SLAPD_MOD_STATIC
40407         fi
40408
40409 cat >>confdefs.h <<_ACEOF
40410 #define SLAPD_META $MFLAG
40411 _ACEOF
40412
40413 fi
40414
40415 if test "$ol_enable_null" != no ; then
40416         BUILD_SLAPD=yes
40417         BUILD_NULL=$ol_enable_null
40418         if test "$ol_enable_null" = mod ; then
40419                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-null"
40420                 MFLAG=SLAPD_MOD_DYNAMIC
40421         else
40422                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-null"
40423                 MFLAG=SLAPD_MOD_STATIC
40424         fi
40425
40426 cat >>confdefs.h <<_ACEOF
40427 #define SLAPD_NULL $MFLAG
40428 _ACEOF
40429
40430 fi
40431
40432 if test "$ol_enable_passwd" != no ; then
40433         BUILD_SLAPD=yes
40434         BUILD_PASSWD=$ol_enable_passwd
40435         if test "$ol_enable_passwd" = mod ; then
40436                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-passwd"
40437                 MFLAG=SLAPD_MOD_DYNAMIC
40438         else
40439                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-passwd"
40440                 MFLAG=SLAPD_MOD_STATIC
40441         fi
40442
40443 cat >>confdefs.h <<_ACEOF
40444 #define SLAPD_PASSWD $MFLAG
40445 _ACEOF
40446
40447 fi
40448
40449 if test "$ol_link_perl" != no ; then
40450         BUILD_SLAPD=yes
40451         BUILD_PERL=$ol_enable_perl
40452         if test "$ol_enable_perl" = mod ; then
40453                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-perl"
40454                 MFLAG=SLAPD_MOD_DYNAMIC
40455         else
40456                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-perl"
40457                 MFLAG=SLAPD_MOD_STATIC
40458         fi
40459
40460 cat >>confdefs.h <<_ACEOF
40461 #define SLAPD_PERL $MFLAG
40462 _ACEOF
40463
40464 fi
40465
40466 if test "$ol_enable_relay" != no ; then
40467         BUILD_SLAPD=yes
40468         BUILD_RELAY=$ol_enable_relay
40469         if test "$ol_enable_relay" = mod ; then
40470                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-relay"
40471                 MFLAG=SLAPD_MOD_DYNAMIC
40472         else
40473                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-relay"
40474                 MFLAG=SLAPD_MOD_STATIC
40475         fi
40476
40477 cat >>confdefs.h <<_ACEOF
40478 #define SLAPD_RELAY $MFLAG
40479 _ACEOF
40480
40481 fi
40482
40483 if test "$ol_enable_shell" != no ; then
40484         if test "$ol_link_threads" != no ; then
40485                 { echo "$as_me:$LINENO: WARNING: Use of --without-threads is recommended with back-shell" >&5
40486 echo "$as_me: WARNING: Use of --without-threads is recommended with back-shell" >&2;}
40487         fi
40488         BUILD_SLAPD=yes
40489         BUILD_SHELL=$ol_enable_shell
40490         if test "$ol_enable_shell" = mod ; then
40491                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-shell"
40492                 MFLAG=SLAPD_MOD_DYNAMIC
40493         else
40494                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-shell"
40495                 MFLAG=SLAPD_MOD_STATIC
40496         fi
40497
40498 cat >>confdefs.h <<_ACEOF
40499 #define SLAPD_SHELL $MFLAG
40500 _ACEOF
40501
40502 fi
40503
40504 if test "$ol_enable_sock" != no ; then
40505         BUILD_SLAPD=yes
40506         BUILD_SOCK=$ol_enable_sock
40507         if test "$ol_enable_sock" = mod ; then
40508                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-sock"
40509                 MFLAG=SLAPD_MOD_DYNAMIC
40510         else
40511                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-sock"
40512                 MFLAG=SLAPD_MOD_STATIC
40513         fi
40514
40515 cat >>confdefs.h <<_ACEOF
40516 #define SLAPD_SOCK $MFLAG
40517 _ACEOF
40518
40519 fi
40520
40521 if test "$ol_link_sql" != no ; then
40522         BUILD_SLAPD=yes
40523         BUILD_SQL=$ol_enable_sql
40524         if test "$ol_enable_sql" = mod; then
40525                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-sql"
40526                 MFLAG=SLAPD_MOD_DYNAMIC
40527         else
40528                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-sql"
40529                 MFLAG=SLAPD_MOD_STATIC
40530         fi
40531
40532 cat >>confdefs.h <<_ACEOF
40533 #define SLAPD_SQL $MFLAG
40534 _ACEOF
40535
40536 fi
40537
40538 if test "$ol_enable_accesslog" != no ; then
40539         BUILD_ACCESSLOG=$ol_enable_accesslog
40540         if test "$ol_enable_accesslog" = mod ; then
40541                 MFLAG=SLAPD_MOD_DYNAMIC
40542                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS accesslog.la"
40543         else
40544                 MFLAG=SLAPD_MOD_STATIC
40545                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS accesslog.o"
40546         fi
40547
40548 cat >>confdefs.h <<_ACEOF
40549 #define SLAPD_OVER_ACCESSLOG $MFLAG
40550 _ACEOF
40551
40552 fi
40553
40554 if test "$ol_enable_auditlog" != no ; then
40555         BUILD_AUDITLOG=$ol_enable_auditlog
40556         if test "$ol_enable_auditlog" = mod ; then
40557                 MFLAG=SLAPD_MOD_DYNAMIC
40558                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS auditlog.la"
40559         else
40560                 MFLAG=SLAPD_MOD_STATIC
40561                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS auditlog.o"
40562         fi
40563
40564 cat >>confdefs.h <<_ACEOF
40565 #define SLAPD_OVER_AUDITLOG $MFLAG
40566 _ACEOF
40567
40568 fi
40569
40570 if test "$ol_enable_constraint" != no ; then
40571         BUILD_CONSTRAINT=$ol_enable_constraint
40572         if test "$ol_enable_constraint" = mod ; then
40573                 MFLAG=SLAPD_MOD_DYNAMIC
40574                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS constraint.la"
40575         else
40576                 MFLAG=SLAPD_MOD_STATIC
40577                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS constraint.o"
40578         fi
40579
40580 cat >>confdefs.h <<_ACEOF
40581 #define SLAPD_OVER_CONSTRAINT $MFLAG
40582 _ACEOF
40583
40584 fi
40585
40586 if test "$ol_enable_dds" != no ; then
40587         BUILD_DDS=$ol_enable_dds
40588         if test "$ol_enable_dds" = mod ; then
40589                 MFLAG=SLAPD_MOD_DYNAMIC
40590                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS dds.la"
40591         else
40592                 MFLAG=SLAPD_MOD_STATIC
40593                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS dds.o"
40594         fi
40595
40596 cat >>confdefs.h <<_ACEOF
40597 #define SLAPD_OVER_DDS $MFLAG
40598 _ACEOF
40599
40600 fi
40601
40602 if test "$ol_enable_dyngroup" != no ; then
40603         BUILD_DYNGROUP=$ol_enable_dyngroup
40604         if test "$ol_enable_dyngroup" = mod ; then
40605                 MFLAG=SLAPD_MOD_DYNAMIC
40606                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS dyngroup.la"
40607         else
40608                 MFLAG=SLAPD_MOD_STATIC
40609                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS dyngroup.o"
40610         fi
40611
40612 cat >>confdefs.h <<_ACEOF
40613 #define SLAPD_OVER_DYNGROUP $MFLAG
40614 _ACEOF
40615
40616 fi
40617
40618 if test "$ol_enable_dynlist" != no ; then
40619         BUILD_DYNLIST=$ol_enable_dynlist
40620         if test "$ol_enable_dynlist" = mod ; then
40621                 MFLAG=SLAPD_MOD_DYNAMIC
40622                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS dynlist.la"
40623         else
40624                 MFLAG=SLAPD_MOD_STATIC
40625                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS dynlist.o"
40626         fi
40627
40628 cat >>confdefs.h <<_ACEOF
40629 #define SLAPD_OVER_DYNLIST $MFLAG
40630 _ACEOF
40631
40632 fi
40633
40634 if test "$ol_enable_memberof" != no ; then
40635         BUILD_MEMBEROF=$ol_enable_memberof
40636         if test "$ol_enable_memberof" = mod ; then
40637                 MFLAG=SLAPD_MOD_DYNAMIC
40638                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS memberof.la"
40639         else
40640                 MFLAG=SLAPD_MOD_STATIC
40641                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS memberof.o"
40642         fi
40643
40644 cat >>confdefs.h <<_ACEOF
40645 #define SLAPD_OVER_MEMBEROF $MFLAG
40646 _ACEOF
40647
40648 fi
40649
40650 if test "$ol_enable_ppolicy" != no ; then
40651         BUILD_PPOLICY=$ol_enable_ppolicy
40652         if test "$ol_enable_ppolicy" = mod ; then
40653                 MFLAG=SLAPD_MOD_DYNAMIC
40654                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS ppolicy.la"
40655         else
40656                 MFLAG=SLAPD_MOD_STATIC
40657                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS ppolicy.o"
40658         fi
40659
40660 cat >>confdefs.h <<_ACEOF
40661 #define SLAPD_OVER_PPOLICY $MFLAG
40662 _ACEOF
40663
40664 fi
40665
40666 if test "$ol_enable_proxycache" != no ; then
40667         BUILD_PROXYCACHE=$ol_enable_proxycache
40668         if test "$ol_enable_proxycache" = mod ; then
40669                 MFLAG=SLAPD_MOD_DYNAMIC
40670                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS pcache.la"
40671         else
40672                 MFLAG=SLAPD_MOD_STATIC
40673                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS pcache.o"
40674         fi
40675
40676 cat >>confdefs.h <<_ACEOF
40677 #define SLAPD_OVER_PROXYCACHE $MFLAG
40678 _ACEOF
40679
40680 fi
40681
40682 if test "$ol_enable_refint" != no ; then
40683         BUILD_REFINT=$ol_enable_refint
40684         if test "$ol_enable_refint" = mod ; then
40685                 MFLAG=SLAPD_MOD_DYNAMIC
40686                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS refint.la"
40687         else
40688                 MFLAG=SLAPD_MOD_STATIC
40689                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS refint.o"
40690         fi
40691
40692 cat >>confdefs.h <<_ACEOF
40693 #define SLAPD_OVER_REFINT $MFLAG
40694 _ACEOF
40695
40696 fi
40697
40698 if test "$ol_enable_retcode" != no ; then
40699         BUILD_RETCODE=$ol_enable_retcode
40700         if test "$ol_enable_retcode" = mod ; then
40701                 MFLAG=SLAPD_MOD_DYNAMIC
40702                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS retcode.la"
40703         else
40704                 MFLAG=SLAPD_MOD_STATIC
40705                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS retcode.o"
40706         fi
40707
40708 cat >>confdefs.h <<_ACEOF
40709 #define SLAPD_OVER_RETCODE $MFLAG
40710 _ACEOF
40711
40712 fi
40713
40714 if test "$ol_enable_rwm" != no ; then
40715         BUILD_REWRITE=yes
40716         BUILD_RWM=$ol_enable_rwm
40717         if test "$ol_enable_rwm" = mod ; then
40718                 MFLAG=SLAPD_MOD_DYNAMIC
40719                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS rwm.la"
40720         else
40721                 MFLAG=SLAPD_MOD_STATIC
40722                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS rwm_x.o"
40723         fi
40724
40725 cat >>confdefs.h <<_ACEOF
40726 #define SLAPD_OVER_RWM $MFLAG
40727 _ACEOF
40728
40729 fi
40730
40731 if test "$ol_enable_seqmod" != no ; then
40732         BUILD_SEQMOD=$ol_enable_seqmod
40733         if test "$ol_enable_seqmod" = mod ; then
40734                 MFLAG=SLAPD_MOD_DYNAMIC
40735                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS seqmod.la"
40736         else
40737                 MFLAG=SLAPD_MOD_STATIC
40738                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS seqmod.o"
40739         fi
40740
40741 cat >>confdefs.h <<_ACEOF
40742 #define SLAPD_OVER_SEQMOD $MFLAG
40743 _ACEOF
40744
40745 fi
40746
40747 if test "$ol_enable_syncprov" != no ; then
40748         BUILD_SYNCPROV=$ol_enable_syncprov
40749         if test "$ol_enable_syncprov" = mod ; then
40750                 MFLAG=SLAPD_MOD_DYNAMIC
40751                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS syncprov.la"
40752         else
40753                 MFLAG=SLAPD_MOD_STATIC
40754                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS syncprov.o"
40755         fi
40756
40757 cat >>confdefs.h <<_ACEOF
40758 #define SLAPD_OVER_SYNCPROV $MFLAG
40759 _ACEOF
40760
40761 fi
40762
40763 if test "$ol_enable_translucent" != no ; then
40764         BUILD_TRANSLUCENT=$ol_enable_translucent
40765         if test "$ol_enable_translucent" = mod ; then
40766                 MFLAG=SLAPD_MOD_DYNAMIC
40767                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS translucent.la"
40768         else
40769                 MFLAG=SLAPD_MOD_STATIC
40770                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS translucent.o"
40771         fi
40772
40773 cat >>confdefs.h <<_ACEOF
40774 #define SLAPD_OVER_TRANSLUCENT $MFLAG
40775 _ACEOF
40776
40777 fi
40778
40779 if test "$ol_enable_unique" != no ; then
40780         BUILD_UNIQUE=$ol_enable_unique
40781         if test "$ol_enable_unique" = mod ; then
40782                 MFLAG=SLAPD_MOD_DYNAMIC
40783                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS unique.la"
40784         else
40785                 MFLAG=SLAPD_MOD_STATIC
40786                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS unique.o"
40787         fi
40788
40789 cat >>confdefs.h <<_ACEOF
40790 #define SLAPD_OVER_UNIQUE $MFLAG
40791 _ACEOF
40792
40793 fi
40794
40795 if test "$ol_enable_valsort" != no ; then
40796         BUILD_VALSORT=$ol_enable_valsort
40797         if test "$ol_enable_valsort" = mod ; then
40798                 MFLAG=SLAPD_MOD_DYNAMIC
40799                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS valsort.la"
40800         else
40801                 MFLAG=SLAPD_MOD_STATIC
40802                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS valsort.o"
40803         fi
40804
40805 cat >>confdefs.h <<_ACEOF
40806 #define SLAPD_OVER_VALSORT $MFLAG
40807 _ACEOF
40808
40809 fi
40810
40811 if test "$ol_enable_rewrite" != no ; then
40812
40813 cat >>confdefs.h <<\_ACEOF
40814 #define ENABLE_REWRITE 1
40815 _ACEOF
40816
40817         BUILD_REWRITE=yes
40818 fi
40819
40820 if test "$ol_enable_slapi" != no ; then
40821
40822 cat >>confdefs.h <<\_ACEOF
40823 #define ENABLE_SLAPI 1
40824 _ACEOF
40825
40826         BUILD_SLAPI=yes
40827         SLAPD_SLAPI_DEPEND=libslapi.a
40828 fi
40829
40830
40831
40832 if test "$ac_cv_mingw32" = yes ; then
40833         PLAT=NT
40834         SLAPD_MODULES_LDFLAGS=
40835 else
40836         PLAT=UNIX
40837 fi
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
40879
40880
40881
40882
40883
40884
40885
40886
40887
40888
40889
40890
40891
40892
40893
40894
40895
40896
40897
40898
40899
40900
40901
40902
40903
40904
40905
40906
40907
40908
40909
40910
40911
40912
40913
40914
40915
40916
40917
40918
40919
40920
40921
40922
40923 # Check whether --with-xxinstall or --without-xxinstall was given.
40924 if test "${with_xxinstall+set}" = set; then
40925   withval="$with_xxinstall"
40926
40927 fi;
40928
40929
40930                                                                                                                                                                                                                                                                                                                                                                                                       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-sock/Makefile:build/top.mk:servers/slapd/back-sock/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"
40931
40932
40933           ac_config_commands="$ac_config_commands default"
40934
40935
40936
40937 test "x$prefix" = xNONE && prefix=$ac_default_prefix
40938 # Let make expand exec_prefix.
40939 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
40940
40941 # VPATH may cause trouble with some makes, so we remove $(srcdir),
40942 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
40943 # trailing colons and then remove the whole line if VPATH becomes empty
40944 # (actually we leave an empty line to preserve line numbers).
40945 if test "x$srcdir" = x.; then
40946   ac_vpsub='/^[  ]*VPATH[        ]*=/{
40947 s/:*\$(srcdir):*/:/;
40948 s/:*\${srcdir}:*/:/;
40949 s/:*@srcdir@:*/:/;
40950 s/^\([^=]*=[     ]*\):*/\1/;
40951 s/:*$//;
40952 s/^[^=]*=[       ]*$//;
40953 }'
40954 fi
40955
40956 DEFS=-DHAVE_CONFIG_H
40957
40958 ac_libobjs=
40959 ac_ltlibobjs=
40960 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
40961   # 1. Remove the extension, and $U if already installed.
40962   ac_i=`echo "$ac_i" |
40963          sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
40964   # 2. Add them.
40965   ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
40966   ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
40967 done
40968 LIBOBJS=$ac_libobjs
40969
40970 LTLIBOBJS=$ac_ltlibobjs
40971
40972
40973 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
40974   { { echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined.
40975 Usually this means the macro was only invoked conditionally." >&5
40976 echo "$as_me: error: conditional \"AMDEP\" was never defined.
40977 Usually this means the macro was only invoked conditionally." >&2;}
40978    { (exit 1); exit 1; }; }
40979 fi
40980 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
40981   { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
40982 Usually this means the macro was only invoked conditionally." >&5
40983 echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
40984 Usually this means the macro was only invoked conditionally." >&2;}
40985    { (exit 1); exit 1; }; }
40986 fi
40987 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
40988   { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
40989 Usually this means the macro was only invoked conditionally." >&5
40990 echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
40991 Usually this means the macro was only invoked conditionally." >&2;}
40992    { (exit 1); exit 1; }; }
40993 fi
40994
40995 : ${CONFIG_STATUS=./config.status}
40996 ac_clean_files_save=$ac_clean_files
40997 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
40998 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
40999 echo "$as_me: creating $CONFIG_STATUS" >&6;}
41000 cat >$CONFIG_STATUS <<_ACEOF
41001 #! $SHELL
41002 # Generated by $as_me.
41003 # Run this file to recreate the current configuration.
41004 # Compiler output produced by configure, useful for debugging
41005 # configure, is in config.log if it exists.
41006
41007 debug=false
41008 ac_cs_recheck=false
41009 ac_cs_silent=false
41010 SHELL=\${CONFIG_SHELL-$SHELL}
41011 _ACEOF
41012
41013 cat >>$CONFIG_STATUS <<\_ACEOF
41014 ## --------------------- ##
41015 ## M4sh Initialization.  ##
41016 ## --------------------- ##
41017
41018 # Be Bourne compatible
41019 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
41020   emulate sh
41021   NULLCMD=:
41022   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
41023   # is contrary to our usage.  Disable this feature.
41024   alias -g '${1+"$@"}'='"$@"'
41025 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
41026   set -o posix
41027 fi
41028 DUALCASE=1; export DUALCASE # for MKS sh
41029
41030 # Support unset when possible.
41031 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
41032   as_unset=unset
41033 else
41034   as_unset=false
41035 fi
41036
41037
41038 # Work around bugs in pre-3.0 UWIN ksh.
41039 $as_unset ENV MAIL MAILPATH
41040 PS1='$ '
41041 PS2='> '
41042 PS4='+ '
41043
41044 # NLS nuisances.
41045 for as_var in \
41046   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
41047   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
41048   LC_TELEPHONE LC_TIME
41049 do
41050   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
41051     eval $as_var=C; export $as_var
41052   else
41053     $as_unset $as_var
41054   fi
41055 done
41056
41057 # Required to use basename.
41058 if expr a : '\(a\)' >/dev/null 2>&1; then
41059   as_expr=expr
41060 else
41061   as_expr=false
41062 fi
41063
41064 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
41065   as_basename=basename
41066 else
41067   as_basename=false
41068 fi
41069
41070
41071 # Name of the executable.
41072 as_me=`$as_basename "$0" ||
41073 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
41074          X"$0" : 'X\(//\)$' \| \
41075          X"$0" : 'X\(/\)$' \| \
41076          .     : '\(.\)' 2>/dev/null ||
41077 echo X/"$0" |
41078     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
41079           /^X\/\(\/\/\)$/{ s//\1/; q; }
41080           /^X\/\(\/\).*/{ s//\1/; q; }
41081           s/.*/./; q'`
41082
41083
41084 # PATH needs CR, and LINENO needs CR and PATH.
41085 # Avoid depending upon Character Ranges.
41086 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
41087 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
41088 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
41089 as_cr_digits='0123456789'
41090 as_cr_alnum=$as_cr_Letters$as_cr_digits
41091
41092 # The user is always right.
41093 if test "${PATH_SEPARATOR+set}" != set; then
41094   echo "#! /bin/sh" >conf$$.sh
41095   echo  "exit 0"   >>conf$$.sh
41096   chmod +x conf$$.sh
41097   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
41098     PATH_SEPARATOR=';'
41099   else
41100     PATH_SEPARATOR=:
41101   fi
41102   rm -f conf$$.sh
41103 fi
41104
41105
41106   as_lineno_1=$LINENO
41107   as_lineno_2=$LINENO
41108   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
41109   test "x$as_lineno_1" != "x$as_lineno_2" &&
41110   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
41111   # Find who we are.  Look in the path if we contain no path at all
41112   # relative or not.
41113   case $0 in
41114     *[\\/]* ) as_myself=$0 ;;
41115     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
41116 for as_dir in $PATH
41117 do
41118   IFS=$as_save_IFS
41119   test -z "$as_dir" && as_dir=.
41120   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
41121 done
41122
41123        ;;
41124   esac
41125   # We did not find ourselves, most probably we were run as `sh COMMAND'
41126   # in which case we are not to be found in the path.
41127   if test "x$as_myself" = x; then
41128     as_myself=$0
41129   fi
41130   if test ! -f "$as_myself"; then
41131     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
41132 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
41133    { (exit 1); exit 1; }; }
41134   fi
41135   case $CONFIG_SHELL in
41136   '')
41137     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
41138 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
41139 do
41140   IFS=$as_save_IFS
41141   test -z "$as_dir" && as_dir=.
41142   for as_base in sh bash ksh sh5; do
41143          case $as_dir in
41144          /*)
41145            if ("$as_dir/$as_base" -c '
41146   as_lineno_1=$LINENO
41147   as_lineno_2=$LINENO
41148   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
41149   test "x$as_lineno_1" != "x$as_lineno_2" &&
41150   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
41151              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
41152              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
41153              CONFIG_SHELL=$as_dir/$as_base
41154              export CONFIG_SHELL
41155              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
41156            fi;;
41157          esac
41158        done
41159 done
41160 ;;
41161   esac
41162
41163   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
41164   # uniformly replaced by the line number.  The first 'sed' inserts a
41165   # line-number line before each line; the second 'sed' does the real
41166   # work.  The second script uses 'N' to pair each line-number line
41167   # with the numbered line, and appends trailing '-' during
41168   # substitution so that $LINENO is not a special case at line end.
41169   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
41170   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
41171   sed '=' <$as_myself |
41172     sed '
41173       N
41174       s,$,-,
41175       : loop
41176       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
41177       t loop
41178       s,-$,,
41179       s,^['$as_cr_digits']*\n,,
41180     ' >$as_me.lineno &&
41181   chmod +x $as_me.lineno ||
41182     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
41183 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
41184    { (exit 1); exit 1; }; }
41185
41186   # Don't try to exec as it changes $[0], causing all sort of problems
41187   # (the dirname of $[0] is not the place where we might find the
41188   # original and so on.  Autoconf is especially sensible to this).
41189   . ./$as_me.lineno
41190   # Exit status is that of the last command.
41191   exit
41192 }
41193
41194
41195 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
41196   *c*,-n*) ECHO_N= ECHO_C='
41197 ' ECHO_T='      ' ;;
41198   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
41199   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
41200 esac
41201
41202 if expr a : '\(a\)' >/dev/null 2>&1; then
41203   as_expr=expr
41204 else
41205   as_expr=false
41206 fi
41207
41208 rm -f conf$$ conf$$.exe conf$$.file
41209 echo >conf$$.file
41210 if ln -s conf$$.file conf$$ 2>/dev/null; then
41211   # We could just check for DJGPP; but this test a) works b) is more generic
41212   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
41213   if test -f conf$$.exe; then
41214     # Don't use ln at all; we don't have any links
41215     as_ln_s='cp -p'
41216   else
41217     as_ln_s='ln -s'
41218   fi
41219 elif ln conf$$.file conf$$ 2>/dev/null; then
41220   as_ln_s=ln
41221 else
41222   as_ln_s='cp -p'
41223 fi
41224 rm -f conf$$ conf$$.exe conf$$.file
41225
41226 if mkdir -p . 2>/dev/null; then
41227   as_mkdir_p=:
41228 else
41229   test -d ./-p && rmdir ./-p
41230   as_mkdir_p=false
41231 fi
41232
41233 as_executable_p="test -f"
41234
41235 # Sed expression to map a string onto a valid CPP name.
41236 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
41237
41238 # Sed expression to map a string onto a valid variable name.
41239 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
41240
41241
41242 # IFS
41243 # We need space, tab and new line, in precisely that order.
41244 as_nl='
41245 '
41246 IFS="   $as_nl"
41247
41248 # CDPATH.
41249 $as_unset CDPATH
41250
41251 exec 6>&1
41252
41253 # Open the log real soon, to keep \$[0] and so on meaningful, and to
41254 # report actual input values of CONFIG_FILES etc. instead of their
41255 # values after options handling.  Logging --version etc. is OK.
41256 exec 5>>config.log
41257 {
41258   echo
41259   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
41260 ## Running $as_me. ##
41261 _ASBOX
41262 } >&5
41263 cat >&5 <<_CSEOF
41264
41265 This file was extended by $as_me, which was
41266 generated by GNU Autoconf 2.59.  Invocation command line was
41267
41268   CONFIG_FILES    = $CONFIG_FILES
41269   CONFIG_HEADERS  = $CONFIG_HEADERS
41270   CONFIG_LINKS    = $CONFIG_LINKS
41271   CONFIG_COMMANDS = $CONFIG_COMMANDS
41272   $ $0 $@
41273
41274 _CSEOF
41275 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
41276 echo >&5
41277 _ACEOF
41278
41279 # Files that config.status was made for.
41280 if test -n "$ac_config_files"; then
41281   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
41282 fi
41283
41284 if test -n "$ac_config_headers"; then
41285   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
41286 fi
41287
41288 if test -n "$ac_config_links"; then
41289   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
41290 fi
41291
41292 if test -n "$ac_config_commands"; then
41293   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
41294 fi
41295
41296 cat >>$CONFIG_STATUS <<\_ACEOF
41297
41298 ac_cs_usage="\
41299 \`$as_me' instantiates files from templates according to the
41300 current configuration.
41301
41302 Usage: $0 [OPTIONS] [FILE]...
41303
41304   -h, --help       print this help, then exit
41305   -V, --version    print version number, then exit
41306   -q, --quiet      do not print progress messages
41307   -d, --debug      don't remove temporary files
41308       --recheck    update $as_me by reconfiguring in the same conditions
41309   --file=FILE[:TEMPLATE]
41310                    instantiate the configuration file FILE
41311   --header=FILE[:TEMPLATE]
41312                    instantiate the configuration header FILE
41313
41314 Configuration files:
41315 $config_files
41316
41317 Configuration headers:
41318 $config_headers
41319
41320 Configuration commands:
41321 $config_commands
41322
41323 Report bugs to <bug-autoconf@gnu.org>."
41324 _ACEOF
41325
41326 cat >>$CONFIG_STATUS <<_ACEOF
41327 ac_cs_version="\\
41328 config.status
41329 configured by $0, generated by GNU Autoconf 2.59,
41330   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
41331
41332 Copyright (C) 2003 Free Software Foundation, Inc.
41333 This config.status script is free software; the Free Software Foundation
41334 gives unlimited permission to copy, distribute and modify it."
41335 srcdir=$srcdir
41336 INSTALL="$INSTALL"
41337 _ACEOF
41338
41339 cat >>$CONFIG_STATUS <<\_ACEOF
41340 # If no file are specified by the user, then we need to provide default
41341 # value.  By we need to know if files were specified by the user.
41342 ac_need_defaults=:
41343 while test $# != 0
41344 do
41345   case $1 in
41346   --*=*)
41347     ac_option=`expr "x$1" : 'x\([^=]*\)='`
41348     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
41349     ac_shift=:
41350     ;;
41351   -*)
41352     ac_option=$1
41353     ac_optarg=$2
41354     ac_shift=shift
41355     ;;
41356   *) # This is not an option, so the user has probably given explicit
41357      # arguments.
41358      ac_option=$1
41359      ac_need_defaults=false;;
41360   esac
41361
41362   case $ac_option in
41363   # Handling of the options.
41364 _ACEOF
41365 cat >>$CONFIG_STATUS <<\_ACEOF
41366   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
41367     ac_cs_recheck=: ;;
41368   --version | --vers* | -V )
41369     echo "$ac_cs_version"; exit 0 ;;
41370   --he | --h)
41371     # Conflict between --help and --header
41372     { { echo "$as_me:$LINENO: error: ambiguous option: $1
41373 Try \`$0 --help' for more information." >&5
41374 echo "$as_me: error: ambiguous option: $1
41375 Try \`$0 --help' for more information." >&2;}
41376    { (exit 1); exit 1; }; };;
41377   --help | --hel | -h )
41378     echo "$ac_cs_usage"; exit 0 ;;
41379   --debug | --d* | -d )
41380     debug=: ;;
41381   --file | --fil | --fi | --f )
41382     $ac_shift
41383     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
41384     ac_need_defaults=false;;
41385   --header | --heade | --head | --hea )
41386     $ac_shift
41387     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
41388     ac_need_defaults=false;;
41389   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
41390   | -silent | --silent | --silen | --sile | --sil | --si | --s)
41391     ac_cs_silent=: ;;
41392
41393   # This is an error.
41394   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
41395 Try \`$0 --help' for more information." >&5
41396 echo "$as_me: error: unrecognized option: $1
41397 Try \`$0 --help' for more information." >&2;}
41398    { (exit 1); exit 1; }; } ;;
41399
41400   *) ac_config_targets="$ac_config_targets $1" ;;
41401
41402   esac
41403   shift
41404 done
41405
41406 ac_configure_extra_args=
41407
41408 if $ac_cs_silent; then
41409   exec 6>/dev/null
41410   ac_configure_extra_args="$ac_configure_extra_args --silent"
41411 fi
41412
41413 _ACEOF
41414 cat >>$CONFIG_STATUS <<_ACEOF
41415 if \$ac_cs_recheck; then
41416   echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
41417   exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
41418 fi
41419
41420 _ACEOF
41421
41422 cat >>$CONFIG_STATUS <<_ACEOF
41423 #
41424 # INIT-COMMANDS section.
41425 #
41426
41427 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
41428
41429 STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS"
41430 STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS"
41431
41432
41433 _ACEOF
41434
41435
41436
41437 cat >>$CONFIG_STATUS <<\_ACEOF
41438 for ac_config_target in $ac_config_targets
41439 do
41440   case "$ac_config_target" in
41441   # Handling of arguments.
41442   "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile:build/top.mk:Makefile.in:build/dir.mk" ;;
41443   "doc/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/Makefile:build/top.mk:doc/Makefile.in:build/dir.mk" ;;
41444   "doc/man/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/Makefile:build/top.mk:doc/man/Makefile.in:build/dir.mk" ;;
41445   "doc/man/man1/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man1/Makefile:build/top.mk:doc/man/man1/Makefile.in:build/man.mk" ;;
41446   "doc/man/man3/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man3/Makefile:build/top.mk:doc/man/man3/Makefile.in:build/man.mk" ;;
41447   "doc/man/man5/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man5/Makefile:build/top.mk:doc/man/man5/Makefile.in:build/man.mk" ;;
41448   "doc/man/man8/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man8/Makefile:build/top.mk:doc/man/man8/Makefile.in:build/man.mk" ;;
41449   "clients/Makefile" ) CONFIG_FILES="$CONFIG_FILES clients/Makefile:build/top.mk:clients/Makefile.in:build/dir.mk" ;;
41450   "clients/tools/Makefile" ) CONFIG_FILES="$CONFIG_FILES clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk" ;;
41451   "include/Makefile" ) CONFIG_FILES="$CONFIG_FILES include/Makefile:build/top.mk:include/Makefile.in" ;;
41452   "libraries/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/Makefile:build/top.mk:libraries/Makefile.in:build/dir.mk" ;;
41453   "libraries/liblber/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblber/Makefile:build/top.mk:libraries/liblber/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
41454   "libraries/libldap/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/libldap/Makefile:build/top.mk:libraries/libldap/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
41455   "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" ;;
41456   "libraries/liblunicode/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblunicode/Makefile:build/top.mk:libraries/liblunicode/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
41457   "libraries/liblutil/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblutil/Makefile:build/top.mk:libraries/liblutil/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
41458   "libraries/librewrite/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/librewrite/Makefile:build/top.mk:libraries/librewrite/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
41459   "servers/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/Makefile:build/top.mk:servers/Makefile.in:build/dir.mk" ;;
41460   "servers/slapd/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/Makefile:build/top.mk:servers/slapd/Makefile.in:build/srv.mk" ;;
41461   "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" ;;
41462   "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" ;;
41463   "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" ;;
41464   "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" ;;
41465   "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" ;;
41466   "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" ;;
41467   "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" ;;
41468   "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" ;;
41469   "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" ;;
41470   "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" ;;
41471   "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" ;;
41472   "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" ;;
41473   "servers/slapd/back-sock/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-sock/Makefile:build/top.mk:servers/slapd/back-sock/Makefile.in:build/mod.mk" ;;
41474   "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" ;;
41475   "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" ;;
41476   "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" ;;
41477   "servers/slapd/overlays/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/overlays/Makefile:build/top.mk:servers/slapd/overlays/Makefile.in:build/lib.mk" ;;
41478   "tests/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/Makefile:build/top.mk:tests/Makefile.in:build/dir.mk" ;;
41479   "tests/run" ) CONFIG_FILES="$CONFIG_FILES tests/run" ;;
41480   "tests/progs/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/progs/Makefile:build/top.mk:tests/progs/Makefile.in:build/rules.mk" ;;
41481   "depfiles" ) CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
41482   "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
41483   "include/portable.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/portable.h:include/portable.hin" ;;
41484   "include/ldap_features.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ldap_features.h:include/ldap_features.hin" ;;
41485   "include/lber_types.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/lber_types.h:include/lber_types.hin" ;;
41486   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
41487 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
41488    { (exit 1); exit 1; }; };;
41489   esac
41490 done
41491
41492 # If the user did not use the arguments to specify the items to instantiate,
41493 # then the envvar interface is used.  Set only those that are not.
41494 # We use the long form for the default assignment because of an extremely
41495 # bizarre bug on SunOS 4.1.3.
41496 if $ac_need_defaults; then
41497   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
41498   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
41499   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
41500 fi
41501
41502 # Have a temporary directory for convenience.  Make it in the build tree
41503 # simply because there is no reason to put it here, and in addition,
41504 # creating and moving files from /tmp can sometimes cause problems.
41505 # Create a temporary directory, and hook for its removal unless debugging.
41506 $debug ||
41507 {
41508   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
41509   trap '{ (exit 1); exit 1; }' 1 2 13 15
41510 }
41511
41512 # Create a (secure) tmp directory for tmp files.
41513
41514 {
41515   tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
41516   test -n "$tmp" && test -d "$tmp"
41517 }  ||
41518 {
41519   tmp=./confstat$$-$RANDOM
41520   (umask 077 && mkdir $tmp)
41521 } ||
41522 {
41523    echo "$me: cannot create a temporary directory in ." >&2
41524    { (exit 1); exit 1; }
41525 }
41526
41527 _ACEOF
41528
41529 cat >>$CONFIG_STATUS <<_ACEOF
41530
41531 #
41532 # CONFIG_FILES section.
41533 #
41534
41535 # No need to generate the scripts if there are no CONFIG_FILES.
41536 # This happens for instance when ./config.status config.h
41537 if test -n "\$CONFIG_FILES"; then
41538   # Protect against being on the right side of a sed subst in config.status.
41539   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
41540    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
41541 s,@SHELL@,$SHELL,;t t
41542 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
41543 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
41544 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
41545 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
41546 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
41547 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
41548 s,@exec_prefix@,$exec_prefix,;t t
41549 s,@prefix@,$prefix,;t t
41550 s,@program_transform_name@,$program_transform_name,;t t
41551 s,@bindir@,$bindir,;t t
41552 s,@sbindir@,$sbindir,;t t
41553 s,@libexecdir@,$libexecdir,;t t
41554 s,@datadir@,$datadir,;t t
41555 s,@sysconfdir@,$sysconfdir,;t t
41556 s,@sharedstatedir@,$sharedstatedir,;t t
41557 s,@localstatedir@,$localstatedir,;t t
41558 s,@libdir@,$libdir,;t t
41559 s,@includedir@,$includedir,;t t
41560 s,@oldincludedir@,$oldincludedir,;t t
41561 s,@infodir@,$infodir,;t t
41562 s,@mandir@,$mandir,;t t
41563 s,@build_alias@,$build_alias,;t t
41564 s,@host_alias@,$host_alias,;t t
41565 s,@target_alias@,$target_alias,;t t
41566 s,@DEFS@,$DEFS,;t t
41567 s,@ECHO_C@,$ECHO_C,;t t
41568 s,@ECHO_N@,$ECHO_N,;t t
41569 s,@ECHO_T@,$ECHO_T,;t t
41570 s,@LIBS@,$LIBS,;t t
41571 s,@build@,$build,;t t
41572 s,@build_cpu@,$build_cpu,;t t
41573 s,@build_vendor@,$build_vendor,;t t
41574 s,@build_os@,$build_os,;t t
41575 s,@host@,$host,;t t
41576 s,@host_cpu@,$host_cpu,;t t
41577 s,@host_vendor@,$host_vendor,;t t
41578 s,@host_os@,$host_os,;t t
41579 s,@target@,$target,;t t
41580 s,@target_cpu@,$target_cpu,;t t
41581 s,@target_vendor@,$target_vendor,;t t
41582 s,@target_os@,$target_os,;t t
41583 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
41584 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
41585 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
41586 s,@CYGPATH_W@,$CYGPATH_W,;t t
41587 s,@PACKAGE@,$PACKAGE,;t t
41588 s,@VERSION@,$VERSION,;t t
41589 s,@ACLOCAL@,$ACLOCAL,;t t
41590 s,@AUTOCONF@,$AUTOCONF,;t t
41591 s,@AUTOMAKE@,$AUTOMAKE,;t t
41592 s,@AUTOHEADER@,$AUTOHEADER,;t t
41593 s,@MAKEINFO@,$MAKEINFO,;t t
41594 s,@install_sh@,$install_sh,;t t
41595 s,@STRIP@,$STRIP,;t t
41596 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
41597 s,@INSTALL_STRIP_PROGRAM@,$INSTALL_STRIP_PROGRAM,;t t
41598 s,@mkdir_p@,$mkdir_p,;t t
41599 s,@AWK@,$AWK,;t t
41600 s,@SET_MAKE@,$SET_MAKE,;t t
41601 s,@am__leading_dot@,$am__leading_dot,;t t
41602 s,@AMTAR@,$AMTAR,;t t
41603 s,@am__tar@,$am__tar,;t t
41604 s,@am__untar@,$am__untar,;t t
41605 s,@OPENLDAP_LIBRELEASE@,$OPENLDAP_LIBRELEASE,;t t
41606 s,@OPENLDAP_LIBVERSION@,$OPENLDAP_LIBVERSION,;t t
41607 s,@OPENLDAP_RELEASE_DATE@,$OPENLDAP_RELEASE_DATE,;t t
41608 s,@top_builddir@,$top_builddir,;t t
41609 s,@ldap_subdir@,$ldap_subdir,;t t
41610 s,@CC@,$CC,;t t
41611 s,@AR@,$AR,;t t
41612 s,@CFLAGS@,$CFLAGS,;t t
41613 s,@LDFLAGS@,$LDFLAGS,;t t
41614 s,@CPPFLAGS@,$CPPFLAGS,;t t
41615 s,@ac_ct_CC@,$ac_ct_CC,;t t
41616 s,@EXEEXT@,$EXEEXT,;t t
41617 s,@OBJEXT@,$OBJEXT,;t t
41618 s,@DEPDIR@,$DEPDIR,;t t
41619 s,@am__include@,$am__include,;t t
41620 s,@am__quote@,$am__quote,;t t
41621 s,@AMDEP_TRUE@,$AMDEP_TRUE,;t t
41622 s,@AMDEP_FALSE@,$AMDEP_FALSE,;t t
41623 s,@AMDEPBACKSLASH@,$AMDEPBACKSLASH,;t t
41624 s,@CCDEPMODE@,$CCDEPMODE,;t t
41625 s,@am__fastdepCC_TRUE@,$am__fastdepCC_TRUE,;t t
41626 s,@am__fastdepCC_FALSE@,$am__fastdepCC_FALSE,;t t
41627 s,@EGREP@,$EGREP,;t t
41628 s,@LN_S@,$LN_S,;t t
41629 s,@ECHO@,$ECHO,;t t
41630 s,@ac_ct_AR@,$ac_ct_AR,;t t
41631 s,@RANLIB@,$RANLIB,;t t
41632 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
41633 s,@DLLTOOL@,$DLLTOOL,;t t
41634 s,@ac_ct_DLLTOOL@,$ac_ct_DLLTOOL,;t t
41635 s,@AS@,$AS,;t t
41636 s,@ac_ct_AS@,$ac_ct_AS,;t t
41637 s,@OBJDUMP@,$OBJDUMP,;t t
41638 s,@ac_ct_OBJDUMP@,$ac_ct_OBJDUMP,;t t
41639 s,@CPP@,$CPP,;t t
41640 s,@LIBTOOL@,$LIBTOOL,;t t
41641 s,@PERLBIN@,$PERLBIN,;t t
41642 s,@OL_MKDEP@,$OL_MKDEP,;t t
41643 s,@OL_MKDEP_FLAGS@,$OL_MKDEP_FLAGS,;t t
41644 s,@LTSTATIC@,$LTSTATIC,;t t
41645 s,@LIBOBJS@,$LIBOBJS,;t t
41646 s,@LIBSRCS@,$LIBSRCS,;t t
41647 s,@PLAT@,$PLAT,;t t
41648 s,@WITH_SASL@,$WITH_SASL,;t t
41649 s,@WITH_TLS@,$WITH_TLS,;t t
41650 s,@WITH_MODULES_ENABLED@,$WITH_MODULES_ENABLED,;t t
41651 s,@WITH_ACI_ENABLED@,$WITH_ACI_ENABLED,;t t
41652 s,@BUILD_THREAD@,$BUILD_THREAD,;t t
41653 s,@BUILD_LIBS_DYNAMIC@,$BUILD_LIBS_DYNAMIC,;t t
41654 s,@BUILD_SLAPD@,$BUILD_SLAPD,;t t
41655 s,@BUILD_SLAPI@,$BUILD_SLAPI,;t t
41656 s,@SLAPD_SLAPI_DEPEND@,$SLAPD_SLAPI_DEPEND,;t t
41657 s,@BUILD_BDB@,$BUILD_BDB,;t t
41658 s,@BUILD_DNSSRV@,$BUILD_DNSSRV,;t t
41659 s,@BUILD_HDB@,$BUILD_HDB,;t t
41660 s,@BUILD_LDAP@,$BUILD_LDAP,;t t
41661 s,@BUILD_META@,$BUILD_META,;t t
41662 s,@BUILD_MONITOR@,$BUILD_MONITOR,;t t
41663 s,@BUILD_NULL@,$BUILD_NULL,;t t
41664 s,@BUILD_PASSWD@,$BUILD_PASSWD,;t t
41665 s,@BUILD_RELAY@,$BUILD_RELAY,;t t
41666 s,@BUILD_PERL@,$BUILD_PERL,;t t
41667 s,@BUILD_SHELL@,$BUILD_SHELL,;t t
41668 s,@BUILD_SOCK@,$BUILD_SOCK,;t t
41669 s,@BUILD_SQL@,$BUILD_SQL,;t t
41670 s,@BUILD_ACCESSLOG@,$BUILD_ACCESSLOG,;t t
41671 s,@BUILD_AUDITLOG@,$BUILD_AUDITLOG,;t t
41672 s,@BUILD_CONSTRAINT@,$BUILD_CONSTRAINT,;t t
41673 s,@BUILD_DDS@,$BUILD_DDS,;t t
41674 s,@BUILD_DENYOP@,$BUILD_DENYOP,;t t
41675 s,@BUILD_DYNGROUP@,$BUILD_DYNGROUP,;t t
41676 s,@BUILD_DYNLIST@,$BUILD_DYNLIST,;t t
41677 s,@BUILD_LASTMOD@,$BUILD_LASTMOD,;t t
41678 s,@BUILD_MEMBEROF@,$BUILD_MEMBEROF,;t t
41679 s,@BUILD_PPOLICY@,$BUILD_PPOLICY,;t t
41680 s,@BUILD_PROXYCACHE@,$BUILD_PROXYCACHE,;t t
41681 s,@BUILD_REFINT@,$BUILD_REFINT,;t t
41682 s,@BUILD_RETCODE@,$BUILD_RETCODE,;t t
41683 s,@BUILD_RWM@,$BUILD_RWM,;t t
41684 s,@BUILD_SEQMOD@,$BUILD_SEQMOD,;t t
41685 s,@BUILD_SYNCPROV@,$BUILD_SYNCPROV,;t t
41686 s,@BUILD_TRANSLUCENT@,$BUILD_TRANSLUCENT,;t t
41687 s,@BUILD_UNIQUE@,$BUILD_UNIQUE,;t t
41688 s,@BUILD_VALSORT@,$BUILD_VALSORT,;t t
41689 s,@LDAP_LIBS@,$LDAP_LIBS,;t t
41690 s,@SLAPD_LIBS@,$SLAPD_LIBS,;t t
41691 s,@BDB_LIBS@,$BDB_LIBS,;t t
41692 s,@LTHREAD_LIBS@,$LTHREAD_LIBS,;t t
41693 s,@LUTIL_LIBS@,$LUTIL_LIBS,;t t
41694 s,@WRAP_LIBS@,$WRAP_LIBS,;t t
41695 s,@SLAPD_MODULES_CPPFLAGS@,$SLAPD_MODULES_CPPFLAGS,;t t
41696 s,@SLAPD_MODULES_LDFLAGS@,$SLAPD_MODULES_LDFLAGS,;t t
41697 s,@SLAPD_NO_STATIC@,$SLAPD_NO_STATIC,;t t
41698 s,@SLAPD_STATIC_BACKENDS@,$SLAPD_STATIC_BACKENDS,;t t
41699 s,@SLAPD_DYNAMIC_BACKENDS@,$SLAPD_DYNAMIC_BACKENDS,;t t
41700 s,@SLAPD_STATIC_OVERLAYS@,$SLAPD_STATIC_OVERLAYS,;t t
41701 s,@SLAPD_DYNAMIC_OVERLAYS@,$SLAPD_DYNAMIC_OVERLAYS,;t t
41702 s,@PERL_CPPFLAGS@,$PERL_CPPFLAGS,;t t
41703 s,@SLAPD_PERL_LDFLAGS@,$SLAPD_PERL_LDFLAGS,;t t
41704 s,@MOD_PERL_LDFLAGS@,$MOD_PERL_LDFLAGS,;t t
41705 s,@KRB4_LIBS@,$KRB4_LIBS,;t t
41706 s,@KRB5_LIBS@,$KRB5_LIBS,;t t
41707 s,@SASL_LIBS@,$SASL_LIBS,;t t
41708 s,@TLS_LIBS@,$TLS_LIBS,;t t
41709 s,@MODULES_LIBS@,$MODULES_LIBS,;t t
41710 s,@SLAPI_LIBS@,$SLAPI_LIBS,;t t
41711 s,@LIBSLAPI@,$LIBSLAPI,;t t
41712 s,@LIBSLAPITOOLS@,$LIBSLAPITOOLS,;t t
41713 s,@AUTH_LIBS@,$AUTH_LIBS,;t t
41714 s,@ICU_LIBS@,$ICU_LIBS,;t t
41715 s,@SLAPD_SLP_LIBS@,$SLAPD_SLP_LIBS,;t t
41716 s,@SLAPD_GMP_LIBS@,$SLAPD_GMP_LIBS,;t t
41717 s,@SLAPD_SQL_LDFLAGS@,$SLAPD_SQL_LDFLAGS,;t t
41718 s,@SLAPD_SQL_LIBS@,$SLAPD_SQL_LIBS,;t t
41719 s,@SLAPD_SQL_INCLUDES@,$SLAPD_SQL_INCLUDES,;t t
41720 s,@LTLIBOBJS@,$LTLIBOBJS,;t t
41721 CEOF
41722
41723 _ACEOF
41724
41725   cat >>$CONFIG_STATUS <<\_ACEOF
41726   # Split the substitutions into bite-sized pieces for seds with
41727   # small command number limits, like on Digital OSF/1 and HP-UX.
41728   ac_max_sed_lines=48
41729   ac_sed_frag=1 # Number of current file.
41730   ac_beg=1 # First line for current file.
41731   ac_end=$ac_max_sed_lines # Line after last line for current file.
41732   ac_more_lines=:
41733   ac_sed_cmds=
41734   while $ac_more_lines; do
41735     if test $ac_beg -gt 1; then
41736       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
41737     else
41738       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
41739     fi
41740     if test ! -s $tmp/subs.frag; then
41741       ac_more_lines=false
41742     else
41743       # The purpose of the label and of the branching condition is to
41744       # speed up the sed processing (if there are no `@' at all, there
41745       # is no need to browse any of the substitutions).
41746       # These are the two extra sed commands mentioned above.
41747       (echo ':t
41748   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
41749       if test -z "$ac_sed_cmds"; then
41750         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
41751       else
41752         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
41753       fi
41754       ac_sed_frag=`expr $ac_sed_frag + 1`
41755       ac_beg=$ac_end
41756       ac_end=`expr $ac_end + $ac_max_sed_lines`
41757     fi
41758   done
41759   if test -z "$ac_sed_cmds"; then
41760     ac_sed_cmds=cat
41761   fi
41762 fi # test -n "$CONFIG_FILES"
41763
41764 _ACEOF
41765 cat >>$CONFIG_STATUS <<\_ACEOF
41766 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
41767   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
41768   case $ac_file in
41769   - | *:- | *:-:* ) # input from stdin
41770         cat >$tmp/stdin
41771         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
41772         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
41773   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
41774         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
41775   * )   ac_file_in=$ac_file.in ;;
41776   esac
41777
41778   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
41779   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
41780 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
41781          X"$ac_file" : 'X\(//\)[^/]' \| \
41782          X"$ac_file" : 'X\(//\)$' \| \
41783          X"$ac_file" : 'X\(/\)' \| \
41784          .     : '\(.\)' 2>/dev/null ||
41785 echo X"$ac_file" |
41786     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
41787           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
41788           /^X\(\/\/\)$/{ s//\1/; q; }
41789           /^X\(\/\).*/{ s//\1/; q; }
41790           s/.*/./; q'`
41791   { if $as_mkdir_p; then
41792     mkdir -p "$ac_dir"
41793   else
41794     as_dir="$ac_dir"
41795     as_dirs=
41796     while test ! -d "$as_dir"; do
41797       as_dirs="$as_dir $as_dirs"
41798       as_dir=`(dirname "$as_dir") 2>/dev/null ||
41799 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
41800          X"$as_dir" : 'X\(//\)[^/]' \| \
41801          X"$as_dir" : 'X\(//\)$' \| \
41802          X"$as_dir" : 'X\(/\)' \| \
41803          .     : '\(.\)' 2>/dev/null ||
41804 echo X"$as_dir" |
41805     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
41806           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
41807           /^X\(\/\/\)$/{ s//\1/; q; }
41808           /^X\(\/\).*/{ s//\1/; q; }
41809           s/.*/./; q'`
41810     done
41811     test ! -n "$as_dirs" || mkdir $as_dirs
41812   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
41813 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
41814    { (exit 1); exit 1; }; }; }
41815
41816   ac_builddir=.
41817
41818 if test "$ac_dir" != .; then
41819   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
41820   # A "../" for each directory in $ac_dir_suffix.
41821   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
41822 else
41823   ac_dir_suffix= ac_top_builddir=
41824 fi
41825
41826 case $srcdir in
41827   .)  # No --srcdir option.  We are building in place.
41828     ac_srcdir=.
41829     if test -z "$ac_top_builddir"; then
41830        ac_top_srcdir=.
41831     else
41832        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
41833     fi ;;
41834   [\\/]* | ?:[\\/]* )  # Absolute path.
41835     ac_srcdir=$srcdir$ac_dir_suffix;
41836     ac_top_srcdir=$srcdir ;;
41837   *) # Relative path.
41838     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
41839     ac_top_srcdir=$ac_top_builddir$srcdir ;;
41840 esac
41841
41842 # Do not use `cd foo && pwd` to compute absolute paths, because
41843 # the directories may not exist.
41844 case `pwd` in
41845 .) ac_abs_builddir="$ac_dir";;
41846 *)
41847   case "$ac_dir" in
41848   .) ac_abs_builddir=`pwd`;;
41849   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
41850   *) ac_abs_builddir=`pwd`/"$ac_dir";;
41851   esac;;
41852 esac
41853 case $ac_abs_builddir in
41854 .) ac_abs_top_builddir=${ac_top_builddir}.;;
41855 *)
41856   case ${ac_top_builddir}. in
41857   .) ac_abs_top_builddir=$ac_abs_builddir;;
41858   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
41859   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
41860   esac;;
41861 esac
41862 case $ac_abs_builddir in
41863 .) ac_abs_srcdir=$ac_srcdir;;
41864 *)
41865   case $ac_srcdir in
41866   .) ac_abs_srcdir=$ac_abs_builddir;;
41867   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
41868   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
41869   esac;;
41870 esac
41871 case $ac_abs_builddir in
41872 .) ac_abs_top_srcdir=$ac_top_srcdir;;
41873 *)
41874   case $ac_top_srcdir in
41875   .) ac_abs_top_srcdir=$ac_abs_builddir;;
41876   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
41877   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
41878   esac;;
41879 esac
41880
41881
41882   case $INSTALL in
41883   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
41884   *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
41885   esac
41886
41887   if test x"$ac_file" != x-; then
41888     { echo "$as_me:$LINENO: creating $ac_file" >&5
41889 echo "$as_me: creating $ac_file" >&6;}
41890     rm -f "$ac_file"
41891   fi
41892   # Let's still pretend it is `configure' which instantiates (i.e., don't
41893   # use $as_me), people would be surprised to read:
41894   #    /* config.h.  Generated by config.status.  */
41895   if test x"$ac_file" = x-; then
41896     configure_input=
41897   else
41898     configure_input="$ac_file.  "
41899   fi
41900   configure_input=$configure_input"Generated from `echo $ac_file_in |
41901                                      sed 's,.*/,,'` by configure."
41902
41903   # First look for the input files in the build tree, otherwise in the
41904   # src tree.
41905   ac_file_inputs=`IFS=:
41906     for f in $ac_file_in; do
41907       case $f in
41908       -) echo $tmp/stdin ;;
41909       [\\/$]*)
41910          # Absolute (can't be DOS-style, as IFS=:)
41911          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
41912 echo "$as_me: error: cannot find input file: $f" >&2;}
41913    { (exit 1); exit 1; }; }
41914          echo "$f";;
41915       *) # Relative
41916          if test -f "$f"; then
41917            # Build tree
41918            echo "$f"
41919          elif test -f "$srcdir/$f"; then
41920            # Source tree
41921            echo "$srcdir/$f"
41922          else
41923            # /dev/null tree
41924            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
41925 echo "$as_me: error: cannot find input file: $f" >&2;}
41926    { (exit 1); exit 1; }; }
41927          fi;;
41928       esac
41929     done` || { (exit 1); exit 1; }
41930 _ACEOF
41931 cat >>$CONFIG_STATUS <<_ACEOF
41932   sed "$ac_vpsub
41933 $extrasub
41934 _ACEOF
41935 cat >>$CONFIG_STATUS <<\_ACEOF
41936 :t
41937 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
41938 s,@configure_input@,$configure_input,;t t
41939 s,@srcdir@,$ac_srcdir,;t t
41940 s,@abs_srcdir@,$ac_abs_srcdir,;t t
41941 s,@top_srcdir@,$ac_top_srcdir,;t t
41942 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
41943 s,@builddir@,$ac_builddir,;t t
41944 s,@abs_builddir@,$ac_abs_builddir,;t t
41945 s,@top_builddir@,$ac_top_builddir,;t t
41946 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
41947 s,@INSTALL@,$ac_INSTALL,;t t
41948 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
41949   rm -f $tmp/stdin
41950   if test x"$ac_file" != x-; then
41951     mv $tmp/out $ac_file
41952   else
41953     cat $tmp/out
41954     rm -f $tmp/out
41955   fi
41956
41957 done
41958 _ACEOF
41959 cat >>$CONFIG_STATUS <<\_ACEOF
41960
41961 #
41962 # CONFIG_HEADER section.
41963 #
41964
41965 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
41966 # NAME is the cpp macro being defined and VALUE is the value it is being given.
41967 #
41968 # ac_d sets the value in "#define NAME VALUE" lines.
41969 ac_dA='s,^\([    ]*\)#\([        ]*define[       ][      ]*\)'
41970 ac_dB='[         ].*$,\1#\2'
41971 ac_dC=' '
41972 ac_dD=',;t'
41973 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
41974 ac_uA='s,^\([    ]*\)#\([        ]*\)undef\([    ][      ]*\)'
41975 ac_uB='$,\1#\2define\3'
41976 ac_uC=' '
41977 ac_uD=',;t'
41978
41979 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
41980   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
41981   case $ac_file in
41982   - | *:- | *:-:* ) # input from stdin
41983         cat >$tmp/stdin
41984         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
41985         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
41986   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
41987         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
41988   * )   ac_file_in=$ac_file.in ;;
41989   esac
41990
41991   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
41992 echo "$as_me: creating $ac_file" >&6;}
41993
41994   # First look for the input files in the build tree, otherwise in the
41995   # src tree.
41996   ac_file_inputs=`IFS=:
41997     for f in $ac_file_in; do
41998       case $f in
41999       -) echo $tmp/stdin ;;
42000       [\\/$]*)
42001          # Absolute (can't be DOS-style, as IFS=:)
42002          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
42003 echo "$as_me: error: cannot find input file: $f" >&2;}
42004    { (exit 1); exit 1; }; }
42005          # Do quote $f, to prevent DOS paths from being IFS'd.
42006          echo "$f";;
42007       *) # Relative
42008          if test -f "$f"; then
42009            # Build tree
42010            echo "$f"
42011          elif test -f "$srcdir/$f"; then
42012            # Source tree
42013            echo "$srcdir/$f"
42014          else
42015            # /dev/null tree
42016            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
42017 echo "$as_me: error: cannot find input file: $f" >&2;}
42018    { (exit 1); exit 1; }; }
42019          fi;;
42020       esac
42021     done` || { (exit 1); exit 1; }
42022   # Remove the trailing spaces.
42023   sed 's/[       ]*$//' $ac_file_inputs >$tmp/in
42024
42025 _ACEOF
42026
42027 # Transform confdefs.h into two sed scripts, `conftest.defines' and
42028 # `conftest.undefs', that substitutes the proper values into
42029 # config.h.in to produce config.h.  The first handles `#define'
42030 # templates, and the second `#undef' templates.
42031 # And first: Protect against being on the right side of a sed subst in
42032 # config.status.  Protect against being in an unquoted here document
42033 # in config.status.
42034 rm -f conftest.defines conftest.undefs
42035 # Using a here document instead of a string reduces the quoting nightmare.
42036 # Putting comments in sed scripts is not portable.
42037 #
42038 # `end' is used to avoid that the second main sed command (meant for
42039 # 0-ary CPP macros) applies to n-ary macro definitions.
42040 # See the Autoconf documentation for `clear'.
42041 cat >confdef2sed.sed <<\_ACEOF
42042 s/[\\&,]/\\&/g
42043 s,[\\$`],\\&,g
42044 t clear
42045 : clear
42046 s,^[     ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
42047 t end
42048 s,^[     ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
42049 : end
42050 _ACEOF
42051 # If some macros were called several times there might be several times
42052 # the same #defines, which is useless.  Nevertheless, we may not want to
42053 # sort them, since we want the *last* AC-DEFINE to be honored.
42054 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
42055 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
42056 rm -f confdef2sed.sed
42057
42058 # This sed command replaces #undef with comments.  This is necessary, for
42059 # example, in the case of _POSIX_SOURCE, which is predefined and required
42060 # on some systems where configure will not decide to define it.
42061 cat >>conftest.undefs <<\_ACEOF
42062 s,^[     ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
42063 _ACEOF
42064
42065 # Break up conftest.defines because some shells have a limit on the size
42066 # of here documents, and old seds have small limits too (100 cmds).
42067 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
42068 echo '  if grep "^[      ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
42069 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
42070 echo '  :' >>$CONFIG_STATUS
42071 rm -f conftest.tail
42072 while grep . conftest.defines >/dev/null
42073 do
42074   # Write a limited-size here document to $tmp/defines.sed.
42075   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
42076   # Speed up: don't consider the non `#define' lines.
42077   echo '/^[      ]*#[    ]*define/!b' >>$CONFIG_STATUS
42078   # Work around the forget-to-reset-the-flag bug.
42079   echo 't clr' >>$CONFIG_STATUS
42080   echo ': clr' >>$CONFIG_STATUS
42081   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
42082   echo 'CEOF
42083   sed -f $tmp/defines.sed $tmp/in >$tmp/out
42084   rm -f $tmp/in
42085   mv $tmp/out $tmp/in
42086 ' >>$CONFIG_STATUS
42087   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
42088   rm -f conftest.defines
42089   mv conftest.tail conftest.defines
42090 done
42091 rm -f conftest.defines
42092 echo '  fi # grep' >>$CONFIG_STATUS
42093 echo >>$CONFIG_STATUS
42094
42095 # Break up conftest.undefs because some shells have a limit on the size
42096 # of here documents, and old seds have small limits too (100 cmds).
42097 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
42098 rm -f conftest.tail
42099 while grep . conftest.undefs >/dev/null
42100 do
42101   # Write a limited-size here document to $tmp/undefs.sed.
42102   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
42103   # Speed up: don't consider the non `#undef'
42104   echo '/^[      ]*#[    ]*undef/!b' >>$CONFIG_STATUS
42105   # Work around the forget-to-reset-the-flag bug.
42106   echo 't clr' >>$CONFIG_STATUS
42107   echo ': clr' >>$CONFIG_STATUS
42108   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
42109   echo 'CEOF
42110   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
42111   rm -f $tmp/in
42112   mv $tmp/out $tmp/in
42113 ' >>$CONFIG_STATUS
42114   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
42115   rm -f conftest.undefs
42116   mv conftest.tail conftest.undefs
42117 done
42118 rm -f conftest.undefs
42119
42120 cat >>$CONFIG_STATUS <<\_ACEOF
42121   # Let's still pretend it is `configure' which instantiates (i.e., don't
42122   # use $as_me), people would be surprised to read:
42123   #    /* config.h.  Generated by config.status.  */
42124   if test x"$ac_file" = x-; then
42125     echo "/* Generated by configure.  */" >$tmp/config.h
42126   else
42127     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
42128   fi
42129   cat $tmp/in >>$tmp/config.h
42130   rm -f $tmp/in
42131   if test x"$ac_file" != x-; then
42132     if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
42133       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
42134 echo "$as_me: $ac_file is unchanged" >&6;}
42135     else
42136       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
42137 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42138          X"$ac_file" : 'X\(//\)[^/]' \| \
42139          X"$ac_file" : 'X\(//\)$' \| \
42140          X"$ac_file" : 'X\(/\)' \| \
42141          .     : '\(.\)' 2>/dev/null ||
42142 echo X"$ac_file" |
42143     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42144           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42145           /^X\(\/\/\)$/{ s//\1/; q; }
42146           /^X\(\/\).*/{ s//\1/; q; }
42147           s/.*/./; q'`
42148       { if $as_mkdir_p; then
42149     mkdir -p "$ac_dir"
42150   else
42151     as_dir="$ac_dir"
42152     as_dirs=
42153     while test ! -d "$as_dir"; do
42154       as_dirs="$as_dir $as_dirs"
42155       as_dir=`(dirname "$as_dir") 2>/dev/null ||
42156 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42157          X"$as_dir" : 'X\(//\)[^/]' \| \
42158          X"$as_dir" : 'X\(//\)$' \| \
42159          X"$as_dir" : 'X\(/\)' \| \
42160          .     : '\(.\)' 2>/dev/null ||
42161 echo X"$as_dir" |
42162     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42163           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42164           /^X\(\/\/\)$/{ s//\1/; q; }
42165           /^X\(\/\).*/{ s//\1/; q; }
42166           s/.*/./; q'`
42167     done
42168     test ! -n "$as_dirs" || mkdir $as_dirs
42169   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
42170 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
42171    { (exit 1); exit 1; }; }; }
42172
42173       rm -f $ac_file
42174       mv $tmp/config.h $ac_file
42175     fi
42176   else
42177     cat $tmp/config.h
42178     rm -f $tmp/config.h
42179   fi
42180 # Compute $ac_file's index in $config_headers.
42181 _am_stamp_count=1
42182 for _am_header in $config_headers :; do
42183   case $_am_header in
42184     $ac_file | $ac_file:* )
42185       break ;;
42186     * )
42187       _am_stamp_count=`expr $_am_stamp_count + 1` ;;
42188   esac
42189 done
42190 echo "timestamp for $ac_file" >`(dirname $ac_file) 2>/dev/null ||
42191 $as_expr X$ac_file : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42192          X$ac_file : 'X\(//\)[^/]' \| \
42193          X$ac_file : 'X\(//\)$' \| \
42194          X$ac_file : 'X\(/\)' \| \
42195          .     : '\(.\)' 2>/dev/null ||
42196 echo X$ac_file |
42197     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42198           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42199           /^X\(\/\/\)$/{ s//\1/; q; }
42200           /^X\(\/\).*/{ s//\1/; q; }
42201           s/.*/./; q'`/stamp-h$_am_stamp_count
42202 done
42203 _ACEOF
42204 cat >>$CONFIG_STATUS <<\_ACEOF
42205
42206 #
42207 # CONFIG_COMMANDS section.
42208 #
42209 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
42210   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
42211   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
42212   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
42213 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42214          X"$ac_dest" : 'X\(//\)[^/]' \| \
42215          X"$ac_dest" : 'X\(//\)$' \| \
42216          X"$ac_dest" : 'X\(/\)' \| \
42217          .     : '\(.\)' 2>/dev/null ||
42218 echo X"$ac_dest" |
42219     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42220           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42221           /^X\(\/\/\)$/{ s//\1/; q; }
42222           /^X\(\/\).*/{ s//\1/; q; }
42223           s/.*/./; q'`
42224   { if $as_mkdir_p; then
42225     mkdir -p "$ac_dir"
42226   else
42227     as_dir="$ac_dir"
42228     as_dirs=
42229     while test ! -d "$as_dir"; do
42230       as_dirs="$as_dir $as_dirs"
42231       as_dir=`(dirname "$as_dir") 2>/dev/null ||
42232 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42233          X"$as_dir" : 'X\(//\)[^/]' \| \
42234          X"$as_dir" : 'X\(//\)$' \| \
42235          X"$as_dir" : 'X\(/\)' \| \
42236          .     : '\(.\)' 2>/dev/null ||
42237 echo X"$as_dir" |
42238     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42239           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42240           /^X\(\/\/\)$/{ s//\1/; q; }
42241           /^X\(\/\).*/{ s//\1/; q; }
42242           s/.*/./; q'`
42243     done
42244     test ! -n "$as_dirs" || mkdir $as_dirs
42245   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
42246 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
42247    { (exit 1); exit 1; }; }; }
42248
42249   ac_builddir=.
42250
42251 if test "$ac_dir" != .; then
42252   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
42253   # A "../" for each directory in $ac_dir_suffix.
42254   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
42255 else
42256   ac_dir_suffix= ac_top_builddir=
42257 fi
42258
42259 case $srcdir in
42260   .)  # No --srcdir option.  We are building in place.
42261     ac_srcdir=.
42262     if test -z "$ac_top_builddir"; then
42263        ac_top_srcdir=.
42264     else
42265        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
42266     fi ;;
42267   [\\/]* | ?:[\\/]* )  # Absolute path.
42268     ac_srcdir=$srcdir$ac_dir_suffix;
42269     ac_top_srcdir=$srcdir ;;
42270   *) # Relative path.
42271     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
42272     ac_top_srcdir=$ac_top_builddir$srcdir ;;
42273 esac
42274
42275 # Do not use `cd foo && pwd` to compute absolute paths, because
42276 # the directories may not exist.
42277 case `pwd` in
42278 .) ac_abs_builddir="$ac_dir";;
42279 *)
42280   case "$ac_dir" in
42281   .) ac_abs_builddir=`pwd`;;
42282   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
42283   *) ac_abs_builddir=`pwd`/"$ac_dir";;
42284   esac;;
42285 esac
42286 case $ac_abs_builddir in
42287 .) ac_abs_top_builddir=${ac_top_builddir}.;;
42288 *)
42289   case ${ac_top_builddir}. in
42290   .) ac_abs_top_builddir=$ac_abs_builddir;;
42291   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
42292   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
42293   esac;;
42294 esac
42295 case $ac_abs_builddir in
42296 .) ac_abs_srcdir=$ac_srcdir;;
42297 *)
42298   case $ac_srcdir in
42299   .) ac_abs_srcdir=$ac_abs_builddir;;
42300   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
42301   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
42302   esac;;
42303 esac
42304 case $ac_abs_builddir in
42305 .) ac_abs_top_srcdir=$ac_top_srcdir;;
42306 *)
42307   case $ac_top_srcdir in
42308   .) ac_abs_top_srcdir=$ac_abs_builddir;;
42309   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
42310   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
42311   esac;;
42312 esac
42313
42314
42315   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
42316 echo "$as_me: executing $ac_dest commands" >&6;}
42317   case $ac_dest in
42318     depfiles ) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do
42319   # Strip MF so we end up with the name of the file.
42320   mf=`echo "$mf" | sed -e 's/:.*$//'`
42321   # Check whether this is an Automake generated Makefile or not.
42322   # We used to match only the files named `Makefile.in', but
42323   # some people rename them; so instead we look at the file content.
42324   # Grep'ing the first line is not enough: some people post-process
42325   # each Makefile.in and add a new line on top of each file to say so.
42326   # So let's grep whole file.
42327   if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
42328     dirpart=`(dirname "$mf") 2>/dev/null ||
42329 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42330          X"$mf" : 'X\(//\)[^/]' \| \
42331          X"$mf" : 'X\(//\)$' \| \
42332          X"$mf" : 'X\(/\)' \| \
42333          .     : '\(.\)' 2>/dev/null ||
42334 echo X"$mf" |
42335     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42336           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42337           /^X\(\/\/\)$/{ s//\1/; q; }
42338           /^X\(\/\).*/{ s//\1/; q; }
42339           s/.*/./; q'`
42340   else
42341     continue
42342   fi
42343   # Extract the definition of DEPDIR, am__include, and am__quote
42344   # from the Makefile without running `make'.
42345   DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
42346   test -z "$DEPDIR" && continue
42347   am__include=`sed -n 's/^am__include = //p' < "$mf"`
42348   test -z "am__include" && continue
42349   am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
42350   # When using ansi2knr, U may be empty or an underscore; expand it
42351   U=`sed -n 's/^U = //p' < "$mf"`
42352   # Find all dependency output files, they are included files with
42353   # $(DEPDIR) in their names.  We invoke sed twice because it is the
42354   # simplest approach to changing $(DEPDIR) to its actual value in the
42355   # expansion.
42356   for file in `sed -n "
42357     s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
42358        sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
42359     # Make sure the directory exists.
42360     test -f "$dirpart/$file" && continue
42361     fdir=`(dirname "$file") 2>/dev/null ||
42362 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42363          X"$file" : 'X\(//\)[^/]' \| \
42364          X"$file" : 'X\(//\)$' \| \
42365          X"$file" : 'X\(/\)' \| \
42366          .     : '\(.\)' 2>/dev/null ||
42367 echo X"$file" |
42368     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42369           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42370           /^X\(\/\/\)$/{ s//\1/; q; }
42371           /^X\(\/\).*/{ s//\1/; q; }
42372           s/.*/./; q'`
42373     { if $as_mkdir_p; then
42374     mkdir -p $dirpart/$fdir
42375   else
42376     as_dir=$dirpart/$fdir
42377     as_dirs=
42378     while test ! -d "$as_dir"; do
42379       as_dirs="$as_dir $as_dirs"
42380       as_dir=`(dirname "$as_dir") 2>/dev/null ||
42381 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42382          X"$as_dir" : 'X\(//\)[^/]' \| \
42383          X"$as_dir" : 'X\(//\)$' \| \
42384          X"$as_dir" : 'X\(/\)' \| \
42385          .     : '\(.\)' 2>/dev/null ||
42386 echo X"$as_dir" |
42387     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
42388           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
42389           /^X\(\/\/\)$/{ s//\1/; q; }
42390           /^X\(\/\).*/{ s//\1/; q; }
42391           s/.*/./; q'`
42392     done
42393     test ! -n "$as_dirs" || mkdir $as_dirs
42394   fi || { { echo "$as_me:$LINENO: error: cannot create directory $dirpart/$fdir" >&5
42395 echo "$as_me: error: cannot create directory $dirpart/$fdir" >&2;}
42396    { (exit 1); exit 1; }; }; }
42397
42398     # echo "creating $dirpart/$file"
42399     echo '# dummy' > "$dirpart/$file"
42400   done
42401 done
42402  ;;
42403     default )
42404 chmod +x tests/run
42405 date > stamp-h
42406 BACKENDSC="servers/slapd/backends.c"
42407 echo "Making $BACKENDSC"
42408 rm -f $BACKENDSC
42409 cat > $BACKENDSC << ENDX
42410 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
42411  *
42412  * Copyright 1998-2008 The OpenLDAP Foundation.
42413  * All rights reserved.
42414  *
42415  * Redistribution and use in source and binary forms, with or without
42416  * modification, are permitted only as authorized by the OpenLDAP
42417  * Public License.
42418  *
42419  * A copy of this license is available in the file LICENSE in the
42420  * top-level directory of the distribution or, alternatively, at
42421  * <http://www.OpenLDAP.org/license.html>.
42422  */
42423 /* This file is automatically generated by configure; please do not edit. */
42424
42425 #include "portable.h"
42426 #include "slap.h"
42427
42428 ENDX
42429 if test "${STATIC_BACKENDS}"; then
42430         for b in config ${STATIC_BACKENDS}; do
42431                 bb=`echo "${b}" | sed -e 's/back-//'`
42432                 cat >> $BACKENDSC << ENDX
42433 extern BI_init ${bb}_back_initialize;
42434 ENDX
42435         done
42436
42437         cat >> $BACKENDSC << ENDX
42438
42439 BackendInfo slap_binfo[] = {
42440 ENDX
42441
42442         for b in config ${STATIC_BACKENDS}; do
42443                 bb=`echo "${b}" | sed -e 's/back-//'`
42444                 echo "    Add ${bb} ..."
42445                 cat >> $BACKENDSC << ENDX
42446         { "${bb}", ${bb}_back_initialize },
42447 ENDX
42448         done
42449
42450         cat >> $BACKENDSC << ENDX
42451         { NULL, NULL },
42452 };
42453
42454 /* end of generated file */
42455 ENDX
42456 fi
42457 OVERLAYSC="servers/slapd/overlays/statover.c"
42458 echo "Making $OVERLAYSC"
42459 rm -f $OVERLAYSC
42460 cat > $OVERLAYSC << ENDX
42461 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
42462  *
42463  * Copyright 1998-2008 The OpenLDAP Foundation.
42464  * All rights reserved.
42465  *
42466  * Redistribution and use in source and binary forms, with or without
42467  * modification, are permitted only as authorized by the OpenLDAP
42468  * Public License.
42469  *
42470  * A copy of this license is available in the file LICENSE in the
42471  * top-level directory of the distribution or, alternatively, at
42472  * <http://www.OpenLDAP.org/license.html>.
42473  */
42474 /* This file is automatically generated by configure; please do not edit. */
42475
42476 #include "portable.h"
42477 #include "slap.h"
42478
42479 ENDX
42480 if test "${STATIC_OVERLAYS}"; then
42481         for o in ${STATIC_OVERLAYS}; do
42482                 oo=`echo "${o}" | sed -e 's/.o$//' -e 's/_x$//'`
42483                 cat >> $OVERLAYSC << ENDX
42484 extern OV_init ${oo}_initialize;
42485 ENDX
42486         done
42487 fi
42488
42489 cat >> $OVERLAYSC << ENDX
42490
42491 OverlayInit slap_oinfo[] = {
42492 ENDX
42493
42494 if test "${STATIC_OVERLAYS}"; then
42495         for o in ${STATIC_OVERLAYS}; do
42496                 oo=`echo "${o}" | sed -e 's/.o$//' -e 's/_x$//'`
42497                 echo "    Add ${oo} ..."
42498                 cat >> $OVERLAYSC << ENDX
42499         { "${oo}", ${oo}_initialize },
42500 ENDX
42501         done
42502 fi
42503
42504         cat >> $OVERLAYSC << ENDX
42505         { NULL, NULL },
42506 };
42507
42508 /* end of generated file */
42509 ENDX
42510
42511 if test "${ol_cv_mkdep}" = no; then
42512         echo '(Do not "make depend"; we do not know how to build dependencies)'
42513 else
42514         echo 'Please run "make depend" to build dependencies'
42515 fi
42516  ;;
42517   esac
42518 done
42519 _ACEOF
42520
42521 cat >>$CONFIG_STATUS <<\_ACEOF
42522
42523 { (exit 0); exit 0; }
42524 _ACEOF
42525 chmod +x $CONFIG_STATUS
42526 ac_clean_files=$ac_clean_files_save
42527
42528
42529 # configure is writing to config.log, and then calls config.status.
42530 # config.status does its own redirection, appending to config.log.
42531 # Unfortunately, on DOS this fails, as config.log is still kept open
42532 # by configure, so config.status won't be able to write to it; its
42533 # output is simply discarded.  So we exec the FD to /dev/null,
42534 # effectively closing config.log, so it can be properly (re)opened and
42535 # appended to by config.status.  When coming back to configure, we
42536 # need to make the FD available again.
42537 if test "$no_create" != yes; then
42538   ac_cs_success=:
42539   ac_config_status_args=
42540   test "$silent" = yes &&
42541     ac_config_status_args="$ac_config_status_args --quiet"
42542   exec 5>/dev/null
42543   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
42544   exec 5>>config.log
42545   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
42546   # would make configure fail if this is the last instruction.
42547   $ac_cs_success || { (exit 1); exit 1; }
42548 fi
42549