]> git.sur5r.net Git - openldap/blob - configure
regenerate to disable back-bdb by default
[openldap] / configure
1 #! /bin/sh
2 # From configure.in OpenLDAP: pkg/ldap/configure.in,v 1.667 2008/09/05 18:59:50 quanah 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 MYSQL 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_NDB 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 SLAPD_NDB_LIBS SLAPD_NDB_INCS 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 [no]
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-ndb          enable MySQL NDB Cluster backend no|yes|mod [no]
1040     --enable-null         enable null backend no|yes|mod [no]
1041     --enable-passwd       enable passwd backend no|yes|mod [no]
1042     --enable-perl         enable perl backend no|yes|mod [no]
1043     --enable-relay        enable relay backend no|yes|mod [yes]
1044     --enable-shell        enable shell backend no|yes|mod [no]
1045     --enable-sock         enable sock backend no|yes|mod [no]
1046     --enable-sql          enable sql backend no|yes|mod [no]
1047
1048 SLAPD Overlay Options:
1049     --enable-overlays     enable all available overlays no|yes|mod
1050     --enable-accesslog    In-Directory Access Logging overlay no|yes|mod [no]
1051     --enable-auditlog     Audit Logging overlay no|yes|mod [no]
1052     --enable-constraint   Attribute Constraint overlay no|yes|mod [no]
1053     --enable-dds          Dynamic Directory Services overlay no|yes|mod [no]
1054     --enable-dyngroup     Dynamic Group overlay no|yes|mod [no]
1055     --enable-dynlist      Dynamic List overlay no|yes|mod [no]
1056     --enable-memberof     Reverse Group Membership overlay no|yes|mod [no]
1057     --enable-ppolicy      Password Policy overlay no|yes|mod [no]
1058     --enable-proxycache   Proxy Cache overlay no|yes|mod [no]
1059     --enable-refint       Referential Integrity overlay no|yes|mod [no]
1060     --enable-retcode      Return Code testing overlay no|yes|mod [no]
1061     --enable-rwm          Rewrite/Remap overlay no|yes|mod [no]
1062     --enable-seqmod       Sequential Modify overlay no|yes|mod [yes]
1063     --enable-syncprov     Syncrepl Provider overlay no|yes|mod [yes]
1064     --enable-translucent  Translucent Proxy overlay no|yes|mod [no]
1065     --enable-unique       Attribute Uniqueness overlay no|yes|mod [no]
1066     --enable-valsort      Value Sorting overlay no|yes|mod [no]
1067
1068 Library Generation & Linking Options
1069   --enable-static[=PKGS]
1070                           build static libraries [default=yes]
1071   --enable-shared[=PKGS]
1072                           build shared libraries [default=yes]
1073   --enable-fast-install[=PKGS]
1074                           optimize for fast installation [default=yes]
1075   --disable-dependency-tracking  speeds up one-time build
1076   --enable-dependency-tracking   do not reject slow dependency extractors
1077   --disable-libtool-lock  avoid locking (might break parallel builds)
1078
1079 Optional Packages:
1080   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1081   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1082   --with-subdir=DIR       change default subdirectory used for installs
1083   --with-cyrus-sasl       with Cyrus SASL support [auto]
1084   --with-fetch            with fetch(3) URL support [auto]
1085   --with-threads          with threads [auto]
1086   --with-tls              with TLS/SSL support auto|openssl|gnutls [auto]
1087   --with-yielding-select  with implicitly yielding select [auto]
1088   --with-mp               with multiple precision statistics auto|longlong|long|bignum|gmp [auto]
1089   --with-odbc             with specific ODBC support iodbc|unixodbc|odbc32|auto [auto]
1090   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1091   --with-pic              try to use only PIC/non-PIC objects [default=use
1092                           both]
1093   --with-tags[=TAGS]
1094                           include additional configurations [automatic]
1095
1096 See INSTALL file for further details.
1097
1098 Some influential environment variables:
1099   CC          C compiler command
1100   CFLAGS      C compiler flags
1101   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1102               nonstandard directory <lib dir>
1103   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
1104               headers in a nonstandard directory <include dir>
1105   CPP         C preprocessor
1106
1107 Use these variables to override the choices made by `configure' or to help
1108 it to find libraries and programs with nonstandard names/locations.
1109
1110 _ACEOF
1111 fi
1112
1113 if test "$ac_init_help" = "recursive"; then
1114   # If there are subdirs, report their specific --help.
1115   ac_popdir=`pwd`
1116   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1117     test -d $ac_dir || continue
1118     ac_builddir=.
1119
1120 if test "$ac_dir" != .; then
1121   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
1122   # A "../" for each directory in $ac_dir_suffix.
1123   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
1124 else
1125   ac_dir_suffix= ac_top_builddir=
1126 fi
1127
1128 case $srcdir in
1129   .)  # No --srcdir option.  We are building in place.
1130     ac_srcdir=.
1131     if test -z "$ac_top_builddir"; then
1132        ac_top_srcdir=.
1133     else
1134        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
1135     fi ;;
1136   [\\/]* | ?:[\\/]* )  # Absolute path.
1137     ac_srcdir=$srcdir$ac_dir_suffix;
1138     ac_top_srcdir=$srcdir ;;
1139   *) # Relative path.
1140     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
1141     ac_top_srcdir=$ac_top_builddir$srcdir ;;
1142 esac
1143
1144 # Do not use `cd foo && pwd` to compute absolute paths, because
1145 # the directories may not exist.
1146 case `pwd` in
1147 .) ac_abs_builddir="$ac_dir";;
1148 *)
1149   case "$ac_dir" in
1150   .) ac_abs_builddir=`pwd`;;
1151   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
1152   *) ac_abs_builddir=`pwd`/"$ac_dir";;
1153   esac;;
1154 esac
1155 case $ac_abs_builddir in
1156 .) ac_abs_top_builddir=${ac_top_builddir}.;;
1157 *)
1158   case ${ac_top_builddir}. in
1159   .) ac_abs_top_builddir=$ac_abs_builddir;;
1160   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
1161   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
1162   esac;;
1163 esac
1164 case $ac_abs_builddir in
1165 .) ac_abs_srcdir=$ac_srcdir;;
1166 *)
1167   case $ac_srcdir in
1168   .) ac_abs_srcdir=$ac_abs_builddir;;
1169   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
1170   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
1171   esac;;
1172 esac
1173 case $ac_abs_builddir in
1174 .) ac_abs_top_srcdir=$ac_top_srcdir;;
1175 *)
1176   case $ac_top_srcdir in
1177   .) ac_abs_top_srcdir=$ac_abs_builddir;;
1178   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
1179   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
1180   esac;;
1181 esac
1182
1183     cd $ac_dir
1184     # Check for guested configure; otherwise get Cygnus style configure.
1185     if test -f $ac_srcdir/configure.gnu; then
1186       echo
1187       $SHELL $ac_srcdir/configure.gnu  --help=recursive
1188     elif test -f $ac_srcdir/configure; then
1189       echo
1190       $SHELL $ac_srcdir/configure  --help=recursive
1191     elif test -f $ac_srcdir/configure.ac ||
1192            test -f $ac_srcdir/configure.in; then
1193       echo
1194       $ac_configure --help
1195     else
1196       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1197     fi
1198     cd $ac_popdir
1199   done
1200 fi
1201
1202 test -n "$ac_init_help" && exit 0
1203 if $ac_init_version; then
1204   cat <<\_ACEOF
1205
1206 Copyright (C) 2003 Free Software Foundation, Inc.
1207 This configure script is free software; the Free Software Foundation
1208 gives unlimited permission to copy, distribute and modify it.
1209
1210 Copyright 1998-2008 The OpenLDAP Foundation. All rights reserved.
1211 Restrictions apply, see COPYRIGHT and LICENSE files.
1212 _ACEOF
1213   exit 0
1214 fi
1215 exec 5>config.log
1216 cat >&5 <<_ACEOF
1217 This file contains any messages produced by compilers while
1218 running configure, to aid debugging if configure makes a mistake.
1219
1220 It was created by $as_me, which was
1221 generated by GNU Autoconf 2.59.  Invocation command line was
1222
1223   $ $0 $@
1224
1225 _ACEOF
1226 {
1227 cat <<_ASUNAME
1228 ## --------- ##
1229 ## Platform. ##
1230 ## --------- ##
1231
1232 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1233 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1234 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1235 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1236 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1237
1238 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1239 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1240
1241 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1242 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1243 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1244 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
1245 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1246 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1247 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1248
1249 _ASUNAME
1250
1251 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1252 for as_dir in $PATH
1253 do
1254   IFS=$as_save_IFS
1255   test -z "$as_dir" && as_dir=.
1256   echo "PATH: $as_dir"
1257 done
1258
1259 } >&5
1260
1261 cat >&5 <<_ACEOF
1262
1263
1264 ## ----------- ##
1265 ## Core tests. ##
1266 ## ----------- ##
1267
1268 _ACEOF
1269
1270
1271 # Keep a trace of the command line.
1272 # Strip out --no-create and --no-recursion so they do not pile up.
1273 # Strip out --silent because we don't want to record it for future runs.
1274 # Also quote any args containing shell meta-characters.
1275 # Make two passes to allow for proper duplicate-argument suppression.
1276 ac_configure_args=
1277 ac_configure_args0=
1278 ac_configure_args1=
1279 ac_sep=
1280 ac_must_keep_next=false
1281 for ac_pass in 1 2
1282 do
1283   for ac_arg
1284   do
1285     case $ac_arg in
1286     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1287     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1288     | -silent | --silent | --silen | --sile | --sil)
1289       continue ;;
1290     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1291       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1292     esac
1293     case $ac_pass in
1294     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1295     2)
1296       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1297       if test $ac_must_keep_next = true; then
1298         ac_must_keep_next=false # Got value, back to normal.
1299       else
1300         case $ac_arg in
1301           *=* | --config-cache | -C | -disable-* | --disable-* \
1302           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1303           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1304           | -with-* | --with-* | -without-* | --without-* | --x)
1305             case "$ac_configure_args0 " in
1306               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1307             esac
1308             ;;
1309           -* ) ac_must_keep_next=true ;;
1310         esac
1311       fi
1312       ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1313       # Get rid of the leading space.
1314       ac_sep=" "
1315       ;;
1316     esac
1317   done
1318 done
1319 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1320 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1321
1322 # When interrupted or exit'd, cleanup temporary files, and complete
1323 # config.log.  We remove comments because anyway the quotes in there
1324 # would cause problems or look ugly.
1325 # WARNING: Be sure not to use single quotes in there, as some shells,
1326 # such as our DU 5.0 friend, will then `close' the trap.
1327 trap 'exit_status=$?
1328   # Save into config.log some information that might help in debugging.
1329   {
1330     echo
1331
1332     cat <<\_ASBOX
1333 ## ---------------- ##
1334 ## Cache variables. ##
1335 ## ---------------- ##
1336 _ASBOX
1337     echo
1338     # The following way of writing the cache mishandles newlines in values,
1339 {
1340   (set) 2>&1 |
1341     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1342     *ac_space=\ *)
1343       sed -n \
1344         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1345           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1346       ;;
1347     *)
1348       sed -n \
1349         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1350       ;;
1351     esac;
1352 }
1353     echo
1354
1355     cat <<\_ASBOX
1356 ## ----------------- ##
1357 ## Output variables. ##
1358 ## ----------------- ##
1359 _ASBOX
1360     echo
1361     for ac_var in $ac_subst_vars
1362     do
1363       eval ac_val=$`echo $ac_var`
1364       echo "$ac_var='"'"'$ac_val'"'"'"
1365     done | sort
1366     echo
1367
1368     if test -n "$ac_subst_files"; then
1369       cat <<\_ASBOX
1370 ## ------------- ##
1371 ## Output files. ##
1372 ## ------------- ##
1373 _ASBOX
1374       echo
1375       for ac_var in $ac_subst_files
1376       do
1377         eval ac_val=$`echo $ac_var`
1378         echo "$ac_var='"'"'$ac_val'"'"'"
1379       done | sort
1380       echo
1381     fi
1382
1383     if test -s confdefs.h; then
1384       cat <<\_ASBOX
1385 ## ----------- ##
1386 ## confdefs.h. ##
1387 ## ----------- ##
1388 _ASBOX
1389       echo
1390       sed "/^$/d" confdefs.h | sort
1391       echo
1392     fi
1393     test "$ac_signal" != 0 &&
1394       echo "$as_me: caught signal $ac_signal"
1395     echo "$as_me: exit $exit_status"
1396   } >&5
1397   rm -f core *.core &&
1398   rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1399     exit $exit_status
1400      ' 0
1401 for ac_signal in 1 2 13 15; do
1402   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1403 done
1404 ac_signal=0
1405
1406 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1407 rm -rf conftest* confdefs.h
1408 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1409 echo >confdefs.h
1410
1411 # Predefined preprocessor variables.
1412
1413 cat >>confdefs.h <<_ACEOF
1414 #define PACKAGE_NAME "$PACKAGE_NAME"
1415 _ACEOF
1416
1417
1418 cat >>confdefs.h <<_ACEOF
1419 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1420 _ACEOF
1421
1422
1423 cat >>confdefs.h <<_ACEOF
1424 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1425 _ACEOF
1426
1427
1428 cat >>confdefs.h <<_ACEOF
1429 #define PACKAGE_STRING "$PACKAGE_STRING"
1430 _ACEOF
1431
1432
1433 cat >>confdefs.h <<_ACEOF
1434 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1435 _ACEOF
1436
1437
1438 # Let the site file select an alternate cache file if it wants to.
1439 # Prefer explicitly selected file to automatically selected ones.
1440 if test -z "$CONFIG_SITE"; then
1441   if test "x$prefix" != xNONE; then
1442     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1443   else
1444     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1445   fi
1446 fi
1447 for ac_site_file in $CONFIG_SITE; do
1448   if test -r "$ac_site_file"; then
1449     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1450 echo "$as_me: loading site script $ac_site_file" >&6;}
1451     sed 's/^/| /' "$ac_site_file" >&5
1452     . "$ac_site_file"
1453   fi
1454 done
1455
1456
1457 # Check that the precious variables saved in the cache have kept the same
1458 # value.
1459 ac_cache_corrupted=false
1460 for ac_var in `(set) 2>&1 |
1461                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1462   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1463   eval ac_new_set=\$ac_env_${ac_var}_set
1464   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1465   eval ac_new_val="\$ac_env_${ac_var}_value"
1466   case $ac_old_set,$ac_new_set in
1467     set,)
1468       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1469 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1470       ac_cache_corrupted=: ;;
1471     ,set)
1472       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1473 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1474       ac_cache_corrupted=: ;;
1475     ,);;
1476     *)
1477       if test "x$ac_old_val" != "x$ac_new_val"; then
1478         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1479 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1480         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1481 echo "$as_me:   former value:  $ac_old_val" >&2;}
1482         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1483 echo "$as_me:   current value: $ac_new_val" >&2;}
1484         ac_cache_corrupted=:
1485       fi;;
1486   esac
1487   # Pass precious variables to config.status.
1488   if test "$ac_new_set" = set; then
1489     case $ac_new_val in
1490     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1491       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1492     *) ac_arg=$ac_var=$ac_new_val ;;
1493     esac
1494     case " $ac_configure_args " in
1495       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1496       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1497     esac
1498   fi
1499 done
1500 if $ac_cache_corrupted; then
1501   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1502 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1503   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1504 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1505    { (exit 1); exit 1; }; }
1506 fi
1507
1508 ac_ext=c
1509 ac_cpp='$CPP $CPPFLAGS'
1510 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1511 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1512 ac_compiler_gnu=$ac_cv_c_compiler_gnu
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
1556 ac_aux_dir=
1557 for ac_dir in build $srcdir/build; do
1558   if test -f $ac_dir/install-sh; then
1559     ac_aux_dir=$ac_dir
1560     ac_install_sh="$ac_aux_dir/install-sh -c"
1561     break
1562   elif test -f $ac_dir/install.sh; then
1563     ac_aux_dir=$ac_dir
1564     ac_install_sh="$ac_aux_dir/install.sh -c"
1565     break
1566   elif test -f $ac_dir/shtool; then
1567     ac_aux_dir=$ac_dir
1568     ac_install_sh="$ac_aux_dir/shtool install -c"
1569     break
1570   fi
1571 done
1572 if test -z "$ac_aux_dir"; then
1573   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in build $srcdir/build" >&5
1574 echo "$as_me: error: cannot find install-sh or install.sh in build $srcdir/build" >&2;}
1575    { (exit 1); exit 1; }; }
1576 fi
1577 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1578 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1579 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1580
1581 eval `$ac_aux_dir/version.sh`
1582 if test -z "$OL_STRING"; then
1583         { { echo "$as_me:$LINENO: error: could not determine version" >&5
1584 echo "$as_me: error: could not determine version" >&2;}
1585    { (exit 1); exit 1; }; }
1586 fi
1587
1588 if test -f "$ac_aux_dir/shtool" && test ! -d $ac_aux_dir/shtool; then
1589         ac_cv_shtool="$ac_aux_dir/shtool"
1590 else
1591         { { echo "$as_me:$LINENO: error: no shtool found in $ac_aux_dir" >&5
1592 echo "$as_me: error: no shtool found in $ac_aux_dir" >&2;}
1593    { (exit 1); exit 1; }; }
1594 fi
1595
1596 SHTOOL="$ac_cv_shtool"
1597
1598 TB="" TN=""
1599 if test -t 1; then
1600         TB="`$SHTOOL echo -e '%B' 2>/dev/null`"
1601         TN="`$SHTOOL echo -e '%b' 2>/dev/null`"
1602 fi
1603
1604 OPENLDAP_CVS=""
1605 if test -d $ac_aux_dir/CVS; then
1606         OPENLDAP_CVS="(from CVS sources) "
1607 fi
1608
1609 echo "Configuring ${TB}${OL_STRING}${TN} ${OPENLDAP_CVS}..."
1610
1611 # Make sure we can run config.sub.
1612 $ac_config_sub sun4 >/dev/null 2>&1 ||
1613   { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
1614 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1615    { (exit 1); exit 1; }; }
1616
1617 echo "$as_me:$LINENO: checking build system type" >&5
1618 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1619 if test "${ac_cv_build+set}" = set; then
1620   echo $ECHO_N "(cached) $ECHO_C" >&6
1621 else
1622   ac_cv_build_alias=$build_alias
1623 test -z "$ac_cv_build_alias" &&
1624   ac_cv_build_alias=`$ac_config_guess`
1625 test -z "$ac_cv_build_alias" &&
1626   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1627 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1628    { (exit 1); exit 1; }; }
1629 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1630   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1631 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
1632    { (exit 1); exit 1; }; }
1633
1634 fi
1635 echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1636 echo "${ECHO_T}$ac_cv_build" >&6
1637 build=$ac_cv_build
1638 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1639 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1640 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1641
1642
1643 echo "$as_me:$LINENO: checking host system type" >&5
1644 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1645 if test "${ac_cv_host+set}" = set; then
1646   echo $ECHO_N "(cached) $ECHO_C" >&6
1647 else
1648   ac_cv_host_alias=$host_alias
1649 test -z "$ac_cv_host_alias" &&
1650   ac_cv_host_alias=$ac_cv_build_alias
1651 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1652   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1653 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1654    { (exit 1); exit 1; }; }
1655
1656 fi
1657 echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1658 echo "${ECHO_T}$ac_cv_host" >&6
1659 host=$ac_cv_host
1660 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1661 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1662 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1663
1664
1665 echo "$as_me:$LINENO: checking target system type" >&5
1666 echo $ECHO_N "checking target system type... $ECHO_C" >&6
1667 if test "${ac_cv_target+set}" = set; then
1668   echo $ECHO_N "(cached) $ECHO_C" >&6
1669 else
1670   ac_cv_target_alias=$target_alias
1671 test "x$ac_cv_target_alias" = "x" &&
1672   ac_cv_target_alias=$ac_cv_host_alias
1673 ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
1674   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1675 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
1676    { (exit 1); exit 1; }; }
1677
1678 fi
1679 echo "$as_me:$LINENO: result: $ac_cv_target" >&5
1680 echo "${ECHO_T}$ac_cv_target" >&6
1681 target=$ac_cv_target
1682 target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1683 target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1684 target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1685
1686
1687 # The aliases save the names the user supplied, while $host etc.
1688 # will get canonicalized.
1689 test -n "$target_alias" &&
1690   test "$program_prefix$program_suffix$program_transform_name" = \
1691     NONENONEs,x,x, &&
1692   program_prefix=${target_alias}-
1693
1694 am__api_version="1.9"
1695 # Find a good install program.  We prefer a C program (faster),
1696 # so one script is as good as another.  But avoid the broken or
1697 # incompatible versions:
1698 # SysV /etc/install, /usr/sbin/install
1699 # SunOS /usr/etc/install
1700 # IRIX /sbin/install
1701 # AIX /bin/install
1702 # AmigaOS /C/install, which installs bootblocks on floppy discs
1703 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1704 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
1705 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1706 # OS/2's system install, which has a completely different semantic
1707 # ./install, which can be erroneously created by make from ./install.sh.
1708 echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
1709 echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
1710 if test -z "$INSTALL"; then
1711 if test "${ac_cv_path_install+set}" = set; then
1712   echo $ECHO_N "(cached) $ECHO_C" >&6
1713 else
1714   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1715 for as_dir in $PATH
1716 do
1717   IFS=$as_save_IFS
1718   test -z "$as_dir" && as_dir=.
1719   # Account for people who put trailing slashes in PATH elements.
1720 case $as_dir/ in
1721   ./ | .// | /cC/* | \
1722   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
1723   ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
1724   /usr/ucb/* ) ;;
1725   *)
1726     # OSF1 and SCO ODT 3.0 have their own names for install.
1727     # Don't use installbsd from OSF since it installs stuff as root
1728     # by default.
1729     for ac_prog in ginstall scoinst install; do
1730       for ac_exec_ext in '' $ac_executable_extensions; do
1731         if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
1732           if test $ac_prog = install &&
1733             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
1734             # AIX install.  It has an incompatible calling convention.
1735             :
1736           elif test $ac_prog = install &&
1737             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
1738             # program-specific install script used by HP pwplus--don't use.
1739             :
1740           else
1741             ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
1742             break 3
1743           fi
1744         fi
1745       done
1746     done
1747     ;;
1748 esac
1749 done
1750
1751
1752 fi
1753   if test "${ac_cv_path_install+set}" = set; then
1754     INSTALL=$ac_cv_path_install
1755   else
1756     # As a last resort, use the slow shell script.  We don't cache a
1757     # path for INSTALL within a source directory, because that will
1758     # break other packages using the cache if that directory is
1759     # removed, or if the path is relative.
1760     INSTALL=$ac_install_sh
1761   fi
1762 fi
1763 echo "$as_me:$LINENO: result: $INSTALL" >&5
1764 echo "${ECHO_T}$INSTALL" >&6
1765
1766 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1767 # It thinks the first close brace ends the variable substitution.
1768 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1769
1770 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
1771
1772 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1773
1774 echo "$as_me:$LINENO: checking whether build environment is sane" >&5
1775 echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6
1776 # Just in case
1777 sleep 1
1778 echo timestamp > conftest.file
1779 # Do `set' in a subshell so we don't clobber the current shell's
1780 # arguments.  Must try -L first in case configure is actually a
1781 # symlink; some systems play weird games with the mod time of symlinks
1782 # (eg FreeBSD returns the mod time of the symlink's containing
1783 # directory).
1784 if (
1785    set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
1786    if test "$*" = "X"; then
1787       # -L didn't work.
1788       set X `ls -t $srcdir/configure conftest.file`
1789    fi
1790    rm -f conftest.file
1791    if test "$*" != "X $srcdir/configure conftest.file" \
1792       && test "$*" != "X conftest.file $srcdir/configure"; then
1793
1794       # If neither matched, then we have a broken ls.  This can happen
1795       # if, for instance, CONFIG_SHELL is bash and it inherits a
1796       # broken ls alias from the environment.  This has actually
1797       # happened.  Such a system could not be considered "sane".
1798       { { echo "$as_me:$LINENO: error: ls -t appears to fail.  Make sure there is not a broken
1799 alias in your environment" >&5
1800 echo "$as_me: error: ls -t appears to fail.  Make sure there is not a broken
1801 alias in your environment" >&2;}
1802    { (exit 1); exit 1; }; }
1803    fi
1804
1805    test "$2" = conftest.file
1806    )
1807 then
1808    # Ok.
1809    :
1810 else
1811    { { echo "$as_me:$LINENO: error: newly created file is older than distributed files!
1812 Check your system clock" >&5
1813 echo "$as_me: error: newly created file is older than distributed files!
1814 Check your system clock" >&2;}
1815    { (exit 1); exit 1; }; }
1816 fi
1817 echo "$as_me:$LINENO: result: yes" >&5
1818 echo "${ECHO_T}yes" >&6
1819 test "$program_prefix" != NONE &&
1820   program_transform_name="s,^,$program_prefix,;$program_transform_name"
1821 # Use a double $ so make ignores it.
1822 test "$program_suffix" != NONE &&
1823   program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1824 # Double any \ or $.  echo might interpret backslashes.
1825 # By default was `s,x,x', remove it if useless.
1826 cat <<\_ACEOF >conftest.sed
1827 s/[\\$]/&&/g;s/;s,x,x,$//
1828 _ACEOF
1829 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1830 rm conftest.sed
1831
1832 # expand $ac_aux_dir to an absolute path
1833 am_aux_dir=`cd $ac_aux_dir && pwd`
1834
1835 test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
1836 # Use eval to expand $SHELL
1837 if eval "$MISSING --run true"; then
1838   am_missing_run="$MISSING --run "
1839 else
1840   am_missing_run=
1841   { echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5
1842 echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
1843 fi
1844
1845 if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then
1846   # We used to keeping the `.' as first argument, in order to
1847   # allow $(mkdir_p) to be used without argument.  As in
1848   #   $(mkdir_p) $(somedir)
1849   # where $(somedir) is conditionally defined.  However this is wrong
1850   # for two reasons:
1851   #  1. if the package is installed by a user who cannot write `.'
1852   #     make install will fail,
1853   #  2. the above comment should most certainly read
1854   #     $(mkdir_p) $(DESTDIR)$(somedir)
1855   #     so it does not work when $(somedir) is undefined and
1856   #     $(DESTDIR) is not.
1857   #  To support the latter case, we have to write
1858   #     test -z "$(somedir)" || $(mkdir_p) $(DESTDIR)$(somedir),
1859   #  so the `.' trick is pointless.
1860   mkdir_p='mkdir -p --'
1861 else
1862   # On NextStep and OpenStep, the `mkdir' command does not
1863   # recognize any option.  It will interpret all options as
1864   # directories to create, and then abort because `.' already
1865   # exists.
1866   for d in ./-p ./--version;
1867   do
1868     test -d $d && rmdir $d
1869   done
1870   # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists.
1871   if test -f "$ac_aux_dir/mkinstalldirs"; then
1872     mkdir_p='$(mkinstalldirs)'
1873   else
1874     mkdir_p='$(install_sh) -d'
1875   fi
1876 fi
1877
1878 for ac_prog in gawk mawk nawk awk
1879 do
1880   # Extract the first word of "$ac_prog", so it can be a program name with args.
1881 set dummy $ac_prog; ac_word=$2
1882 echo "$as_me:$LINENO: checking for $ac_word" >&5
1883 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1884 if test "${ac_cv_prog_AWK+set}" = set; then
1885   echo $ECHO_N "(cached) $ECHO_C" >&6
1886 else
1887   if test -n "$AWK"; then
1888   ac_cv_prog_AWK="$AWK" # Let the user override the test.
1889 else
1890 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1891 for as_dir in $PATH
1892 do
1893   IFS=$as_save_IFS
1894   test -z "$as_dir" && as_dir=.
1895   for ac_exec_ext in '' $ac_executable_extensions; do
1896   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1897     ac_cv_prog_AWK="$ac_prog"
1898     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1899     break 2
1900   fi
1901 done
1902 done
1903
1904 fi
1905 fi
1906 AWK=$ac_cv_prog_AWK
1907 if test -n "$AWK"; then
1908   echo "$as_me:$LINENO: result: $AWK" >&5
1909 echo "${ECHO_T}$AWK" >&6
1910 else
1911   echo "$as_me:$LINENO: result: no" >&5
1912 echo "${ECHO_T}no" >&6
1913 fi
1914
1915   test -n "$AWK" && break
1916 done
1917
1918 echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
1919 echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
1920 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'`
1921 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1922   echo $ECHO_N "(cached) $ECHO_C" >&6
1923 else
1924   cat >conftest.make <<\_ACEOF
1925 all:
1926         @echo 'ac_maketemp="$(MAKE)"'
1927 _ACEOF
1928 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1929 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1930 if test -n "$ac_maketemp"; then
1931   eval ac_cv_prog_make_${ac_make}_set=yes
1932 else
1933   eval ac_cv_prog_make_${ac_make}_set=no
1934 fi
1935 rm -f conftest.make
1936 fi
1937 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1938   echo "$as_me:$LINENO: result: yes" >&5
1939 echo "${ECHO_T}yes" >&6
1940   SET_MAKE=
1941 else
1942   echo "$as_me:$LINENO: result: no" >&5
1943 echo "${ECHO_T}no" >&6
1944   SET_MAKE="MAKE=${MAKE-make}"
1945 fi
1946
1947 rm -rf .tst 2>/dev/null
1948 mkdir .tst 2>/dev/null
1949 if test -d .tst; then
1950   am__leading_dot=.
1951 else
1952   am__leading_dot=_
1953 fi
1954 rmdir .tst 2>/dev/null
1955
1956 # test to see if srcdir already configured
1957 if test "`cd $srcdir && pwd`" != "`pwd`" &&
1958    test -f $srcdir/config.status; then
1959   { { echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5
1960 echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;}
1961    { (exit 1); exit 1; }; }
1962 fi
1963
1964 # test whether we have cygpath
1965 if test -z "$CYGPATH_W"; then
1966   if (cygpath --version) >/dev/null 2>/dev/null; then
1967     CYGPATH_W='cygpath -w'
1968   else
1969     CYGPATH_W=echo
1970   fi
1971 fi
1972
1973
1974 # Define the identity of the package.
1975  PACKAGE=$OL_PACKAGE
1976  VERSION=$OL_VERSION
1977
1978
1979 # Some tools Automake needs.
1980
1981 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
1982
1983
1984 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
1985
1986
1987 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
1988
1989
1990 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
1991
1992
1993 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
1994
1995 install_sh=${install_sh-"$am_aux_dir/install-sh"}
1996
1997 # Installed binaries are usually stripped using `strip' when the user
1998 # run `make install-strip'.  However `strip' might not be the right
1999 # tool to use in cross-compilation environments, therefore Automake
2000 # will honor the `STRIP' environment variable to overrule this program.
2001 if test "$cross_compiling" != no; then
2002   if test -n "$ac_tool_prefix"; then
2003   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
2004 set dummy ${ac_tool_prefix}strip; ac_word=$2
2005 echo "$as_me:$LINENO: checking for $ac_word" >&5
2006 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2007 if test "${ac_cv_prog_STRIP+set}" = set; then
2008   echo $ECHO_N "(cached) $ECHO_C" >&6
2009 else
2010   if test -n "$STRIP"; then
2011   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
2012 else
2013 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2014 for as_dir in $PATH
2015 do
2016   IFS=$as_save_IFS
2017   test -z "$as_dir" && as_dir=.
2018   for ac_exec_ext in '' $ac_executable_extensions; do
2019   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2020     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
2021     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2022     break 2
2023   fi
2024 done
2025 done
2026
2027 fi
2028 fi
2029 STRIP=$ac_cv_prog_STRIP
2030 if test -n "$STRIP"; then
2031   echo "$as_me:$LINENO: result: $STRIP" >&5
2032 echo "${ECHO_T}$STRIP" >&6
2033 else
2034   echo "$as_me:$LINENO: result: no" >&5
2035 echo "${ECHO_T}no" >&6
2036 fi
2037
2038 fi
2039 if test -z "$ac_cv_prog_STRIP"; then
2040   ac_ct_STRIP=$STRIP
2041   # Extract the first word of "strip", so it can be a program name with args.
2042 set dummy strip; ac_word=$2
2043 echo "$as_me:$LINENO: checking for $ac_word" >&5
2044 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2045 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
2046   echo $ECHO_N "(cached) $ECHO_C" >&6
2047 else
2048   if test -n "$ac_ct_STRIP"; then
2049   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
2050 else
2051 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2052 for as_dir in $PATH
2053 do
2054   IFS=$as_save_IFS
2055   test -z "$as_dir" && as_dir=.
2056   for ac_exec_ext in '' $ac_executable_extensions; do
2057   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2058     ac_cv_prog_ac_ct_STRIP="strip"
2059     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2060     break 2
2061   fi
2062 done
2063 done
2064
2065   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
2066 fi
2067 fi
2068 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
2069 if test -n "$ac_ct_STRIP"; then
2070   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
2071 echo "${ECHO_T}$ac_ct_STRIP" >&6
2072 else
2073   echo "$as_me:$LINENO: result: no" >&5
2074 echo "${ECHO_T}no" >&6
2075 fi
2076
2077   STRIP=$ac_ct_STRIP
2078 else
2079   STRIP="$ac_cv_prog_STRIP"
2080 fi
2081
2082 fi
2083 INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
2084
2085 # We need awk for the "check" target.  The system "awk" is bad on
2086 # some platforms.
2087 # Always define AMTAR for backward compatibility.
2088
2089 AMTAR=${AMTAR-"${am_missing_run}tar"}
2090
2091 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
2092
2093
2094
2095
2096
2097 cat >>confdefs.h <<_ACEOF
2098 #define OPENLDAP_PACKAGE "$PACKAGE"
2099 _ACEOF
2100
2101
2102 cat >>confdefs.h <<_ACEOF
2103 #define OPENLDAP_VERSION "$VERSION"
2104 _ACEOF
2105
2106
2107
2108 cat >>confdefs.h <<_ACEOF
2109 #define LDAP_VENDOR_VERSION $OL_API_INC
2110 _ACEOF
2111
2112
2113 cat >>confdefs.h <<_ACEOF
2114 #define LDAP_VENDOR_VERSION_MAJOR $OL_MAJOR
2115 _ACEOF
2116
2117
2118 cat >>confdefs.h <<_ACEOF
2119 #define LDAP_VENDOR_VERSION_MINOR $OL_MINOR
2120 _ACEOF
2121
2122
2123 cat >>confdefs.h <<_ACEOF
2124 #define LDAP_VENDOR_VERSION_PATCH $OL_PATCH
2125 _ACEOF
2126
2127
2128 OPENLDAP_LIBRELEASE=$OL_API_LIB_RELEASE
2129
2130 OPENLDAP_LIBVERSION=$OL_API_LIB_VERSION
2131
2132 OPENLDAP_RELEASE_DATE="$OL_RELEASE_DATE"
2133
2134
2135
2136
2137
2138
2139
2140           ac_config_headers="$ac_config_headers include/portable.h:include/portable.hin"
2141
2142           ac_config_headers="$ac_config_headers include/ldap_features.h:include/ldap_features.hin"
2143
2144           ac_config_headers="$ac_config_headers include/lber_types.h:include/lber_types.hin"
2145
2146
2147 echo "$as_me:$LINENO: checking configure arguments" >&5
2148 echo $ECHO_N "checking configure arguments... $ECHO_C" >&6
2149
2150
2151 top_builddir=`pwd`
2152
2153 ldap_subdir="/openldap"
2154
2155
2156 # Check whether --with-subdir or --without-subdir was given.
2157 if test "${with_subdir+set}" = set; then
2158   withval="$with_subdir"
2159   case "$withval" in
2160         no) ldap_subdir=""
2161                 ;;
2162         yes)
2163                 ;;
2164         /*|\\*)
2165                 ldap_subdir="$withval"
2166                 ;;
2167         *)
2168                 ldap_subdir="/$withval"
2169                 ;;
2170 esac
2171
2172 fi;
2173
2174 # OpenLDAP --enable-debug
2175
2176         # Check whether --enable-debug or --disable-debug was given.
2177 if test "${enable_debug+set}" = set; then
2178   enableval="$enable_debug"
2179
2180         ol_arg=invalid
2181         for ol_val in no yes traditional ; do
2182                 if test "$enableval" = "$ol_val" ; then
2183                         ol_arg="$ol_val"
2184                 fi
2185         done
2186         if test "$ol_arg" = "invalid" ; then
2187                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-debug" >&5
2188 echo "$as_me: error: bad value $enableval for --enable-debug" >&2;}
2189    { (exit 1); exit 1; }; }
2190         fi
2191         ol_enable_debug="$ol_arg"
2192
2193 else
2194         ol_enable_debug=yes
2195 fi;
2196 # end --enable-debug
2197 # OpenLDAP --enable-dynamic
2198
2199         # Check whether --enable-dynamic or --disable-dynamic was given.
2200 if test "${enable_dynamic+set}" = set; then
2201   enableval="$enable_dynamic"
2202
2203         ol_arg=invalid
2204         for ol_val in auto yes no ; do
2205                 if test "$enableval" = "$ol_val" ; then
2206                         ol_arg="$ol_val"
2207                 fi
2208         done
2209         if test "$ol_arg" = "invalid" ; then
2210                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dynamic" >&5
2211 echo "$as_me: error: bad value $enableval for --enable-dynamic" >&2;}
2212    { (exit 1); exit 1; }; }
2213         fi
2214         ol_enable_dynamic="$ol_arg"
2215
2216 else
2217         ol_enable_dynamic=no
2218 fi;
2219 # end --enable-dynamic
2220 # OpenLDAP --enable-syslog
2221
2222         # Check whether --enable-syslog or --disable-syslog was given.
2223 if test "${enable_syslog+set}" = set; then
2224   enableval="$enable_syslog"
2225
2226         ol_arg=invalid
2227         for ol_val in auto yes no ; do
2228                 if test "$enableval" = "$ol_val" ; then
2229                         ol_arg="$ol_val"
2230                 fi
2231         done
2232         if test "$ol_arg" = "invalid" ; then
2233                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-syslog" >&5
2234 echo "$as_me: error: bad value $enableval for --enable-syslog" >&2;}
2235    { (exit 1); exit 1; }; }
2236         fi
2237         ol_enable_syslog="$ol_arg"
2238
2239 else
2240         ol_enable_syslog=auto
2241 fi;
2242 # end --enable-syslog
2243 # OpenLDAP --enable-proctitle
2244
2245         # Check whether --enable-proctitle or --disable-proctitle was given.
2246 if test "${enable_proctitle+set}" = set; then
2247   enableval="$enable_proctitle"
2248
2249         ol_arg=invalid
2250         for ol_val in auto yes no ; do
2251                 if test "$enableval" = "$ol_val" ; then
2252                         ol_arg="$ol_val"
2253                 fi
2254         done
2255         if test "$ol_arg" = "invalid" ; then
2256                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-proctitle" >&5
2257 echo "$as_me: error: bad value $enableval for --enable-proctitle" >&2;}
2258    { (exit 1); exit 1; }; }
2259         fi
2260         ol_enable_proctitle="$ol_arg"
2261
2262 else
2263         ol_enable_proctitle=yes
2264 fi;
2265 # end --enable-proctitle
2266 ol_enable_referrals=${ol_enable_referrals-no}
2267 # OpenLDAP --enable-ipv6
2268
2269         # Check whether --enable-ipv6 or --disable-ipv6 was given.
2270 if test "${enable_ipv6+set}" = set; then
2271   enableval="$enable_ipv6"
2272
2273         ol_arg=invalid
2274         for ol_val in auto yes no ; do
2275                 if test "$enableval" = "$ol_val" ; then
2276                         ol_arg="$ol_val"
2277                 fi
2278         done
2279         if test "$ol_arg" = "invalid" ; then
2280                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ipv6" >&5
2281 echo "$as_me: error: bad value $enableval for --enable-ipv6" >&2;}
2282    { (exit 1); exit 1; }; }
2283         fi
2284         ol_enable_ipv6="$ol_arg"
2285
2286 else
2287         ol_enable_ipv6=auto
2288 fi;
2289 # end --enable-ipv6
2290 # OpenLDAP --enable-local
2291
2292         # Check whether --enable-local or --disable-local was given.
2293 if test "${enable_local+set}" = set; then
2294   enableval="$enable_local"
2295
2296         ol_arg=invalid
2297         for ol_val in auto yes no ; do
2298                 if test "$enableval" = "$ol_val" ; then
2299                         ol_arg="$ol_val"
2300                 fi
2301         done
2302         if test "$ol_arg" = "invalid" ; then
2303                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-local" >&5
2304 echo "$as_me: error: bad value $enableval for --enable-local" >&2;}
2305    { (exit 1); exit 1; }; }
2306         fi
2307         ol_enable_local="$ol_arg"
2308
2309 else
2310         ol_enable_local=auto
2311 fi;
2312 # end --enable-local
2313
2314 # OpenLDAP --with-cyrus_sasl
2315
2316 # Check whether --with-cyrus_sasl or --without-cyrus_sasl was given.
2317 if test "${with_cyrus_sasl+set}" = set; then
2318   withval="$with_cyrus_sasl"
2319
2320         ol_arg=invalid
2321         for ol_val in auto yes no  ; do
2322                 if test "$withval" = "$ol_val" ; then
2323                         ol_arg="$ol_val"
2324                 fi
2325         done
2326         if test "$ol_arg" = "invalid" ; then
2327                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-cyrus_sasl" >&5
2328 echo "$as_me: error: bad value $withval for --with-cyrus_sasl" >&2;}
2329    { (exit 1); exit 1; }; }
2330         fi
2331         ol_with_cyrus_sasl="$ol_arg"
2332
2333 else
2334         ol_with_cyrus_sasl="auto"
2335 fi; # end --with-cyrus_sasl
2336
2337 # OpenLDAP --with-fetch
2338
2339 # Check whether --with-fetch or --without-fetch was given.
2340 if test "${with_fetch+set}" = set; then
2341   withval="$with_fetch"
2342
2343         ol_arg=invalid
2344         for ol_val in auto yes no  ; do
2345                 if test "$withval" = "$ol_val" ; then
2346                         ol_arg="$ol_val"
2347                 fi
2348         done
2349         if test "$ol_arg" = "invalid" ; then
2350                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-fetch" >&5
2351 echo "$as_me: error: bad value $withval for --with-fetch" >&2;}
2352    { (exit 1); exit 1; }; }
2353         fi
2354         ol_with_fetch="$ol_arg"
2355
2356 else
2357         ol_with_fetch="auto"
2358 fi; # end --with-fetch
2359
2360 # OpenLDAP --with-threads
2361
2362 # Check whether --with-threads or --without-threads was given.
2363 if test "${with_threads+set}" = set; then
2364   withval="$with_threads"
2365
2366         ol_arg=invalid
2367         for ol_val in auto nt posix mach pth lwp yes no manual  ; do
2368                 if test "$withval" = "$ol_val" ; then
2369                         ol_arg="$ol_val"
2370                 fi
2371         done
2372         if test "$ol_arg" = "invalid" ; then
2373                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-threads" >&5
2374 echo "$as_me: error: bad value $withval for --with-threads" >&2;}
2375    { (exit 1); exit 1; }; }
2376         fi
2377         ol_with_threads="$ol_arg"
2378
2379 else
2380         ol_with_threads="auto"
2381 fi; # end --with-threads
2382
2383 # OpenLDAP --with-tls
2384
2385 # Check whether --with-tls or --without-tls was given.
2386 if test "${with_tls+set}" = set; then
2387   withval="$with_tls"
2388
2389         ol_arg=invalid
2390         for ol_val in auto openssl gnutls yes no  ; do
2391                 if test "$withval" = "$ol_val" ; then
2392                         ol_arg="$ol_val"
2393                 fi
2394         done
2395         if test "$ol_arg" = "invalid" ; then
2396                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-tls" >&5
2397 echo "$as_me: error: bad value $withval for --with-tls" >&2;}
2398    { (exit 1); exit 1; }; }
2399         fi
2400         ol_with_tls="$ol_arg"
2401
2402 else
2403         ol_with_tls="auto"
2404 fi; # end --with-tls
2405
2406 # OpenLDAP --with-yielding_select
2407
2408 # Check whether --with-yielding_select or --without-yielding_select was given.
2409 if test "${with_yielding_select+set}" = set; then
2410   withval="$with_yielding_select"
2411
2412         ol_arg=invalid
2413         for ol_val in auto yes no manual  ; do
2414                 if test "$withval" = "$ol_val" ; then
2415                         ol_arg="$ol_val"
2416                 fi
2417         done
2418         if test "$ol_arg" = "invalid" ; then
2419                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-yielding_select" >&5
2420 echo "$as_me: error: bad value $withval for --with-yielding_select" >&2;}
2421    { (exit 1); exit 1; }; }
2422         fi
2423         ol_with_yielding_select="$ol_arg"
2424
2425 else
2426         ol_with_yielding_select="auto"
2427 fi; # end --with-yielding_select
2428
2429 # OpenLDAP --with-mp
2430
2431 # Check whether --with-mp or --without-mp was given.
2432 if test "${with_mp+set}" = set; then
2433   withval="$with_mp"
2434
2435         ol_arg=invalid
2436         for ol_val in auto longlong long bignum gmp yes no ; do
2437                 if test "$withval" = "$ol_val" ; then
2438                         ol_arg="$ol_val"
2439                 fi
2440         done
2441         if test "$ol_arg" = "invalid" ; then
2442                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-mp" >&5
2443 echo "$as_me: error: bad value $withval for --with-mp" >&2;}
2444    { (exit 1); exit 1; }; }
2445         fi
2446         ol_with_mp="$ol_arg"
2447
2448 else
2449         ol_with_mp="auto"
2450 fi; # end --with-mp
2451
2452 # OpenLDAP --with-odbc
2453
2454 # Check whether --with-odbc or --without-odbc was given.
2455 if test "${with_odbc+set}" = set; then
2456   withval="$with_odbc"
2457
2458         ol_arg=invalid
2459         for ol_val in auto iodbc unixodbc odbc32  ; do
2460                 if test "$withval" = "$ol_val" ; then
2461                         ol_arg="$ol_val"
2462                 fi
2463         done
2464         if test "$ol_arg" = "invalid" ; then
2465                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-odbc" >&5
2466 echo "$as_me: error: bad value $withval for --with-odbc" >&2;}
2467    { (exit 1); exit 1; }; }
2468         fi
2469         ol_with_odbc="$ol_arg"
2470
2471 else
2472         ol_with_odbc="auto"
2473 fi; # end --with-odbc
2474
2475
2476
2477 # Check whether --enable-xxslapdoptions or --disable-xxslapdoptions was given.
2478 if test "${enable_xxslapdoptions+set}" = set; then
2479   enableval="$enable_xxslapdoptions"
2480
2481 fi;
2482 # OpenLDAP --enable-slapd
2483
2484         # Check whether --enable-slapd or --disable-slapd was given.
2485 if test "${enable_slapd+set}" = set; then
2486   enableval="$enable_slapd"
2487
2488         ol_arg=invalid
2489         for ol_val in auto yes no ; do
2490                 if test "$enableval" = "$ol_val" ; then
2491                         ol_arg="$ol_val"
2492                 fi
2493         done
2494         if test "$ol_arg" = "invalid" ; then
2495                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slapd" >&5
2496 echo "$as_me: error: bad value $enableval for --enable-slapd" >&2;}
2497    { (exit 1); exit 1; }; }
2498         fi
2499         ol_enable_slapd="$ol_arg"
2500
2501 else
2502         ol_enable_slapd=yes
2503 fi;
2504 # end --enable-slapd
2505 # OpenLDAP --enable-dynacl
2506
2507         # Check whether --enable-dynacl or --disable-dynacl was given.
2508 if test "${enable_dynacl+set}" = set; then
2509   enableval="$enable_dynacl"
2510
2511         ol_arg=invalid
2512         for ol_val in auto yes no ; do
2513                 if test "$enableval" = "$ol_val" ; then
2514                         ol_arg="$ol_val"
2515                 fi
2516         done
2517         if test "$ol_arg" = "invalid" ; then
2518                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dynacl" >&5
2519 echo "$as_me: error: bad value $enableval for --enable-dynacl" >&2;}
2520    { (exit 1); exit 1; }; }
2521         fi
2522         ol_enable_dynacl="$ol_arg"
2523
2524 else
2525         ol_enable_dynacl=no
2526 fi;
2527 # end --enable-dynacl
2528 # OpenLDAP --enable-aci
2529
2530         # Check whether --enable-aci or --disable-aci was given.
2531 if test "${enable_aci+set}" = set; then
2532   enableval="$enable_aci"
2533
2534         ol_arg=invalid
2535         for ol_val in no yes mod ; do
2536                 if test "$enableval" = "$ol_val" ; then
2537                         ol_arg="$ol_val"
2538                 fi
2539         done
2540         if test "$ol_arg" = "invalid" ; then
2541                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-aci" >&5
2542 echo "$as_me: error: bad value $enableval for --enable-aci" >&2;}
2543    { (exit 1); exit 1; }; }
2544         fi
2545         ol_enable_aci="$ol_arg"
2546
2547 else
2548         ol_enable_aci=no
2549 fi;
2550 # end --enable-aci
2551 # OpenLDAP --enable-cleartext
2552
2553         # Check whether --enable-cleartext or --disable-cleartext was given.
2554 if test "${enable_cleartext+set}" = set; then
2555   enableval="$enable_cleartext"
2556
2557         ol_arg=invalid
2558         for ol_val in auto yes no ; do
2559                 if test "$enableval" = "$ol_val" ; then
2560                         ol_arg="$ol_val"
2561                 fi
2562         done
2563         if test "$ol_arg" = "invalid" ; then
2564                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-cleartext" >&5
2565 echo "$as_me: error: bad value $enableval for --enable-cleartext" >&2;}
2566    { (exit 1); exit 1; }; }
2567         fi
2568         ol_enable_cleartext="$ol_arg"
2569
2570 else
2571         ol_enable_cleartext=yes
2572 fi;
2573 # end --enable-cleartext
2574 # OpenLDAP --enable-crypt
2575
2576         # Check whether --enable-crypt or --disable-crypt was given.
2577 if test "${enable_crypt+set}" = set; then
2578   enableval="$enable_crypt"
2579
2580         ol_arg=invalid
2581         for ol_val in auto yes no ; do
2582                 if test "$enableval" = "$ol_val" ; then
2583                         ol_arg="$ol_val"
2584                 fi
2585         done
2586         if test "$ol_arg" = "invalid" ; then
2587                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-crypt" >&5
2588 echo "$as_me: error: bad value $enableval for --enable-crypt" >&2;}
2589    { (exit 1); exit 1; }; }
2590         fi
2591         ol_enable_crypt="$ol_arg"
2592
2593 else
2594         ol_enable_crypt=no
2595 fi;
2596 # end --enable-crypt
2597 # OpenLDAP --enable-lmpasswd
2598
2599         # Check whether --enable-lmpasswd or --disable-lmpasswd was given.
2600 if test "${enable_lmpasswd+set}" = set; then
2601   enableval="$enable_lmpasswd"
2602
2603         ol_arg=invalid
2604         for ol_val in auto yes no ; do
2605                 if test "$enableval" = "$ol_val" ; then
2606                         ol_arg="$ol_val"
2607                 fi
2608         done
2609         if test "$ol_arg" = "invalid" ; then
2610                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-lmpasswd" >&5
2611 echo "$as_me: error: bad value $enableval for --enable-lmpasswd" >&2;}
2612    { (exit 1); exit 1; }; }
2613         fi
2614         ol_enable_lmpasswd="$ol_arg"
2615
2616 else
2617         ol_enable_lmpasswd=no
2618 fi;
2619 # end --enable-lmpasswd
2620 # OpenLDAP --enable-spasswd
2621
2622         # Check whether --enable-spasswd or --disable-spasswd was given.
2623 if test "${enable_spasswd+set}" = set; then
2624   enableval="$enable_spasswd"
2625
2626         ol_arg=invalid
2627         for ol_val in auto yes no ; do
2628                 if test "$enableval" = "$ol_val" ; then
2629                         ol_arg="$ol_val"
2630                 fi
2631         done
2632         if test "$ol_arg" = "invalid" ; then
2633                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-spasswd" >&5
2634 echo "$as_me: error: bad value $enableval for --enable-spasswd" >&2;}
2635    { (exit 1); exit 1; }; }
2636         fi
2637         ol_enable_spasswd="$ol_arg"
2638
2639 else
2640         ol_enable_spasswd=no
2641 fi;
2642 # end --enable-spasswd
2643 # OpenLDAP --enable-modules
2644
2645         # Check whether --enable-modules or --disable-modules was given.
2646 if test "${enable_modules+set}" = set; then
2647   enableval="$enable_modules"
2648
2649         ol_arg=invalid
2650         for ol_val in auto yes no ; do
2651                 if test "$enableval" = "$ol_val" ; then
2652                         ol_arg="$ol_val"
2653                 fi
2654         done
2655         if test "$ol_arg" = "invalid" ; then
2656                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-modules" >&5
2657 echo "$as_me: error: bad value $enableval for --enable-modules" >&2;}
2658    { (exit 1); exit 1; }; }
2659         fi
2660         ol_enable_modules="$ol_arg"
2661
2662 else
2663         ol_enable_modules=no
2664 fi;
2665 # end --enable-modules
2666 # OpenLDAP --enable-rewrite
2667
2668         # Check whether --enable-rewrite or --disable-rewrite was given.
2669 if test "${enable_rewrite+set}" = set; then
2670   enableval="$enable_rewrite"
2671
2672         ol_arg=invalid
2673         for ol_val in auto yes no ; do
2674                 if test "$enableval" = "$ol_val" ; then
2675                         ol_arg="$ol_val"
2676                 fi
2677         done
2678         if test "$ol_arg" = "invalid" ; then
2679                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rewrite" >&5
2680 echo "$as_me: error: bad value $enableval for --enable-rewrite" >&2;}
2681    { (exit 1); exit 1; }; }
2682         fi
2683         ol_enable_rewrite="$ol_arg"
2684
2685 else
2686         ol_enable_rewrite=auto
2687 fi;
2688 # end --enable-rewrite
2689 # OpenLDAP --enable-rlookups
2690
2691         # Check whether --enable-rlookups or --disable-rlookups was given.
2692 if test "${enable_rlookups+set}" = set; then
2693   enableval="$enable_rlookups"
2694
2695         ol_arg=invalid
2696         for ol_val in auto yes no ; do
2697                 if test "$enableval" = "$ol_val" ; then
2698                         ol_arg="$ol_val"
2699                 fi
2700         done
2701         if test "$ol_arg" = "invalid" ; then
2702                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rlookups" >&5
2703 echo "$as_me: error: bad value $enableval for --enable-rlookups" >&2;}
2704    { (exit 1); exit 1; }; }
2705         fi
2706         ol_enable_rlookups="$ol_arg"
2707
2708 else
2709         ol_enable_rlookups=no
2710 fi;
2711 # end --enable-rlookups
2712 # OpenLDAP --enable-slapi
2713
2714         # Check whether --enable-slapi or --disable-slapi was given.
2715 if test "${enable_slapi+set}" = set; then
2716   enableval="$enable_slapi"
2717
2718         ol_arg=invalid
2719         for ol_val in auto yes no ; do
2720                 if test "$enableval" = "$ol_val" ; then
2721                         ol_arg="$ol_val"
2722                 fi
2723         done
2724         if test "$ol_arg" = "invalid" ; then
2725                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slapi" >&5
2726 echo "$as_me: error: bad value $enableval for --enable-slapi" >&2;}
2727    { (exit 1); exit 1; }; }
2728         fi
2729         ol_enable_slapi="$ol_arg"
2730
2731 else
2732         ol_enable_slapi=no
2733 fi;
2734 # end --enable-slapi
2735 # OpenLDAP --enable-slp
2736
2737         # Check whether --enable-slp or --disable-slp was given.
2738 if test "${enable_slp+set}" = set; then
2739   enableval="$enable_slp"
2740
2741         ol_arg=invalid
2742         for ol_val in auto yes no ; do
2743                 if test "$enableval" = "$ol_val" ; then
2744                         ol_arg="$ol_val"
2745                 fi
2746         done
2747         if test "$ol_arg" = "invalid" ; then
2748                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slp" >&5
2749 echo "$as_me: error: bad value $enableval for --enable-slp" >&2;}
2750    { (exit 1); exit 1; }; }
2751         fi
2752         ol_enable_slp="$ol_arg"
2753
2754 else
2755         ol_enable_slp=no
2756 fi;
2757 # end --enable-slp
2758 # OpenLDAP --enable-wrappers
2759
2760         # Check whether --enable-wrappers or --disable-wrappers was given.
2761 if test "${enable_wrappers+set}" = set; then
2762   enableval="$enable_wrappers"
2763
2764         ol_arg=invalid
2765         for ol_val in auto yes no ; do
2766                 if test "$enableval" = "$ol_val" ; then
2767                         ol_arg="$ol_val"
2768                 fi
2769         done
2770         if test "$ol_arg" = "invalid" ; then
2771                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-wrappers" >&5
2772 echo "$as_me: error: bad value $enableval for --enable-wrappers" >&2;}
2773    { (exit 1); exit 1; }; }
2774         fi
2775         ol_enable_wrappers="$ol_arg"
2776
2777 else
2778         ol_enable_wrappers=no
2779 fi;
2780 # end --enable-wrappers
2781
2782 Backends="bdb \
2783         dnssrv \
2784         hdb \
2785         ldap \
2786         meta \
2787         monitor \
2788         ndb \
2789         null \
2790         passwd \
2791         perl \
2792         relay \
2793         shell \
2794         sock \
2795         sql"
2796
2797 # Check whether --enable-xxslapbackends or --disable-xxslapbackends was given.
2798 if test "${enable_xxslapbackends+set}" = set; then
2799   enableval="$enable_xxslapbackends"
2800
2801 fi;
2802
2803 # OpenLDAP --enable-backends
2804
2805         # Check whether --enable-backends or --disable-backends was given.
2806 if test "${enable_backends+set}" = set; then
2807   enableval="$enable_backends"
2808
2809         ol_arg=invalid
2810         for ol_val in no yes mod ; do
2811                 if test "$enableval" = "$ol_val" ; then
2812                         ol_arg="$ol_val"
2813                 fi
2814         done
2815         if test "$ol_arg" = "invalid" ; then
2816                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-backends" >&5
2817 echo "$as_me: error: bad value $enableval for --enable-backends" >&2;}
2818    { (exit 1); exit 1; }; }
2819         fi
2820         ol_enable_backends="$ol_arg"
2821
2822 fi;
2823 # end --enable-backends
2824 # OpenLDAP --enable-bdb
2825
2826         # Check whether --enable-bdb or --disable-bdb was given.
2827 if test "${enable_bdb+set}" = set; then
2828   enableval="$enable_bdb"
2829
2830         ol_arg=invalid
2831         for ol_val in no yes mod ; do
2832                 if test "$enableval" = "$ol_val" ; then
2833                         ol_arg="$ol_val"
2834                 fi
2835         done
2836         if test "$ol_arg" = "invalid" ; then
2837                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-bdb" >&5
2838 echo "$as_me: error: bad value $enableval for --enable-bdb" >&2;}
2839    { (exit 1); exit 1; }; }
2840         fi
2841         ol_enable_bdb="$ol_arg"
2842
2843 else
2844         ol_enable_bdb=${ol_enable_backends:-no}
2845 fi;
2846 # end --enable-bdb
2847 # OpenLDAP --enable-dnssrv
2848
2849         # Check whether --enable-dnssrv or --disable-dnssrv was given.
2850 if test "${enable_dnssrv+set}" = set; then
2851   enableval="$enable_dnssrv"
2852
2853         ol_arg=invalid
2854         for ol_val in no yes mod ; do
2855                 if test "$enableval" = "$ol_val" ; then
2856                         ol_arg="$ol_val"
2857                 fi
2858         done
2859         if test "$ol_arg" = "invalid" ; then
2860                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dnssrv" >&5
2861 echo "$as_me: error: bad value $enableval for --enable-dnssrv" >&2;}
2862    { (exit 1); exit 1; }; }
2863         fi
2864         ol_enable_dnssrv="$ol_arg"
2865
2866 else
2867         ol_enable_dnssrv=${ol_enable_backends:-no}
2868 fi;
2869 # end --enable-dnssrv
2870 # OpenLDAP --enable-hdb
2871
2872         # Check whether --enable-hdb or --disable-hdb was given.
2873 if test "${enable_hdb+set}" = set; then
2874   enableval="$enable_hdb"
2875
2876         ol_arg=invalid
2877         for ol_val in no yes mod ; do
2878                 if test "$enableval" = "$ol_val" ; then
2879                         ol_arg="$ol_val"
2880                 fi
2881         done
2882         if test "$ol_arg" = "invalid" ; then
2883                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-hdb" >&5
2884 echo "$as_me: error: bad value $enableval for --enable-hdb" >&2;}
2885    { (exit 1); exit 1; }; }
2886         fi
2887         ol_enable_hdb="$ol_arg"
2888
2889 else
2890         ol_enable_hdb=${ol_enable_backends:-yes}
2891 fi;
2892 # end --enable-hdb
2893 # OpenLDAP --enable-ldap
2894
2895         # Check whether --enable-ldap or --disable-ldap was given.
2896 if test "${enable_ldap+set}" = set; then
2897   enableval="$enable_ldap"
2898
2899         ol_arg=invalid
2900         for ol_val in no yes mod ; do
2901                 if test "$enableval" = "$ol_val" ; then
2902                         ol_arg="$ol_val"
2903                 fi
2904         done
2905         if test "$ol_arg" = "invalid" ; then
2906                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ldap" >&5
2907 echo "$as_me: error: bad value $enableval for --enable-ldap" >&2;}
2908    { (exit 1); exit 1; }; }
2909         fi
2910         ol_enable_ldap="$ol_arg"
2911
2912 else
2913         ol_enable_ldap=${ol_enable_backends:-no}
2914 fi;
2915 # end --enable-ldap
2916 # OpenLDAP --enable-meta
2917
2918         # Check whether --enable-meta or --disable-meta was given.
2919 if test "${enable_meta+set}" = set; then
2920   enableval="$enable_meta"
2921
2922         ol_arg=invalid
2923         for ol_val in no yes mod ; do
2924                 if test "$enableval" = "$ol_val" ; then
2925                         ol_arg="$ol_val"
2926                 fi
2927         done
2928         if test "$ol_arg" = "invalid" ; then
2929                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-meta" >&5
2930 echo "$as_me: error: bad value $enableval for --enable-meta" >&2;}
2931    { (exit 1); exit 1; }; }
2932         fi
2933         ol_enable_meta="$ol_arg"
2934
2935 else
2936         ol_enable_meta=${ol_enable_backends:-no}
2937 fi;
2938 # end --enable-meta
2939 # OpenLDAP --enable-monitor
2940
2941         # Check whether --enable-monitor or --disable-monitor was given.
2942 if test "${enable_monitor+set}" = set; then
2943   enableval="$enable_monitor"
2944
2945         ol_arg=invalid
2946         for ol_val in no yes mod ; do
2947                 if test "$enableval" = "$ol_val" ; then
2948                         ol_arg="$ol_val"
2949                 fi
2950         done
2951         if test "$ol_arg" = "invalid" ; then
2952                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-monitor" >&5
2953 echo "$as_me: error: bad value $enableval for --enable-monitor" >&2;}
2954    { (exit 1); exit 1; }; }
2955         fi
2956         ol_enable_monitor="$ol_arg"
2957
2958 else
2959         ol_enable_monitor=${ol_enable_backends:-yes}
2960 fi;
2961 # end --enable-monitor
2962 # OpenLDAP --enable-ndb
2963
2964         # Check whether --enable-ndb or --disable-ndb was given.
2965 if test "${enable_ndb+set}" = set; then
2966   enableval="$enable_ndb"
2967
2968         ol_arg=invalid
2969         for ol_val in no yes mod ; do
2970                 if test "$enableval" = "$ol_val" ; then
2971                         ol_arg="$ol_val"
2972                 fi
2973         done
2974         if test "$ol_arg" = "invalid" ; then
2975                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ndb" >&5
2976 echo "$as_me: error: bad value $enableval for --enable-ndb" >&2;}
2977    { (exit 1); exit 1; }; }
2978         fi
2979         ol_enable_ndb="$ol_arg"
2980
2981 else
2982         ol_enable_ndb=${ol_enable_backends:-no}
2983 fi;
2984 # end --enable-ndb
2985 # OpenLDAP --enable-null
2986
2987         # Check whether --enable-null or --disable-null was given.
2988 if test "${enable_null+set}" = set; then
2989   enableval="$enable_null"
2990
2991         ol_arg=invalid
2992         for ol_val in no yes mod ; do
2993                 if test "$enableval" = "$ol_val" ; then
2994                         ol_arg="$ol_val"
2995                 fi
2996         done
2997         if test "$ol_arg" = "invalid" ; then
2998                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-null" >&5
2999 echo "$as_me: error: bad value $enableval for --enable-null" >&2;}
3000    { (exit 1); exit 1; }; }
3001         fi
3002         ol_enable_null="$ol_arg"
3003
3004 else
3005         ol_enable_null=${ol_enable_backends:-no}
3006 fi;
3007 # end --enable-null
3008 # OpenLDAP --enable-passwd
3009
3010         # Check whether --enable-passwd or --disable-passwd was given.
3011 if test "${enable_passwd+set}" = set; then
3012   enableval="$enable_passwd"
3013
3014         ol_arg=invalid
3015         for ol_val in no yes mod ; do
3016                 if test "$enableval" = "$ol_val" ; then
3017                         ol_arg="$ol_val"
3018                 fi
3019         done
3020         if test "$ol_arg" = "invalid" ; then
3021                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-passwd" >&5
3022 echo "$as_me: error: bad value $enableval for --enable-passwd" >&2;}
3023    { (exit 1); exit 1; }; }
3024         fi
3025         ol_enable_passwd="$ol_arg"
3026
3027 else
3028         ol_enable_passwd=${ol_enable_backends:-no}
3029 fi;
3030 # end --enable-passwd
3031 # OpenLDAP --enable-perl
3032
3033         # Check whether --enable-perl or --disable-perl was given.
3034 if test "${enable_perl+set}" = set; then
3035   enableval="$enable_perl"
3036
3037         ol_arg=invalid
3038         for ol_val in no yes mod ; do
3039                 if test "$enableval" = "$ol_val" ; then
3040                         ol_arg="$ol_val"
3041                 fi
3042         done
3043         if test "$ol_arg" = "invalid" ; then
3044                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-perl" >&5
3045 echo "$as_me: error: bad value $enableval for --enable-perl" >&2;}
3046    { (exit 1); exit 1; }; }
3047         fi
3048         ol_enable_perl="$ol_arg"
3049
3050 else
3051         ol_enable_perl=${ol_enable_backends:-no}
3052 fi;
3053 # end --enable-perl
3054 # OpenLDAP --enable-relay
3055
3056         # Check whether --enable-relay or --disable-relay was given.
3057 if test "${enable_relay+set}" = set; then
3058   enableval="$enable_relay"
3059
3060         ol_arg=invalid
3061         for ol_val in no yes mod ; do
3062                 if test "$enableval" = "$ol_val" ; then
3063                         ol_arg="$ol_val"
3064                 fi
3065         done
3066         if test "$ol_arg" = "invalid" ; then
3067                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-relay" >&5
3068 echo "$as_me: error: bad value $enableval for --enable-relay" >&2;}
3069    { (exit 1); exit 1; }; }
3070         fi
3071         ol_enable_relay="$ol_arg"
3072
3073 else
3074         ol_enable_relay=${ol_enable_backends:-yes}
3075 fi;
3076 # end --enable-relay
3077 # OpenLDAP --enable-shell
3078
3079         # Check whether --enable-shell or --disable-shell was given.
3080 if test "${enable_shell+set}" = set; then
3081   enableval="$enable_shell"
3082
3083         ol_arg=invalid
3084         for ol_val in no yes mod ; do
3085                 if test "$enableval" = "$ol_val" ; then
3086                         ol_arg="$ol_val"
3087                 fi
3088         done
3089         if test "$ol_arg" = "invalid" ; then
3090                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-shell" >&5
3091 echo "$as_me: error: bad value $enableval for --enable-shell" >&2;}
3092    { (exit 1); exit 1; }; }
3093         fi
3094         ol_enable_shell="$ol_arg"
3095
3096 else
3097         ol_enable_shell=${ol_enable_backends:-no}
3098 fi;
3099 # end --enable-shell
3100 # OpenLDAP --enable-sock
3101
3102         # Check whether --enable-sock or --disable-sock was given.
3103 if test "${enable_sock+set}" = set; then
3104   enableval="$enable_sock"
3105
3106         ol_arg=invalid
3107         for ol_val in no yes mod ; do
3108                 if test "$enableval" = "$ol_val" ; then
3109                         ol_arg="$ol_val"
3110                 fi
3111         done
3112         if test "$ol_arg" = "invalid" ; then
3113                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-sock" >&5
3114 echo "$as_me: error: bad value $enableval for --enable-sock" >&2;}
3115    { (exit 1); exit 1; }; }
3116         fi
3117         ol_enable_sock="$ol_arg"
3118
3119 else
3120         ol_enable_sock=${ol_enable_backends:-no}
3121 fi;
3122 # end --enable-sock
3123 # OpenLDAP --enable-sql
3124
3125         # Check whether --enable-sql or --disable-sql was given.
3126 if test "${enable_sql+set}" = set; then
3127   enableval="$enable_sql"
3128
3129         ol_arg=invalid
3130         for ol_val in no yes mod ; do
3131                 if test "$enableval" = "$ol_val" ; then
3132                         ol_arg="$ol_val"
3133                 fi
3134         done
3135         if test "$ol_arg" = "invalid" ; then
3136                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-sql" >&5
3137 echo "$as_me: error: bad value $enableval for --enable-sql" >&2;}
3138    { (exit 1); exit 1; }; }
3139         fi
3140         ol_enable_sql="$ol_arg"
3141
3142 else
3143         ol_enable_sql=${ol_enable_backends:-no}
3144 fi;
3145 # end --enable-sql
3146
3147 Overlays="accesslog \
3148         auditlog \
3149         constraint \
3150         dds \
3151         dyngroup \
3152         dynlist \
3153         memberof \
3154         ppolicy \
3155         proxycache \
3156         refint \
3157         retcode \
3158         rwm \
3159         seqmod \
3160         syncprov \
3161         translucent \
3162         unique \
3163         valsort"
3164
3165 # Check whether --enable-xxslapoverlays or --disable-xxslapoverlays was given.
3166 if test "${enable_xxslapoverlays+set}" = set; then
3167   enableval="$enable_xxslapoverlays"
3168
3169 fi;
3170
3171 # OpenLDAP --enable-overlays
3172
3173         # Check whether --enable-overlays or --disable-overlays was given.
3174 if test "${enable_overlays+set}" = set; then
3175   enableval="$enable_overlays"
3176
3177         ol_arg=invalid
3178         for ol_val in no yes mod ; do
3179                 if test "$enableval" = "$ol_val" ; then
3180                         ol_arg="$ol_val"
3181                 fi
3182         done
3183         if test "$ol_arg" = "invalid" ; then
3184                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-overlays" >&5
3185 echo "$as_me: error: bad value $enableval for --enable-overlays" >&2;}
3186    { (exit 1); exit 1; }; }
3187         fi
3188         ol_enable_overlays="$ol_arg"
3189
3190 fi;
3191 # end --enable-overlays
3192 # OpenLDAP --enable-accesslog
3193
3194         # Check whether --enable-accesslog or --disable-accesslog was given.
3195 if test "${enable_accesslog+set}" = set; then
3196   enableval="$enable_accesslog"
3197
3198         ol_arg=invalid
3199         for ol_val in no yes mod ; do
3200                 if test "$enableval" = "$ol_val" ; then
3201                         ol_arg="$ol_val"
3202                 fi
3203         done
3204         if test "$ol_arg" = "invalid" ; then
3205                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-accesslog" >&5
3206 echo "$as_me: error: bad value $enableval for --enable-accesslog" >&2;}
3207    { (exit 1); exit 1; }; }
3208         fi
3209         ol_enable_accesslog="$ol_arg"
3210
3211 else
3212         ol_enable_accesslog=${ol_enable_overlays:-no}
3213 fi;
3214 # end --enable-accesslog
3215
3216 # OpenLDAP --enable-auditlog
3217
3218         # Check whether --enable-auditlog or --disable-auditlog was given.
3219 if test "${enable_auditlog+set}" = set; then
3220   enableval="$enable_auditlog"
3221
3222         ol_arg=invalid
3223         for ol_val in no yes mod ; do
3224                 if test "$enableval" = "$ol_val" ; then
3225                         ol_arg="$ol_val"
3226                 fi
3227         done
3228         if test "$ol_arg" = "invalid" ; then
3229                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-auditlog" >&5
3230 echo "$as_me: error: bad value $enableval for --enable-auditlog" >&2;}
3231    { (exit 1); exit 1; }; }
3232         fi
3233         ol_enable_auditlog="$ol_arg"
3234
3235 else
3236         ol_enable_auditlog=${ol_enable_overlays:-no}
3237 fi;
3238 # end --enable-auditlog
3239
3240 # OpenLDAP --enable-constraint
3241
3242         # Check whether --enable-constraint or --disable-constraint was given.
3243 if test "${enable_constraint+set}" = set; then
3244   enableval="$enable_constraint"
3245
3246         ol_arg=invalid
3247         for ol_val in no yes mod ; do
3248                 if test "$enableval" = "$ol_val" ; then
3249                         ol_arg="$ol_val"
3250                 fi
3251         done
3252         if test "$ol_arg" = "invalid" ; then
3253                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-constraint" >&5
3254 echo "$as_me: error: bad value $enableval for --enable-constraint" >&2;}
3255    { (exit 1); exit 1; }; }
3256         fi
3257         ol_enable_constraint="$ol_arg"
3258
3259 else
3260         ol_enable_constraint=${ol_enable_overlays:-no}
3261 fi;
3262 # end --enable-constraint
3263
3264 # OpenLDAP --enable-dds
3265
3266         # Check whether --enable-dds or --disable-dds was given.
3267 if test "${enable_dds+set}" = set; then
3268   enableval="$enable_dds"
3269
3270         ol_arg=invalid
3271         for ol_val in no yes mod ; do
3272                 if test "$enableval" = "$ol_val" ; then
3273                         ol_arg="$ol_val"
3274                 fi
3275         done
3276         if test "$ol_arg" = "invalid" ; then
3277                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dds" >&5
3278 echo "$as_me: error: bad value $enableval for --enable-dds" >&2;}
3279    { (exit 1); exit 1; }; }
3280         fi
3281         ol_enable_dds="$ol_arg"
3282
3283 else
3284         ol_enable_dds=${ol_enable_overlays:-no}
3285 fi;
3286 # end --enable-dds
3287
3288 # OpenLDAP --enable-dyngroup
3289
3290         # Check whether --enable-dyngroup or --disable-dyngroup was given.
3291 if test "${enable_dyngroup+set}" = set; then
3292   enableval="$enable_dyngroup"
3293
3294         ol_arg=invalid
3295         for ol_val in no yes mod ; do
3296                 if test "$enableval" = "$ol_val" ; then
3297                         ol_arg="$ol_val"
3298                 fi
3299         done
3300         if test "$ol_arg" = "invalid" ; then
3301                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dyngroup" >&5
3302 echo "$as_me: error: bad value $enableval for --enable-dyngroup" >&2;}
3303    { (exit 1); exit 1; }; }
3304         fi
3305         ol_enable_dyngroup="$ol_arg"
3306
3307 else
3308         ol_enable_dyngroup=${ol_enable_overlays:-no}
3309 fi;
3310 # end --enable-dyngroup
3311
3312 # OpenLDAP --enable-dynlist
3313
3314         # Check whether --enable-dynlist or --disable-dynlist was given.
3315 if test "${enable_dynlist+set}" = set; then
3316   enableval="$enable_dynlist"
3317
3318         ol_arg=invalid
3319         for ol_val in no yes mod ; do
3320                 if test "$enableval" = "$ol_val" ; then
3321                         ol_arg="$ol_val"
3322                 fi
3323         done
3324         if test "$ol_arg" = "invalid" ; then
3325                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dynlist" >&5
3326 echo "$as_me: error: bad value $enableval for --enable-dynlist" >&2;}
3327    { (exit 1); exit 1; }; }
3328         fi
3329         ol_enable_dynlist="$ol_arg"
3330
3331 else
3332         ol_enable_dynlist=${ol_enable_overlays:-no}
3333 fi;
3334 # end --enable-dynlist
3335
3336 # OpenLDAP --enable-memberof
3337
3338         # Check whether --enable-memberof or --disable-memberof was given.
3339 if test "${enable_memberof+set}" = set; then
3340   enableval="$enable_memberof"
3341
3342         ol_arg=invalid
3343         for ol_val in no yes mod ; do
3344                 if test "$enableval" = "$ol_val" ; then
3345                         ol_arg="$ol_val"
3346                 fi
3347         done
3348         if test "$ol_arg" = "invalid" ; then
3349                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-memberof" >&5
3350 echo "$as_me: error: bad value $enableval for --enable-memberof" >&2;}
3351    { (exit 1); exit 1; }; }
3352         fi
3353         ol_enable_memberof="$ol_arg"
3354
3355 else
3356         ol_enable_memberof=${ol_enable_overlays:-no}
3357 fi;
3358 # end --enable-memberof
3359
3360 # OpenLDAP --enable-ppolicy
3361
3362         # Check whether --enable-ppolicy or --disable-ppolicy was given.
3363 if test "${enable_ppolicy+set}" = set; then
3364   enableval="$enable_ppolicy"
3365
3366         ol_arg=invalid
3367         for ol_val in no yes mod ; do
3368                 if test "$enableval" = "$ol_val" ; then
3369                         ol_arg="$ol_val"
3370                 fi
3371         done
3372         if test "$ol_arg" = "invalid" ; then
3373                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ppolicy" >&5
3374 echo "$as_me: error: bad value $enableval for --enable-ppolicy" >&2;}
3375    { (exit 1); exit 1; }; }
3376         fi
3377         ol_enable_ppolicy="$ol_arg"
3378
3379 else
3380         ol_enable_ppolicy=${ol_enable_overlays:-no}
3381 fi;
3382 # end --enable-ppolicy
3383
3384 # OpenLDAP --enable-proxycache
3385
3386         # Check whether --enable-proxycache or --disable-proxycache was given.
3387 if test "${enable_proxycache+set}" = set; then
3388   enableval="$enable_proxycache"
3389
3390         ol_arg=invalid
3391         for ol_val in no yes mod ; do
3392                 if test "$enableval" = "$ol_val" ; then
3393                         ol_arg="$ol_val"
3394                 fi
3395         done
3396         if test "$ol_arg" = "invalid" ; then
3397                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-proxycache" >&5
3398 echo "$as_me: error: bad value $enableval for --enable-proxycache" >&2;}
3399    { (exit 1); exit 1; }; }
3400         fi
3401         ol_enable_proxycache="$ol_arg"
3402
3403 else
3404         ol_enable_proxycache=${ol_enable_overlays:-no}
3405 fi;
3406 # end --enable-proxycache
3407
3408 # OpenLDAP --enable-refint
3409
3410         # Check whether --enable-refint or --disable-refint was given.
3411 if test "${enable_refint+set}" = set; then
3412   enableval="$enable_refint"
3413
3414         ol_arg=invalid
3415         for ol_val in no yes mod ; do
3416                 if test "$enableval" = "$ol_val" ; then
3417                         ol_arg="$ol_val"
3418                 fi
3419         done
3420         if test "$ol_arg" = "invalid" ; then
3421                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-refint" >&5
3422 echo "$as_me: error: bad value $enableval for --enable-refint" >&2;}
3423    { (exit 1); exit 1; }; }
3424         fi
3425         ol_enable_refint="$ol_arg"
3426
3427 else
3428         ol_enable_refint=${ol_enable_overlays:-no}
3429 fi;
3430 # end --enable-refint
3431
3432 # OpenLDAP --enable-retcode
3433
3434         # Check whether --enable-retcode or --disable-retcode was given.
3435 if test "${enable_retcode+set}" = set; then
3436   enableval="$enable_retcode"
3437
3438         ol_arg=invalid
3439         for ol_val in no yes mod ; do
3440                 if test "$enableval" = "$ol_val" ; then
3441                         ol_arg="$ol_val"
3442                 fi
3443         done
3444         if test "$ol_arg" = "invalid" ; then
3445                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-retcode" >&5
3446 echo "$as_me: error: bad value $enableval for --enable-retcode" >&2;}
3447    { (exit 1); exit 1; }; }
3448         fi
3449         ol_enable_retcode="$ol_arg"
3450
3451 else
3452         ol_enable_retcode=${ol_enable_overlays:-no}
3453 fi;
3454 # end --enable-retcode
3455
3456 # OpenLDAP --enable-rwm
3457
3458         # Check whether --enable-rwm or --disable-rwm was given.
3459 if test "${enable_rwm+set}" = set; then
3460   enableval="$enable_rwm"
3461
3462         ol_arg=invalid
3463         for ol_val in no yes mod ; do
3464                 if test "$enableval" = "$ol_val" ; then
3465                         ol_arg="$ol_val"
3466                 fi
3467         done
3468         if test "$ol_arg" = "invalid" ; then
3469                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rwm" >&5
3470 echo "$as_me: error: bad value $enableval for --enable-rwm" >&2;}
3471    { (exit 1); exit 1; }; }
3472         fi
3473         ol_enable_rwm="$ol_arg"
3474
3475 else
3476         ol_enable_rwm=${ol_enable_overlays:-no}
3477 fi;
3478 # end --enable-rwm
3479
3480 # OpenLDAP --enable-seqmod
3481
3482         # Check whether --enable-seqmod or --disable-seqmod was given.
3483 if test "${enable_seqmod+set}" = set; then
3484   enableval="$enable_seqmod"
3485
3486         ol_arg=invalid
3487         for ol_val in no yes mod ; do
3488                 if test "$enableval" = "$ol_val" ; then
3489                         ol_arg="$ol_val"
3490                 fi
3491         done
3492         if test "$ol_arg" = "invalid" ; then
3493                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-seqmod" >&5
3494 echo "$as_me: error: bad value $enableval for --enable-seqmod" >&2;}
3495    { (exit 1); exit 1; }; }
3496         fi
3497         ol_enable_seqmod="$ol_arg"
3498
3499 else
3500         ol_enable_seqmod=${ol_enable_overlays:-yes}
3501 fi;
3502 # end --enable-seqmod
3503
3504 # OpenLDAP --enable-syncprov
3505
3506         # Check whether --enable-syncprov or --disable-syncprov was given.
3507 if test "${enable_syncprov+set}" = set; then
3508   enableval="$enable_syncprov"
3509
3510         ol_arg=invalid
3511         for ol_val in no yes mod ; do
3512                 if test "$enableval" = "$ol_val" ; then
3513                         ol_arg="$ol_val"
3514                 fi
3515         done
3516         if test "$ol_arg" = "invalid" ; then
3517                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-syncprov" >&5
3518 echo "$as_me: error: bad value $enableval for --enable-syncprov" >&2;}
3519    { (exit 1); exit 1; }; }
3520         fi
3521         ol_enable_syncprov="$ol_arg"
3522
3523 else
3524         ol_enable_syncprov=${ol_enable_overlays:-yes}
3525 fi;
3526 # end --enable-syncprov
3527
3528 # OpenLDAP --enable-translucent
3529
3530         # Check whether --enable-translucent or --disable-translucent was given.
3531 if test "${enable_translucent+set}" = set; then
3532   enableval="$enable_translucent"
3533
3534         ol_arg=invalid
3535         for ol_val in no yes mod ; do
3536                 if test "$enableval" = "$ol_val" ; then
3537                         ol_arg="$ol_val"
3538                 fi
3539         done
3540         if test "$ol_arg" = "invalid" ; then
3541                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-translucent" >&5
3542 echo "$as_me: error: bad value $enableval for --enable-translucent" >&2;}
3543    { (exit 1); exit 1; }; }
3544         fi
3545         ol_enable_translucent="$ol_arg"
3546
3547 else
3548         ol_enable_translucent=${ol_enable_overlays:-no}
3549 fi;
3550 # end --enable-translucent
3551
3552 # OpenLDAP --enable-unique
3553
3554         # Check whether --enable-unique or --disable-unique was given.
3555 if test "${enable_unique+set}" = set; then
3556   enableval="$enable_unique"
3557
3558         ol_arg=invalid
3559         for ol_val in no yes mod ; do
3560                 if test "$enableval" = "$ol_val" ; then
3561                         ol_arg="$ol_val"
3562                 fi
3563         done
3564         if test "$ol_arg" = "invalid" ; then
3565                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-unique" >&5
3566 echo "$as_me: error: bad value $enableval for --enable-unique" >&2;}
3567    { (exit 1); exit 1; }; }
3568         fi
3569         ol_enable_unique="$ol_arg"
3570
3571 else
3572         ol_enable_unique=${ol_enable_overlays:-no}
3573 fi;
3574 # end --enable-unique
3575
3576 # OpenLDAP --enable-valsort
3577
3578         # Check whether --enable-valsort or --disable-valsort was given.
3579 if test "${enable_valsort+set}" = set; then
3580   enableval="$enable_valsort"
3581
3582         ol_arg=invalid
3583         for ol_val in no yes mod ; do
3584                 if test "$enableval" = "$ol_val" ; then
3585                         ol_arg="$ol_val"
3586                 fi
3587         done
3588         if test "$ol_arg" = "invalid" ; then
3589                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-valsort" >&5
3590 echo "$as_me: error: bad value $enableval for --enable-valsort" >&2;}
3591    { (exit 1); exit 1; }; }
3592         fi
3593         ol_enable_valsort="$ol_arg"
3594
3595 else
3596         ol_enable_valsort=${ol_enable_overlays:-no}
3597 fi;
3598 # end --enable-valsort
3599
3600
3601 # Check whether --enable-xxliboptions or --disable-xxliboptions was given.
3602 if test "${enable_xxliboptions+set}" = set; then
3603   enableval="$enable_xxliboptions"
3604
3605 fi;
3606 # Check whether --enable-static or --disable-static was given.
3607 if test "${enable_static+set}" = set; then
3608   enableval="$enable_static"
3609   p=${PACKAGE-default}
3610     case $enableval in
3611     yes) enable_static=yes ;;
3612     no) enable_static=no ;;
3613     *)
3614      enable_static=no
3615       # Look at the argument we got.  We use all the common list separators.
3616       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
3617       for pkg in $enableval; do
3618         IFS="$lt_save_ifs"
3619         if test "X$pkg" = "X$p"; then
3620           enable_static=yes
3621         fi
3622       done
3623       IFS="$lt_save_ifs"
3624       ;;
3625     esac
3626 else
3627   enable_static=yes
3628 fi;
3629
3630 # Check whether --enable-shared or --disable-shared was given.
3631 if test "${enable_shared+set}" = set; then
3632   enableval="$enable_shared"
3633   p=${PACKAGE-default}
3634     case $enableval in
3635     yes) enable_shared=yes ;;
3636     no) enable_shared=no ;;
3637     *)
3638       enable_shared=no
3639       # Look at the argument we got.  We use all the common list separators.
3640       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
3641       for pkg in $enableval; do
3642         IFS="$lt_save_ifs"
3643         if test "X$pkg" = "X$p"; then
3644           enable_shared=yes
3645         fi
3646       done
3647       IFS="$lt_save_ifs"
3648       ;;
3649     esac
3650 else
3651   enable_shared=yes
3652 fi;
3653
3654
3655
3656 # validate options
3657 if test $ol_enable_slapd = no ; then
3658                 if test $ol_enable_slapi = yes ; then
3659                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-slapi argument" >&5
3660 echo "$as_me: WARNING: slapd disabled, ignoring --enable-slapi argument" >&2;}
3661         fi
3662         case "$ol_enable_backends" in yes | mod)
3663                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-backends argument" >&5
3664 echo "$as_me: WARNING: slapd disabled, ignoring --enable-backends argument" >&2;}
3665         esac
3666         for i in $Backends; do
3667                 eval "ol_tmp=\$ol_enable_$i"
3668                 if test $ol_tmp != no ; then
3669                         { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-$i argument" >&5
3670 echo "$as_me: WARNING: slapd disabled, ignoring --enable-$i argument" >&2;}
3671                         eval "ol_enable_$i=no"
3672                 fi
3673         done
3674         if test $ol_enable_modules = yes ; then
3675                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-modules argument" >&5
3676 echo "$as_me: WARNING: slapd disabled, ignoring --enable-modules argument" >&2;}
3677         fi
3678         if test $ol_enable_wrappers = yes ; then
3679                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-wrappers argument" >&5
3680 echo "$as_me: WARNING: slapd disabled, ignoring --enable-wrappers argument" >&2;}
3681         fi
3682         if test $ol_enable_rlookups = yes ; then
3683                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-rlookups argument" >&5
3684 echo "$as_me: WARNING: slapd disabled, ignoring --enable-rlookups argument" >&2;}
3685         fi
3686         if test $ol_enable_dynacl = yes ; then
3687                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-dynacl argument" >&5
3688 echo "$as_me: WARNING: slapd disabled, ignoring --enable-dynacl argument" >&2;}
3689         fi
3690         if test $ol_enable_aci != no ; then
3691                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-aci argument" >&5
3692 echo "$as_me: WARNING: slapd disabled, ignoring --enable-aci argument" >&2;}
3693         fi
3694         if test $ol_enable_rewrite = yes ; then
3695                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-rewrite argument" >&5
3696 echo "$as_me: WARNING: slapd disabled, ignoring --enable-rewrite argument" >&2;}
3697         fi
3698                 case "$ol_enable_overlays" in yes | mod)
3699                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-overlays argument" >&5
3700 echo "$as_me: WARNING: slapd disabled, ignoring --enable-overlays argument" >&2;}
3701         esac
3702         for i in $Overlays; do
3703                 eval "ol_tmp=\$ol_enable_$i"
3704                 if test $ol_tmp != no ; then
3705                         { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-$i argument" >&5
3706 echo "$as_me: WARNING: slapd disabled, ignoring --enable-$i argument" >&2;}
3707                         eval "ol_enable_$i=no"
3708                 fi
3709         done
3710
3711         # force settings to no
3712         ol_enable_slapi=no
3713
3714         ol_enable_backends=
3715         ol_enable_overlays=
3716         ol_enable_modules=no
3717         ol_enable_rlookups=no
3718         ol_enable_dynacl=no
3719         ol_enable_aci=no
3720         ol_enable_wrappers=no
3721
3722         ol_enable_rewrite=no
3723
3724 elif test $ol_enable_modules != yes &&
3725         test $ol_enable_bdb = no &&
3726         test $ol_enable_dnssrv = no &&
3727         test $ol_enable_hdb = no &&
3728         test $ol_enable_ldap = no &&
3729         test $ol_enable_meta = no &&
3730         test $ol_enable_monitor = no &&
3731         test $ol_enable_ndb = no &&
3732         test $ol_enable_null = no &&
3733         test $ol_enable_passwd = no &&
3734         test $ol_enable_perl = no &&
3735         test $ol_enable_relay = no &&
3736         test $ol_enable_shell = no &&
3737         test $ol_enable_sock = no &&
3738         test $ol_enable_sql = no ; then
3739
3740         if test $ol_enable_slapd = yes ; then
3741                 { { echo "$as_me:$LINENO: error: slapd requires a backend" >&5
3742 echo "$as_me: error: slapd requires a backend" >&2;}
3743    { (exit 1); exit 1; }; }
3744         else
3745                 { echo "$as_me:$LINENO: WARNING: skipping slapd, no backend specified" >&5
3746 echo "$as_me: WARNING: skipping slapd, no backend specified" >&2;}
3747                 ol_enable_slapd=no
3748         fi
3749 fi
3750
3751 if test $ol_enable_meta/$ol_enable_ldap = yes/no ; then
3752         { { echo "$as_me:$LINENO: error: --enable-meta requires --enable-ldap" >&5
3753 echo "$as_me: error: --enable-meta requires --enable-ldap" >&2;}
3754    { (exit 1); exit 1; }; }
3755 fi
3756
3757 if test $ol_enable_lmpasswd = yes ; then
3758         if test $ol_with_tls = no ; then
3759                 { { echo "$as_me:$LINENO: error: LAN Manager passwords require OpenSSL" >&5
3760 echo "$as_me: error: LAN Manager passwords require OpenSSL" >&2;}
3761    { (exit 1); exit 1; }; }
3762         fi
3763 fi
3764
3765 if test $ol_enable_spasswd = yes ; then
3766         if test $ol_with_cyrus_sasl = no ; then
3767                 { { echo "$as_me:$LINENO: error: options require --with-cyrus-sasl" >&5
3768 echo "$as_me: error: options require --with-cyrus-sasl" >&2;}
3769    { (exit 1); exit 1; }; }
3770         fi
3771         ol_with_cyrus_sasl=yes
3772 fi
3773
3774 echo "$as_me:$LINENO: result: done" >&5
3775 echo "${ECHO_T}done" >&6
3776
3777 LDAP_LIBS=
3778 BDB_LIBS=
3779 SLAPD_NDB_LIBS=
3780 SLAPD_NDB_INCS=
3781 LTHREAD_LIBS=
3782 LUTIL_LIBS=
3783
3784 SLAPD_LIBS=
3785
3786 BUILD_SLAPD=no
3787
3788 BUILD_THREAD=no
3789
3790 BUILD_SLAPI=no
3791 SLAPD_SLAPI_DEPEND=
3792
3793 BUILD_BDB=no
3794 BUILD_DNSSRV=no
3795 BUILD_HDB=no
3796 BUILD_LDAP=no
3797 BUILD_META=no
3798 BUILD_MONITOR=no
3799 BUILD_NDB=no
3800 BUILD_NULL=no
3801 BUILD_PASSWD=no
3802 BUILD_PERL=no
3803 BUILD_RELAY=no
3804 BUILD_SHELL=no
3805 BUILD_SOCK=no
3806 BUILD_SQL=no
3807
3808 BUILD_ACCESSLOG=no
3809 BUILD_AUDITLOG=no
3810 BUILD_CONSTRAINT=no
3811 BUILD_DDS=no
3812 BUILD_DENYOP=no
3813 BUILD_DYNGROUP=no
3814 BUILD_DYNLIST=no
3815 BUILD_LASTMOD=no
3816 BUILD_MEMBEROF=no
3817 BUILD_PPOLICY=no
3818 BUILD_PROXYCACHE=no
3819 BUILD_REFINT=no
3820 BUILD_RETCODE=no
3821 BUILD_RWM=no
3822 BUILD_SEQMOD=no
3823 BUILD_SYNCPROV=no
3824 BUILD_TRANSLUCENT=no
3825 BUILD_UNIQUE=no
3826 BUILD_VALSORT=no
3827
3828 SLAPD_STATIC_OVERLAYS=
3829 SLAPD_DYNAMIC_OVERLAYS=
3830
3831 SLAPD_MODULES_LDFLAGS=
3832 SLAPD_MODULES_CPPFLAGS=
3833
3834 SLAPD_STATIC_BACKENDS=back-ldif
3835 SLAPD_DYNAMIC_BACKENDS=
3836
3837 SLAPD_PERL_LDFLAGS=
3838 MOD_PERL_LDFLAGS=
3839 PERL_CPPFLAGS=
3840
3841 SLAPD_SQL_LDFLAGS=
3842 SLAPD_SQL_LIBS=
3843 SLAPD_SQL_INCLUDES=
3844
3845 KRB4_LIBS=
3846 KRB5_LIBS=
3847 SASL_LIBS=
3848 TLS_LIBS=
3849 MODULES_LIBS=
3850 SLAPI_LIBS=
3851 LIBSLAPI=
3852 LIBSLAPITOOLS=
3853 AUTH_LIBS=
3854 ICU_LIBS=
3855
3856 SLAPD_SLP_LIBS=
3857 SLAPD_GMP_LIBS=
3858
3859
3860
3861 cat >>confdefs.h <<\_ACEOF
3862 #define HAVE_MKVERSION 1
3863 _ACEOF
3864
3865
3866
3867
3868 ol_aix_threads=no
3869 case "$target" in
3870 *-*-aix*)       if test -z "$CC" ; then
3871                 case "$ol_with_threads" in
3872                 auto | yes |  posix) ol_aix_threads=yes ;;
3873                 esac
3874         fi
3875 ;;
3876 esac
3877
3878 if test $ol_aix_threads = yes ; then
3879         if test -z "${CC}" ; then
3880                 for ac_prog in cc_r xlc_r cc
3881 do
3882   # Extract the first word of "$ac_prog", so it can be a program name with args.
3883 set dummy $ac_prog; ac_word=$2
3884 echo "$as_me:$LINENO: checking for $ac_word" >&5
3885 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3886 if test "${ac_cv_prog_CC+set}" = set; then
3887   echo $ECHO_N "(cached) $ECHO_C" >&6
3888 else
3889   if test -n "$CC"; then
3890   ac_cv_prog_CC="$CC" # Let the user override the test.
3891 else
3892 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3893 for as_dir in $PATH
3894 do
3895   IFS=$as_save_IFS
3896   test -z "$as_dir" && as_dir=.
3897   for ac_exec_ext in '' $ac_executable_extensions; do
3898   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3899     ac_cv_prog_CC="$ac_prog"
3900     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3901     break 2
3902   fi
3903 done
3904 done
3905
3906 fi
3907 fi
3908 CC=$ac_cv_prog_CC
3909 if test -n "$CC"; then
3910   echo "$as_me:$LINENO: result: $CC" >&5
3911 echo "${ECHO_T}$CC" >&6
3912 else
3913   echo "$as_me:$LINENO: result: no" >&5
3914 echo "${ECHO_T}no" >&6
3915 fi
3916
3917   test -n "$CC" && break
3918 done
3919
3920
3921                 if test "$CC" = cc ; then
3922                                                 if test $ol_with_threads != auto ; then
3923                                 { { echo "$as_me:$LINENO: error: --with-threads requires cc_r (or other suitable compiler) on AIX" >&5
3924 echo "$as_me: error: --with-threads requires cc_r (or other suitable compiler) on AIX" >&2;}
3925    { (exit 1); exit 1; }; }
3926                         else
3927                                 { echo "$as_me:$LINENO: WARNING: disabling threads, no cc_r on AIX" >&5
3928 echo "$as_me: WARNING: disabling threads, no cc_r on AIX" >&2;}
3929                         fi
3930                         ol_with_threads=no
3931                 fi
3932         fi
3933
3934         case ${CC} in cc_r | xlc_r)
3935                 ol_with_threads=posix
3936                 ol_cv_pthread_create=yes
3937                 ;;
3938         esac
3939 fi
3940
3941 if test -z "${CC}"; then
3942         for ac_prog in cc gcc
3943 do
3944   # Extract the first word of "$ac_prog", so it can be a program name with args.
3945 set dummy $ac_prog; ac_word=$2
3946 echo "$as_me:$LINENO: checking for $ac_word" >&5
3947 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3948 if test "${ac_cv_prog_CC+set}" = set; then
3949   echo $ECHO_N "(cached) $ECHO_C" >&6
3950 else
3951   if test -n "$CC"; then
3952   ac_cv_prog_CC="$CC" # Let the user override the test.
3953 else
3954 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3955 for as_dir in $PATH
3956 do
3957   IFS=$as_save_IFS
3958   test -z "$as_dir" && as_dir=.
3959   for ac_exec_ext in '' $ac_executable_extensions; do
3960   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3961     ac_cv_prog_CC="$ac_prog"
3962     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3963     break 2
3964   fi
3965 done
3966 done
3967
3968 fi
3969 fi
3970 CC=$ac_cv_prog_CC
3971 if test -n "$CC"; then
3972   echo "$as_me:$LINENO: result: $CC" >&5
3973 echo "${ECHO_T}$CC" >&6
3974 else
3975   echo "$as_me:$LINENO: result: no" >&5
3976 echo "${ECHO_T}no" >&6
3977 fi
3978
3979   test -n "$CC" && break
3980 done
3981 test -n "$CC" || CC="missing"
3982
3983
3984         if test "${CC}" = "missing" ; then
3985                 { { echo "$as_me:$LINENO: error: Unable to locate cc(1) or suitable replacement.  Check PATH or set CC." >&5
3986 echo "$as_me: error: Unable to locate cc(1) or suitable replacement.  Check PATH or set CC." >&2;}
3987    { (exit 1); exit 1; }; }
3988         fi
3989 fi
3990
3991 if test -z "${AR}"; then
3992         for ac_prog in ar gar
3993 do
3994   # Extract the first word of "$ac_prog", so it can be a program name with args.
3995 set dummy $ac_prog; ac_word=$2
3996 echo "$as_me:$LINENO: checking for $ac_word" >&5
3997 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3998 if test "${ac_cv_prog_AR+set}" = set; then
3999   echo $ECHO_N "(cached) $ECHO_C" >&6
4000 else
4001   if test -n "$AR"; then
4002   ac_cv_prog_AR="$AR" # Let the user override the test.
4003 else
4004 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4005 for as_dir in $PATH
4006 do
4007   IFS=$as_save_IFS
4008   test -z "$as_dir" && as_dir=.
4009   for ac_exec_ext in '' $ac_executable_extensions; do
4010   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4011     ac_cv_prog_AR="$ac_prog"
4012     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4013     break 2
4014   fi
4015 done
4016 done
4017
4018 fi
4019 fi
4020 AR=$ac_cv_prog_AR
4021 if test -n "$AR"; then
4022   echo "$as_me:$LINENO: result: $AR" >&5
4023 echo "${ECHO_T}$AR" >&6
4024 else
4025   echo "$as_me:$LINENO: result: no" >&5
4026 echo "${ECHO_T}no" >&6
4027 fi
4028
4029   test -n "$AR" && break
4030 done
4031 test -n "$AR" || AR="missing"
4032
4033
4034         if test "${AR}" = "missing" ; then
4035                 { { echo "$as_me:$LINENO: error: Unable to locate ar(1) or suitable replacement.  Check PATH or set AR." >&5
4036 echo "$as_me: error: Unable to locate ar(1) or suitable replacement.  Check PATH or set AR." >&2;}
4037    { (exit 1); exit 1; }; }
4038         fi
4039 fi
4040
4041
4042
4043
4044
4045 # Check whether --enable-fast-install or --disable-fast-install was given.
4046 if test "${enable_fast_install+set}" = set; then
4047   enableval="$enable_fast_install"
4048   p=${PACKAGE-default}
4049     case $enableval in
4050     yes) enable_fast_install=yes ;;
4051     no) enable_fast_install=no ;;
4052     *)
4053       enable_fast_install=no
4054       # Look at the argument we got.  We use all the common list separators.
4055       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
4056       for pkg in $enableval; do
4057         IFS="$lt_save_ifs"
4058         if test "X$pkg" = "X$p"; then
4059           enable_fast_install=yes
4060         fi
4061       done
4062       IFS="$lt_save_ifs"
4063       ;;
4064     esac
4065 else
4066   enable_fast_install=yes
4067 fi;
4068
4069 DEPDIR="${am__leading_dot}deps"
4070
4071           ac_config_commands="$ac_config_commands depfiles"
4072
4073
4074 am_make=${MAKE-make}
4075 cat > confinc << 'END'
4076 am__doit:
4077         @echo done
4078 .PHONY: am__doit
4079 END
4080 # If we don't find an include directive, just comment out the code.
4081 echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5
4082 echo $ECHO_N "checking for style of include used by $am_make... $ECHO_C" >&6
4083 am__include="#"
4084 am__quote=
4085 _am_result=none
4086 # First try GNU make style include.
4087 echo "include confinc" > confmf
4088 # We grep out `Entering directory' and `Leaving directory'
4089 # messages which can occur if `w' ends up in MAKEFLAGS.
4090 # In particular we don't look at `^make:' because GNU make might
4091 # be invoked under some other name (usually "gmake"), in which
4092 # case it prints its new name instead of `make'.
4093 if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
4094    am__include=include
4095    am__quote=
4096    _am_result=GNU
4097 fi
4098 # Now try BSD make style include.
4099 if test "$am__include" = "#"; then
4100    echo '.include "confinc"' > confmf
4101    if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
4102       am__include=.include
4103       am__quote="\""
4104       _am_result=BSD
4105    fi
4106 fi
4107
4108
4109 echo "$as_me:$LINENO: result: $_am_result" >&5
4110 echo "${ECHO_T}$_am_result" >&6
4111 rm -f confinc confmf
4112
4113 # Check whether --enable-dependency-tracking or --disable-dependency-tracking was given.
4114 if test "${enable_dependency_tracking+set}" = set; then
4115   enableval="$enable_dependency_tracking"
4116
4117 fi;
4118 if test "x$enable_dependency_tracking" != xno; then
4119   am_depcomp="$ac_aux_dir/depcomp"
4120   AMDEPBACKSLASH='\'
4121 fi
4122
4123
4124 if test "x$enable_dependency_tracking" != xno; then
4125   AMDEP_TRUE=
4126   AMDEP_FALSE='#'
4127 else
4128   AMDEP_TRUE='#'
4129   AMDEP_FALSE=
4130 fi
4131
4132
4133
4134 ac_ext=c
4135 ac_cpp='$CPP $CPPFLAGS'
4136 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4137 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4138 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4139 if test -n "$ac_tool_prefix"; then
4140   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4141 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4142 echo "$as_me:$LINENO: checking for $ac_word" >&5
4143 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4144 if test "${ac_cv_prog_CC+set}" = set; then
4145   echo $ECHO_N "(cached) $ECHO_C" >&6
4146 else
4147   if test -n "$CC"; then
4148   ac_cv_prog_CC="$CC" # Let the user override the test.
4149 else
4150 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4151 for as_dir in $PATH
4152 do
4153   IFS=$as_save_IFS
4154   test -z "$as_dir" && as_dir=.
4155   for ac_exec_ext in '' $ac_executable_extensions; do
4156   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4157     ac_cv_prog_CC="${ac_tool_prefix}gcc"
4158     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4159     break 2
4160   fi
4161 done
4162 done
4163
4164 fi
4165 fi
4166 CC=$ac_cv_prog_CC
4167 if test -n "$CC"; then
4168   echo "$as_me:$LINENO: result: $CC" >&5
4169 echo "${ECHO_T}$CC" >&6
4170 else
4171   echo "$as_me:$LINENO: result: no" >&5
4172 echo "${ECHO_T}no" >&6
4173 fi
4174
4175 fi
4176 if test -z "$ac_cv_prog_CC"; then
4177   ac_ct_CC=$CC
4178   # Extract the first word of "gcc", so it can be a program name with args.
4179 set dummy gcc; ac_word=$2
4180 echo "$as_me:$LINENO: checking for $ac_word" >&5
4181 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4182 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
4183   echo $ECHO_N "(cached) $ECHO_C" >&6
4184 else
4185   if test -n "$ac_ct_CC"; then
4186   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4187 else
4188 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4189 for as_dir in $PATH
4190 do
4191   IFS=$as_save_IFS
4192   test -z "$as_dir" && as_dir=.
4193   for ac_exec_ext in '' $ac_executable_extensions; do
4194   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4195     ac_cv_prog_ac_ct_CC="gcc"
4196     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4197     break 2
4198   fi
4199 done
4200 done
4201
4202 fi
4203 fi
4204 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4205 if test -n "$ac_ct_CC"; then
4206   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4207 echo "${ECHO_T}$ac_ct_CC" >&6
4208 else
4209   echo "$as_me:$LINENO: result: no" >&5
4210 echo "${ECHO_T}no" >&6
4211 fi
4212
4213   CC=$ac_ct_CC
4214 else
4215   CC="$ac_cv_prog_CC"
4216 fi
4217
4218 if test -z "$CC"; then
4219   if test -n "$ac_tool_prefix"; then
4220   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4221 set dummy ${ac_tool_prefix}cc; ac_word=$2
4222 echo "$as_me:$LINENO: checking for $ac_word" >&5
4223 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4224 if test "${ac_cv_prog_CC+set}" = set; then
4225   echo $ECHO_N "(cached) $ECHO_C" >&6
4226 else
4227   if test -n "$CC"; then
4228   ac_cv_prog_CC="$CC" # Let the user override the test.
4229 else
4230 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4231 for as_dir in $PATH
4232 do
4233   IFS=$as_save_IFS
4234   test -z "$as_dir" && as_dir=.
4235   for ac_exec_ext in '' $ac_executable_extensions; do
4236   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4237     ac_cv_prog_CC="${ac_tool_prefix}cc"
4238     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4239     break 2
4240   fi
4241 done
4242 done
4243
4244 fi
4245 fi
4246 CC=$ac_cv_prog_CC
4247 if test -n "$CC"; then
4248   echo "$as_me:$LINENO: result: $CC" >&5
4249 echo "${ECHO_T}$CC" >&6
4250 else
4251   echo "$as_me:$LINENO: result: no" >&5
4252 echo "${ECHO_T}no" >&6
4253 fi
4254
4255 fi
4256 if test -z "$ac_cv_prog_CC"; then
4257   ac_ct_CC=$CC
4258   # Extract the first word of "cc", so it can be a program name with args.
4259 set dummy cc; ac_word=$2
4260 echo "$as_me:$LINENO: checking for $ac_word" >&5
4261 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4262 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
4263   echo $ECHO_N "(cached) $ECHO_C" >&6
4264 else
4265   if test -n "$ac_ct_CC"; then
4266   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4267 else
4268 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4269 for as_dir in $PATH
4270 do
4271   IFS=$as_save_IFS
4272   test -z "$as_dir" && as_dir=.
4273   for ac_exec_ext in '' $ac_executable_extensions; do
4274   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4275     ac_cv_prog_ac_ct_CC="cc"
4276     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4277     break 2
4278   fi
4279 done
4280 done
4281
4282 fi
4283 fi
4284 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4285 if test -n "$ac_ct_CC"; then
4286   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4287 echo "${ECHO_T}$ac_ct_CC" >&6
4288 else
4289   echo "$as_me:$LINENO: result: no" >&5
4290 echo "${ECHO_T}no" >&6
4291 fi
4292
4293   CC=$ac_ct_CC
4294 else
4295   CC="$ac_cv_prog_CC"
4296 fi
4297
4298 fi
4299 if test -z "$CC"; then
4300   # Extract the first word of "cc", so it can be a program name with args.
4301 set dummy cc; ac_word=$2
4302 echo "$as_me:$LINENO: checking for $ac_word" >&5
4303 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4304 if test "${ac_cv_prog_CC+set}" = set; then
4305   echo $ECHO_N "(cached) $ECHO_C" >&6
4306 else
4307   if test -n "$CC"; then
4308   ac_cv_prog_CC="$CC" # Let the user override the test.
4309 else
4310   ac_prog_rejected=no
4311 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4312 for as_dir in $PATH
4313 do
4314   IFS=$as_save_IFS
4315   test -z "$as_dir" && as_dir=.
4316   for ac_exec_ext in '' $ac_executable_extensions; do
4317   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4318     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4319        ac_prog_rejected=yes
4320        continue
4321      fi
4322     ac_cv_prog_CC="cc"
4323     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4324     break 2
4325   fi
4326 done
4327 done
4328
4329 if test $ac_prog_rejected = yes; then
4330   # We found a bogon in the path, so make sure we never use it.
4331   set dummy $ac_cv_prog_CC
4332   shift
4333   if test $# != 0; then
4334     # We chose a different compiler from the bogus one.
4335     # However, it has the same basename, so the bogon will be chosen
4336     # first if we set CC to just the basename; use the full file name.
4337     shift
4338     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4339   fi
4340 fi
4341 fi
4342 fi
4343 CC=$ac_cv_prog_CC
4344 if test -n "$CC"; then
4345   echo "$as_me:$LINENO: result: $CC" >&5
4346 echo "${ECHO_T}$CC" >&6
4347 else
4348   echo "$as_me:$LINENO: result: no" >&5
4349 echo "${ECHO_T}no" >&6
4350 fi
4351
4352 fi
4353 if test -z "$CC"; then
4354   if test -n "$ac_tool_prefix"; then
4355   for ac_prog in cl
4356   do
4357     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4358 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4359 echo "$as_me:$LINENO: checking for $ac_word" >&5
4360 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4361 if test "${ac_cv_prog_CC+set}" = set; then
4362   echo $ECHO_N "(cached) $ECHO_C" >&6
4363 else
4364   if test -n "$CC"; then
4365   ac_cv_prog_CC="$CC" # Let the user override the test.
4366 else
4367 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4368 for as_dir in $PATH
4369 do
4370   IFS=$as_save_IFS
4371   test -z "$as_dir" && as_dir=.
4372   for ac_exec_ext in '' $ac_executable_extensions; do
4373   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4374     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4375     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4376     break 2
4377   fi
4378 done
4379 done
4380
4381 fi
4382 fi
4383 CC=$ac_cv_prog_CC
4384 if test -n "$CC"; then
4385   echo "$as_me:$LINENO: result: $CC" >&5
4386 echo "${ECHO_T}$CC" >&6
4387 else
4388   echo "$as_me:$LINENO: result: no" >&5
4389 echo "${ECHO_T}no" >&6
4390 fi
4391
4392     test -n "$CC" && break
4393   done
4394 fi
4395 if test -z "$CC"; then
4396   ac_ct_CC=$CC
4397   for ac_prog in cl
4398 do
4399   # Extract the first word of "$ac_prog", so it can be a program name with args.
4400 set dummy $ac_prog; ac_word=$2
4401 echo "$as_me:$LINENO: checking for $ac_word" >&5
4402 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4403 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
4404   echo $ECHO_N "(cached) $ECHO_C" >&6
4405 else
4406   if test -n "$ac_ct_CC"; then
4407   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4408 else
4409 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4410 for as_dir in $PATH
4411 do
4412   IFS=$as_save_IFS
4413   test -z "$as_dir" && as_dir=.
4414   for ac_exec_ext in '' $ac_executable_extensions; do
4415   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4416     ac_cv_prog_ac_ct_CC="$ac_prog"
4417     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4418     break 2
4419   fi
4420 done
4421 done
4422
4423 fi
4424 fi
4425 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4426 if test -n "$ac_ct_CC"; then
4427   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4428 echo "${ECHO_T}$ac_ct_CC" >&6
4429 else
4430   echo "$as_me:$LINENO: result: no" >&5
4431 echo "${ECHO_T}no" >&6
4432 fi
4433
4434   test -n "$ac_ct_CC" && break
4435 done
4436
4437   CC=$ac_ct_CC
4438 fi
4439
4440 fi
4441
4442
4443 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
4444 See \`config.log' for more details." >&5
4445 echo "$as_me: error: no acceptable C compiler found in \$PATH
4446 See \`config.log' for more details." >&2;}
4447    { (exit 1); exit 1; }; }
4448
4449 # Provide some information about the compiler.
4450 echo "$as_me:$LINENO:" \
4451      "checking for C compiler version" >&5
4452 ac_compiler=`set X $ac_compile; echo $2`
4453 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
4454   (eval $ac_compiler --version </dev/null >&5) 2>&5
4455   ac_status=$?
4456   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4457   (exit $ac_status); }
4458 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
4459   (eval $ac_compiler -v </dev/null >&5) 2>&5
4460   ac_status=$?
4461   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4462   (exit $ac_status); }
4463 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
4464   (eval $ac_compiler -V </dev/null >&5) 2>&5
4465   ac_status=$?
4466   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4467   (exit $ac_status); }
4468
4469 cat >conftest.$ac_ext <<_ACEOF
4470 /* confdefs.h.  */
4471 _ACEOF
4472 cat confdefs.h >>conftest.$ac_ext
4473 cat >>conftest.$ac_ext <<_ACEOF
4474 /* end confdefs.h.  */
4475
4476 int
4477 main ()
4478 {
4479
4480   ;
4481   return 0;
4482 }
4483 _ACEOF
4484 ac_clean_files_save=$ac_clean_files
4485 ac_clean_files="$ac_clean_files a.out a.exe b.out"
4486 # Try to create an executable without -o first, disregard a.out.
4487 # It will help us diagnose broken compilers, and finding out an intuition
4488 # of exeext.
4489 echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
4490 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
4491 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4492 if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
4493   (eval $ac_link_default) 2>&5
4494   ac_status=$?
4495   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4496   (exit $ac_status); }; then
4497   # Find the output, starting from the most likely.  This scheme is
4498 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
4499 # resort.
4500
4501 # Be careful to initialize this variable, since it used to be cached.
4502 # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
4503 ac_cv_exeext=
4504 # b.out is created by i960 compilers.
4505 for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
4506 do
4507   test -f "$ac_file" || continue
4508   case $ac_file in
4509     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
4510         ;;
4511     conftest.$ac_ext )
4512         # This is the source file.
4513         ;;
4514     [ab].out )
4515         # We found the default executable, but exeext='' is most
4516         # certainly right.
4517         break;;
4518     *.* )
4519         ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4520         # FIXME: I believe we export ac_cv_exeext for Libtool,
4521         # but it would be cool to find out if it's true.  Does anybody
4522         # maintain Libtool? --akim.
4523         export ac_cv_exeext
4524         break;;
4525     * )
4526         break;;
4527   esac
4528 done
4529 else
4530   echo "$as_me: failed program was:" >&5
4531 sed 's/^/| /' conftest.$ac_ext >&5
4532
4533 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
4534 See \`config.log' for more details." >&5
4535 echo "$as_me: error: C compiler cannot create executables
4536 See \`config.log' for more details." >&2;}
4537    { (exit 77); exit 77; }; }
4538 fi
4539
4540 ac_exeext=$ac_cv_exeext
4541 echo "$as_me:$LINENO: result: $ac_file" >&5
4542 echo "${ECHO_T}$ac_file" >&6
4543
4544 # Check the compiler produces executables we can run.  If not, either
4545 # the compiler is broken, or we cross compile.
4546 echo "$as_me:$LINENO: checking whether the C compiler works" >&5
4547 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
4548 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
4549 # If not cross compiling, check that we can run a simple program.
4550 if test "$cross_compiling" != yes; then
4551   if { ac_try='./$ac_file'
4552   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4553   (eval $ac_try) 2>&5
4554   ac_status=$?
4555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4556   (exit $ac_status); }; }; then
4557     cross_compiling=no
4558   else
4559     if test "$cross_compiling" = maybe; then
4560         cross_compiling=yes
4561     else
4562         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
4563 If you meant to cross compile, use \`--host'.
4564 See \`config.log' for more details." >&5
4565 echo "$as_me: error: cannot run C compiled programs.
4566 If you meant to cross compile, use \`--host'.
4567 See \`config.log' for more details." >&2;}
4568    { (exit 1); exit 1; }; }
4569     fi
4570   fi
4571 fi
4572 echo "$as_me:$LINENO: result: yes" >&5
4573 echo "${ECHO_T}yes" >&6
4574
4575 rm -f a.out a.exe conftest$ac_cv_exeext b.out
4576 ac_clean_files=$ac_clean_files_save
4577 # Check the compiler produces executables we can run.  If not, either
4578 # the compiler is broken, or we cross compile.
4579 echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
4580 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
4581 echo "$as_me:$LINENO: result: $cross_compiling" >&5
4582 echo "${ECHO_T}$cross_compiling" >&6
4583
4584 echo "$as_me:$LINENO: checking for suffix of executables" >&5
4585 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
4586 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4587   (eval $ac_link) 2>&5
4588   ac_status=$?
4589   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4590   (exit $ac_status); }; then
4591   # If both `conftest.exe' and `conftest' are `present' (well, observable)
4592 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
4593 # work properly (i.e., refer to `conftest.exe'), while it won't with
4594 # `rm'.
4595 for ac_file in conftest.exe conftest conftest.*; do
4596   test -f "$ac_file" || continue
4597   case $ac_file in
4598     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
4599     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4600           export ac_cv_exeext
4601           break;;
4602     * ) break;;
4603   esac
4604 done
4605 else
4606   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
4607 See \`config.log' for more details." >&5
4608 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
4609 See \`config.log' for more details." >&2;}
4610    { (exit 1); exit 1; }; }
4611 fi
4612
4613 rm -f conftest$ac_cv_exeext
4614 echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
4615 echo "${ECHO_T}$ac_cv_exeext" >&6
4616
4617 rm -f conftest.$ac_ext
4618 EXEEXT=$ac_cv_exeext
4619 ac_exeext=$EXEEXT
4620 echo "$as_me:$LINENO: checking for suffix of object files" >&5
4621 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
4622 if test "${ac_cv_objext+set}" = set; then
4623   echo $ECHO_N "(cached) $ECHO_C" >&6
4624 else
4625   cat >conftest.$ac_ext <<_ACEOF
4626 /* confdefs.h.  */
4627 _ACEOF
4628 cat confdefs.h >>conftest.$ac_ext
4629 cat >>conftest.$ac_ext <<_ACEOF
4630 /* end confdefs.h.  */
4631
4632 int
4633 main ()
4634 {
4635
4636   ;
4637   return 0;
4638 }
4639 _ACEOF
4640 rm -f conftest.o conftest.obj
4641 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4642   (eval $ac_compile) 2>&5
4643   ac_status=$?
4644   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4645   (exit $ac_status); }; then
4646   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
4647   case $ac_file in
4648     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
4649     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4650        break;;
4651   esac
4652 done
4653 else
4654   echo "$as_me: failed program was:" >&5
4655 sed 's/^/| /' conftest.$ac_ext >&5
4656
4657 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
4658 See \`config.log' for more details." >&5
4659 echo "$as_me: error: cannot compute suffix of object files: cannot compile
4660 See \`config.log' for more details." >&2;}
4661    { (exit 1); exit 1; }; }
4662 fi
4663
4664 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4665 fi
4666 echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
4667 echo "${ECHO_T}$ac_cv_objext" >&6
4668 OBJEXT=$ac_cv_objext
4669 ac_objext=$OBJEXT
4670 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
4671 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
4672 if test "${ac_cv_c_compiler_gnu+set}" = set; then
4673   echo $ECHO_N "(cached) $ECHO_C" >&6
4674 else
4675   cat >conftest.$ac_ext <<_ACEOF
4676 /* confdefs.h.  */
4677 _ACEOF
4678 cat confdefs.h >>conftest.$ac_ext
4679 cat >>conftest.$ac_ext <<_ACEOF
4680 /* end confdefs.h.  */
4681
4682 int
4683 main ()
4684 {
4685 #ifndef __GNUC__
4686        choke me
4687 #endif
4688
4689   ;
4690   return 0;
4691 }
4692 _ACEOF
4693 rm -f conftest.$ac_objext
4694 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4695   (eval $ac_compile) 2>conftest.er1
4696   ac_status=$?
4697   grep -v '^ *+' conftest.er1 >conftest.err
4698   rm -f conftest.er1
4699   cat conftest.err >&5
4700   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4701   (exit $ac_status); } &&
4702          { ac_try='test -z "$ac_c_werror_flag"
4703                          || test ! -s conftest.err'
4704   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4705   (eval $ac_try) 2>&5
4706   ac_status=$?
4707   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4708   (exit $ac_status); }; } &&
4709          { ac_try='test -s conftest.$ac_objext'
4710   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4711   (eval $ac_try) 2>&5
4712   ac_status=$?
4713   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4714   (exit $ac_status); }; }; then
4715   ac_compiler_gnu=yes
4716 else
4717   echo "$as_me: failed program was:" >&5
4718 sed 's/^/| /' conftest.$ac_ext >&5
4719
4720 ac_compiler_gnu=no
4721 fi
4722 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4723 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4724
4725 fi
4726 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
4727 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
4728 GCC=`test $ac_compiler_gnu = yes && echo yes`
4729 ac_test_CFLAGS=${CFLAGS+set}
4730 ac_save_CFLAGS=$CFLAGS
4731 CFLAGS="-g"
4732 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
4733 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
4734 if test "${ac_cv_prog_cc_g+set}" = set; then
4735   echo $ECHO_N "(cached) $ECHO_C" >&6
4736 else
4737   cat >conftest.$ac_ext <<_ACEOF
4738 /* confdefs.h.  */
4739 _ACEOF
4740 cat confdefs.h >>conftest.$ac_ext
4741 cat >>conftest.$ac_ext <<_ACEOF
4742 /* end confdefs.h.  */
4743
4744 int
4745 main ()
4746 {
4747
4748   ;
4749   return 0;
4750 }
4751 _ACEOF
4752 rm -f conftest.$ac_objext
4753 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4754   (eval $ac_compile) 2>conftest.er1
4755   ac_status=$?
4756   grep -v '^ *+' conftest.er1 >conftest.err
4757   rm -f conftest.er1
4758   cat conftest.err >&5
4759   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4760   (exit $ac_status); } &&
4761          { ac_try='test -z "$ac_c_werror_flag"
4762                          || test ! -s conftest.err'
4763   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4764   (eval $ac_try) 2>&5
4765   ac_status=$?
4766   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4767   (exit $ac_status); }; } &&
4768          { ac_try='test -s conftest.$ac_objext'
4769   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4770   (eval $ac_try) 2>&5
4771   ac_status=$?
4772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4773   (exit $ac_status); }; }; then
4774   ac_cv_prog_cc_g=yes
4775 else
4776   echo "$as_me: failed program was:" >&5
4777 sed 's/^/| /' conftest.$ac_ext >&5
4778
4779 ac_cv_prog_cc_g=no
4780 fi
4781 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4782 fi
4783 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
4784 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
4785 if test "$ac_test_CFLAGS" = set; then
4786   CFLAGS=$ac_save_CFLAGS
4787 elif test $ac_cv_prog_cc_g = yes; then
4788   if test "$GCC" = yes; then
4789     CFLAGS="-g -O2"
4790   else
4791     CFLAGS="-g"
4792   fi
4793 else
4794   if test "$GCC" = yes; then
4795     CFLAGS="-O2"
4796   else
4797     CFLAGS=
4798   fi
4799 fi
4800 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
4801 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
4802 if test "${ac_cv_prog_cc_stdc+set}" = set; then
4803   echo $ECHO_N "(cached) $ECHO_C" >&6
4804 else
4805   ac_cv_prog_cc_stdc=no
4806 ac_save_CC=$CC
4807 cat >conftest.$ac_ext <<_ACEOF
4808 /* confdefs.h.  */
4809 _ACEOF
4810 cat confdefs.h >>conftest.$ac_ext
4811 cat >>conftest.$ac_ext <<_ACEOF
4812 /* end confdefs.h.  */
4813 #include <stdarg.h>
4814 #include <stdio.h>
4815 #include <sys/types.h>
4816 #include <sys/stat.h>
4817 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4818 struct buf { int x; };
4819 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4820 static char *e (p, i)
4821      char **p;
4822      int i;
4823 {
4824   return p[i];
4825 }
4826 static char *f (char * (*g) (char **, int), char **p, ...)
4827 {
4828   char *s;
4829   va_list v;
4830   va_start (v,p);
4831   s = g (p, va_arg (v,int));
4832   va_end (v);
4833   return s;
4834 }
4835
4836 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
4837    function prototypes and stuff, but not '\xHH' hex character constants.
4838    These don't provoke an error unfortunately, instead are silently treated
4839    as 'x'.  The following induces an error, until -std1 is added to get
4840    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
4841    array size at least.  It's necessary to write '\x00'==0 to get something
4842    that's true only with -std1.  */
4843 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4844
4845 int test (int i, double x);
4846 struct s1 {int (*f) (int a);};
4847 struct s2 {int (*f) (double a);};
4848 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4849 int argc;
4850 char **argv;
4851 int
4852 main ()
4853 {
4854 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4855   ;
4856   return 0;
4857 }
4858 _ACEOF
4859 # Don't try gcc -ansi; that turns off useful extensions and
4860 # breaks some systems' header files.
4861 # AIX                   -qlanglvl=ansi
4862 # Ultrix and OSF/1      -std1
4863 # HP-UX 10.20 and later -Ae
4864 # HP-UX older versions  -Aa -D_HPUX_SOURCE
4865 # SVR4                  -Xc -D__EXTENSIONS__
4866 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4867 do
4868   CC="$ac_save_CC $ac_arg"
4869   rm -f conftest.$ac_objext
4870 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4871   (eval $ac_compile) 2>conftest.er1
4872   ac_status=$?
4873   grep -v '^ *+' conftest.er1 >conftest.err
4874   rm -f conftest.er1
4875   cat conftest.err >&5
4876   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4877   (exit $ac_status); } &&
4878          { ac_try='test -z "$ac_c_werror_flag"
4879                          || test ! -s conftest.err'
4880   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4881   (eval $ac_try) 2>&5
4882   ac_status=$?
4883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4884   (exit $ac_status); }; } &&
4885          { ac_try='test -s conftest.$ac_objext'
4886   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4887   (eval $ac_try) 2>&5
4888   ac_status=$?
4889   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4890   (exit $ac_status); }; }; then
4891   ac_cv_prog_cc_stdc=$ac_arg
4892 break
4893 else
4894   echo "$as_me: failed program was:" >&5
4895 sed 's/^/| /' conftest.$ac_ext >&5
4896
4897 fi
4898 rm -f conftest.err conftest.$ac_objext
4899 done
4900 rm -f conftest.$ac_ext conftest.$ac_objext
4901 CC=$ac_save_CC
4902
4903 fi
4904
4905 case "x$ac_cv_prog_cc_stdc" in
4906   x|xno)
4907     echo "$as_me:$LINENO: result: none needed" >&5
4908 echo "${ECHO_T}none needed" >&6 ;;
4909   *)
4910     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
4911 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
4912     CC="$CC $ac_cv_prog_cc_stdc" ;;
4913 esac
4914
4915 # Some people use a C++ compiler to compile C.  Since we use `exit',
4916 # in C++ we need to declare it.  In case someone uses the same compiler
4917 # for both compiling C and C++ we need to have the C++ compiler decide
4918 # the declaration of exit, since it's the most demanding environment.
4919 cat >conftest.$ac_ext <<_ACEOF
4920 #ifndef __cplusplus
4921   choke me
4922 #endif
4923 _ACEOF
4924 rm -f conftest.$ac_objext
4925 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4926   (eval $ac_compile) 2>conftest.er1
4927   ac_status=$?
4928   grep -v '^ *+' conftest.er1 >conftest.err
4929   rm -f conftest.er1
4930   cat conftest.err >&5
4931   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4932   (exit $ac_status); } &&
4933          { ac_try='test -z "$ac_c_werror_flag"
4934                          || test ! -s conftest.err'
4935   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4936   (eval $ac_try) 2>&5
4937   ac_status=$?
4938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4939   (exit $ac_status); }; } &&
4940          { ac_try='test -s conftest.$ac_objext'
4941   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4942   (eval $ac_try) 2>&5
4943   ac_status=$?
4944   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4945   (exit $ac_status); }; }; then
4946   for ac_declaration in \
4947    '' \
4948    'extern "C" void std::exit (int) throw (); using std::exit;' \
4949    'extern "C" void std::exit (int); using std::exit;' \
4950    'extern "C" void exit (int) throw ();' \
4951    'extern "C" void exit (int);' \
4952    'void exit (int);'
4953 do
4954   cat >conftest.$ac_ext <<_ACEOF
4955 /* confdefs.h.  */
4956 _ACEOF
4957 cat confdefs.h >>conftest.$ac_ext
4958 cat >>conftest.$ac_ext <<_ACEOF
4959 /* end confdefs.h.  */
4960 $ac_declaration
4961 #include <stdlib.h>
4962 int
4963 main ()
4964 {
4965 exit (42);
4966   ;
4967   return 0;
4968 }
4969 _ACEOF
4970 rm -f conftest.$ac_objext
4971 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4972   (eval $ac_compile) 2>conftest.er1
4973   ac_status=$?
4974   grep -v '^ *+' conftest.er1 >conftest.err
4975   rm -f conftest.er1
4976   cat conftest.err >&5
4977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4978   (exit $ac_status); } &&
4979          { ac_try='test -z "$ac_c_werror_flag"
4980                          || test ! -s conftest.err'
4981   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4982   (eval $ac_try) 2>&5
4983   ac_status=$?
4984   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4985   (exit $ac_status); }; } &&
4986          { ac_try='test -s conftest.$ac_objext'
4987   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4988   (eval $ac_try) 2>&5
4989   ac_status=$?
4990   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4991   (exit $ac_status); }; }; then
4992   :
4993 else
4994   echo "$as_me: failed program was:" >&5
4995 sed 's/^/| /' conftest.$ac_ext >&5
4996
4997 continue
4998 fi
4999 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5000   cat >conftest.$ac_ext <<_ACEOF
5001 /* confdefs.h.  */
5002 _ACEOF
5003 cat confdefs.h >>conftest.$ac_ext
5004 cat >>conftest.$ac_ext <<_ACEOF
5005 /* end confdefs.h.  */
5006 $ac_declaration
5007 int
5008 main ()
5009 {
5010 exit (42);
5011   ;
5012   return 0;
5013 }
5014 _ACEOF
5015 rm -f conftest.$ac_objext
5016 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5017   (eval $ac_compile) 2>conftest.er1
5018   ac_status=$?
5019   grep -v '^ *+' conftest.er1 >conftest.err
5020   rm -f conftest.er1
5021   cat conftest.err >&5
5022   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5023   (exit $ac_status); } &&
5024          { ac_try='test -z "$ac_c_werror_flag"
5025                          || test ! -s conftest.err'
5026   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5027   (eval $ac_try) 2>&5
5028   ac_status=$?
5029   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5030   (exit $ac_status); }; } &&
5031          { ac_try='test -s conftest.$ac_objext'
5032   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5033   (eval $ac_try) 2>&5
5034   ac_status=$?
5035   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5036   (exit $ac_status); }; }; then
5037   break
5038 else
5039   echo "$as_me: failed program was:" >&5
5040 sed 's/^/| /' conftest.$ac_ext >&5
5041
5042 fi
5043 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5044 done
5045 rm -f conftest*
5046 if test -n "$ac_declaration"; then
5047   echo '#ifdef __cplusplus' >>confdefs.h
5048   echo $ac_declaration      >>confdefs.h
5049   echo '#endif'             >>confdefs.h
5050 fi
5051
5052 else
5053   echo "$as_me: failed program was:" >&5
5054 sed 's/^/| /' conftest.$ac_ext >&5
5055
5056 fi
5057 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5058 ac_ext=c
5059 ac_cpp='$CPP $CPPFLAGS'
5060 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5061 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5062 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5063
5064 depcc="$CC"   am_compiler_list=
5065
5066 echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
5067 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6
5068 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
5069   echo $ECHO_N "(cached) $ECHO_C" >&6
5070 else
5071   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5072   # We make a subdir and do the tests there.  Otherwise we can end up
5073   # making bogus files that we don't know about and never remove.  For
5074   # instance it was reported that on HP-UX the gcc test will end up
5075   # making a dummy file named `D' -- because `-MD' means `put the output
5076   # in D'.
5077   mkdir conftest.dir
5078   # Copy depcomp to subdir because otherwise we won't find it if we're
5079   # using a relative directory.
5080   cp "$am_depcomp" conftest.dir
5081   cd conftest.dir
5082   # We will build objects and dependencies in a subdirectory because
5083   # it helps to detect inapplicable dependency modes.  For instance
5084   # both Tru64's cc and ICC support -MD to output dependencies as a
5085   # side effect of compilation, but ICC will put the dependencies in
5086   # the current directory while Tru64 will put them in the object
5087   # directory.
5088   mkdir sub
5089
5090   am_cv_CC_dependencies_compiler_type=none
5091   if test "$am_compiler_list" = ""; then
5092      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5093   fi
5094   for depmode in $am_compiler_list; do
5095     # Setup a source with many dependencies, because some compilers
5096     # like to wrap large dependency lists on column 80 (with \), and
5097     # we should not choose a depcomp mode which is confused by this.
5098     #
5099     # We need to recreate these files for each test, as the compiler may
5100     # overwrite some of them when testing with obscure command lines.
5101     # This happens at least with the AIX C compiler.
5102     : > sub/conftest.c
5103     for i in 1 2 3 4 5 6; do
5104       echo '#include "conftst'$i'.h"' >> sub/conftest.c
5105       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5106       # Solaris 8's {/usr,}/bin/sh.
5107       touch sub/conftst$i.h
5108     done
5109     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5110
5111     case $depmode in
5112     nosideeffect)
5113       # after this tag, mechanisms are not by side-effect, so they'll
5114       # only be used when explicitly requested
5115       if test "x$enable_dependency_tracking" = xyes; then
5116         continue
5117       else
5118         break
5119       fi
5120       ;;
5121     none) break ;;
5122     esac
5123     # We check with `-c' and `-o' for the sake of the "dashmstdout"
5124     # mode.  It turns out that the SunPro C++ compiler does not properly
5125     # handle `-M -o', and we need to detect this.
5126     if depmode=$depmode \
5127        source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
5128        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5129        $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
5130          >/dev/null 2>conftest.err &&
5131        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5132        grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
5133        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5134       # icc doesn't choke on unknown options, it will just issue warnings
5135       # or remarks (even with -Werror).  So we grep stderr for any message
5136       # that says an option was ignored or not supported.
5137       # When given -MP, icc 7.0 and 7.1 complain thusly:
5138       #   icc: Command line warning: ignoring option '-M'; no argument required
5139       # The diagnosis changed in icc 8.0:
5140       #   icc: Command line remark: option '-MP' not supported
5141       if (grep 'ignoring option' conftest.err ||
5142           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5143         am_cv_CC_dependencies_compiler_type=$depmode
5144         break
5145       fi
5146     fi
5147   done
5148
5149   cd ..
5150   rm -rf conftest.dir
5151 else
5152   am_cv_CC_dependencies_compiler_type=none
5153 fi
5154
5155 fi
5156 echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
5157 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6
5158 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5159
5160
5161
5162 if
5163   test "x$enable_dependency_tracking" != xno \
5164   && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5165   am__fastdepCC_TRUE=
5166   am__fastdepCC_FALSE='#'
5167 else
5168   am__fastdepCC_TRUE='#'
5169   am__fastdepCC_FALSE=
5170 fi
5171
5172
5173 echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5
5174 echo $ECHO_N "checking for a sed that does not truncate output... $ECHO_C" >&6
5175 if test "${lt_cv_path_SED+set}" = set; then
5176   echo $ECHO_N "(cached) $ECHO_C" >&6
5177 else
5178   # Loop through the user's path and test for sed and gsed.
5179 # Then use that list of sed's as ones to test for truncation.
5180 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5181 for as_dir in $PATH
5182 do
5183   IFS=$as_save_IFS
5184   test -z "$as_dir" && as_dir=.
5185   for lt_ac_prog in sed gsed; do
5186     for ac_exec_ext in '' $ac_executable_extensions; do
5187       if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
5188         lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
5189       fi
5190     done
5191   done
5192 done
5193 lt_ac_max=0
5194 lt_ac_count=0
5195 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
5196 # along with /bin/sed that truncates output.
5197 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
5198   test ! -f $lt_ac_sed && continue
5199   cat /dev/null > conftest.in
5200   lt_ac_count=0
5201   echo $ECHO_N "0123456789$ECHO_C" >conftest.in
5202   # Check for GNU sed and select it if it is found.
5203   if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
5204     lt_cv_path_SED=$lt_ac_sed
5205     break
5206   fi
5207   while true; do
5208     cat conftest.in conftest.in >conftest.tmp
5209     mv conftest.tmp conftest.in
5210     cp conftest.in conftest.nl
5211     echo >>conftest.nl
5212     $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
5213     cmp -s conftest.out conftest.nl || break
5214     # 10000 chars as input seems more than enough
5215     test $lt_ac_count -gt 10 && break
5216     lt_ac_count=`expr $lt_ac_count + 1`
5217     if test $lt_ac_count -gt $lt_ac_max; then
5218       lt_ac_max=$lt_ac_count
5219       lt_cv_path_SED=$lt_ac_sed
5220     fi
5221   done
5222 done
5223
5224 fi
5225
5226 SED=$lt_cv_path_SED
5227 echo "$as_me:$LINENO: result: $SED" >&5
5228 echo "${ECHO_T}$SED" >&6
5229
5230 echo "$as_me:$LINENO: checking for egrep" >&5
5231 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
5232 if test "${ac_cv_prog_egrep+set}" = set; then
5233   echo $ECHO_N "(cached) $ECHO_C" >&6
5234 else
5235   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
5236     then ac_cv_prog_egrep='grep -E'
5237     else ac_cv_prog_egrep='egrep'
5238     fi
5239 fi
5240 echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
5241 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
5242  EGREP=$ac_cv_prog_egrep
5243
5244
5245
5246 # Check whether --with-gnu-ld or --without-gnu-ld was given.
5247 if test "${with_gnu_ld+set}" = set; then
5248   withval="$with_gnu_ld"
5249   test "$withval" = no || with_gnu_ld=yes
5250 else
5251   with_gnu_ld=no
5252 fi;
5253 ac_prog=ld
5254 if test "$GCC" = yes; then
5255   # Check if gcc -print-prog-name=ld gives a path.
5256   echo "$as_me:$LINENO: checking for ld used by $CC" >&5
5257 echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6
5258   case $host in
5259   *-*-mingw*)
5260     # gcc leaves a trailing carriage return which upsets mingw
5261     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
5262   *)
5263     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
5264   esac
5265   case $ac_prog in
5266     # Accept absolute paths.
5267     [\\/]* | ?:[\\/]*)
5268       re_direlt='/[^/][^/]*/\.\./'
5269       # Canonicalize the pathname of ld
5270       ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
5271       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
5272         ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
5273       done
5274       test -z "$LD" && LD="$ac_prog"
5275       ;;
5276   "")
5277     # If it fails, then pretend we aren't using GCC.
5278     ac_prog=ld
5279     ;;
5280   *)
5281     # If it is relative, then search for the first ld in PATH.
5282     with_gnu_ld=unknown
5283     ;;
5284   esac
5285 elif test "$with_gnu_ld" = yes; then
5286   echo "$as_me:$LINENO: checking for GNU ld" >&5
5287 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
5288 else
5289   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
5290 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
5291 fi
5292 if test "${lt_cv_path_LD+set}" = set; then
5293   echo $ECHO_N "(cached) $ECHO_C" >&6
5294 else
5295   if test -z "$LD"; then
5296   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
5297   for ac_dir in $PATH; do
5298     IFS="$lt_save_ifs"
5299     test -z "$ac_dir" && ac_dir=.
5300     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
5301       lt_cv_path_LD="$ac_dir/$ac_prog"
5302       # Check to see if the program is GNU ld.  I'd rather use --version,
5303       # but apparently some variants of GNU ld only accept -v.
5304       # Break only if it was the GNU/non-GNU ld that we prefer.
5305       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
5306       *GNU* | *'with BFD'*)
5307         test "$with_gnu_ld" != no && break
5308         ;;
5309       *)
5310         test "$with_gnu_ld" != yes && break
5311         ;;
5312       esac
5313     fi
5314   done
5315   IFS="$lt_save_ifs"
5316 else
5317   lt_cv_path_LD="$LD" # Let the user override the test with a path.
5318 fi
5319 fi
5320
5321 LD="$lt_cv_path_LD"
5322 if test -n "$LD"; then
5323   echo "$as_me:$LINENO: result: $LD" >&5
5324 echo "${ECHO_T}$LD" >&6
5325 else
5326   echo "$as_me:$LINENO: result: no" >&5
5327 echo "${ECHO_T}no" >&6
5328 fi
5329 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
5330 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
5331    { (exit 1); exit 1; }; }
5332 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
5333 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
5334 if test "${lt_cv_prog_gnu_ld+set}" = set; then
5335   echo $ECHO_N "(cached) $ECHO_C" >&6
5336 else
5337   # I'd rather use --version here, but apparently some GNU lds only accept -v.
5338 case `$LD -v 2>&1 </dev/null` in
5339 *GNU* | *'with BFD'*)
5340   lt_cv_prog_gnu_ld=yes
5341   ;;
5342 *)
5343   lt_cv_prog_gnu_ld=no
5344   ;;
5345 esac
5346 fi
5347 echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
5348 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6
5349 with_gnu_ld=$lt_cv_prog_gnu_ld
5350
5351
5352 echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5
5353 echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6
5354 if test "${lt_cv_ld_reload_flag+set}" = set; then
5355   echo $ECHO_N "(cached) $ECHO_C" >&6
5356 else
5357   lt_cv_ld_reload_flag='-r'
5358 fi
5359 echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5
5360 echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6
5361 reload_flag=$lt_cv_ld_reload_flag
5362 case $reload_flag in
5363 "" | " "*) ;;
5364 *) reload_flag=" $reload_flag" ;;
5365 esac
5366 reload_cmds='$LD$reload_flag -o $output$reload_objs'
5367 case $host_os in
5368   darwin*)
5369     if test "$GCC" = yes; then
5370       reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs'
5371     else
5372       reload_cmds='$LD$reload_flag -o $output$reload_objs'
5373     fi
5374     ;;
5375 esac
5376
5377 echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
5378 echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6
5379 if test "${lt_cv_path_NM+set}" = set; then
5380   echo $ECHO_N "(cached) $ECHO_C" >&6
5381 else
5382   if test -n "$NM"; then
5383   # Let the user override the test.
5384   lt_cv_path_NM="$NM"
5385 else
5386   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
5387   for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
5388     IFS="$lt_save_ifs"
5389     test -z "$ac_dir" && ac_dir=.
5390     tmp_nm="$ac_dir/${ac_tool_prefix}nm"
5391     if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
5392       # Check to see if the nm accepts a BSD-compat flag.
5393       # Adding the `sed 1q' prevents false positives on HP-UX, which says:
5394       #   nm: unknown option "B" ignored
5395       # Tru64's nm complains that /dev/null is an invalid object file
5396       case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
5397       */dev/null* | *'Invalid file or object type'*)
5398         lt_cv_path_NM="$tmp_nm -B"
5399         break
5400         ;;
5401       *)
5402         case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
5403         */dev/null*)
5404           lt_cv_path_NM="$tmp_nm -p"
5405           break
5406           ;;
5407         *)
5408           lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
5409           continue # so that we can try to find one that supports BSD flags
5410           ;;
5411         esac
5412       esac
5413     fi
5414   done
5415   IFS="$lt_save_ifs"
5416   test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
5417 fi
5418 fi
5419 echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5
5420 echo "${ECHO_T}$lt_cv_path_NM" >&6
5421 NM="$lt_cv_path_NM"
5422
5423 echo "$as_me:$LINENO: checking whether ln -s works" >&5
5424 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
5425 LN_S=$as_ln_s
5426 if test "$LN_S" = "ln -s"; then
5427   echo "$as_me:$LINENO: result: yes" >&5
5428 echo "${ECHO_T}yes" >&6
5429 else
5430   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
5431 echo "${ECHO_T}no, using $LN_S" >&6
5432 fi
5433
5434 echo "$as_me:$LINENO: checking how to recognise dependent libraries" >&5
5435 echo $ECHO_N "checking how to recognise dependent libraries... $ECHO_C" >&6
5436 if test "${lt_cv_deplibs_check_method+set}" = set; then
5437   echo $ECHO_N "(cached) $ECHO_C" >&6
5438 else
5439   lt_cv_file_magic_cmd='$MAGIC_CMD'
5440 lt_cv_file_magic_test_file=
5441 lt_cv_deplibs_check_method='unknown'
5442 # Need to set the preceding variable on all platforms that support
5443 # interlibrary dependencies.
5444 # 'none' -- dependencies not supported.
5445 # `unknown' -- same as none, but documents that we really don't know.
5446 # 'pass_all' -- all dependencies passed with no checks.
5447 # 'test_compile' -- check by making test program.
5448 # 'file_magic [[regex]]' -- check by looking for files in library path
5449 # which responds to the $file_magic_cmd with a given extended regex.
5450 # If you have `file' or equivalent on your system and you're not sure
5451 # whether `pass_all' will *always* work, you probably want this one.
5452
5453 case $host_os in
5454 aix4* | aix5*)
5455   lt_cv_deplibs_check_method=pass_all
5456   ;;
5457
5458 beos*)
5459   lt_cv_deplibs_check_method=pass_all
5460   ;;
5461
5462 bsdi[45]*)
5463   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
5464   lt_cv_file_magic_cmd='/usr/bin/file -L'
5465   lt_cv_file_magic_test_file=/shlib/libc.so
5466   ;;
5467
5468 cygwin*)
5469   # func_win32_libid is a shell function defined in ltmain.sh
5470   lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
5471   lt_cv_file_magic_cmd='func_win32_libid'
5472   ;;
5473
5474 mingw* | pw32*)
5475   # Base MSYS/MinGW do not provide the 'file' command needed by
5476   # func_win32_libid shell function, so use a weaker test based on 'objdump'.
5477   lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
5478   lt_cv_file_magic_cmd='$OBJDUMP -f'
5479   ;;
5480
5481 darwin* | rhapsody*)
5482   lt_cv_deplibs_check_method=pass_all
5483   ;;
5484
5485 freebsd* | kfreebsd*-gnu | dragonfly*)
5486   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
5487     case $host_cpu in
5488     i*86 )
5489       # Not sure whether the presence of OpenBSD here was a mistake.
5490       # Let's accept both of them until this is cleared up.
5491       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
5492       lt_cv_file_magic_cmd=/usr/bin/file
5493       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
5494       ;;
5495     esac
5496   else
5497     lt_cv_deplibs_check_method=pass_all
5498   fi
5499   ;;
5500
5501 gnu*)
5502   lt_cv_deplibs_check_method=pass_all
5503   ;;
5504
5505 hpux10.20* | hpux11*)
5506   lt_cv_file_magic_cmd=/usr/bin/file
5507   case $host_cpu in
5508   ia64*)
5509     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
5510     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
5511     ;;
5512   hppa*64*)
5513     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]'
5514     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
5515     ;;
5516   *)
5517     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
5518     lt_cv_file_magic_test_file=/usr/lib/libc.sl
5519     ;;
5520   esac
5521   ;;
5522
5523 irix5* | irix6* | nonstopux*)
5524   case $LD in
5525   *-32|*"-32 ") libmagic=32-bit;;
5526   *-n32|*"-n32 ") libmagic=N32;;
5527   *-64|*"-64 ") libmagic=64-bit;;
5528   *) libmagic=never-match;;
5529   esac
5530   lt_cv_deplibs_check_method=pass_all
5531   ;;
5532
5533 # This must be Linux ELF.
5534 linux*)
5535   lt_cv_deplibs_check_method=pass_all
5536   ;;
5537
5538 netbsd*)
5539   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
5540     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5541   else
5542     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
5543   fi
5544   ;;
5545
5546 newos6*)
5547   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
5548   lt_cv_file_magic_cmd=/usr/bin/file
5549   lt_cv_file_magic_test_file=/usr/lib/libnls.so
5550   ;;
5551
5552 nto-qnx*)
5553   lt_cv_deplibs_check_method=unknown
5554   ;;
5555
5556 openbsd*)
5557   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5558     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
5559   else
5560     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5561   fi
5562   ;;
5563
5564 osf3* | osf4* | osf5*)
5565   lt_cv_deplibs_check_method=pass_all
5566   ;;
5567
5568 sco3.2v5*)
5569   lt_cv_deplibs_check_method=pass_all
5570   ;;
5571
5572 solaris*)
5573   lt_cv_deplibs_check_method=pass_all
5574   ;;
5575
5576 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5577   case $host_vendor in
5578   motorola)
5579     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]'
5580     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
5581     ;;
5582   ncr)
5583     lt_cv_deplibs_check_method=pass_all
5584     ;;
5585   sequent)
5586     lt_cv_file_magic_cmd='/bin/file'
5587     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
5588     ;;
5589   sni)
5590     lt_cv_file_magic_cmd='/bin/file'
5591     lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
5592     lt_cv_file_magic_test_file=/lib/libc.so
5593     ;;
5594   siemens)
5595     lt_cv_deplibs_check_method=pass_all
5596     ;;
5597   esac
5598   ;;
5599
5600 sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7* | sysv4*uw2*)
5601   lt_cv_deplibs_check_method=pass_all
5602   ;;
5603 esac
5604
5605 fi
5606 echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5
5607 echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6
5608 file_magic_cmd=$lt_cv_file_magic_cmd
5609 deplibs_check_method=$lt_cv_deplibs_check_method
5610 test -z "$deplibs_check_method" && deplibs_check_method=unknown
5611
5612
5613
5614
5615 # If no C compiler was specified, use CC.
5616 LTCC=${LTCC-"$CC"}
5617
5618 # Allow CC to be a program name with arguments.
5619 compiler=$CC
5620
5621
5622 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
5623 if test "${enable_libtool_lock+set}" = set; then
5624   enableval="$enable_libtool_lock"
5625
5626 fi;
5627 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
5628
5629 # Some flags need to be propagated to the compiler or linker for good
5630 # libtool support.
5631 case $host in
5632 ia64-*-hpux*)
5633   # Find out which ABI we are using.
5634   echo 'int i;' > conftest.$ac_ext
5635   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5636   (eval $ac_compile) 2>&5
5637   ac_status=$?
5638   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5639   (exit $ac_status); }; then
5640     case `/usr/bin/file conftest.$ac_objext` in
5641     *ELF-32*)
5642       HPUX_IA64_MODE="32"
5643       ;;
5644     *ELF-64*)
5645       HPUX_IA64_MODE="64"
5646       ;;
5647     esac
5648   fi
5649   rm -rf conftest*
5650   ;;
5651 *-*-irix6*)
5652   # Find out which ABI we are using.
5653   echo '#line 5653 "configure"' > conftest.$ac_ext
5654   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5655   (eval $ac_compile) 2>&5
5656   ac_status=$?
5657   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5658   (exit $ac_status); }; then
5659    if test "$lt_cv_prog_gnu_ld" = yes; then
5660     case `/usr/bin/file conftest.$ac_objext` in
5661     *32-bit*)
5662       LD="${LD-ld} -melf32bsmip"
5663       ;;
5664     *N32*)
5665       LD="${LD-ld} -melf32bmipn32"
5666       ;;
5667     *64-bit*)
5668       LD="${LD-ld} -melf64bmip"
5669       ;;
5670     esac
5671    else
5672     case `/usr/bin/file conftest.$ac_objext` in
5673     *32-bit*)
5674       LD="${LD-ld} -32"
5675       ;;
5676     *N32*)
5677       LD="${LD-ld} -n32"
5678       ;;
5679     *64-bit*)
5680       LD="${LD-ld} -64"
5681       ;;
5682     esac
5683    fi
5684   fi
5685   rm -rf conftest*
5686   ;;
5687
5688 x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
5689   # Find out which ABI we are using.
5690   echo 'int i;' > conftest.$ac_ext
5691   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5692   (eval $ac_compile) 2>&5
5693   ac_status=$?
5694   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5695   (exit $ac_status); }; then
5696     case `/usr/bin/file conftest.o` in
5697     *32-bit*)
5698       case $host in
5699         x86_64-*linux*)
5700           LD="${LD-ld} -m elf_i386"
5701           ;;
5702         ppc64-*linux*|powerpc64-*linux*)
5703           LD="${LD-ld} -m elf32ppclinux"
5704           ;;
5705         s390x-*linux*)
5706           LD="${LD-ld} -m elf_s390"
5707           ;;
5708         sparc64-*linux*)
5709           LD="${LD-ld} -m elf32_sparc"
5710           ;;
5711       esac
5712       ;;
5713     *64-bit*)
5714       case $host in
5715         x86_64-*linux*)
5716           LD="${LD-ld} -m elf_x86_64"
5717           ;;
5718         ppc*-*linux*|powerpc*-*linux*)
5719           LD="${LD-ld} -m elf64ppc"
5720           ;;
5721         s390*-*linux*)
5722           LD="${LD-ld} -m elf64_s390"
5723           ;;
5724         sparc*-*linux*)
5725           LD="${LD-ld} -m elf64_sparc"
5726           ;;
5727       esac
5728       ;;
5729     esac
5730   fi
5731   rm -rf conftest*
5732   ;;
5733
5734 *-*-sco3.2v5*)
5735   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
5736   SAVE_CFLAGS="$CFLAGS"
5737   CFLAGS="$CFLAGS -belf"
5738   echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5
5739 echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6
5740 if test "${lt_cv_cc_needs_belf+set}" = set; then
5741   echo $ECHO_N "(cached) $ECHO_C" >&6
5742 else
5743   ac_ext=c
5744 ac_cpp='$CPP $CPPFLAGS'
5745 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5746 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5747 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5748
5749      cat >conftest.$ac_ext <<_ACEOF
5750 /* confdefs.h.  */
5751 _ACEOF
5752 cat confdefs.h >>conftest.$ac_ext
5753 cat >>conftest.$ac_ext <<_ACEOF
5754 /* end confdefs.h.  */
5755
5756 int
5757 main ()
5758 {
5759
5760   ;
5761   return 0;
5762 }
5763 _ACEOF
5764 rm -f conftest.$ac_objext conftest$ac_exeext
5765 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5766   (eval $ac_link) 2>conftest.er1
5767   ac_status=$?
5768   grep -v '^ *+' conftest.er1 >conftest.err
5769   rm -f conftest.er1
5770   cat conftest.err >&5
5771   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5772   (exit $ac_status); } &&
5773          { ac_try='test -z "$ac_c_werror_flag"
5774                          || test ! -s conftest.err'
5775   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5776   (eval $ac_try) 2>&5
5777   ac_status=$?
5778   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5779   (exit $ac_status); }; } &&
5780          { ac_try='test -s conftest$ac_exeext'
5781   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5782   (eval $ac_try) 2>&5
5783   ac_status=$?
5784   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5785   (exit $ac_status); }; }; then
5786   lt_cv_cc_needs_belf=yes
5787 else
5788   echo "$as_me: failed program was:" >&5
5789 sed 's/^/| /' conftest.$ac_ext >&5
5790
5791 lt_cv_cc_needs_belf=no
5792 fi
5793 rm -f conftest.err conftest.$ac_objext \
5794       conftest$ac_exeext conftest.$ac_ext
5795      ac_ext=c
5796 ac_cpp='$CPP $CPPFLAGS'
5797 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5798 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5799 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5800
5801 fi
5802 echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5
5803 echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6
5804   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
5805     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
5806     CFLAGS="$SAVE_CFLAGS"
5807   fi
5808   ;;
5809 *-*-cygwin* | *-*-mingw* | *-*-pw32*)
5810   if test -n "$ac_tool_prefix"; then
5811   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
5812 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
5813 echo "$as_me:$LINENO: checking for $ac_word" >&5
5814 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5815 if test "${ac_cv_prog_DLLTOOL+set}" = set; then
5816   echo $ECHO_N "(cached) $ECHO_C" >&6
5817 else
5818   if test -n "$DLLTOOL"; then
5819   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
5820 else
5821 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5822 for as_dir in $PATH
5823 do
5824   IFS=$as_save_IFS
5825   test -z "$as_dir" && as_dir=.
5826   for ac_exec_ext in '' $ac_executable_extensions; do
5827   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5828     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
5829     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5830     break 2
5831   fi
5832 done
5833 done
5834
5835 fi
5836 fi
5837 DLLTOOL=$ac_cv_prog_DLLTOOL
5838 if test -n "$DLLTOOL"; then
5839   echo "$as_me:$LINENO: result: $DLLTOOL" >&5
5840 echo "${ECHO_T}$DLLTOOL" >&6
5841 else
5842   echo "$as_me:$LINENO: result: no" >&5
5843 echo "${ECHO_T}no" >&6
5844 fi
5845
5846 fi
5847 if test -z "$ac_cv_prog_DLLTOOL"; then
5848   ac_ct_DLLTOOL=$DLLTOOL
5849   # Extract the first word of "dlltool", so it can be a program name with args.
5850 set dummy dlltool; ac_word=$2
5851 echo "$as_me:$LINENO: checking for $ac_word" >&5
5852 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5853 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
5854   echo $ECHO_N "(cached) $ECHO_C" >&6
5855 else
5856   if test -n "$ac_ct_DLLTOOL"; then
5857   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
5858 else
5859 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5860 for as_dir in $PATH
5861 do
5862   IFS=$as_save_IFS
5863   test -z "$as_dir" && as_dir=.
5864   for ac_exec_ext in '' $ac_executable_extensions; do
5865   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5866     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
5867     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5868     break 2
5869   fi
5870 done
5871 done
5872
5873   test -z "$ac_cv_prog_ac_ct_DLLTOOL" && ac_cv_prog_ac_ct_DLLTOOL="false"
5874 fi
5875 fi
5876 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
5877 if test -n "$ac_ct_DLLTOOL"; then
5878   echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
5879 echo "${ECHO_T}$ac_ct_DLLTOOL" >&6
5880 else
5881   echo "$as_me:$LINENO: result: no" >&5
5882 echo "${ECHO_T}no" >&6
5883 fi
5884
5885   DLLTOOL=$ac_ct_DLLTOOL
5886 else
5887   DLLTOOL="$ac_cv_prog_DLLTOOL"
5888 fi
5889
5890   if test -n "$ac_tool_prefix"; then
5891   # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
5892 set dummy ${ac_tool_prefix}as; ac_word=$2
5893 echo "$as_me:$LINENO: checking for $ac_word" >&5
5894 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5895 if test "${ac_cv_prog_AS+set}" = set; then
5896   echo $ECHO_N "(cached) $ECHO_C" >&6
5897 else
5898   if test -n "$AS"; then
5899   ac_cv_prog_AS="$AS" # Let the user override the test.
5900 else
5901 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5902 for as_dir in $PATH
5903 do
5904   IFS=$as_save_IFS
5905   test -z "$as_dir" && as_dir=.
5906   for ac_exec_ext in '' $ac_executable_extensions; do
5907   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5908     ac_cv_prog_AS="${ac_tool_prefix}as"
5909     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5910     break 2
5911   fi
5912 done
5913 done
5914
5915 fi
5916 fi
5917 AS=$ac_cv_prog_AS
5918 if test -n "$AS"; then
5919   echo "$as_me:$LINENO: result: $AS" >&5
5920 echo "${ECHO_T}$AS" >&6
5921 else
5922   echo "$as_me:$LINENO: result: no" >&5
5923 echo "${ECHO_T}no" >&6
5924 fi
5925
5926 fi
5927 if test -z "$ac_cv_prog_AS"; then
5928   ac_ct_AS=$AS
5929   # Extract the first word of "as", so it can be a program name with args.
5930 set dummy as; ac_word=$2
5931 echo "$as_me:$LINENO: checking for $ac_word" >&5
5932 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5933 if test "${ac_cv_prog_ac_ct_AS+set}" = set; then
5934   echo $ECHO_N "(cached) $ECHO_C" >&6
5935 else
5936   if test -n "$ac_ct_AS"; then
5937   ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test.
5938 else
5939 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5940 for as_dir in $PATH
5941 do
5942   IFS=$as_save_IFS
5943   test -z "$as_dir" && as_dir=.
5944   for ac_exec_ext in '' $ac_executable_extensions; do
5945   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5946     ac_cv_prog_ac_ct_AS="as"
5947     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5948     break 2
5949   fi
5950 done
5951 done
5952
5953   test -z "$ac_cv_prog_ac_ct_AS" && ac_cv_prog_ac_ct_AS="false"
5954 fi
5955 fi
5956 ac_ct_AS=$ac_cv_prog_ac_ct_AS
5957 if test -n "$ac_ct_AS"; then
5958   echo "$as_me:$LINENO: result: $ac_ct_AS" >&5
5959 echo "${ECHO_T}$ac_ct_AS" >&6
5960 else
5961   echo "$as_me:$LINENO: result: no" >&5
5962 echo "${ECHO_T}no" >&6
5963 fi
5964
5965   AS=$ac_ct_AS
5966 else
5967   AS="$ac_cv_prog_AS"
5968 fi
5969
5970   if test -n "$ac_tool_prefix"; then
5971   # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
5972 set dummy ${ac_tool_prefix}objdump; ac_word=$2
5973 echo "$as_me:$LINENO: checking for $ac_word" >&5
5974 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
5975 if test "${ac_cv_prog_OBJDUMP+set}" = set; then
5976   echo $ECHO_N "(cached) $ECHO_C" >&6
5977 else
5978   if test -n "$OBJDUMP"; then
5979   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
5980 else
5981 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5982 for as_dir in $PATH
5983 do
5984   IFS=$as_save_IFS
5985   test -z "$as_dir" && as_dir=.
5986   for ac_exec_ext in '' $ac_executable_extensions; do
5987   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5988     ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
5989     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5990     break 2
5991   fi
5992 done
5993 done
5994
5995 fi
5996 fi
5997 OBJDUMP=$ac_cv_prog_OBJDUMP
5998 if test -n "$OBJDUMP"; then
5999   echo "$as_me:$LINENO: result: $OBJDUMP" >&5
6000 echo "${ECHO_T}$OBJDUMP" >&6
6001 else
6002   echo "$as_me:$LINENO: result: no" >&5
6003 echo "${ECHO_T}no" >&6
6004 fi
6005
6006 fi
6007 if test -z "$ac_cv_prog_OBJDUMP"; then
6008   ac_ct_OBJDUMP=$OBJDUMP
6009   # Extract the first word of "objdump", so it can be a program name with args.
6010 set dummy objdump; ac_word=$2
6011 echo "$as_me:$LINENO: checking for $ac_word" >&5
6012 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6013 if test "${ac_cv_prog_ac_ct_OBJDUMP+set}" = set; then
6014   echo $ECHO_N "(cached) $ECHO_C" >&6
6015 else
6016   if test -n "$ac_ct_OBJDUMP"; then
6017   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
6018 else
6019 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6020 for as_dir in $PATH
6021 do
6022   IFS=$as_save_IFS
6023   test -z "$as_dir" && as_dir=.
6024   for ac_exec_ext in '' $ac_executable_extensions; do
6025   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6026     ac_cv_prog_ac_ct_OBJDUMP="objdump"
6027     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6028     break 2
6029   fi
6030 done
6031 done
6032
6033   test -z "$ac_cv_prog_ac_ct_OBJDUMP" && ac_cv_prog_ac_ct_OBJDUMP="false"
6034 fi
6035 fi
6036 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
6037 if test -n "$ac_ct_OBJDUMP"; then
6038   echo "$as_me:$LINENO: result: $ac_ct_OBJDUMP" >&5
6039 echo "${ECHO_T}$ac_ct_OBJDUMP" >&6
6040 else
6041   echo "$as_me:$LINENO: result: no" >&5
6042 echo "${ECHO_T}no" >&6
6043 fi
6044
6045   OBJDUMP=$ac_ct_OBJDUMP
6046 else
6047   OBJDUMP="$ac_cv_prog_OBJDUMP"
6048 fi
6049
6050   ;;
6051
6052 esac
6053
6054 need_locks="$enable_libtool_lock"
6055
6056
6057 ac_ext=c
6058 ac_cpp='$CPP $CPPFLAGS'
6059 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6060 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6061 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6062 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
6063 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
6064 # On Suns, sometimes $CPP names a directory.
6065 if test -n "$CPP" && test -d "$CPP"; then
6066   CPP=
6067 fi
6068 if test -z "$CPP"; then
6069   if test "${ac_cv_prog_CPP+set}" = set; then
6070   echo $ECHO_N "(cached) $ECHO_C" >&6
6071 else
6072       # Double quotes because CPP needs to be expanded
6073     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6074     do
6075       ac_preproc_ok=false
6076 for ac_c_preproc_warn_flag in '' yes
6077 do
6078   # Use a header file that comes with gcc, so configuring glibc
6079   # with a fresh cross-compiler works.
6080   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6081   # <limits.h> exists even on freestanding compilers.
6082   # On the NeXT, cc -E runs the code through the compiler's parser,
6083   # not just through cpp. "Syntax error" is here to catch this case.
6084   cat >conftest.$ac_ext <<_ACEOF
6085 /* confdefs.h.  */
6086 _ACEOF
6087 cat confdefs.h >>conftest.$ac_ext
6088 cat >>conftest.$ac_ext <<_ACEOF
6089 /* end confdefs.h.  */
6090 #ifdef __STDC__
6091 # include <limits.h>
6092 #else
6093 # include <assert.h>
6094 #endif
6095                      Syntax error
6096 _ACEOF
6097 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6098   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6099   ac_status=$?
6100   grep -v '^ *+' conftest.er1 >conftest.err
6101   rm -f conftest.er1
6102   cat conftest.err >&5
6103   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6104   (exit $ac_status); } >/dev/null; then
6105   if test -s conftest.err; then
6106     ac_cpp_err=$ac_c_preproc_warn_flag
6107     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6108   else
6109     ac_cpp_err=
6110   fi
6111 else
6112   ac_cpp_err=yes
6113 fi
6114 if test -z "$ac_cpp_err"; then
6115   :
6116 else
6117   echo "$as_me: failed program was:" >&5
6118 sed 's/^/| /' conftest.$ac_ext >&5
6119
6120   # Broken: fails on valid input.
6121 continue
6122 fi
6123 rm -f conftest.err conftest.$ac_ext
6124
6125   # OK, works on sane cases.  Now check whether non-existent headers
6126   # can be detected and how.
6127   cat >conftest.$ac_ext <<_ACEOF
6128 /* confdefs.h.  */
6129 _ACEOF
6130 cat confdefs.h >>conftest.$ac_ext
6131 cat >>conftest.$ac_ext <<_ACEOF
6132 /* end confdefs.h.  */
6133 #include <ac_nonexistent.h>
6134 _ACEOF
6135 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6136   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6137   ac_status=$?
6138   grep -v '^ *+' conftest.er1 >conftest.err
6139   rm -f conftest.er1
6140   cat conftest.err >&5
6141   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6142   (exit $ac_status); } >/dev/null; then
6143   if test -s conftest.err; then
6144     ac_cpp_err=$ac_c_preproc_warn_flag
6145     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6146   else
6147     ac_cpp_err=
6148   fi
6149 else
6150   ac_cpp_err=yes
6151 fi
6152 if test -z "$ac_cpp_err"; then
6153   # Broken: success on invalid input.
6154 continue
6155 else
6156   echo "$as_me: failed program was:" >&5
6157 sed 's/^/| /' conftest.$ac_ext >&5
6158
6159   # Passes both tests.
6160 ac_preproc_ok=:
6161 break
6162 fi
6163 rm -f conftest.err conftest.$ac_ext
6164
6165 done
6166 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6167 rm -f conftest.err conftest.$ac_ext
6168 if $ac_preproc_ok; then
6169   break
6170 fi
6171
6172     done
6173     ac_cv_prog_CPP=$CPP
6174
6175 fi
6176   CPP=$ac_cv_prog_CPP
6177 else
6178   ac_cv_prog_CPP=$CPP
6179 fi
6180 echo "$as_me:$LINENO: result: $CPP" >&5
6181 echo "${ECHO_T}$CPP" >&6
6182 ac_preproc_ok=false
6183 for ac_c_preproc_warn_flag in '' yes
6184 do
6185   # Use a header file that comes with gcc, so configuring glibc
6186   # with a fresh cross-compiler works.
6187   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6188   # <limits.h> exists even on freestanding compilers.
6189   # On the NeXT, cc -E runs the code through the compiler's parser,
6190   # not just through cpp. "Syntax error" is here to catch this case.
6191   cat >conftest.$ac_ext <<_ACEOF
6192 /* confdefs.h.  */
6193 _ACEOF
6194 cat confdefs.h >>conftest.$ac_ext
6195 cat >>conftest.$ac_ext <<_ACEOF
6196 /* end confdefs.h.  */
6197 #ifdef __STDC__
6198 # include <limits.h>
6199 #else
6200 # include <assert.h>
6201 #endif
6202                      Syntax error
6203 _ACEOF
6204 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6205   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6206   ac_status=$?
6207   grep -v '^ *+' conftest.er1 >conftest.err
6208   rm -f conftest.er1
6209   cat conftest.err >&5
6210   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6211   (exit $ac_status); } >/dev/null; then
6212   if test -s conftest.err; then
6213     ac_cpp_err=$ac_c_preproc_warn_flag
6214     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6215   else
6216     ac_cpp_err=
6217   fi
6218 else
6219   ac_cpp_err=yes
6220 fi
6221 if test -z "$ac_cpp_err"; then
6222   :
6223 else
6224   echo "$as_me: failed program was:" >&5
6225 sed 's/^/| /' conftest.$ac_ext >&5
6226
6227   # Broken: fails on valid input.
6228 continue
6229 fi
6230 rm -f conftest.err conftest.$ac_ext
6231
6232   # OK, works on sane cases.  Now check whether non-existent headers
6233   # can be detected and how.
6234   cat >conftest.$ac_ext <<_ACEOF
6235 /* confdefs.h.  */
6236 _ACEOF
6237 cat confdefs.h >>conftest.$ac_ext
6238 cat >>conftest.$ac_ext <<_ACEOF
6239 /* end confdefs.h.  */
6240 #include <ac_nonexistent.h>
6241 _ACEOF
6242 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6243   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6244   ac_status=$?
6245   grep -v '^ *+' conftest.er1 >conftest.err
6246   rm -f conftest.er1
6247   cat conftest.err >&5
6248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6249   (exit $ac_status); } >/dev/null; then
6250   if test -s conftest.err; then
6251     ac_cpp_err=$ac_c_preproc_warn_flag
6252     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6253   else
6254     ac_cpp_err=
6255   fi
6256 else
6257   ac_cpp_err=yes
6258 fi
6259 if test -z "$ac_cpp_err"; then
6260   # Broken: success on invalid input.
6261 continue
6262 else
6263   echo "$as_me: failed program was:" >&5
6264 sed 's/^/| /' conftest.$ac_ext >&5
6265
6266   # Passes both tests.
6267 ac_preproc_ok=:
6268 break
6269 fi
6270 rm -f conftest.err conftest.$ac_ext
6271
6272 done
6273 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6274 rm -f conftest.err conftest.$ac_ext
6275 if $ac_preproc_ok; then
6276   :
6277 else
6278   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
6279 See \`config.log' for more details." >&5
6280 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
6281 See \`config.log' for more details." >&2;}
6282    { (exit 1); exit 1; }; }
6283 fi
6284
6285 ac_ext=c
6286 ac_cpp='$CPP $CPPFLAGS'
6287 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6288 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6289 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6290
6291
6292 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
6293 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
6294 if test "${ac_cv_header_stdc+set}" = set; then
6295   echo $ECHO_N "(cached) $ECHO_C" >&6
6296 else
6297   cat >conftest.$ac_ext <<_ACEOF
6298 /* confdefs.h.  */
6299 _ACEOF
6300 cat confdefs.h >>conftest.$ac_ext
6301 cat >>conftest.$ac_ext <<_ACEOF
6302 /* end confdefs.h.  */
6303 #include <stdlib.h>
6304 #include <stdarg.h>
6305 #include <string.h>
6306 #include <float.h>
6307
6308 int
6309 main ()
6310 {
6311
6312   ;
6313   return 0;
6314 }
6315 _ACEOF
6316 rm -f conftest.$ac_objext
6317 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6318   (eval $ac_compile) 2>conftest.er1
6319   ac_status=$?
6320   grep -v '^ *+' conftest.er1 >conftest.err
6321   rm -f conftest.er1
6322   cat conftest.err >&5
6323   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6324   (exit $ac_status); } &&
6325          { ac_try='test -z "$ac_c_werror_flag"
6326                          || test ! -s conftest.err'
6327   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6328   (eval $ac_try) 2>&5
6329   ac_status=$?
6330   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6331   (exit $ac_status); }; } &&
6332          { ac_try='test -s conftest.$ac_objext'
6333   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6334   (eval $ac_try) 2>&5
6335   ac_status=$?
6336   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6337   (exit $ac_status); }; }; then
6338   ac_cv_header_stdc=yes
6339 else
6340   echo "$as_me: failed program was:" >&5
6341 sed 's/^/| /' conftest.$ac_ext >&5
6342
6343 ac_cv_header_stdc=no
6344 fi
6345 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6346
6347 if test $ac_cv_header_stdc = yes; then
6348   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6349   cat >conftest.$ac_ext <<_ACEOF
6350 /* confdefs.h.  */
6351 _ACEOF
6352 cat confdefs.h >>conftest.$ac_ext
6353 cat >>conftest.$ac_ext <<_ACEOF
6354 /* end confdefs.h.  */
6355 #include <string.h>
6356
6357 _ACEOF
6358 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6359   $EGREP "memchr" >/dev/null 2>&1; then
6360   :
6361 else
6362   ac_cv_header_stdc=no
6363 fi
6364 rm -f conftest*
6365
6366 fi
6367
6368 if test $ac_cv_header_stdc = yes; then
6369   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6370   cat >conftest.$ac_ext <<_ACEOF
6371 /* confdefs.h.  */
6372 _ACEOF
6373 cat confdefs.h >>conftest.$ac_ext
6374 cat >>conftest.$ac_ext <<_ACEOF
6375 /* end confdefs.h.  */
6376 #include <stdlib.h>
6377
6378 _ACEOF
6379 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6380   $EGREP "free" >/dev/null 2>&1; then
6381   :
6382 else
6383   ac_cv_header_stdc=no
6384 fi
6385 rm -f conftest*
6386
6387 fi
6388
6389 if test $ac_cv_header_stdc = yes; then
6390   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6391   if test "$cross_compiling" = yes; then
6392   :
6393 else
6394   cat >conftest.$ac_ext <<_ACEOF
6395 /* confdefs.h.  */
6396 _ACEOF
6397 cat confdefs.h >>conftest.$ac_ext
6398 cat >>conftest.$ac_ext <<_ACEOF
6399 /* end confdefs.h.  */
6400 #include <ctype.h>
6401 #if ((' ' & 0x0FF) == 0x020)
6402 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6403 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6404 #else
6405 # define ISLOWER(c) \
6406                    (('a' <= (c) && (c) <= 'i') \
6407                      || ('j' <= (c) && (c) <= 'r') \
6408                      || ('s' <= (c) && (c) <= 'z'))
6409 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6410 #endif
6411
6412 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6413 int
6414 main ()
6415 {
6416   int i;
6417   for (i = 0; i < 256; i++)
6418     if (XOR (islower (i), ISLOWER (i))
6419         || toupper (i) != TOUPPER (i))
6420       exit(2);
6421   exit (0);
6422 }
6423 _ACEOF
6424 rm -f conftest$ac_exeext
6425 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6426   (eval $ac_link) 2>&5
6427   ac_status=$?
6428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6429   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6430   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6431   (eval $ac_try) 2>&5
6432   ac_status=$?
6433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6434   (exit $ac_status); }; }; then
6435   :
6436 else
6437   echo "$as_me: program exited with status $ac_status" >&5
6438 echo "$as_me: failed program was:" >&5
6439 sed 's/^/| /' conftest.$ac_ext >&5
6440
6441 ( exit $ac_status )
6442 ac_cv_header_stdc=no
6443 fi
6444 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6445 fi
6446 fi
6447 fi
6448 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
6449 echo "${ECHO_T}$ac_cv_header_stdc" >&6
6450 if test $ac_cv_header_stdc = yes; then
6451
6452 cat >>confdefs.h <<\_ACEOF
6453 #define STDC_HEADERS 1
6454 _ACEOF
6455
6456 fi
6457
6458 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6459
6460
6461
6462
6463
6464
6465
6466
6467
6468 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6469                   inttypes.h stdint.h unistd.h
6470 do
6471 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6472 echo "$as_me:$LINENO: checking for $ac_header" >&5
6473 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6474 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6475   echo $ECHO_N "(cached) $ECHO_C" >&6
6476 else
6477   cat >conftest.$ac_ext <<_ACEOF
6478 /* confdefs.h.  */
6479 _ACEOF
6480 cat confdefs.h >>conftest.$ac_ext
6481 cat >>conftest.$ac_ext <<_ACEOF
6482 /* end confdefs.h.  */
6483 $ac_includes_default
6484
6485 #include <$ac_header>
6486 _ACEOF
6487 rm -f conftest.$ac_objext
6488 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6489   (eval $ac_compile) 2>conftest.er1
6490   ac_status=$?
6491   grep -v '^ *+' conftest.er1 >conftest.err
6492   rm -f conftest.er1
6493   cat conftest.err >&5
6494   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6495   (exit $ac_status); } &&
6496          { ac_try='test -z "$ac_c_werror_flag"
6497                          || test ! -s conftest.err'
6498   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6499   (eval $ac_try) 2>&5
6500   ac_status=$?
6501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6502   (exit $ac_status); }; } &&
6503          { ac_try='test -s conftest.$ac_objext'
6504   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6505   (eval $ac_try) 2>&5
6506   ac_status=$?
6507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6508   (exit $ac_status); }; }; then
6509   eval "$as_ac_Header=yes"
6510 else
6511   echo "$as_me: failed program was:" >&5
6512 sed 's/^/| /' conftest.$ac_ext >&5
6513
6514 eval "$as_ac_Header=no"
6515 fi
6516 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6517 fi
6518 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6519 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6520 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6521   cat >>confdefs.h <<_ACEOF
6522 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6523 _ACEOF
6524
6525 fi
6526
6527 done
6528
6529
6530
6531 for ac_header in dlfcn.h
6532 do
6533 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6534 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6535   echo "$as_me:$LINENO: checking for $ac_header" >&5
6536 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6537 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6538   echo $ECHO_N "(cached) $ECHO_C" >&6
6539 fi
6540 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6541 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6542 else
6543   # Is the header compilable?
6544 echo "$as_me:$LINENO: checking $ac_header usability" >&5
6545 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
6546 cat >conftest.$ac_ext <<_ACEOF
6547 /* confdefs.h.  */
6548 _ACEOF
6549 cat confdefs.h >>conftest.$ac_ext
6550 cat >>conftest.$ac_ext <<_ACEOF
6551 /* end confdefs.h.  */
6552 $ac_includes_default
6553 #include <$ac_header>
6554 _ACEOF
6555 rm -f conftest.$ac_objext
6556 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6557   (eval $ac_compile) 2>conftest.er1
6558   ac_status=$?
6559   grep -v '^ *+' conftest.er1 >conftest.err
6560   rm -f conftest.er1
6561   cat conftest.err >&5
6562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6563   (exit $ac_status); } &&
6564          { ac_try='test -z "$ac_c_werror_flag"
6565                          || test ! -s conftest.err'
6566   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6567   (eval $ac_try) 2>&5
6568   ac_status=$?
6569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6570   (exit $ac_status); }; } &&
6571          { ac_try='test -s conftest.$ac_objext'
6572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6573   (eval $ac_try) 2>&5
6574   ac_status=$?
6575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6576   (exit $ac_status); }; }; then
6577   ac_header_compiler=yes
6578 else
6579   echo "$as_me: failed program was:" >&5
6580 sed 's/^/| /' conftest.$ac_ext >&5
6581
6582 ac_header_compiler=no
6583 fi
6584 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6585 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6586 echo "${ECHO_T}$ac_header_compiler" >&6
6587
6588 # Is the header present?
6589 echo "$as_me:$LINENO: checking $ac_header presence" >&5
6590 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
6591 cat >conftest.$ac_ext <<_ACEOF
6592 /* confdefs.h.  */
6593 _ACEOF
6594 cat confdefs.h >>conftest.$ac_ext
6595 cat >>conftest.$ac_ext <<_ACEOF
6596 /* end confdefs.h.  */
6597 #include <$ac_header>
6598 _ACEOF
6599 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6600   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6601   ac_status=$?
6602   grep -v '^ *+' conftest.er1 >conftest.err
6603   rm -f conftest.er1
6604   cat conftest.err >&5
6605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6606   (exit $ac_status); } >/dev/null; then
6607   if test -s conftest.err; then
6608     ac_cpp_err=$ac_c_preproc_warn_flag
6609     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6610   else
6611     ac_cpp_err=
6612   fi
6613 else
6614   ac_cpp_err=yes
6615 fi
6616 if test -z "$ac_cpp_err"; then
6617   ac_header_preproc=yes
6618 else
6619   echo "$as_me: failed program was:" >&5
6620 sed 's/^/| /' conftest.$ac_ext >&5
6621
6622   ac_header_preproc=no
6623 fi
6624 rm -f conftest.err conftest.$ac_ext
6625 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6626 echo "${ECHO_T}$ac_header_preproc" >&6
6627
6628 # So?  What about this header?
6629 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6630   yes:no: )
6631     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6632 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
6633     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
6634 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
6635     ac_header_preproc=yes
6636     ;;
6637   no:yes:* )
6638     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6639 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
6640     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
6641 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
6642     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
6643 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
6644     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
6645 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
6646     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6647 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
6648     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
6649 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
6650     (
6651       cat <<\_ASBOX
6652 ## --------------------------------------------- ##
6653 ## Report this to <http://www.openldap.org/its/> ##
6654 ## --------------------------------------------- ##
6655 _ASBOX
6656     ) |
6657       sed "s/^/$as_me: WARNING:     /" >&2
6658     ;;
6659 esac
6660 echo "$as_me:$LINENO: checking for $ac_header" >&5
6661 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6662 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6663   echo $ECHO_N "(cached) $ECHO_C" >&6
6664 else
6665   eval "$as_ac_Header=\$ac_header_preproc"
6666 fi
6667 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6668 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6669
6670 fi
6671 if test `eval echo '${'$as_ac_Header'}'` = yes; then
6672   cat >>confdefs.h <<_ACEOF
6673 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6674 _ACEOF
6675
6676 fi
6677
6678 done
6679
6680
6681 # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
6682
6683 # find the maximum length of command line arguments
6684 echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5
6685 echo $ECHO_N "checking the maximum length of command line arguments... $ECHO_C" >&6
6686 if test "${lt_cv_sys_max_cmd_len+set}" = set; then
6687   echo $ECHO_N "(cached) $ECHO_C" >&6
6688 else
6689     i=0
6690   teststring="ABCD"
6691
6692   case $build_os in
6693   msdosdjgpp*)
6694     # On DJGPP, this test can blow up pretty badly due to problems in libc
6695     # (any single argument exceeding 2000 bytes causes a buffer overrun
6696     # during glob expansion).  Even if it were fixed, the result of this
6697     # check would be larger than it should be.
6698     lt_cv_sys_max_cmd_len=12288;    # 12K is about right
6699     ;;
6700
6701   gnu*)
6702     # Under GNU Hurd, this test is not required because there is
6703     # no limit to the length of command line arguments.
6704     # Libtool will interpret -1 as no limit whatsoever
6705     lt_cv_sys_max_cmd_len=-1;
6706     ;;
6707
6708   cygwin* | mingw*)
6709     # On Win9x/ME, this test blows up -- it succeeds, but takes
6710     # about 5 minutes as the teststring grows exponentially.
6711     # Worse, since 9x/ME are not pre-emptively multitasking,
6712     # you end up with a "frozen" computer, even though with patience
6713     # the test eventually succeeds (with a max line length of 256k).
6714     # Instead, let's just punt: use the minimum linelength reported by
6715     # all of the supported platforms: 8192 (on NT/2K/XP).
6716     lt_cv_sys_max_cmd_len=8192;
6717     ;;
6718
6719   amigaos*)
6720     # On AmigaOS with pdksh, this test takes hours, literally.
6721     # So we just punt and use a minimum line length of 8192.
6722     lt_cv_sys_max_cmd_len=8192;
6723     ;;
6724
6725   netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
6726     # This has been around since 386BSD, at least.  Likely further.
6727     if test -x /sbin/sysctl; then
6728       lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
6729     elif test -x /usr/sbin/sysctl; then
6730       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
6731     else
6732       lt_cv_sys_max_cmd_len=65536       # usable default for all BSDs
6733     fi
6734     # And add a safety zone
6735     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
6736     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
6737     ;;
6738   osf*)
6739     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
6740     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
6741     # nice to cause kernel panics so lets avoid the loop below.
6742     # First set a reasonable default.
6743     lt_cv_sys_max_cmd_len=16384
6744     #
6745     if test -x /sbin/sysconfig; then
6746       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
6747         *1*) lt_cv_sys_max_cmd_len=-1 ;;
6748       esac
6749     fi
6750     ;;
6751   *)
6752     # If test is not a shell built-in, we'll probably end up computing a
6753     # maximum length that is only half of the actual maximum length, but
6754     # we can't tell.
6755     SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
6756     while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \
6757                = "XX$teststring") >/dev/null 2>&1 &&
6758             new_result=`expr "X$teststring" : ".*" 2>&1` &&
6759             lt_cv_sys_max_cmd_len=$new_result &&
6760             test $i != 17 # 1/2 MB should be enough
6761     do
6762       i=`expr $i + 1`
6763       teststring=$teststring$teststring
6764     done
6765     teststring=
6766     # Add a significant safety factor because C++ compilers can tack on massive
6767     # amounts of additional arguments before passing them to the linker.
6768     # It appears as though 1/2 is a usable value.
6769     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
6770     ;;
6771   esac
6772
6773 fi
6774
6775 if test -n $lt_cv_sys_max_cmd_len ; then
6776   echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5
6777 echo "${ECHO_T}$lt_cv_sys_max_cmd_len" >&6
6778 else
6779   echo "$as_me:$LINENO: result: none" >&5
6780 echo "${ECHO_T}none" >&6
6781 fi
6782
6783
6784
6785
6786 # Check for command to grab the raw symbol name followed by C symbol from nm.
6787 echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5
6788 echo $ECHO_N "checking command to parse $NM output from $compiler object... $ECHO_C" >&6
6789 if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then
6790   echo $ECHO_N "(cached) $ECHO_C" >&6
6791 else
6792
6793 # These are sane defaults that work on at least a few old systems.
6794 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
6795
6796 # Character class describing NM global symbol codes.
6797 symcode='[BCDEGRST]'
6798
6799 # Regexp to match symbols that can be accessed directly from C.
6800 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
6801
6802 # Transform an extracted symbol line into a proper C declaration
6803 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
6804
6805 # Transform an extracted symbol line into symbol name and symbol address
6806 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'"
6807
6808 # Define system-specific variables.
6809 case $host_os in
6810 aix*)
6811   symcode='[BCDT]'
6812   ;;
6813 cygwin* | mingw* | pw32*)
6814   symcode='[ABCDGISTW]'
6815   ;;
6816 hpux*) # Its linker distinguishes data from code symbols
6817   if test "$host_cpu" = ia64; then
6818     symcode='[ABCDEGRST]'
6819   fi
6820   lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
6821   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'"
6822   ;;
6823 linux*)
6824   if test "$host_cpu" = ia64; then
6825     symcode='[ABCDGIRSTW]'
6826     lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
6827     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'"
6828   fi
6829   ;;
6830 irix* | nonstopux*)
6831   symcode='[BCDEGRST]'
6832   ;;
6833 osf*)
6834   symcode='[BCDEGQRST]'
6835   ;;
6836 solaris* | sysv5*)
6837   symcode='[BDRT]'
6838   ;;
6839 sysv4)
6840   symcode='[DFNSTU]'
6841   ;;
6842 esac
6843
6844 # Handle CRLF in mingw tool chain
6845 opt_cr=
6846 case $build_os in
6847 mingw*)
6848   opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
6849   ;;
6850 esac
6851
6852 # If we're using GNU nm, then use its standard symbol codes.
6853 case `$NM -V 2>&1` in
6854 *GNU* | *'with BFD'*)
6855   symcode='[ABCDGIRSTW]' ;;
6856 esac
6857
6858 # Try without a prefix undercore, then with it.
6859 for ac_symprfx in "" "_"; do
6860
6861   # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
6862   symxfrm="\\1 $ac_symprfx\\2 \\2"
6863
6864   # Write the raw and C identifiers.
6865   lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[       ]\($symcode$symcode*\)[         ][      ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
6866
6867   # Check to see that the pipe works correctly.
6868   pipe_works=no
6869
6870   rm -f conftest*
6871   cat > conftest.$ac_ext <<EOF
6872 #ifdef __cplusplus
6873 extern "C" {
6874 #endif
6875 char nm_test_var;
6876 void nm_test_func(){}
6877 #ifdef __cplusplus
6878 }
6879 #endif
6880 int main(){nm_test_var='a';nm_test_func();return(0);}
6881 EOF
6882
6883   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6884   (eval $ac_compile) 2>&5
6885   ac_status=$?
6886   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6887   (exit $ac_status); }; then
6888     # Now try to grab the symbols.
6889     nlist=conftest.nm
6890     if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5
6891   (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5
6892   ac_status=$?
6893   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6894   (exit $ac_status); } && test -s "$nlist"; then
6895       # Try sorting and uniquifying the output.
6896       if sort "$nlist" | uniq > "$nlist"T; then
6897         mv -f "$nlist"T "$nlist"
6898       else
6899         rm -f "$nlist"T
6900       fi
6901
6902       # Make sure that we snagged all the symbols we need.
6903       if grep ' nm_test_var$' "$nlist" >/dev/null; then
6904         if grep ' nm_test_func$' "$nlist" >/dev/null; then
6905           cat <<EOF > conftest.$ac_ext
6906 #ifdef __cplusplus
6907 extern "C" {
6908 #endif
6909
6910 EOF
6911           # Now generate the symbol file.
6912           eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
6913
6914           cat <<EOF >> conftest.$ac_ext
6915 #if defined (__STDC__) && __STDC__
6916 # define lt_ptr_t void *
6917 #else
6918 # define lt_ptr_t char *
6919 # define const
6920 #endif
6921
6922 /* The mapping between symbol names and symbols. */
6923 const struct {
6924   const char *name;
6925   lt_ptr_t address;
6926 }
6927 lt_preloaded_symbols[] =
6928 {
6929 EOF
6930           $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
6931           cat <<\EOF >> conftest.$ac_ext
6932   {0, (lt_ptr_t) 0}
6933 };
6934
6935 #ifdef __cplusplus
6936 }
6937 #endif
6938 EOF
6939           # Now try linking the two files.
6940           mv conftest.$ac_objext conftstm.$ac_objext
6941           lt_save_LIBS="$LIBS"
6942           lt_save_CFLAGS="$CFLAGS"
6943           LIBS="conftstm.$ac_objext"
6944           CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
6945           if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6946   (eval $ac_link) 2>&5
6947   ac_status=$?
6948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6949   (exit $ac_status); } && test -s conftest${ac_exeext}; then
6950             pipe_works=yes
6951           fi
6952           LIBS="$lt_save_LIBS"
6953           CFLAGS="$lt_save_CFLAGS"
6954         else
6955           echo "cannot find nm_test_func in $nlist" >&5
6956         fi
6957       else
6958         echo "cannot find nm_test_var in $nlist" >&5
6959       fi
6960     else
6961       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
6962     fi
6963   else
6964     echo "$progname: failed program was:" >&5
6965     cat conftest.$ac_ext >&5
6966   fi
6967   rm -f conftest* conftst*
6968
6969   # Do not use the global_symbol_pipe unless it works.
6970   if test "$pipe_works" = yes; then
6971     break
6972   else
6973     lt_cv_sys_global_symbol_pipe=
6974   fi
6975 done
6976
6977 fi
6978
6979 if test -z "$lt_cv_sys_global_symbol_pipe"; then
6980   lt_cv_sys_global_symbol_to_cdecl=
6981 fi
6982 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
6983   echo "$as_me:$LINENO: result: failed" >&5
6984 echo "${ECHO_T}failed" >&6
6985 else
6986   echo "$as_me:$LINENO: result: ok" >&5
6987 echo "${ECHO_T}ok" >&6
6988 fi
6989
6990 echo "$as_me:$LINENO: checking for objdir" >&5
6991 echo $ECHO_N "checking for objdir... $ECHO_C" >&6
6992 if test "${lt_cv_objdir+set}" = set; then
6993   echo $ECHO_N "(cached) $ECHO_C" >&6
6994 else
6995   rm -f .libs 2>/dev/null
6996 mkdir .libs 2>/dev/null
6997 if test -d .libs; then
6998   lt_cv_objdir=.libs
6999 else
7000   # MS-DOS does not allow filenames that begin with a dot.
7001   lt_cv_objdir=_libs
7002 fi
7003 rmdir .libs 2>/dev/null
7004 fi
7005 echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5
7006 echo "${ECHO_T}$lt_cv_objdir" >&6
7007 objdir=$lt_cv_objdir
7008
7009
7010
7011
7012
7013 case $host_os in
7014 aix3*)
7015   # AIX sometimes has problems with the GCC collect2 program.  For some
7016   # reason, if we set the COLLECT_NAMES environment variable, the problems
7017   # vanish in a puff of smoke.
7018   if test "X${COLLECT_NAMES+set}" != Xset; then
7019     COLLECT_NAMES=
7020     export COLLECT_NAMES
7021   fi
7022   ;;
7023 esac
7024
7025 # Sed substitution that helps us do robust quoting.  It backslashifies
7026 # metacharacters that are still active within double-quoted strings.
7027 Xsed='sed -e 1s/^X//'
7028 sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'
7029
7030 # Same as above, but do not quote variable references.
7031 double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'
7032
7033 # Sed substitution to delay expansion of an escaped shell variable in a
7034 # double_quote_subst'ed string.
7035 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
7036
7037 # Sed substitution to avoid accidental globbing in evaled expressions
7038 no_glob_subst='s/\*/\\\*/g'
7039
7040 # Constants:
7041 rm="rm -f"
7042
7043 # Global variables:
7044 default_ofile=libtool
7045 can_build_shared=yes
7046
7047 # All known linkers require a `.a' archive for static linking (except MSVC,
7048 # which needs '.lib').
7049 libext=a
7050 ltmain="$ac_aux_dir/ltmain.sh"
7051 ofile="$default_ofile"
7052 with_gnu_ld="$lt_cv_prog_gnu_ld"
7053
7054 if test -n "$ac_tool_prefix"; then
7055   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
7056 set dummy ${ac_tool_prefix}ar; ac_word=$2
7057 echo "$as_me:$LINENO: checking for $ac_word" >&5
7058 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7059 if test "${ac_cv_prog_AR+set}" = set; then
7060   echo $ECHO_N "(cached) $ECHO_C" >&6
7061 else
7062   if test -n "$AR"; then
7063   ac_cv_prog_AR="$AR" # Let the user override the test.
7064 else
7065 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7066 for as_dir in $PATH
7067 do
7068   IFS=$as_save_IFS
7069   test -z "$as_dir" && as_dir=.
7070   for ac_exec_ext in '' $ac_executable_extensions; do
7071   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7072     ac_cv_prog_AR="${ac_tool_prefix}ar"
7073     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7074     break 2
7075   fi
7076 done
7077 done
7078
7079 fi
7080 fi
7081 AR=$ac_cv_prog_AR
7082 if test -n "$AR"; then
7083   echo "$as_me:$LINENO: result: $AR" >&5
7084 echo "${ECHO_T}$AR" >&6
7085 else
7086   echo "$as_me:$LINENO: result: no" >&5
7087 echo "${ECHO_T}no" >&6
7088 fi
7089
7090 fi
7091 if test -z "$ac_cv_prog_AR"; then
7092   ac_ct_AR=$AR
7093   # Extract the first word of "ar", so it can be a program name with args.
7094 set dummy ar; ac_word=$2
7095 echo "$as_me:$LINENO: checking for $ac_word" >&5
7096 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7097 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
7098   echo $ECHO_N "(cached) $ECHO_C" >&6
7099 else
7100   if test -n "$ac_ct_AR"; then
7101   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
7102 else
7103 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7104 for as_dir in $PATH
7105 do
7106   IFS=$as_save_IFS
7107   test -z "$as_dir" && as_dir=.
7108   for ac_exec_ext in '' $ac_executable_extensions; do
7109   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7110     ac_cv_prog_ac_ct_AR="ar"
7111     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7112     break 2
7113   fi
7114 done
7115 done
7116
7117   test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="false"
7118 fi
7119 fi
7120 ac_ct_AR=$ac_cv_prog_ac_ct_AR
7121 if test -n "$ac_ct_AR"; then
7122   echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
7123 echo "${ECHO_T}$ac_ct_AR" >&6
7124 else
7125   echo "$as_me:$LINENO: result: no" >&5
7126 echo "${ECHO_T}no" >&6
7127 fi
7128
7129   AR=$ac_ct_AR
7130 else
7131   AR="$ac_cv_prog_AR"
7132 fi
7133
7134 if test -n "$ac_tool_prefix"; then
7135   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
7136 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
7137 echo "$as_me:$LINENO: checking for $ac_word" >&5
7138 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7139 if test "${ac_cv_prog_RANLIB+set}" = set; then
7140   echo $ECHO_N "(cached) $ECHO_C" >&6
7141 else
7142   if test -n "$RANLIB"; then
7143   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
7144 else
7145 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7146 for as_dir in $PATH
7147 do
7148   IFS=$as_save_IFS
7149   test -z "$as_dir" && as_dir=.
7150   for ac_exec_ext in '' $ac_executable_extensions; do
7151   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7152     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
7153     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7154     break 2
7155   fi
7156 done
7157 done
7158
7159 fi
7160 fi
7161 RANLIB=$ac_cv_prog_RANLIB
7162 if test -n "$RANLIB"; then
7163   echo "$as_me:$LINENO: result: $RANLIB" >&5
7164 echo "${ECHO_T}$RANLIB" >&6
7165 else
7166   echo "$as_me:$LINENO: result: no" >&5
7167 echo "${ECHO_T}no" >&6
7168 fi
7169
7170 fi
7171 if test -z "$ac_cv_prog_RANLIB"; then
7172   ac_ct_RANLIB=$RANLIB
7173   # Extract the first word of "ranlib", so it can be a program name with args.
7174 set dummy ranlib; ac_word=$2
7175 echo "$as_me:$LINENO: checking for $ac_word" >&5
7176 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7177 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
7178   echo $ECHO_N "(cached) $ECHO_C" >&6
7179 else
7180   if test -n "$ac_ct_RANLIB"; then
7181   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
7182 else
7183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7184 for as_dir in $PATH
7185 do
7186   IFS=$as_save_IFS
7187   test -z "$as_dir" && as_dir=.
7188   for ac_exec_ext in '' $ac_executable_extensions; do
7189   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7190     ac_cv_prog_ac_ct_RANLIB="ranlib"
7191     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7192     break 2
7193   fi
7194 done
7195 done
7196
7197   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
7198 fi
7199 fi
7200 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
7201 if test -n "$ac_ct_RANLIB"; then
7202   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
7203 echo "${ECHO_T}$ac_ct_RANLIB" >&6
7204 else
7205   echo "$as_me:$LINENO: result: no" >&5
7206 echo "${ECHO_T}no" >&6
7207 fi
7208
7209   RANLIB=$ac_ct_RANLIB
7210 else
7211   RANLIB="$ac_cv_prog_RANLIB"
7212 fi
7213
7214 if test -n "$ac_tool_prefix"; then
7215   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
7216 set dummy ${ac_tool_prefix}strip; ac_word=$2
7217 echo "$as_me:$LINENO: checking for $ac_word" >&5
7218 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7219 if test "${ac_cv_prog_STRIP+set}" = set; then
7220   echo $ECHO_N "(cached) $ECHO_C" >&6
7221 else
7222   if test -n "$STRIP"; then
7223   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
7224 else
7225 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7226 for as_dir in $PATH
7227 do
7228   IFS=$as_save_IFS
7229   test -z "$as_dir" && as_dir=.
7230   for ac_exec_ext in '' $ac_executable_extensions; do
7231   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7232     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
7233     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7234     break 2
7235   fi
7236 done
7237 done
7238
7239 fi
7240 fi
7241 STRIP=$ac_cv_prog_STRIP
7242 if test -n "$STRIP"; then
7243   echo "$as_me:$LINENO: result: $STRIP" >&5
7244 echo "${ECHO_T}$STRIP" >&6
7245 else
7246   echo "$as_me:$LINENO: result: no" >&5
7247 echo "${ECHO_T}no" >&6
7248 fi
7249
7250 fi
7251 if test -z "$ac_cv_prog_STRIP"; then
7252   ac_ct_STRIP=$STRIP
7253   # Extract the first word of "strip", so it can be a program name with args.
7254 set dummy strip; ac_word=$2
7255 echo "$as_me:$LINENO: checking for $ac_word" >&5
7256 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7257 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
7258   echo $ECHO_N "(cached) $ECHO_C" >&6
7259 else
7260   if test -n "$ac_ct_STRIP"; then
7261   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
7262 else
7263 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7264 for as_dir in $PATH
7265 do
7266   IFS=$as_save_IFS
7267   test -z "$as_dir" && as_dir=.
7268   for ac_exec_ext in '' $ac_executable_extensions; do
7269   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7270     ac_cv_prog_ac_ct_STRIP="strip"
7271     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7272     break 2
7273   fi
7274 done
7275 done
7276
7277   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
7278 fi
7279 fi
7280 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
7281 if test -n "$ac_ct_STRIP"; then
7282   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
7283 echo "${ECHO_T}$ac_ct_STRIP" >&6
7284 else
7285   echo "$as_me:$LINENO: result: no" >&5
7286 echo "${ECHO_T}no" >&6
7287 fi
7288
7289   STRIP=$ac_ct_STRIP
7290 else
7291   STRIP="$ac_cv_prog_STRIP"
7292 fi
7293
7294
7295 old_CC="$CC"
7296 old_CFLAGS="$CFLAGS"
7297
7298 # Set sane defaults for various variables
7299 test -z "$AR" && AR=ar
7300 test -z "$AR_FLAGS" && AR_FLAGS=cru
7301 test -z "$AS" && AS=as
7302 test -z "$CC" && CC=cc
7303 test -z "$LTCC" && LTCC=$CC
7304 test -z "$DLLTOOL" && DLLTOOL=dlltool
7305 test -z "$LD" && LD=ld
7306 test -z "$LN_S" && LN_S="ln -s"
7307 test -z "$MAGIC_CMD" && MAGIC_CMD=file
7308 test -z "$NM" && NM=nm
7309 test -z "$SED" && SED=sed
7310 test -z "$OBJDUMP" && OBJDUMP=objdump
7311 test -z "$RANLIB" && RANLIB=:
7312 test -z "$STRIP" && STRIP=:
7313 test -z "$ac_objext" && ac_objext=o
7314
7315 # Determine commands to create old-style static archives.
7316 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
7317 old_postinstall_cmds='chmod 644 $oldlib'
7318 old_postuninstall_cmds=
7319
7320 if test -n "$RANLIB"; then
7321   case $host_os in
7322   openbsd*)
7323     old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
7324     ;;
7325   *)
7326     old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
7327     ;;
7328   esac
7329   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
7330 fi
7331
7332 for cc_temp in $compiler""; do
7333   case $cc_temp in
7334     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
7335     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
7336     \-*) ;;
7337     *) break;;
7338   esac
7339 done
7340 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
7341
7342
7343 # Only perform the check for file, if the check method requires it
7344 case $deplibs_check_method in
7345 file_magic*)
7346   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
7347     echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5
7348 echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6
7349 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7350   echo $ECHO_N "(cached) $ECHO_C" >&6
7351 else
7352   case $MAGIC_CMD in
7353 [\\/*] |  ?:[\\/]*)
7354   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7355   ;;
7356 *)
7357   lt_save_MAGIC_CMD="$MAGIC_CMD"
7358   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
7359   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
7360   for ac_dir in $ac_dummy; do
7361     IFS="$lt_save_ifs"
7362     test -z "$ac_dir" && ac_dir=.
7363     if test -f $ac_dir/${ac_tool_prefix}file; then
7364       lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
7365       if test -n "$file_magic_test_file"; then
7366         case $deplibs_check_method in
7367         "file_magic "*)
7368           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
7369           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7370           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7371             $EGREP "$file_magic_regex" > /dev/null; then
7372             :
7373           else
7374             cat <<EOF 1>&2
7375
7376 *** Warning: the command libtool uses to detect shared libraries,
7377 *** $file_magic_cmd, produces output that libtool cannot recognize.
7378 *** The result is that libtool may fail to recognize shared libraries
7379 *** as such.  This will affect the creation of libtool libraries that
7380 *** depend on shared libraries, but programs linked with such libtool
7381 *** libraries will work regardless of this problem.  Nevertheless, you
7382 *** may want to report the problem to your system manager and/or to
7383 *** bug-libtool@gnu.org
7384
7385 EOF
7386           fi ;;
7387         esac
7388       fi
7389       break
7390     fi
7391   done
7392   IFS="$lt_save_ifs"
7393   MAGIC_CMD="$lt_save_MAGIC_CMD"
7394   ;;
7395 esac
7396 fi
7397
7398 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7399 if test -n "$MAGIC_CMD"; then
7400   echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7401 echo "${ECHO_T}$MAGIC_CMD" >&6
7402 else
7403   echo "$as_me:$LINENO: result: no" >&5
7404 echo "${ECHO_T}no" >&6
7405 fi
7406
7407 if test -z "$lt_cv_path_MAGIC_CMD"; then
7408   if test -n "$ac_tool_prefix"; then
7409     echo "$as_me:$LINENO: checking for file" >&5
7410 echo $ECHO_N "checking for file... $ECHO_C" >&6
7411 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7412   echo $ECHO_N "(cached) $ECHO_C" >&6
7413 else
7414   case $MAGIC_CMD in
7415 [\\/*] |  ?:[\\/]*)
7416   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7417   ;;
7418 *)
7419   lt_save_MAGIC_CMD="$MAGIC_CMD"
7420   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
7421   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
7422   for ac_dir in $ac_dummy; do
7423     IFS="$lt_save_ifs"
7424     test -z "$ac_dir" && ac_dir=.
7425     if test -f $ac_dir/file; then
7426       lt_cv_path_MAGIC_CMD="$ac_dir/file"
7427       if test -n "$file_magic_test_file"; then
7428         case $deplibs_check_method in
7429         "file_magic "*)
7430           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
7431           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7432           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7433             $EGREP "$file_magic_regex" > /dev/null; then
7434             :
7435           else
7436             cat <<EOF 1>&2
7437
7438 *** Warning: the command libtool uses to detect shared libraries,
7439 *** $file_magic_cmd, produces output that libtool cannot recognize.
7440 *** The result is that libtool may fail to recognize shared libraries
7441 *** as such.  This will affect the creation of libtool libraries that
7442 *** depend on shared libraries, but programs linked with such libtool
7443 *** libraries will work regardless of this problem.  Nevertheless, you
7444 *** may want to report the problem to your system manager and/or to
7445 *** bug-libtool@gnu.org
7446
7447 EOF
7448           fi ;;
7449         esac
7450       fi
7451       break
7452     fi
7453   done
7454   IFS="$lt_save_ifs"
7455   MAGIC_CMD="$lt_save_MAGIC_CMD"
7456   ;;
7457 esac
7458 fi
7459
7460 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7461 if test -n "$MAGIC_CMD"; then
7462   echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7463 echo "${ECHO_T}$MAGIC_CMD" >&6
7464 else
7465   echo "$as_me:$LINENO: result: no" >&5
7466 echo "${ECHO_T}no" >&6
7467 fi
7468
7469   else
7470     MAGIC_CMD=:
7471   fi
7472 fi
7473
7474   fi
7475   ;;
7476 esac
7477
7478 enable_dlopen=yes
7479 enable_win32_dll=yes
7480
7481 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
7482 if test "${enable_libtool_lock+set}" = set; then
7483   enableval="$enable_libtool_lock"
7484
7485 fi;
7486 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
7487
7488
7489 # Check whether --with-pic or --without-pic was given.
7490 if test "${with_pic+set}" = set; then
7491   withval="$with_pic"
7492   pic_mode="$withval"
7493 else
7494   pic_mode=default
7495 fi;
7496 test -z "$pic_mode" && pic_mode=default
7497
7498 # Use C for the default configuration in the libtool script
7499 tagname=
7500 lt_save_CC="$CC"
7501 ac_ext=c
7502 ac_cpp='$CPP $CPPFLAGS'
7503 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7504 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7505 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7506
7507
7508 # Source file extension for C test sources.
7509 ac_ext=c
7510
7511 # Object file extension for compiled C test sources.
7512 objext=o
7513 objext=$objext
7514
7515 # Code to be used in simple compile tests
7516 lt_simple_compile_test_code="int some_variable = 0;\n"
7517
7518 # Code to be used in simple link tests
7519 lt_simple_link_test_code='int main(){return(0);}\n'
7520
7521
7522 # If no C compiler was specified, use CC.
7523 LTCC=${LTCC-"$CC"}
7524
7525 # Allow CC to be a program name with arguments.
7526 compiler=$CC
7527
7528
7529 # save warnings/boilerplate of simple test code
7530 ac_outfile=conftest.$ac_objext
7531 printf "$lt_simple_compile_test_code" >conftest.$ac_ext
7532 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
7533 _lt_compiler_boilerplate=`cat conftest.err`
7534 $rm conftest*
7535
7536 ac_outfile=conftest.$ac_objext
7537 printf "$lt_simple_link_test_code" >conftest.$ac_ext
7538 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
7539 _lt_linker_boilerplate=`cat conftest.err`
7540 $rm conftest*
7541
7542
7543 #
7544 # Check for any special shared library compilation flags.
7545 #
7546 lt_prog_cc_shlib=
7547 if test "$GCC" = no; then
7548   case $host_os in
7549   sco3.2v5*)
7550     lt_prog_cc_shlib='-belf'
7551     ;;
7552   esac
7553 fi
7554 if test -n "$lt_prog_cc_shlib"; then
7555   { echo "$as_me:$LINENO: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&5
7556 echo "$as_me: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&2;}
7557   if echo "$old_CC $old_CFLAGS " | grep "[      ]$lt_prog_cc_shlib[     ]" >/dev/null; then :
7558   else
7559     { echo "$as_me:$LINENO: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&5
7560 echo "$as_me: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&2;}
7561     lt_cv_prog_cc_can_build_shared=no
7562   fi
7563 fi
7564
7565
7566 #
7567 # Check to make sure the static flag actually works.
7568 #
7569 echo "$as_me:$LINENO: checking if $compiler static flag $lt_prog_compiler_static works" >&5
7570 echo $ECHO_N "checking if $compiler static flag $lt_prog_compiler_static works... $ECHO_C" >&6
7571 if test "${lt_prog_compiler_static_works+set}" = set; then
7572   echo $ECHO_N "(cached) $ECHO_C" >&6
7573 else
7574   lt_prog_compiler_static_works=no
7575    save_LDFLAGS="$LDFLAGS"
7576    LDFLAGS="$LDFLAGS $lt_prog_compiler_static"
7577    printf "$lt_simple_link_test_code" > conftest.$ac_ext
7578    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
7579      # The linker can only warn and ignore the option if not recognized
7580      # So say no if there are warnings
7581      if test -s conftest.err; then
7582        # Append any errors to the config.log.
7583        cat conftest.err 1>&5
7584        $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp
7585        $SED '/^$/d' conftest.err >conftest.er2
7586        if diff conftest.exp conftest.er2 >/dev/null; then
7587          lt_prog_compiler_static_works=yes
7588        fi
7589      else
7590        lt_prog_compiler_static_works=yes
7591      fi
7592    fi
7593    $rm conftest*
7594    LDFLAGS="$save_LDFLAGS"
7595
7596 fi
7597 echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works" >&5
7598 echo "${ECHO_T}$lt_prog_compiler_static_works" >&6
7599
7600 if test x"$lt_prog_compiler_static_works" = xyes; then
7601     :
7602 else
7603     lt_prog_compiler_static=
7604 fi
7605
7606
7607
7608
7609 lt_prog_compiler_no_builtin_flag=
7610
7611 if test "$GCC" = yes; then
7612   lt_prog_compiler_no_builtin_flag=' -fno-builtin'
7613
7614
7615 echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
7616 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6
7617 if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then
7618   echo $ECHO_N "(cached) $ECHO_C" >&6
7619 else
7620   lt_cv_prog_compiler_rtti_exceptions=no
7621   ac_outfile=conftest.$ac_objext
7622    printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7623    lt_compiler_flag="-fno-rtti -fno-exceptions"
7624    # Insert the option either (1) after the last *FLAGS variable, or
7625    # (2) before a word containing "conftest.", or (3) at the end.
7626    # Note that $ac_compile itself does not contain backslashes and begins
7627    # with a dollar sign (not a hyphen), so the echo should work correctly.
7628    # The option is referenced via a variable to avoid confusing sed.
7629    lt_compile=`echo "$ac_compile" | $SED \
7630    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7631    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7632    -e 's:$: $lt_compiler_flag:'`
7633    (eval echo "\"\$as_me:7633: $lt_compile\"" >&5)
7634    (eval "$lt_compile" 2>conftest.err)
7635    ac_status=$?
7636    cat conftest.err >&5
7637    echo "$as_me:7637: \$? = $ac_status" >&5
7638    if (exit $ac_status) && test -s "$ac_outfile"; then
7639      # The compiler can only warn and ignore the option if not recognized
7640      # So say no if there are warnings other than the usual output.
7641      $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
7642      $SED '/^$/d' conftest.err >conftest.er2
7643      if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
7644        lt_cv_prog_compiler_rtti_exceptions=yes
7645      fi
7646    fi
7647    $rm conftest*
7648
7649 fi
7650 echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
7651 echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6
7652
7653 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
7654     lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
7655 else
7656     :
7657 fi
7658
7659 fi
7660
7661 lt_prog_compiler_wl=
7662 lt_prog_compiler_pic=
7663 lt_prog_compiler_static=
7664
7665 echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
7666 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6
7667
7668   if test "$GCC" = yes; then
7669     lt_prog_compiler_wl='-Wl,'
7670     lt_prog_compiler_static='-static'
7671
7672     case $host_os in
7673       aix*)
7674       # All AIX code is PIC.
7675       if test "$host_cpu" = ia64; then
7676         # AIX 5 now supports IA64 processor
7677         lt_prog_compiler_static='-Bstatic'
7678       fi
7679       ;;
7680
7681     amigaos*)
7682       # FIXME: we need at least 68020 code to build shared libraries, but
7683       # adding the `-m68020' flag to GCC prevents building anything better,
7684       # like `-m68040'.
7685       lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
7686       ;;
7687
7688     beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
7689       # PIC is the default for these OSes.
7690       ;;
7691
7692     mingw* | pw32* | os2*)
7693       # This hack is so that the source file can tell whether it is being
7694       # built for inclusion in a dll (and should export symbols for example).
7695       lt_prog_compiler_pic='-DDLL_EXPORT'
7696       ;;
7697
7698     darwin* | rhapsody*)
7699       # PIC is the default on this platform
7700       # Common symbols not allowed in MH_DYLIB files
7701       lt_prog_compiler_pic='-fno-common'
7702       ;;
7703
7704     msdosdjgpp*)
7705       # Just because we use GCC doesn't mean we suddenly get shared libraries
7706       # on systems that don't support them.
7707       lt_prog_compiler_can_build_shared=no
7708       enable_shared=no
7709       ;;
7710
7711     sysv4*MP*)
7712       if test -d /usr/nec; then
7713         lt_prog_compiler_pic=-Kconform_pic
7714       fi
7715       ;;
7716
7717     hpux*)
7718       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
7719       # not for PA HP-UX.
7720       case $host_cpu in
7721       hppa*64*|ia64*)
7722         # +Z the default
7723         ;;
7724       *)
7725         lt_prog_compiler_pic='-fPIC'
7726         ;;
7727       esac
7728       ;;
7729
7730     *)
7731       lt_prog_compiler_pic='-fPIC'
7732       ;;
7733     esac
7734   else
7735     # PORTME Check for flag to pass linker flags through the system compiler.
7736     case $host_os in
7737     aix*)
7738       lt_prog_compiler_wl='-Wl,'
7739       if test "$host_cpu" = ia64; then
7740         # AIX 5 now supports IA64 processor
7741         lt_prog_compiler_static='-Bstatic'
7742       else
7743         lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
7744       fi
7745       ;;
7746       darwin*)
7747         # PIC is the default on this platform
7748         # Common symbols not allowed in MH_DYLIB files
7749        case $cc_basename in
7750          xlc*)
7751          lt_prog_compiler_pic='-qnocommon'
7752          lt_prog_compiler_wl='-Wl,'
7753          ;;
7754        esac
7755        ;;
7756
7757     mingw* | pw32* | os2*)
7758       # This hack is so that the source file can tell whether it is being
7759       # built for inclusion in a dll (and should export symbols for example).
7760       lt_prog_compiler_pic='-DDLL_EXPORT'
7761       ;;
7762
7763     hpux9* | hpux10* | hpux11*)
7764       lt_prog_compiler_wl='-Wl,'
7765       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
7766       # not for PA HP-UX.
7767       case $host_cpu in
7768       hppa*64*|ia64*)
7769         # +Z the default
7770         ;;
7771       *)
7772         lt_prog_compiler_pic='+Z'
7773         ;;
7774       esac
7775       # Is there a better lt_prog_compiler_static that works with the bundled CC?
7776       lt_prog_compiler_static='${wl}-a ${wl}archive'
7777       ;;
7778
7779     irix5* | irix6* | nonstopux*)
7780       lt_prog_compiler_wl='-Wl,'
7781       # PIC (with -KPIC) is the default.
7782       lt_prog_compiler_static='-non_shared'
7783       ;;
7784
7785     newsos6)
7786       lt_prog_compiler_pic='-KPIC'
7787       lt_prog_compiler_static='-Bstatic'
7788       ;;
7789
7790     linux*)
7791       case $cc_basename in
7792       icc* | ecc*)
7793         lt_prog_compiler_wl='-Wl,'
7794         lt_prog_compiler_pic='-KPIC'
7795         lt_prog_compiler_static='-static'
7796         ;;
7797       pgcc* | pgf77* | pgf90* | pgf95*)
7798         # Portland Group compilers (*not* the Pentium gcc compiler,
7799         # which looks to be a dead project)
7800         lt_prog_compiler_wl='-Wl,'
7801         lt_prog_compiler_pic='-fpic'
7802         lt_prog_compiler_static='-Bstatic'
7803         ;;
7804       ccc*)
7805         lt_prog_compiler_wl='-Wl,'
7806         # All Alpha code is PIC.
7807         lt_prog_compiler_static='-non_shared'
7808         ;;
7809       esac
7810       ;;
7811
7812     osf3* | osf4* | osf5*)
7813       lt_prog_compiler_wl='-Wl,'
7814       # All OSF/1 code is PIC.
7815       lt_prog_compiler_static='-non_shared'
7816       ;;
7817
7818     sco3.2v5*)
7819       lt_prog_compiler_pic='-Kpic'
7820       lt_prog_compiler_static='-dn'
7821       ;;
7822
7823     solaris*)
7824       lt_prog_compiler_pic='-KPIC'
7825       lt_prog_compiler_static='-Bstatic'
7826       case $cc_basename in
7827       f77* | f90* | f95*)
7828         lt_prog_compiler_wl='-Qoption ld ';;
7829       *)
7830         lt_prog_compiler_wl='-Wl,';;
7831       esac
7832       ;;
7833
7834     sunos4*)
7835       lt_prog_compiler_wl='-Qoption ld '
7836       lt_prog_compiler_pic='-PIC'
7837       lt_prog_compiler_static='-Bstatic'
7838       ;;
7839
7840     sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
7841       lt_prog_compiler_wl='-Wl,'
7842       lt_prog_compiler_pic='-KPIC'
7843       lt_prog_compiler_static='-Bstatic'
7844       ;;
7845
7846     sysv4*MP*)
7847       if test -d /usr/nec ;then
7848         lt_prog_compiler_pic='-Kconform_pic'
7849         lt_prog_compiler_static='-Bstatic'
7850       fi
7851       ;;
7852
7853     unicos*)
7854       lt_prog_compiler_wl='-Wl,'
7855       lt_prog_compiler_can_build_shared=no
7856       ;;
7857
7858     uts4*)
7859       lt_prog_compiler_pic='-pic'
7860       lt_prog_compiler_static='-Bstatic'
7861       ;;
7862
7863     *)
7864       lt_prog_compiler_can_build_shared=no
7865       ;;
7866     esac
7867   fi
7868
7869 echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5
7870 echo "${ECHO_T}$lt_prog_compiler_pic" >&6
7871
7872 #
7873 # Check to make sure the PIC flag actually works.
7874 #
7875 if test -n "$lt_prog_compiler_pic"; then
7876
7877 echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
7878 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic works... $ECHO_C" >&6
7879 if test "${lt_prog_compiler_pic_works+set}" = set; then
7880   echo $ECHO_N "(cached) $ECHO_C" >&6
7881 else
7882   lt_prog_compiler_pic_works=no
7883   ac_outfile=conftest.$ac_objext
7884    printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7885    lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
7886    # Insert the option either (1) after the last *FLAGS variable, or
7887    # (2) before a word containing "conftest.", or (3) at the end.
7888    # Note that $ac_compile itself does not contain backslashes and begins
7889    # with a dollar sign (not a hyphen), so the echo should work correctly.
7890    # The option is referenced via a variable to avoid confusing sed.
7891    lt_compile=`echo "$ac_compile" | $SED \
7892    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7893    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7894    -e 's:$: $lt_compiler_flag:'`
7895    (eval echo "\"\$as_me:7895: $lt_compile\"" >&5)
7896    (eval "$lt_compile" 2>conftest.err)
7897    ac_status=$?
7898    cat conftest.err >&5
7899    echo "$as_me:7899: \$? = $ac_status" >&5
7900    if (exit $ac_status) && test -s "$ac_outfile"; then
7901      # The compiler can only warn and ignore the option if not recognized
7902      # So say no if there are warnings other than the usual output.
7903      $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
7904      $SED '/^$/d' conftest.err >conftest.er2
7905      if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
7906        lt_prog_compiler_pic_works=yes
7907      fi
7908    fi
7909    $rm conftest*
7910
7911 fi
7912 echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works" >&5
7913 echo "${ECHO_T}$lt_prog_compiler_pic_works" >&6
7914
7915 if test x"$lt_prog_compiler_pic_works" = xyes; then
7916     case $lt_prog_compiler_pic in
7917      "" | " "*) ;;
7918      *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
7919      esac
7920 else
7921     lt_prog_compiler_pic=
7922      lt_prog_compiler_can_build_shared=no
7923 fi
7924
7925 fi
7926 case $host_os in
7927   # For platforms which do not support PIC, -DPIC is meaningless:
7928   *djgpp*)
7929     lt_prog_compiler_pic=
7930     ;;
7931   *)
7932     lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
7933     ;;
7934 esac
7935
7936 echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
7937 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6
7938 if test "${lt_cv_prog_compiler_c_o+set}" = set; then
7939   echo $ECHO_N "(cached) $ECHO_C" >&6
7940 else
7941   lt_cv_prog_compiler_c_o=no
7942    $rm -r conftest 2>/dev/null
7943    mkdir conftest
7944    cd conftest
7945    mkdir out
7946    printf "$lt_simple_compile_test_code" > conftest.$ac_ext
7947
7948    lt_compiler_flag="-o out/conftest2.$ac_objext"
7949    # Insert the option either (1) after the last *FLAGS variable, or
7950    # (2) before a word containing "conftest.", or (3) at the end.
7951    # Note that $ac_compile itself does not contain backslashes and begins
7952    # with a dollar sign (not a hyphen), so the echo should work correctly.
7953    lt_compile=`echo "$ac_compile" | $SED \
7954    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7955    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7956    -e 's:$: $lt_compiler_flag:'`
7957    (eval echo "\"\$as_me:7957: $lt_compile\"" >&5)
7958    (eval "$lt_compile" 2>out/conftest.err)
7959    ac_status=$?
7960    cat out/conftest.err >&5
7961    echo "$as_me:7961: \$? = $ac_status" >&5
7962    if (exit $ac_status) && test -s out/conftest2.$ac_objext
7963    then
7964      # The compiler can only warn and ignore the option if not recognized
7965      # So say no if there are warnings
7966      $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp
7967      $SED '/^$/d' out/conftest.err >out/conftest.er2
7968      if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then
7969        lt_cv_prog_compiler_c_o=yes
7970      fi
7971    fi
7972    chmod u+w . 2>&5
7973    $rm conftest*
7974    # SGI C++ compiler will create directory out/ii_files/ for
7975    # template instantiation
7976    test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
7977    $rm out/* && rmdir out
7978    cd ..
7979    rmdir conftest
7980    $rm conftest*
7981
7982 fi
7983 echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5
7984 echo "${ECHO_T}$lt_cv_prog_compiler_c_o" >&6
7985
7986
7987 hard_links="nottested"
7988 if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
7989   # do not overwrite the value of need_locks provided by the user
7990   echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
7991 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6
7992   hard_links=yes
7993   $rm conftest*
7994   ln conftest.a conftest.b 2>/dev/null && hard_links=no
7995   touch conftest.a
7996   ln conftest.a conftest.b 2>&5 || hard_links=no
7997   ln conftest.a conftest.b 2>/dev/null && hard_links=no
7998   echo "$as_me:$LINENO: result: $hard_links" >&5
7999 echo "${ECHO_T}$hard_links" >&6
8000   if test "$hard_links" = no; then
8001     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
8002 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
8003     need_locks=warn
8004   fi
8005 else
8006   need_locks=no
8007 fi
8008
8009 echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
8010 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6
8011
8012   runpath_var=
8013   allow_undefined_flag=
8014   enable_shared_with_static_runtimes=no
8015   archive_cmds=
8016   archive_expsym_cmds=
8017   old_archive_From_new_cmds=
8018   old_archive_from_expsyms_cmds=
8019   export_dynamic_flag_spec=
8020   whole_archive_flag_spec=
8021   thread_safe_flag_spec=
8022   hardcode_libdir_flag_spec=
8023   hardcode_libdir_flag_spec_ld=
8024   hardcode_libdir_separator=
8025   hardcode_direct=no
8026   hardcode_minus_L=no
8027   hardcode_shlibpath_var=unsupported
8028   link_all_deplibs=unknown
8029   hardcode_automatic=no
8030   module_cmds=
8031   module_expsym_cmds=
8032   always_export_symbols=no
8033   export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
8034   # include_expsyms should be a list of space-separated symbols to be *always*
8035   # included in the symbol list
8036   include_expsyms=
8037   # exclude_expsyms can be an extended regexp of symbols to exclude
8038   # it will be wrapped by ` (' and `)$', so one must not match beginning or
8039   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
8040   # as well as any symbol that contains `d'.
8041   exclude_expsyms="_GLOBAL_OFFSET_TABLE_"
8042   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
8043   # platforms (ab)use it in PIC code, but their linkers get confused if
8044   # the symbol is explicitly referenced.  Since portable code cannot
8045   # rely on this symbol name, it's probably fine to never include it in
8046   # preloaded symbol tables.
8047   extract_expsyms_cmds=
8048   # Just being paranoid about ensuring that cc_basename is set.
8049   for cc_temp in $compiler""; do
8050   case $cc_temp in
8051     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
8052     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
8053     \-*) ;;
8054     *) break;;
8055   esac
8056 done
8057 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
8058
8059   case $host_os in
8060   cygwin* | mingw* | pw32*)
8061     # FIXME: the MSVC++ port hasn't been tested in a loooong time
8062     # When not using gcc, we currently assume that we are using
8063     # Microsoft Visual C++.
8064     if test "$GCC" != yes; then
8065       with_gnu_ld=no
8066     fi
8067     ;;
8068   openbsd*)
8069     with_gnu_ld=no
8070     ;;
8071   esac
8072
8073   ld_shlibs=yes
8074   if test "$with_gnu_ld" = yes; then
8075     # If archive_cmds runs LD, not CC, wlarc should be empty
8076     wlarc='${wl}'
8077
8078     # Set some defaults for GNU ld with shared library support. These
8079     # are reset later if shared libraries are not supported. Putting them
8080     # here allows them to be overridden if necessary.
8081     runpath_var=LD_RUN_PATH
8082     hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir'
8083     export_dynamic_flag_spec='${wl}--export-dynamic'
8084     # ancient GNU ld didn't support --whole-archive et. al.
8085     if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
8086         whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
8087       else
8088         whole_archive_flag_spec=
8089     fi
8090     supports_anon_versioning=no
8091     case `$LD -v 2>/dev/null` in
8092       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
8093       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
8094       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
8095       *\ 2.11.*) ;; # other 2.11 versions
8096       *) supports_anon_versioning=yes ;;
8097     esac
8098
8099     # See if GNU ld supports shared libraries.
8100     case $host_os in
8101     aix3* | aix4* | aix5*)
8102       # On AIX/PPC, the GNU linker is very broken
8103       if test "$host_cpu" != ia64; then
8104         ld_shlibs=no
8105         cat <<EOF 1>&2
8106
8107 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
8108 *** to be unable to reliably create shared libraries on AIX.
8109 *** Therefore, libtool is disabling shared libraries support.  If you
8110 *** really care for shared libraries, you may want to modify your PATH
8111 *** so that a non-GNU linker is found, and then restart.
8112
8113 EOF
8114       fi
8115       ;;
8116
8117     amigaos*)
8118       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)'
8119       hardcode_libdir_flag_spec='-L$libdir'
8120       hardcode_minus_L=yes
8121
8122       # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
8123       # that the semantics of dynamic libraries on AmigaOS, at least up
8124       # to version 4, is to share data among multiple programs linked
8125       # with the same dynamic library.  Since this doesn't match the
8126       # behavior of shared libraries on other platforms, we can't use
8127       # them.
8128       ld_shlibs=no
8129       ;;
8130
8131     beos*)
8132       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8133         allow_undefined_flag=unsupported
8134         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
8135         # support --undefined.  This deserves some investigation.  FIXME
8136         archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8137       else
8138         ld_shlibs=no
8139       fi
8140       ;;
8141
8142     cygwin* | mingw* | pw32*)
8143       # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
8144       # as there is no search path for DLLs.
8145       hardcode_libdir_flag_spec='-L$libdir'
8146       allow_undefined_flag=unsupported
8147       always_export_symbols=no
8148       enable_shared_with_static_runtimes=yes
8149       export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols'
8150
8151       if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
8152         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
8153         # If the export-symbols file already is a .def file (1st line
8154         # is EXPORTS), use it as is; otherwise, prepend...
8155         archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
8156           cp $export_symbols $output_objdir/$soname.def;
8157         else
8158           echo EXPORTS > $output_objdir/$soname.def;
8159           cat $export_symbols >> $output_objdir/$soname.def;
8160         fi~
8161         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000  ${wl}--out-implib,$lib'
8162       else
8163         ld_shlibs=no
8164       fi
8165       ;;
8166
8167     linux*)
8168       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8169         tmp_addflag=
8170         case $cc_basename,$host_cpu in
8171         pgcc*)                          # Portland Group C compiler
8172           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'
8173           tmp_addflag=' $pic_flag'
8174           ;;
8175         pgf77* | pgf90* | pgf95*)       # Portland Group f77 and f90 compilers
8176           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'
8177           tmp_addflag=' $pic_flag -Mnomain' ;;
8178         ecc*,ia64* | icc*,ia64*)                # Intel C compiler on ia64
8179           tmp_addflag=' -i_dynamic' ;;
8180         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
8181           tmp_addflag=' -i_dynamic -nofor_main' ;;
8182         ifc* | ifort*)                  # Intel Fortran compiler
8183           tmp_addflag=' -nofor_main' ;;
8184         esac
8185         archive_cmds='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8186
8187         if test $supports_anon_versioning = yes; then
8188           archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~
8189   cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
8190   $echo "local: *; };" >> $output_objdir/$libname.ver~
8191           $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
8192         fi
8193       else
8194         ld_shlibs=no
8195       fi
8196       ;;
8197
8198     netbsd*)
8199       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
8200         archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
8201         wlarc=
8202       else
8203         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8204         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8205       fi
8206       ;;
8207
8208     solaris* | sysv5*)
8209       if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
8210         ld_shlibs=no
8211         cat <<EOF 1>&2
8212
8213 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
8214 *** create shared libraries on Solaris systems.  Therefore, libtool
8215 *** is disabling shared libraries support.  We urge you to upgrade GNU
8216 *** binutils to release 2.9.1 or newer.  Another option is to modify
8217 *** your PATH or compiler configuration so that the native linker is
8218 *** used, and then restart.
8219
8220 EOF
8221       elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8222         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8223         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8224       else
8225         ld_shlibs=no
8226       fi
8227       ;;
8228
8229     sunos4*)
8230       archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8231       wlarc=
8232       hardcode_direct=yes
8233       hardcode_shlibpath_var=no
8234       ;;
8235
8236     *)
8237       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
8238         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8239         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8240       else
8241         ld_shlibs=no
8242       fi
8243       ;;
8244     esac
8245
8246     if test "$ld_shlibs" = no; then
8247       runpath_var=
8248       hardcode_libdir_flag_spec=
8249       export_dynamic_flag_spec=
8250       whole_archive_flag_spec=
8251     fi
8252   else
8253     # PORTME fill in a description of your system's linker (not GNU ld)
8254     case $host_os in
8255     aix3*)
8256       allow_undefined_flag=unsupported
8257       always_export_symbols=yes
8258       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'
8259       # Note: this linker hardcodes the directories in LIBPATH if there
8260       # are no directories specified by -L.
8261       hardcode_minus_L=yes
8262       if test "$GCC" = yes && test -z "$link_static_flag"; then
8263         # Neither direct hardcoding nor static linking is supported with a
8264         # broken collect2.
8265         hardcode_direct=unsupported
8266       fi
8267       ;;
8268
8269     aix4* | aix5*)
8270       if test "$host_cpu" = ia64; then
8271         # On IA64, the linker does run time linking by default, so we don't
8272         # have to do anything special.
8273         aix_use_runtimelinking=no
8274         exp_sym_flag='-Bexport'
8275         no_entry_flag=""
8276       else
8277         # If we're using GNU nm, then we don't want the "-C" option.
8278         # -C means demangle to AIX nm, but means don't demangle with GNU nm
8279         if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
8280           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'
8281         else
8282           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'
8283         fi
8284         aix_use_runtimelinking=no
8285
8286         # Test if we are trying to use run time linking or normal
8287         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
8288         # need to do runtime linking.
8289         case $host_os in aix4.[23]|aix4.[23].*|aix5*)
8290           for ld_flag in $LDFLAGS; do
8291           if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
8292             aix_use_runtimelinking=yes
8293             break
8294           fi
8295           done
8296         esac
8297
8298         exp_sym_flag='-bexport'
8299         no_entry_flag='-bnoentry'
8300       fi
8301
8302       # When large executables or shared objects are built, AIX ld can
8303       # have problems creating the table of contents.  If linking a library
8304       # or program results in "error TOC overflow" add -mminimal-toc to
8305       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
8306       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
8307
8308       archive_cmds=''
8309       hardcode_direct=yes
8310       hardcode_libdir_separator=':'
8311       link_all_deplibs=yes
8312
8313       if test "$GCC" = yes; then
8314         case $host_os in aix4.[012]|aix4.[012].*)
8315         # We only want to do this on AIX 4.2 and lower, the check
8316         # below for broken collect2 doesn't work under 4.3+
8317           collect2name=`${CC} -print-prog-name=collect2`
8318           if test -f "$collect2name" && \
8319            strings "$collect2name" | grep resolve_lib_name >/dev/null
8320           then
8321           # We have reworked collect2
8322           hardcode_direct=yes
8323           else
8324           # We have old collect2
8325           hardcode_direct=unsupported
8326           # It fails to find uninstalled libraries when the uninstalled
8327           # path is not listed in the libpath.  Setting hardcode_minus_L
8328           # to unsupported forces relinking
8329           hardcode_minus_L=yes
8330           hardcode_libdir_flag_spec='-L$libdir'
8331           hardcode_libdir_separator=
8332           fi
8333         esac
8334         shared_flag='-shared'
8335         if test "$aix_use_runtimelinking" = yes; then
8336           shared_flag="$shared_flag "'${wl}-G'
8337         fi
8338       else
8339         # not using gcc
8340         if test "$host_cpu" = ia64; then
8341         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
8342         # chokes on -Wl,-G. The following line is correct:
8343           shared_flag='-G'
8344         else
8345         if test "$aix_use_runtimelinking" = yes; then
8346             shared_flag='${wl}-G'
8347           else
8348             shared_flag='${wl}-bM:SRE'
8349         fi
8350         fi
8351       fi
8352
8353       # It seems that -bexpall does not export symbols beginning with
8354       # underscore (_), so it is better to generate a list of symbols to export.
8355       always_export_symbols=yes
8356       if test "$aix_use_runtimelinking" = yes; then
8357         # Warning - without using the other runtime loading flags (-brtl),
8358         # -berok will link without error, but may produce a broken library.
8359         allow_undefined_flag='-berok'
8360        # Determine the default libpath from the value encoded in an empty executable.
8361        cat >conftest.$ac_ext <<_ACEOF
8362 /* confdefs.h.  */
8363 _ACEOF
8364 cat confdefs.h >>conftest.$ac_ext
8365 cat >>conftest.$ac_ext <<_ACEOF
8366 /* end confdefs.h.  */
8367
8368 int
8369 main ()
8370 {
8371
8372   ;
8373   return 0;
8374 }
8375 _ACEOF
8376 rm -f conftest.$ac_objext conftest$ac_exeext
8377 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8378   (eval $ac_link) 2>conftest.er1
8379   ac_status=$?
8380   grep -v '^ *+' conftest.er1 >conftest.err
8381   rm -f conftest.er1
8382   cat conftest.err >&5
8383   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8384   (exit $ac_status); } &&
8385          { ac_try='test -z "$ac_c_werror_flag"
8386                          || test ! -s conftest.err'
8387   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8388   (eval $ac_try) 2>&5
8389   ac_status=$?
8390   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8391   (exit $ac_status); }; } &&
8392          { ac_try='test -s conftest$ac_exeext'
8393   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8394   (eval $ac_try) 2>&5
8395   ac_status=$?
8396   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8397   (exit $ac_status); }; }; then
8398
8399 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
8400 }'`
8401 # Check for a 64-bit object if we didn't find anything.
8402 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; }
8403 }'`; fi
8404 else
8405   echo "$as_me: failed program was:" >&5
8406 sed 's/^/| /' conftest.$ac_ext >&5
8407
8408 fi
8409 rm -f conftest.err conftest.$ac_objext \
8410       conftest$ac_exeext conftest.$ac_ext
8411 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
8412
8413        hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
8414         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"
8415        else
8416         if test "$host_cpu" = ia64; then
8417           hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
8418           allow_undefined_flag="-z nodefs"
8419           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"
8420         else
8421          # Determine the default libpath from the value encoded in an empty executable.
8422          cat >conftest.$ac_ext <<_ACEOF
8423 /* confdefs.h.  */
8424 _ACEOF
8425 cat confdefs.h >>conftest.$ac_ext
8426 cat >>conftest.$ac_ext <<_ACEOF
8427 /* end confdefs.h.  */
8428
8429 int
8430 main ()
8431 {
8432
8433   ;
8434   return 0;
8435 }
8436 _ACEOF
8437 rm -f conftest.$ac_objext conftest$ac_exeext
8438 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8439   (eval $ac_link) 2>conftest.er1
8440   ac_status=$?
8441   grep -v '^ *+' conftest.er1 >conftest.err
8442   rm -f conftest.er1
8443   cat conftest.err >&5
8444   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8445   (exit $ac_status); } &&
8446          { ac_try='test -z "$ac_c_werror_flag"
8447                          || test ! -s conftest.err'
8448   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8449   (eval $ac_try) 2>&5
8450   ac_status=$?
8451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8452   (exit $ac_status); }; } &&
8453          { ac_try='test -s conftest$ac_exeext'
8454   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8455   (eval $ac_try) 2>&5
8456   ac_status=$?
8457   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8458   (exit $ac_status); }; }; then
8459
8460 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
8461 }'`
8462 # Check for a 64-bit object if we didn't find anything.
8463 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; }
8464 }'`; fi
8465 else
8466   echo "$as_me: failed program was:" >&5
8467 sed 's/^/| /' conftest.$ac_ext >&5
8468
8469 fi
8470 rm -f conftest.err conftest.$ac_objext \
8471       conftest$ac_exeext conftest.$ac_ext
8472 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
8473
8474          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
8475           # Warning - without using the other run time loading flags,
8476           # -berok will link without error, but may produce a broken library.
8477           no_undefined_flag=' ${wl}-bernotok'
8478           allow_undefined_flag=' ${wl}-berok'
8479           # -bexpall does not export symbols beginning with underscore (_)
8480           always_export_symbols=yes
8481           # Exported symbols can be pulled into shared objects from archives
8482           whole_archive_flag_spec=' '
8483           archive_cmds_need_lc=yes
8484           # This is similar to how AIX traditionally builds its shared libraries.
8485           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'
8486         fi
8487       fi
8488       ;;
8489
8490     amigaos*)
8491       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)'
8492       hardcode_libdir_flag_spec='-L$libdir'
8493       hardcode_minus_L=yes
8494       # see comment about different semantics on the GNU ld section
8495       ld_shlibs=no
8496       ;;
8497
8498     bsdi[45]*)
8499       export_dynamic_flag_spec=-rdynamic
8500       ;;
8501
8502     cygwin* | mingw* | pw32*)
8503       # When not using gcc, we currently assume that we are using
8504       # Microsoft Visual C++.
8505       # hardcode_libdir_flag_spec is actually meaningless, as there is
8506       # no search path for DLLs.
8507       hardcode_libdir_flag_spec=' '
8508       allow_undefined_flag=unsupported
8509       # Tell ltmain to make .lib files, not .a files.
8510       libext=lib
8511       # Tell ltmain to make .dll files, not .so files.
8512       shrext_cmds=".dll"
8513       # FIXME: Setting linknames here is a bad hack.
8514       archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
8515       # The linker will automatically build a .lib file if we build a DLL.
8516       old_archive_From_new_cmds='true'
8517       # FIXME: Should let the user specify the lib program.
8518       old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs'
8519       fix_srcfile_path='`cygpath -w "$srcfile"`'
8520       enable_shared_with_static_runtimes=yes
8521       ;;
8522
8523     darwin* | rhapsody*)
8524       case $host_os in
8525         rhapsody* | darwin1.[012])
8526          allow_undefined_flag='${wl}-undefined ${wl}suppress'
8527          ;;
8528        *) # Darwin 1.3 on
8529          if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
8530            allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
8531          else
8532            case ${MACOSX_DEPLOYMENT_TARGET} in
8533              10.[012])
8534                allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
8535                ;;
8536              10.*)
8537                allow_undefined_flag='${wl}-undefined ${wl}dynamic_lookup'
8538                ;;
8539            esac
8540          fi
8541          ;;
8542       esac
8543       archive_cmds_need_lc=no
8544       hardcode_direct=no
8545       hardcode_automatic=yes
8546       hardcode_shlibpath_var=unsupported
8547       whole_archive_flag_spec=''
8548       link_all_deplibs=yes
8549     if test "$GCC" = yes ; then
8550         output_verbose_link_cmd='echo'
8551         archive_cmds='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
8552       module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
8553       # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
8554       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}'
8555       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}'
8556     else
8557       case $cc_basename in
8558         xlc*)
8559          output_verbose_link_cmd='echo'
8560          archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
8561          module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
8562           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
8563          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}'
8564           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}'
8565           ;;
8566        *)
8567          ld_shlibs=no
8568           ;;
8569       esac
8570     fi
8571       ;;
8572
8573     dgux*)
8574       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8575       hardcode_libdir_flag_spec='-L$libdir'
8576       hardcode_shlibpath_var=no
8577       ;;
8578
8579     freebsd1*)
8580       ld_shlibs=no
8581       ;;
8582
8583     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
8584     # support.  Future versions do this automatically, but an explicit c++rt0.o
8585     # does not break anything, and helps significantly (at the cost of a little
8586     # extra space).
8587     freebsd2.2*)
8588       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
8589       hardcode_libdir_flag_spec='-R$libdir'
8590       hardcode_direct=yes
8591       hardcode_shlibpath_var=no
8592       ;;
8593
8594     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
8595     freebsd2*)
8596       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8597       hardcode_direct=yes
8598       hardcode_minus_L=yes
8599       hardcode_shlibpath_var=no
8600       ;;
8601
8602     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
8603     freebsd* | kfreebsd*-gnu | dragonfly*)
8604       archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
8605       hardcode_libdir_flag_spec='-R$libdir'
8606       hardcode_direct=yes
8607       hardcode_shlibpath_var=no
8608       ;;
8609
8610     hpux9*)
8611       if test "$GCC" = yes; then
8612         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'
8613       else
8614         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'
8615       fi
8616       hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8617       hardcode_libdir_separator=:
8618       hardcode_direct=yes
8619
8620       # hardcode_minus_L: Not really in the search PATH,
8621       # but as the default location of the library.
8622       hardcode_minus_L=yes
8623       export_dynamic_flag_spec='${wl}-E'
8624       ;;
8625
8626     hpux10* | hpux11*)
8627       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
8628         case $host_cpu in
8629         hppa*64*|ia64*)
8630           archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8631           ;;
8632         *)
8633           archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
8634           ;;
8635         esac
8636       else
8637         case $host_cpu in
8638         hppa*64*|ia64*)
8639           archive_cmds='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags'
8640           ;;
8641         *)
8642           archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
8643           ;;
8644         esac
8645       fi
8646       if test "$with_gnu_ld" = no; then
8647         case $host_cpu in
8648         hppa*64*)
8649           hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8650           hardcode_libdir_flag_spec_ld='+b $libdir'
8651           hardcode_libdir_separator=:
8652           hardcode_direct=no
8653           hardcode_shlibpath_var=no
8654           ;;
8655         ia64*)
8656           hardcode_libdir_flag_spec='-L$libdir'
8657           hardcode_direct=no
8658           hardcode_shlibpath_var=no
8659
8660           # hardcode_minus_L: Not really in the search PATH,
8661           # but as the default location of the library.
8662           hardcode_minus_L=yes
8663           ;;
8664         *)
8665           hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
8666           hardcode_libdir_separator=:
8667           hardcode_direct=yes
8668           export_dynamic_flag_spec='${wl}-E'
8669
8670           # hardcode_minus_L: Not really in the search PATH,
8671           # but as the default location of the library.
8672           hardcode_minus_L=yes
8673           ;;
8674         esac
8675       fi
8676       ;;
8677
8678     irix5* | irix6* | nonstopux*)
8679       if test "$GCC" = yes; then
8680         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'
8681       else
8682         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'
8683         hardcode_libdir_flag_spec_ld='-rpath $libdir'
8684       fi
8685       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8686       hardcode_libdir_separator=:
8687       link_all_deplibs=yes
8688       ;;
8689
8690     netbsd*)
8691       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
8692         archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
8693       else
8694         archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
8695       fi
8696       hardcode_libdir_flag_spec='-R$libdir'
8697       hardcode_direct=yes
8698       hardcode_shlibpath_var=no
8699       ;;
8700
8701     newsos6)
8702       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8703       hardcode_direct=yes
8704       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8705       hardcode_libdir_separator=:
8706       hardcode_shlibpath_var=no
8707       ;;
8708
8709     openbsd*)
8710       hardcode_direct=yes
8711       hardcode_shlibpath_var=no
8712       if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
8713         archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8714         archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
8715         hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8716         export_dynamic_flag_spec='${wl}-E'
8717       else
8718        case $host_os in
8719          openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
8720            archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8721            hardcode_libdir_flag_spec='-R$libdir'
8722            ;;
8723          *)
8724            archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
8725            hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8726            ;;
8727        esac
8728       fi
8729       ;;
8730
8731     os2*)
8732       hardcode_libdir_flag_spec='-L$libdir'
8733       hardcode_minus_L=yes
8734       allow_undefined_flag=unsupported
8735       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'
8736       old_archive_From_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
8737       ;;
8738
8739     osf3*)
8740       if test "$GCC" = yes; then
8741         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
8742         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'
8743       else
8744         allow_undefined_flag=' -expect_unresolved \*'
8745         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'
8746       fi
8747       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8748       hardcode_libdir_separator=:
8749       ;;
8750
8751     osf4* | osf5*)      # as osf3* with the addition of -msym flag
8752       if test "$GCC" = yes; then
8753         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
8754         archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
8755         hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8756       else
8757         allow_undefined_flag=' -expect_unresolved \*'
8758         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'
8759         archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
8760         $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'
8761
8762         # Both c and cxx compiler support -rpath directly
8763         hardcode_libdir_flag_spec='-rpath $libdir'
8764       fi
8765       hardcode_libdir_separator=:
8766       ;;
8767
8768     sco3.2v5*)
8769       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8770       hardcode_shlibpath_var=no
8771       export_dynamic_flag_spec='${wl}-Bexport'
8772       runpath_var=LD_RUN_PATH
8773       hardcode_runpath_var=yes
8774       ;;
8775
8776     solaris*)
8777       no_undefined_flag=' -z text'
8778       if test "$GCC" = yes; then
8779         wlarc='${wl}'
8780         archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8781         archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8782           $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
8783       else
8784         wlarc=''
8785         archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
8786         archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8787         $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
8788       fi
8789       hardcode_libdir_flag_spec='-R$libdir'
8790       hardcode_shlibpath_var=no
8791       case $host_os in
8792       solaris2.[0-5] | solaris2.[0-5].*) ;;
8793       *)
8794         # The compiler driver will combine linker options so we
8795         # cannot just pass the convience library names through
8796         # without $wl, iff we do not link with $LD.
8797         # Luckily, gcc supports the same syntax we need for Sun Studio.
8798         # Supported since Solaris 2.6 (maybe 2.5.1?)
8799         case $wlarc in
8800         '')
8801           whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;;
8802         *)
8803           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' ;;
8804         esac ;;
8805       esac
8806       link_all_deplibs=yes
8807       ;;
8808
8809     sunos4*)
8810       if test "x$host_vendor" = xsequent; then
8811         # Use $CC to link under sequent, because it throws in some extra .o
8812         # files that make .init and .fini sections work.
8813         archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
8814       else
8815         archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
8816       fi
8817       hardcode_libdir_flag_spec='-L$libdir'
8818       hardcode_direct=yes
8819       hardcode_minus_L=yes
8820       hardcode_shlibpath_var=no
8821       ;;
8822
8823     sysv4)
8824       case $host_vendor in
8825         sni)
8826           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8827           hardcode_direct=yes # is this really true???
8828         ;;
8829         siemens)
8830           ## LD is ld it makes a PLAMLIB
8831           ## CC just makes a GrossModule.
8832           archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
8833           reload_cmds='$CC -r -o $output$reload_objs'
8834           hardcode_direct=no
8835         ;;
8836         motorola)
8837           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8838           hardcode_direct=no #Motorola manual says yes, but my tests say they lie
8839         ;;
8840       esac
8841       runpath_var='LD_RUN_PATH'
8842       hardcode_shlibpath_var=no
8843       ;;
8844
8845     sysv4.3*)
8846       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8847       hardcode_shlibpath_var=no
8848       export_dynamic_flag_spec='-Bexport'
8849       ;;
8850
8851     sysv4*MP*)
8852       if test -d /usr/nec; then
8853         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8854         hardcode_shlibpath_var=no
8855         runpath_var=LD_RUN_PATH
8856         hardcode_runpath_var=yes
8857         ld_shlibs=yes
8858       fi
8859       ;;
8860
8861     sysv4.2uw2*)
8862       archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
8863       hardcode_direct=yes
8864       hardcode_minus_L=no
8865       hardcode_shlibpath_var=no
8866       hardcode_runpath_var=yes
8867       runpath_var=LD_RUN_PATH
8868       ;;
8869
8870    sysv5OpenUNIX8* | sysv5UnixWare7* |  sysv5uw[78]* | unixware7*)
8871       no_undefined_flag='${wl}-z ${wl}text'
8872       if test "$GCC" = yes; then
8873         archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8874       else
8875         archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
8876       fi
8877       runpath_var='LD_RUN_PATH'
8878       hardcode_shlibpath_var=no
8879       ;;
8880
8881     sysv5*)
8882       no_undefined_flag=' -z text'
8883       # $CC -shared without GNU ld will not create a library from C++
8884       # object files and a static libstdc++, better avoid it by now
8885       archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
8886       archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8887                 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
8888       hardcode_libdir_flag_spec=
8889       hardcode_shlibpath_var=no
8890       runpath_var='LD_RUN_PATH'
8891       ;;
8892
8893     uts4*)
8894       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
8895       hardcode_libdir_flag_spec='-L$libdir'
8896       hardcode_shlibpath_var=no
8897       ;;
8898
8899     *)
8900       ld_shlibs=no
8901       ;;
8902     esac
8903   fi
8904
8905 echo "$as_me:$LINENO: result: $ld_shlibs" >&5
8906 echo "${ECHO_T}$ld_shlibs" >&6
8907 test "$ld_shlibs" = no && can_build_shared=no
8908
8909 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
8910 if test "$GCC" = yes; then
8911   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
8912 fi
8913
8914 #
8915 # Do we need to explicitly link libc?
8916 #
8917 case "x$archive_cmds_need_lc" in
8918 x|xyes)
8919   # Assume -lc should be added
8920   archive_cmds_need_lc=yes
8921
8922   if test "$enable_shared" = yes && test "$GCC" = yes; then
8923     case $archive_cmds in
8924     *'~'*)
8925       # FIXME: we may have to deal with multi-command sequences.
8926       ;;
8927     '$CC '*)
8928       # Test whether the compiler implicitly links with -lc since on some
8929       # systems, -lgcc has to come before -lc. If gcc already passes -lc
8930       # to ld, don't add -lc before -lgcc.
8931       echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
8932 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6
8933       $rm conftest*
8934       printf "$lt_simple_compile_test_code" > conftest.$ac_ext
8935
8936       if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8937   (eval $ac_compile) 2>&5
8938   ac_status=$?
8939   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8940   (exit $ac_status); } 2>conftest.err; then
8941         soname=conftest
8942         lib=conftest
8943         libobjs=conftest.$ac_objext
8944         deplibs=
8945         wl=$lt_prog_compiler_wl
8946         compiler_flags=-v
8947         linker_flags=-v
8948         verstring=
8949         output_objdir=.
8950         libname=conftest
8951         lt_save_allow_undefined_flag=$allow_undefined_flag
8952         allow_undefined_flag=
8953         if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5
8954   (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5
8955   ac_status=$?
8956   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8957   (exit $ac_status); }
8958         then
8959           archive_cmds_need_lc=no
8960         else
8961           archive_cmds_need_lc=yes
8962         fi
8963         allow_undefined_flag=$lt_save_allow_undefined_flag
8964       else
8965         cat conftest.err 1>&5
8966       fi
8967       $rm conftest*
8968       echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5
8969 echo "${ECHO_T}$archive_cmds_need_lc" >&6
8970       ;;
8971     esac
8972   fi
8973   ;;
8974 esac
8975
8976 echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
8977 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6
8978 library_names_spec=
8979 libname_spec='lib$name'
8980 soname_spec=
8981 shrext_cmds=".so"
8982 postinstall_cmds=
8983 postuninstall_cmds=
8984 finish_cmds=
8985 finish_eval=
8986 shlibpath_var=
8987 shlibpath_overrides_runpath=unknown
8988 version_type=none
8989 dynamic_linker="$host_os ld.so"
8990 sys_lib_dlsearch_path_spec="/lib /usr/lib"
8991 if test "$GCC" = yes; then
8992   sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
8993   if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
8994     # if the path contains ";" then we assume it to be the separator
8995     # otherwise default to the standard path separator (i.e. ":") - it is
8996     # assumed that no part of a normal pathname contains ";" but that should
8997     # okay in the real world where ";" in dirpaths is itself problematic.
8998     sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
8999   else
9000     sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
9001   fi
9002 else
9003   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
9004 fi
9005 need_lib_prefix=unknown
9006 hardcode_into_libs=no
9007
9008 # when you set need_version to no, make sure it does not cause -set_version
9009 # flags to be left without arguments
9010 need_version=unknown
9011
9012 case $host_os in
9013 aix3*)
9014   version_type=linux
9015   library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
9016   shlibpath_var=LIBPATH
9017
9018   # AIX 3 has no versioning support, so we append a major version to the name.
9019   soname_spec='${libname}${release}${shared_ext}$major'
9020   ;;
9021
9022 aix4* | aix5*)
9023   version_type=linux
9024   need_lib_prefix=no
9025   need_version=no
9026   hardcode_into_libs=yes
9027   if test "$host_cpu" = ia64; then
9028     # AIX 5 supports IA64
9029     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
9030     shlibpath_var=LD_LIBRARY_PATH
9031   else
9032     # With GCC up to 2.95.x, collect2 would create an import file
9033     # for dependence libraries.  The import file would start with
9034     # the line `#! .'.  This would cause the generated library to
9035     # depend on `.', always an invalid library.  This was fixed in
9036     # development snapshots of GCC prior to 3.0.
9037     case $host_os in
9038       aix4 | aix4.[01] | aix4.[01].*)
9039       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
9040            echo ' yes '
9041            echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
9042         :
9043       else
9044         can_build_shared=no
9045       fi
9046       ;;
9047     esac
9048     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
9049     # soname into executable. Probably we can add versioning support to
9050     # collect2, so additional links can be useful in future.
9051     if test "$aix_use_runtimelinking" = yes; then
9052       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
9053       # instead of lib<name>.a to let people know that these are not
9054       # typical AIX shared libraries.
9055       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9056     else
9057       # We preserve .a as extension for shared libraries through AIX4.2
9058       # and later when we are not doing run time linking.
9059       library_names_spec='${libname}${release}.a $libname.a'
9060       soname_spec='${libname}${release}${shared_ext}$major'
9061     fi
9062     shlibpath_var=LIBPATH
9063   fi
9064   ;;
9065
9066 amigaos*)
9067   library_names_spec='$libname.ixlibrary $libname.a'
9068   # Create ${libname}_ixlibrary.a entries in /sys/libs.
9069   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'
9070   ;;
9071
9072 beos*)
9073   library_names_spec='${libname}${shared_ext}'
9074   dynamic_linker="$host_os ld.so"
9075   shlibpath_var=LIBRARY_PATH
9076   ;;
9077
9078 bsdi[45]*)
9079   version_type=linux
9080   need_version=no
9081   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9082   soname_spec='${libname}${release}${shared_ext}$major'
9083   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
9084   shlibpath_var=LD_LIBRARY_PATH
9085   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
9086   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
9087   # the default ld.so.conf also contains /usr/contrib/lib and
9088   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
9089   # libtool to hard-code these into programs
9090   ;;
9091
9092 cygwin* | mingw* | pw32*)
9093   version_type=windows
9094   shrext_cmds=".dll"
9095   need_version=no
9096   need_lib_prefix=no
9097
9098   case $GCC,$host_os in
9099   yes,cygwin* | yes,mingw* | yes,pw32*)
9100     library_names_spec='$libname.dll.a'
9101     # DLL is installed to $(libdir)/../bin by postinstall_cmds
9102     postinstall_cmds='base_file=`basename \${file}`~
9103       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
9104       dldir=$destdir/`dirname \$dlpath`~
9105       test -d \$dldir || mkdir -p \$dldir~
9106       $install_prog $dir/$dlname \$dldir/$dlname~
9107       chmod a+x \$dldir/$dlname'
9108     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
9109       dlpath=$dir/\$dldll~
9110        $rm \$dlpath'
9111     shlibpath_overrides_runpath=yes
9112
9113     case $host_os in
9114     cygwin*)
9115       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
9116       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9117       sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
9118       ;;
9119     mingw*)
9120       # MinGW DLLs use traditional 'lib' prefix
9121       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9122       sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
9123       if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then
9124         # It is most probably a Windows format PATH printed by
9125         # mingw gcc, but we are running on Cygwin. Gcc prints its search
9126         # path with ; separators, and with drive letters. We can handle the
9127         # drive letters (cygwin fileutils understands them), so leave them,
9128         # especially as we might pass files found there to a mingw objdump,
9129         # which wouldn't understand a cygwinified path. Ahh.
9130         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
9131       else
9132         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
9133       fi
9134       ;;
9135     pw32*)
9136       # pw32 DLLs use 'pw' prefix rather than 'lib'
9137       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9138       ;;
9139     esac
9140     ;;
9141
9142   *)
9143     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
9144     ;;
9145   esac
9146   dynamic_linker='Win32 ld.exe'
9147   # FIXME: first we should search . and the directory the executable is in
9148   shlibpath_var=PATH
9149   ;;
9150
9151 darwin* | rhapsody*)
9152   dynamic_linker="$host_os dyld"
9153   version_type=darwin
9154   need_lib_prefix=no
9155   need_version=no
9156   library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
9157   soname_spec='${libname}${release}${major}$shared_ext'
9158   shlibpath_overrides_runpath=yes
9159   shlibpath_var=DYLD_LIBRARY_PATH
9160   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
9161   # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
9162   if test "$GCC" = yes; then
9163     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"`
9164   else
9165     sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
9166   fi
9167   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
9168   ;;
9169
9170 dgux*)
9171   version_type=linux
9172   need_lib_prefix=no
9173   need_version=no
9174   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
9175   soname_spec='${libname}${release}${shared_ext}$major'
9176   shlibpath_var=LD_LIBRARY_PATH
9177   ;;
9178
9179 freebsd1*)
9180   dynamic_linker=no
9181   ;;
9182
9183 kfreebsd*-gnu)
9184   version_type=linux
9185   need_lib_prefix=no
9186   need_version=no
9187   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9188   soname_spec='${libname}${release}${shared_ext}$major'
9189   shlibpath_var=LD_LIBRARY_PATH
9190   shlibpath_overrides_runpath=no
9191   hardcode_into_libs=yes
9192   dynamic_linker='GNU ld.so'
9193   ;;
9194
9195 freebsd* | dragonfly*)
9196   # DragonFly does not have aout.  When/if they implement a new
9197   # versioning mechanism, adjust this.
9198   if test -x /usr/bin/objformat; then
9199     objformat=`/usr/bin/objformat`
9200   else
9201     case $host_os in
9202     freebsd[123]*) objformat=aout ;;
9203     *) objformat=elf ;;
9204     esac
9205   fi
9206   version_type=freebsd-$objformat
9207   case $version_type in
9208     freebsd-elf*)
9209       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
9210       need_version=no
9211       need_lib_prefix=no
9212       ;;
9213     freebsd-*)
9214       library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
9215       need_version=yes
9216       ;;
9217   esac
9218   shlibpath_var=LD_LIBRARY_PATH
9219   case $host_os in
9220   freebsd2*)
9221     shlibpath_overrides_runpath=yes
9222     ;;
9223   freebsd3.[01]* | freebsdelf3.[01]*)
9224     shlibpath_overrides_runpath=yes
9225     hardcode_into_libs=yes
9226     ;;
9227   *) # from 3.2 on
9228     shlibpath_overrides_runpath=no
9229     hardcode_into_libs=yes
9230     ;;
9231   esac
9232   ;;
9233
9234 gnu*)
9235   version_type=linux
9236   need_lib_prefix=no
9237   need_version=no
9238   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
9239   soname_spec='${libname}${release}${shared_ext}$major'
9240   shlibpath_var=LD_LIBRARY_PATH
9241   hardcode_into_libs=yes
9242   ;;
9243
9244 hpux9* | hpux10* | hpux11*)
9245   # Give a soname corresponding to the major version so that dld.sl refuses to
9246   # link against other versions.
9247   version_type=sunos
9248   need_lib_prefix=no
9249   need_version=no
9250   case $host_cpu in
9251   ia64*)
9252     shrext_cmds='.so'
9253     hardcode_into_libs=yes
9254     dynamic_linker="$host_os dld.so"
9255     shlibpath_var=LD_LIBRARY_PATH
9256     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
9257     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9258     soname_spec='${libname}${release}${shared_ext}$major'
9259     if test "X$HPUX_IA64_MODE" = X32; then
9260       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
9261     else
9262       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
9263     fi
9264     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
9265     ;;
9266    hppa*64*)
9267      shrext_cmds='.sl'
9268      hardcode_into_libs=yes
9269      dynamic_linker="$host_os dld.sl"
9270      shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
9271      shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
9272      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9273      soname_spec='${libname}${release}${shared_ext}$major'
9274      sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
9275      sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
9276      ;;
9277    *)
9278     shrext_cmds='.sl'
9279     dynamic_linker="$host_os dld.sl"
9280     shlibpath_var=SHLIB_PATH
9281     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
9282     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9283     soname_spec='${libname}${release}${shared_ext}$major'
9284     ;;
9285   esac
9286   # HP-UX runs *really* slowly unless shared libraries are mode 555.
9287   postinstall_cmds='chmod 555 $lib'
9288   ;;
9289
9290 irix5* | irix6* | nonstopux*)
9291   case $host_os in
9292     nonstopux*) version_type=nonstopux ;;
9293     *)
9294         if test "$lt_cv_prog_gnu_ld" = yes; then
9295                 version_type=linux
9296         else
9297                 version_type=irix
9298         fi ;;
9299   esac
9300   need_lib_prefix=no
9301   need_version=no
9302   soname_spec='${libname}${release}${shared_ext}$major'
9303   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
9304   case $host_os in
9305   irix5* | nonstopux*)
9306     libsuff= shlibsuff=
9307     ;;
9308   *)
9309     case $LD in # libtool.m4 will add one of these switches to LD
9310     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
9311       libsuff= shlibsuff= libmagic=32-bit;;
9312     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
9313       libsuff=32 shlibsuff=N32 libmagic=N32;;
9314     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
9315       libsuff=64 shlibsuff=64 libmagic=64-bit;;
9316     *) libsuff= shlibsuff= libmagic=never-match;;
9317     esac
9318     ;;
9319   esac
9320   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
9321   shlibpath_overrides_runpath=no
9322   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
9323   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
9324   hardcode_into_libs=yes
9325   ;;
9326
9327 # No shared lib support for Linux oldld, aout, or coff.
9328 linux*oldld* | linux*aout* | linux*coff*)
9329   dynamic_linker=no
9330   ;;
9331
9332 # This must be Linux ELF.
9333 linux*)
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   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
9340   shlibpath_var=LD_LIBRARY_PATH
9341   shlibpath_overrides_runpath=no
9342   # This implies no fast_install, which is unacceptable.
9343   # Some rework will be needed to allow for fast_install
9344   # before this can be enabled.
9345   hardcode_into_libs=yes
9346
9347   # Append ld.so.conf contents to the search path
9348   if test -f /etc/ld.so.conf; then
9349     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' ' '`
9350     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
9351   fi
9352
9353   # We used to test for /lib/ld.so.1 and disable shared libraries on
9354   # powerpc, because MkLinux only supported shared libraries with the
9355   # GNU dynamic linker.  Since this was broken with cross compilers,
9356   # most powerpc-linux boxes support dynamic linking these days and
9357   # people can always --disable-shared, the test was removed, and we
9358   # assume the GNU/Linux dynamic linker is in use.
9359   dynamic_linker='GNU/Linux ld.so'
9360   ;;
9361
9362 knetbsd*-gnu)
9363   version_type=linux
9364   need_lib_prefix=no
9365   need_version=no
9366   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9367   soname_spec='${libname}${release}${shared_ext}$major'
9368   shlibpath_var=LD_LIBRARY_PATH
9369   shlibpath_overrides_runpath=no
9370   hardcode_into_libs=yes
9371   dynamic_linker='GNU ld.so'
9372   ;;
9373
9374 netbsd*)
9375   version_type=sunos
9376   need_lib_prefix=no
9377   need_version=no
9378   if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
9379     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9380     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
9381     dynamic_linker='NetBSD (a.out) ld.so'
9382   else
9383     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
9384     soname_spec='${libname}${release}${shared_ext}$major'
9385     dynamic_linker='NetBSD ld.elf_so'
9386   fi
9387   shlibpath_var=LD_LIBRARY_PATH
9388   shlibpath_overrides_runpath=yes
9389   hardcode_into_libs=yes
9390   ;;
9391
9392 newsos6)
9393   version_type=linux
9394   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9395   shlibpath_var=LD_LIBRARY_PATH
9396   shlibpath_overrides_runpath=yes
9397   ;;
9398
9399 nto-qnx*)
9400   version_type=linux
9401   need_lib_prefix=no
9402   need_version=no
9403   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9404   soname_spec='${libname}${release}${shared_ext}$major'
9405   shlibpath_var=LD_LIBRARY_PATH
9406   shlibpath_overrides_runpath=yes
9407   ;;
9408
9409 openbsd*)
9410   version_type=sunos
9411   need_lib_prefix=no
9412   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
9413   case $host_os in
9414     openbsd3.3 | openbsd3.3.*) need_version=yes ;;
9415     *)                         need_version=no  ;;
9416   esac
9417   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9418   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
9419   shlibpath_var=LD_LIBRARY_PATH
9420   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
9421     case $host_os in
9422       openbsd2.[89] | openbsd2.[89].*)
9423         shlibpath_overrides_runpath=no
9424         ;;
9425       *)
9426         shlibpath_overrides_runpath=yes
9427         ;;
9428       esac
9429   else
9430     shlibpath_overrides_runpath=yes
9431   fi
9432   ;;
9433
9434 os2*)
9435   libname_spec='$name'
9436   shrext_cmds=".dll"
9437   need_lib_prefix=no
9438   library_names_spec='$libname${shared_ext} $libname.a'
9439   dynamic_linker='OS/2 ld.exe'
9440   shlibpath_var=LIBPATH
9441   ;;
9442
9443 osf3* | osf4* | osf5*)
9444   version_type=osf
9445   need_lib_prefix=no
9446   need_version=no
9447   soname_spec='${libname}${release}${shared_ext}$major'
9448   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9449   shlibpath_var=LD_LIBRARY_PATH
9450   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
9451   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
9452   ;;
9453
9454 sco3.2v5*)
9455   version_type=osf
9456   soname_spec='${libname}${release}${shared_ext}$major'
9457   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9458   shlibpath_var=LD_LIBRARY_PATH
9459   ;;
9460
9461 solaris*)
9462   version_type=linux
9463   need_lib_prefix=no
9464   need_version=no
9465   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9466   soname_spec='${libname}${release}${shared_ext}$major'
9467   shlibpath_var=LD_LIBRARY_PATH
9468   shlibpath_overrides_runpath=yes
9469   hardcode_into_libs=yes
9470   # ldd complains unless libraries are executable
9471   postinstall_cmds='chmod +x $lib'
9472   ;;
9473
9474 sunos4*)
9475   version_type=sunos
9476   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
9477   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
9478   shlibpath_var=LD_LIBRARY_PATH
9479   shlibpath_overrides_runpath=yes
9480   if test "$with_gnu_ld" = yes; then
9481     need_lib_prefix=no
9482   fi
9483   need_version=yes
9484   ;;
9485
9486 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
9487   version_type=linux
9488   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9489   soname_spec='${libname}${release}${shared_ext}$major'
9490   shlibpath_var=LD_LIBRARY_PATH
9491   case $host_vendor in
9492     sni)
9493       shlibpath_overrides_runpath=no
9494       need_lib_prefix=no
9495       export_dynamic_flag_spec='${wl}-Blargedynsym'
9496       runpath_var=LD_RUN_PATH
9497       ;;
9498     siemens)
9499       need_lib_prefix=no
9500       ;;
9501     motorola)
9502       need_lib_prefix=no
9503       need_version=no
9504       shlibpath_overrides_runpath=no
9505       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
9506       ;;
9507   esac
9508   ;;
9509
9510 sysv4*MP*)
9511   if test -d /usr/nec ;then
9512     version_type=linux
9513     library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
9514     soname_spec='$libname${shared_ext}.$major'
9515     shlibpath_var=LD_LIBRARY_PATH
9516   fi
9517   ;;
9518
9519 uts4*)
9520   version_type=linux
9521   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9522   soname_spec='${libname}${release}${shared_ext}$major'
9523   shlibpath_var=LD_LIBRARY_PATH
9524   ;;
9525
9526 *)
9527   dynamic_linker=no
9528   ;;
9529 esac
9530 echo "$as_me:$LINENO: result: $dynamic_linker" >&5
9531 echo "${ECHO_T}$dynamic_linker" >&6
9532 test "$dynamic_linker" = no && can_build_shared=no
9533
9534 echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
9535 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6
9536 hardcode_action=
9537 if test -n "$hardcode_libdir_flag_spec" || \
9538    test -n "$runpath_var" || \
9539    test "X$hardcode_automatic" = "Xyes" ; then
9540
9541   # We can hardcode non-existant directories.
9542   if test "$hardcode_direct" != no &&
9543      # If the only mechanism to avoid hardcoding is shlibpath_var, we
9544      # have to relink, otherwise we might link with an installed library
9545      # when we should be linking with a yet-to-be-installed one
9546      ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, )" != no &&
9547      test "$hardcode_minus_L" != no; then
9548     # Linking always hardcodes the temporary library directory.
9549     hardcode_action=relink
9550   else
9551     # We can link without hardcoding, and we can hardcode nonexisting dirs.
9552     hardcode_action=immediate
9553   fi
9554 else
9555   # We cannot hardcode anything, or else we can only hardcode existing
9556   # directories.
9557   hardcode_action=unsupported
9558 fi
9559 echo "$as_me:$LINENO: result: $hardcode_action" >&5
9560 echo "${ECHO_T}$hardcode_action" >&6
9561
9562 if test "$hardcode_action" = relink; then
9563   # Fast installation is not supported
9564   enable_fast_install=no
9565 elif test "$shlibpath_overrides_runpath" = yes ||
9566      test "$enable_shared" = no; then
9567   # Fast installation is not necessary
9568   enable_fast_install=needless
9569 fi
9570
9571 striplib=
9572 old_striplib=
9573 echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5
9574 echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&6
9575 if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
9576   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
9577   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
9578   echo "$as_me:$LINENO: result: yes" >&5
9579 echo "${ECHO_T}yes" >&6
9580 else
9581 # FIXME - insert some real tests, host_os isn't really good enough
9582   case $host_os in
9583    darwin*)
9584        if test -n "$STRIP" ; then
9585          striplib="$STRIP -x"
9586          echo "$as_me:$LINENO: result: yes" >&5
9587 echo "${ECHO_T}yes" >&6
9588        else
9589   echo "$as_me:$LINENO: result: no" >&5
9590 echo "${ECHO_T}no" >&6
9591 fi
9592        ;;
9593    *)
9594   echo "$as_me:$LINENO: result: no" >&5
9595 echo "${ECHO_T}no" >&6
9596     ;;
9597   esac
9598 fi
9599
9600 if test "x$enable_dlopen" != xyes; then
9601   enable_dlopen=unknown
9602   enable_dlopen_self=unknown
9603   enable_dlopen_self_static=unknown
9604 else
9605   lt_cv_dlopen=no
9606   lt_cv_dlopen_libs=
9607
9608   case $host_os in
9609   beos*)
9610     lt_cv_dlopen="load_add_on"
9611     lt_cv_dlopen_libs=
9612     lt_cv_dlopen_self=yes
9613     ;;
9614
9615   mingw* | pw32*)
9616     lt_cv_dlopen="LoadLibrary"
9617     lt_cv_dlopen_libs=
9618    ;;
9619
9620   cygwin*)
9621     lt_cv_dlopen="dlopen"
9622     lt_cv_dlopen_libs=
9623    ;;
9624
9625   darwin*)
9626   # if libdl is installed we need to link against it
9627     echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
9628 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
9629 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
9630   echo $ECHO_N "(cached) $ECHO_C" >&6
9631 else
9632   ac_check_lib_save_LIBS=$LIBS
9633 LIBS="-ldl  $LIBS"
9634 cat >conftest.$ac_ext <<_ACEOF
9635 /* confdefs.h.  */
9636 _ACEOF
9637 cat confdefs.h >>conftest.$ac_ext
9638 cat >>conftest.$ac_ext <<_ACEOF
9639 /* end confdefs.h.  */
9640
9641 /* Override any gcc2 internal prototype to avoid an error.  */
9642 #ifdef __cplusplus
9643 extern "C"
9644 #endif
9645 /* We use char because int might match the return type of a gcc2
9646    builtin and then its argument prototype would still apply.  */
9647 char dlopen ();
9648 int
9649 main ()
9650 {
9651 dlopen ();
9652   ;
9653   return 0;
9654 }
9655 _ACEOF
9656 rm -f conftest.$ac_objext conftest$ac_exeext
9657 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9658   (eval $ac_link) 2>conftest.er1
9659   ac_status=$?
9660   grep -v '^ *+' conftest.er1 >conftest.err
9661   rm -f conftest.er1
9662   cat conftest.err >&5
9663   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9664   (exit $ac_status); } &&
9665          { ac_try='test -z "$ac_c_werror_flag"
9666                          || test ! -s conftest.err'
9667   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9668   (eval $ac_try) 2>&5
9669   ac_status=$?
9670   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9671   (exit $ac_status); }; } &&
9672          { ac_try='test -s conftest$ac_exeext'
9673   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9674   (eval $ac_try) 2>&5
9675   ac_status=$?
9676   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9677   (exit $ac_status); }; }; then
9678   ac_cv_lib_dl_dlopen=yes
9679 else
9680   echo "$as_me: failed program was:" >&5
9681 sed 's/^/| /' conftest.$ac_ext >&5
9682
9683 ac_cv_lib_dl_dlopen=no
9684 fi
9685 rm -f conftest.err conftest.$ac_objext \
9686       conftest$ac_exeext conftest.$ac_ext
9687 LIBS=$ac_check_lib_save_LIBS
9688 fi
9689 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
9690 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
9691 if test $ac_cv_lib_dl_dlopen = yes; then
9692   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
9693 else
9694
9695     lt_cv_dlopen="dyld"
9696     lt_cv_dlopen_libs=
9697     lt_cv_dlopen_self=yes
9698
9699 fi
9700
9701    ;;
9702
9703   *)
9704     echo "$as_me:$LINENO: checking for shl_load" >&5
9705 echo $ECHO_N "checking for shl_load... $ECHO_C" >&6
9706 if test "${ac_cv_func_shl_load+set}" = set; then
9707   echo $ECHO_N "(cached) $ECHO_C" >&6
9708 else
9709   cat >conftest.$ac_ext <<_ACEOF
9710 /* confdefs.h.  */
9711 _ACEOF
9712 cat confdefs.h >>conftest.$ac_ext
9713 cat >>conftest.$ac_ext <<_ACEOF
9714 /* end confdefs.h.  */
9715 /* Define shl_load to an innocuous variant, in case <limits.h> declares shl_load.
9716    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9717 #define shl_load innocuous_shl_load
9718
9719 /* System header to define __stub macros and hopefully few prototypes,
9720     which can conflict with char shl_load (); below.
9721     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9722     <limits.h> exists even on freestanding compilers.  */
9723
9724 #ifdef __STDC__
9725 # include <limits.h>
9726 #else
9727 # include <assert.h>
9728 #endif
9729
9730 #undef shl_load
9731
9732 /* Override any gcc2 internal prototype to avoid an error.  */
9733 #ifdef __cplusplus
9734 extern "C"
9735 {
9736 #endif
9737 /* We use char because int might match the return type of a gcc2
9738    builtin and then its argument prototype would still apply.  */
9739 char shl_load ();
9740 /* The GNU C library defines this for functions which it implements
9741     to always fail with ENOSYS.  Some functions are actually named
9742     something starting with __ and the normal name is an alias.  */
9743 #if defined (__stub_shl_load) || defined (__stub___shl_load)
9744 choke me
9745 #else
9746 char (*f) () = shl_load;
9747 #endif
9748 #ifdef __cplusplus
9749 }
9750 #endif
9751
9752 int
9753 main ()
9754 {
9755 return f != shl_load;
9756   ;
9757   return 0;
9758 }
9759 _ACEOF
9760 rm -f conftest.$ac_objext conftest$ac_exeext
9761 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9762   (eval $ac_link) 2>conftest.er1
9763   ac_status=$?
9764   grep -v '^ *+' conftest.er1 >conftest.err
9765   rm -f conftest.er1
9766   cat conftest.err >&5
9767   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9768   (exit $ac_status); } &&
9769          { ac_try='test -z "$ac_c_werror_flag"
9770                          || test ! -s conftest.err'
9771   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9772   (eval $ac_try) 2>&5
9773   ac_status=$?
9774   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9775   (exit $ac_status); }; } &&
9776          { ac_try='test -s conftest$ac_exeext'
9777   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9778   (eval $ac_try) 2>&5
9779   ac_status=$?
9780   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9781   (exit $ac_status); }; }; then
9782   ac_cv_func_shl_load=yes
9783 else
9784   echo "$as_me: failed program was:" >&5
9785 sed 's/^/| /' conftest.$ac_ext >&5
9786
9787 ac_cv_func_shl_load=no
9788 fi
9789 rm -f conftest.err conftest.$ac_objext \
9790       conftest$ac_exeext conftest.$ac_ext
9791 fi
9792 echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5
9793 echo "${ECHO_T}$ac_cv_func_shl_load" >&6
9794 if test $ac_cv_func_shl_load = yes; then
9795   lt_cv_dlopen="shl_load"
9796 else
9797   echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
9798 echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6
9799 if test "${ac_cv_lib_dld_shl_load+set}" = set; then
9800   echo $ECHO_N "(cached) $ECHO_C" >&6
9801 else
9802   ac_check_lib_save_LIBS=$LIBS
9803 LIBS="-ldld  $LIBS"
9804 cat >conftest.$ac_ext <<_ACEOF
9805 /* confdefs.h.  */
9806 _ACEOF
9807 cat confdefs.h >>conftest.$ac_ext
9808 cat >>conftest.$ac_ext <<_ACEOF
9809 /* end confdefs.h.  */
9810
9811 /* Override any gcc2 internal prototype to avoid an error.  */
9812 #ifdef __cplusplus
9813 extern "C"
9814 #endif
9815 /* We use char because int might match the return type of a gcc2
9816    builtin and then its argument prototype would still apply.  */
9817 char shl_load ();
9818 int
9819 main ()
9820 {
9821 shl_load ();
9822   ;
9823   return 0;
9824 }
9825 _ACEOF
9826 rm -f conftest.$ac_objext conftest$ac_exeext
9827 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9828   (eval $ac_link) 2>conftest.er1
9829   ac_status=$?
9830   grep -v '^ *+' conftest.er1 >conftest.err
9831   rm -f conftest.er1
9832   cat conftest.err >&5
9833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9834   (exit $ac_status); } &&
9835          { ac_try='test -z "$ac_c_werror_flag"
9836                          || test ! -s conftest.err'
9837   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9838   (eval $ac_try) 2>&5
9839   ac_status=$?
9840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9841   (exit $ac_status); }; } &&
9842          { ac_try='test -s conftest$ac_exeext'
9843   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9844   (eval $ac_try) 2>&5
9845   ac_status=$?
9846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9847   (exit $ac_status); }; }; then
9848   ac_cv_lib_dld_shl_load=yes
9849 else
9850   echo "$as_me: failed program was:" >&5
9851 sed 's/^/| /' conftest.$ac_ext >&5
9852
9853 ac_cv_lib_dld_shl_load=no
9854 fi
9855 rm -f conftest.err conftest.$ac_objext \
9856       conftest$ac_exeext conftest.$ac_ext
9857 LIBS=$ac_check_lib_save_LIBS
9858 fi
9859 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
9860 echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6
9861 if test $ac_cv_lib_dld_shl_load = yes; then
9862   lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"
9863 else
9864   echo "$as_me:$LINENO: checking for dlopen" >&5
9865 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6
9866 if test "${ac_cv_func_dlopen+set}" = set; then
9867   echo $ECHO_N "(cached) $ECHO_C" >&6
9868 else
9869   cat >conftest.$ac_ext <<_ACEOF
9870 /* confdefs.h.  */
9871 _ACEOF
9872 cat confdefs.h >>conftest.$ac_ext
9873 cat >>conftest.$ac_ext <<_ACEOF
9874 /* end confdefs.h.  */
9875 /* Define dlopen to an innocuous variant, in case <limits.h> declares dlopen.
9876    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9877 #define dlopen innocuous_dlopen
9878
9879 /* System header to define __stub macros and hopefully few prototypes,
9880     which can conflict with char dlopen (); below.
9881     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9882     <limits.h> exists even on freestanding compilers.  */
9883
9884 #ifdef __STDC__
9885 # include <limits.h>
9886 #else
9887 # include <assert.h>
9888 #endif
9889
9890 #undef dlopen
9891
9892 /* Override any gcc2 internal prototype to avoid an error.  */
9893 #ifdef __cplusplus
9894 extern "C"
9895 {
9896 #endif
9897 /* We use char because int might match the return type of a gcc2
9898    builtin and then its argument prototype would still apply.  */
9899 char dlopen ();
9900 /* The GNU C library defines this for functions which it implements
9901     to always fail with ENOSYS.  Some functions are actually named
9902     something starting with __ and the normal name is an alias.  */
9903 #if defined (__stub_dlopen) || defined (__stub___dlopen)
9904 choke me
9905 #else
9906 char (*f) () = dlopen;
9907 #endif
9908 #ifdef __cplusplus
9909 }
9910 #endif
9911
9912 int
9913 main ()
9914 {
9915 return f != dlopen;
9916   ;
9917   return 0;
9918 }
9919 _ACEOF
9920 rm -f conftest.$ac_objext conftest$ac_exeext
9921 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9922   (eval $ac_link) 2>conftest.er1
9923   ac_status=$?
9924   grep -v '^ *+' conftest.er1 >conftest.err
9925   rm -f conftest.er1
9926   cat conftest.err >&5
9927   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9928   (exit $ac_status); } &&
9929          { ac_try='test -z "$ac_c_werror_flag"
9930                          || test ! -s conftest.err'
9931   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9932   (eval $ac_try) 2>&5
9933   ac_status=$?
9934   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9935   (exit $ac_status); }; } &&
9936          { ac_try='test -s conftest$ac_exeext'
9937   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9938   (eval $ac_try) 2>&5
9939   ac_status=$?
9940   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9941   (exit $ac_status); }; }; then
9942   ac_cv_func_dlopen=yes
9943 else
9944   echo "$as_me: failed program was:" >&5
9945 sed 's/^/| /' conftest.$ac_ext >&5
9946
9947 ac_cv_func_dlopen=no
9948 fi
9949 rm -f conftest.err conftest.$ac_objext \
9950       conftest$ac_exeext conftest.$ac_ext
9951 fi
9952 echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
9953 echo "${ECHO_T}$ac_cv_func_dlopen" >&6
9954 if test $ac_cv_func_dlopen = yes; then
9955   lt_cv_dlopen="dlopen"
9956 else
9957   echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
9958 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
9959 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
9960   echo $ECHO_N "(cached) $ECHO_C" >&6
9961 else
9962   ac_check_lib_save_LIBS=$LIBS
9963 LIBS="-ldl  $LIBS"
9964 cat >conftest.$ac_ext <<_ACEOF
9965 /* confdefs.h.  */
9966 _ACEOF
9967 cat confdefs.h >>conftest.$ac_ext
9968 cat >>conftest.$ac_ext <<_ACEOF
9969 /* end confdefs.h.  */
9970
9971 /* Override any gcc2 internal prototype to avoid an error.  */
9972 #ifdef __cplusplus
9973 extern "C"
9974 #endif
9975 /* We use char because int might match the return type of a gcc2
9976    builtin and then its argument prototype would still apply.  */
9977 char dlopen ();
9978 int
9979 main ()
9980 {
9981 dlopen ();
9982   ;
9983   return 0;
9984 }
9985 _ACEOF
9986 rm -f conftest.$ac_objext conftest$ac_exeext
9987 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9988   (eval $ac_link) 2>conftest.er1
9989   ac_status=$?
9990   grep -v '^ *+' conftest.er1 >conftest.err
9991   rm -f conftest.er1
9992   cat conftest.err >&5
9993   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9994   (exit $ac_status); } &&
9995          { ac_try='test -z "$ac_c_werror_flag"
9996                          || test ! -s conftest.err'
9997   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9998   (eval $ac_try) 2>&5
9999   ac_status=$?
10000   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10001   (exit $ac_status); }; } &&
10002          { ac_try='test -s conftest$ac_exeext'
10003   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10004   (eval $ac_try) 2>&5
10005   ac_status=$?
10006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10007   (exit $ac_status); }; }; then
10008   ac_cv_lib_dl_dlopen=yes
10009 else
10010   echo "$as_me: failed program was:" >&5
10011 sed 's/^/| /' conftest.$ac_ext >&5
10012
10013 ac_cv_lib_dl_dlopen=no
10014 fi
10015 rm -f conftest.err conftest.$ac_objext \
10016       conftest$ac_exeext conftest.$ac_ext
10017 LIBS=$ac_check_lib_save_LIBS
10018 fi
10019 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
10020 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
10021 if test $ac_cv_lib_dl_dlopen = yes; then
10022   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
10023 else
10024   echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5
10025 echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6
10026 if test "${ac_cv_lib_svld_dlopen+set}" = set; then
10027   echo $ECHO_N "(cached) $ECHO_C" >&6
10028 else
10029   ac_check_lib_save_LIBS=$LIBS
10030 LIBS="-lsvld  $LIBS"
10031 cat >conftest.$ac_ext <<_ACEOF
10032 /* confdefs.h.  */
10033 _ACEOF
10034 cat confdefs.h >>conftest.$ac_ext
10035 cat >>conftest.$ac_ext <<_ACEOF
10036 /* end confdefs.h.  */
10037
10038 /* Override any gcc2 internal prototype to avoid an error.  */
10039 #ifdef __cplusplus
10040 extern "C"
10041 #endif
10042 /* We use char because int might match the return type of a gcc2
10043    builtin and then its argument prototype would still apply.  */
10044 char dlopen ();
10045 int
10046 main ()
10047 {
10048 dlopen ();
10049   ;
10050   return 0;
10051 }
10052 _ACEOF
10053 rm -f conftest.$ac_objext conftest$ac_exeext
10054 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10055   (eval $ac_link) 2>conftest.er1
10056   ac_status=$?
10057   grep -v '^ *+' conftest.er1 >conftest.err
10058   rm -f conftest.er1
10059   cat conftest.err >&5
10060   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10061   (exit $ac_status); } &&
10062          { ac_try='test -z "$ac_c_werror_flag"
10063                          || test ! -s conftest.err'
10064   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10065   (eval $ac_try) 2>&5
10066   ac_status=$?
10067   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10068   (exit $ac_status); }; } &&
10069          { ac_try='test -s conftest$ac_exeext'
10070   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10071   (eval $ac_try) 2>&5
10072   ac_status=$?
10073   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10074   (exit $ac_status); }; }; then
10075   ac_cv_lib_svld_dlopen=yes
10076 else
10077   echo "$as_me: failed program was:" >&5
10078 sed 's/^/| /' conftest.$ac_ext >&5
10079
10080 ac_cv_lib_svld_dlopen=no
10081 fi
10082 rm -f conftest.err conftest.$ac_objext \
10083       conftest$ac_exeext conftest.$ac_ext
10084 LIBS=$ac_check_lib_save_LIBS
10085 fi
10086 echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5
10087 echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6
10088 if test $ac_cv_lib_svld_dlopen = yes; then
10089   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
10090 else
10091   echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5
10092 echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6
10093 if test "${ac_cv_lib_dld_dld_link+set}" = set; then
10094   echo $ECHO_N "(cached) $ECHO_C" >&6
10095 else
10096   ac_check_lib_save_LIBS=$LIBS
10097 LIBS="-ldld  $LIBS"
10098 cat >conftest.$ac_ext <<_ACEOF
10099 /* confdefs.h.  */
10100 _ACEOF
10101 cat confdefs.h >>conftest.$ac_ext
10102 cat >>conftest.$ac_ext <<_ACEOF
10103 /* end confdefs.h.  */
10104
10105 /* Override any gcc2 internal prototype to avoid an error.  */
10106 #ifdef __cplusplus
10107 extern "C"
10108 #endif
10109 /* We use char because int might match the return type of a gcc2
10110    builtin and then its argument prototype would still apply.  */
10111 char dld_link ();
10112 int
10113 main ()
10114 {
10115 dld_link ();
10116   ;
10117   return 0;
10118 }
10119 _ACEOF
10120 rm -f conftest.$ac_objext conftest$ac_exeext
10121 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10122   (eval $ac_link) 2>conftest.er1
10123   ac_status=$?
10124   grep -v '^ *+' conftest.er1 >conftest.err
10125   rm -f conftest.er1
10126   cat conftest.err >&5
10127   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10128   (exit $ac_status); } &&
10129          { ac_try='test -z "$ac_c_werror_flag"
10130                          || test ! -s conftest.err'
10131   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10132   (eval $ac_try) 2>&5
10133   ac_status=$?
10134   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10135   (exit $ac_status); }; } &&
10136          { ac_try='test -s conftest$ac_exeext'
10137   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10138   (eval $ac_try) 2>&5
10139   ac_status=$?
10140   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10141   (exit $ac_status); }; }; then
10142   ac_cv_lib_dld_dld_link=yes
10143 else
10144   echo "$as_me: failed program was:" >&5
10145 sed 's/^/| /' conftest.$ac_ext >&5
10146
10147 ac_cv_lib_dld_dld_link=no
10148 fi
10149 rm -f conftest.err conftest.$ac_objext \
10150       conftest$ac_exeext conftest.$ac_ext
10151 LIBS=$ac_check_lib_save_LIBS
10152 fi
10153 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5
10154 echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6
10155 if test $ac_cv_lib_dld_dld_link = yes; then
10156   lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"
10157 fi
10158
10159
10160 fi
10161
10162
10163 fi
10164
10165
10166 fi
10167
10168
10169 fi
10170
10171
10172 fi
10173
10174     ;;
10175   esac
10176
10177   if test "x$lt_cv_dlopen" != xno; then
10178     enable_dlopen=yes
10179   else
10180     enable_dlopen=no
10181   fi
10182
10183   case $lt_cv_dlopen in
10184   dlopen)
10185     save_CPPFLAGS="$CPPFLAGS"
10186     test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
10187
10188     save_LDFLAGS="$LDFLAGS"
10189     eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
10190
10191     save_LIBS="$LIBS"
10192     LIBS="$lt_cv_dlopen_libs $LIBS"
10193
10194     echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5
10195 echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6
10196 if test "${lt_cv_dlopen_self+set}" = set; then
10197   echo $ECHO_N "(cached) $ECHO_C" >&6
10198 else
10199           if test "$cross_compiling" = yes; then :
10200   lt_cv_dlopen_self=cross
10201 else
10202   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10203   lt_status=$lt_dlunknown
10204   cat > conftest.$ac_ext <<EOF
10205 #line 10205 "configure"
10206 #include "confdefs.h"
10207
10208 #if HAVE_DLFCN_H
10209 #include <dlfcn.h>
10210 #endif
10211
10212 #include <stdio.h>
10213
10214 #ifdef RTLD_GLOBAL
10215 #  define LT_DLGLOBAL           RTLD_GLOBAL
10216 #else
10217 #  ifdef DL_GLOBAL
10218 #    define LT_DLGLOBAL         DL_GLOBAL
10219 #  else
10220 #    define LT_DLGLOBAL         0
10221 #  endif
10222 #endif
10223
10224 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
10225    find out it does not work in some platform. */
10226 #ifndef LT_DLLAZY_OR_NOW
10227 #  ifdef RTLD_LAZY
10228 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
10229 #  else
10230 #    ifdef DL_LAZY
10231 #      define LT_DLLAZY_OR_NOW          DL_LAZY
10232 #    else
10233 #      ifdef RTLD_NOW
10234 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
10235 #      else
10236 #        ifdef DL_NOW
10237 #          define LT_DLLAZY_OR_NOW      DL_NOW
10238 #        else
10239 #          define LT_DLLAZY_OR_NOW      0
10240 #        endif
10241 #      endif
10242 #    endif
10243 #  endif
10244 #endif
10245
10246 #ifdef __cplusplus
10247 extern "C" void exit (int);
10248 #endif
10249
10250 void fnord() { int i=42;}
10251 int main ()
10252 {
10253   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10254   int status = $lt_dlunknown;
10255
10256   if (self)
10257     {
10258       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
10259       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
10260       /* dlclose (self); */
10261     }
10262
10263     exit (status);
10264 }
10265 EOF
10266   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10267   (eval $ac_link) 2>&5
10268   ac_status=$?
10269   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10270   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
10271     (./conftest; exit; ) >&5 2>/dev/null
10272     lt_status=$?
10273     case x$lt_status in
10274       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
10275       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
10276       x$lt_unknown|x*) lt_cv_dlopen_self=no ;;
10277     esac
10278   else :
10279     # compilation failed
10280     lt_cv_dlopen_self=no
10281   fi
10282 fi
10283 rm -fr conftest*
10284
10285
10286 fi
10287 echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5
10288 echo "${ECHO_T}$lt_cv_dlopen_self" >&6
10289
10290     if test "x$lt_cv_dlopen_self" = xyes; then
10291       LDFLAGS="$LDFLAGS $link_static_flag"
10292       echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5
10293 echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6
10294 if test "${lt_cv_dlopen_self_static+set}" = set; then
10295   echo $ECHO_N "(cached) $ECHO_C" >&6
10296 else
10297           if test "$cross_compiling" = yes; then :
10298   lt_cv_dlopen_self_static=cross
10299 else
10300   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
10301   lt_status=$lt_dlunknown
10302   cat > conftest.$ac_ext <<EOF
10303 #line 10303 "configure"
10304 #include "confdefs.h"
10305
10306 #if HAVE_DLFCN_H
10307 #include <dlfcn.h>
10308 #endif
10309
10310 #include <stdio.h>
10311
10312 #ifdef RTLD_GLOBAL
10313 #  define LT_DLGLOBAL           RTLD_GLOBAL
10314 #else
10315 #  ifdef DL_GLOBAL
10316 #    define LT_DLGLOBAL         DL_GLOBAL
10317 #  else
10318 #    define LT_DLGLOBAL         0
10319 #  endif
10320 #endif
10321
10322 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
10323    find out it does not work in some platform. */
10324 #ifndef LT_DLLAZY_OR_NOW
10325 #  ifdef RTLD_LAZY
10326 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
10327 #  else
10328 #    ifdef DL_LAZY
10329 #      define LT_DLLAZY_OR_NOW          DL_LAZY
10330 #    else
10331 #      ifdef RTLD_NOW
10332 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
10333 #      else
10334 #        ifdef DL_NOW
10335 #          define LT_DLLAZY_OR_NOW      DL_NOW
10336 #        else
10337 #          define LT_DLLAZY_OR_NOW      0
10338 #        endif
10339 #      endif
10340 #    endif
10341 #  endif
10342 #endif
10343
10344 #ifdef __cplusplus
10345 extern "C" void exit (int);
10346 #endif
10347
10348 void fnord() { int i=42;}
10349 int main ()
10350 {
10351   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
10352   int status = $lt_dlunknown;
10353
10354   if (self)
10355     {
10356       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
10357       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
10358       /* dlclose (self); */
10359     }
10360
10361     exit (status);
10362 }
10363 EOF
10364   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10365   (eval $ac_link) 2>&5
10366   ac_status=$?
10367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10368   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
10369     (./conftest; exit; ) >&5 2>/dev/null
10370     lt_status=$?
10371     case x$lt_status in
10372       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
10373       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
10374       x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;;
10375     esac
10376   else :
10377     # compilation failed
10378     lt_cv_dlopen_self_static=no
10379   fi
10380 fi
10381 rm -fr conftest*
10382
10383
10384 fi
10385 echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5
10386 echo "${ECHO_T}$lt_cv_dlopen_self_static" >&6
10387     fi
10388
10389     CPPFLAGS="$save_CPPFLAGS"
10390     LDFLAGS="$save_LDFLAGS"
10391     LIBS="$save_LIBS"
10392     ;;
10393   esac
10394
10395   case $lt_cv_dlopen_self in
10396   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
10397   *) enable_dlopen_self=unknown ;;
10398   esac
10399
10400   case $lt_cv_dlopen_self_static in
10401   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
10402   *) enable_dlopen_self_static=unknown ;;
10403   esac
10404 fi
10405
10406
10407 # Report which librarie types wil actually be built
10408 echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
10409 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6
10410 echo "$as_me:$LINENO: result: $can_build_shared" >&5
10411 echo "${ECHO_T}$can_build_shared" >&6
10412
10413 echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
10414 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6
10415 test "$can_build_shared" = "no" && enable_shared=no
10416
10417 # On AIX, shared libraries and static libraries use the same namespace, and
10418 # are all built from PIC.
10419 case $host_os in
10420 aix3*)
10421   test "$enable_shared" = yes && enable_static=no
10422   if test -n "$RANLIB"; then
10423     archive_cmds="$archive_cmds~\$RANLIB \$lib"
10424     postinstall_cmds='$RANLIB $lib'
10425   fi
10426   ;;
10427
10428 aix4* | aix5*)
10429   if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
10430     test "$enable_shared" = yes && enable_static=no
10431   fi
10432     ;;
10433 esac
10434 echo "$as_me:$LINENO: result: $enable_shared" >&5
10435 echo "${ECHO_T}$enable_shared" >&6
10436
10437 echo "$as_me:$LINENO: checking whether to build static libraries" >&5
10438 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6
10439 # Make sure either enable_shared or enable_static is yes.
10440 test "$enable_shared" = yes || enable_static=yes
10441 echo "$as_me:$LINENO: result: $enable_static" >&5
10442 echo "${ECHO_T}$enable_static" >&6
10443
10444 # The else clause should only fire when bootstrapping the
10445 # libtool distribution, otherwise you forgot to ship ltmain.sh
10446 # with your package, and you will get complaints that there are
10447 # no rules to generate ltmain.sh.
10448 if test -f "$ltmain"; then
10449   # See if we are running on zsh, and set the options which allow our commands through
10450   # without removal of \ escapes.
10451   if test -n "${ZSH_VERSION+set}" ; then
10452     setopt NO_GLOB_SUBST
10453   fi
10454   # Now quote all the things that may contain metacharacters while being
10455   # careful not to overquote the AC_SUBSTed values.  We take copies of the
10456   # variables and quote the copies for generation of the libtool script.
10457   for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
10458     SED SHELL STRIP \
10459     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
10460     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
10461     deplibs_check_method reload_flag reload_cmds need_locks \
10462     lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
10463     lt_cv_sys_global_symbol_to_c_name_address \
10464     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
10465     old_postinstall_cmds old_postuninstall_cmds \
10466     compiler \
10467     CC \
10468     LD \
10469     lt_prog_compiler_wl \
10470     lt_prog_compiler_pic \
10471     lt_prog_compiler_static \
10472     lt_prog_compiler_no_builtin_flag \
10473     export_dynamic_flag_spec \
10474     thread_safe_flag_spec \
10475     whole_archive_flag_spec \
10476     enable_shared_with_static_runtimes \
10477     old_archive_cmds \
10478     old_archive_from_new_cmds \
10479     predep_objects \
10480     postdep_objects \
10481     predeps \
10482     postdeps \
10483     compiler_lib_search_path \
10484     archive_cmds \
10485     archive_expsym_cmds \
10486     postinstall_cmds \
10487     postuninstall_cmds \
10488     old_archive_from_expsyms_cmds \
10489     allow_undefined_flag \
10490     no_undefined_flag \
10491     export_symbols_cmds \
10492     hardcode_libdir_flag_spec \
10493     hardcode_libdir_flag_spec_ld \
10494     hardcode_libdir_separator \
10495     hardcode_automatic \
10496     module_cmds \
10497     module_expsym_cmds \
10498     lt_cv_prog_compiler_c_o \
10499     exclude_expsyms \
10500     include_expsyms; do
10501
10502     case $var in
10503     old_archive_cmds | \
10504     old_archive_from_new_cmds | \
10505     archive_cmds | \
10506     archive_expsym_cmds | \
10507     module_cmds | \
10508     module_expsym_cmds | \
10509     old_archive_from_expsyms_cmds | \
10510     export_symbols_cmds | \
10511     extract_expsyms_cmds | reload_cmds | finish_cmds | \
10512     postinstall_cmds | postuninstall_cmds | \
10513     old_postinstall_cmds | old_postuninstall_cmds | \
10514     sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
10515       # Double-quote double-evaled strings.
10516       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
10517       ;;
10518     *)
10519       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
10520       ;;
10521     esac
10522   done
10523
10524   case $lt_echo in
10525   *'\$0 --fallback-echo"')
10526     lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
10527     ;;
10528   esac
10529
10530 cfgfile="${ofile}T"
10531   trap "$rm \"$cfgfile\"; exit 1" 1 2 15
10532   $rm -f "$cfgfile"
10533   { echo "$as_me:$LINENO: creating $ofile" >&5
10534 echo "$as_me: creating $ofile" >&6;}
10535
10536   cat <<__EOF__ >> "$cfgfile"
10537 #! $SHELL
10538
10539 # `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
10540 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
10541 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
10542 #
10543 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
10544 # Free Software Foundation, Inc.
10545 #
10546 # This file is part of GNU Libtool:
10547 # Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
10548 #
10549 # This program is free software; you can redistribute it and/or modify
10550 # it under the terms of the GNU General Public License as published by
10551 # the Free Software Foundation; either version 2 of the License, or
10552 # (at your option) any later version.
10553 #
10554 # This program is distributed in the hope that it will be useful, but
10555 # WITHOUT ANY WARRANTY; without even the implied warranty of
10556 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
10557 # General Public License for more details.
10558 #
10559 # You should have received a copy of the GNU General Public License
10560 # along with this program; if not, write to the Free Software
10561 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
10562 #
10563 # As a special exception to the GNU General Public License, if you
10564 # distribute this file as part of a program that contains a
10565 # configuration script generated by Autoconf, you may include it under
10566 # the same distribution terms that you use for the rest of that program.
10567
10568 # A sed program that does not truncate output.
10569 SED=$lt_SED
10570
10571 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
10572 Xsed="$SED -e 1s/^X//"
10573
10574 # The HP-UX ksh and POSIX shell print the target directory to stdout
10575 # if CDPATH is set.
10576 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
10577
10578 # The names of the tagged configurations supported by this script.
10579 available_tags=
10580
10581 # ### BEGIN LIBTOOL CONFIG
10582
10583 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
10584
10585 # Shell to use when invoking shell scripts.
10586 SHELL=$lt_SHELL
10587
10588 # Whether or not to build shared libraries.
10589 build_libtool_libs=$enable_shared
10590
10591 # Whether or not to build static libraries.
10592 build_old_libs=$enable_static
10593
10594 # Whether or not to add -lc for building shared libraries.
10595 build_libtool_need_lc=$archive_cmds_need_lc
10596
10597 # Whether or not to disallow shared libs when runtime libs are static
10598 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
10599
10600 # Whether or not to optimize for fast installation.
10601 fast_install=$enable_fast_install
10602
10603 # The host system.
10604 host_alias=$host_alias
10605 host=$host
10606 host_os=$host_os
10607
10608 # The build system.
10609 build_alias=$build_alias
10610 build=$build
10611 build_os=$build_os
10612
10613 # An echo program that does not interpret backslashes.
10614 echo=$lt_echo
10615
10616 # The archiver.
10617 AR=$lt_AR
10618 AR_FLAGS=$lt_AR_FLAGS
10619
10620 # A C compiler.
10621 LTCC=$lt_LTCC
10622
10623 # A language-specific compiler.
10624 CC=$lt_compiler
10625
10626 # Is the compiler the GNU C compiler?
10627 with_gcc=$GCC
10628
10629 # An ERE matcher.
10630 EGREP=$lt_EGREP
10631
10632 # The linker used to build libraries.
10633 LD=$lt_LD
10634
10635 # Whether we need hard or soft links.
10636 LN_S=$lt_LN_S
10637
10638 # A BSD-compatible nm program.
10639 NM=$lt_NM
10640
10641 # A symbol stripping program
10642 STRIP=$lt_STRIP
10643
10644 # Used to examine libraries when file_magic_cmd begins "file"
10645 MAGIC_CMD=$MAGIC_CMD
10646
10647 # Used on cygwin: DLL creation program.
10648 DLLTOOL="$DLLTOOL"
10649
10650 # Used on cygwin: object dumper.
10651 OBJDUMP="$OBJDUMP"
10652
10653 # Used on cygwin: assembler.
10654 AS="$AS"
10655
10656 # The name of the directory that contains temporary libtool files.
10657 objdir=$objdir
10658
10659 # How to create reloadable object files.
10660 reload_flag=$lt_reload_flag
10661 reload_cmds=$lt_reload_cmds
10662
10663 # How to pass a linker flag through the compiler.
10664 wl=$lt_lt_prog_compiler_wl
10665
10666 # Object file suffix (normally "o").
10667 objext="$ac_objext"
10668
10669 # Old archive suffix (normally "a").
10670 libext="$libext"
10671
10672 # Shared library suffix (normally ".so").
10673 shrext_cmds='$shrext_cmds'
10674
10675 # Executable file suffix (normally "").
10676 exeext="$exeext"
10677
10678 # Additional compiler flags for building library objects.
10679 pic_flag=$lt_lt_prog_compiler_pic
10680 pic_mode=$pic_mode
10681
10682 # What is the maximum length of a command?
10683 max_cmd_len=$lt_cv_sys_max_cmd_len
10684
10685 # Does compiler simultaneously support -c and -o options?
10686 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
10687
10688 # Must we lock files when doing compilation?
10689 need_locks=$lt_need_locks
10690
10691 # Do we need the lib prefix for modules?
10692 need_lib_prefix=$need_lib_prefix
10693
10694 # Do we need a version for libraries?
10695 need_version=$need_version
10696
10697 # Whether dlopen is supported.
10698 dlopen_support=$enable_dlopen
10699
10700 # Whether dlopen of programs is supported.
10701 dlopen_self=$enable_dlopen_self
10702
10703 # Whether dlopen of statically linked programs is supported.
10704 dlopen_self_static=$enable_dlopen_self_static
10705
10706 # Compiler flag to prevent dynamic linking.
10707 link_static_flag=$lt_lt_prog_compiler_static
10708
10709 # Compiler flag to turn off builtin functions.
10710 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
10711
10712 # Compiler flag to allow reflexive dlopens.
10713 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
10714
10715 # Compiler flag to generate shared objects directly from archives.
10716 whole_archive_flag_spec=$lt_whole_archive_flag_spec
10717
10718 # Compiler flag to generate thread-safe objects.
10719 thread_safe_flag_spec=$lt_thread_safe_flag_spec
10720
10721 # Library versioning type.
10722 version_type=$version_type
10723
10724 # Format of library name prefix.
10725 libname_spec=$lt_libname_spec
10726
10727 # List of archive names.  First name is the real one, the rest are links.
10728 # The last name is the one that the linker finds with -lNAME.
10729 library_names_spec=$lt_library_names_spec
10730
10731 # The coded name of the library, if different from the real name.
10732 soname_spec=$lt_soname_spec
10733
10734 # Commands used to build and install an old-style archive.
10735 RANLIB=$lt_RANLIB
10736 old_archive_cmds=$lt_old_archive_cmds
10737 old_postinstall_cmds=$lt_old_postinstall_cmds
10738 old_postuninstall_cmds=$lt_old_postuninstall_cmds
10739
10740 # Create an old-style archive from a shared archive.
10741 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
10742
10743 # Create a temporary old-style archive to link instead of a shared archive.
10744 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
10745
10746 # Commands used to build and install a shared archive.
10747 archive_cmds=$lt_archive_cmds
10748 archive_expsym_cmds=$lt_archive_expsym_cmds
10749 postinstall_cmds=$lt_postinstall_cmds
10750 postuninstall_cmds=$lt_postuninstall_cmds
10751
10752 # Commands used to build a loadable module (assumed same as above if empty)
10753 module_cmds=$lt_module_cmds
10754 module_expsym_cmds=$lt_module_expsym_cmds
10755
10756 # Commands to strip libraries.
10757 old_striplib=$lt_old_striplib
10758 striplib=$lt_striplib
10759
10760 # Dependencies to place before the objects being linked to create a
10761 # shared library.
10762 predep_objects=$lt_predep_objects
10763
10764 # Dependencies to place after the objects being linked to create a
10765 # shared library.
10766 postdep_objects=$lt_postdep_objects
10767
10768 # Dependencies to place before the objects being linked to create a
10769 # shared library.
10770 predeps=$lt_predeps
10771
10772 # Dependencies to place after the objects being linked to create a
10773 # shared library.
10774 postdeps=$lt_postdeps
10775
10776 # The library search path used internally by the compiler when linking
10777 # a shared library.
10778 compiler_lib_search_path=$lt_compiler_lib_search_path
10779
10780 # Method to check whether dependent libraries are shared objects.
10781 deplibs_check_method=$lt_deplibs_check_method
10782
10783 # Command to use when deplibs_check_method == file_magic.
10784 file_magic_cmd=$lt_file_magic_cmd
10785
10786 # Flag that allows shared libraries with undefined symbols to be built.
10787 allow_undefined_flag=$lt_allow_undefined_flag
10788
10789 # Flag that forces no undefined symbols.
10790 no_undefined_flag=$lt_no_undefined_flag
10791
10792 # Commands used to finish a libtool library installation in a directory.
10793 finish_cmds=$lt_finish_cmds
10794
10795 # Same as above, but a single script fragment to be evaled but not shown.
10796 finish_eval=$lt_finish_eval
10797
10798 # Take the output of nm and produce a listing of raw symbols and C names.
10799 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
10800
10801 # Transform the output of nm in a proper C declaration
10802 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
10803
10804 # Transform the output of nm in a C name address pair
10805 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
10806
10807 # This is the shared library runtime path variable.
10808 runpath_var=$runpath_var
10809
10810 # This is the shared library path variable.
10811 shlibpath_var=$shlibpath_var
10812
10813 # Is shlibpath searched before the hard-coded library search path?
10814 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
10815
10816 # How to hardcode a shared library path into an executable.
10817 hardcode_action=$hardcode_action
10818
10819 # Whether we should hardcode library paths into libraries.
10820 hardcode_into_libs=$hardcode_into_libs
10821
10822 # Flag to hardcode \$libdir into a binary during linking.
10823 # This must work even if \$libdir does not exist.
10824 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
10825
10826 # If ld is used when linking, flag to hardcode \$libdir into
10827 # a binary during linking. This must work even if \$libdir does
10828 # not exist.
10829 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
10830
10831 # Whether we need a single -rpath flag with a separated argument.
10832 hardcode_libdir_separator=$lt_hardcode_libdir_separator
10833
10834 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
10835 # resulting binary.
10836 hardcode_direct=$hardcode_direct
10837
10838 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
10839 # resulting binary.
10840 hardcode_minus_L=$hardcode_minus_L
10841
10842 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
10843 # the resulting binary.
10844 hardcode_shlibpath_var=$hardcode_shlibpath_var
10845
10846 # Set to yes if building a shared library automatically hardcodes DIR into the library
10847 # and all subsequent libraries and executables linked against it.
10848 hardcode_automatic=$hardcode_automatic
10849
10850 # Variables whose values should be saved in libtool wrapper scripts and
10851 # restored at relink time.
10852 variables_saved_for_relink="$variables_saved_for_relink"
10853
10854 # Whether libtool must link a program against all its dependency libraries.
10855 link_all_deplibs=$link_all_deplibs
10856
10857 # Compile-time system search path for libraries
10858 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
10859
10860 # Run-time system search path for libraries
10861 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
10862
10863 # Fix the shell variable \$srcfile for the compiler.
10864 fix_srcfile_path="$fix_srcfile_path"
10865
10866 # Set to yes if exported symbols are required.
10867 always_export_symbols=$always_export_symbols
10868
10869 # The commands to list exported symbols.
10870 export_symbols_cmds=$lt_export_symbols_cmds
10871
10872 # The commands to extract the exported symbol list from a shared archive.
10873 extract_expsyms_cmds=$lt_extract_expsyms_cmds
10874
10875 # Symbols that should not be listed in the preloaded symbols.
10876 exclude_expsyms=$lt_exclude_expsyms
10877
10878 # Symbols that must always be exported.
10879 include_expsyms=$lt_include_expsyms
10880
10881 # ### END LIBTOOL CONFIG
10882
10883 __EOF__
10884
10885
10886   case $host_os in
10887   aix3*)
10888     cat <<\EOF >> "$cfgfile"
10889
10890 # AIX sometimes has problems with the GCC collect2 program.  For some
10891 # reason, if we set the COLLECT_NAMES environment variable, the problems
10892 # vanish in a puff of smoke.
10893 if test "X${COLLECT_NAMES+set}" != Xset; then
10894   COLLECT_NAMES=
10895   export COLLECT_NAMES
10896 fi
10897 EOF
10898     ;;
10899   esac
10900
10901   # We use sed instead of cat because bash on DJGPP gets confused if
10902   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
10903   # text mode, it properly converts lines to CR/LF.  This bash problem
10904   # is reportedly fixed, but why not run on old versions too?
10905   sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
10906
10907   mv -f "$cfgfile" "$ofile" || \
10908     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
10909   chmod +x "$ofile"
10910
10911 else
10912   # If there is no Makefile yet, we rely on a make rule to execute
10913   # `config.status --recheck' to rerun these tests and create the
10914   # libtool script then.
10915   ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
10916   if test -f "$ltmain_in"; then
10917     test -f Makefile && make "$ltmain"
10918   fi
10919 fi
10920
10921
10922 ac_ext=c
10923 ac_cpp='$CPP $CPPFLAGS'
10924 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10925 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10926 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10927
10928 CC="$lt_save_CC"
10929
10930
10931 # Check whether --with-tags or --without-tags was given.
10932 if test "${with_tags+set}" = set; then
10933   withval="$with_tags"
10934   tagnames="$withval"
10935 fi;
10936
10937 if test -f "$ltmain" && test -n "$tagnames"; then
10938   if test ! -f "${ofile}"; then
10939     { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not exist" >&5
10940 echo "$as_me: WARNING: output file \`$ofile' does not exist" >&2;}
10941   fi
10942
10943   if test -z "$LTCC"; then
10944     eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
10945     if test -z "$LTCC"; then
10946       { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not look like a libtool script" >&5
10947 echo "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;}
10948     else
10949       { echo "$as_me:$LINENO: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5
10950 echo "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;}
10951     fi
10952   fi
10953
10954   # Extract list of available tagged configurations in $ofile.
10955   # Note that this assumes the entire list is on one line.
10956   available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
10957
10958   lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
10959   for tagname in $tagnames; do
10960     IFS="$lt_save_ifs"
10961     # Check whether tagname contains only valid characters
10962     case `$echo "X$tagname" | $Xsed -e 's:[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]::g'` in
10963     "") ;;
10964     *)  { { echo "$as_me:$LINENO: error: invalid tag name: $tagname" >&5
10965 echo "$as_me: error: invalid tag name: $tagname" >&2;}
10966    { (exit 1); exit 1; }; }
10967         ;;
10968     esac
10969
10970     if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
10971     then
10972       { { echo "$as_me:$LINENO: error: tag name \"$tagname\" already exists" >&5
10973 echo "$as_me: error: tag name \"$tagname\" already exists" >&2;}
10974    { (exit 1); exit 1; }; }
10975     fi
10976
10977     # Update the list of available tags.
10978     if test -n "$tagname"; then
10979       echo appending configuration tag \"$tagname\" to $ofile
10980
10981       case $tagname in
10982       CXX)
10983         if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
10984             ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
10985             (test "X$CXX" != "Xg++"))) ; then
10986           :
10987         else
10988           tagname=""
10989         fi
10990         ;;
10991
10992       F77)
10993         if test -n "$F77" && test "X$F77" != "Xno"; then
10994           :
10995         else
10996           tagname=""
10997         fi
10998         ;;
10999
11000       GCJ)
11001         if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
11002           :
11003         else
11004           tagname=""
11005         fi
11006         ;;
11007
11008       RC)
11009
11010
11011
11012 # Source file extension for RC test sources.
11013 ac_ext=rc
11014
11015 # Object file extension for compiled RC test sources.
11016 objext=o
11017 objext_RC=$objext
11018
11019 # Code to be used in simple compile tests
11020 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
11021
11022 # Code to be used in simple link tests
11023 lt_simple_link_test_code="$lt_simple_compile_test_code"
11024
11025 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
11026
11027 # If no C compiler was specified, use CC.
11028 LTCC=${LTCC-"$CC"}
11029
11030 # Allow CC to be a program name with arguments.
11031 compiler=$CC
11032
11033
11034 # save warnings/boilerplate of simple test code
11035 ac_outfile=conftest.$ac_objext
11036 printf "$lt_simple_compile_test_code" >conftest.$ac_ext
11037 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
11038 _lt_compiler_boilerplate=`cat conftest.err`
11039 $rm conftest*
11040
11041 ac_outfile=conftest.$ac_objext
11042 printf "$lt_simple_link_test_code" >conftest.$ac_ext
11043 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
11044 _lt_linker_boilerplate=`cat conftest.err`
11045 $rm conftest*
11046
11047
11048 # Allow CC to be a program name with arguments.
11049 lt_save_CC="$CC"
11050 CC=${RC-"windres"}
11051 compiler=$CC
11052 compiler_RC=$CC
11053 for cc_temp in $compiler""; do
11054   case $cc_temp in
11055     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
11056     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
11057     \-*) ;;
11058     *) break;;
11059   esac
11060 done
11061 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
11062
11063 lt_cv_prog_compiler_c_o_RC=yes
11064
11065 # The else clause should only fire when bootstrapping the
11066 # libtool distribution, otherwise you forgot to ship ltmain.sh
11067 # with your package, and you will get complaints that there are
11068 # no rules to generate ltmain.sh.
11069 if test -f "$ltmain"; then
11070   # See if we are running on zsh, and set the options which allow our commands through
11071   # without removal of \ escapes.
11072   if test -n "${ZSH_VERSION+set}" ; then
11073     setopt NO_GLOB_SUBST
11074   fi
11075   # Now quote all the things that may contain metacharacters while being
11076   # careful not to overquote the AC_SUBSTed values.  We take copies of the
11077   # variables and quote the copies for generation of the libtool script.
11078   for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
11079     SED SHELL STRIP \
11080     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
11081     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
11082     deplibs_check_method reload_flag reload_cmds need_locks \
11083     lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
11084     lt_cv_sys_global_symbol_to_c_name_address \
11085     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
11086     old_postinstall_cmds old_postuninstall_cmds \
11087     compiler_RC \
11088     CC_RC \
11089     LD_RC \
11090     lt_prog_compiler_wl_RC \
11091     lt_prog_compiler_pic_RC \
11092     lt_prog_compiler_static_RC \
11093     lt_prog_compiler_no_builtin_flag_RC \
11094     export_dynamic_flag_spec_RC \
11095     thread_safe_flag_spec_RC \
11096     whole_archive_flag_spec_RC \
11097     enable_shared_with_static_runtimes_RC \
11098     old_archive_cmds_RC \
11099     old_archive_from_new_cmds_RC \
11100     predep_objects_RC \
11101     postdep_objects_RC \
11102     predeps_RC \
11103     postdeps_RC \
11104     compiler_lib_search_path_RC \
11105     archive_cmds_RC \
11106     archive_expsym_cmds_RC \
11107     postinstall_cmds_RC \
11108     postuninstall_cmds_RC \
11109     old_archive_from_expsyms_cmds_RC \
11110     allow_undefined_flag_RC \
11111     no_undefined_flag_RC \
11112     export_symbols_cmds_RC \
11113     hardcode_libdir_flag_spec_RC \
11114     hardcode_libdir_flag_spec_ld_RC \
11115     hardcode_libdir_separator_RC \
11116     hardcode_automatic_RC \
11117     module_cmds_RC \
11118     module_expsym_cmds_RC \
11119     lt_cv_prog_compiler_c_o_RC \
11120     exclude_expsyms_RC \
11121     include_expsyms_RC; do
11122
11123     case $var in
11124     old_archive_cmds_RC | \
11125     old_archive_from_new_cmds_RC | \
11126     archive_cmds_RC | \
11127     archive_expsym_cmds_RC | \
11128     module_cmds_RC | \
11129     module_expsym_cmds_RC | \
11130     old_archive_from_expsyms_cmds_RC | \
11131     export_symbols_cmds_RC | \
11132     extract_expsyms_cmds | reload_cmds | finish_cmds | \
11133     postinstall_cmds | postuninstall_cmds | \
11134     old_postinstall_cmds | old_postuninstall_cmds | \
11135     sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
11136       # Double-quote double-evaled strings.
11137       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
11138       ;;
11139     *)
11140       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
11141       ;;
11142     esac
11143   done
11144
11145   case $lt_echo in
11146   *'\$0 --fallback-echo"')
11147     lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
11148     ;;
11149   esac
11150
11151 cfgfile="$ofile"
11152
11153   cat <<__EOF__ >> "$cfgfile"
11154 # ### BEGIN LIBTOOL TAG CONFIG: $tagname
11155
11156 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
11157
11158 # Shell to use when invoking shell scripts.
11159 SHELL=$lt_SHELL
11160
11161 # Whether or not to build shared libraries.
11162 build_libtool_libs=$enable_shared
11163
11164 # Whether or not to build static libraries.
11165 build_old_libs=$enable_static
11166
11167 # Whether or not to add -lc for building shared libraries.
11168 build_libtool_need_lc=$archive_cmds_need_lc_RC
11169
11170 # Whether or not to disallow shared libs when runtime libs are static
11171 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_RC
11172
11173 # Whether or not to optimize for fast installation.
11174 fast_install=$enable_fast_install
11175
11176 # The host system.
11177 host_alias=$host_alias
11178 host=$host
11179 host_os=$host_os
11180
11181 # The build system.
11182 build_alias=$build_alias
11183 build=$build
11184 build_os=$build_os
11185
11186 # An echo program that does not interpret backslashes.
11187 echo=$lt_echo
11188
11189 # The archiver.
11190 AR=$lt_AR
11191 AR_FLAGS=$lt_AR_FLAGS
11192
11193 # A C compiler.
11194 LTCC=$lt_LTCC
11195
11196 # A language-specific compiler.
11197 CC=$lt_compiler_RC
11198
11199 # Is the compiler the GNU C compiler?
11200 with_gcc=$GCC_RC
11201
11202 # An ERE matcher.
11203 EGREP=$lt_EGREP
11204
11205 # The linker used to build libraries.
11206 LD=$lt_LD_RC
11207
11208 # Whether we need hard or soft links.
11209 LN_S=$lt_LN_S
11210
11211 # A BSD-compatible nm program.
11212 NM=$lt_NM
11213
11214 # A symbol stripping program
11215 STRIP=$lt_STRIP
11216
11217 # Used to examine libraries when file_magic_cmd begins "file"
11218 MAGIC_CMD=$MAGIC_CMD
11219
11220 # Used on cygwin: DLL creation program.
11221 DLLTOOL="$DLLTOOL"
11222
11223 # Used on cygwin: object dumper.
11224 OBJDUMP="$OBJDUMP"
11225
11226 # Used on cygwin: assembler.
11227 AS="$AS"
11228
11229 # The name of the directory that contains temporary libtool files.
11230 objdir=$objdir
11231
11232 # How to create reloadable object files.
11233 reload_flag=$lt_reload_flag
11234 reload_cmds=$lt_reload_cmds
11235
11236 # How to pass a linker flag through the compiler.
11237 wl=$lt_lt_prog_compiler_wl_RC
11238
11239 # Object file suffix (normally "o").
11240 objext="$ac_objext"
11241
11242 # Old archive suffix (normally "a").
11243 libext="$libext"
11244
11245 # Shared library suffix (normally ".so").
11246 shrext_cmds='$shrext_cmds'
11247
11248 # Executable file suffix (normally "").
11249 exeext="$exeext"
11250
11251 # Additional compiler flags for building library objects.
11252 pic_flag=$lt_lt_prog_compiler_pic_RC
11253 pic_mode=$pic_mode
11254
11255 # What is the maximum length of a command?
11256 max_cmd_len=$lt_cv_sys_max_cmd_len
11257
11258 # Does compiler simultaneously support -c and -o options?
11259 compiler_c_o=$lt_lt_cv_prog_compiler_c_o_RC
11260
11261 # Must we lock files when doing compilation?
11262 need_locks=$lt_need_locks
11263
11264 # Do we need the lib prefix for modules?
11265 need_lib_prefix=$need_lib_prefix
11266
11267 # Do we need a version for libraries?
11268 need_version=$need_version
11269
11270 # Whether dlopen is supported.
11271 dlopen_support=$enable_dlopen
11272
11273 # Whether dlopen of programs is supported.
11274 dlopen_self=$enable_dlopen_self
11275
11276 # Whether dlopen of statically linked programs is supported.
11277 dlopen_self_static=$enable_dlopen_self_static
11278
11279 # Compiler flag to prevent dynamic linking.
11280 link_static_flag=$lt_lt_prog_compiler_static_RC
11281
11282 # Compiler flag to turn off builtin functions.
11283 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_RC
11284
11285 # Compiler flag to allow reflexive dlopens.
11286 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_RC
11287
11288 # Compiler flag to generate shared objects directly from archives.
11289 whole_archive_flag_spec=$lt_whole_archive_flag_spec_RC
11290
11291 # Compiler flag to generate thread-safe objects.
11292 thread_safe_flag_spec=$lt_thread_safe_flag_spec_RC
11293
11294 # Library versioning type.
11295 version_type=$version_type
11296
11297 # Format of library name prefix.
11298 libname_spec=$lt_libname_spec
11299
11300 # List of archive names.  First name is the real one, the rest are links.
11301 # The last name is the one that the linker finds with -lNAME.
11302 library_names_spec=$lt_library_names_spec
11303
11304 # The coded name of the library, if different from the real name.
11305 soname_spec=$lt_soname_spec
11306
11307 # Commands used to build and install an old-style archive.
11308 RANLIB=$lt_RANLIB
11309 old_archive_cmds=$lt_old_archive_cmds_RC
11310 old_postinstall_cmds=$lt_old_postinstall_cmds
11311 old_postuninstall_cmds=$lt_old_postuninstall_cmds
11312
11313 # Create an old-style archive from a shared archive.
11314 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_RC
11315
11316 # Create a temporary old-style archive to link instead of a shared archive.
11317 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_RC
11318
11319 # Commands used to build and install a shared archive.
11320 archive_cmds=$lt_archive_cmds_RC
11321 archive_expsym_cmds=$lt_archive_expsym_cmds_RC
11322 postinstall_cmds=$lt_postinstall_cmds
11323 postuninstall_cmds=$lt_postuninstall_cmds
11324
11325 # Commands used to build a loadable module (assumed same as above if empty)
11326 module_cmds=$lt_module_cmds_RC
11327 module_expsym_cmds=$lt_module_expsym_cmds_RC
11328
11329 # Commands to strip libraries.
11330 old_striplib=$lt_old_striplib
11331 striplib=$lt_striplib
11332
11333 # Dependencies to place before the objects being linked to create a
11334 # shared library.
11335 predep_objects=$lt_predep_objects_RC
11336
11337 # Dependencies to place after the objects being linked to create a
11338 # shared library.
11339 postdep_objects=$lt_postdep_objects_RC
11340
11341 # Dependencies to place before the objects being linked to create a
11342 # shared library.
11343 predeps=$lt_predeps_RC
11344
11345 # Dependencies to place after the objects being linked to create a
11346 # shared library.
11347 postdeps=$lt_postdeps_RC
11348
11349 # The library search path used internally by the compiler when linking
11350 # a shared library.
11351 compiler_lib_search_path=$lt_compiler_lib_search_path_RC
11352
11353 # Method to check whether dependent libraries are shared objects.
11354 deplibs_check_method=$lt_deplibs_check_method
11355
11356 # Command to use when deplibs_check_method == file_magic.
11357 file_magic_cmd=$lt_file_magic_cmd
11358
11359 # Flag that allows shared libraries with undefined symbols to be built.
11360 allow_undefined_flag=$lt_allow_undefined_flag_RC
11361
11362 # Flag that forces no undefined symbols.
11363 no_undefined_flag=$lt_no_undefined_flag_RC
11364
11365 # Commands used to finish a libtool library installation in a directory.
11366 finish_cmds=$lt_finish_cmds
11367
11368 # Same as above, but a single script fragment to be evaled but not shown.
11369 finish_eval=$lt_finish_eval
11370
11371 # Take the output of nm and produce a listing of raw symbols and C names.
11372 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
11373
11374 # Transform the output of nm in a proper C declaration
11375 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
11376
11377 # Transform the output of nm in a C name address pair
11378 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
11379
11380 # This is the shared library runtime path variable.
11381 runpath_var=$runpath_var
11382
11383 # This is the shared library path variable.
11384 shlibpath_var=$shlibpath_var
11385
11386 # Is shlibpath searched before the hard-coded library search path?
11387 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
11388
11389 # How to hardcode a shared library path into an executable.
11390 hardcode_action=$hardcode_action_RC
11391
11392 # Whether we should hardcode library paths into libraries.
11393 hardcode_into_libs=$hardcode_into_libs
11394
11395 # Flag to hardcode \$libdir into a binary during linking.
11396 # This must work even if \$libdir does not exist.
11397 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_RC
11398
11399 # If ld is used when linking, flag to hardcode \$libdir into
11400 # a binary during linking. This must work even if \$libdir does
11401 # not exist.
11402 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_RC
11403
11404 # Whether we need a single -rpath flag with a separated argument.
11405 hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC
11406
11407 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
11408 # resulting binary.
11409 hardcode_direct=$hardcode_direct_RC
11410
11411 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
11412 # resulting binary.
11413 hardcode_minus_L=$hardcode_minus_L_RC
11414
11415 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
11416 # the resulting binary.
11417 hardcode_shlibpath_var=$hardcode_shlibpath_var_RC
11418
11419 # Set to yes if building a shared library automatically hardcodes DIR into the library
11420 # and all subsequent libraries and executables linked against it.
11421 hardcode_automatic=$hardcode_automatic_RC
11422
11423 # Variables whose values should be saved in libtool wrapper scripts and
11424 # restored at relink time.
11425 variables_saved_for_relink="$variables_saved_for_relink"
11426
11427 # Whether libtool must link a program against all its dependency libraries.
11428 link_all_deplibs=$link_all_deplibs_RC
11429
11430 # Compile-time system search path for libraries
11431 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
11432
11433 # Run-time system search path for libraries
11434 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
11435
11436 # Fix the shell variable \$srcfile for the compiler.
11437 fix_srcfile_path="$fix_srcfile_path_RC"
11438
11439 # Set to yes if exported symbols are required.
11440 always_export_symbols=$always_export_symbols_RC
11441
11442 # The commands to list exported symbols.
11443 export_symbols_cmds=$lt_export_symbols_cmds_RC
11444
11445 # The commands to extract the exported symbol list from a shared archive.
11446 extract_expsyms_cmds=$lt_extract_expsyms_cmds
11447
11448 # Symbols that should not be listed in the preloaded symbols.
11449 exclude_expsyms=$lt_exclude_expsyms_RC
11450
11451 # Symbols that must always be exported.
11452 include_expsyms=$lt_include_expsyms_RC
11453
11454 # ### END LIBTOOL TAG CONFIG: $tagname
11455
11456 __EOF__
11457
11458
11459 else
11460   # If there is no Makefile yet, we rely on a make rule to execute
11461   # `config.status --recheck' to rerun these tests and create the
11462   # libtool script then.
11463   ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
11464   if test -f "$ltmain_in"; then
11465     test -f Makefile && make "$ltmain"
11466   fi
11467 fi
11468
11469
11470 ac_ext=c
11471 ac_cpp='$CPP $CPPFLAGS'
11472 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11473 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11474 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11475
11476 CC="$lt_save_CC"
11477
11478         ;;
11479
11480       *)
11481         { { echo "$as_me:$LINENO: error: Unsupported tag name: $tagname" >&5
11482 echo "$as_me: error: Unsupported tag name: $tagname" >&2;}
11483    { (exit 1); exit 1; }; }
11484         ;;
11485       esac
11486
11487       # Append the new tag name to the list of available tags.
11488       if test -n "$tagname" ; then
11489       available_tags="$available_tags $tagname"
11490     fi
11491     fi
11492   done
11493   IFS="$lt_save_ifs"
11494
11495   # Now substitute the updated list of available tags.
11496   if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
11497     mv "${ofile}T" "$ofile"
11498     chmod +x "$ofile"
11499   else
11500     rm -f "${ofile}T"
11501     { { echo "$as_me:$LINENO: error: unable to update list of available tagged configurations." >&5
11502 echo "$as_me: error: unable to update list of available tagged configurations." >&2;}
11503    { (exit 1); exit 1; }; }
11504   fi
11505 fi
11506
11507
11508
11509 # This can be used to rebuild libtool when needed
11510 LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
11511
11512 # Always use our own libtool.
11513 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
11514
11515 # Prevent multiple expansion
11516
11517
11518
11519
11520
11521
11522
11523
11524
11525
11526 ol_link_perl=no
11527 if test $ol_enable_perl != no ; then
11528         # Extract the first word of "perl", so it can be a program name with args.
11529 set dummy perl; ac_word=$2
11530 echo "$as_me:$LINENO: checking for $ac_word" >&5
11531 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11532 if test "${ac_cv_path_PERLBIN+set}" = set; then
11533   echo $ECHO_N "(cached) $ECHO_C" >&6
11534 else
11535   case $PERLBIN in
11536   [\\/]* | ?:[\\/]*)
11537   ac_cv_path_PERLBIN="$PERLBIN" # Let the user override the test with a path.
11538   ;;
11539   *)
11540   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11541 for as_dir in $PATH
11542 do
11543   IFS=$as_save_IFS
11544   test -z "$as_dir" && as_dir=.
11545   for ac_exec_ext in '' $ac_executable_extensions; do
11546   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11547     ac_cv_path_PERLBIN="$as_dir/$ac_word$ac_exec_ext"
11548     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11549     break 2
11550   fi
11551 done
11552 done
11553
11554   test -z "$ac_cv_path_PERLBIN" && ac_cv_path_PERLBIN="/usr/bin/perl"
11555   ;;
11556 esac
11557 fi
11558 PERLBIN=$ac_cv_path_PERLBIN
11559
11560 if test -n "$PERLBIN"; then
11561   echo "$as_me:$LINENO: result: $PERLBIN" >&5
11562 echo "${ECHO_T}$PERLBIN" >&6
11563 else
11564   echo "$as_me:$LINENO: result: no" >&5
11565 echo "${ECHO_T}no" >&6
11566 fi
11567
11568
11569         if test "no$PERLBIN" = "no" ; then
11570                 if test $ol_enable_perl = yes ; then
11571                         { { echo "$as_me:$LINENO: error: could not locate perl" >&5
11572 echo "$as_me: error: could not locate perl" >&2;}
11573    { (exit 1); exit 1; }; }
11574                 fi
11575
11576         else
11577                 PERL_CPPFLAGS="`$PERLBIN -MExtUtils::Embed -e ccopts`"
11578                 PERL_LDFLAGS="`$PERLBIN -MExtUtils::Embed -e ldopts|sed -e 's/ -lc / /' -e 's/ -lc$//'`"
11579
11580                 if test x"$ol_enable_perl" = "xyes" ; then
11581                         SLAPD_PERL_LDFLAGS="$PERL_LDFLAGS"
11582                 else
11583                         MOD_PERL_LDFLAGS="$PERL_LDFLAGS"
11584                 fi
11585                                 ol_link_perl=yes
11586         fi
11587 fi
11588
11589 ac_ext=c
11590 ac_cpp='$CPP $CPPFLAGS'
11591 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11592 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11593 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11594 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
11595 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
11596 # On Suns, sometimes $CPP names a directory.
11597 if test -n "$CPP" && test -d "$CPP"; then
11598   CPP=
11599 fi
11600 if test -z "$CPP"; then
11601   if test "${ac_cv_prog_CPP+set}" = set; then
11602   echo $ECHO_N "(cached) $ECHO_C" >&6
11603 else
11604       # Double quotes because CPP needs to be expanded
11605     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
11606     do
11607       ac_preproc_ok=false
11608 for ac_c_preproc_warn_flag in '' yes
11609 do
11610   # Use a header file that comes with gcc, so configuring glibc
11611   # with a fresh cross-compiler works.
11612   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11613   # <limits.h> exists even on freestanding compilers.
11614   # On the NeXT, cc -E runs the code through the compiler's parser,
11615   # not just through cpp. "Syntax error" is here to catch this case.
11616   cat >conftest.$ac_ext <<_ACEOF
11617 /* confdefs.h.  */
11618 _ACEOF
11619 cat confdefs.h >>conftest.$ac_ext
11620 cat >>conftest.$ac_ext <<_ACEOF
11621 /* end confdefs.h.  */
11622 #ifdef __STDC__
11623 # include <limits.h>
11624 #else
11625 # include <assert.h>
11626 #endif
11627                      Syntax error
11628 _ACEOF
11629 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11630   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11631   ac_status=$?
11632   grep -v '^ *+' conftest.er1 >conftest.err
11633   rm -f conftest.er1
11634   cat conftest.err >&5
11635   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11636   (exit $ac_status); } >/dev/null; then
11637   if test -s conftest.err; then
11638     ac_cpp_err=$ac_c_preproc_warn_flag
11639     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11640   else
11641     ac_cpp_err=
11642   fi
11643 else
11644   ac_cpp_err=yes
11645 fi
11646 if test -z "$ac_cpp_err"; then
11647   :
11648 else
11649   echo "$as_me: failed program was:" >&5
11650 sed 's/^/| /' conftest.$ac_ext >&5
11651
11652   # Broken: fails on valid input.
11653 continue
11654 fi
11655 rm -f conftest.err conftest.$ac_ext
11656
11657   # OK, works on sane cases.  Now check whether non-existent headers
11658   # can be detected and how.
11659   cat >conftest.$ac_ext <<_ACEOF
11660 /* confdefs.h.  */
11661 _ACEOF
11662 cat confdefs.h >>conftest.$ac_ext
11663 cat >>conftest.$ac_ext <<_ACEOF
11664 /* end confdefs.h.  */
11665 #include <ac_nonexistent.h>
11666 _ACEOF
11667 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11668   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11669   ac_status=$?
11670   grep -v '^ *+' conftest.er1 >conftest.err
11671   rm -f conftest.er1
11672   cat conftest.err >&5
11673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11674   (exit $ac_status); } >/dev/null; then
11675   if test -s conftest.err; then
11676     ac_cpp_err=$ac_c_preproc_warn_flag
11677     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11678   else
11679     ac_cpp_err=
11680   fi
11681 else
11682   ac_cpp_err=yes
11683 fi
11684 if test -z "$ac_cpp_err"; then
11685   # Broken: success on invalid input.
11686 continue
11687 else
11688   echo "$as_me: failed program was:" >&5
11689 sed 's/^/| /' conftest.$ac_ext >&5
11690
11691   # Passes both tests.
11692 ac_preproc_ok=:
11693 break
11694 fi
11695 rm -f conftest.err conftest.$ac_ext
11696
11697 done
11698 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
11699 rm -f conftest.err conftest.$ac_ext
11700 if $ac_preproc_ok; then
11701   break
11702 fi
11703
11704     done
11705     ac_cv_prog_CPP=$CPP
11706
11707 fi
11708   CPP=$ac_cv_prog_CPP
11709 else
11710   ac_cv_prog_CPP=$CPP
11711 fi
11712 echo "$as_me:$LINENO: result: $CPP" >&5
11713 echo "${ECHO_T}$CPP" >&6
11714 ac_preproc_ok=false
11715 for ac_c_preproc_warn_flag in '' yes
11716 do
11717   # Use a header file that comes with gcc, so configuring glibc
11718   # with a fresh cross-compiler works.
11719   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11720   # <limits.h> exists even on freestanding compilers.
11721   # On the NeXT, cc -E runs the code through the compiler's parser,
11722   # not just through cpp. "Syntax error" is here to catch this case.
11723   cat >conftest.$ac_ext <<_ACEOF
11724 /* confdefs.h.  */
11725 _ACEOF
11726 cat confdefs.h >>conftest.$ac_ext
11727 cat >>conftest.$ac_ext <<_ACEOF
11728 /* end confdefs.h.  */
11729 #ifdef __STDC__
11730 # include <limits.h>
11731 #else
11732 # include <assert.h>
11733 #endif
11734                      Syntax error
11735 _ACEOF
11736 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11737   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11738   ac_status=$?
11739   grep -v '^ *+' conftest.er1 >conftest.err
11740   rm -f conftest.er1
11741   cat conftest.err >&5
11742   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11743   (exit $ac_status); } >/dev/null; then
11744   if test -s conftest.err; then
11745     ac_cpp_err=$ac_c_preproc_warn_flag
11746     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11747   else
11748     ac_cpp_err=
11749   fi
11750 else
11751   ac_cpp_err=yes
11752 fi
11753 if test -z "$ac_cpp_err"; then
11754   :
11755 else
11756   echo "$as_me: failed program was:" >&5
11757 sed 's/^/| /' conftest.$ac_ext >&5
11758
11759   # Broken: fails on valid input.
11760 continue
11761 fi
11762 rm -f conftest.err conftest.$ac_ext
11763
11764   # OK, works on sane cases.  Now check whether non-existent headers
11765   # can be detected and how.
11766   cat >conftest.$ac_ext <<_ACEOF
11767 /* confdefs.h.  */
11768 _ACEOF
11769 cat confdefs.h >>conftest.$ac_ext
11770 cat >>conftest.$ac_ext <<_ACEOF
11771 /* end confdefs.h.  */
11772 #include <ac_nonexistent.h>
11773 _ACEOF
11774 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11775   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11776   ac_status=$?
11777   grep -v '^ *+' conftest.er1 >conftest.err
11778   rm -f conftest.er1
11779   cat conftest.err >&5
11780   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11781   (exit $ac_status); } >/dev/null; then
11782   if test -s conftest.err; then
11783     ac_cpp_err=$ac_c_preproc_warn_flag
11784     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
11785   else
11786     ac_cpp_err=
11787   fi
11788 else
11789   ac_cpp_err=yes
11790 fi
11791 if test -z "$ac_cpp_err"; then
11792   # Broken: success on invalid input.
11793 continue
11794 else
11795   echo "$as_me: failed program was:" >&5
11796 sed 's/^/| /' conftest.$ac_ext >&5
11797
11798   # Passes both tests.
11799 ac_preproc_ok=:
11800 break
11801 fi
11802 rm -f conftest.err conftest.$ac_ext
11803
11804 done
11805 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
11806 rm -f conftest.err conftest.$ac_ext
11807 if $ac_preproc_ok; then
11808   :
11809 else
11810   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
11811 See \`config.log' for more details." >&5
11812 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
11813 See \`config.log' for more details." >&2;}
11814    { (exit 1); exit 1; }; }
11815 fi
11816
11817 ac_ext=c
11818 ac_cpp='$CPP $CPPFLAGS'
11819 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11820 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11821 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11822
11823
11824 case $host_os in
11825   *mingw32* ) ac_cv_mingw32=yes ;;
11826   *cygwin* ) ac_cv_cygwin=yes ;;
11827 esac
11828
11829
11830
11831
11832 cat >>confdefs.h <<_ACEOF
11833 #define EXEEXT "${EXEEXT}"
11834 _ACEOF
11835
11836
11837 echo "$as_me:$LINENO: checking for be_app in -lbe" >&5
11838 echo $ECHO_N "checking for be_app in -lbe... $ECHO_C" >&6
11839 if test "${ac_cv_lib_be_be_app+set}" = set; then
11840   echo $ECHO_N "(cached) $ECHO_C" >&6
11841 else
11842   ac_check_lib_save_LIBS=$LIBS
11843 LIBS="-lbe -lroot -lnet $LIBS"
11844 cat >conftest.$ac_ext <<_ACEOF
11845 /* confdefs.h.  */
11846 _ACEOF
11847 cat confdefs.h >>conftest.$ac_ext
11848 cat >>conftest.$ac_ext <<_ACEOF
11849 /* end confdefs.h.  */
11850
11851 /* Override any gcc2 internal prototype to avoid an error.  */
11852 #ifdef __cplusplus
11853 extern "C"
11854 #endif
11855 /* We use char because int might match the return type of a gcc2
11856    builtin and then its argument prototype would still apply.  */
11857 char be_app ();
11858 int
11859 main ()
11860 {
11861 be_app ();
11862   ;
11863   return 0;
11864 }
11865 _ACEOF
11866 rm -f conftest.$ac_objext conftest$ac_exeext
11867 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11868   (eval $ac_link) 2>conftest.er1
11869   ac_status=$?
11870   grep -v '^ *+' conftest.er1 >conftest.err
11871   rm -f conftest.er1
11872   cat conftest.err >&5
11873   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11874   (exit $ac_status); } &&
11875          { ac_try='test -z "$ac_c_werror_flag"
11876                          || test ! -s conftest.err'
11877   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11878   (eval $ac_try) 2>&5
11879   ac_status=$?
11880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11881   (exit $ac_status); }; } &&
11882          { ac_try='test -s conftest$ac_exeext'
11883   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11884   (eval $ac_try) 2>&5
11885   ac_status=$?
11886   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11887   (exit $ac_status); }; }; then
11888   ac_cv_lib_be_be_app=yes
11889 else
11890   echo "$as_me: failed program was:" >&5
11891 sed 's/^/| /' conftest.$ac_ext >&5
11892
11893 ac_cv_lib_be_be_app=no
11894 fi
11895 rm -f conftest.err conftest.$ac_objext \
11896       conftest$ac_exeext conftest.$ac_ext
11897 LIBS=$ac_check_lib_save_LIBS
11898 fi
11899 echo "$as_me:$LINENO: result: $ac_cv_lib_be_be_app" >&5
11900 echo "${ECHO_T}$ac_cv_lib_be_be_app" >&6
11901 if test $ac_cv_lib_be_be_app = yes; then
11902   LIBS="$LIBS -lbe -lroot -lnet"
11903 else
11904   :
11905 fi
11906
11907
11908 ac_ext=c
11909 ac_cpp='$CPP $CPPFLAGS'
11910 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11911 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11912 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11913 if test -n "$ac_tool_prefix"; then
11914   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
11915 set dummy ${ac_tool_prefix}gcc; ac_word=$2
11916 echo "$as_me:$LINENO: checking for $ac_word" >&5
11917 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11918 if test "${ac_cv_prog_CC+set}" = set; then
11919   echo $ECHO_N "(cached) $ECHO_C" >&6
11920 else
11921   if test -n "$CC"; then
11922   ac_cv_prog_CC="$CC" # Let the user override the test.
11923 else
11924 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11925 for as_dir in $PATH
11926 do
11927   IFS=$as_save_IFS
11928   test -z "$as_dir" && as_dir=.
11929   for ac_exec_ext in '' $ac_executable_extensions; do
11930   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11931     ac_cv_prog_CC="${ac_tool_prefix}gcc"
11932     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11933     break 2
11934   fi
11935 done
11936 done
11937
11938 fi
11939 fi
11940 CC=$ac_cv_prog_CC
11941 if test -n "$CC"; then
11942   echo "$as_me:$LINENO: result: $CC" >&5
11943 echo "${ECHO_T}$CC" >&6
11944 else
11945   echo "$as_me:$LINENO: result: no" >&5
11946 echo "${ECHO_T}no" >&6
11947 fi
11948
11949 fi
11950 if test -z "$ac_cv_prog_CC"; then
11951   ac_ct_CC=$CC
11952   # Extract the first word of "gcc", so it can be a program name with args.
11953 set dummy gcc; ac_word=$2
11954 echo "$as_me:$LINENO: checking for $ac_word" >&5
11955 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11956 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
11957   echo $ECHO_N "(cached) $ECHO_C" >&6
11958 else
11959   if test -n "$ac_ct_CC"; then
11960   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
11961 else
11962 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11963 for as_dir in $PATH
11964 do
11965   IFS=$as_save_IFS
11966   test -z "$as_dir" && as_dir=.
11967   for ac_exec_ext in '' $ac_executable_extensions; do
11968   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11969     ac_cv_prog_ac_ct_CC="gcc"
11970     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11971     break 2
11972   fi
11973 done
11974 done
11975
11976 fi
11977 fi
11978 ac_ct_CC=$ac_cv_prog_ac_ct_CC
11979 if test -n "$ac_ct_CC"; then
11980   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
11981 echo "${ECHO_T}$ac_ct_CC" >&6
11982 else
11983   echo "$as_me:$LINENO: result: no" >&5
11984 echo "${ECHO_T}no" >&6
11985 fi
11986
11987   CC=$ac_ct_CC
11988 else
11989   CC="$ac_cv_prog_CC"
11990 fi
11991
11992 if test -z "$CC"; then
11993   if test -n "$ac_tool_prefix"; then
11994   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
11995 set dummy ${ac_tool_prefix}cc; ac_word=$2
11996 echo "$as_me:$LINENO: checking for $ac_word" >&5
11997 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11998 if test "${ac_cv_prog_CC+set}" = set; then
11999   echo $ECHO_N "(cached) $ECHO_C" >&6
12000 else
12001   if test -n "$CC"; then
12002   ac_cv_prog_CC="$CC" # Let the user override the test.
12003 else
12004 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12005 for as_dir in $PATH
12006 do
12007   IFS=$as_save_IFS
12008   test -z "$as_dir" && as_dir=.
12009   for ac_exec_ext in '' $ac_executable_extensions; do
12010   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12011     ac_cv_prog_CC="${ac_tool_prefix}cc"
12012     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12013     break 2
12014   fi
12015 done
12016 done
12017
12018 fi
12019 fi
12020 CC=$ac_cv_prog_CC
12021 if test -n "$CC"; then
12022   echo "$as_me:$LINENO: result: $CC" >&5
12023 echo "${ECHO_T}$CC" >&6
12024 else
12025   echo "$as_me:$LINENO: result: no" >&5
12026 echo "${ECHO_T}no" >&6
12027 fi
12028
12029 fi
12030 if test -z "$ac_cv_prog_CC"; then
12031   ac_ct_CC=$CC
12032   # Extract the first word of "cc", so it can be a program name with args.
12033 set dummy cc; ac_word=$2
12034 echo "$as_me:$LINENO: checking for $ac_word" >&5
12035 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12036 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
12037   echo $ECHO_N "(cached) $ECHO_C" >&6
12038 else
12039   if test -n "$ac_ct_CC"; then
12040   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
12041 else
12042 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12043 for as_dir in $PATH
12044 do
12045   IFS=$as_save_IFS
12046   test -z "$as_dir" && as_dir=.
12047   for ac_exec_ext in '' $ac_executable_extensions; do
12048   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12049     ac_cv_prog_ac_ct_CC="cc"
12050     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12051     break 2
12052   fi
12053 done
12054 done
12055
12056 fi
12057 fi
12058 ac_ct_CC=$ac_cv_prog_ac_ct_CC
12059 if test -n "$ac_ct_CC"; then
12060   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
12061 echo "${ECHO_T}$ac_ct_CC" >&6
12062 else
12063   echo "$as_me:$LINENO: result: no" >&5
12064 echo "${ECHO_T}no" >&6
12065 fi
12066
12067   CC=$ac_ct_CC
12068 else
12069   CC="$ac_cv_prog_CC"
12070 fi
12071
12072 fi
12073 if test -z "$CC"; then
12074   # Extract the first word of "cc", so it can be a program name with args.
12075 set dummy cc; ac_word=$2
12076 echo "$as_me:$LINENO: checking for $ac_word" >&5
12077 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12078 if test "${ac_cv_prog_CC+set}" = set; then
12079   echo $ECHO_N "(cached) $ECHO_C" >&6
12080 else
12081   if test -n "$CC"; then
12082   ac_cv_prog_CC="$CC" # Let the user override the test.
12083 else
12084   ac_prog_rejected=no
12085 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12086 for as_dir in $PATH
12087 do
12088   IFS=$as_save_IFS
12089   test -z "$as_dir" && as_dir=.
12090   for ac_exec_ext in '' $ac_executable_extensions; do
12091   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12092     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
12093        ac_prog_rejected=yes
12094        continue
12095      fi
12096     ac_cv_prog_CC="cc"
12097     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12098     break 2
12099   fi
12100 done
12101 done
12102
12103 if test $ac_prog_rejected = yes; then
12104   # We found a bogon in the path, so make sure we never use it.
12105   set dummy $ac_cv_prog_CC
12106   shift
12107   if test $# != 0; then
12108     # We chose a different compiler from the bogus one.
12109     # However, it has the same basename, so the bogon will be chosen
12110     # first if we set CC to just the basename; use the full file name.
12111     shift
12112     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
12113   fi
12114 fi
12115 fi
12116 fi
12117 CC=$ac_cv_prog_CC
12118 if test -n "$CC"; then
12119   echo "$as_me:$LINENO: result: $CC" >&5
12120 echo "${ECHO_T}$CC" >&6
12121 else
12122   echo "$as_me:$LINENO: result: no" >&5
12123 echo "${ECHO_T}no" >&6
12124 fi
12125
12126 fi
12127 if test -z "$CC"; then
12128   if test -n "$ac_tool_prefix"; then
12129   for ac_prog in cl
12130   do
12131     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
12132 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
12133 echo "$as_me:$LINENO: checking for $ac_word" >&5
12134 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12135 if test "${ac_cv_prog_CC+set}" = set; then
12136   echo $ECHO_N "(cached) $ECHO_C" >&6
12137 else
12138   if test -n "$CC"; then
12139   ac_cv_prog_CC="$CC" # Let the user override the test.
12140 else
12141 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12142 for as_dir in $PATH
12143 do
12144   IFS=$as_save_IFS
12145   test -z "$as_dir" && as_dir=.
12146   for ac_exec_ext in '' $ac_executable_extensions; do
12147   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12148     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
12149     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12150     break 2
12151   fi
12152 done
12153 done
12154
12155 fi
12156 fi
12157 CC=$ac_cv_prog_CC
12158 if test -n "$CC"; then
12159   echo "$as_me:$LINENO: result: $CC" >&5
12160 echo "${ECHO_T}$CC" >&6
12161 else
12162   echo "$as_me:$LINENO: result: no" >&5
12163 echo "${ECHO_T}no" >&6
12164 fi
12165
12166     test -n "$CC" && break
12167   done
12168 fi
12169 if test -z "$CC"; then
12170   ac_ct_CC=$CC
12171   for ac_prog in cl
12172 do
12173   # Extract the first word of "$ac_prog", so it can be a program name with args.
12174 set dummy $ac_prog; ac_word=$2
12175 echo "$as_me:$LINENO: checking for $ac_word" >&5
12176 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12177 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
12178   echo $ECHO_N "(cached) $ECHO_C" >&6
12179 else
12180   if test -n "$ac_ct_CC"; then
12181   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
12182 else
12183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12184 for as_dir in $PATH
12185 do
12186   IFS=$as_save_IFS
12187   test -z "$as_dir" && as_dir=.
12188   for ac_exec_ext in '' $ac_executable_extensions; do
12189   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12190     ac_cv_prog_ac_ct_CC="$ac_prog"
12191     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12192     break 2
12193   fi
12194 done
12195 done
12196
12197 fi
12198 fi
12199 ac_ct_CC=$ac_cv_prog_ac_ct_CC
12200 if test -n "$ac_ct_CC"; then
12201   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
12202 echo "${ECHO_T}$ac_ct_CC" >&6
12203 else
12204   echo "$as_me:$LINENO: result: no" >&5
12205 echo "${ECHO_T}no" >&6
12206 fi
12207
12208   test -n "$ac_ct_CC" && break
12209 done
12210
12211   CC=$ac_ct_CC
12212 fi
12213
12214 fi
12215
12216
12217 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
12218 See \`config.log' for more details." >&5
12219 echo "$as_me: error: no acceptable C compiler found in \$PATH
12220 See \`config.log' for more details." >&2;}
12221    { (exit 1); exit 1; }; }
12222
12223 # Provide some information about the compiler.
12224 echo "$as_me:$LINENO:" \
12225      "checking for C compiler version" >&5
12226 ac_compiler=`set X $ac_compile; echo $2`
12227 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
12228   (eval $ac_compiler --version </dev/null >&5) 2>&5
12229   ac_status=$?
12230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12231   (exit $ac_status); }
12232 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
12233   (eval $ac_compiler -v </dev/null >&5) 2>&5
12234   ac_status=$?
12235   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12236   (exit $ac_status); }
12237 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
12238   (eval $ac_compiler -V </dev/null >&5) 2>&5
12239   ac_status=$?
12240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12241   (exit $ac_status); }
12242
12243 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
12244 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
12245 if test "${ac_cv_c_compiler_gnu+set}" = set; then
12246   echo $ECHO_N "(cached) $ECHO_C" >&6
12247 else
12248   cat >conftest.$ac_ext <<_ACEOF
12249 /* confdefs.h.  */
12250 _ACEOF
12251 cat confdefs.h >>conftest.$ac_ext
12252 cat >>conftest.$ac_ext <<_ACEOF
12253 /* end confdefs.h.  */
12254
12255 int
12256 main ()
12257 {
12258 #ifndef __GNUC__
12259        choke me
12260 #endif
12261
12262   ;
12263   return 0;
12264 }
12265 _ACEOF
12266 rm -f conftest.$ac_objext
12267 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12268   (eval $ac_compile) 2>conftest.er1
12269   ac_status=$?
12270   grep -v '^ *+' conftest.er1 >conftest.err
12271   rm -f conftest.er1
12272   cat conftest.err >&5
12273   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12274   (exit $ac_status); } &&
12275          { ac_try='test -z "$ac_c_werror_flag"
12276                          || test ! -s conftest.err'
12277   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12278   (eval $ac_try) 2>&5
12279   ac_status=$?
12280   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12281   (exit $ac_status); }; } &&
12282          { ac_try='test -s conftest.$ac_objext'
12283   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12284   (eval $ac_try) 2>&5
12285   ac_status=$?
12286   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12287   (exit $ac_status); }; }; then
12288   ac_compiler_gnu=yes
12289 else
12290   echo "$as_me: failed program was:" >&5
12291 sed 's/^/| /' conftest.$ac_ext >&5
12292
12293 ac_compiler_gnu=no
12294 fi
12295 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12296 ac_cv_c_compiler_gnu=$ac_compiler_gnu
12297
12298 fi
12299 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
12300 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
12301 GCC=`test $ac_compiler_gnu = yes && echo yes`
12302 ac_test_CFLAGS=${CFLAGS+set}
12303 ac_save_CFLAGS=$CFLAGS
12304 CFLAGS="-g"
12305 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
12306 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
12307 if test "${ac_cv_prog_cc_g+set}" = set; then
12308   echo $ECHO_N "(cached) $ECHO_C" >&6
12309 else
12310   cat >conftest.$ac_ext <<_ACEOF
12311 /* confdefs.h.  */
12312 _ACEOF
12313 cat confdefs.h >>conftest.$ac_ext
12314 cat >>conftest.$ac_ext <<_ACEOF
12315 /* end confdefs.h.  */
12316
12317 int
12318 main ()
12319 {
12320
12321   ;
12322   return 0;
12323 }
12324 _ACEOF
12325 rm -f conftest.$ac_objext
12326 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12327   (eval $ac_compile) 2>conftest.er1
12328   ac_status=$?
12329   grep -v '^ *+' conftest.er1 >conftest.err
12330   rm -f conftest.er1
12331   cat conftest.err >&5
12332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12333   (exit $ac_status); } &&
12334          { ac_try='test -z "$ac_c_werror_flag"
12335                          || test ! -s conftest.err'
12336   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12337   (eval $ac_try) 2>&5
12338   ac_status=$?
12339   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12340   (exit $ac_status); }; } &&
12341          { ac_try='test -s conftest.$ac_objext'
12342   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12343   (eval $ac_try) 2>&5
12344   ac_status=$?
12345   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12346   (exit $ac_status); }; }; then
12347   ac_cv_prog_cc_g=yes
12348 else
12349   echo "$as_me: failed program was:" >&5
12350 sed 's/^/| /' conftest.$ac_ext >&5
12351
12352 ac_cv_prog_cc_g=no
12353 fi
12354 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12355 fi
12356 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
12357 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
12358 if test "$ac_test_CFLAGS" = set; then
12359   CFLAGS=$ac_save_CFLAGS
12360 elif test $ac_cv_prog_cc_g = yes; then
12361   if test "$GCC" = yes; then
12362     CFLAGS="-g -O2"
12363   else
12364     CFLAGS="-g"
12365   fi
12366 else
12367   if test "$GCC" = yes; then
12368     CFLAGS="-O2"
12369   else
12370     CFLAGS=
12371   fi
12372 fi
12373 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
12374 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
12375 if test "${ac_cv_prog_cc_stdc+set}" = set; then
12376   echo $ECHO_N "(cached) $ECHO_C" >&6
12377 else
12378   ac_cv_prog_cc_stdc=no
12379 ac_save_CC=$CC
12380 cat >conftest.$ac_ext <<_ACEOF
12381 /* confdefs.h.  */
12382 _ACEOF
12383 cat confdefs.h >>conftest.$ac_ext
12384 cat >>conftest.$ac_ext <<_ACEOF
12385 /* end confdefs.h.  */
12386 #include <stdarg.h>
12387 #include <stdio.h>
12388 #include <sys/types.h>
12389 #include <sys/stat.h>
12390 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
12391 struct buf { int x; };
12392 FILE * (*rcsopen) (struct buf *, struct stat *, int);
12393 static char *e (p, i)
12394      char **p;
12395      int i;
12396 {
12397   return p[i];
12398 }
12399 static char *f (char * (*g) (char **, int), char **p, ...)
12400 {
12401   char *s;
12402   va_list v;
12403   va_start (v,p);
12404   s = g (p, va_arg (v,int));
12405   va_end (v);
12406   return s;
12407 }
12408
12409 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
12410    function prototypes and stuff, but not '\xHH' hex character constants.
12411    These don't provoke an error unfortunately, instead are silently treated
12412    as 'x'.  The following induces an error, until -std1 is added to get
12413    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
12414    array size at least.  It's necessary to write '\x00'==0 to get something
12415    that's true only with -std1.  */
12416 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
12417
12418 int test (int i, double x);
12419 struct s1 {int (*f) (int a);};
12420 struct s2 {int (*f) (double a);};
12421 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
12422 int argc;
12423 char **argv;
12424 int
12425 main ()
12426 {
12427 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
12428   ;
12429   return 0;
12430 }
12431 _ACEOF
12432 # Don't try gcc -ansi; that turns off useful extensions and
12433 # breaks some systems' header files.
12434 # AIX                   -qlanglvl=ansi
12435 # Ultrix and OSF/1      -std1
12436 # HP-UX 10.20 and later -Ae
12437 # HP-UX older versions  -Aa -D_HPUX_SOURCE
12438 # SVR4                  -Xc -D__EXTENSIONS__
12439 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
12440 do
12441   CC="$ac_save_CC $ac_arg"
12442   rm -f conftest.$ac_objext
12443 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12444   (eval $ac_compile) 2>conftest.er1
12445   ac_status=$?
12446   grep -v '^ *+' conftest.er1 >conftest.err
12447   rm -f conftest.er1
12448   cat conftest.err >&5
12449   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12450   (exit $ac_status); } &&
12451          { ac_try='test -z "$ac_c_werror_flag"
12452                          || test ! -s conftest.err'
12453   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12454   (eval $ac_try) 2>&5
12455   ac_status=$?
12456   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12457   (exit $ac_status); }; } &&
12458          { ac_try='test -s conftest.$ac_objext'
12459   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12460   (eval $ac_try) 2>&5
12461   ac_status=$?
12462   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12463   (exit $ac_status); }; }; then
12464   ac_cv_prog_cc_stdc=$ac_arg
12465 break
12466 else
12467   echo "$as_me: failed program was:" >&5
12468 sed 's/^/| /' conftest.$ac_ext >&5
12469
12470 fi
12471 rm -f conftest.err conftest.$ac_objext
12472 done
12473 rm -f conftest.$ac_ext conftest.$ac_objext
12474 CC=$ac_save_CC
12475
12476 fi
12477
12478 case "x$ac_cv_prog_cc_stdc" in
12479   x|xno)
12480     echo "$as_me:$LINENO: result: none needed" >&5
12481 echo "${ECHO_T}none needed" >&6 ;;
12482   *)
12483     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
12484 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
12485     CC="$CC $ac_cv_prog_cc_stdc" ;;
12486 esac
12487
12488 # Some people use a C++ compiler to compile C.  Since we use `exit',
12489 # in C++ we need to declare it.  In case someone uses the same compiler
12490 # for both compiling C and C++ we need to have the C++ compiler decide
12491 # the declaration of exit, since it's the most demanding environment.
12492 cat >conftest.$ac_ext <<_ACEOF
12493 #ifndef __cplusplus
12494   choke me
12495 #endif
12496 _ACEOF
12497 rm -f conftest.$ac_objext
12498 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12499   (eval $ac_compile) 2>conftest.er1
12500   ac_status=$?
12501   grep -v '^ *+' conftest.er1 >conftest.err
12502   rm -f conftest.er1
12503   cat conftest.err >&5
12504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12505   (exit $ac_status); } &&
12506          { ac_try='test -z "$ac_c_werror_flag"
12507                          || test ! -s conftest.err'
12508   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12509   (eval $ac_try) 2>&5
12510   ac_status=$?
12511   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12512   (exit $ac_status); }; } &&
12513          { ac_try='test -s conftest.$ac_objext'
12514   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12515   (eval $ac_try) 2>&5
12516   ac_status=$?
12517   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12518   (exit $ac_status); }; }; then
12519   for ac_declaration in \
12520    '' \
12521    'extern "C" void std::exit (int) throw (); using std::exit;' \
12522    'extern "C" void std::exit (int); using std::exit;' \
12523    'extern "C" void exit (int) throw ();' \
12524    'extern "C" void exit (int);' \
12525    'void exit (int);'
12526 do
12527   cat >conftest.$ac_ext <<_ACEOF
12528 /* confdefs.h.  */
12529 _ACEOF
12530 cat confdefs.h >>conftest.$ac_ext
12531 cat >>conftest.$ac_ext <<_ACEOF
12532 /* end confdefs.h.  */
12533 $ac_declaration
12534 #include <stdlib.h>
12535 int
12536 main ()
12537 {
12538 exit (42);
12539   ;
12540   return 0;
12541 }
12542 _ACEOF
12543 rm -f conftest.$ac_objext
12544 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12545   (eval $ac_compile) 2>conftest.er1
12546   ac_status=$?
12547   grep -v '^ *+' conftest.er1 >conftest.err
12548   rm -f conftest.er1
12549   cat conftest.err >&5
12550   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12551   (exit $ac_status); } &&
12552          { ac_try='test -z "$ac_c_werror_flag"
12553                          || test ! -s conftest.err'
12554   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12555   (eval $ac_try) 2>&5
12556   ac_status=$?
12557   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12558   (exit $ac_status); }; } &&
12559          { ac_try='test -s conftest.$ac_objext'
12560   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12561   (eval $ac_try) 2>&5
12562   ac_status=$?
12563   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12564   (exit $ac_status); }; }; then
12565   :
12566 else
12567   echo "$as_me: failed program was:" >&5
12568 sed 's/^/| /' conftest.$ac_ext >&5
12569
12570 continue
12571 fi
12572 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12573   cat >conftest.$ac_ext <<_ACEOF
12574 /* confdefs.h.  */
12575 _ACEOF
12576 cat confdefs.h >>conftest.$ac_ext
12577 cat >>conftest.$ac_ext <<_ACEOF
12578 /* end confdefs.h.  */
12579 $ac_declaration
12580 int
12581 main ()
12582 {
12583 exit (42);
12584   ;
12585   return 0;
12586 }
12587 _ACEOF
12588 rm -f conftest.$ac_objext
12589 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12590   (eval $ac_compile) 2>conftest.er1
12591   ac_status=$?
12592   grep -v '^ *+' conftest.er1 >conftest.err
12593   rm -f conftest.er1
12594   cat conftest.err >&5
12595   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12596   (exit $ac_status); } &&
12597          { ac_try='test -z "$ac_c_werror_flag"
12598                          || test ! -s conftest.err'
12599   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12600   (eval $ac_try) 2>&5
12601   ac_status=$?
12602   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12603   (exit $ac_status); }; } &&
12604          { ac_try='test -s conftest.$ac_objext'
12605   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12606   (eval $ac_try) 2>&5
12607   ac_status=$?
12608   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12609   (exit $ac_status); }; }; then
12610   break
12611 else
12612   echo "$as_me: failed program was:" >&5
12613 sed 's/^/| /' conftest.$ac_ext >&5
12614
12615 fi
12616 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12617 done
12618 rm -f conftest*
12619 if test -n "$ac_declaration"; then
12620   echo '#ifdef __cplusplus' >>confdefs.h
12621   echo $ac_declaration      >>confdefs.h
12622   echo '#endif'             >>confdefs.h
12623 fi
12624
12625 else
12626   echo "$as_me: failed program was:" >&5
12627 sed 's/^/| /' conftest.$ac_ext >&5
12628
12629 fi
12630 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12631 ac_ext=c
12632 ac_cpp='$CPP $CPPFLAGS'
12633 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
12634 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
12635 ac_compiler_gnu=$ac_cv_c_compiler_gnu
12636
12637 depcc="$CC"   am_compiler_list=
12638
12639 echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
12640 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6
12641 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
12642   echo $ECHO_N "(cached) $ECHO_C" >&6
12643 else
12644   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
12645   # We make a subdir and do the tests there.  Otherwise we can end up
12646   # making bogus files that we don't know about and never remove.  For
12647   # instance it was reported that on HP-UX the gcc test will end up
12648   # making a dummy file named `D' -- because `-MD' means `put the output
12649   # in D'.
12650   mkdir conftest.dir
12651   # Copy depcomp to subdir because otherwise we won't find it if we're
12652   # using a relative directory.
12653   cp "$am_depcomp" conftest.dir
12654   cd conftest.dir
12655   # We will build objects and dependencies in a subdirectory because
12656   # it helps to detect inapplicable dependency modes.  For instance
12657   # both Tru64's cc and ICC support -MD to output dependencies as a
12658   # side effect of compilation, but ICC will put the dependencies in
12659   # the current directory while Tru64 will put them in the object
12660   # directory.
12661   mkdir sub
12662
12663   am_cv_CC_dependencies_compiler_type=none
12664   if test "$am_compiler_list" = ""; then
12665      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
12666   fi
12667   for depmode in $am_compiler_list; do
12668     # Setup a source with many dependencies, because some compilers
12669     # like to wrap large dependency lists on column 80 (with \), and
12670     # we should not choose a depcomp mode which is confused by this.
12671     #
12672     # We need to recreate these files for each test, as the compiler may
12673     # overwrite some of them when testing with obscure command lines.
12674     # This happens at least with the AIX C compiler.
12675     : > sub/conftest.c
12676     for i in 1 2 3 4 5 6; do
12677       echo '#include "conftst'$i'.h"' >> sub/conftest.c
12678       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
12679       # Solaris 8's {/usr,}/bin/sh.
12680       touch sub/conftst$i.h
12681     done
12682     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
12683
12684     case $depmode in
12685     nosideeffect)
12686       # after this tag, mechanisms are not by side-effect, so they'll
12687       # only be used when explicitly requested
12688       if test "x$enable_dependency_tracking" = xyes; then
12689         continue
12690       else
12691         break
12692       fi
12693       ;;
12694     none) break ;;
12695     esac
12696     # We check with `-c' and `-o' for the sake of the "dashmstdout"
12697     # mode.  It turns out that the SunPro C++ compiler does not properly
12698     # handle `-M -o', and we need to detect this.
12699     if depmode=$depmode \
12700        source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
12701        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
12702        $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
12703          >/dev/null 2>conftest.err &&
12704        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
12705        grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
12706        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
12707       # icc doesn't choke on unknown options, it will just issue warnings
12708       # or remarks (even with -Werror).  So we grep stderr for any message
12709       # that says an option was ignored or not supported.
12710       # When given -MP, icc 7.0 and 7.1 complain thusly:
12711       #   icc: Command line warning: ignoring option '-M'; no argument required
12712       # The diagnosis changed in icc 8.0:
12713       #   icc: Command line remark: option '-MP' not supported
12714       if (grep 'ignoring option' conftest.err ||
12715           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
12716         am_cv_CC_dependencies_compiler_type=$depmode
12717         break
12718       fi
12719     fi
12720   done
12721
12722   cd ..
12723   rm -rf conftest.dir
12724 else
12725   am_cv_CC_dependencies_compiler_type=none
12726 fi
12727
12728 fi
12729 echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
12730 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6
12731 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
12732
12733
12734
12735 if
12736   test "x$enable_dependency_tracking" != xno \
12737   && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
12738   am__fastdepCC_TRUE=
12739   am__fastdepCC_FALSE='#'
12740 else
12741   am__fastdepCC_TRUE='#'
12742   am__fastdepCC_FALSE=
12743 fi
12744
12745
12746 if test "X${ac_cv_prog_cc_stdc}" = "Xno" ; then
12747         { { echo "$as_me:$LINENO: error: OpenLDAP requires compiler to support STDC constructs." >&5
12748 echo "$as_me: error: OpenLDAP requires compiler to support STDC constructs." >&2;}
12749    { (exit 1); exit 1; }; }
12750 fi
12751
12752 # test for make depend flag
12753 OL_MKDEP=
12754 OL_MKDEP_FLAGS=
12755 if test -z "${MKDEP}"; then
12756         OL_MKDEP="${CC-cc}"
12757         if test -z "${MKDEP_FLAGS}"; then
12758                 echo "$as_me:$LINENO: checking for ${OL_MKDEP} depend flag" >&5
12759 echo $ECHO_N "checking for ${OL_MKDEP} depend flag... $ECHO_C" >&6
12760 if test "${ol_cv_mkdep+set}" = set; then
12761   echo $ECHO_N "(cached) $ECHO_C" >&6
12762 else
12763
12764                         ol_cv_mkdep=no
12765                         for flag in "-M" "-xM"; do
12766                                 cat > conftest.c <<EOF
12767  noCode;
12768 EOF
12769                                 if { ac_try='$OL_MKDEP $flag conftest.c'
12770   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12771   (eval $ac_try) 2>&5
12772   ac_status=$?
12773   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12774   (exit $ac_status); }; } \
12775                                         | grep '^conftest\.'"${ac_objext}" >/dev/null 2>&1
12776                                 then
12777                                         if test ! -f conftest."${ac_object}" ; then
12778                                                 ol_cv_mkdep=$flag
12779                                                 OL_MKDEP_FLAGS="$flag"
12780                                                 break
12781                                         fi
12782                                 fi
12783                         done
12784                         rm -f conftest*
12785
12786 fi
12787 echo "$as_me:$LINENO: result: $ol_cv_mkdep" >&5
12788 echo "${ECHO_T}$ol_cv_mkdep" >&6
12789                 test "$ol_cv_mkdep" = no && OL_MKDEP=":"
12790         else
12791                 cc_cv_mkdep=yes
12792                 OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
12793         fi
12794 else
12795         cc_cv_mkdep=yes
12796         OL_MKDEP="${MKDEP}"
12797         OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
12798 fi
12799
12800
12801
12802 if test "${ol_cv_mkdep}" = no ; then
12803         # this will soon become an error
12804         { echo "$as_me:$LINENO: WARNING: do not know how to generate dependencies" >&5
12805 echo "$as_me: WARNING: do not know how to generate dependencies" >&2;}
12806 fi
12807
12808 echo "$as_me:$LINENO: checking for afopen in -ls" >&5
12809 echo $ECHO_N "checking for afopen in -ls... $ECHO_C" >&6
12810 if test "${ac_cv_lib_s_afopen+set}" = set; then
12811   echo $ECHO_N "(cached) $ECHO_C" >&6
12812 else
12813   ac_check_lib_save_LIBS=$LIBS
12814 LIBS="-ls  $LIBS"
12815 cat >conftest.$ac_ext <<_ACEOF
12816 /* confdefs.h.  */
12817 _ACEOF
12818 cat confdefs.h >>conftest.$ac_ext
12819 cat >>conftest.$ac_ext <<_ACEOF
12820 /* end confdefs.h.  */
12821
12822 /* Override any gcc2 internal prototype to avoid an error.  */
12823 #ifdef __cplusplus
12824 extern "C"
12825 #endif
12826 /* We use char because int might match the return type of a gcc2
12827    builtin and then its argument prototype would still apply.  */
12828 char afopen ();
12829 int
12830 main ()
12831 {
12832 afopen ();
12833   ;
12834   return 0;
12835 }
12836 _ACEOF
12837 rm -f conftest.$ac_objext conftest$ac_exeext
12838 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12839   (eval $ac_link) 2>conftest.er1
12840   ac_status=$?
12841   grep -v '^ *+' conftest.er1 >conftest.err
12842   rm -f conftest.er1
12843   cat conftest.err >&5
12844   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12845   (exit $ac_status); } &&
12846          { ac_try='test -z "$ac_c_werror_flag"
12847                          || test ! -s conftest.err'
12848   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12849   (eval $ac_try) 2>&5
12850   ac_status=$?
12851   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12852   (exit $ac_status); }; } &&
12853          { ac_try='test -s conftest$ac_exeext'
12854   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12855   (eval $ac_try) 2>&5
12856   ac_status=$?
12857   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12858   (exit $ac_status); }; }; then
12859   ac_cv_lib_s_afopen=yes
12860 else
12861   echo "$as_me: failed program was:" >&5
12862 sed 's/^/| /' conftest.$ac_ext >&5
12863
12864 ac_cv_lib_s_afopen=no
12865 fi
12866 rm -f conftest.err conftest.$ac_objext \
12867       conftest$ac_exeext conftest.$ac_ext
12868 LIBS=$ac_check_lib_save_LIBS
12869 fi
12870 echo "$as_me:$LINENO: result: $ac_cv_lib_s_afopen" >&5
12871 echo "${ECHO_T}$ac_cv_lib_s_afopen" >&6
12872 if test $ac_cv_lib_s_afopen = yes; then
12873
12874         AUTH_LIBS=-ls
12875
12876 cat >>confdefs.h <<\_ACEOF
12877 #define HAVE_AIX_SECURITY 1
12878 _ACEOF
12879
12880
12881 fi
12882
12883
12884 case "$target" in
12885 *-ibm-openedition)
12886         ac_cv_func_getopt=no
12887
12888 cat >>confdefs.h <<\_ACEOF
12889 #define BOTH_STRINGS_H 1
12890 _ACEOF
12891
12892         ;;
12893 esac
12894
12895 ol_link_modules=no
12896 WITH_MODULES_ENABLED=no
12897 if test $ol_enable_modules != no ; then
12898
12899 for ac_header in ltdl.h
12900 do
12901 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12902 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12903   echo "$as_me:$LINENO: checking for $ac_header" >&5
12904 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12905 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12906   echo $ECHO_N "(cached) $ECHO_C" >&6
12907 fi
12908 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12909 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12910 else
12911   # Is the header compilable?
12912 echo "$as_me:$LINENO: checking $ac_header usability" >&5
12913 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
12914 cat >conftest.$ac_ext <<_ACEOF
12915 /* confdefs.h.  */
12916 _ACEOF
12917 cat confdefs.h >>conftest.$ac_ext
12918 cat >>conftest.$ac_ext <<_ACEOF
12919 /* end confdefs.h.  */
12920 $ac_includes_default
12921 #include <$ac_header>
12922 _ACEOF
12923 rm -f conftest.$ac_objext
12924 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12925   (eval $ac_compile) 2>conftest.er1
12926   ac_status=$?
12927   grep -v '^ *+' conftest.er1 >conftest.err
12928   rm -f conftest.er1
12929   cat conftest.err >&5
12930   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12931   (exit $ac_status); } &&
12932          { ac_try='test -z "$ac_c_werror_flag"
12933                          || test ! -s conftest.err'
12934   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12935   (eval $ac_try) 2>&5
12936   ac_status=$?
12937   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12938   (exit $ac_status); }; } &&
12939          { ac_try='test -s conftest.$ac_objext'
12940   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12941   (eval $ac_try) 2>&5
12942   ac_status=$?
12943   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12944   (exit $ac_status); }; }; then
12945   ac_header_compiler=yes
12946 else
12947   echo "$as_me: failed program was:" >&5
12948 sed 's/^/| /' conftest.$ac_ext >&5
12949
12950 ac_header_compiler=no
12951 fi
12952 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12953 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12954 echo "${ECHO_T}$ac_header_compiler" >&6
12955
12956 # Is the header present?
12957 echo "$as_me:$LINENO: checking $ac_header presence" >&5
12958 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
12959 cat >conftest.$ac_ext <<_ACEOF
12960 /* confdefs.h.  */
12961 _ACEOF
12962 cat confdefs.h >>conftest.$ac_ext
12963 cat >>conftest.$ac_ext <<_ACEOF
12964 /* end confdefs.h.  */
12965 #include <$ac_header>
12966 _ACEOF
12967 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
12968   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12969   ac_status=$?
12970   grep -v '^ *+' conftest.er1 >conftest.err
12971   rm -f conftest.er1
12972   cat conftest.err >&5
12973   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12974   (exit $ac_status); } >/dev/null; then
12975   if test -s conftest.err; then
12976     ac_cpp_err=$ac_c_preproc_warn_flag
12977     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
12978   else
12979     ac_cpp_err=
12980   fi
12981 else
12982   ac_cpp_err=yes
12983 fi
12984 if test -z "$ac_cpp_err"; then
12985   ac_header_preproc=yes
12986 else
12987   echo "$as_me: failed program was:" >&5
12988 sed 's/^/| /' conftest.$ac_ext >&5
12989
12990   ac_header_preproc=no
12991 fi
12992 rm -f conftest.err conftest.$ac_ext
12993 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12994 echo "${ECHO_T}$ac_header_preproc" >&6
12995
12996 # So?  What about this header?
12997 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12998   yes:no: )
12999     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13000 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13001     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13002 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13003     ac_header_preproc=yes
13004     ;;
13005   no:yes:* )
13006     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13007 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13008     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13009 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13010     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13011 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13012     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13013 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13014     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13015 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13016     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13017 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13018     (
13019       cat <<\_ASBOX
13020 ## --------------------------------------------- ##
13021 ## Report this to <http://www.openldap.org/its/> ##
13022 ## --------------------------------------------- ##
13023 _ASBOX
13024     ) |
13025       sed "s/^/$as_me: WARNING:     /" >&2
13026     ;;
13027 esac
13028 echo "$as_me:$LINENO: checking for $ac_header" >&5
13029 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13030 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13031   echo $ECHO_N "(cached) $ECHO_C" >&6
13032 else
13033   eval "$as_ac_Header=\$ac_header_preproc"
13034 fi
13035 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13036 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13037
13038 fi
13039 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13040   cat >>confdefs.h <<_ACEOF
13041 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13042 _ACEOF
13043
13044 fi
13045
13046 done
13047
13048
13049         if test $ac_cv_header_ltdl_h = no ; then
13050                 { { echo "$as_me:$LINENO: error: could not locate libtool ltdl.h" >&5
13051 echo "$as_me: error: could not locate libtool ltdl.h" >&2;}
13052    { (exit 1); exit 1; }; }
13053         fi
13054
13055         echo "$as_me:$LINENO: checking for lt_dlinit in -lltdl" >&5
13056 echo $ECHO_N "checking for lt_dlinit in -lltdl... $ECHO_C" >&6
13057 if test "${ac_cv_lib_ltdl_lt_dlinit+set}" = set; then
13058   echo $ECHO_N "(cached) $ECHO_C" >&6
13059 else
13060   ac_check_lib_save_LIBS=$LIBS
13061 LIBS="-lltdl  $LIBS"
13062 cat >conftest.$ac_ext <<_ACEOF
13063 /* confdefs.h.  */
13064 _ACEOF
13065 cat confdefs.h >>conftest.$ac_ext
13066 cat >>conftest.$ac_ext <<_ACEOF
13067 /* end confdefs.h.  */
13068
13069 /* Override any gcc2 internal prototype to avoid an error.  */
13070 #ifdef __cplusplus
13071 extern "C"
13072 #endif
13073 /* We use char because int might match the return type of a gcc2
13074    builtin and then its argument prototype would still apply.  */
13075 char lt_dlinit ();
13076 int
13077 main ()
13078 {
13079 lt_dlinit ();
13080   ;
13081   return 0;
13082 }
13083 _ACEOF
13084 rm -f conftest.$ac_objext conftest$ac_exeext
13085 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13086   (eval $ac_link) 2>conftest.er1
13087   ac_status=$?
13088   grep -v '^ *+' conftest.er1 >conftest.err
13089   rm -f conftest.er1
13090   cat conftest.err >&5
13091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13092   (exit $ac_status); } &&
13093          { ac_try='test -z "$ac_c_werror_flag"
13094                          || test ! -s conftest.err'
13095   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13096   (eval $ac_try) 2>&5
13097   ac_status=$?
13098   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13099   (exit $ac_status); }; } &&
13100          { ac_try='test -s conftest$ac_exeext'
13101   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13102   (eval $ac_try) 2>&5
13103   ac_status=$?
13104   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13105   (exit $ac_status); }; }; then
13106   ac_cv_lib_ltdl_lt_dlinit=yes
13107 else
13108   echo "$as_me: failed program was:" >&5
13109 sed 's/^/| /' conftest.$ac_ext >&5
13110
13111 ac_cv_lib_ltdl_lt_dlinit=no
13112 fi
13113 rm -f conftest.err conftest.$ac_objext \
13114       conftest$ac_exeext conftest.$ac_ext
13115 LIBS=$ac_check_lib_save_LIBS
13116 fi
13117 echo "$as_me:$LINENO: result: $ac_cv_lib_ltdl_lt_dlinit" >&5
13118 echo "${ECHO_T}$ac_cv_lib_ltdl_lt_dlinit" >&6
13119 if test $ac_cv_lib_ltdl_lt_dlinit = yes; then
13120
13121                 MODULES_LIBS=-lltdl
13122
13123 cat >>confdefs.h <<\_ACEOF
13124 #define HAVE_LIBLTDL 1
13125 _ACEOF
13126
13127
13128 fi
13129
13130
13131         if test "$ac_cv_lib_ltdl_lt_dlinit" = no ; then
13132                 { { echo "$as_me:$LINENO: error: could not locate libtool -lltdl" >&5
13133 echo "$as_me: error: could not locate libtool -lltdl" >&2;}
13134    { (exit 1); exit 1; }; }
13135         fi
13136         ol_link_modules=yes
13137         WITH_MODULES_ENABLED=yes
13138
13139 else
13140         for i in $Backends; do
13141                 eval "ol_tmp=\$ol_enable_$i"
13142                 if test $ol_tmp = mod ; then
13143                         { echo "$as_me:$LINENO: WARNING: building static $i backend" >&5
13144 echo "$as_me: WARNING: building static $i backend" >&2;}
13145                         eval "ol_enable_$i=yes"
13146                 fi
13147         done
13148         for i in $Overlays; do
13149                 eval "ol_tmp=\$ol_enable_$i"
13150                 if test $ol_tmp = mod ; then
13151                         { echo "$as_me:$LINENO: WARNING: building static $i overlay" >&5
13152 echo "$as_me: WARNING: building static $i overlay" >&2;}
13153                         eval "ol_enable_$i=yes"
13154                 fi
13155         done
13156 fi
13157
13158 # test for EBCDIC
13159 echo "$as_me:$LINENO: checking for EBCDIC" >&5
13160 echo $ECHO_N "checking for EBCDIC... $ECHO_C" >&6
13161 if test "${ol_cv_cpp_ebcdic+set}" = set; then
13162   echo $ECHO_N "(cached) $ECHO_C" >&6
13163 else
13164
13165         cat >conftest.$ac_ext <<_ACEOF
13166 /* confdefs.h.  */
13167 _ACEOF
13168 cat confdefs.h >>conftest.$ac_ext
13169 cat >>conftest.$ac_ext <<_ACEOF
13170 /* end confdefs.h.  */
13171
13172 #if !('M' == 0xd4)
13173 #include <__ASCII__/generate_error.h>
13174 #endif
13175
13176 _ACEOF
13177 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13178   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13179   ac_status=$?
13180   grep -v '^ *+' conftest.er1 >conftest.err
13181   rm -f conftest.er1
13182   cat conftest.err >&5
13183   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13184   (exit $ac_status); } >/dev/null; then
13185   if test -s conftest.err; then
13186     ac_cpp_err=$ac_c_preproc_warn_flag
13187     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
13188   else
13189     ac_cpp_err=
13190   fi
13191 else
13192   ac_cpp_err=yes
13193 fi
13194 if test -z "$ac_cpp_err"; then
13195   ol_cv_cpp_ebcdic=yes
13196 else
13197   echo "$as_me: failed program was:" >&5
13198 sed 's/^/| /' conftest.$ac_ext >&5
13199
13200   ol_cv_cpp_ebcdic=no
13201 fi
13202 rm -f conftest.err conftest.$ac_ext
13203 fi
13204 echo "$as_me:$LINENO: result: $ol_cv_cpp_ebcdic" >&5
13205 echo "${ECHO_T}$ol_cv_cpp_ebcdic" >&6
13206 if test $ol_cv_cpp_ebcdic = yes ; then
13207
13208 cat >>confdefs.h <<\_ACEOF
13209 #define HAVE_EBCDIC 1
13210 _ACEOF
13211
13212 fi
13213
13214 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
13215 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
13216 if test "${ol_cv_header_stdc+set}" = set; then
13217   echo $ECHO_N "(cached) $ECHO_C" >&6
13218 else
13219   cat >conftest.$ac_ext <<_ACEOF
13220 /* confdefs.h.  */
13221 _ACEOF
13222 cat confdefs.h >>conftest.$ac_ext
13223 cat >>conftest.$ac_ext <<_ACEOF
13224 /* end confdefs.h.  */
13225 #include <stdlib.h>
13226 #include <stdarg.h>
13227 #include <string.h>
13228 #include <float.h>
13229 _ACEOF
13230 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13231   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13232   ac_status=$?
13233   grep -v '^ *+' conftest.er1 >conftest.err
13234   rm -f conftest.er1
13235   cat conftest.err >&5
13236   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13237   (exit $ac_status); } >/dev/null; then
13238   if test -s conftest.err; then
13239     ac_cpp_err=$ac_c_preproc_warn_flag
13240     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
13241   else
13242     ac_cpp_err=
13243   fi
13244 else
13245   ac_cpp_err=yes
13246 fi
13247 if test -z "$ac_cpp_err"; then
13248   ol_cv_header_stdc=yes
13249 else
13250   echo "$as_me: failed program was:" >&5
13251 sed 's/^/| /' conftest.$ac_ext >&5
13252
13253   ol_cv_header_stdc=no
13254 fi
13255 rm -f conftest.err conftest.$ac_ext
13256
13257 if test $ol_cv_header_stdc = yes; then
13258   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
13259 cat >conftest.$ac_ext <<_ACEOF
13260 /* confdefs.h.  */
13261 _ACEOF
13262 cat confdefs.h >>conftest.$ac_ext
13263 cat >>conftest.$ac_ext <<_ACEOF
13264 /* end confdefs.h.  */
13265 #include <string.h>
13266
13267 _ACEOF
13268 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13269   $EGREP "memchr" >/dev/null 2>&1; then
13270   :
13271 else
13272   ol_cv_header_stdc=no
13273 fi
13274 rm -f conftest*
13275
13276 fi
13277
13278 if test $ol_cv_header_stdc = yes; then
13279   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
13280 cat >conftest.$ac_ext <<_ACEOF
13281 /* confdefs.h.  */
13282 _ACEOF
13283 cat confdefs.h >>conftest.$ac_ext
13284 cat >>conftest.$ac_ext <<_ACEOF
13285 /* end confdefs.h.  */
13286 #include <stdlib.h>
13287
13288 _ACEOF
13289 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13290   $EGREP "free" >/dev/null 2>&1; then
13291   :
13292 else
13293   ol_cv_header_stdc=no
13294 fi
13295 rm -f conftest*
13296
13297 fi
13298
13299 if test $ol_cv_header_stdc = yes; then
13300   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
13301 if test "$cross_compiling" = yes; then
13302   :
13303 else
13304   cat >conftest.$ac_ext <<_ACEOF
13305 /* confdefs.h.  */
13306 _ACEOF
13307 cat confdefs.h >>conftest.$ac_ext
13308 cat >>conftest.$ac_ext <<_ACEOF
13309 /* end confdefs.h.  */
13310 #include <ctype.h>
13311 #ifndef HAVE_EBCDIC
13312 #       define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
13313 #       define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
13314 #else
13315 #       define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
13316                 || ('j' <= (c) && (c) <= 'r') \
13317                 || ('s' <= (c) && (c) <= 'z'))
13318 #       define TOUPPER(c)       (ISLOWER(c) ? ((c) | 0x40) : (c))
13319 #endif
13320 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
13321 int main () { int i; for (i = 0; i < 256; i++)
13322 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
13323 exit (0); }
13324
13325 _ACEOF
13326 rm -f conftest$ac_exeext
13327 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13328   (eval $ac_link) 2>&5
13329   ac_status=$?
13330   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13331   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13332   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13333   (eval $ac_try) 2>&5
13334   ac_status=$?
13335   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13336   (exit $ac_status); }; }; then
13337   :
13338 else
13339   echo "$as_me: program exited with status $ac_status" >&5
13340 echo "$as_me: failed program was:" >&5
13341 sed 's/^/| /' conftest.$ac_ext >&5
13342
13343 ( exit $ac_status )
13344 ol_cv_header_stdc=no
13345 fi
13346 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13347 fi
13348 fi
13349 fi
13350 echo "$as_me:$LINENO: result: $ol_cv_header_stdc" >&5
13351 echo "${ECHO_T}$ol_cv_header_stdc" >&6
13352 if test $ol_cv_header_stdc = yes; then
13353   cat >>confdefs.h <<\_ACEOF
13354 #define STDC_HEADERS 1
13355 _ACEOF
13356
13357 fi
13358 ac_cv_header_stdc=disable
13359
13360
13361 if test $ol_cv_header_stdc != yes; then
13362         { echo "$as_me:$LINENO: WARNING: could not locate Standard C compliant headers" >&5
13363 echo "$as_me: WARNING: could not locate Standard C compliant headers" >&2;}
13364 fi
13365
13366
13367
13368
13369
13370
13371 ac_header_dirent=no
13372 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
13373   as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
13374 echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
13375 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
13376 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13377   echo $ECHO_N "(cached) $ECHO_C" >&6
13378 else
13379   cat >conftest.$ac_ext <<_ACEOF
13380 /* confdefs.h.  */
13381 _ACEOF
13382 cat confdefs.h >>conftest.$ac_ext
13383 cat >>conftest.$ac_ext <<_ACEOF
13384 /* end confdefs.h.  */
13385 #include <sys/types.h>
13386 #include <$ac_hdr>
13387
13388 int
13389 main ()
13390 {
13391 if ((DIR *) 0)
13392 return 0;
13393   ;
13394   return 0;
13395 }
13396 _ACEOF
13397 rm -f conftest.$ac_objext
13398 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13399   (eval $ac_compile) 2>conftest.er1
13400   ac_status=$?
13401   grep -v '^ *+' conftest.er1 >conftest.err
13402   rm -f conftest.er1
13403   cat conftest.err >&5
13404   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13405   (exit $ac_status); } &&
13406          { ac_try='test -z "$ac_c_werror_flag"
13407                          || test ! -s conftest.err'
13408   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13409   (eval $ac_try) 2>&5
13410   ac_status=$?
13411   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13412   (exit $ac_status); }; } &&
13413          { ac_try='test -s conftest.$ac_objext'
13414   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13415   (eval $ac_try) 2>&5
13416   ac_status=$?
13417   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13418   (exit $ac_status); }; }; then
13419   eval "$as_ac_Header=yes"
13420 else
13421   echo "$as_me: failed program was:" >&5
13422 sed 's/^/| /' conftest.$ac_ext >&5
13423
13424 eval "$as_ac_Header=no"
13425 fi
13426 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13427 fi
13428 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13429 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13430 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13431   cat >>confdefs.h <<_ACEOF
13432 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
13433 _ACEOF
13434
13435 ac_header_dirent=$ac_hdr; break
13436 fi
13437
13438 done
13439 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
13440 if test $ac_header_dirent = dirent.h; then
13441   echo "$as_me:$LINENO: checking for library containing opendir" >&5
13442 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
13443 if test "${ac_cv_search_opendir+set}" = set; then
13444   echo $ECHO_N "(cached) $ECHO_C" >&6
13445 else
13446   ac_func_search_save_LIBS=$LIBS
13447 ac_cv_search_opendir=no
13448 cat >conftest.$ac_ext <<_ACEOF
13449 /* confdefs.h.  */
13450 _ACEOF
13451 cat confdefs.h >>conftest.$ac_ext
13452 cat >>conftest.$ac_ext <<_ACEOF
13453 /* end confdefs.h.  */
13454
13455 /* Override any gcc2 internal prototype to avoid an error.  */
13456 #ifdef __cplusplus
13457 extern "C"
13458 #endif
13459 /* We use char because int might match the return type of a gcc2
13460    builtin and then its argument prototype would still apply.  */
13461 char opendir ();
13462 int
13463 main ()
13464 {
13465 opendir ();
13466   ;
13467   return 0;
13468 }
13469 _ACEOF
13470 rm -f conftest.$ac_objext conftest$ac_exeext
13471 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13472   (eval $ac_link) 2>conftest.er1
13473   ac_status=$?
13474   grep -v '^ *+' conftest.er1 >conftest.err
13475   rm -f conftest.er1
13476   cat conftest.err >&5
13477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13478   (exit $ac_status); } &&
13479          { ac_try='test -z "$ac_c_werror_flag"
13480                          || test ! -s conftest.err'
13481   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13482   (eval $ac_try) 2>&5
13483   ac_status=$?
13484   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13485   (exit $ac_status); }; } &&
13486          { ac_try='test -s conftest$ac_exeext'
13487   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13488   (eval $ac_try) 2>&5
13489   ac_status=$?
13490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13491   (exit $ac_status); }; }; then
13492   ac_cv_search_opendir="none required"
13493 else
13494   echo "$as_me: failed program was:" >&5
13495 sed 's/^/| /' conftest.$ac_ext >&5
13496
13497 fi
13498 rm -f conftest.err conftest.$ac_objext \
13499       conftest$ac_exeext conftest.$ac_ext
13500 if test "$ac_cv_search_opendir" = no; then
13501   for ac_lib in dir; do
13502     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
13503     cat >conftest.$ac_ext <<_ACEOF
13504 /* confdefs.h.  */
13505 _ACEOF
13506 cat confdefs.h >>conftest.$ac_ext
13507 cat >>conftest.$ac_ext <<_ACEOF
13508 /* end confdefs.h.  */
13509
13510 /* Override any gcc2 internal prototype to avoid an error.  */
13511 #ifdef __cplusplus
13512 extern "C"
13513 #endif
13514 /* We use char because int might match the return type of a gcc2
13515    builtin and then its argument prototype would still apply.  */
13516 char opendir ();
13517 int
13518 main ()
13519 {
13520 opendir ();
13521   ;
13522   return 0;
13523 }
13524 _ACEOF
13525 rm -f conftest.$ac_objext conftest$ac_exeext
13526 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13527   (eval $ac_link) 2>conftest.er1
13528   ac_status=$?
13529   grep -v '^ *+' conftest.er1 >conftest.err
13530   rm -f conftest.er1
13531   cat conftest.err >&5
13532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13533   (exit $ac_status); } &&
13534          { ac_try='test -z "$ac_c_werror_flag"
13535                          || test ! -s conftest.err'
13536   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13537   (eval $ac_try) 2>&5
13538   ac_status=$?
13539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13540   (exit $ac_status); }; } &&
13541          { ac_try='test -s conftest$ac_exeext'
13542   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13543   (eval $ac_try) 2>&5
13544   ac_status=$?
13545   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13546   (exit $ac_status); }; }; then
13547   ac_cv_search_opendir="-l$ac_lib"
13548 break
13549 else
13550   echo "$as_me: failed program was:" >&5
13551 sed 's/^/| /' conftest.$ac_ext >&5
13552
13553 fi
13554 rm -f conftest.err conftest.$ac_objext \
13555       conftest$ac_exeext conftest.$ac_ext
13556   done
13557 fi
13558 LIBS=$ac_func_search_save_LIBS
13559 fi
13560 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
13561 echo "${ECHO_T}$ac_cv_search_opendir" >&6
13562 if test "$ac_cv_search_opendir" != no; then
13563   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
13564
13565 fi
13566
13567 else
13568   echo "$as_me:$LINENO: checking for library containing opendir" >&5
13569 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
13570 if test "${ac_cv_search_opendir+set}" = set; then
13571   echo $ECHO_N "(cached) $ECHO_C" >&6
13572 else
13573   ac_func_search_save_LIBS=$LIBS
13574 ac_cv_search_opendir=no
13575 cat >conftest.$ac_ext <<_ACEOF
13576 /* confdefs.h.  */
13577 _ACEOF
13578 cat confdefs.h >>conftest.$ac_ext
13579 cat >>conftest.$ac_ext <<_ACEOF
13580 /* end confdefs.h.  */
13581
13582 /* Override any gcc2 internal prototype to avoid an error.  */
13583 #ifdef __cplusplus
13584 extern "C"
13585 #endif
13586 /* We use char because int might match the return type of a gcc2
13587    builtin and then its argument prototype would still apply.  */
13588 char opendir ();
13589 int
13590 main ()
13591 {
13592 opendir ();
13593   ;
13594   return 0;
13595 }
13596 _ACEOF
13597 rm -f conftest.$ac_objext conftest$ac_exeext
13598 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13599   (eval $ac_link) 2>conftest.er1
13600   ac_status=$?
13601   grep -v '^ *+' conftest.er1 >conftest.err
13602   rm -f conftest.er1
13603   cat conftest.err >&5
13604   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13605   (exit $ac_status); } &&
13606          { ac_try='test -z "$ac_c_werror_flag"
13607                          || test ! -s conftest.err'
13608   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13609   (eval $ac_try) 2>&5
13610   ac_status=$?
13611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13612   (exit $ac_status); }; } &&
13613          { ac_try='test -s conftest$ac_exeext'
13614   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13615   (eval $ac_try) 2>&5
13616   ac_status=$?
13617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13618   (exit $ac_status); }; }; then
13619   ac_cv_search_opendir="none required"
13620 else
13621   echo "$as_me: failed program was:" >&5
13622 sed 's/^/| /' conftest.$ac_ext >&5
13623
13624 fi
13625 rm -f conftest.err conftest.$ac_objext \
13626       conftest$ac_exeext conftest.$ac_ext
13627 if test "$ac_cv_search_opendir" = no; then
13628   for ac_lib in x; do
13629     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
13630     cat >conftest.$ac_ext <<_ACEOF
13631 /* confdefs.h.  */
13632 _ACEOF
13633 cat confdefs.h >>conftest.$ac_ext
13634 cat >>conftest.$ac_ext <<_ACEOF
13635 /* end confdefs.h.  */
13636
13637 /* Override any gcc2 internal prototype to avoid an error.  */
13638 #ifdef __cplusplus
13639 extern "C"
13640 #endif
13641 /* We use char because int might match the return type of a gcc2
13642    builtin and then its argument prototype would still apply.  */
13643 char opendir ();
13644 int
13645 main ()
13646 {
13647 opendir ();
13648   ;
13649   return 0;
13650 }
13651 _ACEOF
13652 rm -f conftest.$ac_objext conftest$ac_exeext
13653 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13654   (eval $ac_link) 2>conftest.er1
13655   ac_status=$?
13656   grep -v '^ *+' conftest.er1 >conftest.err
13657   rm -f conftest.er1
13658   cat conftest.err >&5
13659   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13660   (exit $ac_status); } &&
13661          { ac_try='test -z "$ac_c_werror_flag"
13662                          || test ! -s conftest.err'
13663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13664   (eval $ac_try) 2>&5
13665   ac_status=$?
13666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13667   (exit $ac_status); }; } &&
13668          { ac_try='test -s conftest$ac_exeext'
13669   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13670   (eval $ac_try) 2>&5
13671   ac_status=$?
13672   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13673   (exit $ac_status); }; }; then
13674   ac_cv_search_opendir="-l$ac_lib"
13675 break
13676 else
13677   echo "$as_me: failed program was:" >&5
13678 sed 's/^/| /' conftest.$ac_ext >&5
13679
13680 fi
13681 rm -f conftest.err conftest.$ac_objext \
13682       conftest$ac_exeext conftest.$ac_ext
13683   done
13684 fi
13685 LIBS=$ac_func_search_save_LIBS
13686 fi
13687 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
13688 echo "${ECHO_T}$ac_cv_search_opendir" >&6
13689 if test "$ac_cv_search_opendir" != no; then
13690   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
13691
13692 fi
13693
13694 fi
13695
13696 echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
13697 echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
13698 if test "${ac_cv_header_sys_wait_h+set}" = set; then
13699   echo $ECHO_N "(cached) $ECHO_C" >&6
13700 else
13701   cat >conftest.$ac_ext <<_ACEOF
13702 /* confdefs.h.  */
13703 _ACEOF
13704 cat confdefs.h >>conftest.$ac_ext
13705 cat >>conftest.$ac_ext <<_ACEOF
13706 /* end confdefs.h.  */
13707 #include <sys/types.h>
13708 #include <sys/wait.h>
13709 #ifndef WEXITSTATUS
13710 # define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
13711 #endif
13712 #ifndef WIFEXITED
13713 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
13714 #endif
13715
13716 int
13717 main ()
13718 {
13719   int s;
13720   wait (&s);
13721   s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
13722   ;
13723   return 0;
13724 }
13725 _ACEOF
13726 rm -f conftest.$ac_objext
13727 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13728   (eval $ac_compile) 2>conftest.er1
13729   ac_status=$?
13730   grep -v '^ *+' conftest.er1 >conftest.err
13731   rm -f conftest.er1
13732   cat conftest.err >&5
13733   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13734   (exit $ac_status); } &&
13735          { ac_try='test -z "$ac_c_werror_flag"
13736                          || test ! -s conftest.err'
13737   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13738   (eval $ac_try) 2>&5
13739   ac_status=$?
13740   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13741   (exit $ac_status); }; } &&
13742          { ac_try='test -s conftest.$ac_objext'
13743   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13744   (eval $ac_try) 2>&5
13745   ac_status=$?
13746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13747   (exit $ac_status); }; }; then
13748   ac_cv_header_sys_wait_h=yes
13749 else
13750   echo "$as_me: failed program was:" >&5
13751 sed 's/^/| /' conftest.$ac_ext >&5
13752
13753 ac_cv_header_sys_wait_h=no
13754 fi
13755 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13756 fi
13757 echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
13758 echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
13759 if test $ac_cv_header_sys_wait_h = yes; then
13760
13761 cat >>confdefs.h <<\_ACEOF
13762 #define HAVE_SYS_WAIT_H 1
13763 _ACEOF
13764
13765 fi
13766
13767 echo "$as_me:$LINENO: checking whether termios.h defines TIOCGWINSZ" >&5
13768 echo $ECHO_N "checking whether termios.h defines TIOCGWINSZ... $ECHO_C" >&6
13769 if test "${ac_cv_sys_tiocgwinsz_in_termios_h+set}" = set; then
13770   echo $ECHO_N "(cached) $ECHO_C" >&6
13771 else
13772   cat >conftest.$ac_ext <<_ACEOF
13773 /* confdefs.h.  */
13774 _ACEOF
13775 cat confdefs.h >>conftest.$ac_ext
13776 cat >>conftest.$ac_ext <<_ACEOF
13777 /* end confdefs.h.  */
13778 #include <sys/types.h>
13779 #include <termios.h>
13780 #ifdef TIOCGWINSZ
13781   yes
13782 #endif
13783
13784 _ACEOF
13785 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13786   $EGREP "yes" >/dev/null 2>&1; then
13787   ac_cv_sys_tiocgwinsz_in_termios_h=yes
13788 else
13789   ac_cv_sys_tiocgwinsz_in_termios_h=no
13790 fi
13791 rm -f conftest*
13792
13793 fi
13794 echo "$as_me:$LINENO: result: $ac_cv_sys_tiocgwinsz_in_termios_h" >&5
13795 echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_termios_h" >&6
13796
13797 if test $ac_cv_sys_tiocgwinsz_in_termios_h != yes; then
13798   echo "$as_me:$LINENO: checking whether sys/ioctl.h defines TIOCGWINSZ" >&5
13799 echo $ECHO_N "checking whether sys/ioctl.h defines TIOCGWINSZ... $ECHO_C" >&6
13800 if test "${ac_cv_sys_tiocgwinsz_in_sys_ioctl_h+set}" = set; then
13801   echo $ECHO_N "(cached) $ECHO_C" >&6
13802 else
13803   cat >conftest.$ac_ext <<_ACEOF
13804 /* confdefs.h.  */
13805 _ACEOF
13806 cat confdefs.h >>conftest.$ac_ext
13807 cat >>conftest.$ac_ext <<_ACEOF
13808 /* end confdefs.h.  */
13809 #include <sys/types.h>
13810 #include <sys/ioctl.h>
13811 #ifdef TIOCGWINSZ
13812   yes
13813 #endif
13814
13815 _ACEOF
13816 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13817   $EGREP "yes" >/dev/null 2>&1; then
13818   ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=yes
13819 else
13820   ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=no
13821 fi
13822 rm -f conftest*
13823
13824 fi
13825 echo "$as_me:$LINENO: result: $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&5
13826 echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&6
13827
13828   if test $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h = yes; then
13829
13830 cat >>confdefs.h <<\_ACEOF
13831 #define GWINSZ_IN_SYS_IOCTL 1
13832 _ACEOF
13833
13834   fi
13835 fi
13836
13837
13838
13839
13840
13841
13842
13843
13844
13845
13846
13847
13848
13849
13850
13851
13852
13853
13854
13855
13856
13857
13858
13859
13860
13861
13862
13863
13864
13865
13866
13867
13868
13869
13870
13871
13872
13873
13874
13875
13876
13877
13878
13879
13880
13881
13882
13883
13884
13885 for ac_header in \
13886         arpa/inet.h             \
13887         arpa/nameser.h  \
13888         assert.h                \
13889         bits/types.h    \
13890         conio.h                 \
13891         crypt.h                 \
13892         direct.h                \
13893         errno.h                 \
13894         fcntl.h                 \
13895         filio.h                 \
13896         getopt.h                \
13897         grp.h                   \
13898         io.h                    \
13899         libutil.h               \
13900         limits.h                \
13901         locale.h                \
13902         malloc.h                \
13903         memory.h                \
13904         psap.h                  \
13905         pwd.h                   \
13906         process.h               \
13907         sgtty.h                 \
13908         shadow.h                \
13909         stddef.h                \
13910         string.h                \
13911         strings.h               \
13912         sysexits.h              \
13913         sys/file.h              \
13914         sys/filio.h             \
13915         sys/fstyp.h             \
13916         sys/errno.h             \
13917         sys/ioctl.h             \
13918         sys/param.h             \
13919         sys/privgrp.h   \
13920         sys/resource.h  \
13921         sys/select.h    \
13922         sys/socket.h    \
13923         sys/stat.h              \
13924         sys/syslog.h    \
13925         sys/time.h              \
13926         sys/types.h             \
13927         sys/uio.h               \
13928         sys/vmount.h    \
13929         syslog.h                \
13930         termios.h               \
13931         unistd.h                \
13932         utime.h                 \
13933
13934 do
13935 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13936 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13937   echo "$as_me:$LINENO: checking for $ac_header" >&5
13938 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13939 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13940   echo $ECHO_N "(cached) $ECHO_C" >&6
13941 fi
13942 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13943 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13944 else
13945   # Is the header compilable?
13946 echo "$as_me:$LINENO: checking $ac_header usability" >&5
13947 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13948 cat >conftest.$ac_ext <<_ACEOF
13949 /* confdefs.h.  */
13950 _ACEOF
13951 cat confdefs.h >>conftest.$ac_ext
13952 cat >>conftest.$ac_ext <<_ACEOF
13953 /* end confdefs.h.  */
13954 $ac_includes_default
13955 #include <$ac_header>
13956 _ACEOF
13957 rm -f conftest.$ac_objext
13958 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13959   (eval $ac_compile) 2>conftest.er1
13960   ac_status=$?
13961   grep -v '^ *+' conftest.er1 >conftest.err
13962   rm -f conftest.er1
13963   cat conftest.err >&5
13964   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13965   (exit $ac_status); } &&
13966          { ac_try='test -z "$ac_c_werror_flag"
13967                          || test ! -s conftest.err'
13968   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13969   (eval $ac_try) 2>&5
13970   ac_status=$?
13971   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13972   (exit $ac_status); }; } &&
13973          { ac_try='test -s conftest.$ac_objext'
13974   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13975   (eval $ac_try) 2>&5
13976   ac_status=$?
13977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13978   (exit $ac_status); }; }; then
13979   ac_header_compiler=yes
13980 else
13981   echo "$as_me: failed program was:" >&5
13982 sed 's/^/| /' conftest.$ac_ext >&5
13983
13984 ac_header_compiler=no
13985 fi
13986 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13987 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13988 echo "${ECHO_T}$ac_header_compiler" >&6
13989
13990 # Is the header present?
13991 echo "$as_me:$LINENO: checking $ac_header presence" >&5
13992 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13993 cat >conftest.$ac_ext <<_ACEOF
13994 /* confdefs.h.  */
13995 _ACEOF
13996 cat confdefs.h >>conftest.$ac_ext
13997 cat >>conftest.$ac_ext <<_ACEOF
13998 /* end confdefs.h.  */
13999 #include <$ac_header>
14000 _ACEOF
14001 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
14002   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14003   ac_status=$?
14004   grep -v '^ *+' conftest.er1 >conftest.err
14005   rm -f conftest.er1
14006   cat conftest.err >&5
14007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14008   (exit $ac_status); } >/dev/null; then
14009   if test -s conftest.err; then
14010     ac_cpp_err=$ac_c_preproc_warn_flag
14011     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
14012   else
14013     ac_cpp_err=
14014   fi
14015 else
14016   ac_cpp_err=yes
14017 fi
14018 if test -z "$ac_cpp_err"; then
14019   ac_header_preproc=yes
14020 else
14021   echo "$as_me: failed program was:" >&5
14022 sed 's/^/| /' conftest.$ac_ext >&5
14023
14024   ac_header_preproc=no
14025 fi
14026 rm -f conftest.err conftest.$ac_ext
14027 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14028 echo "${ECHO_T}$ac_header_preproc" >&6
14029
14030 # So?  What about this header?
14031 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14032   yes:no: )
14033     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14034 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14035     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14036 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14037     ac_header_preproc=yes
14038     ;;
14039   no:yes:* )
14040     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14041 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14042     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14043 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14044     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14045 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14046     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14047 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14048     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14049 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14050     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14051 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14052     (
14053       cat <<\_ASBOX
14054 ## --------------------------------------------- ##
14055 ## Report this to <http://www.openldap.org/its/> ##
14056 ## --------------------------------------------- ##
14057 _ASBOX
14058     ) |
14059       sed "s/^/$as_me: WARNING:     /" >&2
14060     ;;
14061 esac
14062 echo "$as_me:$LINENO: checking for $ac_header" >&5
14063 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14064 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14065   echo $ECHO_N "(cached) $ECHO_C" >&6
14066 else
14067   eval "$as_ac_Header=\$ac_header_preproc"
14068 fi
14069 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14070 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14071
14072 fi
14073 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14074   cat >>confdefs.h <<_ACEOF
14075 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14076 _ACEOF
14077
14078 fi
14079
14080 done
14081
14082
14083 if test "$ac_cv_mingw32" = yes ; then
14084
14085
14086 for ac_header in winsock.h winsock2.h
14087 do
14088 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14089 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14090   echo "$as_me:$LINENO: checking for $ac_header" >&5
14091 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14092 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14093   echo $ECHO_N "(cached) $ECHO_C" >&6
14094 fi
14095 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14096 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14097 else
14098   # Is the header compilable?
14099 echo "$as_me:$LINENO: checking $ac_header usability" >&5
14100 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
14101 cat >conftest.$ac_ext <<_ACEOF
14102 /* confdefs.h.  */
14103 _ACEOF
14104 cat confdefs.h >>conftest.$ac_ext
14105 cat >>conftest.$ac_ext <<_ACEOF
14106 /* end confdefs.h.  */
14107 $ac_includes_default
14108 #include <$ac_header>
14109 _ACEOF
14110 rm -f conftest.$ac_objext
14111 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14112   (eval $ac_compile) 2>conftest.er1
14113   ac_status=$?
14114   grep -v '^ *+' conftest.er1 >conftest.err
14115   rm -f conftest.er1
14116   cat conftest.err >&5
14117   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14118   (exit $ac_status); } &&
14119          { ac_try='test -z "$ac_c_werror_flag"
14120                          || test ! -s conftest.err'
14121   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14122   (eval $ac_try) 2>&5
14123   ac_status=$?
14124   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14125   (exit $ac_status); }; } &&
14126          { ac_try='test -s conftest.$ac_objext'
14127   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14128   (eval $ac_try) 2>&5
14129   ac_status=$?
14130   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14131   (exit $ac_status); }; }; then
14132   ac_header_compiler=yes
14133 else
14134   echo "$as_me: failed program was:" >&5
14135 sed 's/^/| /' conftest.$ac_ext >&5
14136
14137 ac_header_compiler=no
14138 fi
14139 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14140 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14141 echo "${ECHO_T}$ac_header_compiler" >&6
14142
14143 # Is the header present?
14144 echo "$as_me:$LINENO: checking $ac_header presence" >&5
14145 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
14146 cat >conftest.$ac_ext <<_ACEOF
14147 /* confdefs.h.  */
14148 _ACEOF
14149 cat confdefs.h >>conftest.$ac_ext
14150 cat >>conftest.$ac_ext <<_ACEOF
14151 /* end confdefs.h.  */
14152 #include <$ac_header>
14153 _ACEOF
14154 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
14155   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14156   ac_status=$?
14157   grep -v '^ *+' conftest.er1 >conftest.err
14158   rm -f conftest.er1
14159   cat conftest.err >&5
14160   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14161   (exit $ac_status); } >/dev/null; then
14162   if test -s conftest.err; then
14163     ac_cpp_err=$ac_c_preproc_warn_flag
14164     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
14165   else
14166     ac_cpp_err=
14167   fi
14168 else
14169   ac_cpp_err=yes
14170 fi
14171 if test -z "$ac_cpp_err"; then
14172   ac_header_preproc=yes
14173 else
14174   echo "$as_me: failed program was:" >&5
14175 sed 's/^/| /' conftest.$ac_ext >&5
14176
14177   ac_header_preproc=no
14178 fi
14179 rm -f conftest.err conftest.$ac_ext
14180 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14181 echo "${ECHO_T}$ac_header_preproc" >&6
14182
14183 # So?  What about this header?
14184 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14185   yes:no: )
14186     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14187 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14188     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14189 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14190     ac_header_preproc=yes
14191     ;;
14192   no:yes:* )
14193     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14194 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14195     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14196 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14197     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14198 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14199     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14200 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14201     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14202 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14203     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14204 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14205     (
14206       cat <<\_ASBOX
14207 ## --------------------------------------------- ##
14208 ## Report this to <http://www.openldap.org/its/> ##
14209 ## --------------------------------------------- ##
14210 _ASBOX
14211     ) |
14212       sed "s/^/$as_me: WARNING:     /" >&2
14213     ;;
14214 esac
14215 echo "$as_me:$LINENO: checking for $ac_header" >&5
14216 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14217 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14218   echo $ECHO_N "(cached) $ECHO_C" >&6
14219 else
14220   eval "$as_ac_Header=\$ac_header_preproc"
14221 fi
14222 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14223 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14224
14225 fi
14226 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14227   cat >>confdefs.h <<_ACEOF
14228 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14229 _ACEOF
14230
14231 fi
14232
14233 done
14234
14235 fi
14236
14237
14238 for ac_header in resolv.h
14239 do
14240 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14241 echo "$as_me:$LINENO: checking for $ac_header" >&5
14242 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14243 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14244   echo $ECHO_N "(cached) $ECHO_C" >&6
14245 else
14246   cat >conftest.$ac_ext <<_ACEOF
14247 /* confdefs.h.  */
14248 _ACEOF
14249 cat confdefs.h >>conftest.$ac_ext
14250 cat >>conftest.$ac_ext <<_ACEOF
14251 /* end confdefs.h.  */
14252 $ac_includes_default
14253 #include <netinet/in.h>
14254
14255
14256 #include <$ac_header>
14257 _ACEOF
14258 rm -f conftest.$ac_objext
14259 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14260   (eval $ac_compile) 2>conftest.er1
14261   ac_status=$?
14262   grep -v '^ *+' conftest.er1 >conftest.err
14263   rm -f conftest.er1
14264   cat conftest.err >&5
14265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14266   (exit $ac_status); } &&
14267          { ac_try='test -z "$ac_c_werror_flag"
14268                          || test ! -s conftest.err'
14269   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14270   (eval $ac_try) 2>&5
14271   ac_status=$?
14272   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14273   (exit $ac_status); }; } &&
14274          { ac_try='test -s conftest.$ac_objext'
14275   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14276   (eval $ac_try) 2>&5
14277   ac_status=$?
14278   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14279   (exit $ac_status); }; }; then
14280   eval "$as_ac_Header=yes"
14281 else
14282   echo "$as_me: failed program was:" >&5
14283 sed 's/^/| /' conftest.$ac_ext >&5
14284
14285 eval "$as_ac_Header=no"
14286 fi
14287 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14288 fi
14289 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14290 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14291 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14292   cat >>confdefs.h <<_ACEOF
14293 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14294 _ACEOF
14295
14296 fi
14297
14298 done
14299
14300
14301
14302 for ac_header in netinet/tcp.h
14303 do
14304 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14305 echo "$as_me:$LINENO: checking for $ac_header" >&5
14306 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14307 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14308   echo $ECHO_N "(cached) $ECHO_C" >&6
14309 else
14310   cat >conftest.$ac_ext <<_ACEOF
14311 /* confdefs.h.  */
14312 _ACEOF
14313 cat confdefs.h >>conftest.$ac_ext
14314 cat >>conftest.$ac_ext <<_ACEOF
14315 /* end confdefs.h.  */
14316 $ac_includes_default
14317 #include <netinet/in.h>
14318
14319
14320 #include <$ac_header>
14321 _ACEOF
14322 rm -f conftest.$ac_objext
14323 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14324   (eval $ac_compile) 2>conftest.er1
14325   ac_status=$?
14326   grep -v '^ *+' conftest.er1 >conftest.err
14327   rm -f conftest.er1
14328   cat conftest.err >&5
14329   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14330   (exit $ac_status); } &&
14331          { ac_try='test -z "$ac_c_werror_flag"
14332                          || test ! -s conftest.err'
14333   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14334   (eval $ac_try) 2>&5
14335   ac_status=$?
14336   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14337   (exit $ac_status); }; } &&
14338          { ac_try='test -s conftest.$ac_objext'
14339   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14340   (eval $ac_try) 2>&5
14341   ac_status=$?
14342   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14343   (exit $ac_status); }; }; then
14344   eval "$as_ac_Header=yes"
14345 else
14346   echo "$as_me: failed program was:" >&5
14347 sed 's/^/| /' conftest.$ac_ext >&5
14348
14349 eval "$as_ac_Header=no"
14350 fi
14351 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14352 fi
14353 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14354 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14355 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14356   cat >>confdefs.h <<_ACEOF
14357 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14358 _ACEOF
14359
14360 fi
14361
14362 done
14363
14364
14365
14366 for ac_header in sys/ucred.h
14367 do
14368 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14369 echo "$as_me:$LINENO: checking for $ac_header" >&5
14370 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14371 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14372   echo $ECHO_N "(cached) $ECHO_C" >&6
14373 else
14374   cat >conftest.$ac_ext <<_ACEOF
14375 /* confdefs.h.  */
14376 _ACEOF
14377 cat confdefs.h >>conftest.$ac_ext
14378 cat >>conftest.$ac_ext <<_ACEOF
14379 /* end confdefs.h.  */
14380 $ac_includes_default
14381 #ifdef HAVE_SYS_PARAM_H
14382 #include <sys/param.h>
14383 #endif
14384
14385
14386 #include <$ac_header>
14387 _ACEOF
14388 rm -f conftest.$ac_objext
14389 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14390   (eval $ac_compile) 2>conftest.er1
14391   ac_status=$?
14392   grep -v '^ *+' conftest.er1 >conftest.err
14393   rm -f conftest.er1
14394   cat conftest.err >&5
14395   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14396   (exit $ac_status); } &&
14397          { ac_try='test -z "$ac_c_werror_flag"
14398                          || test ! -s conftest.err'
14399   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14400   (eval $ac_try) 2>&5
14401   ac_status=$?
14402   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14403   (exit $ac_status); }; } &&
14404          { ac_try='test -s conftest.$ac_objext'
14405   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14406   (eval $ac_try) 2>&5
14407   ac_status=$?
14408   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14409   (exit $ac_status); }; }; then
14410   eval "$as_ac_Header=yes"
14411 else
14412   echo "$as_me: failed program was:" >&5
14413 sed 's/^/| /' conftest.$ac_ext >&5
14414
14415 eval "$as_ac_Header=no"
14416 fi
14417 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14418 fi
14419 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14420 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14421 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14422   cat >>confdefs.h <<_ACEOF
14423 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14424 _ACEOF
14425
14426 fi
14427
14428 done
14429
14430
14431
14432
14433
14434 for ac_func in sigaction sigset
14435 do
14436 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14437 echo "$as_me:$LINENO: checking for $ac_func" >&5
14438 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14439 if eval "test \"\${$as_ac_var+set}\" = set"; then
14440   echo $ECHO_N "(cached) $ECHO_C" >&6
14441 else
14442   cat >conftest.$ac_ext <<_ACEOF
14443 /* confdefs.h.  */
14444 _ACEOF
14445 cat confdefs.h >>conftest.$ac_ext
14446 cat >>conftest.$ac_ext <<_ACEOF
14447 /* end confdefs.h.  */
14448 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14449    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14450 #define $ac_func innocuous_$ac_func
14451
14452 /* System header to define __stub macros and hopefully few prototypes,
14453     which can conflict with char $ac_func (); below.
14454     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14455     <limits.h> exists even on freestanding compilers.  */
14456
14457 #ifdef __STDC__
14458 # include <limits.h>
14459 #else
14460 # include <assert.h>
14461 #endif
14462
14463 #undef $ac_func
14464
14465 /* Override any gcc2 internal prototype to avoid an error.  */
14466 #ifdef __cplusplus
14467 extern "C"
14468 {
14469 #endif
14470 /* We use char because int might match the return type of a gcc2
14471    builtin and then its argument prototype would still apply.  */
14472 char $ac_func ();
14473 /* The GNU C library defines this for functions which it implements
14474     to always fail with ENOSYS.  Some functions are actually named
14475     something starting with __ and the normal name is an alias.  */
14476 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14477 choke me
14478 #else
14479 char (*f) () = $ac_func;
14480 #endif
14481 #ifdef __cplusplus
14482 }
14483 #endif
14484
14485 int
14486 main ()
14487 {
14488 return f != $ac_func;
14489   ;
14490   return 0;
14491 }
14492 _ACEOF
14493 rm -f conftest.$ac_objext conftest$ac_exeext
14494 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14495   (eval $ac_link) 2>conftest.er1
14496   ac_status=$?
14497   grep -v '^ *+' conftest.er1 >conftest.err
14498   rm -f conftest.er1
14499   cat conftest.err >&5
14500   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14501   (exit $ac_status); } &&
14502          { ac_try='test -z "$ac_c_werror_flag"
14503                          || test ! -s conftest.err'
14504   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14505   (eval $ac_try) 2>&5
14506   ac_status=$?
14507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14508   (exit $ac_status); }; } &&
14509          { ac_try='test -s conftest$ac_exeext'
14510   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14511   (eval $ac_try) 2>&5
14512   ac_status=$?
14513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14514   (exit $ac_status); }; }; then
14515   eval "$as_ac_var=yes"
14516 else
14517   echo "$as_me: failed program was:" >&5
14518 sed 's/^/| /' conftest.$ac_ext >&5
14519
14520 eval "$as_ac_var=no"
14521 fi
14522 rm -f conftest.err conftest.$ac_objext \
14523       conftest$ac_exeext conftest.$ac_ext
14524 fi
14525 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14526 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14527 if test `eval echo '${'$as_ac_var'}'` = yes; then
14528   cat >>confdefs.h <<_ACEOF
14529 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14530 _ACEOF
14531
14532 fi
14533 done
14534
14535
14536 if test $ac_cv_func_sigaction = no && test $ac_cv_func_sigaction = no ; then
14537
14538 echo "$as_me:$LINENO: checking for sigset in -lV3" >&5
14539 echo $ECHO_N "checking for sigset in -lV3... $ECHO_C" >&6
14540 if test "${ac_cv_lib_V3_sigset+set}" = set; then
14541   echo $ECHO_N "(cached) $ECHO_C" >&6
14542 else
14543   ac_check_lib_save_LIBS=$LIBS
14544 LIBS="-lV3  $LIBS"
14545 cat >conftest.$ac_ext <<_ACEOF
14546 /* confdefs.h.  */
14547 _ACEOF
14548 cat confdefs.h >>conftest.$ac_ext
14549 cat >>conftest.$ac_ext <<_ACEOF
14550 /* end confdefs.h.  */
14551
14552 /* Override any gcc2 internal prototype to avoid an error.  */
14553 #ifdef __cplusplus
14554 extern "C"
14555 #endif
14556 /* We use char because int might match the return type of a gcc2
14557    builtin and then its argument prototype would still apply.  */
14558 char sigset ();
14559 int
14560 main ()
14561 {
14562 sigset ();
14563   ;
14564   return 0;
14565 }
14566 _ACEOF
14567 rm -f conftest.$ac_objext conftest$ac_exeext
14568 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14569   (eval $ac_link) 2>conftest.er1
14570   ac_status=$?
14571   grep -v '^ *+' conftest.er1 >conftest.err
14572   rm -f conftest.er1
14573   cat conftest.err >&5
14574   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14575   (exit $ac_status); } &&
14576          { ac_try='test -z "$ac_c_werror_flag"
14577                          || test ! -s conftest.err'
14578   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14579   (eval $ac_try) 2>&5
14580   ac_status=$?
14581   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14582   (exit $ac_status); }; } &&
14583          { ac_try='test -s conftest$ac_exeext'
14584   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14585   (eval $ac_try) 2>&5
14586   ac_status=$?
14587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14588   (exit $ac_status); }; }; then
14589   ac_cv_lib_V3_sigset=yes
14590 else
14591   echo "$as_me: failed program was:" >&5
14592 sed 's/^/| /' conftest.$ac_ext >&5
14593
14594 ac_cv_lib_V3_sigset=no
14595 fi
14596 rm -f conftest.err conftest.$ac_objext \
14597       conftest$ac_exeext conftest.$ac_ext
14598 LIBS=$ac_check_lib_save_LIBS
14599 fi
14600 echo "$as_me:$LINENO: result: $ac_cv_lib_V3_sigset" >&5
14601 echo "${ECHO_T}$ac_cv_lib_V3_sigset" >&6
14602 if test $ac_cv_lib_V3_sigset = yes; then
14603   cat >>confdefs.h <<_ACEOF
14604 #define HAVE_LIBV3 1
14605 _ACEOF
14606
14607   LIBS="-lV3 $LIBS"
14608
14609 fi
14610
14611 fi
14612
14613 if test "$ac_cv_header_winsock_h" = yes; then
14614 echo "$as_me:$LINENO: checking for winsock" >&5
14615 echo $ECHO_N "checking for winsock... $ECHO_C" >&6
14616 if test "${ol_cv_winsock+set}" = set; then
14617   echo $ECHO_N "(cached) $ECHO_C" >&6
14618 else
14619   save_LIBS="$LIBS"
14620 for curlib in ws2_32 wsock32; do
14621         LIBS="$LIBS -l$curlib"
14622         cat >conftest.$ac_ext <<_ACEOF
14623 /* confdefs.h.  */
14624 _ACEOF
14625 cat confdefs.h >>conftest.$ac_ext
14626 cat >>conftest.$ac_ext <<_ACEOF
14627 /* end confdefs.h.  */
14628 #include <winsock.h>
14629
14630 int
14631 main ()
14632 {
14633
14634                         socket(0,0,0);
14635                         select(0,NULL,NULL,NULL,NULL);
14636                         closesocket(0);
14637                         gethostname(NULL,0);
14638
14639   ;
14640   return 0;
14641 }
14642 _ACEOF
14643 rm -f conftest.$ac_objext conftest$ac_exeext
14644 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14645   (eval $ac_link) 2>conftest.er1
14646   ac_status=$?
14647   grep -v '^ *+' conftest.er1 >conftest.err
14648   rm -f conftest.er1
14649   cat conftest.err >&5
14650   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14651   (exit $ac_status); } &&
14652          { ac_try='test -z "$ac_c_werror_flag"
14653                          || test ! -s conftest.err'
14654   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14655   (eval $ac_try) 2>&5
14656   ac_status=$?
14657   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14658   (exit $ac_status); }; } &&
14659          { ac_try='test -s conftest$ac_exeext'
14660   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14661   (eval $ac_try) 2>&5
14662   ac_status=$?
14663   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14664   (exit $ac_status); }; }; then
14665   ol_cv_winsock=yes
14666 else
14667   echo "$as_me: failed program was:" >&5
14668 sed 's/^/| /' conftest.$ac_ext >&5
14669
14670 ol_cv_winsock=no
14671 fi
14672 rm -f conftest.err conftest.$ac_objext \
14673       conftest$ac_exeext conftest.$ac_ext
14674
14675         if test $ol_cv_winsock = yes; then
14676
14677 cat >>confdefs.h <<\_ACEOF
14678 #define HAVE_WINSOCK 1
14679 _ACEOF
14680
14681                 ac_cv_func_socket=yes
14682                 ac_cv_func_select=yes
14683                 ac_cv_func_closesocket=yes
14684                 ac_cv_func_gethostname=yes
14685                 if test $curlib = ws2_32; then
14686                         ol_cv_winsock=winsock2
14687
14688 cat >>confdefs.h <<\_ACEOF
14689 #define HAVE_WINSOCK2 1
14690 _ACEOF
14691
14692                 fi
14693                 break
14694         fi
14695         LIBS="$save_LIBS"
14696 done
14697 fi
14698 echo "$as_me:$LINENO: result: $ol_cv_winsock" >&5
14699 echo "${ECHO_T}$ol_cv_winsock" >&6
14700 fi
14701
14702
14703 echo "$as_me:$LINENO: checking for socket" >&5
14704 echo $ECHO_N "checking for socket... $ECHO_C" >&6
14705 if test "${ac_cv_func_socket+set}" = set; then
14706   echo $ECHO_N "(cached) $ECHO_C" >&6
14707 else
14708   cat >conftest.$ac_ext <<_ACEOF
14709 /* confdefs.h.  */
14710 _ACEOF
14711 cat confdefs.h >>conftest.$ac_ext
14712 cat >>conftest.$ac_ext <<_ACEOF
14713 /* end confdefs.h.  */
14714 /* Define socket to an innocuous variant, in case <limits.h> declares socket.
14715    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14716 #define socket innocuous_socket
14717
14718 /* System header to define __stub macros and hopefully few prototypes,
14719     which can conflict with char socket (); below.
14720     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14721     <limits.h> exists even on freestanding compilers.  */
14722
14723 #ifdef __STDC__
14724 # include <limits.h>
14725 #else
14726 # include <assert.h>
14727 #endif
14728
14729 #undef socket
14730
14731 /* Override any gcc2 internal prototype to avoid an error.  */
14732 #ifdef __cplusplus
14733 extern "C"
14734 {
14735 #endif
14736 /* We use char because int might match the return type of a gcc2
14737    builtin and then its argument prototype would still apply.  */
14738 char socket ();
14739 /* The GNU C library defines this for functions which it implements
14740     to always fail with ENOSYS.  Some functions are actually named
14741     something starting with __ and the normal name is an alias.  */
14742 #if defined (__stub_socket) || defined (__stub___socket)
14743 choke me
14744 #else
14745 char (*f) () = socket;
14746 #endif
14747 #ifdef __cplusplus
14748 }
14749 #endif
14750
14751 int
14752 main ()
14753 {
14754 return f != socket;
14755   ;
14756   return 0;
14757 }
14758 _ACEOF
14759 rm -f conftest.$ac_objext conftest$ac_exeext
14760 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14761   (eval $ac_link) 2>conftest.er1
14762   ac_status=$?
14763   grep -v '^ *+' conftest.er1 >conftest.err
14764   rm -f conftest.er1
14765   cat conftest.err >&5
14766   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14767   (exit $ac_status); } &&
14768          { ac_try='test -z "$ac_c_werror_flag"
14769                          || test ! -s conftest.err'
14770   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14771   (eval $ac_try) 2>&5
14772   ac_status=$?
14773   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14774   (exit $ac_status); }; } &&
14775          { ac_try='test -s conftest$ac_exeext'
14776   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14777   (eval $ac_try) 2>&5
14778   ac_status=$?
14779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14780   (exit $ac_status); }; }; then
14781   ac_cv_func_socket=yes
14782 else
14783   echo "$as_me: failed program was:" >&5
14784 sed 's/^/| /' conftest.$ac_ext >&5
14785
14786 ac_cv_func_socket=no
14787 fi
14788 rm -f conftest.err conftest.$ac_objext \
14789       conftest$ac_exeext conftest.$ac_ext
14790 fi
14791 echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
14792 echo "${ECHO_T}$ac_cv_func_socket" >&6
14793 if test $ac_cv_func_socket = yes; then
14794   :
14795 else
14796
14797
14798 echo "$as_me:$LINENO: checking for main in -lsocket" >&5
14799 echo $ECHO_N "checking for main in -lsocket... $ECHO_C" >&6
14800 if test "${ac_cv_lib_socket_main+set}" = set; then
14801   echo $ECHO_N "(cached) $ECHO_C" >&6
14802 else
14803   ac_check_lib_save_LIBS=$LIBS
14804 LIBS="-lsocket  $LIBS"
14805 cat >conftest.$ac_ext <<_ACEOF
14806 /* confdefs.h.  */
14807 _ACEOF
14808 cat confdefs.h >>conftest.$ac_ext
14809 cat >>conftest.$ac_ext <<_ACEOF
14810 /* end confdefs.h.  */
14811
14812
14813 int
14814 main ()
14815 {
14816 main ();
14817   ;
14818   return 0;
14819 }
14820 _ACEOF
14821 rm -f conftest.$ac_objext conftest$ac_exeext
14822 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14823   (eval $ac_link) 2>conftest.er1
14824   ac_status=$?
14825   grep -v '^ *+' conftest.er1 >conftest.err
14826   rm -f conftest.er1
14827   cat conftest.err >&5
14828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14829   (exit $ac_status); } &&
14830          { ac_try='test -z "$ac_c_werror_flag"
14831                          || test ! -s conftest.err'
14832   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14833   (eval $ac_try) 2>&5
14834   ac_status=$?
14835   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14836   (exit $ac_status); }; } &&
14837          { ac_try='test -s conftest$ac_exeext'
14838   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14839   (eval $ac_try) 2>&5
14840   ac_status=$?
14841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14842   (exit $ac_status); }; }; then
14843   ac_cv_lib_socket_main=yes
14844 else
14845   echo "$as_me: failed program was:" >&5
14846 sed 's/^/| /' conftest.$ac_ext >&5
14847
14848 ac_cv_lib_socket_main=no
14849 fi
14850 rm -f conftest.err conftest.$ac_objext \
14851       conftest$ac_exeext conftest.$ac_ext
14852 LIBS=$ac_check_lib_save_LIBS
14853 fi
14854 echo "$as_me:$LINENO: result: $ac_cv_lib_socket_main" >&5
14855 echo "${ECHO_T}$ac_cv_lib_socket_main" >&6
14856 if test $ac_cv_lib_socket_main = yes; then
14857   cat >>confdefs.h <<_ACEOF
14858 #define HAVE_LIBSOCKET 1
14859 _ACEOF
14860
14861   LIBS="-lsocket $LIBS"
14862
14863 fi
14864
14865
14866 echo "$as_me:$LINENO: checking for main in -lnet" >&5
14867 echo $ECHO_N "checking for main in -lnet... $ECHO_C" >&6
14868 if test "${ac_cv_lib_net_main+set}" = set; then
14869   echo $ECHO_N "(cached) $ECHO_C" >&6
14870 else
14871   ac_check_lib_save_LIBS=$LIBS
14872 LIBS="-lnet  $LIBS"
14873 cat >conftest.$ac_ext <<_ACEOF
14874 /* confdefs.h.  */
14875 _ACEOF
14876 cat confdefs.h >>conftest.$ac_ext
14877 cat >>conftest.$ac_ext <<_ACEOF
14878 /* end confdefs.h.  */
14879
14880
14881 int
14882 main ()
14883 {
14884 main ();
14885   ;
14886   return 0;
14887 }
14888 _ACEOF
14889 rm -f conftest.$ac_objext conftest$ac_exeext
14890 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14891   (eval $ac_link) 2>conftest.er1
14892   ac_status=$?
14893   grep -v '^ *+' conftest.er1 >conftest.err
14894   rm -f conftest.er1
14895   cat conftest.err >&5
14896   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14897   (exit $ac_status); } &&
14898          { ac_try='test -z "$ac_c_werror_flag"
14899                          || test ! -s conftest.err'
14900   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14901   (eval $ac_try) 2>&5
14902   ac_status=$?
14903   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14904   (exit $ac_status); }; } &&
14905          { ac_try='test -s conftest$ac_exeext'
14906   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14907   (eval $ac_try) 2>&5
14908   ac_status=$?
14909   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14910   (exit $ac_status); }; }; then
14911   ac_cv_lib_net_main=yes
14912 else
14913   echo "$as_me: failed program was:" >&5
14914 sed 's/^/| /' conftest.$ac_ext >&5
14915
14916 ac_cv_lib_net_main=no
14917 fi
14918 rm -f conftest.err conftest.$ac_objext \
14919       conftest$ac_exeext conftest.$ac_ext
14920 LIBS=$ac_check_lib_save_LIBS
14921 fi
14922 echo "$as_me:$LINENO: result: $ac_cv_lib_net_main" >&5
14923 echo "${ECHO_T}$ac_cv_lib_net_main" >&6
14924 if test $ac_cv_lib_net_main = yes; then
14925   cat >>confdefs.h <<_ACEOF
14926 #define HAVE_LIBNET 1
14927 _ACEOF
14928
14929   LIBS="-lnet $LIBS"
14930
14931 fi
14932
14933
14934 echo "$as_me:$LINENO: checking for main in -lnsl_s" >&5
14935 echo $ECHO_N "checking for main in -lnsl_s... $ECHO_C" >&6
14936 if test "${ac_cv_lib_nsl_s_main+set}" = set; then
14937   echo $ECHO_N "(cached) $ECHO_C" >&6
14938 else
14939   ac_check_lib_save_LIBS=$LIBS
14940 LIBS="-lnsl_s  $LIBS"
14941 cat >conftest.$ac_ext <<_ACEOF
14942 /* confdefs.h.  */
14943 _ACEOF
14944 cat confdefs.h >>conftest.$ac_ext
14945 cat >>conftest.$ac_ext <<_ACEOF
14946 /* end confdefs.h.  */
14947
14948
14949 int
14950 main ()
14951 {
14952 main ();
14953   ;
14954   return 0;
14955 }
14956 _ACEOF
14957 rm -f conftest.$ac_objext conftest$ac_exeext
14958 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14959   (eval $ac_link) 2>conftest.er1
14960   ac_status=$?
14961   grep -v '^ *+' conftest.er1 >conftest.err
14962   rm -f conftest.er1
14963   cat conftest.err >&5
14964   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14965   (exit $ac_status); } &&
14966          { ac_try='test -z "$ac_c_werror_flag"
14967                          || test ! -s conftest.err'
14968   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14969   (eval $ac_try) 2>&5
14970   ac_status=$?
14971   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14972   (exit $ac_status); }; } &&
14973          { ac_try='test -s conftest$ac_exeext'
14974   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14975   (eval $ac_try) 2>&5
14976   ac_status=$?
14977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14978   (exit $ac_status); }; }; then
14979   ac_cv_lib_nsl_s_main=yes
14980 else
14981   echo "$as_me: failed program was:" >&5
14982 sed 's/^/| /' conftest.$ac_ext >&5
14983
14984 ac_cv_lib_nsl_s_main=no
14985 fi
14986 rm -f conftest.err conftest.$ac_objext \
14987       conftest$ac_exeext conftest.$ac_ext
14988 LIBS=$ac_check_lib_save_LIBS
14989 fi
14990 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_s_main" >&5
14991 echo "${ECHO_T}$ac_cv_lib_nsl_s_main" >&6
14992 if test $ac_cv_lib_nsl_s_main = yes; then
14993   cat >>confdefs.h <<_ACEOF
14994 #define HAVE_LIBNSL_S 1
14995 _ACEOF
14996
14997   LIBS="-lnsl_s $LIBS"
14998
14999 fi
15000
15001
15002 echo "$as_me:$LINENO: checking for main in -lnsl" >&5
15003 echo $ECHO_N "checking for main in -lnsl... $ECHO_C" >&6
15004 if test "${ac_cv_lib_nsl_main+set}" = set; then
15005   echo $ECHO_N "(cached) $ECHO_C" >&6
15006 else
15007   ac_check_lib_save_LIBS=$LIBS
15008 LIBS="-lnsl  $LIBS"
15009 cat >conftest.$ac_ext <<_ACEOF
15010 /* confdefs.h.  */
15011 _ACEOF
15012 cat confdefs.h >>conftest.$ac_ext
15013 cat >>conftest.$ac_ext <<_ACEOF
15014 /* end confdefs.h.  */
15015
15016
15017 int
15018 main ()
15019 {
15020 main ();
15021   ;
15022   return 0;
15023 }
15024 _ACEOF
15025 rm -f conftest.$ac_objext conftest$ac_exeext
15026 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15027   (eval $ac_link) 2>conftest.er1
15028   ac_status=$?
15029   grep -v '^ *+' conftest.er1 >conftest.err
15030   rm -f conftest.er1
15031   cat conftest.err >&5
15032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15033   (exit $ac_status); } &&
15034          { ac_try='test -z "$ac_c_werror_flag"
15035                          || test ! -s conftest.err'
15036   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15037   (eval $ac_try) 2>&5
15038   ac_status=$?
15039   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15040   (exit $ac_status); }; } &&
15041          { ac_try='test -s conftest$ac_exeext'
15042   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15043   (eval $ac_try) 2>&5
15044   ac_status=$?
15045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15046   (exit $ac_status); }; }; then
15047   ac_cv_lib_nsl_main=yes
15048 else
15049   echo "$as_me: failed program was:" >&5
15050 sed 's/^/| /' conftest.$ac_ext >&5
15051
15052 ac_cv_lib_nsl_main=no
15053 fi
15054 rm -f conftest.err conftest.$ac_objext \
15055       conftest$ac_exeext conftest.$ac_ext
15056 LIBS=$ac_check_lib_save_LIBS
15057 fi
15058 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_main" >&5
15059 echo "${ECHO_T}$ac_cv_lib_nsl_main" >&6
15060 if test $ac_cv_lib_nsl_main = yes; then
15061   cat >>confdefs.h <<_ACEOF
15062 #define HAVE_LIBNSL 1
15063 _ACEOF
15064
15065   LIBS="-lnsl $LIBS"
15066
15067 fi
15068
15069
15070 echo "$as_me:$LINENO: checking for socket in -linet" >&5
15071 echo $ECHO_N "checking for socket in -linet... $ECHO_C" >&6
15072 if test "${ac_cv_lib_inet_socket+set}" = set; then
15073   echo $ECHO_N "(cached) $ECHO_C" >&6
15074 else
15075   ac_check_lib_save_LIBS=$LIBS
15076 LIBS="-linet  $LIBS"
15077 cat >conftest.$ac_ext <<_ACEOF
15078 /* confdefs.h.  */
15079 _ACEOF
15080 cat confdefs.h >>conftest.$ac_ext
15081 cat >>conftest.$ac_ext <<_ACEOF
15082 /* end confdefs.h.  */
15083
15084 /* Override any gcc2 internal prototype to avoid an error.  */
15085 #ifdef __cplusplus
15086 extern "C"
15087 #endif
15088 /* We use char because int might match the return type of a gcc2
15089    builtin and then its argument prototype would still apply.  */
15090 char socket ();
15091 int
15092 main ()
15093 {
15094 socket ();
15095   ;
15096   return 0;
15097 }
15098 _ACEOF
15099 rm -f conftest.$ac_objext conftest$ac_exeext
15100 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15101   (eval $ac_link) 2>conftest.er1
15102   ac_status=$?
15103   grep -v '^ *+' conftest.er1 >conftest.err
15104   rm -f conftest.er1
15105   cat conftest.err >&5
15106   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15107   (exit $ac_status); } &&
15108          { ac_try='test -z "$ac_c_werror_flag"
15109                          || test ! -s conftest.err'
15110   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15111   (eval $ac_try) 2>&5
15112   ac_status=$?
15113   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15114   (exit $ac_status); }; } &&
15115          { ac_try='test -s conftest$ac_exeext'
15116   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15117   (eval $ac_try) 2>&5
15118   ac_status=$?
15119   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15120   (exit $ac_status); }; }; then
15121   ac_cv_lib_inet_socket=yes
15122 else
15123   echo "$as_me: failed program was:" >&5
15124 sed 's/^/| /' conftest.$ac_ext >&5
15125
15126 ac_cv_lib_inet_socket=no
15127 fi
15128 rm -f conftest.err conftest.$ac_objext \
15129       conftest$ac_exeext conftest.$ac_ext
15130 LIBS=$ac_check_lib_save_LIBS
15131 fi
15132 echo "$as_me:$LINENO: result: $ac_cv_lib_inet_socket" >&5
15133 echo "${ECHO_T}$ac_cv_lib_inet_socket" >&6
15134 if test $ac_cv_lib_inet_socket = yes; then
15135   cat >>confdefs.h <<_ACEOF
15136 #define HAVE_LIBINET 1
15137 _ACEOF
15138
15139   LIBS="-linet $LIBS"
15140
15141 fi
15142
15143
15144 echo "$as_me:$LINENO: checking for main in -lgen" >&5
15145 echo $ECHO_N "checking for main in -lgen... $ECHO_C" >&6
15146 if test "${ac_cv_lib_gen_main+set}" = set; then
15147   echo $ECHO_N "(cached) $ECHO_C" >&6
15148 else
15149   ac_check_lib_save_LIBS=$LIBS
15150 LIBS="-lgen  $LIBS"
15151 cat >conftest.$ac_ext <<_ACEOF
15152 /* confdefs.h.  */
15153 _ACEOF
15154 cat confdefs.h >>conftest.$ac_ext
15155 cat >>conftest.$ac_ext <<_ACEOF
15156 /* end confdefs.h.  */
15157
15158
15159 int
15160 main ()
15161 {
15162 main ();
15163   ;
15164   return 0;
15165 }
15166 _ACEOF
15167 rm -f conftest.$ac_objext conftest$ac_exeext
15168 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15169   (eval $ac_link) 2>conftest.er1
15170   ac_status=$?
15171   grep -v '^ *+' conftest.er1 >conftest.err
15172   rm -f conftest.er1
15173   cat conftest.err >&5
15174   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15175   (exit $ac_status); } &&
15176          { ac_try='test -z "$ac_c_werror_flag"
15177                          || test ! -s conftest.err'
15178   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15179   (eval $ac_try) 2>&5
15180   ac_status=$?
15181   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15182   (exit $ac_status); }; } &&
15183          { ac_try='test -s conftest$ac_exeext'
15184   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15185   (eval $ac_try) 2>&5
15186   ac_status=$?
15187   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15188   (exit $ac_status); }; }; then
15189   ac_cv_lib_gen_main=yes
15190 else
15191   echo "$as_me: failed program was:" >&5
15192 sed 's/^/| /' conftest.$ac_ext >&5
15193
15194 ac_cv_lib_gen_main=no
15195 fi
15196 rm -f conftest.err conftest.$ac_objext \
15197       conftest$ac_exeext conftest.$ac_ext
15198 LIBS=$ac_check_lib_save_LIBS
15199 fi
15200 echo "$as_me:$LINENO: result: $ac_cv_lib_gen_main" >&5
15201 echo "${ECHO_T}$ac_cv_lib_gen_main" >&6
15202 if test $ac_cv_lib_gen_main = yes; then
15203   cat >>confdefs.h <<_ACEOF
15204 #define HAVE_LIBGEN 1
15205 _ACEOF
15206
15207   LIBS="-lgen $LIBS"
15208
15209 fi
15210
15211
15212 fi
15213
15214
15215 echo "$as_me:$LINENO: checking for select" >&5
15216 echo $ECHO_N "checking for select... $ECHO_C" >&6
15217 if test "${ac_cv_func_select+set}" = set; then
15218   echo $ECHO_N "(cached) $ECHO_C" >&6
15219 else
15220   cat >conftest.$ac_ext <<_ACEOF
15221 /* confdefs.h.  */
15222 _ACEOF
15223 cat confdefs.h >>conftest.$ac_ext
15224 cat >>conftest.$ac_ext <<_ACEOF
15225 /* end confdefs.h.  */
15226 /* Define select to an innocuous variant, in case <limits.h> declares select.
15227    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15228 #define select innocuous_select
15229
15230 /* System header to define __stub macros and hopefully few prototypes,
15231     which can conflict with char select (); below.
15232     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15233     <limits.h> exists even on freestanding compilers.  */
15234
15235 #ifdef __STDC__
15236 # include <limits.h>
15237 #else
15238 # include <assert.h>
15239 #endif
15240
15241 #undef select
15242
15243 /* Override any gcc2 internal prototype to avoid an error.  */
15244 #ifdef __cplusplus
15245 extern "C"
15246 {
15247 #endif
15248 /* We use char because int might match the return type of a gcc2
15249    builtin and then its argument prototype would still apply.  */
15250 char select ();
15251 /* The GNU C library defines this for functions which it implements
15252     to always fail with ENOSYS.  Some functions are actually named
15253     something starting with __ and the normal name is an alias.  */
15254 #if defined (__stub_select) || defined (__stub___select)
15255 choke me
15256 #else
15257 char (*f) () = select;
15258 #endif
15259 #ifdef __cplusplus
15260 }
15261 #endif
15262
15263 int
15264 main ()
15265 {
15266 return f != select;
15267   ;
15268   return 0;
15269 }
15270 _ACEOF
15271 rm -f conftest.$ac_objext conftest$ac_exeext
15272 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15273   (eval $ac_link) 2>conftest.er1
15274   ac_status=$?
15275   grep -v '^ *+' conftest.er1 >conftest.err
15276   rm -f conftest.er1
15277   cat conftest.err >&5
15278   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15279   (exit $ac_status); } &&
15280          { ac_try='test -z "$ac_c_werror_flag"
15281                          || test ! -s conftest.err'
15282   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15283   (eval $ac_try) 2>&5
15284   ac_status=$?
15285   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15286   (exit $ac_status); }; } &&
15287          { ac_try='test -s conftest$ac_exeext'
15288   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15289   (eval $ac_try) 2>&5
15290   ac_status=$?
15291   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15292   (exit $ac_status); }; }; then
15293   ac_cv_func_select=yes
15294 else
15295   echo "$as_me: failed program was:" >&5
15296 sed 's/^/| /' conftest.$ac_ext >&5
15297
15298 ac_cv_func_select=no
15299 fi
15300 rm -f conftest.err conftest.$ac_objext \
15301       conftest$ac_exeext conftest.$ac_ext
15302 fi
15303 echo "$as_me:$LINENO: result: $ac_cv_func_select" >&5
15304 echo "${ECHO_T}$ac_cv_func_select" >&6
15305 if test $ac_cv_func_select = yes; then
15306   :
15307 else
15308   { { echo "$as_me:$LINENO: error: select() required." >&5
15309 echo "$as_me: error: select() required." >&2;}
15310    { (exit 1); exit 1; }; }
15311 fi
15312
15313
15314 if test "${ac_cv_header_winsock_h}" != yes; then
15315
15316
15317 for ac_header in sys/select.h sys/socket.h
15318 do
15319 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15320 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15321   echo "$as_me:$LINENO: checking for $ac_header" >&5
15322 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15323 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15324   echo $ECHO_N "(cached) $ECHO_C" >&6
15325 fi
15326 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15327 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15328 else
15329   # Is the header compilable?
15330 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15331 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15332 cat >conftest.$ac_ext <<_ACEOF
15333 /* confdefs.h.  */
15334 _ACEOF
15335 cat confdefs.h >>conftest.$ac_ext
15336 cat >>conftest.$ac_ext <<_ACEOF
15337 /* end confdefs.h.  */
15338 $ac_includes_default
15339 #include <$ac_header>
15340 _ACEOF
15341 rm -f conftest.$ac_objext
15342 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15343   (eval $ac_compile) 2>conftest.er1
15344   ac_status=$?
15345   grep -v '^ *+' conftest.er1 >conftest.err
15346   rm -f conftest.er1
15347   cat conftest.err >&5
15348   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15349   (exit $ac_status); } &&
15350          { ac_try='test -z "$ac_c_werror_flag"
15351                          || test ! -s conftest.err'
15352   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15353   (eval $ac_try) 2>&5
15354   ac_status=$?
15355   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15356   (exit $ac_status); }; } &&
15357          { ac_try='test -s conftest.$ac_objext'
15358   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15359   (eval $ac_try) 2>&5
15360   ac_status=$?
15361   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15362   (exit $ac_status); }; }; then
15363   ac_header_compiler=yes
15364 else
15365   echo "$as_me: failed program was:" >&5
15366 sed 's/^/| /' conftest.$ac_ext >&5
15367
15368 ac_header_compiler=no
15369 fi
15370 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15371 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15372 echo "${ECHO_T}$ac_header_compiler" >&6
15373
15374 # Is the header present?
15375 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15376 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15377 cat >conftest.$ac_ext <<_ACEOF
15378 /* confdefs.h.  */
15379 _ACEOF
15380 cat confdefs.h >>conftest.$ac_ext
15381 cat >>conftest.$ac_ext <<_ACEOF
15382 /* end confdefs.h.  */
15383 #include <$ac_header>
15384 _ACEOF
15385 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15386   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15387   ac_status=$?
15388   grep -v '^ *+' conftest.er1 >conftest.err
15389   rm -f conftest.er1
15390   cat conftest.err >&5
15391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15392   (exit $ac_status); } >/dev/null; then
15393   if test -s conftest.err; then
15394     ac_cpp_err=$ac_c_preproc_warn_flag
15395     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15396   else
15397     ac_cpp_err=
15398   fi
15399 else
15400   ac_cpp_err=yes
15401 fi
15402 if test -z "$ac_cpp_err"; then
15403   ac_header_preproc=yes
15404 else
15405   echo "$as_me: failed program was:" >&5
15406 sed 's/^/| /' conftest.$ac_ext >&5
15407
15408   ac_header_preproc=no
15409 fi
15410 rm -f conftest.err conftest.$ac_ext
15411 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15412 echo "${ECHO_T}$ac_header_preproc" >&6
15413
15414 # So?  What about this header?
15415 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15416   yes:no: )
15417     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15418 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15419     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15420 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15421     ac_header_preproc=yes
15422     ;;
15423   no:yes:* )
15424     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15425 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15426     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15427 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15428     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15429 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15430     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15431 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15432     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15433 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15434     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15435 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15436     (
15437       cat <<\_ASBOX
15438 ## --------------------------------------------- ##
15439 ## Report this to <http://www.openldap.org/its/> ##
15440 ## --------------------------------------------- ##
15441 _ASBOX
15442     ) |
15443       sed "s/^/$as_me: WARNING:     /" >&2
15444     ;;
15445 esac
15446 echo "$as_me:$LINENO: checking for $ac_header" >&5
15447 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15448 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15449   echo $ECHO_N "(cached) $ECHO_C" >&6
15450 else
15451   eval "$as_ac_Header=\$ac_header_preproc"
15452 fi
15453 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15454 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15455
15456 fi
15457 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15458   cat >>confdefs.h <<_ACEOF
15459 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15460 _ACEOF
15461
15462 fi
15463
15464 done
15465
15466 echo "$as_me:$LINENO: checking types of arguments for select" >&5
15467 echo $ECHO_N "checking types of arguments for select... $ECHO_C" >&6
15468 if test "${ac_cv_func_select_args+set}" = set; then
15469   echo $ECHO_N "(cached) $ECHO_C" >&6
15470 else
15471   for ac_arg234 in 'fd_set *' 'int *' 'void *'; do
15472  for ac_arg1 in 'int' 'size_t' 'unsigned long' 'unsigned'; do
15473   for ac_arg5 in 'struct timeval *' 'const struct timeval *'; do
15474    cat >conftest.$ac_ext <<_ACEOF
15475 /* confdefs.h.  */
15476 _ACEOF
15477 cat confdefs.h >>conftest.$ac_ext
15478 cat >>conftest.$ac_ext <<_ACEOF
15479 /* end confdefs.h.  */
15480 $ac_includes_default
15481 #if HAVE_SYS_SELECT_H
15482 # include <sys/select.h>
15483 #endif
15484 #if HAVE_SYS_SOCKET_H
15485 # include <sys/socket.h>
15486 #endif
15487
15488 int
15489 main ()
15490 {
15491 extern int select ($ac_arg1,
15492                                             $ac_arg234, $ac_arg234, $ac_arg234,
15493                                             $ac_arg5);
15494   ;
15495   return 0;
15496 }
15497 _ACEOF
15498 rm -f conftest.$ac_objext
15499 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15500   (eval $ac_compile) 2>conftest.er1
15501   ac_status=$?
15502   grep -v '^ *+' conftest.er1 >conftest.err
15503   rm -f conftest.er1
15504   cat conftest.err >&5
15505   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15506   (exit $ac_status); } &&
15507          { ac_try='test -z "$ac_c_werror_flag"
15508                          || test ! -s conftest.err'
15509   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15510   (eval $ac_try) 2>&5
15511   ac_status=$?
15512   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15513   (exit $ac_status); }; } &&
15514          { ac_try='test -s conftest.$ac_objext'
15515   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15516   (eval $ac_try) 2>&5
15517   ac_status=$?
15518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15519   (exit $ac_status); }; }; then
15520   ac_cv_func_select_args="$ac_arg1,$ac_arg234,$ac_arg5"; break 3
15521 else
15522   echo "$as_me: failed program was:" >&5
15523 sed 's/^/| /' conftest.$ac_ext >&5
15524
15525 fi
15526 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15527   done
15528  done
15529 done
15530 # Provide a safe default value.
15531 : ${ac_cv_func_select_args='int,int *,struct timeval *'}
15532
15533 fi
15534 echo "$as_me:$LINENO: result: $ac_cv_func_select_args" >&5
15535 echo "${ECHO_T}$ac_cv_func_select_args" >&6
15536 ac_save_IFS=$IFS; IFS=','
15537 set dummy `echo "$ac_cv_func_select_args" | sed 's/\*/\*/g'`
15538 IFS=$ac_save_IFS
15539 shift
15540
15541 cat >>confdefs.h <<_ACEOF
15542 #define SELECT_TYPE_ARG1 $1
15543 _ACEOF
15544
15545
15546 cat >>confdefs.h <<_ACEOF
15547 #define SELECT_TYPE_ARG234 ($2)
15548 _ACEOF
15549
15550
15551 cat >>confdefs.h <<_ACEOF
15552 #define SELECT_TYPE_ARG5 ($3)
15553 _ACEOF
15554
15555 rm -f conftest*
15556
15557 fi
15558
15559
15560
15561 for ac_func in poll
15562 do
15563 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15564 echo "$as_me:$LINENO: checking for $ac_func" >&5
15565 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15566 if eval "test \"\${$as_ac_var+set}\" = set"; then
15567   echo $ECHO_N "(cached) $ECHO_C" >&6
15568 else
15569   cat >conftest.$ac_ext <<_ACEOF
15570 /* confdefs.h.  */
15571 _ACEOF
15572 cat confdefs.h >>conftest.$ac_ext
15573 cat >>conftest.$ac_ext <<_ACEOF
15574 /* end confdefs.h.  */
15575 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15576    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15577 #define $ac_func innocuous_$ac_func
15578
15579 /* System header to define __stub macros and hopefully few prototypes,
15580     which can conflict with char $ac_func (); below.
15581     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15582     <limits.h> exists even on freestanding compilers.  */
15583
15584 #ifdef __STDC__
15585 # include <limits.h>
15586 #else
15587 # include <assert.h>
15588 #endif
15589
15590 #undef $ac_func
15591
15592 /* Override any gcc2 internal prototype to avoid an error.  */
15593 #ifdef __cplusplus
15594 extern "C"
15595 {
15596 #endif
15597 /* We use char because int might match the return type of a gcc2
15598    builtin and then its argument prototype would still apply.  */
15599 char $ac_func ();
15600 /* The GNU C library defines this for functions which it implements
15601     to always fail with ENOSYS.  Some functions are actually named
15602     something starting with __ and the normal name is an alias.  */
15603 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15604 choke me
15605 #else
15606 char (*f) () = $ac_func;
15607 #endif
15608 #ifdef __cplusplus
15609 }
15610 #endif
15611
15612 int
15613 main ()
15614 {
15615 return f != $ac_func;
15616   ;
15617   return 0;
15618 }
15619 _ACEOF
15620 rm -f conftest.$ac_objext conftest$ac_exeext
15621 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15622   (eval $ac_link) 2>conftest.er1
15623   ac_status=$?
15624   grep -v '^ *+' conftest.er1 >conftest.err
15625   rm -f conftest.er1
15626   cat conftest.err >&5
15627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15628   (exit $ac_status); } &&
15629          { ac_try='test -z "$ac_c_werror_flag"
15630                          || test ! -s conftest.err'
15631   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15632   (eval $ac_try) 2>&5
15633   ac_status=$?
15634   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15635   (exit $ac_status); }; } &&
15636          { ac_try='test -s conftest$ac_exeext'
15637   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15638   (eval $ac_try) 2>&5
15639   ac_status=$?
15640   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15641   (exit $ac_status); }; }; then
15642   eval "$as_ac_var=yes"
15643 else
15644   echo "$as_me: failed program was:" >&5
15645 sed 's/^/| /' conftest.$ac_ext >&5
15646
15647 eval "$as_ac_var=no"
15648 fi
15649 rm -f conftest.err conftest.$ac_objext \
15650       conftest$ac_exeext conftest.$ac_ext
15651 fi
15652 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15653 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15654 if test `eval echo '${'$as_ac_var'}'` = yes; then
15655   cat >>confdefs.h <<_ACEOF
15656 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15657 _ACEOF
15658
15659 fi
15660 done
15661
15662 if test $ac_cv_func_poll = yes; then
15663
15664
15665 for ac_header in poll.h sys/poll.h
15666 do
15667 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15668 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15669   echo "$as_me:$LINENO: checking for $ac_header" >&5
15670 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15671 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15672   echo $ECHO_N "(cached) $ECHO_C" >&6
15673 fi
15674 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15675 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15676 else
15677   # Is the header compilable?
15678 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15679 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15680 cat >conftest.$ac_ext <<_ACEOF
15681 /* confdefs.h.  */
15682 _ACEOF
15683 cat confdefs.h >>conftest.$ac_ext
15684 cat >>conftest.$ac_ext <<_ACEOF
15685 /* end confdefs.h.  */
15686 $ac_includes_default
15687 #include <$ac_header>
15688 _ACEOF
15689 rm -f conftest.$ac_objext
15690 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15691   (eval $ac_compile) 2>conftest.er1
15692   ac_status=$?
15693   grep -v '^ *+' conftest.er1 >conftest.err
15694   rm -f conftest.er1
15695   cat conftest.err >&5
15696   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15697   (exit $ac_status); } &&
15698          { ac_try='test -z "$ac_c_werror_flag"
15699                          || test ! -s conftest.err'
15700   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15701   (eval $ac_try) 2>&5
15702   ac_status=$?
15703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15704   (exit $ac_status); }; } &&
15705          { ac_try='test -s conftest.$ac_objext'
15706   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15707   (eval $ac_try) 2>&5
15708   ac_status=$?
15709   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15710   (exit $ac_status); }; }; then
15711   ac_header_compiler=yes
15712 else
15713   echo "$as_me: failed program was:" >&5
15714 sed 's/^/| /' conftest.$ac_ext >&5
15715
15716 ac_header_compiler=no
15717 fi
15718 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15719 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15720 echo "${ECHO_T}$ac_header_compiler" >&6
15721
15722 # Is the header present?
15723 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15724 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15725 cat >conftest.$ac_ext <<_ACEOF
15726 /* confdefs.h.  */
15727 _ACEOF
15728 cat confdefs.h >>conftest.$ac_ext
15729 cat >>conftest.$ac_ext <<_ACEOF
15730 /* end confdefs.h.  */
15731 #include <$ac_header>
15732 _ACEOF
15733 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15734   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15735   ac_status=$?
15736   grep -v '^ *+' conftest.er1 >conftest.err
15737   rm -f conftest.er1
15738   cat conftest.err >&5
15739   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15740   (exit $ac_status); } >/dev/null; then
15741   if test -s conftest.err; then
15742     ac_cpp_err=$ac_c_preproc_warn_flag
15743     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15744   else
15745     ac_cpp_err=
15746   fi
15747 else
15748   ac_cpp_err=yes
15749 fi
15750 if test -z "$ac_cpp_err"; then
15751   ac_header_preproc=yes
15752 else
15753   echo "$as_me: failed program was:" >&5
15754 sed 's/^/| /' conftest.$ac_ext >&5
15755
15756   ac_header_preproc=no
15757 fi
15758 rm -f conftest.err conftest.$ac_ext
15759 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15760 echo "${ECHO_T}$ac_header_preproc" >&6
15761
15762 # So?  What about this header?
15763 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15764   yes:no: )
15765     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15766 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15767     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15768 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15769     ac_header_preproc=yes
15770     ;;
15771   no:yes:* )
15772     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15773 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15774     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15775 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15776     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15777 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15778     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15779 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15780     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15781 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15782     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15783 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15784     (
15785       cat <<\_ASBOX
15786 ## --------------------------------------------- ##
15787 ## Report this to <http://www.openldap.org/its/> ##
15788 ## --------------------------------------------- ##
15789 _ASBOX
15790     ) |
15791       sed "s/^/$as_me: WARNING:     /" >&2
15792     ;;
15793 esac
15794 echo "$as_me:$LINENO: checking for $ac_header" >&5
15795 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15796 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15797   echo $ECHO_N "(cached) $ECHO_C" >&6
15798 else
15799   eval "$as_ac_Header=\$ac_header_preproc"
15800 fi
15801 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15802 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15803
15804 fi
15805 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15806   cat >>confdefs.h <<_ACEOF
15807 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15808 _ACEOF
15809
15810 fi
15811
15812 done
15813
15814 fi
15815
15816
15817 for ac_header in sys/epoll.h
15818 do
15819 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15820 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15821   echo "$as_me:$LINENO: checking for $ac_header" >&5
15822 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15823 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15824   echo $ECHO_N "(cached) $ECHO_C" >&6
15825 fi
15826 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15827 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15828 else
15829   # Is the header compilable?
15830 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15831 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15832 cat >conftest.$ac_ext <<_ACEOF
15833 /* confdefs.h.  */
15834 _ACEOF
15835 cat confdefs.h >>conftest.$ac_ext
15836 cat >>conftest.$ac_ext <<_ACEOF
15837 /* end confdefs.h.  */
15838 $ac_includes_default
15839 #include <$ac_header>
15840 _ACEOF
15841 rm -f conftest.$ac_objext
15842 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15843   (eval $ac_compile) 2>conftest.er1
15844   ac_status=$?
15845   grep -v '^ *+' conftest.er1 >conftest.err
15846   rm -f conftest.er1
15847   cat conftest.err >&5
15848   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15849   (exit $ac_status); } &&
15850          { ac_try='test -z "$ac_c_werror_flag"
15851                          || test ! -s conftest.err'
15852   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15853   (eval $ac_try) 2>&5
15854   ac_status=$?
15855   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15856   (exit $ac_status); }; } &&
15857          { ac_try='test -s conftest.$ac_objext'
15858   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15859   (eval $ac_try) 2>&5
15860   ac_status=$?
15861   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15862   (exit $ac_status); }; }; then
15863   ac_header_compiler=yes
15864 else
15865   echo "$as_me: failed program was:" >&5
15866 sed 's/^/| /' conftest.$ac_ext >&5
15867
15868 ac_header_compiler=no
15869 fi
15870 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15871 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15872 echo "${ECHO_T}$ac_header_compiler" >&6
15873
15874 # Is the header present?
15875 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15876 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15877 cat >conftest.$ac_ext <<_ACEOF
15878 /* confdefs.h.  */
15879 _ACEOF
15880 cat confdefs.h >>conftest.$ac_ext
15881 cat >>conftest.$ac_ext <<_ACEOF
15882 /* end confdefs.h.  */
15883 #include <$ac_header>
15884 _ACEOF
15885 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15886   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15887   ac_status=$?
15888   grep -v '^ *+' conftest.er1 >conftest.err
15889   rm -f conftest.er1
15890   cat conftest.err >&5
15891   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15892   (exit $ac_status); } >/dev/null; then
15893   if test -s conftest.err; then
15894     ac_cpp_err=$ac_c_preproc_warn_flag
15895     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15896   else
15897     ac_cpp_err=
15898   fi
15899 else
15900   ac_cpp_err=yes
15901 fi
15902 if test -z "$ac_cpp_err"; then
15903   ac_header_preproc=yes
15904 else
15905   echo "$as_me: failed program was:" >&5
15906 sed 's/^/| /' conftest.$ac_ext >&5
15907
15908   ac_header_preproc=no
15909 fi
15910 rm -f conftest.err conftest.$ac_ext
15911 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15912 echo "${ECHO_T}$ac_header_preproc" >&6
15913
15914 # So?  What about this header?
15915 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15916   yes:no: )
15917     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15918 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15919     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15920 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15921     ac_header_preproc=yes
15922     ;;
15923   no:yes:* )
15924     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15925 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15926     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
15927 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
15928     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15929 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15930     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
15931 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
15932     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15933 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15934     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15935 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
15936     (
15937       cat <<\_ASBOX
15938 ## --------------------------------------------- ##
15939 ## Report this to <http://www.openldap.org/its/> ##
15940 ## --------------------------------------------- ##
15941 _ASBOX
15942     ) |
15943       sed "s/^/$as_me: WARNING:     /" >&2
15944     ;;
15945 esac
15946 echo "$as_me:$LINENO: checking for $ac_header" >&5
15947 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15948 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15949   echo $ECHO_N "(cached) $ECHO_C" >&6
15950 else
15951   eval "$as_ac_Header=\$ac_header_preproc"
15952 fi
15953 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15954 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15955
15956 fi
15957 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15958   cat >>confdefs.h <<_ACEOF
15959 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15960 _ACEOF
15961
15962 fi
15963
15964 done
15965
15966 if test "${ac_cv_header_sys_epoll_h}" = yes; then
15967         echo "$as_me:$LINENO: checking for epoll system call" >&5
15968 echo $ECHO_N "checking for epoll system call... $ECHO_C" >&6
15969         if test "$cross_compiling" = yes; then
15970   echo "$as_me:$LINENO: result: no" >&5
15971 echo "${ECHO_T}no" >&6
15972 else
15973   cat >conftest.$ac_ext <<_ACEOF
15974 /* confdefs.h.  */
15975 _ACEOF
15976 cat confdefs.h >>conftest.$ac_ext
15977 cat >>conftest.$ac_ext <<_ACEOF
15978 /* end confdefs.h.  */
15979 int main(int argc, char **argv)
15980 {
15981         int epfd = epoll_create(256);
15982         exit (epfd == -1 ? 1 : 0);
15983 }
15984 _ACEOF
15985 rm -f conftest$ac_exeext
15986 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15987   (eval $ac_link) 2>&5
15988   ac_status=$?
15989   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15990   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15991   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15992   (eval $ac_try) 2>&5
15993   ac_status=$?
15994   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15995   (exit $ac_status); }; }; then
15996   echo "$as_me:$LINENO: result: yes" >&5
15997 echo "${ECHO_T}yes" >&6
15998
15999 cat >>confdefs.h <<\_ACEOF
16000 #define HAVE_EPOLL 1
16001 _ACEOF
16002
16003 else
16004   echo "$as_me: program exited with status $ac_status" >&5
16005 echo "$as_me: failed program was:" >&5
16006 sed 's/^/| /' conftest.$ac_ext >&5
16007
16008 ( exit $ac_status )
16009 echo "$as_me:$LINENO: result: no" >&5
16010 echo "${ECHO_T}no" >&6
16011 fi
16012 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16013 fi
16014 fi
16015
16016
16017 for ac_header in sys/devpoll.h
16018 do
16019 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16020 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16021   echo "$as_me:$LINENO: checking for $ac_header" >&5
16022 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16023 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16024   echo $ECHO_N "(cached) $ECHO_C" >&6
16025 fi
16026 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16027 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16028 else
16029   # Is the header compilable?
16030 echo "$as_me:$LINENO: checking $ac_header usability" >&5
16031 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16032 cat >conftest.$ac_ext <<_ACEOF
16033 /* confdefs.h.  */
16034 _ACEOF
16035 cat confdefs.h >>conftest.$ac_ext
16036 cat >>conftest.$ac_ext <<_ACEOF
16037 /* end confdefs.h.  */
16038 $ac_includes_default
16039 #include <$ac_header>
16040 _ACEOF
16041 rm -f conftest.$ac_objext
16042 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16043   (eval $ac_compile) 2>conftest.er1
16044   ac_status=$?
16045   grep -v '^ *+' conftest.er1 >conftest.err
16046   rm -f conftest.er1
16047   cat conftest.err >&5
16048   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16049   (exit $ac_status); } &&
16050          { ac_try='test -z "$ac_c_werror_flag"
16051                          || test ! -s conftest.err'
16052   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16053   (eval $ac_try) 2>&5
16054   ac_status=$?
16055   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16056   (exit $ac_status); }; } &&
16057          { ac_try='test -s conftest.$ac_objext'
16058   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16059   (eval $ac_try) 2>&5
16060   ac_status=$?
16061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16062   (exit $ac_status); }; }; then
16063   ac_header_compiler=yes
16064 else
16065   echo "$as_me: failed program was:" >&5
16066 sed 's/^/| /' conftest.$ac_ext >&5
16067
16068 ac_header_compiler=no
16069 fi
16070 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16071 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16072 echo "${ECHO_T}$ac_header_compiler" >&6
16073
16074 # Is the header present?
16075 echo "$as_me:$LINENO: checking $ac_header presence" >&5
16076 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
16077 cat >conftest.$ac_ext <<_ACEOF
16078 /* confdefs.h.  */
16079 _ACEOF
16080 cat confdefs.h >>conftest.$ac_ext
16081 cat >>conftest.$ac_ext <<_ACEOF
16082 /* end confdefs.h.  */
16083 #include <$ac_header>
16084 _ACEOF
16085 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
16086   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16087   ac_status=$?
16088   grep -v '^ *+' conftest.er1 >conftest.err
16089   rm -f conftest.er1
16090   cat conftest.err >&5
16091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16092   (exit $ac_status); } >/dev/null; then
16093   if test -s conftest.err; then
16094     ac_cpp_err=$ac_c_preproc_warn_flag
16095     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
16096   else
16097     ac_cpp_err=
16098   fi
16099 else
16100   ac_cpp_err=yes
16101 fi
16102 if test -z "$ac_cpp_err"; then
16103   ac_header_preproc=yes
16104 else
16105   echo "$as_me: failed program was:" >&5
16106 sed 's/^/| /' conftest.$ac_ext >&5
16107
16108   ac_header_preproc=no
16109 fi
16110 rm -f conftest.err conftest.$ac_ext
16111 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16112 echo "${ECHO_T}$ac_header_preproc" >&6
16113
16114 # So?  What about this header?
16115 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16116   yes:no: )
16117     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
16118 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
16119     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
16120 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
16121     ac_header_preproc=yes
16122     ;;
16123   no:yes:* )
16124     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
16125 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
16126     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
16127 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
16128     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
16129 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
16130     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
16131 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
16132     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
16133 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16134     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
16135 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
16136     (
16137       cat <<\_ASBOX
16138 ## --------------------------------------------- ##
16139 ## Report this to <http://www.openldap.org/its/> ##
16140 ## --------------------------------------------- ##
16141 _ASBOX
16142     ) |
16143       sed "s/^/$as_me: WARNING:     /" >&2
16144     ;;
16145 esac
16146 echo "$as_me:$LINENO: checking for $ac_header" >&5
16147 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16148 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16149   echo $ECHO_N "(cached) $ECHO_C" >&6
16150 else
16151   eval "$as_ac_Header=\$ac_header_preproc"
16152 fi
16153 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16154 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16155
16156 fi
16157 if test `eval echo '${'$as_ac_Header'}'` = yes; then
16158   cat >>confdefs.h <<_ACEOF
16159 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16160 _ACEOF
16161
16162 fi
16163
16164 done
16165
16166 if test "${ac_cv_header_sys_devpoll_h}" = yes \
16167                 -a "${ac_cv_header_poll_h}" = yes ; \
16168 then
16169         echo "$as_me:$LINENO: checking for /dev/poll" >&5
16170 echo $ECHO_N "checking for /dev/poll... $ECHO_C" >&6
16171         if test "$cross_compiling" = yes; then
16172   echo "$as_me:$LINENO: result: no" >&5
16173 echo "${ECHO_T}no" >&6
16174 else
16175   cat >conftest.$ac_ext <<_ACEOF
16176 /* confdefs.h.  */
16177 _ACEOF
16178 cat confdefs.h >>conftest.$ac_ext
16179 cat >>conftest.$ac_ext <<_ACEOF
16180 /* end confdefs.h.  */
16181 int main(int argc, char **argv)
16182 {
16183         int devpollfd = open("/dev/poll", /* O_RDWR */ 2);
16184         exit (devpollfd == -1 ? 1 : 0);
16185 }
16186 _ACEOF
16187 rm -f conftest$ac_exeext
16188 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16189   (eval $ac_link) 2>&5
16190   ac_status=$?
16191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16192   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16193   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16194   (eval $ac_try) 2>&5
16195   ac_status=$?
16196   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16197   (exit $ac_status); }; }; then
16198   echo "$as_me:$LINENO: result: yes" >&5
16199 echo "${ECHO_T}yes" >&6
16200
16201 cat >>confdefs.h <<\_ACEOF
16202 #define HAVE_DEVPOLL 1
16203 _ACEOF
16204
16205 else
16206   echo "$as_me: program exited with status $ac_status" >&5
16207 echo "$as_me: failed program was:" >&5
16208 sed 's/^/| /' conftest.$ac_ext >&5
16209
16210 ( exit $ac_status )
16211 echo "$as_me:$LINENO: result: no" >&5
16212 echo "${ECHO_T}no" >&6
16213 fi
16214 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16215 fi
16216 fi
16217
16218 # strerror checks
16219 echo "$as_me:$LINENO: checking declaration of sys_errlist" >&5
16220 echo $ECHO_N "checking declaration of sys_errlist... $ECHO_C" >&6
16221 if test "${ol_cv_dcl_sys_errlist+set}" = set; then
16222   echo $ECHO_N "(cached) $ECHO_C" >&6
16223 else
16224
16225         cat >conftest.$ac_ext <<_ACEOF
16226 /* confdefs.h.  */
16227 _ACEOF
16228 cat confdefs.h >>conftest.$ac_ext
16229 cat >>conftest.$ac_ext <<_ACEOF
16230 /* end confdefs.h.  */
16231
16232 #include <stdio.h>
16233 #include <sys/types.h>
16234 #include <errno.h>
16235 #ifdef _WIN32
16236 #include <stdlib.h>
16237 #endif
16238 int
16239 main ()
16240 {
16241 char *c = (char *) *sys_errlist
16242   ;
16243   return 0;
16244 }
16245 _ACEOF
16246 rm -f conftest.$ac_objext
16247 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16248   (eval $ac_compile) 2>conftest.er1
16249   ac_status=$?
16250   grep -v '^ *+' conftest.er1 >conftest.err
16251   rm -f conftest.er1
16252   cat conftest.err >&5
16253   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16254   (exit $ac_status); } &&
16255          { ac_try='test -z "$ac_c_werror_flag"
16256                          || test ! -s conftest.err'
16257   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16258   (eval $ac_try) 2>&5
16259   ac_status=$?
16260   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16261   (exit $ac_status); }; } &&
16262          { ac_try='test -s conftest.$ac_objext'
16263   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16264   (eval $ac_try) 2>&5
16265   ac_status=$?
16266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16267   (exit $ac_status); }; }; then
16268   ol_cv_dcl_sys_errlist=yes
16269         ol_cv_have_sys_errlist=yes
16270 else
16271   echo "$as_me: failed program was:" >&5
16272 sed 's/^/| /' conftest.$ac_ext >&5
16273
16274 ol_cv_dcl_sys_errlist=no
16275 fi
16276 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16277 fi
16278 echo "$as_me:$LINENO: result: $ol_cv_dcl_sys_errlist" >&5
16279 echo "${ECHO_T}$ol_cv_dcl_sys_errlist" >&6
16280 #
16281 # It's possible (for near-UNIX clones) that sys_errlist doesn't exist
16282 if test $ol_cv_dcl_sys_errlist = no ; then
16283
16284 cat >>confdefs.h <<\_ACEOF
16285 #define DECL_SYS_ERRLIST 1
16286 _ACEOF
16287
16288
16289         echo "$as_me:$LINENO: checking existence of sys_errlist" >&5
16290 echo $ECHO_N "checking existence of sys_errlist... $ECHO_C" >&6
16291 if test "${ol_cv_have_sys_errlist+set}" = set; then
16292   echo $ECHO_N "(cached) $ECHO_C" >&6
16293 else
16294
16295                 cat >conftest.$ac_ext <<_ACEOF
16296 /* confdefs.h.  */
16297 _ACEOF
16298 cat confdefs.h >>conftest.$ac_ext
16299 cat >>conftest.$ac_ext <<_ACEOF
16300 /* end confdefs.h.  */
16301 #include <errno.h>
16302 int
16303 main ()
16304 {
16305 char *c = (char *) *sys_errlist
16306   ;
16307   return 0;
16308 }
16309 _ACEOF
16310 rm -f conftest.$ac_objext conftest$ac_exeext
16311 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16312   (eval $ac_link) 2>conftest.er1
16313   ac_status=$?
16314   grep -v '^ *+' conftest.er1 >conftest.err
16315   rm -f conftest.er1
16316   cat conftest.err >&5
16317   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16318   (exit $ac_status); } &&
16319          { ac_try='test -z "$ac_c_werror_flag"
16320                          || test ! -s conftest.err'
16321   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16322   (eval $ac_try) 2>&5
16323   ac_status=$?
16324   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16325   (exit $ac_status); }; } &&
16326          { ac_try='test -s conftest$ac_exeext'
16327   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16328   (eval $ac_try) 2>&5
16329   ac_status=$?
16330   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16331   (exit $ac_status); }; }; then
16332   ol_cv_have_sys_errlist=yes
16333 else
16334   echo "$as_me: failed program was:" >&5
16335 sed 's/^/| /' conftest.$ac_ext >&5
16336
16337 ol_cv_have_sys_errlist=no
16338 fi
16339 rm -f conftest.err conftest.$ac_objext \
16340       conftest$ac_exeext conftest.$ac_ext
16341 fi
16342 echo "$as_me:$LINENO: result: $ol_cv_have_sys_errlist" >&5
16343 echo "${ECHO_T}$ol_cv_have_sys_errlist" >&6
16344 fi
16345 if test $ol_cv_have_sys_errlist = yes ; then
16346
16347 cat >>confdefs.h <<\_ACEOF
16348 #define HAVE_SYS_ERRLIST 1
16349 _ACEOF
16350
16351 fi
16352
16353
16354 for ac_func in strerror strerror_r
16355 do
16356 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16357 echo "$as_me:$LINENO: checking for $ac_func" >&5
16358 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16359 if eval "test \"\${$as_ac_var+set}\" = set"; then
16360   echo $ECHO_N "(cached) $ECHO_C" >&6
16361 else
16362   cat >conftest.$ac_ext <<_ACEOF
16363 /* confdefs.h.  */
16364 _ACEOF
16365 cat confdefs.h >>conftest.$ac_ext
16366 cat >>conftest.$ac_ext <<_ACEOF
16367 /* end confdefs.h.  */
16368 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16369    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16370 #define $ac_func innocuous_$ac_func
16371
16372 /* System header to define __stub macros and hopefully few prototypes,
16373     which can conflict with char $ac_func (); below.
16374     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16375     <limits.h> exists even on freestanding compilers.  */
16376
16377 #ifdef __STDC__
16378 # include <limits.h>
16379 #else
16380 # include <assert.h>
16381 #endif
16382
16383 #undef $ac_func
16384
16385 /* Override any gcc2 internal prototype to avoid an error.  */
16386 #ifdef __cplusplus
16387 extern "C"
16388 {
16389 #endif
16390 /* We use char because int might match the return type of a gcc2
16391    builtin and then its argument prototype would still apply.  */
16392 char $ac_func ();
16393 /* The GNU C library defines this for functions which it implements
16394     to always fail with ENOSYS.  Some functions are actually named
16395     something starting with __ and the normal name is an alias.  */
16396 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16397 choke me
16398 #else
16399 char (*f) () = $ac_func;
16400 #endif
16401 #ifdef __cplusplus
16402 }
16403 #endif
16404
16405 int
16406 main ()
16407 {
16408 return f != $ac_func;
16409   ;
16410   return 0;
16411 }
16412 _ACEOF
16413 rm -f conftest.$ac_objext conftest$ac_exeext
16414 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16415   (eval $ac_link) 2>conftest.er1
16416   ac_status=$?
16417   grep -v '^ *+' conftest.er1 >conftest.err
16418   rm -f conftest.er1
16419   cat conftest.err >&5
16420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16421   (exit $ac_status); } &&
16422          { ac_try='test -z "$ac_c_werror_flag"
16423                          || test ! -s conftest.err'
16424   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16425   (eval $ac_try) 2>&5
16426   ac_status=$?
16427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16428   (exit $ac_status); }; } &&
16429          { ac_try='test -s conftest$ac_exeext'
16430   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16431   (eval $ac_try) 2>&5
16432   ac_status=$?
16433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16434   (exit $ac_status); }; }; then
16435   eval "$as_ac_var=yes"
16436 else
16437   echo "$as_me: failed program was:" >&5
16438 sed 's/^/| /' conftest.$ac_ext >&5
16439
16440 eval "$as_ac_var=no"
16441 fi
16442 rm -f conftest.err conftest.$ac_objext \
16443       conftest$ac_exeext conftest.$ac_ext
16444 fi
16445 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16446 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16447 if test `eval echo '${'$as_ac_var'}'` = yes; then
16448   cat >>confdefs.h <<_ACEOF
16449 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16450 _ACEOF
16451
16452 fi
16453 done
16454
16455 ol_cv_func_strerror_r=no
16456 if test "${ac_cv_func_strerror_r}" = yes ; then
16457         echo "$as_me:$LINENO: checking non-posix strerror_r" >&5
16458 echo $ECHO_N "checking non-posix strerror_r... $ECHO_C" >&6
16459 if test "${ol_cv_nonposix_strerror_r+set}" = set; then
16460   echo $ECHO_N "(cached) $ECHO_C" >&6
16461 else
16462
16463         cat >conftest.$ac_ext <<_ACEOF
16464 /* confdefs.h.  */
16465 _ACEOF
16466 cat confdefs.h >>conftest.$ac_ext
16467 cat >>conftest.$ac_ext <<_ACEOF
16468 /* end confdefs.h.  */
16469 #include <string.h>
16470 _ACEOF
16471 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16472   $EGREP "strerror_r" >/dev/null 2>&1; then
16473   ol_decl_strerror_r=yes
16474 else
16475   ol_decl_strerror_r=no
16476 fi
16477 rm -f conftest*
16478
16479         if test $ol_decl_strerror_r = yes ; then
16480                 cat >conftest.$ac_ext <<_ACEOF
16481 /* confdefs.h.  */
16482 _ACEOF
16483 cat confdefs.h >>conftest.$ac_ext
16484 cat >>conftest.$ac_ext <<_ACEOF
16485 /* end confdefs.h.  */
16486 #include <string.h>
16487 int
16488 main ()
16489 {
16490    /* from autoconf 2.59 */
16491                                 char buf[100];
16492                                 char x = *strerror_r (0, buf, sizeof buf);
16493                                 char *p = strerror_r (0, buf, sizeof buf);
16494
16495   ;
16496   return 0;
16497 }
16498 _ACEOF
16499 rm -f conftest.$ac_objext
16500 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16501   (eval $ac_compile) 2>conftest.er1
16502   ac_status=$?
16503   grep -v '^ *+' conftest.er1 >conftest.err
16504   rm -f conftest.er1
16505   cat conftest.err >&5
16506   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16507   (exit $ac_status); } &&
16508          { ac_try='test -z "$ac_c_werror_flag"
16509                          || test ! -s conftest.err'
16510   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16511   (eval $ac_try) 2>&5
16512   ac_status=$?
16513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16514   (exit $ac_status); }; } &&
16515          { ac_try='test -s conftest.$ac_objext'
16516   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16517   (eval $ac_try) 2>&5
16518   ac_status=$?
16519   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16520   (exit $ac_status); }; }; then
16521   ol_cv_nonposix_strerror_r=yes
16522 else
16523   echo "$as_me: failed program was:" >&5
16524 sed 's/^/| /' conftest.$ac_ext >&5
16525
16526 ol_cv_nonposix_strerror_r=no
16527 fi
16528 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16529         else
16530                 if test "$cross_compiling" = yes; then
16531   ol_cv_nonposix_strerror=no
16532 else
16533   cat >conftest.$ac_ext <<_ACEOF
16534 /* confdefs.h.  */
16535 _ACEOF
16536 cat confdefs.h >>conftest.$ac_ext
16537 cat >>conftest.$ac_ext <<_ACEOF
16538 /* end confdefs.h.  */
16539
16540                         main() {
16541                                 char buf[100];
16542                                 buf[0] = 0;
16543                                 strerror_r( 1, buf, sizeof buf );
16544                                 exit( buf[0] == 0 );
16545                         }
16546
16547 _ACEOF
16548 rm -f conftest$ac_exeext
16549 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16550   (eval $ac_link) 2>&5
16551   ac_status=$?
16552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16553   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16554   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16555   (eval $ac_try) 2>&5
16556   ac_status=$?
16557   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16558   (exit $ac_status); }; }; then
16559   ol_cv_nonposix_strerror_r=yes
16560 else
16561   echo "$as_me: program exited with status $ac_status" >&5
16562 echo "$as_me: failed program was:" >&5
16563 sed 's/^/| /' conftest.$ac_ext >&5
16564
16565 ( exit $ac_status )
16566 ol_cv_nonposix_strerror=no
16567 fi
16568 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16569 fi
16570         fi
16571
16572 fi
16573 echo "$as_me:$LINENO: result: $ol_cv_nonposix_strerror_r" >&5
16574 echo "${ECHO_T}$ol_cv_nonposix_strerror_r" >&6
16575 if test $ol_cv_nonposix_strerror_r = yes ; then
16576
16577 cat >>confdefs.h <<\_ACEOF
16578 #define HAVE_NONPOSIX_STRERROR_R 1
16579 _ACEOF
16580
16581 fi
16582
16583 elif test "${ac_cv_func_strerror}" = no ; then
16584         echo "$as_me:$LINENO: checking declaration of sys_errlist" >&5
16585 echo $ECHO_N "checking declaration of sys_errlist... $ECHO_C" >&6
16586 if test "${ol_cv_dcl_sys_errlist+set}" = set; then
16587   echo $ECHO_N "(cached) $ECHO_C" >&6
16588 else
16589
16590         cat >conftest.$ac_ext <<_ACEOF
16591 /* confdefs.h.  */
16592 _ACEOF
16593 cat confdefs.h >>conftest.$ac_ext
16594 cat >>conftest.$ac_ext <<_ACEOF
16595 /* end confdefs.h.  */
16596
16597 #include <stdio.h>
16598 #include <sys/types.h>
16599 #include <errno.h>
16600 #ifdef _WIN32
16601 #include <stdlib.h>
16602 #endif
16603 int
16604 main ()
16605 {
16606 char *c = (char *) *sys_errlist
16607   ;
16608   return 0;
16609 }
16610 _ACEOF
16611 rm -f conftest.$ac_objext
16612 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16613   (eval $ac_compile) 2>conftest.er1
16614   ac_status=$?
16615   grep -v '^ *+' conftest.er1 >conftest.err
16616   rm -f conftest.er1
16617   cat conftest.err >&5
16618   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16619   (exit $ac_status); } &&
16620          { ac_try='test -z "$ac_c_werror_flag"
16621                          || test ! -s conftest.err'
16622   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16623   (eval $ac_try) 2>&5
16624   ac_status=$?
16625   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16626   (exit $ac_status); }; } &&
16627          { ac_try='test -s conftest.$ac_objext'
16628   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16629   (eval $ac_try) 2>&5
16630   ac_status=$?
16631   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16632   (exit $ac_status); }; }; then
16633   ol_cv_dcl_sys_errlist=yes
16634         ol_cv_have_sys_errlist=yes
16635 else
16636   echo "$as_me: failed program was:" >&5
16637 sed 's/^/| /' conftest.$ac_ext >&5
16638
16639 ol_cv_dcl_sys_errlist=no
16640 fi
16641 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16642 fi
16643 echo "$as_me:$LINENO: result: $ol_cv_dcl_sys_errlist" >&5
16644 echo "${ECHO_T}$ol_cv_dcl_sys_errlist" >&6
16645 #
16646 # It's possible (for near-UNIX clones) that sys_errlist doesn't exist
16647 if test $ol_cv_dcl_sys_errlist = no ; then
16648
16649 cat >>confdefs.h <<\_ACEOF
16650 #define DECL_SYS_ERRLIST 1
16651 _ACEOF
16652
16653
16654         echo "$as_me:$LINENO: checking existence of sys_errlist" >&5
16655 echo $ECHO_N "checking existence of sys_errlist... $ECHO_C" >&6
16656 if test "${ol_cv_have_sys_errlist+set}" = set; then
16657   echo $ECHO_N "(cached) $ECHO_C" >&6
16658 else
16659
16660                 cat >conftest.$ac_ext <<_ACEOF
16661 /* confdefs.h.  */
16662 _ACEOF
16663 cat confdefs.h >>conftest.$ac_ext
16664 cat >>conftest.$ac_ext <<_ACEOF
16665 /* end confdefs.h.  */
16666 #include <errno.h>
16667 int
16668 main ()
16669 {
16670 char *c = (char *) *sys_errlist
16671   ;
16672   return 0;
16673 }
16674 _ACEOF
16675 rm -f conftest.$ac_objext conftest$ac_exeext
16676 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16677   (eval $ac_link) 2>conftest.er1
16678   ac_status=$?
16679   grep -v '^ *+' conftest.er1 >conftest.err
16680   rm -f conftest.er1
16681   cat conftest.err >&5
16682   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16683   (exit $ac_status); } &&
16684          { ac_try='test -z "$ac_c_werror_flag"
16685                          || test ! -s conftest.err'
16686   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16687   (eval $ac_try) 2>&5
16688   ac_status=$?
16689   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16690   (exit $ac_status); }; } &&
16691          { ac_try='test -s conftest$ac_exeext'
16692   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16693   (eval $ac_try) 2>&5
16694   ac_status=$?
16695   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16696   (exit $ac_status); }; }; then
16697   ol_cv_have_sys_errlist=yes
16698 else
16699   echo "$as_me: failed program was:" >&5
16700 sed 's/^/| /' conftest.$ac_ext >&5
16701
16702 ol_cv_have_sys_errlist=no
16703 fi
16704 rm -f conftest.err conftest.$ac_objext \
16705       conftest$ac_exeext conftest.$ac_ext
16706 fi
16707 echo "$as_me:$LINENO: result: $ol_cv_have_sys_errlist" >&5
16708 echo "${ECHO_T}$ol_cv_have_sys_errlist" >&6
16709 fi
16710 if test $ol_cv_have_sys_errlist = yes ; then
16711
16712 cat >>confdefs.h <<\_ACEOF
16713 #define HAVE_SYS_ERRLIST 1
16714 _ACEOF
16715
16716 fi
16717
16718 fi
16719
16720
16721
16722 for ac_header in regex.h
16723 do
16724 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16725 echo "$as_me:$LINENO: checking for $ac_header" >&5
16726 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16727 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16728   echo $ECHO_N "(cached) $ECHO_C" >&6
16729 else
16730   cat >conftest.$ac_ext <<_ACEOF
16731 /* confdefs.h.  */
16732 _ACEOF
16733 cat confdefs.h >>conftest.$ac_ext
16734 cat >>conftest.$ac_ext <<_ACEOF
16735 /* end confdefs.h.  */
16736 $ac_includes_default
16737 #ifdef HAVE_SYS_TYPES_H
16738 #include <sys/types.h>
16739 #endif
16740
16741
16742 #include <$ac_header>
16743 _ACEOF
16744 rm -f conftest.$ac_objext
16745 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16746   (eval $ac_compile) 2>conftest.er1
16747   ac_status=$?
16748   grep -v '^ *+' conftest.er1 >conftest.err
16749   rm -f conftest.er1
16750   cat conftest.err >&5
16751   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16752   (exit $ac_status); } &&
16753          { ac_try='test -z "$ac_c_werror_flag"
16754                          || test ! -s conftest.err'
16755   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16756   (eval $ac_try) 2>&5
16757   ac_status=$?
16758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16759   (exit $ac_status); }; } &&
16760          { ac_try='test -s conftest.$ac_objext'
16761   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16762   (eval $ac_try) 2>&5
16763   ac_status=$?
16764   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16765   (exit $ac_status); }; }; then
16766   eval "$as_ac_Header=yes"
16767 else
16768   echo "$as_me: failed program was:" >&5
16769 sed 's/^/| /' conftest.$ac_ext >&5
16770
16771 eval "$as_ac_Header=no"
16772 fi
16773 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16774 fi
16775 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16776 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16777 if test `eval echo '${'$as_ac_Header'}'` = yes; then
16778   cat >>confdefs.h <<_ACEOF
16779 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16780 _ACEOF
16781
16782 fi
16783
16784 done
16785
16786
16787 if test "$ac_cv_header_regex_h" != yes ; then
16788         { { echo "$as_me:$LINENO: error: POSIX regex.h required." >&5
16789 echo "$as_me: error: POSIX regex.h required." >&2;}
16790    { (exit 1); exit 1; }; }
16791 fi
16792 echo "$as_me:$LINENO: checking for library containing regfree" >&5
16793 echo $ECHO_N "checking for library containing regfree... $ECHO_C" >&6
16794 if test "${ac_cv_search_regfree+set}" = set; then
16795   echo $ECHO_N "(cached) $ECHO_C" >&6
16796 else
16797   ac_func_search_save_LIBS=$LIBS
16798 ac_cv_search_regfree=no
16799 cat >conftest.$ac_ext <<_ACEOF
16800 /* confdefs.h.  */
16801 _ACEOF
16802 cat confdefs.h >>conftest.$ac_ext
16803 cat >>conftest.$ac_ext <<_ACEOF
16804 /* end confdefs.h.  */
16805
16806 /* Override any gcc2 internal prototype to avoid an error.  */
16807 #ifdef __cplusplus
16808 extern "C"
16809 #endif
16810 /* We use char because int might match the return type of a gcc2
16811    builtin and then its argument prototype would still apply.  */
16812 char regfree ();
16813 int
16814 main ()
16815 {
16816 regfree ();
16817   ;
16818   return 0;
16819 }
16820 _ACEOF
16821 rm -f conftest.$ac_objext conftest$ac_exeext
16822 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16823   (eval $ac_link) 2>conftest.er1
16824   ac_status=$?
16825   grep -v '^ *+' conftest.er1 >conftest.err
16826   rm -f conftest.er1
16827   cat conftest.err >&5
16828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16829   (exit $ac_status); } &&
16830          { ac_try='test -z "$ac_c_werror_flag"
16831                          || test ! -s conftest.err'
16832   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16833   (eval $ac_try) 2>&5
16834   ac_status=$?
16835   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16836   (exit $ac_status); }; } &&
16837          { ac_try='test -s conftest$ac_exeext'
16838   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16839   (eval $ac_try) 2>&5
16840   ac_status=$?
16841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16842   (exit $ac_status); }; }; then
16843   ac_cv_search_regfree="none required"
16844 else
16845   echo "$as_me: failed program was:" >&5
16846 sed 's/^/| /' conftest.$ac_ext >&5
16847
16848 fi
16849 rm -f conftest.err conftest.$ac_objext \
16850       conftest$ac_exeext conftest.$ac_ext
16851 if test "$ac_cv_search_regfree" = no; then
16852   for ac_lib in regex gnuregex; do
16853     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
16854     cat >conftest.$ac_ext <<_ACEOF
16855 /* confdefs.h.  */
16856 _ACEOF
16857 cat confdefs.h >>conftest.$ac_ext
16858 cat >>conftest.$ac_ext <<_ACEOF
16859 /* end confdefs.h.  */
16860
16861 /* Override any gcc2 internal prototype to avoid an error.  */
16862 #ifdef __cplusplus
16863 extern "C"
16864 #endif
16865 /* We use char because int might match the return type of a gcc2
16866    builtin and then its argument prototype would still apply.  */
16867 char regfree ();
16868 int
16869 main ()
16870 {
16871 regfree ();
16872   ;
16873   return 0;
16874 }
16875 _ACEOF
16876 rm -f conftest.$ac_objext conftest$ac_exeext
16877 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16878   (eval $ac_link) 2>conftest.er1
16879   ac_status=$?
16880   grep -v '^ *+' conftest.er1 >conftest.err
16881   rm -f conftest.er1
16882   cat conftest.err >&5
16883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16884   (exit $ac_status); } &&
16885          { ac_try='test -z "$ac_c_werror_flag"
16886                          || test ! -s conftest.err'
16887   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16888   (eval $ac_try) 2>&5
16889   ac_status=$?
16890   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16891   (exit $ac_status); }; } &&
16892          { ac_try='test -s conftest$ac_exeext'
16893   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16894   (eval $ac_try) 2>&5
16895   ac_status=$?
16896   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16897   (exit $ac_status); }; }; then
16898   ac_cv_search_regfree="-l$ac_lib"
16899 break
16900 else
16901   echo "$as_me: failed program was:" >&5
16902 sed 's/^/| /' conftest.$ac_ext >&5
16903
16904 fi
16905 rm -f conftest.err conftest.$ac_objext \
16906       conftest$ac_exeext conftest.$ac_ext
16907   done
16908 fi
16909 LIBS=$ac_func_search_save_LIBS
16910 fi
16911 echo "$as_me:$LINENO: result: $ac_cv_search_regfree" >&5
16912 echo "${ECHO_T}$ac_cv_search_regfree" >&6
16913 if test "$ac_cv_search_regfree" != no; then
16914   test "$ac_cv_search_regfree" = "none required" || LIBS="$ac_cv_search_regfree $LIBS"
16915   :
16916 else
16917   { { echo "$as_me:$LINENO: error: POSIX regex required." >&5
16918 echo "$as_me: error: POSIX regex required." >&2;}
16919    { (exit 1); exit 1; }; }
16920 fi
16921
16922
16923
16924 echo "$as_me:$LINENO: checking for compatible POSIX regex" >&5
16925 echo $ECHO_N "checking for compatible POSIX regex... $ECHO_C" >&6
16926 if test "${ol_cv_c_posix_regex+set}" = set; then
16927   echo $ECHO_N "(cached) $ECHO_C" >&6
16928 else
16929
16930         if test "$cross_compiling" = yes; then
16931   ol_cv_c_posix_regex=cross
16932 else
16933   cat >conftest.$ac_ext <<_ACEOF
16934 /* confdefs.h.  */
16935 _ACEOF
16936 cat confdefs.h >>conftest.$ac_ext
16937 cat >>conftest.$ac_ext <<_ACEOF
16938 /* end confdefs.h.  */
16939
16940 #include <sys/types.h>
16941 #include <regex.h>
16942 static char *pattern, *string;
16943 main()
16944 {
16945         int rc;
16946         regex_t re;
16947
16948         pattern = "^A";
16949
16950         if(regcomp(&re, pattern, 0)) {
16951                 return -1;
16952         }
16953
16954         string = "ALL MATCH";
16955
16956         rc = regexec(&re, string, 0, (void*)0, 0);
16957
16958         regfree(&re);
16959
16960         return rc;
16961 }
16962 _ACEOF
16963 rm -f conftest$ac_exeext
16964 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16965   (eval $ac_link) 2>&5
16966   ac_status=$?
16967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16968   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16969   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16970   (eval $ac_try) 2>&5
16971   ac_status=$?
16972   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16973   (exit $ac_status); }; }; then
16974   ol_cv_c_posix_regex=yes
16975 else
16976   echo "$as_me: program exited with status $ac_status" >&5
16977 echo "$as_me: failed program was:" >&5
16978 sed 's/^/| /' conftest.$ac_ext >&5
16979
16980 ( exit $ac_status )
16981 ol_cv_c_posix_regex=no
16982 fi
16983 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16984 fi
16985 fi
16986 echo "$as_me:$LINENO: result: $ol_cv_c_posix_regex" >&5
16987 echo "${ECHO_T}$ol_cv_c_posix_regex" >&6
16988
16989 if test "$ol_cv_c_posix_regex" = no ; then
16990         { { echo "$as_me:$LINENO: error: broken POSIX regex!" >&5
16991 echo "$as_me: error: broken POSIX regex!" >&2;}
16992    { (exit 1); exit 1; }; }
16993 fi
16994
16995
16996 have_uuid=no
16997
16998 for ac_header in sys/uuid.h
16999 do
17000 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17001 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17002   echo "$as_me:$LINENO: checking for $ac_header" >&5
17003 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17004 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17005   echo $ECHO_N "(cached) $ECHO_C" >&6
17006 fi
17007 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17008 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17009 else
17010   # Is the header compilable?
17011 echo "$as_me:$LINENO: checking $ac_header usability" >&5
17012 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17013 cat >conftest.$ac_ext <<_ACEOF
17014 /* confdefs.h.  */
17015 _ACEOF
17016 cat confdefs.h >>conftest.$ac_ext
17017 cat >>conftest.$ac_ext <<_ACEOF
17018 /* end confdefs.h.  */
17019 $ac_includes_default
17020 #include <$ac_header>
17021 _ACEOF
17022 rm -f conftest.$ac_objext
17023 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17024   (eval $ac_compile) 2>conftest.er1
17025   ac_status=$?
17026   grep -v '^ *+' conftest.er1 >conftest.err
17027   rm -f conftest.er1
17028   cat conftest.err >&5
17029   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17030   (exit $ac_status); } &&
17031          { ac_try='test -z "$ac_c_werror_flag"
17032                          || test ! -s conftest.err'
17033   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17034   (eval $ac_try) 2>&5
17035   ac_status=$?
17036   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17037   (exit $ac_status); }; } &&
17038          { ac_try='test -s conftest.$ac_objext'
17039   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17040   (eval $ac_try) 2>&5
17041   ac_status=$?
17042   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17043   (exit $ac_status); }; }; then
17044   ac_header_compiler=yes
17045 else
17046   echo "$as_me: failed program was:" >&5
17047 sed 's/^/| /' conftest.$ac_ext >&5
17048
17049 ac_header_compiler=no
17050 fi
17051 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17052 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17053 echo "${ECHO_T}$ac_header_compiler" >&6
17054
17055 # Is the header present?
17056 echo "$as_me:$LINENO: checking $ac_header presence" >&5
17057 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17058 cat >conftest.$ac_ext <<_ACEOF
17059 /* confdefs.h.  */
17060 _ACEOF
17061 cat confdefs.h >>conftest.$ac_ext
17062 cat >>conftest.$ac_ext <<_ACEOF
17063 /* end confdefs.h.  */
17064 #include <$ac_header>
17065 _ACEOF
17066 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
17067   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17068   ac_status=$?
17069   grep -v '^ *+' conftest.er1 >conftest.err
17070   rm -f conftest.er1
17071   cat conftest.err >&5
17072   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17073   (exit $ac_status); } >/dev/null; then
17074   if test -s conftest.err; then
17075     ac_cpp_err=$ac_c_preproc_warn_flag
17076     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
17077   else
17078     ac_cpp_err=
17079   fi
17080 else
17081   ac_cpp_err=yes
17082 fi
17083 if test -z "$ac_cpp_err"; then
17084   ac_header_preproc=yes
17085 else
17086   echo "$as_me: failed program was:" >&5
17087 sed 's/^/| /' conftest.$ac_ext >&5
17088
17089   ac_header_preproc=no
17090 fi
17091 rm -f conftest.err conftest.$ac_ext
17092 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17093 echo "${ECHO_T}$ac_header_preproc" >&6
17094
17095 # So?  What about this header?
17096 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17097   yes:no: )
17098     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17099 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17100     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
17101 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
17102     ac_header_preproc=yes
17103     ;;
17104   no:yes:* )
17105     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17106 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17107     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
17108 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
17109     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
17110 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
17111     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
17112 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
17113     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17114 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17115     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
17116 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
17117     (
17118       cat <<\_ASBOX
17119 ## --------------------------------------------- ##
17120 ## Report this to <http://www.openldap.org/its/> ##
17121 ## --------------------------------------------- ##
17122 _ASBOX
17123     ) |
17124       sed "s/^/$as_me: WARNING:     /" >&2
17125     ;;
17126 esac
17127 echo "$as_me:$LINENO: checking for $ac_header" >&5
17128 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17129 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17130   echo $ECHO_N "(cached) $ECHO_C" >&6
17131 else
17132   eval "$as_ac_Header=\$ac_header_preproc"
17133 fi
17134 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17135 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17136
17137 fi
17138 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17139   cat >>confdefs.h <<_ACEOF
17140 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17141 _ACEOF
17142
17143 fi
17144
17145 done
17146
17147 if test $ac_cv_header_sys_uuid_h = yes ; then
17148         save_LIBS="$LIBS"
17149         echo "$as_me:$LINENO: checking for library containing uuid_to_str" >&5
17150 echo $ECHO_N "checking for library containing uuid_to_str... $ECHO_C" >&6
17151 if test "${ac_cv_search_uuid_to_str+set}" = set; then
17152   echo $ECHO_N "(cached) $ECHO_C" >&6
17153 else
17154   ac_func_search_save_LIBS=$LIBS
17155 ac_cv_search_uuid_to_str=no
17156 cat >conftest.$ac_ext <<_ACEOF
17157 /* confdefs.h.  */
17158 _ACEOF
17159 cat confdefs.h >>conftest.$ac_ext
17160 cat >>conftest.$ac_ext <<_ACEOF
17161 /* end confdefs.h.  */
17162
17163 /* Override any gcc2 internal prototype to avoid an error.  */
17164 #ifdef __cplusplus
17165 extern "C"
17166 #endif
17167 /* We use char because int might match the return type of a gcc2
17168    builtin and then its argument prototype would still apply.  */
17169 char uuid_to_str ();
17170 int
17171 main ()
17172 {
17173 uuid_to_str ();
17174   ;
17175   return 0;
17176 }
17177 _ACEOF
17178 rm -f conftest.$ac_objext conftest$ac_exeext
17179 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17180   (eval $ac_link) 2>conftest.er1
17181   ac_status=$?
17182   grep -v '^ *+' conftest.er1 >conftest.err
17183   rm -f conftest.er1
17184   cat conftest.err >&5
17185   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17186   (exit $ac_status); } &&
17187          { ac_try='test -z "$ac_c_werror_flag"
17188                          || test ! -s conftest.err'
17189   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17190   (eval $ac_try) 2>&5
17191   ac_status=$?
17192   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17193   (exit $ac_status); }; } &&
17194          { ac_try='test -s conftest$ac_exeext'
17195   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17196   (eval $ac_try) 2>&5
17197   ac_status=$?
17198   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17199   (exit $ac_status); }; }; then
17200   ac_cv_search_uuid_to_str="none required"
17201 else
17202   echo "$as_me: failed program was:" >&5
17203 sed 's/^/| /' conftest.$ac_ext >&5
17204
17205 fi
17206 rm -f conftest.err conftest.$ac_objext \
17207       conftest$ac_exeext conftest.$ac_ext
17208 if test "$ac_cv_search_uuid_to_str" = no; then
17209   for ac_lib in uuid; do
17210     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17211     cat >conftest.$ac_ext <<_ACEOF
17212 /* confdefs.h.  */
17213 _ACEOF
17214 cat confdefs.h >>conftest.$ac_ext
17215 cat >>conftest.$ac_ext <<_ACEOF
17216 /* end confdefs.h.  */
17217
17218 /* Override any gcc2 internal prototype to avoid an error.  */
17219 #ifdef __cplusplus
17220 extern "C"
17221 #endif
17222 /* We use char because int might match the return type of a gcc2
17223    builtin and then its argument prototype would still apply.  */
17224 char uuid_to_str ();
17225 int
17226 main ()
17227 {
17228 uuid_to_str ();
17229   ;
17230   return 0;
17231 }
17232 _ACEOF
17233 rm -f conftest.$ac_objext conftest$ac_exeext
17234 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17235   (eval $ac_link) 2>conftest.er1
17236   ac_status=$?
17237   grep -v '^ *+' conftest.er1 >conftest.err
17238   rm -f conftest.er1
17239   cat conftest.err >&5
17240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17241   (exit $ac_status); } &&
17242          { ac_try='test -z "$ac_c_werror_flag"
17243                          || test ! -s conftest.err'
17244   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17245   (eval $ac_try) 2>&5
17246   ac_status=$?
17247   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17248   (exit $ac_status); }; } &&
17249          { ac_try='test -s conftest$ac_exeext'
17250   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17251   (eval $ac_try) 2>&5
17252   ac_status=$?
17253   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17254   (exit $ac_status); }; }; then
17255   ac_cv_search_uuid_to_str="-l$ac_lib"
17256 break
17257 else
17258   echo "$as_me: failed program was:" >&5
17259 sed 's/^/| /' conftest.$ac_ext >&5
17260
17261 fi
17262 rm -f conftest.err conftest.$ac_objext \
17263       conftest$ac_exeext conftest.$ac_ext
17264   done
17265 fi
17266 LIBS=$ac_func_search_save_LIBS
17267 fi
17268 echo "$as_me:$LINENO: result: $ac_cv_search_uuid_to_str" >&5
17269 echo "${ECHO_T}$ac_cv_search_uuid_to_str" >&6
17270 if test "$ac_cv_search_uuid_to_str" != no; then
17271   test "$ac_cv_search_uuid_to_str" = "none required" || LIBS="$ac_cv_search_uuid_to_str $LIBS"
17272   have_uuid=yes
17273 else
17274   :
17275 fi
17276
17277         LIBS="$save_LIBS"
17278
17279         if test have_uuid = yes ; then
17280
17281 cat >>confdefs.h <<\_ACEOF
17282 #define HAVE_UUID_TO_STR 1
17283 _ACEOF
17284
17285
17286                 test "$ac_cv_search_uuid_to_str" = "none required" || \
17287                         SLAPD_LIBS="$SLAPD_LIBS $ac_cv_search_uuid_to_str"
17288         fi
17289 fi
17290
17291 if test $have_uuid = no ; then
17292
17293 for ac_header in uuid/uuid.h
17294 do
17295 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17296 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17297   echo "$as_me:$LINENO: checking for $ac_header" >&5
17298 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17299 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17300   echo $ECHO_N "(cached) $ECHO_C" >&6
17301 fi
17302 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17303 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17304 else
17305   # Is the header compilable?
17306 echo "$as_me:$LINENO: checking $ac_header usability" >&5
17307 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17308 cat >conftest.$ac_ext <<_ACEOF
17309 /* confdefs.h.  */
17310 _ACEOF
17311 cat confdefs.h >>conftest.$ac_ext
17312 cat >>conftest.$ac_ext <<_ACEOF
17313 /* end confdefs.h.  */
17314 $ac_includes_default
17315 #include <$ac_header>
17316 _ACEOF
17317 rm -f conftest.$ac_objext
17318 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17319   (eval $ac_compile) 2>conftest.er1
17320   ac_status=$?
17321   grep -v '^ *+' conftest.er1 >conftest.err
17322   rm -f conftest.er1
17323   cat conftest.err >&5
17324   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17325   (exit $ac_status); } &&
17326          { ac_try='test -z "$ac_c_werror_flag"
17327                          || test ! -s conftest.err'
17328   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17329   (eval $ac_try) 2>&5
17330   ac_status=$?
17331   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17332   (exit $ac_status); }; } &&
17333          { ac_try='test -s conftest.$ac_objext'
17334   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17335   (eval $ac_try) 2>&5
17336   ac_status=$?
17337   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17338   (exit $ac_status); }; }; then
17339   ac_header_compiler=yes
17340 else
17341   echo "$as_me: failed program was:" >&5
17342 sed 's/^/| /' conftest.$ac_ext >&5
17343
17344 ac_header_compiler=no
17345 fi
17346 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17347 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17348 echo "${ECHO_T}$ac_header_compiler" >&6
17349
17350 # Is the header present?
17351 echo "$as_me:$LINENO: checking $ac_header presence" >&5
17352 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17353 cat >conftest.$ac_ext <<_ACEOF
17354 /* confdefs.h.  */
17355 _ACEOF
17356 cat confdefs.h >>conftest.$ac_ext
17357 cat >>conftest.$ac_ext <<_ACEOF
17358 /* end confdefs.h.  */
17359 #include <$ac_header>
17360 _ACEOF
17361 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
17362   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17363   ac_status=$?
17364   grep -v '^ *+' conftest.er1 >conftest.err
17365   rm -f conftest.er1
17366   cat conftest.err >&5
17367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17368   (exit $ac_status); } >/dev/null; then
17369   if test -s conftest.err; then
17370     ac_cpp_err=$ac_c_preproc_warn_flag
17371     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
17372   else
17373     ac_cpp_err=
17374   fi
17375 else
17376   ac_cpp_err=yes
17377 fi
17378 if test -z "$ac_cpp_err"; then
17379   ac_header_preproc=yes
17380 else
17381   echo "$as_me: failed program was:" >&5
17382 sed 's/^/| /' conftest.$ac_ext >&5
17383
17384   ac_header_preproc=no
17385 fi
17386 rm -f conftest.err conftest.$ac_ext
17387 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17388 echo "${ECHO_T}$ac_header_preproc" >&6
17389
17390 # So?  What about this header?
17391 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17392   yes:no: )
17393     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17394 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17395     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
17396 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
17397     ac_header_preproc=yes
17398     ;;
17399   no:yes:* )
17400     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17401 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17402     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
17403 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
17404     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
17405 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
17406     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
17407 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
17408     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17409 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17410     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
17411 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
17412     (
17413       cat <<\_ASBOX
17414 ## --------------------------------------------- ##
17415 ## Report this to <http://www.openldap.org/its/> ##
17416 ## --------------------------------------------- ##
17417 _ASBOX
17418     ) |
17419       sed "s/^/$as_me: WARNING:     /" >&2
17420     ;;
17421 esac
17422 echo "$as_me:$LINENO: checking for $ac_header" >&5
17423 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17424 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17425   echo $ECHO_N "(cached) $ECHO_C" >&6
17426 else
17427   eval "$as_ac_Header=\$ac_header_preproc"
17428 fi
17429 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17430 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17431
17432 fi
17433 if test `eval echo '${'$as_ac_Header'}'` = yes; then
17434   cat >>confdefs.h <<_ACEOF
17435 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17436 _ACEOF
17437
17438 fi
17439
17440 done
17441
17442         if test $ac_cv_header_uuid_uuid_h = yes ; then
17443                 save_LIBS="$LIBS"
17444                 echo "$as_me:$LINENO: checking for library containing uuid_generate" >&5
17445 echo $ECHO_N "checking for library containing uuid_generate... $ECHO_C" >&6
17446 if test "${ac_cv_search_uuid_generate+set}" = set; then
17447   echo $ECHO_N "(cached) $ECHO_C" >&6
17448 else
17449   ac_func_search_save_LIBS=$LIBS
17450 ac_cv_search_uuid_generate=no
17451 cat >conftest.$ac_ext <<_ACEOF
17452 /* confdefs.h.  */
17453 _ACEOF
17454 cat confdefs.h >>conftest.$ac_ext
17455 cat >>conftest.$ac_ext <<_ACEOF
17456 /* end confdefs.h.  */
17457
17458 /* Override any gcc2 internal prototype to avoid an error.  */
17459 #ifdef __cplusplus
17460 extern "C"
17461 #endif
17462 /* We use char because int might match the return type of a gcc2
17463    builtin and then its argument prototype would still apply.  */
17464 char uuid_generate ();
17465 int
17466 main ()
17467 {
17468 uuid_generate ();
17469   ;
17470   return 0;
17471 }
17472 _ACEOF
17473 rm -f conftest.$ac_objext conftest$ac_exeext
17474 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17475   (eval $ac_link) 2>conftest.er1
17476   ac_status=$?
17477   grep -v '^ *+' conftest.er1 >conftest.err
17478   rm -f conftest.er1
17479   cat conftest.err >&5
17480   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17481   (exit $ac_status); } &&
17482          { ac_try='test -z "$ac_c_werror_flag"
17483                          || test ! -s conftest.err'
17484   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17485   (eval $ac_try) 2>&5
17486   ac_status=$?
17487   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17488   (exit $ac_status); }; } &&
17489          { ac_try='test -s conftest$ac_exeext'
17490   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17491   (eval $ac_try) 2>&5
17492   ac_status=$?
17493   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17494   (exit $ac_status); }; }; then
17495   ac_cv_search_uuid_generate="none required"
17496 else
17497   echo "$as_me: failed program was:" >&5
17498 sed 's/^/| /' conftest.$ac_ext >&5
17499
17500 fi
17501 rm -f conftest.err conftest.$ac_objext \
17502       conftest$ac_exeext conftest.$ac_ext
17503 if test "$ac_cv_search_uuid_generate" = no; then
17504   for ac_lib in uuid; do
17505     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17506     cat >conftest.$ac_ext <<_ACEOF
17507 /* confdefs.h.  */
17508 _ACEOF
17509 cat confdefs.h >>conftest.$ac_ext
17510 cat >>conftest.$ac_ext <<_ACEOF
17511 /* end confdefs.h.  */
17512
17513 /* Override any gcc2 internal prototype to avoid an error.  */
17514 #ifdef __cplusplus
17515 extern "C"
17516 #endif
17517 /* We use char because int might match the return type of a gcc2
17518    builtin and then its argument prototype would still apply.  */
17519 char uuid_generate ();
17520 int
17521 main ()
17522 {
17523 uuid_generate ();
17524   ;
17525   return 0;
17526 }
17527 _ACEOF
17528 rm -f conftest.$ac_objext conftest$ac_exeext
17529 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17530   (eval $ac_link) 2>conftest.er1
17531   ac_status=$?
17532   grep -v '^ *+' conftest.er1 >conftest.err
17533   rm -f conftest.er1
17534   cat conftest.err >&5
17535   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17536   (exit $ac_status); } &&
17537          { ac_try='test -z "$ac_c_werror_flag"
17538                          || test ! -s conftest.err'
17539   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17540   (eval $ac_try) 2>&5
17541   ac_status=$?
17542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17543   (exit $ac_status); }; } &&
17544          { ac_try='test -s conftest$ac_exeext'
17545   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17546   (eval $ac_try) 2>&5
17547   ac_status=$?
17548   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17549   (exit $ac_status); }; }; then
17550   ac_cv_search_uuid_generate="-l$ac_lib"
17551 break
17552 else
17553   echo "$as_me: failed program was:" >&5
17554 sed 's/^/| /' conftest.$ac_ext >&5
17555
17556 fi
17557 rm -f conftest.err conftest.$ac_objext \
17558       conftest$ac_exeext conftest.$ac_ext
17559   done
17560 fi
17561 LIBS=$ac_func_search_save_LIBS
17562 fi
17563 echo "$as_me:$LINENO: result: $ac_cv_search_uuid_generate" >&5
17564 echo "${ECHO_T}$ac_cv_search_uuid_generate" >&6
17565 if test "$ac_cv_search_uuid_generate" != no; then
17566   test "$ac_cv_search_uuid_generate" = "none required" || LIBS="$ac_cv_search_uuid_generate $LIBS"
17567   have_uuid=yes
17568 else
17569   :
17570 fi
17571
17572                 LIBS="$save_LIBS"
17573
17574                 if test have_uuid = yes ; then
17575
17576 cat >>confdefs.h <<\_ACEOF
17577 #define HAVE_UUID_GENERATE 1
17578 _ACEOF
17579
17580
17581                         test "$ac_cv_search_uuid_generate" = "none required" || \
17582                                 SLAPD_LIBS="$SLAPD_LIBS $ac_cv_search_uuid_generate"
17583                 fi
17584         fi
17585 fi
17586
17587 if test $have_uuid = no ; then
17588         echo "$as_me:$LINENO: checking to see if -lrpcrt4 is needed for win32 UUID support" >&5
17589 echo $ECHO_N "checking to see if -lrpcrt4 is needed for win32 UUID support... $ECHO_C" >&6
17590         save_LIBS="$LIBS"
17591         LIBS="$LIBS -lrpcrt4"
17592         cat >conftest.$ac_ext <<_ACEOF
17593 /* confdefs.h.  */
17594 _ACEOF
17595 cat confdefs.h >>conftest.$ac_ext
17596 cat >>conftest.$ac_ext <<_ACEOF
17597 /* end confdefs.h.  */
17598
17599                 int __stdcall UuidCreate(void *);
17600                 int __stdcall UuidToStringA(void *,void **);
17601
17602 int
17603 main ()
17604 {
17605
17606                 UuidCreate(0);
17607                 UuidToStringA(0,0);
17608
17609   ;
17610   return 0;
17611 }
17612 _ACEOF
17613 rm -f conftest.$ac_objext conftest$ac_exeext
17614 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17615   (eval $ac_link) 2>conftest.er1
17616   ac_status=$?
17617   grep -v '^ *+' conftest.er1 >conftest.err
17618   rm -f conftest.er1
17619   cat conftest.err >&5
17620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17621   (exit $ac_status); } &&
17622          { ac_try='test -z "$ac_c_werror_flag"
17623                          || test ! -s conftest.err'
17624   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17625   (eval $ac_try) 2>&5
17626   ac_status=$?
17627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17628   (exit $ac_status); }; } &&
17629          { ac_try='test -s conftest$ac_exeext'
17630   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17631   (eval $ac_try) 2>&5
17632   ac_status=$?
17633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17634   (exit $ac_status); }; }; then
17635   need_rpcrt=yes
17636 else
17637   echo "$as_me: failed program was:" >&5
17638 sed 's/^/| /' conftest.$ac_ext >&5
17639
17640 need_rpcrt=no
17641 fi
17642 rm -f conftest.err conftest.$ac_objext \
17643       conftest$ac_exeext conftest.$ac_ext
17644         if test $need_rpcrt = yes; then
17645                 SLAPD_LIBS="$SLAPD_LIBS -lrpcrt4"
17646         fi
17647         LIBS="$save_LIBS"
17648         echo "$as_me:$LINENO: result: $need_rpcrt" >&5
17649 echo "${ECHO_T}$need_rpcrt" >&6
17650 fi
17651
17652 ol_cv_lib_resolver=no
17653 if test $ol_cv_lib_resolver = no ; then
17654         echo "$as_me:$LINENO: checking for resolver link (default)" >&5
17655 echo $ECHO_N "checking for resolver link (default)... $ECHO_C" >&6
17656 if test "${ol_cv_resolver_none+set}" = set; then
17657   echo $ECHO_N "(cached) $ECHO_C" >&6
17658 else
17659
17660         ol_RESOLVER_LIB=
17661         ol_LIBS=$LIBS
17662         LIBS="$ol_RESOLVER_LIB $LIBS"
17663
17664         cat >conftest.$ac_ext <<_ACEOF
17665 /* confdefs.h.  */
17666 _ACEOF
17667 cat confdefs.h >>conftest.$ac_ext
17668 cat >>conftest.$ac_ext <<_ACEOF
17669 /* end confdefs.h.  */
17670
17671 #ifdef HAVE_SYS_TYPES_H
17672 #       include <sys/types.h>
17673 #endif
17674 #include <netinet/in.h>
17675 #ifdef HAVE_ARPA_NAMESER_H
17676 #       include <arpa/nameser.h>
17677 #endif
17678 #ifdef HAVE_RESOLV_H
17679 #       include <resolv.h>
17680 #endif
17681
17682 int
17683 main ()
17684 {
17685 {
17686         int len, status;
17687         char *request = NULL;
17688         unsigned char reply[64*1024];
17689         unsigned char host[64*1024];
17690         unsigned char *p;
17691
17692 #ifdef NS_HFIXEDSZ
17693         /* Bind 8/9 interface */
17694         len = res_query(request, ns_c_in, ns_t_srv, reply, sizeof(reply));
17695 #else
17696         /* Bind 4 interface */
17697 # ifndef T_SRV
17698 #  define T_SRV 33
17699 # endif
17700         len = res_query(request, C_IN, T_SRV, reply, sizeof(reply));
17701 #endif
17702         p = reply;
17703 #ifdef NS_HFIXEDSZ
17704         /* Bind 8/9 interface */
17705         p += NS_HFIXEDSZ;
17706 #elif defined(HFIXEDSZ)
17707         /* Bind 4 interface w/ HFIXEDSZ */
17708         p += HFIXEDSZ;
17709 #else
17710         /* Bind 4 interface w/o HFIXEDSZ */
17711         p += sizeof(HEADER);
17712 #endif
17713         status = dn_expand( reply, reply+len, p, host, sizeof(host));
17714 }
17715   ;
17716   return 0;
17717 }
17718 _ACEOF
17719 rm -f conftest.$ac_objext conftest$ac_exeext
17720 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17721   (eval $ac_link) 2>conftest.er1
17722   ac_status=$?
17723   grep -v '^ *+' conftest.er1 >conftest.err
17724   rm -f conftest.er1
17725   cat conftest.err >&5
17726   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17727   (exit $ac_status); } &&
17728          { ac_try='test -z "$ac_c_werror_flag"
17729                          || test ! -s conftest.err'
17730   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17731   (eval $ac_try) 2>&5
17732   ac_status=$?
17733   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17734   (exit $ac_status); }; } &&
17735          { ac_try='test -s conftest$ac_exeext'
17736   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17737   (eval $ac_try) 2>&5
17738   ac_status=$?
17739   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17740   (exit $ac_status); }; }; then
17741   ol_cv_resolver_none=yes
17742 else
17743   echo "$as_me: failed program was:" >&5
17744 sed 's/^/| /' conftest.$ac_ext >&5
17745
17746 ol_cv_resolver_none=no
17747 fi
17748 rm -f conftest.err conftest.$ac_objext \
17749       conftest$ac_exeext conftest.$ac_ext
17750
17751         LIBS="$ol_LIBS"
17752
17753 fi
17754 echo "$as_me:$LINENO: result: $ol_cv_resolver_none" >&5
17755 echo "${ECHO_T}$ol_cv_resolver_none" >&6
17756
17757         if test $ol_cv_resolver_none = yes ; then
17758                 ol_cv_lib_resolver=yes
17759         fi
17760 fi
17761
17762 if test $ol_cv_lib_resolver = no ; then
17763         echo "$as_me:$LINENO: checking for resolver link (-lresolv)" >&5
17764 echo $ECHO_N "checking for resolver link (-lresolv)... $ECHO_C" >&6
17765 if test "${ol_cv_resolver_resolv+set}" = set; then
17766   echo $ECHO_N "(cached) $ECHO_C" >&6
17767 else
17768
17769         ol_RESOLVER_LIB=-lresolv
17770         ol_LIBS=$LIBS
17771         LIBS="$ol_RESOLVER_LIB $LIBS"
17772
17773         cat >conftest.$ac_ext <<_ACEOF
17774 /* confdefs.h.  */
17775 _ACEOF
17776 cat confdefs.h >>conftest.$ac_ext
17777 cat >>conftest.$ac_ext <<_ACEOF
17778 /* end confdefs.h.  */
17779
17780 #ifdef HAVE_SYS_TYPES_H
17781 #       include <sys/types.h>
17782 #endif
17783 #include <netinet/in.h>
17784 #ifdef HAVE_ARPA_NAMESER_H
17785 #       include <arpa/nameser.h>
17786 #endif
17787 #ifdef HAVE_RESOLV_H
17788 #       include <resolv.h>
17789 #endif
17790
17791 int
17792 main ()
17793 {
17794 {
17795         int len, status;
17796         char *request = NULL;
17797         unsigned char reply[64*1024];
17798         unsigned char host[64*1024];
17799         unsigned char *p;
17800
17801 #ifdef NS_HFIXEDSZ
17802         /* Bind 8/9 interface */
17803         len = res_query(request, ns_c_in, ns_t_srv, reply, sizeof(reply));
17804 #else
17805         /* Bind 4 interface */
17806 # ifndef T_SRV
17807 #  define T_SRV 33
17808 # endif
17809         len = res_query(request, C_IN, T_SRV, reply, sizeof(reply));
17810 #endif
17811         p = reply;
17812 #ifdef NS_HFIXEDSZ
17813         /* Bind 8/9 interface */
17814         p += NS_HFIXEDSZ;
17815 #elif defined(HFIXEDSZ)
17816         /* Bind 4 interface w/ HFIXEDSZ */
17817         p += HFIXEDSZ;
17818 #else
17819         /* Bind 4 interface w/o HFIXEDSZ */
17820         p += sizeof(HEADER);
17821 #endif
17822         status = dn_expand( reply, reply+len, p, host, sizeof(host));
17823 }
17824   ;
17825   return 0;
17826 }
17827 _ACEOF
17828 rm -f conftest.$ac_objext conftest$ac_exeext
17829 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17830   (eval $ac_link) 2>conftest.er1
17831   ac_status=$?
17832   grep -v '^ *+' conftest.er1 >conftest.err
17833   rm -f conftest.er1
17834   cat conftest.err >&5
17835   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17836   (exit $ac_status); } &&
17837          { ac_try='test -z "$ac_c_werror_flag"
17838                          || test ! -s conftest.err'
17839   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17840   (eval $ac_try) 2>&5
17841   ac_status=$?
17842   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17843   (exit $ac_status); }; } &&
17844          { ac_try='test -s conftest$ac_exeext'
17845   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17846   (eval $ac_try) 2>&5
17847   ac_status=$?
17848   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17849   (exit $ac_status); }; }; then
17850   ol_cv_resolver_resolv=yes
17851 else
17852   echo "$as_me: failed program was:" >&5
17853 sed 's/^/| /' conftest.$ac_ext >&5
17854
17855 ol_cv_resolver_resolv=no
17856 fi
17857 rm -f conftest.err conftest.$ac_objext \
17858       conftest$ac_exeext conftest.$ac_ext
17859
17860         LIBS="$ol_LIBS"
17861
17862 fi
17863 echo "$as_me:$LINENO: result: $ol_cv_resolver_resolv" >&5
17864 echo "${ECHO_T}$ol_cv_resolver_resolv" >&6
17865
17866         if test $ol_cv_resolver_resolv = yes ; then
17867                 ol_cv_lib_resolver=-lresolv
17868         fi
17869 fi
17870
17871 if test $ol_cv_lib_resolver = no ; then
17872         echo "$as_me:$LINENO: checking for resolver link (-lbind)" >&5
17873 echo $ECHO_N "checking for resolver link (-lbind)... $ECHO_C" >&6
17874 if test "${ol_cv_resolver_bind+set}" = set; then
17875   echo $ECHO_N "(cached) $ECHO_C" >&6
17876 else
17877
17878         ol_RESOLVER_LIB=-lbind
17879         ol_LIBS=$LIBS
17880         LIBS="$ol_RESOLVER_LIB $LIBS"
17881
17882         cat >conftest.$ac_ext <<_ACEOF
17883 /* confdefs.h.  */
17884 _ACEOF
17885 cat confdefs.h >>conftest.$ac_ext
17886 cat >>conftest.$ac_ext <<_ACEOF
17887 /* end confdefs.h.  */
17888
17889 #ifdef HAVE_SYS_TYPES_H
17890 #       include <sys/types.h>
17891 #endif
17892 #include <netinet/in.h>
17893 #ifdef HAVE_ARPA_NAMESER_H
17894 #       include <arpa/nameser.h>
17895 #endif
17896 #ifdef HAVE_RESOLV_H
17897 #       include <resolv.h>
17898 #endif
17899
17900 int
17901 main ()
17902 {
17903 {
17904         int len, status;
17905         char *request = NULL;
17906         unsigned char reply[64*1024];
17907         unsigned char host[64*1024];
17908         unsigned char *p;
17909
17910 #ifdef NS_HFIXEDSZ
17911         /* Bind 8/9 interface */
17912         len = res_query(request, ns_c_in, ns_t_srv, reply, sizeof(reply));
17913 #else
17914         /* Bind 4 interface */
17915 # ifndef T_SRV
17916 #  define T_SRV 33
17917 # endif
17918         len = res_query(request, C_IN, T_SRV, reply, sizeof(reply));
17919 #endif
17920         p = reply;
17921 #ifdef NS_HFIXEDSZ
17922         /* Bind 8/9 interface */
17923         p += NS_HFIXEDSZ;
17924 #elif defined(HFIXEDSZ)
17925         /* Bind 4 interface w/ HFIXEDSZ */
17926         p += HFIXEDSZ;
17927 #else
17928         /* Bind 4 interface w/o HFIXEDSZ */
17929         p += sizeof(HEADER);
17930 #endif
17931         status = dn_expand( reply, reply+len, p, host, sizeof(host));
17932 }
17933   ;
17934   return 0;
17935 }
17936 _ACEOF
17937 rm -f conftest.$ac_objext conftest$ac_exeext
17938 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17939   (eval $ac_link) 2>conftest.er1
17940   ac_status=$?
17941   grep -v '^ *+' conftest.er1 >conftest.err
17942   rm -f conftest.er1
17943   cat conftest.err >&5
17944   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17945   (exit $ac_status); } &&
17946          { ac_try='test -z "$ac_c_werror_flag"
17947                          || test ! -s conftest.err'
17948   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17949   (eval $ac_try) 2>&5
17950   ac_status=$?
17951   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17952   (exit $ac_status); }; } &&
17953          { ac_try='test -s conftest$ac_exeext'
17954   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17955   (eval $ac_try) 2>&5
17956   ac_status=$?
17957   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17958   (exit $ac_status); }; }; then
17959   ol_cv_resolver_bind=yes
17960 else
17961   echo "$as_me: failed program was:" >&5
17962 sed 's/^/| /' conftest.$ac_ext >&5
17963
17964 ol_cv_resolver_bind=no
17965 fi
17966 rm -f conftest.err conftest.$ac_objext \
17967       conftest$ac_exeext conftest.$ac_ext
17968
17969         LIBS="$ol_LIBS"
17970
17971 fi
17972 echo "$as_me:$LINENO: result: $ol_cv_resolver_bind" >&5
17973 echo "${ECHO_T}$ol_cv_resolver_bind" >&6
17974
17975         if test $ol_cv_resolver_bind = yes ; then
17976                 ol_cv_lib_resolver=-lbind
17977         fi
17978 fi
17979
17980
17981
17982 ol_link_dnssrv=no
17983 if test "$ol_cv_lib_resolver" != no ; then
17984
17985 cat >>confdefs.h <<\_ACEOF
17986 #define HAVE_RES_QUERY 1
17987 _ACEOF
17988
17989
17990         if test "$ol_enable_dnssrv" != no ; then
17991                 ol_link_dnssrv=yes
17992         fi
17993
17994         if test "$ol_cv_lib_resolver" != yes ; then
17995                 LIBS="$ol_cv_lib_resolver $LIBS"
17996         fi
17997 fi
17998
17999 if test "$ol_enable_dnssrv" = yes || test "$ol_enable_dnssrv" = mod ; then
18000         if test "$ol_link_dnssrv" = no ; then
18001                 { { echo "$as_me:$LINENO: error: DNSSRV requires res_query()" >&5
18002 echo "$as_me: error: DNSSRV requires res_query()" >&2;}
18003    { (exit 1); exit 1; }; }
18004         fi
18005 else
18006         ol_enable_dnssrv=no
18007 fi
18008
18009
18010 for ac_func in hstrerror
18011 do
18012 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18013 echo "$as_me:$LINENO: checking for $ac_func" >&5
18014 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
18015 if eval "test \"\${$as_ac_var+set}\" = set"; then
18016   echo $ECHO_N "(cached) $ECHO_C" >&6
18017 else
18018   cat >conftest.$ac_ext <<_ACEOF
18019 /* confdefs.h.  */
18020 _ACEOF
18021 cat confdefs.h >>conftest.$ac_ext
18022 cat >>conftest.$ac_ext <<_ACEOF
18023 /* end confdefs.h.  */
18024 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18025    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18026 #define $ac_func innocuous_$ac_func
18027
18028 /* System header to define __stub macros and hopefully few prototypes,
18029     which can conflict with char $ac_func (); below.
18030     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18031     <limits.h> exists even on freestanding compilers.  */
18032
18033 #ifdef __STDC__
18034 # include <limits.h>
18035 #else
18036 # include <assert.h>
18037 #endif
18038
18039 #undef $ac_func
18040
18041 /* Override any gcc2 internal prototype to avoid an error.  */
18042 #ifdef __cplusplus
18043 extern "C"
18044 {
18045 #endif
18046 /* We use char because int might match the return type of a gcc2
18047    builtin and then its argument prototype would still apply.  */
18048 char $ac_func ();
18049 /* The GNU C library defines this for functions which it implements
18050     to always fail with ENOSYS.  Some functions are actually named
18051     something starting with __ and the normal name is an alias.  */
18052 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
18053 choke me
18054 #else
18055 char (*f) () = $ac_func;
18056 #endif
18057 #ifdef __cplusplus
18058 }
18059 #endif
18060
18061 int
18062 main ()
18063 {
18064 return f != $ac_func;
18065   ;
18066   return 0;
18067 }
18068 _ACEOF
18069 rm -f conftest.$ac_objext conftest$ac_exeext
18070 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18071   (eval $ac_link) 2>conftest.er1
18072   ac_status=$?
18073   grep -v '^ *+' conftest.er1 >conftest.err
18074   rm -f conftest.er1
18075   cat conftest.err >&5
18076   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18077   (exit $ac_status); } &&
18078          { ac_try='test -z "$ac_c_werror_flag"
18079                          || test ! -s conftest.err'
18080   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18081   (eval $ac_try) 2>&5
18082   ac_status=$?
18083   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18084   (exit $ac_status); }; } &&
18085          { ac_try='test -s conftest$ac_exeext'
18086   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18087   (eval $ac_try) 2>&5
18088   ac_status=$?
18089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18090   (exit $ac_status); }; }; then
18091   eval "$as_ac_var=yes"
18092 else
18093   echo "$as_me: failed program was:" >&5
18094 sed 's/^/| /' conftest.$ac_ext >&5
18095
18096 eval "$as_ac_var=no"
18097 fi
18098 rm -f conftest.err conftest.$ac_objext \
18099       conftest$ac_exeext conftest.$ac_ext
18100 fi
18101 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
18102 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
18103 if test `eval echo '${'$as_ac_var'}'` = yes; then
18104   cat >>confdefs.h <<_ACEOF
18105 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18106 _ACEOF
18107
18108 fi
18109 done
18110
18111
18112
18113
18114
18115
18116 for ac_func in getaddrinfo getnameinfo gai_strerror inet_ntop
18117 do
18118 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18119 echo "$as_me:$LINENO: checking for $ac_func" >&5
18120 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
18121 if eval "test \"\${$as_ac_var+set}\" = set"; then
18122   echo $ECHO_N "(cached) $ECHO_C" >&6
18123 else
18124   cat >conftest.$ac_ext <<_ACEOF
18125 /* confdefs.h.  */
18126 _ACEOF
18127 cat confdefs.h >>conftest.$ac_ext
18128 cat >>conftest.$ac_ext <<_ACEOF
18129 /* end confdefs.h.  */
18130 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18131    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18132 #define $ac_func innocuous_$ac_func
18133
18134 /* System header to define __stub macros and hopefully few prototypes,
18135     which can conflict with char $ac_func (); below.
18136     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18137     <limits.h> exists even on freestanding compilers.  */
18138
18139 #ifdef __STDC__
18140 # include <limits.h>
18141 #else
18142 # include <assert.h>
18143 #endif
18144
18145 #undef $ac_func
18146
18147 /* Override any gcc2 internal prototype to avoid an error.  */
18148 #ifdef __cplusplus
18149 extern "C"
18150 {
18151 #endif
18152 /* We use char because int might match the return type of a gcc2
18153    builtin and then its argument prototype would still apply.  */
18154 char $ac_func ();
18155 /* The GNU C library defines this for functions which it implements
18156     to always fail with ENOSYS.  Some functions are actually named
18157     something starting with __ and the normal name is an alias.  */
18158 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
18159 choke me
18160 #else
18161 char (*f) () = $ac_func;
18162 #endif
18163 #ifdef __cplusplus
18164 }
18165 #endif
18166
18167 int
18168 main ()
18169 {
18170 return f != $ac_func;
18171   ;
18172   return 0;
18173 }
18174 _ACEOF
18175 rm -f conftest.$ac_objext conftest$ac_exeext
18176 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18177   (eval $ac_link) 2>conftest.er1
18178   ac_status=$?
18179   grep -v '^ *+' conftest.er1 >conftest.err
18180   rm -f conftest.er1
18181   cat conftest.err >&5
18182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18183   (exit $ac_status); } &&
18184          { ac_try='test -z "$ac_c_werror_flag"
18185                          || test ! -s conftest.err'
18186   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18187   (eval $ac_try) 2>&5
18188   ac_status=$?
18189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18190   (exit $ac_status); }; } &&
18191          { ac_try='test -s conftest$ac_exeext'
18192   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18193   (eval $ac_try) 2>&5
18194   ac_status=$?
18195   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18196   (exit $ac_status); }; }; then
18197   eval "$as_ac_var=yes"
18198 else
18199   echo "$as_me: failed program was:" >&5
18200 sed 's/^/| /' conftest.$ac_ext >&5
18201
18202 eval "$as_ac_var=no"
18203 fi
18204 rm -f conftest.err conftest.$ac_objext \
18205       conftest$ac_exeext conftest.$ac_ext
18206 fi
18207 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
18208 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
18209 if test `eval echo '${'$as_ac_var'}'` = yes; then
18210   cat >>confdefs.h <<_ACEOF
18211 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18212 _ACEOF
18213
18214 fi
18215 done
18216
18217
18218 ol_link_ipv6=no
18219 if test $ac_cv_func_getaddrinfo = no || test $ac_cv_func_inet_ntop = no ; then
18220         if test $ol_enable_ipv6 = yes ; then
18221                 { { echo "$as_me:$LINENO: error: IPv6 support requires getaddrinfo() and inet_ntop()" >&5
18222 echo "$as_me: error: IPv6 support requires getaddrinfo() and inet_ntop()" >&2;}
18223    { (exit 1); exit 1; }; }
18224         fi
18225 elif test $ol_enable_ipv6 != no ; then
18226         echo "$as_me:$LINENO: checking INET6_ADDRSTRLEN" >&5
18227 echo $ECHO_N "checking INET6_ADDRSTRLEN... $ECHO_C" >&6
18228 if test "${ol_cv_inet6_addrstrlen+set}" = set; then
18229   echo $ECHO_N "(cached) $ECHO_C" >&6
18230 else
18231
18232                 cat >conftest.$ac_ext <<_ACEOF
18233 /* confdefs.h.  */
18234 _ACEOF
18235 cat confdefs.h >>conftest.$ac_ext
18236 cat >>conftest.$ac_ext <<_ACEOF
18237 /* end confdefs.h.  */
18238
18239 #                       include <netinet/in.h>
18240 #                       ifdef INET6_ADDRSTRLEN
18241                                 __has_inet6_addrstrlen__;
18242 #                       endif
18243
18244 _ACEOF
18245 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18246   $EGREP "__has_inet6_addrstrlen__" >/dev/null 2>&1; then
18247   ol_cv_inet6_addrstrlen=yes
18248 else
18249   ol_cv_inet6_addrstrlen=no
18250 fi
18251 rm -f conftest*
18252
18253 fi
18254 echo "$as_me:$LINENO: result: $ol_cv_inet6_addrstrlen" >&5
18255 echo "${ECHO_T}$ol_cv_inet6_addrstrlen" >&6
18256
18257
18258         echo "$as_me:$LINENO: checking struct sockaddr_storage" >&5
18259 echo $ECHO_N "checking struct sockaddr_storage... $ECHO_C" >&6
18260 if test "${ol_cv_struct_sockaddr_storage+set}" = set; then
18261   echo $ECHO_N "(cached) $ECHO_C" >&6
18262 else
18263
18264                 cat >conftest.$ac_ext <<_ACEOF
18265 /* confdefs.h.  */
18266 _ACEOF
18267 cat confdefs.h >>conftest.$ac_ext
18268 cat >>conftest.$ac_ext <<_ACEOF
18269 /* end confdefs.h.  */
18270
18271 #include <sys/types.h>
18272 #include <sys/socket.h>
18273
18274 int
18275 main ()
18276 {
18277
18278                         struct sockaddr_storage ss;
18279
18280   ;
18281   return 0;
18282 }
18283 _ACEOF
18284 rm -f conftest.$ac_objext
18285 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18286   (eval $ac_compile) 2>conftest.er1
18287   ac_status=$?
18288   grep -v '^ *+' conftest.er1 >conftest.err
18289   rm -f conftest.er1
18290   cat conftest.err >&5
18291   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18292   (exit $ac_status); } &&
18293          { ac_try='test -z "$ac_c_werror_flag"
18294                          || test ! -s conftest.err'
18295   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18296   (eval $ac_try) 2>&5
18297   ac_status=$?
18298   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18299   (exit $ac_status); }; } &&
18300          { ac_try='test -s conftest.$ac_objext'
18301   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18302   (eval $ac_try) 2>&5
18303   ac_status=$?
18304   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18305   (exit $ac_status); }; }; then
18306   ol_cv_struct_sockaddr_storage=yes
18307 else
18308   echo "$as_me: failed program was:" >&5
18309 sed 's/^/| /' conftest.$ac_ext >&5
18310
18311 ol_cv_struct_sockaddr_storage=no
18312 fi
18313 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18314 fi
18315 echo "$as_me:$LINENO: result: $ol_cv_struct_sockaddr_storage" >&5
18316 echo "${ECHO_T}$ol_cv_struct_sockaddr_storage" >&6
18317
18318         if test $ol_cv_inet6_addrstrlen = yes &&
18319            test $ol_cv_struct_sockaddr_storage = yes ; then
18320                 ol_link_ipv6=yes
18321         elif test $ol_enable_ipv6 = yes &&
18322              test $ol_cv_inet6_addrstrlen = no ; then
18323                 { { echo "$as_me:$LINENO: error: IPv6 support requires INET6_ADDRSTRLEN" >&5
18324 echo "$as_me: error: IPv6 support requires INET6_ADDRSTRLEN" >&2;}
18325    { (exit 1); exit 1; }; }
18326         elif test $ol_enable_ipv6 = yes &&
18327              test $ol_cv_struct_sockaddr_storage = no ; then
18328                 { { echo "$as_me:$LINENO: error: IPv6 support requires struct sockaddr_storage" >&5
18329 echo "$as_me: error: IPv6 support requires struct sockaddr_storage" >&2;}
18330    { (exit 1); exit 1; }; }
18331         fi
18332 fi
18333
18334 if test $ol_enable_local != no ; then
18335
18336 for ac_header in sys/un.h
18337 do
18338 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18339 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18340   echo "$as_me:$LINENO: checking for $ac_header" >&5
18341 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18342 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18343   echo $ECHO_N "(cached) $ECHO_C" >&6
18344 fi
18345 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18346 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18347 else
18348   # Is the header compilable?
18349 echo "$as_me:$LINENO: checking $ac_header usability" >&5
18350 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18351 cat >conftest.$ac_ext <<_ACEOF
18352 /* confdefs.h.  */
18353 _ACEOF
18354 cat confdefs.h >>conftest.$ac_ext
18355 cat >>conftest.$ac_ext <<_ACEOF
18356 /* end confdefs.h.  */
18357 $ac_includes_default
18358 #include <$ac_header>
18359 _ACEOF
18360 rm -f conftest.$ac_objext
18361 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18362   (eval $ac_compile) 2>conftest.er1
18363   ac_status=$?
18364   grep -v '^ *+' conftest.er1 >conftest.err
18365   rm -f conftest.er1
18366   cat conftest.err >&5
18367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18368   (exit $ac_status); } &&
18369          { ac_try='test -z "$ac_c_werror_flag"
18370                          || test ! -s conftest.err'
18371   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18372   (eval $ac_try) 2>&5
18373   ac_status=$?
18374   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18375   (exit $ac_status); }; } &&
18376          { ac_try='test -s conftest.$ac_objext'
18377   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18378   (eval $ac_try) 2>&5
18379   ac_status=$?
18380   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18381   (exit $ac_status); }; }; then
18382   ac_header_compiler=yes
18383 else
18384   echo "$as_me: failed program was:" >&5
18385 sed 's/^/| /' conftest.$ac_ext >&5
18386
18387 ac_header_compiler=no
18388 fi
18389 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18390 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18391 echo "${ECHO_T}$ac_header_compiler" >&6
18392
18393 # Is the header present?
18394 echo "$as_me:$LINENO: checking $ac_header presence" >&5
18395 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18396 cat >conftest.$ac_ext <<_ACEOF
18397 /* confdefs.h.  */
18398 _ACEOF
18399 cat confdefs.h >>conftest.$ac_ext
18400 cat >>conftest.$ac_ext <<_ACEOF
18401 /* end confdefs.h.  */
18402 #include <$ac_header>
18403 _ACEOF
18404 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18405   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18406   ac_status=$?
18407   grep -v '^ *+' conftest.er1 >conftest.err
18408   rm -f conftest.er1
18409   cat conftest.err >&5
18410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18411   (exit $ac_status); } >/dev/null; then
18412   if test -s conftest.err; then
18413     ac_cpp_err=$ac_c_preproc_warn_flag
18414     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
18415   else
18416     ac_cpp_err=
18417   fi
18418 else
18419   ac_cpp_err=yes
18420 fi
18421 if test -z "$ac_cpp_err"; then
18422   ac_header_preproc=yes
18423 else
18424   echo "$as_me: failed program was:" >&5
18425 sed 's/^/| /' conftest.$ac_ext >&5
18426
18427   ac_header_preproc=no
18428 fi
18429 rm -f conftest.err conftest.$ac_ext
18430 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18431 echo "${ECHO_T}$ac_header_preproc" >&6
18432
18433 # So?  What about this header?
18434 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18435   yes:no: )
18436     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18437 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18438     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18439 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18440     ac_header_preproc=yes
18441     ;;
18442   no:yes:* )
18443     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18444 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
18445     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
18446 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
18447     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18448 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18449     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
18450 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
18451     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18452 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18453     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18454 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
18455     (
18456       cat <<\_ASBOX
18457 ## --------------------------------------------- ##
18458 ## Report this to <http://www.openldap.org/its/> ##
18459 ## --------------------------------------------- ##
18460 _ASBOX
18461     ) |
18462       sed "s/^/$as_me: WARNING:     /" >&2
18463     ;;
18464 esac
18465 echo "$as_me:$LINENO: checking for $ac_header" >&5
18466 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18467 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18468   echo $ECHO_N "(cached) $ECHO_C" >&6
18469 else
18470   eval "$as_ac_Header=\$ac_header_preproc"
18471 fi
18472 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18473 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18474
18475 fi
18476 if test `eval echo '${'$as_ac_Header'}'` = yes; then
18477   cat >>confdefs.h <<_ACEOF
18478 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18479 _ACEOF
18480
18481 fi
18482
18483 done
18484
18485
18486         if test $ol_enable_local = auto ; then
18487                 ol_enable_local=$ac_cv_header_sys_un_h
18488         elif test $ac_cv_header_sys_un_h = no ; then
18489                 { { echo "$as_me:$LINENO: error: AF_LOCAL domain support requires sys/un.h" >&5
18490 echo "$as_me: error: AF_LOCAL domain support requires sys/un.h" >&2;}
18491    { (exit 1); exit 1; }; }
18492         fi
18493 fi
18494
18495
18496 if test $ol_with_tls = yes ; then
18497         ol_with_tls=auto
18498 fi
18499
18500 ol_link_tls=no
18501 if test $ol_with_tls = openssl || test $ol_with_tls = auto ; then
18502
18503 for ac_header in openssl/ssl.h
18504 do
18505 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18506 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18507   echo "$as_me:$LINENO: checking for $ac_header" >&5
18508 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18509 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18510   echo $ECHO_N "(cached) $ECHO_C" >&6
18511 fi
18512 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18513 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18514 else
18515   # Is the header compilable?
18516 echo "$as_me:$LINENO: checking $ac_header usability" >&5
18517 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18518 cat >conftest.$ac_ext <<_ACEOF
18519 /* confdefs.h.  */
18520 _ACEOF
18521 cat confdefs.h >>conftest.$ac_ext
18522 cat >>conftest.$ac_ext <<_ACEOF
18523 /* end confdefs.h.  */
18524 $ac_includes_default
18525 #include <$ac_header>
18526 _ACEOF
18527 rm -f conftest.$ac_objext
18528 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18529   (eval $ac_compile) 2>conftest.er1
18530   ac_status=$?
18531   grep -v '^ *+' conftest.er1 >conftest.err
18532   rm -f conftest.er1
18533   cat conftest.err >&5
18534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18535   (exit $ac_status); } &&
18536          { ac_try='test -z "$ac_c_werror_flag"
18537                          || test ! -s conftest.err'
18538   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18539   (eval $ac_try) 2>&5
18540   ac_status=$?
18541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18542   (exit $ac_status); }; } &&
18543          { ac_try='test -s conftest.$ac_objext'
18544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18545   (eval $ac_try) 2>&5
18546   ac_status=$?
18547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18548   (exit $ac_status); }; }; then
18549   ac_header_compiler=yes
18550 else
18551   echo "$as_me: failed program was:" >&5
18552 sed 's/^/| /' conftest.$ac_ext >&5
18553
18554 ac_header_compiler=no
18555 fi
18556 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18557 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18558 echo "${ECHO_T}$ac_header_compiler" >&6
18559
18560 # Is the header present?
18561 echo "$as_me:$LINENO: checking $ac_header presence" >&5
18562 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18563 cat >conftest.$ac_ext <<_ACEOF
18564 /* confdefs.h.  */
18565 _ACEOF
18566 cat confdefs.h >>conftest.$ac_ext
18567 cat >>conftest.$ac_ext <<_ACEOF
18568 /* end confdefs.h.  */
18569 #include <$ac_header>
18570 _ACEOF
18571 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18572   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18573   ac_status=$?
18574   grep -v '^ *+' conftest.er1 >conftest.err
18575   rm -f conftest.er1
18576   cat conftest.err >&5
18577   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18578   (exit $ac_status); } >/dev/null; then
18579   if test -s conftest.err; then
18580     ac_cpp_err=$ac_c_preproc_warn_flag
18581     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
18582   else
18583     ac_cpp_err=
18584   fi
18585 else
18586   ac_cpp_err=yes
18587 fi
18588 if test -z "$ac_cpp_err"; then
18589   ac_header_preproc=yes
18590 else
18591   echo "$as_me: failed program was:" >&5
18592 sed 's/^/| /' conftest.$ac_ext >&5
18593
18594   ac_header_preproc=no
18595 fi
18596 rm -f conftest.err conftest.$ac_ext
18597 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18598 echo "${ECHO_T}$ac_header_preproc" >&6
18599
18600 # So?  What about this header?
18601 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18602   yes:no: )
18603     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18604 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18605     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18606 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18607     ac_header_preproc=yes
18608     ;;
18609   no:yes:* )
18610     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18611 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
18612     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
18613 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
18614     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18615 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18616     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
18617 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
18618     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18619 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18620     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18621 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
18622     (
18623       cat <<\_ASBOX
18624 ## --------------------------------------------- ##
18625 ## Report this to <http://www.openldap.org/its/> ##
18626 ## --------------------------------------------- ##
18627 _ASBOX
18628     ) |
18629       sed "s/^/$as_me: WARNING:     /" >&2
18630     ;;
18631 esac
18632 echo "$as_me:$LINENO: checking for $ac_header" >&5
18633 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18634 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18635   echo $ECHO_N "(cached) $ECHO_C" >&6
18636 else
18637   eval "$as_ac_Header=\$ac_header_preproc"
18638 fi
18639 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18640 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18641
18642 fi
18643 if test `eval echo '${'$as_ac_Header'}'` = yes; then
18644   cat >>confdefs.h <<_ACEOF
18645 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
18646 _ACEOF
18647
18648 fi
18649
18650 done
18651
18652
18653         if test $ac_cv_header_openssl_ssl_h = yes ; then
18654                 echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
18655 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6
18656 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
18657   echo $ECHO_N "(cached) $ECHO_C" >&6
18658 else
18659   ac_check_lib_save_LIBS=$LIBS
18660 LIBS="-lssl -lcrypto $LIBS"
18661 cat >conftest.$ac_ext <<_ACEOF
18662 /* confdefs.h.  */
18663 _ACEOF
18664 cat confdefs.h >>conftest.$ac_ext
18665 cat >>conftest.$ac_ext <<_ACEOF
18666 /* end confdefs.h.  */
18667
18668 /* Override any gcc2 internal prototype to avoid an error.  */
18669 #ifdef __cplusplus
18670 extern "C"
18671 #endif
18672 /* We use char because int might match the return type of a gcc2
18673    builtin and then its argument prototype would still apply.  */
18674 char SSL_library_init ();
18675 int
18676 main ()
18677 {
18678 SSL_library_init ();
18679   ;
18680   return 0;
18681 }
18682 _ACEOF
18683 rm -f conftest.$ac_objext conftest$ac_exeext
18684 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18685   (eval $ac_link) 2>conftest.er1
18686   ac_status=$?
18687   grep -v '^ *+' conftest.er1 >conftest.err
18688   rm -f conftest.er1
18689   cat conftest.err >&5
18690   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18691   (exit $ac_status); } &&
18692          { ac_try='test -z "$ac_c_werror_flag"
18693                          || test ! -s conftest.err'
18694   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18695   (eval $ac_try) 2>&5
18696   ac_status=$?
18697   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18698   (exit $ac_status); }; } &&
18699          { ac_try='test -s conftest$ac_exeext'
18700   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18701   (eval $ac_try) 2>&5
18702   ac_status=$?
18703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18704   (exit $ac_status); }; }; then
18705   ac_cv_lib_ssl_SSL_library_init=yes
18706 else
18707   echo "$as_me: failed program was:" >&5
18708 sed 's/^/| /' conftest.$ac_ext >&5
18709
18710 ac_cv_lib_ssl_SSL_library_init=no
18711 fi
18712 rm -f conftest.err conftest.$ac_objext \
18713       conftest$ac_exeext conftest.$ac_ext
18714 LIBS=$ac_check_lib_save_LIBS
18715 fi
18716 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
18717 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6
18718 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
18719   have_openssl=yes
18720                         need_rsaref=no
18721 else
18722   have_openssl=no
18723 fi
18724
18725
18726                 if test $have_openssl = no ; then
18727                         echo "$as_me:$LINENO: checking for ssl3_accept in -lssl" >&5
18728 echo $ECHO_N "checking for ssl3_accept in -lssl... $ECHO_C" >&6
18729 if test "${ac_cv_lib_ssl_ssl3_accept+set}" = set; then
18730   echo $ECHO_N "(cached) $ECHO_C" >&6
18731 else
18732   ac_check_lib_save_LIBS=$LIBS
18733 LIBS="-lssl -lcrypto -lRSAglue -lrsaref $LIBS"
18734 cat >conftest.$ac_ext <<_ACEOF
18735 /* confdefs.h.  */
18736 _ACEOF
18737 cat confdefs.h >>conftest.$ac_ext
18738 cat >>conftest.$ac_ext <<_ACEOF
18739 /* end confdefs.h.  */
18740
18741 /* Override any gcc2 internal prototype to avoid an error.  */
18742 #ifdef __cplusplus
18743 extern "C"
18744 #endif
18745 /* We use char because int might match the return type of a gcc2
18746    builtin and then its argument prototype would still apply.  */
18747 char ssl3_accept ();
18748 int
18749 main ()
18750 {
18751 ssl3_accept ();
18752   ;
18753   return 0;
18754 }
18755 _ACEOF
18756 rm -f conftest.$ac_objext conftest$ac_exeext
18757 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18758   (eval $ac_link) 2>conftest.er1
18759   ac_status=$?
18760   grep -v '^ *+' conftest.er1 >conftest.err
18761   rm -f conftest.er1
18762   cat conftest.err >&5
18763   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18764   (exit $ac_status); } &&
18765          { ac_try='test -z "$ac_c_werror_flag"
18766                          || test ! -s conftest.err'
18767   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18768   (eval $ac_try) 2>&5
18769   ac_status=$?
18770   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18771   (exit $ac_status); }; } &&
18772          { ac_try='test -s conftest$ac_exeext'
18773   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18774   (eval $ac_try) 2>&5
18775   ac_status=$?
18776   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18777   (exit $ac_status); }; }; then
18778   ac_cv_lib_ssl_ssl3_accept=yes
18779 else
18780   echo "$as_me: failed program was:" >&5
18781 sed 's/^/| /' conftest.$ac_ext >&5
18782
18783 ac_cv_lib_ssl_ssl3_accept=no
18784 fi
18785 rm -f conftest.err conftest.$ac_objext \
18786       conftest$ac_exeext conftest.$ac_ext
18787 LIBS=$ac_check_lib_save_LIBS
18788 fi
18789 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_ssl3_accept" >&5
18790 echo "${ECHO_T}$ac_cv_lib_ssl_ssl3_accept" >&6
18791 if test $ac_cv_lib_ssl_ssl3_accept = yes; then
18792   have_openssl=yes
18793                                 need_rsaref=yes
18794 else
18795   have_openssl=no
18796 fi
18797
18798                 fi
18799
18800                 if test $have_openssl = yes ; then
18801                         ol_with_tls=openssl
18802                         ol_link_tls=yes
18803
18804
18805 cat >>confdefs.h <<\_ACEOF
18806 #define HAVE_OPENSSL 1
18807 _ACEOF
18808
18809
18810                         if test $need_rsaref = yes; then
18811
18812 cat >>confdefs.h <<\_ACEOF
18813 #define HAVE_RSAREF 1
18814 _ACEOF
18815
18816
18817                                 TLS_LIBS="-lssl -lcrypto -lRSAglue -lrsaref"
18818                         else
18819                                 TLS_LIBS="-lssl -lcrypto"
18820                         fi
18821
18822                         echo "$as_me:$LINENO: checking OpenSSL library version (CRL checking capability)" >&5
18823 echo $ECHO_N "checking OpenSSL library version (CRL checking capability)... $ECHO_C" >&6
18824 if test "${ol_cv_ssl_crl_compat+set}" = set; then
18825   echo $ECHO_N "(cached) $ECHO_C" >&6
18826 else
18827
18828                 cat >conftest.$ac_ext <<_ACEOF
18829 /* confdefs.h.  */
18830 _ACEOF
18831 cat confdefs.h >>conftest.$ac_ext
18832 cat >>conftest.$ac_ext <<_ACEOF
18833 /* end confdefs.h.  */
18834
18835 #ifdef HAVE_OPENSSL_SSL_H
18836 #include <openssl/ssl.h>
18837 #endif
18838
18839 /* Require 0.9.7d+ */
18840 #if OPENSSL_VERSION_NUMBER >= 0x0090704fL
18841         char *__ssl_compat = "0.9.7d";
18842 #endif
18843
18844 _ACEOF
18845 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18846   $EGREP "__ssl_compat" >/dev/null 2>&1; then
18847   ol_cv_ssl_crl_compat=yes
18848 else
18849   ol_cv_ssl_crl_compat=no
18850 fi
18851 rm -f conftest*
18852
18853 fi
18854 echo "$as_me:$LINENO: result: $ol_cv_ssl_crl_compat" >&5
18855 echo "${ECHO_T}$ol_cv_ssl_crl_compat" >&6
18856
18857                         if test $ol_cv_ssl_crl_compat = yes ; then
18858
18859 cat >>confdefs.h <<\_ACEOF
18860 #define HAVE_OPENSSL_CRL 1
18861 _ACEOF
18862
18863                         fi
18864                 fi
18865         fi
18866 fi
18867
18868 if test $ol_link_tls = no ; then
18869         if test $ol_with_tls = gnutls || test $ol_with_tls = auto ; then
18870
18871 for ac_header in gnutls/gnutls.h
18872 do
18873 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
18874 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18875   echo "$as_me:$LINENO: checking for $ac_header" >&5
18876 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18877 if eval "test \"\${$as_ac_Header+set}\" = set"; then
18878   echo $ECHO_N "(cached) $ECHO_C" >&6
18879 fi
18880 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18881 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18882 else
18883   # Is the header compilable?
18884 echo "$as_me:$LINENO: checking $ac_header usability" >&5
18885 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18886 cat >conftest.$ac_ext <<_ACEOF
18887 /* confdefs.h.  */
18888 _ACEOF
18889 cat confdefs.h >>conftest.$ac_ext
18890 cat >>conftest.$ac_ext <<_ACEOF
18891 /* end confdefs.h.  */
18892 $ac_includes_default
18893 #include <$ac_header>
18894 _ACEOF
18895 rm -f conftest.$ac_objext
18896 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18897   (eval $ac_compile) 2>conftest.er1
18898   ac_status=$?
18899   grep -v '^ *+' conftest.er1 >conftest.err
18900   rm -f conftest.er1
18901   cat conftest.err >&5
18902   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18903   (exit $ac_status); } &&
18904          { ac_try='test -z "$ac_c_werror_flag"
18905                          || test ! -s conftest.err'
18906   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18907   (eval $ac_try) 2>&5
18908   ac_status=$?
18909   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18910   (exit $ac_status); }; } &&
18911          { ac_try='test -s conftest.$ac_objext'
18912   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18913   (eval $ac_try) 2>&5
18914   ac_status=$?
18915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18916   (exit $ac_status); }; }; then
18917   ac_header_compiler=yes
18918 else
18919   echo "$as_me: failed program was:" >&5
18920 sed 's/^/| /' conftest.$ac_ext >&5
18921
18922 ac_header_compiler=no
18923 fi
18924 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18925 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18926 echo "${ECHO_T}$ac_header_compiler" >&6
18927
18928 # Is the header present?
18929 echo "$as_me:$LINENO: checking $ac_header presence" >&5
18930 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18931 cat >conftest.$ac_ext <<_ACEOF
18932 /* confdefs.h.  */
18933 _ACEOF
18934 cat confdefs.h >>conftest.$ac_ext
18935 cat >>conftest.$ac_ext <<_ACEOF
18936 /* end confdefs.h.  */
18937 #include <$ac_header>
18938 _ACEOF
18939 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18940   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18941   ac_status=$?
18942   grep -v '^ *+' conftest.er1 >conftest.err
18943   rm -f conftest.er1
18944   cat conftest.err >&5
18945   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18946   (exit $ac_status); } >/dev/null; then
18947   if test -s conftest.err; then
18948     ac_cpp_err=$ac_c_preproc_warn_flag
18949     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
18950   else
18951     ac_cpp_err=
18952   fi
18953 else
18954   ac_cpp_err=yes
18955 fi
18956 if test -z "$ac_cpp_err"; then
18957   ac_header_preproc=yes
18958 else
18959   echo "$as_me: failed program was:" >&5
18960 sed 's/^/| /' conftest.$ac_ext >&5
18961
18962   ac_header_preproc=no
18963 fi
18964 rm -f conftest.err conftest.$ac_ext
18965 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18966 echo "${ECHO_T}$ac_header_preproc" >&6
18967
18968 # So?  What about this header?
18969 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18970   yes:no: )
18971     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18972 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18973     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18974 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18975     ac_header_preproc=yes
18976     ;;
18977   no:yes:* )
18978     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18979 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
18980     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
18981 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
18982     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18983 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18984     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
18985 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
18986     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18987 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18988     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18989 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
18990     (
18991       cat <<\_ASBOX
18992 ## --------------------------------------------- ##
18993 ## Report this to <http://www.openldap.org/its/> ##
18994 ## --------------------------------------------- ##
18995 _ASBOX
18996     ) |
18997       sed "s/^/$as_me: WARNING:     /" >&2
18998     ;;
18999 esac
19000 echo "$as_me:$LINENO: checking for $ac_header" >&5
19001 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19002 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19003   echo $ECHO_N "(cached) $ECHO_C" >&6
19004 else
19005   eval "$as_ac_Header=\$ac_header_preproc"
19006 fi
19007 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19008 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19009
19010 fi
19011 if test `eval echo '${'$as_ac_Header'}'` = yes; then
19012   cat >>confdefs.h <<_ACEOF
19013 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
19014 _ACEOF
19015
19016 fi
19017
19018 done
19019
19020
19021                 if test $ac_cv_header_gnutls_gnutls_h = yes ; then
19022                         echo "$as_me:$LINENO: checking for gnutls_init in -lgnutls" >&5
19023 echo $ECHO_N "checking for gnutls_init in -lgnutls... $ECHO_C" >&6
19024 if test "${ac_cv_lib_gnutls_gnutls_init+set}" = set; then
19025   echo $ECHO_N "(cached) $ECHO_C" >&6
19026 else
19027   ac_check_lib_save_LIBS=$LIBS
19028 LIBS="-lgnutls  $LIBS"
19029 cat >conftest.$ac_ext <<_ACEOF
19030 /* confdefs.h.  */
19031 _ACEOF
19032 cat confdefs.h >>conftest.$ac_ext
19033 cat >>conftest.$ac_ext <<_ACEOF
19034 /* end confdefs.h.  */
19035
19036 /* Override any gcc2 internal prototype to avoid an error.  */
19037 #ifdef __cplusplus
19038 extern "C"
19039 #endif
19040 /* We use char because int might match the return type of a gcc2
19041    builtin and then its argument prototype would still apply.  */
19042 char gnutls_init ();
19043 int
19044 main ()
19045 {
19046 gnutls_init ();
19047   ;
19048   return 0;
19049 }
19050 _ACEOF
19051 rm -f conftest.$ac_objext conftest$ac_exeext
19052 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19053   (eval $ac_link) 2>conftest.er1
19054   ac_status=$?
19055   grep -v '^ *+' conftest.er1 >conftest.err
19056   rm -f conftest.er1
19057   cat conftest.err >&5
19058   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19059   (exit $ac_status); } &&
19060          { ac_try='test -z "$ac_c_werror_flag"
19061                          || test ! -s conftest.err'
19062   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19063   (eval $ac_try) 2>&5
19064   ac_status=$?
19065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19066   (exit $ac_status); }; } &&
19067          { ac_try='test -s conftest$ac_exeext'
19068   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19069   (eval $ac_try) 2>&5
19070   ac_status=$?
19071   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19072   (exit $ac_status); }; }; then
19073   ac_cv_lib_gnutls_gnutls_init=yes
19074 else
19075   echo "$as_me: failed program was:" >&5
19076 sed 's/^/| /' conftest.$ac_ext >&5
19077
19078 ac_cv_lib_gnutls_gnutls_init=no
19079 fi
19080 rm -f conftest.err conftest.$ac_objext \
19081       conftest$ac_exeext conftest.$ac_ext
19082 LIBS=$ac_check_lib_save_LIBS
19083 fi
19084 echo "$as_me:$LINENO: result: $ac_cv_lib_gnutls_gnutls_init" >&5
19085 echo "${ECHO_T}$ac_cv_lib_gnutls_gnutls_init" >&6
19086 if test $ac_cv_lib_gnutls_gnutls_init = yes; then
19087   have_gnutls=yes
19088 else
19089   have_gnutls=no
19090 fi
19091
19092
19093                         if test $have_gnutls = yes ; then
19094                                 ol_with_tls=gnutls
19095                                 ol_link_tls=yes
19096
19097                                 TLS_LIBS="-lgnutls"
19098
19099
19100 cat >>confdefs.h <<\_ACEOF
19101 #define HAVE_GNUTLS 1
19102 _ACEOF
19103
19104                         fi
19105                 fi
19106         fi
19107 fi
19108
19109 WITH_TLS=no
19110 if test $ol_link_tls = yes ; then
19111
19112 cat >>confdefs.h <<\_ACEOF
19113 #define HAVE_TLS 1
19114 _ACEOF
19115
19116         WITH_TLS=yes
19117 elif test $ol_with_tls = auto ; then
19118         { echo "$as_me:$LINENO: WARNING: Could not locate TLS/SSL package" >&5
19119 echo "$as_me: WARNING: Could not locate TLS/SSL package" >&2;}
19120         { echo "$as_me:$LINENO: WARNING: TLS data protection not supported!" >&5
19121 echo "$as_me: WARNING: TLS data protection not supported!" >&2;}
19122 elif test $ol_with_tls != no ; then
19123         { { echo "$as_me:$LINENO: error: Could not locate TLS/SSL package" >&5
19124 echo "$as_me: error: Could not locate TLS/SSL package" >&2;}
19125    { (exit 1); exit 1; }; }
19126 else
19127         { echo "$as_me:$LINENO: WARNING: TLS data protection not supported!" >&5
19128 echo "$as_me: WARNING: TLS data protection not supported!" >&2;}
19129 fi
19130
19131 if test $ol_enable_lmpasswd != no; then
19132         if test $ol_link_tls != yes ; then
19133                 { { echo "$as_me:$LINENO: error: LAN Manager passwords require OpenSSL" >&5
19134 echo "$as_me: error: LAN Manager passwords require OpenSSL" >&2;}
19135    { (exit 1); exit 1; }; }
19136         fi
19137
19138
19139 cat >>confdefs.h <<\_ACEOF
19140 #define SLAPD_LMHASH 1
19141 _ACEOF
19142
19143 fi
19144
19145 ol_link_threads=no
19146
19147 case $ol_with_threads in auto | yes | nt)
19148
19149
19150         echo "$as_me:$LINENO: checking for _beginthread" >&5
19151 echo $ECHO_N "checking for _beginthread... $ECHO_C" >&6
19152 if test "${ac_cv_func__beginthread+set}" = set; then
19153   echo $ECHO_N "(cached) $ECHO_C" >&6
19154 else
19155   cat >conftest.$ac_ext <<_ACEOF
19156 /* confdefs.h.  */
19157 _ACEOF
19158 cat confdefs.h >>conftest.$ac_ext
19159 cat >>conftest.$ac_ext <<_ACEOF
19160 /* end confdefs.h.  */
19161 /* Define _beginthread to an innocuous variant, in case <limits.h> declares _beginthread.
19162    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19163 #define _beginthread innocuous__beginthread
19164
19165 /* System header to define __stub macros and hopefully few prototypes,
19166     which can conflict with char _beginthread (); below.
19167     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19168     <limits.h> exists even on freestanding compilers.  */
19169
19170 #ifdef __STDC__
19171 # include <limits.h>
19172 #else
19173 # include <assert.h>
19174 #endif
19175
19176 #undef _beginthread
19177
19178 /* Override any gcc2 internal prototype to avoid an error.  */
19179 #ifdef __cplusplus
19180 extern "C"
19181 {
19182 #endif
19183 /* We use char because int might match the return type of a gcc2
19184    builtin and then its argument prototype would still apply.  */
19185 char _beginthread ();
19186 /* The GNU C library defines this for functions which it implements
19187     to always fail with ENOSYS.  Some functions are actually named
19188     something starting with __ and the normal name is an alias.  */
19189 #if defined (__stub__beginthread) || defined (__stub____beginthread)
19190 choke me
19191 #else
19192 char (*f) () = _beginthread;
19193 #endif
19194 #ifdef __cplusplus
19195 }
19196 #endif
19197
19198 int
19199 main ()
19200 {
19201 return f != _beginthread;
19202   ;
19203   return 0;
19204 }
19205 _ACEOF
19206 rm -f conftest.$ac_objext conftest$ac_exeext
19207 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19208   (eval $ac_link) 2>conftest.er1
19209   ac_status=$?
19210   grep -v '^ *+' conftest.er1 >conftest.err
19211   rm -f conftest.er1
19212   cat conftest.err >&5
19213   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19214   (exit $ac_status); } &&
19215          { ac_try='test -z "$ac_c_werror_flag"
19216                          || test ! -s conftest.err'
19217   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19218   (eval $ac_try) 2>&5
19219   ac_status=$?
19220   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19221   (exit $ac_status); }; } &&
19222          { ac_try='test -s conftest$ac_exeext'
19223   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19224   (eval $ac_try) 2>&5
19225   ac_status=$?
19226   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19227   (exit $ac_status); }; }; then
19228   ac_cv_func__beginthread=yes
19229 else
19230   echo "$as_me: failed program was:" >&5
19231 sed 's/^/| /' conftest.$ac_ext >&5
19232
19233 ac_cv_func__beginthread=no
19234 fi
19235 rm -f conftest.err conftest.$ac_objext \
19236       conftest$ac_exeext conftest.$ac_ext
19237 fi
19238 echo "$as_me:$LINENO: result: $ac_cv_func__beginthread" >&5
19239 echo "${ECHO_T}$ac_cv_func__beginthread" >&6
19240
19241
19242         if test $ac_cv_func__beginthread = yes ; then
19243
19244 cat >>confdefs.h <<\_ACEOF
19245 #define HAVE_NT_THREADS 1
19246 _ACEOF
19247
19248                 ol_cv_nt_threads=yes
19249         fi
19250
19251
19252         if test "$ol_cv_nt_threads" = yes ; then
19253                 ol_link_threads=nt
19254                 ol_with_threads=found
19255                 ol_with_yielding_select=yes
19256
19257
19258 cat >>confdefs.h <<\_ACEOF
19259 #define HAVE_NT_SERVICE_MANAGER 1
19260 _ACEOF
19261
19262
19263 cat >>confdefs.h <<\_ACEOF
19264 #define HAVE_NT_EVENT_LOG 1
19265 _ACEOF
19266
19267         fi
19268
19269         if test $ol_with_threads = nt ; then
19270                 { { echo "$as_me:$LINENO: error: could not locate NT Threads" >&5
19271 echo "$as_me: error: could not locate NT Threads" >&2;}
19272    { (exit 1); exit 1; }; }
19273         fi
19274         ;;
19275 esac
19276
19277 case $ol_with_threads in auto | yes | posix)
19278
19279
19280 for ac_header in pthread.h
19281 do
19282 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
19283 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19284   echo "$as_me:$LINENO: checking for $ac_header" >&5
19285 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19286 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19287   echo $ECHO_N "(cached) $ECHO_C" >&6
19288 fi
19289 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19290 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19291 else
19292   # Is the header compilable?
19293 echo "$as_me:$LINENO: checking $ac_header usability" >&5
19294 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19295 cat >conftest.$ac_ext <<_ACEOF
19296 /* confdefs.h.  */
19297 _ACEOF
19298 cat confdefs.h >>conftest.$ac_ext
19299 cat >>conftest.$ac_ext <<_ACEOF
19300 /* end confdefs.h.  */
19301 $ac_includes_default
19302 #include <$ac_header>
19303 _ACEOF
19304 rm -f conftest.$ac_objext
19305 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19306   (eval $ac_compile) 2>conftest.er1
19307   ac_status=$?
19308   grep -v '^ *+' conftest.er1 >conftest.err
19309   rm -f conftest.er1
19310   cat conftest.err >&5
19311   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19312   (exit $ac_status); } &&
19313          { ac_try='test -z "$ac_c_werror_flag"
19314                          || test ! -s conftest.err'
19315   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19316   (eval $ac_try) 2>&5
19317   ac_status=$?
19318   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19319   (exit $ac_status); }; } &&
19320          { ac_try='test -s conftest.$ac_objext'
19321   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19322   (eval $ac_try) 2>&5
19323   ac_status=$?
19324   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19325   (exit $ac_status); }; }; then
19326   ac_header_compiler=yes
19327 else
19328   echo "$as_me: failed program was:" >&5
19329 sed 's/^/| /' conftest.$ac_ext >&5
19330
19331 ac_header_compiler=no
19332 fi
19333 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19334 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19335 echo "${ECHO_T}$ac_header_compiler" >&6
19336
19337 # Is the header present?
19338 echo "$as_me:$LINENO: checking $ac_header presence" >&5
19339 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19340 cat >conftest.$ac_ext <<_ACEOF
19341 /* confdefs.h.  */
19342 _ACEOF
19343 cat confdefs.h >>conftest.$ac_ext
19344 cat >>conftest.$ac_ext <<_ACEOF
19345 /* end confdefs.h.  */
19346 #include <$ac_header>
19347 _ACEOF
19348 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
19349   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19350   ac_status=$?
19351   grep -v '^ *+' conftest.er1 >conftest.err
19352   rm -f conftest.er1
19353   cat conftest.err >&5
19354   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19355   (exit $ac_status); } >/dev/null; then
19356   if test -s conftest.err; then
19357     ac_cpp_err=$ac_c_preproc_warn_flag
19358     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
19359   else
19360     ac_cpp_err=
19361   fi
19362 else
19363   ac_cpp_err=yes
19364 fi
19365 if test -z "$ac_cpp_err"; then
19366   ac_header_preproc=yes
19367 else
19368   echo "$as_me: failed program was:" >&5
19369 sed 's/^/| /' conftest.$ac_ext >&5
19370
19371   ac_header_preproc=no
19372 fi
19373 rm -f conftest.err conftest.$ac_ext
19374 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19375 echo "${ECHO_T}$ac_header_preproc" >&6
19376
19377 # So?  What about this header?
19378 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19379   yes:no: )
19380     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19381 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
19382     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19383 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19384     ac_header_preproc=yes
19385     ;;
19386   no:yes:* )
19387     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19388 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
19389     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
19390 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
19391     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19392 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19393     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
19394 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
19395     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19396 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19397     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19398 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19399     (
19400       cat <<\_ASBOX
19401 ## --------------------------------------------- ##
19402 ## Report this to <http://www.openldap.org/its/> ##
19403 ## --------------------------------------------- ##
19404 _ASBOX
19405     ) |
19406       sed "s/^/$as_me: WARNING:     /" >&2
19407     ;;
19408 esac
19409 echo "$as_me:$LINENO: checking for $ac_header" >&5
19410 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19411 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19412   echo $ECHO_N "(cached) $ECHO_C" >&6
19413 else
19414   eval "$as_ac_Header=\$ac_header_preproc"
19415 fi
19416 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19417 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19418
19419 fi
19420 if test `eval echo '${'$as_ac_Header'}'` = yes; then
19421   cat >>confdefs.h <<_ACEOF
19422 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
19423 _ACEOF
19424
19425 fi
19426
19427 done
19428
19429
19430         if test $ac_cv_header_pthread_h = yes ; then
19431                 echo "$as_me:$LINENO: checking POSIX thread version" >&5
19432 echo $ECHO_N "checking POSIX thread version... $ECHO_C" >&6
19433 if test "${ol_cv_pthread_version+set}" = set; then
19434   echo $ECHO_N "(cached) $ECHO_C" >&6
19435 else
19436
19437         cat >conftest.$ac_ext <<_ACEOF
19438 /* confdefs.h.  */
19439 _ACEOF
19440 cat confdefs.h >>conftest.$ac_ext
19441 cat >>conftest.$ac_ext <<_ACEOF
19442 /* end confdefs.h.  */
19443
19444 #               include <pthread.h>
19445
19446 int
19447 main ()
19448 {
19449
19450                 int i = PTHREAD_CREATE_JOINABLE;
19451
19452   ;
19453   return 0;
19454 }
19455 _ACEOF
19456 rm -f conftest.$ac_objext
19457 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19458   (eval $ac_compile) 2>conftest.er1
19459   ac_status=$?
19460   grep -v '^ *+' conftest.er1 >conftest.err
19461   rm -f conftest.er1
19462   cat conftest.err >&5
19463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19464   (exit $ac_status); } &&
19465          { ac_try='test -z "$ac_c_werror_flag"
19466                          || test ! -s conftest.err'
19467   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19468   (eval $ac_try) 2>&5
19469   ac_status=$?
19470   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19471   (exit $ac_status); }; } &&
19472          { ac_try='test -s conftest.$ac_objext'
19473   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19474   (eval $ac_try) 2>&5
19475   ac_status=$?
19476   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19477   (exit $ac_status); }; }; then
19478
19479         cat >conftest.$ac_ext <<_ACEOF
19480 /* confdefs.h.  */
19481 _ACEOF
19482 cat confdefs.h >>conftest.$ac_ext
19483 cat >>conftest.$ac_ext <<_ACEOF
19484 /* end confdefs.h.  */
19485 #include <pthread.h>
19486
19487 _ACEOF
19488 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19489   $EGREP "pthread_detach" >/dev/null 2>&1; then
19490   ol_cv_pthread_version=10
19491 else
19492   ol_cv_pthread_version=8
19493 fi
19494 rm -f conftest*
19495
19496 else
19497   echo "$as_me: failed program was:" >&5
19498 sed 's/^/| /' conftest.$ac_ext >&5
19499
19500
19501         cat >conftest.$ac_ext <<_ACEOF
19502 /* confdefs.h.  */
19503 _ACEOF
19504 cat confdefs.h >>conftest.$ac_ext
19505 cat >>conftest.$ac_ext <<_ACEOF
19506 /* end confdefs.h.  */
19507
19508 #               include <pthread.h>
19509 #               ifdef PTHREAD_CREATE_UNDETACHED
19510                 draft7
19511 #               endif
19512
19513 _ACEOF
19514 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19515   $EGREP "draft7" >/dev/null 2>&1; then
19516   ol_cv_pthread_version=7
19517 else
19518
19519         cat >conftest.$ac_ext <<_ACEOF
19520 /* confdefs.h.  */
19521 _ACEOF
19522 cat confdefs.h >>conftest.$ac_ext
19523 cat >>conftest.$ac_ext <<_ACEOF
19524 /* end confdefs.h.  */
19525 #include <pthread.h>
19526
19527 _ACEOF
19528 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19529   $EGREP "pthread_attr_init" >/dev/null 2>&1; then
19530   ol_cv_pthread_version=6
19531 else
19532
19533         cat >conftest.$ac_ext <<_ACEOF
19534 /* confdefs.h.  */
19535 _ACEOF
19536 cat confdefs.h >>conftest.$ac_ext
19537 cat >>conftest.$ac_ext <<_ACEOF
19538 /* end confdefs.h.  */
19539
19540 #               include <pthread.h>
19541 #ifdef          PTHREAD_MUTEX_INITIALIZER
19542                 draft5
19543 #endif
19544
19545 _ACEOF
19546 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19547   $EGREP "draft5" >/dev/null 2>&1; then
19548   ol_cv_pthread_version=5
19549 else
19550   ol_cv_pthread_version=4
19551 fi
19552 rm -f conftest*
19553
19554 fi
19555 rm -f conftest*
19556
19557 fi
19558 rm -f conftest*
19559
19560 fi
19561 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19562
19563 fi
19564 echo "$as_me:$LINENO: result: $ol_cv_pthread_version" >&5
19565 echo "${ECHO_T}$ol_cv_pthread_version" >&6
19566
19567
19568                 if test $ol_cv_pthread_version != 0 ; then
19569
19570 cat >>confdefs.h <<_ACEOF
19571 #define HAVE_PTHREADS $ol_cv_pthread_version
19572 _ACEOF
19573
19574                 else
19575                         { { echo "$as_me:$LINENO: error: unknown pthread version" >&5
19576 echo "$as_me: error: unknown pthread version" >&2;}
19577    { (exit 1); exit 1; }; }
19578                 fi
19579
19580                 # consider threads found
19581                 ol_with_threads=found
19582
19583
19584         echo "$as_me:$LINENO: checking for LinuxThreads pthread.h" >&5
19585 echo $ECHO_N "checking for LinuxThreads pthread.h... $ECHO_C" >&6
19586 if test "${ol_cv_header_linux_threads+set}" = set; then
19587   echo $ECHO_N "(cached) $ECHO_C" >&6
19588 else
19589   cat >conftest.$ac_ext <<_ACEOF
19590 /* confdefs.h.  */
19591 _ACEOF
19592 cat confdefs.h >>conftest.$ac_ext
19593 cat >>conftest.$ac_ext <<_ACEOF
19594 /* end confdefs.h.  */
19595 #include <pthread.h>
19596 _ACEOF
19597 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19598   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then
19599   ol_cv_header_linux_threads=yes
19600 else
19601   ol_cv_header_linux_threads=no
19602 fi
19603 rm -f conftest*
19604
19605
19606 fi
19607 echo "$as_me:$LINENO: result: $ol_cv_header_linux_threads" >&5
19608 echo "${ECHO_T}$ol_cv_header_linux_threads" >&6
19609         if test $ol_cv_header_linux_threads = yes; then
19610
19611 cat >>confdefs.h <<\_ACEOF
19612 #define HAVE_LINUX_THREADS 1
19613 _ACEOF
19614
19615         fi
19616
19617
19618         echo "$as_me:$LINENO: checking for GNU Pth pthread.h" >&5
19619 echo $ECHO_N "checking for GNU Pth pthread.h... $ECHO_C" >&6
19620 if test "${ol_cv_header_gnu_pth_pthread_h+set}" = set; then
19621   echo $ECHO_N "(cached) $ECHO_C" >&6
19622 else
19623   cat >conftest.$ac_ext <<_ACEOF
19624 /* confdefs.h.  */
19625 _ACEOF
19626 cat confdefs.h >>conftest.$ac_ext
19627 cat >>conftest.$ac_ext <<_ACEOF
19628 /* end confdefs.h.  */
19629 #include <pthread.h>
19630 #ifdef _POSIX_THREAD_IS_GNU_PTH
19631         __gnu_pth__;
19632 #endif
19633
19634 _ACEOF
19635 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19636   $EGREP "__gnu_pth__" >/dev/null 2>&1; then
19637   ol_cv_header_gnu_pth_pthread_h=yes
19638 else
19639   ol_cv_header_gnu_pth_pthread_h=no
19640 fi
19641 rm -f conftest*
19642
19643
19644 fi
19645 echo "$as_me:$LINENO: result: $ol_cv_header_gnu_pth_pthread_h" >&5
19646 echo "${ECHO_T}$ol_cv_header_gnu_pth_pthread_h" >&6
19647
19648
19649                 if test $ol_cv_header_gnu_pth_pthread_h = no ; then
19650
19651 for ac_header in sched.h
19652 do
19653 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
19654 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19655   echo "$as_me:$LINENO: checking for $ac_header" >&5
19656 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19657 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19658   echo $ECHO_N "(cached) $ECHO_C" >&6
19659 fi
19660 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19661 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19662 else
19663   # Is the header compilable?
19664 echo "$as_me:$LINENO: checking $ac_header usability" >&5
19665 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19666 cat >conftest.$ac_ext <<_ACEOF
19667 /* confdefs.h.  */
19668 _ACEOF
19669 cat confdefs.h >>conftest.$ac_ext
19670 cat >>conftest.$ac_ext <<_ACEOF
19671 /* end confdefs.h.  */
19672 $ac_includes_default
19673 #include <$ac_header>
19674 _ACEOF
19675 rm -f conftest.$ac_objext
19676 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19677   (eval $ac_compile) 2>conftest.er1
19678   ac_status=$?
19679   grep -v '^ *+' conftest.er1 >conftest.err
19680   rm -f conftest.er1
19681   cat conftest.err >&5
19682   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19683   (exit $ac_status); } &&
19684          { ac_try='test -z "$ac_c_werror_flag"
19685                          || test ! -s conftest.err'
19686   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19687   (eval $ac_try) 2>&5
19688   ac_status=$?
19689   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19690   (exit $ac_status); }; } &&
19691          { ac_try='test -s conftest.$ac_objext'
19692   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19693   (eval $ac_try) 2>&5
19694   ac_status=$?
19695   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19696   (exit $ac_status); }; }; then
19697   ac_header_compiler=yes
19698 else
19699   echo "$as_me: failed program was:" >&5
19700 sed 's/^/| /' conftest.$ac_ext >&5
19701
19702 ac_header_compiler=no
19703 fi
19704 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19705 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19706 echo "${ECHO_T}$ac_header_compiler" >&6
19707
19708 # Is the header present?
19709 echo "$as_me:$LINENO: checking $ac_header presence" >&5
19710 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19711 cat >conftest.$ac_ext <<_ACEOF
19712 /* confdefs.h.  */
19713 _ACEOF
19714 cat confdefs.h >>conftest.$ac_ext
19715 cat >>conftest.$ac_ext <<_ACEOF
19716 /* end confdefs.h.  */
19717 #include <$ac_header>
19718 _ACEOF
19719 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
19720   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19721   ac_status=$?
19722   grep -v '^ *+' conftest.er1 >conftest.err
19723   rm -f conftest.er1
19724   cat conftest.err >&5
19725   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19726   (exit $ac_status); } >/dev/null; then
19727   if test -s conftest.err; then
19728     ac_cpp_err=$ac_c_preproc_warn_flag
19729     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
19730   else
19731     ac_cpp_err=
19732   fi
19733 else
19734   ac_cpp_err=yes
19735 fi
19736 if test -z "$ac_cpp_err"; then
19737   ac_header_preproc=yes
19738 else
19739   echo "$as_me: failed program was:" >&5
19740 sed 's/^/| /' conftest.$ac_ext >&5
19741
19742   ac_header_preproc=no
19743 fi
19744 rm -f conftest.err conftest.$ac_ext
19745 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19746 echo "${ECHO_T}$ac_header_preproc" >&6
19747
19748 # So?  What about this header?
19749 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19750   yes:no: )
19751     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19752 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
19753     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19754 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19755     ac_header_preproc=yes
19756     ;;
19757   no:yes:* )
19758     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19759 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
19760     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
19761 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
19762     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19763 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19764     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
19765 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
19766     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19767 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19768     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19769 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19770     (
19771       cat <<\_ASBOX
19772 ## --------------------------------------------- ##
19773 ## Report this to <http://www.openldap.org/its/> ##
19774 ## --------------------------------------------- ##
19775 _ASBOX
19776     ) |
19777       sed "s/^/$as_me: WARNING:     /" >&2
19778     ;;
19779 esac
19780 echo "$as_me:$LINENO: checking for $ac_header" >&5
19781 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19782 if eval "test \"\${$as_ac_Header+set}\" = set"; then
19783   echo $ECHO_N "(cached) $ECHO_C" >&6
19784 else
19785   eval "$as_ac_Header=\$ac_header_preproc"
19786 fi
19787 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19788 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19789
19790 fi
19791 if test `eval echo '${'$as_ac_Header'}'` = yes; then
19792   cat >>confdefs.h <<_ACEOF
19793 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
19794 _ACEOF
19795
19796 fi
19797
19798 done
19799
19800                 fi
19801
19802
19803                                 echo "$as_me:$LINENO: checking for pthread_create in default libraries" >&5
19804 echo $ECHO_N "checking for pthread_create in default libraries... $ECHO_C" >&6
19805 if test "${ol_cv_pthread_create+set}" = set; then
19806   echo $ECHO_N "(cached) $ECHO_C" >&6
19807 else
19808
19809                         if test "$cross_compiling" = yes; then
19810   cat >conftest.$ac_ext <<_ACEOF
19811 /* confdefs.h.  */
19812 _ACEOF
19813 cat confdefs.h >>conftest.$ac_ext
19814 cat >>conftest.$ac_ext <<_ACEOF
19815 /* end confdefs.h.  */
19816
19817 /* pthread test headers */
19818 #include <pthread.h>
19819 #if HAVE_PTHREADS < 7
19820 #include <errno.h>
19821 #endif
19822 #ifndef NULL
19823 #define NULL (void*)0
19824 #endif
19825
19826 static void *task(p)
19827         void *p;
19828 {
19829         return (void *) (p == NULL);
19830 }
19831
19832 int
19833 main ()
19834 {
19835
19836         /* pthread test function */
19837 #ifndef PTHREAD_CREATE_DETACHED
19838 #define PTHREAD_CREATE_DETACHED 1
19839 #endif
19840         pthread_t t;
19841         int status;
19842         int detach = PTHREAD_CREATE_DETACHED;
19843
19844 #if HAVE_PTHREADS > 4
19845         /* Final pthreads */
19846         pthread_attr_t attr;
19847
19848         status = pthread_attr_init(&attr);
19849         if( status ) return status;
19850
19851 #if HAVE_PTHREADS < 7
19852         status = pthread_attr_setdetachstate(&attr, &detach);
19853         if( status < 0 ) status = errno;
19854 #else
19855         status = pthread_attr_setdetachstate(&attr, detach);
19856 #endif
19857         if( status ) return status;
19858         status = pthread_create( &t, &attr, task, NULL );
19859 #if HAVE_PTHREADS < 7
19860         if( status < 0 ) status = errno;
19861 #endif
19862         if( status ) return status;
19863 #else
19864         /* Draft 4 pthreads */
19865         status = pthread_create( &t, pthread_attr_default, task, NULL );
19866         if( status ) return errno;
19867
19868         /* give thread a chance to complete */
19869         /* it should remain joinable and hence detachable */
19870         sleep( 1 );
19871
19872         status = pthread_detach( &t );
19873         if( status ) return errno;
19874 #endif
19875
19876 #ifdef HAVE_LINUX_THREADS
19877         pthread_kill_other_threads_np();
19878 #endif
19879
19880         return 0;
19881
19882   ;
19883   return 0;
19884 }
19885 _ACEOF
19886 rm -f conftest.$ac_objext conftest$ac_exeext
19887 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19888   (eval $ac_link) 2>conftest.er1
19889   ac_status=$?
19890   grep -v '^ *+' conftest.er1 >conftest.err
19891   rm -f conftest.er1
19892   cat conftest.err >&5
19893   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19894   (exit $ac_status); } &&
19895          { ac_try='test -z "$ac_c_werror_flag"
19896                          || test ! -s conftest.err'
19897   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19898   (eval $ac_try) 2>&5
19899   ac_status=$?
19900   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19901   (exit $ac_status); }; } &&
19902          { ac_try='test -s conftest$ac_exeext'
19903   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19904   (eval $ac_try) 2>&5
19905   ac_status=$?
19906   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19907   (exit $ac_status); }; }; then
19908   ol_cv_pthread_create=yes
19909 else
19910   echo "$as_me: failed program was:" >&5
19911 sed 's/^/| /' conftest.$ac_ext >&5
19912
19913 ol_cv_pthread_create=no
19914 fi
19915 rm -f conftest.err conftest.$ac_objext \
19916       conftest$ac_exeext conftest.$ac_ext
19917 else
19918   cat >conftest.$ac_ext <<_ACEOF
19919 /* confdefs.h.  */
19920 _ACEOF
19921 cat confdefs.h >>conftest.$ac_ext
19922 cat >>conftest.$ac_ext <<_ACEOF
19923 /* end confdefs.h.  */
19924
19925 /* pthread test headers */
19926 #include <pthread.h>
19927 #if HAVE_PTHREADS < 7
19928 #include <errno.h>
19929 #endif
19930 #ifndef NULL
19931 #define NULL (void*)0
19932 #endif
19933
19934 static void *task(p)
19935         void *p;
19936 {
19937         return (void *) (p == NULL);
19938 }
19939
19940
19941 int main(argc, argv)
19942         int argc;
19943         char **argv;
19944 {
19945
19946         /* pthread test function */
19947 #ifndef PTHREAD_CREATE_DETACHED
19948 #define PTHREAD_CREATE_DETACHED 1
19949 #endif
19950         pthread_t t;
19951         int status;
19952         int detach = PTHREAD_CREATE_DETACHED;
19953
19954 #if HAVE_PTHREADS > 4
19955         /* Final pthreads */
19956         pthread_attr_t attr;
19957
19958         status = pthread_attr_init(&attr);
19959         if( status ) return status;
19960
19961 #if HAVE_PTHREADS < 7
19962         status = pthread_attr_setdetachstate(&attr, &detach);
19963         if( status < 0 ) status = errno;
19964 #else
19965         status = pthread_attr_setdetachstate(&attr, detach);
19966 #endif
19967         if( status ) return status;
19968         status = pthread_create( &t, &attr, task, NULL );
19969 #if HAVE_PTHREADS < 7
19970         if( status < 0 ) status = errno;
19971 #endif
19972         if( status ) return status;
19973 #else
19974         /* Draft 4 pthreads */
19975         status = pthread_create( &t, pthread_attr_default, task, NULL );
19976         if( status ) return errno;
19977
19978         /* give thread a chance to complete */
19979         /* it should remain joinable and hence detachable */
19980         sleep( 1 );
19981
19982         status = pthread_detach( &t );
19983         if( status ) return errno;
19984 #endif
19985
19986 #ifdef HAVE_LINUX_THREADS
19987         pthread_kill_other_threads_np();
19988 #endif
19989
19990         return 0;
19991
19992 }
19993
19994 _ACEOF
19995 rm -f conftest$ac_exeext
19996 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19997   (eval $ac_link) 2>&5
19998   ac_status=$?
19999   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20000   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20001   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20002   (eval $ac_try) 2>&5
20003   ac_status=$?
20004   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20005   (exit $ac_status); }; }; then
20006   ol_cv_pthread_create=yes
20007 else
20008   echo "$as_me: program exited with status $ac_status" >&5
20009 echo "$as_me: failed program was:" >&5
20010 sed 's/^/| /' conftest.$ac_ext >&5
20011
20012 ( exit $ac_status )
20013 ol_cv_pthread_create=no
20014 fi
20015 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20016 fi
20017 fi
20018 echo "$as_me:$LINENO: result: $ol_cv_pthread_create" >&5
20019 echo "${ECHO_T}$ol_cv_pthread_create" >&6
20020
20021                 if test $ol_cv_pthread_create != no ; then
20022                         ol_link_threads=posix
20023                         ol_link_pthreads=""
20024                 fi
20025
20026                 # Pthread try link: -kthread (ol_cv_pthread_kthread)
20027 if test "$ol_link_threads" = no ; then
20028         # try -kthread
20029         echo "$as_me:$LINENO: checking for pthread link with -kthread" >&5
20030 echo $ECHO_N "checking for pthread link with -kthread... $ECHO_C" >&6
20031 if test "${ol_cv_pthread_kthread+set}" = set; then
20032   echo $ECHO_N "(cached) $ECHO_C" >&6
20033 else
20034
20035                 # save the flags
20036                 ol_LIBS="$LIBS"
20037                 LIBS="-kthread $LIBS"
20038
20039                 if test "$cross_compiling" = yes; then
20040   cat >conftest.$ac_ext <<_ACEOF
20041 /* confdefs.h.  */
20042 _ACEOF
20043 cat confdefs.h >>conftest.$ac_ext
20044 cat >>conftest.$ac_ext <<_ACEOF
20045 /* end confdefs.h.  */
20046
20047 /* pthread test headers */
20048 #include <pthread.h>
20049 #if HAVE_PTHREADS < 7
20050 #include <errno.h>
20051 #endif
20052 #ifndef NULL
20053 #define NULL (void*)0
20054 #endif
20055
20056 static void *task(p)
20057         void *p;
20058 {
20059         return (void *) (p == NULL);
20060 }
20061
20062 int
20063 main ()
20064 {
20065
20066         /* pthread test function */
20067 #ifndef PTHREAD_CREATE_DETACHED
20068 #define PTHREAD_CREATE_DETACHED 1
20069 #endif
20070         pthread_t t;
20071         int status;
20072         int detach = PTHREAD_CREATE_DETACHED;
20073
20074 #if HAVE_PTHREADS > 4
20075         /* Final pthreads */
20076         pthread_attr_t attr;
20077
20078         status = pthread_attr_init(&attr);
20079         if( status ) return status;
20080
20081 #if HAVE_PTHREADS < 7
20082         status = pthread_attr_setdetachstate(&attr, &detach);
20083         if( status < 0 ) status = errno;
20084 #else
20085         status = pthread_attr_setdetachstate(&attr, detach);
20086 #endif
20087         if( status ) return status;
20088         status = pthread_create( &t, &attr, task, NULL );
20089 #if HAVE_PTHREADS < 7
20090         if( status < 0 ) status = errno;
20091 #endif
20092         if( status ) return status;
20093 #else
20094         /* Draft 4 pthreads */
20095         status = pthread_create( &t, pthread_attr_default, task, NULL );
20096         if( status ) return errno;
20097
20098         /* give thread a chance to complete */
20099         /* it should remain joinable and hence detachable */
20100         sleep( 1 );
20101
20102         status = pthread_detach( &t );
20103         if( status ) return errno;
20104 #endif
20105
20106 #ifdef HAVE_LINUX_THREADS
20107         pthread_kill_other_threads_np();
20108 #endif
20109
20110         return 0;
20111
20112   ;
20113   return 0;
20114 }
20115 _ACEOF
20116 rm -f conftest.$ac_objext conftest$ac_exeext
20117 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20118   (eval $ac_link) 2>conftest.er1
20119   ac_status=$?
20120   grep -v '^ *+' conftest.er1 >conftest.err
20121   rm -f conftest.er1
20122   cat conftest.err >&5
20123   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20124   (exit $ac_status); } &&
20125          { ac_try='test -z "$ac_c_werror_flag"
20126                          || test ! -s conftest.err'
20127   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20128   (eval $ac_try) 2>&5
20129   ac_status=$?
20130   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20131   (exit $ac_status); }; } &&
20132          { ac_try='test -s conftest$ac_exeext'
20133   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20134   (eval $ac_try) 2>&5
20135   ac_status=$?
20136   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20137   (exit $ac_status); }; }; then
20138   ol_cv_pthread_kthread=yes
20139 else
20140   echo "$as_me: failed program was:" >&5
20141 sed 's/^/| /' conftest.$ac_ext >&5
20142
20143 ol_cv_pthread_kthread=no
20144 fi
20145 rm -f conftest.err conftest.$ac_objext \
20146       conftest$ac_exeext conftest.$ac_ext
20147 else
20148   cat >conftest.$ac_ext <<_ACEOF
20149 /* confdefs.h.  */
20150 _ACEOF
20151 cat confdefs.h >>conftest.$ac_ext
20152 cat >>conftest.$ac_ext <<_ACEOF
20153 /* end confdefs.h.  */
20154
20155 /* pthread test headers */
20156 #include <pthread.h>
20157 #if HAVE_PTHREADS < 7
20158 #include <errno.h>
20159 #endif
20160 #ifndef NULL
20161 #define NULL (void*)0
20162 #endif
20163
20164 static void *task(p)
20165         void *p;
20166 {
20167         return (void *) (p == NULL);
20168 }
20169
20170
20171 int main(argc, argv)
20172         int argc;
20173         char **argv;
20174 {
20175
20176         /* pthread test function */
20177 #ifndef PTHREAD_CREATE_DETACHED
20178 #define PTHREAD_CREATE_DETACHED 1
20179 #endif
20180         pthread_t t;
20181         int status;
20182         int detach = PTHREAD_CREATE_DETACHED;
20183
20184 #if HAVE_PTHREADS > 4
20185         /* Final pthreads */
20186         pthread_attr_t attr;
20187
20188         status = pthread_attr_init(&attr);
20189         if( status ) return status;
20190
20191 #if HAVE_PTHREADS < 7
20192         status = pthread_attr_setdetachstate(&attr, &detach);
20193         if( status < 0 ) status = errno;
20194 #else
20195         status = pthread_attr_setdetachstate(&attr, detach);
20196 #endif
20197         if( status ) return status;
20198         status = pthread_create( &t, &attr, task, NULL );
20199 #if HAVE_PTHREADS < 7
20200         if( status < 0 ) status = errno;
20201 #endif
20202         if( status ) return status;
20203 #else
20204         /* Draft 4 pthreads */
20205         status = pthread_create( &t, pthread_attr_default, task, NULL );
20206         if( status ) return errno;
20207
20208         /* give thread a chance to complete */
20209         /* it should remain joinable and hence detachable */
20210         sleep( 1 );
20211
20212         status = pthread_detach( &t );
20213         if( status ) return errno;
20214 #endif
20215
20216 #ifdef HAVE_LINUX_THREADS
20217         pthread_kill_other_threads_np();
20218 #endif
20219
20220         return 0;
20221
20222 }
20223
20224 _ACEOF
20225 rm -f conftest$ac_exeext
20226 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20227   (eval $ac_link) 2>&5
20228   ac_status=$?
20229   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20230   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20231   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20232   (eval $ac_try) 2>&5
20233   ac_status=$?
20234   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20235   (exit $ac_status); }; }; then
20236   ol_cv_pthread_kthread=yes
20237 else
20238   echo "$as_me: program exited with status $ac_status" >&5
20239 echo "$as_me: failed program was:" >&5
20240 sed 's/^/| /' conftest.$ac_ext >&5
20241
20242 ( exit $ac_status )
20243 ol_cv_pthread_kthread=no
20244 fi
20245 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20246 fi
20247
20248                 # restore the LIBS
20249                 LIBS="$ol_LIBS"
20250
20251 fi
20252 echo "$as_me:$LINENO: result: $ol_cv_pthread_kthread" >&5
20253 echo "${ECHO_T}$ol_cv_pthread_kthread" >&6
20254
20255         if test $ol_cv_pthread_kthread = yes ; then
20256                 ol_link_pthreads="-kthread"
20257                 ol_link_threads=posix
20258         fi
20259 fi
20260
20261                 # Pthread try link: -pthread (ol_cv_pthread_pthread)
20262 if test "$ol_link_threads" = no ; then
20263         # try -pthread
20264         echo "$as_me:$LINENO: checking for pthread link with -pthread" >&5
20265 echo $ECHO_N "checking for pthread link with -pthread... $ECHO_C" >&6
20266 if test "${ol_cv_pthread_pthread+set}" = set; then
20267   echo $ECHO_N "(cached) $ECHO_C" >&6
20268 else
20269
20270                 # save the flags
20271                 ol_LIBS="$LIBS"
20272                 LIBS="-pthread $LIBS"
20273
20274                 if test "$cross_compiling" = yes; then
20275   cat >conftest.$ac_ext <<_ACEOF
20276 /* confdefs.h.  */
20277 _ACEOF
20278 cat confdefs.h >>conftest.$ac_ext
20279 cat >>conftest.$ac_ext <<_ACEOF
20280 /* end confdefs.h.  */
20281
20282 /* pthread test headers */
20283 #include <pthread.h>
20284 #if HAVE_PTHREADS < 7
20285 #include <errno.h>
20286 #endif
20287 #ifndef NULL
20288 #define NULL (void*)0
20289 #endif
20290
20291 static void *task(p)
20292         void *p;
20293 {
20294         return (void *) (p == NULL);
20295 }
20296
20297 int
20298 main ()
20299 {
20300
20301         /* pthread test function */
20302 #ifndef PTHREAD_CREATE_DETACHED
20303 #define PTHREAD_CREATE_DETACHED 1
20304 #endif
20305         pthread_t t;
20306         int status;
20307         int detach = PTHREAD_CREATE_DETACHED;
20308
20309 #if HAVE_PTHREADS > 4
20310         /* Final pthreads */
20311         pthread_attr_t attr;
20312
20313         status = pthread_attr_init(&attr);
20314         if( status ) return status;
20315
20316 #if HAVE_PTHREADS < 7
20317         status = pthread_attr_setdetachstate(&attr, &detach);
20318         if( status < 0 ) status = errno;
20319 #else
20320         status = pthread_attr_setdetachstate(&attr, detach);
20321 #endif
20322         if( status ) return status;
20323         status = pthread_create( &t, &attr, task, NULL );
20324 #if HAVE_PTHREADS < 7
20325         if( status < 0 ) status = errno;
20326 #endif
20327         if( status ) return status;
20328 #else
20329         /* Draft 4 pthreads */
20330         status = pthread_create( &t, pthread_attr_default, task, NULL );
20331         if( status ) return errno;
20332
20333         /* give thread a chance to complete */
20334         /* it should remain joinable and hence detachable */
20335         sleep( 1 );
20336
20337         status = pthread_detach( &t );
20338         if( status ) return errno;
20339 #endif
20340
20341 #ifdef HAVE_LINUX_THREADS
20342         pthread_kill_other_threads_np();
20343 #endif
20344
20345         return 0;
20346
20347   ;
20348   return 0;
20349 }
20350 _ACEOF
20351 rm -f conftest.$ac_objext conftest$ac_exeext
20352 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20353   (eval $ac_link) 2>conftest.er1
20354   ac_status=$?
20355   grep -v '^ *+' conftest.er1 >conftest.err
20356   rm -f conftest.er1
20357   cat conftest.err >&5
20358   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20359   (exit $ac_status); } &&
20360          { ac_try='test -z "$ac_c_werror_flag"
20361                          || test ! -s conftest.err'
20362   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20363   (eval $ac_try) 2>&5
20364   ac_status=$?
20365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20366   (exit $ac_status); }; } &&
20367          { ac_try='test -s conftest$ac_exeext'
20368   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20369   (eval $ac_try) 2>&5
20370   ac_status=$?
20371   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20372   (exit $ac_status); }; }; then
20373   ol_cv_pthread_pthread=yes
20374 else
20375   echo "$as_me: failed program was:" >&5
20376 sed 's/^/| /' conftest.$ac_ext >&5
20377
20378 ol_cv_pthread_pthread=no
20379 fi
20380 rm -f conftest.err conftest.$ac_objext \
20381       conftest$ac_exeext conftest.$ac_ext
20382 else
20383   cat >conftest.$ac_ext <<_ACEOF
20384 /* confdefs.h.  */
20385 _ACEOF
20386 cat confdefs.h >>conftest.$ac_ext
20387 cat >>conftest.$ac_ext <<_ACEOF
20388 /* end confdefs.h.  */
20389
20390 /* pthread test headers */
20391 #include <pthread.h>
20392 #if HAVE_PTHREADS < 7
20393 #include <errno.h>
20394 #endif
20395 #ifndef NULL
20396 #define NULL (void*)0
20397 #endif
20398
20399 static void *task(p)
20400         void *p;
20401 {
20402         return (void *) (p == NULL);
20403 }
20404
20405
20406 int main(argc, argv)
20407         int argc;
20408         char **argv;
20409 {
20410
20411         /* pthread test function */
20412 #ifndef PTHREAD_CREATE_DETACHED
20413 #define PTHREAD_CREATE_DETACHED 1
20414 #endif
20415         pthread_t t;
20416         int status;
20417         int detach = PTHREAD_CREATE_DETACHED;
20418
20419 #if HAVE_PTHREADS > 4
20420         /* Final pthreads */
20421         pthread_attr_t attr;
20422
20423         status = pthread_attr_init(&attr);
20424         if( status ) return status;
20425
20426 #if HAVE_PTHREADS < 7
20427         status = pthread_attr_setdetachstate(&attr, &detach);
20428         if( status < 0 ) status = errno;
20429 #else
20430         status = pthread_attr_setdetachstate(&attr, detach);
20431 #endif
20432         if( status ) return status;
20433         status = pthread_create( &t, &attr, task, NULL );
20434 #if HAVE_PTHREADS < 7
20435         if( status < 0 ) status = errno;
20436 #endif
20437         if( status ) return status;
20438 #else
20439         /* Draft 4 pthreads */
20440         status = pthread_create( &t, pthread_attr_default, task, NULL );
20441         if( status ) return errno;
20442
20443         /* give thread a chance to complete */
20444         /* it should remain joinable and hence detachable */
20445         sleep( 1 );
20446
20447         status = pthread_detach( &t );
20448         if( status ) return errno;
20449 #endif
20450
20451 #ifdef HAVE_LINUX_THREADS
20452         pthread_kill_other_threads_np();
20453 #endif
20454
20455         return 0;
20456
20457 }
20458
20459 _ACEOF
20460 rm -f conftest$ac_exeext
20461 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20462   (eval $ac_link) 2>&5
20463   ac_status=$?
20464   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20465   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20466   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20467   (eval $ac_try) 2>&5
20468   ac_status=$?
20469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20470   (exit $ac_status); }; }; then
20471   ol_cv_pthread_pthread=yes
20472 else
20473   echo "$as_me: program exited with status $ac_status" >&5
20474 echo "$as_me: failed program was:" >&5
20475 sed 's/^/| /' conftest.$ac_ext >&5
20476
20477 ( exit $ac_status )
20478 ol_cv_pthread_pthread=no
20479 fi
20480 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20481 fi
20482
20483                 # restore the LIBS
20484                 LIBS="$ol_LIBS"
20485
20486 fi
20487 echo "$as_me:$LINENO: result: $ol_cv_pthread_pthread" >&5
20488 echo "${ECHO_T}$ol_cv_pthread_pthread" >&6
20489
20490         if test $ol_cv_pthread_pthread = yes ; then
20491                 ol_link_pthreads="-pthread"
20492                 ol_link_threads=posix
20493         fi
20494 fi
20495
20496                 # Pthread try link: -pthreads (ol_cv_pthread_pthreads)
20497 if test "$ol_link_threads" = no ; then
20498         # try -pthreads
20499         echo "$as_me:$LINENO: checking for pthread link with -pthreads" >&5
20500 echo $ECHO_N "checking for pthread link with -pthreads... $ECHO_C" >&6
20501 if test "${ol_cv_pthread_pthreads+set}" = set; then
20502   echo $ECHO_N "(cached) $ECHO_C" >&6
20503 else
20504
20505                 # save the flags
20506                 ol_LIBS="$LIBS"
20507                 LIBS="-pthreads $LIBS"
20508
20509                 if test "$cross_compiling" = yes; then
20510   cat >conftest.$ac_ext <<_ACEOF
20511 /* confdefs.h.  */
20512 _ACEOF
20513 cat confdefs.h >>conftest.$ac_ext
20514 cat >>conftest.$ac_ext <<_ACEOF
20515 /* end confdefs.h.  */
20516
20517 /* pthread test headers */
20518 #include <pthread.h>
20519 #if HAVE_PTHREADS < 7
20520 #include <errno.h>
20521 #endif
20522 #ifndef NULL
20523 #define NULL (void*)0
20524 #endif
20525
20526 static void *task(p)
20527         void *p;
20528 {
20529         return (void *) (p == NULL);
20530 }
20531
20532 int
20533 main ()
20534 {
20535
20536         /* pthread test function */
20537 #ifndef PTHREAD_CREATE_DETACHED
20538 #define PTHREAD_CREATE_DETACHED 1
20539 #endif
20540         pthread_t t;
20541         int status;
20542         int detach = PTHREAD_CREATE_DETACHED;
20543
20544 #if HAVE_PTHREADS > 4
20545         /* Final pthreads */
20546         pthread_attr_t attr;
20547
20548         status = pthread_attr_init(&attr);
20549         if( status ) return status;
20550
20551 #if HAVE_PTHREADS < 7
20552         status = pthread_attr_setdetachstate(&attr, &detach);
20553         if( status < 0 ) status = errno;
20554 #else
20555         status = pthread_attr_setdetachstate(&attr, detach);
20556 #endif
20557         if( status ) return status;
20558         status = pthread_create( &t, &attr, task, NULL );
20559 #if HAVE_PTHREADS < 7
20560         if( status < 0 ) status = errno;
20561 #endif
20562         if( status ) return status;
20563 #else
20564         /* Draft 4 pthreads */
20565         status = pthread_create( &t, pthread_attr_default, task, NULL );
20566         if( status ) return errno;
20567
20568         /* give thread a chance to complete */
20569         /* it should remain joinable and hence detachable */
20570         sleep( 1 );
20571
20572         status = pthread_detach( &t );
20573         if( status ) return errno;
20574 #endif
20575
20576 #ifdef HAVE_LINUX_THREADS
20577         pthread_kill_other_threads_np();
20578 #endif
20579
20580         return 0;
20581
20582   ;
20583   return 0;
20584 }
20585 _ACEOF
20586 rm -f conftest.$ac_objext conftest$ac_exeext
20587 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20588   (eval $ac_link) 2>conftest.er1
20589   ac_status=$?
20590   grep -v '^ *+' conftest.er1 >conftest.err
20591   rm -f conftest.er1
20592   cat conftest.err >&5
20593   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20594   (exit $ac_status); } &&
20595          { ac_try='test -z "$ac_c_werror_flag"
20596                          || test ! -s conftest.err'
20597   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20598   (eval $ac_try) 2>&5
20599   ac_status=$?
20600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20601   (exit $ac_status); }; } &&
20602          { ac_try='test -s conftest$ac_exeext'
20603   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20604   (eval $ac_try) 2>&5
20605   ac_status=$?
20606   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20607   (exit $ac_status); }; }; then
20608   ol_cv_pthread_pthreads=yes
20609 else
20610   echo "$as_me: failed program was:" >&5
20611 sed 's/^/| /' conftest.$ac_ext >&5
20612
20613 ol_cv_pthread_pthreads=no
20614 fi
20615 rm -f conftest.err conftest.$ac_objext \
20616       conftest$ac_exeext conftest.$ac_ext
20617 else
20618   cat >conftest.$ac_ext <<_ACEOF
20619 /* confdefs.h.  */
20620 _ACEOF
20621 cat confdefs.h >>conftest.$ac_ext
20622 cat >>conftest.$ac_ext <<_ACEOF
20623 /* end confdefs.h.  */
20624
20625 /* pthread test headers */
20626 #include <pthread.h>
20627 #if HAVE_PTHREADS < 7
20628 #include <errno.h>
20629 #endif
20630 #ifndef NULL
20631 #define NULL (void*)0
20632 #endif
20633
20634 static void *task(p)
20635         void *p;
20636 {
20637         return (void *) (p == NULL);
20638 }
20639
20640
20641 int main(argc, argv)
20642         int argc;
20643         char **argv;
20644 {
20645
20646         /* pthread test function */
20647 #ifndef PTHREAD_CREATE_DETACHED
20648 #define PTHREAD_CREATE_DETACHED 1
20649 #endif
20650         pthread_t t;
20651         int status;
20652         int detach = PTHREAD_CREATE_DETACHED;
20653
20654 #if HAVE_PTHREADS > 4
20655         /* Final pthreads */
20656         pthread_attr_t attr;
20657
20658         status = pthread_attr_init(&attr);
20659         if( status ) return status;
20660
20661 #if HAVE_PTHREADS < 7
20662         status = pthread_attr_setdetachstate(&attr, &detach);
20663         if( status < 0 ) status = errno;
20664 #else
20665         status = pthread_attr_setdetachstate(&attr, detach);
20666 #endif
20667         if( status ) return status;
20668         status = pthread_create( &t, &attr, task, NULL );
20669 #if HAVE_PTHREADS < 7
20670         if( status < 0 ) status = errno;
20671 #endif
20672         if( status ) return status;
20673 #else
20674         /* Draft 4 pthreads */
20675         status = pthread_create( &t, pthread_attr_default, task, NULL );
20676         if( status ) return errno;
20677
20678         /* give thread a chance to complete */
20679         /* it should remain joinable and hence detachable */
20680         sleep( 1 );
20681
20682         status = pthread_detach( &t );
20683         if( status ) return errno;
20684 #endif
20685
20686 #ifdef HAVE_LINUX_THREADS
20687         pthread_kill_other_threads_np();
20688 #endif
20689
20690         return 0;
20691
20692 }
20693
20694 _ACEOF
20695 rm -f conftest$ac_exeext
20696 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20697   (eval $ac_link) 2>&5
20698   ac_status=$?
20699   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20700   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20701   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20702   (eval $ac_try) 2>&5
20703   ac_status=$?
20704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20705   (exit $ac_status); }; }; then
20706   ol_cv_pthread_pthreads=yes
20707 else
20708   echo "$as_me: program exited with status $ac_status" >&5
20709 echo "$as_me: failed program was:" >&5
20710 sed 's/^/| /' conftest.$ac_ext >&5
20711
20712 ( exit $ac_status )
20713 ol_cv_pthread_pthreads=no
20714 fi
20715 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20716 fi
20717
20718                 # restore the LIBS
20719                 LIBS="$ol_LIBS"
20720
20721 fi
20722 echo "$as_me:$LINENO: result: $ol_cv_pthread_pthreads" >&5
20723 echo "${ECHO_T}$ol_cv_pthread_pthreads" >&6
20724
20725         if test $ol_cv_pthread_pthreads = yes ; then
20726                 ol_link_pthreads="-pthreads"
20727                 ol_link_threads=posix
20728         fi
20729 fi
20730
20731                 # Pthread try link: -mthreads (ol_cv_pthread_mthreads)
20732 if test "$ol_link_threads" = no ; then
20733         # try -mthreads
20734         echo "$as_me:$LINENO: checking for pthread link with -mthreads" >&5
20735 echo $ECHO_N "checking for pthread link with -mthreads... $ECHO_C" >&6
20736 if test "${ol_cv_pthread_mthreads+set}" = set; then
20737   echo $ECHO_N "(cached) $ECHO_C" >&6
20738 else
20739
20740                 # save the flags
20741                 ol_LIBS="$LIBS"
20742                 LIBS="-mthreads $LIBS"
20743
20744                 if test "$cross_compiling" = yes; then
20745   cat >conftest.$ac_ext <<_ACEOF
20746 /* confdefs.h.  */
20747 _ACEOF
20748 cat confdefs.h >>conftest.$ac_ext
20749 cat >>conftest.$ac_ext <<_ACEOF
20750 /* end confdefs.h.  */
20751
20752 /* pthread test headers */
20753 #include <pthread.h>
20754 #if HAVE_PTHREADS < 7
20755 #include <errno.h>
20756 #endif
20757 #ifndef NULL
20758 #define NULL (void*)0
20759 #endif
20760
20761 static void *task(p)
20762         void *p;
20763 {
20764         return (void *) (p == NULL);
20765 }
20766
20767 int
20768 main ()
20769 {
20770
20771         /* pthread test function */
20772 #ifndef PTHREAD_CREATE_DETACHED
20773 #define PTHREAD_CREATE_DETACHED 1
20774 #endif
20775         pthread_t t;
20776         int status;
20777         int detach = PTHREAD_CREATE_DETACHED;
20778
20779 #if HAVE_PTHREADS > 4
20780         /* Final pthreads */
20781         pthread_attr_t attr;
20782
20783         status = pthread_attr_init(&attr);
20784         if( status ) return status;
20785
20786 #if HAVE_PTHREADS < 7
20787         status = pthread_attr_setdetachstate(&attr, &detach);
20788         if( status < 0 ) status = errno;
20789 #else
20790         status = pthread_attr_setdetachstate(&attr, detach);
20791 #endif
20792         if( status ) return status;
20793         status = pthread_create( &t, &attr, task, NULL );
20794 #if HAVE_PTHREADS < 7
20795         if( status < 0 ) status = errno;
20796 #endif
20797         if( status ) return status;
20798 #else
20799         /* Draft 4 pthreads */
20800         status = pthread_create( &t, pthread_attr_default, task, NULL );
20801         if( status ) return errno;
20802
20803         /* give thread a chance to complete */
20804         /* it should remain joinable and hence detachable */
20805         sleep( 1 );
20806
20807         status = pthread_detach( &t );
20808         if( status ) return errno;
20809 #endif
20810
20811 #ifdef HAVE_LINUX_THREADS
20812         pthread_kill_other_threads_np();
20813 #endif
20814
20815         return 0;
20816
20817   ;
20818   return 0;
20819 }
20820 _ACEOF
20821 rm -f conftest.$ac_objext conftest$ac_exeext
20822 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20823   (eval $ac_link) 2>conftest.er1
20824   ac_status=$?
20825   grep -v '^ *+' conftest.er1 >conftest.err
20826   rm -f conftest.er1
20827   cat conftest.err >&5
20828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20829   (exit $ac_status); } &&
20830          { ac_try='test -z "$ac_c_werror_flag"
20831                          || test ! -s conftest.err'
20832   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20833   (eval $ac_try) 2>&5
20834   ac_status=$?
20835   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20836   (exit $ac_status); }; } &&
20837          { ac_try='test -s conftest$ac_exeext'
20838   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20839   (eval $ac_try) 2>&5
20840   ac_status=$?
20841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20842   (exit $ac_status); }; }; then
20843   ol_cv_pthread_mthreads=yes
20844 else
20845   echo "$as_me: failed program was:" >&5
20846 sed 's/^/| /' conftest.$ac_ext >&5
20847
20848 ol_cv_pthread_mthreads=no
20849 fi
20850 rm -f conftest.err conftest.$ac_objext \
20851       conftest$ac_exeext conftest.$ac_ext
20852 else
20853   cat >conftest.$ac_ext <<_ACEOF
20854 /* confdefs.h.  */
20855 _ACEOF
20856 cat confdefs.h >>conftest.$ac_ext
20857 cat >>conftest.$ac_ext <<_ACEOF
20858 /* end confdefs.h.  */
20859
20860 /* pthread test headers */
20861 #include <pthread.h>
20862 #if HAVE_PTHREADS < 7
20863 #include <errno.h>
20864 #endif
20865 #ifndef NULL
20866 #define NULL (void*)0
20867 #endif
20868
20869 static void *task(p)
20870         void *p;
20871 {
20872         return (void *) (p == NULL);
20873 }
20874
20875
20876 int main(argc, argv)
20877         int argc;
20878         char **argv;
20879 {
20880
20881         /* pthread test function */
20882 #ifndef PTHREAD_CREATE_DETACHED
20883 #define PTHREAD_CREATE_DETACHED 1
20884 #endif
20885         pthread_t t;
20886         int status;
20887         int detach = PTHREAD_CREATE_DETACHED;
20888
20889 #if HAVE_PTHREADS > 4
20890         /* Final pthreads */
20891         pthread_attr_t attr;
20892
20893         status = pthread_attr_init(&attr);
20894         if( status ) return status;
20895
20896 #if HAVE_PTHREADS < 7
20897         status = pthread_attr_setdetachstate(&attr, &detach);
20898         if( status < 0 ) status = errno;
20899 #else
20900         status = pthread_attr_setdetachstate(&attr, detach);
20901 #endif
20902         if( status ) return status;
20903         status = pthread_create( &t, &attr, task, NULL );
20904 #if HAVE_PTHREADS < 7
20905         if( status < 0 ) status = errno;
20906 #endif
20907         if( status ) return status;
20908 #else
20909         /* Draft 4 pthreads */
20910         status = pthread_create( &t, pthread_attr_default, task, NULL );
20911         if( status ) return errno;
20912
20913         /* give thread a chance to complete */
20914         /* it should remain joinable and hence detachable */
20915         sleep( 1 );
20916
20917         status = pthread_detach( &t );
20918         if( status ) return errno;
20919 #endif
20920
20921 #ifdef HAVE_LINUX_THREADS
20922         pthread_kill_other_threads_np();
20923 #endif
20924
20925         return 0;
20926
20927 }
20928
20929 _ACEOF
20930 rm -f conftest$ac_exeext
20931 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20932   (eval $ac_link) 2>&5
20933   ac_status=$?
20934   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20935   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20936   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20937   (eval $ac_try) 2>&5
20938   ac_status=$?
20939   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20940   (exit $ac_status); }; }; then
20941   ol_cv_pthread_mthreads=yes
20942 else
20943   echo "$as_me: program exited with status $ac_status" >&5
20944 echo "$as_me: failed program was:" >&5
20945 sed 's/^/| /' conftest.$ac_ext >&5
20946
20947 ( exit $ac_status )
20948 ol_cv_pthread_mthreads=no
20949 fi
20950 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20951 fi
20952
20953                 # restore the LIBS
20954                 LIBS="$ol_LIBS"
20955
20956 fi
20957 echo "$as_me:$LINENO: result: $ol_cv_pthread_mthreads" >&5
20958 echo "${ECHO_T}$ol_cv_pthread_mthreads" >&6
20959
20960         if test $ol_cv_pthread_mthreads = yes ; then
20961                 ol_link_pthreads="-mthreads"
20962                 ol_link_threads=posix
20963         fi
20964 fi
20965
20966                 # Pthread try link: -thread (ol_cv_pthread_thread)
20967 if test "$ol_link_threads" = no ; then
20968         # try -thread
20969         echo "$as_me:$LINENO: checking for pthread link with -thread" >&5
20970 echo $ECHO_N "checking for pthread link with -thread... $ECHO_C" >&6
20971 if test "${ol_cv_pthread_thread+set}" = set; then
20972   echo $ECHO_N "(cached) $ECHO_C" >&6
20973 else
20974
20975                 # save the flags
20976                 ol_LIBS="$LIBS"
20977                 LIBS="-thread $LIBS"
20978
20979                 if test "$cross_compiling" = yes; then
20980   cat >conftest.$ac_ext <<_ACEOF
20981 /* confdefs.h.  */
20982 _ACEOF
20983 cat confdefs.h >>conftest.$ac_ext
20984 cat >>conftest.$ac_ext <<_ACEOF
20985 /* end confdefs.h.  */
20986
20987 /* pthread test headers */
20988 #include <pthread.h>
20989 #if HAVE_PTHREADS < 7
20990 #include <errno.h>
20991 #endif
20992 #ifndef NULL
20993 #define NULL (void*)0
20994 #endif
20995
20996 static void *task(p)
20997         void *p;
20998 {
20999         return (void *) (p == NULL);
21000 }
21001
21002 int
21003 main ()
21004 {
21005
21006         /* pthread test function */
21007 #ifndef PTHREAD_CREATE_DETACHED
21008 #define PTHREAD_CREATE_DETACHED 1
21009 #endif
21010         pthread_t t;
21011         int status;
21012         int detach = PTHREAD_CREATE_DETACHED;
21013
21014 #if HAVE_PTHREADS > 4
21015         /* Final pthreads */
21016         pthread_attr_t attr;
21017
21018         status = pthread_attr_init(&attr);
21019         if( status ) return status;
21020
21021 #if HAVE_PTHREADS < 7
21022         status = pthread_attr_setdetachstate(&attr, &detach);
21023         if( status < 0 ) status = errno;
21024 #else
21025         status = pthread_attr_setdetachstate(&attr, detach);
21026 #endif
21027         if( status ) return status;
21028         status = pthread_create( &t, &attr, task, NULL );
21029 #if HAVE_PTHREADS < 7
21030         if( status < 0 ) status = errno;
21031 #endif
21032         if( status ) return status;
21033 #else
21034         /* Draft 4 pthreads */
21035         status = pthread_create( &t, pthread_attr_default, task, NULL );
21036         if( status ) return errno;
21037
21038         /* give thread a chance to complete */
21039         /* it should remain joinable and hence detachable */
21040         sleep( 1 );
21041
21042         status = pthread_detach( &t );
21043         if( status ) return errno;
21044 #endif
21045
21046 #ifdef HAVE_LINUX_THREADS
21047         pthread_kill_other_threads_np();
21048 #endif
21049
21050         return 0;
21051
21052   ;
21053   return 0;
21054 }
21055 _ACEOF
21056 rm -f conftest.$ac_objext conftest$ac_exeext
21057 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21058   (eval $ac_link) 2>conftest.er1
21059   ac_status=$?
21060   grep -v '^ *+' conftest.er1 >conftest.err
21061   rm -f conftest.er1
21062   cat conftest.err >&5
21063   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21064   (exit $ac_status); } &&
21065          { ac_try='test -z "$ac_c_werror_flag"
21066                          || test ! -s conftest.err'
21067   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21068   (eval $ac_try) 2>&5
21069   ac_status=$?
21070   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21071   (exit $ac_status); }; } &&
21072          { ac_try='test -s conftest$ac_exeext'
21073   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21074   (eval $ac_try) 2>&5
21075   ac_status=$?
21076   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21077   (exit $ac_status); }; }; then
21078   ol_cv_pthread_thread=yes
21079 else
21080   echo "$as_me: failed program was:" >&5
21081 sed 's/^/| /' conftest.$ac_ext >&5
21082
21083 ol_cv_pthread_thread=no
21084 fi
21085 rm -f conftest.err conftest.$ac_objext \
21086       conftest$ac_exeext conftest.$ac_ext
21087 else
21088   cat >conftest.$ac_ext <<_ACEOF
21089 /* confdefs.h.  */
21090 _ACEOF
21091 cat confdefs.h >>conftest.$ac_ext
21092 cat >>conftest.$ac_ext <<_ACEOF
21093 /* end confdefs.h.  */
21094
21095 /* pthread test headers */
21096 #include <pthread.h>
21097 #if HAVE_PTHREADS < 7
21098 #include <errno.h>
21099 #endif
21100 #ifndef NULL
21101 #define NULL (void*)0
21102 #endif
21103
21104 static void *task(p)
21105         void *p;
21106 {
21107         return (void *) (p == NULL);
21108 }
21109
21110
21111 int main(argc, argv)
21112         int argc;
21113         char **argv;
21114 {
21115
21116         /* pthread test function */
21117 #ifndef PTHREAD_CREATE_DETACHED
21118 #define PTHREAD_CREATE_DETACHED 1
21119 #endif
21120         pthread_t t;
21121         int status;
21122         int detach = PTHREAD_CREATE_DETACHED;
21123
21124 #if HAVE_PTHREADS > 4
21125         /* Final pthreads */
21126         pthread_attr_t attr;
21127
21128         status = pthread_attr_init(&attr);
21129         if( status ) return status;
21130
21131 #if HAVE_PTHREADS < 7
21132         status = pthread_attr_setdetachstate(&attr, &detach);
21133         if( status < 0 ) status = errno;
21134 #else
21135         status = pthread_attr_setdetachstate(&attr, detach);
21136 #endif
21137         if( status ) return status;
21138         status = pthread_create( &t, &attr, task, NULL );
21139 #if HAVE_PTHREADS < 7
21140         if( status < 0 ) status = errno;
21141 #endif
21142         if( status ) return status;
21143 #else
21144         /* Draft 4 pthreads */
21145         status = pthread_create( &t, pthread_attr_default, task, NULL );
21146         if( status ) return errno;
21147
21148         /* give thread a chance to complete */
21149         /* it should remain joinable and hence detachable */
21150         sleep( 1 );
21151
21152         status = pthread_detach( &t );
21153         if( status ) return errno;
21154 #endif
21155
21156 #ifdef HAVE_LINUX_THREADS
21157         pthread_kill_other_threads_np();
21158 #endif
21159
21160         return 0;
21161
21162 }
21163
21164 _ACEOF
21165 rm -f conftest$ac_exeext
21166 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21167   (eval $ac_link) 2>&5
21168   ac_status=$?
21169   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21170   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21171   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21172   (eval $ac_try) 2>&5
21173   ac_status=$?
21174   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21175   (exit $ac_status); }; }; then
21176   ol_cv_pthread_thread=yes
21177 else
21178   echo "$as_me: program exited with status $ac_status" >&5
21179 echo "$as_me: failed program was:" >&5
21180 sed 's/^/| /' conftest.$ac_ext >&5
21181
21182 ( exit $ac_status )
21183 ol_cv_pthread_thread=no
21184 fi
21185 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21186 fi
21187
21188                 # restore the LIBS
21189                 LIBS="$ol_LIBS"
21190
21191 fi
21192 echo "$as_me:$LINENO: result: $ol_cv_pthread_thread" >&5
21193 echo "${ECHO_T}$ol_cv_pthread_thread" >&6
21194
21195         if test $ol_cv_pthread_thread = yes ; then
21196                 ol_link_pthreads="-thread"
21197                 ol_link_threads=posix
21198         fi
21199 fi
21200
21201
21202                 # Pthread try link: -lpthread -lmach -lexc -lc_r (ol_cv_pthread_lpthread_lmach_lexc_lc_r)
21203 if test "$ol_link_threads" = no ; then
21204         # try -lpthread -lmach -lexc -lc_r
21205         echo "$as_me:$LINENO: checking for pthread link with -lpthread -lmach -lexc -lc_r" >&5
21206 echo $ECHO_N "checking for pthread link with -lpthread -lmach -lexc -lc_r... $ECHO_C" >&6
21207 if test "${ol_cv_pthread_lpthread_lmach_lexc_lc_r+set}" = set; then
21208   echo $ECHO_N "(cached) $ECHO_C" >&6
21209 else
21210
21211                 # save the flags
21212                 ol_LIBS="$LIBS"
21213                 LIBS="-lpthread -lmach -lexc -lc_r $LIBS"
21214
21215                 if test "$cross_compiling" = yes; then
21216   cat >conftest.$ac_ext <<_ACEOF
21217 /* confdefs.h.  */
21218 _ACEOF
21219 cat confdefs.h >>conftest.$ac_ext
21220 cat >>conftest.$ac_ext <<_ACEOF
21221 /* end confdefs.h.  */
21222
21223 /* pthread test headers */
21224 #include <pthread.h>
21225 #if HAVE_PTHREADS < 7
21226 #include <errno.h>
21227 #endif
21228 #ifndef NULL
21229 #define NULL (void*)0
21230 #endif
21231
21232 static void *task(p)
21233         void *p;
21234 {
21235         return (void *) (p == NULL);
21236 }
21237
21238 int
21239 main ()
21240 {
21241
21242         /* pthread test function */
21243 #ifndef PTHREAD_CREATE_DETACHED
21244 #define PTHREAD_CREATE_DETACHED 1
21245 #endif
21246         pthread_t t;
21247         int status;
21248         int detach = PTHREAD_CREATE_DETACHED;
21249
21250 #if HAVE_PTHREADS > 4
21251         /* Final pthreads */
21252         pthread_attr_t attr;
21253
21254         status = pthread_attr_init(&attr);
21255         if( status ) return status;
21256
21257 #if HAVE_PTHREADS < 7
21258         status = pthread_attr_setdetachstate(&attr, &detach);
21259         if( status < 0 ) status = errno;
21260 #else
21261         status = pthread_attr_setdetachstate(&attr, detach);
21262 #endif
21263         if( status ) return status;
21264         status = pthread_create( &t, &attr, task, NULL );
21265 #if HAVE_PTHREADS < 7
21266         if( status < 0 ) status = errno;
21267 #endif
21268         if( status ) return status;
21269 #else
21270         /* Draft 4 pthreads */
21271         status = pthread_create( &t, pthread_attr_default, task, NULL );
21272         if( status ) return errno;
21273
21274         /* give thread a chance to complete */
21275         /* it should remain joinable and hence detachable */
21276         sleep( 1 );
21277
21278         status = pthread_detach( &t );
21279         if( status ) return errno;
21280 #endif
21281
21282 #ifdef HAVE_LINUX_THREADS
21283         pthread_kill_other_threads_np();
21284 #endif
21285
21286         return 0;
21287
21288   ;
21289   return 0;
21290 }
21291 _ACEOF
21292 rm -f conftest.$ac_objext conftest$ac_exeext
21293 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21294   (eval $ac_link) 2>conftest.er1
21295   ac_status=$?
21296   grep -v '^ *+' conftest.er1 >conftest.err
21297   rm -f conftest.er1
21298   cat conftest.err >&5
21299   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21300   (exit $ac_status); } &&
21301          { ac_try='test -z "$ac_c_werror_flag"
21302                          || test ! -s conftest.err'
21303   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21304   (eval $ac_try) 2>&5
21305   ac_status=$?
21306   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21307   (exit $ac_status); }; } &&
21308          { ac_try='test -s conftest$ac_exeext'
21309   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21310   (eval $ac_try) 2>&5
21311   ac_status=$?
21312   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21313   (exit $ac_status); }; }; then
21314   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
21315 else
21316   echo "$as_me: failed program was:" >&5
21317 sed 's/^/| /' conftest.$ac_ext >&5
21318
21319 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
21320 fi
21321 rm -f conftest.err conftest.$ac_objext \
21322       conftest$ac_exeext conftest.$ac_ext
21323 else
21324   cat >conftest.$ac_ext <<_ACEOF
21325 /* confdefs.h.  */
21326 _ACEOF
21327 cat confdefs.h >>conftest.$ac_ext
21328 cat >>conftest.$ac_ext <<_ACEOF
21329 /* end confdefs.h.  */
21330
21331 /* pthread test headers */
21332 #include <pthread.h>
21333 #if HAVE_PTHREADS < 7
21334 #include <errno.h>
21335 #endif
21336 #ifndef NULL
21337 #define NULL (void*)0
21338 #endif
21339
21340 static void *task(p)
21341         void *p;
21342 {
21343         return (void *) (p == NULL);
21344 }
21345
21346
21347 int main(argc, argv)
21348         int argc;
21349         char **argv;
21350 {
21351
21352         /* pthread test function */
21353 #ifndef PTHREAD_CREATE_DETACHED
21354 #define PTHREAD_CREATE_DETACHED 1
21355 #endif
21356         pthread_t t;
21357         int status;
21358         int detach = PTHREAD_CREATE_DETACHED;
21359
21360 #if HAVE_PTHREADS > 4
21361         /* Final pthreads */
21362         pthread_attr_t attr;
21363
21364         status = pthread_attr_init(&attr);
21365         if( status ) return status;
21366
21367 #if HAVE_PTHREADS < 7
21368         status = pthread_attr_setdetachstate(&attr, &detach);
21369         if( status < 0 ) status = errno;
21370 #else
21371         status = pthread_attr_setdetachstate(&attr, detach);
21372 #endif
21373         if( status ) return status;
21374         status = pthread_create( &t, &attr, task, NULL );
21375 #if HAVE_PTHREADS < 7
21376         if( status < 0 ) status = errno;
21377 #endif
21378         if( status ) return status;
21379 #else
21380         /* Draft 4 pthreads */
21381         status = pthread_create( &t, pthread_attr_default, task, NULL );
21382         if( status ) return errno;
21383
21384         /* give thread a chance to complete */
21385         /* it should remain joinable and hence detachable */
21386         sleep( 1 );
21387
21388         status = pthread_detach( &t );
21389         if( status ) return errno;
21390 #endif
21391
21392 #ifdef HAVE_LINUX_THREADS
21393         pthread_kill_other_threads_np();
21394 #endif
21395
21396         return 0;
21397
21398 }
21399
21400 _ACEOF
21401 rm -f conftest$ac_exeext
21402 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21403   (eval $ac_link) 2>&5
21404   ac_status=$?
21405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21406   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21407   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21408   (eval $ac_try) 2>&5
21409   ac_status=$?
21410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21411   (exit $ac_status); }; }; then
21412   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
21413 else
21414   echo "$as_me: program exited with status $ac_status" >&5
21415 echo "$as_me: failed program was:" >&5
21416 sed 's/^/| /' conftest.$ac_ext >&5
21417
21418 ( exit $ac_status )
21419 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
21420 fi
21421 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21422 fi
21423
21424                 # restore the LIBS
21425                 LIBS="$ol_LIBS"
21426
21427 fi
21428 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&5
21429 echo "${ECHO_T}$ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&6
21430
21431         if test $ol_cv_pthread_lpthread_lmach_lexc_lc_r = yes ; then
21432                 ol_link_pthreads="-lpthread -lmach -lexc -lc_r"
21433                 ol_link_threads=posix
21434         fi
21435 fi
21436
21437                 # Pthread try link: -lpthread -lmach -lexc (ol_cv_pthread_lpthread_lmach_lexc)
21438 if test "$ol_link_threads" = no ; then
21439         # try -lpthread -lmach -lexc
21440         echo "$as_me:$LINENO: checking for pthread link with -lpthread -lmach -lexc" >&5
21441 echo $ECHO_N "checking for pthread link with -lpthread -lmach -lexc... $ECHO_C" >&6
21442 if test "${ol_cv_pthread_lpthread_lmach_lexc+set}" = set; then
21443   echo $ECHO_N "(cached) $ECHO_C" >&6
21444 else
21445
21446                 # save the flags
21447                 ol_LIBS="$LIBS"
21448                 LIBS="-lpthread -lmach -lexc $LIBS"
21449
21450                 if test "$cross_compiling" = yes; then
21451   cat >conftest.$ac_ext <<_ACEOF
21452 /* confdefs.h.  */
21453 _ACEOF
21454 cat confdefs.h >>conftest.$ac_ext
21455 cat >>conftest.$ac_ext <<_ACEOF
21456 /* end confdefs.h.  */
21457
21458 /* pthread test headers */
21459 #include <pthread.h>
21460 #if HAVE_PTHREADS < 7
21461 #include <errno.h>
21462 #endif
21463 #ifndef NULL
21464 #define NULL (void*)0
21465 #endif
21466
21467 static void *task(p)
21468         void *p;
21469 {
21470         return (void *) (p == NULL);
21471 }
21472
21473 int
21474 main ()
21475 {
21476
21477         /* pthread test function */
21478 #ifndef PTHREAD_CREATE_DETACHED
21479 #define PTHREAD_CREATE_DETACHED 1
21480 #endif
21481         pthread_t t;
21482         int status;
21483         int detach = PTHREAD_CREATE_DETACHED;
21484
21485 #if HAVE_PTHREADS > 4
21486         /* Final pthreads */
21487         pthread_attr_t attr;
21488
21489         status = pthread_attr_init(&attr);
21490         if( status ) return status;
21491
21492 #if HAVE_PTHREADS < 7
21493         status = pthread_attr_setdetachstate(&attr, &detach);
21494         if( status < 0 ) status = errno;
21495 #else
21496         status = pthread_attr_setdetachstate(&attr, detach);
21497 #endif
21498         if( status ) return status;
21499         status = pthread_create( &t, &attr, task, NULL );
21500 #if HAVE_PTHREADS < 7
21501         if( status < 0 ) status = errno;
21502 #endif
21503         if( status ) return status;
21504 #else
21505         /* Draft 4 pthreads */
21506         status = pthread_create( &t, pthread_attr_default, task, NULL );
21507         if( status ) return errno;
21508
21509         /* give thread a chance to complete */
21510         /* it should remain joinable and hence detachable */
21511         sleep( 1 );
21512
21513         status = pthread_detach( &t );
21514         if( status ) return errno;
21515 #endif
21516
21517 #ifdef HAVE_LINUX_THREADS
21518         pthread_kill_other_threads_np();
21519 #endif
21520
21521         return 0;
21522
21523   ;
21524   return 0;
21525 }
21526 _ACEOF
21527 rm -f conftest.$ac_objext conftest$ac_exeext
21528 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21529   (eval $ac_link) 2>conftest.er1
21530   ac_status=$?
21531   grep -v '^ *+' conftest.er1 >conftest.err
21532   rm -f conftest.er1
21533   cat conftest.err >&5
21534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21535   (exit $ac_status); } &&
21536          { ac_try='test -z "$ac_c_werror_flag"
21537                          || test ! -s conftest.err'
21538   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21539   (eval $ac_try) 2>&5
21540   ac_status=$?
21541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21542   (exit $ac_status); }; } &&
21543          { ac_try='test -s conftest$ac_exeext'
21544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21545   (eval $ac_try) 2>&5
21546   ac_status=$?
21547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21548   (exit $ac_status); }; }; then
21549   ol_cv_pthread_lpthread_lmach_lexc=yes
21550 else
21551   echo "$as_me: failed program was:" >&5
21552 sed 's/^/| /' conftest.$ac_ext >&5
21553
21554 ol_cv_pthread_lpthread_lmach_lexc=no
21555 fi
21556 rm -f conftest.err conftest.$ac_objext \
21557       conftest$ac_exeext conftest.$ac_ext
21558 else
21559   cat >conftest.$ac_ext <<_ACEOF
21560 /* confdefs.h.  */
21561 _ACEOF
21562 cat confdefs.h >>conftest.$ac_ext
21563 cat >>conftest.$ac_ext <<_ACEOF
21564 /* end confdefs.h.  */
21565
21566 /* pthread test headers */
21567 #include <pthread.h>
21568 #if HAVE_PTHREADS < 7
21569 #include <errno.h>
21570 #endif
21571 #ifndef NULL
21572 #define NULL (void*)0
21573 #endif
21574
21575 static void *task(p)
21576         void *p;
21577 {
21578         return (void *) (p == NULL);
21579 }
21580
21581
21582 int main(argc, argv)
21583         int argc;
21584         char **argv;
21585 {
21586
21587         /* pthread test function */
21588 #ifndef PTHREAD_CREATE_DETACHED
21589 #define PTHREAD_CREATE_DETACHED 1
21590 #endif
21591         pthread_t t;
21592         int status;
21593         int detach = PTHREAD_CREATE_DETACHED;
21594
21595 #if HAVE_PTHREADS > 4
21596         /* Final pthreads */
21597         pthread_attr_t attr;
21598
21599         status = pthread_attr_init(&attr);
21600         if( status ) return status;
21601
21602 #if HAVE_PTHREADS < 7
21603         status = pthread_attr_setdetachstate(&attr, &detach);
21604         if( status < 0 ) status = errno;
21605 #else
21606         status = pthread_attr_setdetachstate(&attr, detach);
21607 #endif
21608         if( status ) return status;
21609         status = pthread_create( &t, &attr, task, NULL );
21610 #if HAVE_PTHREADS < 7
21611         if( status < 0 ) status = errno;
21612 #endif
21613         if( status ) return status;
21614 #else
21615         /* Draft 4 pthreads */
21616         status = pthread_create( &t, pthread_attr_default, task, NULL );
21617         if( status ) return errno;
21618
21619         /* give thread a chance to complete */
21620         /* it should remain joinable and hence detachable */
21621         sleep( 1 );
21622
21623         status = pthread_detach( &t );
21624         if( status ) return errno;
21625 #endif
21626
21627 #ifdef HAVE_LINUX_THREADS
21628         pthread_kill_other_threads_np();
21629 #endif
21630
21631         return 0;
21632
21633 }
21634
21635 _ACEOF
21636 rm -f conftest$ac_exeext
21637 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21638   (eval $ac_link) 2>&5
21639   ac_status=$?
21640   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21641   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21642   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21643   (eval $ac_try) 2>&5
21644   ac_status=$?
21645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21646   (exit $ac_status); }; }; then
21647   ol_cv_pthread_lpthread_lmach_lexc=yes
21648 else
21649   echo "$as_me: program exited with status $ac_status" >&5
21650 echo "$as_me: failed program was:" >&5
21651 sed 's/^/| /' conftest.$ac_ext >&5
21652
21653 ( exit $ac_status )
21654 ol_cv_pthread_lpthread_lmach_lexc=no
21655 fi
21656 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21657 fi
21658
21659                 # restore the LIBS
21660                 LIBS="$ol_LIBS"
21661
21662 fi
21663 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread_lmach_lexc" >&5
21664 echo "${ECHO_T}$ol_cv_pthread_lpthread_lmach_lexc" >&6
21665
21666         if test $ol_cv_pthread_lpthread_lmach_lexc = yes ; then
21667                 ol_link_pthreads="-lpthread -lmach -lexc"
21668                 ol_link_threads=posix
21669         fi
21670 fi
21671
21672
21673                 # Pthread try link: -lpthread -Wl,-woff,85 (ol_cv_pthread_lib_lpthread_woff)
21674 if test "$ol_link_threads" = no ; then
21675         # try -lpthread -Wl,-woff,85
21676         echo "$as_me:$LINENO: checking for pthread link with -lpthread -Wl,-woff,85" >&5
21677 echo $ECHO_N "checking for pthread link with -lpthread -Wl,-woff,85... $ECHO_C" >&6
21678 if test "${ol_cv_pthread_lib_lpthread_woff+set}" = set; then
21679   echo $ECHO_N "(cached) $ECHO_C" >&6
21680 else
21681
21682                 # save the flags
21683                 ol_LIBS="$LIBS"
21684                 LIBS="-lpthread -Wl,-woff,85 $LIBS"
21685
21686                 if test "$cross_compiling" = yes; then
21687   cat >conftest.$ac_ext <<_ACEOF
21688 /* confdefs.h.  */
21689 _ACEOF
21690 cat confdefs.h >>conftest.$ac_ext
21691 cat >>conftest.$ac_ext <<_ACEOF
21692 /* end confdefs.h.  */
21693
21694 /* pthread test headers */
21695 #include <pthread.h>
21696 #if HAVE_PTHREADS < 7
21697 #include <errno.h>
21698 #endif
21699 #ifndef NULL
21700 #define NULL (void*)0
21701 #endif
21702
21703 static void *task(p)
21704         void *p;
21705 {
21706         return (void *) (p == NULL);
21707 }
21708
21709 int
21710 main ()
21711 {
21712
21713         /* pthread test function */
21714 #ifndef PTHREAD_CREATE_DETACHED
21715 #define PTHREAD_CREATE_DETACHED 1
21716 #endif
21717         pthread_t t;
21718         int status;
21719         int detach = PTHREAD_CREATE_DETACHED;
21720
21721 #if HAVE_PTHREADS > 4
21722         /* Final pthreads */
21723         pthread_attr_t attr;
21724
21725         status = pthread_attr_init(&attr);
21726         if( status ) return status;
21727
21728 #if HAVE_PTHREADS < 7
21729         status = pthread_attr_setdetachstate(&attr, &detach);
21730         if( status < 0 ) status = errno;
21731 #else
21732         status = pthread_attr_setdetachstate(&attr, detach);
21733 #endif
21734         if( status ) return status;
21735         status = pthread_create( &t, &attr, task, NULL );
21736 #if HAVE_PTHREADS < 7
21737         if( status < 0 ) status = errno;
21738 #endif
21739         if( status ) return status;
21740 #else
21741         /* Draft 4 pthreads */
21742         status = pthread_create( &t, pthread_attr_default, task, NULL );
21743         if( status ) return errno;
21744
21745         /* give thread a chance to complete */
21746         /* it should remain joinable and hence detachable */
21747         sleep( 1 );
21748
21749         status = pthread_detach( &t );
21750         if( status ) return errno;
21751 #endif
21752
21753 #ifdef HAVE_LINUX_THREADS
21754         pthread_kill_other_threads_np();
21755 #endif
21756
21757         return 0;
21758
21759   ;
21760   return 0;
21761 }
21762 _ACEOF
21763 rm -f conftest.$ac_objext conftest$ac_exeext
21764 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21765   (eval $ac_link) 2>conftest.er1
21766   ac_status=$?
21767   grep -v '^ *+' conftest.er1 >conftest.err
21768   rm -f conftest.er1
21769   cat conftest.err >&5
21770   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21771   (exit $ac_status); } &&
21772          { ac_try='test -z "$ac_c_werror_flag"
21773                          || test ! -s conftest.err'
21774   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21775   (eval $ac_try) 2>&5
21776   ac_status=$?
21777   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21778   (exit $ac_status); }; } &&
21779          { ac_try='test -s conftest$ac_exeext'
21780   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21781   (eval $ac_try) 2>&5
21782   ac_status=$?
21783   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21784   (exit $ac_status); }; }; then
21785   ol_cv_pthread_lib_lpthread_woff=yes
21786 else
21787   echo "$as_me: failed program was:" >&5
21788 sed 's/^/| /' conftest.$ac_ext >&5
21789
21790 ol_cv_pthread_lib_lpthread_woff=no
21791 fi
21792 rm -f conftest.err conftest.$ac_objext \
21793       conftest$ac_exeext conftest.$ac_ext
21794 else
21795   cat >conftest.$ac_ext <<_ACEOF
21796 /* confdefs.h.  */
21797 _ACEOF
21798 cat confdefs.h >>conftest.$ac_ext
21799 cat >>conftest.$ac_ext <<_ACEOF
21800 /* end confdefs.h.  */
21801
21802 /* pthread test headers */
21803 #include <pthread.h>
21804 #if HAVE_PTHREADS < 7
21805 #include <errno.h>
21806 #endif
21807 #ifndef NULL
21808 #define NULL (void*)0
21809 #endif
21810
21811 static void *task(p)
21812         void *p;
21813 {
21814         return (void *) (p == NULL);
21815 }
21816
21817
21818 int main(argc, argv)
21819         int argc;
21820         char **argv;
21821 {
21822
21823         /* pthread test function */
21824 #ifndef PTHREAD_CREATE_DETACHED
21825 #define PTHREAD_CREATE_DETACHED 1
21826 #endif
21827         pthread_t t;
21828         int status;
21829         int detach = PTHREAD_CREATE_DETACHED;
21830
21831 #if HAVE_PTHREADS > 4
21832         /* Final pthreads */
21833         pthread_attr_t attr;
21834
21835         status = pthread_attr_init(&attr);
21836         if( status ) return status;
21837
21838 #if HAVE_PTHREADS < 7
21839         status = pthread_attr_setdetachstate(&attr, &detach);
21840         if( status < 0 ) status = errno;
21841 #else
21842         status = pthread_attr_setdetachstate(&attr, detach);
21843 #endif
21844         if( status ) return status;
21845         status = pthread_create( &t, &attr, task, NULL );
21846 #if HAVE_PTHREADS < 7
21847         if( status < 0 ) status = errno;
21848 #endif
21849         if( status ) return status;
21850 #else
21851         /* Draft 4 pthreads */
21852         status = pthread_create( &t, pthread_attr_default, task, NULL );
21853         if( status ) return errno;
21854
21855         /* give thread a chance to complete */
21856         /* it should remain joinable and hence detachable */
21857         sleep( 1 );
21858
21859         status = pthread_detach( &t );
21860         if( status ) return errno;
21861 #endif
21862
21863 #ifdef HAVE_LINUX_THREADS
21864         pthread_kill_other_threads_np();
21865 #endif
21866
21867         return 0;
21868
21869 }
21870
21871 _ACEOF
21872 rm -f conftest$ac_exeext
21873 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21874   (eval $ac_link) 2>&5
21875   ac_status=$?
21876   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21877   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21878   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21879   (eval $ac_try) 2>&5
21880   ac_status=$?
21881   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21882   (exit $ac_status); }; }; then
21883   ol_cv_pthread_lib_lpthread_woff=yes
21884 else
21885   echo "$as_me: program exited with status $ac_status" >&5
21886 echo "$as_me: failed program was:" >&5
21887 sed 's/^/| /' conftest.$ac_ext >&5
21888
21889 ( exit $ac_status )
21890 ol_cv_pthread_lib_lpthread_woff=no
21891 fi
21892 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21893 fi
21894
21895                 # restore the LIBS
21896                 LIBS="$ol_LIBS"
21897
21898 fi
21899 echo "$as_me:$LINENO: result: $ol_cv_pthread_lib_lpthread_woff" >&5
21900 echo "${ECHO_T}$ol_cv_pthread_lib_lpthread_woff" >&6
21901
21902         if test $ol_cv_pthread_lib_lpthread_woff = yes ; then
21903                 ol_link_pthreads="-lpthread -Wl,-woff,85"
21904                 ol_link_threads=posix
21905         fi
21906 fi
21907
21908
21909                 # Pthread try link: -lpthread (ol_cv_pthread_lpthread)
21910 if test "$ol_link_threads" = no ; then
21911         # try -lpthread
21912         echo "$as_me:$LINENO: checking for pthread link with -lpthread" >&5
21913 echo $ECHO_N "checking for pthread link with -lpthread... $ECHO_C" >&6
21914 if test "${ol_cv_pthread_lpthread+set}" = set; then
21915   echo $ECHO_N "(cached) $ECHO_C" >&6
21916 else
21917
21918                 # save the flags
21919                 ol_LIBS="$LIBS"
21920                 LIBS="-lpthread $LIBS"
21921
21922                 if test "$cross_compiling" = yes; then
21923   cat >conftest.$ac_ext <<_ACEOF
21924 /* confdefs.h.  */
21925 _ACEOF
21926 cat confdefs.h >>conftest.$ac_ext
21927 cat >>conftest.$ac_ext <<_ACEOF
21928 /* end confdefs.h.  */
21929
21930 /* pthread test headers */
21931 #include <pthread.h>
21932 #if HAVE_PTHREADS < 7
21933 #include <errno.h>
21934 #endif
21935 #ifndef NULL
21936 #define NULL (void*)0
21937 #endif
21938
21939 static void *task(p)
21940         void *p;
21941 {
21942         return (void *) (p == NULL);
21943 }
21944
21945 int
21946 main ()
21947 {
21948
21949         /* pthread test function */
21950 #ifndef PTHREAD_CREATE_DETACHED
21951 #define PTHREAD_CREATE_DETACHED 1
21952 #endif
21953         pthread_t t;
21954         int status;
21955         int detach = PTHREAD_CREATE_DETACHED;
21956
21957 #if HAVE_PTHREADS > 4
21958         /* Final pthreads */
21959         pthread_attr_t attr;
21960
21961         status = pthread_attr_init(&attr);
21962         if( status ) return status;
21963
21964 #if HAVE_PTHREADS < 7
21965         status = pthread_attr_setdetachstate(&attr, &detach);
21966         if( status < 0 ) status = errno;
21967 #else
21968         status = pthread_attr_setdetachstate(&attr, detach);
21969 #endif
21970         if( status ) return status;
21971         status = pthread_create( &t, &attr, task, NULL );
21972 #if HAVE_PTHREADS < 7
21973         if( status < 0 ) status = errno;
21974 #endif
21975         if( status ) return status;
21976 #else
21977         /* Draft 4 pthreads */
21978         status = pthread_create( &t, pthread_attr_default, task, NULL );
21979         if( status ) return errno;
21980
21981         /* give thread a chance to complete */
21982         /* it should remain joinable and hence detachable */
21983         sleep( 1 );
21984
21985         status = pthread_detach( &t );
21986         if( status ) return errno;
21987 #endif
21988
21989 #ifdef HAVE_LINUX_THREADS
21990         pthread_kill_other_threads_np();
21991 #endif
21992
21993         return 0;
21994
21995   ;
21996   return 0;
21997 }
21998 _ACEOF
21999 rm -f conftest.$ac_objext conftest$ac_exeext
22000 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22001   (eval $ac_link) 2>conftest.er1
22002   ac_status=$?
22003   grep -v '^ *+' conftest.er1 >conftest.err
22004   rm -f conftest.er1
22005   cat conftest.err >&5
22006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22007   (exit $ac_status); } &&
22008          { ac_try='test -z "$ac_c_werror_flag"
22009                          || test ! -s conftest.err'
22010   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22011   (eval $ac_try) 2>&5
22012   ac_status=$?
22013   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22014   (exit $ac_status); }; } &&
22015          { ac_try='test -s conftest$ac_exeext'
22016   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22017   (eval $ac_try) 2>&5
22018   ac_status=$?
22019   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22020   (exit $ac_status); }; }; then
22021   ol_cv_pthread_lpthread=yes
22022 else
22023   echo "$as_me: failed program was:" >&5
22024 sed 's/^/| /' conftest.$ac_ext >&5
22025
22026 ol_cv_pthread_lpthread=no
22027 fi
22028 rm -f conftest.err conftest.$ac_objext \
22029       conftest$ac_exeext conftest.$ac_ext
22030 else
22031   cat >conftest.$ac_ext <<_ACEOF
22032 /* confdefs.h.  */
22033 _ACEOF
22034 cat confdefs.h >>conftest.$ac_ext
22035 cat >>conftest.$ac_ext <<_ACEOF
22036 /* end confdefs.h.  */
22037
22038 /* pthread test headers */
22039 #include <pthread.h>
22040 #if HAVE_PTHREADS < 7
22041 #include <errno.h>
22042 #endif
22043 #ifndef NULL
22044 #define NULL (void*)0
22045 #endif
22046
22047 static void *task(p)
22048         void *p;
22049 {
22050         return (void *) (p == NULL);
22051 }
22052
22053
22054 int main(argc, argv)
22055         int argc;
22056         char **argv;
22057 {
22058
22059         /* pthread test function */
22060 #ifndef PTHREAD_CREATE_DETACHED
22061 #define PTHREAD_CREATE_DETACHED 1
22062 #endif
22063         pthread_t t;
22064         int status;
22065         int detach = PTHREAD_CREATE_DETACHED;
22066
22067 #if HAVE_PTHREADS > 4
22068         /* Final pthreads */
22069         pthread_attr_t attr;
22070
22071         status = pthread_attr_init(&attr);
22072         if( status ) return status;
22073
22074 #if HAVE_PTHREADS < 7
22075         status = pthread_attr_setdetachstate(&attr, &detach);
22076         if( status < 0 ) status = errno;
22077 #else
22078         status = pthread_attr_setdetachstate(&attr, detach);
22079 #endif
22080         if( status ) return status;
22081         status = pthread_create( &t, &attr, task, NULL );
22082 #if HAVE_PTHREADS < 7
22083         if( status < 0 ) status = errno;
22084 #endif
22085         if( status ) return status;
22086 #else
22087         /* Draft 4 pthreads */
22088         status = pthread_create( &t, pthread_attr_default, task, NULL );
22089         if( status ) return errno;
22090
22091         /* give thread a chance to complete */
22092         /* it should remain joinable and hence detachable */
22093         sleep( 1 );
22094
22095         status = pthread_detach( &t );
22096         if( status ) return errno;
22097 #endif
22098
22099 #ifdef HAVE_LINUX_THREADS
22100         pthread_kill_other_threads_np();
22101 #endif
22102
22103         return 0;
22104
22105 }
22106
22107 _ACEOF
22108 rm -f conftest$ac_exeext
22109 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22110   (eval $ac_link) 2>&5
22111   ac_status=$?
22112   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22113   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22114   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22115   (eval $ac_try) 2>&5
22116   ac_status=$?
22117   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22118   (exit $ac_status); }; }; then
22119   ol_cv_pthread_lpthread=yes
22120 else
22121   echo "$as_me: program exited with status $ac_status" >&5
22122 echo "$as_me: failed program was:" >&5
22123 sed 's/^/| /' conftest.$ac_ext >&5
22124
22125 ( exit $ac_status )
22126 ol_cv_pthread_lpthread=no
22127 fi
22128 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22129 fi
22130
22131                 # restore the LIBS
22132                 LIBS="$ol_LIBS"
22133
22134 fi
22135 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread" >&5
22136 echo "${ECHO_T}$ol_cv_pthread_lpthread" >&6
22137
22138         if test $ol_cv_pthread_lpthread = yes ; then
22139                 ol_link_pthreads="-lpthread"
22140                 ol_link_threads=posix
22141         fi
22142 fi
22143
22144                 # Pthread try link: -lc_r (ol_cv_pthread_lc_r)
22145 if test "$ol_link_threads" = no ; then
22146         # try -lc_r
22147         echo "$as_me:$LINENO: checking for pthread link with -lc_r" >&5
22148 echo $ECHO_N "checking for pthread link with -lc_r... $ECHO_C" >&6
22149 if test "${ol_cv_pthread_lc_r+set}" = set; then
22150   echo $ECHO_N "(cached) $ECHO_C" >&6
22151 else
22152
22153                 # save the flags
22154                 ol_LIBS="$LIBS"
22155                 LIBS="-lc_r $LIBS"
22156
22157                 if test "$cross_compiling" = yes; then
22158   cat >conftest.$ac_ext <<_ACEOF
22159 /* confdefs.h.  */
22160 _ACEOF
22161 cat confdefs.h >>conftest.$ac_ext
22162 cat >>conftest.$ac_ext <<_ACEOF
22163 /* end confdefs.h.  */
22164
22165 /* pthread test headers */
22166 #include <pthread.h>
22167 #if HAVE_PTHREADS < 7
22168 #include <errno.h>
22169 #endif
22170 #ifndef NULL
22171 #define NULL (void*)0
22172 #endif
22173
22174 static void *task(p)
22175         void *p;
22176 {
22177         return (void *) (p == NULL);
22178 }
22179
22180 int
22181 main ()
22182 {
22183
22184         /* pthread test function */
22185 #ifndef PTHREAD_CREATE_DETACHED
22186 #define PTHREAD_CREATE_DETACHED 1
22187 #endif
22188         pthread_t t;
22189         int status;
22190         int detach = PTHREAD_CREATE_DETACHED;
22191
22192 #if HAVE_PTHREADS > 4
22193         /* Final pthreads */
22194         pthread_attr_t attr;
22195
22196         status = pthread_attr_init(&attr);
22197         if( status ) return status;
22198
22199 #if HAVE_PTHREADS < 7
22200         status = pthread_attr_setdetachstate(&attr, &detach);
22201         if( status < 0 ) status = errno;
22202 #else
22203         status = pthread_attr_setdetachstate(&attr, detach);
22204 #endif
22205         if( status ) return status;
22206         status = pthread_create( &t, &attr, task, NULL );
22207 #if HAVE_PTHREADS < 7
22208         if( status < 0 ) status = errno;
22209 #endif
22210         if( status ) return status;
22211 #else
22212         /* Draft 4 pthreads */
22213         status = pthread_create( &t, pthread_attr_default, task, NULL );
22214         if( status ) return errno;
22215
22216         /* give thread a chance to complete */
22217         /* it should remain joinable and hence detachable */
22218         sleep( 1 );
22219
22220         status = pthread_detach( &t );
22221         if( status ) return errno;
22222 #endif
22223
22224 #ifdef HAVE_LINUX_THREADS
22225         pthread_kill_other_threads_np();
22226 #endif
22227
22228         return 0;
22229
22230   ;
22231   return 0;
22232 }
22233 _ACEOF
22234 rm -f conftest.$ac_objext conftest$ac_exeext
22235 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22236   (eval $ac_link) 2>conftest.er1
22237   ac_status=$?
22238   grep -v '^ *+' conftest.er1 >conftest.err
22239   rm -f conftest.er1
22240   cat conftest.err >&5
22241   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22242   (exit $ac_status); } &&
22243          { ac_try='test -z "$ac_c_werror_flag"
22244                          || test ! -s conftest.err'
22245   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22246   (eval $ac_try) 2>&5
22247   ac_status=$?
22248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22249   (exit $ac_status); }; } &&
22250          { ac_try='test -s conftest$ac_exeext'
22251   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22252   (eval $ac_try) 2>&5
22253   ac_status=$?
22254   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22255   (exit $ac_status); }; }; then
22256   ol_cv_pthread_lc_r=yes
22257 else
22258   echo "$as_me: failed program was:" >&5
22259 sed 's/^/| /' conftest.$ac_ext >&5
22260
22261 ol_cv_pthread_lc_r=no
22262 fi
22263 rm -f conftest.err conftest.$ac_objext \
22264       conftest$ac_exeext conftest.$ac_ext
22265 else
22266   cat >conftest.$ac_ext <<_ACEOF
22267 /* confdefs.h.  */
22268 _ACEOF
22269 cat confdefs.h >>conftest.$ac_ext
22270 cat >>conftest.$ac_ext <<_ACEOF
22271 /* end confdefs.h.  */
22272
22273 /* pthread test headers */
22274 #include <pthread.h>
22275 #if HAVE_PTHREADS < 7
22276 #include <errno.h>
22277 #endif
22278 #ifndef NULL
22279 #define NULL (void*)0
22280 #endif
22281
22282 static void *task(p)
22283         void *p;
22284 {
22285         return (void *) (p == NULL);
22286 }
22287
22288
22289 int main(argc, argv)
22290         int argc;
22291         char **argv;
22292 {
22293
22294         /* pthread test function */
22295 #ifndef PTHREAD_CREATE_DETACHED
22296 #define PTHREAD_CREATE_DETACHED 1
22297 #endif
22298         pthread_t t;
22299         int status;
22300         int detach = PTHREAD_CREATE_DETACHED;
22301
22302 #if HAVE_PTHREADS > 4
22303         /* Final pthreads */
22304         pthread_attr_t attr;
22305
22306         status = pthread_attr_init(&attr);
22307         if( status ) return status;
22308
22309 #if HAVE_PTHREADS < 7
22310         status = pthread_attr_setdetachstate(&attr, &detach);
22311         if( status < 0 ) status = errno;
22312 #else
22313         status = pthread_attr_setdetachstate(&attr, detach);
22314 #endif
22315         if( status ) return status;
22316         status = pthread_create( &t, &attr, task, NULL );
22317 #if HAVE_PTHREADS < 7
22318         if( status < 0 ) status = errno;
22319 #endif
22320         if( status ) return status;
22321 #else
22322         /* Draft 4 pthreads */
22323         status = pthread_create( &t, pthread_attr_default, task, NULL );
22324         if( status ) return errno;
22325
22326         /* give thread a chance to complete */
22327         /* it should remain joinable and hence detachable */
22328         sleep( 1 );
22329
22330         status = pthread_detach( &t );
22331         if( status ) return errno;
22332 #endif
22333
22334 #ifdef HAVE_LINUX_THREADS
22335         pthread_kill_other_threads_np();
22336 #endif
22337
22338         return 0;
22339
22340 }
22341
22342 _ACEOF
22343 rm -f conftest$ac_exeext
22344 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22345   (eval $ac_link) 2>&5
22346   ac_status=$?
22347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22348   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22349   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22350   (eval $ac_try) 2>&5
22351   ac_status=$?
22352   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22353   (exit $ac_status); }; }; then
22354   ol_cv_pthread_lc_r=yes
22355 else
22356   echo "$as_me: program exited with status $ac_status" >&5
22357 echo "$as_me: failed program was:" >&5
22358 sed 's/^/| /' conftest.$ac_ext >&5
22359
22360 ( exit $ac_status )
22361 ol_cv_pthread_lc_r=no
22362 fi
22363 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22364 fi
22365
22366                 # restore the LIBS
22367                 LIBS="$ol_LIBS"
22368
22369 fi
22370 echo "$as_me:$LINENO: result: $ol_cv_pthread_lc_r" >&5
22371 echo "${ECHO_T}$ol_cv_pthread_lc_r" >&6
22372
22373         if test $ol_cv_pthread_lc_r = yes ; then
22374                 ol_link_pthreads="-lc_r"
22375                 ol_link_threads=posix
22376         fi
22377 fi
22378
22379
22380                 # Pthread try link: -threads (ol_cv_pthread_threads)
22381 if test "$ol_link_threads" = no ; then
22382         # try -threads
22383         echo "$as_me:$LINENO: checking for pthread link with -threads" >&5
22384 echo $ECHO_N "checking for pthread link with -threads... $ECHO_C" >&6
22385 if test "${ol_cv_pthread_threads+set}" = set; then
22386   echo $ECHO_N "(cached) $ECHO_C" >&6
22387 else
22388
22389                 # save the flags
22390                 ol_LIBS="$LIBS"
22391                 LIBS="-threads $LIBS"
22392
22393                 if test "$cross_compiling" = yes; then
22394   cat >conftest.$ac_ext <<_ACEOF
22395 /* confdefs.h.  */
22396 _ACEOF
22397 cat confdefs.h >>conftest.$ac_ext
22398 cat >>conftest.$ac_ext <<_ACEOF
22399 /* end confdefs.h.  */
22400
22401 /* pthread test headers */
22402 #include <pthread.h>
22403 #if HAVE_PTHREADS < 7
22404 #include <errno.h>
22405 #endif
22406 #ifndef NULL
22407 #define NULL (void*)0
22408 #endif
22409
22410 static void *task(p)
22411         void *p;
22412 {
22413         return (void *) (p == NULL);
22414 }
22415
22416 int
22417 main ()
22418 {
22419
22420         /* pthread test function */
22421 #ifndef PTHREAD_CREATE_DETACHED
22422 #define PTHREAD_CREATE_DETACHED 1
22423 #endif
22424         pthread_t t;
22425         int status;
22426         int detach = PTHREAD_CREATE_DETACHED;
22427
22428 #if HAVE_PTHREADS > 4
22429         /* Final pthreads */
22430         pthread_attr_t attr;
22431
22432         status = pthread_attr_init(&attr);
22433         if( status ) return status;
22434
22435 #if HAVE_PTHREADS < 7
22436         status = pthread_attr_setdetachstate(&attr, &detach);
22437         if( status < 0 ) status = errno;
22438 #else
22439         status = pthread_attr_setdetachstate(&attr, detach);
22440 #endif
22441         if( status ) return status;
22442         status = pthread_create( &t, &attr, task, NULL );
22443 #if HAVE_PTHREADS < 7
22444         if( status < 0 ) status = errno;
22445 #endif
22446         if( status ) return status;
22447 #else
22448         /* Draft 4 pthreads */
22449         status = pthread_create( &t, pthread_attr_default, task, NULL );
22450         if( status ) return errno;
22451
22452         /* give thread a chance to complete */
22453         /* it should remain joinable and hence detachable */
22454         sleep( 1 );
22455
22456         status = pthread_detach( &t );
22457         if( status ) return errno;
22458 #endif
22459
22460 #ifdef HAVE_LINUX_THREADS
22461         pthread_kill_other_threads_np();
22462 #endif
22463
22464         return 0;
22465
22466   ;
22467   return 0;
22468 }
22469 _ACEOF
22470 rm -f conftest.$ac_objext conftest$ac_exeext
22471 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22472   (eval $ac_link) 2>conftest.er1
22473   ac_status=$?
22474   grep -v '^ *+' conftest.er1 >conftest.err
22475   rm -f conftest.er1
22476   cat conftest.err >&5
22477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22478   (exit $ac_status); } &&
22479          { ac_try='test -z "$ac_c_werror_flag"
22480                          || test ! -s conftest.err'
22481   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22482   (eval $ac_try) 2>&5
22483   ac_status=$?
22484   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22485   (exit $ac_status); }; } &&
22486          { ac_try='test -s conftest$ac_exeext'
22487   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22488   (eval $ac_try) 2>&5
22489   ac_status=$?
22490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22491   (exit $ac_status); }; }; then
22492   ol_cv_pthread_threads=yes
22493 else
22494   echo "$as_me: failed program was:" >&5
22495 sed 's/^/| /' conftest.$ac_ext >&5
22496
22497 ol_cv_pthread_threads=no
22498 fi
22499 rm -f conftest.err conftest.$ac_objext \
22500       conftest$ac_exeext conftest.$ac_ext
22501 else
22502   cat >conftest.$ac_ext <<_ACEOF
22503 /* confdefs.h.  */
22504 _ACEOF
22505 cat confdefs.h >>conftest.$ac_ext
22506 cat >>conftest.$ac_ext <<_ACEOF
22507 /* end confdefs.h.  */
22508
22509 /* pthread test headers */
22510 #include <pthread.h>
22511 #if HAVE_PTHREADS < 7
22512 #include <errno.h>
22513 #endif
22514 #ifndef NULL
22515 #define NULL (void*)0
22516 #endif
22517
22518 static void *task(p)
22519         void *p;
22520 {
22521         return (void *) (p == NULL);
22522 }
22523
22524
22525 int main(argc, argv)
22526         int argc;
22527         char **argv;
22528 {
22529
22530         /* pthread test function */
22531 #ifndef PTHREAD_CREATE_DETACHED
22532 #define PTHREAD_CREATE_DETACHED 1
22533 #endif
22534         pthread_t t;
22535         int status;
22536         int detach = PTHREAD_CREATE_DETACHED;
22537
22538 #if HAVE_PTHREADS > 4
22539         /* Final pthreads */
22540         pthread_attr_t attr;
22541
22542         status = pthread_attr_init(&attr);
22543         if( status ) return status;
22544
22545 #if HAVE_PTHREADS < 7
22546         status = pthread_attr_setdetachstate(&attr, &detach);
22547         if( status < 0 ) status = errno;
22548 #else
22549         status = pthread_attr_setdetachstate(&attr, detach);
22550 #endif
22551         if( status ) return status;
22552         status = pthread_create( &t, &attr, task, NULL );
22553 #if HAVE_PTHREADS < 7
22554         if( status < 0 ) status = errno;
22555 #endif
22556         if( status ) return status;
22557 #else
22558         /* Draft 4 pthreads */
22559         status = pthread_create( &t, pthread_attr_default, task, NULL );
22560         if( status ) return errno;
22561
22562         /* give thread a chance to complete */
22563         /* it should remain joinable and hence detachable */
22564         sleep( 1 );
22565
22566         status = pthread_detach( &t );
22567         if( status ) return errno;
22568 #endif
22569
22570 #ifdef HAVE_LINUX_THREADS
22571         pthread_kill_other_threads_np();
22572 #endif
22573
22574         return 0;
22575
22576 }
22577
22578 _ACEOF
22579 rm -f conftest$ac_exeext
22580 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22581   (eval $ac_link) 2>&5
22582   ac_status=$?
22583   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22584   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22585   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22586   (eval $ac_try) 2>&5
22587   ac_status=$?
22588   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22589   (exit $ac_status); }; }; then
22590   ol_cv_pthread_threads=yes
22591 else
22592   echo "$as_me: program exited with status $ac_status" >&5
22593 echo "$as_me: failed program was:" >&5
22594 sed 's/^/| /' conftest.$ac_ext >&5
22595
22596 ( exit $ac_status )
22597 ol_cv_pthread_threads=no
22598 fi
22599 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22600 fi
22601
22602                 # restore the LIBS
22603                 LIBS="$ol_LIBS"
22604
22605 fi
22606 echo "$as_me:$LINENO: result: $ol_cv_pthread_threads" >&5
22607 echo "${ECHO_T}$ol_cv_pthread_threads" >&6
22608
22609         if test $ol_cv_pthread_threads = yes ; then
22610                 ol_link_pthreads="-threads"
22611                 ol_link_threads=posix
22612         fi
22613 fi
22614
22615
22616                 # Pthread try link: -lpthreads -lmach -lexc -lc_r (ol_cv_pthread_lpthreads_lmach_lexc_lc_r)
22617 if test "$ol_link_threads" = no ; then
22618         # try -lpthreads -lmach -lexc -lc_r
22619         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lmach -lexc -lc_r" >&5
22620 echo $ECHO_N "checking for pthread link with -lpthreads -lmach -lexc -lc_r... $ECHO_C" >&6
22621 if test "${ol_cv_pthread_lpthreads_lmach_lexc_lc_r+set}" = set; then
22622   echo $ECHO_N "(cached) $ECHO_C" >&6
22623 else
22624
22625                 # save the flags
22626                 ol_LIBS="$LIBS"
22627                 LIBS="-lpthreads -lmach -lexc -lc_r $LIBS"
22628
22629                 if test "$cross_compiling" = yes; then
22630   cat >conftest.$ac_ext <<_ACEOF
22631 /* confdefs.h.  */
22632 _ACEOF
22633 cat confdefs.h >>conftest.$ac_ext
22634 cat >>conftest.$ac_ext <<_ACEOF
22635 /* end confdefs.h.  */
22636
22637 /* pthread test headers */
22638 #include <pthread.h>
22639 #if HAVE_PTHREADS < 7
22640 #include <errno.h>
22641 #endif
22642 #ifndef NULL
22643 #define NULL (void*)0
22644 #endif
22645
22646 static void *task(p)
22647         void *p;
22648 {
22649         return (void *) (p == NULL);
22650 }
22651
22652 int
22653 main ()
22654 {
22655
22656         /* pthread test function */
22657 #ifndef PTHREAD_CREATE_DETACHED
22658 #define PTHREAD_CREATE_DETACHED 1
22659 #endif
22660         pthread_t t;
22661         int status;
22662         int detach = PTHREAD_CREATE_DETACHED;
22663
22664 #if HAVE_PTHREADS > 4
22665         /* Final pthreads */
22666         pthread_attr_t attr;
22667
22668         status = pthread_attr_init(&attr);
22669         if( status ) return status;
22670
22671 #if HAVE_PTHREADS < 7
22672         status = pthread_attr_setdetachstate(&attr, &detach);
22673         if( status < 0 ) status = errno;
22674 #else
22675         status = pthread_attr_setdetachstate(&attr, detach);
22676 #endif
22677         if( status ) return status;
22678         status = pthread_create( &t, &attr, task, NULL );
22679 #if HAVE_PTHREADS < 7
22680         if( status < 0 ) status = errno;
22681 #endif
22682         if( status ) return status;
22683 #else
22684         /* Draft 4 pthreads */
22685         status = pthread_create( &t, pthread_attr_default, task, NULL );
22686         if( status ) return errno;
22687
22688         /* give thread a chance to complete */
22689         /* it should remain joinable and hence detachable */
22690         sleep( 1 );
22691
22692         status = pthread_detach( &t );
22693         if( status ) return errno;
22694 #endif
22695
22696 #ifdef HAVE_LINUX_THREADS
22697         pthread_kill_other_threads_np();
22698 #endif
22699
22700         return 0;
22701
22702   ;
22703   return 0;
22704 }
22705 _ACEOF
22706 rm -f conftest.$ac_objext conftest$ac_exeext
22707 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22708   (eval $ac_link) 2>conftest.er1
22709   ac_status=$?
22710   grep -v '^ *+' conftest.er1 >conftest.err
22711   rm -f conftest.er1
22712   cat conftest.err >&5
22713   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22714   (exit $ac_status); } &&
22715          { ac_try='test -z "$ac_c_werror_flag"
22716                          || test ! -s conftest.err'
22717   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22718   (eval $ac_try) 2>&5
22719   ac_status=$?
22720   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22721   (exit $ac_status); }; } &&
22722          { ac_try='test -s conftest$ac_exeext'
22723   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22724   (eval $ac_try) 2>&5
22725   ac_status=$?
22726   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22727   (exit $ac_status); }; }; then
22728   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
22729 else
22730   echo "$as_me: failed program was:" >&5
22731 sed 's/^/| /' conftest.$ac_ext >&5
22732
22733 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
22734 fi
22735 rm -f conftest.err conftest.$ac_objext \
22736       conftest$ac_exeext conftest.$ac_ext
22737 else
22738   cat >conftest.$ac_ext <<_ACEOF
22739 /* confdefs.h.  */
22740 _ACEOF
22741 cat confdefs.h >>conftest.$ac_ext
22742 cat >>conftest.$ac_ext <<_ACEOF
22743 /* end confdefs.h.  */
22744
22745 /* pthread test headers */
22746 #include <pthread.h>
22747 #if HAVE_PTHREADS < 7
22748 #include <errno.h>
22749 #endif
22750 #ifndef NULL
22751 #define NULL (void*)0
22752 #endif
22753
22754 static void *task(p)
22755         void *p;
22756 {
22757         return (void *) (p == NULL);
22758 }
22759
22760
22761 int main(argc, argv)
22762         int argc;
22763         char **argv;
22764 {
22765
22766         /* pthread test function */
22767 #ifndef PTHREAD_CREATE_DETACHED
22768 #define PTHREAD_CREATE_DETACHED 1
22769 #endif
22770         pthread_t t;
22771         int status;
22772         int detach = PTHREAD_CREATE_DETACHED;
22773
22774 #if HAVE_PTHREADS > 4
22775         /* Final pthreads */
22776         pthread_attr_t attr;
22777
22778         status = pthread_attr_init(&attr);
22779         if( status ) return status;
22780
22781 #if HAVE_PTHREADS < 7
22782         status = pthread_attr_setdetachstate(&attr, &detach);
22783         if( status < 0 ) status = errno;
22784 #else
22785         status = pthread_attr_setdetachstate(&attr, detach);
22786 #endif
22787         if( status ) return status;
22788         status = pthread_create( &t, &attr, task, NULL );
22789 #if HAVE_PTHREADS < 7
22790         if( status < 0 ) status = errno;
22791 #endif
22792         if( status ) return status;
22793 #else
22794         /* Draft 4 pthreads */
22795         status = pthread_create( &t, pthread_attr_default, task, NULL );
22796         if( status ) return errno;
22797
22798         /* give thread a chance to complete */
22799         /* it should remain joinable and hence detachable */
22800         sleep( 1 );
22801
22802         status = pthread_detach( &t );
22803         if( status ) return errno;
22804 #endif
22805
22806 #ifdef HAVE_LINUX_THREADS
22807         pthread_kill_other_threads_np();
22808 #endif
22809
22810         return 0;
22811
22812 }
22813
22814 _ACEOF
22815 rm -f conftest$ac_exeext
22816 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22817   (eval $ac_link) 2>&5
22818   ac_status=$?
22819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22820   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22821   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22822   (eval $ac_try) 2>&5
22823   ac_status=$?
22824   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22825   (exit $ac_status); }; }; then
22826   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
22827 else
22828   echo "$as_me: program exited with status $ac_status" >&5
22829 echo "$as_me: failed program was:" >&5
22830 sed 's/^/| /' conftest.$ac_ext >&5
22831
22832 ( exit $ac_status )
22833 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
22834 fi
22835 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22836 fi
22837
22838                 # restore the LIBS
22839                 LIBS="$ol_LIBS"
22840
22841 fi
22842 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&5
22843 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&6
22844
22845         if test $ol_cv_pthread_lpthreads_lmach_lexc_lc_r = yes ; then
22846                 ol_link_pthreads="-lpthreads -lmach -lexc -lc_r"
22847                 ol_link_threads=posix
22848         fi
22849 fi
22850
22851                 # Pthread try link: -lpthreads -lmach -lexc (ol_cv_pthread_lpthreads_lmach_lexc)
22852 if test "$ol_link_threads" = no ; then
22853         # try -lpthreads -lmach -lexc
22854         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lmach -lexc" >&5
22855 echo $ECHO_N "checking for pthread link with -lpthreads -lmach -lexc... $ECHO_C" >&6
22856 if test "${ol_cv_pthread_lpthreads_lmach_lexc+set}" = set; then
22857   echo $ECHO_N "(cached) $ECHO_C" >&6
22858 else
22859
22860                 # save the flags
22861                 ol_LIBS="$LIBS"
22862                 LIBS="-lpthreads -lmach -lexc $LIBS"
22863
22864                 if test "$cross_compiling" = yes; then
22865   cat >conftest.$ac_ext <<_ACEOF
22866 /* confdefs.h.  */
22867 _ACEOF
22868 cat confdefs.h >>conftest.$ac_ext
22869 cat >>conftest.$ac_ext <<_ACEOF
22870 /* end confdefs.h.  */
22871
22872 /* pthread test headers */
22873 #include <pthread.h>
22874 #if HAVE_PTHREADS < 7
22875 #include <errno.h>
22876 #endif
22877 #ifndef NULL
22878 #define NULL (void*)0
22879 #endif
22880
22881 static void *task(p)
22882         void *p;
22883 {
22884         return (void *) (p == NULL);
22885 }
22886
22887 int
22888 main ()
22889 {
22890
22891         /* pthread test function */
22892 #ifndef PTHREAD_CREATE_DETACHED
22893 #define PTHREAD_CREATE_DETACHED 1
22894 #endif
22895         pthread_t t;
22896         int status;
22897         int detach = PTHREAD_CREATE_DETACHED;
22898
22899 #if HAVE_PTHREADS > 4
22900         /* Final pthreads */
22901         pthread_attr_t attr;
22902
22903         status = pthread_attr_init(&attr);
22904         if( status ) return status;
22905
22906 #if HAVE_PTHREADS < 7
22907         status = pthread_attr_setdetachstate(&attr, &detach);
22908         if( status < 0 ) status = errno;
22909 #else
22910         status = pthread_attr_setdetachstate(&attr, detach);
22911 #endif
22912         if( status ) return status;
22913         status = pthread_create( &t, &attr, task, NULL );
22914 #if HAVE_PTHREADS < 7
22915         if( status < 0 ) status = errno;
22916 #endif
22917         if( status ) return status;
22918 #else
22919         /* Draft 4 pthreads */
22920         status = pthread_create( &t, pthread_attr_default, task, NULL );
22921         if( status ) return errno;
22922
22923         /* give thread a chance to complete */
22924         /* it should remain joinable and hence detachable */
22925         sleep( 1 );
22926
22927         status = pthread_detach( &t );
22928         if( status ) return errno;
22929 #endif
22930
22931 #ifdef HAVE_LINUX_THREADS
22932         pthread_kill_other_threads_np();
22933 #endif
22934
22935         return 0;
22936
22937   ;
22938   return 0;
22939 }
22940 _ACEOF
22941 rm -f conftest.$ac_objext conftest$ac_exeext
22942 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22943   (eval $ac_link) 2>conftest.er1
22944   ac_status=$?
22945   grep -v '^ *+' conftest.er1 >conftest.err
22946   rm -f conftest.er1
22947   cat conftest.err >&5
22948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22949   (exit $ac_status); } &&
22950          { ac_try='test -z "$ac_c_werror_flag"
22951                          || test ! -s conftest.err'
22952   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22953   (eval $ac_try) 2>&5
22954   ac_status=$?
22955   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22956   (exit $ac_status); }; } &&
22957          { ac_try='test -s conftest$ac_exeext'
22958   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22959   (eval $ac_try) 2>&5
22960   ac_status=$?
22961   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22962   (exit $ac_status); }; }; then
22963   ol_cv_pthread_lpthreads_lmach_lexc=yes
22964 else
22965   echo "$as_me: failed program was:" >&5
22966 sed 's/^/| /' conftest.$ac_ext >&5
22967
22968 ol_cv_pthread_lpthreads_lmach_lexc=no
22969 fi
22970 rm -f conftest.err conftest.$ac_objext \
22971       conftest$ac_exeext conftest.$ac_ext
22972 else
22973   cat >conftest.$ac_ext <<_ACEOF
22974 /* confdefs.h.  */
22975 _ACEOF
22976 cat confdefs.h >>conftest.$ac_ext
22977 cat >>conftest.$ac_ext <<_ACEOF
22978 /* end confdefs.h.  */
22979
22980 /* pthread test headers */
22981 #include <pthread.h>
22982 #if HAVE_PTHREADS < 7
22983 #include <errno.h>
22984 #endif
22985 #ifndef NULL
22986 #define NULL (void*)0
22987 #endif
22988
22989 static void *task(p)
22990         void *p;
22991 {
22992         return (void *) (p == NULL);
22993 }
22994
22995
22996 int main(argc, argv)
22997         int argc;
22998         char **argv;
22999 {
23000
23001         /* pthread test function */
23002 #ifndef PTHREAD_CREATE_DETACHED
23003 #define PTHREAD_CREATE_DETACHED 1
23004 #endif
23005         pthread_t t;
23006         int status;
23007         int detach = PTHREAD_CREATE_DETACHED;
23008
23009 #if HAVE_PTHREADS > 4
23010         /* Final pthreads */
23011         pthread_attr_t attr;
23012
23013         status = pthread_attr_init(&attr);
23014         if( status ) return status;
23015
23016 #if HAVE_PTHREADS < 7
23017         status = pthread_attr_setdetachstate(&attr, &detach);
23018         if( status < 0 ) status = errno;
23019 #else
23020         status = pthread_attr_setdetachstate(&attr, detach);
23021 #endif
23022         if( status ) return status;
23023         status = pthread_create( &t, &attr, task, NULL );
23024 #if HAVE_PTHREADS < 7
23025         if( status < 0 ) status = errno;
23026 #endif
23027         if( status ) return status;
23028 #else
23029         /* Draft 4 pthreads */
23030         status = pthread_create( &t, pthread_attr_default, task, NULL );
23031         if( status ) return errno;
23032
23033         /* give thread a chance to complete */
23034         /* it should remain joinable and hence detachable */
23035         sleep( 1 );
23036
23037         status = pthread_detach( &t );
23038         if( status ) return errno;
23039 #endif
23040
23041 #ifdef HAVE_LINUX_THREADS
23042         pthread_kill_other_threads_np();
23043 #endif
23044
23045         return 0;
23046
23047 }
23048
23049 _ACEOF
23050 rm -f conftest$ac_exeext
23051 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23052   (eval $ac_link) 2>&5
23053   ac_status=$?
23054   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23055   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23056   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23057   (eval $ac_try) 2>&5
23058   ac_status=$?
23059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23060   (exit $ac_status); }; }; then
23061   ol_cv_pthread_lpthreads_lmach_lexc=yes
23062 else
23063   echo "$as_me: program exited with status $ac_status" >&5
23064 echo "$as_me: failed program was:" >&5
23065 sed 's/^/| /' conftest.$ac_ext >&5
23066
23067 ( exit $ac_status )
23068 ol_cv_pthread_lpthreads_lmach_lexc=no
23069 fi
23070 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23071 fi
23072
23073                 # restore the LIBS
23074                 LIBS="$ol_LIBS"
23075
23076 fi
23077 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lmach_lexc" >&5
23078 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lmach_lexc" >&6
23079
23080         if test $ol_cv_pthread_lpthreads_lmach_lexc = yes ; then
23081                 ol_link_pthreads="-lpthreads -lmach -lexc"
23082                 ol_link_threads=posix
23083         fi
23084 fi
23085
23086                 # Pthread try link: -lpthreads -lexc (ol_cv_pthread_lpthreads_lexc)
23087 if test "$ol_link_threads" = no ; then
23088         # try -lpthreads -lexc
23089         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lexc" >&5
23090 echo $ECHO_N "checking for pthread link with -lpthreads -lexc... $ECHO_C" >&6
23091 if test "${ol_cv_pthread_lpthreads_lexc+set}" = set; then
23092   echo $ECHO_N "(cached) $ECHO_C" >&6
23093 else
23094
23095                 # save the flags
23096                 ol_LIBS="$LIBS"
23097                 LIBS="-lpthreads -lexc $LIBS"
23098
23099                 if test "$cross_compiling" = yes; then
23100   cat >conftest.$ac_ext <<_ACEOF
23101 /* confdefs.h.  */
23102 _ACEOF
23103 cat confdefs.h >>conftest.$ac_ext
23104 cat >>conftest.$ac_ext <<_ACEOF
23105 /* end confdefs.h.  */
23106
23107 /* pthread test headers */
23108 #include <pthread.h>
23109 #if HAVE_PTHREADS < 7
23110 #include <errno.h>
23111 #endif
23112 #ifndef NULL
23113 #define NULL (void*)0
23114 #endif
23115
23116 static void *task(p)
23117         void *p;
23118 {
23119         return (void *) (p == NULL);
23120 }
23121
23122 int
23123 main ()
23124 {
23125
23126         /* pthread test function */
23127 #ifndef PTHREAD_CREATE_DETACHED
23128 #define PTHREAD_CREATE_DETACHED 1
23129 #endif
23130         pthread_t t;
23131         int status;
23132         int detach = PTHREAD_CREATE_DETACHED;
23133
23134 #if HAVE_PTHREADS > 4
23135         /* Final pthreads */
23136         pthread_attr_t attr;
23137
23138         status = pthread_attr_init(&attr);
23139         if( status ) return status;
23140
23141 #if HAVE_PTHREADS < 7
23142         status = pthread_attr_setdetachstate(&attr, &detach);
23143         if( status < 0 ) status = errno;
23144 #else
23145         status = pthread_attr_setdetachstate(&attr, detach);
23146 #endif
23147         if( status ) return status;
23148         status = pthread_create( &t, &attr, task, NULL );
23149 #if HAVE_PTHREADS < 7
23150         if( status < 0 ) status = errno;
23151 #endif
23152         if( status ) return status;
23153 #else
23154         /* Draft 4 pthreads */
23155         status = pthread_create( &t, pthread_attr_default, task, NULL );
23156         if( status ) return errno;
23157
23158         /* give thread a chance to complete */
23159         /* it should remain joinable and hence detachable */
23160         sleep( 1 );
23161
23162         status = pthread_detach( &t );
23163         if( status ) return errno;
23164 #endif
23165
23166 #ifdef HAVE_LINUX_THREADS
23167         pthread_kill_other_threads_np();
23168 #endif
23169
23170         return 0;
23171
23172   ;
23173   return 0;
23174 }
23175 _ACEOF
23176 rm -f conftest.$ac_objext conftest$ac_exeext
23177 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23178   (eval $ac_link) 2>conftest.er1
23179   ac_status=$?
23180   grep -v '^ *+' conftest.er1 >conftest.err
23181   rm -f conftest.er1
23182   cat conftest.err >&5
23183   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23184   (exit $ac_status); } &&
23185          { ac_try='test -z "$ac_c_werror_flag"
23186                          || test ! -s conftest.err'
23187   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23188   (eval $ac_try) 2>&5
23189   ac_status=$?
23190   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23191   (exit $ac_status); }; } &&
23192          { ac_try='test -s conftest$ac_exeext'
23193   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23194   (eval $ac_try) 2>&5
23195   ac_status=$?
23196   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23197   (exit $ac_status); }; }; then
23198   ol_cv_pthread_lpthreads_lexc=yes
23199 else
23200   echo "$as_me: failed program was:" >&5
23201 sed 's/^/| /' conftest.$ac_ext >&5
23202
23203 ol_cv_pthread_lpthreads_lexc=no
23204 fi
23205 rm -f conftest.err conftest.$ac_objext \
23206       conftest$ac_exeext conftest.$ac_ext
23207 else
23208   cat >conftest.$ac_ext <<_ACEOF
23209 /* confdefs.h.  */
23210 _ACEOF
23211 cat confdefs.h >>conftest.$ac_ext
23212 cat >>conftest.$ac_ext <<_ACEOF
23213 /* end confdefs.h.  */
23214
23215 /* pthread test headers */
23216 #include <pthread.h>
23217 #if HAVE_PTHREADS < 7
23218 #include <errno.h>
23219 #endif
23220 #ifndef NULL
23221 #define NULL (void*)0
23222 #endif
23223
23224 static void *task(p)
23225         void *p;
23226 {
23227         return (void *) (p == NULL);
23228 }
23229
23230
23231 int main(argc, argv)
23232         int argc;
23233         char **argv;
23234 {
23235
23236         /* pthread test function */
23237 #ifndef PTHREAD_CREATE_DETACHED
23238 #define PTHREAD_CREATE_DETACHED 1
23239 #endif
23240         pthread_t t;
23241         int status;
23242         int detach = PTHREAD_CREATE_DETACHED;
23243
23244 #if HAVE_PTHREADS > 4
23245         /* Final pthreads */
23246         pthread_attr_t attr;
23247
23248         status = pthread_attr_init(&attr);
23249         if( status ) return status;
23250
23251 #if HAVE_PTHREADS < 7
23252         status = pthread_attr_setdetachstate(&attr, &detach);
23253         if( status < 0 ) status = errno;
23254 #else
23255         status = pthread_attr_setdetachstate(&attr, detach);
23256 #endif
23257         if( status ) return status;
23258         status = pthread_create( &t, &attr, task, NULL );
23259 #if HAVE_PTHREADS < 7
23260         if( status < 0 ) status = errno;
23261 #endif
23262         if( status ) return status;
23263 #else
23264         /* Draft 4 pthreads */
23265         status = pthread_create( &t, pthread_attr_default, task, NULL );
23266         if( status ) return errno;
23267
23268         /* give thread a chance to complete */
23269         /* it should remain joinable and hence detachable */
23270         sleep( 1 );
23271
23272         status = pthread_detach( &t );
23273         if( status ) return errno;
23274 #endif
23275
23276 #ifdef HAVE_LINUX_THREADS
23277         pthread_kill_other_threads_np();
23278 #endif
23279
23280         return 0;
23281
23282 }
23283
23284 _ACEOF
23285 rm -f conftest$ac_exeext
23286 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23287   (eval $ac_link) 2>&5
23288   ac_status=$?
23289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23290   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23291   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23292   (eval $ac_try) 2>&5
23293   ac_status=$?
23294   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23295   (exit $ac_status); }; }; then
23296   ol_cv_pthread_lpthreads_lexc=yes
23297 else
23298   echo "$as_me: program exited with status $ac_status" >&5
23299 echo "$as_me: failed program was:" >&5
23300 sed 's/^/| /' conftest.$ac_ext >&5
23301
23302 ( exit $ac_status )
23303 ol_cv_pthread_lpthreads_lexc=no
23304 fi
23305 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23306 fi
23307
23308                 # restore the LIBS
23309                 LIBS="$ol_LIBS"
23310
23311 fi
23312 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lexc" >&5
23313 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lexc" >&6
23314
23315         if test $ol_cv_pthread_lpthreads_lexc = yes ; then
23316                 ol_link_pthreads="-lpthreads -lexc"
23317                 ol_link_threads=posix
23318         fi
23319 fi
23320
23321
23322                 # Pthread try link: -lpthreads (ol_cv_pthread_lib_lpthreads)
23323 if test "$ol_link_threads" = no ; then
23324         # try -lpthreads
23325         echo "$as_me:$LINENO: checking for pthread link with -lpthreads" >&5
23326 echo $ECHO_N "checking for pthread link with -lpthreads... $ECHO_C" >&6
23327 if test "${ol_cv_pthread_lib_lpthreads+set}" = set; then
23328   echo $ECHO_N "(cached) $ECHO_C" >&6
23329 else
23330
23331                 # save the flags
23332                 ol_LIBS="$LIBS"
23333                 LIBS="-lpthreads $LIBS"
23334
23335                 if test "$cross_compiling" = yes; then
23336   cat >conftest.$ac_ext <<_ACEOF
23337 /* confdefs.h.  */
23338 _ACEOF
23339 cat confdefs.h >>conftest.$ac_ext
23340 cat >>conftest.$ac_ext <<_ACEOF
23341 /* end confdefs.h.  */
23342
23343 /* pthread test headers */
23344 #include <pthread.h>
23345 #if HAVE_PTHREADS < 7
23346 #include <errno.h>
23347 #endif
23348 #ifndef NULL
23349 #define NULL (void*)0
23350 #endif
23351
23352 static void *task(p)
23353         void *p;
23354 {
23355         return (void *) (p == NULL);
23356 }
23357
23358 int
23359 main ()
23360 {
23361
23362         /* pthread test function */
23363 #ifndef PTHREAD_CREATE_DETACHED
23364 #define PTHREAD_CREATE_DETACHED 1
23365 #endif
23366         pthread_t t;
23367         int status;
23368         int detach = PTHREAD_CREATE_DETACHED;
23369
23370 #if HAVE_PTHREADS > 4
23371         /* Final pthreads */
23372         pthread_attr_t attr;
23373
23374         status = pthread_attr_init(&attr);
23375         if( status ) return status;
23376
23377 #if HAVE_PTHREADS < 7
23378         status = pthread_attr_setdetachstate(&attr, &detach);
23379         if( status < 0 ) status = errno;
23380 #else
23381         status = pthread_attr_setdetachstate(&attr, detach);
23382 #endif
23383         if( status ) return status;
23384         status = pthread_create( &t, &attr, task, NULL );
23385 #if HAVE_PTHREADS < 7
23386         if( status < 0 ) status = errno;
23387 #endif
23388         if( status ) return status;
23389 #else
23390         /* Draft 4 pthreads */
23391         status = pthread_create( &t, pthread_attr_default, task, NULL );
23392         if( status ) return errno;
23393
23394         /* give thread a chance to complete */
23395         /* it should remain joinable and hence detachable */
23396         sleep( 1 );
23397
23398         status = pthread_detach( &t );
23399         if( status ) return errno;
23400 #endif
23401
23402 #ifdef HAVE_LINUX_THREADS
23403         pthread_kill_other_threads_np();
23404 #endif
23405
23406         return 0;
23407
23408   ;
23409   return 0;
23410 }
23411 _ACEOF
23412 rm -f conftest.$ac_objext conftest$ac_exeext
23413 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23414   (eval $ac_link) 2>conftest.er1
23415   ac_status=$?
23416   grep -v '^ *+' conftest.er1 >conftest.err
23417   rm -f conftest.er1
23418   cat conftest.err >&5
23419   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23420   (exit $ac_status); } &&
23421          { ac_try='test -z "$ac_c_werror_flag"
23422                          || test ! -s conftest.err'
23423   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23424   (eval $ac_try) 2>&5
23425   ac_status=$?
23426   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23427   (exit $ac_status); }; } &&
23428          { ac_try='test -s conftest$ac_exeext'
23429   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23430   (eval $ac_try) 2>&5
23431   ac_status=$?
23432   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23433   (exit $ac_status); }; }; then
23434   ol_cv_pthread_lib_lpthreads=yes
23435 else
23436   echo "$as_me: failed program was:" >&5
23437 sed 's/^/| /' conftest.$ac_ext >&5
23438
23439 ol_cv_pthread_lib_lpthreads=no
23440 fi
23441 rm -f conftest.err conftest.$ac_objext \
23442       conftest$ac_exeext conftest.$ac_ext
23443 else
23444   cat >conftest.$ac_ext <<_ACEOF
23445 /* confdefs.h.  */
23446 _ACEOF
23447 cat confdefs.h >>conftest.$ac_ext
23448 cat >>conftest.$ac_ext <<_ACEOF
23449 /* end confdefs.h.  */
23450
23451 /* pthread test headers */
23452 #include <pthread.h>
23453 #if HAVE_PTHREADS < 7
23454 #include <errno.h>
23455 #endif
23456 #ifndef NULL
23457 #define NULL (void*)0
23458 #endif
23459
23460 static void *task(p)
23461         void *p;
23462 {
23463         return (void *) (p == NULL);
23464 }
23465
23466
23467 int main(argc, argv)
23468         int argc;
23469         char **argv;
23470 {
23471
23472         /* pthread test function */
23473 #ifndef PTHREAD_CREATE_DETACHED
23474 #define PTHREAD_CREATE_DETACHED 1
23475 #endif
23476         pthread_t t;
23477         int status;
23478         int detach = PTHREAD_CREATE_DETACHED;
23479
23480 #if HAVE_PTHREADS > 4
23481         /* Final pthreads */
23482         pthread_attr_t attr;
23483
23484         status = pthread_attr_init(&attr);
23485         if( status ) return status;
23486
23487 #if HAVE_PTHREADS < 7
23488         status = pthread_attr_setdetachstate(&attr, &detach);
23489         if( status < 0 ) status = errno;
23490 #else
23491         status = pthread_attr_setdetachstate(&attr, detach);
23492 #endif
23493         if( status ) return status;
23494         status = pthread_create( &t, &attr, task, NULL );
23495 #if HAVE_PTHREADS < 7
23496         if( status < 0 ) status = errno;
23497 #endif
23498         if( status ) return status;
23499 #else
23500         /* Draft 4 pthreads */
23501         status = pthread_create( &t, pthread_attr_default, task, NULL );
23502         if( status ) return errno;
23503
23504         /* give thread a chance to complete */
23505         /* it should remain joinable and hence detachable */
23506         sleep( 1 );
23507
23508         status = pthread_detach( &t );
23509         if( status ) return errno;
23510 #endif
23511
23512 #ifdef HAVE_LINUX_THREADS
23513         pthread_kill_other_threads_np();
23514 #endif
23515
23516         return 0;
23517
23518 }
23519
23520 _ACEOF
23521 rm -f conftest$ac_exeext
23522 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23523   (eval $ac_link) 2>&5
23524   ac_status=$?
23525   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23526   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23527   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23528   (eval $ac_try) 2>&5
23529   ac_status=$?
23530   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23531   (exit $ac_status); }; }; then
23532   ol_cv_pthread_lib_lpthreads=yes
23533 else
23534   echo "$as_me: program exited with status $ac_status" >&5
23535 echo "$as_me: failed program was:" >&5
23536 sed 's/^/| /' conftest.$ac_ext >&5
23537
23538 ( exit $ac_status )
23539 ol_cv_pthread_lib_lpthreads=no
23540 fi
23541 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23542 fi
23543
23544                 # restore the LIBS
23545                 LIBS="$ol_LIBS"
23546
23547 fi
23548 echo "$as_me:$LINENO: result: $ol_cv_pthread_lib_lpthreads" >&5
23549 echo "${ECHO_T}$ol_cv_pthread_lib_lpthreads" >&6
23550
23551         if test $ol_cv_pthread_lib_lpthreads = yes ; then
23552                 ol_link_pthreads="-lpthreads"
23553                 ol_link_threads=posix
23554         fi
23555 fi
23556
23557
23558                 if test $ol_link_threads != no ; then
23559                         LTHREAD_LIBS="$LTHREAD_LIBS $ol_link_pthreads"
23560
23561                                                 save_CPPFLAGS="$CPPFLAGS"
23562                         save_LIBS="$LIBS"
23563                         LIBS="$LTHREAD_LIBS $LIBS"
23564
23565
23566
23567
23568 for ac_func in sched_yield pthread_yield thr_yield
23569 do
23570 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
23571 echo "$as_me:$LINENO: checking for $ac_func" >&5
23572 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
23573 if eval "test \"\${$as_ac_var+set}\" = set"; then
23574   echo $ECHO_N "(cached) $ECHO_C" >&6
23575 else
23576   cat >conftest.$ac_ext <<_ACEOF
23577 /* confdefs.h.  */
23578 _ACEOF
23579 cat confdefs.h >>conftest.$ac_ext
23580 cat >>conftest.$ac_ext <<_ACEOF
23581 /* end confdefs.h.  */
23582 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23583    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23584 #define $ac_func innocuous_$ac_func
23585
23586 /* System header to define __stub macros and hopefully few prototypes,
23587     which can conflict with char $ac_func (); below.
23588     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23589     <limits.h> exists even on freestanding compilers.  */
23590
23591 #ifdef __STDC__
23592 # include <limits.h>
23593 #else
23594 # include <assert.h>
23595 #endif
23596
23597 #undef $ac_func
23598
23599 /* Override any gcc2 internal prototype to avoid an error.  */
23600 #ifdef __cplusplus
23601 extern "C"
23602 {
23603 #endif
23604 /* We use char because int might match the return type of a gcc2
23605    builtin and then its argument prototype would still apply.  */
23606 char $ac_func ();
23607 /* The GNU C library defines this for functions which it implements
23608     to always fail with ENOSYS.  Some functions are actually named
23609     something starting with __ and the normal name is an alias.  */
23610 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
23611 choke me
23612 #else
23613 char (*f) () = $ac_func;
23614 #endif
23615 #ifdef __cplusplus
23616 }
23617 #endif
23618
23619 int
23620 main ()
23621 {
23622 return f != $ac_func;
23623   ;
23624   return 0;
23625 }
23626 _ACEOF
23627 rm -f conftest.$ac_objext conftest$ac_exeext
23628 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23629   (eval $ac_link) 2>conftest.er1
23630   ac_status=$?
23631   grep -v '^ *+' conftest.er1 >conftest.err
23632   rm -f conftest.er1
23633   cat conftest.err >&5
23634   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23635   (exit $ac_status); } &&
23636          { ac_try='test -z "$ac_c_werror_flag"
23637                          || test ! -s conftest.err'
23638   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23639   (eval $ac_try) 2>&5
23640   ac_status=$?
23641   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23642   (exit $ac_status); }; } &&
23643          { ac_try='test -s conftest$ac_exeext'
23644   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23645   (eval $ac_try) 2>&5
23646   ac_status=$?
23647   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23648   (exit $ac_status); }; }; then
23649   eval "$as_ac_var=yes"
23650 else
23651   echo "$as_me: failed program was:" >&5
23652 sed 's/^/| /' conftest.$ac_ext >&5
23653
23654 eval "$as_ac_var=no"
23655 fi
23656 rm -f conftest.err conftest.$ac_objext \
23657       conftest$ac_exeext conftest.$ac_ext
23658 fi
23659 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
23660 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
23661 if test `eval echo '${'$as_ac_var'}'` = yes; then
23662   cat >>confdefs.h <<_ACEOF
23663 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
23664 _ACEOF
23665
23666 fi
23667 done
23668
23669
23670                         if test $ac_cv_func_sched_yield = no &&
23671                            test $ac_cv_func_pthread_yield = no &&
23672                            test $ac_cv_func_thr_yield = no ; then
23673                                                                 echo "$as_me:$LINENO: checking for sched_yield in -lrt" >&5
23674 echo $ECHO_N "checking for sched_yield in -lrt... $ECHO_C" >&6
23675 if test "${ac_cv_lib_rt_sched_yield+set}" = set; then
23676   echo $ECHO_N "(cached) $ECHO_C" >&6
23677 else
23678   ac_check_lib_save_LIBS=$LIBS
23679 LIBS="-lrt  $LIBS"
23680 cat >conftest.$ac_ext <<_ACEOF
23681 /* confdefs.h.  */
23682 _ACEOF
23683 cat confdefs.h >>conftest.$ac_ext
23684 cat >>conftest.$ac_ext <<_ACEOF
23685 /* end confdefs.h.  */
23686
23687 /* Override any gcc2 internal prototype to avoid an error.  */
23688 #ifdef __cplusplus
23689 extern "C"
23690 #endif
23691 /* We use char because int might match the return type of a gcc2
23692    builtin and then its argument prototype would still apply.  */
23693 char sched_yield ();
23694 int
23695 main ()
23696 {
23697 sched_yield ();
23698   ;
23699   return 0;
23700 }
23701 _ACEOF
23702 rm -f conftest.$ac_objext conftest$ac_exeext
23703 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23704   (eval $ac_link) 2>conftest.er1
23705   ac_status=$?
23706   grep -v '^ *+' conftest.er1 >conftest.err
23707   rm -f conftest.er1
23708   cat conftest.err >&5
23709   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23710   (exit $ac_status); } &&
23711          { ac_try='test -z "$ac_c_werror_flag"
23712                          || test ! -s conftest.err'
23713   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23714   (eval $ac_try) 2>&5
23715   ac_status=$?
23716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23717   (exit $ac_status); }; } &&
23718          { ac_try='test -s conftest$ac_exeext'
23719   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23720   (eval $ac_try) 2>&5
23721   ac_status=$?
23722   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23723   (exit $ac_status); }; }; then
23724   ac_cv_lib_rt_sched_yield=yes
23725 else
23726   echo "$as_me: failed program was:" >&5
23727 sed 's/^/| /' conftest.$ac_ext >&5
23728
23729 ac_cv_lib_rt_sched_yield=no
23730 fi
23731 rm -f conftest.err conftest.$ac_objext \
23732       conftest$ac_exeext conftest.$ac_ext
23733 LIBS=$ac_check_lib_save_LIBS
23734 fi
23735 echo "$as_me:$LINENO: result: $ac_cv_lib_rt_sched_yield" >&5
23736 echo "${ECHO_T}$ac_cv_lib_rt_sched_yield" >&6
23737 if test $ac_cv_lib_rt_sched_yield = yes; then
23738   LTHREAD_LIBS="$LTHREAD_LIBS -lrt"
23739
23740 cat >>confdefs.h <<\_ACEOF
23741 #define HAVE_SCHED_YIELD 1
23742 _ACEOF
23743
23744                                         ac_cv_func_sched_yield=yes
23745 else
23746   ac_cv_func_sched_yield=no
23747 fi
23748
23749                         fi
23750                         if test $ac_cv_func_sched_yield = no &&
23751                            test $ac_cv_func_pthread_yield = no &&
23752                            test "$ac_cv_func_thr_yield" = no ; then
23753                                 { echo "$as_me:$LINENO: WARNING: could not locate sched_yield() or pthread_yield()" >&5
23754 echo "$as_me: WARNING: could not locate sched_yield() or pthread_yield()" >&2;}
23755                         fi
23756
23757
23758 for ac_func in pthread_kill
23759 do
23760 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
23761 echo "$as_me:$LINENO: checking for $ac_func" >&5
23762 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
23763 if eval "test \"\${$as_ac_var+set}\" = set"; then
23764   echo $ECHO_N "(cached) $ECHO_C" >&6
23765 else
23766   cat >conftest.$ac_ext <<_ACEOF
23767 /* confdefs.h.  */
23768 _ACEOF
23769 cat confdefs.h >>conftest.$ac_ext
23770 cat >>conftest.$ac_ext <<_ACEOF
23771 /* end confdefs.h.  */
23772 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23773    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23774 #define $ac_func innocuous_$ac_func
23775
23776 /* System header to define __stub macros and hopefully few prototypes,
23777     which can conflict with char $ac_func (); below.
23778     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23779     <limits.h> exists even on freestanding compilers.  */
23780
23781 #ifdef __STDC__
23782 # include <limits.h>
23783 #else
23784 # include <assert.h>
23785 #endif
23786
23787 #undef $ac_func
23788
23789 /* Override any gcc2 internal prototype to avoid an error.  */
23790 #ifdef __cplusplus
23791 extern "C"
23792 {
23793 #endif
23794 /* We use char because int might match the return type of a gcc2
23795    builtin and then its argument prototype would still apply.  */
23796 char $ac_func ();
23797 /* The GNU C library defines this for functions which it implements
23798     to always fail with ENOSYS.  Some functions are actually named
23799     something starting with __ and the normal name is an alias.  */
23800 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
23801 choke me
23802 #else
23803 char (*f) () = $ac_func;
23804 #endif
23805 #ifdef __cplusplus
23806 }
23807 #endif
23808
23809 int
23810 main ()
23811 {
23812 return f != $ac_func;
23813   ;
23814   return 0;
23815 }
23816 _ACEOF
23817 rm -f conftest.$ac_objext conftest$ac_exeext
23818 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23819   (eval $ac_link) 2>conftest.er1
23820   ac_status=$?
23821   grep -v '^ *+' conftest.er1 >conftest.err
23822   rm -f conftest.er1
23823   cat conftest.err >&5
23824   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23825   (exit $ac_status); } &&
23826          { ac_try='test -z "$ac_c_werror_flag"
23827                          || test ! -s conftest.err'
23828   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23829   (eval $ac_try) 2>&5
23830   ac_status=$?
23831   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23832   (exit $ac_status); }; } &&
23833          { ac_try='test -s conftest$ac_exeext'
23834   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23835   (eval $ac_try) 2>&5
23836   ac_status=$?
23837   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23838   (exit $ac_status); }; }; then
23839   eval "$as_ac_var=yes"
23840 else
23841   echo "$as_me: failed program was:" >&5
23842 sed 's/^/| /' conftest.$ac_ext >&5
23843
23844 eval "$as_ac_var=no"
23845 fi
23846 rm -f conftest.err conftest.$ac_objext \
23847       conftest$ac_exeext conftest.$ac_ext
23848 fi
23849 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
23850 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
23851 if test `eval echo '${'$as_ac_var'}'` = yes; then
23852   cat >>confdefs.h <<_ACEOF
23853 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
23854 _ACEOF
23855
23856 fi
23857 done
23858
23859
23860                                                                         echo "$as_me:$LINENO: checking for pthread_rwlock_destroy with <pthread.h>" >&5
23861 echo $ECHO_N "checking for pthread_rwlock_destroy with <pthread.h>... $ECHO_C" >&6
23862 if test "${ol_cv_func_pthread_rwlock_destroy+set}" = set; then
23863   echo $ECHO_N "(cached) $ECHO_C" >&6
23864 else
23865
23866                                                                 cat >conftest.$ac_ext <<_ACEOF
23867 /* confdefs.h.  */
23868 _ACEOF
23869 cat confdefs.h >>conftest.$ac_ext
23870 cat >>conftest.$ac_ext <<_ACEOF
23871 /* end confdefs.h.  */
23872
23873 #include <pthread.h>
23874 pthread_rwlock_t rwlock;
23875
23876 int
23877 main ()
23878 {
23879 pthread_rwlock_destroy(&rwlock);
23880   ;
23881   return 0;
23882 }
23883 _ACEOF
23884 rm -f conftest.$ac_objext conftest$ac_exeext
23885 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23886   (eval $ac_link) 2>conftest.er1
23887   ac_status=$?
23888   grep -v '^ *+' conftest.er1 >conftest.err
23889   rm -f conftest.er1
23890   cat conftest.err >&5
23891   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23892   (exit $ac_status); } &&
23893          { ac_try='test -z "$ac_c_werror_flag"
23894                          || test ! -s conftest.err'
23895   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23896   (eval $ac_try) 2>&5
23897   ac_status=$?
23898   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23899   (exit $ac_status); }; } &&
23900          { ac_try='test -s conftest$ac_exeext'
23901   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23902   (eval $ac_try) 2>&5
23903   ac_status=$?
23904   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23905   (exit $ac_status); }; }; then
23906   ol_cv_func_pthread_rwlock_destroy=yes
23907 else
23908   echo "$as_me: failed program was:" >&5
23909 sed 's/^/| /' conftest.$ac_ext >&5
23910
23911 ol_cv_func_pthread_rwlock_destroy=no
23912 fi
23913 rm -f conftest.err conftest.$ac_objext \
23914       conftest$ac_exeext conftest.$ac_ext
23915
23916 fi
23917 echo "$as_me:$LINENO: result: $ol_cv_func_pthread_rwlock_destroy" >&5
23918 echo "${ECHO_T}$ol_cv_func_pthread_rwlock_destroy" >&6
23919                         if test $ol_cv_func_pthread_rwlock_destroy = yes ; then
23920
23921 cat >>confdefs.h <<\_ACEOF
23922 #define HAVE_PTHREAD_RWLOCK_DESTROY 1
23923 _ACEOF
23924
23925                         fi
23926
23927                                                                         echo "$as_me:$LINENO: checking for pthread_detach with <pthread.h>" >&5
23928 echo $ECHO_N "checking for pthread_detach with <pthread.h>... $ECHO_C" >&6
23929 if test "${ol_cv_func_pthread_detach+set}" = set; then
23930   echo $ECHO_N "(cached) $ECHO_C" >&6
23931 else
23932
23933                                                                 cat >conftest.$ac_ext <<_ACEOF
23934 /* confdefs.h.  */
23935 _ACEOF
23936 cat confdefs.h >>conftest.$ac_ext
23937 cat >>conftest.$ac_ext <<_ACEOF
23938 /* end confdefs.h.  */
23939
23940 #include <pthread.h>
23941 #ifndef NULL
23942 #define NULL (void*)0
23943 #endif
23944
23945 int
23946 main ()
23947 {
23948 pthread_detach(NULL);
23949   ;
23950   return 0;
23951 }
23952 _ACEOF
23953 rm -f conftest.$ac_objext conftest$ac_exeext
23954 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23955   (eval $ac_link) 2>conftest.er1
23956   ac_status=$?
23957   grep -v '^ *+' conftest.er1 >conftest.err
23958   rm -f conftest.er1
23959   cat conftest.err >&5
23960   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23961   (exit $ac_status); } &&
23962          { ac_try='test -z "$ac_c_werror_flag"
23963                          || test ! -s conftest.err'
23964   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23965   (eval $ac_try) 2>&5
23966   ac_status=$?
23967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23968   (exit $ac_status); }; } &&
23969          { ac_try='test -s conftest$ac_exeext'
23970   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23971   (eval $ac_try) 2>&5
23972   ac_status=$?
23973   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23974   (exit $ac_status); }; }; then
23975   ol_cv_func_pthread_detach=yes
23976 else
23977   echo "$as_me: failed program was:" >&5
23978 sed 's/^/| /' conftest.$ac_ext >&5
23979
23980 ol_cv_func_pthread_detach=no
23981 fi
23982 rm -f conftest.err conftest.$ac_objext \
23983       conftest$ac_exeext conftest.$ac_ext
23984
23985 fi
23986 echo "$as_me:$LINENO: result: $ol_cv_func_pthread_detach" >&5
23987 echo "${ECHO_T}$ol_cv_func_pthread_detach" >&6
23988
23989                         if test $ol_cv_func_pthread_detach = no ; then
23990                                 { { echo "$as_me:$LINENO: error: could not locate pthread_detach()" >&5
23991 echo "$as_me: error: could not locate pthread_detach()" >&2;}
23992    { (exit 1); exit 1; }; }
23993                         fi
23994
23995
23996 cat >>confdefs.h <<\_ACEOF
23997 #define HAVE_PTHREAD_DETACH 1
23998 _ACEOF
23999
24000
24001
24002
24003
24004
24005 for ac_func in \
24006                                 pthread_setconcurrency \
24007                                 pthread_getconcurrency \
24008                                 thr_setconcurrency \
24009                                 thr_getconcurrency \
24010
24011 do
24012 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
24013 echo "$as_me:$LINENO: checking for $ac_func" >&5
24014 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
24015 if eval "test \"\${$as_ac_var+set}\" = set"; then
24016   echo $ECHO_N "(cached) $ECHO_C" >&6
24017 else
24018   cat >conftest.$ac_ext <<_ACEOF
24019 /* confdefs.h.  */
24020 _ACEOF
24021 cat confdefs.h >>conftest.$ac_ext
24022 cat >>conftest.$ac_ext <<_ACEOF
24023 /* end confdefs.h.  */
24024 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
24025    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24026 #define $ac_func innocuous_$ac_func
24027
24028 /* System header to define __stub macros and hopefully few prototypes,
24029     which can conflict with char $ac_func (); below.
24030     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24031     <limits.h> exists even on freestanding compilers.  */
24032
24033 #ifdef __STDC__
24034 # include <limits.h>
24035 #else
24036 # include <assert.h>
24037 #endif
24038
24039 #undef $ac_func
24040
24041 /* Override any gcc2 internal prototype to avoid an error.  */
24042 #ifdef __cplusplus
24043 extern "C"
24044 {
24045 #endif
24046 /* We use char because int might match the return type of a gcc2
24047    builtin and then its argument prototype would still apply.  */
24048 char $ac_func ();
24049 /* The GNU C library defines this for functions which it implements
24050     to always fail with ENOSYS.  Some functions are actually named
24051     something starting with __ and the normal name is an alias.  */
24052 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
24053 choke me
24054 #else
24055 char (*f) () = $ac_func;
24056 #endif
24057 #ifdef __cplusplus
24058 }
24059 #endif
24060
24061 int
24062 main ()
24063 {
24064 return f != $ac_func;
24065   ;
24066   return 0;
24067 }
24068 _ACEOF
24069 rm -f conftest.$ac_objext conftest$ac_exeext
24070 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24071   (eval $ac_link) 2>conftest.er1
24072   ac_status=$?
24073   grep -v '^ *+' conftest.er1 >conftest.err
24074   rm -f conftest.er1
24075   cat conftest.err >&5
24076   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24077   (exit $ac_status); } &&
24078          { ac_try='test -z "$ac_c_werror_flag"
24079                          || test ! -s conftest.err'
24080   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24081   (eval $ac_try) 2>&5
24082   ac_status=$?
24083   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24084   (exit $ac_status); }; } &&
24085          { ac_try='test -s conftest$ac_exeext'
24086   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24087   (eval $ac_try) 2>&5
24088   ac_status=$?
24089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24090   (exit $ac_status); }; }; then
24091   eval "$as_ac_var=yes"
24092 else
24093   echo "$as_me: failed program was:" >&5
24094 sed 's/^/| /' conftest.$ac_ext >&5
24095
24096 eval "$as_ac_var=no"
24097 fi
24098 rm -f conftest.err conftest.$ac_objext \
24099       conftest$ac_exeext conftest.$ac_ext
24100 fi
24101 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
24102 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
24103 if test `eval echo '${'$as_ac_var'}'` = yes; then
24104   cat >>confdefs.h <<_ACEOF
24105 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
24106 _ACEOF
24107
24108 fi
24109 done
24110
24111
24112
24113
24114 for ac_func in pthread_kill_other_threads_np
24115 do
24116 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
24117 echo "$as_me:$LINENO: checking for $ac_func" >&5
24118 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
24119 if eval "test \"\${$as_ac_var+set}\" = set"; then
24120   echo $ECHO_N "(cached) $ECHO_C" >&6
24121 else
24122   cat >conftest.$ac_ext <<_ACEOF
24123 /* confdefs.h.  */
24124 _ACEOF
24125 cat confdefs.h >>conftest.$ac_ext
24126 cat >>conftest.$ac_ext <<_ACEOF
24127 /* end confdefs.h.  */
24128 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
24129    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24130 #define $ac_func innocuous_$ac_func
24131
24132 /* System header to define __stub macros and hopefully few prototypes,
24133     which can conflict with char $ac_func (); below.
24134     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24135     <limits.h> exists even on freestanding compilers.  */
24136
24137 #ifdef __STDC__
24138 # include <limits.h>
24139 #else
24140 # include <assert.h>
24141 #endif
24142
24143 #undef $ac_func
24144
24145 /* Override any gcc2 internal prototype to avoid an error.  */
24146 #ifdef __cplusplus
24147 extern "C"
24148 {
24149 #endif
24150 /* We use char because int might match the return type of a gcc2
24151    builtin and then its argument prototype would still apply.  */
24152 char $ac_func ();
24153 /* The GNU C library defines this for functions which it implements
24154     to always fail with ENOSYS.  Some functions are actually named
24155     something starting with __ and the normal name is an alias.  */
24156 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
24157 choke me
24158 #else
24159 char (*f) () = $ac_func;
24160 #endif
24161 #ifdef __cplusplus
24162 }
24163 #endif
24164
24165 int
24166 main ()
24167 {
24168 return f != $ac_func;
24169   ;
24170   return 0;
24171 }
24172 _ACEOF
24173 rm -f conftest.$ac_objext conftest$ac_exeext
24174 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24175   (eval $ac_link) 2>conftest.er1
24176   ac_status=$?
24177   grep -v '^ *+' conftest.er1 >conftest.err
24178   rm -f conftest.er1
24179   cat conftest.err >&5
24180   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24181   (exit $ac_status); } &&
24182          { ac_try='test -z "$ac_c_werror_flag"
24183                          || test ! -s conftest.err'
24184   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24185   (eval $ac_try) 2>&5
24186   ac_status=$?
24187   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24188   (exit $ac_status); }; } &&
24189          { ac_try='test -s conftest$ac_exeext'
24190   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24191   (eval $ac_try) 2>&5
24192   ac_status=$?
24193   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24194   (exit $ac_status); }; }; then
24195   eval "$as_ac_var=yes"
24196 else
24197   echo "$as_me: failed program was:" >&5
24198 sed 's/^/| /' conftest.$ac_ext >&5
24199
24200 eval "$as_ac_var=no"
24201 fi
24202 rm -f conftest.err conftest.$ac_objext \
24203       conftest$ac_exeext conftest.$ac_ext
24204 fi
24205 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
24206 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
24207 if test `eval echo '${'$as_ac_var'}'` = yes; then
24208   cat >>confdefs.h <<_ACEOF
24209 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
24210 _ACEOF
24211
24212 fi
24213 done
24214
24215         echo "$as_me:$LINENO: checking for LinuxThreads implementation" >&5
24216 echo $ECHO_N "checking for LinuxThreads implementation... $ECHO_C" >&6
24217 if test "${ol_cv_sys_linux_threads+set}" = set; then
24218   echo $ECHO_N "(cached) $ECHO_C" >&6
24219 else
24220   ol_cv_sys_linux_threads=$ac_cv_func_pthread_kill_other_threads_np
24221 fi
24222 echo "$as_me:$LINENO: result: $ol_cv_sys_linux_threads" >&5
24223 echo "${ECHO_T}$ol_cv_sys_linux_threads" >&6
24224
24225
24226
24227
24228         echo "$as_me:$LINENO: checking for LinuxThreads consistency" >&5
24229 echo $ECHO_N "checking for LinuxThreads consistency... $ECHO_C" >&6
24230 if test "${ol_cv_linux_threads+set}" = set; then
24231   echo $ECHO_N "(cached) $ECHO_C" >&6
24232 else
24233
24234                 if test $ol_cv_header_linux_threads = yes &&
24235                    test $ol_cv_sys_linux_threads = yes; then
24236                         ol_cv_linux_threads=yes
24237                 elif test $ol_cv_header_linux_threads = no &&
24238                      test $ol_cv_sys_linux_threads = no; then
24239                         ol_cv_linux_threads=no
24240                 else
24241                         ol_cv_linux_threads=error
24242                 fi
24243
24244 fi
24245 echo "$as_me:$LINENO: result: $ol_cv_linux_threads" >&5
24246 echo "${ECHO_T}$ol_cv_linux_threads" >&6
24247
24248
24249                         if test $ol_cv_linux_threads = error; then
24250                                 { { echo "$as_me:$LINENO: error: LinuxThreads header/library mismatch" >&5
24251 echo "$as_me: error: LinuxThreads header/library mismatch" >&2;}
24252    { (exit 1); exit 1; }; };
24253                         fi
24254
24255                         echo "$as_me:$LINENO: checking if pthread_create() works" >&5
24256 echo $ECHO_N "checking if pthread_create() works... $ECHO_C" >&6
24257 if test "${ol_cv_pthread_create_works+set}" = set; then
24258   echo $ECHO_N "(cached) $ECHO_C" >&6
24259 else
24260
24261                         if test "$cross_compiling" = yes; then
24262                                 ol_cv_pthread_create_works=yes
24263 else
24264   cat >conftest.$ac_ext <<_ACEOF
24265 /* confdefs.h.  */
24266 _ACEOF
24267 cat confdefs.h >>conftest.$ac_ext
24268 cat >>conftest.$ac_ext <<_ACEOF
24269 /* end confdefs.h.  */
24270
24271 /* pthread test headers */
24272 #include <pthread.h>
24273 #if HAVE_PTHREADS < 7
24274 #include <errno.h>
24275 #endif
24276 #ifndef NULL
24277 #define NULL (void*)0
24278 #endif
24279
24280 static void *task(p)
24281         void *p;
24282 {
24283         return (void *) (p == NULL);
24284 }
24285
24286
24287 int main(argc, argv)
24288         int argc;
24289         char **argv;
24290 {
24291
24292         /* pthread test function */
24293 #ifndef PTHREAD_CREATE_DETACHED
24294 #define PTHREAD_CREATE_DETACHED 1
24295 #endif
24296         pthread_t t;
24297         int status;
24298         int detach = PTHREAD_CREATE_DETACHED;
24299
24300 #if HAVE_PTHREADS > 4
24301         /* Final pthreads */
24302         pthread_attr_t attr;
24303
24304         status = pthread_attr_init(&attr);
24305         if( status ) return status;
24306
24307 #if HAVE_PTHREADS < 7
24308         status = pthread_attr_setdetachstate(&attr, &detach);
24309         if( status < 0 ) status = errno;
24310 #else
24311         status = pthread_attr_setdetachstate(&attr, detach);
24312 #endif
24313         if( status ) return status;
24314         status = pthread_create( &t, &attr, task, NULL );
24315 #if HAVE_PTHREADS < 7
24316         if( status < 0 ) status = errno;
24317 #endif
24318         if( status ) return status;
24319 #else
24320         /* Draft 4 pthreads */
24321         status = pthread_create( &t, pthread_attr_default, task, NULL );
24322         if( status ) return errno;
24323
24324         /* give thread a chance to complete */
24325         /* it should remain joinable and hence detachable */
24326         sleep( 1 );
24327
24328         status = pthread_detach( &t );
24329         if( status ) return errno;
24330 #endif
24331
24332 #ifdef HAVE_LINUX_THREADS
24333         pthread_kill_other_threads_np();
24334 #endif
24335
24336         return 0;
24337
24338 }
24339
24340 _ACEOF
24341 rm -f conftest$ac_exeext
24342 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24343   (eval $ac_link) 2>&5
24344   ac_status=$?
24345   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24346   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24347   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24348   (eval $ac_try) 2>&5
24349   ac_status=$?
24350   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24351   (exit $ac_status); }; }; then
24352   ol_cv_pthread_create_works=yes
24353 else
24354   echo "$as_me: program exited with status $ac_status" >&5
24355 echo "$as_me: failed program was:" >&5
24356 sed 's/^/| /' conftest.$ac_ext >&5
24357
24358 ( exit $ac_status )
24359 ol_cv_pthread_create_works=no
24360 fi
24361 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24362 fi
24363 fi
24364 echo "$as_me:$LINENO: result: $ol_cv_pthread_create_works" >&5
24365 echo "${ECHO_T}$ol_cv_pthread_create_works" >&6
24366
24367                         if test $ol_cv_pthread_create_works = no ; then
24368                                 { { echo "$as_me:$LINENO: error: pthread_create is not usable, check environment settings" >&5
24369 echo "$as_me: error: pthread_create is not usable, check environment settings" >&2;}
24370    { (exit 1); exit 1; }; }
24371                         fi
24372
24373                         ol_replace_broken_yield=no
24374
24375                         if test $ol_replace_broken_yield = yes ; then
24376
24377 cat >>confdefs.h <<\_ACEOF
24378 #define REPLACE_BROKEN_YIELD 1
24379 _ACEOF
24380
24381                         fi
24382
24383                                                 if test $ol_with_yielding_select = auto ; then
24384                                 echo "$as_me:$LINENO: checking if select yields when using pthreads" >&5
24385 echo $ECHO_N "checking if select yields when using pthreads... $ECHO_C" >&6
24386 if test "${ol_cv_pthread_select_yields+set}" = set; then
24387   echo $ECHO_N "(cached) $ECHO_C" >&6
24388 else
24389
24390                                 if test "$cross_compiling" = yes; then
24391   ol_cv_pthread_select_yields=cross
24392 else
24393   cat >conftest.$ac_ext <<_ACEOF
24394 /* confdefs.h.  */
24395 _ACEOF
24396 cat confdefs.h >>conftest.$ac_ext
24397 cat >>conftest.$ac_ext <<_ACEOF
24398 /* end confdefs.h.  */
24399
24400 #include <sys/types.h>
24401 #include <sys/time.h>
24402 #include <unistd.h>
24403 #include <pthread.h>
24404 #ifndef NULL
24405 #define NULL (void*) 0
24406 #endif
24407
24408 static int fildes[2];
24409
24410 static void *task(p)
24411         void *p;
24412 {
24413         int i;
24414         struct timeval tv;
24415
24416         fd_set rfds;
24417
24418         tv.tv_sec=10;
24419         tv.tv_usec=0;
24420
24421         FD_ZERO(&rfds);
24422         FD_SET(fildes[0], &rfds);
24423
24424         /* we're not interested in any fds */
24425         i = select(FD_SETSIZE, &rfds, NULL, NULL, &tv);
24426
24427         if(i < 0) {
24428                 perror("select");
24429                 exit(10);
24430         }
24431
24432         exit(0); /* if we exit here, the select blocked the whole process */
24433 }
24434
24435 int main(argc, argv)
24436         int argc;
24437         char **argv;
24438 {
24439         pthread_t t;
24440
24441         /* create a pipe to select */
24442         if(pipe(&fildes[0])) {
24443                 perror("select");
24444                 exit(1);
24445         }
24446
24447 #ifdef HAVE_PTHREAD_SETCONCURRENCY
24448         (void) pthread_setconcurrency(2);
24449 #else
24450 #ifdef HAVE_THR_SETCONCURRENCY
24451         /* Set Solaris LWP concurrency to 2 */
24452         thr_setconcurrency(2);
24453 #endif
24454 #endif
24455
24456 #if HAVE_PTHREADS < 6
24457         pthread_create(&t, pthread_attr_default, task, NULL);
24458 #else
24459         pthread_create(&t, NULL, task, NULL);
24460 #endif
24461
24462         /* make sure task runs first */
24463 #ifdef HAVE_THR_YIELD
24464         thr_yield();
24465 #elif defined( HAVE_SCHED_YIELD )
24466         sched_yield();
24467 #elif defined( HAVE_PTHREAD_YIELD )
24468         pthread_yield();
24469 #endif
24470
24471         exit(2);
24472 }
24473 _ACEOF
24474 rm -f conftest$ac_exeext
24475 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24476   (eval $ac_link) 2>&5
24477   ac_status=$?
24478   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24479   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24480   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24481   (eval $ac_try) 2>&5
24482   ac_status=$?
24483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24484   (exit $ac_status); }; }; then
24485   ol_cv_pthread_select_yields=no
24486 else
24487   echo "$as_me: program exited with status $ac_status" >&5
24488 echo "$as_me: failed program was:" >&5
24489 sed 's/^/| /' conftest.$ac_ext >&5
24490
24491 ( exit $ac_status )
24492 ol_cv_pthread_select_yields=yes
24493 fi
24494 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24495 fi
24496 fi
24497 echo "$as_me:$LINENO: result: $ol_cv_pthread_select_yields" >&5
24498 echo "${ECHO_T}$ol_cv_pthread_select_yields" >&6
24499
24500                                 if test $ol_cv_pthread_select_yields = cross ; then
24501                                         { { echo "$as_me:$LINENO: error: crossing compiling: use --with-yielding_select=yes|no|manual" >&5
24502 echo "$as_me: error: crossing compiling: use --with-yielding_select=yes|no|manual" >&2;}
24503    { (exit 1); exit 1; }; }
24504                                 fi
24505
24506                                 if test $ol_cv_pthread_select_yields = yes ; then
24507                                         ol_with_yielding_select=yes
24508                                 fi
24509                         fi
24510
24511                                                 CPPFLAGS="$save_CPPFLAGS"
24512                         LIBS="$save_LIBS"
24513                 else
24514                         { { echo "$as_me:$LINENO: error: could not locate usable POSIX Threads" >&5
24515 echo "$as_me: error: could not locate usable POSIX Threads" >&2;}
24516    { (exit 1); exit 1; }; }
24517                 fi
24518         fi
24519
24520         if test $ol_with_threads = posix ; then
24521                 { { echo "$as_me:$LINENO: error: could not locate POSIX Threads" >&5
24522 echo "$as_me: error: could not locate POSIX Threads" >&2;}
24523    { (exit 1); exit 1; }; }
24524         fi
24525         ;;
24526 esac
24527
24528 case $ol_with_threads in auto | yes | mach)
24529
24530
24531
24532 for ac_header in mach/cthreads.h cthreads.h
24533 do
24534 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
24535 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24536   echo "$as_me:$LINENO: checking for $ac_header" >&5
24537 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24538 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24539   echo $ECHO_N "(cached) $ECHO_C" >&6
24540 fi
24541 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24542 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24543 else
24544   # Is the header compilable?
24545 echo "$as_me:$LINENO: checking $ac_header usability" >&5
24546 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
24547 cat >conftest.$ac_ext <<_ACEOF
24548 /* confdefs.h.  */
24549 _ACEOF
24550 cat confdefs.h >>conftest.$ac_ext
24551 cat >>conftest.$ac_ext <<_ACEOF
24552 /* end confdefs.h.  */
24553 $ac_includes_default
24554 #include <$ac_header>
24555 _ACEOF
24556 rm -f conftest.$ac_objext
24557 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
24558   (eval $ac_compile) 2>conftest.er1
24559   ac_status=$?
24560   grep -v '^ *+' conftest.er1 >conftest.err
24561   rm -f conftest.er1
24562   cat conftest.err >&5
24563   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24564   (exit $ac_status); } &&
24565          { ac_try='test -z "$ac_c_werror_flag"
24566                          || test ! -s conftest.err'
24567   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24568   (eval $ac_try) 2>&5
24569   ac_status=$?
24570   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24571   (exit $ac_status); }; } &&
24572          { ac_try='test -s conftest.$ac_objext'
24573   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24574   (eval $ac_try) 2>&5
24575   ac_status=$?
24576   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24577   (exit $ac_status); }; }; then
24578   ac_header_compiler=yes
24579 else
24580   echo "$as_me: failed program was:" >&5
24581 sed 's/^/| /' conftest.$ac_ext >&5
24582
24583 ac_header_compiler=no
24584 fi
24585 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
24586 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
24587 echo "${ECHO_T}$ac_header_compiler" >&6
24588
24589 # Is the header present?
24590 echo "$as_me:$LINENO: checking $ac_header presence" >&5
24591 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
24592 cat >conftest.$ac_ext <<_ACEOF
24593 /* confdefs.h.  */
24594 _ACEOF
24595 cat confdefs.h >>conftest.$ac_ext
24596 cat >>conftest.$ac_ext <<_ACEOF
24597 /* end confdefs.h.  */
24598 #include <$ac_header>
24599 _ACEOF
24600 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
24601   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
24602   ac_status=$?
24603   grep -v '^ *+' conftest.er1 >conftest.err
24604   rm -f conftest.er1
24605   cat conftest.err >&5
24606   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24607   (exit $ac_status); } >/dev/null; then
24608   if test -s conftest.err; then
24609     ac_cpp_err=$ac_c_preproc_warn_flag
24610     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
24611   else
24612     ac_cpp_err=
24613   fi
24614 else
24615   ac_cpp_err=yes
24616 fi
24617 if test -z "$ac_cpp_err"; then
24618   ac_header_preproc=yes
24619 else
24620   echo "$as_me: failed program was:" >&5
24621 sed 's/^/| /' conftest.$ac_ext >&5
24622
24623   ac_header_preproc=no
24624 fi
24625 rm -f conftest.err conftest.$ac_ext
24626 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
24627 echo "${ECHO_T}$ac_header_preproc" >&6
24628
24629 # So?  What about this header?
24630 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
24631   yes:no: )
24632     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
24633 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
24634     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
24635 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
24636     ac_header_preproc=yes
24637     ;;
24638   no:yes:* )
24639     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
24640 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
24641     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
24642 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
24643     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
24644 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
24645     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
24646 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
24647     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
24648 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
24649     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
24650 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
24651     (
24652       cat <<\_ASBOX
24653 ## --------------------------------------------- ##
24654 ## Report this to <http://www.openldap.org/its/> ##
24655 ## --------------------------------------------- ##
24656 _ASBOX
24657     ) |
24658       sed "s/^/$as_me: WARNING:     /" >&2
24659     ;;
24660 esac
24661 echo "$as_me:$LINENO: checking for $ac_header" >&5
24662 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24663 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24664   echo $ECHO_N "(cached) $ECHO_C" >&6
24665 else
24666   eval "$as_ac_Header=\$ac_header_preproc"
24667 fi
24668 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24669 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24670
24671 fi
24672 if test `eval echo '${'$as_ac_Header'}'` = yes; then
24673   cat >>confdefs.h <<_ACEOF
24674 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
24675 _ACEOF
24676
24677 fi
24678
24679 done
24680
24681         if test $ac_cv_header_mach_cthreads_h = yes ; then
24682                 ol_with_threads=found
24683
24684                                 echo "$as_me:$LINENO: checking for cthread_fork" >&5
24685 echo $ECHO_N "checking for cthread_fork... $ECHO_C" >&6
24686 if test "${ac_cv_func_cthread_fork+set}" = set; then
24687   echo $ECHO_N "(cached) $ECHO_C" >&6
24688 else
24689   cat >conftest.$ac_ext <<_ACEOF
24690 /* confdefs.h.  */
24691 _ACEOF
24692 cat confdefs.h >>conftest.$ac_ext
24693 cat >>conftest.$ac_ext <<_ACEOF
24694 /* end confdefs.h.  */
24695 /* Define cthread_fork to an innocuous variant, in case <limits.h> declares cthread_fork.
24696    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24697 #define cthread_fork innocuous_cthread_fork
24698
24699 /* System header to define __stub macros and hopefully few prototypes,
24700     which can conflict with char cthread_fork (); below.
24701     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24702     <limits.h> exists even on freestanding compilers.  */
24703
24704 #ifdef __STDC__
24705 # include <limits.h>
24706 #else
24707 # include <assert.h>
24708 #endif
24709
24710 #undef cthread_fork
24711
24712 /* Override any gcc2 internal prototype to avoid an error.  */
24713 #ifdef __cplusplus
24714 extern "C"
24715 {
24716 #endif
24717 /* We use char because int might match the return type of a gcc2
24718    builtin and then its argument prototype would still apply.  */
24719 char cthread_fork ();
24720 /* The GNU C library defines this for functions which it implements
24721     to always fail with ENOSYS.  Some functions are actually named
24722     something starting with __ and the normal name is an alias.  */
24723 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
24724 choke me
24725 #else
24726 char (*f) () = cthread_fork;
24727 #endif
24728 #ifdef __cplusplus
24729 }
24730 #endif
24731
24732 int
24733 main ()
24734 {
24735 return f != cthread_fork;
24736   ;
24737   return 0;
24738 }
24739 _ACEOF
24740 rm -f conftest.$ac_objext conftest$ac_exeext
24741 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24742   (eval $ac_link) 2>conftest.er1
24743   ac_status=$?
24744   grep -v '^ *+' conftest.er1 >conftest.err
24745   rm -f conftest.er1
24746   cat conftest.err >&5
24747   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24748   (exit $ac_status); } &&
24749          { ac_try='test -z "$ac_c_werror_flag"
24750                          || test ! -s conftest.err'
24751   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24752   (eval $ac_try) 2>&5
24753   ac_status=$?
24754   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24755   (exit $ac_status); }; } &&
24756          { ac_try='test -s conftest$ac_exeext'
24757   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24758   (eval $ac_try) 2>&5
24759   ac_status=$?
24760   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24761   (exit $ac_status); }; }; then
24762   ac_cv_func_cthread_fork=yes
24763 else
24764   echo "$as_me: failed program was:" >&5
24765 sed 's/^/| /' conftest.$ac_ext >&5
24766
24767 ac_cv_func_cthread_fork=no
24768 fi
24769 rm -f conftest.err conftest.$ac_objext \
24770       conftest$ac_exeext conftest.$ac_ext
24771 fi
24772 echo "$as_me:$LINENO: result: $ac_cv_func_cthread_fork" >&5
24773 echo "${ECHO_T}$ac_cv_func_cthread_fork" >&6
24774 if test $ac_cv_func_cthread_fork = yes; then
24775   ol_link_threads=yes
24776 fi
24777
24778
24779                 if test $ol_link_threads = no ; then
24780                                                                         echo "$as_me:$LINENO: checking for cthread_fork with -all_load" >&5
24781 echo $ECHO_N "checking for cthread_fork with -all_load... $ECHO_C" >&6
24782 if test "${ol_cv_cthread_all_load+set}" = set; then
24783   echo $ECHO_N "(cached) $ECHO_C" >&6
24784 else
24785
24786                                                                 save_LIBS="$LIBS"
24787                                 LIBS="-all_load $LIBS"
24788                                 cat >conftest.$ac_ext <<_ACEOF
24789 /* confdefs.h.  */
24790 _ACEOF
24791 cat confdefs.h >>conftest.$ac_ext
24792 cat >>conftest.$ac_ext <<_ACEOF
24793 /* end confdefs.h.  */
24794 #include <mach/cthreads.h>
24795 int
24796 main ()
24797 {
24798
24799                                         cthread_fork((void *)0, (void *)0);
24800
24801   ;
24802   return 0;
24803 }
24804 _ACEOF
24805 rm -f conftest.$ac_objext conftest$ac_exeext
24806 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24807   (eval $ac_link) 2>conftest.er1
24808   ac_status=$?
24809   grep -v '^ *+' conftest.er1 >conftest.err
24810   rm -f conftest.er1
24811   cat conftest.err >&5
24812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24813   (exit $ac_status); } &&
24814          { ac_try='test -z "$ac_c_werror_flag"
24815                          || test ! -s conftest.err'
24816   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24817   (eval $ac_try) 2>&5
24818   ac_status=$?
24819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24820   (exit $ac_status); }; } &&
24821          { ac_try='test -s conftest$ac_exeext'
24822   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24823   (eval $ac_try) 2>&5
24824   ac_status=$?
24825   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24826   (exit $ac_status); }; }; then
24827   ol_cv_cthread_all_load=yes
24828 else
24829   echo "$as_me: failed program was:" >&5
24830 sed 's/^/| /' conftest.$ac_ext >&5
24831
24832 ol_cv_cthread_all_load=no
24833 fi
24834 rm -f conftest.err conftest.$ac_objext \
24835       conftest$ac_exeext conftest.$ac_ext
24836                                                                 LIBS="$save_LIBS"
24837
24838 fi
24839 echo "$as_me:$LINENO: result: $ol_cv_cthread_all_load" >&5
24840 echo "${ECHO_T}$ol_cv_cthread_all_load" >&6
24841
24842                         if test $ol_cv_cthread_all_load = yes ; then
24843                                 LTHREAD_LIBS="$LTHREAD_LIBS -all_load"
24844                                 ol_link_threads=mach
24845                                 ol_with_threads=found
24846                         fi
24847                 fi
24848
24849         elif test $ac_cv_header_cthreads_h = yes ; then
24850
24851                 ol_with_threads=found
24852
24853                                 save_LIBS="$LIBS"
24854                 LIBS="$LIBS -lthreads"
24855                 echo "$as_me:$LINENO: checking for cthread_fork" >&5
24856 echo $ECHO_N "checking for cthread_fork... $ECHO_C" >&6
24857 if test "${ac_cv_func_cthread_fork+set}" = set; then
24858   echo $ECHO_N "(cached) $ECHO_C" >&6
24859 else
24860   cat >conftest.$ac_ext <<_ACEOF
24861 /* confdefs.h.  */
24862 _ACEOF
24863 cat confdefs.h >>conftest.$ac_ext
24864 cat >>conftest.$ac_ext <<_ACEOF
24865 /* end confdefs.h.  */
24866 /* Define cthread_fork to an innocuous variant, in case <limits.h> declares cthread_fork.
24867    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
24868 #define cthread_fork innocuous_cthread_fork
24869
24870 /* System header to define __stub macros and hopefully few prototypes,
24871     which can conflict with char cthread_fork (); below.
24872     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
24873     <limits.h> exists even on freestanding compilers.  */
24874
24875 #ifdef __STDC__
24876 # include <limits.h>
24877 #else
24878 # include <assert.h>
24879 #endif
24880
24881 #undef cthread_fork
24882
24883 /* Override any gcc2 internal prototype to avoid an error.  */
24884 #ifdef __cplusplus
24885 extern "C"
24886 {
24887 #endif
24888 /* We use char because int might match the return type of a gcc2
24889    builtin and then its argument prototype would still apply.  */
24890 char cthread_fork ();
24891 /* The GNU C library defines this for functions which it implements
24892     to always fail with ENOSYS.  Some functions are actually named
24893     something starting with __ and the normal name is an alias.  */
24894 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
24895 choke me
24896 #else
24897 char (*f) () = cthread_fork;
24898 #endif
24899 #ifdef __cplusplus
24900 }
24901 #endif
24902
24903 int
24904 main ()
24905 {
24906 return f != cthread_fork;
24907   ;
24908   return 0;
24909 }
24910 _ACEOF
24911 rm -f conftest.$ac_objext conftest$ac_exeext
24912 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24913   (eval $ac_link) 2>conftest.er1
24914   ac_status=$?
24915   grep -v '^ *+' conftest.er1 >conftest.err
24916   rm -f conftest.er1
24917   cat conftest.err >&5
24918   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24919   (exit $ac_status); } &&
24920          { ac_try='test -z "$ac_c_werror_flag"
24921                          || test ! -s conftest.err'
24922   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24923   (eval $ac_try) 2>&5
24924   ac_status=$?
24925   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24926   (exit $ac_status); }; } &&
24927          { ac_try='test -s conftest$ac_exeext'
24928   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24929   (eval $ac_try) 2>&5
24930   ac_status=$?
24931   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24932   (exit $ac_status); }; }; then
24933   ac_cv_func_cthread_fork=yes
24934 else
24935   echo "$as_me: failed program was:" >&5
24936 sed 's/^/| /' conftest.$ac_ext >&5
24937
24938 ac_cv_func_cthread_fork=no
24939 fi
24940 rm -f conftest.err conftest.$ac_objext \
24941       conftest$ac_exeext conftest.$ac_ext
24942 fi
24943 echo "$as_me:$LINENO: result: $ac_cv_func_cthread_fork" >&5
24944 echo "${ECHO_T}$ac_cv_func_cthread_fork" >&6
24945 if test $ac_cv_func_cthread_fork = yes; then
24946   ol_link_threads=yes
24947 fi
24948
24949                 LIBS="$save_LIBS"
24950
24951                 if test $ol_link_threads = yes ; then
24952                         LTHREAD_LIBS="-lthreads"
24953                         ol_link_threads=mach
24954                         ol_with_threads=found
24955                 else
24956                         { { echo "$as_me:$LINENO: error: could not link with Mach CThreads" >&5
24957 echo "$as_me: error: could not link with Mach CThreads" >&2;}
24958    { (exit 1); exit 1; }; }
24959                 fi
24960
24961         elif test $ol_with_threads = mach ; then
24962                 { { echo "$as_me:$LINENO: error: could not locate Mach CThreads" >&5
24963 echo "$as_me: error: could not locate Mach CThreads" >&2;}
24964    { (exit 1); exit 1; }; }
24965         fi
24966
24967         if test $ol_link_threads = mach ; then
24968
24969 cat >>confdefs.h <<\_ACEOF
24970 #define HAVE_MACH_CTHREADS 1
24971 _ACEOF
24972
24973         elif test $ol_with_threads = found ; then
24974                 { { echo "$as_me:$LINENO: error: could not link with Mach CThreads" >&5
24975 echo "$as_me: error: could not link with Mach CThreads" >&2;}
24976    { (exit 1); exit 1; }; }
24977         fi
24978         ;;
24979 esac
24980
24981 case $ol_with_threads in auto | yes | pth)
24982
24983
24984 for ac_header in pth.h
24985 do
24986 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
24987 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24988   echo "$as_me:$LINENO: checking for $ac_header" >&5
24989 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24990 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24991   echo $ECHO_N "(cached) $ECHO_C" >&6
24992 fi
24993 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24994 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24995 else
24996   # Is the header compilable?
24997 echo "$as_me:$LINENO: checking $ac_header usability" >&5
24998 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
24999 cat >conftest.$ac_ext <<_ACEOF
25000 /* confdefs.h.  */
25001 _ACEOF
25002 cat confdefs.h >>conftest.$ac_ext
25003 cat >>conftest.$ac_ext <<_ACEOF
25004 /* end confdefs.h.  */
25005 $ac_includes_default
25006 #include <$ac_header>
25007 _ACEOF
25008 rm -f conftest.$ac_objext
25009 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
25010   (eval $ac_compile) 2>conftest.er1
25011   ac_status=$?
25012   grep -v '^ *+' conftest.er1 >conftest.err
25013   rm -f conftest.er1
25014   cat conftest.err >&5
25015   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25016   (exit $ac_status); } &&
25017          { ac_try='test -z "$ac_c_werror_flag"
25018                          || test ! -s conftest.err'
25019   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25020   (eval $ac_try) 2>&5
25021   ac_status=$?
25022   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25023   (exit $ac_status); }; } &&
25024          { ac_try='test -s conftest.$ac_objext'
25025   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25026   (eval $ac_try) 2>&5
25027   ac_status=$?
25028   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25029   (exit $ac_status); }; }; then
25030   ac_header_compiler=yes
25031 else
25032   echo "$as_me: failed program was:" >&5
25033 sed 's/^/| /' conftest.$ac_ext >&5
25034
25035 ac_header_compiler=no
25036 fi
25037 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
25038 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25039 echo "${ECHO_T}$ac_header_compiler" >&6
25040
25041 # Is the header present?
25042 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25043 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25044 cat >conftest.$ac_ext <<_ACEOF
25045 /* confdefs.h.  */
25046 _ACEOF
25047 cat confdefs.h >>conftest.$ac_ext
25048 cat >>conftest.$ac_ext <<_ACEOF
25049 /* end confdefs.h.  */
25050 #include <$ac_header>
25051 _ACEOF
25052 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25053   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25054   ac_status=$?
25055   grep -v '^ *+' conftest.er1 >conftest.err
25056   rm -f conftest.er1
25057   cat conftest.err >&5
25058   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25059   (exit $ac_status); } >/dev/null; then
25060   if test -s conftest.err; then
25061     ac_cpp_err=$ac_c_preproc_warn_flag
25062     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25063   else
25064     ac_cpp_err=
25065   fi
25066 else
25067   ac_cpp_err=yes
25068 fi
25069 if test -z "$ac_cpp_err"; then
25070   ac_header_preproc=yes
25071 else
25072   echo "$as_me: failed program was:" >&5
25073 sed 's/^/| /' conftest.$ac_ext >&5
25074
25075   ac_header_preproc=no
25076 fi
25077 rm -f conftest.err conftest.$ac_ext
25078 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25079 echo "${ECHO_T}$ac_header_preproc" >&6
25080
25081 # So?  What about this header?
25082 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25083   yes:no: )
25084     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25085 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25086     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25087 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25088     ac_header_preproc=yes
25089     ;;
25090   no:yes:* )
25091     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25092 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25093     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25094 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25095     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25096 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25097     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25098 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25099     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25100 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25101     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25102 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25103     (
25104       cat <<\_ASBOX
25105 ## --------------------------------------------- ##
25106 ## Report this to <http://www.openldap.org/its/> ##
25107 ## --------------------------------------------- ##
25108 _ASBOX
25109     ) |
25110       sed "s/^/$as_me: WARNING:     /" >&2
25111     ;;
25112 esac
25113 echo "$as_me:$LINENO: checking for $ac_header" >&5
25114 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25115 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25116   echo $ECHO_N "(cached) $ECHO_C" >&6
25117 else
25118   eval "$as_ac_Header=\$ac_header_preproc"
25119 fi
25120 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25121 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25122
25123 fi
25124 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25125   cat >>confdefs.h <<_ACEOF
25126 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25127 _ACEOF
25128
25129 fi
25130
25131 done
25132
25133
25134         if test $ac_cv_header_pth_h = yes ; then
25135                 echo "$as_me:$LINENO: checking for pth_version in -lpth" >&5
25136 echo $ECHO_N "checking for pth_version in -lpth... $ECHO_C" >&6
25137 if test "${ac_cv_lib_pth_pth_version+set}" = set; then
25138   echo $ECHO_N "(cached) $ECHO_C" >&6
25139 else
25140   ac_check_lib_save_LIBS=$LIBS
25141 LIBS="-lpth  $LIBS"
25142 cat >conftest.$ac_ext <<_ACEOF
25143 /* confdefs.h.  */
25144 _ACEOF
25145 cat confdefs.h >>conftest.$ac_ext
25146 cat >>conftest.$ac_ext <<_ACEOF
25147 /* end confdefs.h.  */
25148
25149 /* Override any gcc2 internal prototype to avoid an error.  */
25150 #ifdef __cplusplus
25151 extern "C"
25152 #endif
25153 /* We use char because int might match the return type of a gcc2
25154    builtin and then its argument prototype would still apply.  */
25155 char pth_version ();
25156 int
25157 main ()
25158 {
25159 pth_version ();
25160   ;
25161   return 0;
25162 }
25163 _ACEOF
25164 rm -f conftest.$ac_objext conftest$ac_exeext
25165 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25166   (eval $ac_link) 2>conftest.er1
25167   ac_status=$?
25168   grep -v '^ *+' conftest.er1 >conftest.err
25169   rm -f conftest.er1
25170   cat conftest.err >&5
25171   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25172   (exit $ac_status); } &&
25173          { ac_try='test -z "$ac_c_werror_flag"
25174                          || test ! -s conftest.err'
25175   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25176   (eval $ac_try) 2>&5
25177   ac_status=$?
25178   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25179   (exit $ac_status); }; } &&
25180          { ac_try='test -s conftest$ac_exeext'
25181   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25182   (eval $ac_try) 2>&5
25183   ac_status=$?
25184   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25185   (exit $ac_status); }; }; then
25186   ac_cv_lib_pth_pth_version=yes
25187 else
25188   echo "$as_me: failed program was:" >&5
25189 sed 's/^/| /' conftest.$ac_ext >&5
25190
25191 ac_cv_lib_pth_pth_version=no
25192 fi
25193 rm -f conftest.err conftest.$ac_objext \
25194       conftest$ac_exeext conftest.$ac_ext
25195 LIBS=$ac_check_lib_save_LIBS
25196 fi
25197 echo "$as_me:$LINENO: result: $ac_cv_lib_pth_pth_version" >&5
25198 echo "${ECHO_T}$ac_cv_lib_pth_pth_version" >&6
25199 if test $ac_cv_lib_pth_pth_version = yes; then
25200   have_pth=yes
25201 else
25202   have_pth=no
25203 fi
25204
25205
25206                 if test $have_pth = yes ; then
25207
25208 cat >>confdefs.h <<\_ACEOF
25209 #define HAVE_GNU_PTH 1
25210 _ACEOF
25211
25212                         LTHREAD_LIBS="$LTHREAD_LIBS -lpth"
25213                         ol_link_threads=pth
25214                         ol_with_threads=found
25215
25216                         if test $ol_with_yielding_select = auto ; then
25217                                 ol_with_yielding_select=yes
25218                         fi
25219                 fi
25220         fi
25221         ;;
25222 esac
25223
25224 case $ol_with_threads in auto | yes | lwp)
25225
25226
25227
25228 for ac_header in thread.h synch.h
25229 do
25230 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25231 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25232   echo "$as_me:$LINENO: checking for $ac_header" >&5
25233 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25234 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25235   echo $ECHO_N "(cached) $ECHO_C" >&6
25236 fi
25237 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25238 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25239 else
25240   # Is the header compilable?
25241 echo "$as_me:$LINENO: checking $ac_header usability" >&5
25242 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
25243 cat >conftest.$ac_ext <<_ACEOF
25244 /* confdefs.h.  */
25245 _ACEOF
25246 cat confdefs.h >>conftest.$ac_ext
25247 cat >>conftest.$ac_ext <<_ACEOF
25248 /* end confdefs.h.  */
25249 $ac_includes_default
25250 #include <$ac_header>
25251 _ACEOF
25252 rm -f conftest.$ac_objext
25253 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
25254   (eval $ac_compile) 2>conftest.er1
25255   ac_status=$?
25256   grep -v '^ *+' conftest.er1 >conftest.err
25257   rm -f conftest.er1
25258   cat conftest.err >&5
25259   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25260   (exit $ac_status); } &&
25261          { ac_try='test -z "$ac_c_werror_flag"
25262                          || test ! -s conftest.err'
25263   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25264   (eval $ac_try) 2>&5
25265   ac_status=$?
25266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25267   (exit $ac_status); }; } &&
25268          { ac_try='test -s conftest.$ac_objext'
25269   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25270   (eval $ac_try) 2>&5
25271   ac_status=$?
25272   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25273   (exit $ac_status); }; }; then
25274   ac_header_compiler=yes
25275 else
25276   echo "$as_me: failed program was:" >&5
25277 sed 's/^/| /' conftest.$ac_ext >&5
25278
25279 ac_header_compiler=no
25280 fi
25281 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
25282 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25283 echo "${ECHO_T}$ac_header_compiler" >&6
25284
25285 # Is the header present?
25286 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25287 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25288 cat >conftest.$ac_ext <<_ACEOF
25289 /* confdefs.h.  */
25290 _ACEOF
25291 cat confdefs.h >>conftest.$ac_ext
25292 cat >>conftest.$ac_ext <<_ACEOF
25293 /* end confdefs.h.  */
25294 #include <$ac_header>
25295 _ACEOF
25296 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25297   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25298   ac_status=$?
25299   grep -v '^ *+' conftest.er1 >conftest.err
25300   rm -f conftest.er1
25301   cat conftest.err >&5
25302   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25303   (exit $ac_status); } >/dev/null; then
25304   if test -s conftest.err; then
25305     ac_cpp_err=$ac_c_preproc_warn_flag
25306     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25307   else
25308     ac_cpp_err=
25309   fi
25310 else
25311   ac_cpp_err=yes
25312 fi
25313 if test -z "$ac_cpp_err"; then
25314   ac_header_preproc=yes
25315 else
25316   echo "$as_me: failed program was:" >&5
25317 sed 's/^/| /' conftest.$ac_ext >&5
25318
25319   ac_header_preproc=no
25320 fi
25321 rm -f conftest.err conftest.$ac_ext
25322 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25323 echo "${ECHO_T}$ac_header_preproc" >&6
25324
25325 # So?  What about this header?
25326 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25327   yes:no: )
25328     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25329 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25330     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25331 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25332     ac_header_preproc=yes
25333     ;;
25334   no:yes:* )
25335     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25336 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25337     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25338 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25339     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25340 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25341     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25342 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25343     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25344 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25345     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25346 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25347     (
25348       cat <<\_ASBOX
25349 ## --------------------------------------------- ##
25350 ## Report this to <http://www.openldap.org/its/> ##
25351 ## --------------------------------------------- ##
25352 _ASBOX
25353     ) |
25354       sed "s/^/$as_me: WARNING:     /" >&2
25355     ;;
25356 esac
25357 echo "$as_me:$LINENO: checking for $ac_header" >&5
25358 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25359 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25360   echo $ECHO_N "(cached) $ECHO_C" >&6
25361 else
25362   eval "$as_ac_Header=\$ac_header_preproc"
25363 fi
25364 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25365 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25366
25367 fi
25368 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25369   cat >>confdefs.h <<_ACEOF
25370 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25371 _ACEOF
25372
25373 fi
25374
25375 done
25376
25377         if test $ac_cv_header_thread_h = yes &&
25378            test $ac_cv_header_synch_h = yes ; then
25379                 echo "$as_me:$LINENO: checking for thr_create in -lthread" >&5
25380 echo $ECHO_N "checking for thr_create in -lthread... $ECHO_C" >&6
25381 if test "${ac_cv_lib_thread_thr_create+set}" = set; then
25382   echo $ECHO_N "(cached) $ECHO_C" >&6
25383 else
25384   ac_check_lib_save_LIBS=$LIBS
25385 LIBS="-lthread  $LIBS"
25386 cat >conftest.$ac_ext <<_ACEOF
25387 /* confdefs.h.  */
25388 _ACEOF
25389 cat confdefs.h >>conftest.$ac_ext
25390 cat >>conftest.$ac_ext <<_ACEOF
25391 /* end confdefs.h.  */
25392
25393 /* Override any gcc2 internal prototype to avoid an error.  */
25394 #ifdef __cplusplus
25395 extern "C"
25396 #endif
25397 /* We use char because int might match the return type of a gcc2
25398    builtin and then its argument prototype would still apply.  */
25399 char thr_create ();
25400 int
25401 main ()
25402 {
25403 thr_create ();
25404   ;
25405   return 0;
25406 }
25407 _ACEOF
25408 rm -f conftest.$ac_objext conftest$ac_exeext
25409 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25410   (eval $ac_link) 2>conftest.er1
25411   ac_status=$?
25412   grep -v '^ *+' conftest.er1 >conftest.err
25413   rm -f conftest.er1
25414   cat conftest.err >&5
25415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25416   (exit $ac_status); } &&
25417          { ac_try='test -z "$ac_c_werror_flag"
25418                          || test ! -s conftest.err'
25419   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25420   (eval $ac_try) 2>&5
25421   ac_status=$?
25422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25423   (exit $ac_status); }; } &&
25424          { ac_try='test -s conftest$ac_exeext'
25425   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25426   (eval $ac_try) 2>&5
25427   ac_status=$?
25428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25429   (exit $ac_status); }; }; then
25430   ac_cv_lib_thread_thr_create=yes
25431 else
25432   echo "$as_me: failed program was:" >&5
25433 sed 's/^/| /' conftest.$ac_ext >&5
25434
25435 ac_cv_lib_thread_thr_create=no
25436 fi
25437 rm -f conftest.err conftest.$ac_objext \
25438       conftest$ac_exeext conftest.$ac_ext
25439 LIBS=$ac_check_lib_save_LIBS
25440 fi
25441 echo "$as_me:$LINENO: result: $ac_cv_lib_thread_thr_create" >&5
25442 echo "${ECHO_T}$ac_cv_lib_thread_thr_create" >&6
25443 if test $ac_cv_lib_thread_thr_create = yes; then
25444   have_thr=yes
25445 else
25446   have_thr=no
25447 fi
25448
25449
25450                 if test $have_thr = yes ; then
25451
25452 cat >>confdefs.h <<\_ACEOF
25453 #define HAVE_THR 1
25454 _ACEOF
25455
25456                         LTHREAD_LIBS="$LTHREAD_LIBS -lthread"
25457                         ol_link_threads=thr
25458
25459                         if test $ol_with_yielding_select = auto ; then
25460                                 ol_with_yielding_select=yes
25461                         fi
25462
25463
25464
25465 for ac_func in \
25466                                 thr_setconcurrency \
25467                                 thr_getconcurrency \
25468
25469 do
25470 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
25471 echo "$as_me:$LINENO: checking for $ac_func" >&5
25472 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
25473 if eval "test \"\${$as_ac_var+set}\" = set"; then
25474   echo $ECHO_N "(cached) $ECHO_C" >&6
25475 else
25476   cat >conftest.$ac_ext <<_ACEOF
25477 /* confdefs.h.  */
25478 _ACEOF
25479 cat confdefs.h >>conftest.$ac_ext
25480 cat >>conftest.$ac_ext <<_ACEOF
25481 /* end confdefs.h.  */
25482 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
25483    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
25484 #define $ac_func innocuous_$ac_func
25485
25486 /* System header to define __stub macros and hopefully few prototypes,
25487     which can conflict with char $ac_func (); below.
25488     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
25489     <limits.h> exists even on freestanding compilers.  */
25490
25491 #ifdef __STDC__
25492 # include <limits.h>
25493 #else
25494 # include <assert.h>
25495 #endif
25496
25497 #undef $ac_func
25498
25499 /* Override any gcc2 internal prototype to avoid an error.  */
25500 #ifdef __cplusplus
25501 extern "C"
25502 {
25503 #endif
25504 /* We use char because int might match the return type of a gcc2
25505    builtin and then its argument prototype would still apply.  */
25506 char $ac_func ();
25507 /* The GNU C library defines this for functions which it implements
25508     to always fail with ENOSYS.  Some functions are actually named
25509     something starting with __ and the normal name is an alias.  */
25510 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
25511 choke me
25512 #else
25513 char (*f) () = $ac_func;
25514 #endif
25515 #ifdef __cplusplus
25516 }
25517 #endif
25518
25519 int
25520 main ()
25521 {
25522 return f != $ac_func;
25523   ;
25524   return 0;
25525 }
25526 _ACEOF
25527 rm -f conftest.$ac_objext conftest$ac_exeext
25528 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25529   (eval $ac_link) 2>conftest.er1
25530   ac_status=$?
25531   grep -v '^ *+' conftest.er1 >conftest.err
25532   rm -f conftest.er1
25533   cat conftest.err >&5
25534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25535   (exit $ac_status); } &&
25536          { ac_try='test -z "$ac_c_werror_flag"
25537                          || test ! -s conftest.err'
25538   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25539   (eval $ac_try) 2>&5
25540   ac_status=$?
25541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25542   (exit $ac_status); }; } &&
25543          { ac_try='test -s conftest$ac_exeext'
25544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25545   (eval $ac_try) 2>&5
25546   ac_status=$?
25547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25548   (exit $ac_status); }; }; then
25549   eval "$as_ac_var=yes"
25550 else
25551   echo "$as_me: failed program was:" >&5
25552 sed 's/^/| /' conftest.$ac_ext >&5
25553
25554 eval "$as_ac_var=no"
25555 fi
25556 rm -f conftest.err conftest.$ac_objext \
25557       conftest$ac_exeext conftest.$ac_ext
25558 fi
25559 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
25560 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
25561 if test `eval echo '${'$as_ac_var'}'` = yes; then
25562   cat >>confdefs.h <<_ACEOF
25563 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
25564 _ACEOF
25565
25566 fi
25567 done
25568
25569                 fi
25570         fi
25571
25572
25573 for ac_header in lwp/lwp.h
25574 do
25575 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25576 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25577   echo "$as_me:$LINENO: checking for $ac_header" >&5
25578 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25579 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25580   echo $ECHO_N "(cached) $ECHO_C" >&6
25581 fi
25582 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25583 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25584 else
25585   # Is the header compilable?
25586 echo "$as_me:$LINENO: checking $ac_header usability" >&5
25587 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
25588 cat >conftest.$ac_ext <<_ACEOF
25589 /* confdefs.h.  */
25590 _ACEOF
25591 cat confdefs.h >>conftest.$ac_ext
25592 cat >>conftest.$ac_ext <<_ACEOF
25593 /* end confdefs.h.  */
25594 $ac_includes_default
25595 #include <$ac_header>
25596 _ACEOF
25597 rm -f conftest.$ac_objext
25598 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
25599   (eval $ac_compile) 2>conftest.er1
25600   ac_status=$?
25601   grep -v '^ *+' conftest.er1 >conftest.err
25602   rm -f conftest.er1
25603   cat conftest.err >&5
25604   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25605   (exit $ac_status); } &&
25606          { ac_try='test -z "$ac_c_werror_flag"
25607                          || test ! -s conftest.err'
25608   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25609   (eval $ac_try) 2>&5
25610   ac_status=$?
25611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25612   (exit $ac_status); }; } &&
25613          { ac_try='test -s conftest.$ac_objext'
25614   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25615   (eval $ac_try) 2>&5
25616   ac_status=$?
25617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25618   (exit $ac_status); }; }; then
25619   ac_header_compiler=yes
25620 else
25621   echo "$as_me: failed program was:" >&5
25622 sed 's/^/| /' conftest.$ac_ext >&5
25623
25624 ac_header_compiler=no
25625 fi
25626 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
25627 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25628 echo "${ECHO_T}$ac_header_compiler" >&6
25629
25630 # Is the header present?
25631 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25632 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25633 cat >conftest.$ac_ext <<_ACEOF
25634 /* confdefs.h.  */
25635 _ACEOF
25636 cat confdefs.h >>conftest.$ac_ext
25637 cat >>conftest.$ac_ext <<_ACEOF
25638 /* end confdefs.h.  */
25639 #include <$ac_header>
25640 _ACEOF
25641 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25642   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25643   ac_status=$?
25644   grep -v '^ *+' conftest.er1 >conftest.err
25645   rm -f conftest.er1
25646   cat conftest.err >&5
25647   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25648   (exit $ac_status); } >/dev/null; then
25649   if test -s conftest.err; then
25650     ac_cpp_err=$ac_c_preproc_warn_flag
25651     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25652   else
25653     ac_cpp_err=
25654   fi
25655 else
25656   ac_cpp_err=yes
25657 fi
25658 if test -z "$ac_cpp_err"; then
25659   ac_header_preproc=yes
25660 else
25661   echo "$as_me: failed program was:" >&5
25662 sed 's/^/| /' conftest.$ac_ext >&5
25663
25664   ac_header_preproc=no
25665 fi
25666 rm -f conftest.err conftest.$ac_ext
25667 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25668 echo "${ECHO_T}$ac_header_preproc" >&6
25669
25670 # So?  What about this header?
25671 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25672   yes:no: )
25673     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25674 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25675     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25676 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25677     ac_header_preproc=yes
25678     ;;
25679   no:yes:* )
25680     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25681 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25682     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25683 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25684     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25685 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25686     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25687 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25688     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25689 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25690     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25691 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25692     (
25693       cat <<\_ASBOX
25694 ## --------------------------------------------- ##
25695 ## Report this to <http://www.openldap.org/its/> ##
25696 ## --------------------------------------------- ##
25697 _ASBOX
25698     ) |
25699       sed "s/^/$as_me: WARNING:     /" >&2
25700     ;;
25701 esac
25702 echo "$as_me:$LINENO: checking for $ac_header" >&5
25703 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25704 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25705   echo $ECHO_N "(cached) $ECHO_C" >&6
25706 else
25707   eval "$as_ac_Header=\$ac_header_preproc"
25708 fi
25709 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25710 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25711
25712 fi
25713 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25714   cat >>confdefs.h <<_ACEOF
25715 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25716 _ACEOF
25717
25718 fi
25719
25720 done
25721
25722         if test $ac_cv_header_lwp_lwp_h = yes ; then
25723                 echo "$as_me:$LINENO: checking for lwp_create in -llwp" >&5
25724 echo $ECHO_N "checking for lwp_create in -llwp... $ECHO_C" >&6
25725 if test "${ac_cv_lib_lwp_lwp_create+set}" = set; then
25726   echo $ECHO_N "(cached) $ECHO_C" >&6
25727 else
25728   ac_check_lib_save_LIBS=$LIBS
25729 LIBS="-llwp  $LIBS"
25730 cat >conftest.$ac_ext <<_ACEOF
25731 /* confdefs.h.  */
25732 _ACEOF
25733 cat confdefs.h >>conftest.$ac_ext
25734 cat >>conftest.$ac_ext <<_ACEOF
25735 /* end confdefs.h.  */
25736
25737 /* Override any gcc2 internal prototype to avoid an error.  */
25738 #ifdef __cplusplus
25739 extern "C"
25740 #endif
25741 /* We use char because int might match the return type of a gcc2
25742    builtin and then its argument prototype would still apply.  */
25743 char lwp_create ();
25744 int
25745 main ()
25746 {
25747 lwp_create ();
25748   ;
25749   return 0;
25750 }
25751 _ACEOF
25752 rm -f conftest.$ac_objext conftest$ac_exeext
25753 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25754   (eval $ac_link) 2>conftest.er1
25755   ac_status=$?
25756   grep -v '^ *+' conftest.er1 >conftest.err
25757   rm -f conftest.er1
25758   cat conftest.err >&5
25759   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25760   (exit $ac_status); } &&
25761          { ac_try='test -z "$ac_c_werror_flag"
25762                          || test ! -s conftest.err'
25763   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25764   (eval $ac_try) 2>&5
25765   ac_status=$?
25766   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25767   (exit $ac_status); }; } &&
25768          { ac_try='test -s conftest$ac_exeext'
25769   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25770   (eval $ac_try) 2>&5
25771   ac_status=$?
25772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25773   (exit $ac_status); }; }; then
25774   ac_cv_lib_lwp_lwp_create=yes
25775 else
25776   echo "$as_me: failed program was:" >&5
25777 sed 's/^/| /' conftest.$ac_ext >&5
25778
25779 ac_cv_lib_lwp_lwp_create=no
25780 fi
25781 rm -f conftest.err conftest.$ac_objext \
25782       conftest$ac_exeext conftest.$ac_ext
25783 LIBS=$ac_check_lib_save_LIBS
25784 fi
25785 echo "$as_me:$LINENO: result: $ac_cv_lib_lwp_lwp_create" >&5
25786 echo "${ECHO_T}$ac_cv_lib_lwp_lwp_create" >&6
25787 if test $ac_cv_lib_lwp_lwp_create = yes; then
25788   have_lwp=yes
25789 else
25790   have_lwp=no
25791 fi
25792
25793
25794                 if test $have_lwp = yes ; then
25795
25796 cat >>confdefs.h <<\_ACEOF
25797 #define HAVE_LWP 1
25798 _ACEOF
25799
25800                         LTHREAD_LIBS="$LTHREAD_LIBS -llwp"
25801                         ol_link_threads=lwp
25802
25803                         if test $ol_with_yielding_select = auto ; then
25804                                 ol_with_yielding_select=no
25805                         fi
25806                 fi
25807         fi
25808         ;;
25809 esac
25810
25811 if test $ol_with_yielding_select = yes ; then
25812
25813 cat >>confdefs.h <<\_ACEOF
25814 #define HAVE_YIELDING_SELECT 1
25815 _ACEOF
25816
25817 fi
25818
25819 if test $ol_with_threads = manual ; then
25820                 ol_link_threads=yes
25821
25822         { echo "$as_me:$LINENO: WARNING: thread defines and link options must be set manually" >&5
25823 echo "$as_me: WARNING: thread defines and link options must be set manually" >&2;}
25824
25825
25826
25827 for ac_header in pthread.h sched.h
25828 do
25829 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25830 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25831   echo "$as_me:$LINENO: checking for $ac_header" >&5
25832 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25833 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25834   echo $ECHO_N "(cached) $ECHO_C" >&6
25835 fi
25836 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25837 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25838 else
25839   # Is the header compilable?
25840 echo "$as_me:$LINENO: checking $ac_header usability" >&5
25841 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
25842 cat >conftest.$ac_ext <<_ACEOF
25843 /* confdefs.h.  */
25844 _ACEOF
25845 cat confdefs.h >>conftest.$ac_ext
25846 cat >>conftest.$ac_ext <<_ACEOF
25847 /* end confdefs.h.  */
25848 $ac_includes_default
25849 #include <$ac_header>
25850 _ACEOF
25851 rm -f conftest.$ac_objext
25852 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
25853   (eval $ac_compile) 2>conftest.er1
25854   ac_status=$?
25855   grep -v '^ *+' conftest.er1 >conftest.err
25856   rm -f conftest.er1
25857   cat conftest.err >&5
25858   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25859   (exit $ac_status); } &&
25860          { ac_try='test -z "$ac_c_werror_flag"
25861                          || test ! -s conftest.err'
25862   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25863   (eval $ac_try) 2>&5
25864   ac_status=$?
25865   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25866   (exit $ac_status); }; } &&
25867          { ac_try='test -s conftest.$ac_objext'
25868   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25869   (eval $ac_try) 2>&5
25870   ac_status=$?
25871   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25872   (exit $ac_status); }; }; then
25873   ac_header_compiler=yes
25874 else
25875   echo "$as_me: failed program was:" >&5
25876 sed 's/^/| /' conftest.$ac_ext >&5
25877
25878 ac_header_compiler=no
25879 fi
25880 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
25881 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25882 echo "${ECHO_T}$ac_header_compiler" >&6
25883
25884 # Is the header present?
25885 echo "$as_me:$LINENO: checking $ac_header presence" >&5
25886 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
25887 cat >conftest.$ac_ext <<_ACEOF
25888 /* confdefs.h.  */
25889 _ACEOF
25890 cat confdefs.h >>conftest.$ac_ext
25891 cat >>conftest.$ac_ext <<_ACEOF
25892 /* end confdefs.h.  */
25893 #include <$ac_header>
25894 _ACEOF
25895 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
25896   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
25897   ac_status=$?
25898   grep -v '^ *+' conftest.er1 >conftest.err
25899   rm -f conftest.er1
25900   cat conftest.err >&5
25901   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25902   (exit $ac_status); } >/dev/null; then
25903   if test -s conftest.err; then
25904     ac_cpp_err=$ac_c_preproc_warn_flag
25905     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
25906   else
25907     ac_cpp_err=
25908   fi
25909 else
25910   ac_cpp_err=yes
25911 fi
25912 if test -z "$ac_cpp_err"; then
25913   ac_header_preproc=yes
25914 else
25915   echo "$as_me: failed program was:" >&5
25916 sed 's/^/| /' conftest.$ac_ext >&5
25917
25918   ac_header_preproc=no
25919 fi
25920 rm -f conftest.err conftest.$ac_ext
25921 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25922 echo "${ECHO_T}$ac_header_preproc" >&6
25923
25924 # So?  What about this header?
25925 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25926   yes:no: )
25927     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25928 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25929     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25930 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25931     ac_header_preproc=yes
25932     ;;
25933   no:yes:* )
25934     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25935 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25936     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25937 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25938     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25939 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25940     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25941 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25942     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25943 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25944     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25945 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25946     (
25947       cat <<\_ASBOX
25948 ## --------------------------------------------- ##
25949 ## Report this to <http://www.openldap.org/its/> ##
25950 ## --------------------------------------------- ##
25951 _ASBOX
25952     ) |
25953       sed "s/^/$as_me: WARNING:     /" >&2
25954     ;;
25955 esac
25956 echo "$as_me:$LINENO: checking for $ac_header" >&5
25957 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
25958 if eval "test \"\${$as_ac_Header+set}\" = set"; then
25959   echo $ECHO_N "(cached) $ECHO_C" >&6
25960 else
25961   eval "$as_ac_Header=\$ac_header_preproc"
25962 fi
25963 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
25964 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
25965
25966 fi
25967 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25968   cat >>confdefs.h <<_ACEOF
25969 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25970 _ACEOF
25971
25972 fi
25973
25974 done
25975
25976
25977
25978 for ac_func in sched_yield pthread_yield
25979 do
25980 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
25981 echo "$as_me:$LINENO: checking for $ac_func" >&5
25982 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
25983 if eval "test \"\${$as_ac_var+set}\" = set"; then
25984   echo $ECHO_N "(cached) $ECHO_C" >&6
25985 else
25986   cat >conftest.$ac_ext <<_ACEOF
25987 /* confdefs.h.  */
25988 _ACEOF
25989 cat confdefs.h >>conftest.$ac_ext
25990 cat >>conftest.$ac_ext <<_ACEOF
25991 /* end confdefs.h.  */
25992 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
25993    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
25994 #define $ac_func innocuous_$ac_func
25995
25996 /* System header to define __stub macros and hopefully few prototypes,
25997     which can conflict with char $ac_func (); below.
25998     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
25999     <limits.h> exists even on freestanding compilers.  */
26000
26001 #ifdef __STDC__
26002 # include <limits.h>
26003 #else
26004 # include <assert.h>
26005 #endif
26006
26007 #undef $ac_func
26008
26009 /* Override any gcc2 internal prototype to avoid an error.  */
26010 #ifdef __cplusplus
26011 extern "C"
26012 {
26013 #endif
26014 /* We use char because int might match the return type of a gcc2
26015    builtin and then its argument prototype would still apply.  */
26016 char $ac_func ();
26017 /* The GNU C library defines this for functions which it implements
26018     to always fail with ENOSYS.  Some functions are actually named
26019     something starting with __ and the normal name is an alias.  */
26020 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
26021 choke me
26022 #else
26023 char (*f) () = $ac_func;
26024 #endif
26025 #ifdef __cplusplus
26026 }
26027 #endif
26028
26029 int
26030 main ()
26031 {
26032 return f != $ac_func;
26033   ;
26034   return 0;
26035 }
26036 _ACEOF
26037 rm -f conftest.$ac_objext conftest$ac_exeext
26038 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26039   (eval $ac_link) 2>conftest.er1
26040   ac_status=$?
26041   grep -v '^ *+' conftest.er1 >conftest.err
26042   rm -f conftest.er1
26043   cat conftest.err >&5
26044   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26045   (exit $ac_status); } &&
26046          { ac_try='test -z "$ac_c_werror_flag"
26047                          || test ! -s conftest.err'
26048   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26049   (eval $ac_try) 2>&5
26050   ac_status=$?
26051   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26052   (exit $ac_status); }; } &&
26053          { ac_try='test -s conftest$ac_exeext'
26054   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26055   (eval $ac_try) 2>&5
26056   ac_status=$?
26057   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26058   (exit $ac_status); }; }; then
26059   eval "$as_ac_var=yes"
26060 else
26061   echo "$as_me: failed program was:" >&5
26062 sed 's/^/| /' conftest.$ac_ext >&5
26063
26064 eval "$as_ac_var=no"
26065 fi
26066 rm -f conftest.err conftest.$ac_objext \
26067       conftest$ac_exeext conftest.$ac_ext
26068 fi
26069 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
26070 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
26071 if test `eval echo '${'$as_ac_var'}'` = yes; then
26072   cat >>confdefs.h <<_ACEOF
26073 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
26074 _ACEOF
26075
26076 fi
26077 done
26078
26079
26080         echo "$as_me:$LINENO: checking for LinuxThreads pthread.h" >&5
26081 echo $ECHO_N "checking for LinuxThreads pthread.h... $ECHO_C" >&6
26082 if test "${ol_cv_header_linux_threads+set}" = set; then
26083   echo $ECHO_N "(cached) $ECHO_C" >&6
26084 else
26085   cat >conftest.$ac_ext <<_ACEOF
26086 /* confdefs.h.  */
26087 _ACEOF
26088 cat confdefs.h >>conftest.$ac_ext
26089 cat >>conftest.$ac_ext <<_ACEOF
26090 /* end confdefs.h.  */
26091 #include <pthread.h>
26092 _ACEOF
26093 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
26094   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then
26095   ol_cv_header_linux_threads=yes
26096 else
26097   ol_cv_header_linux_threads=no
26098 fi
26099 rm -f conftest*
26100
26101
26102 fi
26103 echo "$as_me:$LINENO: result: $ol_cv_header_linux_threads" >&5
26104 echo "${ECHO_T}$ol_cv_header_linux_threads" >&6
26105         if test $ol_cv_header_linux_threads = yes; then
26106
26107 cat >>confdefs.h <<\_ACEOF
26108 #define HAVE_LINUX_THREADS 1
26109 _ACEOF
26110
26111         fi
26112
26113
26114
26115 for ac_header in mach/cthreads.h
26116 do
26117 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26118 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26119   echo "$as_me:$LINENO: checking for $ac_header" >&5
26120 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26121 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26122   echo $ECHO_N "(cached) $ECHO_C" >&6
26123 fi
26124 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26125 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26126 else
26127   # Is the header compilable?
26128 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26129 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26130 cat >conftest.$ac_ext <<_ACEOF
26131 /* confdefs.h.  */
26132 _ACEOF
26133 cat confdefs.h >>conftest.$ac_ext
26134 cat >>conftest.$ac_ext <<_ACEOF
26135 /* end confdefs.h.  */
26136 $ac_includes_default
26137 #include <$ac_header>
26138 _ACEOF
26139 rm -f conftest.$ac_objext
26140 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26141   (eval $ac_compile) 2>conftest.er1
26142   ac_status=$?
26143   grep -v '^ *+' conftest.er1 >conftest.err
26144   rm -f conftest.er1
26145   cat conftest.err >&5
26146   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26147   (exit $ac_status); } &&
26148          { ac_try='test -z "$ac_c_werror_flag"
26149                          || test ! -s conftest.err'
26150   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26151   (eval $ac_try) 2>&5
26152   ac_status=$?
26153   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26154   (exit $ac_status); }; } &&
26155          { ac_try='test -s conftest.$ac_objext'
26156   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26157   (eval $ac_try) 2>&5
26158   ac_status=$?
26159   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26160   (exit $ac_status); }; }; then
26161   ac_header_compiler=yes
26162 else
26163   echo "$as_me: failed program was:" >&5
26164 sed 's/^/| /' conftest.$ac_ext >&5
26165
26166 ac_header_compiler=no
26167 fi
26168 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26169 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26170 echo "${ECHO_T}$ac_header_compiler" >&6
26171
26172 # Is the header present?
26173 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26174 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26175 cat >conftest.$ac_ext <<_ACEOF
26176 /* confdefs.h.  */
26177 _ACEOF
26178 cat confdefs.h >>conftest.$ac_ext
26179 cat >>conftest.$ac_ext <<_ACEOF
26180 /* end confdefs.h.  */
26181 #include <$ac_header>
26182 _ACEOF
26183 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26184   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26185   ac_status=$?
26186   grep -v '^ *+' conftest.er1 >conftest.err
26187   rm -f conftest.er1
26188   cat conftest.err >&5
26189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26190   (exit $ac_status); } >/dev/null; then
26191   if test -s conftest.err; then
26192     ac_cpp_err=$ac_c_preproc_warn_flag
26193     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26194   else
26195     ac_cpp_err=
26196   fi
26197 else
26198   ac_cpp_err=yes
26199 fi
26200 if test -z "$ac_cpp_err"; then
26201   ac_header_preproc=yes
26202 else
26203   echo "$as_me: failed program was:" >&5
26204 sed 's/^/| /' conftest.$ac_ext >&5
26205
26206   ac_header_preproc=no
26207 fi
26208 rm -f conftest.err conftest.$ac_ext
26209 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26210 echo "${ECHO_T}$ac_header_preproc" >&6
26211
26212 # So?  What about this header?
26213 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26214   yes:no: )
26215     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26216 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26217     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26218 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26219     ac_header_preproc=yes
26220     ;;
26221   no:yes:* )
26222     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26223 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26224     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26225 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26226     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26227 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26228     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26229 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26230     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26231 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26232     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26233 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26234     (
26235       cat <<\_ASBOX
26236 ## --------------------------------------------- ##
26237 ## Report this to <http://www.openldap.org/its/> ##
26238 ## --------------------------------------------- ##
26239 _ASBOX
26240     ) |
26241       sed "s/^/$as_me: WARNING:     /" >&2
26242     ;;
26243 esac
26244 echo "$as_me:$LINENO: checking for $ac_header" >&5
26245 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26246 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26247   echo $ECHO_N "(cached) $ECHO_C" >&6
26248 else
26249   eval "$as_ac_Header=\$ac_header_preproc"
26250 fi
26251 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26252 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26253
26254 fi
26255 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26256   cat >>confdefs.h <<_ACEOF
26257 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26258 _ACEOF
26259
26260 fi
26261
26262 done
26263
26264
26265 for ac_header in lwp/lwp.h
26266 do
26267 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26268 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26269   echo "$as_me:$LINENO: checking for $ac_header" >&5
26270 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26271 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26272   echo $ECHO_N "(cached) $ECHO_C" >&6
26273 fi
26274 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26275 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26276 else
26277   # Is the header compilable?
26278 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26279 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26280 cat >conftest.$ac_ext <<_ACEOF
26281 /* confdefs.h.  */
26282 _ACEOF
26283 cat confdefs.h >>conftest.$ac_ext
26284 cat >>conftest.$ac_ext <<_ACEOF
26285 /* end confdefs.h.  */
26286 $ac_includes_default
26287 #include <$ac_header>
26288 _ACEOF
26289 rm -f conftest.$ac_objext
26290 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26291   (eval $ac_compile) 2>conftest.er1
26292   ac_status=$?
26293   grep -v '^ *+' conftest.er1 >conftest.err
26294   rm -f conftest.er1
26295   cat conftest.err >&5
26296   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26297   (exit $ac_status); } &&
26298          { ac_try='test -z "$ac_c_werror_flag"
26299                          || test ! -s conftest.err'
26300   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26301   (eval $ac_try) 2>&5
26302   ac_status=$?
26303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26304   (exit $ac_status); }; } &&
26305          { ac_try='test -s conftest.$ac_objext'
26306   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26307   (eval $ac_try) 2>&5
26308   ac_status=$?
26309   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26310   (exit $ac_status); }; }; then
26311   ac_header_compiler=yes
26312 else
26313   echo "$as_me: failed program was:" >&5
26314 sed 's/^/| /' conftest.$ac_ext >&5
26315
26316 ac_header_compiler=no
26317 fi
26318 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26319 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26320 echo "${ECHO_T}$ac_header_compiler" >&6
26321
26322 # Is the header present?
26323 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26324 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26325 cat >conftest.$ac_ext <<_ACEOF
26326 /* confdefs.h.  */
26327 _ACEOF
26328 cat confdefs.h >>conftest.$ac_ext
26329 cat >>conftest.$ac_ext <<_ACEOF
26330 /* end confdefs.h.  */
26331 #include <$ac_header>
26332 _ACEOF
26333 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26334   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26335   ac_status=$?
26336   grep -v '^ *+' conftest.er1 >conftest.err
26337   rm -f conftest.er1
26338   cat conftest.err >&5
26339   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26340   (exit $ac_status); } >/dev/null; then
26341   if test -s conftest.err; then
26342     ac_cpp_err=$ac_c_preproc_warn_flag
26343     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26344   else
26345     ac_cpp_err=
26346   fi
26347 else
26348   ac_cpp_err=yes
26349 fi
26350 if test -z "$ac_cpp_err"; then
26351   ac_header_preproc=yes
26352 else
26353   echo "$as_me: failed program was:" >&5
26354 sed 's/^/| /' conftest.$ac_ext >&5
26355
26356   ac_header_preproc=no
26357 fi
26358 rm -f conftest.err conftest.$ac_ext
26359 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26360 echo "${ECHO_T}$ac_header_preproc" >&6
26361
26362 # So?  What about this header?
26363 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26364   yes:no: )
26365     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26366 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26367     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26368 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26369     ac_header_preproc=yes
26370     ;;
26371   no:yes:* )
26372     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26373 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26374     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26375 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26376     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26377 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26378     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26379 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26380     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26381 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26382     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26383 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26384     (
26385       cat <<\_ASBOX
26386 ## --------------------------------------------- ##
26387 ## Report this to <http://www.openldap.org/its/> ##
26388 ## --------------------------------------------- ##
26389 _ASBOX
26390     ) |
26391       sed "s/^/$as_me: WARNING:     /" >&2
26392     ;;
26393 esac
26394 echo "$as_me:$LINENO: checking for $ac_header" >&5
26395 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26396 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26397   echo $ECHO_N "(cached) $ECHO_C" >&6
26398 else
26399   eval "$as_ac_Header=\$ac_header_preproc"
26400 fi
26401 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26402 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26403
26404 fi
26405 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26406   cat >>confdefs.h <<_ACEOF
26407 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26408 _ACEOF
26409
26410 fi
26411
26412 done
26413
26414
26415
26416 for ac_header in thread.h synch.h
26417 do
26418 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26419 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26420   echo "$as_me:$LINENO: checking for $ac_header" >&5
26421 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26422 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26423   echo $ECHO_N "(cached) $ECHO_C" >&6
26424 fi
26425 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26426 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26427 else
26428   # Is the header compilable?
26429 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26430 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26431 cat >conftest.$ac_ext <<_ACEOF
26432 /* confdefs.h.  */
26433 _ACEOF
26434 cat confdefs.h >>conftest.$ac_ext
26435 cat >>conftest.$ac_ext <<_ACEOF
26436 /* end confdefs.h.  */
26437 $ac_includes_default
26438 #include <$ac_header>
26439 _ACEOF
26440 rm -f conftest.$ac_objext
26441 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26442   (eval $ac_compile) 2>conftest.er1
26443   ac_status=$?
26444   grep -v '^ *+' conftest.er1 >conftest.err
26445   rm -f conftest.er1
26446   cat conftest.err >&5
26447   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26448   (exit $ac_status); } &&
26449          { ac_try='test -z "$ac_c_werror_flag"
26450                          || test ! -s conftest.err'
26451   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26452   (eval $ac_try) 2>&5
26453   ac_status=$?
26454   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26455   (exit $ac_status); }; } &&
26456          { ac_try='test -s conftest.$ac_objext'
26457   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26458   (eval $ac_try) 2>&5
26459   ac_status=$?
26460   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26461   (exit $ac_status); }; }; then
26462   ac_header_compiler=yes
26463 else
26464   echo "$as_me: failed program was:" >&5
26465 sed 's/^/| /' conftest.$ac_ext >&5
26466
26467 ac_header_compiler=no
26468 fi
26469 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26470 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26471 echo "${ECHO_T}$ac_header_compiler" >&6
26472
26473 # Is the header present?
26474 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26475 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26476 cat >conftest.$ac_ext <<_ACEOF
26477 /* confdefs.h.  */
26478 _ACEOF
26479 cat confdefs.h >>conftest.$ac_ext
26480 cat >>conftest.$ac_ext <<_ACEOF
26481 /* end confdefs.h.  */
26482 #include <$ac_header>
26483 _ACEOF
26484 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26485   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26486   ac_status=$?
26487   grep -v '^ *+' conftest.er1 >conftest.err
26488   rm -f conftest.er1
26489   cat conftest.err >&5
26490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26491   (exit $ac_status); } >/dev/null; then
26492   if test -s conftest.err; then
26493     ac_cpp_err=$ac_c_preproc_warn_flag
26494     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
26495   else
26496     ac_cpp_err=
26497   fi
26498 else
26499   ac_cpp_err=yes
26500 fi
26501 if test -z "$ac_cpp_err"; then
26502   ac_header_preproc=yes
26503 else
26504   echo "$as_me: failed program was:" >&5
26505 sed 's/^/| /' conftest.$ac_ext >&5
26506
26507   ac_header_preproc=no
26508 fi
26509 rm -f conftest.err conftest.$ac_ext
26510 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26511 echo "${ECHO_T}$ac_header_preproc" >&6
26512
26513 # So?  What about this header?
26514 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26515   yes:no: )
26516     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26517 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26518     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
26519 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
26520     ac_header_preproc=yes
26521     ;;
26522   no:yes:* )
26523     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26524 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26525     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
26526 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
26527     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
26528 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
26529     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
26530 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
26531     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26532 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26533     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
26534 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
26535     (
26536       cat <<\_ASBOX
26537 ## --------------------------------------------- ##
26538 ## Report this to <http://www.openldap.org/its/> ##
26539 ## --------------------------------------------- ##
26540 _ASBOX
26541     ) |
26542       sed "s/^/$as_me: WARNING:     /" >&2
26543     ;;
26544 esac
26545 echo "$as_me:$LINENO: checking for $ac_header" >&5
26546 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26547 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26548   echo $ECHO_N "(cached) $ECHO_C" >&6
26549 else
26550   eval "$as_ac_Header=\$ac_header_preproc"
26551 fi
26552 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26553 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26554
26555 fi
26556 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26557   cat >>confdefs.h <<_ACEOF
26558 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26559 _ACEOF
26560
26561 fi
26562
26563 done
26564
26565 fi
26566
26567 if test $ol_link_threads != no && test $ol_link_threads != nt ; then
26568                         cat >>confdefs.h <<\_ACEOF
26569 #define REENTRANT 1
26570 _ACEOF
26571
26572         cat >>confdefs.h <<\_ACEOF
26573 #define _REENTRANT 1
26574 _ACEOF
26575
26576         cat >>confdefs.h <<\_ACEOF
26577 #define THREAD_SAFE 1
26578 _ACEOF
26579
26580         cat >>confdefs.h <<\_ACEOF
26581 #define _THREAD_SAFE 1
26582 _ACEOF
26583
26584         cat >>confdefs.h <<\_ACEOF
26585 #define THREADSAFE 1
26586 _ACEOF
26587
26588         cat >>confdefs.h <<\_ACEOF
26589 #define _THREADSAFE 1
26590 _ACEOF
26591
26592         cat >>confdefs.h <<\_ACEOF
26593 #define _SGI_MP_SOURCE 1
26594 _ACEOF
26595
26596
26597                         echo "$as_me:$LINENO: checking for thread specific errno" >&5
26598 echo $ECHO_N "checking for thread specific errno... $ECHO_C" >&6
26599 if test "${ol_cv_errno_thread_specific+set}" = set; then
26600   echo $ECHO_N "(cached) $ECHO_C" >&6
26601 else
26602
26603                 cat >conftest.$ac_ext <<_ACEOF
26604 /* confdefs.h.  */
26605 _ACEOF
26606 cat confdefs.h >>conftest.$ac_ext
26607 cat >>conftest.$ac_ext <<_ACEOF
26608 /* end confdefs.h.  */
26609 #include <errno.h>
26610 int
26611 main ()
26612 {
26613 errno = 0;
26614   ;
26615   return 0;
26616 }
26617 _ACEOF
26618 rm -f conftest.$ac_objext conftest$ac_exeext
26619 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26620   (eval $ac_link) 2>conftest.er1
26621   ac_status=$?
26622   grep -v '^ *+' conftest.er1 >conftest.err
26623   rm -f conftest.er1
26624   cat conftest.err >&5
26625   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26626   (exit $ac_status); } &&
26627          { ac_try='test -z "$ac_c_werror_flag"
26628                          || test ! -s conftest.err'
26629   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26630   (eval $ac_try) 2>&5
26631   ac_status=$?
26632   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26633   (exit $ac_status); }; } &&
26634          { ac_try='test -s conftest$ac_exeext'
26635   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26636   (eval $ac_try) 2>&5
26637   ac_status=$?
26638   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26639   (exit $ac_status); }; }; then
26640   ol_cv_errno_thread_specific=yes
26641 else
26642   echo "$as_me: failed program was:" >&5
26643 sed 's/^/| /' conftest.$ac_ext >&5
26644
26645 ol_cv_errno_thread_specific=no
26646 fi
26647 rm -f conftest.err conftest.$ac_objext \
26648       conftest$ac_exeext conftest.$ac_ext
26649
26650 fi
26651 echo "$as_me:$LINENO: result: $ol_cv_errno_thread_specific" >&5
26652 echo "${ECHO_T}$ol_cv_errno_thread_specific" >&6
26653
26654                         echo "$as_me:$LINENO: checking for thread specific h_errno" >&5
26655 echo $ECHO_N "checking for thread specific h_errno... $ECHO_C" >&6
26656 if test "${ol_cv_h_errno_thread_specific+set}" = set; then
26657   echo $ECHO_N "(cached) $ECHO_C" >&6
26658 else
26659
26660                 cat >conftest.$ac_ext <<_ACEOF
26661 /* confdefs.h.  */
26662 _ACEOF
26663 cat confdefs.h >>conftest.$ac_ext
26664 cat >>conftest.$ac_ext <<_ACEOF
26665 /* end confdefs.h.  */
26666 #include <netdb.h>
26667 int
26668 main ()
26669 {
26670 h_errno = 0;
26671   ;
26672   return 0;
26673 }
26674 _ACEOF
26675 rm -f conftest.$ac_objext conftest$ac_exeext
26676 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26677   (eval $ac_link) 2>conftest.er1
26678   ac_status=$?
26679   grep -v '^ *+' conftest.er1 >conftest.err
26680   rm -f conftest.er1
26681   cat conftest.err >&5
26682   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26683   (exit $ac_status); } &&
26684          { ac_try='test -z "$ac_c_werror_flag"
26685                          || test ! -s conftest.err'
26686   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26687   (eval $ac_try) 2>&5
26688   ac_status=$?
26689   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26690   (exit $ac_status); }; } &&
26691          { ac_try='test -s conftest$ac_exeext'
26692   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26693   (eval $ac_try) 2>&5
26694   ac_status=$?
26695   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26696   (exit $ac_status); }; }; then
26697   ol_cv_h_errno_thread_specific=yes
26698 else
26699   echo "$as_me: failed program was:" >&5
26700 sed 's/^/| /' conftest.$ac_ext >&5
26701
26702 ol_cv_h_errno_thread_specific=no
26703 fi
26704 rm -f conftest.err conftest.$ac_objext \
26705       conftest$ac_exeext conftest.$ac_ext
26706
26707 fi
26708 echo "$as_me:$LINENO: result: $ol_cv_h_errno_thread_specific" >&5
26709 echo "${ECHO_T}$ol_cv_h_errno_thread_specific" >&6
26710
26711         if test $ol_cv_errno_thread_specific != yes ||
26712            test $ol_cv_h_errno_thread_specific != yes ; then
26713                 LIBS="$LTHREAD_LIBS $LIBS"
26714                 LTHREAD_LIBS=""
26715         fi
26716
26717 fi
26718
26719 if test $ol_link_threads = no ; then
26720         if test $ol_with_threads = yes ; then
26721                 { { echo "$as_me:$LINENO: error: no suitable thread support" >&5
26722 echo "$as_me: error: no suitable thread support" >&2;}
26723    { (exit 1); exit 1; }; }
26724         fi
26725
26726         if test $ol_with_threads = auto ; then
26727                 { echo "$as_me:$LINENO: WARNING: no suitable thread support, disabling threads" >&5
26728 echo "$as_me: WARNING: no suitable thread support, disabling threads" >&2;}
26729                 ol_with_threads=no
26730         fi
26731
26732
26733 cat >>confdefs.h <<\_ACEOF
26734 #define NO_THREADS 1
26735 _ACEOF
26736
26737         LTHREAD_LIBS=""
26738         BUILD_THREAD=no
26739 else
26740         BUILD_THREAD=yes
26741 fi
26742
26743 if test $ol_link_threads != no ; then
26744
26745 cat >>confdefs.h <<\_ACEOF
26746 #define LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE 1
26747 _ACEOF
26748
26749 fi
26750
26751
26752
26753
26754 for ac_func in \
26755         ctime_r                 \
26756         gethostbyname_r gethostbyaddr_r \
26757
26758 do
26759 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
26760 echo "$as_me:$LINENO: checking for $ac_func" >&5
26761 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
26762 if eval "test \"\${$as_ac_var+set}\" = set"; then
26763   echo $ECHO_N "(cached) $ECHO_C" >&6
26764 else
26765   cat >conftest.$ac_ext <<_ACEOF
26766 /* confdefs.h.  */
26767 _ACEOF
26768 cat confdefs.h >>conftest.$ac_ext
26769 cat >>conftest.$ac_ext <<_ACEOF
26770 /* end confdefs.h.  */
26771 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
26772    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
26773 #define $ac_func innocuous_$ac_func
26774
26775 /* System header to define __stub macros and hopefully few prototypes,
26776     which can conflict with char $ac_func (); below.
26777     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
26778     <limits.h> exists even on freestanding compilers.  */
26779
26780 #ifdef __STDC__
26781 # include <limits.h>
26782 #else
26783 # include <assert.h>
26784 #endif
26785
26786 #undef $ac_func
26787
26788 /* Override any gcc2 internal prototype to avoid an error.  */
26789 #ifdef __cplusplus
26790 extern "C"
26791 {
26792 #endif
26793 /* We use char because int might match the return type of a gcc2
26794    builtin and then its argument prototype would still apply.  */
26795 char $ac_func ();
26796 /* The GNU C library defines this for functions which it implements
26797     to always fail with ENOSYS.  Some functions are actually named
26798     something starting with __ and the normal name is an alias.  */
26799 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
26800 choke me
26801 #else
26802 char (*f) () = $ac_func;
26803 #endif
26804 #ifdef __cplusplus
26805 }
26806 #endif
26807
26808 int
26809 main ()
26810 {
26811 return f != $ac_func;
26812   ;
26813   return 0;
26814 }
26815 _ACEOF
26816 rm -f conftest.$ac_objext conftest$ac_exeext
26817 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26818   (eval $ac_link) 2>conftest.er1
26819   ac_status=$?
26820   grep -v '^ *+' conftest.er1 >conftest.err
26821   rm -f conftest.er1
26822   cat conftest.err >&5
26823   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26824   (exit $ac_status); } &&
26825          { ac_try='test -z "$ac_c_werror_flag"
26826                          || test ! -s conftest.err'
26827   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26828   (eval $ac_try) 2>&5
26829   ac_status=$?
26830   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26831   (exit $ac_status); }; } &&
26832          { ac_try='test -s conftest$ac_exeext'
26833   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26834   (eval $ac_try) 2>&5
26835   ac_status=$?
26836   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26837   (exit $ac_status); }; }; then
26838   eval "$as_ac_var=yes"
26839 else
26840   echo "$as_me: failed program was:" >&5
26841 sed 's/^/| /' conftest.$ac_ext >&5
26842
26843 eval "$as_ac_var=no"
26844 fi
26845 rm -f conftest.err conftest.$ac_objext \
26846       conftest$ac_exeext conftest.$ac_ext
26847 fi
26848 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
26849 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
26850 if test `eval echo '${'$as_ac_var'}'` = yes; then
26851   cat >>confdefs.h <<_ACEOF
26852 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
26853 _ACEOF
26854
26855 fi
26856 done
26857
26858
26859 if test "$ac_cv_func_ctime_r" = no ; then
26860         ol_cv_func_ctime_r_nargs=0
26861 else
26862         echo "$as_me:$LINENO: checking number of arguments of ctime_r" >&5
26863 echo $ECHO_N "checking number of arguments of ctime_r... $ECHO_C" >&6
26864 if test "${ol_cv_func_ctime_r_nargs+set}" = set; then
26865   echo $ECHO_N "(cached) $ECHO_C" >&6
26866 else
26867   cat >conftest.$ac_ext <<_ACEOF
26868 /* confdefs.h.  */
26869 _ACEOF
26870 cat confdefs.h >>conftest.$ac_ext
26871 cat >>conftest.$ac_ext <<_ACEOF
26872 /* end confdefs.h.  */
26873 #include <time.h>
26874 int
26875 main ()
26876 {
26877 time_t ti; char *buffer; ctime_r(&ti,buffer,32);
26878   ;
26879   return 0;
26880 }
26881 _ACEOF
26882 rm -f conftest.$ac_objext
26883 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26884   (eval $ac_compile) 2>conftest.er1
26885   ac_status=$?
26886   grep -v '^ *+' conftest.er1 >conftest.err
26887   rm -f conftest.er1
26888   cat conftest.err >&5
26889   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26890   (exit $ac_status); } &&
26891          { ac_try='test -z "$ac_c_werror_flag"
26892                          || test ! -s conftest.err'
26893   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26894   (eval $ac_try) 2>&5
26895   ac_status=$?
26896   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26897   (exit $ac_status); }; } &&
26898          { ac_try='test -s conftest.$ac_objext'
26899   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26900   (eval $ac_try) 2>&5
26901   ac_status=$?
26902   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26903   (exit $ac_status); }; }; then
26904   ol_cv_func_ctime_r_nargs3=yes
26905 else
26906   echo "$as_me: failed program was:" >&5
26907 sed 's/^/| /' conftest.$ac_ext >&5
26908
26909 ol_cv_func_ctime_r_nargs3=no
26910 fi
26911 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26912
26913         cat >conftest.$ac_ext <<_ACEOF
26914 /* confdefs.h.  */
26915 _ACEOF
26916 cat confdefs.h >>conftest.$ac_ext
26917 cat >>conftest.$ac_ext <<_ACEOF
26918 /* end confdefs.h.  */
26919 #include <time.h>
26920 int
26921 main ()
26922 {
26923 time_t ti; char *buffer; ctime_r(&ti,buffer);
26924   ;
26925   return 0;
26926 }
26927 _ACEOF
26928 rm -f conftest.$ac_objext
26929 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26930   (eval $ac_compile) 2>conftest.er1
26931   ac_status=$?
26932   grep -v '^ *+' conftest.er1 >conftest.err
26933   rm -f conftest.er1
26934   cat conftest.err >&5
26935   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26936   (exit $ac_status); } &&
26937          { ac_try='test -z "$ac_c_werror_flag"
26938                          || test ! -s conftest.err'
26939   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26940   (eval $ac_try) 2>&5
26941   ac_status=$?
26942   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26943   (exit $ac_status); }; } &&
26944          { ac_try='test -s conftest.$ac_objext'
26945   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26946   (eval $ac_try) 2>&5
26947   ac_status=$?
26948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26949   (exit $ac_status); }; }; then
26950   ol_cv_func_ctime_r_nargs2=yes
26951 else
26952   echo "$as_me: failed program was:" >&5
26953 sed 's/^/| /' conftest.$ac_ext >&5
26954
26955 ol_cv_func_ctime_r_nargs2=no
26956 fi
26957 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
26958
26959         if test $ol_cv_func_ctime_r_nargs3 = yes &&
26960            test $ol_cv_func_ctime_r_nargs2 = no ; then
26961
26962                 ol_cv_func_ctime_r_nargs=3
26963
26964         elif test $ol_cv_func_ctime_r_nargs3 = no &&
26965              test $ol_cv_func_ctime_r_nargs2 = yes ; then
26966
26967                 ol_cv_func_ctime_r_nargs=2
26968
26969         else
26970                 ol_cv_func_ctime_r_nargs=0
26971         fi
26972
26973 fi
26974 echo "$as_me:$LINENO: result: $ol_cv_func_ctime_r_nargs" >&5
26975 echo "${ECHO_T}$ol_cv_func_ctime_r_nargs" >&6
26976
26977   if test $ol_cv_func_ctime_r_nargs -gt 1 ; then
26978
26979 cat >>confdefs.h <<_ACEOF
26980 #define CTIME_R_NARGS $ol_cv_func_ctime_r_nargs
26981 _ACEOF
26982
26983   fi
26984
26985 fi
26986
26987 if test "$ac_cv_func_gethostbyname_r" = yes ; then
26988         echo "$as_me:$LINENO: checking number of arguments of gethostbyname_r" >&5
26989 echo $ECHO_N "checking number of arguments of gethostbyname_r... $ECHO_C" >&6
26990 if test "${ol_cv_func_gethostbyname_r_nargs+set}" = set; then
26991   echo $ECHO_N "(cached) $ECHO_C" >&6
26992 else
26993   cat >conftest.$ac_ext <<_ACEOF
26994 /* confdefs.h.  */
26995 _ACEOF
26996 cat confdefs.h >>conftest.$ac_ext
26997 cat >>conftest.$ac_ext <<_ACEOF
26998 /* end confdefs.h.  */
26999 #include <sys/types.h>
27000 #include <sys/socket.h>
27001 #include <netinet/in.h>
27002 #include <netdb.h>
27003 #define BUFSIZE (sizeof(struct hostent)+10)
27004 int
27005 main ()
27006 {
27007 struct hostent hent; char buffer[BUFSIZE];
27008                 int bufsize=BUFSIZE;int h_errno;
27009                 (void)gethostbyname_r("segovia.cs.purdue.edu", &hent,
27010                         buffer, bufsize, &h_errno);
27011   ;
27012   return 0;
27013 }
27014 _ACEOF
27015 rm -f conftest.$ac_objext
27016 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27017   (eval $ac_compile) 2>conftest.er1
27018   ac_status=$?
27019   grep -v '^ *+' conftest.er1 >conftest.err
27020   rm -f conftest.er1
27021   cat conftest.err >&5
27022   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27023   (exit $ac_status); } &&
27024          { ac_try='test -z "$ac_c_werror_flag"
27025                          || test ! -s conftest.err'
27026   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27027   (eval $ac_try) 2>&5
27028   ac_status=$?
27029   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27030   (exit $ac_status); }; } &&
27031          { ac_try='test -s conftest.$ac_objext'
27032   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27033   (eval $ac_try) 2>&5
27034   ac_status=$?
27035   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27036   (exit $ac_status); }; }; then
27037   ol_cv_func_gethostbyname_r_nargs5=yes
27038 else
27039   echo "$as_me: failed program was:" >&5
27040 sed 's/^/| /' conftest.$ac_ext >&5
27041
27042 ol_cv_func_gethostbyname_r_nargs5=no
27043 fi
27044 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27045
27046         cat >conftest.$ac_ext <<_ACEOF
27047 /* confdefs.h.  */
27048 _ACEOF
27049 cat confdefs.h >>conftest.$ac_ext
27050 cat >>conftest.$ac_ext <<_ACEOF
27051 /* end confdefs.h.  */
27052 #include <sys/types.h>
27053 #include <sys/socket.h>
27054 #include <netinet/in.h>
27055 #include <netdb.h>
27056 #define BUFSIZE (sizeof(struct hostent)+10)
27057 int
27058 main ()
27059 {
27060 struct hostent hent;struct hostent *rhent;
27061                 char buffer[BUFSIZE];
27062                 int bufsize=BUFSIZE;int h_errno;
27063                 (void)gethostbyname_r("localhost", &hent, buffer, bufsize,
27064                         &rhent, &h_errno);
27065   ;
27066   return 0;
27067 }
27068 _ACEOF
27069 rm -f conftest.$ac_objext
27070 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27071   (eval $ac_compile) 2>conftest.er1
27072   ac_status=$?
27073   grep -v '^ *+' conftest.er1 >conftest.err
27074   rm -f conftest.er1
27075   cat conftest.err >&5
27076   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27077   (exit $ac_status); } &&
27078          { ac_try='test -z "$ac_c_werror_flag"
27079                          || test ! -s conftest.err'
27080   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27081   (eval $ac_try) 2>&5
27082   ac_status=$?
27083   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27084   (exit $ac_status); }; } &&
27085          { ac_try='test -s conftest.$ac_objext'
27086   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27087   (eval $ac_try) 2>&5
27088   ac_status=$?
27089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27090   (exit $ac_status); }; }; then
27091   ol_cv_func_gethostbyname_r_nargs6=yes
27092 else
27093   echo "$as_me: failed program was:" >&5
27094 sed 's/^/| /' conftest.$ac_ext >&5
27095
27096 ol_cv_func_gethostbyname_r_nargs6=no
27097 fi
27098 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27099
27100         if test $ol_cv_func_gethostbyname_r_nargs5 = yes &&
27101            test $ol_cv_func_gethostbyname_r_nargs6 = no ; then
27102
27103                 ol_cv_func_gethostbyname_r_nargs=5
27104
27105         elif test $ol_cv_func_gethostbyname_r_nargs5 = no &&
27106              test $ol_cv_func_gethostbyname_r_nargs6 = yes ; then
27107
27108                 ol_cv_func_gethostbyname_r_nargs=6
27109
27110         else
27111                 ol_cv_func_gethostbyname_r_nargs=0
27112         fi
27113
27114 fi
27115 echo "$as_me:$LINENO: result: $ol_cv_func_gethostbyname_r_nargs" >&5
27116 echo "${ECHO_T}$ol_cv_func_gethostbyname_r_nargs" >&6
27117   if test $ol_cv_func_gethostbyname_r_nargs -gt 1 ; then
27118
27119 cat >>confdefs.h <<_ACEOF
27120 #define GETHOSTBYNAME_R_NARGS $ol_cv_func_gethostbyname_r_nargs
27121 _ACEOF
27122
27123   fi
27124
27125 else
27126         ol_cv_func_gethostbyname_r_nargs=0
27127 fi
27128
27129 if test "$ac_cv_func_gethostbyaddr_r" = yes ; then
27130         echo "$as_me:$LINENO: checking number of arguments of gethostbyaddr_r" >&5
27131 echo $ECHO_N "checking number of arguments of gethostbyaddr_r... $ECHO_C" >&6
27132 if test "${ol_cv_func_gethostbyaddr_r_nargs+set}" = set; then
27133   echo $ECHO_N "(cached) $ECHO_C" >&6
27134 else
27135   cat >conftest.$ac_ext <<_ACEOF
27136 /* confdefs.h.  */
27137 _ACEOF
27138 cat confdefs.h >>conftest.$ac_ext
27139 cat >>conftest.$ac_ext <<_ACEOF
27140 /* end confdefs.h.  */
27141 #include <sys/types.h>
27142 #include <sys/socket.h>
27143 #include <netinet/in.h>
27144 #include <netdb.h>
27145 #define BUFSIZE (sizeof(struct hostent)+10)
27146 int
27147 main ()
27148 {
27149 struct hostent hent; char buffer[BUFSIZE];
27150             struct in_addr add;
27151             size_t alen=sizeof(struct in_addr);
27152             int bufsize=BUFSIZE;int h_errno;
27153                 (void)gethostbyaddr_r( (void *)&(add.s_addr),
27154                         alen, AF_INET, &hent, buffer, bufsize, &h_errno);
27155   ;
27156   return 0;
27157 }
27158 _ACEOF
27159 rm -f conftest.$ac_objext
27160 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27161   (eval $ac_compile) 2>conftest.er1
27162   ac_status=$?
27163   grep -v '^ *+' conftest.er1 >conftest.err
27164   rm -f conftest.er1
27165   cat conftest.err >&5
27166   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27167   (exit $ac_status); } &&
27168          { ac_try='test -z "$ac_c_werror_flag"
27169                          || test ! -s conftest.err'
27170   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27171   (eval $ac_try) 2>&5
27172   ac_status=$?
27173   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27174   (exit $ac_status); }; } &&
27175          { ac_try='test -s conftest.$ac_objext'
27176   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27177   (eval $ac_try) 2>&5
27178   ac_status=$?
27179   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27180   (exit $ac_status); }; }; then
27181   ol_cv_func_gethostbyaddr_r_nargs7=yes
27182 else
27183   echo "$as_me: failed program was:" >&5
27184 sed 's/^/| /' conftest.$ac_ext >&5
27185
27186 ol_cv_func_gethostbyaddr_r_nargs7=no
27187 fi
27188 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27189
27190         cat >conftest.$ac_ext <<_ACEOF
27191 /* confdefs.h.  */
27192 _ACEOF
27193 cat confdefs.h >>conftest.$ac_ext
27194 cat >>conftest.$ac_ext <<_ACEOF
27195 /* end confdefs.h.  */
27196 #include <sys/types.h>
27197 #include <sys/socket.h>
27198 #include <netinet/in.h>
27199 #include <netdb.h>
27200 #define BUFSIZE (sizeof(struct hostent)+10)
27201 int
27202 main ()
27203 {
27204 struct hostent hent;
27205                 struct hostent *rhent; char buffer[BUFSIZE];
27206                 struct in_addr add;
27207                 size_t alen=sizeof(struct in_addr);
27208                 int bufsize=BUFSIZE;int h_errno;
27209                 (void)gethostbyaddr_r( (void *)&(add.s_addr),
27210                         alen, AF_INET, &hent, buffer, bufsize,
27211                         &rhent, &h_errno);
27212   ;
27213   return 0;
27214 }
27215 _ACEOF
27216 rm -f conftest.$ac_objext
27217 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27218   (eval $ac_compile) 2>conftest.er1
27219   ac_status=$?
27220   grep -v '^ *+' conftest.er1 >conftest.err
27221   rm -f conftest.er1
27222   cat conftest.err >&5
27223   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27224   (exit $ac_status); } &&
27225          { ac_try='test -z "$ac_c_werror_flag"
27226                          || test ! -s conftest.err'
27227   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27228   (eval $ac_try) 2>&5
27229   ac_status=$?
27230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27231   (exit $ac_status); }; } &&
27232          { ac_try='test -s conftest.$ac_objext'
27233   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27234   (eval $ac_try) 2>&5
27235   ac_status=$?
27236   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27237   (exit $ac_status); }; }; then
27238   ol_cv_func_gethostbyaddr_r_nargs8=yes
27239 else
27240   echo "$as_me: failed program was:" >&5
27241 sed 's/^/| /' conftest.$ac_ext >&5
27242
27243 ol_cv_func_gethostbyaddr_r_nargs8=no
27244 fi
27245 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27246
27247         if test $ol_cv_func_gethostbyaddr_r_nargs7 = yes &&
27248            test $ol_cv_func_gethostbyaddr_r_nargs8 = no ; then
27249
27250                 ol_cv_func_gethostbyaddr_r_nargs=7
27251
27252         elif test $ol_cv_func_gethostbyaddr_r_nargs7 = no &&
27253              test $ol_cv_func_gethostbyaddr_r_nargs8 = yes ; then
27254
27255                 ol_cv_func_gethostbyaddr_r_nargs=8
27256
27257         else
27258                 ol_cv_func_gethostbyaddr_r_nargs=0
27259         fi
27260
27261 fi
27262 echo "$as_me:$LINENO: result: $ol_cv_func_gethostbyaddr_r_nargs" >&5
27263 echo "${ECHO_T}$ol_cv_func_gethostbyaddr_r_nargs" >&6
27264   if test $ol_cv_func_gethostbyaddr_r_nargs -gt 1 ; then
27265
27266 cat >>confdefs.h <<_ACEOF
27267 #define GETHOSTBYADDR_R_NARGS $ol_cv_func_gethostbyaddr_r_nargs
27268 _ACEOF
27269
27270   fi
27271
27272 else
27273         ol_cv_func_gethostbyaddr_r_nargs=0
27274 fi
27275
27276 ol_link_bdb=no
27277
27278 if test $ol_enable_bdb/$ol_enable_hdb != no/no; then
27279         ol_cv_berkeley_db=no
27280
27281 for ac_header in db.h
27282 do
27283 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
27284 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27285   echo "$as_me:$LINENO: checking for $ac_header" >&5
27286 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27287 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27288   echo $ECHO_N "(cached) $ECHO_C" >&6
27289 fi
27290 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27291 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27292 else
27293   # Is the header compilable?
27294 echo "$as_me:$LINENO: checking $ac_header usability" >&5
27295 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
27296 cat >conftest.$ac_ext <<_ACEOF
27297 /* confdefs.h.  */
27298 _ACEOF
27299 cat confdefs.h >>conftest.$ac_ext
27300 cat >>conftest.$ac_ext <<_ACEOF
27301 /* end confdefs.h.  */
27302 $ac_includes_default
27303 #include <$ac_header>
27304 _ACEOF
27305 rm -f conftest.$ac_objext
27306 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27307   (eval $ac_compile) 2>conftest.er1
27308   ac_status=$?
27309   grep -v '^ *+' conftest.er1 >conftest.err
27310   rm -f conftest.er1
27311   cat conftest.err >&5
27312   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27313   (exit $ac_status); } &&
27314          { ac_try='test -z "$ac_c_werror_flag"
27315                          || test ! -s conftest.err'
27316   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27317   (eval $ac_try) 2>&5
27318   ac_status=$?
27319   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27320   (exit $ac_status); }; } &&
27321          { ac_try='test -s conftest.$ac_objext'
27322   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27323   (eval $ac_try) 2>&5
27324   ac_status=$?
27325   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27326   (exit $ac_status); }; }; then
27327   ac_header_compiler=yes
27328 else
27329   echo "$as_me: failed program was:" >&5
27330 sed 's/^/| /' conftest.$ac_ext >&5
27331
27332 ac_header_compiler=no
27333 fi
27334 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
27335 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
27336 echo "${ECHO_T}$ac_header_compiler" >&6
27337
27338 # Is the header present?
27339 echo "$as_me:$LINENO: checking $ac_header presence" >&5
27340 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
27341 cat >conftest.$ac_ext <<_ACEOF
27342 /* confdefs.h.  */
27343 _ACEOF
27344 cat confdefs.h >>conftest.$ac_ext
27345 cat >>conftest.$ac_ext <<_ACEOF
27346 /* end confdefs.h.  */
27347 #include <$ac_header>
27348 _ACEOF
27349 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
27350   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
27351   ac_status=$?
27352   grep -v '^ *+' conftest.er1 >conftest.err
27353   rm -f conftest.er1
27354   cat conftest.err >&5
27355   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27356   (exit $ac_status); } >/dev/null; then
27357   if test -s conftest.err; then
27358     ac_cpp_err=$ac_c_preproc_warn_flag
27359     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
27360   else
27361     ac_cpp_err=
27362   fi
27363 else
27364   ac_cpp_err=yes
27365 fi
27366 if test -z "$ac_cpp_err"; then
27367   ac_header_preproc=yes
27368 else
27369   echo "$as_me: failed program was:" >&5
27370 sed 's/^/| /' conftest.$ac_ext >&5
27371
27372   ac_header_preproc=no
27373 fi
27374 rm -f conftest.err conftest.$ac_ext
27375 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
27376 echo "${ECHO_T}$ac_header_preproc" >&6
27377
27378 # So?  What about this header?
27379 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
27380   yes:no: )
27381     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
27382 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
27383     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
27384 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
27385     ac_header_preproc=yes
27386     ;;
27387   no:yes:* )
27388     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
27389 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
27390     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
27391 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
27392     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
27393 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
27394     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
27395 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
27396     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27397 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27398     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
27399 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
27400     (
27401       cat <<\_ASBOX
27402 ## --------------------------------------------- ##
27403 ## Report this to <http://www.openldap.org/its/> ##
27404 ## --------------------------------------------- ##
27405 _ASBOX
27406     ) |
27407       sed "s/^/$as_me: WARNING:     /" >&2
27408     ;;
27409 esac
27410 echo "$as_me:$LINENO: checking for $ac_header" >&5
27411 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27412 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27413   echo $ECHO_N "(cached) $ECHO_C" >&6
27414 else
27415   eval "$as_ac_Header=\$ac_header_preproc"
27416 fi
27417 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27418 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27419
27420 fi
27421 if test `eval echo '${'$as_ac_Header'}'` = yes; then
27422   cat >>confdefs.h <<_ACEOF
27423 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
27424 _ACEOF
27425
27426 fi
27427
27428 done
27429
27430 if test $ac_cv_header_db_h = yes; then
27431         ol_cv_lib_db=no
27432
27433 echo "$as_me:$LINENO: checking for Berkeley DB major version" >&5
27434 echo $ECHO_N "checking for Berkeley DB major version... $ECHO_C" >&6
27435 if test "${ol_cv_bdb_major+set}" = set; then
27436   echo $ECHO_N "(cached) $ECHO_C" >&6
27437 else
27438
27439         ol_cv_bdb_major=0
27440         if test $ol_cv_bdb_major = 0 ; then
27441                 cat >conftest.$ac_ext <<_ACEOF
27442 /* confdefs.h.  */
27443 _ACEOF
27444 cat confdefs.h >>conftest.$ac_ext
27445 cat >>conftest.$ac_ext <<_ACEOF
27446 /* end confdefs.h.  */
27447
27448 #include <db.h>
27449 #ifndef DB_VERSION_MAJOR
27450 #       define DB_VERSION_MAJOR 1
27451 #endif
27452 #if DB_VERSION_MAJOR == 4
27453 __db_version
27454 #endif
27455
27456 _ACEOF
27457 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27458   $EGREP "__db_version" >/dev/null 2>&1; then
27459   ol_cv_bdb_major=4
27460 else
27461   :
27462 fi
27463 rm -f conftest*
27464
27465         fi
27466         if test $ol_cv_bdb_major = 0 ; then
27467                 cat >conftest.$ac_ext <<_ACEOF
27468 /* confdefs.h.  */
27469 _ACEOF
27470 cat confdefs.h >>conftest.$ac_ext
27471 cat >>conftest.$ac_ext <<_ACEOF
27472 /* end confdefs.h.  */
27473
27474 #include <db.h>
27475 #ifndef DB_VERSION_MAJOR
27476 #       define DB_VERSION_MAJOR 1
27477 #endif
27478 #if DB_VERSION_MAJOR == 3
27479 __db_version
27480 #endif
27481
27482 _ACEOF
27483 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27484   $EGREP "__db_version" >/dev/null 2>&1; then
27485   ol_cv_bdb_major=3
27486 else
27487   :
27488 fi
27489 rm -f conftest*
27490
27491         fi
27492         if test $ol_cv_bdb_major = 0 ; then
27493                 cat >conftest.$ac_ext <<_ACEOF
27494 /* confdefs.h.  */
27495 _ACEOF
27496 cat confdefs.h >>conftest.$ac_ext
27497 cat >>conftest.$ac_ext <<_ACEOF
27498 /* end confdefs.h.  */
27499
27500 #include <db.h>
27501 #ifndef DB_VERSION_MAJOR
27502 #       define DB_VERSION_MAJOR 1
27503 #endif
27504 #if DB_VERSION_MAJOR == 2
27505 __db_version
27506 #endif
27507
27508 _ACEOF
27509 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27510   $EGREP "__db_version" >/dev/null 2>&1; then
27511   ol_cv_bdb_major=2
27512 else
27513   :
27514 fi
27515 rm -f conftest*
27516
27517         fi
27518         if test $ol_cv_bdb_major = 0 ; then
27519                 cat >conftest.$ac_ext <<_ACEOF
27520 /* confdefs.h.  */
27521 _ACEOF
27522 cat confdefs.h >>conftest.$ac_ext
27523 cat >>conftest.$ac_ext <<_ACEOF
27524 /* end confdefs.h.  */
27525
27526 #include <db.h>
27527 #ifndef DB_VERSION_MAJOR
27528 #       define DB_VERSION_MAJOR 1
27529 #endif
27530 #if DB_VERSION_MAJOR == 1
27531 __db_version
27532 #endif
27533
27534 _ACEOF
27535 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27536   $EGREP "__db_version" >/dev/null 2>&1; then
27537   ol_cv_bdb_major=1
27538 else
27539   :
27540 fi
27541 rm -f conftest*
27542
27543         fi
27544
27545         if test $ol_cv_bdb_major = 0 ; then
27546                 { { echo "$as_me:$LINENO: error: Unknown Berkeley DB major version" >&5
27547 echo "$as_me: error: Unknown Berkeley DB major version" >&2;}
27548    { (exit 1); exit 1; }; }
27549         fi
27550
27551 fi
27552 echo "$as_me:$LINENO: result: $ol_cv_bdb_major" >&5
27553 echo "${ECHO_T}$ol_cv_bdb_major" >&6
27554
27555 echo "$as_me:$LINENO: checking for Berkeley DB minor version" >&5
27556 echo $ECHO_N "checking for Berkeley DB minor version... $ECHO_C" >&6
27557 if test "${ol_cv_bdb_minor+set}" = set; then
27558   echo $ECHO_N "(cached) $ECHO_C" >&6
27559 else
27560
27561         ol_cv_bdb_minor=0
27562         if test $ol_cv_bdb_minor = 0 ; then
27563                 cat >conftest.$ac_ext <<_ACEOF
27564 /* confdefs.h.  */
27565 _ACEOF
27566 cat confdefs.h >>conftest.$ac_ext
27567 cat >>conftest.$ac_ext <<_ACEOF
27568 /* end confdefs.h.  */
27569
27570 #include <db.h>
27571 #ifndef DB_VERSION_MINOR
27572 #       define DB_VERSION_MINOR 0
27573 #endif
27574 #if DB_VERSION_MINOR == 9
27575 __db_version
27576 #endif
27577
27578 _ACEOF
27579 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27580   $EGREP "__db_version" >/dev/null 2>&1; then
27581   ol_cv_bdb_minor=9
27582 else
27583   :
27584 fi
27585 rm -f conftest*
27586
27587         fi
27588         if test $ol_cv_bdb_minor = 0 ; then
27589                 cat >conftest.$ac_ext <<_ACEOF
27590 /* confdefs.h.  */
27591 _ACEOF
27592 cat confdefs.h >>conftest.$ac_ext
27593 cat >>conftest.$ac_ext <<_ACEOF
27594 /* end confdefs.h.  */
27595
27596 #include <db.h>
27597 #ifndef DB_VERSION_MINOR
27598 #       define DB_VERSION_MINOR 0
27599 #endif
27600 #if DB_VERSION_MINOR == 8
27601 __db_version
27602 #endif
27603
27604 _ACEOF
27605 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27606   $EGREP "__db_version" >/dev/null 2>&1; then
27607   ol_cv_bdb_minor=8
27608 else
27609   :
27610 fi
27611 rm -f conftest*
27612
27613         fi
27614         if test $ol_cv_bdb_minor = 0 ; then
27615                 cat >conftest.$ac_ext <<_ACEOF
27616 /* confdefs.h.  */
27617 _ACEOF
27618 cat confdefs.h >>conftest.$ac_ext
27619 cat >>conftest.$ac_ext <<_ACEOF
27620 /* end confdefs.h.  */
27621
27622 #include <db.h>
27623 #ifndef DB_VERSION_MINOR
27624 #       define DB_VERSION_MINOR 0
27625 #endif
27626 #if DB_VERSION_MINOR == 7
27627 __db_version
27628 #endif
27629
27630 _ACEOF
27631 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27632   $EGREP "__db_version" >/dev/null 2>&1; then
27633   ol_cv_bdb_minor=7
27634 else
27635   :
27636 fi
27637 rm -f conftest*
27638
27639         fi
27640         if test $ol_cv_bdb_minor = 0 ; then
27641                 cat >conftest.$ac_ext <<_ACEOF
27642 /* confdefs.h.  */
27643 _ACEOF
27644 cat confdefs.h >>conftest.$ac_ext
27645 cat >>conftest.$ac_ext <<_ACEOF
27646 /* end confdefs.h.  */
27647
27648 #include <db.h>
27649 #ifndef DB_VERSION_MINOR
27650 #       define DB_VERSION_MINOR 0
27651 #endif
27652 #if DB_VERSION_MINOR == 6
27653 __db_version
27654 #endif
27655
27656 _ACEOF
27657 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27658   $EGREP "__db_version" >/dev/null 2>&1; then
27659   ol_cv_bdb_minor=6
27660 else
27661   :
27662 fi
27663 rm -f conftest*
27664
27665         fi
27666         if test $ol_cv_bdb_minor = 0 ; then
27667                 cat >conftest.$ac_ext <<_ACEOF
27668 /* confdefs.h.  */
27669 _ACEOF
27670 cat confdefs.h >>conftest.$ac_ext
27671 cat >>conftest.$ac_ext <<_ACEOF
27672 /* end confdefs.h.  */
27673
27674 #include <db.h>
27675 #ifndef DB_VERSION_MINOR
27676 #       define DB_VERSION_MINOR 0
27677 #endif
27678 #if DB_VERSION_MINOR == 5
27679 __db_version
27680 #endif
27681
27682 _ACEOF
27683 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27684   $EGREP "__db_version" >/dev/null 2>&1; then
27685   ol_cv_bdb_minor=5
27686 else
27687   :
27688 fi
27689 rm -f conftest*
27690
27691         fi
27692         if test $ol_cv_bdb_minor = 0 ; then
27693                 cat >conftest.$ac_ext <<_ACEOF
27694 /* confdefs.h.  */
27695 _ACEOF
27696 cat confdefs.h >>conftest.$ac_ext
27697 cat >>conftest.$ac_ext <<_ACEOF
27698 /* end confdefs.h.  */
27699
27700 #include <db.h>
27701 #ifndef DB_VERSION_MINOR
27702 #       define DB_VERSION_MINOR 0
27703 #endif
27704 #if DB_VERSION_MINOR == 4
27705 __db_version
27706 #endif
27707
27708 _ACEOF
27709 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27710   $EGREP "__db_version" >/dev/null 2>&1; then
27711   ol_cv_bdb_minor=4
27712 else
27713   :
27714 fi
27715 rm -f conftest*
27716
27717         fi
27718         if test $ol_cv_bdb_minor = 0 ; then
27719                 cat >conftest.$ac_ext <<_ACEOF
27720 /* confdefs.h.  */
27721 _ACEOF
27722 cat confdefs.h >>conftest.$ac_ext
27723 cat >>conftest.$ac_ext <<_ACEOF
27724 /* end confdefs.h.  */
27725
27726 #include <db.h>
27727 #ifndef DB_VERSION_MINOR
27728 #       define DB_VERSION_MINOR 0
27729 #endif
27730 #if DB_VERSION_MINOR == 3
27731 __db_version
27732 #endif
27733
27734 _ACEOF
27735 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27736   $EGREP "__db_version" >/dev/null 2>&1; then
27737   ol_cv_bdb_minor=3
27738 else
27739   :
27740 fi
27741 rm -f conftest*
27742
27743         fi
27744         if test $ol_cv_bdb_minor = 0 ; then
27745                 cat >conftest.$ac_ext <<_ACEOF
27746 /* confdefs.h.  */
27747 _ACEOF
27748 cat confdefs.h >>conftest.$ac_ext
27749 cat >>conftest.$ac_ext <<_ACEOF
27750 /* end confdefs.h.  */
27751
27752 #include <db.h>
27753 #ifndef DB_VERSION_MINOR
27754 #       define DB_VERSION_MINOR 0
27755 #endif
27756 #if DB_VERSION_MINOR == 2
27757 __db_version
27758 #endif
27759
27760 _ACEOF
27761 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27762   $EGREP "__db_version" >/dev/null 2>&1; then
27763   ol_cv_bdb_minor=2
27764 else
27765   :
27766 fi
27767 rm -f conftest*
27768
27769         fi
27770         if test $ol_cv_bdb_minor = 0 ; then
27771                 cat >conftest.$ac_ext <<_ACEOF
27772 /* confdefs.h.  */
27773 _ACEOF
27774 cat confdefs.h >>conftest.$ac_ext
27775 cat >>conftest.$ac_ext <<_ACEOF
27776 /* end confdefs.h.  */
27777
27778 #include <db.h>
27779 #ifndef DB_VERSION_MINOR
27780 #       define DB_VERSION_MINOR 0
27781 #endif
27782 #if DB_VERSION_MINOR == 1
27783 __db_version
27784 #endif
27785
27786 _ACEOF
27787 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27788   $EGREP "__db_version" >/dev/null 2>&1; then
27789   ol_cv_bdb_minor=1
27790 else
27791   :
27792 fi
27793 rm -f conftest*
27794
27795         fi
27796
27797 fi
27798 echo "$as_me:$LINENO: result: $ol_cv_bdb_minor" >&5
27799 echo "${ECHO_T}$ol_cv_bdb_minor" >&6
27800
27801 if test $ol_cv_bdb_major = 4 ; then
27802         if test $ol_cv_lib_db = no ; then
27803         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.$ol_cv_bdb_minor)" >&5
27804 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.$ol_cv_bdb_minor)... $ECHO_C" >&6
27805 if test "${ol_cv_db_db_4_dot_m+set}" = set; then
27806   echo $ECHO_N "(cached) $ECHO_C" >&6
27807 else
27808
27809         ol_DB_LIB=-ldb-4.$ol_cv_bdb_minor
27810         ol_LIBS=$LIBS
27811         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
27812
27813         cat >conftest.$ac_ext <<_ACEOF
27814 /* confdefs.h.  */
27815 _ACEOF
27816 cat confdefs.h >>conftest.$ac_ext
27817 cat >>conftest.$ac_ext <<_ACEOF
27818 /* end confdefs.h.  */
27819
27820 #ifdef HAVE_DB_185_H
27821 # include <db_185.h>
27822 #else
27823 # include <db.h>
27824 #endif
27825
27826 #ifndef DB_VERSION_MAJOR
27827 # define DB_VERSION_MAJOR 1
27828 #endif
27829
27830 #ifndef NULL
27831 #define NULL ((void*)0)
27832 #endif
27833
27834 int
27835 main ()
27836 {
27837
27838 #if DB_VERSION_MAJOR > 1
27839         {
27840                 char *version;
27841                 int major, minor, patch;
27842
27843                 version = db_version( &major, &minor, &patch );
27844
27845                 if( major != DB_VERSION_MAJOR ||
27846                         minor < DB_VERSION_MINOR )
27847                 {
27848                         printf("Berkeley DB version mismatch\n"
27849                                 "\theader: %s\n\tlibrary: %s\n",
27850                                 DB_VERSION_STRING, version);
27851                         return 1;
27852                 }
27853         }
27854 #endif
27855
27856 #if DB_VERSION_MAJOR > 2
27857         db_env_create( NULL, 0 );
27858 #elif DB_VERSION_MAJOR > 1
27859         db_appexit( NULL );
27860 #else
27861         (void) dbopen( NULL, 0, 0, 0, NULL);
27862 #endif
27863
27864   ;
27865   return 0;
27866 }
27867 _ACEOF
27868 rm -f conftest.$ac_objext conftest$ac_exeext
27869 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27870   (eval $ac_link) 2>conftest.er1
27871   ac_status=$?
27872   grep -v '^ *+' conftest.er1 >conftest.err
27873   rm -f conftest.er1
27874   cat conftest.err >&5
27875   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27876   (exit $ac_status); } &&
27877          { ac_try='test -z "$ac_c_werror_flag"
27878                          || test ! -s conftest.err'
27879   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27880   (eval $ac_try) 2>&5
27881   ac_status=$?
27882   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27883   (exit $ac_status); }; } &&
27884          { ac_try='test -s conftest$ac_exeext'
27885   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27886   (eval $ac_try) 2>&5
27887   ac_status=$?
27888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27889   (exit $ac_status); }; }; then
27890   ol_cv_db_db_4_dot_m=yes
27891 else
27892   echo "$as_me: failed program was:" >&5
27893 sed 's/^/| /' conftest.$ac_ext >&5
27894
27895 ol_cv_db_db_4_dot_m=no
27896 fi
27897 rm -f conftest.err conftest.$ac_objext \
27898       conftest$ac_exeext conftest.$ac_ext
27899
27900         LIBS="$ol_LIBS"
27901
27902 fi
27903 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_m" >&5
27904 echo "${ECHO_T}$ol_cv_db_db_4_dot_m" >&6
27905
27906         if test $ol_cv_db_db_4_dot_m = yes ; then
27907                 ol_cv_lib_db=-ldb-4.$ol_cv_bdb_minor
27908         fi
27909 fi
27910
27911         if test $ol_cv_lib_db = no ; then
27912         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb4$ol_cv_bdb_minor)" >&5
27913 echo $ECHO_N "checking for Berkeley DB link (-ldb4$ol_cv_bdb_minor)... $ECHO_C" >&6
27914 if test "${ol_cv_db_db4m+set}" = set; then
27915   echo $ECHO_N "(cached) $ECHO_C" >&6
27916 else
27917
27918         ol_DB_LIB=-ldb4$ol_cv_bdb_minor
27919         ol_LIBS=$LIBS
27920         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
27921
27922         cat >conftest.$ac_ext <<_ACEOF
27923 /* confdefs.h.  */
27924 _ACEOF
27925 cat confdefs.h >>conftest.$ac_ext
27926 cat >>conftest.$ac_ext <<_ACEOF
27927 /* end confdefs.h.  */
27928
27929 #ifdef HAVE_DB_185_H
27930 # include <db_185.h>
27931 #else
27932 # include <db.h>
27933 #endif
27934
27935 #ifndef DB_VERSION_MAJOR
27936 # define DB_VERSION_MAJOR 1
27937 #endif
27938
27939 #ifndef NULL
27940 #define NULL ((void*)0)
27941 #endif
27942
27943 int
27944 main ()
27945 {
27946
27947 #if DB_VERSION_MAJOR > 1
27948         {
27949                 char *version;
27950                 int major, minor, patch;
27951
27952                 version = db_version( &major, &minor, &patch );
27953
27954                 if( major != DB_VERSION_MAJOR ||
27955                         minor < DB_VERSION_MINOR )
27956                 {
27957                         printf("Berkeley DB version mismatch\n"
27958                                 "\theader: %s\n\tlibrary: %s\n",
27959                                 DB_VERSION_STRING, version);
27960                         return 1;
27961                 }
27962         }
27963 #endif
27964
27965 #if DB_VERSION_MAJOR > 2
27966         db_env_create( NULL, 0 );
27967 #elif DB_VERSION_MAJOR > 1
27968         db_appexit( NULL );
27969 #else
27970         (void) dbopen( NULL, 0, 0, 0, NULL);
27971 #endif
27972
27973   ;
27974   return 0;
27975 }
27976 _ACEOF
27977 rm -f conftest.$ac_objext conftest$ac_exeext
27978 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27979   (eval $ac_link) 2>conftest.er1
27980   ac_status=$?
27981   grep -v '^ *+' conftest.er1 >conftest.err
27982   rm -f conftest.er1
27983   cat conftest.err >&5
27984   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27985   (exit $ac_status); } &&
27986          { ac_try='test -z "$ac_c_werror_flag"
27987                          || test ! -s conftest.err'
27988   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27989   (eval $ac_try) 2>&5
27990   ac_status=$?
27991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27992   (exit $ac_status); }; } &&
27993          { ac_try='test -s conftest$ac_exeext'
27994   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27995   (eval $ac_try) 2>&5
27996   ac_status=$?
27997   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27998   (exit $ac_status); }; }; then
27999   ol_cv_db_db4m=yes
28000 else
28001   echo "$as_me: failed program was:" >&5
28002 sed 's/^/| /' conftest.$ac_ext >&5
28003
28004 ol_cv_db_db4m=no
28005 fi
28006 rm -f conftest.err conftest.$ac_objext \
28007       conftest$ac_exeext conftest.$ac_ext
28008
28009         LIBS="$ol_LIBS"
28010
28011 fi
28012 echo "$as_me:$LINENO: result: $ol_cv_db_db4m" >&5
28013 echo "${ECHO_T}$ol_cv_db_db4m" >&6
28014
28015         if test $ol_cv_db_db4m = yes ; then
28016                 ol_cv_lib_db=-ldb4$ol_cv_bdb_minor
28017         fi
28018 fi
28019
28020         if test $ol_cv_lib_db = no ; then
28021         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4$ol_cv_bdb_minor)" >&5
28022 echo $ECHO_N "checking for Berkeley DB link (-ldb-4$ol_cv_bdb_minor)... $ECHO_C" >&6
28023 if test "${ol_cv_db_db_4m+set}" = set; then
28024   echo $ECHO_N "(cached) $ECHO_C" >&6
28025 else
28026
28027         ol_DB_LIB=-ldb-4$ol_cv_bdb_minor
28028         ol_LIBS=$LIBS
28029         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28030
28031         cat >conftest.$ac_ext <<_ACEOF
28032 /* confdefs.h.  */
28033 _ACEOF
28034 cat confdefs.h >>conftest.$ac_ext
28035 cat >>conftest.$ac_ext <<_ACEOF
28036 /* end confdefs.h.  */
28037
28038 #ifdef HAVE_DB_185_H
28039 # include <db_185.h>
28040 #else
28041 # include <db.h>
28042 #endif
28043
28044 #ifndef DB_VERSION_MAJOR
28045 # define DB_VERSION_MAJOR 1
28046 #endif
28047
28048 #ifndef NULL
28049 #define NULL ((void*)0)
28050 #endif
28051
28052 int
28053 main ()
28054 {
28055
28056 #if DB_VERSION_MAJOR > 1
28057         {
28058                 char *version;
28059                 int major, minor, patch;
28060
28061                 version = db_version( &major, &minor, &patch );
28062
28063                 if( major != DB_VERSION_MAJOR ||
28064                         minor < DB_VERSION_MINOR )
28065                 {
28066                         printf("Berkeley DB version mismatch\n"
28067                                 "\theader: %s\n\tlibrary: %s\n",
28068                                 DB_VERSION_STRING, version);
28069                         return 1;
28070                 }
28071         }
28072 #endif
28073
28074 #if DB_VERSION_MAJOR > 2
28075         db_env_create( NULL, 0 );
28076 #elif DB_VERSION_MAJOR > 1
28077         db_appexit( NULL );
28078 #else
28079         (void) dbopen( NULL, 0, 0, 0, NULL);
28080 #endif
28081
28082   ;
28083   return 0;
28084 }
28085 _ACEOF
28086 rm -f conftest.$ac_objext conftest$ac_exeext
28087 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28088   (eval $ac_link) 2>conftest.er1
28089   ac_status=$?
28090   grep -v '^ *+' conftest.er1 >conftest.err
28091   rm -f conftest.er1
28092   cat conftest.err >&5
28093   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28094   (exit $ac_status); } &&
28095          { ac_try='test -z "$ac_c_werror_flag"
28096                          || test ! -s conftest.err'
28097   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28098   (eval $ac_try) 2>&5
28099   ac_status=$?
28100   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28101   (exit $ac_status); }; } &&
28102          { ac_try='test -s conftest$ac_exeext'
28103   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28104   (eval $ac_try) 2>&5
28105   ac_status=$?
28106   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28107   (exit $ac_status); }; }; then
28108   ol_cv_db_db_4m=yes
28109 else
28110   echo "$as_me: failed program was:" >&5
28111 sed 's/^/| /' conftest.$ac_ext >&5
28112
28113 ol_cv_db_db_4m=no
28114 fi
28115 rm -f conftest.err conftest.$ac_objext \
28116       conftest$ac_exeext conftest.$ac_ext
28117
28118         LIBS="$ol_LIBS"
28119
28120 fi
28121 echo "$as_me:$LINENO: result: $ol_cv_db_db_4m" >&5
28122 echo "${ECHO_T}$ol_cv_db_db_4m" >&6
28123
28124         if test $ol_cv_db_db_4m = yes ; then
28125                 ol_cv_lib_db=-ldb-4$ol_cv_bdb_minor
28126         fi
28127 fi
28128
28129         if test $ol_cv_lib_db = no ; then
28130         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-$ol_cv_bdb_minor)" >&5
28131 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-$ol_cv_bdb_minor)... $ECHO_C" >&6
28132 if test "${ol_cv_db_db_4_m+set}" = set; then
28133   echo $ECHO_N "(cached) $ECHO_C" >&6
28134 else
28135
28136         ol_DB_LIB=-ldb-4-$ol_cv_bdb_minor
28137         ol_LIBS=$LIBS
28138         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28139
28140         cat >conftest.$ac_ext <<_ACEOF
28141 /* confdefs.h.  */
28142 _ACEOF
28143 cat confdefs.h >>conftest.$ac_ext
28144 cat >>conftest.$ac_ext <<_ACEOF
28145 /* end confdefs.h.  */
28146
28147 #ifdef HAVE_DB_185_H
28148 # include <db_185.h>
28149 #else
28150 # include <db.h>
28151 #endif
28152
28153 #ifndef DB_VERSION_MAJOR
28154 # define DB_VERSION_MAJOR 1
28155 #endif
28156
28157 #ifndef NULL
28158 #define NULL ((void*)0)
28159 #endif
28160
28161 int
28162 main ()
28163 {
28164
28165 #if DB_VERSION_MAJOR > 1
28166         {
28167                 char *version;
28168                 int major, minor, patch;
28169
28170                 version = db_version( &major, &minor, &patch );
28171
28172                 if( major != DB_VERSION_MAJOR ||
28173                         minor < DB_VERSION_MINOR )
28174                 {
28175                         printf("Berkeley DB version mismatch\n"
28176                                 "\theader: %s\n\tlibrary: %s\n",
28177                                 DB_VERSION_STRING, version);
28178                         return 1;
28179                 }
28180         }
28181 #endif
28182
28183 #if DB_VERSION_MAJOR > 2
28184         db_env_create( NULL, 0 );
28185 #elif DB_VERSION_MAJOR > 1
28186         db_appexit( NULL );
28187 #else
28188         (void) dbopen( NULL, 0, 0, 0, NULL);
28189 #endif
28190
28191   ;
28192   return 0;
28193 }
28194 _ACEOF
28195 rm -f conftest.$ac_objext conftest$ac_exeext
28196 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28197   (eval $ac_link) 2>conftest.er1
28198   ac_status=$?
28199   grep -v '^ *+' conftest.er1 >conftest.err
28200   rm -f conftest.er1
28201   cat conftest.err >&5
28202   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28203   (exit $ac_status); } &&
28204          { ac_try='test -z "$ac_c_werror_flag"
28205                          || test ! -s conftest.err'
28206   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28207   (eval $ac_try) 2>&5
28208   ac_status=$?
28209   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28210   (exit $ac_status); }; } &&
28211          { ac_try='test -s conftest$ac_exeext'
28212   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28213   (eval $ac_try) 2>&5
28214   ac_status=$?
28215   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28216   (exit $ac_status); }; }; then
28217   ol_cv_db_db_4_m=yes
28218 else
28219   echo "$as_me: failed program was:" >&5
28220 sed 's/^/| /' conftest.$ac_ext >&5
28221
28222 ol_cv_db_db_4_m=no
28223 fi
28224 rm -f conftest.err conftest.$ac_objext \
28225       conftest$ac_exeext conftest.$ac_ext
28226
28227         LIBS="$ol_LIBS"
28228
28229 fi
28230 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_m" >&5
28231 echo "${ECHO_T}$ol_cv_db_db_4_m" >&6
28232
28233         if test $ol_cv_db_db_4_m = yes ; then
28234                 ol_cv_lib_db=-ldb-4-$ol_cv_bdb_minor
28235         fi
28236 fi
28237
28238         if test $ol_cv_lib_db = no ; then
28239         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4)" >&5
28240 echo $ECHO_N "checking for Berkeley DB link (-ldb-4)... $ECHO_C" >&6
28241 if test "${ol_cv_db_db_4+set}" = set; then
28242   echo $ECHO_N "(cached) $ECHO_C" >&6
28243 else
28244
28245         ol_DB_LIB=-ldb-4
28246         ol_LIBS=$LIBS
28247         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28248
28249         cat >conftest.$ac_ext <<_ACEOF
28250 /* confdefs.h.  */
28251 _ACEOF
28252 cat confdefs.h >>conftest.$ac_ext
28253 cat >>conftest.$ac_ext <<_ACEOF
28254 /* end confdefs.h.  */
28255
28256 #ifdef HAVE_DB_185_H
28257 # include <db_185.h>
28258 #else
28259 # include <db.h>
28260 #endif
28261
28262 #ifndef DB_VERSION_MAJOR
28263 # define DB_VERSION_MAJOR 1
28264 #endif
28265
28266 #ifndef NULL
28267 #define NULL ((void*)0)
28268 #endif
28269
28270 int
28271 main ()
28272 {
28273
28274 #if DB_VERSION_MAJOR > 1
28275         {
28276                 char *version;
28277                 int major, minor, patch;
28278
28279                 version = db_version( &major, &minor, &patch );
28280
28281                 if( major != DB_VERSION_MAJOR ||
28282                         minor < DB_VERSION_MINOR )
28283                 {
28284                         printf("Berkeley DB version mismatch\n"
28285                                 "\theader: %s\n\tlibrary: %s\n",
28286                                 DB_VERSION_STRING, version);
28287                         return 1;
28288                 }
28289         }
28290 #endif
28291
28292 #if DB_VERSION_MAJOR > 2
28293         db_env_create( NULL, 0 );
28294 #elif DB_VERSION_MAJOR > 1
28295         db_appexit( NULL );
28296 #else
28297         (void) dbopen( NULL, 0, 0, 0, NULL);
28298 #endif
28299
28300   ;
28301   return 0;
28302 }
28303 _ACEOF
28304 rm -f conftest.$ac_objext conftest$ac_exeext
28305 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28306   (eval $ac_link) 2>conftest.er1
28307   ac_status=$?
28308   grep -v '^ *+' conftest.er1 >conftest.err
28309   rm -f conftest.er1
28310   cat conftest.err >&5
28311   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28312   (exit $ac_status); } &&
28313          { ac_try='test -z "$ac_c_werror_flag"
28314                          || test ! -s conftest.err'
28315   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28316   (eval $ac_try) 2>&5
28317   ac_status=$?
28318   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28319   (exit $ac_status); }; } &&
28320          { ac_try='test -s conftest$ac_exeext'
28321   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28322   (eval $ac_try) 2>&5
28323   ac_status=$?
28324   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28325   (exit $ac_status); }; }; then
28326   ol_cv_db_db_4=yes
28327 else
28328   echo "$as_me: failed program was:" >&5
28329 sed 's/^/| /' conftest.$ac_ext >&5
28330
28331 ol_cv_db_db_4=no
28332 fi
28333 rm -f conftest.err conftest.$ac_objext \
28334       conftest$ac_exeext conftest.$ac_ext
28335
28336         LIBS="$ol_LIBS"
28337
28338 fi
28339 echo "$as_me:$LINENO: result: $ol_cv_db_db_4" >&5
28340 echo "${ECHO_T}$ol_cv_db_db_4" >&6
28341
28342         if test $ol_cv_db_db_4 = yes ; then
28343                 ol_cv_lib_db=-ldb-4
28344         fi
28345 fi
28346
28347         if test $ol_cv_lib_db = no ; then
28348         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb4)" >&5
28349 echo $ECHO_N "checking for Berkeley DB link (-ldb4)... $ECHO_C" >&6
28350 if test "${ol_cv_db_db4+set}" = set; then
28351   echo $ECHO_N "(cached) $ECHO_C" >&6
28352 else
28353
28354         ol_DB_LIB=-ldb4
28355         ol_LIBS=$LIBS
28356         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28357
28358         cat >conftest.$ac_ext <<_ACEOF
28359 /* confdefs.h.  */
28360 _ACEOF
28361 cat confdefs.h >>conftest.$ac_ext
28362 cat >>conftest.$ac_ext <<_ACEOF
28363 /* end confdefs.h.  */
28364
28365 #ifdef HAVE_DB_185_H
28366 # include <db_185.h>
28367 #else
28368 # include <db.h>
28369 #endif
28370
28371 #ifndef DB_VERSION_MAJOR
28372 # define DB_VERSION_MAJOR 1
28373 #endif
28374
28375 #ifndef NULL
28376 #define NULL ((void*)0)
28377 #endif
28378
28379 int
28380 main ()
28381 {
28382
28383 #if DB_VERSION_MAJOR > 1
28384         {
28385                 char *version;
28386                 int major, minor, patch;
28387
28388                 version = db_version( &major, &minor, &patch );
28389
28390                 if( major != DB_VERSION_MAJOR ||
28391                         minor < DB_VERSION_MINOR )
28392                 {
28393                         printf("Berkeley DB version mismatch\n"
28394                                 "\theader: %s\n\tlibrary: %s\n",
28395                                 DB_VERSION_STRING, version);
28396                         return 1;
28397                 }
28398         }
28399 #endif
28400
28401 #if DB_VERSION_MAJOR > 2
28402         db_env_create( NULL, 0 );
28403 #elif DB_VERSION_MAJOR > 1
28404         db_appexit( NULL );
28405 #else
28406         (void) dbopen( NULL, 0, 0, 0, NULL);
28407 #endif
28408
28409   ;
28410   return 0;
28411 }
28412 _ACEOF
28413 rm -f conftest.$ac_objext conftest$ac_exeext
28414 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28415   (eval $ac_link) 2>conftest.er1
28416   ac_status=$?
28417   grep -v '^ *+' conftest.er1 >conftest.err
28418   rm -f conftest.er1
28419   cat conftest.err >&5
28420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28421   (exit $ac_status); } &&
28422          { ac_try='test -z "$ac_c_werror_flag"
28423                          || test ! -s conftest.err'
28424   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28425   (eval $ac_try) 2>&5
28426   ac_status=$?
28427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28428   (exit $ac_status); }; } &&
28429          { ac_try='test -s conftest$ac_exeext'
28430   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28431   (eval $ac_try) 2>&5
28432   ac_status=$?
28433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28434   (exit $ac_status); }; }; then
28435   ol_cv_db_db4=yes
28436 else
28437   echo "$as_me: failed program was:" >&5
28438 sed 's/^/| /' conftest.$ac_ext >&5
28439
28440 ol_cv_db_db4=no
28441 fi
28442 rm -f conftest.err conftest.$ac_objext \
28443       conftest$ac_exeext conftest.$ac_ext
28444
28445         LIBS="$ol_LIBS"
28446
28447 fi
28448 echo "$as_me:$LINENO: result: $ol_cv_db_db4" >&5
28449 echo "${ECHO_T}$ol_cv_db_db4" >&6
28450
28451         if test $ol_cv_db_db4 = yes ; then
28452                 ol_cv_lib_db=-ldb4
28453         fi
28454 fi
28455
28456         if test $ol_cv_lib_db = no ; then
28457         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb)" >&5
28458 echo $ECHO_N "checking for Berkeley DB link (-ldb)... $ECHO_C" >&6
28459 if test "${ol_cv_db_db+set}" = set; then
28460   echo $ECHO_N "(cached) $ECHO_C" >&6
28461 else
28462
28463         ol_DB_LIB=-ldb
28464         ol_LIBS=$LIBS
28465         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28466
28467         cat >conftest.$ac_ext <<_ACEOF
28468 /* confdefs.h.  */
28469 _ACEOF
28470 cat confdefs.h >>conftest.$ac_ext
28471 cat >>conftest.$ac_ext <<_ACEOF
28472 /* end confdefs.h.  */
28473
28474 #ifdef HAVE_DB_185_H
28475 # include <db_185.h>
28476 #else
28477 # include <db.h>
28478 #endif
28479
28480 #ifndef DB_VERSION_MAJOR
28481 # define DB_VERSION_MAJOR 1
28482 #endif
28483
28484 #ifndef NULL
28485 #define NULL ((void*)0)
28486 #endif
28487
28488 int
28489 main ()
28490 {
28491
28492 #if DB_VERSION_MAJOR > 1
28493         {
28494                 char *version;
28495                 int major, minor, patch;
28496
28497                 version = db_version( &major, &minor, &patch );
28498
28499                 if( major != DB_VERSION_MAJOR ||
28500                         minor < DB_VERSION_MINOR )
28501                 {
28502                         printf("Berkeley DB version mismatch\n"
28503                                 "\theader: %s\n\tlibrary: %s\n",
28504                                 DB_VERSION_STRING, version);
28505                         return 1;
28506                 }
28507         }
28508 #endif
28509
28510 #if DB_VERSION_MAJOR > 2
28511         db_env_create( NULL, 0 );
28512 #elif DB_VERSION_MAJOR > 1
28513         db_appexit( NULL );
28514 #else
28515         (void) dbopen( NULL, 0, 0, 0, NULL);
28516 #endif
28517
28518   ;
28519   return 0;
28520 }
28521 _ACEOF
28522 rm -f conftest.$ac_objext conftest$ac_exeext
28523 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28524   (eval $ac_link) 2>conftest.er1
28525   ac_status=$?
28526   grep -v '^ *+' conftest.er1 >conftest.err
28527   rm -f conftest.er1
28528   cat conftest.err >&5
28529   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28530   (exit $ac_status); } &&
28531          { ac_try='test -z "$ac_c_werror_flag"
28532                          || test ! -s conftest.err'
28533   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28534   (eval $ac_try) 2>&5
28535   ac_status=$?
28536   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28537   (exit $ac_status); }; } &&
28538          { ac_try='test -s conftest$ac_exeext'
28539   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28540   (eval $ac_try) 2>&5
28541   ac_status=$?
28542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28543   (exit $ac_status); }; }; then
28544   ol_cv_db_db=yes
28545 else
28546   echo "$as_me: failed program was:" >&5
28547 sed 's/^/| /' conftest.$ac_ext >&5
28548
28549 ol_cv_db_db=no
28550 fi
28551 rm -f conftest.err conftest.$ac_objext \
28552       conftest$ac_exeext conftest.$ac_ext
28553
28554         LIBS="$ol_LIBS"
28555
28556 fi
28557 echo "$as_me:$LINENO: result: $ol_cv_db_db" >&5
28558 echo "${ECHO_T}$ol_cv_db_db" >&6
28559
28560         if test $ol_cv_db_db = yes ; then
28561                 ol_cv_lib_db=-ldb
28562         fi
28563 fi
28564
28565
28566 elif test $ol_cv_bdb_major = 3 ; then
28567         if test $ol_cv_lib_db = no ; then
28568         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb3)" >&5
28569 echo $ECHO_N "checking for Berkeley DB link (-ldb3)... $ECHO_C" >&6
28570 if test "${ol_cv_db_db3+set}" = set; then
28571   echo $ECHO_N "(cached) $ECHO_C" >&6
28572 else
28573
28574         ol_DB_LIB=-ldb3
28575         ol_LIBS=$LIBS
28576         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28577
28578         cat >conftest.$ac_ext <<_ACEOF
28579 /* confdefs.h.  */
28580 _ACEOF
28581 cat confdefs.h >>conftest.$ac_ext
28582 cat >>conftest.$ac_ext <<_ACEOF
28583 /* end confdefs.h.  */
28584
28585 #ifdef HAVE_DB_185_H
28586 # include <db_185.h>
28587 #else
28588 # include <db.h>
28589 #endif
28590
28591 #ifndef DB_VERSION_MAJOR
28592 # define DB_VERSION_MAJOR 1
28593 #endif
28594
28595 #ifndef NULL
28596 #define NULL ((void*)0)
28597 #endif
28598
28599 int
28600 main ()
28601 {
28602
28603 #if DB_VERSION_MAJOR > 1
28604         {
28605                 char *version;
28606                 int major, minor, patch;
28607
28608                 version = db_version( &major, &minor, &patch );
28609
28610                 if( major != DB_VERSION_MAJOR ||
28611                         minor < DB_VERSION_MINOR )
28612                 {
28613                         printf("Berkeley DB version mismatch\n"
28614                                 "\theader: %s\n\tlibrary: %s\n",
28615                                 DB_VERSION_STRING, version);
28616                         return 1;
28617                 }
28618         }
28619 #endif
28620
28621 #if DB_VERSION_MAJOR > 2
28622         db_env_create( NULL, 0 );
28623 #elif DB_VERSION_MAJOR > 1
28624         db_appexit( NULL );
28625 #else
28626         (void) dbopen( NULL, 0, 0, 0, NULL);
28627 #endif
28628
28629   ;
28630   return 0;
28631 }
28632 _ACEOF
28633 rm -f conftest.$ac_objext conftest$ac_exeext
28634 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28635   (eval $ac_link) 2>conftest.er1
28636   ac_status=$?
28637   grep -v '^ *+' conftest.er1 >conftest.err
28638   rm -f conftest.er1
28639   cat conftest.err >&5
28640   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28641   (exit $ac_status); } &&
28642          { ac_try='test -z "$ac_c_werror_flag"
28643                          || test ! -s conftest.err'
28644   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28645   (eval $ac_try) 2>&5
28646   ac_status=$?
28647   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28648   (exit $ac_status); }; } &&
28649          { ac_try='test -s conftest$ac_exeext'
28650   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28651   (eval $ac_try) 2>&5
28652   ac_status=$?
28653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28654   (exit $ac_status); }; }; then
28655   ol_cv_db_db3=yes
28656 else
28657   echo "$as_me: failed program was:" >&5
28658 sed 's/^/| /' conftest.$ac_ext >&5
28659
28660 ol_cv_db_db3=no
28661 fi
28662 rm -f conftest.err conftest.$ac_objext \
28663       conftest$ac_exeext conftest.$ac_ext
28664
28665         LIBS="$ol_LIBS"
28666
28667 fi
28668 echo "$as_me:$LINENO: result: $ol_cv_db_db3" >&5
28669 echo "${ECHO_T}$ol_cv_db_db3" >&6
28670
28671         if test $ol_cv_db_db3 = yes ; then
28672                 ol_cv_lib_db=-ldb3
28673         fi
28674 fi
28675
28676         if test $ol_cv_lib_db = no ; then
28677         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-3)" >&5
28678 echo $ECHO_N "checking for Berkeley DB link (-ldb-3)... $ECHO_C" >&6
28679 if test "${ol_cv_db_db_3+set}" = set; then
28680   echo $ECHO_N "(cached) $ECHO_C" >&6
28681 else
28682
28683         ol_DB_LIB=-ldb-3
28684         ol_LIBS=$LIBS
28685         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28686
28687         cat >conftest.$ac_ext <<_ACEOF
28688 /* confdefs.h.  */
28689 _ACEOF
28690 cat confdefs.h >>conftest.$ac_ext
28691 cat >>conftest.$ac_ext <<_ACEOF
28692 /* end confdefs.h.  */
28693
28694 #ifdef HAVE_DB_185_H
28695 # include <db_185.h>
28696 #else
28697 # include <db.h>
28698 #endif
28699
28700 #ifndef DB_VERSION_MAJOR
28701 # define DB_VERSION_MAJOR 1
28702 #endif
28703
28704 #ifndef NULL
28705 #define NULL ((void*)0)
28706 #endif
28707
28708 int
28709 main ()
28710 {
28711
28712 #if DB_VERSION_MAJOR > 1
28713         {
28714                 char *version;
28715                 int major, minor, patch;
28716
28717                 version = db_version( &major, &minor, &patch );
28718
28719                 if( major != DB_VERSION_MAJOR ||
28720                         minor < DB_VERSION_MINOR )
28721                 {
28722                         printf("Berkeley DB version mismatch\n"
28723                                 "\theader: %s\n\tlibrary: %s\n",
28724                                 DB_VERSION_STRING, version);
28725                         return 1;
28726                 }
28727         }
28728 #endif
28729
28730 #if DB_VERSION_MAJOR > 2
28731         db_env_create( NULL, 0 );
28732 #elif DB_VERSION_MAJOR > 1
28733         db_appexit( NULL );
28734 #else
28735         (void) dbopen( NULL, 0, 0, 0, NULL);
28736 #endif
28737
28738   ;
28739   return 0;
28740 }
28741 _ACEOF
28742 rm -f conftest.$ac_objext conftest$ac_exeext
28743 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28744   (eval $ac_link) 2>conftest.er1
28745   ac_status=$?
28746   grep -v '^ *+' conftest.er1 >conftest.err
28747   rm -f conftest.er1
28748   cat conftest.err >&5
28749   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28750   (exit $ac_status); } &&
28751          { ac_try='test -z "$ac_c_werror_flag"
28752                          || test ! -s conftest.err'
28753   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28754   (eval $ac_try) 2>&5
28755   ac_status=$?
28756   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28757   (exit $ac_status); }; } &&
28758          { ac_try='test -s conftest$ac_exeext'
28759   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28760   (eval $ac_try) 2>&5
28761   ac_status=$?
28762   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28763   (exit $ac_status); }; }; then
28764   ol_cv_db_db_3=yes
28765 else
28766   echo "$as_me: failed program was:" >&5
28767 sed 's/^/| /' conftest.$ac_ext >&5
28768
28769 ol_cv_db_db_3=no
28770 fi
28771 rm -f conftest.err conftest.$ac_objext \
28772       conftest$ac_exeext conftest.$ac_ext
28773
28774         LIBS="$ol_LIBS"
28775
28776 fi
28777 echo "$as_me:$LINENO: result: $ol_cv_db_db_3" >&5
28778 echo "${ECHO_T}$ol_cv_db_db_3" >&6
28779
28780         if test $ol_cv_db_db_3 = yes ; then
28781                 ol_cv_lib_db=-ldb-3
28782         fi
28783 fi
28784
28785
28786 elif test $ol_cv_bdb_major = 2 ; then
28787         if test $ol_cv_lib_db = no ; then
28788         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb2)" >&5
28789 echo $ECHO_N "checking for Berkeley DB link (-ldb2)... $ECHO_C" >&6
28790 if test "${ol_cv_db_db2+set}" = set; then
28791   echo $ECHO_N "(cached) $ECHO_C" >&6
28792 else
28793
28794         ol_DB_LIB=-ldb2
28795         ol_LIBS=$LIBS
28796         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28797
28798         cat >conftest.$ac_ext <<_ACEOF
28799 /* confdefs.h.  */
28800 _ACEOF
28801 cat confdefs.h >>conftest.$ac_ext
28802 cat >>conftest.$ac_ext <<_ACEOF
28803 /* end confdefs.h.  */
28804
28805 #ifdef HAVE_DB_185_H
28806 # include <db_185.h>
28807 #else
28808 # include <db.h>
28809 #endif
28810
28811 #ifndef DB_VERSION_MAJOR
28812 # define DB_VERSION_MAJOR 1
28813 #endif
28814
28815 #ifndef NULL
28816 #define NULL ((void*)0)
28817 #endif
28818
28819 int
28820 main ()
28821 {
28822
28823 #if DB_VERSION_MAJOR > 1
28824         {
28825                 char *version;
28826                 int major, minor, patch;
28827
28828                 version = db_version( &major, &minor, &patch );
28829
28830                 if( major != DB_VERSION_MAJOR ||
28831                         minor < DB_VERSION_MINOR )
28832                 {
28833                         printf("Berkeley DB version mismatch\n"
28834                                 "\theader: %s\n\tlibrary: %s\n",
28835                                 DB_VERSION_STRING, version);
28836                         return 1;
28837                 }
28838         }
28839 #endif
28840
28841 #if DB_VERSION_MAJOR > 2
28842         db_env_create( NULL, 0 );
28843 #elif DB_VERSION_MAJOR > 1
28844         db_appexit( NULL );
28845 #else
28846         (void) dbopen( NULL, 0, 0, 0, NULL);
28847 #endif
28848
28849   ;
28850   return 0;
28851 }
28852 _ACEOF
28853 rm -f conftest.$ac_objext conftest$ac_exeext
28854 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28855   (eval $ac_link) 2>conftest.er1
28856   ac_status=$?
28857   grep -v '^ *+' conftest.er1 >conftest.err
28858   rm -f conftest.er1
28859   cat conftest.err >&5
28860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28861   (exit $ac_status); } &&
28862          { ac_try='test -z "$ac_c_werror_flag"
28863                          || test ! -s conftest.err'
28864   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28865   (eval $ac_try) 2>&5
28866   ac_status=$?
28867   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28868   (exit $ac_status); }; } &&
28869          { ac_try='test -s conftest$ac_exeext'
28870   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28871   (eval $ac_try) 2>&5
28872   ac_status=$?
28873   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28874   (exit $ac_status); }; }; then
28875   ol_cv_db_db2=yes
28876 else
28877   echo "$as_me: failed program was:" >&5
28878 sed 's/^/| /' conftest.$ac_ext >&5
28879
28880 ol_cv_db_db2=no
28881 fi
28882 rm -f conftest.err conftest.$ac_objext \
28883       conftest$ac_exeext conftest.$ac_ext
28884
28885         LIBS="$ol_LIBS"
28886
28887 fi
28888 echo "$as_me:$LINENO: result: $ol_cv_db_db2" >&5
28889 echo "${ECHO_T}$ol_cv_db_db2" >&6
28890
28891         if test $ol_cv_db_db2 = yes ; then
28892                 ol_cv_lib_db=-ldb2
28893         fi
28894 fi
28895
28896         if test $ol_cv_lib_db = no ; then
28897         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-2)" >&5
28898 echo $ECHO_N "checking for Berkeley DB link (-ldb-2)... $ECHO_C" >&6
28899 if test "${ol_cv_db_db_2+set}" = set; then
28900   echo $ECHO_N "(cached) $ECHO_C" >&6
28901 else
28902
28903         ol_DB_LIB=-ldb-2
28904         ol_LIBS=$LIBS
28905         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
28906
28907         cat >conftest.$ac_ext <<_ACEOF
28908 /* confdefs.h.  */
28909 _ACEOF
28910 cat confdefs.h >>conftest.$ac_ext
28911 cat >>conftest.$ac_ext <<_ACEOF
28912 /* end confdefs.h.  */
28913
28914 #ifdef HAVE_DB_185_H
28915 # include <db_185.h>
28916 #else
28917 # include <db.h>
28918 #endif
28919
28920 #ifndef DB_VERSION_MAJOR
28921 # define DB_VERSION_MAJOR 1
28922 #endif
28923
28924 #ifndef NULL
28925 #define NULL ((void*)0)
28926 #endif
28927
28928 int
28929 main ()
28930 {
28931
28932 #if DB_VERSION_MAJOR > 1
28933         {
28934                 char *version;
28935                 int major, minor, patch;
28936
28937                 version = db_version( &major, &minor, &patch );
28938
28939                 if( major != DB_VERSION_MAJOR ||
28940                         minor < DB_VERSION_MINOR )
28941                 {
28942                         printf("Berkeley DB version mismatch\n"
28943                                 "\theader: %s\n\tlibrary: %s\n",
28944                                 DB_VERSION_STRING, version);
28945                         return 1;
28946                 }
28947         }
28948 #endif
28949
28950 #if DB_VERSION_MAJOR > 2
28951         db_env_create( NULL, 0 );
28952 #elif DB_VERSION_MAJOR > 1
28953         db_appexit( NULL );
28954 #else
28955         (void) dbopen( NULL, 0, 0, 0, NULL);
28956 #endif
28957
28958   ;
28959   return 0;
28960 }
28961 _ACEOF
28962 rm -f conftest.$ac_objext conftest$ac_exeext
28963 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28964   (eval $ac_link) 2>conftest.er1
28965   ac_status=$?
28966   grep -v '^ *+' conftest.er1 >conftest.err
28967   rm -f conftest.er1
28968   cat conftest.err >&5
28969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28970   (exit $ac_status); } &&
28971          { ac_try='test -z "$ac_c_werror_flag"
28972                          || test ! -s conftest.err'
28973   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28974   (eval $ac_try) 2>&5
28975   ac_status=$?
28976   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28977   (exit $ac_status); }; } &&
28978          { ac_try='test -s conftest$ac_exeext'
28979   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28980   (eval $ac_try) 2>&5
28981   ac_status=$?
28982   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28983   (exit $ac_status); }; }; then
28984   ol_cv_db_db_2=yes
28985 else
28986   echo "$as_me: failed program was:" >&5
28987 sed 's/^/| /' conftest.$ac_ext >&5
28988
28989 ol_cv_db_db_2=no
28990 fi
28991 rm -f conftest.err conftest.$ac_objext \
28992       conftest$ac_exeext conftest.$ac_ext
28993
28994         LIBS="$ol_LIBS"
28995
28996 fi
28997 echo "$as_me:$LINENO: result: $ol_cv_db_db_2" >&5
28998 echo "${ECHO_T}$ol_cv_db_db_2" >&6
28999
29000         if test $ol_cv_db_db_2 = yes ; then
29001                 ol_cv_lib_db=-ldb-2
29002         fi
29003 fi
29004
29005
29006 elif test $ol_cv_bdb_major = 1 ; then
29007         if test $ol_cv_lib_db = no ; then
29008         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb1)" >&5
29009 echo $ECHO_N "checking for Berkeley DB link (-ldb1)... $ECHO_C" >&6
29010 if test "${ol_cv_db_db1+set}" = set; then
29011   echo $ECHO_N "(cached) $ECHO_C" >&6
29012 else
29013
29014         ol_DB_LIB=-ldb1
29015         ol_LIBS=$LIBS
29016         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29017
29018         cat >conftest.$ac_ext <<_ACEOF
29019 /* confdefs.h.  */
29020 _ACEOF
29021 cat confdefs.h >>conftest.$ac_ext
29022 cat >>conftest.$ac_ext <<_ACEOF
29023 /* end confdefs.h.  */
29024
29025 #ifdef HAVE_DB_185_H
29026 # include <db_185.h>
29027 #else
29028 # include <db.h>
29029 #endif
29030
29031 #ifndef DB_VERSION_MAJOR
29032 # define DB_VERSION_MAJOR 1
29033 #endif
29034
29035 #ifndef NULL
29036 #define NULL ((void*)0)
29037 #endif
29038
29039 int
29040 main ()
29041 {
29042
29043 #if DB_VERSION_MAJOR > 1
29044         {
29045                 char *version;
29046                 int major, minor, patch;
29047
29048                 version = db_version( &major, &minor, &patch );
29049
29050                 if( major != DB_VERSION_MAJOR ||
29051                         minor < DB_VERSION_MINOR )
29052                 {
29053                         printf("Berkeley DB version mismatch\n"
29054                                 "\theader: %s\n\tlibrary: %s\n",
29055                                 DB_VERSION_STRING, version);
29056                         return 1;
29057                 }
29058         }
29059 #endif
29060
29061 #if DB_VERSION_MAJOR > 2
29062         db_env_create( NULL, 0 );
29063 #elif DB_VERSION_MAJOR > 1
29064         db_appexit( NULL );
29065 #else
29066         (void) dbopen( NULL, 0, 0, 0, NULL);
29067 #endif
29068
29069   ;
29070   return 0;
29071 }
29072 _ACEOF
29073 rm -f conftest.$ac_objext conftest$ac_exeext
29074 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29075   (eval $ac_link) 2>conftest.er1
29076   ac_status=$?
29077   grep -v '^ *+' conftest.er1 >conftest.err
29078   rm -f conftest.er1
29079   cat conftest.err >&5
29080   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29081   (exit $ac_status); } &&
29082          { ac_try='test -z "$ac_c_werror_flag"
29083                          || test ! -s conftest.err'
29084   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29085   (eval $ac_try) 2>&5
29086   ac_status=$?
29087   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29088   (exit $ac_status); }; } &&
29089          { ac_try='test -s conftest$ac_exeext'
29090   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29091   (eval $ac_try) 2>&5
29092   ac_status=$?
29093   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29094   (exit $ac_status); }; }; then
29095   ol_cv_db_db1=yes
29096 else
29097   echo "$as_me: failed program was:" >&5
29098 sed 's/^/| /' conftest.$ac_ext >&5
29099
29100 ol_cv_db_db1=no
29101 fi
29102 rm -f conftest.err conftest.$ac_objext \
29103       conftest$ac_exeext conftest.$ac_ext
29104
29105         LIBS="$ol_LIBS"
29106
29107 fi
29108 echo "$as_me:$LINENO: result: $ol_cv_db_db1" >&5
29109 echo "${ECHO_T}$ol_cv_db_db1" >&6
29110
29111         if test $ol_cv_db_db1 = yes ; then
29112                 ol_cv_lib_db=-ldb1
29113         fi
29114 fi
29115
29116         if test $ol_cv_lib_db = no ; then
29117         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-1)" >&5
29118 echo $ECHO_N "checking for Berkeley DB link (-ldb-1)... $ECHO_C" >&6
29119 if test "${ol_cv_db_db_1+set}" = set; then
29120   echo $ECHO_N "(cached) $ECHO_C" >&6
29121 else
29122
29123         ol_DB_LIB=-ldb-1
29124         ol_LIBS=$LIBS
29125         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29126
29127         cat >conftest.$ac_ext <<_ACEOF
29128 /* confdefs.h.  */
29129 _ACEOF
29130 cat confdefs.h >>conftest.$ac_ext
29131 cat >>conftest.$ac_ext <<_ACEOF
29132 /* end confdefs.h.  */
29133
29134 #ifdef HAVE_DB_185_H
29135 # include <db_185.h>
29136 #else
29137 # include <db.h>
29138 #endif
29139
29140 #ifndef DB_VERSION_MAJOR
29141 # define DB_VERSION_MAJOR 1
29142 #endif
29143
29144 #ifndef NULL
29145 #define NULL ((void*)0)
29146 #endif
29147
29148 int
29149 main ()
29150 {
29151
29152 #if DB_VERSION_MAJOR > 1
29153         {
29154                 char *version;
29155                 int major, minor, patch;
29156
29157                 version = db_version( &major, &minor, &patch );
29158
29159                 if( major != DB_VERSION_MAJOR ||
29160                         minor < DB_VERSION_MINOR )
29161                 {
29162                         printf("Berkeley DB version mismatch\n"
29163                                 "\theader: %s\n\tlibrary: %s\n",
29164                                 DB_VERSION_STRING, version);
29165                         return 1;
29166                 }
29167         }
29168 #endif
29169
29170 #if DB_VERSION_MAJOR > 2
29171         db_env_create( NULL, 0 );
29172 #elif DB_VERSION_MAJOR > 1
29173         db_appexit( NULL );
29174 #else
29175         (void) dbopen( NULL, 0, 0, 0, NULL);
29176 #endif
29177
29178   ;
29179   return 0;
29180 }
29181 _ACEOF
29182 rm -f conftest.$ac_objext conftest$ac_exeext
29183 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29184   (eval $ac_link) 2>conftest.er1
29185   ac_status=$?
29186   grep -v '^ *+' conftest.er1 >conftest.err
29187   rm -f conftest.er1
29188   cat conftest.err >&5
29189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29190   (exit $ac_status); } &&
29191          { ac_try='test -z "$ac_c_werror_flag"
29192                          || test ! -s conftest.err'
29193   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29194   (eval $ac_try) 2>&5
29195   ac_status=$?
29196   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29197   (exit $ac_status); }; } &&
29198          { ac_try='test -s conftest$ac_exeext'
29199   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29200   (eval $ac_try) 2>&5
29201   ac_status=$?
29202   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29203   (exit $ac_status); }; }; then
29204   ol_cv_db_db_1=yes
29205 else
29206   echo "$as_me: failed program was:" >&5
29207 sed 's/^/| /' conftest.$ac_ext >&5
29208
29209 ol_cv_db_db_1=no
29210 fi
29211 rm -f conftest.err conftest.$ac_objext \
29212       conftest$ac_exeext conftest.$ac_ext
29213
29214         LIBS="$ol_LIBS"
29215
29216 fi
29217 echo "$as_me:$LINENO: result: $ol_cv_db_db_1" >&5
29218 echo "${ECHO_T}$ol_cv_db_db_1" >&6
29219
29220         if test $ol_cv_db_db_1 = yes ; then
29221                 ol_cv_lib_db=-ldb-1
29222         fi
29223 fi
29224
29225 fi
29226 if test $ol_cv_lib_db = no ; then
29227         echo "$as_me:$LINENO: checking for Berkeley DB link (default)" >&5
29228 echo $ECHO_N "checking for Berkeley DB link (default)... $ECHO_C" >&6
29229 if test "${ol_cv_db_none+set}" = set; then
29230   echo $ECHO_N "(cached) $ECHO_C" >&6
29231 else
29232
29233         ol_DB_LIB=
29234         ol_LIBS=$LIBS
29235         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
29236
29237         cat >conftest.$ac_ext <<_ACEOF
29238 /* confdefs.h.  */
29239 _ACEOF
29240 cat confdefs.h >>conftest.$ac_ext
29241 cat >>conftest.$ac_ext <<_ACEOF
29242 /* end confdefs.h.  */
29243
29244 #ifdef HAVE_DB_185_H
29245 # include <db_185.h>
29246 #else
29247 # include <db.h>
29248 #endif
29249
29250 #ifndef DB_VERSION_MAJOR
29251 # define DB_VERSION_MAJOR 1
29252 #endif
29253
29254 #ifndef NULL
29255 #define NULL ((void*)0)
29256 #endif
29257
29258 int
29259 main ()
29260 {
29261
29262 #if DB_VERSION_MAJOR > 1
29263         {
29264                 char *version;
29265                 int major, minor, patch;
29266
29267                 version = db_version( &major, &minor, &patch );
29268
29269                 if( major != DB_VERSION_MAJOR ||
29270                         minor < DB_VERSION_MINOR )
29271                 {
29272                         printf("Berkeley DB version mismatch\n"
29273                                 "\theader: %s\n\tlibrary: %s\n",
29274                                 DB_VERSION_STRING, version);
29275                         return 1;
29276                 }
29277         }
29278 #endif
29279
29280 #if DB_VERSION_MAJOR > 2
29281         db_env_create( NULL, 0 );
29282 #elif DB_VERSION_MAJOR > 1
29283         db_appexit( NULL );
29284 #else
29285         (void) dbopen( NULL, 0, 0, 0, NULL);
29286 #endif
29287
29288   ;
29289   return 0;
29290 }
29291 _ACEOF
29292 rm -f conftest.$ac_objext conftest$ac_exeext
29293 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29294   (eval $ac_link) 2>conftest.er1
29295   ac_status=$?
29296   grep -v '^ *+' conftest.er1 >conftest.err
29297   rm -f conftest.er1
29298   cat conftest.err >&5
29299   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29300   (exit $ac_status); } &&
29301          { ac_try='test -z "$ac_c_werror_flag"
29302                          || test ! -s conftest.err'
29303   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29304   (eval $ac_try) 2>&5
29305   ac_status=$?
29306   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29307   (exit $ac_status); }; } &&
29308          { ac_try='test -s conftest$ac_exeext'
29309   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29310   (eval $ac_try) 2>&5
29311   ac_status=$?
29312   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29313   (exit $ac_status); }; }; then
29314   ol_cv_db_none=yes
29315 else
29316   echo "$as_me: failed program was:" >&5
29317 sed 's/^/| /' conftest.$ac_ext >&5
29318
29319 ol_cv_db_none=no
29320 fi
29321 rm -f conftest.err conftest.$ac_objext \
29322       conftest$ac_exeext conftest.$ac_ext
29323
29324         LIBS="$ol_LIBS"
29325
29326 fi
29327 echo "$as_me:$LINENO: result: $ol_cv_db_none" >&5
29328 echo "${ECHO_T}$ol_cv_db_none" >&6
29329
29330         if test $ol_cv_db_none = yes ; then
29331                 ol_cv_lib_db=yes
29332         fi
29333 fi
29334
29335
29336         if test "$ol_cv_lib_db" != no ; then
29337                 ol_cv_berkeley_db=yes
29338                 echo "$as_me:$LINENO: checking for Berkeley DB version match" >&5
29339 echo $ECHO_N "checking for Berkeley DB version match... $ECHO_C" >&6
29340 if test "${ol_cv_berkeley_db_version+set}" = set; then
29341   echo $ECHO_N "(cached) $ECHO_C" >&6
29342 else
29343
29344         ol_LIBS="$LIBS"
29345         LIBS="$LTHREAD_LIBS $LIBS"
29346         if test $ol_cv_lib_db != yes ; then
29347                 LIBS="$ol_cv_lib_db $LIBS"
29348         fi
29349
29350         if test "$cross_compiling" = yes; then
29351   ol_cv_berkeley_db_version=cross
29352 else
29353   cat >conftest.$ac_ext <<_ACEOF
29354 /* confdefs.h.  */
29355 _ACEOF
29356 cat confdefs.h >>conftest.$ac_ext
29357 cat >>conftest.$ac_ext <<_ACEOF
29358 /* end confdefs.h.  */
29359
29360 #ifdef HAVE_DB_185_H
29361         choke me;
29362 #else
29363 #include <db.h>
29364 #endif
29365 #ifndef DB_VERSION_MAJOR
29366 # define DB_VERSION_MAJOR 1
29367 #endif
29368 #ifndef NULL
29369 #define NULL ((void *)0)
29370 #endif
29371 main()
29372 {
29373 #if DB_VERSION_MAJOR > 1
29374         char *version;
29375         int major, minor, patch;
29376
29377         version = db_version( &major, &minor, &patch );
29378
29379         if( major != DB_VERSION_MAJOR ||
29380                 minor != DB_VERSION_MINOR ||
29381                 patch != DB_VERSION_PATCH )
29382         {
29383                 printf("Berkeley DB version mismatch\n"
29384                         "\theader: %s\n\tlibrary: %s\n",
29385                         DB_VERSION_STRING, version);
29386                 return 1;
29387         }
29388 #endif
29389
29390         return 0;
29391 }
29392 _ACEOF
29393 rm -f conftest$ac_exeext
29394 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29395   (eval $ac_link) 2>&5
29396   ac_status=$?
29397   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29398   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29399   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29400   (eval $ac_try) 2>&5
29401   ac_status=$?
29402   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29403   (exit $ac_status); }; }; then
29404   ol_cv_berkeley_db_version=yes
29405 else
29406   echo "$as_me: program exited with status $ac_status" >&5
29407 echo "$as_me: failed program was:" >&5
29408 sed 's/^/| /' conftest.$ac_ext >&5
29409
29410 ( exit $ac_status )
29411 ol_cv_berkeley_db_version=no
29412 fi
29413 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29414 fi
29415
29416         LIBS="$ol_LIBS"
29417
29418 fi
29419 echo "$as_me:$LINENO: result: $ol_cv_berkeley_db_version" >&5
29420 echo "${ECHO_T}$ol_cv_berkeley_db_version" >&6
29421
29422         if test $ol_cv_berkeley_db_version = no ; then
29423                 { { echo "$as_me:$LINENO: error: Berkeley DB version mismatch" >&5
29424 echo "$as_me: error: Berkeley DB version mismatch" >&2;}
29425    { (exit 1); exit 1; }; }
29426         fi
29427
29428                 echo "$as_me:$LINENO: checking for Berkeley DB thread support" >&5
29429 echo $ECHO_N "checking for Berkeley DB thread support... $ECHO_C" >&6
29430 if test "${ol_cv_berkeley_db_thread+set}" = set; then
29431   echo $ECHO_N "(cached) $ECHO_C" >&6
29432 else
29433
29434         ol_LIBS="$LIBS"
29435         LIBS="$LTHREAD_LIBS $LIBS"
29436         if test $ol_cv_lib_db != yes ; then
29437                 LIBS="$ol_cv_lib_db $LIBS"
29438         fi
29439
29440         if test "$cross_compiling" = yes; then
29441   ol_cv_berkeley_db_thread=cross
29442 else
29443   cat >conftest.$ac_ext <<_ACEOF
29444 /* confdefs.h.  */
29445 _ACEOF
29446 cat confdefs.h >>conftest.$ac_ext
29447 cat >>conftest.$ac_ext <<_ACEOF
29448 /* end confdefs.h.  */
29449
29450 #ifdef HAVE_DB_185_H
29451         choke me;
29452 #else
29453 #include <db.h>
29454 #endif
29455 #ifndef NULL
29456 #define NULL ((void *)0)
29457 #endif
29458 main()
29459 {
29460         int rc;
29461         u_int32_t flags = DB_CREATE |
29462 #ifdef DB_PRIVATE
29463                 DB_PRIVATE |
29464 #endif
29465                 DB_THREAD;
29466
29467 #if DB_VERSION_MAJOR > 2
29468         DB_ENV *env = NULL;
29469
29470         rc = db_env_create( &env, 0 );
29471
29472         flags |= DB_INIT_MPOOL;
29473 #ifdef DB_MPOOL_PRIVATE
29474         flags |= DB_MPOOL_PRIVATE;
29475 #endif
29476
29477         if( rc ) {
29478                 printf("BerkeleyDB: %s\n", db_strerror(rc) );
29479                 return rc;
29480         }
29481
29482 #if (DB_VERSION_MAJOR > 3) || (DB_VERSION_MINOR >= 1)
29483         rc = (env->open)( env, NULL, flags, 0 );
29484 #else
29485         rc = (env->open)( env, NULL, NULL, flags, 0 );
29486 #endif
29487
29488         if ( rc == 0 ) {
29489                 rc = env->close( env, 0 );
29490         }
29491
29492         if( rc ) {
29493                 printf("BerkeleyDB: %s\n", db_strerror(rc) );
29494                 return rc;
29495         }
29496
29497 #else
29498         DB_ENV env;
29499         memset( &env, '\0', sizeof(env) );
29500
29501         rc = db_appinit( NULL, NULL, &env, flags );
29502
29503         if( rc == 0 ) {
29504                 db_appexit( &env );
29505         }
29506
29507         unlink("__db_mpool.share");
29508         unlink("__db_lock.share");
29509 #endif
29510
29511         return rc;
29512 }
29513 _ACEOF
29514 rm -f conftest$ac_exeext
29515 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29516   (eval $ac_link) 2>&5
29517   ac_status=$?
29518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29519   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29520   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29521   (eval $ac_try) 2>&5
29522   ac_status=$?
29523   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29524   (exit $ac_status); }; }; then
29525   ol_cv_berkeley_db_thread=yes
29526 else
29527   echo "$as_me: program exited with status $ac_status" >&5
29528 echo "$as_me: failed program was:" >&5
29529 sed 's/^/| /' conftest.$ac_ext >&5
29530
29531 ( exit $ac_status )
29532 ol_cv_berkeley_db_thread=no
29533 fi
29534 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29535 fi
29536
29537         LIBS="$ol_LIBS"
29538
29539 fi
29540 echo "$as_me:$LINENO: result: $ol_cv_berkeley_db_thread" >&5
29541 echo "${ECHO_T}$ol_cv_berkeley_db_thread" >&6
29542
29543         if test $ol_cv_berkeley_db_thread != no ; then
29544
29545 cat >>confdefs.h <<\_ACEOF
29546 #define HAVE_BERKELEY_DB_THREAD 1
29547 _ACEOF
29548
29549         fi
29550
29551         fi
29552 fi
29553
29554
29555         if test $ol_cv_berkeley_db = no ; then
29556                 { { echo "$as_me:$LINENO: error: BDB/HDB: BerkeleyDB not available" >&5
29557 echo "$as_me: error: BDB/HDB: BerkeleyDB not available" >&2;}
29558    { (exit 1); exit 1; }; }
29559         fi
29560
29561
29562 cat >>confdefs.h <<\_ACEOF
29563 #define HAVE_BERKELEY_DB 1
29564 _ACEOF
29565
29566
29567                         if test $ol_cv_lib_db != yes ; then
29568                 BDB_LIBS="$BDB_LIBS $ol_cv_lib_db"
29569         fi
29570
29571         echo "$as_me:$LINENO: checking Berkeley DB version for BDB/HDB backends" >&5
29572 echo $ECHO_N "checking Berkeley DB version for BDB/HDB backends... $ECHO_C" >&6
29573 if test "${ol_cv_bdb_compat+set}" = set; then
29574   echo $ECHO_N "(cached) $ECHO_C" >&6
29575 else
29576
29577         cat >conftest.$ac_ext <<_ACEOF
29578 /* confdefs.h.  */
29579 _ACEOF
29580 cat confdefs.h >>conftest.$ac_ext
29581 cat >>conftest.$ac_ext <<_ACEOF
29582 /* end confdefs.h.  */
29583
29584 #include <db.h>
29585
29586  /* this check could be improved */
29587 #ifndef DB_VERSION_MAJOR
29588 #       define DB_VERSION_MAJOR 1
29589 #endif
29590 #ifndef DB_VERSION_MINOR
29591 #       define DB_VERSION_MINOR 0
29592 #endif
29593
29594 #define DB_VERSION_MM   ((DB_VERSION_MAJOR<<8)|DB_VERSION_MINOR)
29595
29596 /* require 4.4 or later */
29597 #if DB_VERSION_MM >= 0x0404
29598         __db_version_compat
29599 #endif
29600
29601 _ACEOF
29602 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
29603   $EGREP "__db_version_compat" >/dev/null 2>&1; then
29604   ol_cv_bdb_compat=yes
29605 else
29606   ol_cv_bdb_compat=no
29607 fi
29608 rm -f conftest*
29609
29610 fi
29611 echo "$as_me:$LINENO: result: $ol_cv_bdb_compat" >&5
29612 echo "${ECHO_T}$ol_cv_bdb_compat" >&6
29613
29614
29615         if test $ol_cv_bdb_compat != yes ; then
29616                 { { echo "$as_me:$LINENO: error: BDB/HDB: BerkeleyDB version incompatible" >&5
29617 echo "$as_me: error: BDB/HDB: BerkeleyDB version incompatible" >&2;}
29618    { (exit 1); exit 1; }; }
29619         fi
29620
29621         SLAPD_LIBS="$SLAPD_LIBS \$(BDB_LIBS)"
29622
29623         ol_link_bdb=yes
29624 fi
29625
29626
29627 if test $ol_enable_dynamic = yes && test $enable_shared = yes ; then
29628         BUILD_LIBS_DYNAMIC=shared
29629
29630 cat >>confdefs.h <<\_ACEOF
29631 #define LDAP_LIBS_DYNAMIC 1
29632 _ACEOF
29633
29634         LTSTATIC=""
29635 else
29636         BUILD_LIBS_DYNAMIC=static
29637         LTSTATIC="-static"
29638 fi
29639
29640 if test $ol_enable_wrappers != no ; then
29641
29642 for ac_header in tcpd.h
29643 do
29644 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
29645 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29646   echo "$as_me:$LINENO: checking for $ac_header" >&5
29647 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
29648 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29649   echo $ECHO_N "(cached) $ECHO_C" >&6
29650 fi
29651 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
29652 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
29653 else
29654   # Is the header compilable?
29655 echo "$as_me:$LINENO: checking $ac_header usability" >&5
29656 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
29657 cat >conftest.$ac_ext <<_ACEOF
29658 /* confdefs.h.  */
29659 _ACEOF
29660 cat confdefs.h >>conftest.$ac_ext
29661 cat >>conftest.$ac_ext <<_ACEOF
29662 /* end confdefs.h.  */
29663 $ac_includes_default
29664 #include <$ac_header>
29665 _ACEOF
29666 rm -f conftest.$ac_objext
29667 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
29668   (eval $ac_compile) 2>conftest.er1
29669   ac_status=$?
29670   grep -v '^ *+' conftest.er1 >conftest.err
29671   rm -f conftest.er1
29672   cat conftest.err >&5
29673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29674   (exit $ac_status); } &&
29675          { ac_try='test -z "$ac_c_werror_flag"
29676                          || test ! -s conftest.err'
29677   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29678   (eval $ac_try) 2>&5
29679   ac_status=$?
29680   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29681   (exit $ac_status); }; } &&
29682          { ac_try='test -s conftest.$ac_objext'
29683   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29684   (eval $ac_try) 2>&5
29685   ac_status=$?
29686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29687   (exit $ac_status); }; }; then
29688   ac_header_compiler=yes
29689 else
29690   echo "$as_me: failed program was:" >&5
29691 sed 's/^/| /' conftest.$ac_ext >&5
29692
29693 ac_header_compiler=no
29694 fi
29695 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
29696 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
29697 echo "${ECHO_T}$ac_header_compiler" >&6
29698
29699 # Is the header present?
29700 echo "$as_me:$LINENO: checking $ac_header presence" >&5
29701 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
29702 cat >conftest.$ac_ext <<_ACEOF
29703 /* confdefs.h.  */
29704 _ACEOF
29705 cat confdefs.h >>conftest.$ac_ext
29706 cat >>conftest.$ac_ext <<_ACEOF
29707 /* end confdefs.h.  */
29708 #include <$ac_header>
29709 _ACEOF
29710 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
29711   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
29712   ac_status=$?
29713   grep -v '^ *+' conftest.er1 >conftest.err
29714   rm -f conftest.er1
29715   cat conftest.err >&5
29716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29717   (exit $ac_status); } >/dev/null; then
29718   if test -s conftest.err; then
29719     ac_cpp_err=$ac_c_preproc_warn_flag
29720     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
29721   else
29722     ac_cpp_err=
29723   fi
29724 else
29725   ac_cpp_err=yes
29726 fi
29727 if test -z "$ac_cpp_err"; then
29728   ac_header_preproc=yes
29729 else
29730   echo "$as_me: failed program was:" >&5
29731 sed 's/^/| /' conftest.$ac_ext >&5
29732
29733   ac_header_preproc=no
29734 fi
29735 rm -f conftest.err conftest.$ac_ext
29736 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
29737 echo "${ECHO_T}$ac_header_preproc" >&6
29738
29739 # So?  What about this header?
29740 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
29741   yes:no: )
29742     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
29743 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
29744     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
29745 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
29746     ac_header_preproc=yes
29747     ;;
29748   no:yes:* )
29749     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
29750 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
29751     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
29752 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
29753     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
29754 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
29755     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
29756 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
29757     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29758 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29759     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
29760 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
29761     (
29762       cat <<\_ASBOX
29763 ## --------------------------------------------- ##
29764 ## Report this to <http://www.openldap.org/its/> ##
29765 ## --------------------------------------------- ##
29766 _ASBOX
29767     ) |
29768       sed "s/^/$as_me: WARNING:     /" >&2
29769     ;;
29770 esac
29771 echo "$as_me:$LINENO: checking for $ac_header" >&5
29772 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
29773 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29774   echo $ECHO_N "(cached) $ECHO_C" >&6
29775 else
29776   eval "$as_ac_Header=\$ac_header_preproc"
29777 fi
29778 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
29779 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
29780
29781 fi
29782 if test `eval echo '${'$as_ac_Header'}'` = yes; then
29783   cat >>confdefs.h <<_ACEOF
29784 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
29785 _ACEOF
29786
29787                 echo "$as_me:$LINENO: checking for TCP wrappers library" >&5
29788 echo $ECHO_N "checking for TCP wrappers library... $ECHO_C" >&6
29789                 save_LIBS="$LIBS"
29790                 LIBS="$LIBS -lwrap"
29791                 cat >conftest.$ac_ext <<_ACEOF
29792 /* confdefs.h.  */
29793 _ACEOF
29794 cat confdefs.h >>conftest.$ac_ext
29795 cat >>conftest.$ac_ext <<_ACEOF
29796 /* end confdefs.h.  */
29797
29798 #include <tcpd.h>
29799 int allow_severity = 0;
29800 int deny_severity  = 0;
29801
29802 struct request_info *req;
29803
29804 int
29805 main ()
29806 {
29807
29808 hosts_access(req)
29809
29810   ;
29811   return 0;
29812 }
29813 _ACEOF
29814 rm -f conftest.$ac_objext conftest$ac_exeext
29815 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29816   (eval $ac_link) 2>conftest.er1
29817   ac_status=$?
29818   grep -v '^ *+' conftest.er1 >conftest.err
29819   rm -f conftest.er1
29820   cat conftest.err >&5
29821   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29822   (exit $ac_status); } &&
29823          { ac_try='test -z "$ac_c_werror_flag"
29824                          || test ! -s conftest.err'
29825   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29826   (eval $ac_try) 2>&5
29827   ac_status=$?
29828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29829   (exit $ac_status); }; } &&
29830          { ac_try='test -s conftest$ac_exeext'
29831   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29832   (eval $ac_try) 2>&5
29833   ac_status=$?
29834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29835   (exit $ac_status); }; }; then
29836   echo "$as_me:$LINENO: result: -lwrap" >&5
29837 echo "${ECHO_T}-lwrap" >&6
29838                 have_wrappers=yes
29839                 LIBS="$save_LIBS"
29840 else
29841   echo "$as_me: failed program was:" >&5
29842 sed 's/^/| /' conftest.$ac_ext >&5
29843
29844
29845                                 LIBS="$LIBS -lnsl"
29846                 cat >conftest.$ac_ext <<_ACEOF
29847 /* confdefs.h.  */
29848 _ACEOF
29849 cat confdefs.h >>conftest.$ac_ext
29850 cat >>conftest.$ac_ext <<_ACEOF
29851 /* end confdefs.h.  */
29852
29853 #include <tcpd.h>
29854 int allow_severity = 0;
29855 int deny_severity  = 0;
29856
29857 struct request_info *req;
29858
29859 int
29860 main ()
29861 {
29862
29863 hosts_access(req)
29864
29865   ;
29866   return 0;
29867 }
29868 _ACEOF
29869 rm -f conftest.$ac_objext conftest$ac_exeext
29870 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29871   (eval $ac_link) 2>conftest.er1
29872   ac_status=$?
29873   grep -v '^ *+' conftest.er1 >conftest.err
29874   rm -f conftest.er1
29875   cat conftest.err >&5
29876   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29877   (exit $ac_status); } &&
29878          { ac_try='test -z "$ac_c_werror_flag"
29879                          || test ! -s conftest.err'
29880   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29881   (eval $ac_try) 2>&5
29882   ac_status=$?
29883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29884   (exit $ac_status); }; } &&
29885          { ac_try='test -s conftest$ac_exeext'
29886   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29887   (eval $ac_try) 2>&5
29888   ac_status=$?
29889   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29890   (exit $ac_status); }; }; then
29891   echo "$as_me:$LINENO: result: -lwrap -lnsl" >&5
29892 echo "${ECHO_T}-lwrap -lnsl" >&6
29893                 have_wrappers=yes
29894                 LIBS="$save_LIBS -lnsl"
29895 else
29896   echo "$as_me: failed program was:" >&5
29897 sed 's/^/| /' conftest.$ac_ext >&5
29898
29899
29900                 echo "$as_me:$LINENO: result: no" >&5
29901 echo "${ECHO_T}no" >&6
29902                 have_wrappers=no
29903                 LIBS=$save_LIBS
29904 fi
29905 rm -f conftest.err conftest.$ac_objext \
29906       conftest$ac_exeext conftest.$ac_ext
29907 fi
29908 rm -f conftest.err conftest.$ac_objext \
29909       conftest$ac_exeext conftest.$ac_ext
29910 else
29911   have_wrappers=no
29912 fi
29913
29914 done
29915
29916
29917         if test $have_wrappers = yes ; then
29918
29919 cat >>confdefs.h <<\_ACEOF
29920 #define HAVE_TCPD 1
29921 _ACEOF
29922
29923                 WRAP_LIBS="-lwrap"
29924         elif test $ol_enable_wrappers = yes ; then
29925                 { { echo "$as_me:$LINENO: error: could not find TCP wrappers, select apppropriate options or disable" >&5
29926 echo "$as_me: error: could not find TCP wrappers, select apppropriate options or disable" >&2;}
29927    { (exit 1); exit 1; }; }
29928         else
29929                 { echo "$as_me:$LINENO: WARNING: could not find TCP wrappers, support disabled" >&5
29930 echo "$as_me: WARNING: could not find TCP wrappers, support disabled" >&2;}
29931                 WRAP_LIBS=""
29932         fi
29933 fi
29934
29935 if test $ol_enable_syslog != no ; then
29936         echo "$as_me:$LINENO: checking for openlog" >&5
29937 echo $ECHO_N "checking for openlog... $ECHO_C" >&6
29938 if test "${ac_cv_func_openlog+set}" = set; then
29939   echo $ECHO_N "(cached) $ECHO_C" >&6
29940 else
29941   cat >conftest.$ac_ext <<_ACEOF
29942 /* confdefs.h.  */
29943 _ACEOF
29944 cat confdefs.h >>conftest.$ac_ext
29945 cat >>conftest.$ac_ext <<_ACEOF
29946 /* end confdefs.h.  */
29947 /* Define openlog to an innocuous variant, in case <limits.h> declares openlog.
29948    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
29949 #define openlog innocuous_openlog
29950
29951 /* System header to define __stub macros and hopefully few prototypes,
29952     which can conflict with char openlog (); below.
29953     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
29954     <limits.h> exists even on freestanding compilers.  */
29955
29956 #ifdef __STDC__
29957 # include <limits.h>
29958 #else
29959 # include <assert.h>
29960 #endif
29961
29962 #undef openlog
29963
29964 /* Override any gcc2 internal prototype to avoid an error.  */
29965 #ifdef __cplusplus
29966 extern "C"
29967 {
29968 #endif
29969 /* We use char because int might match the return type of a gcc2
29970    builtin and then its argument prototype would still apply.  */
29971 char openlog ();
29972 /* The GNU C library defines this for functions which it implements
29973     to always fail with ENOSYS.  Some functions are actually named
29974     something starting with __ and the normal name is an alias.  */
29975 #if defined (__stub_openlog) || defined (__stub___openlog)
29976 choke me
29977 #else
29978 char (*f) () = openlog;
29979 #endif
29980 #ifdef __cplusplus
29981 }
29982 #endif
29983
29984 int
29985 main ()
29986 {
29987 return f != openlog;
29988   ;
29989   return 0;
29990 }
29991 _ACEOF
29992 rm -f conftest.$ac_objext conftest$ac_exeext
29993 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29994   (eval $ac_link) 2>conftest.er1
29995   ac_status=$?
29996   grep -v '^ *+' conftest.er1 >conftest.err
29997   rm -f conftest.er1
29998   cat conftest.err >&5
29999   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30000   (exit $ac_status); } &&
30001          { ac_try='test -z "$ac_c_werror_flag"
30002                          || test ! -s conftest.err'
30003   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30004   (eval $ac_try) 2>&5
30005   ac_status=$?
30006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30007   (exit $ac_status); }; } &&
30008          { ac_try='test -s conftest$ac_exeext'
30009   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30010   (eval $ac_try) 2>&5
30011   ac_status=$?
30012   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30013   (exit $ac_status); }; }; then
30014   ac_cv_func_openlog=yes
30015 else
30016   echo "$as_me: failed program was:" >&5
30017 sed 's/^/| /' conftest.$ac_ext >&5
30018
30019 ac_cv_func_openlog=no
30020 fi
30021 rm -f conftest.err conftest.$ac_objext \
30022       conftest$ac_exeext conftest.$ac_ext
30023 fi
30024 echo "$as_me:$LINENO: result: $ac_cv_func_openlog" >&5
30025 echo "${ECHO_T}$ac_cv_func_openlog" >&6
30026
30027         if test $ac_cv_func_openlog = no && test $ol_enable_syslog = yes; then
30028                 { { echo "$as_me:$LINENO: error: could not find syslog" >&5
30029 echo "$as_me: error: could not find syslog" >&2;}
30030    { (exit select appropriate options or disable); exit select appropriate options or disable; }; }
30031         fi
30032         ol_enable_syslog=$ac_cv_func_openlog
30033 fi
30034
30035 ol_link_sql=no
30036 if test $ol_enable_sql != no ; then
30037
30038
30039 for ac_header in sql.h sqlext.h
30040 do
30041 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
30042 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30043   echo "$as_me:$LINENO: checking for $ac_header" >&5
30044 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
30045 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30046   echo $ECHO_N "(cached) $ECHO_C" >&6
30047 fi
30048 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
30049 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
30050 else
30051   # Is the header compilable?
30052 echo "$as_me:$LINENO: checking $ac_header usability" >&5
30053 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
30054 cat >conftest.$ac_ext <<_ACEOF
30055 /* confdefs.h.  */
30056 _ACEOF
30057 cat confdefs.h >>conftest.$ac_ext
30058 cat >>conftest.$ac_ext <<_ACEOF
30059 /* end confdefs.h.  */
30060 $ac_includes_default
30061 #include <$ac_header>
30062 _ACEOF
30063 rm -f conftest.$ac_objext
30064 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30065   (eval $ac_compile) 2>conftest.er1
30066   ac_status=$?
30067   grep -v '^ *+' conftest.er1 >conftest.err
30068   rm -f conftest.er1
30069   cat conftest.err >&5
30070   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30071   (exit $ac_status); } &&
30072          { ac_try='test -z "$ac_c_werror_flag"
30073                          || test ! -s conftest.err'
30074   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30075   (eval $ac_try) 2>&5
30076   ac_status=$?
30077   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30078   (exit $ac_status); }; } &&
30079          { ac_try='test -s conftest.$ac_objext'
30080   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30081   (eval $ac_try) 2>&5
30082   ac_status=$?
30083   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30084   (exit $ac_status); }; }; then
30085   ac_header_compiler=yes
30086 else
30087   echo "$as_me: failed program was:" >&5
30088 sed 's/^/| /' conftest.$ac_ext >&5
30089
30090 ac_header_compiler=no
30091 fi
30092 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
30093 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
30094 echo "${ECHO_T}$ac_header_compiler" >&6
30095
30096 # Is the header present?
30097 echo "$as_me:$LINENO: checking $ac_header presence" >&5
30098 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
30099 cat >conftest.$ac_ext <<_ACEOF
30100 /* confdefs.h.  */
30101 _ACEOF
30102 cat confdefs.h >>conftest.$ac_ext
30103 cat >>conftest.$ac_ext <<_ACEOF
30104 /* end confdefs.h.  */
30105 #include <$ac_header>
30106 _ACEOF
30107 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
30108   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
30109   ac_status=$?
30110   grep -v '^ *+' conftest.er1 >conftest.err
30111   rm -f conftest.er1
30112   cat conftest.err >&5
30113   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30114   (exit $ac_status); } >/dev/null; then
30115   if test -s conftest.err; then
30116     ac_cpp_err=$ac_c_preproc_warn_flag
30117     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
30118   else
30119     ac_cpp_err=
30120   fi
30121 else
30122   ac_cpp_err=yes
30123 fi
30124 if test -z "$ac_cpp_err"; then
30125   ac_header_preproc=yes
30126 else
30127   echo "$as_me: failed program was:" >&5
30128 sed 's/^/| /' conftest.$ac_ext >&5
30129
30130   ac_header_preproc=no
30131 fi
30132 rm -f conftest.err conftest.$ac_ext
30133 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
30134 echo "${ECHO_T}$ac_header_preproc" >&6
30135
30136 # So?  What about this header?
30137 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
30138   yes:no: )
30139     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
30140 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
30141     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
30142 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
30143     ac_header_preproc=yes
30144     ;;
30145   no:yes:* )
30146     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
30147 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
30148     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
30149 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
30150     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
30151 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
30152     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
30153 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
30154     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
30155 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
30156     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
30157 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
30158     (
30159       cat <<\_ASBOX
30160 ## --------------------------------------------- ##
30161 ## Report this to <http://www.openldap.org/its/> ##
30162 ## --------------------------------------------- ##
30163 _ASBOX
30164     ) |
30165       sed "s/^/$as_me: WARNING:     /" >&2
30166     ;;
30167 esac
30168 echo "$as_me:$LINENO: checking for $ac_header" >&5
30169 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
30170 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30171   echo $ECHO_N "(cached) $ECHO_C" >&6
30172 else
30173   eval "$as_ac_Header=\$ac_header_preproc"
30174 fi
30175 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
30176 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
30177
30178 fi
30179 if test `eval echo '${'$as_ac_Header'}'` = yes; then
30180   cat >>confdefs.h <<_ACEOF
30181 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
30182 _ACEOF
30183
30184 else
30185
30186                 { { echo "$as_me:$LINENO: error: could not locate SQL headers" >&5
30187 echo "$as_me: error: could not locate SQL headers" >&2;}
30188    { (exit 1); exit 1; }; }
30189
30190 fi
30191
30192 done
30193
30194
30195         sql_LIBS="$LIBS"
30196         LIBS="$LTHREAD_LIBS"
30197
30198         if test $ol_with_odbc = auto ; then
30199                 ol_with_odbc="iodbc unixodbc odbc32"
30200         fi
30201
30202         for odbc in $ol_with_odbc ; do
30203                 if test $ol_link_sql = no ; then
30204                         case $odbc in
30205                         iodbc)
30206                                 echo "$as_me:$LINENO: checking for SQLDriverConnect in -liodbc" >&5
30207 echo $ECHO_N "checking for SQLDriverConnect in -liodbc... $ECHO_C" >&6
30208 if test "${ac_cv_lib_iodbc_SQLDriverConnect+set}" = set; then
30209   echo $ECHO_N "(cached) $ECHO_C" >&6
30210 else
30211   ac_check_lib_save_LIBS=$LIBS
30212 LIBS="-liodbc  $LIBS"
30213 cat >conftest.$ac_ext <<_ACEOF
30214 /* confdefs.h.  */
30215 _ACEOF
30216 cat confdefs.h >>conftest.$ac_ext
30217 cat >>conftest.$ac_ext <<_ACEOF
30218 /* end confdefs.h.  */
30219
30220 /* Override any gcc2 internal prototype to avoid an error.  */
30221 #ifdef __cplusplus
30222 extern "C"
30223 #endif
30224 /* We use char because int might match the return type of a gcc2
30225    builtin and then its argument prototype would still apply.  */
30226 char SQLDriverConnect ();
30227 int
30228 main ()
30229 {
30230 SQLDriverConnect ();
30231   ;
30232   return 0;
30233 }
30234 _ACEOF
30235 rm -f conftest.$ac_objext conftest$ac_exeext
30236 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30237   (eval $ac_link) 2>conftest.er1
30238   ac_status=$?
30239   grep -v '^ *+' conftest.er1 >conftest.err
30240   rm -f conftest.er1
30241   cat conftest.err >&5
30242   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30243   (exit $ac_status); } &&
30244          { ac_try='test -z "$ac_c_werror_flag"
30245                          || test ! -s conftest.err'
30246   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30247   (eval $ac_try) 2>&5
30248   ac_status=$?
30249   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30250   (exit $ac_status); }; } &&
30251          { ac_try='test -s conftest$ac_exeext'
30252   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30253   (eval $ac_try) 2>&5
30254   ac_status=$?
30255   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30256   (exit $ac_status); }; }; then
30257   ac_cv_lib_iodbc_SQLDriverConnect=yes
30258 else
30259   echo "$as_me: failed program was:" >&5
30260 sed 's/^/| /' conftest.$ac_ext >&5
30261
30262 ac_cv_lib_iodbc_SQLDriverConnect=no
30263 fi
30264 rm -f conftest.err conftest.$ac_objext \
30265       conftest$ac_exeext conftest.$ac_ext
30266 LIBS=$ac_check_lib_save_LIBS
30267 fi
30268 echo "$as_me:$LINENO: result: $ac_cv_lib_iodbc_SQLDriverConnect" >&5
30269 echo "${ECHO_T}$ac_cv_lib_iodbc_SQLDriverConnect" >&6
30270 if test $ac_cv_lib_iodbc_SQLDriverConnect = yes; then
30271   have_iodbc=yes
30272 else
30273   have_iodbc=no
30274 fi
30275
30276                                 if test $have_iodbc = yes ; then
30277                                         ol_link_sql="-liodbc"
30278                                 fi
30279                                 ;;
30280
30281                         unixodbc)
30282                                 echo "$as_me:$LINENO: checking for SQLDriverConnect in -lodbc" >&5
30283 echo $ECHO_N "checking for SQLDriverConnect in -lodbc... $ECHO_C" >&6
30284 if test "${ac_cv_lib_odbc_SQLDriverConnect+set}" = set; then
30285   echo $ECHO_N "(cached) $ECHO_C" >&6
30286 else
30287   ac_check_lib_save_LIBS=$LIBS
30288 LIBS="-lodbc  $LIBS"
30289 cat >conftest.$ac_ext <<_ACEOF
30290 /* confdefs.h.  */
30291 _ACEOF
30292 cat confdefs.h >>conftest.$ac_ext
30293 cat >>conftest.$ac_ext <<_ACEOF
30294 /* end confdefs.h.  */
30295
30296 /* Override any gcc2 internal prototype to avoid an error.  */
30297 #ifdef __cplusplus
30298 extern "C"
30299 #endif
30300 /* We use char because int might match the return type of a gcc2
30301    builtin and then its argument prototype would still apply.  */
30302 char SQLDriverConnect ();
30303 int
30304 main ()
30305 {
30306 SQLDriverConnect ();
30307   ;
30308   return 0;
30309 }
30310 _ACEOF
30311 rm -f conftest.$ac_objext conftest$ac_exeext
30312 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30313   (eval $ac_link) 2>conftest.er1
30314   ac_status=$?
30315   grep -v '^ *+' conftest.er1 >conftest.err
30316   rm -f conftest.er1
30317   cat conftest.err >&5
30318   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30319   (exit $ac_status); } &&
30320          { ac_try='test -z "$ac_c_werror_flag"
30321                          || test ! -s conftest.err'
30322   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30323   (eval $ac_try) 2>&5
30324   ac_status=$?
30325   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30326   (exit $ac_status); }; } &&
30327          { ac_try='test -s conftest$ac_exeext'
30328   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30329   (eval $ac_try) 2>&5
30330   ac_status=$?
30331   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30332   (exit $ac_status); }; }; then
30333   ac_cv_lib_odbc_SQLDriverConnect=yes
30334 else
30335   echo "$as_me: failed program was:" >&5
30336 sed 's/^/| /' conftest.$ac_ext >&5
30337
30338 ac_cv_lib_odbc_SQLDriverConnect=no
30339 fi
30340 rm -f conftest.err conftest.$ac_objext \
30341       conftest$ac_exeext conftest.$ac_ext
30342 LIBS=$ac_check_lib_save_LIBS
30343 fi
30344 echo "$as_me:$LINENO: result: $ac_cv_lib_odbc_SQLDriverConnect" >&5
30345 echo "${ECHO_T}$ac_cv_lib_odbc_SQLDriverConnect" >&6
30346 if test $ac_cv_lib_odbc_SQLDriverConnect = yes; then
30347   have_odbc=yes
30348 else
30349   have_odbc=no
30350 fi
30351
30352                                 if test $have_odbc = yes ; then
30353                                         ol_link_sql="-lodbc"
30354                                 fi
30355                                 ;;
30356
30357                         odbc32)
30358                                 echo "$as_me:$LINENO: checking for SQLDriverConnect in -lodbc32" >&5
30359 echo $ECHO_N "checking for SQLDriverConnect in -lodbc32... $ECHO_C" >&6
30360 if test "${ac_cv_lib_odbc32_SQLDriverConnect+set}" = set; then
30361   echo $ECHO_N "(cached) $ECHO_C" >&6
30362 else
30363   ac_check_lib_save_LIBS=$LIBS
30364 LIBS="-lodbc32  $LIBS"
30365 cat >conftest.$ac_ext <<_ACEOF
30366 /* confdefs.h.  */
30367 _ACEOF
30368 cat confdefs.h >>conftest.$ac_ext
30369 cat >>conftest.$ac_ext <<_ACEOF
30370 /* end confdefs.h.  */
30371
30372 /* Override any gcc2 internal prototype to avoid an error.  */
30373 #ifdef __cplusplus
30374 extern "C"
30375 #endif
30376 /* We use char because int might match the return type of a gcc2
30377    builtin and then its argument prototype would still apply.  */
30378 char SQLDriverConnect ();
30379 int
30380 main ()
30381 {
30382 SQLDriverConnect ();
30383   ;
30384   return 0;
30385 }
30386 _ACEOF
30387 rm -f conftest.$ac_objext conftest$ac_exeext
30388 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30389   (eval $ac_link) 2>conftest.er1
30390   ac_status=$?
30391   grep -v '^ *+' conftest.er1 >conftest.err
30392   rm -f conftest.er1
30393   cat conftest.err >&5
30394   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30395   (exit $ac_status); } &&
30396          { ac_try='test -z "$ac_c_werror_flag"
30397                          || test ! -s conftest.err'
30398   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30399   (eval $ac_try) 2>&5
30400   ac_status=$?
30401   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30402   (exit $ac_status); }; } &&
30403          { ac_try='test -s conftest$ac_exeext'
30404   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30405   (eval $ac_try) 2>&5
30406   ac_status=$?
30407   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30408   (exit $ac_status); }; }; then
30409   ac_cv_lib_odbc32_SQLDriverConnect=yes
30410 else
30411   echo "$as_me: failed program was:" >&5
30412 sed 's/^/| /' conftest.$ac_ext >&5
30413
30414 ac_cv_lib_odbc32_SQLDriverConnect=no
30415 fi
30416 rm -f conftest.err conftest.$ac_objext \
30417       conftest$ac_exeext conftest.$ac_ext
30418 LIBS=$ac_check_lib_save_LIBS
30419 fi
30420 echo "$as_me:$LINENO: result: $ac_cv_lib_odbc32_SQLDriverConnect" >&5
30421 echo "${ECHO_T}$ac_cv_lib_odbc32_SQLDriverConnect" >&6
30422 if test $ac_cv_lib_odbc32_SQLDriverConnect = yes; then
30423   have_odbc32=yes
30424 else
30425   have_odbc32=no
30426 fi
30427
30428                                 if test $have_odbc32 = yes ; then
30429                                         ol_link_sql="-lodbc32"
30430                                 fi
30431                                 ;;
30432
30433                         *)
30434                                 { { echo "$as_me:$LINENO: error: unknown ODBC library" >&5
30435 echo "$as_me: error: unknown ODBC library" >&2;}
30436    { (exit 1); exit 1; }; }
30437                                 ;;
30438                         esac
30439                 fi
30440         done
30441
30442         LIBS="$sql_LIBS"
30443
30444         if test $ol_link_sql != no ; then
30445                 SLAPD_SQL_LIBS="$ol_link_sql"
30446
30447         elif test $ol_enable_sql != auto ; then
30448                 { { echo "$as_me:$LINENO: error: could not locate suitable ODBC library" >&5
30449 echo "$as_me: error: could not locate suitable ODBC library" >&2;}
30450    { (exit 1); exit 1; }; }
30451         fi
30452 fi
30453
30454 ol_link_ndb=no
30455 if test $ol_enable_ndb != no ; then
30456         # Extract the first word of "mysql_config", so it can be a program name with args.
30457 set dummy mysql_config; ac_word=$2
30458 echo "$as_me:$LINENO: checking for $ac_word" >&5
30459 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
30460 if test "${ac_cv_prog_MYSQL+set}" = set; then
30461   echo $ECHO_N "(cached) $ECHO_C" >&6
30462 else
30463   if test -n "$MYSQL"; then
30464   ac_cv_prog_MYSQL="$MYSQL" # Let the user override the test.
30465 else
30466 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30467 for as_dir in $PATH
30468 do
30469   IFS=$as_save_IFS
30470   test -z "$as_dir" && as_dir=.
30471   for ac_exec_ext in '' $ac_executable_extensions; do
30472   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30473     ac_cv_prog_MYSQL="yes"
30474     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
30475     break 2
30476   fi
30477 done
30478 done
30479
30480 fi
30481 fi
30482 MYSQL=$ac_cv_prog_MYSQL
30483 if test -n "$MYSQL"; then
30484   echo "$as_me:$LINENO: result: $MYSQL" >&5
30485 echo "${ECHO_T}$MYSQL" >&6
30486 else
30487   echo "$as_me:$LINENO: result: no" >&5
30488 echo "${ECHO_T}no" >&6
30489 fi
30490
30491         if test "$MYSQL" != yes ; then
30492                 { { echo "$as_me:$LINENO: error: could not locate mysql_config" >&5
30493 echo "$as_me: error: could not locate mysql_config" >&2;}
30494    { (exit 1); exit 1; }; }
30495         fi
30496
30497         SQL_INC=`mysql_config --include`
30498         SLAPD_NDB_INCS="$SQL_INC $SQL_INC/storage/ndb $SQL_INC/storage/ndb/ndbapi"
30499
30500         save_CPPFLAGS="$CPPFLAGS"
30501         CPPFLAGS="$SLAPD_NDB_INCS"
30502         echo "$as_me:$LINENO: checking for NdbApi.hpp" >&5
30503 echo $ECHO_N "checking for NdbApi.hpp... $ECHO_C" >&6
30504         cat >conftest.$ac_ext <<_ACEOF
30505 /* confdefs.h.  */
30506 _ACEOF
30507 cat confdefs.h >>conftest.$ac_ext
30508 cat >>conftest.$ac_ext <<_ACEOF
30509 /* end confdefs.h.  */
30510 #include <NdbApi.hpp>
30511 _ACEOF
30512 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
30513   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
30514   ac_status=$?
30515   grep -v '^ *+' conftest.er1 >conftest.err
30516   rm -f conftest.er1
30517   cat conftest.err >&5
30518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30519   (exit $ac_status); } >/dev/null; then
30520   if test -s conftest.err; then
30521     ac_cpp_err=$ac_c_preproc_warn_flag
30522     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
30523   else
30524     ac_cpp_err=
30525   fi
30526 else
30527   ac_cpp_err=yes
30528 fi
30529 if test -z "$ac_cpp_err"; then
30530   echo "$as_me:$LINENO: result: yes" >&5
30531 echo "${ECHO_T}yes" >&6
30532 else
30533   echo "$as_me: failed program was:" >&5
30534 sed 's/^/| /' conftest.$ac_ext >&5
30535
30536   { { echo "$as_me:$LINENO: error: could not locate NdbApi headers" >&5
30537 echo "$as_me: error: could not locate NdbApi headers" >&2;}
30538    { (exit 1); exit 1; }; }
30539
30540 fi
30541 rm -f conftest.err conftest.$ac_ext
30542         CPPFLAGS="$save_CPPFLAGS"
30543
30544         SQL_LIB=`mysql_config --libs_r`
30545         SLAPD_NDB_LIBS="$SQL_LIB -lndbclient -lstdc++"
30546
30547         save_LDFLAGS="$LDFLAGS"
30548         save_LIBS="$LIBS"
30549         LDFLAGS="$SQL_LIB"
30550
30551 echo "$as_me:$LINENO: checking for ndb_init in -lndbclient" >&5
30552 echo $ECHO_N "checking for ndb_init in -lndbclient... $ECHO_C" >&6
30553 if test "${ac_cv_lib_ndbclient_ndb_init+set}" = set; then
30554   echo $ECHO_N "(cached) $ECHO_C" >&6
30555 else
30556   ac_check_lib_save_LIBS=$LIBS
30557 LIBS="-lndbclient -lstdc++ $LIBS"
30558 cat >conftest.$ac_ext <<_ACEOF
30559 /* confdefs.h.  */
30560 _ACEOF
30561 cat confdefs.h >>conftest.$ac_ext
30562 cat >>conftest.$ac_ext <<_ACEOF
30563 /* end confdefs.h.  */
30564
30565 /* Override any gcc2 internal prototype to avoid an error.  */
30566 #ifdef __cplusplus
30567 extern "C"
30568 #endif
30569 /* We use char because int might match the return type of a gcc2
30570    builtin and then its argument prototype would still apply.  */
30571 char ndb_init ();
30572 int
30573 main ()
30574 {
30575 ndb_init ();
30576   ;
30577   return 0;
30578 }
30579 _ACEOF
30580 rm -f conftest.$ac_objext conftest$ac_exeext
30581 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30582   (eval $ac_link) 2>conftest.er1
30583   ac_status=$?
30584   grep -v '^ *+' conftest.er1 >conftest.err
30585   rm -f conftest.er1
30586   cat conftest.err >&5
30587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30588   (exit $ac_status); } &&
30589          { ac_try='test -z "$ac_c_werror_flag"
30590                          || test ! -s conftest.err'
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); }; } &&
30596          { ac_try='test -s conftest$ac_exeext'
30597   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30598   (eval $ac_try) 2>&5
30599   ac_status=$?
30600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30601   (exit $ac_status); }; }; then
30602   ac_cv_lib_ndbclient_ndb_init=yes
30603 else
30604   echo "$as_me: failed program was:" >&5
30605 sed 's/^/| /' conftest.$ac_ext >&5
30606
30607 ac_cv_lib_ndbclient_ndb_init=no
30608 fi
30609 rm -f conftest.err conftest.$ac_objext \
30610       conftest$ac_exeext conftest.$ac_ext
30611 LIBS=$ac_check_lib_save_LIBS
30612 fi
30613 echo "$as_me:$LINENO: result: $ac_cv_lib_ndbclient_ndb_init" >&5
30614 echo "${ECHO_T}$ac_cv_lib_ndbclient_ndb_init" >&6
30615 if test $ac_cv_lib_ndbclient_ndb_init = yes; then
30616   cat >>confdefs.h <<_ACEOF
30617 #define HAVE_LIBNDBCLIENT 1
30618 _ACEOF
30619
30620   LIBS="-lndbclient $LIBS"
30621
30622 else
30623
30624                 { { echo "$as_me:$LINENO: error: could not locate ndbclient library" >&5
30625 echo "$as_me: error: could not locate ndbclient library" >&2;}
30626    { (exit 1); exit 1; }; }
30627
30628 fi
30629
30630         LIBS="$save_LIBS"
30631         LDFLAGS="$save_LDFLAGS"
30632
30633         if test "$ol_enable_ndb" = yes ; then
30634                 SLAPD_LIBS="$SLAPD_LIBS \$(SLAPD_NDB_LIBS)"
30635         fi
30636 fi
30637
30638 ol_icu=no
30639
30640 for ac_header in unicode/utypes.h
30641 do
30642 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
30643 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30644   echo "$as_me:$LINENO: checking for $ac_header" >&5
30645 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
30646 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30647   echo $ECHO_N "(cached) $ECHO_C" >&6
30648 fi
30649 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
30650 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
30651 else
30652   # Is the header compilable?
30653 echo "$as_me:$LINENO: checking $ac_header usability" >&5
30654 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
30655 cat >conftest.$ac_ext <<_ACEOF
30656 /* confdefs.h.  */
30657 _ACEOF
30658 cat confdefs.h >>conftest.$ac_ext
30659 cat >>conftest.$ac_ext <<_ACEOF
30660 /* end confdefs.h.  */
30661 $ac_includes_default
30662 #include <$ac_header>
30663 _ACEOF
30664 rm -f conftest.$ac_objext
30665 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30666   (eval $ac_compile) 2>conftest.er1
30667   ac_status=$?
30668   grep -v '^ *+' conftest.er1 >conftest.err
30669   rm -f conftest.er1
30670   cat conftest.err >&5
30671   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30672   (exit $ac_status); } &&
30673          { ac_try='test -z "$ac_c_werror_flag"
30674                          || test ! -s conftest.err'
30675   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30676   (eval $ac_try) 2>&5
30677   ac_status=$?
30678   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30679   (exit $ac_status); }; } &&
30680          { ac_try='test -s conftest.$ac_objext'
30681   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30682   (eval $ac_try) 2>&5
30683   ac_status=$?
30684   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30685   (exit $ac_status); }; }; then
30686   ac_header_compiler=yes
30687 else
30688   echo "$as_me: failed program was:" >&5
30689 sed 's/^/| /' conftest.$ac_ext >&5
30690
30691 ac_header_compiler=no
30692 fi
30693 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
30694 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
30695 echo "${ECHO_T}$ac_header_compiler" >&6
30696
30697 # Is the header present?
30698 echo "$as_me:$LINENO: checking $ac_header presence" >&5
30699 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
30700 cat >conftest.$ac_ext <<_ACEOF
30701 /* confdefs.h.  */
30702 _ACEOF
30703 cat confdefs.h >>conftest.$ac_ext
30704 cat >>conftest.$ac_ext <<_ACEOF
30705 /* end confdefs.h.  */
30706 #include <$ac_header>
30707 _ACEOF
30708 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
30709   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
30710   ac_status=$?
30711   grep -v '^ *+' conftest.er1 >conftest.err
30712   rm -f conftest.er1
30713   cat conftest.err >&5
30714   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30715   (exit $ac_status); } >/dev/null; then
30716   if test -s conftest.err; then
30717     ac_cpp_err=$ac_c_preproc_warn_flag
30718     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
30719   else
30720     ac_cpp_err=
30721   fi
30722 else
30723   ac_cpp_err=yes
30724 fi
30725 if test -z "$ac_cpp_err"; then
30726   ac_header_preproc=yes
30727 else
30728   echo "$as_me: failed program was:" >&5
30729 sed 's/^/| /' conftest.$ac_ext >&5
30730
30731   ac_header_preproc=no
30732 fi
30733 rm -f conftest.err conftest.$ac_ext
30734 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
30735 echo "${ECHO_T}$ac_header_preproc" >&6
30736
30737 # So?  What about this header?
30738 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
30739   yes:no: )
30740     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
30741 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
30742     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
30743 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
30744     ac_header_preproc=yes
30745     ;;
30746   no:yes:* )
30747     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
30748 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
30749     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
30750 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
30751     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
30752 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
30753     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
30754 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
30755     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
30756 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
30757     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
30758 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
30759     (
30760       cat <<\_ASBOX
30761 ## --------------------------------------------- ##
30762 ## Report this to <http://www.openldap.org/its/> ##
30763 ## --------------------------------------------- ##
30764 _ASBOX
30765     ) |
30766       sed "s/^/$as_me: WARNING:     /" >&2
30767     ;;
30768 esac
30769 echo "$as_me:$LINENO: checking for $ac_header" >&5
30770 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
30771 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30772   echo $ECHO_N "(cached) $ECHO_C" >&6
30773 else
30774   eval "$as_ac_Header=\$ac_header_preproc"
30775 fi
30776 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
30777 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
30778
30779 fi
30780 if test `eval echo '${'$as_ac_Header'}'` = yes; then
30781   cat >>confdefs.h <<_ACEOF
30782 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
30783 _ACEOF
30784
30785 fi
30786
30787 done
30788
30789 if test $ac_cv_header_unicode_utypes_h = yes ; then
30790                 OL_ICULIBS="-licuuc -licudata"
30791
30792         echo "$as_me:$LINENO: checking for ICU libraries" >&5
30793 echo $ECHO_N "checking for ICU libraries... $ECHO_C" >&6
30794 if test "${ol_cv_lib_icu+set}" = set; then
30795   echo $ECHO_N "(cached) $ECHO_C" >&6
30796 else
30797
30798                 ol_LIBS="$LIBS"
30799                 LIBS="$OL_ICULIBS $LIBS"
30800                 cat >conftest.$ac_ext <<_ACEOF
30801 /* confdefs.h.  */
30802 _ACEOF
30803 cat confdefs.h >>conftest.$ac_ext
30804 cat >>conftest.$ac_ext <<_ACEOF
30805 /* end confdefs.h.  */
30806
30807 #include <unicode/utypes.h>
30808
30809 int
30810 main ()
30811 {
30812
30813 (void) u_errorName(0);
30814
30815   ;
30816   return 0;
30817 }
30818 _ACEOF
30819 rm -f conftest.$ac_objext conftest$ac_exeext
30820 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30821   (eval $ac_link) 2>conftest.er1
30822   ac_status=$?
30823   grep -v '^ *+' conftest.er1 >conftest.err
30824   rm -f conftest.er1
30825   cat conftest.err >&5
30826   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30827   (exit $ac_status); } &&
30828          { ac_try='test -z "$ac_c_werror_flag"
30829                          || test ! -s conftest.err'
30830   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30831   (eval $ac_try) 2>&5
30832   ac_status=$?
30833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30834   (exit $ac_status); }; } &&
30835          { ac_try='test -s conftest$ac_exeext'
30836   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30837   (eval $ac_try) 2>&5
30838   ac_status=$?
30839   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30840   (exit $ac_status); }; }; then
30841   ol_cv_lib_icu=yes
30842 else
30843   echo "$as_me: failed program was:" >&5
30844 sed 's/^/| /' conftest.$ac_ext >&5
30845
30846 ol_cv_lib_icu=no
30847 fi
30848 rm -f conftest.err conftest.$ac_objext \
30849       conftest$ac_exeext conftest.$ac_ext
30850                 LIBS="$ol_LIBS"
30851
30852 fi
30853 echo "$as_me:$LINENO: result: $ol_cv_lib_icu" >&5
30854 echo "${ECHO_T}$ol_cv_lib_icu" >&6
30855
30856         if test $ol_cv_lib_icu != no ; then
30857                 ol_icu="$OL_ICULIBS"
30858
30859 cat >>confdefs.h <<\_ACEOF
30860 #define HAVE_ICU 1
30861 _ACEOF
30862
30863         fi
30864 fi
30865
30866 if test "$ol_icu" = no ; then
30867         { echo "$as_me:$LINENO: WARNING: ICU not available" >&5
30868 echo "$as_me: WARNING: ICU not available" >&2;}
30869 else
30870         ICU_LIBS="$ol_icu"
30871 fi
30872 WITH_SASL=no
30873 ol_link_sasl=no
30874 ol_link_spasswd=no
30875 if test $ol_with_cyrus_sasl != no ; then
30876
30877
30878 for ac_header in sasl/sasl.h sasl.h
30879 do
30880 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
30881 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30882   echo "$as_me:$LINENO: checking for $ac_header" >&5
30883 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
30884 if eval "test \"\${$as_ac_Header+set}\" = set"; then
30885   echo $ECHO_N "(cached) $ECHO_C" >&6
30886 fi
30887 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
30888 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
30889 else
30890   # Is the header compilable?
30891 echo "$as_me:$LINENO: checking $ac_header usability" >&5
30892 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
30893 cat >conftest.$ac_ext <<_ACEOF
30894 /* confdefs.h.  */
30895 _ACEOF
30896 cat confdefs.h >>conftest.$ac_ext
30897 cat >>conftest.$ac_ext <<_ACEOF
30898 /* end confdefs.h.  */
30899 $ac_includes_default
30900 #include <$ac_header>
30901 _ACEOF
30902 rm -f conftest.$ac_objext
30903 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30904   (eval $ac_compile) 2>conftest.er1
30905   ac_status=$?
30906   grep -v '^ *+' conftest.er1 >conftest.err
30907   rm -f conftest.er1
30908   cat conftest.err >&5
30909   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30910   (exit $ac_status); } &&
30911          { ac_try='test -z "$ac_c_werror_flag"
30912                          || test ! -s conftest.err'
30913   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30914   (eval $ac_try) 2>&5
30915   ac_status=$?
30916   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30917   (exit $ac_status); }; } &&
30918          { ac_try='test -s conftest.$ac_objext'
30919   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30920   (eval $ac_try) 2>&5
30921   ac_status=$?
30922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30923   (exit $ac_status); }; }; then
30924   ac_header_compiler=yes
30925 else
30926   echo "$as_me: failed program was:" >&5
30927 sed 's/^/| /' conftest.$ac_ext >&5
30928
30929 ac_header_compiler=no
30930 fi
30931 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
30932 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
30933 echo "${ECHO_T}$ac_header_compiler" >&6
30934
30935 # Is the header present?
30936 echo "$as_me:$LINENO: checking $ac_header presence" >&5
30937 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
30938 cat >conftest.$ac_ext <<_ACEOF
30939 /* confdefs.h.  */
30940 _ACEOF
30941 cat confdefs.h >>conftest.$ac_ext
30942 cat >>conftest.$ac_ext <<_ACEOF
30943 /* end confdefs.h.  */
30944 #include <$ac_header>
30945 _ACEOF
30946 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
30947   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
30948   ac_status=$?
30949   grep -v '^ *+' conftest.er1 >conftest.err
30950   rm -f conftest.er1
30951   cat conftest.err >&5
30952   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30953   (exit $ac_status); } >/dev/null; then
30954   if test -s conftest.err; then
30955     ac_cpp_err=$ac_c_preproc_warn_flag
30956     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
30957   else
30958     ac_cpp_err=
30959   fi
30960 else
30961   ac_cpp_err=yes
30962 fi
30963 if test -z "$ac_cpp_err"; then
30964   ac_header_preproc=yes
30965 else
30966   echo "$as_me: failed program was:" >&5
30967 sed 's/^/| /' conftest.$ac_ext >&5
30968
30969   ac_header_preproc=no
30970 fi
30971 rm -f conftest.err conftest.$ac_ext
30972 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
30973 echo "${ECHO_T}$ac_header_preproc" >&6
30974
30975 # So?  What about this header?
30976 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
30977   yes:no: )
30978     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
30979 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
30980     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
30981 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
30982     ac_header_preproc=yes
30983     ;;
30984   no:yes:* )
30985     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
30986 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
30987     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
30988 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
30989     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
30990 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
30991     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
30992 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
30993     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
30994 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
30995     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
30996 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
30997     (
30998       cat <<\_ASBOX
30999 ## --------------------------------------------- ##
31000 ## Report this to <http://www.openldap.org/its/> ##
31001 ## --------------------------------------------- ##
31002 _ASBOX
31003     ) |
31004       sed "s/^/$as_me: WARNING:     /" >&2
31005     ;;
31006 esac
31007 echo "$as_me:$LINENO: checking for $ac_header" >&5
31008 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31009 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31010   echo $ECHO_N "(cached) $ECHO_C" >&6
31011 else
31012   eval "$as_ac_Header=\$ac_header_preproc"
31013 fi
31014 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31015 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31016
31017 fi
31018 if test `eval echo '${'$as_ac_Header'}'` = yes; then
31019   cat >>confdefs.h <<_ACEOF
31020 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
31021 _ACEOF
31022
31023 fi
31024
31025 done
31026
31027
31028         if test $ac_cv_header_sasl_sasl_h = yes ||
31029            test $ac_cv_header_sasl_h = yes; then
31030                 echo "$as_me:$LINENO: checking for sasl_client_init in -lsasl2" >&5
31031 echo $ECHO_N "checking for sasl_client_init in -lsasl2... $ECHO_C" >&6
31032 if test "${ac_cv_lib_sasl2_sasl_client_init+set}" = set; then
31033   echo $ECHO_N "(cached) $ECHO_C" >&6
31034 else
31035   ac_check_lib_save_LIBS=$LIBS
31036 LIBS="-lsasl2  $LIBS"
31037 cat >conftest.$ac_ext <<_ACEOF
31038 /* confdefs.h.  */
31039 _ACEOF
31040 cat confdefs.h >>conftest.$ac_ext
31041 cat >>conftest.$ac_ext <<_ACEOF
31042 /* end confdefs.h.  */
31043
31044 /* Override any gcc2 internal prototype to avoid an error.  */
31045 #ifdef __cplusplus
31046 extern "C"
31047 #endif
31048 /* We use char because int might match the return type of a gcc2
31049    builtin and then its argument prototype would still apply.  */
31050 char sasl_client_init ();
31051 int
31052 main ()
31053 {
31054 sasl_client_init ();
31055   ;
31056   return 0;
31057 }
31058 _ACEOF
31059 rm -f conftest.$ac_objext conftest$ac_exeext
31060 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31061   (eval $ac_link) 2>conftest.er1
31062   ac_status=$?
31063   grep -v '^ *+' conftest.er1 >conftest.err
31064   rm -f conftest.er1
31065   cat conftest.err >&5
31066   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31067   (exit $ac_status); } &&
31068          { ac_try='test -z "$ac_c_werror_flag"
31069                          || test ! -s conftest.err'
31070   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31071   (eval $ac_try) 2>&5
31072   ac_status=$?
31073   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31074   (exit $ac_status); }; } &&
31075          { ac_try='test -s conftest$ac_exeext'
31076   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31077   (eval $ac_try) 2>&5
31078   ac_status=$?
31079   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31080   (exit $ac_status); }; }; then
31081   ac_cv_lib_sasl2_sasl_client_init=yes
31082 else
31083   echo "$as_me: failed program was:" >&5
31084 sed 's/^/| /' conftest.$ac_ext >&5
31085
31086 ac_cv_lib_sasl2_sasl_client_init=no
31087 fi
31088 rm -f conftest.err conftest.$ac_objext \
31089       conftest$ac_exeext conftest.$ac_ext
31090 LIBS=$ac_check_lib_save_LIBS
31091 fi
31092 echo "$as_me:$LINENO: result: $ac_cv_lib_sasl2_sasl_client_init" >&5
31093 echo "${ECHO_T}$ac_cv_lib_sasl2_sasl_client_init" >&6
31094 if test $ac_cv_lib_sasl2_sasl_client_init = yes; then
31095   ol_link_sasl="-lsasl2"
31096 else
31097   echo "$as_me:$LINENO: checking for sasl_client_init in -lsasl" >&5
31098 echo $ECHO_N "checking for sasl_client_init in -lsasl... $ECHO_C" >&6
31099 if test "${ac_cv_lib_sasl_sasl_client_init+set}" = set; then
31100   echo $ECHO_N "(cached) $ECHO_C" >&6
31101 else
31102   ac_check_lib_save_LIBS=$LIBS
31103 LIBS="-lsasl  $LIBS"
31104 cat >conftest.$ac_ext <<_ACEOF
31105 /* confdefs.h.  */
31106 _ACEOF
31107 cat confdefs.h >>conftest.$ac_ext
31108 cat >>conftest.$ac_ext <<_ACEOF
31109 /* end confdefs.h.  */
31110
31111 /* Override any gcc2 internal prototype to avoid an error.  */
31112 #ifdef __cplusplus
31113 extern "C"
31114 #endif
31115 /* We use char because int might match the return type of a gcc2
31116    builtin and then its argument prototype would still apply.  */
31117 char sasl_client_init ();
31118 int
31119 main ()
31120 {
31121 sasl_client_init ();
31122   ;
31123   return 0;
31124 }
31125 _ACEOF
31126 rm -f conftest.$ac_objext conftest$ac_exeext
31127 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31128   (eval $ac_link) 2>conftest.er1
31129   ac_status=$?
31130   grep -v '^ *+' conftest.er1 >conftest.err
31131   rm -f conftest.er1
31132   cat conftest.err >&5
31133   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31134   (exit $ac_status); } &&
31135          { ac_try='test -z "$ac_c_werror_flag"
31136                          || test ! -s conftest.err'
31137   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31138   (eval $ac_try) 2>&5
31139   ac_status=$?
31140   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31141   (exit $ac_status); }; } &&
31142          { ac_try='test -s conftest$ac_exeext'
31143   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31144   (eval $ac_try) 2>&5
31145   ac_status=$?
31146   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31147   (exit $ac_status); }; }; then
31148   ac_cv_lib_sasl_sasl_client_init=yes
31149 else
31150   echo "$as_me: failed program was:" >&5
31151 sed 's/^/| /' conftest.$ac_ext >&5
31152
31153 ac_cv_lib_sasl_sasl_client_init=no
31154 fi
31155 rm -f conftest.err conftest.$ac_objext \
31156       conftest$ac_exeext conftest.$ac_ext
31157 LIBS=$ac_check_lib_save_LIBS
31158 fi
31159 echo "$as_me:$LINENO: result: $ac_cv_lib_sasl_sasl_client_init" >&5
31160 echo "${ECHO_T}$ac_cv_lib_sasl_sasl_client_init" >&6
31161 if test $ac_cv_lib_sasl_sasl_client_init = yes; then
31162   ol_link_sasl="-lsasl"
31163 fi
31164
31165 fi
31166
31167         fi
31168
31169         if test $ol_link_sasl = no ; then
31170                 if test $ol_with_cyrus_sasl != auto ; then
31171                         { { echo "$as_me:$LINENO: error: Could not locate Cyrus SASL" >&5
31172 echo "$as_me: error: Could not locate Cyrus SASL" >&2;}
31173    { (exit 1); exit 1; }; }
31174                 else
31175                         { echo "$as_me:$LINENO: WARNING: Could not locate Cyrus SASL" >&5
31176 echo "$as_me: WARNING: Could not locate Cyrus SASL" >&2;}
31177                         { echo "$as_me:$LINENO: WARNING: SASL authentication not supported!" >&5
31178 echo "$as_me: WARNING: SASL authentication not supported!" >&2;}
31179                         if test $ol_link_tls = no ; then
31180                                 { echo "$as_me:$LINENO: WARNING: Strong authentication not supported!" >&5
31181 echo "$as_me: WARNING: Strong authentication not supported!" >&2;}
31182                         fi
31183                 fi
31184         else
31185                 echo "$as_me:$LINENO: checking Cyrus SASL library version" >&5
31186 echo $ECHO_N "checking Cyrus SASL library version... $ECHO_C" >&6
31187 if test "${ol_cv_sasl_compat+set}" = set; then
31188   echo $ECHO_N "(cached) $ECHO_C" >&6
31189 else
31190
31191         cat >conftest.$ac_ext <<_ACEOF
31192 /* confdefs.h.  */
31193 _ACEOF
31194 cat confdefs.h >>conftest.$ac_ext
31195 cat >>conftest.$ac_ext <<_ACEOF
31196 /* end confdefs.h.  */
31197
31198 #ifdef HAVE_SASL_SASL_H
31199 #include <sasl/sasl.h>
31200 #else
31201 #include <sasl.h>
31202 #endif
31203
31204 /* Require 2.1.15+ */
31205 #if SASL_VERSION_MAJOR == 2  && SASL_VERSION_MINOR > 1
31206         char *__sasl_compat = "2.2+ or better okay (we guess)";
31207 #elif SASL_VERSION_MAJOR == 2  && SASL_VERSION_MINOR == 1 \
31208         && SASL_VERSION_STEP >=15
31209         char *__sasl_compat = "2.1.15+ or better okay";
31210 #endif
31211
31212 _ACEOF
31213 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
31214   $EGREP "__sasl_compat" >/dev/null 2>&1; then
31215   ol_cv_sasl_compat=yes
31216 else
31217   ol_cv_sasl_compat=no
31218 fi
31219 rm -f conftest*
31220
31221 fi
31222 echo "$as_me:$LINENO: result: $ol_cv_sasl_compat" >&5
31223 echo "${ECHO_T}$ol_cv_sasl_compat" >&6
31224
31225                 if test $ol_cv_sasl_compat = no ; then
31226                         ol_link_sasl=no
31227                         { { echo "$as_me:$LINENO: error: Cyrus SASL library located but is incompatible" >&5
31228 echo "$as_me: error: Cyrus SASL library located but is incompatible" >&2;}
31229    { (exit 1); exit 1; }; }
31230                 fi
31231
31232
31233 cat >>confdefs.h <<\_ACEOF
31234 #define HAVE_CYRUS_SASL 1
31235 _ACEOF
31236
31237                 SASL_LIBS="$ol_link_sasl"
31238                 if test $ol_enable_spasswd != no ; then
31239                         ol_link_spasswd=yes
31240                 fi
31241
31242                 ac_save_LIBS="$LIBS"
31243                 LIBS="$LIBS $ol_link_sasl"
31244                 echo "$as_me:$LINENO: checking for sasl_version" >&5
31245 echo $ECHO_N "checking for sasl_version... $ECHO_C" >&6
31246 if test "${ac_cv_func_sasl_version+set}" = set; then
31247   echo $ECHO_N "(cached) $ECHO_C" >&6
31248 else
31249   cat >conftest.$ac_ext <<_ACEOF
31250 /* confdefs.h.  */
31251 _ACEOF
31252 cat confdefs.h >>conftest.$ac_ext
31253 cat >>conftest.$ac_ext <<_ACEOF
31254 /* end confdefs.h.  */
31255 /* Define sasl_version to an innocuous variant, in case <limits.h> declares sasl_version.
31256    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
31257 #define sasl_version innocuous_sasl_version
31258
31259 /* System header to define __stub macros and hopefully few prototypes,
31260     which can conflict with char sasl_version (); below.
31261     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31262     <limits.h> exists even on freestanding compilers.  */
31263
31264 #ifdef __STDC__
31265 # include <limits.h>
31266 #else
31267 # include <assert.h>
31268 #endif
31269
31270 #undef sasl_version
31271
31272 /* Override any gcc2 internal prototype to avoid an error.  */
31273 #ifdef __cplusplus
31274 extern "C"
31275 {
31276 #endif
31277 /* We use char because int might match the return type of a gcc2
31278    builtin and then its argument prototype would still apply.  */
31279 char sasl_version ();
31280 /* The GNU C library defines this for functions which it implements
31281     to always fail with ENOSYS.  Some functions are actually named
31282     something starting with __ and the normal name is an alias.  */
31283 #if defined (__stub_sasl_version) || defined (__stub___sasl_version)
31284 choke me
31285 #else
31286 char (*f) () = sasl_version;
31287 #endif
31288 #ifdef __cplusplus
31289 }
31290 #endif
31291
31292 int
31293 main ()
31294 {
31295 return f != sasl_version;
31296   ;
31297   return 0;
31298 }
31299 _ACEOF
31300 rm -f conftest.$ac_objext conftest$ac_exeext
31301 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31302   (eval $ac_link) 2>conftest.er1
31303   ac_status=$?
31304   grep -v '^ *+' conftest.er1 >conftest.err
31305   rm -f conftest.er1
31306   cat conftest.err >&5
31307   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31308   (exit $ac_status); } &&
31309          { ac_try='test -z "$ac_c_werror_flag"
31310                          || test ! -s conftest.err'
31311   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31312   (eval $ac_try) 2>&5
31313   ac_status=$?
31314   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31315   (exit $ac_status); }; } &&
31316          { ac_try='test -s conftest$ac_exeext'
31317   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31318   (eval $ac_try) 2>&5
31319   ac_status=$?
31320   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31321   (exit $ac_status); }; }; then
31322   ac_cv_func_sasl_version=yes
31323 else
31324   echo "$as_me: failed program was:" >&5
31325 sed 's/^/| /' conftest.$ac_ext >&5
31326
31327 ac_cv_func_sasl_version=no
31328 fi
31329 rm -f conftest.err conftest.$ac_objext \
31330       conftest$ac_exeext conftest.$ac_ext
31331 fi
31332 echo "$as_me:$LINENO: result: $ac_cv_func_sasl_version" >&5
31333 echo "${ECHO_T}$ac_cv_func_sasl_version" >&6
31334 if test $ac_cv_func_sasl_version = yes; then
31335
31336 cat >>confdefs.h <<\_ACEOF
31337 #define HAVE_SASL_VERSION 1
31338 _ACEOF
31339
31340 fi
31341
31342                 LIBS="$ac_save_LIBS"
31343
31344                 WITH_SASL=yes
31345         fi
31346
31347 else
31348         { echo "$as_me:$LINENO: WARNING: SASL authentication not supported!" >&5
31349 echo "$as_me: WARNING: SASL authentication not supported!" >&2;}
31350         if test $ol_link_tls = no ; then
31351                 { echo "$as_me:$LINENO: WARNING: Strong authentication not supported!" >&5
31352 echo "$as_me: WARNING: Strong authentication not supported!" >&2;}
31353         fi
31354 fi
31355
31356 if test $cross_compiling != yes && test "$ac_cv_mingw32" != yes ; then
31357         dev=no
31358         if test -r /dev/urandom ; then
31359                 dev="/dev/urandom";
31360         elif test -r /idev/urandom ; then
31361                 dev="/idev/urandom";
31362         elif test -r /dev/srandom ; then
31363                 dev="/dev/srandom";
31364         elif test -r /dev/random ; then
31365                 dev="/dev/random";
31366         elif test -r /idev/random ; then
31367                 dev="/idev/random";
31368         fi
31369
31370         if test $dev != no ; then
31371
31372 cat >>confdefs.h <<_ACEOF
31373 #define URANDOM_DEVICE "$dev"
31374 _ACEOF
31375
31376         fi
31377 fi
31378
31379 ol_link_fetch=no
31380 if test $ol_with_fetch != no ; then
31381         ol_LIBS=$LIBS
31382 LIBS="-lfetch -lcom_err $LIBS"
31383 echo "$as_me:$LINENO: checking fetch(3) library" >&5
31384 echo $ECHO_N "checking fetch(3) library... $ECHO_C" >&6
31385 if test "${ol_cv_lib_fetch+set}" = set; then
31386   echo $ECHO_N "(cached) $ECHO_C" >&6
31387 else
31388
31389         cat >conftest.$ac_ext <<_ACEOF
31390 /* confdefs.h.  */
31391 _ACEOF
31392 cat confdefs.h >>conftest.$ac_ext
31393 cat >>conftest.$ac_ext <<_ACEOF
31394 /* end confdefs.h.  */
31395
31396 #include <sys/param.h>
31397 #include <stdio.h>
31398 #include <fetch.h>
31399 int
31400 main ()
31401 {
31402 struct url *u = fetchParseURL("file:///");
31403   ;
31404   return 0;
31405 }
31406 _ACEOF
31407 rm -f conftest.$ac_objext conftest$ac_exeext
31408 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31409   (eval $ac_link) 2>conftest.er1
31410   ac_status=$?
31411   grep -v '^ *+' conftest.er1 >conftest.err
31412   rm -f conftest.er1
31413   cat conftest.err >&5
31414   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31415   (exit $ac_status); } &&
31416          { ac_try='test -z "$ac_c_werror_flag"
31417                          || test ! -s conftest.err'
31418   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31419   (eval $ac_try) 2>&5
31420   ac_status=$?
31421   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31422   (exit $ac_status); }; } &&
31423          { ac_try='test -s conftest$ac_exeext'
31424   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31425   (eval $ac_try) 2>&5
31426   ac_status=$?
31427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31428   (exit $ac_status); }; }; then
31429   ol_cv_lib_fetch=yes
31430 else
31431   echo "$as_me: failed program was:" >&5
31432 sed 's/^/| /' conftest.$ac_ext >&5
31433
31434 ol_cv_lib_fetch=no
31435 fi
31436 rm -f conftest.err conftest.$ac_objext \
31437       conftest$ac_exeext conftest.$ac_ext
31438 fi
31439 echo "$as_me:$LINENO: result: $ol_cv_lib_fetch" >&5
31440 echo "${ECHO_T}$ol_cv_lib_fetch" >&6
31441 LIBS=$ol_LIBS
31442 if test $ol_cv_lib_fetch != no ; then
31443         ol_link_fetch="-lfetch -lcom_err"
31444
31445 cat >>confdefs.h <<\_ACEOF
31446 #define HAVE_FETCH 1
31447 _ACEOF
31448
31449 fi
31450
31451
31452         if test $ol_cv_lib_fetch != no ; then
31453                 LUTIL_LIBS="$LUTIL_LIBS $ol_link_fetch"
31454                 ol_link_fetch=freebsd
31455
31456         elif test $ol_with_fetch != auto ; then
31457                 { { echo "$as_me:$LINENO: error: no suitable API for --with-fetch=$ol_with_fetch" >&5
31458 echo "$as_me: error: no suitable API for --with-fetch=$ol_with_fetch" >&2;}
31459    { (exit 1); exit 1; }; }
31460         fi
31461 fi
31462
31463 if test $ol_enable_crypt != no ; then
31464         save_LIBS="$LIBS"
31465         LIBS="$TLS_LIBS $LIBS"
31466
31467         echo "$as_me:$LINENO: checking for crypt" >&5
31468 echo $ECHO_N "checking for crypt... $ECHO_C" >&6
31469 if test "${ac_cv_func_crypt+set}" = set; then
31470   echo $ECHO_N "(cached) $ECHO_C" >&6
31471 else
31472   cat >conftest.$ac_ext <<_ACEOF
31473 /* confdefs.h.  */
31474 _ACEOF
31475 cat confdefs.h >>conftest.$ac_ext
31476 cat >>conftest.$ac_ext <<_ACEOF
31477 /* end confdefs.h.  */
31478 /* Define crypt to an innocuous variant, in case <limits.h> declares crypt.
31479    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
31480 #define crypt innocuous_crypt
31481
31482 /* System header to define __stub macros and hopefully few prototypes,
31483     which can conflict with char crypt (); below.
31484     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31485     <limits.h> exists even on freestanding compilers.  */
31486
31487 #ifdef __STDC__
31488 # include <limits.h>
31489 #else
31490 # include <assert.h>
31491 #endif
31492
31493 #undef crypt
31494
31495 /* Override any gcc2 internal prototype to avoid an error.  */
31496 #ifdef __cplusplus
31497 extern "C"
31498 {
31499 #endif
31500 /* We use char because int might match the return type of a gcc2
31501    builtin and then its argument prototype would still apply.  */
31502 char crypt ();
31503 /* The GNU C library defines this for functions which it implements
31504     to always fail with ENOSYS.  Some functions are actually named
31505     something starting with __ and the normal name is an alias.  */
31506 #if defined (__stub_crypt) || defined (__stub___crypt)
31507 choke me
31508 #else
31509 char (*f) () = crypt;
31510 #endif
31511 #ifdef __cplusplus
31512 }
31513 #endif
31514
31515 int
31516 main ()
31517 {
31518 return f != crypt;
31519   ;
31520   return 0;
31521 }
31522 _ACEOF
31523 rm -f conftest.$ac_objext conftest$ac_exeext
31524 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31525   (eval $ac_link) 2>conftest.er1
31526   ac_status=$?
31527   grep -v '^ *+' conftest.er1 >conftest.err
31528   rm -f conftest.er1
31529   cat conftest.err >&5
31530   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31531   (exit $ac_status); } &&
31532          { ac_try='test -z "$ac_c_werror_flag"
31533                          || test ! -s conftest.err'
31534   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31535   (eval $ac_try) 2>&5
31536   ac_status=$?
31537   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31538   (exit $ac_status); }; } &&
31539          { ac_try='test -s conftest$ac_exeext'
31540   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31541   (eval $ac_try) 2>&5
31542   ac_status=$?
31543   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31544   (exit $ac_status); }; }; then
31545   ac_cv_func_crypt=yes
31546 else
31547   echo "$as_me: failed program was:" >&5
31548 sed 's/^/| /' conftest.$ac_ext >&5
31549
31550 ac_cv_func_crypt=no
31551 fi
31552 rm -f conftest.err conftest.$ac_objext \
31553       conftest$ac_exeext conftest.$ac_ext
31554 fi
31555 echo "$as_me:$LINENO: result: $ac_cv_func_crypt" >&5
31556 echo "${ECHO_T}$ac_cv_func_crypt" >&6
31557 if test $ac_cv_func_crypt = yes; then
31558   have_crypt=yes
31559 else
31560
31561                 LIBS="$save_LIBS"
31562                 echo "$as_me:$LINENO: checking for crypt in -lcrypt" >&5
31563 echo $ECHO_N "checking for crypt in -lcrypt... $ECHO_C" >&6
31564 if test "${ac_cv_lib_crypt_crypt+set}" = set; then
31565   echo $ECHO_N "(cached) $ECHO_C" >&6
31566 else
31567   ac_check_lib_save_LIBS=$LIBS
31568 LIBS="-lcrypt  $LIBS"
31569 cat >conftest.$ac_ext <<_ACEOF
31570 /* confdefs.h.  */
31571 _ACEOF
31572 cat confdefs.h >>conftest.$ac_ext
31573 cat >>conftest.$ac_ext <<_ACEOF
31574 /* end confdefs.h.  */
31575
31576 /* Override any gcc2 internal prototype to avoid an error.  */
31577 #ifdef __cplusplus
31578 extern "C"
31579 #endif
31580 /* We use char because int might match the return type of a gcc2
31581    builtin and then its argument prototype would still apply.  */
31582 char crypt ();
31583 int
31584 main ()
31585 {
31586 crypt ();
31587   ;
31588   return 0;
31589 }
31590 _ACEOF
31591 rm -f conftest.$ac_objext conftest$ac_exeext
31592 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31593   (eval $ac_link) 2>conftest.er1
31594   ac_status=$?
31595   grep -v '^ *+' conftest.er1 >conftest.err
31596   rm -f conftest.er1
31597   cat conftest.err >&5
31598   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31599   (exit $ac_status); } &&
31600          { ac_try='test -z "$ac_c_werror_flag"
31601                          || test ! -s conftest.err'
31602   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31603   (eval $ac_try) 2>&5
31604   ac_status=$?
31605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31606   (exit $ac_status); }; } &&
31607          { ac_try='test -s conftest$ac_exeext'
31608   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31609   (eval $ac_try) 2>&5
31610   ac_status=$?
31611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31612   (exit $ac_status); }; }; then
31613   ac_cv_lib_crypt_crypt=yes
31614 else
31615   echo "$as_me: failed program was:" >&5
31616 sed 's/^/| /' conftest.$ac_ext >&5
31617
31618 ac_cv_lib_crypt_crypt=no
31619 fi
31620 rm -f conftest.err conftest.$ac_objext \
31621       conftest$ac_exeext conftest.$ac_ext
31622 LIBS=$ac_check_lib_save_LIBS
31623 fi
31624 echo "$as_me:$LINENO: result: $ac_cv_lib_crypt_crypt" >&5
31625 echo "${ECHO_T}$ac_cv_lib_crypt_crypt" >&6
31626 if test $ac_cv_lib_crypt_crypt = yes; then
31627   LUTIL_LIBS="$LUTIL_LIBS -lcrypt"
31628                         have_crypt=yes
31629 else
31630   have_crypt=no
31631 fi
31632
31633 fi
31634
31635
31636         LIBS="$save_LIBS"
31637
31638         if test $have_crypt = yes ; then
31639
31640 cat >>confdefs.h <<\_ACEOF
31641 #define HAVE_CRYPT 1
31642 _ACEOF
31643
31644         else
31645                 { echo "$as_me:$LINENO: WARNING: could not find crypt" >&5
31646 echo "$as_me: WARNING: could not find crypt" >&2;}
31647                 if test $ol_enable_crypt = yes ; then
31648                         { { echo "$as_me:$LINENO: error: could not find crypt, select appropriate options or disable" >&5
31649 echo "$as_me: error: could not find crypt, select appropriate options or disable" >&2;}
31650    { (exit 1); exit 1; }; }
31651                 fi
31652
31653                 { echo "$as_me:$LINENO: WARNING: disabling crypt support" >&5
31654 echo "$as_me: WARNING: disabling crypt support" >&2;}
31655                 ol_enable_crypt=no
31656         fi
31657 fi
31658
31659 if test $ol_enable_proctitle != no ; then
31660         echo "$as_me:$LINENO: checking for setproctitle" >&5
31661 echo $ECHO_N "checking for setproctitle... $ECHO_C" >&6
31662 if test "${ac_cv_func_setproctitle+set}" = set; then
31663   echo $ECHO_N "(cached) $ECHO_C" >&6
31664 else
31665   cat >conftest.$ac_ext <<_ACEOF
31666 /* confdefs.h.  */
31667 _ACEOF
31668 cat confdefs.h >>conftest.$ac_ext
31669 cat >>conftest.$ac_ext <<_ACEOF
31670 /* end confdefs.h.  */
31671 /* Define setproctitle to an innocuous variant, in case <limits.h> declares setproctitle.
31672    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
31673 #define setproctitle innocuous_setproctitle
31674
31675 /* System header to define __stub macros and hopefully few prototypes,
31676     which can conflict with char setproctitle (); below.
31677     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31678     <limits.h> exists even on freestanding compilers.  */
31679
31680 #ifdef __STDC__
31681 # include <limits.h>
31682 #else
31683 # include <assert.h>
31684 #endif
31685
31686 #undef setproctitle
31687
31688 /* Override any gcc2 internal prototype to avoid an error.  */
31689 #ifdef __cplusplus
31690 extern "C"
31691 {
31692 #endif
31693 /* We use char because int might match the return type of a gcc2
31694    builtin and then its argument prototype would still apply.  */
31695 char setproctitle ();
31696 /* The GNU C library defines this for functions which it implements
31697     to always fail with ENOSYS.  Some functions are actually named
31698     something starting with __ and the normal name is an alias.  */
31699 #if defined (__stub_setproctitle) || defined (__stub___setproctitle)
31700 choke me
31701 #else
31702 char (*f) () = setproctitle;
31703 #endif
31704 #ifdef __cplusplus
31705 }
31706 #endif
31707
31708 int
31709 main ()
31710 {
31711 return f != setproctitle;
31712   ;
31713   return 0;
31714 }
31715 _ACEOF
31716 rm -f conftest.$ac_objext conftest$ac_exeext
31717 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31718   (eval $ac_link) 2>conftest.er1
31719   ac_status=$?
31720   grep -v '^ *+' conftest.er1 >conftest.err
31721   rm -f conftest.er1
31722   cat conftest.err >&5
31723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31724   (exit $ac_status); } &&
31725          { ac_try='test -z "$ac_c_werror_flag"
31726                          || test ! -s conftest.err'
31727   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31728   (eval $ac_try) 2>&5
31729   ac_status=$?
31730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31731   (exit $ac_status); }; } &&
31732          { ac_try='test -s conftest$ac_exeext'
31733   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31734   (eval $ac_try) 2>&5
31735   ac_status=$?
31736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31737   (exit $ac_status); }; }; then
31738   ac_cv_func_setproctitle=yes
31739 else
31740   echo "$as_me: failed program was:" >&5
31741 sed 's/^/| /' conftest.$ac_ext >&5
31742
31743 ac_cv_func_setproctitle=no
31744 fi
31745 rm -f conftest.err conftest.$ac_objext \
31746       conftest$ac_exeext conftest.$ac_ext
31747 fi
31748 echo "$as_me:$LINENO: result: $ac_cv_func_setproctitle" >&5
31749 echo "${ECHO_T}$ac_cv_func_setproctitle" >&6
31750 if test $ac_cv_func_setproctitle = yes; then
31751   have_setproctitle=yes
31752 else
31753
31754                 echo "$as_me:$LINENO: checking for setproctitle in -lutil" >&5
31755 echo $ECHO_N "checking for setproctitle in -lutil... $ECHO_C" >&6
31756 if test "${ac_cv_lib_util_setproctitle+set}" = set; then
31757   echo $ECHO_N "(cached) $ECHO_C" >&6
31758 else
31759   ac_check_lib_save_LIBS=$LIBS
31760 LIBS="-lutil  $LIBS"
31761 cat >conftest.$ac_ext <<_ACEOF
31762 /* confdefs.h.  */
31763 _ACEOF
31764 cat confdefs.h >>conftest.$ac_ext
31765 cat >>conftest.$ac_ext <<_ACEOF
31766 /* end confdefs.h.  */
31767
31768 /* Override any gcc2 internal prototype to avoid an error.  */
31769 #ifdef __cplusplus
31770 extern "C"
31771 #endif
31772 /* We use char because int might match the return type of a gcc2
31773    builtin and then its argument prototype would still apply.  */
31774 char setproctitle ();
31775 int
31776 main ()
31777 {
31778 setproctitle ();
31779   ;
31780   return 0;
31781 }
31782 _ACEOF
31783 rm -f conftest.$ac_objext conftest$ac_exeext
31784 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31785   (eval $ac_link) 2>conftest.er1
31786   ac_status=$?
31787   grep -v '^ *+' conftest.er1 >conftest.err
31788   rm -f conftest.er1
31789   cat conftest.err >&5
31790   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31791   (exit $ac_status); } &&
31792          { ac_try='test -z "$ac_c_werror_flag"
31793                          || test ! -s conftest.err'
31794   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31795   (eval $ac_try) 2>&5
31796   ac_status=$?
31797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31798   (exit $ac_status); }; } &&
31799          { ac_try='test -s conftest$ac_exeext'
31800   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31801   (eval $ac_try) 2>&5
31802   ac_status=$?
31803   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31804   (exit $ac_status); }; }; then
31805   ac_cv_lib_util_setproctitle=yes
31806 else
31807   echo "$as_me: failed program was:" >&5
31808 sed 's/^/| /' conftest.$ac_ext >&5
31809
31810 ac_cv_lib_util_setproctitle=no
31811 fi
31812 rm -f conftest.err conftest.$ac_objext \
31813       conftest$ac_exeext conftest.$ac_ext
31814 LIBS=$ac_check_lib_save_LIBS
31815 fi
31816 echo "$as_me:$LINENO: result: $ac_cv_lib_util_setproctitle" >&5
31817 echo "${ECHO_T}$ac_cv_lib_util_setproctitle" >&6
31818 if test $ac_cv_lib_util_setproctitle = yes; then
31819   have_setproctitle=yes
31820                         LUTIL_LIBS="$LUTIL_LIBS -lutil"
31821 else
31822   have_setproctitle=no
31823                         case $LIBOBJS in
31824     "setproctitle.$ac_objext"   | \
31825   *" setproctitle.$ac_objext"   | \
31826     "setproctitle.$ac_objext "* | \
31827   *" setproctitle.$ac_objext "* ) ;;
31828   *) LIBOBJS="$LIBOBJS setproctitle.$ac_objext" ;;
31829 esac
31830
31831                         LIBSRCS="$LIBSRCS setproctitle.c"
31832 fi
31833
31834 fi
31835
31836
31837         if test $have_setproctitle = yes ; then
31838
31839 cat >>confdefs.h <<\_ACEOF
31840 #define HAVE_SETPROCTITLE 1
31841 _ACEOF
31842
31843         fi
31844 fi
31845
31846 if test $ol_enable_slp != no ; then
31847
31848 for ac_header in slp.h
31849 do
31850 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
31851 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31852   echo "$as_me:$LINENO: checking for $ac_header" >&5
31853 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31854 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31855   echo $ECHO_N "(cached) $ECHO_C" >&6
31856 fi
31857 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31858 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31859 else
31860   # Is the header compilable?
31861 echo "$as_me:$LINENO: checking $ac_header usability" >&5
31862 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
31863 cat >conftest.$ac_ext <<_ACEOF
31864 /* confdefs.h.  */
31865 _ACEOF
31866 cat confdefs.h >>conftest.$ac_ext
31867 cat >>conftest.$ac_ext <<_ACEOF
31868 /* end confdefs.h.  */
31869 $ac_includes_default
31870 #include <$ac_header>
31871 _ACEOF
31872 rm -f conftest.$ac_objext
31873 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31874   (eval $ac_compile) 2>conftest.er1
31875   ac_status=$?
31876   grep -v '^ *+' conftest.er1 >conftest.err
31877   rm -f conftest.er1
31878   cat conftest.err >&5
31879   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31880   (exit $ac_status); } &&
31881          { ac_try='test -z "$ac_c_werror_flag"
31882                          || test ! -s conftest.err'
31883   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31884   (eval $ac_try) 2>&5
31885   ac_status=$?
31886   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31887   (exit $ac_status); }; } &&
31888          { ac_try='test -s conftest.$ac_objext'
31889   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31890   (eval $ac_try) 2>&5
31891   ac_status=$?
31892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31893   (exit $ac_status); }; }; then
31894   ac_header_compiler=yes
31895 else
31896   echo "$as_me: failed program was:" >&5
31897 sed 's/^/| /' conftest.$ac_ext >&5
31898
31899 ac_header_compiler=no
31900 fi
31901 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
31902 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
31903 echo "${ECHO_T}$ac_header_compiler" >&6
31904
31905 # Is the header present?
31906 echo "$as_me:$LINENO: checking $ac_header presence" >&5
31907 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
31908 cat >conftest.$ac_ext <<_ACEOF
31909 /* confdefs.h.  */
31910 _ACEOF
31911 cat confdefs.h >>conftest.$ac_ext
31912 cat >>conftest.$ac_ext <<_ACEOF
31913 /* end confdefs.h.  */
31914 #include <$ac_header>
31915 _ACEOF
31916 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
31917   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
31918   ac_status=$?
31919   grep -v '^ *+' conftest.er1 >conftest.err
31920   rm -f conftest.er1
31921   cat conftest.err >&5
31922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31923   (exit $ac_status); } >/dev/null; then
31924   if test -s conftest.err; then
31925     ac_cpp_err=$ac_c_preproc_warn_flag
31926     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
31927   else
31928     ac_cpp_err=
31929   fi
31930 else
31931   ac_cpp_err=yes
31932 fi
31933 if test -z "$ac_cpp_err"; then
31934   ac_header_preproc=yes
31935 else
31936   echo "$as_me: failed program was:" >&5
31937 sed 's/^/| /' conftest.$ac_ext >&5
31938
31939   ac_header_preproc=no
31940 fi
31941 rm -f conftest.err conftest.$ac_ext
31942 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
31943 echo "${ECHO_T}$ac_header_preproc" >&6
31944
31945 # So?  What about this header?
31946 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
31947   yes:no: )
31948     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
31949 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
31950     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
31951 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
31952     ac_header_preproc=yes
31953     ;;
31954   no:yes:* )
31955     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
31956 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
31957     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
31958 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
31959     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
31960 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
31961     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
31962 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
31963     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
31964 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
31965     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
31966 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
31967     (
31968       cat <<\_ASBOX
31969 ## --------------------------------------------- ##
31970 ## Report this to <http://www.openldap.org/its/> ##
31971 ## --------------------------------------------- ##
31972 _ASBOX
31973     ) |
31974       sed "s/^/$as_me: WARNING:     /" >&2
31975     ;;
31976 esac
31977 echo "$as_me:$LINENO: checking for $ac_header" >&5
31978 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
31979 if eval "test \"\${$as_ac_Header+set}\" = set"; then
31980   echo $ECHO_N "(cached) $ECHO_C" >&6
31981 else
31982   eval "$as_ac_Header=\$ac_header_preproc"
31983 fi
31984 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
31985 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
31986
31987 fi
31988 if test `eval echo '${'$as_ac_Header'}'` = yes; then
31989   cat >>confdefs.h <<_ACEOF
31990 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
31991 _ACEOF
31992
31993 fi
31994
31995 done
31996
31997
31998         if test $ac_cv_header_slp_h = yes ; then
31999                 echo "$as_me:$LINENO: checking for SLPOpen in -lslp" >&5
32000 echo $ECHO_N "checking for SLPOpen in -lslp... $ECHO_C" >&6
32001 if test "${ac_cv_lib_slp_SLPOpen+set}" = set; then
32002   echo $ECHO_N "(cached) $ECHO_C" >&6
32003 else
32004   ac_check_lib_save_LIBS=$LIBS
32005 LIBS="-lslp  $LIBS"
32006 cat >conftest.$ac_ext <<_ACEOF
32007 /* confdefs.h.  */
32008 _ACEOF
32009 cat confdefs.h >>conftest.$ac_ext
32010 cat >>conftest.$ac_ext <<_ACEOF
32011 /* end confdefs.h.  */
32012
32013 /* Override any gcc2 internal prototype to avoid an error.  */
32014 #ifdef __cplusplus
32015 extern "C"
32016 #endif
32017 /* We use char because int might match the return type of a gcc2
32018    builtin and then its argument prototype would still apply.  */
32019 char SLPOpen ();
32020 int
32021 main ()
32022 {
32023 SLPOpen ();
32024   ;
32025   return 0;
32026 }
32027 _ACEOF
32028 rm -f conftest.$ac_objext conftest$ac_exeext
32029 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32030   (eval $ac_link) 2>conftest.er1
32031   ac_status=$?
32032   grep -v '^ *+' conftest.er1 >conftest.err
32033   rm -f conftest.er1
32034   cat conftest.err >&5
32035   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32036   (exit $ac_status); } &&
32037          { ac_try='test -z "$ac_c_werror_flag"
32038                          || test ! -s conftest.err'
32039   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32040   (eval $ac_try) 2>&5
32041   ac_status=$?
32042   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32043   (exit $ac_status); }; } &&
32044          { ac_try='test -s conftest$ac_exeext'
32045   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32046   (eval $ac_try) 2>&5
32047   ac_status=$?
32048   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32049   (exit $ac_status); }; }; then
32050   ac_cv_lib_slp_SLPOpen=yes
32051 else
32052   echo "$as_me: failed program was:" >&5
32053 sed 's/^/| /' conftest.$ac_ext >&5
32054
32055 ac_cv_lib_slp_SLPOpen=no
32056 fi
32057 rm -f conftest.err conftest.$ac_objext \
32058       conftest$ac_exeext conftest.$ac_ext
32059 LIBS=$ac_check_lib_save_LIBS
32060 fi
32061 echo "$as_me:$LINENO: result: $ac_cv_lib_slp_SLPOpen" >&5
32062 echo "${ECHO_T}$ac_cv_lib_slp_SLPOpen" >&6
32063 if test $ac_cv_lib_slp_SLPOpen = yes; then
32064   have_slp=yes
32065 else
32066   have_slp=no
32067 fi
32068
32069                 if test $have_slp = yes ; then
32070
32071 cat >>confdefs.h <<\_ACEOF
32072 #define HAVE_SLP 1
32073 _ACEOF
32074
32075                         SLAPD_SLP_LIBS=-lslp
32076                 fi
32077
32078         elif test $ol_enable_slp = yes ; then
32079                 { { echo "$as_me:$LINENO: error: SLP not found" >&5
32080 echo "$as_me: error: SLP not found" >&2;}
32081    { (exit 1); exit 1; }; }
32082         fi
32083 fi
32084
32085
32086 echo "$as_me:$LINENO: checking for mode_t" >&5
32087 echo $ECHO_N "checking for mode_t... $ECHO_C" >&6
32088 if test "${ac_cv_type_mode_t+set}" = set; then
32089   echo $ECHO_N "(cached) $ECHO_C" >&6
32090 else
32091   cat >conftest.$ac_ext <<_ACEOF
32092 /* confdefs.h.  */
32093 _ACEOF
32094 cat confdefs.h >>conftest.$ac_ext
32095 cat >>conftest.$ac_ext <<_ACEOF
32096 /* end confdefs.h.  */
32097 $ac_includes_default
32098 int
32099 main ()
32100 {
32101 if ((mode_t *) 0)
32102   return 0;
32103 if (sizeof (mode_t))
32104   return 0;
32105   ;
32106   return 0;
32107 }
32108 _ACEOF
32109 rm -f conftest.$ac_objext
32110 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32111   (eval $ac_compile) 2>conftest.er1
32112   ac_status=$?
32113   grep -v '^ *+' conftest.er1 >conftest.err
32114   rm -f conftest.er1
32115   cat conftest.err >&5
32116   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32117   (exit $ac_status); } &&
32118          { ac_try='test -z "$ac_c_werror_flag"
32119                          || test ! -s conftest.err'
32120   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32121   (eval $ac_try) 2>&5
32122   ac_status=$?
32123   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32124   (exit $ac_status); }; } &&
32125          { ac_try='test -s conftest.$ac_objext'
32126   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32127   (eval $ac_try) 2>&5
32128   ac_status=$?
32129   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32130   (exit $ac_status); }; }; then
32131   ac_cv_type_mode_t=yes
32132 else
32133   echo "$as_me: failed program was:" >&5
32134 sed 's/^/| /' conftest.$ac_ext >&5
32135
32136 ac_cv_type_mode_t=no
32137 fi
32138 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32139 fi
32140 echo "$as_me:$LINENO: result: $ac_cv_type_mode_t" >&5
32141 echo "${ECHO_T}$ac_cv_type_mode_t" >&6
32142 if test $ac_cv_type_mode_t = yes; then
32143   :
32144 else
32145
32146 cat >>confdefs.h <<_ACEOF
32147 #define mode_t int
32148 _ACEOF
32149
32150 fi
32151
32152 echo "$as_me:$LINENO: checking for off_t" >&5
32153 echo $ECHO_N "checking for off_t... $ECHO_C" >&6
32154 if test "${ac_cv_type_off_t+set}" = set; then
32155   echo $ECHO_N "(cached) $ECHO_C" >&6
32156 else
32157   cat >conftest.$ac_ext <<_ACEOF
32158 /* confdefs.h.  */
32159 _ACEOF
32160 cat confdefs.h >>conftest.$ac_ext
32161 cat >>conftest.$ac_ext <<_ACEOF
32162 /* end confdefs.h.  */
32163 $ac_includes_default
32164 int
32165 main ()
32166 {
32167 if ((off_t *) 0)
32168   return 0;
32169 if (sizeof (off_t))
32170   return 0;
32171   ;
32172   return 0;
32173 }
32174 _ACEOF
32175 rm -f conftest.$ac_objext
32176 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32177   (eval $ac_compile) 2>conftest.er1
32178   ac_status=$?
32179   grep -v '^ *+' conftest.er1 >conftest.err
32180   rm -f conftest.er1
32181   cat conftest.err >&5
32182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32183   (exit $ac_status); } &&
32184          { ac_try='test -z "$ac_c_werror_flag"
32185                          || test ! -s conftest.err'
32186   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32187   (eval $ac_try) 2>&5
32188   ac_status=$?
32189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32190   (exit $ac_status); }; } &&
32191          { ac_try='test -s conftest.$ac_objext'
32192   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32193   (eval $ac_try) 2>&5
32194   ac_status=$?
32195   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32196   (exit $ac_status); }; }; then
32197   ac_cv_type_off_t=yes
32198 else
32199   echo "$as_me: failed program was:" >&5
32200 sed 's/^/| /' conftest.$ac_ext >&5
32201
32202 ac_cv_type_off_t=no
32203 fi
32204 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32205 fi
32206 echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
32207 echo "${ECHO_T}$ac_cv_type_off_t" >&6
32208 if test $ac_cv_type_off_t = yes; then
32209   :
32210 else
32211
32212 cat >>confdefs.h <<_ACEOF
32213 #define off_t long
32214 _ACEOF
32215
32216 fi
32217
32218 echo "$as_me:$LINENO: checking for pid_t" >&5
32219 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
32220 if test "${ac_cv_type_pid_t+set}" = set; then
32221   echo $ECHO_N "(cached) $ECHO_C" >&6
32222 else
32223   cat >conftest.$ac_ext <<_ACEOF
32224 /* confdefs.h.  */
32225 _ACEOF
32226 cat confdefs.h >>conftest.$ac_ext
32227 cat >>conftest.$ac_ext <<_ACEOF
32228 /* end confdefs.h.  */
32229 $ac_includes_default
32230 int
32231 main ()
32232 {
32233 if ((pid_t *) 0)
32234   return 0;
32235 if (sizeof (pid_t))
32236   return 0;
32237   ;
32238   return 0;
32239 }
32240 _ACEOF
32241 rm -f conftest.$ac_objext
32242 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32243   (eval $ac_compile) 2>conftest.er1
32244   ac_status=$?
32245   grep -v '^ *+' conftest.er1 >conftest.err
32246   rm -f conftest.er1
32247   cat conftest.err >&5
32248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32249   (exit $ac_status); } &&
32250          { ac_try='test -z "$ac_c_werror_flag"
32251                          || test ! -s conftest.err'
32252   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32253   (eval $ac_try) 2>&5
32254   ac_status=$?
32255   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32256   (exit $ac_status); }; } &&
32257          { ac_try='test -s conftest.$ac_objext'
32258   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32259   (eval $ac_try) 2>&5
32260   ac_status=$?
32261   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32262   (exit $ac_status); }; }; then
32263   ac_cv_type_pid_t=yes
32264 else
32265   echo "$as_me: failed program was:" >&5
32266 sed 's/^/| /' conftest.$ac_ext >&5
32267
32268 ac_cv_type_pid_t=no
32269 fi
32270 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32271 fi
32272 echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
32273 echo "${ECHO_T}$ac_cv_type_pid_t" >&6
32274 if test $ac_cv_type_pid_t = yes; then
32275   :
32276 else
32277
32278 cat >>confdefs.h <<_ACEOF
32279 #define pid_t int
32280 _ACEOF
32281
32282 fi
32283
32284 echo "$as_me:$LINENO: checking for ssize_t" >&5
32285 echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6
32286 if test "${ac_cv_type_ssize_t+set}" = set; then
32287   echo $ECHO_N "(cached) $ECHO_C" >&6
32288 else
32289   cat >conftest.$ac_ext <<_ACEOF
32290 /* confdefs.h.  */
32291 _ACEOF
32292 cat confdefs.h >>conftest.$ac_ext
32293 cat >>conftest.$ac_ext <<_ACEOF
32294 /* end confdefs.h.  */
32295 $ac_includes_default
32296 int
32297 main ()
32298 {
32299 if ((ssize_t *) 0)
32300   return 0;
32301 if (sizeof (ssize_t))
32302   return 0;
32303   ;
32304   return 0;
32305 }
32306 _ACEOF
32307 rm -f conftest.$ac_objext
32308 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32309   (eval $ac_compile) 2>conftest.er1
32310   ac_status=$?
32311   grep -v '^ *+' conftest.er1 >conftest.err
32312   rm -f conftest.er1
32313   cat conftest.err >&5
32314   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32315   (exit $ac_status); } &&
32316          { ac_try='test -z "$ac_c_werror_flag"
32317                          || test ! -s conftest.err'
32318   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32319   (eval $ac_try) 2>&5
32320   ac_status=$?
32321   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32322   (exit $ac_status); }; } &&
32323          { ac_try='test -s conftest.$ac_objext'
32324   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32325   (eval $ac_try) 2>&5
32326   ac_status=$?
32327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32328   (exit $ac_status); }; }; then
32329   ac_cv_type_ssize_t=yes
32330 else
32331   echo "$as_me: failed program was:" >&5
32332 sed 's/^/| /' conftest.$ac_ext >&5
32333
32334 ac_cv_type_ssize_t=no
32335 fi
32336 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32337 fi
32338 echo "$as_me:$LINENO: result: $ac_cv_type_ssize_t" >&5
32339 echo "${ECHO_T}$ac_cv_type_ssize_t" >&6
32340 if test $ac_cv_type_ssize_t = yes; then
32341   :
32342 else
32343
32344 cat >>confdefs.h <<_ACEOF
32345 #define ssize_t signed int
32346 _ACEOF
32347
32348 fi
32349
32350 echo "$as_me:$LINENO: checking for caddr_t" >&5
32351 echo $ECHO_N "checking for caddr_t... $ECHO_C" >&6
32352 if test "${ac_cv_type_caddr_t+set}" = set; then
32353   echo $ECHO_N "(cached) $ECHO_C" >&6
32354 else
32355   cat >conftest.$ac_ext <<_ACEOF
32356 /* confdefs.h.  */
32357 _ACEOF
32358 cat confdefs.h >>conftest.$ac_ext
32359 cat >>conftest.$ac_ext <<_ACEOF
32360 /* end confdefs.h.  */
32361 $ac_includes_default
32362 int
32363 main ()
32364 {
32365 if ((caddr_t *) 0)
32366   return 0;
32367 if (sizeof (caddr_t))
32368   return 0;
32369   ;
32370   return 0;
32371 }
32372 _ACEOF
32373 rm -f conftest.$ac_objext
32374 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32375   (eval $ac_compile) 2>conftest.er1
32376   ac_status=$?
32377   grep -v '^ *+' conftest.er1 >conftest.err
32378   rm -f conftest.er1
32379   cat conftest.err >&5
32380   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32381   (exit $ac_status); } &&
32382          { ac_try='test -z "$ac_c_werror_flag"
32383                          || test ! -s conftest.err'
32384   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32385   (eval $ac_try) 2>&5
32386   ac_status=$?
32387   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32388   (exit $ac_status); }; } &&
32389          { ac_try='test -s conftest.$ac_objext'
32390   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32391   (eval $ac_try) 2>&5
32392   ac_status=$?
32393   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32394   (exit $ac_status); }; }; then
32395   ac_cv_type_caddr_t=yes
32396 else
32397   echo "$as_me: failed program was:" >&5
32398 sed 's/^/| /' conftest.$ac_ext >&5
32399
32400 ac_cv_type_caddr_t=no
32401 fi
32402 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32403 fi
32404 echo "$as_me:$LINENO: result: $ac_cv_type_caddr_t" >&5
32405 echo "${ECHO_T}$ac_cv_type_caddr_t" >&6
32406 if test $ac_cv_type_caddr_t = yes; then
32407   :
32408 else
32409
32410 cat >>confdefs.h <<_ACEOF
32411 #define caddr_t char *
32412 _ACEOF
32413
32414 fi
32415
32416 echo "$as_me:$LINENO: checking for size_t" >&5
32417 echo $ECHO_N "checking for size_t... $ECHO_C" >&6
32418 if test "${ac_cv_type_size_t+set}" = set; then
32419   echo $ECHO_N "(cached) $ECHO_C" >&6
32420 else
32421   cat >conftest.$ac_ext <<_ACEOF
32422 /* confdefs.h.  */
32423 _ACEOF
32424 cat confdefs.h >>conftest.$ac_ext
32425 cat >>conftest.$ac_ext <<_ACEOF
32426 /* end confdefs.h.  */
32427 $ac_includes_default
32428 int
32429 main ()
32430 {
32431 if ((size_t *) 0)
32432   return 0;
32433 if (sizeof (size_t))
32434   return 0;
32435   ;
32436   return 0;
32437 }
32438 _ACEOF
32439 rm -f conftest.$ac_objext
32440 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32441   (eval $ac_compile) 2>conftest.er1
32442   ac_status=$?
32443   grep -v '^ *+' conftest.er1 >conftest.err
32444   rm -f conftest.er1
32445   cat conftest.err >&5
32446   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32447   (exit $ac_status); } &&
32448          { ac_try='test -z "$ac_c_werror_flag"
32449                          || test ! -s conftest.err'
32450   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32451   (eval $ac_try) 2>&5
32452   ac_status=$?
32453   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32454   (exit $ac_status); }; } &&
32455          { ac_try='test -s conftest.$ac_objext'
32456   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32457   (eval $ac_try) 2>&5
32458   ac_status=$?
32459   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32460   (exit $ac_status); }; }; then
32461   ac_cv_type_size_t=yes
32462 else
32463   echo "$as_me: failed program was:" >&5
32464 sed 's/^/| /' conftest.$ac_ext >&5
32465
32466 ac_cv_type_size_t=no
32467 fi
32468 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32469 fi
32470 echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
32471 echo "${ECHO_T}$ac_cv_type_size_t" >&6
32472 if test $ac_cv_type_size_t = yes; then
32473   :
32474 else
32475
32476 cat >>confdefs.h <<_ACEOF
32477 #define size_t unsigned
32478 _ACEOF
32479
32480 fi
32481
32482
32483 echo "$as_me:$LINENO: checking for long long" >&5
32484 echo $ECHO_N "checking for long long... $ECHO_C" >&6
32485 if test "${ac_cv_type_long_long+set}" = set; then
32486   echo $ECHO_N "(cached) $ECHO_C" >&6
32487 else
32488   cat >conftest.$ac_ext <<_ACEOF
32489 /* confdefs.h.  */
32490 _ACEOF
32491 cat confdefs.h >>conftest.$ac_ext
32492 cat >>conftest.$ac_ext <<_ACEOF
32493 /* end confdefs.h.  */
32494 $ac_includes_default
32495 int
32496 main ()
32497 {
32498 if ((long long *) 0)
32499   return 0;
32500 if (sizeof (long long))
32501   return 0;
32502   ;
32503   return 0;
32504 }
32505 _ACEOF
32506 rm -f conftest.$ac_objext
32507 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32508   (eval $ac_compile) 2>conftest.er1
32509   ac_status=$?
32510   grep -v '^ *+' conftest.er1 >conftest.err
32511   rm -f conftest.er1
32512   cat conftest.err >&5
32513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32514   (exit $ac_status); } &&
32515          { ac_try='test -z "$ac_c_werror_flag"
32516                          || test ! -s conftest.err'
32517   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32518   (eval $ac_try) 2>&5
32519   ac_status=$?
32520   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32521   (exit $ac_status); }; } &&
32522          { ac_try='test -s conftest.$ac_objext'
32523   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32524   (eval $ac_try) 2>&5
32525   ac_status=$?
32526   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32527   (exit $ac_status); }; }; then
32528   ac_cv_type_long_long=yes
32529 else
32530   echo "$as_me: failed program was:" >&5
32531 sed 's/^/| /' conftest.$ac_ext >&5
32532
32533 ac_cv_type_long_long=no
32534 fi
32535 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32536 fi
32537 echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
32538 echo "${ECHO_T}$ac_cv_type_long_long" >&6
32539 if test $ac_cv_type_long_long = yes; then
32540
32541 cat >>confdefs.h <<_ACEOF
32542 #define HAVE_LONG_LONG 1
32543 _ACEOF
32544
32545
32546 fi
32547
32548 echo "$as_me:$LINENO: checking for ptrdiff_t" >&5
32549 echo $ECHO_N "checking for ptrdiff_t... $ECHO_C" >&6
32550 if test "${ac_cv_type_ptrdiff_t+set}" = set; then
32551   echo $ECHO_N "(cached) $ECHO_C" >&6
32552 else
32553   cat >conftest.$ac_ext <<_ACEOF
32554 /* confdefs.h.  */
32555 _ACEOF
32556 cat confdefs.h >>conftest.$ac_ext
32557 cat >>conftest.$ac_ext <<_ACEOF
32558 /* end confdefs.h.  */
32559 $ac_includes_default
32560 int
32561 main ()
32562 {
32563 if ((ptrdiff_t *) 0)
32564   return 0;
32565 if (sizeof (ptrdiff_t))
32566   return 0;
32567   ;
32568   return 0;
32569 }
32570 _ACEOF
32571 rm -f conftest.$ac_objext
32572 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32573   (eval $ac_compile) 2>conftest.er1
32574   ac_status=$?
32575   grep -v '^ *+' conftest.er1 >conftest.err
32576   rm -f conftest.er1
32577   cat conftest.err >&5
32578   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32579   (exit $ac_status); } &&
32580          { ac_try='test -z "$ac_c_werror_flag"
32581                          || test ! -s conftest.err'
32582   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32583   (eval $ac_try) 2>&5
32584   ac_status=$?
32585   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32586   (exit $ac_status); }; } &&
32587          { ac_try='test -s conftest.$ac_objext'
32588   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32589   (eval $ac_try) 2>&5
32590   ac_status=$?
32591   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32592   (exit $ac_status); }; }; then
32593   ac_cv_type_ptrdiff_t=yes
32594 else
32595   echo "$as_me: failed program was:" >&5
32596 sed 's/^/| /' conftest.$ac_ext >&5
32597
32598 ac_cv_type_ptrdiff_t=no
32599 fi
32600 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32601 fi
32602 echo "$as_me:$LINENO: result: $ac_cv_type_ptrdiff_t" >&5
32603 echo "${ECHO_T}$ac_cv_type_ptrdiff_t" >&6
32604 if test $ac_cv_type_ptrdiff_t = yes; then
32605
32606 cat >>confdefs.h <<_ACEOF
32607 #define HAVE_PTRDIFF_T 1
32608 _ACEOF
32609
32610
32611 fi
32612
32613
32614
32615 echo "$as_me:$LINENO: checking for socklen_t" >&5
32616 echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6
32617 if test "${ac_cv_type_socklen_t+set}" = set; then
32618   echo $ECHO_N "(cached) $ECHO_C" >&6
32619 else
32620   cat >conftest.$ac_ext <<_ACEOF
32621 /* confdefs.h.  */
32622 _ACEOF
32623 cat confdefs.h >>conftest.$ac_ext
32624 cat >>conftest.$ac_ext <<_ACEOF
32625 /* end confdefs.h.  */
32626 $ac_includes_default
32627 #ifdef HAVE_SYS_SOCKET_H
32628 #include <sys/socket.h>
32629 #endif
32630
32631 int
32632 main ()
32633 {
32634 if ((socklen_t *) 0)
32635   return 0;
32636 if (sizeof (socklen_t))
32637   return 0;
32638   ;
32639   return 0;
32640 }
32641 _ACEOF
32642 rm -f conftest.$ac_objext
32643 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32644   (eval $ac_compile) 2>conftest.er1
32645   ac_status=$?
32646   grep -v '^ *+' conftest.er1 >conftest.err
32647   rm -f conftest.er1
32648   cat conftest.err >&5
32649   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32650   (exit $ac_status); } &&
32651          { ac_try='test -z "$ac_c_werror_flag"
32652                          || test ! -s conftest.err'
32653   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32654   (eval $ac_try) 2>&5
32655   ac_status=$?
32656   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32657   (exit $ac_status); }; } &&
32658          { ac_try='test -s conftest.$ac_objext'
32659   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32660   (eval $ac_try) 2>&5
32661   ac_status=$?
32662   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32663   (exit $ac_status); }; }; then
32664   ac_cv_type_socklen_t=yes
32665 else
32666   echo "$as_me: failed program was:" >&5
32667 sed 's/^/| /' conftest.$ac_ext >&5
32668
32669 ac_cv_type_socklen_t=no
32670 fi
32671 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32672 fi
32673 echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5
32674 echo "${ECHO_T}$ac_cv_type_socklen_t" >&6
32675
32676
32677 echo "$as_me:$LINENO: checking the type of arg 3 to accept()" >&5
32678 echo $ECHO_N "checking the type of arg 3 to accept()... $ECHO_C" >&6
32679 if test "${ol_cv_type_ber_socklen_t+set}" = set; then
32680   echo $ECHO_N "(cached) $ECHO_C" >&6
32681 else
32682
32683         set socklen_t int unsigned "unsigned long" long size_t
32684         test "$ac_cv_type_socklen_t" = yes || shift
32685         ol_cv_type_ber_socklen_t=$1 guessing="guessing "
32686         for lentype in "$@" ; do for addrtype in "struct sockaddr" void ; do
32687                 cat >conftest.$ac_ext <<_ACEOF
32688 /* confdefs.h.  */
32689 _ACEOF
32690 cat confdefs.h >>conftest.$ac_ext
32691 cat >>conftest.$ac_ext <<_ACEOF
32692 /* end confdefs.h.  */
32693 $ac_includes_default
32694 #ifdef HAVE_SYS_SOCKET_H
32695 #include <sys/socket.h>
32696 #endif
32697 extern int accept(int s, $addrtype *ap, $lentype *lp);
32698
32699 int
32700 main ()
32701 {
32702
32703 accept(0, (struct sockaddr *) 0, ($lentype *) 0);
32704
32705   ;
32706   return 0;
32707 }
32708 _ACEOF
32709 rm -f conftest.$ac_objext
32710 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32711   (eval $ac_compile) 2>conftest.er1
32712   ac_status=$?
32713   grep -v '^ *+' conftest.er1 >conftest.err
32714   rm -f conftest.er1
32715   cat conftest.err >&5
32716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32717   (exit $ac_status); } &&
32718          { ac_try='test -z "$ac_c_werror_flag"
32719                          || test ! -s conftest.err'
32720   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32721   (eval $ac_try) 2>&5
32722   ac_status=$?
32723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32724   (exit $ac_status); }; } &&
32725          { ac_try='test -s conftest.$ac_objext'
32726   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32727   (eval $ac_try) 2>&5
32728   ac_status=$?
32729   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32730   (exit $ac_status); }; }; then
32731   ol_cv_type_ber_socklen_t=$lentype guessing= ; break 2
32732 else
32733   echo "$as_me: failed program was:" >&5
32734 sed 's/^/| /' conftest.$ac_ext >&5
32735
32736 fi
32737 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32738         done ; done
32739 fi
32740
32741 echo "$as_me:$LINENO: result: $guessing$ol_cv_type_ber_socklen_t *" >&5
32742 echo "${ECHO_T}$guessing$ol_cv_type_ber_socklen_t *" >&6
32743
32744 cat >>confdefs.h <<_ACEOF
32745 #define ber_socklen_t $ol_cv_type_ber_socklen_t
32746 _ACEOF
32747
32748
32749 if test "$ac_cv_type_socklen_t" != yes; then
32750
32751 cat >>confdefs.h <<_ACEOF
32752 #define socklen_t $ol_cv_type_ber_socklen_t
32753 _ACEOF
32754
32755 fi
32756
32757
32758 echo "$as_me:$LINENO: checking return type of signal handlers" >&5
32759 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
32760 if test "${ac_cv_type_signal+set}" = set; then
32761   echo $ECHO_N "(cached) $ECHO_C" >&6
32762 else
32763   cat >conftest.$ac_ext <<_ACEOF
32764 /* confdefs.h.  */
32765 _ACEOF
32766 cat confdefs.h >>conftest.$ac_ext
32767 cat >>conftest.$ac_ext <<_ACEOF
32768 /* end confdefs.h.  */
32769 #include <sys/types.h>
32770 #include <signal.h>
32771 #ifdef signal
32772 # undef signal
32773 #endif
32774 #ifdef __cplusplus
32775 extern "C" void (*signal (int, void (*)(int)))(int);
32776 #else
32777 void (*signal ()) ();
32778 #endif
32779
32780 int
32781 main ()
32782 {
32783 int i;
32784   ;
32785   return 0;
32786 }
32787 _ACEOF
32788 rm -f conftest.$ac_objext
32789 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32790   (eval $ac_compile) 2>conftest.er1
32791   ac_status=$?
32792   grep -v '^ *+' conftest.er1 >conftest.err
32793   rm -f conftest.er1
32794   cat conftest.err >&5
32795   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32796   (exit $ac_status); } &&
32797          { ac_try='test -z "$ac_c_werror_flag"
32798                          || test ! -s conftest.err'
32799   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32800   (eval $ac_try) 2>&5
32801   ac_status=$?
32802   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32803   (exit $ac_status); }; } &&
32804          { ac_try='test -s conftest.$ac_objext'
32805   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32806   (eval $ac_try) 2>&5
32807   ac_status=$?
32808   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32809   (exit $ac_status); }; }; then
32810   ac_cv_type_signal=void
32811 else
32812   echo "$as_me: failed program was:" >&5
32813 sed 's/^/| /' conftest.$ac_ext >&5
32814
32815 ac_cv_type_signal=int
32816 fi
32817 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32818 fi
32819 echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
32820 echo "${ECHO_T}$ac_cv_type_signal" >&6
32821
32822 cat >>confdefs.h <<_ACEOF
32823 #define RETSIGTYPE $ac_cv_type_signal
32824 _ACEOF
32825
32826
32827
32828 echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
32829 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6
32830 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
32831   echo $ECHO_N "(cached) $ECHO_C" >&6
32832 else
32833   cat >conftest.$ac_ext <<_ACEOF
32834 /* confdefs.h.  */
32835 _ACEOF
32836 cat confdefs.h >>conftest.$ac_ext
32837 cat >>conftest.$ac_ext <<_ACEOF
32838 /* end confdefs.h.  */
32839 $ac_includes_default
32840 #include <signal.h>
32841
32842
32843 int
32844 main ()
32845 {
32846 if ((sig_atomic_t *) 0)
32847   return 0;
32848 if (sizeof (sig_atomic_t))
32849   return 0;
32850   ;
32851   return 0;
32852 }
32853 _ACEOF
32854 rm -f conftest.$ac_objext
32855 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32856   (eval $ac_compile) 2>conftest.er1
32857   ac_status=$?
32858   grep -v '^ *+' conftest.er1 >conftest.err
32859   rm -f conftest.er1
32860   cat conftest.err >&5
32861   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32862   (exit $ac_status); } &&
32863          { ac_try='test -z "$ac_c_werror_flag"
32864                          || test ! -s conftest.err'
32865   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32866   (eval $ac_try) 2>&5
32867   ac_status=$?
32868   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32869   (exit $ac_status); }; } &&
32870          { ac_try='test -s conftest.$ac_objext'
32871   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32872   (eval $ac_try) 2>&5
32873   ac_status=$?
32874   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32875   (exit $ac_status); }; }; then
32876   ac_cv_type_sig_atomic_t=yes
32877 else
32878   echo "$as_me: failed program was:" >&5
32879 sed 's/^/| /' conftest.$ac_ext >&5
32880
32881 ac_cv_type_sig_atomic_t=no
32882 fi
32883 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32884 fi
32885 echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
32886 echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6
32887 if test $ac_cv_type_sig_atomic_t = yes; then
32888   :
32889 else
32890
32891 cat >>confdefs.h <<_ACEOF
32892 #define sig_atomic_t int
32893 _ACEOF
32894
32895 fi
32896
32897
32898 echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5
32899 echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6
32900 if test "${ac_cv_type_uid_t+set}" = set; then
32901   echo $ECHO_N "(cached) $ECHO_C" >&6
32902 else
32903   cat >conftest.$ac_ext <<_ACEOF
32904 /* confdefs.h.  */
32905 _ACEOF
32906 cat confdefs.h >>conftest.$ac_ext
32907 cat >>conftest.$ac_ext <<_ACEOF
32908 /* end confdefs.h.  */
32909 #include <sys/types.h>
32910
32911 _ACEOF
32912 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32913   $EGREP "uid_t" >/dev/null 2>&1; then
32914   ac_cv_type_uid_t=yes
32915 else
32916   ac_cv_type_uid_t=no
32917 fi
32918 rm -f conftest*
32919
32920 fi
32921 echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5
32922 echo "${ECHO_T}$ac_cv_type_uid_t" >&6
32923 if test $ac_cv_type_uid_t = no; then
32924
32925 cat >>confdefs.h <<\_ACEOF
32926 #define uid_t int
32927 _ACEOF
32928
32929
32930 cat >>confdefs.h <<\_ACEOF
32931 #define gid_t int
32932 _ACEOF
32933
32934 fi
32935
32936
32937 echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
32938 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
32939 if test "${ac_cv_header_time+set}" = set; then
32940   echo $ECHO_N "(cached) $ECHO_C" >&6
32941 else
32942   cat >conftest.$ac_ext <<_ACEOF
32943 /* confdefs.h.  */
32944 _ACEOF
32945 cat confdefs.h >>conftest.$ac_ext
32946 cat >>conftest.$ac_ext <<_ACEOF
32947 /* end confdefs.h.  */
32948 #include <sys/types.h>
32949 #include <sys/time.h>
32950 #include <time.h>
32951
32952 int
32953 main ()
32954 {
32955 if ((struct tm *) 0)
32956 return 0;
32957   ;
32958   return 0;
32959 }
32960 _ACEOF
32961 rm -f conftest.$ac_objext
32962 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32963   (eval $ac_compile) 2>conftest.er1
32964   ac_status=$?
32965   grep -v '^ *+' conftest.er1 >conftest.err
32966   rm -f conftest.er1
32967   cat conftest.err >&5
32968   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32969   (exit $ac_status); } &&
32970          { ac_try='test -z "$ac_c_werror_flag"
32971                          || test ! -s conftest.err'
32972   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32973   (eval $ac_try) 2>&5
32974   ac_status=$?
32975   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32976   (exit $ac_status); }; } &&
32977          { ac_try='test -s conftest.$ac_objext'
32978   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32979   (eval $ac_try) 2>&5
32980   ac_status=$?
32981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32982   (exit $ac_status); }; }; then
32983   ac_cv_header_time=yes
32984 else
32985   echo "$as_me: failed program was:" >&5
32986 sed 's/^/| /' conftest.$ac_ext >&5
32987
32988 ac_cv_header_time=no
32989 fi
32990 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
32991 fi
32992 echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
32993 echo "${ECHO_T}$ac_cv_header_time" >&6
32994 if test $ac_cv_header_time = yes; then
32995
32996 cat >>confdefs.h <<\_ACEOF
32997 #define TIME_WITH_SYS_TIME 1
32998 _ACEOF
32999
33000 fi
33001
33002 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
33003 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
33004 if test "${ac_cv_struct_tm+set}" = set; then
33005   echo $ECHO_N "(cached) $ECHO_C" >&6
33006 else
33007   cat >conftest.$ac_ext <<_ACEOF
33008 /* confdefs.h.  */
33009 _ACEOF
33010 cat confdefs.h >>conftest.$ac_ext
33011 cat >>conftest.$ac_ext <<_ACEOF
33012 /* end confdefs.h.  */
33013 #include <sys/types.h>
33014 #include <time.h>
33015
33016 int
33017 main ()
33018 {
33019 struct tm *tp; tp->tm_sec;
33020   ;
33021   return 0;
33022 }
33023 _ACEOF
33024 rm -f conftest.$ac_objext
33025 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33026   (eval $ac_compile) 2>conftest.er1
33027   ac_status=$?
33028   grep -v '^ *+' conftest.er1 >conftest.err
33029   rm -f conftest.er1
33030   cat conftest.err >&5
33031   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33032   (exit $ac_status); } &&
33033          { ac_try='test -z "$ac_c_werror_flag"
33034                          || test ! -s conftest.err'
33035   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33036   (eval $ac_try) 2>&5
33037   ac_status=$?
33038   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33039   (exit $ac_status); }; } &&
33040          { ac_try='test -s conftest.$ac_objext'
33041   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33042   (eval $ac_try) 2>&5
33043   ac_status=$?
33044   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33045   (exit $ac_status); }; }; then
33046   ac_cv_struct_tm=time.h
33047 else
33048   echo "$as_me: failed program was:" >&5
33049 sed 's/^/| /' conftest.$ac_ext >&5
33050
33051 ac_cv_struct_tm=sys/time.h
33052 fi
33053 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33054 fi
33055 echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
33056 echo "${ECHO_T}$ac_cv_struct_tm" >&6
33057 if test $ac_cv_struct_tm = sys/time.h; then
33058
33059 cat >>confdefs.h <<\_ACEOF
33060 #define TM_IN_SYS_TIME 1
33061 _ACEOF
33062
33063 fi
33064
33065 echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
33066 echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6
33067 if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
33068   echo $ECHO_N "(cached) $ECHO_C" >&6
33069 else
33070   cat >conftest.$ac_ext <<_ACEOF
33071 /* confdefs.h.  */
33072 _ACEOF
33073 cat confdefs.h >>conftest.$ac_ext
33074 cat >>conftest.$ac_ext <<_ACEOF
33075 /* end confdefs.h.  */
33076 $ac_includes_default
33077 int
33078 main ()
33079 {
33080 static struct stat ac_aggr;
33081 if (ac_aggr.st_blksize)
33082 return 0;
33083   ;
33084   return 0;
33085 }
33086 _ACEOF
33087 rm -f conftest.$ac_objext
33088 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33089   (eval $ac_compile) 2>conftest.er1
33090   ac_status=$?
33091   grep -v '^ *+' conftest.er1 >conftest.err
33092   rm -f conftest.er1
33093   cat conftest.err >&5
33094   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33095   (exit $ac_status); } &&
33096          { ac_try='test -z "$ac_c_werror_flag"
33097                          || test ! -s conftest.err'
33098   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33099   (eval $ac_try) 2>&5
33100   ac_status=$?
33101   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33102   (exit $ac_status); }; } &&
33103          { ac_try='test -s conftest.$ac_objext'
33104   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33105   (eval $ac_try) 2>&5
33106   ac_status=$?
33107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33108   (exit $ac_status); }; }; then
33109   ac_cv_member_struct_stat_st_blksize=yes
33110 else
33111   echo "$as_me: failed program was:" >&5
33112 sed 's/^/| /' conftest.$ac_ext >&5
33113
33114 cat >conftest.$ac_ext <<_ACEOF
33115 /* confdefs.h.  */
33116 _ACEOF
33117 cat confdefs.h >>conftest.$ac_ext
33118 cat >>conftest.$ac_ext <<_ACEOF
33119 /* end confdefs.h.  */
33120 $ac_includes_default
33121 int
33122 main ()
33123 {
33124 static struct stat ac_aggr;
33125 if (sizeof ac_aggr.st_blksize)
33126 return 0;
33127   ;
33128   return 0;
33129 }
33130 _ACEOF
33131 rm -f conftest.$ac_objext
33132 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33133   (eval $ac_compile) 2>conftest.er1
33134   ac_status=$?
33135   grep -v '^ *+' conftest.er1 >conftest.err
33136   rm -f conftest.er1
33137   cat conftest.err >&5
33138   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33139   (exit $ac_status); } &&
33140          { ac_try='test -z "$ac_c_werror_flag"
33141                          || test ! -s conftest.err'
33142   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33143   (eval $ac_try) 2>&5
33144   ac_status=$?
33145   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33146   (exit $ac_status); }; } &&
33147          { ac_try='test -s conftest.$ac_objext'
33148   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33149   (eval $ac_try) 2>&5
33150   ac_status=$?
33151   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33152   (exit $ac_status); }; }; then
33153   ac_cv_member_struct_stat_st_blksize=yes
33154 else
33155   echo "$as_me: failed program was:" >&5
33156 sed 's/^/| /' conftest.$ac_ext >&5
33157
33158 ac_cv_member_struct_stat_st_blksize=no
33159 fi
33160 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33161 fi
33162 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33163 fi
33164 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
33165 echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6
33166 if test $ac_cv_member_struct_stat_st_blksize = yes; then
33167
33168 cat >>confdefs.h <<_ACEOF
33169 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
33170 _ACEOF
33171
33172
33173 fi
33174
33175 echo "$as_me:$LINENO: checking for struct passwd.pw_gecos" >&5
33176 echo $ECHO_N "checking for struct passwd.pw_gecos... $ECHO_C" >&6
33177 if test "${ac_cv_member_struct_passwd_pw_gecos+set}" = set; then
33178   echo $ECHO_N "(cached) $ECHO_C" >&6
33179 else
33180   cat >conftest.$ac_ext <<_ACEOF
33181 /* confdefs.h.  */
33182 _ACEOF
33183 cat confdefs.h >>conftest.$ac_ext
33184 cat >>conftest.$ac_ext <<_ACEOF
33185 /* end confdefs.h.  */
33186 $ac_includes_default
33187 #include <pwd.h>
33188
33189 int
33190 main ()
33191 {
33192 static struct passwd ac_aggr;
33193 if (ac_aggr.pw_gecos)
33194 return 0;
33195   ;
33196   return 0;
33197 }
33198 _ACEOF
33199 rm -f conftest.$ac_objext
33200 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33201   (eval $ac_compile) 2>conftest.er1
33202   ac_status=$?
33203   grep -v '^ *+' conftest.er1 >conftest.err
33204   rm -f conftest.er1
33205   cat conftest.err >&5
33206   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33207   (exit $ac_status); } &&
33208          { ac_try='test -z "$ac_c_werror_flag"
33209                          || test ! -s conftest.err'
33210   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33211   (eval $ac_try) 2>&5
33212   ac_status=$?
33213   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33214   (exit $ac_status); }; } &&
33215          { ac_try='test -s conftest.$ac_objext'
33216   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33217   (eval $ac_try) 2>&5
33218   ac_status=$?
33219   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33220   (exit $ac_status); }; }; then
33221   ac_cv_member_struct_passwd_pw_gecos=yes
33222 else
33223   echo "$as_me: failed program was:" >&5
33224 sed 's/^/| /' conftest.$ac_ext >&5
33225
33226 cat >conftest.$ac_ext <<_ACEOF
33227 /* confdefs.h.  */
33228 _ACEOF
33229 cat confdefs.h >>conftest.$ac_ext
33230 cat >>conftest.$ac_ext <<_ACEOF
33231 /* end confdefs.h.  */
33232 $ac_includes_default
33233 #include <pwd.h>
33234
33235 int
33236 main ()
33237 {
33238 static struct passwd ac_aggr;
33239 if (sizeof ac_aggr.pw_gecos)
33240 return 0;
33241   ;
33242   return 0;
33243 }
33244 _ACEOF
33245 rm -f conftest.$ac_objext
33246 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33247   (eval $ac_compile) 2>conftest.er1
33248   ac_status=$?
33249   grep -v '^ *+' conftest.er1 >conftest.err
33250   rm -f conftest.er1
33251   cat conftest.err >&5
33252   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33253   (exit $ac_status); } &&
33254          { ac_try='test -z "$ac_c_werror_flag"
33255                          || test ! -s conftest.err'
33256   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33257   (eval $ac_try) 2>&5
33258   ac_status=$?
33259   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33260   (exit $ac_status); }; } &&
33261          { ac_try='test -s conftest.$ac_objext'
33262   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33263   (eval $ac_try) 2>&5
33264   ac_status=$?
33265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33266   (exit $ac_status); }; }; then
33267   ac_cv_member_struct_passwd_pw_gecos=yes
33268 else
33269   echo "$as_me: failed program was:" >&5
33270 sed 's/^/| /' conftest.$ac_ext >&5
33271
33272 ac_cv_member_struct_passwd_pw_gecos=no
33273 fi
33274 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33275 fi
33276 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33277 fi
33278 echo "$as_me:$LINENO: result: $ac_cv_member_struct_passwd_pw_gecos" >&5
33279 echo "${ECHO_T}$ac_cv_member_struct_passwd_pw_gecos" >&6
33280 if test $ac_cv_member_struct_passwd_pw_gecos = yes; then
33281
33282 cat >>confdefs.h <<_ACEOF
33283 #define HAVE_STRUCT_PASSWD_PW_GECOS 1
33284 _ACEOF
33285
33286
33287 fi
33288
33289 echo "$as_me:$LINENO: checking for struct passwd.pw_passwd" >&5
33290 echo $ECHO_N "checking for struct passwd.pw_passwd... $ECHO_C" >&6
33291 if test "${ac_cv_member_struct_passwd_pw_passwd+set}" = set; then
33292   echo $ECHO_N "(cached) $ECHO_C" >&6
33293 else
33294   cat >conftest.$ac_ext <<_ACEOF
33295 /* confdefs.h.  */
33296 _ACEOF
33297 cat confdefs.h >>conftest.$ac_ext
33298 cat >>conftest.$ac_ext <<_ACEOF
33299 /* end confdefs.h.  */
33300 $ac_includes_default
33301 #include <pwd.h>
33302
33303 int
33304 main ()
33305 {
33306 static struct passwd ac_aggr;
33307 if (ac_aggr.pw_passwd)
33308 return 0;
33309   ;
33310   return 0;
33311 }
33312 _ACEOF
33313 rm -f conftest.$ac_objext
33314 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33315   (eval $ac_compile) 2>conftest.er1
33316   ac_status=$?
33317   grep -v '^ *+' conftest.er1 >conftest.err
33318   rm -f conftest.er1
33319   cat conftest.err >&5
33320   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33321   (exit $ac_status); } &&
33322          { ac_try='test -z "$ac_c_werror_flag"
33323                          || test ! -s conftest.err'
33324   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33325   (eval $ac_try) 2>&5
33326   ac_status=$?
33327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33328   (exit $ac_status); }; } &&
33329          { ac_try='test -s conftest.$ac_objext'
33330   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33331   (eval $ac_try) 2>&5
33332   ac_status=$?
33333   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33334   (exit $ac_status); }; }; then
33335   ac_cv_member_struct_passwd_pw_passwd=yes
33336 else
33337   echo "$as_me: failed program was:" >&5
33338 sed 's/^/| /' conftest.$ac_ext >&5
33339
33340 cat >conftest.$ac_ext <<_ACEOF
33341 /* confdefs.h.  */
33342 _ACEOF
33343 cat confdefs.h >>conftest.$ac_ext
33344 cat >>conftest.$ac_ext <<_ACEOF
33345 /* end confdefs.h.  */
33346 $ac_includes_default
33347 #include <pwd.h>
33348
33349 int
33350 main ()
33351 {
33352 static struct passwd ac_aggr;
33353 if (sizeof ac_aggr.pw_passwd)
33354 return 0;
33355   ;
33356   return 0;
33357 }
33358 _ACEOF
33359 rm -f conftest.$ac_objext
33360 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33361   (eval $ac_compile) 2>conftest.er1
33362   ac_status=$?
33363   grep -v '^ *+' conftest.er1 >conftest.err
33364   rm -f conftest.er1
33365   cat conftest.err >&5
33366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33367   (exit $ac_status); } &&
33368          { ac_try='test -z "$ac_c_werror_flag"
33369                          || test ! -s conftest.err'
33370   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33371   (eval $ac_try) 2>&5
33372   ac_status=$?
33373   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33374   (exit $ac_status); }; } &&
33375          { ac_try='test -s conftest.$ac_objext'
33376   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33377   (eval $ac_try) 2>&5
33378   ac_status=$?
33379   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33380   (exit $ac_status); }; }; then
33381   ac_cv_member_struct_passwd_pw_passwd=yes
33382 else
33383   echo "$as_me: failed program was:" >&5
33384 sed 's/^/| /' conftest.$ac_ext >&5
33385
33386 ac_cv_member_struct_passwd_pw_passwd=no
33387 fi
33388 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33389 fi
33390 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33391 fi
33392 echo "$as_me:$LINENO: result: $ac_cv_member_struct_passwd_pw_passwd" >&5
33393 echo "${ECHO_T}$ac_cv_member_struct_passwd_pw_passwd" >&6
33394 if test $ac_cv_member_struct_passwd_pw_passwd = yes; then
33395
33396 cat >>confdefs.h <<_ACEOF
33397 #define HAVE_STRUCT_PASSWD_PW_PASSWD 1
33398 _ACEOF
33399
33400
33401 fi
33402
33403
33404 echo "$as_me:$LINENO: checking if toupper() requires islower()" >&5
33405 echo $ECHO_N "checking if toupper() requires islower()... $ECHO_C" >&6
33406 if test "${ol_cv_c_upper_lower+set}" = set; then
33407   echo $ECHO_N "(cached) $ECHO_C" >&6
33408 else
33409
33410         if test "$cross_compiling" = yes; then
33411   ol_cv_c_upper_lower=safe
33412 else
33413   cat >conftest.$ac_ext <<_ACEOF
33414 /* confdefs.h.  */
33415 _ACEOF
33416 cat confdefs.h >>conftest.$ac_ext
33417 cat >>conftest.$ac_ext <<_ACEOF
33418 /* end confdefs.h.  */
33419
33420 #include <ctype.h>
33421 main()
33422 {
33423         if ('C' == toupper('C'))
33424                 exit(0);
33425         else
33426                 exit(1);
33427 }
33428 _ACEOF
33429 rm -f conftest$ac_exeext
33430 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33431   (eval $ac_link) 2>&5
33432   ac_status=$?
33433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33434   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
33435   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33436   (eval $ac_try) 2>&5
33437   ac_status=$?
33438   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33439   (exit $ac_status); }; }; then
33440   ol_cv_c_upper_lower=no
33441 else
33442   echo "$as_me: program exited with status $ac_status" >&5
33443 echo "$as_me: failed program was:" >&5
33444 sed 's/^/| /' conftest.$ac_ext >&5
33445
33446 ( exit $ac_status )
33447 ol_cv_c_upper_lower=yes
33448 fi
33449 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
33450 fi
33451 fi
33452 echo "$as_me:$LINENO: result: $ol_cv_c_upper_lower" >&5
33453 echo "${ECHO_T}$ol_cv_c_upper_lower" >&6
33454 if test $ol_cv_c_upper_lower != no ; then
33455
33456 cat >>confdefs.h <<\_ACEOF
33457 #define C_UPPER_LOWER 1
33458 _ACEOF
33459
33460 fi
33461
33462 echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
33463 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
33464 if test "${ac_cv_c_const+set}" = set; then
33465   echo $ECHO_N "(cached) $ECHO_C" >&6
33466 else
33467   cat >conftest.$ac_ext <<_ACEOF
33468 /* confdefs.h.  */
33469 _ACEOF
33470 cat confdefs.h >>conftest.$ac_ext
33471 cat >>conftest.$ac_ext <<_ACEOF
33472 /* end confdefs.h.  */
33473
33474 int
33475 main ()
33476 {
33477 /* FIXME: Include the comments suggested by Paul. */
33478 #ifndef __cplusplus
33479   /* Ultrix mips cc rejects this.  */
33480   typedef int charset[2];
33481   const charset x;
33482   /* SunOS 4.1.1 cc rejects this.  */
33483   char const *const *ccp;
33484   char **p;
33485   /* NEC SVR4.0.2 mips cc rejects this.  */
33486   struct point {int x, y;};
33487   static struct point const zero = {0,0};
33488   /* AIX XL C 1.02.0.0 rejects this.
33489      It does not let you subtract one const X* pointer from another in
33490      an arm of an if-expression whose if-part is not a constant
33491      expression */
33492   const char *g = "string";
33493   ccp = &g + (g ? g-g : 0);
33494   /* HPUX 7.0 cc rejects these. */
33495   ++ccp;
33496   p = (char**) ccp;
33497   ccp = (char const *const *) p;
33498   { /* SCO 3.2v4 cc rejects this.  */
33499     char *t;
33500     char const *s = 0 ? (char *) 0 : (char const *) 0;
33501
33502     *t++ = 0;
33503   }
33504   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
33505     int x[] = {25, 17};
33506     const int *foo = &x[0];
33507     ++foo;
33508   }
33509   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
33510     typedef const int *iptr;
33511     iptr p = 0;
33512     ++p;
33513   }
33514   { /* AIX XL C 1.02.0.0 rejects this saying
33515        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
33516     struct s { int j; const int *ap[3]; };
33517     struct s *b; b->j = 5;
33518   }
33519   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
33520     const int foo = 10;
33521   }
33522 #endif
33523
33524   ;
33525   return 0;
33526 }
33527 _ACEOF
33528 rm -f conftest.$ac_objext
33529 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33530   (eval $ac_compile) 2>conftest.er1
33531   ac_status=$?
33532   grep -v '^ *+' conftest.er1 >conftest.err
33533   rm -f conftest.er1
33534   cat conftest.err >&5
33535   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33536   (exit $ac_status); } &&
33537          { ac_try='test -z "$ac_c_werror_flag"
33538                          || test ! -s conftest.err'
33539   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33540   (eval $ac_try) 2>&5
33541   ac_status=$?
33542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33543   (exit $ac_status); }; } &&
33544          { ac_try='test -s conftest.$ac_objext'
33545   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33546   (eval $ac_try) 2>&5
33547   ac_status=$?
33548   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33549   (exit $ac_status); }; }; then
33550   ac_cv_c_const=yes
33551 else
33552   echo "$as_me: failed program was:" >&5
33553 sed 's/^/| /' conftest.$ac_ext >&5
33554
33555 ac_cv_c_const=no
33556 fi
33557 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33558 fi
33559 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
33560 echo "${ECHO_T}$ac_cv_c_const" >&6
33561 if test $ac_cv_c_const = no; then
33562
33563 cat >>confdefs.h <<\_ACEOF
33564 #define const
33565 _ACEOF
33566
33567 fi
33568
33569 echo "$as_me:$LINENO: checking if compiler understands volatile" >&5
33570 echo $ECHO_N "checking if compiler understands volatile... $ECHO_C" >&6
33571 if test "${ol_cv_c_volatile+set}" = set; then
33572   echo $ECHO_N "(cached) $ECHO_C" >&6
33573 else
33574   cat >conftest.$ac_ext <<_ACEOF
33575 /* confdefs.h.  */
33576 _ACEOF
33577 cat confdefs.h >>conftest.$ac_ext
33578 cat >>conftest.$ac_ext <<_ACEOF
33579 /* end confdefs.h.  */
33580 int x, y, z;
33581 int
33582 main ()
33583 {
33584 volatile int a; int * volatile b = x ? &y : &z;
33585       /* Older MIPS compilers (eg., in Ultrix 4.2) don't like *b = 0 */
33586       *b = 0;
33587   ;
33588   return 0;
33589 }
33590 _ACEOF
33591 rm -f conftest.$ac_objext
33592 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33593   (eval $ac_compile) 2>conftest.er1
33594   ac_status=$?
33595   grep -v '^ *+' conftest.er1 >conftest.err
33596   rm -f conftest.er1
33597   cat conftest.err >&5
33598   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33599   (exit $ac_status); } &&
33600          { ac_try='test -z "$ac_c_werror_flag"
33601                          || test ! -s conftest.err'
33602   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33603   (eval $ac_try) 2>&5
33604   ac_status=$?
33605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33606   (exit $ac_status); }; } &&
33607          { ac_try='test -s conftest.$ac_objext'
33608   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33609   (eval $ac_try) 2>&5
33610   ac_status=$?
33611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33612   (exit $ac_status); }; }; then
33613   ol_cv_c_volatile=yes
33614 else
33615   echo "$as_me: failed program was:" >&5
33616 sed 's/^/| /' conftest.$ac_ext >&5
33617
33618 ol_cv_c_volatile=no
33619 fi
33620 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33621 fi
33622 echo "$as_me:$LINENO: result: $ol_cv_c_volatile" >&5
33623 echo "${ECHO_T}$ol_cv_c_volatile" >&6
33624   if test $ol_cv_c_volatile = yes; then
33625     :
33626   else
33627
33628 cat >>confdefs.h <<\_ACEOF
33629 #define volatile
33630 _ACEOF
33631
33632   fi
33633
33634
33635 if test $cross_compiling = yes ; then
33636         { echo "$as_me:$LINENO: WARNING: Crossing compiling... all bets are off!" >&5
33637 echo "$as_me: WARNING: Crossing compiling... all bets are off!" >&2;}
33638
33639 cat >>confdefs.h <<\_ACEOF
33640 #define CROSS_COMPILING 1
33641 _ACEOF
33642
33643 else
33644         echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
33645 echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
33646 if test "${ac_cv_c_bigendian+set}" = set; then
33647   echo $ECHO_N "(cached) $ECHO_C" >&6
33648 else
33649   # See if sys/param.h defines the BYTE_ORDER macro.
33650 cat >conftest.$ac_ext <<_ACEOF
33651 /* confdefs.h.  */
33652 _ACEOF
33653 cat confdefs.h >>conftest.$ac_ext
33654 cat >>conftest.$ac_ext <<_ACEOF
33655 /* end confdefs.h.  */
33656 #include <sys/types.h>
33657 #include <sys/param.h>
33658
33659 int
33660 main ()
33661 {
33662 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
33663  bogus endian macros
33664 #endif
33665
33666   ;
33667   return 0;
33668 }
33669 _ACEOF
33670 rm -f conftest.$ac_objext
33671 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33672   (eval $ac_compile) 2>conftest.er1
33673   ac_status=$?
33674   grep -v '^ *+' conftest.er1 >conftest.err
33675   rm -f conftest.er1
33676   cat conftest.err >&5
33677   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33678   (exit $ac_status); } &&
33679          { ac_try='test -z "$ac_c_werror_flag"
33680                          || test ! -s conftest.err'
33681   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33682   (eval $ac_try) 2>&5
33683   ac_status=$?
33684   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33685   (exit $ac_status); }; } &&
33686          { ac_try='test -s conftest.$ac_objext'
33687   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33688   (eval $ac_try) 2>&5
33689   ac_status=$?
33690   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33691   (exit $ac_status); }; }; then
33692   # It does; now see whether it defined to BIG_ENDIAN or not.
33693 cat >conftest.$ac_ext <<_ACEOF
33694 /* confdefs.h.  */
33695 _ACEOF
33696 cat confdefs.h >>conftest.$ac_ext
33697 cat >>conftest.$ac_ext <<_ACEOF
33698 /* end confdefs.h.  */
33699 #include <sys/types.h>
33700 #include <sys/param.h>
33701
33702 int
33703 main ()
33704 {
33705 #if BYTE_ORDER != BIG_ENDIAN
33706  not big endian
33707 #endif
33708
33709   ;
33710   return 0;
33711 }
33712 _ACEOF
33713 rm -f conftest.$ac_objext
33714 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33715   (eval $ac_compile) 2>conftest.er1
33716   ac_status=$?
33717   grep -v '^ *+' conftest.er1 >conftest.err
33718   rm -f conftest.er1
33719   cat conftest.err >&5
33720   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33721   (exit $ac_status); } &&
33722          { ac_try='test -z "$ac_c_werror_flag"
33723                          || test ! -s conftest.err'
33724   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33725   (eval $ac_try) 2>&5
33726   ac_status=$?
33727   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33728   (exit $ac_status); }; } &&
33729          { ac_try='test -s conftest.$ac_objext'
33730   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33731   (eval $ac_try) 2>&5
33732   ac_status=$?
33733   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33734   (exit $ac_status); }; }; then
33735   ac_cv_c_bigendian=yes
33736 else
33737   echo "$as_me: failed program was:" >&5
33738 sed 's/^/| /' conftest.$ac_ext >&5
33739
33740 ac_cv_c_bigendian=no
33741 fi
33742 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33743 else
33744   echo "$as_me: failed program was:" >&5
33745 sed 's/^/| /' conftest.$ac_ext >&5
33746
33747 # It does not; compile a test program.
33748 if test "$cross_compiling" = yes; then
33749   # try to guess the endianness by grepping values into an object file
33750   ac_cv_c_bigendian=unknown
33751   cat >conftest.$ac_ext <<_ACEOF
33752 /* confdefs.h.  */
33753 _ACEOF
33754 cat confdefs.h >>conftest.$ac_ext
33755 cat >>conftest.$ac_ext <<_ACEOF
33756 /* end confdefs.h.  */
33757 short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
33758 short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
33759 void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
33760 short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
33761 short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
33762 void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
33763 int
33764 main ()
33765 {
33766  _ascii (); _ebcdic ();
33767   ;
33768   return 0;
33769 }
33770 _ACEOF
33771 rm -f conftest.$ac_objext
33772 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33773   (eval $ac_compile) 2>conftest.er1
33774   ac_status=$?
33775   grep -v '^ *+' conftest.er1 >conftest.err
33776   rm -f conftest.er1
33777   cat conftest.err >&5
33778   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33779   (exit $ac_status); } &&
33780          { ac_try='test -z "$ac_c_werror_flag"
33781                          || test ! -s conftest.err'
33782   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33783   (eval $ac_try) 2>&5
33784   ac_status=$?
33785   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33786   (exit $ac_status); }; } &&
33787          { ac_try='test -s conftest.$ac_objext'
33788   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33789   (eval $ac_try) 2>&5
33790   ac_status=$?
33791   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33792   (exit $ac_status); }; }; then
33793   if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
33794   ac_cv_c_bigendian=yes
33795 fi
33796 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
33797   if test "$ac_cv_c_bigendian" = unknown; then
33798     ac_cv_c_bigendian=no
33799   else
33800     # finding both strings is unlikely to happen, but who knows?
33801     ac_cv_c_bigendian=unknown
33802   fi
33803 fi
33804 else
33805   echo "$as_me: failed program was:" >&5
33806 sed 's/^/| /' conftest.$ac_ext >&5
33807
33808 fi
33809 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33810 else
33811   cat >conftest.$ac_ext <<_ACEOF
33812 /* confdefs.h.  */
33813 _ACEOF
33814 cat confdefs.h >>conftest.$ac_ext
33815 cat >>conftest.$ac_ext <<_ACEOF
33816 /* end confdefs.h.  */
33817 int
33818 main ()
33819 {
33820   /* Are we little or big endian?  From Harbison&Steele.  */
33821   union
33822   {
33823     long l;
33824     char c[sizeof (long)];
33825   } u;
33826   u.l = 1;
33827   exit (u.c[sizeof (long) - 1] == 1);
33828 }
33829 _ACEOF
33830 rm -f conftest$ac_exeext
33831 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
33832   (eval $ac_link) 2>&5
33833   ac_status=$?
33834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33835   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
33836   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33837   (eval $ac_try) 2>&5
33838   ac_status=$?
33839   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33840   (exit $ac_status); }; }; then
33841   ac_cv_c_bigendian=no
33842 else
33843   echo "$as_me: program exited with status $ac_status" >&5
33844 echo "$as_me: failed program was:" >&5
33845 sed 's/^/| /' conftest.$ac_ext >&5
33846
33847 ( exit $ac_status )
33848 ac_cv_c_bigendian=yes
33849 fi
33850 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
33851 fi
33852 fi
33853 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33854 fi
33855 echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
33856 echo "${ECHO_T}$ac_cv_c_bigendian" >&6
33857 case $ac_cv_c_bigendian in
33858   yes)
33859
33860 cat >>confdefs.h <<\_ACEOF
33861 #define WORDS_BIGENDIAN 1
33862 _ACEOF
33863  ;;
33864   no)
33865      ;;
33866   *)
33867     { { echo "$as_me:$LINENO: error: unknown endianness
33868 presetting ac_cv_c_bigendian=no (or yes) will help" >&5
33869 echo "$as_me: error: unknown endianness
33870 presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
33871    { (exit 1); exit 1; }; } ;;
33872 esac
33873
33874 fi
33875
33876 echo "$as_me:$LINENO: checking for short" >&5
33877 echo $ECHO_N "checking for short... $ECHO_C" >&6
33878 if test "${ac_cv_type_short+set}" = set; then
33879   echo $ECHO_N "(cached) $ECHO_C" >&6
33880 else
33881   cat >conftest.$ac_ext <<_ACEOF
33882 /* confdefs.h.  */
33883 _ACEOF
33884 cat confdefs.h >>conftest.$ac_ext
33885 cat >>conftest.$ac_ext <<_ACEOF
33886 /* end confdefs.h.  */
33887 $ac_includes_default
33888 int
33889 main ()
33890 {
33891 if ((short *) 0)
33892   return 0;
33893 if (sizeof (short))
33894   return 0;
33895   ;
33896   return 0;
33897 }
33898 _ACEOF
33899 rm -f conftest.$ac_objext
33900 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33901   (eval $ac_compile) 2>conftest.er1
33902   ac_status=$?
33903   grep -v '^ *+' conftest.er1 >conftest.err
33904   rm -f conftest.er1
33905   cat conftest.err >&5
33906   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33907   (exit $ac_status); } &&
33908          { ac_try='test -z "$ac_c_werror_flag"
33909                          || test ! -s conftest.err'
33910   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33911   (eval $ac_try) 2>&5
33912   ac_status=$?
33913   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33914   (exit $ac_status); }; } &&
33915          { ac_try='test -s conftest.$ac_objext'
33916   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33917   (eval $ac_try) 2>&5
33918   ac_status=$?
33919   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33920   (exit $ac_status); }; }; then
33921   ac_cv_type_short=yes
33922 else
33923   echo "$as_me: failed program was:" >&5
33924 sed 's/^/| /' conftest.$ac_ext >&5
33925
33926 ac_cv_type_short=no
33927 fi
33928 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
33929 fi
33930 echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
33931 echo "${ECHO_T}$ac_cv_type_short" >&6
33932
33933 echo "$as_me:$LINENO: checking size of short" >&5
33934 echo $ECHO_N "checking size of short... $ECHO_C" >&6
33935 if test "${ac_cv_sizeof_short+set}" = set; then
33936   echo $ECHO_N "(cached) $ECHO_C" >&6
33937 else
33938   if test "$ac_cv_type_short" = yes; then
33939   # The cast to unsigned long works around a bug in the HP C Compiler
33940   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
33941   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
33942   # This bug is HP SR number 8606223364.
33943   if test "$cross_compiling" = yes; then
33944   # Depending upon the size, compute the lo and hi bounds.
33945 cat >conftest.$ac_ext <<_ACEOF
33946 /* confdefs.h.  */
33947 _ACEOF
33948 cat confdefs.h >>conftest.$ac_ext
33949 cat >>conftest.$ac_ext <<_ACEOF
33950 /* end confdefs.h.  */
33951 $ac_includes_default
33952 int
33953 main ()
33954 {
33955 static int test_array [1 - 2 * !(((long) (sizeof (short))) >= 0)];
33956 test_array [0] = 0
33957
33958   ;
33959   return 0;
33960 }
33961 _ACEOF
33962 rm -f conftest.$ac_objext
33963 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
33964   (eval $ac_compile) 2>conftest.er1
33965   ac_status=$?
33966   grep -v '^ *+' conftest.er1 >conftest.err
33967   rm -f conftest.er1
33968   cat conftest.err >&5
33969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33970   (exit $ac_status); } &&
33971          { ac_try='test -z "$ac_c_werror_flag"
33972                          || test ! -s conftest.err'
33973   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33974   (eval $ac_try) 2>&5
33975   ac_status=$?
33976   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33977   (exit $ac_status); }; } &&
33978          { ac_try='test -s conftest.$ac_objext'
33979   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
33980   (eval $ac_try) 2>&5
33981   ac_status=$?
33982   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33983   (exit $ac_status); }; }; then
33984   ac_lo=0 ac_mid=0
33985   while :; do
33986     cat >conftest.$ac_ext <<_ACEOF
33987 /* confdefs.h.  */
33988 _ACEOF
33989 cat confdefs.h >>conftest.$ac_ext
33990 cat >>conftest.$ac_ext <<_ACEOF
33991 /* end confdefs.h.  */
33992 $ac_includes_default
33993 int
33994 main ()
33995 {
33996 static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
33997 test_array [0] = 0
33998
33999   ;
34000   return 0;
34001 }
34002 _ACEOF
34003 rm -f conftest.$ac_objext
34004 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34005   (eval $ac_compile) 2>conftest.er1
34006   ac_status=$?
34007   grep -v '^ *+' conftest.er1 >conftest.err
34008   rm -f conftest.er1
34009   cat conftest.err >&5
34010   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34011   (exit $ac_status); } &&
34012          { ac_try='test -z "$ac_c_werror_flag"
34013                          || test ! -s conftest.err'
34014   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34015   (eval $ac_try) 2>&5
34016   ac_status=$?
34017   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34018   (exit $ac_status); }; } &&
34019          { ac_try='test -s conftest.$ac_objext'
34020   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34021   (eval $ac_try) 2>&5
34022   ac_status=$?
34023   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34024   (exit $ac_status); }; }; then
34025   ac_hi=$ac_mid; break
34026 else
34027   echo "$as_me: failed program was:" >&5
34028 sed 's/^/| /' conftest.$ac_ext >&5
34029
34030 ac_lo=`expr $ac_mid + 1`
34031                     if test $ac_lo -le $ac_mid; then
34032                       ac_lo= ac_hi=
34033                       break
34034                     fi
34035                     ac_mid=`expr 2 '*' $ac_mid + 1`
34036 fi
34037 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34038   done
34039 else
34040   echo "$as_me: failed program was:" >&5
34041 sed 's/^/| /' conftest.$ac_ext >&5
34042
34043 cat >conftest.$ac_ext <<_ACEOF
34044 /* confdefs.h.  */
34045 _ACEOF
34046 cat confdefs.h >>conftest.$ac_ext
34047 cat >>conftest.$ac_ext <<_ACEOF
34048 /* end confdefs.h.  */
34049 $ac_includes_default
34050 int
34051 main ()
34052 {
34053 static int test_array [1 - 2 * !(((long) (sizeof (short))) < 0)];
34054 test_array [0] = 0
34055
34056   ;
34057   return 0;
34058 }
34059 _ACEOF
34060 rm -f conftest.$ac_objext
34061 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34062   (eval $ac_compile) 2>conftest.er1
34063   ac_status=$?
34064   grep -v '^ *+' conftest.er1 >conftest.err
34065   rm -f conftest.er1
34066   cat conftest.err >&5
34067   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34068   (exit $ac_status); } &&
34069          { ac_try='test -z "$ac_c_werror_flag"
34070                          || test ! -s conftest.err'
34071   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34072   (eval $ac_try) 2>&5
34073   ac_status=$?
34074   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34075   (exit $ac_status); }; } &&
34076          { ac_try='test -s conftest.$ac_objext'
34077   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34078   (eval $ac_try) 2>&5
34079   ac_status=$?
34080   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34081   (exit $ac_status); }; }; then
34082   ac_hi=-1 ac_mid=-1
34083   while :; do
34084     cat >conftest.$ac_ext <<_ACEOF
34085 /* confdefs.h.  */
34086 _ACEOF
34087 cat confdefs.h >>conftest.$ac_ext
34088 cat >>conftest.$ac_ext <<_ACEOF
34089 /* end confdefs.h.  */
34090 $ac_includes_default
34091 int
34092 main ()
34093 {
34094 static int test_array [1 - 2 * !(((long) (sizeof (short))) >= $ac_mid)];
34095 test_array [0] = 0
34096
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_lo=$ac_mid; break
34124 else
34125   echo "$as_me: failed program was:" >&5
34126 sed 's/^/| /' conftest.$ac_ext >&5
34127
34128 ac_hi=`expr '(' $ac_mid ')' - 1`
34129                        if test $ac_mid -le $ac_hi; then
34130                          ac_lo= ac_hi=
34131                          break
34132                        fi
34133                        ac_mid=`expr 2 '*' $ac_mid`
34134 fi
34135 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34136   done
34137 else
34138   echo "$as_me: failed program was:" >&5
34139 sed 's/^/| /' conftest.$ac_ext >&5
34140
34141 ac_lo= ac_hi=
34142 fi
34143 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34144 fi
34145 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34146 # Binary search between lo and hi bounds.
34147 while test "x$ac_lo" != "x$ac_hi"; do
34148   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
34149   cat >conftest.$ac_ext <<_ACEOF
34150 /* confdefs.h.  */
34151 _ACEOF
34152 cat confdefs.h >>conftest.$ac_ext
34153 cat >>conftest.$ac_ext <<_ACEOF
34154 /* end confdefs.h.  */
34155 $ac_includes_default
34156 int
34157 main ()
34158 {
34159 static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
34160 test_array [0] = 0
34161
34162   ;
34163   return 0;
34164 }
34165 _ACEOF
34166 rm -f conftest.$ac_objext
34167 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34168   (eval $ac_compile) 2>conftest.er1
34169   ac_status=$?
34170   grep -v '^ *+' conftest.er1 >conftest.err
34171   rm -f conftest.er1
34172   cat conftest.err >&5
34173   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34174   (exit $ac_status); } &&
34175          { ac_try='test -z "$ac_c_werror_flag"
34176                          || test ! -s conftest.err'
34177   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34178   (eval $ac_try) 2>&5
34179   ac_status=$?
34180   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34181   (exit $ac_status); }; } &&
34182          { ac_try='test -s conftest.$ac_objext'
34183   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34184   (eval $ac_try) 2>&5
34185   ac_status=$?
34186   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34187   (exit $ac_status); }; }; then
34188   ac_hi=$ac_mid
34189 else
34190   echo "$as_me: failed program was:" >&5
34191 sed 's/^/| /' conftest.$ac_ext >&5
34192
34193 ac_lo=`expr '(' $ac_mid ')' + 1`
34194 fi
34195 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34196 done
34197 case $ac_lo in
34198 ?*) ac_cv_sizeof_short=$ac_lo;;
34199 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
34200 See \`config.log' for more details." >&5
34201 echo "$as_me: error: cannot compute sizeof (short), 77
34202 See \`config.log' for more details." >&2;}
34203    { (exit 1); exit 1; }; } ;;
34204 esac
34205 else
34206   if test "$cross_compiling" = yes; then
34207   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
34208 See \`config.log' for more details." >&5
34209 echo "$as_me: error: cannot run test program while cross compiling
34210 See \`config.log' for more details." >&2;}
34211    { (exit 1); exit 1; }; }
34212 else
34213   cat >conftest.$ac_ext <<_ACEOF
34214 /* confdefs.h.  */
34215 _ACEOF
34216 cat confdefs.h >>conftest.$ac_ext
34217 cat >>conftest.$ac_ext <<_ACEOF
34218 /* end confdefs.h.  */
34219 $ac_includes_default
34220 long longval () { return (long) (sizeof (short)); }
34221 unsigned long ulongval () { return (long) (sizeof (short)); }
34222 #include <stdio.h>
34223 #include <stdlib.h>
34224 int
34225 main ()
34226 {
34227
34228   FILE *f = fopen ("conftest.val", "w");
34229   if (! f)
34230     exit (1);
34231   if (((long) (sizeof (short))) < 0)
34232     {
34233       long i = longval ();
34234       if (i != ((long) (sizeof (short))))
34235         exit (1);
34236       fprintf (f, "%ld\n", i);
34237     }
34238   else
34239     {
34240       unsigned long i = ulongval ();
34241       if (i != ((long) (sizeof (short))))
34242         exit (1);
34243       fprintf (f, "%lu\n", i);
34244     }
34245   exit (ferror (f) || fclose (f) != 0);
34246
34247   ;
34248   return 0;
34249 }
34250 _ACEOF
34251 rm -f conftest$ac_exeext
34252 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
34253   (eval $ac_link) 2>&5
34254   ac_status=$?
34255   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34256   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
34257   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34258   (eval $ac_try) 2>&5
34259   ac_status=$?
34260   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34261   (exit $ac_status); }; }; then
34262   ac_cv_sizeof_short=`cat conftest.val`
34263 else
34264   echo "$as_me: program exited with status $ac_status" >&5
34265 echo "$as_me: failed program was:" >&5
34266 sed 's/^/| /' conftest.$ac_ext >&5
34267
34268 ( exit $ac_status )
34269 { { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
34270 See \`config.log' for more details." >&5
34271 echo "$as_me: error: cannot compute sizeof (short), 77
34272 See \`config.log' for more details." >&2;}
34273    { (exit 1); exit 1; }; }
34274 fi
34275 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
34276 fi
34277 fi
34278 rm -f conftest.val
34279 else
34280   ac_cv_sizeof_short=0
34281 fi
34282 fi
34283 echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
34284 echo "${ECHO_T}$ac_cv_sizeof_short" >&6
34285 cat >>confdefs.h <<_ACEOF
34286 #define SIZEOF_SHORT $ac_cv_sizeof_short
34287 _ACEOF
34288
34289
34290 echo "$as_me:$LINENO: checking for int" >&5
34291 echo $ECHO_N "checking for int... $ECHO_C" >&6
34292 if test "${ac_cv_type_int+set}" = set; then
34293   echo $ECHO_N "(cached) $ECHO_C" >&6
34294 else
34295   cat >conftest.$ac_ext <<_ACEOF
34296 /* confdefs.h.  */
34297 _ACEOF
34298 cat confdefs.h >>conftest.$ac_ext
34299 cat >>conftest.$ac_ext <<_ACEOF
34300 /* end confdefs.h.  */
34301 $ac_includes_default
34302 int
34303 main ()
34304 {
34305 if ((int *) 0)
34306   return 0;
34307 if (sizeof (int))
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_int=yes
34336 else
34337   echo "$as_me: failed program was:" >&5
34338 sed 's/^/| /' conftest.$ac_ext >&5
34339
34340 ac_cv_type_int=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_int" >&5
34345 echo "${ECHO_T}$ac_cv_type_int" >&6
34346
34347 echo "$as_me:$LINENO: checking size of int" >&5
34348 echo $ECHO_N "checking size of int... $ECHO_C" >&6
34349 if test "${ac_cv_sizeof_int+set}" = set; then
34350   echo $ECHO_N "(cached) $ECHO_C" >&6
34351 else
34352   if test "$ac_cv_type_int" = yes; then
34353   # The cast to unsigned long works around a bug in the HP C Compiler
34354   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
34355   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
34356   # This bug is HP SR number 8606223364.
34357   if test "$cross_compiling" = yes; then
34358   # Depending upon the size, compute the lo and hi bounds.
34359 cat >conftest.$ac_ext <<_ACEOF
34360 /* confdefs.h.  */
34361 _ACEOF
34362 cat confdefs.h >>conftest.$ac_ext
34363 cat >>conftest.$ac_ext <<_ACEOF
34364 /* end confdefs.h.  */
34365 $ac_includes_default
34366 int
34367 main ()
34368 {
34369 static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
34370 test_array [0] = 0
34371
34372   ;
34373   return 0;
34374 }
34375 _ACEOF
34376 rm -f conftest.$ac_objext
34377 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34378   (eval $ac_compile) 2>conftest.er1
34379   ac_status=$?
34380   grep -v '^ *+' conftest.er1 >conftest.err
34381   rm -f conftest.er1
34382   cat conftest.err >&5
34383   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34384   (exit $ac_status); } &&
34385          { ac_try='test -z "$ac_c_werror_flag"
34386                          || test ! -s conftest.err'
34387   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34388   (eval $ac_try) 2>&5
34389   ac_status=$?
34390   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34391   (exit $ac_status); }; } &&
34392          { ac_try='test -s conftest.$ac_objext'
34393   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34394   (eval $ac_try) 2>&5
34395   ac_status=$?
34396   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34397   (exit $ac_status); }; }; then
34398   ac_lo=0 ac_mid=0
34399   while :; do
34400     cat >conftest.$ac_ext <<_ACEOF
34401 /* confdefs.h.  */
34402 _ACEOF
34403 cat confdefs.h >>conftest.$ac_ext
34404 cat >>conftest.$ac_ext <<_ACEOF
34405 /* end confdefs.h.  */
34406 $ac_includes_default
34407 int
34408 main ()
34409 {
34410 static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
34411 test_array [0] = 0
34412
34413   ;
34414   return 0;
34415 }
34416 _ACEOF
34417 rm -f conftest.$ac_objext
34418 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34419   (eval $ac_compile) 2>conftest.er1
34420   ac_status=$?
34421   grep -v '^ *+' conftest.er1 >conftest.err
34422   rm -f conftest.er1
34423   cat conftest.err >&5
34424   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34425   (exit $ac_status); } &&
34426          { ac_try='test -z "$ac_c_werror_flag"
34427                          || test ! -s conftest.err'
34428   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34429   (eval $ac_try) 2>&5
34430   ac_status=$?
34431   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34432   (exit $ac_status); }; } &&
34433          { ac_try='test -s conftest.$ac_objext'
34434   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34435   (eval $ac_try) 2>&5
34436   ac_status=$?
34437   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34438   (exit $ac_status); }; }; then
34439   ac_hi=$ac_mid; break
34440 else
34441   echo "$as_me: failed program was:" >&5
34442 sed 's/^/| /' conftest.$ac_ext >&5
34443
34444 ac_lo=`expr $ac_mid + 1`
34445                     if test $ac_lo -le $ac_mid; then
34446                       ac_lo= ac_hi=
34447                       break
34448                     fi
34449                     ac_mid=`expr 2 '*' $ac_mid + 1`
34450 fi
34451 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34452   done
34453 else
34454   echo "$as_me: failed program was:" >&5
34455 sed 's/^/| /' conftest.$ac_ext >&5
34456
34457 cat >conftest.$ac_ext <<_ACEOF
34458 /* confdefs.h.  */
34459 _ACEOF
34460 cat confdefs.h >>conftest.$ac_ext
34461 cat >>conftest.$ac_ext <<_ACEOF
34462 /* end confdefs.h.  */
34463 $ac_includes_default
34464 int
34465 main ()
34466 {
34467 static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
34468 test_array [0] = 0
34469
34470   ;
34471   return 0;
34472 }
34473 _ACEOF
34474 rm -f conftest.$ac_objext
34475 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34476   (eval $ac_compile) 2>conftest.er1
34477   ac_status=$?
34478   grep -v '^ *+' conftest.er1 >conftest.err
34479   rm -f conftest.er1
34480   cat conftest.err >&5
34481   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34482   (exit $ac_status); } &&
34483          { ac_try='test -z "$ac_c_werror_flag"
34484                          || test ! -s conftest.err'
34485   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34486   (eval $ac_try) 2>&5
34487   ac_status=$?
34488   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34489   (exit $ac_status); }; } &&
34490          { ac_try='test -s conftest.$ac_objext'
34491   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34492   (eval $ac_try) 2>&5
34493   ac_status=$?
34494   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34495   (exit $ac_status); }; }; then
34496   ac_hi=-1 ac_mid=-1
34497   while :; do
34498     cat >conftest.$ac_ext <<_ACEOF
34499 /* confdefs.h.  */
34500 _ACEOF
34501 cat confdefs.h >>conftest.$ac_ext
34502 cat >>conftest.$ac_ext <<_ACEOF
34503 /* end confdefs.h.  */
34504 $ac_includes_default
34505 int
34506 main ()
34507 {
34508 static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
34509 test_array [0] = 0
34510
34511   ;
34512   return 0;
34513 }
34514 _ACEOF
34515 rm -f conftest.$ac_objext
34516 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34517   (eval $ac_compile) 2>conftest.er1
34518   ac_status=$?
34519   grep -v '^ *+' conftest.er1 >conftest.err
34520   rm -f conftest.er1
34521   cat conftest.err >&5
34522   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34523   (exit $ac_status); } &&
34524          { ac_try='test -z "$ac_c_werror_flag"
34525                          || test ! -s conftest.err'
34526   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34527   (eval $ac_try) 2>&5
34528   ac_status=$?
34529   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34530   (exit $ac_status); }; } &&
34531          { ac_try='test -s conftest.$ac_objext'
34532   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34533   (eval $ac_try) 2>&5
34534   ac_status=$?
34535   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34536   (exit $ac_status); }; }; then
34537   ac_lo=$ac_mid; break
34538 else
34539   echo "$as_me: failed program was:" >&5
34540 sed 's/^/| /' conftest.$ac_ext >&5
34541
34542 ac_hi=`expr '(' $ac_mid ')' - 1`
34543                        if test $ac_mid -le $ac_hi; then
34544                          ac_lo= ac_hi=
34545                          break
34546                        fi
34547                        ac_mid=`expr 2 '*' $ac_mid`
34548 fi
34549 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34550   done
34551 else
34552   echo "$as_me: failed program was:" >&5
34553 sed 's/^/| /' conftest.$ac_ext >&5
34554
34555 ac_lo= ac_hi=
34556 fi
34557 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34558 fi
34559 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34560 # Binary search between lo and hi bounds.
34561 while test "x$ac_lo" != "x$ac_hi"; do
34562   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
34563   cat >conftest.$ac_ext <<_ACEOF
34564 /* confdefs.h.  */
34565 _ACEOF
34566 cat confdefs.h >>conftest.$ac_ext
34567 cat >>conftest.$ac_ext <<_ACEOF
34568 /* end confdefs.h.  */
34569 $ac_includes_default
34570 int
34571 main ()
34572 {
34573 static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
34574 test_array [0] = 0
34575
34576   ;
34577   return 0;
34578 }
34579 _ACEOF
34580 rm -f conftest.$ac_objext
34581 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34582   (eval $ac_compile) 2>conftest.er1
34583   ac_status=$?
34584   grep -v '^ *+' conftest.er1 >conftest.err
34585   rm -f conftest.er1
34586   cat conftest.err >&5
34587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34588   (exit $ac_status); } &&
34589          { ac_try='test -z "$ac_c_werror_flag"
34590                          || test ! -s conftest.err'
34591   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34592   (eval $ac_try) 2>&5
34593   ac_status=$?
34594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34595   (exit $ac_status); }; } &&
34596          { ac_try='test -s conftest.$ac_objext'
34597   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34598   (eval $ac_try) 2>&5
34599   ac_status=$?
34600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34601   (exit $ac_status); }; }; then
34602   ac_hi=$ac_mid
34603 else
34604   echo "$as_me: failed program was:" >&5
34605 sed 's/^/| /' conftest.$ac_ext >&5
34606
34607 ac_lo=`expr '(' $ac_mid ')' + 1`
34608 fi
34609 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34610 done
34611 case $ac_lo in
34612 ?*) ac_cv_sizeof_int=$ac_lo;;
34613 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
34614 See \`config.log' for more details." >&5
34615 echo "$as_me: error: cannot compute sizeof (int), 77
34616 See \`config.log' for more details." >&2;}
34617    { (exit 1); exit 1; }; } ;;
34618 esac
34619 else
34620   if test "$cross_compiling" = yes; then
34621   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
34622 See \`config.log' for more details." >&5
34623 echo "$as_me: error: cannot run test program while cross compiling
34624 See \`config.log' for more details." >&2;}
34625    { (exit 1); exit 1; }; }
34626 else
34627   cat >conftest.$ac_ext <<_ACEOF
34628 /* confdefs.h.  */
34629 _ACEOF
34630 cat confdefs.h >>conftest.$ac_ext
34631 cat >>conftest.$ac_ext <<_ACEOF
34632 /* end confdefs.h.  */
34633 $ac_includes_default
34634 long longval () { return (long) (sizeof (int)); }
34635 unsigned long ulongval () { return (long) (sizeof (int)); }
34636 #include <stdio.h>
34637 #include <stdlib.h>
34638 int
34639 main ()
34640 {
34641
34642   FILE *f = fopen ("conftest.val", "w");
34643   if (! f)
34644     exit (1);
34645   if (((long) (sizeof (int))) < 0)
34646     {
34647       long i = longval ();
34648       if (i != ((long) (sizeof (int))))
34649         exit (1);
34650       fprintf (f, "%ld\n", i);
34651     }
34652   else
34653     {
34654       unsigned long i = ulongval ();
34655       if (i != ((long) (sizeof (int))))
34656         exit (1);
34657       fprintf (f, "%lu\n", i);
34658     }
34659   exit (ferror (f) || fclose (f) != 0);
34660
34661   ;
34662   return 0;
34663 }
34664 _ACEOF
34665 rm -f conftest$ac_exeext
34666 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
34667   (eval $ac_link) 2>&5
34668   ac_status=$?
34669   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34670   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
34671   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34672   (eval $ac_try) 2>&5
34673   ac_status=$?
34674   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34675   (exit $ac_status); }; }; then
34676   ac_cv_sizeof_int=`cat conftest.val`
34677 else
34678   echo "$as_me: program exited with status $ac_status" >&5
34679 echo "$as_me: failed program was:" >&5
34680 sed 's/^/| /' conftest.$ac_ext >&5
34681
34682 ( exit $ac_status )
34683 { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
34684 See \`config.log' for more details." >&5
34685 echo "$as_me: error: cannot compute sizeof (int), 77
34686 See \`config.log' for more details." >&2;}
34687    { (exit 1); exit 1; }; }
34688 fi
34689 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
34690 fi
34691 fi
34692 rm -f conftest.val
34693 else
34694   ac_cv_sizeof_int=0
34695 fi
34696 fi
34697 echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
34698 echo "${ECHO_T}$ac_cv_sizeof_int" >&6
34699 cat >>confdefs.h <<_ACEOF
34700 #define SIZEOF_INT $ac_cv_sizeof_int
34701 _ACEOF
34702
34703
34704 echo "$as_me:$LINENO: checking for long" >&5
34705 echo $ECHO_N "checking for long... $ECHO_C" >&6
34706 if test "${ac_cv_type_long+set}" = set; then
34707   echo $ECHO_N "(cached) $ECHO_C" >&6
34708 else
34709   cat >conftest.$ac_ext <<_ACEOF
34710 /* confdefs.h.  */
34711 _ACEOF
34712 cat confdefs.h >>conftest.$ac_ext
34713 cat >>conftest.$ac_ext <<_ACEOF
34714 /* end confdefs.h.  */
34715 $ac_includes_default
34716 int
34717 main ()
34718 {
34719 if ((long *) 0)
34720   return 0;
34721 if (sizeof (long))
34722   return 0;
34723   ;
34724   return 0;
34725 }
34726 _ACEOF
34727 rm -f conftest.$ac_objext
34728 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34729   (eval $ac_compile) 2>conftest.er1
34730   ac_status=$?
34731   grep -v '^ *+' conftest.er1 >conftest.err
34732   rm -f conftest.er1
34733   cat conftest.err >&5
34734   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34735   (exit $ac_status); } &&
34736          { ac_try='test -z "$ac_c_werror_flag"
34737                          || test ! -s conftest.err'
34738   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34739   (eval $ac_try) 2>&5
34740   ac_status=$?
34741   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34742   (exit $ac_status); }; } &&
34743          { ac_try='test -s conftest.$ac_objext'
34744   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34745   (eval $ac_try) 2>&5
34746   ac_status=$?
34747   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34748   (exit $ac_status); }; }; then
34749   ac_cv_type_long=yes
34750 else
34751   echo "$as_me: failed program was:" >&5
34752 sed 's/^/| /' conftest.$ac_ext >&5
34753
34754 ac_cv_type_long=no
34755 fi
34756 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34757 fi
34758 echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
34759 echo "${ECHO_T}$ac_cv_type_long" >&6
34760
34761 echo "$as_me:$LINENO: checking size of long" >&5
34762 echo $ECHO_N "checking size of long... $ECHO_C" >&6
34763 if test "${ac_cv_sizeof_long+set}" = set; then
34764   echo $ECHO_N "(cached) $ECHO_C" >&6
34765 else
34766   if test "$ac_cv_type_long" = yes; then
34767   # The cast to unsigned long works around a bug in the HP C Compiler
34768   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
34769   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
34770   # This bug is HP SR number 8606223364.
34771   if test "$cross_compiling" = yes; then
34772   # Depending upon the size, compute the lo and hi bounds.
34773 cat >conftest.$ac_ext <<_ACEOF
34774 /* confdefs.h.  */
34775 _ACEOF
34776 cat confdefs.h >>conftest.$ac_ext
34777 cat >>conftest.$ac_ext <<_ACEOF
34778 /* end confdefs.h.  */
34779 $ac_includes_default
34780 int
34781 main ()
34782 {
34783 static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
34784 test_array [0] = 0
34785
34786   ;
34787   return 0;
34788 }
34789 _ACEOF
34790 rm -f conftest.$ac_objext
34791 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34792   (eval $ac_compile) 2>conftest.er1
34793   ac_status=$?
34794   grep -v '^ *+' conftest.er1 >conftest.err
34795   rm -f conftest.er1
34796   cat conftest.err >&5
34797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34798   (exit $ac_status); } &&
34799          { ac_try='test -z "$ac_c_werror_flag"
34800                          || test ! -s conftest.err'
34801   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34802   (eval $ac_try) 2>&5
34803   ac_status=$?
34804   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34805   (exit $ac_status); }; } &&
34806          { ac_try='test -s conftest.$ac_objext'
34807   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34808   (eval $ac_try) 2>&5
34809   ac_status=$?
34810   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34811   (exit $ac_status); }; }; then
34812   ac_lo=0 ac_mid=0
34813   while :; do
34814     cat >conftest.$ac_ext <<_ACEOF
34815 /* confdefs.h.  */
34816 _ACEOF
34817 cat confdefs.h >>conftest.$ac_ext
34818 cat >>conftest.$ac_ext <<_ACEOF
34819 /* end confdefs.h.  */
34820 $ac_includes_default
34821 int
34822 main ()
34823 {
34824 static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
34825 test_array [0] = 0
34826
34827   ;
34828   return 0;
34829 }
34830 _ACEOF
34831 rm -f conftest.$ac_objext
34832 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34833   (eval $ac_compile) 2>conftest.er1
34834   ac_status=$?
34835   grep -v '^ *+' conftest.er1 >conftest.err
34836   rm -f conftest.er1
34837   cat conftest.err >&5
34838   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34839   (exit $ac_status); } &&
34840          { ac_try='test -z "$ac_c_werror_flag"
34841                          || test ! -s conftest.err'
34842   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34843   (eval $ac_try) 2>&5
34844   ac_status=$?
34845   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34846   (exit $ac_status); }; } &&
34847          { ac_try='test -s conftest.$ac_objext'
34848   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34849   (eval $ac_try) 2>&5
34850   ac_status=$?
34851   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34852   (exit $ac_status); }; }; then
34853   ac_hi=$ac_mid; break
34854 else
34855   echo "$as_me: failed program was:" >&5
34856 sed 's/^/| /' conftest.$ac_ext >&5
34857
34858 ac_lo=`expr $ac_mid + 1`
34859                     if test $ac_lo -le $ac_mid; then
34860                       ac_lo= ac_hi=
34861                       break
34862                     fi
34863                     ac_mid=`expr 2 '*' $ac_mid + 1`
34864 fi
34865 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34866   done
34867 else
34868   echo "$as_me: failed program was:" >&5
34869 sed 's/^/| /' conftest.$ac_ext >&5
34870
34871 cat >conftest.$ac_ext <<_ACEOF
34872 /* confdefs.h.  */
34873 _ACEOF
34874 cat confdefs.h >>conftest.$ac_ext
34875 cat >>conftest.$ac_ext <<_ACEOF
34876 /* end confdefs.h.  */
34877 $ac_includes_default
34878 int
34879 main ()
34880 {
34881 static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
34882 test_array [0] = 0
34883
34884   ;
34885   return 0;
34886 }
34887 _ACEOF
34888 rm -f conftest.$ac_objext
34889 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34890   (eval $ac_compile) 2>conftest.er1
34891   ac_status=$?
34892   grep -v '^ *+' conftest.er1 >conftest.err
34893   rm -f conftest.er1
34894   cat conftest.err >&5
34895   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34896   (exit $ac_status); } &&
34897          { ac_try='test -z "$ac_c_werror_flag"
34898                          || test ! -s conftest.err'
34899   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34900   (eval $ac_try) 2>&5
34901   ac_status=$?
34902   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34903   (exit $ac_status); }; } &&
34904          { ac_try='test -s conftest.$ac_objext'
34905   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34906   (eval $ac_try) 2>&5
34907   ac_status=$?
34908   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34909   (exit $ac_status); }; }; then
34910   ac_hi=-1 ac_mid=-1
34911   while :; do
34912     cat >conftest.$ac_ext <<_ACEOF
34913 /* confdefs.h.  */
34914 _ACEOF
34915 cat confdefs.h >>conftest.$ac_ext
34916 cat >>conftest.$ac_ext <<_ACEOF
34917 /* end confdefs.h.  */
34918 $ac_includes_default
34919 int
34920 main ()
34921 {
34922 static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
34923 test_array [0] = 0
34924
34925   ;
34926   return 0;
34927 }
34928 _ACEOF
34929 rm -f conftest.$ac_objext
34930 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34931   (eval $ac_compile) 2>conftest.er1
34932   ac_status=$?
34933   grep -v '^ *+' conftest.er1 >conftest.err
34934   rm -f conftest.er1
34935   cat conftest.err >&5
34936   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34937   (exit $ac_status); } &&
34938          { ac_try='test -z "$ac_c_werror_flag"
34939                          || test ! -s conftest.err'
34940   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34941   (eval $ac_try) 2>&5
34942   ac_status=$?
34943   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34944   (exit $ac_status); }; } &&
34945          { ac_try='test -s conftest.$ac_objext'
34946   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
34947   (eval $ac_try) 2>&5
34948   ac_status=$?
34949   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34950   (exit $ac_status); }; }; then
34951   ac_lo=$ac_mid; break
34952 else
34953   echo "$as_me: failed program was:" >&5
34954 sed 's/^/| /' conftest.$ac_ext >&5
34955
34956 ac_hi=`expr '(' $ac_mid ')' - 1`
34957                        if test $ac_mid -le $ac_hi; then
34958                          ac_lo= ac_hi=
34959                          break
34960                        fi
34961                        ac_mid=`expr 2 '*' $ac_mid`
34962 fi
34963 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34964   done
34965 else
34966   echo "$as_me: failed program was:" >&5
34967 sed 's/^/| /' conftest.$ac_ext >&5
34968
34969 ac_lo= ac_hi=
34970 fi
34971 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34972 fi
34973 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
34974 # Binary search between lo and hi bounds.
34975 while test "x$ac_lo" != "x$ac_hi"; do
34976   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
34977   cat >conftest.$ac_ext <<_ACEOF
34978 /* confdefs.h.  */
34979 _ACEOF
34980 cat confdefs.h >>conftest.$ac_ext
34981 cat >>conftest.$ac_ext <<_ACEOF
34982 /* end confdefs.h.  */
34983 $ac_includes_default
34984 int
34985 main ()
34986 {
34987 static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
34988 test_array [0] = 0
34989
34990   ;
34991   return 0;
34992 }
34993 _ACEOF
34994 rm -f conftest.$ac_objext
34995 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
34996   (eval $ac_compile) 2>conftest.er1
34997   ac_status=$?
34998   grep -v '^ *+' conftest.er1 >conftest.err
34999   rm -f conftest.er1
35000   cat conftest.err >&5
35001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35002   (exit $ac_status); } &&
35003          { ac_try='test -z "$ac_c_werror_flag"
35004                          || test ! -s conftest.err'
35005   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35006   (eval $ac_try) 2>&5
35007   ac_status=$?
35008   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35009   (exit $ac_status); }; } &&
35010          { ac_try='test -s conftest.$ac_objext'
35011   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35012   (eval $ac_try) 2>&5
35013   ac_status=$?
35014   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35015   (exit $ac_status); }; }; then
35016   ac_hi=$ac_mid
35017 else
35018   echo "$as_me: failed program was:" >&5
35019 sed 's/^/| /' conftest.$ac_ext >&5
35020
35021 ac_lo=`expr '(' $ac_mid ')' + 1`
35022 fi
35023 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35024 done
35025 case $ac_lo in
35026 ?*) ac_cv_sizeof_long=$ac_lo;;
35027 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
35028 See \`config.log' for more details." >&5
35029 echo "$as_me: error: cannot compute sizeof (long), 77
35030 See \`config.log' for more details." >&2;}
35031    { (exit 1); exit 1; }; } ;;
35032 esac
35033 else
35034   if test "$cross_compiling" = yes; then
35035   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
35036 See \`config.log' for more details." >&5
35037 echo "$as_me: error: cannot run test program while cross compiling
35038 See \`config.log' for more details." >&2;}
35039    { (exit 1); exit 1; }; }
35040 else
35041   cat >conftest.$ac_ext <<_ACEOF
35042 /* confdefs.h.  */
35043 _ACEOF
35044 cat confdefs.h >>conftest.$ac_ext
35045 cat >>conftest.$ac_ext <<_ACEOF
35046 /* end confdefs.h.  */
35047 $ac_includes_default
35048 long longval () { return (long) (sizeof (long)); }
35049 unsigned long ulongval () { return (long) (sizeof (long)); }
35050 #include <stdio.h>
35051 #include <stdlib.h>
35052 int
35053 main ()
35054 {
35055
35056   FILE *f = fopen ("conftest.val", "w");
35057   if (! f)
35058     exit (1);
35059   if (((long) (sizeof (long))) < 0)
35060     {
35061       long i = longval ();
35062       if (i != ((long) (sizeof (long))))
35063         exit (1);
35064       fprintf (f, "%ld\n", i);
35065     }
35066   else
35067     {
35068       unsigned long i = ulongval ();
35069       if (i != ((long) (sizeof (long))))
35070         exit (1);
35071       fprintf (f, "%lu\n", i);
35072     }
35073   exit (ferror (f) || fclose (f) != 0);
35074
35075   ;
35076   return 0;
35077 }
35078 _ACEOF
35079 rm -f conftest$ac_exeext
35080 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35081   (eval $ac_link) 2>&5
35082   ac_status=$?
35083   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35084   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
35085   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35086   (eval $ac_try) 2>&5
35087   ac_status=$?
35088   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35089   (exit $ac_status); }; }; then
35090   ac_cv_sizeof_long=`cat conftest.val`
35091 else
35092   echo "$as_me: program exited with status $ac_status" >&5
35093 echo "$as_me: failed program was:" >&5
35094 sed 's/^/| /' conftest.$ac_ext >&5
35095
35096 ( exit $ac_status )
35097 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
35098 See \`config.log' for more details." >&5
35099 echo "$as_me: error: cannot compute sizeof (long), 77
35100 See \`config.log' for more details." >&2;}
35101    { (exit 1); exit 1; }; }
35102 fi
35103 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
35104 fi
35105 fi
35106 rm -f conftest.val
35107 else
35108   ac_cv_sizeof_long=0
35109 fi
35110 fi
35111 echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
35112 echo "${ECHO_T}$ac_cv_sizeof_long" >&6
35113 cat >>confdefs.h <<_ACEOF
35114 #define SIZEOF_LONG $ac_cv_sizeof_long
35115 _ACEOF
35116
35117
35118 echo "$as_me:$LINENO: checking for long long" >&5
35119 echo $ECHO_N "checking for long long... $ECHO_C" >&6
35120 if test "${ac_cv_type_long_long+set}" = set; then
35121   echo $ECHO_N "(cached) $ECHO_C" >&6
35122 else
35123   cat >conftest.$ac_ext <<_ACEOF
35124 /* confdefs.h.  */
35125 _ACEOF
35126 cat confdefs.h >>conftest.$ac_ext
35127 cat >>conftest.$ac_ext <<_ACEOF
35128 /* end confdefs.h.  */
35129 $ac_includes_default
35130 int
35131 main ()
35132 {
35133 if ((long long *) 0)
35134   return 0;
35135 if (sizeof (long long))
35136   return 0;
35137   ;
35138   return 0;
35139 }
35140 _ACEOF
35141 rm -f conftest.$ac_objext
35142 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35143   (eval $ac_compile) 2>conftest.er1
35144   ac_status=$?
35145   grep -v '^ *+' conftest.er1 >conftest.err
35146   rm -f conftest.er1
35147   cat conftest.err >&5
35148   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35149   (exit $ac_status); } &&
35150          { ac_try='test -z "$ac_c_werror_flag"
35151                          || test ! -s conftest.err'
35152   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35153   (eval $ac_try) 2>&5
35154   ac_status=$?
35155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35156   (exit $ac_status); }; } &&
35157          { ac_try='test -s conftest.$ac_objext'
35158   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35159   (eval $ac_try) 2>&5
35160   ac_status=$?
35161   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35162   (exit $ac_status); }; }; then
35163   ac_cv_type_long_long=yes
35164 else
35165   echo "$as_me: failed program was:" >&5
35166 sed 's/^/| /' conftest.$ac_ext >&5
35167
35168 ac_cv_type_long_long=no
35169 fi
35170 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35171 fi
35172 echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
35173 echo "${ECHO_T}$ac_cv_type_long_long" >&6
35174
35175 echo "$as_me:$LINENO: checking size of long long" >&5
35176 echo $ECHO_N "checking size of long long... $ECHO_C" >&6
35177 if test "${ac_cv_sizeof_long_long+set}" = set; then
35178   echo $ECHO_N "(cached) $ECHO_C" >&6
35179 else
35180   if test "$ac_cv_type_long_long" = yes; then
35181   # The cast to unsigned long works around a bug in the HP C Compiler
35182   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
35183   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
35184   # This bug is HP SR number 8606223364.
35185   if test "$cross_compiling" = yes; then
35186   # Depending upon the size, compute the lo and hi bounds.
35187 cat >conftest.$ac_ext <<_ACEOF
35188 /* confdefs.h.  */
35189 _ACEOF
35190 cat confdefs.h >>conftest.$ac_ext
35191 cat >>conftest.$ac_ext <<_ACEOF
35192 /* end confdefs.h.  */
35193 $ac_includes_default
35194 int
35195 main ()
35196 {
35197 static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= 0)];
35198 test_array [0] = 0
35199
35200   ;
35201   return 0;
35202 }
35203 _ACEOF
35204 rm -f conftest.$ac_objext
35205 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35206   (eval $ac_compile) 2>conftest.er1
35207   ac_status=$?
35208   grep -v '^ *+' conftest.er1 >conftest.err
35209   rm -f conftest.er1
35210   cat conftest.err >&5
35211   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35212   (exit $ac_status); } &&
35213          { ac_try='test -z "$ac_c_werror_flag"
35214                          || test ! -s conftest.err'
35215   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35216   (eval $ac_try) 2>&5
35217   ac_status=$?
35218   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35219   (exit $ac_status); }; } &&
35220          { ac_try='test -s conftest.$ac_objext'
35221   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35222   (eval $ac_try) 2>&5
35223   ac_status=$?
35224   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35225   (exit $ac_status); }; }; then
35226   ac_lo=0 ac_mid=0
35227   while :; do
35228     cat >conftest.$ac_ext <<_ACEOF
35229 /* confdefs.h.  */
35230 _ACEOF
35231 cat confdefs.h >>conftest.$ac_ext
35232 cat >>conftest.$ac_ext <<_ACEOF
35233 /* end confdefs.h.  */
35234 $ac_includes_default
35235 int
35236 main ()
35237 {
35238 static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
35239 test_array [0] = 0
35240
35241   ;
35242   return 0;
35243 }
35244 _ACEOF
35245 rm -f conftest.$ac_objext
35246 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35247   (eval $ac_compile) 2>conftest.er1
35248   ac_status=$?
35249   grep -v '^ *+' conftest.er1 >conftest.err
35250   rm -f conftest.er1
35251   cat conftest.err >&5
35252   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35253   (exit $ac_status); } &&
35254          { ac_try='test -z "$ac_c_werror_flag"
35255                          || test ! -s conftest.err'
35256   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35257   (eval $ac_try) 2>&5
35258   ac_status=$?
35259   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35260   (exit $ac_status); }; } &&
35261          { ac_try='test -s conftest.$ac_objext'
35262   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35263   (eval $ac_try) 2>&5
35264   ac_status=$?
35265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35266   (exit $ac_status); }; }; then
35267   ac_hi=$ac_mid; break
35268 else
35269   echo "$as_me: failed program was:" >&5
35270 sed 's/^/| /' conftest.$ac_ext >&5
35271
35272 ac_lo=`expr $ac_mid + 1`
35273                     if test $ac_lo -le $ac_mid; then
35274                       ac_lo= ac_hi=
35275                       break
35276                     fi
35277                     ac_mid=`expr 2 '*' $ac_mid + 1`
35278 fi
35279 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35280   done
35281 else
35282   echo "$as_me: failed program was:" >&5
35283 sed 's/^/| /' conftest.$ac_ext >&5
35284
35285 cat >conftest.$ac_ext <<_ACEOF
35286 /* confdefs.h.  */
35287 _ACEOF
35288 cat confdefs.h >>conftest.$ac_ext
35289 cat >>conftest.$ac_ext <<_ACEOF
35290 /* end confdefs.h.  */
35291 $ac_includes_default
35292 int
35293 main ()
35294 {
35295 static int test_array [1 - 2 * !(((long) (sizeof (long long))) < 0)];
35296 test_array [0] = 0
35297
35298   ;
35299   return 0;
35300 }
35301 _ACEOF
35302 rm -f conftest.$ac_objext
35303 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35304   (eval $ac_compile) 2>conftest.er1
35305   ac_status=$?
35306   grep -v '^ *+' conftest.er1 >conftest.err
35307   rm -f conftest.er1
35308   cat conftest.err >&5
35309   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35310   (exit $ac_status); } &&
35311          { ac_try='test -z "$ac_c_werror_flag"
35312                          || test ! -s conftest.err'
35313   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35314   (eval $ac_try) 2>&5
35315   ac_status=$?
35316   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35317   (exit $ac_status); }; } &&
35318          { ac_try='test -s conftest.$ac_objext'
35319   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35320   (eval $ac_try) 2>&5
35321   ac_status=$?
35322   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35323   (exit $ac_status); }; }; then
35324   ac_hi=-1 ac_mid=-1
35325   while :; do
35326     cat >conftest.$ac_ext <<_ACEOF
35327 /* confdefs.h.  */
35328 _ACEOF
35329 cat confdefs.h >>conftest.$ac_ext
35330 cat >>conftest.$ac_ext <<_ACEOF
35331 /* end confdefs.h.  */
35332 $ac_includes_default
35333 int
35334 main ()
35335 {
35336 static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= $ac_mid)];
35337 test_array [0] = 0
35338
35339   ;
35340   return 0;
35341 }
35342 _ACEOF
35343 rm -f conftest.$ac_objext
35344 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35345   (eval $ac_compile) 2>conftest.er1
35346   ac_status=$?
35347   grep -v '^ *+' conftest.er1 >conftest.err
35348   rm -f conftest.er1
35349   cat conftest.err >&5
35350   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35351   (exit $ac_status); } &&
35352          { ac_try='test -z "$ac_c_werror_flag"
35353                          || test ! -s conftest.err'
35354   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35355   (eval $ac_try) 2>&5
35356   ac_status=$?
35357   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35358   (exit $ac_status); }; } &&
35359          { ac_try='test -s conftest.$ac_objext'
35360   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35361   (eval $ac_try) 2>&5
35362   ac_status=$?
35363   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35364   (exit $ac_status); }; }; then
35365   ac_lo=$ac_mid; break
35366 else
35367   echo "$as_me: failed program was:" >&5
35368 sed 's/^/| /' conftest.$ac_ext >&5
35369
35370 ac_hi=`expr '(' $ac_mid ')' - 1`
35371                        if test $ac_mid -le $ac_hi; then
35372                          ac_lo= ac_hi=
35373                          break
35374                        fi
35375                        ac_mid=`expr 2 '*' $ac_mid`
35376 fi
35377 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35378   done
35379 else
35380   echo "$as_me: failed program was:" >&5
35381 sed 's/^/| /' conftest.$ac_ext >&5
35382
35383 ac_lo= ac_hi=
35384 fi
35385 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35386 fi
35387 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35388 # Binary search between lo and hi bounds.
35389 while test "x$ac_lo" != "x$ac_hi"; do
35390   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
35391   cat >conftest.$ac_ext <<_ACEOF
35392 /* confdefs.h.  */
35393 _ACEOF
35394 cat confdefs.h >>conftest.$ac_ext
35395 cat >>conftest.$ac_ext <<_ACEOF
35396 /* end confdefs.h.  */
35397 $ac_includes_default
35398 int
35399 main ()
35400 {
35401 static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
35402 test_array [0] = 0
35403
35404   ;
35405   return 0;
35406 }
35407 _ACEOF
35408 rm -f conftest.$ac_objext
35409 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35410   (eval $ac_compile) 2>conftest.er1
35411   ac_status=$?
35412   grep -v '^ *+' conftest.er1 >conftest.err
35413   rm -f conftest.er1
35414   cat conftest.err >&5
35415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35416   (exit $ac_status); } &&
35417          { ac_try='test -z "$ac_c_werror_flag"
35418                          || test ! -s conftest.err'
35419   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35420   (eval $ac_try) 2>&5
35421   ac_status=$?
35422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35423   (exit $ac_status); }; } &&
35424          { ac_try='test -s conftest.$ac_objext'
35425   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35426   (eval $ac_try) 2>&5
35427   ac_status=$?
35428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35429   (exit $ac_status); }; }; then
35430   ac_hi=$ac_mid
35431 else
35432   echo "$as_me: failed program was:" >&5
35433 sed 's/^/| /' conftest.$ac_ext >&5
35434
35435 ac_lo=`expr '(' $ac_mid ')' + 1`
35436 fi
35437 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35438 done
35439 case $ac_lo in
35440 ?*) ac_cv_sizeof_long_long=$ac_lo;;
35441 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
35442 See \`config.log' for more details." >&5
35443 echo "$as_me: error: cannot compute sizeof (long long), 77
35444 See \`config.log' for more details." >&2;}
35445    { (exit 1); exit 1; }; } ;;
35446 esac
35447 else
35448   if test "$cross_compiling" = yes; then
35449   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
35450 See \`config.log' for more details." >&5
35451 echo "$as_me: error: cannot run test program while cross compiling
35452 See \`config.log' for more details." >&2;}
35453    { (exit 1); exit 1; }; }
35454 else
35455   cat >conftest.$ac_ext <<_ACEOF
35456 /* confdefs.h.  */
35457 _ACEOF
35458 cat confdefs.h >>conftest.$ac_ext
35459 cat >>conftest.$ac_ext <<_ACEOF
35460 /* end confdefs.h.  */
35461 $ac_includes_default
35462 long longval () { return (long) (sizeof (long long)); }
35463 unsigned long ulongval () { return (long) (sizeof (long long)); }
35464 #include <stdio.h>
35465 #include <stdlib.h>
35466 int
35467 main ()
35468 {
35469
35470   FILE *f = fopen ("conftest.val", "w");
35471   if (! f)
35472     exit (1);
35473   if (((long) (sizeof (long long))) < 0)
35474     {
35475       long i = longval ();
35476       if (i != ((long) (sizeof (long long))))
35477         exit (1);
35478       fprintf (f, "%ld\n", i);
35479     }
35480   else
35481     {
35482       unsigned long i = ulongval ();
35483       if (i != ((long) (sizeof (long long))))
35484         exit (1);
35485       fprintf (f, "%lu\n", i);
35486     }
35487   exit (ferror (f) || fclose (f) != 0);
35488
35489   ;
35490   return 0;
35491 }
35492 _ACEOF
35493 rm -f conftest$ac_exeext
35494 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35495   (eval $ac_link) 2>&5
35496   ac_status=$?
35497   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35498   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
35499   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35500   (eval $ac_try) 2>&5
35501   ac_status=$?
35502   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35503   (exit $ac_status); }; }; then
35504   ac_cv_sizeof_long_long=`cat conftest.val`
35505 else
35506   echo "$as_me: program exited with status $ac_status" >&5
35507 echo "$as_me: failed program was:" >&5
35508 sed 's/^/| /' conftest.$ac_ext >&5
35509
35510 ( exit $ac_status )
35511 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
35512 See \`config.log' for more details." >&5
35513 echo "$as_me: error: cannot compute sizeof (long long), 77
35514 See \`config.log' for more details." >&2;}
35515    { (exit 1); exit 1; }; }
35516 fi
35517 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
35518 fi
35519 fi
35520 rm -f conftest.val
35521 else
35522   ac_cv_sizeof_long_long=0
35523 fi
35524 fi
35525 echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
35526 echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
35527 cat >>confdefs.h <<_ACEOF
35528 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
35529 _ACEOF
35530
35531
35532 echo "$as_me:$LINENO: checking for wchar_t" >&5
35533 echo $ECHO_N "checking for wchar_t... $ECHO_C" >&6
35534 if test "${ac_cv_type_wchar_t+set}" = set; then
35535   echo $ECHO_N "(cached) $ECHO_C" >&6
35536 else
35537   cat >conftest.$ac_ext <<_ACEOF
35538 /* confdefs.h.  */
35539 _ACEOF
35540 cat confdefs.h >>conftest.$ac_ext
35541 cat >>conftest.$ac_ext <<_ACEOF
35542 /* end confdefs.h.  */
35543 $ac_includes_default
35544 int
35545 main ()
35546 {
35547 if ((wchar_t *) 0)
35548   return 0;
35549 if (sizeof (wchar_t))
35550   return 0;
35551   ;
35552   return 0;
35553 }
35554 _ACEOF
35555 rm -f conftest.$ac_objext
35556 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35557   (eval $ac_compile) 2>conftest.er1
35558   ac_status=$?
35559   grep -v '^ *+' conftest.er1 >conftest.err
35560   rm -f conftest.er1
35561   cat conftest.err >&5
35562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35563   (exit $ac_status); } &&
35564          { ac_try='test -z "$ac_c_werror_flag"
35565                          || test ! -s conftest.err'
35566   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35567   (eval $ac_try) 2>&5
35568   ac_status=$?
35569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35570   (exit $ac_status); }; } &&
35571          { ac_try='test -s conftest.$ac_objext'
35572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35573   (eval $ac_try) 2>&5
35574   ac_status=$?
35575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35576   (exit $ac_status); }; }; then
35577   ac_cv_type_wchar_t=yes
35578 else
35579   echo "$as_me: failed program was:" >&5
35580 sed 's/^/| /' conftest.$ac_ext >&5
35581
35582 ac_cv_type_wchar_t=no
35583 fi
35584 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35585 fi
35586 echo "$as_me:$LINENO: result: $ac_cv_type_wchar_t" >&5
35587 echo "${ECHO_T}$ac_cv_type_wchar_t" >&6
35588
35589 echo "$as_me:$LINENO: checking size of wchar_t" >&5
35590 echo $ECHO_N "checking size of wchar_t... $ECHO_C" >&6
35591 if test "${ac_cv_sizeof_wchar_t+set}" = set; then
35592   echo $ECHO_N "(cached) $ECHO_C" >&6
35593 else
35594   if test "$ac_cv_type_wchar_t" = yes; then
35595   # The cast to unsigned long works around a bug in the HP C Compiler
35596   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
35597   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
35598   # This bug is HP SR number 8606223364.
35599   if test "$cross_compiling" = yes; then
35600   # Depending upon the size, compute the lo and hi bounds.
35601 cat >conftest.$ac_ext <<_ACEOF
35602 /* confdefs.h.  */
35603 _ACEOF
35604 cat confdefs.h >>conftest.$ac_ext
35605 cat >>conftest.$ac_ext <<_ACEOF
35606 /* end confdefs.h.  */
35607 $ac_includes_default
35608 int
35609 main ()
35610 {
35611 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= 0)];
35612 test_array [0] = 0
35613
35614   ;
35615   return 0;
35616 }
35617 _ACEOF
35618 rm -f conftest.$ac_objext
35619 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35620   (eval $ac_compile) 2>conftest.er1
35621   ac_status=$?
35622   grep -v '^ *+' conftest.er1 >conftest.err
35623   rm -f conftest.er1
35624   cat conftest.err >&5
35625   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35626   (exit $ac_status); } &&
35627          { ac_try='test -z "$ac_c_werror_flag"
35628                          || test ! -s conftest.err'
35629   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35630   (eval $ac_try) 2>&5
35631   ac_status=$?
35632   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35633   (exit $ac_status); }; } &&
35634          { ac_try='test -s conftest.$ac_objext'
35635   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35636   (eval $ac_try) 2>&5
35637   ac_status=$?
35638   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35639   (exit $ac_status); }; }; then
35640   ac_lo=0 ac_mid=0
35641   while :; do
35642     cat >conftest.$ac_ext <<_ACEOF
35643 /* confdefs.h.  */
35644 _ACEOF
35645 cat confdefs.h >>conftest.$ac_ext
35646 cat >>conftest.$ac_ext <<_ACEOF
35647 /* end confdefs.h.  */
35648 $ac_includes_default
35649 int
35650 main ()
35651 {
35652 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
35653 test_array [0] = 0
35654
35655   ;
35656   return 0;
35657 }
35658 _ACEOF
35659 rm -f conftest.$ac_objext
35660 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35661   (eval $ac_compile) 2>conftest.er1
35662   ac_status=$?
35663   grep -v '^ *+' conftest.er1 >conftest.err
35664   rm -f conftest.er1
35665   cat conftest.err >&5
35666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35667   (exit $ac_status); } &&
35668          { ac_try='test -z "$ac_c_werror_flag"
35669                          || test ! -s conftest.err'
35670   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35671   (eval $ac_try) 2>&5
35672   ac_status=$?
35673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35674   (exit $ac_status); }; } &&
35675          { ac_try='test -s conftest.$ac_objext'
35676   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35677   (eval $ac_try) 2>&5
35678   ac_status=$?
35679   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35680   (exit $ac_status); }; }; then
35681   ac_hi=$ac_mid; break
35682 else
35683   echo "$as_me: failed program was:" >&5
35684 sed 's/^/| /' conftest.$ac_ext >&5
35685
35686 ac_lo=`expr $ac_mid + 1`
35687                     if test $ac_lo -le $ac_mid; then
35688                       ac_lo= ac_hi=
35689                       break
35690                     fi
35691                     ac_mid=`expr 2 '*' $ac_mid + 1`
35692 fi
35693 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35694   done
35695 else
35696   echo "$as_me: failed program was:" >&5
35697 sed 's/^/| /' conftest.$ac_ext >&5
35698
35699 cat >conftest.$ac_ext <<_ACEOF
35700 /* confdefs.h.  */
35701 _ACEOF
35702 cat confdefs.h >>conftest.$ac_ext
35703 cat >>conftest.$ac_ext <<_ACEOF
35704 /* end confdefs.h.  */
35705 $ac_includes_default
35706 int
35707 main ()
35708 {
35709 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) < 0)];
35710 test_array [0] = 0
35711
35712   ;
35713   return 0;
35714 }
35715 _ACEOF
35716 rm -f conftest.$ac_objext
35717 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35718   (eval $ac_compile) 2>conftest.er1
35719   ac_status=$?
35720   grep -v '^ *+' conftest.er1 >conftest.err
35721   rm -f conftest.er1
35722   cat conftest.err >&5
35723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35724   (exit $ac_status); } &&
35725          { ac_try='test -z "$ac_c_werror_flag"
35726                          || test ! -s conftest.err'
35727   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35728   (eval $ac_try) 2>&5
35729   ac_status=$?
35730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35731   (exit $ac_status); }; } &&
35732          { ac_try='test -s conftest.$ac_objext'
35733   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35734   (eval $ac_try) 2>&5
35735   ac_status=$?
35736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35737   (exit $ac_status); }; }; then
35738   ac_hi=-1 ac_mid=-1
35739   while :; do
35740     cat >conftest.$ac_ext <<_ACEOF
35741 /* confdefs.h.  */
35742 _ACEOF
35743 cat confdefs.h >>conftest.$ac_ext
35744 cat >>conftest.$ac_ext <<_ACEOF
35745 /* end confdefs.h.  */
35746 $ac_includes_default
35747 int
35748 main ()
35749 {
35750 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= $ac_mid)];
35751 test_array [0] = 0
35752
35753   ;
35754   return 0;
35755 }
35756 _ACEOF
35757 rm -f conftest.$ac_objext
35758 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35759   (eval $ac_compile) 2>conftest.er1
35760   ac_status=$?
35761   grep -v '^ *+' conftest.er1 >conftest.err
35762   rm -f conftest.er1
35763   cat conftest.err >&5
35764   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35765   (exit $ac_status); } &&
35766          { ac_try='test -z "$ac_c_werror_flag"
35767                          || test ! -s conftest.err'
35768   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35769   (eval $ac_try) 2>&5
35770   ac_status=$?
35771   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35772   (exit $ac_status); }; } &&
35773          { ac_try='test -s conftest.$ac_objext'
35774   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35775   (eval $ac_try) 2>&5
35776   ac_status=$?
35777   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35778   (exit $ac_status); }; }; then
35779   ac_lo=$ac_mid; break
35780 else
35781   echo "$as_me: failed program was:" >&5
35782 sed 's/^/| /' conftest.$ac_ext >&5
35783
35784 ac_hi=`expr '(' $ac_mid ')' - 1`
35785                        if test $ac_mid -le $ac_hi; then
35786                          ac_lo= ac_hi=
35787                          break
35788                        fi
35789                        ac_mid=`expr 2 '*' $ac_mid`
35790 fi
35791 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35792   done
35793 else
35794   echo "$as_me: failed program was:" >&5
35795 sed 's/^/| /' conftest.$ac_ext >&5
35796
35797 ac_lo= ac_hi=
35798 fi
35799 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35800 fi
35801 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35802 # Binary search between lo and hi bounds.
35803 while test "x$ac_lo" != "x$ac_hi"; do
35804   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
35805   cat >conftest.$ac_ext <<_ACEOF
35806 /* confdefs.h.  */
35807 _ACEOF
35808 cat confdefs.h >>conftest.$ac_ext
35809 cat >>conftest.$ac_ext <<_ACEOF
35810 /* end confdefs.h.  */
35811 $ac_includes_default
35812 int
35813 main ()
35814 {
35815 static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
35816 test_array [0] = 0
35817
35818   ;
35819   return 0;
35820 }
35821 _ACEOF
35822 rm -f conftest.$ac_objext
35823 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35824   (eval $ac_compile) 2>conftest.er1
35825   ac_status=$?
35826   grep -v '^ *+' conftest.er1 >conftest.err
35827   rm -f conftest.er1
35828   cat conftest.err >&5
35829   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35830   (exit $ac_status); } &&
35831          { ac_try='test -z "$ac_c_werror_flag"
35832                          || test ! -s conftest.err'
35833   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35834   (eval $ac_try) 2>&5
35835   ac_status=$?
35836   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35837   (exit $ac_status); }; } &&
35838          { ac_try='test -s conftest.$ac_objext'
35839   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35840   (eval $ac_try) 2>&5
35841   ac_status=$?
35842   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35843   (exit $ac_status); }; }; then
35844   ac_hi=$ac_mid
35845 else
35846   echo "$as_me: failed program was:" >&5
35847 sed 's/^/| /' conftest.$ac_ext >&5
35848
35849 ac_lo=`expr '(' $ac_mid ')' + 1`
35850 fi
35851 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
35852 done
35853 case $ac_lo in
35854 ?*) ac_cv_sizeof_wchar_t=$ac_lo;;
35855 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77
35856 See \`config.log' for more details." >&5
35857 echo "$as_me: error: cannot compute sizeof (wchar_t), 77
35858 See \`config.log' for more details." >&2;}
35859    { (exit 1); exit 1; }; } ;;
35860 esac
35861 else
35862   if test "$cross_compiling" = yes; then
35863   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
35864 See \`config.log' for more details." >&5
35865 echo "$as_me: error: cannot run test program while cross compiling
35866 See \`config.log' for more details." >&2;}
35867    { (exit 1); exit 1; }; }
35868 else
35869   cat >conftest.$ac_ext <<_ACEOF
35870 /* confdefs.h.  */
35871 _ACEOF
35872 cat confdefs.h >>conftest.$ac_ext
35873 cat >>conftest.$ac_ext <<_ACEOF
35874 /* end confdefs.h.  */
35875 $ac_includes_default
35876 long longval () { return (long) (sizeof (wchar_t)); }
35877 unsigned long ulongval () { return (long) (sizeof (wchar_t)); }
35878 #include <stdio.h>
35879 #include <stdlib.h>
35880 int
35881 main ()
35882 {
35883
35884   FILE *f = fopen ("conftest.val", "w");
35885   if (! f)
35886     exit (1);
35887   if (((long) (sizeof (wchar_t))) < 0)
35888     {
35889       long i = longval ();
35890       if (i != ((long) (sizeof (wchar_t))))
35891         exit (1);
35892       fprintf (f, "%ld\n", i);
35893     }
35894   else
35895     {
35896       unsigned long i = ulongval ();
35897       if (i != ((long) (sizeof (wchar_t))))
35898         exit (1);
35899       fprintf (f, "%lu\n", i);
35900     }
35901   exit (ferror (f) || fclose (f) != 0);
35902
35903   ;
35904   return 0;
35905 }
35906 _ACEOF
35907 rm -f conftest$ac_exeext
35908 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35909   (eval $ac_link) 2>&5
35910   ac_status=$?
35911   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35912   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
35913   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
35914   (eval $ac_try) 2>&5
35915   ac_status=$?
35916   echo "$as_me:$LINENO: \$? = $ac_status" >&5
35917   (exit $ac_status); }; }; then
35918   ac_cv_sizeof_wchar_t=`cat conftest.val`
35919 else
35920   echo "$as_me: program exited with status $ac_status" >&5
35921 echo "$as_me: failed program was:" >&5
35922 sed 's/^/| /' conftest.$ac_ext >&5
35923
35924 ( exit $ac_status )
35925 { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77
35926 See \`config.log' for more details." >&5
35927 echo "$as_me: error: cannot compute sizeof (wchar_t), 77
35928 See \`config.log' for more details." >&2;}
35929    { (exit 1); exit 1; }; }
35930 fi
35931 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
35932 fi
35933 fi
35934 rm -f conftest.val
35935 else
35936   ac_cv_sizeof_wchar_t=0
35937 fi
35938 fi
35939 echo "$as_me:$LINENO: result: $ac_cv_sizeof_wchar_t" >&5
35940 echo "${ECHO_T}$ac_cv_sizeof_wchar_t" >&6
35941 cat >>confdefs.h <<_ACEOF
35942 #define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t
35943 _ACEOF
35944
35945
35946
35947 if test "$ac_cv_sizeof_int" -lt 4 ; then
35948         { echo "$as_me:$LINENO: WARNING: OpenLDAP requires 'int' to be 32 bits or greater." >&5
35949 echo "$as_me: WARNING: OpenLDAP requires 'int' to be 32 bits or greater." >&2;}
35950
35951
35952 cat >>confdefs.h <<\_ACEOF
35953 #define LBER_INT_T long
35954 _ACEOF
35955
35956 else
35957
35958 cat >>confdefs.h <<\_ACEOF
35959 #define LBER_INT_T int
35960 _ACEOF
35961
35962 fi
35963
35964
35965 cat >>confdefs.h <<\_ACEOF
35966 #define LBER_LEN_T long
35967 _ACEOF
35968
35969
35970 cat >>confdefs.h <<\_ACEOF
35971 #define LBER_SOCKET_T int
35972 _ACEOF
35973
35974
35975 cat >>confdefs.h <<\_ACEOF
35976 #define LBER_TAG_T long
35977 _ACEOF
35978
35979
35980 if test $ol_with_mp = longlong || test $ol_with_mp = auto ; then
35981         if test $ac_cv_sizeof_long_long -gt 4 ; then
35982                 ol_with_mp=longlong
35983
35984 cat >>confdefs.h <<\_ACEOF
35985 #define USE_MP_LONG_LONG 1
35986 _ACEOF
35987
35988         elif test $ol_with_mp = longlong ; then
35989                 { { echo "$as_me:$LINENO: error: long long unusable for multiple precision" >&5
35990 echo "$as_me: error: long long unusable for multiple precision" >&2;}
35991    { (exit 1); exit 1; }; }
35992         fi
35993 fi
35994 if test $ol_with_mp = long || test $ol_with_mp = auto ; then
35995         if test $ac_cv_sizeof_long -gt 4 ; then
35996                 ol_with_mp=long
35997
35998 cat >>confdefs.h <<\_ACEOF
35999 #define USE_MP_LONG 1
36000 _ACEOF
36001
36002         elif test $ol_with_mp = long ; then
36003                 { { echo "$as_me:$LINENO: error: long unusable for multiple precision" >&5
36004 echo "$as_me: error: long unusable for multiple precision" >&2;}
36005    { (exit 1); exit 1; }; }
36006         fi
36007 fi
36008 if test $ol_with_mp = bignum || test $ol_with_mp = auto ; then
36009
36010 for ac_header in openssl/bn.h
36011 do
36012 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
36013 if eval "test \"\${$as_ac_Header+set}\" = set"; then
36014   echo "$as_me:$LINENO: checking for $ac_header" >&5
36015 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
36016 if eval "test \"\${$as_ac_Header+set}\" = set"; then
36017   echo $ECHO_N "(cached) $ECHO_C" >&6
36018 fi
36019 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
36020 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
36021 else
36022   # Is the header compilable?
36023 echo "$as_me:$LINENO: checking $ac_header usability" >&5
36024 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
36025 cat >conftest.$ac_ext <<_ACEOF
36026 /* confdefs.h.  */
36027 _ACEOF
36028 cat confdefs.h >>conftest.$ac_ext
36029 cat >>conftest.$ac_ext <<_ACEOF
36030 /* end confdefs.h.  */
36031 $ac_includes_default
36032 #include <$ac_header>
36033 _ACEOF
36034 rm -f conftest.$ac_objext
36035 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36036   (eval $ac_compile) 2>conftest.er1
36037   ac_status=$?
36038   grep -v '^ *+' conftest.er1 >conftest.err
36039   rm -f conftest.er1
36040   cat conftest.err >&5
36041   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36042   (exit $ac_status); } &&
36043          { ac_try='test -z "$ac_c_werror_flag"
36044                          || test ! -s conftest.err'
36045   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36046   (eval $ac_try) 2>&5
36047   ac_status=$?
36048   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36049   (exit $ac_status); }; } &&
36050          { ac_try='test -s conftest.$ac_objext'
36051   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36052   (eval $ac_try) 2>&5
36053   ac_status=$?
36054   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36055   (exit $ac_status); }; }; then
36056   ac_header_compiler=yes
36057 else
36058   echo "$as_me: failed program was:" >&5
36059 sed 's/^/| /' conftest.$ac_ext >&5
36060
36061 ac_header_compiler=no
36062 fi
36063 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36064 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
36065 echo "${ECHO_T}$ac_header_compiler" >&6
36066
36067 # Is the header present?
36068 echo "$as_me:$LINENO: checking $ac_header presence" >&5
36069 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
36070 cat >conftest.$ac_ext <<_ACEOF
36071 /* confdefs.h.  */
36072 _ACEOF
36073 cat confdefs.h >>conftest.$ac_ext
36074 cat >>conftest.$ac_ext <<_ACEOF
36075 /* end confdefs.h.  */
36076 #include <$ac_header>
36077 _ACEOF
36078 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
36079   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
36080   ac_status=$?
36081   grep -v '^ *+' conftest.er1 >conftest.err
36082   rm -f conftest.er1
36083   cat conftest.err >&5
36084   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36085   (exit $ac_status); } >/dev/null; then
36086   if test -s conftest.err; then
36087     ac_cpp_err=$ac_c_preproc_warn_flag
36088     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
36089   else
36090     ac_cpp_err=
36091   fi
36092 else
36093   ac_cpp_err=yes
36094 fi
36095 if test -z "$ac_cpp_err"; then
36096   ac_header_preproc=yes
36097 else
36098   echo "$as_me: failed program was:" >&5
36099 sed 's/^/| /' conftest.$ac_ext >&5
36100
36101   ac_header_preproc=no
36102 fi
36103 rm -f conftest.err conftest.$ac_ext
36104 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
36105 echo "${ECHO_T}$ac_header_preproc" >&6
36106
36107 # So?  What about this header?
36108 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
36109   yes:no: )
36110     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
36111 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
36112     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
36113 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
36114     ac_header_preproc=yes
36115     ;;
36116   no:yes:* )
36117     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
36118 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
36119     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
36120 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
36121     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
36122 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
36123     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
36124 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
36125     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
36126 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
36127     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
36128 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
36129     (
36130       cat <<\_ASBOX
36131 ## --------------------------------------------- ##
36132 ## Report this to <http://www.openldap.org/its/> ##
36133 ## --------------------------------------------- ##
36134 _ASBOX
36135     ) |
36136       sed "s/^/$as_me: WARNING:     /" >&2
36137     ;;
36138 esac
36139 echo "$as_me:$LINENO: checking for $ac_header" >&5
36140 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
36141 if eval "test \"\${$as_ac_Header+set}\" = set"; then
36142   echo $ECHO_N "(cached) $ECHO_C" >&6
36143 else
36144   eval "$as_ac_Header=\$ac_header_preproc"
36145 fi
36146 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
36147 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
36148
36149 fi
36150 if test `eval echo '${'$as_ac_Header'}'` = yes; then
36151   cat >>confdefs.h <<_ACEOF
36152 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
36153 _ACEOF
36154
36155 fi
36156
36157 done
36158
36159
36160 for ac_header in openssl/crypto.h
36161 do
36162 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
36163 if eval "test \"\${$as_ac_Header+set}\" = set"; then
36164   echo "$as_me:$LINENO: checking for $ac_header" >&5
36165 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
36166 if eval "test \"\${$as_ac_Header+set}\" = set"; then
36167   echo $ECHO_N "(cached) $ECHO_C" >&6
36168 fi
36169 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
36170 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
36171 else
36172   # Is the header compilable?
36173 echo "$as_me:$LINENO: checking $ac_header usability" >&5
36174 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
36175 cat >conftest.$ac_ext <<_ACEOF
36176 /* confdefs.h.  */
36177 _ACEOF
36178 cat confdefs.h >>conftest.$ac_ext
36179 cat >>conftest.$ac_ext <<_ACEOF
36180 /* end confdefs.h.  */
36181 $ac_includes_default
36182 #include <$ac_header>
36183 _ACEOF
36184 rm -f conftest.$ac_objext
36185 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36186   (eval $ac_compile) 2>conftest.er1
36187   ac_status=$?
36188   grep -v '^ *+' conftest.er1 >conftest.err
36189   rm -f conftest.er1
36190   cat conftest.err >&5
36191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36192   (exit $ac_status); } &&
36193          { ac_try='test -z "$ac_c_werror_flag"
36194                          || test ! -s conftest.err'
36195   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36196   (eval $ac_try) 2>&5
36197   ac_status=$?
36198   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36199   (exit $ac_status); }; } &&
36200          { ac_try='test -s conftest.$ac_objext'
36201   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36202   (eval $ac_try) 2>&5
36203   ac_status=$?
36204   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36205   (exit $ac_status); }; }; then
36206   ac_header_compiler=yes
36207 else
36208   echo "$as_me: failed program was:" >&5
36209 sed 's/^/| /' conftest.$ac_ext >&5
36210
36211 ac_header_compiler=no
36212 fi
36213 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36214 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
36215 echo "${ECHO_T}$ac_header_compiler" >&6
36216
36217 # Is the header present?
36218 echo "$as_me:$LINENO: checking $ac_header presence" >&5
36219 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
36220 cat >conftest.$ac_ext <<_ACEOF
36221 /* confdefs.h.  */
36222 _ACEOF
36223 cat confdefs.h >>conftest.$ac_ext
36224 cat >>conftest.$ac_ext <<_ACEOF
36225 /* end confdefs.h.  */
36226 #include <$ac_header>
36227 _ACEOF
36228 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
36229   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
36230   ac_status=$?
36231   grep -v '^ *+' conftest.er1 >conftest.err
36232   rm -f conftest.er1
36233   cat conftest.err >&5
36234   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36235   (exit $ac_status); } >/dev/null; then
36236   if test -s conftest.err; then
36237     ac_cpp_err=$ac_c_preproc_warn_flag
36238     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
36239   else
36240     ac_cpp_err=
36241   fi
36242 else
36243   ac_cpp_err=yes
36244 fi
36245 if test -z "$ac_cpp_err"; then
36246   ac_header_preproc=yes
36247 else
36248   echo "$as_me: failed program was:" >&5
36249 sed 's/^/| /' conftest.$ac_ext >&5
36250
36251   ac_header_preproc=no
36252 fi
36253 rm -f conftest.err conftest.$ac_ext
36254 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
36255 echo "${ECHO_T}$ac_header_preproc" >&6
36256
36257 # So?  What about this header?
36258 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
36259   yes:no: )
36260     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
36261 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
36262     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
36263 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
36264     ac_header_preproc=yes
36265     ;;
36266   no:yes:* )
36267     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
36268 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
36269     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
36270 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
36271     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
36272 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
36273     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
36274 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
36275     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
36276 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
36277     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
36278 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
36279     (
36280       cat <<\_ASBOX
36281 ## --------------------------------------------- ##
36282 ## Report this to <http://www.openldap.org/its/> ##
36283 ## --------------------------------------------- ##
36284 _ASBOX
36285     ) |
36286       sed "s/^/$as_me: WARNING:     /" >&2
36287     ;;
36288 esac
36289 echo "$as_me:$LINENO: checking for $ac_header" >&5
36290 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
36291 if eval "test \"\${$as_ac_Header+set}\" = set"; then
36292   echo $ECHO_N "(cached) $ECHO_C" >&6
36293 else
36294   eval "$as_ac_Header=\$ac_header_preproc"
36295 fi
36296 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
36297 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
36298
36299 fi
36300 if test `eval echo '${'$as_ac_Header'}'` = yes; then
36301   cat >>confdefs.h <<_ACEOF
36302 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
36303 _ACEOF
36304
36305 fi
36306
36307 done
36308
36309         if test "$ac_cv_header_openssl_bn_h" = "yes" &&
36310                 test "$ac_cv_header_openssl_crypto_h" = "yes" &&
36311                 test "$ol_with_tls" = "found" ; then
36312                 ol_with_mp=bignum
36313
36314 cat >>confdefs.h <<\_ACEOF
36315 #define USE_MP_BIGNUM 1
36316 _ACEOF
36317
36318         elif test $ol_with_mp = bignum ; then
36319                 { { echo "$as_me:$LINENO: error: bignum not available" >&5
36320 echo "$as_me: error: bignum not available" >&2;}
36321    { (exit 1); exit 1; }; }
36322         fi
36323 fi
36324 if test $ol_with_mp = gmp || test $ol_with_mp = auto ; then
36325
36326 for ac_header in gmp.h
36327 do
36328 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
36329 if eval "test \"\${$as_ac_Header+set}\" = set"; then
36330   echo "$as_me:$LINENO: checking for $ac_header" >&5
36331 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
36332 if eval "test \"\${$as_ac_Header+set}\" = set"; then
36333   echo $ECHO_N "(cached) $ECHO_C" >&6
36334 fi
36335 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
36336 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
36337 else
36338   # Is the header compilable?
36339 echo "$as_me:$LINENO: checking $ac_header usability" >&5
36340 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
36341 cat >conftest.$ac_ext <<_ACEOF
36342 /* confdefs.h.  */
36343 _ACEOF
36344 cat confdefs.h >>conftest.$ac_ext
36345 cat >>conftest.$ac_ext <<_ACEOF
36346 /* end confdefs.h.  */
36347 $ac_includes_default
36348 #include <$ac_header>
36349 _ACEOF
36350 rm -f conftest.$ac_objext
36351 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
36352   (eval $ac_compile) 2>conftest.er1
36353   ac_status=$?
36354   grep -v '^ *+' conftest.er1 >conftest.err
36355   rm -f conftest.er1
36356   cat conftest.err >&5
36357   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36358   (exit $ac_status); } &&
36359          { ac_try='test -z "$ac_c_werror_flag"
36360                          || test ! -s conftest.err'
36361   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36362   (eval $ac_try) 2>&5
36363   ac_status=$?
36364   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36365   (exit $ac_status); }; } &&
36366          { ac_try='test -s conftest.$ac_objext'
36367   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36368   (eval $ac_try) 2>&5
36369   ac_status=$?
36370   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36371   (exit $ac_status); }; }; then
36372   ac_header_compiler=yes
36373 else
36374   echo "$as_me: failed program was:" >&5
36375 sed 's/^/| /' conftest.$ac_ext >&5
36376
36377 ac_header_compiler=no
36378 fi
36379 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
36380 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
36381 echo "${ECHO_T}$ac_header_compiler" >&6
36382
36383 # Is the header present?
36384 echo "$as_me:$LINENO: checking $ac_header presence" >&5
36385 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
36386 cat >conftest.$ac_ext <<_ACEOF
36387 /* confdefs.h.  */
36388 _ACEOF
36389 cat confdefs.h >>conftest.$ac_ext
36390 cat >>conftest.$ac_ext <<_ACEOF
36391 /* end confdefs.h.  */
36392 #include <$ac_header>
36393 _ACEOF
36394 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
36395   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
36396   ac_status=$?
36397   grep -v '^ *+' conftest.er1 >conftest.err
36398   rm -f conftest.er1
36399   cat conftest.err >&5
36400   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36401   (exit $ac_status); } >/dev/null; then
36402   if test -s conftest.err; then
36403     ac_cpp_err=$ac_c_preproc_warn_flag
36404     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
36405   else
36406     ac_cpp_err=
36407   fi
36408 else
36409   ac_cpp_err=yes
36410 fi
36411 if test -z "$ac_cpp_err"; then
36412   ac_header_preproc=yes
36413 else
36414   echo "$as_me: failed program was:" >&5
36415 sed 's/^/| /' conftest.$ac_ext >&5
36416
36417   ac_header_preproc=no
36418 fi
36419 rm -f conftest.err conftest.$ac_ext
36420 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
36421 echo "${ECHO_T}$ac_header_preproc" >&6
36422
36423 # So?  What about this header?
36424 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
36425   yes:no: )
36426     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
36427 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
36428     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
36429 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
36430     ac_header_preproc=yes
36431     ;;
36432   no:yes:* )
36433     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
36434 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
36435     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
36436 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
36437     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
36438 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
36439     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
36440 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
36441     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
36442 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
36443     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
36444 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
36445     (
36446       cat <<\_ASBOX
36447 ## --------------------------------------------- ##
36448 ## Report this to <http://www.openldap.org/its/> ##
36449 ## --------------------------------------------- ##
36450 _ASBOX
36451     ) |
36452       sed "s/^/$as_me: WARNING:     /" >&2
36453     ;;
36454 esac
36455 echo "$as_me:$LINENO: checking for $ac_header" >&5
36456 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
36457 if eval "test \"\${$as_ac_Header+set}\" = set"; then
36458   echo $ECHO_N "(cached) $ECHO_C" >&6
36459 else
36460   eval "$as_ac_Header=\$ac_header_preproc"
36461 fi
36462 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
36463 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
36464
36465 fi
36466 if test `eval echo '${'$as_ac_Header'}'` = yes; then
36467   cat >>confdefs.h <<_ACEOF
36468 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
36469 _ACEOF
36470
36471 fi
36472
36473 done
36474
36475
36476 echo "$as_me:$LINENO: checking for __gmpz_add_ui in -lgmp" >&5
36477 echo $ECHO_N "checking for __gmpz_add_ui in -lgmp... $ECHO_C" >&6
36478 if test "${ac_cv_lib_gmp___gmpz_add_ui+set}" = set; then
36479   echo $ECHO_N "(cached) $ECHO_C" >&6
36480 else
36481   ac_check_lib_save_LIBS=$LIBS
36482 LIBS="-lgmp  $LIBS"
36483 cat >conftest.$ac_ext <<_ACEOF
36484 /* confdefs.h.  */
36485 _ACEOF
36486 cat confdefs.h >>conftest.$ac_ext
36487 cat >>conftest.$ac_ext <<_ACEOF
36488 /* end confdefs.h.  */
36489
36490 /* Override any gcc2 internal prototype to avoid an error.  */
36491 #ifdef __cplusplus
36492 extern "C"
36493 #endif
36494 /* We use char because int might match the return type of a gcc2
36495    builtin and then its argument prototype would still apply.  */
36496 char __gmpz_add_ui ();
36497 int
36498 main ()
36499 {
36500 __gmpz_add_ui ();
36501   ;
36502   return 0;
36503 }
36504 _ACEOF
36505 rm -f conftest.$ac_objext conftest$ac_exeext
36506 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36507   (eval $ac_link) 2>conftest.er1
36508   ac_status=$?
36509   grep -v '^ *+' conftest.er1 >conftest.err
36510   rm -f conftest.er1
36511   cat conftest.err >&5
36512   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36513   (exit $ac_status); } &&
36514          { ac_try='test -z "$ac_c_werror_flag"
36515                          || test ! -s conftest.err'
36516   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36517   (eval $ac_try) 2>&5
36518   ac_status=$?
36519   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36520   (exit $ac_status); }; } &&
36521          { ac_try='test -s conftest$ac_exeext'
36522   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36523   (eval $ac_try) 2>&5
36524   ac_status=$?
36525   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36526   (exit $ac_status); }; }; then
36527   ac_cv_lib_gmp___gmpz_add_ui=yes
36528 else
36529   echo "$as_me: failed program was:" >&5
36530 sed 's/^/| /' conftest.$ac_ext >&5
36531
36532 ac_cv_lib_gmp___gmpz_add_ui=no
36533 fi
36534 rm -f conftest.err conftest.$ac_objext \
36535       conftest$ac_exeext conftest.$ac_ext
36536 LIBS=$ac_check_lib_save_LIBS
36537 fi
36538 echo "$as_me:$LINENO: result: $ac_cv_lib_gmp___gmpz_add_ui" >&5
36539 echo "${ECHO_T}$ac_cv_lib_gmp___gmpz_add_ui" >&6
36540 if test $ac_cv_lib_gmp___gmpz_add_ui = yes; then
36541   cat >>confdefs.h <<_ACEOF
36542 #define HAVE_LIBGMP 1
36543 _ACEOF
36544
36545   LIBS="-lgmp $LIBS"
36546
36547 fi
36548
36549         if test $ac_cv_header_gmp_h = yes && test $ac_cv_lib_gmp___gmpz_add_ui = yes ; then
36550
36551 cat >>confdefs.h <<\_ACEOF
36552 #define USE_MP_GMP 1
36553 _ACEOF
36554
36555                 ol_with_mp=gmp
36556         elif test $ol_with_mp = gmp ; then
36557                 { { echo "$as_me:$LINENO: error: gmp not available" >&5
36558 echo "$as_me: error: gmp not available" >&2;}
36559    { (exit 1); exit 1; }; }
36560         fi
36561 fi
36562 if test $ol_with_mp = auto ; then
36563         ol_with_mp=no
36564 fi
36565
36566 echo "$as_me:$LINENO: checking for working memcmp" >&5
36567 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
36568 if test "${ac_cv_func_memcmp_working+set}" = set; then
36569   echo $ECHO_N "(cached) $ECHO_C" >&6
36570 else
36571   if test "$cross_compiling" = yes; then
36572   ac_cv_func_memcmp_working=no
36573 else
36574   cat >conftest.$ac_ext <<_ACEOF
36575 /* confdefs.h.  */
36576 _ACEOF
36577 cat confdefs.h >>conftest.$ac_ext
36578 cat >>conftest.$ac_ext <<_ACEOF
36579 /* end confdefs.h.  */
36580 $ac_includes_default
36581 int
36582 main ()
36583 {
36584
36585   /* Some versions of memcmp are not 8-bit clean.  */
36586   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
36587   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
36588     exit (1);
36589
36590   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
36591      or more and with at least one buffer not starting on a 4-byte boundary.
36592      William Lewis provided this test program.   */
36593   {
36594     char foo[21];
36595     char bar[21];
36596     int i;
36597     for (i = 0; i < 4; i++)
36598       {
36599         char *a = foo + i;
36600         char *b = bar + i;
36601         strcpy (a, "--------01111111");
36602         strcpy (b, "--------10000000");
36603         if (memcmp (a, b, 16) >= 0)
36604           exit (1);
36605       }
36606     exit (0);
36607   }
36608
36609   ;
36610   return 0;
36611 }
36612 _ACEOF
36613 rm -f conftest$ac_exeext
36614 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36615   (eval $ac_link) 2>&5
36616   ac_status=$?
36617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36618   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
36619   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36620   (eval $ac_try) 2>&5
36621   ac_status=$?
36622   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36623   (exit $ac_status); }; }; then
36624   ac_cv_func_memcmp_working=yes
36625 else
36626   echo "$as_me: program exited with status $ac_status" >&5
36627 echo "$as_me: failed program was:" >&5
36628 sed 's/^/| /' conftest.$ac_ext >&5
36629
36630 ( exit $ac_status )
36631 ac_cv_func_memcmp_working=no
36632 fi
36633 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
36634 fi
36635 fi
36636 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
36637 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
36638 test $ac_cv_func_memcmp_working = no && case $LIBOBJS in
36639     "memcmp.$ac_objext"   | \
36640   *" memcmp.$ac_objext"   | \
36641     "memcmp.$ac_objext "* | \
36642   *" memcmp.$ac_objext "* ) ;;
36643   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext" ;;
36644 esac
36645
36646
36647
36648 if test $ac_cv_func_memcmp_working = no ; then
36649
36650 cat >>confdefs.h <<\_ACEOF
36651 #define NEED_MEMCMP_REPLACEMENT 1
36652 _ACEOF
36653
36654 fi
36655
36656
36657 for ac_func in strftime
36658 do
36659 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
36660 echo "$as_me:$LINENO: checking for $ac_func" >&5
36661 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
36662 if eval "test \"\${$as_ac_var+set}\" = set"; then
36663   echo $ECHO_N "(cached) $ECHO_C" >&6
36664 else
36665   cat >conftest.$ac_ext <<_ACEOF
36666 /* confdefs.h.  */
36667 _ACEOF
36668 cat confdefs.h >>conftest.$ac_ext
36669 cat >>conftest.$ac_ext <<_ACEOF
36670 /* end confdefs.h.  */
36671 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
36672    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
36673 #define $ac_func innocuous_$ac_func
36674
36675 /* System header to define __stub macros and hopefully few prototypes,
36676     which can conflict with char $ac_func (); below.
36677     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
36678     <limits.h> exists even on freestanding compilers.  */
36679
36680 #ifdef __STDC__
36681 # include <limits.h>
36682 #else
36683 # include <assert.h>
36684 #endif
36685
36686 #undef $ac_func
36687
36688 /* Override any gcc2 internal prototype to avoid an error.  */
36689 #ifdef __cplusplus
36690 extern "C"
36691 {
36692 #endif
36693 /* We use char because int might match the return type of a gcc2
36694    builtin and then its argument prototype would still apply.  */
36695 char $ac_func ();
36696 /* The GNU C library defines this for functions which it implements
36697     to always fail with ENOSYS.  Some functions are actually named
36698     something starting with __ and the normal name is an alias.  */
36699 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
36700 choke me
36701 #else
36702 char (*f) () = $ac_func;
36703 #endif
36704 #ifdef __cplusplus
36705 }
36706 #endif
36707
36708 int
36709 main ()
36710 {
36711 return f != $ac_func;
36712   ;
36713   return 0;
36714 }
36715 _ACEOF
36716 rm -f conftest.$ac_objext conftest$ac_exeext
36717 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36718   (eval $ac_link) 2>conftest.er1
36719   ac_status=$?
36720   grep -v '^ *+' conftest.er1 >conftest.err
36721   rm -f conftest.er1
36722   cat conftest.err >&5
36723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36724   (exit $ac_status); } &&
36725          { ac_try='test -z "$ac_c_werror_flag"
36726                          || test ! -s conftest.err'
36727   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36728   (eval $ac_try) 2>&5
36729   ac_status=$?
36730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36731   (exit $ac_status); }; } &&
36732          { ac_try='test -s conftest$ac_exeext'
36733   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36734   (eval $ac_try) 2>&5
36735   ac_status=$?
36736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36737   (exit $ac_status); }; }; then
36738   eval "$as_ac_var=yes"
36739 else
36740   echo "$as_me: failed program was:" >&5
36741 sed 's/^/| /' conftest.$ac_ext >&5
36742
36743 eval "$as_ac_var=no"
36744 fi
36745 rm -f conftest.err conftest.$ac_objext \
36746       conftest$ac_exeext conftest.$ac_ext
36747 fi
36748 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
36749 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
36750 if test `eval echo '${'$as_ac_var'}'` = yes; then
36751   cat >>confdefs.h <<_ACEOF
36752 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
36753 _ACEOF
36754
36755 else
36756   # strftime is in -lintl on SCO UNIX.
36757 echo "$as_me:$LINENO: checking for strftime in -lintl" >&5
36758 echo $ECHO_N "checking for strftime in -lintl... $ECHO_C" >&6
36759 if test "${ac_cv_lib_intl_strftime+set}" = set; then
36760   echo $ECHO_N "(cached) $ECHO_C" >&6
36761 else
36762   ac_check_lib_save_LIBS=$LIBS
36763 LIBS="-lintl  $LIBS"
36764 cat >conftest.$ac_ext <<_ACEOF
36765 /* confdefs.h.  */
36766 _ACEOF
36767 cat confdefs.h >>conftest.$ac_ext
36768 cat >>conftest.$ac_ext <<_ACEOF
36769 /* end confdefs.h.  */
36770
36771 /* Override any gcc2 internal prototype to avoid an error.  */
36772 #ifdef __cplusplus
36773 extern "C"
36774 #endif
36775 /* We use char because int might match the return type of a gcc2
36776    builtin and then its argument prototype would still apply.  */
36777 char strftime ();
36778 int
36779 main ()
36780 {
36781 strftime ();
36782   ;
36783   return 0;
36784 }
36785 _ACEOF
36786 rm -f conftest.$ac_objext conftest$ac_exeext
36787 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36788   (eval $ac_link) 2>conftest.er1
36789   ac_status=$?
36790   grep -v '^ *+' conftest.er1 >conftest.err
36791   rm -f conftest.er1
36792   cat conftest.err >&5
36793   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36794   (exit $ac_status); } &&
36795          { ac_try='test -z "$ac_c_werror_flag"
36796                          || test ! -s conftest.err'
36797   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36798   (eval $ac_try) 2>&5
36799   ac_status=$?
36800   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36801   (exit $ac_status); }; } &&
36802          { ac_try='test -s conftest$ac_exeext'
36803   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36804   (eval $ac_try) 2>&5
36805   ac_status=$?
36806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36807   (exit $ac_status); }; }; then
36808   ac_cv_lib_intl_strftime=yes
36809 else
36810   echo "$as_me: failed program was:" >&5
36811 sed 's/^/| /' conftest.$ac_ext >&5
36812
36813 ac_cv_lib_intl_strftime=no
36814 fi
36815 rm -f conftest.err conftest.$ac_objext \
36816       conftest$ac_exeext conftest.$ac_ext
36817 LIBS=$ac_check_lib_save_LIBS
36818 fi
36819 echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5
36820 echo "${ECHO_T}$ac_cv_lib_intl_strftime" >&6
36821 if test $ac_cv_lib_intl_strftime = yes; then
36822   cat >>confdefs.h <<\_ACEOF
36823 #define HAVE_STRFTIME 1
36824 _ACEOF
36825
36826 LIBS="-lintl $LIBS"
36827 fi
36828
36829 fi
36830 done
36831
36832
36833 echo "$as_me:$LINENO: checking for inet_aton()" >&5
36834 echo $ECHO_N "checking for inet_aton()... $ECHO_C" >&6
36835 if test "${ol_cv_func_inet_aton+set}" = set; then
36836   echo $ECHO_N "(cached) $ECHO_C" >&6
36837 else
36838   cat >conftest.$ac_ext <<_ACEOF
36839 /* confdefs.h.  */
36840 _ACEOF
36841 cat confdefs.h >>conftest.$ac_ext
36842 cat >>conftest.$ac_ext <<_ACEOF
36843 /* end confdefs.h.  */
36844
36845 #ifdef HAVE_SYS_TYPES_H
36846 #       include <sys/types.h>
36847 #endif
36848 #ifdef HAVE_SYS_SOCKET_H
36849 #       include <sys/socket.h>
36850 #       ifdef HAVE_SYS_SELECT_H
36851 #               include <sys/select.h>
36852 #       endif
36853 #       include <netinet/in.h>
36854 #       ifdef HAVE_ARPA_INET_H
36855 #               include <arpa/inet.h>
36856 #       endif
36857 #endif
36858
36859 int
36860 main ()
36861 {
36862 struct in_addr in;
36863 int rc = inet_aton( "255.255.255.255", &in );
36864   ;
36865   return 0;
36866 }
36867 _ACEOF
36868 rm -f conftest.$ac_objext conftest$ac_exeext
36869 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36870   (eval $ac_link) 2>conftest.er1
36871   ac_status=$?
36872   grep -v '^ *+' conftest.er1 >conftest.err
36873   rm -f conftest.er1
36874   cat conftest.err >&5
36875   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36876   (exit $ac_status); } &&
36877          { ac_try='test -z "$ac_c_werror_flag"
36878                          || test ! -s conftest.err'
36879   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36880   (eval $ac_try) 2>&5
36881   ac_status=$?
36882   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36883   (exit $ac_status); }; } &&
36884          { ac_try='test -s conftest$ac_exeext'
36885   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36886   (eval $ac_try) 2>&5
36887   ac_status=$?
36888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36889   (exit $ac_status); }; }; then
36890   ol_cv_func_inet_aton=yes
36891 else
36892   echo "$as_me: failed program was:" >&5
36893 sed 's/^/| /' conftest.$ac_ext >&5
36894
36895 ol_cv_func_inet_aton=no
36896 fi
36897 rm -f conftest.err conftest.$ac_objext \
36898       conftest$ac_exeext conftest.$ac_ext
36899 fi
36900 echo "$as_me:$LINENO: result: $ol_cv_func_inet_aton" >&5
36901 echo "${ECHO_T}$ol_cv_func_inet_aton" >&6
36902   if test $ol_cv_func_inet_aton != no; then
36903
36904 cat >>confdefs.h <<\_ACEOF
36905 #define HAVE_INET_ATON 1
36906 _ACEOF
36907
36908   fi
36909
36910
36911 echo "$as_me:$LINENO: checking for _spawnlp" >&5
36912 echo $ECHO_N "checking for _spawnlp... $ECHO_C" >&6
36913 if test "${ac_cv_func__spawnlp+set}" = set; then
36914   echo $ECHO_N "(cached) $ECHO_C" >&6
36915 else
36916   cat >conftest.$ac_ext <<_ACEOF
36917 /* confdefs.h.  */
36918 _ACEOF
36919 cat confdefs.h >>conftest.$ac_ext
36920 cat >>conftest.$ac_ext <<_ACEOF
36921 /* end confdefs.h.  */
36922 /* Define _spawnlp to an innocuous variant, in case <limits.h> declares _spawnlp.
36923    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
36924 #define _spawnlp innocuous__spawnlp
36925
36926 /* System header to define __stub macros and hopefully few prototypes,
36927     which can conflict with char _spawnlp (); below.
36928     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
36929     <limits.h> exists even on freestanding compilers.  */
36930
36931 #ifdef __STDC__
36932 # include <limits.h>
36933 #else
36934 # include <assert.h>
36935 #endif
36936
36937 #undef _spawnlp
36938
36939 /* Override any gcc2 internal prototype to avoid an error.  */
36940 #ifdef __cplusplus
36941 extern "C"
36942 {
36943 #endif
36944 /* We use char because int might match the return type of a gcc2
36945    builtin and then its argument prototype would still apply.  */
36946 char _spawnlp ();
36947 /* The GNU C library defines this for functions which it implements
36948     to always fail with ENOSYS.  Some functions are actually named
36949     something starting with __ and the normal name is an alias.  */
36950 #if defined (__stub__spawnlp) || defined (__stub____spawnlp)
36951 choke me
36952 #else
36953 char (*f) () = _spawnlp;
36954 #endif
36955 #ifdef __cplusplus
36956 }
36957 #endif
36958
36959 int
36960 main ()
36961 {
36962 return f != _spawnlp;
36963   ;
36964   return 0;
36965 }
36966 _ACEOF
36967 rm -f conftest.$ac_objext conftest$ac_exeext
36968 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
36969   (eval $ac_link) 2>conftest.er1
36970   ac_status=$?
36971   grep -v '^ *+' conftest.er1 >conftest.err
36972   rm -f conftest.er1
36973   cat conftest.err >&5
36974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36975   (exit $ac_status); } &&
36976          { ac_try='test -z "$ac_c_werror_flag"
36977                          || test ! -s conftest.err'
36978   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36979   (eval $ac_try) 2>&5
36980   ac_status=$?
36981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36982   (exit $ac_status); }; } &&
36983          { ac_try='test -s conftest$ac_exeext'
36984   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
36985   (eval $ac_try) 2>&5
36986   ac_status=$?
36987   echo "$as_me:$LINENO: \$? = $ac_status" >&5
36988   (exit $ac_status); }; }; then
36989   ac_cv_func__spawnlp=yes
36990 else
36991   echo "$as_me: failed program was:" >&5
36992 sed 's/^/| /' conftest.$ac_ext >&5
36993
36994 ac_cv_func__spawnlp=no
36995 fi
36996 rm -f conftest.err conftest.$ac_objext \
36997       conftest$ac_exeext conftest.$ac_ext
36998 fi
36999 echo "$as_me:$LINENO: result: $ac_cv_func__spawnlp" >&5
37000 echo "${ECHO_T}$ac_cv_func__spawnlp" >&6
37001 if test $ac_cv_func__spawnlp = yes; then
37002
37003 cat >>confdefs.h <<\_ACEOF
37004 #define HAVE_SPAWNLP 1
37005 _ACEOF
37006
37007 fi
37008
37009
37010 echo "$as_me:$LINENO: checking for _snprintf" >&5
37011 echo $ECHO_N "checking for _snprintf... $ECHO_C" >&6
37012 if test "${ac_cv_func__snprintf+set}" = set; then
37013   echo $ECHO_N "(cached) $ECHO_C" >&6
37014 else
37015   cat >conftest.$ac_ext <<_ACEOF
37016 /* confdefs.h.  */
37017 _ACEOF
37018 cat confdefs.h >>conftest.$ac_ext
37019 cat >>conftest.$ac_ext <<_ACEOF
37020 /* end confdefs.h.  */
37021 /* Define _snprintf to an innocuous variant, in case <limits.h> declares _snprintf.
37022    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
37023 #define _snprintf innocuous__snprintf
37024
37025 /* System header to define __stub macros and hopefully few prototypes,
37026     which can conflict with char _snprintf (); below.
37027     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
37028     <limits.h> exists even on freestanding compilers.  */
37029
37030 #ifdef __STDC__
37031 # include <limits.h>
37032 #else
37033 # include <assert.h>
37034 #endif
37035
37036 #undef _snprintf
37037
37038 /* Override any gcc2 internal prototype to avoid an error.  */
37039 #ifdef __cplusplus
37040 extern "C"
37041 {
37042 #endif
37043 /* We use char because int might match the return type of a gcc2
37044    builtin and then its argument prototype would still apply.  */
37045 char _snprintf ();
37046 /* The GNU C library defines this for functions which it implements
37047     to always fail with ENOSYS.  Some functions are actually named
37048     something starting with __ and the normal name is an alias.  */
37049 #if defined (__stub__snprintf) || defined (__stub____snprintf)
37050 choke me
37051 #else
37052 char (*f) () = _snprintf;
37053 #endif
37054 #ifdef __cplusplus
37055 }
37056 #endif
37057
37058 int
37059 main ()
37060 {
37061 return f != _snprintf;
37062   ;
37063   return 0;
37064 }
37065 _ACEOF
37066 rm -f conftest.$ac_objext conftest$ac_exeext
37067 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37068   (eval $ac_link) 2>conftest.er1
37069   ac_status=$?
37070   grep -v '^ *+' conftest.er1 >conftest.err
37071   rm -f conftest.er1
37072   cat conftest.err >&5
37073   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37074   (exit $ac_status); } &&
37075          { ac_try='test -z "$ac_c_werror_flag"
37076                          || test ! -s conftest.err'
37077   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37078   (eval $ac_try) 2>&5
37079   ac_status=$?
37080   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37081   (exit $ac_status); }; } &&
37082          { ac_try='test -s conftest$ac_exeext'
37083   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37084   (eval $ac_try) 2>&5
37085   ac_status=$?
37086   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37087   (exit $ac_status); }; }; then
37088   ac_cv_func__snprintf=yes
37089 else
37090   echo "$as_me: failed program was:" >&5
37091 sed 's/^/| /' conftest.$ac_ext >&5
37092
37093 ac_cv_func__snprintf=no
37094 fi
37095 rm -f conftest.err conftest.$ac_objext \
37096       conftest$ac_exeext conftest.$ac_ext
37097 fi
37098 echo "$as_me:$LINENO: result: $ac_cv_func__snprintf" >&5
37099 echo "${ECHO_T}$ac_cv_func__snprintf" >&6
37100 if test $ac_cv_func__snprintf = yes; then
37101   ac_cv_func_snprintf=yes
37102
37103 cat >>confdefs.h <<\_ACEOF
37104 #define snprintf _snprintf
37105 _ACEOF
37106
37107
37108 fi
37109
37110
37111 echo "$as_me:$LINENO: checking for _vsnprintf" >&5
37112 echo $ECHO_N "checking for _vsnprintf... $ECHO_C" >&6
37113 if test "${ac_cv_func__vsnprintf+set}" = set; then
37114   echo $ECHO_N "(cached) $ECHO_C" >&6
37115 else
37116   cat >conftest.$ac_ext <<_ACEOF
37117 /* confdefs.h.  */
37118 _ACEOF
37119 cat confdefs.h >>conftest.$ac_ext
37120 cat >>conftest.$ac_ext <<_ACEOF
37121 /* end confdefs.h.  */
37122 /* Define _vsnprintf to an innocuous variant, in case <limits.h> declares _vsnprintf.
37123    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
37124 #define _vsnprintf innocuous__vsnprintf
37125
37126 /* System header to define __stub macros and hopefully few prototypes,
37127     which can conflict with char _vsnprintf (); below.
37128     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
37129     <limits.h> exists even on freestanding compilers.  */
37130
37131 #ifdef __STDC__
37132 # include <limits.h>
37133 #else
37134 # include <assert.h>
37135 #endif
37136
37137 #undef _vsnprintf
37138
37139 /* Override any gcc2 internal prototype to avoid an error.  */
37140 #ifdef __cplusplus
37141 extern "C"
37142 {
37143 #endif
37144 /* We use char because int might match the return type of a gcc2
37145    builtin and then its argument prototype would still apply.  */
37146 char _vsnprintf ();
37147 /* The GNU C library defines this for functions which it implements
37148     to always fail with ENOSYS.  Some functions are actually named
37149     something starting with __ and the normal name is an alias.  */
37150 #if defined (__stub__vsnprintf) || defined (__stub____vsnprintf)
37151 choke me
37152 #else
37153 char (*f) () = _vsnprintf;
37154 #endif
37155 #ifdef __cplusplus
37156 }
37157 #endif
37158
37159 int
37160 main ()
37161 {
37162 return f != _vsnprintf;
37163   ;
37164   return 0;
37165 }
37166 _ACEOF
37167 rm -f conftest.$ac_objext conftest$ac_exeext
37168 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37169   (eval $ac_link) 2>conftest.er1
37170   ac_status=$?
37171   grep -v '^ *+' conftest.er1 >conftest.err
37172   rm -f conftest.er1
37173   cat conftest.err >&5
37174   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37175   (exit $ac_status); } &&
37176          { ac_try='test -z "$ac_c_werror_flag"
37177                          || test ! -s conftest.err'
37178   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37179   (eval $ac_try) 2>&5
37180   ac_status=$?
37181   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37182   (exit $ac_status); }; } &&
37183          { ac_try='test -s conftest$ac_exeext'
37184   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37185   (eval $ac_try) 2>&5
37186   ac_status=$?
37187   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37188   (exit $ac_status); }; }; then
37189   ac_cv_func__vsnprintf=yes
37190 else
37191   echo "$as_me: failed program was:" >&5
37192 sed 's/^/| /' conftest.$ac_ext >&5
37193
37194 ac_cv_func__vsnprintf=no
37195 fi
37196 rm -f conftest.err conftest.$ac_objext \
37197       conftest$ac_exeext conftest.$ac_ext
37198 fi
37199 echo "$as_me:$LINENO: result: $ac_cv_func__vsnprintf" >&5
37200 echo "${ECHO_T}$ac_cv_func__vsnprintf" >&6
37201 if test $ac_cv_func__vsnprintf = yes; then
37202   ac_cv_func_vsnprintf=yes
37203
37204 cat >>confdefs.h <<\_ACEOF
37205 #define vsnprintf _vsnprintf
37206 _ACEOF
37207
37208
37209 fi
37210
37211
37212
37213 for ac_func in vprintf
37214 do
37215 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
37216 echo "$as_me:$LINENO: checking for $ac_func" >&5
37217 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
37218 if eval "test \"\${$as_ac_var+set}\" = set"; then
37219   echo $ECHO_N "(cached) $ECHO_C" >&6
37220 else
37221   cat >conftest.$ac_ext <<_ACEOF
37222 /* confdefs.h.  */
37223 _ACEOF
37224 cat confdefs.h >>conftest.$ac_ext
37225 cat >>conftest.$ac_ext <<_ACEOF
37226 /* end confdefs.h.  */
37227 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
37228    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
37229 #define $ac_func innocuous_$ac_func
37230
37231 /* System header to define __stub macros and hopefully few prototypes,
37232     which can conflict with char $ac_func (); below.
37233     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
37234     <limits.h> exists even on freestanding compilers.  */
37235
37236 #ifdef __STDC__
37237 # include <limits.h>
37238 #else
37239 # include <assert.h>
37240 #endif
37241
37242 #undef $ac_func
37243
37244 /* Override any gcc2 internal prototype to avoid an error.  */
37245 #ifdef __cplusplus
37246 extern "C"
37247 {
37248 #endif
37249 /* We use char because int might match the return type of a gcc2
37250    builtin and then its argument prototype would still apply.  */
37251 char $ac_func ();
37252 /* The GNU C library defines this for functions which it implements
37253     to always fail with ENOSYS.  Some functions are actually named
37254     something starting with __ and the normal name is an alias.  */
37255 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
37256 choke me
37257 #else
37258 char (*f) () = $ac_func;
37259 #endif
37260 #ifdef __cplusplus
37261 }
37262 #endif
37263
37264 int
37265 main ()
37266 {
37267 return f != $ac_func;
37268   ;
37269   return 0;
37270 }
37271 _ACEOF
37272 rm -f conftest.$ac_objext conftest$ac_exeext
37273 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37274   (eval $ac_link) 2>conftest.er1
37275   ac_status=$?
37276   grep -v '^ *+' conftest.er1 >conftest.err
37277   rm -f conftest.er1
37278   cat conftest.err >&5
37279   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37280   (exit $ac_status); } &&
37281          { ac_try='test -z "$ac_c_werror_flag"
37282                          || test ! -s conftest.err'
37283   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37284   (eval $ac_try) 2>&5
37285   ac_status=$?
37286   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37287   (exit $ac_status); }; } &&
37288          { ac_try='test -s conftest$ac_exeext'
37289   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37290   (eval $ac_try) 2>&5
37291   ac_status=$?
37292   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37293   (exit $ac_status); }; }; then
37294   eval "$as_ac_var=yes"
37295 else
37296   echo "$as_me: failed program was:" >&5
37297 sed 's/^/| /' conftest.$ac_ext >&5
37298
37299 eval "$as_ac_var=no"
37300 fi
37301 rm -f conftest.err conftest.$ac_objext \
37302       conftest$ac_exeext conftest.$ac_ext
37303 fi
37304 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
37305 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
37306 if test `eval echo '${'$as_ac_var'}'` = yes; then
37307   cat >>confdefs.h <<_ACEOF
37308 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
37309 _ACEOF
37310
37311 echo "$as_me:$LINENO: checking for _doprnt" >&5
37312 echo $ECHO_N "checking for _doprnt... $ECHO_C" >&6
37313 if test "${ac_cv_func__doprnt+set}" = set; then
37314   echo $ECHO_N "(cached) $ECHO_C" >&6
37315 else
37316   cat >conftest.$ac_ext <<_ACEOF
37317 /* confdefs.h.  */
37318 _ACEOF
37319 cat confdefs.h >>conftest.$ac_ext
37320 cat >>conftest.$ac_ext <<_ACEOF
37321 /* end confdefs.h.  */
37322 /* Define _doprnt to an innocuous variant, in case <limits.h> declares _doprnt.
37323    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
37324 #define _doprnt innocuous__doprnt
37325
37326 /* System header to define __stub macros and hopefully few prototypes,
37327     which can conflict with char _doprnt (); below.
37328     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
37329     <limits.h> exists even on freestanding compilers.  */
37330
37331 #ifdef __STDC__
37332 # include <limits.h>
37333 #else
37334 # include <assert.h>
37335 #endif
37336
37337 #undef _doprnt
37338
37339 /* Override any gcc2 internal prototype to avoid an error.  */
37340 #ifdef __cplusplus
37341 extern "C"
37342 {
37343 #endif
37344 /* We use char because int might match the return type of a gcc2
37345    builtin and then its argument prototype would still apply.  */
37346 char _doprnt ();
37347 /* The GNU C library defines this for functions which it implements
37348     to always fail with ENOSYS.  Some functions are actually named
37349     something starting with __ and the normal name is an alias.  */
37350 #if defined (__stub__doprnt) || defined (__stub____doprnt)
37351 choke me
37352 #else
37353 char (*f) () = _doprnt;
37354 #endif
37355 #ifdef __cplusplus
37356 }
37357 #endif
37358
37359 int
37360 main ()
37361 {
37362 return f != _doprnt;
37363   ;
37364   return 0;
37365 }
37366 _ACEOF
37367 rm -f conftest.$ac_objext conftest$ac_exeext
37368 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37369   (eval $ac_link) 2>conftest.er1
37370   ac_status=$?
37371   grep -v '^ *+' conftest.er1 >conftest.err
37372   rm -f conftest.er1
37373   cat conftest.err >&5
37374   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37375   (exit $ac_status); } &&
37376          { ac_try='test -z "$ac_c_werror_flag"
37377                          || test ! -s conftest.err'
37378   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37379   (eval $ac_try) 2>&5
37380   ac_status=$?
37381   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37382   (exit $ac_status); }; } &&
37383          { ac_try='test -s conftest$ac_exeext'
37384   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37385   (eval $ac_try) 2>&5
37386   ac_status=$?
37387   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37388   (exit $ac_status); }; }; then
37389   ac_cv_func__doprnt=yes
37390 else
37391   echo "$as_me: failed program was:" >&5
37392 sed 's/^/| /' conftest.$ac_ext >&5
37393
37394 ac_cv_func__doprnt=no
37395 fi
37396 rm -f conftest.err conftest.$ac_objext \
37397       conftest$ac_exeext conftest.$ac_ext
37398 fi
37399 echo "$as_me:$LINENO: result: $ac_cv_func__doprnt" >&5
37400 echo "${ECHO_T}$ac_cv_func__doprnt" >&6
37401 if test $ac_cv_func__doprnt = yes; then
37402
37403 cat >>confdefs.h <<\_ACEOF
37404 #define HAVE_DOPRNT 1
37405 _ACEOF
37406
37407 fi
37408
37409 fi
37410 done
37411
37412
37413
37414 if test $ac_cv_func_vprintf = yes ; then
37415
37416
37417 for ac_func in snprintf vsnprintf
37418 do
37419 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
37420 echo "$as_me:$LINENO: checking for $ac_func" >&5
37421 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
37422 if eval "test \"\${$as_ac_var+set}\" = set"; then
37423   echo $ECHO_N "(cached) $ECHO_C" >&6
37424 else
37425   cat >conftest.$ac_ext <<_ACEOF
37426 /* confdefs.h.  */
37427 _ACEOF
37428 cat confdefs.h >>conftest.$ac_ext
37429 cat >>conftest.$ac_ext <<_ACEOF
37430 /* end confdefs.h.  */
37431 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
37432    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
37433 #define $ac_func innocuous_$ac_func
37434
37435 /* System header to define __stub macros and hopefully few prototypes,
37436     which can conflict with char $ac_func (); below.
37437     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
37438     <limits.h> exists even on freestanding compilers.  */
37439
37440 #ifdef __STDC__
37441 # include <limits.h>
37442 #else
37443 # include <assert.h>
37444 #endif
37445
37446 #undef $ac_func
37447
37448 /* Override any gcc2 internal prototype to avoid an error.  */
37449 #ifdef __cplusplus
37450 extern "C"
37451 {
37452 #endif
37453 /* We use char because int might match the return type of a gcc2
37454    builtin and then its argument prototype would still apply.  */
37455 char $ac_func ();
37456 /* The GNU C library defines this for functions which it implements
37457     to always fail with ENOSYS.  Some functions are actually named
37458     something starting with __ and the normal name is an alias.  */
37459 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
37460 choke me
37461 #else
37462 char (*f) () = $ac_func;
37463 #endif
37464 #ifdef __cplusplus
37465 }
37466 #endif
37467
37468 int
37469 main ()
37470 {
37471 return f != $ac_func;
37472   ;
37473   return 0;
37474 }
37475 _ACEOF
37476 rm -f conftest.$ac_objext conftest$ac_exeext
37477 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37478   (eval $ac_link) 2>conftest.er1
37479   ac_status=$?
37480   grep -v '^ *+' conftest.er1 >conftest.err
37481   rm -f conftest.er1
37482   cat conftest.err >&5
37483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37484   (exit $ac_status); } &&
37485          { ac_try='test -z "$ac_c_werror_flag"
37486                          || test ! -s conftest.err'
37487   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37488   (eval $ac_try) 2>&5
37489   ac_status=$?
37490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37491   (exit $ac_status); }; } &&
37492          { ac_try='test -s conftest$ac_exeext'
37493   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37494   (eval $ac_try) 2>&5
37495   ac_status=$?
37496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37497   (exit $ac_status); }; }; then
37498   eval "$as_ac_var=yes"
37499 else
37500   echo "$as_me: failed program was:" >&5
37501 sed 's/^/| /' conftest.$ac_ext >&5
37502
37503 eval "$as_ac_var=no"
37504 fi
37505 rm -f conftest.err conftest.$ac_objext \
37506       conftest$ac_exeext conftest.$ac_ext
37507 fi
37508 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
37509 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
37510 if test `eval echo '${'$as_ac_var'}'` = yes; then
37511   cat >>confdefs.h <<_ACEOF
37512 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
37513 _ACEOF
37514
37515 fi
37516 done
37517
37518 fi
37519
37520
37521
37522
37523
37524
37525
37526
37527
37528
37529
37530
37531
37532
37533
37534
37535
37536
37537
37538
37539
37540
37541
37542
37543
37544
37545
37546
37547
37548
37549
37550
37551
37552
37553
37554
37555
37556
37557
37558
37559
37560
37561
37562
37563
37564
37565
37566
37567
37568
37569
37570
37571
37572
37573
37574
37575 for ac_func in \
37576         bcopy                   \
37577         closesocket             \
37578         chroot                  \
37579         endgrent                \
37580         endpwent                \
37581         fcntl                   \
37582         flock                   \
37583         fstat                   \
37584         getdtablesize           \
37585         getgrgid                \
37586         gethostname             \
37587         getpass                 \
37588         getpassphrase           \
37589         getpwuid                \
37590         getpwnam                \
37591         getspnam                \
37592         gettimeofday            \
37593         initgroups              \
37594         inet_ntoa_b             \
37595         ioctl                   \
37596         lockf                   \
37597         memcpy                  \
37598         memmove                 \
37599         memrchr                 \
37600         mkstemp                 \
37601         mktemp                  \
37602         pipe                    \
37603         read                    \
37604         recv                    \
37605         recvfrom                \
37606         setpwfile               \
37607         setgid                  \
37608         setegid                 \
37609         setsid                  \
37610         setuid                  \
37611         seteuid                 \
37612         signal                  \
37613         strdup                  \
37614         strpbrk                 \
37615         strrchr                 \
37616         strsep                  \
37617         strstr                  \
37618         strtol                  \
37619         strtoul                 \
37620         strtoq                  \
37621         strtouq                 \
37622         strtoll                 \
37623         strspn                  \
37624         sysconf                 \
37625         waitpid                 \
37626         wait4                   \
37627         write                   \
37628         send                    \
37629         sendmsg                 \
37630         sendto                  \
37631
37632 do
37633 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
37634 echo "$as_me:$LINENO: checking for $ac_func" >&5
37635 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
37636 if eval "test \"\${$as_ac_var+set}\" = set"; then
37637   echo $ECHO_N "(cached) $ECHO_C" >&6
37638 else
37639   cat >conftest.$ac_ext <<_ACEOF
37640 /* confdefs.h.  */
37641 _ACEOF
37642 cat confdefs.h >>conftest.$ac_ext
37643 cat >>conftest.$ac_ext <<_ACEOF
37644 /* end confdefs.h.  */
37645 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
37646    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
37647 #define $ac_func innocuous_$ac_func
37648
37649 /* System header to define __stub macros and hopefully few prototypes,
37650     which can conflict with char $ac_func (); below.
37651     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
37652     <limits.h> exists even on freestanding compilers.  */
37653
37654 #ifdef __STDC__
37655 # include <limits.h>
37656 #else
37657 # include <assert.h>
37658 #endif
37659
37660 #undef $ac_func
37661
37662 /* Override any gcc2 internal prototype to avoid an error.  */
37663 #ifdef __cplusplus
37664 extern "C"
37665 {
37666 #endif
37667 /* We use char because int might match the return type of a gcc2
37668    builtin and then its argument prototype would still apply.  */
37669 char $ac_func ();
37670 /* The GNU C library defines this for functions which it implements
37671     to always fail with ENOSYS.  Some functions are actually named
37672     something starting with __ and the normal name is an alias.  */
37673 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
37674 choke me
37675 #else
37676 char (*f) () = $ac_func;
37677 #endif
37678 #ifdef __cplusplus
37679 }
37680 #endif
37681
37682 int
37683 main ()
37684 {
37685 return f != $ac_func;
37686   ;
37687   return 0;
37688 }
37689 _ACEOF
37690 rm -f conftest.$ac_objext conftest$ac_exeext
37691 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37692   (eval $ac_link) 2>conftest.er1
37693   ac_status=$?
37694   grep -v '^ *+' conftest.er1 >conftest.err
37695   rm -f conftest.er1
37696   cat conftest.err >&5
37697   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37698   (exit $ac_status); } &&
37699          { ac_try='test -z "$ac_c_werror_flag"
37700                          || test ! -s conftest.err'
37701   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37702   (eval $ac_try) 2>&5
37703   ac_status=$?
37704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37705   (exit $ac_status); }; } &&
37706          { ac_try='test -s conftest$ac_exeext'
37707   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37708   (eval $ac_try) 2>&5
37709   ac_status=$?
37710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37711   (exit $ac_status); }; }; then
37712   eval "$as_ac_var=yes"
37713 else
37714   echo "$as_me: failed program was:" >&5
37715 sed 's/^/| /' conftest.$ac_ext >&5
37716
37717 eval "$as_ac_var=no"
37718 fi
37719 rm -f conftest.err conftest.$ac_objext \
37720       conftest$ac_exeext conftest.$ac_ext
37721 fi
37722 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
37723 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
37724 if test `eval echo '${'$as_ac_var'}'` = yes; then
37725   cat >>confdefs.h <<_ACEOF
37726 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
37727 _ACEOF
37728
37729 fi
37730 done
37731
37732
37733
37734
37735 for ac_func in getopt getpeereid
37736 do
37737 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
37738 echo "$as_me:$LINENO: checking for $ac_func" >&5
37739 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
37740 if eval "test \"\${$as_ac_var+set}\" = set"; then
37741   echo $ECHO_N "(cached) $ECHO_C" >&6
37742 else
37743   cat >conftest.$ac_ext <<_ACEOF
37744 /* confdefs.h.  */
37745 _ACEOF
37746 cat confdefs.h >>conftest.$ac_ext
37747 cat >>conftest.$ac_ext <<_ACEOF
37748 /* end confdefs.h.  */
37749 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
37750    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
37751 #define $ac_func innocuous_$ac_func
37752
37753 /* System header to define __stub macros and hopefully few prototypes,
37754     which can conflict with char $ac_func (); below.
37755     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
37756     <limits.h> exists even on freestanding compilers.  */
37757
37758 #ifdef __STDC__
37759 # include <limits.h>
37760 #else
37761 # include <assert.h>
37762 #endif
37763
37764 #undef $ac_func
37765
37766 /* Override any gcc2 internal prototype to avoid an error.  */
37767 #ifdef __cplusplus
37768 extern "C"
37769 {
37770 #endif
37771 /* We use char because int might match the return type of a gcc2
37772    builtin and then its argument prototype would still apply.  */
37773 char $ac_func ();
37774 /* The GNU C library defines this for functions which it implements
37775     to always fail with ENOSYS.  Some functions are actually named
37776     something starting with __ and the normal name is an alias.  */
37777 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
37778 choke me
37779 #else
37780 char (*f) () = $ac_func;
37781 #endif
37782 #ifdef __cplusplus
37783 }
37784 #endif
37785
37786 int
37787 main ()
37788 {
37789 return f != $ac_func;
37790   ;
37791   return 0;
37792 }
37793 _ACEOF
37794 rm -f conftest.$ac_objext conftest$ac_exeext
37795 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37796   (eval $ac_link) 2>conftest.er1
37797   ac_status=$?
37798   grep -v '^ *+' conftest.er1 >conftest.err
37799   rm -f conftest.er1
37800   cat conftest.err >&5
37801   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37802   (exit $ac_status); } &&
37803          { ac_try='test -z "$ac_c_werror_flag"
37804                          || test ! -s conftest.err'
37805   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37806   (eval $ac_try) 2>&5
37807   ac_status=$?
37808   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37809   (exit $ac_status); }; } &&
37810          { ac_try='test -s conftest$ac_exeext'
37811   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37812   (eval $ac_try) 2>&5
37813   ac_status=$?
37814   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37815   (exit $ac_status); }; }; then
37816   eval "$as_ac_var=yes"
37817 else
37818   echo "$as_me: failed program was:" >&5
37819 sed 's/^/| /' conftest.$ac_ext >&5
37820
37821 eval "$as_ac_var=no"
37822 fi
37823 rm -f conftest.err conftest.$ac_objext \
37824       conftest$ac_exeext conftest.$ac_ext
37825 fi
37826 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
37827 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
37828 if test `eval echo '${'$as_ac_var'}'` = yes; then
37829   cat >>confdefs.h <<_ACEOF
37830 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
37831 _ACEOF
37832
37833 else
37834   case $LIBOBJS in
37835     "$ac_func.$ac_objext"   | \
37836   *" $ac_func.$ac_objext"   | \
37837     "$ac_func.$ac_objext "* | \
37838   *" $ac_func.$ac_objext "* ) ;;
37839   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
37840 esac
37841
37842 fi
37843 done
37844
37845
37846
37847 if test "$ac_cv_func_getopt" != yes; then
37848         LIBSRCS="$LIBSRCS getopt.c"
37849 fi
37850
37851 if test "$ac_cv_func_getpeereid" != yes; then
37852
37853 for ac_func in getpeerucred
37854 do
37855 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
37856 echo "$as_me:$LINENO: checking for $ac_func" >&5
37857 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
37858 if eval "test \"\${$as_ac_var+set}\" = set"; then
37859   echo $ECHO_N "(cached) $ECHO_C" >&6
37860 else
37861   cat >conftest.$ac_ext <<_ACEOF
37862 /* confdefs.h.  */
37863 _ACEOF
37864 cat confdefs.h >>conftest.$ac_ext
37865 cat >>conftest.$ac_ext <<_ACEOF
37866 /* end confdefs.h.  */
37867 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
37868    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
37869 #define $ac_func innocuous_$ac_func
37870
37871 /* System header to define __stub macros and hopefully few prototypes,
37872     which can conflict with char $ac_func (); below.
37873     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
37874     <limits.h> exists even on freestanding compilers.  */
37875
37876 #ifdef __STDC__
37877 # include <limits.h>
37878 #else
37879 # include <assert.h>
37880 #endif
37881
37882 #undef $ac_func
37883
37884 /* Override any gcc2 internal prototype to avoid an error.  */
37885 #ifdef __cplusplus
37886 extern "C"
37887 {
37888 #endif
37889 /* We use char because int might match the return type of a gcc2
37890    builtin and then its argument prototype would still apply.  */
37891 char $ac_func ();
37892 /* The GNU C library defines this for functions which it implements
37893     to always fail with ENOSYS.  Some functions are actually named
37894     something starting with __ and the normal name is an alias.  */
37895 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
37896 choke me
37897 #else
37898 char (*f) () = $ac_func;
37899 #endif
37900 #ifdef __cplusplus
37901 }
37902 #endif
37903
37904 int
37905 main ()
37906 {
37907 return f != $ac_func;
37908   ;
37909   return 0;
37910 }
37911 _ACEOF
37912 rm -f conftest.$ac_objext conftest$ac_exeext
37913 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
37914   (eval $ac_link) 2>conftest.er1
37915   ac_status=$?
37916   grep -v '^ *+' conftest.er1 >conftest.err
37917   rm -f conftest.er1
37918   cat conftest.err >&5
37919   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37920   (exit $ac_status); } &&
37921          { ac_try='test -z "$ac_c_werror_flag"
37922                          || test ! -s conftest.err'
37923   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37924   (eval $ac_try) 2>&5
37925   ac_status=$?
37926   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37927   (exit $ac_status); }; } &&
37928          { ac_try='test -s conftest$ac_exeext'
37929   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37930   (eval $ac_try) 2>&5
37931   ac_status=$?
37932   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37933   (exit $ac_status); }; }; then
37934   eval "$as_ac_var=yes"
37935 else
37936   echo "$as_me: failed program was:" >&5
37937 sed 's/^/| /' conftest.$ac_ext >&5
37938
37939 eval "$as_ac_var=no"
37940 fi
37941 rm -f conftest.err conftest.$ac_objext \
37942       conftest$ac_exeext conftest.$ac_ext
37943 fi
37944 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
37945 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
37946 if test `eval echo '${'$as_ac_var'}'` = yes; then
37947   cat >>confdefs.h <<_ACEOF
37948 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
37949 _ACEOF
37950
37951 fi
37952 done
37953
37954         if test "$ac_cv_func_getpeerucred" != yes ; then
37955                 echo "$as_me:$LINENO: checking for struct msghdr.msg_accrightslen" >&5
37956 echo $ECHO_N "checking for struct msghdr.msg_accrightslen... $ECHO_C" >&6
37957 if test "${ac_cv_member_struct_msghdr_msg_accrightslen+set}" = set; then
37958   echo $ECHO_N "(cached) $ECHO_C" >&6
37959 else
37960   cat >conftest.$ac_ext <<_ACEOF
37961 /* confdefs.h.  */
37962 _ACEOF
37963 cat confdefs.h >>conftest.$ac_ext
37964 cat >>conftest.$ac_ext <<_ACEOF
37965 /* end confdefs.h.  */
37966 $ac_includes_default
37967 #ifdef HAVE_SYS_SOCKET_H
37968 #include <sys/socket.h>
37969 #endif
37970
37971 int
37972 main ()
37973 {
37974 static struct msghdr ac_aggr;
37975 if (ac_aggr.msg_accrightslen)
37976 return 0;
37977   ;
37978   return 0;
37979 }
37980 _ACEOF
37981 rm -f conftest.$ac_objext
37982 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
37983   (eval $ac_compile) 2>conftest.er1
37984   ac_status=$?
37985   grep -v '^ *+' conftest.er1 >conftest.err
37986   rm -f conftest.er1
37987   cat conftest.err >&5
37988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37989   (exit $ac_status); } &&
37990          { ac_try='test -z "$ac_c_werror_flag"
37991                          || test ! -s conftest.err'
37992   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37993   (eval $ac_try) 2>&5
37994   ac_status=$?
37995   echo "$as_me:$LINENO: \$? = $ac_status" >&5
37996   (exit $ac_status); }; } &&
37997          { ac_try='test -s conftest.$ac_objext'
37998   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
37999   (eval $ac_try) 2>&5
38000   ac_status=$?
38001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38002   (exit $ac_status); }; }; then
38003   ac_cv_member_struct_msghdr_msg_accrightslen=yes
38004 else
38005   echo "$as_me: failed program was:" >&5
38006 sed 's/^/| /' conftest.$ac_ext >&5
38007
38008 cat >conftest.$ac_ext <<_ACEOF
38009 /* confdefs.h.  */
38010 _ACEOF
38011 cat confdefs.h >>conftest.$ac_ext
38012 cat >>conftest.$ac_ext <<_ACEOF
38013 /* end confdefs.h.  */
38014 $ac_includes_default
38015 #ifdef HAVE_SYS_SOCKET_H
38016 #include <sys/socket.h>
38017 #endif
38018
38019 int
38020 main ()
38021 {
38022 static struct msghdr ac_aggr;
38023 if (sizeof ac_aggr.msg_accrightslen)
38024 return 0;
38025   ;
38026   return 0;
38027 }
38028 _ACEOF
38029 rm -f conftest.$ac_objext
38030 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
38031   (eval $ac_compile) 2>conftest.er1
38032   ac_status=$?
38033   grep -v '^ *+' conftest.er1 >conftest.err
38034   rm -f conftest.er1
38035   cat conftest.err >&5
38036   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38037   (exit $ac_status); } &&
38038          { ac_try='test -z "$ac_c_werror_flag"
38039                          || test ! -s conftest.err'
38040   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38041   (eval $ac_try) 2>&5
38042   ac_status=$?
38043   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38044   (exit $ac_status); }; } &&
38045          { ac_try='test -s conftest.$ac_objext'
38046   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38047   (eval $ac_try) 2>&5
38048   ac_status=$?
38049   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38050   (exit $ac_status); }; }; then
38051   ac_cv_member_struct_msghdr_msg_accrightslen=yes
38052 else
38053   echo "$as_me: failed program was:" >&5
38054 sed 's/^/| /' conftest.$ac_ext >&5
38055
38056 ac_cv_member_struct_msghdr_msg_accrightslen=no
38057 fi
38058 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
38059 fi
38060 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
38061 fi
38062 echo "$as_me:$LINENO: result: $ac_cv_member_struct_msghdr_msg_accrightslen" >&5
38063 echo "${ECHO_T}$ac_cv_member_struct_msghdr_msg_accrightslen" >&6
38064 if test $ac_cv_member_struct_msghdr_msg_accrightslen = yes; then
38065
38066 cat >>confdefs.h <<_ACEOF
38067 #define HAVE_STRUCT_MSGHDR_MSG_ACCRIGHTSLEN 1
38068 _ACEOF
38069
38070
38071 fi
38072
38073                 if test "$ac_cv_member_struct_msghdr_msg_accrightslen" != yes; then
38074                         echo "$as_me:$LINENO: checking for struct msghdr.msg_control" >&5
38075 echo $ECHO_N "checking for struct msghdr.msg_control... $ECHO_C" >&6
38076 if test "${ac_cv_member_struct_msghdr_msg_control+set}" = set; then
38077   echo $ECHO_N "(cached) $ECHO_C" >&6
38078 else
38079   cat >conftest.$ac_ext <<_ACEOF
38080 /* confdefs.h.  */
38081 _ACEOF
38082 cat confdefs.h >>conftest.$ac_ext
38083 cat >>conftest.$ac_ext <<_ACEOF
38084 /* end confdefs.h.  */
38085 $ac_includes_default
38086 #ifdef HAVE_SYS_SOCKET_H
38087 #include <sys/socket.h>
38088 #endif
38089
38090 int
38091 main ()
38092 {
38093 static struct msghdr ac_aggr;
38094 if (ac_aggr.msg_control)
38095 return 0;
38096   ;
38097   return 0;
38098 }
38099 _ACEOF
38100 rm -f conftest.$ac_objext
38101 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
38102   (eval $ac_compile) 2>conftest.er1
38103   ac_status=$?
38104   grep -v '^ *+' conftest.er1 >conftest.err
38105   rm -f conftest.er1
38106   cat conftest.err >&5
38107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38108   (exit $ac_status); } &&
38109          { ac_try='test -z "$ac_c_werror_flag"
38110                          || test ! -s conftest.err'
38111   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38112   (eval $ac_try) 2>&5
38113   ac_status=$?
38114   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38115   (exit $ac_status); }; } &&
38116          { ac_try='test -s conftest.$ac_objext'
38117   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38118   (eval $ac_try) 2>&5
38119   ac_status=$?
38120   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38121   (exit $ac_status); }; }; then
38122   ac_cv_member_struct_msghdr_msg_control=yes
38123 else
38124   echo "$as_me: failed program was:" >&5
38125 sed 's/^/| /' conftest.$ac_ext >&5
38126
38127 cat >conftest.$ac_ext <<_ACEOF
38128 /* confdefs.h.  */
38129 _ACEOF
38130 cat confdefs.h >>conftest.$ac_ext
38131 cat >>conftest.$ac_ext <<_ACEOF
38132 /* end confdefs.h.  */
38133 $ac_includes_default
38134 #ifdef HAVE_SYS_SOCKET_H
38135 #include <sys/socket.h>
38136 #endif
38137
38138 int
38139 main ()
38140 {
38141 static struct msghdr ac_aggr;
38142 if (sizeof ac_aggr.msg_control)
38143 return 0;
38144   ;
38145   return 0;
38146 }
38147 _ACEOF
38148 rm -f conftest.$ac_objext
38149 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
38150   (eval $ac_compile) 2>conftest.er1
38151   ac_status=$?
38152   grep -v '^ *+' conftest.er1 >conftest.err
38153   rm -f conftest.er1
38154   cat conftest.err >&5
38155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38156   (exit $ac_status); } &&
38157          { ac_try='test -z "$ac_c_werror_flag"
38158                          || test ! -s conftest.err'
38159   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38160   (eval $ac_try) 2>&5
38161   ac_status=$?
38162   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38163   (exit $ac_status); }; } &&
38164          { ac_try='test -s conftest.$ac_objext'
38165   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38166   (eval $ac_try) 2>&5
38167   ac_status=$?
38168   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38169   (exit $ac_status); }; }; then
38170   ac_cv_member_struct_msghdr_msg_control=yes
38171 else
38172   echo "$as_me: failed program was:" >&5
38173 sed 's/^/| /' conftest.$ac_ext >&5
38174
38175 ac_cv_member_struct_msghdr_msg_control=no
38176 fi
38177 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
38178 fi
38179 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
38180 fi
38181 echo "$as_me:$LINENO: result: $ac_cv_member_struct_msghdr_msg_control" >&5
38182 echo "${ECHO_T}$ac_cv_member_struct_msghdr_msg_control" >&6
38183 if test $ac_cv_member_struct_msghdr_msg_control = yes; then
38184
38185 cat >>confdefs.h <<_ACEOF
38186 #define HAVE_STRUCT_MSGHDR_MSG_CONTROL 1
38187 _ACEOF
38188
38189
38190 fi
38191
38192                 fi
38193                 echo "$as_me:$LINENO: checking for struct stat.st_fstype" >&5
38194 echo $ECHO_N "checking for struct stat.st_fstype... $ECHO_C" >&6
38195 if test "${ac_cv_member_struct_stat_st_fstype+set}" = set; then
38196   echo $ECHO_N "(cached) $ECHO_C" >&6
38197 else
38198   cat >conftest.$ac_ext <<_ACEOF
38199 /* confdefs.h.  */
38200 _ACEOF
38201 cat confdefs.h >>conftest.$ac_ext
38202 cat >>conftest.$ac_ext <<_ACEOF
38203 /* end confdefs.h.  */
38204 $ac_includes_default
38205 int
38206 main ()
38207 {
38208 static struct stat ac_aggr;
38209 if (ac_aggr.st_fstype)
38210 return 0;
38211   ;
38212   return 0;
38213 }
38214 _ACEOF
38215 rm -f conftest.$ac_objext
38216 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
38217   (eval $ac_compile) 2>conftest.er1
38218   ac_status=$?
38219   grep -v '^ *+' conftest.er1 >conftest.err
38220   rm -f conftest.er1
38221   cat conftest.err >&5
38222   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38223   (exit $ac_status); } &&
38224          { ac_try='test -z "$ac_c_werror_flag"
38225                          || test ! -s conftest.err'
38226   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38227   (eval $ac_try) 2>&5
38228   ac_status=$?
38229   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38230   (exit $ac_status); }; } &&
38231          { ac_try='test -s conftest.$ac_objext'
38232   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38233   (eval $ac_try) 2>&5
38234   ac_status=$?
38235   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38236   (exit $ac_status); }; }; then
38237   ac_cv_member_struct_stat_st_fstype=yes
38238 else
38239   echo "$as_me: failed program was:" >&5
38240 sed 's/^/| /' conftest.$ac_ext >&5
38241
38242 cat >conftest.$ac_ext <<_ACEOF
38243 /* confdefs.h.  */
38244 _ACEOF
38245 cat confdefs.h >>conftest.$ac_ext
38246 cat >>conftest.$ac_ext <<_ACEOF
38247 /* end confdefs.h.  */
38248 $ac_includes_default
38249 int
38250 main ()
38251 {
38252 static struct stat ac_aggr;
38253 if (sizeof ac_aggr.st_fstype)
38254 return 0;
38255   ;
38256   return 0;
38257 }
38258 _ACEOF
38259 rm -f conftest.$ac_objext
38260 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
38261   (eval $ac_compile) 2>conftest.er1
38262   ac_status=$?
38263   grep -v '^ *+' conftest.er1 >conftest.err
38264   rm -f conftest.er1
38265   cat conftest.err >&5
38266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38267   (exit $ac_status); } &&
38268          { ac_try='test -z "$ac_c_werror_flag"
38269                          || test ! -s conftest.err'
38270   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38271   (eval $ac_try) 2>&5
38272   ac_status=$?
38273   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38274   (exit $ac_status); }; } &&
38275          { ac_try='test -s conftest.$ac_objext'
38276   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38277   (eval $ac_try) 2>&5
38278   ac_status=$?
38279   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38280   (exit $ac_status); }; }; then
38281   ac_cv_member_struct_stat_st_fstype=yes
38282 else
38283   echo "$as_me: failed program was:" >&5
38284 sed 's/^/| /' conftest.$ac_ext >&5
38285
38286 ac_cv_member_struct_stat_st_fstype=no
38287 fi
38288 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
38289 fi
38290 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
38291 fi
38292 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_fstype" >&5
38293 echo "${ECHO_T}$ac_cv_member_struct_stat_st_fstype" >&6
38294 if test $ac_cv_member_struct_stat_st_fstype = yes; then
38295
38296 cat >>confdefs.h <<_ACEOF
38297 #define HAVE_STRUCT_STAT_ST_FSTYPE 1
38298 _ACEOF
38299
38300
38301 fi
38302 echo "$as_me:$LINENO: checking for struct stat.st_vfstype" >&5
38303 echo $ECHO_N "checking for struct stat.st_vfstype... $ECHO_C" >&6
38304 if test "${ac_cv_member_struct_stat_st_vfstype+set}" = set; then
38305   echo $ECHO_N "(cached) $ECHO_C" >&6
38306 else
38307   cat >conftest.$ac_ext <<_ACEOF
38308 /* confdefs.h.  */
38309 _ACEOF
38310 cat confdefs.h >>conftest.$ac_ext
38311 cat >>conftest.$ac_ext <<_ACEOF
38312 /* end confdefs.h.  */
38313 $ac_includes_default
38314 int
38315 main ()
38316 {
38317 static struct stat ac_aggr;
38318 if (ac_aggr.st_vfstype)
38319 return 0;
38320   ;
38321   return 0;
38322 }
38323 _ACEOF
38324 rm -f conftest.$ac_objext
38325 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
38326   (eval $ac_compile) 2>conftest.er1
38327   ac_status=$?
38328   grep -v '^ *+' conftest.er1 >conftest.err
38329   rm -f conftest.er1
38330   cat conftest.err >&5
38331   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38332   (exit $ac_status); } &&
38333          { ac_try='test -z "$ac_c_werror_flag"
38334                          || test ! -s conftest.err'
38335   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38336   (eval $ac_try) 2>&5
38337   ac_status=$?
38338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38339   (exit $ac_status); }; } &&
38340          { ac_try='test -s conftest.$ac_objext'
38341   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38342   (eval $ac_try) 2>&5
38343   ac_status=$?
38344   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38345   (exit $ac_status); }; }; then
38346   ac_cv_member_struct_stat_st_vfstype=yes
38347 else
38348   echo "$as_me: failed program was:" >&5
38349 sed 's/^/| /' conftest.$ac_ext >&5
38350
38351 cat >conftest.$ac_ext <<_ACEOF
38352 /* confdefs.h.  */
38353 _ACEOF
38354 cat confdefs.h >>conftest.$ac_ext
38355 cat >>conftest.$ac_ext <<_ACEOF
38356 /* end confdefs.h.  */
38357 $ac_includes_default
38358 int
38359 main ()
38360 {
38361 static struct stat ac_aggr;
38362 if (sizeof ac_aggr.st_vfstype)
38363 return 0;
38364   ;
38365   return 0;
38366 }
38367 _ACEOF
38368 rm -f conftest.$ac_objext
38369 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
38370   (eval $ac_compile) 2>conftest.er1
38371   ac_status=$?
38372   grep -v '^ *+' conftest.er1 >conftest.err
38373   rm -f conftest.er1
38374   cat conftest.err >&5
38375   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38376   (exit $ac_status); } &&
38377          { ac_try='test -z "$ac_c_werror_flag"
38378                          || test ! -s conftest.err'
38379   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38380   (eval $ac_try) 2>&5
38381   ac_status=$?
38382   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38383   (exit $ac_status); }; } &&
38384          { ac_try='test -s conftest.$ac_objext'
38385   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38386   (eval $ac_try) 2>&5
38387   ac_status=$?
38388   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38389   (exit $ac_status); }; }; then
38390   ac_cv_member_struct_stat_st_vfstype=yes
38391 else
38392   echo "$as_me: failed program was:" >&5
38393 sed 's/^/| /' conftest.$ac_ext >&5
38394
38395 ac_cv_member_struct_stat_st_vfstype=no
38396 fi
38397 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
38398 fi
38399 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
38400 fi
38401 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_vfstype" >&5
38402 echo "${ECHO_T}$ac_cv_member_struct_stat_st_vfstype" >&6
38403 if test $ac_cv_member_struct_stat_st_vfstype = yes; then
38404
38405 cat >>confdefs.h <<_ACEOF
38406 #define HAVE_STRUCT_STAT_ST_VFSTYPE 1
38407 _ACEOF
38408
38409
38410 fi
38411
38412                 if test "$ac_cv_member_struct_stat_st_fstype" = yes; then
38413                         cat >conftest.$ac_ext <<_ACEOF
38414 struct stat st; char *ptr=st.st_fstype;
38415 _ACEOF
38416 rm -f conftest.$ac_objext
38417 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
38418   (eval $ac_compile) 2>conftest.er1
38419   ac_status=$?
38420   grep -v '^ *+' conftest.er1 >conftest.err
38421   rm -f conftest.er1
38422   cat conftest.err >&5
38423   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38424   (exit $ac_status); } &&
38425          { ac_try='test -z "$ac_c_werror_flag"
38426                          || test ! -s conftest.err'
38427   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38428   (eval $ac_try) 2>&5
38429   ac_status=$?
38430   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38431   (exit $ac_status); }; } &&
38432          { ac_try='test -s conftest.$ac_objext'
38433   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38434   (eval $ac_try) 2>&5
38435   ac_status=$?
38436   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38437   (exit $ac_status); }; }; then
38438
38439 cat >>confdefs.h <<\_ACEOF
38440 #define HAVE_STRUCT_STAT_ST_FSTYPE_CHAR 1
38441 _ACEOF
38442
38443 else
38444   echo "$as_me: failed program was:" >&5
38445 sed 's/^/| /' conftest.$ac_ext >&5
38446
38447
38448 cat >>confdefs.h <<\_ACEOF
38449 #define HAVE_STRUCT_STAT_ST_FSTYPE_INT 1
38450 _ACEOF
38451
38452 fi
38453 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
38454                 fi
38455         fi
38456         LIBSRCS="$LIBSRCS getpeereid.c"
38457 fi
38458
38459 if test "$ac_cv_func_snprintf" != yes ||
38460    test "$ac_cv_func_vsnprintf" != yes; then
38461         if test "$ac_cv_func_snprintf" != yes; then
38462
38463 cat >>confdefs.h <<\_ACEOF
38464 #define snprintf ber_pvt_snprintf
38465 _ACEOF
38466
38467         fi
38468         if test "$ac_cv_func_vsnprintf" != yes; then
38469
38470 cat >>confdefs.h <<\_ACEOF
38471 #define vsnprintf ber_pvt_vsnprintf
38472 _ACEOF
38473
38474         fi
38475 fi
38476
38477
38478 if test "$ol_enable_slapi" != no ; then
38479
38480 for ac_header in ltdl.h
38481 do
38482 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
38483 if eval "test \"\${$as_ac_Header+set}\" = set"; then
38484   echo "$as_me:$LINENO: checking for $ac_header" >&5
38485 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
38486 if eval "test \"\${$as_ac_Header+set}\" = set"; then
38487   echo $ECHO_N "(cached) $ECHO_C" >&6
38488 fi
38489 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
38490 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
38491 else
38492   # Is the header compilable?
38493 echo "$as_me:$LINENO: checking $ac_header usability" >&5
38494 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
38495 cat >conftest.$ac_ext <<_ACEOF
38496 /* confdefs.h.  */
38497 _ACEOF
38498 cat confdefs.h >>conftest.$ac_ext
38499 cat >>conftest.$ac_ext <<_ACEOF
38500 /* end confdefs.h.  */
38501 $ac_includes_default
38502 #include <$ac_header>
38503 _ACEOF
38504 rm -f conftest.$ac_objext
38505 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
38506   (eval $ac_compile) 2>conftest.er1
38507   ac_status=$?
38508   grep -v '^ *+' conftest.er1 >conftest.err
38509   rm -f conftest.er1
38510   cat conftest.err >&5
38511   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38512   (exit $ac_status); } &&
38513          { ac_try='test -z "$ac_c_werror_flag"
38514                          || test ! -s conftest.err'
38515   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38516   (eval $ac_try) 2>&5
38517   ac_status=$?
38518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38519   (exit $ac_status); }; } &&
38520          { ac_try='test -s conftest.$ac_objext'
38521   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38522   (eval $ac_try) 2>&5
38523   ac_status=$?
38524   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38525   (exit $ac_status); }; }; then
38526   ac_header_compiler=yes
38527 else
38528   echo "$as_me: failed program was:" >&5
38529 sed 's/^/| /' conftest.$ac_ext >&5
38530
38531 ac_header_compiler=no
38532 fi
38533 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
38534 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
38535 echo "${ECHO_T}$ac_header_compiler" >&6
38536
38537 # Is the header present?
38538 echo "$as_me:$LINENO: checking $ac_header presence" >&5
38539 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
38540 cat >conftest.$ac_ext <<_ACEOF
38541 /* confdefs.h.  */
38542 _ACEOF
38543 cat confdefs.h >>conftest.$ac_ext
38544 cat >>conftest.$ac_ext <<_ACEOF
38545 /* end confdefs.h.  */
38546 #include <$ac_header>
38547 _ACEOF
38548 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
38549   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
38550   ac_status=$?
38551   grep -v '^ *+' conftest.er1 >conftest.err
38552   rm -f conftest.er1
38553   cat conftest.err >&5
38554   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38555   (exit $ac_status); } >/dev/null; then
38556   if test -s conftest.err; then
38557     ac_cpp_err=$ac_c_preproc_warn_flag
38558     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
38559   else
38560     ac_cpp_err=
38561   fi
38562 else
38563   ac_cpp_err=yes
38564 fi
38565 if test -z "$ac_cpp_err"; then
38566   ac_header_preproc=yes
38567 else
38568   echo "$as_me: failed program was:" >&5
38569 sed 's/^/| /' conftest.$ac_ext >&5
38570
38571   ac_header_preproc=no
38572 fi
38573 rm -f conftest.err conftest.$ac_ext
38574 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
38575 echo "${ECHO_T}$ac_header_preproc" >&6
38576
38577 # So?  What about this header?
38578 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
38579   yes:no: )
38580     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
38581 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
38582     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
38583 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
38584     ac_header_preproc=yes
38585     ;;
38586   no:yes:* )
38587     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
38588 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
38589     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
38590 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
38591     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
38592 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
38593     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
38594 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
38595     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
38596 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
38597     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
38598 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
38599     (
38600       cat <<\_ASBOX
38601 ## --------------------------------------------- ##
38602 ## Report this to <http://www.openldap.org/its/> ##
38603 ## --------------------------------------------- ##
38604 _ASBOX
38605     ) |
38606       sed "s/^/$as_me: WARNING:     /" >&2
38607     ;;
38608 esac
38609 echo "$as_me:$LINENO: checking for $ac_header" >&5
38610 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
38611 if eval "test \"\${$as_ac_Header+set}\" = set"; then
38612   echo $ECHO_N "(cached) $ECHO_C" >&6
38613 else
38614   eval "$as_ac_Header=\$ac_header_preproc"
38615 fi
38616 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
38617 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
38618
38619 fi
38620 if test `eval echo '${'$as_ac_Header'}'` = yes; then
38621   cat >>confdefs.h <<_ACEOF
38622 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
38623 _ACEOF
38624
38625 fi
38626
38627 done
38628
38629
38630         if test $ac_cv_header_ltdl_h != yes ; then
38631                 { { echo "$as_me:$LINENO: error: could not locate <ltdl.h>" >&5
38632 echo "$as_me: error: could not locate <ltdl.h>" >&2;}
38633    { (exit 1); exit 1; }; }
38634         fi
38635         echo "$as_me:$LINENO: checking for lt_dlinit in -lltdl" >&5
38636 echo $ECHO_N "checking for lt_dlinit in -lltdl... $ECHO_C" >&6
38637 if test "${ac_cv_lib_ltdl_lt_dlinit+set}" = set; then
38638   echo $ECHO_N "(cached) $ECHO_C" >&6
38639 else
38640   ac_check_lib_save_LIBS=$LIBS
38641 LIBS="-lltdl  $LIBS"
38642 cat >conftest.$ac_ext <<_ACEOF
38643 /* confdefs.h.  */
38644 _ACEOF
38645 cat confdefs.h >>conftest.$ac_ext
38646 cat >>conftest.$ac_ext <<_ACEOF
38647 /* end confdefs.h.  */
38648
38649 /* Override any gcc2 internal prototype to avoid an error.  */
38650 #ifdef __cplusplus
38651 extern "C"
38652 #endif
38653 /* We use char because int might match the return type of a gcc2
38654    builtin and then its argument prototype would still apply.  */
38655 char lt_dlinit ();
38656 int
38657 main ()
38658 {
38659 lt_dlinit ();
38660   ;
38661   return 0;
38662 }
38663 _ACEOF
38664 rm -f conftest.$ac_objext conftest$ac_exeext
38665 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
38666   (eval $ac_link) 2>conftest.er1
38667   ac_status=$?
38668   grep -v '^ *+' conftest.er1 >conftest.err
38669   rm -f conftest.er1
38670   cat conftest.err >&5
38671   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38672   (exit $ac_status); } &&
38673          { ac_try='test -z "$ac_c_werror_flag"
38674                          || test ! -s conftest.err'
38675   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38676   (eval $ac_try) 2>&5
38677   ac_status=$?
38678   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38679   (exit $ac_status); }; } &&
38680          { ac_try='test -s conftest$ac_exeext'
38681   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
38682   (eval $ac_try) 2>&5
38683   ac_status=$?
38684   echo "$as_me:$LINENO: \$? = $ac_status" >&5
38685   (exit $ac_status); }; }; then
38686   ac_cv_lib_ltdl_lt_dlinit=yes
38687 else
38688   echo "$as_me: failed program was:" >&5
38689 sed 's/^/| /' conftest.$ac_ext >&5
38690
38691 ac_cv_lib_ltdl_lt_dlinit=no
38692 fi
38693 rm -f conftest.err conftest.$ac_objext \
38694       conftest$ac_exeext conftest.$ac_ext
38695 LIBS=$ac_check_lib_save_LIBS
38696 fi
38697 echo "$as_me:$LINENO: result: $ac_cv_lib_ltdl_lt_dlinit" >&5
38698 echo "${ECHO_T}$ac_cv_lib_ltdl_lt_dlinit" >&6
38699 if test $ac_cv_lib_ltdl_lt_dlinit = yes; then
38700
38701                 SLAPI_LIBS=-lltdl
38702                 LIBSLAPI=libslapi.a
38703                 LIBSLAPITOOLS=../libslapi.a
38704
38705 cat >>confdefs.h <<\_ACEOF
38706 #define HAVE_LIBLTDL 1
38707 _ACEOF
38708
38709
38710 else
38711   { { echo "$as_me:$LINENO: error: could not locate libtool -lltdl" >&5
38712 echo "$as_me: error: could not locate libtool -lltdl" >&2;}
38713    { (exit 1); exit 1; }; }
38714 fi
38715
38716
38717
38718 cat >>confdefs.h <<\_ACEOF
38719 #define LDAP_SLAPI 1
38720 _ACEOF
38721
38722 fi
38723
38724 if test "$ol_enable_debug" != no ; then
38725         if test "$ol_enable_debug" = traditional; then
38726
38727 cat >>confdefs.h <<\_ACEOF
38728 #define OLD_DEBUG 1
38729 _ACEOF
38730
38731         fi
38732
38733 cat >>confdefs.h <<\_ACEOF
38734 #define LDAP_DEBUG 1
38735 _ACEOF
38736
38737 fi
38738 if test "$ol_enable_syslog" = yes ; then
38739
38740 cat >>confdefs.h <<\_ACEOF
38741 #define LDAP_SYSLOG 1
38742 _ACEOF
38743
38744 fi
38745 if test "$ol_enable_proctitle" != no ; then
38746
38747 cat >>confdefs.h <<\_ACEOF
38748 #define LDAP_PROCTITLE 1
38749 _ACEOF
38750
38751 fi
38752 if test "$ol_enable_referrals" != no ; then
38753
38754 cat >>confdefs.h <<\_ACEOF
38755 #define LDAP_API_FEATURE_X_OPENLDAP_V2_REFERRALS LDAP_VENDOR_VERSION
38756 _ACEOF
38757
38758 fi
38759 if test "$ol_enable_local" != no; then
38760
38761 cat >>confdefs.h <<\_ACEOF
38762 #define LDAP_PF_LOCAL 1
38763 _ACEOF
38764
38765 fi
38766 if test "$ol_link_ipv6" != no; then
38767
38768 cat >>confdefs.h <<\_ACEOF
38769 #define LDAP_PF_INET6 1
38770 _ACEOF
38771
38772 fi
38773 if test "$ol_enable_cleartext" != no ; then
38774
38775 cat >>confdefs.h <<\_ACEOF
38776 #define SLAPD_CLEARTEXT 1
38777 _ACEOF
38778
38779 fi
38780 if test "$ol_enable_crypt" != no ; then
38781
38782 cat >>confdefs.h <<\_ACEOF
38783 #define SLAPD_CRYPT 1
38784 _ACEOF
38785
38786 fi
38787 if test "$ol_link_spasswd" != no ; then
38788
38789 cat >>confdefs.h <<\_ACEOF
38790 #define SLAPD_SPASSWD 1
38791 _ACEOF
38792
38793 fi
38794 if test "$ol_enable_rlookups" != no ; then
38795
38796 cat >>confdefs.h <<\_ACEOF
38797 #define SLAPD_RLOOKUPS 1
38798 _ACEOF
38799
38800 fi
38801 if test "$ol_enable_aci" != no ; then
38802         if test $ol_enable_dynacl = no ; then
38803                 ol_enable_dynacl=yes
38804                 { echo "$as_me:$LINENO: WARNING: ACIs need dynacl" >&5
38805 echo "$as_me: WARNING: ACIs need dynacl" >&2;}
38806         fi
38807         if test "$ol_enable_aci" = mod ; then
38808                 MFLAG=SLAPD_MOD_DYNAMIC
38809                                 { { echo "$as_me:$LINENO: error: ACI build as dynamic module not supported (yet)" >&5
38810 echo "$as_me: error: ACI build as dynamic module not supported (yet)" >&2;}
38811    { (exit 1); exit 1; }; }
38812         else
38813                 MFLAG=SLAPD_MOD_STATIC
38814         fi
38815         WITH_ACI_ENABLED=$ol_enable_aci
38816
38817 cat >>confdefs.h <<_ACEOF
38818 #define SLAPD_ACI_ENABLED $MFLAG
38819 _ACEOF
38820
38821 else
38822         WITH_ACI_ENABLED=no
38823 fi
38824 if test "$ol_enable_dynacl" != no ; then
38825
38826 cat >>confdefs.h <<\_ACEOF
38827 #define SLAP_DYNACL 1
38828 _ACEOF
38829
38830 fi
38831
38832 if test "$ol_link_modules" != no ; then
38833
38834 cat >>confdefs.h <<\_ACEOF
38835 #define SLAPD_MODULES 1
38836 _ACEOF
38837
38838         BUILD_SLAPD=yes
38839         SLAPD_MODULES_LDFLAGS="-dlopen self"
38840 fi
38841
38842
38843 cat >>confdefs.h <<\_ACEOF
38844 #define SLAPD_MOD_STATIC 1
38845 _ACEOF
38846
38847
38848 cat >>confdefs.h <<\_ACEOF
38849 #define SLAPD_MOD_DYNAMIC 2
38850 _ACEOF
38851
38852
38853 if test "$ol_enable_monitor" != no ; then
38854         BUILD_SLAPD=yes
38855         BUILD_MONITOR=$ol_enable_monitor
38856         if test "$ol_enable_monitor" = mod ; then
38857                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-monitor"
38858                 MFLAG=SLAPD_MOD_DYNAMIC
38859         else
38860                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-monitor"
38861                 MFLAG=SLAPD_MOD_STATIC
38862         fi
38863
38864 cat >>confdefs.h <<_ACEOF
38865 #define SLAPD_MONITOR $MFLAG
38866 _ACEOF
38867
38868 fi
38869
38870 if test "$ol_enable_bdb" != no ; then
38871         BUILD_SLAPD=yes
38872         BUILD_BDB=$ol_enable_bdb
38873         if test "$ol_enable_bdb" = mod ; then
38874                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-bdb"
38875                 MFLAG=SLAPD_MOD_DYNAMIC
38876         else
38877                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-bdb"
38878                 MFLAG=SLAPD_MOD_STATIC
38879         fi
38880
38881 cat >>confdefs.h <<_ACEOF
38882 #define SLAPD_BDB $MFLAG
38883 _ACEOF
38884
38885 fi
38886
38887 if test "$ol_enable_dnssrv" != no ; then
38888         BUILD_SLAPD=yes
38889         BUILD_DNSSRV=$ol_enable_dnssrv
38890         if test "$ol_enable_dnssrv" = mod ; then
38891                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-dnssrv"
38892                 MFLAG=SLAPD_MOD_DYNAMIC
38893         else
38894                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-dnssrv"
38895                 MFLAG=SLAPD_MOD_STATIC
38896         fi
38897
38898 cat >>confdefs.h <<_ACEOF
38899 #define SLAPD_DNSSRV $MFLAG
38900 _ACEOF
38901
38902 fi
38903
38904 if test "$ol_enable_hdb" != no ; then
38905         BUILD_SLAPD=yes
38906         BUILD_HDB=$ol_enable_hdb
38907         if test "$ol_enable_hdb" = mod ; then
38908                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-hdb"
38909                 MFLAG=SLAPD_MOD_DYNAMIC
38910         else
38911                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-hdb"
38912                 MFLAG=SLAPD_MOD_STATIC
38913         fi
38914
38915 cat >>confdefs.h <<_ACEOF
38916 #define SLAPD_HDB $MFLAG
38917 _ACEOF
38918
38919 fi
38920
38921 if test "$ol_enable_ldap" != no ; then
38922         BUILD_SLAPD=yes
38923         BUILD_LDAP=$ol_enable_ldap
38924         if test "$ol_enable_ldap" = mod ; then
38925                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-ldap"
38926                 MFLAG=SLAPD_MOD_DYNAMIC
38927         else
38928                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-ldap"
38929                 MFLAG=SLAPD_MOD_STATIC
38930         fi
38931
38932 cat >>confdefs.h <<_ACEOF
38933 #define SLAPD_LDAP $MFLAG
38934 _ACEOF
38935
38936 fi
38937
38938 if test "$ol_enable_meta" != no ; then
38939         BUILD_SLAPD=yes
38940         BUILD_META=$ol_enable_meta
38941         BUILD_REWRITE=yes
38942         if test "$ol_enable_meta" = mod ; then
38943                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-meta"
38944                 MFLAG=SLAPD_MOD_DYNAMIC
38945         else
38946                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-meta"
38947                 MFLAG=SLAPD_MOD_STATIC
38948         fi
38949
38950 cat >>confdefs.h <<_ACEOF
38951 #define SLAPD_META $MFLAG
38952 _ACEOF
38953
38954 fi
38955
38956 if test "$ol_enable_ndb" != no ; then
38957         BUILD_SLAPD=yes
38958         BUILD_NDB=$ol_enable_ndb
38959         if test "$ol_enable_ndb" = mod ; then
38960                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-ndb"
38961                 MFLAG=SLAPD_MOD_DYNAMIC
38962         else
38963                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-ndb"
38964                 MFLAG=SLAPD_MOD_STATIC
38965         fi
38966
38967 cat >>confdefs.h <<_ACEOF
38968 #define SLAPD_NDB $MFLAG
38969 _ACEOF
38970
38971 fi
38972
38973 if test "$ol_enable_null" != no ; then
38974         BUILD_SLAPD=yes
38975         BUILD_NULL=$ol_enable_null
38976         if test "$ol_enable_null" = mod ; then
38977                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-null"
38978                 MFLAG=SLAPD_MOD_DYNAMIC
38979         else
38980                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-null"
38981                 MFLAG=SLAPD_MOD_STATIC
38982         fi
38983
38984 cat >>confdefs.h <<_ACEOF
38985 #define SLAPD_NULL $MFLAG
38986 _ACEOF
38987
38988 fi
38989
38990 if test "$ol_enable_passwd" != no ; then
38991         BUILD_SLAPD=yes
38992         BUILD_PASSWD=$ol_enable_passwd
38993         if test "$ol_enable_passwd" = mod ; then
38994                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-passwd"
38995                 MFLAG=SLAPD_MOD_DYNAMIC
38996         else
38997                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-passwd"
38998                 MFLAG=SLAPD_MOD_STATIC
38999         fi
39000
39001 cat >>confdefs.h <<_ACEOF
39002 #define SLAPD_PASSWD $MFLAG
39003 _ACEOF
39004
39005 fi
39006
39007 if test "$ol_link_perl" != no ; then
39008         BUILD_SLAPD=yes
39009         BUILD_PERL=$ol_enable_perl
39010         if test "$ol_enable_perl" = mod ; then
39011                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-perl"
39012                 MFLAG=SLAPD_MOD_DYNAMIC
39013         else
39014                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-perl"
39015                 MFLAG=SLAPD_MOD_STATIC
39016         fi
39017
39018 cat >>confdefs.h <<_ACEOF
39019 #define SLAPD_PERL $MFLAG
39020 _ACEOF
39021
39022 fi
39023
39024 if test "$ol_enable_relay" != no ; then
39025         BUILD_SLAPD=yes
39026         BUILD_RELAY=$ol_enable_relay
39027         if test "$ol_enable_relay" = mod ; then
39028                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-relay"
39029                 MFLAG=SLAPD_MOD_DYNAMIC
39030         else
39031                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-relay"
39032                 MFLAG=SLAPD_MOD_STATIC
39033         fi
39034
39035 cat >>confdefs.h <<_ACEOF
39036 #define SLAPD_RELAY $MFLAG
39037 _ACEOF
39038
39039 fi
39040
39041 if test "$ol_enable_shell" != no ; then
39042         if test "$ol_link_threads" != no ; then
39043                 { echo "$as_me:$LINENO: WARNING: Use of --without-threads is recommended with back-shell" >&5
39044 echo "$as_me: WARNING: Use of --without-threads is recommended with back-shell" >&2;}
39045         fi
39046         BUILD_SLAPD=yes
39047         BUILD_SHELL=$ol_enable_shell
39048         if test "$ol_enable_shell" = mod ; then
39049                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-shell"
39050                 MFLAG=SLAPD_MOD_DYNAMIC
39051         else
39052                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-shell"
39053                 MFLAG=SLAPD_MOD_STATIC
39054         fi
39055
39056 cat >>confdefs.h <<_ACEOF
39057 #define SLAPD_SHELL $MFLAG
39058 _ACEOF
39059
39060 fi
39061
39062 if test "$ol_enable_sock" != no ; then
39063         BUILD_SLAPD=yes
39064         BUILD_SOCK=$ol_enable_sock
39065         if test "$ol_enable_sock" = mod ; then
39066                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-sock"
39067                 MFLAG=SLAPD_MOD_DYNAMIC
39068         else
39069                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-sock"
39070                 MFLAG=SLAPD_MOD_STATIC
39071         fi
39072
39073 cat >>confdefs.h <<_ACEOF
39074 #define SLAPD_SOCK $MFLAG
39075 _ACEOF
39076
39077 fi
39078
39079 if test "$ol_link_sql" != no ; then
39080         BUILD_SLAPD=yes
39081         BUILD_SQL=$ol_enable_sql
39082         if test "$ol_enable_sql" = mod; then
39083                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-sql"
39084                 MFLAG=SLAPD_MOD_DYNAMIC
39085         else
39086                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-sql"
39087                 MFLAG=SLAPD_MOD_STATIC
39088         fi
39089
39090 cat >>confdefs.h <<_ACEOF
39091 #define SLAPD_SQL $MFLAG
39092 _ACEOF
39093
39094 fi
39095
39096 if test "$ol_enable_accesslog" != no ; then
39097         BUILD_ACCESSLOG=$ol_enable_accesslog
39098         if test "$ol_enable_accesslog" = mod ; then
39099                 MFLAG=SLAPD_MOD_DYNAMIC
39100                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS accesslog.la"
39101         else
39102                 MFLAG=SLAPD_MOD_STATIC
39103                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS accesslog.o"
39104         fi
39105
39106 cat >>confdefs.h <<_ACEOF
39107 #define SLAPD_OVER_ACCESSLOG $MFLAG
39108 _ACEOF
39109
39110 fi
39111
39112 if test "$ol_enable_auditlog" != no ; then
39113         BUILD_AUDITLOG=$ol_enable_auditlog
39114         if test "$ol_enable_auditlog" = mod ; then
39115                 MFLAG=SLAPD_MOD_DYNAMIC
39116                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS auditlog.la"
39117         else
39118                 MFLAG=SLAPD_MOD_STATIC
39119                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS auditlog.o"
39120         fi
39121
39122 cat >>confdefs.h <<_ACEOF
39123 #define SLAPD_OVER_AUDITLOG $MFLAG
39124 _ACEOF
39125
39126 fi
39127
39128 if test "$ol_enable_constraint" != no ; then
39129         BUILD_CONSTRAINT=$ol_enable_constraint
39130         if test "$ol_enable_constraint" = mod ; then
39131                 MFLAG=SLAPD_MOD_DYNAMIC
39132                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS constraint.la"
39133         else
39134                 MFLAG=SLAPD_MOD_STATIC
39135                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS constraint.o"
39136         fi
39137
39138 cat >>confdefs.h <<_ACEOF
39139 #define SLAPD_OVER_CONSTRAINT $MFLAG
39140 _ACEOF
39141
39142 fi
39143
39144 if test "$ol_enable_dds" != no ; then
39145         BUILD_DDS=$ol_enable_dds
39146         if test "$ol_enable_dds" = mod ; then
39147                 MFLAG=SLAPD_MOD_DYNAMIC
39148                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS dds.la"
39149         else
39150                 MFLAG=SLAPD_MOD_STATIC
39151                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS dds.o"
39152         fi
39153
39154 cat >>confdefs.h <<_ACEOF
39155 #define SLAPD_OVER_DDS $MFLAG
39156 _ACEOF
39157
39158 fi
39159
39160 if test "$ol_enable_dyngroup" != no ; then
39161         BUILD_DYNGROUP=$ol_enable_dyngroup
39162         if test "$ol_enable_dyngroup" = mod ; then
39163                 MFLAG=SLAPD_MOD_DYNAMIC
39164                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS dyngroup.la"
39165         else
39166                 MFLAG=SLAPD_MOD_STATIC
39167                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS dyngroup.o"
39168         fi
39169
39170 cat >>confdefs.h <<_ACEOF
39171 #define SLAPD_OVER_DYNGROUP $MFLAG
39172 _ACEOF
39173
39174 fi
39175
39176 if test "$ol_enable_dynlist" != no ; then
39177         BUILD_DYNLIST=$ol_enable_dynlist
39178         if test "$ol_enable_dynlist" = mod ; then
39179                 MFLAG=SLAPD_MOD_DYNAMIC
39180                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS dynlist.la"
39181         else
39182                 MFLAG=SLAPD_MOD_STATIC
39183                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS dynlist.o"
39184         fi
39185
39186 cat >>confdefs.h <<_ACEOF
39187 #define SLAPD_OVER_DYNLIST $MFLAG
39188 _ACEOF
39189
39190 fi
39191
39192 if test "$ol_enable_memberof" != no ; then
39193         BUILD_MEMBEROF=$ol_enable_memberof
39194         if test "$ol_enable_memberof" = mod ; then
39195                 MFLAG=SLAPD_MOD_DYNAMIC
39196                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS memberof.la"
39197         else
39198                 MFLAG=SLAPD_MOD_STATIC
39199                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS memberof.o"
39200         fi
39201
39202 cat >>confdefs.h <<_ACEOF
39203 #define SLAPD_OVER_MEMBEROF $MFLAG
39204 _ACEOF
39205
39206 fi
39207
39208 if test "$ol_enable_ppolicy" != no ; then
39209         BUILD_PPOLICY=$ol_enable_ppolicy
39210         if test "$ol_enable_ppolicy" = mod ; then
39211                 MFLAG=SLAPD_MOD_DYNAMIC
39212                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS ppolicy.la"
39213         else
39214                 MFLAG=SLAPD_MOD_STATIC
39215                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS ppolicy.o"
39216         fi
39217
39218 cat >>confdefs.h <<_ACEOF
39219 #define SLAPD_OVER_PPOLICY $MFLAG
39220 _ACEOF
39221
39222 fi
39223
39224 if test "$ol_enable_proxycache" != no ; then
39225         BUILD_PROXYCACHE=$ol_enable_proxycache
39226         if test "$ol_enable_proxycache" = mod ; then
39227                 MFLAG=SLAPD_MOD_DYNAMIC
39228                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS pcache.la"
39229         else
39230                 MFLAG=SLAPD_MOD_STATIC
39231                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS pcache.o"
39232         fi
39233
39234 cat >>confdefs.h <<_ACEOF
39235 #define SLAPD_OVER_PROXYCACHE $MFLAG
39236 _ACEOF
39237
39238 fi
39239
39240 if test "$ol_enable_refint" != no ; then
39241         BUILD_REFINT=$ol_enable_refint
39242         if test "$ol_enable_refint" = mod ; then
39243                 MFLAG=SLAPD_MOD_DYNAMIC
39244                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS refint.la"
39245         else
39246                 MFLAG=SLAPD_MOD_STATIC
39247                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS refint.o"
39248         fi
39249
39250 cat >>confdefs.h <<_ACEOF
39251 #define SLAPD_OVER_REFINT $MFLAG
39252 _ACEOF
39253
39254 fi
39255
39256 if test "$ol_enable_retcode" != no ; then
39257         BUILD_RETCODE=$ol_enable_retcode
39258         if test "$ol_enable_retcode" = mod ; then
39259                 MFLAG=SLAPD_MOD_DYNAMIC
39260                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS retcode.la"
39261         else
39262                 MFLAG=SLAPD_MOD_STATIC
39263                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS retcode.o"
39264         fi
39265
39266 cat >>confdefs.h <<_ACEOF
39267 #define SLAPD_OVER_RETCODE $MFLAG
39268 _ACEOF
39269
39270 fi
39271
39272 if test "$ol_enable_rwm" != no ; then
39273         BUILD_REWRITE=yes
39274         BUILD_RWM=$ol_enable_rwm
39275         if test "$ol_enable_rwm" = mod ; then
39276                 MFLAG=SLAPD_MOD_DYNAMIC
39277                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS rwm.la"
39278         else
39279                 MFLAG=SLAPD_MOD_STATIC
39280                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS rwm_x.o"
39281         fi
39282
39283 cat >>confdefs.h <<_ACEOF
39284 #define SLAPD_OVER_RWM $MFLAG
39285 _ACEOF
39286
39287 fi
39288
39289 if test "$ol_enable_seqmod" != no ; then
39290         BUILD_SEQMOD=$ol_enable_seqmod
39291         if test "$ol_enable_seqmod" = mod ; then
39292                 MFLAG=SLAPD_MOD_DYNAMIC
39293                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS seqmod.la"
39294         else
39295                 MFLAG=SLAPD_MOD_STATIC
39296                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS seqmod.o"
39297         fi
39298
39299 cat >>confdefs.h <<_ACEOF
39300 #define SLAPD_OVER_SEQMOD $MFLAG
39301 _ACEOF
39302
39303 fi
39304
39305 if test "$ol_enable_syncprov" != no ; then
39306         BUILD_SYNCPROV=$ol_enable_syncprov
39307         if test "$ol_enable_syncprov" = mod ; then
39308                 MFLAG=SLAPD_MOD_DYNAMIC
39309                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS syncprov.la"
39310         else
39311                 MFLAG=SLAPD_MOD_STATIC
39312                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS syncprov.o"
39313         fi
39314
39315 cat >>confdefs.h <<_ACEOF
39316 #define SLAPD_OVER_SYNCPROV $MFLAG
39317 _ACEOF
39318
39319 fi
39320
39321 if test "$ol_enable_translucent" != no ; then
39322         BUILD_TRANSLUCENT=$ol_enable_translucent
39323         if test "$ol_enable_translucent" = mod ; then
39324                 MFLAG=SLAPD_MOD_DYNAMIC
39325                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS translucent.la"
39326         else
39327                 MFLAG=SLAPD_MOD_STATIC
39328                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS translucent.o"
39329         fi
39330
39331 cat >>confdefs.h <<_ACEOF
39332 #define SLAPD_OVER_TRANSLUCENT $MFLAG
39333 _ACEOF
39334
39335 fi
39336
39337 if test "$ol_enable_unique" != no ; then
39338         BUILD_UNIQUE=$ol_enable_unique
39339         if test "$ol_enable_unique" = mod ; then
39340                 MFLAG=SLAPD_MOD_DYNAMIC
39341                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS unique.la"
39342         else
39343                 MFLAG=SLAPD_MOD_STATIC
39344                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS unique.o"
39345         fi
39346
39347 cat >>confdefs.h <<_ACEOF
39348 #define SLAPD_OVER_UNIQUE $MFLAG
39349 _ACEOF
39350
39351 fi
39352
39353 if test "$ol_enable_valsort" != no ; then
39354         BUILD_VALSORT=$ol_enable_valsort
39355         if test "$ol_enable_valsort" = mod ; then
39356                 MFLAG=SLAPD_MOD_DYNAMIC
39357                 SLAPD_DYNAMIC_OVERLAYS="$SLAPD_DYNAMIC_OVERLAYS valsort.la"
39358         else
39359                 MFLAG=SLAPD_MOD_STATIC
39360                 SLAPD_STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS valsort.o"
39361         fi
39362
39363 cat >>confdefs.h <<_ACEOF
39364 #define SLAPD_OVER_VALSORT $MFLAG
39365 _ACEOF
39366
39367 fi
39368
39369 if test "$ol_enable_rewrite" != no ; then
39370
39371 cat >>confdefs.h <<\_ACEOF
39372 #define ENABLE_REWRITE 1
39373 _ACEOF
39374
39375         BUILD_REWRITE=yes
39376 fi
39377
39378 if test "$ol_enable_slapi" != no ; then
39379
39380 cat >>confdefs.h <<\_ACEOF
39381 #define ENABLE_SLAPI 1
39382 _ACEOF
39383
39384         BUILD_SLAPI=yes
39385         SLAPD_SLAPI_DEPEND=libslapi.a
39386 fi
39387
39388
39389
39390 if test "$ac_cv_mingw32" = yes ; then
39391         PLAT=NT
39392         SLAPD_MODULES_LDFLAGS=
39393 else
39394         PLAT=UNIX
39395 fi
39396
39397
39398
39399
39400
39401
39402
39403
39404
39405
39406
39407
39408
39409
39410
39411
39412
39413
39414
39415
39416
39417
39418
39419
39420
39421
39422
39423
39424
39425
39426
39427
39428
39429
39430
39431
39432
39433
39434
39435
39436
39437
39438
39439
39440
39441
39442
39443
39444
39445
39446
39447
39448
39449
39450
39451
39452
39453
39454
39455
39456
39457
39458
39459
39460
39461
39462
39463
39464
39465
39466
39467
39468
39469
39470
39471
39472
39473
39474
39475
39476
39477
39478
39479
39480
39481
39482
39483
39484 # Check whether --with-xxinstall or --without-xxinstall was given.
39485 if test "${with_xxinstall+set}" = set; then
39486   withval="$with_xxinstall"
39487
39488 fi;
39489
39490
39491                                                                                                                                                                                                                                                                                                                                                                                                                 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-ndb/Makefile:build/top.mk:servers/slapd/back-ndb/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"
39492
39493
39494           ac_config_commands="$ac_config_commands default"
39495
39496
39497
39498 test "x$prefix" = xNONE && prefix=$ac_default_prefix
39499 # Let make expand exec_prefix.
39500 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
39501
39502 # VPATH may cause trouble with some makes, so we remove $(srcdir),
39503 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
39504 # trailing colons and then remove the whole line if VPATH becomes empty
39505 # (actually we leave an empty line to preserve line numbers).
39506 if test "x$srcdir" = x.; then
39507   ac_vpsub='/^[  ]*VPATH[        ]*=/{
39508 s/:*\$(srcdir):*/:/;
39509 s/:*\${srcdir}:*/:/;
39510 s/:*@srcdir@:*/:/;
39511 s/^\([^=]*=[     ]*\):*/\1/;
39512 s/:*$//;
39513 s/^[^=]*=[       ]*$//;
39514 }'
39515 fi
39516
39517 DEFS=-DHAVE_CONFIG_H
39518
39519 ac_libobjs=
39520 ac_ltlibobjs=
39521 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
39522   # 1. Remove the extension, and $U if already installed.
39523   ac_i=`echo "$ac_i" |
39524          sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
39525   # 2. Add them.
39526   ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
39527   ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
39528 done
39529 LIBOBJS=$ac_libobjs
39530
39531 LTLIBOBJS=$ac_ltlibobjs
39532
39533
39534 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
39535   { { echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined.
39536 Usually this means the macro was only invoked conditionally." >&5
39537 echo "$as_me: error: conditional \"AMDEP\" was never defined.
39538 Usually this means the macro was only invoked conditionally." >&2;}
39539    { (exit 1); exit 1; }; }
39540 fi
39541 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
39542   { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
39543 Usually this means the macro was only invoked conditionally." >&5
39544 echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
39545 Usually this means the macro was only invoked conditionally." >&2;}
39546    { (exit 1); exit 1; }; }
39547 fi
39548 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
39549   { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
39550 Usually this means the macro was only invoked conditionally." >&5
39551 echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
39552 Usually this means the macro was only invoked conditionally." >&2;}
39553    { (exit 1); exit 1; }; }
39554 fi
39555
39556 : ${CONFIG_STATUS=./config.status}
39557 ac_clean_files_save=$ac_clean_files
39558 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
39559 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
39560 echo "$as_me: creating $CONFIG_STATUS" >&6;}
39561 cat >$CONFIG_STATUS <<_ACEOF
39562 #! $SHELL
39563 # Generated by $as_me.
39564 # Run this file to recreate the current configuration.
39565 # Compiler output produced by configure, useful for debugging
39566 # configure, is in config.log if it exists.
39567
39568 debug=false
39569 ac_cs_recheck=false
39570 ac_cs_silent=false
39571 SHELL=\${CONFIG_SHELL-$SHELL}
39572 _ACEOF
39573
39574 cat >>$CONFIG_STATUS <<\_ACEOF
39575 ## --------------------- ##
39576 ## M4sh Initialization.  ##
39577 ## --------------------- ##
39578
39579 # Be Bourne compatible
39580 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
39581   emulate sh
39582   NULLCMD=:
39583   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
39584   # is contrary to our usage.  Disable this feature.
39585   alias -g '${1+"$@"}'='"$@"'
39586 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
39587   set -o posix
39588 fi
39589 DUALCASE=1; export DUALCASE # for MKS sh
39590
39591 # Support unset when possible.
39592 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
39593   as_unset=unset
39594 else
39595   as_unset=false
39596 fi
39597
39598
39599 # Work around bugs in pre-3.0 UWIN ksh.
39600 $as_unset ENV MAIL MAILPATH
39601 PS1='$ '
39602 PS2='> '
39603 PS4='+ '
39604
39605 # NLS nuisances.
39606 for as_var in \
39607   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
39608   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
39609   LC_TELEPHONE LC_TIME
39610 do
39611   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
39612     eval $as_var=C; export $as_var
39613   else
39614     $as_unset $as_var
39615   fi
39616 done
39617
39618 # Required to use basename.
39619 if expr a : '\(a\)' >/dev/null 2>&1; then
39620   as_expr=expr
39621 else
39622   as_expr=false
39623 fi
39624
39625 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
39626   as_basename=basename
39627 else
39628   as_basename=false
39629 fi
39630
39631
39632 # Name of the executable.
39633 as_me=`$as_basename "$0" ||
39634 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
39635          X"$0" : 'X\(//\)$' \| \
39636          X"$0" : 'X\(/\)$' \| \
39637          .     : '\(.\)' 2>/dev/null ||
39638 echo X/"$0" |
39639     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
39640           /^X\/\(\/\/\)$/{ s//\1/; q; }
39641           /^X\/\(\/\).*/{ s//\1/; q; }
39642           s/.*/./; q'`
39643
39644
39645 # PATH needs CR, and LINENO needs CR and PATH.
39646 # Avoid depending upon Character Ranges.
39647 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
39648 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
39649 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
39650 as_cr_digits='0123456789'
39651 as_cr_alnum=$as_cr_Letters$as_cr_digits
39652
39653 # The user is always right.
39654 if test "${PATH_SEPARATOR+set}" != set; then
39655   echo "#! /bin/sh" >conf$$.sh
39656   echo  "exit 0"   >>conf$$.sh
39657   chmod +x conf$$.sh
39658   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
39659     PATH_SEPARATOR=';'
39660   else
39661     PATH_SEPARATOR=:
39662   fi
39663   rm -f conf$$.sh
39664 fi
39665
39666
39667   as_lineno_1=$LINENO
39668   as_lineno_2=$LINENO
39669   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
39670   test "x$as_lineno_1" != "x$as_lineno_2" &&
39671   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
39672   # Find who we are.  Look in the path if we contain no path at all
39673   # relative or not.
39674   case $0 in
39675     *[\\/]* ) as_myself=$0 ;;
39676     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39677 for as_dir in $PATH
39678 do
39679   IFS=$as_save_IFS
39680   test -z "$as_dir" && as_dir=.
39681   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
39682 done
39683
39684        ;;
39685   esac
39686   # We did not find ourselves, most probably we were run as `sh COMMAND'
39687   # in which case we are not to be found in the path.
39688   if test "x$as_myself" = x; then
39689     as_myself=$0
39690   fi
39691   if test ! -f "$as_myself"; then
39692     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
39693 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
39694    { (exit 1); exit 1; }; }
39695   fi
39696   case $CONFIG_SHELL in
39697   '')
39698     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39699 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
39700 do
39701   IFS=$as_save_IFS
39702   test -z "$as_dir" && as_dir=.
39703   for as_base in sh bash ksh sh5; do
39704          case $as_dir in
39705          /*)
39706            if ("$as_dir/$as_base" -c '
39707   as_lineno_1=$LINENO
39708   as_lineno_2=$LINENO
39709   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
39710   test "x$as_lineno_1" != "x$as_lineno_2" &&
39711   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
39712              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
39713              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
39714              CONFIG_SHELL=$as_dir/$as_base
39715              export CONFIG_SHELL
39716              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
39717            fi;;
39718          esac
39719        done
39720 done
39721 ;;
39722   esac
39723
39724   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
39725   # uniformly replaced by the line number.  The first 'sed' inserts a
39726   # line-number line before each line; the second 'sed' does the real
39727   # work.  The second script uses 'N' to pair each line-number line
39728   # with the numbered line, and appends trailing '-' during
39729   # substitution so that $LINENO is not a special case at line end.
39730   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
39731   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
39732   sed '=' <$as_myself |
39733     sed '
39734       N
39735       s,$,-,
39736       : loop
39737       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
39738       t loop
39739       s,-$,,
39740       s,^['$as_cr_digits']*\n,,
39741     ' >$as_me.lineno &&
39742   chmod +x $as_me.lineno ||
39743     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
39744 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
39745    { (exit 1); exit 1; }; }
39746
39747   # Don't try to exec as it changes $[0], causing all sort of problems
39748   # (the dirname of $[0] is not the place where we might find the
39749   # original and so on.  Autoconf is especially sensible to this).
39750   . ./$as_me.lineno
39751   # Exit status is that of the last command.
39752   exit
39753 }
39754
39755
39756 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
39757   *c*,-n*) ECHO_N= ECHO_C='
39758 ' ECHO_T='      ' ;;
39759   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
39760   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
39761 esac
39762
39763 if expr a : '\(a\)' >/dev/null 2>&1; then
39764   as_expr=expr
39765 else
39766   as_expr=false
39767 fi
39768
39769 rm -f conf$$ conf$$.exe conf$$.file
39770 echo >conf$$.file
39771 if ln -s conf$$.file conf$$ 2>/dev/null; then
39772   # We could just check for DJGPP; but this test a) works b) is more generic
39773   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
39774   if test -f conf$$.exe; then
39775     # Don't use ln at all; we don't have any links
39776     as_ln_s='cp -p'
39777   else
39778     as_ln_s='ln -s'
39779   fi
39780 elif ln conf$$.file conf$$ 2>/dev/null; then
39781   as_ln_s=ln
39782 else
39783   as_ln_s='cp -p'
39784 fi
39785 rm -f conf$$ conf$$.exe conf$$.file
39786
39787 if mkdir -p . 2>/dev/null; then
39788   as_mkdir_p=:
39789 else
39790   test -d ./-p && rmdir ./-p
39791   as_mkdir_p=false
39792 fi
39793
39794 as_executable_p="test -f"
39795
39796 # Sed expression to map a string onto a valid CPP name.
39797 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
39798
39799 # Sed expression to map a string onto a valid variable name.
39800 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
39801
39802
39803 # IFS
39804 # We need space, tab and new line, in precisely that order.
39805 as_nl='
39806 '
39807 IFS="   $as_nl"
39808
39809 # CDPATH.
39810 $as_unset CDPATH
39811
39812 exec 6>&1
39813
39814 # Open the log real soon, to keep \$[0] and so on meaningful, and to
39815 # report actual input values of CONFIG_FILES etc. instead of their
39816 # values after options handling.  Logging --version etc. is OK.
39817 exec 5>>config.log
39818 {
39819   echo
39820   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
39821 ## Running $as_me. ##
39822 _ASBOX
39823 } >&5
39824 cat >&5 <<_CSEOF
39825
39826 This file was extended by $as_me, which was
39827 generated by GNU Autoconf 2.59.  Invocation command line was
39828
39829   CONFIG_FILES    = $CONFIG_FILES
39830   CONFIG_HEADERS  = $CONFIG_HEADERS
39831   CONFIG_LINKS    = $CONFIG_LINKS
39832   CONFIG_COMMANDS = $CONFIG_COMMANDS
39833   $ $0 $@
39834
39835 _CSEOF
39836 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
39837 echo >&5
39838 _ACEOF
39839
39840 # Files that config.status was made for.
39841 if test -n "$ac_config_files"; then
39842   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
39843 fi
39844
39845 if test -n "$ac_config_headers"; then
39846   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
39847 fi
39848
39849 if test -n "$ac_config_links"; then
39850   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
39851 fi
39852
39853 if test -n "$ac_config_commands"; then
39854   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
39855 fi
39856
39857 cat >>$CONFIG_STATUS <<\_ACEOF
39858
39859 ac_cs_usage="\
39860 \`$as_me' instantiates files from templates according to the
39861 current configuration.
39862
39863 Usage: $0 [OPTIONS] [FILE]...
39864
39865   -h, --help       print this help, then exit
39866   -V, --version    print version number, then exit
39867   -q, --quiet      do not print progress messages
39868   -d, --debug      don't remove temporary files
39869       --recheck    update $as_me by reconfiguring in the same conditions
39870   --file=FILE[:TEMPLATE]
39871                    instantiate the configuration file FILE
39872   --header=FILE[:TEMPLATE]
39873                    instantiate the configuration header FILE
39874
39875 Configuration files:
39876 $config_files
39877
39878 Configuration headers:
39879 $config_headers
39880
39881 Configuration commands:
39882 $config_commands
39883
39884 Report bugs to <bug-autoconf@gnu.org>."
39885 _ACEOF
39886
39887 cat >>$CONFIG_STATUS <<_ACEOF
39888 ac_cs_version="\\
39889 config.status
39890 configured by $0, generated by GNU Autoconf 2.59,
39891   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
39892
39893 Copyright (C) 2003 Free Software Foundation, Inc.
39894 This config.status script is free software; the Free Software Foundation
39895 gives unlimited permission to copy, distribute and modify it."
39896 srcdir=$srcdir
39897 INSTALL="$INSTALL"
39898 _ACEOF
39899
39900 cat >>$CONFIG_STATUS <<\_ACEOF
39901 # If no file are specified by the user, then we need to provide default
39902 # value.  By we need to know if files were specified by the user.
39903 ac_need_defaults=:
39904 while test $# != 0
39905 do
39906   case $1 in
39907   --*=*)
39908     ac_option=`expr "x$1" : 'x\([^=]*\)='`
39909     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
39910     ac_shift=:
39911     ;;
39912   -*)
39913     ac_option=$1
39914     ac_optarg=$2
39915     ac_shift=shift
39916     ;;
39917   *) # This is not an option, so the user has probably given explicit
39918      # arguments.
39919      ac_option=$1
39920      ac_need_defaults=false;;
39921   esac
39922
39923   case $ac_option in
39924   # Handling of the options.
39925 _ACEOF
39926 cat >>$CONFIG_STATUS <<\_ACEOF
39927   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
39928     ac_cs_recheck=: ;;
39929   --version | --vers* | -V )
39930     echo "$ac_cs_version"; exit 0 ;;
39931   --he | --h)
39932     # Conflict between --help and --header
39933     { { echo "$as_me:$LINENO: error: ambiguous option: $1
39934 Try \`$0 --help' for more information." >&5
39935 echo "$as_me: error: ambiguous option: $1
39936 Try \`$0 --help' for more information." >&2;}
39937    { (exit 1); exit 1; }; };;
39938   --help | --hel | -h )
39939     echo "$ac_cs_usage"; exit 0 ;;
39940   --debug | --d* | -d )
39941     debug=: ;;
39942   --file | --fil | --fi | --f )
39943     $ac_shift
39944     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
39945     ac_need_defaults=false;;
39946   --header | --heade | --head | --hea )
39947     $ac_shift
39948     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
39949     ac_need_defaults=false;;
39950   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
39951   | -silent | --silent | --silen | --sile | --sil | --si | --s)
39952     ac_cs_silent=: ;;
39953
39954   # This is an error.
39955   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
39956 Try \`$0 --help' for more information." >&5
39957 echo "$as_me: error: unrecognized option: $1
39958 Try \`$0 --help' for more information." >&2;}
39959    { (exit 1); exit 1; }; } ;;
39960
39961   *) ac_config_targets="$ac_config_targets $1" ;;
39962
39963   esac
39964   shift
39965 done
39966
39967 ac_configure_extra_args=
39968
39969 if $ac_cs_silent; then
39970   exec 6>/dev/null
39971   ac_configure_extra_args="$ac_configure_extra_args --silent"
39972 fi
39973
39974 _ACEOF
39975 cat >>$CONFIG_STATUS <<_ACEOF
39976 if \$ac_cs_recheck; then
39977   echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
39978   exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
39979 fi
39980
39981 _ACEOF
39982
39983 cat >>$CONFIG_STATUS <<_ACEOF
39984 #
39985 # INIT-COMMANDS section.
39986 #
39987
39988 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
39989
39990 STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS"
39991 STATIC_OVERLAYS="$SLAPD_STATIC_OVERLAYS"
39992
39993
39994 _ACEOF
39995
39996
39997
39998 cat >>$CONFIG_STATUS <<\_ACEOF
39999 for ac_config_target in $ac_config_targets
40000 do
40001   case "$ac_config_target" in
40002   # Handling of arguments.
40003   "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile:build/top.mk:Makefile.in:build/dir.mk" ;;
40004   "doc/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/Makefile:build/top.mk:doc/Makefile.in:build/dir.mk" ;;
40005   "doc/man/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/Makefile:build/top.mk:doc/man/Makefile.in:build/dir.mk" ;;
40006   "doc/man/man1/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man1/Makefile:build/top.mk:doc/man/man1/Makefile.in:build/man.mk" ;;
40007   "doc/man/man3/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man3/Makefile:build/top.mk:doc/man/man3/Makefile.in:build/man.mk" ;;
40008   "doc/man/man5/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man5/Makefile:build/top.mk:doc/man/man5/Makefile.in:build/man.mk" ;;
40009   "doc/man/man8/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man8/Makefile:build/top.mk:doc/man/man8/Makefile.in:build/man.mk" ;;
40010   "clients/Makefile" ) CONFIG_FILES="$CONFIG_FILES clients/Makefile:build/top.mk:clients/Makefile.in:build/dir.mk" ;;
40011   "clients/tools/Makefile" ) CONFIG_FILES="$CONFIG_FILES clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk" ;;
40012   "include/Makefile" ) CONFIG_FILES="$CONFIG_FILES include/Makefile:build/top.mk:include/Makefile.in" ;;
40013   "libraries/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/Makefile:build/top.mk:libraries/Makefile.in:build/dir.mk" ;;
40014   "libraries/liblber/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblber/Makefile:build/top.mk:libraries/liblber/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
40015   "libraries/libldap/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/libldap/Makefile:build/top.mk:libraries/libldap/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
40016   "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" ;;
40017   "libraries/liblunicode/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblunicode/Makefile:build/top.mk:libraries/liblunicode/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
40018   "libraries/liblutil/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblutil/Makefile:build/top.mk:libraries/liblutil/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
40019   "libraries/librewrite/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/librewrite/Makefile:build/top.mk:libraries/librewrite/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
40020   "servers/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/Makefile:build/top.mk:servers/Makefile.in:build/dir.mk" ;;
40021   "servers/slapd/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/Makefile:build/top.mk:servers/slapd/Makefile.in:build/srv.mk" ;;
40022   "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" ;;
40023   "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" ;;
40024   "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" ;;
40025   "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" ;;
40026   "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" ;;
40027   "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" ;;
40028   "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" ;;
40029   "servers/slapd/back-ndb/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-ndb/Makefile:build/top.mk:servers/slapd/back-ndb/Makefile.in:build/mod.mk" ;;
40030   "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" ;;
40031   "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" ;;
40032   "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" ;;
40033   "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" ;;
40034   "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" ;;
40035   "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" ;;
40036   "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" ;;
40037   "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" ;;
40038   "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" ;;
40039   "servers/slapd/overlays/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/overlays/Makefile:build/top.mk:servers/slapd/overlays/Makefile.in:build/lib.mk" ;;
40040   "tests/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/Makefile:build/top.mk:tests/Makefile.in:build/dir.mk" ;;
40041   "tests/run" ) CONFIG_FILES="$CONFIG_FILES tests/run" ;;
40042   "tests/progs/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/progs/Makefile:build/top.mk:tests/progs/Makefile.in:build/rules.mk" ;;
40043   "depfiles" ) CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
40044   "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
40045   "include/portable.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/portable.h:include/portable.hin" ;;
40046   "include/ldap_features.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ldap_features.h:include/ldap_features.hin" ;;
40047   "include/lber_types.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/lber_types.h:include/lber_types.hin" ;;
40048   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
40049 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
40050    { (exit 1); exit 1; }; };;
40051   esac
40052 done
40053
40054 # If the user did not use the arguments to specify the items to instantiate,
40055 # then the envvar interface is used.  Set only those that are not.
40056 # We use the long form for the default assignment because of an extremely
40057 # bizarre bug on SunOS 4.1.3.
40058 if $ac_need_defaults; then
40059   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
40060   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
40061   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
40062 fi
40063
40064 # Have a temporary directory for convenience.  Make it in the build tree
40065 # simply because there is no reason to put it here, and in addition,
40066 # creating and moving files from /tmp can sometimes cause problems.
40067 # Create a temporary directory, and hook for its removal unless debugging.
40068 $debug ||
40069 {
40070   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
40071   trap '{ (exit 1); exit 1; }' 1 2 13 15
40072 }
40073
40074 # Create a (secure) tmp directory for tmp files.
40075
40076 {
40077   tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
40078   test -n "$tmp" && test -d "$tmp"
40079 }  ||
40080 {
40081   tmp=./confstat$$-$RANDOM
40082   (umask 077 && mkdir $tmp)
40083 } ||
40084 {
40085    echo "$me: cannot create a temporary directory in ." >&2
40086    { (exit 1); exit 1; }
40087 }
40088
40089 _ACEOF
40090
40091 cat >>$CONFIG_STATUS <<_ACEOF
40092
40093 #
40094 # CONFIG_FILES section.
40095 #
40096
40097 # No need to generate the scripts if there are no CONFIG_FILES.
40098 # This happens for instance when ./config.status config.h
40099 if test -n "\$CONFIG_FILES"; then
40100   # Protect against being on the right side of a sed subst in config.status.
40101   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
40102    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
40103 s,@SHELL@,$SHELL,;t t
40104 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
40105 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
40106 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
40107 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
40108 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
40109 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
40110 s,@exec_prefix@,$exec_prefix,;t t
40111 s,@prefix@,$prefix,;t t
40112 s,@program_transform_name@,$program_transform_name,;t t
40113 s,@bindir@,$bindir,;t t
40114 s,@sbindir@,$sbindir,;t t
40115 s,@libexecdir@,$libexecdir,;t t
40116 s,@datadir@,$datadir,;t t
40117 s,@sysconfdir@,$sysconfdir,;t t
40118 s,@sharedstatedir@,$sharedstatedir,;t t
40119 s,@localstatedir@,$localstatedir,;t t
40120 s,@libdir@,$libdir,;t t
40121 s,@includedir@,$includedir,;t t
40122 s,@oldincludedir@,$oldincludedir,;t t
40123 s,@infodir@,$infodir,;t t
40124 s,@mandir@,$mandir,;t t
40125 s,@build_alias@,$build_alias,;t t
40126 s,@host_alias@,$host_alias,;t t
40127 s,@target_alias@,$target_alias,;t t
40128 s,@DEFS@,$DEFS,;t t
40129 s,@ECHO_C@,$ECHO_C,;t t
40130 s,@ECHO_N@,$ECHO_N,;t t
40131 s,@ECHO_T@,$ECHO_T,;t t
40132 s,@LIBS@,$LIBS,;t t
40133 s,@build@,$build,;t t
40134 s,@build_cpu@,$build_cpu,;t t
40135 s,@build_vendor@,$build_vendor,;t t
40136 s,@build_os@,$build_os,;t t
40137 s,@host@,$host,;t t
40138 s,@host_cpu@,$host_cpu,;t t
40139 s,@host_vendor@,$host_vendor,;t t
40140 s,@host_os@,$host_os,;t t
40141 s,@target@,$target,;t t
40142 s,@target_cpu@,$target_cpu,;t t
40143 s,@target_vendor@,$target_vendor,;t t
40144 s,@target_os@,$target_os,;t t
40145 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
40146 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
40147 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
40148 s,@CYGPATH_W@,$CYGPATH_W,;t t
40149 s,@PACKAGE@,$PACKAGE,;t t
40150 s,@VERSION@,$VERSION,;t t
40151 s,@ACLOCAL@,$ACLOCAL,;t t
40152 s,@AUTOCONF@,$AUTOCONF,;t t
40153 s,@AUTOMAKE@,$AUTOMAKE,;t t
40154 s,@AUTOHEADER@,$AUTOHEADER,;t t
40155 s,@MAKEINFO@,$MAKEINFO,;t t
40156 s,@install_sh@,$install_sh,;t t
40157 s,@STRIP@,$STRIP,;t t
40158 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
40159 s,@INSTALL_STRIP_PROGRAM@,$INSTALL_STRIP_PROGRAM,;t t
40160 s,@mkdir_p@,$mkdir_p,;t t
40161 s,@AWK@,$AWK,;t t
40162 s,@SET_MAKE@,$SET_MAKE,;t t
40163 s,@am__leading_dot@,$am__leading_dot,;t t
40164 s,@AMTAR@,$AMTAR,;t t
40165 s,@am__tar@,$am__tar,;t t
40166 s,@am__untar@,$am__untar,;t t
40167 s,@OPENLDAP_LIBRELEASE@,$OPENLDAP_LIBRELEASE,;t t
40168 s,@OPENLDAP_LIBVERSION@,$OPENLDAP_LIBVERSION,;t t
40169 s,@OPENLDAP_RELEASE_DATE@,$OPENLDAP_RELEASE_DATE,;t t
40170 s,@top_builddir@,$top_builddir,;t t
40171 s,@ldap_subdir@,$ldap_subdir,;t t
40172 s,@CC@,$CC,;t t
40173 s,@AR@,$AR,;t t
40174 s,@CFLAGS@,$CFLAGS,;t t
40175 s,@LDFLAGS@,$LDFLAGS,;t t
40176 s,@CPPFLAGS@,$CPPFLAGS,;t t
40177 s,@ac_ct_CC@,$ac_ct_CC,;t t
40178 s,@EXEEXT@,$EXEEXT,;t t
40179 s,@OBJEXT@,$OBJEXT,;t t
40180 s,@DEPDIR@,$DEPDIR,;t t
40181 s,@am__include@,$am__include,;t t
40182 s,@am__quote@,$am__quote,;t t
40183 s,@AMDEP_TRUE@,$AMDEP_TRUE,;t t
40184 s,@AMDEP_FALSE@,$AMDEP_FALSE,;t t
40185 s,@AMDEPBACKSLASH@,$AMDEPBACKSLASH,;t t
40186 s,@CCDEPMODE@,$CCDEPMODE,;t t
40187 s,@am__fastdepCC_TRUE@,$am__fastdepCC_TRUE,;t t
40188 s,@am__fastdepCC_FALSE@,$am__fastdepCC_FALSE,;t t
40189 s,@EGREP@,$EGREP,;t t
40190 s,@LN_S@,$LN_S,;t t
40191 s,@ECHO@,$ECHO,;t t
40192 s,@ac_ct_AR@,$ac_ct_AR,;t t
40193 s,@RANLIB@,$RANLIB,;t t
40194 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
40195 s,@DLLTOOL@,$DLLTOOL,;t t
40196 s,@ac_ct_DLLTOOL@,$ac_ct_DLLTOOL,;t t
40197 s,@AS@,$AS,;t t
40198 s,@ac_ct_AS@,$ac_ct_AS,;t t
40199 s,@OBJDUMP@,$OBJDUMP,;t t
40200 s,@ac_ct_OBJDUMP@,$ac_ct_OBJDUMP,;t t
40201 s,@CPP@,$CPP,;t t
40202 s,@LIBTOOL@,$LIBTOOL,;t t
40203 s,@PERLBIN@,$PERLBIN,;t t
40204 s,@OL_MKDEP@,$OL_MKDEP,;t t
40205 s,@OL_MKDEP_FLAGS@,$OL_MKDEP_FLAGS,;t t
40206 s,@LTSTATIC@,$LTSTATIC,;t t
40207 s,@MYSQL@,$MYSQL,;t t
40208 s,@LIBOBJS@,$LIBOBJS,;t t
40209 s,@LIBSRCS@,$LIBSRCS,;t t
40210 s,@PLAT@,$PLAT,;t t
40211 s,@WITH_SASL@,$WITH_SASL,;t t
40212 s,@WITH_TLS@,$WITH_TLS,;t t
40213 s,@WITH_MODULES_ENABLED@,$WITH_MODULES_ENABLED,;t t
40214 s,@WITH_ACI_ENABLED@,$WITH_ACI_ENABLED,;t t
40215 s,@BUILD_THREAD@,$BUILD_THREAD,;t t
40216 s,@BUILD_LIBS_DYNAMIC@,$BUILD_LIBS_DYNAMIC,;t t
40217 s,@BUILD_SLAPD@,$BUILD_SLAPD,;t t
40218 s,@BUILD_SLAPI@,$BUILD_SLAPI,;t t
40219 s,@SLAPD_SLAPI_DEPEND@,$SLAPD_SLAPI_DEPEND,;t t
40220 s,@BUILD_BDB@,$BUILD_BDB,;t t
40221 s,@BUILD_DNSSRV@,$BUILD_DNSSRV,;t t
40222 s,@BUILD_HDB@,$BUILD_HDB,;t t
40223 s,@BUILD_LDAP@,$BUILD_LDAP,;t t
40224 s,@BUILD_META@,$BUILD_META,;t t
40225 s,@BUILD_MONITOR@,$BUILD_MONITOR,;t t
40226 s,@BUILD_NDB@,$BUILD_NDB,;t t
40227 s,@BUILD_NULL@,$BUILD_NULL,;t t
40228 s,@BUILD_PASSWD@,$BUILD_PASSWD,;t t
40229 s,@BUILD_RELAY@,$BUILD_RELAY,;t t
40230 s,@BUILD_PERL@,$BUILD_PERL,;t t
40231 s,@BUILD_SHELL@,$BUILD_SHELL,;t t
40232 s,@BUILD_SOCK@,$BUILD_SOCK,;t t
40233 s,@BUILD_SQL@,$BUILD_SQL,;t t
40234 s,@BUILD_ACCESSLOG@,$BUILD_ACCESSLOG,;t t
40235 s,@BUILD_AUDITLOG@,$BUILD_AUDITLOG,;t t
40236 s,@BUILD_CONSTRAINT@,$BUILD_CONSTRAINT,;t t
40237 s,@BUILD_DDS@,$BUILD_DDS,;t t
40238 s,@BUILD_DENYOP@,$BUILD_DENYOP,;t t
40239 s,@BUILD_DYNGROUP@,$BUILD_DYNGROUP,;t t
40240 s,@BUILD_DYNLIST@,$BUILD_DYNLIST,;t t
40241 s,@BUILD_LASTMOD@,$BUILD_LASTMOD,;t t
40242 s,@BUILD_MEMBEROF@,$BUILD_MEMBEROF,;t t
40243 s,@BUILD_PPOLICY@,$BUILD_PPOLICY,;t t
40244 s,@BUILD_PROXYCACHE@,$BUILD_PROXYCACHE,;t t
40245 s,@BUILD_REFINT@,$BUILD_REFINT,;t t
40246 s,@BUILD_RETCODE@,$BUILD_RETCODE,;t t
40247 s,@BUILD_RWM@,$BUILD_RWM,;t t
40248 s,@BUILD_SEQMOD@,$BUILD_SEQMOD,;t t
40249 s,@BUILD_SYNCPROV@,$BUILD_SYNCPROV,;t t
40250 s,@BUILD_TRANSLUCENT@,$BUILD_TRANSLUCENT,;t t
40251 s,@BUILD_UNIQUE@,$BUILD_UNIQUE,;t t
40252 s,@BUILD_VALSORT@,$BUILD_VALSORT,;t t
40253 s,@LDAP_LIBS@,$LDAP_LIBS,;t t
40254 s,@SLAPD_LIBS@,$SLAPD_LIBS,;t t
40255 s,@BDB_LIBS@,$BDB_LIBS,;t t
40256 s,@SLAPD_NDB_LIBS@,$SLAPD_NDB_LIBS,;t t
40257 s,@SLAPD_NDB_INCS@,$SLAPD_NDB_INCS,;t t
40258 s,@LTHREAD_LIBS@,$LTHREAD_LIBS,;t t
40259 s,@LUTIL_LIBS@,$LUTIL_LIBS,;t t
40260 s,@WRAP_LIBS@,$WRAP_LIBS,;t t
40261 s,@SLAPD_MODULES_CPPFLAGS@,$SLAPD_MODULES_CPPFLAGS,;t t
40262 s,@SLAPD_MODULES_LDFLAGS@,$SLAPD_MODULES_LDFLAGS,;t t
40263 s,@SLAPD_NO_STATIC@,$SLAPD_NO_STATIC,;t t
40264 s,@SLAPD_STATIC_BACKENDS@,$SLAPD_STATIC_BACKENDS,;t t
40265 s,@SLAPD_DYNAMIC_BACKENDS@,$SLAPD_DYNAMIC_BACKENDS,;t t
40266 s,@SLAPD_STATIC_OVERLAYS@,$SLAPD_STATIC_OVERLAYS,;t t
40267 s,@SLAPD_DYNAMIC_OVERLAYS@,$SLAPD_DYNAMIC_OVERLAYS,;t t
40268 s,@PERL_CPPFLAGS@,$PERL_CPPFLAGS,;t t
40269 s,@SLAPD_PERL_LDFLAGS@,$SLAPD_PERL_LDFLAGS,;t t
40270 s,@MOD_PERL_LDFLAGS@,$MOD_PERL_LDFLAGS,;t t
40271 s,@KRB4_LIBS@,$KRB4_LIBS,;t t
40272 s,@KRB5_LIBS@,$KRB5_LIBS,;t t
40273 s,@SASL_LIBS@,$SASL_LIBS,;t t
40274 s,@TLS_LIBS@,$TLS_LIBS,;t t
40275 s,@MODULES_LIBS@,$MODULES_LIBS,;t t
40276 s,@SLAPI_LIBS@,$SLAPI_LIBS,;t t
40277 s,@LIBSLAPI@,$LIBSLAPI,;t t
40278 s,@LIBSLAPITOOLS@,$LIBSLAPITOOLS,;t t
40279 s,@AUTH_LIBS@,$AUTH_LIBS,;t t
40280 s,@ICU_LIBS@,$ICU_LIBS,;t t
40281 s,@SLAPD_SLP_LIBS@,$SLAPD_SLP_LIBS,;t t
40282 s,@SLAPD_GMP_LIBS@,$SLAPD_GMP_LIBS,;t t
40283 s,@SLAPD_SQL_LDFLAGS@,$SLAPD_SQL_LDFLAGS,;t t
40284 s,@SLAPD_SQL_LIBS@,$SLAPD_SQL_LIBS,;t t
40285 s,@SLAPD_SQL_INCLUDES@,$SLAPD_SQL_INCLUDES,;t t
40286 s,@LTLIBOBJS@,$LTLIBOBJS,;t t
40287 CEOF
40288
40289 _ACEOF
40290
40291   cat >>$CONFIG_STATUS <<\_ACEOF
40292   # Split the substitutions into bite-sized pieces for seds with
40293   # small command number limits, like on Digital OSF/1 and HP-UX.
40294   ac_max_sed_lines=48
40295   ac_sed_frag=1 # Number of current file.
40296   ac_beg=1 # First line for current file.
40297   ac_end=$ac_max_sed_lines # Line after last line for current file.
40298   ac_more_lines=:
40299   ac_sed_cmds=
40300   while $ac_more_lines; do
40301     if test $ac_beg -gt 1; then
40302       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
40303     else
40304       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
40305     fi
40306     if test ! -s $tmp/subs.frag; then
40307       ac_more_lines=false
40308     else
40309       # The purpose of the label and of the branching condition is to
40310       # speed up the sed processing (if there are no `@' at all, there
40311       # is no need to browse any of the substitutions).
40312       # These are the two extra sed commands mentioned above.
40313       (echo ':t
40314   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
40315       if test -z "$ac_sed_cmds"; then
40316         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
40317       else
40318         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
40319       fi
40320       ac_sed_frag=`expr $ac_sed_frag + 1`
40321       ac_beg=$ac_end
40322       ac_end=`expr $ac_end + $ac_max_sed_lines`
40323     fi
40324   done
40325   if test -z "$ac_sed_cmds"; then
40326     ac_sed_cmds=cat
40327   fi
40328 fi # test -n "$CONFIG_FILES"
40329
40330 _ACEOF
40331 cat >>$CONFIG_STATUS <<\_ACEOF
40332 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
40333   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
40334   case $ac_file in
40335   - | *:- | *:-:* ) # input from stdin
40336         cat >$tmp/stdin
40337         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
40338         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
40339   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
40340         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
40341   * )   ac_file_in=$ac_file.in ;;
40342   esac
40343
40344   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
40345   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
40346 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
40347          X"$ac_file" : 'X\(//\)[^/]' \| \
40348          X"$ac_file" : 'X\(//\)$' \| \
40349          X"$ac_file" : 'X\(/\)' \| \
40350          .     : '\(.\)' 2>/dev/null ||
40351 echo X"$ac_file" |
40352     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
40353           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
40354           /^X\(\/\/\)$/{ s//\1/; q; }
40355           /^X\(\/\).*/{ s//\1/; q; }
40356           s/.*/./; q'`
40357   { if $as_mkdir_p; then
40358     mkdir -p "$ac_dir"
40359   else
40360     as_dir="$ac_dir"
40361     as_dirs=
40362     while test ! -d "$as_dir"; do
40363       as_dirs="$as_dir $as_dirs"
40364       as_dir=`(dirname "$as_dir") 2>/dev/null ||
40365 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
40366          X"$as_dir" : 'X\(//\)[^/]' \| \
40367          X"$as_dir" : 'X\(//\)$' \| \
40368          X"$as_dir" : 'X\(/\)' \| \
40369          .     : '\(.\)' 2>/dev/null ||
40370 echo X"$as_dir" |
40371     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
40372           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
40373           /^X\(\/\/\)$/{ s//\1/; q; }
40374           /^X\(\/\).*/{ s//\1/; q; }
40375           s/.*/./; q'`
40376     done
40377     test ! -n "$as_dirs" || mkdir $as_dirs
40378   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
40379 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
40380    { (exit 1); exit 1; }; }; }
40381
40382   ac_builddir=.
40383
40384 if test "$ac_dir" != .; then
40385   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
40386   # A "../" for each directory in $ac_dir_suffix.
40387   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
40388 else
40389   ac_dir_suffix= ac_top_builddir=
40390 fi
40391
40392 case $srcdir in
40393   .)  # No --srcdir option.  We are building in place.
40394     ac_srcdir=.
40395     if test -z "$ac_top_builddir"; then
40396        ac_top_srcdir=.
40397     else
40398        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
40399     fi ;;
40400   [\\/]* | ?:[\\/]* )  # Absolute path.
40401     ac_srcdir=$srcdir$ac_dir_suffix;
40402     ac_top_srcdir=$srcdir ;;
40403   *) # Relative path.
40404     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
40405     ac_top_srcdir=$ac_top_builddir$srcdir ;;
40406 esac
40407
40408 # Do not use `cd foo && pwd` to compute absolute paths, because
40409 # the directories may not exist.
40410 case `pwd` in
40411 .) ac_abs_builddir="$ac_dir";;
40412 *)
40413   case "$ac_dir" in
40414   .) ac_abs_builddir=`pwd`;;
40415   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
40416   *) ac_abs_builddir=`pwd`/"$ac_dir";;
40417   esac;;
40418 esac
40419 case $ac_abs_builddir in
40420 .) ac_abs_top_builddir=${ac_top_builddir}.;;
40421 *)
40422   case ${ac_top_builddir}. in
40423   .) ac_abs_top_builddir=$ac_abs_builddir;;
40424   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
40425   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
40426   esac;;
40427 esac
40428 case $ac_abs_builddir in
40429 .) ac_abs_srcdir=$ac_srcdir;;
40430 *)
40431   case $ac_srcdir in
40432   .) ac_abs_srcdir=$ac_abs_builddir;;
40433   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
40434   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
40435   esac;;
40436 esac
40437 case $ac_abs_builddir in
40438 .) ac_abs_top_srcdir=$ac_top_srcdir;;
40439 *)
40440   case $ac_top_srcdir in
40441   .) ac_abs_top_srcdir=$ac_abs_builddir;;
40442   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
40443   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
40444   esac;;
40445 esac
40446
40447
40448   case $INSTALL in
40449   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
40450   *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
40451   esac
40452
40453   if test x"$ac_file" != x-; then
40454     { echo "$as_me:$LINENO: creating $ac_file" >&5
40455 echo "$as_me: creating $ac_file" >&6;}
40456     rm -f "$ac_file"
40457   fi
40458   # Let's still pretend it is `configure' which instantiates (i.e., don't
40459   # use $as_me), people would be surprised to read:
40460   #    /* config.h.  Generated by config.status.  */
40461   if test x"$ac_file" = x-; then
40462     configure_input=
40463   else
40464     configure_input="$ac_file.  "
40465   fi
40466   configure_input=$configure_input"Generated from `echo $ac_file_in |
40467                                      sed 's,.*/,,'` by configure."
40468
40469   # First look for the input files in the build tree, otherwise in the
40470   # src tree.
40471   ac_file_inputs=`IFS=:
40472     for f in $ac_file_in; do
40473       case $f in
40474       -) echo $tmp/stdin ;;
40475       [\\/$]*)
40476          # Absolute (can't be DOS-style, as IFS=:)
40477          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
40478 echo "$as_me: error: cannot find input file: $f" >&2;}
40479    { (exit 1); exit 1; }; }
40480          echo "$f";;
40481       *) # Relative
40482          if test -f "$f"; then
40483            # Build tree
40484            echo "$f"
40485          elif test -f "$srcdir/$f"; then
40486            # Source tree
40487            echo "$srcdir/$f"
40488          else
40489            # /dev/null tree
40490            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
40491 echo "$as_me: error: cannot find input file: $f" >&2;}
40492    { (exit 1); exit 1; }; }
40493          fi;;
40494       esac
40495     done` || { (exit 1); exit 1; }
40496 _ACEOF
40497 cat >>$CONFIG_STATUS <<_ACEOF
40498   sed "$ac_vpsub
40499 $extrasub
40500 _ACEOF
40501 cat >>$CONFIG_STATUS <<\_ACEOF
40502 :t
40503 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
40504 s,@configure_input@,$configure_input,;t t
40505 s,@srcdir@,$ac_srcdir,;t t
40506 s,@abs_srcdir@,$ac_abs_srcdir,;t t
40507 s,@top_srcdir@,$ac_top_srcdir,;t t
40508 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
40509 s,@builddir@,$ac_builddir,;t t
40510 s,@abs_builddir@,$ac_abs_builddir,;t t
40511 s,@top_builddir@,$ac_top_builddir,;t t
40512 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
40513 s,@INSTALL@,$ac_INSTALL,;t t
40514 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
40515   rm -f $tmp/stdin
40516   if test x"$ac_file" != x-; then
40517     mv $tmp/out $ac_file
40518   else
40519     cat $tmp/out
40520     rm -f $tmp/out
40521   fi
40522
40523 done
40524 _ACEOF
40525 cat >>$CONFIG_STATUS <<\_ACEOF
40526
40527 #
40528 # CONFIG_HEADER section.
40529 #
40530
40531 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
40532 # NAME is the cpp macro being defined and VALUE is the value it is being given.
40533 #
40534 # ac_d sets the value in "#define NAME VALUE" lines.
40535 ac_dA='s,^\([    ]*\)#\([        ]*define[       ][      ]*\)'
40536 ac_dB='[         ].*$,\1#\2'
40537 ac_dC=' '
40538 ac_dD=',;t'
40539 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
40540 ac_uA='s,^\([    ]*\)#\([        ]*\)undef\([    ][      ]*\)'
40541 ac_uB='$,\1#\2define\3'
40542 ac_uC=' '
40543 ac_uD=',;t'
40544
40545 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
40546   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
40547   case $ac_file in
40548   - | *:- | *:-:* ) # input from stdin
40549         cat >$tmp/stdin
40550         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
40551         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
40552   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
40553         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
40554   * )   ac_file_in=$ac_file.in ;;
40555   esac
40556
40557   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
40558 echo "$as_me: creating $ac_file" >&6;}
40559
40560   # First look for the input files in the build tree, otherwise in the
40561   # src tree.
40562   ac_file_inputs=`IFS=:
40563     for f in $ac_file_in; do
40564       case $f in
40565       -) echo $tmp/stdin ;;
40566       [\\/$]*)
40567          # Absolute (can't be DOS-style, as IFS=:)
40568          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
40569 echo "$as_me: error: cannot find input file: $f" >&2;}
40570    { (exit 1); exit 1; }; }
40571          # Do quote $f, to prevent DOS paths from being IFS'd.
40572          echo "$f";;
40573       *) # Relative
40574          if test -f "$f"; then
40575            # Build tree
40576            echo "$f"
40577          elif test -f "$srcdir/$f"; then
40578            # Source tree
40579            echo "$srcdir/$f"
40580          else
40581            # /dev/null tree
40582            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
40583 echo "$as_me: error: cannot find input file: $f" >&2;}
40584    { (exit 1); exit 1; }; }
40585          fi;;
40586       esac
40587     done` || { (exit 1); exit 1; }
40588   # Remove the trailing spaces.
40589   sed 's/[       ]*$//' $ac_file_inputs >$tmp/in
40590
40591 _ACEOF
40592
40593 # Transform confdefs.h into two sed scripts, `conftest.defines' and
40594 # `conftest.undefs', that substitutes the proper values into
40595 # config.h.in to produce config.h.  The first handles `#define'
40596 # templates, and the second `#undef' templates.
40597 # And first: Protect against being on the right side of a sed subst in
40598 # config.status.  Protect against being in an unquoted here document
40599 # in config.status.
40600 rm -f conftest.defines conftest.undefs
40601 # Using a here document instead of a string reduces the quoting nightmare.
40602 # Putting comments in sed scripts is not portable.
40603 #
40604 # `end' is used to avoid that the second main sed command (meant for
40605 # 0-ary CPP macros) applies to n-ary macro definitions.
40606 # See the Autoconf documentation for `clear'.
40607 cat >confdef2sed.sed <<\_ACEOF
40608 s/[\\&,]/\\&/g
40609 s,[\\$`],\\&,g
40610 t clear
40611 : clear
40612 s,^[     ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
40613 t end
40614 s,^[     ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
40615 : end
40616 _ACEOF
40617 # If some macros were called several times there might be several times
40618 # the same #defines, which is useless.  Nevertheless, we may not want to
40619 # sort them, since we want the *last* AC-DEFINE to be honored.
40620 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
40621 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
40622 rm -f confdef2sed.sed
40623
40624 # This sed command replaces #undef with comments.  This is necessary, for
40625 # example, in the case of _POSIX_SOURCE, which is predefined and required
40626 # on some systems where configure will not decide to define it.
40627 cat >>conftest.undefs <<\_ACEOF
40628 s,^[     ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
40629 _ACEOF
40630
40631 # Break up conftest.defines because some shells have a limit on the size
40632 # of here documents, and old seds have small limits too (100 cmds).
40633 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
40634 echo '  if grep "^[      ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
40635 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
40636 echo '  :' >>$CONFIG_STATUS
40637 rm -f conftest.tail
40638 while grep . conftest.defines >/dev/null
40639 do
40640   # Write a limited-size here document to $tmp/defines.sed.
40641   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
40642   # Speed up: don't consider the non `#define' lines.
40643   echo '/^[      ]*#[    ]*define/!b' >>$CONFIG_STATUS
40644   # Work around the forget-to-reset-the-flag bug.
40645   echo 't clr' >>$CONFIG_STATUS
40646   echo ': clr' >>$CONFIG_STATUS
40647   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
40648   echo 'CEOF
40649   sed -f $tmp/defines.sed $tmp/in >$tmp/out
40650   rm -f $tmp/in
40651   mv $tmp/out $tmp/in
40652 ' >>$CONFIG_STATUS
40653   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
40654   rm -f conftest.defines
40655   mv conftest.tail conftest.defines
40656 done
40657 rm -f conftest.defines
40658 echo '  fi # grep' >>$CONFIG_STATUS
40659 echo >>$CONFIG_STATUS
40660
40661 # Break up conftest.undefs because some shells have a limit on the size
40662 # of here documents, and old seds have small limits too (100 cmds).
40663 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
40664 rm -f conftest.tail
40665 while grep . conftest.undefs >/dev/null
40666 do
40667   # Write a limited-size here document to $tmp/undefs.sed.
40668   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
40669   # Speed up: don't consider the non `#undef'
40670   echo '/^[      ]*#[    ]*undef/!b' >>$CONFIG_STATUS
40671   # Work around the forget-to-reset-the-flag bug.
40672   echo 't clr' >>$CONFIG_STATUS
40673   echo ': clr' >>$CONFIG_STATUS
40674   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
40675   echo 'CEOF
40676   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
40677   rm -f $tmp/in
40678   mv $tmp/out $tmp/in
40679 ' >>$CONFIG_STATUS
40680   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
40681   rm -f conftest.undefs
40682   mv conftest.tail conftest.undefs
40683 done
40684 rm -f conftest.undefs
40685
40686 cat >>$CONFIG_STATUS <<\_ACEOF
40687   # Let's still pretend it is `configure' which instantiates (i.e., don't
40688   # use $as_me), people would be surprised to read:
40689   #    /* config.h.  Generated by config.status.  */
40690   if test x"$ac_file" = x-; then
40691     echo "/* Generated by configure.  */" >$tmp/config.h
40692   else
40693     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
40694   fi
40695   cat $tmp/in >>$tmp/config.h
40696   rm -f $tmp/in
40697   if test x"$ac_file" != x-; then
40698     if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
40699       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
40700 echo "$as_me: $ac_file is unchanged" >&6;}
40701     else
40702       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
40703 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
40704          X"$ac_file" : 'X\(//\)[^/]' \| \
40705          X"$ac_file" : 'X\(//\)$' \| \
40706          X"$ac_file" : 'X\(/\)' \| \
40707          .     : '\(.\)' 2>/dev/null ||
40708 echo X"$ac_file" |
40709     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
40710           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
40711           /^X\(\/\/\)$/{ s//\1/; q; }
40712           /^X\(\/\).*/{ s//\1/; q; }
40713           s/.*/./; q'`
40714       { if $as_mkdir_p; then
40715     mkdir -p "$ac_dir"
40716   else
40717     as_dir="$ac_dir"
40718     as_dirs=
40719     while test ! -d "$as_dir"; do
40720       as_dirs="$as_dir $as_dirs"
40721       as_dir=`(dirname "$as_dir") 2>/dev/null ||
40722 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
40723          X"$as_dir" : 'X\(//\)[^/]' \| \
40724          X"$as_dir" : 'X\(//\)$' \| \
40725          X"$as_dir" : 'X\(/\)' \| \
40726          .     : '\(.\)' 2>/dev/null ||
40727 echo X"$as_dir" |
40728     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
40729           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
40730           /^X\(\/\/\)$/{ s//\1/; q; }
40731           /^X\(\/\).*/{ s//\1/; q; }
40732           s/.*/./; q'`
40733     done
40734     test ! -n "$as_dirs" || mkdir $as_dirs
40735   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
40736 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
40737    { (exit 1); exit 1; }; }; }
40738
40739       rm -f $ac_file
40740       mv $tmp/config.h $ac_file
40741     fi
40742   else
40743     cat $tmp/config.h
40744     rm -f $tmp/config.h
40745   fi
40746 # Compute $ac_file's index in $config_headers.
40747 _am_stamp_count=1
40748 for _am_header in $config_headers :; do
40749   case $_am_header in
40750     $ac_file | $ac_file:* )
40751       break ;;
40752     * )
40753       _am_stamp_count=`expr $_am_stamp_count + 1` ;;
40754   esac
40755 done
40756 echo "timestamp for $ac_file" >`(dirname $ac_file) 2>/dev/null ||
40757 $as_expr X$ac_file : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
40758          X$ac_file : 'X\(//\)[^/]' \| \
40759          X$ac_file : 'X\(//\)$' \| \
40760          X$ac_file : 'X\(/\)' \| \
40761          .     : '\(.\)' 2>/dev/null ||
40762 echo X$ac_file |
40763     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
40764           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
40765           /^X\(\/\/\)$/{ s//\1/; q; }
40766           /^X\(\/\).*/{ s//\1/; q; }
40767           s/.*/./; q'`/stamp-h$_am_stamp_count
40768 done
40769 _ACEOF
40770 cat >>$CONFIG_STATUS <<\_ACEOF
40771
40772 #
40773 # CONFIG_COMMANDS section.
40774 #
40775 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
40776   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
40777   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
40778   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
40779 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
40780          X"$ac_dest" : 'X\(//\)[^/]' \| \
40781          X"$ac_dest" : 'X\(//\)$' \| \
40782          X"$ac_dest" : 'X\(/\)' \| \
40783          .     : '\(.\)' 2>/dev/null ||
40784 echo X"$ac_dest" |
40785     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
40786           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
40787           /^X\(\/\/\)$/{ s//\1/; q; }
40788           /^X\(\/\).*/{ s//\1/; q; }
40789           s/.*/./; q'`
40790   { if $as_mkdir_p; then
40791     mkdir -p "$ac_dir"
40792   else
40793     as_dir="$ac_dir"
40794     as_dirs=
40795     while test ! -d "$as_dir"; do
40796       as_dirs="$as_dir $as_dirs"
40797       as_dir=`(dirname "$as_dir") 2>/dev/null ||
40798 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
40799          X"$as_dir" : 'X\(//\)[^/]' \| \
40800          X"$as_dir" : 'X\(//\)$' \| \
40801          X"$as_dir" : 'X\(/\)' \| \
40802          .     : '\(.\)' 2>/dev/null ||
40803 echo X"$as_dir" |
40804     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
40805           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
40806           /^X\(\/\/\)$/{ s//\1/; q; }
40807           /^X\(\/\).*/{ s//\1/; q; }
40808           s/.*/./; q'`
40809     done
40810     test ! -n "$as_dirs" || mkdir $as_dirs
40811   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
40812 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
40813    { (exit 1); exit 1; }; }; }
40814
40815   ac_builddir=.
40816
40817 if test "$ac_dir" != .; then
40818   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
40819   # A "../" for each directory in $ac_dir_suffix.
40820   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
40821 else
40822   ac_dir_suffix= ac_top_builddir=
40823 fi
40824
40825 case $srcdir in
40826   .)  # No --srcdir option.  We are building in place.
40827     ac_srcdir=.
40828     if test -z "$ac_top_builddir"; then
40829        ac_top_srcdir=.
40830     else
40831        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
40832     fi ;;
40833   [\\/]* | ?:[\\/]* )  # Absolute path.
40834     ac_srcdir=$srcdir$ac_dir_suffix;
40835     ac_top_srcdir=$srcdir ;;
40836   *) # Relative path.
40837     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
40838     ac_top_srcdir=$ac_top_builddir$srcdir ;;
40839 esac
40840
40841 # Do not use `cd foo && pwd` to compute absolute paths, because
40842 # the directories may not exist.
40843 case `pwd` in
40844 .) ac_abs_builddir="$ac_dir";;
40845 *)
40846   case "$ac_dir" in
40847   .) ac_abs_builddir=`pwd`;;
40848   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
40849   *) ac_abs_builddir=`pwd`/"$ac_dir";;
40850   esac;;
40851 esac
40852 case $ac_abs_builddir in
40853 .) ac_abs_top_builddir=${ac_top_builddir}.;;
40854 *)
40855   case ${ac_top_builddir}. in
40856   .) ac_abs_top_builddir=$ac_abs_builddir;;
40857   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
40858   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
40859   esac;;
40860 esac
40861 case $ac_abs_builddir in
40862 .) ac_abs_srcdir=$ac_srcdir;;
40863 *)
40864   case $ac_srcdir in
40865   .) ac_abs_srcdir=$ac_abs_builddir;;
40866   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
40867   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
40868   esac;;
40869 esac
40870 case $ac_abs_builddir in
40871 .) ac_abs_top_srcdir=$ac_top_srcdir;;
40872 *)
40873   case $ac_top_srcdir in
40874   .) ac_abs_top_srcdir=$ac_abs_builddir;;
40875   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
40876   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
40877   esac;;
40878 esac
40879
40880
40881   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
40882 echo "$as_me: executing $ac_dest commands" >&6;}
40883   case $ac_dest in
40884     depfiles ) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do
40885   # Strip MF so we end up with the name of the file.
40886   mf=`echo "$mf" | sed -e 's/:.*$//'`
40887   # Check whether this is an Automake generated Makefile or not.
40888   # We used to match only the files named `Makefile.in', but
40889   # some people rename them; so instead we look at the file content.
40890   # Grep'ing the first line is not enough: some people post-process
40891   # each Makefile.in and add a new line on top of each file to say so.
40892   # So let's grep whole file.
40893   if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
40894     dirpart=`(dirname "$mf") 2>/dev/null ||
40895 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
40896          X"$mf" : 'X\(//\)[^/]' \| \
40897          X"$mf" : 'X\(//\)$' \| \
40898          X"$mf" : 'X\(/\)' \| \
40899          .     : '\(.\)' 2>/dev/null ||
40900 echo X"$mf" |
40901     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
40902           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
40903           /^X\(\/\/\)$/{ s//\1/; q; }
40904           /^X\(\/\).*/{ s//\1/; q; }
40905           s/.*/./; q'`
40906   else
40907     continue
40908   fi
40909   # Extract the definition of DEPDIR, am__include, and am__quote
40910   # from the Makefile without running `make'.
40911   DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
40912   test -z "$DEPDIR" && continue
40913   am__include=`sed -n 's/^am__include = //p' < "$mf"`
40914   test -z "am__include" && continue
40915   am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
40916   # When using ansi2knr, U may be empty or an underscore; expand it
40917   U=`sed -n 's/^U = //p' < "$mf"`
40918   # Find all dependency output files, they are included files with
40919   # $(DEPDIR) in their names.  We invoke sed twice because it is the
40920   # simplest approach to changing $(DEPDIR) to its actual value in the
40921   # expansion.
40922   for file in `sed -n "
40923     s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
40924        sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
40925     # Make sure the directory exists.
40926     test -f "$dirpart/$file" && continue
40927     fdir=`(dirname "$file") 2>/dev/null ||
40928 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
40929          X"$file" : 'X\(//\)[^/]' \| \
40930          X"$file" : 'X\(//\)$' \| \
40931          X"$file" : 'X\(/\)' \| \
40932          .     : '\(.\)' 2>/dev/null ||
40933 echo X"$file" |
40934     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
40935           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
40936           /^X\(\/\/\)$/{ s//\1/; q; }
40937           /^X\(\/\).*/{ s//\1/; q; }
40938           s/.*/./; q'`
40939     { if $as_mkdir_p; then
40940     mkdir -p $dirpart/$fdir
40941   else
40942     as_dir=$dirpart/$fdir
40943     as_dirs=
40944     while test ! -d "$as_dir"; do
40945       as_dirs="$as_dir $as_dirs"
40946       as_dir=`(dirname "$as_dir") 2>/dev/null ||
40947 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
40948          X"$as_dir" : 'X\(//\)[^/]' \| \
40949          X"$as_dir" : 'X\(//\)$' \| \
40950          X"$as_dir" : 'X\(/\)' \| \
40951          .     : '\(.\)' 2>/dev/null ||
40952 echo X"$as_dir" |
40953     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
40954           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
40955           /^X\(\/\/\)$/{ s//\1/; q; }
40956           /^X\(\/\).*/{ s//\1/; q; }
40957           s/.*/./; q'`
40958     done
40959     test ! -n "$as_dirs" || mkdir $as_dirs
40960   fi || { { echo "$as_me:$LINENO: error: cannot create directory $dirpart/$fdir" >&5
40961 echo "$as_me: error: cannot create directory $dirpart/$fdir" >&2;}
40962    { (exit 1); exit 1; }; }; }
40963
40964     # echo "creating $dirpart/$file"
40965     echo '# dummy' > "$dirpart/$file"
40966   done
40967 done
40968  ;;
40969     default )
40970 chmod +x tests/run
40971 date > stamp-h
40972 BACKENDSC="servers/slapd/backends.c"
40973 echo "Making $BACKENDSC"
40974 rm -f $BACKENDSC
40975 cat > $BACKENDSC << ENDX
40976 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
40977  *
40978  * Copyright 1998-2008 The OpenLDAP Foundation.
40979  * All rights reserved.
40980  *
40981  * Redistribution and use in source and binary forms, with or without
40982  * modification, are permitted only as authorized by the OpenLDAP
40983  * Public License.
40984  *
40985  * A copy of this license is available in the file LICENSE in the
40986  * top-level directory of the distribution or, alternatively, at
40987  * <http://www.OpenLDAP.org/license.html>.
40988  */
40989 /* This file is automatically generated by configure; please do not edit. */
40990
40991 #include "portable.h"
40992 #include "slap.h"
40993
40994 ENDX
40995 if test "${STATIC_BACKENDS}"; then
40996         for b in config ${STATIC_BACKENDS}; do
40997                 bb=`echo "${b}" | sed -e 's/back-//'`
40998                 cat >> $BACKENDSC << ENDX
40999 extern BI_init ${bb}_back_initialize;
41000 ENDX
41001         done
41002
41003         cat >> $BACKENDSC << ENDX
41004
41005 BackendInfo slap_binfo[] = {
41006 ENDX
41007
41008         for b in config ${STATIC_BACKENDS}; do
41009                 bb=`echo "${b}" | sed -e 's/back-//'`
41010                 echo "    Add ${bb} ..."
41011                 cat >> $BACKENDSC << ENDX
41012         { "${bb}", ${bb}_back_initialize },
41013 ENDX
41014         done
41015
41016         cat >> $BACKENDSC << ENDX
41017         { NULL, NULL },
41018 };
41019
41020 /* end of generated file */
41021 ENDX
41022 fi
41023 OVERLAYSC="servers/slapd/overlays/statover.c"
41024 echo "Making $OVERLAYSC"
41025 rm -f $OVERLAYSC
41026 cat > $OVERLAYSC << ENDX
41027 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
41028  *
41029  * Copyright 1998-2008 The OpenLDAP Foundation.
41030  * All rights reserved.
41031  *
41032  * Redistribution and use in source and binary forms, with or without
41033  * modification, are permitted only as authorized by the OpenLDAP
41034  * Public License.
41035  *
41036  * A copy of this license is available in the file LICENSE in the
41037  * top-level directory of the distribution or, alternatively, at
41038  * <http://www.OpenLDAP.org/license.html>.
41039  */
41040 /* This file is automatically generated by configure; please do not edit. */
41041
41042 #include "portable.h"
41043 #include "slap.h"
41044
41045 ENDX
41046 if test "${STATIC_OVERLAYS}"; then
41047         for o in ${STATIC_OVERLAYS}; do
41048                 oo=`echo "${o}" | sed -e 's/.o$//' -e 's/_x$//'`
41049                 cat >> $OVERLAYSC << ENDX
41050 extern OV_init ${oo}_initialize;
41051 ENDX
41052         done
41053 fi
41054
41055 cat >> $OVERLAYSC << ENDX
41056
41057 OverlayInit slap_oinfo[] = {
41058 ENDX
41059
41060 if test "${STATIC_OVERLAYS}"; then
41061         for o in ${STATIC_OVERLAYS}; do
41062                 oo=`echo "${o}" | sed -e 's/.o$//' -e 's/_x$//'`
41063                 echo "    Add ${oo} ..."
41064                 cat >> $OVERLAYSC << ENDX
41065         { "${oo}", ${oo}_initialize },
41066 ENDX
41067         done
41068 fi
41069
41070         cat >> $OVERLAYSC << ENDX
41071         { NULL, NULL },
41072 };
41073
41074 /* end of generated file */
41075 ENDX
41076
41077 if test "${ol_cv_mkdep}" = no; then
41078         echo '(Do not "make depend"; we do not know how to build dependencies)'
41079 else
41080         echo 'Please run "make depend" to build dependencies'
41081 fi
41082  ;;
41083   esac
41084 done
41085 _ACEOF
41086
41087 cat >>$CONFIG_STATUS <<\_ACEOF
41088
41089 { (exit 0); exit 0; }
41090 _ACEOF
41091 chmod +x $CONFIG_STATUS
41092 ac_clean_files=$ac_clean_files_save
41093
41094
41095 # configure is writing to config.log, and then calls config.status.
41096 # config.status does its own redirection, appending to config.log.
41097 # Unfortunately, on DOS this fails, as config.log is still kept open
41098 # by configure, so config.status won't be able to write to it; its
41099 # output is simply discarded.  So we exec the FD to /dev/null,
41100 # effectively closing config.log, so it can be properly (re)opened and
41101 # appended to by config.status.  When coming back to configure, we
41102 # need to make the FD available again.
41103 if test "$no_create" != yes; then
41104   ac_cs_success=:
41105   ac_config_status_args=
41106   test "$silent" = yes &&
41107     ac_config_status_args="$ac_config_status_args --quiet"
41108   exec 5>/dev/null
41109   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
41110   exec 5>>config.log
41111   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
41112   # would make configure fail if this is the last instruction.
41113   $ac_cs_success || { (exit 1); exit 1; }
41114 fi
41115