]> git.sur5r.net Git - openldap/blob - configure
3c18203401ef5586a8a08a0ff4bc46add0ec9181
[openldap] / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.57.
4 #
5 # Copyright 1998-2003 The OpenLDAP Foundation. All Rights Reserved.
6 #
7 # Redistribution and use in source and binary forms, with or without
8 # modification, are permitted only as authorized by the OpenLDAP
9 # Public License.  A copy of this license is available at
10 # http://www.OpenLDAP.org/license.html or in file LICENSE in the
11 # top-level directory of the distribution.
12 #
13 #
14 # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
15 # Free Software Foundation, Inc.
16 # This configure script is free software; the Free Software Foundation
17 # gives unlimited permission to copy, distribute and modify it.
18 ## --------------------- ##
19 ## M4sh Initialization.  ##
20 ## --------------------- ##
21
22 # Be Bourne compatible
23 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
24   emulate sh
25   NULLCMD=:
26   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
27   # is contrary to our usage.  Disable this feature.
28   alias -g '${1+"$@"}'='"$@"'
29 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
30   set -o posix
31 fi
32
33 # Support unset when possible.
34 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
35   as_unset=unset
36 else
37   as_unset=false
38 fi
39
40
41 # Work around bugs in pre-3.0 UWIN ksh.
42 $as_unset ENV MAIL MAILPATH
43 PS1='$ '
44 PS2='> '
45 PS4='+ '
46
47 # NLS nuisances.
48 for as_var in \
49   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
50   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
51   LC_TELEPHONE LC_TIME
52 do
53   if (set +x; test -n "`(eval $as_var=C; export $as_var) 2>&1`"); then
54     eval $as_var=C; export $as_var
55   else
56     $as_unset $as_var
57   fi
58 done
59
60 # Required to use basename.
61 if expr a : '\(a\)' >/dev/null 2>&1; then
62   as_expr=expr
63 else
64   as_expr=false
65 fi
66
67 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
68   as_basename=basename
69 else
70   as_basename=false
71 fi
72
73
74 # Name of the executable.
75 as_me=`$as_basename "$0" ||
76 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
77          X"$0" : 'X\(//\)$' \| \
78          X"$0" : 'X\(/\)$' \| \
79          .     : '\(.\)' 2>/dev/null ||
80 echo X/"$0" |
81     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
82           /^X\/\(\/\/\)$/{ s//\1/; q; }
83           /^X\/\(\/\).*/{ s//\1/; q; }
84           s/.*/./; q'`
85
86
87 # PATH needs CR, and LINENO needs CR and PATH.
88 # Avoid depending upon Character Ranges.
89 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
90 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
91 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
92 as_cr_digits='0123456789'
93 as_cr_alnum=$as_cr_Letters$as_cr_digits
94
95 # The user is always right.
96 if test "${PATH_SEPARATOR+set}" != set; then
97   echo "#! /bin/sh" >conf$$.sh
98   echo  "exit 0"   >>conf$$.sh
99   chmod +x conf$$.sh
100   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
101     PATH_SEPARATOR=';'
102   else
103     PATH_SEPARATOR=:
104   fi
105   rm -f conf$$.sh
106 fi
107
108
109   as_lineno_1=$LINENO
110   as_lineno_2=$LINENO
111   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
112   test "x$as_lineno_1" != "x$as_lineno_2" &&
113   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
114   # Find who we are.  Look in the path if we contain no path at all
115   # relative or not.
116   case $0 in
117     *[\\/]* ) as_myself=$0 ;;
118     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
119 for as_dir in $PATH
120 do
121   IFS=$as_save_IFS
122   test -z "$as_dir" && as_dir=.
123   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
124 done
125
126        ;;
127   esac
128   # We did not find ourselves, most probably we were run as `sh COMMAND'
129   # in which case we are not to be found in the path.
130   if test "x$as_myself" = x; then
131     as_myself=$0
132   fi
133   if test ! -f "$as_myself"; then
134     { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
135    { (exit 1); exit 1; }; }
136   fi
137   case $CONFIG_SHELL in
138   '')
139     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
140 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
141 do
142   IFS=$as_save_IFS
143   test -z "$as_dir" && as_dir=.
144   for as_base in sh bash ksh sh5; do
145          case $as_dir in
146          /*)
147            if ("$as_dir/$as_base" -c '
148   as_lineno_1=$LINENO
149   as_lineno_2=$LINENO
150   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
151   test "x$as_lineno_1" != "x$as_lineno_2" &&
152   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
153              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
154              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
155              CONFIG_SHELL=$as_dir/$as_base
156              export CONFIG_SHELL
157              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
158            fi;;
159          esac
160        done
161 done
162 ;;
163   esac
164
165   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
166   # uniformly replaced by the line number.  The first 'sed' inserts a
167   # line-number line before each line; the second 'sed' does the real
168   # work.  The second script uses 'N' to pair each line-number line
169   # with the numbered line, and appends trailing '-' during
170   # substitution so that $LINENO is not a special case at line end.
171   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
172   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
173   sed '=' <$as_myself |
174     sed '
175       N
176       s,$,-,
177       : loop
178       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
179       t loop
180       s,-$,,
181       s,^['$as_cr_digits']*\n,,
182     ' >$as_me.lineno &&
183   chmod +x $as_me.lineno ||
184     { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
185    { (exit 1); exit 1; }; }
186
187   # Don't try to exec as it changes $[0], causing all sort of problems
188   # (the dirname of $[0] is not the place where we might find the
189   # original and so on.  Autoconf is especially sensible to this).
190   . ./$as_me.lineno
191   # Exit status is that of the last command.
192   exit
193 }
194
195
196 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
197   *c*,-n*) ECHO_N= ECHO_C='
198 ' ECHO_T='      ' ;;
199   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
200   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
201 esac
202
203 if expr a : '\(a\)' >/dev/null 2>&1; then
204   as_expr=expr
205 else
206   as_expr=false
207 fi
208
209 rm -f conf$$ conf$$.exe conf$$.file
210 echo >conf$$.file
211 if ln -s conf$$.file conf$$ 2>/dev/null; then
212   # We could just check for DJGPP; but this test a) works b) is more generic
213   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
214   if test -f conf$$.exe; then
215     # Don't use ln at all; we don't have any links
216     as_ln_s='cp -p'
217   else
218     as_ln_s='ln -s'
219   fi
220 elif ln conf$$.file conf$$ 2>/dev/null; then
221   as_ln_s=ln
222 else
223   as_ln_s='cp -p'
224 fi
225 rm -f conf$$ conf$$.exe conf$$.file
226
227 if mkdir -p . 2>/dev/null; then
228   as_mkdir_p=:
229 else
230   as_mkdir_p=false
231 fi
232
233 as_executable_p="test -f"
234
235 # Sed expression to map a string onto a valid CPP name.
236 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
237
238 # Sed expression to map a string onto a valid variable name.
239 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
240
241
242 # IFS
243 # We need space, tab and new line, in precisely that order.
244 as_nl='
245 '
246 IFS="   $as_nl"
247
248 # CDPATH.
249 $as_unset CDPATH
250
251
252 # Find the correct PATH separator.  Usually this is `:', but
253 # DJGPP uses `;' like DOS.
254 if test "X${PATH_SEPARATOR+set}" != Xset; then
255   UNAME=${UNAME-`uname 2>/dev/null`}
256   case X$UNAME in
257     *-DOS) lt_cv_sys_path_separator=';' ;;
258     *)     lt_cv_sys_path_separator=':' ;;
259   esac
260   PATH_SEPARATOR=$lt_cv_sys_path_separator
261 fi
262
263
264 # Check that we are running under the correct shell.
265 SHELL=${CONFIG_SHELL-/bin/sh}
266
267 case X$ECHO in
268 X*--fallback-echo)
269   # Remove one level of quotation (which was required for Make).
270   ECHO=`echo "$ECHO" | sed 's,\\\\\$\\$0,'$0','`
271   ;;
272 esac
273
274 echo=${ECHO-echo}
275 if test "X$1" = X--no-reexec; then
276   # Discard the --no-reexec flag, and continue.
277   shift
278 elif test "X$1" = X--fallback-echo; then
279   # Avoid inline document here, it may be left over
280   :
281 elif test "X`($echo '\t') 2>/dev/null`" = 'X\t'; then
282   # Yippee, $echo works!
283   :
284 else
285   # Restart under the correct shell.
286   exec $SHELL "$0" --no-reexec ${1+"$@"}
287 fi
288
289 if test "X$1" = X--fallback-echo; then
290   # used as fallback echo
291   shift
292   cat <<EOF
293
294 EOF
295   exit 0
296 fi
297
298 # The HP-UX ksh and POSIX shell print the target directory to stdout
299 # if CDPATH is set.
300 if test "X${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
301
302 if test -z "$ECHO"; then
303 if test "X${echo_test_string+set}" != Xset; then
304 # find a string as large as possible, as long as the shell can cope with it
305   for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do
306     # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
307     if (echo_test_string="`eval $cmd`") 2>/dev/null &&
308        echo_test_string="`eval $cmd`" &&
309        (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
310     then
311       break
312     fi
313   done
314 fi
315
316 if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
317    echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
318    test "X$echo_testing_string" = "X$echo_test_string"; then
319   :
320 else
321   # The Solaris, AIX, and Digital Unix default echo programs unquote
322   # backslashes.  This makes it impossible to quote backslashes using
323   #   echo "$something" | sed 's/\\/\\\\/g'
324   #
325   # So, first we look for a working echo in the user's PATH.
326
327   IFS="${IFS=   }"; save_ifs="$IFS"; IFS=$PATH_SEPARATOR
328   for dir in $PATH /usr/ucb; do
329     if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
330        test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
331        echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
332        test "X$echo_testing_string" = "X$echo_test_string"; then
333       echo="$dir/echo"
334       break
335     fi
336   done
337   IFS="$save_ifs"
338
339   if test "X$echo" = Xecho; then
340     # We didn't find a better echo, so look for alternatives.
341     if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
342        echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
343        test "X$echo_testing_string" = "X$echo_test_string"; then
344       # This shell has a builtin print -r that does the trick.
345       echo='print -r'
346     elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
347          test "X$CONFIG_SHELL" != X/bin/ksh; then
348       # If we have ksh, try running configure again with it.
349       ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
350       export ORIGINAL_CONFIG_SHELL
351       CONFIG_SHELL=/bin/ksh
352       export CONFIG_SHELL
353       exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"}
354     else
355       # Try using printf.
356       echo='printf %s\n'
357       if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
358          echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
359          test "X$echo_testing_string" = "X$echo_test_string"; then
360         # Cool, printf works
361         :
362       elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
363            test "X$echo_testing_string" = 'X\t' &&
364            echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
365            test "X$echo_testing_string" = "X$echo_test_string"; then
366         CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
367         export CONFIG_SHELL
368         SHELL="$CONFIG_SHELL"
369         export SHELL
370         echo="$CONFIG_SHELL $0 --fallback-echo"
371       elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
372            test "X$echo_testing_string" = 'X\t' &&
373            echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
374            test "X$echo_testing_string" = "X$echo_test_string"; then
375         echo="$CONFIG_SHELL $0 --fallback-echo"
376       else
377         # maybe with a smaller string...
378         prev=:
379
380         for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do
381           if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
382           then
383             break
384           fi
385           prev="$cmd"
386         done
387
388         if test "$prev" != 'sed 50q "$0"'; then
389           echo_test_string=`eval $prev`
390           export echo_test_string
391           exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"}
392         else
393           # Oops.  We lost completely, so just stick with echo.
394           echo=echo
395         fi
396       fi
397     fi
398   fi
399 fi
400 fi
401
402 # Copy echo and quote the copy suitably for passing to libtool from
403 # the Makefile, instead of quoting the original, which is used later.
404 ECHO=$echo
405 if test "X$ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then
406    ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo"
407 fi
408
409
410
411 # Name of the host.
412 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
413 # so uname gets run too.
414 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
415
416 exec 6>&1
417
418 #
419 # Initializations.
420 #
421 ac_default_prefix=/usr/local
422 ac_config_libobj_dir=.
423 cross_compiling=no
424 subdirs=
425 MFLAGS=
426 MAKEFLAGS=
427 SHELL=${CONFIG_SHELL-/bin/sh}
428
429 # Maximum number of lines to put in a shell here document.
430 # This variable seems obsolete.  It should probably be removed, and
431 # only ac_max_sed_lines should be used.
432 : ${ac_max_here_lines=38}
433
434 # Identity of this package.
435 PACKAGE_NAME=
436 PACKAGE_TARNAME=
437 PACKAGE_VERSION=
438 PACKAGE_STRING=
439 PACKAGE_BUGREPORT=
440
441 ac_unique_file="OpenLDAP"
442 ac_unique_file="include/ldap.h"
443 ac_default_prefix=/usr/local
444 # Factoring default headers for most tests.
445 ac_includes_default="\
446 #include <stdio.h>
447 #if HAVE_SYS_TYPES_H
448 # include <sys/types.h>
449 #endif
450 #if HAVE_SYS_STAT_H
451 # include <sys/stat.h>
452 #endif
453 #if STDC_HEADERS
454 # include <stdlib.h>
455 # include <stddef.h>
456 #else
457 # if HAVE_STDLIB_H
458 #  include <stdlib.h>
459 # endif
460 #endif
461 #if HAVE_STRING_H
462 # if !STDC_HEADERS && HAVE_MEMORY_H
463 #  include <memory.h>
464 # endif
465 # include <string.h>
466 #endif
467 #if HAVE_STRINGS_H
468 # include <strings.h>
469 #endif
470 #if HAVE_INTTYPES_H
471 # include <inttypes.h>
472 #else
473 # if HAVE_STDINT_H
474 #  include <stdint.h>
475 # endif
476 #endif
477 #if HAVE_UNISTD_H
478 # include <unistd.h>
479 #endif"
480
481 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 SHTOOL build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os OPENLDAP_PACKAGE OPENLDAP_VERSION OPENLDAP_LIBVERSION OPENLDAP_RELEASE_DATE top_builddir ldap_subdir SET_MAKE INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CC AR CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT LN_S ECHO RANLIB ac_ct_RANLIB STRIP ac_ct_STRIP CPP EGREP LIBTOOL LN_H PERLBIN OL_MKDEP OL_MKDEP_FLAGS LTSTATIC LIBOBJS LIBSRCS PLAT BUILD_LIBS_DYNAMIC BUILD_SLAPD BUILD_SLAPI SLAPD_SLAPI_DEPEND BUILD_BDB BUILD_DNSSRV BUILD_LDAP BUILD_LDBM BUILD_META BUILD_MONITOR BUILD_NULL BUILD_PASSWD BUILD_PERL BUILD_SHELL BUILD_SQL BUILD_TCL BUILD_BDB_DYNAMIC BUILD_DNSSRV_DYNAMIC BUILD_LDAP_DYNAMIC BUILD_LDBM_DYNAMIC BUILD_META_DYNAMIC BUILD_MONITOR_DYNAMIC BUILD_NULL_DYNAMIC BUILD_PASSWD_DYNAMIC BUILD_PERL_DYNAMIC BUILD_SHELL_DYNAMIC BUILD_SQL_DYNAMIC BUILD_TCL_DYNAMIC BUILD_SLURPD LDAP_LIBS LDIF_LIBS SLAPD_LIBS SLURPD_LIBS LDBM_LIBS LTHREAD_LIBS LUTIL_LIBS WRAP_LIBS MOD_TCL_LIB SLAPD_MODULES_CPPFLAGS SLAPD_MODULES_LDFLAGS SLAPD_NO_STATIC SLAPD_STATIC_BACKENDS SLAPD_DYNAMIC_BACKENDS PERL_CPPFLAGS SLAPD_PERL_LDFLAGS MOD_PERL_LDFLAGS KRB4_LIBS KRB5_LIBS READLINE_LIBS SASL_LIBS TERMCAP_LIBS TLS_LIBS MODULES_LIBS SLAPI_LIBS LIBSLAPI LIBSLAPITOOLS AUTH_LIBS SLAPD_SLP_LIBS SLAPD_SQL_LDFLAGS SLAPD_SQL_LIBS SLAPD_SQL_INCLUDES LTLIBOBJS'
482 ac_subst_files=''
483
484 # Initialize some variables set by options.
485 ac_init_help=
486 ac_init_version=false
487 # The variables have the same names as the options, with
488 # dashes changed to underlines.
489 cache_file=/dev/null
490 exec_prefix=NONE
491 no_create=
492 no_recursion=
493 prefix=NONE
494 program_prefix=NONE
495 program_suffix=NONE
496 program_transform_name=s,x,x,
497 silent=
498 site=
499 srcdir=
500 verbose=
501 x_includes=NONE
502 x_libraries=NONE
503
504 # Installation directory options.
505 # These are left unexpanded so users can "make install exec_prefix=/foo"
506 # and all the variables that are supposed to be based on exec_prefix
507 # by default will actually change.
508 # Use braces instead of parens because sh, perl, etc. also accept them.
509 bindir='${exec_prefix}/bin'
510 sbindir='${exec_prefix}/sbin'
511 libexecdir='${exec_prefix}/libexec'
512 datadir='${prefix}/share'
513 sysconfdir='${prefix}/etc'
514 sharedstatedir='${prefix}/com'
515 localstatedir='${prefix}/var'
516 libdir='${exec_prefix}/lib'
517 includedir='${prefix}/include'
518 oldincludedir='/usr/include'
519 infodir='${prefix}/info'
520 mandir='${prefix}/man'
521
522 ac_prev=
523 for ac_option
524 do
525   # If the previous option needs an argument, assign it.
526   if test -n "$ac_prev"; then
527     eval "$ac_prev=\$ac_option"
528     ac_prev=
529     continue
530   fi
531
532   ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
533
534   # Accept the important Cygnus configure options, so we can diagnose typos.
535
536   case $ac_option in
537
538   -bindir | --bindir | --bindi | --bind | --bin | --bi)
539     ac_prev=bindir ;;
540   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
541     bindir=$ac_optarg ;;
542
543   -build | --build | --buil | --bui | --bu)
544     ac_prev=build_alias ;;
545   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
546     build_alias=$ac_optarg ;;
547
548   -cache-file | --cache-file | --cache-fil | --cache-fi \
549   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
550     ac_prev=cache_file ;;
551   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
552   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
553     cache_file=$ac_optarg ;;
554
555   --config-cache | -C)
556     cache_file=config.cache ;;
557
558   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
559     ac_prev=datadir ;;
560   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
561   | --da=*)
562     datadir=$ac_optarg ;;
563
564   -disable-* | --disable-*)
565     ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
566     # Reject names that are not valid shell variable names.
567     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
568       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
569    { (exit 1); exit 1; }; }
570     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
571     eval "enable_$ac_feature=no" ;;
572
573   -enable-* | --enable-*)
574     ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
575     # Reject names that are not valid shell variable names.
576     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
577       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
578    { (exit 1); exit 1; }; }
579     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
580     case $ac_option in
581       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
582       *) ac_optarg=yes ;;
583     esac
584     eval "enable_$ac_feature='$ac_optarg'" ;;
585
586   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
587   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
588   | --exec | --exe | --ex)
589     ac_prev=exec_prefix ;;
590   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
591   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
592   | --exec=* | --exe=* | --ex=*)
593     exec_prefix=$ac_optarg ;;
594
595   -gas | --gas | --ga | --g)
596     # Obsolete; use --with-gas.
597     with_gas=yes ;;
598
599   -help | --help | --hel | --he | -h)
600     ac_init_help=long ;;
601   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
602     ac_init_help=recursive ;;
603   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
604     ac_init_help=short ;;
605
606   -host | --host | --hos | --ho)
607     ac_prev=host_alias ;;
608   -host=* | --host=* | --hos=* | --ho=*)
609     host_alias=$ac_optarg ;;
610
611   -includedir | --includedir | --includedi | --included | --include \
612   | --includ | --inclu | --incl | --inc)
613     ac_prev=includedir ;;
614   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
615   | --includ=* | --inclu=* | --incl=* | --inc=*)
616     includedir=$ac_optarg ;;
617
618   -infodir | --infodir | --infodi | --infod | --info | --inf)
619     ac_prev=infodir ;;
620   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
621     infodir=$ac_optarg ;;
622
623   -libdir | --libdir | --libdi | --libd)
624     ac_prev=libdir ;;
625   -libdir=* | --libdir=* | --libdi=* | --libd=*)
626     libdir=$ac_optarg ;;
627
628   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
629   | --libexe | --libex | --libe)
630     ac_prev=libexecdir ;;
631   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
632   | --libexe=* | --libex=* | --libe=*)
633     libexecdir=$ac_optarg ;;
634
635   -localstatedir | --localstatedir | --localstatedi | --localstated \
636   | --localstate | --localstat | --localsta | --localst \
637   | --locals | --local | --loca | --loc | --lo)
638     ac_prev=localstatedir ;;
639   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
640   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
641   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
642     localstatedir=$ac_optarg ;;
643
644   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
645     ac_prev=mandir ;;
646   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
647     mandir=$ac_optarg ;;
648
649   -nfp | --nfp | --nf)
650     # Obsolete; use --without-fp.
651     with_fp=no ;;
652
653   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
654   | --no-cr | --no-c | -n)
655     no_create=yes ;;
656
657   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
658   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
659     no_recursion=yes ;;
660
661   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
662   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
663   | --oldin | --oldi | --old | --ol | --o)
664     ac_prev=oldincludedir ;;
665   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
666   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
667   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
668     oldincludedir=$ac_optarg ;;
669
670   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
671     ac_prev=prefix ;;
672   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
673     prefix=$ac_optarg ;;
674
675   -program-prefix | --program-prefix | --program-prefi | --program-pref \
676   | --program-pre | --program-pr | --program-p)
677     ac_prev=program_prefix ;;
678   -program-prefix=* | --program-prefix=* | --program-prefi=* \
679   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
680     program_prefix=$ac_optarg ;;
681
682   -program-suffix | --program-suffix | --program-suffi | --program-suff \
683   | --program-suf | --program-su | --program-s)
684     ac_prev=program_suffix ;;
685   -program-suffix=* | --program-suffix=* | --program-suffi=* \
686   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
687     program_suffix=$ac_optarg ;;
688
689   -program-transform-name | --program-transform-name \
690   | --program-transform-nam | --program-transform-na \
691   | --program-transform-n | --program-transform- \
692   | --program-transform | --program-transfor \
693   | --program-transfo | --program-transf \
694   | --program-trans | --program-tran \
695   | --progr-tra | --program-tr | --program-t)
696     ac_prev=program_transform_name ;;
697   -program-transform-name=* | --program-transform-name=* \
698   | --program-transform-nam=* | --program-transform-na=* \
699   | --program-transform-n=* | --program-transform-=* \
700   | --program-transform=* | --program-transfor=* \
701   | --program-transfo=* | --program-transf=* \
702   | --program-trans=* | --program-tran=* \
703   | --progr-tra=* | --program-tr=* | --program-t=*)
704     program_transform_name=$ac_optarg ;;
705
706   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
707   | -silent | --silent | --silen | --sile | --sil)
708     silent=yes ;;
709
710   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
711     ac_prev=sbindir ;;
712   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
713   | --sbi=* | --sb=*)
714     sbindir=$ac_optarg ;;
715
716   -sharedstatedir | --sharedstatedir | --sharedstatedi \
717   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
718   | --sharedst | --shareds | --shared | --share | --shar \
719   | --sha | --sh)
720     ac_prev=sharedstatedir ;;
721   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
722   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
723   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
724   | --sha=* | --sh=*)
725     sharedstatedir=$ac_optarg ;;
726
727   -site | --site | --sit)
728     ac_prev=site ;;
729   -site=* | --site=* | --sit=*)
730     site=$ac_optarg ;;
731
732   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
733     ac_prev=srcdir ;;
734   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
735     srcdir=$ac_optarg ;;
736
737   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
738   | --syscon | --sysco | --sysc | --sys | --sy)
739     ac_prev=sysconfdir ;;
740   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
741   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
742     sysconfdir=$ac_optarg ;;
743
744   -target | --target | --targe | --targ | --tar | --ta | --t)
745     ac_prev=target_alias ;;
746   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
747     target_alias=$ac_optarg ;;
748
749   -v | -verbose | --verbose | --verbos | --verbo | --verb)
750     verbose=yes ;;
751
752   -version | --version | --versio | --versi | --vers | -V)
753     ac_init_version=: ;;
754
755   -with-* | --with-*)
756     ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
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     case $ac_option in
763       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
764       *) ac_optarg=yes ;;
765     esac
766     eval "with_$ac_package='$ac_optarg'" ;;
767
768   -without-* | --without-*)
769     ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
770     # Reject names that are not valid shell variable names.
771     expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
772       { echo "$as_me: error: invalid package name: $ac_package" >&2
773    { (exit 1); exit 1; }; }
774     ac_package=`echo $ac_package | sed 's/-/_/g'`
775     eval "with_$ac_package=no" ;;
776
777   --x)
778     # Obsolete; use --with-x.
779     with_x=yes ;;
780
781   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
782   | --x-incl | --x-inc | --x-in | --x-i)
783     ac_prev=x_includes ;;
784   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
785   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
786     x_includes=$ac_optarg ;;
787
788   -x-libraries | --x-libraries | --x-librarie | --x-librari \
789   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
790     ac_prev=x_libraries ;;
791   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
792   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
793     x_libraries=$ac_optarg ;;
794
795   -*) { echo "$as_me: error: unrecognized option: $ac_option
796 Try \`$0 --help' for more information." >&2
797    { (exit 1); exit 1; }; }
798     ;;
799
800   *=*)
801     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
802     # Reject names that are not valid shell variable names.
803     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
804       { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
805    { (exit 1); exit 1; }; }
806     ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
807     eval "$ac_envvar='$ac_optarg'"
808     export $ac_envvar ;;
809
810   *)
811     # FIXME: should be removed in autoconf 3.0.
812     echo "$as_me: WARNING: you should use --build, --host, --target" >&2
813     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
814       echo "$as_me: WARNING: invalid host type: $ac_option" >&2
815     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
816     ;;
817
818   esac
819 done
820
821 if test -n "$ac_prev"; then
822   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
823   { echo "$as_me: error: missing argument to $ac_option" >&2
824    { (exit 1); exit 1; }; }
825 fi
826
827 # Be sure to have absolute paths.
828 for ac_var in exec_prefix prefix
829 do
830   eval ac_val=$`echo $ac_var`
831   case $ac_val in
832     [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
833     *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
834    { (exit 1); exit 1; }; };;
835   esac
836 done
837
838 # Be sure to have absolute paths.
839 for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
840               localstatedir libdir includedir oldincludedir infodir mandir
841 do
842   eval ac_val=$`echo $ac_var`
843   case $ac_val in
844     [\\/$]* | ?:[\\/]* ) ;;
845     *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
846    { (exit 1); exit 1; }; };;
847   esac
848 done
849
850 # There might be people who depend on the old broken behavior: `$host'
851 # used to hold the argument of --host etc.
852 # FIXME: To remove some day.
853 build=$build_alias
854 host=$host_alias
855 target=$target_alias
856
857 # FIXME: To remove some day.
858 if test "x$host_alias" != x; then
859   if test "x$build_alias" = x; then
860     cross_compiling=maybe
861     echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
862     If a cross compiler is detected then cross compile mode will be used." >&2
863   elif test "x$build_alias" != "x$host_alias"; then
864     cross_compiling=yes
865   fi
866 fi
867
868 ac_tool_prefix=
869 test -n "$host_alias" && ac_tool_prefix=$host_alias-
870
871 test "$silent" = yes && exec 6>/dev/null
872
873
874 # Find the source files, if location was not specified.
875 if test -z "$srcdir"; then
876   ac_srcdir_defaulted=yes
877   # Try the directory containing this script, then its parent.
878   ac_confdir=`(dirname "$0") 2>/dev/null ||
879 $as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
880          X"$0" : 'X\(//\)[^/]' \| \
881          X"$0" : 'X\(//\)$' \| \
882          X"$0" : 'X\(/\)' \| \
883          .     : '\(.\)' 2>/dev/null ||
884 echo X"$0" |
885     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
886           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
887           /^X\(\/\/\)$/{ s//\1/; q; }
888           /^X\(\/\).*/{ s//\1/; q; }
889           s/.*/./; q'`
890   srcdir=$ac_confdir
891   if test ! -r $srcdir/$ac_unique_file; then
892     srcdir=..
893   fi
894 else
895   ac_srcdir_defaulted=no
896 fi
897 if test ! -r $srcdir/$ac_unique_file; then
898   if test "$ac_srcdir_defaulted" = yes; then
899     { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
900    { (exit 1); exit 1; }; }
901   else
902     { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
903    { (exit 1); exit 1; }; }
904   fi
905 fi
906 (cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
907   { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
908    { (exit 1); exit 1; }; }
909 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
910 ac_env_build_alias_set=${build_alias+set}
911 ac_env_build_alias_value=$build_alias
912 ac_cv_env_build_alias_set=${build_alias+set}
913 ac_cv_env_build_alias_value=$build_alias
914 ac_env_host_alias_set=${host_alias+set}
915 ac_env_host_alias_value=$host_alias
916 ac_cv_env_host_alias_set=${host_alias+set}
917 ac_cv_env_host_alias_value=$host_alias
918 ac_env_target_alias_set=${target_alias+set}
919 ac_env_target_alias_value=$target_alias
920 ac_cv_env_target_alias_set=${target_alias+set}
921 ac_cv_env_target_alias_value=$target_alias
922 ac_env_CC_set=${CC+set}
923 ac_env_CC_value=$CC
924 ac_cv_env_CC_set=${CC+set}
925 ac_cv_env_CC_value=$CC
926 ac_env_CFLAGS_set=${CFLAGS+set}
927 ac_env_CFLAGS_value=$CFLAGS
928 ac_cv_env_CFLAGS_set=${CFLAGS+set}
929 ac_cv_env_CFLAGS_value=$CFLAGS
930 ac_env_LDFLAGS_set=${LDFLAGS+set}
931 ac_env_LDFLAGS_value=$LDFLAGS
932 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
933 ac_cv_env_LDFLAGS_value=$LDFLAGS
934 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
935 ac_env_CPPFLAGS_value=$CPPFLAGS
936 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
937 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
938 ac_env_CPP_set=${CPP+set}
939 ac_env_CPP_value=$CPP
940 ac_cv_env_CPP_set=${CPP+set}
941 ac_cv_env_CPP_value=$CPP
942
943 #
944 # Report the --help message.
945 #
946 if test "$ac_init_help" = "long"; then
947   # Omit some internal or obsolete options to make the list less imposing.
948   # This message is too long to be a string in the A/UX 3.1 sh.
949   cat <<_ACEOF
950 \`configure' configures this package to adapt to many kinds of systems.
951
952 Usage: $0 [OPTION]... [VAR=VALUE]...
953
954 To assign environment variables (e.g., CC, CFLAGS...), specify them as
955 VAR=VALUE.  See below for descriptions of some of the useful variables.
956
957 Defaults for the options are specified in brackets.
958
959 Configuration:
960   -h, --help              display this help and exit
961       --help=short        display options specific to this package
962       --help=recursive    display the short help of all the included packages
963   -V, --version           display version information and exit
964   -q, --quiet, --silent   do not print \`checking...' messages
965       --cache-file=FILE   cache test results in FILE [disabled]
966   -C, --config-cache      alias for \`--cache-file=config.cache'
967   -n, --no-create         do not create output files
968       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
969
970 _ACEOF
971
972   cat <<_ACEOF
973 Installation directories:
974   --prefix=PREFIX         install architecture-independent files in PREFIX
975                           [$ac_default_prefix]
976   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
977                           [PREFIX]
978
979 By default, \`make install' will install all the files in
980 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
981 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
982 for instance \`--prefix=\$HOME'.
983
984 For better control, use the options below.
985
986 Fine tuning of the installation directories:
987   --bindir=DIR           user executables [EPREFIX/bin]
988   --sbindir=DIR          system admin executables [EPREFIX/sbin]
989   --libexecdir=DIR       program executables [EPREFIX/libexec]
990   --datadir=DIR          read-only architecture-independent data [PREFIX/share]
991   --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
992   --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
993   --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
994   --libdir=DIR           object code libraries [EPREFIX/lib]
995   --includedir=DIR       C header files [PREFIX/include]
996   --oldincludedir=DIR    C header files for non-gcc [/usr/include]
997   --infodir=DIR          info documentation [PREFIX/info]
998   --mandir=DIR           man documentation [PREFIX/man]
999 _ACEOF
1000
1001   cat <<\_ACEOF
1002
1003 System types:
1004   --build=BUILD     configure for building on BUILD [guessed]
1005   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1006   --target=TARGET   configure for building compilers for TARGET [HOST]
1007 _ACEOF
1008 fi
1009
1010 if test -n "$ac_init_help"; then
1011
1012   cat <<\_ACEOF
1013
1014 Optional Features:
1015   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1016   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1017   --enable-debug          enable debugging yes
1018   --enable-dynamic        enable linking built binaries with dynamic libs no
1019   --enable-syslog         enable syslog support auto
1020   --enable-proctitle      enable proctitle support yes
1021   --enable-ipv6           enable IPv6 support auto
1022   --enable-local          enable AF_LOCAL (AF_UNIX) socket support auto
1023   --enable-x-compile      enable cross compiling no
1024   --enable-slapd          enable building slapd yes
1025     --enable-aci          enable per-object ACIs (experimental) no
1026     --enable-cleartext    enable cleartext passwords yes
1027     --enable-crypt        enable crypt(3) passwords no
1028     --enable-kpasswd      enable Kerberos password verification no
1029     --enable-lmpasswd     enable LAN Manager passwords no
1030     --enable-spasswd      enable (Cyrus) SASL password verification no
1031     --enable-modules      enable dynamic module support no
1032     --enable-phonetic     enable phonetic/soundex no
1033     --enable-rewrite      enable DN rewriting in back-ldap and back-meta no
1034     --enable-rlookups     enable reverse lookups of client hostnames no
1035     --enable-slapi        enable installation of slapi library no
1036     --enable-slp          enable SLPv2 support no
1037     --enable-wrappers     enable tcp wrapper support no
1038     --enable-bdb          enable Berkeley DB backend yes
1039     --enable-dnssrv       enable dnssrv backend no
1040     --enable-ldap         enable ldap backend no
1041     --enable-ldbm         enable ldbm backend no
1042     --enable-meta         enable metadirectory backend no
1043     --enable-monitor      enable monitor backend no
1044     --enable-null         enable null backend no
1045     --enable-passwd       enable passwd backend no
1046     --enable-perl         enable perl backend no
1047     --enable-shell        enable shell backend no
1048     --enable-sql          enable sql backend no
1049     --enable-tcl          enable tcl backend no
1050   --enable-slurpd         enable building slurpd auto
1051   --enable-static=PKGS  build static libraries default=yes
1052   --enable-shared=PKGS  build shared libraries default=yes
1053   --enable-fast-install=PKGS  optimize for fast installation default=yes
1054   --disable-libtool-lock  avoid locking (might break parallel builds)
1055
1056 Optional Packages:
1057   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1058   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1059   --with-subdir=DIR       change default subdirectory used for installs
1060   --with-cyrus-sasl       with Cyrus SASL support auto
1061   --with-fetch            with fetch(3) URL support auto
1062   --with-kerberos         with Kerberos support auto
1063   --with-readline         with readline support auto
1064   --with-threads          with threads auto
1065   --with-tls              with TLS/SSL support auto
1066   --with-yielding-select  with implicitly yielding select auto
1067
1068 SLAPD (Standalone LDAP Daemon) Options:
1069     --with-bdb-module     module type static|dynamic static
1070     --with-dnssrv-module  module type static|dynamic static
1071     --with-ldap-module    module type static|dynamic static
1072     --with-ldbm-api       with LDBM API auto|berkeley|bcompat|mdbm|gdbm auto
1073     --with-ldbm-module    module type static|dynamic static
1074     --with-ldbm-type      use LDBM type auto|btree|hash auto
1075     --with-meta-module    module type static|dynamic static
1076     --with-monitor-module module type static|dynamic static
1077     --with-null-module    module type static|dynamic static
1078     --with-passwd-module  module type static|dynamic static
1079     --with-perl-module    module type static|dynamic static
1080     --with-shell-module   module type static|dynamic static
1081     --with-sql-module     module type static|dynamic static
1082     --with-tcl-module     module type static|dynamic static
1083
1084 SLURPD (Replication Daemon) Options:
1085
1086 Library Generation & Linking Options
1087   --with-gnu-ld           assume the C compiler uses GNU ld default=no
1088   --with-pic              try to use only PIC/non-PIC objects default=use both
1089
1090 See INSTALL file for further details.
1091
1092 Some influential environment variables:
1093   CC          C compiler command
1094   CFLAGS      C compiler flags
1095   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1096               nonstandard directory <lib dir>
1097   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
1098               headers in a nonstandard directory <include dir>
1099   CPP         C preprocessor
1100
1101 Use these variables to override the choices made by `configure' or to help
1102 it to find libraries and programs with nonstandard names/locations.
1103
1104 _ACEOF
1105 fi
1106
1107 if test "$ac_init_help" = "recursive"; then
1108   # If there are subdirs, report their specific --help.
1109   ac_popdir=`pwd`
1110   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1111     test -d $ac_dir || continue
1112     ac_builddir=.
1113
1114 if test "$ac_dir" != .; then
1115   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
1116   # A "../" for each directory in $ac_dir_suffix.
1117   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
1118 else
1119   ac_dir_suffix= ac_top_builddir=
1120 fi
1121
1122 case $srcdir in
1123   .)  # No --srcdir option.  We are building in place.
1124     ac_srcdir=.
1125     if test -z "$ac_top_builddir"; then
1126        ac_top_srcdir=.
1127     else
1128        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
1129     fi ;;
1130   [\\/]* | ?:[\\/]* )  # Absolute path.
1131     ac_srcdir=$srcdir$ac_dir_suffix;
1132     ac_top_srcdir=$srcdir ;;
1133   *) # Relative path.
1134     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
1135     ac_top_srcdir=$ac_top_builddir$srcdir ;;
1136 esac
1137 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
1138 # absolute.
1139 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
1140 ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
1141 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
1142 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
1143
1144     cd $ac_dir
1145     # Check for guested configure; otherwise get Cygnus style configure.
1146     if test -f $ac_srcdir/configure.gnu; then
1147       echo
1148       $SHELL $ac_srcdir/configure.gnu  --help=recursive
1149     elif test -f $ac_srcdir/configure; then
1150       echo
1151       $SHELL $ac_srcdir/configure  --help=recursive
1152     elif test -f $ac_srcdir/configure.ac ||
1153            test -f $ac_srcdir/configure.in; then
1154       echo
1155       $ac_configure --help
1156     else
1157       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1158     fi
1159     cd $ac_popdir
1160   done
1161 fi
1162
1163 test -n "$ac_init_help" && exit 0
1164 if $ac_init_version; then
1165   cat <<\_ACEOF
1166
1167 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
1168 Free Software Foundation, Inc.
1169 This configure script is free software; the Free Software Foundation
1170 gives unlimited permission to copy, distribute and modify it.
1171
1172 Copyright 1998-2003 The OpenLDAP Foundation. All Rights Reserved.
1173
1174 Redistribution and use in source and binary forms, with or without
1175 modification, are permitted only as authorized by the OpenLDAP
1176 Public License.  A copy of this license is available at
1177 http://www.OpenLDAP.org/license.html or in file LICENSE in the
1178 top-level directory of the distribution.
1179
1180 _ACEOF
1181   exit 0
1182 fi
1183 exec 5>config.log
1184 cat >&5 <<_ACEOF
1185 This file contains any messages produced by compilers while
1186 running configure, to aid debugging if configure makes a mistake.
1187
1188 It was created by $as_me, which was
1189 generated by GNU Autoconf 2.57.  Invocation command line was
1190
1191   $ $0 $@
1192
1193 _ACEOF
1194 {
1195 cat <<_ASUNAME
1196 ## --------- ##
1197 ## Platform. ##
1198 ## --------- ##
1199
1200 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1201 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1202 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1203 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1204 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1205
1206 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1207 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1208
1209 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1210 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1211 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1212 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
1213 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1214 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1215 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1216
1217 _ASUNAME
1218
1219 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1220 for as_dir in $PATH
1221 do
1222   IFS=$as_save_IFS
1223   test -z "$as_dir" && as_dir=.
1224   echo "PATH: $as_dir"
1225 done
1226
1227 } >&5
1228
1229 cat >&5 <<_ACEOF
1230
1231
1232 ## ----------- ##
1233 ## Core tests. ##
1234 ## ----------- ##
1235
1236 _ACEOF
1237
1238
1239 # Keep a trace of the command line.
1240 # Strip out --no-create and --no-recursion so they do not pile up.
1241 # Strip out --silent because we don't want to record it for future runs.
1242 # Also quote any args containing shell meta-characters.
1243 # Make two passes to allow for proper duplicate-argument suppression.
1244 ac_configure_args=
1245 ac_configure_args0=
1246 ac_configure_args1=
1247 ac_sep=
1248 ac_must_keep_next=false
1249 for ac_pass in 1 2
1250 do
1251   for ac_arg
1252   do
1253     case $ac_arg in
1254     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1255     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1256     | -silent | --silent | --silen | --sile | --sil)
1257       continue ;;
1258     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1259       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1260     esac
1261     case $ac_pass in
1262     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1263     2)
1264       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1265       if test $ac_must_keep_next = true; then
1266         ac_must_keep_next=false # Got value, back to normal.
1267       else
1268         case $ac_arg in
1269           *=* | --config-cache | -C | -disable-* | --disable-* \
1270           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1271           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1272           | -with-* | --with-* | -without-* | --without-* | --x)
1273             case "$ac_configure_args0 " in
1274               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1275             esac
1276             ;;
1277           -* ) ac_must_keep_next=true ;;
1278         esac
1279       fi
1280       ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1281       # Get rid of the leading space.
1282       ac_sep=" "
1283       ;;
1284     esac
1285   done
1286 done
1287 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1288 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1289
1290 # When interrupted or exit'd, cleanup temporary files, and complete
1291 # config.log.  We remove comments because anyway the quotes in there
1292 # would cause problems or look ugly.
1293 # WARNING: Be sure not to use single quotes in there, as some shells,
1294 # such as our DU 5.0 friend, will then `close' the trap.
1295 trap 'exit_status=$?
1296   # Save into config.log some information that might help in debugging.
1297   {
1298     echo
1299
1300     cat <<\_ASBOX
1301 ## ---------------- ##
1302 ## Cache variables. ##
1303 ## ---------------- ##
1304 _ASBOX
1305     echo
1306     # The following way of writing the cache mishandles newlines in values,
1307 {
1308   (set) 2>&1 |
1309     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1310     *ac_space=\ *)
1311       sed -n \
1312         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1313           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1314       ;;
1315     *)
1316       sed -n \
1317         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1318       ;;
1319     esac;
1320 }
1321     echo
1322
1323     cat <<\_ASBOX
1324 ## ----------------- ##
1325 ## Output variables. ##
1326 ## ----------------- ##
1327 _ASBOX
1328     echo
1329     for ac_var in $ac_subst_vars
1330     do
1331       eval ac_val=$`echo $ac_var`
1332       echo "$ac_var='"'"'$ac_val'"'"'"
1333     done | sort
1334     echo
1335
1336     if test -n "$ac_subst_files"; then
1337       cat <<\_ASBOX
1338 ## ------------- ##
1339 ## Output files. ##
1340 ## ------------- ##
1341 _ASBOX
1342       echo
1343       for ac_var in $ac_subst_files
1344       do
1345         eval ac_val=$`echo $ac_var`
1346         echo "$ac_var='"'"'$ac_val'"'"'"
1347       done | sort
1348       echo
1349     fi
1350
1351     if test -s confdefs.h; then
1352       cat <<\_ASBOX
1353 ## ----------- ##
1354 ## confdefs.h. ##
1355 ## ----------- ##
1356 _ASBOX
1357       echo
1358       sed "/^$/d" confdefs.h | sort
1359       echo
1360     fi
1361     test "$ac_signal" != 0 &&
1362       echo "$as_me: caught signal $ac_signal"
1363     echo "$as_me: exit $exit_status"
1364   } >&5
1365   rm -f core core.* *.core &&
1366   rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1367     exit $exit_status
1368      ' 0
1369 for ac_signal in 1 2 13 15; do
1370   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1371 done
1372 ac_signal=0
1373
1374 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1375 rm -rf conftest* confdefs.h
1376 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1377 echo >confdefs.h
1378
1379 # Predefined preprocessor variables.
1380
1381 cat >>confdefs.h <<_ACEOF
1382 #define PACKAGE_NAME "$PACKAGE_NAME"
1383 _ACEOF
1384
1385
1386 cat >>confdefs.h <<_ACEOF
1387 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1388 _ACEOF
1389
1390
1391 cat >>confdefs.h <<_ACEOF
1392 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1393 _ACEOF
1394
1395
1396 cat >>confdefs.h <<_ACEOF
1397 #define PACKAGE_STRING "$PACKAGE_STRING"
1398 _ACEOF
1399
1400
1401 cat >>confdefs.h <<_ACEOF
1402 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1403 _ACEOF
1404
1405
1406 # Let the site file select an alternate cache file if it wants to.
1407 # Prefer explicitly selected file to automatically selected ones.
1408 if test -z "$CONFIG_SITE"; then
1409   if test "x$prefix" != xNONE; then
1410     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1411   else
1412     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1413   fi
1414 fi
1415 for ac_site_file in $CONFIG_SITE; do
1416   if test -r "$ac_site_file"; then
1417     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1418 echo "$as_me: loading site script $ac_site_file" >&6;}
1419     sed 's/^/| /' "$ac_site_file" >&5
1420     . "$ac_site_file"
1421   fi
1422 done
1423
1424 if test -r "$cache_file"; then
1425   # Some versions of bash will fail to source /dev/null (special
1426   # files actually), so we avoid doing that.
1427   if test -f "$cache_file"; then
1428     { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1429 echo "$as_me: loading cache $cache_file" >&6;}
1430     case $cache_file in
1431       [\\/]* | ?:[\\/]* ) . $cache_file;;
1432       *)                      . ./$cache_file;;
1433     esac
1434   fi
1435 else
1436   { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1437 echo "$as_me: creating cache $cache_file" >&6;}
1438   >$cache_file
1439 fi
1440
1441 # Check that the precious variables saved in the cache have kept the same
1442 # value.
1443 ac_cache_corrupted=false
1444 for ac_var in `(set) 2>&1 |
1445                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1446   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1447   eval ac_new_set=\$ac_env_${ac_var}_set
1448   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1449   eval ac_new_val="\$ac_env_${ac_var}_value"
1450   case $ac_old_set,$ac_new_set in
1451     set,)
1452       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1453 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1454       ac_cache_corrupted=: ;;
1455     ,set)
1456       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1457 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1458       ac_cache_corrupted=: ;;
1459     ,);;
1460     *)
1461       if test "x$ac_old_val" != "x$ac_new_val"; then
1462         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1463 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1464         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1465 echo "$as_me:   former value:  $ac_old_val" >&2;}
1466         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1467 echo "$as_me:   current value: $ac_new_val" >&2;}
1468         ac_cache_corrupted=:
1469       fi;;
1470   esac
1471   # Pass precious variables to config.status.
1472   if test "$ac_new_set" = set; then
1473     case $ac_new_val in
1474     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1475       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1476     *) ac_arg=$ac_var=$ac_new_val ;;
1477     esac
1478     case " $ac_configure_args " in
1479       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1480       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1481     esac
1482   fi
1483 done
1484 if $ac_cache_corrupted; then
1485   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1486 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1487   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1488 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1489    { (exit 1); exit 1; }; }
1490 fi
1491
1492 ac_ext=c
1493 ac_cpp='$CPP $CPPFLAGS'
1494 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1495 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1496 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516 ac_aux_dir=
1517 for ac_dir in build $srcdir/build; do
1518   if test -f $ac_dir/install-sh; then
1519     ac_aux_dir=$ac_dir
1520     ac_install_sh="$ac_aux_dir/install-sh -c"
1521     break
1522   elif test -f $ac_dir/install.sh; then
1523     ac_aux_dir=$ac_dir
1524     ac_install_sh="$ac_aux_dir/install.sh -c"
1525     break
1526   elif test -f $ac_dir/shtool; then
1527     ac_aux_dir=$ac_dir
1528     ac_install_sh="$ac_aux_dir/shtool install -c"
1529     break
1530   fi
1531 done
1532 if test -z "$ac_aux_dir"; then
1533   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in build $srcdir/build" >&5
1534 echo "$as_me: error: cannot find install-sh or install.sh in build $srcdir/build" >&2;}
1535    { (exit 1); exit 1; }; }
1536 fi
1537 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1538 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1539 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1540
1541 eval `$ac_aux_dir/version.sh`
1542 if test -z "$OL_STRING"; then
1543         { { echo "$as_me:$LINENO: error: could not determine version" >&5
1544 echo "$as_me: error: could not determine version" >&2;}
1545    { (exit 1); exit 1; }; }
1546 fi
1547
1548 echo "$as_me:$LINENO: checking for GNU shtool" >&5
1549 echo $ECHO_N "checking for GNU shtool... $ECHO_C" >&6
1550 if test "${ac_cv_shtool+set}" = set; then
1551   echo $ECHO_N "(cached) $ECHO_C" >&6
1552 else
1553   #   canonicalize and split path string
1554 ac_paths="`echo .:$ac_aux_dir:$PATH |\
1555            sed -e 's%/*:%:%g' -e 's%/*$%%' \
1556                -e 's/^:/.:/' -e 's/::/:.:/g' -e 's/:$/:./' \
1557                -e 's/:/ /g'`"
1558 #   iterate over $PATH but prefer CWD
1559 ac_cv_shtool=""
1560 for ac_path in $ac_paths; do
1561     if test -f "$ac_path/shtool" && test ! -d "$ac_path/shtool"; then
1562         ac_cv_shtool="$ac_path/shtool"
1563         break
1564     fi
1565 done
1566 #   check for existance
1567 if test ".$ac_cv_shtool" = .; then
1568     { { echo "$as_me:$LINENO: error: no shtool found in .:$PATH" >&5
1569 echo "$as_me: error: no shtool found in .:$PATH" >&2;}
1570    { (exit 1); exit 1; }; }
1571 fi
1572 #   check deeper
1573 ac_rc=`($ac_cv_shtool --version) </dev/null 2>/dev/null | grep 'GNU shtool'`
1574 if test ".$ac_rc" = .; then
1575     ac_cv_shtool="${CONFIG_SHELL-/bin/sh} $ac_cv_shtool"
1576     ac_rc=`($ac_cv_shtool --version) </dev/null 2>/dev/null | grep 'GNU shtool'`
1577     if test ".$ac_rc" = .; then
1578         { { echo "$as_me:$LINENO: error: $ac_cv_shtool seems not to be GNU shtool" >&5
1579 echo "$as_me: error: $ac_cv_shtool seems not to be GNU shtool" >&2;}
1580    { (exit 1); exit 1; }; }
1581     fi
1582 fi
1583
1584 fi
1585 echo "$as_me:$LINENO: result: $ac_cv_shtool" >&5
1586 echo "${ECHO_T}$ac_cv_shtool" >&6
1587 SHTOOL="$ac_cv_shtool"
1588
1589
1590
1591 TB="`$SHTOOL echo -e '%B' 2>/dev/null`"
1592 TN="`$SHTOOL echo -e '%b' 2>/dev/null`"
1593
1594 OPENLDAP_CVS=""
1595 if test -d $ac_aux_dir/CVS; then
1596         OPENLDAP_CVS="(from CVS sources) "
1597 fi
1598
1599 echo "Configuring ${TB}${OL_STRING}${TN} ${OPENLDAP_CVS}..."
1600
1601 # Make sure we can run config.sub.
1602 $ac_config_sub sun4 >/dev/null 2>&1 ||
1603   { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
1604 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1605    { (exit 1); exit 1; }; }
1606
1607 echo "$as_me:$LINENO: checking build system type" >&5
1608 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1609 if test "${ac_cv_build+set}" = set; then
1610   echo $ECHO_N "(cached) $ECHO_C" >&6
1611 else
1612   ac_cv_build_alias=$build_alias
1613 test -z "$ac_cv_build_alias" &&
1614   ac_cv_build_alias=`$ac_config_guess`
1615 test -z "$ac_cv_build_alias" &&
1616   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1617 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1618    { (exit 1); exit 1; }; }
1619 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1620   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1621 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
1622    { (exit 1); exit 1; }; }
1623
1624 fi
1625 echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1626 echo "${ECHO_T}$ac_cv_build" >&6
1627 build=$ac_cv_build
1628 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1629 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1630 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1631
1632
1633 echo "$as_me:$LINENO: checking host system type" >&5
1634 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1635 if test "${ac_cv_host+set}" = set; then
1636   echo $ECHO_N "(cached) $ECHO_C" >&6
1637 else
1638   ac_cv_host_alias=$host_alias
1639 test -z "$ac_cv_host_alias" &&
1640   ac_cv_host_alias=$ac_cv_build_alias
1641 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1642   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1643 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1644    { (exit 1); exit 1; }; }
1645
1646 fi
1647 echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1648 echo "${ECHO_T}$ac_cv_host" >&6
1649 host=$ac_cv_host
1650 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1651 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1652 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1653
1654
1655 echo "$as_me:$LINENO: checking target system type" >&5
1656 echo $ECHO_N "checking target system type... $ECHO_C" >&6
1657 if test "${ac_cv_target+set}" = set; then
1658   echo $ECHO_N "(cached) $ECHO_C" >&6
1659 else
1660   ac_cv_target_alias=$target_alias
1661 test "x$ac_cv_target_alias" = "x" &&
1662   ac_cv_target_alias=$ac_cv_host_alias
1663 ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
1664   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_target_alias failed" >&5
1665 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
1666    { (exit 1); exit 1; }; }
1667
1668 fi
1669 echo "$as_me:$LINENO: result: $ac_cv_target" >&5
1670 echo "${ECHO_T}$ac_cv_target" >&6
1671 target=$ac_cv_target
1672 target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1673 target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1674 target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1675
1676
1677 # The aliases save the names the user supplied, while $host etc.
1678 # will get canonicalized.
1679 test -n "$target_alias" &&
1680   test "$program_prefix$program_suffix$program_transform_name" = \
1681     NONENONEs,x,x, &&
1682   program_prefix=${target_alias}-
1683
1684 OPENLDAP_PACKAGE=$OL_PACKAGE
1685 OPENLDAP_VERSION=$OL_VERSION
1686
1687
1688
1689
1690
1691 cat >>confdefs.h <<_ACEOF
1692 #define OPENLDAP_PACKAGE "$OL_PACKAGE"
1693 _ACEOF
1694
1695
1696 cat >>confdefs.h <<_ACEOF
1697 #define OPENLDAP_VERSION "$OL_VERSION"
1698 _ACEOF
1699
1700
1701
1702 cat >>confdefs.h <<_ACEOF
1703 #define LDAP_VENDOR_VERSION $OL_API_INC
1704 _ACEOF
1705
1706
1707 cat >>confdefs.h <<_ACEOF
1708 #define LDAP_VENDOR_VERSION_MAJOR $OL_MAJOR
1709 _ACEOF
1710
1711
1712 cat >>confdefs.h <<_ACEOF
1713 #define LDAP_VENDOR_VERSION_MINOR $OL_MINOR
1714 _ACEOF
1715
1716
1717 cat >>confdefs.h <<_ACEOF
1718 #define LDAP_VENDOR_VERSION_PATCH $OL_PATCH
1719 _ACEOF
1720
1721
1722 OPENLDAP_LIBVERSION=$OL_API_LIB
1723
1724 OPENLDAP_RELEASE_DATE="$OL_RELEASE_DATE"
1725
1726
1727                               ac_config_headers="$ac_config_headers include/portable.h include/ldap_features.h include/lber_types.h"
1728
1729 echo "$as_me:$LINENO: checking configure arguments" >&5
1730 echo $ECHO_N "checking configure arguments... $ECHO_C" >&6
1731
1732
1733 top_builddir=`pwd`
1734
1735 ldap_subdir="/openldap"
1736
1737
1738 # Check whether --with-subdir or --without-subdir was given.
1739 if test "${with_subdir+set}" = set; then
1740   withval="$with_subdir"
1741   case "$withval" in
1742         no) ldap_subdir=""
1743                 ;;
1744         yes)
1745                 ;;
1746         /*|\\*)
1747                 ldap_subdir="$withval"
1748                 ;;
1749         *)
1750                 ldap_subdir="/$withval"
1751                 ;;
1752 esac
1753
1754 fi;
1755
1756 # OpenLDAP --enable-debug
1757         # Check whether --enable-debug or --disable-debug was given.
1758 if test "${enable_debug+set}" = set; then
1759   enableval="$enable_debug"
1760
1761         ol_arg=invalid
1762         for ol_val in auto yes no ; do
1763                 if test "$enableval" = "$ol_val" ; then
1764                         ol_arg="$ol_val"
1765                 fi
1766         done
1767         if test "$ol_arg" = "invalid" ; then
1768                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-debug" >&5
1769 echo "$as_me: error: bad value $enableval for --enable-debug" >&2;}
1770    { (exit 1); exit 1; }; }
1771         fi
1772         ol_enable_debug="$ol_arg"
1773
1774 else
1775         ol_enable_debug="yes"
1776 fi; # end --enable-debug
1777 # OpenLDAP --enable-dynamic
1778         # Check whether --enable-dynamic or --disable-dynamic was given.
1779 if test "${enable_dynamic+set}" = set; then
1780   enableval="$enable_dynamic"
1781
1782         ol_arg=invalid
1783         for ol_val in auto yes no ; do
1784                 if test "$enableval" = "$ol_val" ; then
1785                         ol_arg="$ol_val"
1786                 fi
1787         done
1788         if test "$ol_arg" = "invalid" ; then
1789                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dynamic" >&5
1790 echo "$as_me: error: bad value $enableval for --enable-dynamic" >&2;}
1791    { (exit 1); exit 1; }; }
1792         fi
1793         ol_enable_dynamic="$ol_arg"
1794
1795 else
1796         ol_enable_dynamic="no"
1797 fi; # end --enable-dynamic
1798 # OpenLDAP --enable-syslog
1799         # Check whether --enable-syslog or --disable-syslog was given.
1800 if test "${enable_syslog+set}" = set; then
1801   enableval="$enable_syslog"
1802
1803         ol_arg=invalid
1804         for ol_val in auto yes no ; do
1805                 if test "$enableval" = "$ol_val" ; then
1806                         ol_arg="$ol_val"
1807                 fi
1808         done
1809         if test "$ol_arg" = "invalid" ; then
1810                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-syslog" >&5
1811 echo "$as_me: error: bad value $enableval for --enable-syslog" >&2;}
1812    { (exit 1); exit 1; }; }
1813         fi
1814         ol_enable_syslog="$ol_arg"
1815
1816 else
1817         ol_enable_syslog="auto"
1818 fi; # end --enable-syslog
1819 # OpenLDAP --enable-proctitle
1820         # Check whether --enable-proctitle or --disable-proctitle was given.
1821 if test "${enable_proctitle+set}" = set; then
1822   enableval="$enable_proctitle"
1823
1824         ol_arg=invalid
1825         for ol_val in auto yes no ; do
1826                 if test "$enableval" = "$ol_val" ; then
1827                         ol_arg="$ol_val"
1828                 fi
1829         done
1830         if test "$ol_arg" = "invalid" ; then
1831                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-proctitle" >&5
1832 echo "$as_me: error: bad value $enableval for --enable-proctitle" >&2;}
1833    { (exit 1); exit 1; }; }
1834         fi
1835         ol_enable_proctitle="$ol_arg"
1836
1837 else
1838         ol_enable_proctitle="yes"
1839 fi; # end --enable-proctitle
1840 ol_enable_referrals=${ol_enable_referrals-no}
1841 ol_enable_kbind=${ol_enable_kbind-no}
1842 # OpenLDAP --enable-ipv6
1843         # Check whether --enable-ipv6 or --disable-ipv6 was given.
1844 if test "${enable_ipv6+set}" = set; then
1845   enableval="$enable_ipv6"
1846
1847         ol_arg=invalid
1848         for ol_val in auto yes no ; do
1849                 if test "$enableval" = "$ol_val" ; then
1850                         ol_arg="$ol_val"
1851                 fi
1852         done
1853         if test "$ol_arg" = "invalid" ; then
1854                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ipv6" >&5
1855 echo "$as_me: error: bad value $enableval for --enable-ipv6" >&2;}
1856    { (exit 1); exit 1; }; }
1857         fi
1858         ol_enable_ipv6="$ol_arg"
1859
1860 else
1861         ol_enable_ipv6="auto"
1862 fi; # end --enable-ipv6
1863 # OpenLDAP --enable-local
1864         # Check whether --enable-local or --disable-local was given.
1865 if test "${enable_local+set}" = set; then
1866   enableval="$enable_local"
1867
1868         ol_arg=invalid
1869         for ol_val in auto yes no ; do
1870                 if test "$enableval" = "$ol_val" ; then
1871                         ol_arg="$ol_val"
1872                 fi
1873         done
1874         if test "$ol_arg" = "invalid" ; then
1875                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-local" >&5
1876 echo "$as_me: error: bad value $enableval for --enable-local" >&2;}
1877    { (exit 1); exit 1; }; }
1878         fi
1879         ol_enable_local="$ol_arg"
1880
1881 else
1882         ol_enable_local="auto"
1883 fi; # end --enable-local
1884 # OpenLDAP --enable-x_compile
1885         # Check whether --enable-x_compile or --disable-x_compile was given.
1886 if test "${enable_x_compile+set}" = set; then
1887   enableval="$enable_x_compile"
1888
1889         ol_arg=invalid
1890         for ol_val in yes no ; do
1891                 if test "$enableval" = "$ol_val" ; then
1892                         ol_arg="$ol_val"
1893                 fi
1894         done
1895         if test "$ol_arg" = "invalid" ; then
1896                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-x_compile" >&5
1897 echo "$as_me: error: bad value $enableval for --enable-x_compile" >&2;}
1898    { (exit 1); exit 1; }; }
1899         fi
1900         ol_enable_x_compile="$ol_arg"
1901
1902 else
1903         ol_enable_x_compile="no"
1904 fi; # end --enable-x_compile
1905
1906
1907 # OpenLDAP --with-cyrus_sasl
1908
1909 # Check whether --with-cyrus_sasl or --without-cyrus_sasl was given.
1910 if test "${with_cyrus_sasl+set}" = set; then
1911   withval="$with_cyrus_sasl"
1912
1913         ol_arg=invalid
1914         for ol_val in auto yes no  ; do
1915                 if test "$withval" = "$ol_val" ; then
1916                         ol_arg="$ol_val"
1917                 fi
1918         done
1919         if test "$ol_arg" = "invalid" ; then
1920                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-cyrus_sasl" >&5
1921 echo "$as_me: error: bad value $withval for --with-cyrus_sasl" >&2;}
1922    { (exit 1); exit 1; }; }
1923         fi
1924         ol_with_cyrus_sasl="$ol_arg"
1925
1926 else
1927         ol_with_cyrus_sasl="auto"
1928 fi; # end --with-cyrus_sasl
1929
1930 # OpenLDAP --with-fetch
1931
1932 # Check whether --with-fetch or --without-fetch was given.
1933 if test "${with_fetch+set}" = set; then
1934   withval="$with_fetch"
1935
1936         ol_arg=invalid
1937         for ol_val in auto yes no  ; do
1938                 if test "$withval" = "$ol_val" ; then
1939                         ol_arg="$ol_val"
1940                 fi
1941         done
1942         if test "$ol_arg" = "invalid" ; then
1943                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-fetch" >&5
1944 echo "$as_me: error: bad value $withval for --with-fetch" >&2;}
1945    { (exit 1); exit 1; }; }
1946         fi
1947         ol_with_fetch="$ol_arg"
1948
1949 else
1950         ol_with_fetch="auto"
1951 fi; # end --with-fetch
1952
1953 # OpenLDAP --with-kerberos
1954
1955 # Check whether --with-kerberos or --without-kerberos was given.
1956 if test "${with_kerberos+set}" = set; then
1957   withval="$with_kerberos"
1958
1959         ol_arg=invalid
1960         for ol_val in auto k5 k5only k425 kth k4 afs yes no ; do
1961                 if test "$withval" = "$ol_val" ; then
1962                         ol_arg="$ol_val"
1963                 fi
1964         done
1965         if test "$ol_arg" = "invalid" ; then
1966                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-kerberos" >&5
1967 echo "$as_me: error: bad value $withval for --with-kerberos" >&2;}
1968    { (exit 1); exit 1; }; }
1969         fi
1970         ol_with_kerberos="$ol_arg"
1971
1972 else
1973         ol_with_kerberos="auto"
1974 fi; # end --with-kerberos
1975
1976 # OpenLDAP --with-readline
1977
1978 # Check whether --with-readline or --without-readline was given.
1979 if test "${with_readline+set}" = set; then
1980   withval="$with_readline"
1981
1982         ol_arg=invalid
1983         for ol_val in auto yes no  ; do
1984                 if test "$withval" = "$ol_val" ; then
1985                         ol_arg="$ol_val"
1986                 fi
1987         done
1988         if test "$ol_arg" = "invalid" ; then
1989                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-readline" >&5
1990 echo "$as_me: error: bad value $withval for --with-readline" >&2;}
1991    { (exit 1); exit 1; }; }
1992         fi
1993         ol_with_readline="$ol_arg"
1994
1995 else
1996         ol_with_readline="auto"
1997 fi; # end --with-readline
1998
1999 # OpenLDAP --with-threads
2000
2001 # Check whether --with-threads or --without-threads was given.
2002 if test "${with_threads+set}" = set; then
2003   withval="$with_threads"
2004
2005         ol_arg=invalid
2006         for ol_val in auto nt posix mach pth lwp yes no manual  ; do
2007                 if test "$withval" = "$ol_val" ; then
2008                         ol_arg="$ol_val"
2009                 fi
2010         done
2011         if test "$ol_arg" = "invalid" ; then
2012                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-threads" >&5
2013 echo "$as_me: error: bad value $withval for --with-threads" >&2;}
2014    { (exit 1); exit 1; }; }
2015         fi
2016         ol_with_threads="$ol_arg"
2017
2018 else
2019         ol_with_threads="auto"
2020 fi; # end --with-threads
2021
2022 # OpenLDAP --with-tls
2023
2024 # Check whether --with-tls or --without-tls was given.
2025 if test "${with_tls+set}" = set; then
2026   withval="$with_tls"
2027
2028         ol_arg=invalid
2029         for ol_val in auto ssleay openssl yes no  ; do
2030                 if test "$withval" = "$ol_val" ; then
2031                         ol_arg="$ol_val"
2032                 fi
2033         done
2034         if test "$ol_arg" = "invalid" ; then
2035                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-tls" >&5
2036 echo "$as_me: error: bad value $withval for --with-tls" >&2;}
2037    { (exit 1); exit 1; }; }
2038         fi
2039         ol_with_tls="$ol_arg"
2040
2041 else
2042         ol_with_tls="auto"
2043 fi; # end --with-tls
2044
2045 # OpenLDAP --with-yielding_select
2046
2047 # Check whether --with-yielding_select or --without-yielding_select was given.
2048 if test "${with_yielding_select+set}" = set; then
2049   withval="$with_yielding_select"
2050
2051         ol_arg=invalid
2052         for ol_val in auto yes no manual  ; do
2053                 if test "$withval" = "$ol_val" ; then
2054                         ol_arg="$ol_val"
2055                 fi
2056         done
2057         if test "$ol_arg" = "invalid" ; then
2058                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-yielding_select" >&5
2059 echo "$as_me: error: bad value $withval for --with-yielding_select" >&2;}
2060    { (exit 1); exit 1; }; }
2061         fi
2062         ol_with_yielding_select="$ol_arg"
2063
2064 else
2065         ol_with_yielding_select="auto"
2066 fi; # end --with-yielding_select
2067
2068
2069
2070
2071 # Check whether --with-xxslapdoptions or --without-xxslapdoptions was given.
2072 if test "${with_xxslapdoptions+set}" = set; then
2073   withval="$with_xxslapdoptions"
2074
2075 fi;
2076 # OpenLDAP --enable-slapd
2077         # Check whether --enable-slapd or --disable-slapd was given.
2078 if test "${enable_slapd+set}" = set; then
2079   enableval="$enable_slapd"
2080
2081         ol_arg=invalid
2082         for ol_val in auto yes no ; do
2083                 if test "$enableval" = "$ol_val" ; then
2084                         ol_arg="$ol_val"
2085                 fi
2086         done
2087         if test "$ol_arg" = "invalid" ; then
2088                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slapd" >&5
2089 echo "$as_me: error: bad value $enableval for --enable-slapd" >&2;}
2090    { (exit 1); exit 1; }; }
2091         fi
2092         ol_enable_slapd="$ol_arg"
2093
2094 else
2095         ol_enable_slapd="yes"
2096 fi; # end --enable-slapd
2097 # OpenLDAP --enable-aci
2098         # Check whether --enable-aci or --disable-aci was given.
2099 if test "${enable_aci+set}" = set; then
2100   enableval="$enable_aci"
2101
2102         ol_arg=invalid
2103         for ol_val in auto yes no ; do
2104                 if test "$enableval" = "$ol_val" ; then
2105                         ol_arg="$ol_val"
2106                 fi
2107         done
2108         if test "$ol_arg" = "invalid" ; then
2109                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-aci" >&5
2110 echo "$as_me: error: bad value $enableval for --enable-aci" >&2;}
2111    { (exit 1); exit 1; }; }
2112         fi
2113         ol_enable_aci="$ol_arg"
2114
2115 else
2116         ol_enable_aci="no"
2117 fi; # end --enable-aci
2118 # OpenLDAP --enable-cleartext
2119         # Check whether --enable-cleartext or --disable-cleartext was given.
2120 if test "${enable_cleartext+set}" = set; then
2121   enableval="$enable_cleartext"
2122
2123         ol_arg=invalid
2124         for ol_val in auto yes no ; do
2125                 if test "$enableval" = "$ol_val" ; then
2126                         ol_arg="$ol_val"
2127                 fi
2128         done
2129         if test "$ol_arg" = "invalid" ; then
2130                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-cleartext" >&5
2131 echo "$as_me: error: bad value $enableval for --enable-cleartext" >&2;}
2132    { (exit 1); exit 1; }; }
2133         fi
2134         ol_enable_cleartext="$ol_arg"
2135
2136 else
2137         ol_enable_cleartext="yes"
2138 fi; # end --enable-cleartext
2139 # OpenLDAP --enable-crypt
2140         # Check whether --enable-crypt or --disable-crypt was given.
2141 if test "${enable_crypt+set}" = set; then
2142   enableval="$enable_crypt"
2143
2144         ol_arg=invalid
2145         for ol_val in auto yes no ; do
2146                 if test "$enableval" = "$ol_val" ; then
2147                         ol_arg="$ol_val"
2148                 fi
2149         done
2150         if test "$ol_arg" = "invalid" ; then
2151                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-crypt" >&5
2152 echo "$as_me: error: bad value $enableval for --enable-crypt" >&2;}
2153    { (exit 1); exit 1; }; }
2154         fi
2155         ol_enable_crypt="$ol_arg"
2156
2157 else
2158         ol_enable_crypt="no"
2159 fi; # end --enable-crypt
2160 # OpenLDAP --enable-kpasswd
2161         # Check whether --enable-kpasswd or --disable-kpasswd was given.
2162 if test "${enable_kpasswd+set}" = set; then
2163   enableval="$enable_kpasswd"
2164
2165         ol_arg=invalid
2166         for ol_val in auto yes no ; do
2167                 if test "$enableval" = "$ol_val" ; then
2168                         ol_arg="$ol_val"
2169                 fi
2170         done
2171         if test "$ol_arg" = "invalid" ; then
2172                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-kpasswd" >&5
2173 echo "$as_me: error: bad value $enableval for --enable-kpasswd" >&2;}
2174    { (exit 1); exit 1; }; }
2175         fi
2176         ol_enable_kpasswd="$ol_arg"
2177
2178 else
2179         ol_enable_kpasswd="no"
2180 fi; # end --enable-kpasswd
2181 # OpenLDAP --enable-lmpasswd
2182         # Check whether --enable-lmpasswd or --disable-lmpasswd was given.
2183 if test "${enable_lmpasswd+set}" = set; then
2184   enableval="$enable_lmpasswd"
2185
2186         ol_arg=invalid
2187         for ol_val in auto yes no ; do
2188                 if test "$enableval" = "$ol_val" ; then
2189                         ol_arg="$ol_val"
2190                 fi
2191         done
2192         if test "$ol_arg" = "invalid" ; then
2193                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-lmpasswd" >&5
2194 echo "$as_me: error: bad value $enableval for --enable-lmpasswd" >&2;}
2195    { (exit 1); exit 1; }; }
2196         fi
2197         ol_enable_lmpasswd="$ol_arg"
2198
2199 else
2200         ol_enable_lmpasswd="no"
2201 fi; # end --enable-lmpasswd
2202 # OpenLDAP --enable-spasswd
2203         # Check whether --enable-spasswd or --disable-spasswd was given.
2204 if test "${enable_spasswd+set}" = set; then
2205   enableval="$enable_spasswd"
2206
2207         ol_arg=invalid
2208         for ol_val in auto yes no ; do
2209                 if test "$enableval" = "$ol_val" ; then
2210                         ol_arg="$ol_val"
2211                 fi
2212         done
2213         if test "$ol_arg" = "invalid" ; then
2214                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-spasswd" >&5
2215 echo "$as_me: error: bad value $enableval for --enable-spasswd" >&2;}
2216    { (exit 1); exit 1; }; }
2217         fi
2218         ol_enable_spasswd="$ol_arg"
2219
2220 else
2221         ol_enable_spasswd="no"
2222 fi; # end --enable-spasswd
2223 # OpenLDAP --enable-modules
2224         # Check whether --enable-modules or --disable-modules was given.
2225 if test "${enable_modules+set}" = set; then
2226   enableval="$enable_modules"
2227
2228         ol_arg=invalid
2229         for ol_val in auto yes no ; do
2230                 if test "$enableval" = "$ol_val" ; then
2231                         ol_arg="$ol_val"
2232                 fi
2233         done
2234         if test "$ol_arg" = "invalid" ; then
2235                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-modules" >&5
2236 echo "$as_me: error: bad value $enableval for --enable-modules" >&2;}
2237    { (exit 1); exit 1; }; }
2238         fi
2239         ol_enable_modules="$ol_arg"
2240
2241 else
2242         ol_enable_modules="no"
2243 fi; # end --enable-modules
2244 ol_enable_multimaster=${ol_enable_multimaster-no}
2245 # OpenLDAP --enable-phonetic
2246         # Check whether --enable-phonetic or --disable-phonetic was given.
2247 if test "${enable_phonetic+set}" = set; then
2248   enableval="$enable_phonetic"
2249
2250         ol_arg=invalid
2251         for ol_val in auto yes no ; do
2252                 if test "$enableval" = "$ol_val" ; then
2253                         ol_arg="$ol_val"
2254                 fi
2255         done
2256         if test "$ol_arg" = "invalid" ; then
2257                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-phonetic" >&5
2258 echo "$as_me: error: bad value $enableval for --enable-phonetic" >&2;}
2259    { (exit 1); exit 1; }; }
2260         fi
2261         ol_enable_phonetic="$ol_arg"
2262
2263 else
2264         ol_enable_phonetic="no"
2265 fi; # end --enable-phonetic
2266 # OpenLDAP --enable-rewrite
2267         # Check whether --enable-rewrite or --disable-rewrite was given.
2268 if test "${enable_rewrite+set}" = set; then
2269   enableval="$enable_rewrite"
2270
2271         ol_arg=invalid
2272         for ol_val in auto yes no ; do
2273                 if test "$enableval" = "$ol_val" ; then
2274                         ol_arg="$ol_val"
2275                 fi
2276         done
2277         if test "$ol_arg" = "invalid" ; then
2278                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rewrite" >&5
2279 echo "$as_me: error: bad value $enableval for --enable-rewrite" >&2;}
2280    { (exit 1); exit 1; }; }
2281         fi
2282         ol_enable_rewrite="$ol_arg"
2283
2284 else
2285         ol_enable_rewrite="no"
2286 fi; # end --enable-rewrite
2287 # OpenLDAP --enable-rlookups
2288         # Check whether --enable-rlookups or --disable-rlookups was given.
2289 if test "${enable_rlookups+set}" = set; then
2290   enableval="$enable_rlookups"
2291
2292         ol_arg=invalid
2293         for ol_val in auto yes no ; do
2294                 if test "$enableval" = "$ol_val" ; then
2295                         ol_arg="$ol_val"
2296                 fi
2297         done
2298         if test "$ol_arg" = "invalid" ; then
2299                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-rlookups" >&5
2300 echo "$as_me: error: bad value $enableval for --enable-rlookups" >&2;}
2301    { (exit 1); exit 1; }; }
2302         fi
2303         ol_enable_rlookups="$ol_arg"
2304
2305 else
2306         ol_enable_rlookups="no"
2307 fi; # end --enable-rlookups
2308 # OpenLDAP --enable-slapi
2309         # Check whether --enable-slapi or --disable-slapi was given.
2310 if test "${enable_slapi+set}" = set; then
2311   enableval="$enable_slapi"
2312
2313         ol_arg=invalid
2314         for ol_val in auto yes no ; do
2315                 if test "$enableval" = "$ol_val" ; then
2316                         ol_arg="$ol_val"
2317                 fi
2318         done
2319         if test "$ol_arg" = "invalid" ; then
2320                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slapi" >&5
2321 echo "$as_me: error: bad value $enableval for --enable-slapi" >&2;}
2322    { (exit 1); exit 1; }; }
2323         fi
2324         ol_enable_slapi="$ol_arg"
2325
2326 else
2327         ol_enable_slapi="no"
2328 fi; # end --enable-slapi
2329 # OpenLDAP --enable-slp
2330         # Check whether --enable-slp or --disable-slp was given.
2331 if test "${enable_slp+set}" = set; then
2332   enableval="$enable_slp"
2333
2334         ol_arg=invalid
2335         for ol_val in auto yes no ; do
2336                 if test "$enableval" = "$ol_val" ; then
2337                         ol_arg="$ol_val"
2338                 fi
2339         done
2340         if test "$ol_arg" = "invalid" ; then
2341                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slp" >&5
2342 echo "$as_me: error: bad value $enableval for --enable-slp" >&2;}
2343    { (exit 1); exit 1; }; }
2344         fi
2345         ol_enable_slp="$ol_arg"
2346
2347 else
2348         ol_enable_slp="no"
2349 fi; # end --enable-slp
2350 # OpenLDAP --enable-wrappers
2351         # Check whether --enable-wrappers or --disable-wrappers was given.
2352 if test "${enable_wrappers+set}" = set; then
2353   enableval="$enable_wrappers"
2354
2355         ol_arg=invalid
2356         for ol_val in auto yes no ; do
2357                 if test "$enableval" = "$ol_val" ; then
2358                         ol_arg="$ol_val"
2359                 fi
2360         done
2361         if test "$ol_arg" = "invalid" ; then
2362                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-wrappers" >&5
2363 echo "$as_me: error: bad value $enableval for --enable-wrappers" >&2;}
2364    { (exit 1); exit 1; }; }
2365         fi
2366         ol_enable_wrappers="$ol_arg"
2367
2368 else
2369         ol_enable_wrappers="no"
2370 fi; # end --enable-wrappers
2371
2372
2373 # OpenLDAP --enable-bdb
2374         # Check whether --enable-bdb or --disable-bdb was given.
2375 if test "${enable_bdb+set}" = set; then
2376   enableval="$enable_bdb"
2377
2378         ol_arg=invalid
2379         for ol_val in auto yes no ; do
2380                 if test "$enableval" = "$ol_val" ; then
2381                         ol_arg="$ol_val"
2382                 fi
2383         done
2384         if test "$ol_arg" = "invalid" ; then
2385                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-bdb" >&5
2386 echo "$as_me: error: bad value $enableval for --enable-bdb" >&2;}
2387    { (exit 1); exit 1; }; }
2388         fi
2389         ol_enable_bdb="$ol_arg"
2390
2391 else
2392         ol_enable_bdb="yes"
2393 fi; # end --enable-bdb
2394 # OpenLDAP --with-bdb_module
2395
2396 # Check whether --with-bdb_module or --without-bdb_module was given.
2397 if test "${with_bdb_module+set}" = set; then
2398   withval="$with_bdb_module"
2399
2400         ol_arg=invalid
2401         for ol_val in static dynamic ; do
2402                 if test "$withval" = "$ol_val" ; then
2403                         ol_arg="$ol_val"
2404                 fi
2405         done
2406         if test "$ol_arg" = "invalid" ; then
2407                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-bdb_module" >&5
2408 echo "$as_me: error: bad value $withval for --with-bdb_module" >&2;}
2409    { (exit 1); exit 1; }; }
2410         fi
2411         ol_with_bdb_module="$ol_arg"
2412
2413 else
2414         ol_with_bdb_module="static"
2415 fi; # end --with-bdb_module
2416
2417 # OpenLDAP --enable-dnssrv
2418         # Check whether --enable-dnssrv or --disable-dnssrv was given.
2419 if test "${enable_dnssrv+set}" = set; then
2420   enableval="$enable_dnssrv"
2421
2422         ol_arg=invalid
2423         for ol_val in auto yes no ; do
2424                 if test "$enableval" = "$ol_val" ; then
2425                         ol_arg="$ol_val"
2426                 fi
2427         done
2428         if test "$ol_arg" = "invalid" ; then
2429                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-dnssrv" >&5
2430 echo "$as_me: error: bad value $enableval for --enable-dnssrv" >&2;}
2431    { (exit 1); exit 1; }; }
2432         fi
2433         ol_enable_dnssrv="$ol_arg"
2434
2435 else
2436         ol_enable_dnssrv="no"
2437 fi; # end --enable-dnssrv
2438 # OpenLDAP --with-dnssrv_module
2439
2440 # Check whether --with-dnssrv_module or --without-dnssrv_module was given.
2441 if test "${with_dnssrv_module+set}" = set; then
2442   withval="$with_dnssrv_module"
2443
2444         ol_arg=invalid
2445         for ol_val in static dynamic ; do
2446                 if test "$withval" = "$ol_val" ; then
2447                         ol_arg="$ol_val"
2448                 fi
2449         done
2450         if test "$ol_arg" = "invalid" ; then
2451                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-dnssrv_module" >&5
2452 echo "$as_me: error: bad value $withval for --with-dnssrv_module" >&2;}
2453    { (exit 1); exit 1; }; }
2454         fi
2455         ol_with_dnssrv_module="$ol_arg"
2456
2457 else
2458         ol_with_dnssrv_module="static"
2459 fi; # end --with-dnssrv_module
2460
2461 # OpenLDAP --enable-ldap
2462         # Check whether --enable-ldap or --disable-ldap was given.
2463 if test "${enable_ldap+set}" = set; then
2464   enableval="$enable_ldap"
2465
2466         ol_arg=invalid
2467         for ol_val in auto yes no ; do
2468                 if test "$enableval" = "$ol_val" ; then
2469                         ol_arg="$ol_val"
2470                 fi
2471         done
2472         if test "$ol_arg" = "invalid" ; then
2473                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ldap" >&5
2474 echo "$as_me: error: bad value $enableval for --enable-ldap" >&2;}
2475    { (exit 1); exit 1; }; }
2476         fi
2477         ol_enable_ldap="$ol_arg"
2478
2479 else
2480         ol_enable_ldap="no"
2481 fi; # end --enable-ldap
2482 # OpenLDAP --with-ldap_module
2483
2484 # Check whether --with-ldap_module or --without-ldap_module was given.
2485 if test "${with_ldap_module+set}" = set; then
2486   withval="$with_ldap_module"
2487
2488         ol_arg=invalid
2489         for ol_val in static dynamic ; do
2490                 if test "$withval" = "$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 $withval for --with-ldap_module" >&5
2496 echo "$as_me: error: bad value $withval for --with-ldap_module" >&2;}
2497    { (exit 1); exit 1; }; }
2498         fi
2499         ol_with_ldap_module="$ol_arg"
2500
2501 else
2502         ol_with_ldap_module="static"
2503 fi; # end --with-ldap_module
2504
2505 # OpenLDAP --enable-ldbm
2506         # Check whether --enable-ldbm or --disable-ldbm was given.
2507 if test "${enable_ldbm+set}" = set; then
2508   enableval="$enable_ldbm"
2509
2510         ol_arg=invalid
2511         for ol_val in auto yes no ; do
2512                 if test "$enableval" = "$ol_val" ; then
2513                         ol_arg="$ol_val"
2514                 fi
2515         done
2516         if test "$ol_arg" = "invalid" ; then
2517                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-ldbm" >&5
2518 echo "$as_me: error: bad value $enableval for --enable-ldbm" >&2;}
2519    { (exit 1); exit 1; }; }
2520         fi
2521         ol_enable_ldbm="$ol_arg"
2522
2523 else
2524         ol_enable_ldbm="no"
2525 fi; # end --enable-ldbm
2526 # OpenLDAP --with-ldbm_api
2527
2528 # Check whether --with-ldbm_api or --without-ldbm_api was given.
2529 if test "${with_ldbm_api+set}" = set; then
2530   withval="$with_ldbm_api"
2531
2532         ol_arg=invalid
2533         for ol_val in auto berkeley bcompat mdbm gdbm ; do
2534                 if test "$withval" = "$ol_val" ; then
2535                         ol_arg="$ol_val"
2536                 fi
2537         done
2538         if test "$ol_arg" = "invalid" ; then
2539                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-ldbm_api" >&5
2540 echo "$as_me: error: bad value $withval for --with-ldbm_api" >&2;}
2541    { (exit 1); exit 1; }; }
2542         fi
2543         ol_with_ldbm_api="$ol_arg"
2544
2545 else
2546         ol_with_ldbm_api="auto"
2547 fi; # end --with-ldbm_api
2548
2549 # OpenLDAP --with-ldbm_module
2550
2551 # Check whether --with-ldbm_module or --without-ldbm_module was given.
2552 if test "${with_ldbm_module+set}" = set; then
2553   withval="$with_ldbm_module"
2554
2555         ol_arg=invalid
2556         for ol_val in static dynamic ; do
2557                 if test "$withval" = "$ol_val" ; then
2558                         ol_arg="$ol_val"
2559                 fi
2560         done
2561         if test "$ol_arg" = "invalid" ; then
2562                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-ldbm_module" >&5
2563 echo "$as_me: error: bad value $withval for --with-ldbm_module" >&2;}
2564    { (exit 1); exit 1; }; }
2565         fi
2566         ol_with_ldbm_module="$ol_arg"
2567
2568 else
2569         ol_with_ldbm_module="static"
2570 fi; # end --with-ldbm_module
2571
2572 # OpenLDAP --with-ldbm_type
2573
2574 # Check whether --with-ldbm_type or --without-ldbm_type was given.
2575 if test "${with_ldbm_type+set}" = set; then
2576   withval="$with_ldbm_type"
2577
2578         ol_arg=invalid
2579         for ol_val in auto btree hash ; do
2580                 if test "$withval" = "$ol_val" ; then
2581                         ol_arg="$ol_val"
2582                 fi
2583         done
2584         if test "$ol_arg" = "invalid" ; then
2585                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-ldbm_type" >&5
2586 echo "$as_me: error: bad value $withval for --with-ldbm_type" >&2;}
2587    { (exit 1); exit 1; }; }
2588         fi
2589         ol_with_ldbm_type="$ol_arg"
2590
2591 else
2592         ol_with_ldbm_type="auto"
2593 fi; # end --with-ldbm_type
2594
2595 # OpenLDAP --enable-meta
2596         # Check whether --enable-meta or --disable-meta was given.
2597 if test "${enable_meta+set}" = set; then
2598   enableval="$enable_meta"
2599
2600         ol_arg=invalid
2601         for ol_val in auto yes no ; do
2602                 if test "$enableval" = "$ol_val" ; then
2603                         ol_arg="$ol_val"
2604                 fi
2605         done
2606         if test "$ol_arg" = "invalid" ; then
2607                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-meta" >&5
2608 echo "$as_me: error: bad value $enableval for --enable-meta" >&2;}
2609    { (exit 1); exit 1; }; }
2610         fi
2611         ol_enable_meta="$ol_arg"
2612
2613 else
2614         ol_enable_meta="no"
2615 fi; # end --enable-meta
2616 # OpenLDAP --with-meta_module
2617
2618 # Check whether --with-meta_module or --without-meta_module was given.
2619 if test "${with_meta_module+set}" = set; then
2620   withval="$with_meta_module"
2621
2622         ol_arg=invalid
2623         for ol_val in static dynamic ; do
2624                 if test "$withval" = "$ol_val" ; then
2625                         ol_arg="$ol_val"
2626                 fi
2627         done
2628         if test "$ol_arg" = "invalid" ; then
2629                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-meta_module" >&5
2630 echo "$as_me: error: bad value $withval for --with-meta_module" >&2;}
2631    { (exit 1); exit 1; }; }
2632         fi
2633         ol_with_meta_module="$ol_arg"
2634
2635 else
2636         ol_with_meta_module="static"
2637 fi; # end --with-meta_module
2638
2639 # OpenLDAP --enable-monitor
2640         # Check whether --enable-monitor or --disable-monitor was given.
2641 if test "${enable_monitor+set}" = set; then
2642   enableval="$enable_monitor"
2643
2644         ol_arg=invalid
2645         for ol_val in auto yes no ; do
2646                 if test "$enableval" = "$ol_val" ; then
2647                         ol_arg="$ol_val"
2648                 fi
2649         done
2650         if test "$ol_arg" = "invalid" ; then
2651                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-monitor" >&5
2652 echo "$as_me: error: bad value $enableval for --enable-monitor" >&2;}
2653    { (exit 1); exit 1; }; }
2654         fi
2655         ol_enable_monitor="$ol_arg"
2656
2657 else
2658         ol_enable_monitor="no"
2659 fi; # end --enable-monitor
2660 # OpenLDAP --with-monitor_module
2661
2662 # Check whether --with-monitor_module or --without-monitor_module was given.
2663 if test "${with_monitor_module+set}" = set; then
2664   withval="$with_monitor_module"
2665
2666         ol_arg=invalid
2667         for ol_val in static dynamic ; do
2668                 if test "$withval" = "$ol_val" ; then
2669                         ol_arg="$ol_val"
2670                 fi
2671         done
2672         if test "$ol_arg" = "invalid" ; then
2673                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-monitor_module" >&5
2674 echo "$as_me: error: bad value $withval for --with-monitor_module" >&2;}
2675    { (exit 1); exit 1; }; }
2676         fi
2677         ol_with_monitor_module="$ol_arg"
2678
2679 else
2680         ol_with_monitor_module="static"
2681 fi; # end --with-monitor_module
2682
2683 # OpenLDAP --enable-null
2684         # Check whether --enable-null or --disable-null was given.
2685 if test "${enable_null+set}" = set; then
2686   enableval="$enable_null"
2687
2688         ol_arg=invalid
2689         for ol_val in auto yes no ; do
2690                 if test "$enableval" = "$ol_val" ; then
2691                         ol_arg="$ol_val"
2692                 fi
2693         done
2694         if test "$ol_arg" = "invalid" ; then
2695                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-null" >&5
2696 echo "$as_me: error: bad value $enableval for --enable-null" >&2;}
2697    { (exit 1); exit 1; }; }
2698         fi
2699         ol_enable_null="$ol_arg"
2700
2701 else
2702         ol_enable_null="no"
2703 fi; # end --enable-null
2704 # OpenLDAP --with-null_module
2705
2706 # Check whether --with-null_module or --without-null_module was given.
2707 if test "${with_null_module+set}" = set; then
2708   withval="$with_null_module"
2709
2710         ol_arg=invalid
2711         for ol_val in static dynamic ; do
2712                 if test "$withval" = "$ol_val" ; then
2713                         ol_arg="$ol_val"
2714                 fi
2715         done
2716         if test "$ol_arg" = "invalid" ; then
2717                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-null_module" >&5
2718 echo "$as_me: error: bad value $withval for --with-null_module" >&2;}
2719    { (exit 1); exit 1; }; }
2720         fi
2721         ol_with_null_module="$ol_arg"
2722
2723 else
2724         ol_with_null_module="static"
2725 fi; # end --with-null_module
2726
2727 # OpenLDAP --enable-passwd
2728         # Check whether --enable-passwd or --disable-passwd was given.
2729 if test "${enable_passwd+set}" = set; then
2730   enableval="$enable_passwd"
2731
2732         ol_arg=invalid
2733         for ol_val in auto yes no ; do
2734                 if test "$enableval" = "$ol_val" ; then
2735                         ol_arg="$ol_val"
2736                 fi
2737         done
2738         if test "$ol_arg" = "invalid" ; then
2739                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-passwd" >&5
2740 echo "$as_me: error: bad value $enableval for --enable-passwd" >&2;}
2741    { (exit 1); exit 1; }; }
2742         fi
2743         ol_enable_passwd="$ol_arg"
2744
2745 else
2746         ol_enable_passwd="no"
2747 fi; # end --enable-passwd
2748 # OpenLDAP --with-passwd_module
2749
2750 # Check whether --with-passwd_module or --without-passwd_module was given.
2751 if test "${with_passwd_module+set}" = set; then
2752   withval="$with_passwd_module"
2753
2754         ol_arg=invalid
2755         for ol_val in static dynamic ; do
2756                 if test "$withval" = "$ol_val" ; then
2757                         ol_arg="$ol_val"
2758                 fi
2759         done
2760         if test "$ol_arg" = "invalid" ; then
2761                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-passwd_module" >&5
2762 echo "$as_me: error: bad value $withval for --with-passwd_module" >&2;}
2763    { (exit 1); exit 1; }; }
2764         fi
2765         ol_with_passwd_module="$ol_arg"
2766
2767 else
2768         ol_with_passwd_module="static"
2769 fi; # end --with-passwd_module
2770
2771 # OpenLDAP --enable-perl
2772         # Check whether --enable-perl or --disable-perl was given.
2773 if test "${enable_perl+set}" = set; then
2774   enableval="$enable_perl"
2775
2776         ol_arg=invalid
2777         for ol_val in auto yes no ; do
2778                 if test "$enableval" = "$ol_val" ; then
2779                         ol_arg="$ol_val"
2780                 fi
2781         done
2782         if test "$ol_arg" = "invalid" ; then
2783                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-perl" >&5
2784 echo "$as_me: error: bad value $enableval for --enable-perl" >&2;}
2785    { (exit 1); exit 1; }; }
2786         fi
2787         ol_enable_perl="$ol_arg"
2788
2789 else
2790         ol_enable_perl="no"
2791 fi; # end --enable-perl
2792 # OpenLDAP --with-perl_module
2793
2794 # Check whether --with-perl_module or --without-perl_module was given.
2795 if test "${with_perl_module+set}" = set; then
2796   withval="$with_perl_module"
2797
2798         ol_arg=invalid
2799         for ol_val in static dynamic ; do
2800                 if test "$withval" = "$ol_val" ; then
2801                         ol_arg="$ol_val"
2802                 fi
2803         done
2804         if test "$ol_arg" = "invalid" ; then
2805                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-perl_module" >&5
2806 echo "$as_me: error: bad value $withval for --with-perl_module" >&2;}
2807    { (exit 1); exit 1; }; }
2808         fi
2809         ol_with_perl_module="$ol_arg"
2810
2811 else
2812         ol_with_perl_module="static"
2813 fi; # end --with-perl_module
2814
2815 # OpenLDAP --enable-shell
2816         # Check whether --enable-shell or --disable-shell was given.
2817 if test "${enable_shell+set}" = set; then
2818   enableval="$enable_shell"
2819
2820         ol_arg=invalid
2821         for ol_val in auto yes no ; do
2822                 if test "$enableval" = "$ol_val" ; then
2823                         ol_arg="$ol_val"
2824                 fi
2825         done
2826         if test "$ol_arg" = "invalid" ; then
2827                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-shell" >&5
2828 echo "$as_me: error: bad value $enableval for --enable-shell" >&2;}
2829    { (exit 1); exit 1; }; }
2830         fi
2831         ol_enable_shell="$ol_arg"
2832
2833 else
2834         ol_enable_shell="no"
2835 fi; # end --enable-shell
2836 # OpenLDAP --with-shell_module
2837
2838 # Check whether --with-shell_module or --without-shell_module was given.
2839 if test "${with_shell_module+set}" = set; then
2840   withval="$with_shell_module"
2841
2842         ol_arg=invalid
2843         for ol_val in static dynamic ; do
2844                 if test "$withval" = "$ol_val" ; then
2845                         ol_arg="$ol_val"
2846                 fi
2847         done
2848         if test "$ol_arg" = "invalid" ; then
2849                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-shell_module" >&5
2850 echo "$as_me: error: bad value $withval for --with-shell_module" >&2;}
2851    { (exit 1); exit 1; }; }
2852         fi
2853         ol_with_shell_module="$ol_arg"
2854
2855 else
2856         ol_with_shell_module="static"
2857 fi; # end --with-shell_module
2858
2859 # OpenLDAP --enable-sql
2860         # Check whether --enable-sql or --disable-sql was given.
2861 if test "${enable_sql+set}" = set; then
2862   enableval="$enable_sql"
2863
2864         ol_arg=invalid
2865         for ol_val in auto yes no ; do
2866                 if test "$enableval" = "$ol_val" ; then
2867                         ol_arg="$ol_val"
2868                 fi
2869         done
2870         if test "$ol_arg" = "invalid" ; then
2871                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-sql" >&5
2872 echo "$as_me: error: bad value $enableval for --enable-sql" >&2;}
2873    { (exit 1); exit 1; }; }
2874         fi
2875         ol_enable_sql="$ol_arg"
2876
2877 else
2878         ol_enable_sql="no"
2879 fi; # end --enable-sql
2880 # OpenLDAP --with-sql_module
2881
2882 # Check whether --with-sql_module or --without-sql_module was given.
2883 if test "${with_sql_module+set}" = set; then
2884   withval="$with_sql_module"
2885
2886         ol_arg=invalid
2887         for ol_val in static dynamic ; do
2888                 if test "$withval" = "$ol_val" ; then
2889                         ol_arg="$ol_val"
2890                 fi
2891         done
2892         if test "$ol_arg" = "invalid" ; then
2893                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-sql_module" >&5
2894 echo "$as_me: error: bad value $withval for --with-sql_module" >&2;}
2895    { (exit 1); exit 1; }; }
2896         fi
2897         ol_with_sql_module="$ol_arg"
2898
2899 else
2900         ol_with_sql_module="static"
2901 fi; # end --with-sql_module
2902
2903 # OpenLDAP --enable-tcl
2904         # Check whether --enable-tcl or --disable-tcl was given.
2905 if test "${enable_tcl+set}" = set; then
2906   enableval="$enable_tcl"
2907
2908         ol_arg=invalid
2909         for ol_val in auto yes no ; do
2910                 if test "$enableval" = "$ol_val" ; then
2911                         ol_arg="$ol_val"
2912                 fi
2913         done
2914         if test "$ol_arg" = "invalid" ; then
2915                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-tcl" >&5
2916 echo "$as_me: error: bad value $enableval for --enable-tcl" >&2;}
2917    { (exit 1); exit 1; }; }
2918         fi
2919         ol_enable_tcl="$ol_arg"
2920
2921 else
2922         ol_enable_tcl="no"
2923 fi; # end --enable-tcl
2924 # OpenLDAP --with-tcl_module
2925
2926 # Check whether --with-tcl_module or --without-tcl_module was given.
2927 if test "${with_tcl_module+set}" = set; then
2928   withval="$with_tcl_module"
2929
2930         ol_arg=invalid
2931         for ol_val in static dynamic ; do
2932                 if test "$withval" = "$ol_val" ; then
2933                         ol_arg="$ol_val"
2934                 fi
2935         done
2936         if test "$ol_arg" = "invalid" ; then
2937                 { { echo "$as_me:$LINENO: error: bad value $withval for --with-tcl_module" >&5
2938 echo "$as_me: error: bad value $withval for --with-tcl_module" >&2;}
2939    { (exit 1); exit 1; }; }
2940         fi
2941         ol_with_tcl_module="$ol_arg"
2942
2943 else
2944         ol_with_tcl_module="static"
2945 fi; # end --with-tcl_module
2946
2947
2948
2949 # Check whether --with-xxslurpdoptions or --without-xxslurpdoptions was given.
2950 if test "${with_xxslurpdoptions+set}" = set; then
2951   withval="$with_xxslurpdoptions"
2952
2953 fi;
2954 # OpenLDAP --enable-slurpd
2955         # Check whether --enable-slurpd or --disable-slurpd was given.
2956 if test "${enable_slurpd+set}" = set; then
2957   enableval="$enable_slurpd"
2958
2959         ol_arg=invalid
2960         for ol_val in auto yes no ; do
2961                 if test "$enableval" = "$ol_val" ; then
2962                         ol_arg="$ol_val"
2963                 fi
2964         done
2965         if test "$ol_arg" = "invalid" ; then
2966                 { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-slurpd" >&5
2967 echo "$as_me: error: bad value $enableval for --enable-slurpd" >&2;}
2968    { (exit 1); exit 1; }; }
2969         fi
2970         ol_enable_slurpd="$ol_arg"
2971
2972 else
2973         ol_enable_slurpd="auto"
2974 fi; # end --enable-slurpd
2975
2976
2977 # Check whether --with-xxliboptions or --without-xxliboptions was given.
2978 if test "${with_xxliboptions+set}" = set; then
2979   withval="$with_xxliboptions"
2980
2981 fi;
2982 # Check whether --enable-static or --disable-static was given.
2983 if test "${enable_static+set}" = set; then
2984   enableval="$enable_static"
2985   p=${PACKAGE-default}
2986 case $enableval in
2987 yes) enable_static=yes ;;
2988 no) enable_static=no ;;
2989 *)
2990   enable_static=no
2991   # Look at the argument we got.  We use all the common list separators.
2992   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
2993   for pkg in $enableval; do
2994     if test "X$pkg" = "X$p"; then
2995       enable_static=yes
2996     fi
2997   done
2998   IFS="$ac_save_ifs"
2999   ;;
3000 esac
3001 else
3002   enable_static=yes
3003 fi;
3004 # Check whether --enable-shared or --disable-shared was given.
3005 if test "${enable_shared+set}" = set; then
3006   enableval="$enable_shared"
3007   p=${PACKAGE-default}
3008 case $enableval in
3009 yes) enable_shared=yes ;;
3010 no) enable_shared=no ;;
3011 *)
3012   enable_shared=no
3013   # Look at the argument we got.  We use all the common list separators.
3014   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
3015   for pkg in $enableval; do
3016     if test "X$pkg" = "X$p"; then
3017       enable_shared=yes
3018     fi
3019   done
3020   IFS="$ac_save_ifs"
3021   ;;
3022 esac
3023 else
3024   enable_shared=yes
3025 fi;
3026
3027
3028 # validate options
3029 if test $ol_enable_slapd = no ; then
3030                 if test $ol_enable_slapi = yes ; then
3031                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-slapi argument" >&5
3032 echo "$as_me: WARNING: slapd disabled, ignoring --enable-slapi argument" >&2;}
3033         fi
3034         if test $ol_enable_bdb = yes ; then
3035                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-bdb argument" >&5
3036 echo "$as_me: WARNING: slapd disabled, ignoring --enable-bdb argument" >&2;}
3037         fi
3038         if test $ol_enable_dnssrv = yes ; then
3039                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-dnssrv argument" >&5
3040 echo "$as_me: WARNING: slapd disabled, ignoring --enable-dnssrv argument" >&2;}
3041         fi
3042         if test $ol_enable_ldap = yes ; then
3043                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-ldap argument" >&5
3044 echo "$as_me: WARNING: slapd disabled, ignoring --enable-ldap argument" >&2;}
3045         fi
3046         if test $ol_enable_ldbm = yes ; then
3047                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-ldbm argument" >&5
3048 echo "$as_me: WARNING: slapd disabled, ignoring --enable-ldbm argument" >&2;}
3049         fi
3050         if test $ol_enable_meta = yes ; then
3051                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-meta argument" >&5
3052 echo "$as_me: WARNING: slapd disabled, ignoring --enable-meta argument" >&2;}
3053         fi
3054         if test $ol_enable_monitor = yes ; then
3055                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-monitor argument" >&5
3056 echo "$as_me: WARNING: slapd disabled, ignoring --enable-monitor argument" >&2;}
3057         fi
3058         if test $ol_enable_null = yes ; then
3059                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-null argument" >&5
3060 echo "$as_me: WARNING: slapd disabled, ignoring --enable-null argument" >&2;}
3061         fi
3062         if test $ol_enable_passwd = yes ; then
3063                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-passwd argument" >&5
3064 echo "$as_me: WARNING: slapd disabled, ignoring --enable-passwd argument" >&2;}
3065         fi
3066         if test $ol_enable_perl = yes ; then
3067                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-perl argument" >&5
3068 echo "$as_me: WARNING: slapd disabled, ignoring --enable-perl argument" >&2;}
3069         fi
3070         if test $ol_enable_shell = yes ; then
3071                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-shell argument" >&5
3072 echo "$as_me: WARNING: slapd disabled, ignoring --enable-shell argument" >&2;}
3073         fi
3074         if test $ol_enable_tcl = yes ; then
3075                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-tcl argument" >&5
3076 echo "$as_me: WARNING: slapd disabled, ignoring --enable-tcl argument" >&2;}
3077         fi
3078         if test $ol_enable_sql = yes ; then
3079                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-sql argument" >&5
3080 echo "$as_me: WARNING: slapd disabled, ignoring --enable-sql argument" >&2;}
3081         fi
3082         if test $ol_enable_modules = yes ; then
3083                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-modules argument" >&5
3084 echo "$as_me: WARNING: slapd disabled, ignoring --enable-modules argument" >&2;}
3085         fi
3086         if test $ol_enable_multimaster = yes ; then
3087                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-multimaster argument" >&5
3088 echo "$as_me: WARNING: slapd disabled, ignoring --enable-multimaster argument" >&2;}
3089         fi
3090         if test $ol_enable_wrappers = yes ; then
3091                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-wrappers argument" >&5
3092 echo "$as_me: WARNING: slapd disabled, ignoring --enable-wrappers argument" >&2;}
3093         fi
3094         if test $ol_enable_phonetic = yes ; then
3095                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-phonetic argument" >&5
3096 echo "$as_me: WARNING: slapd disabled, ignoring --enable-phonetic argument" >&2;}
3097         fi
3098         if test $ol_enable_rlookups = yes ; then
3099                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-rlookups argument" >&5
3100 echo "$as_me: WARNING: slapd disabled, ignoring --enable-rlookups argument" >&2;}
3101         fi
3102         if test $ol_enable_aci = yes ; then
3103                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-aci argument" >&5
3104 echo "$as_me: WARNING: slapd disabled, ignoring --enable-aci argument" >&2;}
3105         fi
3106         if test $ol_with_ldbm_api != auto ; then
3107                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-ldbm-api argument" >&5
3108 echo "$as_me: WARNING: slapd disabled, ignoring --with-ldbm-api argument" >&2;}
3109         fi
3110         if test $ol_with_ldbm_type != auto ; then
3111                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-ldbm-type argument" >&5
3112 echo "$as_me: WARNING: slapd disabled, ignoring --with-ldbm-type argument" >&2;}
3113         fi
3114         if test $ol_with_bdb_module != static ; then
3115                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-bdb-module argument" >&5
3116 echo "$as_me: WARNING: slapd disabled, ignoring --with-bdb-module argument" >&2;}
3117         fi
3118         if test $ol_with_dnssrv_module != static ; then
3119                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-dnssrv-module argument" >&5
3120 echo "$as_me: WARNING: slapd disabled, ignoring --with-dnssrv-module argument" >&2;}
3121         fi
3122         if test $ol_with_ldap_module != static ; then
3123                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-ldap-module argument" >&5
3124 echo "$as_me: WARNING: slapd disabled, ignoring --with-ldap-module argument" >&2;}
3125         fi
3126         if test $ol_with_ldbm_module != static ; then
3127                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-ldbm-module argument" >&5
3128 echo "$as_me: WARNING: slapd disabled, ignoring --with-ldbm-module argument" >&2;}
3129         fi
3130         if test $ol_with_meta_module != static ; then
3131                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-meta-module argument" >&5
3132 echo "$as_me: WARNING: slapd disabled, ignoring --with-meta-module argument" >&2;}
3133         fi
3134         if test $ol_with_monitor_module != static ; then
3135                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-monitor-module argument" >&5
3136 echo "$as_me: WARNING: slapd disabled, ignoring --with-monitor-module argument" >&2;}
3137         fi
3138         if test $ol_with_null_module != static ; then
3139                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-null-module argument" >&5
3140 echo "$as_me: WARNING: slapd disabled, ignoring --with-null-module argument" >&2;}
3141         fi
3142         if test $ol_with_passwd_module != static ; then
3143                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-passwd-module argument" >&5
3144 echo "$as_me: WARNING: slapd disabled, ignoring --with-passwd-module argument" >&2;}
3145         fi
3146         if test $ol_with_perl_module != static ; then
3147                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-perl-module argument" >&5
3148 echo "$as_me: WARNING: slapd disabled, ignoring --with-perl-module argument" >&2;}
3149         fi
3150         if test $ol_with_shell_module != static ; then
3151                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-shell-module argument" >&5
3152 echo "$as_me: WARNING: slapd disabled, ignoring --with-shell-module argument" >&2;}
3153         fi
3154         if test $ol_with_tcl_module != static ; then
3155                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-tcl-module argument" >&5
3156 echo "$as_me: WARNING: slapd disabled, ignoring --with-tcl-module argument" >&2;}
3157         fi
3158         if test $ol_with_sql_module != static ; then
3159                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --with-sql-module argument" >&5
3160 echo "$as_me: WARNING: slapd disabled, ignoring --with-sql-module argument" >&2;}
3161         fi
3162         if test $ol_enable_slurpd = yes ; then
3163                 { { echo "$as_me:$LINENO: error: slurpd requires slapd" >&5
3164 echo "$as_me: error: slurpd requires slapd" >&2;}
3165    { (exit 1); exit 1; }; }
3166         fi
3167         if test $ol_enable_rewrite = yes ; then
3168                 { echo "$as_me:$LINENO: WARNING: slapd disabled, ignoring --enable-rewrite argument" >&5
3169 echo "$as_me: WARNING: slapd disabled, ignoring --enable-rewrite argument" >&2;}
3170         fi
3171
3172         # force settings to no
3173         ol_enable_slapi=no
3174         ol_enable_bdb=no
3175         ol_enable_dnssrv=no
3176         ol_enable_ldap=no
3177         ol_enable_ldbm=no
3178         ol_enable_meta=no
3179         ol_enable_monitor=no
3180         ol_enable_null=no
3181         ol_enable_passwd=no
3182         ol_enable_perl=no
3183         ol_enable_shell=no
3184         ol_enable_tcl=no
3185         ol_enable_sql=no
3186
3187         ol_enable_modules=no
3188         ol_enable_multimaster=no
3189         ol_enable_phonetic=no
3190         ol_enable_rlookups=no
3191         ol_enable_aci=no
3192         ol_enable_wrappers=no
3193         ol_enable_dynamic=no
3194
3195         ol_with_ldbm_api=no
3196         ol_with_ldbm_type=no
3197
3198         ol_with_bdb_module=static
3199         ol_with_dnssrv_module=static
3200         ol_with_ldap_module=static
3201         ol_with_ldbm_module=static
3202         ol_with_meta_module=static
3203         ol_with_monitor_module=static
3204         ol_with_null_module=static
3205         ol_with_passwd_module=static
3206         ol_with_perl_module=static
3207         ol_with_shell_module=static
3208         ol_with_tcl_module=static
3209         ol_with_sql_module=static
3210
3211         ol_enable_slurpd=no
3212
3213         ol_enable_rewrite=no
3214
3215 elif test $ol_enable_ldbm = no ; then
3216
3217         if test $ol_with_ldbm_api != auto ; then
3218                 { echo "$as_me:$LINENO: WARNING: LDBM disabled, ignoring --with-ldbm-api argument" >&5
3219 echo "$as_me: WARNING: LDBM disabled, ignoring --with-ldbm-api argument" >&2;}
3220         fi
3221
3222         if test $ol_with_ldbm_type != auto ; then
3223                 { echo "$as_me:$LINENO: WARNING: LDBM disabled, ignoring --with-ldbm-type argument" >&5
3224 echo "$as_me: WARNING: LDBM disabled, ignoring --with-ldbm-type argument" >&2;}
3225         fi
3226
3227         if test $ol_with_ldbm_module != static ; then
3228                 { echo "$as_me:$LINENO: WARNING: LDBM disabled, ignoring --with-ldbm-module argument" >&5
3229 echo "$as_me: WARNING: LDBM disabled, ignoring --with-ldbm-module argument" >&2;}
3230         fi
3231
3232         if test $ol_enable_modules != yes -a \
3233                 $ol_enable_bdb = no -a \
3234                 $ol_enable_dnssrv = no -a \
3235                 $ol_enable_ldap = no -a \
3236                 $ol_enable_meta = no -a \
3237                 $ol_enable_monitor = no -a \
3238                 $ol_enable_null = no -a \
3239                 $ol_enable_passwd = no -a \
3240                 $ol_enable_perl = no -a \
3241                 $ol_enable_shell = no -a \
3242                 $ol_enable_sql = no -a \
3243                 $ol_enable_tcl = no ; then
3244
3245                 if test $ol_enable_slapd = yes ; then
3246                         { { echo "$as_me:$LINENO: error: slapd requires a backend" >&5
3247 echo "$as_me: error: slapd requires a backend" >&2;}
3248    { (exit 1); exit 1; }; }
3249                 else
3250                         { echo "$as_me:$LINENO: WARNING: skipping slapd, no backend specified" >&5
3251 echo "$as_me: WARNING: skipping slapd, no backend specified" >&2;}
3252                         ol_enable_slapd=no
3253                 fi
3254         fi
3255
3256         ol_with_ldbm_api=no
3257         ol_with_ldbm_type=no
3258         ol_with_ldbm_module=static
3259
3260         if test $ol_enable_bdb != no ; then
3261                 ol_with_ldbm_api=berkeley
3262         fi
3263
3264 else
3265                 if test $ol_with_ldbm_api = gdbm -a \
3266                 $ol_with_ldbm_type = btree ; then
3267                 { { echo "$as_me:$LINENO: error: GDBM only supports LDBM type hash" >&5
3268 echo "$as_me: error: GDBM only supports LDBM type hash" >&2;}
3269    { (exit 1); exit 1; }; }
3270         fi
3271         if test $ol_with_ldbm_api = mdbm -a \
3272                 $ol_with_ldbm_type = btree ; then
3273                 { { echo "$as_me:$LINENO: error: MDBM only supports LDBM type hash" >&5
3274 echo "$as_me: error: MDBM only supports LDBM type hash" >&2;}
3275    { (exit 1); exit 1; }; }
3276         fi
3277         if test $ol_with_ldbm_api = ndbm -a \
3278                 $ol_with_ldbm_type = btree ; then
3279                 { { echo "$as_me:$LINENO: error: NDBM only supports LDBM type hash" >&5
3280 echo "$as_me: error: NDBM only supports LDBM type hash" >&2;}
3281    { (exit 1); exit 1; }; }
3282         fi
3283
3284         if test $ol_enable_bdb = yes ; then
3285                 if test $ol_with_ldbm_api = auto ; then
3286                         ol_with_ldbm_api=berkeley
3287                 elif test $ol_with_ldbm_api != berkeley ; then
3288                         { { echo "$as_me:$LINENO: error: LDBM API not compatible with BDB" >&5
3289 echo "$as_me: error: LDBM API not compatible with BDB" >&2;}
3290    { (exit 1); exit 1; }; }
3291                 fi
3292
3293         elif test $ol_enable_bdb = auto ; then
3294                 if test $ol_with_ldbm_api != berkeley \
3295                         -o $ol_with_ldbm_api != auto ; then
3296                         { echo "$as_me:$LINENO: WARNING: LDBM API not compatible with BDB, disabling BDB" >&5
3297 echo "$as_me: WARNING: LDBM API not compatible with BDB, disabling BDB" >&2;}
3298                         ol_enable_bdb=no
3299                 fi
3300         fi
3301 fi
3302
3303 if test $ol_enable_slurpd = yes ; then
3304                 if test $ol_with_threads = no ; then
3305                 { { echo "$as_me:$LINENO: error: slurpd requires threads" >&5
3306 echo "$as_me: error: slurpd requires threads" >&2;}
3307    { (exit 1); exit 1; }; }
3308         fi
3309 fi
3310
3311 if test $ol_enable_lmpasswd = yes ; then
3312         if test $ol_with_tls = no ; then
3313                 { { echo "$as_me:$LINENO: error: LAN Manager passwords require OpenSSL" >&5
3314 echo "$as_me: error: LAN Manager passwords require OpenSSL" >&2;}
3315    { (exit 1); exit 1; }; }
3316         fi
3317 fi
3318
3319 if test $ol_enable_kbind = yes -o $ol_enable_kpasswd = yes ; then
3320         if test $ol_with_kerberos = no ; then
3321                 { { echo "$as_me:$LINENO: error: options require --with-kerberos" >&5
3322 echo "$as_me: error: options require --with-kerberos" >&2;}
3323    { (exit 1); exit 1; }; }
3324         elif test $ol_with_kerberos = auto ; then
3325                 ol_with_kerberos=yes
3326         fi
3327
3328 elif test $ol_enable_kbind = no -o $ol_enable_kpasswd = no ; then
3329         if test $ol_with_kerberos = auto ; then
3330                 ol_with_kerberos=no
3331         elif test $ol_with_kerberos != no ; then
3332                 { echo "$as_me:$LINENO: WARNING: Kerberos detection enabled unnecessarily" >&5
3333 echo "$as_me: WARNING: Kerberos detection enabled unnecessarily" >&2;};
3334                 ol_with_kerberos=no
3335         fi
3336 fi
3337
3338 if test $ol_enable_spasswd = yes ; then
3339         if test $ol_with_cyrus_sasl = no ; then
3340                 { { echo "$as_me:$LINENO: error: options require --with-cyrus-sasl" >&5
3341 echo "$as_me: error: options require --with-cyrus-sasl" >&2;}
3342    { (exit 1); exit 1; }; }
3343         fi
3344         ol_with_cyrus_sasl=yes
3345 fi
3346
3347 echo "$as_me:$LINENO: result: done" >&5
3348 echo "${ECHO_T}done" >&6
3349
3350 LDAP_LIBS=
3351 LDIF_LIBS=
3352 LDBM_LIBS=
3353 LTHREAD_LIBS=
3354 LUTIL_LIBS=
3355
3356 SLAPD_LIBS=
3357 SLURPD_LIBS=
3358
3359 BUILD_SLAPD=no
3360 BUILD_SLURPD=no
3361
3362 BUILD_THREAD=no
3363
3364 BUILD_SLAPI=no
3365 SLAPD_SLAPI_DEPEND=
3366
3367 BUILD_BDB=no
3368 BUILD_DNSSRV=no
3369 BUILD_LDAP=no
3370 BUILD_LDBM=no
3371 BUILD_META=no
3372 BUILD_MONITOR=no
3373 BUILD_NULL=no
3374 BUILD_PASSWD=no
3375 BUILD_PERL=no
3376 BUILD_SHELL=no
3377 BUILD_SQL=no
3378 BUILD_TCL=no
3379
3380 BUILD_BDB_DYNAMIC=static
3381 BUILD_DNSSRV_DYNAMIC=static
3382 BUILD_LDAP_DYNAMIC=static
3383 BUILD_LDBM_DYNAMIC=static
3384 BUILD_META_DYNAMIC=static
3385 BUILD_MONITOR_DYNAMIC=static
3386 BUILD_NULL_DYNAMIC=static
3387 BUILD_PASSWD_DYNAMIC=static
3388 BUILD_PERL_DYNAMIC=static
3389 BUILD_SHELL_DYNAMIC=static
3390 BUILD_TCL_DYNAMIC=static
3391 BUILD_SQL_DYNAMIC=static
3392
3393 SLAPD_MODULES_LDFLAGS=
3394 SLAPD_MODULES_CPPFLAGS=
3395
3396 SLAPD_STATIC_BACKENDS=
3397 SLAPD_DYNAMIC_BACKENDS=
3398
3399 SLAPD_PERL_LDFLAGS=
3400 MOD_PERL_LDFLAGS=
3401 PERL_CPPFLAGS=
3402
3403 SLAPD_SQL_LDFLAGS=
3404 SLAPD_SQL_LIBS=
3405 SLAPD_SQL_INCLUDES=
3406
3407 MOD_TCL_LIB=
3408 KRB4_LIBS=
3409 KRB5_LIBS=
3410 READLINE_LIBS=
3411 SASL_LIBS=
3412 TERMCAP_LIBS=
3413 TLS_LIBS=
3414 MODULES_LIBS=
3415 SLAPI_LIBS=
3416 LIBSLAPI=
3417 LIBSLAPITOOLS=
3418 AUTH_LIBS=
3419
3420 SLAPD_SLP_LIBS=
3421
3422
3423 echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3424 echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
3425 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
3426 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
3427   echo $ECHO_N "(cached) $ECHO_C" >&6
3428 else
3429   cat >conftest.make <<\_ACEOF
3430 all:
3431         @echo 'ac_maketemp="$(MAKE)"'
3432 _ACEOF
3433 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3434 eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
3435 if test -n "$ac_maketemp"; then
3436   eval ac_cv_prog_make_${ac_make}_set=yes
3437 else
3438   eval ac_cv_prog_make_${ac_make}_set=no
3439 fi
3440 rm -f conftest.make
3441 fi
3442 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
3443   echo "$as_me:$LINENO: result: yes" >&5
3444 echo "${ECHO_T}yes" >&6
3445   SET_MAKE=
3446 else
3447   echo "$as_me:$LINENO: result: no" >&5
3448 echo "${ECHO_T}no" >&6
3449   SET_MAKE="MAKE=${MAKE-make}"
3450 fi
3451
3452 # Find a good install program.  We prefer a C program (faster),
3453 # so one script is as good as another.  But avoid the broken or
3454 # incompatible versions:
3455 # SysV /etc/install, /usr/sbin/install
3456 # SunOS /usr/etc/install
3457 # IRIX /sbin/install
3458 # AIX /bin/install
3459 # AmigaOS /C/install, which installs bootblocks on floppy discs
3460 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3461 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3462 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3463 # ./install, which can be erroneously created by make from ./install.sh.
3464 echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3465 echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
3466 if test -z "$INSTALL"; then
3467 if test "${ac_cv_path_install+set}" = set; then
3468   echo $ECHO_N "(cached) $ECHO_C" >&6
3469 else
3470   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3471 for as_dir in $PATH
3472 do
3473   IFS=$as_save_IFS
3474   test -z "$as_dir" && as_dir=.
3475   # Account for people who put trailing slashes in PATH elements.
3476 case $as_dir/ in
3477   ./ | .// | /cC/* | \
3478   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3479   /usr/ucb/* ) ;;
3480   *)
3481     # OSF1 and SCO ODT 3.0 have their own names for install.
3482     # Don't use installbsd from OSF since it installs stuff as root
3483     # by default.
3484     for ac_prog in ginstall scoinst install; do
3485       for ac_exec_ext in '' $ac_executable_extensions; do
3486         if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3487           if test $ac_prog = install &&
3488             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3489             # AIX install.  It has an incompatible calling convention.
3490             :
3491           elif test $ac_prog = install &&
3492             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3493             # program-specific install script used by HP pwplus--don't use.
3494             :
3495           else
3496             ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3497             break 3
3498           fi
3499         fi
3500       done
3501     done
3502     ;;
3503 esac
3504 done
3505
3506
3507 fi
3508   if test "${ac_cv_path_install+set}" = set; then
3509     INSTALL=$ac_cv_path_install
3510   else
3511     # As a last resort, use the slow shell script.  We don't cache a
3512     # path for INSTALL within a source directory, because that will
3513     # break other packages using the cache if that directory is
3514     # removed, or if the path is relative.
3515     INSTALL=$ac_install_sh
3516   fi
3517 fi
3518 echo "$as_me:$LINENO: result: $INSTALL" >&5
3519 echo "${ECHO_T}$INSTALL" >&6
3520
3521 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3522 # It thinks the first close brace ends the variable substitution.
3523 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3524
3525 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3526
3527 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3528
3529
3530
3531 cat >>confdefs.h <<\_ACEOF
3532 #define HAVE_MKVERSION 1
3533 _ACEOF
3534
3535
3536
3537
3538 ol_aix_threads=no
3539 case "$target" in
3540 *-*-aix*)       if test -z "$CC" ; then
3541                 case "$ol_with_threads" in
3542                 auto | yes |  posix) ol_aix_threads=yes ;;
3543                 esac
3544         fi
3545 ;;
3546 esac
3547
3548 if test $ol_aix_threads = yes ; then
3549         if test -z "${CC}" ; then
3550                 for ac_prog in cc_r xlc_r cc
3551 do
3552   # Extract the first word of "$ac_prog", so it can be a program name with args.
3553 set dummy $ac_prog; ac_word=$2
3554 echo "$as_me:$LINENO: checking for $ac_word" >&5
3555 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3556 if test "${ac_cv_prog_CC+set}" = set; then
3557   echo $ECHO_N "(cached) $ECHO_C" >&6
3558 else
3559   if test -n "$CC"; then
3560   ac_cv_prog_CC="$CC" # Let the user override the test.
3561 else
3562 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3563 for as_dir in $PATH
3564 do
3565   IFS=$as_save_IFS
3566   test -z "$as_dir" && as_dir=.
3567   for ac_exec_ext in '' $ac_executable_extensions; do
3568   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3569     ac_cv_prog_CC="$ac_prog"
3570     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3571     break 2
3572   fi
3573 done
3574 done
3575
3576 fi
3577 fi
3578 CC=$ac_cv_prog_CC
3579 if test -n "$CC"; then
3580   echo "$as_me:$LINENO: result: $CC" >&5
3581 echo "${ECHO_T}$CC" >&6
3582 else
3583   echo "$as_me:$LINENO: result: no" >&5
3584 echo "${ECHO_T}no" >&6
3585 fi
3586
3587   test -n "$CC" && break
3588 done
3589
3590
3591                 if test "$CC" = cc ; then
3592                                                 if test $ol_with_threads != auto ; then
3593                                 { { echo "$as_me:$LINENO: error: --with-threads requires cc_r (or other suitable compiler) on AIX" >&5
3594 echo "$as_me: error: --with-threads requires cc_r (or other suitable compiler) on AIX" >&2;}
3595    { (exit 1); exit 1; }; }
3596                         else
3597                                 { echo "$as_me:$LINENO: WARNING: disabling threads, no cc_r on AIX" >&5
3598 echo "$as_me: WARNING: disabling threads, no cc_r on AIX" >&2;}
3599                         fi
3600                         ol_with_threads=no
3601                 fi
3602         fi
3603
3604         if test "${CC}" = "cc_r" -o "${CC}" = "xlc_r" ; then
3605                 ol_with_threads=posix
3606                 ol_cv_pthread_create=yes
3607         fi
3608 fi
3609
3610 if test -z "${CC}"; then
3611         for ac_prog in cc gcc
3612 do
3613   # Extract the first word of "$ac_prog", so it can be a program name with args.
3614 set dummy $ac_prog; ac_word=$2
3615 echo "$as_me:$LINENO: checking for $ac_word" >&5
3616 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3617 if test "${ac_cv_prog_CC+set}" = set; then
3618   echo $ECHO_N "(cached) $ECHO_C" >&6
3619 else
3620   if test -n "$CC"; then
3621   ac_cv_prog_CC="$CC" # Let the user override the test.
3622 else
3623 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3624 for as_dir in $PATH
3625 do
3626   IFS=$as_save_IFS
3627   test -z "$as_dir" && as_dir=.
3628   for ac_exec_ext in '' $ac_executable_extensions; do
3629   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3630     ac_cv_prog_CC="$ac_prog"
3631     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3632     break 2
3633   fi
3634 done
3635 done
3636
3637 fi
3638 fi
3639 CC=$ac_cv_prog_CC
3640 if test -n "$CC"; then
3641   echo "$as_me:$LINENO: result: $CC" >&5
3642 echo "${ECHO_T}$CC" >&6
3643 else
3644   echo "$as_me:$LINENO: result: no" >&5
3645 echo "${ECHO_T}no" >&6
3646 fi
3647
3648   test -n "$CC" && break
3649 done
3650 test -n "$CC" || CC="missing"
3651
3652
3653         if test "${CC}" = "missing" ; then
3654                 { { echo "$as_me:$LINENO: error: Unable to locate cc(1) or suitable replacement.  Check PATH or set CC." >&5
3655 echo "$as_me: error: Unable to locate cc(1) or suitable replacement.  Check PATH or set CC." >&2;}
3656    { (exit 1); exit 1; }; }
3657         fi
3658 fi
3659
3660 if test -z "${AR}"; then
3661         for ac_prog in ar gar
3662 do
3663   # Extract the first word of "$ac_prog", so it can be a program name with args.
3664 set dummy $ac_prog; ac_word=$2
3665 echo "$as_me:$LINENO: checking for $ac_word" >&5
3666 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3667 if test "${ac_cv_prog_AR+set}" = set; then
3668   echo $ECHO_N "(cached) $ECHO_C" >&6
3669 else
3670   if test -n "$AR"; then
3671   ac_cv_prog_AR="$AR" # Let the user override the test.
3672 else
3673 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3674 for as_dir in $PATH
3675 do
3676   IFS=$as_save_IFS
3677   test -z "$as_dir" && as_dir=.
3678   for ac_exec_ext in '' $ac_executable_extensions; do
3679   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3680     ac_cv_prog_AR="$ac_prog"
3681     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3682     break 2
3683   fi
3684 done
3685 done
3686
3687 fi
3688 fi
3689 AR=$ac_cv_prog_AR
3690 if test -n "$AR"; then
3691   echo "$as_me:$LINENO: result: $AR" >&5
3692 echo "${ECHO_T}$AR" >&6
3693 else
3694   echo "$as_me:$LINENO: result: no" >&5
3695 echo "${ECHO_T}no" >&6
3696 fi
3697
3698   test -n "$AR" && break
3699 done
3700 test -n "$AR" || AR="missing"
3701
3702
3703         if test "${AR}" = "missing" ; then
3704                 { { echo "$as_me:$LINENO: error: Unable to locate ar(1) or suitable replacement.  Check PATH or set AR." >&5
3705 echo "$as_me: error: Unable to locate ar(1) or suitable replacement.  Check PATH or set AR." >&2;}
3706    { (exit 1); exit 1; }; }
3707         fi
3708 fi
3709
3710
3711
3712 # Check whether --enable-fast-install or --disable-fast-install was given.
3713 if test "${enable_fast_install+set}" = set; then
3714   enableval="$enable_fast_install"
3715   p=${PACKAGE-default}
3716 case $enableval in
3717 yes) enable_fast_install=yes ;;
3718 no) enable_fast_install=no ;;
3719 *)
3720   enable_fast_install=no
3721   # Look at the argument we got.  We use all the common list separators.
3722   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
3723   for pkg in $enableval; do
3724     if test "X$pkg" = "X$p"; then
3725       enable_fast_install=yes
3726     fi
3727   done
3728   IFS="$ac_save_ifs"
3729   ;;
3730 esac
3731 else
3732   enable_fast_install=yes
3733 fi;
3734 ac_ext=c
3735 ac_cpp='$CPP $CPPFLAGS'
3736 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3737 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3738 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3739 if test -n "$ac_tool_prefix"; then
3740   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3741 set dummy ${ac_tool_prefix}gcc; ac_word=$2
3742 echo "$as_me:$LINENO: checking for $ac_word" >&5
3743 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3744 if test "${ac_cv_prog_CC+set}" = set; then
3745   echo $ECHO_N "(cached) $ECHO_C" >&6
3746 else
3747   if test -n "$CC"; then
3748   ac_cv_prog_CC="$CC" # Let the user override the test.
3749 else
3750 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3751 for as_dir in $PATH
3752 do
3753   IFS=$as_save_IFS
3754   test -z "$as_dir" && as_dir=.
3755   for ac_exec_ext in '' $ac_executable_extensions; do
3756   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3757     ac_cv_prog_CC="${ac_tool_prefix}gcc"
3758     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3759     break 2
3760   fi
3761 done
3762 done
3763
3764 fi
3765 fi
3766 CC=$ac_cv_prog_CC
3767 if test -n "$CC"; then
3768   echo "$as_me:$LINENO: result: $CC" >&5
3769 echo "${ECHO_T}$CC" >&6
3770 else
3771   echo "$as_me:$LINENO: result: no" >&5
3772 echo "${ECHO_T}no" >&6
3773 fi
3774
3775 fi
3776 if test -z "$ac_cv_prog_CC"; then
3777   ac_ct_CC=$CC
3778   # Extract the first word of "gcc", so it can be a program name with args.
3779 set dummy gcc; ac_word=$2
3780 echo "$as_me:$LINENO: checking for $ac_word" >&5
3781 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3782 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3783   echo $ECHO_N "(cached) $ECHO_C" >&6
3784 else
3785   if test -n "$ac_ct_CC"; then
3786   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3787 else
3788 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3789 for as_dir in $PATH
3790 do
3791   IFS=$as_save_IFS
3792   test -z "$as_dir" && as_dir=.
3793   for ac_exec_ext in '' $ac_executable_extensions; do
3794   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3795     ac_cv_prog_ac_ct_CC="gcc"
3796     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3797     break 2
3798   fi
3799 done
3800 done
3801
3802 fi
3803 fi
3804 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3805 if test -n "$ac_ct_CC"; then
3806   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3807 echo "${ECHO_T}$ac_ct_CC" >&6
3808 else
3809   echo "$as_me:$LINENO: result: no" >&5
3810 echo "${ECHO_T}no" >&6
3811 fi
3812
3813   CC=$ac_ct_CC
3814 else
3815   CC="$ac_cv_prog_CC"
3816 fi
3817
3818 if test -z "$CC"; then
3819   if test -n "$ac_tool_prefix"; then
3820   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3821 set dummy ${ac_tool_prefix}cc; ac_word=$2
3822 echo "$as_me:$LINENO: checking for $ac_word" >&5
3823 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3824 if test "${ac_cv_prog_CC+set}" = set; then
3825   echo $ECHO_N "(cached) $ECHO_C" >&6
3826 else
3827   if test -n "$CC"; then
3828   ac_cv_prog_CC="$CC" # Let the user override the test.
3829 else
3830 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3831 for as_dir in $PATH
3832 do
3833   IFS=$as_save_IFS
3834   test -z "$as_dir" && as_dir=.
3835   for ac_exec_ext in '' $ac_executable_extensions; do
3836   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3837     ac_cv_prog_CC="${ac_tool_prefix}cc"
3838     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3839     break 2
3840   fi
3841 done
3842 done
3843
3844 fi
3845 fi
3846 CC=$ac_cv_prog_CC
3847 if test -n "$CC"; then
3848   echo "$as_me:$LINENO: result: $CC" >&5
3849 echo "${ECHO_T}$CC" >&6
3850 else
3851   echo "$as_me:$LINENO: result: no" >&5
3852 echo "${ECHO_T}no" >&6
3853 fi
3854
3855 fi
3856 if test -z "$ac_cv_prog_CC"; then
3857   ac_ct_CC=$CC
3858   # Extract the first word of "cc", so it can be a program name with args.
3859 set dummy cc; ac_word=$2
3860 echo "$as_me:$LINENO: checking for $ac_word" >&5
3861 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3862 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3863   echo $ECHO_N "(cached) $ECHO_C" >&6
3864 else
3865   if test -n "$ac_ct_CC"; then
3866   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3867 else
3868 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3869 for as_dir in $PATH
3870 do
3871   IFS=$as_save_IFS
3872   test -z "$as_dir" && as_dir=.
3873   for ac_exec_ext in '' $ac_executable_extensions; do
3874   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3875     ac_cv_prog_ac_ct_CC="cc"
3876     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3877     break 2
3878   fi
3879 done
3880 done
3881
3882 fi
3883 fi
3884 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3885 if test -n "$ac_ct_CC"; then
3886   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3887 echo "${ECHO_T}$ac_ct_CC" >&6
3888 else
3889   echo "$as_me:$LINENO: result: no" >&5
3890 echo "${ECHO_T}no" >&6
3891 fi
3892
3893   CC=$ac_ct_CC
3894 else
3895   CC="$ac_cv_prog_CC"
3896 fi
3897
3898 fi
3899 if test -z "$CC"; then
3900   # Extract the first word of "cc", so it can be a program name with args.
3901 set dummy cc; ac_word=$2
3902 echo "$as_me:$LINENO: checking for $ac_word" >&5
3903 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3904 if test "${ac_cv_prog_CC+set}" = set; then
3905   echo $ECHO_N "(cached) $ECHO_C" >&6
3906 else
3907   if test -n "$CC"; then
3908   ac_cv_prog_CC="$CC" # Let the user override the test.
3909 else
3910   ac_prog_rejected=no
3911 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3912 for as_dir in $PATH
3913 do
3914   IFS=$as_save_IFS
3915   test -z "$as_dir" && as_dir=.
3916   for ac_exec_ext in '' $ac_executable_extensions; do
3917   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3918     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3919        ac_prog_rejected=yes
3920        continue
3921      fi
3922     ac_cv_prog_CC="cc"
3923     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3924     break 2
3925   fi
3926 done
3927 done
3928
3929 if test $ac_prog_rejected = yes; then
3930   # We found a bogon in the path, so make sure we never use it.
3931   set dummy $ac_cv_prog_CC
3932   shift
3933   if test $# != 0; then
3934     # We chose a different compiler from the bogus one.
3935     # However, it has the same basename, so the bogon will be chosen
3936     # first if we set CC to just the basename; use the full file name.
3937     shift
3938     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3939   fi
3940 fi
3941 fi
3942 fi
3943 CC=$ac_cv_prog_CC
3944 if test -n "$CC"; then
3945   echo "$as_me:$LINENO: result: $CC" >&5
3946 echo "${ECHO_T}$CC" >&6
3947 else
3948   echo "$as_me:$LINENO: result: no" >&5
3949 echo "${ECHO_T}no" >&6
3950 fi
3951
3952 fi
3953 if test -z "$CC"; then
3954   if test -n "$ac_tool_prefix"; then
3955   for ac_prog in cl
3956   do
3957     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3958 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3959 echo "$as_me:$LINENO: checking for $ac_word" >&5
3960 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3961 if test "${ac_cv_prog_CC+set}" = set; then
3962   echo $ECHO_N "(cached) $ECHO_C" >&6
3963 else
3964   if test -n "$CC"; then
3965   ac_cv_prog_CC="$CC" # Let the user override the test.
3966 else
3967 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3968 for as_dir in $PATH
3969 do
3970   IFS=$as_save_IFS
3971   test -z "$as_dir" && as_dir=.
3972   for ac_exec_ext in '' $ac_executable_extensions; do
3973   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3974     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3975     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3976     break 2
3977   fi
3978 done
3979 done
3980
3981 fi
3982 fi
3983 CC=$ac_cv_prog_CC
3984 if test -n "$CC"; then
3985   echo "$as_me:$LINENO: result: $CC" >&5
3986 echo "${ECHO_T}$CC" >&6
3987 else
3988   echo "$as_me:$LINENO: result: no" >&5
3989 echo "${ECHO_T}no" >&6
3990 fi
3991
3992     test -n "$CC" && break
3993   done
3994 fi
3995 if test -z "$CC"; then
3996   ac_ct_CC=$CC
3997   for ac_prog in cl
3998 do
3999   # Extract the first word of "$ac_prog", so it can be a program name with args.
4000 set dummy $ac_prog; ac_word=$2
4001 echo "$as_me:$LINENO: checking for $ac_word" >&5
4002 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4003 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
4004   echo $ECHO_N "(cached) $ECHO_C" >&6
4005 else
4006   if test -n "$ac_ct_CC"; then
4007   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4008 else
4009 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4010 for as_dir in $PATH
4011 do
4012   IFS=$as_save_IFS
4013   test -z "$as_dir" && as_dir=.
4014   for ac_exec_ext in '' $ac_executable_extensions; do
4015   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4016     ac_cv_prog_ac_ct_CC="$ac_prog"
4017     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4018     break 2
4019   fi
4020 done
4021 done
4022
4023 fi
4024 fi
4025 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4026 if test -n "$ac_ct_CC"; then
4027   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
4028 echo "${ECHO_T}$ac_ct_CC" >&6
4029 else
4030   echo "$as_me:$LINENO: result: no" >&5
4031 echo "${ECHO_T}no" >&6
4032 fi
4033
4034   test -n "$ac_ct_CC" && break
4035 done
4036
4037   CC=$ac_ct_CC
4038 fi
4039
4040 fi
4041
4042
4043 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
4044 See \`config.log' for more details." >&5
4045 echo "$as_me: error: no acceptable C compiler found in \$PATH
4046 See \`config.log' for more details." >&2;}
4047    { (exit 1); exit 1; }; }
4048
4049 # Provide some information about the compiler.
4050 echo "$as_me:$LINENO:" \
4051      "checking for C compiler version" >&5
4052 ac_compiler=`set X $ac_compile; echo $2`
4053 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
4054   (eval $ac_compiler --version </dev/null >&5) 2>&5
4055   ac_status=$?
4056   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4057   (exit $ac_status); }
4058 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
4059   (eval $ac_compiler -v </dev/null >&5) 2>&5
4060   ac_status=$?
4061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4062   (exit $ac_status); }
4063 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
4064   (eval $ac_compiler -V </dev/null >&5) 2>&5
4065   ac_status=$?
4066   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4067   (exit $ac_status); }
4068
4069 cat >conftest.$ac_ext <<_ACEOF
4070 #line $LINENO "configure"
4071 /* confdefs.h.  */
4072 _ACEOF
4073 cat confdefs.h >>conftest.$ac_ext
4074 cat >>conftest.$ac_ext <<_ACEOF
4075 /* end confdefs.h.  */
4076
4077 int
4078 main ()
4079 {
4080
4081   ;
4082   return 0;
4083 }
4084 _ACEOF
4085 ac_clean_files_save=$ac_clean_files
4086 ac_clean_files="$ac_clean_files a.out a.exe b.out"
4087 # Try to create an executable without -o first, disregard a.out.
4088 # It will help us diagnose broken compilers, and finding out an intuition
4089 # of exeext.
4090 echo "$as_me:$LINENO: checking for C compiler default output" >&5
4091 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
4092 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4093 if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
4094   (eval $ac_link_default) 2>&5
4095   ac_status=$?
4096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4097   (exit $ac_status); }; then
4098   # Find the output, starting from the most likely.  This scheme is
4099 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
4100 # resort.
4101
4102 # Be careful to initialize this variable, since it used to be cached.
4103 # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
4104 ac_cv_exeext=
4105 # b.out is created by i960 compilers.
4106 for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
4107 do
4108   test -f "$ac_file" || continue
4109   case $ac_file in
4110     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
4111         ;;
4112     conftest.$ac_ext )
4113         # This is the source file.
4114         ;;
4115     [ab].out )
4116         # We found the default executable, but exeext='' is most
4117         # certainly right.
4118         break;;
4119     *.* )
4120         ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4121         # FIXME: I believe we export ac_cv_exeext for Libtool,
4122         # but it would be cool to find out if it's true.  Does anybody
4123         # maintain Libtool? --akim.
4124         export ac_cv_exeext
4125         break;;
4126     * )
4127         break;;
4128   esac
4129 done
4130 else
4131   echo "$as_me: failed program was:" >&5
4132 sed 's/^/| /' conftest.$ac_ext >&5
4133
4134 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
4135 See \`config.log' for more details." >&5
4136 echo "$as_me: error: C compiler cannot create executables
4137 See \`config.log' for more details." >&2;}
4138    { (exit 77); exit 77; }; }
4139 fi
4140
4141 ac_exeext=$ac_cv_exeext
4142 echo "$as_me:$LINENO: result: $ac_file" >&5
4143 echo "${ECHO_T}$ac_file" >&6
4144
4145 # Check the compiler produces executables we can run.  If not, either
4146 # the compiler is broken, or we cross compile.
4147 echo "$as_me:$LINENO: checking whether the C compiler works" >&5
4148 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
4149 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
4150 # If not cross compiling, check that we can run a simple program.
4151 if test "$cross_compiling" != yes; then
4152   if { ac_try='./$ac_file'
4153   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4154   (eval $ac_try) 2>&5
4155   ac_status=$?
4156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4157   (exit $ac_status); }; }; then
4158     cross_compiling=no
4159   else
4160     if test "$cross_compiling" = maybe; then
4161         cross_compiling=yes
4162     else
4163         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
4164 If you meant to cross compile, use \`--host'.
4165 See \`config.log' for more details." >&5
4166 echo "$as_me: error: cannot run C compiled programs.
4167 If you meant to cross compile, use \`--host'.
4168 See \`config.log' for more details." >&2;}
4169    { (exit 1); exit 1; }; }
4170     fi
4171   fi
4172 fi
4173 echo "$as_me:$LINENO: result: yes" >&5
4174 echo "${ECHO_T}yes" >&6
4175
4176 rm -f a.out a.exe conftest$ac_cv_exeext b.out
4177 ac_clean_files=$ac_clean_files_save
4178 # Check the compiler produces executables we can run.  If not, either
4179 # the compiler is broken, or we cross compile.
4180 echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
4181 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
4182 echo "$as_me:$LINENO: result: $cross_compiling" >&5
4183 echo "${ECHO_T}$cross_compiling" >&6
4184
4185 echo "$as_me:$LINENO: checking for suffix of executables" >&5
4186 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
4187 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4188   (eval $ac_link) 2>&5
4189   ac_status=$?
4190   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4191   (exit $ac_status); }; then
4192   # If both `conftest.exe' and `conftest' are `present' (well, observable)
4193 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
4194 # work properly (i.e., refer to `conftest.exe'), while it won't with
4195 # `rm'.
4196 for ac_file in conftest.exe conftest conftest.*; do
4197   test -f "$ac_file" || continue
4198   case $ac_file in
4199     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
4200     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4201           export ac_cv_exeext
4202           break;;
4203     * ) break;;
4204   esac
4205 done
4206 else
4207   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
4208 See \`config.log' for more details." >&5
4209 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
4210 See \`config.log' for more details." >&2;}
4211    { (exit 1); exit 1; }; }
4212 fi
4213
4214 rm -f conftest$ac_cv_exeext
4215 echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
4216 echo "${ECHO_T}$ac_cv_exeext" >&6
4217
4218 rm -f conftest.$ac_ext
4219 EXEEXT=$ac_cv_exeext
4220 ac_exeext=$EXEEXT
4221 echo "$as_me:$LINENO: checking for suffix of object files" >&5
4222 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
4223 if test "${ac_cv_objext+set}" = set; then
4224   echo $ECHO_N "(cached) $ECHO_C" >&6
4225 else
4226   cat >conftest.$ac_ext <<_ACEOF
4227 #line $LINENO "configure"
4228 /* confdefs.h.  */
4229 _ACEOF
4230 cat confdefs.h >>conftest.$ac_ext
4231 cat >>conftest.$ac_ext <<_ACEOF
4232 /* end confdefs.h.  */
4233
4234 int
4235 main ()
4236 {
4237
4238   ;
4239   return 0;
4240 }
4241 _ACEOF
4242 rm -f conftest.o conftest.obj
4243 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4244   (eval $ac_compile) 2>&5
4245   ac_status=$?
4246   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4247   (exit $ac_status); }; then
4248   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
4249   case $ac_file in
4250     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
4251     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4252        break;;
4253   esac
4254 done
4255 else
4256   echo "$as_me: failed program was:" >&5
4257 sed 's/^/| /' conftest.$ac_ext >&5
4258
4259 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
4260 See \`config.log' for more details." >&5
4261 echo "$as_me: error: cannot compute suffix of object files: cannot compile
4262 See \`config.log' for more details." >&2;}
4263    { (exit 1); exit 1; }; }
4264 fi
4265
4266 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4267 fi
4268 echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
4269 echo "${ECHO_T}$ac_cv_objext" >&6
4270 OBJEXT=$ac_cv_objext
4271 ac_objext=$OBJEXT
4272 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
4273 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
4274 if test "${ac_cv_c_compiler_gnu+set}" = set; then
4275   echo $ECHO_N "(cached) $ECHO_C" >&6
4276 else
4277   cat >conftest.$ac_ext <<_ACEOF
4278 #line $LINENO "configure"
4279 /* confdefs.h.  */
4280 _ACEOF
4281 cat confdefs.h >>conftest.$ac_ext
4282 cat >>conftest.$ac_ext <<_ACEOF
4283 /* end confdefs.h.  */
4284
4285 int
4286 main ()
4287 {
4288 #ifndef __GNUC__
4289        choke me
4290 #endif
4291
4292   ;
4293   return 0;
4294 }
4295 _ACEOF
4296 rm -f conftest.$ac_objext
4297 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4298   (eval $ac_compile) 2>&5
4299   ac_status=$?
4300   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4301   (exit $ac_status); } &&
4302          { ac_try='test -s conftest.$ac_objext'
4303   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4304   (eval $ac_try) 2>&5
4305   ac_status=$?
4306   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4307   (exit $ac_status); }; }; then
4308   ac_compiler_gnu=yes
4309 else
4310   echo "$as_me: failed program was:" >&5
4311 sed 's/^/| /' conftest.$ac_ext >&5
4312
4313 ac_compiler_gnu=no
4314 fi
4315 rm -f conftest.$ac_objext conftest.$ac_ext
4316 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4317
4318 fi
4319 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
4320 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
4321 GCC=`test $ac_compiler_gnu = yes && echo yes`
4322 ac_test_CFLAGS=${CFLAGS+set}
4323 ac_save_CFLAGS=$CFLAGS
4324 CFLAGS="-g"
4325 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
4326 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
4327 if test "${ac_cv_prog_cc_g+set}" = set; then
4328   echo $ECHO_N "(cached) $ECHO_C" >&6
4329 else
4330   cat >conftest.$ac_ext <<_ACEOF
4331 #line $LINENO "configure"
4332 /* confdefs.h.  */
4333 _ACEOF
4334 cat confdefs.h >>conftest.$ac_ext
4335 cat >>conftest.$ac_ext <<_ACEOF
4336 /* end confdefs.h.  */
4337
4338 int
4339 main ()
4340 {
4341
4342   ;
4343   return 0;
4344 }
4345 _ACEOF
4346 rm -f conftest.$ac_objext
4347 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4348   (eval $ac_compile) 2>&5
4349   ac_status=$?
4350   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4351   (exit $ac_status); } &&
4352          { ac_try='test -s conftest.$ac_objext'
4353   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4354   (eval $ac_try) 2>&5
4355   ac_status=$?
4356   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4357   (exit $ac_status); }; }; then
4358   ac_cv_prog_cc_g=yes
4359 else
4360   echo "$as_me: failed program was:" >&5
4361 sed 's/^/| /' conftest.$ac_ext >&5
4362
4363 ac_cv_prog_cc_g=no
4364 fi
4365 rm -f conftest.$ac_objext conftest.$ac_ext
4366 fi
4367 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
4368 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
4369 if test "$ac_test_CFLAGS" = set; then
4370   CFLAGS=$ac_save_CFLAGS
4371 elif test $ac_cv_prog_cc_g = yes; then
4372   if test "$GCC" = yes; then
4373     CFLAGS="-g -O2"
4374   else
4375     CFLAGS="-g"
4376   fi
4377 else
4378   if test "$GCC" = yes; then
4379     CFLAGS="-O2"
4380   else
4381     CFLAGS=
4382   fi
4383 fi
4384 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
4385 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
4386 if test "${ac_cv_prog_cc_stdc+set}" = set; then
4387   echo $ECHO_N "(cached) $ECHO_C" >&6
4388 else
4389   ac_cv_prog_cc_stdc=no
4390 ac_save_CC=$CC
4391 cat >conftest.$ac_ext <<_ACEOF
4392 #line $LINENO "configure"
4393 /* confdefs.h.  */
4394 _ACEOF
4395 cat confdefs.h >>conftest.$ac_ext
4396 cat >>conftest.$ac_ext <<_ACEOF
4397 /* end confdefs.h.  */
4398 #include <stdarg.h>
4399 #include <stdio.h>
4400 #include <sys/types.h>
4401 #include <sys/stat.h>
4402 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4403 struct buf { int x; };
4404 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4405 static char *e (p, i)
4406      char **p;
4407      int i;
4408 {
4409   return p[i];
4410 }
4411 static char *f (char * (*g) (char **, int), char **p, ...)
4412 {
4413   char *s;
4414   va_list v;
4415   va_start (v,p);
4416   s = g (p, va_arg (v,int));
4417   va_end (v);
4418   return s;
4419 }
4420 int test (int i, double x);
4421 struct s1 {int (*f) (int a);};
4422 struct s2 {int (*f) (double a);};
4423 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4424 int argc;
4425 char **argv;
4426 int
4427 main ()
4428 {
4429 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4430   ;
4431   return 0;
4432 }
4433 _ACEOF
4434 # Don't try gcc -ansi; that turns off useful extensions and
4435 # breaks some systems' header files.
4436 # AIX                   -qlanglvl=ansi
4437 # Ultrix and OSF/1      -std1
4438 # HP-UX 10.20 and later -Ae
4439 # HP-UX older versions  -Aa -D_HPUX_SOURCE
4440 # SVR4                  -Xc -D__EXTENSIONS__
4441 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4442 do
4443   CC="$ac_save_CC $ac_arg"
4444   rm -f conftest.$ac_objext
4445 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4446   (eval $ac_compile) 2>&5
4447   ac_status=$?
4448   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4449   (exit $ac_status); } &&
4450          { ac_try='test -s conftest.$ac_objext'
4451   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4452   (eval $ac_try) 2>&5
4453   ac_status=$?
4454   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4455   (exit $ac_status); }; }; then
4456   ac_cv_prog_cc_stdc=$ac_arg
4457 break
4458 else
4459   echo "$as_me: failed program was:" >&5
4460 sed 's/^/| /' conftest.$ac_ext >&5
4461
4462 fi
4463 rm -f conftest.$ac_objext
4464 done
4465 rm -f conftest.$ac_ext conftest.$ac_objext
4466 CC=$ac_save_CC
4467
4468 fi
4469
4470 case "x$ac_cv_prog_cc_stdc" in
4471   x|xno)
4472     echo "$as_me:$LINENO: result: none needed" >&5
4473 echo "${ECHO_T}none needed" >&6 ;;
4474   *)
4475     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
4476 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
4477     CC="$CC $ac_cv_prog_cc_stdc" ;;
4478 esac
4479
4480 # Some people use a C++ compiler to compile C.  Since we use `exit',
4481 # in C++ we need to declare it.  In case someone uses the same compiler
4482 # for both compiling C and C++ we need to have the C++ compiler decide
4483 # the declaration of exit, since it's the most demanding environment.
4484 cat >conftest.$ac_ext <<_ACEOF
4485 #ifndef __cplusplus
4486   choke me
4487 #endif
4488 _ACEOF
4489 rm -f conftest.$ac_objext
4490 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4491   (eval $ac_compile) 2>&5
4492   ac_status=$?
4493   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4494   (exit $ac_status); } &&
4495          { ac_try='test -s conftest.$ac_objext'
4496   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4497   (eval $ac_try) 2>&5
4498   ac_status=$?
4499   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4500   (exit $ac_status); }; }; then
4501   for ac_declaration in \
4502    ''\
4503    '#include <stdlib.h>' \
4504    'extern "C" void std::exit (int) throw (); using std::exit;' \
4505    'extern "C" void std::exit (int); using std::exit;' \
4506    'extern "C" void exit (int) throw ();' \
4507    'extern "C" void exit (int);' \
4508    'void exit (int);'
4509 do
4510   cat >conftest.$ac_ext <<_ACEOF
4511 #line $LINENO "configure"
4512 /* confdefs.h.  */
4513 _ACEOF
4514 cat confdefs.h >>conftest.$ac_ext
4515 cat >>conftest.$ac_ext <<_ACEOF
4516 /* end confdefs.h.  */
4517 #include <stdlib.h>
4518 $ac_declaration
4519 int
4520 main ()
4521 {
4522 exit (42);
4523   ;
4524   return 0;
4525 }
4526 _ACEOF
4527 rm -f conftest.$ac_objext
4528 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4529   (eval $ac_compile) 2>&5
4530   ac_status=$?
4531   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4532   (exit $ac_status); } &&
4533          { ac_try='test -s conftest.$ac_objext'
4534   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4535   (eval $ac_try) 2>&5
4536   ac_status=$?
4537   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4538   (exit $ac_status); }; }; then
4539   :
4540 else
4541   echo "$as_me: failed program was:" >&5
4542 sed 's/^/| /' conftest.$ac_ext >&5
4543
4544 continue
4545 fi
4546 rm -f conftest.$ac_objext conftest.$ac_ext
4547   cat >conftest.$ac_ext <<_ACEOF
4548 #line $LINENO "configure"
4549 /* confdefs.h.  */
4550 _ACEOF
4551 cat confdefs.h >>conftest.$ac_ext
4552 cat >>conftest.$ac_ext <<_ACEOF
4553 /* end confdefs.h.  */
4554 $ac_declaration
4555 int
4556 main ()
4557 {
4558 exit (42);
4559   ;
4560   return 0;
4561 }
4562 _ACEOF
4563 rm -f conftest.$ac_objext
4564 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4565   (eval $ac_compile) 2>&5
4566   ac_status=$?
4567   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4568   (exit $ac_status); } &&
4569          { ac_try='test -s conftest.$ac_objext'
4570   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4571   (eval $ac_try) 2>&5
4572   ac_status=$?
4573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4574   (exit $ac_status); }; }; then
4575   break
4576 else
4577   echo "$as_me: failed program was:" >&5
4578 sed 's/^/| /' conftest.$ac_ext >&5
4579
4580 fi
4581 rm -f conftest.$ac_objext conftest.$ac_ext
4582 done
4583 rm -f conftest*
4584 if test -n "$ac_declaration"; then
4585   echo '#ifdef __cplusplus' >>confdefs.h
4586   echo $ac_declaration      >>confdefs.h
4587   echo '#endif'             >>confdefs.h
4588 fi
4589
4590 else
4591   echo "$as_me: failed program was:" >&5
4592 sed 's/^/| /' conftest.$ac_ext >&5
4593
4594 fi
4595 rm -f conftest.$ac_objext conftest.$ac_ext
4596 ac_ext=c
4597 ac_cpp='$CPP $CPPFLAGS'
4598 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4599 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4600 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4601
4602 # Find the correct PATH separator.  Usually this is `:', but
4603 # DJGPP uses `;' like DOS.
4604 if test "X${PATH_SEPARATOR+set}" != Xset; then
4605   UNAME=${UNAME-`uname 2>/dev/null`}
4606   case X$UNAME in
4607     *-DOS) lt_cv_sys_path_separator=';' ;;
4608     *)     lt_cv_sys_path_separator=':' ;;
4609   esac
4610   PATH_SEPARATOR=$lt_cv_sys_path_separator
4611 fi
4612
4613
4614 # Check whether --with-gnu-ld or --without-gnu-ld was given.
4615 if test "${with_gnu_ld+set}" = set; then
4616   withval="$with_gnu_ld"
4617   test "$withval" = no || with_gnu_ld=yes
4618 else
4619   with_gnu_ld=no
4620 fi;
4621 ac_prog=ld
4622 if test "$GCC" = yes; then
4623   # Check if gcc -print-prog-name=ld gives a path.
4624   echo "$as_me:$LINENO: checking for ld used by GCC" >&5
4625 echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6
4626   case $host in
4627   *-*-mingw*)
4628     # gcc leaves a trailing carriage return which upsets mingw
4629     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
4630   *)
4631     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
4632   esac
4633   case $ac_prog in
4634     # Accept absolute paths.
4635     [\\/]* | [A-Za-z]:[\\/]*)
4636       re_direlt='/[^/][^/]*/\.\./'
4637       # Canonicalize the path of ld
4638       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
4639       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
4640         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
4641       done
4642       test -z "$LD" && LD="$ac_prog"
4643       ;;
4644   "")
4645     # If it fails, then pretend we aren't using GCC.
4646     ac_prog=ld
4647     ;;
4648   *)
4649     # If it is relative, then search for the first ld in PATH.
4650     with_gnu_ld=unknown
4651     ;;
4652   esac
4653 elif test "$with_gnu_ld" = yes; then
4654   echo "$as_me:$LINENO: checking for GNU ld" >&5
4655 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
4656 else
4657   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
4658 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
4659 fi
4660 if test "${lt_cv_path_LD+set}" = set; then
4661   echo $ECHO_N "(cached) $ECHO_C" >&6
4662 else
4663   if test -z "$LD"; then
4664   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4665   for ac_dir in $PATH; do
4666     test -z "$ac_dir" && ac_dir=.
4667     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
4668       lt_cv_path_LD="$ac_dir/$ac_prog"
4669       # Check to see if the program is GNU ld.  I'd rather use --version,
4670       # but apparently some GNU ld's only accept -v.
4671       # Break only if it was the GNU/non-GNU ld that we prefer.
4672       if "$lt_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
4673         test "$with_gnu_ld" != no && break
4674       else
4675         test "$with_gnu_ld" != yes && break
4676       fi
4677     fi
4678   done
4679   IFS="$ac_save_ifs"
4680 else
4681   lt_cv_path_LD="$LD" # Let the user override the test with a path.
4682 fi
4683 fi
4684
4685 LD="$lt_cv_path_LD"
4686 if test -n "$LD"; then
4687   echo "$as_me:$LINENO: result: $LD" >&5
4688 echo "${ECHO_T}$LD" >&6
4689 else
4690   echo "$as_me:$LINENO: result: no" >&5
4691 echo "${ECHO_T}no" >&6
4692 fi
4693 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
4694 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
4695    { (exit 1); exit 1; }; }
4696 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
4697 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
4698 if test "${lt_cv_prog_gnu_ld+set}" = set; then
4699   echo $ECHO_N "(cached) $ECHO_C" >&6
4700 else
4701   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
4702 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
4703   lt_cv_prog_gnu_ld=yes
4704 else
4705   lt_cv_prog_gnu_ld=no
4706 fi
4707 fi
4708 echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
4709 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6
4710 with_gnu_ld=$lt_cv_prog_gnu_ld
4711
4712
4713 echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5
4714 echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6
4715 if test "${lt_cv_ld_reload_flag+set}" = set; then
4716   echo $ECHO_N "(cached) $ECHO_C" >&6
4717 else
4718   lt_cv_ld_reload_flag='-r'
4719 fi
4720 echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5
4721 echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6
4722 reload_flag=$lt_cv_ld_reload_flag
4723 test -n "$reload_flag" && reload_flag=" $reload_flag"
4724
4725 echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
4726 echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6
4727 if test "${lt_cv_path_NM+set}" = set; then
4728   echo $ECHO_N "(cached) $ECHO_C" >&6
4729 else
4730   if test -n "$NM"; then
4731   # Let the user override the test.
4732   lt_cv_path_NM="$NM"
4733 else
4734   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4735   for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
4736     test -z "$ac_dir" && ac_dir=.
4737     tmp_nm=$ac_dir/${ac_tool_prefix}nm
4738     if test -f $tmp_nm || test -f $tmp_nm$ac_exeext ; then
4739       # Check to see if the nm accepts a BSD-compat flag.
4740       # Adding the `sed 1q' prevents false positives on HP-UX, which says:
4741       #   nm: unknown option "B" ignored
4742       # Tru64's nm complains that /dev/null is an invalid object file
4743       if ($tmp_nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep '(/dev/null|Invalid file or object type)' >/dev/null; then
4744         lt_cv_path_NM="$tmp_nm -B"
4745         break
4746       elif ($tmp_nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
4747         lt_cv_path_NM="$tmp_nm -p"
4748         break
4749       else
4750         lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
4751         continue # so that we can try to find one that supports BSD flags
4752       fi
4753     fi
4754   done
4755   IFS="$ac_save_ifs"
4756   test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
4757 fi
4758 fi
4759
4760 NM="$lt_cv_path_NM"
4761 echo "$as_me:$LINENO: result: $NM" >&5
4762 echo "${ECHO_T}$NM" >&6
4763
4764 echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5
4765 echo $ECHO_N "checking for a sed that does not truncate output... $ECHO_C" >&6
4766 if test "${lt_cv_path_SED+set}" = set; then
4767   echo $ECHO_N "(cached) $ECHO_C" >&6
4768 else
4769   # Loop through the user's path and test for sed and gsed.
4770 # Then use that list of sed's as ones to test for truncation.
4771 as_executable_p="test -f"
4772 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4773 for as_dir in $PATH
4774 do
4775   IFS=$as_save_IFS
4776   test -z "$as_dir" && as_dir=.
4777   for ac_prog in sed gsed; do
4778     for ac_exec_ext in '' $ac_executable_extensions; do
4779       if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
4780         _sed_list="$_sed_list $as_dir/$ac_prog$ac_exec_ext"
4781       fi
4782     done
4783   done
4784 done
4785
4786   # Create a temporary directory, and hook for its removal unless debugging.
4787 $debug ||
4788 {
4789   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
4790   trap '{ (exit 1); exit 1; }' 1 2 13 15
4791 }
4792
4793 # Create a (secure) tmp directory for tmp files.
4794 : ${TMPDIR=/tmp}
4795 {
4796   tmp=`(umask 077 && mktemp -d -q "$TMPDIR/sedXXXXXX") 2>/dev/null` &&
4797   test -n "$tmp" && test -d "$tmp"
4798 }  ||
4799 {
4800   tmp=$TMPDIR/sed$$-$RANDOM
4801   (umask 077 && mkdir $tmp)
4802 } ||
4803 {
4804    echo "$me: cannot create a temporary directory in $TMPDIR" >&2
4805    { (exit 1); exit 1; }
4806 }
4807   _max=0
4808   _count=0
4809   # Add /usr/xpg4/bin/sed as it is typically found on Solaris
4810   # along with /bin/sed that truncates output.
4811   for _sed in $_sed_list /usr/xpg4/bin/sed; do
4812     test ! -f ${_sed} && break
4813     cat /dev/null > "$tmp/sed.in"
4814     _count=0
4815     echo ${ECHO_N-$ac_n} "0123456789${ECHO_C-$ac_c}" >"$tmp/sed.in"
4816     # Check for GNU sed and select it if it is found.
4817     if "${_sed}" --version 2>&1 < /dev/null | egrep '(GNU)' > /dev/null; then
4818       lt_cv_path_SED=${_sed}
4819       break
4820     fi
4821     while true; do
4822       cat "$tmp/sed.in" "$tmp/sed.in" >"$tmp/sed.tmp"
4823       mv "$tmp/sed.tmp" "$tmp/sed.in"
4824       cp "$tmp/sed.in" "$tmp/sed.nl"
4825       echo >>"$tmp/sed.nl"
4826       ${_sed} -e 's/a$//' < "$tmp/sed.nl" >"$tmp/sed.out" || break
4827       cmp -s "$tmp/sed.out" "$tmp/sed.nl" || break
4828       # 40000 chars as input seems more than enough
4829       test $_count -gt 10 && break
4830       _count=`expr $_count + 1`
4831       if test $_count -gt $_max; then
4832         _max=$_count
4833         lt_cv_path_SED=$_sed
4834       fi
4835     done
4836   done
4837   rm -rf "$tmp"
4838
4839 fi
4840
4841 if test "X$SED" != "X"; then
4842   lt_cv_path_SED=$SED
4843 else
4844   SED=$lt_cv_path_SED
4845 fi
4846 echo "$as_me:$LINENO: result: $SED" >&5
4847 echo "${ECHO_T}$SED" >&6
4848
4849 echo "$as_me:$LINENO: checking whether ln -s works" >&5
4850 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
4851 LN_S=$as_ln_s
4852 if test "$LN_S" = "ln -s"; then
4853   echo "$as_me:$LINENO: result: yes" >&5
4854 echo "${ECHO_T}yes" >&6
4855 else
4856   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
4857 echo "${ECHO_T}no, using $LN_S" >&6
4858 fi
4859
4860 echo "$as_me:$LINENO: checking how to recognise dependent libraries" >&5
4861 echo $ECHO_N "checking how to recognise dependent libraries... $ECHO_C" >&6
4862 if test "${lt_cv_deplibs_check_method+set}" = set; then
4863   echo $ECHO_N "(cached) $ECHO_C" >&6
4864 else
4865   lt_cv_file_magic_cmd='$MAGIC_CMD'
4866 lt_cv_file_magic_test_file=
4867 lt_cv_deplibs_check_method='unknown'
4868 # Need to set the preceding variable on all platforms that support
4869 # interlibrary dependencies.
4870 # 'none' -- dependencies not supported.
4871 # `unknown' -- same as none, but documents that we really don't know.
4872 # 'pass_all' -- all dependencies passed with no checks.
4873 # 'test_compile' -- check by making test program.
4874 # 'file_magic [[regex]]' -- check by looking for files in library path
4875 # which responds to the $file_magic_cmd with a given egrep regex.
4876 # If you have `file' or equivalent on your system and you're not sure
4877 # whether `pass_all' will *always* work, you probably want this one.
4878
4879 case $host_os in
4880 aix4* | aix5*)
4881   lt_cv_deplibs_check_method=pass_all
4882   ;;
4883
4884 beos*)
4885   lt_cv_deplibs_check_method=pass_all
4886   ;;
4887
4888 bsdi4*)
4889   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
4890   lt_cv_file_magic_cmd='/usr/bin/file -L'
4891   lt_cv_file_magic_test_file=/shlib/libc.so
4892   ;;
4893
4894 cygwin* | mingw* | pw32*)
4895   lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
4896   lt_cv_file_magic_cmd='$OBJDUMP -f'
4897   ;;
4898
4899 darwin* | rhapsody*)
4900   lt_cv_deplibs_check_method='file_magic Mach-O dynamically linked shared library'
4901   lt_cv_file_magic_cmd='/usr/bin/file -L'
4902   case "$host_os" in
4903   rhapsody* | darwin1.[012])
4904     lt_cv_file_magic_test_file=`echo /System/Library/Frameworks/System.framework/Versions/*/System | head -1`
4905     ;;
4906   *) # Darwin 1.3 on
4907     lt_cv_file_magic_test_file='/usr/lib/libSystem.dylib'
4908     ;;
4909   esac
4910   ;;
4911
4912 freebsd*)
4913   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
4914     case $host_cpu in
4915     i*86 )
4916       # Not sure whether the presence of OpenBSD here was a mistake.
4917       # Let's accept both of them until this is cleared up.
4918       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library'
4919       lt_cv_file_magic_cmd=/usr/bin/file
4920       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
4921       ;;
4922     esac
4923   else
4924     lt_cv_deplibs_check_method=pass_all
4925   fi
4926   ;;
4927
4928 gnu*)
4929   lt_cv_deplibs_check_method=pass_all
4930   ;;
4931
4932 hpux10.20*|hpux11*)
4933   lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
4934   lt_cv_file_magic_cmd=/usr/bin/file
4935   lt_cv_file_magic_test_file=/usr/lib/libc.sl
4936   ;;
4937
4938 irix5* | irix6* | nonstopux*)
4939   case $host_os in
4940   irix5* | nonstopux*)
4941     # this will be overridden with pass_all, but let us keep it just in case
4942     lt_cv_deplibs_check_method="file_magic ELF 32-bit MSB dynamic lib MIPS - version 1"
4943     ;;
4944   *)
4945     case $LD in
4946     *-32|*"-32 ") libmagic=32-bit;;
4947     *-n32|*"-n32 ") libmagic=N32;;
4948     *-64|*"-64 ") libmagic=64-bit;;
4949     *) libmagic=never-match;;
4950     esac
4951     # this will be overridden with pass_all, but let us keep it just in case
4952     lt_cv_deplibs_check_method="file_magic ELF ${libmagic} MSB mips-[1234] dynamic lib MIPS - version 1"
4953     ;;
4954   esac
4955   lt_cv_file_magic_test_file=`echo /lib${libsuff}/libc.so*`
4956   lt_cv_deplibs_check_method=pass_all
4957   ;;
4958
4959 # This must be Linux ELF.
4960 linux-gnu*)
4961   case $host_cpu in
4962   alpha* | hppa* | i*86 | mips | mipsel | powerpc* | sparc* | ia64*)
4963     lt_cv_deplibs_check_method=pass_all ;;
4964   *)
4965     # glibc up to 2.1.1 does not perform some relocations on ARM
4966     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;;
4967   esac
4968   lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
4969   ;;
4970
4971 netbsd*)
4972   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
4973     lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'
4974   else
4975     lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so$'
4976   fi
4977   ;;
4978
4979 newos6*)
4980   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
4981   lt_cv_file_magic_cmd=/usr/bin/file
4982   lt_cv_file_magic_test_file=/usr/lib/libnls.so
4983   ;;
4984
4985 openbsd*)
4986   lt_cv_file_magic_cmd=/usr/bin/file
4987   lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
4988   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
4989     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB shared object'
4990   else
4991     lt_cv_deplibs_check_method='file_magic OpenBSD.* shared library'
4992   fi
4993   ;;
4994
4995 osf3* | osf4* | osf5*)
4996   # this will be overridden with pass_all, but let us keep it just in case
4997   lt_cv_deplibs_check_method='file_magic COFF format alpha shared library'
4998   lt_cv_file_magic_test_file=/shlib/libc.so
4999   lt_cv_deplibs_check_method=pass_all
5000   ;;
5001
5002 sco3.2v5*)
5003   lt_cv_deplibs_check_method=pass_all
5004   ;;
5005
5006 solaris*)
5007   lt_cv_deplibs_check_method=pass_all
5008   lt_cv_file_magic_test_file=/lib/libc.so
5009   ;;
5010
5011 sysv5uw[78]* | sysv4*uw2*)
5012   lt_cv_deplibs_check_method=pass_all
5013   ;;
5014
5015 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5016   case $host_vendor in
5017   motorola)
5018     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]'
5019     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
5020     ;;
5021   ncr)
5022     lt_cv_deplibs_check_method=pass_all
5023     ;;
5024   sequent)
5025     lt_cv_file_magic_cmd='/bin/file'
5026     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
5027     ;;
5028   sni)
5029     lt_cv_file_magic_cmd='/bin/file'
5030     lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
5031     lt_cv_file_magic_test_file=/lib/libc.so
5032     ;;
5033   siemens)
5034     lt_cv_deplibs_check_method=pass_all
5035     ;;
5036   esac
5037   ;;
5038 esac
5039
5040 fi
5041 echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5
5042 echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6
5043 file_magic_cmd=$lt_cv_file_magic_cmd
5044 deplibs_check_method=$lt_cv_deplibs_check_method
5045
5046
5047
5048
5049
5050
5051
5052
5053 # Check for command to grab the raw symbol name followed by C symbol from nm.
5054 echo "$as_me:$LINENO: checking command to parse $NM output" >&5
5055 echo $ECHO_N "checking command to parse $NM output... $ECHO_C" >&6
5056 if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then
5057   echo $ECHO_N "(cached) $ECHO_C" >&6
5058 else
5059
5060 # These are sane defaults that work on at least a few old systems.
5061 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
5062
5063 # Character class describing NM global symbol codes.
5064 symcode='[BCDEGRST]'
5065
5066 # Regexp to match symbols that can be accessed directly from C.
5067 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
5068
5069 # Transform the above into a raw symbol and a C symbol.
5070 symxfrm='\1 \2\3 \3'
5071
5072 # Transform an extracted symbol line into a proper C declaration
5073 lt_cv_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern char \1;/p'"
5074
5075 # Transform an extracted symbol line into symbol name and symbol address
5076 lt_cv_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([^ ]*\) \([^ ]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
5077
5078 # Define system-specific variables.
5079 case $host_os in
5080 aix*)
5081   symcode='[BCDT]'
5082   ;;
5083 cygwin* | mingw* | pw32*)
5084   symcode='[ABCDGISTW]'
5085   ;;
5086 hpux*) # Its linker distinguishes data from code symbols
5087   lt_cv_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern char \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5088   lt_cv_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
5089   ;;
5090 irix* | nonstopux*)
5091   symcode='[BCDEGRST]'
5092   ;;
5093 osf*)
5094   symcode='[BCDEGQRST]'
5095   ;;
5096 solaris* | sysv5*)
5097   symcode='[BDT]'
5098   ;;
5099 sysv4)
5100   symcode='[DFNSTU]'
5101   ;;
5102 esac
5103
5104 # Handle CRLF in mingw tool chain
5105 opt_cr=
5106 case $host_os in
5107 mingw*)
5108   opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
5109   ;;
5110 esac
5111
5112 # If we're using GNU nm, then use its standard symbol codes.
5113 if $NM -V 2>&1 | egrep '(GNU|with BFD)' > /dev/null; then
5114   symcode='[ABCDGISTW]'
5115 fi
5116
5117 # Try without a prefix undercore, then with it.
5118 for ac_symprfx in "" "_"; do
5119
5120   # Write the raw and C identifiers.
5121 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[         ]\($symcode$symcode*\)[         ][      ]*\($ac_symprfx\)$sympat$opt_cr$/$symxfrm/p'"
5122
5123   # Check to see that the pipe works correctly.
5124   pipe_works=no
5125   rm -f conftest*
5126   cat > conftest.$ac_ext <<EOF
5127 #ifdef __cplusplus
5128 extern "C" {
5129 #endif
5130 char nm_test_var;
5131 void nm_test_func(){}
5132 #ifdef __cplusplus
5133 }
5134 #endif
5135 int main(){nm_test_var='a';nm_test_func();return(0);}
5136 EOF
5137
5138   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5139   (eval $ac_compile) 2>&5
5140   ac_status=$?
5141   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5142   (exit $ac_status); }; then
5143     # Now try to grab the symbols.
5144     nlist=conftest.nm
5145     if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5
5146   (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5
5147   ac_status=$?
5148   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5149   (exit $ac_status); } && test -s "$nlist"; then
5150       # Try sorting and uniquifying the output.
5151       if sort "$nlist" | uniq > "$nlist"T; then
5152         mv -f "$nlist"T "$nlist"
5153       else
5154         rm -f "$nlist"T
5155       fi
5156
5157       # Make sure that we snagged all the symbols we need.
5158       if egrep ' nm_test_var$' "$nlist" >/dev/null; then
5159         if egrep ' nm_test_func$' "$nlist" >/dev/null; then
5160           cat <<EOF > conftest.$ac_ext
5161 #ifdef __cplusplus
5162 extern "C" {
5163 #endif
5164
5165 EOF
5166           # Now generate the symbol file.
5167           eval "$lt_cv_global_symbol_to_cdecl"' < "$nlist" >> conftest.$ac_ext'
5168
5169           cat <<EOF >> conftest.$ac_ext
5170 #if defined (__STDC__) && __STDC__
5171 # define lt_ptr void *
5172 #else
5173 # define lt_ptr char *
5174 # define const
5175 #endif
5176
5177 /* The mapping between symbol names and symbols. */
5178 const struct {
5179   const char *name;
5180   lt_ptr address;
5181 }
5182 lt_preloaded_symbols[] =
5183 {
5184 EOF
5185           sed "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (lt_ptr) \&\2},/" < "$nlist" >> conftest.$ac_ext
5186           cat <<\EOF >> conftest.$ac_ext
5187   {0, (lt_ptr) 0}
5188 };
5189
5190 #ifdef __cplusplus
5191 }
5192 #endif
5193 EOF
5194           # Now try linking the two files.
5195           mv conftest.$ac_objext conftstm.$ac_objext
5196           save_LIBS="$LIBS"
5197           save_CFLAGS="$CFLAGS"
5198           LIBS="conftstm.$ac_objext"
5199           CFLAGS="$CFLAGS$no_builtin_flag"
5200           if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5201   (eval $ac_link) 2>&5
5202   ac_status=$?
5203   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5204   (exit $ac_status); } && test -s conftest$ac_exeext; then
5205             pipe_works=yes
5206           fi
5207           LIBS="$save_LIBS"
5208           CFLAGS="$save_CFLAGS"
5209         else
5210           echo "cannot find nm_test_func in $nlist" >&5
5211         fi
5212       else
5213         echo "cannot find nm_test_var in $nlist" >&5
5214       fi
5215     else
5216       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
5217     fi
5218   else
5219     echo "$progname: failed program was:" >&5
5220     cat conftest.$ac_ext >&5
5221   fi
5222   rm -f conftest* conftst*
5223
5224   # Do not use the global_symbol_pipe unless it works.
5225   if test "$pipe_works" = yes; then
5226     break
5227   else
5228     lt_cv_sys_global_symbol_pipe=
5229   fi
5230 done
5231
5232 fi
5233
5234 global_symbol_pipe="$lt_cv_sys_global_symbol_pipe"
5235 if test -z "$lt_cv_sys_global_symbol_pipe"; then
5236   global_symbol_to_cdecl=
5237   global_symbol_to_c_name_address=
5238 else
5239   global_symbol_to_cdecl="$lt_cv_global_symbol_to_cdecl"
5240   global_symbol_to_c_name_address="$lt_cv_global_symbol_to_c_name_address"
5241 fi
5242 if test -z "$global_symbol_pipe$global_symbol_to_cdec$global_symbol_to_c_name_address";
5243 then
5244   echo "$as_me:$LINENO: result: failed" >&5
5245 echo "${ECHO_T}failed" >&6
5246 else
5247   echo "$as_me:$LINENO: result: ok" >&5
5248 echo "${ECHO_T}ok" >&6
5249 fi
5250
5251 ac_ext=c
5252 ac_cpp='$CPP $CPPFLAGS'
5253 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5254 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5255 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5256 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
5257 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
5258 # On Suns, sometimes $CPP names a directory.
5259 if test -n "$CPP" && test -d "$CPP"; then
5260   CPP=
5261 fi
5262 if test -z "$CPP"; then
5263   if test "${ac_cv_prog_CPP+set}" = set; then
5264   echo $ECHO_N "(cached) $ECHO_C" >&6
5265 else
5266       # Double quotes because CPP needs to be expanded
5267     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5268     do
5269       ac_preproc_ok=false
5270 for ac_c_preproc_warn_flag in '' yes
5271 do
5272   # Use a header file that comes with gcc, so configuring glibc
5273   # with a fresh cross-compiler works.
5274   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5275   # <limits.h> exists even on freestanding compilers.
5276   # On the NeXT, cc -E runs the code through the compiler's parser,
5277   # not just through cpp. "Syntax error" is here to catch this case.
5278   cat >conftest.$ac_ext <<_ACEOF
5279 #line $LINENO "configure"
5280 /* confdefs.h.  */
5281 _ACEOF
5282 cat confdefs.h >>conftest.$ac_ext
5283 cat >>conftest.$ac_ext <<_ACEOF
5284 /* end confdefs.h.  */
5285 #ifdef __STDC__
5286 # include <limits.h>
5287 #else
5288 # include <assert.h>
5289 #endif
5290                      Syntax error
5291 _ACEOF
5292 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5293   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5294   ac_status=$?
5295   grep -v '^ *+' conftest.er1 >conftest.err
5296   rm -f conftest.er1
5297   cat conftest.err >&5
5298   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5299   (exit $ac_status); } >/dev/null; then
5300   if test -s conftest.err; then
5301     ac_cpp_err=$ac_c_preproc_warn_flag
5302   else
5303     ac_cpp_err=
5304   fi
5305 else
5306   ac_cpp_err=yes
5307 fi
5308 if test -z "$ac_cpp_err"; then
5309   :
5310 else
5311   echo "$as_me: failed program was:" >&5
5312 sed 's/^/| /' conftest.$ac_ext >&5
5313
5314   # Broken: fails on valid input.
5315 continue
5316 fi
5317 rm -f conftest.err conftest.$ac_ext
5318
5319   # OK, works on sane cases.  Now check whether non-existent headers
5320   # can be detected and how.
5321   cat >conftest.$ac_ext <<_ACEOF
5322 #line $LINENO "configure"
5323 /* confdefs.h.  */
5324 _ACEOF
5325 cat confdefs.h >>conftest.$ac_ext
5326 cat >>conftest.$ac_ext <<_ACEOF
5327 /* end confdefs.h.  */
5328 #include <ac_nonexistent.h>
5329 _ACEOF
5330 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5331   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5332   ac_status=$?
5333   grep -v '^ *+' conftest.er1 >conftest.err
5334   rm -f conftest.er1
5335   cat conftest.err >&5
5336   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5337   (exit $ac_status); } >/dev/null; then
5338   if test -s conftest.err; then
5339     ac_cpp_err=$ac_c_preproc_warn_flag
5340   else
5341     ac_cpp_err=
5342   fi
5343 else
5344   ac_cpp_err=yes
5345 fi
5346 if test -z "$ac_cpp_err"; then
5347   # Broken: success on invalid input.
5348 continue
5349 else
5350   echo "$as_me: failed program was:" >&5
5351 sed 's/^/| /' conftest.$ac_ext >&5
5352
5353   # Passes both tests.
5354 ac_preproc_ok=:
5355 break
5356 fi
5357 rm -f conftest.err conftest.$ac_ext
5358
5359 done
5360 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5361 rm -f conftest.err conftest.$ac_ext
5362 if $ac_preproc_ok; then
5363   break
5364 fi
5365
5366     done
5367     ac_cv_prog_CPP=$CPP
5368
5369 fi
5370   CPP=$ac_cv_prog_CPP
5371 else
5372   ac_cv_prog_CPP=$CPP
5373 fi
5374 echo "$as_me:$LINENO: result: $CPP" >&5
5375 echo "${ECHO_T}$CPP" >&6
5376 ac_preproc_ok=false
5377 for ac_c_preproc_warn_flag in '' yes
5378 do
5379   # Use a header file that comes with gcc, so configuring glibc
5380   # with a fresh cross-compiler works.
5381   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5382   # <limits.h> exists even on freestanding compilers.
5383   # On the NeXT, cc -E runs the code through the compiler's parser,
5384   # not just through cpp. "Syntax error" is here to catch this case.
5385   cat >conftest.$ac_ext <<_ACEOF
5386 #line $LINENO "configure"
5387 /* confdefs.h.  */
5388 _ACEOF
5389 cat confdefs.h >>conftest.$ac_ext
5390 cat >>conftest.$ac_ext <<_ACEOF
5391 /* end confdefs.h.  */
5392 #ifdef __STDC__
5393 # include <limits.h>
5394 #else
5395 # include <assert.h>
5396 #endif
5397                      Syntax error
5398 _ACEOF
5399 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5400   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5401   ac_status=$?
5402   grep -v '^ *+' conftest.er1 >conftest.err
5403   rm -f conftest.er1
5404   cat conftest.err >&5
5405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5406   (exit $ac_status); } >/dev/null; then
5407   if test -s conftest.err; then
5408     ac_cpp_err=$ac_c_preproc_warn_flag
5409   else
5410     ac_cpp_err=
5411   fi
5412 else
5413   ac_cpp_err=yes
5414 fi
5415 if test -z "$ac_cpp_err"; then
5416   :
5417 else
5418   echo "$as_me: failed program was:" >&5
5419 sed 's/^/| /' conftest.$ac_ext >&5
5420
5421   # Broken: fails on valid input.
5422 continue
5423 fi
5424 rm -f conftest.err conftest.$ac_ext
5425
5426   # OK, works on sane cases.  Now check whether non-existent headers
5427   # can be detected and how.
5428   cat >conftest.$ac_ext <<_ACEOF
5429 #line $LINENO "configure"
5430 /* confdefs.h.  */
5431 _ACEOF
5432 cat confdefs.h >>conftest.$ac_ext
5433 cat >>conftest.$ac_ext <<_ACEOF
5434 /* end confdefs.h.  */
5435 #include <ac_nonexistent.h>
5436 _ACEOF
5437 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5438   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5439   ac_status=$?
5440   grep -v '^ *+' conftest.er1 >conftest.err
5441   rm -f conftest.er1
5442   cat conftest.err >&5
5443   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5444   (exit $ac_status); } >/dev/null; then
5445   if test -s conftest.err; then
5446     ac_cpp_err=$ac_c_preproc_warn_flag
5447   else
5448     ac_cpp_err=
5449   fi
5450 else
5451   ac_cpp_err=yes
5452 fi
5453 if test -z "$ac_cpp_err"; then
5454   # Broken: success on invalid input.
5455 continue
5456 else
5457   echo "$as_me: failed program was:" >&5
5458 sed 's/^/| /' conftest.$ac_ext >&5
5459
5460   # Passes both tests.
5461 ac_preproc_ok=:
5462 break
5463 fi
5464 rm -f conftest.err conftest.$ac_ext
5465
5466 done
5467 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5468 rm -f conftest.err conftest.$ac_ext
5469 if $ac_preproc_ok; then
5470   :
5471 else
5472   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
5473 See \`config.log' for more details." >&5
5474 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
5475 See \`config.log' for more details." >&2;}
5476    { (exit 1); exit 1; }; }
5477 fi
5478
5479 ac_ext=c
5480 ac_cpp='$CPP $CPPFLAGS'
5481 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5482 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5483 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5484
5485
5486 echo "$as_me:$LINENO: checking for egrep" >&5
5487 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
5488 if test "${ac_cv_prog_egrep+set}" = set; then
5489   echo $ECHO_N "(cached) $ECHO_C" >&6
5490 else
5491   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
5492     then ac_cv_prog_egrep='grep -E'
5493     else ac_cv_prog_egrep='egrep'
5494     fi
5495 fi
5496 echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
5497 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
5498  EGREP=$ac_cv_prog_egrep
5499
5500
5501 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
5502 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
5503 if test "${ac_cv_header_stdc+set}" = set; then
5504   echo $ECHO_N "(cached) $ECHO_C" >&6
5505 else
5506   cat >conftest.$ac_ext <<_ACEOF
5507 #line $LINENO "configure"
5508 /* confdefs.h.  */
5509 _ACEOF
5510 cat confdefs.h >>conftest.$ac_ext
5511 cat >>conftest.$ac_ext <<_ACEOF
5512 /* end confdefs.h.  */
5513 #include <stdlib.h>
5514 #include <stdarg.h>
5515 #include <string.h>
5516 #include <float.h>
5517
5518 int
5519 main ()
5520 {
5521
5522   ;
5523   return 0;
5524 }
5525 _ACEOF
5526 rm -f conftest.$ac_objext
5527 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5528   (eval $ac_compile) 2>&5
5529   ac_status=$?
5530   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5531   (exit $ac_status); } &&
5532          { ac_try='test -s conftest.$ac_objext'
5533   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5534   (eval $ac_try) 2>&5
5535   ac_status=$?
5536   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5537   (exit $ac_status); }; }; then
5538   ac_cv_header_stdc=yes
5539 else
5540   echo "$as_me: failed program was:" >&5
5541 sed 's/^/| /' conftest.$ac_ext >&5
5542
5543 ac_cv_header_stdc=no
5544 fi
5545 rm -f conftest.$ac_objext conftest.$ac_ext
5546
5547 if test $ac_cv_header_stdc = yes; then
5548   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5549   cat >conftest.$ac_ext <<_ACEOF
5550 #line $LINENO "configure"
5551 /* confdefs.h.  */
5552 _ACEOF
5553 cat confdefs.h >>conftest.$ac_ext
5554 cat >>conftest.$ac_ext <<_ACEOF
5555 /* end confdefs.h.  */
5556 #include <string.h>
5557
5558 _ACEOF
5559 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5560   $EGREP "memchr" >/dev/null 2>&1; then
5561   :
5562 else
5563   ac_cv_header_stdc=no
5564 fi
5565 rm -f conftest*
5566
5567 fi
5568
5569 if test $ac_cv_header_stdc = yes; then
5570   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5571   cat >conftest.$ac_ext <<_ACEOF
5572 #line $LINENO "configure"
5573 /* confdefs.h.  */
5574 _ACEOF
5575 cat confdefs.h >>conftest.$ac_ext
5576 cat >>conftest.$ac_ext <<_ACEOF
5577 /* end confdefs.h.  */
5578 #include <stdlib.h>
5579
5580 _ACEOF
5581 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5582   $EGREP "free" >/dev/null 2>&1; then
5583   :
5584 else
5585   ac_cv_header_stdc=no
5586 fi
5587 rm -f conftest*
5588
5589 fi
5590
5591 if test $ac_cv_header_stdc = yes; then
5592   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5593   if test "$cross_compiling" = yes; then
5594   :
5595 else
5596   cat >conftest.$ac_ext <<_ACEOF
5597 #line $LINENO "configure"
5598 /* confdefs.h.  */
5599 _ACEOF
5600 cat confdefs.h >>conftest.$ac_ext
5601 cat >>conftest.$ac_ext <<_ACEOF
5602 /* end confdefs.h.  */
5603 #include <ctype.h>
5604 #if ((' ' & 0x0FF) == 0x020)
5605 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5606 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5607 #else
5608 # define ISLOWER(c) \
5609                    (('a' <= (c) && (c) <= 'i') \
5610                      || ('j' <= (c) && (c) <= 'r') \
5611                      || ('s' <= (c) && (c) <= 'z'))
5612 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5613 #endif
5614
5615 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
5616 int
5617 main ()
5618 {
5619   int i;
5620   for (i = 0; i < 256; i++)
5621     if (XOR (islower (i), ISLOWER (i))
5622         || toupper (i) != TOUPPER (i))
5623       exit(2);
5624   exit (0);
5625 }
5626 _ACEOF
5627 rm -f conftest$ac_exeext
5628 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5629   (eval $ac_link) 2>&5
5630   ac_status=$?
5631   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5632   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5633   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5634   (eval $ac_try) 2>&5
5635   ac_status=$?
5636   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5637   (exit $ac_status); }; }; then
5638   :
5639 else
5640   echo "$as_me: program exited with status $ac_status" >&5
5641 echo "$as_me: failed program was:" >&5
5642 sed 's/^/| /' conftest.$ac_ext >&5
5643
5644 ( exit $ac_status )
5645 ac_cv_header_stdc=no
5646 fi
5647 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5648 fi
5649 fi
5650 fi
5651 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
5652 echo "${ECHO_T}$ac_cv_header_stdc" >&6
5653 if test $ac_cv_header_stdc = yes; then
5654
5655 cat >>confdefs.h <<\_ACEOF
5656 #define STDC_HEADERS 1
5657 _ACEOF
5658
5659 fi
5660
5661 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
5662
5663
5664
5665
5666
5667
5668
5669
5670
5671 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
5672                   inttypes.h stdint.h unistd.h
5673 do
5674 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5675 echo "$as_me:$LINENO: checking for $ac_header" >&5
5676 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5677 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5678   echo $ECHO_N "(cached) $ECHO_C" >&6
5679 else
5680   cat >conftest.$ac_ext <<_ACEOF
5681 #line $LINENO "configure"
5682 /* confdefs.h.  */
5683 _ACEOF
5684 cat confdefs.h >>conftest.$ac_ext
5685 cat >>conftest.$ac_ext <<_ACEOF
5686 /* end confdefs.h.  */
5687 $ac_includes_default
5688
5689 #include <$ac_header>
5690 _ACEOF
5691 rm -f conftest.$ac_objext
5692 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5693   (eval $ac_compile) 2>&5
5694   ac_status=$?
5695   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5696   (exit $ac_status); } &&
5697          { ac_try='test -s conftest.$ac_objext'
5698   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5699   (eval $ac_try) 2>&5
5700   ac_status=$?
5701   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5702   (exit $ac_status); }; }; then
5703   eval "$as_ac_Header=yes"
5704 else
5705   echo "$as_me: failed program was:" >&5
5706 sed 's/^/| /' conftest.$ac_ext >&5
5707
5708 eval "$as_ac_Header=no"
5709 fi
5710 rm -f conftest.$ac_objext conftest.$ac_ext
5711 fi
5712 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5713 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5714 if test `eval echo '${'$as_ac_Header'}'` = yes; then
5715   cat >>confdefs.h <<_ACEOF
5716 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5717 _ACEOF
5718
5719 fi
5720
5721 done
5722
5723
5724
5725 for ac_header in dlfcn.h
5726 do
5727 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5728 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5729   echo "$as_me:$LINENO: checking for $ac_header" >&5
5730 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5731 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5732   echo $ECHO_N "(cached) $ECHO_C" >&6
5733 fi
5734 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5735 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5736 else
5737   # Is the header compilable?
5738 echo "$as_me:$LINENO: checking $ac_header usability" >&5
5739 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
5740 cat >conftest.$ac_ext <<_ACEOF
5741 #line $LINENO "configure"
5742 /* confdefs.h.  */
5743 _ACEOF
5744 cat confdefs.h >>conftest.$ac_ext
5745 cat >>conftest.$ac_ext <<_ACEOF
5746 /* end confdefs.h.  */
5747 $ac_includes_default
5748 #include <$ac_header>
5749 _ACEOF
5750 rm -f conftest.$ac_objext
5751 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5752   (eval $ac_compile) 2>&5
5753   ac_status=$?
5754   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5755   (exit $ac_status); } &&
5756          { ac_try='test -s conftest.$ac_objext'
5757   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5758   (eval $ac_try) 2>&5
5759   ac_status=$?
5760   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5761   (exit $ac_status); }; }; then
5762   ac_header_compiler=yes
5763 else
5764   echo "$as_me: failed program was:" >&5
5765 sed 's/^/| /' conftest.$ac_ext >&5
5766
5767 ac_header_compiler=no
5768 fi
5769 rm -f conftest.$ac_objext conftest.$ac_ext
5770 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5771 echo "${ECHO_T}$ac_header_compiler" >&6
5772
5773 # Is the header present?
5774 echo "$as_me:$LINENO: checking $ac_header presence" >&5
5775 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
5776 cat >conftest.$ac_ext <<_ACEOF
5777 #line $LINENO "configure"
5778 /* confdefs.h.  */
5779 _ACEOF
5780 cat confdefs.h >>conftest.$ac_ext
5781 cat >>conftest.$ac_ext <<_ACEOF
5782 /* end confdefs.h.  */
5783 #include <$ac_header>
5784 _ACEOF
5785 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5786   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5787   ac_status=$?
5788   grep -v '^ *+' conftest.er1 >conftest.err
5789   rm -f conftest.er1
5790   cat conftest.err >&5
5791   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5792   (exit $ac_status); } >/dev/null; then
5793   if test -s conftest.err; then
5794     ac_cpp_err=$ac_c_preproc_warn_flag
5795   else
5796     ac_cpp_err=
5797   fi
5798 else
5799   ac_cpp_err=yes
5800 fi
5801 if test -z "$ac_cpp_err"; then
5802   ac_header_preproc=yes
5803 else
5804   echo "$as_me: failed program was:" >&5
5805 sed 's/^/| /' conftest.$ac_ext >&5
5806
5807   ac_header_preproc=no
5808 fi
5809 rm -f conftest.err conftest.$ac_ext
5810 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5811 echo "${ECHO_T}$ac_header_preproc" >&6
5812
5813 # So?  What about this header?
5814 case $ac_header_compiler:$ac_header_preproc in
5815   yes:no )
5816     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5817 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
5818     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
5819 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
5820     (
5821       cat <<\_ASBOX
5822 ## ------------------------------------ ##
5823 ## Report this to bug-autoconf@gnu.org. ##
5824 ## ------------------------------------ ##
5825 _ASBOX
5826     ) |
5827       sed "s/^/$as_me: WARNING:     /" >&2
5828     ;;
5829   no:yes )
5830     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5831 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
5832     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
5833 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
5834     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
5835 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
5836     (
5837       cat <<\_ASBOX
5838 ## ------------------------------------ ##
5839 ## Report this to bug-autoconf@gnu.org. ##
5840 ## ------------------------------------ ##
5841 _ASBOX
5842     ) |
5843       sed "s/^/$as_me: WARNING:     /" >&2
5844     ;;
5845 esac
5846 echo "$as_me:$LINENO: checking for $ac_header" >&5
5847 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5848 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5849   echo $ECHO_N "(cached) $ECHO_C" >&6
5850 else
5851   eval "$as_ac_Header=$ac_header_preproc"
5852 fi
5853 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5854 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5855
5856 fi
5857 if test `eval echo '${'$as_ac_Header'}'` = yes; then
5858   cat >>confdefs.h <<_ACEOF
5859 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5860 _ACEOF
5861
5862 fi
5863
5864 done
5865
5866
5867
5868
5869
5870
5871 # Only perform the check for file, if the check method requires it
5872 case $deplibs_check_method in
5873 file_magic*)
5874   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
5875     echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5
5876 echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6
5877 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
5878   echo $ECHO_N "(cached) $ECHO_C" >&6
5879 else
5880   case $MAGIC_CMD in
5881   /*)
5882   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
5883   ;;
5884   ?:/*)
5885   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
5886   ;;
5887   *)
5888   ac_save_MAGIC_CMD="$MAGIC_CMD"
5889   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
5890   ac_dummy="/usr/bin:$PATH"
5891   for ac_dir in $ac_dummy; do
5892     test -z "$ac_dir" && ac_dir=.
5893     if test -f $ac_dir/${ac_tool_prefix}file; then
5894       lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
5895       if test -n "$file_magic_test_file"; then
5896         case $deplibs_check_method in
5897         "file_magic "*)
5898           file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
5899           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
5900           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
5901             egrep "$file_magic_regex" > /dev/null; then
5902             :
5903           else
5904             cat <<EOF 1>&2
5905
5906 *** Warning: the command libtool uses to detect shared libraries,
5907 *** $file_magic_cmd, produces output that libtool cannot recognize.
5908 *** The result is that libtool may fail to recognize shared libraries
5909 *** as such.  This will affect the creation of libtool libraries that
5910 *** depend on shared libraries, but programs linked with such libtool
5911 *** libraries will work regardless of this problem.  Nevertheless, you
5912 *** may want to report the problem to your system manager and/or to
5913 *** bug-libtool@gnu.org
5914
5915 EOF
5916           fi ;;
5917         esac
5918       fi
5919       break
5920     fi
5921   done
5922   IFS="$ac_save_ifs"
5923   MAGIC_CMD="$ac_save_MAGIC_CMD"
5924   ;;
5925 esac
5926 fi
5927
5928 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
5929 if test -n "$MAGIC_CMD"; then
5930   echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
5931 echo "${ECHO_T}$MAGIC_CMD" >&6
5932 else
5933   echo "$as_me:$LINENO: result: no" >&5
5934 echo "${ECHO_T}no" >&6
5935 fi
5936
5937 if test -z "$lt_cv_path_MAGIC_CMD"; then
5938   if test -n "$ac_tool_prefix"; then
5939     echo "$as_me:$LINENO: checking for file" >&5
5940 echo $ECHO_N "checking for file... $ECHO_C" >&6
5941 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
5942   echo $ECHO_N "(cached) $ECHO_C" >&6
5943 else
5944   case $MAGIC_CMD in
5945   /*)
5946   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
5947   ;;
5948   ?:/*)
5949   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
5950   ;;
5951   *)
5952   ac_save_MAGIC_CMD="$MAGIC_CMD"
5953   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
5954   ac_dummy="/usr/bin:$PATH"
5955   for ac_dir in $ac_dummy; do
5956     test -z "$ac_dir" && ac_dir=.
5957     if test -f $ac_dir/file; then
5958       lt_cv_path_MAGIC_CMD="$ac_dir/file"
5959       if test -n "$file_magic_test_file"; then
5960         case $deplibs_check_method in
5961         "file_magic "*)
5962           file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
5963           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
5964           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
5965             egrep "$file_magic_regex" > /dev/null; then
5966             :
5967           else
5968             cat <<EOF 1>&2
5969
5970 *** Warning: the command libtool uses to detect shared libraries,
5971 *** $file_magic_cmd, produces output that libtool cannot recognize.
5972 *** The result is that libtool may fail to recognize shared libraries
5973 *** as such.  This will affect the creation of libtool libraries that
5974 *** depend on shared libraries, but programs linked with such libtool
5975 *** libraries will work regardless of this problem.  Nevertheless, you
5976 *** may want to report the problem to your system manager and/or to
5977 *** bug-libtool@gnu.org
5978
5979 EOF
5980           fi ;;
5981         esac
5982       fi
5983       break
5984     fi
5985   done
5986   IFS="$ac_save_ifs"
5987   MAGIC_CMD="$ac_save_MAGIC_CMD"
5988   ;;
5989 esac
5990 fi
5991
5992 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
5993 if test -n "$MAGIC_CMD"; then
5994   echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
5995 echo "${ECHO_T}$MAGIC_CMD" >&6
5996 else
5997   echo "$as_me:$LINENO: result: no" >&5
5998 echo "${ECHO_T}no" >&6
5999 fi
6000
6001   else
6002     MAGIC_CMD=:
6003   fi
6004 fi
6005
6006   fi
6007   ;;
6008 esac
6009
6010 if test -n "$ac_tool_prefix"; then
6011   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6012 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6013 echo "$as_me:$LINENO: checking for $ac_word" >&5
6014 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6015 if test "${ac_cv_prog_RANLIB+set}" = set; then
6016   echo $ECHO_N "(cached) $ECHO_C" >&6
6017 else
6018   if test -n "$RANLIB"; then
6019   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6020 else
6021 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6022 for as_dir in $PATH
6023 do
6024   IFS=$as_save_IFS
6025   test -z "$as_dir" && as_dir=.
6026   for ac_exec_ext in '' $ac_executable_extensions; do
6027   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6028     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6029     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6030     break 2
6031   fi
6032 done
6033 done
6034
6035 fi
6036 fi
6037 RANLIB=$ac_cv_prog_RANLIB
6038 if test -n "$RANLIB"; then
6039   echo "$as_me:$LINENO: result: $RANLIB" >&5
6040 echo "${ECHO_T}$RANLIB" >&6
6041 else
6042   echo "$as_me:$LINENO: result: no" >&5
6043 echo "${ECHO_T}no" >&6
6044 fi
6045
6046 fi
6047 if test -z "$ac_cv_prog_RANLIB"; then
6048   ac_ct_RANLIB=$RANLIB
6049   # Extract the first word of "ranlib", so it can be a program name with args.
6050 set dummy ranlib; ac_word=$2
6051 echo "$as_me:$LINENO: checking for $ac_word" >&5
6052 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6053 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
6054   echo $ECHO_N "(cached) $ECHO_C" >&6
6055 else
6056   if test -n "$ac_ct_RANLIB"; then
6057   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6058 else
6059 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6060 for as_dir in $PATH
6061 do
6062   IFS=$as_save_IFS
6063   test -z "$as_dir" && as_dir=.
6064   for ac_exec_ext in '' $ac_executable_extensions; do
6065   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6066     ac_cv_prog_ac_ct_RANLIB="ranlib"
6067     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6068     break 2
6069   fi
6070 done
6071 done
6072
6073   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
6074 fi
6075 fi
6076 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6077 if test -n "$ac_ct_RANLIB"; then
6078   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
6079 echo "${ECHO_T}$ac_ct_RANLIB" >&6
6080 else
6081   echo "$as_me:$LINENO: result: no" >&5
6082 echo "${ECHO_T}no" >&6
6083 fi
6084
6085   RANLIB=$ac_ct_RANLIB
6086 else
6087   RANLIB="$ac_cv_prog_RANLIB"
6088 fi
6089
6090 if test -n "$ac_tool_prefix"; then
6091   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6092 set dummy ${ac_tool_prefix}strip; ac_word=$2
6093 echo "$as_me:$LINENO: checking for $ac_word" >&5
6094 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6095 if test "${ac_cv_prog_STRIP+set}" = set; then
6096   echo $ECHO_N "(cached) $ECHO_C" >&6
6097 else
6098   if test -n "$STRIP"; then
6099   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6100 else
6101 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6102 for as_dir in $PATH
6103 do
6104   IFS=$as_save_IFS
6105   test -z "$as_dir" && as_dir=.
6106   for ac_exec_ext in '' $ac_executable_extensions; do
6107   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6108     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6109     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6110     break 2
6111   fi
6112 done
6113 done
6114
6115 fi
6116 fi
6117 STRIP=$ac_cv_prog_STRIP
6118 if test -n "$STRIP"; then
6119   echo "$as_me:$LINENO: result: $STRIP" >&5
6120 echo "${ECHO_T}$STRIP" >&6
6121 else
6122   echo "$as_me:$LINENO: result: no" >&5
6123 echo "${ECHO_T}no" >&6
6124 fi
6125
6126 fi
6127 if test -z "$ac_cv_prog_STRIP"; then
6128   ac_ct_STRIP=$STRIP
6129   # Extract the first word of "strip", so it can be a program name with args.
6130 set dummy strip; ac_word=$2
6131 echo "$as_me:$LINENO: checking for $ac_word" >&5
6132 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6133 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
6134   echo $ECHO_N "(cached) $ECHO_C" >&6
6135 else
6136   if test -n "$ac_ct_STRIP"; then
6137   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6138 else
6139 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6140 for as_dir in $PATH
6141 do
6142   IFS=$as_save_IFS
6143   test -z "$as_dir" && as_dir=.
6144   for ac_exec_ext in '' $ac_executable_extensions; do
6145   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6146     ac_cv_prog_ac_ct_STRIP="strip"
6147     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6148     break 2
6149   fi
6150 done
6151 done
6152
6153   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
6154 fi
6155 fi
6156 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6157 if test -n "$ac_ct_STRIP"; then
6158   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
6159 echo "${ECHO_T}$ac_ct_STRIP" >&6
6160 else
6161   echo "$as_me:$LINENO: result: no" >&5
6162 echo "${ECHO_T}no" >&6
6163 fi
6164
6165   STRIP=$ac_ct_STRIP
6166 else
6167   STRIP="$ac_cv_prog_STRIP"
6168 fi
6169
6170
6171 enable_dlopen=no
6172 enable_win32_dll=no
6173
6174 # Check whether --enable-libtool-lock or --disable-libtool-lock was given.
6175 if test "${enable_libtool_lock+set}" = set; then
6176   enableval="$enable_libtool_lock"
6177
6178 fi;
6179 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
6180
6181 # Some flags need to be propagated to the compiler or linker for good
6182 # libtool support.
6183 case $host in
6184 *-*-irix6*)
6185   # Find out which ABI we are using.
6186   echo '#line 6186 "configure"' > conftest.$ac_ext
6187   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6188   (eval $ac_compile) 2>&5
6189   ac_status=$?
6190   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6191   (exit $ac_status); }; then
6192     case `/usr/bin/file conftest.$ac_objext` in
6193     *32-bit*)
6194       LD="${LD-ld} -32"
6195       ;;
6196     *N32*)
6197       LD="${LD-ld} -n32"
6198       ;;
6199     *64-bit*)
6200       LD="${LD-ld} -64"
6201       ;;
6202     esac
6203   fi
6204   rm -rf conftest*
6205   ;;
6206
6207 *-*-sco3.2v5*)
6208   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
6209   SAVE_CFLAGS="$CFLAGS"
6210   CFLAGS="$CFLAGS -belf"
6211   echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5
6212 echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6
6213 if test "${lt_cv_cc_needs_belf+set}" = set; then
6214   echo $ECHO_N "(cached) $ECHO_C" >&6
6215 else
6216
6217
6218      ac_ext=c
6219 ac_cpp='$CPP $CPPFLAGS'
6220 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6221 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6222 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6223
6224      cat >conftest.$ac_ext <<_ACEOF
6225 #line $LINENO "configure"
6226 /* confdefs.h.  */
6227 _ACEOF
6228 cat confdefs.h >>conftest.$ac_ext
6229 cat >>conftest.$ac_ext <<_ACEOF
6230 /* end confdefs.h.  */
6231
6232 int
6233 main ()
6234 {
6235
6236   ;
6237   return 0;
6238 }
6239 _ACEOF
6240 rm -f conftest.$ac_objext conftest$ac_exeext
6241 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6242   (eval $ac_link) 2>&5
6243   ac_status=$?
6244   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6245   (exit $ac_status); } &&
6246          { ac_try='test -s conftest$ac_exeext'
6247   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6248   (eval $ac_try) 2>&5
6249   ac_status=$?
6250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6251   (exit $ac_status); }; }; then
6252   lt_cv_cc_needs_belf=yes
6253 else
6254   echo "$as_me: failed program was:" >&5
6255 sed 's/^/| /' conftest.$ac_ext >&5
6256
6257 lt_cv_cc_needs_belf=no
6258 fi
6259 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6260      ac_ext=c
6261 ac_cpp='$CPP $CPPFLAGS'
6262 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6263 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6264 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6265
6266 fi
6267 echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5
6268 echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6
6269   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
6270     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
6271     CFLAGS="$SAVE_CFLAGS"
6272   fi
6273   ;;
6274
6275
6276 esac
6277
6278 # Sed substitution that helps us do robust quoting.  It backslashifies
6279 # metacharacters that are still active within double-quoted strings.
6280 Xsed='sed -e s/^X//'
6281 sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'
6282
6283 # Same as above, but do not quote variable references.
6284 double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'
6285
6286 # Sed substitution to delay expansion of an escaped shell variable in a
6287 # double_quote_subst'ed string.
6288 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
6289
6290 # Constants:
6291 rm="rm -f"
6292
6293 # Global variables:
6294 default_ofile=libtool
6295 can_build_shared=yes
6296
6297 # All known linkers require a `.a' archive for static linking (except M$VC,
6298 # which needs '.lib').
6299 libext=a
6300 ltmain="$ac_aux_dir/ltmain.sh"
6301 ofile="$default_ofile"
6302 with_gnu_ld="$lt_cv_prog_gnu_ld"
6303 need_locks="$enable_libtool_lock"
6304
6305 old_CC="$CC"
6306 old_CFLAGS="$CFLAGS"
6307
6308 # Set sane defaults for various variables
6309 test -z "$AR" && AR=ar
6310 test -z "$AR_FLAGS" && AR_FLAGS=cru
6311 test -z "$AS" && AS=as
6312 test -z "$CC" && CC=cc
6313 test -z "$DLLTOOL" && DLLTOOL=dlltool
6314 test -z "$LD" && LD=ld
6315 test -z "$LN_S" && LN_S="ln -s"
6316 test -z "$MAGIC_CMD" && MAGIC_CMD=file
6317 test -z "$NM" && NM=nm
6318 test -z "$OBJDUMP" && OBJDUMP=objdump
6319 test -z "$RANLIB" && RANLIB=:
6320 test -z "$STRIP" && STRIP=:
6321 test -z "$ac_objext" && ac_objext=o
6322
6323 if test x"$host" != x"$build"; then
6324   ac_tool_prefix=${host_alias}-
6325 else
6326   ac_tool_prefix=
6327 fi
6328
6329 # Transform linux* to *-*-linux-gnu*, to support old configure scripts.
6330 case $host_os in
6331 linux-gnu*) ;;
6332 linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'`
6333 esac
6334
6335 case $host_os in
6336 aix3*)
6337   # AIX sometimes has problems with the GCC collect2 program.  For some
6338   # reason, if we set the COLLECT_NAMES environment variable, the problems
6339   # vanish in a puff of smoke.
6340   if test "X${COLLECT_NAMES+set}" != Xset; then
6341     COLLECT_NAMES=
6342     export COLLECT_NAMES
6343   fi
6344   ;;
6345 esac
6346
6347 # Determine commands to create old-style static archives.
6348 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
6349 old_postinstall_cmds='chmod 644 $oldlib'
6350 old_postuninstall_cmds=
6351
6352 if test -n "$RANLIB"; then
6353   case $host_os in
6354   openbsd*)
6355     old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
6356     ;;
6357   *)
6358     old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
6359     ;;
6360   esac
6361   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
6362 fi
6363
6364 # Allow CC to be a program name with arguments.
6365 set dummy $CC
6366 compiler="$2"
6367
6368 echo "$as_me:$LINENO: checking for objdir" >&5
6369 echo $ECHO_N "checking for objdir... $ECHO_C" >&6
6370 rm -f .libs 2>/dev/null
6371 mkdir .libs 2>/dev/null
6372 if test -d .libs; then
6373   objdir=.libs
6374 else
6375   # MS-DOS does not allow filenames that begin with a dot.
6376   objdir=_libs
6377 fi
6378 rmdir .libs 2>/dev/null
6379 echo "$as_me:$LINENO: result: $objdir" >&5
6380 echo "${ECHO_T}$objdir" >&6
6381
6382
6383
6384 # Check whether --with-pic or --without-pic was given.
6385 if test "${with_pic+set}" = set; then
6386   withval="$with_pic"
6387   pic_mode="$withval"
6388 else
6389   pic_mode=default
6390 fi;
6391 test -z "$pic_mode" && pic_mode=default
6392
6393 # We assume here that the value for lt_cv_prog_cc_pic will not be cached
6394 # in isolation, and that seeing it set (from the cache) indicates that
6395 # the associated values are set (in the cache) correctly too.
6396 echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
6397 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6
6398 if test "${lt_cv_prog_cc_pic+set}" = set; then
6399   echo $ECHO_N "(cached) $ECHO_C" >&6
6400 else
6401    lt_cv_prog_cc_pic=
6402   lt_cv_prog_cc_shlib=
6403   lt_cv_prog_cc_wl=
6404   lt_cv_prog_cc_static=
6405   lt_cv_prog_cc_no_builtin=
6406   lt_cv_prog_cc_can_build_shared=$can_build_shared
6407
6408   if test "$GCC" = yes; then
6409     lt_cv_prog_cc_wl='-Wl,'
6410     lt_cv_prog_cc_static='-static'
6411
6412     case $host_os in
6413     aix*)
6414       # Below there is a dirty hack to force normal static linking with -ldl
6415       # The problem is because libdl dynamically linked with both libc and
6416       # libC (AIX C++ library), which obviously doesn't included in libraries
6417       # list by gcc. This cause undefined symbols with -static flags.
6418       # This hack allows C programs to be linked with "-static -ldl", but
6419       # not sure about C++ programs.
6420       lt_cv_prog_cc_static="$lt_cv_prog_cc_static ${lt_cv_prog_cc_wl}-lC"
6421       ;;
6422     amigaos*)
6423       # FIXME: we need at least 68020 code to build shared libraries, but
6424       # adding the `-m68020' flag to GCC prevents building anything better,
6425       # like `-m68040'.
6426       lt_cv_prog_cc_pic='-m68020 -resident32 -malways-restore-a4'
6427       ;;
6428     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
6429       # PIC is the default for these OSes.
6430       ;;
6431     darwin* | rhapsody*)
6432       # PIC is the default on this platform
6433       # Common symbols not allowed in MH_DYLIB files
6434       lt_cv_prog_cc_pic='-fno-common'
6435       ;;
6436     cygwin* | mingw* | pw32* | os2*)
6437       # This hack is so that the source file can tell whether it is being
6438       # built for inclusion in a dll (and should export symbols for example).
6439       lt_cv_prog_cc_pic='-DDLL_EXPORT'
6440       ;;
6441     sysv4*MP*)
6442       if test -d /usr/nec; then
6443          lt_cv_prog_cc_pic=-Kconform_pic
6444       fi
6445       ;;
6446     *)
6447       lt_cv_prog_cc_pic='-fPIC'
6448       ;;
6449     esac
6450   else
6451     # PORTME Check for PIC flags for the system compiler.
6452     case $host_os in
6453     aix3* | aix4* | aix5*)
6454       lt_cv_prog_cc_wl='-Wl,'
6455       # All AIX code is PIC.
6456       if test "$host_cpu" = ia64; then
6457         # AIX 5 now supports IA64 processor
6458         lt_cv_prog_cc_static='-Bstatic'
6459       else
6460         lt_cv_prog_cc_static='-bnso -bI:/lib/syscalls.exp'
6461       fi
6462       ;;
6463
6464     hpux9* | hpux10* | hpux11*)
6465       # Is there a better lt_cv_prog_cc_static that works with the bundled CC?
6466       lt_cv_prog_cc_wl='-Wl,'
6467       lt_cv_prog_cc_static="${lt_cv_prog_cc_wl}-a ${lt_cv_prog_cc_wl}archive"
6468       lt_cv_prog_cc_pic='+Z'
6469       ;;
6470
6471     irix5* | irix6* | nonstopux*)
6472       lt_cv_prog_cc_wl='-Wl,'
6473       lt_cv_prog_cc_static='-non_shared'
6474       # PIC (with -KPIC) is the default.
6475       ;;
6476
6477     cygwin* | mingw* | pw32* | os2*)
6478       # This hack is so that the source file can tell whether it is being
6479       # built for inclusion in a dll (and should export symbols for example).
6480       lt_cv_prog_cc_pic='-DDLL_EXPORT'
6481       ;;
6482
6483     newsos6)
6484       lt_cv_prog_cc_pic='-KPIC'
6485       lt_cv_prog_cc_static='-Bstatic'
6486       ;;
6487
6488     osf3* | osf4* | osf5*)
6489       # All OSF/1 code is PIC.
6490       lt_cv_prog_cc_wl='-Wl,'
6491       lt_cv_prog_cc_static='-non_shared'
6492       ;;
6493
6494     sco3.2v5*)
6495       lt_cv_prog_cc_pic='-Kpic'
6496       lt_cv_prog_cc_static='-dn'
6497       lt_cv_prog_cc_shlib='-belf'
6498       ;;
6499
6500     solaris*)
6501       lt_cv_prog_cc_pic='-KPIC'
6502       lt_cv_prog_cc_static='-Bstatic'
6503       lt_cv_prog_cc_wl='-Wl,'
6504       ;;
6505
6506     sunos4*)
6507       lt_cv_prog_cc_pic='-PIC'
6508       lt_cv_prog_cc_static='-Bstatic'
6509       lt_cv_prog_cc_wl='-Qoption ld '
6510       ;;
6511
6512     sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
6513       lt_cv_prog_cc_pic='-KPIC'
6514       lt_cv_prog_cc_static='-Bstatic'
6515       lt_cv_prog_cc_wl='-Wl,'
6516       ;;
6517
6518     uts4*)
6519       lt_cv_prog_cc_pic='-pic'
6520       lt_cv_prog_cc_static='-Bstatic'
6521       ;;
6522
6523     sysv4*MP*)
6524       if test -d /usr/nec ;then
6525         lt_cv_prog_cc_pic='-Kconform_pic'
6526         lt_cv_prog_cc_static='-Bstatic'
6527       fi
6528       ;;
6529
6530     *)
6531       lt_cv_prog_cc_can_build_shared=no
6532       ;;
6533     esac
6534   fi
6535
6536 fi
6537
6538 if test -z "$lt_cv_prog_cc_pic"; then
6539   echo "$as_me:$LINENO: result: none" >&5
6540 echo "${ECHO_T}none" >&6
6541 else
6542   echo "$as_me:$LINENO: result: $lt_cv_prog_cc_pic" >&5
6543 echo "${ECHO_T}$lt_cv_prog_cc_pic" >&6
6544
6545   # Check to make sure the pic_flag actually works.
6546   echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_cv_prog_cc_pic works" >&5
6547 echo $ECHO_N "checking if $compiler PIC flag $lt_cv_prog_cc_pic works... $ECHO_C" >&6
6548   if test "${lt_cv_prog_cc_pic_works+set}" = set; then
6549   echo $ECHO_N "(cached) $ECHO_C" >&6
6550 else
6551       save_CFLAGS="$CFLAGS"
6552     CFLAGS="$CFLAGS $lt_cv_prog_cc_pic -DPIC"
6553     cat >conftest.$ac_ext <<_ACEOF
6554 #line $LINENO "configure"
6555 /* confdefs.h.  */
6556 _ACEOF
6557 cat confdefs.h >>conftest.$ac_ext
6558 cat >>conftest.$ac_ext <<_ACEOF
6559 /* end confdefs.h.  */
6560
6561 int
6562 main ()
6563 {
6564
6565   ;
6566   return 0;
6567 }
6568 _ACEOF
6569 rm -f conftest.$ac_objext
6570 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6571   (eval $ac_compile) 2>&5
6572   ac_status=$?
6573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6574   (exit $ac_status); } &&
6575          { ac_try='test -s conftest.$ac_objext'
6576   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6577   (eval $ac_try) 2>&5
6578   ac_status=$?
6579   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6580   (exit $ac_status); }; }; then
6581         case $host_os in
6582       hpux9* | hpux10* | hpux11*)
6583         # On HP-UX, both CC and GCC only warn that PIC is supported... then
6584         # they create non-PIC objects.  So, if there were any warnings, we
6585         # assume that PIC is not supported.
6586         if test -s conftest.err; then
6587           lt_cv_prog_cc_pic_works=no
6588         else
6589           lt_cv_prog_cc_pic_works=yes
6590         fi
6591         ;;
6592       *)
6593         lt_cv_prog_cc_pic_works=yes
6594         ;;
6595       esac
6596
6597 else
6598   echo "$as_me: failed program was:" >&5
6599 sed 's/^/| /' conftest.$ac_ext >&5
6600
6601       lt_cv_prog_cc_pic_works=no
6602
6603 fi
6604 rm -f conftest.$ac_objext conftest.$ac_ext
6605     CFLAGS="$save_CFLAGS"
6606
6607 fi
6608
6609
6610   if test "X$lt_cv_prog_cc_pic_works" = Xno; then
6611     lt_cv_prog_cc_pic=
6612     lt_cv_prog_cc_can_build_shared=no
6613   else
6614     lt_cv_prog_cc_pic=" $lt_cv_prog_cc_pic"
6615   fi
6616
6617   echo "$as_me:$LINENO: result: $lt_cv_prog_cc_pic_works" >&5
6618 echo "${ECHO_T}$lt_cv_prog_cc_pic_works" >&6
6619 fi
6620
6621 # Check for any special shared library compilation flags.
6622 if test -n "$lt_cv_prog_cc_shlib"; then
6623   { echo "$as_me:$LINENO: WARNING: \`$CC' requires \`$lt_cv_prog_cc_shlib' to build shared libraries" >&5
6624 echo "$as_me: WARNING: \`$CC' requires \`$lt_cv_prog_cc_shlib' to build shared libraries" >&2;}
6625   if echo "$old_CC $old_CFLAGS " | egrep -e "[  ]$lt_cv_prog_cc_shlib[  ]" >/dev/null; then :
6626   else
6627    { echo "$as_me:$LINENO: WARNING: add \`$lt_cv_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&5
6628 echo "$as_me: WARNING: add \`$lt_cv_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&2;}
6629     lt_cv_prog_cc_can_build_shared=no
6630   fi
6631 fi
6632
6633 echo "$as_me:$LINENO: checking if $compiler static flag $lt_cv_prog_cc_static works" >&5
6634 echo $ECHO_N "checking if $compiler static flag $lt_cv_prog_cc_static works... $ECHO_C" >&6
6635 if test "${lt_cv_prog_cc_static_works+set}" = set; then
6636   echo $ECHO_N "(cached) $ECHO_C" >&6
6637 else
6638     lt_cv_prog_cc_static_works=no
6639   save_LDFLAGS="$LDFLAGS"
6640   LDFLAGS="$LDFLAGS $lt_cv_prog_cc_static"
6641   cat >conftest.$ac_ext <<_ACEOF
6642 #line $LINENO "configure"
6643 /* confdefs.h.  */
6644 _ACEOF
6645 cat confdefs.h >>conftest.$ac_ext
6646 cat >>conftest.$ac_ext <<_ACEOF
6647 /* end confdefs.h.  */
6648
6649 int
6650 main ()
6651 {
6652
6653   ;
6654   return 0;
6655 }
6656 _ACEOF
6657 rm -f conftest.$ac_objext conftest$ac_exeext
6658 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6659   (eval $ac_link) 2>&5
6660   ac_status=$?
6661   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6662   (exit $ac_status); } &&
6663          { ac_try='test -s conftest$ac_exeext'
6664   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6665   (eval $ac_try) 2>&5
6666   ac_status=$?
6667   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6668   (exit $ac_status); }; }; then
6669   lt_cv_prog_cc_static_works=yes
6670 else
6671   echo "$as_me: failed program was:" >&5
6672 sed 's/^/| /' conftest.$ac_ext >&5
6673
6674 fi
6675 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6676   LDFLAGS="$save_LDFLAGS"
6677
6678 fi
6679
6680
6681 # Belt *and* braces to stop my trousers falling down:
6682 test "X$lt_cv_prog_cc_static_works" = Xno && lt_cv_prog_cc_static=
6683 echo "$as_me:$LINENO: result: $lt_cv_prog_cc_static_works" >&5
6684 echo "${ECHO_T}$lt_cv_prog_cc_static_works" >&6
6685
6686 pic_flag="$lt_cv_prog_cc_pic"
6687 special_shlib_compile_flags="$lt_cv_prog_cc_shlib"
6688 wl="$lt_cv_prog_cc_wl"
6689 link_static_flag="$lt_cv_prog_cc_static"
6690 no_builtin_flag="$lt_cv_prog_cc_no_builtin"
6691 can_build_shared="$lt_cv_prog_cc_can_build_shared"
6692
6693
6694 # Check to see if options -o and -c are simultaneously supported by compiler
6695 echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
6696 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6
6697 if test "${lt_cv_compiler_c_o+set}" = set; then
6698   echo $ECHO_N "(cached) $ECHO_C" >&6
6699 else
6700
6701 $rm -r conftest 2>/dev/null
6702 mkdir conftest
6703 cd conftest
6704 echo "int some_variable = 0;" > conftest.$ac_ext
6705 mkdir out
6706 # According to Tom Tromey, Ian Lance Taylor reported there are C compilers
6707 # that will create temporary files in the current directory regardless of
6708 # the output directory.  Thus, making CWD read-only will cause this test
6709 # to fail, enabling locking or at least warning the user not to do parallel
6710 # builds.
6711 chmod -w .
6712 save_CFLAGS="$CFLAGS"
6713 CFLAGS="$CFLAGS -o out/conftest2.$ac_objext"
6714 compiler_c_o=no
6715 if { (eval echo configure:6715: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.$ac_objext; then
6716   # The compiler can only warn and ignore the option if not recognized
6717   # So say no if there are warnings
6718   if test -s out/conftest.err; then
6719     lt_cv_compiler_c_o=no
6720   else
6721     lt_cv_compiler_c_o=yes
6722   fi
6723 else
6724   # Append any errors to the config.log.
6725   cat out/conftest.err 1>&5
6726   lt_cv_compiler_c_o=no
6727 fi
6728 CFLAGS="$save_CFLAGS"
6729 chmod u+w .
6730 $rm conftest* out/*
6731 rmdir out
6732 cd ..
6733 rmdir conftest
6734 $rm -r conftest 2>/dev/null
6735
6736 fi
6737
6738 compiler_c_o=$lt_cv_compiler_c_o
6739 echo "$as_me:$LINENO: result: $compiler_c_o" >&5
6740 echo "${ECHO_T}$compiler_c_o" >&6
6741
6742 if test x"$compiler_c_o" = x"yes"; then
6743   # Check to see if we can write to a .lo
6744   echo "$as_me:$LINENO: checking if $compiler supports -c -o file.lo" >&5
6745 echo $ECHO_N "checking if $compiler supports -c -o file.lo... $ECHO_C" >&6
6746   if test "${lt_cv_compiler_o_lo+set}" = set; then
6747   echo $ECHO_N "(cached) $ECHO_C" >&6
6748 else
6749
6750   lt_cv_compiler_o_lo=no
6751   save_CFLAGS="$CFLAGS"
6752   CFLAGS="$CFLAGS -c -o conftest.lo"
6753   save_objext="$ac_objext"
6754   ac_objext=lo
6755   cat >conftest.$ac_ext <<_ACEOF
6756 #line $LINENO "configure"
6757 /* confdefs.h.  */
6758 _ACEOF
6759 cat confdefs.h >>conftest.$ac_ext
6760 cat >>conftest.$ac_ext <<_ACEOF
6761 /* end confdefs.h.  */
6762
6763 int
6764 main ()
6765 {
6766 int some_variable = 0;
6767   ;
6768   return 0;
6769 }
6770 _ACEOF
6771 rm -f conftest.$ac_objext
6772 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6773   (eval $ac_compile) 2>&5
6774   ac_status=$?
6775   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6776   (exit $ac_status); } &&
6777          { ac_try='test -s conftest.$ac_objext'
6778   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6779   (eval $ac_try) 2>&5
6780   ac_status=$?
6781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6782   (exit $ac_status); }; }; then
6783       # The compiler can only warn and ignore the option if not recognized
6784     # So say no if there are warnings
6785     if test -s conftest.err; then
6786       lt_cv_compiler_o_lo=no
6787     else
6788       lt_cv_compiler_o_lo=yes
6789     fi
6790
6791 else
6792   echo "$as_me: failed program was:" >&5
6793 sed 's/^/| /' conftest.$ac_ext >&5
6794
6795 fi
6796 rm -f conftest.$ac_objext conftest.$ac_ext
6797   ac_objext="$save_objext"
6798   CFLAGS="$save_CFLAGS"
6799
6800 fi
6801
6802   compiler_o_lo=$lt_cv_compiler_o_lo
6803   echo "$as_me:$LINENO: result: $compiler_o_lo" >&5
6804 echo "${ECHO_T}$compiler_o_lo" >&6
6805 else
6806   compiler_o_lo=no
6807 fi
6808
6809 # Check to see if we can do hard links to lock some files if needed
6810 hard_links="nottested"
6811 if test "$compiler_c_o" = no && test "$need_locks" != no; then
6812   # do not overwrite the value of need_locks provided by the user
6813   echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
6814 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6
6815   hard_links=yes
6816   $rm conftest*
6817   ln conftest.a conftest.b 2>/dev/null && hard_links=no
6818   touch conftest.a
6819   ln conftest.a conftest.b 2>&5 || hard_links=no
6820   ln conftest.a conftest.b 2>/dev/null && hard_links=no
6821   echo "$as_me:$LINENO: result: $hard_links" >&5
6822 echo "${ECHO_T}$hard_links" >&6
6823   if test "$hard_links" = no; then
6824     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
6825 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
6826     need_locks=warn
6827   fi
6828 else
6829   need_locks=no
6830 fi
6831
6832 if test "$GCC" = yes; then
6833   # Check to see if options -fno-rtti -fno-exceptions are supported by compiler
6834   echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
6835 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6
6836   echo "int some_variable = 0;" > conftest.$ac_ext
6837   save_CFLAGS="$CFLAGS"
6838   CFLAGS="$CFLAGS -fno-rtti -fno-exceptions -c conftest.$ac_ext"
6839   compiler_rtti_exceptions=no
6840   cat >conftest.$ac_ext <<_ACEOF
6841 #line $LINENO "configure"
6842 /* confdefs.h.  */
6843 _ACEOF
6844 cat confdefs.h >>conftest.$ac_ext
6845 cat >>conftest.$ac_ext <<_ACEOF
6846 /* end confdefs.h.  */
6847
6848 int
6849 main ()
6850 {
6851 int some_variable = 0;
6852   ;
6853   return 0;
6854 }
6855 _ACEOF
6856 rm -f conftest.$ac_objext
6857 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6858   (eval $ac_compile) 2>&5
6859   ac_status=$?
6860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6861   (exit $ac_status); } &&
6862          { ac_try='test -s conftest.$ac_objext'
6863   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6864   (eval $ac_try) 2>&5
6865   ac_status=$?
6866   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6867   (exit $ac_status); }; }; then
6868       # The compiler can only warn and ignore the option if not recognized
6869     # So say no if there are warnings
6870     if test -s conftest.err; then
6871       compiler_rtti_exceptions=no
6872     else
6873       compiler_rtti_exceptions=yes
6874     fi
6875
6876 else
6877   echo "$as_me: failed program was:" >&5
6878 sed 's/^/| /' conftest.$ac_ext >&5
6879
6880 fi
6881 rm -f conftest.$ac_objext conftest.$ac_ext
6882   CFLAGS="$save_CFLAGS"
6883   echo "$as_me:$LINENO: result: $compiler_rtti_exceptions" >&5
6884 echo "${ECHO_T}$compiler_rtti_exceptions" >&6
6885
6886   if test "$compiler_rtti_exceptions" = "yes"; then
6887     no_builtin_flag=' -fno-builtin -fno-rtti -fno-exceptions'
6888   else
6889     no_builtin_flag=' -fno-builtin'
6890   fi
6891 fi
6892
6893 # See if the linker supports building shared libraries.
6894 echo "$as_me:$LINENO: checking whether the linker ($LD) supports shared libraries" >&5
6895 echo $ECHO_N "checking whether the linker ($LD) supports shared libraries... $ECHO_C" >&6
6896
6897 allow_undefined_flag=
6898 no_undefined_flag=
6899 need_lib_prefix=unknown
6900 need_version=unknown
6901 # when you set need_version to no, make sure it does not cause -set_version
6902 # flags to be left without arguments
6903 archive_cmds=
6904 archive_expsym_cmds=
6905 old_archive_from_new_cmds=
6906 old_archive_from_expsyms_cmds=
6907 export_dynamic_flag_spec=
6908 whole_archive_flag_spec=
6909 thread_safe_flag_spec=
6910 hardcode_into_libs=no
6911 hardcode_libdir_flag_spec=
6912 hardcode_libdir_separator=
6913 hardcode_direct=no
6914 hardcode_minus_L=no
6915 hardcode_shlibpath_var=unsupported
6916 runpath_var=
6917 link_all_deplibs=unknown
6918 always_export_symbols=no
6919 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | sed '\''s/.* //'\'' | sort | uniq > $export_symbols'
6920 # include_expsyms should be a list of space-separated symbols to be *always*
6921 # included in the symbol list
6922 include_expsyms=
6923 # exclude_expsyms can be an egrep regular expression of symbols to exclude
6924 # it will be wrapped by ` (' and `)$', so one must not match beginning or
6925 # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
6926 # as well as any symbol that contains `d'.
6927 exclude_expsyms="_GLOBAL_OFFSET_TABLE_"
6928 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
6929 # platforms (ab)use it in PIC code, but their linkers get confused if
6930 # the symbol is explicitly referenced.  Since portable code cannot
6931 # rely on this symbol name, it's probably fine to never include it in
6932 # preloaded symbol tables.
6933 extract_expsyms_cmds=
6934
6935 case $host_os in
6936 cygwin* | mingw* | pw32*)
6937   # FIXME: the MSVC++ port hasn't been tested in a loooong time
6938   # When not using gcc, we currently assume that we are using
6939   # Microsoft Visual C++.
6940   if test "$GCC" != yes; then
6941     with_gnu_ld=no
6942   fi
6943   ;;
6944 openbsd*)
6945   with_gnu_ld=no
6946   ;;
6947 esac
6948
6949 ld_shlibs=yes
6950 if test "$with_gnu_ld" = yes; then
6951   # If archive_cmds runs LD, not CC, wlarc should be empty
6952   wlarc='${wl}'
6953
6954   # See if GNU ld supports shared libraries.
6955   case $host_os in
6956   aix3* | aix4* | aix5*)
6957     # On AIX, the GNU linker is very broken
6958     # Note:Check GNU linker on AIX 5-IA64 when/if it becomes available.
6959     ld_shlibs=no
6960     cat <<EOF 1>&2
6961
6962 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
6963 *** to be unable to reliably create shared libraries on AIX.
6964 *** Therefore, libtool is disabling shared libraries support.  If you
6965 *** really care for shared libraries, you may want to modify your PATH
6966 *** so that a non-GNU linker is found, and then restart.
6967
6968 EOF
6969     ;;
6970
6971   amigaos*)
6972     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)'
6973     hardcode_libdir_flag_spec='-L$libdir'
6974     hardcode_minus_L=yes
6975
6976     # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
6977     # that the semantics of dynamic libraries on AmigaOS, at least up
6978     # to version 4, is to share data among multiple programs linked
6979     # with the same dynamic library.  Since this doesn't match the
6980     # behavior of shared libraries on other platforms, we can use
6981     # them.
6982     ld_shlibs=no
6983     ;;
6984
6985   beos*)
6986     if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
6987       allow_undefined_flag=unsupported
6988       # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
6989       # support --undefined.  This deserves some investigation.  FIXME
6990       archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6991     else
6992       ld_shlibs=no
6993     fi
6994     ;;
6995
6996   cygwin* | mingw* | pw32*)
6997     # hardcode_libdir_flag_spec is actually meaningless, as there is
6998     # no search path for DLLs.
6999     hardcode_libdir_flag_spec='-L$libdir'
7000     allow_undefined_flag=unsupported
7001     always_export_symbols=yes
7002
7003     extract_expsyms_cmds='test -f $output_objdir/impgen.c || \
7004       sed -e "/^# \/\* impgen\.c starts here \*\//,/^# \/\* impgen.c ends here \*\// { s/^# //;s/^# *$//; p; }" -e d < $''0 > $output_objdir/impgen.c~
7005       test -f $output_objdir/impgen.exe || (cd $output_objdir && \
7006       if test "x$HOST_CC" != "x" ; then $HOST_CC -o impgen impgen.c ; \
7007       else $CC -o impgen impgen.c ; fi)~
7008       $output_objdir/impgen $dir/$soroot > $output_objdir/$soname-def'
7009
7010     old_archive_from_expsyms_cmds='$DLLTOOL --as=$AS --dllname $soname --def $output_objdir/$soname-def --output-lib $output_objdir/$newlib'
7011
7012     # cygwin and mingw dlls have different entry points and sets of symbols
7013     # to exclude.
7014     # FIXME: what about values for MSVC?
7015     dll_entry=__cygwin_dll_entry@12
7016     dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12~
7017     case $host_os in
7018     mingw*)
7019       # mingw values
7020       dll_entry=_DllMainCRTStartup@12
7021       dll_exclude_symbols=DllMain@12,DllMainCRTStartup@12,DllEntryPoint@12~
7022       ;;
7023     esac
7024
7025     # mingw and cygwin differ, and it's simplest to just exclude the union
7026     # of the two symbol sets.
7027     dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12,DllMainCRTStartup@12,DllEntryPoint@12
7028
7029     # recent cygwin and mingw systems supply a stub DllMain which the user
7030     # can override, but on older systems we have to supply one (in ltdll.c)
7031     if test "x$lt_cv_need_dllmain" = "xyes"; then
7032       ltdll_obj='$output_objdir/$soname-ltdll.'"$ac_objext "
7033       ltdll_cmds='test -f $output_objdir/$soname-ltdll.c || sed -e "/^# \/\* ltdll\.c starts here \*\//,/^# \/\* ltdll.c ends here \*\// { s/^# //; p; }" -e d < $''0 > $output_objdir/$soname-ltdll.c~
7034         test -f $output_objdir/$soname-ltdll.$ac_objext || (cd $output_objdir && $CC -c $soname-ltdll.c)~'
7035     else
7036       ltdll_obj=
7037       ltdll_cmds=
7038     fi
7039
7040     # Extract the symbol export list from an `--export-all' def file,
7041     # then regenerate the def file from the symbol export list, so that
7042     # the compiled dll only exports the symbol export list.
7043     # Be careful not to strip the DATA tag left be newer dlltools.
7044     export_symbols_cmds="$ltdll_cmds"'
7045       $DLLTOOL --export-all --exclude-symbols '$dll_exclude_symbols' --output-def $output_objdir/$soname-def '$ltdll_obj'$libobjs $convenience~
7046       sed -e "1,/EXPORTS/d" -e "s/ @ [0-9]*//" -e "s/ *;.*$//" < $output_objdir/$soname-def > $export_symbols'
7047
7048     # If the export-symbols file already is a .def file (1st line
7049     # is EXPORTS), use it as is.
7050     # If DATA tags from a recent dlltool are present, honour them!
7051     archive_expsym_cmds='if test "x`sed 1q $export_symbols`" = xEXPORTS; then
7052         cp $export_symbols $output_objdir/$soname-def;
7053       else
7054         echo EXPORTS > $output_objdir/$soname-def;
7055         _lt_hint=1;
7056         cat $export_symbols | while read symbol; do
7057          set dummy \$symbol;
7058          case \$# in
7059            2) echo "   \$2 @ \$_lt_hint ; " >> $output_objdir/$soname-def;;
7060            4) echo "   \$2 \$3 \$4 ; " >> $output_objdir/$soname-def; _lt_hint=`expr \$_lt_hint - 1`;;
7061            *) echo "     \$2 @ \$_lt_hint \$3 ; " >> $output_objdir/$soname-def;;
7062          esac;
7063          _lt_hint=`expr 1 + \$_lt_hint`;
7064         done;
7065       fi~
7066       '"$ltdll_cmds"'
7067       $CC -Wl,--base-file,$output_objdir/$soname-base '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags~
7068       $DLLTOOL --as=$AS --dllname $soname --exclude-symbols '$dll_exclude_symbols' --def $output_objdir/$soname-def --base-file $output_objdir/$soname-base --output-exp $output_objdir/$soname-exp~
7069       $CC -Wl,--base-file,$output_objdir/$soname-base $output_objdir/$soname-exp '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags~
7070       $DLLTOOL --as=$AS --dllname $soname --exclude-symbols '$dll_exclude_symbols' --def $output_objdir/$soname-def --base-file $output_objdir/$soname-base --output-exp $output_objdir/$soname-exp --output-lib $output_objdir/$libname.dll.a~
7071       $CC $output_objdir/$soname-exp '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags'
7072     ;;
7073
7074   netbsd*)
7075     if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
7076       archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
7077       wlarc=
7078     else
7079       archive_cmds='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7080       archive_expsym_cmds='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
7081     fi
7082     ;;
7083
7084   solaris* | sysv5*)
7085     if $LD -v 2>&1 | egrep 'BFD 2\.8' > /dev/null; then
7086       ld_shlibs=no
7087       cat <<EOF 1>&2
7088
7089 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
7090 *** create shared libraries on Solaris systems.  Therefore, libtool
7091 *** is disabling shared libraries support.  We urge you to upgrade GNU
7092 *** binutils to release 2.9.1 or newer.  Another option is to modify
7093 *** your PATH or compiler configuration so that the native linker is
7094 *** used, and then restart.
7095
7096 EOF
7097     elif $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
7098       archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7099       archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
7100     else
7101       ld_shlibs=no
7102     fi
7103     ;;
7104
7105   sunos4*)
7106     archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
7107     wlarc=
7108     hardcode_direct=yes
7109     hardcode_shlibpath_var=no
7110     ;;
7111
7112   *)
7113     if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
7114       archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
7115       archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
7116     else
7117       ld_shlibs=no
7118     fi
7119     ;;
7120   esac
7121
7122   if test "$ld_shlibs" = yes; then
7123     runpath_var=LD_RUN_PATH
7124     hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir'
7125     export_dynamic_flag_spec='${wl}--export-dynamic'
7126     case $host_os in
7127     cygwin* | mingw* | pw32*)
7128       # dlltool doesn't understand --whole-archive et. al.
7129       whole_archive_flag_spec=
7130       ;;
7131     *)
7132       # ancient GNU ld didn't support --whole-archive et. al.
7133       if $LD --help 2>&1 | egrep 'no-whole-archive' > /dev/null; then
7134         whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
7135       else
7136         whole_archive_flag_spec=
7137       fi
7138       ;;
7139     esac
7140   fi
7141 else
7142   # PORTME fill in a description of your system's linker (not GNU ld)
7143   case $host_os in
7144   aix3*)
7145     allow_undefined_flag=unsupported
7146     always_export_symbols=yes
7147     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'
7148     # Note: this linker hardcodes the directories in LIBPATH if there
7149     # are no directories specified by -L.
7150     hardcode_minus_L=yes
7151     if test "$GCC" = yes && test -z "$link_static_flag"; then
7152       # Neither direct hardcoding nor static linking is supported with a
7153       # broken collect2.
7154       hardcode_direct=unsupported
7155     fi
7156     ;;
7157
7158   aix4* | aix5*)
7159     if test "$host_cpu" = ia64; then
7160       # On IA64, the linker does run time linking by default, so we don't
7161       # have to do anything special.
7162       aix_use_runtimelinking=no
7163       exp_sym_flag='-Bexport'
7164       no_entry_flag=""
7165     else
7166       aix_use_runtimelinking=no
7167
7168       # Test if we are trying to use run time linking or normal
7169       # AIX style linking. If -brtl is somewhere in LDFLAGS, we
7170       # need to do runtime linking.
7171       case $host_os in aix4.[23]|aix4.[23].*|aix5*)
7172         for ld_flag in $LDFLAGS; do
7173           case $ld_flag in
7174           *-brtl*)
7175             aix_use_runtimelinking=yes
7176             break
7177           ;;
7178           esac
7179         done
7180       esac
7181
7182       exp_sym_flag='-bexport'
7183       no_entry_flag='-bnoentry'
7184     fi
7185
7186     # When large executables or shared objects are built, AIX ld can
7187     # have problems creating the table of contents.  If linking a library
7188     # or program results in "error TOC overflow" add -mminimal-toc to
7189     # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
7190     # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
7191
7192     hardcode_direct=yes
7193     archive_cmds=''
7194     hardcode_libdir_separator=':'
7195     if test "$GCC" = yes; then
7196       case $host_os in aix4.[012]|aix4.[012].*)
7197         collect2name=`${CC} -print-prog-name=collect2`
7198         if test -f "$collect2name" && \
7199           strings "$collect2name" | grep resolve_lib_name >/dev/null
7200         then
7201           # We have reworked collect2
7202           hardcode_direct=yes
7203         else
7204           # We have old collect2
7205           hardcode_direct=unsupported
7206           # It fails to find uninstalled libraries when the uninstalled
7207           # path is not listed in the libpath.  Setting hardcode_minus_L
7208           # to unsupported forces relinking
7209           hardcode_minus_L=yes
7210           hardcode_libdir_flag_spec='-L$libdir'
7211           hardcode_libdir_separator=
7212         fi
7213       esac
7214
7215       shared_flag='-shared'
7216     else
7217       # not using gcc
7218       if test "$host_cpu" = ia64; then
7219         shared_flag='${wl}-G'
7220       else
7221         if test "$aix_use_runtimelinking" = yes; then
7222           shared_flag='${wl}-G'
7223         else
7224           shared_flag='${wl}-bM:SRE'
7225         fi
7226       fi
7227     fi
7228
7229     # It seems that -bexpall can do strange things, so it is better to
7230     # generate a list of symbols to export.
7231     always_export_symbols=yes
7232     if test "$aix_use_runtimelinking" = yes; then
7233       # Warning - without using the other runtime loading flags (-brtl),
7234       # -berok will link without error, but may produce a broken library.
7235       allow_undefined_flag='-berok'
7236       hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:/usr/lib:/lib'
7237       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"
7238     else
7239       if test "$host_cpu" = ia64; then
7240         hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
7241         allow_undefined_flag="-z nodefs"
7242         archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname ${wl}-h$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
7243       else
7244         hardcode_libdir_flag_spec='${wl}-bnolibpath ${wl}-blibpath:$libdir:/usr/lib:/lib'
7245         # Warning - without using the other run time loading flags,
7246         # -berok will link without error, but may produce a broken library.
7247         allow_undefined_flag='${wl}-berok'
7248         # This is a bit strange, but is similar to how AIX traditionally builds
7249         # it's shared libraries.
7250         archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"' ~$AR -crlo $objdir/$libname$release.a $objdir/$soname'
7251       fi
7252     fi
7253     ;;
7254
7255   amigaos*)
7256     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)'
7257     hardcode_libdir_flag_spec='-L$libdir'
7258     hardcode_minus_L=yes
7259     # see comment about different semantics on the GNU ld section
7260     ld_shlibs=no
7261     ;;
7262
7263   cygwin* | mingw* | pw32*)
7264     # When not using gcc, we currently assume that we are using
7265     # Microsoft Visual C++.
7266     # hardcode_libdir_flag_spec is actually meaningless, as there is
7267     # no search path for DLLs.
7268     hardcode_libdir_flag_spec=' '
7269     allow_undefined_flag=unsupported
7270     # Tell ltmain to make .lib files, not .a files.
7271     libext=lib
7272     # FIXME: Setting linknames here is a bad hack.
7273     archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | sed -e '\''s/ -lc$//'\''` -link -dll~linknames='
7274     # The linker will automatically build a .lib file if we build a DLL.
7275     old_archive_from_new_cmds='true'
7276     # FIXME: Should let the user specify the lib program.
7277     old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs'
7278     fix_srcfile_path='`cygpath -w "$srcfile"`'
7279     ;;
7280
7281   darwin* | rhapsody*)
7282     case "$host_os" in
7283     rhapsody* | darwin1.[012])
7284       allow_undefined_flag='-undefined suppress'
7285       ;;
7286     *) # Darwin 1.3 on
7287       allow_undefined_flag='-flat_namespace -undefined suppress'
7288       ;;
7289     esac
7290     # FIXME: Relying on posixy $() will cause problems for
7291     #        cross-compilation, but unfortunately the echo tests do not
7292     #        yet detect zsh echo's removal of \ escapes.  Also zsh mangles
7293     #        `"' quotes if we put them in here... so don't!
7294     archive_cmds='$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs && $CC $(test .$module = .yes && echo -bundle || echo -dynamiclib) $allow_undefined_flag -o $lib ${lib}-master.o $deplibs$linker_flags $(test .$module != .yes && echo -install_name $rpath/$soname $verstring)'
7295     # We need to add '_' to the symbols in $export_symbols first
7296     #archive_expsym_cmds="$archive_cmds"' && strip -s $export_symbols'
7297     hardcode_direct=yes
7298     hardcode_shlibpath_var=no
7299     whole_archive_flag_spec='-all_load $convenience'
7300     ;;
7301
7302   freebsd1*)
7303     ld_shlibs=no
7304     ;;
7305
7306   # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
7307   # support.  Future versions do this automatically, but an explicit c++rt0.o
7308   # does not break anything, and helps significantly (at the cost of a little
7309   # extra space).
7310   freebsd2.2*)
7311     archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
7312     hardcode_libdir_flag_spec='-R$libdir'
7313     hardcode_direct=yes
7314     hardcode_shlibpath_var=no
7315     ;;
7316
7317   # Unfortunately, older versions of FreeBSD 2 do not have this feature.
7318   freebsd2*)
7319     archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
7320     hardcode_direct=yes
7321     hardcode_minus_L=yes
7322     hardcode_shlibpath_var=no
7323     ;;
7324
7325   # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
7326   freebsd*)
7327     archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
7328     hardcode_libdir_flag_spec='-R$libdir'
7329     hardcode_direct=yes
7330     hardcode_shlibpath_var=no
7331     ;;
7332
7333   hpux9* | hpux10* | hpux11*)
7334     case $host_os in
7335     hpux9*) 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' ;;
7336     *) archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' ;;
7337     esac
7338     hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
7339     hardcode_libdir_separator=:
7340     hardcode_direct=yes
7341     hardcode_minus_L=yes # Not in the search PATH, but as the default
7342                          # location of the library.
7343     export_dynamic_flag_spec='${wl}-E'
7344     ;;
7345
7346   irix5* | irix6* | nonstopux*)
7347     if test "$GCC" = yes; then
7348       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'
7349       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
7350     else
7351       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'
7352       hardcode_libdir_flag_spec='-rpath $libdir'
7353     fi
7354     hardcode_libdir_separator=:
7355     link_all_deplibs=yes
7356     ;;
7357
7358   netbsd*)
7359     if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
7360       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
7361     else
7362       archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
7363     fi
7364     hardcode_libdir_flag_spec='-R$libdir'
7365     hardcode_direct=yes
7366     hardcode_shlibpath_var=no
7367     ;;
7368
7369   newsos6)
7370     archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7371     hardcode_direct=yes
7372     hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
7373     hardcode_libdir_separator=:
7374     hardcode_shlibpath_var=no
7375     ;;
7376
7377   openbsd*)
7378     hardcode_direct=yes
7379     hardcode_shlibpath_var=no
7380     if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
7381       archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
7382       hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
7383       export_dynamic_flag_spec='${wl}-E'
7384     else
7385       case "$host_os" in
7386       openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
7387         archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
7388         hardcode_libdir_flag_spec='-R$libdir'
7389         ;;
7390       *)
7391         archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
7392         hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
7393         ;;
7394       esac
7395     fi
7396     ;;
7397
7398   os2*)
7399     hardcode_libdir_flag_spec='-L$libdir'
7400     hardcode_minus_L=yes
7401     allow_undefined_flag=unsupported
7402     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'
7403     old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
7404     ;;
7405
7406   osf3*)
7407     if test "$GCC" = yes; then
7408       allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
7409       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'
7410     else
7411       allow_undefined_flag=' -expect_unresolved \*'
7412       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'
7413     fi
7414     hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
7415     hardcode_libdir_separator=:
7416     ;;
7417
7418   osf4* | osf5*)        # as osf3* with the addition of -msym flag
7419     if test "$GCC" = yes; then
7420       allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
7421       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'
7422       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
7423     else
7424       allow_undefined_flag=' -expect_unresolved \*'
7425       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'
7426       archive_expsym_cmds='for i in `cat $export_symbols`; do printf "-exported_symbol " >> $lib.exp; echo "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
7427       $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib~$rm $lib.exp'
7428
7429       #Both c and cxx compiler support -rpath directly
7430       hardcode_libdir_flag_spec='-rpath $libdir'
7431     fi
7432     hardcode_libdir_separator=:
7433     ;;
7434
7435   sco3.2v5*)
7436     archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7437     hardcode_shlibpath_var=no
7438     runpath_var=LD_RUN_PATH
7439     hardcode_runpath_var=yes
7440     export_dynamic_flag_spec='${wl}-Bexport'
7441     ;;
7442
7443   solaris*)
7444     # gcc --version < 3.0 without binutils cannot create self contained
7445     # shared libraries reliably, requiring libgcc.a to resolve some of
7446     # the object symbols generated in some cases.  Libraries that use
7447     # assert need libgcc.a to resolve __eprintf, for example.  Linking
7448     # a copy of libgcc.a into every shared library to guarantee resolving
7449     # such symbols causes other problems:  According to Tim Van Holder
7450     # <tim.van.holder@pandora.be>, C++ libraries end up with a separate
7451     # (to the application) exception stack for one thing.
7452     no_undefined_flag=' -z defs'
7453     if test "$GCC" = yes; then
7454       case `$CC --version 2>/dev/null` in
7455       [12].*)
7456         cat <<EOF 1>&2
7457
7458 *** Warning: Releases of GCC earlier than version 3.0 cannot reliably
7459 *** create self contained shared libraries on Solaris systems, without
7460 *** introducing a dependency on libgcc.a.  Therefore, libtool is disabling
7461 *** -no-undefined support, which will at least allow you to build shared
7462 *** libraries.  However, you may find that when you link such libraries
7463 *** into an application without using GCC, you have to manually add
7464 *** \`gcc --print-libgcc-file-name\` to the link command.  We urge you to
7465 *** upgrade to a newer version of GCC.  Another option is to rebuild your
7466 *** current GCC to use the GNU linker from GNU binutils 2.9.1 or newer.
7467
7468 EOF
7469         no_undefined_flag=
7470         ;;
7471       esac
7472     fi
7473     # $CC -shared without GNU ld will not create a library from C++
7474     # object files and a static libstdc++, better avoid it by now
7475     archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
7476     archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
7477                 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
7478     hardcode_libdir_flag_spec='-R$libdir'
7479     hardcode_shlibpath_var=no
7480     case $host_os in
7481     solaris2.[0-5] | solaris2.[0-5].*) ;;
7482     *) # Supported since Solaris 2.6 (maybe 2.5.1?)
7483       whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;;
7484     esac
7485     link_all_deplibs=yes
7486     ;;
7487
7488   sunos4*)
7489     if test "x$host_vendor" = xsequent; then
7490       # Use $CC to link under sequent, because it throws in some extra .o
7491       # files that make .init and .fini sections work.
7492       archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
7493     else
7494       archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
7495     fi
7496     hardcode_libdir_flag_spec='-L$libdir'
7497     hardcode_direct=yes
7498     hardcode_minus_L=yes
7499     hardcode_shlibpath_var=no
7500     ;;
7501
7502   sysv4)
7503     case $host_vendor in
7504       sni)
7505         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7506         hardcode_direct=yes # is this really true???
7507         ;;
7508       siemens)
7509         ## LD is ld it makes a PLAMLIB
7510         ## CC just makes a GrossModule.
7511         archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
7512         reload_cmds='$CC -r -o $output$reload_objs'
7513         hardcode_direct=no
7514         ;;
7515       motorola)
7516         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7517         hardcode_direct=no #Motorola manual says yes, but my tests say they lie
7518         ;;
7519     esac
7520     runpath_var='LD_RUN_PATH'
7521     hardcode_shlibpath_var=no
7522     ;;
7523
7524   sysv4.3*)
7525     archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7526     hardcode_shlibpath_var=no
7527     export_dynamic_flag_spec='-Bexport'
7528     ;;
7529
7530   sysv5*)
7531     no_undefined_flag=' -z text'
7532     # $CC -shared without GNU ld will not create a library from C++
7533     # object files and a static libstdc++, better avoid it by now
7534     archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
7535     archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
7536                 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
7537     hardcode_libdir_flag_spec=
7538     hardcode_shlibpath_var=no
7539     runpath_var='LD_RUN_PATH'
7540     ;;
7541
7542   uts4*)
7543     archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7544     hardcode_libdir_flag_spec='-L$libdir'
7545     hardcode_shlibpath_var=no
7546     ;;
7547
7548   dgux*)
7549     archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7550     hardcode_libdir_flag_spec='-L$libdir'
7551     hardcode_shlibpath_var=no
7552     ;;
7553
7554   sysv4*MP*)
7555     if test -d /usr/nec; then
7556       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7557       hardcode_shlibpath_var=no
7558       runpath_var=LD_RUN_PATH
7559       hardcode_runpath_var=yes
7560       ld_shlibs=yes
7561     fi
7562     ;;
7563
7564   sysv4.2uw2*)
7565     archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
7566     hardcode_direct=yes
7567     hardcode_minus_L=no
7568     hardcode_shlibpath_var=no
7569     hardcode_runpath_var=yes
7570     runpath_var=LD_RUN_PATH
7571     ;;
7572
7573   sysv5uw7* | unixware7*)
7574     no_undefined_flag='${wl}-z ${wl}text'
7575     if test "$GCC" = yes; then
7576       archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
7577     else
7578       archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
7579     fi
7580     runpath_var='LD_RUN_PATH'
7581     hardcode_shlibpath_var=no
7582     ;;
7583
7584   *)
7585     ld_shlibs=no
7586     ;;
7587   esac
7588 fi
7589 echo "$as_me:$LINENO: result: $ld_shlibs" >&5
7590 echo "${ECHO_T}$ld_shlibs" >&6
7591 test "$ld_shlibs" = no && can_build_shared=no
7592
7593 # Check hardcoding attributes.
7594 echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
7595 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6
7596 hardcode_action=
7597 if test -n "$hardcode_libdir_flag_spec" || \
7598    test -n "$runpath_var"; then
7599
7600   # We can hardcode non-existant directories.
7601   if test "$hardcode_direct" != no &&
7602      # If the only mechanism to avoid hardcoding is shlibpath_var, we
7603      # have to relink, otherwise we might link with an installed library
7604      # when we should be linking with a yet-to-be-installed one
7605      ## test "$hardcode_shlibpath_var" != no &&
7606      test "$hardcode_minus_L" != no; then
7607     # Linking always hardcodes the temporary library directory.
7608     hardcode_action=relink
7609   else
7610     # We can link without hardcoding, and we can hardcode nonexisting dirs.
7611     hardcode_action=immediate
7612   fi
7613 else
7614   # We cannot hardcode anything, or else we can only hardcode existing
7615   # directories.
7616   hardcode_action=unsupported
7617 fi
7618 echo "$as_me:$LINENO: result: $hardcode_action" >&5
7619 echo "${ECHO_T}$hardcode_action" >&6
7620
7621 striplib=
7622 old_striplib=
7623 echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5
7624 echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&6
7625 if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
7626   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
7627   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
7628   echo "$as_me:$LINENO: result: yes" >&5
7629 echo "${ECHO_T}yes" >&6
7630 else
7631   echo "$as_me:$LINENO: result: no" >&5
7632 echo "${ECHO_T}no" >&6
7633 fi
7634
7635 reload_cmds='$LD$reload_flag -o $output$reload_objs'
7636 test -z "$deplibs_check_method" && deplibs_check_method=unknown
7637
7638 # PORTME Fill in your ld.so characteristics
7639 echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
7640 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6
7641 library_names_spec=
7642 libname_spec='lib$name'
7643 soname_spec=
7644 postinstall_cmds=
7645 postuninstall_cmds=
7646 finish_cmds=
7647 finish_eval=
7648 shlibpath_var=
7649 shlibpath_overrides_runpath=unknown
7650 version_type=none
7651 dynamic_linker="$host_os ld.so"
7652 sys_lib_dlsearch_path_spec="/lib /usr/lib"
7653 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
7654
7655 case $host_os in
7656 aix3*)
7657   version_type=linux
7658   library_names_spec='${libname}${release}.so$versuffix $libname.a'
7659   shlibpath_var=LIBPATH
7660
7661   # AIX has no versioning support, so we append a major version to the name.
7662   soname_spec='${libname}${release}.so$major'
7663   ;;
7664
7665 aix4* | aix5*)
7666   version_type=linux
7667   need_lib_prefix=no
7668   need_version=no
7669   hardcode_into_libs=yes
7670   if test "$host_cpu" = ia64; then
7671     # AIX 5 supports IA64
7672     library_names_spec='${libname}${release}.so$major ${libname}${release}.so$versuffix $libname.so'
7673     shlibpath_var=LD_LIBRARY_PATH
7674   else
7675     # With GCC up to 2.95.x, collect2 would create an import file
7676     # for dependence libraries.  The import file would start with
7677     # the line `#! .'.  This would cause the generated library to
7678     # depend on `.', always an invalid library.  This was fixed in
7679     # development snapshots of GCC prior to 3.0.
7680     case $host_os in
7681       aix4 | aix4.[01] | aix4.[01].*)
7682         if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
7683              echo ' yes '
7684              echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
7685           :
7686         else
7687           can_build_shared=no
7688         fi
7689         ;;
7690     esac
7691     # AIX (on Power*) has no versioning support, so currently we can
7692     # not hardcode correct soname into executable. Probably we can
7693     # add versioning support to collect2, so additional links can
7694     # be useful in future.
7695     if test "$aix_use_runtimelinking" = yes; then
7696       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
7697       # instead of lib<name>.a to let people know that these are not
7698       # typical AIX shared libraries.
7699       library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
7700     else
7701       # We preserve .a as extension for shared libraries through AIX4.2
7702       # and later when we are not doing run time linking.
7703       library_names_spec='${libname}${release}.a $libname.a'
7704       soname_spec='${libname}${release}.so$major'
7705     fi
7706     shlibpath_var=LIBPATH
7707   fi
7708   hardcode_into_libs=yes
7709   ;;
7710
7711 amigaos*)
7712   library_names_spec='$libname.ixlibrary $libname.a'
7713   # Create ${libname}_ixlibrary.a entries in /sys/libs.
7714   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'
7715   ;;
7716
7717 beos*)
7718   library_names_spec='${libname}.so'
7719   dynamic_linker="$host_os ld.so"
7720   shlibpath_var=LIBRARY_PATH
7721   ;;
7722
7723 bsdi4*)
7724   version_type=linux
7725   need_version=no
7726   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
7727   soname_spec='${libname}${release}.so$major'
7728   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
7729   shlibpath_var=LD_LIBRARY_PATH
7730   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
7731   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
7732   export_dynamic_flag_spec=-rdynamic
7733   # the default ld.so.conf also contains /usr/contrib/lib and
7734   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
7735   # libtool to hard-code these into programs
7736   ;;
7737
7738 cygwin* | mingw* | pw32*)
7739   version_type=windows
7740   need_version=no
7741   need_lib_prefix=no
7742   case $GCC,$host_os in
7743   yes,cygwin*)
7744     library_names_spec='$libname.dll.a'
7745     soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll'
7746     postinstall_cmds='dlpath=`bash 2>&1 -c '\''. $dir/${file}i;echo \$dlname'\''`~
7747       dldir=$destdir/`dirname \$dlpath`~
7748       test -d \$dldir || mkdir -p \$dldir~
7749       $install_prog .libs/$dlname \$dldir/$dlname'
7750     postuninstall_cmds='dldll=`bash 2>&1 -c '\''. $file; echo \$dlname'\''`~
7751       dlpath=$dir/\$dldll~
7752        $rm \$dlpath'
7753     ;;
7754   yes,mingw*)
7755     library_names_spec='${libname}`echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll'
7756     sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | sed -e "s/^libraries://" -e "s/;/ /g" -e "s,=/,/,g"`
7757     ;;
7758   yes,pw32*)
7759     library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | sed -e 's/./-/g'`${versuffix}.dll'
7760     ;;
7761   *)
7762     library_names_spec='${libname}`echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll $libname.lib'
7763     ;;
7764   esac
7765   dynamic_linker='Win32 ld.exe'
7766   # FIXME: first we should search . and the directory the executable is in
7767   shlibpath_var=PATH
7768   ;;
7769
7770 darwin* | rhapsody*)
7771   dynamic_linker="$host_os dyld"
7772   version_type=darwin
7773   need_lib_prefix=no
7774   need_version=no
7775   # FIXME: Relying on posixy $() will cause problems for
7776   #        cross-compilation, but unfortunately the echo tests do not
7777   #        yet detect zsh echo's removal of \ escapes.
7778   library_names_spec='${libname}${release}${versuffix}.$(test .$module = .yes && echo so || echo dylib) ${libname}${release}${major}.$(test .$module = .yes && echo so || echo dylib) ${libname}.$(test .$module = .yes && echo so || echo dylib)'
7779   soname_spec='${libname}${release}${major}.$(test .$module = .yes && echo so || echo dylib)'
7780   shlibpath_overrides_runpath=yes
7781   shlibpath_var=DYLD_LIBRARY_PATH
7782   ;;
7783
7784 freebsd1*)
7785   dynamic_linker=no
7786   ;;
7787
7788 freebsd*)
7789   objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
7790   version_type=freebsd-$objformat
7791   case $version_type in
7792     freebsd-elf*)
7793       library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so $libname.so'
7794       need_version=no
7795       need_lib_prefix=no
7796       ;;
7797     freebsd-*)
7798       library_names_spec='${libname}${release}.so$versuffix $libname.so$versuffix'
7799       need_version=yes
7800       ;;
7801   esac
7802   shlibpath_var=LD_LIBRARY_PATH
7803   case $host_os in
7804   freebsd2*)
7805     shlibpath_overrides_runpath=yes
7806     ;;
7807   *)
7808     shlibpath_overrides_runpath=no
7809     hardcode_into_libs=yes
7810     ;;
7811   esac
7812   ;;
7813
7814 gnu*)
7815   version_type=linux
7816   need_lib_prefix=no
7817   need_version=no
7818   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so${major} ${libname}.so'
7819   soname_spec='${libname}${release}.so$major'
7820   shlibpath_var=LD_LIBRARY_PATH
7821   hardcode_into_libs=yes
7822   ;;
7823
7824 hpux9* | hpux10* | hpux11*)
7825   # Give a soname corresponding to the major version so that dld.sl refuses to
7826   # link against other versions.
7827   dynamic_linker="$host_os dld.sl"
7828   version_type=sunos
7829   need_lib_prefix=no
7830   need_version=no
7831   shlibpath_var=SHLIB_PATH
7832   shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
7833   library_names_spec='${libname}${release}.sl$versuffix ${libname}${release}.sl$major $libname.sl'
7834   soname_spec='${libname}${release}.sl$major'
7835   # HP-UX runs *really* slowly unless shared libraries are mode 555.
7836   postinstall_cmds='chmod 555 $lib'
7837   ;;
7838
7839 irix5* | irix6* | nonstopux*)
7840   case $host_os in
7841     nonstopux*) version_type=nonstopux ;;
7842     *)          version_type=irix ;;
7843   esac
7844   need_lib_prefix=no
7845   need_version=no
7846   soname_spec='${libname}${release}.so$major'
7847   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major ${libname}${release}.so $libname.so'
7848   case $host_os in
7849   irix5* | nonstopux*)
7850     libsuff= shlibsuff=
7851     ;;
7852   *)
7853     case $LD in # libtool.m4 will add one of these switches to LD
7854     *-32|*"-32 ") libsuff= shlibsuff= libmagic=32-bit;;
7855     *-n32|*"-n32 ") libsuff=32 shlibsuff=N32 libmagic=N32;;
7856     *-64|*"-64 ") libsuff=64 shlibsuff=64 libmagic=64-bit;;
7857     *) libsuff= shlibsuff= libmagic=never-match;;
7858     esac
7859     ;;
7860   esac
7861   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
7862   shlibpath_overrides_runpath=no
7863   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
7864   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
7865   ;;
7866
7867 # No shared lib support for Linux oldld, aout, or coff.
7868 linux-gnuoldld* | linux-gnuaout* | linux-gnucoff*)
7869   dynamic_linker=no
7870   ;;
7871
7872 # This must be Linux ELF.
7873 linux-gnu*)
7874   version_type=linux
7875   need_lib_prefix=no
7876   need_version=no
7877   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
7878   soname_spec='${libname}${release}.so$major'
7879   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
7880   shlibpath_var=LD_LIBRARY_PATH
7881   shlibpath_overrides_runpath=no
7882   # This implies no fast_install, which is unacceptable.
7883   # Some rework will be needed to allow for fast_install
7884   # before this can be enabled.
7885   hardcode_into_libs=yes
7886
7887   # We used to test for /lib/ld.so.1 and disable shared libraries on
7888   # powerpc, because MkLinux only supported shared libraries with the
7889   # GNU dynamic linker.  Since this was broken with cross compilers,
7890   # most powerpc-linux boxes support dynamic linking these days and
7891   # people can always --disable-shared, the test was removed, and we
7892   # assume the GNU/Linux dynamic linker is in use.
7893   dynamic_linker='GNU/Linux ld.so'
7894   ;;
7895
7896 netbsd*)
7897   version_type=sunos
7898   need_lib_prefix=no
7899   need_version=no
7900   if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
7901     library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
7902     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
7903     dynamic_linker='NetBSD (a.out) ld.so'
7904   else
7905     library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major ${libname}${release}.so ${libname}.so'
7906     soname_spec='${libname}${release}.so$major'
7907     dynamic_linker='NetBSD ld.elf_so'
7908   fi
7909   shlibpath_var=LD_LIBRARY_PATH
7910   shlibpath_overrides_runpath=yes
7911   hardcode_into_libs=yes
7912   ;;
7913
7914 newsos6)
7915   version_type=linux
7916   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
7917   shlibpath_var=LD_LIBRARY_PATH
7918   shlibpath_overrides_runpath=yes
7919   ;;
7920
7921 openbsd*)
7922   version_type=sunos
7923   need_lib_prefix=no
7924   need_version=no
7925   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
7926     case "$host_os" in
7927     openbsd2.[89] | openbsd2.[89].*)
7928       shlibpath_overrides_runpath=no
7929       ;;
7930     *)
7931       shlibpath_overrides_runpath=yes
7932       ;;
7933     esac
7934   else
7935     shlibpath_overrides_runpath=yes
7936   fi
7937   library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
7938   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
7939   shlibpath_var=LD_LIBRARY_PATH
7940   ;;
7941
7942 os2*)
7943   libname_spec='$name'
7944   need_lib_prefix=no
7945   library_names_spec='$libname.dll $libname.a'
7946   dynamic_linker='OS/2 ld.exe'
7947   shlibpath_var=LIBPATH
7948   ;;
7949
7950 osf3* | osf4* | osf5*)
7951   version_type=osf
7952   need_version=no
7953   soname_spec='${libname}${release}.so$major'
7954   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
7955   shlibpath_var=LD_LIBRARY_PATH
7956   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
7957   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
7958   hardcode_into_libs=yes
7959   ;;
7960
7961 sco3.2v5*)
7962   version_type=osf
7963   soname_spec='${libname}${release}.so$major'
7964   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
7965   shlibpath_var=LD_LIBRARY_PATH
7966   ;;
7967
7968 solaris*)
7969   version_type=linux
7970   need_lib_prefix=no
7971   need_version=no
7972   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
7973   soname_spec='${libname}${release}.so$major'
7974   shlibpath_var=LD_LIBRARY_PATH
7975   shlibpath_overrides_runpath=yes
7976   hardcode_into_libs=yes
7977   # ldd complains unless libraries are executable
7978   postinstall_cmds='chmod +x $lib'
7979   ;;
7980
7981 sunos4*)
7982   version_type=sunos
7983   library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
7984   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
7985   shlibpath_var=LD_LIBRARY_PATH
7986   shlibpath_overrides_runpath=yes
7987   if test "$with_gnu_ld" = yes; then
7988     need_lib_prefix=no
7989   fi
7990   need_version=yes
7991   ;;
7992
7993 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
7994   version_type=linux
7995   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
7996   soname_spec='${libname}${release}.so$major'
7997   shlibpath_var=LD_LIBRARY_PATH
7998   case $host_vendor in
7999     sni)
8000       shlibpath_overrides_runpath=no
8001       need_lib_prefix=no
8002       export_dynamic_flag_spec='${wl}-Blargedynsym'
8003       runpath_var=LD_RUN_PATH
8004       ;;
8005     siemens)
8006       need_lib_prefix=no
8007       ;;
8008     motorola)
8009       need_lib_prefix=no
8010       need_version=no
8011       shlibpath_overrides_runpath=no
8012       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
8013       ;;
8014   esac
8015   ;;
8016
8017 uts4*)
8018   version_type=linux
8019   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
8020   soname_spec='${libname}${release}.so$major'
8021   shlibpath_var=LD_LIBRARY_PATH
8022   ;;
8023
8024 dgux*)
8025   version_type=linux
8026   need_lib_prefix=no
8027   need_version=no
8028   library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
8029   soname_spec='${libname}${release}.so$major'
8030   shlibpath_var=LD_LIBRARY_PATH
8031   ;;
8032
8033 sysv4*MP*)
8034   if test -d /usr/nec ;then
8035     version_type=linux
8036     library_names_spec='$libname.so.$versuffix $libname.so.$major $libname.so'
8037     soname_spec='$libname.so.$major'
8038     shlibpath_var=LD_LIBRARY_PATH
8039   fi
8040   ;;
8041
8042 *)
8043   dynamic_linker=no
8044   ;;
8045 esac
8046 echo "$as_me:$LINENO: result: $dynamic_linker" >&5
8047 echo "${ECHO_T}$dynamic_linker" >&6
8048 test "$dynamic_linker" = no && can_build_shared=no
8049
8050 # Report the final consequences.
8051 echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
8052 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6
8053 echo "$as_me:$LINENO: result: $can_build_shared" >&5
8054 echo "${ECHO_T}$can_build_shared" >&6
8055
8056 echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
8057 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6
8058 test "$can_build_shared" = "no" && enable_shared=no
8059
8060 # On AIX, shared libraries and static libraries use the same namespace, and
8061 # are all built from PIC.
8062 case "$host_os" in
8063 aix3*)
8064   test "$enable_shared" = yes && enable_static=no
8065   if test -n "$RANLIB"; then
8066     archive_cmds="$archive_cmds~\$RANLIB \$lib"
8067     postinstall_cmds='$RANLIB $lib'
8068   fi
8069   ;;
8070
8071 aix4*)
8072   if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
8073     test "$enable_shared" = yes && enable_static=no
8074   fi
8075   ;;
8076 esac
8077 echo "$as_me:$LINENO: result: $enable_shared" >&5
8078 echo "${ECHO_T}$enable_shared" >&6
8079
8080 echo "$as_me:$LINENO: checking whether to build static libraries" >&5
8081 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6
8082 # Make sure either enable_shared or enable_static is yes.
8083 test "$enable_shared" = yes || enable_static=yes
8084 echo "$as_me:$LINENO: result: $enable_static" >&5
8085 echo "${ECHO_T}$enable_static" >&6
8086
8087 if test "$hardcode_action" = relink; then
8088   # Fast installation is not supported
8089   enable_fast_install=no
8090 elif test "$shlibpath_overrides_runpath" = yes ||
8091      test "$enable_shared" = no; then
8092   # Fast installation is not necessary
8093   enable_fast_install=needless
8094 fi
8095
8096 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
8097 if test "$GCC" = yes; then
8098   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
8099 fi
8100
8101 if test "x$enable_dlopen" != xyes; then
8102   enable_dlopen=unknown
8103   enable_dlopen_self=unknown
8104   enable_dlopen_self_static=unknown
8105 else
8106   lt_cv_dlopen=no
8107   lt_cv_dlopen_libs=
8108
8109   case $host_os in
8110   beos*)
8111     lt_cv_dlopen="load_add_on"
8112     lt_cv_dlopen_libs=
8113     lt_cv_dlopen_self=yes
8114     ;;
8115
8116   cygwin* | mingw* | pw32*)
8117     lt_cv_dlopen="LoadLibrary"
8118     lt_cv_dlopen_libs=
8119    ;;
8120
8121   *)
8122     echo "$as_me:$LINENO: checking for shl_load" >&5
8123 echo $ECHO_N "checking for shl_load... $ECHO_C" >&6
8124 if test "${ac_cv_func_shl_load+set}" = set; then
8125   echo $ECHO_N "(cached) $ECHO_C" >&6
8126 else
8127   cat >conftest.$ac_ext <<_ACEOF
8128 #line $LINENO "configure"
8129 /* confdefs.h.  */
8130 _ACEOF
8131 cat confdefs.h >>conftest.$ac_ext
8132 cat >>conftest.$ac_ext <<_ACEOF
8133 /* end confdefs.h.  */
8134 /* System header to define __stub macros and hopefully few prototypes,
8135     which can conflict with char shl_load (); below.
8136     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8137     <limits.h> exists even on freestanding compilers.  */
8138 #ifdef __STDC__
8139 # include <limits.h>
8140 #else
8141 # include <assert.h>
8142 #endif
8143 /* Override any gcc2 internal prototype to avoid an error.  */
8144 #ifdef __cplusplus
8145 extern "C"
8146 {
8147 #endif
8148 /* We use char because int might match the return type of a gcc2
8149    builtin and then its argument prototype would still apply.  */
8150 char shl_load ();
8151 /* The GNU C library defines this for functions which it implements
8152     to always fail with ENOSYS.  Some functions are actually named
8153     something starting with __ and the normal name is an alias.  */
8154 #if defined (__stub_shl_load) || defined (__stub___shl_load)
8155 choke me
8156 #else
8157 char (*f) () = shl_load;
8158 #endif
8159 #ifdef __cplusplus
8160 }
8161 #endif
8162
8163 int
8164 main ()
8165 {
8166 return f != shl_load;
8167   ;
8168   return 0;
8169 }
8170 _ACEOF
8171 rm -f conftest.$ac_objext conftest$ac_exeext
8172 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8173   (eval $ac_link) 2>&5
8174   ac_status=$?
8175   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8176   (exit $ac_status); } &&
8177          { ac_try='test -s conftest$ac_exeext'
8178   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8179   (eval $ac_try) 2>&5
8180   ac_status=$?
8181   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8182   (exit $ac_status); }; }; then
8183   ac_cv_func_shl_load=yes
8184 else
8185   echo "$as_me: failed program was:" >&5
8186 sed 's/^/| /' conftest.$ac_ext >&5
8187
8188 ac_cv_func_shl_load=no
8189 fi
8190 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8191 fi
8192 echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5
8193 echo "${ECHO_T}$ac_cv_func_shl_load" >&6
8194 if test $ac_cv_func_shl_load = yes; then
8195   lt_cv_dlopen="shl_load"
8196 else
8197   echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
8198 echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6
8199 if test "${ac_cv_lib_dld_shl_load+set}" = set; then
8200   echo $ECHO_N "(cached) $ECHO_C" >&6
8201 else
8202   ac_check_lib_save_LIBS=$LIBS
8203 LIBS="-ldld  $LIBS"
8204 cat >conftest.$ac_ext <<_ACEOF
8205 #line $LINENO "configure"
8206 /* confdefs.h.  */
8207 _ACEOF
8208 cat confdefs.h >>conftest.$ac_ext
8209 cat >>conftest.$ac_ext <<_ACEOF
8210 /* end confdefs.h.  */
8211
8212 /* Override any gcc2 internal prototype to avoid an error.  */
8213 #ifdef __cplusplus
8214 extern "C"
8215 #endif
8216 /* We use char because int might match the return type of a gcc2
8217    builtin and then its argument prototype would still apply.  */
8218 char shl_load ();
8219 int
8220 main ()
8221 {
8222 shl_load ();
8223   ;
8224   return 0;
8225 }
8226 _ACEOF
8227 rm -f conftest.$ac_objext conftest$ac_exeext
8228 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8229   (eval $ac_link) 2>&5
8230   ac_status=$?
8231   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8232   (exit $ac_status); } &&
8233          { ac_try='test -s conftest$ac_exeext'
8234   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8235   (eval $ac_try) 2>&5
8236   ac_status=$?
8237   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8238   (exit $ac_status); }; }; then
8239   ac_cv_lib_dld_shl_load=yes
8240 else
8241   echo "$as_me: failed program was:" >&5
8242 sed 's/^/| /' conftest.$ac_ext >&5
8243
8244 ac_cv_lib_dld_shl_load=no
8245 fi
8246 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8247 LIBS=$ac_check_lib_save_LIBS
8248 fi
8249 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
8250 echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6
8251 if test $ac_cv_lib_dld_shl_load = yes; then
8252   lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"
8253 else
8254   echo "$as_me:$LINENO: checking for dlopen" >&5
8255 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6
8256 if test "${ac_cv_func_dlopen+set}" = set; then
8257   echo $ECHO_N "(cached) $ECHO_C" >&6
8258 else
8259   cat >conftest.$ac_ext <<_ACEOF
8260 #line $LINENO "configure"
8261 /* confdefs.h.  */
8262 _ACEOF
8263 cat confdefs.h >>conftest.$ac_ext
8264 cat >>conftest.$ac_ext <<_ACEOF
8265 /* end confdefs.h.  */
8266 /* System header to define __stub macros and hopefully few prototypes,
8267     which can conflict with char dlopen (); below.
8268     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8269     <limits.h> exists even on freestanding compilers.  */
8270 #ifdef __STDC__
8271 # include <limits.h>
8272 #else
8273 # include <assert.h>
8274 #endif
8275 /* Override any gcc2 internal prototype to avoid an error.  */
8276 #ifdef __cplusplus
8277 extern "C"
8278 {
8279 #endif
8280 /* We use char because int might match the return type of a gcc2
8281    builtin and then its argument prototype would still apply.  */
8282 char dlopen ();
8283 /* The GNU C library defines this for functions which it implements
8284     to always fail with ENOSYS.  Some functions are actually named
8285     something starting with __ and the normal name is an alias.  */
8286 #if defined (__stub_dlopen) || defined (__stub___dlopen)
8287 choke me
8288 #else
8289 char (*f) () = dlopen;
8290 #endif
8291 #ifdef __cplusplus
8292 }
8293 #endif
8294
8295 int
8296 main ()
8297 {
8298 return f != dlopen;
8299   ;
8300   return 0;
8301 }
8302 _ACEOF
8303 rm -f conftest.$ac_objext conftest$ac_exeext
8304 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8305   (eval $ac_link) 2>&5
8306   ac_status=$?
8307   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8308   (exit $ac_status); } &&
8309          { ac_try='test -s conftest$ac_exeext'
8310   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8311   (eval $ac_try) 2>&5
8312   ac_status=$?
8313   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8314   (exit $ac_status); }; }; then
8315   ac_cv_func_dlopen=yes
8316 else
8317   echo "$as_me: failed program was:" >&5
8318 sed 's/^/| /' conftest.$ac_ext >&5
8319
8320 ac_cv_func_dlopen=no
8321 fi
8322 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8323 fi
8324 echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
8325 echo "${ECHO_T}$ac_cv_func_dlopen" >&6
8326 if test $ac_cv_func_dlopen = yes; then
8327   lt_cv_dlopen="dlopen"
8328 else
8329   echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
8330 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
8331 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
8332   echo $ECHO_N "(cached) $ECHO_C" >&6
8333 else
8334   ac_check_lib_save_LIBS=$LIBS
8335 LIBS="-ldl  $LIBS"
8336 cat >conftest.$ac_ext <<_ACEOF
8337 #line $LINENO "configure"
8338 /* confdefs.h.  */
8339 _ACEOF
8340 cat confdefs.h >>conftest.$ac_ext
8341 cat >>conftest.$ac_ext <<_ACEOF
8342 /* end confdefs.h.  */
8343
8344 /* Override any gcc2 internal prototype to avoid an error.  */
8345 #ifdef __cplusplus
8346 extern "C"
8347 #endif
8348 /* We use char because int might match the return type of a gcc2
8349    builtin and then its argument prototype would still apply.  */
8350 char dlopen ();
8351 int
8352 main ()
8353 {
8354 dlopen ();
8355   ;
8356   return 0;
8357 }
8358 _ACEOF
8359 rm -f conftest.$ac_objext conftest$ac_exeext
8360 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8361   (eval $ac_link) 2>&5
8362   ac_status=$?
8363   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8364   (exit $ac_status); } &&
8365          { ac_try='test -s conftest$ac_exeext'
8366   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8367   (eval $ac_try) 2>&5
8368   ac_status=$?
8369   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8370   (exit $ac_status); }; }; then
8371   ac_cv_lib_dl_dlopen=yes
8372 else
8373   echo "$as_me: failed program was:" >&5
8374 sed 's/^/| /' conftest.$ac_ext >&5
8375
8376 ac_cv_lib_dl_dlopen=no
8377 fi
8378 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8379 LIBS=$ac_check_lib_save_LIBS
8380 fi
8381 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
8382 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
8383 if test $ac_cv_lib_dl_dlopen = yes; then
8384   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
8385 else
8386   echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5
8387 echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6
8388 if test "${ac_cv_lib_svld_dlopen+set}" = set; then
8389   echo $ECHO_N "(cached) $ECHO_C" >&6
8390 else
8391   ac_check_lib_save_LIBS=$LIBS
8392 LIBS="-lsvld  $LIBS"
8393 cat >conftest.$ac_ext <<_ACEOF
8394 #line $LINENO "configure"
8395 /* confdefs.h.  */
8396 _ACEOF
8397 cat confdefs.h >>conftest.$ac_ext
8398 cat >>conftest.$ac_ext <<_ACEOF
8399 /* end confdefs.h.  */
8400
8401 /* Override any gcc2 internal prototype to avoid an error.  */
8402 #ifdef __cplusplus
8403 extern "C"
8404 #endif
8405 /* We use char because int might match the return type of a gcc2
8406    builtin and then its argument prototype would still apply.  */
8407 char dlopen ();
8408 int
8409 main ()
8410 {
8411 dlopen ();
8412   ;
8413   return 0;
8414 }
8415 _ACEOF
8416 rm -f conftest.$ac_objext conftest$ac_exeext
8417 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8418   (eval $ac_link) 2>&5
8419   ac_status=$?
8420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8421   (exit $ac_status); } &&
8422          { ac_try='test -s conftest$ac_exeext'
8423   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8424   (eval $ac_try) 2>&5
8425   ac_status=$?
8426   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8427   (exit $ac_status); }; }; then
8428   ac_cv_lib_svld_dlopen=yes
8429 else
8430   echo "$as_me: failed program was:" >&5
8431 sed 's/^/| /' conftest.$ac_ext >&5
8432
8433 ac_cv_lib_svld_dlopen=no
8434 fi
8435 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8436 LIBS=$ac_check_lib_save_LIBS
8437 fi
8438 echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5
8439 echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6
8440 if test $ac_cv_lib_svld_dlopen = yes; then
8441   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
8442 else
8443   echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5
8444 echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6
8445 if test "${ac_cv_lib_dld_dld_link+set}" = set; then
8446   echo $ECHO_N "(cached) $ECHO_C" >&6
8447 else
8448   ac_check_lib_save_LIBS=$LIBS
8449 LIBS="-ldld  $LIBS"
8450 cat >conftest.$ac_ext <<_ACEOF
8451 #line $LINENO "configure"
8452 /* confdefs.h.  */
8453 _ACEOF
8454 cat confdefs.h >>conftest.$ac_ext
8455 cat >>conftest.$ac_ext <<_ACEOF
8456 /* end confdefs.h.  */
8457
8458 /* Override any gcc2 internal prototype to avoid an error.  */
8459 #ifdef __cplusplus
8460 extern "C"
8461 #endif
8462 /* We use char because int might match the return type of a gcc2
8463    builtin and then its argument prototype would still apply.  */
8464 char dld_link ();
8465 int
8466 main ()
8467 {
8468 dld_link ();
8469   ;
8470   return 0;
8471 }
8472 _ACEOF
8473 rm -f conftest.$ac_objext conftest$ac_exeext
8474 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8475   (eval $ac_link) 2>&5
8476   ac_status=$?
8477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8478   (exit $ac_status); } &&
8479          { ac_try='test -s conftest$ac_exeext'
8480   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8481   (eval $ac_try) 2>&5
8482   ac_status=$?
8483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8484   (exit $ac_status); }; }; then
8485   ac_cv_lib_dld_dld_link=yes
8486 else
8487   echo "$as_me: failed program was:" >&5
8488 sed 's/^/| /' conftest.$ac_ext >&5
8489
8490 ac_cv_lib_dld_dld_link=no
8491 fi
8492 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8493 LIBS=$ac_check_lib_save_LIBS
8494 fi
8495 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5
8496 echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6
8497 if test $ac_cv_lib_dld_dld_link = yes; then
8498   lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"
8499 fi
8500
8501
8502 fi
8503
8504
8505 fi
8506
8507
8508 fi
8509
8510
8511 fi
8512
8513
8514 fi
8515
8516     ;;
8517   esac
8518
8519   if test "x$lt_cv_dlopen" != xno; then
8520     enable_dlopen=yes
8521   else
8522     enable_dlopen=no
8523   fi
8524
8525   case $lt_cv_dlopen in
8526   dlopen)
8527     save_CPPFLAGS="$CPPFLAGS"
8528         test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
8529
8530     save_LDFLAGS="$LDFLAGS"
8531     eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
8532
8533     save_LIBS="$LIBS"
8534     LIBS="$lt_cv_dlopen_libs $LIBS"
8535
8536     echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5
8537 echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6
8538 if test "${lt_cv_dlopen_self+set}" = set; then
8539   echo $ECHO_N "(cached) $ECHO_C" >&6
8540 else
8541           if test "$cross_compiling" = yes; then :
8542   lt_cv_dlopen_self=cross
8543 else
8544     lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
8545   lt_status=$lt_dlunknown
8546   cat > conftest.$ac_ext <<EOF
8547 #line 8547 "configure"
8548 #include "confdefs.h"
8549
8550 #if HAVE_DLFCN_H
8551 #include <dlfcn.h>
8552 #endif
8553
8554 #include <stdio.h>
8555
8556 #ifdef RTLD_GLOBAL
8557 #  define LT_DLGLOBAL           RTLD_GLOBAL
8558 #else
8559 #  ifdef DL_GLOBAL
8560 #    define LT_DLGLOBAL         DL_GLOBAL
8561 #  else
8562 #    define LT_DLGLOBAL         0
8563 #  endif
8564 #endif
8565
8566 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
8567    find out it does not work in some platform. */
8568 #ifndef LT_DLLAZY_OR_NOW
8569 #  ifdef RTLD_LAZY
8570 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
8571 #  else
8572 #    ifdef DL_LAZY
8573 #      define LT_DLLAZY_OR_NOW          DL_LAZY
8574 #    else
8575 #      ifdef RTLD_NOW
8576 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
8577 #      else
8578 #        ifdef DL_NOW
8579 #          define LT_DLLAZY_OR_NOW      DL_NOW
8580 #        else
8581 #          define LT_DLLAZY_OR_NOW      0
8582 #        endif
8583 #      endif
8584 #    endif
8585 #  endif
8586 #endif
8587
8588 #ifdef __cplusplus
8589 extern "C" void exit (int);
8590 #endif
8591
8592 void fnord() { int i=42;}
8593 int main ()
8594 {
8595   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
8596   int status = $lt_dlunknown;
8597
8598   if (self)
8599     {
8600       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
8601       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
8602       /* dlclose (self); */
8603     }
8604
8605     exit (status);
8606 }
8607 EOF
8608   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8609   (eval $ac_link) 2>&5
8610   ac_status=$?
8611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8612   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
8613     (./conftest; exit; ) 2>/dev/null
8614     lt_status=$?
8615     case x$lt_status in
8616       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
8617       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
8618       x$lt_unknown|x*) lt_cv_dlopen_self=no ;;
8619     esac
8620   else :
8621     # compilation failed
8622     lt_cv_dlopen_self=no
8623   fi
8624 fi
8625 rm -fr conftest*
8626
8627
8628 fi
8629 echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5
8630 echo "${ECHO_T}$lt_cv_dlopen_self" >&6
8631
8632     if test "x$lt_cv_dlopen_self" = xyes; then
8633       LDFLAGS="$LDFLAGS $link_static_flag"
8634       echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5
8635 echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6
8636 if test "${lt_cv_dlopen_self_static+set}" = set; then
8637   echo $ECHO_N "(cached) $ECHO_C" >&6
8638 else
8639           if test "$cross_compiling" = yes; then :
8640   lt_cv_dlopen_self_static=cross
8641 else
8642     lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
8643   lt_status=$lt_dlunknown
8644   cat > conftest.$ac_ext <<EOF
8645 #line 8645 "configure"
8646 #include "confdefs.h"
8647
8648 #if HAVE_DLFCN_H
8649 #include <dlfcn.h>
8650 #endif
8651
8652 #include <stdio.h>
8653
8654 #ifdef RTLD_GLOBAL
8655 #  define LT_DLGLOBAL           RTLD_GLOBAL
8656 #else
8657 #  ifdef DL_GLOBAL
8658 #    define LT_DLGLOBAL         DL_GLOBAL
8659 #  else
8660 #    define LT_DLGLOBAL         0
8661 #  endif
8662 #endif
8663
8664 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
8665    find out it does not work in some platform. */
8666 #ifndef LT_DLLAZY_OR_NOW
8667 #  ifdef RTLD_LAZY
8668 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
8669 #  else
8670 #    ifdef DL_LAZY
8671 #      define LT_DLLAZY_OR_NOW          DL_LAZY
8672 #    else
8673 #      ifdef RTLD_NOW
8674 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
8675 #      else
8676 #        ifdef DL_NOW
8677 #          define LT_DLLAZY_OR_NOW      DL_NOW
8678 #        else
8679 #          define LT_DLLAZY_OR_NOW      0
8680 #        endif
8681 #      endif
8682 #    endif
8683 #  endif
8684 #endif
8685
8686 #ifdef __cplusplus
8687 extern "C" void exit (int);
8688 #endif
8689
8690 void fnord() { int i=42;}
8691 int main ()
8692 {
8693   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
8694   int status = $lt_dlunknown;
8695
8696   if (self)
8697     {
8698       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
8699       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
8700       /* dlclose (self); */
8701     }
8702
8703     exit (status);
8704 }
8705 EOF
8706   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8707   (eval $ac_link) 2>&5
8708   ac_status=$?
8709   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8710   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
8711     (./conftest; exit; ) 2>/dev/null
8712     lt_status=$?
8713     case x$lt_status in
8714       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
8715       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
8716       x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;;
8717     esac
8718   else :
8719     # compilation failed
8720     lt_cv_dlopen_self_static=no
8721   fi
8722 fi
8723 rm -fr conftest*
8724
8725
8726 fi
8727 echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5
8728 echo "${ECHO_T}$lt_cv_dlopen_self_static" >&6
8729     fi
8730
8731     CPPFLAGS="$save_CPPFLAGS"
8732     LDFLAGS="$save_LDFLAGS"
8733     LIBS="$save_LIBS"
8734     ;;
8735   esac
8736
8737   case $lt_cv_dlopen_self in
8738   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
8739   *) enable_dlopen_self=unknown ;;
8740   esac
8741
8742   case $lt_cv_dlopen_self_static in
8743   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
8744   *) enable_dlopen_self_static=unknown ;;
8745   esac
8746 fi
8747
8748
8749 if test "$enable_shared" = yes && test "$GCC" = yes; then
8750   case $archive_cmds in
8751   *'~'*)
8752     # FIXME: we may have to deal with multi-command sequences.
8753     ;;
8754   '$CC '*)
8755     # Test whether the compiler implicitly links with -lc since on some
8756     # systems, -lgcc has to come before -lc. If gcc already passes -lc
8757     # to ld, don't add -lc before -lgcc.
8758     echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
8759 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6
8760     if test "${lt_cv_archive_cmds_need_lc+set}" = set; then
8761   echo $ECHO_N "(cached) $ECHO_C" >&6
8762 else
8763   $rm conftest*
8764     echo 'static int dummy;' > conftest.$ac_ext
8765
8766     if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8767   (eval $ac_compile) 2>&5
8768   ac_status=$?
8769   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8770   (exit $ac_status); }; then
8771       soname=conftest
8772       lib=conftest
8773       libobjs=conftest.$ac_objext
8774       deplibs=
8775       wl=$lt_cv_prog_cc_wl
8776       compiler_flags=-v
8777       linker_flags=-v
8778       verstring=
8779       output_objdir=.
8780       libname=conftest
8781       save_allow_undefined_flag=$allow_undefined_flag
8782       allow_undefined_flag=
8783       if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5
8784   (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5
8785   ac_status=$?
8786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8787   (exit $ac_status); }
8788       then
8789         lt_cv_archive_cmds_need_lc=no
8790       else
8791         lt_cv_archive_cmds_need_lc=yes
8792       fi
8793       allow_undefined_flag=$save_allow_undefined_flag
8794     else
8795       cat conftest.err 1>&5
8796     fi
8797 fi
8798
8799     echo "$as_me:$LINENO: result: $lt_cv_archive_cmds_need_lc" >&5
8800 echo "${ECHO_T}$lt_cv_archive_cmds_need_lc" >&6
8801     ;;
8802   esac
8803 fi
8804 need_lc=${lt_cv_archive_cmds_need_lc-yes}
8805
8806 # The second clause should only fire when bootstrapping the
8807 # libtool distribution, otherwise you forgot to ship ltmain.sh
8808 # with your package, and you will get complaints that there are
8809 # no rules to generate ltmain.sh.
8810 if test -f "$ltmain"; then
8811   :
8812 else
8813   # If there is no Makefile yet, we rely on a make rule to execute
8814   # `config.status --recheck' to rerun these tests and create the
8815   # libtool script then.
8816   test -f Makefile && make "$ltmain"
8817 fi
8818
8819 if test -f "$ltmain"; then
8820   trap "$rm \"${ofile}T\"; exit 1" 1 2 15
8821   $rm -f "${ofile}T"
8822
8823   echo creating $ofile
8824
8825   # Now quote all the things that may contain metacharacters while being
8826   # careful not to overquote the AC_SUBSTed values.  We take copies of the
8827   # variables and quote the copies for generation of the libtool script.
8828   for var in echo old_CC old_CFLAGS SED \
8829     AR AR_FLAGS CC LD LN_S NM SHELL \
8830     reload_flag reload_cmds wl \
8831     pic_flag link_static_flag no_builtin_flag export_dynamic_flag_spec \
8832     thread_safe_flag_spec whole_archive_flag_spec libname_spec \
8833     library_names_spec soname_spec \
8834     RANLIB old_archive_cmds old_archive_from_new_cmds old_postinstall_cmds \
8835     old_postuninstall_cmds archive_cmds archive_expsym_cmds postinstall_cmds \
8836     postuninstall_cmds extract_expsyms_cmds old_archive_from_expsyms_cmds \
8837     old_striplib striplib file_magic_cmd export_symbols_cmds \
8838     deplibs_check_method allow_undefined_flag no_undefined_flag \
8839     finish_cmds finish_eval global_symbol_pipe global_symbol_to_cdecl \
8840     global_symbol_to_c_name_address \
8841     hardcode_libdir_flag_spec hardcode_libdir_separator  \
8842     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
8843     compiler_c_o compiler_o_lo need_locks exclude_expsyms include_expsyms; do
8844
8845     case $var in
8846     reload_cmds | old_archive_cmds | old_archive_from_new_cmds | \
8847     old_postinstall_cmds | old_postuninstall_cmds | \
8848     export_symbols_cmds | archive_cmds | archive_expsym_cmds | \
8849     extract_expsyms_cmds | old_archive_from_expsyms_cmds | \
8850     postinstall_cmds | postuninstall_cmds | \
8851     finish_cmds | sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
8852       # Double-quote double-evaled strings.
8853       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
8854       ;;
8855     *)
8856       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
8857       ;;
8858     esac
8859   done
8860
8861   cat <<__EOF__ > "${ofile}T"
8862 #! $SHELL
8863
8864 # `$echo "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
8865 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
8866 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
8867 #
8868 # Copyright (C) 1996-2000 Free Software Foundation, Inc.
8869 # Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
8870 #
8871 # This program is free software; you can redistribute it and/or modify
8872 # it under the terms of the GNU General Public License as published by
8873 # the Free Software Foundation; either version 2 of the License, or
8874 # (at your option) any later version.
8875 #
8876 # This program is distributed in the hope that it will be useful, but
8877 # WITHOUT ANY WARRANTY; without even the implied warranty of
8878 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
8879 # General Public License for more details.
8880 #
8881 # You should have received a copy of the GNU General Public License
8882 # along with this program; if not, write to the Free Software
8883 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
8884 #
8885 # As a special exception to the GNU General Public License, if you
8886 # distribute this file as part of a program that contains a
8887 # configuration script generated by Autoconf, you may include it under
8888 # the same distribution terms that you use for the rest of that program.
8889
8890 # A sed that does not truncate output.
8891 SED=$lt_SED
8892
8893 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
8894 Xsed="${SED} -e s/^X//"
8895
8896 # The HP-UX ksh and POSIX shell print the target directory to stdout
8897 # if CDPATH is set.
8898 if test "X\${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
8899
8900 # ### BEGIN LIBTOOL CONFIG
8901
8902 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
8903
8904 # Shell to use when invoking shell scripts.
8905 SHELL=$lt_SHELL
8906
8907 # Whether or not to build shared libraries.
8908 build_libtool_libs=$enable_shared
8909
8910 # Whether or not to build static libraries.
8911 build_old_libs=$enable_static
8912
8913 # Whether or not to add -lc for building shared libraries.
8914 build_libtool_need_lc=$need_lc
8915
8916 # Whether or not to optimize for fast installation.
8917 fast_install=$enable_fast_install
8918
8919 # The host system.
8920 host_alias=$host_alias
8921 host=$host
8922
8923 # An echo program that does not interpret backslashes.
8924 echo=$lt_echo
8925
8926 # The archiver.
8927 AR=$lt_AR
8928 AR_FLAGS=$lt_AR_FLAGS
8929
8930 # The default C compiler.
8931 CC=$lt_CC
8932
8933 # Is the compiler the GNU C compiler?
8934 with_gcc=$GCC
8935
8936 # The linker used to build libraries.
8937 LD=$lt_LD
8938
8939 # Whether we need hard or soft links.
8940 LN_S=$lt_LN_S
8941
8942 # A BSD-compatible nm program.
8943 NM=$lt_NM
8944
8945 # A symbol stripping program
8946 STRIP=$STRIP
8947
8948 # Used to examine libraries when file_magic_cmd begins "file"
8949 MAGIC_CMD=$MAGIC_CMD
8950
8951 # Used on cygwin: DLL creation program.
8952 DLLTOOL="$DLLTOOL"
8953
8954 # Used on cygwin: object dumper.
8955 OBJDUMP="$OBJDUMP"
8956
8957 # Used on cygwin: assembler.
8958 AS="$AS"
8959
8960 # The name of the directory that contains temporary libtool files.
8961 objdir=$objdir
8962
8963 # How to create reloadable object files.
8964 reload_flag=$lt_reload_flag
8965 reload_cmds=$lt_reload_cmds
8966
8967 # How to pass a linker flag through the compiler.
8968 wl=$lt_wl
8969
8970 # Object file suffix (normally "o").
8971 objext="$ac_objext"
8972
8973 # Old archive suffix (normally "a").
8974 libext="$libext"
8975
8976 # Executable file suffix (normally "").
8977 exeext="$exeext"
8978
8979 # Additional compiler flags for building library objects.
8980 pic_flag=$lt_pic_flag
8981 pic_mode=$pic_mode
8982
8983 # Does compiler simultaneously support -c and -o options?
8984 compiler_c_o=$lt_compiler_c_o
8985
8986 # Can we write directly to a .lo ?
8987 compiler_o_lo=$lt_compiler_o_lo
8988
8989 # Must we lock files when doing compilation ?
8990 need_locks=$lt_need_locks
8991
8992 # Do we need the lib prefix for modules?
8993 need_lib_prefix=$need_lib_prefix
8994
8995 # Do we need a version for libraries?
8996 need_version=$need_version
8997
8998 # Whether dlopen is supported.
8999 dlopen_support=$enable_dlopen
9000
9001 # Whether dlopen of programs is supported.
9002 dlopen_self=$enable_dlopen_self
9003
9004 # Whether dlopen of statically linked programs is supported.
9005 dlopen_self_static=$enable_dlopen_self_static
9006
9007 # Compiler flag to prevent dynamic linking.
9008 link_static_flag=$lt_link_static_flag
9009
9010 # Compiler flag to turn off builtin functions.
9011 no_builtin_flag=$lt_no_builtin_flag
9012
9013 # Compiler flag to allow reflexive dlopens.
9014 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
9015
9016 # Compiler flag to generate shared objects directly from archives.
9017 whole_archive_flag_spec=$lt_whole_archive_flag_spec
9018
9019 # Compiler flag to generate thread-safe objects.
9020 thread_safe_flag_spec=$lt_thread_safe_flag_spec
9021
9022 # Library versioning type.
9023 version_type=$version_type
9024
9025 # Format of library name prefix.
9026 libname_spec=$lt_libname_spec
9027
9028 # List of archive names.  First name is the real one, the rest are links.
9029 # The last name is the one that the linker finds with -lNAME.
9030 library_names_spec=$lt_library_names_spec
9031
9032 # The coded name of the library, if different from the real name.
9033 soname_spec=$lt_soname_spec
9034
9035 # Commands used to build and install an old-style archive.
9036 RANLIB=$lt_RANLIB
9037 old_archive_cmds=$lt_old_archive_cmds
9038 old_postinstall_cmds=$lt_old_postinstall_cmds
9039 old_postuninstall_cmds=$lt_old_postuninstall_cmds
9040
9041 # Create an old-style archive from a shared archive.
9042 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
9043
9044 # Create a temporary old-style archive to link instead of a shared archive.
9045 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
9046
9047 # Commands used to build and install a shared archive.
9048 archive_cmds=$lt_archive_cmds
9049 archive_expsym_cmds=$lt_archive_expsym_cmds
9050 postinstall_cmds=$lt_postinstall_cmds
9051 postuninstall_cmds=$lt_postuninstall_cmds
9052
9053 # Commands to strip libraries.
9054 old_striplib=$lt_old_striplib
9055 striplib=$lt_striplib
9056
9057 # Method to check whether dependent libraries are shared objects.
9058 deplibs_check_method=$lt_deplibs_check_method
9059
9060 # Command to use when deplibs_check_method == file_magic.
9061 file_magic_cmd=$lt_file_magic_cmd
9062
9063 # Flag that allows shared libraries with undefined symbols to be built.
9064 allow_undefined_flag=$lt_allow_undefined_flag
9065
9066 # Flag that forces no undefined symbols.
9067 no_undefined_flag=$lt_no_undefined_flag
9068
9069 # Commands used to finish a libtool library installation in a directory.
9070 finish_cmds=$lt_finish_cmds
9071
9072 # Same as above, but a single script fragment to be evaled but not shown.
9073 finish_eval=$lt_finish_eval
9074
9075 # Take the output of nm and produce a listing of raw symbols and C names.
9076 global_symbol_pipe=$lt_global_symbol_pipe
9077
9078 # Transform the output of nm in a proper C declaration
9079 global_symbol_to_cdecl=$lt_global_symbol_to_cdecl
9080
9081 # Transform the output of nm in a C name address pair
9082 global_symbol_to_c_name_address=$lt_global_symbol_to_c_name_address
9083
9084 # This is the shared library runtime path variable.
9085 runpath_var=$runpath_var
9086
9087 # This is the shared library path variable.
9088 shlibpath_var=$shlibpath_var
9089
9090 # Is shlibpath searched before the hard-coded library search path?
9091 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
9092
9093 # How to hardcode a shared library path into an executable.
9094 hardcode_action=$hardcode_action
9095
9096 # Whether we should hardcode library paths into libraries.
9097 hardcode_into_libs=$hardcode_into_libs
9098
9099 # Flag to hardcode \$libdir into a binary during linking.
9100 # This must work even if \$libdir does not exist.
9101 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
9102
9103 # Whether we need a single -rpath flag with a separated argument.
9104 hardcode_libdir_separator=$lt_hardcode_libdir_separator
9105
9106 # Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the
9107 # resulting binary.
9108 hardcode_direct=$hardcode_direct
9109
9110 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
9111 # resulting binary.
9112 hardcode_minus_L=$hardcode_minus_L
9113
9114 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
9115 # the resulting binary.
9116 hardcode_shlibpath_var=$hardcode_shlibpath_var
9117
9118 # Variables whose values should be saved in libtool wrapper scripts and
9119 # restored at relink time.
9120 variables_saved_for_relink="$variables_saved_for_relink"
9121
9122 # Whether libtool must link a program against all its dependency libraries.
9123 link_all_deplibs=$link_all_deplibs
9124
9125 # Compile-time system search path for libraries
9126 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
9127
9128 # Run-time system search path for libraries
9129 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
9130
9131 # Fix the shell variable \$srcfile for the compiler.
9132 fix_srcfile_path="$fix_srcfile_path"
9133
9134 # Set to yes if exported symbols are required.
9135 always_export_symbols=$always_export_symbols
9136
9137 # The commands to list exported symbols.
9138 export_symbols_cmds=$lt_export_symbols_cmds
9139
9140 # The commands to extract the exported symbol list from a shared archive.
9141 extract_expsyms_cmds=$lt_extract_expsyms_cmds
9142
9143 # Symbols that should not be listed in the preloaded symbols.
9144 exclude_expsyms=$lt_exclude_expsyms
9145
9146 # Symbols that must always be exported.
9147 include_expsyms=$lt_include_expsyms
9148
9149 # ### END LIBTOOL CONFIG
9150
9151 __EOF__
9152
9153   case $host_os in
9154   aix3*)
9155     cat <<\EOF >> "${ofile}T"
9156
9157 # AIX sometimes has problems with the GCC collect2 program.  For some
9158 # reason, if we set the COLLECT_NAMES environment variable, the problems
9159 # vanish in a puff of smoke.
9160 if test "X${COLLECT_NAMES+set}" != Xset; then
9161   COLLECT_NAMES=
9162   export COLLECT_NAMES
9163 fi
9164 EOF
9165     ;;
9166   esac
9167
9168   case $host_os in
9169   cygwin* | mingw* | pw32* | os2*)
9170     cat <<'EOF' >> "${ofile}T"
9171       # This is a source program that is used to create dlls on Windows
9172       # Don't remove nor modify the starting and closing comments
9173 # /* ltdll.c starts here */
9174 # #define WIN32_LEAN_AND_MEAN
9175 # #include <windows.h>
9176 # #undef WIN32_LEAN_AND_MEAN
9177 # #include <stdio.h>
9178 #
9179 # #ifndef __CYGWIN__
9180 # #  ifdef __CYGWIN32__
9181 # #    define __CYGWIN__ __CYGWIN32__
9182 # #  endif
9183 # #endif
9184 #
9185 # #ifdef __cplusplus
9186 # extern "C" {
9187 # #endif
9188 # BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
9189 # #ifdef __cplusplus
9190 # }
9191 # #endif
9192 #
9193 # #ifdef __CYGWIN__
9194 # #include <cygwin/cygwin_dll.h>
9195 # DECLARE_CYGWIN_DLL( DllMain );
9196 # #endif
9197 # HINSTANCE __hDllInstance_base;
9198 #
9199 # BOOL APIENTRY
9200 # DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
9201 # {
9202 #   __hDllInstance_base = hInst;
9203 #   return TRUE;
9204 # }
9205 # /* ltdll.c ends here */
9206         # This is a source program that is used to create import libraries
9207         # on Windows for dlls which lack them. Don't remove nor modify the
9208         # starting and closing comments
9209 # /* impgen.c starts here */
9210 # /*   Copyright (C) 1999-2000 Free Software Foundation, Inc.
9211 #
9212 #  This file is part of GNU libtool.
9213 #
9214 #  This program is free software; you can redistribute it and/or modify
9215 #  it under the terms of the GNU General Public License as published by
9216 #  the Free Software Foundation; either version 2 of the License, or
9217 #  (at your option) any later version.
9218 #
9219 #  This program is distributed in the hope that it will be useful,
9220 #  but WITHOUT ANY WARRANTY; without even the implied warranty of
9221 #  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
9222 #  GNU General Public License for more details.
9223 #
9224 #  You should have received a copy of the GNU General Public License
9225 #  along with this program; if not, write to the Free Software
9226 #  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
9227 #  */
9228 #
9229 # #include <stdio.h>            /* for printf() */
9230 # #include <unistd.h>           /* for open(), lseek(), read() */
9231 # #include <fcntl.h>            /* for O_RDONLY, O_BINARY */
9232 # #include <string.h>           /* for strdup() */
9233 #
9234 # /* O_BINARY isn't required (or even defined sometimes) under Unix */
9235 # #ifndef O_BINARY
9236 # #define O_BINARY 0
9237 # #endif
9238 #
9239 # static unsigned int
9240 # pe_get16 (fd, offset)
9241 #      int fd;
9242 #      int offset;
9243 # {
9244 #   unsigned char b[2];
9245 #   lseek (fd, offset, SEEK_SET);
9246 #   read (fd, b, 2);
9247 #   return b[0] + (b[1]<<8);
9248 # }
9249 #
9250 # static unsigned int
9251 # pe_get32 (fd, offset)
9252 #     int fd;
9253 #     int offset;
9254 # {
9255 #   unsigned char b[4];
9256 #   lseek (fd, offset, SEEK_SET);
9257 #   read (fd, b, 4);
9258 #   return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
9259 # }
9260 #
9261 # static unsigned int
9262 # pe_as32 (ptr)
9263 #      void *ptr;
9264 # {
9265 #   unsigned char *b = ptr;
9266 #   return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
9267 # }
9268 #
9269 # int
9270 # main (argc, argv)
9271 #     int argc;
9272 #     char *argv[];
9273 # {
9274 #     int dll;
9275 #     unsigned long pe_header_offset, opthdr_ofs, num_entries, i;
9276 #     unsigned long export_rva, export_size, nsections, secptr, expptr;
9277 #     unsigned long name_rvas, nexp;
9278 #     unsigned char *expdata, *erva;
9279 #     char *filename, *dll_name;
9280 #
9281 #     filename = argv[1];
9282 #
9283 #     dll = open(filename, O_RDONLY|O_BINARY);
9284 #     if (dll < 1)
9285 #       return 1;
9286 #
9287 #     dll_name = filename;
9288 #
9289 #     for (i=0; filename[i]; i++)
9290 #       if (filename[i] == '/' || filename[i] == '\\'  || filename[i] == ':')
9291 #           dll_name = filename + i +1;
9292 #
9293 #     pe_header_offset = pe_get32 (dll, 0x3c);
9294 #     opthdr_ofs = pe_header_offset + 4 + 20;
9295 #     num_entries = pe_get32 (dll, opthdr_ofs + 92);
9296 #
9297 #     if (num_entries < 1) /* no exports */
9298 #       return 1;
9299 #
9300 #     export_rva = pe_get32 (dll, opthdr_ofs + 96);
9301 #     export_size = pe_get32 (dll, opthdr_ofs + 100);
9302 #     nsections = pe_get16 (dll, pe_header_offset + 4 +2);
9303 #     secptr = (pe_header_offset + 4 + 20 +
9304 #             pe_get16 (dll, pe_header_offset + 4 + 16));
9305 #
9306 #     expptr = 0;
9307 #     for (i = 0; i < nsections; i++)
9308 #     {
9309 #       char sname[8];
9310 #       unsigned long secptr1 = secptr + 40 * i;
9311 #       unsigned long vaddr = pe_get32 (dll, secptr1 + 12);
9312 #       unsigned long vsize = pe_get32 (dll, secptr1 + 16);
9313 #       unsigned long fptr = pe_get32 (dll, secptr1 + 20);
9314 #       lseek(dll, secptr1, SEEK_SET);
9315 #       read(dll, sname, 8);
9316 #       if (vaddr <= export_rva && vaddr+vsize > export_rva)
9317 #       {
9318 #           expptr = fptr + (export_rva - vaddr);
9319 #           if (export_rva + export_size > vaddr + vsize)
9320 #               export_size = vsize - (export_rva - vaddr);
9321 #           break;
9322 #       }
9323 #     }
9324 #
9325 #     expdata = (unsigned char*)malloc(export_size);
9326 #     lseek (dll, expptr, SEEK_SET);
9327 #     read (dll, expdata, export_size);
9328 #     erva = expdata - export_rva;
9329 #
9330 #     nexp = pe_as32 (expdata+24);
9331 #     name_rvas = pe_as32 (expdata+32);
9332 #
9333 #     printf ("EXPORTS\n");
9334 #     for (i = 0; i<nexp; i++)
9335 #     {
9336 #       unsigned long name_rva = pe_as32 (erva+name_rvas+i*4);
9337 #       printf ("\t%s @ %ld ;\n", erva+name_rva, 1+ i);
9338 #     }
9339 #
9340 #     return 0;
9341 # }
9342 # /* impgen.c ends here */
9343
9344 EOF
9345     ;;
9346   esac
9347
9348   # We use sed instead of cat because bash on DJGPP gets confused if
9349   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
9350   # text mode, it properly converts lines to CR/LF.  This bash problem
9351   # is reportedly fixed, but why not run on old versions too?
9352   sed '$q' "$ltmain" >> "${ofile}T" || (rm -f "${ofile}T"; exit 1)
9353
9354   mv -f "${ofile}T" "$ofile" || \
9355     (rm -f "$ofile" && cp "${ofile}T" "$ofile" && rm -f "${ofile}T")
9356   chmod +x "$ofile"
9357 fi
9358
9359
9360
9361
9362
9363 # This can be used to rebuild libtool when needed
9364 LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
9365
9366 # Always use our own libtool.
9367 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
9368
9369 # Prevent multiple expansion
9370
9371
9372
9373 # test for ln hardlink support
9374 echo "$as_me:$LINENO: checking whether ln works" >&5
9375 echo $ECHO_N "checking whether ln works... $ECHO_C" >&6
9376 if test "${ol_cv_prog_LN_H+set}" = set; then
9377   echo $ECHO_N "(cached) $ECHO_C" >&6
9378 else
9379   rm -f conftest.src conftest.dst
9380 echo "conftest" > conftest.src
9381 if ln conftest.src conftest.dst 2>/dev/null
9382 then
9383   ol_cv_prog_LN_H="ln"
9384 else
9385   ol_cv_prog_LN_H="cp"
9386 fi
9387 rm -f conftest.src conftest.dst
9388
9389 fi
9390 LN_H="$ol_cv_prog_LN_H"
9391 if test "$ol_cv_prog_LN_H" = "ln"; then
9392         echo "$as_me:$LINENO: result: yes" >&5
9393 echo "${ECHO_T}yes" >&6
9394 else
9395         echo "$as_me:$LINENO: result: no" >&5
9396 echo "${ECHO_T}no" >&6
9397 fi
9398
9399 echo "$as_me:$LINENO: checking whether ln -s works" >&5
9400 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
9401 LN_S=$as_ln_s
9402 if test "$LN_S" = "ln -s"; then
9403   echo "$as_me:$LINENO: result: yes" >&5
9404 echo "${ECHO_T}yes" >&6
9405 else
9406   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
9407 echo "${ECHO_T}no, using $LN_S" >&6
9408 fi
9409
9410
9411 ol_link_perl=no
9412 if test $ol_enable_perl != no ; then
9413         # Extract the first word of "perl", so it can be a program name with args.
9414 set dummy perl; ac_word=$2
9415 echo "$as_me:$LINENO: checking for $ac_word" >&5
9416 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9417 if test "${ac_cv_path_PERLBIN+set}" = set; then
9418   echo $ECHO_N "(cached) $ECHO_C" >&6
9419 else
9420   case $PERLBIN in
9421   [\\/]* | ?:[\\/]*)
9422   ac_cv_path_PERLBIN="$PERLBIN" # Let the user override the test with a path.
9423   ;;
9424   *)
9425   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9426 for as_dir in $PATH
9427 do
9428   IFS=$as_save_IFS
9429   test -z "$as_dir" && as_dir=.
9430   for ac_exec_ext in '' $ac_executable_extensions; do
9431   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9432     ac_cv_path_PERLBIN="$as_dir/$ac_word$ac_exec_ext"
9433     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
9434     break 2
9435   fi
9436 done
9437 done
9438
9439   test -z "$ac_cv_path_PERLBIN" && ac_cv_path_PERLBIN="/usr/bin/perl"
9440   ;;
9441 esac
9442 fi
9443 PERLBIN=$ac_cv_path_PERLBIN
9444
9445 if test -n "$PERLBIN"; then
9446   echo "$as_me:$LINENO: result: $PERLBIN" >&5
9447 echo "${ECHO_T}$PERLBIN" >&6
9448 else
9449   echo "$as_me:$LINENO: result: no" >&5
9450 echo "${ECHO_T}no" >&6
9451 fi
9452
9453
9454         if test "no$PERLBIN" = "no" ; then
9455                 if test $ol_enable_perl = yes ; then
9456                         { { echo "$as_me:$LINENO: error: could not locate perl" >&5
9457 echo "$as_me: error: could not locate perl" >&2;}
9458    { (exit 1); exit 1; }; }
9459                 fi
9460
9461         else
9462                 PERL_CPPFLAGS="`$PERLBIN -MExtUtils::Embed -e ccopts`"
9463                 if test x"$ol_with_perl_module" = "xstatic" ; then
9464                         SLAPD_PERL_LDFLAGS="`$PERLBIN -MExtUtils::Embed -e ldopts|sed -e s/-lc//`"
9465                 else
9466                         MOD_PERL_LDFLAGS="`$PERLBIN -MExtUtils::Embed -e ldopts|sed -e s/-lc//`"
9467                 fi
9468                                 ol_link_perl=yes
9469         fi
9470 fi
9471
9472 ac_ext=c
9473 ac_cpp='$CPP $CPPFLAGS'
9474 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9475 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9476 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9477 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
9478 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
9479 # On Suns, sometimes $CPP names a directory.
9480 if test -n "$CPP" && test -d "$CPP"; then
9481   CPP=
9482 fi
9483 if test -z "$CPP"; then
9484   if test "${ac_cv_prog_CPP+set}" = set; then
9485   echo $ECHO_N "(cached) $ECHO_C" >&6
9486 else
9487       # Double quotes because CPP needs to be expanded
9488     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
9489     do
9490       ac_preproc_ok=false
9491 for ac_c_preproc_warn_flag in '' yes
9492 do
9493   # Use a header file that comes with gcc, so configuring glibc
9494   # with a fresh cross-compiler works.
9495   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9496   # <limits.h> exists even on freestanding compilers.
9497   # On the NeXT, cc -E runs the code through the compiler's parser,
9498   # not just through cpp. "Syntax error" is here to catch this case.
9499   cat >conftest.$ac_ext <<_ACEOF
9500 #line $LINENO "configure"
9501 /* confdefs.h.  */
9502 _ACEOF
9503 cat confdefs.h >>conftest.$ac_ext
9504 cat >>conftest.$ac_ext <<_ACEOF
9505 /* end confdefs.h.  */
9506 #ifdef __STDC__
9507 # include <limits.h>
9508 #else
9509 # include <assert.h>
9510 #endif
9511                      Syntax error
9512 _ACEOF
9513 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9514   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9515   ac_status=$?
9516   grep -v '^ *+' conftest.er1 >conftest.err
9517   rm -f conftest.er1
9518   cat conftest.err >&5
9519   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9520   (exit $ac_status); } >/dev/null; then
9521   if test -s conftest.err; then
9522     ac_cpp_err=$ac_c_preproc_warn_flag
9523   else
9524     ac_cpp_err=
9525   fi
9526 else
9527   ac_cpp_err=yes
9528 fi
9529 if test -z "$ac_cpp_err"; then
9530   :
9531 else
9532   echo "$as_me: failed program was:" >&5
9533 sed 's/^/| /' conftest.$ac_ext >&5
9534
9535   # Broken: fails on valid input.
9536 continue
9537 fi
9538 rm -f conftest.err conftest.$ac_ext
9539
9540   # OK, works on sane cases.  Now check whether non-existent headers
9541   # can be detected and how.
9542   cat >conftest.$ac_ext <<_ACEOF
9543 #line $LINENO "configure"
9544 /* confdefs.h.  */
9545 _ACEOF
9546 cat confdefs.h >>conftest.$ac_ext
9547 cat >>conftest.$ac_ext <<_ACEOF
9548 /* end confdefs.h.  */
9549 #include <ac_nonexistent.h>
9550 _ACEOF
9551 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9552   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9553   ac_status=$?
9554   grep -v '^ *+' conftest.er1 >conftest.err
9555   rm -f conftest.er1
9556   cat conftest.err >&5
9557   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9558   (exit $ac_status); } >/dev/null; then
9559   if test -s conftest.err; then
9560     ac_cpp_err=$ac_c_preproc_warn_flag
9561   else
9562     ac_cpp_err=
9563   fi
9564 else
9565   ac_cpp_err=yes
9566 fi
9567 if test -z "$ac_cpp_err"; then
9568   # Broken: success on invalid input.
9569 continue
9570 else
9571   echo "$as_me: failed program was:" >&5
9572 sed 's/^/| /' conftest.$ac_ext >&5
9573
9574   # Passes both tests.
9575 ac_preproc_ok=:
9576 break
9577 fi
9578 rm -f conftest.err conftest.$ac_ext
9579
9580 done
9581 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
9582 rm -f conftest.err conftest.$ac_ext
9583 if $ac_preproc_ok; then
9584   break
9585 fi
9586
9587     done
9588     ac_cv_prog_CPP=$CPP
9589
9590 fi
9591   CPP=$ac_cv_prog_CPP
9592 else
9593   ac_cv_prog_CPP=$CPP
9594 fi
9595 echo "$as_me:$LINENO: result: $CPP" >&5
9596 echo "${ECHO_T}$CPP" >&6
9597 ac_preproc_ok=false
9598 for ac_c_preproc_warn_flag in '' yes
9599 do
9600   # Use a header file that comes with gcc, so configuring glibc
9601   # with a fresh cross-compiler works.
9602   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9603   # <limits.h> exists even on freestanding compilers.
9604   # On the NeXT, cc -E runs the code through the compiler's parser,
9605   # not just through cpp. "Syntax error" is here to catch this case.
9606   cat >conftest.$ac_ext <<_ACEOF
9607 #line $LINENO "configure"
9608 /* confdefs.h.  */
9609 _ACEOF
9610 cat confdefs.h >>conftest.$ac_ext
9611 cat >>conftest.$ac_ext <<_ACEOF
9612 /* end confdefs.h.  */
9613 #ifdef __STDC__
9614 # include <limits.h>
9615 #else
9616 # include <assert.h>
9617 #endif
9618                      Syntax error
9619 _ACEOF
9620 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9621   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9622   ac_status=$?
9623   grep -v '^ *+' conftest.er1 >conftest.err
9624   rm -f conftest.er1
9625   cat conftest.err >&5
9626   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9627   (exit $ac_status); } >/dev/null; then
9628   if test -s conftest.err; then
9629     ac_cpp_err=$ac_c_preproc_warn_flag
9630   else
9631     ac_cpp_err=
9632   fi
9633 else
9634   ac_cpp_err=yes
9635 fi
9636 if test -z "$ac_cpp_err"; then
9637   :
9638 else
9639   echo "$as_me: failed program was:" >&5
9640 sed 's/^/| /' conftest.$ac_ext >&5
9641
9642   # Broken: fails on valid input.
9643 continue
9644 fi
9645 rm -f conftest.err conftest.$ac_ext
9646
9647   # OK, works on sane cases.  Now check whether non-existent headers
9648   # can be detected and how.
9649   cat >conftest.$ac_ext <<_ACEOF
9650 #line $LINENO "configure"
9651 /* confdefs.h.  */
9652 _ACEOF
9653 cat confdefs.h >>conftest.$ac_ext
9654 cat >>conftest.$ac_ext <<_ACEOF
9655 /* end confdefs.h.  */
9656 #include <ac_nonexistent.h>
9657 _ACEOF
9658 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9659   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9660   ac_status=$?
9661   grep -v '^ *+' conftest.er1 >conftest.err
9662   rm -f conftest.er1
9663   cat conftest.err >&5
9664   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9665   (exit $ac_status); } >/dev/null; then
9666   if test -s conftest.err; then
9667     ac_cpp_err=$ac_c_preproc_warn_flag
9668   else
9669     ac_cpp_err=
9670   fi
9671 else
9672   ac_cpp_err=yes
9673 fi
9674 if test -z "$ac_cpp_err"; then
9675   # Broken: success on invalid input.
9676 continue
9677 else
9678   echo "$as_me: failed program was:" >&5
9679 sed 's/^/| /' conftest.$ac_ext >&5
9680
9681   # Passes both tests.
9682 ac_preproc_ok=:
9683 break
9684 fi
9685 rm -f conftest.err conftest.$ac_ext
9686
9687 done
9688 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
9689 rm -f conftest.err conftest.$ac_ext
9690 if $ac_preproc_ok; then
9691   :
9692 else
9693   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
9694 See \`config.log' for more details." >&5
9695 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
9696 See \`config.log' for more details." >&2;}
9697    { (exit 1); exit 1; }; }
9698 fi
9699
9700 ac_ext=c
9701 ac_cpp='$CPP $CPPFLAGS'
9702 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9703 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9704 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9705
9706
9707 if test $cross_compiling = yes -a $ol_enable_x_compile = yes; then
9708         { echo "$as_me:$LINENO: WARNING: cross compiling....  some functionality will be removed." >&5
9709 echo "$as_me: WARNING: cross compiling....  some functionality will be removed." >&2;}
9710
9711 elif test $cross_compiling = no -a $ol_enable_x_compile = yes; then
9712         { echo "$as_me:$LINENO: WARNING: programs compiled here do run here..." >&5
9713 echo "$as_me: WARNING: programs compiled here do run here..." >&2;}
9714         { { echo "$as_me:$LINENO: error:   if not cross compiling, use --disable-x-compile." >&5
9715 echo "$as_me: error:   if not cross compiling, use --disable-x-compile." >&2;}
9716    { (exit 1); exit 1; }; }
9717
9718 elif test $cross_compiling = yes -a $ol_enable_x_compile = no; then
9719         { echo "$as_me:$LINENO: WARNING: programs compiled here do not run here..." >&5
9720 echo "$as_me: WARNING: programs compiled here do not run here..." >&2;}
9721         { { echo "$as_me:$LINENO: error:   if cross compiling,  add --enable-x-compile." >&5
9722 echo "$as_me: error:   if cross compiling,  add --enable-x-compile." >&2;}
9723    { (exit 1); exit 1; }; }
9724 fi
9725
9726
9727
9728 case $host_os in
9729   *cygwin* ) CYGWIN=yes;;
9730          * ) CYGWIN=no;;
9731 esac
9732
9733
9734 case $host_os in
9735   *mingw32* ) MINGW32=yes;;
9736           * ) MINGW32=no;;
9737 esac
9738
9739
9740
9741
9742
9743 cat >>confdefs.h <<_ACEOF
9744 #define EXEEXT "${EXEEXT}"
9745 _ACEOF
9746
9747
9748 echo "$as_me:$LINENO: checking for be_app in -lbe" >&5
9749 echo $ECHO_N "checking for be_app in -lbe... $ECHO_C" >&6
9750 if test "${ac_cv_lib_be_be_app+set}" = set; then
9751   echo $ECHO_N "(cached) $ECHO_C" >&6
9752 else
9753   ac_check_lib_save_LIBS=$LIBS
9754 LIBS="-lbe -lroot -lnet $LIBS"
9755 cat >conftest.$ac_ext <<_ACEOF
9756 #line $LINENO "configure"
9757 /* confdefs.h.  */
9758 _ACEOF
9759 cat confdefs.h >>conftest.$ac_ext
9760 cat >>conftest.$ac_ext <<_ACEOF
9761 /* end confdefs.h.  */
9762
9763 /* Override any gcc2 internal prototype to avoid an error.  */
9764 #ifdef __cplusplus
9765 extern "C"
9766 #endif
9767 /* We use char because int might match the return type of a gcc2
9768    builtin and then its argument prototype would still apply.  */
9769 char be_app ();
9770 int
9771 main ()
9772 {
9773 be_app ();
9774   ;
9775   return 0;
9776 }
9777 _ACEOF
9778 rm -f conftest.$ac_objext conftest$ac_exeext
9779 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9780   (eval $ac_link) 2>&5
9781   ac_status=$?
9782   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9783   (exit $ac_status); } &&
9784          { ac_try='test -s conftest$ac_exeext'
9785   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9786   (eval $ac_try) 2>&5
9787   ac_status=$?
9788   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9789   (exit $ac_status); }; }; then
9790   ac_cv_lib_be_be_app=yes
9791 else
9792   echo "$as_me: failed program was:" >&5
9793 sed 's/^/| /' conftest.$ac_ext >&5
9794
9795 ac_cv_lib_be_be_app=no
9796 fi
9797 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9798 LIBS=$ac_check_lib_save_LIBS
9799 fi
9800 echo "$as_me:$LINENO: result: $ac_cv_lib_be_be_app" >&5
9801 echo "${ECHO_T}$ac_cv_lib_be_be_app" >&6
9802 if test $ac_cv_lib_be_be_app = yes; then
9803   LIBS="$LIBS -lbe -lroot -lnet"
9804 else
9805   :
9806 fi
9807
9808
9809
9810
9811
9812 echo "$as_me:$LINENO: checking for ${CC-cc} option to accept ANSI C" >&5
9813 echo $ECHO_N "checking for ${CC-cc} option to accept ANSI C... $ECHO_C" >&6
9814 if test "${am_cv_prog_cc_stdc+set}" = set; then
9815   echo $ECHO_N "(cached) $ECHO_C" >&6
9816 else
9817   am_cv_prog_cc_stdc=no
9818 ac_save_CC="$CC"
9819 # Don't try gcc -ansi; that turns off useful extensions and
9820 # breaks some systems' header files.
9821 # AIX                   -qlanglvl=ansi
9822 # Ultrix and OSF/1      -std1
9823 # HP-UX 10.20 and later -Ae
9824 # HP-UX older versions  -Aa -D_HPUX_SOURCE
9825 # SVR4                  -Xc -D__EXTENSIONS__
9826 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
9827 do
9828   CC="$ac_save_CC $ac_arg"
9829   cat >conftest.$ac_ext <<_ACEOF
9830 #line $LINENO "configure"
9831 /* confdefs.h.  */
9832 _ACEOF
9833 cat confdefs.h >>conftest.$ac_ext
9834 cat >>conftest.$ac_ext <<_ACEOF
9835 /* end confdefs.h.  */
9836 #include <stdarg.h>
9837 #include <stdio.h>
9838 #include <sys/types.h>
9839 #include <sys/stat.h>
9840 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
9841 struct buf { int x; };
9842 FILE * (*rcsopen) (struct buf *, struct stat *, int);
9843 static char *e (p, i)
9844      char **p;
9845      int i;
9846 {
9847   return p[i];
9848 }
9849 static char *f (char * (*g) (char **, int), char **p, ...)
9850 {
9851   char *s;
9852   va_list v;
9853   va_start (v,p);
9854   s = g (p, va_arg (v,int));
9855   va_end (v);
9856   return s;
9857 }
9858 int test (int i, double x);
9859 struct s1 {int (*f) (int a);};
9860 struct s2 {int (*f) (double a);};
9861 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
9862 int argc;
9863 char **argv;
9864
9865 int
9866 main ()
9867 {
9868
9869 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
9870
9871   ;
9872   return 0;
9873 }
9874 _ACEOF
9875 rm -f conftest.$ac_objext
9876 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9877   (eval $ac_compile) 2>&5
9878   ac_status=$?
9879   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9880   (exit $ac_status); } &&
9881          { ac_try='test -s conftest.$ac_objext'
9882   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9883   (eval $ac_try) 2>&5
9884   ac_status=$?
9885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9886   (exit $ac_status); }; }; then
9887   am_cv_prog_cc_stdc="$ac_arg"; break
9888 else
9889   echo "$as_me: failed program was:" >&5
9890 sed 's/^/| /' conftest.$ac_ext >&5
9891
9892 fi
9893 rm -f conftest.$ac_objext conftest.$ac_ext
9894 done
9895 CC="$ac_save_CC"
9896
9897 fi
9898
9899 if test -z "$am_cv_prog_cc_stdc"; then
9900   echo "$as_me:$LINENO: result: none needed" >&5
9901 echo "${ECHO_T}none needed" >&6
9902 else
9903   echo "$as_me:$LINENO: result: $am_cv_prog_cc_stdc" >&5
9904 echo "${ECHO_T}$am_cv_prog_cc_stdc" >&6
9905 fi
9906 case "x$am_cv_prog_cc_stdc" in
9907   x|xno) ;;
9908   *) CC="$CC $am_cv_prog_cc_stdc" ;;
9909 esac
9910
9911 if test "X${am_cv_prog_cc_stdc}" = "Xno" ; then
9912         { { echo "$as_me:$LINENO: error: OpenLDAP requires compiler to support STDC constructs." >&5
9913 echo "$as_me: error: OpenLDAP requires compiler to support STDC constructs." >&2;}
9914    { (exit 1); exit 1; }; }
9915 fi
9916
9917 # test for make depend flag
9918 OL_MKDEP=
9919 OL_MKDEP_FLAGS=
9920 if test -z "${MKDEP}"; then
9921         OL_MKDEP="${CC-cc}"
9922         if test -z "${MKDEP_FLAGS}"; then
9923                 echo "$as_me:$LINENO: checking for ${OL_MKDEP} depend flag" >&5
9924 echo $ECHO_N "checking for ${OL_MKDEP} depend flag... $ECHO_C" >&6
9925 if test "${ol_cv_mkdep+set}" = set; then
9926   echo $ECHO_N "(cached) $ECHO_C" >&6
9927 else
9928
9929                         ol_cv_mkdep=no
9930                         for flag in "-M" "-xM"; do
9931                                 cat > conftest.c <<EOF
9932  noCode;
9933 EOF
9934                                 if { ac_try='$OL_MKDEP $flag conftest.c'
9935   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9936   (eval $ac_try) 2>&5
9937   ac_status=$?
9938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9939   (exit $ac_status); }; } \
9940                                         | egrep '^conftest\.'"${ac_objext}" >/dev/null 2>&1
9941                                 then
9942                                         if test ! -f conftest."${ac_object}" ; then
9943                                                 ol_cv_mkdep=$flag
9944                                                 OL_MKDEP_FLAGS="$flag"
9945                                                 break
9946                                         fi
9947                                 fi
9948                         done
9949                         rm -f conftest*
9950
9951 fi
9952 echo "$as_me:$LINENO: result: $ol_cv_mkdep" >&5
9953 echo "${ECHO_T}$ol_cv_mkdep" >&6
9954         else
9955                 cc_cv_mkdep=yes
9956                 OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
9957         fi
9958 else
9959         cc_cv_mkdep=yes
9960         OL_MKDEP="${MKDEP}"
9961         OL_MKDEP_FLAGS="${MKDEP_FLAGS}"
9962 fi
9963
9964
9965
9966 if test "${ol_cv_mkdep}" = no ; then
9967         # this will soon become an error
9968         { echo "$as_me:$LINENO: WARNING: do not know how to generate dependencies" >&5
9969 echo "$as_me: WARNING: do not know how to generate dependencies" >&2;}
9970 fi
9971
9972 echo "$as_me:$LINENO: checking for afopen in -ls" >&5
9973 echo $ECHO_N "checking for afopen in -ls... $ECHO_C" >&6
9974 if test "${ac_cv_lib_s_afopen+set}" = set; then
9975   echo $ECHO_N "(cached) $ECHO_C" >&6
9976 else
9977   ac_check_lib_save_LIBS=$LIBS
9978 LIBS="-ls  $LIBS"
9979 cat >conftest.$ac_ext <<_ACEOF
9980 #line $LINENO "configure"
9981 /* confdefs.h.  */
9982 _ACEOF
9983 cat confdefs.h >>conftest.$ac_ext
9984 cat >>conftest.$ac_ext <<_ACEOF
9985 /* end confdefs.h.  */
9986
9987 /* Override any gcc2 internal prototype to avoid an error.  */
9988 #ifdef __cplusplus
9989 extern "C"
9990 #endif
9991 /* We use char because int might match the return type of a gcc2
9992    builtin and then its argument prototype would still apply.  */
9993 char afopen ();
9994 int
9995 main ()
9996 {
9997 afopen ();
9998   ;
9999   return 0;
10000 }
10001 _ACEOF
10002 rm -f conftest.$ac_objext conftest$ac_exeext
10003 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10004   (eval $ac_link) 2>&5
10005   ac_status=$?
10006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10007   (exit $ac_status); } &&
10008          { ac_try='test -s conftest$ac_exeext'
10009   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10010   (eval $ac_try) 2>&5
10011   ac_status=$?
10012   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10013   (exit $ac_status); }; }; then
10014   ac_cv_lib_s_afopen=yes
10015 else
10016   echo "$as_me: failed program was:" >&5
10017 sed 's/^/| /' conftest.$ac_ext >&5
10018
10019 ac_cv_lib_s_afopen=no
10020 fi
10021 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10022 LIBS=$ac_check_lib_save_LIBS
10023 fi
10024 echo "$as_me:$LINENO: result: $ac_cv_lib_s_afopen" >&5
10025 echo "${ECHO_T}$ac_cv_lib_s_afopen" >&6
10026 if test $ac_cv_lib_s_afopen = yes; then
10027
10028         AUTH_LIBS=-ls
10029
10030 cat >>confdefs.h <<\_ACEOF
10031 #define HAVE_AIX_SECURITY 1
10032 _ACEOF
10033
10034
10035 fi
10036
10037
10038 case "$target" in
10039 *-ibm-openedition)
10040         ac_cv_func_getopt=no
10041
10042 cat >>confdefs.h <<\_ACEOF
10043 #define BOTH_STRINGS_H 1
10044 _ACEOF
10045
10046         ;;
10047 esac
10048
10049 ol_link_modules=no
10050 if test $ol_enable_modules != no ; then
10051
10052 for ac_header in ltdl.h
10053 do
10054 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10055 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10056   echo "$as_me:$LINENO: checking for $ac_header" >&5
10057 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10058 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10059   echo $ECHO_N "(cached) $ECHO_C" >&6
10060 fi
10061 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10062 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10063 else
10064   # Is the header compilable?
10065 echo "$as_me:$LINENO: checking $ac_header usability" >&5
10066 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
10067 cat >conftest.$ac_ext <<_ACEOF
10068 #line $LINENO "configure"
10069 /* confdefs.h.  */
10070 _ACEOF
10071 cat confdefs.h >>conftest.$ac_ext
10072 cat >>conftest.$ac_ext <<_ACEOF
10073 /* end confdefs.h.  */
10074 $ac_includes_default
10075 #include <$ac_header>
10076 _ACEOF
10077 rm -f conftest.$ac_objext
10078 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10079   (eval $ac_compile) 2>&5
10080   ac_status=$?
10081   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10082   (exit $ac_status); } &&
10083          { ac_try='test -s conftest.$ac_objext'
10084   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10085   (eval $ac_try) 2>&5
10086   ac_status=$?
10087   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10088   (exit $ac_status); }; }; then
10089   ac_header_compiler=yes
10090 else
10091   echo "$as_me: failed program was:" >&5
10092 sed 's/^/| /' conftest.$ac_ext >&5
10093
10094 ac_header_compiler=no
10095 fi
10096 rm -f conftest.$ac_objext conftest.$ac_ext
10097 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10098 echo "${ECHO_T}$ac_header_compiler" >&6
10099
10100 # Is the header present?
10101 echo "$as_me:$LINENO: checking $ac_header presence" >&5
10102 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
10103 cat >conftest.$ac_ext <<_ACEOF
10104 #line $LINENO "configure"
10105 /* confdefs.h.  */
10106 _ACEOF
10107 cat confdefs.h >>conftest.$ac_ext
10108 cat >>conftest.$ac_ext <<_ACEOF
10109 /* end confdefs.h.  */
10110 #include <$ac_header>
10111 _ACEOF
10112 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10113   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10114   ac_status=$?
10115   grep -v '^ *+' conftest.er1 >conftest.err
10116   rm -f conftest.er1
10117   cat conftest.err >&5
10118   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10119   (exit $ac_status); } >/dev/null; then
10120   if test -s conftest.err; then
10121     ac_cpp_err=$ac_c_preproc_warn_flag
10122   else
10123     ac_cpp_err=
10124   fi
10125 else
10126   ac_cpp_err=yes
10127 fi
10128 if test -z "$ac_cpp_err"; then
10129   ac_header_preproc=yes
10130 else
10131   echo "$as_me: failed program was:" >&5
10132 sed 's/^/| /' conftest.$ac_ext >&5
10133
10134   ac_header_preproc=no
10135 fi
10136 rm -f conftest.err conftest.$ac_ext
10137 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10138 echo "${ECHO_T}$ac_header_preproc" >&6
10139
10140 # So?  What about this header?
10141 case $ac_header_compiler:$ac_header_preproc in
10142   yes:no )
10143     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10144 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10145     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10146 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10147     (
10148       cat <<\_ASBOX
10149 ## ------------------------------------ ##
10150 ## Report this to bug-autoconf@gnu.org. ##
10151 ## ------------------------------------ ##
10152 _ASBOX
10153     ) |
10154       sed "s/^/$as_me: WARNING:     /" >&2
10155     ;;
10156   no:yes )
10157     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10158 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10159     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
10160 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
10161     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10162 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10163     (
10164       cat <<\_ASBOX
10165 ## ------------------------------------ ##
10166 ## Report this to bug-autoconf@gnu.org. ##
10167 ## ------------------------------------ ##
10168 _ASBOX
10169     ) |
10170       sed "s/^/$as_me: WARNING:     /" >&2
10171     ;;
10172 esac
10173 echo "$as_me:$LINENO: checking for $ac_header" >&5
10174 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10175 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10176   echo $ECHO_N "(cached) $ECHO_C" >&6
10177 else
10178   eval "$as_ac_Header=$ac_header_preproc"
10179 fi
10180 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10181 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10182
10183 fi
10184 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10185   cat >>confdefs.h <<_ACEOF
10186 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10187 _ACEOF
10188
10189 fi
10190
10191 done
10192
10193
10194         if test $ac_cv_header_ltdl_h = no ; then
10195                 { { echo "$as_me:$LINENO: error: could not locate libtool ltdl.h" >&5
10196 echo "$as_me: error: could not locate libtool ltdl.h" >&2;}
10197    { (exit 1); exit 1; }; }
10198         fi
10199
10200         echo "$as_me:$LINENO: checking for lt_dlinit in -lltdl" >&5
10201 echo $ECHO_N "checking for lt_dlinit in -lltdl... $ECHO_C" >&6
10202 if test "${ac_cv_lib_ltdl_lt_dlinit+set}" = set; then
10203   echo $ECHO_N "(cached) $ECHO_C" >&6
10204 else
10205   ac_check_lib_save_LIBS=$LIBS
10206 LIBS="-lltdl  $LIBS"
10207 cat >conftest.$ac_ext <<_ACEOF
10208 #line $LINENO "configure"
10209 /* confdefs.h.  */
10210 _ACEOF
10211 cat confdefs.h >>conftest.$ac_ext
10212 cat >>conftest.$ac_ext <<_ACEOF
10213 /* end confdefs.h.  */
10214
10215 /* Override any gcc2 internal prototype to avoid an error.  */
10216 #ifdef __cplusplus
10217 extern "C"
10218 #endif
10219 /* We use char because int might match the return type of a gcc2
10220    builtin and then its argument prototype would still apply.  */
10221 char lt_dlinit ();
10222 int
10223 main ()
10224 {
10225 lt_dlinit ();
10226   ;
10227   return 0;
10228 }
10229 _ACEOF
10230 rm -f conftest.$ac_objext conftest$ac_exeext
10231 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10232   (eval $ac_link) 2>&5
10233   ac_status=$?
10234   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10235   (exit $ac_status); } &&
10236          { ac_try='test -s conftest$ac_exeext'
10237   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10238   (eval $ac_try) 2>&5
10239   ac_status=$?
10240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10241   (exit $ac_status); }; }; then
10242   ac_cv_lib_ltdl_lt_dlinit=yes
10243 else
10244   echo "$as_me: failed program was:" >&5
10245 sed 's/^/| /' conftest.$ac_ext >&5
10246
10247 ac_cv_lib_ltdl_lt_dlinit=no
10248 fi
10249 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10250 LIBS=$ac_check_lib_save_LIBS
10251 fi
10252 echo "$as_me:$LINENO: result: $ac_cv_lib_ltdl_lt_dlinit" >&5
10253 echo "${ECHO_T}$ac_cv_lib_ltdl_lt_dlinit" >&6
10254 if test $ac_cv_lib_ltdl_lt_dlinit = yes; then
10255
10256                 MODULES_LIBS=-lltdl
10257
10258 cat >>confdefs.h <<\_ACEOF
10259 #define HAVE_LIBLTDL 1
10260 _ACEOF
10261
10262
10263 fi
10264
10265
10266         if test "$ac_cv_lib_ltdl_lt_dlinit" = no ; then
10267                 { { echo "$as_me:$LINENO: error: could not locate libtool -lltdl" >&5
10268 echo "$as_me: error: could not locate libtool -lltdl" >&2;}
10269    { (exit 1); exit 1; }; }
10270         fi
10271         ol_link_modules=yes
10272 else
10273         ol_with_bdb_module=static
10274         ol_with_dnssrv_module=static
10275         ol_with_ldap_module=static
10276         ol_with_ldbm_module=static
10277         ol_with_meta_module=static
10278         ol_with_monitor_module=static
10279         ol_with_null_module=static
10280         ol_with_passwd_module=static
10281         ol_with_perl_module=static
10282         ol_with_shell_module=static
10283         ol_with_tcl_module=static
10284         ol_with_sql_module=static
10285 fi
10286
10287 # test for EBCDIC
10288 echo "$as_me:$LINENO: checking for EBCDIC" >&5
10289 echo $ECHO_N "checking for EBCDIC... $ECHO_C" >&6
10290 if test "${ol_cv_cpp_ebcdic+set}" = set; then
10291   echo $ECHO_N "(cached) $ECHO_C" >&6
10292 else
10293
10294         cat >conftest.$ac_ext <<_ACEOF
10295 #line $LINENO "configure"
10296 /* confdefs.h.  */
10297 _ACEOF
10298 cat confdefs.h >>conftest.$ac_ext
10299 cat >>conftest.$ac_ext <<_ACEOF
10300 /* end confdefs.h.  */
10301
10302 #if !('M' == 0xd4)
10303 #include <__ASCII__/generate_error.h>
10304 #endif
10305
10306 _ACEOF
10307 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10308   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10309   ac_status=$?
10310   grep -v '^ *+' conftest.er1 >conftest.err
10311   rm -f conftest.er1
10312   cat conftest.err >&5
10313   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10314   (exit $ac_status); } >/dev/null; then
10315   if test -s conftest.err; then
10316     ac_cpp_err=$ac_c_preproc_warn_flag
10317   else
10318     ac_cpp_err=
10319   fi
10320 else
10321   ac_cpp_err=yes
10322 fi
10323 if test -z "$ac_cpp_err"; then
10324   ol_cv_cpp_ebcdic=yes
10325 else
10326   echo "$as_me: failed program was:" >&5
10327 sed 's/^/| /' conftest.$ac_ext >&5
10328
10329   ol_cv_cpp_ebcdic=no
10330 fi
10331 rm -f conftest.err conftest.$ac_ext
10332 fi
10333 echo "$as_me:$LINENO: result: $ol_cv_cpp_ebcdic" >&5
10334 echo "${ECHO_T}$ol_cv_cpp_ebcdic" >&6
10335 if test $ol_cv_cpp_ebcdic = yes ; then
10336
10337 cat >>confdefs.h <<\_ACEOF
10338 #define HAVE_EBCDIC 1
10339 _ACEOF
10340
10341 fi
10342
10343 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
10344 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
10345 if test "${ol_cv_header_stdc+set}" = set; then
10346   echo $ECHO_N "(cached) $ECHO_C" >&6
10347 else
10348   cat >conftest.$ac_ext <<_ACEOF
10349 #line $LINENO "configure"
10350 /* confdefs.h.  */
10351 _ACEOF
10352 cat confdefs.h >>conftest.$ac_ext
10353 cat >>conftest.$ac_ext <<_ACEOF
10354 /* end confdefs.h.  */
10355 #include <stdlib.h>
10356 #include <stdarg.h>
10357 #include <string.h>
10358 #include <float.h>
10359 _ACEOF
10360 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10361   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10362   ac_status=$?
10363   grep -v '^ *+' conftest.er1 >conftest.err
10364   rm -f conftest.er1
10365   cat conftest.err >&5
10366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10367   (exit $ac_status); } >/dev/null; then
10368   if test -s conftest.err; then
10369     ac_cpp_err=$ac_c_preproc_warn_flag
10370   else
10371     ac_cpp_err=
10372   fi
10373 else
10374   ac_cpp_err=yes
10375 fi
10376 if test -z "$ac_cpp_err"; then
10377   ol_cv_header_stdc=yes
10378 else
10379   echo "$as_me: failed program was:" >&5
10380 sed 's/^/| /' conftest.$ac_ext >&5
10381
10382   ol_cv_header_stdc=no
10383 fi
10384 rm -f conftest.err conftest.$ac_ext
10385
10386 if test $ol_cv_header_stdc = yes; then
10387   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
10388 cat >conftest.$ac_ext <<_ACEOF
10389 #line $LINENO "configure"
10390 /* confdefs.h.  */
10391 _ACEOF
10392 cat confdefs.h >>conftest.$ac_ext
10393 cat >>conftest.$ac_ext <<_ACEOF
10394 /* end confdefs.h.  */
10395 #include <string.h>
10396
10397 _ACEOF
10398 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10399   $EGREP "memchr" >/dev/null 2>&1; then
10400   :
10401 else
10402   ol_cv_header_stdc=no
10403 fi
10404 rm -f conftest*
10405
10406 fi
10407
10408 if test $ol_cv_header_stdc = yes; then
10409   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
10410 cat >conftest.$ac_ext <<_ACEOF
10411 #line $LINENO "configure"
10412 /* confdefs.h.  */
10413 _ACEOF
10414 cat confdefs.h >>conftest.$ac_ext
10415 cat >>conftest.$ac_ext <<_ACEOF
10416 /* end confdefs.h.  */
10417 #include <stdlib.h>
10418
10419 _ACEOF
10420 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10421   $EGREP "free" >/dev/null 2>&1; then
10422   :
10423 else
10424   ol_cv_header_stdc=no
10425 fi
10426 rm -f conftest*
10427
10428 fi
10429
10430 if test $ol_cv_header_stdc = yes; then
10431   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
10432 if test "$cross_compiling" = yes; then
10433   :
10434 else
10435   cat >conftest.$ac_ext <<_ACEOF
10436 #line $LINENO "configure"
10437 /* confdefs.h.  */
10438 _ACEOF
10439 cat confdefs.h >>conftest.$ac_ext
10440 cat >>conftest.$ac_ext <<_ACEOF
10441 /* end confdefs.h.  */
10442 #include <ctype.h>
10443 #ifndef HAVE_EBCDIC
10444 #       define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
10445 #       define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
10446 #else
10447 #       define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
10448                 || ('j' <= (c) && (c) <= 'r') \
10449                 || ('s' <= (c) && (c) <= 'z'))
10450 #       define TOUPPER(c)       (ISLOWER(c) ? ((c) | 0x40) : (c))
10451 #endif
10452 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
10453 int main () { int i; for (i = 0; i < 256; i++)
10454 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
10455 exit (0); }
10456
10457 _ACEOF
10458 rm -f conftest$ac_exeext
10459 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10460   (eval $ac_link) 2>&5
10461   ac_status=$?
10462   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10463   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
10464   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10465   (eval $ac_try) 2>&5
10466   ac_status=$?
10467   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10468   (exit $ac_status); }; }; then
10469   :
10470 else
10471   echo "$as_me: program exited with status $ac_status" >&5
10472 echo "$as_me: failed program was:" >&5
10473 sed 's/^/| /' conftest.$ac_ext >&5
10474
10475 ( exit $ac_status )
10476 ol_cv_header_stdc=no
10477 fi
10478 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
10479 fi
10480 fi
10481 fi
10482 echo "$as_me:$LINENO: result: $ol_cv_header_stdc" >&5
10483 echo "${ECHO_T}$ol_cv_header_stdc" >&6
10484 if test $ol_cv_header_stdc = yes; then
10485   cat >>confdefs.h <<\_ACEOF
10486 #define STDC_HEADERS 1
10487 _ACEOF
10488
10489 fi
10490 ac_cv_header_stdc=disable
10491
10492
10493 if test $ol_cv_header_stdc != yes; then
10494         { echo "$as_me:$LINENO: WARNING: could not locate Standard C compliant headers" >&5
10495 echo "$as_me: WARNING: could not locate Standard C compliant headers" >&2;}
10496 fi
10497
10498
10499
10500
10501
10502
10503 ac_header_dirent=no
10504 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
10505   as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
10506 echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
10507 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
10508 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10509   echo $ECHO_N "(cached) $ECHO_C" >&6
10510 else
10511   cat >conftest.$ac_ext <<_ACEOF
10512 #line $LINENO "configure"
10513 /* confdefs.h.  */
10514 _ACEOF
10515 cat confdefs.h >>conftest.$ac_ext
10516 cat >>conftest.$ac_ext <<_ACEOF
10517 /* end confdefs.h.  */
10518 #include <sys/types.h>
10519 #include <$ac_hdr>
10520
10521 int
10522 main ()
10523 {
10524 if ((DIR *) 0)
10525 return 0;
10526   ;
10527   return 0;
10528 }
10529 _ACEOF
10530 rm -f conftest.$ac_objext
10531 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10532   (eval $ac_compile) 2>&5
10533   ac_status=$?
10534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10535   (exit $ac_status); } &&
10536          { ac_try='test -s conftest.$ac_objext'
10537   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10538   (eval $ac_try) 2>&5
10539   ac_status=$?
10540   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10541   (exit $ac_status); }; }; then
10542   eval "$as_ac_Header=yes"
10543 else
10544   echo "$as_me: failed program was:" >&5
10545 sed 's/^/| /' conftest.$ac_ext >&5
10546
10547 eval "$as_ac_Header=no"
10548 fi
10549 rm -f conftest.$ac_objext conftest.$ac_ext
10550 fi
10551 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10552 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10553 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10554   cat >>confdefs.h <<_ACEOF
10555 #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
10556 _ACEOF
10557
10558 ac_header_dirent=$ac_hdr; break
10559 fi
10560
10561 done
10562 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
10563 if test $ac_header_dirent = dirent.h; then
10564   echo "$as_me:$LINENO: checking for library containing opendir" >&5
10565 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
10566 if test "${ac_cv_search_opendir+set}" = set; then
10567   echo $ECHO_N "(cached) $ECHO_C" >&6
10568 else
10569   ac_func_search_save_LIBS=$LIBS
10570 ac_cv_search_opendir=no
10571 cat >conftest.$ac_ext <<_ACEOF
10572 #line $LINENO "configure"
10573 /* confdefs.h.  */
10574 _ACEOF
10575 cat confdefs.h >>conftest.$ac_ext
10576 cat >>conftest.$ac_ext <<_ACEOF
10577 /* end confdefs.h.  */
10578
10579 /* Override any gcc2 internal prototype to avoid an error.  */
10580 #ifdef __cplusplus
10581 extern "C"
10582 #endif
10583 /* We use char because int might match the return type of a gcc2
10584    builtin and then its argument prototype would still apply.  */
10585 char opendir ();
10586 int
10587 main ()
10588 {
10589 opendir ();
10590   ;
10591   return 0;
10592 }
10593 _ACEOF
10594 rm -f conftest.$ac_objext conftest$ac_exeext
10595 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10596   (eval $ac_link) 2>&5
10597   ac_status=$?
10598   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10599   (exit $ac_status); } &&
10600          { ac_try='test -s conftest$ac_exeext'
10601   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10602   (eval $ac_try) 2>&5
10603   ac_status=$?
10604   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10605   (exit $ac_status); }; }; then
10606   ac_cv_search_opendir="none required"
10607 else
10608   echo "$as_me: failed program was:" >&5
10609 sed 's/^/| /' conftest.$ac_ext >&5
10610
10611 fi
10612 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10613 if test "$ac_cv_search_opendir" = no; then
10614   for ac_lib in dir; do
10615     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
10616     cat >conftest.$ac_ext <<_ACEOF
10617 #line $LINENO "configure"
10618 /* confdefs.h.  */
10619 _ACEOF
10620 cat confdefs.h >>conftest.$ac_ext
10621 cat >>conftest.$ac_ext <<_ACEOF
10622 /* end confdefs.h.  */
10623
10624 /* Override any gcc2 internal prototype to avoid an error.  */
10625 #ifdef __cplusplus
10626 extern "C"
10627 #endif
10628 /* We use char because int might match the return type of a gcc2
10629    builtin and then its argument prototype would still apply.  */
10630 char opendir ();
10631 int
10632 main ()
10633 {
10634 opendir ();
10635   ;
10636   return 0;
10637 }
10638 _ACEOF
10639 rm -f conftest.$ac_objext conftest$ac_exeext
10640 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10641   (eval $ac_link) 2>&5
10642   ac_status=$?
10643   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10644   (exit $ac_status); } &&
10645          { ac_try='test -s conftest$ac_exeext'
10646   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10647   (eval $ac_try) 2>&5
10648   ac_status=$?
10649   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10650   (exit $ac_status); }; }; then
10651   ac_cv_search_opendir="-l$ac_lib"
10652 break
10653 else
10654   echo "$as_me: failed program was:" >&5
10655 sed 's/^/| /' conftest.$ac_ext >&5
10656
10657 fi
10658 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10659   done
10660 fi
10661 LIBS=$ac_func_search_save_LIBS
10662 fi
10663 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
10664 echo "${ECHO_T}$ac_cv_search_opendir" >&6
10665 if test "$ac_cv_search_opendir" != no; then
10666   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
10667
10668 fi
10669
10670 else
10671   echo "$as_me:$LINENO: checking for library containing opendir" >&5
10672 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
10673 if test "${ac_cv_search_opendir+set}" = set; then
10674   echo $ECHO_N "(cached) $ECHO_C" >&6
10675 else
10676   ac_func_search_save_LIBS=$LIBS
10677 ac_cv_search_opendir=no
10678 cat >conftest.$ac_ext <<_ACEOF
10679 #line $LINENO "configure"
10680 /* confdefs.h.  */
10681 _ACEOF
10682 cat confdefs.h >>conftest.$ac_ext
10683 cat >>conftest.$ac_ext <<_ACEOF
10684 /* end confdefs.h.  */
10685
10686 /* Override any gcc2 internal prototype to avoid an error.  */
10687 #ifdef __cplusplus
10688 extern "C"
10689 #endif
10690 /* We use char because int might match the return type of a gcc2
10691    builtin and then its argument prototype would still apply.  */
10692 char opendir ();
10693 int
10694 main ()
10695 {
10696 opendir ();
10697   ;
10698   return 0;
10699 }
10700 _ACEOF
10701 rm -f conftest.$ac_objext conftest$ac_exeext
10702 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10703   (eval $ac_link) 2>&5
10704   ac_status=$?
10705   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10706   (exit $ac_status); } &&
10707          { ac_try='test -s conftest$ac_exeext'
10708   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10709   (eval $ac_try) 2>&5
10710   ac_status=$?
10711   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10712   (exit $ac_status); }; }; then
10713   ac_cv_search_opendir="none required"
10714 else
10715   echo "$as_me: failed program was:" >&5
10716 sed 's/^/| /' conftest.$ac_ext >&5
10717
10718 fi
10719 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10720 if test "$ac_cv_search_opendir" = no; then
10721   for ac_lib in x; do
10722     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
10723     cat >conftest.$ac_ext <<_ACEOF
10724 #line $LINENO "configure"
10725 /* confdefs.h.  */
10726 _ACEOF
10727 cat confdefs.h >>conftest.$ac_ext
10728 cat >>conftest.$ac_ext <<_ACEOF
10729 /* end confdefs.h.  */
10730
10731 /* Override any gcc2 internal prototype to avoid an error.  */
10732 #ifdef __cplusplus
10733 extern "C"
10734 #endif
10735 /* We use char because int might match the return type of a gcc2
10736    builtin and then its argument prototype would still apply.  */
10737 char opendir ();
10738 int
10739 main ()
10740 {
10741 opendir ();
10742   ;
10743   return 0;
10744 }
10745 _ACEOF
10746 rm -f conftest.$ac_objext conftest$ac_exeext
10747 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10748   (eval $ac_link) 2>&5
10749   ac_status=$?
10750   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10751   (exit $ac_status); } &&
10752          { ac_try='test -s conftest$ac_exeext'
10753   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10754   (eval $ac_try) 2>&5
10755   ac_status=$?
10756   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10757   (exit $ac_status); }; }; then
10758   ac_cv_search_opendir="-l$ac_lib"
10759 break
10760 else
10761   echo "$as_me: failed program was:" >&5
10762 sed 's/^/| /' conftest.$ac_ext >&5
10763
10764 fi
10765 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10766   done
10767 fi
10768 LIBS=$ac_func_search_save_LIBS
10769 fi
10770 echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
10771 echo "${ECHO_T}$ac_cv_search_opendir" >&6
10772 if test "$ac_cv_search_opendir" != no; then
10773   test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
10774
10775 fi
10776
10777 fi
10778
10779 echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
10780 echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
10781 if test "${ac_cv_header_sys_wait_h+set}" = set; then
10782   echo $ECHO_N "(cached) $ECHO_C" >&6
10783 else
10784   cat >conftest.$ac_ext <<_ACEOF
10785 #line $LINENO "configure"
10786 /* confdefs.h.  */
10787 _ACEOF
10788 cat confdefs.h >>conftest.$ac_ext
10789 cat >>conftest.$ac_ext <<_ACEOF
10790 /* end confdefs.h.  */
10791 #include <sys/types.h>
10792 #include <sys/wait.h>
10793 #ifndef WEXITSTATUS
10794 # define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
10795 #endif
10796 #ifndef WIFEXITED
10797 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
10798 #endif
10799
10800 int
10801 main ()
10802 {
10803   int s;
10804   wait (&s);
10805   s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
10806   ;
10807   return 0;
10808 }
10809 _ACEOF
10810 rm -f conftest.$ac_objext
10811 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10812   (eval $ac_compile) 2>&5
10813   ac_status=$?
10814   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10815   (exit $ac_status); } &&
10816          { ac_try='test -s conftest.$ac_objext'
10817   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10818   (eval $ac_try) 2>&5
10819   ac_status=$?
10820   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10821   (exit $ac_status); }; }; then
10822   ac_cv_header_sys_wait_h=yes
10823 else
10824   echo "$as_me: failed program was:" >&5
10825 sed 's/^/| /' conftest.$ac_ext >&5
10826
10827 ac_cv_header_sys_wait_h=no
10828 fi
10829 rm -f conftest.$ac_objext conftest.$ac_ext
10830 fi
10831 echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
10832 echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
10833 if test $ac_cv_header_sys_wait_h = yes; then
10834
10835 cat >>confdefs.h <<\_ACEOF
10836 #define HAVE_SYS_WAIT_H 1
10837 _ACEOF
10838
10839 fi
10840
10841 echo "$as_me:$LINENO: checking whether termios.h defines TIOCGWINSZ" >&5
10842 echo $ECHO_N "checking whether termios.h defines TIOCGWINSZ... $ECHO_C" >&6
10843 if test "${ac_cv_sys_tiocgwinsz_in_termios_h+set}" = set; then
10844   echo $ECHO_N "(cached) $ECHO_C" >&6
10845 else
10846   cat >conftest.$ac_ext <<_ACEOF
10847 #line $LINENO "configure"
10848 /* confdefs.h.  */
10849 _ACEOF
10850 cat confdefs.h >>conftest.$ac_ext
10851 cat >>conftest.$ac_ext <<_ACEOF
10852 /* end confdefs.h.  */
10853 #include <sys/types.h>
10854 #include <termios.h>
10855 #ifdef TIOCGWINSZ
10856   yes
10857 #endif
10858
10859 _ACEOF
10860 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10861   $EGREP "yes" >/dev/null 2>&1; then
10862   ac_cv_sys_tiocgwinsz_in_termios_h=yes
10863 else
10864   ac_cv_sys_tiocgwinsz_in_termios_h=no
10865 fi
10866 rm -f conftest*
10867
10868 fi
10869 echo "$as_me:$LINENO: result: $ac_cv_sys_tiocgwinsz_in_termios_h" >&5
10870 echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_termios_h" >&6
10871
10872 if test $ac_cv_sys_tiocgwinsz_in_termios_h != yes; then
10873   echo "$as_me:$LINENO: checking whether sys/ioctl.h defines TIOCGWINSZ" >&5
10874 echo $ECHO_N "checking whether sys/ioctl.h defines TIOCGWINSZ... $ECHO_C" >&6
10875 if test "${ac_cv_sys_tiocgwinsz_in_sys_ioctl_h+set}" = set; then
10876   echo $ECHO_N "(cached) $ECHO_C" >&6
10877 else
10878   cat >conftest.$ac_ext <<_ACEOF
10879 #line $LINENO "configure"
10880 /* confdefs.h.  */
10881 _ACEOF
10882 cat confdefs.h >>conftest.$ac_ext
10883 cat >>conftest.$ac_ext <<_ACEOF
10884 /* end confdefs.h.  */
10885 #include <sys/types.h>
10886 #include <sys/ioctl.h>
10887 #ifdef TIOCGWINSZ
10888   yes
10889 #endif
10890
10891 _ACEOF
10892 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10893   $EGREP "yes" >/dev/null 2>&1; then
10894   ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=yes
10895 else
10896   ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=no
10897 fi
10898 rm -f conftest*
10899
10900 fi
10901 echo "$as_me:$LINENO: result: $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&5
10902 echo "${ECHO_T}$ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&6
10903
10904   if test $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h = yes; then
10905
10906 cat >>confdefs.h <<\_ACEOF
10907 #define GWINSZ_IN_SYS_IOCTL 1
10908 _ACEOF
10909
10910   fi
10911 fi
10912
10913 if test $am_cv_sys_posix_termios = yes ; then
10914
10915 cat >>confdefs.h <<\_ACEOF
10916 #define HAVE_POSIX_TERMIOS 1
10917 _ACEOF
10918
10919 fi
10920
10921
10922
10923
10924
10925
10926
10927
10928
10929
10930
10931
10932
10933
10934
10935
10936
10937
10938
10939
10940
10941
10942
10943
10944
10945
10946
10947
10948
10949
10950
10951
10952
10953
10954
10955
10956
10957
10958
10959
10960
10961
10962
10963
10964
10965
10966 for ac_header in \
10967         arpa/inet.h             \
10968         arpa/nameser.h  \
10969         assert.h                \
10970         conio.h                 \
10971         crypt.h                 \
10972         direct.h                \
10973         errno.h                 \
10974         fcntl.h                 \
10975         filio.h                 \
10976         getopt.h                \
10977         grp.h                   \
10978         io.h                    \
10979         libutil.h               \
10980         limits.h                \
10981         locale.h                \
10982         netinet/tcp.h   \
10983         malloc.h                \
10984         memory.h                \
10985         psap.h                  \
10986         pwd.h                   \
10987         process.h               \
10988         sgtty.h                 \
10989         shadow.h                \
10990         stddef.h                \
10991         string.h                \
10992         strings.h               \
10993         sysexits.h              \
10994         sys/file.h              \
10995         sys/filio.h             \
10996         sys/errno.h             \
10997         sys/ioctl.h             \
10998         sys/param.h             \
10999         sys/resource.h  \
11000         sys/select.h    \
11001         sys/socket.h    \
11002         sys/stat.h              \
11003         sys/syslog.h    \
11004         sys/time.h              \
11005         sys/types.h             \
11006         sys/uio.h               \
11007         syslog.h                \
11008         termios.h               \
11009         unistd.h                \
11010         winsock.h               \
11011         winsock2.h              \
11012
11013 do
11014 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11015 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11016   echo "$as_me:$LINENO: checking for $ac_header" >&5
11017 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11018 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11019   echo $ECHO_N "(cached) $ECHO_C" >&6
11020 fi
11021 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11022 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11023 else
11024   # Is the header compilable?
11025 echo "$as_me:$LINENO: checking $ac_header usability" >&5
11026 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
11027 cat >conftest.$ac_ext <<_ACEOF
11028 #line $LINENO "configure"
11029 /* confdefs.h.  */
11030 _ACEOF
11031 cat confdefs.h >>conftest.$ac_ext
11032 cat >>conftest.$ac_ext <<_ACEOF
11033 /* end confdefs.h.  */
11034 $ac_includes_default
11035 #include <$ac_header>
11036 _ACEOF
11037 rm -f conftest.$ac_objext
11038 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11039   (eval $ac_compile) 2>&5
11040   ac_status=$?
11041   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11042   (exit $ac_status); } &&
11043          { ac_try='test -s conftest.$ac_objext'
11044   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11045   (eval $ac_try) 2>&5
11046   ac_status=$?
11047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11048   (exit $ac_status); }; }; then
11049   ac_header_compiler=yes
11050 else
11051   echo "$as_me: failed program was:" >&5
11052 sed 's/^/| /' conftest.$ac_ext >&5
11053
11054 ac_header_compiler=no
11055 fi
11056 rm -f conftest.$ac_objext conftest.$ac_ext
11057 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11058 echo "${ECHO_T}$ac_header_compiler" >&6
11059
11060 # Is the header present?
11061 echo "$as_me:$LINENO: checking $ac_header presence" >&5
11062 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
11063 cat >conftest.$ac_ext <<_ACEOF
11064 #line $LINENO "configure"
11065 /* confdefs.h.  */
11066 _ACEOF
11067 cat confdefs.h >>conftest.$ac_ext
11068 cat >>conftest.$ac_ext <<_ACEOF
11069 /* end confdefs.h.  */
11070 #include <$ac_header>
11071 _ACEOF
11072 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11073   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11074   ac_status=$?
11075   grep -v '^ *+' conftest.er1 >conftest.err
11076   rm -f conftest.er1
11077   cat conftest.err >&5
11078   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11079   (exit $ac_status); } >/dev/null; then
11080   if test -s conftest.err; then
11081     ac_cpp_err=$ac_c_preproc_warn_flag
11082   else
11083     ac_cpp_err=
11084   fi
11085 else
11086   ac_cpp_err=yes
11087 fi
11088 if test -z "$ac_cpp_err"; then
11089   ac_header_preproc=yes
11090 else
11091   echo "$as_me: failed program was:" >&5
11092 sed 's/^/| /' conftest.$ac_ext >&5
11093
11094   ac_header_preproc=no
11095 fi
11096 rm -f conftest.err conftest.$ac_ext
11097 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11098 echo "${ECHO_T}$ac_header_preproc" >&6
11099
11100 # So?  What about this header?
11101 case $ac_header_compiler:$ac_header_preproc in
11102   yes:no )
11103     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11104 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11105     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11106 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11107     (
11108       cat <<\_ASBOX
11109 ## ------------------------------------ ##
11110 ## Report this to bug-autoconf@gnu.org. ##
11111 ## ------------------------------------ ##
11112 _ASBOX
11113     ) |
11114       sed "s/^/$as_me: WARNING:     /" >&2
11115     ;;
11116   no:yes )
11117     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11118 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11119     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11120 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11121     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11122 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11123     (
11124       cat <<\_ASBOX
11125 ## ------------------------------------ ##
11126 ## Report this to bug-autoconf@gnu.org. ##
11127 ## ------------------------------------ ##
11128 _ASBOX
11129     ) |
11130       sed "s/^/$as_me: WARNING:     /" >&2
11131     ;;
11132 esac
11133 echo "$as_me:$LINENO: checking for $ac_header" >&5
11134 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11135 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11136   echo $ECHO_N "(cached) $ECHO_C" >&6
11137 else
11138   eval "$as_ac_Header=$ac_header_preproc"
11139 fi
11140 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11141 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11142
11143 fi
11144 if test `eval echo '${'$as_ac_Header'}'` = yes; then
11145   cat >>confdefs.h <<_ACEOF
11146 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11147 _ACEOF
11148
11149 fi
11150
11151 done
11152
11153
11154
11155 for ac_header in sys/ucred.h
11156 do
11157 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11158 echo "$as_me:$LINENO: checking for $ac_header" >&5
11159 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11160 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11161   echo $ECHO_N "(cached) $ECHO_C" >&6
11162 else
11163   cat >conftest.$ac_ext <<_ACEOF
11164 #line $LINENO "configure"
11165 /* confdefs.h.  */
11166 _ACEOF
11167 cat confdefs.h >>conftest.$ac_ext
11168 cat >>conftest.$ac_ext <<_ACEOF
11169 /* end confdefs.h.  */
11170 #include <sys/types.h>
11171
11172 #include <$ac_header>
11173 _ACEOF
11174 rm -f conftest.$ac_objext
11175 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11176   (eval $ac_compile) 2>&5
11177   ac_status=$?
11178   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11179   (exit $ac_status); } &&
11180          { ac_try='test -s conftest.$ac_objext'
11181   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11182   (eval $ac_try) 2>&5
11183   ac_status=$?
11184   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11185   (exit $ac_status); }; }; then
11186   eval "$as_ac_Header=yes"
11187 else
11188   echo "$as_me: failed program was:" >&5
11189 sed 's/^/| /' conftest.$ac_ext >&5
11190
11191 eval "$as_ac_Header=no"
11192 fi
11193 rm -f conftest.$ac_objext conftest.$ac_ext
11194 fi
11195 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11196 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11197 if test `eval echo '${'$as_ac_Header'}'` = yes; then
11198   cat >>confdefs.h <<_ACEOF
11199 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11200 _ACEOF
11201
11202 fi
11203
11204 done
11205
11206
11207 for ac_header in resolv.h
11208 do
11209 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11210 echo "$as_me:$LINENO: checking for $ac_header" >&5
11211 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11212 if eval "test \"\${$as_ac_Header+set}\" = set"; then
11213   echo $ECHO_N "(cached) $ECHO_C" >&6
11214 else
11215   cat >conftest.$ac_ext <<_ACEOF
11216 #line $LINENO "configure"
11217 /* confdefs.h.  */
11218 _ACEOF
11219 cat confdefs.h >>conftest.$ac_ext
11220 cat >>conftest.$ac_ext <<_ACEOF
11221 /* end confdefs.h.  */
11222
11223 #include <sys/types.h>
11224 #include <netinet/in.h>
11225 #include <arpa/nameser.h>
11226
11227
11228 #include <$ac_header>
11229 _ACEOF
11230 rm -f conftest.$ac_objext
11231 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11232   (eval $ac_compile) 2>&5
11233   ac_status=$?
11234   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11235   (exit $ac_status); } &&
11236          { ac_try='test -s conftest.$ac_objext'
11237   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11238   (eval $ac_try) 2>&5
11239   ac_status=$?
11240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11241   (exit $ac_status); }; }; then
11242   eval "$as_ac_Header=yes"
11243 else
11244   echo "$as_me: failed program was:" >&5
11245 sed 's/^/| /' conftest.$ac_ext >&5
11246
11247 eval "$as_ac_Header=no"
11248 fi
11249 rm -f conftest.$ac_objext conftest.$ac_ext
11250 fi
11251 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11252 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11253 if test `eval echo '${'$as_ac_Header'}'` = yes; then
11254   cat >>confdefs.h <<_ACEOF
11255 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11256 _ACEOF
11257
11258 fi
11259
11260 done
11261
11262
11263
11264 echo "$as_me:$LINENO: checking for dlopen" >&5
11265 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6
11266 if test "${ac_cv_func_dlopen+set}" = set; then
11267   echo $ECHO_N "(cached) $ECHO_C" >&6
11268 else
11269   cat >conftest.$ac_ext <<_ACEOF
11270 #line $LINENO "configure"
11271 /* confdefs.h.  */
11272 _ACEOF
11273 cat confdefs.h >>conftest.$ac_ext
11274 cat >>conftest.$ac_ext <<_ACEOF
11275 /* end confdefs.h.  */
11276 /* System header to define __stub macros and hopefully few prototypes,
11277     which can conflict with char dlopen (); below.
11278     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11279     <limits.h> exists even on freestanding compilers.  */
11280 #ifdef __STDC__
11281 # include <limits.h>
11282 #else
11283 # include <assert.h>
11284 #endif
11285 /* Override any gcc2 internal prototype to avoid an error.  */
11286 #ifdef __cplusplus
11287 extern "C"
11288 {
11289 #endif
11290 /* We use char because int might match the return type of a gcc2
11291    builtin and then its argument prototype would still apply.  */
11292 char dlopen ();
11293 /* The GNU C library defines this for functions which it implements
11294     to always fail with ENOSYS.  Some functions are actually named
11295     something starting with __ and the normal name is an alias.  */
11296 #if defined (__stub_dlopen) || defined (__stub___dlopen)
11297 choke me
11298 #else
11299 char (*f) () = dlopen;
11300 #endif
11301 #ifdef __cplusplus
11302 }
11303 #endif
11304
11305 int
11306 main ()
11307 {
11308 return f != dlopen;
11309   ;
11310   return 0;
11311 }
11312 _ACEOF
11313 rm -f conftest.$ac_objext conftest$ac_exeext
11314 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11315   (eval $ac_link) 2>&5
11316   ac_status=$?
11317   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11318   (exit $ac_status); } &&
11319          { ac_try='test -s conftest$ac_exeext'
11320   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11321   (eval $ac_try) 2>&5
11322   ac_status=$?
11323   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11324   (exit $ac_status); }; }; then
11325   ac_cv_func_dlopen=yes
11326 else
11327   echo "$as_me: failed program was:" >&5
11328 sed 's/^/| /' conftest.$ac_ext >&5
11329
11330 ac_cv_func_dlopen=no
11331 fi
11332 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11333 fi
11334 echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
11335 echo "${ECHO_T}$ac_cv_func_dlopen" >&6
11336 if test $ac_cv_func_dlopen = yes; then
11337   :
11338 else
11339
11340 echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
11341 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
11342 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
11343   echo $ECHO_N "(cached) $ECHO_C" >&6
11344 else
11345   ac_check_lib_save_LIBS=$LIBS
11346 LIBS="-ldl  $LIBS"
11347 cat >conftest.$ac_ext <<_ACEOF
11348 #line $LINENO "configure"
11349 /* confdefs.h.  */
11350 _ACEOF
11351 cat confdefs.h >>conftest.$ac_ext
11352 cat >>conftest.$ac_ext <<_ACEOF
11353 /* end confdefs.h.  */
11354
11355 /* Override any gcc2 internal prototype to avoid an error.  */
11356 #ifdef __cplusplus
11357 extern "C"
11358 #endif
11359 /* We use char because int might match the return type of a gcc2
11360    builtin and then its argument prototype would still apply.  */
11361 char dlopen ();
11362 int
11363 main ()
11364 {
11365 dlopen ();
11366   ;
11367   return 0;
11368 }
11369 _ACEOF
11370 rm -f conftest.$ac_objext conftest$ac_exeext
11371 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11372   (eval $ac_link) 2>&5
11373   ac_status=$?
11374   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11375   (exit $ac_status); } &&
11376          { ac_try='test -s conftest$ac_exeext'
11377   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11378   (eval $ac_try) 2>&5
11379   ac_status=$?
11380   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11381   (exit $ac_status); }; }; then
11382   ac_cv_lib_dl_dlopen=yes
11383 else
11384   echo "$as_me: failed program was:" >&5
11385 sed 's/^/| /' conftest.$ac_ext >&5
11386
11387 ac_cv_lib_dl_dlopen=no
11388 fi
11389 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11390 LIBS=$ac_check_lib_save_LIBS
11391 fi
11392 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
11393 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
11394 if test $ac_cv_lib_dl_dlopen = yes; then
11395   cat >>confdefs.h <<_ACEOF
11396 #define HAVE_LIBDL 1
11397 _ACEOF
11398
11399   LIBS="-ldl $LIBS"
11400
11401 fi
11402
11403 fi
11404
11405
11406
11407 echo "$as_me:$LINENO: checking for sigset in -lV3" >&5
11408 echo $ECHO_N "checking for sigset in -lV3... $ECHO_C" >&6
11409 if test "${ac_cv_lib_V3_sigset+set}" = set; then
11410   echo $ECHO_N "(cached) $ECHO_C" >&6
11411 else
11412   ac_check_lib_save_LIBS=$LIBS
11413 LIBS="-lV3  $LIBS"
11414 cat >conftest.$ac_ext <<_ACEOF
11415 #line $LINENO "configure"
11416 /* confdefs.h.  */
11417 _ACEOF
11418 cat confdefs.h >>conftest.$ac_ext
11419 cat >>conftest.$ac_ext <<_ACEOF
11420 /* end confdefs.h.  */
11421
11422 /* Override any gcc2 internal prototype to avoid an error.  */
11423 #ifdef __cplusplus
11424 extern "C"
11425 #endif
11426 /* We use char because int might match the return type of a gcc2
11427    builtin and then its argument prototype would still apply.  */
11428 char sigset ();
11429 int
11430 main ()
11431 {
11432 sigset ();
11433   ;
11434   return 0;
11435 }
11436 _ACEOF
11437 rm -f conftest.$ac_objext conftest$ac_exeext
11438 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11439   (eval $ac_link) 2>&5
11440   ac_status=$?
11441   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11442   (exit $ac_status); } &&
11443          { ac_try='test -s conftest$ac_exeext'
11444   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11445   (eval $ac_try) 2>&5
11446   ac_status=$?
11447   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11448   (exit $ac_status); }; }; then
11449   ac_cv_lib_V3_sigset=yes
11450 else
11451   echo "$as_me: failed program was:" >&5
11452 sed 's/^/| /' conftest.$ac_ext >&5
11453
11454 ac_cv_lib_V3_sigset=no
11455 fi
11456 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11457 LIBS=$ac_check_lib_save_LIBS
11458 fi
11459 echo "$as_me:$LINENO: result: $ac_cv_lib_V3_sigset" >&5
11460 echo "${ECHO_T}$ac_cv_lib_V3_sigset" >&6
11461 if test $ac_cv_lib_V3_sigset = yes; then
11462   cat >>confdefs.h <<_ACEOF
11463 #define HAVE_LIBV3 1
11464 _ACEOF
11465
11466   LIBS="-lV3 $LIBS"
11467
11468 fi
11469
11470
11471 echo "$as_me:$LINENO: checking for winsock" >&5
11472 echo $ECHO_N "checking for winsock... $ECHO_C" >&6
11473 save_LIBS="$LIBS"
11474 for curlib in ws2_32 wsock32; do
11475         LIBS="$LIBS -l$curlib"
11476         cat >conftest.$ac_ext <<_ACEOF
11477 #line $LINENO "configure"
11478 /* confdefs.h.  */
11479 _ACEOF
11480 cat confdefs.h >>conftest.$ac_ext
11481 cat >>conftest.$ac_ext <<_ACEOF
11482 /* end confdefs.h.  */
11483
11484                         char socket@12();
11485                         char select@20();
11486                         char closesocket@4();
11487                         char gethostname@8();
11488
11489 int
11490 main ()
11491 {
11492
11493                         socket@12();
11494                         select@20();
11495                         closesocket@4();
11496                         gethostname@8();
11497
11498   ;
11499   return 0;
11500 }
11501 _ACEOF
11502 rm -f conftest.$ac_objext conftest$ac_exeext
11503 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11504   (eval $ac_link) 2>&5
11505   ac_status=$?
11506   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11507   (exit $ac_status); } &&
11508          { ac_try='test -s conftest$ac_exeext'
11509   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11510   (eval $ac_try) 2>&5
11511   ac_status=$?
11512   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11513   (exit $ac_status); }; }; then
11514   have_winsock=yes
11515 else
11516   echo "$as_me: failed program was:" >&5
11517 sed 's/^/| /' conftest.$ac_ext >&5
11518
11519 have_winsock=no
11520 fi
11521 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11522
11523         if test $have_winsock = yes; then
11524
11525 cat >>confdefs.h <<\_ACEOF
11526 #define HAVE_WINSOCK 1
11527 _ACEOF
11528
11529                 ac_cv_func_socket=yes
11530                 ac_cv_func_select=yes
11531                 ac_cv_func_closesocket=yes
11532                 ac_cv_func_gethostname=yes
11533                 if test $curlib = ws2_32; then
11534                         have_winsock=winsock2
11535
11536 cat >>confdefs.h <<\_ACEOF
11537 #define HAVE_WINSOCK2 1
11538 _ACEOF
11539
11540                 fi
11541                 break
11542         fi
11543         LIBS="$save_LIBS"
11544 done
11545 echo "$as_me:$LINENO: result: $have_winsock" >&5
11546 echo "${ECHO_T}$have_winsock" >&6
11547
11548
11549 echo "$as_me:$LINENO: checking for socket" >&5
11550 echo $ECHO_N "checking for socket... $ECHO_C" >&6
11551 if test "${ac_cv_func_socket+set}" = set; then
11552   echo $ECHO_N "(cached) $ECHO_C" >&6
11553 else
11554   cat >conftest.$ac_ext <<_ACEOF
11555 #line $LINENO "configure"
11556 /* confdefs.h.  */
11557 _ACEOF
11558 cat confdefs.h >>conftest.$ac_ext
11559 cat >>conftest.$ac_ext <<_ACEOF
11560 /* end confdefs.h.  */
11561 /* System header to define __stub macros and hopefully few prototypes,
11562     which can conflict with char socket (); below.
11563     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11564     <limits.h> exists even on freestanding compilers.  */
11565 #ifdef __STDC__
11566 # include <limits.h>
11567 #else
11568 # include <assert.h>
11569 #endif
11570 /* Override any gcc2 internal prototype to avoid an error.  */
11571 #ifdef __cplusplus
11572 extern "C"
11573 {
11574 #endif
11575 /* We use char because int might match the return type of a gcc2
11576    builtin and then its argument prototype would still apply.  */
11577 char socket ();
11578 /* The GNU C library defines this for functions which it implements
11579     to always fail with ENOSYS.  Some functions are actually named
11580     something starting with __ and the normal name is an alias.  */
11581 #if defined (__stub_socket) || defined (__stub___socket)
11582 choke me
11583 #else
11584 char (*f) () = socket;
11585 #endif
11586 #ifdef __cplusplus
11587 }
11588 #endif
11589
11590 int
11591 main ()
11592 {
11593 return f != socket;
11594   ;
11595   return 0;
11596 }
11597 _ACEOF
11598 rm -f conftest.$ac_objext conftest$ac_exeext
11599 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11600   (eval $ac_link) 2>&5
11601   ac_status=$?
11602   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11603   (exit $ac_status); } &&
11604          { ac_try='test -s conftest$ac_exeext'
11605   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11606   (eval $ac_try) 2>&5
11607   ac_status=$?
11608   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11609   (exit $ac_status); }; }; then
11610   ac_cv_func_socket=yes
11611 else
11612   echo "$as_me: failed program was:" >&5
11613 sed 's/^/| /' conftest.$ac_ext >&5
11614
11615 ac_cv_func_socket=no
11616 fi
11617 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11618 fi
11619 echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
11620 echo "${ECHO_T}$ac_cv_func_socket" >&6
11621 if test $ac_cv_func_socket = yes; then
11622   :
11623 else
11624
11625
11626 echo "$as_me:$LINENO: checking for main in -lsocket" >&5
11627 echo $ECHO_N "checking for main in -lsocket... $ECHO_C" >&6
11628 if test "${ac_cv_lib_socket_main+set}" = set; then
11629   echo $ECHO_N "(cached) $ECHO_C" >&6
11630 else
11631   ac_check_lib_save_LIBS=$LIBS
11632 LIBS="-lsocket  $LIBS"
11633 cat >conftest.$ac_ext <<_ACEOF
11634 #line $LINENO "configure"
11635 /* confdefs.h.  */
11636 _ACEOF
11637 cat confdefs.h >>conftest.$ac_ext
11638 cat >>conftest.$ac_ext <<_ACEOF
11639 /* end confdefs.h.  */
11640
11641
11642 int
11643 main ()
11644 {
11645 main ();
11646   ;
11647   return 0;
11648 }
11649 _ACEOF
11650 rm -f conftest.$ac_objext conftest$ac_exeext
11651 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11652   (eval $ac_link) 2>&5
11653   ac_status=$?
11654   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11655   (exit $ac_status); } &&
11656          { ac_try='test -s conftest$ac_exeext'
11657   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11658   (eval $ac_try) 2>&5
11659   ac_status=$?
11660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11661   (exit $ac_status); }; }; then
11662   ac_cv_lib_socket_main=yes
11663 else
11664   echo "$as_me: failed program was:" >&5
11665 sed 's/^/| /' conftest.$ac_ext >&5
11666
11667 ac_cv_lib_socket_main=no
11668 fi
11669 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11670 LIBS=$ac_check_lib_save_LIBS
11671 fi
11672 echo "$as_me:$LINENO: result: $ac_cv_lib_socket_main" >&5
11673 echo "${ECHO_T}$ac_cv_lib_socket_main" >&6
11674 if test $ac_cv_lib_socket_main = yes; then
11675   cat >>confdefs.h <<_ACEOF
11676 #define HAVE_LIBSOCKET 1
11677 _ACEOF
11678
11679   LIBS="-lsocket $LIBS"
11680
11681 fi
11682
11683
11684 echo "$as_me:$LINENO: checking for main in -lnet" >&5
11685 echo $ECHO_N "checking for main in -lnet... $ECHO_C" >&6
11686 if test "${ac_cv_lib_net_main+set}" = set; then
11687   echo $ECHO_N "(cached) $ECHO_C" >&6
11688 else
11689   ac_check_lib_save_LIBS=$LIBS
11690 LIBS="-lnet  $LIBS"
11691 cat >conftest.$ac_ext <<_ACEOF
11692 #line $LINENO "configure"
11693 /* confdefs.h.  */
11694 _ACEOF
11695 cat confdefs.h >>conftest.$ac_ext
11696 cat >>conftest.$ac_ext <<_ACEOF
11697 /* end confdefs.h.  */
11698
11699
11700 int
11701 main ()
11702 {
11703 main ();
11704   ;
11705   return 0;
11706 }
11707 _ACEOF
11708 rm -f conftest.$ac_objext conftest$ac_exeext
11709 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11710   (eval $ac_link) 2>&5
11711   ac_status=$?
11712   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11713   (exit $ac_status); } &&
11714          { ac_try='test -s conftest$ac_exeext'
11715   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11716   (eval $ac_try) 2>&5
11717   ac_status=$?
11718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11719   (exit $ac_status); }; }; then
11720   ac_cv_lib_net_main=yes
11721 else
11722   echo "$as_me: failed program was:" >&5
11723 sed 's/^/| /' conftest.$ac_ext >&5
11724
11725 ac_cv_lib_net_main=no
11726 fi
11727 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11728 LIBS=$ac_check_lib_save_LIBS
11729 fi
11730 echo "$as_me:$LINENO: result: $ac_cv_lib_net_main" >&5
11731 echo "${ECHO_T}$ac_cv_lib_net_main" >&6
11732 if test $ac_cv_lib_net_main = yes; then
11733   cat >>confdefs.h <<_ACEOF
11734 #define HAVE_LIBNET 1
11735 _ACEOF
11736
11737   LIBS="-lnet $LIBS"
11738
11739 fi
11740
11741
11742 echo "$as_me:$LINENO: checking for main in -lnsl_s" >&5
11743 echo $ECHO_N "checking for main in -lnsl_s... $ECHO_C" >&6
11744 if test "${ac_cv_lib_nsl_s_main+set}" = set; then
11745   echo $ECHO_N "(cached) $ECHO_C" >&6
11746 else
11747   ac_check_lib_save_LIBS=$LIBS
11748 LIBS="-lnsl_s  $LIBS"
11749 cat >conftest.$ac_ext <<_ACEOF
11750 #line $LINENO "configure"
11751 /* confdefs.h.  */
11752 _ACEOF
11753 cat confdefs.h >>conftest.$ac_ext
11754 cat >>conftest.$ac_ext <<_ACEOF
11755 /* end confdefs.h.  */
11756
11757
11758 int
11759 main ()
11760 {
11761 main ();
11762   ;
11763   return 0;
11764 }
11765 _ACEOF
11766 rm -f conftest.$ac_objext conftest$ac_exeext
11767 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11768   (eval $ac_link) 2>&5
11769   ac_status=$?
11770   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11771   (exit $ac_status); } &&
11772          { ac_try='test -s conftest$ac_exeext'
11773   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11774   (eval $ac_try) 2>&5
11775   ac_status=$?
11776   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11777   (exit $ac_status); }; }; then
11778   ac_cv_lib_nsl_s_main=yes
11779 else
11780   echo "$as_me: failed program was:" >&5
11781 sed 's/^/| /' conftest.$ac_ext >&5
11782
11783 ac_cv_lib_nsl_s_main=no
11784 fi
11785 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11786 LIBS=$ac_check_lib_save_LIBS
11787 fi
11788 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_s_main" >&5
11789 echo "${ECHO_T}$ac_cv_lib_nsl_s_main" >&6
11790 if test $ac_cv_lib_nsl_s_main = yes; then
11791   cat >>confdefs.h <<_ACEOF
11792 #define HAVE_LIBNSL_S 1
11793 _ACEOF
11794
11795   LIBS="-lnsl_s $LIBS"
11796
11797 fi
11798
11799
11800 echo "$as_me:$LINENO: checking for main in -lnsl" >&5
11801 echo $ECHO_N "checking for main in -lnsl... $ECHO_C" >&6
11802 if test "${ac_cv_lib_nsl_main+set}" = set; then
11803   echo $ECHO_N "(cached) $ECHO_C" >&6
11804 else
11805   ac_check_lib_save_LIBS=$LIBS
11806 LIBS="-lnsl  $LIBS"
11807 cat >conftest.$ac_ext <<_ACEOF
11808 #line $LINENO "configure"
11809 /* confdefs.h.  */
11810 _ACEOF
11811 cat confdefs.h >>conftest.$ac_ext
11812 cat >>conftest.$ac_ext <<_ACEOF
11813 /* end confdefs.h.  */
11814
11815
11816 int
11817 main ()
11818 {
11819 main ();
11820   ;
11821   return 0;
11822 }
11823 _ACEOF
11824 rm -f conftest.$ac_objext conftest$ac_exeext
11825 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11826   (eval $ac_link) 2>&5
11827   ac_status=$?
11828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11829   (exit $ac_status); } &&
11830          { ac_try='test -s conftest$ac_exeext'
11831   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11832   (eval $ac_try) 2>&5
11833   ac_status=$?
11834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11835   (exit $ac_status); }; }; then
11836   ac_cv_lib_nsl_main=yes
11837 else
11838   echo "$as_me: failed program was:" >&5
11839 sed 's/^/| /' conftest.$ac_ext >&5
11840
11841 ac_cv_lib_nsl_main=no
11842 fi
11843 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11844 LIBS=$ac_check_lib_save_LIBS
11845 fi
11846 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_main" >&5
11847 echo "${ECHO_T}$ac_cv_lib_nsl_main" >&6
11848 if test $ac_cv_lib_nsl_main = yes; then
11849   cat >>confdefs.h <<_ACEOF
11850 #define HAVE_LIBNSL 1
11851 _ACEOF
11852
11853   LIBS="-lnsl $LIBS"
11854
11855 fi
11856
11857
11858 echo "$as_me:$LINENO: checking for socket in -linet" >&5
11859 echo $ECHO_N "checking for socket in -linet... $ECHO_C" >&6
11860 if test "${ac_cv_lib_inet_socket+set}" = set; then
11861   echo $ECHO_N "(cached) $ECHO_C" >&6
11862 else
11863   ac_check_lib_save_LIBS=$LIBS
11864 LIBS="-linet  $LIBS"
11865 cat >conftest.$ac_ext <<_ACEOF
11866 #line $LINENO "configure"
11867 /* confdefs.h.  */
11868 _ACEOF
11869 cat confdefs.h >>conftest.$ac_ext
11870 cat >>conftest.$ac_ext <<_ACEOF
11871 /* end confdefs.h.  */
11872
11873 /* Override any gcc2 internal prototype to avoid an error.  */
11874 #ifdef __cplusplus
11875 extern "C"
11876 #endif
11877 /* We use char because int might match the return type of a gcc2
11878    builtin and then its argument prototype would still apply.  */
11879 char socket ();
11880 int
11881 main ()
11882 {
11883 socket ();
11884   ;
11885   return 0;
11886 }
11887 _ACEOF
11888 rm -f conftest.$ac_objext conftest$ac_exeext
11889 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11890   (eval $ac_link) 2>&5
11891   ac_status=$?
11892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11893   (exit $ac_status); } &&
11894          { ac_try='test -s conftest$ac_exeext'
11895   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11896   (eval $ac_try) 2>&5
11897   ac_status=$?
11898   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11899   (exit $ac_status); }; }; then
11900   ac_cv_lib_inet_socket=yes
11901 else
11902   echo "$as_me: failed program was:" >&5
11903 sed 's/^/| /' conftest.$ac_ext >&5
11904
11905 ac_cv_lib_inet_socket=no
11906 fi
11907 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11908 LIBS=$ac_check_lib_save_LIBS
11909 fi
11910 echo "$as_me:$LINENO: result: $ac_cv_lib_inet_socket" >&5
11911 echo "${ECHO_T}$ac_cv_lib_inet_socket" >&6
11912 if test $ac_cv_lib_inet_socket = yes; then
11913   cat >>confdefs.h <<_ACEOF
11914 #define HAVE_LIBINET 1
11915 _ACEOF
11916
11917   LIBS="-linet $LIBS"
11918
11919 fi
11920
11921
11922 echo "$as_me:$LINENO: checking for main in -lgen" >&5
11923 echo $ECHO_N "checking for main in -lgen... $ECHO_C" >&6
11924 if test "${ac_cv_lib_gen_main+set}" = set; then
11925   echo $ECHO_N "(cached) $ECHO_C" >&6
11926 else
11927   ac_check_lib_save_LIBS=$LIBS
11928 LIBS="-lgen  $LIBS"
11929 cat >conftest.$ac_ext <<_ACEOF
11930 #line $LINENO "configure"
11931 /* confdefs.h.  */
11932 _ACEOF
11933 cat confdefs.h >>conftest.$ac_ext
11934 cat >>conftest.$ac_ext <<_ACEOF
11935 /* end confdefs.h.  */
11936
11937
11938 int
11939 main ()
11940 {
11941 main ();
11942   ;
11943   return 0;
11944 }
11945 _ACEOF
11946 rm -f conftest.$ac_objext conftest$ac_exeext
11947 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11948   (eval $ac_link) 2>&5
11949   ac_status=$?
11950   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11951   (exit $ac_status); } &&
11952          { ac_try='test -s conftest$ac_exeext'
11953   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11954   (eval $ac_try) 2>&5
11955   ac_status=$?
11956   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11957   (exit $ac_status); }; }; then
11958   ac_cv_lib_gen_main=yes
11959 else
11960   echo "$as_me: failed program was:" >&5
11961 sed 's/^/| /' conftest.$ac_ext >&5
11962
11963 ac_cv_lib_gen_main=no
11964 fi
11965 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11966 LIBS=$ac_check_lib_save_LIBS
11967 fi
11968 echo "$as_me:$LINENO: result: $ac_cv_lib_gen_main" >&5
11969 echo "${ECHO_T}$ac_cv_lib_gen_main" >&6
11970 if test $ac_cv_lib_gen_main = yes; then
11971   cat >>confdefs.h <<_ACEOF
11972 #define HAVE_LIBGEN 1
11973 _ACEOF
11974
11975   LIBS="-lgen $LIBS"
11976
11977 fi
11978
11979
11980 fi
11981
11982
11983 echo "$as_me:$LINENO: checking for select" >&5
11984 echo $ECHO_N "checking for select... $ECHO_C" >&6
11985 if test "${ac_cv_func_select+set}" = set; then
11986   echo $ECHO_N "(cached) $ECHO_C" >&6
11987 else
11988   cat >conftest.$ac_ext <<_ACEOF
11989 #line $LINENO "configure"
11990 /* confdefs.h.  */
11991 _ACEOF
11992 cat confdefs.h >>conftest.$ac_ext
11993 cat >>conftest.$ac_ext <<_ACEOF
11994 /* end confdefs.h.  */
11995 /* System header to define __stub macros and hopefully few prototypes,
11996     which can conflict with char select (); below.
11997     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11998     <limits.h> exists even on freestanding compilers.  */
11999 #ifdef __STDC__
12000 # include <limits.h>
12001 #else
12002 # include <assert.h>
12003 #endif
12004 /* Override any gcc2 internal prototype to avoid an error.  */
12005 #ifdef __cplusplus
12006 extern "C"
12007 {
12008 #endif
12009 /* We use char because int might match the return type of a gcc2
12010    builtin and then its argument prototype would still apply.  */
12011 char select ();
12012 /* The GNU C library defines this for functions which it implements
12013     to always fail with ENOSYS.  Some functions are actually named
12014     something starting with __ and the normal name is an alias.  */
12015 #if defined (__stub_select) || defined (__stub___select)
12016 choke me
12017 #else
12018 char (*f) () = select;
12019 #endif
12020 #ifdef __cplusplus
12021 }
12022 #endif
12023
12024 int
12025 main ()
12026 {
12027 return f != select;
12028   ;
12029   return 0;
12030 }
12031 _ACEOF
12032 rm -f conftest.$ac_objext conftest$ac_exeext
12033 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12034   (eval $ac_link) 2>&5
12035   ac_status=$?
12036   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12037   (exit $ac_status); } &&
12038          { ac_try='test -s conftest$ac_exeext'
12039   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12040   (eval $ac_try) 2>&5
12041   ac_status=$?
12042   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12043   (exit $ac_status); }; }; then
12044   ac_cv_func_select=yes
12045 else
12046   echo "$as_me: failed program was:" >&5
12047 sed 's/^/| /' conftest.$ac_ext >&5
12048
12049 ac_cv_func_select=no
12050 fi
12051 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12052 fi
12053 echo "$as_me:$LINENO: result: $ac_cv_func_select" >&5
12054 echo "${ECHO_T}$ac_cv_func_select" >&6
12055 if test $ac_cv_func_select = yes; then
12056   :
12057 else
12058   { { echo "$as_me:$LINENO: error: select() required." >&5
12059 echo "$as_me: error: select() required." >&2;}
12060    { (exit 1); exit 1; }; }
12061 fi
12062
12063
12064 if test "${ac_cv_header_winsock_h}" != yes; then
12065
12066
12067 for ac_header in sys/select.h sys/socket.h
12068 do
12069 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12070 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12071   echo "$as_me:$LINENO: checking for $ac_header" >&5
12072 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12073 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12074   echo $ECHO_N "(cached) $ECHO_C" >&6
12075 fi
12076 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12077 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12078 else
12079   # Is the header compilable?
12080 echo "$as_me:$LINENO: checking $ac_header usability" >&5
12081 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
12082 cat >conftest.$ac_ext <<_ACEOF
12083 #line $LINENO "configure"
12084 /* confdefs.h.  */
12085 _ACEOF
12086 cat confdefs.h >>conftest.$ac_ext
12087 cat >>conftest.$ac_ext <<_ACEOF
12088 /* end confdefs.h.  */
12089 $ac_includes_default
12090 #include <$ac_header>
12091 _ACEOF
12092 rm -f conftest.$ac_objext
12093 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12094   (eval $ac_compile) 2>&5
12095   ac_status=$?
12096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12097   (exit $ac_status); } &&
12098          { ac_try='test -s conftest.$ac_objext'
12099   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12100   (eval $ac_try) 2>&5
12101   ac_status=$?
12102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12103   (exit $ac_status); }; }; then
12104   ac_header_compiler=yes
12105 else
12106   echo "$as_me: failed program was:" >&5
12107 sed 's/^/| /' conftest.$ac_ext >&5
12108
12109 ac_header_compiler=no
12110 fi
12111 rm -f conftest.$ac_objext conftest.$ac_ext
12112 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12113 echo "${ECHO_T}$ac_header_compiler" >&6
12114
12115 # Is the header present?
12116 echo "$as_me:$LINENO: checking $ac_header presence" >&5
12117 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
12118 cat >conftest.$ac_ext <<_ACEOF
12119 #line $LINENO "configure"
12120 /* confdefs.h.  */
12121 _ACEOF
12122 cat confdefs.h >>conftest.$ac_ext
12123 cat >>conftest.$ac_ext <<_ACEOF
12124 /* end confdefs.h.  */
12125 #include <$ac_header>
12126 _ACEOF
12127 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
12128   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12129   ac_status=$?
12130   grep -v '^ *+' conftest.er1 >conftest.err
12131   rm -f conftest.er1
12132   cat conftest.err >&5
12133   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12134   (exit $ac_status); } >/dev/null; then
12135   if test -s conftest.err; then
12136     ac_cpp_err=$ac_c_preproc_warn_flag
12137   else
12138     ac_cpp_err=
12139   fi
12140 else
12141   ac_cpp_err=yes
12142 fi
12143 if test -z "$ac_cpp_err"; then
12144   ac_header_preproc=yes
12145 else
12146   echo "$as_me: failed program was:" >&5
12147 sed 's/^/| /' conftest.$ac_ext >&5
12148
12149   ac_header_preproc=no
12150 fi
12151 rm -f conftest.err conftest.$ac_ext
12152 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12153 echo "${ECHO_T}$ac_header_preproc" >&6
12154
12155 # So?  What about this header?
12156 case $ac_header_compiler:$ac_header_preproc in
12157   yes:no )
12158     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12159 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12160     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12161 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12162     (
12163       cat <<\_ASBOX
12164 ## ------------------------------------ ##
12165 ## Report this to bug-autoconf@gnu.org. ##
12166 ## ------------------------------------ ##
12167 _ASBOX
12168     ) |
12169       sed "s/^/$as_me: WARNING:     /" >&2
12170     ;;
12171   no:yes )
12172     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12173 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12174     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
12175 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
12176     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12177 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12178     (
12179       cat <<\_ASBOX
12180 ## ------------------------------------ ##
12181 ## Report this to bug-autoconf@gnu.org. ##
12182 ## ------------------------------------ ##
12183 _ASBOX
12184     ) |
12185       sed "s/^/$as_me: WARNING:     /" >&2
12186     ;;
12187 esac
12188 echo "$as_me:$LINENO: checking for $ac_header" >&5
12189 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12190 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12191   echo $ECHO_N "(cached) $ECHO_C" >&6
12192 else
12193   eval "$as_ac_Header=$ac_header_preproc"
12194 fi
12195 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12196 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12197
12198 fi
12199 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12200   cat >>confdefs.h <<_ACEOF
12201 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12202 _ACEOF
12203
12204 fi
12205
12206 done
12207
12208 echo "$as_me:$LINENO: checking types of arguments for select" >&5
12209 echo $ECHO_N "checking types of arguments for select... $ECHO_C" >&6
12210 if test "${ac_cv_func_select_args+set}" = set; then
12211   echo $ECHO_N "(cached) $ECHO_C" >&6
12212 else
12213   for ac_arg234 in 'fd_set *' 'int *' 'void *'; do
12214  for ac_arg1 in 'int' 'size_t' 'unsigned long' 'unsigned'; do
12215   for ac_arg5 in 'struct timeval *' 'const struct timeval *'; do
12216    cat >conftest.$ac_ext <<_ACEOF
12217 #line $LINENO "configure"
12218 /* confdefs.h.  */
12219 _ACEOF
12220 cat confdefs.h >>conftest.$ac_ext
12221 cat >>conftest.$ac_ext <<_ACEOF
12222 /* end confdefs.h.  */
12223 $ac_includes_default
12224 #if HAVE_SYS_SELECT_H
12225 # include <sys/select.h>
12226 #endif
12227 #if HAVE_SYS_SOCKET_H
12228 # include <sys/socket.h>
12229 #endif
12230
12231 int
12232 main ()
12233 {
12234 extern int select ($ac_arg1,
12235                                             $ac_arg234, $ac_arg234, $ac_arg234,
12236                                             $ac_arg5);
12237   ;
12238   return 0;
12239 }
12240 _ACEOF
12241 rm -f conftest.$ac_objext
12242 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12243   (eval $ac_compile) 2>&5
12244   ac_status=$?
12245   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12246   (exit $ac_status); } &&
12247          { ac_try='test -s conftest.$ac_objext'
12248   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12249   (eval $ac_try) 2>&5
12250   ac_status=$?
12251   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12252   (exit $ac_status); }; }; then
12253   ac_cv_func_select_args="$ac_arg1,$ac_arg234,$ac_arg5"; break 3
12254 else
12255   echo "$as_me: failed program was:" >&5
12256 sed 's/^/| /' conftest.$ac_ext >&5
12257
12258 fi
12259 rm -f conftest.$ac_objext conftest.$ac_ext
12260   done
12261  done
12262 done
12263 # Provide a safe default value.
12264 : ${ac_cv_func_select_args='int,int *,struct timeval *'}
12265
12266 fi
12267 echo "$as_me:$LINENO: result: $ac_cv_func_select_args" >&5
12268 echo "${ECHO_T}$ac_cv_func_select_args" >&6
12269 ac_save_IFS=$IFS; IFS=','
12270 set dummy `echo "$ac_cv_func_select_args" | sed 's/\*/\*/g'`
12271 IFS=$ac_save_IFS
12272 shift
12273
12274 cat >>confdefs.h <<_ACEOF
12275 #define SELECT_TYPE_ARG1 $1
12276 _ACEOF
12277
12278
12279 cat >>confdefs.h <<_ACEOF
12280 #define SELECT_TYPE_ARG234 ($2)
12281 _ACEOF
12282
12283
12284 cat >>confdefs.h <<_ACEOF
12285 #define SELECT_TYPE_ARG5 ($3)
12286 _ACEOF
12287
12288 rm -f conftest*
12289
12290 fi
12291
12292
12293
12294 for ac_header in regex.h
12295 do
12296 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12297 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12298   echo "$as_me:$LINENO: checking for $ac_header" >&5
12299 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12300 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12301   echo $ECHO_N "(cached) $ECHO_C" >&6
12302 fi
12303 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12304 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12305 else
12306   # Is the header compilable?
12307 echo "$as_me:$LINENO: checking $ac_header usability" >&5
12308 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
12309 cat >conftest.$ac_ext <<_ACEOF
12310 #line $LINENO "configure"
12311 /* confdefs.h.  */
12312 _ACEOF
12313 cat confdefs.h >>conftest.$ac_ext
12314 cat >>conftest.$ac_ext <<_ACEOF
12315 /* end confdefs.h.  */
12316 $ac_includes_default
12317 #include <$ac_header>
12318 _ACEOF
12319 rm -f conftest.$ac_objext
12320 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12321   (eval $ac_compile) 2>&5
12322   ac_status=$?
12323   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12324   (exit $ac_status); } &&
12325          { ac_try='test -s conftest.$ac_objext'
12326   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12327   (eval $ac_try) 2>&5
12328   ac_status=$?
12329   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12330   (exit $ac_status); }; }; then
12331   ac_header_compiler=yes
12332 else
12333   echo "$as_me: failed program was:" >&5
12334 sed 's/^/| /' conftest.$ac_ext >&5
12335
12336 ac_header_compiler=no
12337 fi
12338 rm -f conftest.$ac_objext conftest.$ac_ext
12339 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12340 echo "${ECHO_T}$ac_header_compiler" >&6
12341
12342 # Is the header present?
12343 echo "$as_me:$LINENO: checking $ac_header presence" >&5
12344 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
12345 cat >conftest.$ac_ext <<_ACEOF
12346 #line $LINENO "configure"
12347 /* confdefs.h.  */
12348 _ACEOF
12349 cat confdefs.h >>conftest.$ac_ext
12350 cat >>conftest.$ac_ext <<_ACEOF
12351 /* end confdefs.h.  */
12352 #include <$ac_header>
12353 _ACEOF
12354 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
12355   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12356   ac_status=$?
12357   grep -v '^ *+' conftest.er1 >conftest.err
12358   rm -f conftest.er1
12359   cat conftest.err >&5
12360   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12361   (exit $ac_status); } >/dev/null; then
12362   if test -s conftest.err; then
12363     ac_cpp_err=$ac_c_preproc_warn_flag
12364   else
12365     ac_cpp_err=
12366   fi
12367 else
12368   ac_cpp_err=yes
12369 fi
12370 if test -z "$ac_cpp_err"; then
12371   ac_header_preproc=yes
12372 else
12373   echo "$as_me: failed program was:" >&5
12374 sed 's/^/| /' conftest.$ac_ext >&5
12375
12376   ac_header_preproc=no
12377 fi
12378 rm -f conftest.err conftest.$ac_ext
12379 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12380 echo "${ECHO_T}$ac_header_preproc" >&6
12381
12382 # So?  What about this header?
12383 case $ac_header_compiler:$ac_header_preproc in
12384   yes:no )
12385     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12386 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12387     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12388 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12389     (
12390       cat <<\_ASBOX
12391 ## ------------------------------------ ##
12392 ## Report this to bug-autoconf@gnu.org. ##
12393 ## ------------------------------------ ##
12394 _ASBOX
12395     ) |
12396       sed "s/^/$as_me: WARNING:     /" >&2
12397     ;;
12398   no:yes )
12399     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12400 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12401     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
12402 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
12403     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12404 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12405     (
12406       cat <<\_ASBOX
12407 ## ------------------------------------ ##
12408 ## Report this to bug-autoconf@gnu.org. ##
12409 ## ------------------------------------ ##
12410 _ASBOX
12411     ) |
12412       sed "s/^/$as_me: WARNING:     /" >&2
12413     ;;
12414 esac
12415 echo "$as_me:$LINENO: checking for $ac_header" >&5
12416 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12417 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12418   echo $ECHO_N "(cached) $ECHO_C" >&6
12419 else
12420   eval "$as_ac_Header=$ac_header_preproc"
12421 fi
12422 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12423 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12424
12425 fi
12426 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12427   cat >>confdefs.h <<_ACEOF
12428 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12429 _ACEOF
12430
12431 fi
12432
12433 done
12434
12435 if test "$ac_cv_header_regex_h" != yes ; then
12436         { { echo "$as_me:$LINENO: error: POSIX regex.h required." >&5
12437 echo "$as_me: error: POSIX regex.h required." >&2;}
12438    { (exit 1); exit 1; }; }
12439 fi
12440 echo "$as_me:$LINENO: checking for library containing regfree" >&5
12441 echo $ECHO_N "checking for library containing regfree... $ECHO_C" >&6
12442 if test "${ac_cv_search_regfree+set}" = set; then
12443   echo $ECHO_N "(cached) $ECHO_C" >&6
12444 else
12445   ac_func_search_save_LIBS=$LIBS
12446 ac_cv_search_regfree=no
12447 cat >conftest.$ac_ext <<_ACEOF
12448 #line $LINENO "configure"
12449 /* confdefs.h.  */
12450 _ACEOF
12451 cat confdefs.h >>conftest.$ac_ext
12452 cat >>conftest.$ac_ext <<_ACEOF
12453 /* end confdefs.h.  */
12454
12455 /* Override any gcc2 internal prototype to avoid an error.  */
12456 #ifdef __cplusplus
12457 extern "C"
12458 #endif
12459 /* We use char because int might match the return type of a gcc2
12460    builtin and then its argument prototype would still apply.  */
12461 char regfree ();
12462 int
12463 main ()
12464 {
12465 regfree ();
12466   ;
12467   return 0;
12468 }
12469 _ACEOF
12470 rm -f conftest.$ac_objext conftest$ac_exeext
12471 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12472   (eval $ac_link) 2>&5
12473   ac_status=$?
12474   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12475   (exit $ac_status); } &&
12476          { ac_try='test -s conftest$ac_exeext'
12477   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12478   (eval $ac_try) 2>&5
12479   ac_status=$?
12480   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12481   (exit $ac_status); }; }; then
12482   ac_cv_search_regfree="none required"
12483 else
12484   echo "$as_me: failed program was:" >&5
12485 sed 's/^/| /' conftest.$ac_ext >&5
12486
12487 fi
12488 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12489 if test "$ac_cv_search_regfree" = no; then
12490   for ac_lib in regex gnuregex; do
12491     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
12492     cat >conftest.$ac_ext <<_ACEOF
12493 #line $LINENO "configure"
12494 /* confdefs.h.  */
12495 _ACEOF
12496 cat confdefs.h >>conftest.$ac_ext
12497 cat >>conftest.$ac_ext <<_ACEOF
12498 /* end confdefs.h.  */
12499
12500 /* Override any gcc2 internal prototype to avoid an error.  */
12501 #ifdef __cplusplus
12502 extern "C"
12503 #endif
12504 /* We use char because int might match the return type of a gcc2
12505    builtin and then its argument prototype would still apply.  */
12506 char regfree ();
12507 int
12508 main ()
12509 {
12510 regfree ();
12511   ;
12512   return 0;
12513 }
12514 _ACEOF
12515 rm -f conftest.$ac_objext conftest$ac_exeext
12516 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12517   (eval $ac_link) 2>&5
12518   ac_status=$?
12519   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12520   (exit $ac_status); } &&
12521          { ac_try='test -s conftest$ac_exeext'
12522   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12523   (eval $ac_try) 2>&5
12524   ac_status=$?
12525   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12526   (exit $ac_status); }; }; then
12527   ac_cv_search_regfree="-l$ac_lib"
12528 break
12529 else
12530   echo "$as_me: failed program was:" >&5
12531 sed 's/^/| /' conftest.$ac_ext >&5
12532
12533 fi
12534 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12535   done
12536 fi
12537 LIBS=$ac_func_search_save_LIBS
12538 fi
12539 echo "$as_me:$LINENO: result: $ac_cv_search_regfree" >&5
12540 echo "${ECHO_T}$ac_cv_search_regfree" >&6
12541 if test "$ac_cv_search_regfree" != no; then
12542   test "$ac_cv_search_regfree" = "none required" || LIBS="$ac_cv_search_regfree $LIBS"
12543   :
12544 else
12545   { { echo "$as_me:$LINENO: error: POSIX regex required." >&5
12546 echo "$as_me: error: POSIX regex required." >&2;}
12547    { (exit 1); exit 1; }; }
12548 fi
12549
12550
12551
12552 echo "$as_me:$LINENO: checking for compatible POSIX regex" >&5
12553 echo $ECHO_N "checking for compatible POSIX regex... $ECHO_C" >&6
12554 if test "${ol_cv_c_posix_regex+set}" = set; then
12555   echo $ECHO_N "(cached) $ECHO_C" >&6
12556 else
12557
12558         if test "$cross_compiling" = yes; then
12559   ol_cv_c_posix_regex=cross
12560 else
12561   cat >conftest.$ac_ext <<_ACEOF
12562 #line $LINENO "configure"
12563 /* confdefs.h.  */
12564 _ACEOF
12565 cat confdefs.h >>conftest.$ac_ext
12566 cat >>conftest.$ac_ext <<_ACEOF
12567 /* end confdefs.h.  */
12568
12569 #include <sys/types.h>
12570 #include <regex.h>
12571 static char *pattern, *string;
12572 main()
12573 {
12574         int rc;
12575         regex_t re;
12576
12577         pattern = "^A";
12578
12579         if(regcomp(&re, pattern, 0)) {
12580                 return -1;
12581         }
12582
12583         string = "ALL MATCH";
12584
12585         rc = regexec(&re, string, 0, (void*)0, 0);
12586
12587         regfree(&re);
12588
12589         return rc;
12590 }
12591 _ACEOF
12592 rm -f conftest$ac_exeext
12593 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12594   (eval $ac_link) 2>&5
12595   ac_status=$?
12596   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12597   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12598   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12599   (eval $ac_try) 2>&5
12600   ac_status=$?
12601   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12602   (exit $ac_status); }; }; then
12603   ol_cv_c_posix_regex=yes
12604 else
12605   echo "$as_me: program exited with status $ac_status" >&5
12606 echo "$as_me: failed program was:" >&5
12607 sed 's/^/| /' conftest.$ac_ext >&5
12608
12609 ( exit $ac_status )
12610 ol_cv_c_posix_regex=no
12611 fi
12612 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12613 fi
12614 fi
12615 echo "$as_me:$LINENO: result: $ol_cv_c_posix_regex" >&5
12616 echo "${ECHO_T}$ol_cv_c_posix_regex" >&6
12617
12618 if test "$ol_cv_c_posix_regex" = no ; then
12619         { { echo "$as_me:$LINENO: error: broken POSIX regex!" >&5
12620 echo "$as_me: error: broken POSIX regex!" >&2;}
12621    { (exit 1); exit 1; }; }
12622 fi
12623
12624
12625 have_uuid=no
12626
12627 for ac_header in sys/uuid.h
12628 do
12629 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12630 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12631   echo "$as_me:$LINENO: checking for $ac_header" >&5
12632 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12633 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12634   echo $ECHO_N "(cached) $ECHO_C" >&6
12635 fi
12636 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12637 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12638 else
12639   # Is the header compilable?
12640 echo "$as_me:$LINENO: checking $ac_header usability" >&5
12641 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
12642 cat >conftest.$ac_ext <<_ACEOF
12643 #line $LINENO "configure"
12644 /* confdefs.h.  */
12645 _ACEOF
12646 cat confdefs.h >>conftest.$ac_ext
12647 cat >>conftest.$ac_ext <<_ACEOF
12648 /* end confdefs.h.  */
12649 $ac_includes_default
12650 #include <$ac_header>
12651 _ACEOF
12652 rm -f conftest.$ac_objext
12653 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12654   (eval $ac_compile) 2>&5
12655   ac_status=$?
12656   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12657   (exit $ac_status); } &&
12658          { ac_try='test -s conftest.$ac_objext'
12659   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12660   (eval $ac_try) 2>&5
12661   ac_status=$?
12662   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12663   (exit $ac_status); }; }; then
12664   ac_header_compiler=yes
12665 else
12666   echo "$as_me: failed program was:" >&5
12667 sed 's/^/| /' conftest.$ac_ext >&5
12668
12669 ac_header_compiler=no
12670 fi
12671 rm -f conftest.$ac_objext conftest.$ac_ext
12672 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12673 echo "${ECHO_T}$ac_header_compiler" >&6
12674
12675 # Is the header present?
12676 echo "$as_me:$LINENO: checking $ac_header presence" >&5
12677 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
12678 cat >conftest.$ac_ext <<_ACEOF
12679 #line $LINENO "configure"
12680 /* confdefs.h.  */
12681 _ACEOF
12682 cat confdefs.h >>conftest.$ac_ext
12683 cat >>conftest.$ac_ext <<_ACEOF
12684 /* end confdefs.h.  */
12685 #include <$ac_header>
12686 _ACEOF
12687 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
12688   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12689   ac_status=$?
12690   grep -v '^ *+' conftest.er1 >conftest.err
12691   rm -f conftest.er1
12692   cat conftest.err >&5
12693   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12694   (exit $ac_status); } >/dev/null; then
12695   if test -s conftest.err; then
12696     ac_cpp_err=$ac_c_preproc_warn_flag
12697   else
12698     ac_cpp_err=
12699   fi
12700 else
12701   ac_cpp_err=yes
12702 fi
12703 if test -z "$ac_cpp_err"; then
12704   ac_header_preproc=yes
12705 else
12706   echo "$as_me: failed program was:" >&5
12707 sed 's/^/| /' conftest.$ac_ext >&5
12708
12709   ac_header_preproc=no
12710 fi
12711 rm -f conftest.err conftest.$ac_ext
12712 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12713 echo "${ECHO_T}$ac_header_preproc" >&6
12714
12715 # So?  What about this header?
12716 case $ac_header_compiler:$ac_header_preproc in
12717   yes:no )
12718     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12719 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12720     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12721 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12722     (
12723       cat <<\_ASBOX
12724 ## ------------------------------------ ##
12725 ## Report this to bug-autoconf@gnu.org. ##
12726 ## ------------------------------------ ##
12727 _ASBOX
12728     ) |
12729       sed "s/^/$as_me: WARNING:     /" >&2
12730     ;;
12731   no:yes )
12732     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12733 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12734     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
12735 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
12736     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12737 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12738     (
12739       cat <<\_ASBOX
12740 ## ------------------------------------ ##
12741 ## Report this to bug-autoconf@gnu.org. ##
12742 ## ------------------------------------ ##
12743 _ASBOX
12744     ) |
12745       sed "s/^/$as_me: WARNING:     /" >&2
12746     ;;
12747 esac
12748 echo "$as_me:$LINENO: checking for $ac_header" >&5
12749 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12750 if eval "test \"\${$as_ac_Header+set}\" = set"; then
12751   echo $ECHO_N "(cached) $ECHO_C" >&6
12752 else
12753   eval "$as_ac_Header=$ac_header_preproc"
12754 fi
12755 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12756 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12757
12758 fi
12759 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12760   cat >>confdefs.h <<_ACEOF
12761 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12762 _ACEOF
12763
12764 fi
12765
12766 done
12767
12768 if test $ac_cv_header_sys_uuid_h = yes ; then
12769         save_LIBS="$LIBS"
12770         echo "$as_me:$LINENO: checking for library containing uuid_to_str" >&5
12771 echo $ECHO_N "checking for library containing uuid_to_str... $ECHO_C" >&6
12772 if test "${ac_cv_search_uuid_to_str+set}" = set; then
12773   echo $ECHO_N "(cached) $ECHO_C" >&6
12774 else
12775   ac_func_search_save_LIBS=$LIBS
12776 ac_cv_search_uuid_to_str=no
12777 cat >conftest.$ac_ext <<_ACEOF
12778 #line $LINENO "configure"
12779 /* confdefs.h.  */
12780 _ACEOF
12781 cat confdefs.h >>conftest.$ac_ext
12782 cat >>conftest.$ac_ext <<_ACEOF
12783 /* end confdefs.h.  */
12784
12785 /* Override any gcc2 internal prototype to avoid an error.  */
12786 #ifdef __cplusplus
12787 extern "C"
12788 #endif
12789 /* We use char because int might match the return type of a gcc2
12790    builtin and then its argument prototype would still apply.  */
12791 char uuid_to_str ();
12792 int
12793 main ()
12794 {
12795 uuid_to_str ();
12796   ;
12797   return 0;
12798 }
12799 _ACEOF
12800 rm -f conftest.$ac_objext conftest$ac_exeext
12801 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12802   (eval $ac_link) 2>&5
12803   ac_status=$?
12804   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12805   (exit $ac_status); } &&
12806          { ac_try='test -s conftest$ac_exeext'
12807   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12808   (eval $ac_try) 2>&5
12809   ac_status=$?
12810   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12811   (exit $ac_status); }; }; then
12812   ac_cv_search_uuid_to_str="none required"
12813 else
12814   echo "$as_me: failed program was:" >&5
12815 sed 's/^/| /' conftest.$ac_ext >&5
12816
12817 fi
12818 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12819 if test "$ac_cv_search_uuid_to_str" = no; then
12820   for ac_lib in uuid; do
12821     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
12822     cat >conftest.$ac_ext <<_ACEOF
12823 #line $LINENO "configure"
12824 /* confdefs.h.  */
12825 _ACEOF
12826 cat confdefs.h >>conftest.$ac_ext
12827 cat >>conftest.$ac_ext <<_ACEOF
12828 /* end confdefs.h.  */
12829
12830 /* Override any gcc2 internal prototype to avoid an error.  */
12831 #ifdef __cplusplus
12832 extern "C"
12833 #endif
12834 /* We use char because int might match the return type of a gcc2
12835    builtin and then its argument prototype would still apply.  */
12836 char uuid_to_str ();
12837 int
12838 main ()
12839 {
12840 uuid_to_str ();
12841   ;
12842   return 0;
12843 }
12844 _ACEOF
12845 rm -f conftest.$ac_objext conftest$ac_exeext
12846 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12847   (eval $ac_link) 2>&5
12848   ac_status=$?
12849   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12850   (exit $ac_status); } &&
12851          { ac_try='test -s conftest$ac_exeext'
12852   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12853   (eval $ac_try) 2>&5
12854   ac_status=$?
12855   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12856   (exit $ac_status); }; }; then
12857   ac_cv_search_uuid_to_str="-l$ac_lib"
12858 break
12859 else
12860   echo "$as_me: failed program was:" >&5
12861 sed 's/^/| /' conftest.$ac_ext >&5
12862
12863 fi
12864 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12865   done
12866 fi
12867 LIBS=$ac_func_search_save_LIBS
12868 fi
12869 echo "$as_me:$LINENO: result: $ac_cv_search_uuid_to_str" >&5
12870 echo "${ECHO_T}$ac_cv_search_uuid_to_str" >&6
12871 if test "$ac_cv_search_uuid_to_str" != no; then
12872   test "$ac_cv_search_uuid_to_str" = "none required" || LIBS="$ac_cv_search_uuid_to_str $LIBS"
12873   have_uuid=yes
12874 else
12875   :
12876 fi
12877
12878         LIBS="$save_LIBS"
12879
12880         if test have_uuid = yes ; then
12881
12882 cat >>confdefs.h <<\_ACEOF
12883 #define HAVE_UUID_TO_STR 1
12884 _ACEOF
12885
12886
12887                 test "$ac_cv_search_uuid_to_str" = "none required" || \
12888                         SLAPD_LIBS="$SLAPD_LIBS $ac_cv_search_uuid_to_str"
12889         fi
12890 fi
12891
12892 if test $have_uuid = no ; then
12893         echo "$as_me:$LINENO: checking to see if -lrpcrt4 is needed for win32 UUID support" >&5
12894 echo $ECHO_N "checking to see if -lrpcrt4 is needed for win32 UUID support... $ECHO_C" >&6
12895         save_LIBS="$LIBS"
12896         LIBS="$LIBS -lrpcrt4"
12897         cat >conftest.$ac_ext <<_ACEOF
12898 #line $LINENO "configure"
12899 /* confdefs.h.  */
12900 _ACEOF
12901 cat confdefs.h >>conftest.$ac_ext
12902 cat >>conftest.$ac_ext <<_ACEOF
12903 /* end confdefs.h.  */
12904
12905                 char UuidCreate@4();
12906                 char UuidToStringA@8();
12907
12908 int
12909 main ()
12910 {
12911
12912                 UuidCreate@4();
12913                 UuidToStringA@8();
12914
12915   ;
12916   return 0;
12917 }
12918 _ACEOF
12919 rm -f conftest.$ac_objext conftest$ac_exeext
12920 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12921   (eval $ac_link) 2>&5
12922   ac_status=$?
12923   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12924   (exit $ac_status); } &&
12925          { ac_try='test -s conftest$ac_exeext'
12926   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12927   (eval $ac_try) 2>&5
12928   ac_status=$?
12929   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12930   (exit $ac_status); }; }; then
12931   need_rpcrt=yes
12932 else
12933   echo "$as_me: failed program was:" >&5
12934 sed 's/^/| /' conftest.$ac_ext >&5
12935
12936 need_rpcrt=no
12937 fi
12938 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12939         if test $need_rpcrt = yes; then
12940                 SLAPD_LIBS="$SLAPD_LIBS -lrpcrt4"
12941         fi
12942         LIBS="$save_LIBS"
12943         echo "$as_me:$LINENO: result: $need_rpcrt" >&5
12944 echo "${ECHO_T}$need_rpcrt" >&6
12945 fi
12946
12947 ol_link_dnssrv=no
12948 echo "$as_me:$LINENO: checking for res_query" >&5
12949 echo $ECHO_N "checking for res_query... $ECHO_C" >&6
12950 if test "${ac_cv_func_res_query+set}" = set; then
12951   echo $ECHO_N "(cached) $ECHO_C" >&6
12952 else
12953   cat >conftest.$ac_ext <<_ACEOF
12954 #line $LINENO "configure"
12955 /* confdefs.h.  */
12956 _ACEOF
12957 cat confdefs.h >>conftest.$ac_ext
12958 cat >>conftest.$ac_ext <<_ACEOF
12959 /* end confdefs.h.  */
12960 /* System header to define __stub macros and hopefully few prototypes,
12961     which can conflict with char res_query (); below.
12962     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12963     <limits.h> exists even on freestanding compilers.  */
12964 #ifdef __STDC__
12965 # include <limits.h>
12966 #else
12967 # include <assert.h>
12968 #endif
12969 /* Override any gcc2 internal prototype to avoid an error.  */
12970 #ifdef __cplusplus
12971 extern "C"
12972 {
12973 #endif
12974 /* We use char because int might match the return type of a gcc2
12975    builtin and then its argument prototype would still apply.  */
12976 char res_query ();
12977 /* The GNU C library defines this for functions which it implements
12978     to always fail with ENOSYS.  Some functions are actually named
12979     something starting with __ and the normal name is an alias.  */
12980 #if defined (__stub_res_query) || defined (__stub___res_query)
12981 choke me
12982 #else
12983 char (*f) () = res_query;
12984 #endif
12985 #ifdef __cplusplus
12986 }
12987 #endif
12988
12989 int
12990 main ()
12991 {
12992 return f != res_query;
12993   ;
12994   return 0;
12995 }
12996 _ACEOF
12997 rm -f conftest.$ac_objext conftest$ac_exeext
12998 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12999   (eval $ac_link) 2>&5
13000   ac_status=$?
13001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13002   (exit $ac_status); } &&
13003          { ac_try='test -s conftest$ac_exeext'
13004   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13005   (eval $ac_try) 2>&5
13006   ac_status=$?
13007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13008   (exit $ac_status); }; }; then
13009   ac_cv_func_res_query=yes
13010 else
13011   echo "$as_me: failed program was:" >&5
13012 sed 's/^/| /' conftest.$ac_ext >&5
13013
13014 ac_cv_func_res_query=no
13015 fi
13016 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13017 fi
13018 echo "$as_me:$LINENO: result: $ac_cv_func_res_query" >&5
13019 echo "${ECHO_T}$ac_cv_func_res_query" >&6
13020 if test $ac_cv_func_res_query = yes; then
13021   :
13022 fi
13023
13024 if test $ac_cv_func_res_query = no ; then
13025         echo "$as_me:$LINENO: checking for __res_query" >&5
13026 echo $ECHO_N "checking for __res_query... $ECHO_C" >&6
13027 if test "${ac_cv_func___res_query+set}" = set; then
13028   echo $ECHO_N "(cached) $ECHO_C" >&6
13029 else
13030   cat >conftest.$ac_ext <<_ACEOF
13031 #line $LINENO "configure"
13032 /* confdefs.h.  */
13033 _ACEOF
13034 cat confdefs.h >>conftest.$ac_ext
13035 cat >>conftest.$ac_ext <<_ACEOF
13036 /* end confdefs.h.  */
13037 /* System header to define __stub macros and hopefully few prototypes,
13038     which can conflict with char __res_query (); below.
13039     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13040     <limits.h> exists even on freestanding compilers.  */
13041 #ifdef __STDC__
13042 # include <limits.h>
13043 #else
13044 # include <assert.h>
13045 #endif
13046 /* Override any gcc2 internal prototype to avoid an error.  */
13047 #ifdef __cplusplus
13048 extern "C"
13049 {
13050 #endif
13051 /* We use char because int might match the return type of a gcc2
13052    builtin and then its argument prototype would still apply.  */
13053 char __res_query ();
13054 /* The GNU C library defines this for functions which it implements
13055     to always fail with ENOSYS.  Some functions are actually named
13056     something starting with __ and the normal name is an alias.  */
13057 #if defined (__stub___res_query) || defined (__stub_____res_query)
13058 choke me
13059 #else
13060 char (*f) () = __res_query;
13061 #endif
13062 #ifdef __cplusplus
13063 }
13064 #endif
13065
13066 int
13067 main ()
13068 {
13069 return f != __res_query;
13070   ;
13071   return 0;
13072 }
13073 _ACEOF
13074 rm -f conftest.$ac_objext conftest$ac_exeext
13075 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13076   (eval $ac_link) 2>&5
13077   ac_status=$?
13078   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13079   (exit $ac_status); } &&
13080          { ac_try='test -s conftest$ac_exeext'
13081   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13082   (eval $ac_try) 2>&5
13083   ac_status=$?
13084   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13085   (exit $ac_status); }; }; then
13086   ac_cv_func___res_query=yes
13087 else
13088   echo "$as_me: failed program was:" >&5
13089 sed 's/^/| /' conftest.$ac_ext >&5
13090
13091 ac_cv_func___res_query=no
13092 fi
13093 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13094 fi
13095 echo "$as_me:$LINENO: result: $ac_cv_func___res_query" >&5
13096 echo "${ECHO_T}$ac_cv_func___res_query" >&6
13097 if test $ac_cv_func___res_query = yes; then
13098   :
13099 fi
13100
13101         ac_cv_func_res_query=$ac_cv_func___res_query
13102 fi
13103
13104 if test $ac_cv_func_res_query = no ; then
13105
13106 echo "$as_me:$LINENO: checking for res_query in -lbind" >&5
13107 echo $ECHO_N "checking for res_query in -lbind... $ECHO_C" >&6
13108 if test "${ac_cv_lib_bind_res_query+set}" = set; then
13109   echo $ECHO_N "(cached) $ECHO_C" >&6
13110 else
13111   ac_check_lib_save_LIBS=$LIBS
13112 LIBS="-lbind  $LIBS"
13113 cat >conftest.$ac_ext <<_ACEOF
13114 #line $LINENO "configure"
13115 /* confdefs.h.  */
13116 _ACEOF
13117 cat confdefs.h >>conftest.$ac_ext
13118 cat >>conftest.$ac_ext <<_ACEOF
13119 /* end confdefs.h.  */
13120
13121 /* Override any gcc2 internal prototype to avoid an error.  */
13122 #ifdef __cplusplus
13123 extern "C"
13124 #endif
13125 /* We use char because int might match the return type of a gcc2
13126    builtin and then its argument prototype would still apply.  */
13127 char res_query ();
13128 int
13129 main ()
13130 {
13131 res_query ();
13132   ;
13133   return 0;
13134 }
13135 _ACEOF
13136 rm -f conftest.$ac_objext conftest$ac_exeext
13137 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13138   (eval $ac_link) 2>&5
13139   ac_status=$?
13140   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13141   (exit $ac_status); } &&
13142          { ac_try='test -s conftest$ac_exeext'
13143   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13144   (eval $ac_try) 2>&5
13145   ac_status=$?
13146   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13147   (exit $ac_status); }; }; then
13148   ac_cv_lib_bind_res_query=yes
13149 else
13150   echo "$as_me: failed program was:" >&5
13151 sed 's/^/| /' conftest.$ac_ext >&5
13152
13153 ac_cv_lib_bind_res_query=no
13154 fi
13155 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13156 LIBS=$ac_check_lib_save_LIBS
13157 fi
13158 echo "$as_me:$LINENO: result: $ac_cv_lib_bind_res_query" >&5
13159 echo "${ECHO_T}$ac_cv_lib_bind_res_query" >&6
13160 if test $ac_cv_lib_bind_res_query = yes; then
13161   cat >>confdefs.h <<_ACEOF
13162 #define HAVE_LIBBIND 1
13163 _ACEOF
13164
13165   LIBS="-lbind $LIBS"
13166
13167 fi
13168
13169         ac_cv_func_res_query=$ac_cv_lib_bind_res_query
13170 fi
13171
13172 if test $ac_cv_func_res_query = no ; then
13173
13174 echo "$as_me:$LINENO: checking for __res_query in -lbind" >&5
13175 echo $ECHO_N "checking for __res_query in -lbind... $ECHO_C" >&6
13176 if test "${ac_cv_lib_bind___res_query+set}" = set; then
13177   echo $ECHO_N "(cached) $ECHO_C" >&6
13178 else
13179   ac_check_lib_save_LIBS=$LIBS
13180 LIBS="-lbind  $LIBS"
13181 cat >conftest.$ac_ext <<_ACEOF
13182 #line $LINENO "configure"
13183 /* confdefs.h.  */
13184 _ACEOF
13185 cat confdefs.h >>conftest.$ac_ext
13186 cat >>conftest.$ac_ext <<_ACEOF
13187 /* end confdefs.h.  */
13188
13189 /* Override any gcc2 internal prototype to avoid an error.  */
13190 #ifdef __cplusplus
13191 extern "C"
13192 #endif
13193 /* We use char because int might match the return type of a gcc2
13194    builtin and then its argument prototype would still apply.  */
13195 char __res_query ();
13196 int
13197 main ()
13198 {
13199 __res_query ();
13200   ;
13201   return 0;
13202 }
13203 _ACEOF
13204 rm -f conftest.$ac_objext conftest$ac_exeext
13205 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13206   (eval $ac_link) 2>&5
13207   ac_status=$?
13208   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13209   (exit $ac_status); } &&
13210          { ac_try='test -s conftest$ac_exeext'
13211   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13212   (eval $ac_try) 2>&5
13213   ac_status=$?
13214   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13215   (exit $ac_status); }; }; then
13216   ac_cv_lib_bind___res_query=yes
13217 else
13218   echo "$as_me: failed program was:" >&5
13219 sed 's/^/| /' conftest.$ac_ext >&5
13220
13221 ac_cv_lib_bind___res_query=no
13222 fi
13223 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13224 LIBS=$ac_check_lib_save_LIBS
13225 fi
13226 echo "$as_me:$LINENO: result: $ac_cv_lib_bind___res_query" >&5
13227 echo "${ECHO_T}$ac_cv_lib_bind___res_query" >&6
13228 if test $ac_cv_lib_bind___res_query = yes; then
13229   cat >>confdefs.h <<_ACEOF
13230 #define HAVE_LIBBIND 1
13231 _ACEOF
13232
13233   LIBS="-lbind $LIBS"
13234
13235 fi
13236
13237         ac_cv_func_res_query=$ac_cv_lib_bind___res_query
13238 fi
13239
13240 if test $ac_cv_func_res_query = no ; then
13241
13242 echo "$as_me:$LINENO: checking for res_query in -lresolv" >&5
13243 echo $ECHO_N "checking for res_query in -lresolv... $ECHO_C" >&6
13244 if test "${ac_cv_lib_resolv_res_query+set}" = set; then
13245   echo $ECHO_N "(cached) $ECHO_C" >&6
13246 else
13247   ac_check_lib_save_LIBS=$LIBS
13248 LIBS="-lresolv  $LIBS"
13249 cat >conftest.$ac_ext <<_ACEOF
13250 #line $LINENO "configure"
13251 /* confdefs.h.  */
13252 _ACEOF
13253 cat confdefs.h >>conftest.$ac_ext
13254 cat >>conftest.$ac_ext <<_ACEOF
13255 /* end confdefs.h.  */
13256
13257 /* Override any gcc2 internal prototype to avoid an error.  */
13258 #ifdef __cplusplus
13259 extern "C"
13260 #endif
13261 /* We use char because int might match the return type of a gcc2
13262    builtin and then its argument prototype would still apply.  */
13263 char res_query ();
13264 int
13265 main ()
13266 {
13267 res_query ();
13268   ;
13269   return 0;
13270 }
13271 _ACEOF
13272 rm -f conftest.$ac_objext conftest$ac_exeext
13273 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13274   (eval $ac_link) 2>&5
13275   ac_status=$?
13276   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13277   (exit $ac_status); } &&
13278          { ac_try='test -s conftest$ac_exeext'
13279   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13280   (eval $ac_try) 2>&5
13281   ac_status=$?
13282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13283   (exit $ac_status); }; }; then
13284   ac_cv_lib_resolv_res_query=yes
13285 else
13286   echo "$as_me: failed program was:" >&5
13287 sed 's/^/| /' conftest.$ac_ext >&5
13288
13289 ac_cv_lib_resolv_res_query=no
13290 fi
13291 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13292 LIBS=$ac_check_lib_save_LIBS
13293 fi
13294 echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_res_query" >&5
13295 echo "${ECHO_T}$ac_cv_lib_resolv_res_query" >&6
13296 if test $ac_cv_lib_resolv_res_query = yes; then
13297   cat >>confdefs.h <<_ACEOF
13298 #define HAVE_LIBRESOLV 1
13299 _ACEOF
13300
13301   LIBS="-lresolv $LIBS"
13302
13303 fi
13304
13305         ac_cv_func_res_query=$ac_cv_lib_resolv_res_query
13306 fi
13307
13308 if test $ac_cv_func_res_query = no ; then
13309
13310 echo "$as_me:$LINENO: checking for __res_query in -lresolv" >&5
13311 echo $ECHO_N "checking for __res_query in -lresolv... $ECHO_C" >&6
13312 if test "${ac_cv_lib_resolv___res_query+set}" = set; then
13313   echo $ECHO_N "(cached) $ECHO_C" >&6
13314 else
13315   ac_check_lib_save_LIBS=$LIBS
13316 LIBS="-lresolv  $LIBS"
13317 cat >conftest.$ac_ext <<_ACEOF
13318 #line $LINENO "configure"
13319 /* confdefs.h.  */
13320 _ACEOF
13321 cat confdefs.h >>conftest.$ac_ext
13322 cat >>conftest.$ac_ext <<_ACEOF
13323 /* end confdefs.h.  */
13324
13325 /* Override any gcc2 internal prototype to avoid an error.  */
13326 #ifdef __cplusplus
13327 extern "C"
13328 #endif
13329 /* We use char because int might match the return type of a gcc2
13330    builtin and then its argument prototype would still apply.  */
13331 char __res_query ();
13332 int
13333 main ()
13334 {
13335 __res_query ();
13336   ;
13337   return 0;
13338 }
13339 _ACEOF
13340 rm -f conftest.$ac_objext conftest$ac_exeext
13341 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13342   (eval $ac_link) 2>&5
13343   ac_status=$?
13344   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13345   (exit $ac_status); } &&
13346          { ac_try='test -s conftest$ac_exeext'
13347   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13348   (eval $ac_try) 2>&5
13349   ac_status=$?
13350   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13351   (exit $ac_status); }; }; then
13352   ac_cv_lib_resolv___res_query=yes
13353 else
13354   echo "$as_me: failed program was:" >&5
13355 sed 's/^/| /' conftest.$ac_ext >&5
13356
13357 ac_cv_lib_resolv___res_query=no
13358 fi
13359 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13360 LIBS=$ac_check_lib_save_LIBS
13361 fi
13362 echo "$as_me:$LINENO: result: $ac_cv_lib_resolv___res_query" >&5
13363 echo "${ECHO_T}$ac_cv_lib_resolv___res_query" >&6
13364 if test $ac_cv_lib_resolv___res_query = yes; then
13365   cat >>confdefs.h <<_ACEOF
13366 #define HAVE_LIBRESOLV 1
13367 _ACEOF
13368
13369   LIBS="-lresolv $LIBS"
13370
13371 fi
13372
13373         ac_cv_func_res_query=$ac_cv_lib_resolv___res_query
13374 fi
13375
13376 if test "$ac_cv_func_res_query" = yes ; then
13377
13378 cat >>confdefs.h <<\_ACEOF
13379 #define HAVE_RES_QUERY 1
13380 _ACEOF
13381
13382
13383         if test $ol_enable_dnssrv != no ; then
13384                 ol_link_dnssrv=yes
13385         fi
13386 fi
13387
13388 if test "$ol_enable_dnssrv" = yes -a "$ol_link_dnssrv" = no ; then
13389         { { echo "$as_me:$LINENO: error: DNSSRV requires res_query()" >&5
13390 echo "$as_me: error: DNSSRV requires res_query()" >&2;}
13391    { (exit 1); exit 1; }; }
13392 fi
13393
13394
13395
13396
13397
13398 for ac_func in getaddrinfo getnameinfo gai_strerror inet_ntop
13399 do
13400 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13401 echo "$as_me:$LINENO: checking for $ac_func" >&5
13402 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13403 if eval "test \"\${$as_ac_var+set}\" = set"; then
13404   echo $ECHO_N "(cached) $ECHO_C" >&6
13405 else
13406   cat >conftest.$ac_ext <<_ACEOF
13407 #line $LINENO "configure"
13408 /* confdefs.h.  */
13409 _ACEOF
13410 cat confdefs.h >>conftest.$ac_ext
13411 cat >>conftest.$ac_ext <<_ACEOF
13412 /* end confdefs.h.  */
13413 /* System header to define __stub macros and hopefully few prototypes,
13414     which can conflict with char $ac_func (); below.
13415     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13416     <limits.h> exists even on freestanding compilers.  */
13417 #ifdef __STDC__
13418 # include <limits.h>
13419 #else
13420 # include <assert.h>
13421 #endif
13422 /* Override any gcc2 internal prototype to avoid an error.  */
13423 #ifdef __cplusplus
13424 extern "C"
13425 {
13426 #endif
13427 /* We use char because int might match the return type of a gcc2
13428    builtin and then its argument prototype would still apply.  */
13429 char $ac_func ();
13430 /* The GNU C library defines this for functions which it implements
13431     to always fail with ENOSYS.  Some functions are actually named
13432     something starting with __ and the normal name is an alias.  */
13433 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13434 choke me
13435 #else
13436 char (*f) () = $ac_func;
13437 #endif
13438 #ifdef __cplusplus
13439 }
13440 #endif
13441
13442 int
13443 main ()
13444 {
13445 return f != $ac_func;
13446   ;
13447   return 0;
13448 }
13449 _ACEOF
13450 rm -f conftest.$ac_objext conftest$ac_exeext
13451 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13452   (eval $ac_link) 2>&5
13453   ac_status=$?
13454   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13455   (exit $ac_status); } &&
13456          { ac_try='test -s conftest$ac_exeext'
13457   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13458   (eval $ac_try) 2>&5
13459   ac_status=$?
13460   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13461   (exit $ac_status); }; }; then
13462   eval "$as_ac_var=yes"
13463 else
13464   echo "$as_me: failed program was:" >&5
13465 sed 's/^/| /' conftest.$ac_ext >&5
13466
13467 eval "$as_ac_var=no"
13468 fi
13469 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13470 fi
13471 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13472 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13473 if test `eval echo '${'$as_ac_var'}'` = yes; then
13474   cat >>confdefs.h <<_ACEOF
13475 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13476 _ACEOF
13477
13478 fi
13479 done
13480
13481
13482 ol_link_ipv6=no
13483 if test $ac_cv_func_getaddrinfo = no -o $ac_cv_func_inet_ntop = no ; then
13484         if test $ol_enable_ipv6 = yes ; then
13485                 { { echo "$as_me:$LINENO: error: IPv6 support requires getaddrinfo() and inet_ntop()" >&5
13486 echo "$as_me: error: IPv6 support requires getaddrinfo() and inet_ntop()" >&2;}
13487    { (exit 1); exit 1; }; }
13488         fi
13489 elif test $ol_enable_ipv6 != no ; then
13490         echo "$as_me:$LINENO: checking INET6_ADDRSTRLEN" >&5
13491 echo $ECHO_N "checking INET6_ADDRSTRLEN... $ECHO_C" >&6
13492 if test "${ol_cv_inet6_addrstrlen+set}" = set; then
13493   echo $ECHO_N "(cached) $ECHO_C" >&6
13494 else
13495
13496                 cat >conftest.$ac_ext <<_ACEOF
13497 #line $LINENO "configure"
13498 /* confdefs.h.  */
13499 _ACEOF
13500 cat confdefs.h >>conftest.$ac_ext
13501 cat >>conftest.$ac_ext <<_ACEOF
13502 /* end confdefs.h.  */
13503
13504 #                       include <netinet/in.h>
13505 #                       ifdef INET6_ADDRSTRLEN
13506                                 __has_inet6_addrstrlen__;
13507 #                       endif
13508
13509 _ACEOF
13510 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13511   $EGREP "__has_inet6_addrstrlen__" >/dev/null 2>&1; then
13512   ol_cv_inet6_addrstrlen=yes
13513 else
13514   ol_cv_inet6_addrstrlen=no
13515 fi
13516 rm -f conftest*
13517
13518 fi
13519 echo "$as_me:$LINENO: result: $ol_cv_inet6_addrstrlen" >&5
13520 echo "${ECHO_T}$ol_cv_inet6_addrstrlen" >&6
13521
13522
13523         echo "$as_me:$LINENO: checking struct sockaddr_storage" >&5
13524 echo $ECHO_N "checking struct sockaddr_storage... $ECHO_C" >&6
13525 if test "${ol_cv_struct_sockaddr_storage+set}" = set; then
13526   echo $ECHO_N "(cached) $ECHO_C" >&6
13527 else
13528
13529                 cat >conftest.$ac_ext <<_ACEOF
13530 #line $LINENO "configure"
13531 /* confdefs.h.  */
13532 _ACEOF
13533 cat confdefs.h >>conftest.$ac_ext
13534 cat >>conftest.$ac_ext <<_ACEOF
13535 /* end confdefs.h.  */
13536
13537 #include <sys/types.h>
13538 #include <sys/socket.h>
13539
13540 int
13541 main ()
13542 {
13543
13544                         struct sockaddr_storage ss;
13545
13546   ;
13547   return 0;
13548 }
13549 _ACEOF
13550 rm -f conftest.$ac_objext
13551 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13552   (eval $ac_compile) 2>&5
13553   ac_status=$?
13554   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13555   (exit $ac_status); } &&
13556          { ac_try='test -s conftest.$ac_objext'
13557   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13558   (eval $ac_try) 2>&5
13559   ac_status=$?
13560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13561   (exit $ac_status); }; }; then
13562   ol_cv_struct_sockaddr_storage=yes
13563 else
13564   echo "$as_me: failed program was:" >&5
13565 sed 's/^/| /' conftest.$ac_ext >&5
13566
13567 ol_cv_struct_sockaddr_storage=no
13568 fi
13569 rm -f conftest.$ac_objext conftest.$ac_ext
13570 fi
13571 echo "$as_me:$LINENO: result: $ol_cv_struct_sockaddr_storage" >&5
13572 echo "${ECHO_T}$ol_cv_struct_sockaddr_storage" >&6
13573
13574         if test $ol_cv_inet6_addrstrlen = yes \
13575                 -a $ol_cv_struct_sockaddr_storage = yes ; then
13576                 ol_link_ipv6=yes
13577         elif test $ol_enable_ipv6 = yes \
13578                         -a $ol_cv_inet6_addrstrlen = no ; then
13579                 { { echo "$as_me:$LINENO: error: IPv6 support requires INET6_ADDRSTRLEN" >&5
13580 echo "$as_me: error: IPv6 support requires INET6_ADDRSTRLEN" >&2;}
13581    { (exit 1); exit 1; }; }
13582         elif test $ol_enable_ipv6 = yes \
13583                         -a $ol_cv_struct_sockaddr_storage = no ; then
13584                 { { echo "$as_me:$LINENO: error: IPv6 support requires struct sockaddr_storage" >&5
13585 echo "$as_me: error: IPv6 support requires struct sockaddr_storage" >&2;}
13586    { (exit 1); exit 1; }; }
13587         fi
13588 fi
13589
13590 if test $ol_enable_local != no ; then
13591
13592 for ac_header in sys/un.h
13593 do
13594 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13595 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13596   echo "$as_me:$LINENO: checking for $ac_header" >&5
13597 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13598 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13599   echo $ECHO_N "(cached) $ECHO_C" >&6
13600 fi
13601 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13602 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13603 else
13604   # Is the header compilable?
13605 echo "$as_me:$LINENO: checking $ac_header usability" >&5
13606 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13607 cat >conftest.$ac_ext <<_ACEOF
13608 #line $LINENO "configure"
13609 /* confdefs.h.  */
13610 _ACEOF
13611 cat confdefs.h >>conftest.$ac_ext
13612 cat >>conftest.$ac_ext <<_ACEOF
13613 /* end confdefs.h.  */
13614 $ac_includes_default
13615 #include <$ac_header>
13616 _ACEOF
13617 rm -f conftest.$ac_objext
13618 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13619   (eval $ac_compile) 2>&5
13620   ac_status=$?
13621   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13622   (exit $ac_status); } &&
13623          { ac_try='test -s conftest.$ac_objext'
13624   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13625   (eval $ac_try) 2>&5
13626   ac_status=$?
13627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13628   (exit $ac_status); }; }; then
13629   ac_header_compiler=yes
13630 else
13631   echo "$as_me: failed program was:" >&5
13632 sed 's/^/| /' conftest.$ac_ext >&5
13633
13634 ac_header_compiler=no
13635 fi
13636 rm -f conftest.$ac_objext conftest.$ac_ext
13637 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13638 echo "${ECHO_T}$ac_header_compiler" >&6
13639
13640 # Is the header present?
13641 echo "$as_me:$LINENO: checking $ac_header presence" >&5
13642 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13643 cat >conftest.$ac_ext <<_ACEOF
13644 #line $LINENO "configure"
13645 /* confdefs.h.  */
13646 _ACEOF
13647 cat confdefs.h >>conftest.$ac_ext
13648 cat >>conftest.$ac_ext <<_ACEOF
13649 /* end confdefs.h.  */
13650 #include <$ac_header>
13651 _ACEOF
13652 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13653   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13654   ac_status=$?
13655   grep -v '^ *+' conftest.er1 >conftest.err
13656   rm -f conftest.er1
13657   cat conftest.err >&5
13658   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13659   (exit $ac_status); } >/dev/null; then
13660   if test -s conftest.err; then
13661     ac_cpp_err=$ac_c_preproc_warn_flag
13662   else
13663     ac_cpp_err=
13664   fi
13665 else
13666   ac_cpp_err=yes
13667 fi
13668 if test -z "$ac_cpp_err"; then
13669   ac_header_preproc=yes
13670 else
13671   echo "$as_me: failed program was:" >&5
13672 sed 's/^/| /' conftest.$ac_ext >&5
13673
13674   ac_header_preproc=no
13675 fi
13676 rm -f conftest.err conftest.$ac_ext
13677 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13678 echo "${ECHO_T}$ac_header_preproc" >&6
13679
13680 # So?  What about this header?
13681 case $ac_header_compiler:$ac_header_preproc in
13682   yes:no )
13683     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13684 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13685     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13686 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13687     (
13688       cat <<\_ASBOX
13689 ## ------------------------------------ ##
13690 ## Report this to bug-autoconf@gnu.org. ##
13691 ## ------------------------------------ ##
13692 _ASBOX
13693     ) |
13694       sed "s/^/$as_me: WARNING:     /" >&2
13695     ;;
13696   no:yes )
13697     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13698 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13699     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13700 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13701     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13702 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13703     (
13704       cat <<\_ASBOX
13705 ## ------------------------------------ ##
13706 ## Report this to bug-autoconf@gnu.org. ##
13707 ## ------------------------------------ ##
13708 _ASBOX
13709     ) |
13710       sed "s/^/$as_me: WARNING:     /" >&2
13711     ;;
13712 esac
13713 echo "$as_me:$LINENO: checking for $ac_header" >&5
13714 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13715 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13716   echo $ECHO_N "(cached) $ECHO_C" >&6
13717 else
13718   eval "$as_ac_Header=$ac_header_preproc"
13719 fi
13720 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13721 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13722
13723 fi
13724 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13725   cat >>confdefs.h <<_ACEOF
13726 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13727 _ACEOF
13728
13729 fi
13730
13731 done
13732
13733
13734         if test $ol_enable_local = auto ; then
13735                 ol_enable_local=$ac_cv_header_sys_un_h
13736         elif test $ac_cv_header_sys_un_h = no ; then
13737                 { { echo "$as_me:$LINENO: error: AF_LOCAL domain support requires sys/un.h" >&5
13738 echo "$as_me: error: AF_LOCAL domain support requires sys/un.h" >&2;}
13739    { (exit 1); exit 1; }; }
13740         fi
13741 fi
13742
13743 ol_link_kbind=no
13744 ol_link_kpasswd=no
13745 ol_link_krb5=no
13746 ol_link_krb4=no
13747
13748 if test $ol_with_kerberos = yes -o $ol_with_kerberos = auto \
13749         -o $ol_with_kerberos = k5 -o $ol_with_kerberos = k5only \
13750         -o $ol_with_kerberos = k425 ; then
13751
13752
13753 for ac_header in krb5.h
13754 do
13755 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13756 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13757   echo "$as_me:$LINENO: checking for $ac_header" >&5
13758 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13759 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13760   echo $ECHO_N "(cached) $ECHO_C" >&6
13761 fi
13762 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13763 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13764 else
13765   # Is the header compilable?
13766 echo "$as_me:$LINENO: checking $ac_header usability" >&5
13767 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13768 cat >conftest.$ac_ext <<_ACEOF
13769 #line $LINENO "configure"
13770 /* confdefs.h.  */
13771 _ACEOF
13772 cat confdefs.h >>conftest.$ac_ext
13773 cat >>conftest.$ac_ext <<_ACEOF
13774 /* end confdefs.h.  */
13775 $ac_includes_default
13776 #include <$ac_header>
13777 _ACEOF
13778 rm -f conftest.$ac_objext
13779 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13780   (eval $ac_compile) 2>&5
13781   ac_status=$?
13782   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13783   (exit $ac_status); } &&
13784          { ac_try='test -s conftest.$ac_objext'
13785   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13786   (eval $ac_try) 2>&5
13787   ac_status=$?
13788   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13789   (exit $ac_status); }; }; then
13790   ac_header_compiler=yes
13791 else
13792   echo "$as_me: failed program was:" >&5
13793 sed 's/^/| /' conftest.$ac_ext >&5
13794
13795 ac_header_compiler=no
13796 fi
13797 rm -f conftest.$ac_objext conftest.$ac_ext
13798 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13799 echo "${ECHO_T}$ac_header_compiler" >&6
13800
13801 # Is the header present?
13802 echo "$as_me:$LINENO: checking $ac_header presence" >&5
13803 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13804 cat >conftest.$ac_ext <<_ACEOF
13805 #line $LINENO "configure"
13806 /* confdefs.h.  */
13807 _ACEOF
13808 cat confdefs.h >>conftest.$ac_ext
13809 cat >>conftest.$ac_ext <<_ACEOF
13810 /* end confdefs.h.  */
13811 #include <$ac_header>
13812 _ACEOF
13813 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13814   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13815   ac_status=$?
13816   grep -v '^ *+' conftest.er1 >conftest.err
13817   rm -f conftest.er1
13818   cat conftest.err >&5
13819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13820   (exit $ac_status); } >/dev/null; then
13821   if test -s conftest.err; then
13822     ac_cpp_err=$ac_c_preproc_warn_flag
13823   else
13824     ac_cpp_err=
13825   fi
13826 else
13827   ac_cpp_err=yes
13828 fi
13829 if test -z "$ac_cpp_err"; then
13830   ac_header_preproc=yes
13831 else
13832   echo "$as_me: failed program was:" >&5
13833 sed 's/^/| /' conftest.$ac_ext >&5
13834
13835   ac_header_preproc=no
13836 fi
13837 rm -f conftest.err conftest.$ac_ext
13838 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13839 echo "${ECHO_T}$ac_header_preproc" >&6
13840
13841 # So?  What about this header?
13842 case $ac_header_compiler:$ac_header_preproc in
13843   yes:no )
13844     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13845 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13846     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13847 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13848     (
13849       cat <<\_ASBOX
13850 ## ------------------------------------ ##
13851 ## Report this to bug-autoconf@gnu.org. ##
13852 ## ------------------------------------ ##
13853 _ASBOX
13854     ) |
13855       sed "s/^/$as_me: WARNING:     /" >&2
13856     ;;
13857   no:yes )
13858     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13859 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13860     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13861 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13862     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13863 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13864     (
13865       cat <<\_ASBOX
13866 ## ------------------------------------ ##
13867 ## Report this to bug-autoconf@gnu.org. ##
13868 ## ------------------------------------ ##
13869 _ASBOX
13870     ) |
13871       sed "s/^/$as_me: WARNING:     /" >&2
13872     ;;
13873 esac
13874 echo "$as_me:$LINENO: checking for $ac_header" >&5
13875 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13876 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13877   echo $ECHO_N "(cached) $ECHO_C" >&6
13878 else
13879   eval "$as_ac_Header=$ac_header_preproc"
13880 fi
13881 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13882 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13883
13884 fi
13885 if test `eval echo '${'$as_ac_Header'}'` = yes; then
13886   cat >>confdefs.h <<_ACEOF
13887 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13888 _ACEOF
13889
13890 fi
13891
13892 done
13893
13894
13895         if test $ac_cv_header_krb5_h = yes ; then
13896
13897 for ac_header in heim_err.h
13898 do
13899 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13900 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13901   echo "$as_me:$LINENO: checking for $ac_header" >&5
13902 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13903 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13904   echo $ECHO_N "(cached) $ECHO_C" >&6
13905 fi
13906 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13907 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13908 else
13909   # Is the header compilable?
13910 echo "$as_me:$LINENO: checking $ac_header usability" >&5
13911 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13912 cat >conftest.$ac_ext <<_ACEOF
13913 #line $LINENO "configure"
13914 /* confdefs.h.  */
13915 _ACEOF
13916 cat confdefs.h >>conftest.$ac_ext
13917 cat >>conftest.$ac_ext <<_ACEOF
13918 /* end confdefs.h.  */
13919 $ac_includes_default
13920 #include <$ac_header>
13921 _ACEOF
13922 rm -f conftest.$ac_objext
13923 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13924   (eval $ac_compile) 2>&5
13925   ac_status=$?
13926   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13927   (exit $ac_status); } &&
13928          { ac_try='test -s conftest.$ac_objext'
13929   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13930   (eval $ac_try) 2>&5
13931   ac_status=$?
13932   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13933   (exit $ac_status); }; }; then
13934   ac_header_compiler=yes
13935 else
13936   echo "$as_me: failed program was:" >&5
13937 sed 's/^/| /' conftest.$ac_ext >&5
13938
13939 ac_header_compiler=no
13940 fi
13941 rm -f conftest.$ac_objext conftest.$ac_ext
13942 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13943 echo "${ECHO_T}$ac_header_compiler" >&6
13944
13945 # Is the header present?
13946 echo "$as_me:$LINENO: checking $ac_header presence" >&5
13947 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13948 cat >conftest.$ac_ext <<_ACEOF
13949 #line $LINENO "configure"
13950 /* confdefs.h.  */
13951 _ACEOF
13952 cat confdefs.h >>conftest.$ac_ext
13953 cat >>conftest.$ac_ext <<_ACEOF
13954 /* end confdefs.h.  */
13955 #include <$ac_header>
13956 _ACEOF
13957 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13958   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13959   ac_status=$?
13960   grep -v '^ *+' conftest.er1 >conftest.err
13961   rm -f conftest.er1
13962   cat conftest.err >&5
13963   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13964   (exit $ac_status); } >/dev/null; then
13965   if test -s conftest.err; then
13966     ac_cpp_err=$ac_c_preproc_warn_flag
13967   else
13968     ac_cpp_err=
13969   fi
13970 else
13971   ac_cpp_err=yes
13972 fi
13973 if test -z "$ac_cpp_err"; then
13974   ac_header_preproc=yes
13975 else
13976   echo "$as_me: failed program was:" >&5
13977 sed 's/^/| /' conftest.$ac_ext >&5
13978
13979   ac_header_preproc=no
13980 fi
13981 rm -f conftest.err conftest.$ac_ext
13982 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13983 echo "${ECHO_T}$ac_header_preproc" >&6
13984
13985 # So?  What about this header?
13986 case $ac_header_compiler:$ac_header_preproc in
13987   yes:no )
13988     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13989 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13990     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13991 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13992     (
13993       cat <<\_ASBOX
13994 ## ------------------------------------ ##
13995 ## Report this to bug-autoconf@gnu.org. ##
13996 ## ------------------------------------ ##
13997 _ASBOX
13998     ) |
13999       sed "s/^/$as_me: WARNING:     /" >&2
14000     ;;
14001   no:yes )
14002     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14003 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14004     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
14005 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
14006     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14007 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14008     (
14009       cat <<\_ASBOX
14010 ## ------------------------------------ ##
14011 ## Report this to bug-autoconf@gnu.org. ##
14012 ## ------------------------------------ ##
14013 _ASBOX
14014     ) |
14015       sed "s/^/$as_me: WARNING:     /" >&2
14016     ;;
14017 esac
14018 echo "$as_me:$LINENO: checking for $ac_header" >&5
14019 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14020 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14021   echo $ECHO_N "(cached) $ECHO_C" >&6
14022 else
14023   eval "$as_ac_Header=$ac_header_preproc"
14024 fi
14025 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14026 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14027
14028 fi
14029 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14030   cat >>confdefs.h <<_ACEOF
14031 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14032 _ACEOF
14033
14034 fi
14035
14036 done
14037
14038                 if test $ac_cv_header_heim_err_h = yes ; then
14039                         krb5_impl=heimdal
14040                 else
14041                         krb5_impl=mit
14042                 fi
14043
14044                 if test $krb5_impl = mit; then
14045                         echo "$as_me:$LINENO: checking for main in -lk5crypto" >&5
14046 echo $ECHO_N "checking for main in -lk5crypto... $ECHO_C" >&6
14047 if test "${ac_cv_lib_k5crypto_main+set}" = set; then
14048   echo $ECHO_N "(cached) $ECHO_C" >&6
14049 else
14050   ac_check_lib_save_LIBS=$LIBS
14051 LIBS="-lk5crypto  $LIBS"
14052 cat >conftest.$ac_ext <<_ACEOF
14053 #line $LINENO "configure"
14054 /* confdefs.h.  */
14055 _ACEOF
14056 cat confdefs.h >>conftest.$ac_ext
14057 cat >>conftest.$ac_ext <<_ACEOF
14058 /* end confdefs.h.  */
14059
14060
14061 int
14062 main ()
14063 {
14064 main ();
14065   ;
14066   return 0;
14067 }
14068 _ACEOF
14069 rm -f conftest.$ac_objext conftest$ac_exeext
14070 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14071   (eval $ac_link) 2>&5
14072   ac_status=$?
14073   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14074   (exit $ac_status); } &&
14075          { ac_try='test -s conftest$ac_exeext'
14076   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14077   (eval $ac_try) 2>&5
14078   ac_status=$?
14079   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14080   (exit $ac_status); }; }; then
14081   ac_cv_lib_k5crypto_main=yes
14082 else
14083   echo "$as_me: failed program was:" >&5
14084 sed 's/^/| /' conftest.$ac_ext >&5
14085
14086 ac_cv_lib_k5crypto_main=no
14087 fi
14088 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14089 LIBS=$ac_check_lib_save_LIBS
14090 fi
14091 echo "$as_me:$LINENO: result: $ac_cv_lib_k5crypto_main" >&5
14092 echo "${ECHO_T}$ac_cv_lib_k5crypto_main" >&6
14093 if test $ac_cv_lib_k5crypto_main = yes; then
14094   krb5crypto=k5crypto
14095 else
14096   krb5crypto=crypto
14097 fi
14098
14099
14100                         echo "$as_me:$LINENO: checking for main in -lkrb5" >&5
14101 echo $ECHO_N "checking for main in -lkrb5... $ECHO_C" >&6
14102 if test "${ac_cv_lib_krb5_main+set}" = set; then
14103   echo $ECHO_N "(cached) $ECHO_C" >&6
14104 else
14105   ac_check_lib_save_LIBS=$LIBS
14106 LIBS="-lkrb5 -l$krb5crypto -lcom_err $LIBS"
14107 cat >conftest.$ac_ext <<_ACEOF
14108 #line $LINENO "configure"
14109 /* confdefs.h.  */
14110 _ACEOF
14111 cat confdefs.h >>conftest.$ac_ext
14112 cat >>conftest.$ac_ext <<_ACEOF
14113 /* end confdefs.h.  */
14114
14115
14116 int
14117 main ()
14118 {
14119 main ();
14120   ;
14121   return 0;
14122 }
14123 _ACEOF
14124 rm -f conftest.$ac_objext conftest$ac_exeext
14125 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14126   (eval $ac_link) 2>&5
14127   ac_status=$?
14128   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14129   (exit $ac_status); } &&
14130          { ac_try='test -s conftest$ac_exeext'
14131   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14132   (eval $ac_try) 2>&5
14133   ac_status=$?
14134   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14135   (exit $ac_status); }; }; then
14136   ac_cv_lib_krb5_main=yes
14137 else
14138   echo "$as_me: failed program was:" >&5
14139 sed 's/^/| /' conftest.$ac_ext >&5
14140
14141 ac_cv_lib_krb5_main=no
14142 fi
14143 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14144 LIBS=$ac_check_lib_save_LIBS
14145 fi
14146 echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_main" >&5
14147 echo "${ECHO_T}$ac_cv_lib_krb5_main" >&6
14148 if test $ac_cv_lib_krb5_main = yes; then
14149   have_krb5=yes
14150                                 KRB5_LIBS="-lkrb5 -l$krb5crypto -lcom_err"
14151 else
14152   have_krb5=no
14153 fi
14154
14155
14156                 elif test $krb5_impl = heimdal; then
14157                         echo "$as_me:$LINENO: checking for main in -ldes" >&5
14158 echo $ECHO_N "checking for main in -ldes... $ECHO_C" >&6
14159 if test "${ac_cv_lib_des_main+set}" = set; then
14160   echo $ECHO_N "(cached) $ECHO_C" >&6
14161 else
14162   ac_check_lib_save_LIBS=$LIBS
14163 LIBS="-ldes  $LIBS"
14164 cat >conftest.$ac_ext <<_ACEOF
14165 #line $LINENO "configure"
14166 /* confdefs.h.  */
14167 _ACEOF
14168 cat confdefs.h >>conftest.$ac_ext
14169 cat >>conftest.$ac_ext <<_ACEOF
14170 /* end confdefs.h.  */
14171
14172
14173 int
14174 main ()
14175 {
14176 main ();
14177   ;
14178   return 0;
14179 }
14180 _ACEOF
14181 rm -f conftest.$ac_objext conftest$ac_exeext
14182 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14183   (eval $ac_link) 2>&5
14184   ac_status=$?
14185   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14186   (exit $ac_status); } &&
14187          { ac_try='test -s conftest$ac_exeext'
14188   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14189   (eval $ac_try) 2>&5
14190   ac_status=$?
14191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14192   (exit $ac_status); }; }; then
14193   ac_cv_lib_des_main=yes
14194 else
14195   echo "$as_me: failed program was:" >&5
14196 sed 's/^/| /' conftest.$ac_ext >&5
14197
14198 ac_cv_lib_des_main=no
14199 fi
14200 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14201 LIBS=$ac_check_lib_save_LIBS
14202 fi
14203 echo "$as_me:$LINENO: result: $ac_cv_lib_des_main" >&5
14204 echo "${ECHO_T}$ac_cv_lib_des_main" >&6
14205 if test $ac_cv_lib_des_main = yes; then
14206   krb5crypto=des
14207 else
14208   krb5crypto=crypto
14209 fi
14210
14211
14212                         echo "$as_me:$LINENO: checking for main in -lkrb5" >&5
14213 echo $ECHO_N "checking for main in -lkrb5... $ECHO_C" >&6
14214 if test "${ac_cv_lib_krb5_main+set}" = set; then
14215   echo $ECHO_N "(cached) $ECHO_C" >&6
14216 else
14217   ac_check_lib_save_LIBS=$LIBS
14218 LIBS="-lkrb5 -l$krb5crypto -lasn1 -lroken -lcom_err $LIBS"
14219 cat >conftest.$ac_ext <<_ACEOF
14220 #line $LINENO "configure"
14221 /* confdefs.h.  */
14222 _ACEOF
14223 cat confdefs.h >>conftest.$ac_ext
14224 cat >>conftest.$ac_ext <<_ACEOF
14225 /* end confdefs.h.  */
14226
14227
14228 int
14229 main ()
14230 {
14231 main ();
14232   ;
14233   return 0;
14234 }
14235 _ACEOF
14236 rm -f conftest.$ac_objext conftest$ac_exeext
14237 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14238   (eval $ac_link) 2>&5
14239   ac_status=$?
14240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14241   (exit $ac_status); } &&
14242          { ac_try='test -s conftest$ac_exeext'
14243   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14244   (eval $ac_try) 2>&5
14245   ac_status=$?
14246   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14247   (exit $ac_status); }; }; then
14248   ac_cv_lib_krb5_main=yes
14249 else
14250   echo "$as_me: failed program was:" >&5
14251 sed 's/^/| /' conftest.$ac_ext >&5
14252
14253 ac_cv_lib_krb5_main=no
14254 fi
14255 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14256 LIBS=$ac_check_lib_save_LIBS
14257 fi
14258 echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_main" >&5
14259 echo "${ECHO_T}$ac_cv_lib_krb5_main" >&6
14260 if test $ac_cv_lib_krb5_main = yes; then
14261   have_krb5=yes
14262                                 KRB5_LIBS="-lkrb5 -l$krb5crypto -lasn1 -lroken -lcom_err"
14263 else
14264   have_krb5=no
14265 fi
14266
14267
14268
14269 cat >>confdefs.h <<\_ACEOF
14270 #define HAVE_HEIMDAL_KERBEROS 1
14271 _ACEOF
14272
14273
14274                 else
14275                         have_krb5=no
14276                         { echo "$as_me:$LINENO: WARNING: Unrecognized Kerberos5 Implementation" >&5
14277 echo "$as_me: WARNING: Unrecognized Kerberos5 Implementation" >&2;}
14278                 fi
14279
14280                 if test $have_krb5 = yes ; then
14281                         ol_link_krb5=yes
14282
14283
14284 cat >>confdefs.h <<\_ACEOF
14285 #define HAVE_KRB5 1
14286 _ACEOF
14287
14288
14289                         if test $ol_enable_kpasswd != no ; then
14290                                 ol_link_kpasswd=yes;
14291                         fi
14292
14293                         if test $ol_with_kerberos = k5only ; then
14294                                 ol_with_kerberos=found
14295                         fi
14296
14297                 elif test $ol_with_kerberos != auto ; then
14298                         { { echo "$as_me:$LINENO: error: Required Kerberos 5 support not available" >&5
14299 echo "$as_me: error: Required Kerberos 5 support not available" >&2;}
14300    { (exit 1); exit 1; }; }
14301                 fi
14302
14303         fi
14304 fi
14305
14306 if test $ol_link_krb5 = yes -a \( $ol_with_kerberos = yes -o \
14307         $ol_with_kerberos = auto -o $ol_with_kerberos = k425 \) ; then
14308
14309
14310
14311 for ac_header in kerberosIV/krb.h kerberosIV/des.h
14312 do
14313 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14314 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14315   echo "$as_me:$LINENO: checking for $ac_header" >&5
14316 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14317 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14318   echo $ECHO_N "(cached) $ECHO_C" >&6
14319 fi
14320 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14321 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14322 else
14323   # Is the header compilable?
14324 echo "$as_me:$LINENO: checking $ac_header usability" >&5
14325 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
14326 cat >conftest.$ac_ext <<_ACEOF
14327 #line $LINENO "configure"
14328 /* confdefs.h.  */
14329 _ACEOF
14330 cat confdefs.h >>conftest.$ac_ext
14331 cat >>conftest.$ac_ext <<_ACEOF
14332 /* end confdefs.h.  */
14333 $ac_includes_default
14334 #include <$ac_header>
14335 _ACEOF
14336 rm -f conftest.$ac_objext
14337 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14338   (eval $ac_compile) 2>&5
14339   ac_status=$?
14340   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14341   (exit $ac_status); } &&
14342          { ac_try='test -s conftest.$ac_objext'
14343   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14344   (eval $ac_try) 2>&5
14345   ac_status=$?
14346   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14347   (exit $ac_status); }; }; then
14348   ac_header_compiler=yes
14349 else
14350   echo "$as_me: failed program was:" >&5
14351 sed 's/^/| /' conftest.$ac_ext >&5
14352
14353 ac_header_compiler=no
14354 fi
14355 rm -f conftest.$ac_objext conftest.$ac_ext
14356 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14357 echo "${ECHO_T}$ac_header_compiler" >&6
14358
14359 # Is the header present?
14360 echo "$as_me:$LINENO: checking $ac_header presence" >&5
14361 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
14362 cat >conftest.$ac_ext <<_ACEOF
14363 #line $LINENO "configure"
14364 /* confdefs.h.  */
14365 _ACEOF
14366 cat confdefs.h >>conftest.$ac_ext
14367 cat >>conftest.$ac_ext <<_ACEOF
14368 /* end confdefs.h.  */
14369 #include <$ac_header>
14370 _ACEOF
14371 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
14372   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14373   ac_status=$?
14374   grep -v '^ *+' conftest.er1 >conftest.err
14375   rm -f conftest.er1
14376   cat conftest.err >&5
14377   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14378   (exit $ac_status); } >/dev/null; then
14379   if test -s conftest.err; then
14380     ac_cpp_err=$ac_c_preproc_warn_flag
14381   else
14382     ac_cpp_err=
14383   fi
14384 else
14385   ac_cpp_err=yes
14386 fi
14387 if test -z "$ac_cpp_err"; then
14388   ac_header_preproc=yes
14389 else
14390   echo "$as_me: failed program was:" >&5
14391 sed 's/^/| /' conftest.$ac_ext >&5
14392
14393   ac_header_preproc=no
14394 fi
14395 rm -f conftest.err conftest.$ac_ext
14396 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14397 echo "${ECHO_T}$ac_header_preproc" >&6
14398
14399 # So?  What about this header?
14400 case $ac_header_compiler:$ac_header_preproc in
14401   yes:no )
14402     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14403 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14404     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14405 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14406     (
14407       cat <<\_ASBOX
14408 ## ------------------------------------ ##
14409 ## Report this to bug-autoconf@gnu.org. ##
14410 ## ------------------------------------ ##
14411 _ASBOX
14412     ) |
14413       sed "s/^/$as_me: WARNING:     /" >&2
14414     ;;
14415   no:yes )
14416     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14417 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14418     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
14419 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
14420     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14421 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14422     (
14423       cat <<\_ASBOX
14424 ## ------------------------------------ ##
14425 ## Report this to bug-autoconf@gnu.org. ##
14426 ## ------------------------------------ ##
14427 _ASBOX
14428     ) |
14429       sed "s/^/$as_me: WARNING:     /" >&2
14430     ;;
14431 esac
14432 echo "$as_me:$LINENO: checking for $ac_header" >&5
14433 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14434 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14435   echo $ECHO_N "(cached) $ECHO_C" >&6
14436 else
14437   eval "$as_ac_Header=$ac_header_preproc"
14438 fi
14439 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14440 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14441
14442 fi
14443 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14444   cat >>confdefs.h <<_ACEOF
14445 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14446 _ACEOF
14447
14448 fi
14449
14450 done
14451
14452
14453         if test $ac_cv_header_kerberosIV_krb_h = yes ; then
14454                 if test $krb5_impl = mit; then
14455                         echo "$as_me:$LINENO: checking for main in -lkrb4" >&5
14456 echo $ECHO_N "checking for main in -lkrb4... $ECHO_C" >&6
14457 if test "${ac_cv_lib_krb4_main+set}" = set; then
14458   echo $ECHO_N "(cached) $ECHO_C" >&6
14459 else
14460   ac_check_lib_save_LIBS=$LIBS
14461 LIBS="-lkrb4 -ldes425 -lkrb5 -l$krb5crypto -lcom_err $LIBS"
14462 cat >conftest.$ac_ext <<_ACEOF
14463 #line $LINENO "configure"
14464 /* confdefs.h.  */
14465 _ACEOF
14466 cat confdefs.h >>conftest.$ac_ext
14467 cat >>conftest.$ac_ext <<_ACEOF
14468 /* end confdefs.h.  */
14469
14470
14471 int
14472 main ()
14473 {
14474 main ();
14475   ;
14476   return 0;
14477 }
14478 _ACEOF
14479 rm -f conftest.$ac_objext conftest$ac_exeext
14480 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14481   (eval $ac_link) 2>&5
14482   ac_status=$?
14483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14484   (exit $ac_status); } &&
14485          { ac_try='test -s conftest$ac_exeext'
14486   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14487   (eval $ac_try) 2>&5
14488   ac_status=$?
14489   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14490   (exit $ac_status); }; }; then
14491   ac_cv_lib_krb4_main=yes
14492 else
14493   echo "$as_me: failed program was:" >&5
14494 sed 's/^/| /' conftest.$ac_ext >&5
14495
14496 ac_cv_lib_krb4_main=no
14497 fi
14498 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14499 LIBS=$ac_check_lib_save_LIBS
14500 fi
14501 echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_main" >&5
14502 echo "${ECHO_T}$ac_cv_lib_krb4_main" >&6
14503 if test $ac_cv_lib_krb4_main = yes; then
14504   have_k425=yes
14505                                 KRB4_LIBS="-lkrb4 -ldes425"
14506 else
14507   have_k425=no
14508 fi
14509
14510
14511                 elif test $krb5_impl = heimdal; then
14512                         echo "$as_me:$LINENO: checking for main in -lkrb4" >&5
14513 echo $ECHO_N "checking for main in -lkrb4... $ECHO_C" >&6
14514 if test "${ac_cv_lib_krb4_main+set}" = set; then
14515   echo $ECHO_N "(cached) $ECHO_C" >&6
14516 else
14517   ac_check_lib_save_LIBS=$LIBS
14518 LIBS="-lkrb4 -lkrb5 -l$krb5crypto -lasn1 -lroken -lcom_err $LIBS"
14519 cat >conftest.$ac_ext <<_ACEOF
14520 #line $LINENO "configure"
14521 /* confdefs.h.  */
14522 _ACEOF
14523 cat confdefs.h >>conftest.$ac_ext
14524 cat >>conftest.$ac_ext <<_ACEOF
14525 /* end confdefs.h.  */
14526
14527
14528 int
14529 main ()
14530 {
14531 main ();
14532   ;
14533   return 0;
14534 }
14535 _ACEOF
14536 rm -f conftest.$ac_objext conftest$ac_exeext
14537 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14538   (eval $ac_link) 2>&5
14539   ac_status=$?
14540   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14541   (exit $ac_status); } &&
14542          { ac_try='test -s conftest$ac_exeext'
14543   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14544   (eval $ac_try) 2>&5
14545   ac_status=$?
14546   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14547   (exit $ac_status); }; }; then
14548   ac_cv_lib_krb4_main=yes
14549 else
14550   echo "$as_me: failed program was:" >&5
14551 sed 's/^/| /' conftest.$ac_ext >&5
14552
14553 ac_cv_lib_krb4_main=no
14554 fi
14555 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14556 LIBS=$ac_check_lib_save_LIBS
14557 fi
14558 echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_main" >&5
14559 echo "${ECHO_T}$ac_cv_lib_krb4_main" >&6
14560 if test $ac_cv_lib_krb4_main = yes; then
14561   have_k425=yes
14562                                 KRB4_LIBS="-lkrb4"
14563 else
14564   have_k425=no
14565 fi
14566
14567
14568                 else
14569                         have_425=no
14570                         { echo "$as_me:$LINENO: WARNING: Unrecongized Kerberos V Implementation" >&5
14571 echo "$as_me: WARNING: Unrecongized Kerberos V Implementation" >&2;}
14572                 fi
14573
14574                 if test $have_k425 = yes ; then
14575                         ol_with_kerberos=found
14576                         ol_link_krb4=yes
14577
14578
14579 cat >>confdefs.h <<\_ACEOF
14580 #define HAVE_KRB425 1
14581 _ACEOF
14582
14583
14584 cat >>confdefs.h <<\_ACEOF
14585 #define HAVE_KRB4 1
14586 _ACEOF
14587
14588
14589                         echo "$as_me:$LINENO: checking for des_debug in Kerberos libraries" >&5
14590 echo $ECHO_N "checking for des_debug in Kerberos libraries... $ECHO_C" >&6
14591 if test "${ol_cv_var_des_debug+set}" = set; then
14592   echo $ECHO_N "(cached) $ECHO_C" >&6
14593 else
14594
14595                                                                 save_LIBS="$LIBS"
14596                                 LIBS="$KRB4_LIBS $KRB5_LIBS $LIBS"
14597                                 cat >conftest.$ac_ext <<_ACEOF
14598 #line $LINENO "configure"
14599 /* confdefs.h.  */
14600 _ACEOF
14601 cat confdefs.h >>conftest.$ac_ext
14602 cat >>conftest.$ac_ext <<_ACEOF
14603 /* end confdefs.h.  */
14604
14605 #include <kerberosIV/krb.h>
14606 #include <kerberosIV/des.h>
14607 extern int des_debug;
14608
14609 int
14610 main ()
14611 {
14612
14613 des_debug = 1;
14614
14615   ;
14616   return 0;
14617 }
14618 _ACEOF
14619 rm -f conftest.$ac_objext conftest$ac_exeext
14620 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14621   (eval $ac_link) 2>&5
14622   ac_status=$?
14623   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14624   (exit $ac_status); } &&
14625          { ac_try='test -s conftest$ac_exeext'
14626   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14627   (eval $ac_try) 2>&5
14628   ac_status=$?
14629   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14630   (exit $ac_status); }; }; then
14631   ol_cv_var_des_debug=yes
14632 else
14633   echo "$as_me: failed program was:" >&5
14634 sed 's/^/| /' conftest.$ac_ext >&5
14635
14636 ol_cv_var_des_debug=no
14637 fi
14638 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14639                                                                 LIBS="$save_LIBS"
14640
14641 fi
14642 echo "$as_me:$LINENO: result: $ol_cv_var_des_debug" >&5
14643 echo "${ECHO_T}$ol_cv_var_des_debug" >&6
14644
14645                         if test $ol_cv_var_des_debug = yes ; then
14646
14647 cat >>confdefs.h <<\_ACEOF
14648 #define HAVE_DES_DEBUG 1
14649 _ACEOF
14650
14651                         fi
14652
14653                         LIBS="$save_LIBS"
14654                 fi
14655         fi
14656 fi
14657
14658 if test $ol_link_krb5 = yes ; then
14659         ol_with_kerberos=found
14660 fi
14661
14662 if test $ol_with_kerberos = yes -o $ol_with_kerberos = auto \
14663         -o $ol_with_kerberos = k4 -o $ol_with_kerberos = kth ; then
14664
14665
14666
14667
14668 for ac_header in krb.h des.h krb-archaeology.h
14669 do
14670 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14671 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14672   echo "$as_me:$LINENO: checking for $ac_header" >&5
14673 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14674 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14675   echo $ECHO_N "(cached) $ECHO_C" >&6
14676 fi
14677 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14678 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14679 else
14680   # Is the header compilable?
14681 echo "$as_me:$LINENO: checking $ac_header usability" >&5
14682 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
14683 cat >conftest.$ac_ext <<_ACEOF
14684 #line $LINENO "configure"
14685 /* confdefs.h.  */
14686 _ACEOF
14687 cat confdefs.h >>conftest.$ac_ext
14688 cat >>conftest.$ac_ext <<_ACEOF
14689 /* end confdefs.h.  */
14690 $ac_includes_default
14691 #include <$ac_header>
14692 _ACEOF
14693 rm -f conftest.$ac_objext
14694 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14695   (eval $ac_compile) 2>&5
14696   ac_status=$?
14697   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14698   (exit $ac_status); } &&
14699          { ac_try='test -s conftest.$ac_objext'
14700   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14701   (eval $ac_try) 2>&5
14702   ac_status=$?
14703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14704   (exit $ac_status); }; }; then
14705   ac_header_compiler=yes
14706 else
14707   echo "$as_me: failed program was:" >&5
14708 sed 's/^/| /' conftest.$ac_ext >&5
14709
14710 ac_header_compiler=no
14711 fi
14712 rm -f conftest.$ac_objext conftest.$ac_ext
14713 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14714 echo "${ECHO_T}$ac_header_compiler" >&6
14715
14716 # Is the header present?
14717 echo "$as_me:$LINENO: checking $ac_header presence" >&5
14718 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
14719 cat >conftest.$ac_ext <<_ACEOF
14720 #line $LINENO "configure"
14721 /* confdefs.h.  */
14722 _ACEOF
14723 cat confdefs.h >>conftest.$ac_ext
14724 cat >>conftest.$ac_ext <<_ACEOF
14725 /* end confdefs.h.  */
14726 #include <$ac_header>
14727 _ACEOF
14728 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
14729   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14730   ac_status=$?
14731   grep -v '^ *+' conftest.er1 >conftest.err
14732   rm -f conftest.er1
14733   cat conftest.err >&5
14734   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14735   (exit $ac_status); } >/dev/null; then
14736   if test -s conftest.err; then
14737     ac_cpp_err=$ac_c_preproc_warn_flag
14738   else
14739     ac_cpp_err=
14740   fi
14741 else
14742   ac_cpp_err=yes
14743 fi
14744 if test -z "$ac_cpp_err"; then
14745   ac_header_preproc=yes
14746 else
14747   echo "$as_me: failed program was:" >&5
14748 sed 's/^/| /' conftest.$ac_ext >&5
14749
14750   ac_header_preproc=no
14751 fi
14752 rm -f conftest.err conftest.$ac_ext
14753 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14754 echo "${ECHO_T}$ac_header_preproc" >&6
14755
14756 # So?  What about this header?
14757 case $ac_header_compiler:$ac_header_preproc in
14758   yes:no )
14759     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14760 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14761     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14762 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14763     (
14764       cat <<\_ASBOX
14765 ## ------------------------------------ ##
14766 ## Report this to bug-autoconf@gnu.org. ##
14767 ## ------------------------------------ ##
14768 _ASBOX
14769     ) |
14770       sed "s/^/$as_me: WARNING:     /" >&2
14771     ;;
14772   no:yes )
14773     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14774 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14775     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
14776 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
14777     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14778 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14779     (
14780       cat <<\_ASBOX
14781 ## ------------------------------------ ##
14782 ## Report this to bug-autoconf@gnu.org. ##
14783 ## ------------------------------------ ##
14784 _ASBOX
14785     ) |
14786       sed "s/^/$as_me: WARNING:     /" >&2
14787     ;;
14788 esac
14789 echo "$as_me:$LINENO: checking for $ac_header" >&5
14790 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14791 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14792   echo $ECHO_N "(cached) $ECHO_C" >&6
14793 else
14794   eval "$as_ac_Header=$ac_header_preproc"
14795 fi
14796 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14797 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14798
14799 fi
14800 if test `eval echo '${'$as_ac_Header'}'` = yes; then
14801   cat >>confdefs.h <<_ACEOF
14802 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
14803 _ACEOF
14804
14805 fi
14806
14807 done
14808
14809
14810         if test $ac_cv_header_krb_h = yes ; then
14811                 echo "$as_me:$LINENO: checking for main in -lkrb" >&5
14812 echo $ECHO_N "checking for main in -lkrb... $ECHO_C" >&6
14813 if test "${ac_cv_lib_krb_main+set}" = set; then
14814   echo $ECHO_N "(cached) $ECHO_C" >&6
14815 else
14816   ac_check_lib_save_LIBS=$LIBS
14817 LIBS="-lkrb -ldes $LIBS"
14818 cat >conftest.$ac_ext <<_ACEOF
14819 #line $LINENO "configure"
14820 /* confdefs.h.  */
14821 _ACEOF
14822 cat confdefs.h >>conftest.$ac_ext
14823 cat >>conftest.$ac_ext <<_ACEOF
14824 /* end confdefs.h.  */
14825
14826
14827 int
14828 main ()
14829 {
14830 main ();
14831   ;
14832   return 0;
14833 }
14834 _ACEOF
14835 rm -f conftest.$ac_objext conftest$ac_exeext
14836 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14837   (eval $ac_link) 2>&5
14838   ac_status=$?
14839   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14840   (exit $ac_status); } &&
14841          { ac_try='test -s conftest$ac_exeext'
14842   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14843   (eval $ac_try) 2>&5
14844   ac_status=$?
14845   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14846   (exit $ac_status); }; }; then
14847   ac_cv_lib_krb_main=yes
14848 else
14849   echo "$as_me: failed program was:" >&5
14850 sed 's/^/| /' conftest.$ac_ext >&5
14851
14852 ac_cv_lib_krb_main=no
14853 fi
14854 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14855 LIBS=$ac_check_lib_save_LIBS
14856 fi
14857 echo "$as_me:$LINENO: result: $ac_cv_lib_krb_main" >&5
14858 echo "${ECHO_T}$ac_cv_lib_krb_main" >&6
14859 if test $ac_cv_lib_krb_main = yes; then
14860   have_k4=yes
14861 else
14862   have_k4=no
14863 fi
14864
14865
14866                 if test $have_k4 = yes ; then
14867                         ol_with_kerberos=found
14868                         ol_link_krb4=yes
14869
14870
14871 cat >>confdefs.h <<\_ACEOF
14872 #define HAVE_KRB4 1
14873 _ACEOF
14874
14875
14876                         KRB4_LIBS="-lkrb -ldes"
14877
14878                         if test $ac_cv_header_krb_archaeology_h = yes ; then
14879
14880 cat >>confdefs.h <<\_ACEOF
14881 #define HAVE_KTH_KERBEROS 1
14882 _ACEOF
14883
14884                         fi
14885                 fi
14886         fi
14887 fi
14888
14889 if test $ol_link_krb4 = yes -a $ol_enable_kpasswd != no ; then
14890         ol_link_kpasswd=yes
14891 fi
14892
14893 if test $ol_link_krb4 = yes -a $ol_enable_kbind != no ; then
14894         ol_link_kbind=yes
14895
14896 elif test $ol_enable_kbind = yes ; then
14897         { { echo "$as_me:$LINENO: error: Kerberos IV detection failed" >&5
14898 echo "$as_me: error: Kerberos IV detection failed" >&2;}
14899    { (exit 1); exit 1; }; }
14900 fi
14901
14902 if test $ol_link_krb4 = yes -o $ol_link_krb5 = yes ; then
14903
14904 cat >>confdefs.h <<\_ACEOF
14905 #define HAVE_KERBEROS 1
14906 _ACEOF
14907
14908
14909 elif test $ol_with_kerberos != auto -a $ol_with_kerberos != no ; then
14910         { { echo "$as_me:$LINENO: error: Kerberos detection failed" >&5
14911 echo "$as_me: error: Kerberos detection failed" >&2;}
14912    { (exit 1); exit 1; }; }
14913 fi
14914
14915 ol_link_tls=no
14916 if test $ol_with_tls != no ; then
14917
14918
14919 for ac_header in openssl/ssl.h ssl.h
14920 do
14921 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
14922 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14923   echo "$as_me:$LINENO: checking for $ac_header" >&5
14924 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14925 if eval "test \"\${$as_ac_Header+set}\" = set"; then
14926   echo $ECHO_N "(cached) $ECHO_C" >&6
14927 fi
14928 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14929 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
14930 else
14931   # Is the header compilable?
14932 echo "$as_me:$LINENO: checking $ac_header usability" >&5
14933 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
14934 cat >conftest.$ac_ext <<_ACEOF
14935 #line $LINENO "configure"
14936 /* confdefs.h.  */
14937 _ACEOF
14938 cat confdefs.h >>conftest.$ac_ext
14939 cat >>conftest.$ac_ext <<_ACEOF
14940 /* end confdefs.h.  */
14941 $ac_includes_default
14942 #include <$ac_header>
14943 _ACEOF
14944 rm -f conftest.$ac_objext
14945 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14946   (eval $ac_compile) 2>&5
14947   ac_status=$?
14948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14949   (exit $ac_status); } &&
14950          { ac_try='test -s conftest.$ac_objext'
14951   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14952   (eval $ac_try) 2>&5
14953   ac_status=$?
14954   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14955   (exit $ac_status); }; }; then
14956   ac_header_compiler=yes
14957 else
14958   echo "$as_me: failed program was:" >&5
14959 sed 's/^/| /' conftest.$ac_ext >&5
14960
14961 ac_header_compiler=no
14962 fi
14963 rm -f conftest.$ac_objext conftest.$ac_ext
14964 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14965 echo "${ECHO_T}$ac_header_compiler" >&6
14966
14967 # Is the header present?
14968 echo "$as_me:$LINENO: checking $ac_header presence" >&5
14969 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
14970 cat >conftest.$ac_ext <<_ACEOF
14971 #line $LINENO "configure"
14972 /* confdefs.h.  */
14973 _ACEOF
14974 cat confdefs.h >>conftest.$ac_ext
14975 cat >>conftest.$ac_ext <<_ACEOF
14976 /* end confdefs.h.  */
14977 #include <$ac_header>
14978 _ACEOF
14979 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
14980   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14981   ac_status=$?
14982   grep -v '^ *+' conftest.er1 >conftest.err
14983   rm -f conftest.er1
14984   cat conftest.err >&5
14985   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14986   (exit $ac_status); } >/dev/null; then
14987   if test -s conftest.err; then
14988     ac_cpp_err=$ac_c_preproc_warn_flag
14989   else
14990     ac_cpp_err=
14991   fi
14992 else
14993   ac_cpp_err=yes
14994 fi
14995 if test -z "$ac_cpp_err"; then
14996   ac_header_preproc=yes
14997 else
14998   echo "$as_me: failed program was:" >&5
14999 sed 's/^/| /' conftest.$ac_ext >&5
15000
15001   ac_header_preproc=no
15002 fi
15003 rm -f conftest.err conftest.$ac_ext
15004 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15005 echo "${ECHO_T}$ac_header_preproc" >&6
15006
15007 # So?  What about this header?
15008 case $ac_header_compiler:$ac_header_preproc in
15009   yes:no )
15010     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15011 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15012     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15013 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15014     (
15015       cat <<\_ASBOX
15016 ## ------------------------------------ ##
15017 ## Report this to bug-autoconf@gnu.org. ##
15018 ## ------------------------------------ ##
15019 _ASBOX
15020     ) |
15021       sed "s/^/$as_me: WARNING:     /" >&2
15022     ;;
15023   no:yes )
15024     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15025 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15026     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15027 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15028     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15029 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15030     (
15031       cat <<\_ASBOX
15032 ## ------------------------------------ ##
15033 ## Report this to bug-autoconf@gnu.org. ##
15034 ## ------------------------------------ ##
15035 _ASBOX
15036     ) |
15037       sed "s/^/$as_me: WARNING:     /" >&2
15038     ;;
15039 esac
15040 echo "$as_me:$LINENO: checking for $ac_header" >&5
15041 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15042 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15043   echo $ECHO_N "(cached) $ECHO_C" >&6
15044 else
15045   eval "$as_ac_Header=$ac_header_preproc"
15046 fi
15047 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15048 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15049
15050 fi
15051 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15052   cat >>confdefs.h <<_ACEOF
15053 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15054 _ACEOF
15055
15056 fi
15057
15058 done
15059
15060
15061         if test $ac_cv_header_openssl_ssl_h = yes \
15062                 -o $ac_cv_header_ssl_h = yes ; then
15063                 echo "$as_me:$LINENO: checking for SSLeay_add_ssl_algorithms in -lssl" >&5
15064 echo $ECHO_N "checking for SSLeay_add_ssl_algorithms in -lssl... $ECHO_C" >&6
15065 if test "${ac_cv_lib_ssl_SSLeay_add_ssl_algorithms+set}" = set; then
15066   echo $ECHO_N "(cached) $ECHO_C" >&6
15067 else
15068   ac_check_lib_save_LIBS=$LIBS
15069 LIBS="-lssl -lcrypto $LIBS"
15070 cat >conftest.$ac_ext <<_ACEOF
15071 #line $LINENO "configure"
15072 /* confdefs.h.  */
15073 _ACEOF
15074 cat confdefs.h >>conftest.$ac_ext
15075 cat >>conftest.$ac_ext <<_ACEOF
15076 /* end confdefs.h.  */
15077
15078 /* Override any gcc2 internal prototype to avoid an error.  */
15079 #ifdef __cplusplus
15080 extern "C"
15081 #endif
15082 /* We use char because int might match the return type of a gcc2
15083    builtin and then its argument prototype would still apply.  */
15084 char SSLeay_add_ssl_algorithms ();
15085 int
15086 main ()
15087 {
15088 SSLeay_add_ssl_algorithms ();
15089   ;
15090   return 0;
15091 }
15092 _ACEOF
15093 rm -f conftest.$ac_objext conftest$ac_exeext
15094 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15095   (eval $ac_link) 2>&5
15096   ac_status=$?
15097   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15098   (exit $ac_status); } &&
15099          { ac_try='test -s conftest$ac_exeext'
15100   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15101   (eval $ac_try) 2>&5
15102   ac_status=$?
15103   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15104   (exit $ac_status); }; }; then
15105   ac_cv_lib_ssl_SSLeay_add_ssl_algorithms=yes
15106 else
15107   echo "$as_me: failed program was:" >&5
15108 sed 's/^/| /' conftest.$ac_ext >&5
15109
15110 ac_cv_lib_ssl_SSLeay_add_ssl_algorithms=no
15111 fi
15112 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15113 LIBS=$ac_check_lib_save_LIBS
15114 fi
15115 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSLeay_add_ssl_algorithms" >&5
15116 echo "${ECHO_T}$ac_cv_lib_ssl_SSLeay_add_ssl_algorithms" >&6
15117 if test $ac_cv_lib_ssl_SSLeay_add_ssl_algorithms = yes; then
15118   have_ssleay=yes
15119                         need_rsaref=no
15120 else
15121   have_ssleay=no
15122 fi
15123
15124
15125                 if test $have_ssleay = no ; then
15126                         echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
15127 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6
15128 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
15129   echo $ECHO_N "(cached) $ECHO_C" >&6
15130 else
15131   ac_check_lib_save_LIBS=$LIBS
15132 LIBS="-lssl -lcrypto $LIBS"
15133 cat >conftest.$ac_ext <<_ACEOF
15134 #line $LINENO "configure"
15135 /* confdefs.h.  */
15136 _ACEOF
15137 cat confdefs.h >>conftest.$ac_ext
15138 cat >>conftest.$ac_ext <<_ACEOF
15139 /* end confdefs.h.  */
15140
15141 /* Override any gcc2 internal prototype to avoid an error.  */
15142 #ifdef __cplusplus
15143 extern "C"
15144 #endif
15145 /* We use char because int might match the return type of a gcc2
15146    builtin and then its argument prototype would still apply.  */
15147 char SSL_library_init ();
15148 int
15149 main ()
15150 {
15151 SSL_library_init ();
15152   ;
15153   return 0;
15154 }
15155 _ACEOF
15156 rm -f conftest.$ac_objext conftest$ac_exeext
15157 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15158   (eval $ac_link) 2>&5
15159   ac_status=$?
15160   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15161   (exit $ac_status); } &&
15162          { ac_try='test -s conftest$ac_exeext'
15163   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15164   (eval $ac_try) 2>&5
15165   ac_status=$?
15166   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15167   (exit $ac_status); }; }; then
15168   ac_cv_lib_ssl_SSL_library_init=yes
15169 else
15170   echo "$as_me: failed program was:" >&5
15171 sed 's/^/| /' conftest.$ac_ext >&5
15172
15173 ac_cv_lib_ssl_SSL_library_init=no
15174 fi
15175 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15176 LIBS=$ac_check_lib_save_LIBS
15177 fi
15178 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
15179 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6
15180 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
15181   have_ssleay=yes
15182                                 need_rsaref=no
15183 else
15184   have_ssleay=no
15185 fi
15186
15187                 fi
15188
15189                 if test $have_ssleay = no ; then
15190                         echo "$as_me:$LINENO: checking for ssl3_accept in -lssl" >&5
15191 echo $ECHO_N "checking for ssl3_accept in -lssl... $ECHO_C" >&6
15192 if test "${ac_cv_lib_ssl_ssl3_accept+set}" = set; then
15193   echo $ECHO_N "(cached) $ECHO_C" >&6
15194 else
15195   ac_check_lib_save_LIBS=$LIBS
15196 LIBS="-lssl -lcrypto -lRSAglue -lrsaref $LIBS"
15197 cat >conftest.$ac_ext <<_ACEOF
15198 #line $LINENO "configure"
15199 /* confdefs.h.  */
15200 _ACEOF
15201 cat confdefs.h >>conftest.$ac_ext
15202 cat >>conftest.$ac_ext <<_ACEOF
15203 /* end confdefs.h.  */
15204
15205 /* Override any gcc2 internal prototype to avoid an error.  */
15206 #ifdef __cplusplus
15207 extern "C"
15208 #endif
15209 /* We use char because int might match the return type of a gcc2
15210    builtin and then its argument prototype would still apply.  */
15211 char ssl3_accept ();
15212 int
15213 main ()
15214 {
15215 ssl3_accept ();
15216   ;
15217   return 0;
15218 }
15219 _ACEOF
15220 rm -f conftest.$ac_objext conftest$ac_exeext
15221 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15222   (eval $ac_link) 2>&5
15223   ac_status=$?
15224   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15225   (exit $ac_status); } &&
15226          { ac_try='test -s conftest$ac_exeext'
15227   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15228   (eval $ac_try) 2>&5
15229   ac_status=$?
15230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15231   (exit $ac_status); }; }; then
15232   ac_cv_lib_ssl_ssl3_accept=yes
15233 else
15234   echo "$as_me: failed program was:" >&5
15235 sed 's/^/| /' conftest.$ac_ext >&5
15236
15237 ac_cv_lib_ssl_ssl3_accept=no
15238 fi
15239 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15240 LIBS=$ac_check_lib_save_LIBS
15241 fi
15242 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_ssl3_accept" >&5
15243 echo "${ECHO_T}$ac_cv_lib_ssl_ssl3_accept" >&6
15244 if test $ac_cv_lib_ssl_ssl3_accept = yes; then
15245   have_ssleay=yes
15246                                 need_rsaref=yes
15247 else
15248   have_ssleay=no
15249 fi
15250
15251                 fi
15252
15253                 if test $have_ssleay = yes ; then
15254                         ol_with_tls=found
15255                         ol_link_tls=yes
15256
15257
15258 cat >>confdefs.h <<\_ACEOF
15259 #define HAVE_SSLEAY 1
15260 _ACEOF
15261
15262
15263                         if test $need_rsaref = yes; then
15264
15265 cat >>confdefs.h <<\_ACEOF
15266 #define HAVE_RSAREF 1
15267 _ACEOF
15268
15269
15270                                 TLS_LIBS="-lssl -lcrypto -lRSAglue -lrsaref"
15271                         else
15272                                 TLS_LIBS="-lssl -lcrypto"
15273                         fi
15274                 fi
15275         fi
15276
15277 else
15278         { echo "$as_me:$LINENO: WARNING: TLS data protection not supported!" >&5
15279 echo "$as_me: WARNING: TLS data protection not supported!" >&2;}
15280 fi
15281
15282 if test $ol_link_tls = yes ; then
15283
15284 cat >>confdefs.h <<\_ACEOF
15285 #define HAVE_TLS 1
15286 _ACEOF
15287
15288
15289 elif test $ol_with_tls = auto ; then
15290         { echo "$as_me:$LINENO: WARNING: Could not locate TLS/SSL package" >&5
15291 echo "$as_me: WARNING: Could not locate TLS/SSL package" >&2;}
15292         { echo "$as_me:$LINENO: WARNING: TLS data protection not supported!" >&5
15293 echo "$as_me: WARNING: TLS data protection not supported!" >&2;}
15294
15295 elif test $ol_with_tls != no ; then
15296         { { echo "$as_me:$LINENO: error: Could not locate TLS/SSL package" >&5
15297 echo "$as_me: error: Could not locate TLS/SSL package" >&2;}
15298    { (exit 1); exit 1; }; }
15299 fi
15300
15301 if test $ol_enable_lmpasswd != no; then
15302         if test $ol_link_tls != yes ; then
15303                 { { echo "$as_me:$LINENO: error: LAN Manager passwords require OpenSSL" >&5
15304 echo "$as_me: error: LAN Manager passwords require OpenSSL" >&2;}
15305    { (exit 1); exit 1; }; }
15306         fi
15307
15308
15309 cat >>confdefs.h <<\_ACEOF
15310 #define SLAPD_LMHASH 1
15311 _ACEOF
15312
15313 fi
15314
15315 ol_link_threads=no
15316
15317 if test $ol_with_threads = auto -o $ol_with_threads = yes \
15318         -o $ol_with_threads = nt ; then
15319
15320
15321         echo "$as_me:$LINENO: checking for _beginthread" >&5
15322 echo $ECHO_N "checking for _beginthread... $ECHO_C" >&6
15323 if test "${ac_cv_func__beginthread+set}" = set; then
15324   echo $ECHO_N "(cached) $ECHO_C" >&6
15325 else
15326   cat >conftest.$ac_ext <<_ACEOF
15327 #line $LINENO "configure"
15328 /* confdefs.h.  */
15329 _ACEOF
15330 cat confdefs.h >>conftest.$ac_ext
15331 cat >>conftest.$ac_ext <<_ACEOF
15332 /* end confdefs.h.  */
15333 /* System header to define __stub macros and hopefully few prototypes,
15334     which can conflict with char _beginthread (); below.
15335     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15336     <limits.h> exists even on freestanding compilers.  */
15337 #ifdef __STDC__
15338 # include <limits.h>
15339 #else
15340 # include <assert.h>
15341 #endif
15342 /* Override any gcc2 internal prototype to avoid an error.  */
15343 #ifdef __cplusplus
15344 extern "C"
15345 {
15346 #endif
15347 /* We use char because int might match the return type of a gcc2
15348    builtin and then its argument prototype would still apply.  */
15349 char _beginthread ();
15350 /* The GNU C library defines this for functions which it implements
15351     to always fail with ENOSYS.  Some functions are actually named
15352     something starting with __ and the normal name is an alias.  */
15353 #if defined (__stub__beginthread) || defined (__stub____beginthread)
15354 choke me
15355 #else
15356 char (*f) () = _beginthread;
15357 #endif
15358 #ifdef __cplusplus
15359 }
15360 #endif
15361
15362 int
15363 main ()
15364 {
15365 return f != _beginthread;
15366   ;
15367   return 0;
15368 }
15369 _ACEOF
15370 rm -f conftest.$ac_objext conftest$ac_exeext
15371 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15372   (eval $ac_link) 2>&5
15373   ac_status=$?
15374   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15375   (exit $ac_status); } &&
15376          { ac_try='test -s conftest$ac_exeext'
15377   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15378   (eval $ac_try) 2>&5
15379   ac_status=$?
15380   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15381   (exit $ac_status); }; }; then
15382   ac_cv_func__beginthread=yes
15383 else
15384   echo "$as_me: failed program was:" >&5
15385 sed 's/^/| /' conftest.$ac_ext >&5
15386
15387 ac_cv_func__beginthread=no
15388 fi
15389 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15390 fi
15391 echo "$as_me:$LINENO: result: $ac_cv_func__beginthread" >&5
15392 echo "${ECHO_T}$ac_cv_func__beginthread" >&6
15393
15394
15395         if test $ac_cv_func__beginthread = yes ; then
15396
15397 cat >>confdefs.h <<\_ACEOF
15398 #define HAVE_NT_THREADS 1
15399 _ACEOF
15400
15401                 ol_cv_nt_threads=yes
15402         fi
15403
15404
15405         if test "$ol_cv_nt_threads" = yes ; then
15406                 ol_link_threads=nt
15407                 ol_with_threads=found
15408                 ol_with_yielding_select=yes
15409
15410
15411 cat >>confdefs.h <<\_ACEOF
15412 #define HAVE_NT_SERVICE_MANAGER 1
15413 _ACEOF
15414
15415
15416 cat >>confdefs.h <<\_ACEOF
15417 #define HAVE_NT_EVENT_LOG 1
15418 _ACEOF
15419
15420         fi
15421
15422         if test $ol_with_threads = nt ; then
15423                 { { echo "$as_me:$LINENO: error: could not locate NT Threads" >&5
15424 echo "$as_me: error: could not locate NT Threads" >&2;}
15425    { (exit 1); exit 1; }; }
15426         fi
15427 fi
15428
15429 if test $ol_with_threads = auto -o $ol_with_threads = yes \
15430         -o $ol_with_threads = posix ; then
15431
15432
15433 for ac_header in pthread.h
15434 do
15435 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15436 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15437   echo "$as_me:$LINENO: checking for $ac_header" >&5
15438 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15439 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15440   echo $ECHO_N "(cached) $ECHO_C" >&6
15441 fi
15442 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15443 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15444 else
15445   # Is the header compilable?
15446 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15447 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15448 cat >conftest.$ac_ext <<_ACEOF
15449 #line $LINENO "configure"
15450 /* confdefs.h.  */
15451 _ACEOF
15452 cat confdefs.h >>conftest.$ac_ext
15453 cat >>conftest.$ac_ext <<_ACEOF
15454 /* end confdefs.h.  */
15455 $ac_includes_default
15456 #include <$ac_header>
15457 _ACEOF
15458 rm -f conftest.$ac_objext
15459 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15460   (eval $ac_compile) 2>&5
15461   ac_status=$?
15462   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15463   (exit $ac_status); } &&
15464          { ac_try='test -s conftest.$ac_objext'
15465   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15466   (eval $ac_try) 2>&5
15467   ac_status=$?
15468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15469   (exit $ac_status); }; }; then
15470   ac_header_compiler=yes
15471 else
15472   echo "$as_me: failed program was:" >&5
15473 sed 's/^/| /' conftest.$ac_ext >&5
15474
15475 ac_header_compiler=no
15476 fi
15477 rm -f conftest.$ac_objext conftest.$ac_ext
15478 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15479 echo "${ECHO_T}$ac_header_compiler" >&6
15480
15481 # Is the header present?
15482 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15483 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15484 cat >conftest.$ac_ext <<_ACEOF
15485 #line $LINENO "configure"
15486 /* confdefs.h.  */
15487 _ACEOF
15488 cat confdefs.h >>conftest.$ac_ext
15489 cat >>conftest.$ac_ext <<_ACEOF
15490 /* end confdefs.h.  */
15491 #include <$ac_header>
15492 _ACEOF
15493 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15494   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15495   ac_status=$?
15496   grep -v '^ *+' conftest.er1 >conftest.err
15497   rm -f conftest.er1
15498   cat conftest.err >&5
15499   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15500   (exit $ac_status); } >/dev/null; then
15501   if test -s conftest.err; then
15502     ac_cpp_err=$ac_c_preproc_warn_flag
15503   else
15504     ac_cpp_err=
15505   fi
15506 else
15507   ac_cpp_err=yes
15508 fi
15509 if test -z "$ac_cpp_err"; then
15510   ac_header_preproc=yes
15511 else
15512   echo "$as_me: failed program was:" >&5
15513 sed 's/^/| /' conftest.$ac_ext >&5
15514
15515   ac_header_preproc=no
15516 fi
15517 rm -f conftest.err conftest.$ac_ext
15518 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15519 echo "${ECHO_T}$ac_header_preproc" >&6
15520
15521 # So?  What about this header?
15522 case $ac_header_compiler:$ac_header_preproc in
15523   yes:no )
15524     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15525 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15526     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15527 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15528     (
15529       cat <<\_ASBOX
15530 ## ------------------------------------ ##
15531 ## Report this to bug-autoconf@gnu.org. ##
15532 ## ------------------------------------ ##
15533 _ASBOX
15534     ) |
15535       sed "s/^/$as_me: WARNING:     /" >&2
15536     ;;
15537   no:yes )
15538     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15539 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15540     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15541 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15542     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15543 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15544     (
15545       cat <<\_ASBOX
15546 ## ------------------------------------ ##
15547 ## Report this to bug-autoconf@gnu.org. ##
15548 ## ------------------------------------ ##
15549 _ASBOX
15550     ) |
15551       sed "s/^/$as_me: WARNING:     /" >&2
15552     ;;
15553 esac
15554 echo "$as_me:$LINENO: checking for $ac_header" >&5
15555 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15556 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15557   echo $ECHO_N "(cached) $ECHO_C" >&6
15558 else
15559   eval "$as_ac_Header=$ac_header_preproc"
15560 fi
15561 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15562 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15563
15564 fi
15565 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15566   cat >>confdefs.h <<_ACEOF
15567 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15568 _ACEOF
15569
15570 fi
15571
15572 done
15573
15574
15575         if test $ac_cv_header_pthread_h = yes ; then
15576                 echo "$as_me:$LINENO: checking POSIX thread version" >&5
15577 echo $ECHO_N "checking POSIX thread version... $ECHO_C" >&6
15578 if test "${ol_cv_pthread_version+set}" = set; then
15579   echo $ECHO_N "(cached) $ECHO_C" >&6
15580 else
15581
15582         cat >conftest.$ac_ext <<_ACEOF
15583 #line $LINENO "configure"
15584 /* confdefs.h.  */
15585 _ACEOF
15586 cat confdefs.h >>conftest.$ac_ext
15587 cat >>conftest.$ac_ext <<_ACEOF
15588 /* end confdefs.h.  */
15589
15590 #               include <pthread.h>
15591
15592 int
15593 main ()
15594 {
15595
15596                 int i = PTHREAD_CREATE_JOINABLE;
15597
15598   ;
15599   return 0;
15600 }
15601 _ACEOF
15602 rm -f conftest.$ac_objext
15603 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15604   (eval $ac_compile) 2>&5
15605   ac_status=$?
15606   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15607   (exit $ac_status); } &&
15608          { ac_try='test -s conftest.$ac_objext'
15609   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15610   (eval $ac_try) 2>&5
15611   ac_status=$?
15612   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15613   (exit $ac_status); }; }; then
15614
15615         cat >conftest.$ac_ext <<_ACEOF
15616 #line $LINENO "configure"
15617 /* confdefs.h.  */
15618 _ACEOF
15619 cat confdefs.h >>conftest.$ac_ext
15620 cat >>conftest.$ac_ext <<_ACEOF
15621 /* end confdefs.h.  */
15622 #include <pthread.h>
15623
15624 _ACEOF
15625 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15626   $EGREP "pthread_detach" >/dev/null 2>&1; then
15627   ol_cv_pthread_version=10
15628 else
15629   ol_cv_pthread_version=8
15630 fi
15631 rm -f conftest*
15632
15633 else
15634   echo "$as_me: failed program was:" >&5
15635 sed 's/^/| /' conftest.$ac_ext >&5
15636
15637
15638         cat >conftest.$ac_ext <<_ACEOF
15639 #line $LINENO "configure"
15640 /* confdefs.h.  */
15641 _ACEOF
15642 cat confdefs.h >>conftest.$ac_ext
15643 cat >>conftest.$ac_ext <<_ACEOF
15644 /* end confdefs.h.  */
15645
15646 #               include <pthread.h>
15647 #               ifdef PTHREAD_CREATE_UNDETACHED
15648                 draft7
15649 #               endif
15650
15651 _ACEOF
15652 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15653   $EGREP "draft7" >/dev/null 2>&1; then
15654   ol_cv_pthread_version=7
15655 else
15656
15657         cat >conftest.$ac_ext <<_ACEOF
15658 #line $LINENO "configure"
15659 /* confdefs.h.  */
15660 _ACEOF
15661 cat confdefs.h >>conftest.$ac_ext
15662 cat >>conftest.$ac_ext <<_ACEOF
15663 /* end confdefs.h.  */
15664 #include <pthread.h>
15665
15666 _ACEOF
15667 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15668   $EGREP "pthread_attr_init" >/dev/null 2>&1; then
15669   ol_cv_pthread_version=6
15670 else
15671
15672         cat >conftest.$ac_ext <<_ACEOF
15673 #line $LINENO "configure"
15674 /* confdefs.h.  */
15675 _ACEOF
15676 cat confdefs.h >>conftest.$ac_ext
15677 cat >>conftest.$ac_ext <<_ACEOF
15678 /* end confdefs.h.  */
15679
15680 #               include <pthread.h>
15681 #ifdef          PTHREAD_MUTEX_INITIALIZER
15682                 draft5
15683 #endif
15684
15685 _ACEOF
15686 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15687   $EGREP "draft5" >/dev/null 2>&1; then
15688   ol_cv_pthread_version=5
15689 else
15690   ol_cv_pthread_version=4
15691 fi
15692 rm -f conftest*
15693
15694 fi
15695 rm -f conftest*
15696
15697 fi
15698 rm -f conftest*
15699
15700 fi
15701 rm -f conftest.$ac_objext conftest.$ac_ext
15702
15703 fi
15704 echo "$as_me:$LINENO: result: $ol_cv_pthread_version" >&5
15705 echo "${ECHO_T}$ol_cv_pthread_version" >&6
15706
15707
15708                 if test $ol_cv_pthread_version != 0 ; then
15709
15710 cat >>confdefs.h <<_ACEOF
15711 #define HAVE_PTHREADS $ol_cv_pthread_version
15712 _ACEOF
15713
15714                 else
15715                         { { echo "$as_me:$LINENO: error: unknown pthread version" >&5
15716 echo "$as_me: error: unknown pthread version" >&2;}
15717    { (exit 1); exit 1; }; }
15718                 fi
15719
15720                 # consider threads found
15721                 ol_with_threads=found
15722
15723
15724         echo "$as_me:$LINENO: checking for LinuxThreads pthread.h" >&5
15725 echo $ECHO_N "checking for LinuxThreads pthread.h... $ECHO_C" >&6
15726 if test "${ol_cv_header_linux_threads+set}" = set; then
15727   echo $ECHO_N "(cached) $ECHO_C" >&6
15728 else
15729   cat >conftest.$ac_ext <<_ACEOF
15730 #line $LINENO "configure"
15731 /* confdefs.h.  */
15732 _ACEOF
15733 cat confdefs.h >>conftest.$ac_ext
15734 cat >>conftest.$ac_ext <<_ACEOF
15735 /* end confdefs.h.  */
15736 #include <pthread.h>
15737 _ACEOF
15738 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15739   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then
15740   ol_cv_header_linux_threads=yes
15741 else
15742   ol_cv_header_linux_threads=no
15743 fi
15744 rm -f conftest*
15745
15746
15747 fi
15748 echo "$as_me:$LINENO: result: $ol_cv_header_linux_threads" >&5
15749 echo "${ECHO_T}$ol_cv_header_linux_threads" >&6
15750         if test $ol_cv_header_linux_threads = yes; then
15751
15752 cat >>confdefs.h <<\_ACEOF
15753 #define HAVE_LINUX_THREADS 1
15754 _ACEOF
15755
15756         fi
15757
15758
15759         echo "$as_me:$LINENO: checking for GNU Pth pthread.h" >&5
15760 echo $ECHO_N "checking for GNU Pth pthread.h... $ECHO_C" >&6
15761 if test "${ol_cv_header_gnu_pth_pthread_h+set}" = set; then
15762   echo $ECHO_N "(cached) $ECHO_C" >&6
15763 else
15764   cat >conftest.$ac_ext <<_ACEOF
15765 #line $LINENO "configure"
15766 /* confdefs.h.  */
15767 _ACEOF
15768 cat confdefs.h >>conftest.$ac_ext
15769 cat >>conftest.$ac_ext <<_ACEOF
15770 /* end confdefs.h.  */
15771 #include <pthread.h>
15772 #ifdef _POSIX_THREAD_IS_GNU_PTH
15773         __gnu_pth__;
15774 #endif
15775
15776 _ACEOF
15777 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15778   $EGREP "__gnu_pth__" >/dev/null 2>&1; then
15779   ol_cv_header_gnu_pth_pthread_h=yes
15780 else
15781   ol_cv_header_gnu_pth_pthread_h=no
15782 fi
15783 rm -f conftest*
15784
15785
15786 fi
15787 echo "$as_me:$LINENO: result: $ol_cv_header_gnu_pth_pthread_h" >&5
15788 echo "${ECHO_T}$ol_cv_header_gnu_pth_pthread_h" >&6
15789
15790
15791                 if test $ol_cv_header_gnu_pth_pthread_h = no ; then
15792
15793 for ac_header in sched.h
15794 do
15795 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15796 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15797   echo "$as_me:$LINENO: checking for $ac_header" >&5
15798 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15799 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15800   echo $ECHO_N "(cached) $ECHO_C" >&6
15801 fi
15802 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15803 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15804 else
15805   # Is the header compilable?
15806 echo "$as_me:$LINENO: checking $ac_header usability" >&5
15807 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15808 cat >conftest.$ac_ext <<_ACEOF
15809 #line $LINENO "configure"
15810 /* confdefs.h.  */
15811 _ACEOF
15812 cat confdefs.h >>conftest.$ac_ext
15813 cat >>conftest.$ac_ext <<_ACEOF
15814 /* end confdefs.h.  */
15815 $ac_includes_default
15816 #include <$ac_header>
15817 _ACEOF
15818 rm -f conftest.$ac_objext
15819 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15820   (eval $ac_compile) 2>&5
15821   ac_status=$?
15822   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15823   (exit $ac_status); } &&
15824          { ac_try='test -s conftest.$ac_objext'
15825   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15826   (eval $ac_try) 2>&5
15827   ac_status=$?
15828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15829   (exit $ac_status); }; }; then
15830   ac_header_compiler=yes
15831 else
15832   echo "$as_me: failed program was:" >&5
15833 sed 's/^/| /' conftest.$ac_ext >&5
15834
15835 ac_header_compiler=no
15836 fi
15837 rm -f conftest.$ac_objext conftest.$ac_ext
15838 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15839 echo "${ECHO_T}$ac_header_compiler" >&6
15840
15841 # Is the header present?
15842 echo "$as_me:$LINENO: checking $ac_header presence" >&5
15843 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15844 cat >conftest.$ac_ext <<_ACEOF
15845 #line $LINENO "configure"
15846 /* confdefs.h.  */
15847 _ACEOF
15848 cat confdefs.h >>conftest.$ac_ext
15849 cat >>conftest.$ac_ext <<_ACEOF
15850 /* end confdefs.h.  */
15851 #include <$ac_header>
15852 _ACEOF
15853 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15854   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15855   ac_status=$?
15856   grep -v '^ *+' conftest.er1 >conftest.err
15857   rm -f conftest.er1
15858   cat conftest.err >&5
15859   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15860   (exit $ac_status); } >/dev/null; then
15861   if test -s conftest.err; then
15862     ac_cpp_err=$ac_c_preproc_warn_flag
15863   else
15864     ac_cpp_err=
15865   fi
15866 else
15867   ac_cpp_err=yes
15868 fi
15869 if test -z "$ac_cpp_err"; then
15870   ac_header_preproc=yes
15871 else
15872   echo "$as_me: failed program was:" >&5
15873 sed 's/^/| /' conftest.$ac_ext >&5
15874
15875   ac_header_preproc=no
15876 fi
15877 rm -f conftest.err conftest.$ac_ext
15878 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15879 echo "${ECHO_T}$ac_header_preproc" >&6
15880
15881 # So?  What about this header?
15882 case $ac_header_compiler:$ac_header_preproc in
15883   yes:no )
15884     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15885 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15886     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15887 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15888     (
15889       cat <<\_ASBOX
15890 ## ------------------------------------ ##
15891 ## Report this to bug-autoconf@gnu.org. ##
15892 ## ------------------------------------ ##
15893 _ASBOX
15894     ) |
15895       sed "s/^/$as_me: WARNING:     /" >&2
15896     ;;
15897   no:yes )
15898     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15899 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15900     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15901 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15902     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15903 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15904     (
15905       cat <<\_ASBOX
15906 ## ------------------------------------ ##
15907 ## Report this to bug-autoconf@gnu.org. ##
15908 ## ------------------------------------ ##
15909 _ASBOX
15910     ) |
15911       sed "s/^/$as_me: WARNING:     /" >&2
15912     ;;
15913 esac
15914 echo "$as_me:$LINENO: checking for $ac_header" >&5
15915 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15916 if eval "test \"\${$as_ac_Header+set}\" = set"; then
15917   echo $ECHO_N "(cached) $ECHO_C" >&6
15918 else
15919   eval "$as_ac_Header=$ac_header_preproc"
15920 fi
15921 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15922 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15923
15924 fi
15925 if test `eval echo '${'$as_ac_Header'}'` = yes; then
15926   cat >>confdefs.h <<_ACEOF
15927 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15928 _ACEOF
15929
15930 fi
15931
15932 done
15933
15934                 fi
15935
15936
15937                                 echo "$as_me:$LINENO: checking for pthread_create in default libraries" >&5
15938 echo $ECHO_N "checking for pthread_create in default libraries... $ECHO_C" >&6
15939 if test "${ol_cv_pthread_create+set}" = set; then
15940   echo $ECHO_N "(cached) $ECHO_C" >&6
15941 else
15942
15943                 if test "$cross_compiling" = yes; then
15944   cat >conftest.$ac_ext <<_ACEOF
15945 #line $LINENO "configure"
15946 /* confdefs.h.  */
15947 _ACEOF
15948 cat confdefs.h >>conftest.$ac_ext
15949 cat >>conftest.$ac_ext <<_ACEOF
15950 /* end confdefs.h.  */
15951 /* pthread test headers */
15952 #include <pthread.h>
15953 #if HAVE_PTHREADS < 7
15954 #include <errno.h>
15955 #endif
15956 #ifndef NULL
15957 #define NULL (void*)0
15958 #endif
15959
15960 static void *task(p)
15961         void *p;
15962 {
15963         return (void *) (p == NULL);
15964 }
15965
15966 int
15967 main ()
15968 {
15969
15970         /* pthread test function */
15971 #ifndef PTHREAD_CREATE_DETACHED
15972 #define PTHREAD_CREATE_DETACHED 1
15973 #endif
15974         pthread_t t;
15975         int status;
15976         int detach = PTHREAD_CREATE_DETACHED;
15977
15978 #if HAVE_PTHREADS > 4
15979         /* Final pthreads */
15980         pthread_attr_t attr;
15981
15982         status = pthread_attr_init(&attr);
15983         if( status ) return status;
15984
15985 #if HAVE_PTHREADS < 7
15986         status = pthread_attr_setdetachstate(&attr, &detach);
15987         if( status < 0 ) status = errno;
15988 #else
15989         status = pthread_attr_setdetachstate(&attr, detach);
15990 #endif
15991         if( status ) return status;
15992         status = pthread_create( &t, &attr, task, NULL );
15993 #if HAVE_PTHREADS < 7
15994         if( status < 0 ) status = errno;
15995 #endif
15996         if( status ) return status;
15997 #else
15998         /* Draft 4 pthreads */
15999         status = pthread_create( &t, pthread_attr_default, task, NULL );
16000         if( status ) return errno;
16001
16002         /* give thread a chance to complete */
16003         /* it should remain joinable and hence detachable */
16004         sleep( 1 );
16005
16006         status = pthread_detach( &t );
16007         if( status ) return errno;
16008 #endif
16009
16010 #ifdef HAVE_LINUX_THREADS
16011         pthread_kill_other_threads_np();
16012 #endif
16013
16014         return 0;
16015
16016   ;
16017   return 0;
16018 }
16019 _ACEOF
16020 rm -f conftest.$ac_objext conftest$ac_exeext
16021 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16022   (eval $ac_link) 2>&5
16023   ac_status=$?
16024   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16025   (exit $ac_status); } &&
16026          { ac_try='test -s conftest$ac_exeext'
16027   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16028   (eval $ac_try) 2>&5
16029   ac_status=$?
16030   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16031   (exit $ac_status); }; }; then
16032   ol_cv_pthread_create=yes
16033 else
16034   echo "$as_me: failed program was:" >&5
16035 sed 's/^/| /' conftest.$ac_ext >&5
16036
16037 ol_cv_pthread_create=no
16038 fi
16039 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16040 else
16041   cat >conftest.$ac_ext <<_ACEOF
16042 #line $LINENO "configure"
16043 /* confdefs.h.  */
16044 _ACEOF
16045 cat confdefs.h >>conftest.$ac_ext
16046 cat >>conftest.$ac_ext <<_ACEOF
16047 /* end confdefs.h.  */
16048 /* pthread test headers */
16049 #include <pthread.h>
16050 #if HAVE_PTHREADS < 7
16051 #include <errno.h>
16052 #endif
16053 #ifndef NULL
16054 #define NULL (void*)0
16055 #endif
16056
16057 static void *task(p)
16058         void *p;
16059 {
16060         return (void *) (p == NULL);
16061 }
16062
16063
16064 int main(argc, argv)
16065         int argc;
16066         char **argv;
16067 {
16068
16069         /* pthread test function */
16070 #ifndef PTHREAD_CREATE_DETACHED
16071 #define PTHREAD_CREATE_DETACHED 1
16072 #endif
16073         pthread_t t;
16074         int status;
16075         int detach = PTHREAD_CREATE_DETACHED;
16076
16077 #if HAVE_PTHREADS > 4
16078         /* Final pthreads */
16079         pthread_attr_t attr;
16080
16081         status = pthread_attr_init(&attr);
16082         if( status ) return status;
16083
16084 #if HAVE_PTHREADS < 7
16085         status = pthread_attr_setdetachstate(&attr, &detach);
16086         if( status < 0 ) status = errno;
16087 #else
16088         status = pthread_attr_setdetachstate(&attr, detach);
16089 #endif
16090         if( status ) return status;
16091         status = pthread_create( &t, &attr, task, NULL );
16092 #if HAVE_PTHREADS < 7
16093         if( status < 0 ) status = errno;
16094 #endif
16095         if( status ) return status;
16096 #else
16097         /* Draft 4 pthreads */
16098         status = pthread_create( &t, pthread_attr_default, task, NULL );
16099         if( status ) return errno;
16100
16101         /* give thread a chance to complete */
16102         /* it should remain joinable and hence detachable */
16103         sleep( 1 );
16104
16105         status = pthread_detach( &t );
16106         if( status ) return errno;
16107 #endif
16108
16109 #ifdef HAVE_LINUX_THREADS
16110         pthread_kill_other_threads_np();
16111 #endif
16112
16113         return 0;
16114
16115 }
16116
16117 _ACEOF
16118 rm -f conftest$ac_exeext
16119 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16120   (eval $ac_link) 2>&5
16121   ac_status=$?
16122   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16123   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16124   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16125   (eval $ac_try) 2>&5
16126   ac_status=$?
16127   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16128   (exit $ac_status); }; }; then
16129   ol_cv_pthread_create=yes
16130 else
16131   echo "$as_me: program exited with status $ac_status" >&5
16132 echo "$as_me: failed program was:" >&5
16133 sed 's/^/| /' conftest.$ac_ext >&5
16134
16135 ( exit $ac_status )
16136 ol_cv_pthread_create=no
16137 fi
16138 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16139 fi
16140 fi
16141 echo "$as_me:$LINENO: result: $ol_cv_pthread_create" >&5
16142 echo "${ECHO_T}$ol_cv_pthread_create" >&6
16143
16144                 if test $ol_cv_pthread_create != no ; then
16145                         ol_link_threads=posix
16146                         ol_link_pthreads=""
16147                 fi
16148
16149                 # Pthread try link: -kthread (ol_cv_pthread_kthread)
16150 if test "$ol_link_threads" = no ; then
16151         # try -kthread
16152         echo "$as_me:$LINENO: checking for pthread link with -kthread" >&5
16153 echo $ECHO_N "checking for pthread link with -kthread... $ECHO_C" >&6
16154 if test "${ol_cv_pthread_kthread+set}" = set; then
16155   echo $ECHO_N "(cached) $ECHO_C" >&6
16156 else
16157
16158                 # save the flags
16159                 ol_LIBS="$LIBS"
16160                 LIBS="-kthread $LIBS"
16161
16162                 if test "$cross_compiling" = yes; then
16163   cat >conftest.$ac_ext <<_ACEOF
16164 #line $LINENO "configure"
16165 /* confdefs.h.  */
16166 _ACEOF
16167 cat confdefs.h >>conftest.$ac_ext
16168 cat >>conftest.$ac_ext <<_ACEOF
16169 /* end confdefs.h.  */
16170 /* pthread test headers */
16171 #include <pthread.h>
16172 #if HAVE_PTHREADS < 7
16173 #include <errno.h>
16174 #endif
16175 #ifndef NULL
16176 #define NULL (void*)0
16177 #endif
16178
16179 static void *task(p)
16180         void *p;
16181 {
16182         return (void *) (p == NULL);
16183 }
16184
16185 int
16186 main ()
16187 {
16188
16189         /* pthread test function */
16190 #ifndef PTHREAD_CREATE_DETACHED
16191 #define PTHREAD_CREATE_DETACHED 1
16192 #endif
16193         pthread_t t;
16194         int status;
16195         int detach = PTHREAD_CREATE_DETACHED;
16196
16197 #if HAVE_PTHREADS > 4
16198         /* Final pthreads */
16199         pthread_attr_t attr;
16200
16201         status = pthread_attr_init(&attr);
16202         if( status ) return status;
16203
16204 #if HAVE_PTHREADS < 7
16205         status = pthread_attr_setdetachstate(&attr, &detach);
16206         if( status < 0 ) status = errno;
16207 #else
16208         status = pthread_attr_setdetachstate(&attr, detach);
16209 #endif
16210         if( status ) return status;
16211         status = pthread_create( &t, &attr, task, NULL );
16212 #if HAVE_PTHREADS < 7
16213         if( status < 0 ) status = errno;
16214 #endif
16215         if( status ) return status;
16216 #else
16217         /* Draft 4 pthreads */
16218         status = pthread_create( &t, pthread_attr_default, task, NULL );
16219         if( status ) return errno;
16220
16221         /* give thread a chance to complete */
16222         /* it should remain joinable and hence detachable */
16223         sleep( 1 );
16224
16225         status = pthread_detach( &t );
16226         if( status ) return errno;
16227 #endif
16228
16229 #ifdef HAVE_LINUX_THREADS
16230         pthread_kill_other_threads_np();
16231 #endif
16232
16233         return 0;
16234
16235   ;
16236   return 0;
16237 }
16238 _ACEOF
16239 rm -f conftest.$ac_objext conftest$ac_exeext
16240 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16241   (eval $ac_link) 2>&5
16242   ac_status=$?
16243   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16244   (exit $ac_status); } &&
16245          { ac_try='test -s conftest$ac_exeext'
16246   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16247   (eval $ac_try) 2>&5
16248   ac_status=$?
16249   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16250   (exit $ac_status); }; }; then
16251   ol_cv_pthread_kthread=yes
16252 else
16253   echo "$as_me: failed program was:" >&5
16254 sed 's/^/| /' conftest.$ac_ext >&5
16255
16256 ol_cv_pthread_kthread=no
16257 fi
16258 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16259 else
16260   cat >conftest.$ac_ext <<_ACEOF
16261 #line $LINENO "configure"
16262 /* confdefs.h.  */
16263 _ACEOF
16264 cat confdefs.h >>conftest.$ac_ext
16265 cat >>conftest.$ac_ext <<_ACEOF
16266 /* end confdefs.h.  */
16267 /* pthread test headers */
16268 #include <pthread.h>
16269 #if HAVE_PTHREADS < 7
16270 #include <errno.h>
16271 #endif
16272 #ifndef NULL
16273 #define NULL (void*)0
16274 #endif
16275
16276 static void *task(p)
16277         void *p;
16278 {
16279         return (void *) (p == NULL);
16280 }
16281
16282
16283 int main(argc, argv)
16284         int argc;
16285         char **argv;
16286 {
16287
16288         /* pthread test function */
16289 #ifndef PTHREAD_CREATE_DETACHED
16290 #define PTHREAD_CREATE_DETACHED 1
16291 #endif
16292         pthread_t t;
16293         int status;
16294         int detach = PTHREAD_CREATE_DETACHED;
16295
16296 #if HAVE_PTHREADS > 4
16297         /* Final pthreads */
16298         pthread_attr_t attr;
16299
16300         status = pthread_attr_init(&attr);
16301         if( status ) return status;
16302
16303 #if HAVE_PTHREADS < 7
16304         status = pthread_attr_setdetachstate(&attr, &detach);
16305         if( status < 0 ) status = errno;
16306 #else
16307         status = pthread_attr_setdetachstate(&attr, detach);
16308 #endif
16309         if( status ) return status;
16310         status = pthread_create( &t, &attr, task, NULL );
16311 #if HAVE_PTHREADS < 7
16312         if( status < 0 ) status = errno;
16313 #endif
16314         if( status ) return status;
16315 #else
16316         /* Draft 4 pthreads */
16317         status = pthread_create( &t, pthread_attr_default, task, NULL );
16318         if( status ) return errno;
16319
16320         /* give thread a chance to complete */
16321         /* it should remain joinable and hence detachable */
16322         sleep( 1 );
16323
16324         status = pthread_detach( &t );
16325         if( status ) return errno;
16326 #endif
16327
16328 #ifdef HAVE_LINUX_THREADS
16329         pthread_kill_other_threads_np();
16330 #endif
16331
16332         return 0;
16333
16334 }
16335
16336 _ACEOF
16337 rm -f conftest$ac_exeext
16338 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16339   (eval $ac_link) 2>&5
16340   ac_status=$?
16341   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16342   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16343   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16344   (eval $ac_try) 2>&5
16345   ac_status=$?
16346   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16347   (exit $ac_status); }; }; then
16348   ol_cv_pthread_kthread=yes
16349 else
16350   echo "$as_me: program exited with status $ac_status" >&5
16351 echo "$as_me: failed program was:" >&5
16352 sed 's/^/| /' conftest.$ac_ext >&5
16353
16354 ( exit $ac_status )
16355 ol_cv_pthread_kthread=no
16356 fi
16357 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16358 fi
16359
16360                 # restore the LIBS
16361                 LIBS="$ol_LIBS"
16362
16363 fi
16364 echo "$as_me:$LINENO: result: $ol_cv_pthread_kthread" >&5
16365 echo "${ECHO_T}$ol_cv_pthread_kthread" >&6
16366
16367         if test $ol_cv_pthread_kthread = yes ; then
16368                 ol_link_pthreads="-kthread"
16369                 ol_link_threads=posix
16370         fi
16371 fi
16372
16373                 # Pthread try link: -pthread (ol_cv_pthread_pthread)
16374 if test "$ol_link_threads" = no ; then
16375         # try -pthread
16376         echo "$as_me:$LINENO: checking for pthread link with -pthread" >&5
16377 echo $ECHO_N "checking for pthread link with -pthread... $ECHO_C" >&6
16378 if test "${ol_cv_pthread_pthread+set}" = set; then
16379   echo $ECHO_N "(cached) $ECHO_C" >&6
16380 else
16381
16382                 # save the flags
16383                 ol_LIBS="$LIBS"
16384                 LIBS="-pthread $LIBS"
16385
16386                 if test "$cross_compiling" = yes; then
16387   cat >conftest.$ac_ext <<_ACEOF
16388 #line $LINENO "configure"
16389 /* confdefs.h.  */
16390 _ACEOF
16391 cat confdefs.h >>conftest.$ac_ext
16392 cat >>conftest.$ac_ext <<_ACEOF
16393 /* end confdefs.h.  */
16394 /* pthread test headers */
16395 #include <pthread.h>
16396 #if HAVE_PTHREADS < 7
16397 #include <errno.h>
16398 #endif
16399 #ifndef NULL
16400 #define NULL (void*)0
16401 #endif
16402
16403 static void *task(p)
16404         void *p;
16405 {
16406         return (void *) (p == NULL);
16407 }
16408
16409 int
16410 main ()
16411 {
16412
16413         /* pthread test function */
16414 #ifndef PTHREAD_CREATE_DETACHED
16415 #define PTHREAD_CREATE_DETACHED 1
16416 #endif
16417         pthread_t t;
16418         int status;
16419         int detach = PTHREAD_CREATE_DETACHED;
16420
16421 #if HAVE_PTHREADS > 4
16422         /* Final pthreads */
16423         pthread_attr_t attr;
16424
16425         status = pthread_attr_init(&attr);
16426         if( status ) return status;
16427
16428 #if HAVE_PTHREADS < 7
16429         status = pthread_attr_setdetachstate(&attr, &detach);
16430         if( status < 0 ) status = errno;
16431 #else
16432         status = pthread_attr_setdetachstate(&attr, detach);
16433 #endif
16434         if( status ) return status;
16435         status = pthread_create( &t, &attr, task, NULL );
16436 #if HAVE_PTHREADS < 7
16437         if( status < 0 ) status = errno;
16438 #endif
16439         if( status ) return status;
16440 #else
16441         /* Draft 4 pthreads */
16442         status = pthread_create( &t, pthread_attr_default, task, NULL );
16443         if( status ) return errno;
16444
16445         /* give thread a chance to complete */
16446         /* it should remain joinable and hence detachable */
16447         sleep( 1 );
16448
16449         status = pthread_detach( &t );
16450         if( status ) return errno;
16451 #endif
16452
16453 #ifdef HAVE_LINUX_THREADS
16454         pthread_kill_other_threads_np();
16455 #endif
16456
16457         return 0;
16458
16459   ;
16460   return 0;
16461 }
16462 _ACEOF
16463 rm -f conftest.$ac_objext conftest$ac_exeext
16464 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16465   (eval $ac_link) 2>&5
16466   ac_status=$?
16467   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16468   (exit $ac_status); } &&
16469          { ac_try='test -s conftest$ac_exeext'
16470   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16471   (eval $ac_try) 2>&5
16472   ac_status=$?
16473   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16474   (exit $ac_status); }; }; then
16475   ol_cv_pthread_pthread=yes
16476 else
16477   echo "$as_me: failed program was:" >&5
16478 sed 's/^/| /' conftest.$ac_ext >&5
16479
16480 ol_cv_pthread_pthread=no
16481 fi
16482 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16483 else
16484   cat >conftest.$ac_ext <<_ACEOF
16485 #line $LINENO "configure"
16486 /* confdefs.h.  */
16487 _ACEOF
16488 cat confdefs.h >>conftest.$ac_ext
16489 cat >>conftest.$ac_ext <<_ACEOF
16490 /* end confdefs.h.  */
16491 /* pthread test headers */
16492 #include <pthread.h>
16493 #if HAVE_PTHREADS < 7
16494 #include <errno.h>
16495 #endif
16496 #ifndef NULL
16497 #define NULL (void*)0
16498 #endif
16499
16500 static void *task(p)
16501         void *p;
16502 {
16503         return (void *) (p == NULL);
16504 }
16505
16506
16507 int main(argc, argv)
16508         int argc;
16509         char **argv;
16510 {
16511
16512         /* pthread test function */
16513 #ifndef PTHREAD_CREATE_DETACHED
16514 #define PTHREAD_CREATE_DETACHED 1
16515 #endif
16516         pthread_t t;
16517         int status;
16518         int detach = PTHREAD_CREATE_DETACHED;
16519
16520 #if HAVE_PTHREADS > 4
16521         /* Final pthreads */
16522         pthread_attr_t attr;
16523
16524         status = pthread_attr_init(&attr);
16525         if( status ) return status;
16526
16527 #if HAVE_PTHREADS < 7
16528         status = pthread_attr_setdetachstate(&attr, &detach);
16529         if( status < 0 ) status = errno;
16530 #else
16531         status = pthread_attr_setdetachstate(&attr, detach);
16532 #endif
16533         if( status ) return status;
16534         status = pthread_create( &t, &attr, task, NULL );
16535 #if HAVE_PTHREADS < 7
16536         if( status < 0 ) status = errno;
16537 #endif
16538         if( status ) return status;
16539 #else
16540         /* Draft 4 pthreads */
16541         status = pthread_create( &t, pthread_attr_default, task, NULL );
16542         if( status ) return errno;
16543
16544         /* give thread a chance to complete */
16545         /* it should remain joinable and hence detachable */
16546         sleep( 1 );
16547
16548         status = pthread_detach( &t );
16549         if( status ) return errno;
16550 #endif
16551
16552 #ifdef HAVE_LINUX_THREADS
16553         pthread_kill_other_threads_np();
16554 #endif
16555
16556         return 0;
16557
16558 }
16559
16560 _ACEOF
16561 rm -f conftest$ac_exeext
16562 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16563   (eval $ac_link) 2>&5
16564   ac_status=$?
16565   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16566   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16567   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16568   (eval $ac_try) 2>&5
16569   ac_status=$?
16570   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16571   (exit $ac_status); }; }; then
16572   ol_cv_pthread_pthread=yes
16573 else
16574   echo "$as_me: program exited with status $ac_status" >&5
16575 echo "$as_me: failed program was:" >&5
16576 sed 's/^/| /' conftest.$ac_ext >&5
16577
16578 ( exit $ac_status )
16579 ol_cv_pthread_pthread=no
16580 fi
16581 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16582 fi
16583
16584                 # restore the LIBS
16585                 LIBS="$ol_LIBS"
16586
16587 fi
16588 echo "$as_me:$LINENO: result: $ol_cv_pthread_pthread" >&5
16589 echo "${ECHO_T}$ol_cv_pthread_pthread" >&6
16590
16591         if test $ol_cv_pthread_pthread = yes ; then
16592                 ol_link_pthreads="-pthread"
16593                 ol_link_threads=posix
16594         fi
16595 fi
16596
16597                 # Pthread try link: -pthreads (ol_cv_pthread_pthreads)
16598 if test "$ol_link_threads" = no ; then
16599         # try -pthreads
16600         echo "$as_me:$LINENO: checking for pthread link with -pthreads" >&5
16601 echo $ECHO_N "checking for pthread link with -pthreads... $ECHO_C" >&6
16602 if test "${ol_cv_pthread_pthreads+set}" = set; then
16603   echo $ECHO_N "(cached) $ECHO_C" >&6
16604 else
16605
16606                 # save the flags
16607                 ol_LIBS="$LIBS"
16608                 LIBS="-pthreads $LIBS"
16609
16610                 if test "$cross_compiling" = yes; then
16611   cat >conftest.$ac_ext <<_ACEOF
16612 #line $LINENO "configure"
16613 /* confdefs.h.  */
16614 _ACEOF
16615 cat confdefs.h >>conftest.$ac_ext
16616 cat >>conftest.$ac_ext <<_ACEOF
16617 /* end confdefs.h.  */
16618 /* pthread test headers */
16619 #include <pthread.h>
16620 #if HAVE_PTHREADS < 7
16621 #include <errno.h>
16622 #endif
16623 #ifndef NULL
16624 #define NULL (void*)0
16625 #endif
16626
16627 static void *task(p)
16628         void *p;
16629 {
16630         return (void *) (p == NULL);
16631 }
16632
16633 int
16634 main ()
16635 {
16636
16637         /* pthread test function */
16638 #ifndef PTHREAD_CREATE_DETACHED
16639 #define PTHREAD_CREATE_DETACHED 1
16640 #endif
16641         pthread_t t;
16642         int status;
16643         int detach = PTHREAD_CREATE_DETACHED;
16644
16645 #if HAVE_PTHREADS > 4
16646         /* Final pthreads */
16647         pthread_attr_t attr;
16648
16649         status = pthread_attr_init(&attr);
16650         if( status ) return status;
16651
16652 #if HAVE_PTHREADS < 7
16653         status = pthread_attr_setdetachstate(&attr, &detach);
16654         if( status < 0 ) status = errno;
16655 #else
16656         status = pthread_attr_setdetachstate(&attr, detach);
16657 #endif
16658         if( status ) return status;
16659         status = pthread_create( &t, &attr, task, NULL );
16660 #if HAVE_PTHREADS < 7
16661         if( status < 0 ) status = errno;
16662 #endif
16663         if( status ) return status;
16664 #else
16665         /* Draft 4 pthreads */
16666         status = pthread_create( &t, pthread_attr_default, task, NULL );
16667         if( status ) return errno;
16668
16669         /* give thread a chance to complete */
16670         /* it should remain joinable and hence detachable */
16671         sleep( 1 );
16672
16673         status = pthread_detach( &t );
16674         if( status ) return errno;
16675 #endif
16676
16677 #ifdef HAVE_LINUX_THREADS
16678         pthread_kill_other_threads_np();
16679 #endif
16680
16681         return 0;
16682
16683   ;
16684   return 0;
16685 }
16686 _ACEOF
16687 rm -f conftest.$ac_objext conftest$ac_exeext
16688 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16689   (eval $ac_link) 2>&5
16690   ac_status=$?
16691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16692   (exit $ac_status); } &&
16693          { ac_try='test -s conftest$ac_exeext'
16694   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16695   (eval $ac_try) 2>&5
16696   ac_status=$?
16697   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16698   (exit $ac_status); }; }; then
16699   ol_cv_pthread_pthreads=yes
16700 else
16701   echo "$as_me: failed program was:" >&5
16702 sed 's/^/| /' conftest.$ac_ext >&5
16703
16704 ol_cv_pthread_pthreads=no
16705 fi
16706 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16707 else
16708   cat >conftest.$ac_ext <<_ACEOF
16709 #line $LINENO "configure"
16710 /* confdefs.h.  */
16711 _ACEOF
16712 cat confdefs.h >>conftest.$ac_ext
16713 cat >>conftest.$ac_ext <<_ACEOF
16714 /* end confdefs.h.  */
16715 /* pthread test headers */
16716 #include <pthread.h>
16717 #if HAVE_PTHREADS < 7
16718 #include <errno.h>
16719 #endif
16720 #ifndef NULL
16721 #define NULL (void*)0
16722 #endif
16723
16724 static void *task(p)
16725         void *p;
16726 {
16727         return (void *) (p == NULL);
16728 }
16729
16730
16731 int main(argc, argv)
16732         int argc;
16733         char **argv;
16734 {
16735
16736         /* pthread test function */
16737 #ifndef PTHREAD_CREATE_DETACHED
16738 #define PTHREAD_CREATE_DETACHED 1
16739 #endif
16740         pthread_t t;
16741         int status;
16742         int detach = PTHREAD_CREATE_DETACHED;
16743
16744 #if HAVE_PTHREADS > 4
16745         /* Final pthreads */
16746         pthread_attr_t attr;
16747
16748         status = pthread_attr_init(&attr);
16749         if( status ) return status;
16750
16751 #if HAVE_PTHREADS < 7
16752         status = pthread_attr_setdetachstate(&attr, &detach);
16753         if( status < 0 ) status = errno;
16754 #else
16755         status = pthread_attr_setdetachstate(&attr, detach);
16756 #endif
16757         if( status ) return status;
16758         status = pthread_create( &t, &attr, task, NULL );
16759 #if HAVE_PTHREADS < 7
16760         if( status < 0 ) status = errno;
16761 #endif
16762         if( status ) return status;
16763 #else
16764         /* Draft 4 pthreads */
16765         status = pthread_create( &t, pthread_attr_default, task, NULL );
16766         if( status ) return errno;
16767
16768         /* give thread a chance to complete */
16769         /* it should remain joinable and hence detachable */
16770         sleep( 1 );
16771
16772         status = pthread_detach( &t );
16773         if( status ) return errno;
16774 #endif
16775
16776 #ifdef HAVE_LINUX_THREADS
16777         pthread_kill_other_threads_np();
16778 #endif
16779
16780         return 0;
16781
16782 }
16783
16784 _ACEOF
16785 rm -f conftest$ac_exeext
16786 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16787   (eval $ac_link) 2>&5
16788   ac_status=$?
16789   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16790   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16791   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16792   (eval $ac_try) 2>&5
16793   ac_status=$?
16794   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16795   (exit $ac_status); }; }; then
16796   ol_cv_pthread_pthreads=yes
16797 else
16798   echo "$as_me: program exited with status $ac_status" >&5
16799 echo "$as_me: failed program was:" >&5
16800 sed 's/^/| /' conftest.$ac_ext >&5
16801
16802 ( exit $ac_status )
16803 ol_cv_pthread_pthreads=no
16804 fi
16805 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16806 fi
16807
16808                 # restore the LIBS
16809                 LIBS="$ol_LIBS"
16810
16811 fi
16812 echo "$as_me:$LINENO: result: $ol_cv_pthread_pthreads" >&5
16813 echo "${ECHO_T}$ol_cv_pthread_pthreads" >&6
16814
16815         if test $ol_cv_pthread_pthreads = yes ; then
16816                 ol_link_pthreads="-pthreads"
16817                 ol_link_threads=posix
16818         fi
16819 fi
16820
16821                 # Pthread try link: -mthreads (ol_cv_pthread_mthreads)
16822 if test "$ol_link_threads" = no ; then
16823         # try -mthreads
16824         echo "$as_me:$LINENO: checking for pthread link with -mthreads" >&5
16825 echo $ECHO_N "checking for pthread link with -mthreads... $ECHO_C" >&6
16826 if test "${ol_cv_pthread_mthreads+set}" = set; then
16827   echo $ECHO_N "(cached) $ECHO_C" >&6
16828 else
16829
16830                 # save the flags
16831                 ol_LIBS="$LIBS"
16832                 LIBS="-mthreads $LIBS"
16833
16834                 if test "$cross_compiling" = yes; then
16835   cat >conftest.$ac_ext <<_ACEOF
16836 #line $LINENO "configure"
16837 /* confdefs.h.  */
16838 _ACEOF
16839 cat confdefs.h >>conftest.$ac_ext
16840 cat >>conftest.$ac_ext <<_ACEOF
16841 /* end confdefs.h.  */
16842 /* pthread test headers */
16843 #include <pthread.h>
16844 #if HAVE_PTHREADS < 7
16845 #include <errno.h>
16846 #endif
16847 #ifndef NULL
16848 #define NULL (void*)0
16849 #endif
16850
16851 static void *task(p)
16852         void *p;
16853 {
16854         return (void *) (p == NULL);
16855 }
16856
16857 int
16858 main ()
16859 {
16860
16861         /* pthread test function */
16862 #ifndef PTHREAD_CREATE_DETACHED
16863 #define PTHREAD_CREATE_DETACHED 1
16864 #endif
16865         pthread_t t;
16866         int status;
16867         int detach = PTHREAD_CREATE_DETACHED;
16868
16869 #if HAVE_PTHREADS > 4
16870         /* Final pthreads */
16871         pthread_attr_t attr;
16872
16873         status = pthread_attr_init(&attr);
16874         if( status ) return status;
16875
16876 #if HAVE_PTHREADS < 7
16877         status = pthread_attr_setdetachstate(&attr, &detach);
16878         if( status < 0 ) status = errno;
16879 #else
16880         status = pthread_attr_setdetachstate(&attr, detach);
16881 #endif
16882         if( status ) return status;
16883         status = pthread_create( &t, &attr, task, NULL );
16884 #if HAVE_PTHREADS < 7
16885         if( status < 0 ) status = errno;
16886 #endif
16887         if( status ) return status;
16888 #else
16889         /* Draft 4 pthreads */
16890         status = pthread_create( &t, pthread_attr_default, task, NULL );
16891         if( status ) return errno;
16892
16893         /* give thread a chance to complete */
16894         /* it should remain joinable and hence detachable */
16895         sleep( 1 );
16896
16897         status = pthread_detach( &t );
16898         if( status ) return errno;
16899 #endif
16900
16901 #ifdef HAVE_LINUX_THREADS
16902         pthread_kill_other_threads_np();
16903 #endif
16904
16905         return 0;
16906
16907   ;
16908   return 0;
16909 }
16910 _ACEOF
16911 rm -f conftest.$ac_objext conftest$ac_exeext
16912 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16913   (eval $ac_link) 2>&5
16914   ac_status=$?
16915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16916   (exit $ac_status); } &&
16917          { ac_try='test -s conftest$ac_exeext'
16918   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16919   (eval $ac_try) 2>&5
16920   ac_status=$?
16921   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16922   (exit $ac_status); }; }; then
16923   ol_cv_pthread_mthreads=yes
16924 else
16925   echo "$as_me: failed program was:" >&5
16926 sed 's/^/| /' conftest.$ac_ext >&5
16927
16928 ol_cv_pthread_mthreads=no
16929 fi
16930 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16931 else
16932   cat >conftest.$ac_ext <<_ACEOF
16933 #line $LINENO "configure"
16934 /* confdefs.h.  */
16935 _ACEOF
16936 cat confdefs.h >>conftest.$ac_ext
16937 cat >>conftest.$ac_ext <<_ACEOF
16938 /* end confdefs.h.  */
16939 /* pthread test headers */
16940 #include <pthread.h>
16941 #if HAVE_PTHREADS < 7
16942 #include <errno.h>
16943 #endif
16944 #ifndef NULL
16945 #define NULL (void*)0
16946 #endif
16947
16948 static void *task(p)
16949         void *p;
16950 {
16951         return (void *) (p == NULL);
16952 }
16953
16954
16955 int main(argc, argv)
16956         int argc;
16957         char **argv;
16958 {
16959
16960         /* pthread test function */
16961 #ifndef PTHREAD_CREATE_DETACHED
16962 #define PTHREAD_CREATE_DETACHED 1
16963 #endif
16964         pthread_t t;
16965         int status;
16966         int detach = PTHREAD_CREATE_DETACHED;
16967
16968 #if HAVE_PTHREADS > 4
16969         /* Final pthreads */
16970         pthread_attr_t attr;
16971
16972         status = pthread_attr_init(&attr);
16973         if( status ) return status;
16974
16975 #if HAVE_PTHREADS < 7
16976         status = pthread_attr_setdetachstate(&attr, &detach);
16977         if( status < 0 ) status = errno;
16978 #else
16979         status = pthread_attr_setdetachstate(&attr, detach);
16980 #endif
16981         if( status ) return status;
16982         status = pthread_create( &t, &attr, task, NULL );
16983 #if HAVE_PTHREADS < 7
16984         if( status < 0 ) status = errno;
16985 #endif
16986         if( status ) return status;
16987 #else
16988         /* Draft 4 pthreads */
16989         status = pthread_create( &t, pthread_attr_default, task, NULL );
16990         if( status ) return errno;
16991
16992         /* give thread a chance to complete */
16993         /* it should remain joinable and hence detachable */
16994         sleep( 1 );
16995
16996         status = pthread_detach( &t );
16997         if( status ) return errno;
16998 #endif
16999
17000 #ifdef HAVE_LINUX_THREADS
17001         pthread_kill_other_threads_np();
17002 #endif
17003
17004         return 0;
17005
17006 }
17007
17008 _ACEOF
17009 rm -f conftest$ac_exeext
17010 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17011   (eval $ac_link) 2>&5
17012   ac_status=$?
17013   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17014   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17015   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17016   (eval $ac_try) 2>&5
17017   ac_status=$?
17018   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17019   (exit $ac_status); }; }; then
17020   ol_cv_pthread_mthreads=yes
17021 else
17022   echo "$as_me: program exited with status $ac_status" >&5
17023 echo "$as_me: failed program was:" >&5
17024 sed 's/^/| /' conftest.$ac_ext >&5
17025
17026 ( exit $ac_status )
17027 ol_cv_pthread_mthreads=no
17028 fi
17029 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17030 fi
17031
17032                 # restore the LIBS
17033                 LIBS="$ol_LIBS"
17034
17035 fi
17036 echo "$as_me:$LINENO: result: $ol_cv_pthread_mthreads" >&5
17037 echo "${ECHO_T}$ol_cv_pthread_mthreads" >&6
17038
17039         if test $ol_cv_pthread_mthreads = yes ; then
17040                 ol_link_pthreads="-mthreads"
17041                 ol_link_threads=posix
17042         fi
17043 fi
17044
17045                 # Pthread try link: -thread (ol_cv_pthread_thread)
17046 if test "$ol_link_threads" = no ; then
17047         # try -thread
17048         echo "$as_me:$LINENO: checking for pthread link with -thread" >&5
17049 echo $ECHO_N "checking for pthread link with -thread... $ECHO_C" >&6
17050 if test "${ol_cv_pthread_thread+set}" = set; then
17051   echo $ECHO_N "(cached) $ECHO_C" >&6
17052 else
17053
17054                 # save the flags
17055                 ol_LIBS="$LIBS"
17056                 LIBS="-thread $LIBS"
17057
17058                 if test "$cross_compiling" = yes; then
17059   cat >conftest.$ac_ext <<_ACEOF
17060 #line $LINENO "configure"
17061 /* confdefs.h.  */
17062 _ACEOF
17063 cat confdefs.h >>conftest.$ac_ext
17064 cat >>conftest.$ac_ext <<_ACEOF
17065 /* end confdefs.h.  */
17066 /* pthread test headers */
17067 #include <pthread.h>
17068 #if HAVE_PTHREADS < 7
17069 #include <errno.h>
17070 #endif
17071 #ifndef NULL
17072 #define NULL (void*)0
17073 #endif
17074
17075 static void *task(p)
17076         void *p;
17077 {
17078         return (void *) (p == NULL);
17079 }
17080
17081 int
17082 main ()
17083 {
17084
17085         /* pthread test function */
17086 #ifndef PTHREAD_CREATE_DETACHED
17087 #define PTHREAD_CREATE_DETACHED 1
17088 #endif
17089         pthread_t t;
17090         int status;
17091         int detach = PTHREAD_CREATE_DETACHED;
17092
17093 #if HAVE_PTHREADS > 4
17094         /* Final pthreads */
17095         pthread_attr_t attr;
17096
17097         status = pthread_attr_init(&attr);
17098         if( status ) return status;
17099
17100 #if HAVE_PTHREADS < 7
17101         status = pthread_attr_setdetachstate(&attr, &detach);
17102         if( status < 0 ) status = errno;
17103 #else
17104         status = pthread_attr_setdetachstate(&attr, detach);
17105 #endif
17106         if( status ) return status;
17107         status = pthread_create( &t, &attr, task, NULL );
17108 #if HAVE_PTHREADS < 7
17109         if( status < 0 ) status = errno;
17110 #endif
17111         if( status ) return status;
17112 #else
17113         /* Draft 4 pthreads */
17114         status = pthread_create( &t, pthread_attr_default, task, NULL );
17115         if( status ) return errno;
17116
17117         /* give thread a chance to complete */
17118         /* it should remain joinable and hence detachable */
17119         sleep( 1 );
17120
17121         status = pthread_detach( &t );
17122         if( status ) return errno;
17123 #endif
17124
17125 #ifdef HAVE_LINUX_THREADS
17126         pthread_kill_other_threads_np();
17127 #endif
17128
17129         return 0;
17130
17131   ;
17132   return 0;
17133 }
17134 _ACEOF
17135 rm -f conftest.$ac_objext conftest$ac_exeext
17136 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17137   (eval $ac_link) 2>&5
17138   ac_status=$?
17139   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17140   (exit $ac_status); } &&
17141          { ac_try='test -s conftest$ac_exeext'
17142   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17143   (eval $ac_try) 2>&5
17144   ac_status=$?
17145   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17146   (exit $ac_status); }; }; then
17147   ol_cv_pthread_thread=yes
17148 else
17149   echo "$as_me: failed program was:" >&5
17150 sed 's/^/| /' conftest.$ac_ext >&5
17151
17152 ol_cv_pthread_thread=no
17153 fi
17154 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17155 else
17156   cat >conftest.$ac_ext <<_ACEOF
17157 #line $LINENO "configure"
17158 /* confdefs.h.  */
17159 _ACEOF
17160 cat confdefs.h >>conftest.$ac_ext
17161 cat >>conftest.$ac_ext <<_ACEOF
17162 /* end confdefs.h.  */
17163 /* pthread test headers */
17164 #include <pthread.h>
17165 #if HAVE_PTHREADS < 7
17166 #include <errno.h>
17167 #endif
17168 #ifndef NULL
17169 #define NULL (void*)0
17170 #endif
17171
17172 static void *task(p)
17173         void *p;
17174 {
17175         return (void *) (p == NULL);
17176 }
17177
17178
17179 int main(argc, argv)
17180         int argc;
17181         char **argv;
17182 {
17183
17184         /* pthread test function */
17185 #ifndef PTHREAD_CREATE_DETACHED
17186 #define PTHREAD_CREATE_DETACHED 1
17187 #endif
17188         pthread_t t;
17189         int status;
17190         int detach = PTHREAD_CREATE_DETACHED;
17191
17192 #if HAVE_PTHREADS > 4
17193         /* Final pthreads */
17194         pthread_attr_t attr;
17195
17196         status = pthread_attr_init(&attr);
17197         if( status ) return status;
17198
17199 #if HAVE_PTHREADS < 7
17200         status = pthread_attr_setdetachstate(&attr, &detach);
17201         if( status < 0 ) status = errno;
17202 #else
17203         status = pthread_attr_setdetachstate(&attr, detach);
17204 #endif
17205         if( status ) return status;
17206         status = pthread_create( &t, &attr, task, NULL );
17207 #if HAVE_PTHREADS < 7
17208         if( status < 0 ) status = errno;
17209 #endif
17210         if( status ) return status;
17211 #else
17212         /* Draft 4 pthreads */
17213         status = pthread_create( &t, pthread_attr_default, task, NULL );
17214         if( status ) return errno;
17215
17216         /* give thread a chance to complete */
17217         /* it should remain joinable and hence detachable */
17218         sleep( 1 );
17219
17220         status = pthread_detach( &t );
17221         if( status ) return errno;
17222 #endif
17223
17224 #ifdef HAVE_LINUX_THREADS
17225         pthread_kill_other_threads_np();
17226 #endif
17227
17228         return 0;
17229
17230 }
17231
17232 _ACEOF
17233 rm -f conftest$ac_exeext
17234 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17235   (eval $ac_link) 2>&5
17236   ac_status=$?
17237   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17238   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17239   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17240   (eval $ac_try) 2>&5
17241   ac_status=$?
17242   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17243   (exit $ac_status); }; }; then
17244   ol_cv_pthread_thread=yes
17245 else
17246   echo "$as_me: program exited with status $ac_status" >&5
17247 echo "$as_me: failed program was:" >&5
17248 sed 's/^/| /' conftest.$ac_ext >&5
17249
17250 ( exit $ac_status )
17251 ol_cv_pthread_thread=no
17252 fi
17253 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17254 fi
17255
17256                 # restore the LIBS
17257                 LIBS="$ol_LIBS"
17258
17259 fi
17260 echo "$as_me:$LINENO: result: $ol_cv_pthread_thread" >&5
17261 echo "${ECHO_T}$ol_cv_pthread_thread" >&6
17262
17263         if test $ol_cv_pthread_thread = yes ; then
17264                 ol_link_pthreads="-thread"
17265                 ol_link_threads=posix
17266         fi
17267 fi
17268
17269
17270                 # Pthread try link: -lpthread -lmach -lexc -lc_r (ol_cv_pthread_lpthread_lmach_lexc_lc_r)
17271 if test "$ol_link_threads" = no ; then
17272         # try -lpthread -lmach -lexc -lc_r
17273         echo "$as_me:$LINENO: checking for pthread link with -lpthread -lmach -lexc -lc_r" >&5
17274 echo $ECHO_N "checking for pthread link with -lpthread -lmach -lexc -lc_r... $ECHO_C" >&6
17275 if test "${ol_cv_pthread_lpthread_lmach_lexc_lc_r+set}" = set; then
17276   echo $ECHO_N "(cached) $ECHO_C" >&6
17277 else
17278
17279                 # save the flags
17280                 ol_LIBS="$LIBS"
17281                 LIBS="-lpthread -lmach -lexc -lc_r $LIBS"
17282
17283                 if test "$cross_compiling" = yes; then
17284   cat >conftest.$ac_ext <<_ACEOF
17285 #line $LINENO "configure"
17286 /* confdefs.h.  */
17287 _ACEOF
17288 cat confdefs.h >>conftest.$ac_ext
17289 cat >>conftest.$ac_ext <<_ACEOF
17290 /* end confdefs.h.  */
17291 /* pthread test headers */
17292 #include <pthread.h>
17293 #if HAVE_PTHREADS < 7
17294 #include <errno.h>
17295 #endif
17296 #ifndef NULL
17297 #define NULL (void*)0
17298 #endif
17299
17300 static void *task(p)
17301         void *p;
17302 {
17303         return (void *) (p == NULL);
17304 }
17305
17306 int
17307 main ()
17308 {
17309
17310         /* pthread test function */
17311 #ifndef PTHREAD_CREATE_DETACHED
17312 #define PTHREAD_CREATE_DETACHED 1
17313 #endif
17314         pthread_t t;
17315         int status;
17316         int detach = PTHREAD_CREATE_DETACHED;
17317
17318 #if HAVE_PTHREADS > 4
17319         /* Final pthreads */
17320         pthread_attr_t attr;
17321
17322         status = pthread_attr_init(&attr);
17323         if( status ) return status;
17324
17325 #if HAVE_PTHREADS < 7
17326         status = pthread_attr_setdetachstate(&attr, &detach);
17327         if( status < 0 ) status = errno;
17328 #else
17329         status = pthread_attr_setdetachstate(&attr, detach);
17330 #endif
17331         if( status ) return status;
17332         status = pthread_create( &t, &attr, task, NULL );
17333 #if HAVE_PTHREADS < 7
17334         if( status < 0 ) status = errno;
17335 #endif
17336         if( status ) return status;
17337 #else
17338         /* Draft 4 pthreads */
17339         status = pthread_create( &t, pthread_attr_default, task, NULL );
17340         if( status ) return errno;
17341
17342         /* give thread a chance to complete */
17343         /* it should remain joinable and hence detachable */
17344         sleep( 1 );
17345
17346         status = pthread_detach( &t );
17347         if( status ) return errno;
17348 #endif
17349
17350 #ifdef HAVE_LINUX_THREADS
17351         pthread_kill_other_threads_np();
17352 #endif
17353
17354         return 0;
17355
17356   ;
17357   return 0;
17358 }
17359 _ACEOF
17360 rm -f conftest.$ac_objext conftest$ac_exeext
17361 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17362   (eval $ac_link) 2>&5
17363   ac_status=$?
17364   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17365   (exit $ac_status); } &&
17366          { ac_try='test -s conftest$ac_exeext'
17367   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17368   (eval $ac_try) 2>&5
17369   ac_status=$?
17370   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17371   (exit $ac_status); }; }; then
17372   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
17373 else
17374   echo "$as_me: failed program was:" >&5
17375 sed 's/^/| /' conftest.$ac_ext >&5
17376
17377 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
17378 fi
17379 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17380 else
17381   cat >conftest.$ac_ext <<_ACEOF
17382 #line $LINENO "configure"
17383 /* confdefs.h.  */
17384 _ACEOF
17385 cat confdefs.h >>conftest.$ac_ext
17386 cat >>conftest.$ac_ext <<_ACEOF
17387 /* end confdefs.h.  */
17388 /* pthread test headers */
17389 #include <pthread.h>
17390 #if HAVE_PTHREADS < 7
17391 #include <errno.h>
17392 #endif
17393 #ifndef NULL
17394 #define NULL (void*)0
17395 #endif
17396
17397 static void *task(p)
17398         void *p;
17399 {
17400         return (void *) (p == NULL);
17401 }
17402
17403
17404 int main(argc, argv)
17405         int argc;
17406         char **argv;
17407 {
17408
17409         /* pthread test function */
17410 #ifndef PTHREAD_CREATE_DETACHED
17411 #define PTHREAD_CREATE_DETACHED 1
17412 #endif
17413         pthread_t t;
17414         int status;
17415         int detach = PTHREAD_CREATE_DETACHED;
17416
17417 #if HAVE_PTHREADS > 4
17418         /* Final pthreads */
17419         pthread_attr_t attr;
17420
17421         status = pthread_attr_init(&attr);
17422         if( status ) return status;
17423
17424 #if HAVE_PTHREADS < 7
17425         status = pthread_attr_setdetachstate(&attr, &detach);
17426         if( status < 0 ) status = errno;
17427 #else
17428         status = pthread_attr_setdetachstate(&attr, detach);
17429 #endif
17430         if( status ) return status;
17431         status = pthread_create( &t, &attr, task, NULL );
17432 #if HAVE_PTHREADS < 7
17433         if( status < 0 ) status = errno;
17434 #endif
17435         if( status ) return status;
17436 #else
17437         /* Draft 4 pthreads */
17438         status = pthread_create( &t, pthread_attr_default, task, NULL );
17439         if( status ) return errno;
17440
17441         /* give thread a chance to complete */
17442         /* it should remain joinable and hence detachable */
17443         sleep( 1 );
17444
17445         status = pthread_detach( &t );
17446         if( status ) return errno;
17447 #endif
17448
17449 #ifdef HAVE_LINUX_THREADS
17450         pthread_kill_other_threads_np();
17451 #endif
17452
17453         return 0;
17454
17455 }
17456
17457 _ACEOF
17458 rm -f conftest$ac_exeext
17459 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17460   (eval $ac_link) 2>&5
17461   ac_status=$?
17462   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17463   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17464   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17465   (eval $ac_try) 2>&5
17466   ac_status=$?
17467   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17468   (exit $ac_status); }; }; then
17469   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
17470 else
17471   echo "$as_me: program exited with status $ac_status" >&5
17472 echo "$as_me: failed program was:" >&5
17473 sed 's/^/| /' conftest.$ac_ext >&5
17474
17475 ( exit $ac_status )
17476 ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
17477 fi
17478 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17479 fi
17480
17481                 # restore the LIBS
17482                 LIBS="$ol_LIBS"
17483
17484 fi
17485 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&5
17486 echo "${ECHO_T}$ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&6
17487
17488         if test $ol_cv_pthread_lpthread_lmach_lexc_lc_r = yes ; then
17489                 ol_link_pthreads="-lpthread -lmach -lexc -lc_r"
17490                 ol_link_threads=posix
17491         fi
17492 fi
17493
17494                 # Pthread try link: -lpthread -lmach -lexc (ol_cv_pthread_lpthread_lmach_lexc)
17495 if test "$ol_link_threads" = no ; then
17496         # try -lpthread -lmach -lexc
17497         echo "$as_me:$LINENO: checking for pthread link with -lpthread -lmach -lexc" >&5
17498 echo $ECHO_N "checking for pthread link with -lpthread -lmach -lexc... $ECHO_C" >&6
17499 if test "${ol_cv_pthread_lpthread_lmach_lexc+set}" = set; then
17500   echo $ECHO_N "(cached) $ECHO_C" >&6
17501 else
17502
17503                 # save the flags
17504                 ol_LIBS="$LIBS"
17505                 LIBS="-lpthread -lmach -lexc $LIBS"
17506
17507                 if test "$cross_compiling" = yes; then
17508   cat >conftest.$ac_ext <<_ACEOF
17509 #line $LINENO "configure"
17510 /* confdefs.h.  */
17511 _ACEOF
17512 cat confdefs.h >>conftest.$ac_ext
17513 cat >>conftest.$ac_ext <<_ACEOF
17514 /* end confdefs.h.  */
17515 /* pthread test headers */
17516 #include <pthread.h>
17517 #if HAVE_PTHREADS < 7
17518 #include <errno.h>
17519 #endif
17520 #ifndef NULL
17521 #define NULL (void*)0
17522 #endif
17523
17524 static void *task(p)
17525         void *p;
17526 {
17527         return (void *) (p == NULL);
17528 }
17529
17530 int
17531 main ()
17532 {
17533
17534         /* pthread test function */
17535 #ifndef PTHREAD_CREATE_DETACHED
17536 #define PTHREAD_CREATE_DETACHED 1
17537 #endif
17538         pthread_t t;
17539         int status;
17540         int detach = PTHREAD_CREATE_DETACHED;
17541
17542 #if HAVE_PTHREADS > 4
17543         /* Final pthreads */
17544         pthread_attr_t attr;
17545
17546         status = pthread_attr_init(&attr);
17547         if( status ) return status;
17548
17549 #if HAVE_PTHREADS < 7
17550         status = pthread_attr_setdetachstate(&attr, &detach);
17551         if( status < 0 ) status = errno;
17552 #else
17553         status = pthread_attr_setdetachstate(&attr, detach);
17554 #endif
17555         if( status ) return status;
17556         status = pthread_create( &t, &attr, task, NULL );
17557 #if HAVE_PTHREADS < 7
17558         if( status < 0 ) status = errno;
17559 #endif
17560         if( status ) return status;
17561 #else
17562         /* Draft 4 pthreads */
17563         status = pthread_create( &t, pthread_attr_default, task, NULL );
17564         if( status ) return errno;
17565
17566         /* give thread a chance to complete */
17567         /* it should remain joinable and hence detachable */
17568         sleep( 1 );
17569
17570         status = pthread_detach( &t );
17571         if( status ) return errno;
17572 #endif
17573
17574 #ifdef HAVE_LINUX_THREADS
17575         pthread_kill_other_threads_np();
17576 #endif
17577
17578         return 0;
17579
17580   ;
17581   return 0;
17582 }
17583 _ACEOF
17584 rm -f conftest.$ac_objext conftest$ac_exeext
17585 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17586   (eval $ac_link) 2>&5
17587   ac_status=$?
17588   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17589   (exit $ac_status); } &&
17590          { ac_try='test -s conftest$ac_exeext'
17591   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17592   (eval $ac_try) 2>&5
17593   ac_status=$?
17594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17595   (exit $ac_status); }; }; then
17596   ol_cv_pthread_lpthread_lmach_lexc=yes
17597 else
17598   echo "$as_me: failed program was:" >&5
17599 sed 's/^/| /' conftest.$ac_ext >&5
17600
17601 ol_cv_pthread_lpthread_lmach_lexc=no
17602 fi
17603 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17604 else
17605   cat >conftest.$ac_ext <<_ACEOF
17606 #line $LINENO "configure"
17607 /* confdefs.h.  */
17608 _ACEOF
17609 cat confdefs.h >>conftest.$ac_ext
17610 cat >>conftest.$ac_ext <<_ACEOF
17611 /* end confdefs.h.  */
17612 /* pthread test headers */
17613 #include <pthread.h>
17614 #if HAVE_PTHREADS < 7
17615 #include <errno.h>
17616 #endif
17617 #ifndef NULL
17618 #define NULL (void*)0
17619 #endif
17620
17621 static void *task(p)
17622         void *p;
17623 {
17624         return (void *) (p == NULL);
17625 }
17626
17627
17628 int main(argc, argv)
17629         int argc;
17630         char **argv;
17631 {
17632
17633         /* pthread test function */
17634 #ifndef PTHREAD_CREATE_DETACHED
17635 #define PTHREAD_CREATE_DETACHED 1
17636 #endif
17637         pthread_t t;
17638         int status;
17639         int detach = PTHREAD_CREATE_DETACHED;
17640
17641 #if HAVE_PTHREADS > 4
17642         /* Final pthreads */
17643         pthread_attr_t attr;
17644
17645         status = pthread_attr_init(&attr);
17646         if( status ) return status;
17647
17648 #if HAVE_PTHREADS < 7
17649         status = pthread_attr_setdetachstate(&attr, &detach);
17650         if( status < 0 ) status = errno;
17651 #else
17652         status = pthread_attr_setdetachstate(&attr, detach);
17653 #endif
17654         if( status ) return status;
17655         status = pthread_create( &t, &attr, task, NULL );
17656 #if HAVE_PTHREADS < 7
17657         if( status < 0 ) status = errno;
17658 #endif
17659         if( status ) return status;
17660 #else
17661         /* Draft 4 pthreads */
17662         status = pthread_create( &t, pthread_attr_default, task, NULL );
17663         if( status ) return errno;
17664
17665         /* give thread a chance to complete */
17666         /* it should remain joinable and hence detachable */
17667         sleep( 1 );
17668
17669         status = pthread_detach( &t );
17670         if( status ) return errno;
17671 #endif
17672
17673 #ifdef HAVE_LINUX_THREADS
17674         pthread_kill_other_threads_np();
17675 #endif
17676
17677         return 0;
17678
17679 }
17680
17681 _ACEOF
17682 rm -f conftest$ac_exeext
17683 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17684   (eval $ac_link) 2>&5
17685   ac_status=$?
17686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17687   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17688   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17689   (eval $ac_try) 2>&5
17690   ac_status=$?
17691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17692   (exit $ac_status); }; }; then
17693   ol_cv_pthread_lpthread_lmach_lexc=yes
17694 else
17695   echo "$as_me: program exited with status $ac_status" >&5
17696 echo "$as_me: failed program was:" >&5
17697 sed 's/^/| /' conftest.$ac_ext >&5
17698
17699 ( exit $ac_status )
17700 ol_cv_pthread_lpthread_lmach_lexc=no
17701 fi
17702 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17703 fi
17704
17705                 # restore the LIBS
17706                 LIBS="$ol_LIBS"
17707
17708 fi
17709 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread_lmach_lexc" >&5
17710 echo "${ECHO_T}$ol_cv_pthread_lpthread_lmach_lexc" >&6
17711
17712         if test $ol_cv_pthread_lpthread_lmach_lexc = yes ; then
17713                 ol_link_pthreads="-lpthread -lmach -lexc"
17714                 ol_link_threads=posix
17715         fi
17716 fi
17717
17718
17719                 # Pthread try link: -lpthread -Wl,-woff,85 (ol_cv_pthread_lib_lpthread_woff)
17720 if test "$ol_link_threads" = no ; then
17721         # try -lpthread -Wl,-woff,85
17722         echo "$as_me:$LINENO: checking for pthread link with -lpthread -Wl,-woff,85" >&5
17723 echo $ECHO_N "checking for pthread link with -lpthread -Wl,-woff,85... $ECHO_C" >&6
17724 if test "${ol_cv_pthread_lib_lpthread_woff+set}" = set; then
17725   echo $ECHO_N "(cached) $ECHO_C" >&6
17726 else
17727
17728                 # save the flags
17729                 ol_LIBS="$LIBS"
17730                 LIBS="-lpthread -Wl,-woff,85 $LIBS"
17731
17732                 if test "$cross_compiling" = yes; then
17733   cat >conftest.$ac_ext <<_ACEOF
17734 #line $LINENO "configure"
17735 /* confdefs.h.  */
17736 _ACEOF
17737 cat confdefs.h >>conftest.$ac_ext
17738 cat >>conftest.$ac_ext <<_ACEOF
17739 /* end confdefs.h.  */
17740 /* pthread test headers */
17741 #include <pthread.h>
17742 #if HAVE_PTHREADS < 7
17743 #include <errno.h>
17744 #endif
17745 #ifndef NULL
17746 #define NULL (void*)0
17747 #endif
17748
17749 static void *task(p)
17750         void *p;
17751 {
17752         return (void *) (p == NULL);
17753 }
17754
17755 int
17756 main ()
17757 {
17758
17759         /* pthread test function */
17760 #ifndef PTHREAD_CREATE_DETACHED
17761 #define PTHREAD_CREATE_DETACHED 1
17762 #endif
17763         pthread_t t;
17764         int status;
17765         int detach = PTHREAD_CREATE_DETACHED;
17766
17767 #if HAVE_PTHREADS > 4
17768         /* Final pthreads */
17769         pthread_attr_t attr;
17770
17771         status = pthread_attr_init(&attr);
17772         if( status ) return status;
17773
17774 #if HAVE_PTHREADS < 7
17775         status = pthread_attr_setdetachstate(&attr, &detach);
17776         if( status < 0 ) status = errno;
17777 #else
17778         status = pthread_attr_setdetachstate(&attr, detach);
17779 #endif
17780         if( status ) return status;
17781         status = pthread_create( &t, &attr, task, NULL );
17782 #if HAVE_PTHREADS < 7
17783         if( status < 0 ) status = errno;
17784 #endif
17785         if( status ) return status;
17786 #else
17787         /* Draft 4 pthreads */
17788         status = pthread_create( &t, pthread_attr_default, task, NULL );
17789         if( status ) return errno;
17790
17791         /* give thread a chance to complete */
17792         /* it should remain joinable and hence detachable */
17793         sleep( 1 );
17794
17795         status = pthread_detach( &t );
17796         if( status ) return errno;
17797 #endif
17798
17799 #ifdef HAVE_LINUX_THREADS
17800         pthread_kill_other_threads_np();
17801 #endif
17802
17803         return 0;
17804
17805   ;
17806   return 0;
17807 }
17808 _ACEOF
17809 rm -f conftest.$ac_objext conftest$ac_exeext
17810 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17811   (eval $ac_link) 2>&5
17812   ac_status=$?
17813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17814   (exit $ac_status); } &&
17815          { ac_try='test -s conftest$ac_exeext'
17816   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17817   (eval $ac_try) 2>&5
17818   ac_status=$?
17819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17820   (exit $ac_status); }; }; then
17821   ol_cv_pthread_lib_lpthread_woff=yes
17822 else
17823   echo "$as_me: failed program was:" >&5
17824 sed 's/^/| /' conftest.$ac_ext >&5
17825
17826 ol_cv_pthread_lib_lpthread_woff=no
17827 fi
17828 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17829 else
17830   cat >conftest.$ac_ext <<_ACEOF
17831 #line $LINENO "configure"
17832 /* confdefs.h.  */
17833 _ACEOF
17834 cat confdefs.h >>conftest.$ac_ext
17835 cat >>conftest.$ac_ext <<_ACEOF
17836 /* end confdefs.h.  */
17837 /* pthread test headers */
17838 #include <pthread.h>
17839 #if HAVE_PTHREADS < 7
17840 #include <errno.h>
17841 #endif
17842 #ifndef NULL
17843 #define NULL (void*)0
17844 #endif
17845
17846 static void *task(p)
17847         void *p;
17848 {
17849         return (void *) (p == NULL);
17850 }
17851
17852
17853 int main(argc, argv)
17854         int argc;
17855         char **argv;
17856 {
17857
17858         /* pthread test function */
17859 #ifndef PTHREAD_CREATE_DETACHED
17860 #define PTHREAD_CREATE_DETACHED 1
17861 #endif
17862         pthread_t t;
17863         int status;
17864         int detach = PTHREAD_CREATE_DETACHED;
17865
17866 #if HAVE_PTHREADS > 4
17867         /* Final pthreads */
17868         pthread_attr_t attr;
17869
17870         status = pthread_attr_init(&attr);
17871         if( status ) return status;
17872
17873 #if HAVE_PTHREADS < 7
17874         status = pthread_attr_setdetachstate(&attr, &detach);
17875         if( status < 0 ) status = errno;
17876 #else
17877         status = pthread_attr_setdetachstate(&attr, detach);
17878 #endif
17879         if( status ) return status;
17880         status = pthread_create( &t, &attr, task, NULL );
17881 #if HAVE_PTHREADS < 7
17882         if( status < 0 ) status = errno;
17883 #endif
17884         if( status ) return status;
17885 #else
17886         /* Draft 4 pthreads */
17887         status = pthread_create( &t, pthread_attr_default, task, NULL );
17888         if( status ) return errno;
17889
17890         /* give thread a chance to complete */
17891         /* it should remain joinable and hence detachable */
17892         sleep( 1 );
17893
17894         status = pthread_detach( &t );
17895         if( status ) return errno;
17896 #endif
17897
17898 #ifdef HAVE_LINUX_THREADS
17899         pthread_kill_other_threads_np();
17900 #endif
17901
17902         return 0;
17903
17904 }
17905
17906 _ACEOF
17907 rm -f conftest$ac_exeext
17908 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17909   (eval $ac_link) 2>&5
17910   ac_status=$?
17911   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17912   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17913   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17914   (eval $ac_try) 2>&5
17915   ac_status=$?
17916   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17917   (exit $ac_status); }; }; then
17918   ol_cv_pthread_lib_lpthread_woff=yes
17919 else
17920   echo "$as_me: program exited with status $ac_status" >&5
17921 echo "$as_me: failed program was:" >&5
17922 sed 's/^/| /' conftest.$ac_ext >&5
17923
17924 ( exit $ac_status )
17925 ol_cv_pthread_lib_lpthread_woff=no
17926 fi
17927 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17928 fi
17929
17930                 # restore the LIBS
17931                 LIBS="$ol_LIBS"
17932
17933 fi
17934 echo "$as_me:$LINENO: result: $ol_cv_pthread_lib_lpthread_woff" >&5
17935 echo "${ECHO_T}$ol_cv_pthread_lib_lpthread_woff" >&6
17936
17937         if test $ol_cv_pthread_lib_lpthread_woff = yes ; then
17938                 ol_link_pthreads="-lpthread -Wl,-woff,85"
17939                 ol_link_threads=posix
17940         fi
17941 fi
17942
17943
17944                 # Pthread try link: -lpthread (ol_cv_pthread_lpthread)
17945 if test "$ol_link_threads" = no ; then
17946         # try -lpthread
17947         echo "$as_me:$LINENO: checking for pthread link with -lpthread" >&5
17948 echo $ECHO_N "checking for pthread link with -lpthread... $ECHO_C" >&6
17949 if test "${ol_cv_pthread_lpthread+set}" = set; then
17950   echo $ECHO_N "(cached) $ECHO_C" >&6
17951 else
17952
17953                 # save the flags
17954                 ol_LIBS="$LIBS"
17955                 LIBS="-lpthread $LIBS"
17956
17957                 if test "$cross_compiling" = yes; then
17958   cat >conftest.$ac_ext <<_ACEOF
17959 #line $LINENO "configure"
17960 /* confdefs.h.  */
17961 _ACEOF
17962 cat confdefs.h >>conftest.$ac_ext
17963 cat >>conftest.$ac_ext <<_ACEOF
17964 /* end confdefs.h.  */
17965 /* pthread test headers */
17966 #include <pthread.h>
17967 #if HAVE_PTHREADS < 7
17968 #include <errno.h>
17969 #endif
17970 #ifndef NULL
17971 #define NULL (void*)0
17972 #endif
17973
17974 static void *task(p)
17975         void *p;
17976 {
17977         return (void *) (p == NULL);
17978 }
17979
17980 int
17981 main ()
17982 {
17983
17984         /* pthread test function */
17985 #ifndef PTHREAD_CREATE_DETACHED
17986 #define PTHREAD_CREATE_DETACHED 1
17987 #endif
17988         pthread_t t;
17989         int status;
17990         int detach = PTHREAD_CREATE_DETACHED;
17991
17992 #if HAVE_PTHREADS > 4
17993         /* Final pthreads */
17994         pthread_attr_t attr;
17995
17996         status = pthread_attr_init(&attr);
17997         if( status ) return status;
17998
17999 #if HAVE_PTHREADS < 7
18000         status = pthread_attr_setdetachstate(&attr, &detach);
18001         if( status < 0 ) status = errno;
18002 #else
18003         status = pthread_attr_setdetachstate(&attr, detach);
18004 #endif
18005         if( status ) return status;
18006         status = pthread_create( &t, &attr, task, NULL );
18007 #if HAVE_PTHREADS < 7
18008         if( status < 0 ) status = errno;
18009 #endif
18010         if( status ) return status;
18011 #else
18012         /* Draft 4 pthreads */
18013         status = pthread_create( &t, pthread_attr_default, task, NULL );
18014         if( status ) return errno;
18015
18016         /* give thread a chance to complete */
18017         /* it should remain joinable and hence detachable */
18018         sleep( 1 );
18019
18020         status = pthread_detach( &t );
18021         if( status ) return errno;
18022 #endif
18023
18024 #ifdef HAVE_LINUX_THREADS
18025         pthread_kill_other_threads_np();
18026 #endif
18027
18028         return 0;
18029
18030   ;
18031   return 0;
18032 }
18033 _ACEOF
18034 rm -f conftest.$ac_objext conftest$ac_exeext
18035 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18036   (eval $ac_link) 2>&5
18037   ac_status=$?
18038   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18039   (exit $ac_status); } &&
18040          { ac_try='test -s conftest$ac_exeext'
18041   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18042   (eval $ac_try) 2>&5
18043   ac_status=$?
18044   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18045   (exit $ac_status); }; }; then
18046   ol_cv_pthread_lpthread=yes
18047 else
18048   echo "$as_me: failed program was:" >&5
18049 sed 's/^/| /' conftest.$ac_ext >&5
18050
18051 ol_cv_pthread_lpthread=no
18052 fi
18053 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18054 else
18055   cat >conftest.$ac_ext <<_ACEOF
18056 #line $LINENO "configure"
18057 /* confdefs.h.  */
18058 _ACEOF
18059 cat confdefs.h >>conftest.$ac_ext
18060 cat >>conftest.$ac_ext <<_ACEOF
18061 /* end confdefs.h.  */
18062 /* pthread test headers */
18063 #include <pthread.h>
18064 #if HAVE_PTHREADS < 7
18065 #include <errno.h>
18066 #endif
18067 #ifndef NULL
18068 #define NULL (void*)0
18069 #endif
18070
18071 static void *task(p)
18072         void *p;
18073 {
18074         return (void *) (p == NULL);
18075 }
18076
18077
18078 int main(argc, argv)
18079         int argc;
18080         char **argv;
18081 {
18082
18083         /* pthread test function */
18084 #ifndef PTHREAD_CREATE_DETACHED
18085 #define PTHREAD_CREATE_DETACHED 1
18086 #endif
18087         pthread_t t;
18088         int status;
18089         int detach = PTHREAD_CREATE_DETACHED;
18090
18091 #if HAVE_PTHREADS > 4
18092         /* Final pthreads */
18093         pthread_attr_t attr;
18094
18095         status = pthread_attr_init(&attr);
18096         if( status ) return status;
18097
18098 #if HAVE_PTHREADS < 7
18099         status = pthread_attr_setdetachstate(&attr, &detach);
18100         if( status < 0 ) status = errno;
18101 #else
18102         status = pthread_attr_setdetachstate(&attr, detach);
18103 #endif
18104         if( status ) return status;
18105         status = pthread_create( &t, &attr, task, NULL );
18106 #if HAVE_PTHREADS < 7
18107         if( status < 0 ) status = errno;
18108 #endif
18109         if( status ) return status;
18110 #else
18111         /* Draft 4 pthreads */
18112         status = pthread_create( &t, pthread_attr_default, task, NULL );
18113         if( status ) return errno;
18114
18115         /* give thread a chance to complete */
18116         /* it should remain joinable and hence detachable */
18117         sleep( 1 );
18118
18119         status = pthread_detach( &t );
18120         if( status ) return errno;
18121 #endif
18122
18123 #ifdef HAVE_LINUX_THREADS
18124         pthread_kill_other_threads_np();
18125 #endif
18126
18127         return 0;
18128
18129 }
18130
18131 _ACEOF
18132 rm -f conftest$ac_exeext
18133 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18134   (eval $ac_link) 2>&5
18135   ac_status=$?
18136   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18137   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18138   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18139   (eval $ac_try) 2>&5
18140   ac_status=$?
18141   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18142   (exit $ac_status); }; }; then
18143   ol_cv_pthread_lpthread=yes
18144 else
18145   echo "$as_me: program exited with status $ac_status" >&5
18146 echo "$as_me: failed program was:" >&5
18147 sed 's/^/| /' conftest.$ac_ext >&5
18148
18149 ( exit $ac_status )
18150 ol_cv_pthread_lpthread=no
18151 fi
18152 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18153 fi
18154
18155                 # restore the LIBS
18156                 LIBS="$ol_LIBS"
18157
18158 fi
18159 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthread" >&5
18160 echo "${ECHO_T}$ol_cv_pthread_lpthread" >&6
18161
18162         if test $ol_cv_pthread_lpthread = yes ; then
18163                 ol_link_pthreads="-lpthread"
18164                 ol_link_threads=posix
18165         fi
18166 fi
18167
18168                 # Pthread try link: -lc_r (ol_cv_pthread_lc_r)
18169 if test "$ol_link_threads" = no ; then
18170         # try -lc_r
18171         echo "$as_me:$LINENO: checking for pthread link with -lc_r" >&5
18172 echo $ECHO_N "checking for pthread link with -lc_r... $ECHO_C" >&6
18173 if test "${ol_cv_pthread_lc_r+set}" = set; then
18174   echo $ECHO_N "(cached) $ECHO_C" >&6
18175 else
18176
18177                 # save the flags
18178                 ol_LIBS="$LIBS"
18179                 LIBS="-lc_r $LIBS"
18180
18181                 if test "$cross_compiling" = yes; then
18182   cat >conftest.$ac_ext <<_ACEOF
18183 #line $LINENO "configure"
18184 /* confdefs.h.  */
18185 _ACEOF
18186 cat confdefs.h >>conftest.$ac_ext
18187 cat >>conftest.$ac_ext <<_ACEOF
18188 /* end confdefs.h.  */
18189 /* pthread test headers */
18190 #include <pthread.h>
18191 #if HAVE_PTHREADS < 7
18192 #include <errno.h>
18193 #endif
18194 #ifndef NULL
18195 #define NULL (void*)0
18196 #endif
18197
18198 static void *task(p)
18199         void *p;
18200 {
18201         return (void *) (p == NULL);
18202 }
18203
18204 int
18205 main ()
18206 {
18207
18208         /* pthread test function */
18209 #ifndef PTHREAD_CREATE_DETACHED
18210 #define PTHREAD_CREATE_DETACHED 1
18211 #endif
18212         pthread_t t;
18213         int status;
18214         int detach = PTHREAD_CREATE_DETACHED;
18215
18216 #if HAVE_PTHREADS > 4
18217         /* Final pthreads */
18218         pthread_attr_t attr;
18219
18220         status = pthread_attr_init(&attr);
18221         if( status ) return status;
18222
18223 #if HAVE_PTHREADS < 7
18224         status = pthread_attr_setdetachstate(&attr, &detach);
18225         if( status < 0 ) status = errno;
18226 #else
18227         status = pthread_attr_setdetachstate(&attr, detach);
18228 #endif
18229         if( status ) return status;
18230         status = pthread_create( &t, &attr, task, NULL );
18231 #if HAVE_PTHREADS < 7
18232         if( status < 0 ) status = errno;
18233 #endif
18234         if( status ) return status;
18235 #else
18236         /* Draft 4 pthreads */
18237         status = pthread_create( &t, pthread_attr_default, task, NULL );
18238         if( status ) return errno;
18239
18240         /* give thread a chance to complete */
18241         /* it should remain joinable and hence detachable */
18242         sleep( 1 );
18243
18244         status = pthread_detach( &t );
18245         if( status ) return errno;
18246 #endif
18247
18248 #ifdef HAVE_LINUX_THREADS
18249         pthread_kill_other_threads_np();
18250 #endif
18251
18252         return 0;
18253
18254   ;
18255   return 0;
18256 }
18257 _ACEOF
18258 rm -f conftest.$ac_objext conftest$ac_exeext
18259 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18260   (eval $ac_link) 2>&5
18261   ac_status=$?
18262   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18263   (exit $ac_status); } &&
18264          { ac_try='test -s conftest$ac_exeext'
18265   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18266   (eval $ac_try) 2>&5
18267   ac_status=$?
18268   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18269   (exit $ac_status); }; }; then
18270   ol_cv_pthread_lc_r=yes
18271 else
18272   echo "$as_me: failed program was:" >&5
18273 sed 's/^/| /' conftest.$ac_ext >&5
18274
18275 ol_cv_pthread_lc_r=no
18276 fi
18277 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18278 else
18279   cat >conftest.$ac_ext <<_ACEOF
18280 #line $LINENO "configure"
18281 /* confdefs.h.  */
18282 _ACEOF
18283 cat confdefs.h >>conftest.$ac_ext
18284 cat >>conftest.$ac_ext <<_ACEOF
18285 /* end confdefs.h.  */
18286 /* pthread test headers */
18287 #include <pthread.h>
18288 #if HAVE_PTHREADS < 7
18289 #include <errno.h>
18290 #endif
18291 #ifndef NULL
18292 #define NULL (void*)0
18293 #endif
18294
18295 static void *task(p)
18296         void *p;
18297 {
18298         return (void *) (p == NULL);
18299 }
18300
18301
18302 int main(argc, argv)
18303         int argc;
18304         char **argv;
18305 {
18306
18307         /* pthread test function */
18308 #ifndef PTHREAD_CREATE_DETACHED
18309 #define PTHREAD_CREATE_DETACHED 1
18310 #endif
18311         pthread_t t;
18312         int status;
18313         int detach = PTHREAD_CREATE_DETACHED;
18314
18315 #if HAVE_PTHREADS > 4
18316         /* Final pthreads */
18317         pthread_attr_t attr;
18318
18319         status = pthread_attr_init(&attr);
18320         if( status ) return status;
18321
18322 #if HAVE_PTHREADS < 7
18323         status = pthread_attr_setdetachstate(&attr, &detach);
18324         if( status < 0 ) status = errno;
18325 #else
18326         status = pthread_attr_setdetachstate(&attr, detach);
18327 #endif
18328         if( status ) return status;
18329         status = pthread_create( &t, &attr, task, NULL );
18330 #if HAVE_PTHREADS < 7
18331         if( status < 0 ) status = errno;
18332 #endif
18333         if( status ) return status;
18334 #else
18335         /* Draft 4 pthreads */
18336         status = pthread_create( &t, pthread_attr_default, task, NULL );
18337         if( status ) return errno;
18338
18339         /* give thread a chance to complete */
18340         /* it should remain joinable and hence detachable */
18341         sleep( 1 );
18342
18343         status = pthread_detach( &t );
18344         if( status ) return errno;
18345 #endif
18346
18347 #ifdef HAVE_LINUX_THREADS
18348         pthread_kill_other_threads_np();
18349 #endif
18350
18351         return 0;
18352
18353 }
18354
18355 _ACEOF
18356 rm -f conftest$ac_exeext
18357 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18358   (eval $ac_link) 2>&5
18359   ac_status=$?
18360   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18361   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18362   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18363   (eval $ac_try) 2>&5
18364   ac_status=$?
18365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18366   (exit $ac_status); }; }; then
18367   ol_cv_pthread_lc_r=yes
18368 else
18369   echo "$as_me: program exited with status $ac_status" >&5
18370 echo "$as_me: failed program was:" >&5
18371 sed 's/^/| /' conftest.$ac_ext >&5
18372
18373 ( exit $ac_status )
18374 ol_cv_pthread_lc_r=no
18375 fi
18376 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18377 fi
18378
18379                 # restore the LIBS
18380                 LIBS="$ol_LIBS"
18381
18382 fi
18383 echo "$as_me:$LINENO: result: $ol_cv_pthread_lc_r" >&5
18384 echo "${ECHO_T}$ol_cv_pthread_lc_r" >&6
18385
18386         if test $ol_cv_pthread_lc_r = yes ; then
18387                 ol_link_pthreads="-lc_r"
18388                 ol_link_threads=posix
18389         fi
18390 fi
18391
18392
18393                 # Pthread try link: -threads (ol_cv_pthread_threads)
18394 if test "$ol_link_threads" = no ; then
18395         # try -threads
18396         echo "$as_me:$LINENO: checking for pthread link with -threads" >&5
18397 echo $ECHO_N "checking for pthread link with -threads... $ECHO_C" >&6
18398 if test "${ol_cv_pthread_threads+set}" = set; then
18399   echo $ECHO_N "(cached) $ECHO_C" >&6
18400 else
18401
18402                 # save the flags
18403                 ol_LIBS="$LIBS"
18404                 LIBS="-threads $LIBS"
18405
18406                 if test "$cross_compiling" = yes; then
18407   cat >conftest.$ac_ext <<_ACEOF
18408 #line $LINENO "configure"
18409 /* confdefs.h.  */
18410 _ACEOF
18411 cat confdefs.h >>conftest.$ac_ext
18412 cat >>conftest.$ac_ext <<_ACEOF
18413 /* end confdefs.h.  */
18414 /* pthread test headers */
18415 #include <pthread.h>
18416 #if HAVE_PTHREADS < 7
18417 #include <errno.h>
18418 #endif
18419 #ifndef NULL
18420 #define NULL (void*)0
18421 #endif
18422
18423 static void *task(p)
18424         void *p;
18425 {
18426         return (void *) (p == NULL);
18427 }
18428
18429 int
18430 main ()
18431 {
18432
18433         /* pthread test function */
18434 #ifndef PTHREAD_CREATE_DETACHED
18435 #define PTHREAD_CREATE_DETACHED 1
18436 #endif
18437         pthread_t t;
18438         int status;
18439         int detach = PTHREAD_CREATE_DETACHED;
18440
18441 #if HAVE_PTHREADS > 4
18442         /* Final pthreads */
18443         pthread_attr_t attr;
18444
18445         status = pthread_attr_init(&attr);
18446         if( status ) return status;
18447
18448 #if HAVE_PTHREADS < 7
18449         status = pthread_attr_setdetachstate(&attr, &detach);
18450         if( status < 0 ) status = errno;
18451 #else
18452         status = pthread_attr_setdetachstate(&attr, detach);
18453 #endif
18454         if( status ) return status;
18455         status = pthread_create( &t, &attr, task, NULL );
18456 #if HAVE_PTHREADS < 7
18457         if( status < 0 ) status = errno;
18458 #endif
18459         if( status ) return status;
18460 #else
18461         /* Draft 4 pthreads */
18462         status = pthread_create( &t, pthread_attr_default, task, NULL );
18463         if( status ) return errno;
18464
18465         /* give thread a chance to complete */
18466         /* it should remain joinable and hence detachable */
18467         sleep( 1 );
18468
18469         status = pthread_detach( &t );
18470         if( status ) return errno;
18471 #endif
18472
18473 #ifdef HAVE_LINUX_THREADS
18474         pthread_kill_other_threads_np();
18475 #endif
18476
18477         return 0;
18478
18479   ;
18480   return 0;
18481 }
18482 _ACEOF
18483 rm -f conftest.$ac_objext conftest$ac_exeext
18484 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18485   (eval $ac_link) 2>&5
18486   ac_status=$?
18487   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18488   (exit $ac_status); } &&
18489          { ac_try='test -s conftest$ac_exeext'
18490   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18491   (eval $ac_try) 2>&5
18492   ac_status=$?
18493   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18494   (exit $ac_status); }; }; then
18495   ol_cv_pthread_threads=yes
18496 else
18497   echo "$as_me: failed program was:" >&5
18498 sed 's/^/| /' conftest.$ac_ext >&5
18499
18500 ol_cv_pthread_threads=no
18501 fi
18502 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18503 else
18504   cat >conftest.$ac_ext <<_ACEOF
18505 #line $LINENO "configure"
18506 /* confdefs.h.  */
18507 _ACEOF
18508 cat confdefs.h >>conftest.$ac_ext
18509 cat >>conftest.$ac_ext <<_ACEOF
18510 /* end confdefs.h.  */
18511 /* pthread test headers */
18512 #include <pthread.h>
18513 #if HAVE_PTHREADS < 7
18514 #include <errno.h>
18515 #endif
18516 #ifndef NULL
18517 #define NULL (void*)0
18518 #endif
18519
18520 static void *task(p)
18521         void *p;
18522 {
18523         return (void *) (p == NULL);
18524 }
18525
18526
18527 int main(argc, argv)
18528         int argc;
18529         char **argv;
18530 {
18531
18532         /* pthread test function */
18533 #ifndef PTHREAD_CREATE_DETACHED
18534 #define PTHREAD_CREATE_DETACHED 1
18535 #endif
18536         pthread_t t;
18537         int status;
18538         int detach = PTHREAD_CREATE_DETACHED;
18539
18540 #if HAVE_PTHREADS > 4
18541         /* Final pthreads */
18542         pthread_attr_t attr;
18543
18544         status = pthread_attr_init(&attr);
18545         if( status ) return status;
18546
18547 #if HAVE_PTHREADS < 7
18548         status = pthread_attr_setdetachstate(&attr, &detach);
18549         if( status < 0 ) status = errno;
18550 #else
18551         status = pthread_attr_setdetachstate(&attr, detach);
18552 #endif
18553         if( status ) return status;
18554         status = pthread_create( &t, &attr, task, NULL );
18555 #if HAVE_PTHREADS < 7
18556         if( status < 0 ) status = errno;
18557 #endif
18558         if( status ) return status;
18559 #else
18560         /* Draft 4 pthreads */
18561         status = pthread_create( &t, pthread_attr_default, task, NULL );
18562         if( status ) return errno;
18563
18564         /* give thread a chance to complete */
18565         /* it should remain joinable and hence detachable */
18566         sleep( 1 );
18567
18568         status = pthread_detach( &t );
18569         if( status ) return errno;
18570 #endif
18571
18572 #ifdef HAVE_LINUX_THREADS
18573         pthread_kill_other_threads_np();
18574 #endif
18575
18576         return 0;
18577
18578 }
18579
18580 _ACEOF
18581 rm -f conftest$ac_exeext
18582 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18583   (eval $ac_link) 2>&5
18584   ac_status=$?
18585   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18586   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18587   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18588   (eval $ac_try) 2>&5
18589   ac_status=$?
18590   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18591   (exit $ac_status); }; }; then
18592   ol_cv_pthread_threads=yes
18593 else
18594   echo "$as_me: program exited with status $ac_status" >&5
18595 echo "$as_me: failed program was:" >&5
18596 sed 's/^/| /' conftest.$ac_ext >&5
18597
18598 ( exit $ac_status )
18599 ol_cv_pthread_threads=no
18600 fi
18601 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18602 fi
18603
18604                 # restore the LIBS
18605                 LIBS="$ol_LIBS"
18606
18607 fi
18608 echo "$as_me:$LINENO: result: $ol_cv_pthread_threads" >&5
18609 echo "${ECHO_T}$ol_cv_pthread_threads" >&6
18610
18611         if test $ol_cv_pthread_threads = yes ; then
18612                 ol_link_pthreads="-threads"
18613                 ol_link_threads=posix
18614         fi
18615 fi
18616
18617
18618                 # Pthread try link: -lpthreads -lmach -lexc -lc_r (ol_cv_pthread_lpthreads_lmach_lexc_lc_r)
18619 if test "$ol_link_threads" = no ; then
18620         # try -lpthreads -lmach -lexc -lc_r
18621         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lmach -lexc -lc_r" >&5
18622 echo $ECHO_N "checking for pthread link with -lpthreads -lmach -lexc -lc_r... $ECHO_C" >&6
18623 if test "${ol_cv_pthread_lpthreads_lmach_lexc_lc_r+set}" = set; then
18624   echo $ECHO_N "(cached) $ECHO_C" >&6
18625 else
18626
18627                 # save the flags
18628                 ol_LIBS="$LIBS"
18629                 LIBS="-lpthreads -lmach -lexc -lc_r $LIBS"
18630
18631                 if test "$cross_compiling" = yes; then
18632   cat >conftest.$ac_ext <<_ACEOF
18633 #line $LINENO "configure"
18634 /* confdefs.h.  */
18635 _ACEOF
18636 cat confdefs.h >>conftest.$ac_ext
18637 cat >>conftest.$ac_ext <<_ACEOF
18638 /* end confdefs.h.  */
18639 /* pthread test headers */
18640 #include <pthread.h>
18641 #if HAVE_PTHREADS < 7
18642 #include <errno.h>
18643 #endif
18644 #ifndef NULL
18645 #define NULL (void*)0
18646 #endif
18647
18648 static void *task(p)
18649         void *p;
18650 {
18651         return (void *) (p == NULL);
18652 }
18653
18654 int
18655 main ()
18656 {
18657
18658         /* pthread test function */
18659 #ifndef PTHREAD_CREATE_DETACHED
18660 #define PTHREAD_CREATE_DETACHED 1
18661 #endif
18662         pthread_t t;
18663         int status;
18664         int detach = PTHREAD_CREATE_DETACHED;
18665
18666 #if HAVE_PTHREADS > 4
18667         /* Final pthreads */
18668         pthread_attr_t attr;
18669
18670         status = pthread_attr_init(&attr);
18671         if( status ) return status;
18672
18673 #if HAVE_PTHREADS < 7
18674         status = pthread_attr_setdetachstate(&attr, &detach);
18675         if( status < 0 ) status = errno;
18676 #else
18677         status = pthread_attr_setdetachstate(&attr, detach);
18678 #endif
18679         if( status ) return status;
18680         status = pthread_create( &t, &attr, task, NULL );
18681 #if HAVE_PTHREADS < 7
18682         if( status < 0 ) status = errno;
18683 #endif
18684         if( status ) return status;
18685 #else
18686         /* Draft 4 pthreads */
18687         status = pthread_create( &t, pthread_attr_default, task, NULL );
18688         if( status ) return errno;
18689
18690         /* give thread a chance to complete */
18691         /* it should remain joinable and hence detachable */
18692         sleep( 1 );
18693
18694         status = pthread_detach( &t );
18695         if( status ) return errno;
18696 #endif
18697
18698 #ifdef HAVE_LINUX_THREADS
18699         pthread_kill_other_threads_np();
18700 #endif
18701
18702         return 0;
18703
18704   ;
18705   return 0;
18706 }
18707 _ACEOF
18708 rm -f conftest.$ac_objext conftest$ac_exeext
18709 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18710   (eval $ac_link) 2>&5
18711   ac_status=$?
18712   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18713   (exit $ac_status); } &&
18714          { ac_try='test -s conftest$ac_exeext'
18715   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18716   (eval $ac_try) 2>&5
18717   ac_status=$?
18718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18719   (exit $ac_status); }; }; then
18720   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
18721 else
18722   echo "$as_me: failed program was:" >&5
18723 sed 's/^/| /' conftest.$ac_ext >&5
18724
18725 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
18726 fi
18727 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18728 else
18729   cat >conftest.$ac_ext <<_ACEOF
18730 #line $LINENO "configure"
18731 /* confdefs.h.  */
18732 _ACEOF
18733 cat confdefs.h >>conftest.$ac_ext
18734 cat >>conftest.$ac_ext <<_ACEOF
18735 /* end confdefs.h.  */
18736 /* pthread test headers */
18737 #include <pthread.h>
18738 #if HAVE_PTHREADS < 7
18739 #include <errno.h>
18740 #endif
18741 #ifndef NULL
18742 #define NULL (void*)0
18743 #endif
18744
18745 static void *task(p)
18746         void *p;
18747 {
18748         return (void *) (p == NULL);
18749 }
18750
18751
18752 int main(argc, argv)
18753         int argc;
18754         char **argv;
18755 {
18756
18757         /* pthread test function */
18758 #ifndef PTHREAD_CREATE_DETACHED
18759 #define PTHREAD_CREATE_DETACHED 1
18760 #endif
18761         pthread_t t;
18762         int status;
18763         int detach = PTHREAD_CREATE_DETACHED;
18764
18765 #if HAVE_PTHREADS > 4
18766         /* Final pthreads */
18767         pthread_attr_t attr;
18768
18769         status = pthread_attr_init(&attr);
18770         if( status ) return status;
18771
18772 #if HAVE_PTHREADS < 7
18773         status = pthread_attr_setdetachstate(&attr, &detach);
18774         if( status < 0 ) status = errno;
18775 #else
18776         status = pthread_attr_setdetachstate(&attr, detach);
18777 #endif
18778         if( status ) return status;
18779         status = pthread_create( &t, &attr, task, NULL );
18780 #if HAVE_PTHREADS < 7
18781         if( status < 0 ) status = errno;
18782 #endif
18783         if( status ) return status;
18784 #else
18785         /* Draft 4 pthreads */
18786         status = pthread_create( &t, pthread_attr_default, task, NULL );
18787         if( status ) return errno;
18788
18789         /* give thread a chance to complete */
18790         /* it should remain joinable and hence detachable */
18791         sleep( 1 );
18792
18793         status = pthread_detach( &t );
18794         if( status ) return errno;
18795 #endif
18796
18797 #ifdef HAVE_LINUX_THREADS
18798         pthread_kill_other_threads_np();
18799 #endif
18800
18801         return 0;
18802
18803 }
18804
18805 _ACEOF
18806 rm -f conftest$ac_exeext
18807 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18808   (eval $ac_link) 2>&5
18809   ac_status=$?
18810   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18811   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18812   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18813   (eval $ac_try) 2>&5
18814   ac_status=$?
18815   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18816   (exit $ac_status); }; }; then
18817   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
18818 else
18819   echo "$as_me: program exited with status $ac_status" >&5
18820 echo "$as_me: failed program was:" >&5
18821 sed 's/^/| /' conftest.$ac_ext >&5
18822
18823 ( exit $ac_status )
18824 ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
18825 fi
18826 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18827 fi
18828
18829                 # restore the LIBS
18830                 LIBS="$ol_LIBS"
18831
18832 fi
18833 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&5
18834 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&6
18835
18836         if test $ol_cv_pthread_lpthreads_lmach_lexc_lc_r = yes ; then
18837                 ol_link_pthreads="-lpthreads -lmach -lexc -lc_r"
18838                 ol_link_threads=posix
18839         fi
18840 fi
18841
18842                 # Pthread try link: -lpthreads -lmach -lexc (ol_cv_pthread_lpthreads_lmach_lexc)
18843 if test "$ol_link_threads" = no ; then
18844         # try -lpthreads -lmach -lexc
18845         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lmach -lexc" >&5
18846 echo $ECHO_N "checking for pthread link with -lpthreads -lmach -lexc... $ECHO_C" >&6
18847 if test "${ol_cv_pthread_lpthreads_lmach_lexc+set}" = set; then
18848   echo $ECHO_N "(cached) $ECHO_C" >&6
18849 else
18850
18851                 # save the flags
18852                 ol_LIBS="$LIBS"
18853                 LIBS="-lpthreads -lmach -lexc $LIBS"
18854
18855                 if test "$cross_compiling" = yes; then
18856   cat >conftest.$ac_ext <<_ACEOF
18857 #line $LINENO "configure"
18858 /* confdefs.h.  */
18859 _ACEOF
18860 cat confdefs.h >>conftest.$ac_ext
18861 cat >>conftest.$ac_ext <<_ACEOF
18862 /* end confdefs.h.  */
18863 /* pthread test headers */
18864 #include <pthread.h>
18865 #if HAVE_PTHREADS < 7
18866 #include <errno.h>
18867 #endif
18868 #ifndef NULL
18869 #define NULL (void*)0
18870 #endif
18871
18872 static void *task(p)
18873         void *p;
18874 {
18875         return (void *) (p == NULL);
18876 }
18877
18878 int
18879 main ()
18880 {
18881
18882         /* pthread test function */
18883 #ifndef PTHREAD_CREATE_DETACHED
18884 #define PTHREAD_CREATE_DETACHED 1
18885 #endif
18886         pthread_t t;
18887         int status;
18888         int detach = PTHREAD_CREATE_DETACHED;
18889
18890 #if HAVE_PTHREADS > 4
18891         /* Final pthreads */
18892         pthread_attr_t attr;
18893
18894         status = pthread_attr_init(&attr);
18895         if( status ) return status;
18896
18897 #if HAVE_PTHREADS < 7
18898         status = pthread_attr_setdetachstate(&attr, &detach);
18899         if( status < 0 ) status = errno;
18900 #else
18901         status = pthread_attr_setdetachstate(&attr, detach);
18902 #endif
18903         if( status ) return status;
18904         status = pthread_create( &t, &attr, task, NULL );
18905 #if HAVE_PTHREADS < 7
18906         if( status < 0 ) status = errno;
18907 #endif
18908         if( status ) return status;
18909 #else
18910         /* Draft 4 pthreads */
18911         status = pthread_create( &t, pthread_attr_default, task, NULL );
18912         if( status ) return errno;
18913
18914         /* give thread a chance to complete */
18915         /* it should remain joinable and hence detachable */
18916         sleep( 1 );
18917
18918         status = pthread_detach( &t );
18919         if( status ) return errno;
18920 #endif
18921
18922 #ifdef HAVE_LINUX_THREADS
18923         pthread_kill_other_threads_np();
18924 #endif
18925
18926         return 0;
18927
18928   ;
18929   return 0;
18930 }
18931 _ACEOF
18932 rm -f conftest.$ac_objext conftest$ac_exeext
18933 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18934   (eval $ac_link) 2>&5
18935   ac_status=$?
18936   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18937   (exit $ac_status); } &&
18938          { ac_try='test -s conftest$ac_exeext'
18939   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18940   (eval $ac_try) 2>&5
18941   ac_status=$?
18942   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18943   (exit $ac_status); }; }; then
18944   ol_cv_pthread_lpthreads_lmach_lexc=yes
18945 else
18946   echo "$as_me: failed program was:" >&5
18947 sed 's/^/| /' conftest.$ac_ext >&5
18948
18949 ol_cv_pthread_lpthreads_lmach_lexc=no
18950 fi
18951 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18952 else
18953   cat >conftest.$ac_ext <<_ACEOF
18954 #line $LINENO "configure"
18955 /* confdefs.h.  */
18956 _ACEOF
18957 cat confdefs.h >>conftest.$ac_ext
18958 cat >>conftest.$ac_ext <<_ACEOF
18959 /* end confdefs.h.  */
18960 /* pthread test headers */
18961 #include <pthread.h>
18962 #if HAVE_PTHREADS < 7
18963 #include <errno.h>
18964 #endif
18965 #ifndef NULL
18966 #define NULL (void*)0
18967 #endif
18968
18969 static void *task(p)
18970         void *p;
18971 {
18972         return (void *) (p == NULL);
18973 }
18974
18975
18976 int main(argc, argv)
18977         int argc;
18978         char **argv;
18979 {
18980
18981         /* pthread test function */
18982 #ifndef PTHREAD_CREATE_DETACHED
18983 #define PTHREAD_CREATE_DETACHED 1
18984 #endif
18985         pthread_t t;
18986         int status;
18987         int detach = PTHREAD_CREATE_DETACHED;
18988
18989 #if HAVE_PTHREADS > 4
18990         /* Final pthreads */
18991         pthread_attr_t attr;
18992
18993         status = pthread_attr_init(&attr);
18994         if( status ) return status;
18995
18996 #if HAVE_PTHREADS < 7
18997         status = pthread_attr_setdetachstate(&attr, &detach);
18998         if( status < 0 ) status = errno;
18999 #else
19000         status = pthread_attr_setdetachstate(&attr, detach);
19001 #endif
19002         if( status ) return status;
19003         status = pthread_create( &t, &attr, task, NULL );
19004 #if HAVE_PTHREADS < 7
19005         if( status < 0 ) status = errno;
19006 #endif
19007         if( status ) return status;
19008 #else
19009         /* Draft 4 pthreads */
19010         status = pthread_create( &t, pthread_attr_default, task, NULL );
19011         if( status ) return errno;
19012
19013         /* give thread a chance to complete */
19014         /* it should remain joinable and hence detachable */
19015         sleep( 1 );
19016
19017         status = pthread_detach( &t );
19018         if( status ) return errno;
19019 #endif
19020
19021 #ifdef HAVE_LINUX_THREADS
19022         pthread_kill_other_threads_np();
19023 #endif
19024
19025         return 0;
19026
19027 }
19028
19029 _ACEOF
19030 rm -f conftest$ac_exeext
19031 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19032   (eval $ac_link) 2>&5
19033   ac_status=$?
19034   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19035   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19036   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19037   (eval $ac_try) 2>&5
19038   ac_status=$?
19039   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19040   (exit $ac_status); }; }; then
19041   ol_cv_pthread_lpthreads_lmach_lexc=yes
19042 else
19043   echo "$as_me: program exited with status $ac_status" >&5
19044 echo "$as_me: failed program was:" >&5
19045 sed 's/^/| /' conftest.$ac_ext >&5
19046
19047 ( exit $ac_status )
19048 ol_cv_pthread_lpthreads_lmach_lexc=no
19049 fi
19050 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19051 fi
19052
19053                 # restore the LIBS
19054                 LIBS="$ol_LIBS"
19055
19056 fi
19057 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lmach_lexc" >&5
19058 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lmach_lexc" >&6
19059
19060         if test $ol_cv_pthread_lpthreads_lmach_lexc = yes ; then
19061                 ol_link_pthreads="-lpthreads -lmach -lexc"
19062                 ol_link_threads=posix
19063         fi
19064 fi
19065
19066                 # Pthread try link: -lpthreads -lexc (ol_cv_pthread_lpthreads_lexc)
19067 if test "$ol_link_threads" = no ; then
19068         # try -lpthreads -lexc
19069         echo "$as_me:$LINENO: checking for pthread link with -lpthreads -lexc" >&5
19070 echo $ECHO_N "checking for pthread link with -lpthreads -lexc... $ECHO_C" >&6
19071 if test "${ol_cv_pthread_lpthreads_lexc+set}" = set; then
19072   echo $ECHO_N "(cached) $ECHO_C" >&6
19073 else
19074
19075                 # save the flags
19076                 ol_LIBS="$LIBS"
19077                 LIBS="-lpthreads -lexc $LIBS"
19078
19079                 if test "$cross_compiling" = yes; then
19080   cat >conftest.$ac_ext <<_ACEOF
19081 #line $LINENO "configure"
19082 /* confdefs.h.  */
19083 _ACEOF
19084 cat confdefs.h >>conftest.$ac_ext
19085 cat >>conftest.$ac_ext <<_ACEOF
19086 /* end confdefs.h.  */
19087 /* pthread test headers */
19088 #include <pthread.h>
19089 #if HAVE_PTHREADS < 7
19090 #include <errno.h>
19091 #endif
19092 #ifndef NULL
19093 #define NULL (void*)0
19094 #endif
19095
19096 static void *task(p)
19097         void *p;
19098 {
19099         return (void *) (p == NULL);
19100 }
19101
19102 int
19103 main ()
19104 {
19105
19106         /* pthread test function */
19107 #ifndef PTHREAD_CREATE_DETACHED
19108 #define PTHREAD_CREATE_DETACHED 1
19109 #endif
19110         pthread_t t;
19111         int status;
19112         int detach = PTHREAD_CREATE_DETACHED;
19113
19114 #if HAVE_PTHREADS > 4
19115         /* Final pthreads */
19116         pthread_attr_t attr;
19117
19118         status = pthread_attr_init(&attr);
19119         if( status ) return status;
19120
19121 #if HAVE_PTHREADS < 7
19122         status = pthread_attr_setdetachstate(&attr, &detach);
19123         if( status < 0 ) status = errno;
19124 #else
19125         status = pthread_attr_setdetachstate(&attr, detach);
19126 #endif
19127         if( status ) return status;
19128         status = pthread_create( &t, &attr, task, NULL );
19129 #if HAVE_PTHREADS < 7
19130         if( status < 0 ) status = errno;
19131 #endif
19132         if( status ) return status;
19133 #else
19134         /* Draft 4 pthreads */
19135         status = pthread_create( &t, pthread_attr_default, task, NULL );
19136         if( status ) return errno;
19137
19138         /* give thread a chance to complete */
19139         /* it should remain joinable and hence detachable */
19140         sleep( 1 );
19141
19142         status = pthread_detach( &t );
19143         if( status ) return errno;
19144 #endif
19145
19146 #ifdef HAVE_LINUX_THREADS
19147         pthread_kill_other_threads_np();
19148 #endif
19149
19150         return 0;
19151
19152   ;
19153   return 0;
19154 }
19155 _ACEOF
19156 rm -f conftest.$ac_objext conftest$ac_exeext
19157 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19158   (eval $ac_link) 2>&5
19159   ac_status=$?
19160   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19161   (exit $ac_status); } &&
19162          { ac_try='test -s conftest$ac_exeext'
19163   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19164   (eval $ac_try) 2>&5
19165   ac_status=$?
19166   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19167   (exit $ac_status); }; }; then
19168   ol_cv_pthread_lpthreads_lexc=yes
19169 else
19170   echo "$as_me: failed program was:" >&5
19171 sed 's/^/| /' conftest.$ac_ext >&5
19172
19173 ol_cv_pthread_lpthreads_lexc=no
19174 fi
19175 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19176 else
19177   cat >conftest.$ac_ext <<_ACEOF
19178 #line $LINENO "configure"
19179 /* confdefs.h.  */
19180 _ACEOF
19181 cat confdefs.h >>conftest.$ac_ext
19182 cat >>conftest.$ac_ext <<_ACEOF
19183 /* end confdefs.h.  */
19184 /* pthread test headers */
19185 #include <pthread.h>
19186 #if HAVE_PTHREADS < 7
19187 #include <errno.h>
19188 #endif
19189 #ifndef NULL
19190 #define NULL (void*)0
19191 #endif
19192
19193 static void *task(p)
19194         void *p;
19195 {
19196         return (void *) (p == NULL);
19197 }
19198
19199
19200 int main(argc, argv)
19201         int argc;
19202         char **argv;
19203 {
19204
19205         /* pthread test function */
19206 #ifndef PTHREAD_CREATE_DETACHED
19207 #define PTHREAD_CREATE_DETACHED 1
19208 #endif
19209         pthread_t t;
19210         int status;
19211         int detach = PTHREAD_CREATE_DETACHED;
19212
19213 #if HAVE_PTHREADS > 4
19214         /* Final pthreads */
19215         pthread_attr_t attr;
19216
19217         status = pthread_attr_init(&attr);
19218         if( status ) return status;
19219
19220 #if HAVE_PTHREADS < 7
19221         status = pthread_attr_setdetachstate(&attr, &detach);
19222         if( status < 0 ) status = errno;
19223 #else
19224         status = pthread_attr_setdetachstate(&attr, detach);
19225 #endif
19226         if( status ) return status;
19227         status = pthread_create( &t, &attr, task, NULL );
19228 #if HAVE_PTHREADS < 7
19229         if( status < 0 ) status = errno;
19230 #endif
19231         if( status ) return status;
19232 #else
19233         /* Draft 4 pthreads */
19234         status = pthread_create( &t, pthread_attr_default, task, NULL );
19235         if( status ) return errno;
19236
19237         /* give thread a chance to complete */
19238         /* it should remain joinable and hence detachable */
19239         sleep( 1 );
19240
19241         status = pthread_detach( &t );
19242         if( status ) return errno;
19243 #endif
19244
19245 #ifdef HAVE_LINUX_THREADS
19246         pthread_kill_other_threads_np();
19247 #endif
19248
19249         return 0;
19250
19251 }
19252
19253 _ACEOF
19254 rm -f conftest$ac_exeext
19255 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19256   (eval $ac_link) 2>&5
19257   ac_status=$?
19258   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19259   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19260   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19261   (eval $ac_try) 2>&5
19262   ac_status=$?
19263   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19264   (exit $ac_status); }; }; then
19265   ol_cv_pthread_lpthreads_lexc=yes
19266 else
19267   echo "$as_me: program exited with status $ac_status" >&5
19268 echo "$as_me: failed program was:" >&5
19269 sed 's/^/| /' conftest.$ac_ext >&5
19270
19271 ( exit $ac_status )
19272 ol_cv_pthread_lpthreads_lexc=no
19273 fi
19274 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19275 fi
19276
19277                 # restore the LIBS
19278                 LIBS="$ol_LIBS"
19279
19280 fi
19281 echo "$as_me:$LINENO: result: $ol_cv_pthread_lpthreads_lexc" >&5
19282 echo "${ECHO_T}$ol_cv_pthread_lpthreads_lexc" >&6
19283
19284         if test $ol_cv_pthread_lpthreads_lexc = yes ; then
19285                 ol_link_pthreads="-lpthreads -lexc"
19286                 ol_link_threads=posix
19287         fi
19288 fi
19289
19290
19291                 # Pthread try link: -lpthreads (ol_cv_pthread_lib_lpthreads)
19292 if test "$ol_link_threads" = no ; then
19293         # try -lpthreads
19294         echo "$as_me:$LINENO: checking for pthread link with -lpthreads" >&5
19295 echo $ECHO_N "checking for pthread link with -lpthreads... $ECHO_C" >&6
19296 if test "${ol_cv_pthread_lib_lpthreads+set}" = set; then
19297   echo $ECHO_N "(cached) $ECHO_C" >&6
19298 else
19299
19300                 # save the flags
19301                 ol_LIBS="$LIBS"
19302                 LIBS="-lpthreads $LIBS"
19303
19304                 if test "$cross_compiling" = yes; then
19305   cat >conftest.$ac_ext <<_ACEOF
19306 #line $LINENO "configure"
19307 /* confdefs.h.  */
19308 _ACEOF
19309 cat confdefs.h >>conftest.$ac_ext
19310 cat >>conftest.$ac_ext <<_ACEOF
19311 /* end confdefs.h.  */
19312 /* pthread test headers */
19313 #include <pthread.h>
19314 #if HAVE_PTHREADS < 7
19315 #include <errno.h>
19316 #endif
19317 #ifndef NULL
19318 #define NULL (void*)0
19319 #endif
19320
19321 static void *task(p)
19322         void *p;
19323 {
19324         return (void *) (p == NULL);
19325 }
19326
19327 int
19328 main ()
19329 {
19330
19331         /* pthread test function */
19332 #ifndef PTHREAD_CREATE_DETACHED
19333 #define PTHREAD_CREATE_DETACHED 1
19334 #endif
19335         pthread_t t;
19336         int status;
19337         int detach = PTHREAD_CREATE_DETACHED;
19338
19339 #if HAVE_PTHREADS > 4
19340         /* Final pthreads */
19341         pthread_attr_t attr;
19342
19343         status = pthread_attr_init(&attr);
19344         if( status ) return status;
19345
19346 #if HAVE_PTHREADS < 7
19347         status = pthread_attr_setdetachstate(&attr, &detach);
19348         if( status < 0 ) status = errno;
19349 #else
19350         status = pthread_attr_setdetachstate(&attr, detach);
19351 #endif
19352         if( status ) return status;
19353         status = pthread_create( &t, &attr, task, NULL );
19354 #if HAVE_PTHREADS < 7
19355         if( status < 0 ) status = errno;
19356 #endif
19357         if( status ) return status;
19358 #else
19359         /* Draft 4 pthreads */
19360         status = pthread_create( &t, pthread_attr_default, task, NULL );
19361         if( status ) return errno;
19362
19363         /* give thread a chance to complete */
19364         /* it should remain joinable and hence detachable */
19365         sleep( 1 );
19366
19367         status = pthread_detach( &t );
19368         if( status ) return errno;
19369 #endif
19370
19371 #ifdef HAVE_LINUX_THREADS
19372         pthread_kill_other_threads_np();
19373 #endif
19374
19375         return 0;
19376
19377   ;
19378   return 0;
19379 }
19380 _ACEOF
19381 rm -f conftest.$ac_objext conftest$ac_exeext
19382 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19383   (eval $ac_link) 2>&5
19384   ac_status=$?
19385   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19386   (exit $ac_status); } &&
19387          { ac_try='test -s conftest$ac_exeext'
19388   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19389   (eval $ac_try) 2>&5
19390   ac_status=$?
19391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19392   (exit $ac_status); }; }; then
19393   ol_cv_pthread_lib_lpthreads=yes
19394 else
19395   echo "$as_me: failed program was:" >&5
19396 sed 's/^/| /' conftest.$ac_ext >&5
19397
19398 ol_cv_pthread_lib_lpthreads=no
19399 fi
19400 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19401 else
19402   cat >conftest.$ac_ext <<_ACEOF
19403 #line $LINENO "configure"
19404 /* confdefs.h.  */
19405 _ACEOF
19406 cat confdefs.h >>conftest.$ac_ext
19407 cat >>conftest.$ac_ext <<_ACEOF
19408 /* end confdefs.h.  */
19409 /* pthread test headers */
19410 #include <pthread.h>
19411 #if HAVE_PTHREADS < 7
19412 #include <errno.h>
19413 #endif
19414 #ifndef NULL
19415 #define NULL (void*)0
19416 #endif
19417
19418 static void *task(p)
19419         void *p;
19420 {
19421         return (void *) (p == NULL);
19422 }
19423
19424
19425 int main(argc, argv)
19426         int argc;
19427         char **argv;
19428 {
19429
19430         /* pthread test function */
19431 #ifndef PTHREAD_CREATE_DETACHED
19432 #define PTHREAD_CREATE_DETACHED 1
19433 #endif
19434         pthread_t t;
19435         int status;
19436         int detach = PTHREAD_CREATE_DETACHED;
19437
19438 #if HAVE_PTHREADS > 4
19439         /* Final pthreads */
19440         pthread_attr_t attr;
19441
19442         status = pthread_attr_init(&attr);
19443         if( status ) return status;
19444
19445 #if HAVE_PTHREADS < 7
19446         status = pthread_attr_setdetachstate(&attr, &detach);
19447         if( status < 0 ) status = errno;
19448 #else
19449         status = pthread_attr_setdetachstate(&attr, detach);
19450 #endif
19451         if( status ) return status;
19452         status = pthread_create( &t, &attr, task, NULL );
19453 #if HAVE_PTHREADS < 7
19454         if( status < 0 ) status = errno;
19455 #endif
19456         if( status ) return status;
19457 #else
19458         /* Draft 4 pthreads */
19459         status = pthread_create( &t, pthread_attr_default, task, NULL );
19460         if( status ) return errno;
19461
19462         /* give thread a chance to complete */
19463         /* it should remain joinable and hence detachable */
19464         sleep( 1 );
19465
19466         status = pthread_detach( &t );
19467         if( status ) return errno;
19468 #endif
19469
19470 #ifdef HAVE_LINUX_THREADS
19471         pthread_kill_other_threads_np();
19472 #endif
19473
19474         return 0;
19475
19476 }
19477
19478 _ACEOF
19479 rm -f conftest$ac_exeext
19480 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19481   (eval $ac_link) 2>&5
19482   ac_status=$?
19483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19484   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19485   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19486   (eval $ac_try) 2>&5
19487   ac_status=$?
19488   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19489   (exit $ac_status); }; }; then
19490   ol_cv_pthread_lib_lpthreads=yes
19491 else
19492   echo "$as_me: program exited with status $ac_status" >&5
19493 echo "$as_me: failed program was:" >&5
19494 sed 's/^/| /' conftest.$ac_ext >&5
19495
19496 ( exit $ac_status )
19497 ol_cv_pthread_lib_lpthreads=no
19498 fi
19499 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19500 fi
19501
19502                 # restore the LIBS
19503                 LIBS="$ol_LIBS"
19504
19505 fi
19506 echo "$as_me:$LINENO: result: $ol_cv_pthread_lib_lpthreads" >&5
19507 echo "${ECHO_T}$ol_cv_pthread_lib_lpthreads" >&6
19508
19509         if test $ol_cv_pthread_lib_lpthreads = yes ; then
19510                 ol_link_pthreads="-lpthreads"
19511                 ol_link_threads=posix
19512         fi
19513 fi
19514
19515
19516                 if test $ol_link_threads != no ; then
19517                         LTHREAD_LIBS="$LTHREAD_LIBS $ol_link_pthreads"
19518
19519                                                 save_CPPFLAGS="$CPPFLAGS"
19520                         save_LIBS="$LIBS"
19521                         LIBS="$LTHREAD_LIBS $LIBS"
19522
19523
19524
19525
19526 for ac_func in sched_yield pthread_yield thr_yield
19527 do
19528 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
19529 echo "$as_me:$LINENO: checking for $ac_func" >&5
19530 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
19531 if eval "test \"\${$as_ac_var+set}\" = set"; then
19532   echo $ECHO_N "(cached) $ECHO_C" >&6
19533 else
19534   cat >conftest.$ac_ext <<_ACEOF
19535 #line $LINENO "configure"
19536 /* confdefs.h.  */
19537 _ACEOF
19538 cat confdefs.h >>conftest.$ac_ext
19539 cat >>conftest.$ac_ext <<_ACEOF
19540 /* end confdefs.h.  */
19541 /* System header to define __stub macros and hopefully few prototypes,
19542     which can conflict with char $ac_func (); below.
19543     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19544     <limits.h> exists even on freestanding compilers.  */
19545 #ifdef __STDC__
19546 # include <limits.h>
19547 #else
19548 # include <assert.h>
19549 #endif
19550 /* Override any gcc2 internal prototype to avoid an error.  */
19551 #ifdef __cplusplus
19552 extern "C"
19553 {
19554 #endif
19555 /* We use char because int might match the return type of a gcc2
19556    builtin and then its argument prototype would still apply.  */
19557 char $ac_func ();
19558 /* The GNU C library defines this for functions which it implements
19559     to always fail with ENOSYS.  Some functions are actually named
19560     something starting with __ and the normal name is an alias.  */
19561 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
19562 choke me
19563 #else
19564 char (*f) () = $ac_func;
19565 #endif
19566 #ifdef __cplusplus
19567 }
19568 #endif
19569
19570 int
19571 main ()
19572 {
19573 return f != $ac_func;
19574   ;
19575   return 0;
19576 }
19577 _ACEOF
19578 rm -f conftest.$ac_objext conftest$ac_exeext
19579 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19580   (eval $ac_link) 2>&5
19581   ac_status=$?
19582   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19583   (exit $ac_status); } &&
19584          { ac_try='test -s conftest$ac_exeext'
19585   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19586   (eval $ac_try) 2>&5
19587   ac_status=$?
19588   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19589   (exit $ac_status); }; }; then
19590   eval "$as_ac_var=yes"
19591 else
19592   echo "$as_me: failed program was:" >&5
19593 sed 's/^/| /' conftest.$ac_ext >&5
19594
19595 eval "$as_ac_var=no"
19596 fi
19597 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19598 fi
19599 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
19600 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
19601 if test `eval echo '${'$as_ac_var'}'` = yes; then
19602   cat >>confdefs.h <<_ACEOF
19603 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
19604 _ACEOF
19605
19606 fi
19607 done
19608
19609
19610                         if test $ac_cv_func_sched_yield = no -a \
19611                                 $ac_cv_func_pthread_yield = no -a \
19612                                 $ac_cv_func_thr_yield = no ; then
19613                                                                 echo "$as_me:$LINENO: checking for sched_yield in -lrt" >&5
19614 echo $ECHO_N "checking for sched_yield in -lrt... $ECHO_C" >&6
19615 if test "${ac_cv_lib_rt_sched_yield+set}" = set; then
19616   echo $ECHO_N "(cached) $ECHO_C" >&6
19617 else
19618   ac_check_lib_save_LIBS=$LIBS
19619 LIBS="-lrt  $LIBS"
19620 cat >conftest.$ac_ext <<_ACEOF
19621 #line $LINENO "configure"
19622 /* confdefs.h.  */
19623 _ACEOF
19624 cat confdefs.h >>conftest.$ac_ext
19625 cat >>conftest.$ac_ext <<_ACEOF
19626 /* end confdefs.h.  */
19627
19628 /* Override any gcc2 internal prototype to avoid an error.  */
19629 #ifdef __cplusplus
19630 extern "C"
19631 #endif
19632 /* We use char because int might match the return type of a gcc2
19633    builtin and then its argument prototype would still apply.  */
19634 char sched_yield ();
19635 int
19636 main ()
19637 {
19638 sched_yield ();
19639   ;
19640   return 0;
19641 }
19642 _ACEOF
19643 rm -f conftest.$ac_objext conftest$ac_exeext
19644 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19645   (eval $ac_link) 2>&5
19646   ac_status=$?
19647   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19648   (exit $ac_status); } &&
19649          { ac_try='test -s conftest$ac_exeext'
19650   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19651   (eval $ac_try) 2>&5
19652   ac_status=$?
19653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19654   (exit $ac_status); }; }; then
19655   ac_cv_lib_rt_sched_yield=yes
19656 else
19657   echo "$as_me: failed program was:" >&5
19658 sed 's/^/| /' conftest.$ac_ext >&5
19659
19660 ac_cv_lib_rt_sched_yield=no
19661 fi
19662 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19663 LIBS=$ac_check_lib_save_LIBS
19664 fi
19665 echo "$as_me:$LINENO: result: $ac_cv_lib_rt_sched_yield" >&5
19666 echo "${ECHO_T}$ac_cv_lib_rt_sched_yield" >&6
19667 if test $ac_cv_lib_rt_sched_yield = yes; then
19668   LTHREAD_LIBS="$LTHREAD_LIBS -lrt"
19669
19670 cat >>confdefs.h <<\_ACEOF
19671 #define HAVE_SCHED_YIELD 1
19672 _ACEOF
19673
19674                                         ac_cv_func_sched_yield=yes
19675 else
19676   ac_cv_func_sched_yield=no
19677 fi
19678
19679                         fi
19680                         if test $ac_cv_func_sched_yield = no -a \
19681                                 $ac_cv_func_pthread_yield = no -a \
19682                                 "$ac_cv_func_thr_yield" = no ; then
19683                                 { echo "$as_me:$LINENO: WARNING: could not locate sched_yield() or pthread_yield()" >&5
19684 echo "$as_me: WARNING: could not locate sched_yield() or pthread_yield()" >&2;}
19685                         fi
19686
19687
19688
19689 for ac_func in pthread_kill pthread_rwlock_destroy
19690 do
19691 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
19692 echo "$as_me:$LINENO: checking for $ac_func" >&5
19693 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
19694 if eval "test \"\${$as_ac_var+set}\" = set"; then
19695   echo $ECHO_N "(cached) $ECHO_C" >&6
19696 else
19697   cat >conftest.$ac_ext <<_ACEOF
19698 #line $LINENO "configure"
19699 /* confdefs.h.  */
19700 _ACEOF
19701 cat confdefs.h >>conftest.$ac_ext
19702 cat >>conftest.$ac_ext <<_ACEOF
19703 /* end confdefs.h.  */
19704 /* System header to define __stub macros and hopefully few prototypes,
19705     which can conflict with char $ac_func (); below.
19706     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19707     <limits.h> exists even on freestanding compilers.  */
19708 #ifdef __STDC__
19709 # include <limits.h>
19710 #else
19711 # include <assert.h>
19712 #endif
19713 /* Override any gcc2 internal prototype to avoid an error.  */
19714 #ifdef __cplusplus
19715 extern "C"
19716 {
19717 #endif
19718 /* We use char because int might match the return type of a gcc2
19719    builtin and then its argument prototype would still apply.  */
19720 char $ac_func ();
19721 /* The GNU C library defines this for functions which it implements
19722     to always fail with ENOSYS.  Some functions are actually named
19723     something starting with __ and the normal name is an alias.  */
19724 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
19725 choke me
19726 #else
19727 char (*f) () = $ac_func;
19728 #endif
19729 #ifdef __cplusplus
19730 }
19731 #endif
19732
19733 int
19734 main ()
19735 {
19736 return f != $ac_func;
19737   ;
19738   return 0;
19739 }
19740 _ACEOF
19741 rm -f conftest.$ac_objext conftest$ac_exeext
19742 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19743   (eval $ac_link) 2>&5
19744   ac_status=$?
19745   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19746   (exit $ac_status); } &&
19747          { ac_try='test -s conftest$ac_exeext'
19748   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19749   (eval $ac_try) 2>&5
19750   ac_status=$?
19751   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19752   (exit $ac_status); }; }; then
19753   eval "$as_ac_var=yes"
19754 else
19755   echo "$as_me: failed program was:" >&5
19756 sed 's/^/| /' conftest.$ac_ext >&5
19757
19758 eval "$as_ac_var=no"
19759 fi
19760 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19761 fi
19762 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
19763 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
19764 if test `eval echo '${'$as_ac_var'}'` = yes; then
19765   cat >>confdefs.h <<_ACEOF
19766 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
19767 _ACEOF
19768
19769 fi
19770 done
19771
19772
19773                                                                         echo "$as_me:$LINENO: checking for pthread_detach with <pthread.h>" >&5
19774 echo $ECHO_N "checking for pthread_detach with <pthread.h>... $ECHO_C" >&6
19775 if test "${ol_cv_func_pthread_detach+set}" = set; then
19776   echo $ECHO_N "(cached) $ECHO_C" >&6
19777 else
19778
19779                                                                 cat >conftest.$ac_ext <<_ACEOF
19780 #line $LINENO "configure"
19781 /* confdefs.h.  */
19782 _ACEOF
19783 cat confdefs.h >>conftest.$ac_ext
19784 cat >>conftest.$ac_ext <<_ACEOF
19785 /* end confdefs.h.  */
19786
19787 #include <pthread.h>
19788 #ifndef NULL
19789 #define NULL (void*)0
19790 #endif
19791
19792 int
19793 main ()
19794 {
19795 pthread_detach(NULL);
19796   ;
19797   return 0;
19798 }
19799 _ACEOF
19800 rm -f conftest.$ac_objext conftest$ac_exeext
19801 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19802   (eval $ac_link) 2>&5
19803   ac_status=$?
19804   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19805   (exit $ac_status); } &&
19806          { ac_try='test -s conftest$ac_exeext'
19807   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19808   (eval $ac_try) 2>&5
19809   ac_status=$?
19810   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19811   (exit $ac_status); }; }; then
19812   ol_cv_func_pthread_detach=yes
19813 else
19814   echo "$as_me: failed program was:" >&5
19815 sed 's/^/| /' conftest.$ac_ext >&5
19816
19817 ol_cv_func_pthread_detach=no
19818 fi
19819 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19820
19821 fi
19822 echo "$as_me:$LINENO: result: $ol_cv_func_pthread_detach" >&5
19823 echo "${ECHO_T}$ol_cv_func_pthread_detach" >&6
19824
19825                         if test $ol_cv_func_pthread_detach = no ; then
19826                                 { { echo "$as_me:$LINENO: error: could not locate pthread_detach()" >&5
19827 echo "$as_me: error: could not locate pthread_detach()" >&2;}
19828    { (exit 1); exit 1; }; }
19829                         fi
19830
19831
19832 cat >>confdefs.h <<\_ACEOF
19833 #define HAVE_PTHREAD_DETACH 1
19834 _ACEOF
19835
19836
19837
19838
19839
19840
19841 for ac_func in \
19842                                 pthread_setconcurrency \
19843                                 pthread_getconcurrency \
19844                                 thr_setconcurrency \
19845                                 thr_getconcurrency \
19846
19847 do
19848 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
19849 echo "$as_me:$LINENO: checking for $ac_func" >&5
19850 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
19851 if eval "test \"\${$as_ac_var+set}\" = set"; then
19852   echo $ECHO_N "(cached) $ECHO_C" >&6
19853 else
19854   cat >conftest.$ac_ext <<_ACEOF
19855 #line $LINENO "configure"
19856 /* confdefs.h.  */
19857 _ACEOF
19858 cat confdefs.h >>conftest.$ac_ext
19859 cat >>conftest.$ac_ext <<_ACEOF
19860 /* end confdefs.h.  */
19861 /* System header to define __stub macros and hopefully few prototypes,
19862     which can conflict with char $ac_func (); below.
19863     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19864     <limits.h> exists even on freestanding compilers.  */
19865 #ifdef __STDC__
19866 # include <limits.h>
19867 #else
19868 # include <assert.h>
19869 #endif
19870 /* Override any gcc2 internal prototype to avoid an error.  */
19871 #ifdef __cplusplus
19872 extern "C"
19873 {
19874 #endif
19875 /* We use char because int might match the return type of a gcc2
19876    builtin and then its argument prototype would still apply.  */
19877 char $ac_func ();
19878 /* The GNU C library defines this for functions which it implements
19879     to always fail with ENOSYS.  Some functions are actually named
19880     something starting with __ and the normal name is an alias.  */
19881 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
19882 choke me
19883 #else
19884 char (*f) () = $ac_func;
19885 #endif
19886 #ifdef __cplusplus
19887 }
19888 #endif
19889
19890 int
19891 main ()
19892 {
19893 return f != $ac_func;
19894   ;
19895   return 0;
19896 }
19897 _ACEOF
19898 rm -f conftest.$ac_objext conftest$ac_exeext
19899 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19900   (eval $ac_link) 2>&5
19901   ac_status=$?
19902   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19903   (exit $ac_status); } &&
19904          { ac_try='test -s conftest$ac_exeext'
19905   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19906   (eval $ac_try) 2>&5
19907   ac_status=$?
19908   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19909   (exit $ac_status); }; }; then
19910   eval "$as_ac_var=yes"
19911 else
19912   echo "$as_me: failed program was:" >&5
19913 sed 's/^/| /' conftest.$ac_ext >&5
19914
19915 eval "$as_ac_var=no"
19916 fi
19917 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
19918 fi
19919 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
19920 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
19921 if test `eval echo '${'$as_ac_var'}'` = yes; then
19922   cat >>confdefs.h <<_ACEOF
19923 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
19924 _ACEOF
19925
19926 fi
19927 done
19928
19929
19930
19931
19932 for ac_func in pthread_kill_other_threads_np
19933 do
19934 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
19935 echo "$as_me:$LINENO: checking for $ac_func" >&5
19936 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
19937 if eval "test \"\${$as_ac_var+set}\" = set"; then
19938   echo $ECHO_N "(cached) $ECHO_C" >&6
19939 else
19940   cat >conftest.$ac_ext <<_ACEOF
19941 #line $LINENO "configure"
19942 /* confdefs.h.  */
19943 _ACEOF
19944 cat confdefs.h >>conftest.$ac_ext
19945 cat >>conftest.$ac_ext <<_ACEOF
19946 /* end confdefs.h.  */
19947 /* System header to define __stub macros and hopefully few prototypes,
19948     which can conflict with char $ac_func (); below.
19949     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19950     <limits.h> exists even on freestanding compilers.  */
19951 #ifdef __STDC__
19952 # include <limits.h>
19953 #else
19954 # include <assert.h>
19955 #endif
19956 /* Override any gcc2 internal prototype to avoid an error.  */
19957 #ifdef __cplusplus
19958 extern "C"
19959 {
19960 #endif
19961 /* We use char because int might match the return type of a gcc2
19962    builtin and then its argument prototype would still apply.  */
19963 char $ac_func ();
19964 /* The GNU C library defines this for functions which it implements
19965     to always fail with ENOSYS.  Some functions are actually named
19966     something starting with __ and the normal name is an alias.  */
19967 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
19968 choke me
19969 #else
19970 char (*f) () = $ac_func;
19971 #endif
19972 #ifdef __cplusplus
19973 }
19974 #endif
19975
19976 int
19977 main ()
19978 {
19979 return f != $ac_func;
19980   ;
19981   return 0;
19982 }
19983 _ACEOF
19984 rm -f conftest.$ac_objext conftest$ac_exeext
19985 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19986   (eval $ac_link) 2>&5
19987   ac_status=$?
19988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19989   (exit $ac_status); } &&
19990          { ac_try='test -s conftest$ac_exeext'
19991   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19992   (eval $ac_try) 2>&5
19993   ac_status=$?
19994   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19995   (exit $ac_status); }; }; then
19996   eval "$as_ac_var=yes"
19997 else
19998   echo "$as_me: failed program was:" >&5
19999 sed 's/^/| /' conftest.$ac_ext >&5
20000
20001 eval "$as_ac_var=no"
20002 fi
20003 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20004 fi
20005 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
20006 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
20007 if test `eval echo '${'$as_ac_var'}'` = yes; then
20008   cat >>confdefs.h <<_ACEOF
20009 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
20010 _ACEOF
20011
20012 fi
20013 done
20014
20015         echo "$as_me:$LINENO: checking for LinuxThreads implementation" >&5
20016 echo $ECHO_N "checking for LinuxThreads implementation... $ECHO_C" >&6
20017 if test "${ol_cv_sys_linux_threads+set}" = set; then
20018   echo $ECHO_N "(cached) $ECHO_C" >&6
20019 else
20020   ol_cv_sys_linux_threads=$ac_cv_func_pthread_kill_other_threads_np
20021 fi
20022 echo "$as_me:$LINENO: result: $ol_cv_sys_linux_threads" >&5
20023 echo "${ECHO_T}$ol_cv_sys_linux_threads" >&6
20024
20025
20026
20027
20028         echo "$as_me:$LINENO: checking for LinuxThreads consistency" >&5
20029 echo $ECHO_N "checking for LinuxThreads consistency... $ECHO_C" >&6
20030 if test "${ol_cv_linux_threads+set}" = set; then
20031   echo $ECHO_N "(cached) $ECHO_C" >&6
20032 else
20033
20034                 if test $ol_cv_header_linux_threads = yes -a \
20035                         $ol_cv_sys_linux_threads = yes; then
20036                         ol_cv_linux_threads=yes
20037                 elif test $ol_cv_header_linux_threads = no -a \
20038                         $ol_cv_sys_linux_threads = no; then
20039                         ol_cv_linux_threads=no
20040                 else
20041                         ol_cv_linux_threads=error
20042                 fi
20043
20044 fi
20045 echo "$as_me:$LINENO: result: $ol_cv_linux_threads" >&5
20046 echo "${ECHO_T}$ol_cv_linux_threads" >&6
20047
20048
20049                         if test $ol_cv_linux_threads = error; then
20050                                 { { echo "$as_me:$LINENO: error: LinuxThreads header/library mismatch" >&5
20051 echo "$as_me: error: LinuxThreads header/library mismatch" >&2;}
20052    { (exit 1); exit 1; }; };
20053                         fi
20054
20055                         echo "$as_me:$LINENO: checking if pthread_create() works" >&5
20056 echo $ECHO_N "checking if pthread_create() works... $ECHO_C" >&6
20057 if test "${ol_cv_pthread_create_works+set}" = set; then
20058   echo $ECHO_N "(cached) $ECHO_C" >&6
20059 else
20060
20061                         if test "$cross_compiling" = yes; then
20062                                 ol_cv_pthread_create_works=yes
20063 else
20064   cat >conftest.$ac_ext <<_ACEOF
20065 #line $LINENO "configure"
20066 /* confdefs.h.  */
20067 _ACEOF
20068 cat confdefs.h >>conftest.$ac_ext
20069 cat >>conftest.$ac_ext <<_ACEOF
20070 /* end confdefs.h.  */
20071 /* pthread test headers */
20072 #include <pthread.h>
20073 #if HAVE_PTHREADS < 7
20074 #include <errno.h>
20075 #endif
20076 #ifndef NULL
20077 #define NULL (void*)0
20078 #endif
20079
20080 static void *task(p)
20081         void *p;
20082 {
20083         return (void *) (p == NULL);
20084 }
20085
20086
20087 int main(argc, argv)
20088         int argc;
20089         char **argv;
20090 {
20091
20092         /* pthread test function */
20093 #ifndef PTHREAD_CREATE_DETACHED
20094 #define PTHREAD_CREATE_DETACHED 1
20095 #endif
20096         pthread_t t;
20097         int status;
20098         int detach = PTHREAD_CREATE_DETACHED;
20099
20100 #if HAVE_PTHREADS > 4
20101         /* Final pthreads */
20102         pthread_attr_t attr;
20103
20104         status = pthread_attr_init(&attr);
20105         if( status ) return status;
20106
20107 #if HAVE_PTHREADS < 7
20108         status = pthread_attr_setdetachstate(&attr, &detach);
20109         if( status < 0 ) status = errno;
20110 #else
20111         status = pthread_attr_setdetachstate(&attr, detach);
20112 #endif
20113         if( status ) return status;
20114         status = pthread_create( &t, &attr, task, NULL );
20115 #if HAVE_PTHREADS < 7
20116         if( status < 0 ) status = errno;
20117 #endif
20118         if( status ) return status;
20119 #else
20120         /* Draft 4 pthreads */
20121         status = pthread_create( &t, pthread_attr_default, task, NULL );
20122         if( status ) return errno;
20123
20124         /* give thread a chance to complete */
20125         /* it should remain joinable and hence detachable */
20126         sleep( 1 );
20127
20128         status = pthread_detach( &t );
20129         if( status ) return errno;
20130 #endif
20131
20132 #ifdef HAVE_LINUX_THREADS
20133         pthread_kill_other_threads_np();
20134 #endif
20135
20136         return 0;
20137
20138 }
20139
20140 _ACEOF
20141 rm -f conftest$ac_exeext
20142 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20143   (eval $ac_link) 2>&5
20144   ac_status=$?
20145   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20146   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20147   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20148   (eval $ac_try) 2>&5
20149   ac_status=$?
20150   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20151   (exit $ac_status); }; }; then
20152   ol_cv_pthread_create_works=yes
20153 else
20154   echo "$as_me: program exited with status $ac_status" >&5
20155 echo "$as_me: failed program was:" >&5
20156 sed 's/^/| /' conftest.$ac_ext >&5
20157
20158 ( exit $ac_status )
20159 ol_cv_pthread_create_works=no
20160 fi
20161 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20162 fi
20163 fi
20164 echo "$as_me:$LINENO: result: $ol_cv_pthread_create_works" >&5
20165 echo "${ECHO_T}$ol_cv_pthread_create_works" >&6
20166
20167                         if test $ol_cv_pthread_create_works = no ; then
20168                                 { { echo "$as_me:$LINENO: error: pthread_create is not usable, check environment settings" >&5
20169 echo "$as_me: error: pthread_create is not usable, check environment settings" >&2;}
20170    { (exit 1); exit 1; }; }
20171                         fi
20172
20173                                                 if test $ol_with_yielding_select = auto ; then
20174                                 echo "$as_me:$LINENO: checking if select yields when using pthreads" >&5
20175 echo $ECHO_N "checking if select yields when using pthreads... $ECHO_C" >&6
20176 if test "${ol_cv_pthread_select_yields+set}" = set; then
20177   echo $ECHO_N "(cached) $ECHO_C" >&6
20178 else
20179
20180                                 if test "$cross_compiling" = yes; then
20181   ol_cv_pthread_select_yields=cross
20182 else
20183   cat >conftest.$ac_ext <<_ACEOF
20184 #line $LINENO "configure"
20185 /* confdefs.h.  */
20186 _ACEOF
20187 cat confdefs.h >>conftest.$ac_ext
20188 cat >>conftest.$ac_ext <<_ACEOF
20189 /* end confdefs.h.  */
20190
20191 #include <sys/types.h>
20192 #include <sys/time.h>
20193 #include <unistd.h>
20194 #include <pthread.h>
20195 #ifndef NULL
20196 #define NULL (void*) 0
20197 #endif
20198
20199 static int fildes[2];
20200
20201 static void *task(p)
20202         void *p;
20203 {
20204         int i;
20205         struct timeval tv;
20206
20207         fd_set rfds;
20208
20209         tv.tv_sec=10;
20210         tv.tv_usec=0;
20211
20212         FD_ZERO(&rfds);
20213         FD_SET(fildes[0], &rfds);
20214
20215         /* we're not interested in any fds */
20216         i = select(FD_SETSIZE, &rfds, NULL, NULL, &tv);
20217
20218         if(i < 0) {
20219                 perror("select");
20220                 exit(10);
20221         }
20222
20223         exit(0); /* if we exit here, the select blocked the whole process */
20224 }
20225
20226 int main(argc, argv)
20227         int argc;
20228         char **argv;
20229 {
20230         pthread_t t;
20231
20232         /* create a pipe to select */
20233         if(pipe(&fildes[0])) {
20234                 perror("select");
20235                 exit(1);
20236         }
20237
20238 #ifdef HAVE_PTHREAD_SETCONCURRENCY
20239         (void) pthread_setconcurrency(2);
20240 #else
20241 #ifdef HAVE_THR_SETCONCURRENCY
20242         /* Set Solaris LWP concurrency to 2 */
20243         thr_setconcurrency(2);
20244 #endif
20245 #endif
20246
20247 #if HAVE_PTHREADS < 6
20248         pthread_create(&t, pthread_attr_default, task, NULL);
20249 #else
20250         pthread_create(&t, NULL, task, NULL);
20251 #endif
20252
20253         /* make sure task runs first */
20254 #if HAVE_THR_YIELD
20255         thr_yield();
20256 #elif defined( HAVE_SCHED_YIELD )
20257         sched_yield();
20258 #elif defined( HAVE_PTHREAD_YIELD )
20259         pthread_yield();
20260 #endif
20261
20262         exit(2);
20263 }
20264 _ACEOF
20265 rm -f conftest$ac_exeext
20266 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20267   (eval $ac_link) 2>&5
20268   ac_status=$?
20269   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20270   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20271   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20272   (eval $ac_try) 2>&5
20273   ac_status=$?
20274   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20275   (exit $ac_status); }; }; then
20276   ol_cv_pthread_select_yields=no
20277 else
20278   echo "$as_me: program exited with status $ac_status" >&5
20279 echo "$as_me: failed program was:" >&5
20280 sed 's/^/| /' conftest.$ac_ext >&5
20281
20282 ( exit $ac_status )
20283 ol_cv_pthread_select_yields=yes
20284 fi
20285 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20286 fi
20287 fi
20288 echo "$as_me:$LINENO: result: $ol_cv_pthread_select_yields" >&5
20289 echo "${ECHO_T}$ol_cv_pthread_select_yields" >&6
20290
20291                                 if test $ol_cv_pthread_select_yields = cross ; then
20292                                         { { echo "$as_me:$LINENO: error: crossing compiling: use --with-yielding_select=yes|no|manual" >&5
20293 echo "$as_me: error: crossing compiling: use --with-yielding_select=yes|no|manual" >&2;}
20294    { (exit 1); exit 1; }; }
20295                                 fi
20296
20297                                 if test $ol_cv_pthread_select_yields = yes ; then
20298                                         ol_with_yielding_select=yes
20299                                 fi
20300                         fi
20301
20302                                                 CPPFLAGS="$save_CPPFLAGS"
20303                         LIBS="$save_LIBS"
20304                 else
20305                         { { echo "$as_me:$LINENO: error: could not locate usable POSIX Threads" >&5
20306 echo "$as_me: error: could not locate usable POSIX Threads" >&2;}
20307    { (exit 1); exit 1; }; }
20308                 fi
20309         fi
20310
20311         if test $ol_with_threads = posix ; then
20312                 { { echo "$as_me:$LINENO: error: could not locate POSIX Threads" >&5
20313 echo "$as_me: error: could not locate POSIX Threads" >&2;}
20314    { (exit 1); exit 1; }; }
20315         fi
20316 fi
20317
20318 if test $ol_with_threads = auto -o $ol_with_threads = yes \
20319         -o $ol_with_threads = mach ; then
20320
20321
20322
20323 for ac_header in mach/cthreads.h cthreads.h
20324 do
20325 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
20326 if eval "test \"\${$as_ac_Header+set}\" = set"; then
20327   echo "$as_me:$LINENO: checking for $ac_header" >&5
20328 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20329 if eval "test \"\${$as_ac_Header+set}\" = set"; then
20330   echo $ECHO_N "(cached) $ECHO_C" >&6
20331 fi
20332 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20333 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
20334 else
20335   # Is the header compilable?
20336 echo "$as_me:$LINENO: checking $ac_header usability" >&5
20337 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
20338 cat >conftest.$ac_ext <<_ACEOF
20339 #line $LINENO "configure"
20340 /* confdefs.h.  */
20341 _ACEOF
20342 cat confdefs.h >>conftest.$ac_ext
20343 cat >>conftest.$ac_ext <<_ACEOF
20344 /* end confdefs.h.  */
20345 $ac_includes_default
20346 #include <$ac_header>
20347 _ACEOF
20348 rm -f conftest.$ac_objext
20349 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20350   (eval $ac_compile) 2>&5
20351   ac_status=$?
20352   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20353   (exit $ac_status); } &&
20354          { ac_try='test -s conftest.$ac_objext'
20355   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20356   (eval $ac_try) 2>&5
20357   ac_status=$?
20358   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20359   (exit $ac_status); }; }; then
20360   ac_header_compiler=yes
20361 else
20362   echo "$as_me: failed program was:" >&5
20363 sed 's/^/| /' conftest.$ac_ext >&5
20364
20365 ac_header_compiler=no
20366 fi
20367 rm -f conftest.$ac_objext conftest.$ac_ext
20368 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20369 echo "${ECHO_T}$ac_header_compiler" >&6
20370
20371 # Is the header present?
20372 echo "$as_me:$LINENO: checking $ac_header presence" >&5
20373 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
20374 cat >conftest.$ac_ext <<_ACEOF
20375 #line $LINENO "configure"
20376 /* confdefs.h.  */
20377 _ACEOF
20378 cat confdefs.h >>conftest.$ac_ext
20379 cat >>conftest.$ac_ext <<_ACEOF
20380 /* end confdefs.h.  */
20381 #include <$ac_header>
20382 _ACEOF
20383 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
20384   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20385   ac_status=$?
20386   grep -v '^ *+' conftest.er1 >conftest.err
20387   rm -f conftest.er1
20388   cat conftest.err >&5
20389   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20390   (exit $ac_status); } >/dev/null; then
20391   if test -s conftest.err; then
20392     ac_cpp_err=$ac_c_preproc_warn_flag
20393   else
20394     ac_cpp_err=
20395   fi
20396 else
20397   ac_cpp_err=yes
20398 fi
20399 if test -z "$ac_cpp_err"; then
20400   ac_header_preproc=yes
20401 else
20402   echo "$as_me: failed program was:" >&5
20403 sed 's/^/| /' conftest.$ac_ext >&5
20404
20405   ac_header_preproc=no
20406 fi
20407 rm -f conftest.err conftest.$ac_ext
20408 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20409 echo "${ECHO_T}$ac_header_preproc" >&6
20410
20411 # So?  What about this header?
20412 case $ac_header_compiler:$ac_header_preproc in
20413   yes:no )
20414     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20415 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
20416     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20417 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
20418     (
20419       cat <<\_ASBOX
20420 ## ------------------------------------ ##
20421 ## Report this to bug-autoconf@gnu.org. ##
20422 ## ------------------------------------ ##
20423 _ASBOX
20424     ) |
20425       sed "s/^/$as_me: WARNING:     /" >&2
20426     ;;
20427   no:yes )
20428     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20429 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
20430     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
20431 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
20432     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20433 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
20434     (
20435       cat <<\_ASBOX
20436 ## ------------------------------------ ##
20437 ## Report this to bug-autoconf@gnu.org. ##
20438 ## ------------------------------------ ##
20439 _ASBOX
20440     ) |
20441       sed "s/^/$as_me: WARNING:     /" >&2
20442     ;;
20443 esac
20444 echo "$as_me:$LINENO: checking for $ac_header" >&5
20445 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20446 if eval "test \"\${$as_ac_Header+set}\" = set"; then
20447   echo $ECHO_N "(cached) $ECHO_C" >&6
20448 else
20449   eval "$as_ac_Header=$ac_header_preproc"
20450 fi
20451 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20452 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
20453
20454 fi
20455 if test `eval echo '${'$as_ac_Header'}'` = yes; then
20456   cat >>confdefs.h <<_ACEOF
20457 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
20458 _ACEOF
20459
20460 fi
20461
20462 done
20463
20464         if test $ac_cv_header_mach_cthreads_h = yes ; then
20465                 ol_with_threads=found
20466
20467                                 echo "$as_me:$LINENO: checking for cthread_fork" >&5
20468 echo $ECHO_N "checking for cthread_fork... $ECHO_C" >&6
20469 if test "${ac_cv_func_cthread_fork+set}" = set; then
20470   echo $ECHO_N "(cached) $ECHO_C" >&6
20471 else
20472   cat >conftest.$ac_ext <<_ACEOF
20473 #line $LINENO "configure"
20474 /* confdefs.h.  */
20475 _ACEOF
20476 cat confdefs.h >>conftest.$ac_ext
20477 cat >>conftest.$ac_ext <<_ACEOF
20478 /* end confdefs.h.  */
20479 /* System header to define __stub macros and hopefully few prototypes,
20480     which can conflict with char cthread_fork (); below.
20481     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20482     <limits.h> exists even on freestanding compilers.  */
20483 #ifdef __STDC__
20484 # include <limits.h>
20485 #else
20486 # include <assert.h>
20487 #endif
20488 /* Override any gcc2 internal prototype to avoid an error.  */
20489 #ifdef __cplusplus
20490 extern "C"
20491 {
20492 #endif
20493 /* We use char because int might match the return type of a gcc2
20494    builtin and then its argument prototype would still apply.  */
20495 char cthread_fork ();
20496 /* The GNU C library defines this for functions which it implements
20497     to always fail with ENOSYS.  Some functions are actually named
20498     something starting with __ and the normal name is an alias.  */
20499 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
20500 choke me
20501 #else
20502 char (*f) () = cthread_fork;
20503 #endif
20504 #ifdef __cplusplus
20505 }
20506 #endif
20507
20508 int
20509 main ()
20510 {
20511 return f != cthread_fork;
20512   ;
20513   return 0;
20514 }
20515 _ACEOF
20516 rm -f conftest.$ac_objext conftest$ac_exeext
20517 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20518   (eval $ac_link) 2>&5
20519   ac_status=$?
20520   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20521   (exit $ac_status); } &&
20522          { ac_try='test -s conftest$ac_exeext'
20523   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20524   (eval $ac_try) 2>&5
20525   ac_status=$?
20526   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20527   (exit $ac_status); }; }; then
20528   ac_cv_func_cthread_fork=yes
20529 else
20530   echo "$as_me: failed program was:" >&5
20531 sed 's/^/| /' conftest.$ac_ext >&5
20532
20533 ac_cv_func_cthread_fork=no
20534 fi
20535 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20536 fi
20537 echo "$as_me:$LINENO: result: $ac_cv_func_cthread_fork" >&5
20538 echo "${ECHO_T}$ac_cv_func_cthread_fork" >&6
20539 if test $ac_cv_func_cthread_fork = yes; then
20540   ol_link_threads=yes
20541 fi
20542
20543
20544                 if test $ol_link_threads = no ; then
20545                                                                         echo "$as_me:$LINENO: checking for cthread_fork with -all_load" >&5
20546 echo $ECHO_N "checking for cthread_fork with -all_load... $ECHO_C" >&6
20547 if test "${ol_cv_cthread_all_load+set}" = set; then
20548   echo $ECHO_N "(cached) $ECHO_C" >&6
20549 else
20550
20551                                                                 save_LIBS="$LIBS"
20552                                 LIBS="-all_load $LIBS"
20553                                 cat >conftest.$ac_ext <<_ACEOF
20554 #line $LINENO "configure"
20555 /* confdefs.h.  */
20556 _ACEOF
20557 cat confdefs.h >>conftest.$ac_ext
20558 cat >>conftest.$ac_ext <<_ACEOF
20559 /* end confdefs.h.  */
20560 #include <mach/cthreads.h>
20561 int
20562 main ()
20563 {
20564
20565                                         cthread_fork((void *)0, (void *)0);
20566
20567   ;
20568   return 0;
20569 }
20570 _ACEOF
20571 rm -f conftest.$ac_objext conftest$ac_exeext
20572 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20573   (eval $ac_link) 2>&5
20574   ac_status=$?
20575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20576   (exit $ac_status); } &&
20577          { ac_try='test -s conftest$ac_exeext'
20578   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20579   (eval $ac_try) 2>&5
20580   ac_status=$?
20581   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20582   (exit $ac_status); }; }; then
20583   ol_cv_cthread_all_load=yes
20584 else
20585   echo "$as_me: failed program was:" >&5
20586 sed 's/^/| /' conftest.$ac_ext >&5
20587
20588 ol_cv_cthread_all_load=no
20589 fi
20590 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20591                                                                 LIBS="$save_LIBS"
20592
20593 fi
20594 echo "$as_me:$LINENO: result: $ol_cv_cthread_all_load" >&5
20595 echo "${ECHO_T}$ol_cv_cthread_all_load" >&6
20596
20597                         if test $ol_cv_cthread_all_load = yes ; then
20598                                 LTHREAD_LIBS="$LTHREAD_LIBS -all_load"
20599                                 ol_link_threads=mach
20600                                 ol_with_threads=found
20601                         fi
20602                 fi
20603
20604         elif test $ac_cv_header_cthreads_h = yes ; then
20605
20606                 ol_with_threads=found
20607
20608                                 save_LIBS="$LIBS"
20609                 LIBS="$LIBS -lthreads"
20610                 echo "$as_me:$LINENO: checking for cthread_fork" >&5
20611 echo $ECHO_N "checking for cthread_fork... $ECHO_C" >&6
20612 if test "${ac_cv_func_cthread_fork+set}" = set; then
20613   echo $ECHO_N "(cached) $ECHO_C" >&6
20614 else
20615   cat >conftest.$ac_ext <<_ACEOF
20616 #line $LINENO "configure"
20617 /* confdefs.h.  */
20618 _ACEOF
20619 cat confdefs.h >>conftest.$ac_ext
20620 cat >>conftest.$ac_ext <<_ACEOF
20621 /* end confdefs.h.  */
20622 /* System header to define __stub macros and hopefully few prototypes,
20623     which can conflict with char cthread_fork (); below.
20624     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20625     <limits.h> exists even on freestanding compilers.  */
20626 #ifdef __STDC__
20627 # include <limits.h>
20628 #else
20629 # include <assert.h>
20630 #endif
20631 /* Override any gcc2 internal prototype to avoid an error.  */
20632 #ifdef __cplusplus
20633 extern "C"
20634 {
20635 #endif
20636 /* We use char because int might match the return type of a gcc2
20637    builtin and then its argument prototype would still apply.  */
20638 char cthread_fork ();
20639 /* The GNU C library defines this for functions which it implements
20640     to always fail with ENOSYS.  Some functions are actually named
20641     something starting with __ and the normal name is an alias.  */
20642 #if defined (__stub_cthread_fork) || defined (__stub___cthread_fork)
20643 choke me
20644 #else
20645 char (*f) () = cthread_fork;
20646 #endif
20647 #ifdef __cplusplus
20648 }
20649 #endif
20650
20651 int
20652 main ()
20653 {
20654 return f != cthread_fork;
20655   ;
20656   return 0;
20657 }
20658 _ACEOF
20659 rm -f conftest.$ac_objext conftest$ac_exeext
20660 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20661   (eval $ac_link) 2>&5
20662   ac_status=$?
20663   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20664   (exit $ac_status); } &&
20665          { ac_try='test -s conftest$ac_exeext'
20666   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20667   (eval $ac_try) 2>&5
20668   ac_status=$?
20669   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20670   (exit $ac_status); }; }; then
20671   ac_cv_func_cthread_fork=yes
20672 else
20673   echo "$as_me: failed program was:" >&5
20674 sed 's/^/| /' conftest.$ac_ext >&5
20675
20676 ac_cv_func_cthread_fork=no
20677 fi
20678 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20679 fi
20680 echo "$as_me:$LINENO: result: $ac_cv_func_cthread_fork" >&5
20681 echo "${ECHO_T}$ac_cv_func_cthread_fork" >&6
20682 if test $ac_cv_func_cthread_fork = yes; then
20683   ol_link_threads=yes
20684 fi
20685
20686                 LIBS="$save_LIBS"
20687
20688                 if test $ol_link_threads = yes ; then
20689                         LTHREAD_LIBS="-lthreads"
20690                         ol_link_threads=mach
20691                         ol_with_threads=found
20692                 else
20693                         { { echo "$as_me:$LINENO: error: could not link with Mach CThreads" >&5
20694 echo "$as_me: error: could not link with Mach CThreads" >&2;}
20695    { (exit 1); exit 1; }; }
20696                 fi
20697
20698         elif test $ol_with_threads = mach ; then
20699                 { { echo "$as_me:$LINENO: error: could not locate Mach CThreads" >&5
20700 echo "$as_me: error: could not locate Mach CThreads" >&2;}
20701    { (exit 1); exit 1; }; }
20702         fi
20703
20704         if test $ol_link_threads = mach ; then
20705
20706 cat >>confdefs.h <<\_ACEOF
20707 #define HAVE_MACH_CTHREADS 1
20708 _ACEOF
20709
20710         elif test $ol_with_threads = found ; then
20711                 { { echo "$as_me:$LINENO: error: could not link with Mach CThreads" >&5
20712 echo "$as_me: error: could not link with Mach CThreads" >&2;}
20713    { (exit 1); exit 1; }; }
20714         fi
20715 fi
20716
20717 if test $ol_with_threads = auto -o $ol_with_threads = yes \
20718         -o $ol_with_threads = pth ; then
20719
20720
20721 for ac_header in pth.h
20722 do
20723 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
20724 if eval "test \"\${$as_ac_Header+set}\" = set"; then
20725   echo "$as_me:$LINENO: checking for $ac_header" >&5
20726 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20727 if eval "test \"\${$as_ac_Header+set}\" = set"; then
20728   echo $ECHO_N "(cached) $ECHO_C" >&6
20729 fi
20730 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20731 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
20732 else
20733   # Is the header compilable?
20734 echo "$as_me:$LINENO: checking $ac_header usability" >&5
20735 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
20736 cat >conftest.$ac_ext <<_ACEOF
20737 #line $LINENO "configure"
20738 /* confdefs.h.  */
20739 _ACEOF
20740 cat confdefs.h >>conftest.$ac_ext
20741 cat >>conftest.$ac_ext <<_ACEOF
20742 /* end confdefs.h.  */
20743 $ac_includes_default
20744 #include <$ac_header>
20745 _ACEOF
20746 rm -f conftest.$ac_objext
20747 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20748   (eval $ac_compile) 2>&5
20749   ac_status=$?
20750   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20751   (exit $ac_status); } &&
20752          { ac_try='test -s conftest.$ac_objext'
20753   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20754   (eval $ac_try) 2>&5
20755   ac_status=$?
20756   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20757   (exit $ac_status); }; }; then
20758   ac_header_compiler=yes
20759 else
20760   echo "$as_me: failed program was:" >&5
20761 sed 's/^/| /' conftest.$ac_ext >&5
20762
20763 ac_header_compiler=no
20764 fi
20765 rm -f conftest.$ac_objext conftest.$ac_ext
20766 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20767 echo "${ECHO_T}$ac_header_compiler" >&6
20768
20769 # Is the header present?
20770 echo "$as_me:$LINENO: checking $ac_header presence" >&5
20771 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
20772 cat >conftest.$ac_ext <<_ACEOF
20773 #line $LINENO "configure"
20774 /* confdefs.h.  */
20775 _ACEOF
20776 cat confdefs.h >>conftest.$ac_ext
20777 cat >>conftest.$ac_ext <<_ACEOF
20778 /* end confdefs.h.  */
20779 #include <$ac_header>
20780 _ACEOF
20781 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
20782   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20783   ac_status=$?
20784   grep -v '^ *+' conftest.er1 >conftest.err
20785   rm -f conftest.er1
20786   cat conftest.err >&5
20787   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20788   (exit $ac_status); } >/dev/null; then
20789   if test -s conftest.err; then
20790     ac_cpp_err=$ac_c_preproc_warn_flag
20791   else
20792     ac_cpp_err=
20793   fi
20794 else
20795   ac_cpp_err=yes
20796 fi
20797 if test -z "$ac_cpp_err"; then
20798   ac_header_preproc=yes
20799 else
20800   echo "$as_me: failed program was:" >&5
20801 sed 's/^/| /' conftest.$ac_ext >&5
20802
20803   ac_header_preproc=no
20804 fi
20805 rm -f conftest.err conftest.$ac_ext
20806 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20807 echo "${ECHO_T}$ac_header_preproc" >&6
20808
20809 # So?  What about this header?
20810 case $ac_header_compiler:$ac_header_preproc in
20811   yes:no )
20812     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20813 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
20814     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20815 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
20816     (
20817       cat <<\_ASBOX
20818 ## ------------------------------------ ##
20819 ## Report this to bug-autoconf@gnu.org. ##
20820 ## ------------------------------------ ##
20821 _ASBOX
20822     ) |
20823       sed "s/^/$as_me: WARNING:     /" >&2
20824     ;;
20825   no:yes )
20826     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20827 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
20828     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
20829 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
20830     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20831 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
20832     (
20833       cat <<\_ASBOX
20834 ## ------------------------------------ ##
20835 ## Report this to bug-autoconf@gnu.org. ##
20836 ## ------------------------------------ ##
20837 _ASBOX
20838     ) |
20839       sed "s/^/$as_me: WARNING:     /" >&2
20840     ;;
20841 esac
20842 echo "$as_me:$LINENO: checking for $ac_header" >&5
20843 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20844 if eval "test \"\${$as_ac_Header+set}\" = set"; then
20845   echo $ECHO_N "(cached) $ECHO_C" >&6
20846 else
20847   eval "$as_ac_Header=$ac_header_preproc"
20848 fi
20849 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20850 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
20851
20852 fi
20853 if test `eval echo '${'$as_ac_Header'}'` = yes; then
20854   cat >>confdefs.h <<_ACEOF
20855 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
20856 _ACEOF
20857
20858 fi
20859
20860 done
20861
20862
20863         if test $ac_cv_header_pth_h = yes ; then
20864                 echo "$as_me:$LINENO: checking for pth_version in -lpth" >&5
20865 echo $ECHO_N "checking for pth_version in -lpth... $ECHO_C" >&6
20866 if test "${ac_cv_lib_pth_pth_version+set}" = set; then
20867   echo $ECHO_N "(cached) $ECHO_C" >&6
20868 else
20869   ac_check_lib_save_LIBS=$LIBS
20870 LIBS="-lpth  $LIBS"
20871 cat >conftest.$ac_ext <<_ACEOF
20872 #line $LINENO "configure"
20873 /* confdefs.h.  */
20874 _ACEOF
20875 cat confdefs.h >>conftest.$ac_ext
20876 cat >>conftest.$ac_ext <<_ACEOF
20877 /* end confdefs.h.  */
20878
20879 /* Override any gcc2 internal prototype to avoid an error.  */
20880 #ifdef __cplusplus
20881 extern "C"
20882 #endif
20883 /* We use char because int might match the return type of a gcc2
20884    builtin and then its argument prototype would still apply.  */
20885 char pth_version ();
20886 int
20887 main ()
20888 {
20889 pth_version ();
20890   ;
20891   return 0;
20892 }
20893 _ACEOF
20894 rm -f conftest.$ac_objext conftest$ac_exeext
20895 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20896   (eval $ac_link) 2>&5
20897   ac_status=$?
20898   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20899   (exit $ac_status); } &&
20900          { ac_try='test -s conftest$ac_exeext'
20901   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20902   (eval $ac_try) 2>&5
20903   ac_status=$?
20904   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20905   (exit $ac_status); }; }; then
20906   ac_cv_lib_pth_pth_version=yes
20907 else
20908   echo "$as_me: failed program was:" >&5
20909 sed 's/^/| /' conftest.$ac_ext >&5
20910
20911 ac_cv_lib_pth_pth_version=no
20912 fi
20913 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
20914 LIBS=$ac_check_lib_save_LIBS
20915 fi
20916 echo "$as_me:$LINENO: result: $ac_cv_lib_pth_pth_version" >&5
20917 echo "${ECHO_T}$ac_cv_lib_pth_pth_version" >&6
20918 if test $ac_cv_lib_pth_pth_version = yes; then
20919   have_pth=yes
20920 else
20921   have_pth=no
20922 fi
20923
20924
20925                 if test $have_pth = yes ; then
20926
20927 cat >>confdefs.h <<\_ACEOF
20928 #define HAVE_GNU_PTH 1
20929 _ACEOF
20930
20931                         LTHREAD_LIBS="$LTHREAD_LIBS -lpth"
20932                         ol_link_threads=pth
20933                         ol_with_threads=found
20934
20935                         if test $ol_with_yielding_select = auto ; then
20936                                 ol_with_yielding_select=yes
20937                         fi
20938                 fi
20939         fi
20940 fi
20941
20942 if test $ol_with_threads = auto -o $ol_with_threads = yes \
20943         -o $ol_with_threads = lwp ; then
20944
20945
20946
20947 for ac_header in thread.h synch.h
20948 do
20949 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
20950 if eval "test \"\${$as_ac_Header+set}\" = set"; then
20951   echo "$as_me:$LINENO: checking for $ac_header" >&5
20952 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20953 if eval "test \"\${$as_ac_Header+set}\" = set"; then
20954   echo $ECHO_N "(cached) $ECHO_C" >&6
20955 fi
20956 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20957 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
20958 else
20959   # Is the header compilable?
20960 echo "$as_me:$LINENO: checking $ac_header usability" >&5
20961 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
20962 cat >conftest.$ac_ext <<_ACEOF
20963 #line $LINENO "configure"
20964 /* confdefs.h.  */
20965 _ACEOF
20966 cat confdefs.h >>conftest.$ac_ext
20967 cat >>conftest.$ac_ext <<_ACEOF
20968 /* end confdefs.h.  */
20969 $ac_includes_default
20970 #include <$ac_header>
20971 _ACEOF
20972 rm -f conftest.$ac_objext
20973 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20974   (eval $ac_compile) 2>&5
20975   ac_status=$?
20976   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20977   (exit $ac_status); } &&
20978          { ac_try='test -s conftest.$ac_objext'
20979   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20980   (eval $ac_try) 2>&5
20981   ac_status=$?
20982   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20983   (exit $ac_status); }; }; then
20984   ac_header_compiler=yes
20985 else
20986   echo "$as_me: failed program was:" >&5
20987 sed 's/^/| /' conftest.$ac_ext >&5
20988
20989 ac_header_compiler=no
20990 fi
20991 rm -f conftest.$ac_objext conftest.$ac_ext
20992 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20993 echo "${ECHO_T}$ac_header_compiler" >&6
20994
20995 # Is the header present?
20996 echo "$as_me:$LINENO: checking $ac_header presence" >&5
20997 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
20998 cat >conftest.$ac_ext <<_ACEOF
20999 #line $LINENO "configure"
21000 /* confdefs.h.  */
21001 _ACEOF
21002 cat confdefs.h >>conftest.$ac_ext
21003 cat >>conftest.$ac_ext <<_ACEOF
21004 /* end confdefs.h.  */
21005 #include <$ac_header>
21006 _ACEOF
21007 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
21008   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21009   ac_status=$?
21010   grep -v '^ *+' conftest.er1 >conftest.err
21011   rm -f conftest.er1
21012   cat conftest.err >&5
21013   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21014   (exit $ac_status); } >/dev/null; then
21015   if test -s conftest.err; then
21016     ac_cpp_err=$ac_c_preproc_warn_flag
21017   else
21018     ac_cpp_err=
21019   fi
21020 else
21021   ac_cpp_err=yes
21022 fi
21023 if test -z "$ac_cpp_err"; then
21024   ac_header_preproc=yes
21025 else
21026   echo "$as_me: failed program was:" >&5
21027 sed 's/^/| /' conftest.$ac_ext >&5
21028
21029   ac_header_preproc=no
21030 fi
21031 rm -f conftest.err conftest.$ac_ext
21032 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21033 echo "${ECHO_T}$ac_header_preproc" >&6
21034
21035 # So?  What about this header?
21036 case $ac_header_compiler:$ac_header_preproc in
21037   yes:no )
21038     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
21039 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
21040     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21041 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
21042     (
21043       cat <<\_ASBOX
21044 ## ------------------------------------ ##
21045 ## Report this to bug-autoconf@gnu.org. ##
21046 ## ------------------------------------ ##
21047 _ASBOX
21048     ) |
21049       sed "s/^/$as_me: WARNING:     /" >&2
21050     ;;
21051   no:yes )
21052     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
21053 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
21054     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
21055 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
21056     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21057 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
21058     (
21059       cat <<\_ASBOX
21060 ## ------------------------------------ ##
21061 ## Report this to bug-autoconf@gnu.org. ##
21062 ## ------------------------------------ ##
21063 _ASBOX
21064     ) |
21065       sed "s/^/$as_me: WARNING:     /" >&2
21066     ;;
21067 esac
21068 echo "$as_me:$LINENO: checking for $ac_header" >&5
21069 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21070 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21071   echo $ECHO_N "(cached) $ECHO_C" >&6
21072 else
21073   eval "$as_ac_Header=$ac_header_preproc"
21074 fi
21075 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
21076 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
21077
21078 fi
21079 if test `eval echo '${'$as_ac_Header'}'` = yes; then
21080   cat >>confdefs.h <<_ACEOF
21081 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
21082 _ACEOF
21083
21084 fi
21085
21086 done
21087
21088         if test $ac_cv_header_thread_h = yes -a $ac_cv_header_synch_h = yes ; then
21089                 echo "$as_me:$LINENO: checking for thr_create in -lthread" >&5
21090 echo $ECHO_N "checking for thr_create in -lthread... $ECHO_C" >&6
21091 if test "${ac_cv_lib_thread_thr_create+set}" = set; then
21092   echo $ECHO_N "(cached) $ECHO_C" >&6
21093 else
21094   ac_check_lib_save_LIBS=$LIBS
21095 LIBS="-lthread  $LIBS"
21096 cat >conftest.$ac_ext <<_ACEOF
21097 #line $LINENO "configure"
21098 /* confdefs.h.  */
21099 _ACEOF
21100 cat confdefs.h >>conftest.$ac_ext
21101 cat >>conftest.$ac_ext <<_ACEOF
21102 /* end confdefs.h.  */
21103
21104 /* Override any gcc2 internal prototype to avoid an error.  */
21105 #ifdef __cplusplus
21106 extern "C"
21107 #endif
21108 /* We use char because int might match the return type of a gcc2
21109    builtin and then its argument prototype would still apply.  */
21110 char thr_create ();
21111 int
21112 main ()
21113 {
21114 thr_create ();
21115   ;
21116   return 0;
21117 }
21118 _ACEOF
21119 rm -f conftest.$ac_objext conftest$ac_exeext
21120 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21121   (eval $ac_link) 2>&5
21122   ac_status=$?
21123   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21124   (exit $ac_status); } &&
21125          { ac_try='test -s conftest$ac_exeext'
21126   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21127   (eval $ac_try) 2>&5
21128   ac_status=$?
21129   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21130   (exit $ac_status); }; }; then
21131   ac_cv_lib_thread_thr_create=yes
21132 else
21133   echo "$as_me: failed program was:" >&5
21134 sed 's/^/| /' conftest.$ac_ext >&5
21135
21136 ac_cv_lib_thread_thr_create=no
21137 fi
21138 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21139 LIBS=$ac_check_lib_save_LIBS
21140 fi
21141 echo "$as_me:$LINENO: result: $ac_cv_lib_thread_thr_create" >&5
21142 echo "${ECHO_T}$ac_cv_lib_thread_thr_create" >&6
21143 if test $ac_cv_lib_thread_thr_create = yes; then
21144   have_thr=yes
21145 else
21146   have_thr=no
21147 fi
21148
21149
21150                 if test $have_thr = yes ; then
21151
21152 cat >>confdefs.h <<\_ACEOF
21153 #define HAVE_THR 1
21154 _ACEOF
21155
21156                         LTHREAD_LIBS="$LTHREAD_LIBS -lthread"
21157                         ol_link_threads=thr
21158
21159                         if test $ol_with_yielding_select = auto ; then
21160                                 ol_with_yielding_select=yes
21161                         fi
21162
21163
21164
21165 for ac_func in \
21166                                 thr_setconcurrency \
21167                                 thr_getconcurrency \
21168
21169 do
21170 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
21171 echo "$as_me:$LINENO: checking for $ac_func" >&5
21172 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
21173 if eval "test \"\${$as_ac_var+set}\" = set"; then
21174   echo $ECHO_N "(cached) $ECHO_C" >&6
21175 else
21176   cat >conftest.$ac_ext <<_ACEOF
21177 #line $LINENO "configure"
21178 /* confdefs.h.  */
21179 _ACEOF
21180 cat confdefs.h >>conftest.$ac_ext
21181 cat >>conftest.$ac_ext <<_ACEOF
21182 /* end confdefs.h.  */
21183 /* System header to define __stub macros and hopefully few prototypes,
21184     which can conflict with char $ac_func (); below.
21185     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21186     <limits.h> exists even on freestanding compilers.  */
21187 #ifdef __STDC__
21188 # include <limits.h>
21189 #else
21190 # include <assert.h>
21191 #endif
21192 /* Override any gcc2 internal prototype to avoid an error.  */
21193 #ifdef __cplusplus
21194 extern "C"
21195 {
21196 #endif
21197 /* We use char because int might match the return type of a gcc2
21198    builtin and then its argument prototype would still apply.  */
21199 char $ac_func ();
21200 /* The GNU C library defines this for functions which it implements
21201     to always fail with ENOSYS.  Some functions are actually named
21202     something starting with __ and the normal name is an alias.  */
21203 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
21204 choke me
21205 #else
21206 char (*f) () = $ac_func;
21207 #endif
21208 #ifdef __cplusplus
21209 }
21210 #endif
21211
21212 int
21213 main ()
21214 {
21215 return f != $ac_func;
21216   ;
21217   return 0;
21218 }
21219 _ACEOF
21220 rm -f conftest.$ac_objext conftest$ac_exeext
21221 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21222   (eval $ac_link) 2>&5
21223   ac_status=$?
21224   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21225   (exit $ac_status); } &&
21226          { ac_try='test -s conftest$ac_exeext'
21227   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21228   (eval $ac_try) 2>&5
21229   ac_status=$?
21230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21231   (exit $ac_status); }; }; then
21232   eval "$as_ac_var=yes"
21233 else
21234   echo "$as_me: failed program was:" >&5
21235 sed 's/^/| /' conftest.$ac_ext >&5
21236
21237 eval "$as_ac_var=no"
21238 fi
21239 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21240 fi
21241 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
21242 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
21243 if test `eval echo '${'$as_ac_var'}'` = yes; then
21244   cat >>confdefs.h <<_ACEOF
21245 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
21246 _ACEOF
21247
21248 fi
21249 done
21250
21251                 fi
21252         fi
21253
21254
21255 for ac_header in lwp/lwp.h
21256 do
21257 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
21258 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21259   echo "$as_me:$LINENO: checking for $ac_header" >&5
21260 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21261 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21262   echo $ECHO_N "(cached) $ECHO_C" >&6
21263 fi
21264 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
21265 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
21266 else
21267   # Is the header compilable?
21268 echo "$as_me:$LINENO: checking $ac_header usability" >&5
21269 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
21270 cat >conftest.$ac_ext <<_ACEOF
21271 #line $LINENO "configure"
21272 /* confdefs.h.  */
21273 _ACEOF
21274 cat confdefs.h >>conftest.$ac_ext
21275 cat >>conftest.$ac_ext <<_ACEOF
21276 /* end confdefs.h.  */
21277 $ac_includes_default
21278 #include <$ac_header>
21279 _ACEOF
21280 rm -f conftest.$ac_objext
21281 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21282   (eval $ac_compile) 2>&5
21283   ac_status=$?
21284   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21285   (exit $ac_status); } &&
21286          { ac_try='test -s conftest.$ac_objext'
21287   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21288   (eval $ac_try) 2>&5
21289   ac_status=$?
21290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21291   (exit $ac_status); }; }; then
21292   ac_header_compiler=yes
21293 else
21294   echo "$as_me: failed program was:" >&5
21295 sed 's/^/| /' conftest.$ac_ext >&5
21296
21297 ac_header_compiler=no
21298 fi
21299 rm -f conftest.$ac_objext conftest.$ac_ext
21300 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21301 echo "${ECHO_T}$ac_header_compiler" >&6
21302
21303 # Is the header present?
21304 echo "$as_me:$LINENO: checking $ac_header presence" >&5
21305 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
21306 cat >conftest.$ac_ext <<_ACEOF
21307 #line $LINENO "configure"
21308 /* confdefs.h.  */
21309 _ACEOF
21310 cat confdefs.h >>conftest.$ac_ext
21311 cat >>conftest.$ac_ext <<_ACEOF
21312 /* end confdefs.h.  */
21313 #include <$ac_header>
21314 _ACEOF
21315 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
21316   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21317   ac_status=$?
21318   grep -v '^ *+' conftest.er1 >conftest.err
21319   rm -f conftest.er1
21320   cat conftest.err >&5
21321   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21322   (exit $ac_status); } >/dev/null; then
21323   if test -s conftest.err; then
21324     ac_cpp_err=$ac_c_preproc_warn_flag
21325   else
21326     ac_cpp_err=
21327   fi
21328 else
21329   ac_cpp_err=yes
21330 fi
21331 if test -z "$ac_cpp_err"; then
21332   ac_header_preproc=yes
21333 else
21334   echo "$as_me: failed program was:" >&5
21335 sed 's/^/| /' conftest.$ac_ext >&5
21336
21337   ac_header_preproc=no
21338 fi
21339 rm -f conftest.err conftest.$ac_ext
21340 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21341 echo "${ECHO_T}$ac_header_preproc" >&6
21342
21343 # So?  What about this header?
21344 case $ac_header_compiler:$ac_header_preproc in
21345   yes:no )
21346     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
21347 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
21348     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21349 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
21350     (
21351       cat <<\_ASBOX
21352 ## ------------------------------------ ##
21353 ## Report this to bug-autoconf@gnu.org. ##
21354 ## ------------------------------------ ##
21355 _ASBOX
21356     ) |
21357       sed "s/^/$as_me: WARNING:     /" >&2
21358     ;;
21359   no:yes )
21360     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
21361 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
21362     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
21363 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
21364     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21365 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
21366     (
21367       cat <<\_ASBOX
21368 ## ------------------------------------ ##
21369 ## Report this to bug-autoconf@gnu.org. ##
21370 ## ------------------------------------ ##
21371 _ASBOX
21372     ) |
21373       sed "s/^/$as_me: WARNING:     /" >&2
21374     ;;
21375 esac
21376 echo "$as_me:$LINENO: checking for $ac_header" >&5
21377 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21378 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21379   echo $ECHO_N "(cached) $ECHO_C" >&6
21380 else
21381   eval "$as_ac_Header=$ac_header_preproc"
21382 fi
21383 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
21384 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
21385
21386 fi
21387 if test `eval echo '${'$as_ac_Header'}'` = yes; then
21388   cat >>confdefs.h <<_ACEOF
21389 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
21390 _ACEOF
21391
21392 fi
21393
21394 done
21395
21396         if test $ac_cv_header_lwp_lwp_h = yes ; then
21397                 echo "$as_me:$LINENO: checking for lwp_create in -llwp" >&5
21398 echo $ECHO_N "checking for lwp_create in -llwp... $ECHO_C" >&6
21399 if test "${ac_cv_lib_lwp_lwp_create+set}" = set; then
21400   echo $ECHO_N "(cached) $ECHO_C" >&6
21401 else
21402   ac_check_lib_save_LIBS=$LIBS
21403 LIBS="-llwp  $LIBS"
21404 cat >conftest.$ac_ext <<_ACEOF
21405 #line $LINENO "configure"
21406 /* confdefs.h.  */
21407 _ACEOF
21408 cat confdefs.h >>conftest.$ac_ext
21409 cat >>conftest.$ac_ext <<_ACEOF
21410 /* end confdefs.h.  */
21411
21412 /* Override any gcc2 internal prototype to avoid an error.  */
21413 #ifdef __cplusplus
21414 extern "C"
21415 #endif
21416 /* We use char because int might match the return type of a gcc2
21417    builtin and then its argument prototype would still apply.  */
21418 char lwp_create ();
21419 int
21420 main ()
21421 {
21422 lwp_create ();
21423   ;
21424   return 0;
21425 }
21426 _ACEOF
21427 rm -f conftest.$ac_objext conftest$ac_exeext
21428 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21429   (eval $ac_link) 2>&5
21430   ac_status=$?
21431   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21432   (exit $ac_status); } &&
21433          { ac_try='test -s conftest$ac_exeext'
21434   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21435   (eval $ac_try) 2>&5
21436   ac_status=$?
21437   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21438   (exit $ac_status); }; }; then
21439   ac_cv_lib_lwp_lwp_create=yes
21440 else
21441   echo "$as_me: failed program was:" >&5
21442 sed 's/^/| /' conftest.$ac_ext >&5
21443
21444 ac_cv_lib_lwp_lwp_create=no
21445 fi
21446 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21447 LIBS=$ac_check_lib_save_LIBS
21448 fi
21449 echo "$as_me:$LINENO: result: $ac_cv_lib_lwp_lwp_create" >&5
21450 echo "${ECHO_T}$ac_cv_lib_lwp_lwp_create" >&6
21451 if test $ac_cv_lib_lwp_lwp_create = yes; then
21452   have_lwp=yes
21453 else
21454   have_lwp=no
21455 fi
21456
21457
21458                 if test $have_lwp = yes ; then
21459
21460 cat >>confdefs.h <<\_ACEOF
21461 #define HAVE_LWP 1
21462 _ACEOF
21463
21464                         LTHREAD_LIBS="$LTHREAD_LIBS -llwp"
21465                         ol_link_threads=lwp
21466
21467                         if test $ol_with_yielding_select = auto ; then
21468                                 ol_with_yielding_select=no
21469                         fi
21470                 fi
21471         fi
21472 fi
21473
21474 if test $ol_with_yielding_select = yes ; then
21475
21476 cat >>confdefs.h <<\_ACEOF
21477 #define HAVE_YIELDING_SELECT 1
21478 _ACEOF
21479
21480 fi
21481
21482 if test $ol_with_threads = manual ; then
21483                 ol_link_threads=yes
21484
21485         { echo "$as_me:$LINENO: WARNING: thread defines and link options must be set manually" >&5
21486 echo "$as_me: WARNING: thread defines and link options must be set manually" >&2;}
21487
21488
21489
21490 for ac_header in pthread.h sched.h
21491 do
21492 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
21493 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21494   echo "$as_me:$LINENO: checking for $ac_header" >&5
21495 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21496 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21497   echo $ECHO_N "(cached) $ECHO_C" >&6
21498 fi
21499 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
21500 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
21501 else
21502   # Is the header compilable?
21503 echo "$as_me:$LINENO: checking $ac_header usability" >&5
21504 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
21505 cat >conftest.$ac_ext <<_ACEOF
21506 #line $LINENO "configure"
21507 /* confdefs.h.  */
21508 _ACEOF
21509 cat confdefs.h >>conftest.$ac_ext
21510 cat >>conftest.$ac_ext <<_ACEOF
21511 /* end confdefs.h.  */
21512 $ac_includes_default
21513 #include <$ac_header>
21514 _ACEOF
21515 rm -f conftest.$ac_objext
21516 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21517   (eval $ac_compile) 2>&5
21518   ac_status=$?
21519   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21520   (exit $ac_status); } &&
21521          { ac_try='test -s conftest.$ac_objext'
21522   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21523   (eval $ac_try) 2>&5
21524   ac_status=$?
21525   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21526   (exit $ac_status); }; }; then
21527   ac_header_compiler=yes
21528 else
21529   echo "$as_me: failed program was:" >&5
21530 sed 's/^/| /' conftest.$ac_ext >&5
21531
21532 ac_header_compiler=no
21533 fi
21534 rm -f conftest.$ac_objext conftest.$ac_ext
21535 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21536 echo "${ECHO_T}$ac_header_compiler" >&6
21537
21538 # Is the header present?
21539 echo "$as_me:$LINENO: checking $ac_header presence" >&5
21540 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
21541 cat >conftest.$ac_ext <<_ACEOF
21542 #line $LINENO "configure"
21543 /* confdefs.h.  */
21544 _ACEOF
21545 cat confdefs.h >>conftest.$ac_ext
21546 cat >>conftest.$ac_ext <<_ACEOF
21547 /* end confdefs.h.  */
21548 #include <$ac_header>
21549 _ACEOF
21550 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
21551   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21552   ac_status=$?
21553   grep -v '^ *+' conftest.er1 >conftest.err
21554   rm -f conftest.er1
21555   cat conftest.err >&5
21556   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21557   (exit $ac_status); } >/dev/null; then
21558   if test -s conftest.err; then
21559     ac_cpp_err=$ac_c_preproc_warn_flag
21560   else
21561     ac_cpp_err=
21562   fi
21563 else
21564   ac_cpp_err=yes
21565 fi
21566 if test -z "$ac_cpp_err"; then
21567   ac_header_preproc=yes
21568 else
21569   echo "$as_me: failed program was:" >&5
21570 sed 's/^/| /' conftest.$ac_ext >&5
21571
21572   ac_header_preproc=no
21573 fi
21574 rm -f conftest.err conftest.$ac_ext
21575 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21576 echo "${ECHO_T}$ac_header_preproc" >&6
21577
21578 # So?  What about this header?
21579 case $ac_header_compiler:$ac_header_preproc in
21580   yes:no )
21581     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
21582 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
21583     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21584 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
21585     (
21586       cat <<\_ASBOX
21587 ## ------------------------------------ ##
21588 ## Report this to bug-autoconf@gnu.org. ##
21589 ## ------------------------------------ ##
21590 _ASBOX
21591     ) |
21592       sed "s/^/$as_me: WARNING:     /" >&2
21593     ;;
21594   no:yes )
21595     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
21596 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
21597     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
21598 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
21599     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21600 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
21601     (
21602       cat <<\_ASBOX
21603 ## ------------------------------------ ##
21604 ## Report this to bug-autoconf@gnu.org. ##
21605 ## ------------------------------------ ##
21606 _ASBOX
21607     ) |
21608       sed "s/^/$as_me: WARNING:     /" >&2
21609     ;;
21610 esac
21611 echo "$as_me:$LINENO: checking for $ac_header" >&5
21612 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21613 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21614   echo $ECHO_N "(cached) $ECHO_C" >&6
21615 else
21616   eval "$as_ac_Header=$ac_header_preproc"
21617 fi
21618 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
21619 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
21620
21621 fi
21622 if test `eval echo '${'$as_ac_Header'}'` = yes; then
21623   cat >>confdefs.h <<_ACEOF
21624 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
21625 _ACEOF
21626
21627 fi
21628
21629 done
21630
21631
21632
21633 for ac_func in sched_yield pthread_yield
21634 do
21635 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
21636 echo "$as_me:$LINENO: checking for $ac_func" >&5
21637 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
21638 if eval "test \"\${$as_ac_var+set}\" = set"; then
21639   echo $ECHO_N "(cached) $ECHO_C" >&6
21640 else
21641   cat >conftest.$ac_ext <<_ACEOF
21642 #line $LINENO "configure"
21643 /* confdefs.h.  */
21644 _ACEOF
21645 cat confdefs.h >>conftest.$ac_ext
21646 cat >>conftest.$ac_ext <<_ACEOF
21647 /* end confdefs.h.  */
21648 /* System header to define __stub macros and hopefully few prototypes,
21649     which can conflict with char $ac_func (); below.
21650     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21651     <limits.h> exists even on freestanding compilers.  */
21652 #ifdef __STDC__
21653 # include <limits.h>
21654 #else
21655 # include <assert.h>
21656 #endif
21657 /* Override any gcc2 internal prototype to avoid an error.  */
21658 #ifdef __cplusplus
21659 extern "C"
21660 {
21661 #endif
21662 /* We use char because int might match the return type of a gcc2
21663    builtin and then its argument prototype would still apply.  */
21664 char $ac_func ();
21665 /* The GNU C library defines this for functions which it implements
21666     to always fail with ENOSYS.  Some functions are actually named
21667     something starting with __ and the normal name is an alias.  */
21668 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
21669 choke me
21670 #else
21671 char (*f) () = $ac_func;
21672 #endif
21673 #ifdef __cplusplus
21674 }
21675 #endif
21676
21677 int
21678 main ()
21679 {
21680 return f != $ac_func;
21681   ;
21682   return 0;
21683 }
21684 _ACEOF
21685 rm -f conftest.$ac_objext conftest$ac_exeext
21686 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21687   (eval $ac_link) 2>&5
21688   ac_status=$?
21689   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21690   (exit $ac_status); } &&
21691          { ac_try='test -s conftest$ac_exeext'
21692   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21693   (eval $ac_try) 2>&5
21694   ac_status=$?
21695   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21696   (exit $ac_status); }; }; then
21697   eval "$as_ac_var=yes"
21698 else
21699   echo "$as_me: failed program was:" >&5
21700 sed 's/^/| /' conftest.$ac_ext >&5
21701
21702 eval "$as_ac_var=no"
21703 fi
21704 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
21705 fi
21706 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
21707 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
21708 if test `eval echo '${'$as_ac_var'}'` = yes; then
21709   cat >>confdefs.h <<_ACEOF
21710 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
21711 _ACEOF
21712
21713 fi
21714 done
21715
21716
21717         echo "$as_me:$LINENO: checking for LinuxThreads pthread.h" >&5
21718 echo $ECHO_N "checking for LinuxThreads pthread.h... $ECHO_C" >&6
21719 if test "${ol_cv_header_linux_threads+set}" = set; then
21720   echo $ECHO_N "(cached) $ECHO_C" >&6
21721 else
21722   cat >conftest.$ac_ext <<_ACEOF
21723 #line $LINENO "configure"
21724 /* confdefs.h.  */
21725 _ACEOF
21726 cat confdefs.h >>conftest.$ac_ext
21727 cat >>conftest.$ac_ext <<_ACEOF
21728 /* end confdefs.h.  */
21729 #include <pthread.h>
21730 _ACEOF
21731 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
21732   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then
21733   ol_cv_header_linux_threads=yes
21734 else
21735   ol_cv_header_linux_threads=no
21736 fi
21737 rm -f conftest*
21738
21739
21740 fi
21741 echo "$as_me:$LINENO: result: $ol_cv_header_linux_threads" >&5
21742 echo "${ECHO_T}$ol_cv_header_linux_threads" >&6
21743         if test $ol_cv_header_linux_threads = yes; then
21744
21745 cat >>confdefs.h <<\_ACEOF
21746 #define HAVE_LINUX_THREADS 1
21747 _ACEOF
21748
21749         fi
21750
21751
21752
21753 for ac_header in mach/cthreads.h
21754 do
21755 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
21756 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21757   echo "$as_me:$LINENO: checking for $ac_header" >&5
21758 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21759 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21760   echo $ECHO_N "(cached) $ECHO_C" >&6
21761 fi
21762 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
21763 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
21764 else
21765   # Is the header compilable?
21766 echo "$as_me:$LINENO: checking $ac_header usability" >&5
21767 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
21768 cat >conftest.$ac_ext <<_ACEOF
21769 #line $LINENO "configure"
21770 /* confdefs.h.  */
21771 _ACEOF
21772 cat confdefs.h >>conftest.$ac_ext
21773 cat >>conftest.$ac_ext <<_ACEOF
21774 /* end confdefs.h.  */
21775 $ac_includes_default
21776 #include <$ac_header>
21777 _ACEOF
21778 rm -f conftest.$ac_objext
21779 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21780   (eval $ac_compile) 2>&5
21781   ac_status=$?
21782   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21783   (exit $ac_status); } &&
21784          { ac_try='test -s conftest.$ac_objext'
21785   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21786   (eval $ac_try) 2>&5
21787   ac_status=$?
21788   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21789   (exit $ac_status); }; }; then
21790   ac_header_compiler=yes
21791 else
21792   echo "$as_me: failed program was:" >&5
21793 sed 's/^/| /' conftest.$ac_ext >&5
21794
21795 ac_header_compiler=no
21796 fi
21797 rm -f conftest.$ac_objext conftest.$ac_ext
21798 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21799 echo "${ECHO_T}$ac_header_compiler" >&6
21800
21801 # Is the header present?
21802 echo "$as_me:$LINENO: checking $ac_header presence" >&5
21803 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
21804 cat >conftest.$ac_ext <<_ACEOF
21805 #line $LINENO "configure"
21806 /* confdefs.h.  */
21807 _ACEOF
21808 cat confdefs.h >>conftest.$ac_ext
21809 cat >>conftest.$ac_ext <<_ACEOF
21810 /* end confdefs.h.  */
21811 #include <$ac_header>
21812 _ACEOF
21813 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
21814   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21815   ac_status=$?
21816   grep -v '^ *+' conftest.er1 >conftest.err
21817   rm -f conftest.er1
21818   cat conftest.err >&5
21819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21820   (exit $ac_status); } >/dev/null; then
21821   if test -s conftest.err; then
21822     ac_cpp_err=$ac_c_preproc_warn_flag
21823   else
21824     ac_cpp_err=
21825   fi
21826 else
21827   ac_cpp_err=yes
21828 fi
21829 if test -z "$ac_cpp_err"; then
21830   ac_header_preproc=yes
21831 else
21832   echo "$as_me: failed program was:" >&5
21833 sed 's/^/| /' conftest.$ac_ext >&5
21834
21835   ac_header_preproc=no
21836 fi
21837 rm -f conftest.err conftest.$ac_ext
21838 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21839 echo "${ECHO_T}$ac_header_preproc" >&6
21840
21841 # So?  What about this header?
21842 case $ac_header_compiler:$ac_header_preproc in
21843   yes:no )
21844     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
21845 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
21846     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21847 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
21848     (
21849       cat <<\_ASBOX
21850 ## ------------------------------------ ##
21851 ## Report this to bug-autoconf@gnu.org. ##
21852 ## ------------------------------------ ##
21853 _ASBOX
21854     ) |
21855       sed "s/^/$as_me: WARNING:     /" >&2
21856     ;;
21857   no:yes )
21858     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
21859 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
21860     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
21861 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
21862     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21863 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
21864     (
21865       cat <<\_ASBOX
21866 ## ------------------------------------ ##
21867 ## Report this to bug-autoconf@gnu.org. ##
21868 ## ------------------------------------ ##
21869 _ASBOX
21870     ) |
21871       sed "s/^/$as_me: WARNING:     /" >&2
21872     ;;
21873 esac
21874 echo "$as_me:$LINENO: checking for $ac_header" >&5
21875 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21876 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21877   echo $ECHO_N "(cached) $ECHO_C" >&6
21878 else
21879   eval "$as_ac_Header=$ac_header_preproc"
21880 fi
21881 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
21882 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
21883
21884 fi
21885 if test `eval echo '${'$as_ac_Header'}'` = yes; then
21886   cat >>confdefs.h <<_ACEOF
21887 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
21888 _ACEOF
21889
21890 fi
21891
21892 done
21893
21894
21895 for ac_header in lwp/lwp.h
21896 do
21897 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
21898 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21899   echo "$as_me:$LINENO: checking for $ac_header" >&5
21900 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21901 if eval "test \"\${$as_ac_Header+set}\" = set"; then
21902   echo $ECHO_N "(cached) $ECHO_C" >&6
21903 fi
21904 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
21905 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
21906 else
21907   # Is the header compilable?
21908 echo "$as_me:$LINENO: checking $ac_header usability" >&5
21909 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
21910 cat >conftest.$ac_ext <<_ACEOF
21911 #line $LINENO "configure"
21912 /* confdefs.h.  */
21913 _ACEOF
21914 cat confdefs.h >>conftest.$ac_ext
21915 cat >>conftest.$ac_ext <<_ACEOF
21916 /* end confdefs.h.  */
21917 $ac_includes_default
21918 #include <$ac_header>
21919 _ACEOF
21920 rm -f conftest.$ac_objext
21921 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21922   (eval $ac_compile) 2>&5
21923   ac_status=$?
21924   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21925   (exit $ac_status); } &&
21926          { ac_try='test -s conftest.$ac_objext'
21927   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21928   (eval $ac_try) 2>&5
21929   ac_status=$?
21930   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21931   (exit $ac_status); }; }; then
21932   ac_header_compiler=yes
21933 else
21934   echo "$as_me: failed program was:" >&5
21935 sed 's/^/| /' conftest.$ac_ext >&5
21936
21937 ac_header_compiler=no
21938 fi
21939 rm -f conftest.$ac_objext conftest.$ac_ext
21940 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21941 echo "${ECHO_T}$ac_header_compiler" >&6
21942
21943 # Is the header present?
21944 echo "$as_me:$LINENO: checking $ac_header presence" >&5
21945 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
21946 cat >conftest.$ac_ext <<_ACEOF
21947 #line $LINENO "configure"
21948 /* confdefs.h.  */
21949 _ACEOF
21950 cat confdefs.h >>conftest.$ac_ext
21951 cat >>conftest.$ac_ext <<_ACEOF
21952 /* end confdefs.h.  */
21953 #include <$ac_header>
21954 _ACEOF
21955 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
21956   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21957   ac_status=$?
21958   grep -v '^ *+' conftest.er1 >conftest.err
21959   rm -f conftest.er1
21960   cat conftest.err >&5
21961   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21962   (exit $ac_status); } >/dev/null; then
21963   if test -s conftest.err; then
21964     ac_cpp_err=$ac_c_preproc_warn_flag
21965   else
21966     ac_cpp_err=
21967   fi
21968 else
21969   ac_cpp_err=yes
21970 fi
21971 if test -z "$ac_cpp_err"; then
21972   ac_header_preproc=yes
21973 else
21974   echo "$as_me: failed program was:" >&5
21975 sed 's/^/| /' conftest.$ac_ext >&5
21976
21977   ac_header_preproc=no
21978 fi
21979 rm -f conftest.err conftest.$ac_ext
21980 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21981 echo "${ECHO_T}$ac_header_preproc" >&6
21982
21983 # So?  What about this header?
21984 case $ac_header_compiler:$ac_header_preproc in
21985   yes:no )
21986     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
21987 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
21988     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21989 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
21990     (
21991       cat <<\_ASBOX
21992 ## ------------------------------------ ##
21993 ## Report this to bug-autoconf@gnu.org. ##
21994 ## ------------------------------------ ##
21995 _ASBOX
21996     ) |
21997       sed "s/^/$as_me: WARNING:     /" >&2
21998     ;;
21999   no:yes )
22000     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
22001 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
22002     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
22003 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
22004     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
22005 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
22006     (
22007       cat <<\_ASBOX
22008 ## ------------------------------------ ##
22009 ## Report this to bug-autoconf@gnu.org. ##
22010 ## ------------------------------------ ##
22011 _ASBOX
22012     ) |
22013       sed "s/^/$as_me: WARNING:     /" >&2
22014     ;;
22015 esac
22016 echo "$as_me:$LINENO: checking for $ac_header" >&5
22017 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
22018 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22019   echo $ECHO_N "(cached) $ECHO_C" >&6
22020 else
22021   eval "$as_ac_Header=$ac_header_preproc"
22022 fi
22023 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
22024 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
22025
22026 fi
22027 if test `eval echo '${'$as_ac_Header'}'` = yes; then
22028   cat >>confdefs.h <<_ACEOF
22029 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
22030 _ACEOF
22031
22032 fi
22033
22034 done
22035
22036
22037
22038 for ac_header in thread.h synch.h
22039 do
22040 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
22041 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22042   echo "$as_me:$LINENO: checking for $ac_header" >&5
22043 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
22044 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22045   echo $ECHO_N "(cached) $ECHO_C" >&6
22046 fi
22047 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
22048 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
22049 else
22050   # Is the header compilable?
22051 echo "$as_me:$LINENO: checking $ac_header usability" >&5
22052 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
22053 cat >conftest.$ac_ext <<_ACEOF
22054 #line $LINENO "configure"
22055 /* confdefs.h.  */
22056 _ACEOF
22057 cat confdefs.h >>conftest.$ac_ext
22058 cat >>conftest.$ac_ext <<_ACEOF
22059 /* end confdefs.h.  */
22060 $ac_includes_default
22061 #include <$ac_header>
22062 _ACEOF
22063 rm -f conftest.$ac_objext
22064 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
22065   (eval $ac_compile) 2>&5
22066   ac_status=$?
22067   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22068   (exit $ac_status); } &&
22069          { ac_try='test -s conftest.$ac_objext'
22070   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22071   (eval $ac_try) 2>&5
22072   ac_status=$?
22073   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22074   (exit $ac_status); }; }; then
22075   ac_header_compiler=yes
22076 else
22077   echo "$as_me: failed program was:" >&5
22078 sed 's/^/| /' conftest.$ac_ext >&5
22079
22080 ac_header_compiler=no
22081 fi
22082 rm -f conftest.$ac_objext conftest.$ac_ext
22083 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22084 echo "${ECHO_T}$ac_header_compiler" >&6
22085
22086 # Is the header present?
22087 echo "$as_me:$LINENO: checking $ac_header presence" >&5
22088 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
22089 cat >conftest.$ac_ext <<_ACEOF
22090 #line $LINENO "configure"
22091 /* confdefs.h.  */
22092 _ACEOF
22093 cat confdefs.h >>conftest.$ac_ext
22094 cat >>conftest.$ac_ext <<_ACEOF
22095 /* end confdefs.h.  */
22096 #include <$ac_header>
22097 _ACEOF
22098 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
22099   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
22100   ac_status=$?
22101   grep -v '^ *+' conftest.er1 >conftest.err
22102   rm -f conftest.er1
22103   cat conftest.err >&5
22104   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22105   (exit $ac_status); } >/dev/null; then
22106   if test -s conftest.err; then
22107     ac_cpp_err=$ac_c_preproc_warn_flag
22108   else
22109     ac_cpp_err=
22110   fi
22111 else
22112   ac_cpp_err=yes
22113 fi
22114 if test -z "$ac_cpp_err"; then
22115   ac_header_preproc=yes
22116 else
22117   echo "$as_me: failed program was:" >&5
22118 sed 's/^/| /' conftest.$ac_ext >&5
22119
22120   ac_header_preproc=no
22121 fi
22122 rm -f conftest.err conftest.$ac_ext
22123 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22124 echo "${ECHO_T}$ac_header_preproc" >&6
22125
22126 # So?  What about this header?
22127 case $ac_header_compiler:$ac_header_preproc in
22128   yes:no )
22129     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
22130 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
22131     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
22132 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
22133     (
22134       cat <<\_ASBOX
22135 ## ------------------------------------ ##
22136 ## Report this to bug-autoconf@gnu.org. ##
22137 ## ------------------------------------ ##
22138 _ASBOX
22139     ) |
22140       sed "s/^/$as_me: WARNING:     /" >&2
22141     ;;
22142   no:yes )
22143     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
22144 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
22145     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
22146 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
22147     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
22148 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
22149     (
22150       cat <<\_ASBOX
22151 ## ------------------------------------ ##
22152 ## Report this to bug-autoconf@gnu.org. ##
22153 ## ------------------------------------ ##
22154 _ASBOX
22155     ) |
22156       sed "s/^/$as_me: WARNING:     /" >&2
22157     ;;
22158 esac
22159 echo "$as_me:$LINENO: checking for $ac_header" >&5
22160 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
22161 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22162   echo $ECHO_N "(cached) $ECHO_C" >&6
22163 else
22164   eval "$as_ac_Header=$ac_header_preproc"
22165 fi
22166 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
22167 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
22168
22169 fi
22170 if test `eval echo '${'$as_ac_Header'}'` = yes; then
22171   cat >>confdefs.h <<_ACEOF
22172 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
22173 _ACEOF
22174
22175 fi
22176
22177 done
22178
22179 fi
22180
22181 if test $ol_link_threads != no -a $ol_link_threads != nt ; then
22182                         cat >>confdefs.h <<\_ACEOF
22183 #define REENTRANT 1
22184 _ACEOF
22185
22186         cat >>confdefs.h <<\_ACEOF
22187 #define _REENTRANT 1
22188 _ACEOF
22189
22190         cat >>confdefs.h <<\_ACEOF
22191 #define THREAD_SAFE 1
22192 _ACEOF
22193
22194         cat >>confdefs.h <<\_ACEOF
22195 #define _THREAD_SAFE 1
22196 _ACEOF
22197
22198         cat >>confdefs.h <<\_ACEOF
22199 #define THREADSAFE 1
22200 _ACEOF
22201
22202         cat >>confdefs.h <<\_ACEOF
22203 #define _THREADSAFE 1
22204 _ACEOF
22205
22206         cat >>confdefs.h <<\_ACEOF
22207 #define _SGI_MP_SOURCE 1
22208 _ACEOF
22209
22210
22211                         echo "$as_me:$LINENO: checking for thread specific errno" >&5
22212 echo $ECHO_N "checking for thread specific errno... $ECHO_C" >&6
22213 if test "${ol_cv_errno_thread_specific+set}" = set; then
22214   echo $ECHO_N "(cached) $ECHO_C" >&6
22215 else
22216
22217                 cat >conftest.$ac_ext <<_ACEOF
22218 #line $LINENO "configure"
22219 /* confdefs.h.  */
22220 _ACEOF
22221 cat confdefs.h >>conftest.$ac_ext
22222 cat >>conftest.$ac_ext <<_ACEOF
22223 /* end confdefs.h.  */
22224 #include <errno.h>
22225 int
22226 main ()
22227 {
22228 errno = 0;
22229   ;
22230   return 0;
22231 }
22232 _ACEOF
22233 rm -f conftest.$ac_objext conftest$ac_exeext
22234 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22235   (eval $ac_link) 2>&5
22236   ac_status=$?
22237   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22238   (exit $ac_status); } &&
22239          { ac_try='test -s conftest$ac_exeext'
22240   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22241   (eval $ac_try) 2>&5
22242   ac_status=$?
22243   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22244   (exit $ac_status); }; }; then
22245   ol_cv_errno_thread_specific=yes
22246 else
22247   echo "$as_me: failed program was:" >&5
22248 sed 's/^/| /' conftest.$ac_ext >&5
22249
22250 ol_cv_errno_thread_specific=no
22251 fi
22252 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22253
22254 fi
22255 echo "$as_me:$LINENO: result: $ol_cv_errno_thread_specific" >&5
22256 echo "${ECHO_T}$ol_cv_errno_thread_specific" >&6
22257
22258                         echo "$as_me:$LINENO: checking for thread specific h_errno" >&5
22259 echo $ECHO_N "checking for thread specific h_errno... $ECHO_C" >&6
22260 if test "${ol_cv_h_errno_thread_specific+set}" = set; then
22261   echo $ECHO_N "(cached) $ECHO_C" >&6
22262 else
22263
22264                 cat >conftest.$ac_ext <<_ACEOF
22265 #line $LINENO "configure"
22266 /* confdefs.h.  */
22267 _ACEOF
22268 cat confdefs.h >>conftest.$ac_ext
22269 cat >>conftest.$ac_ext <<_ACEOF
22270 /* end confdefs.h.  */
22271 #include <netdb.h>
22272 int
22273 main ()
22274 {
22275 h_errno = 0;
22276   ;
22277   return 0;
22278 }
22279 _ACEOF
22280 rm -f conftest.$ac_objext conftest$ac_exeext
22281 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22282   (eval $ac_link) 2>&5
22283   ac_status=$?
22284   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22285   (exit $ac_status); } &&
22286          { ac_try='test -s conftest$ac_exeext'
22287   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22288   (eval $ac_try) 2>&5
22289   ac_status=$?
22290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22291   (exit $ac_status); }; }; then
22292   ol_cv_h_errno_thread_specific=yes
22293 else
22294   echo "$as_me: failed program was:" >&5
22295 sed 's/^/| /' conftest.$ac_ext >&5
22296
22297 ol_cv_h_errno_thread_specific=no
22298 fi
22299 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22300
22301 fi
22302 echo "$as_me:$LINENO: result: $ol_cv_h_errno_thread_specific" >&5
22303 echo "${ECHO_T}$ol_cv_h_errno_thread_specific" >&6
22304
22305         if test $ol_cv_errno_thread_specific != yes \
22306                 -o $ol_cv_h_errno_thread_specific != yes ; then
22307                 LIBS="$LTHREAD_LIBS $LIBS"
22308                 LTHREAD_LIBS=""
22309         fi
22310
22311 fi
22312
22313 if test $ol_link_threads = no ; then
22314         if test $ol_with_threads = yes ; then
22315                 { { echo "$as_me:$LINENO: error: no suitable thread support" >&5
22316 echo "$as_me: error: no suitable thread support" >&2;}
22317    { (exit 1); exit 1; }; }
22318         fi
22319
22320         if test $ol_with_threads = auto ; then
22321                 { echo "$as_me:$LINENO: WARNING: no suitable thread support, disabling threads" >&5
22322 echo "$as_me: WARNING: no suitable thread support, disabling threads" >&2;}
22323                 ol_with_threads=no
22324         fi
22325
22326
22327 cat >>confdefs.h <<\_ACEOF
22328 #define NO_THREADS 1
22329 _ACEOF
22330
22331         LTHREAD_LIBS=""
22332 fi
22333
22334 if test $ol_link_threads != no ; then
22335         cat >>confdefs.h <<\_ACEOF
22336 #define LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE 1
22337 _ACEOF
22338
22339 fi
22340
22341
22342
22343
22344 for ac_func in \
22345         ctime_r                 \
22346         gethostbyname_r gethostbyaddr_r \
22347
22348 do
22349 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
22350 echo "$as_me:$LINENO: checking for $ac_func" >&5
22351 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
22352 if eval "test \"\${$as_ac_var+set}\" = set"; then
22353   echo $ECHO_N "(cached) $ECHO_C" >&6
22354 else
22355   cat >conftest.$ac_ext <<_ACEOF
22356 #line $LINENO "configure"
22357 /* confdefs.h.  */
22358 _ACEOF
22359 cat confdefs.h >>conftest.$ac_ext
22360 cat >>conftest.$ac_ext <<_ACEOF
22361 /* end confdefs.h.  */
22362 /* System header to define __stub macros and hopefully few prototypes,
22363     which can conflict with char $ac_func (); below.
22364     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22365     <limits.h> exists even on freestanding compilers.  */
22366 #ifdef __STDC__
22367 # include <limits.h>
22368 #else
22369 # include <assert.h>
22370 #endif
22371 /* Override any gcc2 internal prototype to avoid an error.  */
22372 #ifdef __cplusplus
22373 extern "C"
22374 {
22375 #endif
22376 /* We use char because int might match the return type of a gcc2
22377    builtin and then its argument prototype would still apply.  */
22378 char $ac_func ();
22379 /* The GNU C library defines this for functions which it implements
22380     to always fail with ENOSYS.  Some functions are actually named
22381     something starting with __ and the normal name is an alias.  */
22382 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
22383 choke me
22384 #else
22385 char (*f) () = $ac_func;
22386 #endif
22387 #ifdef __cplusplus
22388 }
22389 #endif
22390
22391 int
22392 main ()
22393 {
22394 return f != $ac_func;
22395   ;
22396   return 0;
22397 }
22398 _ACEOF
22399 rm -f conftest.$ac_objext conftest$ac_exeext
22400 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22401   (eval $ac_link) 2>&5
22402   ac_status=$?
22403   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22404   (exit $ac_status); } &&
22405          { ac_try='test -s conftest$ac_exeext'
22406   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22407   (eval $ac_try) 2>&5
22408   ac_status=$?
22409   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22410   (exit $ac_status); }; }; then
22411   eval "$as_ac_var=yes"
22412 else
22413   echo "$as_me: failed program was:" >&5
22414 sed 's/^/| /' conftest.$ac_ext >&5
22415
22416 eval "$as_ac_var=no"
22417 fi
22418 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
22419 fi
22420 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
22421 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
22422 if test `eval echo '${'$as_ac_var'}'` = yes; then
22423   cat >>confdefs.h <<_ACEOF
22424 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
22425 _ACEOF
22426
22427 fi
22428 done
22429
22430
22431 if test "$ac_cv_func_ctime_r" = no ; then
22432         ol_cv_func_ctime_r_nargs=0
22433 else
22434         echo "$as_me:$LINENO: checking number of arguments of ctime_r" >&5
22435 echo $ECHO_N "checking number of arguments of ctime_r... $ECHO_C" >&6
22436 if test "${ol_cv_func_ctime_r_nargs+set}" = set; then
22437   echo $ECHO_N "(cached) $ECHO_C" >&6
22438 else
22439   cat >conftest.$ac_ext <<_ACEOF
22440 #line $LINENO "configure"
22441 /* confdefs.h.  */
22442 _ACEOF
22443 cat confdefs.h >>conftest.$ac_ext
22444 cat >>conftest.$ac_ext <<_ACEOF
22445 /* end confdefs.h.  */
22446 #include <time.h>
22447 int
22448 main ()
22449 {
22450 time_t ti; char *buffer; ctime_r(&ti,buffer,32);
22451   ;
22452   return 0;
22453 }
22454 _ACEOF
22455 rm -f conftest.$ac_objext
22456 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
22457   (eval $ac_compile) 2>&5
22458   ac_status=$?
22459   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22460   (exit $ac_status); } &&
22461          { ac_try='test -s conftest.$ac_objext'
22462   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22463   (eval $ac_try) 2>&5
22464   ac_status=$?
22465   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22466   (exit $ac_status); }; }; then
22467   ol_cv_func_ctime_r_nargs3=yes
22468 else
22469   echo "$as_me: failed program was:" >&5
22470 sed 's/^/| /' conftest.$ac_ext >&5
22471
22472 ol_cv_func_ctime_r_nargs3=no
22473 fi
22474 rm -f conftest.$ac_objext conftest.$ac_ext
22475
22476         cat >conftest.$ac_ext <<_ACEOF
22477 #line $LINENO "configure"
22478 /* confdefs.h.  */
22479 _ACEOF
22480 cat confdefs.h >>conftest.$ac_ext
22481 cat >>conftest.$ac_ext <<_ACEOF
22482 /* end confdefs.h.  */
22483 #include <time.h>
22484 int
22485 main ()
22486 {
22487 time_t ti; char *buffer; ctime_r(&ti,buffer);
22488   ;
22489   return 0;
22490 }
22491 _ACEOF
22492 rm -f conftest.$ac_objext
22493 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
22494   (eval $ac_compile) 2>&5
22495   ac_status=$?
22496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22497   (exit $ac_status); } &&
22498          { ac_try='test -s conftest.$ac_objext'
22499   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22500   (eval $ac_try) 2>&5
22501   ac_status=$?
22502   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22503   (exit $ac_status); }; }; then
22504   ol_cv_func_ctime_r_nargs2=yes
22505 else
22506   echo "$as_me: failed program was:" >&5
22507 sed 's/^/| /' conftest.$ac_ext >&5
22508
22509 ol_cv_func_ctime_r_nargs2=no
22510 fi
22511 rm -f conftest.$ac_objext conftest.$ac_ext
22512
22513         if test $ol_cv_func_ctime_r_nargs3 = yes -a \
22514                 $ol_cv_func_ctime_r_nargs2 = no ; then
22515
22516                 ol_cv_func_ctime_r_nargs=3
22517
22518         elif test $ol_cv_func_ctime_r_nargs3 = no -a \
22519                 $ol_cv_func_ctime_r_nargs2 = yes ; then
22520
22521                 ol_cv_func_ctime_r_nargs=2
22522
22523         else
22524                 ol_cv_func_ctime_r_nargs=0
22525         fi
22526
22527 fi
22528 echo "$as_me:$LINENO: result: $ol_cv_func_ctime_r_nargs" >&5
22529 echo "${ECHO_T}$ol_cv_func_ctime_r_nargs" >&6
22530
22531   if test $ol_cv_func_ctime_r_nargs -gt 1 ; then
22532
22533 cat >>confdefs.h <<_ACEOF
22534 #define CTIME_R_NARGS $ol_cv_func_ctime_r_nargs
22535 _ACEOF
22536
22537   fi
22538
22539 fi
22540
22541 if test "$ac_cv_func_gethostbyname_r" = yes ; then
22542         echo "$as_me:$LINENO: checking number of arguments of gethostbyname_r" >&5
22543 echo $ECHO_N "checking number of arguments of gethostbyname_r... $ECHO_C" >&6
22544 if test "${ol_cv_func_gethostbyname_r_nargs+set}" = set; then
22545   echo $ECHO_N "(cached) $ECHO_C" >&6
22546 else
22547   cat >conftest.$ac_ext <<_ACEOF
22548 #line $LINENO "configure"
22549 /* confdefs.h.  */
22550 _ACEOF
22551 cat confdefs.h >>conftest.$ac_ext
22552 cat >>conftest.$ac_ext <<_ACEOF
22553 /* end confdefs.h.  */
22554 #include <sys/types.h>
22555 #include <sys/socket.h>
22556 #include <netinet/in.h>
22557 #include <netdb.h>
22558 #define BUFSIZE (sizeof(struct hostent)+10)
22559 int
22560 main ()
22561 {
22562 struct hostent hent; char buffer[BUFSIZE];
22563                 int bufsize=BUFSIZE;int h_errno;
22564                 (void)gethostbyname_r("segovia.cs.purdue.edu", &hent,
22565                         buffer, bufsize, &h_errno);
22566   ;
22567   return 0;
22568 }
22569 _ACEOF
22570 rm -f conftest.$ac_objext
22571 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
22572   (eval $ac_compile) 2>&5
22573   ac_status=$?
22574   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22575   (exit $ac_status); } &&
22576          { ac_try='test -s conftest.$ac_objext'
22577   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22578   (eval $ac_try) 2>&5
22579   ac_status=$?
22580   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22581   (exit $ac_status); }; }; then
22582   ol_cv_func_gethostbyname_r_nargs5=yes
22583 else
22584   echo "$as_me: failed program was:" >&5
22585 sed 's/^/| /' conftest.$ac_ext >&5
22586
22587 ol_cv_func_gethostbyname_r_nargs5=no
22588 fi
22589 rm -f conftest.$ac_objext conftest.$ac_ext
22590
22591         cat >conftest.$ac_ext <<_ACEOF
22592 #line $LINENO "configure"
22593 /* confdefs.h.  */
22594 _ACEOF
22595 cat confdefs.h >>conftest.$ac_ext
22596 cat >>conftest.$ac_ext <<_ACEOF
22597 /* end confdefs.h.  */
22598 #include <sys/types.h>
22599 #include <sys/socket.h>
22600 #include <netinet/in.h>
22601 #include <netdb.h>
22602 #define BUFSIZE (sizeof(struct hostent)+10)
22603 int
22604 main ()
22605 {
22606 struct hostent hent;struct hostent *rhent;
22607                 char buffer[BUFSIZE];
22608                 int bufsize=BUFSIZE;int h_errno;
22609                 (void)gethostbyname_r("localhost", &hent, buffer, bufsize,
22610                         &rhent, &h_errno);
22611   ;
22612   return 0;
22613 }
22614 _ACEOF
22615 rm -f conftest.$ac_objext
22616 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
22617   (eval $ac_compile) 2>&5
22618   ac_status=$?
22619   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22620   (exit $ac_status); } &&
22621          { ac_try='test -s conftest.$ac_objext'
22622   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22623   (eval $ac_try) 2>&5
22624   ac_status=$?
22625   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22626   (exit $ac_status); }; }; then
22627   ol_cv_func_gethostbyname_r_nargs6=yes
22628 else
22629   echo "$as_me: failed program was:" >&5
22630 sed 's/^/| /' conftest.$ac_ext >&5
22631
22632 ol_cv_func_gethostbyname_r_nargs6=no
22633 fi
22634 rm -f conftest.$ac_objext conftest.$ac_ext
22635
22636         if test $ol_cv_func_gethostbyname_r_nargs5 = yes -a \
22637                 $ol_cv_func_gethostbyname_r_nargs6 = no ; then
22638
22639                 ol_cv_func_gethostbyname_r_nargs=5
22640
22641         elif test $ol_cv_func_gethostbyname_r_nargs5 = no -a \
22642                 $ol_cv_func_gethostbyname_r_nargs6 = yes ; then
22643
22644                 ol_cv_func_gethostbyname_r_nargs=6
22645
22646         else
22647                 ol_cv_func_gethostbyname_r_nargs=0
22648         fi
22649
22650 fi
22651 echo "$as_me:$LINENO: result: $ol_cv_func_gethostbyname_r_nargs" >&5
22652 echo "${ECHO_T}$ol_cv_func_gethostbyname_r_nargs" >&6
22653   if test $ol_cv_func_gethostbyname_r_nargs -gt 1 ; then
22654
22655 cat >>confdefs.h <<_ACEOF
22656 #define GETHOSTBYNAME_R_NARGS $ol_cv_func_gethostbyname_r_nargs
22657 _ACEOF
22658
22659   fi
22660
22661 else
22662         ol_cv_func_gethostbyname_r_nargs=0
22663 fi
22664
22665 if test "$ac_cv_func_gethostbyaddr_r" = yes ; then
22666         echo "$as_me:$LINENO: checking number of arguments of gethostbyaddr_r" >&5
22667 echo $ECHO_N "checking number of arguments of gethostbyaddr_r... $ECHO_C" >&6
22668 if test "${ol_cv_func_gethostbyaddr_r_nargs+set}" = set; then
22669   echo $ECHO_N "(cached) $ECHO_C" >&6
22670 else
22671   cat >conftest.$ac_ext <<_ACEOF
22672 #line $LINENO "configure"
22673 /* confdefs.h.  */
22674 _ACEOF
22675 cat confdefs.h >>conftest.$ac_ext
22676 cat >>conftest.$ac_ext <<_ACEOF
22677 /* end confdefs.h.  */
22678 #include <sys/types.h>
22679 #include <sys/socket.h>
22680 #include <netinet/in.h>
22681 #include <netdb.h>
22682 #define BUFSIZE (sizeof(struct hostent)+10)
22683 int
22684 main ()
22685 {
22686 struct hostent hent; char buffer[BUFSIZE];
22687             struct in_addr add;
22688             size_t alen=sizeof(struct in_addr);
22689             int bufsize=BUFSIZE;int h_errno;
22690                 (void)gethostbyaddr_r( (void *)&(add.s_addr),
22691                         alen, AF_INET, &hent, buffer, bufsize, &h_errno);
22692   ;
22693   return 0;
22694 }
22695 _ACEOF
22696 rm -f conftest.$ac_objext
22697 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
22698   (eval $ac_compile) 2>&5
22699   ac_status=$?
22700   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22701   (exit $ac_status); } &&
22702          { ac_try='test -s conftest.$ac_objext'
22703   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22704   (eval $ac_try) 2>&5
22705   ac_status=$?
22706   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22707   (exit $ac_status); }; }; then
22708   ol_cv_func_gethostbyaddr_r_nargs7=yes
22709 else
22710   echo "$as_me: failed program was:" >&5
22711 sed 's/^/| /' conftest.$ac_ext >&5
22712
22713 ol_cv_func_gethostbyaddr_r_nargs7=no
22714 fi
22715 rm -f conftest.$ac_objext conftest.$ac_ext
22716
22717         cat >conftest.$ac_ext <<_ACEOF
22718 #line $LINENO "configure"
22719 /* confdefs.h.  */
22720 _ACEOF
22721 cat confdefs.h >>conftest.$ac_ext
22722 cat >>conftest.$ac_ext <<_ACEOF
22723 /* end confdefs.h.  */
22724 #include <sys/types.h>
22725 #include <sys/socket.h>
22726 #include <netinet/in.h>
22727 #include <netdb.h>
22728 #define BUFSIZE (sizeof(struct hostent)+10)
22729 int
22730 main ()
22731 {
22732 struct hostent hent;
22733                 struct hostent *rhent; char buffer[BUFSIZE];
22734                 struct in_addr add;
22735                 size_t alen=sizeof(struct in_addr);
22736                 int bufsize=BUFSIZE;int h_errno;
22737                 (void)gethostbyaddr_r( (void *)&(add.s_addr),
22738                         alen, AF_INET, &hent, buffer, bufsize,
22739                         &rhent, &h_errno);
22740   ;
22741   return 0;
22742 }
22743 _ACEOF
22744 rm -f conftest.$ac_objext
22745 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
22746   (eval $ac_compile) 2>&5
22747   ac_status=$?
22748   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22749   (exit $ac_status); } &&
22750          { ac_try='test -s conftest.$ac_objext'
22751   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22752   (eval $ac_try) 2>&5
22753   ac_status=$?
22754   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22755   (exit $ac_status); }; }; then
22756   ol_cv_func_gethostbyaddr_r_nargs8=yes
22757 else
22758   echo "$as_me: failed program was:" >&5
22759 sed 's/^/| /' conftest.$ac_ext >&5
22760
22761 ol_cv_func_gethostbyaddr_r_nargs8=no
22762 fi
22763 rm -f conftest.$ac_objext conftest.$ac_ext
22764
22765         if test $ol_cv_func_gethostbyaddr_r_nargs7 = yes -a \
22766                 $ol_cv_func_gethostbyaddr_r_nargs8 = no ; then
22767
22768                 ol_cv_func_gethostbyaddr_r_nargs=7
22769
22770         elif test $ol_cv_func_gethostbyaddr_r_nargs7 = no -a \
22771                 $ol_cv_func_gethostbyaddr_r_nargs8 = yes ; then
22772
22773                 ol_cv_func_gethostbyaddr_r_nargs=8
22774
22775         else
22776                 ol_cv_func_gethostbyaddr_r_nargs=0
22777         fi
22778
22779 fi
22780 echo "$as_me:$LINENO: result: $ol_cv_func_gethostbyaddr_r_nargs" >&5
22781 echo "${ECHO_T}$ol_cv_func_gethostbyaddr_r_nargs" >&6
22782   if test $ol_cv_func_gethostbyaddr_r_nargs -gt 1 ; then
22783
22784 cat >>confdefs.h <<_ACEOF
22785 #define GETHOSTBYADDR_R_NARGS $ol_cv_func_gethostbyaddr_r_nargs
22786 _ACEOF
22787
22788   fi
22789
22790 else
22791         ol_cv_func_gethostbyaddr_r_nargs=0
22792 fi
22793
22794 ol_link_ldbm=no
22795
22796 if test $ol_with_ldbm_api = auto \
22797         -o $ol_with_ldbm_api = berkeley \
22798         -o $ol_with_ldbm_api = bcompat ; then
22799
22800         if test $ol_with_ldbm_api = bcompat; then \
22801
22802
22803 for ac_header in db_185.h db.h
22804 do
22805 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
22806 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22807   echo "$as_me:$LINENO: checking for $ac_header" >&5
22808 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
22809 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22810   echo $ECHO_N "(cached) $ECHO_C" >&6
22811 fi
22812 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
22813 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
22814 else
22815   # Is the header compilable?
22816 echo "$as_me:$LINENO: checking $ac_header usability" >&5
22817 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
22818 cat >conftest.$ac_ext <<_ACEOF
22819 #line $LINENO "configure"
22820 /* confdefs.h.  */
22821 _ACEOF
22822 cat confdefs.h >>conftest.$ac_ext
22823 cat >>conftest.$ac_ext <<_ACEOF
22824 /* end confdefs.h.  */
22825 $ac_includes_default
22826 #include <$ac_header>
22827 _ACEOF
22828 rm -f conftest.$ac_objext
22829 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
22830   (eval $ac_compile) 2>&5
22831   ac_status=$?
22832   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22833   (exit $ac_status); } &&
22834          { ac_try='test -s conftest.$ac_objext'
22835   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22836   (eval $ac_try) 2>&5
22837   ac_status=$?
22838   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22839   (exit $ac_status); }; }; then
22840   ac_header_compiler=yes
22841 else
22842   echo "$as_me: failed program was:" >&5
22843 sed 's/^/| /' conftest.$ac_ext >&5
22844
22845 ac_header_compiler=no
22846 fi
22847 rm -f conftest.$ac_objext conftest.$ac_ext
22848 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22849 echo "${ECHO_T}$ac_header_compiler" >&6
22850
22851 # Is the header present?
22852 echo "$as_me:$LINENO: checking $ac_header presence" >&5
22853 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
22854 cat >conftest.$ac_ext <<_ACEOF
22855 #line $LINENO "configure"
22856 /* confdefs.h.  */
22857 _ACEOF
22858 cat confdefs.h >>conftest.$ac_ext
22859 cat >>conftest.$ac_ext <<_ACEOF
22860 /* end confdefs.h.  */
22861 #include <$ac_header>
22862 _ACEOF
22863 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
22864   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
22865   ac_status=$?
22866   grep -v '^ *+' conftest.er1 >conftest.err
22867   rm -f conftest.er1
22868   cat conftest.err >&5
22869   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22870   (exit $ac_status); } >/dev/null; then
22871   if test -s conftest.err; then
22872     ac_cpp_err=$ac_c_preproc_warn_flag
22873   else
22874     ac_cpp_err=
22875   fi
22876 else
22877   ac_cpp_err=yes
22878 fi
22879 if test -z "$ac_cpp_err"; then
22880   ac_header_preproc=yes
22881 else
22882   echo "$as_me: failed program was:" >&5
22883 sed 's/^/| /' conftest.$ac_ext >&5
22884
22885   ac_header_preproc=no
22886 fi
22887 rm -f conftest.err conftest.$ac_ext
22888 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22889 echo "${ECHO_T}$ac_header_preproc" >&6
22890
22891 # So?  What about this header?
22892 case $ac_header_compiler:$ac_header_preproc in
22893   yes:no )
22894     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
22895 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
22896     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
22897 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
22898     (
22899       cat <<\_ASBOX
22900 ## ------------------------------------ ##
22901 ## Report this to bug-autoconf@gnu.org. ##
22902 ## ------------------------------------ ##
22903 _ASBOX
22904     ) |
22905       sed "s/^/$as_me: WARNING:     /" >&2
22906     ;;
22907   no:yes )
22908     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
22909 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
22910     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
22911 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
22912     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
22913 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
22914     (
22915       cat <<\_ASBOX
22916 ## ------------------------------------ ##
22917 ## Report this to bug-autoconf@gnu.org. ##
22918 ## ------------------------------------ ##
22919 _ASBOX
22920     ) |
22921       sed "s/^/$as_me: WARNING:     /" >&2
22922     ;;
22923 esac
22924 echo "$as_me:$LINENO: checking for $ac_header" >&5
22925 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
22926 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22927   echo $ECHO_N "(cached) $ECHO_C" >&6
22928 else
22929   eval "$as_ac_Header=$ac_header_preproc"
22930 fi
22931 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
22932 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
22933
22934 fi
22935 if test `eval echo '${'$as_ac_Header'}'` = yes; then
22936   cat >>confdefs.h <<_ACEOF
22937 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
22938 _ACEOF
22939
22940 fi
22941
22942 done
22943
22944 if test $ac_cv_header_db_185_h = yes -o $ac_cv_header_db_h = yes; then
22945         echo "$as_me:$LINENO: checking if Berkeley DB header compatibility" >&5
22946 echo $ECHO_N "checking if Berkeley DB header compatibility... $ECHO_C" >&6
22947 if test "${ol_cv_header_db1+set}" = set; then
22948   echo $ECHO_N "(cached) $ECHO_C" >&6
22949 else
22950
22951                 cat >conftest.$ac_ext <<_ACEOF
22952 #line $LINENO "configure"
22953 /* confdefs.h.  */
22954 _ACEOF
22955 cat confdefs.h >>conftest.$ac_ext
22956 cat >>conftest.$ac_ext <<_ACEOF
22957 /* end confdefs.h.  */
22958
22959 #if HAVE_DB_185_H
22960 #       include <db_185.h>
22961 #else
22962 #       include <db.h>
22963 #endif
22964
22965  /* this check could be improved */
22966 #ifndef DB_VERSION_MAJOR
22967 #       define DB_VERSION_MAJOR 1
22968 #endif
22969
22970 #if DB_VERSION_MAJOR == 1
22971         __db_version_1
22972 #endif
22973
22974 _ACEOF
22975 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22976   $EGREP "__db_version_1" >/dev/null 2>&1; then
22977   ol_cv_header_db1=yes
22978 else
22979   ol_cv_header_db1=no
22980 fi
22981 rm -f conftest*
22982
22983 fi
22984 echo "$as_me:$LINENO: result: $ol_cv_header_db1" >&5
22985 echo "${ECHO_T}$ol_cv_header_db1" >&6
22986
22987         if test $ol_cv_header_db1 = yes ; then
22988                 ol_cv_lib_db=no
22989 if test $ol_cv_lib_db = no ; then
22990         echo "$as_me:$LINENO: checking for Berkeley DB link (default)" >&5
22991 echo $ECHO_N "checking for Berkeley DB link (default)... $ECHO_C" >&6
22992 if test "${ol_cv_db_none+set}" = set; then
22993   echo $ECHO_N "(cached) $ECHO_C" >&6
22994 else
22995
22996         ol_DB_LIB=
22997         ol_LIBS=$LIBS
22998         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
22999
23000         cat >conftest.$ac_ext <<_ACEOF
23001 #line $LINENO "configure"
23002 /* confdefs.h.  */
23003 _ACEOF
23004 cat confdefs.h >>conftest.$ac_ext
23005 cat >>conftest.$ac_ext <<_ACEOF
23006 /* end confdefs.h.  */
23007
23008 #ifdef HAVE_DB_185_H
23009 # include <db_185.h>
23010 #else
23011 # include <db.h>
23012 #endif
23013
23014 #ifndef DB_VERSION_MAJOR
23015 # define DB_VERSION_MAJOR 1
23016 #endif
23017
23018 #ifndef NULL
23019 #define NULL ((void*)0)
23020 #endif
23021
23022 int
23023 main ()
23024 {
23025
23026 #if DB_VERSION_MAJOR > 1
23027         {
23028                 char *version;
23029                 int major, minor, patch;
23030
23031                 version = db_version( &major, &minor, &patch );
23032
23033                 if( major != DB_VERSION_MAJOR ||
23034                         minor < DB_VERSION_MINOR )
23035                 {
23036                         printf("Berkeley DB version mismatch\n"
23037                                 "\texpected: %s\n\tgot: %s\n",
23038                                 DB_VERSION_STRING, version);
23039                         return 1;
23040                 }
23041         }
23042 #endif
23043
23044 #if DB_VERSION_MAJOR > 2
23045         db_env_create( NULL, 0 );
23046 #elif DB_VERSION_MAJOR > 1
23047         db_appexit( NULL );
23048 #else
23049         (void) dbopen( NULL, 0, 0, 0, NULL);
23050 #endif
23051
23052   ;
23053   return 0;
23054 }
23055 _ACEOF
23056 rm -f conftest.$ac_objext conftest$ac_exeext
23057 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23058   (eval $ac_link) 2>&5
23059   ac_status=$?
23060   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23061   (exit $ac_status); } &&
23062          { ac_try='test -s conftest$ac_exeext'
23063   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23064   (eval $ac_try) 2>&5
23065   ac_status=$?
23066   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23067   (exit $ac_status); }; }; then
23068   ol_cv_db_none=yes
23069 else
23070   echo "$as_me: failed program was:" >&5
23071 sed 's/^/| /' conftest.$ac_ext >&5
23072
23073 ol_cv_db_none=no
23074 fi
23075 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23076
23077         LIBS="$ol_LIBS"
23078
23079 fi
23080 echo "$as_me:$LINENO: result: $ol_cv_db_none" >&5
23081 echo "${ECHO_T}$ol_cv_db_none" >&6
23082
23083         if test $ol_cv_db_none = yes ; then
23084                 ol_cv_lib_db=yes
23085         fi
23086 fi
23087
23088 if test $ol_cv_lib_db = no ; then
23089         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb41)" >&5
23090 echo $ECHO_N "checking for Berkeley DB link (-ldb41)... $ECHO_C" >&6
23091 if test "${ol_cv_db_db41+set}" = set; then
23092   echo $ECHO_N "(cached) $ECHO_C" >&6
23093 else
23094
23095         ol_DB_LIB=-ldb41
23096         ol_LIBS=$LIBS
23097         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
23098
23099         cat >conftest.$ac_ext <<_ACEOF
23100 #line $LINENO "configure"
23101 /* confdefs.h.  */
23102 _ACEOF
23103 cat confdefs.h >>conftest.$ac_ext
23104 cat >>conftest.$ac_ext <<_ACEOF
23105 /* end confdefs.h.  */
23106
23107 #ifdef HAVE_DB_185_H
23108 # include <db_185.h>
23109 #else
23110 # include <db.h>
23111 #endif
23112
23113 #ifndef DB_VERSION_MAJOR
23114 # define DB_VERSION_MAJOR 1
23115 #endif
23116
23117 #ifndef NULL
23118 #define NULL ((void*)0)
23119 #endif
23120
23121 int
23122 main ()
23123 {
23124
23125 #if DB_VERSION_MAJOR > 1
23126         {
23127                 char *version;
23128                 int major, minor, patch;
23129
23130                 version = db_version( &major, &minor, &patch );
23131
23132                 if( major != DB_VERSION_MAJOR ||
23133                         minor < DB_VERSION_MINOR )
23134                 {
23135                         printf("Berkeley DB version mismatch\n"
23136                                 "\texpected: %s\n\tgot: %s\n",
23137                                 DB_VERSION_STRING, version);
23138                         return 1;
23139                 }
23140         }
23141 #endif
23142
23143 #if DB_VERSION_MAJOR > 2
23144         db_env_create( NULL, 0 );
23145 #elif DB_VERSION_MAJOR > 1
23146         db_appexit( NULL );
23147 #else
23148         (void) dbopen( NULL, 0, 0, 0, NULL);
23149 #endif
23150
23151   ;
23152   return 0;
23153 }
23154 _ACEOF
23155 rm -f conftest.$ac_objext conftest$ac_exeext
23156 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23157   (eval $ac_link) 2>&5
23158   ac_status=$?
23159   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23160   (exit $ac_status); } &&
23161          { ac_try='test -s conftest$ac_exeext'
23162   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23163   (eval $ac_try) 2>&5
23164   ac_status=$?
23165   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23166   (exit $ac_status); }; }; then
23167   ol_cv_db_db41=yes
23168 else
23169   echo "$as_me: failed program was:" >&5
23170 sed 's/^/| /' conftest.$ac_ext >&5
23171
23172 ol_cv_db_db41=no
23173 fi
23174 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23175
23176         LIBS="$ol_LIBS"
23177
23178 fi
23179 echo "$as_me:$LINENO: result: $ol_cv_db_db41" >&5
23180 echo "${ECHO_T}$ol_cv_db_db41" >&6
23181
23182         if test $ol_cv_db_db41 = yes ; then
23183                 ol_cv_lib_db=-ldb41
23184         fi
23185 fi
23186
23187 if test $ol_cv_lib_db = no ; then
23188         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-41)" >&5
23189 echo $ECHO_N "checking for Berkeley DB link (-ldb-41)... $ECHO_C" >&6
23190 if test "${ol_cv_db_db_41+set}" = set; then
23191   echo $ECHO_N "(cached) $ECHO_C" >&6
23192 else
23193
23194         ol_DB_LIB=-ldb-41
23195         ol_LIBS=$LIBS
23196         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
23197
23198         cat >conftest.$ac_ext <<_ACEOF
23199 #line $LINENO "configure"
23200 /* confdefs.h.  */
23201 _ACEOF
23202 cat confdefs.h >>conftest.$ac_ext
23203 cat >>conftest.$ac_ext <<_ACEOF
23204 /* end confdefs.h.  */
23205
23206 #ifdef HAVE_DB_185_H
23207 # include <db_185.h>
23208 #else
23209 # include <db.h>
23210 #endif
23211
23212 #ifndef DB_VERSION_MAJOR
23213 # define DB_VERSION_MAJOR 1
23214 #endif
23215
23216 #ifndef NULL
23217 #define NULL ((void*)0)
23218 #endif
23219
23220 int
23221 main ()
23222 {
23223
23224 #if DB_VERSION_MAJOR > 1
23225         {
23226                 char *version;
23227                 int major, minor, patch;
23228
23229                 version = db_version( &major, &minor, &patch );
23230
23231                 if( major != DB_VERSION_MAJOR ||
23232                         minor < DB_VERSION_MINOR )
23233                 {
23234                         printf("Berkeley DB version mismatch\n"
23235                                 "\texpected: %s\n\tgot: %s\n",
23236                                 DB_VERSION_STRING, version);
23237                         return 1;
23238                 }
23239         }
23240 #endif
23241
23242 #if DB_VERSION_MAJOR > 2
23243         db_env_create( NULL, 0 );
23244 #elif DB_VERSION_MAJOR > 1
23245         db_appexit( NULL );
23246 #else
23247         (void) dbopen( NULL, 0, 0, 0, NULL);
23248 #endif
23249
23250   ;
23251   return 0;
23252 }
23253 _ACEOF
23254 rm -f conftest.$ac_objext conftest$ac_exeext
23255 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23256   (eval $ac_link) 2>&5
23257   ac_status=$?
23258   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23259   (exit $ac_status); } &&
23260          { ac_try='test -s conftest$ac_exeext'
23261   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23262   (eval $ac_try) 2>&5
23263   ac_status=$?
23264   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23265   (exit $ac_status); }; }; then
23266   ol_cv_db_db_41=yes
23267 else
23268   echo "$as_me: failed program was:" >&5
23269 sed 's/^/| /' conftest.$ac_ext >&5
23270
23271 ol_cv_db_db_41=no
23272 fi
23273 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23274
23275         LIBS="$ol_LIBS"
23276
23277 fi
23278 echo "$as_me:$LINENO: result: $ol_cv_db_db_41" >&5
23279 echo "${ECHO_T}$ol_cv_db_db_41" >&6
23280
23281         if test $ol_cv_db_db_41 = yes ; then
23282                 ol_cv_lib_db=-ldb-41
23283         fi
23284 fi
23285
23286 if test $ol_cv_lib_db = no ; then
23287         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.1)" >&5
23288 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.1)... $ECHO_C" >&6
23289 if test "${ol_cv_db_db_4_dot_1+set}" = set; then
23290   echo $ECHO_N "(cached) $ECHO_C" >&6
23291 else
23292
23293         ol_DB_LIB=-ldb-4.1
23294         ol_LIBS=$LIBS
23295         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
23296
23297         cat >conftest.$ac_ext <<_ACEOF
23298 #line $LINENO "configure"
23299 /* confdefs.h.  */
23300 _ACEOF
23301 cat confdefs.h >>conftest.$ac_ext
23302 cat >>conftest.$ac_ext <<_ACEOF
23303 /* end confdefs.h.  */
23304
23305 #ifdef HAVE_DB_185_H
23306 # include <db_185.h>
23307 #else
23308 # include <db.h>
23309 #endif
23310
23311 #ifndef DB_VERSION_MAJOR
23312 # define DB_VERSION_MAJOR 1
23313 #endif
23314
23315 #ifndef NULL
23316 #define NULL ((void*)0)
23317 #endif
23318
23319 int
23320 main ()
23321 {
23322
23323 #if DB_VERSION_MAJOR > 1
23324         {
23325                 char *version;
23326                 int major, minor, patch;
23327
23328                 version = db_version( &major, &minor, &patch );
23329
23330                 if( major != DB_VERSION_MAJOR ||
23331                         minor < DB_VERSION_MINOR )
23332                 {
23333                         printf("Berkeley DB version mismatch\n"
23334                                 "\texpected: %s\n\tgot: %s\n",
23335                                 DB_VERSION_STRING, version);
23336                         return 1;
23337                 }
23338         }
23339 #endif
23340
23341 #if DB_VERSION_MAJOR > 2
23342         db_env_create( NULL, 0 );
23343 #elif DB_VERSION_MAJOR > 1
23344         db_appexit( NULL );
23345 #else
23346         (void) dbopen( NULL, 0, 0, 0, NULL);
23347 #endif
23348
23349   ;
23350   return 0;
23351 }
23352 _ACEOF
23353 rm -f conftest.$ac_objext conftest$ac_exeext
23354 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23355   (eval $ac_link) 2>&5
23356   ac_status=$?
23357   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23358   (exit $ac_status); } &&
23359          { ac_try='test -s conftest$ac_exeext'
23360   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23361   (eval $ac_try) 2>&5
23362   ac_status=$?
23363   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23364   (exit $ac_status); }; }; then
23365   ol_cv_db_db_4_dot_1=yes
23366 else
23367   echo "$as_me: failed program was:" >&5
23368 sed 's/^/| /' conftest.$ac_ext >&5
23369
23370 ol_cv_db_db_4_dot_1=no
23371 fi
23372 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23373
23374         LIBS="$ol_LIBS"
23375
23376 fi
23377 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_1" >&5
23378 echo "${ECHO_T}$ol_cv_db_db_4_dot_1" >&6
23379
23380         if test $ol_cv_db_db_4_dot_1 = yes ; then
23381                 ol_cv_lib_db=-ldb-4.1
23382         fi
23383 fi
23384
23385 if test $ol_cv_lib_db = no ; then
23386         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-1)" >&5
23387 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-1)... $ECHO_C" >&6
23388 if test "${ol_cv_db_db_4_1+set}" = set; then
23389   echo $ECHO_N "(cached) $ECHO_C" >&6
23390 else
23391
23392         ol_DB_LIB=-ldb-4-1
23393         ol_LIBS=$LIBS
23394         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
23395
23396         cat >conftest.$ac_ext <<_ACEOF
23397 #line $LINENO "configure"
23398 /* confdefs.h.  */
23399 _ACEOF
23400 cat confdefs.h >>conftest.$ac_ext
23401 cat >>conftest.$ac_ext <<_ACEOF
23402 /* end confdefs.h.  */
23403
23404 #ifdef HAVE_DB_185_H
23405 # include <db_185.h>
23406 #else
23407 # include <db.h>
23408 #endif
23409
23410 #ifndef DB_VERSION_MAJOR
23411 # define DB_VERSION_MAJOR 1
23412 #endif
23413
23414 #ifndef NULL
23415 #define NULL ((void*)0)
23416 #endif
23417
23418 int
23419 main ()
23420 {
23421
23422 #if DB_VERSION_MAJOR > 1
23423         {
23424                 char *version;
23425                 int major, minor, patch;
23426
23427                 version = db_version( &major, &minor, &patch );
23428
23429                 if( major != DB_VERSION_MAJOR ||
23430                         minor < DB_VERSION_MINOR )
23431                 {
23432                         printf("Berkeley DB version mismatch\n"
23433                                 "\texpected: %s\n\tgot: %s\n",
23434                                 DB_VERSION_STRING, version);
23435                         return 1;
23436                 }
23437         }
23438 #endif
23439
23440 #if DB_VERSION_MAJOR > 2
23441         db_env_create( NULL, 0 );
23442 #elif DB_VERSION_MAJOR > 1
23443         db_appexit( NULL );
23444 #else
23445         (void) dbopen( NULL, 0, 0, 0, NULL);
23446 #endif
23447
23448   ;
23449   return 0;
23450 }
23451 _ACEOF
23452 rm -f conftest.$ac_objext conftest$ac_exeext
23453 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23454   (eval $ac_link) 2>&5
23455   ac_status=$?
23456   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23457   (exit $ac_status); } &&
23458          { ac_try='test -s conftest$ac_exeext'
23459   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23460   (eval $ac_try) 2>&5
23461   ac_status=$?
23462   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23463   (exit $ac_status); }; }; then
23464   ol_cv_db_db_4_1=yes
23465 else
23466   echo "$as_me: failed program was:" >&5
23467 sed 's/^/| /' conftest.$ac_ext >&5
23468
23469 ol_cv_db_db_4_1=no
23470 fi
23471 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23472
23473         LIBS="$ol_LIBS"
23474
23475 fi
23476 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_1" >&5
23477 echo "${ECHO_T}$ol_cv_db_db_4_1" >&6
23478
23479         if test $ol_cv_db_db_4_1 = yes ; then
23480                 ol_cv_lib_db=-ldb-4-1
23481         fi
23482 fi
23483
23484 if test $ol_cv_lib_db = no ; then
23485         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4)" >&5
23486 echo $ECHO_N "checking for Berkeley DB link (-ldb-4)... $ECHO_C" >&6
23487 if test "${ol_cv_db_db_4+set}" = set; then
23488   echo $ECHO_N "(cached) $ECHO_C" >&6
23489 else
23490
23491         ol_DB_LIB=-ldb-4
23492         ol_LIBS=$LIBS
23493         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
23494
23495         cat >conftest.$ac_ext <<_ACEOF
23496 #line $LINENO "configure"
23497 /* confdefs.h.  */
23498 _ACEOF
23499 cat confdefs.h >>conftest.$ac_ext
23500 cat >>conftest.$ac_ext <<_ACEOF
23501 /* end confdefs.h.  */
23502
23503 #ifdef HAVE_DB_185_H
23504 # include <db_185.h>
23505 #else
23506 # include <db.h>
23507 #endif
23508
23509 #ifndef DB_VERSION_MAJOR
23510 # define DB_VERSION_MAJOR 1
23511 #endif
23512
23513 #ifndef NULL
23514 #define NULL ((void*)0)
23515 #endif
23516
23517 int
23518 main ()
23519 {
23520
23521 #if DB_VERSION_MAJOR > 1
23522         {
23523                 char *version;
23524                 int major, minor, patch;
23525
23526                 version = db_version( &major, &minor, &patch );
23527
23528                 if( major != DB_VERSION_MAJOR ||
23529                         minor < DB_VERSION_MINOR )
23530                 {
23531                         printf("Berkeley DB version mismatch\n"
23532                                 "\texpected: %s\n\tgot: %s\n",
23533                                 DB_VERSION_STRING, version);
23534                         return 1;
23535                 }
23536         }
23537 #endif
23538
23539 #if DB_VERSION_MAJOR > 2
23540         db_env_create( NULL, 0 );
23541 #elif DB_VERSION_MAJOR > 1
23542         db_appexit( NULL );
23543 #else
23544         (void) dbopen( NULL, 0, 0, 0, NULL);
23545 #endif
23546
23547   ;
23548   return 0;
23549 }
23550 _ACEOF
23551 rm -f conftest.$ac_objext conftest$ac_exeext
23552 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23553   (eval $ac_link) 2>&5
23554   ac_status=$?
23555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23556   (exit $ac_status); } &&
23557          { ac_try='test -s conftest$ac_exeext'
23558   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23559   (eval $ac_try) 2>&5
23560   ac_status=$?
23561   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23562   (exit $ac_status); }; }; then
23563   ol_cv_db_db_4=yes
23564 else
23565   echo "$as_me: failed program was:" >&5
23566 sed 's/^/| /' conftest.$ac_ext >&5
23567
23568 ol_cv_db_db_4=no
23569 fi
23570 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23571
23572         LIBS="$ol_LIBS"
23573
23574 fi
23575 echo "$as_me:$LINENO: result: $ol_cv_db_db_4" >&5
23576 echo "${ECHO_T}$ol_cv_db_db_4" >&6
23577
23578         if test $ol_cv_db_db_4 = yes ; then
23579                 ol_cv_lib_db=-ldb-4
23580         fi
23581 fi
23582
23583 if test $ol_cv_lib_db = no ; then
23584         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb4)" >&5
23585 echo $ECHO_N "checking for Berkeley DB link (-ldb4)... $ECHO_C" >&6
23586 if test "${ol_cv_db_db4+set}" = set; then
23587   echo $ECHO_N "(cached) $ECHO_C" >&6
23588 else
23589
23590         ol_DB_LIB=-ldb4
23591         ol_LIBS=$LIBS
23592         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
23593
23594         cat >conftest.$ac_ext <<_ACEOF
23595 #line $LINENO "configure"
23596 /* confdefs.h.  */
23597 _ACEOF
23598 cat confdefs.h >>conftest.$ac_ext
23599 cat >>conftest.$ac_ext <<_ACEOF
23600 /* end confdefs.h.  */
23601
23602 #ifdef HAVE_DB_185_H
23603 # include <db_185.h>
23604 #else
23605 # include <db.h>
23606 #endif
23607
23608 #ifndef DB_VERSION_MAJOR
23609 # define DB_VERSION_MAJOR 1
23610 #endif
23611
23612 #ifndef NULL
23613 #define NULL ((void*)0)
23614 #endif
23615
23616 int
23617 main ()
23618 {
23619
23620 #if DB_VERSION_MAJOR > 1
23621         {
23622                 char *version;
23623                 int major, minor, patch;
23624
23625                 version = db_version( &major, &minor, &patch );
23626
23627                 if( major != DB_VERSION_MAJOR ||
23628                         minor < DB_VERSION_MINOR )
23629                 {
23630                         printf("Berkeley DB version mismatch\n"
23631                                 "\texpected: %s\n\tgot: %s\n",
23632                                 DB_VERSION_STRING, version);
23633                         return 1;
23634                 }
23635         }
23636 #endif
23637
23638 #if DB_VERSION_MAJOR > 2
23639         db_env_create( NULL, 0 );
23640 #elif DB_VERSION_MAJOR > 1
23641         db_appexit( NULL );
23642 #else
23643         (void) dbopen( NULL, 0, 0, 0, NULL);
23644 #endif
23645
23646   ;
23647   return 0;
23648 }
23649 _ACEOF
23650 rm -f conftest.$ac_objext conftest$ac_exeext
23651 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23652   (eval $ac_link) 2>&5
23653   ac_status=$?
23654   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23655   (exit $ac_status); } &&
23656          { ac_try='test -s conftest$ac_exeext'
23657   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23658   (eval $ac_try) 2>&5
23659   ac_status=$?
23660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23661   (exit $ac_status); }; }; then
23662   ol_cv_db_db4=yes
23663 else
23664   echo "$as_me: failed program was:" >&5
23665 sed 's/^/| /' conftest.$ac_ext >&5
23666
23667 ol_cv_db_db4=no
23668 fi
23669 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23670
23671         LIBS="$ol_LIBS"
23672
23673 fi
23674 echo "$as_me:$LINENO: result: $ol_cv_db_db4" >&5
23675 echo "${ECHO_T}$ol_cv_db_db4" >&6
23676
23677         if test $ol_cv_db_db4 = yes ; then
23678                 ol_cv_lib_db=-ldb4
23679         fi
23680 fi
23681
23682 if test $ol_cv_lib_db = no ; then
23683         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb)" >&5
23684 echo $ECHO_N "checking for Berkeley DB link (-ldb)... $ECHO_C" >&6
23685 if test "${ol_cv_db_db+set}" = set; then
23686   echo $ECHO_N "(cached) $ECHO_C" >&6
23687 else
23688
23689         ol_DB_LIB=-ldb
23690         ol_LIBS=$LIBS
23691         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
23692
23693         cat >conftest.$ac_ext <<_ACEOF
23694 #line $LINENO "configure"
23695 /* confdefs.h.  */
23696 _ACEOF
23697 cat confdefs.h >>conftest.$ac_ext
23698 cat >>conftest.$ac_ext <<_ACEOF
23699 /* end confdefs.h.  */
23700
23701 #ifdef HAVE_DB_185_H
23702 # include <db_185.h>
23703 #else
23704 # include <db.h>
23705 #endif
23706
23707 #ifndef DB_VERSION_MAJOR
23708 # define DB_VERSION_MAJOR 1
23709 #endif
23710
23711 #ifndef NULL
23712 #define NULL ((void*)0)
23713 #endif
23714
23715 int
23716 main ()
23717 {
23718
23719 #if DB_VERSION_MAJOR > 1
23720         {
23721                 char *version;
23722                 int major, minor, patch;
23723
23724                 version = db_version( &major, &minor, &patch );
23725
23726                 if( major != DB_VERSION_MAJOR ||
23727                         minor < DB_VERSION_MINOR )
23728                 {
23729                         printf("Berkeley DB version mismatch\n"
23730                                 "\texpected: %s\n\tgot: %s\n",
23731                                 DB_VERSION_STRING, version);
23732                         return 1;
23733                 }
23734         }
23735 #endif
23736
23737 #if DB_VERSION_MAJOR > 2
23738         db_env_create( NULL, 0 );
23739 #elif DB_VERSION_MAJOR > 1
23740         db_appexit( NULL );
23741 #else
23742         (void) dbopen( NULL, 0, 0, 0, NULL);
23743 #endif
23744
23745   ;
23746   return 0;
23747 }
23748 _ACEOF
23749 rm -f conftest.$ac_objext conftest$ac_exeext
23750 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23751   (eval $ac_link) 2>&5
23752   ac_status=$?
23753   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23754   (exit $ac_status); } &&
23755          { ac_try='test -s conftest$ac_exeext'
23756   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23757   (eval $ac_try) 2>&5
23758   ac_status=$?
23759   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23760   (exit $ac_status); }; }; then
23761   ol_cv_db_db=yes
23762 else
23763   echo "$as_me: failed program was:" >&5
23764 sed 's/^/| /' conftest.$ac_ext >&5
23765
23766 ol_cv_db_db=no
23767 fi
23768 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23769
23770         LIBS="$ol_LIBS"
23771
23772 fi
23773 echo "$as_me:$LINENO: result: $ol_cv_db_db" >&5
23774 echo "${ECHO_T}$ol_cv_db_db" >&6
23775
23776         if test $ol_cv_db_db = yes ; then
23777                 ol_cv_lib_db=-ldb
23778         fi
23779 fi
23780
23781 if test $ol_cv_lib_db = no ; then
23782         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb3)" >&5
23783 echo $ECHO_N "checking for Berkeley DB link (-ldb3)... $ECHO_C" >&6
23784 if test "${ol_cv_db_db3+set}" = set; then
23785   echo $ECHO_N "(cached) $ECHO_C" >&6
23786 else
23787
23788         ol_DB_LIB=-ldb3
23789         ol_LIBS=$LIBS
23790         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
23791
23792         cat >conftest.$ac_ext <<_ACEOF
23793 #line $LINENO "configure"
23794 /* confdefs.h.  */
23795 _ACEOF
23796 cat confdefs.h >>conftest.$ac_ext
23797 cat >>conftest.$ac_ext <<_ACEOF
23798 /* end confdefs.h.  */
23799
23800 #ifdef HAVE_DB_185_H
23801 # include <db_185.h>
23802 #else
23803 # include <db.h>
23804 #endif
23805
23806 #ifndef DB_VERSION_MAJOR
23807 # define DB_VERSION_MAJOR 1
23808 #endif
23809
23810 #ifndef NULL
23811 #define NULL ((void*)0)
23812 #endif
23813
23814 int
23815 main ()
23816 {
23817
23818 #if DB_VERSION_MAJOR > 1
23819         {
23820                 char *version;
23821                 int major, minor, patch;
23822
23823                 version = db_version( &major, &minor, &patch );
23824
23825                 if( major != DB_VERSION_MAJOR ||
23826                         minor < DB_VERSION_MINOR )
23827                 {
23828                         printf("Berkeley DB version mismatch\n"
23829                                 "\texpected: %s\n\tgot: %s\n",
23830                                 DB_VERSION_STRING, version);
23831                         return 1;
23832                 }
23833         }
23834 #endif
23835
23836 #if DB_VERSION_MAJOR > 2
23837         db_env_create( NULL, 0 );
23838 #elif DB_VERSION_MAJOR > 1
23839         db_appexit( NULL );
23840 #else
23841         (void) dbopen( NULL, 0, 0, 0, NULL);
23842 #endif
23843
23844   ;
23845   return 0;
23846 }
23847 _ACEOF
23848 rm -f conftest.$ac_objext conftest$ac_exeext
23849 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23850   (eval $ac_link) 2>&5
23851   ac_status=$?
23852   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23853   (exit $ac_status); } &&
23854          { ac_try='test -s conftest$ac_exeext'
23855   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23856   (eval $ac_try) 2>&5
23857   ac_status=$?
23858   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23859   (exit $ac_status); }; }; then
23860   ol_cv_db_db3=yes
23861 else
23862   echo "$as_me: failed program was:" >&5
23863 sed 's/^/| /' conftest.$ac_ext >&5
23864
23865 ol_cv_db_db3=no
23866 fi
23867 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23868
23869         LIBS="$ol_LIBS"
23870
23871 fi
23872 echo "$as_me:$LINENO: result: $ol_cv_db_db3" >&5
23873 echo "${ECHO_T}$ol_cv_db_db3" >&6
23874
23875         if test $ol_cv_db_db3 = yes ; then
23876                 ol_cv_lib_db=-ldb3
23877         fi
23878 fi
23879
23880 if test $ol_cv_lib_db = no ; then
23881         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-3)" >&5
23882 echo $ECHO_N "checking for Berkeley DB link (-ldb-3)... $ECHO_C" >&6
23883 if test "${ol_cv_db_db_3+set}" = set; then
23884   echo $ECHO_N "(cached) $ECHO_C" >&6
23885 else
23886
23887         ol_DB_LIB=-ldb-3
23888         ol_LIBS=$LIBS
23889         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
23890
23891         cat >conftest.$ac_ext <<_ACEOF
23892 #line $LINENO "configure"
23893 /* confdefs.h.  */
23894 _ACEOF
23895 cat confdefs.h >>conftest.$ac_ext
23896 cat >>conftest.$ac_ext <<_ACEOF
23897 /* end confdefs.h.  */
23898
23899 #ifdef HAVE_DB_185_H
23900 # include <db_185.h>
23901 #else
23902 # include <db.h>
23903 #endif
23904
23905 #ifndef DB_VERSION_MAJOR
23906 # define DB_VERSION_MAJOR 1
23907 #endif
23908
23909 #ifndef NULL
23910 #define NULL ((void*)0)
23911 #endif
23912
23913 int
23914 main ()
23915 {
23916
23917 #if DB_VERSION_MAJOR > 1
23918         {
23919                 char *version;
23920                 int major, minor, patch;
23921
23922                 version = db_version( &major, &minor, &patch );
23923
23924                 if( major != DB_VERSION_MAJOR ||
23925                         minor < DB_VERSION_MINOR )
23926                 {
23927                         printf("Berkeley DB version mismatch\n"
23928                                 "\texpected: %s\n\tgot: %s\n",
23929                                 DB_VERSION_STRING, version);
23930                         return 1;
23931                 }
23932         }
23933 #endif
23934
23935 #if DB_VERSION_MAJOR > 2
23936         db_env_create( NULL, 0 );
23937 #elif DB_VERSION_MAJOR > 1
23938         db_appexit( NULL );
23939 #else
23940         (void) dbopen( NULL, 0, 0, 0, NULL);
23941 #endif
23942
23943   ;
23944   return 0;
23945 }
23946 _ACEOF
23947 rm -f conftest.$ac_objext conftest$ac_exeext
23948 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
23949   (eval $ac_link) 2>&5
23950   ac_status=$?
23951   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23952   (exit $ac_status); } &&
23953          { ac_try='test -s conftest$ac_exeext'
23954   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23955   (eval $ac_try) 2>&5
23956   ac_status=$?
23957   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23958   (exit $ac_status); }; }; then
23959   ol_cv_db_db_3=yes
23960 else
23961   echo "$as_me: failed program was:" >&5
23962 sed 's/^/| /' conftest.$ac_ext >&5
23963
23964 ol_cv_db_db_3=no
23965 fi
23966 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
23967
23968         LIBS="$ol_LIBS"
23969
23970 fi
23971 echo "$as_me:$LINENO: result: $ol_cv_db_db_3" >&5
23972 echo "${ECHO_T}$ol_cv_db_db_3" >&6
23973
23974         if test $ol_cv_db_db_3 = yes ; then
23975                 ol_cv_lib_db=-ldb-3
23976         fi
23977 fi
23978
23979 if test $ol_cv_lib_db = no ; then
23980         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb2)" >&5
23981 echo $ECHO_N "checking for Berkeley DB link (-ldb2)... $ECHO_C" >&6
23982 if test "${ol_cv_db_db2+set}" = set; then
23983   echo $ECHO_N "(cached) $ECHO_C" >&6
23984 else
23985
23986         ol_DB_LIB=-ldb2
23987         ol_LIBS=$LIBS
23988         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
23989
23990         cat >conftest.$ac_ext <<_ACEOF
23991 #line $LINENO "configure"
23992 /* confdefs.h.  */
23993 _ACEOF
23994 cat confdefs.h >>conftest.$ac_ext
23995 cat >>conftest.$ac_ext <<_ACEOF
23996 /* end confdefs.h.  */
23997
23998 #ifdef HAVE_DB_185_H
23999 # include <db_185.h>
24000 #else
24001 # include <db.h>
24002 #endif
24003
24004 #ifndef DB_VERSION_MAJOR
24005 # define DB_VERSION_MAJOR 1
24006 #endif
24007
24008 #ifndef NULL
24009 #define NULL ((void*)0)
24010 #endif
24011
24012 int
24013 main ()
24014 {
24015
24016 #if DB_VERSION_MAJOR > 1
24017         {
24018                 char *version;
24019                 int major, minor, patch;
24020
24021                 version = db_version( &major, &minor, &patch );
24022
24023                 if( major != DB_VERSION_MAJOR ||
24024                         minor < DB_VERSION_MINOR )
24025                 {
24026                         printf("Berkeley DB version mismatch\n"
24027                                 "\texpected: %s\n\tgot: %s\n",
24028                                 DB_VERSION_STRING, version);
24029                         return 1;
24030                 }
24031         }
24032 #endif
24033
24034 #if DB_VERSION_MAJOR > 2
24035         db_env_create( NULL, 0 );
24036 #elif DB_VERSION_MAJOR > 1
24037         db_appexit( NULL );
24038 #else
24039         (void) dbopen( NULL, 0, 0, 0, NULL);
24040 #endif
24041
24042   ;
24043   return 0;
24044 }
24045 _ACEOF
24046 rm -f conftest.$ac_objext conftest$ac_exeext
24047 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24048   (eval $ac_link) 2>&5
24049   ac_status=$?
24050   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24051   (exit $ac_status); } &&
24052          { ac_try='test -s conftest$ac_exeext'
24053   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24054   (eval $ac_try) 2>&5
24055   ac_status=$?
24056   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24057   (exit $ac_status); }; }; then
24058   ol_cv_db_db2=yes
24059 else
24060   echo "$as_me: failed program was:" >&5
24061 sed 's/^/| /' conftest.$ac_ext >&5
24062
24063 ol_cv_db_db2=no
24064 fi
24065 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
24066
24067         LIBS="$ol_LIBS"
24068
24069 fi
24070 echo "$as_me:$LINENO: result: $ol_cv_db_db2" >&5
24071 echo "${ECHO_T}$ol_cv_db_db2" >&6
24072
24073         if test $ol_cv_db_db2 = yes ; then
24074                 ol_cv_lib_db=-ldb2
24075         fi
24076 fi
24077
24078 if test $ol_cv_lib_db = no ; then
24079         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-2)" >&5
24080 echo $ECHO_N "checking for Berkeley DB link (-ldb-2)... $ECHO_C" >&6
24081 if test "${ol_cv_db_db_2+set}" = set; then
24082   echo $ECHO_N "(cached) $ECHO_C" >&6
24083 else
24084
24085         ol_DB_LIB=-ldb-2
24086         ol_LIBS=$LIBS
24087         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24088
24089         cat >conftest.$ac_ext <<_ACEOF
24090 #line $LINENO "configure"
24091 /* confdefs.h.  */
24092 _ACEOF
24093 cat confdefs.h >>conftest.$ac_ext
24094 cat >>conftest.$ac_ext <<_ACEOF
24095 /* end confdefs.h.  */
24096
24097 #ifdef HAVE_DB_185_H
24098 # include <db_185.h>
24099 #else
24100 # include <db.h>
24101 #endif
24102
24103 #ifndef DB_VERSION_MAJOR
24104 # define DB_VERSION_MAJOR 1
24105 #endif
24106
24107 #ifndef NULL
24108 #define NULL ((void*)0)
24109 #endif
24110
24111 int
24112 main ()
24113 {
24114
24115 #if DB_VERSION_MAJOR > 1
24116         {
24117                 char *version;
24118                 int major, minor, patch;
24119
24120                 version = db_version( &major, &minor, &patch );
24121
24122                 if( major != DB_VERSION_MAJOR ||
24123                         minor < DB_VERSION_MINOR )
24124                 {
24125                         printf("Berkeley DB version mismatch\n"
24126                                 "\texpected: %s\n\tgot: %s\n",
24127                                 DB_VERSION_STRING, version);
24128                         return 1;
24129                 }
24130         }
24131 #endif
24132
24133 #if DB_VERSION_MAJOR > 2
24134         db_env_create( NULL, 0 );
24135 #elif DB_VERSION_MAJOR > 1
24136         db_appexit( NULL );
24137 #else
24138         (void) dbopen( NULL, 0, 0, 0, NULL);
24139 #endif
24140
24141   ;
24142   return 0;
24143 }
24144 _ACEOF
24145 rm -f conftest.$ac_objext conftest$ac_exeext
24146 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24147   (eval $ac_link) 2>&5
24148   ac_status=$?
24149   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24150   (exit $ac_status); } &&
24151          { ac_try='test -s conftest$ac_exeext'
24152   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24153   (eval $ac_try) 2>&5
24154   ac_status=$?
24155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24156   (exit $ac_status); }; }; then
24157   ol_cv_db_db_2=yes
24158 else
24159   echo "$as_me: failed program was:" >&5
24160 sed 's/^/| /' conftest.$ac_ext >&5
24161
24162 ol_cv_db_db_2=no
24163 fi
24164 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
24165
24166         LIBS="$ol_LIBS"
24167
24168 fi
24169 echo "$as_me:$LINENO: result: $ol_cv_db_db_2" >&5
24170 echo "${ECHO_T}$ol_cv_db_db_2" >&6
24171
24172         if test $ol_cv_db_db_2 = yes ; then
24173                 ol_cv_lib_db=-ldb-2
24174         fi
24175 fi
24176
24177 if test $ol_cv_lib_db = no ; then
24178         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb1)" >&5
24179 echo $ECHO_N "checking for Berkeley DB link (-ldb1)... $ECHO_C" >&6
24180 if test "${ol_cv_db_db1+set}" = set; then
24181   echo $ECHO_N "(cached) $ECHO_C" >&6
24182 else
24183
24184         ol_DB_LIB=-ldb1
24185         ol_LIBS=$LIBS
24186         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24187
24188         cat >conftest.$ac_ext <<_ACEOF
24189 #line $LINENO "configure"
24190 /* confdefs.h.  */
24191 _ACEOF
24192 cat confdefs.h >>conftest.$ac_ext
24193 cat >>conftest.$ac_ext <<_ACEOF
24194 /* end confdefs.h.  */
24195
24196 #ifdef HAVE_DB_185_H
24197 # include <db_185.h>
24198 #else
24199 # include <db.h>
24200 #endif
24201
24202 #ifndef DB_VERSION_MAJOR
24203 # define DB_VERSION_MAJOR 1
24204 #endif
24205
24206 #ifndef NULL
24207 #define NULL ((void*)0)
24208 #endif
24209
24210 int
24211 main ()
24212 {
24213
24214 #if DB_VERSION_MAJOR > 1
24215         {
24216                 char *version;
24217                 int major, minor, patch;
24218
24219                 version = db_version( &major, &minor, &patch );
24220
24221                 if( major != DB_VERSION_MAJOR ||
24222                         minor < DB_VERSION_MINOR )
24223                 {
24224                         printf("Berkeley DB version mismatch\n"
24225                                 "\texpected: %s\n\tgot: %s\n",
24226                                 DB_VERSION_STRING, version);
24227                         return 1;
24228                 }
24229         }
24230 #endif
24231
24232 #if DB_VERSION_MAJOR > 2
24233         db_env_create( NULL, 0 );
24234 #elif DB_VERSION_MAJOR > 1
24235         db_appexit( NULL );
24236 #else
24237         (void) dbopen( NULL, 0, 0, 0, NULL);
24238 #endif
24239
24240   ;
24241   return 0;
24242 }
24243 _ACEOF
24244 rm -f conftest.$ac_objext conftest$ac_exeext
24245 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24246   (eval $ac_link) 2>&5
24247   ac_status=$?
24248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24249   (exit $ac_status); } &&
24250          { ac_try='test -s conftest$ac_exeext'
24251   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24252   (eval $ac_try) 2>&5
24253   ac_status=$?
24254   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24255   (exit $ac_status); }; }; then
24256   ol_cv_db_db1=yes
24257 else
24258   echo "$as_me: failed program was:" >&5
24259 sed 's/^/| /' conftest.$ac_ext >&5
24260
24261 ol_cv_db_db1=no
24262 fi
24263 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
24264
24265         LIBS="$ol_LIBS"
24266
24267 fi
24268 echo "$as_me:$LINENO: result: $ol_cv_db_db1" >&5
24269 echo "${ECHO_T}$ol_cv_db_db1" >&6
24270
24271         if test $ol_cv_db_db1 = yes ; then
24272                 ol_cv_lib_db=-ldb1
24273         fi
24274 fi
24275
24276 if test $ol_cv_lib_db = no ; then
24277         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-1)" >&5
24278 echo $ECHO_N "checking for Berkeley DB link (-ldb-1)... $ECHO_C" >&6
24279 if test "${ol_cv_db_db_1+set}" = set; then
24280   echo $ECHO_N "(cached) $ECHO_C" >&6
24281 else
24282
24283         ol_DB_LIB=-ldb-1
24284         ol_LIBS=$LIBS
24285         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24286
24287         cat >conftest.$ac_ext <<_ACEOF
24288 #line $LINENO "configure"
24289 /* confdefs.h.  */
24290 _ACEOF
24291 cat confdefs.h >>conftest.$ac_ext
24292 cat >>conftest.$ac_ext <<_ACEOF
24293 /* end confdefs.h.  */
24294
24295 #ifdef HAVE_DB_185_H
24296 # include <db_185.h>
24297 #else
24298 # include <db.h>
24299 #endif
24300
24301 #ifndef DB_VERSION_MAJOR
24302 # define DB_VERSION_MAJOR 1
24303 #endif
24304
24305 #ifndef NULL
24306 #define NULL ((void*)0)
24307 #endif
24308
24309 int
24310 main ()
24311 {
24312
24313 #if DB_VERSION_MAJOR > 1
24314         {
24315                 char *version;
24316                 int major, minor, patch;
24317
24318                 version = db_version( &major, &minor, &patch );
24319
24320                 if( major != DB_VERSION_MAJOR ||
24321                         minor < DB_VERSION_MINOR )
24322                 {
24323                         printf("Berkeley DB version mismatch\n"
24324                                 "\texpected: %s\n\tgot: %s\n",
24325                                 DB_VERSION_STRING, version);
24326                         return 1;
24327                 }
24328         }
24329 #endif
24330
24331 #if DB_VERSION_MAJOR > 2
24332         db_env_create( NULL, 0 );
24333 #elif DB_VERSION_MAJOR > 1
24334         db_appexit( NULL );
24335 #else
24336         (void) dbopen( NULL, 0, 0, 0, NULL);
24337 #endif
24338
24339   ;
24340   return 0;
24341 }
24342 _ACEOF
24343 rm -f conftest.$ac_objext conftest$ac_exeext
24344 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24345   (eval $ac_link) 2>&5
24346   ac_status=$?
24347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24348   (exit $ac_status); } &&
24349          { ac_try='test -s conftest$ac_exeext'
24350   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24351   (eval $ac_try) 2>&5
24352   ac_status=$?
24353   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24354   (exit $ac_status); }; }; then
24355   ol_cv_db_db_1=yes
24356 else
24357   echo "$as_me: failed program was:" >&5
24358 sed 's/^/| /' conftest.$ac_ext >&5
24359
24360 ol_cv_db_db_1=no
24361 fi
24362 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
24363
24364         LIBS="$ol_LIBS"
24365
24366 fi
24367 echo "$as_me:$LINENO: result: $ol_cv_db_db_1" >&5
24368 echo "${ECHO_T}$ol_cv_db_db_1" >&6
24369
24370         if test $ol_cv_db_db_1 = yes ; then
24371                 ol_cv_lib_db=-ldb-1
24372         fi
24373 fi
24374
24375
24376                 if test "$ol_cv_lib_db" != no ; then
24377                         ol_cv_berkeley_db=yes
24378                 fi
24379         fi
24380 fi
24381
24382         else
24383                 ol_cv_berkeley_db=no
24384
24385 for ac_header in db.h
24386 do
24387 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
24388 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24389   echo "$as_me:$LINENO: checking for $ac_header" >&5
24390 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24391 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24392   echo $ECHO_N "(cached) $ECHO_C" >&6
24393 fi
24394 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24395 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24396 else
24397   # Is the header compilable?
24398 echo "$as_me:$LINENO: checking $ac_header usability" >&5
24399 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
24400 cat >conftest.$ac_ext <<_ACEOF
24401 #line $LINENO "configure"
24402 /* confdefs.h.  */
24403 _ACEOF
24404 cat confdefs.h >>conftest.$ac_ext
24405 cat >>conftest.$ac_ext <<_ACEOF
24406 /* end confdefs.h.  */
24407 $ac_includes_default
24408 #include <$ac_header>
24409 _ACEOF
24410 rm -f conftest.$ac_objext
24411 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
24412   (eval $ac_compile) 2>&5
24413   ac_status=$?
24414   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24415   (exit $ac_status); } &&
24416          { ac_try='test -s conftest.$ac_objext'
24417   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24418   (eval $ac_try) 2>&5
24419   ac_status=$?
24420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24421   (exit $ac_status); }; }; then
24422   ac_header_compiler=yes
24423 else
24424   echo "$as_me: failed program was:" >&5
24425 sed 's/^/| /' conftest.$ac_ext >&5
24426
24427 ac_header_compiler=no
24428 fi
24429 rm -f conftest.$ac_objext conftest.$ac_ext
24430 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
24431 echo "${ECHO_T}$ac_header_compiler" >&6
24432
24433 # Is the header present?
24434 echo "$as_me:$LINENO: checking $ac_header presence" >&5
24435 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
24436 cat >conftest.$ac_ext <<_ACEOF
24437 #line $LINENO "configure"
24438 /* confdefs.h.  */
24439 _ACEOF
24440 cat confdefs.h >>conftest.$ac_ext
24441 cat >>conftest.$ac_ext <<_ACEOF
24442 /* end confdefs.h.  */
24443 #include <$ac_header>
24444 _ACEOF
24445 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
24446   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
24447   ac_status=$?
24448   grep -v '^ *+' conftest.er1 >conftest.err
24449   rm -f conftest.er1
24450   cat conftest.err >&5
24451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24452   (exit $ac_status); } >/dev/null; then
24453   if test -s conftest.err; then
24454     ac_cpp_err=$ac_c_preproc_warn_flag
24455   else
24456     ac_cpp_err=
24457   fi
24458 else
24459   ac_cpp_err=yes
24460 fi
24461 if test -z "$ac_cpp_err"; then
24462   ac_header_preproc=yes
24463 else
24464   echo "$as_me: failed program was:" >&5
24465 sed 's/^/| /' conftest.$ac_ext >&5
24466
24467   ac_header_preproc=no
24468 fi
24469 rm -f conftest.err conftest.$ac_ext
24470 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
24471 echo "${ECHO_T}$ac_header_preproc" >&6
24472
24473 # So?  What about this header?
24474 case $ac_header_compiler:$ac_header_preproc in
24475   yes:no )
24476     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
24477 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
24478     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
24479 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
24480     (
24481       cat <<\_ASBOX
24482 ## ------------------------------------ ##
24483 ## Report this to bug-autoconf@gnu.org. ##
24484 ## ------------------------------------ ##
24485 _ASBOX
24486     ) |
24487       sed "s/^/$as_me: WARNING:     /" >&2
24488     ;;
24489   no:yes )
24490     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
24491 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
24492     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
24493 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
24494     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
24495 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
24496     (
24497       cat <<\_ASBOX
24498 ## ------------------------------------ ##
24499 ## Report this to bug-autoconf@gnu.org. ##
24500 ## ------------------------------------ ##
24501 _ASBOX
24502     ) |
24503       sed "s/^/$as_me: WARNING:     /" >&2
24504     ;;
24505 esac
24506 echo "$as_me:$LINENO: checking for $ac_header" >&5
24507 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
24508 if eval "test \"\${$as_ac_Header+set}\" = set"; then
24509   echo $ECHO_N "(cached) $ECHO_C" >&6
24510 else
24511   eval "$as_ac_Header=$ac_header_preproc"
24512 fi
24513 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
24514 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
24515
24516 fi
24517 if test `eval echo '${'$as_ac_Header'}'` = yes; then
24518   cat >>confdefs.h <<_ACEOF
24519 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
24520 _ACEOF
24521
24522 fi
24523
24524 done
24525
24526 if test $ac_cv_header_db_h = yes; then
24527         ol_cv_lib_db=no
24528 if test $ol_cv_lib_db = no ; then
24529         echo "$as_me:$LINENO: checking for Berkeley DB link (default)" >&5
24530 echo $ECHO_N "checking for Berkeley DB link (default)... $ECHO_C" >&6
24531 if test "${ol_cv_db_none+set}" = set; then
24532   echo $ECHO_N "(cached) $ECHO_C" >&6
24533 else
24534
24535         ol_DB_LIB=
24536         ol_LIBS=$LIBS
24537         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24538
24539         cat >conftest.$ac_ext <<_ACEOF
24540 #line $LINENO "configure"
24541 /* confdefs.h.  */
24542 _ACEOF
24543 cat confdefs.h >>conftest.$ac_ext
24544 cat >>conftest.$ac_ext <<_ACEOF
24545 /* end confdefs.h.  */
24546
24547 #ifdef HAVE_DB_185_H
24548 # include <db_185.h>
24549 #else
24550 # include <db.h>
24551 #endif
24552
24553 #ifndef DB_VERSION_MAJOR
24554 # define DB_VERSION_MAJOR 1
24555 #endif
24556
24557 #ifndef NULL
24558 #define NULL ((void*)0)
24559 #endif
24560
24561 int
24562 main ()
24563 {
24564
24565 #if DB_VERSION_MAJOR > 1
24566         {
24567                 char *version;
24568                 int major, minor, patch;
24569
24570                 version = db_version( &major, &minor, &patch );
24571
24572                 if( major != DB_VERSION_MAJOR ||
24573                         minor < DB_VERSION_MINOR )
24574                 {
24575                         printf("Berkeley DB version mismatch\n"
24576                                 "\texpected: %s\n\tgot: %s\n",
24577                                 DB_VERSION_STRING, version);
24578                         return 1;
24579                 }
24580         }
24581 #endif
24582
24583 #if DB_VERSION_MAJOR > 2
24584         db_env_create( NULL, 0 );
24585 #elif DB_VERSION_MAJOR > 1
24586         db_appexit( NULL );
24587 #else
24588         (void) dbopen( NULL, 0, 0, 0, NULL);
24589 #endif
24590
24591   ;
24592   return 0;
24593 }
24594 _ACEOF
24595 rm -f conftest.$ac_objext conftest$ac_exeext
24596 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24597   (eval $ac_link) 2>&5
24598   ac_status=$?
24599   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24600   (exit $ac_status); } &&
24601          { ac_try='test -s conftest$ac_exeext'
24602   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24603   (eval $ac_try) 2>&5
24604   ac_status=$?
24605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24606   (exit $ac_status); }; }; then
24607   ol_cv_db_none=yes
24608 else
24609   echo "$as_me: failed program was:" >&5
24610 sed 's/^/| /' conftest.$ac_ext >&5
24611
24612 ol_cv_db_none=no
24613 fi
24614 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
24615
24616         LIBS="$ol_LIBS"
24617
24618 fi
24619 echo "$as_me:$LINENO: result: $ol_cv_db_none" >&5
24620 echo "${ECHO_T}$ol_cv_db_none" >&6
24621
24622         if test $ol_cv_db_none = yes ; then
24623                 ol_cv_lib_db=yes
24624         fi
24625 fi
24626
24627 if test $ol_cv_lib_db = no ; then
24628         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb41)" >&5
24629 echo $ECHO_N "checking for Berkeley DB link (-ldb41)... $ECHO_C" >&6
24630 if test "${ol_cv_db_db41+set}" = set; then
24631   echo $ECHO_N "(cached) $ECHO_C" >&6
24632 else
24633
24634         ol_DB_LIB=-ldb41
24635         ol_LIBS=$LIBS
24636         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24637
24638         cat >conftest.$ac_ext <<_ACEOF
24639 #line $LINENO "configure"
24640 /* confdefs.h.  */
24641 _ACEOF
24642 cat confdefs.h >>conftest.$ac_ext
24643 cat >>conftest.$ac_ext <<_ACEOF
24644 /* end confdefs.h.  */
24645
24646 #ifdef HAVE_DB_185_H
24647 # include <db_185.h>
24648 #else
24649 # include <db.h>
24650 #endif
24651
24652 #ifndef DB_VERSION_MAJOR
24653 # define DB_VERSION_MAJOR 1
24654 #endif
24655
24656 #ifndef NULL
24657 #define NULL ((void*)0)
24658 #endif
24659
24660 int
24661 main ()
24662 {
24663
24664 #if DB_VERSION_MAJOR > 1
24665         {
24666                 char *version;
24667                 int major, minor, patch;
24668
24669                 version = db_version( &major, &minor, &patch );
24670
24671                 if( major != DB_VERSION_MAJOR ||
24672                         minor < DB_VERSION_MINOR )
24673                 {
24674                         printf("Berkeley DB version mismatch\n"
24675                                 "\texpected: %s\n\tgot: %s\n",
24676                                 DB_VERSION_STRING, version);
24677                         return 1;
24678                 }
24679         }
24680 #endif
24681
24682 #if DB_VERSION_MAJOR > 2
24683         db_env_create( NULL, 0 );
24684 #elif DB_VERSION_MAJOR > 1
24685         db_appexit( NULL );
24686 #else
24687         (void) dbopen( NULL, 0, 0, 0, NULL);
24688 #endif
24689
24690   ;
24691   return 0;
24692 }
24693 _ACEOF
24694 rm -f conftest.$ac_objext conftest$ac_exeext
24695 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24696   (eval $ac_link) 2>&5
24697   ac_status=$?
24698   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24699   (exit $ac_status); } &&
24700          { ac_try='test -s conftest$ac_exeext'
24701   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24702   (eval $ac_try) 2>&5
24703   ac_status=$?
24704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24705   (exit $ac_status); }; }; then
24706   ol_cv_db_db41=yes
24707 else
24708   echo "$as_me: failed program was:" >&5
24709 sed 's/^/| /' conftest.$ac_ext >&5
24710
24711 ol_cv_db_db41=no
24712 fi
24713 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
24714
24715         LIBS="$ol_LIBS"
24716
24717 fi
24718 echo "$as_me:$LINENO: result: $ol_cv_db_db41" >&5
24719 echo "${ECHO_T}$ol_cv_db_db41" >&6
24720
24721         if test $ol_cv_db_db41 = yes ; then
24722                 ol_cv_lib_db=-ldb41
24723         fi
24724 fi
24725
24726 if test $ol_cv_lib_db = no ; then
24727         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-41)" >&5
24728 echo $ECHO_N "checking for Berkeley DB link (-ldb-41)... $ECHO_C" >&6
24729 if test "${ol_cv_db_db_41+set}" = set; then
24730   echo $ECHO_N "(cached) $ECHO_C" >&6
24731 else
24732
24733         ol_DB_LIB=-ldb-41
24734         ol_LIBS=$LIBS
24735         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24736
24737         cat >conftest.$ac_ext <<_ACEOF
24738 #line $LINENO "configure"
24739 /* confdefs.h.  */
24740 _ACEOF
24741 cat confdefs.h >>conftest.$ac_ext
24742 cat >>conftest.$ac_ext <<_ACEOF
24743 /* end confdefs.h.  */
24744
24745 #ifdef HAVE_DB_185_H
24746 # include <db_185.h>
24747 #else
24748 # include <db.h>
24749 #endif
24750
24751 #ifndef DB_VERSION_MAJOR
24752 # define DB_VERSION_MAJOR 1
24753 #endif
24754
24755 #ifndef NULL
24756 #define NULL ((void*)0)
24757 #endif
24758
24759 int
24760 main ()
24761 {
24762
24763 #if DB_VERSION_MAJOR > 1
24764         {
24765                 char *version;
24766                 int major, minor, patch;
24767
24768                 version = db_version( &major, &minor, &patch );
24769
24770                 if( major != DB_VERSION_MAJOR ||
24771                         minor < DB_VERSION_MINOR )
24772                 {
24773                         printf("Berkeley DB version mismatch\n"
24774                                 "\texpected: %s\n\tgot: %s\n",
24775                                 DB_VERSION_STRING, version);
24776                         return 1;
24777                 }
24778         }
24779 #endif
24780
24781 #if DB_VERSION_MAJOR > 2
24782         db_env_create( NULL, 0 );
24783 #elif DB_VERSION_MAJOR > 1
24784         db_appexit( NULL );
24785 #else
24786         (void) dbopen( NULL, 0, 0, 0, NULL);
24787 #endif
24788
24789   ;
24790   return 0;
24791 }
24792 _ACEOF
24793 rm -f conftest.$ac_objext conftest$ac_exeext
24794 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24795   (eval $ac_link) 2>&5
24796   ac_status=$?
24797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24798   (exit $ac_status); } &&
24799          { ac_try='test -s conftest$ac_exeext'
24800   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24801   (eval $ac_try) 2>&5
24802   ac_status=$?
24803   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24804   (exit $ac_status); }; }; then
24805   ol_cv_db_db_41=yes
24806 else
24807   echo "$as_me: failed program was:" >&5
24808 sed 's/^/| /' conftest.$ac_ext >&5
24809
24810 ol_cv_db_db_41=no
24811 fi
24812 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
24813
24814         LIBS="$ol_LIBS"
24815
24816 fi
24817 echo "$as_me:$LINENO: result: $ol_cv_db_db_41" >&5
24818 echo "${ECHO_T}$ol_cv_db_db_41" >&6
24819
24820         if test $ol_cv_db_db_41 = yes ; then
24821                 ol_cv_lib_db=-ldb-41
24822         fi
24823 fi
24824
24825 if test $ol_cv_lib_db = no ; then
24826         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4.1)" >&5
24827 echo $ECHO_N "checking for Berkeley DB link (-ldb-4.1)... $ECHO_C" >&6
24828 if test "${ol_cv_db_db_4_dot_1+set}" = set; then
24829   echo $ECHO_N "(cached) $ECHO_C" >&6
24830 else
24831
24832         ol_DB_LIB=-ldb-4.1
24833         ol_LIBS=$LIBS
24834         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24835
24836         cat >conftest.$ac_ext <<_ACEOF
24837 #line $LINENO "configure"
24838 /* confdefs.h.  */
24839 _ACEOF
24840 cat confdefs.h >>conftest.$ac_ext
24841 cat >>conftest.$ac_ext <<_ACEOF
24842 /* end confdefs.h.  */
24843
24844 #ifdef HAVE_DB_185_H
24845 # include <db_185.h>
24846 #else
24847 # include <db.h>
24848 #endif
24849
24850 #ifndef DB_VERSION_MAJOR
24851 # define DB_VERSION_MAJOR 1
24852 #endif
24853
24854 #ifndef NULL
24855 #define NULL ((void*)0)
24856 #endif
24857
24858 int
24859 main ()
24860 {
24861
24862 #if DB_VERSION_MAJOR > 1
24863         {
24864                 char *version;
24865                 int major, minor, patch;
24866
24867                 version = db_version( &major, &minor, &patch );
24868
24869                 if( major != DB_VERSION_MAJOR ||
24870                         minor < DB_VERSION_MINOR )
24871                 {
24872                         printf("Berkeley DB version mismatch\n"
24873                                 "\texpected: %s\n\tgot: %s\n",
24874                                 DB_VERSION_STRING, version);
24875                         return 1;
24876                 }
24877         }
24878 #endif
24879
24880 #if DB_VERSION_MAJOR > 2
24881         db_env_create( NULL, 0 );
24882 #elif DB_VERSION_MAJOR > 1
24883         db_appexit( NULL );
24884 #else
24885         (void) dbopen( NULL, 0, 0, 0, NULL);
24886 #endif
24887
24888   ;
24889   return 0;
24890 }
24891 _ACEOF
24892 rm -f conftest.$ac_objext conftest$ac_exeext
24893 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24894   (eval $ac_link) 2>&5
24895   ac_status=$?
24896   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24897   (exit $ac_status); } &&
24898          { ac_try='test -s conftest$ac_exeext'
24899   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24900   (eval $ac_try) 2>&5
24901   ac_status=$?
24902   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24903   (exit $ac_status); }; }; then
24904   ol_cv_db_db_4_dot_1=yes
24905 else
24906   echo "$as_me: failed program was:" >&5
24907 sed 's/^/| /' conftest.$ac_ext >&5
24908
24909 ol_cv_db_db_4_dot_1=no
24910 fi
24911 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
24912
24913         LIBS="$ol_LIBS"
24914
24915 fi
24916 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_dot_1" >&5
24917 echo "${ECHO_T}$ol_cv_db_db_4_dot_1" >&6
24918
24919         if test $ol_cv_db_db_4_dot_1 = yes ; then
24920                 ol_cv_lib_db=-ldb-4.1
24921         fi
24922 fi
24923
24924 if test $ol_cv_lib_db = no ; then
24925         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4-1)" >&5
24926 echo $ECHO_N "checking for Berkeley DB link (-ldb-4-1)... $ECHO_C" >&6
24927 if test "${ol_cv_db_db_4_1+set}" = set; then
24928   echo $ECHO_N "(cached) $ECHO_C" >&6
24929 else
24930
24931         ol_DB_LIB=-ldb-4-1
24932         ol_LIBS=$LIBS
24933         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
24934
24935         cat >conftest.$ac_ext <<_ACEOF
24936 #line $LINENO "configure"
24937 /* confdefs.h.  */
24938 _ACEOF
24939 cat confdefs.h >>conftest.$ac_ext
24940 cat >>conftest.$ac_ext <<_ACEOF
24941 /* end confdefs.h.  */
24942
24943 #ifdef HAVE_DB_185_H
24944 # include <db_185.h>
24945 #else
24946 # include <db.h>
24947 #endif
24948
24949 #ifndef DB_VERSION_MAJOR
24950 # define DB_VERSION_MAJOR 1
24951 #endif
24952
24953 #ifndef NULL
24954 #define NULL ((void*)0)
24955 #endif
24956
24957 int
24958 main ()
24959 {
24960
24961 #if DB_VERSION_MAJOR > 1
24962         {
24963                 char *version;
24964                 int major, minor, patch;
24965
24966                 version = db_version( &major, &minor, &patch );
24967
24968                 if( major != DB_VERSION_MAJOR ||
24969                         minor < DB_VERSION_MINOR )
24970                 {
24971                         printf("Berkeley DB version mismatch\n"
24972                                 "\texpected: %s\n\tgot: %s\n",
24973                                 DB_VERSION_STRING, version);
24974                         return 1;
24975                 }
24976         }
24977 #endif
24978
24979 #if DB_VERSION_MAJOR > 2
24980         db_env_create( NULL, 0 );
24981 #elif DB_VERSION_MAJOR > 1
24982         db_appexit( NULL );
24983 #else
24984         (void) dbopen( NULL, 0, 0, 0, NULL);
24985 #endif
24986
24987   ;
24988   return 0;
24989 }
24990 _ACEOF
24991 rm -f conftest.$ac_objext conftest$ac_exeext
24992 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
24993   (eval $ac_link) 2>&5
24994   ac_status=$?
24995   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24996   (exit $ac_status); } &&
24997          { ac_try='test -s conftest$ac_exeext'
24998   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24999   (eval $ac_try) 2>&5
25000   ac_status=$?
25001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25002   (exit $ac_status); }; }; then
25003   ol_cv_db_db_4_1=yes
25004 else
25005   echo "$as_me: failed program was:" >&5
25006 sed 's/^/| /' conftest.$ac_ext >&5
25007
25008 ol_cv_db_db_4_1=no
25009 fi
25010 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25011
25012         LIBS="$ol_LIBS"
25013
25014 fi
25015 echo "$as_me:$LINENO: result: $ol_cv_db_db_4_1" >&5
25016 echo "${ECHO_T}$ol_cv_db_db_4_1" >&6
25017
25018         if test $ol_cv_db_db_4_1 = yes ; then
25019                 ol_cv_lib_db=-ldb-4-1
25020         fi
25021 fi
25022
25023 if test $ol_cv_lib_db = no ; then
25024         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-4)" >&5
25025 echo $ECHO_N "checking for Berkeley DB link (-ldb-4)... $ECHO_C" >&6
25026 if test "${ol_cv_db_db_4+set}" = set; then
25027   echo $ECHO_N "(cached) $ECHO_C" >&6
25028 else
25029
25030         ol_DB_LIB=-ldb-4
25031         ol_LIBS=$LIBS
25032         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25033
25034         cat >conftest.$ac_ext <<_ACEOF
25035 #line $LINENO "configure"
25036 /* confdefs.h.  */
25037 _ACEOF
25038 cat confdefs.h >>conftest.$ac_ext
25039 cat >>conftest.$ac_ext <<_ACEOF
25040 /* end confdefs.h.  */
25041
25042 #ifdef HAVE_DB_185_H
25043 # include <db_185.h>
25044 #else
25045 # include <db.h>
25046 #endif
25047
25048 #ifndef DB_VERSION_MAJOR
25049 # define DB_VERSION_MAJOR 1
25050 #endif
25051
25052 #ifndef NULL
25053 #define NULL ((void*)0)
25054 #endif
25055
25056 int
25057 main ()
25058 {
25059
25060 #if DB_VERSION_MAJOR > 1
25061         {
25062                 char *version;
25063                 int major, minor, patch;
25064
25065                 version = db_version( &major, &minor, &patch );
25066
25067                 if( major != DB_VERSION_MAJOR ||
25068                         minor < DB_VERSION_MINOR )
25069                 {
25070                         printf("Berkeley DB version mismatch\n"
25071                                 "\texpected: %s\n\tgot: %s\n",
25072                                 DB_VERSION_STRING, version);
25073                         return 1;
25074                 }
25075         }
25076 #endif
25077
25078 #if DB_VERSION_MAJOR > 2
25079         db_env_create( NULL, 0 );
25080 #elif DB_VERSION_MAJOR > 1
25081         db_appexit( NULL );
25082 #else
25083         (void) dbopen( NULL, 0, 0, 0, NULL);
25084 #endif
25085
25086   ;
25087   return 0;
25088 }
25089 _ACEOF
25090 rm -f conftest.$ac_objext conftest$ac_exeext
25091 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25092   (eval $ac_link) 2>&5
25093   ac_status=$?
25094   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25095   (exit $ac_status); } &&
25096          { ac_try='test -s conftest$ac_exeext'
25097   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25098   (eval $ac_try) 2>&5
25099   ac_status=$?
25100   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25101   (exit $ac_status); }; }; then
25102   ol_cv_db_db_4=yes
25103 else
25104   echo "$as_me: failed program was:" >&5
25105 sed 's/^/| /' conftest.$ac_ext >&5
25106
25107 ol_cv_db_db_4=no
25108 fi
25109 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25110
25111         LIBS="$ol_LIBS"
25112
25113 fi
25114 echo "$as_me:$LINENO: result: $ol_cv_db_db_4" >&5
25115 echo "${ECHO_T}$ol_cv_db_db_4" >&6
25116
25117         if test $ol_cv_db_db_4 = yes ; then
25118                 ol_cv_lib_db=-ldb-4
25119         fi
25120 fi
25121
25122 if test $ol_cv_lib_db = no ; then
25123         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb4)" >&5
25124 echo $ECHO_N "checking for Berkeley DB link (-ldb4)... $ECHO_C" >&6
25125 if test "${ol_cv_db_db4+set}" = set; then
25126   echo $ECHO_N "(cached) $ECHO_C" >&6
25127 else
25128
25129         ol_DB_LIB=-ldb4
25130         ol_LIBS=$LIBS
25131         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25132
25133         cat >conftest.$ac_ext <<_ACEOF
25134 #line $LINENO "configure"
25135 /* confdefs.h.  */
25136 _ACEOF
25137 cat confdefs.h >>conftest.$ac_ext
25138 cat >>conftest.$ac_ext <<_ACEOF
25139 /* end confdefs.h.  */
25140
25141 #ifdef HAVE_DB_185_H
25142 # include <db_185.h>
25143 #else
25144 # include <db.h>
25145 #endif
25146
25147 #ifndef DB_VERSION_MAJOR
25148 # define DB_VERSION_MAJOR 1
25149 #endif
25150
25151 #ifndef NULL
25152 #define NULL ((void*)0)
25153 #endif
25154
25155 int
25156 main ()
25157 {
25158
25159 #if DB_VERSION_MAJOR > 1
25160         {
25161                 char *version;
25162                 int major, minor, patch;
25163
25164                 version = db_version( &major, &minor, &patch );
25165
25166                 if( major != DB_VERSION_MAJOR ||
25167                         minor < DB_VERSION_MINOR )
25168                 {
25169                         printf("Berkeley DB version mismatch\n"
25170                                 "\texpected: %s\n\tgot: %s\n",
25171                                 DB_VERSION_STRING, version);
25172                         return 1;
25173                 }
25174         }
25175 #endif
25176
25177 #if DB_VERSION_MAJOR > 2
25178         db_env_create( NULL, 0 );
25179 #elif DB_VERSION_MAJOR > 1
25180         db_appexit( NULL );
25181 #else
25182         (void) dbopen( NULL, 0, 0, 0, NULL);
25183 #endif
25184
25185   ;
25186   return 0;
25187 }
25188 _ACEOF
25189 rm -f conftest.$ac_objext conftest$ac_exeext
25190 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25191   (eval $ac_link) 2>&5
25192   ac_status=$?
25193   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25194   (exit $ac_status); } &&
25195          { ac_try='test -s conftest$ac_exeext'
25196   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25197   (eval $ac_try) 2>&5
25198   ac_status=$?
25199   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25200   (exit $ac_status); }; }; then
25201   ol_cv_db_db4=yes
25202 else
25203   echo "$as_me: failed program was:" >&5
25204 sed 's/^/| /' conftest.$ac_ext >&5
25205
25206 ol_cv_db_db4=no
25207 fi
25208 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25209
25210         LIBS="$ol_LIBS"
25211
25212 fi
25213 echo "$as_me:$LINENO: result: $ol_cv_db_db4" >&5
25214 echo "${ECHO_T}$ol_cv_db_db4" >&6
25215
25216         if test $ol_cv_db_db4 = yes ; then
25217                 ol_cv_lib_db=-ldb4
25218         fi
25219 fi
25220
25221 if test $ol_cv_lib_db = no ; then
25222         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb)" >&5
25223 echo $ECHO_N "checking for Berkeley DB link (-ldb)... $ECHO_C" >&6
25224 if test "${ol_cv_db_db+set}" = set; then
25225   echo $ECHO_N "(cached) $ECHO_C" >&6
25226 else
25227
25228         ol_DB_LIB=-ldb
25229         ol_LIBS=$LIBS
25230         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25231
25232         cat >conftest.$ac_ext <<_ACEOF
25233 #line $LINENO "configure"
25234 /* confdefs.h.  */
25235 _ACEOF
25236 cat confdefs.h >>conftest.$ac_ext
25237 cat >>conftest.$ac_ext <<_ACEOF
25238 /* end confdefs.h.  */
25239
25240 #ifdef HAVE_DB_185_H
25241 # include <db_185.h>
25242 #else
25243 # include <db.h>
25244 #endif
25245
25246 #ifndef DB_VERSION_MAJOR
25247 # define DB_VERSION_MAJOR 1
25248 #endif
25249
25250 #ifndef NULL
25251 #define NULL ((void*)0)
25252 #endif
25253
25254 int
25255 main ()
25256 {
25257
25258 #if DB_VERSION_MAJOR > 1
25259         {
25260                 char *version;
25261                 int major, minor, patch;
25262
25263                 version = db_version( &major, &minor, &patch );
25264
25265                 if( major != DB_VERSION_MAJOR ||
25266                         minor < DB_VERSION_MINOR )
25267                 {
25268                         printf("Berkeley DB version mismatch\n"
25269                                 "\texpected: %s\n\tgot: %s\n",
25270                                 DB_VERSION_STRING, version);
25271                         return 1;
25272                 }
25273         }
25274 #endif
25275
25276 #if DB_VERSION_MAJOR > 2
25277         db_env_create( NULL, 0 );
25278 #elif DB_VERSION_MAJOR > 1
25279         db_appexit( NULL );
25280 #else
25281         (void) dbopen( NULL, 0, 0, 0, NULL);
25282 #endif
25283
25284   ;
25285   return 0;
25286 }
25287 _ACEOF
25288 rm -f conftest.$ac_objext conftest$ac_exeext
25289 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25290   (eval $ac_link) 2>&5
25291   ac_status=$?
25292   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25293   (exit $ac_status); } &&
25294          { ac_try='test -s conftest$ac_exeext'
25295   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25296   (eval $ac_try) 2>&5
25297   ac_status=$?
25298   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25299   (exit $ac_status); }; }; then
25300   ol_cv_db_db=yes
25301 else
25302   echo "$as_me: failed program was:" >&5
25303 sed 's/^/| /' conftest.$ac_ext >&5
25304
25305 ol_cv_db_db=no
25306 fi
25307 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25308
25309         LIBS="$ol_LIBS"
25310
25311 fi
25312 echo "$as_me:$LINENO: result: $ol_cv_db_db" >&5
25313 echo "${ECHO_T}$ol_cv_db_db" >&6
25314
25315         if test $ol_cv_db_db = yes ; then
25316                 ol_cv_lib_db=-ldb
25317         fi
25318 fi
25319
25320 if test $ol_cv_lib_db = no ; then
25321         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb3)" >&5
25322 echo $ECHO_N "checking for Berkeley DB link (-ldb3)... $ECHO_C" >&6
25323 if test "${ol_cv_db_db3+set}" = set; then
25324   echo $ECHO_N "(cached) $ECHO_C" >&6
25325 else
25326
25327         ol_DB_LIB=-ldb3
25328         ol_LIBS=$LIBS
25329         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25330
25331         cat >conftest.$ac_ext <<_ACEOF
25332 #line $LINENO "configure"
25333 /* confdefs.h.  */
25334 _ACEOF
25335 cat confdefs.h >>conftest.$ac_ext
25336 cat >>conftest.$ac_ext <<_ACEOF
25337 /* end confdefs.h.  */
25338
25339 #ifdef HAVE_DB_185_H
25340 # include <db_185.h>
25341 #else
25342 # include <db.h>
25343 #endif
25344
25345 #ifndef DB_VERSION_MAJOR
25346 # define DB_VERSION_MAJOR 1
25347 #endif
25348
25349 #ifndef NULL
25350 #define NULL ((void*)0)
25351 #endif
25352
25353 int
25354 main ()
25355 {
25356
25357 #if DB_VERSION_MAJOR > 1
25358         {
25359                 char *version;
25360                 int major, minor, patch;
25361
25362                 version = db_version( &major, &minor, &patch );
25363
25364                 if( major != DB_VERSION_MAJOR ||
25365                         minor < DB_VERSION_MINOR )
25366                 {
25367                         printf("Berkeley DB version mismatch\n"
25368                                 "\texpected: %s\n\tgot: %s\n",
25369                                 DB_VERSION_STRING, version);
25370                         return 1;
25371                 }
25372         }
25373 #endif
25374
25375 #if DB_VERSION_MAJOR > 2
25376         db_env_create( NULL, 0 );
25377 #elif DB_VERSION_MAJOR > 1
25378         db_appexit( NULL );
25379 #else
25380         (void) dbopen( NULL, 0, 0, 0, NULL);
25381 #endif
25382
25383   ;
25384   return 0;
25385 }
25386 _ACEOF
25387 rm -f conftest.$ac_objext conftest$ac_exeext
25388 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25389   (eval $ac_link) 2>&5
25390   ac_status=$?
25391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25392   (exit $ac_status); } &&
25393          { ac_try='test -s conftest$ac_exeext'
25394   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25395   (eval $ac_try) 2>&5
25396   ac_status=$?
25397   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25398   (exit $ac_status); }; }; then
25399   ol_cv_db_db3=yes
25400 else
25401   echo "$as_me: failed program was:" >&5
25402 sed 's/^/| /' conftest.$ac_ext >&5
25403
25404 ol_cv_db_db3=no
25405 fi
25406 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25407
25408         LIBS="$ol_LIBS"
25409
25410 fi
25411 echo "$as_me:$LINENO: result: $ol_cv_db_db3" >&5
25412 echo "${ECHO_T}$ol_cv_db_db3" >&6
25413
25414         if test $ol_cv_db_db3 = yes ; then
25415                 ol_cv_lib_db=-ldb3
25416         fi
25417 fi
25418
25419 if test $ol_cv_lib_db = no ; then
25420         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-3)" >&5
25421 echo $ECHO_N "checking for Berkeley DB link (-ldb-3)... $ECHO_C" >&6
25422 if test "${ol_cv_db_db_3+set}" = set; then
25423   echo $ECHO_N "(cached) $ECHO_C" >&6
25424 else
25425
25426         ol_DB_LIB=-ldb-3
25427         ol_LIBS=$LIBS
25428         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25429
25430         cat >conftest.$ac_ext <<_ACEOF
25431 #line $LINENO "configure"
25432 /* confdefs.h.  */
25433 _ACEOF
25434 cat confdefs.h >>conftest.$ac_ext
25435 cat >>conftest.$ac_ext <<_ACEOF
25436 /* end confdefs.h.  */
25437
25438 #ifdef HAVE_DB_185_H
25439 # include <db_185.h>
25440 #else
25441 # include <db.h>
25442 #endif
25443
25444 #ifndef DB_VERSION_MAJOR
25445 # define DB_VERSION_MAJOR 1
25446 #endif
25447
25448 #ifndef NULL
25449 #define NULL ((void*)0)
25450 #endif
25451
25452 int
25453 main ()
25454 {
25455
25456 #if DB_VERSION_MAJOR > 1
25457         {
25458                 char *version;
25459                 int major, minor, patch;
25460
25461                 version = db_version( &major, &minor, &patch );
25462
25463                 if( major != DB_VERSION_MAJOR ||
25464                         minor < DB_VERSION_MINOR )
25465                 {
25466                         printf("Berkeley DB version mismatch\n"
25467                                 "\texpected: %s\n\tgot: %s\n",
25468                                 DB_VERSION_STRING, version);
25469                         return 1;
25470                 }
25471         }
25472 #endif
25473
25474 #if DB_VERSION_MAJOR > 2
25475         db_env_create( NULL, 0 );
25476 #elif DB_VERSION_MAJOR > 1
25477         db_appexit( NULL );
25478 #else
25479         (void) dbopen( NULL, 0, 0, 0, NULL);
25480 #endif
25481
25482   ;
25483   return 0;
25484 }
25485 _ACEOF
25486 rm -f conftest.$ac_objext conftest$ac_exeext
25487 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25488   (eval $ac_link) 2>&5
25489   ac_status=$?
25490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25491   (exit $ac_status); } &&
25492          { ac_try='test -s conftest$ac_exeext'
25493   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25494   (eval $ac_try) 2>&5
25495   ac_status=$?
25496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25497   (exit $ac_status); }; }; then
25498   ol_cv_db_db_3=yes
25499 else
25500   echo "$as_me: failed program was:" >&5
25501 sed 's/^/| /' conftest.$ac_ext >&5
25502
25503 ol_cv_db_db_3=no
25504 fi
25505 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25506
25507         LIBS="$ol_LIBS"
25508
25509 fi
25510 echo "$as_me:$LINENO: result: $ol_cv_db_db_3" >&5
25511 echo "${ECHO_T}$ol_cv_db_db_3" >&6
25512
25513         if test $ol_cv_db_db_3 = yes ; then
25514                 ol_cv_lib_db=-ldb-3
25515         fi
25516 fi
25517
25518 if test $ol_cv_lib_db = no ; then
25519         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb2)" >&5
25520 echo $ECHO_N "checking for Berkeley DB link (-ldb2)... $ECHO_C" >&6
25521 if test "${ol_cv_db_db2+set}" = set; then
25522   echo $ECHO_N "(cached) $ECHO_C" >&6
25523 else
25524
25525         ol_DB_LIB=-ldb2
25526         ol_LIBS=$LIBS
25527         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25528
25529         cat >conftest.$ac_ext <<_ACEOF
25530 #line $LINENO "configure"
25531 /* confdefs.h.  */
25532 _ACEOF
25533 cat confdefs.h >>conftest.$ac_ext
25534 cat >>conftest.$ac_ext <<_ACEOF
25535 /* end confdefs.h.  */
25536
25537 #ifdef HAVE_DB_185_H
25538 # include <db_185.h>
25539 #else
25540 # include <db.h>
25541 #endif
25542
25543 #ifndef DB_VERSION_MAJOR
25544 # define DB_VERSION_MAJOR 1
25545 #endif
25546
25547 #ifndef NULL
25548 #define NULL ((void*)0)
25549 #endif
25550
25551 int
25552 main ()
25553 {
25554
25555 #if DB_VERSION_MAJOR > 1
25556         {
25557                 char *version;
25558                 int major, minor, patch;
25559
25560                 version = db_version( &major, &minor, &patch );
25561
25562                 if( major != DB_VERSION_MAJOR ||
25563                         minor < DB_VERSION_MINOR )
25564                 {
25565                         printf("Berkeley DB version mismatch\n"
25566                                 "\texpected: %s\n\tgot: %s\n",
25567                                 DB_VERSION_STRING, version);
25568                         return 1;
25569                 }
25570         }
25571 #endif
25572
25573 #if DB_VERSION_MAJOR > 2
25574         db_env_create( NULL, 0 );
25575 #elif DB_VERSION_MAJOR > 1
25576         db_appexit( NULL );
25577 #else
25578         (void) dbopen( NULL, 0, 0, 0, NULL);
25579 #endif
25580
25581   ;
25582   return 0;
25583 }
25584 _ACEOF
25585 rm -f conftest.$ac_objext conftest$ac_exeext
25586 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25587   (eval $ac_link) 2>&5
25588   ac_status=$?
25589   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25590   (exit $ac_status); } &&
25591          { ac_try='test -s conftest$ac_exeext'
25592   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25593   (eval $ac_try) 2>&5
25594   ac_status=$?
25595   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25596   (exit $ac_status); }; }; then
25597   ol_cv_db_db2=yes
25598 else
25599   echo "$as_me: failed program was:" >&5
25600 sed 's/^/| /' conftest.$ac_ext >&5
25601
25602 ol_cv_db_db2=no
25603 fi
25604 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25605
25606         LIBS="$ol_LIBS"
25607
25608 fi
25609 echo "$as_me:$LINENO: result: $ol_cv_db_db2" >&5
25610 echo "${ECHO_T}$ol_cv_db_db2" >&6
25611
25612         if test $ol_cv_db_db2 = yes ; then
25613                 ol_cv_lib_db=-ldb2
25614         fi
25615 fi
25616
25617 if test $ol_cv_lib_db = no ; then
25618         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-2)" >&5
25619 echo $ECHO_N "checking for Berkeley DB link (-ldb-2)... $ECHO_C" >&6
25620 if test "${ol_cv_db_db_2+set}" = set; then
25621   echo $ECHO_N "(cached) $ECHO_C" >&6
25622 else
25623
25624         ol_DB_LIB=-ldb-2
25625         ol_LIBS=$LIBS
25626         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25627
25628         cat >conftest.$ac_ext <<_ACEOF
25629 #line $LINENO "configure"
25630 /* confdefs.h.  */
25631 _ACEOF
25632 cat confdefs.h >>conftest.$ac_ext
25633 cat >>conftest.$ac_ext <<_ACEOF
25634 /* end confdefs.h.  */
25635
25636 #ifdef HAVE_DB_185_H
25637 # include <db_185.h>
25638 #else
25639 # include <db.h>
25640 #endif
25641
25642 #ifndef DB_VERSION_MAJOR
25643 # define DB_VERSION_MAJOR 1
25644 #endif
25645
25646 #ifndef NULL
25647 #define NULL ((void*)0)
25648 #endif
25649
25650 int
25651 main ()
25652 {
25653
25654 #if DB_VERSION_MAJOR > 1
25655         {
25656                 char *version;
25657                 int major, minor, patch;
25658
25659                 version = db_version( &major, &minor, &patch );
25660
25661                 if( major != DB_VERSION_MAJOR ||
25662                         minor < DB_VERSION_MINOR )
25663                 {
25664                         printf("Berkeley DB version mismatch\n"
25665                                 "\texpected: %s\n\tgot: %s\n",
25666                                 DB_VERSION_STRING, version);
25667                         return 1;
25668                 }
25669         }
25670 #endif
25671
25672 #if DB_VERSION_MAJOR > 2
25673         db_env_create( NULL, 0 );
25674 #elif DB_VERSION_MAJOR > 1
25675         db_appexit( NULL );
25676 #else
25677         (void) dbopen( NULL, 0, 0, 0, NULL);
25678 #endif
25679
25680   ;
25681   return 0;
25682 }
25683 _ACEOF
25684 rm -f conftest.$ac_objext conftest$ac_exeext
25685 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25686   (eval $ac_link) 2>&5
25687   ac_status=$?
25688   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25689   (exit $ac_status); } &&
25690          { ac_try='test -s conftest$ac_exeext'
25691   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25692   (eval $ac_try) 2>&5
25693   ac_status=$?
25694   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25695   (exit $ac_status); }; }; then
25696   ol_cv_db_db_2=yes
25697 else
25698   echo "$as_me: failed program was:" >&5
25699 sed 's/^/| /' conftest.$ac_ext >&5
25700
25701 ol_cv_db_db_2=no
25702 fi
25703 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25704
25705         LIBS="$ol_LIBS"
25706
25707 fi
25708 echo "$as_me:$LINENO: result: $ol_cv_db_db_2" >&5
25709 echo "${ECHO_T}$ol_cv_db_db_2" >&6
25710
25711         if test $ol_cv_db_db_2 = yes ; then
25712                 ol_cv_lib_db=-ldb-2
25713         fi
25714 fi
25715
25716 if test $ol_cv_lib_db = no ; then
25717         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb1)" >&5
25718 echo $ECHO_N "checking for Berkeley DB link (-ldb1)... $ECHO_C" >&6
25719 if test "${ol_cv_db_db1+set}" = set; then
25720   echo $ECHO_N "(cached) $ECHO_C" >&6
25721 else
25722
25723         ol_DB_LIB=-ldb1
25724         ol_LIBS=$LIBS
25725         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25726
25727         cat >conftest.$ac_ext <<_ACEOF
25728 #line $LINENO "configure"
25729 /* confdefs.h.  */
25730 _ACEOF
25731 cat confdefs.h >>conftest.$ac_ext
25732 cat >>conftest.$ac_ext <<_ACEOF
25733 /* end confdefs.h.  */
25734
25735 #ifdef HAVE_DB_185_H
25736 # include <db_185.h>
25737 #else
25738 # include <db.h>
25739 #endif
25740
25741 #ifndef DB_VERSION_MAJOR
25742 # define DB_VERSION_MAJOR 1
25743 #endif
25744
25745 #ifndef NULL
25746 #define NULL ((void*)0)
25747 #endif
25748
25749 int
25750 main ()
25751 {
25752
25753 #if DB_VERSION_MAJOR > 1
25754         {
25755                 char *version;
25756                 int major, minor, patch;
25757
25758                 version = db_version( &major, &minor, &patch );
25759
25760                 if( major != DB_VERSION_MAJOR ||
25761                         minor < DB_VERSION_MINOR )
25762                 {
25763                         printf("Berkeley DB version mismatch\n"
25764                                 "\texpected: %s\n\tgot: %s\n",
25765                                 DB_VERSION_STRING, version);
25766                         return 1;
25767                 }
25768         }
25769 #endif
25770
25771 #if DB_VERSION_MAJOR > 2
25772         db_env_create( NULL, 0 );
25773 #elif DB_VERSION_MAJOR > 1
25774         db_appexit( NULL );
25775 #else
25776         (void) dbopen( NULL, 0, 0, 0, NULL);
25777 #endif
25778
25779   ;
25780   return 0;
25781 }
25782 _ACEOF
25783 rm -f conftest.$ac_objext conftest$ac_exeext
25784 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25785   (eval $ac_link) 2>&5
25786   ac_status=$?
25787   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25788   (exit $ac_status); } &&
25789          { ac_try='test -s conftest$ac_exeext'
25790   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25791   (eval $ac_try) 2>&5
25792   ac_status=$?
25793   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25794   (exit $ac_status); }; }; then
25795   ol_cv_db_db1=yes
25796 else
25797   echo "$as_me: failed program was:" >&5
25798 sed 's/^/| /' conftest.$ac_ext >&5
25799
25800 ol_cv_db_db1=no
25801 fi
25802 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25803
25804         LIBS="$ol_LIBS"
25805
25806 fi
25807 echo "$as_me:$LINENO: result: $ol_cv_db_db1" >&5
25808 echo "${ECHO_T}$ol_cv_db_db1" >&6
25809
25810         if test $ol_cv_db_db1 = yes ; then
25811                 ol_cv_lib_db=-ldb1
25812         fi
25813 fi
25814
25815 if test $ol_cv_lib_db = no ; then
25816         echo "$as_me:$LINENO: checking for Berkeley DB link (-ldb-1)" >&5
25817 echo $ECHO_N "checking for Berkeley DB link (-ldb-1)... $ECHO_C" >&6
25818 if test "${ol_cv_db_db_1+set}" = set; then
25819   echo $ECHO_N "(cached) $ECHO_C" >&6
25820 else
25821
25822         ol_DB_LIB=-ldb-1
25823         ol_LIBS=$LIBS
25824         LIBS="$ol_DB_LIB $LTHREAD_LIBS $LIBS"
25825
25826         cat >conftest.$ac_ext <<_ACEOF
25827 #line $LINENO "configure"
25828 /* confdefs.h.  */
25829 _ACEOF
25830 cat confdefs.h >>conftest.$ac_ext
25831 cat >>conftest.$ac_ext <<_ACEOF
25832 /* end confdefs.h.  */
25833
25834 #ifdef HAVE_DB_185_H
25835 # include <db_185.h>
25836 #else
25837 # include <db.h>
25838 #endif
25839
25840 #ifndef DB_VERSION_MAJOR
25841 # define DB_VERSION_MAJOR 1
25842 #endif
25843
25844 #ifndef NULL
25845 #define NULL ((void*)0)
25846 #endif
25847
25848 int
25849 main ()
25850 {
25851
25852 #if DB_VERSION_MAJOR > 1
25853         {
25854                 char *version;
25855                 int major, minor, patch;
25856
25857                 version = db_version( &major, &minor, &patch );
25858
25859                 if( major != DB_VERSION_MAJOR ||
25860                         minor < DB_VERSION_MINOR )
25861                 {
25862                         printf("Berkeley DB version mismatch\n"
25863                                 "\texpected: %s\n\tgot: %s\n",
25864                                 DB_VERSION_STRING, version);
25865                         return 1;
25866                 }
25867         }
25868 #endif
25869
25870 #if DB_VERSION_MAJOR > 2
25871         db_env_create( NULL, 0 );
25872 #elif DB_VERSION_MAJOR > 1
25873         db_appexit( NULL );
25874 #else
25875         (void) dbopen( NULL, 0, 0, 0, NULL);
25876 #endif
25877
25878   ;
25879   return 0;
25880 }
25881 _ACEOF
25882 rm -f conftest.$ac_objext conftest$ac_exeext
25883 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
25884   (eval $ac_link) 2>&5
25885   ac_status=$?
25886   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25887   (exit $ac_status); } &&
25888          { ac_try='test -s conftest$ac_exeext'
25889   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25890   (eval $ac_try) 2>&5
25891   ac_status=$?
25892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25893   (exit $ac_status); }; }; then
25894   ol_cv_db_db_1=yes
25895 else
25896   echo "$as_me: failed program was:" >&5
25897 sed 's/^/| /' conftest.$ac_ext >&5
25898
25899 ol_cv_db_db_1=no
25900 fi
25901 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
25902
25903         LIBS="$ol_LIBS"
25904
25905 fi
25906 echo "$as_me:$LINENO: result: $ol_cv_db_db_1" >&5
25907 echo "${ECHO_T}$ol_cv_db_db_1" >&6
25908
25909         if test $ol_cv_db_db_1 = yes ; then
25910                 ol_cv_lib_db=-ldb-1
25911         fi
25912 fi
25913
25914
25915         if test "$ol_cv_lib_db" != no ; then
25916                 ol_cv_berkeley_db=yes
25917                 echo "$as_me:$LINENO: checking for Berkeley DB thread support" >&5
25918 echo $ECHO_N "checking for Berkeley DB thread support... $ECHO_C" >&6
25919 if test "${ol_cv_berkeley_db_thread+set}" = set; then
25920   echo $ECHO_N "(cached) $ECHO_C" >&6
25921 else
25922
25923         ol_LIBS="$LIBS"
25924         LIBS="$LTHREAD_LIBS $LIBS"
25925         if test $ol_cv_lib_db != yes ; then
25926                 LIBS="$ol_cv_lib_db $LIBS"
25927         fi
25928
25929         if test "$cross_compiling" = yes; then
25930   ol_cv_berkeley_db_thread=cross
25931 else
25932   cat >conftest.$ac_ext <<_ACEOF
25933 #line $LINENO "configure"
25934 /* confdefs.h.  */
25935 _ACEOF
25936 cat confdefs.h >>conftest.$ac_ext
25937 cat >>conftest.$ac_ext <<_ACEOF
25938 /* end confdefs.h.  */
25939
25940 #ifdef HAVE_DB_185_H
25941         choke me;
25942 #else
25943 #include <db.h>
25944 #endif
25945 #ifndef NULL
25946 #define NULL ((void *)0)
25947 #endif
25948 main()
25949 {
25950         int rc;
25951         u_int32_t flags = DB_CREATE |
25952 #ifdef DB_PRIVATE
25953                 DB_PRIVATE |
25954 #endif
25955                 DB_THREAD;
25956
25957 #if DB_VERSION_MAJOR > 2
25958         DB_ENV *env = NULL;
25959
25960         rc = db_env_create( &env, 0 );
25961
25962         flags |= DB_INIT_MPOOL;
25963 #ifdef DB_MPOOL_PRIVATE
25964         flags |= DB_MPOOL_PRIVATE;
25965 #endif
25966
25967         if( rc ) {
25968                 printf("BerkeleyDB: %s\n", db_strerror(rc) );
25969                 return rc;
25970         }
25971
25972 #if (DB_VERSION_MAJOR > 3) || (DB_VERSION_MINOR >= 1)
25973         rc = env->open( env, NULL, flags, 0 );
25974 #else
25975         rc = env->open( env, NULL, NULL, flags, 0 );
25976 #endif
25977
25978         if ( rc == 0 ) {
25979                 rc = env->close( env, 0 );
25980         }
25981
25982         if( rc ) {
25983                 printf("BerkeleyDB: %s\n", db_strerror(rc) );
25984                 return rc;
25985         }
25986
25987 #else
25988         DB_ENV env;
25989         memset( &env, '\0', sizeof(env) );
25990
25991         rc = db_appinit( NULL, NULL, &env, flags );
25992
25993         if( rc == 0 ) {
25994                 db_appexit( &env );
25995         }
25996
25997         unlink("__db_mpool.share");
25998         unlink("__db_lock.share");
25999 #endif
26000
26001         return rc;
26002 }
26003 _ACEOF
26004 rm -f conftest$ac_exeext
26005 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26006   (eval $ac_link) 2>&5
26007   ac_status=$?
26008   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26009   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26010   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26011   (eval $ac_try) 2>&5
26012   ac_status=$?
26013   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26014   (exit $ac_status); }; }; then
26015   ol_cv_berkeley_db_thread=yes
26016 else
26017   echo "$as_me: program exited with status $ac_status" >&5
26018 echo "$as_me: failed program was:" >&5
26019 sed 's/^/| /' conftest.$ac_ext >&5
26020
26021 ( exit $ac_status )
26022 ol_cv_berkeley_db_thread=no
26023 fi
26024 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26025 fi
26026
26027         LIBS="$ol_LIBS"
26028
26029 fi
26030 echo "$as_me:$LINENO: result: $ol_cv_berkeley_db_thread" >&5
26031 echo "${ECHO_T}$ol_cv_berkeley_db_thread" >&6
26032
26033         if test $ol_cv_berkeley_db_thread != no ; then
26034
26035 cat >>confdefs.h <<\_ACEOF
26036 #define HAVE_BERKELEY_DB_THREAD 1
26037 _ACEOF
26038
26039         fi
26040
26041         fi
26042 fi
26043
26044         fi
26045
26046         if test $ol_cv_berkeley_db != no ; then
26047
26048 cat >>confdefs.h <<\_ACEOF
26049 #define HAVE_BERKELEY_DB 1
26050 _ACEOF
26051
26052
26053                 ol_link_ldbm=berkeley
26054                 ol_with_ldbm_api=berkeley
26055
26056                 if test $ol_with_ldbm_type = hash ; then
26057
26058 cat >>confdefs.h <<\_ACEOF
26059 #define LDBM_USE_DBHASH 1
26060 _ACEOF
26061
26062                 else
26063
26064 cat >>confdefs.h <<\_ACEOF
26065 #define LDBM_USE_DBBTREE 1
26066 _ACEOF
26067
26068                 fi
26069
26070                                                 if test $ol_cv_lib_db != yes ; then
26071                         LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_db"
26072                 fi
26073         fi
26074 fi
26075
26076 if test $ol_enable_bdb = yes -a $ol_link_ldbm != berkeley ; then
26077         { { echo "$as_me:$LINENO: error: BDB: BerkeleyDB not available" >&5
26078 echo "$as_me: error: BDB: BerkeleyDB not available" >&2;}
26079    { (exit 1); exit 1; }; }
26080 elif test $ol_enable_bdb != no -a $ol_link_ldbm = berkeley ; then
26081         echo "$as_me:$LINENO: checking Berkeley DB version for BDB backend" >&5
26082 echo $ECHO_N "checking Berkeley DB version for BDB backend... $ECHO_C" >&6
26083 if test "${ol_cv_bdb_compat+set}" = set; then
26084   echo $ECHO_N "(cached) $ECHO_C" >&6
26085 else
26086
26087         cat >conftest.$ac_ext <<_ACEOF
26088 #line $LINENO "configure"
26089 /* confdefs.h.  */
26090 _ACEOF
26091 cat confdefs.h >>conftest.$ac_ext
26092 cat >>conftest.$ac_ext <<_ACEOF
26093 /* end confdefs.h.  */
26094
26095 #include <db.h>
26096
26097  /* this check could be improved */
26098 #ifndef DB_VERSION_MAJOR
26099 #       define DB_VERSION_MAJOR 1
26100 #endif
26101 #ifndef DB_VERSION_MINOR
26102 #       define DB_VERSION_MINOR 0
26103 #endif
26104
26105 /* require 4.1 or later */
26106 #if (DB_VERSION_MAJOR >= 4) && (DB_VERSION_MINOR >= 1)
26107         __db_version_compat
26108 #endif
26109
26110 _ACEOF
26111 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
26112   $EGREP "__db_version_compat" >/dev/null 2>&1; then
26113   ol_cv_bdb_compat=yes
26114 else
26115   ol_cv_bdb_compat=no
26116 fi
26117 rm -f conftest*
26118
26119 fi
26120 echo "$as_me:$LINENO: result: $ol_cv_bdb_compat" >&5
26121 echo "${ECHO_T}$ol_cv_bdb_compat" >&6
26122
26123
26124         if test $ol_cv_bdb_compat = yes ; then
26125                 ol_enable_bdb=yes
26126         elif test $ol_enable_bdb = yes ; then
26127                 { { echo "$as_me:$LINENO: error: BDB: BerkeleyDB version incompatible" >&5
26128 echo "$as_me: error: BDB: BerkeleyDB version incompatible" >&2;}
26129    { (exit 1); exit 1; }; }
26130         else
26131                 ol_enable_bdb=no
26132         fi
26133 fi
26134
26135 if test $ol_link_ldbm = no -a $ol_with_ldbm_type = btree ; then
26136         { echo "$as_me:$LINENO: WARNING: Could not find LDBM with BTREE support" >&5
26137 echo "$as_me: WARNING: Could not find LDBM with BTREE support" >&2;}
26138         ol_with_ldbm_api=none
26139 fi
26140
26141 if test $ol_with_ldbm_api = auto -o $ol_with_ldbm_api = mdbm ; then
26142         echo "$as_me:$LINENO: checking for MDBM library" >&5
26143 echo $ECHO_N "checking for MDBM library... $ECHO_C" >&6
26144 if test "${ol_cv_lib_mdbm+set}" = set; then
26145   echo $ECHO_N "(cached) $ECHO_C" >&6
26146 else
26147         ol_LIBS="$LIBS"
26148         echo "$as_me:$LINENO: checking for mdbm_set_chain" >&5
26149 echo $ECHO_N "checking for mdbm_set_chain... $ECHO_C" >&6
26150 if test "${ac_cv_func_mdbm_set_chain+set}" = set; then
26151   echo $ECHO_N "(cached) $ECHO_C" >&6
26152 else
26153   cat >conftest.$ac_ext <<_ACEOF
26154 #line $LINENO "configure"
26155 /* confdefs.h.  */
26156 _ACEOF
26157 cat confdefs.h >>conftest.$ac_ext
26158 cat >>conftest.$ac_ext <<_ACEOF
26159 /* end confdefs.h.  */
26160 /* System header to define __stub macros and hopefully few prototypes,
26161     which can conflict with char mdbm_set_chain (); below.
26162     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
26163     <limits.h> exists even on freestanding compilers.  */
26164 #ifdef __STDC__
26165 # include <limits.h>
26166 #else
26167 # include <assert.h>
26168 #endif
26169 /* Override any gcc2 internal prototype to avoid an error.  */
26170 #ifdef __cplusplus
26171 extern "C"
26172 {
26173 #endif
26174 /* We use char because int might match the return type of a gcc2
26175    builtin and then its argument prototype would still apply.  */
26176 char mdbm_set_chain ();
26177 /* The GNU C library defines this for functions which it implements
26178     to always fail with ENOSYS.  Some functions are actually named
26179     something starting with __ and the normal name is an alias.  */
26180 #if defined (__stub_mdbm_set_chain) || defined (__stub___mdbm_set_chain)
26181 choke me
26182 #else
26183 char (*f) () = mdbm_set_chain;
26184 #endif
26185 #ifdef __cplusplus
26186 }
26187 #endif
26188
26189 int
26190 main ()
26191 {
26192 return f != mdbm_set_chain;
26193   ;
26194   return 0;
26195 }
26196 _ACEOF
26197 rm -f conftest.$ac_objext conftest$ac_exeext
26198 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26199   (eval $ac_link) 2>&5
26200   ac_status=$?
26201   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26202   (exit $ac_status); } &&
26203          { ac_try='test -s conftest$ac_exeext'
26204   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26205   (eval $ac_try) 2>&5
26206   ac_status=$?
26207   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26208   (exit $ac_status); }; }; then
26209   ac_cv_func_mdbm_set_chain=yes
26210 else
26211   echo "$as_me: failed program was:" >&5
26212 sed 's/^/| /' conftest.$ac_ext >&5
26213
26214 ac_cv_func_mdbm_set_chain=no
26215 fi
26216 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26217 fi
26218 echo "$as_me:$LINENO: result: $ac_cv_func_mdbm_set_chain" >&5
26219 echo "${ECHO_T}$ac_cv_func_mdbm_set_chain" >&6
26220 if test $ac_cv_func_mdbm_set_chain = yes; then
26221   ol_cv_lib_mdbm=yes
26222 else
26223
26224                 echo "$as_me:$LINENO: checking for mdbm_set_chain in -lmdbm" >&5
26225 echo $ECHO_N "checking for mdbm_set_chain in -lmdbm... $ECHO_C" >&6
26226 if test "${ac_cv_lib_mdbm_mdbm_set_chain+set}" = set; then
26227   echo $ECHO_N "(cached) $ECHO_C" >&6
26228 else
26229   ac_check_lib_save_LIBS=$LIBS
26230 LIBS="-lmdbm  $LIBS"
26231 cat >conftest.$ac_ext <<_ACEOF
26232 #line $LINENO "configure"
26233 /* confdefs.h.  */
26234 _ACEOF
26235 cat confdefs.h >>conftest.$ac_ext
26236 cat >>conftest.$ac_ext <<_ACEOF
26237 /* end confdefs.h.  */
26238
26239 /* Override any gcc2 internal prototype to avoid an error.  */
26240 #ifdef __cplusplus
26241 extern "C"
26242 #endif
26243 /* We use char because int might match the return type of a gcc2
26244    builtin and then its argument prototype would still apply.  */
26245 char mdbm_set_chain ();
26246 int
26247 main ()
26248 {
26249 mdbm_set_chain ();
26250   ;
26251   return 0;
26252 }
26253 _ACEOF
26254 rm -f conftest.$ac_objext conftest$ac_exeext
26255 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26256   (eval $ac_link) 2>&5
26257   ac_status=$?
26258   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26259   (exit $ac_status); } &&
26260          { ac_try='test -s conftest$ac_exeext'
26261   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26262   (eval $ac_try) 2>&5
26263   ac_status=$?
26264   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26265   (exit $ac_status); }; }; then
26266   ac_cv_lib_mdbm_mdbm_set_chain=yes
26267 else
26268   echo "$as_me: failed program was:" >&5
26269 sed 's/^/| /' conftest.$ac_ext >&5
26270
26271 ac_cv_lib_mdbm_mdbm_set_chain=no
26272 fi
26273 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26274 LIBS=$ac_check_lib_save_LIBS
26275 fi
26276 echo "$as_me:$LINENO: result: $ac_cv_lib_mdbm_mdbm_set_chain" >&5
26277 echo "${ECHO_T}$ac_cv_lib_mdbm_mdbm_set_chain" >&6
26278 if test $ac_cv_lib_mdbm_mdbm_set_chain = yes; then
26279   ol_cv_lib_mdbm=-lmdbm
26280 else
26281   ol_cv_lib_mdbm=no
26282 fi
26283
26284
26285 fi
26286
26287         LIBS="$ol_LIBS"
26288
26289 fi
26290 echo "$as_me:$LINENO: result: $ol_cv_lib_mdbm" >&5
26291 echo "${ECHO_T}$ol_cv_lib_mdbm" >&6
26292
26293
26294
26295 for ac_header in mdbm.h
26296 do
26297 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26298 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26299   echo "$as_me:$LINENO: checking for $ac_header" >&5
26300 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26301 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26302   echo $ECHO_N "(cached) $ECHO_C" >&6
26303 fi
26304 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26305 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26306 else
26307   # Is the header compilable?
26308 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26309 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26310 cat >conftest.$ac_ext <<_ACEOF
26311 #line $LINENO "configure"
26312 /* confdefs.h.  */
26313 _ACEOF
26314 cat confdefs.h >>conftest.$ac_ext
26315 cat >>conftest.$ac_ext <<_ACEOF
26316 /* end confdefs.h.  */
26317 $ac_includes_default
26318 #include <$ac_header>
26319 _ACEOF
26320 rm -f conftest.$ac_objext
26321 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26322   (eval $ac_compile) 2>&5
26323   ac_status=$?
26324   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26325   (exit $ac_status); } &&
26326          { ac_try='test -s conftest.$ac_objext'
26327   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26328   (eval $ac_try) 2>&5
26329   ac_status=$?
26330   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26331   (exit $ac_status); }; }; then
26332   ac_header_compiler=yes
26333 else
26334   echo "$as_me: failed program was:" >&5
26335 sed 's/^/| /' conftest.$ac_ext >&5
26336
26337 ac_header_compiler=no
26338 fi
26339 rm -f conftest.$ac_objext conftest.$ac_ext
26340 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26341 echo "${ECHO_T}$ac_header_compiler" >&6
26342
26343 # Is the header present?
26344 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26345 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26346 cat >conftest.$ac_ext <<_ACEOF
26347 #line $LINENO "configure"
26348 /* confdefs.h.  */
26349 _ACEOF
26350 cat confdefs.h >>conftest.$ac_ext
26351 cat >>conftest.$ac_ext <<_ACEOF
26352 /* end confdefs.h.  */
26353 #include <$ac_header>
26354 _ACEOF
26355 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26356   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26357   ac_status=$?
26358   grep -v '^ *+' conftest.er1 >conftest.err
26359   rm -f conftest.er1
26360   cat conftest.err >&5
26361   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26362   (exit $ac_status); } >/dev/null; then
26363   if test -s conftest.err; then
26364     ac_cpp_err=$ac_c_preproc_warn_flag
26365   else
26366     ac_cpp_err=
26367   fi
26368 else
26369   ac_cpp_err=yes
26370 fi
26371 if test -z "$ac_cpp_err"; then
26372   ac_header_preproc=yes
26373 else
26374   echo "$as_me: failed program was:" >&5
26375 sed 's/^/| /' conftest.$ac_ext >&5
26376
26377   ac_header_preproc=no
26378 fi
26379 rm -f conftest.err conftest.$ac_ext
26380 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26381 echo "${ECHO_T}$ac_header_preproc" >&6
26382
26383 # So?  What about this header?
26384 case $ac_header_compiler:$ac_header_preproc in
26385   yes:no )
26386     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26387 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26388     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26389 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26390     (
26391       cat <<\_ASBOX
26392 ## ------------------------------------ ##
26393 ## Report this to bug-autoconf@gnu.org. ##
26394 ## ------------------------------------ ##
26395 _ASBOX
26396     ) |
26397       sed "s/^/$as_me: WARNING:     /" >&2
26398     ;;
26399   no:yes )
26400     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26401 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26402     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
26403 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
26404     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26405 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26406     (
26407       cat <<\_ASBOX
26408 ## ------------------------------------ ##
26409 ## Report this to bug-autoconf@gnu.org. ##
26410 ## ------------------------------------ ##
26411 _ASBOX
26412     ) |
26413       sed "s/^/$as_me: WARNING:     /" >&2
26414     ;;
26415 esac
26416 echo "$as_me:$LINENO: checking for $ac_header" >&5
26417 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26418 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26419   echo $ECHO_N "(cached) $ECHO_C" >&6
26420 else
26421   eval "$as_ac_Header=$ac_header_preproc"
26422 fi
26423 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26424 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26425
26426 fi
26427 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26428   cat >>confdefs.h <<_ACEOF
26429 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26430 _ACEOF
26431
26432 fi
26433
26434 done
26435
26436  echo "$as_me:$LINENO: checking for db" >&5
26437 echo $ECHO_N "checking for db... $ECHO_C" >&6
26438 if test "${ol_cv_mdbm+set}" = set; then
26439   echo $ECHO_N "(cached) $ECHO_C" >&6
26440 else
26441
26442         if test $ol_cv_lib_mdbm = no -o $ac_cv_header_mdbm_h = no ; then
26443                 ol_cv_mdbm=no
26444         else
26445                 ol_cv_mdbm=yes
26446         fi
26447
26448 fi
26449 echo "$as_me:$LINENO: result: $ol_cv_mdbm" >&5
26450 echo "${ECHO_T}$ol_cv_mdbm" >&6
26451  if test $ol_cv_mdbm = yes ; then
26452
26453 cat >>confdefs.h <<\_ACEOF
26454 #define HAVE_MDBM 1
26455 _ACEOF
26456
26457  fi
26458
26459
26460         if test $ol_cv_mdbm = yes ; then
26461                 ol_link_ldbm=mdbm
26462                 ol_with_ldbm_api=mdbm
26463                 if test $ol_cv_lib_mdbm != yes ; then
26464                         LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_mdbm"
26465                 fi
26466         fi
26467 fi
26468
26469 if test $ol_with_ldbm_api = auto -o $ol_with_ldbm_api = gdbm ; then
26470         echo "$as_me:$LINENO: checking for GDBM library" >&5
26471 echo $ECHO_N "checking for GDBM library... $ECHO_C" >&6
26472 if test "${ol_cv_lib_gdbm+set}" = set; then
26473   echo $ECHO_N "(cached) $ECHO_C" >&6
26474 else
26475         ol_LIBS="$LIBS"
26476         echo "$as_me:$LINENO: checking for gdbm_open" >&5
26477 echo $ECHO_N "checking for gdbm_open... $ECHO_C" >&6
26478 if test "${ac_cv_func_gdbm_open+set}" = set; then
26479   echo $ECHO_N "(cached) $ECHO_C" >&6
26480 else
26481   cat >conftest.$ac_ext <<_ACEOF
26482 #line $LINENO "configure"
26483 /* confdefs.h.  */
26484 _ACEOF
26485 cat confdefs.h >>conftest.$ac_ext
26486 cat >>conftest.$ac_ext <<_ACEOF
26487 /* end confdefs.h.  */
26488 /* System header to define __stub macros and hopefully few prototypes,
26489     which can conflict with char gdbm_open (); below.
26490     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
26491     <limits.h> exists even on freestanding compilers.  */
26492 #ifdef __STDC__
26493 # include <limits.h>
26494 #else
26495 # include <assert.h>
26496 #endif
26497 /* Override any gcc2 internal prototype to avoid an error.  */
26498 #ifdef __cplusplus
26499 extern "C"
26500 {
26501 #endif
26502 /* We use char because int might match the return type of a gcc2
26503    builtin and then its argument prototype would still apply.  */
26504 char gdbm_open ();
26505 /* The GNU C library defines this for functions which it implements
26506     to always fail with ENOSYS.  Some functions are actually named
26507     something starting with __ and the normal name is an alias.  */
26508 #if defined (__stub_gdbm_open) || defined (__stub___gdbm_open)
26509 choke me
26510 #else
26511 char (*f) () = gdbm_open;
26512 #endif
26513 #ifdef __cplusplus
26514 }
26515 #endif
26516
26517 int
26518 main ()
26519 {
26520 return f != gdbm_open;
26521   ;
26522   return 0;
26523 }
26524 _ACEOF
26525 rm -f conftest.$ac_objext conftest$ac_exeext
26526 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26527   (eval $ac_link) 2>&5
26528   ac_status=$?
26529   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26530   (exit $ac_status); } &&
26531          { ac_try='test -s conftest$ac_exeext'
26532   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26533   (eval $ac_try) 2>&5
26534   ac_status=$?
26535   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26536   (exit $ac_status); }; }; then
26537   ac_cv_func_gdbm_open=yes
26538 else
26539   echo "$as_me: failed program was:" >&5
26540 sed 's/^/| /' conftest.$ac_ext >&5
26541
26542 ac_cv_func_gdbm_open=no
26543 fi
26544 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26545 fi
26546 echo "$as_me:$LINENO: result: $ac_cv_func_gdbm_open" >&5
26547 echo "${ECHO_T}$ac_cv_func_gdbm_open" >&6
26548 if test $ac_cv_func_gdbm_open = yes; then
26549   ol_cv_lib_gdbm=yes
26550 else
26551
26552                 echo "$as_me:$LINENO: checking for gdbm_open in -lgdbm" >&5
26553 echo $ECHO_N "checking for gdbm_open in -lgdbm... $ECHO_C" >&6
26554 if test "${ac_cv_lib_gdbm_gdbm_open+set}" = set; then
26555   echo $ECHO_N "(cached) $ECHO_C" >&6
26556 else
26557   ac_check_lib_save_LIBS=$LIBS
26558 LIBS="-lgdbm  $LIBS"
26559 cat >conftest.$ac_ext <<_ACEOF
26560 #line $LINENO "configure"
26561 /* confdefs.h.  */
26562 _ACEOF
26563 cat confdefs.h >>conftest.$ac_ext
26564 cat >>conftest.$ac_ext <<_ACEOF
26565 /* end confdefs.h.  */
26566
26567 /* Override any gcc2 internal prototype to avoid an error.  */
26568 #ifdef __cplusplus
26569 extern "C"
26570 #endif
26571 /* We use char because int might match the return type of a gcc2
26572    builtin and then its argument prototype would still apply.  */
26573 char gdbm_open ();
26574 int
26575 main ()
26576 {
26577 gdbm_open ();
26578   ;
26579   return 0;
26580 }
26581 _ACEOF
26582 rm -f conftest.$ac_objext conftest$ac_exeext
26583 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26584   (eval $ac_link) 2>&5
26585   ac_status=$?
26586   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26587   (exit $ac_status); } &&
26588          { ac_try='test -s conftest$ac_exeext'
26589   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26590   (eval $ac_try) 2>&5
26591   ac_status=$?
26592   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26593   (exit $ac_status); }; }; then
26594   ac_cv_lib_gdbm_gdbm_open=yes
26595 else
26596   echo "$as_me: failed program was:" >&5
26597 sed 's/^/| /' conftest.$ac_ext >&5
26598
26599 ac_cv_lib_gdbm_gdbm_open=no
26600 fi
26601 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26602 LIBS=$ac_check_lib_save_LIBS
26603 fi
26604 echo "$as_me:$LINENO: result: $ac_cv_lib_gdbm_gdbm_open" >&5
26605 echo "${ECHO_T}$ac_cv_lib_gdbm_gdbm_open" >&6
26606 if test $ac_cv_lib_gdbm_gdbm_open = yes; then
26607   ol_cv_lib_gdbm=-lgdbm
26608 else
26609   ol_cv_lib_gdbm=no
26610 fi
26611
26612
26613 fi
26614
26615         LIBS="$ol_LIBS"
26616
26617 fi
26618 echo "$as_me:$LINENO: result: $ol_cv_lib_gdbm" >&5
26619 echo "${ECHO_T}$ol_cv_lib_gdbm" >&6
26620
26621
26622
26623 for ac_header in gdbm.h
26624 do
26625 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26626 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26627   echo "$as_me:$LINENO: checking for $ac_header" >&5
26628 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26629 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26630   echo $ECHO_N "(cached) $ECHO_C" >&6
26631 fi
26632 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26633 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26634 else
26635   # Is the header compilable?
26636 echo "$as_me:$LINENO: checking $ac_header usability" >&5
26637 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
26638 cat >conftest.$ac_ext <<_ACEOF
26639 #line $LINENO "configure"
26640 /* confdefs.h.  */
26641 _ACEOF
26642 cat confdefs.h >>conftest.$ac_ext
26643 cat >>conftest.$ac_ext <<_ACEOF
26644 /* end confdefs.h.  */
26645 $ac_includes_default
26646 #include <$ac_header>
26647 _ACEOF
26648 rm -f conftest.$ac_objext
26649 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
26650   (eval $ac_compile) 2>&5
26651   ac_status=$?
26652   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26653   (exit $ac_status); } &&
26654          { ac_try='test -s conftest.$ac_objext'
26655   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26656   (eval $ac_try) 2>&5
26657   ac_status=$?
26658   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26659   (exit $ac_status); }; }; then
26660   ac_header_compiler=yes
26661 else
26662   echo "$as_me: failed program was:" >&5
26663 sed 's/^/| /' conftest.$ac_ext >&5
26664
26665 ac_header_compiler=no
26666 fi
26667 rm -f conftest.$ac_objext conftest.$ac_ext
26668 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26669 echo "${ECHO_T}$ac_header_compiler" >&6
26670
26671 # Is the header present?
26672 echo "$as_me:$LINENO: checking $ac_header presence" >&5
26673 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
26674 cat >conftest.$ac_ext <<_ACEOF
26675 #line $LINENO "configure"
26676 /* confdefs.h.  */
26677 _ACEOF
26678 cat confdefs.h >>conftest.$ac_ext
26679 cat >>conftest.$ac_ext <<_ACEOF
26680 /* end confdefs.h.  */
26681 #include <$ac_header>
26682 _ACEOF
26683 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
26684   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
26685   ac_status=$?
26686   grep -v '^ *+' conftest.er1 >conftest.err
26687   rm -f conftest.er1
26688   cat conftest.err >&5
26689   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26690   (exit $ac_status); } >/dev/null; then
26691   if test -s conftest.err; then
26692     ac_cpp_err=$ac_c_preproc_warn_flag
26693   else
26694     ac_cpp_err=
26695   fi
26696 else
26697   ac_cpp_err=yes
26698 fi
26699 if test -z "$ac_cpp_err"; then
26700   ac_header_preproc=yes
26701 else
26702   echo "$as_me: failed program was:" >&5
26703 sed 's/^/| /' conftest.$ac_ext >&5
26704
26705   ac_header_preproc=no
26706 fi
26707 rm -f conftest.err conftest.$ac_ext
26708 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26709 echo "${ECHO_T}$ac_header_preproc" >&6
26710
26711 # So?  What about this header?
26712 case $ac_header_compiler:$ac_header_preproc in
26713   yes:no )
26714     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
26715 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
26716     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26717 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26718     (
26719       cat <<\_ASBOX
26720 ## ------------------------------------ ##
26721 ## Report this to bug-autoconf@gnu.org. ##
26722 ## ------------------------------------ ##
26723 _ASBOX
26724     ) |
26725       sed "s/^/$as_me: WARNING:     /" >&2
26726     ;;
26727   no:yes )
26728     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
26729 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
26730     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
26731 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
26732     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
26733 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
26734     (
26735       cat <<\_ASBOX
26736 ## ------------------------------------ ##
26737 ## Report this to bug-autoconf@gnu.org. ##
26738 ## ------------------------------------ ##
26739 _ASBOX
26740     ) |
26741       sed "s/^/$as_me: WARNING:     /" >&2
26742     ;;
26743 esac
26744 echo "$as_me:$LINENO: checking for $ac_header" >&5
26745 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
26746 if eval "test \"\${$as_ac_Header+set}\" = set"; then
26747   echo $ECHO_N "(cached) $ECHO_C" >&6
26748 else
26749   eval "$as_ac_Header=$ac_header_preproc"
26750 fi
26751 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
26752 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
26753
26754 fi
26755 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26756   cat >>confdefs.h <<_ACEOF
26757 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26758 _ACEOF
26759
26760 fi
26761
26762 done
26763
26764  echo "$as_me:$LINENO: checking for db" >&5
26765 echo $ECHO_N "checking for db... $ECHO_C" >&6
26766 if test "${ol_cv_gdbm+set}" = set; then
26767   echo $ECHO_N "(cached) $ECHO_C" >&6
26768 else
26769
26770         if test $ol_cv_lib_gdbm = no -o $ac_cv_header_gdbm_h = no ; then
26771                 ol_cv_gdbm=no
26772         else
26773                 ol_cv_gdbm=yes
26774         fi
26775
26776 fi
26777 echo "$as_me:$LINENO: result: $ol_cv_gdbm" >&5
26778 echo "${ECHO_T}$ol_cv_gdbm" >&6
26779  if test $ol_cv_gdbm = yes ; then
26780
26781 cat >>confdefs.h <<\_ACEOF
26782 #define HAVE_GDBM 1
26783 _ACEOF
26784
26785  fi
26786
26787
26788         if test $ol_cv_gdbm = yes ; then
26789                 ol_link_ldbm=gdbm
26790                 ol_with_ldbm_api=gdbm
26791
26792                 if test $ol_cv_lib_gdbm != yes ; then
26793                         LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_gdbm"
26794                 fi
26795         fi
26796 fi
26797
26798 if test $ol_with_ldbm_api = ndbm ; then
26799         echo "$as_me:$LINENO: checking for NDBM library" >&5
26800 echo $ECHO_N "checking for NDBM library... $ECHO_C" >&6
26801 if test "${ol_cv_lib_ndbm+set}" = set; then
26802   echo $ECHO_N "(cached) $ECHO_C" >&6
26803 else
26804         ol_LIBS="$LIBS"
26805         echo "$as_me:$LINENO: checking for dbm_open" >&5
26806 echo $ECHO_N "checking for dbm_open... $ECHO_C" >&6
26807 if test "${ac_cv_func_dbm_open+set}" = set; then
26808   echo $ECHO_N "(cached) $ECHO_C" >&6
26809 else
26810   cat >conftest.$ac_ext <<_ACEOF
26811 #line $LINENO "configure"
26812 /* confdefs.h.  */
26813 _ACEOF
26814 cat confdefs.h >>conftest.$ac_ext
26815 cat >>conftest.$ac_ext <<_ACEOF
26816 /* end confdefs.h.  */
26817 /* System header to define __stub macros and hopefully few prototypes,
26818     which can conflict with char dbm_open (); below.
26819     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
26820     <limits.h> exists even on freestanding compilers.  */
26821 #ifdef __STDC__
26822 # include <limits.h>
26823 #else
26824 # include <assert.h>
26825 #endif
26826 /* Override any gcc2 internal prototype to avoid an error.  */
26827 #ifdef __cplusplus
26828 extern "C"
26829 {
26830 #endif
26831 /* We use char because int might match the return type of a gcc2
26832    builtin and then its argument prototype would still apply.  */
26833 char dbm_open ();
26834 /* The GNU C library defines this for functions which it implements
26835     to always fail with ENOSYS.  Some functions are actually named
26836     something starting with __ and the normal name is an alias.  */
26837 #if defined (__stub_dbm_open) || defined (__stub___dbm_open)
26838 choke me
26839 #else
26840 char (*f) () = dbm_open;
26841 #endif
26842 #ifdef __cplusplus
26843 }
26844 #endif
26845
26846 int
26847 main ()
26848 {
26849 return f != dbm_open;
26850   ;
26851   return 0;
26852 }
26853 _ACEOF
26854 rm -f conftest.$ac_objext conftest$ac_exeext
26855 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26856   (eval $ac_link) 2>&5
26857   ac_status=$?
26858   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26859   (exit $ac_status); } &&
26860          { ac_try='test -s conftest$ac_exeext'
26861   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26862   (eval $ac_try) 2>&5
26863   ac_status=$?
26864   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26865   (exit $ac_status); }; }; then
26866   ac_cv_func_dbm_open=yes
26867 else
26868   echo "$as_me: failed program was:" >&5
26869 sed 's/^/| /' conftest.$ac_ext >&5
26870
26871 ac_cv_func_dbm_open=no
26872 fi
26873 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26874 fi
26875 echo "$as_me:$LINENO: result: $ac_cv_func_dbm_open" >&5
26876 echo "${ECHO_T}$ac_cv_func_dbm_open" >&6
26877 if test $ac_cv_func_dbm_open = yes; then
26878   ol_cv_lib_ndbm=yes
26879 else
26880
26881                 echo "$as_me:$LINENO: checking for dbm_open in -lndbm" >&5
26882 echo $ECHO_N "checking for dbm_open in -lndbm... $ECHO_C" >&6
26883 if test "${ac_cv_lib_ndbm_dbm_open+set}" = set; then
26884   echo $ECHO_N "(cached) $ECHO_C" >&6
26885 else
26886   ac_check_lib_save_LIBS=$LIBS
26887 LIBS="-lndbm  $LIBS"
26888 cat >conftest.$ac_ext <<_ACEOF
26889 #line $LINENO "configure"
26890 /* confdefs.h.  */
26891 _ACEOF
26892 cat confdefs.h >>conftest.$ac_ext
26893 cat >>conftest.$ac_ext <<_ACEOF
26894 /* end confdefs.h.  */
26895
26896 /* Override any gcc2 internal prototype to avoid an error.  */
26897 #ifdef __cplusplus
26898 extern "C"
26899 #endif
26900 /* We use char because int might match the return type of a gcc2
26901    builtin and then its argument prototype would still apply.  */
26902 char dbm_open ();
26903 int
26904 main ()
26905 {
26906 dbm_open ();
26907   ;
26908   return 0;
26909 }
26910 _ACEOF
26911 rm -f conftest.$ac_objext conftest$ac_exeext
26912 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26913   (eval $ac_link) 2>&5
26914   ac_status=$?
26915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26916   (exit $ac_status); } &&
26917          { ac_try='test -s conftest$ac_exeext'
26918   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26919   (eval $ac_try) 2>&5
26920   ac_status=$?
26921   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26922   (exit $ac_status); }; }; then
26923   ac_cv_lib_ndbm_dbm_open=yes
26924 else
26925   echo "$as_me: failed program was:" >&5
26926 sed 's/^/| /' conftest.$ac_ext >&5
26927
26928 ac_cv_lib_ndbm_dbm_open=no
26929 fi
26930 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26931 LIBS=$ac_check_lib_save_LIBS
26932 fi
26933 echo "$as_me:$LINENO: result: $ac_cv_lib_ndbm_dbm_open" >&5
26934 echo "${ECHO_T}$ac_cv_lib_ndbm_dbm_open" >&6
26935 if test $ac_cv_lib_ndbm_dbm_open = yes; then
26936   ol_cv_lib_ndbm=-lndbm
26937 else
26938
26939                         echo "$as_me:$LINENO: checking for dbm_open in -ldbm" >&5
26940 echo $ECHO_N "checking for dbm_open in -ldbm... $ECHO_C" >&6
26941 if test "${ac_cv_lib_dbm_dbm_open+set}" = set; then
26942   echo $ECHO_N "(cached) $ECHO_C" >&6
26943 else
26944   ac_check_lib_save_LIBS=$LIBS
26945 LIBS="-ldbm  $LIBS"
26946 cat >conftest.$ac_ext <<_ACEOF
26947 #line $LINENO "configure"
26948 /* confdefs.h.  */
26949 _ACEOF
26950 cat confdefs.h >>conftest.$ac_ext
26951 cat >>conftest.$ac_ext <<_ACEOF
26952 /* end confdefs.h.  */
26953
26954 /* Override any gcc2 internal prototype to avoid an error.  */
26955 #ifdef __cplusplus
26956 extern "C"
26957 #endif
26958 /* We use char because int might match the return type of a gcc2
26959    builtin and then its argument prototype would still apply.  */
26960 char dbm_open ();
26961 int
26962 main ()
26963 {
26964 dbm_open ();
26965   ;
26966   return 0;
26967 }
26968 _ACEOF
26969 rm -f conftest.$ac_objext conftest$ac_exeext
26970 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
26971   (eval $ac_link) 2>&5
26972   ac_status=$?
26973   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26974   (exit $ac_status); } &&
26975          { ac_try='test -s conftest$ac_exeext'
26976   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
26977   (eval $ac_try) 2>&5
26978   ac_status=$?
26979   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26980   (exit $ac_status); }; }; then
26981   ac_cv_lib_dbm_dbm_open=yes
26982 else
26983   echo "$as_me: failed program was:" >&5
26984 sed 's/^/| /' conftest.$ac_ext >&5
26985
26986 ac_cv_lib_dbm_dbm_open=no
26987 fi
26988 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
26989 LIBS=$ac_check_lib_save_LIBS
26990 fi
26991 echo "$as_me:$LINENO: result: $ac_cv_lib_dbm_dbm_open" >&5
26992 echo "${ECHO_T}$ac_cv_lib_dbm_dbm_open" >&6
26993 if test $ac_cv_lib_dbm_dbm_open = yes; then
26994   ol_cv_lib_ndbm=-ldbm
26995 else
26996   ol_cv_lib_ndbm=no
26997 fi
26998
26999 fi
27000
27001
27002 fi
27003
27004         LIBS="$ol_LIBS"
27005
27006 fi
27007 echo "$as_me:$LINENO: result: $ol_cv_lib_ndbm" >&5
27008 echo "${ECHO_T}$ol_cv_lib_ndbm" >&6
27009
27010
27011
27012 for ac_header in ndbm.h
27013 do
27014 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
27015 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27016   echo "$as_me:$LINENO: checking for $ac_header" >&5
27017 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27018 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27019   echo $ECHO_N "(cached) $ECHO_C" >&6
27020 fi
27021 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27022 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27023 else
27024   # Is the header compilable?
27025 echo "$as_me:$LINENO: checking $ac_header usability" >&5
27026 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
27027 cat >conftest.$ac_ext <<_ACEOF
27028 #line $LINENO "configure"
27029 /* confdefs.h.  */
27030 _ACEOF
27031 cat confdefs.h >>conftest.$ac_ext
27032 cat >>conftest.$ac_ext <<_ACEOF
27033 /* end confdefs.h.  */
27034 $ac_includes_default
27035 #include <$ac_header>
27036 _ACEOF
27037 rm -f conftest.$ac_objext
27038 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27039   (eval $ac_compile) 2>&5
27040   ac_status=$?
27041   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27042   (exit $ac_status); } &&
27043          { ac_try='test -s conftest.$ac_objext'
27044   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27045   (eval $ac_try) 2>&5
27046   ac_status=$?
27047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27048   (exit $ac_status); }; }; then
27049   ac_header_compiler=yes
27050 else
27051   echo "$as_me: failed program was:" >&5
27052 sed 's/^/| /' conftest.$ac_ext >&5
27053
27054 ac_header_compiler=no
27055 fi
27056 rm -f conftest.$ac_objext conftest.$ac_ext
27057 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
27058 echo "${ECHO_T}$ac_header_compiler" >&6
27059
27060 # Is the header present?
27061 echo "$as_me:$LINENO: checking $ac_header presence" >&5
27062 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
27063 cat >conftest.$ac_ext <<_ACEOF
27064 #line $LINENO "configure"
27065 /* confdefs.h.  */
27066 _ACEOF
27067 cat confdefs.h >>conftest.$ac_ext
27068 cat >>conftest.$ac_ext <<_ACEOF
27069 /* end confdefs.h.  */
27070 #include <$ac_header>
27071 _ACEOF
27072 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
27073   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
27074   ac_status=$?
27075   grep -v '^ *+' conftest.er1 >conftest.err
27076   rm -f conftest.er1
27077   cat conftest.err >&5
27078   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27079   (exit $ac_status); } >/dev/null; then
27080   if test -s conftest.err; then
27081     ac_cpp_err=$ac_c_preproc_warn_flag
27082   else
27083     ac_cpp_err=
27084   fi
27085 else
27086   ac_cpp_err=yes
27087 fi
27088 if test -z "$ac_cpp_err"; then
27089   ac_header_preproc=yes
27090 else
27091   echo "$as_me: failed program was:" >&5
27092 sed 's/^/| /' conftest.$ac_ext >&5
27093
27094   ac_header_preproc=no
27095 fi
27096 rm -f conftest.err conftest.$ac_ext
27097 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
27098 echo "${ECHO_T}$ac_header_preproc" >&6
27099
27100 # So?  What about this header?
27101 case $ac_header_compiler:$ac_header_preproc in
27102   yes:no )
27103     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
27104 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
27105     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27106 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27107     (
27108       cat <<\_ASBOX
27109 ## ------------------------------------ ##
27110 ## Report this to bug-autoconf@gnu.org. ##
27111 ## ------------------------------------ ##
27112 _ASBOX
27113     ) |
27114       sed "s/^/$as_me: WARNING:     /" >&2
27115     ;;
27116   no:yes )
27117     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
27118 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
27119     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
27120 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
27121     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27122 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27123     (
27124       cat <<\_ASBOX
27125 ## ------------------------------------ ##
27126 ## Report this to bug-autoconf@gnu.org. ##
27127 ## ------------------------------------ ##
27128 _ASBOX
27129     ) |
27130       sed "s/^/$as_me: WARNING:     /" >&2
27131     ;;
27132 esac
27133 echo "$as_me:$LINENO: checking for $ac_header" >&5
27134 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27135 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27136   echo $ECHO_N "(cached) $ECHO_C" >&6
27137 else
27138   eval "$as_ac_Header=$ac_header_preproc"
27139 fi
27140 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27141 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27142
27143 fi
27144 if test `eval echo '${'$as_ac_Header'}'` = yes; then
27145   cat >>confdefs.h <<_ACEOF
27146 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
27147 _ACEOF
27148
27149 fi
27150
27151 done
27152
27153  echo "$as_me:$LINENO: checking for db" >&5
27154 echo $ECHO_N "checking for db... $ECHO_C" >&6
27155 if test "${ol_cv_ndbm+set}" = set; then
27156   echo $ECHO_N "(cached) $ECHO_C" >&6
27157 else
27158
27159         if test $ol_cv_lib_ndbm = no -o $ac_cv_header_ndbm_h = no ; then
27160                 ol_cv_ndbm=no
27161         else
27162                 ol_cv_ndbm=yes
27163         fi
27164
27165 fi
27166 echo "$as_me:$LINENO: result: $ol_cv_ndbm" >&5
27167 echo "${ECHO_T}$ol_cv_ndbm" >&6
27168  if test $ol_cv_ndbm = yes ; then
27169
27170 cat >>confdefs.h <<\_ACEOF
27171 #define HAVE_NDBM 1
27172 _ACEOF
27173
27174  fi
27175
27176
27177         if test $ol_cv_ndbm = yes ; then
27178                 ol_link_ldbm=ndbm
27179                 ol_with_ldbm_api=ndbm
27180
27181                 if test $ol_cv_lib_ndbm != yes ; then
27182                         LDBM_LIBS="$LDBM_LIBS $ol_cv_lib_ndbm"
27183                 fi
27184         fi
27185 fi
27186
27187 if test $ol_link_ldbm = no -a $ol_enable_ldbm != no ; then
27188         { echo "$as_me:$LINENO: WARNING: could not find suitable LDBM backend" >&5
27189 echo "$as_me: WARNING: could not find suitable LDBM backend" >&2;}
27190         if test $ol_enable_ldbm = yes ; then
27191                 { { echo "$as_me:$LINENO: error: select appropriate LDBM options or disable" >&5
27192 echo "$as_me: error: select appropriate LDBM options or disable" >&2;}
27193    { (exit 1); exit 1; }; }
27194         fi
27195
27196         { echo "$as_me:$LINENO: WARNING: disabling LDBM" >&5
27197 echo "$as_me: WARNING: disabling LDBM" >&2;}
27198         ol_enable_ldbm=no
27199 fi
27200
27201
27202 if test $ol_enable_dynamic = yes -a $enable_shared = yes ; then
27203         BUILD_LIBS_DYNAMIC=shared
27204
27205 cat >>confdefs.h <<\_ACEOF
27206 #define LDAP_LIBS_DYNAMIC 1
27207 _ACEOF
27208
27209         LTSTATIC=""
27210 else
27211         BUILD_LIBS_DYNAMIC=static
27212         LTSTATIC="-static"
27213 fi
27214
27215 if test $ol_enable_wrappers != no ; then
27216
27217 for ac_header in tcpd.h
27218 do
27219 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
27220 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27221   echo "$as_me:$LINENO: checking for $ac_header" >&5
27222 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27223 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27224   echo $ECHO_N "(cached) $ECHO_C" >&6
27225 fi
27226 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27227 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27228 else
27229   # Is the header compilable?
27230 echo "$as_me:$LINENO: checking $ac_header usability" >&5
27231 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
27232 cat >conftest.$ac_ext <<_ACEOF
27233 #line $LINENO "configure"
27234 /* confdefs.h.  */
27235 _ACEOF
27236 cat confdefs.h >>conftest.$ac_ext
27237 cat >>conftest.$ac_ext <<_ACEOF
27238 /* end confdefs.h.  */
27239 $ac_includes_default
27240 #include <$ac_header>
27241 _ACEOF
27242 rm -f conftest.$ac_objext
27243 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27244   (eval $ac_compile) 2>&5
27245   ac_status=$?
27246   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27247   (exit $ac_status); } &&
27248          { ac_try='test -s conftest.$ac_objext'
27249   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27250   (eval $ac_try) 2>&5
27251   ac_status=$?
27252   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27253   (exit $ac_status); }; }; then
27254   ac_header_compiler=yes
27255 else
27256   echo "$as_me: failed program was:" >&5
27257 sed 's/^/| /' conftest.$ac_ext >&5
27258
27259 ac_header_compiler=no
27260 fi
27261 rm -f conftest.$ac_objext conftest.$ac_ext
27262 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
27263 echo "${ECHO_T}$ac_header_compiler" >&6
27264
27265 # Is the header present?
27266 echo "$as_me:$LINENO: checking $ac_header presence" >&5
27267 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
27268 cat >conftest.$ac_ext <<_ACEOF
27269 #line $LINENO "configure"
27270 /* confdefs.h.  */
27271 _ACEOF
27272 cat confdefs.h >>conftest.$ac_ext
27273 cat >>conftest.$ac_ext <<_ACEOF
27274 /* end confdefs.h.  */
27275 #include <$ac_header>
27276 _ACEOF
27277 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
27278   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
27279   ac_status=$?
27280   grep -v '^ *+' conftest.er1 >conftest.err
27281   rm -f conftest.er1
27282   cat conftest.err >&5
27283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27284   (exit $ac_status); } >/dev/null; then
27285   if test -s conftest.err; then
27286     ac_cpp_err=$ac_c_preproc_warn_flag
27287   else
27288     ac_cpp_err=
27289   fi
27290 else
27291   ac_cpp_err=yes
27292 fi
27293 if test -z "$ac_cpp_err"; then
27294   ac_header_preproc=yes
27295 else
27296   echo "$as_me: failed program was:" >&5
27297 sed 's/^/| /' conftest.$ac_ext >&5
27298
27299   ac_header_preproc=no
27300 fi
27301 rm -f conftest.err conftest.$ac_ext
27302 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
27303 echo "${ECHO_T}$ac_header_preproc" >&6
27304
27305 # So?  What about this header?
27306 case $ac_header_compiler:$ac_header_preproc in
27307   yes:no )
27308     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
27309 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
27310     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27311 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27312     (
27313       cat <<\_ASBOX
27314 ## ------------------------------------ ##
27315 ## Report this to bug-autoconf@gnu.org. ##
27316 ## ------------------------------------ ##
27317 _ASBOX
27318     ) |
27319       sed "s/^/$as_me: WARNING:     /" >&2
27320     ;;
27321   no:yes )
27322     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
27323 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
27324     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
27325 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
27326     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27327 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27328     (
27329       cat <<\_ASBOX
27330 ## ------------------------------------ ##
27331 ## Report this to bug-autoconf@gnu.org. ##
27332 ## ------------------------------------ ##
27333 _ASBOX
27334     ) |
27335       sed "s/^/$as_me: WARNING:     /" >&2
27336     ;;
27337 esac
27338 echo "$as_me:$LINENO: checking for $ac_header" >&5
27339 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27340 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27341   echo $ECHO_N "(cached) $ECHO_C" >&6
27342 else
27343   eval "$as_ac_Header=$ac_header_preproc"
27344 fi
27345 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27346 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27347
27348 fi
27349 if test `eval echo '${'$as_ac_Header'}'` = yes; then
27350   cat >>confdefs.h <<_ACEOF
27351 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
27352 _ACEOF
27353
27354                 echo "$as_me:$LINENO: checking for TCP wrappers library" >&5
27355 echo $ECHO_N "checking for TCP wrappers library... $ECHO_C" >&6
27356                 save_LIBS="$LIBS"
27357                 LIBS="$LIBS -lwrap"
27358                 cat >conftest.$ac_ext <<_ACEOF
27359 #line $LINENO "configure"
27360 /* confdefs.h.  */
27361 _ACEOF
27362 cat confdefs.h >>conftest.$ac_ext
27363 cat >>conftest.$ac_ext <<_ACEOF
27364 /* end confdefs.h.  */
27365
27366 #include <tcpd.h>
27367 int allow_severity = 0;
27368 int deny_severity  = 0;
27369
27370 struct request_info *req;
27371
27372 int
27373 main ()
27374 {
27375
27376 hosts_access(req)
27377
27378   ;
27379   return 0;
27380 }
27381 _ACEOF
27382 rm -f conftest.$ac_objext conftest$ac_exeext
27383 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27384   (eval $ac_link) 2>&5
27385   ac_status=$?
27386   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27387   (exit $ac_status); } &&
27388          { ac_try='test -s conftest$ac_exeext'
27389   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27390   (eval $ac_try) 2>&5
27391   ac_status=$?
27392   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27393   (exit $ac_status); }; }; then
27394   echo "$as_me:$LINENO: result: -lwrap" >&5
27395 echo "${ECHO_T}-lwrap" >&6
27396                 have_wrappers=yes
27397                 LIBS="$save_LIBS"
27398 else
27399   echo "$as_me: failed program was:" >&5
27400 sed 's/^/| /' conftest.$ac_ext >&5
27401
27402
27403                                 LIBS="$LIBS -lnsl"
27404                 cat >conftest.$ac_ext <<_ACEOF
27405 #line $LINENO "configure"
27406 /* confdefs.h.  */
27407 _ACEOF
27408 cat confdefs.h >>conftest.$ac_ext
27409 cat >>conftest.$ac_ext <<_ACEOF
27410 /* end confdefs.h.  */
27411
27412 #include <tcpd.h>
27413 int allow_severity = 0;
27414 int deny_severity  = 0;
27415
27416 struct request_info *req;
27417
27418 int
27419 main ()
27420 {
27421
27422 hosts_access(req)
27423
27424   ;
27425   return 0;
27426 }
27427 _ACEOF
27428 rm -f conftest.$ac_objext conftest$ac_exeext
27429 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27430   (eval $ac_link) 2>&5
27431   ac_status=$?
27432   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27433   (exit $ac_status); } &&
27434          { ac_try='test -s conftest$ac_exeext'
27435   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27436   (eval $ac_try) 2>&5
27437   ac_status=$?
27438   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27439   (exit $ac_status); }; }; then
27440   echo "$as_me:$LINENO: result: -lwrap -lnsl" >&5
27441 echo "${ECHO_T}-lwrap -lnsl" >&6
27442                 have_wrappers=yes
27443                 LIBS="$save_LIBS -lnsl"
27444 else
27445   echo "$as_me: failed program was:" >&5
27446 sed 's/^/| /' conftest.$ac_ext >&5
27447
27448
27449                 echo "$as_me:$LINENO: result: no" >&5
27450 echo "${ECHO_T}no" >&6
27451                 have_wrappers=no
27452                 LIBS=$save_LIBS
27453 fi
27454 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
27455 fi
27456 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
27457 else
27458   have_wrappers=no
27459 fi
27460
27461 done
27462
27463
27464         if test $have_wrappers = yes ; then
27465
27466 cat >>confdefs.h <<\_ACEOF
27467 #define HAVE_TCPD 1
27468 _ACEOF
27469
27470                 WRAP_LIBS="-lwrap"
27471         elif test $ol_enable_wrappers = yes ; then
27472                 { { echo "$as_me:$LINENO: error: could not find TCP wrappers, select apppropriate options ore disable" >&5
27473 echo "$as_me: error: could not find TCP wrappers, select apppropriate options ore disable" >&2;}
27474    { (exit 1); exit 1; }; }
27475         else
27476                 { echo "$as_me:$LINENO: WARNING: could not find TCP wrappers, support disabled" >&5
27477 echo "$as_me: WARNING: could not find TCP wrappers, support disabled" >&2;}
27478                 WRAP_LIBS=""
27479         fi
27480 fi
27481
27482 if test $ol_enable_syslog != no ; then
27483         echo "$as_me:$LINENO: checking for openlog" >&5
27484 echo $ECHO_N "checking for openlog... $ECHO_C" >&6
27485 if test "${ac_cv_func_openlog+set}" = set; then
27486   echo $ECHO_N "(cached) $ECHO_C" >&6
27487 else
27488   cat >conftest.$ac_ext <<_ACEOF
27489 #line $LINENO "configure"
27490 /* confdefs.h.  */
27491 _ACEOF
27492 cat confdefs.h >>conftest.$ac_ext
27493 cat >>conftest.$ac_ext <<_ACEOF
27494 /* end confdefs.h.  */
27495 /* System header to define __stub macros and hopefully few prototypes,
27496     which can conflict with char openlog (); below.
27497     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
27498     <limits.h> exists even on freestanding compilers.  */
27499 #ifdef __STDC__
27500 # include <limits.h>
27501 #else
27502 # include <assert.h>
27503 #endif
27504 /* Override any gcc2 internal prototype to avoid an error.  */
27505 #ifdef __cplusplus
27506 extern "C"
27507 {
27508 #endif
27509 /* We use char because int might match the return type of a gcc2
27510    builtin and then its argument prototype would still apply.  */
27511 char openlog ();
27512 /* The GNU C library defines this for functions which it implements
27513     to always fail with ENOSYS.  Some functions are actually named
27514     something starting with __ and the normal name is an alias.  */
27515 #if defined (__stub_openlog) || defined (__stub___openlog)
27516 choke me
27517 #else
27518 char (*f) () = openlog;
27519 #endif
27520 #ifdef __cplusplus
27521 }
27522 #endif
27523
27524 int
27525 main ()
27526 {
27527 return f != openlog;
27528   ;
27529   return 0;
27530 }
27531 _ACEOF
27532 rm -f conftest.$ac_objext conftest$ac_exeext
27533 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27534   (eval $ac_link) 2>&5
27535   ac_status=$?
27536   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27537   (exit $ac_status); } &&
27538          { ac_try='test -s conftest$ac_exeext'
27539   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27540   (eval $ac_try) 2>&5
27541   ac_status=$?
27542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27543   (exit $ac_status); }; }; then
27544   ac_cv_func_openlog=yes
27545 else
27546   echo "$as_me: failed program was:" >&5
27547 sed 's/^/| /' conftest.$ac_ext >&5
27548
27549 ac_cv_func_openlog=no
27550 fi
27551 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
27552 fi
27553 echo "$as_me:$LINENO: result: $ac_cv_func_openlog" >&5
27554 echo "${ECHO_T}$ac_cv_func_openlog" >&6
27555
27556         if test $ac_cv_func_openlog = no -a $ol_enable_syslog = yes; then
27557                 { { echo "$as_me:$LINENO: error: could not find syslog" >&5
27558 echo "$as_me: error: could not find syslog" >&2;}
27559    { (exit select appropriate options or disable); exit select appropriate options or disable; }; }
27560         fi
27561         ol_enable_syslog=$ac_cv_func_openlog
27562 fi
27563
27564
27565 ol_link_sql=no
27566 if test $ol_enable_sql != no ; then
27567
27568
27569 for ac_header in sql.h sqlext.h
27570 do
27571 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
27572 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27573   echo "$as_me:$LINENO: checking for $ac_header" >&5
27574 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27575 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27576   echo $ECHO_N "(cached) $ECHO_C" >&6
27577 fi
27578 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27579 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27580 else
27581   # Is the header compilable?
27582 echo "$as_me:$LINENO: checking $ac_header usability" >&5
27583 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
27584 cat >conftest.$ac_ext <<_ACEOF
27585 #line $LINENO "configure"
27586 /* confdefs.h.  */
27587 _ACEOF
27588 cat confdefs.h >>conftest.$ac_ext
27589 cat >>conftest.$ac_ext <<_ACEOF
27590 /* end confdefs.h.  */
27591 $ac_includes_default
27592 #include <$ac_header>
27593 _ACEOF
27594 rm -f conftest.$ac_objext
27595 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27596   (eval $ac_compile) 2>&5
27597   ac_status=$?
27598   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27599   (exit $ac_status); } &&
27600          { ac_try='test -s conftest.$ac_objext'
27601   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27602   (eval $ac_try) 2>&5
27603   ac_status=$?
27604   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27605   (exit $ac_status); }; }; then
27606   ac_header_compiler=yes
27607 else
27608   echo "$as_me: failed program was:" >&5
27609 sed 's/^/| /' conftest.$ac_ext >&5
27610
27611 ac_header_compiler=no
27612 fi
27613 rm -f conftest.$ac_objext conftest.$ac_ext
27614 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
27615 echo "${ECHO_T}$ac_header_compiler" >&6
27616
27617 # Is the header present?
27618 echo "$as_me:$LINENO: checking $ac_header presence" >&5
27619 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
27620 cat >conftest.$ac_ext <<_ACEOF
27621 #line $LINENO "configure"
27622 /* confdefs.h.  */
27623 _ACEOF
27624 cat confdefs.h >>conftest.$ac_ext
27625 cat >>conftest.$ac_ext <<_ACEOF
27626 /* end confdefs.h.  */
27627 #include <$ac_header>
27628 _ACEOF
27629 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
27630   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
27631   ac_status=$?
27632   grep -v '^ *+' conftest.er1 >conftest.err
27633   rm -f conftest.er1
27634   cat conftest.err >&5
27635   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27636   (exit $ac_status); } >/dev/null; then
27637   if test -s conftest.err; then
27638     ac_cpp_err=$ac_c_preproc_warn_flag
27639   else
27640     ac_cpp_err=
27641   fi
27642 else
27643   ac_cpp_err=yes
27644 fi
27645 if test -z "$ac_cpp_err"; then
27646   ac_header_preproc=yes
27647 else
27648   echo "$as_me: failed program was:" >&5
27649 sed 's/^/| /' conftest.$ac_ext >&5
27650
27651   ac_header_preproc=no
27652 fi
27653 rm -f conftest.err conftest.$ac_ext
27654 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
27655 echo "${ECHO_T}$ac_header_preproc" >&6
27656
27657 # So?  What about this header?
27658 case $ac_header_compiler:$ac_header_preproc in
27659   yes:no )
27660     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
27661 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
27662     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27663 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27664     (
27665       cat <<\_ASBOX
27666 ## ------------------------------------ ##
27667 ## Report this to bug-autoconf@gnu.org. ##
27668 ## ------------------------------------ ##
27669 _ASBOX
27670     ) |
27671       sed "s/^/$as_me: WARNING:     /" >&2
27672     ;;
27673   no:yes )
27674     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
27675 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
27676     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
27677 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
27678     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27679 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27680     (
27681       cat <<\_ASBOX
27682 ## ------------------------------------ ##
27683 ## Report this to bug-autoconf@gnu.org. ##
27684 ## ------------------------------------ ##
27685 _ASBOX
27686     ) |
27687       sed "s/^/$as_me: WARNING:     /" >&2
27688     ;;
27689 esac
27690 echo "$as_me:$LINENO: checking for $ac_header" >&5
27691 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27692 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27693   echo $ECHO_N "(cached) $ECHO_C" >&6
27694 else
27695   eval "$as_ac_Header=$ac_header_preproc"
27696 fi
27697 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27698 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27699
27700 fi
27701 if test `eval echo '${'$as_ac_Header'}'` = yes; then
27702   cat >>confdefs.h <<_ACEOF
27703 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
27704 _ACEOF
27705
27706 else
27707
27708                 { { echo "$as_me:$LINENO: error: could not locate SQL headers" >&5
27709 echo "$as_me: error: could not locate SQL headers" >&2;}
27710    { (exit 1); exit 1; }; }
27711
27712 fi
27713
27714 done
27715
27716
27717         echo "$as_me:$LINENO: checking for SQLDriverConnect in -liodbc" >&5
27718 echo $ECHO_N "checking for SQLDriverConnect in -liodbc... $ECHO_C" >&6
27719 if test "${ac_cv_lib_iodbc_SQLDriverConnect+set}" = set; then
27720   echo $ECHO_N "(cached) $ECHO_C" >&6
27721 else
27722   ac_check_lib_save_LIBS=$LIBS
27723 LIBS="-liodbc  $LIBS"
27724 cat >conftest.$ac_ext <<_ACEOF
27725 #line $LINENO "configure"
27726 /* confdefs.h.  */
27727 _ACEOF
27728 cat confdefs.h >>conftest.$ac_ext
27729 cat >>conftest.$ac_ext <<_ACEOF
27730 /* end confdefs.h.  */
27731
27732 /* Override any gcc2 internal prototype to avoid an error.  */
27733 #ifdef __cplusplus
27734 extern "C"
27735 #endif
27736 /* We use char because int might match the return type of a gcc2
27737    builtin and then its argument prototype would still apply.  */
27738 char SQLDriverConnect ();
27739 int
27740 main ()
27741 {
27742 SQLDriverConnect ();
27743   ;
27744   return 0;
27745 }
27746 _ACEOF
27747 rm -f conftest.$ac_objext conftest$ac_exeext
27748 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27749   (eval $ac_link) 2>&5
27750   ac_status=$?
27751   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27752   (exit $ac_status); } &&
27753          { ac_try='test -s conftest$ac_exeext'
27754   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27755   (eval $ac_try) 2>&5
27756   ac_status=$?
27757   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27758   (exit $ac_status); }; }; then
27759   ac_cv_lib_iodbc_SQLDriverConnect=yes
27760 else
27761   echo "$as_me: failed program was:" >&5
27762 sed 's/^/| /' conftest.$ac_ext >&5
27763
27764 ac_cv_lib_iodbc_SQLDriverConnect=no
27765 fi
27766 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
27767 LIBS=$ac_check_lib_save_LIBS
27768 fi
27769 echo "$as_me:$LINENO: result: $ac_cv_lib_iodbc_SQLDriverConnect" >&5
27770 echo "${ECHO_T}$ac_cv_lib_iodbc_SQLDriverConnect" >&6
27771 if test $ac_cv_lib_iodbc_SQLDriverConnect = yes; then
27772   have_iodbc=yes
27773 else
27774   have_iodbc=no
27775 fi
27776
27777         if test $have_iodbc = yes ; then
27778                 ol_link_sql="-liodbc"
27779         else
27780                 echo "$as_me:$LINENO: checking for SQLDriverConnect in -lodbc" >&5
27781 echo $ECHO_N "checking for SQLDriverConnect in -lodbc... $ECHO_C" >&6
27782 if test "${ac_cv_lib_odbc_SQLDriverConnect+set}" = set; then
27783   echo $ECHO_N "(cached) $ECHO_C" >&6
27784 else
27785   ac_check_lib_save_LIBS=$LIBS
27786 LIBS="-lodbc  $LIBS"
27787 cat >conftest.$ac_ext <<_ACEOF
27788 #line $LINENO "configure"
27789 /* confdefs.h.  */
27790 _ACEOF
27791 cat confdefs.h >>conftest.$ac_ext
27792 cat >>conftest.$ac_ext <<_ACEOF
27793 /* end confdefs.h.  */
27794
27795 /* Override any gcc2 internal prototype to avoid an error.  */
27796 #ifdef __cplusplus
27797 extern "C"
27798 #endif
27799 /* We use char because int might match the return type of a gcc2
27800    builtin and then its argument prototype would still apply.  */
27801 char SQLDriverConnect ();
27802 int
27803 main ()
27804 {
27805 SQLDriverConnect ();
27806   ;
27807   return 0;
27808 }
27809 _ACEOF
27810 rm -f conftest.$ac_objext conftest$ac_exeext
27811 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
27812   (eval $ac_link) 2>&5
27813   ac_status=$?
27814   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27815   (exit $ac_status); } &&
27816          { ac_try='test -s conftest$ac_exeext'
27817   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27818   (eval $ac_try) 2>&5
27819   ac_status=$?
27820   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27821   (exit $ac_status); }; }; then
27822   ac_cv_lib_odbc_SQLDriverConnect=yes
27823 else
27824   echo "$as_me: failed program was:" >&5
27825 sed 's/^/| /' conftest.$ac_ext >&5
27826
27827 ac_cv_lib_odbc_SQLDriverConnect=no
27828 fi
27829 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
27830 LIBS=$ac_check_lib_save_LIBS
27831 fi
27832 echo "$as_me:$LINENO: result: $ac_cv_lib_odbc_SQLDriverConnect" >&5
27833 echo "${ECHO_T}$ac_cv_lib_odbc_SQLDriverConnect" >&6
27834 if test $ac_cv_lib_odbc_SQLDriverConnect = yes; then
27835   have_odbc=yes
27836 else
27837   have_odbc=no
27838 fi
27839
27840                 if test $have_odbc = yes ; then
27841                         ol_link_sql="-lodbc"
27842                 fi
27843         fi
27844
27845         if test $ol_link_sql != no ; then
27846                 SLAPD_SQL_LIBS="$ol_link_sql"
27847
27848         elif test $ol_enable_sql != auto ; then
27849                 { { echo "$as_me:$LINENO: error: could not locate suitable ODBC library" >&5
27850 echo "$as_me: error: could not locate suitable ODBC library" >&2;}
27851    { (exit 1); exit 1; }; }
27852         fi
27853 fi
27854
27855 if test $ol_enable_tcl != no ; then
27856
27857 for ac_header in tcl.h
27858 do
27859 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
27860 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27861   echo "$as_me:$LINENO: checking for $ac_header" >&5
27862 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27863 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27864   echo $ECHO_N "(cached) $ECHO_C" >&6
27865 fi
27866 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27867 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27868 else
27869   # Is the header compilable?
27870 echo "$as_me:$LINENO: checking $ac_header usability" >&5
27871 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
27872 cat >conftest.$ac_ext <<_ACEOF
27873 #line $LINENO "configure"
27874 /* confdefs.h.  */
27875 _ACEOF
27876 cat confdefs.h >>conftest.$ac_ext
27877 cat >>conftest.$ac_ext <<_ACEOF
27878 /* end confdefs.h.  */
27879 $ac_includes_default
27880 #include <$ac_header>
27881 _ACEOF
27882 rm -f conftest.$ac_objext
27883 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
27884   (eval $ac_compile) 2>&5
27885   ac_status=$?
27886   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27887   (exit $ac_status); } &&
27888          { ac_try='test -s conftest.$ac_objext'
27889   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
27890   (eval $ac_try) 2>&5
27891   ac_status=$?
27892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27893   (exit $ac_status); }; }; then
27894   ac_header_compiler=yes
27895 else
27896   echo "$as_me: failed program was:" >&5
27897 sed 's/^/| /' conftest.$ac_ext >&5
27898
27899 ac_header_compiler=no
27900 fi
27901 rm -f conftest.$ac_objext conftest.$ac_ext
27902 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
27903 echo "${ECHO_T}$ac_header_compiler" >&6
27904
27905 # Is the header present?
27906 echo "$as_me:$LINENO: checking $ac_header presence" >&5
27907 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
27908 cat >conftest.$ac_ext <<_ACEOF
27909 #line $LINENO "configure"
27910 /* confdefs.h.  */
27911 _ACEOF
27912 cat confdefs.h >>conftest.$ac_ext
27913 cat >>conftest.$ac_ext <<_ACEOF
27914 /* end confdefs.h.  */
27915 #include <$ac_header>
27916 _ACEOF
27917 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
27918   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
27919   ac_status=$?
27920   grep -v '^ *+' conftest.er1 >conftest.err
27921   rm -f conftest.er1
27922   cat conftest.err >&5
27923   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27924   (exit $ac_status); } >/dev/null; then
27925   if test -s conftest.err; then
27926     ac_cpp_err=$ac_c_preproc_warn_flag
27927   else
27928     ac_cpp_err=
27929   fi
27930 else
27931   ac_cpp_err=yes
27932 fi
27933 if test -z "$ac_cpp_err"; then
27934   ac_header_preproc=yes
27935 else
27936   echo "$as_me: failed program was:" >&5
27937 sed 's/^/| /' conftest.$ac_ext >&5
27938
27939   ac_header_preproc=no
27940 fi
27941 rm -f conftest.err conftest.$ac_ext
27942 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
27943 echo "${ECHO_T}$ac_header_preproc" >&6
27944
27945 # So?  What about this header?
27946 case $ac_header_compiler:$ac_header_preproc in
27947   yes:no )
27948     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
27949 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
27950     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27951 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27952     (
27953       cat <<\_ASBOX
27954 ## ------------------------------------ ##
27955 ## Report this to bug-autoconf@gnu.org. ##
27956 ## ------------------------------------ ##
27957 _ASBOX
27958     ) |
27959       sed "s/^/$as_me: WARNING:     /" >&2
27960     ;;
27961   no:yes )
27962     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
27963 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
27964     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
27965 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
27966     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
27967 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
27968     (
27969       cat <<\_ASBOX
27970 ## ------------------------------------ ##
27971 ## Report this to bug-autoconf@gnu.org. ##
27972 ## ------------------------------------ ##
27973 _ASBOX
27974     ) |
27975       sed "s/^/$as_me: WARNING:     /" >&2
27976     ;;
27977 esac
27978 echo "$as_me:$LINENO: checking for $ac_header" >&5
27979 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
27980 if eval "test \"\${$as_ac_Header+set}\" = set"; then
27981   echo $ECHO_N "(cached) $ECHO_C" >&6
27982 else
27983   eval "$as_ac_Header=$ac_header_preproc"
27984 fi
27985 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
27986 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
27987
27988 fi
27989 if test `eval echo '${'$as_ac_Header'}'` = yes; then
27990   cat >>confdefs.h <<_ACEOF
27991 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
27992 _ACEOF
27993
27994 fi
27995
27996 done
27997
27998
27999         if test $ac_cv_header_tcl_h != yes ; then
28000                 have_tcl=no
28001         else
28002                 for lib in tcl tcl7.6 tcl8.0 tcl8.2 ; do
28003                         as_ac_Lib=`echo "ac_cv_lib_$lib''_main" | $as_tr_sh`
28004 echo "$as_me:$LINENO: checking for main in -l$lib" >&5
28005 echo $ECHO_N "checking for main in -l$lib... $ECHO_C" >&6
28006 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
28007   echo $ECHO_N "(cached) $ECHO_C" >&6
28008 else
28009   ac_check_lib_save_LIBS=$LIBS
28010 LIBS="-l$lib  $LIBS"
28011 cat >conftest.$ac_ext <<_ACEOF
28012 #line $LINENO "configure"
28013 /* confdefs.h.  */
28014 _ACEOF
28015 cat confdefs.h >>conftest.$ac_ext
28016 cat >>conftest.$ac_ext <<_ACEOF
28017 /* end confdefs.h.  */
28018
28019
28020 int
28021 main ()
28022 {
28023 main ();
28024   ;
28025   return 0;
28026 }
28027 _ACEOF
28028 rm -f conftest.$ac_objext conftest$ac_exeext
28029 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28030   (eval $ac_link) 2>&5
28031   ac_status=$?
28032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28033   (exit $ac_status); } &&
28034          { ac_try='test -s conftest$ac_exeext'
28035   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28036   (eval $ac_try) 2>&5
28037   ac_status=$?
28038   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28039   (exit $ac_status); }; }; then
28040   eval "$as_ac_Lib=yes"
28041 else
28042   echo "$as_me: failed program was:" >&5
28043 sed 's/^/| /' conftest.$ac_ext >&5
28044
28045 eval "$as_ac_Lib=no"
28046 fi
28047 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28048 LIBS=$ac_check_lib_save_LIBS
28049 fi
28050 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Lib'}'`" >&5
28051 echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
28052 if test `eval echo '${'$as_ac_Lib'}'` = yes; then
28053   have_tcl=yes
28054                            if test x"$ol_with_tcl_module" = "xstatic" ; then
28055                                         SLAPD_LIBS="$SLAPD_LIBS -l${lib}"
28056                            else
28057                                         MOD_TCL_LIB="-l${lib}"
28058                            fi;break
28059 else
28060   have_tcl=no
28061 fi
28062
28063                 done
28064         fi
28065
28066         if test $have_tcl != yes ; then
28067                 { echo "$as_me:$LINENO: WARNING: could not find -ltcl" >&5
28068 echo "$as_me: WARNING: could not find -ltcl" >&2;}
28069                 if test $ol_enable_tcl = yes ; then
28070                         { { echo "$as_me:$LINENO: error: could not find tcl, select appropriate options or disable" >&5
28071 echo "$as_me: error: could not find tcl, select appropriate options or disable" >&2;}
28072    { (exit 1); exit 1; }; }
28073                 fi
28074
28075                 ol_enable_tcl=no
28076         fi
28077 fi
28078
28079 ol_link_termcap=no
28080
28081
28082 for ac_header in termcap.h ncurses.h
28083 do
28084 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
28085 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28086   echo "$as_me:$LINENO: checking for $ac_header" >&5
28087 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
28088 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28089   echo $ECHO_N "(cached) $ECHO_C" >&6
28090 fi
28091 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
28092 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
28093 else
28094   # Is the header compilable?
28095 echo "$as_me:$LINENO: checking $ac_header usability" >&5
28096 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
28097 cat >conftest.$ac_ext <<_ACEOF
28098 #line $LINENO "configure"
28099 /* confdefs.h.  */
28100 _ACEOF
28101 cat confdefs.h >>conftest.$ac_ext
28102 cat >>conftest.$ac_ext <<_ACEOF
28103 /* end confdefs.h.  */
28104 $ac_includes_default
28105 #include <$ac_header>
28106 _ACEOF
28107 rm -f conftest.$ac_objext
28108 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
28109   (eval $ac_compile) 2>&5
28110   ac_status=$?
28111   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28112   (exit $ac_status); } &&
28113          { ac_try='test -s conftest.$ac_objext'
28114   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28115   (eval $ac_try) 2>&5
28116   ac_status=$?
28117   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28118   (exit $ac_status); }; }; then
28119   ac_header_compiler=yes
28120 else
28121   echo "$as_me: failed program was:" >&5
28122 sed 's/^/| /' conftest.$ac_ext >&5
28123
28124 ac_header_compiler=no
28125 fi
28126 rm -f conftest.$ac_objext conftest.$ac_ext
28127 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28128 echo "${ECHO_T}$ac_header_compiler" >&6
28129
28130 # Is the header present?
28131 echo "$as_me:$LINENO: checking $ac_header presence" >&5
28132 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
28133 cat >conftest.$ac_ext <<_ACEOF
28134 #line $LINENO "configure"
28135 /* confdefs.h.  */
28136 _ACEOF
28137 cat confdefs.h >>conftest.$ac_ext
28138 cat >>conftest.$ac_ext <<_ACEOF
28139 /* end confdefs.h.  */
28140 #include <$ac_header>
28141 _ACEOF
28142 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
28143   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
28144   ac_status=$?
28145   grep -v '^ *+' conftest.er1 >conftest.err
28146   rm -f conftest.er1
28147   cat conftest.err >&5
28148   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28149   (exit $ac_status); } >/dev/null; then
28150   if test -s conftest.err; then
28151     ac_cpp_err=$ac_c_preproc_warn_flag
28152   else
28153     ac_cpp_err=
28154   fi
28155 else
28156   ac_cpp_err=yes
28157 fi
28158 if test -z "$ac_cpp_err"; then
28159   ac_header_preproc=yes
28160 else
28161   echo "$as_me: failed program was:" >&5
28162 sed 's/^/| /' conftest.$ac_ext >&5
28163
28164   ac_header_preproc=no
28165 fi
28166 rm -f conftest.err conftest.$ac_ext
28167 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28168 echo "${ECHO_T}$ac_header_preproc" >&6
28169
28170 # So?  What about this header?
28171 case $ac_header_compiler:$ac_header_preproc in
28172   yes:no )
28173     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
28174 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
28175     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
28176 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
28177     (
28178       cat <<\_ASBOX
28179 ## ------------------------------------ ##
28180 ## Report this to bug-autoconf@gnu.org. ##
28181 ## ------------------------------------ ##
28182 _ASBOX
28183     ) |
28184       sed "s/^/$as_me: WARNING:     /" >&2
28185     ;;
28186   no:yes )
28187     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
28188 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
28189     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
28190 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
28191     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
28192 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
28193     (
28194       cat <<\_ASBOX
28195 ## ------------------------------------ ##
28196 ## Report this to bug-autoconf@gnu.org. ##
28197 ## ------------------------------------ ##
28198 _ASBOX
28199     ) |
28200       sed "s/^/$as_me: WARNING:     /" >&2
28201     ;;
28202 esac
28203 echo "$as_me:$LINENO: checking for $ac_header" >&5
28204 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
28205 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28206   echo $ECHO_N "(cached) $ECHO_C" >&6
28207 else
28208   eval "$as_ac_Header=$ac_header_preproc"
28209 fi
28210 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
28211 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
28212
28213 fi
28214 if test `eval echo '${'$as_ac_Header'}'` = yes; then
28215   cat >>confdefs.h <<_ACEOF
28216 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
28217 _ACEOF
28218
28219 fi
28220
28221 done
28222
28223
28224 if test $ol_link_termcap = no ; then
28225         echo "$as_me:$LINENO: checking for tputs in -ltermcap" >&5
28226 echo $ECHO_N "checking for tputs in -ltermcap... $ECHO_C" >&6
28227 if test "${ac_cv_lib_termcap_tputs+set}" = set; then
28228   echo $ECHO_N "(cached) $ECHO_C" >&6
28229 else
28230   ac_check_lib_save_LIBS=$LIBS
28231 LIBS="-ltermcap  $LIBS"
28232 cat >conftest.$ac_ext <<_ACEOF
28233 #line $LINENO "configure"
28234 /* confdefs.h.  */
28235 _ACEOF
28236 cat confdefs.h >>conftest.$ac_ext
28237 cat >>conftest.$ac_ext <<_ACEOF
28238 /* end confdefs.h.  */
28239
28240 /* Override any gcc2 internal prototype to avoid an error.  */
28241 #ifdef __cplusplus
28242 extern "C"
28243 #endif
28244 /* We use char because int might match the return type of a gcc2
28245    builtin and then its argument prototype would still apply.  */
28246 char tputs ();
28247 int
28248 main ()
28249 {
28250 tputs ();
28251   ;
28252   return 0;
28253 }
28254 _ACEOF
28255 rm -f conftest.$ac_objext conftest$ac_exeext
28256 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28257   (eval $ac_link) 2>&5
28258   ac_status=$?
28259   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28260   (exit $ac_status); } &&
28261          { ac_try='test -s conftest$ac_exeext'
28262   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28263   (eval $ac_try) 2>&5
28264   ac_status=$?
28265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28266   (exit $ac_status); }; }; then
28267   ac_cv_lib_termcap_tputs=yes
28268 else
28269   echo "$as_me: failed program was:" >&5
28270 sed 's/^/| /' conftest.$ac_ext >&5
28271
28272 ac_cv_lib_termcap_tputs=no
28273 fi
28274 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28275 LIBS=$ac_check_lib_save_LIBS
28276 fi
28277 echo "$as_me:$LINENO: result: $ac_cv_lib_termcap_tputs" >&5
28278 echo "${ECHO_T}$ac_cv_lib_termcap_tputs" >&6
28279 if test $ac_cv_lib_termcap_tputs = yes; then
28280   have_termcap=yes
28281 else
28282   have_termcap=no
28283 fi
28284
28285         if test $have_termcap = yes ; then
28286
28287 cat >>confdefs.h <<\_ACEOF
28288 #define HAVE_TERMCAP 1
28289 _ACEOF
28290
28291                 ol_link_termcap=yes
28292                 TERMCAP_LIBS=-ltermcap
28293         fi
28294 fi
28295
28296 if test $ol_link_termcap = no ; then
28297         echo "$as_me:$LINENO: checking for initscr in -lncurses" >&5
28298 echo $ECHO_N "checking for initscr in -lncurses... $ECHO_C" >&6
28299 if test "${ac_cv_lib_ncurses_initscr+set}" = set; then
28300   echo $ECHO_N "(cached) $ECHO_C" >&6
28301 else
28302   ac_check_lib_save_LIBS=$LIBS
28303 LIBS="-lncurses  $LIBS"
28304 cat >conftest.$ac_ext <<_ACEOF
28305 #line $LINENO "configure"
28306 /* confdefs.h.  */
28307 _ACEOF
28308 cat confdefs.h >>conftest.$ac_ext
28309 cat >>conftest.$ac_ext <<_ACEOF
28310 /* end confdefs.h.  */
28311
28312 /* Override any gcc2 internal prototype to avoid an error.  */
28313 #ifdef __cplusplus
28314 extern "C"
28315 #endif
28316 /* We use char because int might match the return type of a gcc2
28317    builtin and then its argument prototype would still apply.  */
28318 char initscr ();
28319 int
28320 main ()
28321 {
28322 initscr ();
28323   ;
28324   return 0;
28325 }
28326 _ACEOF
28327 rm -f conftest.$ac_objext conftest$ac_exeext
28328 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28329   (eval $ac_link) 2>&5
28330   ac_status=$?
28331   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28332   (exit $ac_status); } &&
28333          { ac_try='test -s conftest$ac_exeext'
28334   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28335   (eval $ac_try) 2>&5
28336   ac_status=$?
28337   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28338   (exit $ac_status); }; }; then
28339   ac_cv_lib_ncurses_initscr=yes
28340 else
28341   echo "$as_me: failed program was:" >&5
28342 sed 's/^/| /' conftest.$ac_ext >&5
28343
28344 ac_cv_lib_ncurses_initscr=no
28345 fi
28346 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28347 LIBS=$ac_check_lib_save_LIBS
28348 fi
28349 echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_initscr" >&5
28350 echo "${ECHO_T}$ac_cv_lib_ncurses_initscr" >&6
28351 if test $ac_cv_lib_ncurses_initscr = yes; then
28352   have_ncurses=yes
28353 else
28354   have_ncurses=no
28355 fi
28356
28357         if test $have_ncurses = yes ; then
28358
28359 cat >>confdefs.h <<\_ACEOF
28360 #define HAVE_NCURSES 1
28361 _ACEOF
28362
28363                 ol_link_termcap=yes
28364                 TERMCAP_LIBS=-lncurses
28365         fi
28366 fi
28367
28368 if test $ol_link_termcap = no ; then
28369
28370 cat >>confdefs.h <<\_ACEOF
28371 #define NO_TERMCAP 1
28372 _ACEOF
28373
28374         TERMCAP_LIBS=
28375 fi
28376
28377 ol_link_sasl=no
28378 ol_link_spasswd=no
28379 if test $ol_with_cyrus_sasl != no ; then
28380
28381
28382 for ac_header in sasl/sasl.h sasl.h
28383 do
28384 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
28385 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28386   echo "$as_me:$LINENO: checking for $ac_header" >&5
28387 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
28388 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28389   echo $ECHO_N "(cached) $ECHO_C" >&6
28390 fi
28391 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
28392 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
28393 else
28394   # Is the header compilable?
28395 echo "$as_me:$LINENO: checking $ac_header usability" >&5
28396 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
28397 cat >conftest.$ac_ext <<_ACEOF
28398 #line $LINENO "configure"
28399 /* confdefs.h.  */
28400 _ACEOF
28401 cat confdefs.h >>conftest.$ac_ext
28402 cat >>conftest.$ac_ext <<_ACEOF
28403 /* end confdefs.h.  */
28404 $ac_includes_default
28405 #include <$ac_header>
28406 _ACEOF
28407 rm -f conftest.$ac_objext
28408 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
28409   (eval $ac_compile) 2>&5
28410   ac_status=$?
28411   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28412   (exit $ac_status); } &&
28413          { ac_try='test -s conftest.$ac_objext'
28414   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28415   (eval $ac_try) 2>&5
28416   ac_status=$?
28417   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28418   (exit $ac_status); }; }; then
28419   ac_header_compiler=yes
28420 else
28421   echo "$as_me: failed program was:" >&5
28422 sed 's/^/| /' conftest.$ac_ext >&5
28423
28424 ac_header_compiler=no
28425 fi
28426 rm -f conftest.$ac_objext conftest.$ac_ext
28427 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28428 echo "${ECHO_T}$ac_header_compiler" >&6
28429
28430 # Is the header present?
28431 echo "$as_me:$LINENO: checking $ac_header presence" >&5
28432 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
28433 cat >conftest.$ac_ext <<_ACEOF
28434 #line $LINENO "configure"
28435 /* confdefs.h.  */
28436 _ACEOF
28437 cat confdefs.h >>conftest.$ac_ext
28438 cat >>conftest.$ac_ext <<_ACEOF
28439 /* end confdefs.h.  */
28440 #include <$ac_header>
28441 _ACEOF
28442 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
28443   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
28444   ac_status=$?
28445   grep -v '^ *+' conftest.er1 >conftest.err
28446   rm -f conftest.er1
28447   cat conftest.err >&5
28448   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28449   (exit $ac_status); } >/dev/null; then
28450   if test -s conftest.err; then
28451     ac_cpp_err=$ac_c_preproc_warn_flag
28452   else
28453     ac_cpp_err=
28454   fi
28455 else
28456   ac_cpp_err=yes
28457 fi
28458 if test -z "$ac_cpp_err"; then
28459   ac_header_preproc=yes
28460 else
28461   echo "$as_me: failed program was:" >&5
28462 sed 's/^/| /' conftest.$ac_ext >&5
28463
28464   ac_header_preproc=no
28465 fi
28466 rm -f conftest.err conftest.$ac_ext
28467 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28468 echo "${ECHO_T}$ac_header_preproc" >&6
28469
28470 # So?  What about this header?
28471 case $ac_header_compiler:$ac_header_preproc in
28472   yes:no )
28473     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
28474 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
28475     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
28476 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
28477     (
28478       cat <<\_ASBOX
28479 ## ------------------------------------ ##
28480 ## Report this to bug-autoconf@gnu.org. ##
28481 ## ------------------------------------ ##
28482 _ASBOX
28483     ) |
28484       sed "s/^/$as_me: WARNING:     /" >&2
28485     ;;
28486   no:yes )
28487     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
28488 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
28489     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
28490 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
28491     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
28492 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
28493     (
28494       cat <<\_ASBOX
28495 ## ------------------------------------ ##
28496 ## Report this to bug-autoconf@gnu.org. ##
28497 ## ------------------------------------ ##
28498 _ASBOX
28499     ) |
28500       sed "s/^/$as_me: WARNING:     /" >&2
28501     ;;
28502 esac
28503 echo "$as_me:$LINENO: checking for $ac_header" >&5
28504 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
28505 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28506   echo $ECHO_N "(cached) $ECHO_C" >&6
28507 else
28508   eval "$as_ac_Header=$ac_header_preproc"
28509 fi
28510 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
28511 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
28512
28513 fi
28514 if test `eval echo '${'$as_ac_Header'}'` = yes; then
28515   cat >>confdefs.h <<_ACEOF
28516 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
28517 _ACEOF
28518
28519 fi
28520
28521 done
28522
28523
28524         if test $ac_cv_header_sasl_sasl_h = yes -o $ac_cv_header_sasl_h = yes; then
28525                 echo "$as_me:$LINENO: checking for sasl_client_init in -lsasl2" >&5
28526 echo $ECHO_N "checking for sasl_client_init in -lsasl2... $ECHO_C" >&6
28527 if test "${ac_cv_lib_sasl2_sasl_client_init+set}" = set; then
28528   echo $ECHO_N "(cached) $ECHO_C" >&6
28529 else
28530   ac_check_lib_save_LIBS=$LIBS
28531 LIBS="-lsasl2  $LIBS"
28532 cat >conftest.$ac_ext <<_ACEOF
28533 #line $LINENO "configure"
28534 /* confdefs.h.  */
28535 _ACEOF
28536 cat confdefs.h >>conftest.$ac_ext
28537 cat >>conftest.$ac_ext <<_ACEOF
28538 /* end confdefs.h.  */
28539
28540 /* Override any gcc2 internal prototype to avoid an error.  */
28541 #ifdef __cplusplus
28542 extern "C"
28543 #endif
28544 /* We use char because int might match the return type of a gcc2
28545    builtin and then its argument prototype would still apply.  */
28546 char sasl_client_init ();
28547 int
28548 main ()
28549 {
28550 sasl_client_init ();
28551   ;
28552   return 0;
28553 }
28554 _ACEOF
28555 rm -f conftest.$ac_objext conftest$ac_exeext
28556 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28557   (eval $ac_link) 2>&5
28558   ac_status=$?
28559   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28560   (exit $ac_status); } &&
28561          { ac_try='test -s conftest$ac_exeext'
28562   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28563   (eval $ac_try) 2>&5
28564   ac_status=$?
28565   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28566   (exit $ac_status); }; }; then
28567   ac_cv_lib_sasl2_sasl_client_init=yes
28568 else
28569   echo "$as_me: failed program was:" >&5
28570 sed 's/^/| /' conftest.$ac_ext >&5
28571
28572 ac_cv_lib_sasl2_sasl_client_init=no
28573 fi
28574 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28575 LIBS=$ac_check_lib_save_LIBS
28576 fi
28577 echo "$as_me:$LINENO: result: $ac_cv_lib_sasl2_sasl_client_init" >&5
28578 echo "${ECHO_T}$ac_cv_lib_sasl2_sasl_client_init" >&6
28579 if test $ac_cv_lib_sasl2_sasl_client_init = yes; then
28580   ol_link_sasl="-lsasl2"
28581 else
28582   echo "$as_me:$LINENO: checking for sasl_client_init in -lsasl" >&5
28583 echo $ECHO_N "checking for sasl_client_init in -lsasl... $ECHO_C" >&6
28584 if test "${ac_cv_lib_sasl_sasl_client_init+set}" = set; then
28585   echo $ECHO_N "(cached) $ECHO_C" >&6
28586 else
28587   ac_check_lib_save_LIBS=$LIBS
28588 LIBS="-lsasl  $LIBS"
28589 cat >conftest.$ac_ext <<_ACEOF
28590 #line $LINENO "configure"
28591 /* confdefs.h.  */
28592 _ACEOF
28593 cat confdefs.h >>conftest.$ac_ext
28594 cat >>conftest.$ac_ext <<_ACEOF
28595 /* end confdefs.h.  */
28596
28597 /* Override any gcc2 internal prototype to avoid an error.  */
28598 #ifdef __cplusplus
28599 extern "C"
28600 #endif
28601 /* We use char because int might match the return type of a gcc2
28602    builtin and then its argument prototype would still apply.  */
28603 char sasl_client_init ();
28604 int
28605 main ()
28606 {
28607 sasl_client_init ();
28608   ;
28609   return 0;
28610 }
28611 _ACEOF
28612 rm -f conftest.$ac_objext conftest$ac_exeext
28613 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28614   (eval $ac_link) 2>&5
28615   ac_status=$?
28616   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28617   (exit $ac_status); } &&
28618          { ac_try='test -s conftest$ac_exeext'
28619   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28620   (eval $ac_try) 2>&5
28621   ac_status=$?
28622   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28623   (exit $ac_status); }; }; then
28624   ac_cv_lib_sasl_sasl_client_init=yes
28625 else
28626   echo "$as_me: failed program was:" >&5
28627 sed 's/^/| /' conftest.$ac_ext >&5
28628
28629 ac_cv_lib_sasl_sasl_client_init=no
28630 fi
28631 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28632 LIBS=$ac_check_lib_save_LIBS
28633 fi
28634 echo "$as_me:$LINENO: result: $ac_cv_lib_sasl_sasl_client_init" >&5
28635 echo "${ECHO_T}$ac_cv_lib_sasl_sasl_client_init" >&6
28636 if test $ac_cv_lib_sasl_sasl_client_init = yes; then
28637   ol_link_sasl="-lsasl"
28638 fi
28639
28640 fi
28641
28642         fi
28643
28644         if test $ol_link_sasl = no ; then
28645                 if test $ol_with_cyrus_sasl != auto ; then
28646                         { { echo "$as_me:$LINENO: error: Could not locate Cyrus SASL" >&5
28647 echo "$as_me: error: Could not locate Cyrus SASL" >&2;}
28648    { (exit 1); exit 1; }; }
28649                 else
28650                         { echo "$as_me:$LINENO: WARNING: Could not locate Cyrus SASL" >&5
28651 echo "$as_me: WARNING: Could not locate Cyrus SASL" >&2;}
28652                         { echo "$as_me:$LINENO: WARNING: SASL authentication not supported!" >&5
28653 echo "$as_me: WARNING: SASL authentication not supported!" >&2;}
28654                         if test $ol_link_tls = no ; then
28655                                 { echo "$as_me:$LINENO: WARNING: Strong authentication not supported!" >&5
28656 echo "$as_me: WARNING: Strong authentication not supported!" >&2;}
28657                         fi
28658                 fi
28659         else
28660                 echo "$as_me:$LINENO: checking Cyrus SASL library version" >&5
28661 echo $ECHO_N "checking Cyrus SASL library version... $ECHO_C" >&6
28662 if test "${ol_cv_sasl_compat+set}" = set; then
28663   echo $ECHO_N "(cached) $ECHO_C" >&6
28664 else
28665
28666         cat >conftest.$ac_ext <<_ACEOF
28667 #line $LINENO "configure"
28668 /* confdefs.h.  */
28669 _ACEOF
28670 cat confdefs.h >>conftest.$ac_ext
28671 cat >>conftest.$ac_ext <<_ACEOF
28672 /* end confdefs.h.  */
28673
28674 #ifdef HAVE_SASL_SASL_H
28675 #include <sasl/sasl.h>
28676 #else
28677 #include <sasl.h>
28678 #endif
28679
28680 /* require 2.1.3 or later */
28681 #if SASL_VERSION_MAJOR == 1  && SASL_VERSION_MINOR >= 5
28682         char *__sasl_compat = "1.5.x okay";
28683 #elif SASL_VERSION_MAJOR == 2  && SASL_VERSION_MINOR > 1
28684         __sasl_compat "2.2+ or better okay (we guess)";
28685 #elif SASL_VERSION_MAJOR == 2  && SASL_VERSION_MINOR == 1 \
28686         && SASL_VERSION_STEP >=3
28687         __sasl_compat = "2.1.3+ or better okay";
28688 #endif
28689
28690 _ACEOF
28691 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28692   $EGREP "__sasl_compat" >/dev/null 2>&1; then
28693   ol_cv_sasl_compat=yes
28694 else
28695   ol_cv_sasl_compat=no
28696 fi
28697 rm -f conftest*
28698
28699 fi
28700 echo "$as_me:$LINENO: result: $ol_cv_sasl_compat" >&5
28701 echo "${ECHO_T}$ol_cv_sasl_compat" >&6
28702
28703                 if test $ol_cv_sasl_compat = no ; then
28704                         ol_link_sasl=no
28705                         { { echo "$as_me:$LINENO: error: Cyrus SASL library located but incompatible" >&5
28706 echo "$as_me: error: Cyrus SASL library located but incompatible" >&2;}
28707    { (exit 1); exit 1; }; }
28708                 fi
28709
28710
28711 cat >>confdefs.h <<\_ACEOF
28712 #define HAVE_CYRUS_SASL 1
28713 _ACEOF
28714
28715                 SASL_LIBS="$ol_link_sasl"
28716                 if test $ol_enable_spasswd != no ; then
28717                         ol_link_spasswd=yes
28718                 fi
28719
28720                 ac_save_LIBS="$LIBS"
28721                 LIBS="$LIBS $ol_link_sasl"
28722                 echo "$as_me:$LINENO: checking for sasl_version" >&5
28723 echo $ECHO_N "checking for sasl_version... $ECHO_C" >&6
28724 if test "${ac_cv_func_sasl_version+set}" = set; then
28725   echo $ECHO_N "(cached) $ECHO_C" >&6
28726 else
28727   cat >conftest.$ac_ext <<_ACEOF
28728 #line $LINENO "configure"
28729 /* confdefs.h.  */
28730 _ACEOF
28731 cat confdefs.h >>conftest.$ac_ext
28732 cat >>conftest.$ac_ext <<_ACEOF
28733 /* end confdefs.h.  */
28734 /* System header to define __stub macros and hopefully few prototypes,
28735     which can conflict with char sasl_version (); below.
28736     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
28737     <limits.h> exists even on freestanding compilers.  */
28738 #ifdef __STDC__
28739 # include <limits.h>
28740 #else
28741 # include <assert.h>
28742 #endif
28743 /* Override any gcc2 internal prototype to avoid an error.  */
28744 #ifdef __cplusplus
28745 extern "C"
28746 {
28747 #endif
28748 /* We use char because int might match the return type of a gcc2
28749    builtin and then its argument prototype would still apply.  */
28750 char sasl_version ();
28751 /* The GNU C library defines this for functions which it implements
28752     to always fail with ENOSYS.  Some functions are actually named
28753     something starting with __ and the normal name is an alias.  */
28754 #if defined (__stub_sasl_version) || defined (__stub___sasl_version)
28755 choke me
28756 #else
28757 char (*f) () = sasl_version;
28758 #endif
28759 #ifdef __cplusplus
28760 }
28761 #endif
28762
28763 int
28764 main ()
28765 {
28766 return f != sasl_version;
28767   ;
28768   return 0;
28769 }
28770 _ACEOF
28771 rm -f conftest.$ac_objext conftest$ac_exeext
28772 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28773   (eval $ac_link) 2>&5
28774   ac_status=$?
28775   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28776   (exit $ac_status); } &&
28777          { ac_try='test -s conftest$ac_exeext'
28778   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28779   (eval $ac_try) 2>&5
28780   ac_status=$?
28781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28782   (exit $ac_status); }; }; then
28783   ac_cv_func_sasl_version=yes
28784 else
28785   echo "$as_me: failed program was:" >&5
28786 sed 's/^/| /' conftest.$ac_ext >&5
28787
28788 ac_cv_func_sasl_version=no
28789 fi
28790 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28791 fi
28792 echo "$as_me:$LINENO: result: $ac_cv_func_sasl_version" >&5
28793 echo "${ECHO_T}$ac_cv_func_sasl_version" >&6
28794 if test $ac_cv_func_sasl_version = yes; then
28795
28796 cat >>confdefs.h <<\_ACEOF
28797 #define HAVE_SASL_VERSION 1
28798 _ACEOF
28799
28800 fi
28801
28802                 LIBS="$ac_save_LIBS"
28803         fi
28804
28805 else
28806         { echo "$as_me:$LINENO: WARNING: SASL authentication not supported!" >&5
28807 echo "$as_me: WARNING: SASL authentication not supported!" >&2;}
28808         if test $ol_link_tls = no ; then
28809                 { echo "$as_me:$LINENO: WARNING: Strong authentication not supported!" >&5
28810 echo "$as_me: WARNING: Strong authentication not supported!" >&2;}
28811         fi
28812 fi
28813
28814 if test $cross_compiling != yes -a "$ac_cv_mingw32" != yes ; then
28815         dev=no
28816         if test -r /dev/urandom ; then
28817                 dev="/dev/urandom";
28818         elif test -r /idev/urandom ; then
28819                 dev="/idev/urandom";
28820         elif test -r /dev/srandom ; then
28821                 dev="/dev/srandom";
28822         elif test -r /dev/random ; then
28823                 dev="/dev/random";
28824         elif test -r /idev/random ; then
28825                 dev="/idev/random";
28826         fi
28827
28828         if test $dev != no ; then
28829
28830 cat >>confdefs.h <<_ACEOF
28831 #define URANDOM_DEVICE "$dev"
28832 _ACEOF
28833
28834         fi
28835 fi
28836
28837 ol_link_fetch=no
28838 if test $ol_with_fetch != no ; then
28839         ol_LIBS=$LIBS
28840 LIBS="-lfetch -lcom_err $LIBS"
28841 echo "$as_me:$LINENO: checking fetch(3) library" >&5
28842 echo $ECHO_N "checking fetch(3) library... $ECHO_C" >&6
28843 if test "${ol_cv_lib_fetch+set}" = set; then
28844   echo $ECHO_N "(cached) $ECHO_C" >&6
28845 else
28846
28847         cat >conftest.$ac_ext <<_ACEOF
28848 #line $LINENO "configure"
28849 /* confdefs.h.  */
28850 _ACEOF
28851 cat confdefs.h >>conftest.$ac_ext
28852 cat >>conftest.$ac_ext <<_ACEOF
28853 /* end confdefs.h.  */
28854
28855 #include <sys/param.h>
28856 #include <stdio.h>
28857 #include <fetch.h>
28858 int
28859 main ()
28860 {
28861 struct url *u = fetchParseURL("file:///");
28862   ;
28863   return 0;
28864 }
28865 _ACEOF
28866 rm -f conftest.$ac_objext conftest$ac_exeext
28867 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
28868   (eval $ac_link) 2>&5
28869   ac_status=$?
28870   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28871   (exit $ac_status); } &&
28872          { ac_try='test -s conftest$ac_exeext'
28873   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28874   (eval $ac_try) 2>&5
28875   ac_status=$?
28876   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28877   (exit $ac_status); }; }; then
28878   ol_cv_lib_fetch=yes
28879 else
28880   echo "$as_me: failed program was:" >&5
28881 sed 's/^/| /' conftest.$ac_ext >&5
28882
28883 ol_cv_lib_fetch=no
28884 fi
28885 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
28886 fi
28887 echo "$as_me:$LINENO: result: $ol_cv_lib_fetch" >&5
28888 echo "${ECHO_T}$ol_cv_lib_fetch" >&6
28889 LIBS=$ol_LIBS
28890 if test $ol_cv_lib_fetch != no ; then
28891         ol_link_fetch="-lfetch -lcom_err"
28892
28893 cat >>confdefs.h <<\_ACEOF
28894 #define HAVE_FETCH 1
28895 _ACEOF
28896
28897 fi
28898
28899
28900         if test $ol_cv_lib_fetch != no ; then
28901                 LDIF_LIBS="$LDIF_LIBS $ol_link_fetch"
28902                 ol_link_fetch=freebsd
28903
28904         elif test $ol_with_fetch != auto ; then
28905                 { { echo "$as_me:$LINENO: error: no suitable API for --with-fetch=$ol_with_fetch" >&5
28906 echo "$as_me: error: no suitable API for --with-fetch=$ol_with_fetch" >&2;}
28907    { (exit 1); exit 1; }; }
28908         fi
28909 fi
28910
28911 ol_link_readline=no
28912 if test $ol_with_readline != no ; then
28913
28914
28915 for ac_header in readline/readline.h readline/history.h
28916 do
28917 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
28918 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28919   echo "$as_me:$LINENO: checking for $ac_header" >&5
28920 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
28921 if eval "test \"\${$as_ac_Header+set}\" = set"; then
28922   echo $ECHO_N "(cached) $ECHO_C" >&6
28923 fi
28924 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
28925 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
28926 else
28927   # Is the header compilable?
28928 echo "$as_me:$LINENO: checking $ac_header usability" >&5
28929 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
28930 cat >conftest.$ac_ext <<_ACEOF
28931 #line $LINENO "configure"
28932 /* confdefs.h.  */
28933 _ACEOF
28934 cat confdefs.h >>conftest.$ac_ext
28935 cat >>conftest.$ac_ext <<_ACEOF
28936 /* end confdefs.h.  */
28937 $ac_includes_default
28938 #include <$ac_header>
28939 _ACEOF
28940 rm -f conftest.$ac_objext
28941 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
28942   (eval $ac_compile) 2>&5
28943   ac_status=$?
28944   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28945   (exit $ac_status); } &&
28946          { ac_try='test -s conftest.$ac_objext'
28947   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
28948   (eval $ac_try) 2>&5
28949   ac_status=$?
28950   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28951   (exit $ac_status); }; }; then
28952   ac_header_compiler=yes
28953 else
28954   echo "$as_me: failed program was:" >&5
28955 sed 's/^/| /' conftest.$ac_ext >&5
28956
28957 ac_header_compiler=no
28958 fi
28959 rm -f conftest.$ac_objext conftest.$ac_ext
28960 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28961 echo "${ECHO_T}$ac_header_compiler" >&6
28962
28963 # Is the header present?
28964 echo "$as_me:$LINENO: checking $ac_header presence" >&5
28965 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
28966 cat >conftest.$ac_ext <<_ACEOF
28967 #line $LINENO "configure"
28968 /* confdefs.h.  */
28969 _ACEOF
28970 cat confdefs.h >>conftest.$ac_ext
28971 cat >>conftest.$ac_ext <<_ACEOF
28972 /* end confdefs.h.  */
28973 #include <$ac_header>
28974 _ACEOF
28975 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
28976   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
28977   ac_status=$?
28978   grep -v '^ *+' conftest.er1 >conftest.err
28979   rm -f conftest.er1
28980   cat conftest.err >&5
28981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28982   (exit $ac_status); } >/dev/null; then
28983   if test -s conftest.err; then
28984     ac_cpp_err=$ac_c_preproc_warn_flag
28985   else
28986     ac_cpp_err=
28987   fi
28988 else
28989   ac_cpp_err=yes
28990 fi
28991 if test -z "$ac_cpp_err"; then
28992   ac_header_preproc=yes
28993 else
28994   echo "$as_me: failed program was:" >&5
28995 sed 's/^/| /' conftest.$ac_ext >&5
28996
28997   ac_header_preproc=no
28998 fi
28999 rm -f conftest.err conftest.$ac_ext
29000 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
29001 echo "${ECHO_T}$ac_header_preproc" >&6
29002
29003 # So?  What about this header?
29004 case $ac_header_compiler:$ac_header_preproc in
29005   yes:no )
29006     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
29007 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
29008     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29009 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29010     (
29011       cat <<\_ASBOX
29012 ## ------------------------------------ ##
29013 ## Report this to bug-autoconf@gnu.org. ##
29014 ## ------------------------------------ ##
29015 _ASBOX
29016     ) |
29017       sed "s/^/$as_me: WARNING:     /" >&2
29018     ;;
29019   no:yes )
29020     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
29021 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
29022     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
29023 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
29024     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29025 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29026     (
29027       cat <<\_ASBOX
29028 ## ------------------------------------ ##
29029 ## Report this to bug-autoconf@gnu.org. ##
29030 ## ------------------------------------ ##
29031 _ASBOX
29032     ) |
29033       sed "s/^/$as_me: WARNING:     /" >&2
29034     ;;
29035 esac
29036 echo "$as_me:$LINENO: checking for $ac_header" >&5
29037 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
29038 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29039   echo $ECHO_N "(cached) $ECHO_C" >&6
29040 else
29041   eval "$as_ac_Header=$ac_header_preproc"
29042 fi
29043 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
29044 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
29045
29046 fi
29047 if test `eval echo '${'$as_ac_Header'}'` = yes; then
29048   cat >>confdefs.h <<_ACEOF
29049 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
29050 _ACEOF
29051
29052 fi
29053
29054 done
29055
29056
29057         if test $ac_cv_header_readline_readline_h = yes ; then
29058                 save_LIBS="$LIBS"
29059                 LIBS="$TERMCAP_LIBS $LIBS"
29060                 echo "$as_me:$LINENO: checking for readline in -lreadline" >&5
29061 echo $ECHO_N "checking for readline in -lreadline... $ECHO_C" >&6
29062 if test "${ac_cv_lib_readline_readline+set}" = set; then
29063   echo $ECHO_N "(cached) $ECHO_C" >&6
29064 else
29065   ac_check_lib_save_LIBS=$LIBS
29066 LIBS="-lreadline  $LIBS"
29067 cat >conftest.$ac_ext <<_ACEOF
29068 #line $LINENO "configure"
29069 /* confdefs.h.  */
29070 _ACEOF
29071 cat confdefs.h >>conftest.$ac_ext
29072 cat >>conftest.$ac_ext <<_ACEOF
29073 /* end confdefs.h.  */
29074
29075 /* Override any gcc2 internal prototype to avoid an error.  */
29076 #ifdef __cplusplus
29077 extern "C"
29078 #endif
29079 /* We use char because int might match the return type of a gcc2
29080    builtin and then its argument prototype would still apply.  */
29081 char readline ();
29082 int
29083 main ()
29084 {
29085 readline ();
29086   ;
29087   return 0;
29088 }
29089 _ACEOF
29090 rm -f conftest.$ac_objext conftest$ac_exeext
29091 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29092   (eval $ac_link) 2>&5
29093   ac_status=$?
29094   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29095   (exit $ac_status); } &&
29096          { ac_try='test -s conftest$ac_exeext'
29097   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29098   (eval $ac_try) 2>&5
29099   ac_status=$?
29100   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29101   (exit $ac_status); }; }; then
29102   ac_cv_lib_readline_readline=yes
29103 else
29104   echo "$as_me: failed program was:" >&5
29105 sed 's/^/| /' conftest.$ac_ext >&5
29106
29107 ac_cv_lib_readline_readline=no
29108 fi
29109 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
29110 LIBS=$ac_check_lib_save_LIBS
29111 fi
29112 echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5
29113 echo "${ECHO_T}$ac_cv_lib_readline_readline" >&6
29114 if test $ac_cv_lib_readline_readline = yes; then
29115   have_readline=yes
29116 else
29117   have_readline=no
29118 fi
29119
29120                 LIBS="$save_LIBS"
29121
29122                 if test $have_readline = yes ; then
29123                         ol_with_readline=found
29124                         ol_link_readline=yes
29125
29126                         READLINE_LIBS="-lreadline"
29127                 fi
29128         fi
29129 fi
29130
29131 if test $ol_link_readline = yes ; then
29132
29133 cat >>confdefs.h <<\_ACEOF
29134 #define HAVE_READLINE 1
29135 _ACEOF
29136
29137 fi
29138
29139
29140 if test $ol_enable_crypt != no ; then
29141         save_LIBS="$LIBS"
29142         LIBS="$TLS_LIBS $LIBS"
29143
29144         echo "$as_me:$LINENO: checking for crypt" >&5
29145 echo $ECHO_N "checking for crypt... $ECHO_C" >&6
29146 if test "${ac_cv_func_crypt+set}" = set; then
29147   echo $ECHO_N "(cached) $ECHO_C" >&6
29148 else
29149   cat >conftest.$ac_ext <<_ACEOF
29150 #line $LINENO "configure"
29151 /* confdefs.h.  */
29152 _ACEOF
29153 cat confdefs.h >>conftest.$ac_ext
29154 cat >>conftest.$ac_ext <<_ACEOF
29155 /* end confdefs.h.  */
29156 /* System header to define __stub macros and hopefully few prototypes,
29157     which can conflict with char crypt (); below.
29158     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
29159     <limits.h> exists even on freestanding compilers.  */
29160 #ifdef __STDC__
29161 # include <limits.h>
29162 #else
29163 # include <assert.h>
29164 #endif
29165 /* Override any gcc2 internal prototype to avoid an error.  */
29166 #ifdef __cplusplus
29167 extern "C"
29168 {
29169 #endif
29170 /* We use char because int might match the return type of a gcc2
29171    builtin and then its argument prototype would still apply.  */
29172 char crypt ();
29173 /* The GNU C library defines this for functions which it implements
29174     to always fail with ENOSYS.  Some functions are actually named
29175     something starting with __ and the normal name is an alias.  */
29176 #if defined (__stub_crypt) || defined (__stub___crypt)
29177 choke me
29178 #else
29179 char (*f) () = crypt;
29180 #endif
29181 #ifdef __cplusplus
29182 }
29183 #endif
29184
29185 int
29186 main ()
29187 {
29188 return f != crypt;
29189   ;
29190   return 0;
29191 }
29192 _ACEOF
29193 rm -f conftest.$ac_objext conftest$ac_exeext
29194 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29195   (eval $ac_link) 2>&5
29196   ac_status=$?
29197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29198   (exit $ac_status); } &&
29199          { ac_try='test -s conftest$ac_exeext'
29200   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29201   (eval $ac_try) 2>&5
29202   ac_status=$?
29203   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29204   (exit $ac_status); }; }; then
29205   ac_cv_func_crypt=yes
29206 else
29207   echo "$as_me: failed program was:" >&5
29208 sed 's/^/| /' conftest.$ac_ext >&5
29209
29210 ac_cv_func_crypt=no
29211 fi
29212 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
29213 fi
29214 echo "$as_me:$LINENO: result: $ac_cv_func_crypt" >&5
29215 echo "${ECHO_T}$ac_cv_func_crypt" >&6
29216 if test $ac_cv_func_crypt = yes; then
29217   have_crypt=yes
29218 else
29219
29220                 LIBS="$save_LIBS"
29221                 echo "$as_me:$LINENO: checking for crypt in -lcrypt" >&5
29222 echo $ECHO_N "checking for crypt in -lcrypt... $ECHO_C" >&6
29223 if test "${ac_cv_lib_crypt_crypt+set}" = set; then
29224   echo $ECHO_N "(cached) $ECHO_C" >&6
29225 else
29226   ac_check_lib_save_LIBS=$LIBS
29227 LIBS="-lcrypt  $LIBS"
29228 cat >conftest.$ac_ext <<_ACEOF
29229 #line $LINENO "configure"
29230 /* confdefs.h.  */
29231 _ACEOF
29232 cat confdefs.h >>conftest.$ac_ext
29233 cat >>conftest.$ac_ext <<_ACEOF
29234 /* end confdefs.h.  */
29235
29236 /* Override any gcc2 internal prototype to avoid an error.  */
29237 #ifdef __cplusplus
29238 extern "C"
29239 #endif
29240 /* We use char because int might match the return type of a gcc2
29241    builtin and then its argument prototype would still apply.  */
29242 char crypt ();
29243 int
29244 main ()
29245 {
29246 crypt ();
29247   ;
29248   return 0;
29249 }
29250 _ACEOF
29251 rm -f conftest.$ac_objext conftest$ac_exeext
29252 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29253   (eval $ac_link) 2>&5
29254   ac_status=$?
29255   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29256   (exit $ac_status); } &&
29257          { ac_try='test -s conftest$ac_exeext'
29258   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29259   (eval $ac_try) 2>&5
29260   ac_status=$?
29261   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29262   (exit $ac_status); }; }; then
29263   ac_cv_lib_crypt_crypt=yes
29264 else
29265   echo "$as_me: failed program was:" >&5
29266 sed 's/^/| /' conftest.$ac_ext >&5
29267
29268 ac_cv_lib_crypt_crypt=no
29269 fi
29270 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
29271 LIBS=$ac_check_lib_save_LIBS
29272 fi
29273 echo "$as_me:$LINENO: result: $ac_cv_lib_crypt_crypt" >&5
29274 echo "${ECHO_T}$ac_cv_lib_crypt_crypt" >&6
29275 if test $ac_cv_lib_crypt_crypt = yes; then
29276   LUTIL_LIBS="$LUTIL_LIBS -lcrypt"
29277                         have_crypt=yes
29278 else
29279   have_crypt=no
29280 fi
29281
29282 fi
29283
29284
29285         LIBS="$save_LIBS"
29286
29287         if test $have_crypt = yes ; then
29288
29289 cat >>confdefs.h <<\_ACEOF
29290 #define HAVE_CRYPT 1
29291 _ACEOF
29292
29293         else
29294                 { echo "$as_me:$LINENO: WARNING: could not find crypt" >&5
29295 echo "$as_me: WARNING: could not find crypt" >&2;}
29296                 if test $ol_enable_crypt = yes ; then
29297                         { { echo "$as_me:$LINENO: error: could not find crypt" >&5
29298 echo "$as_me: error: could not find crypt" >&2;}
29299    { (exit select appropriate options or disable); exit select appropriate options or disable; }; }
29300                 fi
29301
29302                 { echo "$as_me:$LINENO: WARNING: disabling crypt support" >&5
29303 echo "$as_me: WARNING: disabling crypt support" >&2;}
29304                 ol_enable_crypt=no
29305         fi
29306 fi
29307
29308 if test $ol_enable_proctitle != no ; then
29309         echo "$as_me:$LINENO: checking for setproctitle" >&5
29310 echo $ECHO_N "checking for setproctitle... $ECHO_C" >&6
29311 if test "${ac_cv_func_setproctitle+set}" = set; then
29312   echo $ECHO_N "(cached) $ECHO_C" >&6
29313 else
29314   cat >conftest.$ac_ext <<_ACEOF
29315 #line $LINENO "configure"
29316 /* confdefs.h.  */
29317 _ACEOF
29318 cat confdefs.h >>conftest.$ac_ext
29319 cat >>conftest.$ac_ext <<_ACEOF
29320 /* end confdefs.h.  */
29321 /* System header to define __stub macros and hopefully few prototypes,
29322     which can conflict with char setproctitle (); below.
29323     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
29324     <limits.h> exists even on freestanding compilers.  */
29325 #ifdef __STDC__
29326 # include <limits.h>
29327 #else
29328 # include <assert.h>
29329 #endif
29330 /* Override any gcc2 internal prototype to avoid an error.  */
29331 #ifdef __cplusplus
29332 extern "C"
29333 {
29334 #endif
29335 /* We use char because int might match the return type of a gcc2
29336    builtin and then its argument prototype would still apply.  */
29337 char setproctitle ();
29338 /* The GNU C library defines this for functions which it implements
29339     to always fail with ENOSYS.  Some functions are actually named
29340     something starting with __ and the normal name is an alias.  */
29341 #if defined (__stub_setproctitle) || defined (__stub___setproctitle)
29342 choke me
29343 #else
29344 char (*f) () = setproctitle;
29345 #endif
29346 #ifdef __cplusplus
29347 }
29348 #endif
29349
29350 int
29351 main ()
29352 {
29353 return f != setproctitle;
29354   ;
29355   return 0;
29356 }
29357 _ACEOF
29358 rm -f conftest.$ac_objext conftest$ac_exeext
29359 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29360   (eval $ac_link) 2>&5
29361   ac_status=$?
29362   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29363   (exit $ac_status); } &&
29364          { ac_try='test -s conftest$ac_exeext'
29365   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29366   (eval $ac_try) 2>&5
29367   ac_status=$?
29368   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29369   (exit $ac_status); }; }; then
29370   ac_cv_func_setproctitle=yes
29371 else
29372   echo "$as_me: failed program was:" >&5
29373 sed 's/^/| /' conftest.$ac_ext >&5
29374
29375 ac_cv_func_setproctitle=no
29376 fi
29377 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
29378 fi
29379 echo "$as_me:$LINENO: result: $ac_cv_func_setproctitle" >&5
29380 echo "${ECHO_T}$ac_cv_func_setproctitle" >&6
29381 if test $ac_cv_func_setproctitle = yes; then
29382   have_setproctitle=yes
29383 else
29384
29385                 echo "$as_me:$LINENO: checking for setproctitle in -lutil" >&5
29386 echo $ECHO_N "checking for setproctitle in -lutil... $ECHO_C" >&6
29387 if test "${ac_cv_lib_util_setproctitle+set}" = set; then
29388   echo $ECHO_N "(cached) $ECHO_C" >&6
29389 else
29390   ac_check_lib_save_LIBS=$LIBS
29391 LIBS="-lutil  $LIBS"
29392 cat >conftest.$ac_ext <<_ACEOF
29393 #line $LINENO "configure"
29394 /* confdefs.h.  */
29395 _ACEOF
29396 cat confdefs.h >>conftest.$ac_ext
29397 cat >>conftest.$ac_ext <<_ACEOF
29398 /* end confdefs.h.  */
29399
29400 /* Override any gcc2 internal prototype to avoid an error.  */
29401 #ifdef __cplusplus
29402 extern "C"
29403 #endif
29404 /* We use char because int might match the return type of a gcc2
29405    builtin and then its argument prototype would still apply.  */
29406 char setproctitle ();
29407 int
29408 main ()
29409 {
29410 setproctitle ();
29411   ;
29412   return 0;
29413 }
29414 _ACEOF
29415 rm -f conftest.$ac_objext conftest$ac_exeext
29416 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29417   (eval $ac_link) 2>&5
29418   ac_status=$?
29419   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29420   (exit $ac_status); } &&
29421          { ac_try='test -s conftest$ac_exeext'
29422   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29423   (eval $ac_try) 2>&5
29424   ac_status=$?
29425   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29426   (exit $ac_status); }; }; then
29427   ac_cv_lib_util_setproctitle=yes
29428 else
29429   echo "$as_me: failed program was:" >&5
29430 sed 's/^/| /' conftest.$ac_ext >&5
29431
29432 ac_cv_lib_util_setproctitle=no
29433 fi
29434 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
29435 LIBS=$ac_check_lib_save_LIBS
29436 fi
29437 echo "$as_me:$LINENO: result: $ac_cv_lib_util_setproctitle" >&5
29438 echo "${ECHO_T}$ac_cv_lib_util_setproctitle" >&6
29439 if test $ac_cv_lib_util_setproctitle = yes; then
29440   have_setproctitle=yes
29441                         LUTIL_LIBS="$LUTIL_LIBS -lutil"
29442 else
29443   have_setproctitle=no
29444                         LIBOBJS="$LIBOBJS setproctitle.$ac_objext"
29445                         LIBSRCS="$LIBSRCS setproctitle.c"
29446 fi
29447
29448 fi
29449
29450
29451         if test $have_setproctitle = yes ; then
29452
29453 cat >>confdefs.h <<\_ACEOF
29454 #define HAVE_SETPROCTITLE 1
29455 _ACEOF
29456
29457         fi
29458 fi
29459
29460 if test $ol_enable_slp != no ; then
29461
29462 for ac_header in slp.h
29463 do
29464 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
29465 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29466   echo "$as_me:$LINENO: checking for $ac_header" >&5
29467 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
29468 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29469   echo $ECHO_N "(cached) $ECHO_C" >&6
29470 fi
29471 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
29472 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
29473 else
29474   # Is the header compilable?
29475 echo "$as_me:$LINENO: checking $ac_header usability" >&5
29476 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
29477 cat >conftest.$ac_ext <<_ACEOF
29478 #line $LINENO "configure"
29479 /* confdefs.h.  */
29480 _ACEOF
29481 cat confdefs.h >>conftest.$ac_ext
29482 cat >>conftest.$ac_ext <<_ACEOF
29483 /* end confdefs.h.  */
29484 $ac_includes_default
29485 #include <$ac_header>
29486 _ACEOF
29487 rm -f conftest.$ac_objext
29488 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
29489   (eval $ac_compile) 2>&5
29490   ac_status=$?
29491   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29492   (exit $ac_status); } &&
29493          { ac_try='test -s conftest.$ac_objext'
29494   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29495   (eval $ac_try) 2>&5
29496   ac_status=$?
29497   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29498   (exit $ac_status); }; }; then
29499   ac_header_compiler=yes
29500 else
29501   echo "$as_me: failed program was:" >&5
29502 sed 's/^/| /' conftest.$ac_ext >&5
29503
29504 ac_header_compiler=no
29505 fi
29506 rm -f conftest.$ac_objext conftest.$ac_ext
29507 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
29508 echo "${ECHO_T}$ac_header_compiler" >&6
29509
29510 # Is the header present?
29511 echo "$as_me:$LINENO: checking $ac_header presence" >&5
29512 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
29513 cat >conftest.$ac_ext <<_ACEOF
29514 #line $LINENO "configure"
29515 /* confdefs.h.  */
29516 _ACEOF
29517 cat confdefs.h >>conftest.$ac_ext
29518 cat >>conftest.$ac_ext <<_ACEOF
29519 /* end confdefs.h.  */
29520 #include <$ac_header>
29521 _ACEOF
29522 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
29523   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
29524   ac_status=$?
29525   grep -v '^ *+' conftest.er1 >conftest.err
29526   rm -f conftest.er1
29527   cat conftest.err >&5
29528   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29529   (exit $ac_status); } >/dev/null; then
29530   if test -s conftest.err; then
29531     ac_cpp_err=$ac_c_preproc_warn_flag
29532   else
29533     ac_cpp_err=
29534   fi
29535 else
29536   ac_cpp_err=yes
29537 fi
29538 if test -z "$ac_cpp_err"; then
29539   ac_header_preproc=yes
29540 else
29541   echo "$as_me: failed program was:" >&5
29542 sed 's/^/| /' conftest.$ac_ext >&5
29543
29544   ac_header_preproc=no
29545 fi
29546 rm -f conftest.err conftest.$ac_ext
29547 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
29548 echo "${ECHO_T}$ac_header_preproc" >&6
29549
29550 # So?  What about this header?
29551 case $ac_header_compiler:$ac_header_preproc in
29552   yes:no )
29553     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
29554 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
29555     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29556 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29557     (
29558       cat <<\_ASBOX
29559 ## ------------------------------------ ##
29560 ## Report this to bug-autoconf@gnu.org. ##
29561 ## ------------------------------------ ##
29562 _ASBOX
29563     ) |
29564       sed "s/^/$as_me: WARNING:     /" >&2
29565     ;;
29566   no:yes )
29567     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
29568 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
29569     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
29570 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
29571     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29572 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29573     (
29574       cat <<\_ASBOX
29575 ## ------------------------------------ ##
29576 ## Report this to bug-autoconf@gnu.org. ##
29577 ## ------------------------------------ ##
29578 _ASBOX
29579     ) |
29580       sed "s/^/$as_me: WARNING:     /" >&2
29581     ;;
29582 esac
29583 echo "$as_me:$LINENO: checking for $ac_header" >&5
29584 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
29585 if eval "test \"\${$as_ac_Header+set}\" = set"; then
29586   echo $ECHO_N "(cached) $ECHO_C" >&6
29587 else
29588   eval "$as_ac_Header=$ac_header_preproc"
29589 fi
29590 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
29591 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
29592
29593 fi
29594 if test `eval echo '${'$as_ac_Header'}'` = yes; then
29595   cat >>confdefs.h <<_ACEOF
29596 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
29597 _ACEOF
29598
29599 fi
29600
29601 done
29602
29603
29604         if test $ac_cv_header_slp_h = yes ; then
29605                 echo "$as_me:$LINENO: checking for SLPOpen in -lslp" >&5
29606 echo $ECHO_N "checking for SLPOpen in -lslp... $ECHO_C" >&6
29607 if test "${ac_cv_lib_slp_SLPOpen+set}" = set; then
29608   echo $ECHO_N "(cached) $ECHO_C" >&6
29609 else
29610   ac_check_lib_save_LIBS=$LIBS
29611 LIBS="-lslp  $LIBS"
29612 cat >conftest.$ac_ext <<_ACEOF
29613 #line $LINENO "configure"
29614 /* confdefs.h.  */
29615 _ACEOF
29616 cat confdefs.h >>conftest.$ac_ext
29617 cat >>conftest.$ac_ext <<_ACEOF
29618 /* end confdefs.h.  */
29619
29620 /* Override any gcc2 internal prototype to avoid an error.  */
29621 #ifdef __cplusplus
29622 extern "C"
29623 #endif
29624 /* We use char because int might match the return type of a gcc2
29625    builtin and then its argument prototype would still apply.  */
29626 char SLPOpen ();
29627 int
29628 main ()
29629 {
29630 SLPOpen ();
29631   ;
29632   return 0;
29633 }
29634 _ACEOF
29635 rm -f conftest.$ac_objext conftest$ac_exeext
29636 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
29637   (eval $ac_link) 2>&5
29638   ac_status=$?
29639   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29640   (exit $ac_status); } &&
29641          { ac_try='test -s conftest$ac_exeext'
29642   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29643   (eval $ac_try) 2>&5
29644   ac_status=$?
29645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29646   (exit $ac_status); }; }; then
29647   ac_cv_lib_slp_SLPOpen=yes
29648 else
29649   echo "$as_me: failed program was:" >&5
29650 sed 's/^/| /' conftest.$ac_ext >&5
29651
29652 ac_cv_lib_slp_SLPOpen=no
29653 fi
29654 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
29655 LIBS=$ac_check_lib_save_LIBS
29656 fi
29657 echo "$as_me:$LINENO: result: $ac_cv_lib_slp_SLPOpen" >&5
29658 echo "${ECHO_T}$ac_cv_lib_slp_SLPOpen" >&6
29659 if test $ac_cv_lib_slp_SLPOpen = yes; then
29660   have_slp=yes
29661 else
29662   have_slp=no
29663 fi
29664
29665                 if test $have_slp = yes ; then
29666
29667 cat >>confdefs.h <<\_ACEOF
29668 #define HAVE_SLP 1
29669 _ACEOF
29670
29671                         SLAPD_SLP_LIBS=-lslp
29672                 fi
29673
29674         elif test $ol_enable_slp = yes ; then
29675                 { { echo "$as_me:$LINENO: error: SLP not found" >&5
29676 echo "$as_me: error: SLP not found" >&2;}
29677    { (exit 1); exit 1; }; }
29678         fi
29679 fi
29680
29681 echo "$as_me:$LINENO: checking for mode_t" >&5
29682 echo $ECHO_N "checking for mode_t... $ECHO_C" >&6
29683 if test "${ac_cv_type_mode_t+set}" = set; then
29684   echo $ECHO_N "(cached) $ECHO_C" >&6
29685 else
29686   cat >conftest.$ac_ext <<_ACEOF
29687 #line $LINENO "configure"
29688 /* confdefs.h.  */
29689 _ACEOF
29690 cat confdefs.h >>conftest.$ac_ext
29691 cat >>conftest.$ac_ext <<_ACEOF
29692 /* end confdefs.h.  */
29693 $ac_includes_default
29694 int
29695 main ()
29696 {
29697 if ((mode_t *) 0)
29698   return 0;
29699 if (sizeof (mode_t))
29700   return 0;
29701   ;
29702   return 0;
29703 }
29704 _ACEOF
29705 rm -f conftest.$ac_objext
29706 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
29707   (eval $ac_compile) 2>&5
29708   ac_status=$?
29709   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29710   (exit $ac_status); } &&
29711          { ac_try='test -s conftest.$ac_objext'
29712   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29713   (eval $ac_try) 2>&5
29714   ac_status=$?
29715   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29716   (exit $ac_status); }; }; then
29717   ac_cv_type_mode_t=yes
29718 else
29719   echo "$as_me: failed program was:" >&5
29720 sed 's/^/| /' conftest.$ac_ext >&5
29721
29722 ac_cv_type_mode_t=no
29723 fi
29724 rm -f conftest.$ac_objext conftest.$ac_ext
29725 fi
29726 echo "$as_me:$LINENO: result: $ac_cv_type_mode_t" >&5
29727 echo "${ECHO_T}$ac_cv_type_mode_t" >&6
29728 if test $ac_cv_type_mode_t = yes; then
29729   :
29730 else
29731
29732 cat >>confdefs.h <<_ACEOF
29733 #define mode_t int
29734 _ACEOF
29735
29736 fi
29737
29738 echo "$as_me:$LINENO: checking for off_t" >&5
29739 echo $ECHO_N "checking for off_t... $ECHO_C" >&6
29740 if test "${ac_cv_type_off_t+set}" = set; then
29741   echo $ECHO_N "(cached) $ECHO_C" >&6
29742 else
29743   cat >conftest.$ac_ext <<_ACEOF
29744 #line $LINENO "configure"
29745 /* confdefs.h.  */
29746 _ACEOF
29747 cat confdefs.h >>conftest.$ac_ext
29748 cat >>conftest.$ac_ext <<_ACEOF
29749 /* end confdefs.h.  */
29750 $ac_includes_default
29751 int
29752 main ()
29753 {
29754 if ((off_t *) 0)
29755   return 0;
29756 if (sizeof (off_t))
29757   return 0;
29758   ;
29759   return 0;
29760 }
29761 _ACEOF
29762 rm -f conftest.$ac_objext
29763 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
29764   (eval $ac_compile) 2>&5
29765   ac_status=$?
29766   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29767   (exit $ac_status); } &&
29768          { ac_try='test -s conftest.$ac_objext'
29769   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29770   (eval $ac_try) 2>&5
29771   ac_status=$?
29772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29773   (exit $ac_status); }; }; then
29774   ac_cv_type_off_t=yes
29775 else
29776   echo "$as_me: failed program was:" >&5
29777 sed 's/^/| /' conftest.$ac_ext >&5
29778
29779 ac_cv_type_off_t=no
29780 fi
29781 rm -f conftest.$ac_objext conftest.$ac_ext
29782 fi
29783 echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
29784 echo "${ECHO_T}$ac_cv_type_off_t" >&6
29785 if test $ac_cv_type_off_t = yes; then
29786   :
29787 else
29788
29789 cat >>confdefs.h <<_ACEOF
29790 #define off_t long
29791 _ACEOF
29792
29793 fi
29794
29795 echo "$as_me:$LINENO: checking for pid_t" >&5
29796 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
29797 if test "${ac_cv_type_pid_t+set}" = set; then
29798   echo $ECHO_N "(cached) $ECHO_C" >&6
29799 else
29800   cat >conftest.$ac_ext <<_ACEOF
29801 #line $LINENO "configure"
29802 /* confdefs.h.  */
29803 _ACEOF
29804 cat confdefs.h >>conftest.$ac_ext
29805 cat >>conftest.$ac_ext <<_ACEOF
29806 /* end confdefs.h.  */
29807 $ac_includes_default
29808 int
29809 main ()
29810 {
29811 if ((pid_t *) 0)
29812   return 0;
29813 if (sizeof (pid_t))
29814   return 0;
29815   ;
29816   return 0;
29817 }
29818 _ACEOF
29819 rm -f conftest.$ac_objext
29820 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
29821   (eval $ac_compile) 2>&5
29822   ac_status=$?
29823   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29824   (exit $ac_status); } &&
29825          { ac_try='test -s conftest.$ac_objext'
29826   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29827   (eval $ac_try) 2>&5
29828   ac_status=$?
29829   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29830   (exit $ac_status); }; }; then
29831   ac_cv_type_pid_t=yes
29832 else
29833   echo "$as_me: failed program was:" >&5
29834 sed 's/^/| /' conftest.$ac_ext >&5
29835
29836 ac_cv_type_pid_t=no
29837 fi
29838 rm -f conftest.$ac_objext conftest.$ac_ext
29839 fi
29840 echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
29841 echo "${ECHO_T}$ac_cv_type_pid_t" >&6
29842 if test $ac_cv_type_pid_t = yes; then
29843   :
29844 else
29845
29846 cat >>confdefs.h <<_ACEOF
29847 #define pid_t int
29848 _ACEOF
29849
29850 fi
29851
29852 echo "$as_me:$LINENO: checking for ptrdiff_t" >&5
29853 echo $ECHO_N "checking for ptrdiff_t... $ECHO_C" >&6
29854 if test "${ac_cv_type_ptrdiff_t+set}" = set; then
29855   echo $ECHO_N "(cached) $ECHO_C" >&6
29856 else
29857   cat >conftest.$ac_ext <<_ACEOF
29858 #line $LINENO "configure"
29859 /* confdefs.h.  */
29860 _ACEOF
29861 cat confdefs.h >>conftest.$ac_ext
29862 cat >>conftest.$ac_ext <<_ACEOF
29863 /* end confdefs.h.  */
29864 $ac_includes_default
29865 int
29866 main ()
29867 {
29868 if ((ptrdiff_t *) 0)
29869   return 0;
29870 if (sizeof (ptrdiff_t))
29871   return 0;
29872   ;
29873   return 0;
29874 }
29875 _ACEOF
29876 rm -f conftest.$ac_objext
29877 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
29878   (eval $ac_compile) 2>&5
29879   ac_status=$?
29880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29881   (exit $ac_status); } &&
29882          { ac_try='test -s conftest.$ac_objext'
29883   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29884   (eval $ac_try) 2>&5
29885   ac_status=$?
29886   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29887   (exit $ac_status); }; }; then
29888   ac_cv_type_ptrdiff_t=yes
29889 else
29890   echo "$as_me: failed program was:" >&5
29891 sed 's/^/| /' conftest.$ac_ext >&5
29892
29893 ac_cv_type_ptrdiff_t=no
29894 fi
29895 rm -f conftest.$ac_objext conftest.$ac_ext
29896 fi
29897 echo "$as_me:$LINENO: result: $ac_cv_type_ptrdiff_t" >&5
29898 echo "${ECHO_T}$ac_cv_type_ptrdiff_t" >&6
29899 if test $ac_cv_type_ptrdiff_t = yes; then
29900
29901 cat >>confdefs.h <<_ACEOF
29902 #define HAVE_PTRDIFF_T 1
29903 _ACEOF
29904
29905
29906 fi
29907 echo "$as_me:$LINENO: checking for uintmax_t" >&5
29908 echo $ECHO_N "checking for uintmax_t... $ECHO_C" >&6
29909 if test "${ac_cv_type_uintmax_t+set}" = set; then
29910   echo $ECHO_N "(cached) $ECHO_C" >&6
29911 else
29912   cat >conftest.$ac_ext <<_ACEOF
29913 #line $LINENO "configure"
29914 /* confdefs.h.  */
29915 _ACEOF
29916 cat confdefs.h >>conftest.$ac_ext
29917 cat >>conftest.$ac_ext <<_ACEOF
29918 /* end confdefs.h.  */
29919 $ac_includes_default
29920 int
29921 main ()
29922 {
29923 if ((uintmax_t *) 0)
29924   return 0;
29925 if (sizeof (uintmax_t))
29926   return 0;
29927   ;
29928   return 0;
29929 }
29930 _ACEOF
29931 rm -f conftest.$ac_objext
29932 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
29933   (eval $ac_compile) 2>&5
29934   ac_status=$?
29935   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29936   (exit $ac_status); } &&
29937          { ac_try='test -s conftest.$ac_objext'
29938   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
29939   (eval $ac_try) 2>&5
29940   ac_status=$?
29941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29942   (exit $ac_status); }; }; then
29943   ac_cv_type_uintmax_t=yes
29944 else
29945   echo "$as_me: failed program was:" >&5
29946 sed 's/^/| /' conftest.$ac_ext >&5
29947
29948 ac_cv_type_uintmax_t=no
29949 fi
29950 rm -f conftest.$ac_objext conftest.$ac_ext
29951 fi
29952 echo "$as_me:$LINENO: result: $ac_cv_type_uintmax_t" >&5
29953 echo "${ECHO_T}$ac_cv_type_uintmax_t" >&6
29954 if test $ac_cv_type_uintmax_t = yes; then
29955
29956 cat >>confdefs.h <<_ACEOF
29957 #define HAVE_UINTMAX_T 1
29958 _ACEOF
29959
29960
29961 fi
29962
29963 echo "$as_me:$LINENO: checking return type of signal handlers" >&5
29964 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
29965 if test "${ac_cv_type_signal+set}" = set; then
29966   echo $ECHO_N "(cached) $ECHO_C" >&6
29967 else
29968   cat >conftest.$ac_ext <<_ACEOF
29969 #line $LINENO "configure"
29970 /* confdefs.h.  */
29971 _ACEOF
29972 cat confdefs.h >>conftest.$ac_ext
29973 cat >>conftest.$ac_ext <<_ACEOF
29974 /* end confdefs.h.  */
29975 #include <sys/types.h>
29976 #include <signal.h>
29977 #ifdef signal
29978 # undef signal
29979 #endif
29980 #ifdef __cplusplus
29981 extern "C" void (*signal (int, void (*)(int)))(int);
29982 #else
29983 void (*signal ()) ();
29984 #endif
29985
29986 int
29987 main ()
29988 {
29989 int i;
29990   ;
29991   return 0;
29992 }
29993 _ACEOF
29994 rm -f conftest.$ac_objext
29995 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
29996   (eval $ac_compile) 2>&5
29997   ac_status=$?
29998   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29999   (exit $ac_status); } &&
30000          { ac_try='test -s conftest.$ac_objext'
30001   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30002   (eval $ac_try) 2>&5
30003   ac_status=$?
30004   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30005   (exit $ac_status); }; }; then
30006   ac_cv_type_signal=void
30007 else
30008   echo "$as_me: failed program was:" >&5
30009 sed 's/^/| /' conftest.$ac_ext >&5
30010
30011 ac_cv_type_signal=int
30012 fi
30013 rm -f conftest.$ac_objext conftest.$ac_ext
30014 fi
30015 echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
30016 echo "${ECHO_T}$ac_cv_type_signal" >&6
30017
30018 cat >>confdefs.h <<_ACEOF
30019 #define RETSIGTYPE $ac_cv_type_signal
30020 _ACEOF
30021
30022
30023 echo "$as_me:$LINENO: checking for size_t" >&5
30024 echo $ECHO_N "checking for size_t... $ECHO_C" >&6
30025 if test "${ac_cv_type_size_t+set}" = set; then
30026   echo $ECHO_N "(cached) $ECHO_C" >&6
30027 else
30028   cat >conftest.$ac_ext <<_ACEOF
30029 #line $LINENO "configure"
30030 /* confdefs.h.  */
30031 _ACEOF
30032 cat confdefs.h >>conftest.$ac_ext
30033 cat >>conftest.$ac_ext <<_ACEOF
30034 /* end confdefs.h.  */
30035 $ac_includes_default
30036 int
30037 main ()
30038 {
30039 if ((size_t *) 0)
30040   return 0;
30041 if (sizeof (size_t))
30042   return 0;
30043   ;
30044   return 0;
30045 }
30046 _ACEOF
30047 rm -f conftest.$ac_objext
30048 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30049   (eval $ac_compile) 2>&5
30050   ac_status=$?
30051   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30052   (exit $ac_status); } &&
30053          { ac_try='test -s conftest.$ac_objext'
30054   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30055   (eval $ac_try) 2>&5
30056   ac_status=$?
30057   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30058   (exit $ac_status); }; }; then
30059   ac_cv_type_size_t=yes
30060 else
30061   echo "$as_me: failed program was:" >&5
30062 sed 's/^/| /' conftest.$ac_ext >&5
30063
30064 ac_cv_type_size_t=no
30065 fi
30066 rm -f conftest.$ac_objext conftest.$ac_ext
30067 fi
30068 echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
30069 echo "${ECHO_T}$ac_cv_type_size_t" >&6
30070 if test $ac_cv_type_size_t = yes; then
30071   :
30072 else
30073
30074 cat >>confdefs.h <<_ACEOF
30075 #define size_t unsigned
30076 _ACEOF
30077
30078 fi
30079
30080
30081 echo "$as_me:$LINENO: checking for ssize_t" >&5
30082 echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6
30083 if test "${ac_cv_type_ssize_t+set}" = set; then
30084   echo $ECHO_N "(cached) $ECHO_C" >&6
30085 else
30086   cat >conftest.$ac_ext <<_ACEOF
30087 #line $LINENO "configure"
30088 /* confdefs.h.  */
30089 _ACEOF
30090 cat confdefs.h >>conftest.$ac_ext
30091 cat >>conftest.$ac_ext <<_ACEOF
30092 /* end confdefs.h.  */
30093 $ac_includes_default
30094 int
30095 main ()
30096 {
30097 if ((ssize_t *) 0)
30098   return 0;
30099 if (sizeof (ssize_t))
30100   return 0;
30101   ;
30102   return 0;
30103 }
30104 _ACEOF
30105 rm -f conftest.$ac_objext
30106 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30107   (eval $ac_compile) 2>&5
30108   ac_status=$?
30109   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30110   (exit $ac_status); } &&
30111          { ac_try='test -s conftest.$ac_objext'
30112   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30113   (eval $ac_try) 2>&5
30114   ac_status=$?
30115   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30116   (exit $ac_status); }; }; then
30117   ac_cv_type_ssize_t=yes
30118 else
30119   echo "$as_me: failed program was:" >&5
30120 sed 's/^/| /' conftest.$ac_ext >&5
30121
30122 ac_cv_type_ssize_t=no
30123 fi
30124 rm -f conftest.$ac_objext conftest.$ac_ext
30125 fi
30126 echo "$as_me:$LINENO: result: $ac_cv_type_ssize_t" >&5
30127 echo "${ECHO_T}$ac_cv_type_ssize_t" >&6
30128 if test $ac_cv_type_ssize_t = yes; then
30129
30130 cat >>confdefs.h <<_ACEOF
30131 #define HAVE_SSIZE_T 1
30132 _ACEOF
30133
30134
30135 fi
30136 echo "$as_me:$LINENO: checking for signed int" >&5
30137 echo $ECHO_N "checking for signed int... $ECHO_C" >&6
30138 if test "${ac_cv_type_signed_int+set}" = set; then
30139   echo $ECHO_N "(cached) $ECHO_C" >&6
30140 else
30141   cat >conftest.$ac_ext <<_ACEOF
30142 #line $LINENO "configure"
30143 /* confdefs.h.  */
30144 _ACEOF
30145 cat confdefs.h >>conftest.$ac_ext
30146 cat >>conftest.$ac_ext <<_ACEOF
30147 /* end confdefs.h.  */
30148 $ac_includes_default
30149 int
30150 main ()
30151 {
30152 if ((signed int *) 0)
30153   return 0;
30154 if (sizeof (signed int))
30155   return 0;
30156   ;
30157   return 0;
30158 }
30159 _ACEOF
30160 rm -f conftest.$ac_objext
30161 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30162   (eval $ac_compile) 2>&5
30163   ac_status=$?
30164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30165   (exit $ac_status); } &&
30166          { ac_try='test -s conftest.$ac_objext'
30167   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30168   (eval $ac_try) 2>&5
30169   ac_status=$?
30170   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30171   (exit $ac_status); }; }; then
30172   ac_cv_type_signed_int=yes
30173 else
30174   echo "$as_me: failed program was:" >&5
30175 sed 's/^/| /' conftest.$ac_ext >&5
30176
30177 ac_cv_type_signed_int=no
30178 fi
30179 rm -f conftest.$ac_objext conftest.$ac_ext
30180 fi
30181 echo "$as_me:$LINENO: result: $ac_cv_type_signed_int" >&5
30182 echo "${ECHO_T}$ac_cv_type_signed_int" >&6
30183 if test $ac_cv_type_signed_int = yes; then
30184
30185 cat >>confdefs.h <<_ACEOF
30186 #define HAVE_SIGNED_INT 1
30187 _ACEOF
30188
30189
30190 fi
30191
30192 echo "$as_me:$LINENO: checking for caddr_t" >&5
30193 echo $ECHO_N "checking for caddr_t... $ECHO_C" >&6
30194 if test "${ac_cv_type_caddr_t+set}" = set; then
30195   echo $ECHO_N "(cached) $ECHO_C" >&6
30196 else
30197   cat >conftest.$ac_ext <<_ACEOF
30198 #line $LINENO "configure"
30199 /* confdefs.h.  */
30200 _ACEOF
30201 cat confdefs.h >>conftest.$ac_ext
30202 cat >>conftest.$ac_ext <<_ACEOF
30203 /* end confdefs.h.  */
30204 $ac_includes_default
30205 int
30206 main ()
30207 {
30208 if ((caddr_t *) 0)
30209   return 0;
30210 if (sizeof (caddr_t))
30211   return 0;
30212   ;
30213   return 0;
30214 }
30215 _ACEOF
30216 rm -f conftest.$ac_objext
30217 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30218   (eval $ac_compile) 2>&5
30219   ac_status=$?
30220   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30221   (exit $ac_status); } &&
30222          { ac_try='test -s conftest.$ac_objext'
30223   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30224   (eval $ac_try) 2>&5
30225   ac_status=$?
30226   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30227   (exit $ac_status); }; }; then
30228   ac_cv_type_caddr_t=yes
30229 else
30230   echo "$as_me: failed program was:" >&5
30231 sed 's/^/| /' conftest.$ac_ext >&5
30232
30233 ac_cv_type_caddr_t=no
30234 fi
30235 rm -f conftest.$ac_objext conftest.$ac_ext
30236 fi
30237 echo "$as_me:$LINENO: result: $ac_cv_type_caddr_t" >&5
30238 echo "${ECHO_T}$ac_cv_type_caddr_t" >&6
30239 if test $ac_cv_type_caddr_t = yes; then
30240
30241 cat >>confdefs.h <<_ACEOF
30242 #define HAVE_CADDR_T 1
30243 _ACEOF
30244
30245
30246 fi
30247 echo "$as_me:$LINENO: checking for char *" >&5
30248 echo $ECHO_N "checking for char *... $ECHO_C" >&6
30249 if test "${ac_cv_type_char_p+set}" = set; then
30250   echo $ECHO_N "(cached) $ECHO_C" >&6
30251 else
30252   cat >conftest.$ac_ext <<_ACEOF
30253 #line $LINENO "configure"
30254 /* confdefs.h.  */
30255 _ACEOF
30256 cat confdefs.h >>conftest.$ac_ext
30257 cat >>conftest.$ac_ext <<_ACEOF
30258 /* end confdefs.h.  */
30259 $ac_includes_default
30260 int
30261 main ()
30262 {
30263 if ((char * *) 0)
30264   return 0;
30265 if (sizeof (char *))
30266   return 0;
30267   ;
30268   return 0;
30269 }
30270 _ACEOF
30271 rm -f conftest.$ac_objext
30272 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30273   (eval $ac_compile) 2>&5
30274   ac_status=$?
30275   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30276   (exit $ac_status); } &&
30277          { ac_try='test -s conftest.$ac_objext'
30278   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30279   (eval $ac_try) 2>&5
30280   ac_status=$?
30281   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30282   (exit $ac_status); }; }; then
30283   ac_cv_type_char_p=yes
30284 else
30285   echo "$as_me: failed program was:" >&5
30286 sed 's/^/| /' conftest.$ac_ext >&5
30287
30288 ac_cv_type_char_p=no
30289 fi
30290 rm -f conftest.$ac_objext conftest.$ac_ext
30291 fi
30292 echo "$as_me:$LINENO: result: $ac_cv_type_char_p" >&5
30293 echo "${ECHO_T}$ac_cv_type_char_p" >&6
30294 if test $ac_cv_type_char_p = yes; then
30295
30296 cat >>confdefs.h <<_ACEOF
30297 #define HAVE_CHAR_P 1
30298 _ACEOF
30299
30300
30301 fi
30302
30303
30304 echo "$as_me:$LINENO: checking for socklen_t" >&5
30305 echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6
30306 if test "${ol_cv_type_socklen_t+set}" = set; then
30307   echo $ECHO_N "(cached) $ECHO_C" >&6
30308 else
30309   cat >conftest.$ac_ext <<_ACEOF
30310 #line $LINENO "configure"
30311 /* confdefs.h.  */
30312 _ACEOF
30313 cat confdefs.h >>conftest.$ac_ext
30314 cat >>conftest.$ac_ext <<_ACEOF
30315 /* end confdefs.h.  */
30316
30317 #ifdef HAVE_SYS_TYPES_H
30318 #include <sys/types.h>
30319 #endif
30320 #ifdef HAVE_SYS_SOCKET_H
30321 #include <sys/socket.h>
30322 #endif
30323
30324 int
30325 main ()
30326 {
30327 socklen_t len;
30328   ;
30329   return 0;
30330 }
30331 _ACEOF
30332 rm -f conftest.$ac_objext
30333 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30334   (eval $ac_compile) 2>&5
30335   ac_status=$?
30336   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30337   (exit $ac_status); } &&
30338          { ac_try='test -s conftest.$ac_objext'
30339   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30340   (eval $ac_try) 2>&5
30341   ac_status=$?
30342   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30343   (exit $ac_status); }; }; then
30344   ol_cv_type_socklen_t=yes
30345 else
30346   echo "$as_me: failed program was:" >&5
30347 sed 's/^/| /' conftest.$ac_ext >&5
30348
30349 ol_cv_type_socklen_t=no
30350 fi
30351 rm -f conftest.$ac_objext conftest.$ac_ext
30352 fi
30353 echo "$as_me:$LINENO: result: $ol_cv_type_socklen_t" >&5
30354 echo "${ECHO_T}$ol_cv_type_socklen_t" >&6
30355   if test $ol_cv_type_socklen_t = no; then
30356
30357 cat >>confdefs.h <<\_ACEOF
30358 #define socklen_t int
30359 _ACEOF
30360
30361   fi
30362
30363
30364 echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
30365 echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6
30366 if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
30367   echo $ECHO_N "(cached) $ECHO_C" >&6
30368 else
30369   cat >conftest.$ac_ext <<_ACEOF
30370 #line $LINENO "configure"
30371 /* confdefs.h.  */
30372 _ACEOF
30373 cat confdefs.h >>conftest.$ac_ext
30374 cat >>conftest.$ac_ext <<_ACEOF
30375 /* end confdefs.h.  */
30376 $ac_includes_default
30377 int
30378 main ()
30379 {
30380 static struct stat ac_aggr;
30381 if (ac_aggr.st_blksize)
30382 return 0;
30383   ;
30384   return 0;
30385 }
30386 _ACEOF
30387 rm -f conftest.$ac_objext
30388 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30389   (eval $ac_compile) 2>&5
30390   ac_status=$?
30391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30392   (exit $ac_status); } &&
30393          { ac_try='test -s conftest.$ac_objext'
30394   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30395   (eval $ac_try) 2>&5
30396   ac_status=$?
30397   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30398   (exit $ac_status); }; }; then
30399   ac_cv_member_struct_stat_st_blksize=yes
30400 else
30401   echo "$as_me: failed program was:" >&5
30402 sed 's/^/| /' conftest.$ac_ext >&5
30403
30404 cat >conftest.$ac_ext <<_ACEOF
30405 #line $LINENO "configure"
30406 /* confdefs.h.  */
30407 _ACEOF
30408 cat confdefs.h >>conftest.$ac_ext
30409 cat >>conftest.$ac_ext <<_ACEOF
30410 /* end confdefs.h.  */
30411 $ac_includes_default
30412 int
30413 main ()
30414 {
30415 static struct stat ac_aggr;
30416 if (sizeof ac_aggr.st_blksize)
30417 return 0;
30418   ;
30419   return 0;
30420 }
30421 _ACEOF
30422 rm -f conftest.$ac_objext
30423 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30424   (eval $ac_compile) 2>&5
30425   ac_status=$?
30426   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30427   (exit $ac_status); } &&
30428          { ac_try='test -s conftest.$ac_objext'
30429   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30430   (eval $ac_try) 2>&5
30431   ac_status=$?
30432   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30433   (exit $ac_status); }; }; then
30434   ac_cv_member_struct_stat_st_blksize=yes
30435 else
30436   echo "$as_me: failed program was:" >&5
30437 sed 's/^/| /' conftest.$ac_ext >&5
30438
30439 ac_cv_member_struct_stat_st_blksize=no
30440 fi
30441 rm -f conftest.$ac_objext conftest.$ac_ext
30442 fi
30443 rm -f conftest.$ac_objext conftest.$ac_ext
30444 fi
30445 echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
30446 echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6
30447 if test $ac_cv_member_struct_stat_st_blksize = yes; then
30448
30449 cat >>confdefs.h <<_ACEOF
30450 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
30451 _ACEOF
30452
30453
30454 cat >>confdefs.h <<\_ACEOF
30455 #define HAVE_ST_BLKSIZE 1
30456 _ACEOF
30457
30458 fi
30459
30460
30461 echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
30462 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
30463 if test "${ac_cv_header_time+set}" = set; then
30464   echo $ECHO_N "(cached) $ECHO_C" >&6
30465 else
30466   cat >conftest.$ac_ext <<_ACEOF
30467 #line $LINENO "configure"
30468 /* confdefs.h.  */
30469 _ACEOF
30470 cat confdefs.h >>conftest.$ac_ext
30471 cat >>conftest.$ac_ext <<_ACEOF
30472 /* end confdefs.h.  */
30473 #include <sys/types.h>
30474 #include <sys/time.h>
30475 #include <time.h>
30476
30477 int
30478 main ()
30479 {
30480 if ((struct tm *) 0)
30481 return 0;
30482   ;
30483   return 0;
30484 }
30485 _ACEOF
30486 rm -f conftest.$ac_objext
30487 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30488   (eval $ac_compile) 2>&5
30489   ac_status=$?
30490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30491   (exit $ac_status); } &&
30492          { ac_try='test -s conftest.$ac_objext'
30493   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30494   (eval $ac_try) 2>&5
30495   ac_status=$?
30496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30497   (exit $ac_status); }; }; then
30498   ac_cv_header_time=yes
30499 else
30500   echo "$as_me: failed program was:" >&5
30501 sed 's/^/| /' conftest.$ac_ext >&5
30502
30503 ac_cv_header_time=no
30504 fi
30505 rm -f conftest.$ac_objext conftest.$ac_ext
30506 fi
30507 echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
30508 echo "${ECHO_T}$ac_cv_header_time" >&6
30509 if test $ac_cv_header_time = yes; then
30510
30511 cat >>confdefs.h <<\_ACEOF
30512 #define TIME_WITH_SYS_TIME 1
30513 _ACEOF
30514
30515 fi
30516
30517 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
30518 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
30519 if test "${ac_cv_struct_tm+set}" = set; then
30520   echo $ECHO_N "(cached) $ECHO_C" >&6
30521 else
30522   cat >conftest.$ac_ext <<_ACEOF
30523 #line $LINENO "configure"
30524 /* confdefs.h.  */
30525 _ACEOF
30526 cat confdefs.h >>conftest.$ac_ext
30527 cat >>conftest.$ac_ext <<_ACEOF
30528 /* end confdefs.h.  */
30529 #include <sys/types.h>
30530 #include <time.h>
30531
30532 int
30533 main ()
30534 {
30535 struct tm *tp; tp->tm_sec;
30536   ;
30537   return 0;
30538 }
30539 _ACEOF
30540 rm -f conftest.$ac_objext
30541 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30542   (eval $ac_compile) 2>&5
30543   ac_status=$?
30544   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30545   (exit $ac_status); } &&
30546          { ac_try='test -s conftest.$ac_objext'
30547   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30548   (eval $ac_try) 2>&5
30549   ac_status=$?
30550   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30551   (exit $ac_status); }; }; then
30552   ac_cv_struct_tm=time.h
30553 else
30554   echo "$as_me: failed program was:" >&5
30555 sed 's/^/| /' conftest.$ac_ext >&5
30556
30557 ac_cv_struct_tm=sys/time.h
30558 fi
30559 rm -f conftest.$ac_objext conftest.$ac_ext
30560 fi
30561 echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
30562 echo "${ECHO_T}$ac_cv_struct_tm" >&6
30563 if test $ac_cv_struct_tm = sys/time.h; then
30564
30565 cat >>confdefs.h <<\_ACEOF
30566 #define TM_IN_SYS_TIME 1
30567 _ACEOF
30568
30569 fi
30570
30571 echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5
30572 echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6
30573 if test "${ac_cv_type_uid_t+set}" = set; then
30574   echo $ECHO_N "(cached) $ECHO_C" >&6
30575 else
30576   cat >conftest.$ac_ext <<_ACEOF
30577 #line $LINENO "configure"
30578 /* confdefs.h.  */
30579 _ACEOF
30580 cat confdefs.h >>conftest.$ac_ext
30581 cat >>conftest.$ac_ext <<_ACEOF
30582 /* end confdefs.h.  */
30583 #include <sys/types.h>
30584
30585 _ACEOF
30586 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30587   $EGREP "uid_t" >/dev/null 2>&1; then
30588   ac_cv_type_uid_t=yes
30589 else
30590   ac_cv_type_uid_t=no
30591 fi
30592 rm -f conftest*
30593
30594 fi
30595 echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5
30596 echo "${ECHO_T}$ac_cv_type_uid_t" >&6
30597 if test $ac_cv_type_uid_t = no; then
30598
30599 cat >>confdefs.h <<\_ACEOF
30600 #define uid_t int
30601 _ACEOF
30602
30603
30604 cat >>confdefs.h <<\_ACEOF
30605 #define gid_t int
30606 _ACEOF
30607
30608 fi
30609
30610 echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
30611 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6
30612 if test "${ol_cv_type_sig_atomic_t+set}" = set; then
30613   echo $ECHO_N "(cached) $ECHO_C" >&6
30614 else
30615   cat >conftest.$ac_ext <<_ACEOF
30616 #line $LINENO "configure"
30617 /* confdefs.h.  */
30618 _ACEOF
30619 cat confdefs.h >>conftest.$ac_ext
30620 cat >>conftest.$ac_ext <<_ACEOF
30621 /* end confdefs.h.  */
30622 #include <signal.h>
30623 int
30624 main ()
30625 {
30626 sig_atomic_t atomic;
30627   ;
30628   return 0;
30629 }
30630 _ACEOF
30631 rm -f conftest.$ac_objext
30632 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30633   (eval $ac_compile) 2>&5
30634   ac_status=$?
30635   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30636   (exit $ac_status); } &&
30637          { ac_try='test -s conftest.$ac_objext'
30638   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30639   (eval $ac_try) 2>&5
30640   ac_status=$?
30641   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30642   (exit $ac_status); }; }; then
30643   ol_cv_type_sig_atomic_t=yes
30644 else
30645   echo "$as_me: failed program was:" >&5
30646 sed 's/^/| /' conftest.$ac_ext >&5
30647
30648 ol_cv_type_sig_atomic_t=no
30649 fi
30650 rm -f conftest.$ac_objext conftest.$ac_ext
30651 fi
30652 echo "$as_me:$LINENO: result: $ol_cv_type_sig_atomic_t" >&5
30653 echo "${ECHO_T}$ol_cv_type_sig_atomic_t" >&6
30654   if test $ol_cv_type_sig_atomic_t = no; then
30655
30656 cat >>confdefs.h <<\_ACEOF
30657 #define sig_atomic_t int
30658 _ACEOF
30659
30660   fi
30661
30662
30663
30664 # test for pw_gecos in struct passwd
30665 echo "$as_me:$LINENO: checking struct passwd for pw_gecos" >&5
30666 echo $ECHO_N "checking struct passwd for pw_gecos... $ECHO_C" >&6
30667 if test "${ol_cv_struct_passwd_pw_gecos+set}" = set; then
30668   echo $ECHO_N "(cached) $ECHO_C" >&6
30669 else
30670
30671         cat >conftest.$ac_ext <<_ACEOF
30672 #line $LINENO "configure"
30673 /* confdefs.h.  */
30674 _ACEOF
30675 cat confdefs.h >>conftest.$ac_ext
30676 cat >>conftest.$ac_ext <<_ACEOF
30677 /* end confdefs.h.  */
30678 #include <pwd.h>
30679 int
30680 main ()
30681 {
30682
30683         struct passwd pwd;
30684         pwd.pw_gecos = pwd.pw_name;
30685
30686   ;
30687   return 0;
30688 }
30689 _ACEOF
30690 rm -f conftest.$ac_objext
30691 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30692   (eval $ac_compile) 2>&5
30693   ac_status=$?
30694   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30695   (exit $ac_status); } &&
30696          { ac_try='test -s conftest.$ac_objext'
30697   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30698   (eval $ac_try) 2>&5
30699   ac_status=$?
30700   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30701   (exit $ac_status); }; }; then
30702   ol_cv_struct_passwd_pw_gecos=yes
30703 else
30704   echo "$as_me: failed program was:" >&5
30705 sed 's/^/| /' conftest.$ac_ext >&5
30706
30707 ol_cv_struct_passwd_pw_gecos=no
30708 fi
30709 rm -f conftest.$ac_objext conftest.$ac_ext
30710 fi
30711 echo "$as_me:$LINENO: result: $ol_cv_struct_passwd_pw_gecos" >&5
30712 echo "${ECHO_T}$ol_cv_struct_passwd_pw_gecos" >&6
30713 if test $ol_cv_struct_passwd_pw_gecos = yes ; then
30714
30715 cat >>confdefs.h <<\_ACEOF
30716 #define HAVE_PW_GECOS 1
30717 _ACEOF
30718
30719 fi
30720
30721 # test for pw_passwd in struct passwd
30722 echo "$as_me:$LINENO: checking struct passwd for pw_passwd" >&5
30723 echo $ECHO_N "checking struct passwd for pw_passwd... $ECHO_C" >&6
30724 if test "${ol_cv_struct_passwd_pw_passwd+set}" = set; then
30725   echo $ECHO_N "(cached) $ECHO_C" >&6
30726 else
30727
30728         cat >conftest.$ac_ext <<_ACEOF
30729 #line $LINENO "configure"
30730 /* confdefs.h.  */
30731 _ACEOF
30732 cat confdefs.h >>conftest.$ac_ext
30733 cat >>conftest.$ac_ext <<_ACEOF
30734 /* end confdefs.h.  */
30735 #include <pwd.h>
30736 int
30737 main ()
30738 {
30739
30740         struct passwd pwd;
30741         pwd.pw_passwd = pwd.pw_name;
30742
30743   ;
30744   return 0;
30745 }
30746 _ACEOF
30747 rm -f conftest.$ac_objext
30748 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30749   (eval $ac_compile) 2>&5
30750   ac_status=$?
30751   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30752   (exit $ac_status); } &&
30753          { ac_try='test -s conftest.$ac_objext'
30754   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30755   (eval $ac_try) 2>&5
30756   ac_status=$?
30757   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30758   (exit $ac_status); }; }; then
30759   ol_cv_struct_passwd_pw_passwd=yes
30760 else
30761   echo "$as_me: failed program was:" >&5
30762 sed 's/^/| /' conftest.$ac_ext >&5
30763
30764 ol_cv_struct_passwd_pw_passwd=no
30765 fi
30766 rm -f conftest.$ac_objext conftest.$ac_ext
30767 fi
30768 echo "$as_me:$LINENO: result: $ol_cv_struct_passwd_pw_passwd" >&5
30769 echo "${ECHO_T}$ol_cv_struct_passwd_pw_passwd" >&6
30770 if test $ol_cv_struct_passwd_pw_passwd = yes ; then
30771
30772 cat >>confdefs.h <<\_ACEOF
30773 #define HAVE_PW_PASSWD 1
30774 _ACEOF
30775
30776 fi
30777
30778
30779 echo "$as_me:$LINENO: checking if toupper() requires islower()" >&5
30780 echo $ECHO_N "checking if toupper() requires islower()... $ECHO_C" >&6
30781 if test "${ol_cv_c_upper_lower+set}" = set; then
30782   echo $ECHO_N "(cached) $ECHO_C" >&6
30783 else
30784
30785         if test "$cross_compiling" = yes; then
30786   ol_cv_c_upper_lower=safe
30787 else
30788   cat >conftest.$ac_ext <<_ACEOF
30789 #line $LINENO "configure"
30790 /* confdefs.h.  */
30791 _ACEOF
30792 cat confdefs.h >>conftest.$ac_ext
30793 cat >>conftest.$ac_ext <<_ACEOF
30794 /* end confdefs.h.  */
30795
30796 #include <ctype.h>
30797 main()
30798 {
30799         if ('C' == toupper('C'))
30800                 exit(0);
30801         else
30802                 exit(1);
30803 }
30804 _ACEOF
30805 rm -f conftest$ac_exeext
30806 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
30807   (eval $ac_link) 2>&5
30808   ac_status=$?
30809   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30810   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
30811   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30812   (eval $ac_try) 2>&5
30813   ac_status=$?
30814   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30815   (exit $ac_status); }; }; then
30816   ol_cv_c_upper_lower=no
30817 else
30818   echo "$as_me: program exited with status $ac_status" >&5
30819 echo "$as_me: failed program was:" >&5
30820 sed 's/^/| /' conftest.$ac_ext >&5
30821
30822 ( exit $ac_status )
30823 ol_cv_c_upper_lower=yes
30824 fi
30825 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
30826 fi
30827 fi
30828 echo "$as_me:$LINENO: result: $ol_cv_c_upper_lower" >&5
30829 echo "${ECHO_T}$ol_cv_c_upper_lower" >&6
30830 if test $ol_cv_c_upper_lower != no ; then
30831
30832 cat >>confdefs.h <<\_ACEOF
30833 #define C_UPPER_LOWER 1
30834 _ACEOF
30835
30836 fi
30837
30838 echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
30839 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
30840 if test "${ac_cv_c_const+set}" = set; then
30841   echo $ECHO_N "(cached) $ECHO_C" >&6
30842 else
30843   cat >conftest.$ac_ext <<_ACEOF
30844 #line $LINENO "configure"
30845 /* confdefs.h.  */
30846 _ACEOF
30847 cat confdefs.h >>conftest.$ac_ext
30848 cat >>conftest.$ac_ext <<_ACEOF
30849 /* end confdefs.h.  */
30850
30851 int
30852 main ()
30853 {
30854 /* FIXME: Include the comments suggested by Paul. */
30855 #ifndef __cplusplus
30856   /* Ultrix mips cc rejects this.  */
30857   typedef int charset[2];
30858   const charset x;
30859   /* SunOS 4.1.1 cc rejects this.  */
30860   char const *const *ccp;
30861   char **p;
30862   /* NEC SVR4.0.2 mips cc rejects this.  */
30863   struct point {int x, y;};
30864   static struct point const zero = {0,0};
30865   /* AIX XL C 1.02.0.0 rejects this.
30866      It does not let you subtract one const X* pointer from another in
30867      an arm of an if-expression whose if-part is not a constant
30868      expression */
30869   const char *g = "string";
30870   ccp = &g + (g ? g-g : 0);
30871   /* HPUX 7.0 cc rejects these. */
30872   ++ccp;
30873   p = (char**) ccp;
30874   ccp = (char const *const *) p;
30875   { /* SCO 3.2v4 cc rejects this.  */
30876     char *t;
30877     char const *s = 0 ? (char *) 0 : (char const *) 0;
30878
30879     *t++ = 0;
30880   }
30881   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
30882     int x[] = {25, 17};
30883     const int *foo = &x[0];
30884     ++foo;
30885   }
30886   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
30887     typedef const int *iptr;
30888     iptr p = 0;
30889     ++p;
30890   }
30891   { /* AIX XL C 1.02.0.0 rejects this saying
30892        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
30893     struct s { int j; const int *ap[3]; };
30894     struct s *b; b->j = 5;
30895   }
30896   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
30897     const int foo = 10;
30898   }
30899 #endif
30900
30901   ;
30902   return 0;
30903 }
30904 _ACEOF
30905 rm -f conftest.$ac_objext
30906 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30907   (eval $ac_compile) 2>&5
30908   ac_status=$?
30909   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30910   (exit $ac_status); } &&
30911          { ac_try='test -s conftest.$ac_objext'
30912   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30913   (eval $ac_try) 2>&5
30914   ac_status=$?
30915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30916   (exit $ac_status); }; }; then
30917   ac_cv_c_const=yes
30918 else
30919   echo "$as_me: failed program was:" >&5
30920 sed 's/^/| /' conftest.$ac_ext >&5
30921
30922 ac_cv_c_const=no
30923 fi
30924 rm -f conftest.$ac_objext conftest.$ac_ext
30925 fi
30926 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
30927 echo "${ECHO_T}$ac_cv_c_const" >&6
30928 if test $ac_cv_c_const = no; then
30929
30930 cat >>confdefs.h <<\_ACEOF
30931 #define const
30932 _ACEOF
30933
30934 fi
30935
30936 echo "$as_me:$LINENO: checking if compiler understands volatile" >&5
30937 echo $ECHO_N "checking if compiler understands volatile... $ECHO_C" >&6
30938 if test "${ol_cv_c_volatile+set}" = set; then
30939   echo $ECHO_N "(cached) $ECHO_C" >&6
30940 else
30941   cat >conftest.$ac_ext <<_ACEOF
30942 #line $LINENO "configure"
30943 /* confdefs.h.  */
30944 _ACEOF
30945 cat confdefs.h >>conftest.$ac_ext
30946 cat >>conftest.$ac_ext <<_ACEOF
30947 /* end confdefs.h.  */
30948 int x, y, z;
30949 int
30950 main ()
30951 {
30952 volatile int a; int * volatile b = x ? &y : &z;
30953       /* Older MIPS compilers (eg., in Ultrix 4.2) don't like *b = 0 */
30954       *b = 0;
30955   ;
30956   return 0;
30957 }
30958 _ACEOF
30959 rm -f conftest.$ac_objext
30960 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
30961   (eval $ac_compile) 2>&5
30962   ac_status=$?
30963   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30964   (exit $ac_status); } &&
30965          { ac_try='test -s conftest.$ac_objext'
30966   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
30967   (eval $ac_try) 2>&5
30968   ac_status=$?
30969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30970   (exit $ac_status); }; }; then
30971   ol_cv_c_volatile=yes
30972 else
30973   echo "$as_me: failed program was:" >&5
30974 sed 's/^/| /' conftest.$ac_ext >&5
30975
30976 ol_cv_c_volatile=no
30977 fi
30978 rm -f conftest.$ac_objext conftest.$ac_ext
30979 fi
30980 echo "$as_me:$LINENO: result: $ol_cv_c_volatile" >&5
30981 echo "${ECHO_T}$ol_cv_c_volatile" >&6
30982   if test $ol_cv_c_volatile = yes; then
30983     :
30984   else
30985
30986 cat >>confdefs.h <<\_ACEOF
30987 #define volatile
30988 _ACEOF
30989
30990   fi
30991
30992
30993 if test $cross_compiling = yes ; then
30994
30995 cat >>confdefs.h <<\_ACEOF
30996 #define CROSS_COMPILING 1
30997 _ACEOF
30998
30999 else
31000         echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
31001 echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
31002 if test "${ac_cv_c_bigendian+set}" = set; then
31003   echo $ECHO_N "(cached) $ECHO_C" >&6
31004 else
31005   # See if sys/param.h defines the BYTE_ORDER macro.
31006 cat >conftest.$ac_ext <<_ACEOF
31007 #line $LINENO "configure"
31008 /* confdefs.h.  */
31009 _ACEOF
31010 cat confdefs.h >>conftest.$ac_ext
31011 cat >>conftest.$ac_ext <<_ACEOF
31012 /* end confdefs.h.  */
31013 #include <sys/types.h>
31014 #include <sys/param.h>
31015
31016 int
31017 main ()
31018 {
31019 #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
31020  bogus endian macros
31021 #endif
31022
31023   ;
31024   return 0;
31025 }
31026 _ACEOF
31027 rm -f conftest.$ac_objext
31028 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31029   (eval $ac_compile) 2>&5
31030   ac_status=$?
31031   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31032   (exit $ac_status); } &&
31033          { ac_try='test -s conftest.$ac_objext'
31034   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31035   (eval $ac_try) 2>&5
31036   ac_status=$?
31037   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31038   (exit $ac_status); }; }; then
31039   # It does; now see whether it defined to BIG_ENDIAN or not.
31040 cat >conftest.$ac_ext <<_ACEOF
31041 #line $LINENO "configure"
31042 /* confdefs.h.  */
31043 _ACEOF
31044 cat confdefs.h >>conftest.$ac_ext
31045 cat >>conftest.$ac_ext <<_ACEOF
31046 /* end confdefs.h.  */
31047 #include <sys/types.h>
31048 #include <sys/param.h>
31049
31050 int
31051 main ()
31052 {
31053 #if BYTE_ORDER != BIG_ENDIAN
31054  not big endian
31055 #endif
31056
31057   ;
31058   return 0;
31059 }
31060 _ACEOF
31061 rm -f conftest.$ac_objext
31062 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31063   (eval $ac_compile) 2>&5
31064   ac_status=$?
31065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31066   (exit $ac_status); } &&
31067          { ac_try='test -s conftest.$ac_objext'
31068   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31069   (eval $ac_try) 2>&5
31070   ac_status=$?
31071   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31072   (exit $ac_status); }; }; then
31073   ac_cv_c_bigendian=yes
31074 else
31075   echo "$as_me: failed program was:" >&5
31076 sed 's/^/| /' conftest.$ac_ext >&5
31077
31078 ac_cv_c_bigendian=no
31079 fi
31080 rm -f conftest.$ac_objext conftest.$ac_ext
31081 else
31082   echo "$as_me: failed program was:" >&5
31083 sed 's/^/| /' conftest.$ac_ext >&5
31084
31085 # It does not; compile a test program.
31086 if test "$cross_compiling" = yes; then
31087   # try to guess the endianness by grepping values into an object file
31088   ac_cv_c_bigendian=unknown
31089   cat >conftest.$ac_ext <<_ACEOF
31090 #line $LINENO "configure"
31091 /* confdefs.h.  */
31092 _ACEOF
31093 cat confdefs.h >>conftest.$ac_ext
31094 cat >>conftest.$ac_ext <<_ACEOF
31095 /* end confdefs.h.  */
31096 short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
31097 short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
31098 void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
31099 short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
31100 short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
31101 void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
31102 int
31103 main ()
31104 {
31105  _ascii (); _ebcdic ();
31106   ;
31107   return 0;
31108 }
31109 _ACEOF
31110 rm -f conftest.$ac_objext
31111 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31112   (eval $ac_compile) 2>&5
31113   ac_status=$?
31114   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31115   (exit $ac_status); } &&
31116          { ac_try='test -s conftest.$ac_objext'
31117   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31118   (eval $ac_try) 2>&5
31119   ac_status=$?
31120   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31121   (exit $ac_status); }; }; then
31122   if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
31123   ac_cv_c_bigendian=yes
31124 fi
31125 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
31126   if test "$ac_cv_c_bigendian" = unknown; then
31127     ac_cv_c_bigendian=no
31128   else
31129     # finding both strings is unlikely to happen, but who knows?
31130     ac_cv_c_bigendian=unknown
31131   fi
31132 fi
31133 else
31134   echo "$as_me: failed program was:" >&5
31135 sed 's/^/| /' conftest.$ac_ext >&5
31136
31137 fi
31138 rm -f conftest.$ac_objext conftest.$ac_ext
31139 else
31140   cat >conftest.$ac_ext <<_ACEOF
31141 #line $LINENO "configure"
31142 /* confdefs.h.  */
31143 _ACEOF
31144 cat confdefs.h >>conftest.$ac_ext
31145 cat >>conftest.$ac_ext <<_ACEOF
31146 /* end confdefs.h.  */
31147 int
31148 main ()
31149 {
31150   /* Are we little or big endian?  From Harbison&Steele.  */
31151   union
31152   {
31153     long l;
31154     char c[sizeof (long)];
31155   } u;
31156   u.l = 1;
31157   exit (u.c[sizeof (long) - 1] == 1);
31158 }
31159 _ACEOF
31160 rm -f conftest$ac_exeext
31161 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31162   (eval $ac_link) 2>&5
31163   ac_status=$?
31164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31165   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
31166   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31167   (eval $ac_try) 2>&5
31168   ac_status=$?
31169   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31170   (exit $ac_status); }; }; then
31171   ac_cv_c_bigendian=no
31172 else
31173   echo "$as_me: program exited with status $ac_status" >&5
31174 echo "$as_me: failed program was:" >&5
31175 sed 's/^/| /' conftest.$ac_ext >&5
31176
31177 ( exit $ac_status )
31178 ac_cv_c_bigendian=yes
31179 fi
31180 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
31181 fi
31182 fi
31183 rm -f conftest.$ac_objext conftest.$ac_ext
31184 fi
31185 echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
31186 echo "${ECHO_T}$ac_cv_c_bigendian" >&6
31187 case $ac_cv_c_bigendian in
31188   yes)
31189
31190 cat >>confdefs.h <<\_ACEOF
31191 #define WORDS_BIGENDIAN 1
31192 _ACEOF
31193  ;;
31194   no)
31195      ;;
31196   *)
31197     { { echo "$as_me:$LINENO: error: unknown endianness
31198 presetting ac_cv_c_bigendian=no (or yes) will help" >&5
31199 echo "$as_me: error: unknown endianness
31200 presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
31201    { (exit 1); exit 1; }; } ;;
31202 esac
31203
31204 fi
31205
31206 echo "$as_me:$LINENO: checking size of short" >&5
31207 echo $ECHO_N "checking size of short... $ECHO_C" >&6
31208 if test "${ac_cv_sizeof_short+set}" = set; then
31209   echo $ECHO_N "(cached) $ECHO_C" >&6
31210 else
31211   for ac_size in 4 8 1 2 16  ; do # List sizes in rough order of prevalence.
31212   cat >conftest.$ac_ext <<_ACEOF
31213 #line $LINENO "configure"
31214 /* confdefs.h.  */
31215 _ACEOF
31216 cat confdefs.h >>conftest.$ac_ext
31217 cat >>conftest.$ac_ext <<_ACEOF
31218 /* end confdefs.h.  */
31219 #include "confdefs.h"
31220 #include <sys/types.h>
31221
31222
31223 int
31224 main ()
31225 {
31226 switch (0) case 0: case (sizeof (short) == $ac_size):;
31227   ;
31228   return 0;
31229 }
31230 _ACEOF
31231 rm -f conftest.$ac_objext
31232 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31233   (eval $ac_compile) 2>&5
31234   ac_status=$?
31235   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31236   (exit $ac_status); } &&
31237          { ac_try='test -s conftest.$ac_objext'
31238   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31239   (eval $ac_try) 2>&5
31240   ac_status=$?
31241   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31242   (exit $ac_status); }; }; then
31243   ac_cv_sizeof_short=$ac_size
31244 else
31245   echo "$as_me: failed program was:" >&5
31246 sed 's/^/| /' conftest.$ac_ext >&5
31247
31248 fi
31249 rm -f conftest.$ac_objext conftest.$ac_ext
31250   if test x$ac_cv_sizeof_short != x ; then break; fi
31251 done
31252
31253 fi
31254
31255 if test x$ac_cv_sizeof_short = x ; then
31256   { { echo "$as_me:$LINENO: error: cannot determine a size for short" >&5
31257 echo "$as_me: error: cannot determine a size for short" >&2;}
31258    { (exit 1); exit 1; }; }
31259 fi
31260 echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
31261 echo "${ECHO_T}$ac_cv_sizeof_short" >&6
31262
31263 cat >>confdefs.h <<_ACEOF
31264 #define SIZEOF_SHORT $ac_cv_sizeof_short
31265 _ACEOF
31266
31267
31268 echo "$as_me:$LINENO: checking size of int" >&5
31269 echo $ECHO_N "checking size of int... $ECHO_C" >&6
31270 if test "${ac_cv_sizeof_int+set}" = set; then
31271   echo $ECHO_N "(cached) $ECHO_C" >&6
31272 else
31273   for ac_size in 4 8 1 2 16  ; do # List sizes in rough order of prevalence.
31274   cat >conftest.$ac_ext <<_ACEOF
31275 #line $LINENO "configure"
31276 /* confdefs.h.  */
31277 _ACEOF
31278 cat confdefs.h >>conftest.$ac_ext
31279 cat >>conftest.$ac_ext <<_ACEOF
31280 /* end confdefs.h.  */
31281 #include "confdefs.h"
31282 #include <sys/types.h>
31283
31284
31285 int
31286 main ()
31287 {
31288 switch (0) case 0: case (sizeof (int) == $ac_size):;
31289   ;
31290   return 0;
31291 }
31292 _ACEOF
31293 rm -f conftest.$ac_objext
31294 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31295   (eval $ac_compile) 2>&5
31296   ac_status=$?
31297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31298   (exit $ac_status); } &&
31299          { ac_try='test -s conftest.$ac_objext'
31300   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31301   (eval $ac_try) 2>&5
31302   ac_status=$?
31303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31304   (exit $ac_status); }; }; then
31305   ac_cv_sizeof_int=$ac_size
31306 else
31307   echo "$as_me: failed program was:" >&5
31308 sed 's/^/| /' conftest.$ac_ext >&5
31309
31310 fi
31311 rm -f conftest.$ac_objext conftest.$ac_ext
31312   if test x$ac_cv_sizeof_int != x ; then break; fi
31313 done
31314
31315 fi
31316
31317 if test x$ac_cv_sizeof_int = x ; then
31318   { { echo "$as_me:$LINENO: error: cannot determine a size for int" >&5
31319 echo "$as_me: error: cannot determine a size for int" >&2;}
31320    { (exit 1); exit 1; }; }
31321 fi
31322 echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
31323 echo "${ECHO_T}$ac_cv_sizeof_int" >&6
31324
31325 cat >>confdefs.h <<_ACEOF
31326 #define SIZEOF_INT $ac_cv_sizeof_int
31327 _ACEOF
31328
31329
31330 echo "$as_me:$LINENO: checking size of long" >&5
31331 echo $ECHO_N "checking size of long... $ECHO_C" >&6
31332 if test "${ac_cv_sizeof_long+set}" = set; then
31333   echo $ECHO_N "(cached) $ECHO_C" >&6
31334 else
31335   for ac_size in 4 8 1 2 16  ; do # List sizes in rough order of prevalence.
31336   cat >conftest.$ac_ext <<_ACEOF
31337 #line $LINENO "configure"
31338 /* confdefs.h.  */
31339 _ACEOF
31340 cat confdefs.h >>conftest.$ac_ext
31341 cat >>conftest.$ac_ext <<_ACEOF
31342 /* end confdefs.h.  */
31343 #include "confdefs.h"
31344 #include <sys/types.h>
31345
31346
31347 int
31348 main ()
31349 {
31350 switch (0) case 0: case (sizeof (long) == $ac_size):;
31351   ;
31352   return 0;
31353 }
31354 _ACEOF
31355 rm -f conftest.$ac_objext
31356 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
31357   (eval $ac_compile) 2>&5
31358   ac_status=$?
31359   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31360   (exit $ac_status); } &&
31361          { ac_try='test -s conftest.$ac_objext'
31362   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31363   (eval $ac_try) 2>&5
31364   ac_status=$?
31365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31366   (exit $ac_status); }; }; then
31367   ac_cv_sizeof_long=$ac_size
31368 else
31369   echo "$as_me: failed program was:" >&5
31370 sed 's/^/| /' conftest.$ac_ext >&5
31371
31372 fi
31373 rm -f conftest.$ac_objext conftest.$ac_ext
31374   if test x$ac_cv_sizeof_long != x ; then break; fi
31375 done
31376
31377 fi
31378
31379 if test x$ac_cv_sizeof_long = x ; then
31380   { { echo "$as_me:$LINENO: error: cannot determine a size for long" >&5
31381 echo "$as_me: error: cannot determine a size for long" >&2;}
31382    { (exit 1); exit 1; }; }
31383 fi
31384 echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
31385 echo "${ECHO_T}$ac_cv_sizeof_long" >&6
31386
31387 cat >>confdefs.h <<_ACEOF
31388 #define SIZEOF_LONG $ac_cv_sizeof_long
31389 _ACEOF
31390
31391
31392
31393 if test "$ac_cv_sizeof_int" -lt 4 ; then
31394         { echo "$as_me:$LINENO: WARNING: OpenLDAP requires 'int' to be 32 bits or greater." >&5
31395 echo "$as_me: WARNING: OpenLDAP requires 'int' to be 32 bits or greater." >&2;}
31396
31397         cat >>confdefs.h <<\_ACEOF
31398 #define LBER_INT_T long
31399 _ACEOF
31400
31401 else
31402         cat >>confdefs.h <<\_ACEOF
31403 #define LBER_INT_T int
31404 _ACEOF
31405
31406 fi
31407
31408 cat >>confdefs.h <<\_ACEOF
31409 #define LBER_LEN_T long
31410 _ACEOF
31411
31412 cat >>confdefs.h <<\_ACEOF
31413 #define LBER_SOCKET_T int
31414 _ACEOF
31415
31416 cat >>confdefs.h <<\_ACEOF
31417 #define LBER_TAG_T long
31418 _ACEOF
31419
31420
31421 echo "$as_me:$LINENO: checking for working memcmp" >&5
31422 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
31423 if test "${ac_cv_func_memcmp_working+set}" = set; then
31424   echo $ECHO_N "(cached) $ECHO_C" >&6
31425 else
31426   if test "$cross_compiling" = yes; then
31427   ac_cv_func_memcmp_working=no
31428 else
31429   cat >conftest.$ac_ext <<_ACEOF
31430 #line $LINENO "configure"
31431 /* confdefs.h.  */
31432 _ACEOF
31433 cat confdefs.h >>conftest.$ac_ext
31434 cat >>conftest.$ac_ext <<_ACEOF
31435 /* end confdefs.h.  */
31436
31437 int
31438 main ()
31439 {
31440
31441   /* Some versions of memcmp are not 8-bit clean.  */
31442   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
31443   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
31444     exit (1);
31445
31446   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
31447      or more and with at least one buffer not starting on a 4-byte boundary.
31448      William Lewis provided this test program.   */
31449   {
31450     char foo[21];
31451     char bar[21];
31452     int i;
31453     for (i = 0; i < 4; i++)
31454       {
31455         char *a = foo + i;
31456         char *b = bar + i;
31457         strcpy (a, "--------01111111");
31458         strcpy (b, "--------10000000");
31459         if (memcmp (a, b, 16) >= 0)
31460           exit (1);
31461       }
31462     exit (0);
31463   }
31464
31465   ;
31466   return 0;
31467 }
31468 _ACEOF
31469 rm -f conftest$ac_exeext
31470 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31471   (eval $ac_link) 2>&5
31472   ac_status=$?
31473   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31474   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
31475   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31476   (eval $ac_try) 2>&5
31477   ac_status=$?
31478   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31479   (exit $ac_status); }; }; then
31480   ac_cv_func_memcmp_working=yes
31481 else
31482   echo "$as_me: program exited with status $ac_status" >&5
31483 echo "$as_me: failed program was:" >&5
31484 sed 's/^/| /' conftest.$ac_ext >&5
31485
31486 ( exit $ac_status )
31487 ac_cv_func_memcmp_working=no
31488 fi
31489 rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
31490 fi
31491 fi
31492 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
31493 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
31494 test $ac_cv_func_memcmp_working = no && LIBOBJS="$LIBOBJS memcmp.$ac_objext"
31495
31496
31497 for ac_func in strftime
31498 do
31499 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
31500 echo "$as_me:$LINENO: checking for $ac_func" >&5
31501 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
31502 if eval "test \"\${$as_ac_var+set}\" = set"; then
31503   echo $ECHO_N "(cached) $ECHO_C" >&6
31504 else
31505   cat >conftest.$ac_ext <<_ACEOF
31506 #line $LINENO "configure"
31507 /* confdefs.h.  */
31508 _ACEOF
31509 cat confdefs.h >>conftest.$ac_ext
31510 cat >>conftest.$ac_ext <<_ACEOF
31511 /* end confdefs.h.  */
31512 /* System header to define __stub macros and hopefully few prototypes,
31513     which can conflict with char $ac_func (); below.
31514     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31515     <limits.h> exists even on freestanding compilers.  */
31516 #ifdef __STDC__
31517 # include <limits.h>
31518 #else
31519 # include <assert.h>
31520 #endif
31521 /* Override any gcc2 internal prototype to avoid an error.  */
31522 #ifdef __cplusplus
31523 extern "C"
31524 {
31525 #endif
31526 /* We use char because int might match the return type of a gcc2
31527    builtin and then its argument prototype would still apply.  */
31528 char $ac_func ();
31529 /* The GNU C library defines this for functions which it implements
31530     to always fail with ENOSYS.  Some functions are actually named
31531     something starting with __ and the normal name is an alias.  */
31532 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
31533 choke me
31534 #else
31535 char (*f) () = $ac_func;
31536 #endif
31537 #ifdef __cplusplus
31538 }
31539 #endif
31540
31541 int
31542 main ()
31543 {
31544 return f != $ac_func;
31545   ;
31546   return 0;
31547 }
31548 _ACEOF
31549 rm -f conftest.$ac_objext conftest$ac_exeext
31550 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31551   (eval $ac_link) 2>&5
31552   ac_status=$?
31553   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31554   (exit $ac_status); } &&
31555          { ac_try='test -s conftest$ac_exeext'
31556   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31557   (eval $ac_try) 2>&5
31558   ac_status=$?
31559   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31560   (exit $ac_status); }; }; then
31561   eval "$as_ac_var=yes"
31562 else
31563   echo "$as_me: failed program was:" >&5
31564 sed 's/^/| /' conftest.$ac_ext >&5
31565
31566 eval "$as_ac_var=no"
31567 fi
31568 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
31569 fi
31570 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
31571 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
31572 if test `eval echo '${'$as_ac_var'}'` = yes; then
31573   cat >>confdefs.h <<_ACEOF
31574 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
31575 _ACEOF
31576
31577 else
31578   # strftime is in -lintl on SCO UNIX.
31579 echo "$as_me:$LINENO: checking for strftime in -lintl" >&5
31580 echo $ECHO_N "checking for strftime in -lintl... $ECHO_C" >&6
31581 if test "${ac_cv_lib_intl_strftime+set}" = set; then
31582   echo $ECHO_N "(cached) $ECHO_C" >&6
31583 else
31584   ac_check_lib_save_LIBS=$LIBS
31585 LIBS="-lintl  $LIBS"
31586 cat >conftest.$ac_ext <<_ACEOF
31587 #line $LINENO "configure"
31588 /* confdefs.h.  */
31589 _ACEOF
31590 cat confdefs.h >>conftest.$ac_ext
31591 cat >>conftest.$ac_ext <<_ACEOF
31592 /* end confdefs.h.  */
31593
31594 /* Override any gcc2 internal prototype to avoid an error.  */
31595 #ifdef __cplusplus
31596 extern "C"
31597 #endif
31598 /* We use char because int might match the return type of a gcc2
31599    builtin and then its argument prototype would still apply.  */
31600 char strftime ();
31601 int
31602 main ()
31603 {
31604 strftime ();
31605   ;
31606   return 0;
31607 }
31608 _ACEOF
31609 rm -f conftest.$ac_objext conftest$ac_exeext
31610 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31611   (eval $ac_link) 2>&5
31612   ac_status=$?
31613   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31614   (exit $ac_status); } &&
31615          { ac_try='test -s conftest$ac_exeext'
31616   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31617   (eval $ac_try) 2>&5
31618   ac_status=$?
31619   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31620   (exit $ac_status); }; }; then
31621   ac_cv_lib_intl_strftime=yes
31622 else
31623   echo "$as_me: failed program was:" >&5
31624 sed 's/^/| /' conftest.$ac_ext >&5
31625
31626 ac_cv_lib_intl_strftime=no
31627 fi
31628 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
31629 LIBS=$ac_check_lib_save_LIBS
31630 fi
31631 echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5
31632 echo "${ECHO_T}$ac_cv_lib_intl_strftime" >&6
31633 if test $ac_cv_lib_intl_strftime = yes; then
31634   cat >>confdefs.h <<\_ACEOF
31635 #define HAVE_STRFTIME 1
31636 _ACEOF
31637
31638 LIBS="-lintl $LIBS"
31639 fi
31640
31641 fi
31642 done
31643
31644
31645 echo "$as_me:$LINENO: checking for inet_aton()" >&5
31646 echo $ECHO_N "checking for inet_aton()... $ECHO_C" >&6
31647 if test "${ol_cv_func_inet_aton+set}" = set; then
31648   echo $ECHO_N "(cached) $ECHO_C" >&6
31649 else
31650   cat >conftest.$ac_ext <<_ACEOF
31651 #line $LINENO "configure"
31652 /* confdefs.h.  */
31653 _ACEOF
31654 cat confdefs.h >>conftest.$ac_ext
31655 cat >>conftest.$ac_ext <<_ACEOF
31656 /* end confdefs.h.  */
31657
31658 #ifdef HAVE_SYS_TYPES_H
31659 #       include <sys/types.h>
31660 #endif
31661 #ifdef HAVE_SYS_SOCKET_H
31662 #       include <sys/socket.h>
31663 #       ifdef HAVE_SYS_SELECT_H
31664 #               include <sys/select.h>
31665 #       endif
31666 #       include <netinet/in.h>
31667 #       ifdef HAVE_ARPA_INET_H
31668 #               include <arpa/inet.h>
31669 #       endif
31670 #endif
31671
31672 int
31673 main ()
31674 {
31675 struct in_addr in;
31676 int rc = inet_aton( "255.255.255.255", &in );
31677   ;
31678   return 0;
31679 }
31680 _ACEOF
31681 rm -f conftest.$ac_objext conftest$ac_exeext
31682 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31683   (eval $ac_link) 2>&5
31684   ac_status=$?
31685   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31686   (exit $ac_status); } &&
31687          { ac_try='test -s conftest$ac_exeext'
31688   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31689   (eval $ac_try) 2>&5
31690   ac_status=$?
31691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31692   (exit $ac_status); }; }; then
31693   ol_cv_func_inet_aton=yes
31694 else
31695   echo "$as_me: failed program was:" >&5
31696 sed 's/^/| /' conftest.$ac_ext >&5
31697
31698 ol_cv_func_inet_aton=no
31699 fi
31700 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
31701 fi
31702 echo "$as_me:$LINENO: result: $ol_cv_func_inet_aton" >&5
31703 echo "${ECHO_T}$ol_cv_func_inet_aton" >&6
31704   if test $ol_cv_func_inet_aton != no; then
31705
31706 cat >>confdefs.h <<\_ACEOF
31707 #define HAVE_INET_ATON 1
31708 _ACEOF
31709
31710   fi
31711
31712
31713 echo "$as_me:$LINENO: checking for _spawnlp" >&5
31714 echo $ECHO_N "checking for _spawnlp... $ECHO_C" >&6
31715 if test "${ac_cv_func__spawnlp+set}" = set; then
31716   echo $ECHO_N "(cached) $ECHO_C" >&6
31717 else
31718   cat >conftest.$ac_ext <<_ACEOF
31719 #line $LINENO "configure"
31720 /* confdefs.h.  */
31721 _ACEOF
31722 cat confdefs.h >>conftest.$ac_ext
31723 cat >>conftest.$ac_ext <<_ACEOF
31724 /* end confdefs.h.  */
31725 /* System header to define __stub macros and hopefully few prototypes,
31726     which can conflict with char _spawnlp (); below.
31727     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31728     <limits.h> exists even on freestanding compilers.  */
31729 #ifdef __STDC__
31730 # include <limits.h>
31731 #else
31732 # include <assert.h>
31733 #endif
31734 /* Override any gcc2 internal prototype to avoid an error.  */
31735 #ifdef __cplusplus
31736 extern "C"
31737 {
31738 #endif
31739 /* We use char because int might match the return type of a gcc2
31740    builtin and then its argument prototype would still apply.  */
31741 char _spawnlp ();
31742 /* The GNU C library defines this for functions which it implements
31743     to always fail with ENOSYS.  Some functions are actually named
31744     something starting with __ and the normal name is an alias.  */
31745 #if defined (__stub__spawnlp) || defined (__stub____spawnlp)
31746 choke me
31747 #else
31748 char (*f) () = _spawnlp;
31749 #endif
31750 #ifdef __cplusplus
31751 }
31752 #endif
31753
31754 int
31755 main ()
31756 {
31757 return f != _spawnlp;
31758   ;
31759   return 0;
31760 }
31761 _ACEOF
31762 rm -f conftest.$ac_objext conftest$ac_exeext
31763 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31764   (eval $ac_link) 2>&5
31765   ac_status=$?
31766   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31767   (exit $ac_status); } &&
31768          { ac_try='test -s conftest$ac_exeext'
31769   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31770   (eval $ac_try) 2>&5
31771   ac_status=$?
31772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31773   (exit $ac_status); }; }; then
31774   ac_cv_func__spawnlp=yes
31775 else
31776   echo "$as_me: failed program was:" >&5
31777 sed 's/^/| /' conftest.$ac_ext >&5
31778
31779 ac_cv_func__spawnlp=no
31780 fi
31781 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
31782 fi
31783 echo "$as_me:$LINENO: result: $ac_cv_func__spawnlp" >&5
31784 echo "${ECHO_T}$ac_cv_func__spawnlp" >&6
31785 if test $ac_cv_func__spawnlp = yes; then
31786
31787 cat >>confdefs.h <<\_ACEOF
31788 #define HAVE_SPAWNLP 1
31789 _ACEOF
31790
31791 fi
31792
31793
31794 echo "$as_me:$LINENO: checking for _snprintf" >&5
31795 echo $ECHO_N "checking for _snprintf... $ECHO_C" >&6
31796 if test "${ac_cv_func__snprintf+set}" = set; then
31797   echo $ECHO_N "(cached) $ECHO_C" >&6
31798 else
31799   cat >conftest.$ac_ext <<_ACEOF
31800 #line $LINENO "configure"
31801 /* confdefs.h.  */
31802 _ACEOF
31803 cat confdefs.h >>conftest.$ac_ext
31804 cat >>conftest.$ac_ext <<_ACEOF
31805 /* end confdefs.h.  */
31806 /* System header to define __stub macros and hopefully few prototypes,
31807     which can conflict with char _snprintf (); below.
31808     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31809     <limits.h> exists even on freestanding compilers.  */
31810 #ifdef __STDC__
31811 # include <limits.h>
31812 #else
31813 # include <assert.h>
31814 #endif
31815 /* Override any gcc2 internal prototype to avoid an error.  */
31816 #ifdef __cplusplus
31817 extern "C"
31818 {
31819 #endif
31820 /* We use char because int might match the return type of a gcc2
31821    builtin and then its argument prototype would still apply.  */
31822 char _snprintf ();
31823 /* The GNU C library defines this for functions which it implements
31824     to always fail with ENOSYS.  Some functions are actually named
31825     something starting with __ and the normal name is an alias.  */
31826 #if defined (__stub__snprintf) || defined (__stub____snprintf)
31827 choke me
31828 #else
31829 char (*f) () = _snprintf;
31830 #endif
31831 #ifdef __cplusplus
31832 }
31833 #endif
31834
31835 int
31836 main ()
31837 {
31838 return f != _snprintf;
31839   ;
31840   return 0;
31841 }
31842 _ACEOF
31843 rm -f conftest.$ac_objext conftest$ac_exeext
31844 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31845   (eval $ac_link) 2>&5
31846   ac_status=$?
31847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31848   (exit $ac_status); } &&
31849          { ac_try='test -s conftest$ac_exeext'
31850   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31851   (eval $ac_try) 2>&5
31852   ac_status=$?
31853   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31854   (exit $ac_status); }; }; then
31855   ac_cv_func__snprintf=yes
31856 else
31857   echo "$as_me: failed program was:" >&5
31858 sed 's/^/| /' conftest.$ac_ext >&5
31859
31860 ac_cv_func__snprintf=no
31861 fi
31862 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
31863 fi
31864 echo "$as_me:$LINENO: result: $ac_cv_func__snprintf" >&5
31865 echo "${ECHO_T}$ac_cv_func__snprintf" >&6
31866 if test $ac_cv_func__snprintf = yes; then
31867   ac_cv_func_snprintf=yes
31868
31869 cat >>confdefs.h <<\_ACEOF
31870 #define snprintf _snprintf
31871 _ACEOF
31872
31873
31874 fi
31875
31876
31877 echo "$as_me:$LINENO: checking for _vsnprintf" >&5
31878 echo $ECHO_N "checking for _vsnprintf... $ECHO_C" >&6
31879 if test "${ac_cv_func__vsnprintf+set}" = set; then
31880   echo $ECHO_N "(cached) $ECHO_C" >&6
31881 else
31882   cat >conftest.$ac_ext <<_ACEOF
31883 #line $LINENO "configure"
31884 /* confdefs.h.  */
31885 _ACEOF
31886 cat confdefs.h >>conftest.$ac_ext
31887 cat >>conftest.$ac_ext <<_ACEOF
31888 /* end confdefs.h.  */
31889 /* System header to define __stub macros and hopefully few prototypes,
31890     which can conflict with char _vsnprintf (); below.
31891     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31892     <limits.h> exists even on freestanding compilers.  */
31893 #ifdef __STDC__
31894 # include <limits.h>
31895 #else
31896 # include <assert.h>
31897 #endif
31898 /* Override any gcc2 internal prototype to avoid an error.  */
31899 #ifdef __cplusplus
31900 extern "C"
31901 {
31902 #endif
31903 /* We use char because int might match the return type of a gcc2
31904    builtin and then its argument prototype would still apply.  */
31905 char _vsnprintf ();
31906 /* The GNU C library defines this for functions which it implements
31907     to always fail with ENOSYS.  Some functions are actually named
31908     something starting with __ and the normal name is an alias.  */
31909 #if defined (__stub__vsnprintf) || defined (__stub____vsnprintf)
31910 choke me
31911 #else
31912 char (*f) () = _vsnprintf;
31913 #endif
31914 #ifdef __cplusplus
31915 }
31916 #endif
31917
31918 int
31919 main ()
31920 {
31921 return f != _vsnprintf;
31922   ;
31923   return 0;
31924 }
31925 _ACEOF
31926 rm -f conftest.$ac_objext conftest$ac_exeext
31927 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
31928   (eval $ac_link) 2>&5
31929   ac_status=$?
31930   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31931   (exit $ac_status); } &&
31932          { ac_try='test -s conftest$ac_exeext'
31933   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
31934   (eval $ac_try) 2>&5
31935   ac_status=$?
31936   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31937   (exit $ac_status); }; }; then
31938   ac_cv_func__vsnprintf=yes
31939 else
31940   echo "$as_me: failed program was:" >&5
31941 sed 's/^/| /' conftest.$ac_ext >&5
31942
31943 ac_cv_func__vsnprintf=no
31944 fi
31945 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
31946 fi
31947 echo "$as_me:$LINENO: result: $ac_cv_func__vsnprintf" >&5
31948 echo "${ECHO_T}$ac_cv_func__vsnprintf" >&6
31949 if test $ac_cv_func__vsnprintf = yes; then
31950   ac_cv_func_vsnprintf=yes
31951
31952 cat >>confdefs.h <<\_ACEOF
31953 #define vsnprintf _vsnprintf
31954 _ACEOF
31955
31956
31957 fi
31958
31959
31960
31961 for ac_func in vprintf
31962 do
31963 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
31964 echo "$as_me:$LINENO: checking for $ac_func" >&5
31965 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
31966 if eval "test \"\${$as_ac_var+set}\" = set"; then
31967   echo $ECHO_N "(cached) $ECHO_C" >&6
31968 else
31969   cat >conftest.$ac_ext <<_ACEOF
31970 #line $LINENO "configure"
31971 /* confdefs.h.  */
31972 _ACEOF
31973 cat confdefs.h >>conftest.$ac_ext
31974 cat >>conftest.$ac_ext <<_ACEOF
31975 /* end confdefs.h.  */
31976 /* System header to define __stub macros and hopefully few prototypes,
31977     which can conflict with char $ac_func (); below.
31978     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31979     <limits.h> exists even on freestanding compilers.  */
31980 #ifdef __STDC__
31981 # include <limits.h>
31982 #else
31983 # include <assert.h>
31984 #endif
31985 /* Override any gcc2 internal prototype to avoid an error.  */
31986 #ifdef __cplusplus
31987 extern "C"
31988 {
31989 #endif
31990 /* We use char because int might match the return type of a gcc2
31991    builtin and then its argument prototype would still apply.  */
31992 char $ac_func ();
31993 /* The GNU C library defines this for functions which it implements
31994     to always fail with ENOSYS.  Some functions are actually named
31995     something starting with __ and the normal name is an alias.  */
31996 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
31997 choke me
31998 #else
31999 char (*f) () = $ac_func;
32000 #endif
32001 #ifdef __cplusplus
32002 }
32003 #endif
32004
32005 int
32006 main ()
32007 {
32008 return f != $ac_func;
32009   ;
32010   return 0;
32011 }
32012 _ACEOF
32013 rm -f conftest.$ac_objext conftest$ac_exeext
32014 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32015   (eval $ac_link) 2>&5
32016   ac_status=$?
32017   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32018   (exit $ac_status); } &&
32019          { ac_try='test -s conftest$ac_exeext'
32020   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32021   (eval $ac_try) 2>&5
32022   ac_status=$?
32023   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32024   (exit $ac_status); }; }; then
32025   eval "$as_ac_var=yes"
32026 else
32027   echo "$as_me: failed program was:" >&5
32028 sed 's/^/| /' conftest.$ac_ext >&5
32029
32030 eval "$as_ac_var=no"
32031 fi
32032 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
32033 fi
32034 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
32035 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
32036 if test `eval echo '${'$as_ac_var'}'` = yes; then
32037   cat >>confdefs.h <<_ACEOF
32038 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
32039 _ACEOF
32040
32041 echo "$as_me:$LINENO: checking for _doprnt" >&5
32042 echo $ECHO_N "checking for _doprnt... $ECHO_C" >&6
32043 if test "${ac_cv_func__doprnt+set}" = set; then
32044   echo $ECHO_N "(cached) $ECHO_C" >&6
32045 else
32046   cat >conftest.$ac_ext <<_ACEOF
32047 #line $LINENO "configure"
32048 /* confdefs.h.  */
32049 _ACEOF
32050 cat confdefs.h >>conftest.$ac_ext
32051 cat >>conftest.$ac_ext <<_ACEOF
32052 /* end confdefs.h.  */
32053 /* System header to define __stub macros and hopefully few prototypes,
32054     which can conflict with char _doprnt (); below.
32055     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
32056     <limits.h> exists even on freestanding compilers.  */
32057 #ifdef __STDC__
32058 # include <limits.h>
32059 #else
32060 # include <assert.h>
32061 #endif
32062 /* Override any gcc2 internal prototype to avoid an error.  */
32063 #ifdef __cplusplus
32064 extern "C"
32065 {
32066 #endif
32067 /* We use char because int might match the return type of a gcc2
32068    builtin and then its argument prototype would still apply.  */
32069 char _doprnt ();
32070 /* The GNU C library defines this for functions which it implements
32071     to always fail with ENOSYS.  Some functions are actually named
32072     something starting with __ and the normal name is an alias.  */
32073 #if defined (__stub__doprnt) || defined (__stub____doprnt)
32074 choke me
32075 #else
32076 char (*f) () = _doprnt;
32077 #endif
32078 #ifdef __cplusplus
32079 }
32080 #endif
32081
32082 int
32083 main ()
32084 {
32085 return f != _doprnt;
32086   ;
32087   return 0;
32088 }
32089 _ACEOF
32090 rm -f conftest.$ac_objext conftest$ac_exeext
32091 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32092   (eval $ac_link) 2>&5
32093   ac_status=$?
32094   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32095   (exit $ac_status); } &&
32096          { ac_try='test -s conftest$ac_exeext'
32097   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32098   (eval $ac_try) 2>&5
32099   ac_status=$?
32100   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32101   (exit $ac_status); }; }; then
32102   ac_cv_func__doprnt=yes
32103 else
32104   echo "$as_me: failed program was:" >&5
32105 sed 's/^/| /' conftest.$ac_ext >&5
32106
32107 ac_cv_func__doprnt=no
32108 fi
32109 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
32110 fi
32111 echo "$as_me:$LINENO: result: $ac_cv_func__doprnt" >&5
32112 echo "${ECHO_T}$ac_cv_func__doprnt" >&6
32113 if test $ac_cv_func__doprnt = yes; then
32114
32115 cat >>confdefs.h <<\_ACEOF
32116 #define HAVE_DOPRNT 1
32117 _ACEOF
32118
32119 fi
32120
32121 fi
32122 done
32123
32124
32125
32126 if test $ac_cv_func_vprintf = yes ; then
32127
32128
32129 for ac_func in snprintf vsnprintf
32130 do
32131 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
32132 echo "$as_me:$LINENO: checking for $ac_func" >&5
32133 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
32134 if eval "test \"\${$as_ac_var+set}\" = set"; then
32135   echo $ECHO_N "(cached) $ECHO_C" >&6
32136 else
32137   cat >conftest.$ac_ext <<_ACEOF
32138 #line $LINENO "configure"
32139 /* confdefs.h.  */
32140 _ACEOF
32141 cat confdefs.h >>conftest.$ac_ext
32142 cat >>conftest.$ac_ext <<_ACEOF
32143 /* end confdefs.h.  */
32144 /* System header to define __stub macros and hopefully few prototypes,
32145     which can conflict with char $ac_func (); below.
32146     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
32147     <limits.h> exists even on freestanding compilers.  */
32148 #ifdef __STDC__
32149 # include <limits.h>
32150 #else
32151 # include <assert.h>
32152 #endif
32153 /* Override any gcc2 internal prototype to avoid an error.  */
32154 #ifdef __cplusplus
32155 extern "C"
32156 {
32157 #endif
32158 /* We use char because int might match the return type of a gcc2
32159    builtin and then its argument prototype would still apply.  */
32160 char $ac_func ();
32161 /* The GNU C library defines this for functions which it implements
32162     to always fail with ENOSYS.  Some functions are actually named
32163     something starting with __ and the normal name is an alias.  */
32164 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
32165 choke me
32166 #else
32167 char (*f) () = $ac_func;
32168 #endif
32169 #ifdef __cplusplus
32170 }
32171 #endif
32172
32173 int
32174 main ()
32175 {
32176 return f != $ac_func;
32177   ;
32178   return 0;
32179 }
32180 _ACEOF
32181 rm -f conftest.$ac_objext conftest$ac_exeext
32182 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32183   (eval $ac_link) 2>&5
32184   ac_status=$?
32185   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32186   (exit $ac_status); } &&
32187          { ac_try='test -s conftest$ac_exeext'
32188   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32189   (eval $ac_try) 2>&5
32190   ac_status=$?
32191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32192   (exit $ac_status); }; }; then
32193   eval "$as_ac_var=yes"
32194 else
32195   echo "$as_me: failed program was:" >&5
32196 sed 's/^/| /' conftest.$ac_ext >&5
32197
32198 eval "$as_ac_var=no"
32199 fi
32200 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
32201 fi
32202 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
32203 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
32204 if test `eval echo '${'$as_ac_var'}'` = yes; then
32205   cat >>confdefs.h <<_ACEOF
32206 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
32207 _ACEOF
32208
32209 fi
32210 done
32211
32212 fi
32213
32214
32215
32216
32217
32218
32219
32220
32221
32222
32223
32224
32225
32226
32227
32228
32229
32230
32231
32232
32233
32234
32235
32236
32237
32238
32239
32240
32241
32242
32243
32244
32245
32246
32247
32248
32249
32250
32251
32252
32253
32254
32255
32256
32257
32258
32259
32260
32261
32262
32263
32264
32265
32266
32267 for ac_func in \
32268         bcopy                   \
32269         closesocket             \
32270         chroot                  \
32271         endgrent                \
32272         endpwent                \
32273         fcntl                   \
32274         flock                   \
32275         fstat                   \
32276         getdtablesize   \
32277         getgrgid                \
32278         gethostname             \
32279         getpass                 \
32280         getpassphrase   \
32281         getpwuid                \
32282         getpwnam                \
32283         getspnam                \
32284         gettimeofday    \
32285         initgroups              \
32286         lockf                   \
32287         memcpy                  \
32288         memmove                 \
32289         mkstemp                 \
32290         mktemp                  \
32291         pipe                    \
32292         read                    \
32293         recv                    \
32294         recvfrom                \
32295         setpwfile               \
32296         setgid                  \
32297         setegid                 \
32298         setsid                  \
32299         setuid                  \
32300         seteuid                 \
32301         sigaction               \
32302         signal                  \
32303         sigset                  \
32304         strdup                  \
32305         strerror                \
32306         strpbrk                 \
32307         strrchr                 \
32308         strsep                  \
32309         strstr                  \
32310         strtol                  \
32311         strtoul                 \
32312         strspn                  \
32313         sysconf                 \
32314         usleep                  \
32315         waitpid                 \
32316         wait4                   \
32317         write                   \
32318         send                    \
32319         sendmsg                 \
32320         sendto                  \
32321
32322 do
32323 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
32324 echo "$as_me:$LINENO: checking for $ac_func" >&5
32325 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
32326 if eval "test \"\${$as_ac_var+set}\" = set"; then
32327   echo $ECHO_N "(cached) $ECHO_C" >&6
32328 else
32329   cat >conftest.$ac_ext <<_ACEOF
32330 #line $LINENO "configure"
32331 /* confdefs.h.  */
32332 _ACEOF
32333 cat confdefs.h >>conftest.$ac_ext
32334 cat >>conftest.$ac_ext <<_ACEOF
32335 /* end confdefs.h.  */
32336 /* System header to define __stub macros and hopefully few prototypes,
32337     which can conflict with char $ac_func (); below.
32338     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
32339     <limits.h> exists even on freestanding compilers.  */
32340 #ifdef __STDC__
32341 # include <limits.h>
32342 #else
32343 # include <assert.h>
32344 #endif
32345 /* Override any gcc2 internal prototype to avoid an error.  */
32346 #ifdef __cplusplus
32347 extern "C"
32348 {
32349 #endif
32350 /* We use char because int might match the return type of a gcc2
32351    builtin and then its argument prototype would still apply.  */
32352 char $ac_func ();
32353 /* The GNU C library defines this for functions which it implements
32354     to always fail with ENOSYS.  Some functions are actually named
32355     something starting with __ and the normal name is an alias.  */
32356 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
32357 choke me
32358 #else
32359 char (*f) () = $ac_func;
32360 #endif
32361 #ifdef __cplusplus
32362 }
32363 #endif
32364
32365 int
32366 main ()
32367 {
32368 return f != $ac_func;
32369   ;
32370   return 0;
32371 }
32372 _ACEOF
32373 rm -f conftest.$ac_objext conftest$ac_exeext
32374 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32375   (eval $ac_link) 2>&5
32376   ac_status=$?
32377   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32378   (exit $ac_status); } &&
32379          { ac_try='test -s conftest$ac_exeext'
32380   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32381   (eval $ac_try) 2>&5
32382   ac_status=$?
32383   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32384   (exit $ac_status); }; }; then
32385   eval "$as_ac_var=yes"
32386 else
32387   echo "$as_me: failed program was:" >&5
32388 sed 's/^/| /' conftest.$ac_ext >&5
32389
32390 eval "$as_ac_var=no"
32391 fi
32392 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
32393 fi
32394 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
32395 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
32396 if test `eval echo '${'$as_ac_var'}'` = yes; then
32397   cat >>confdefs.h <<_ACEOF
32398 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
32399 _ACEOF
32400
32401 fi
32402 done
32403
32404
32405
32406
32407 for ac_func in getopt getpeereid
32408 do
32409 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
32410 echo "$as_me:$LINENO: checking for $ac_func" >&5
32411 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
32412 if eval "test \"\${$as_ac_var+set}\" = set"; then
32413   echo $ECHO_N "(cached) $ECHO_C" >&6
32414 else
32415   cat >conftest.$ac_ext <<_ACEOF
32416 #line $LINENO "configure"
32417 /* confdefs.h.  */
32418 _ACEOF
32419 cat confdefs.h >>conftest.$ac_ext
32420 cat >>conftest.$ac_ext <<_ACEOF
32421 /* end confdefs.h.  */
32422 /* System header to define __stub macros and hopefully few prototypes,
32423     which can conflict with char $ac_func (); below.
32424     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
32425     <limits.h> exists even on freestanding compilers.  */
32426 #ifdef __STDC__
32427 # include <limits.h>
32428 #else
32429 # include <assert.h>
32430 #endif
32431 /* Override any gcc2 internal prototype to avoid an error.  */
32432 #ifdef __cplusplus
32433 extern "C"
32434 {
32435 #endif
32436 /* We use char because int might match the return type of a gcc2
32437    builtin and then its argument prototype would still apply.  */
32438 char $ac_func ();
32439 /* The GNU C library defines this for functions which it implements
32440     to always fail with ENOSYS.  Some functions are actually named
32441     something starting with __ and the normal name is an alias.  */
32442 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
32443 choke me
32444 #else
32445 char (*f) () = $ac_func;
32446 #endif
32447 #ifdef __cplusplus
32448 }
32449 #endif
32450
32451 int
32452 main ()
32453 {
32454 return f != $ac_func;
32455   ;
32456   return 0;
32457 }
32458 _ACEOF
32459 rm -f conftest.$ac_objext conftest$ac_exeext
32460 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32461   (eval $ac_link) 2>&5
32462   ac_status=$?
32463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32464   (exit $ac_status); } &&
32465          { ac_try='test -s conftest$ac_exeext'
32466   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32467   (eval $ac_try) 2>&5
32468   ac_status=$?
32469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32470   (exit $ac_status); }; }; then
32471   eval "$as_ac_var=yes"
32472 else
32473   echo "$as_me: failed program was:" >&5
32474 sed 's/^/| /' conftest.$ac_ext >&5
32475
32476 eval "$as_ac_var=no"
32477 fi
32478 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
32479 fi
32480 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
32481 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
32482 if test `eval echo '${'$as_ac_var'}'` = yes; then
32483   cat >>confdefs.h <<_ACEOF
32484 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
32485 _ACEOF
32486
32487 else
32488   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
32489 fi
32490 done
32491
32492
32493
32494 if test "$ac_cv_func_getopt" != yes; then
32495         LIBSRCS="$LIBSRCS getopt.c"
32496 fi
32497 if test "$ac_cv_func_getpeereid" != yes; then
32498         echo "$as_me:$LINENO: checking for struct msghdr.msg_accrights" >&5
32499 echo $ECHO_N "checking for struct msghdr.msg_accrights... $ECHO_C" >&6
32500 if test "${ac_cv_member_struct_msghdr_msg_accrights+set}" = set; then
32501   echo $ECHO_N "(cached) $ECHO_C" >&6
32502 else
32503   cat >conftest.$ac_ext <<_ACEOF
32504 #line $LINENO "configure"
32505 /* confdefs.h.  */
32506 _ACEOF
32507 cat confdefs.h >>conftest.$ac_ext
32508 cat >>conftest.$ac_ext <<_ACEOF
32509 /* end confdefs.h.  */
32510 #include <sys/socket.h>
32511
32512 int
32513 main ()
32514 {
32515 static struct msghdr ac_aggr;
32516 if (ac_aggr.msg_accrights)
32517 return 0;
32518   ;
32519   return 0;
32520 }
32521 _ACEOF
32522 rm -f conftest.$ac_objext
32523 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32524   (eval $ac_compile) 2>&5
32525   ac_status=$?
32526   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32527   (exit $ac_status); } &&
32528          { ac_try='test -s conftest.$ac_objext'
32529   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32530   (eval $ac_try) 2>&5
32531   ac_status=$?
32532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32533   (exit $ac_status); }; }; then
32534   ac_cv_member_struct_msghdr_msg_accrights=yes
32535 else
32536   echo "$as_me: failed program was:" >&5
32537 sed 's/^/| /' conftest.$ac_ext >&5
32538
32539 cat >conftest.$ac_ext <<_ACEOF
32540 #line $LINENO "configure"
32541 /* confdefs.h.  */
32542 _ACEOF
32543 cat confdefs.h >>conftest.$ac_ext
32544 cat >>conftest.$ac_ext <<_ACEOF
32545 /* end confdefs.h.  */
32546 #include <sys/socket.h>
32547
32548 int
32549 main ()
32550 {
32551 static struct msghdr ac_aggr;
32552 if (sizeof ac_aggr.msg_accrights)
32553 return 0;
32554   ;
32555   return 0;
32556 }
32557 _ACEOF
32558 rm -f conftest.$ac_objext
32559 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32560   (eval $ac_compile) 2>&5
32561   ac_status=$?
32562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32563   (exit $ac_status); } &&
32564          { ac_try='test -s conftest.$ac_objext'
32565   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32566   (eval $ac_try) 2>&5
32567   ac_status=$?
32568   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32569   (exit $ac_status); }; }; then
32570   ac_cv_member_struct_msghdr_msg_accrights=yes
32571 else
32572   echo "$as_me: failed program was:" >&5
32573 sed 's/^/| /' conftest.$ac_ext >&5
32574
32575 ac_cv_member_struct_msghdr_msg_accrights=no
32576 fi
32577 rm -f conftest.$ac_objext conftest.$ac_ext
32578 fi
32579 rm -f conftest.$ac_objext conftest.$ac_ext
32580 fi
32581 echo "$as_me:$LINENO: result: $ac_cv_member_struct_msghdr_msg_accrights" >&5
32582 echo "${ECHO_T}$ac_cv_member_struct_msghdr_msg_accrights" >&6
32583
32584    if test $ac_cv_member_struct_msghdr_msg_accrights = "yes" ; then
32585
32586 cat >>confdefs.h <<\_ACEOF
32587 #define HAVE_MSGHDR_MSG_ACCRIGHTS 1
32588 _ACEOF
32589
32590    fi
32591
32592         LIBSRCS="$LIBSRCS getpeereid.c"
32593 fi
32594 if test "$ac_cv_func_snprintf" != yes -o "$ac_cv_func_vsnprintf" != yes; then
32595         if test "$ac_cv_func_snprintf" != yes; then
32596
32597 cat >>confdefs.h <<\_ACEOF
32598 #define snprintf ber_pvt_snprintf
32599 _ACEOF
32600
32601         fi
32602         if test "$ac_cv_func_vsnprintf" != yes; then
32603
32604 cat >>confdefs.h <<\_ACEOF
32605 #define vsnprintf ber_pvt_vsnprintf
32606 _ACEOF
32607
32608         fi
32609 fi
32610
32611 # Check Configuration
32612 echo "$as_me:$LINENO: checking declaration of sys_errlist" >&5
32613 echo $ECHO_N "checking declaration of sys_errlist... $ECHO_C" >&6
32614 if test "${ol_cv_dcl_sys_errlist+set}" = set; then
32615   echo $ECHO_N "(cached) $ECHO_C" >&6
32616 else
32617
32618         cat >conftest.$ac_ext <<_ACEOF
32619 #line $LINENO "configure"
32620 /* confdefs.h.  */
32621 _ACEOF
32622 cat confdefs.h >>conftest.$ac_ext
32623 cat >>conftest.$ac_ext <<_ACEOF
32624 /* end confdefs.h.  */
32625
32626 #include <stdio.h>
32627 #include <sys/types.h>
32628 #include <errno.h>
32629 #ifdef WINNT
32630 #include <stdlib.h>
32631 #endif
32632 int
32633 main ()
32634 {
32635 char *c = (char *) *sys_errlist
32636   ;
32637   return 0;
32638 }
32639 _ACEOF
32640 rm -f conftest.$ac_objext
32641 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32642   (eval $ac_compile) 2>&5
32643   ac_status=$?
32644   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32645   (exit $ac_status); } &&
32646          { ac_try='test -s conftest.$ac_objext'
32647   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32648   (eval $ac_try) 2>&5
32649   ac_status=$?
32650   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32651   (exit $ac_status); }; }; then
32652   ol_cv_dcl_sys_errlist=yes
32653         ol_cv_have_sys_errlist=yes
32654 else
32655   echo "$as_me: failed program was:" >&5
32656 sed 's/^/| /' conftest.$ac_ext >&5
32657
32658 ol_cv_dcl_sys_errlist=no
32659 fi
32660 rm -f conftest.$ac_objext conftest.$ac_ext
32661 fi
32662 echo "$as_me:$LINENO: result: $ol_cv_dcl_sys_errlist" >&5
32663 echo "${ECHO_T}$ol_cv_dcl_sys_errlist" >&6
32664 #
32665 # It's possible (for near-UNIX clones) that sys_errlist doesn't exist
32666 if test $ol_cv_dcl_sys_errlist = no ; then
32667
32668 cat >>confdefs.h <<\_ACEOF
32669 #define DECL_SYS_ERRLIST 1
32670 _ACEOF
32671
32672
32673         echo "$as_me:$LINENO: checking existence of sys_errlist" >&5
32674 echo $ECHO_N "checking existence of sys_errlist... $ECHO_C" >&6
32675 if test "${ol_cv_have_sys_errlist+set}" = set; then
32676   echo $ECHO_N "(cached) $ECHO_C" >&6
32677 else
32678
32679                 cat >conftest.$ac_ext <<_ACEOF
32680 #line $LINENO "configure"
32681 /* confdefs.h.  */
32682 _ACEOF
32683 cat confdefs.h >>conftest.$ac_ext
32684 cat >>conftest.$ac_ext <<_ACEOF
32685 /* end confdefs.h.  */
32686 #include <errno.h>
32687 int
32688 main ()
32689 {
32690 char *c = (char *) *sys_errlist
32691   ;
32692   return 0;
32693 }
32694 _ACEOF
32695 rm -f conftest.$ac_objext conftest$ac_exeext
32696 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32697   (eval $ac_link) 2>&5
32698   ac_status=$?
32699   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32700   (exit $ac_status); } &&
32701          { ac_try='test -s conftest$ac_exeext'
32702   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32703   (eval $ac_try) 2>&5
32704   ac_status=$?
32705   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32706   (exit $ac_status); }; }; then
32707   ol_cv_have_sys_errlist=yes
32708 else
32709   echo "$as_me: failed program was:" >&5
32710 sed 's/^/| /' conftest.$ac_ext >&5
32711
32712 ol_cv_have_sys_errlist=no
32713 fi
32714 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
32715 fi
32716 echo "$as_me:$LINENO: result: $ol_cv_have_sys_errlist" >&5
32717 echo "${ECHO_T}$ol_cv_have_sys_errlist" >&6
32718 fi
32719 if test $ol_cv_have_sys_errlist = yes ; then
32720
32721 cat >>confdefs.h <<\_ACEOF
32722 #define HAVE_SYS_ERRLIST 1
32723 _ACEOF
32724
32725 fi
32726
32727
32728
32729 if test "$ol_enable_slapi" != no ; then
32730
32731 for ac_header in ltdl.h
32732 do
32733 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
32734 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32735   echo "$as_me:$LINENO: checking for $ac_header" >&5
32736 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32737 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32738   echo $ECHO_N "(cached) $ECHO_C" >&6
32739 fi
32740 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32741 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32742 else
32743   # Is the header compilable?
32744 echo "$as_me:$LINENO: checking $ac_header usability" >&5
32745 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
32746 cat >conftest.$ac_ext <<_ACEOF
32747 #line $LINENO "configure"
32748 /* confdefs.h.  */
32749 _ACEOF
32750 cat confdefs.h >>conftest.$ac_ext
32751 cat >>conftest.$ac_ext <<_ACEOF
32752 /* end confdefs.h.  */
32753 $ac_includes_default
32754 #include <$ac_header>
32755 _ACEOF
32756 rm -f conftest.$ac_objext
32757 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
32758   (eval $ac_compile) 2>&5
32759   ac_status=$?
32760   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32761   (exit $ac_status); } &&
32762          { ac_try='test -s conftest.$ac_objext'
32763   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32764   (eval $ac_try) 2>&5
32765   ac_status=$?
32766   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32767   (exit $ac_status); }; }; then
32768   ac_header_compiler=yes
32769 else
32770   echo "$as_me: failed program was:" >&5
32771 sed 's/^/| /' conftest.$ac_ext >&5
32772
32773 ac_header_compiler=no
32774 fi
32775 rm -f conftest.$ac_objext conftest.$ac_ext
32776 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
32777 echo "${ECHO_T}$ac_header_compiler" >&6
32778
32779 # Is the header present?
32780 echo "$as_me:$LINENO: checking $ac_header presence" >&5
32781 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
32782 cat >conftest.$ac_ext <<_ACEOF
32783 #line $LINENO "configure"
32784 /* confdefs.h.  */
32785 _ACEOF
32786 cat confdefs.h >>conftest.$ac_ext
32787 cat >>conftest.$ac_ext <<_ACEOF
32788 /* end confdefs.h.  */
32789 #include <$ac_header>
32790 _ACEOF
32791 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
32792   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
32793   ac_status=$?
32794   grep -v '^ *+' conftest.er1 >conftest.err
32795   rm -f conftest.er1
32796   cat conftest.err >&5
32797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32798   (exit $ac_status); } >/dev/null; then
32799   if test -s conftest.err; then
32800     ac_cpp_err=$ac_c_preproc_warn_flag
32801   else
32802     ac_cpp_err=
32803   fi
32804 else
32805   ac_cpp_err=yes
32806 fi
32807 if test -z "$ac_cpp_err"; then
32808   ac_header_preproc=yes
32809 else
32810   echo "$as_me: failed program was:" >&5
32811 sed 's/^/| /' conftest.$ac_ext >&5
32812
32813   ac_header_preproc=no
32814 fi
32815 rm -f conftest.err conftest.$ac_ext
32816 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
32817 echo "${ECHO_T}$ac_header_preproc" >&6
32818
32819 # So?  What about this header?
32820 case $ac_header_compiler:$ac_header_preproc in
32821   yes:no )
32822     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
32823 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
32824     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
32825 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
32826     (
32827       cat <<\_ASBOX
32828 ## ------------------------------------ ##
32829 ## Report this to bug-autoconf@gnu.org. ##
32830 ## ------------------------------------ ##
32831 _ASBOX
32832     ) |
32833       sed "s/^/$as_me: WARNING:     /" >&2
32834     ;;
32835   no:yes )
32836     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
32837 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
32838     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
32839 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
32840     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
32841 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
32842     (
32843       cat <<\_ASBOX
32844 ## ------------------------------------ ##
32845 ## Report this to bug-autoconf@gnu.org. ##
32846 ## ------------------------------------ ##
32847 _ASBOX
32848     ) |
32849       sed "s/^/$as_me: WARNING:     /" >&2
32850     ;;
32851 esac
32852 echo "$as_me:$LINENO: checking for $ac_header" >&5
32853 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
32854 if eval "test \"\${$as_ac_Header+set}\" = set"; then
32855   echo $ECHO_N "(cached) $ECHO_C" >&6
32856 else
32857   eval "$as_ac_Header=$ac_header_preproc"
32858 fi
32859 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
32860 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
32861
32862 fi
32863 if test `eval echo '${'$as_ac_Header'}'` = yes; then
32864   cat >>confdefs.h <<_ACEOF
32865 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
32866 _ACEOF
32867
32868 fi
32869
32870 done
32871
32872
32873         if test $ac_cv_header_ltdl_h != yes ; then
32874                 { { echo "$as_me:$LINENO: error: could not locate <ltdl.h>" >&5
32875 echo "$as_me: error: could not locate <ltdl.h>" >&2;}
32876    { (exit 1); exit 1; }; }
32877         fi
32878         echo "$as_me:$LINENO: checking for lt_dlinit in -lltdl" >&5
32879 echo $ECHO_N "checking for lt_dlinit in -lltdl... $ECHO_C" >&6
32880 if test "${ac_cv_lib_ltdl_lt_dlinit+set}" = set; then
32881   echo $ECHO_N "(cached) $ECHO_C" >&6
32882 else
32883   ac_check_lib_save_LIBS=$LIBS
32884 LIBS="-lltdl  $LIBS"
32885 cat >conftest.$ac_ext <<_ACEOF
32886 #line $LINENO "configure"
32887 /* confdefs.h.  */
32888 _ACEOF
32889 cat confdefs.h >>conftest.$ac_ext
32890 cat >>conftest.$ac_ext <<_ACEOF
32891 /* end confdefs.h.  */
32892
32893 /* Override any gcc2 internal prototype to avoid an error.  */
32894 #ifdef __cplusplus
32895 extern "C"
32896 #endif
32897 /* We use char because int might match the return type of a gcc2
32898    builtin and then its argument prototype would still apply.  */
32899 char lt_dlinit ();
32900 int
32901 main ()
32902 {
32903 lt_dlinit ();
32904   ;
32905   return 0;
32906 }
32907 _ACEOF
32908 rm -f conftest.$ac_objext conftest$ac_exeext
32909 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
32910   (eval $ac_link) 2>&5
32911   ac_status=$?
32912   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32913   (exit $ac_status); } &&
32914          { ac_try='test -s conftest$ac_exeext'
32915   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
32916   (eval $ac_try) 2>&5
32917   ac_status=$?
32918   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32919   (exit $ac_status); }; }; then
32920   ac_cv_lib_ltdl_lt_dlinit=yes
32921 else
32922   echo "$as_me: failed program was:" >&5
32923 sed 's/^/| /' conftest.$ac_ext >&5
32924
32925 ac_cv_lib_ltdl_lt_dlinit=no
32926 fi
32927 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
32928 LIBS=$ac_check_lib_save_LIBS
32929 fi
32930 echo "$as_me:$LINENO: result: $ac_cv_lib_ltdl_lt_dlinit" >&5
32931 echo "${ECHO_T}$ac_cv_lib_ltdl_lt_dlinit" >&6
32932 if test $ac_cv_lib_ltdl_lt_dlinit = yes; then
32933
32934                 SLAPI_LIBS=-lltdl
32935                 LIBSLAPI=./libslapi.a
32936                 LIBSLAPITOOLS=../libslapi.a
32937
32938 cat >>confdefs.h <<\_ACEOF
32939 #define HAVE_LIBLTDL 1
32940 _ACEOF
32941
32942
32943 else
32944   { { echo "$as_me:$LINENO: error: could not locate libtool -lltdl" >&5
32945 echo "$as_me: error: could not locate libtool -lltdl" >&2;}
32946    { (exit 1); exit 1; }; }
32947 fi
32948
32949
32950
32951 cat >>confdefs.h <<\_ACEOF
32952 #define LDAP_SLAPI 1
32953 _ACEOF
32954
32955 fi
32956
32957 if test "$ol_enable_debug" != no ; then
32958
32959 cat >>confdefs.h <<\_ACEOF
32960 #define LDAP_DEBUG 1
32961 _ACEOF
32962
32963 fi
32964 if test "$ol_enable_syslog" = yes ; then
32965
32966 cat >>confdefs.h <<\_ACEOF
32967 #define LDAP_SYSLOG 1
32968 _ACEOF
32969
32970 fi
32971 if test "$ol_link_kbind" != no ; then
32972         cat >>confdefs.h <<\_ACEOF
32973 #define LDAP_API_FEATURE_X_OPENLDAP_V2_KBIND LDAP_VENDOR_VERSION
32974 _ACEOF
32975
32976 fi
32977 if test "$ol_enable_proctitle" != no ; then
32978
32979 cat >>confdefs.h <<\_ACEOF
32980 #define LDAP_PROCTITLE 1
32981 _ACEOF
32982
32983 fi
32984 if test "$ol_enable_referrals" != no ; then
32985         cat >>confdefs.h <<\_ACEOF
32986 #define LDAP_API_FEATURE_X_OPENLDAP_V2_REFERRALS LDAP_VENDOR_VERSION
32987 _ACEOF
32988
32989 fi
32990 if test "$ol_enable_local" != no; then
32991
32992 cat >>confdefs.h <<\_ACEOF
32993 #define LDAP_PF_LOCAL 1
32994 _ACEOF
32995
32996 fi
32997 if test "$ol_link_ipv6" != no; then
32998
32999 cat >>confdefs.h <<\_ACEOF
33000 #define LDAP_PF_INET6 1
33001 _ACEOF
33002
33003 fi
33004 if test "$ol_enable_cleartext" != no ; then
33005
33006 cat >>confdefs.h <<\_ACEOF
33007 #define SLAPD_CLEARTEXT 1
33008 _ACEOF
33009
33010 fi
33011 if test "$ol_enable_crypt" != no ; then
33012
33013 cat >>confdefs.h <<\_ACEOF
33014 #define SLAPD_CRYPT 1
33015 _ACEOF
33016
33017 fi
33018 if test "$ol_link_kpasswd" != no ; then
33019
33020 cat >>confdefs.h <<\_ACEOF
33021 #define SLAPD_KPASSWD 1
33022 _ACEOF
33023
33024 fi
33025 if test "$ol_link_spasswd" != no ; then
33026
33027 cat >>confdefs.h <<\_ACEOF
33028 #define SLAPD_SPASSWD 1
33029 _ACEOF
33030
33031 fi
33032 if test "$ol_enable_multimaster" != no ; then
33033
33034 cat >>confdefs.h <<\_ACEOF
33035 #define SLAPD_MULTIMASTER 1
33036 _ACEOF
33037
33038 fi
33039 if test "$ol_enable_phonetic" != no ; then
33040
33041 cat >>confdefs.h <<\_ACEOF
33042 #define SLAPD_PHONETIC 1
33043 _ACEOF
33044
33045 fi
33046 if test "$ol_enable_rlookups" != no ; then
33047
33048 cat >>confdefs.h <<\_ACEOF
33049 #define SLAPD_RLOOKUPS 1
33050 _ACEOF
33051
33052 fi
33053 if test "$ol_enable_aci" != no ; then
33054
33055 cat >>confdefs.h <<\_ACEOF
33056 #define SLAPD_ACI_ENABLED 1
33057 _ACEOF
33058
33059 fi
33060
33061 if test "$ol_link_modules" != no ; then
33062
33063 cat >>confdefs.h <<\_ACEOF
33064 #define SLAPD_MODULES 1
33065 _ACEOF
33066
33067         BUILD_SLAPD=yes
33068         SLAPD_MODULES_LDFLAGS="-dlopen self"
33069 fi
33070
33071 if test "$ol_enable_bdb" != no ; then
33072
33073 cat >>confdefs.h <<\_ACEOF
33074 #define SLAPD_BDB 1
33075 _ACEOF
33076
33077         BUILD_SLAPD=yes
33078         BUILD_BDB=yes
33079         if test "$ol_with_bdb_module" != static ; then
33080
33081 cat >>confdefs.h <<\_ACEOF
33082 #define SLAPD_BDB_DYNAMIC 1
33083 _ACEOF
33084
33085                 BUILD_BDB=mod
33086                 BUILD_BDB_DYNAMIC=shared
33087                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-bdb"
33088         else
33089                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-bdb"
33090         fi
33091 fi
33092
33093 if test "$ol_link_dnssrv" != no ; then
33094
33095 cat >>confdefs.h <<\_ACEOF
33096 #define SLAPD_DNSSRV 1
33097 _ACEOF
33098
33099         BUILD_SLAPD=yes
33100         BUILD_DNSSRV=yes
33101         if test "$ol_with_dnssrv_module" != static ; then
33102
33103 cat >>confdefs.h <<\_ACEOF
33104 #define SLAPD_DNSSRV_DYNAMIC 1
33105 _ACEOF
33106
33107                 BUILD_DNSSRV=mod
33108                 BUILD_DNSSRV_DYNAMIC=shared
33109                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-dnssrv"
33110         else
33111                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-dnssrv"
33112         fi
33113 fi
33114
33115 if test "$ol_enable_ldap" != no ; then
33116
33117 cat >>confdefs.h <<\_ACEOF
33118 #define SLAPD_LDAP 1
33119 _ACEOF
33120
33121         BUILD_SLAPD=yes
33122         BUILD_LDAP=yes
33123         if test "$ol_with_ldap_module" != static ; then
33124
33125 cat >>confdefs.h <<\_ACEOF
33126 #define SLAPD_LDAP_DYNAMIC 1
33127 _ACEOF
33128
33129                 BUILD_LDAP=mod
33130                 BUILD_LDAP_DYNAMIC=shared
33131                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-ldap"
33132         else
33133                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-ldap"
33134         fi
33135 fi
33136
33137 if test "$ol_link_ldbm" != no -a $ol_enable_ldbm != no; then
33138
33139 cat >>confdefs.h <<\_ACEOF
33140 #define SLAPD_LDBM 1
33141 _ACEOF
33142
33143         BUILD_SLAPD=yes
33144         BUILD_LDBM=yes
33145         if test "$ol_with_ldbm_module" != static ; then
33146
33147 cat >>confdefs.h <<\_ACEOF
33148 #define SLAPD_LDBM_DYNAMIC 1
33149 _ACEOF
33150
33151                 BUILD_LDBM=mod
33152                 BUILD_LDBM_DYNAMIC=shared
33153                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-ldbm"
33154         else
33155                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-ldbm"
33156         fi
33157 fi
33158
33159 if test "$ol_enable_meta" != no ; then
33160         if test "$ol_enable_ldap" = no ; then
33161                 { { echo "$as_me:$LINENO: error: need --enable-ldap to use --enable-meta" >&5
33162 echo "$as_me: error: need --enable-ldap to use --enable-meta" >&2;}
33163    { (exit 1); exit 1; }; }
33164         fi
33165         if test "$ol_enable_rewrite" = no ; then
33166                 { { echo "$as_me:$LINENO: error: need --enable-rewrite to use --enable-meta" >&5
33167 echo "$as_me: error: need --enable-rewrite to use --enable-meta" >&2;}
33168    { (exit 1); exit 1; }; }
33169         fi
33170
33171 cat >>confdefs.h <<\_ACEOF
33172 #define SLAPD_META 1
33173 _ACEOF
33174
33175         BUILD_SLAPD=yes
33176         BUILD_META=yes
33177         BUILD_LDAP=yes
33178         BUILD_REWRITE=yes
33179         if test "$ol_with_meta_module" != static ; then
33180
33181 cat >>confdefs.h <<\_ACEOF
33182 #define SLAPD_META_DYNAMIC 1
33183 _ACEOF
33184
33185                 BUILD_META=mod
33186                 BUILD_META_DYNAMIC=shared
33187                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-meta"
33188         else
33189                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-meta"
33190         fi
33191 fi
33192
33193 if test "$ol_enable_monitor" != no ; then
33194
33195 cat >>confdefs.h <<\_ACEOF
33196 #define SLAPD_MONITOR 1
33197 _ACEOF
33198
33199         BUILD_SLAPD=yes
33200         BUILD_MONITOR=yes
33201         if test "$ol_with_monitor_module" != static ; then
33202
33203 cat >>confdefs.h <<\_ACEOF
33204 #define SLAPD_MONITOR_DYNAMIC 1
33205 _ACEOF
33206
33207                 BUILD_MONITOR=mod
33208                 BUILD_MONITOR_DYNAMIC=shared
33209                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-monitor"
33210         else
33211                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-monitor"
33212         fi
33213 fi
33214
33215 if test "$ol_enable_null" != no ; then
33216
33217 cat >>confdefs.h <<\_ACEOF
33218 #define SLAPD_NULL 1
33219 _ACEOF
33220
33221         BUILD_SLAPD=yes
33222         BUILD_NULL=yes
33223         if test "$ol_with_null_module" != static ; then
33224
33225 cat >>confdefs.h <<\_ACEOF
33226 #define SLAPD_NULL_DYNAMIC 1
33227 _ACEOF
33228
33229                 BUILD_NULL=mod
33230                 BUILD_NULL_DYNAMIC=shared
33231                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-null"
33232         else
33233                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-null"
33234         fi
33235 fi
33236
33237 if test "$ol_enable_passwd" != no ; then
33238
33239 cat >>confdefs.h <<\_ACEOF
33240 #define SLAPD_PASSWD 1
33241 _ACEOF
33242
33243         BUILD_SLAPD=yes
33244         BUILD_PASSWD=yes
33245         if test "$ol_with_passwd_module" != static ; then
33246
33247 cat >>confdefs.h <<\_ACEOF
33248 #define SLAPD_PASSWD_DYNAMIC 1
33249 _ACEOF
33250
33251                 BUILD_PASSWD=mod
33252                 BUILD_PASSWD_DYNAMIC=shared
33253                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-passwd"
33254         else
33255                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-passwd"
33256         fi
33257 fi
33258
33259 if test "$ol_link_perl" != no ; then
33260
33261 cat >>confdefs.h <<\_ACEOF
33262 #define SLAPD_PERL 1
33263 _ACEOF
33264
33265         BUILD_SLAPD=yes
33266         BUILD_PERL=yes
33267         if test "$ol_with_perl_module" != static ; then
33268
33269 cat >>confdefs.h <<\_ACEOF
33270 #define SLAPD_PERL_DYNAMIC 1
33271 _ACEOF
33272
33273                 BUILD_PERL=mod
33274                 BUILD_PERL_DYNAMIC=shared
33275                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-perl"
33276         else
33277                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-perl"
33278         fi
33279 fi
33280
33281 if test "$ol_enable_shell" != no ; then
33282         if test "$ol_link_thread" != no ; then
33283                 { echo "$as_me:$LINENO: WARNING: Use of --without-threads is recommended with back-shell" >&5
33284 echo "$as_me: WARNING: Use of --without-threads is recommended with back-shell" >&2;}
33285         fi
33286
33287 cat >>confdefs.h <<\_ACEOF
33288 #define SLAPD_SHELL 1
33289 _ACEOF
33290
33291         BUILD_SLAPD=yes
33292         BUILD_SHELL=yes
33293         if test "$ol_with_shell_module" != static ; then
33294
33295 cat >>confdefs.h <<\_ACEOF
33296 #define SLAPD_SHELL_DYNAMIC 1
33297 _ACEOF
33298
33299                 BUILD_SHELL=mod
33300                 BUILD_SHELL_DYNAMIC=shared
33301                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-shell"
33302         else
33303                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-shell"
33304         fi
33305 fi
33306
33307 if test "$ol_enable_tcl" != no ; then
33308
33309 cat >>confdefs.h <<\_ACEOF
33310 #define SLAPD_TCL 1
33311 _ACEOF
33312
33313         BUILD_SLAPD=yes
33314         BUILD_TCL=yes
33315         if test "$ol_with_tcl_module" != static; then
33316
33317 cat >>confdefs.h <<\_ACEOF
33318 #define SLAPD_TCL_DYNAMIC 1
33319 _ACEOF
33320
33321                 BUILD_TCL=mod
33322                 BUILD_TCL_DYNAMIC=shared
33323                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-tcl"
33324         else
33325                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-tcl"
33326         fi
33327 fi
33328
33329 if test "$ol_link_sql" != no ; then
33330
33331 cat >>confdefs.h <<\_ACEOF
33332 #define SLAPD_SQL 1
33333 _ACEOF
33334
33335         BUILD_SLAPD=yes
33336         BUILD_SQL=yes
33337         if test "$ol_with_sql_module" != static; then
33338
33339 cat >>confdefs.h <<\_ACEOF
33340 #define SLAPD_SQL_DYNAMIC 1
33341 _ACEOF
33342
33343                 BUILD_SQL=mod
33344                 BUILD_SQL_DYNAMIC=shared
33345                 SLAPD_DYNAMIC_BACKENDS="$SLAPD_DYNAMIC_BACKENDS back-sql"
33346         else
33347                 SLAPD_STATIC_BACKENDS="$SLAPD_STATIC_BACKENDS back-sql"
33348         fi
33349 fi
33350
33351 if test "$ol_enable_slurpd" != no -a "$ol_link_threads" != no -a \
33352         $BUILD_SLAPD = yes ; then
33353         BUILD_SLURPD=yes
33354 fi
33355
33356 if test "$ol_enable_rewrite" != no ; then
33357
33358 cat >>confdefs.h <<\_ACEOF
33359 #define ENABLE_REWRITE 1
33360 _ACEOF
33361
33362         BUILD_REWRITE=yes
33363 fi
33364
33365 if test "$ol_enable_slapi" != no ; then
33366
33367 cat >>confdefs.h <<\_ACEOF
33368 #define ENABLE_SLAPI 1
33369 _ACEOF
33370
33371         BUILD_SLAPI=yes
33372         SLAPD_SLAPI_DEPEND=libslapi.a
33373 fi
33374
33375
33376
33377 if test "$ac_cv_mingw32" = yes ; then
33378         PLAT=NT
33379         SLAPD_MODULES_LDFLAGS=
33380 else
33381         PLAT=UNIX
33382 fi
33383
33384 if test -z "$SLAPD_STATIC_BACKENDS"; then
33385         SLAPD_NO_STATIC='#'
33386 else
33387         SLAPD_NO_STATIC=
33388 fi
33389
33390
33391
33392
33393
33394
33395
33396
33397
33398
33399
33400
33401
33402
33403
33404
33405
33406
33407
33408
33409
33410
33411
33412
33413
33414
33415
33416
33417
33418
33419
33420
33421
33422
33423
33424
33425
33426
33427
33428
33429
33430
33431
33432
33433
33434
33435
33436
33437
33438
33439
33440
33441
33442
33443
33444
33445
33446
33447
33448
33449
33450
33451
33452
33453
33454
33455
33456
33457
33458
33459
33460
33461
33462
33463 # Check whether --with-xxinstall or --without-xxinstall was given.
33464 if test "${with_xxinstall+set}" = set; then
33465   withval="$with_xxinstall"
33466
33467 fi;
33468
33469           ac_config_files="$ac_config_files Makefile:build/top.mk:Makefile.in:build/dir.mk"
33470
33471           ac_config_files="$ac_config_files doc/Makefile:build/top.mk:doc/Makefile.in:build/dir.mk"
33472
33473           ac_config_files="$ac_config_files doc/man/Makefile:build/top.mk:doc/man/Makefile.in:build/dir.mk"
33474
33475           ac_config_files="$ac_config_files doc/man/man1/Makefile:build/top.mk:doc/man/man1/Makefile.in:build/man.mk"
33476
33477           ac_config_files="$ac_config_files doc/man/man3/Makefile:build/top.mk:doc/man/man3/Makefile.in:build/man.mk"
33478
33479           ac_config_files="$ac_config_files doc/man/man5/Makefile:build/top.mk:doc/man/man5/Makefile.in:build/man.mk"
33480
33481           ac_config_files="$ac_config_files doc/man/man8/Makefile:build/top.mk:doc/man/man8/Makefile.in:build/man.mk"
33482
33483           ac_config_files="$ac_config_files clients/Makefile:build/top.mk:clients/Makefile.in:build/dir.mk"
33484
33485           ac_config_files="$ac_config_files clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk"
33486
33487           ac_config_files="$ac_config_files include/Makefile:build/top.mk:include/Makefile.in"
33488
33489           ac_config_files="$ac_config_files libraries/Makefile:build/top.mk:libraries/Makefile.in:build/dir.mk"
33490
33491           ac_config_files="$ac_config_files libraries/libavl/Makefile:build/top.mk:libraries/libavl/Makefile.in:build/lib.mk:build/lib-static.mk"
33492
33493           ac_config_files="$ac_config_files libraries/liblber/Makefile:build/top.mk:libraries/liblber/Makefile.in:build/lib.mk:build/lib-shared.mk"
33494
33495           ac_config_files="$ac_config_files libraries/libldap/Makefile:build/top.mk:libraries/libldap/Makefile.in:build/lib.mk:build/lib-shared.mk"
33496
33497           ac_config_files="$ac_config_files libraries/libldap_r/Makefile:build/top.mk:libraries/libldap_r/Makefile.in:build/lib.mk:build/lib-shared.mk"
33498
33499           ac_config_files="$ac_config_files libraries/libldbm/Makefile:build/top.mk:libraries/libldbm/Makefile.in:build/lib.mk:build/lib-static.mk"
33500
33501           ac_config_files="$ac_config_files libraries/libldif/Makefile:build/top.mk:libraries/libldif/Makefile.in:build/lib.mk:build/lib-static.mk"
33502
33503           ac_config_files="$ac_config_files libraries/liblunicode/Makefile:build/top.mk:libraries/liblunicode/Makefile.in:build/lib.mk:build/lib-static.mk"
33504
33505           ac_config_files="$ac_config_files libraries/liblutil/Makefile:build/top.mk:libraries/liblutil/Makefile.in:build/lib.mk:build/lib-static.mk"
33506
33507           ac_config_files="$ac_config_files libraries/librewrite/Makefile:build/top.mk:libraries/librewrite/Makefile.in:build/lib.mk:build/lib-static.mk"
33508
33509           ac_config_files="$ac_config_files servers/Makefile:build/top.mk:servers/Makefile.in:build/dir.mk"
33510
33511           ac_config_files="$ac_config_files servers/slapd/Makefile:build/top.mk:servers/slapd/Makefile.in:build/srv.mk"
33512
33513           ac_config_files="$ac_config_files servers/slapd/back-bdb/Makefile:build/top.mk:servers/slapd/back-bdb/Makefile.in:build/mod.mk"
33514
33515           ac_config_files="$ac_config_files servers/slapd/back-dnssrv/Makefile:build/top.mk:servers/slapd/back-dnssrv/Makefile.in:build/mod.mk"
33516
33517           ac_config_files="$ac_config_files servers/slapd/back-ldap/Makefile:build/top.mk:servers/slapd/back-ldap/Makefile.in:build/mod.mk"
33518
33519           ac_config_files="$ac_config_files servers/slapd/back-ldbm/Makefile:build/top.mk:servers/slapd/back-ldbm/Makefile.in:build/mod.mk"
33520
33521           ac_config_files="$ac_config_files servers/slapd/back-meta/Makefile:build/top.mk:servers/slapd/back-meta/Makefile.in:build/mod.mk"
33522
33523           ac_config_files="$ac_config_files servers/slapd/back-monitor/Makefile:build/top.mk:servers/slapd/back-monitor/Makefile.in:build/mod.mk"
33524
33525           ac_config_files="$ac_config_files servers/slapd/back-null/Makefile:build/top.mk:servers/slapd/back-null/Makefile.in:build/mod.mk"
33526
33527           ac_config_files="$ac_config_files servers/slapd/back-passwd/Makefile:build/top.mk:servers/slapd/back-passwd/Makefile.in:build/mod.mk"
33528
33529           ac_config_files="$ac_config_files servers/slapd/back-perl/Makefile:build/top.mk:servers/slapd/back-perl/Makefile.in:build/mod.mk"
33530
33531           ac_config_files="$ac_config_files servers/slapd/back-shell/Makefile:build/top.mk:servers/slapd/back-shell/Makefile.in:build/mod.mk"
33532
33533           ac_config_files="$ac_config_files servers/slapd/back-sql/Makefile:build/top.mk:servers/slapd/back-sql/Makefile.in:build/mod.mk"
33534
33535           ac_config_files="$ac_config_files servers/slapd/back-tcl/Makefile:build/top.mk:servers/slapd/back-tcl/Makefile.in:build/mod.mk"
33536
33537           ac_config_files="$ac_config_files servers/slapd/shell-backends/Makefile:build/top.mk:servers/slapd/shell-backends/Makefile.in:build/srv.mk"
33538
33539           ac_config_files="$ac_config_files servers/slapd/slapi/Makefile:build/top.mk:servers/slapd/slapi/Makefile.in:build/lib.mk:build/lib-shared.mk"
33540
33541           ac_config_files="$ac_config_files servers/slapd/tools/Makefile:build/top.mk:servers/slapd/tools/Makefile.in"
33542
33543           ac_config_files="$ac_config_files servers/slurpd/Makefile:build/top.mk:servers/slurpd/Makefile.in:build/srv.mk"
33544
33545           ac_config_files="$ac_config_files tests/Makefile:build/top.mk:tests/Makefile.in:build/dir.mk"
33546
33547           ac_config_files="$ac_config_files tests/progs/Makefile:build/top.mk:tests/progs/Makefile.in:build/rules.mk"
33548
33549
33550           ac_config_commands="$ac_config_commands time-stamp"
33551
33552 cat >confcache <<\_ACEOF
33553 # This file is a shell script that caches the results of configure
33554 # tests run on this system so they can be shared between configure
33555 # scripts and configure runs, see configure's option --config-cache.
33556 # It is not useful on other systems.  If it contains results you don't
33557 # want to keep, you may remove or edit it.
33558 #
33559 # config.status only pays attention to the cache file if you give it
33560 # the --recheck option to rerun configure.
33561 #
33562 # `ac_cv_env_foo' variables (set or unset) will be overridden when
33563 # loading this file, other *unset* `ac_cv_foo' will be assigned the
33564 # following values.
33565
33566 _ACEOF
33567
33568 # The following way of writing the cache mishandles newlines in values,
33569 # but we know of no workaround that is simple, portable, and efficient.
33570 # So, don't put newlines in cache variables' values.
33571 # Ultrix sh set writes to stderr and can't be redirected directly,
33572 # and sets the high bit in the cache file unless we assign to the vars.
33573 {
33574   (set) 2>&1 |
33575     case `(ac_space=' '; set | grep ac_space) 2>&1` in
33576     *ac_space=\ *)
33577       # `set' does not quote correctly, so add quotes (double-quote
33578       # substitution turns \\\\ into \\, and sed turns \\ into \).
33579       sed -n \
33580         "s/'/'\\\\''/g;
33581           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
33582       ;;
33583     *)
33584       # `set' quotes correctly as required by POSIX, so do not add quotes.
33585       sed -n \
33586         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
33587       ;;
33588     esac;
33589 } |
33590   sed '
33591      t clear
33592      : clear
33593      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
33594      t end
33595      /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
33596      : end' >>confcache
33597 if diff $cache_file confcache >/dev/null 2>&1; then :; else
33598   if test -w $cache_file; then
33599     test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
33600     cat confcache >$cache_file
33601   else
33602     echo "not updating unwritable cache $cache_file"
33603   fi
33604 fi
33605 rm -f confcache
33606
33607 test "x$prefix" = xNONE && prefix=$ac_default_prefix
33608 # Let make expand exec_prefix.
33609 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
33610
33611 # VPATH may cause trouble with some makes, so we remove $(srcdir),
33612 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
33613 # trailing colons and then remove the whole line if VPATH becomes empty
33614 # (actually we leave an empty line to preserve line numbers).
33615 if test "x$srcdir" = x.; then
33616   ac_vpsub='/^[         ]*VPATH[        ]*=/{
33617 s/:*\$(srcdir):*/:/;
33618 s/:*\${srcdir}:*/:/;
33619 s/:*@srcdir@:*/:/;
33620 s/^\([^=]*=[    ]*\):*/\1/;
33621 s/:*$//;
33622 s/^[^=]*=[      ]*$//;
33623 }'
33624 fi
33625
33626 DEFS=-DHAVE_CONFIG_H
33627
33628 ac_libobjs=
33629 ac_ltlibobjs=
33630 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
33631   # 1. Remove the extension, and $U if already installed.
33632   ac_i=`echo "$ac_i" |
33633          sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
33634   # 2. Add them.
33635   ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
33636   ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
33637 done
33638 LIBOBJS=$ac_libobjs
33639
33640 LTLIBOBJS=$ac_ltlibobjs
33641
33642
33643
33644 : ${CONFIG_STATUS=./config.status}
33645 ac_clean_files_save=$ac_clean_files
33646 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
33647 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
33648 echo "$as_me: creating $CONFIG_STATUS" >&6;}
33649 cat >$CONFIG_STATUS <<_ACEOF
33650 #! $SHELL
33651 # Generated by $as_me.
33652 # Run this file to recreate the current configuration.
33653 # Compiler output produced by configure, useful for debugging
33654 # configure, is in config.log if it exists.
33655
33656 debug=false
33657 ac_cs_recheck=false
33658 ac_cs_silent=false
33659 SHELL=\${CONFIG_SHELL-$SHELL}
33660 _ACEOF
33661
33662 cat >>$CONFIG_STATUS <<\_ACEOF
33663 ## --------------------- ##
33664 ## M4sh Initialization.  ##
33665 ## --------------------- ##
33666
33667 # Be Bourne compatible
33668 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
33669   emulate sh
33670   NULLCMD=:
33671   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
33672   # is contrary to our usage.  Disable this feature.
33673   alias -g '${1+"$@"}'='"$@"'
33674 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
33675   set -o posix
33676 fi
33677
33678 # Support unset when possible.
33679 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
33680   as_unset=unset
33681 else
33682   as_unset=false
33683 fi
33684
33685
33686 # Work around bugs in pre-3.0 UWIN ksh.
33687 $as_unset ENV MAIL MAILPATH
33688 PS1='$ '
33689 PS2='> '
33690 PS4='+ '
33691
33692 # NLS nuisances.
33693 for as_var in \
33694   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
33695   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
33696   LC_TELEPHONE LC_TIME
33697 do
33698   if (set +x; test -n "`(eval $as_var=C; export $as_var) 2>&1`"); then
33699     eval $as_var=C; export $as_var
33700   else
33701     $as_unset $as_var
33702   fi
33703 done
33704
33705 # Required to use basename.
33706 if expr a : '\(a\)' >/dev/null 2>&1; then
33707   as_expr=expr
33708 else
33709   as_expr=false
33710 fi
33711
33712 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
33713   as_basename=basename
33714 else
33715   as_basename=false
33716 fi
33717
33718
33719 # Name of the executable.
33720 as_me=`$as_basename "$0" ||
33721 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
33722          X"$0" : 'X\(//\)$' \| \
33723          X"$0" : 'X\(/\)$' \| \
33724          .     : '\(.\)' 2>/dev/null ||
33725 echo X/"$0" |
33726     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
33727           /^X\/\(\/\/\)$/{ s//\1/; q; }
33728           /^X\/\(\/\).*/{ s//\1/; q; }
33729           s/.*/./; q'`
33730
33731
33732 # PATH needs CR, and LINENO needs CR and PATH.
33733 # Avoid depending upon Character Ranges.
33734 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
33735 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
33736 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
33737 as_cr_digits='0123456789'
33738 as_cr_alnum=$as_cr_Letters$as_cr_digits
33739
33740 # The user is always right.
33741 if test "${PATH_SEPARATOR+set}" != set; then
33742   echo "#! /bin/sh" >conf$$.sh
33743   echo  "exit 0"   >>conf$$.sh
33744   chmod +x conf$$.sh
33745   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
33746     PATH_SEPARATOR=';'
33747   else
33748     PATH_SEPARATOR=:
33749   fi
33750   rm -f conf$$.sh
33751 fi
33752
33753
33754   as_lineno_1=$LINENO
33755   as_lineno_2=$LINENO
33756   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
33757   test "x$as_lineno_1" != "x$as_lineno_2" &&
33758   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
33759   # Find who we are.  Look in the path if we contain no path at all
33760   # relative or not.
33761   case $0 in
33762     *[\\/]* ) as_myself=$0 ;;
33763     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33764 for as_dir in $PATH
33765 do
33766   IFS=$as_save_IFS
33767   test -z "$as_dir" && as_dir=.
33768   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
33769 done
33770
33771        ;;
33772   esac
33773   # We did not find ourselves, most probably we were run as `sh COMMAND'
33774   # in which case we are not to be found in the path.
33775   if test "x$as_myself" = x; then
33776     as_myself=$0
33777   fi
33778   if test ! -f "$as_myself"; then
33779     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
33780 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
33781    { (exit 1); exit 1; }; }
33782   fi
33783   case $CONFIG_SHELL in
33784   '')
33785     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33786 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
33787 do
33788   IFS=$as_save_IFS
33789   test -z "$as_dir" && as_dir=.
33790   for as_base in sh bash ksh sh5; do
33791          case $as_dir in
33792          /*)
33793            if ("$as_dir/$as_base" -c '
33794   as_lineno_1=$LINENO
33795   as_lineno_2=$LINENO
33796   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
33797   test "x$as_lineno_1" != "x$as_lineno_2" &&
33798   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
33799              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
33800              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
33801              CONFIG_SHELL=$as_dir/$as_base
33802              export CONFIG_SHELL
33803              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
33804            fi;;
33805          esac
33806        done
33807 done
33808 ;;
33809   esac
33810
33811   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
33812   # uniformly replaced by the line number.  The first 'sed' inserts a
33813   # line-number line before each line; the second 'sed' does the real
33814   # work.  The second script uses 'N' to pair each line-number line
33815   # with the numbered line, and appends trailing '-' during
33816   # substitution so that $LINENO is not a special case at line end.
33817   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
33818   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
33819   sed '=' <$as_myself |
33820     sed '
33821       N
33822       s,$,-,
33823       : loop
33824       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
33825       t loop
33826       s,-$,,
33827       s,^['$as_cr_digits']*\n,,
33828     ' >$as_me.lineno &&
33829   chmod +x $as_me.lineno ||
33830     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
33831 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
33832    { (exit 1); exit 1; }; }
33833
33834   # Don't try to exec as it changes $[0], causing all sort of problems
33835   # (the dirname of $[0] is not the place where we might find the
33836   # original and so on.  Autoconf is especially sensible to this).
33837   . ./$as_me.lineno
33838   # Exit status is that of the last command.
33839   exit
33840 }
33841
33842
33843 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
33844   *c*,-n*) ECHO_N= ECHO_C='
33845 ' ECHO_T='      ' ;;
33846   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
33847   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
33848 esac
33849
33850 if expr a : '\(a\)' >/dev/null 2>&1; then
33851   as_expr=expr
33852 else
33853   as_expr=false
33854 fi
33855
33856 rm -f conf$$ conf$$.exe conf$$.file
33857 echo >conf$$.file
33858 if ln -s conf$$.file conf$$ 2>/dev/null; then
33859   # We could just check for DJGPP; but this test a) works b) is more generic
33860   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
33861   if test -f conf$$.exe; then
33862     # Don't use ln at all; we don't have any links
33863     as_ln_s='cp -p'
33864   else
33865     as_ln_s='ln -s'
33866   fi
33867 elif ln conf$$.file conf$$ 2>/dev/null; then
33868   as_ln_s=ln
33869 else
33870   as_ln_s='cp -p'
33871 fi
33872 rm -f conf$$ conf$$.exe conf$$.file
33873
33874 if mkdir -p . 2>/dev/null; then
33875   as_mkdir_p=:
33876 else
33877   as_mkdir_p=false
33878 fi
33879
33880 as_executable_p="test -f"
33881
33882 # Sed expression to map a string onto a valid CPP name.
33883 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
33884
33885 # Sed expression to map a string onto a valid variable name.
33886 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
33887
33888
33889 # IFS
33890 # We need space, tab and new line, in precisely that order.
33891 as_nl='
33892 '
33893 IFS="   $as_nl"
33894
33895 # CDPATH.
33896 $as_unset CDPATH
33897
33898 exec 6>&1
33899
33900 # Open the log real soon, to keep \$[0] and so on meaningful, and to
33901 # report actual input values of CONFIG_FILES etc. instead of their
33902 # values after options handling.  Logging --version etc. is OK.
33903 exec 5>>config.log
33904 {
33905   echo
33906   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
33907 ## Running $as_me. ##
33908 _ASBOX
33909 } >&5
33910 cat >&5 <<_CSEOF
33911
33912 This file was extended by $as_me, which was
33913 generated by GNU Autoconf 2.57.  Invocation command line was
33914
33915   CONFIG_FILES    = $CONFIG_FILES
33916   CONFIG_HEADERS  = $CONFIG_HEADERS
33917   CONFIG_LINKS    = $CONFIG_LINKS
33918   CONFIG_COMMANDS = $CONFIG_COMMANDS
33919   $ $0 $@
33920
33921 _CSEOF
33922 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
33923 echo >&5
33924 _ACEOF
33925
33926 # Files that config.status was made for.
33927 if test -n "$ac_config_files"; then
33928   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
33929 fi
33930
33931 if test -n "$ac_config_headers"; then
33932   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
33933 fi
33934
33935 if test -n "$ac_config_links"; then
33936   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
33937 fi
33938
33939 if test -n "$ac_config_commands"; then
33940   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
33941 fi
33942
33943 cat >>$CONFIG_STATUS <<\_ACEOF
33944
33945 ac_cs_usage="\
33946 \`$as_me' instantiates files from templates according to the
33947 current configuration.
33948
33949 Usage: $0 [OPTIONS] [FILE]...
33950
33951   -h, --help       print this help, then exit
33952   -V, --version    print version number, then exit
33953   -q, --quiet      do not print progress messages
33954   -d, --debug      don't remove temporary files
33955       --recheck    update $as_me by reconfiguring in the same conditions
33956   --file=FILE[:TEMPLATE]
33957                    instantiate the configuration file FILE
33958   --header=FILE[:TEMPLATE]
33959                    instantiate the configuration header FILE
33960
33961 Configuration files:
33962 $config_files
33963
33964 Configuration headers:
33965 $config_headers
33966
33967 Configuration commands:
33968 $config_commands
33969
33970 Report bugs to <bug-autoconf@gnu.org>."
33971 _ACEOF
33972
33973 cat >>$CONFIG_STATUS <<_ACEOF
33974 ac_cs_version="\\
33975 config.status
33976 configured by $0, generated by GNU Autoconf 2.57,
33977   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
33978
33979 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
33980 Free Software Foundation, Inc.
33981 This config.status script is free software; the Free Software Foundation
33982 gives unlimited permission to copy, distribute and modify it."
33983 srcdir=$srcdir
33984 INSTALL="$INSTALL"
33985 _ACEOF
33986
33987 cat >>$CONFIG_STATUS <<\_ACEOF
33988 # If no file are specified by the user, then we need to provide default
33989 # value.  By we need to know if files were specified by the user.
33990 ac_need_defaults=:
33991 while test $# != 0
33992 do
33993   case $1 in
33994   --*=*)
33995     ac_option=`expr "x$1" : 'x\([^=]*\)='`
33996     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
33997     ac_shift=:
33998     ;;
33999   -*)
34000     ac_option=$1
34001     ac_optarg=$2
34002     ac_shift=shift
34003     ;;
34004   *) # This is not an option, so the user has probably given explicit
34005      # arguments.
34006      ac_option=$1
34007      ac_need_defaults=false;;
34008   esac
34009
34010   case $ac_option in
34011   # Handling of the options.
34012 _ACEOF
34013 cat >>$CONFIG_STATUS <<\_ACEOF
34014   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
34015     ac_cs_recheck=: ;;
34016   --version | --vers* | -V )
34017     echo "$ac_cs_version"; exit 0 ;;
34018   --he | --h)
34019     # Conflict between --help and --header
34020     { { echo "$as_me:$LINENO: error: ambiguous option: $1
34021 Try \`$0 --help' for more information." >&5
34022 echo "$as_me: error: ambiguous option: $1
34023 Try \`$0 --help' for more information." >&2;}
34024    { (exit 1); exit 1; }; };;
34025   --help | --hel | -h )
34026     echo "$ac_cs_usage"; exit 0 ;;
34027   --debug | --d* | -d )
34028     debug=: ;;
34029   --file | --fil | --fi | --f )
34030     $ac_shift
34031     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
34032     ac_need_defaults=false;;
34033   --header | --heade | --head | --hea )
34034     $ac_shift
34035     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
34036     ac_need_defaults=false;;
34037   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
34038   | -silent | --silent | --silen | --sile | --sil | --si | --s)
34039     ac_cs_silent=: ;;
34040
34041   # This is an error.
34042   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
34043 Try \`$0 --help' for more information." >&5
34044 echo "$as_me: error: unrecognized option: $1
34045 Try \`$0 --help' for more information." >&2;}
34046    { (exit 1); exit 1; }; } ;;
34047
34048   *) ac_config_targets="$ac_config_targets $1" ;;
34049
34050   esac
34051   shift
34052 done
34053
34054 ac_configure_extra_args=
34055
34056 if $ac_cs_silent; then
34057   exec 6>/dev/null
34058   ac_configure_extra_args="$ac_configure_extra_args --silent"
34059 fi
34060
34061 _ACEOF
34062 cat >>$CONFIG_STATUS <<_ACEOF
34063 if \$ac_cs_recheck; then
34064   echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
34065   exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
34066 fi
34067
34068 _ACEOF
34069
34070
34071
34072
34073
34074 cat >>$CONFIG_STATUS <<\_ACEOF
34075 for ac_config_target in $ac_config_targets
34076 do
34077   case "$ac_config_target" in
34078   # Handling of arguments.
34079   "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile:build/top.mk:Makefile.in:build/dir.mk" ;;
34080   "doc/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/Makefile:build/top.mk:doc/Makefile.in:build/dir.mk" ;;
34081   "doc/man/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/Makefile:build/top.mk:doc/man/Makefile.in:build/dir.mk" ;;
34082   "doc/man/man1/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man1/Makefile:build/top.mk:doc/man/man1/Makefile.in:build/man.mk" ;;
34083   "doc/man/man3/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man3/Makefile:build/top.mk:doc/man/man3/Makefile.in:build/man.mk" ;;
34084   "doc/man/man5/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man5/Makefile:build/top.mk:doc/man/man5/Makefile.in:build/man.mk" ;;
34085   "doc/man/man8/Makefile" ) CONFIG_FILES="$CONFIG_FILES doc/man/man8/Makefile:build/top.mk:doc/man/man8/Makefile.in:build/man.mk" ;;
34086   "clients/Makefile" ) CONFIG_FILES="$CONFIG_FILES clients/Makefile:build/top.mk:clients/Makefile.in:build/dir.mk" ;;
34087   "clients/tools/Makefile" ) CONFIG_FILES="$CONFIG_FILES clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk" ;;
34088   "include/Makefile" ) CONFIG_FILES="$CONFIG_FILES include/Makefile:build/top.mk:include/Makefile.in" ;;
34089   "libraries/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/Makefile:build/top.mk:libraries/Makefile.in:build/dir.mk" ;;
34090   "libraries/libavl/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/libavl/Makefile:build/top.mk:libraries/libavl/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
34091   "libraries/liblber/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblber/Makefile:build/top.mk:libraries/liblber/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
34092   "libraries/libldap/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/libldap/Makefile:build/top.mk:libraries/libldap/Makefile.in:build/lib.mk:build/lib-shared.mk" ;;
34093   "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" ;;
34094   "libraries/libldbm/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/libldbm/Makefile:build/top.mk:libraries/libldbm/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
34095   "libraries/libldif/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/libldif/Makefile:build/top.mk:libraries/libldif/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
34096   "libraries/liblunicode/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblunicode/Makefile:build/top.mk:libraries/liblunicode/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
34097   "libraries/liblutil/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/liblutil/Makefile:build/top.mk:libraries/liblutil/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
34098   "libraries/librewrite/Makefile" ) CONFIG_FILES="$CONFIG_FILES libraries/librewrite/Makefile:build/top.mk:libraries/librewrite/Makefile.in:build/lib.mk:build/lib-static.mk" ;;
34099   "servers/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/Makefile:build/top.mk:servers/Makefile.in:build/dir.mk" ;;
34100   "servers/slapd/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/Makefile:build/top.mk:servers/slapd/Makefile.in:build/srv.mk" ;;
34101   "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" ;;
34102   "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" ;;
34103   "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" ;;
34104   "servers/slapd/back-ldbm/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-ldbm/Makefile:build/top.mk:servers/slapd/back-ldbm/Makefile.in:build/mod.mk" ;;
34105   "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" ;;
34106   "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" ;;
34107   "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" ;;
34108   "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" ;;
34109   "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" ;;
34110   "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" ;;
34111   "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" ;;
34112   "servers/slapd/back-tcl/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/back-tcl/Makefile:build/top.mk:servers/slapd/back-tcl/Makefile.in:build/mod.mk" ;;
34113   "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" ;;
34114   "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" ;;
34115   "servers/slapd/tools/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slapd/tools/Makefile:build/top.mk:servers/slapd/tools/Makefile.in" ;;
34116   "servers/slurpd/Makefile" ) CONFIG_FILES="$CONFIG_FILES servers/slurpd/Makefile:build/top.mk:servers/slurpd/Makefile.in:build/srv.mk" ;;
34117   "tests/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/Makefile:build/top.mk:tests/Makefile.in:build/dir.mk" ;;
34118   "tests/progs/Makefile" ) CONFIG_FILES="$CONFIG_FILES tests/progs/Makefile:build/top.mk:tests/progs/Makefile.in:build/rules.mk" ;;
34119   "time-stamp" ) CONFIG_COMMANDS="$CONFIG_COMMANDS time-stamp" ;;
34120   "include/portable.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/portable.h" ;;
34121   "include/ldap_features.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ldap_features.h" ;;
34122   "include/lber_types.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/lber_types.h" ;;
34123   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
34124 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
34125    { (exit 1); exit 1; }; };;
34126   esac
34127 done
34128
34129 # If the user did not use the arguments to specify the items to instantiate,
34130 # then the envvar interface is used.  Set only those that are not.
34131 # We use the long form for the default assignment because of an extremely
34132 # bizarre bug on SunOS 4.1.3.
34133 if $ac_need_defaults; then
34134   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
34135   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
34136   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
34137 fi
34138
34139 # Have a temporary directory for convenience.  Make it in the build tree
34140 # simply because there is no reason to put it here, and in addition,
34141 # creating and moving files from /tmp can sometimes cause problems.
34142 # Create a temporary directory, and hook for its removal unless debugging.
34143 $debug ||
34144 {
34145   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
34146   trap '{ (exit 1); exit 1; }' 1 2 13 15
34147 }
34148
34149 # Create a (secure) tmp directory for tmp files.
34150
34151 {
34152   tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
34153   test -n "$tmp" && test -d "$tmp"
34154 }  ||
34155 {
34156   tmp=./confstat$$-$RANDOM
34157   (umask 077 && mkdir $tmp)
34158 } ||
34159 {
34160    echo "$me: cannot create a temporary directory in ." >&2
34161    { (exit 1); exit 1; }
34162 }
34163
34164 _ACEOF
34165
34166 cat >>$CONFIG_STATUS <<_ACEOF
34167
34168 #
34169 # CONFIG_FILES section.
34170 #
34171
34172 # No need to generate the scripts if there are no CONFIG_FILES.
34173 # This happens for instance when ./config.status config.h
34174 if test -n "\$CONFIG_FILES"; then
34175   # Protect against being on the right side of a sed subst in config.status.
34176   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
34177    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
34178 s,@SHELL@,$SHELL,;t t
34179 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
34180 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
34181 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
34182 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
34183 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
34184 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
34185 s,@exec_prefix@,$exec_prefix,;t t
34186 s,@prefix@,$prefix,;t t
34187 s,@program_transform_name@,$program_transform_name,;t t
34188 s,@bindir@,$bindir,;t t
34189 s,@sbindir@,$sbindir,;t t
34190 s,@libexecdir@,$libexecdir,;t t
34191 s,@datadir@,$datadir,;t t
34192 s,@sysconfdir@,$sysconfdir,;t t
34193 s,@sharedstatedir@,$sharedstatedir,;t t
34194 s,@localstatedir@,$localstatedir,;t t
34195 s,@libdir@,$libdir,;t t
34196 s,@includedir@,$includedir,;t t
34197 s,@oldincludedir@,$oldincludedir,;t t
34198 s,@infodir@,$infodir,;t t
34199 s,@mandir@,$mandir,;t t
34200 s,@build_alias@,$build_alias,;t t
34201 s,@host_alias@,$host_alias,;t t
34202 s,@target_alias@,$target_alias,;t t
34203 s,@DEFS@,$DEFS,;t t
34204 s,@ECHO_C@,$ECHO_C,;t t
34205 s,@ECHO_N@,$ECHO_N,;t t
34206 s,@ECHO_T@,$ECHO_T,;t t
34207 s,@LIBS@,$LIBS,;t t
34208 s,@SHTOOL@,$SHTOOL,;t t
34209 s,@build@,$build,;t t
34210 s,@build_cpu@,$build_cpu,;t t
34211 s,@build_vendor@,$build_vendor,;t t
34212 s,@build_os@,$build_os,;t t
34213 s,@host@,$host,;t t
34214 s,@host_cpu@,$host_cpu,;t t
34215 s,@host_vendor@,$host_vendor,;t t
34216 s,@host_os@,$host_os,;t t
34217 s,@target@,$target,;t t
34218 s,@target_cpu@,$target_cpu,;t t
34219 s,@target_vendor@,$target_vendor,;t t
34220 s,@target_os@,$target_os,;t t
34221 s,@OPENLDAP_PACKAGE@,$OPENLDAP_PACKAGE,;t t
34222 s,@OPENLDAP_VERSION@,$OPENLDAP_VERSION,;t t
34223 s,@OPENLDAP_LIBVERSION@,$OPENLDAP_LIBVERSION,;t t
34224 s,@OPENLDAP_RELEASE_DATE@,$OPENLDAP_RELEASE_DATE,;t t
34225 s,@top_builddir@,$top_builddir,;t t
34226 s,@ldap_subdir@,$ldap_subdir,;t t
34227 s,@SET_MAKE@,$SET_MAKE,;t t
34228 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
34229 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
34230 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
34231 s,@CC@,$CC,;t t
34232 s,@AR@,$AR,;t t
34233 s,@CFLAGS@,$CFLAGS,;t t
34234 s,@LDFLAGS@,$LDFLAGS,;t t
34235 s,@CPPFLAGS@,$CPPFLAGS,;t t
34236 s,@ac_ct_CC@,$ac_ct_CC,;t t
34237 s,@EXEEXT@,$EXEEXT,;t t
34238 s,@OBJEXT@,$OBJEXT,;t t
34239 s,@LN_S@,$LN_S,;t t
34240 s,@ECHO@,$ECHO,;t t
34241 s,@RANLIB@,$RANLIB,;t t
34242 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
34243 s,@STRIP@,$STRIP,;t t
34244 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
34245 s,@CPP@,$CPP,;t t
34246 s,@EGREP@,$EGREP,;t t
34247 s,@LIBTOOL@,$LIBTOOL,;t t
34248 s,@LN_H@,$LN_H,;t t
34249 s,@PERLBIN@,$PERLBIN,;t t
34250 s,@OL_MKDEP@,$OL_MKDEP,;t t
34251 s,@OL_MKDEP_FLAGS@,$OL_MKDEP_FLAGS,;t t
34252 s,@LTSTATIC@,$LTSTATIC,;t t
34253 s,@LIBOBJS@,$LIBOBJS,;t t
34254 s,@LIBSRCS@,$LIBSRCS,;t t
34255 s,@PLAT@,$PLAT,;t t
34256 s,@BUILD_LIBS_DYNAMIC@,$BUILD_LIBS_DYNAMIC,;t t
34257 s,@BUILD_SLAPD@,$BUILD_SLAPD,;t t
34258 s,@BUILD_SLAPI@,$BUILD_SLAPI,;t t
34259 s,@SLAPD_SLAPI_DEPEND@,$SLAPD_SLAPI_DEPEND,;t t
34260 s,@BUILD_BDB@,$BUILD_BDB,;t t
34261 s,@BUILD_DNSSRV@,$BUILD_DNSSRV,;t t
34262 s,@BUILD_LDAP@,$BUILD_LDAP,;t t
34263 s,@BUILD_LDBM@,$BUILD_LDBM,;t t
34264 s,@BUILD_META@,$BUILD_META,;t t
34265 s,@BUILD_MONITOR@,$BUILD_MONITOR,;t t
34266 s,@BUILD_NULL@,$BUILD_NULL,;t t
34267 s,@BUILD_PASSWD@,$BUILD_PASSWD,;t t
34268 s,@BUILD_PERL@,$BUILD_PERL,;t t
34269 s,@BUILD_SHELL@,$BUILD_SHELL,;t t
34270 s,@BUILD_SQL@,$BUILD_SQL,;t t
34271 s,@BUILD_TCL@,$BUILD_TCL,;t t
34272 s,@BUILD_BDB_DYNAMIC@,$BUILD_BDB_DYNAMIC,;t t
34273 s,@BUILD_DNSSRV_DYNAMIC@,$BUILD_DNSSRV_DYNAMIC,;t t
34274 s,@BUILD_LDAP_DYNAMIC@,$BUILD_LDAP_DYNAMIC,;t t
34275 s,@BUILD_LDBM_DYNAMIC@,$BUILD_LDBM_DYNAMIC,;t t
34276 s,@BUILD_META_DYNAMIC@,$BUILD_META_DYNAMIC,;t t
34277 s,@BUILD_MONITOR_DYNAMIC@,$BUILD_MONITOR_DYNAMIC,;t t
34278 s,@BUILD_NULL_DYNAMIC@,$BUILD_NULL_DYNAMIC,;t t
34279 s,@BUILD_PASSWD_DYNAMIC@,$BUILD_PASSWD_DYNAMIC,;t t
34280 s,@BUILD_PERL_DYNAMIC@,$BUILD_PERL_DYNAMIC,;t t
34281 s,@BUILD_SHELL_DYNAMIC@,$BUILD_SHELL_DYNAMIC,;t t
34282 s,@BUILD_SQL_DYNAMIC@,$BUILD_SQL_DYNAMIC,;t t
34283 s,@BUILD_TCL_DYNAMIC@,$BUILD_TCL_DYNAMIC,;t t
34284 s,@BUILD_SLURPD@,$BUILD_SLURPD,;t t
34285 s,@LDAP_LIBS@,$LDAP_LIBS,;t t
34286 s,@LDIF_LIBS@,$LDIF_LIBS,;t t
34287 s,@SLAPD_LIBS@,$SLAPD_LIBS,;t t
34288 s,@SLURPD_LIBS@,$SLURPD_LIBS,;t t
34289 s,@LDBM_LIBS@,$LDBM_LIBS,;t t
34290 s,@LTHREAD_LIBS@,$LTHREAD_LIBS,;t t
34291 s,@LUTIL_LIBS@,$LUTIL_LIBS,;t t
34292 s,@WRAP_LIBS@,$WRAP_LIBS,;t t
34293 s,@MOD_TCL_LIB@,$MOD_TCL_LIB,;t t
34294 s,@SLAPD_MODULES_CPPFLAGS@,$SLAPD_MODULES_CPPFLAGS,;t t
34295 s,@SLAPD_MODULES_LDFLAGS@,$SLAPD_MODULES_LDFLAGS,;t t
34296 s,@SLAPD_NO_STATIC@,$SLAPD_NO_STATIC,;t t
34297 s,@SLAPD_STATIC_BACKENDS@,$SLAPD_STATIC_BACKENDS,;t t
34298 s,@SLAPD_DYNAMIC_BACKENDS@,$SLAPD_DYNAMIC_BACKENDS,;t t
34299 s,@PERL_CPPFLAGS@,$PERL_CPPFLAGS,;t t
34300 s,@SLAPD_PERL_LDFLAGS@,$SLAPD_PERL_LDFLAGS,;t t
34301 s,@MOD_PERL_LDFLAGS@,$MOD_PERL_LDFLAGS,;t t
34302 s,@KRB4_LIBS@,$KRB4_LIBS,;t t
34303 s,@KRB5_LIBS@,$KRB5_LIBS,;t t
34304 s,@READLINE_LIBS@,$READLINE_LIBS,;t t
34305 s,@SASL_LIBS@,$SASL_LIBS,;t t
34306 s,@TERMCAP_LIBS@,$TERMCAP_LIBS,;t t
34307 s,@TLS_LIBS@,$TLS_LIBS,;t t
34308 s,@MODULES_LIBS@,$MODULES_LIBS,;t t
34309 s,@SLAPI_LIBS@,$SLAPI_LIBS,;t t
34310 s,@LIBSLAPI@,$LIBSLAPI,;t t
34311 s,@LIBSLAPITOOLS@,$LIBSLAPITOOLS,;t t
34312 s,@AUTH_LIBS@,$AUTH_LIBS,;t t
34313 s,@SLAPD_SLP_LIBS@,$SLAPD_SLP_LIBS,;t t
34314 s,@SLAPD_SQL_LDFLAGS@,$SLAPD_SQL_LDFLAGS,;t t
34315 s,@SLAPD_SQL_LIBS@,$SLAPD_SQL_LIBS,;t t
34316 s,@SLAPD_SQL_INCLUDES@,$SLAPD_SQL_INCLUDES,;t t
34317 s,@LTLIBOBJS@,$LTLIBOBJS,;t t
34318 CEOF
34319
34320 _ACEOF
34321
34322   cat >>$CONFIG_STATUS <<\_ACEOF
34323   # Split the substitutions into bite-sized pieces for seds with
34324   # small command number limits, like on Digital OSF/1 and HP-UX.
34325   ac_max_sed_lines=48
34326   ac_sed_frag=1 # Number of current file.
34327   ac_beg=1 # First line for current file.
34328   ac_end=$ac_max_sed_lines # Line after last line for current file.
34329   ac_more_lines=:
34330   ac_sed_cmds=
34331   while $ac_more_lines; do
34332     if test $ac_beg -gt 1; then
34333       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
34334     else
34335       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
34336     fi
34337     if test ! -s $tmp/subs.frag; then
34338       ac_more_lines=false
34339     else
34340       # The purpose of the label and of the branching condition is to
34341       # speed up the sed processing (if there are no `@' at all, there
34342       # is no need to browse any of the substitutions).
34343       # These are the two extra sed commands mentioned above.
34344       (echo ':t
34345   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
34346       if test -z "$ac_sed_cmds"; then
34347         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
34348       else
34349         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
34350       fi
34351       ac_sed_frag=`expr $ac_sed_frag + 1`
34352       ac_beg=$ac_end
34353       ac_end=`expr $ac_end + $ac_max_sed_lines`
34354     fi
34355   done
34356   if test -z "$ac_sed_cmds"; then
34357     ac_sed_cmds=cat
34358   fi
34359 fi # test -n "$CONFIG_FILES"
34360
34361 _ACEOF
34362 cat >>$CONFIG_STATUS <<\_ACEOF
34363 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
34364   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
34365   case $ac_file in
34366   - | *:- | *:-:* ) # input from stdin
34367         cat >$tmp/stdin
34368         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
34369         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
34370   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
34371         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
34372   * )   ac_file_in=$ac_file.in ;;
34373   esac
34374
34375   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
34376   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
34377 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
34378          X"$ac_file" : 'X\(//\)[^/]' \| \
34379          X"$ac_file" : 'X\(//\)$' \| \
34380          X"$ac_file" : 'X\(/\)' \| \
34381          .     : '\(.\)' 2>/dev/null ||
34382 echo X"$ac_file" |
34383     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
34384           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
34385           /^X\(\/\/\)$/{ s//\1/; q; }
34386           /^X\(\/\).*/{ s//\1/; q; }
34387           s/.*/./; q'`
34388   { if $as_mkdir_p; then
34389     mkdir -p "$ac_dir"
34390   else
34391     as_dir="$ac_dir"
34392     as_dirs=
34393     while test ! -d "$as_dir"; do
34394       as_dirs="$as_dir $as_dirs"
34395       as_dir=`(dirname "$as_dir") 2>/dev/null ||
34396 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
34397          X"$as_dir" : 'X\(//\)[^/]' \| \
34398          X"$as_dir" : 'X\(//\)$' \| \
34399          X"$as_dir" : 'X\(/\)' \| \
34400          .     : '\(.\)' 2>/dev/null ||
34401 echo X"$as_dir" |
34402     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
34403           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
34404           /^X\(\/\/\)$/{ s//\1/; q; }
34405           /^X\(\/\).*/{ s//\1/; q; }
34406           s/.*/./; q'`
34407     done
34408     test ! -n "$as_dirs" || mkdir $as_dirs
34409   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
34410 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
34411    { (exit 1); exit 1; }; }; }
34412
34413   ac_builddir=.
34414
34415 if test "$ac_dir" != .; then
34416   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
34417   # A "../" for each directory in $ac_dir_suffix.
34418   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
34419 else
34420   ac_dir_suffix= ac_top_builddir=
34421 fi
34422
34423 case $srcdir in
34424   .)  # No --srcdir option.  We are building in place.
34425     ac_srcdir=.
34426     if test -z "$ac_top_builddir"; then
34427        ac_top_srcdir=.
34428     else
34429        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
34430     fi ;;
34431   [\\/]* | ?:[\\/]* )  # Absolute path.
34432     ac_srcdir=$srcdir$ac_dir_suffix;
34433     ac_top_srcdir=$srcdir ;;
34434   *) # Relative path.
34435     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
34436     ac_top_srcdir=$ac_top_builddir$srcdir ;;
34437 esac
34438 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
34439 # absolute.
34440 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
34441 ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
34442 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
34443 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
34444
34445
34446   case $INSTALL in
34447   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
34448   *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
34449   esac
34450
34451   if test x"$ac_file" != x-; then
34452     { echo "$as_me:$LINENO: creating $ac_file" >&5
34453 echo "$as_me: creating $ac_file" >&6;}
34454     rm -f "$ac_file"
34455   fi
34456   # Let's still pretend it is `configure' which instantiates (i.e., don't
34457   # use $as_me), people would be surprised to read:
34458   #    /* config.h.  Generated by config.status.  */
34459   if test x"$ac_file" = x-; then
34460     configure_input=
34461   else
34462     configure_input="$ac_file.  "
34463   fi
34464   configure_input=$configure_input"Generated from `echo $ac_file_in |
34465                                      sed 's,.*/,,'` by configure."
34466
34467   # First look for the input files in the build tree, otherwise in the
34468   # src tree.
34469   ac_file_inputs=`IFS=:
34470     for f in $ac_file_in; do
34471       case $f in
34472       -) echo $tmp/stdin ;;
34473       [\\/$]*)
34474          # Absolute (can't be DOS-style, as IFS=:)
34475          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
34476 echo "$as_me: error: cannot find input file: $f" >&2;}
34477    { (exit 1); exit 1; }; }
34478          echo $f;;
34479       *) # Relative
34480          if test -f "$f"; then
34481            # Build tree
34482            echo $f
34483          elif test -f "$srcdir/$f"; then
34484            # Source tree
34485            echo $srcdir/$f
34486          else
34487            # /dev/null tree
34488            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
34489 echo "$as_me: error: cannot find input file: $f" >&2;}
34490    { (exit 1); exit 1; }; }
34491          fi;;
34492       esac
34493     done` || { (exit 1); exit 1; }
34494 _ACEOF
34495 cat >>$CONFIG_STATUS <<_ACEOF
34496   sed "$ac_vpsub
34497 $extrasub
34498 _ACEOF
34499 cat >>$CONFIG_STATUS <<\_ACEOF
34500 :t
34501 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
34502 s,@configure_input@,$configure_input,;t t
34503 s,@srcdir@,$ac_srcdir,;t t
34504 s,@abs_srcdir@,$ac_abs_srcdir,;t t
34505 s,@top_srcdir@,$ac_top_srcdir,;t t
34506 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
34507 s,@builddir@,$ac_builddir,;t t
34508 s,@abs_builddir@,$ac_abs_builddir,;t t
34509 s,@top_builddir@,$ac_top_builddir,;t t
34510 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
34511 s,@INSTALL@,$ac_INSTALL,;t t
34512 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
34513   rm -f $tmp/stdin
34514   if test x"$ac_file" != x-; then
34515     mv $tmp/out $ac_file
34516   else
34517     cat $tmp/out
34518     rm -f $tmp/out
34519   fi
34520
34521 done
34522 _ACEOF
34523 cat >>$CONFIG_STATUS <<\_ACEOF
34524
34525 #
34526 # CONFIG_HEADER section.
34527 #
34528
34529 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
34530 # NAME is the cpp macro being defined and VALUE is the value it is being given.
34531 #
34532 # ac_d sets the value in "#define NAME VALUE" lines.
34533 ac_dA='s,^\([   ]*\)#\([        ]*define[       ][      ]*\)'
34534 ac_dB='[        ].*$,\1#\2'
34535 ac_dC=' '
34536 ac_dD=',;t'
34537 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
34538 ac_uA='s,^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
34539 ac_uB='$,\1#\2define\3'
34540 ac_uC=' '
34541 ac_uD=',;t'
34542
34543 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
34544   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
34545   case $ac_file in
34546   - | *:- | *:-:* ) # input from stdin
34547         cat >$tmp/stdin
34548         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
34549         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
34550   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
34551         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
34552   * )   ac_file_in=$ac_file.in ;;
34553   esac
34554
34555   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
34556 echo "$as_me: creating $ac_file" >&6;}
34557
34558   # First look for the input files in the build tree, otherwise in the
34559   # src tree.
34560   ac_file_inputs=`IFS=:
34561     for f in $ac_file_in; do
34562       case $f in
34563       -) echo $tmp/stdin ;;
34564       [\\/$]*)
34565          # Absolute (can't be DOS-style, as IFS=:)
34566          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
34567 echo "$as_me: error: cannot find input file: $f" >&2;}
34568    { (exit 1); exit 1; }; }
34569          echo $f;;
34570       *) # Relative
34571          if test -f "$f"; then
34572            # Build tree
34573            echo $f
34574          elif test -f "$srcdir/$f"; then
34575            # Source tree
34576            echo $srcdir/$f
34577          else
34578            # /dev/null tree
34579            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
34580 echo "$as_me: error: cannot find input file: $f" >&2;}
34581    { (exit 1); exit 1; }; }
34582          fi;;
34583       esac
34584     done` || { (exit 1); exit 1; }
34585   # Remove the trailing spaces.
34586   sed 's/[      ]*$//' $ac_file_inputs >$tmp/in
34587
34588 _ACEOF
34589
34590 # Transform confdefs.h into two sed scripts, `conftest.defines' and
34591 # `conftest.undefs', that substitutes the proper values into
34592 # config.h.in to produce config.h.  The first handles `#define'
34593 # templates, and the second `#undef' templates.
34594 # And first: Protect against being on the right side of a sed subst in
34595 # config.status.  Protect against being in an unquoted here document
34596 # in config.status.
34597 rm -f conftest.defines conftest.undefs
34598 # Using a here document instead of a string reduces the quoting nightmare.
34599 # Putting comments in sed scripts is not portable.
34600 #
34601 # `end' is used to avoid that the second main sed command (meant for
34602 # 0-ary CPP macros) applies to n-ary macro definitions.
34603 # See the Autoconf documentation for `clear'.
34604 cat >confdef2sed.sed <<\_ACEOF
34605 s/[\\&,]/\\&/g
34606 s,[\\$`],\\&,g
34607 t clear
34608 : clear
34609 s,^[    ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
34610 t end
34611 s,^[    ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
34612 : end
34613 _ACEOF
34614 # If some macros were called several times there might be several times
34615 # the same #defines, which is useless.  Nevertheless, we may not want to
34616 # sort them, since we want the *last* AC-DEFINE to be honored.
34617 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
34618 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
34619 rm -f confdef2sed.sed
34620
34621 # This sed command replaces #undef with comments.  This is necessary, for
34622 # example, in the case of _POSIX_SOURCE, which is predefined and required
34623 # on some systems where configure will not decide to define it.
34624 cat >>conftest.undefs <<\_ACEOF
34625 s,^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
34626 _ACEOF
34627
34628 # Break up conftest.defines because some shells have a limit on the size
34629 # of here documents, and old seds have small limits too (100 cmds).
34630 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
34631 echo '  if grep "^[     ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
34632 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
34633 echo '  :' >>$CONFIG_STATUS
34634 rm -f conftest.tail
34635 while grep . conftest.defines >/dev/null
34636 do
34637   # Write a limited-size here document to $tmp/defines.sed.
34638   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
34639   # Speed up: don't consider the non `#define' lines.
34640   echo '/^[     ]*#[    ]*define/!b' >>$CONFIG_STATUS
34641   # Work around the forget-to-reset-the-flag bug.
34642   echo 't clr' >>$CONFIG_STATUS
34643   echo ': clr' >>$CONFIG_STATUS
34644   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
34645   echo 'CEOF
34646   sed -f $tmp/defines.sed $tmp/in >$tmp/out
34647   rm -f $tmp/in
34648   mv $tmp/out $tmp/in
34649 ' >>$CONFIG_STATUS
34650   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
34651   rm -f conftest.defines
34652   mv conftest.tail conftest.defines
34653 done
34654 rm -f conftest.defines
34655 echo '  fi # grep' >>$CONFIG_STATUS
34656 echo >>$CONFIG_STATUS
34657
34658 # Break up conftest.undefs because some shells have a limit on the size
34659 # of here documents, and old seds have small limits too (100 cmds).
34660 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
34661 rm -f conftest.tail
34662 while grep . conftest.undefs >/dev/null
34663 do
34664   # Write a limited-size here document to $tmp/undefs.sed.
34665   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
34666   # Speed up: don't consider the non `#undef'
34667   echo '/^[     ]*#[    ]*undef/!b' >>$CONFIG_STATUS
34668   # Work around the forget-to-reset-the-flag bug.
34669   echo 't clr' >>$CONFIG_STATUS
34670   echo ': clr' >>$CONFIG_STATUS
34671   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
34672   echo 'CEOF
34673   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
34674   rm -f $tmp/in
34675   mv $tmp/out $tmp/in
34676 ' >>$CONFIG_STATUS
34677   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
34678   rm -f conftest.undefs
34679   mv conftest.tail conftest.undefs
34680 done
34681 rm -f conftest.undefs
34682
34683 cat >>$CONFIG_STATUS <<\_ACEOF
34684   # Let's still pretend it is `configure' which instantiates (i.e., don't
34685   # use $as_me), people would be surprised to read:
34686   #    /* config.h.  Generated by config.status.  */
34687   if test x"$ac_file" = x-; then
34688     echo "/* Generated by configure.  */" >$tmp/config.h
34689   else
34690     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
34691   fi
34692   cat $tmp/in >>$tmp/config.h
34693   rm -f $tmp/in
34694   if test x"$ac_file" != x-; then
34695     if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
34696       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
34697 echo "$as_me: $ac_file is unchanged" >&6;}
34698     else
34699       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
34700 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
34701          X"$ac_file" : 'X\(//\)[^/]' \| \
34702          X"$ac_file" : 'X\(//\)$' \| \
34703          X"$ac_file" : 'X\(/\)' \| \
34704          .     : '\(.\)' 2>/dev/null ||
34705 echo X"$ac_file" |
34706     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
34707           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
34708           /^X\(\/\/\)$/{ s//\1/; q; }
34709           /^X\(\/\).*/{ s//\1/; q; }
34710           s/.*/./; q'`
34711       { if $as_mkdir_p; then
34712     mkdir -p "$ac_dir"
34713   else
34714     as_dir="$ac_dir"
34715     as_dirs=
34716     while test ! -d "$as_dir"; do
34717       as_dirs="$as_dir $as_dirs"
34718       as_dir=`(dirname "$as_dir") 2>/dev/null ||
34719 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
34720          X"$as_dir" : 'X\(//\)[^/]' \| \
34721          X"$as_dir" : 'X\(//\)$' \| \
34722          X"$as_dir" : 'X\(/\)' \| \
34723          .     : '\(.\)' 2>/dev/null ||
34724 echo X"$as_dir" |
34725     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
34726           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
34727           /^X\(\/\/\)$/{ s//\1/; q; }
34728           /^X\(\/\).*/{ s//\1/; q; }
34729           s/.*/./; q'`
34730     done
34731     test ! -n "$as_dirs" || mkdir $as_dirs
34732   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
34733 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
34734    { (exit 1); exit 1; }; }; }
34735
34736       rm -f $ac_file
34737       mv $tmp/config.h $ac_file
34738     fi
34739   else
34740     cat $tmp/config.h
34741     rm -f $tmp/config.h
34742   fi
34743 done
34744 _ACEOF
34745 cat >>$CONFIG_STATUS <<\_ACEOF
34746
34747 #
34748 # CONFIG_COMMANDS section.
34749 #
34750 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
34751   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
34752   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
34753   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
34754 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
34755          X"$ac_dest" : 'X\(//\)[^/]' \| \
34756          X"$ac_dest" : 'X\(//\)$' \| \
34757          X"$ac_dest" : 'X\(/\)' \| \
34758          .     : '\(.\)' 2>/dev/null ||
34759 echo X"$ac_dest" |
34760     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
34761           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
34762           /^X\(\/\/\)$/{ s//\1/; q; }
34763           /^X\(\/\).*/{ s//\1/; q; }
34764           s/.*/./; q'`
34765   ac_builddir=.
34766
34767 if test "$ac_dir" != .; then
34768   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
34769   # A "../" for each directory in $ac_dir_suffix.
34770   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
34771 else
34772   ac_dir_suffix= ac_top_builddir=
34773 fi
34774
34775 case $srcdir in
34776   .)  # No --srcdir option.  We are building in place.
34777     ac_srcdir=.
34778     if test -z "$ac_top_builddir"; then
34779        ac_top_srcdir=.
34780     else
34781        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
34782     fi ;;
34783   [\\/]* | ?:[\\/]* )  # Absolute path.
34784     ac_srcdir=$srcdir$ac_dir_suffix;
34785     ac_top_srcdir=$srcdir ;;
34786   *) # Relative path.
34787     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
34788     ac_top_srcdir=$ac_top_builddir$srcdir ;;
34789 esac
34790 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
34791 # absolute.
34792 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
34793 ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
34794 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
34795 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
34796
34797
34798   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
34799 echo "$as_me: executing $ac_dest commands" >&6;}
34800   case $ac_dest in
34801     time-stamp ) date >stamp-h
34802 echo Please run \"make depend\" to build dependencies ;;
34803   esac
34804 done
34805 _ACEOF
34806
34807 cat >>$CONFIG_STATUS <<\_ACEOF
34808
34809 { (exit 0); exit 0; }
34810 _ACEOF
34811 chmod +x $CONFIG_STATUS
34812 ac_clean_files=$ac_clean_files_save
34813
34814
34815 # configure is writing to config.log, and then calls config.status.
34816 # config.status does its own redirection, appending to config.log.
34817 # Unfortunately, on DOS this fails, as config.log is still kept open
34818 # by configure, so config.status won't be able to write to it; its
34819 # output is simply discarded.  So we exec the FD to /dev/null,
34820 # effectively closing config.log, so it can be properly (re)opened and
34821 # appended to by config.status.  When coming back to configure, we
34822 # need to make the FD available again.
34823 if test "$no_create" != yes; then
34824   ac_cs_success=:
34825   ac_config_status_args=
34826   test "$silent" = yes &&
34827     ac_config_status_args="$ac_config_status_args --quiet"
34828   exec 5>/dev/null
34829   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
34830   exec 5>>config.log
34831   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
34832   # would make configure fail if this is the last instruction.
34833   $ac_cs_success || { (exit 1); exit 1; }
34834 fi
34835